Skip to content

Commit

Permalink
Use workspace inheritance for dependencies (paritytech#974)
Browse files Browse the repository at this point in the history
* use workspace inheritance for package info

* primitives: use workspace inheritance for dependencies

* frame: use workspace inheritance for dependencies

* primitives: adjust codec dep inheritance

* client: use workspace inheritance for dependencies

* frame: use workspace inheritance for dev-dependencies

* adjust toml format

* template: use workspace inheritance for dependencies

* rename codec ==> scale-codec for better format
  • Loading branch information
koushiro authored Jan 12, 2023
1 parent 66b8a0c commit a756c0a
Show file tree
Hide file tree
Showing 51 changed files with 494 additions and 530 deletions.
19 changes: 0 additions & 19 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

107 changes: 107 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,110 @@ resolver = "2"
authors = ["Parity Technologies <admin@parity.io>"]
edition = "2021"
repository = "https://github.com/paritytech/frontier/"

[workspace.dependencies]
bn = { package = "substrate-bn", version = "0.6", default-features = false }
environmental = { version = "1.1.3", default-features = false }
ethereum = { version = "0.14.0", default-features = false }
ethereum-types = { version = "0.14.1", default-features = false }
evm = { version = "0.37.0", default-features = false }
jsonrpsee = "0.16.2"
kvdb-rocksdb = "0.17.0"
libsecp256k1 = "0.7.1"
parity-db = "0.4.2"
rlp = { version = "0.5", default-features = false }
scale-codec = { package = "parity-scale-codec", version = "3.2.1", default-features = false, features = ["derive"] }
scale-info = { version = "2.3.1", default-features = false, features = ["derive"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
# Substrate Client
sc-basic-authorship = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-block-builder = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-cli = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-client-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-client-db = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-consensus = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-consensus-aura = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-consensus-manual-seal = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-executor = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-finality-grandpa = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-keystore = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-network = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-network-common = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-rpc = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-rpc-api = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-service = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-telemetry = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-transaction-pool = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-transaction-pool-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
# Substrate Primitive
sp-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-block-builder = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-blockchain = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-consensus = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-consensus-aura = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-core = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-database = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-finality-grandpa = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-inherents = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-io = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-keyring = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-offchain = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-runtime = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-session = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-std = { version = "5.0.0", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-storage = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-timestamp = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-transaction-pool = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
sp-version = { version = "5.0.0", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
# Substrate FRAME
frame-benchmarking = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
frame-executive = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
frame-support = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
frame-system = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
frame-system-benchmarking = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
frame-system-rpc-runtime-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-aura = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-balances = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-grandpa = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-sudo = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-timestamp = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-transaction-payment = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-transaction-payment-rpc = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
pallet-transaction-payment-rpc-runtime-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
pallet-utility = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
# Substrate Utility
frame-benchmarking-cli = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
prometheus-endpoint = { package = "substrate-prometheus-endpoint", version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
substrate-build-script-utils = { version = "3.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
substrate-frame-rpc-system = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
substrate-test-runtime-client = { version = "2.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
substrate-wasm-builder = { version = "5.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
# Frontier Client
fc-cli = { version = "1.0.0-dev", path = "client/cli" }
fc-consensus = { version = "2.0.0-dev", path = "client/consensus" }
fc-db = { version = "2.0.0-dev", path = "client/db" }
fc-mapping-sync = { version = "2.0.0-dev", path = "client/mapping-sync" }
fc-rpc = { version = "2.0.0-dev", path = "client/rpc" }
fc-rpc-core = { version = "1.1.0-dev", path = "client/rpc-core" }
# Frontier Primitive
fp-consensus = { version = "2.0.0-dev", path = "primitives/consensus", default-features = false }
fp-dynamic-fee = { version = "1.0.0", path = "primitives/dynamic-fee", default-features = false }
fp-ethereum = { version = "1.0.0-dev", path = "primitives/ethereum", default-features = false }
fp-evm = { version = "3.0.0-dev", path = "primitives/evm", default-features = false }
fp-rpc = { version = "3.0.0-dev", path = "primitives/rpc", default-features = false }
fp-self-contained = { version = "1.0.0-dev", path = "primitives/self-contained", default-features = false }
fp-storage = { version = "2.0.0", path = "primitives/storage", default-features = false }
# Frontier FRAME
pallet-base-fee = { version = "1.0.0", path = "frame/base-fee", default-features = false }
pallet-dynamic-fee = { version = "4.0.0-dev", path = "frame/dynamic-fee", default-features = false }
pallet-ethereum = { version = "4.0.0-dev", path = "frame/ethereum", default-features = false }
pallet-evm = { version = "6.0.0-dev", path = "frame/evm", default-features = false }
pallet-evm-chain-id = { version = "1.0.0-dev", path = "frame/evm-chain-id", default-features = false }
pallet-evm-precompile-modexp = { version = "2.0.0-dev", path = "frame/evm/precompile/modexp", default-features = false }
pallet-evm-precompile-sha3fips = { version = "2.0.0-dev", path = "frame/evm/precompile/sha3fips", default-features = false }
pallet-evm-precompile-simple = { version = "2.0.0-dev", path = "frame/evm/precompile/simple", default-features = false }
pallet-evm-test-vector-support = { version = "1.0.0-dev", path = "frame/evm/test-vector-support" }
pallet-hotfix-sufficients = { version = "1.0.0", path = "frame/hotfix-sufficients", default-features = false }
# Frontier Template
frontier-template-runtime = { path = "template/runtime", default-features = false }
40 changes: 17 additions & 23 deletions client/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,28 @@ targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
clap = { version = "4.0", features = ["derive"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"

# Parity
ethereum-types = "0.14.0"

ethereum-types = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
# Substrate
sc-cli = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-service = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-blockchain = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-runtime = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }

sc-cli = { workspace = true }
sp-api = { workspace = true }
sp-blockchain = { workspace = true }
sp-runtime = { workspace = true }
# Frontier
fc-db = { path = "../db" }
fp-rpc = { version = "3.0.0-dev", path = "../../primitives/rpc" }
fp-storage = { version = "2.0.0-dev", path = "../../primitives/storage" }
fc-db = { workspace = true }
fp-rpc = { workspace = true, features = ["std"] }
fp-storage = { workspace = true, features = ["std"] }

[dev-dependencies]
futures = "0.3.21"
scale-codec = { package = "parity-scale-codec", workspace = true }
tempfile = "3.3.0"
# Parity
codec = { package = "parity-scale-codec", version = "3.2.1" }
# Substrate
sc-block-builder = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-client-db = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-consensus = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-io = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
substrate-test-runtime-client = { version = "2.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-block-builder = { workspace = true }
sc-client-db = { workspace = true }
sp-consensus = { workspace = true }
sp-io = { workspace = true }
substrate-test-runtime-client = { workspace = true }
# Frontier
frontier-template-runtime = { path = "../../template/runtime" }
frontier-template-runtime = { workspace = true, features = ["std", "aura", "with-rocksdb-weights"] }
2 changes: 1 addition & 1 deletion client/cli/src/frontier_db_cmd/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@

use std::{collections::HashMap, path::PathBuf, str::FromStr, sync::Arc};

use codec::Encode;
use ethereum_types::H256;
use futures::executor;
use scale_codec::Encode;
use serde::Serialize;
use tempfile::tempdir;
// Substrate
Expand Down
22 changes: 10 additions & 12 deletions client/consensus/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,15 @@ targets = ["x86_64-unknown-linux-gnu"]
[dependencies]
async-trait = "0.1"
thiserror = "1.0"

# Substrate
sc-client-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-consensus = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-api = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-block-builder = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-blockchain = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-consensus = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-runtime = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }

sc-client-api = { workspace = true }
sc-consensus = { workspace = true }
sp-api = { workspace = true }
sp-block-builder = { workspace = true, features = ["std"] }
sp-blockchain = { workspace = true }
sp-consensus = { workspace = true }
sp-runtime = { workspace = true }
# Frontier
fc-db = { version = "2.0.0-dev", path = "../db" }
fp-consensus = { version = "2.0.0-dev", path = "../../primitives/consensus" }
fp-rpc = { version = "3.0.0-dev", path = "../../primitives/rpc" }
fc-db = { workspace = true }
fp-consensus = { workspace = true, features = ["std"] }
fp-rpc = { workspace = true, features = ["std"] }
30 changes: 13 additions & 17 deletions client/db/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,32 +11,28 @@ repository = { workspace = true }
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
kvdb-rocksdb = { workspace = true, optional = true }
log = "0.4.17"
parity-db = { workspace = true, optional = true }
parking_lot = "0.12.1"
scale-codec = { package = "parity-scale-codec", workspace = true }
smallvec = "1.10"

# Parity
codec = { package = "parity-scale-codec", version = "3.2.1", features = ["derive"] }
kvdb-rocksdb = { version = "0.17.0", optional = true }
parity-db = { version = "0.4.2", optional = true }

# Substrate
sc-client-db = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", features = ["rocksdb"] }
sp-blockchain = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-core = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-database = { version = "4.0.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sp-runtime = { version = "7.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }

sc-client-db = { workspace = true, features = ["rocksdb"] }
sp-blockchain = { workspace = true }
sp-core = { workspace = true }
sp-database = { workspace = true }
sp-runtime = { workspace = true }
# Frontier
fp-storage = { version = "2.0.0-dev", path = "../../primitives/storage" }
fp-storage = { workspace = true, features = ["std"] }

[features]
default = ["kvdb-rocksdb", "parity-db"]

[dev-dependencies]
futures = "0.3.25"
sc-block-builder = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
sc-client-db = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master", features = ["rocksdb"] }
sp-consensus = { version = "0.10.0-dev", git = "https://github.com/paritytech/substrate", branch = "master" }
substrate-test-runtime-client = { version = "2.0.0", git = "https://github.com/paritytech/substrate", branch = "master" }
tempfile = "3.3.0"
# Substrate
sc-block-builder = { workspace = true }
sp-consensus = { workspace = true }
substrate-test-runtime-client = { workspace = true }
Loading

0 comments on commit a756c0a

Please sign in to comment.