Skip to content

Commit

Permalink
Avoid duplicate crates (#3293)
Browse files Browse the repository at this point in the history
Co-authored-by: Martin Magnus <martin.beckmann@protonmail.com>
Co-authored-by: ilya <ilya@cow.fi>
  • Loading branch information
3 people authored Mar 4, 2025
1 parent 889ee02 commit a72dcd2
Show file tree
Hide file tree
Showing 20 changed files with 171 additions and 129 deletions.
42 changes: 42 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,48 @@ tracing-subscriber = "0.3.18"
url = "2.5.0"
warp = { git = 'https://github.com/cowprotocol/warp.git', rev = "586244e", default-features = false }
web3 = { version = "0.19.0", default-features = false }
app-data = { path = "crates/app-data" }
arc-swap = "1.7.1"
async-stream = "0.3.5"
atty = "0.2"
autopilot = { path = "crates/autopilot" }
aws-config = "1.5.1"
aws-sdk-s3 = { version = "1.34.0", default-features = false }
bytes-hex = { path = "crates/bytes-hex" }
chain = { path = "crates/chain" }
console-subscriber = "0.3.0"
const_format = "0.2.32"
contracts = { path = "crates/contracts" }
cow-amm = { path = "crates/cow-amm" }
database = { path = "crates/database" }
driver = { path = "crates/driver" }
ethabi = "18.0"
ethrpc = { path = "crates/ethrpc" }
model = { path = "crates/model" }
moka = "0.12.10"
multibase = "0.9"
number = { path = "crates/number" }
observe = { path = "crates/observe" }
order-validation = { path = "crates/order-validation" }
orderbook = { path = "crates/orderbook" }
pin-project-lite = "0.2.14"
rate-limit = { path = "crates/rate-limit" }
refunder = { path = "crates/refunder" }
rust_decimal = "1.35.0"
s3 = { path = "crates/s3" }
scopeguard = "1.2.0"
shared = { path = "crates/shared" }
solver = { path = "crates/solver" }
solvers = { path = "crates/solvers" }
solvers-dto = { path = "crates/solvers-dto" }
strum_macros = "0.26.4"
tap = "1.0.1"
testlib = { path = "crates/testlib" }
time = "0.3.37"
tiny-keccak = "2.0.2"
tower = "0.4"
tower-http = "0.4"
vergen = "8"

[workspace.lints]
clippy.cast_possible_wrap = "deny"
8 changes: 4 additions & 4 deletions crates/alerter/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ license = "MIT OR Apache-2.0"
anyhow = { workspace = true }
clap = { workspace = true }
humantime = { workspace = true }
observe = { path = "../observe" }
observe = { workspace = true }
mimalloc = { workspace = true }
model = { path = "../model" }
number = { path = "../number" }
model = { workspace = true }
number = { workspace = true }
primitive-types = { workspace = true }
prometheus = { workspace = true }
reqwest = { workspace = true, features = ["json"] }
serde_with = { workspace = true }
serde = { workspace = true }
shared = { path = "../shared" }
shared = { workspace = true }
tokio = { workspace = true, features = ["macros", "time", "rt-multi-thread"] }
tracing = { workspace = true }
url = { workspace = true }
Expand Down
4 changes: 2 additions & 2 deletions crates/app-data/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ edition = "2024"
license = "MIT OR Apache-2.0"

[dependencies]
bytes-hex = { path = "../bytes-hex" }
bytes-hex = { workspace = true }
anyhow = { workspace = true }
tiny-keccak = { version = "2.0.2", features = ["keccak"] }
tiny-keccak = { workspace = true, features = ["keccak"] }
serde = { workspace = true }
serde_json = { workspace = true }
serde_with = { workspace = true }
Expand Down
26 changes: 13 additions & 13 deletions crates/autopilot/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,44 +15,44 @@ name = "autopilot"
path = "src/main.rs"

[dependencies]
app-data = { path = "../app-data" }
bytes-hex = { path = "../bytes-hex" }
app-data = { workspace = true }
bytes-hex = { workspace = true }
anyhow = { workspace = true }
async-trait = { workspace = true }
bigdecimal = { workspace = true }
chain = { path = "../chain" }
chain = { workspace = true }
chrono = { workspace = true }
clap = { workspace = true }
contracts = { path = "../contracts" }
cow-amm = { path = "../cow-amm" }
contracts = { workspace = true }
cow-amm = { workspace = true }
dashmap = { workspace = true }
database = { path = "../database" }
database = { workspace = true }
derive_more = { workspace = true }
ethcontract = { workspace = true }
ethrpc = { path = "../ethrpc" }
ethrpc = { workspace = true }
futures = { workspace = true }
observe = { path = "../observe" }
observe = { workspace = true }
hex = { workspace = true }
hex-literal = { workspace = true }
humantime = { workspace = true }
indexmap = { workspace = true }
itertools = { workspace = true }
maplit = { workspace = true }
mimalloc = { workspace = true }
model = { path = "../model" }
model = { workspace = true }
num = { workspace = true }
number = { path = "../number" }
order-validation = { path = "../order-validation" }
number = { workspace = true }
order-validation = { workspace = true }
primitive-types = { workspace = true }
prometheus = { workspace = true }
prometheus-metric-storage = { workspace = true }
rand = { workspace = true }
reqwest = { workspace = true, features = ["gzip", "json"] }
s3 = { path = "../s3" }
s3 = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
serde_with = { workspace = true }
shared = { path = "../shared" }
shared = { workspace = true }
sqlx = { workspace = true }
strum = { workspace = true }
thiserror = { workspace = true }
Expand Down
10 changes: 5 additions & 5 deletions crates/cow-amm/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ edition = "2024"

[dependencies]
anyhow = { workspace = true }
app-data = { path = "../app-data" }
app-data = { workspace = true }
async-trait = { workspace = true }
contracts = { path = "../contracts" }
contracts = { workspace = true }
ethcontract = { workspace = true }
ethrpc = { path = "../ethrpc" }
model = { path = "../model" }
shared = { path = "../shared" }
ethrpc = { workspace = true }
model = { workspace = true }
shared = { workspace = true }
tokio = { workspace = true, features = [] }
tracing = { workspace = true }
hex = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion crates/database/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ license = "MIT OR Apache-2.0"
[dependencies]
bigdecimal = { workspace = true }
chrono = { workspace = true, features = ["clock"] }
const_format = "0.2.32"
const_format = { workspace = true }
futures = { workspace = true }
hex = { workspace = true }
sqlx = { workspace = true }
Expand Down
34 changes: 17 additions & 17 deletions crates/driver/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@ name = "driver"
path = "src/main.rs"

[dependencies]
app-data = { path = "../app-data" }
bytes-hex = { path = "../bytes-hex" }
chain = { path = "../chain" }
s3 = { path = "../s3" }
app-data = { workspace = true }
bytes-hex = { workspace = true }
chain = { workspace = true }
s3 = { workspace = true }
async-trait = { workspace = true }
axum = { workspace = true }
bigdecimal = { workspace = true }
chrono = { workspace = true, features = ["clock"], default-features = false }
cow-amm = { path = "../cow-amm" }
cow-amm = { workspace = true }
dashmap = { workspace = true }
derive_more = { workspace = true }
ethabi = "18.0"
ethabi = { workspace = true }
ethereum-types = { workspace = true }
ethrpc = { path = "../ethrpc" }
ethrpc = { workspace = true }
futures = { workspace = true }
hex = { workspace = true }
hex-literal = { workspace = true }
Expand All @@ -38,9 +38,9 @@ hyper = { workspace = true }
indexmap = { workspace = true, features = ["serde"] }
itertools = { workspace = true }
mimalloc = { workspace = true }
moka = { version = "0.12.10", features = ["future"] }
moka = { workspace = true, features = ["future"] }
num = { workspace = true }
number = { path = "../number" }
number = { workspace = true }
prometheus = { workspace = true }
prometheus-metric-storage = { workspace = true }
rand = { workspace = true }
Expand All @@ -53,8 +53,8 @@ tap = "1.0.1"
thiserror = { workspace = true }
tokio = { workspace = true, features = ["macros", "rt-multi-thread", "signal", "time"] }
toml = { workspace = true }
tower = "0.4"
tower-http = { version = "0.4", features = ["limit", "trace"] }
tower = { workspace = true }
tower-http = { workspace = true, features = ["limit", "trace"] }
url = { workspace = true, features = ["serde"] }
web3 = { workspace = true, features = ["http"] }

Expand All @@ -67,18 +67,18 @@ secp256k1 = { workspace = true }
# dependencies rather than workspace dependencies
anyhow = { workspace = true }
clap = { workspace = true }
contracts = { path = "../contracts" }
contracts = { workspace = true }
ethcontract = { workspace = true }
gas-estimation = { workspace = true }
model = { path = "../model" }
observe = { path = "../observe" }
shared = { path = "../shared" }
solver = { path = "../solver" }
model = { workspace = true }
observe = { workspace = true }
shared = { workspace = true }
solver = { workspace = true }
tracing = { workspace = true }
warp = { workspace = true }

[dev-dependencies]
app-data = { path = "../app-data", features = ["test_helpers"] }
app-data = { workspace = true, features = ["test_helpers"] }
maplit = { workspace = true }
mockall = { workspace = true }
tokio = { workspace = true, features = ["test-util", "process"] }
Expand Down
30 changes: 15 additions & 15 deletions crates/e2e/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,32 +6,32 @@ edition = "2024"
license = "MIT OR Apache-2.0"

[dependencies]
app-data = { path = "../app-data" }
app-data = { workspace = true }
anyhow = { workspace = true }
autopilot = { path = "../autopilot" }
autopilot = { workspace = true }
axum = { workspace = true }
bigdecimal = { workspace = true }
chrono = { workspace = true }
clap = { workspace = true }
contracts = { path = "../contracts" }
database = { path = "../database" }
driver = { path = "../driver" }
contracts = { workspace = true }
database = { workspace = true }
driver = { workspace = true }
ethcontract = { workspace = true }
ethrpc = { path = "../ethrpc" }
ethrpc = { workspace = true }
hex = { workspace = true }
hex-literal = { workspace = true }
model = { path = "../model", features = ["e2e"] }
number = { path = "../number" }
observe = { path = "../observe" }
orderbook = { path = "../orderbook", features = ["e2e"] }
model = { workspace = true, features = ["e2e"] }
number = { workspace = true }
observe = { workspace = true }
orderbook = { workspace = true, features = ["e2e"] }
reqwest = { workspace = true, features = ["blocking"] }
secp256k1 = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
shared = { path = "../shared" }
solver = { path = "../solver" }
solvers = { path = "../solvers" }
solvers-dto = { path = "../solvers-dto" }
shared = { workspace = true }
solver = { workspace = true }
solvers = { workspace = true }
solvers-dto = { workspace = true }
sqlx = { workspace = true }
tempfile = { workspace = true }
tokio = { workspace = true, features = ["macros", "process"] }
Expand All @@ -41,7 +41,7 @@ web3 = { workspace = true, features = ["http"] }

[dev-dependencies]
futures = { workspace = true }
refunder = { path = "../refunder" }
refunder = { workspace = true }

[lints]
workspace = true
8 changes: 4 additions & 4 deletions crates/ethrpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,26 +17,26 @@ futures = { workspace = true }
hex = { workspace = true }
hex-literal = { workspace = true }
mockall = { workspace = true }
observe = { path = "../observe" }
observe = { workspace = true }
primitive-types = { workspace = true }
prometheus = { workspace = true }
prometheus-metric-storage = { workspace = true }
reqwest = { workspace = true, features = ["cookies"] }
scopeguard = "1.2.0"
scopeguard = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
tokio = { workspace = true, features = [] }
tokio-stream = { workspace = true }
web3 = { workspace = true }
contracts = { path = "../contracts" }
contracts = { workspace = true }
ethcontract = { workspace = true }
tracing = { workspace = true }
url = { workspace = true }
itertools = { workspace = true }

[dev-dependencies]
maplit = { workspace = true }
testlib = { path = "../testlib" }
testlib = { workspace = true }

[lints]
workspace = true
8 changes: 4 additions & 4 deletions crates/model/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ doctest = false

[dependencies]
anyhow = { workspace = true }
app-data = { path = "../app-data" }
bytes-hex = { path = "../bytes-hex" }
app-data = { workspace = true }
bytes-hex = { workspace = true }
bigdecimal = { workspace = true }
chrono = { workspace = true, features = ["serde", "clock"] }
derive_more = { workspace = true }
hex = { workspace = true, default-features = false }
hex-literal = { workspace = true }
number = { path = "../number" }
number = { workspace = true }
num = { workspace = true }
primitive-types = { workspace = true }
secp256k1 = { workspace = true }
Expand All @@ -29,7 +29,7 @@ web3 = { workspace = true, features = ["signing"] }
[dev-dependencies]
serde_json = { workspace = true }
maplit = { workspace = true }
testlib = { path = "../testlib" }
testlib = { workspace = true }

[features]
e2e = []
Expand Down
8 changes: 4 additions & 4 deletions crates/observe/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ edition = "2024"
license = "MIT OR Apache-2.0"

[dependencies]
atty = "0.2"
atty = { workspace = true }
async-trait = { workspace = true }
console-subscriber = "0.3.0"
console-subscriber = { workspace = true }
futures = { workspace = true }
pin-project-lite = "0.2.14"
pin-project-lite = { workspace = true }
prometheus = { workspace = true }
prometheus-metric-storage = { workspace = true }
time = { version = "0.3.37", features = ["macros"] }
time = { workspace = true, features = ["macros"] }
tokio = { workspace = true, features = [ "fs" ] }
tracing = { workspace = true }
tracing-subscriber = { workspace = true, features = ["env-filter", "fmt", "time"] }
Expand Down
2 changes: 1 addition & 1 deletion crates/order-validation/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ edition = "2024"
license = "MIT OR Apache-2.0"

[dependencies]
contracts = { path = "../contracts" }
contracts = { workspace = true }
ethcontract = { workspace = true }
thiserror = { workspace = true }
tokio = { workspace = true }
Expand Down
Loading

0 comments on commit a72dcd2

Please sign in to comment.