refactor(substreams): remove workspace dependencies (#129)

This is to make each substreams completely independent, before when we would need a new version of a dependency, we would have to change it for every crate which would lead to a change of every substreams module hash. We want to make every Substreams completely independant and frozen, this also helps to maintain a correct versionning.

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
This commit is contained in:
Zizou
2025-01-07 17:04:17 +01:00
committed by GitHub
parent b8aeaa3dc6
commit 39934347b3
13 changed files with 138 additions and 114 deletions

61
substreams/Cargo.lock generated
View File

@@ -236,7 +236,7 @@ dependencies = [
"prost-types 0.12.6", "prost-types 0.12.6",
"substreams", "substreams",
"substreams-ethereum", "substreams-ethereum",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -257,7 +257,7 @@ dependencies = [
"serde_qs", "serde_qs",
"substreams", "substreams",
"substreams-ethereum", "substreams-ethereum",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -277,7 +277,7 @@ dependencies = [
"regex", "regex",
"substreams", "substreams",
"substreams-ethereum", "substreams-ethereum",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -297,7 +297,7 @@ dependencies = [
"regex", "regex",
"substreams", "substreams",
"substreams-ethereum", "substreams-ethereum",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -343,8 +343,8 @@ dependencies = [
"serde_qs", "serde_qs",
"substreams", "substreams",
"substreams-ethereum", "substreams-ethereum",
"substreams-helper", "substreams-helper 0.0.2 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -362,9 +362,9 @@ dependencies = [
"substreams", "substreams",
"substreams-entity-change", "substreams-entity-change",
"substreams-ethereum", "substreams-ethereum",
"substreams-helper", "substreams-helper 0.0.2 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
"tiny-keccak", "tiny-keccak",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -1141,7 +1141,7 @@ dependencies = [
"substreams", "substreams",
"substreams-ethereum", "substreams-ethereum",
"tiny-keccak", "tiny-keccak",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -1190,9 +1190,9 @@ dependencies = [
"substreams", "substreams",
"substreams-entity-change", "substreams-entity-change",
"substreams-ethereum", "substreams-ethereum",
"substreams-helper", "substreams-helper 0.0.2 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
"tiny-keccak", "tiny-keccak",
"tycho-substreams", "tycho-substreams 0.2.0 (git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3)",
] ]
[[package]] [[package]]
@@ -1217,6 +1217,29 @@ dependencies = [
"tiny-keccak", "tiny-keccak",
] ]
[[package]]
name = "substreams-helper"
version = "0.0.2"
source = "git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3#b8aeaa3dc6e7242a5dd23681921258ef2cb3c6dd"
dependencies = [
"anyhow",
"base64",
"bigdecimal",
"downcast-rs",
"ethabi 18.0.0",
"hex",
"hex-literal 0.4.1",
"num-bigint",
"pad",
"prost 0.11.9",
"prost-types 0.12.6",
"substreams",
"substreams-entity-change",
"substreams-ethereum",
"thiserror",
"tiny-keccak",
]
[[package]] [[package]]
name = "substreams-macro" name = "substreams-macro"
version = "0.5.22" version = "0.5.22"
@@ -1330,6 +1353,22 @@ dependencies = [
"substreams-ethereum", "substreams-ethereum",
] ]
[[package]]
name = "tycho-substreams"
version = "0.2.0"
source = "git+https://github.com/propeller-heads/tycho-protocol-sdk.git?rev=b8aeaa3#b8aeaa3dc6e7242a5dd23681921258ef2cb3c6dd"
dependencies = [
"ethabi 18.0.0",
"hex",
"itertools 0.12.1",
"num-bigint",
"prost 0.11.9",
"serde",
"serde_json",
"substreams",
"substreams-ethereum",
]
[[package]] [[package]]
name = "typenum" name = "typenum"
version = "1.17.0" version = "1.17.0"

View File

@@ -13,21 +13,6 @@ members = [
] ]
resolver = "2" resolver = "2"
[workspace.dependencies]
substreams-ethereum = "0.9.9"
substreams = "0.5.22"
prost = "0.11"
prost-types = "0.12.3"
hex-literal = "0.4.1"
anyhow = "1.0.75"
hex = "0.4.3"
ethabi = "18.0.0"
tycho-substreams = { path = "crates/tycho-substreams" }
substreams-helper = { path = "crates/substreams-helper" }
serde = "1.0.204"
serde_json = "1.0.120"
[profile.release] [profile.release]
lto = true lto = true
opt-level = 's' opt-level = 's'

View File

@@ -8,17 +8,17 @@ homepage = "https://messari.io/"
repository = "https://github.com/messari/substreams/substreams-helper" repository = "https://github.com/messari/substreams/substreams-helper"
[dependencies] [dependencies]
ethabi.workspace = true ethabi = "18.0.0"
hex.workspace = true hex = "0.4.3"
hex-literal.workspace = true hex-literal = "0.4.1"
prost.workspace = true prost = "0.11"
prost-types.workspace = true prost-types = "0.12.3"
num-bigint = "0.4" num-bigint = "0.4"
bigdecimal = "0.3" bigdecimal = "0.3"
pad = "0.1" pad = "0.1"
tiny-keccak = { version = "2.0", features = ["keccak"] } tiny-keccak = { version = "2.0", features = ["keccak"] }
substreams = { workspace = true } substreams = "0.5.22"
substreams-ethereum = { workspace = true } substreams-ethereum = "0.9.9"
thiserror = "1.0.37" thiserror = "1.0.37"
downcast-rs = "1.2.0" downcast-rs = "1.2.0"
substreams-entity-change = "1.1.0" substreams-entity-change = "1.1.0"
@@ -26,4 +26,4 @@ base64 = "0.13.0"
[build-dependencies] [build-dependencies]
anyhow.workspace = true anyhow = "1.0.75"

View File

@@ -4,12 +4,12 @@ version = "0.2.0"
edition = "2021" edition = "2021"
[dependencies] [dependencies]
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
substreams.workspace = true substreams = "0.5.22"
prost.workspace = true prost = "0.11"
hex.workspace = true hex = "0.4.3"
itertools = "0.12.0" itertools = "0.12.0"
ethabi.workspace = true ethabi = "18.0.0"
num-bigint = "0.4.4" num-bigint = "0.4.4"
serde.workspace = true serde = "1.0.204"
serde_json.workspace = true serde_json = "1.0.120"

View File

@@ -8,15 +8,15 @@ name = "substreams_ethereum_ambient"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
hex-literal.workspace = true hex-literal = "0.4.1"
ethabi.workspace = true ethabi = "18.0.0"
hex.workspace = true hex = "0.4.3"
bytes = "1.5.0" bytes = "1.5.0"
anyhow.workspace = true anyhow = "1.0.75"
tiny-keccak = "2.0.2" tiny-keccak = "2.0.2"
num-bigint = { version = "0.4.4", features = [] } num-bigint = { version = "0.4.4", features = [] }
quote = "1.0.33" quote = "1.0.33"

View File

@@ -8,18 +8,18 @@ name = "ethereum_balancer_v2"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
prost-types.workspace = true prost-types = "0.12.3"
hex-literal.workspace = true hex-literal = "0.4.1"
ethabi.workspace = true ethabi = "18.0.0"
hex.workspace = true hex = "0.4.3"
bytes = "1.5.0" bytes = "1.5.0"
anyhow = "1.0.75" anyhow = "1.0.75"
num-bigint = "0.4.4" num-bigint = "0.4.4"
itertools = "0.12.0" itertools = "0.12.0"
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
[build-dependencies] [build-dependencies]
anyhow = "1" anyhow = "1"

View File

@@ -8,17 +8,17 @@ name = "ethereum_curve"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
prost-types.workspace = true prost-types = "0.12.3"
hex-literal.workspace = true hex-literal = "0.4.1"
ethabi.workspace = true ethabi = "18.0.0"
hex.workspace = true hex = "0.4.3"
bytes = "1.5.0" bytes = "1.5.0"
anyhow = "1.0.75" anyhow = "1.0.75"
num-bigint = "0.4.4" num-bigint = "0.4.4"
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
serde = { version = "1.0", features = ["derive"] } serde = { version = "1.0", features = ["derive"] }
serde_qs = "0.13.0" serde_qs = "0.13.0"
itertools = "0.13.0" itertools = "0.13.0"

View File

@@ -9,15 +9,15 @@ crate-type = ["cdylib"]
[dependencies] [dependencies]
ethabi = "17" ethabi = "17"
hex-literal.workspace = true hex-literal = "0.4.1"
num-bigint = "0.4" num-bigint = "0.4"
num-traits = "0.2.15" num-traits = "0.2.15"
prost.workspace = true prost = "0.11"
prost-types = "0.11" prost-types = "0.11"
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
hex.workspace = true hex = "0.4.3"
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
itertools = "0.12.0" itertools = "0.12.0"
anyhow = "1.0.75" anyhow = "1.0.75"

View File

@@ -9,15 +9,15 @@ crate-type = ["cdylib"]
[dependencies] [dependencies]
ethabi = "17" ethabi = "17"
hex-literal.workspace = true hex-literal = "0.4.1"
num-bigint = "0.4" num-bigint = "0.4"
num-traits = "0.2.15" num-traits = "0.2.15"
prost.workspace = true prost = "0.11"
prost-types = "0.11" prost-types = "0.11"
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
hex.workspace = true hex = "0.4.3"
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
itertools = "0.12.0" itertools = "0.12.0"
anyhow = "1.0.75" anyhow = "1.0.75"

View File

@@ -8,7 +8,7 @@ name = "ethereum_template"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }

View File

@@ -8,22 +8,22 @@ name = "ethereum_uniswap_v2"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
ethabi.workspace = true ethabi = "18.0.0"
anyhow = { workspace = true, features = [] } anyhow = "1.0.75"
hex-literal.workspace = true hex-literal = "0.4.1"
substreams-helper.workspace = true substreams-helper = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
num-bigint = "0.4.4" num-bigint = "0.4.4"
itertools = "0.12.1" itertools = "0.12.1"
serde_qs = "0.13.0" serde_qs = "0.13.0"
serde.workspace = true serde = "1.0.204"
[target.wasm32-unknown-unknown.dependencies] [target.wasm32-unknown-unknown.dependencies]
getrandom = { version = "0.2", features = ["custom"] } getrandom = { version = "0.2", features = ["custom"] }
[build-dependencies] [build-dependencies]
anyhow.workspace = true anyhow = "1.0.75"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"

View File

@@ -8,16 +8,16 @@ name = "ethereum_uniswap_v3_logs_only"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
ethabi.workspace = true ethabi = "18.0.0"
anyhow = { workspace = true, features = [] } anyhow = "1.0.75"
hex-literal.workspace = true hex-literal = "0.4.1"
substreams-helper.workspace = true substreams-helper = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
num-bigint = "0.4.4" num-bigint = "0.4.4"
hex.workspace = true hex = "0.4.3"
tiny-keccak = "2.0" tiny-keccak = "2.0"
substreams-entity-change = "1.3" substreams-entity-change = "1.3"
itertools = "0.13.0" itertools = "0.13.0"
@@ -26,5 +26,5 @@ itertools = "0.13.0"
getrandom = { version = "0.2", features = ["custom"] } getrandom = { version = "0.2", features = ["custom"] }
[build-dependencies] [build-dependencies]
anyhow.workspace = true anyhow = "1.0.75"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"

View File

@@ -8,16 +8,16 @@ name = "substreams_ethereum_uniswap_v3"
crate-type = ["cdylib"] crate-type = ["cdylib"]
[dependencies] [dependencies]
substreams.workspace = true substreams = "0.5.22"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"
prost.workspace = true prost = "0.11"
ethabi.workspace = true ethabi = "18.0.0"
anyhow = { workspace = true, features = [] } anyhow = "1.0.75"
hex-literal.workspace = true hex-literal = "0.4.1"
substreams-helper.workspace = true substreams-helper = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
tycho-substreams.workspace = true tycho-substreams = { git = "https://github.com/propeller-heads/tycho-protocol-sdk.git", rev = "b8aeaa3" }
num-bigint = "0.4.4" num-bigint = "0.4.4"
hex.workspace = true hex = "0.4.3"
tiny-keccak = "2.0" tiny-keccak = "2.0"
substreams-entity-change = "1.3" substreams-entity-change = "1.3"
@@ -25,5 +25,5 @@ substreams-entity-change = "1.3"
getrandom = { version = "0.2", features = ["custom"] } getrandom = { version = "0.2", features = ["custom"] }
[build-dependencies] [build-dependencies]
anyhow.workspace = true anyhow = "1.0.75"
substreams-ethereum.workspace = true substreams-ethereum = "0.9.9"