From 9b1e675ce6f6fdbf48f4c3b4eea1eada00c49628 Mon Sep 17 00:00:00 2001 From: Yi Song Date: Thu, 19 Dec 2024 18:22:07 +0800 Subject: [PATCH] chore: fix some typos in comment (#12650) Signed-off-by: goodfirm --- benchmarks/continuous/db/tool/cli/src/main.rs | 2 +- chain/network/src/config.rs | 2 +- chain/network/src/types.rs | 2 +- docs/practices/workflows/profiling.md | 2 +- integration-tests/src/tests/client/resharding_v2.rs | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/benchmarks/continuous/db/tool/cli/src/main.rs b/benchmarks/continuous/db/tool/cli/src/main.rs index df57ac333b9..b9d43e016c7 100644 --- a/benchmarks/continuous/db/tool/cli/src/main.rs +++ b/benchmarks/continuous/db/tool/cli/src/main.rs @@ -26,7 +26,7 @@ fn main() -> anyhow::Result<()> { #[derive(Debug, Parser)] #[command( - about = "A CLI to interact with the db storing contiuous benchmark data. Commands that connect to the db require the env var DATABASE_URL_CLI to be set in a format compatible with the diesel crate. Consider sourcing the dbprofile file in the repository.", + about = "A CLI to interact with the db storing continuous benchmark data. Commands that connect to the db require the env var DATABASE_URL_CLI to be set in a format compatible with the diesel crate. Consider sourcing the dbprofile file in the repository.", long_about = None )] struct Cli { diff --git a/chain/network/src/config.rs b/chain/network/src/config.rs index 6e020c799c2..8e06b8452ab 100644 --- a/chain/network/src/config.rs +++ b/chain/network/src/config.rs @@ -90,7 +90,7 @@ pub struct Tier1 { /// TIER1 can consists of hundreds of nodes, so it is not feasible to connect to all of them at /// once. pub new_connections_per_attempt: u64, - /// Interval between broacasts of the list of validator's proxies. + /// Interval between broadcasts of the list of validator's proxies. /// Before the broadcast, validator tries to establish all the missing connections to proxies. pub advertise_proxies_interval: time::Duration, /// Support for gradual TIER1 feature rollout: diff --git a/chain/network/src/types.rs b/chain/network/src/types.rs index cd83e57fbd3..3b257f22c0b 100644 --- a/chain/network/src/types.rs +++ b/chain/network/src/types.rs @@ -157,7 +157,7 @@ pub type AccountKeys = HashMap>; #[derive(Debug, Clone)] pub struct ChainInfo { pub tracked_shards: Vec, - // The lastest block on chain. + // The latest block on chain. pub block: Block, // Public keys of accounts participating in the BFT consensus // It currently includes "block producers", "chunk producers" and "approvers". diff --git a/docs/practices/workflows/profiling.md b/docs/practices/workflows/profiling.md index 876f25fe79c..4187d378cdb 100755 --- a/docs/practices/workflows/profiling.md +++ b/docs/practices/workflows/profiling.md @@ -69,7 +69,7 @@ $ perf record -e cpu-clock -F1000 -g --call-graph fp,65528 YOUR_COMMAND_HERE ### Profiling with hardware counters -As mentioned earlier, sampling profiler is probablistic and the data it produces is only really +As mentioned earlier, sampling profiler is probabilistic and the data it produces is only really suitable for a broad overview. Any attempt to analyze the performance of the code at the microarchitectural level (which you might want to do if investigating how to speed up a small but frequently invoked function) will be severely hampered by the low quality of data. diff --git a/integration-tests/src/tests/client/resharding_v2.rs b/integration-tests/src/tests/client/resharding_v2.rs index c6782846c8d..59eae8e41db 100644 --- a/integration-tests/src/tests/client/resharding_v2.rs +++ b/integration-tests/src/tests/client/resharding_v2.rs @@ -359,7 +359,7 @@ impl TestReshardingEnv { let shard_layout = client.epoch_manager.get_shard_layout(&epoch_id).unwrap(); for shard_id in shard_layout.shard_ids() { // get hash of the last block that we need to check that it has empty chunks for the shard - // if `get_next_block_hash_with_new_chunk` returns None, that would be the lastest block + // if `get_next_block_hash_with_new_chunk` returns None, that would be the latest block // on chain, otherwise, that would be the block before the `block_hash` that the function // call returns let next_block_hash_with_new_chunk =