Skip to content

Commit

Permalink
Remove unused dependecies (#523)
Browse files Browse the repository at this point in the history
* Fix docs warnings
  • Loading branch information
citizen-stig authored and preston-evans98 committed Sep 14, 2023
1 parent 32afabd commit 06f3579
Show file tree
Hide file tree
Showing 22 changed files with 31 additions and 62 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ jobs:
- name: cargo hack
run: make check-features
test:
runs-on: ubuntu-latest
runs-on:
group: 8-cores_32GB_Ubuntu Group
timeout-minutes: 60
env:
SCCACHE_GHA_ENABLED: "true"
Expand Down
5 changes: 1 addition & 4 deletions adapters/celestia/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@ base64 = "0.13.1"
hex = { version = "0.4.3", features = ["serde"] }
hex-literal = "0.3.4"
jsonrpsee = { version = "0.16.2", features = ["http-client"], optional = true }
reqwest = { version = "0.11.13", features = ["blocking"], optional = true }
serde = { workspace = true }
serde_cbor = "0.11.2"
serde_json = { workspace = true }
tokio = { workspace = true, optional = true }
thiserror = { workspace = true }
Expand All @@ -40,8 +38,7 @@ wiremock = "0.5"
[build-dependencies]
prost-build = { version = "0.11" }


[features]
default = ["native"]
native = ["dep:tokio", "dep:reqwest", "dep:jsonrpsee"]
native = ["dep:tokio", "dep:jsonrpsee"]
verifier = []
2 changes: 1 addition & 1 deletion adapters/celestia/src/share_commit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ impl std::fmt::Display for CommitmentError {

impl std::error::Error for CommitmentError {}

/// Derived from https://github.com/celestiaorg/celestia-app/blob/0c81704939cd743937aac2859f3cb5ae6368f174/x/payment/types/payfordata.go#L170
/// Derived from <https://github.com/celestiaorg/celestia-app/blob/0c81704939cd743937aac2859f3cb5ae6368f174/x/payment/types/payfordata.go#L170>
pub fn recreate_commitment(
square_size: usize,
shares: shares::BlobRef,
Expand Down
1 change: 0 additions & 1 deletion examples/demo-simple-stf/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ publish = false
[dependencies]
anyhow = { workspace = true}
serde = { workspace = true }
serde_json = { workspace = true, optional = true }
sha2 = { workspace = true }

sov-rollup-interface = { path = "../../rollup-interface" }
Expand Down
9 changes: 2 additions & 7 deletions examples/demo-stf/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ anyhow = { workspace = true }
borsh = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true, optional = true }
sha2 = { workspace = true }
clap = { workspace = true, optional = true }
toml = { workspace = true, optional = true }
jsonrpsee = { workspace = true, features = ["http-client", "server"], optional = true }
tokio = { workspace = true, optional = true }
hex = { workspace = true }
tracing = { workspace = true }

const-rollup-config = { path = "../const-rollup-config" }
sov-rollup-interface = { path = "../../rollup-interface" }
sov-election = { path = "../../module-system/module-implementations/examples/sov-election", default-features = false }
sov-sequencer-registry = { path = "../../module-system/module-implementations/sov-sequencer-registry", default-features = false }
Expand All @@ -37,10 +37,7 @@ sov-accounts = { path = "../../module-system/module-implementations/sov-accounts
sov-state = { path = "../../module-system/sov-state", default-features = false }
sov-modules-api = { path = "../../module-system/sov-modules-api", default-features = false }
sov-modules-macros = { path = "../../module-system/sov-modules-macros" }
# Only enable the db on "native" feature
sov-schema-db = { path = "../../full-node/db/sov-schema-db", optional = true }
sov-db = { path = "../../full-node/db/sov-db", optional = true }
const-rollup-config = { path = "../const-rollup-config" }
# Only enable the sequencer on "native" feature
sov-sequencer = { path = "../../full-node/sov-sequencer", optional = true }

# Only enable the evm on "experimental" feature
Expand All @@ -57,8 +54,6 @@ experimental =["sov-evm/experimental"]


native = [
"dep:sov-db",
"dep:sov-schema-db",
"sov-bank/native",
"sov-accounts/native",
"sov-election/native",
Expand Down
3 changes: 0 additions & 3 deletions full-node/sov-ethereum/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,7 @@ resolver = "2"


[dependencies]
anyhow = { workspace = true }
jsonrpsee = { workspace = true, features = ["http-client", "server"] }
serde = { workspace = true, features = ["derive"] }
sov-rollup-interface = { path = "../../rollup-interface" }

sov-evm = { path = "../../module-system/module-implementations/sov-evm", default-features = false }
demo-stf = { path = "../../examples/demo-stf", features = ["native"] }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "sov-election"
description = "A Sovereign SDK module for incentivizing provers"
description = "A Sovereign SDK module for demonstrating election"
authors = { workspace = true }
edition = { workspace = true }
homepage = { workspace = true }
Expand All @@ -14,22 +14,20 @@ publish = false

[dependencies]
anyhow = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }
serde = { workspace = true, optional = true }

sov-modules-api = { path = "../../../sov-modules-api", default-features = false }
sov-modules-macros = { path = "../../../sov-modules-macros" }
sov-state = { path = "../../../sov-state", default-features = false }
sov-rollup-interface = { path = "../../../../rollup-interface" }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
hex = { workspace = true }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }


[dev-dependencies]
sov-modules-api = { path = "../../../sov-modules-api" }
tempfile = { workspace = true }

[features]
default = ["native"]
serde = ["dep:serde", "dep:serde_json"]
serde = ["dep:serde"]
native = ["serde", "sov-modules-api/native", "dep:jsonrpsee"]
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "sov-value-setter"
description = "A Sovereign SDK module for incentivizing provers"
description = "A Sovereign SDK example module for setting/reading value from state"
authors = { workspace = true }
edition = { workspace = true }
homepage = { workspace = true }
Expand All @@ -23,12 +23,11 @@ sov-modules-macros = { path = "../../../sov-modules-macros" }
sov-state = { path = "../../../sov-state", default-features = false }
sov-rollup-interface = { path = "../../../../rollup-interface" }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }

[features]
default = ["native"]
serde = ["dep:serde", "dep:serde_json"]
serde = ["dep:serde"]
native = ["serde", "sov-modules-api/native", "dep:jsonrpsee"]
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,11 @@ publish = false
[dev-dependencies]
anyhow = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
serde_json = { workspace = true }
serial_test = "*"
tempfile = { workspace = true }

sov-modules-api = { path = "../../sov-modules-api" }
sov-modules-macros = { path = "../../sov-modules-macros" }
sov-state = { path = "../../sov-state" }
sov-rollup-interface = { path = "../../../rollup-interface" }
sov-schema-db = { path = "../../../full-node/db/sov-schema-db" }
tempfile = { workspace = true }

Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ sov-modules-macros = { path = "../../sov-modules-macros" }
sov-state = { path = "../../sov-state", default-features = false }
sov-rollup-interface = { path = "../../../rollup-interface" }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }

Expand All @@ -30,5 +29,5 @@ tempfile = { workspace = true }

[features]
default = ["native"]
serde = ["dep:serde", "dep:serde_json"]
serde = ["dep:serde"]
native = ["serde", "sov-modules-api/native"]
3 changes: 0 additions & 3 deletions module-system/module-implementations/sov-accounts/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,13 @@ resolver = "2"
[dependencies]
anyhow = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
hex = { workspace = true }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }

sov-modules-api = { path = "../../sov-modules-api", version = "0.1", default-features = false }
sov-modules-macros = { path = "../../sov-modules-macros", version = "0.1" }
sov-state = { path = "../../sov-state", version = "0.1", default-features = false }
sov-rollup-interface = { path = "../../../rollup-interface", version = "0.1" }


[dev-dependencies]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ fn test_update_account_fails() {
}

#[test]
fn test_get_acc_after_pub_key_update() {
fn test_get_account_after_pub_key_update() {
let tmpdir = tempfile::tempdir().unwrap();
let native_working_set = &mut WorkingSet::new(ProverStorage::with_path(tmpdir.path()).unwrap());
let accounts = &mut Accounts::<C>::default();
Expand Down
14 changes: 7 additions & 7 deletions module-system/module-implementations/sov-bank/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,17 @@ resolver = "2"

[dependencies]
anyhow = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }
schemars = { workspace = true, optional = true }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }

sov-modules-api = { path = "../../sov-modules-api", version = "0.1", default-features = false }
sov-modules-macros = { path = "../../sov-modules-macros", version = "0.1" }
sov-state = { path = "../../sov-state", version = "0.1", default-features = false }
sov-rollup-interface = { path = "../../../rollup-interface", version = "0.1" }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
hex = { workspace = true }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }



[dev-dependencies]
sov-modules-api = { path = "../../sov-modules-api", version = "0.1" }
Expand Down
2 changes: 0 additions & 2 deletions module-system/module-implementations/sov-evm/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,11 @@ revm = "3.3.0"
sov-modules-api = { path = "../../sov-modules-api", version = "0.1", default-features = false }
sov-modules-macros = { path = "../../sov-modules-macros", version = "0.1" }
sov-state = { path = "../../sov-state", version = "0.1", default-features = false }
sov-rollup-interface = { path = "../../../rollup-interface", version = "0.1" }

anyhow = { workspace = true }
bytes = { workspace = true }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
hex = { workspace = true }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ sov-modules-macros = { path = "../../sov-modules-macros", version = "0.1" }
sov-state = { path = "../../sov-state", version = "0.1", default-features = false }
sov-rollup-interface = { path = "../../../rollup-interface", version = "0.1" }
serde = { workspace = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
# TODO: Replace with serde-compatible borsh implementation when it becomes availabile
# see https://github.com/Sovereign-Labs/sovereign-sdk/issues/215
Expand All @@ -34,5 +32,4 @@ bincode = "1.3.3"

[features]
default = ["native"]
serde = ["dep:serde_json"]
native = ["serde", "sov-modules-api/native"]
native = ["sov-modules-api/native"]
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,10 @@ sov-modules-macros = { path = "../../sov-modules-macros", version = "0.1" }
sov-state = { path = "../../sov-state", version = "0.1", default-features = false }
sov-rollup-interface = { path = "../../../rollup-interface", version = "0.1" }
serde = { workspace = true, optional = true }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
borsh = { workspace = true, features = ["rc"] }
hex = { workspace = true }
jsonrpsee = { workspace = true, features = ["macros", "client-core", "server"], optional = true }

[features]
default = ["native"]
serde = ["dep:serde", "dep:serde_json"]
serde = ["dep:serde"]
native = ["serde", "sov-modules-api/native", "sov-state/native", "sov-bank/native", "dep:jsonrpsee"]
1 change: 0 additions & 1 deletion module-system/sov-modules-api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ sov-rollup-interface = { path = "../../rollup-interface", version = "0.1" }
serde = { workspace = true }
borsh = { workspace = true }
thiserror = { workspace = true }
jmt = { workspace = true }
sha2 = { workspace = true }
bech32 = { workspace = true }
derive_more = { workspace = true }
Expand Down
2 changes: 0 additions & 2 deletions module-system/sov-modules-macros/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ path = "tests/all_tests.rs"
[dev-dependencies]
serde_json = "1"
jsonrpsee = { workspace = true, features = ["macros", "http-client", "server"] }
tempfile = { workspace = true }
trybuild = "1.0"

sov-modules-api = { path = "../sov-modules-api", version = "0.1", default-features = false }
Expand All @@ -39,4 +38,3 @@ schemars = { workspace = true }
syn = { version = "1.0", features = ["full"] }

sov-modules-api = { path = "../sov-modules-api", version = "0.1", default-features = false }
sov-rollup-interface = { path = "../../rollup-interface", version = "0.1" }
1 change: 0 additions & 1 deletion module-system/sov-state/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ sov-first-read-last-write-cache = { path = "../utils/sov-first-read-last-write-c
jmt = { workspace = true }
hex = { workspace = true }
sha2 = { workspace = true }
tracing = { workspace = true }

[dev-dependencies]
tempfile = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion rollup-interface/src/node/services/stf_runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ use crate::zk::Zkvm;
///
/// and a `impl StateTransitionRunner<ZkConfig, Vm> for MyRunner` which instead uses a state root as its runtime config.
///
/// TODO: Why is it called runner? It only creates. Creator, Factory: https://github.com/Sovereign-Labs/sovereign-sdk/issues/447
/// TODO: Why is it called runner? It only creates. Creator, Factory: <https://github.com/Sovereign-Labs/sovereign-sdk/issues/447>
pub trait StateTransitionRunner<T: StateTransitionConfig, Vm: Zkvm, B: BlobTransactionTrait> {
/// The parameters of the state transition function which are set at runtime. For example,
/// the runtime config might contain path to a data directory.
Expand Down
2 changes: 1 addition & 1 deletion rollup-interface/src/state_machine/crypto/simple_hasher.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pub use jmt::SimpleHasher;

/// A SimpleHasher implementation which always returns the digest [0;32]
/// A SimpleHasher implementation which always returns the digest `[0;32]`
pub struct NoOpHasher;

impl SimpleHasher for NoOpHasher {
Expand Down
2 changes: 1 addition & 1 deletion rollup-interface/src/state_machine/da.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ impl<B: Buf> CountedBufReader<B> {
}

/// Getter: returns a reference to an accumulator of the blob data read by the rollup
/// TODO: Refactor https://github.com/Sovereign-Labs/sovereign-sdk/issues/462
/// TODO: Refactor <https://github.com/Sovereign-Labs/sovereign-sdk/issues/462>
pub fn acc(&self) -> &Vec<u8> {
&self.reading_acc
}
Expand Down

0 comments on commit 06f3579

Please sign in to comment.