From 189a77b6da89085b6448dc9c3d4c9c2ed30a4322 Mon Sep 17 00:00:00 2001 From: Jeb Bearer Date: Mon, 23 Sep 2024 10:40:00 -0400 Subject: [PATCH 1/6] Include details in error message for header construction (#3690) --- crates/task-impls/src/quorum_proposal/handlers.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/task-impls/src/quorum_proposal/handlers.rs b/crates/task-impls/src/quorum_proposal/handlers.rs index 867b6298a9..e53a618320 100644 --- a/crates/task-impls/src/quorum_proposal/handlers.rs +++ b/crates/task-impls/src/quorum_proposal/handlers.rs @@ -362,7 +362,7 @@ impl HandleDepOutput for ProposalDependencyHandle< ) .await { - error!("Failed to publish proposal; error = {e}"); + error!("Failed to publish proposal; error = {e:#}"); } } } From 1b8d676202c4ed361ead81265271ae8540661162 Mon Sep 17 00:00:00 2001 From: ss-es <155648797+ss-es@users.noreply.github.com> Date: Mon, 23 Sep 2024 11:04:03 -0400 Subject: [PATCH 2/6] Lower threshold for marketplace test (#3692) --- crates/testing/tests/tests_3/test_marketplace.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/testing/tests/tests_3/test_marketplace.rs b/crates/testing/tests/tests_3/test_marketplace.rs index 2d97535427..eb0738ffc7 100644 --- a/crates/testing/tests/tests_3/test_marketplace.rs +++ b/crates/testing/tests/tests_3/test_marketplace.rs @@ -73,7 +73,7 @@ cross_tests!( ); // Test marketplace with both regular builders down but solver + fallback builder up -// Requires 90% nonempty blocks +// Requires 80% nonempty blocks cross_tests!( TestName: test_marketplace_builders_down, Impls: [MemoryImpl], @@ -96,7 +96,7 @@ cross_tests!( changes: HashMap::from([(0, BuilderChange::Down)]) } ], - validate_transactions: nonempty_block_threshold((90,100)), + validate_transactions: nonempty_block_threshold((40,50)), ..TestDescription::default() } }, @@ -128,7 +128,7 @@ cross_tests!( BuilderDescription { changes: HashMap::from([(0, BuilderChange::Down)]) }, - validate_transactions: nonempty_block_threshold((80,100)), + validate_transactions: nonempty_block_threshold((40,50)), ..TestDescription::default() } }, From a3c89783723d23ee4f26708284e8f77870e042ca Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 11:08:07 -0400 Subject: [PATCH 3/6] Bump the all group with 2 updates (#3691) Bumps the all group with 2 updates: [tide-disco](https://github.com/EspressoSystems/tide-disco) and [clap](https://github.com/clap-rs/clap). Updates `tide-disco` from 0.9.0 to 0.9.2 - [Release notes](https://github.com/EspressoSystems/tide-disco/releases) - [Commits](https://github.com/EspressoSystems/tide-disco/compare/v0.9.0...v0.9.2) Updates `clap` from 4.5.17 to 4.5.18 - [Release notes](https://github.com/clap-rs/clap/releases) - [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md) - [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.17...clap_complete-v4.5.18) --- updated-dependencies: - dependency-name: tide-disco dependency-type: direct:production update-type: version-update:semver-patch dependency-group: all - dependency-name: clap dependency-type: direct:production update-type: version-update:semver-patch dependency-group: all ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Cargo.lock | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index e5955431d0..5aad960f2f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1122,7 +1122,7 @@ dependencies = [ "bitflags 2.5.0", "cexpr", "clang-sys", - "itertools 0.12.1", + "itertools 0.10.5", "lazy_static", "lazycell", "log", @@ -1455,9 +1455,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.17" +version = "4.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e5a21b8495e732f1b3c364c9949b201ca7bae518c502c80256c96ad79eaf6ac" +checksum = "b0956a43b323ac1afaffc053ed5c4b7c1f1800bacd1683c353aabbb752515dd3" dependencies = [ "clap_builder", "clap_derive", @@ -1465,9 +1465,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.17" +version = "4.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cf2dd12af7a047ad9d6da2b6b249759a22a7abc0f474c1dae1777afa4b21a73" +checksum = "4d72166dd41634086d5803a47eb71ae740e61d84709c36f3c34110173db3961b" dependencies = [ "anstream", "anstyle", @@ -1477,9 +1477,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.13" +version = "4.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "501d359d5f3dcaf6ecdeee48833ae73ec6e42723a1e52419c79abf9507eec0a0" +checksum = "4ac6a0c7b1a9e9a5186361f67dfa1b88213572f427fb9ab038efb2bd8c582dab" dependencies = [ "heck 0.5.0", "proc-macro2", @@ -4232,7 +4232,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c2a198fb6b0eada2a8df47933734e6d35d350665a33a3593d7164fa52c75c19" dependencies = [ "cfg-if", - "windows-targets 0.52.6", + "windows-targets 0.48.5", ] [[package]] @@ -5773,7 +5773,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "81bddcdb20abf9501610992b6759a4c888aef7d1a7247ef75e2404275ac24af1" dependencies = [ "anyhow", - "itertools 0.12.1", + "itertools 0.10.5", "proc-macro2", "quote", "syn 2.0.77", @@ -6995,7 +6995,7 @@ version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "38d1e02fca405f6280643174a50c942219f0bbf4dbf7d480f1dd864d6f211ae5" dependencies = [ - "heck 0.5.0", + "heck 0.4.1", "proc-macro2", "quote", "syn 2.0.77", @@ -7666,9 +7666,9 @@ dependencies = [ [[package]] name = "tide-disco" -version = "0.9.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01e81752cd71cc517973c6ff743919848d7c9890331f38c43abadfb49eede3a6" +checksum = "4cb76ff5fefcbad305ea82288a2f6828e6a2eff992fe60fb492b45b195382c8f" dependencies = [ "anyhow", "async-h1", From afda0c1cbb3d9c9cb4b995181b669349a82bd59a Mon Sep 17 00:00:00 2001 From: ss-es <155648797+ss-es@users.noreply.github.com> Date: Mon, 23 Sep 2024 12:25:47 -0400 Subject: [PATCH 4/6] Fix double counting nodes in `post_ready` (#3694) --- crates/orchestrator/src/lib.rs | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/crates/orchestrator/src/lib.rs b/crates/orchestrator/src/lib.rs index f6c83c9309..ba9d31e463 100644 --- a/crates/orchestrator/src/lib.rs +++ b/crates/orchestrator/src/lib.rs @@ -12,7 +12,7 @@ pub mod client; pub mod config; use std::{ - collections::HashMap, + collections::{HashMap, HashSet}, fs::OpenOptions, io::{self, ErrorKind}, time::Duration, @@ -90,7 +90,7 @@ struct OrchestratorState { /// Will be set to true once all nodes post they are ready to start start: bool, /// The total nodes that have posted they are ready to start - nodes_connected: u64, + nodes_connected: HashSet>, /// The results of the benchmarks bench_results: BenchResults, /// The number of nodes that have posted their results @@ -131,7 +131,7 @@ impl OrchestratorState { config: network_config, peer_pub_ready, pub_posted: HashMap::new(), - nodes_connected: 0, + nodes_connected: HashSet::new(), start: false, bench_results: BenchResults::default(), nodes_post_results: 0, @@ -534,12 +534,16 @@ where }); } - self.nodes_connected += 1; - - tracing::error!("Nodes connected: {}", self.nodes_connected); + // `HashSet::insert()` returns whether the node was newly inserted (true) or not + if self.nodes_connected.insert(peer_config.clone()) { + tracing::error!( + "Node {peer_config} connected. Total nodes connected: {}", + self.nodes_connected.len() + ); + } // i.e. nodes_connected >= num_nodes_with_stake * (start_threshold.0 / start_threshold.1) - if self.nodes_connected * self.config.config.start_threshold.1 + if self.nodes_connected.len() as u64 * self.config.config.start_threshold.1 >= (self.config.config.num_nodes_with_stake.get() as u64) * self.config.config.start_threshold.0 { From bc887d784c39c4ee86f7935ae7736471bd758f8e Mon Sep 17 00:00:00 2001 From: Keyao Shen Date: Mon, 23 Sep 2024 09:57:04 -0700 Subject: [PATCH 5/6] Bump version (#3689) --- Cargo.lock | 22 +++++++++++----------- Cargo.toml | 2 +- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5aad960f2f..96e2c53032 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3077,7 +3077,7 @@ dependencies = [ [[package]] name = "hotshot" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-broadcast", @@ -3144,7 +3144,7 @@ dependencies = [ [[package]] name = "hotshot-example-types" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-broadcast", @@ -3176,7 +3176,7 @@ dependencies = [ [[package]] name = "hotshot-examples" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-broadcast", @@ -3226,7 +3226,7 @@ dependencies = [ [[package]] name = "hotshot-fakeapi" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-lock 2.8.0", @@ -3244,7 +3244,7 @@ dependencies = [ [[package]] name = "hotshot-macros" -version = "0.5.74" +version = "0.5.75" dependencies = [ "derive_builder", "proc-macro2", @@ -3254,7 +3254,7 @@ dependencies = [ [[package]] name = "hotshot-orchestrator" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-compatibility-layer", @@ -3283,7 +3283,7 @@ dependencies = [ [[package]] name = "hotshot-stake-table" -version = "0.5.74" +version = "0.5.75" dependencies = [ "ark-bn254", "ark-ed-on-bn254", @@ -3304,7 +3304,7 @@ dependencies = [ [[package]] name = "hotshot-task" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-broadcast", @@ -3318,7 +3318,7 @@ dependencies = [ [[package]] name = "hotshot-task-impls" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-broadcast", @@ -3354,7 +3354,7 @@ dependencies = [ [[package]] name = "hotshot-testing" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-broadcast", @@ -4515,7 +4515,7 @@ dependencies = [ [[package]] name = "libp2p-networking" -version = "0.5.74" +version = "0.5.75" dependencies = [ "anyhow", "async-compatibility-layer", diff --git a/Cargo.toml b/Cargo.toml index 41365c9a2c..680ed9e007 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [workspace.package] -version = "0.5.74" # same as `hotshot`, but workspace subcrate can also release its own version +version = "0.5.75" # same as `hotshot`, but workspace subcrate can also release its own version authors = ["Espresso Systems "] edition = "2021" rust-version = "1.76.0" From 66f69e436015b55d8b8ca5f9d5ae6b1e7067e126 Mon Sep 17 00:00:00 2001 From: Jarred Parr Date: Mon, 23 Sep 2024 12:47:33 -0600 Subject: [PATCH 6/6] remove generic-array (#3696) --- Cargo.lock | 1 - Cargo.toml | 7 ++----- crates/types/Cargo.toml | 4 ---- crates/types/src/qc.rs | 2 +- crates/types/src/signature_key.rs | 2 +- crates/types/src/traits/qc.rs | 2 +- 6 files changed, 5 insertions(+), 13 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 96e2c53032..1101fc1a0a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3426,7 +3426,6 @@ dependencies = [ "espresso-systems-common", "ethereum-types", "futures", - "generic-array", "jf-pcs", "jf-signature", "jf-utils", diff --git a/Cargo.toml b/Cargo.toml index 680ed9e007..57b30eba38 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [workspace.package] -version = "0.5.75" # same as `hotshot`, but workspace subcrate can also release its own version +version = "0.5.75" # same as `hotshot`, but workspace subcrate can also release its own version authors = ["Espresso Systems "] edition = "2021" rust-version = "1.76.0" @@ -57,11 +57,8 @@ espresso-systems-common = { git = "https://github.com/espressosystems/espresso-s ethereum-types = { version = "0.14", default-features = false, features = [ "serialize", ] } -derive_more = { version = "1.0", features = [ "from" ] } +derive_more = { version = "1.0", features = ["from"] } futures = { version = "0.3", default-features = false } -# TODO generic-array should not be a direct dependency -# https://github.com/EspressoSystems/HotShot/issues/1850 -generic-array = { version = "0.14.7", features = ["serde"] } jf-crhf = { version = "0.1.0", git = "https://github.com/EspressoSystems/jellyfish", tag = "0.4.5" } jf-vid = { version = "0.1.0", git = "https://github.com/EspressoSystems/jellyfish", tag = "0.4.5" } jf-signature = { version = "0.1.0", git = "https://github.com/EspressoSystems/jellyfish", tag = "0.4.5" } diff --git a/crates/types/Cargo.toml b/crates/types/Cargo.toml index cb0f1faede..652c035e89 100644 --- a/crates/types/Cargo.toml +++ b/crates/types/Cargo.toml @@ -29,10 +29,6 @@ futures = { workspace = true } cdn-proto = { workspace = true } reqwest = { workspace = true } -generic-array = { workspace = true } - -# TODO generic-array should not be a direct dependency -# https://github.com/EspressoSystems/HotShot/issues/1850 lazy_static = { workspace = true } memoize = { workspace = true } rand = { workspace = true } diff --git a/crates/types/src/qc.rs b/crates/types/src/qc.rs index 18a9739347..2f556159a2 100644 --- a/crates/types/src/qc.rs +++ b/crates/types/src/qc.rs @@ -16,8 +16,8 @@ use ark_std::{ vec::Vec, }; use bitvec::prelude::*; +use digest::generic_array::GenericArray; use ethereum_types::U256; -use generic_array::GenericArray; use jf_signature::{AggregateableSignatureSchemes, SignatureError}; use serde::{Deserialize, Serialize}; use typenum::U32; diff --git a/crates/types/src/signature_key.rs b/crates/types/src/signature_key.rs index 562e77cb06..2741912f14 100644 --- a/crates/types/src/signature_key.rs +++ b/crates/types/src/signature_key.rs @@ -8,8 +8,8 @@ use ark_serialize::SerializationError; use bitvec::{slice::BitSlice, vec::BitVec}; +use digest::generic_array::GenericArray; use ethereum_types::U256; -use generic_array::GenericArray; use jf_signature::{ bls_over_bn254::{BLSOverBN254CurveSignatureScheme, KeyPair, SignKey, VerKey}, SignatureError, SignatureScheme, diff --git a/crates/types/src/traits/qc.rs b/crates/types/src/traits/qc.rs index 439b5bcc89..1f907ed59c 100644 --- a/crates/types/src/traits/qc.rs +++ b/crates/types/src/traits/qc.rs @@ -12,7 +12,7 @@ use ark_std::{ vec::Vec, }; use bitvec::prelude::*; -use generic_array::{ArrayLength, GenericArray}; +use digest::generic_array::{ArrayLength, GenericArray}; use jf_signature::{AggregateableSignatureSchemes, SignatureError}; use serde::{Deserialize, Serialize};