diff --git a/Cargo.lock b/Cargo.lock index 1c42f791f..c4a095a16 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -179,6 +179,12 @@ dependencies = [ "memchr", ] +[[package]] +name = "allocator-api2" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" + [[package]] name = "android_system_properties" version = "0.1.5" @@ -435,6 +441,15 @@ dependencies = [ "pin-project-lite 0.2.9", ] +[[package]] +name = "atoi" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f28d99ec8bfea296261ca1af174f24225171fea9664ba9003cbebee704810528" +dependencies = [ + "num-traits", +] + [[package]] name = "atomic-waker" version = "1.1.1" @@ -581,7 +596,7 @@ version = "0.64.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c4243e6031260db77ede97ad86c27e501d646a27ab57b59a574f725d98ab1fb4" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cexpr", "clang-sys", "lazy_static", @@ -662,6 +677,15 @@ version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" +[[package]] +name = "bitflags" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +dependencies = [ + "serde", +] + [[package]] name = "bitvec" version = "1.0.1" @@ -1082,7 +1106,7 @@ checksum = "223163f58c9a40c3b0a43e1c4b50a9ce09f007ea2cb1ec258a687945b4b7929f" dependencies = [ "anstream", "anstyle", - "bitflags", + "bitflags 1.3.2", "clap_lex", "strsim", ] @@ -1309,7 +1333,7 @@ dependencies = [ "cranelift-codegen", "cranelift-entity", "cranelift-frontend", - "itertools", + "itertools 0.10.5", "log", "smallvec", "wasmparser", @@ -1374,6 +1398,16 @@ dependencies = [ "scopeguard", ] +[[package]] +name = "crossbeam-queue" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" +dependencies = [ + "cfg-if", + "crossbeam-utils", +] + [[package]] name = "crossbeam-utils" version = "0.8.15" @@ -1389,7 +1423,7 @@ version = "0.25.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e64e6c0fbe2c17357405f7c758c1ef960fce08bdfb2c03d88d2a18d7e09c4b67" dependencies = [ - "bitflags", + "bitflags 1.3.2", "crossterm_winapi", "libc", "mio", @@ -1476,7 +1510,7 @@ dependencies = [ "frame-support", "pallet-im-online", "sp-consensus-babe", - "sp-finality-grandpa", + "sp-consensus-grandpa", "sp-runtime", ] @@ -1486,7 +1520,7 @@ version = "0.1.0" dependencies = [ "anyhow", "bip32", - "hex-literal", + "hex-literal 0.4.1", "libsecp256k1", "sha3 0.10.6", "sp-core", @@ -1697,7 +1731,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f1a467a65c5e759bce6e65eaf91cc29f466cdc57cb65777bd646872a8a1fd4de" dependencies = [ "const-oid", - "pem-rfc7468", + "pem-rfc7468 0.6.0", "zeroize", ] @@ -1708,6 +1742,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "82b10af9f9f9f2134a42d3f8aa74658660f2e0234b0eb81bd171df8aa32779ed" dependencies = [ "const-oid", + "pem-rfc7468 0.7.0", "zeroize", ] @@ -1890,6 +1925,12 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "dotenvy" +version = "0.15.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" + [[package]] name = "downcast" version = "0.11.0" @@ -2038,7 +2079,7 @@ version = "0.1.0" dependencies = [ "eip191-crypto", "hex", - "hex-literal", + "hex-literal 0.4.1", "primitives-ethereum", "sp-std", ] @@ -2049,14 +2090,14 @@ version = "0.1.0" dependencies = [ "eip712-common", "eip712-common-test-utils", - "hex-literal", + "hex-literal 0.4.1", ] [[package]] name = "eip712-common" version = "0.1.0" dependencies = [ - "hex-literal", + "hex-literal 0.4.1", "primitives-ethereum", "sp-core", "sp-core-hashing-proc-macro", @@ -2082,7 +2123,7 @@ version = "0.1.0" dependencies = [ "eip712-common", "eip712-common-test-utils", - "hex-literal", + "hex-literal 0.4.1", ] [[package]] @@ -2090,6 +2131,9 @@ name = "either" version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" +dependencies = [ + "serde", +] [[package]] name = "elliptic-curve" @@ -2105,7 +2149,7 @@ dependencies = [ "generic-array 0.14.7", "group 0.12.1", "hkdf", - "pem-rfc7468", + "pem-rfc7468 0.6.0", "pkcs8 0.9.0", "rand_core 0.6.4", "sec1 0.3.0", @@ -2205,6 +2249,17 @@ dependencies = [ "libc", ] +[[package]] +name = "etcetera" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "136d1b5283a1ab77bd9257427ffd09d8667ced0570b6f938942bc7568ed5b943" +dependencies = [ + "cfg-if", + "home", + "windows-sys 0.48.0", +] + [[package]] name = "ethabi" version = "18.0.0" @@ -2245,7 +2300,7 @@ checksum = "6a89fb87a9e103f71b903b80b670200b54cc67a07578f070681f1fffb7396fb7" dependencies = [ "bytes", "ethereum-types", - "hash-db", + "hash-db 0.15.2", "hash256-std-hasher", "parity-scale-codec", "rlp", @@ -2307,9 +2362,8 @@ checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" [[package]] name = "evm" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4448c65b71e8e2b9718232d84d09045eeaaccb2320494e6bd6dbf7e58fec8ff" +version = "0.39.1" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" dependencies = [ "auto_impl", "environmental", @@ -2328,9 +2382,8 @@ dependencies = [ [[package]] name = "evm-core" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64c51bec0eb68a891c2575c758eaaa1d61373fc51f7caaf216b1fb5c3fea3b5d" +version = "0.39.0" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" dependencies = [ "parity-scale-codec", "primitive-types", @@ -2340,9 +2393,8 @@ dependencies = [ [[package]] name = "evm-gasometer" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8b93c59c54fc26522d842f0e0d3f8e8be331c776df18ff3e540b53c2f64d509" +version = "0.39.0" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" dependencies = [ "environmental", "evm-core", @@ -2352,9 +2404,8 @@ dependencies = [ [[package]] name = "evm-runtime" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c79b9459ce64f1a28688397c4013764ce53cd57bb84efc16b5187fa9b05b13ad" +version = "0.39.0" +source = "git+https://github.com/rust-blockchain/evm?rev=b7b82c7e1fc57b7449d6dfa6826600de37cc1e65#b7b82c7e1fc57b7449d6dfa6826600de37cc1e65" dependencies = [ "auto_impl", "environmental", @@ -2372,6 +2423,19 @@ dependencies = [ "futures", ] +[[package]] +name = "expander" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f360349150728553f92e4c997a16af8915f418d3a0f21b440d34c5632f16ed84" +dependencies = [ + "blake2", + "fs-err", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "facetec-api-client" version = "0.1.0" @@ -2411,7 +2475,7 @@ dependencies = [ [[package]] name = "fc-cli" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "clap", "ethereum-types", @@ -2429,16 +2493,14 @@ dependencies = [ [[package]] name = "fc-consensus" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "async-trait", - "fc-db", "fp-consensus", "fp-rpc", "sc-consensus", "sp-api", "sp-block-builder", - "sp-blockchain", "sp-consensus", "sp-runtime", "thiserror", @@ -2447,26 +2509,37 @@ dependencies = [ [[package]] name = "fc-db" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ + "async-trait", + "ethereum", + "fc-storage", + "fp-consensus", + "fp-rpc", "fp-storage", + "futures", "kvdb-rocksdb", "log", "parity-db", "parity-scale-codec", "parking_lot 0.12.1", + "sc-client-api", "sc-client-db", "smallvec", + "sp-api", "sp-blockchain", "sp-core", "sp-database", "sp-runtime", + "sp-storage", + "sqlx", + "tokio", ] [[package]] name = "fc-mapping-sync" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "fc-db", "fc-storage", @@ -2481,13 +2554,15 @@ dependencies = [ "sp-api", "sp-blockchain", "sp-consensus", + "sp-core", "sp-runtime", + "tokio", ] [[package]] name = "fc-rpc" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "ethereum-types", @@ -2514,11 +2589,13 @@ dependencies = [ "sc-client-api", "sc-network", "sc-network-common", + "sc-network-sync", "sc-rpc", "sc-service", "sc-transaction-pool", "sc-transaction-pool-api", "sc-utils", + "serde", "sp-api", "sp-block-builder", "sp-blockchain", @@ -2535,7 +2612,7 @@ dependencies = [ [[package]] name = "fc-rpc-core" version = "1.1.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "ethereum-types", @@ -2548,7 +2625,7 @@ dependencies = [ [[package]] name = "fc-storage" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "ethereum-types", @@ -2636,6 +2713,12 @@ dependencies = [ "scale-info", ] +[[package]] +name = "finl_unicode" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fcfdc7a0362c9f4444381a9e697c79d435fe65b52a37466fc2c1184cee9edc6" + [[package]] name = "fixed-hash" version = "0.8.0" @@ -2674,6 +2757,17 @@ dependencies = [ "num-traits", ] +[[package]] +name = "flume" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55ac459de2512911e4b674ce33cf20befaba382d05b62b008afc1c8b57cbf181" +dependencies = [ + "futures-core", + "futures-sink", + "spin 0.9.8", +] + [[package]] name = "fnv" version = "1.0.7" @@ -2698,7 +2792,7 @@ checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" [[package]] name = "fork-tree" version = "3.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", ] @@ -2715,7 +2809,7 @@ dependencies = [ [[package]] name = "fp-account" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "hex", "impl-serde", @@ -2727,13 +2821,14 @@ dependencies = [ "sp-core", "sp-io", "sp-runtime", + "sp-runtime-interface", "sp-std", ] [[package]] name = "fp-consensus" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "parity-scale-codec", @@ -2745,7 +2840,7 @@ dependencies = [ [[package]] name = "fp-ethereum" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "ethereum-types", @@ -2759,7 +2854,7 @@ dependencies = [ [[package]] name = "fp-evm" version = "3.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "evm", "frame-support", @@ -2773,7 +2868,7 @@ dependencies = [ [[package]] name = "fp-rpc" version = "3.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "ethereum-types", @@ -2790,7 +2885,7 @@ dependencies = [ [[package]] name = "fp-self-contained" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "frame-support", "parity-scale-codec", @@ -2802,7 +2897,7 @@ dependencies = [ [[package]] name = "fp-storage" version = "2.0.0" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "parity-scale-codec", "serde", @@ -2817,7 +2912,7 @@ checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa" [[package]] name = "frame-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-support-procedural", @@ -2842,7 +2937,7 @@ dependencies = [ [[package]] name = "frame-benchmarking-cli" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "Inflector", "array-bytes", @@ -2854,7 +2949,7 @@ dependencies = [ "frame-system", "gethostname", "handlebars", - "itertools", + "itertools 0.10.5", "lazy_static", "linked-hash-map", "log", @@ -2889,7 +2984,7 @@ dependencies = [ [[package]] name = "frame-executive" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-system", @@ -2918,7 +3013,7 @@ dependencies = [ [[package]] name = "frame-remote-externalities" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "log", @@ -2934,9 +3029,10 @@ dependencies = [ [[package]] name = "frame-support" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ - "bitflags", + "bitflags 1.3.2", + "environmental", "frame-metadata", "frame-support-procedural", "impl-trait-for-tuples", @@ -2966,13 +3062,13 @@ dependencies = [ [[package]] name = "frame-support-procedural" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "Inflector", "cfg-expr", "derive-syn-parse", "frame-support-procedural-tools", - "itertools", + "itertools 0.10.5", "proc-macro2", "quote", "syn 1.0.109", @@ -2981,7 +3077,7 @@ dependencies = [ [[package]] name = "frame-support-procedural-tools" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support-procedural-tools-derive", "proc-macro-crate", @@ -2993,7 +3089,7 @@ dependencies = [ [[package]] name = "frame-support-procedural-tools-derive" version = "3.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "proc-macro2", "quote", @@ -3003,7 +3099,7 @@ dependencies = [ [[package]] name = "frame-system" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "log", @@ -3021,7 +3117,7 @@ dependencies = [ [[package]] name = "frame-system-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -3036,7 +3132,7 @@ dependencies = [ [[package]] name = "frame-system-rpc-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "sp-api", @@ -3045,7 +3141,7 @@ dependencies = [ [[package]] name = "frame-try-runtime" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "parity-scale-codec", @@ -3054,6 +3150,15 @@ dependencies = [ "sp-std", ] +[[package]] +name = "fs-err" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88a41f105fe1d5b6b34b2055e3dc59bb79b46b48b2040b9e6c7b4b5de097aa41" +dependencies = [ + "autocfg", +] + [[package]] name = "fs2" version = "0.4.3" @@ -3064,6 +3169,16 @@ dependencies = [ "winapi", ] +[[package]] +name = "fs4" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7672706608ecb74ab2e055c68327ffc25ae4cac1e12349204fd5fb0f3487cce2" +dependencies = [ + "rustix 0.37.11", + "windows-sys 0.48.0", +] + [[package]] name = "funty" version = "2.0.0" @@ -3113,6 +3228,17 @@ dependencies = [ "num_cpus", ] +[[package]] +name = "futures-intrusive" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d930c203dd0b6ff06e0201a4a2fe9149b43c684fd4420555b26d21b1a02956f" +dependencies = [ + "futures-core", + "lock_api", + "parking_lot 0.12.1", +] + [[package]] name = "futures-io" version = "0.3.28" @@ -3372,6 +3498,12 @@ version = "0.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d23bd4e7b5eda0d0f3a307e8b381fdc8ba9000f26fbe912250c0a4cc3956364a" +[[package]] +name = "hash-db" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e7d7786361d7425ae2fe4f9e407eb0efaa0840f5212d109cc018c40c35c6ab4" + [[package]] name = "hash256-std-hasher" version = "0.15.2" @@ -3401,9 +3533,22 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.3" +version = "0.14.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f93e7192158dbcda357bdec5fb5788eebf8bbac027f3f33e719d29135ae84156" +dependencies = [ + "ahash 0.8.3", + "allocator-api2", +] + +[[package]] +name = "hashlink" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" +checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" +dependencies = [ + "hashbrown 0.14.2", +] [[package]] name = "headers" @@ -3412,7 +3557,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f3e372db8e5c0d213e0cd0b9be18be2aca3d44cf2fe30a9d46a65581cd454584" dependencies = [ "base64 0.13.1", - "bitflags", + "bitflags 1.3.2", "bytes", "headers-core", "http", @@ -3435,6 +3580,9 @@ name = "heck" version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +dependencies = [ + "unicode-segmentation", +] [[package]] name = "hermit-abi" @@ -3466,6 +3614,12 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +[[package]] +name = "hex-literal" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0" + [[package]] name = "hex-literal" version = "0.4.1" @@ -3521,6 +3675,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" @@ -3619,7 +3782,7 @@ dependencies = [ "frame-system-rpc-runtime-api", "futures", "hex", - "hex-literal", + "hex-literal 0.4.1", "humanode-rpc", "humanode-runtime", "indoc", @@ -3638,8 +3801,8 @@ dependencies = [ "sc-client-api", "sc-consensus", "sc-consensus-babe", + "sc-consensus-grandpa", "sc-executor", - "sc-finality-grandpa", "sc-service", "sc-telemetry", "sc-transaction-pool", @@ -3648,8 +3811,8 @@ dependencies = [ "sp-api", "sp-application-crypto", "sp-consensus-babe", + "sp-consensus-grandpa", "sp-core", - "sp-finality-grandpa", "sp-inherents", "sp-io", "sp-keyring", @@ -3690,9 +3853,10 @@ dependencies = [ "sc-consensus-babe", "sc-consensus-babe-rpc", "sc-consensus-epochs", - "sc-finality-grandpa", - "sc-finality-grandpa-rpc", + "sc-consensus-grandpa", + "sc-consensus-grandpa-rpc", "sc-network", + "sc-network-sync", "sc-rpc", "sc-rpc-api", "sc-rpc-spec-v2", @@ -3736,7 +3900,7 @@ dependencies = [ "frame-system-rpc-runtime-api", "frame-try-runtime", "hex", - "hex-literal", + "hex-literal 0.4.1", "keystore-bioauth-account-id", "libsecp256k1", "pallet-authorship", @@ -4002,7 +4166,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" dependencies = [ "equivalent", - "hashbrown 0.14.3", + "hashbrown 0.14.2", ] [[package]] @@ -4119,6 +4283,15 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25db6b064527c5d482d0423354fcd07a89a2dfe07b67892e62411946db7f07b0" +dependencies = [ + "either", +] + [[package]] name = "itoa" version = "1.0.6" @@ -4351,6 +4524,9 @@ name = "lazy_static" version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +dependencies = [ + "spin 0.5.2", +] [[package]] name = "lazycell" @@ -4896,6 +5072,17 @@ dependencies = [ "libsecp256k1-core", ] +[[package]] +name = "libsqlite3-sys" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "afc22eff61b133b115c6e8c74e818c628d6d5e7a502afea6f64dee076dd94326" +dependencies = [ + "cc", + "pkg-config", + "vcpkg", +] + [[package]] name = "libz-sys" version = "1.1.8" @@ -5099,15 +5286,6 @@ dependencies = [ "autocfg", ] -[[package]] -name = "memoffset" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5de893c32cde5f383baa4c04c5d6dbdd735cfd4a794b0debdb2bb1b421da5ff4" -dependencies = [ - "autocfg", -] - [[package]] name = "memoffset" version = "0.8.0" @@ -5119,12 +5297,11 @@ dependencies = [ [[package]] name = "memory-db" -version = "0.31.0" +version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e0c7cba9ce19ac7ffd2053ac9f49843bbd3f4318feedfd74e85c19d5fb0ba66" +checksum = "808b50db46293432a45e63bc15ea51e0ab4c0a1647b8eb114e31a3e698dd6fbe" dependencies = [ - "hash-db", - "hashbrown 0.12.3", + "hash-db 0.16.0", ] [[package]] @@ -5418,7 +5595,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9ea4302b9759a7a88242299225ea3688e63c85ea136371bb6cf94fd674efaab" dependencies = [ "anyhow", - "bitflags", + "bitflags 1.3.2", "byteorder", "libc", "netlink-packet-core", @@ -5482,26 +5659,12 @@ version = "0.24.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fa52e972a9a719cecb6864fb88568781eb706bac2cd1d4f04a648542dbf78069" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg-if", "libc", "memoffset 0.6.5", ] -[[package]] -name = "nix" -version = "0.26.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfdda3d196821d6af13126e40375cdf7da646a96114af134d5f417a9a1dc8e1a" -dependencies = [ - "bitflags", - "cfg-if", - "libc", - "memoffset 0.7.1", - "pin-utils", - "static_assertions", -] - [[package]] name = "nohash-hasher" version = "0.2.0" @@ -5559,6 +5722,23 @@ dependencies = [ "num-traits", ] +[[package]] +name = "num-bigint-dig" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc84195820f291c7697304f3cbdadd1cb7199c0efc917ff5eafd71225c136151" +dependencies = [ + "byteorder", + "lazy_static", + "libm", + "num-integer", + "num-iter", + "num-traits", + "rand 0.8.5", + "smallvec", + "zeroize", +] + [[package]] name = "num-complex" version = "0.4.3" @@ -5618,6 +5798,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" dependencies = [ "autocfg", + "libm", ] [[package]] @@ -5766,7 +5947,7 @@ version = "0.10.55" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "345df152bc43501c5eb9e4654ff05f794effb78d4efe3d53abc158baddc0703d" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg-if", "foreign-types", "libc", @@ -5835,7 +6016,7 @@ dependencies = [ [[package]] name = "pallet-authorship" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-system", @@ -5849,7 +6030,7 @@ dependencies = [ [[package]] name = "pallet-babe" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -5888,7 +6069,7 @@ dependencies = [ [[package]] name = "pallet-balances" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -5981,7 +6162,7 @@ dependencies = [ "fp-evm", "frame-support", "frame-system", - "hex-literal", + "hex-literal 0.4.1", "pallet-balances", "pallet-evm", "pallet-evm-balances", @@ -6008,7 +6189,7 @@ dependencies = [ [[package]] name = "pallet-ethereum" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "ethereum", "ethereum-types", @@ -6044,7 +6225,7 @@ dependencies = [ [[package]] name = "pallet-evm" version = "6.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "environmental", "evm", @@ -6054,6 +6235,7 @@ dependencies = [ "frame-support", "frame-system", "hex", + "hex-literal 0.3.4", "impl-trait-for-tuples", "log", "parity-scale-codec", @@ -6083,7 +6265,7 @@ dependencies = [ [[package]] name = "pallet-evm-balances" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "frame-support", "frame-system", @@ -6097,7 +6279,7 @@ dependencies = [ [[package]] name = "pallet-evm-precompile-modexp" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "fp-evm", "num", @@ -6106,7 +6288,7 @@ dependencies = [ [[package]] name = "pallet-evm-precompile-sha3fips" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "fp-evm", "tiny-keccak", @@ -6115,7 +6297,7 @@ dependencies = [ [[package]] name = "pallet-evm-precompile-simple" version = "2.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "fp-evm", "ripemd", @@ -6125,7 +6307,7 @@ dependencies = [ [[package]] name = "pallet-evm-system" version = "1.0.0-dev" -source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.39#a487de275b0bfa60f924fef5b3d6ba446fad1edd" +source = "git+https://github.com/humanode-network/frontier?branch=locked/polkadot-v0.9.40#9f01d682957d0a2bcc022e0f0264941342fb5305" dependencies = [ "fp-evm", "frame-support", @@ -6140,7 +6322,7 @@ dependencies = [ [[package]] name = "pallet-grandpa" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -6151,8 +6333,8 @@ dependencies = [ "parity-scale-codec", "scale-info", "sp-application-crypto", + "sp-consensus-grandpa", "sp-core", - "sp-finality-grandpa", "sp-io", "sp-runtime", "sp-session", @@ -6178,7 +6360,7 @@ dependencies = [ [[package]] name = "pallet-im-online" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -6198,7 +6380,7 @@ dependencies = [ [[package]] name = "pallet-multisig" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -6214,7 +6396,7 @@ dependencies = [ [[package]] name = "pallet-offences" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-system", @@ -6244,7 +6426,7 @@ dependencies = [ [[package]] name = "pallet-session" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-system", @@ -6265,7 +6447,7 @@ dependencies = [ [[package]] name = "pallet-sudo" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-system", @@ -6279,7 +6461,7 @@ dependencies = [ [[package]] name = "pallet-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -6316,7 +6498,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-support", "frame-system", @@ -6332,7 +6514,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "jsonrpsee", "pallet-transaction-payment-rpc-runtime-api", @@ -6348,7 +6530,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "pallet-transaction-payment", "parity-scale-codec", @@ -6360,7 +6542,7 @@ dependencies = [ [[package]] name = "pallet-utility" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-benchmarking", "frame-support", @@ -6561,6 +6743,15 @@ dependencies = [ "base64ct", ] +[[package]] +name = "pem-rfc7468" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88b39c9bfcfc231068454382784bb460aae594343fb030d46e9f50a645418412" +dependencies = [ + "base64ct", +] + [[package]] name = "percent-encoding" version = "2.2.0" @@ -6659,6 +6850,17 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +[[package]] +name = "pkcs1" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8ffb9f10fa047879315e6625af03c164b16962a5368d724ed16323b68ace47f" +dependencies = [ + "der 0.7.3", + "pkcs8 0.10.2", + "spki 0.7.1", +] + [[package]] name = "pkcs8" version = "0.9.0" @@ -6698,7 +6900,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4be1c66a6add46bff50935c313dae30a5030cf8385c5206e8a95e9e9def974aa" dependencies = [ "autocfg", - "bitflags", + "bitflags 1.3.2", "cfg-if", "concurrent-queue", "libc", @@ -6776,7 +6978,7 @@ dependencies = [ "fp-evm", "frame-support", "frame-system", - "hex-literal", + "hex-literal 0.4.1", "mockall", "num_enum 0.6.0", "pallet-balances", @@ -6798,7 +7000,7 @@ dependencies = [ "fp-evm", "frame-support", "frame-system", - "hex-literal", + "hex-literal 0.4.1", "mockall", "pallet-evm-accounts-mapping", "parity-scale-codec", @@ -6817,7 +7019,7 @@ dependencies = [ "fp-evm", "frame-support", "frame-system", - "hex-literal", + "hex-literal 0.4.1", "num_enum 0.6.0", "pallet-balances", "pallet-erc20-support", @@ -6839,7 +7041,7 @@ dependencies = [ "fp-evm", "frame-support", "frame-system", - "hex-literal", + "hex-literal 0.4.1", "impl-trait-for-tuples", "log", "num_enum 0.6.0", @@ -6871,7 +7073,7 @@ checksum = "59230a63c37f3e18569bdb90e4a89cbf5bf8b06fea0b84e65ea10cc4df47addd" dependencies = [ "difflib", "float-cmp", - "itertools", + "itertools 0.10.5", "normalize-line-endings", "predicates-core", "regex", @@ -7062,7 +7264,7 @@ checksum = "2c828f93f5ca4826f97fedcbd3f9a536c16b12cff3dbbb4a007f932bbad95b12" dependencies = [ "bytes", "heck", - "itertools", + "itertools 0.10.5", "lazy_static", "log", "multimap", @@ -7096,7 +7298,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4ea9b0f8cbe5e15a8a042d030bd96668db28ecb567ec37d691971ff5731d2b1b" dependencies = [ "anyhow", - "itertools", + "itertools 0.10.5", "proc-macro2", "quote", "syn 1.0.109", @@ -7337,7 +7539,7 @@ version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" dependencies = [ - "bitflags", + "bitflags 1.3.2", ] [[package]] @@ -7346,7 +7548,7 @@ version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" dependencies = [ - "bitflags", + "bitflags 1.3.2", ] [[package]] @@ -7424,7 +7626,7 @@ version = "3.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "76e189c2369884dce920945e2ddf79b3dff49e071a167dd1817fa9c4c00d512e" dependencies = [ - "bitflags", + "bitflags 1.3.2", "libc", "mach", "winapi", @@ -7568,7 +7770,7 @@ name = "robonode-crypto" version = "0.1.0" dependencies = [ "ed25519-dalek 2.0.0", - "hex-literal", + "hex-literal 0.4.1", "rand 0.8.5", ] @@ -7652,6 +7854,27 @@ dependencies = [ "tracing", ] +[[package]] +name = "rsa" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72f1471dbb4be5de45050e8ef7040625298ccb9efe941419ac2697088715925f" +dependencies = [ + "byteorder", + "const-oid", + "digest 0.10.6", + "num-bigint-dig", + "num-integer", + "num-iter", + "num-traits", + "pkcs1", + "pkcs8 0.10.2", + "rand_core 0.6.4", + "signature 2.1.0", + "subtle", + "zeroize", +] + [[package]] name = "rtcp" version = "0.7.2" @@ -7673,7 +7896,7 @@ dependencies = [ "log", "netlink-packet-route", "netlink-proto", - "nix 0.24.3", + "nix", "thiserror", "tokio", ] @@ -7744,7 +7967,7 @@ version = "0.36.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "305efbd14fde4139eb501df5f136994bb520b033fa9fbdce287507dc23b8c7ed" dependencies = [ - "bitflags", + "bitflags 1.3.2", "errno", "io-lifetimes", "libc", @@ -7758,7 +7981,7 @@ version = "0.37.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "85597d61f83914ddeba6a47b3b8ffe7365107221c2e557ed94426489fefb5f77" dependencies = [ - "bitflags", + "bitflags 1.3.2", "errno", "io-lifetimes", "libc", @@ -7856,7 +8079,7 @@ dependencies = [ [[package]] name = "sc-allocator" version = "4.1.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "log", "sp-core", @@ -7867,7 +8090,7 @@ dependencies = [ [[package]] name = "sc-basic-authorship" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "futures-timer", @@ -7890,7 +8113,7 @@ dependencies = [ [[package]] name = "sc-block-builder" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "sc-client-api", @@ -7900,28 +8123,31 @@ dependencies = [ "sp-core", "sp-inherents", "sp-runtime", - "sp-state-machine", ] [[package]] name = "sc-chain-spec" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "memmap2", "sc-chain-spec-derive", - "sc-network-common", + "sc-client-api", + "sc-executor", + "sc-network", "sc-telemetry", "serde", "serde_json", + "sp-blockchain", "sp-core", "sp-runtime", + "sp-state-machine", ] [[package]] name = "sc-chain-spec-derive" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "proc-macro-crate", "proc-macro2", @@ -7932,7 +8158,7 @@ dependencies = [ [[package]] name = "sc-cli" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "chrono", @@ -7972,7 +8198,7 @@ dependencies = [ [[package]] name = "sc-client-api" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "fnv", "futures", @@ -7998,9 +8224,9 @@ dependencies = [ [[package]] name = "sc-client-db" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ - "hash-db", + "hash-db 0.16.0", "kvdb", "kvdb-memorydb", "kvdb-rocksdb", @@ -8024,7 +8250,7 @@ dependencies = [ [[package]] name = "sc-consensus" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "futures", @@ -8049,7 +8275,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "fork-tree", @@ -8088,7 +8314,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe-rpc" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "jsonrpsee", @@ -8110,7 +8336,7 @@ dependencies = [ [[package]] name = "sc-consensus-epochs" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "fork-tree", "parity-scale-codec", @@ -8121,32 +8347,92 @@ dependencies = [ ] [[package]] -name = "sc-consensus-slots" +name = "sc-consensus-grandpa" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ + "ahash 0.8.3", + "array-bytes", "async-trait", + "dyn-clone", + "finality-grandpa", + "fork-tree", "futures", "futures-timer", "log", "parity-scale-codec", + "parking_lot 0.12.1", + "rand 0.8.5", + "sc-block-builder", + "sc-chain-spec", "sc-client-api", "sc-consensus", + "sc-network", + "sc-network-common", + "sc-network-gossip", "sc-telemetry", + "sc-utils", + "serde_json", + "sp-api", + "sp-application-crypto", "sp-arithmetic", "sp-blockchain", "sp-consensus", - "sp-consensus-slots", + "sp-consensus-grandpa", "sp-core", - "sp-inherents", + "sp-keystore", "sp-runtime", - "sp-state-machine", + "substrate-prometheus-endpoint", + "thiserror", +] + +[[package]] +name = "sc-consensus-grandpa-rpc" +version = "0.10.0-dev" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" +dependencies = [ + "finality-grandpa", + "futures", + "jsonrpsee", + "log", + "parity-scale-codec", + "sc-client-api", + "sc-consensus-grandpa", + "sc-rpc", + "serde", + "sp-blockchain", + "sp-core", + "sp-runtime", + "thiserror", +] + +[[package]] +name = "sc-consensus-slots" +version = "0.10.0-dev" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" +dependencies = [ + "async-trait", + "futures", + "futures-timer", + "log", + "parity-scale-codec", + "sc-client-api", + "sc-consensus", + "sc-telemetry", + "sp-arithmetic", + "sp-blockchain", + "sp-consensus", + "sp-consensus-slots", + "sp-core", + "sp-inherents", + "sp-runtime", + "sp-state-machine", ] [[package]] name = "sc-executor" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "lru", "parity-scale-codec", @@ -8170,7 +8456,7 @@ dependencies = [ [[package]] name = "sc-executor-common" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "sc-allocator", "sp-maybe-compressed-blob", @@ -8183,7 +8469,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmi" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "log", "sc-allocator", @@ -8196,7 +8482,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmtime" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "anyhow", "cfg-if", @@ -8211,76 +8497,17 @@ dependencies = [ "wasmtime", ] -[[package]] -name = "sc-finality-grandpa" -version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" -dependencies = [ - "ahash 0.8.3", - "array-bytes", - "async-trait", - "dyn-clone", - "finality-grandpa", - "fork-tree", - "futures", - "futures-timer", - "log", - "parity-scale-codec", - "parking_lot 0.12.1", - "rand 0.8.5", - "sc-block-builder", - "sc-chain-spec", - "sc-client-api", - "sc-consensus", - "sc-network", - "sc-network-common", - "sc-network-gossip", - "sc-telemetry", - "sc-utils", - "serde_json", - "sp-api", - "sp-application-crypto", - "sp-arithmetic", - "sp-blockchain", - "sp-consensus", - "sp-core", - "sp-finality-grandpa", - "sp-keystore", - "sp-runtime", - "substrate-prometheus-endpoint", - "thiserror", -] - -[[package]] -name = "sc-finality-grandpa-rpc" -version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" -dependencies = [ - "finality-grandpa", - "futures", - "jsonrpsee", - "log", - "parity-scale-codec", - "sc-client-api", - "sc-finality-grandpa", - "sc-rpc", - "serde", - "sp-blockchain", - "sp-core", - "sp-runtime", - "thiserror", -] - [[package]] name = "sc-informant" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "ansi_term", "futures", "futures-timer", "log", "sc-client-api", + "sc-network", "sc-network-common", "sp-blockchain", "sp-runtime", @@ -8289,7 +8516,7 @@ dependencies = [ [[package]] name = "sc-keystore" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "async-trait", @@ -8304,12 +8531,12 @@ dependencies = [ [[package]] name = "sc-network" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", + "async-channel", "async-trait", "asynchronous-codec", - "backtrace", "bytes", "either", "fnv", @@ -8317,6 +8544,7 @@ dependencies = [ "futures-timer", "ip_network", "libp2p", + "linked_hash_set", "log", "lru", "mockall", @@ -8347,7 +8575,7 @@ dependencies = [ [[package]] name = "sc-network-bitswap" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "cid", "futures", @@ -8356,6 +8584,7 @@ dependencies = [ "prost", "prost-build", "sc-client-api", + "sc-network", "sc-network-common", "sp-blockchain", "sp-runtime", @@ -8366,33 +8595,35 @@ dependencies = [ [[package]] name = "sc-network-common" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ + "array-bytes", "async-trait", - "bitflags", + "bitflags 1.3.2", "bytes", "futures", "futures-timer", "libp2p", - "linked_hash_set", "parity-scale-codec", "prost-build", "sc-consensus", "sc-peerset", + "sc-utils", "serde", "smallvec", "sp-blockchain", "sp-consensus", - "sp-finality-grandpa", + "sp-consensus-grandpa", "sp-runtime", "substrate-prometheus-endpoint", "thiserror", + "zeroize", ] [[package]] name = "sc-network-gossip" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "ahash 0.8.3", "futures", @@ -8400,6 +8631,7 @@ dependencies = [ "libp2p", "log", "lru", + "sc-network", "sc-network-common", "sc-peerset", "sp-runtime", @@ -8410,7 +8642,7 @@ dependencies = [ [[package]] name = "sc-network-light" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "futures", @@ -8420,6 +8652,7 @@ dependencies = [ "prost", "prost-build", "sc-client-api", + "sc-network", "sc-network-common", "sc-peerset", "sp-blockchain", @@ -8431,12 +8664,13 @@ dependencies = [ [[package]] name = "sc-network-sync" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "async-trait", "fork-tree", "futures", + "futures-timer", "libp2p", "log", "lru", @@ -8446,6 +8680,7 @@ dependencies = [ "prost-build", "sc-client-api", "sc-consensus", + "sc-network", "sc-network-common", "sc-peerset", "sc-utils", @@ -8453,8 +8688,8 @@ dependencies = [ "sp-arithmetic", "sp-blockchain", "sp-consensus", + "sp-consensus-grandpa", "sp-core", - "sp-finality-grandpa", "sp-runtime", "substrate-prometheus-endpoint", "thiserror", @@ -8463,7 +8698,7 @@ dependencies = [ [[package]] name = "sc-network-transactions" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "futures", @@ -8471,6 +8706,7 @@ dependencies = [ "log", "parity-scale-codec", "pin-project", + "sc-network", "sc-network-common", "sc-peerset", "sc-utils", @@ -8482,7 +8718,7 @@ dependencies = [ [[package]] name = "sc-offchain" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "bytes", @@ -8498,6 +8734,7 @@ dependencies = [ "parking_lot 0.12.1", "rand 0.8.5", "sc-client-api", + "sc-network", "sc-network-common", "sc-peerset", "sc-utils", @@ -8512,7 +8749,7 @@ dependencies = [ [[package]] name = "sc-peerset" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "libp2p", @@ -8525,7 +8762,7 @@ dependencies = [ [[package]] name = "sc-proposer-metrics" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "log", "substrate-prometheus-endpoint", @@ -8534,7 +8771,7 @@ dependencies = [ [[package]] name = "sc-rpc" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "jsonrpsee", @@ -8564,7 +8801,7 @@ dependencies = [ [[package]] name = "sc-rpc-api" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -8583,7 +8820,7 @@ dependencies = [ [[package]] name = "sc-rpc-server" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "http", "jsonrpsee", @@ -8598,7 +8835,7 @@ dependencies = [ [[package]] name = "sc-rpc-spec-v2" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "futures", @@ -8624,7 +8861,7 @@ dependencies = [ [[package]] name = "sc-service" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "directories", @@ -8690,7 +8927,7 @@ dependencies = [ [[package]] name = "sc-state-db" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "log", "parity-scale-codec", @@ -8701,12 +8938,12 @@ dependencies = [ [[package]] name = "sc-storage-monitor" version = "0.1.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "clap", + "fs4", "futures", "log", - "nix 0.26.2", "sc-client-db", "sc-utils", "sp-core", @@ -8717,7 +8954,7 @@ dependencies = [ [[package]] name = "sc-sysinfo" version = "6.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "libc", @@ -8736,7 +8973,7 @@ dependencies = [ [[package]] name = "sc-telemetry" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "chrono", "futures", @@ -8755,7 +8992,7 @@ dependencies = [ [[package]] name = "sc-tracing" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "ansi_term", "atty", @@ -8786,7 +9023,7 @@ dependencies = [ [[package]] name = "sc-tracing-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "proc-macro-crate", "proc-macro2", @@ -8797,7 +9034,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "futures", @@ -8824,7 +9061,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool-api" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "futures", @@ -8838,15 +9075,16 @@ dependencies = [ [[package]] name = "sc-utils" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ - "backtrace", + "async-channel", "futures", "futures-timer", "lazy_static", "log", "parking_lot 0.12.1", "prometheus", + "sp-arithmetic", ] [[package]] @@ -9042,7 +9280,7 @@ version = "2.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a332be01508d814fed64bf28f798a146d73792121129962fdf335bb3c49a4254" dependencies = [ - "bitflags", + "bitflags 1.3.2", "core-foundation", "core-foundation-sys", "libc", @@ -9397,9 +9635,9 @@ dependencies = [ [[package]] name = "sp-api" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ - "hash-db", + "hash-db 0.16.0", "log", "parity-scale-codec", "sp-api-proc-macro", @@ -9415,9 +9653,11 @@ dependencies = [ [[package]] name = "sp-api-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ + "Inflector", "blake2", + "expander", "proc-macro-crate", "proc-macro2", "quote", @@ -9427,7 +9667,7 @@ dependencies = [ [[package]] name = "sp-application-crypto" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "scale-info", @@ -9440,7 +9680,7 @@ dependencies = [ [[package]] name = "sp-arithmetic" version = "6.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "integer-sqrt", "num-traits", @@ -9454,7 +9694,7 @@ dependencies = [ [[package]] name = "sp-block-builder" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "sp-api", @@ -9466,7 +9706,7 @@ dependencies = [ [[package]] name = "sp-blockchain" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "futures", "log", @@ -9484,25 +9724,22 @@ dependencies = [ [[package]] name = "sp-consensus" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "futures", "log", - "parity-scale-codec", "sp-core", "sp-inherents", "sp-runtime", "sp-state-machine", - "sp-std", - "sp-version", "thiserror", ] [[package]] name = "sp-consensus-aura" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "parity-scale-codec", @@ -9520,7 +9757,7 @@ dependencies = [ [[package]] name = "sp-consensus-babe" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "merlin", @@ -9540,10 +9777,28 @@ dependencies = [ "sp-timestamp", ] +[[package]] +name = "sp-consensus-grandpa" +version = "4.0.0-dev" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" +dependencies = [ + "finality-grandpa", + "log", + "parity-scale-codec", + "scale-info", + "serde", + "sp-api", + "sp-application-crypto", + "sp-core", + "sp-keystore", + "sp-runtime", + "sp-std", +] + [[package]] name = "sp-consensus-slots" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "scale-info", @@ -9555,7 +9810,7 @@ dependencies = [ [[package]] name = "sp-consensus-vrf" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "scale-info", @@ -9568,17 +9823,17 @@ dependencies = [ [[package]] name = "sp-core" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "array-bytes", "base58", - "bitflags", + "bitflags 1.3.2", "blake2", "bounded-collections", "dyn-clonable", "ed25519-zebra", "futures", - "hash-db", + "hash-db 0.16.0", "hash256-std-hasher", "impl-serde", "lazy_static", @@ -9611,9 +9866,9 @@ dependencies = [ [[package]] name = "sp-core-hashing" version = "5.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ - "blake2", + "blake2b_simd", "byteorder", "digest 0.10.6", "sha2 0.10.6", @@ -9625,7 +9880,7 @@ dependencies = [ [[package]] name = "sp-core-hashing-proc-macro" version = "5.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "proc-macro2", "quote", @@ -9636,7 +9891,7 @@ dependencies = [ [[package]] name = "sp-database" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "kvdb", "parking_lot 0.12.1", @@ -9645,7 +9900,7 @@ dependencies = [ [[package]] name = "sp-debug-derive" version = "5.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "proc-macro2", "quote", @@ -9655,7 +9910,7 @@ dependencies = [ [[package]] name = "sp-externalities" version = "0.13.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "environmental", "parity-scale-codec", @@ -9663,28 +9918,10 @@ dependencies = [ "sp-storage", ] -[[package]] -name = "sp-finality-grandpa" -version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" -dependencies = [ - "finality-grandpa", - "log", - "parity-scale-codec", - "scale-info", - "serde", - "sp-api", - "sp-application-crypto", - "sp-core", - "sp-keystore", - "sp-runtime", - "sp-std", -] - [[package]] name = "sp-inherents" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "impl-trait-for-tuples", @@ -9699,7 +9936,7 @@ dependencies = [ [[package]] name = "sp-io" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "bytes", "ed25519 1.5.3", @@ -9724,7 +9961,7 @@ dependencies = [ [[package]] name = "sp-keyring" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "lazy_static", "sp-core", @@ -9735,7 +9972,7 @@ dependencies = [ [[package]] name = "sp-keystore" version = "0.13.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "futures", @@ -9752,7 +9989,7 @@ dependencies = [ [[package]] name = "sp-maybe-compressed-blob" version = "4.1.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "thiserror", "zstd", @@ -9761,7 +9998,7 @@ dependencies = [ [[package]] name = "sp-offchain" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "sp-api", "sp-core", @@ -9771,7 +10008,7 @@ dependencies = [ [[package]] name = "sp-panic-handler" version = "5.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "backtrace", "lazy_static", @@ -9781,7 +10018,7 @@ dependencies = [ [[package]] name = "sp-rpc" version = "6.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "rustc-hash", "serde", @@ -9791,7 +10028,7 @@ dependencies = [ [[package]] name = "sp-runtime" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "either", "hash256-std-hasher", @@ -9813,7 +10050,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "bytes", "impl-trait-for-tuples", @@ -9831,7 +10068,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface-proc-macro" version = "6.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "Inflector", "proc-macro-crate", @@ -9843,7 +10080,7 @@ dependencies = [ [[package]] name = "sp-session" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "scale-info", @@ -9857,7 +10094,7 @@ dependencies = [ [[package]] name = "sp-staking" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "scale-info", @@ -9869,9 +10106,9 @@ dependencies = [ [[package]] name = "sp-state-machine" version = "0.13.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ - "hash-db", + "hash-db 0.16.0", "log", "parity-scale-codec", "parking_lot 0.12.1", @@ -9889,12 +10126,12 @@ dependencies = [ [[package]] name = "sp-std" version = "5.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" [[package]] name = "sp-storage" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "impl-serde", "parity-scale-codec", @@ -9907,7 +10144,7 @@ dependencies = [ [[package]] name = "sp-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "futures-timer", @@ -9922,7 +10159,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "6.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "sp-std", @@ -9934,7 +10171,7 @@ dependencies = [ [[package]] name = "sp-transaction-pool" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "sp-api", "sp-runtime", @@ -9943,7 +10180,7 @@ dependencies = [ [[package]] name = "sp-transaction-storage-proof" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "log", @@ -9959,10 +10196,10 @@ dependencies = [ [[package]] name = "sp-trie" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "ahash 0.8.3", - "hash-db", + "hash-db 0.16.0", "hashbrown 0.12.3", "lazy_static", "memory-db", @@ -9982,7 +10219,7 @@ dependencies = [ [[package]] name = "sp-version" version = "5.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "impl-serde", "parity-scale-codec", @@ -9999,7 +10236,7 @@ dependencies = [ [[package]] name = "sp-version-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "proc-macro2", @@ -10010,7 +10247,7 @@ dependencies = [ [[package]] name = "sp-wasm-interface" version = "7.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "anyhow", "impl-trait-for-tuples", @@ -10024,7 +10261,7 @@ dependencies = [ [[package]] name = "sp-weights" version = "4.0.0" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "parity-scale-codec", "scale-info", @@ -10047,6 +10284,9 @@ name = "spin" version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" +dependencies = [ + "lock_api", +] [[package]] name = "spki" @@ -10068,6 +10308,212 @@ dependencies = [ "der 0.7.3", ] +[[package]] +name = "sqlformat" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce81b7bd7c4493975347ef60d8c7e8b742d4694f4c49f93e0a12ea263938176c" +dependencies = [ + "itertools 0.12.0", + "nom", + "unicode_categories", +] + +[[package]] +name = "sqlx" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0e50c216e3624ec8e7ecd14c6a6a6370aad6ee5d8cfc3ab30b5162eeeef2ed33" +dependencies = [ + "sqlx-core", + "sqlx-macros", + "sqlx-mysql", + "sqlx-postgres", + "sqlx-sqlite", +] + +[[package]] +name = "sqlx-core" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d6753e460c998bbd4cd8c6f0ed9a64346fcca0723d6e75e52fdc351c5d2169d" +dependencies = [ + "ahash 0.8.3", + "atoi", + "byteorder", + "bytes", + "crc", + "crossbeam-queue", + "dotenvy", + "either", + "event-listener", + "futures-channel", + "futures-core", + "futures-intrusive", + "futures-io", + "futures-util", + "hashlink", + "hex", + "indexmap 2.1.0", + "log", + "memchr", + "native-tls", + "once_cell", + "paste", + "percent-encoding", + "serde", + "serde_json", + "sha2 0.10.6", + "smallvec", + "sqlformat", + "thiserror", + "tokio", + "tokio-stream", + "tracing", + "url", +] + +[[package]] +name = "sqlx-macros" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a793bb3ba331ec8359c1853bd39eed32cdd7baaf22c35ccf5c92a7e8d1189ec" +dependencies = [ + "proc-macro2", + "quote", + "sqlx-core", + "sqlx-macros-core", + "syn 1.0.109", +] + +[[package]] +name = "sqlx-macros-core" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a4ee1e104e00dedb6aa5ffdd1343107b0a4702e862a84320ee7cc74782d96fc" +dependencies = [ + "dotenvy", + "either", + "heck", + "hex", + "once_cell", + "proc-macro2", + "quote", + "serde", + "serde_json", + "sha2 0.10.6", + "sqlx-core", + "sqlx-mysql", + "sqlx-sqlite", + "syn 1.0.109", + "tempfile", + "tokio", + "url", +] + +[[package]] +name = "sqlx-mysql" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "864b869fdf56263f4c95c45483191ea0af340f9f3e3e7b4d57a61c7c87a970db" +dependencies = [ + "atoi", + "base64 0.21.0", + "bitflags 2.4.1", + "byteorder", + "bytes", + "crc", + "digest 0.10.6", + "dotenvy", + "either", + "futures-channel", + "futures-core", + "futures-io", + "futures-util", + "generic-array 0.14.7", + "hex", + "hkdf", + "hmac 0.12.1", + "itoa", + "log", + "md-5", + "memchr", + "once_cell", + "percent-encoding", + "rand 0.8.5", + "rsa", + "serde", + "sha1", + "sha2 0.10.6", + "smallvec", + "sqlx-core", + "stringprep", + "thiserror", + "tracing", + "whoami", +] + +[[package]] +name = "sqlx-postgres" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb7ae0e6a97fb3ba33b23ac2671a5ce6e3cabe003f451abd5a56e7951d975624" +dependencies = [ + "atoi", + "base64 0.21.0", + "bitflags 2.4.1", + "byteorder", + "crc", + "dotenvy", + "etcetera", + "futures-channel", + "futures-core", + "futures-io", + "futures-util", + "hex", + "hkdf", + "hmac 0.12.1", + "home", + "itoa", + "log", + "md-5", + "memchr", + "once_cell", + "rand 0.8.5", + "serde", + "serde_json", + "sha1", + "sha2 0.10.6", + "smallvec", + "sqlx-core", + "stringprep", + "thiserror", + "tracing", + "whoami", +] + +[[package]] +name = "sqlx-sqlite" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d59dc83cf45d89c555a577694534fcd1b55c545a816c816ce51f20bbe56a4f3f" +dependencies = [ + "atoi", + "flume", + "futures-channel", + "futures-core", + "futures-executor", + "futures-intrusive", + "futures-util", + "libsqlite3-sys", + "log", + "percent-encoding", + "serde", + "sqlx-core", + "tracing", + "url", +] + [[package]] name = "ss58-registry" version = "1.39.0" @@ -10101,7 +10547,7 @@ version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a2a1c578e98c1c16fc3b8ec1328f7659a500737d7a0c6d625e73e830ff9c1f6" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg_aliases", "libc", "parking_lot 0.11.2", @@ -10123,6 +10569,17 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "stringprep" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb41d74e231a107a1b4ee36bd1214b11285b77768d2e3824aedafa988fd36ee6" +dependencies = [ + "finl_unicode", + "unicode-bidi", + "unicode-normalization", +] + [[package]] name = "strsim" version = "0.10.0" @@ -10186,7 +10643,7 @@ dependencies = [ [[package]] name = "substrate-frame-rpc-system" version = "4.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "frame-system-rpc-runtime-api", "futures", @@ -10205,7 +10662,7 @@ dependencies = [ [[package]] name = "substrate-prometheus-endpoint" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "hyper", "log", @@ -10217,7 +10674,7 @@ dependencies = [ [[package]] name = "substrate-rpc-client" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "jsonrpsee", @@ -10230,7 +10687,7 @@ dependencies = [ [[package]] name = "substrate-wasm-builder" version = "5.0.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "ansi_term", "build-helper", @@ -10299,7 +10756,7 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d75182f12f490e953596550b65ee31bda7c8e043d9386174b353bda50838c3fd" dependencies = [ - "bitflags", + "bitflags 1.3.2", "core-foundation", "system-configuration-sys", ] @@ -10616,7 +11073,7 @@ version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f873044bf02dd1e8239e9c1293ea39dad76dc594ec16185d0a1bf31d8dc8d858" dependencies = [ - "bitflags", + "bitflags 1.3.2", "bytes", "futures-core", "futures-util", @@ -10771,11 +11228,11 @@ dependencies = [ [[package]] name = "trie-db" -version = "0.25.1" +version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3390c0409daaa6027d6681393316f4ccd3ff82e1590a1e4725014e3ae2bf1920" +checksum = "767abe6ffed88a1889671a102c2861ae742726f52e0a5a425b92c9fbfa7e9c85" dependencies = [ - "hash-db", + "hash-db 0.16.0", "hashbrown 0.13.2", "log", "rustc-hex", @@ -10784,11 +11241,11 @@ dependencies = [ [[package]] name = "trie-root" -version = "0.17.0" +version = "0.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a36c5ca3911ed3c9a5416ee6c679042064b93fc637ded67e25f92e68d783891" +checksum = "d4ed310ef5ab98f5fa467900ed906cb9232dd5376597e00fd4cba2a449d06c0b" dependencies = [ - "hash-db", + "hash-db 0.16.0", ] [[package]] @@ -10797,7 +11254,7 @@ version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1631b201eb031b563d2e85ca18ec8092508e262a3196ce9bd10a67ec87b9f5c" dependencies = [ - "hash-db", + "hash-db 0.15.2", "rlp", ] @@ -10856,7 +11313,7 @@ checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" [[package]] name = "try-runtime-cli" version = "0.10.0-dev" -source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.39#5b23f49147d482eadf96a1bb95924e8b661a931a" +source = "git+https://github.com/humanode-network/substrate?branch=locked/polkadot-v0.9.40#fc5aabd84ebf6be57f97bf6dbf557eed5753719b" dependencies = [ "async-trait", "clap", @@ -11018,6 +11475,12 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" +[[package]] +name = "unicode_categories" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" + [[package]] name = "universal-hash" version = "0.4.1" @@ -11823,14 +12286,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "93f1db1727772c05cf7a2cfece52c3aca8045ca1e176cd517d323489aa3c6d87" dependencies = [ "async-trait", - "bitflags", + "bitflags 1.3.2", "bytes", "cc", "ipnet", "lazy_static", "libc", "log", - "nix 0.24.3", + "nix", "rand 0.8.5", "thiserror", "tokio", @@ -11848,6 +12311,12 @@ dependencies = [ "once_cell", ] +[[package]] +name = "whoami" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22fc3756b8a9133049b26c7f61ab35416c130e8c09b660f5b3958b446f52cc50" + [[package]] name = "wide" version = "0.7.13" diff --git a/Cargo.toml b/Cargo.toml index 4f500734b..e995012d7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,7 +18,7 @@ clap = { version = "4", default-features = false } ed25519-dalek = { version = "2", default-features = false } ethereum = { version = "0.14", default-features = false } ethers-core = { version = "2.0.3", default-features = false } -evm = { version = "0.37", default-features = false } +evm = { git = "https://github.com/rust-blockchain/evm", rev = "b7b82c7e1fc57b7449d6dfa6826600de37cc1e65", default-features = false } fdlimit = { version = "0.2", default-features = false } futures = { version = "0.3", default-features = false } getrandom = { version = "0.2", default-features = false } @@ -66,96 +66,97 @@ wiremock = { version = "0.5", default-features = false } codec = { package = "parity-scale-codec", version = "3.2.2", default-features = false } # Substrate fork. -frame-benchmarking = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-benchmarking-cli = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-executive = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-support = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-system = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-system-benchmarking = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-system-rpc-runtime-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -frame-try-runtime = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-authorship = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-babe = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-balances = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-grandpa = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-im-online = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-multisig = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-offences = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-session = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-sudo = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-timestamp = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-transaction-payment = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-transaction-payment-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-utility = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-basic-authorship = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-chain-spec = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-chain-spec-derive = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-cli = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-client-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-consensus = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-consensus-babe = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-consensus-babe-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-consensus-epochs = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-executor = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-finality-grandpa = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-finality-grandpa-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-network = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-rpc-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-rpc-spec-v2 = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-service = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-telemetry = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-tracing = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-transaction-pool = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-transaction-pool-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sc-utils = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-application-crypto = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-block-builder = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-blockchain = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-consensus = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-consensus-babe = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-core = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-core-hashing-proc-macro = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-finality-grandpa = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-inherents = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-io = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-keyring = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-keystore = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-offchain = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-panic-handler = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-runtime = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-session = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-staking = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-std = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-timestamp = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-tracing = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-transaction-pool = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -sp-version = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -substrate-frame-rpc-system = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -substrate-wasm-builder = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } -try-runtime-cli = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.39", default-features = false } +frame-benchmarking = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-benchmarking-cli = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-executive = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-support = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-system = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-system-benchmarking = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-system-rpc-runtime-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +frame-try-runtime = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-authorship = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-babe = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-balances = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-grandpa = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-im-online = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-multisig = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-offences = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-session = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-sudo = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-timestamp = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-transaction-payment = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-transaction-payment-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-utility = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-basic-authorship = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-chain-spec = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-chain-spec-derive = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-cli = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-client-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-consensus = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-consensus-babe = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-consensus-babe-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-consensus-epochs = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-consensus-grandpa = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-consensus-grandpa-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-executor = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-network = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-network-sync = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-rpc = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-rpc-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-rpc-spec-v2 = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-service = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-telemetry = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-tracing = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-transaction-pool = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-transaction-pool-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sc-utils = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-api = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-application-crypto = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-block-builder = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-blockchain = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-consensus = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-consensus-babe = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-consensus-grandpa = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-core = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-core-hashing-proc-macro = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-inherents = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-io = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-keyring = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-keystore = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-offchain = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-panic-handler = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-runtime = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-session = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-staking = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-std = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-timestamp = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-tracing = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-transaction-pool = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +sp-version = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +substrate-frame-rpc-system = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +substrate-wasm-builder = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } +try-runtime-cli = { git = "https://github.com/humanode-network/substrate", branch = "locked/polkadot-v0.9.40", default-features = false } # Frontier fork. -fc-cli = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fc-consensus = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fc-db = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fc-mapping-sync = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fc-rpc = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fc-rpc-core = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fc-storage = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fp-evm = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fp-rpc = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fp-self-contained = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -fp-storage = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-ethereum = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-evm = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-evm-balances = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-evm-precompile-modexp = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-evm-precompile-sha3fips = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-evm-precompile-simple = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } -pallet-evm-system = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.39", default-features = false } +fc-cli = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fc-consensus = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fc-db = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fc-mapping-sync = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fc-rpc = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fc-rpc-core = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fc-storage = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fp-evm = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fp-rpc = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fp-self-contained = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +fp-storage = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-ethereum = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-evm = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-evm-balances = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-evm-precompile-modexp = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-evm-precompile-sha3fips = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-evm-precompile-simple = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } +pallet-evm-system = { git = "https://github.com/humanode-network/frontier", branch = "locked/polkadot-v0.9.40", default-features = false } [profile.release-lto] inherits = "release" diff --git a/crates/crypto-utils/Cargo.toml b/crates/crypto-utils/Cargo.toml index d29c98799..c93c9a3aa 100644 --- a/crates/crypto-utils/Cargo.toml +++ b/crates/crypto-utils/Cargo.toml @@ -8,5 +8,5 @@ publish = false frame-support = { workspace = true } pallet-im-online = { workspace = true } sp-consensus-babe = { workspace = true } -sp-finality-grandpa = { workspace = true } +sp-consensus-grandpa = { workspace = true } sp-runtime = { workspace = true } diff --git a/crates/crypto-utils/src/lib.rs b/crates/crypto-utils/src/lib.rs index 5f34a8564..e377aa395 100644 --- a/crates/crypto-utils/src/lib.rs +++ b/crates/crypto-utils/src/lib.rs @@ -2,7 +2,7 @@ use pallet_im_online::sr25519::AuthorityId as ImOnlineId; use sp_consensus_babe::AuthorityId as BabeId; -use sp_finality_grandpa::AuthorityId as GrandpaId; +use sp_consensus_grandpa::AuthorityId as GrandpaId; use sp_runtime::{ app_crypto::{Pair, Public}, traits::IdentifyAccount, diff --git a/crates/humanode-peer/Cargo.toml b/crates/humanode-peer/Cargo.toml index 2c213b6c4..3ed7b7551 100644 --- a/crates/humanode-peer/Cargo.toml +++ b/crates/humanode-peer/Cargo.toml @@ -27,8 +27,8 @@ clap = { workspace = true, features = ["derive"] } codec = { workspace = true, package = "parity-scale-codec" } fc-cli = { workspace = true } fc-consensus = { workspace = true } -fc-db = { workspace = true } -fc-mapping-sync = { workspace = true } +fc-db = { workspace = true, features = ["sql"] } +fc-mapping-sync = { workspace = true, features = ["sql"] } fc-rpc = { workspace = true } fc-rpc-core = { workspace = true } fc-storage = { workspace = true } @@ -53,8 +53,8 @@ sc-cli = { workspace = true } sc-client-api = { workspace = true } sc-consensus = { workspace = true } sc-consensus-babe = { workspace = true } +sc-consensus-grandpa = { workspace = true } sc-executor = { workspace = true } -sc-finality-grandpa = { workspace = true } sc-service = { workspace = true } sc-telemetry = { workspace = true } sc-transaction-pool = { workspace = true } @@ -63,8 +63,8 @@ serde_json = { workspace = true } sp-api = { workspace = true } sp-application-crypto = { workspace = true } sp-consensus-babe = { workspace = true } +sp-consensus-grandpa = { workspace = true } sp-core = { workspace = true } -sp-finality-grandpa = { workspace = true } sp-inherents = { workspace = true } sp-io = { workspace = true } sp-keyring = { workspace = true } @@ -87,7 +87,8 @@ sp-io = { workspace = true } vergen = { workspace = true, features = ["cargo", "git", "gitcl"] } [features] -default = [] +default = ["rocksdb"] +rocksdb = ["fc-db/rocksdb"] runtime-benchmarks = [ "frame-benchmarking-cli/runtime-benchmarks", "frame-benchmarking/runtime-benchmarks", diff --git a/crates/humanode-peer/src/chain_spec.rs b/crates/humanode-peer/src/chain_spec.rs index bc47b1b2d..4a8b79c9a 100644 --- a/crates/humanode-peer/src/chain_spec.rs +++ b/crates/humanode-peer/src/chain_spec.rs @@ -15,7 +15,7 @@ use sc_chain_spec_derive::{ChainSpecExtension, ChainSpecGroup}; use sc_service::ChainType; use serde::{Deserialize, Serialize}; use sp_consensus_babe::AuthorityId as BabeId; -use sp_finality_grandpa::AuthorityId as GrandpaId; +use sp_consensus_grandpa::AuthorityId as GrandpaId; use sp_runtime::{app_crypto::sr25519, traits::Verify}; /// The concrete chain spec type we're using for the humanode network. diff --git a/crates/humanode-peer/src/cli/config.rs b/crates/humanode-peer/src/cli/config.rs index 5af2c44b4..aa5da88fc 100644 --- a/crates/humanode-peer/src/cli/config.rs +++ b/crates/humanode-peer/src/cli/config.rs @@ -54,6 +54,15 @@ pub trait CliConfigurationExt: SubstrateCliConfigurationProvider { execute_gas_limit_multiplier: params.execute_gas_limit_multiplier, }); + let fb_params = self.frontier_backend(); + let frontier_backend = configuration::FrontierBackend { + frontier_backend_type: fb_params.frontier_backend_type, + frontier_sql_backend_pool_size: fb_params.frontier_sql_backend_pool_size, + frontier_sql_backend_num_ops_timeout: fb_params.frontier_sql_backend_num_ops_timeout, + frontier_sql_backend_thread_count: fb_params.frontier_sql_backend_thread_count, + frontier_sql_backend_cache_size: fb_params.frontier_sql_backend_cache_size, + }; + let time_warp = self.time_warp_params().and_then(|params| { params .time_warp_fork_timestamp @@ -71,6 +80,7 @@ pub trait CliConfigurationExt: SubstrateCliConfigurationProvider { substrate, bioauth_flow, ethereum_rpc, + frontier_backend, time_warp, }) } @@ -85,6 +95,11 @@ pub trait CliConfigurationExt: SubstrateCliConfigurationProvider { None } + /// Provide the Frontier backend params. + fn frontier_backend(&self) -> params::FrontierBackendParams { + Default::default() + } + /// Provide the time warp related params, if available. fn time_warp_params(&self) -> Option<¶ms::TimeWarpParams> { None diff --git a/crates/humanode-peer/src/cli/params.rs b/crates/humanode-peer/src/cli/params.rs index 168043a43..667229afa 100644 --- a/crates/humanode-peer/src/cli/params.rs +++ b/crates/humanode-peer/src/cli/params.rs @@ -1,5 +1,7 @@ //! Shared CLI parameters. +use crate::configuration::FrontierBackendType; + /// Possible RPC URL scheme preference options. #[derive(Debug, clap::ValueEnum, Clone)] pub enum RpcUrlSchemePreference { @@ -75,6 +77,31 @@ pub struct EthereumRpcParams { pub execute_gas_limit_multiplier: u64, } +/// Shared CLI parameters used to configure Frontier backend. +#[derive(Debug, Default, clap::Parser, Clone)] +pub struct FrontierBackendParams { + /// Sets the frontier backend type (KeyValue or Sql). + #[arg(long, value_enum, ignore_case = true, default_value_t = FrontierBackendType::default())] + pub frontier_backend_type: FrontierBackendType, + + /// Sets the SQL backend's pool size. + #[arg(long, default_value = "100")] + pub frontier_sql_backend_pool_size: u32, + + /// Sets the SQL backend's query timeout in number of VM ops. + #[arg(long, default_value = "10000000")] + pub frontier_sql_backend_num_ops_timeout: u32, + + /// Sets the SQL backend's auxiliary thread limit. + #[arg(long, default_value = "4")] + pub frontier_sql_backend_thread_count: u32, + + /// Sets the SQL backend's query timeout in number of VM ops. + /// Default value is 200MB. + #[arg(long, default_value = "209715200")] + pub frontier_sql_backend_cache_size: u64, +} + /// Shared CLI parameters used to configure time warp mode. #[derive(Debug, clap::Parser, Clone)] pub struct TimeWarpParams { diff --git a/crates/humanode-peer/src/cli/run.rs b/crates/humanode-peer/src/cli/run.rs index dbef7a99d..5353507a1 100644 --- a/crates/humanode-peer/src/cli/run.rs +++ b/crates/humanode-peer/src/cli/run.rs @@ -6,7 +6,7 @@ use frame_benchmarking_cli::*; use humanode_runtime::Block; #[cfg(feature = "runtime-benchmarks")] use humanode_runtime::Runtime; -use sc_service::PartialComponents; +use sc_service::{DatabaseSource, PartialComponents}; #[cfg(feature = "runtime-benchmarks")] use sp_core::Get; #[cfg(feature = "try-runtime")] @@ -18,7 +18,7 @@ use { use super::{bioauth, Root, Subcommand}; #[cfg(feature = "runtime-benchmarks")] use crate::benchmarking::{inherent_benchmark_data, RemarkBuilder, TransferKeepAliveBuilder}; -use crate::service; +use crate::{configuration, service}; /// Parse command line arguments and run the requested operation. pub async fn run() -> sc_cli::Result<()> { @@ -86,7 +86,10 @@ pub async fn run() -> sc_cli::Result<()> { } Some(Subcommand::PurgeChain(cmd)) => { let runner = root.create_humanode_runner(cmd)?; - runner.sync_run(|config| cmd.run(config.substrate.database)) + runner.sync_run(|config| { + remove_frontier_offchain_db(cmd, &config)?; + cmd.run(config.substrate.database) + }) } Some(Subcommand::Revert(cmd)) => { let runner = root.create_humanode_runner(cmd)?; @@ -100,7 +103,7 @@ pub async fn run() -> sc_cli::Result<()> { } = service::new_partial(&config)?; let aux_revert = Box::new(|client, backend, blocks| { sc_consensus_babe::revert(Arc::clone(&client), backend, blocks)?; - sc_finality_grandpa::revert(client, blocks)?; + sc_consensus_grandpa::revert(client, blocks)?; Ok(()) }); Ok((cmd.run(client, backend, Some(aux_revert)), task_manager)) @@ -230,7 +233,12 @@ pub async fn run() -> sc_cli::Result<()> { let runner = root.create_humanode_runner(cmd)?; runner.sync_run(|config| { let partial = service::new_partial(&config)?; - let frontier_backend = partial.other.4; + let frontier_backend = match partial.other.4 { + fc_db::Backend::KeyValue(kv_fb) => Arc::new(kv_fb), + _ => { + panic!("Only fc_db::Backend::KeyValue supported for FrontierDb command") + } + }; cmd.run(partial.client, frontier_backend) }) } @@ -297,3 +305,44 @@ fn print_build_info() { crate::build_info::CARGO_FEATURES ); } + +/// Remove Frontier offchain db. +fn remove_frontier_offchain_db( + cmd: &sc_cli::PurgeChainCmd, + config: &configuration::Configuration, +) -> sc_cli::Result<()> { + let fdb_config_dir = service::frontier::db_config_dir(&config.substrate); + + match config.frontier_backend.frontier_backend_type { + crate::configuration::FrontierBackendType::KeyValue => { + let frontier_database_config = match config.substrate.database { + DatabaseSource::RocksDb { .. } => DatabaseSource::RocksDb { + path: fc_db::kv::frontier_database_dir(&fdb_config_dir, "db"), + cache_size: 0, + }, + DatabaseSource::ParityDb { .. } => DatabaseSource::ParityDb { + path: fc_db::kv::frontier_database_dir(&fdb_config_dir, "paritydb"), + }, + _ => panic!("frontier supports either rocksdb or paritydb"), + }; + cmd.run(frontier_database_config)?; + } + crate::configuration::FrontierBackendType::Sql => { + let db_path = fdb_config_dir.join("sql"); + + match std::fs::remove_dir_all(&db_path) { + Ok(_) => { + tracing::info!("{:?} removed.", &db_path); + } + Err(ref err) if err.kind() == std::io::ErrorKind::NotFound => { + tracing::error!("{:?} did not exist.", &db_path); + } + Err(err) => { + return Err(format!("Cannot purge `{:?}` database: {:?}", db_path, err).into()) + } + }; + } + }; + + Ok(()) +} diff --git a/crates/humanode-peer/src/configuration.rs b/crates/humanode-peer/src/configuration.rs index 81b741c21..920255c74 100644 --- a/crates/humanode-peer/src/configuration.rs +++ b/crates/humanode-peer/src/configuration.rs @@ -21,6 +21,9 @@ pub struct Configuration { /// Ethereum RPC configuration. pub ethereum_rpc: Option, + /// Frontier backend configuration. + pub frontier_backend: FrontierBackend, + /// Time warp mode configuration. /// If not defined, time warp mode isn't enabled. pub time_warp: Option, @@ -73,3 +76,32 @@ pub struct EthereumRpc { /// block.gas_limit * execute_gas_limit_multiplier. pub execute_gas_limit_multiplier: u64, } + +/// Frontier backend configuration parameters. +pub struct FrontierBackend { + /// Sets the frontier backend type (KeyValue or Sql). + pub frontier_backend_type: FrontierBackendType, + + /// Sets the SQL backend's pool size. + pub frontier_sql_backend_pool_size: u32, + + /// Sets the SQL backend's query timeout in number of VM ops. + pub frontier_sql_backend_num_ops_timeout: u32, + + /// Sets the SQL backend's auxiliary thread limit. + pub frontier_sql_backend_thread_count: u32, + + /// Sets the SQL backend's query timeout in number of VM ops. + /// Default value is 200MB. + pub frontier_sql_backend_cache_size: u64, +} + +/// Avalailable frontier backend types. +#[derive(Default, Debug, Copy, Clone, clap::ValueEnum)] +pub enum FrontierBackendType { + /// Either RocksDb or ParityDb as per inherited from the global backend settings. + #[default] + KeyValue, + /// Sql database with custom log indexing. + Sql, +} diff --git a/crates/humanode-peer/src/service/frontier.rs b/crates/humanode-peer/src/service/frontier.rs index 9330c6faa..7d5539f8b 100644 --- a/crates/humanode-peer/src/service/frontier.rs +++ b/crates/humanode-peer/src/service/frontier.rs @@ -1,9 +1,15 @@ //! The Frontier related stuff. +use std::{path::Path, sync::Arc}; + +use fc_storage::OverrideHandle; use humanode_runtime::opaque::Block; use sc_cli::SubstrateCli; use sc_client_api::backend::Backend; -use sc_service::BasePath; +use sc_service::{BasePath, Configuration}; + +use super::{FrontierBackend, FullClient, ServiceError}; +use crate::configuration::{self, FrontierBackendType}; /// Create frontier dir. pub fn db_config_dir(config: &sc_service::Configuration) -> std::path::PathBuf { @@ -17,6 +23,45 @@ pub fn db_config_dir(config: &sc_service::Configuration) -> std::path::PathBuf { }) } +/// Create frontier backend. +pub fn backend( + config: &Configuration, + client: Arc, + fb_config: &configuration::FrontierBackend, + eth_overrides: Arc>, +) -> Result { + match fb_config.frontier_backend_type { + FrontierBackendType::KeyValue => Ok(FrontierBackend::KeyValue(fc_db::kv::Backend::open( + Arc::clone(&client), + &config.database, + &db_config_dir(config), + )?)), + FrontierBackendType::Sql => { + let db_path = db_config_dir(config).join("sql"); + std::fs::create_dir_all(&db_path)?; + + let backend = futures::executor::block_on(fc_db::sql::Backend::new( + fc_db::sql::BackendConfig::Sqlite(fc_db::sql::SqliteBackendConfig { + path: Path::new("sqlite:///") + .join(db_path) + .join("frontier.db3") + .to_str() + .ok_or(ServiceError::Other("invalid sqlite path".to_owned()))?, + create_if_missing: true, + thread_count: fb_config.frontier_sql_backend_thread_count, + cache_size: fb_config.frontier_sql_backend_cache_size, + }), + fb_config.frontier_sql_backend_pool_size, + std::num::NonZeroU32::new(fb_config.frontier_sql_backend_num_ops_timeout), + Arc::clone(ð_overrides), + )) + .map_err(|err| ServiceError::Application(err.into()))?; + + Ok(FrontierBackend::Sql(backend)) + } + } +} + /// Default ethereum config. pub struct DefaultEthConfig(std::marker::PhantomData<(C, BE)>); diff --git a/crates/humanode-peer/src/service/mod.rs b/crates/humanode-peer/src/service/mod.rs index bd859e044..d8facb35f 100644 --- a/crates/humanode-peer/src/service/mod.rs +++ b/crates/humanode-peer/src/service/mod.rs @@ -8,15 +8,14 @@ use std::{ }; use fc_consensus::FrontierBlockImport; -use fc_mapping_sync::{MappingSyncWorker, SyncStrategy}; use fc_rpc::EthTask; use fc_rpc_core::types::{FeeHistoryCache, FilterPool}; use futures::StreamExt; use humanode_runtime::{self, opaque::Block, RuntimeApi}; use sc_client_api::{BlockBackend, BlockchainEvents}; use sc_consensus_babe::SlotProportion; +use sc_consensus_grandpa::SharedVoterState; pub use sc_executor::NativeElseWasmExecutor; -use sc_finality_grandpa::SharedVoterState; use sc_service::{ Error as ServiceError, KeystoreContainer, PartialComponents, TaskManager, WarpSyncParams, }; @@ -61,7 +60,7 @@ type FullBackend = sc_service::TFullBackend; type FullSelectChain = sc_consensus::LongestChain; /// Full type for `GrandpaBlockImport`. type FullGrandpa = - sc_finality_grandpa::GrandpaBlockImport; + sc_consensus_grandpa::GrandpaBlockImport; /// Full type for `BabeBlockImport`. type FullBabe = sc_consensus_babe::BabeBlockImport; /// Full type for `FrontierBlockImport`. @@ -98,11 +97,11 @@ pub fn new_partial( sc_consensus::DefaultImportQueue, sc_transaction_pool::FullPool, ( - sc_finality_grandpa::LinkHalf, + sc_consensus_grandpa::LinkHalf, sc_consensus_babe::BabeLink, EffectiveFullBlockImport, inherents::Creator, - Arc, + FrontierBackend, Option, ), >, @@ -111,6 +110,7 @@ pub fn new_partial( let Configuration { substrate: config, time_warp: time_warp_config, + frontier_backend: fronter_backend_config, .. } = config; @@ -157,7 +157,7 @@ pub fn new_partial( let select_chain = sc_consensus::LongestChain::new(Arc::clone(&backend)); - let (grandpa_block_import, grandpa_link) = sc_finality_grandpa::block_import( + let (grandpa_block_import, grandpa_link) = sc_consensus_grandpa::block_import( Arc::clone(&client), &(Arc::clone(&client) as Arc<_>), select_chain.clone(), @@ -170,16 +170,14 @@ pub fn new_partial( Arc::clone(&client), )?; - let frontier_backend = Arc::new(FrontierBackend::open( - Arc::clone(&client), - &config.database, - &frontier::db_config_dir(config), - )?); - let frontier_block_import = FrontierBlockImport::new( - babe_block_import, + let frontier_backend = frontier::backend( + config, Arc::clone(&client), - Arc::clone(&frontier_backend), - ); + fronter_backend_config, + fc_storage::overrides_handle(Arc::clone(&client)), + )?; + + let frontier_block_import = FrontierBlockImport::new(babe_block_import, Arc::clone(&client)); let raw_slot_duration = babe_link.config().slot_duration(); let inherent_data_providers_creator = inherents::Creator { @@ -246,7 +244,7 @@ pub async fn new_full(config: Configuration) -> Result Result Result Result Result Result Result Arc::new(b), + fc_db::Backend::Sql(b) => Arc::new(b), + }, eth_max_past_logs: ethereum_rpc_config.max_past_logs, eth_fee_history_limit, eth_fee_history_cache: Arc::clone(ð_fee_history_cache), @@ -449,6 +452,7 @@ pub async fn new_full(config: Configuration) -> Result Result Result Result Result::Number, - 0, - SyncStrategy::Normal, - network, - eth_pubsub_notification_sinks, - ) - .for_each(|()| futures::future::ready(())), - ); + match frontier_backend { + fc_db::Backend::KeyValue(b) => { + task_manager.spawn_essential_handle().spawn( + "frontier-mapping-sync-worker", + Some("evm"), + fc_mapping_sync::kv::MappingSyncWorker::new( + client.import_notification_stream(), + Duration::from_millis(humanode_runtime::SLOT_DURATION), + Arc::clone(&client), + backend, + Arc::clone(ð_overrides), + Arc::new(b), + // retry_times: usize. + 3, + // sync_from: ::Number. + 0, + fc_mapping_sync::SyncStrategy::Normal, + sync_service, + eth_pubsub_notification_sinks, + ) + .for_each(|()| futures::future::ready(())), + ); + } + fc_db::Backend::Sql(b) => { + task_manager.spawn_essential_handle().spawn_blocking( + "frontier-mapping-sync-worker", + Some("evm"), + fc_mapping_sync::sql::SyncWorker::run( + Arc::clone(&client), + backend, + Arc::new(b), + client.import_notification_stream(), + fc_mapping_sync::sql::SyncWorkerConfig { + read_notification_timeout: Duration::from_secs(10), + check_indexed_blocks_interval: Duration::from_secs(60), + }, + fc_mapping_sync::SyncStrategy::Parachain, + sync_service, + eth_pubsub_notification_sinks, + ), + ); + } + } // Spawn Frontier FeeHistory cache maintenance task. task_manager.spawn_essential_handle().spawn( diff --git a/crates/humanode-rpc/Cargo.toml b/crates/humanode-rpc/Cargo.toml index 7ea74f958..384b84cfe 100644 --- a/crates/humanode-rpc/Cargo.toml +++ b/crates/humanode-rpc/Cargo.toml @@ -26,9 +26,10 @@ sc-client-api = { workspace = true } sc-consensus-babe = { workspace = true } sc-consensus-babe-rpc = { workspace = true } sc-consensus-epochs = { workspace = true } -sc-finality-grandpa = { workspace = true } -sc-finality-grandpa-rpc = { workspace = true } +sc-consensus-grandpa = { workspace = true } +sc-consensus-grandpa-rpc = { workspace = true } sc-network = { workspace = true } +sc-network-sync = { workspace = true } sc-rpc = { workspace = true } sc-rpc-api = { workspace = true } sc-rpc-spec-v2 = { workspace = true } diff --git a/crates/humanode-rpc/src/lib.rs b/crates/humanode-rpc/src/lib.rs index fa5ec7169..290972b8c 100644 --- a/crates/humanode-rpc/src/lib.rs +++ b/crates/humanode-rpc/src/lib.rs @@ -8,7 +8,7 @@ use bioauth_flow_rpc::{Bioauth, BioauthServer, Signer, SignerFactory}; use bioauth_keys::traits::KeyExtractor as KeyExtractorT; use fc_rpc::{ Eth, EthApiServer, EthBlockDataCacheTask, EthConfig, EthFilter, EthFilterApiServer, EthPubSub, - EthPubSubApiServer, Net, NetApiServer, Web3, Web3ApiServer, + EthPubSubApiServer, Net, NetApiServer, TxPoolApiServer, Web3, Web3ApiServer, }; use fc_rpc_core::types::{FeeHistoryCache, FilterPool}; use fc_storage::OverrideHandle; @@ -24,11 +24,12 @@ use sc_client_api::{ use sc_consensus_babe::{BabeConfiguration, Epoch}; use sc_consensus_babe_rpc::{Babe, BabeApiServer}; use sc_consensus_epochs::SharedEpochChanges; -use sc_finality_grandpa::{ +use sc_consensus_grandpa::{ FinalityProofProvider, GrandpaJustificationStream, SharedAuthoritySet, SharedVoterState, }; -use sc_finality_grandpa_rpc::{Grandpa, GrandpaApiServer}; +use sc_consensus_grandpa_rpc::{Grandpa, GrandpaApiServer}; use sc_network::NetworkService; +use sc_network_sync::SyncingService; pub use sc_rpc_api::DenyUnsafe; use sc_rpc_spec_v2::chain_spec::{ChainSpec, ChainSpecApiServer}; use sc_transaction_pool::{ChainApi, Pool}; @@ -86,7 +87,7 @@ pub struct EvmDeps { /// Maximum number of stored filters. pub eth_max_stored_filters: usize, /// Backend. - pub eth_backend: Arc>, + pub eth_backend: Arc + Send + Sync>, /// Maximum number of logs in a query. pub eth_max_past_logs: u32, /// Maximum fee history cache size. @@ -126,8 +127,10 @@ pub struct Deps { pub deny_unsafe: DenyUnsafe, /// Graph pool instance. pub graph: Arc>, - /// Network service + /// Network service. pub network: Arc>, + /// Chain syncing service. + pub sync: Arc>, /// A copy of the chain spec. pub chain_spec: Box, /// AuthorExt specific dependencies. @@ -191,6 +194,7 @@ where deny_unsafe, graph, network, + sync, chain_spec, author_ext, is_authority, @@ -301,9 +305,9 @@ where Eth::new( Arc::clone(&client), Arc::clone(&pool), - graph, + Arc::clone(&graph), Some(humanode_runtime::TransactionConverter), - Arc::clone(&network), + Arc::clone(&sync), Vec::new(), Arc::clone(ð_overrides), Arc::clone(ð_backend), @@ -324,7 +328,7 @@ where EthPubSub::new( Arc::clone(&pool), Arc::clone(&client), - Arc::clone(&network), + Arc::clone(&sync), Arc::clone(&subscription_task_executor), Arc::clone(ð_overrides), Arc::clone(ð_pubsub_notification_sinks), @@ -342,11 +346,14 @@ where .into_rpc(), )?; + let eth_tx_pool = fc_rpc::TxPool::new(Arc::clone(&client), graph); + if let Some(eth_filter_pool) = eth_filter_pool { io.merge( EthFilter::new( client, eth_backend, + eth_tx_pool.clone(), eth_filter_pool, eth_max_stored_filters, eth_max_past_logs, @@ -356,5 +363,7 @@ where )?; } + io.merge(eth_tx_pool.into_rpc())?; + Ok(io) } diff --git a/crates/humanode-runtime/src/constants.rs b/crates/humanode-runtime/src/constants.rs index 8814e1eb9..51567f77e 100644 --- a/crates/humanode-runtime/src/constants.rs +++ b/crates/humanode-runtime/src/constants.rs @@ -113,6 +113,12 @@ pub mod evm_fees { /// - so we must charge about 0.2 * 10^18 / 21000 fee per a unit of gas /// The value below is a nice round number that fits the requirements outlined above. pub const FEE_PER_GAS: u128 = 10_000_000_000_000; + + /// The max proof size ratio per block. + /// Set to the zero as humanode is solo chain. Otherwise, additional used gas has + /// been added to transactions cost. + /// Ref: + pub const GAS_LIMIT_POV_SIZE_RATIO: u64 = 0; } /// Ethereum related constants. diff --git a/crates/humanode-runtime/src/frontier_precompiles.rs b/crates/humanode-runtime/src/frontier_precompiles.rs index c1b820853..004d768ef 100644 --- a/crates/humanode-runtime/src/frontier_precompiles.rs +++ b/crates/humanode-runtime/src/frontier_precompiles.rs @@ -1,5 +1,7 @@ use frame_support::traits::Currency; -use pallet_evm::{Precompile, PrecompileHandle, PrecompileResult, PrecompileSet}; +use pallet_evm::{ + IsPrecompileResult, Precompile, PrecompileHandle, PrecompileResult, PrecompileSet, +}; use pallet_evm_precompile_modexp::Modexp; use pallet_evm_precompile_sha3fips::Sha3FIPS256; use pallet_evm_precompile_simple::{ECRecover, ECRecoverPublicKey, Identity, Ripemd160, Sha256}; @@ -120,8 +122,11 @@ where } } - fn is_precompile(&self, address: H160) -> bool { - Self::used_addresses().contains(&address) + fn is_precompile(&self, address: H160, _gas: u64) -> IsPrecompileResult { + IsPrecompileResult::Answer { + is_precompile: Self::used_addresses().contains(&address), + extra_cost: 0, + } } } diff --git a/crates/humanode-runtime/src/lib.rs b/crates/humanode-runtime/src/lib.rs index 3a7d08d55..2fa5e847e 100644 --- a/crates/humanode-runtime/src/lib.rs +++ b/crates/humanode-runtime/src/lib.rs @@ -21,7 +21,7 @@ pub use frame_support::{ construct_runtime, parameter_types, traits::{ ConstBool, ConstU128, ConstU16, ConstU32, ConstU64, ConstU8, FindAuthor, Get, - KeyOwnerProofSystem, Randomness, + KeyOwnerProofSystem, OnFinalize, Randomness, }, weights::{ constants::{ @@ -312,19 +312,12 @@ impl pallet_babe::Config for Runtime { type EpochChangeTrigger = pallet_babe::ExternalTrigger; type DisabledValidators = Session; - type KeyOwnerProofSystem = Historical; - type KeyOwnerProof = - >::Proof; - - type KeyOwnerIdentification = >::IdentificationTuple; - - type HandleEquivocation = pallet_babe::EquivocationHandler< - Self::KeyOwnerIdentification, + >::Proof; + type EquivocationReportSystem = pallet_babe::EquivocationReportSystem< + Self, Offences, + Historical, ConstU64, >; @@ -361,19 +354,11 @@ impl pallet_session::historical::Config for Runtime { impl pallet_grandpa::Config for Runtime { type RuntimeEvent = RuntimeEvent; - type KeyOwnerProofSystem = Historical; - - type KeyOwnerProof = - >::Proof; - - type KeyOwnerIdentification = >::IdentificationTuple; - - type HandleEquivocation = pallet_grandpa::EquivocationHandler< - Self::KeyOwnerIdentification, + type KeyOwnerProof = >::Proof; + type EquivocationReportSystem = pallet_grandpa::EquivocationReportSystem< + Self, Offences, + Historical, ConstU64, >; @@ -638,12 +623,13 @@ const_assert!(WEIGHT_MILLISECS_PER_BLOCK == 2000u64); parameter_types! { pub BlockGasLimit: U256 = U256::from(constants::evm_fees::BLOCK_GAS_LIMIT); + pub GasLimitPovSizeRatio: u64 = constants::evm_fees::GAS_LIMIT_POV_SIZE_RATIO; pub PrecompilesValue: FrontierPrecompiles = FrontierPrecompiles::<_>::default(); - pub WeightPerGas: Weight = Weight::from_ref_time(fp_evm::weight_per_gas( + pub WeightPerGas: Weight = Weight::from_parts(fp_evm::weight_per_gas( constants::evm_fees::BLOCK_GAS_LIMIT, NORMAL_DISPATCH_RATIO, WEIGHT_MILLISECS_PER_BLOCK, - )); + ), 0); } impl pallet_evm_system::Config for Runtime { @@ -702,6 +688,7 @@ impl pallet_evm::Config for Runtime { type FindAuthor = find_author::FindAuthorTruncated< find_author::FindAuthorFromSession, >; + type GasLimitPovSizeRatio = GasLimitPovSizeRatio; type Timestamp = Timestamp; type WeightInfo = pallet_evm::weights::SubstrateWeight; } @@ -834,7 +821,7 @@ impl pallet_dummy_precompiles_code::Config for Runtime { // Create the runtime by composing the FRAME pallets that were previously // configured. construct_runtime!( - pub enum Runtime where + pub struct Runtime where Block = Block, NodeBlock = opaque::Block, UncheckedExtrinsic = UncheckedExtrinsic @@ -1351,6 +1338,9 @@ impl_runtime_apis! { access_list.unwrap_or_default(), is_transactional, validate, + // TODO(#864): set proper values. + None, + None, &config, ).map_err(|err| err.error.into()) } @@ -1387,6 +1377,9 @@ impl_runtime_apis! { access_list.unwrap_or_default(), is_transactional, validate, + // TODO(#864): set proper values. + None, + None, &config, ).map_err(|err| err.error.into()) } @@ -1429,6 +1422,21 @@ impl_runtime_apis! { } fn gas_limit_multiplier_support() {} + + fn pending_block( + xts: Vec<::Extrinsic>, + ) -> (Option, Option>) { + for ext in xts { + let _ = Executive::apply_extrinsic(ext); + } + + Ethereum::on_finalize(System::block_number() + 1); + + ( + pallet_ethereum::CurrentBlock::::get(), + pallet_ethereum::CurrentTransactionStatuses::::get() + ) + } } impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi diff --git a/crates/humanode-runtime/src/tests/claims_and_vesting.rs b/crates/humanode-runtime/src/tests/claims_and_vesting.rs index e64837514..2f5101518 100644 --- a/crates/humanode-runtime/src/tests/claims_and_vesting.rs +++ b/crates/humanode-runtime/src/tests/claims_and_vesting.rs @@ -88,7 +88,7 @@ fn prepare_applyable_data( ); let normal_dispatch_info = DispatchInfo { - weight: Weight::from_ref_time(100), + weight: Weight::from_parts(100, 0), class: DispatchClass::Normal, pays_fee: Pays::No, }; diff --git a/crates/humanode-runtime/src/tests/currency_swap.rs b/crates/humanode-runtime/src/tests/currency_swap.rs index 300c05df9..a5ba72123 100644 --- a/crates/humanode-runtime/src/tests/currency_swap.rs +++ b/crates/humanode-runtime/src/tests/currency_swap.rs @@ -202,6 +202,8 @@ fn currency_swap_precompile_call_works() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -209,7 +211,7 @@ fn currency_swap_precompile_call_works() { execinfo.exit_reason, fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Returned) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, EvmDataWriter::new().write(true).build()); assert_eq!( execinfo.logs, diff --git a/crates/humanode-runtime/src/tests/fees.rs b/crates/humanode-runtime/src/tests/fees.rs index 945bd8dcb..697950bbc 100644 --- a/crates/humanode-runtime/src/tests/fees.rs +++ b/crates/humanode-runtime/src/tests/fees.rs @@ -169,7 +169,7 @@ pub mod crypto { } fn switch_block() { - use frame_support::traits::{OnFinalize, OnInitialize}; + use frame_support::traits::OnInitialize; if System::block_number() != 0 { AllPalletsWithSystem::on_finalize(System::block_number()); @@ -315,6 +315,8 @@ fn simple_evm_transaction_via_runner_estimate() { access_list, is_transactional, validate, + None, + None, config, ) .unwrap(); @@ -323,7 +325,11 @@ fn simple_evm_transaction_via_runner_estimate() { fp_evm::CallInfo { exit_reason: fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Stopped), value: vec![], - used_gas: 21000.into(), + used_gas: fp_evm::UsedGas { + standard: 21000.into(), + effective: 21000.into(), + }, + weight_info: Default::default(), logs: vec![] } ); diff --git a/crates/humanode-runtime/src/tests/fixed_supply.rs b/crates/humanode-runtime/src/tests/fixed_supply.rs index d29ab4c83..f198f2e75 100644 --- a/crates/humanode-runtime/src/tests/fixed_supply.rs +++ b/crates/humanode-runtime/src/tests/fixed_supply.rs @@ -209,7 +209,7 @@ fn total_issuance_transaction_payment_validate() { } .into(); let normal = DispatchInfo { - weight: Weight::from_ref_time(10), + weight: Weight::from_parts(10, 0), class: DispatchClass::Normal, pays_fee: Pays::Yes, }; diff --git a/crates/humanode-runtime/src/weights/frame_system.rs b/crates/humanode-runtime/src/weights/frame_system.rs index 61a3985c7..b4564aa9e 100644 --- a/crates/humanode-runtime/src/weights/frame_system.rs +++ b/crates/humanode-runtime/src/weights/frame_system.rs @@ -14,35 +14,35 @@ impl frame_system::WeightInfo for WeightInfo { /// The range of component `b` is `[0, 3932160]`. fn remark(_b: u32, ) -> Weight { // Minimum execution time: 3_000 nanoseconds. - Weight::from_ref_time(336_000_000) + Weight::from_parts(336_000_000, 0) } /// The range of component `b` is `[0, 3932160]`. fn remark_with_event(_b: u32, ) -> Weight { // Minimum execution time: 12_000 nanoseconds. - Weight::from_ref_time(4_281_000_000) + Weight::from_parts(4_281_000_000, 0) } fn set_heap_pages() -> Weight { // Minimum execution time: 8_000 nanoseconds. - Weight::from_ref_time(8_000_000) + Weight::from_parts(8_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(2)) } /// The range of component `i` is `[0, 1000]`. fn set_storage(_i: u32, ) -> Weight { // Minimum execution time: 4_000 nanoseconds. - Weight::from_ref_time(632_000_000) + Weight::from_parts(632_000_000, 0) .saturating_add(T::DbWeight::get().writes(1000)) } /// The range of component `i` is `[0, 1000]`. fn kill_storage(_i: u32, ) -> Weight { // Minimum execution time: 3_000 nanoseconds. - Weight::from_ref_time(580_000_000) + Weight::from_parts(580_000_000, 0) .saturating_add(T::DbWeight::get().writes(1000)) } /// The range of component `p` is `[0, 1000]`. fn kill_prefix(_p: u32, ) -> Weight { // Minimum execution time: 7_000 nanoseconds. - Weight::from_ref_time(1_467_000_000) + Weight::from_parts(1_467_000_000, 0) .saturating_add(T::DbWeight::get().writes(1000)) } } diff --git a/crates/humanode-runtime/src/weights/pallet_balances.rs b/crates/humanode-runtime/src/weights/pallet_balances.rs index 5b34e857b..4ab57445a 100644 --- a/crates/humanode-runtime/src/weights/pallet_balances.rs +++ b/crates/humanode-runtime/src/weights/pallet_balances.rs @@ -13,43 +13,43 @@ pub struct WeightInfo(PhantomData); impl pallet_balances::WeightInfo for WeightInfo { fn transfer() -> Weight { // Minimum execution time: 37_000 nanoseconds. - Weight::from_ref_time(37_000_000) + Weight::from_parts(37_000_000, 0) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } fn transfer_keep_alive() -> Weight { // Minimum execution time: 25_000 nanoseconds. - Weight::from_ref_time(25_000_000) + Weight::from_parts(25_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } fn set_balance_creating() -> Weight { // Minimum execution time: 20_000 nanoseconds. - Weight::from_ref_time(20_000_000) + Weight::from_parts(20_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } fn set_balance_killing() -> Weight { // Minimum execution time: 21_000 nanoseconds. - Weight::from_ref_time(21_000_000) + Weight::from_parts(21_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } fn force_transfer() -> Weight { // Minimum execution time: 37_000 nanoseconds. - Weight::from_ref_time(37_000_000) + Weight::from_parts(37_000_000, 0) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) } fn transfer_all() -> Weight { // Minimum execution time: 30_000 nanoseconds. - Weight::from_ref_time(30_000_000) + Weight::from_parts(30_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } fn force_unreserve() -> Weight { // Minimum execution time: 17_000 nanoseconds. - Weight::from_ref_time(17_000_000) + Weight::from_parts(17_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/crates/humanode-runtime/src/weights/pallet_bioauth.rs b/crates/humanode-runtime/src/weights/pallet_bioauth.rs index 8a1ff7c31..280b5f356 100644 --- a/crates/humanode-runtime/src/weights/pallet_bioauth.rs +++ b/crates/humanode-runtime/src/weights/pallet_bioauth.rs @@ -15,22 +15,22 @@ impl pallet_bioauth::WeightInfo for WeightInfo { /// The range of component `a` is `[0, 3071]`. fn authenticate(_a: u32, n: u32, ) -> Weight { // Minimum execution time: 127_000 nanoseconds. - Weight::from_ref_time(227_889_999_931) + Weight::from_parts(227_889_999_931, 0) // Standard Error: 9_401 - .saturating_add(Weight::from_ref_time(132_701).saturating_mul(n.into())) + .saturating_add(Weight::from_parts(132_701, 0).saturating_mul(n.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(2)) } /// The range of component `a` is `[0, 3072]`. fn set_robonode_public_key(_a: u32, ) -> Weight { // Minimum execution time: 6_000 nanoseconds. - Weight::from_ref_time(7_000_000) + Weight::from_parts(7_000_000, 0) .saturating_add(T::DbWeight::get().writes(2)) } /// The range of component `a` is `[0, 3072]`. fn on_initialize(_a: u32, ) -> Weight { // Minimum execution time: 6_000 nanoseconds. - Weight::from_ref_time(74_000_000) + Weight::from_parts(74_000_000, 0) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/crates/humanode-runtime/src/weights/pallet_evm_accounts_mapping.rs b/crates/humanode-runtime/src/weights/pallet_evm_accounts_mapping.rs index ff60aa1ea..8c5c10f5a 100644 --- a/crates/humanode-runtime/src/weights/pallet_evm_accounts_mapping.rs +++ b/crates/humanode-runtime/src/weights/pallet_evm_accounts_mapping.rs @@ -13,7 +13,7 @@ pub struct WeightInfo(PhantomData); impl pallet_evm_accounts_mapping::WeightInfo for WeightInfo { fn claim_account() -> Weight { // Minimum execution time: 58_000 nanoseconds. - Weight::from_ref_time(58_000_000) + Weight::from_parts(58_000_000, 0) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(2)) } diff --git a/crates/humanode-runtime/src/weights/pallet_im_online.rs b/crates/humanode-runtime/src/weights/pallet_im_online.rs index e8b76ba51..3a2c4209d 100644 --- a/crates/humanode-runtime/src/weights/pallet_im_online.rs +++ b/crates/humanode-runtime/src/weights/pallet_im_online.rs @@ -15,11 +15,11 @@ impl pallet_im_online::WeightInfo for WeightInfo { /// The range of component `k` is `[1, 1000]`. fn validate_unsigned_and_then_heartbeat(k: u32, e: u32, ) -> Weight { // Minimum execution time: 94_000 nanoseconds. - Weight::from_ref_time(71_732_732) + Weight::from_parts(71_732_732, 0) // Standard Error: 5_201 - .saturating_add(Weight::from_ref_time(45_045).saturating_mul(k.into())) + .saturating_add(Weight::from_parts(45_045, 0).saturating_mul(k.into())) // Standard Error: 52_486 - .saturating_add(Weight::from_ref_time(222_222).saturating_mul(e.into())) + .saturating_add(Weight::from_parts(222_222, 0).saturating_mul(e.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/crates/humanode-runtime/src/weights/pallet_multisig.rs b/crates/humanode-runtime/src/weights/pallet_multisig.rs index 8949e99ea..33705b650 100644 --- a/crates/humanode-runtime/src/weights/pallet_multisig.rs +++ b/crates/humanode-runtime/src/weights/pallet_multisig.rs @@ -14,17 +14,17 @@ impl pallet_multisig::WeightInfo for WeightInfo { /// The range of component `z` is `[0, 10000]`. fn as_multi_threshold_1(_z: u32, ) -> Weight { // Minimum execution time: 14_000 nanoseconds. - Weight::from_ref_time(16_000_000) + Weight::from_parts(16_000_000, 0) } /// The range of component `z` is `[0, 10000]`. /// The range of component `s` is `[2, 128]`. fn as_multi_create(s: u32, z: u32, ) -> Weight { // Minimum execution time: 34_000 nanoseconds. - Weight::from_ref_time(26_888_888) + Weight::from_parts(26_888_888, 0) // Standard Error: 0 - .saturating_add(Weight::from_ref_time(55_555).saturating_mul(s.into())) + .saturating_add(Weight::from_parts(55_555, 0).saturating_mul(s.into())) // Standard Error: 0 - .saturating_add(Weight::from_ref_time(1_000).saturating_mul(z.into())) + .saturating_add(Weight::from_parts(1_000, 0).saturating_mul(z.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -32,11 +32,11 @@ impl pallet_multisig::WeightInfo for WeightInfo { /// The range of component `z` is `[0, 10000]`. fn as_multi_approve(s: u32, z: u32, ) -> Weight { // Minimum execution time: 25_000 nanoseconds. - Weight::from_ref_time(19_368_000) + Weight::from_parts(19_368_000, 0) // Standard Error: 20_784 - .saturating_add(Weight::from_ref_time(44_000).saturating_mul(s.into())) + .saturating_add(Weight::from_parts(44_000, 0).saturating_mul(s.into())) // Standard Error: 259 - .saturating_add(Weight::from_ref_time(1_050).saturating_mul(z.into())) + .saturating_add(Weight::from_parts(1_050, 0).saturating_mul(z.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -44,30 +44,30 @@ impl pallet_multisig::WeightInfo for WeightInfo { /// The range of component `z` is `[0, 10000]`. fn as_multi_complete(s: u32, _z: u32, ) -> Weight { // Minimum execution time: 39_000 nanoseconds. - Weight::from_ref_time(47_349_206) + Weight::from_parts(47_349_206, 0) // Standard Error: 48_112 - .saturating_add(Weight::from_ref_time(75_396).saturating_mul(s.into())) + .saturating_add(Weight::from_parts(75_396, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } /// The range of component `s` is `[2, 128]`. fn approve_as_multi_create(_s: u32, ) -> Weight { // Minimum execution time: 30_000 nanoseconds. - Weight::from_ref_time(32_000_000) + Weight::from_parts(32_000_000, 0) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } /// The range of component `s` is `[2, 128]`. fn approve_as_multi_approve(_s: u32, ) -> Weight { // Minimum execution time: 20_000 nanoseconds. - Weight::from_ref_time(24_000_000) + Weight::from_parts(24_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } /// The range of component `s` is `[2, 128]`. fn cancel_as_multi(_s: u32, ) -> Weight { // Minimum execution time: 25_000 nanoseconds. - Weight::from_ref_time(35_000_000) + Weight::from_parts(35_000_000, 0) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/crates/humanode-runtime/src/weights/pallet_timestamp.rs b/crates/humanode-runtime/src/weights/pallet_timestamp.rs index fa2252cbe..e10e19d42 100644 --- a/crates/humanode-runtime/src/weights/pallet_timestamp.rs +++ b/crates/humanode-runtime/src/weights/pallet_timestamp.rs @@ -13,12 +13,12 @@ pub struct WeightInfo(PhantomData); impl pallet_timestamp::WeightInfo for WeightInfo { fn set() -> Weight { // Minimum execution time: 11_000 nanoseconds. - Weight::from_ref_time(11_000_000) + Weight::from_parts(11_000_000, 0) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } fn on_finalize() -> Weight { // Minimum execution time: 4_000 nanoseconds. - Weight::from_ref_time(4_000_000) + Weight::from_parts(4_000_000, 0) } } diff --git a/crates/humanode-runtime/src/weights/pallet_token_claims.rs b/crates/humanode-runtime/src/weights/pallet_token_claims.rs index d33c1c461..620fbe231 100644 --- a/crates/humanode-runtime/src/weights/pallet_token_claims.rs +++ b/crates/humanode-runtime/src/weights/pallet_token_claims.rs @@ -13,25 +13,25 @@ pub struct WeightInfo(PhantomData); impl pallet_token_claims::WeightInfo for WeightInfo { fn claim() -> Weight { // Minimum execution time: 93_000 nanoseconds. - Weight::from_ref_time(93_000_000) + Weight::from_parts(93_000_000, 0) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(5)) } fn add_claim() -> Weight { // Minimum execution time: 31_000 nanoseconds. - Weight::from_ref_time(31_000_000) + Weight::from_parts(31_000_000, 0) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(4)) } fn remove_claim() -> Weight { // Minimum execution time: 30_000 nanoseconds. - Weight::from_ref_time(30_000_000) + Weight::from_parts(30_000_000, 0) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(4)) } fn change_claim() -> Weight { // Minimum execution time: 32_000 nanoseconds. - Weight::from_ref_time(32_000_000) + Weight::from_parts(32_000_000, 0) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(4)) } diff --git a/crates/humanode-runtime/src/weights/pallet_utility.rs b/crates/humanode-runtime/src/weights/pallet_utility.rs index 877d886d8..52f65b149 100644 --- a/crates/humanode-runtime/src/weights/pallet_utility.rs +++ b/crates/humanode-runtime/src/weights/pallet_utility.rs @@ -14,24 +14,24 @@ impl pallet_utility::WeightInfo for WeightInfo { /// The range of component `c` is `[0, 1000]`. fn batch(_c: u32, ) -> Weight { // Minimum execution time: 11_000 nanoseconds. - Weight::from_ref_time(1_867_000_000) + Weight::from_parts(1_867_000_000, 0) } fn as_derivative() -> Weight { // Minimum execution time: 13_000 nanoseconds. - Weight::from_ref_time(13_000_000) + Weight::from_parts(13_000_000, 0) } /// The range of component `c` is `[0, 1000]`. fn batch_all(_c: u32, ) -> Weight { // Minimum execution time: 13_000 nanoseconds. - Weight::from_ref_time(2_124_000_000) + Weight::from_parts(2_124_000_000, 0) } fn dispatch_as() -> Weight { // Minimum execution time: 13_000 nanoseconds. - Weight::from_ref_time(13_000_000) + Weight::from_parts(13_000_000, 0) } /// The range of component `c` is `[0, 1000]`. fn force_batch(_c: u32, ) -> Weight { // Minimum execution time: 10_000 nanoseconds. - Weight::from_ref_time(1_822_000_000) + Weight::from_parts(1_822_000_000, 0) } } diff --git a/crates/humanode-runtime/src/weights/pallet_vesting.rs b/crates/humanode-runtime/src/weights/pallet_vesting.rs index a76b1e1e8..ef492ab2b 100644 --- a/crates/humanode-runtime/src/weights/pallet_vesting.rs +++ b/crates/humanode-runtime/src/weights/pallet_vesting.rs @@ -13,13 +13,13 @@ pub struct WeightInfo(PhantomData); impl pallet_vesting::WeightInfo for WeightInfo { fn unlock() -> Weight { // Minimum execution time: 35_000 nanoseconds. - Weight::from_ref_time(35_000_000) + Weight::from_parts(35_000_000, 0) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } fn update_schedule() -> Weight { // Minimum execution time: 38_000 nanoseconds. - Weight::from_ref_time(38_000_000) + Weight::from_parts(38_000_000, 0) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } diff --git a/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v0.rs b/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v0.rs index 8d7d39e4c..f119d8c60 100644 --- a/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v0.rs +++ b/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v0.rs @@ -19,12 +19,13 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, { - System: frame_system, + System: frame_system = 0, Balances: pallet_balances::, EvmBalances: pallet_balances::, } diff --git a/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v1.rs b/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v1.rs index e32f6e253..29b4efabd 100644 --- a/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v1.rs +++ b/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v1.rs @@ -22,12 +22,13 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, { - System: frame_system, + System: frame_system = 0, Balances: pallet_balances::, EvmBalances: pallet_balances::, SwapBridgeNativeToEvmPot: pallet_pot::, diff --git a/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v2.rs b/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v2.rs index eb97e1cdf..65792ea55 100644 --- a/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v2.rs +++ b/crates/pallet-balanced-currency-swap-bridges-initializer/src/mock/v2.rs @@ -22,12 +22,13 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, { - System: frame_system, + System: frame_system = 0, Balances: pallet_balances::, EvmBalances: pallet_balances::, SwapBridgeNativeToEvmPot: pallet_pot::, diff --git a/crates/pallet-bioauth/src/mock/testing.rs b/crates/pallet-bioauth/src/mock/testing.rs index 28abb0579..6a43d892f 100644 --- a/crates/pallet-bioauth/src/mock/testing.rs +++ b/crates/pallet-bioauth/src/mock/testing.rs @@ -27,7 +27,7 @@ pub type BlockNumber = u64; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-chain-properties/src/mock.rs b/crates/pallet-chain-properties/src/mock.rs index 5d58dbe52..fbc194b0a 100644 --- a/crates/pallet-chain-properties/src/mock.rs +++ b/crates/pallet-chain-properties/src/mock.rs @@ -17,7 +17,7 @@ pub type BlockNumber = u64; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-chain-start-moment/src/mock.rs b/crates/pallet-chain-start-moment/src/mock.rs index cc06ff770..0d9e3ce65 100644 --- a/crates/pallet-chain-start-moment/src/mock.rs +++ b/crates/pallet-chain-start-moment/src/mock.rs @@ -19,7 +19,7 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-currency-swap/src/mock.rs b/crates/pallet-currency-swap/src/mock.rs index 73d023f9a..d0f5b63ce 100644 --- a/crates/pallet-currency-swap/src/mock.rs +++ b/crates/pallet-currency-swap/src/mock.rs @@ -27,7 +27,8 @@ pub(crate) type EvmAccountId = H160; type Balance = u64; frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-dummy-precompiles-code/src/mock/v0.rs b/crates/pallet-dummy-precompiles-code/src/mock/v0.rs index 622ca6dcd..0524b1b42 100644 --- a/crates/pallet-dummy-precompiles-code/src/mock/v0.rs +++ b/crates/pallet-dummy-precompiles-code/src/mock/v0.rs @@ -20,7 +20,8 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, @@ -108,13 +109,14 @@ pub struct FixedGasPrice; impl fp_evm::FeeCalculator for FixedGasPrice { fn min_gas_price() -> (U256, Weight) { // Return some meaningful gas price and weight - (*GAS_PRICE, Weight::from_ref_time(7u64)) + (*GAS_PRICE, Weight::from_parts(7u64, 0)) } } frame_support::parameter_types! { pub BlockGasLimit: U256 = U256::max_value(); - pub WeightPerGas: Weight = Weight::from_ref_time(20_000); + pub GasLimitPovSizeRatio: u64 = 0; + pub WeightPerGas: Weight = Weight::from_parts(20_000, 0); } impl pallet_evm::Config for Test { @@ -140,6 +142,7 @@ impl pallet_evm::Config for Test { type OnChargeTransaction = (); type OnCreate = (); type FindAuthor = (); + type GasLimitPovSizeRatio = GasLimitPovSizeRatio; type Timestamp = Timestamp; type WeightInfo = (); } diff --git a/crates/pallet-dummy-precompiles-code/src/mock/v1.rs b/crates/pallet-dummy-precompiles-code/src/mock/v1.rs index ef657e8fe..0842439a9 100644 --- a/crates/pallet-dummy-precompiles-code/src/mock/v1.rs +++ b/crates/pallet-dummy-precompiles-code/src/mock/v1.rs @@ -25,7 +25,8 @@ pub(crate) type EvmAccountId = H160; type Balance = u64; frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, @@ -114,13 +115,14 @@ pub struct FixedGasPrice; impl fp_evm::FeeCalculator for FixedGasPrice { fn min_gas_price() -> (U256, Weight) { // Return some meaningful gas price and weight - (*GAS_PRICE, Weight::from_ref_time(7u64)) + (*GAS_PRICE, Weight::from_parts(7u64, 0)) } } frame_support::parameter_types! { pub BlockGasLimit: U256 = U256::max_value(); - pub WeightPerGas: Weight = Weight::from_ref_time(20_000); + pub GasLimitPovSizeRatio: u64 = 0; + pub WeightPerGas: Weight = Weight::from_parts(20_000, 0); } impl pallet_evm::Config for Test { @@ -146,6 +148,7 @@ impl pallet_evm::Config for Test { type OnChargeTransaction = (); type OnCreate = (); type FindAuthor = (); + type GasLimitPovSizeRatio = GasLimitPovSizeRatio; type Timestamp = Timestamp; type WeightInfo = (); } diff --git a/crates/pallet-erc20-support/src/mock.rs b/crates/pallet-erc20-support/src/mock.rs index 499eb8602..589daf473 100644 --- a/crates/pallet-erc20-support/src/mock.rs +++ b/crates/pallet-erc20-support/src/mock.rs @@ -22,7 +22,8 @@ type Block = frame_system::mocking::MockBlock; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-ethereum-chain-id/src/mock.rs b/crates/pallet-ethereum-chain-id/src/mock.rs index c33db0674..51d73d07e 100644 --- a/crates/pallet-ethereum-chain-id/src/mock.rs +++ b/crates/pallet-ethereum-chain-id/src/mock.rs @@ -17,7 +17,7 @@ pub type BlockNumber = u64; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-evm-accounts-mapping/src/mock.rs b/crates/pallet-evm-accounts-mapping/src/mock.rs index 2f4f49a5d..b0fae13fd 100644 --- a/crates/pallet-evm-accounts-mapping/src/mock.rs +++ b/crates/pallet-evm-accounts-mapping/src/mock.rs @@ -62,7 +62,7 @@ impl TestExternalitiesExt for frame_support::sp_io::TestExternalities { } frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-token-claims/src/mock.rs b/crates/pallet-token-claims/src/mock.rs index 0672e6940..7e817280d 100644 --- a/crates/pallet-token-claims/src/mock.rs +++ b/crates/pallet-token-claims/src/mock.rs @@ -25,7 +25,7 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/pallet-token-claims/src/tests.rs b/crates/pallet-token-claims/src/tests.rs index 4bfa2e75d..0a6577a74 100644 --- a/crates/pallet-token-claims/src/tests.rs +++ b/crates/pallet-token-claims/src/tests.rs @@ -1156,7 +1156,7 @@ fn signed_ext_validate_works() { // Invoke the function under test. let normal = DispatchInfo { - weight: Weight::from_ref_time(100), + weight: Weight::from_parts(100, 0), class: DispatchClass::Normal, pays_fee: Pays::No, }; @@ -1208,7 +1208,7 @@ fn signed_ext_validate_fails_invalid_eth_signature() { // Invoke the function under test. let normal = DispatchInfo { - weight: Weight::from_ref_time(100), + weight: Weight::from_parts(100, 0), class: DispatchClass::Normal, pays_fee: Pays::No, }; @@ -1260,7 +1260,7 @@ fn signed_ext_validate_fails_when_claim_is_absent() { // Invoke the function under test. let normal = DispatchInfo { - weight: Weight::from_ref_time(100), + weight: Weight::from_parts(100, 0), class: DispatchClass::Normal, pays_fee: Pays::No, }; diff --git a/crates/pallet-vesting/src/mock.rs b/crates/pallet-vesting/src/mock.rs index 25fd6c2c0..7d176e7fb 100644 --- a/crates/pallet-vesting/src/mock.rs +++ b/crates/pallet-vesting/src/mock.rs @@ -20,7 +20,7 @@ type UncheckedExtrinsic = frame_system::mocking::MockUncheckedExtrinsic; type Block = frame_system::mocking::MockBlock; frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, diff --git a/crates/precompile-bioauth/src/mock.rs b/crates/precompile-bioauth/src/mock.rs index 62298b74c..d19cb0b5a 100644 --- a/crates/precompile-bioauth/src/mock.rs +++ b/crates/precompile-bioauth/src/mock.rs @@ -29,7 +29,7 @@ pub type BlockNumber = u64; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, @@ -213,6 +213,14 @@ mock! { fn is_static(&self) -> bool; fn gas_limit(&self) -> Option; + + fn record_external_cost( + &mut self, + ref_time: Option, + proof_size: Option, + ) -> Result<(), ExitError>; + + fn refund_external_cost(&mut self, ref_time: Option, proof_size: Option); } } diff --git a/crates/precompile-currency-swap/src/mock.rs b/crates/precompile-currency-swap/src/mock.rs index ce9dba6cc..f556d8f74 100644 --- a/crates/precompile-currency-swap/src/mock.rs +++ b/crates/precompile-currency-swap/src/mock.rs @@ -3,7 +3,7 @@ // Allow simple integer arithmetic in tests. #![allow(clippy::arithmetic_side_effects)] -use fp_evm::PrecompileHandle; +use fp_evm::{IsPrecompileResult, PrecompileHandle}; use frame_support::{ once_cell::sync::Lazy, sp_io, @@ -29,7 +29,8 @@ pub(crate) type Balance = u128; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, @@ -116,13 +117,14 @@ pub struct FixedGasPrice; impl fp_evm::FeeCalculator for FixedGasPrice { fn min_gas_price() -> (U256, Weight) { // Return some meaningful gas price and weight - (*GAS_PRICE, Weight::from_ref_time(7u64)) + (*GAS_PRICE, Weight::from_parts(7u64, 0)) } } frame_support::parameter_types! { pub BlockGasLimit: U256 = U256::max_value(); - pub WeightPerGas: Weight = Weight::from_ref_time(20_000); + pub GasLimitPovSizeRatio: u64 = 0; + pub WeightPerGas: Weight = Weight::from_parts(20_000, 0); pub MockPrecompiles: MockPrecompileSet = MockPrecompileSet; } @@ -149,6 +151,7 @@ impl pallet_evm::Config for Test { type OnChargeTransaction = (); type OnCreate = (); type FindAuthor = (); + type GasLimitPovSizeRatio = GasLimitPovSizeRatio; type Timestamp = Timestamp; type WeightInfo = (); } @@ -178,8 +181,11 @@ impl pallet_evm::PrecompileSet for MockPrecompileSet { /// Check if the given address is a precompile. Should only be called to /// perform the check while not executing the precompile afterward, since /// `execute` already performs a check internally. - fn is_precompile(&self, address: H160) -> bool { - address == *PRECOMPILE_ADDRESS + fn is_precompile(&self, address: H160, _gas: u64) -> IsPrecompileResult { + IsPrecompileResult::Answer { + is_precompile: address == *PRECOMPILE_ADDRESS, + extra_cost: 0, + } } } diff --git a/crates/precompile-currency-swap/src/tests.rs b/crates/precompile-currency-swap/src/tests.rs index 79a79d5c7..dfd7381d5 100644 --- a/crates/precompile-currency-swap/src/tests.rs +++ b/crates/precompile-currency-swap/src/tests.rs @@ -77,6 +77,8 @@ fn swap_works() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -84,7 +86,7 @@ fn swap_works() { execinfo.exit_reason, fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Returned) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, EvmDataWriter::new().write(true).build()); assert_eq!( execinfo.logs, @@ -178,6 +180,8 @@ fn swap_works_almost_full_balance() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -185,7 +189,7 @@ fn swap_works_almost_full_balance() { execinfo.exit_reason, fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Returned) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, EvmDataWriter::new().write(true).build()); assert_eq!( execinfo.logs, @@ -264,6 +268,8 @@ fn swap_fail_no_funds() { Vec::new(), true, true, + None, + None, config, ) .unwrap_err(); @@ -343,6 +349,8 @@ fn swap_fail_below_ed() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -350,7 +358,7 @@ fn swap_fail_below_ed() { execinfo.exit_reason, fp_evm::ExitReason::Error(fp_evm::ExitError::OutOfFund) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, Vec::::new()); assert_eq!(execinfo.logs, Vec::new()); @@ -438,6 +446,8 @@ fn swap_fail_trait_error() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -445,7 +455,7 @@ fn swap_fail_trait_error() { execinfo.exit_reason, fp_evm::ExitReason::Revert(ExitRevert::Reverted) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, "unable to swap the currency".as_bytes()); assert_eq!(execinfo.logs, Vec::new()); @@ -530,6 +540,8 @@ fn swap_works_full_balance() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -537,7 +549,7 @@ fn swap_works_full_balance() { execinfo.exit_reason, fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Returned) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, EvmDataWriter::new().write(true).build()); assert_eq!( execinfo.logs, @@ -617,6 +629,8 @@ fn swap_fail_bad_selector() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -624,7 +638,7 @@ fn swap_fail_bad_selector() { execinfo.exit_reason, fp_evm::ExitReason::Error(fp_evm::ExitError::Other("invalid function selector".into())) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, Vec::::new()); assert_eq!(execinfo.logs, Vec::new()); @@ -697,6 +711,8 @@ fn swap_fail_value_overflow() { Vec::new(), true, true, + None, + None, config, ) .unwrap_err(); @@ -769,6 +785,8 @@ fn swap_fail_no_arguments() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -778,7 +796,7 @@ fn swap_fail_no_arguments() { "exactly one argument is expected".into() )) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, Vec::::new()); assert_eq!(execinfo.logs, Vec::new()); @@ -848,6 +866,8 @@ fn swap_fail_short_argument() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -857,7 +877,7 @@ fn swap_fail_short_argument() { "exactly one argument is expected".into() )) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, Vec::::new()); assert_eq!(execinfo.logs, Vec::new()); @@ -929,6 +949,8 @@ fn swap_fail_trailing_junk() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -936,7 +958,7 @@ fn swap_fail_trailing_junk() { execinfo.exit_reason, fp_evm::ExitReason::Error(fp_evm::ExitError::Other("junk at the end of input".into())) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, Vec::::new()); assert_eq!(execinfo.logs, Vec::new()); diff --git a/crates/precompile-evm-accounts-mapping/src/mock.rs b/crates/precompile-evm-accounts-mapping/src/mock.rs index 6053645c2..005ffe979 100644 --- a/crates/precompile-evm-accounts-mapping/src/mock.rs +++ b/crates/precompile-evm-accounts-mapping/src/mock.rs @@ -26,7 +26,8 @@ pub type AccountId = <::Signer as IdentifyAccount>::Account // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, @@ -107,6 +108,14 @@ mock! { fn is_static(&self) -> bool; fn gas_limit(&self) -> Option; + + fn record_external_cost( + &mut self, + ref_time: Option, + proof_size: Option, + ) -> Result<(), ExitError>; + + fn refund_external_cost(&mut self, ref_time: Option, proof_size: Option); } } diff --git a/crates/precompile-native-currency/src/mock.rs b/crates/precompile-native-currency/src/mock.rs index 8db15318e..6d835d6a7 100644 --- a/crates/precompile-native-currency/src/mock.rs +++ b/crates/precompile-native-currency/src/mock.rs @@ -30,7 +30,8 @@ pub(crate) const GAS_COST: u64 = 200; // Configure a mock runtime to test the pallet. frame_support::construct_runtime!( - pub enum Test where + pub struct Test + where Block = Block, NodeBlock = Block, UncheckedExtrinsic = UncheckedExtrinsic, @@ -141,7 +142,7 @@ pub struct FixedGasPrice; impl fp_evm::FeeCalculator for FixedGasPrice { fn min_gas_price() -> (U256, Weight) { // Return some meaningful gas price and weight - (*GAS_PRICE, Weight::from_ref_time(7u64)) + (*GAS_PRICE, Weight::from_parts(7u64, 0)) } } @@ -154,7 +155,8 @@ pub type Precompiles = frame_support::parameter_types! { pub BlockGasLimit: U256 = U256::max_value(); - pub WeightPerGas: Weight = Weight::from_ref_time(20_000); + pub GasLimitPovSizeRatio: u64 = 0; + pub WeightPerGas: Weight = Weight::from_parts(20_000, 0); pub PrecompileAddress: H160 = *PRECOMPILE_ADDRESS; pub PrecompilesValue: Precompiles = Precompiles::new(); } @@ -182,6 +184,7 @@ impl pallet_evm::Config for Test { type OnChargeTransaction = (); type OnCreate = (); type FindAuthor = (); + type GasLimitPovSizeRatio = GasLimitPovSizeRatio; type Timestamp = Timestamp; type WeightInfo = (); } diff --git a/crates/precompile-native-currency/src/tests.rs b/crates/precompile-native-currency/src/tests.rs index 769d5a302..ea166a43a 100644 --- a/crates/precompile-native-currency/src/tests.rs +++ b/crates/precompile-native-currency/src/tests.rs @@ -389,6 +389,8 @@ fn deposit_works() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -396,7 +398,7 @@ fn deposit_works() { execinfo.exit_reason, fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Returned) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, EvmDataWriter::new().write(true).build()); assert_eq!( execinfo.logs, @@ -447,6 +449,8 @@ fn deposit_fails_zero_value() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -454,7 +458,7 @@ fn deposit_fails_zero_value() { execinfo.exit_reason, fp_evm::ExitReason::Revert(ExitRevert::Reverted) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!( execinfo.value, "deposited amount must be non-zero".as_bytes() @@ -501,6 +505,8 @@ fn withdraw_works() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -508,7 +514,7 @@ fn withdraw_works() { execinfo.exit_reason, fp_evm::ExitReason::Succeed(fp_evm::ExitSucceed::Returned) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!(execinfo.value, EvmDataWriter::new().write(true).build()); assert_eq!( execinfo.logs, @@ -559,6 +565,8 @@ fn withdraw_fails_more_than_allowed() { Vec::new(), true, true, + None, + None, config, ) .unwrap(); @@ -566,7 +574,7 @@ fn withdraw_fails_more_than_allowed() { execinfo.exit_reason, fp_evm::ExitReason::Revert(ExitRevert::Reverted) ); - assert_eq!(execinfo.used_gas, expected_gas_usage.into()); + assert_eq!(execinfo.used_gas.standard, expected_gas_usage.into()); assert_eq!( execinfo.value, "trying to withdraw more than owned".as_bytes() diff --git a/crates/precompile-utils/src/lib.rs b/crates/precompile-utils/src/lib.rs index 6b1c8c5f8..a6dde71c0 100644 --- a/crates/precompile-utils/src/lib.rs +++ b/crates/precompile-utils/src/lib.rs @@ -227,15 +227,17 @@ where { /// Cost of a Substrate DB write in gas. pub fn db_write_gas_cost() -> u64 { - ::GasWeightMapping::weight_to_gas(Weight::from_ref_time( + ::GasWeightMapping::weight_to_gas(Weight::from_parts( ::DbWeight::get().write, + 0, )) } /// Cost of a Substrate DB read in gas. pub fn db_read_gas_cost() -> u64 { - ::GasWeightMapping::weight_to_gas(Weight::from_ref_time( + ::GasWeightMapping::weight_to_gas(Weight::from_parts( ::DbWeight::get().read, + 0, )) } } diff --git a/crates/precompile-utils/src/precompile_set.rs b/crates/precompile-utils/src/precompile_set.rs index 0d9cc9fbc..0952f3255 100644 --- a/crates/precompile-utils/src/precompile_set.rs +++ b/crates/precompile-utils/src/precompile_set.rs @@ -2,7 +2,7 @@ //! final precompile set with security checks. All security checks are enabled by //! default and must be disabled explicely throught type annotations. -use fp_evm::{Precompile, PrecompileHandle, PrecompileResult, PrecompileSet}; +use fp_evm::{IsPrecompileResult, Precompile, PrecompileHandle, PrecompileResult, PrecompileSet}; use frame_support::pallet_prelude::Get; use impl_trait_for_tuples::impl_for_tuples; use pallet_evm::AddressMapping; @@ -99,7 +99,7 @@ pub trait PrecompileSetFragment { fn execute(&self, handle: &mut impl PrecompileHandle) -> Option; /// Is the provided address a precompile in this fragment? - fn is_precompile(&self, address: H160) -> bool; + fn is_precompile(&self, address: H160, gas: u64) -> IsPrecompileResult; /// Return the list of addresses covered by this fragment. fn used_addresses(&self) -> Vec; @@ -186,8 +186,11 @@ where } #[inline(always)] - fn is_precompile(&self, address: H160) -> bool { - address == A::get() + fn is_precompile(&self, address: H160, _gas: u64) -> IsPrecompileResult { + IsPrecompileResult::Answer { + is_precompile: address == A::get(), + extra_cost: 0, + } } #[inline(always)] @@ -279,8 +282,11 @@ where } #[inline(always)] - fn is_precompile(&self, address: H160) -> bool { - address == A::get() + fn is_precompile(&self, address: H160, _gas: u64) -> IsPrecompileResult { + IsPrecompileResult::Answer { + is_precompile: address == A::get(), + extra_cost: 0, + } } #[inline(always)] @@ -320,8 +326,13 @@ where fn execute(&self, handle: &mut impl PrecompileHandle) -> Option { let code_address = handle.code_address(); - if !self.is_precompile(code_address) { - return None; + match self.is_precompile(code_address, handle.remaining_gas()) { + IsPrecompileResult::Answer { is_precompile, .. } => { + if !is_precompile { + return None; + } + } + IsPrecompileResult::OutOfGas => return None, } // Check DELEGATECALL config. @@ -378,8 +389,14 @@ where } #[inline(always)] - fn is_precompile(&self, address: H160) -> bool { - address.as_bytes().starts_with(A::get()) && self.precompile_set.is_precompile(address) + fn is_precompile(&self, address: H160, gas: u64) -> IsPrecompileResult { + if address.as_bytes().starts_with(A::get()) { + return self.precompile_set.is_precompile(address, gas); + } + IsPrecompileResult::Answer { + is_precompile: false, + extra_cost: 0, + } } #[inline(always)] @@ -412,8 +429,11 @@ where } #[inline(always)] - fn is_precompile(&self, address: H160) -> bool { - address == A::get() + fn is_precompile(&self, address: H160, _gas: u64) -> IsPrecompileResult { + IsPrecompileResult::Answer { + is_precompile: address == A::get(), + extra_cost: 0, + } } #[inline(always)] @@ -444,14 +464,23 @@ impl PrecompileSetFragment for Tuple { } #[inline(always)] - fn is_precompile(&self, address: H160) -> bool { + fn is_precompile(&self, address: H160, gas: u64) -> IsPrecompileResult { for_tuples!(#( - if self.Tuple.is_precompile(address) { - return true; - } + if let IsPrecompileResult::Answer { + is_precompile: true, + .. + } = self.Tuple.is_precompile(address, gas) { + return IsPrecompileResult::Answer { + is_precompile: true, + extra_cost: 0, + } + } )*); - false + IsPrecompileResult::Answer { + is_precompile: false, + extra_cost: 0, + } } #[inline(always)] @@ -497,11 +526,14 @@ where } } - fn is_precompile(&self, address: H160) -> bool { + fn is_precompile(&self, address: H160, gas: u64) -> IsPrecompileResult { if self.range.contains(&address) { - self.inner.is_precompile(address) + self.inner.is_precompile(address, gas) } else { - false + IsPrecompileResult::Answer { + is_precompile: false, + extra_cost: 0, + } } } @@ -521,8 +553,8 @@ impl PrecompileSet for PrecompileSetBuilder { self.inner.execute(handle) } - fn is_precompile(&self, address: H160) -> bool { - self.inner.is_precompile(address) + fn is_precompile(&self, address: H160, gas: u64) -> IsPrecompileResult { + self.inner.is_precompile(address, gas) } } diff --git a/crates/precompile-utils/src/testing.rs b/crates/precompile-utils/src/testing.rs index e091b5c4f..705411304 100644 --- a/crates/precompile-utils/src/testing.rs +++ b/crates/precompile-utils/src/testing.rs @@ -172,6 +172,16 @@ impl PrecompileHandle for MockHandle { fn gas_limit(&self) -> Option { Some(self.gas_limit) } + + fn record_external_cost( + &mut self, + _ref_time: Option, + _proof_size: Option, + ) -> Result<(), ExitError> { + Ok(()) + } + + fn refund_external_cost(&mut self, _ref_time: Option, _proof_size: Option) {} } pub struct PrecompilesTester<'p, P> { diff --git a/utils/checks/snapshots/features.yaml b/utils/checks/snapshots/features.yaml index 8e396deb1..e4e1c4dfa 100644 --- a/utils/checks/snapshots/features.yaml +++ b/utils/checks/snapshots/features.yaml @@ -56,6 +56,9 @@ features: - default - std +- name: allocator-api2 0.2.16 + features: + - alloc - name: android_system_properties 0.1.5 features: [] - name: ansi_term 0.12.1 @@ -131,6 +134,10 @@ - name: asynchronous-codec 0.6.1 features: - default +- name: atoi 2.0.0 + features: + - default + - std - name: atomic-waker 1.1.1 features: [] - name: atty 0.2.14 @@ -204,6 +211,9 @@ - name: bitflags 1.3.2 features: - default +- name: bitflags 2.4.1 + features: + - serde - name: bitvec 1.0.1 features: - alloc @@ -213,7 +223,8 @@ - default - std - name: blake2b_simd 1.0.1 - features: [] + features: + - std - name: blake2s_simd 1.0.1 features: [] - name: blake3 1.3.3 @@ -472,6 +483,11 @@ features: - alloc - std +- name: crossbeam-queue 0.3.8 + features: + - alloc + - default + - std - name: crossbeam-utils 0.8.15 features: - default @@ -587,6 +603,7 @@ features: - alloc - oid + - pem - std - zeroize - name: der-parser 7.0.0 @@ -647,6 +664,8 @@ features: - default - std +- name: dotenvy 0.15.7 + features: [] - name: downcast 0.11.0 features: - default @@ -735,6 +754,7 @@ - name: either 1.8.1 features: - default + - serde - use_std - name: elliptic-curve 0.12.3 features: @@ -788,6 +808,8 @@ features: [] - name: errno-dragonfly 0.1.2 features: [] +- name: etcetera 0.8.0 + features: [] - name: ethabi 18.0.0 features: - full-serde @@ -835,7 +857,7 @@ - eip712 - name: event-listener 2.5.3 features: [] -- name: evm 0.37.0 +- name: evm 0.39.1 features: - environmental - scale-codec @@ -844,7 +866,7 @@ - std - with-codec - with-serde -- name: evm-core 0.37.0 +- name: evm-core 0.39.0 features: - scale-codec - scale-info @@ -852,16 +874,21 @@ - std - with-codec - with-serde -- name: evm-gasometer 0.37.0 +- name: evm-gasometer 0.39.0 features: - environmental - std -- name: evm-runtime 0.37.0 +- name: evm-runtime 0.39.0 features: - environmental - std - name: exit-future 0.2.0 features: [] +- name: expander 1.0.0 + features: + - default + - syn + - syndicate - name: facetec-api-client 0.1.0 features: [] - name: fake-simd 0.1.2 @@ -878,10 +905,26 @@ - name: fc-db 2.0.0-dev features: - default + - ethereum + - fc-storage + - fp-consensus + - fp-rpc + - futures - kvdb-rocksdb - parity-db + - rocksdb + - sc-client-api + - smallvec + - sp-api + - sp-storage + - sql + - sqlx + - tokio - name: fc-mapping-sync 2.0.0-dev - features: [] + features: + - sp-core + - sql + - tokio - name: fc-rpc 2.0.0-dev features: - rpc-binary-search-estimate @@ -914,6 +957,11 @@ - parking_lot - scale-info - std +- name: finl_unicode 1.2.0 + features: + - categories + - default + - grapheme_clusters - name: fixed-hash 0.8.0 features: - byteorder @@ -932,6 +980,11 @@ - default - num-traits - ratio +- name: flume 0.11.0 + features: + - async + - futures-core + - futures-sink - name: fnv 1.0.7 features: - default @@ -1024,8 +1077,14 @@ - name: frame-try-runtime 0.10.0-dev features: - std +- name: fs-err 2.11.0 + features: [] - name: fs2 0.4.3 features: [] +- name: fs4 0.6.5 + features: + - default + - sync - name: funty 2.0.0 features: [] - name: futures 0.3.28 @@ -1055,9 +1114,16 @@ - unstable - name: futures-executor 0.3.28 features: + - default - num_cpus - std - thread-pool +- name: futures-intrusive 0.5.0 + features: + - alloc + - default + - parking_lot + - std - name: futures-io 0.3.28 features: - default @@ -1160,6 +1226,9 @@ features: - default - name: hash-db 0.15.2 + features: + - std +- name: hash-db 0.16.0 features: - default - std @@ -1177,9 +1246,15 @@ - ahash - inline-more - raw -- name: hashbrown 0.14.3 +- name: hashbrown 0.14.2 features: + - ahash + - allocator-api2 + - default + - inline-more - raw +- name: hashlink 0.8.4 + features: [] - name: headers 0.3.8 features: [] - name: headers-core 0.2.0 @@ -1187,6 +1262,8 @@ - name: heck 0.4.1 features: - default + - unicode + - unicode-segmentation - name: hermit-abi 0.1.19 features: - default @@ -1201,6 +1278,8 @@ - alloc - default - std +- name: hex-literal 0.3.4 + features: [] - name: hex-literal 0.4.1 features: [] - name: hkdf 0.12.3 @@ -1215,6 +1294,8 @@ features: [] - name: hmac-drbg 0.3.0 features: [] +- name: home 0.5.5 + features: [] - name: hostname 0.3.1 features: - default @@ -1237,6 +1318,7 @@ - name: humanode-peer 0.1.0 features: - default + - rocksdb - name: humanode-rpc 0.1.0 features: [] - name: humanode-runtime 0.1.0 @@ -1346,6 +1428,11 @@ - default - use_alloc - use_std +- name: itertools 0.12.0 + features: + - default + - use_alloc + - use_std - name: itoa 1.0.6 features: [] - name: jobserver 0.1.26 @@ -1417,7 +1504,9 @@ - name: kvdb-rocksdb 0.17.0 features: [] - name: lazy_static 1.4.0 - features: [] + features: + - spin + - spin_no_std - name: lazycell 1.3.0 features: [] - name: libc 0.2.141 @@ -1535,6 +1624,14 @@ features: [] - name: libsecp256k1-gen-genmult 0.3.0 features: [] +- name: libsqlite3-sys 0.26.0 + features: + - bundled + - bundled_bindings + - cc + - pkg-config + - unlock_notify + - vcpkg - name: libz-sys 1.1.8 features: - static @@ -1606,13 +1703,10 @@ - name: memoffset 0.6.5 features: - default -- name: memoffset 0.7.1 - features: - - default - name: memoffset 0.8.0 features: - default -- name: memory-db 0.31.0 +- name: memory-db 0.32.0 features: - std - name: memory_units 0.4.0 @@ -1767,43 +1861,6 @@ - uio - user - zerocopy -- name: nix 0.26.2 - features: - - acct - - aio - - default - - dir - - env - - event - - feature - - fs - - hostname - - inotify - - ioctl - - kmod - - memoffset - - mman - - mount - - mqueue - - net - - personality - - pin-utils - - poll - - process - - pthread - - ptrace - - quota - - reboot - - resource - - sched - - signal - - socket - - term - - time - - ucontext - - uio - - user - - zerocopy - name: nohash-hasher 0.2.0 features: - default @@ -1827,6 +1884,13 @@ features: - default - std +- name: num-bigint-dig 0.8.4 + features: + - i128 + - prime + - rand + - u64_digit + - zeroize - name: num-complex 0.4.3 features: - std @@ -1852,6 +1916,7 @@ features: - default - i128 + - libm - std - name: num_cpus 1.15.0 features: [] @@ -2164,6 +2229,9 @@ - name: pem-rfc7468 0.6.0 features: - alloc +- name: pem-rfc7468 0.7.0 + features: + - alloc - name: percent-encoding 2.2.0 features: - alloc @@ -2194,9 +2262,17 @@ features: [] - name: pin-utils 0.1.0 features: [] +- name: pkcs1 0.7.5 + features: + - alloc + - pem + - pkcs8 + - std + - zeroize - name: pkcs8 0.10.2 features: - alloc + - pem - std - name: pkcs8 0.9.0 features: @@ -2521,6 +2597,12 @@ features: [] - name: rpc-validator-key-logic 0.1.0 features: [] +- name: rsa 0.9.1 + features: + - default + - pem + - std + - u64_digit - name: rtcp 0.7.2 features: [] - name: rtnetlink 0.10.1 @@ -2610,7 +2692,6 @@ features: [] - name: sc-cli 0.10.0-dev features: - - default - rocksdb - name: sc-client-api 4.0.0-dev features: [] @@ -2627,6 +2708,10 @@ features: [] - name: sc-consensus-epochs 0.10.0-dev features: [] +- name: sc-consensus-grandpa 0.10.0-dev + features: [] +- name: sc-consensus-grandpa-rpc 0.10.0-dev + features: [] - name: sc-consensus-slots 0.10.0-dev features: [] - name: sc-executor 0.10.0-dev @@ -2640,10 +2725,6 @@ features: [] - name: sc-executor-wasmtime 0.10.0-dev features: [] -- name: sc-finality-grandpa 0.10.0-dev - features: [] -- name: sc-finality-grandpa-rpc 0.10.0-dev - features: [] - name: sc-informant 0.10.0-dev features: [] - name: sc-keystore 4.0.0-dev @@ -2679,9 +2760,7 @@ - name: sc-rpc-spec-v2 0.10.0-dev features: [] - name: sc-service 0.10.0-dev - features: - - default - - rocksdb + features: [] - name: sc-state-db 0.10.0-dev features: [] - name: sc-storage-monitor 0.1.0 @@ -2807,6 +2886,7 @@ - alloc - default - derive + - rc - serde_derive - std - name: serde_derive 1.0.160 @@ -2978,6 +3058,12 @@ - sp-keystore - sp-timestamp - std +- name: sp-consensus-grandpa 4.0.0-dev + features: + - default + - serde + - sp-keystore + - std - name: sp-consensus-slots 0.10.0-dev features: - default @@ -3027,12 +3113,6 @@ features: - default - std -- name: sp-finality-grandpa 4.0.0-dev - features: - - default - - serde - - sp-keystore - - std - name: sp-inherents 4.0.0-dev features: - async-trait @@ -3177,7 +3257,14 @@ features: [] - name: spin 0.9.8 features: + - barrier + - default + - lazy + - lock_api + - lock_api_crate - mutex + - once + - rwlock - spin_mutex - name: spki 0.6.0 features: @@ -3187,7 +3274,77 @@ - name: spki 0.7.1 features: - alloc + - pem - std +- name: sqlformat 0.2.3 + features: [] +- name: sqlx 0.7.2 + features: + - _rt-tokio + - any + - default + - json + - macros + - migrate + - runtime-tokio + - runtime-tokio-native-tls + - sqlite + - sqlx-macros + - sqlx-sqlite + - tls-native-tls +- name: sqlx-core 0.7.2 + features: + - _rt-tokio + - _tls-native-tls + - any + - crc + - default + - json + - migrate + - native-tls + - offline + - serde + - serde_json + - sha2 + - tokio + - tokio-stream +- name: sqlx-macros 0.7.2 + features: + - _rt-tokio + - _tls-native-tls + - default + - json + - migrate + - sqlite +- name: sqlx-macros-core 0.7.2 + features: + - _rt-tokio + - _tls-native-tls + - default + - json + - migrate + - sqlite + - sqlx-sqlite + - tokio +- name: sqlx-mysql 0.7.2 + features: + - any + - json + - migrate + - offline + - serde +- name: sqlx-postgres 0.7.2 + features: + - any + - json + - migrate +- name: sqlx-sqlite 0.7.2 + features: + - any + - json + - migrate + - offline + - serde - name: ss58-registry 1.39.0 features: - num-format @@ -3203,6 +3360,8 @@ - default - name: static_init_macro 1.0.2 features: [] +- name: stringprep 0.1.4 + features: [] - name: strsim 0.10.0 features: [] - name: strum 0.24.1 @@ -3369,6 +3528,7 @@ - name: tokio-stream 0.1.12 features: - default + - fs - sync - time - tokio-util @@ -3475,11 +3635,11 @@ features: [] - name: tracing-test-macro 0.2.4 features: [] -- name: trie-db 0.25.1 +- name: trie-db 0.27.1 features: - rustc-hex - std -- name: trie-root 0.17.0 +- name: trie-root 0.18.0 features: - std - name: triehash 0.8.4 @@ -3547,6 +3707,8 @@ - name: unicode-xid 0.2.4 features: - default +- name: unicode_categories 0.1.1 + features: [] - name: universal-hash 0.4.1 features: [] - name: universal-hash 0.5.0 @@ -3774,6 +3936,8 @@ - vnet - name: which 4.4.0 features: [] +- name: whoami 1.4.1 + features: [] - name: wide 0.7.13 features: - std @@ -3901,6 +4065,8 @@ - Win32_System_LibraryLoader - Win32_System_Threading - Win32_System_WindowsProgramming + - Win32_UI + - Win32_UI_Shell - default - name: windows-targets 0.42.2 features: [] diff --git a/utils/e2e-tests/bash/fixtures/help.stdout.txt b/utils/e2e-tests/bash/fixtures/help.stdout.txt index 6cbb6bab5..ef2021f51 100644 --- a/utils/e2e-tests/bash/fixtures/help.stdout.txt +++ b/utils/e2e-tests/bash/fixtures/help.stdout.txt @@ -431,12 +431,12 @@ Options: --out-peers Specify the number of outgoing connections we're trying to maintain - [default: 15] + [default: 8] --in-peers Maximum number of inbound full nodes peers - [default: 25] + [default: 32] --in-peers-light Maximum number of inbound light nodes peers diff --git a/utils/weights/assets/template.hbs b/utils/weights/assets/template.hbs index 7f99b341f..1f9e56817 100644 --- a/utils/weights/assets/template.hbs +++ b/utils/weights/assets/template.hbs @@ -23,12 +23,14 @@ impl {{pallet}}::WeightInfo for WeightInfo { {{~#each benchmark.components as |c| ~}} {{~#if (not c.is_used)}}_{{/if}}{{c.name}}: u32, {{/each~}} ) -> Weight { - // Minimum execution time: {{underscore benchmark.min_execution_time}} nanoseconds. - Weight::from_ref_time({{underscore benchmark.base_weight}}) - .saturating_add(Weight::from_proof_size({{benchmark.base_calculated_proof_size}})) + // Proof Size summary in bytes: + // Measured: `{{benchmark.base_recorded_proof_size}}{{#each benchmark.component_recorded_proof_size as |cp|}} + {{cp.name}} * ({{cp.slope}} ±{{underscore cp.error}}){{/each}}` + // Estimated: `{{benchmark.base_calculated_proof_size}}{{#each benchmark.component_calculated_proof_size as |cp|}} + {{cp.name}} * ({{cp.slope}} ±{{underscore cp.error}}){{/each}}` + // Minimum execution time: {{underscore benchmark.min_execution_time}}_000 picoseconds. + Weight::from_parts({{underscore benchmark.base_weight}}, {{benchmark.base_calculated_proof_size}}) {{#each benchmark.component_weight as |cw|}} // Standard Error: {{underscore cw.error}} - .saturating_add(Weight::from_ref_time({{underscore cw.slope}}).saturating_mul({{cw.name}}.into())) + .saturating_add(Weight::from_parts({{underscore cw.slope}}, 0).saturating_mul({{cw.name}}.into())) {{/each}} {{#if (ne benchmark.base_reads "0")}} .saturating_add(T::DbWeight::get().reads({{benchmark.base_reads}})) @@ -40,7 +42,7 @@ impl {{pallet}}::WeightInfo for WeightInfo { .saturating_add(T::DbWeight::get().writes({{benchmark.base_writes}})) {{/if}} {{#each benchmark.component_writes as |cw|}} - .saturating_add(T::DbWeight::get().writes(({{cw.slope}}_u64).saturating_mul({{cw.name}}.into()))) + .saturating_add(Weight::from_parts(0, {{cp.slope}}).saturating_mul({{cp.name}}.into())) {{/each}} } {{/each}}