Skip to content

Commit

Permalink
chore: remove repetitive words (#16702)
Browse files Browse the repository at this point in the history
## Description 

Describe the changes or additions included in this PR.

## Test Plan 

How did you test the new or updated feature?

---
If your changes are not user-facing and do not break anything, you can
skip the following section. Otherwise, please briefly describe what has
changed under the Release Notes section.

### Type of Change (Check all that apply)

- [ ] protocol change
- [ ] user-visible impact
- [ ] breaking change for a client SDKs
- [ ] breaking change for FNs (FN binary must upgrade)
- [ ] breaking change for validators or node operators (must upgrade
binaries)
- [ ] breaking change for on-chain data layout
- [ ] necessitate either a data wipe or data migration

### Release notes

Signed-off-by: hishope <[email protected]>
  • Loading branch information
hishope authored Mar 18, 2024
1 parent 67b4c83 commit 4282678
Show file tree
Hide file tree
Showing 28 changed files with 31 additions and 31 deletions.
2 changes: 1 addition & 1 deletion consensus/core/src/commit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ pub(crate) struct CommitV1 {
/// Digest of the previous commit.
/// Set to CommitDigest::MIN for the first commit after genesis.
previous_digest: CommitDigest,
/// A reference to the the commit leader.
/// A reference to the commit leader.
leader: BlockRef,
/// Refs to committed blocks, in the commit order.
blocks: Vec<BlockRef>,
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-aws-orchestrator/src/benchmark.rs
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ impl<T: BenchmarkType> BenchmarkParametersGenerator<T> {
}
}
LoadType::Search { max_iterations, .. } => {
// Terminate the the search.
// Terminate the search.
if self.iterations >= *max_iterations {
None

Expand Down
2 changes: 1 addition & 1 deletion crates/sui-config/src/node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -706,7 +706,7 @@ pub struct AuthorityOverloadConfig {
#[serde(default = "default_max_load_shedding_percentage")]
pub max_load_shedding_percentage: u32,

// When in aggressive load shedding mode, the the minimum percentage of
// When in aggressive load shedding mode, the minimum percentage of
// transactions to shed.
#[serde(default = "default_min_load_shedding_percentage_above_hard_limit")]
pub min_load_shedding_percentage_above_hard_limit: u32,
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-core/src/execution_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ pub trait ExecutionCacheRead: Send + Sync {
// be false, but since this is a receiving object we should mark it as available if
// we can determine that an object with a version greater than or equal to the
// specified version exists or was deleted. We will then let mark it as available
// to let the the transaction through so it can fail at execution.
// to let the transaction through so it can fail at execution.
let is_available = self
.get_object(&input_key.id())?
.map(|obj| obj.version() >= input_key.version().unwrap())
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-core/src/execution_cache/writeback_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ struct UncommittedData {
/// This table may contain both live and dead objects, since we flush both live and dead
/// objects to the db in order to support past object queries on fullnodes.
///
/// Further, we only remove objects in FIFO order, which ensures that the the cached
/// Further, we only remove objects in FIFO order, which ensures that the cached
/// sequence of objects has no gaps. In other words, if we have versions 4, 8, 13 of
/// an object, we can deduce that version 9 does not exist. This also makes child object
/// reads efficient. `object_cache` cannot contain a more recent version of an object than
Expand Down
6 changes: 3 additions & 3 deletions crates/sui-faucet/src/faucet/simple_faucet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1417,7 +1417,7 @@ mod tests {

let number_of_coins = gases.len();
let amounts = &vec![1; number_of_coins];
// We traverse the the list twice, which must trigger the transferred gas to be kicked out
// We traverse the list twice, which must trigger the transferred gas to be kicked out
futures::future::join_all((0..2).map(|_| {
faucet.send(
Uuid::new_v4(),
Expand Down Expand Up @@ -1566,7 +1566,7 @@ mod tests {
// Ask for a value higher than tiny coin + DEFAULT_GAS_COMPUTATION_BUCKET
let number_of_coins = gases.len();
let amounts = &vec![tiny_value + 1; number_of_coins];
// We traverse the the list ten times, which must trigger the tiny gas to be examined and then discarded
// We traverse the list ten times, which must trigger the tiny gas to be examined and then discarded
futures::future::join_all((0..10).map(|_| {
faucet.send(
Uuid::new_v4(),
Expand Down Expand Up @@ -1648,7 +1648,7 @@ mod tests {
.await
.unwrap();

// We traverse the the list twice, which must trigger the split gas to be kicked out
// We traverse the list twice, which must trigger the split gas to be kicked out
futures::future::join_all((0..2).map(|_| {
faucet.send(
Uuid::new_v4(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ Sender is not @0x0 the system address.

<a name="0x2_sui_MIST_PER_SUI"></a>

The amount of Mist per Sui token based on the the fact that mist is
The amount of Mist per Sui token based on the fact that mist is
10^-9 of a Sui token


Expand Down
2 changes: 1 addition & 1 deletion crates/sui-framework/docs/sui-framework/sui.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ Sender is not @0x0 the system address.

<a name="0x2_sui_MIST_PER_SUI"></a>

The amount of Mist per Sui token based on the the fact that mist is
The amount of Mist per Sui token based on the fact that mist is
10^-9 of a Sui token


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ Sender is not @0x0 the system address.

<a name="0x2_sui_MIST_PER_SUI"></a>

The amount of Mist per Sui token based on the the fact that mist is
The amount of Mist per Sui token based on the fact that mist is
10^-9 of a Sui token


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ module sui::sui {
const ENotSystemAddress: u64 = 1;

#[allow(unused_const)]
/// The amount of Mist per Sui token based on the the fact that mist is
/// The amount of Mist per Sui token based on the fact that mist is
/// 10^-9 of a Sui token
const MIST_PER_SUI: u64 = 1_000_000_000;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3581,7 +3581,7 @@ type SystemParameters {
"""
validatorLowStakeThreshold: BigInt
"""
Validators with stake below this threshold will be removed from the the active validator set
Validators with stake below this threshold will be removed from the active validator set
at the next epoch boundary, without a grace period.
"""
validatorVeryLowStakeThreshold: BigInt
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-graphql-rpc/src/types/system_parameters.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pub(crate) struct SystemParameters {
/// `validatorLowStakeGracePeriod`), after which they are removed from the active validator set.
pub validator_low_stake_threshold: Option<BigInt>,

/// Validators with stake below this threshold will be removed from the the active validator set
/// Validators with stake below this threshold will be removed from the active validator set
/// at the next epoch boundary, without a grace period.
pub validator_very_low_stake_threshold: Option<BigInt>,

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3585,7 +3585,7 @@ type SystemParameters {
"""
validatorLowStakeThreshold: BigInt
"""
Validators with stake below this threshold will be removed from the the active validator set
Validators with stake below this threshold will be removed from the active validator set
at the next epoch boundary, without a grace period.
"""
validatorVeryLowStakeThreshold: BigInt
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-sdk/src/apis.rs
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ impl ReadApi {
.await?)
}

/// Return the loaded child objects response for the the provided digest, or an error upon failure.
/// Return the loaded child objects response for the provided digest, or an error upon failure.
///
/// Loaded child objects ([SuiLoadedChildObject](sui_json_rpc_types::SuiLoadedChildObject)) are the non-input objects that the transaction at the digest loaded
/// in response to dynamic field accesses.
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-types/src/gas_model/tables.rs
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ impl GasMeter for GasStatus {
}

fn charge_read_ref(&mut self, ref_val: impl ValueView) -> PartialVMResult<()> {
// We read the the reference so we are decreasing the size of the stack by the size of the
// We read the reference so we are decreasing the size of the stack by the size of the
// reference, and adding to it the size of the value that has been read from that
// reference.
self.charge(
Expand Down
2 changes: 1 addition & 1 deletion crates/transaction-fuzzer/src/account_universe.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ pub fn default_num_transactions() -> usize {
/// Represents any sort of transaction that can be done in an account universe.
pub trait AUTransactionGen: fmt::Debug {
/// Applies this transaction onto the universe, updating balances within the universe as
/// necessary. Returns a signed transaction that can be run on the VM and the the execution status.
/// necessary. Returns a signed transaction that can be run on the VM and the execution status.
fn apply(
&self,
universe: &mut AccountUniverse,
Expand Down
2 changes: 1 addition & 1 deletion docker/grafana-local/tempo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ storage:
trace:
backend: local # backend configuration to use
wal:
path: /tmp/tempo/wal # where to store the the wal locally
path: /tmp/tempo/wal # where to store the wal locally
local:
path: /tmp/tempo/blocks

Expand Down
2 changes: 1 addition & 1 deletion docs/content/concepts/cryptography/zklogin.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@ However, Groth16 needs a computation-specific Common Reference String (CRS) to b

The Sui zkLogin ceremony is essentially a cryptographic multi-party computation (MPC) performed by a diverse group of participants to generate this CRS. We follow the MPC protocol [MMORPG](https://eprint.iacr.org/2017/1050.pdf) described by Bowe, Gabizon and Miers. The protocol roughly proceeds in 2 phases. The first phase results in a series of powers of a secret quantity tau in the exponent of an elliptic curve element. Since this phase is circuit-agnostic, we adopted the result of the existing community contributed [perpetual powers of tau](https://github.com/privacy-scaling-explorations/perpetualpowersoftau/tree/master). Our ceremony was the second phase, which is specific to the zkLogin circuit.

The MMORPG protocol is a sequential protocol, which allows an indefinite number of parties to participate in sequence, without the need of any prior synchronization or ordering. Each party needs to download the output of the previous party, generate entropy of its own and then layer it on top of the received result, producing its own contribution, which is then relayed to the next party. The protocol guarantees security, if at least one of the the participants follows the protocol faithfully, generates strong entropy and discards it reliably.
The MMORPG protocol is a sequential protocol, which allows an indefinite number of parties to participate in sequence, without the need of any prior synchronization or ordering. Each party needs to download the output of the previous party, generate entropy of its own and then layer it on top of the received result, producing its own contribution, which is then relayed to the next party. The protocol guarantees security, if at least one of the participants follows the protocol faithfully, generates strong entropy and discards it reliably.

### How was the ceremony performed?

Expand Down
4 changes: 2 additions & 2 deletions docs/content/concepts/transactions/prog-txn-blocks.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ For pure inputs, the only data provided is the [BCS](https://github.com/MystenLa
- A vector, `vector<T>`, where `T` is a valid type for a pure input, checked recursively.
- An option, `std::option::Option<T>`, where `T` is a valid type for a pure input, checked recursively.

Interestingly, the bytes are not validated until the type is specified in a command, for example in `MoveCall` or `MakeMoveVec`. This means that a given pure input could be used to instantiate Move values of several types. See the the [Arguments section](#arguments) for more details.
Interestingly, the bytes are not validated until the type is specified in a command, for example in `MoveCall` or `MakeMoveVec`. This means that a given pure input could be used to instantiate Move values of several types. See the [Arguments section](#arguments) for more details.

### Results

Expand Down Expand Up @@ -264,7 +264,7 @@ Suppose you want to buy two items from a marketplace costing `100 MIST`. You kee

The inputs include the friend's address, the marketplace object, and the value for the coin split. For the commands, split off the coin, call the market place function, send the gas coin and one object, grab your address (via `sui::tx_context::sender`), and then send the remaining object to yourself. For simplicity, the documentation refers to the package names by name, but note that in practice they are referenced by the package's Object ID.

To walk through this, first look at the the memory locations, for the gas object, inputs, and results
To walk through this, first look at the memory locations, for the gas object, inputs, and results

```rust
Gas Coin: sui::coin::Coin<SUI> { id: gas_coin, balance: sui::balance::Balance<SUI> { value: 1_000_000u64 } }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -798,7 +798,7 @@ On modifications that are made to the template package this process needs to be

:::

Before proceeding to how to make these edits, it's important to understand how the library exposes the template module bytecode. The process is currently manual. This requires that you build and retrieve the compiled bytecode. To do this, navigate inside the the template folder and run the following command:
Before proceeding to how to make these edits, it's important to understand how the library exposes the template module bytecode. The process is currently manual. This requires that you build and retrieve the compiled bytecode. To do this, navigate inside the template folder and run the following command:

```bash
xxd -c 0 -p build/template/bytecode_modules/template.mv | head -n 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ export function useCreateEscrowMutation() {

### Accept escrows

To accept the escrow, create a mutation through the `useAcceptEscrowMutation` hook in `src/mutations/escrow.ts`. The implementation should be fairly familiar to you now. The accept function accepts the escrow `ApiEscrowObject` and the locked object `ApiLockedObject`. The `{PACKAGE_ID}::shared::swap` Move call is generic, thus it requires the type parameters of the escrowed and locked objects. Query the objects details by using `multiGetObjects` on Sui client instance. Lastly, execute the `{PACKAGE_ID}::shared::swap` Move call and transfer the returned escrowed item to the the connected wallet account. When the mutation succeeds, invalidate the cache to allow automatic re-fetch of the data.
To accept the escrow, create a mutation through the `useAcceptEscrowMutation` hook in `src/mutations/escrow.ts`. The implementation should be fairly familiar to you now. The accept function accepts the escrow `ApiEscrowObject` and the locked object `ApiLockedObject`. The `{PACKAGE_ID}::shared::swap` Move call is generic, thus it requires the type parameters of the escrowed and locked objects. Query the objects details by using `multiGetObjects` on Sui client instance. Lastly, execute the `{PACKAGE_ID}::shared::swap` Move call and transfer the returned escrowed item to the connected wallet account. When the mutation succeeds, invalidate the cache to allow automatic re-fetch of the data.

```ts title='src/mutations/escrow.ts'
import { ApiEscrowObject, ApiLockedObject } from '@/types/types';
Expand Down
2 changes: 1 addition & 1 deletion narwhal/types/src/consensus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ pub type SequenceNumber = u64;

#[derive(Clone, Debug)]
/// The output of Consensus, which includes all the batches for each certificate in the sub dag
/// It is sent to the the ExecutionState handle_consensus_transactions
/// It is sent to the ExecutionState handle_consensus_transactions
pub struct ConsensusOutput {
pub sub_dag: Arc<CommittedSubDag>,
/// Matches certificates in the `sub_dag` one-to-one.
Expand Down
2 changes: 1 addition & 1 deletion sdk/docs/pages/dapp-kit/wallet-hooks/useConnectWallet.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,5 @@ function MyComponent() {
- `wallet` - The wallet to connect to.
- `accountAddress` - (optional) The address in the wallet to connect to.

- `options` - Options passed the the `useMutation` hook from
- `options` - Options passed the `useMutation` hook from
[@tanstack/react-query](https://tanstack.com/query/latest/docs/react/guides/mutations).
2 changes: 1 addition & 1 deletion sdk/docs/pages/dapp-kit/wallet-hooks/useSwitchAccount.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -47,5 +47,5 @@ function MyComponent() {

- `account` - The account to switch to.

- `options` - Options passed the the `useMutation` hook from
- `options` - Options passed the `useMutation` hook from
[@tanstack/react-query](https://tanstack.com/query/latest/docs/react/guides/mutations).
2 changes: 1 addition & 1 deletion sdk/graphql-transport/src/generated/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4042,7 +4042,7 @@ export type SystemParameters = {
*/
validatorLowStakeThreshold?: Maybe<Scalars['BigInt']['output']>;
/**
* Validators with stake below this threshold will be removed from the the active validator set
* Validators with stake below this threshold will be removed from the active validator set
* at the next epoch boundary, without a grace period.
*/
validatorVeryLowStakeThreshold?: Maybe<Scalars['BigInt']['output']>;
Expand Down
2 changes: 1 addition & 1 deletion sui-execution/latest/sui-adapter/src/gas_charger.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ pub mod checked {
tx_digest: TransactionDigest,
gas_model_version: u64,
gas_coins: Vec<ObjectRef>,
// this is the the first gas coin in `gas_coins` and the one that all others will
// this is the first gas coin in `gas_coins` and the one that all others will
// be smashed into. It can be None for system transactions when `gas_coins` is empty.
smashed_gas_coin: Option<ObjectID>,
gas_status: SuiGasStatus,
Expand Down
2 changes: 1 addition & 1 deletion sui-execution/v0/sui-adapter/src/gas_charger.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ pub mod checked {
tx_digest: TransactionDigest,
gas_model_version: u64,
gas_coins: Vec<ObjectRef>,
// this is the the first gas coin in `gas_coins` and the one that all others will
// this is the first gas coin in `gas_coins` and the one that all others will
// be smashed into. It can be None for system transactions when `gas_coins` is empty.
smashed_gas_coin: Option<ObjectID>,
gas_status: SuiGasStatus,
Expand Down
2 changes: 1 addition & 1 deletion sui-execution/v1/sui-adapter/src/gas_charger.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ pub mod checked {
tx_digest: TransactionDigest,
gas_model_version: u64,
gas_coins: Vec<ObjectRef>,
// this is the the first gas coin in `gas_coins` and the one that all others will
// this is the first gas coin in `gas_coins` and the one that all others will
// be smashed into. It can be None for system transactions when `gas_coins` is empty.
smashed_gas_coin: Option<ObjectID>,
gas_status: SuiGasStatus,
Expand Down

0 comments on commit 4282678

Please sign in to comment.