diff --git a/CHANGELOG.md b/CHANGELOG.md index 6446bf8c32..cbc127d984 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Next release +- feat: unification of the DA interface - feat: use resolver 2 for cargo in the workspace - upgrade: restructure code for rust latest version - upgrade: bump rustc nightly version to 1.74 date diff --git a/Cargo.lock b/Cargo.lock index fc3640da17..96034a0c2f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -185,6 +185,17 @@ version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" +[[package]] +name = "alloy-rlp" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f938f00332d63a5b0ac687bd6f46d03884638948921d9f8b50c59563d421ae25" +dependencies = [ + "arrayvec 0.7.4", + "bytes", + "smol_str", +] + [[package]] name = "android-tzdata" version = "0.1.1" @@ -284,10 +295,10 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "defd9a439d56ac24968cca0571f598a61bc8c55f71d50a89cda591cb750670ba" dependencies = [ - "ark-ff", + "ark-ff 0.4.2", "ark-poly", - "ark-serialize", - "ark-std", + "ark-serialize 0.4.2", + "ark-std 0.4.0", "derivative", "hashbrown 0.13.2", "itertools", @@ -295,26 +306,54 @@ dependencies = [ "zeroize", ] +[[package]] +name = "ark-ff" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b3235cc41ee7a12aaaf2c575a2ad7b46713a8a50bda2fc3b003a04845c05dd6" +dependencies = [ + "ark-ff-asm 0.3.0", + "ark-ff-macros 0.3.0", + "ark-serialize 0.3.0", + "ark-std 0.3.0", + "derivative", + "num-bigint", + "num-traits 0.2.16", + "paste", + "rustc_version 0.3.3", + "zeroize", +] + [[package]] name = "ark-ff" version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" dependencies = [ - "ark-ff-asm", - "ark-ff-macros", - "ark-serialize", - "ark-std", + "ark-ff-asm 0.4.2", + "ark-ff-macros 0.4.2", + "ark-serialize 0.4.2", + "ark-std 0.4.0", "derivative", "digest 0.10.7", "itertools", "num-bigint", "num-traits 0.2.16", "paste", - "rustc_version", + "rustc_version 0.4.0", "zeroize", ] +[[package]] +name = "ark-ff-asm" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44" +dependencies = [ + "quote", + "syn 1.0.109", +] + [[package]] name = "ark-ff-asm" version = "0.4.2" @@ -325,6 +364,18 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "ark-ff-macros" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20" +dependencies = [ + "num-bigint", + "num-traits 0.2.16", + "quote", + "syn 1.0.109", +] + [[package]] name = "ark-ff-macros" version = "0.4.2" @@ -344,9 +395,9 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d320bfc44ee185d899ccbadfa8bc31aab923ce1558716e1997a1e74057fe86bf" dependencies = [ - "ark-ff", - "ark-serialize", - "ark-std", + "ark-ff 0.4.2", + "ark-serialize 0.4.2", + "ark-std 0.4.0", "derivative", "hashbrown 0.13.2", ] @@ -358,8 +409,18 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4c02e954eaeb4ddb29613fee20840c2bbc85ca4396d53e33837e11905363c5f2" dependencies = [ "ark-ec", - "ark-ff", - "ark-std", + "ark-ff 0.4.2", + "ark-std 0.4.0", +] + +[[package]] +name = "ark-serialize" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d6c2b318ee6e10f8c2853e73a83adc0ccb88995aa978d8a3408d492ab2ee671" +dependencies = [ + "ark-std 0.3.0", + "digest 0.9.0", ] [[package]] @@ -369,7 +430,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" dependencies = [ "ark-serialize-derive", - "ark-std", + "ark-std 0.4.0", "digest 0.10.7", "num-bigint", ] @@ -385,6 +446,16 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "ark-std" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" +dependencies = [ + "num-traits 0.2.16", + "rand 0.8.5", +] + [[package]] name = "ark-std" version = "0.4.0" @@ -407,6 +478,15 @@ version = "6.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9b1c5a481ec30a5abd8dfbd94ab5cf1bb4e9a66be7f1b3b322f2f1170c200fd" +[[package]] +name = "array-init" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23589ecb866b460d3a0f1278834750268c607e8e28a1b982c907219f3178cd72" +dependencies = [ + "nodrop", +] + [[package]] name = "arrayref" version = "0.3.7" @@ -569,6 +649,17 @@ dependencies = [ "syn 2.0.28", ] +[[package]] +name = "async_io_stream" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6d7b9decdf35d8908a7e3ef02f64c5e9b1695e230154c0e8de3969142d9b94c" +dependencies = [ + "futures", + "pharos", + "rustc_version 0.4.0", +] + [[package]] name = "asynchronous-codec" version = "0.6.1" @@ -579,7 +670,7 @@ dependencies = [ "futures-sink", "futures-util", "memchr", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", ] [[package]] @@ -599,12 +690,47 @@ dependencies = [ "winapi", ] +[[package]] +name = "auto_impl" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fee3da8ef1276b0bee5dd1c7258010d8fffd31801447323115a25560e1327b89" +dependencies = [ + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "autocfg" version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +[[package]] +name = "avail-subxt" +version = "0.3.0" +source = "git+https://github.com/availproject/avail?branch=develop#5c739ef8d26e9ee9e98c9aa91cede4bff226f208" +dependencies = [ + "anyhow", + "curve25519-dalek 2.1.3", + "derive_more", + "futures", + "hex", + "jsonrpsee 0.16.3", + "num_enum 0.5.11", + "parity-scale-codec", + "scale-info", + "schnorrkel", + "serde", + "serde-hex", + "sp-core 21.0.0", + "structopt", + "subxt", + "tokio", +] + [[package]] name = "backtrace" version = "0.3.68" @@ -638,6 +764,12 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" +[[package]] +name = "base58" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6107fe1be6682a68940da878d9e9f5e90ca5745b3dec9fd1bb393c8777d4f581" + [[package]] name = "base64" version = "0.13.1" @@ -656,6 +788,12 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + [[package]] name = "beef" version = "0.5.2" @@ -867,7 +1005,7 @@ name = "blockifier" version = "0.1.0-rc2" source = "git+https://github.com/keep-starknet-strange/blockifier?branch=no_std-support-7578442#1042c076ce2b669cad9a20aad2e727b3a94713ac" dependencies = [ - "ark-ff", + "ark-ff 0.4.2", "ark-secp256k1", "cached", "cairo-felt", @@ -896,8 +1034,8 @@ dependencies = [ "spin 0.9.8", "starknet-crypto 0.5.1", "starknet_api", - "strum", - "strum_macros", + "strum 0.24.1", + "strum_macros 0.24.3", "thiserror-no-std", ] @@ -919,6 +1057,16 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" +[[package]] +name = "bs58" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f5353f36341f7451062466f0b755b96ac3a9547e4d7f6b70d603fc721a7d7896" +dependencies = [ + "sha2 0.10.7", + "tinyvec", +] + [[package]] name = "bstr" version = "1.6.0" @@ -973,6 +1121,19 @@ name = "bytes" version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" +dependencies = [ + "serde", +] + +[[package]] +name = "bzip2" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bdb116a6ef3f6c3698828873ad02c3014b3c85cadb88496095628e3ef1e347f8" +dependencies = [ + "bzip2-sys", + "libc", +] [[package]] name = "bzip2-sys" @@ -1242,7 +1403,7 @@ source = "git+https://github.com/keep-starknet-strange/cairo.git?branch=no_std-s dependencies = [ "cairo-lang-utils", "const-fnv1a-hash", - "convert_case", + "convert_case 0.6.0", "derivative", "itertools", "lalrpop", @@ -1363,7 +1524,7 @@ dependencies = [ "cairo-lang-sierra-to-casm", "cairo-lang-syntax", "cairo-lang-utils", - "convert_case", + "convert_case 0.6.0", "genco", "indent", "indoc", @@ -1426,8 +1587,8 @@ name = "cairo-lang-vm-utils" version = "2.1.0" source = "git+https://github.com/keep-starknet-strange/cairo.git?branch=no_std-support-8bbf530#0e591510d73be8d737b0832dc9215ff409e0ed15" dependencies = [ - "ark-ff", - "ark-std", + "ark-ff 0.4.2", + "ark-std 0.4.0", "cairo-felt", "cairo-lang-casm", "cairo-lang-utils", @@ -1452,8 +1613,8 @@ version = "0.8.5" source = "git+https://github.com/keep-starknet-strange/cairo-rs?branch=no_std-support-21eff70#b68cc5fb723bc68ed65b16656bdb7bffb92d3b9a" dependencies = [ "anyhow", - "ark-ff", - "ark-std", + "ark-ff 0.4.2", + "ark-std 0.4.0", "bincode 2.0.0-rc.3", "bitvec", "cairo-felt", @@ -1512,6 +1673,20 @@ dependencies = [ "thiserror", ] +[[package]] +name = "cargo_metadata" +version = "0.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7daec1a2a2129eeba1644b220b4647ec537b0b5d4bfd6876fcc5a540056b592" +dependencies = [ + "camino", + "cargo-platform", + "semver 1.0.18", + "serde", + "serde_json", + "thiserror", +] + [[package]] name = "cc" version = "1.0.79" @@ -1532,6 +1707,55 @@ dependencies = [ "subtle", ] +[[package]] +name = "celestia-proto" +version = "0.1.0" +source = "git+https://github.com/eigerco/celestia-node-rs#aa810b7ce74aef6c6a6ec190099ba4415da094ee" +dependencies = [ + "anyhow", + "prost 0.12.0", + "prost-build 0.12.0", + "prost-types 0.12.0", + "serde", + "tendermint-proto", +] + +[[package]] +name = "celestia-rpc" +version = "0.1.0" +source = "git+https://github.com/eigerco/celestia-node-rs#aa810b7ce74aef6c6a6ec190099ba4415da094ee" +dependencies = [ + "celestia-types", + "http", + "jsonrpsee 0.20.0", + "serde", + "thiserror", +] + +[[package]] +name = "celestia-types" +version = "0.1.0" +source = "git+https://github.com/eigerco/celestia-node-rs#aa810b7ce74aef6c6a6ec190099ba4415da094ee" +dependencies = [ + "base64 0.21.2", + "bech32", + "bytes", + "celestia-proto", + "cid 0.10.1", + "const_format", + "enum_dispatch", + "libp2p-identity 0.2.3", + "multiaddr 0.18.0", + "nmt-rs", + "ruint", + "serde", + "serde_repr", + "sha2 0.10.7", + "tendermint", + "tendermint-proto", + "thiserror", +] + [[package]] name = "cexpr" version = "0.6.0" @@ -1547,7 +1771,7 @@ version = "0.15.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "215c0072ecc28f92eeb0eea38ba63ddfcb65c2828c46311d646f1a3ff5f9841c" dependencies = [ - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -1616,6 +1840,19 @@ dependencies = [ "unsigned-varint", ] +[[package]] +name = "cid" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd94671561e36e4e7de75f753f577edafb0e7c05d6e4547229fdf7938fbcd2c3" +dependencies = [ + "core2", + "multibase", + "multihash 0.18.1", + "serde", + "unsigned-varint", +] + [[package]] name = "cipher" version = "0.2.5" @@ -1664,6 +1901,21 @@ dependencies = [ "libloading", ] +[[package]] +name = "clap" +version = "2.34.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c" +dependencies = [ + "ansi_term", + "atty", + "bitflags 1.3.2", + "strsim 0.8.0", + "textwrap", + "unicode-width", + "vec_map", +] + [[package]] name = "clap" version = "4.4.2" @@ -1683,7 +1935,7 @@ dependencies = [ "anstream", "anstyle", "clap_lex", - "strsim", + "strsim 0.10.0", ] [[package]] @@ -1714,6 +1966,58 @@ dependencies = [ "unicode-width", ] +[[package]] +name = "coins-bip32" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b6be4a5df2098cd811f3194f64ddb96c267606bffd9689ac7b0160097b01ad3" +dependencies = [ + "bs58 0.5.0", + "coins-core", + "digest 0.10.7", + "hmac 0.12.1", + "k256", + "serde", + "sha2 0.10.7", + "thiserror", +] + +[[package]] +name = "coins-bip39" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3db8fba409ce3dc04f7d804074039eb68b960b0829161f8e06c95fea3f122528" +dependencies = [ + "bitvec", + "coins-bip32", + "hmac 0.12.1", + "once_cell", + "pbkdf2 0.12.2", + "rand 0.8.5", + "sha2 0.10.7", + "thiserror", +] + +[[package]] +name = "coins-core" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5286a0843c21f8367f7be734f89df9b822e0321d8bcce8d6e735aadff7d74979" +dependencies = [ + "base64 0.21.2", + "bech32", + "bs58 0.5.0", + "digest 0.10.7", + "generic-array 0.14.7", + "hex", + "ripemd", + "serde", + "serde_derive", + "sha2 0.10.7", + "sha3", + "thiserror", +] + [[package]] name = "colorchoice" version = "1.0.0" @@ -1737,8 +2041,8 @@ version = "6.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7e959d788268e3bf9d35ace83e81b124190378e4c91c9067524675e33394b8ba" dependencies = [ - "strum", - "strum_macros", + "strum 0.24.1", + "strum_macros 0.24.3", "unicode-width", ] @@ -1770,12 +2074,50 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32b13ea120a812beba79e34316b3942a857c86ec1593cb34f27bb28272ce2cca" +[[package]] +name = "const-hex" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08849ed393c907c90016652a01465a12d86361cd38ad2a7de026c56a520cc259" +dependencies = [ + "cfg-if", + "cpufeatures", + "hex", + "serde", +] + [[package]] name = "const-oid" version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "795bc6e66a8e340f075fcf6227e417a2dc976b92b91f3cdc778bb858778b6747" +[[package]] +name = "const_format" +version = "0.2.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c990efc7a285731f9a4378d81aff2f0e85a2c8781a05ef0f8baa8dac54d0ff48" +dependencies = [ + "const_format_proc_macros", +] + +[[package]] +name = "const_format_proc_macros" +version = "0.2.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e026b6ce194a874cb9cf32cd5772d1ef9767cc8fcb5765948d74f37a9d8b2bf6" +dependencies = [ + "proc-macro2", + "quote", + "unicode-xid", +] + +[[package]] +name = "constant_time_eq" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbc" + [[package]] name = "constant_time_eq" version = "0.2.6" @@ -1788,6 +2130,12 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f7144d30dcf0fafbce74250a3963025d8d52177934239851c917d29f1df280c2" +[[package]] +name = "convert_case" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" + [[package]] name = "convert_case" version = "0.6.0" @@ -1865,7 +2213,7 @@ dependencies = [ "hashbrown 0.13.2", "log", "regalloc2", - "smallvec", + "smallvec 1.11.0", "target-lexicon", ] @@ -1901,7 +2249,7 @@ checksum = "64a25d9d0a0ae3079c463c34115ec59507b4707175454f0eee0891e83e30e82d" dependencies = [ "cranelift-codegen", "log", - "smallvec", + "smallvec 1.11.0", "target-lexicon", ] @@ -1933,7 +2281,7 @@ dependencies = [ "cranelift-frontend", "itertools", "log", - "smallvec", + "smallvec 1.11.0", "wasmparser", "wasmtime-types", ] @@ -2125,8 +2473,21 @@ dependencies = [ ] [[package]] -name = "cxx" -version = "1.0.100" +name = "curve25519-dalek-ng" +version = "4.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c359b7249347e46fb28804470d071c921156ad62b3eef5d34e2ba867533dec8" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.6.4", + "subtle-ng", + "zeroize", +] + +[[package]] +name = "cxx" +version = "1.0.100" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e928d50d5858b744d1ea920b790641129c347a770d1530c3a85b77705a5ee031" dependencies = [ @@ -2198,7 +2559,7 @@ dependencies = [ "ident_case", "proc-macro2", "quote", - "strsim", + "strsim 0.10.0", "syn 1.0.109", ] @@ -2212,7 +2573,7 @@ dependencies = [ "ident_case", "proc-macro2", "quote", - "strsim", + "strsim 0.10.0", "syn 2.0.28", ] @@ -2372,8 +2733,10 @@ version = "0.99.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" dependencies = [ + "convert_case 0.4.0", "proc-macro2", "quote", + "rustc_version 0.4.0", "syn 1.0.109", ] @@ -2425,7 +2788,7 @@ version = "4.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f51c5d4ddabd36886dd3e1438cb358cdcb0d7c499cb99cb4ac2e38e18b5cb210" dependencies = [ - "dirs-sys", + "dirs-sys 0.3.7", ] [[package]] @@ -2438,6 +2801,15 @@ dependencies = [ "dirs-sys-next", ] +[[package]] +name = "dirs" +version = "5.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44c45a9d03d6676652bcb5e724c7e988de1acad23a711b5217ab9cbecbec2225" +dependencies = [ + "dirs-sys 0.4.1", +] + [[package]] name = "dirs-next" version = "2.0.0" @@ -2459,6 +2831,18 @@ dependencies = [ "winapi", ] +[[package]] +name = "dirs-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "520f05a5cbd335fae5a99ff7a6ab8627577660ee5cfd6a94a6a929b52ff0321c" +dependencies = [ + "libc", + "option-ext", + "redox_users", + "windows-sys 0.48.0", +] + [[package]] name = "dirs-sys-next" version = "0.1.2" @@ -2499,6 +2883,12 @@ version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dcbb2bf8e87535c23f7a8a321e364ce21462d0ff10cb6407820e8e96dfff6653" +[[package]] +name = "dunce" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" + [[package]] name = "dyn-clonable" version = "0.9.0" @@ -2561,6 +2951,29 @@ dependencies = [ "signature 1.6.4", ] +[[package]] +name = "ed25519" +version = "2.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60f6d271ca33075c88028be6f04d502853d63a5ece419d269c15315d4fc1cf1d" +dependencies = [ + "pkcs8 0.10.2", + "signature 2.1.0", +] + +[[package]] +name = "ed25519-consensus" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c8465edc8ee7436ffea81d21a019b16676ee3db267aa8d5a8d729581ecf998b" +dependencies = [ + "curve25519-dalek-ng", + "hex", + "rand_core 0.6.4", + "sha2 0.9.9", + "zeroize", +] + [[package]] name = "ed25519-dalek" version = "1.0.1" @@ -2568,7 +2981,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" dependencies = [ "curve25519-dalek 3.2.0", - "ed25519", + "ed25519 1.5.3", "rand 0.7.3", "serde", "sha2 0.9.9", @@ -2660,6 +3073,25 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "enr" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0be7b2ac146c1f99fe245c02d16af0696450d8e06c135db75e10eeb9e642c20d" +dependencies = [ + "base64 0.21.2", + "bytes", + "hex", + "k256", + "log", + "rand 0.8.5", + "rlp", + "serde", + "serde-hex", + "sha3", + "zeroize", +] + [[package]] name = "enum-as-inner" version = "0.5.1" @@ -2672,6 +3104,18 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "enum_dispatch" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f33313078bb8d4d05a2733a94ac4c2d8a0df9a2b84424ebf4f33bfc224a890e" +dependencies = [ + "once_cell", + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "env_logger" version = "0.10.0" @@ -2718,6 +3162,323 @@ dependencies = [ "libc", ] +[[package]] +name = "eth-keystore" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fda3bf123be441da5260717e0661c25a2fd9cb2b2c1d20bf2e05580047158ab" +dependencies = [ + "aes 0.8.3", + "ctr 0.9.2", + "digest 0.10.7", + "hex", + "hmac 0.12.1", + "pbkdf2 0.11.0", + "rand 0.8.5", + "scrypt", + "serde", + "serde_json", + "sha2 0.10.7", + "sha3", + "thiserror", + "uuid 0.8.2", +] + +[[package]] +name = "ethabi" +version = "18.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7413c5f74cc903ea37386a8965a936cbeb334bd270862fdece542c1b2dcbc898" +dependencies = [ + "ethereum-types", + "hex", + "once_cell", + "regex", + "serde", + "serde_json", + "sha3", + "thiserror", + "uint", +] + +[[package]] +name = "ethbloom" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c22d4b5885b6aa2fe5e8b9329fb8d232bf739e434e6b87347c63bdd00c120f60" +dependencies = [ + "crunchy", + "fixed-hash", + "impl-codec", + "impl-rlp", + "impl-serde", + "scale-info", + "tiny-keccak", +] + +[[package]] +name = "ethereum-types" +version = "0.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02d215cbf040552efcbe99a38372fe80ab9d00268e20012b79fcd0f073edd8ee" +dependencies = [ + "ethbloom", + "fixed-hash", + "impl-codec", + "impl-rlp", + "impl-serde", + "primitive-types", + "scale-info", + "uint", +] + +[[package]] +name = "ethers" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ba3fd516c15a9a587135229466dbbfc85796de55c5660afbbb1b1c78517d85c" +dependencies = [ + "ethers-addressbook", + "ethers-contract", + "ethers-core", + "ethers-etherscan", + "ethers-middleware", + "ethers-providers", + "ethers-signers", + "ethers-solc", +] + +[[package]] +name = "ethers-addressbook" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0245617f11b8178fa50b52e433e2c34ac69f39116b62c8be2437decf2edf1986" +dependencies = [ + "ethers-core", + "once_cell", + "serde", + "serde_json", +] + +[[package]] +name = "ethers-contract" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02bb80fd2c22631a5eb8a02cbf373cc5fd86937fc966bb670b9a884580c8e71c" +dependencies = [ + "const-hex", + "ethers-contract-abigen", + "ethers-contract-derive", + "ethers-core", + "ethers-providers", + "futures-util", + "once_cell", + "pin-project", + "serde", + "serde_json", + "thiserror", +] + +[[package]] +name = "ethers-contract-abigen" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22c54db0d393393e732a5b20273e4f8ab89f0cce501c84e75fab9c126799a6e6" +dependencies = [ + "Inflector", + "const-hex", + "dunce", + "ethers-core", + "ethers-etherscan", + "eyre", + "prettyplease 0.2.10", + "proc-macro2", + "quote", + "regex", + "reqwest", + "serde", + "serde_json", + "syn 2.0.28", + "toml 0.7.6", + "walkdir", +] + +[[package]] +name = "ethers-contract-derive" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62ee4f216184a1304b707ed258f4f70aa40bf7e1522ab8963d127a8d516eaa1a" +dependencies = [ + "Inflector", + "const-hex", + "ethers-contract-abigen", + "ethers-core", + "proc-macro2", + "quote", + "serde_json", + "syn 2.0.28", +] + +[[package]] +name = "ethers-core" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c29523f73c12753165781c6e5dc11c84d3e44c080a15f7c6cfbd70b514cb6f1" +dependencies = [ + "arrayvec 0.7.4", + "bytes", + "cargo_metadata 0.17.0", + "chrono", + "const-hex", + "elliptic-curve 0.13.5", + "ethabi", + "generic-array 0.14.7", + "k256", + "num_enum 0.7.0", + "once_cell", + "open-fastrlp", + "rand 0.8.5", + "rlp", + "serde", + "serde_json", + "strum 0.25.0", + "syn 2.0.28", + "tempfile", + "thiserror", + "tiny-keccak", + "unicode-xid", +] + +[[package]] +name = "ethers-etherscan" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4aab5af432b3fe5b7756b60df5c9ddeb85a13414575ad8a9acd707c24f0a77a5" +dependencies = [ + "ethers-core", + "reqwest", + "semver 1.0.18", + "serde", + "serde_json", + "thiserror", + "tracing", +] + +[[package]] +name = "ethers-middleware" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "356151d5ded56d4918146366abc9dfc9df367cf0096492a7a5477b21b7693615" +dependencies = [ + "async-trait", + "auto_impl", + "ethers-contract", + "ethers-core", + "ethers-etherscan", + "ethers-providers", + "ethers-signers", + "futures-channel", + "futures-locks", + "futures-util", + "instant", + "reqwest", + "serde", + "serde_json", + "thiserror", + "tokio", + "tracing", + "tracing-futures", + "url", +] + +[[package]] +name = "ethers-providers" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00c84664b294e47fc2860d6db0db0246f79c4c724e552549631bb9505b834bee" +dependencies = [ + "async-trait", + "auto_impl", + "base64 0.21.2", + "bytes", + "const-hex", + "enr", + "ethers-core", + "futures-core", + "futures-timer", + "futures-util", + "hashers", + "http", + "instant", + "jsonwebtoken", + "once_cell", + "pin-project", + "reqwest", + "serde", + "serde_json", + "thiserror", + "tokio", + "tokio-tungstenite", + "tracing", + "tracing-futures", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "ws_stream_wasm", +] + +[[package]] +name = "ethers-signers" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "170b299698702ef1f53d2275af7d6d97409cfa4f9398ee9ff518f6bc9102d0ad" +dependencies = [ + "async-trait", + "coins-bip32", + "coins-bip39", + "const-hex", + "elliptic-curve 0.13.5", + "eth-keystore", + "ethers-core", + "rand 0.8.5", + "sha2 0.10.7", + "thiserror", + "tracing", +] + +[[package]] +name = "ethers-solc" +version = "2.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "66559c8f774712df303c907d087275a52a2046b256791aaa566d5abc8ea66731" +dependencies = [ + "cfg-if", + "const-hex", + "dirs", + "dunce", + "ethers-core", + "glob", + "home", + "md-5", + "num_cpus", + "once_cell", + "path-slash", + "rayon", + "regex", + "semver 1.0.18", + "serde", + "serde_json", + "solang-parser", + "svm-rs", + "thiserror", + "tiny-keccak", + "tokio", + "tracing", + "walkdir", + "yansi", +] + [[package]] name = "event-listener" version = "2.5.3" @@ -2746,6 +3507,16 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "eyre" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c2b6b5a29c02cdc822728b7d7b8ae1bab3e3b05d44522770ddd49722eeac7eb" +dependencies = [ + "indenter", + "once_cell", +] + [[package]] name = "fake-simd" version = "0.1.2" @@ -2767,6 +3538,23 @@ dependencies = [ "instant", ] +[[package]] +name = "fastrand" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6999dc1837253364c2ebb0704ba97994bd874e8f195d665c50b7548f6ea92764" + +[[package]] +name = "fastrlp" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "139834ddba373bbdd213dffe02c8d110508dcf1726c2be27e8d1f7d7e1856418" +dependencies = [ + "arrayvec 0.7.4", + "auto_impl", + "bytes", +] + [[package]] name = "fdlimit" version = "0.2.1" @@ -2869,6 +3657,16 @@ dependencies = [ "miniz_oxide", ] +[[package]] +name = "flex-error" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c606d892c9de11507fa0dcffc116434f94e105d0bbdc4e405b61519464c49d7b" +dependencies = [ + "eyre", + "paste", +] + [[package]] name = "float-cmp" version = "0.9.0" @@ -2884,6 +3682,21 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + [[package]] name = "fork-tree" version = "3.0.0" @@ -2922,13 +3735,13 @@ dependencies = [ "scale-info", "serde", "sp-api", - "sp-application-crypto", - "sp-core", - "sp-io", - "sp-runtime", - "sp-runtime-interface", - "sp-std", - "sp-storage", + "sp-application-crypto 7.0.0", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-runtime-interface 7.0.0", + "sp-std 5.0.0", + "sp-storage 7.0.0", "static_assertions", ] @@ -2940,7 +3753,7 @@ dependencies = [ "Inflector", "array-bytes 4.2.0", "chrono", - "clap", + "clap 4.4.2", "comfy-table", "frame-benchmarking", "frame-support", @@ -2965,16 +3778,16 @@ dependencies = [ "serde_json", "sp-api", "sp-blockchain", - "sp-core", + "sp-core 7.0.0", "sp-database", - "sp-externalities", + "sp-externalities 0.13.0", "sp-inherents", - "sp-keystore", - "sp-runtime", - "sp-state-machine", - "sp-std", - "sp-storage", - "sp-trie", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", + "sp-std 5.0.0", + "sp-storage 7.0.0", + "sp-trie 7.0.0", "thiserror", "thousands", ] @@ -2989,11 +3802,11 @@ dependencies = [ "frame-try-runtime", "parity-scale-codec", "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std", - "sp-tracing", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", + "sp-tracing 6.0.0", ] [[package]] @@ -3016,13 +3829,13 @@ dependencies = [ "async-recursion", "futures", "indicatif", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "parity-scale-codec", "serde", - "sp-core", - "sp-io", - "sp-runtime", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", "spinners", "substrate-rpc-client", "tokio", @@ -3046,20 +3859,20 @@ dependencies = [ "paste", "scale-info", "serde", - "smallvec", + "smallvec 1.11.0", "sp-api", - "sp-arithmetic", - "sp-core", + "sp-arithmetic 6.0.0", + "sp-core 7.0.0", "sp-core-hashing-proc-macro", - "sp-debug-derive", + "sp-debug-derive 5.0.0", "sp-inherents", - "sp-io", - "sp-runtime", + "sp-io 7.0.0", + "sp-runtime 7.0.0", "sp-staking", - "sp-state-machine", - "sp-std", - "sp-tracing", - "sp-weights", + "sp-state-machine 0.13.0", + "sp-std 5.0.0", + "sp-tracing 6.0.0", + "sp-weights 4.0.0", "tt-call", ] @@ -3112,12 +3925,12 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "sp-version", - "sp-weights", + "sp-weights 4.0.0", ] [[package]] @@ -3130,9 +3943,9 @@ dependencies = [ "frame-system", "parity-scale-codec", "scale-info", - "sp-core", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -3152,8 +3965,8 @@ dependencies = [ "frame-support", "parity-scale-codec", "sp-api", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -3243,15 +4056,25 @@ version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" dependencies = [ - "fastrand", + "fastrand 1.9.0", "futures-core", "futures-io", "memchr", "parking", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "waker-fn", ] +[[package]] +name = "futures-locks" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45ec6fe3675af967e67c5536c0b9d44e34e6c52f86bedc4ea49c5317b8e94d06" +dependencies = [ + "futures-channel", + "futures-task", +] + [[package]] name = "futures-macro" version = "0.3.28" @@ -3291,6 +4114,10 @@ name = "futures-timer" version = "3.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2c" +dependencies = [ + "gloo-timers", + "send_wrapper 0.4.0", +] [[package]] name = "futures-util" @@ -3305,7 +4132,7 @@ dependencies = [ "futures-sink", "futures-task", "memchr", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "pin-utils", "slab", ] @@ -3327,7 +4154,7 @@ checksum = "6973ce8518068a71d404f428f6a5b563088545546a6bd8f9c0a7f2608149bc8a" dependencies = [ "genco-macros", "relative-path", - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -3445,6 +4272,51 @@ dependencies = [ "regex", ] +[[package]] +name = "gloo-net" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9902a044653b26b99f7e3693a42f171312d9be8b26b5697bd1e43ad1f8a35e10" +dependencies = [ + "futures-channel", + "futures-core", + "futures-sink", + "gloo-utils", + "js-sys", + "pin-project", + "serde", + "serde_json", + "thiserror", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", +] + +[[package]] +name = "gloo-timers" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c" +dependencies = [ + "futures-channel", + "futures-core", + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "gloo-utils" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "037fcb07216cb3a30f7292bd0176b050b7b9a052ba830ef7d5d65f6dc64ba58e" +dependencies = [ + "js-sys", + "serde", + "serde_json", + "wasm-bindgen", + "web-sys", +] + [[package]] name = "good_lp" version = "1.4.0" @@ -3554,6 +4426,15 @@ dependencies = [ "serde", ] +[[package]] +name = "hashers" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2bca93b15ea5a746f220e56587f71e73c6165eab783df9e26590069953e3c30" +dependencies = [ + "fxhash", +] + [[package]] name = "heck" version = "0.3.3" @@ -3645,6 +4526,15 @@ dependencies = [ "hmac 0.8.1", ] +[[package]] +name = "home" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" +dependencies = [ + "windows-sys 0.48.0", +] + [[package]] name = "hostname" version = "0.3.1" @@ -3675,7 +4565,7 @@ checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" dependencies = [ "bytes", "http", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", ] [[package]] @@ -3718,7 +4608,7 @@ dependencies = [ "httparse", "httpdate", "itoa", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "socket2 0.4.9", "tokio", "tower-service", @@ -3758,6 +4648,19 @@ dependencies = [ "webpki-roots 0.23.1", ] +[[package]] +name = "hyper-tls" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +dependencies = [ + "bytes", + "hyper", + "native-tls", + "tokio", + "tokio-native-tls", +] + [[package]] name = "iana-time-zone" version = "0.1.57" @@ -3852,6 +4755,15 @@ dependencies = [ "parity-scale-codec", ] +[[package]] +name = "impl-rlp" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f28220f89297a075ddc7245cd538076ee98b01f2a9c23a53a4f1105d5a322808" +dependencies = [ + "rlp", +] + [[package]] name = "impl-serde" version = "0.4.0" @@ -3878,6 +4790,12 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9f1a0777d972970f204fdf8ef319f1f4f8459131636d7e3c96c5d59570d0fa6" +[[package]] +name = "indenter" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" + [[package]] name = "indexmap" version = "1.9.3" @@ -4058,12 +4976,28 @@ version = "0.16.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "367a292944c07385839818bb71c8d76611138e2dedb0677d035b8da21d29c78b" dependencies = [ - "jsonrpsee-core", - "jsonrpsee-http-client", - "jsonrpsee-proc-macros", + "jsonrpsee-client-transport 0.16.3", + "jsonrpsee-core 0.16.3", + "jsonrpsee-http-client 0.16.3", + "jsonrpsee-proc-macros 0.16.3", "jsonrpsee-server", - "jsonrpsee-types", - "jsonrpsee-ws-client", + "jsonrpsee-types 0.16.3", + "jsonrpsee-wasm-client", + "jsonrpsee-ws-client 0.16.3", + "tracing", +] + +[[package]] +name = "jsonrpsee" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8002beb64691edce321fc16cdba91916b10d798f9d480a05467b0ee98463c03b" +dependencies = [ + "jsonrpsee-core 0.20.0", + "jsonrpsee-http-client 0.20.0", + "jsonrpsee-proc-macros 0.20.0", + "jsonrpsee-types 0.20.0", + "jsonrpsee-ws-client 0.20.0", "tracing", ] @@ -4073,10 +5007,14 @@ version = "0.16.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c8b3815d9f5d5de348e5f162b316dc9cdf4548305ebb15b4eb9328e66cf27d7a" dependencies = [ + "anyhow", + "futures-channel", + "futures-timer", "futures-util", + "gloo-net", "http", - "jsonrpsee-core", - "jsonrpsee-types", + "jsonrpsee-core 0.16.3", + "jsonrpsee-types 0.16.3", "pin-project", "rustls-native-certs", "soketto", @@ -4088,6 +5026,26 @@ dependencies = [ "webpki-roots 0.25.2", ] +[[package]] +name = "jsonrpsee-client-transport" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "310f9566a32ec8db214805127c4f17e7e8e91015e4a1407fc1d0e84df0086a73" +dependencies = [ + "futures-util", + "http", + "jsonrpsee-core 0.20.0", + "pin-project", + "rustls-native-certs", + "soketto", + "thiserror", + "tokio", + "tokio-rustls 0.24.1", + "tokio-util", + "tracing", + "url", +] + [[package]] name = "jsonrpsee-core" version = "0.16.3" @@ -4104,7 +5062,7 @@ dependencies = [ "futures-util", "globset", "hyper", - "jsonrpsee-types", + "jsonrpsee-types 0.16.3", "parking_lot 0.12.1", "rand 0.8.5", "rustc-hash", @@ -4114,6 +5072,29 @@ dependencies = [ "thiserror", "tokio", "tracing", + "wasm-bindgen-futures", +] + +[[package]] +name = "jsonrpsee-core" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4278372ecb78ebb522c36a242209a29162f4af0997a41158c8b60450b081baf1" +dependencies = [ + "anyhow", + "async-lock", + "async-trait", + "beef", + "futures-timer", + "futures-util", + "hyper", + "jsonrpsee-types 0.20.0", + "rustc-hash", + "serde", + "serde_json", + "thiserror", + "tokio", + "tracing", ] [[package]] @@ -4125,8 +5106,8 @@ dependencies = [ "async-trait", "hyper", "hyper-rustls 0.24.1", - "jsonrpsee-core", - "jsonrpsee-types", + "jsonrpsee-core 0.16.3", + "jsonrpsee-types 0.16.3", "rustc-hash", "serde", "serde_json", @@ -4135,11 +5116,44 @@ dependencies = [ "tracing", ] +[[package]] +name = "jsonrpsee-http-client" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2393386c97ce214851a9677568c5a38223ae4eada833617cb16d8464d1128f1b" +dependencies = [ + "async-trait", + "hyper", + "hyper-rustls 0.24.1", + "jsonrpsee-core 0.20.0", + "jsonrpsee-types 0.20.0", + "serde", + "serde_json", + "thiserror", + "tokio", + "tower", + "tracing", + "url", +] + +[[package]] +name = "jsonrpsee-proc-macros" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44e8ab85614a08792b9bff6c8feee23be78c98d0182d4c622c05256ab553892a" +dependencies = [ + "heck 0.4.1", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "jsonrpsee-proc-macros" -version = "0.16.3" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44e8ab85614a08792b9bff6c8feee23be78c98d0182d4c622c05256ab553892a" +checksum = "985d4a3753a08aaf120429924567795b2764c5c691489316a7fd076178e708b4" dependencies = [ "heck 0.4.1", "proc-macro-crate", @@ -4158,8 +5172,8 @@ dependencies = [ "futures-util", "http", "hyper", - "jsonrpsee-core", - "jsonrpsee-types", + "jsonrpsee-core 0.16.3", + "jsonrpsee-types 0.16.3", "serde", "serde_json", "soketto", @@ -4184,6 +5198,31 @@ dependencies = [ "tracing", ] +[[package]] +name = "jsonrpsee-types" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbea61f2d95b9592491228db0c4d2b1e43ea1154ed9713bb666169cf3919ea7d" +dependencies = [ + "anyhow", + "beef", + "serde", + "serde_json", + "thiserror", + "tracing", +] + +[[package]] +name = "jsonrpsee-wasm-client" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18e5df77c8f625d36e4cfb583c5a674eccebe32403fcfe42f7ceff7fac9324dd" +dependencies = [ + "jsonrpsee-client-transport 0.16.3", + "jsonrpsee-core 0.16.3", + "jsonrpsee-types 0.16.3", +] + [[package]] name = "jsonrpsee-ws-client" version = "0.16.3" @@ -4191,9 +5230,36 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4e1b3975ed5d73f456478681a417128597acd6a2487855fdb7b4a3d4d195bf5e" dependencies = [ "http", - "jsonrpsee-client-transport", - "jsonrpsee-core", - "jsonrpsee-types", + "jsonrpsee-client-transport 0.16.3", + "jsonrpsee-core 0.16.3", + "jsonrpsee-types 0.16.3", +] + +[[package]] +name = "jsonrpsee-ws-client" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9590173f77867bc96b5127e4a862e2edcb7f603c83616e9302d68aab983bc023" +dependencies = [ + "http", + "jsonrpsee-client-transport 0.20.0", + "jsonrpsee-core 0.20.0", + "jsonrpsee-types 0.20.0", + "url", +] + +[[package]] +name = "jsonwebtoken" +version = "8.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6971da4d9c3aa03c3d8f3ff0f4155b534aad021292003895a469716b2a230378" +dependencies = [ + "base64 0.21.2", + "pem", + "ring", + "serde", + "serde_json", + "simple_asn1", ] [[package]] @@ -4207,6 +5273,7 @@ dependencies = [ "elliptic-curve 0.13.5", "once_cell", "sha2 0.10.7", + "signature 2.1.0", ] [[package]] @@ -4224,7 +5291,7 @@ version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e7d770dcb02bf6835887c3a979b5107a04ff4bbde97a5f0928d27404a155add9" dependencies = [ - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -4248,7 +5315,7 @@ dependencies = [ "parking_lot 0.12.1", "regex", "rocksdb", - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -4342,7 +5409,7 @@ dependencies = [ "libp2p-core", "libp2p-dns", "libp2p-identify", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-kad", "libp2p-mdns", "libp2p-metrics", @@ -4356,7 +5423,7 @@ dependencies = [ "libp2p-webrtc", "libp2p-websocket", "libp2p-yamux", - "multiaddr", + "multiaddr 0.17.1", "pin-project", ] @@ -4367,7 +5434,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "510daa05efbc25184458db837f6f9a5143888f1caa742426d92e1833ddd38a50" dependencies = [ "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm", "void", ] @@ -4379,7 +5446,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4caa33f1d26ed664c4fe2cca81a08c8e07d4c1c04f2f4ac7655c2dd85467fda0" dependencies = [ "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm", "void", ] @@ -4395,9 +5462,9 @@ dependencies = [ "futures", "futures-timer", "instant", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", - "multiaddr", + "multiaddr 0.17.1", "multihash 0.17.0", "multistream-select", "once_cell", @@ -4406,7 +5473,7 @@ dependencies = [ "quick-protobuf", "rand 0.8.5", "rw-stream-sink", - "smallvec", + "smallvec 1.11.0", "thiserror", "unsigned-varint", "void", @@ -4422,7 +5489,7 @@ dependencies = [ "libp2p-core", "log", "parking_lot 0.12.1", - "smallvec", + "smallvec 1.11.0", "trust-dns-resolver", ] @@ -4437,13 +5504,13 @@ dependencies = [ "futures", "futures-timer", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm", "log", "lru 0.10.1", "quick-protobuf", "quick-protobuf-codec", - "smallvec", + "smallvec 1.11.0", "thiserror", "void", ] @@ -4454,10 +5521,10 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e2d584751cecb2aabaa56106be6be91338a60a0f4e420cf2af639204f596fc1" dependencies = [ - "bs58", + "bs58 0.4.0", "ed25519-dalek", "log", - "multiaddr", + "multiaddr 0.17.1", "multihash 0.17.0", "quick-protobuf", "rand 0.8.5", @@ -4466,6 +5533,21 @@ dependencies = [ "zeroize", ] +[[package]] +name = "libp2p-identity" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "686e73aff5e23efbb99bc85340ea6fd8686986aa7b283a881ba182cfca535ca9" +dependencies = [ + "bs58 0.5.0", + "log", + "multihash 0.19.1", + "quick-protobuf", + "rand 0.8.5", + "sha2 0.10.7", + "thiserror", +] + [[package]] name = "libp2p-kad" version = "0.43.3" @@ -4481,13 +5563,13 @@ dependencies = [ "futures-timer", "instant", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm", "log", "quick-protobuf", "rand 0.8.5", "sha2 0.10.7", - "smallvec", + "smallvec 1.11.0", "thiserror", "uint", "unsigned-varint", @@ -4504,11 +5586,11 @@ dependencies = [ "futures", "if-watch", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm", "log", "rand 0.8.5", - "smallvec", + "smallvec 1.11.0", "socket2 0.4.9", "tokio", "trust-dns-proto", @@ -4539,7 +5621,7 @@ dependencies = [ "curve25519-dalek 3.2.0", "futures", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", "once_cell", "quick-protobuf", @@ -4580,7 +5662,7 @@ dependencies = [ "futures-timer", "if-watch", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-tls", "log", "parking_lot 0.12.1", @@ -4601,10 +5683,10 @@ dependencies = [ "futures", "instant", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm", "rand 0.8.5", - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -4619,11 +5701,11 @@ dependencies = [ "futures-timer", "instant", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-swarm-derive", "log", "rand 0.8.5", - "smallvec", + "smallvec 1.11.0", "tokio", "void", ] @@ -4664,7 +5746,7 @@ dependencies = [ "futures", "futures-rustls", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "rcgen 0.10.0", "ring", "rustls 0.20.8", @@ -4702,7 +5784,7 @@ dependencies = [ "hex", "if-watch", "libp2p-core", - "libp2p-identity", + "libp2p-identity 0.1.2", "libp2p-noise", "log", "multihash 0.17.0", @@ -4963,16 +6045,17 @@ version = "0.2.0" dependencies = [ "async-trait", "blockifier", - "clap", + "clap 4.4.2", "frame-benchmarking", "frame-benchmarking-cli", "frame-system", "futures", "hex", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "madara-runtime", "mc-block-proposer", + "mc-data-availability", "mc-db", "mc-mapping-sync", "mc-rpc", @@ -5002,14 +6085,14 @@ dependencies = [ "sp-blockchain", "sp-consensus-aura", "sp-consensus-grandpa", - "sp-core", + "sp-core 7.0.0", "sp-inherents", "sp-keyring", "sp-offchain", - "sp-runtime", - "sp-state-machine", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", "sp-timestamp", - "sp-trie", + "sp-trie 7.0.0", "starknet-core", "substrate-build-script-utils", "substrate-frame-rpc-system", @@ -5039,12 +6122,12 @@ dependencies = [ "sp-api", "sp-block-builder", "sp-consensus-aura", - "sp-core", + "sp-core 7.0.0", "sp-inherents", "sp-offchain", - "sp-runtime", + "sp-runtime 7.0.0", "sp-session", - "sp-std", + "sp-std 5.0.0", "sp-transaction-pool", "sp-version", "starknet-ff", @@ -5097,6 +6180,12 @@ dependencies = [ "rawpointer", ] +[[package]] +name = "maybe-uninit" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60302e4db3a61da70c0cb7991976248362f30319e88850c487b9b95bbf059e00" + [[package]] name = "mc-block-proposer" version = "0.2.0" @@ -5115,25 +6204,62 @@ dependencies = [ "sp-api", "sp-blockchain", "sp-consensus", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-runtime", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "substrate-test-runtime-client", ] +[[package]] +name = "mc-data-availability" +version = "0.1.0" +dependencies = [ + "anyhow", + "async-trait", + "avail-subxt", + "celestia-rpc", + "celestia-types", + "clap 4.4.2", + "ethers", + "futures", + "jsonrpsee 0.20.0", + "lazy_static", + "log", + "mc-db", + "mp-starknet", + "reqwest", + "sc-client-api", + "serde", + "serde_json", + "sp-api", + "sp-blockchain", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-keyring", + "sp-runtime 7.0.0", + "starknet_api", + "subxt", + "thiserror", + "tokio", + "url", + "uuid 1.4.0", +] + [[package]] name = "mc-db" version = "0.2.0" dependencies = [ + "ethers", "kvdb-rocksdb", "log", "parity-db", "parity-scale-codec", "sc-client-db", - "sp-core", + "sp-core 7.0.0", "sp-database", - "sp-runtime", + "sp-runtime 7.0.0", + "uuid 1.4.0", ] [[package]] @@ -5152,8 +6278,8 @@ dependencies = [ "sc-client-api", "sp-api", "sp-blockchain", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", ] [[package]] @@ -5164,7 +6290,7 @@ dependencies = [ "frame-support", "frame-system", "hex", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "mc-db", "mc-rpc-core", @@ -5179,10 +6305,10 @@ dependencies = [ "sc-transaction-pool-api", "serde_json", "sp-api", - "sp-arithmetic", + "sp-arithmetic 6.0.0", "sp-blockchain", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "starknet-core", "starknet-ff", "starknet_api", @@ -5203,7 +6329,7 @@ dependencies = [ "flate2", "frame-support", "hex", - "jsonrpsee", + "jsonrpsee 0.16.3", "mp-digest-log", "mp-starknet", "num-bigint", @@ -5212,8 +6338,8 @@ dependencies = [ "serde_with", "sp-api", "sp-blockchain", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "starknet-core", "starknet_api", ] @@ -5231,10 +6357,10 @@ dependencies = [ "sc-client-api", "sp-api", "sp-blockchain", - "sp-core", - "sp-io", - "sp-runtime", - "sp-storage", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-storage 7.0.0", "starknet-core", ] @@ -5257,9 +6383,9 @@ dependencies = [ "serde", "sp-api", "sp-blockchain", - "sp-core", - "sp-runtime", - "sp-tracing", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-tracing 6.0.0", "sp-transaction-pool", "substrate-prometheus-endpoint", "thiserror", @@ -5428,7 +6554,7 @@ dependencies = [ "assert_matches", "mp-starknet", "parity-scale-codec", - "sp-runtime", + "sp-runtime 7.0.0", ] [[package]] @@ -5452,10 +6578,10 @@ dependencies = [ "scale-info", "serde", "serde_json", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "starknet-core", "starknet-crypto 0.6.0", "starknet-ff", @@ -5483,6 +6609,25 @@ dependencies = [ "url", ] +[[package]] +name = "multiaddr" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92a651988b3ed3ad1bc8c87d016bb92f6f395b84ed1db9b926b32b1fc5a2c8b5" +dependencies = [ + "arrayref", + "byteorder", + "data-encoding", + "libp2p-identity 0.2.3", + "multibase", + "multihash 0.19.1", + "percent-encoding", + "serde", + "static_assertions", + "unsigned-varint", + "url", +] + [[package]] name = "multibase" version = "0.9.1" @@ -5524,6 +6669,27 @@ dependencies = [ "unsigned-varint", ] +[[package]] +name = "multihash" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfd8a792c1694c6da4f68db0a9d707c72bd260994da179e6030a5dcee00bb815" +dependencies = [ + "core2", + "multihash-derive", + "unsigned-varint", +] + +[[package]] +name = "multihash" +version = "0.19.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "076d548d76a0e2a0d4ab471d0b1c36c577786dfc4471242035d97a12a735c492" +dependencies = [ + "core2", + "unsigned-varint", +] + [[package]] name = "multihash-derive" version = "0.8.1" @@ -5554,7 +6720,7 @@ dependencies = [ "futures", "log", "pin-project", - "smallvec", + "smallvec 1.11.0", "unsigned-varint", ] @@ -5594,6 +6760,24 @@ dependencies = [ "rand 0.8.5", ] +[[package]] +name = "native-tls" +version = "0.2.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07226173c32f2926027b63cce4bcd8076c3552846cbe7925f3aaffeac0a3b92e" +dependencies = [ + "lazy_static", + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + [[package]] name = "ndarray" version = "0.13.1" @@ -5691,6 +6875,21 @@ dependencies = [ "memoffset 0.6.5", ] +[[package]] +name = "nmt-rs" +version = "0.1.0" +source = "git+https://github.com/eigerco/nmt-rs.git?rev=5146800#514680024ae3bc389aba0e3c70d635ee6d437a0e" +dependencies = [ + "bytes", + "sha2 0.10.7", +] + +[[package]] +name = "nodrop" +version = "0.1.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" + [[package]] name = "nohash-hasher" version = "0.2.0" @@ -5745,6 +6944,17 @@ dependencies = [ "num-traits 0.2.16", ] +[[package]] +name = "num-derive" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "num-format" version = "0.4.4" @@ -5820,6 +7030,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f30b0abd723be7e2ffca1272140fac1a2f084c77ec3e123c192b66af1ee9e6c2" dependencies = [ "autocfg", + "libm 0.2.7", ] [[package]] @@ -5832,6 +7043,48 @@ dependencies = [ "libc", ] +[[package]] +name = "num_enum" +version = "0.5.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" +dependencies = [ + "num_enum_derive 0.5.11", +] + +[[package]] +name = "num_enum" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70bf6736f74634d299d00086f02986875b3c2d924781a6a2cb6c201e73da0ceb" +dependencies = [ + "num_enum_derive 0.7.0", +] + +[[package]] +name = "num_enum_derive" +version = "0.5.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56ea360eafe1022f7cc56cd7b869ed57330fb2453d0c7831d99b74c65d2f5597" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "number_prefix" version = "0.4.0" @@ -5901,12 +7154,81 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" +[[package]] +name = "open-fastrlp" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "786393f80485445794f6043fd3138854dd109cc6c4bd1a6383db304c9ce9b9ce" +dependencies = [ + "arrayvec 0.7.4", + "auto_impl", + "bytes", + "ethereum-types", + "open-fastrlp-derive", +] + +[[package]] +name = "open-fastrlp-derive" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "003b2be5c6c53c1cfeb0a238b8a1c3915cd410feb684457a36c10038f764bb1c" +dependencies = [ + "bytes", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "openssl" +version = "0.10.57" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bac25ee399abb46215765b1cb35bc0212377e58a061560d8b29b024fd0430e7c" +dependencies = [ + "bitflags 2.3.3", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "openssl-probe" version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" +[[package]] +name = "openssl-sys" +version = "0.9.93" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db4d56a4c0478783083cfafcc42493dd4a981d41669da64b4572a2a089b51b1d" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "option-ext" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" + [[package]] name = "p256" version = "0.11.1" @@ -5949,10 +7271,10 @@ dependencies = [ "pallet-timestamp", "parity-scale-codec", "scale-info", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-consensus-aura", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -5965,8 +7287,8 @@ dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", "scale-info", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -5983,14 +7305,14 @@ dependencies = [ "pallet-timestamp", "parity-scale-codec", "scale-info", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-consensus-babe", - "sp-core", - "sp-io", - "sp-runtime", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", "sp-session", "sp-staking", - "sp-std", + "sp-std 5.0.0", ] [[package]] @@ -6004,8 +7326,8 @@ dependencies = [ "log", "parity-scale-codec", "scale-info", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -6021,10 +7343,10 @@ dependencies = [ "scale-info", "serde", "sp-consensus-beefy", - "sp-runtime", + "sp-runtime 7.0.0", "sp-session", "sp-staking", - "sp-std", + "sp-std 5.0.0", ] [[package]] @@ -6045,10 +7367,10 @@ dependencies = [ "serde", "sp-api", "sp-consensus-beefy", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -6064,14 +7386,14 @@ dependencies = [ "pallet-session", "parity-scale-codec", "scale-info", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-consensus-grandpa", - "sp-core", - "sp-io", - "sp-runtime", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", "sp-session", "sp-staking", - "sp-std", + "sp-std 5.0.0", ] [[package]] @@ -6084,11 +7406,11 @@ dependencies = [ "frame-system", "parity-scale-codec", "scale-info", - "sp-core", - "sp-io", + "sp-core 7.0.0", + "sp-io 7.0.0", "sp-mmr-primitives", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -6100,10 +7422,10 @@ dependencies = [ "frame-system", "parity-scale-codec", "scale-info", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -6118,13 +7440,13 @@ dependencies = [ "pallet-timestamp", "parity-scale-codec", "scale-info", - "sp-core", - "sp-io", - "sp-runtime", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-runtime 7.0.0", "sp-session", "sp-staking", - "sp-std", - "sp-trie", + "sp-std 5.0.0", + "sp-trie 7.0.0", ] [[package]] @@ -6152,11 +7474,11 @@ dependencies = [ "serde_json", "serde_with", "sp-api", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-io", - "sp-runtime", - "sp-std", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "starknet-core", "starknet-crypto 0.6.0", "starknet_api", @@ -6173,9 +7495,9 @@ dependencies = [ "frame-system", "parity-scale-codec", "scale-info", - "sp-io", - "sp-runtime", - "sp-std", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -6190,9 +7512,9 @@ dependencies = [ "parity-scale-codec", "scale-info", "sp-inherents", - "sp-io", - "sp-runtime", - "sp-std", + "sp-io 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "sp-timestamp", ] @@ -6292,7 +7614,7 @@ dependencies = [ "instant", "libc", "redox_syscall 0.2.16", - "smallvec", + "smallvec 1.11.0", "winapi", ] @@ -6305,7 +7627,7 @@ dependencies = [ "cfg-if", "libc", "redox_syscall 0.3.5", - "smallvec", + "smallvec 1.11.0", "windows-targets 0.48.1", ] @@ -6315,6 +7637,17 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7924d1d0ad836f665c9065e26d016c673ece3993f30d340068b16f282afc1156" +[[package]] +name = "password-hash" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7676374caaee8a325c9e7a2ae557f216c5563a171d6997b0ef8a65af35147700" +dependencies = [ + "base64ct", + "rand_core 0.6.4", + "subtle", +] + [[package]] name = "paste" version = "1.0.14" @@ -6327,6 +7660,12 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "17359afc20d7ab31fdb42bb844c8b3bb1dabd7dcf7e68428492da7f16966fcef" +[[package]] +name = "path-slash" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e91099d4268b0e11973f036e885d652fb0b21fedcf69738c627f94db6a44f42" + [[package]] name = "pbkdf2" version = "0.8.0" @@ -6340,9 +7679,22 @@ dependencies = [ name = "pbkdf2" version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" +checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" +dependencies = [ + "digest 0.10.7", + "hmac 0.12.1", + "password-hash", + "sha2 0.10.7", +] + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ "digest 0.10.7", + "hmac 0.12.1", ] [[package]] @@ -6429,6 +7781,16 @@ dependencies = [ "indexmap 1.9.3", ] +[[package]] +name = "pharos" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e9567389417feee6ce15dd6527a8a1ecac205ef62c2932bcf3d9f6fc5b78b414" +dependencies = [ + "futures", + "rustc_version 0.4.0", +] + [[package]] name = "phf" version = "0.11.2" @@ -6514,9 +7876,9 @@ checksum = "257b64915a082f7811703966789728173279bdebb956b143dbcd23f6f970a777" [[package]] name = "pin-project-lite" -version = "0.2.10" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c40d25201921e5ff0c862a505c6557ea88568a4e3ace775ab55e93f2f4f9d57" +checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" [[package]] name = "pin-utils" @@ -6574,7 +7936,7 @@ dependencies = [ "concurrent-queue", "libc", "log", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "windows-sys 0.48.0", ] @@ -6699,6 +8061,7 @@ checksum = "9f3486ccba82358b11a77516035647c34ba167dfa53312630de83b12bd4f3d66" dependencies = [ "fixed-hash", "impl-codec", + "impl-rlp", "impl-serde", "scale-info", "uint", @@ -6795,6 +8158,23 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "proptest" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e35c06b98bf36aba164cc17cb25f7e232f5c4aeea73baa14b8a9f0d92dbfa65" +dependencies = [ + "bitflags 1.3.2", + "byteorder", + "lazy_static", + "num-traits 0.2.16", + "rand 0.8.5", + "rand_chacha 0.3.1", + "rand_xorshift", + "regex-syntax 0.6.29", + "unarray", +] + [[package]] name = "prost" version = "0.11.9" @@ -6802,7 +8182,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b82eaa1d779e9a4bc1c3217db8ffbeabaae1dca241bf70183242128d48681cd" dependencies = [ "bytes", - "prost-derive", + "prost-derive 0.11.9", +] + +[[package]] +name = "prost" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa8473a65b88506c106c28ae905ca4a2b83a2993640467a41bb3080627ddfd2c" +dependencies = [ + "bytes", + "prost-derive 0.12.0", ] [[package]] @@ -6819,14 +8209,36 @@ dependencies = [ "multimap", "petgraph", "prettyplease 0.1.25", - "prost", - "prost-types", + "prost 0.11.9", + "prost-types 0.11.9", "regex", "syn 1.0.109", "tempfile", "which", ] +[[package]] +name = "prost-build" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30d3e647e9eb04ddfef78dfee2d5b3fefdf94821c84b710a3d8ebc89ede8b164" +dependencies = [ + "bytes", + "heck 0.4.1", + "itertools", + "log", + "multimap", + "once_cell", + "petgraph", + "prettyplease 0.2.10", + "prost 0.12.0", + "prost-types 0.12.0", + "regex", + "syn 2.0.28", + "tempfile", + "which", +] + [[package]] name = "prost-derive" version = "0.11.9" @@ -6840,13 +8252,35 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "prost-derive" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56075c27b20ae524d00f247b8a4dc333e5784f889fe63099f8e626bc8d73486c" +dependencies = [ + "anyhow", + "itertools", + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "prost-types" version = "0.11.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "213622a1460818959ac1181aaeb2dc9c7f63df720db7d788b3e24eacd1983e13" dependencies = [ - "prost", + "prost 0.11.9", +] + +[[package]] +name = "prost-types" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cebe0a918c97f86c217b0f76fd754e966f8b9f41595095cf7d74cb4e59d730f6" +dependencies = [ + "prost 0.12.0", ] [[package]] @@ -7010,6 +8444,15 @@ dependencies = [ "rand_core 0.6.4", ] +[[package]] +name = "rand_xorshift" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" +dependencies = [ + "rand_core 0.6.4", +] + [[package]] name = "rawpointer" version = "0.2.1" @@ -7121,7 +8564,7 @@ dependencies = [ "fxhash", "log", "slice-group-by", - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -7190,19 +8633,22 @@ dependencies = [ "http-body", "hyper", "hyper-rustls 0.24.1", + "hyper-tls", "ipnet", "js-sys", "log", "mime", + "native-tls", "once_cell", "percent-encoding", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "rustls 0.21.6", "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", "tokio", + "tokio-native-tls", "tokio-rustls 0.24.1", "tower-service", "url", @@ -7259,6 +8705,37 @@ dependencies = [ "winapi", ] +[[package]] +name = "ripemd" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd124222d17ad93a644ed9d011a40f4fb64aa54275c08cc216524a9ea82fb09f" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "rlp" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb919243f34364b6bd2fc10ef797edbfa75f33c252e7998527479c6d6b47e1ec" +dependencies = [ + "bytes", + "rlp-derive", + "rustc-hex", +] + +[[package]] +name = "rlp-derive" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e33d7b2abe0c340d8797fe2907d3f20d3b5ea5908683618bfe80df7f621f672a" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "rocksdb" version = "0.21.0" @@ -7289,7 +8766,7 @@ dependencies = [ "futures", "futures-timer", "rstest_macros", - "rustc_version", + "rustc_version 0.4.0", ] [[package]] @@ -7301,7 +8778,7 @@ dependencies = [ "cfg-if", "proc-macro2", "quote", - "rustc_version", + "rustc_version 0.4.0", "syn 1.0.109", "unicode-ident", ] @@ -7356,6 +8833,35 @@ dependencies = [ "webrtc-util", ] +[[package]] +name = "ruint" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95294d6e3a6192f3aabf91c38f56505a625aa495533442744185a36d75a790c4" +dependencies = [ + "alloy-rlp", + "ark-ff 0.3.0", + "ark-ff 0.4.2", + "bytes", + "fastrlp", + "num-bigint", + "parity-scale-codec", + "primitive-types", + "proptest", + "rand 0.8.5", + "rlp", + "ruint-macro", + "serde", + "valuable", + "zeroize", +] + +[[package]] +name = "ruint-macro" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e666a5496a0b2186dbcd0ff6106e29e093c15591bde62c20d3842007c6978a09" + [[package]] name = "rustc-demangle" version = "0.1.23" @@ -7374,6 +8880,15 @@ version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" +[[package]] +name = "rustc_version" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" +dependencies = [ + "semver 0.11.0", +] + [[package]] name = "rustc_version" version = "0.4.0" @@ -7557,7 +9072,7 @@ dependencies = [ "parking_lot 0.11.2", "rustc-hash", "salsa-macros", - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -7572,6 +9087,15 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "salsa20" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97a22f5af31f73a954c10289c93e8a50cc23d971e80ee446f1f6f7137a088213" +dependencies = [ + "cipher 0.4.4", +] + [[package]] name = "same-file" version = "1.0.6" @@ -7587,8 +9111,8 @@ version = "4.1.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "log", - "sp-core", - "sp-wasm-interface", + "sp-core 7.0.0", + "sp-wasm-interface 7.0.0", "thiserror", ] @@ -7602,9 +9126,9 @@ dependencies = [ "sp-api", "sp-block-builder", "sp-blockchain", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-runtime", + "sp-runtime 7.0.0", ] [[package]] @@ -7621,9 +9145,9 @@ dependencies = [ "serde", "serde_json", "sp-blockchain", - "sp-core", - "sp-runtime", - "sp-state-machine", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", ] [[package]] @@ -7644,10 +9168,10 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "array-bytes 4.2.0", "chrono", - "clap", + "clap 4.4.2", "fdlimit", "futures", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", "names", "parity-scale-codec", @@ -7666,11 +9190,11 @@ dependencies = [ "serde", "serde_json", "sp-blockchain", - "sp-core", + "sp-core 7.0.0", "sp-keyring", - "sp-keystore", - "sp-panic-handler", - "sp-runtime", + "sp-keystore 0.13.0", + "sp-panic-handler 5.0.0", + "sp-runtime 7.0.0", "sp-version", "thiserror", "tiny-bip39", @@ -7693,14 +9217,14 @@ dependencies = [ "sp-api", "sp-blockchain", "sp-consensus", - "sp-core", + "sp-core 7.0.0", "sp-database", - "sp-externalities", - "sp-keystore", - "sp-runtime", - "sp-state-machine", + "sp-externalities 0.13.0", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", "sp-statement-store", - "sp-storage", + "sp-storage 7.0.0", "substrate-prometheus-endpoint", ] @@ -7721,13 +9245,13 @@ dependencies = [ "sc-client-api", "sc-state-db", "schnellru", - "sp-arithmetic", + "sp-arithmetic 6.0.0", "sp-blockchain", - "sp-core", + "sp-core 7.0.0", "sp-database", - "sp-runtime", - "sp-state-machine", - "sp-trie", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", + "sp-trie 7.0.0", ] [[package]] @@ -7738,7 +9262,7 @@ dependencies = [ "async-trait", "futures", "futures-timer", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", "mockall", "parking_lot 0.12.1", @@ -7748,9 +9272,9 @@ dependencies = [ "sp-api", "sp-blockchain", "sp-consensus", - "sp-core", - "sp-runtime", - "sp-state-machine", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", "substrate-prometheus-endpoint", "thiserror", ] @@ -7770,16 +9294,16 @@ dependencies = [ "sc-consensus-slots", "sc-telemetry", "sp-api", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-block-builder", "sp-blockchain", "sp-consensus", "sp-consensus-aura", "sp-consensus-slots", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-keystore", - "sp-runtime", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "thiserror", ] @@ -7806,16 +9330,16 @@ dependencies = [ "sc-telemetry", "scale-info", "sp-api", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-block-builder", "sp-blockchain", "sp-consensus", "sp-consensus-babe", "sp-consensus-slots", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-keystore", - "sp-runtime", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "thiserror", ] @@ -7830,7 +9354,7 @@ dependencies = [ "sc-client-api", "sc-consensus", "sp-blockchain", - "sp-runtime", + "sp-runtime 7.0.0", ] [[package]] @@ -7861,14 +9385,14 @@ dependencies = [ "sc-utils", "serde_json", "sp-api", - "sp-application-crypto", - "sp-arithmetic", + "sp-application-crypto 7.0.0", + "sp-arithmetic 6.0.0", "sp-blockchain", "sp-consensus", "sp-consensus-grandpa", - "sp-core", - "sp-keystore", - "sp-runtime", + "sp-core 7.0.0", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "thiserror", ] @@ -7882,7 +9406,7 @@ dependencies = [ "async-trait", "futures", "futures-timer", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "parity-scale-codec", "sc-client-api", @@ -7899,10 +9423,10 @@ dependencies = [ "sp-consensus-aura", "sp-consensus-babe", "sp-consensus-slots", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-keystore", - "sp-runtime", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", "sp-timestamp", "substrate-prometheus-endpoint", "thiserror", @@ -7921,14 +9445,14 @@ dependencies = [ "sc-client-api", "sc-consensus", "sc-telemetry", - "sp-arithmetic", + "sp-arithmetic 6.0.0", "sp-blockchain", "sp-consensus", "sp-consensus-slots", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-runtime", - "sp-state-machine", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", ] [[package]] @@ -7942,14 +9466,14 @@ dependencies = [ "sc-executor-common", "sc-executor-wasmtime", "sp-api", - "sp-core", - "sp-externalities", - "sp-io", - "sp-panic-handler", - "sp-runtime-interface", - "sp-trie", + "sp-core 7.0.0", + "sp-externalities 0.13.0", + "sp-io 7.0.0", + "sp-panic-handler 5.0.0", + "sp-runtime-interface 7.0.0", + "sp-trie 7.0.0", "sp-version", - "sp-wasm-interface", + "sp-wasm-interface 7.0.0", "tracing", ] @@ -7960,7 +9484,7 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "sc-allocator", "sp-maybe-compressed-blob", - "sp-wasm-interface", + "sp-wasm-interface 7.0.0", "thiserror", "wasm-instrument", ] @@ -7978,8 +9502,8 @@ dependencies = [ "rustix 0.36.15", "sc-allocator", "sc-executor-common", - "sp-runtime-interface", - "sp-wasm-interface", + "sp-runtime-interface 7.0.0", + "sp-wasm-interface 7.0.0", "wasmtime", ] @@ -7996,7 +9520,7 @@ dependencies = [ "sc-network", "sc-network-common", "sp-blockchain", - "sp-runtime", + "sp-runtime 7.0.0", ] [[package]] @@ -8007,9 +9531,9 @@ dependencies = [ "array-bytes 4.2.0", "parking_lot 0.12.1", "serde_json", - "sp-application-crypto", - "sp-core", - "sp-keystore", + "sp-application-crypto 7.0.0", + "sp-core 7.0.0", + "sp-keystore 0.13.0", "thiserror", ] @@ -8045,13 +9569,13 @@ dependencies = [ "sc-utils", "serde", "serde_json", - "smallvec", + "smallvec 1.11.0", "snow", - "sp-arithmetic", + "sp-arithmetic 6.0.0", "sp-blockchain", "sp-consensus", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "thiserror", "unsigned-varint", @@ -8064,17 +9588,17 @@ version = "0.10.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "async-channel", - "cid", + "cid 0.8.6", "futures", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", - "prost", - "prost-build", + "prost 0.11.9", + "prost-build 0.11.9", "sc-client-api", "sc-network", "sc-network-common", "sp-blockchain", - "sp-runtime", + "sp-runtime 7.0.0", "thiserror", "unsigned-varint", ] @@ -8090,18 +9614,18 @@ dependencies = [ "bytes", "futures", "futures-timer", - "libp2p-identity", + "libp2p-identity 0.1.2", "parity-scale-codec", - "prost-build", + "prost-build 0.11.9", "sc-consensus", "sc-peerset", "sc-utils", "serde", - "smallvec", + "smallvec 1.11.0", "sp-blockchain", "sp-consensus", "sp-consensus-grandpa", - "sp-runtime", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "thiserror", "zeroize", @@ -8121,7 +9645,7 @@ dependencies = [ "sc-network", "sc-network-common", "sc-peerset", - "sp-runtime", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "tracing", ] @@ -8134,18 +9658,18 @@ dependencies = [ "array-bytes 4.2.0", "async-channel", "futures", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", "parity-scale-codec", - "prost", - "prost-build", + "prost 0.11.9", + "prost-build 0.11.9", "sc-client-api", "sc-network", "sc-network-common", "sc-peerset", "sp-blockchain", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "thiserror", ] @@ -8165,21 +9689,21 @@ dependencies = [ "lru 0.8.1", "mockall", "parity-scale-codec", - "prost", - "prost-build", + "prost 0.11.9", + "prost-build 0.11.9", "sc-client-api", "sc-consensus", "sc-network", "sc-network-common", "sc-peerset", "sc-utils", - "smallvec", - "sp-arithmetic", + "smallvec 1.11.0", + "sp-arithmetic 6.0.0", "sp-blockchain", "sp-consensus", "sp-consensus-grandpa", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", "thiserror", ] @@ -8200,7 +9724,7 @@ dependencies = [ "sc-peerset", "sc-utils", "sp-consensus", - "sp-runtime", + "sp-runtime 7.0.0", "substrate-prometheus-endpoint", ] @@ -8228,9 +9752,9 @@ dependencies = [ "sc-peerset", "sc-utils", "sp-api", - "sp-core", + "sp-core 7.0.0", "sp-offchain", - "sp-runtime", + "sp-runtime 7.0.0", "threadpool", "tracing", ] @@ -8241,13 +9765,13 @@ version = "4.0.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "futures", - "libp2p-identity", + "libp2p-identity 0.1.2", "log", "parking_lot 0.12.1", "partial_sort", "sc-utils", "serde_json", - "sp-arithmetic", + "sp-arithmetic 6.0.0", "wasm-timer", ] @@ -8266,7 +9790,7 @@ version = "4.0.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "futures", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "parity-scale-codec", "parking_lot 0.12.1", @@ -8280,11 +9804,11 @@ dependencies = [ "serde_json", "sp-api", "sp-blockchain", - "sp-core", - "sp-keystore", + "sp-core 7.0.0", + "sp-keystore 0.13.0", "sp-offchain", "sp-rpc", - "sp-runtime", + "sp-runtime 7.0.0", "sp-session", "sp-statement-store", "sp-version", @@ -8296,16 +9820,16 @@ name = "sc-rpc-api" version = "0.10.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ - "jsonrpsee", + "jsonrpsee 0.16.3", "parity-scale-codec", "sc-chain-spec", "sc-transaction-pool-api", "scale-info", "serde", "serde_json", - "sp-core", + "sp-core 7.0.0", "sp-rpc", - "sp-runtime", + "sp-runtime 7.0.0", "sp-version", "thiserror", ] @@ -8316,7 +9840,7 @@ version = "4.0.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "http", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "serde_json", "substrate-prometheus-endpoint", @@ -8334,7 +9858,7 @@ dependencies = [ "futures", "futures-util", "hex", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "parity-scale-codec", "parking_lot 0.12.1", @@ -8344,8 +9868,8 @@ dependencies = [ "serde", "sp-api", "sp-blockchain", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "sp-version", "thiserror", "tokio-stream", @@ -8361,7 +9885,7 @@ dependencies = [ "exit-future", "futures", "futures-timer", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "parity-scale-codec", "parking_lot 0.12.1", @@ -8397,16 +9921,16 @@ dependencies = [ "sp-api", "sp-blockchain", "sp-consensus", - "sp-core", - "sp-externalities", - "sp-keystore", - "sp-runtime", + "sp-core 7.0.0", + "sp-externalities 0.13.0", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", "sp-session", - "sp-state-machine", - "sp-storage", + "sp-state-machine 0.13.0", + "sp-storage 7.0.0", "sp-transaction-pool", "sp-transaction-storage-proof", - "sp-trie", + "sp-trie 7.0.0", "sp-version", "static_init", "substrate-prometheus-endpoint", @@ -8425,7 +9949,7 @@ dependencies = [ "log", "parity-scale-codec", "parking_lot 0.12.1", - "sp-core", + "sp-core 7.0.0", ] [[package]] @@ -8433,13 +9957,13 @@ name = "sc-storage-monitor" version = "0.1.0" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ - "clap", + "clap 4.4.2", "fs4", "futures", "log", "sc-client-db", "sc-utils", - "sp-core", + "sp-core 7.0.0", "thiserror", "tokio", ] @@ -8458,9 +9982,9 @@ dependencies = [ "sc-telemetry", "serde", "serde_json", - "sp-core", - "sp-io", - "sp-std", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -8503,10 +10027,10 @@ dependencies = [ "serde", "sp-api", "sp-blockchain", - "sp-core", + "sp-core 7.0.0", "sp-rpc", - "sp-runtime", - "sp-tracing", + "sp-runtime 7.0.0", + "sp-tracing 6.0.0", "thiserror", "tracing", "tracing-log", @@ -8543,9 +10067,9 @@ dependencies = [ "serde", "sp-api", "sp-blockchain", - "sp-core", - "sp-runtime", - "sp-tracing", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-tracing 6.0.0", "sp-transaction-pool", "substrate-prometheus-endpoint", "thiserror", @@ -8561,7 +10085,7 @@ dependencies = [ "log", "serde", "sp-blockchain", - "sp-runtime", + "sp-runtime 7.0.0", "thiserror", ] @@ -8577,7 +10101,74 @@ dependencies = [ "log", "parking_lot 0.12.1", "prometheus", - "sp-arithmetic", + "sp-arithmetic 6.0.0", +] + +[[package]] +name = "scale-bits" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8dd7aca73785181cc41f0bbe017263e682b585ca660540ba569133901d013ecf" +dependencies = [ + "parity-scale-codec", + "scale-info", + "serde", +] + +[[package]] +name = "scale-decode" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0459d00b0dbd2e765009924a78ef36b2ff7ba116292d732f00eb0ed8e465d15" +dependencies = [ + "parity-scale-codec", + "primitive-types", + "scale-bits", + "scale-decode-derive", + "scale-info", + "smallvec 1.11.0", + "thiserror", +] + +[[package]] +name = "scale-decode-derive" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4391f0dfbb6690f035f6d2a15d6a12f88cc5395c36bcc056db07ffa2a90870ec" +dependencies = [ + "darling 0.14.4", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "scale-encode" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0401b7cdae8b8aa33725f3611a051358d5b32887ecaa0fda5953a775b2d4d76" +dependencies = [ + "parity-scale-codec", + "primitive-types", + "scale-bits", + "scale-encode-derive", + "scale-info", + "smallvec 1.11.0", + "thiserror", +] + +[[package]] +name = "scale-encode-derive" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "316e0fb10ec0fee266822bd641bab5e332a4ab80ef8c5b5ff35e5401a394f5a6" +dependencies = [ + "darling 0.14.4", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", ] [[package]] @@ -8606,6 +10197,26 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "scale-value" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2096d36e94ce9bf87d8addb752423b6b19730dc88edd7cc452bb2b90573f7a7" +dependencies = [ + "base58", + "blake2", + "either", + "frame-metadata", + "parity-scale-codec", + "scale-bits", + "scale-decode", + "scale-encode", + "scale-info", + "serde", + "thiserror", + "yap", +] + [[package]] name = "schannel" version = "0.1.22" @@ -8656,6 +10267,18 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a3cf7c11c38cb994f3d40e8a8cde3bbd1f72a435e4c49e85d6553d8312306152" +[[package]] +name = "scrypt" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f9e24d2b632954ded8ab2ef9fea0a0c769ea56ea98bddbafbad22caeeadf45d" +dependencies = [ + "hmac 0.12.1", + "pbkdf2 0.11.0", + "salsa20", + "sha2 0.10.7", +] + [[package]] name = "sct" version = "0.6.1" @@ -8772,7 +10395,16 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a3186ec9e65071a2095434b1f5bb24838d4e8e130f584c790f6033c79943537" dependencies = [ - "semver-parser", + "semver-parser 0.7.0", +] + +[[package]] +name = "semver" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" +dependencies = [ + "semver-parser 0.10.2", ] [[package]] @@ -8790,6 +10422,27 @@ version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" +[[package]] +name = "semver-parser" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" +dependencies = [ + "pest", +] + +[[package]] +name = "send_wrapper" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f638d531eccd6e23b980caf34876660d38e265409d8e99b397ab71eb3612fad0" + +[[package]] +name = "send_wrapper" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd0b0ec5f1c1ca621c432a25813d8d60c88abe6d3e08a3eb9cf37d97a0fe3d73" + [[package]] name = "serde" version = "1.0.188" @@ -8799,6 +10452,26 @@ dependencies = [ "serde_derive", ] +[[package]] +name = "serde-hex" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca37e3e4d1b39afd7ff11ee4e947efae85adfddf4841787bfa47c470e96dc26d" +dependencies = [ + "array-init", + "serde", + "smallvec 0.6.14", +] + +[[package]] +name = "serde_bytes" +version = "0.11.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab33ec92f677585af6d88c65593ae2375adde54efdbf16d597f2cbc7a6d368ff" +dependencies = [ + "serde", +] + [[package]] name = "serde_derive" version = "1.0.188" @@ -8832,6 +10505,17 @@ dependencies = [ "serde", ] +[[package]] +name = "serde_repr" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8725e1dfadb3a50f7e5ce0b1a540466f6ed3fe7a0fca2ac2b8b831d31316bd00" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "serde_spanned" version = "0.6.3" @@ -9007,6 +10691,18 @@ dependencies = [ "wide", ] +[[package]] +name = "simple_asn1" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adc4e5204eb1910f40f9cfa375f6f05b68c3abac4b6fd879c8ff5e7ae8a0a085" +dependencies = [ + "num-bigint", + "num-traits 0.2.16", + "thiserror", + "time 0.3.23", +] + [[package]] name = "siphasher" version = "0.3.10" @@ -9028,6 +10724,15 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "826167069c09b99d56f31e9ae5c99049e932a98c9dc2dac47645b08dbbf76ba7" +[[package]] +name = "smallvec" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b97fcaeba89edba30f044a10c6a3cc39df9c3f17d7cd829dd1446cab35f890e0" +dependencies = [ + "maybe-uninit", +] + [[package]] name = "smallvec" version = "1.11.0" @@ -9061,7 +10766,7 @@ dependencies = [ "curve25519-dalek 4.0.0-rc.1", "rand_core 0.6.4", "ring", - "rustc_version", + "rustc_version 0.4.0", "sha2 0.10.7", "subtle", ] @@ -9103,6 +10808,20 @@ dependencies = [ "sha-1", ] +[[package]] +name = "solang-parser" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c792fe9fae2a2f716846f214ca10d5a1e21133e0bf36cef34bcc4a852467b21" +dependencies = [ + "itertools", + "lalrpop", + "lalrpop-util", + "phf", + "thiserror", + "unicode-xid", +] + [[package]] name = "sp-api" version = "4.0.0-dev" @@ -9113,12 +10832,12 @@ dependencies = [ "parity-scale-codec", "scale-info", "sp-api-proc-macro", - "sp-core", + "sp-core 7.0.0", "sp-metadata-ir", - "sp-runtime", - "sp-state-machine", - "sp-std", - "sp-trie", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", + "sp-std 5.0.0", + "sp-trie 7.0.0", "sp-version", "thiserror", ] @@ -9145,9 +10864,23 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-core", - "sp-io", - "sp-std", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-std 5.0.0", +] + +[[package]] +name = "sp-application-crypto" +version = "23.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "899492ea547816d5dfe9a5a2ecc32f65a7110805af6da3380aa4902371b31dc2" +dependencies = [ + "parity-scale-codec", + "scale-info", + "serde", + "sp-core 21.0.0", + "sp-io 23.0.0", + "sp-std 8.0.0", ] [[package]] @@ -9160,7 +10893,22 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-std", + "sp-std 5.0.0", + "static_assertions", +] + +[[package]] +name = "sp-arithmetic" +version = "16.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb6020576e544c6824a51d651bc8df8e6ab67cd59f1c9ac09868bb81a5199ded" +dependencies = [ + "integer-sqrt", + "num-traits 0.2.16", + "parity-scale-codec", + "scale-info", + "serde", + "sp-std 8.0.0", "static_assertions", ] @@ -9172,8 +10920,8 @@ dependencies = [ "parity-scale-codec", "sp-api", "sp-inherents", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -9189,8 +10937,8 @@ dependencies = [ "sp-api", "sp-consensus", "sp-database", - "sp-runtime", - "sp-state-machine", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", "thiserror", ] @@ -9202,10 +10950,10 @@ dependencies = [ "async-trait", "futures", "log", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-runtime", - "sp-state-machine", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", "thiserror", ] @@ -9218,12 +10966,12 @@ dependencies = [ "parity-scale-codec", "scale-info", "sp-api", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-consensus", "sp-consensus-slots", "sp-inherents", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "sp-timestamp", ] @@ -9237,14 +10985,14 @@ dependencies = [ "scale-info", "serde", "sp-api", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-consensus", "sp-consensus-slots", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-keystore", - "sp-runtime", - "sp-std", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "sp-timestamp", ] @@ -9258,13 +11006,13 @@ dependencies = [ "scale-info", "serde", "sp-api", - "sp-application-crypto", - "sp-core", - "sp-io", + "sp-application-crypto 7.0.0", + "sp-core 7.0.0", + "sp-io 7.0.0", "sp-mmr-primitives", - "sp-runtime", - "sp-std", - "strum", + "sp-runtime 7.0.0", + "sp-std 5.0.0", + "strum 0.24.1", ] [[package]] @@ -9278,11 +11026,11 @@ dependencies = [ "scale-info", "serde", "sp-api", - "sp-application-crypto", - "sp-core", - "sp-keystore", - "sp-runtime", - "sp-std", + "sp-application-crypto 7.0.0", + "sp-core 7.0.0", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -9293,7 +11041,7 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-std", + "sp-std 5.0.0", "sp-timestamp", ] @@ -9306,7 +11054,52 @@ dependencies = [ "bitflags 1.3.2", "blake2", "bounded-collections", - "bs58", + "bs58 0.4.0", + "dyn-clonable", + "ed25519-zebra", + "futures", + "hash-db", + "hash256-std-hasher", + "impl-serde", + "lazy_static", + "libsecp256k1", + "log", + "merlin", + "parity-scale-codec", + "parking_lot 0.12.1", + "paste", + "primitive-types", + "rand 0.8.5", + "regex", + "scale-info", + "schnorrkel", + "secp256k1", + "secrecy", + "serde", + "sp-core-hashing 5.0.0", + "sp-debug-derive 5.0.0", + "sp-externalities 0.13.0", + "sp-runtime-interface 7.0.0", + "sp-std 5.0.0", + "sp-storage 7.0.0", + "ss58-registry", + "substrate-bip39", + "thiserror", + "tiny-bip39", + "zeroize", +] + +[[package]] +name = "sp-core" +version = "21.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f18d9e2f67d8661f9729f35347069ac29d92758b59135176799db966947a7336" +dependencies = [ + "array-bytes 4.2.0", + "bitflags 1.3.2", + "blake2", + "bounded-collections", + "bs58 0.4.0", "dyn-clonable", "ed25519-zebra", "futures", @@ -9328,12 +11121,12 @@ dependencies = [ "secp256k1", "secrecy", "serde", - "sp-core-hashing", - "sp-debug-derive", - "sp-externalities", - "sp-runtime-interface", - "sp-std", - "sp-storage", + "sp-core-hashing 9.0.0", + "sp-debug-derive 8.0.0", + "sp-externalities 0.19.0", + "sp-runtime-interface 17.0.0", + "sp-std 8.0.0", + "sp-storage 13.0.0", "ss58-registry", "substrate-bip39", "thiserror", @@ -9351,7 +11144,22 @@ dependencies = [ "digest 0.10.7", "sha2 0.10.7", "sha3", - "sp-std", + "sp-std 5.0.0", + "twox-hash", +] + +[[package]] +name = "sp-core-hashing" +version = "9.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ee599a8399448e65197f9a6cee338ad192e9023e35e31f22382964c3c174c68" +dependencies = [ + "blake2b_simd", + "byteorder", + "digest 0.10.7", + "sha2 0.10.7", + "sha3", + "sp-std 8.0.0", "twox-hash", ] @@ -9362,7 +11170,7 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "proc-macro2", "quote", - "sp-core-hashing", + "sp-core-hashing 5.0.0", "syn 2.0.28", ] @@ -9385,6 +11193,17 @@ dependencies = [ "syn 2.0.28", ] +[[package]] +name = "sp-debug-derive" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7f531814d2f16995144c74428830ccf7d94ff4a7749632b83ad8199b181140c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "sp-externalities" version = "0.13.0" @@ -9392,8 +11211,20 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "environmental", "parity-scale-codec", - "sp-std", - "sp-storage", + "sp-std 5.0.0", + "sp-storage 7.0.0", +] + +[[package]] +name = "sp-externalities" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0f71c671e01a8ca60da925d43a1b351b69626e268b8837f8371e320cf1dd100" +dependencies = [ + "environmental", + "parity-scale-codec", + "sp-std 8.0.0", + "sp-storage 13.0.0", ] [[package]] @@ -9405,9 +11236,9 @@ dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", "scale-info", - "sp-core", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "thiserror", ] @@ -9417,7 +11248,34 @@ version = "7.0.0" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "bytes", - "ed25519", + "ed25519 1.5.3", + "ed25519-dalek", + "futures", + "libsecp256k1", + "log", + "parity-scale-codec", + "rustversion", + "secp256k1", + "sp-core 7.0.0", + "sp-externalities 0.13.0", + "sp-keystore 0.13.0", + "sp-runtime-interface 7.0.0", + "sp-state-machine 0.13.0", + "sp-std 5.0.0", + "sp-tracing 6.0.0", + "sp-trie 7.0.0", + "tracing", + "tracing-core", +] + +[[package]] +name = "sp-io" +version = "23.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d597e35a9628fe7454b08965b2442e3ec0f264b0a90d41328e87422cec02e99" +dependencies = [ + "bytes", + "ed25519 1.5.3", "ed25519-dalek", "futures", "libsecp256k1", @@ -9425,14 +11283,14 @@ dependencies = [ "parity-scale-codec", "rustversion", "secp256k1", - "sp-core", - "sp-externalities", - "sp-keystore", - "sp-runtime-interface", - "sp-state-machine", - "sp-std", - "sp-tracing", - "sp-trie", + "sp-core 21.0.0", + "sp-externalities 0.19.0", + "sp-keystore 0.27.0", + "sp-runtime-interface 17.0.0", + "sp-state-machine 0.28.0", + "sp-std 8.0.0", + "sp-tracing 10.0.0", + "sp-trie 22.0.0", "tracing", "tracing-core", ] @@ -9443,9 +11301,9 @@ version = "7.0.0" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "lazy_static", - "sp-core", - "sp-runtime", - "strum", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "strum 0.24.1", ] [[package]] @@ -9457,8 +11315,22 @@ dependencies = [ "parity-scale-codec", "parking_lot 0.12.1", "serde", - "sp-core", - "sp-externalities", + "sp-core 7.0.0", + "sp-externalities 0.13.0", + "thiserror", +] + +[[package]] +name = "sp-keystore" +version = "0.27.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9be3cdd67cc1d9c1db17c5cbc4ec4924054a8437009d167f21f6590797e4aa45" +dependencies = [ + "futures", + "parity-scale-codec", + "parking_lot 0.12.1", + "sp-core 21.0.0", + "sp-externalities 0.19.0", "thiserror", ] @@ -9479,7 +11351,7 @@ dependencies = [ "frame-metadata", "parity-scale-codec", "scale-info", - "sp-std", + "sp-std 5.0.0", ] [[package]] @@ -9493,10 +11365,10 @@ dependencies = [ "scale-info", "serde", "sp-api", - "sp-core", - "sp-debug-derive", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-debug-derive 5.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "thiserror", ] @@ -9506,8 +11378,8 @@ version = "4.0.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "sp-api", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", ] [[package]] @@ -9520,6 +11392,17 @@ dependencies = [ "regex", ] +[[package]] +name = "sp-panic-handler" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebd2de46003fa8212426838ca71cd42ee36a26480ba9ffea983506ce03131033" +dependencies = [ + "backtrace", + "lazy_static", + "regex", +] + [[package]] name = "sp-rpc" version = "6.0.0" @@ -9527,7 +11410,7 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "rustc-hash", "serde", - "sp-core", + "sp-core 7.0.0", ] [[package]] @@ -9544,12 +11427,35 @@ dependencies = [ "rand 0.8.5", "scale-info", "serde", - "sp-application-crypto", - "sp-arithmetic", - "sp-core", - "sp-io", - "sp-std", - "sp-weights", + "sp-application-crypto 7.0.0", + "sp-arithmetic 6.0.0", + "sp-core 7.0.0", + "sp-io 7.0.0", + "sp-std 5.0.0", + "sp-weights 4.0.0", +] + +[[package]] +name = "sp-runtime" +version = "24.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21c5bfc764a1a8259d7e8f7cfd22c84006275a512c958d3ff966c92151e134d5" +dependencies = [ + "either", + "hash256-std-hasher", + "impl-trait-for-tuples", + "log", + "parity-scale-codec", + "paste", + "rand 0.8.5", + "scale-info", + "serde", + "sp-application-crypto 23.0.0", + "sp-arithmetic 16.0.0", + "sp-core 21.0.0", + "sp-io 23.0.0", + "sp-std 8.0.0", + "sp-weights 20.0.0", ] [[package]] @@ -9561,12 +11467,31 @@ dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", "primitive-types", - "sp-externalities", - "sp-runtime-interface-proc-macro", - "sp-std", - "sp-storage", - "sp-tracing", - "sp-wasm-interface", + "sp-externalities 0.13.0", + "sp-runtime-interface-proc-macro 6.0.0", + "sp-std 5.0.0", + "sp-storage 7.0.0", + "sp-tracing 6.0.0", + "sp-wasm-interface 7.0.0", + "static_assertions", +] + +[[package]] +name = "sp-runtime-interface" +version = "17.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e676128182f90015e916f806cba635c8141e341e7abbc45d25525472e1bbce8" +dependencies = [ + "bytes", + "impl-trait-for-tuples", + "parity-scale-codec", + "primitive-types", + "sp-externalities 0.19.0", + "sp-runtime-interface-proc-macro 11.0.0", + "sp-std 8.0.0", + "sp-storage 13.0.0", + "sp-tracing 10.0.0", + "sp-wasm-interface 14.0.0", "static_assertions", ] @@ -9582,6 +11507,19 @@ dependencies = [ "syn 2.0.28", ] +[[package]] +name = "sp-runtime-interface-proc-macro" +version = "11.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a5d5bd5566fe5633ec48dfa35ab152fd29f8a577c21971e1c6db9f28afb9bbb9" +dependencies = [ + "Inflector", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.28", +] + [[package]] name = "sp-session" version = "4.0.0-dev" @@ -9590,10 +11528,10 @@ dependencies = [ "parity-scale-codec", "scale-info", "sp-api", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "sp-staking", - "sp-std", + "sp-std 5.0.0", ] [[package]] @@ -9604,9 +11542,9 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "sp-core", - "sp-runtime", - "sp-std", + "sp-core 7.0.0", + "sp-runtime 7.0.0", + "sp-std 5.0.0", ] [[package]] @@ -9619,12 +11557,33 @@ dependencies = [ "parity-scale-codec", "parking_lot 0.12.1", "rand 0.8.5", - "smallvec", - "sp-core", - "sp-externalities", - "sp-panic-handler", - "sp-std", - "sp-trie", + "smallvec 1.11.0", + "sp-core 7.0.0", + "sp-externalities 0.13.0", + "sp-panic-handler 5.0.0", + "sp-std 5.0.0", + "sp-trie 7.0.0", + "thiserror", + "tracing", +] + +[[package]] +name = "sp-state-machine" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ef45d31f9e7ac648f8899a0cd038a3608f8499028bff55b6c799702592325b6" +dependencies = [ + "hash-db", + "log", + "parity-scale-codec", + "parking_lot 0.12.1", + "rand 0.8.5", + "smallvec 1.11.0", + "sp-core 21.0.0", + "sp-externalities 0.19.0", + "sp-panic-handler 8.0.0", + "sp-std 8.0.0", + "sp-trie 22.0.0", "thiserror", "tracing", ] @@ -9638,12 +11597,12 @@ dependencies = [ "parity-scale-codec", "scale-info", "sp-api", - "sp-application-crypto", - "sp-core", - "sp-externalities", - "sp-runtime", - "sp-runtime-interface", - "sp-std", + "sp-application-crypto 7.0.0", + "sp-core 7.0.0", + "sp-externalities 0.13.0", + "sp-runtime 7.0.0", + "sp-runtime-interface 7.0.0", + "sp-std 5.0.0", "thiserror", ] @@ -9652,6 +11611,12 @@ name = "sp-std" version = "5.0.0" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" +[[package]] +name = "sp-std" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53458e3c57df53698b3401ec0934bea8e8cfce034816873c0b0abbd83d7bac0d" + [[package]] name = "sp-storage" version = "7.0.0" @@ -9661,8 +11626,22 @@ dependencies = [ "parity-scale-codec", "ref-cast", "serde", - "sp-debug-derive", - "sp-std", + "sp-debug-derive 5.0.0", + "sp-std 5.0.0", +] + +[[package]] +name = "sp-storage" +version = "13.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94294be83f11d4958cfea89ed5798f0b6605f5defc3a996948848458abbcc18e" +dependencies = [ + "impl-serde", + "parity-scale-codec", + "ref-cast", + "serde", + "sp-debug-derive 8.0.0", + "sp-std 8.0.0", ] [[package]] @@ -9675,8 +11654,8 @@ dependencies = [ "log", "parity-scale-codec", "sp-inherents", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "thiserror", ] @@ -9686,7 +11665,20 @@ version = "6.0.0" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "parity-scale-codec", - "sp-std", + "sp-std 5.0.0", + "tracing", + "tracing-core", + "tracing-subscriber", +] + +[[package]] +name = "sp-tracing" +version = "10.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "357f7591980dd58305956d32f8f6646d0a8ea9ea0e7e868e46f53b68ddf00cec" +dependencies = [ + "parity-scale-codec", + "sp-std 8.0.0", "tracing", "tracing-core", "tracing-subscriber", @@ -9698,7 +11690,7 @@ version = "4.0.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "sp-api", - "sp-runtime", + "sp-runtime 7.0.0", ] [[package]] @@ -9710,11 +11702,11 @@ dependencies = [ "log", "parity-scale-codec", "scale-info", - "sp-core", + "sp-core 7.0.0", "sp-inherents", - "sp-runtime", - "sp-std", - "sp-trie", + "sp-runtime 7.0.0", + "sp-std 5.0.0", + "sp-trie 7.0.0", ] [[package]] @@ -9732,8 +11724,32 @@ dependencies = [ "parking_lot 0.12.1", "scale-info", "schnellru", - "sp-core", - "sp-std", + "sp-core 7.0.0", + "sp-std 5.0.0", + "thiserror", + "tracing", + "trie-db", + "trie-root", +] + +[[package]] +name = "sp-trie" +version = "22.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48e4eeb7ef23f79eba8609db79ef9cef242f994f1f87a3c0387b4b5f177fda74" +dependencies = [ + "ahash 0.8.3", + "hash-db", + "hashbrown 0.13.2", + "lazy_static", + "memory-db", + "nohash-hasher", + "parity-scale-codec", + "parking_lot 0.12.1", + "scale-info", + "schnellru", + "sp-core 21.0.0", + "sp-std 8.0.0", "thiserror", "tracing", "trie-db", @@ -9751,8 +11767,8 @@ dependencies = [ "scale-info", "serde", "sp-core-hashing-proc-macro", - "sp-runtime", - "sp-std", + "sp-runtime 7.0.0", + "sp-std 5.0.0", "sp-version-proc-macro", "thiserror", ] @@ -9777,11 +11793,25 @@ dependencies = [ "impl-trait-for-tuples", "log", "parity-scale-codec", - "sp-std", + "sp-std 5.0.0", "wasmi", "wasmtime", ] +[[package]] +name = "sp-wasm-interface" +version = "14.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a19c122609ca5d8246be6386888596320d03c7bc880959eaa2c36bcd5acd6846" +dependencies = [ + "anyhow", + "impl-trait-for-tuples", + "log", + "parity-scale-codec", + "sp-std 8.0.0", + "wasmtime", +] + [[package]] name = "sp-weights" version = "4.0.0" @@ -9790,11 +11820,27 @@ dependencies = [ "parity-scale-codec", "scale-info", "serde", - "smallvec", - "sp-arithmetic", - "sp-core", - "sp-debug-derive", - "sp-std", + "smallvec 1.11.0", + "sp-arithmetic 6.0.0", + "sp-core 7.0.0", + "sp-debug-derive 5.0.0", + "sp-std 5.0.0", +] + +[[package]] +name = "sp-weights" +version = "20.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45d084c735544f70625b821c3acdbc7a2fc1893ca98b85f1942631284692c75b" +dependencies = [ + "parity-scale-codec", + "scale-info", + "serde", + "smallvec 1.11.0", + "sp-arithmetic 16.0.0", + "sp-core 21.0.0", + "sp-debug-derive 8.0.0", + "sp-std 8.0.0", ] [[package]] @@ -9817,7 +11863,7 @@ checksum = "08615eea740067d9899969bc2891c68a19c315cb1f66640af9a9ecb91b13bcab" dependencies = [ "lazy_static", "maplit", - "strum", + "strum 0.24.1", ] [[package]] @@ -9965,7 +12011,7 @@ version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "db2cb1d9c0a50380cddab99cb202c6bfb3332728a2769bd0ca2ee80b0b390dd4" dependencies = [ - "ark-ff", + "ark-ff 0.4.2", "bigdecimal", "crypto-bigint 0.5.2", "getrandom 0.2.10", @@ -10039,19 +12085,58 @@ dependencies = [ "precomputed-hash", ] +[[package]] +name = "strsim" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a" + [[package]] name = "strsim" version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +[[package]] +name = "structopt" +version = "0.3.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c6b5c64445ba8094a6ab0c3cd2ad323e07171012d9c98b0b15651daf1787a10" +dependencies = [ + "clap 2.34.0", + "lazy_static", + "structopt-derive", +] + +[[package]] +name = "structopt-derive" +version = "0.4.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dcb5ae327f9cc13b68763b5749770cb9e048a99bd9dfdfa58d0cf05d5f64afe0" +dependencies = [ + "heck 0.3.3", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "strum" version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f" dependencies = [ - "strum_macros", + "strum_macros 0.24.3", +] + +[[package]] +name = "strum" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" +dependencies = [ + "strum_macros 0.25.2", ] [[package]] @@ -10067,6 +12152,19 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "strum_macros" +version = "0.25.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad8d03b598d3d0fff69bf533ee3ef19b8eeb342729596df84bcc7e1f96ec4059" +dependencies = [ + "heck 0.4.1", + "proc-macro2", + "quote", + "rustversion", + "syn 2.0.28", +] + [[package]] name = "stun" version = "0.4.4" @@ -10114,7 +12212,7 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "frame-system-rpc-runtime-api", "futures", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "parity-scale-codec", "sc-rpc-api", @@ -10122,8 +12220,8 @@ dependencies = [ "sp-api", "sp-block-builder", "sp-blockchain", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", ] [[package]] @@ -10144,11 +12242,11 @@ version = "0.10.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "async-trait", - "jsonrpsee", + "jsonrpsee 0.16.3", "log", "sc-rpc-api", "serde", - "sp-runtime", + "sp-runtime 7.0.0", ] [[package]] @@ -10170,11 +12268,11 @@ dependencies = [ "serde_json", "sp-blockchain", "sp-consensus", - "sp-core", + "sp-core 7.0.0", "sp-keyring", - "sp-keystore", - "sp-runtime", - "sp-state-machine", + "sp-keystore 0.13.0", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", ] [[package]] @@ -10200,26 +12298,26 @@ dependencies = [ "scale-info", "serde", "sp-api", - "sp-application-crypto", + "sp-application-crypto 7.0.0", "sp-block-builder", "sp-consensus-aura", "sp-consensus-babe", "sp-consensus-beefy", "sp-consensus-grandpa", - "sp-core", - "sp-debug-derive", - "sp-externalities", + "sp-core 7.0.0", + "sp-debug-derive 5.0.0", + "sp-externalities 0.13.0", "sp-inherents", - "sp-io", + "sp-io 7.0.0", "sp-keyring", "sp-offchain", - "sp-runtime", - "sp-runtime-interface", + "sp-runtime 7.0.0", + "sp-runtime-interface 7.0.0", "sp-session", - "sp-state-machine", - "sp-std", + "sp-state-machine 0.13.0", + "sp-std 5.0.0", "sp-transaction-pool", - "sp-trie", + "sp-trie 7.0.0", "sp-version", "substrate-wasm-builder", "trie-db", @@ -10239,8 +12337,8 @@ dependencies = [ "sp-api", "sp-blockchain", "sp-consensus", - "sp-core", - "sp-runtime", + "sp-core 7.0.0", + "sp-runtime 7.0.0", "substrate-test-client", "substrate-test-runtime", ] @@ -10252,10 +12350,10 @@ source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e dependencies = [ "ansi_term", "build-helper", - "cargo_metadata", + "cargo_metadata 0.15.4", "filetime", "sp-maybe-compressed-blob", - "strum", + "strum 0.24.1", "tempfile", "toml 0.7.6", "walkdir", @@ -10277,6 +12375,120 @@ version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" +[[package]] +name = "subtle-encoding" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dcb1ed7b8330c5eed5441052651dd7a12c75e2ed88f2ec024ae1fa3a5e59945" +dependencies = [ + "zeroize", +] + +[[package]] +name = "subtle-ng" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "734676eb262c623cec13c3155096e08d1f8f29adce39ba17948b18dad1e54142" + +[[package]] +name = "subxt" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "31a734d66fa935fbda56ba6a71d7e969f424c8c5608d416ba8499d71d8cbfc1f" +dependencies = [ + "base58", + "blake2", + "derivative", + "either", + "frame-metadata", + "futures", + "getrandom 0.2.10", + "hex", + "impl-serde", + "jsonrpsee 0.16.3", + "parity-scale-codec", + "primitive-types", + "scale-bits", + "scale-decode", + "scale-encode", + "scale-info", + "scale-value", + "serde", + "serde_json", + "sp-core 21.0.0", + "sp-core-hashing 9.0.0", + "sp-runtime 24.0.0", + "subxt-macro", + "subxt-metadata", + "thiserror", + "tracing", +] + +[[package]] +name = "subxt-codegen" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e2f231d97c145c564bd544212c0cc0c29c09ff516af199f4ce00c8e055f8138" +dependencies = [ + "frame-metadata", + "heck 0.4.1", + "hex", + "jsonrpsee 0.16.3", + "parity-scale-codec", + "proc-macro2", + "quote", + "scale-info", + "subxt-metadata", + "syn 2.0.28", + "thiserror", + "tokio", +] + +[[package]] +name = "subxt-macro" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e544e41e1c84b616632cd2f86862342868f62e11e4cd9062a9e3dbf5fc871f64" +dependencies = [ + "darling 0.20.3", + "proc-macro-error", + "subxt-codegen", + "syn 2.0.28", +] + +[[package]] +name = "subxt-metadata" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a01ce5044c81db3404d38c56f1e69d72eff72c54e5913c9bba4c0b58d376031f" +dependencies = [ + "frame-metadata", + "parity-scale-codec", + "scale-info", + "sp-core-hashing 9.0.0", + "thiserror", +] + +[[package]] +name = "svm-rs" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "597e3a746727984cb7ea2487b6a40726cad0dbe86628e7d429aa6b8c4c153db4" +dependencies = [ + "dirs", + "fs2", + "hex", + "once_cell", + "reqwest", + "semver 1.0.18", + "serde", + "serde_json", + "sha2 0.10.7", + "thiserror", + "url", + "zip", +] + [[package]] name = "syn" version = "1.0.109" @@ -10346,18 +12558,62 @@ checksum = "df8e77cb757a61f51b947ec4a7e3646efd825b73561db1c232a8ccb639e611a0" [[package]] name = "tempfile" -version = "3.6.0" +version = "3.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31c0432476357e58790aaa47a8efb0c5138f137343f3b5f23bd36a27e3b0a6d6" +checksum = "cb94d2f3cc536af71caac6b6fcebf65860b347e7ce0cc9ebe8f70d3e521054ef" dependencies = [ - "autocfg", "cfg-if", - "fastrand", + "fastrand 2.0.0", "redox_syscall 0.3.5", - "rustix 0.37.23", + "rustix 0.38.4", "windows-sys 0.48.0", ] +[[package]] +name = "tendermint" +version = "0.32.0" +source = "git+https://github.com/eigerco/celestia-tendermint-rs.git?rev=19dc3da#19dc3dae78ee7e4dcde67881ab31af229ed133a2" +dependencies = [ + "bytes", + "digest 0.10.7", + "ed25519 2.2.2", + "ed25519-consensus", + "flex-error", + "futures", + "num-traits 0.2.16", + "once_cell", + "prost 0.12.0", + "prost-types 0.12.0", + "serde", + "serde_bytes", + "serde_json", + "serde_repr", + "sha2 0.10.7", + "signature 2.1.0", + "subtle", + "subtle-encoding", + "tendermint-proto", + "time 0.3.23", + "zeroize", +] + +[[package]] +name = "tendermint-proto" +version = "0.32.0" +source = "git+https://github.com/eigerco/celestia-tendermint-rs.git?rev=19dc3da#19dc3dae78ee7e4dcde67881ab31af229ed133a2" +dependencies = [ + "bytes", + "flex-error", + "num-derive", + "num-traits 0.2.16", + "prost 0.12.0", + "prost-types 0.12.0", + "serde", + "serde_bytes", + "subtle-encoding", + "time 0.3.23", +] + [[package]] name = "term" version = "0.7.0" @@ -10419,6 +12675,15 @@ dependencies = [ "test-case-core", ] +[[package]] +name = "textwrap" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060" +dependencies = [ + "unicode-width", +] + [[package]] name = "thiserror" version = "1.0.48" @@ -10587,20 +12852,19 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.29.1" +version = "1.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "532826ff75199d5833b9d2c5fe410f29235e25704ee5f0ef599fb51c21f4a4da" +checksum = "17ed6077ed6cd6c74735e21f37eb16dc3935f96878b1fe961074089cc80893f9" dependencies = [ - "autocfg", "backtrace", "bytes", "libc", "mio", "num_cpus", "parking_lot 0.12.1", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "signal-hook-registry", - "socket2 0.4.9", + "socket2 0.5.3", "tokio-macros", "windows-sys 0.48.0", ] @@ -10616,6 +12880,16 @@ dependencies = [ "syn 2.0.28", ] +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + [[package]] name = "tokio-retry" version = "0.3.0" @@ -10655,11 +12929,26 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" dependencies = [ "futures-core", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "tokio", "tokio-util", ] +[[package]] +name = "tokio-tungstenite" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b2dbec703c26b00d74844519606ef15d09a7d6857860f84ad223dec002ddea2" +dependencies = [ + "futures-util", + "log", + "rustls 0.21.6", + "tokio", + "tokio-rustls 0.24.1", + "tungstenite", + "webpki-roots 0.23.1", +] + [[package]] name = "tokio-util" version = "0.7.8" @@ -10670,7 +12959,7 @@ dependencies = [ "futures-core", "futures-io", "futures-sink", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "tokio", "tracing", ] @@ -10724,6 +13013,10 @@ version = "0.4.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite 0.2.13", "tower-layer", "tower-service", "tracing", @@ -10742,7 +13035,7 @@ dependencies = [ "http", "http-body", "http-range-header", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "tower-layer", "tower-service", ] @@ -10767,7 +13060,7 @@ checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" dependencies = [ "cfg-if", "log", - "pin-project-lite 0.2.10", + "pin-project-lite 0.2.13", "tracing-attributes", "tracing-core", ] @@ -10839,7 +13132,7 @@ dependencies = [ "serde", "serde_json", "sharded-slab", - "smallvec", + "smallvec 1.11.0", "thread_local", "tracing", "tracing-core", @@ -10857,7 +13150,7 @@ dependencies = [ "hashbrown 0.13.2", "log", "rustc-hex", - "smallvec", + "smallvec 1.11.0", ] [[package]] @@ -10886,7 +13179,7 @@ dependencies = [ "ipnet", "lazy_static", "rand 0.8.5", - "smallvec", + "smallvec 1.11.0", "socket2 0.4.9", "thiserror", "tinyvec", @@ -10908,7 +13201,7 @@ dependencies = [ "lru-cache", "parking_lot 0.12.1", "resolv-conf", - "smallvec", + "smallvec 1.11.0", "thiserror", "tokio", "tracing", @@ -10927,7 +13220,7 @@ version = "0.10.0-dev" source = "git+https://github.com/paritytech/substrate?branch=polkadot-v0.9.43#5e49f6e44820affccaf517fd22af564f4b495d40" dependencies = [ "async-trait", - "clap", + "clap 4.4.2", "frame-remote-externalities", "frame-try-runtime", "hex", @@ -10941,19 +13234,19 @@ dependencies = [ "sp-api", "sp-consensus-aura", "sp-consensus-babe", - "sp-core", - "sp-debug-derive", - "sp-externalities", + "sp-core 7.0.0", + "sp-debug-derive 5.0.0", + "sp-externalities 0.13.0", "sp-inherents", - "sp-io", - "sp-keystore", + "sp-io 7.0.0", + "sp-keystore 0.13.0", "sp-rpc", - "sp-runtime", - "sp-state-machine", + "sp-runtime 7.0.0", + "sp-state-machine 0.13.0", "sp-timestamp", "sp-transaction-storage-proof", "sp-version", - "sp-weights", + "sp-weights 4.0.0", "substrate-rpc-client", "zstd 0.12.3+zstd.1.5.2", ] @@ -10964,6 +13257,26 @@ version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f4f195fd851901624eee5a58c4bb2b4f06399148fcd0ed336e6f1cb60a9881df" +[[package]] +name = "tungstenite" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e862a1c4128df0112ab625f55cd5c934bcb4312ba80b39ae4b4835a3fd58e649" +dependencies = [ + "byteorder", + "bytes", + "data-encoding", + "http", + "httparse", + "log", + "rand 0.8.5", + "rustls 0.21.6", + "sha1", + "thiserror", + "url", + "utf-8", +] + [[package]] name = "turn" version = "0.6.1" @@ -11019,6 +13332,12 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "unarray" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" + [[package]] name = "unescaper" version = "0.1.1" @@ -11116,12 +13435,28 @@ dependencies = [ "percent-encoding", ] +[[package]] +name = "utf-8" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" + [[package]] name = "utf8parse" version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +[[package]] +name = "uuid" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" +dependencies = [ + "getrandom 0.2.10", + "serde", +] + [[package]] name = "uuid" version = "1.4.0" @@ -11129,6 +13464,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d023da39d1fde5a8a3fe1f3e01ca9632ada0a63e9797de55a879d6e2236277be" dependencies = [ "getrandom 0.2.10", + "serde", ] [[package]] @@ -11143,6 +13479,12 @@ version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" +[[package]] +name = "vec_map" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bddf1187be692e79c5ffeab891132dfb0f236ed36a43c7ed39f1165ee20191" + [[package]] name = "version_check" version = "0.9.4" @@ -11290,8 +13632,8 @@ checksum = "87fef6d0d508f08334e0ab0e6877feb4c0ecb3956bcf2cb950699b22fedf3e9c" dependencies = [ "anyhow", "libc", - "strum", - "strum_macros", + "strum 0.24.1", + "strum_macros 0.24.3", "tempfile", "thiserror", "wasm-opt-cxx-sys", @@ -11744,7 +14086,7 @@ dependencies = [ "tokio", "turn", "url", - "uuid", + "uuid 1.4.0", "waitgroup", "webrtc-mdns", "webrtc-util", @@ -12099,6 +14441,25 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "ws_stream_wasm" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7999f5f4217fe3818726b66257a4475f71e74ffd190776ad053fa159e50737f5" +dependencies = [ + "async_io_stream", + "futures", + "js-sys", + "log", + "pharos", + "rustc_version 0.4.0", + "send_wrapper 0.6.0", + "thiserror", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", +] + [[package]] name = "wyz" version = "0.5.1" @@ -12202,6 +14563,12 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" +[[package]] +name = "yap" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2a7eb6d82a11e4d0b8e6bda8347169aff4ccd8235d039bba7c47482d977dcf7" + [[package]] name = "yasna" version = "0.5.2" @@ -12231,6 +14598,26 @@ dependencies = [ "syn 2.0.28", ] +[[package]] +name = "zip" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "760394e246e4c28189f19d488c058bf16f564016aefac5d32bb1f3b51d5e9261" +dependencies = [ + "aes 0.8.3", + "byteorder", + "bzip2", + "constant_time_eq 0.1.5", + "crc32fast", + "crossbeam-utils", + "flate2", + "hmac 0.12.1", + "pbkdf2 0.11.0", + "sha1", + "time 0.3.23", + "zstd 0.11.2+zstd.1.5.2", +] + [[package]] name = "zstd" version = "0.11.2+zstd.1.5.2" diff --git a/Cargo.toml b/Cargo.toml index 44f9f3bf6a..7931a28f9e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -122,6 +122,7 @@ mc-rpc = { path = "crates/client/rpc" } mc-rpc-core = { path = "crates/client/rpc-core" } mc-block-proposer = { path = "crates/client/block-proposer" } mc-transaction-pool = { path = "crates/client/transaction-pool" } +mc-data-availability = { path = "crates/client/data-availability" } # Madara runtime madara-runtime = { path = "crates/runtime" } diff --git a/crates/client/data-availability/Cargo.toml b/crates/client/data-availability/Cargo.toml new file mode 100644 index 0000000000..c040d10a85 --- /dev/null +++ b/crates/client/data-availability/Cargo.toml @@ -0,0 +1,57 @@ +[package] +name = "mc-data-availability" +version = "0.1.0" +description = "Starknet data availability." +homepage = "https://github.com/keep-starknet-strange/madara" +edition = "2021" +license = "MIT" +publish = false +repository = "https://github.com/keep-starknet-strange/madara" + +[package.metadata.docs.rs] +targets = ["x86_64-unknown-linux-gnu"] + +[dependencies] +anyhow = { workspace = true } +async-trait = { workspace = true } +clap = { workspace = true, features = ["derive"] } +futures = "0.3.21" +jsonrpsee = { version = "0.20.0", features = [ + "http-client", + "ws-client", + "macros", +] } +lazy_static = { workspace = true } +log = "0.4.19" +reqwest = { version = "0.11.18", features = ["blocking", "json"] } +serde = { workspace = true } +serde_json = { workspace = true } +thiserror = { workspace = true } +tokio = { version = "1", features = ["full"] } +url = "2.4.0" +uuid = { version = "1.4.0", features = ["v4", "serde"] } + +# Substrate +sc-client-api = { workspace = true } +sp-api = { workspace = true } +sp-blockchain = { workspace = true } +sp-core = { workspace = true } +sp-io = { workspace = true } +sp-runtime = { workspace = true } + +# Starknet +mc-db = { workspace = true, default-features = true } +mp-starknet = { workspace = true, default-features = true } +starknet_api = { workspace = true, default-features = true } + +# Ethereum +ethers = "2.0.7" + +# Avail subxt dependency +avail-subxt = { git = "https://github.com/availproject/avail", version = "0.3.0", branch = "develop" } +sp-keyring = { workspace = true } +subxt = "0.29" + +# Celestia +celestia-rpc = { git = "https://github.com/eigerco/celestia-node-rs" } +celestia-types = { git = "https://github.com/eigerco/celestia-node-rs" } diff --git a/crates/client/data-availability/src/avail/config.rs b/crates/client/data-availability/src/avail/config.rs new file mode 100644 index 0000000000..378caca379 --- /dev/null +++ b/crates/client/data-availability/src/avail/config.rs @@ -0,0 +1,61 @@ +use std::fs::File; +use std::path::PathBuf; + +use serde::Deserialize; + +use crate::DaMode; + +const DEFAULT_AVAIL_WS: &str = "wss://kate.avail.tools:443/ws"; +const DEFAULT_APP_ID: u32 = 0; +const DEFAULT_AVAIL_VALIDATE_CODEGEN: bool = true; +const DEFAULT_AVAIL_SEED: &str = "//Alice"; + +#[derive(Clone, PartialEq, Deserialize, Debug)] +pub struct AvailConfig { + #[serde(default = "default_ws")] + pub ws_provider: String, + #[serde(default = "default_app_id")] + pub app_id: u32, + #[serde(default = "default_validate_codegen")] + pub validate_codegen: bool, + #[serde(default = "default_seed")] + pub seed: String, + #[serde(default)] + pub mode: DaMode, +} + +impl TryFrom<&PathBuf> for AvailConfig { + type Error = String; + fn try_from(path: &PathBuf) -> Result { + let file = File::open(path).map_err(|e| format!("error opening da config: {e}"))?; + serde_json::from_reader(file).map_err(|e| format!("error parsing da config: {e}")) + } +} + +fn default_ws() -> String { + DEFAULT_AVAIL_WS.to_string() +} + +fn default_app_id() -> u32 { + DEFAULT_APP_ID +} + +fn default_validate_codegen() -> bool { + DEFAULT_AVAIL_VALIDATE_CODEGEN +} + +fn default_seed() -> String { + DEFAULT_AVAIL_SEED.to_string() +} + +impl Default for AvailConfig { + fn default() -> Self { + Self { + ws_provider: default_ws(), + app_id: default_app_id(), + mode: DaMode::default(), + validate_codegen: default_validate_codegen(), + seed: default_seed(), + } + } +} diff --git a/crates/client/data-availability/src/avail/mod.rs b/crates/client/data-availability/src/avail/mod.rs new file mode 100644 index 0000000000..88608a55ec --- /dev/null +++ b/crates/client/data-availability/src/avail/mod.rs @@ -0,0 +1,109 @@ +pub mod config; + +use anyhow::Result; +use async_trait::async_trait; +use avail_subxt::api::runtime_types::avail_core::AppId; +use avail_subxt::api::runtime_types::da_control::pallet::Call as DaCall; +use avail_subxt::api::runtime_types::sp_core::bounded::bounded_vec::BoundedVec; +use avail_subxt::avail::{AppUncheckedExtrinsic, Client as AvailSubxtClient}; +use avail_subxt::primitives::AvailExtrinsicParams; +use avail_subxt::{api as AvailApi, build_client, AvailConfig, Call}; +use ethers::types::{I256, U256}; +use sp_core::H256; +use subxt::ext::sp_core::sr25519::Pair; + +use crate::utils::get_bytes_from_state_diff; +use crate::{DaClient, DaMode}; + +type AvailPairSigner = subxt::tx::PairSigner; + +#[derive(Clone)] +pub struct AvailClient { + ws_client: AvailSubxtClient, + app_id: AppId, + signer: AvailPairSigner, + mode: DaMode, +} + +#[async_trait] +impl DaClient for AvailClient { + async fn publish_state_diff(&self, state_diff: Vec) -> Result<()> { + let bytes = get_bytes_from_state_diff(&state_diff); + let bytes = BoundedVec(bytes); + + let submitted_block_hash = self.publish_data(&bytes).await?; + + self.verify_bytes_inclusion(submitted_block_hash, &bytes).await?; + Ok(()) + } + + // state diff can be published w/o verification of last state for the time being + // may change in subsequent DaMode implementations + async fn last_published_state(&self) -> Result { + Ok(I256::from(1)) + } + + fn get_mode(&self) -> DaMode { + self.mode + } +} + +impl AvailClient { + async fn publish_data(&self, bytes: &BoundedVec) -> Result { + let data_transfer = AvailApi::tx().data_availability().submit_data(bytes.clone()); + let extrinsic_params = AvailExtrinsicParams::new_with_app_id(self.app_id); + let events = self + .ws_client + .tx() + .sign_and_submit_then_watch(&data_transfer, &self.signer, extrinsic_params) + .await? + .wait_for_finalized_success() + .await?; + + Ok(events.block_hash()) + } + + async fn verify_bytes_inclusion(&self, block_hash: H256, bytes: &BoundedVec) -> Result<()> { + let submitted_block = self + .ws_client + .rpc() + .block(Some(block_hash)) + .await? + .ok_or(anyhow::anyhow!("Invalid hash, block not found"))?; + + submitted_block + .block + .extrinsics + .into_iter() + .filter_map(|chain_block_ext| AppUncheckedExtrinsic::try_from(chain_block_ext).map(|ext| ext.function).ok()) + .find(|call| match call { + Call::DataAvailability(DaCall::submit_data { data }) => data == bytes, + _ => false, + }) + .ok_or(anyhow::anyhow!("Bytes not found in specified block"))?; + + Ok(()) + } +} + +impl TryFrom for AvailClient { + type Error = anyhow::Error; + + fn try_from(conf: config::AvailConfig) -> Result { + let signer = signer_from_seed(conf.seed.as_str())?; + + let app_id = AppId(conf.app_id); + + let ws_client = + futures::executor::block_on(async { build_client(conf.ws_provider.as_str(), conf.validate_codegen).await }) + .map_err(|e| anyhow::anyhow!("could not initialize ws endpoint {e}"))?; + + Ok(Self { ws_client, app_id, signer, mode: conf.mode }) + } +} + +fn signer_from_seed(seed: &str) -> Result { + let pair = ::from_string(seed, None)?; + let signer = AvailPairSigner::new(pair); + Ok(signer) +} diff --git a/crates/client/data-availability/src/celestia/config.rs b/crates/client/data-availability/src/celestia/config.rs new file mode 100644 index 0000000000..3b7d655bd4 --- /dev/null +++ b/crates/client/data-availability/src/celestia/config.rs @@ -0,0 +1,56 @@ +use std::fs::File; +use std::path::PathBuf; + +use serde::Deserialize; + +use crate::DaMode; + +pub const DEFAULT_CELESTIA_NODE: &str = "127.0.0.1:26658"; +pub const DEFAULT_NID: &str = "Madara"; + +#[derive(Clone, PartialEq, Deserialize, Debug)] +pub struct CelestiaConfig { + #[serde(default = "default_http")] + pub http_provider: String, + #[serde(default = "default_ws")] + pub ws_provider: String, + #[serde(default = "default_nid")] + pub nid: String, + #[serde(default)] + pub auth_token: Option, + #[serde(default)] + pub mode: DaMode, +} + +impl TryFrom<&PathBuf> for CelestiaConfig { + type Error = String; + + fn try_from(path: &PathBuf) -> Result { + let file = File::open(path).map_err(|e| format!("error opening da config: {e}"))?; + serde_json::from_reader(file).map_err(|e| format!("error parsing da config: {e}")) + } +} + +fn default_http() -> String { + format!("http://{DEFAULT_CELESTIA_NODE}") +} + +fn default_ws() -> String { + format!("ws://{DEFAULT_CELESTIA_NODE}") +} + +fn default_nid() -> String { + DEFAULT_NID.to_string() +} + +impl Default for CelestiaConfig { + fn default() -> Self { + Self { + http_provider: default_http(), + ws_provider: default_ws(), + nid: default_nid(), + mode: DaMode::default(), + auth_token: None, + } + } +} diff --git a/crates/client/data-availability/src/celestia/mod.rs b/crates/client/data-availability/src/celestia/mod.rs new file mode 100644 index 0000000000..a13ae3a39a --- /dev/null +++ b/crates/client/data-availability/src/celestia/mod.rs @@ -0,0 +1,89 @@ +pub mod config; + +use anyhow::Result; +use async_trait::async_trait; +use celestia_rpc::client::new_http; +use celestia_rpc::{BlobClient, HeaderClient}; +use celestia_types::nmt::Namespace; +use celestia_types::{Blob, Result as CelestiaTypesResult}; +use ethers::types::{I256, U256}; +use jsonrpsee::http_client::HttpClient; + +use crate::{DaClient, DaMode}; + +#[derive(Clone, Debug)] +pub struct CelestiaClient { + http_client: HttpClient, + nid: Namespace, + mode: DaMode, +} + +#[async_trait] +impl DaClient for CelestiaClient { + async fn publish_state_diff(&self, state_diff: Vec) -> Result<()> { + let blob = self.get_blob_from_state_diff(state_diff).map_err(|e| anyhow::anyhow!("celestia error: {e}"))?; + let submitted_height = self.publish_data(&blob).await.map_err(|e| anyhow::anyhow!("celestia error: {e}"))?; + + // blocking call, awaiting on server side (Celestia Node) that a block with our data is included + self.http_client + .header_wait_for_height(submitted_height) + .await + .map_err(|e| anyhow::anyhow!("celestia da error: {e}"))?; + + self.verify_blob_was_included(submitted_height, blob) + .await + .map_err(|e| anyhow::anyhow!("celestia error: {e}"))?; + + Ok(()) + } + + async fn last_published_state(&self) -> Result { + Ok(I256::from(1)) + } + + fn get_mode(&self) -> DaMode { + self.mode + } +} + +impl CelestiaClient { + async fn publish_data(&self, blob: &Blob) -> Result { + self.http_client.blob_submit(&[blob.clone()]).await.map_err(|e| anyhow::anyhow!("could not submit blob {e}")) + } + + fn get_blob_from_state_diff(&self, state_diff: Vec) -> CelestiaTypesResult { + let state_diff_bytes: Vec = state_diff + .iter() + .flat_map(|item| { + let mut bytes = [0_u8; 32]; + item.to_big_endian(&mut bytes); + bytes.to_vec() + }) + .collect(); + + Blob::new(self.nid, state_diff_bytes) + } + + async fn verify_blob_was_included(&self, submitted_height: u64, blob: Blob) -> Result<()> { + let received_blob = self.http_client.blob_get(submitted_height, self.nid, blob.commitment).await.unwrap(); + received_blob.validate()?; + Ok(()) + } +} + +impl TryFrom for CelestiaClient { + type Error = anyhow::Error; + + fn try_from(conf: config::CelestiaConfig) -> Result { + let http_client = new_http(conf.http_provider.as_str(), conf.auth_token.as_deref()) + .map_err(|e| anyhow::anyhow!("could not init http client: {e}"))?; + + // Convert the input string to bytes + let bytes = conf.nid.as_bytes(); + + // Create a new Namespace from these bytes + let nid = Namespace::new_v0(bytes).map_err(|e| anyhow::anyhow!("could not init namespace: {e}"))?; + + Ok(Self { http_client, nid, mode: conf.mode }) + } +} diff --git a/crates/client/data-availability/src/ethereum/config.rs b/crates/client/data-availability/src/ethereum/config.rs new file mode 100644 index 0000000000..19ecf520a2 --- /dev/null +++ b/crates/client/data-availability/src/ethereum/config.rs @@ -0,0 +1,65 @@ +use std::fs::File; +use std::path::PathBuf; + +use serde::Deserialize; + +use crate::DaMode; + +pub const DEFAULT_ETHEREUM_NODE: &str = "127.0.0.1:8545"; +// default key derived from starting anvil as follows: +// anvil -b 5 --config-out $BUILD_DIR/anvil.json +// PRE_PRIVATE=$(jq -r '.private_keys[0]' $BUILD_DIR/anvil.json) +pub const DEFAULT_SEQUENCER_KEY: &str = "ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"; +pub const DEFAULT_STARKNET_CORE_CONTRACTS: &str = "0x5FbDB2315678afecb367f032d93F642f64180aa3"; +pub const DEFAULT_CHAIN_ID: u64 = 31337; + +#[derive(Clone, PartialEq, Deserialize, Debug)] +pub struct EthereumConfig { + #[serde(default = "default_http")] + pub http_provider: String, + #[serde(default = "default_core_contracts")] + pub core_contracts: String, + #[serde(default = "default_sequencer_key")] + pub sequencer_key: String, + #[serde(default = "default_chain_id")] + pub chain_id: u64, + #[serde(default)] + pub mode: DaMode, +} + +impl TryFrom<&PathBuf> for EthereumConfig { + type Error = String; + + fn try_from(path: &PathBuf) -> Result { + let file = File::open(path).map_err(|e| format!("error opening da config: {e}"))?; + serde_json::from_reader(file).map_err(|e| format!("error parsing da config: {e}")) + } +} + +fn default_http() -> String { + format!("http://{DEFAULT_ETHEREUM_NODE}") +} + +fn default_core_contracts() -> String { + DEFAULT_STARKNET_CORE_CONTRACTS.to_string() +} + +fn default_sequencer_key() -> String { + DEFAULT_SEQUENCER_KEY.to_string() +} + +fn default_chain_id() -> u64 { + DEFAULT_CHAIN_ID +} + +impl Default for EthereumConfig { + fn default() -> Self { + Self { + http_provider: default_http(), + mode: DaMode::default(), + core_contracts: default_core_contracts(), + sequencer_key: default_sequencer_key(), + chain_id: default_chain_id(), + } + } +} diff --git a/crates/client/data-availability/src/ethereum/mod.rs b/crates/client/data-availability/src/ethereum/mod.rs new file mode 100644 index 0000000000..f7b7ee0a1e --- /dev/null +++ b/crates/client/data-availability/src/ethereum/mod.rs @@ -0,0 +1,86 @@ +pub mod config; + +use std::sync::Arc; + +use anyhow::Result; +use async_trait::async_trait; +use ethers::prelude::{abigen, SignerMiddleware}; +use ethers::providers::{Http, Provider}; +use ethers::signers::{LocalWallet, Signer}; +use ethers::types::{Address, I256, U256}; + +use crate::utils::is_valid_http_endpoint; +use crate::{DaClient, DaMode}; + +#[derive(Clone, Debug)] +pub struct EthereumClient { + http_provider: Provider, + signer: Arc, LocalWallet>>, + cc_address: Address, + mode: DaMode, +} + +#[async_trait] +impl DaClient for EthereumClient { + async fn publish_state_diff(&self, state_diff: Vec) -> Result<()> { + abigen!( + STARKNET, + r#"[ + function updateState(uint256[] calldata programOutput, uint256 onchainDataHash, uint256 onchainDataSize) external + ]"#, + ); + + let core_contracts = STARKNET::new(self.cc_address, self.signer.clone()); + + let fmt_tx = core_contracts.update_state(state_diff, U256::default(), U256::default()); + let tx = fmt_tx + .send() + .await + .map_err(|e| anyhow::anyhow!("ethereum send update err: {e}"))? + .await + .map_err(|e| anyhow::anyhow!("ethereum poll update err: {e}"))?; + + log::info!("State Update: {:?}", tx); + Ok(()) + } + + async fn last_published_state(&self) -> Result { + abigen!( + STARKNET, + r#"[ + function stateBlockNumber() external view returns (int256) + ]"#, + ); + + let contract = STARKNET::new(self.cc_address, self.http_provider.clone().into()); + contract.state_block_number().call().await.map_err(|e| anyhow::anyhow!("ethereum contract err: {e}")) + } + + fn get_mode(&self) -> DaMode { + self.mode + } +} + +impl TryFrom for EthereumClient { + type Error = String; + + fn try_from(conf: config::EthereumConfig) -> Result { + if !is_valid_http_endpoint(&conf.http_provider) { + return Err(format!("invalid http endpoint, received {}", &conf.http_provider)); + } + + let provider = Provider::::try_from(conf.http_provider).map_err(|e| format!("ethereum error: {e}"))?; + + let wallet: LocalWallet = conf + .sequencer_key + .parse::() + .map_err(|e| format!("ethereum error: {e}"))? + .with_chain_id(conf.chain_id); + + let signer = Arc::new(SignerMiddleware::new(provider.clone(), wallet)); + + let cc_address: Address = conf.core_contracts.parse().map_err(|e| format!("ethereum error: {e}"))?; + + Ok(Self { http_provider: provider, signer, cc_address, mode: conf.mode }) + } +} diff --git a/crates/client/data-availability/src/lib.rs b/crates/client/data-availability/src/lib.rs new file mode 100644 index 0000000000..83e94d5d78 --- /dev/null +++ b/crates/client/data-availability/src/lib.rs @@ -0,0 +1,190 @@ +pub mod avail; +pub mod celestia; +pub mod ethereum; +mod sharp; +pub mod utils; + +use std::collections::HashMap; +use std::marker::PhantomData; +use std::sync::Arc; + +use anyhow::Result; +use async_trait::async_trait; +use ethers::types::{I256, U256}; +use futures::StreamExt; +use sc_client_api::client::BlockchainEvents; +use serde::Deserialize; +use sp_api::ProvideRuntimeApi; +use sp_runtime::traits::Block as BlockT; + +pub type StorageWrites<'a> = Vec<(&'a [u8], &'a [u8])>; + +pub struct DataAvailabilityWorker(PhantomData<(B, C)>); + +#[derive(Debug, Copy, Clone, PartialEq, clap::ValueEnum)] +pub enum DaLayer { + Celestia, + Ethereum, + Avail, +} + +/// Data availability modes in which Madara can be initialized. +/// +/// Default only mode currently implemented is Validium. +#[derive(Debug, Copy, Clone, PartialEq, Deserialize, Default)] +pub enum DaMode { + /// Full Validity Rollup + /// + /// Generates a Cairo execution trace of the StarknetOS + /// run for the given block as it is applied to the current Madara state. + /// Once this execution trace is proved to the L1 Verifier(i.e. [Ethereum](https://goerli.etherscan.io/address/0x8f97970aC5a9aa8D130d35146F5b59c4aef57963)) + /// the relevant [state diff](https://docs.starknet.io/documentation/architecture_and_concepts/Network_Architecture/on-chain-data) can be written and validated against the on-chain + /// proof verification of the block propogation. + #[serde(rename = "validity")] + Validity, + /// Hybrid Volition + /// + /// Volitions allow applications and users to interoperate between on-chain data and off-chain + /// da. Although full specs are not currently available, this mode will entail generating + /// a StarknetOS execution trace for data elected to be on-chain and interaction w/ the prover + /// will be necessary. + #[serde(rename = "volition")] + Volition, + /// Sovereign Validium + /// + /// Validium state diffs are untethered to an accompanying validity proof therefore + /// they can simply be published to any da solution available. As this solution does not + /// require an execution trace to be proved we can simply parse the state diff from the + /// storage changes of the block. + #[serde(rename = "validium")] + #[default] + Validium, +} + +#[async_trait] +pub trait DaClient: Send + Sync { + fn get_mode(&self) -> DaMode; + async fn last_published_state(&self) -> Result; + async fn publish_state_diff(&self, state_diff: Vec) -> Result<()>; +} + +impl DataAvailabilityWorker +where + B: BlockT, + C: ProvideRuntimeApi, + C: BlockchainEvents + 'static, +{ + pub async fn prove_current_block(da_mode: DaMode, client: Arc, madara_backend: Arc>) { + let mut storage_event_st = client + .storage_changes_notification_stream(None, None) + .expect("node has been initialized to prove state change, but can't read from notification stream"); + + while let Some(storage_event) = storage_event_st.next().await { + // Locate and encode the storage change + let mut nonces: HashMap<&[u8], &[u8]> = HashMap::new(); + let mut storage_diffs: HashMap<&[u8], StorageWrites> = HashMap::new(); + + // Locate and encode the storage change + for event in storage_event.changes.iter() { + let mut prefix = event.1.0.as_slice(); + let mut key: &[u8] = &[]; + if prefix.len() > 32 { + let raw_split = prefix.split_at(32); + prefix = raw_split.0; + key = raw_split.1; + } + + if prefix == *utils::SN_NONCE_PREFIX { + if let Some(data) = event.2 { + nonces.insert(key, data.0.as_slice()); + } + } + + if prefix == *utils::SN_STORAGE_PREFIX { + if let Some(data) = event.2 { + // first 32 bytes = contract address, second 32 bytes = storage variable + let write_split = key.split_at(32); + + storage_diffs + .entry(write_split.0) + .and_modify(|v| v.push((write_split.1, data.0.as_slice()))) + .or_insert(vec![(write_split.1, data.0.as_slice())]); + } + } + } + + let state_diff = utils::pre_0_11_0_state_diff(storage_diffs, nonces); + + // Store the DA output from the SN OS + if let Err(db_err) = madara_backend.da().store_state_diff(&storage_event.block, state_diff) { + log::error!("db err: {db_err}"); + }; + + match da_mode { + DaMode::Validity => { + // Submit the StarkNet OS PIE + // TODO: Validity Impl + // run the Starknet OS with the Cairo VM + // extract the PIE from the Cairo VM run + // pass the PIE to `submit_pie` and zip/base64 internal + if let Ok(job_resp) = sharp::submit_pie("TODO") { + log::info!("Job Submitted: {}", job_resp.cairo_job_key); + // Store the cairo job key + if let Err(db_err) = + madara_backend.da().update_cairo_job(&storage_event.block, job_resp.cairo_job_key) + { + log::error!("db err: {db_err}"); + }; + } + } + _ => { + log::info!("don't prove in remaining DA modes") + } + } + } + } +} + +impl DataAvailabilityWorker +where + B: BlockT, + C: ProvideRuntimeApi, + C: BlockchainEvents + 'static, +{ + pub async fn update_state( + da_client: Box, + client: Arc, + madara_backend: Arc>, + ) { + let mut notification_st = client.import_notification_stream(); + + while let Some(notification) = notification_st.next().await { + // Query last written state + // TODO: this value will be used to ensure the correct state diff is being written in Validity mode + let _last_published_state = match da_client.last_published_state().await { + Ok(last_published_state) => last_published_state, + Err(e) => { + log::error!("da provider error: {e}"); + continue; + } + }; + + match da_client.get_mode() { + DaMode::Validity => { + // Check the SHARP status of last_proved + 1 + // Write the publish state diff of last_proved + 1 + log::info!("validity da mode not implemented"); + } + DaMode::Validium => match madara_backend.da().state_diff(¬ification.hash) { + Ok(state_diff) => { + if let Err(e) = da_client.publish_state_diff(state_diff).await { + log::error!("DA PUBLISH ERROR: {}", e); + } + } + Err(e) => log::error!("could not pull state diff: {e}"), + }, + DaMode::Volition => log::info!("volition da mode not implemented"), + } + } + } +} diff --git a/crates/client/data-availability/src/sharp/mod.rs b/crates/client/data-availability/src/sharp/mod.rs new file mode 100644 index 0000000000..845a103581 --- /dev/null +++ b/crates/client/data-availability/src/sharp/mod.rs @@ -0,0 +1,83 @@ +use anyhow::Result; +use serde::Deserialize; +use uuid::Uuid; + +#[allow(dead_code)] +pub const LAMBDA_URL: &str = "https://testnet.provingservice.io"; +pub const _LAMBDA_MAX_PIE_MB: u64 = 20_971_520; + +#[derive(Debug)] +#[allow(dead_code)] +pub enum CairoJobStatus { + Unknown, + NotCreated, + InProgress, + Processed, + Onchain, + Invalid, + Failed, +} + +#[allow(dead_code)] +impl CairoJobStatus { + fn as_str(&self) -> &'static str { + match self { + CairoJobStatus::Unknown => "UNKNOWN", + CairoJobStatus::NotCreated => "NOT_CREATED", + CairoJobStatus::InProgress => "IN_PROGRESS", + CairoJobStatus::Processed => "PROCESSED", + CairoJobStatus::Onchain => "ONCHAIN", + CairoJobStatus::Invalid => "INVALID", + CairoJobStatus::Failed => "FAILED", + } + } +} + +#[derive(Default, Debug, Clone, PartialEq, Deserialize)] +pub struct CairoJobResponse { + pub cairo_job_key: Uuid, + pub version: u64, +} + +// Send zipped CairoPie to SHARP +// - PIE Submission format base64.b64encode(cairo_pie.serialize()).decode("ascii") +pub fn submit_pie(pie: &str) -> Result { + let data = serde_json::json!({ "cairo_pie": pie }); + let data = serde_json::json!({ "action": "add_job", "request": data }); + let _payload: serde_json::Value = serde_json::from_value(data).unwrap(); + + // CAREFUL NOT TO OVERWHELM SHARP DUE TO SHORT BLOCK TIMES + // TODO: uncomment w/ Validity DaMode impl + // let resp = reqwest::blocking::Client::new().post(LAMBDA_URL).json(&payload).send().unwrap(); + + // match resp.status() { + // reqwest::StatusCode::OK => Ok(resp.json::().unwrap()), + // _ => Err(String::from("could not submit pie")), + // } + + Ok(CairoJobResponse { cairo_job_key: Uuid::new_v4(), version: 1_u64 }) +} + +#[derive(Default, Debug, Clone, PartialEq, Deserialize)] +#[serde(rename_all = "camelCase")] +pub struct CairoStatusResponse { + pub status: Option, + #[serde(rename = "validation_done")] + pub validation_done: Option, + pub version: Option, +} + +// Fetch Cairo Job Status from SHARP +// TODO: function will be needed in Validity DaMode impl +fn _get_status(job_key: &str) -> Result { + let data = serde_json::json!({ "cairo_job_key": job_key }); + let data = serde_json::json!({ "action": "get_status", "request": data }); + let payload: serde_json::Value = serde_json::from_value(data).unwrap(); + + let resp = reqwest::blocking::Client::new().post(LAMBDA_URL).json(&payload).send().unwrap(); + + match resp.status() { + reqwest::StatusCode::OK => Ok(resp.json::().unwrap()), + _ => Err(anyhow::anyhow!("could not get job status")), + } +} diff --git a/crates/client/data-availability/src/utils.rs b/crates/client/data-availability/src/utils.rs new file mode 100644 index 0000000000..2c4e62c49c --- /dev/null +++ b/crates/client/data-availability/src/utils.rs @@ -0,0 +1,69 @@ +use std::collections::HashMap; + +use ethers::types::U256; +use lazy_static::lazy_static; +use mp_starknet::storage::{ + PALLET_STARKNET, STARKNET_CONTRACT_CLASS, STARKNET_CONTRACT_CLASS_HASH, STARKNET_NONCE, STARKNET_STORAGE, +}; +use sp_io::hashing::twox_128; +use url::{ParseError, Url}; + +lazy_static! { + pub static ref SN_NONCE_PREFIX: Vec = [twox_128(PALLET_STARKNET), twox_128(STARKNET_NONCE)].concat(); + pub static ref SN_CONTRACT_CLASS_HASH_PREFIX: Vec = + [twox_128(PALLET_STARKNET), twox_128(STARKNET_CONTRACT_CLASS_HASH)].concat(); + pub static ref SN_CONTRACT_CLASS_PREFIX: Vec = + [twox_128(PALLET_STARKNET), twox_128(STARKNET_CONTRACT_CLASS)].concat(); + pub static ref SN_STORAGE_PREFIX: Vec = [twox_128(PALLET_STARKNET), twox_128(STARKNET_STORAGE)].concat(); +} + +// encode calldata: +// - https://docs.starknet.io/documentation/architecture_and_concepts/Data_Availability/on-chain-data/#pre_v0.11.0_example +pub fn pre_0_11_0_state_diff( + storage_diffs: HashMap<&[u8], crate::StorageWrites>, + nonces: HashMap<&[u8], &[u8]>, +) -> Vec { + let mut state_diff: Vec = Vec::new(); + + state_diff.push(U256::from(storage_diffs.len())); + + for (addr, writes) in storage_diffs { + state_diff.push(U256::from_big_endian(addr)); + state_diff.push(U256::from(writes.len())); + for write in writes { + state_diff.push(U256::from_big_endian(write.0)); + state_diff.push(U256::from_big_endian(write.1)); + } + } + + for (addr, nonce) in nonces { + state_diff.push(U256::from_big_endian(addr)); + state_diff.push(U256::from_big_endian(nonce)); + } + state_diff +} + +pub fn get_bytes_from_state_diff(state_diff: &[U256]) -> Vec { + let state_diff_bytes: Vec = state_diff + .iter() + .flat_map(|item| { + let mut bytes = [0_u8; 32]; + item.to_big_endian(&mut bytes); + bytes.to_vec() + }) + .collect(); + + state_diff_bytes +} + +pub fn get_valid_url(endpoint: &str) -> Result { + Url::parse(endpoint) +} + +pub fn is_valid_ws_endpoint(endpoint: &str) -> bool { + if let Ok(url) = get_valid_url(endpoint) { matches!(url.scheme(), "ws" | "wss") } else { false } +} + +pub fn is_valid_http_endpoint(endpoint: &str) -> bool { + if let Ok(url) = get_valid_url(endpoint) { matches!(url.scheme(), "http" | "https") } else { false } +} diff --git a/crates/client/db/Cargo.toml b/crates/client/db/Cargo.toml index f9d7302163..2785dd0945 100644 --- a/crates/client/db/Cargo.toml +++ b/crates/client/db/Cargo.toml @@ -16,6 +16,7 @@ repository = "https://github.com/keep-starknet-strange/madara" targets = ["x86_64-unknown-linux-gnu"] [dependencies] +ethers = "2.0.7" kvdb-rocksdb = { version = "0.19.0", optional = true } log = { workspace = true, default-features = true } parity-db = { version = "0.4.10", optional = true } @@ -26,7 +27,7 @@ scale-codec = { workspace = true, default-features = true, features = [ sp-core = { workspace = true, default-features = true } sp-database = { workspace = true, default-features = true } sp-runtime = { workspace = true, default-features = true } - +uuid = "1.4.0" [features] default = ["kvdb-rocksdb", "parity-db"] diff --git a/crates/client/db/src/da_db.rs b/crates/client/db/src/da_db.rs new file mode 100644 index 0000000000..3bb68046f9 --- /dev/null +++ b/crates/client/db/src/da_db.rs @@ -0,0 +1,71 @@ +use std::marker::PhantomData; +use std::sync::Arc; + +use ethers::types::U256; +// Substrate +use scale_codec::{Decode, Encode}; +use sp_database::Database; +use sp_runtime::traits::Block as BlockT; +use uuid::Uuid; + +use crate::DbHash; + +// The fact db stores DA facts that need to be written to L1 +pub struct DaDb { + pub(crate) db: Arc>, + pub(crate) _marker: PhantomData, +} + +// TODO: purge old cairo job keys +impl DaDb { + pub fn state_diff(&self, block_hash: &B::Hash) -> Result, String> { + match self.db.get(crate::columns::DA, &block_hash.encode()) { + Some(raw) => Ok(Vec::::decode(&mut &raw[..]).map_err(|e| format!("{:?}", e))?), + None => Ok(Vec::new()), + } + } + + pub fn store_state_diff(&self, block_hash: &B::Hash, diffs: Vec) -> Result<(), String> { + let mut transaction = sp_database::Transaction::new(); + + transaction.set(crate::columns::DA, &block_hash.encode(), &diffs.encode()); + + self.db.commit(transaction).map_err(|e| format!("{:?}", e))?; + + Ok(()) + } + + pub fn cairo_job(&self, block_hash: &B::Hash) -> Result { + match self.db.get(crate::columns::DA, &block_hash.encode()) { + Some(raw) => Ok(Uuid::from_slice(&raw[..]).map_err(|e| format!("{:?}", e))?), + None => Err(String::from("can't locate cairo job")), + } + } + + pub fn update_cairo_job(&self, block_hash: &B::Hash, job_id: Uuid) -> Result<(), String> { + let mut transaction = sp_database::Transaction::new(); + + transaction.set(crate::columns::DA, &block_hash.encode(), &job_id.into_bytes()); + + self.db.commit(transaction).map_err(|e| format!("{:?}", e))?; + + Ok(()) + } + + pub fn last_proved_block(&self) -> Result { + match self.db.get(crate::columns::DA, crate::static_keys::LAST_PROVED_BLOCK) { + Some(raw) => Ok(B::Hash::decode(&mut &raw[..]).map_err(|e| format!("{:?}", e))?), + None => Err(String::from("can't locate last proved block")), + } + } + + pub fn update_last_proved_block(&self, block_hash: &B::Hash) -> Result<(), String> { + let mut transaction = sp_database::Transaction::new(); + + transaction.set(crate::columns::DA, crate::static_keys::LAST_PROVED_BLOCK, &block_hash.encode()); + + self.db.commit(transaction).map_err(|e| format!("{:?}", e))?; + + Ok(()) + } +} diff --git a/crates/client/db/src/lib.rs b/crates/client/db/src/lib.rs index 82cf026f54..5414e0af79 100644 --- a/crates/client/db/src/lib.rs +++ b/crates/client/db/src/lib.rs @@ -13,6 +13,7 @@ mod mapping_db; pub use mapping_db::MappingCommitment; +mod da_db; mod db_opening_utils; mod meta_db; @@ -20,6 +21,7 @@ use std::marker::PhantomData; use std::path::{Path, PathBuf}; use std::sync::{Arc, Mutex}; +use da_db::DaDb; use mapping_db::MappingDb; use meta_db::MetaDb; use sc_client_db::DatabaseSource; @@ -36,16 +38,18 @@ struct DatabaseSettings { } pub(crate) mod columns { - pub const NUM_COLUMNS: u32 = 4; + pub const NUM_COLUMNS: u32 = 5; pub const META: u32 = 0; pub const BLOCK_MAPPING: u32 = 1; pub const TRANSACTION_MAPPING: u32 = 2; pub const SYNCED_MAPPING: u32 = 3; + pub const DA: u32 = 4; } pub mod static_keys { pub const CURRENT_SYNCING_TIPS: &[u8] = b"CURRENT_SYNCING_TIPS"; + pub const LAST_PROVED_BLOCK: &[u8] = b"LAST_PROVED_BLOCK"; } /// The Madara client database backend @@ -56,6 +60,7 @@ pub mod static_keys { pub struct Backend { meta: Arc>, mapping: Arc>, + da: Arc>, } /// Returns the Starknet database directory. @@ -92,6 +97,7 @@ impl Backend { Ok(Self { mapping: Arc::new(MappingDb { db: db.clone(), write_lock: Arc::new(Mutex::new(())), _marker: PhantomData }), meta: Arc::new(MetaDb { db: db.clone(), _marker: PhantomData }), + da: Arc::new(DaDb { db: db.clone(), _marker: PhantomData }), }) } @@ -104,4 +110,9 @@ impl Backend { pub fn meta(&self) -> &Arc> { &self.meta } + + /// Return the da database manager + pub fn da(&self) -> &Arc> { + &self.da + } } diff --git a/crates/node/Cargo.toml b/crates/node/Cargo.toml index 07d3369901..d90207e519 100644 --- a/crates/node/Cargo.toml +++ b/crates/node/Cargo.toml @@ -75,6 +75,7 @@ blockifier = { workspace = true } hex = { workspace = true } madara-runtime = { workspace = true } mc-block-proposer = { workspace = true } +mc-data-availability = { workspace = true } mc-db = { workspace = true } mc-mapping-sync = { workspace = true } mc-rpc = { workspace = true } diff --git a/crates/node/src/cli.rs b/crates/node/src/cli.rs index f8253224b5..e56c44cb16 100644 --- a/crates/node/src/cli.rs +++ b/crates/node/src/cli.rs @@ -1,5 +1,6 @@ use std::path::PathBuf; +use mc_data_availability::DaLayer; use sc_cli::RunCmd; /// Available Sealing methods. @@ -47,6 +48,9 @@ pub struct ExtendedRunCmd { #[clap(long)] pub genesis_url: Option, + + #[clap(long)] + pub da_layer: Option, } #[allow(clippy::large_enum_variant)] diff --git a/crates/node/src/command.rs b/crates/node/src/command.rs index 7cd1c8a49d..ae9abc0ea8 100644 --- a/crates/node/src/command.rs +++ b/crates/node/src/command.rs @@ -1,5 +1,8 @@ +use std::path::PathBuf; + use frame_benchmarking_cli::{BenchmarkCmd, ExtrinsicFactory, SUBSTRATE_REFERENCE_HARDWARE}; use madara_runtime::Block; +use mc_data_availability::DaLayer; use pallet_starknet::utils; use sc_cli::{ChainSpec, RpcMethods, RuntimeVersion, SubstrateCli}; @@ -265,16 +268,33 @@ pub fn run() -> sc_cli::Result<()> { )?; } - cli.run.run_cmd.shared_params.chain = Some(madara_path + "/chain-specs/testnet-sharingan-raw.json"); + cli.run.run_cmd.shared_params.chain = + Some(madara_path.clone() + "/chain-specs/testnet-sharingan-raw.json"); // This should go apply to all testnets when applying a match pattern cli.run.run_cmd.rpc_external = true; cli.run.run_cmd.rpc_methods = RpcMethods::Unsafe; } + let da_config: Option<(DaLayer, PathBuf)> = match cli.run.da_layer { + Some(da_layer) => { + let da_path = std::path::PathBuf::from(madara_path.clone() + "/da-config.json"); + if !da_path.exists() { + log::info!("{} does not contain DA config", madara_path); + return Err("DA config not available".into()); + } + + Some((da_layer, da_path)) + } + None => { + log::info!("madara initialized w/o da layer"); + None + } + }; + let runner = cli.create_runner(&cli.run.run_cmd)?; runner.run_node_until_exit(|config| async move { - service::new_full(config, cli.sealing).map_err(sc_cli::Error::Service) + service::new_full(config, cli.sealing, da_config).map_err(sc_cli::Error::Service) }) } } diff --git a/crates/node/src/service.rs b/crates/node/src/service.rs index 39cfaf1962..4ff2267ea9 100644 --- a/crates/node/src/service.rs +++ b/crates/node/src/service.rs @@ -1,6 +1,7 @@ //! Service and ServiceFactory implementation. Specialized wrapper over substrate service. use std::cell::RefCell; +use std::path::PathBuf; use std::sync::Arc; use std::time::Duration; @@ -10,6 +11,13 @@ use futures::prelude::*; use madara_runtime::opaque::Block; use madara_runtime::{self, Hash, RuntimeApi}; use mc_block_proposer::ProposerFactory; +use mc_data_availability::avail::config::AvailConfig; +use mc_data_availability::avail::AvailClient; +use mc_data_availability::celestia::config::CelestiaConfig; +use mc_data_availability::celestia::CelestiaClient; +use mc_data_availability::ethereum::config::EthereumConfig; +use mc_data_availability::ethereum::EthereumClient; +use mc_data_availability::{DaClient, DaLayer, DataAvailabilityWorker}; use mc_mapping_sync::MappingSyncWorker; use mc_storage::overrides_handle; use mc_transaction_pool::FullPool; @@ -244,7 +252,11 @@ where } /// Builds a new service for a full client. -pub fn new_full(config: Configuration, sealing: Option) -> Result { +pub fn new_full( + config: Configuration, + sealing: Option, + da_layer: Option<(DaLayer, PathBuf)>, +) -> Result { let build_import_queue = if sealing.is_some() { build_manual_seal_import_queue } else { build_aura_grandpa_import_queue }; @@ -361,7 +373,7 @@ pub fn new_full(config: Configuration, sealing: Option) -> Result) -> Result = match da_layer { + DaLayer::Celestia => { + let celestia_conf = CelestiaConfig::try_from(&da_path)?; + Box::new(CelestiaClient::try_from(celestia_conf).map_err(|e| ServiceError::Other(e.to_string()))?) + } + DaLayer::Ethereum => { + let ethereum_conf = EthereumConfig::try_from(&da_path)?; + Box::new(EthereumClient::try_from(ethereum_conf)?) + } + DaLayer::Avail => { + let avail_conf = AvailConfig::try_from(&da_path)?; + Box::new(AvailClient::try_from(avail_conf).map_err(|e| ServiceError::Other(e.to_string()))?) + } + }; + + task_manager.spawn_essential_handle().spawn( + "da-worker-prove", + Some("madara"), + DataAvailabilityWorker::prove_current_block(da_client.get_mode(), client.clone(), madara_backend.clone()), + ); + task_manager.spawn_essential_handle().spawn( + "da-worker-update", + Some("madara"), + DataAvailabilityWorker::update_state(da_client, client.clone(), madara_backend), + ); + }; + if role.is_authority() { // manual-seal authorship if let Some(sealing) = sealing { diff --git a/examples/rpc/starknet/starknet_addInvokeTransaction.hurl b/examples/rpc/starknet/starknet_addInvokeTransaction.hurl index 5d203fc538..39a6fd6b70 100644 --- a/examples/rpc/starknet/starknet_addInvokeTransaction.hurl +++ b/examples/rpc/starknet/starknet_addInvokeTransaction.hurl @@ -8,7 +8,7 @@ Content-Type: application/json "type": "INVOKE", "max_fee":"0xDEADB", "version":"0x1", - "nonce":"0x0", + "nonce":"0x1", "signature":[ "0x0", "0x0" diff --git a/scripts/da_devnet.sh b/scripts/da_devnet.sh new file mode 100755 index 0000000000..ca2f833ddc --- /dev/null +++ b/scripts/da_devnet.sh @@ -0,0 +1,76 @@ +#!/bin/bash + +# [ethereum, celestia, avail] +DA_LAYER=$1 +MADARA_PATH=$2 + +if [ -z $MADARA_PATH ]; then + MADARA_PATH="$HOME/.madara" +fi + +if [ ! -f "$MADARA_PATH/da-config.json" ]; then + echo "{}" > $MADARA_PATH/da-config.json +fi + +cargo build --release + +if [ "$DA_LAYER" = "ethereum" ]; then + echo "Ethereum DA Test:" + # TODO: do we want to add zaun as submodule + git clone --recurse-submodules https://github.com/keep-starknet-strange/zaun.git target/zaun 2> /dev/null + ./target/zaun/scripts/sn-base-dev.sh target target/zaun 2> /dev/null + + echo -e "\t anvil logs -> target/anvil.log" + echo -e "\t to kill anvil -> ./target/zaun/scripts/sn-base-kill.sh target" +elif [ "$DA_LAYER" = "celestia" ]; then + if ! command -v celestia > /dev/null + then + echo "please install jq" + exit 1 + fi + rm target/celestia.log + echo "Celestia DA Test:" + + celestia light start --core.ip consensus-full-arabica-9.celestia-arabica.com --p2p.network arabica 1>target/celestia.log --keyring.accname da-test 2>&1 & + + sleep 3 + + CELESTIA_JWT=$(celestia light auth admin --p2p.network arabica-9) + jq -r '.auth_token = "'$CELESTIA_JWT'"' $MADARA_PATH/da-config.json > $MADARA_PATH/da-config-tmp.json + mv $MADARA_PATH/da-config-tmp.json $MADARA_PATH/da-config.json + + export CELESTIA_NODE_AUTH_TOKEN=$CELESTIA_JWT + echo "celestia account balance $(celestia rpc state Balance | jq '.result.amount')" +elif [ "$DA_LAYER" = "avail" ]; then + echo "Avail DA Test:" + + if [ ! -d "avail" ]; then + echo "Cloning Avail repository" + git clone https://github.com/availproject/avail 2> /dev/null + fi + + # Navigate to cloned directory + cd avail + + # Check if data-avail binary exists + if [ ! -f "./target/release/data-avail" ]; then + # Build the project + echo "Building repository" + cargo build --release 2> /dev/null + fi + + # End avail if we exit + trap 'pkill -f "data-avail"' EXIT + + # Run data-avail and redirect logs and errors + echo "Launching Avail" + ./target/release/data-avail --dev --tmp --rpc-port 9934 --ws-port 9945 --port 30334 1>../target/avail.log 2> /dev/null & + + # Navigate back to original directory + cd .. + + sleep 5 +fi + +echo "Launching Madara with DA $DA_LAYER" +./target/release/madara --dev --da-layer=$DA_LAYER diff --git a/taplo/taplo.toml b/taplo/taplo.toml index d8854a4d88..e49b66281e 100644 --- a/taplo/taplo.toml +++ b/taplo/taplo.toml @@ -1,5 +1,5 @@ -include = ["../**/*.toml"] -exclude = ["../**/bad.toml"] +include = ["**/*.toml"] +exclude = ["**/bad.toml"] [formatting] align_entries = false