diff --git a/consensus/Cargo.toml b/consensus/Cargo.toml index 89d1f2ed0e..2b486ef7de 100644 --- a/consensus/Cargo.toml +++ b/consensus/Cargo.toml @@ -49,7 +49,7 @@ nimiq-primitives = { workspace = true, features = ["policy", "trie"] } nimiq-serde = { workspace = true } nimiq-time = { workspace = true } nimiq-transaction = { workspace = true } -nimiq-utils = { workspace = true, features = ["merkle", "spawn", "time"] } +nimiq-utils = { workspace = true, features = ["futures", "merkle", "spawn", "time"] } nimiq-zkp-component = { workspace = true } [dev-dependencies] diff --git a/handel/Cargo.toml b/handel/Cargo.toml index d3c031da75..f7ed528ca4 100644 --- a/handel/Cargo.toml +++ b/handel/Cargo.toml @@ -28,7 +28,7 @@ nimiq-collections = { workspace = true } nimiq-hash = { workspace = true } nimiq-serde = { workspace = true } nimiq-time = { workspace = true } -nimiq-utils = { workspace = true } +nimiq-utils = { workspace = true, features = ["futures"] } [dev-dependencies] nimiq-network-interface = { workspace = true } diff --git a/tendermint/Cargo.toml b/tendermint/Cargo.toml index 24efa59d44..397de0c513 100644 --- a/tendermint/Cargo.toml +++ b/tendermint/Cargo.toml @@ -26,7 +26,7 @@ tokio = { version = "1.39", features = [ tokio-stream = "0.1" nimiq-collections = { workspace = true } -nimiq-utils = { workspace = true } +nimiq-utils = { workspace = true, features = ["futures"] } nimiq-time = { workspace = true } [dev-dependencies] diff --git a/utils/Cargo.toml b/utils/Cargo.toml index 3feb3d6c20..04e20c4023 100644 --- a/utils/Cargo.toml +++ b/utils/Cargo.toml @@ -21,7 +21,7 @@ workspace = true [dependencies] clear_on_drop = { version = "0.2", optional = true } -futures = { workspace = true } +futures = { workspace = true, optional = true } hex = { version = "0.4", optional = true } libp2p-identity = { version = "0.2", optional = true } log = { workspace = true, optional = true } @@ -51,6 +51,7 @@ nimiq-test-utils = { workspace = true } [features] crc = [] +futures = ["dep:futures"] key-rng = ["rand", "rand_core"] key-store = ["log", "thiserror"] libp2p = ["libp2p-identity"] diff --git a/utils/src/lib.rs b/utils/src/lib.rs index c405e56136..f4c3f341de 100644 --- a/utils/src/lib.rs +++ b/utils/src/lib.rs @@ -18,6 +18,7 @@ pub mod tagged_signing; #[cfg(feature = "time")] pub mod time; +#[cfg(feature = "futures")] pub mod stream; mod sensitive; diff --git a/validator-network/Cargo.toml b/validator-network/Cargo.toml index 1e2f6f53c9..65c6955e3c 100644 --- a/validator-network/Cargo.toml +++ b/validator-network/Cargo.toml @@ -32,4 +32,4 @@ tokio = { version = "1.39", features = ["rt"] } nimiq-bls = { workspace = true, features = ["lazy", "serde-derive"] } nimiq-network-interface = { workspace = true } nimiq-serde = { workspace = true } -nimiq-utils = { workspace = true, features = ["spawn", "tagged-signing"] } +nimiq-utils = { workspace = true, features = ["futures", "spawn", "tagged-signing"] } diff --git a/validator/Cargo.toml b/validator/Cargo.toml index 6b197e2664..2dd91104de 100644 --- a/validator/Cargo.toml +++ b/validator/Cargo.toml @@ -54,7 +54,7 @@ nimiq-serde = { workspace = true } nimiq-tendermint = { workspace = true } nimiq-time = { workspace = true } nimiq-transaction-builder = { workspace = true } -nimiq-utils = { workspace = true, features = ["time"] } +nimiq-utils = { workspace = true, features = ["futures", "time"] } nimiq-validator-network = { workspace = true } nimiq-vrf = { workspace = true } diff --git a/zkp-component/Cargo.toml b/zkp-component/Cargo.toml index 123ce2dbe0..b777291a76 100644 --- a/zkp-component/Cargo.toml +++ b/zkp-component/Cargo.toml @@ -55,7 +55,7 @@ nimiq-network-interface = { workspace = true } nimiq-primitives = { workspace = true, features = ["policy"] } nimiq-serde = { workspace = true } nimiq-transaction = { workspace = true } -nimiq-utils = { workspace = true, features = ["merkle", "spawn", "time"] } +nimiq-utils = { workspace = true, features = ["futures", "merkle", "spawn", "time"] } nimiq-zkp = { workspace = true } nimiq-zkp-circuits = { workspace = true } nimiq-zkp-primitives = { workspace = true }