Implement helpers for relative balances.

Adds some helpers that will users help to convert relative balances changes to absolute ones.

The goal is to make this as reduce the effort of the user to  implementing a simple map handler that extracts relative balances changes.
This commit is contained in:
kayibal
2024-03-13 18:46:10 +00:00
parent 92f20d0521
commit 3d248f3fa1
9 changed files with 632 additions and 129 deletions

View File

@@ -333,6 +333,15 @@ dependencies = [
"either",
]
[[package]]
name = "itertools"
version = "0.12.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569"
dependencies = [
"either",
]
[[package]]
name = "itoa"
version = "1.0.10"
@@ -530,7 +539,7 @@ checksum = "119533552c9a7ffacc21e099c24a0ac8bb19c2a2a3f363de84cd9b844feab270"
dependencies = [
"bytes",
"heck",
"itertools",
"itertools 0.10.5",
"lazy_static",
"log",
"multimap",
@@ -551,7 +560,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4"
dependencies = [
"anyhow",
"itertools",
"itertools 0.10.5",
"proc-macro2",
"quote",
"syn 1.0.109",
@@ -908,6 +917,10 @@ dependencies = [
name = "tycho-substreams"
version = "0.1.0"
dependencies = [
"hex",
"itertools 0.12.1",
"prost",
"substreams",
"substreams-ethereum",
]