diff --git a/Cargo.lock b/Cargo.lock index d4273e3af..9f01fa564 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -933,6 +933,7 @@ dependencies = [ "darwinia-treasury", "darwinia-vesting", "dp-storage", + "dvm-dynamic-fee", "dvm-ethereum", "dvm-rpc-runtime-api", "ethereum-primitives", @@ -1277,8 +1278,8 @@ dependencies = [ [[package]] name = "darwinia-balances" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-balances-rpc-runtime-api", "darwinia-support", @@ -1292,8 +1293,8 @@ dependencies = [ [[package]] name = "darwinia-balances-rpc" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-balances-rpc-runtime-api", "jsonrpc-core", @@ -1307,8 +1308,8 @@ dependencies = [ [[package]] name = "darwinia-balances-rpc-runtime-api" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "parity-scale-codec", @@ -1319,8 +1320,8 @@ dependencies = [ [[package]] name = "darwinia-claims" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "darwinia-support", @@ -1339,7 +1340,7 @@ dependencies = [ name = "darwinia-cli" version = "0.11.0" dependencies = [ - "darwinia-cli 2.3.0", + "darwinia-cli 2.4.0", "darwinia-service", "log", "sc-cli", @@ -1359,8 +1360,8 @@ dependencies = [ [[package]] name = "darwinia-cli" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "sc-cli", "sc-client-api", @@ -1372,8 +1373,8 @@ dependencies = [ [[package]] name = "darwinia-crab-backing" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "frame-support", "frame-system", @@ -1383,8 +1384,8 @@ dependencies = [ [[package]] name = "darwinia-crab-issuing" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "frame-support", "frame-system", @@ -1395,8 +1396,8 @@ dependencies = [ [[package]] name = "darwinia-democracy" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "frame-support", @@ -1410,8 +1411,8 @@ dependencies = [ [[package]] name = "darwinia-elections-phragmen" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "frame-support", @@ -1427,8 +1428,8 @@ dependencies = [ [[package]] name = "darwinia-ethereum-backing" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "darwinia-relay-primitives", @@ -1448,8 +1449,8 @@ dependencies = [ [[package]] name = "darwinia-ethereum-relay" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "blake2-rfc", @@ -1472,8 +1473,8 @@ dependencies = [ [[package]] name = "darwinia-evm" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-balances", "dp-evm", @@ -1497,8 +1498,8 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-empty" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "dp-evm", "evm", @@ -1506,8 +1507,8 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-simple" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "dp-evm", "evm", @@ -1518,8 +1519,8 @@ dependencies = [ [[package]] name = "darwinia-evm-precompile-withdraw" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-evm", "darwinia-support", @@ -1538,8 +1539,8 @@ dependencies = [ [[package]] name = "darwinia-header-mmr" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "ckb-merkle-mountain-range", "darwinia-header-mmr-rpc-runtime-api", @@ -1558,8 +1559,8 @@ dependencies = [ [[package]] name = "darwinia-header-mmr-rpc" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-header-mmr-rpc-runtime-api", "jsonrpc-core", @@ -1573,8 +1574,8 @@ dependencies = [ [[package]] name = "darwinia-header-mmr-rpc-runtime-api" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "parity-scale-codec", @@ -1597,8 +1598,8 @@ dependencies = [ [[package]] name = "darwinia-relay-authorities" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-relay-primitives", "darwinia-support", @@ -1612,8 +1613,8 @@ dependencies = [ [[package]] name = "darwinia-relay-primitives" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "frame-support", "parity-scale-codec", @@ -1623,8 +1624,8 @@ dependencies = [ [[package]] name = "darwinia-relayer-game" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-relay-primitives", "darwinia-support", @@ -1786,6 +1787,7 @@ dependencies = [ "dc-mapping-sync", "dc-rpc", "dp-rpc", + "dvm-dynamic-fee", "dvm-rpc-runtime-api", "frame-system-rpc-runtime-api", "futures 0.3.15", @@ -1801,6 +1803,7 @@ dependencies = [ "sc-consensus", "sc-consensus-babe", "sc-consensus-slots", + "sc-consensus-uncles", "sc-executor", "sc-finality-grandpa", "sc-keystore", @@ -1812,6 +1815,7 @@ dependencies = [ "serde_json", "sp-api", "sp-authority-discovery", + "sp-authorship", "sp-block-builder", "sp-blockchain", "sp-consensus", @@ -1822,6 +1826,7 @@ dependencies = [ "sp-offchain", "sp-runtime", "sp-session", + "sp-timestamp", "sp-transaction-pool", "sp-trie", "substrate-prometheus-endpoint", @@ -1829,8 +1834,8 @@ dependencies = [ [[package]] name = "darwinia-staking" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-staking-rpc-runtime-api", "darwinia-support", @@ -1854,8 +1859,8 @@ dependencies = [ [[package]] name = "darwinia-staking-rpc" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-staking-rpc-runtime-api", "jsonrpc-core", @@ -1869,8 +1874,8 @@ dependencies = [ [[package]] name = "darwinia-staking-rpc-runtime-api" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "parity-scale-codec", @@ -1881,8 +1886,8 @@ dependencies = [ [[package]] name = "darwinia-support" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "ethereum-primitives", "frame-support", @@ -1895,8 +1900,8 @@ dependencies = [ [[package]] name = "darwinia-treasury" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "frame-support", @@ -1909,8 +1914,8 @@ dependencies = [ [[package]] name = "darwinia-tron-backing" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "frame-support", "frame-system", @@ -1920,8 +1925,8 @@ dependencies = [ [[package]] name = "darwinia-vesting" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-support", "frame-support", @@ -1959,8 +1964,8 @@ dependencies = [ [[package]] name = "dc-db" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "kvdb", "kvdb-rocksdb", @@ -1973,8 +1978,8 @@ dependencies = [ [[package]] name = "dc-mapping-sync" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "dc-db", "dp_consensus", @@ -1990,8 +1995,8 @@ dependencies = [ [[package]] name = "dc-rpc" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "dc-db", @@ -2111,8 +2116,8 @@ dependencies = [ [[package]] name = "dp-evm" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "evm", "impl-trait-for-tuples", @@ -2124,8 +2129,8 @@ dependencies = [ [[package]] name = "dp-rpc" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "ethereum-types", "jsonrpc-core", @@ -2139,13 +2144,13 @@ dependencies = [ [[package]] name = "dp-storage" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" [[package]] name = "dp_consensus" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "ethereum", "parity-scale-codec", @@ -2156,10 +2161,26 @@ dependencies = [ "sp-std", ] +[[package]] +name = "dvm-dynamic-fee" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" +dependencies = [ + "async-trait", + "darwinia-evm", + "frame-support", + "frame-system", + "parity-scale-codec", + "sp-core", + "sp-inherents", + "sp-runtime", + "sp-std", +] + [[package]] name = "dvm-ethereum" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "darwinia-evm", @@ -2187,8 +2208,8 @@ dependencies = [ [[package]] name = "dvm-rpc-core" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-evm", "dp-evm", @@ -2207,8 +2228,8 @@ dependencies = [ [[package]] name = "dvm-rpc-runtime-api" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "darwinia-evm", "darwinia-support", @@ -2434,8 +2455,8 @@ dependencies = [ [[package]] name = "ethereum-primitives" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "ethash", @@ -2655,7 +2676,7 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] name = "fork-tree" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", ] @@ -2673,7 +2694,7 @@ dependencies = [ [[package]] name = "frame-benchmarking" version = "3.1.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -2692,7 +2713,7 @@ dependencies = [ [[package]] name = "frame-election-provider-support" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -2705,7 +2726,7 @@ dependencies = [ [[package]] name = "frame-executive" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -2720,7 +2741,7 @@ dependencies = [ [[package]] name = "frame-metadata" version = "13.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "serde", @@ -2731,7 +2752,7 @@ dependencies = [ [[package]] name = "frame-support" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "bitflags", "frame-metadata", @@ -2757,7 +2778,7 @@ dependencies = [ [[package]] name = "frame-support-procedural" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "Inflector", "frame-support-procedural-tools", @@ -2769,7 +2790,7 @@ dependencies = [ [[package]] name = "frame-support-procedural-tools" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support-procedural-tools-derive", "proc-macro-crate 1.0.0", @@ -2781,7 +2802,7 @@ dependencies = [ [[package]] name = "frame-support-procedural-tools-derive" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "proc-macro2", "quote", @@ -2791,7 +2812,7 @@ dependencies = [ [[package]] name = "frame-system" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "impl-trait-for-tuples", @@ -2808,7 +2829,7 @@ dependencies = [ [[package]] name = "frame-system-rpc-runtime-api" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sp-api", @@ -2817,7 +2838,7 @@ dependencies = [ [[package]] name = "frame-try-runtime" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "parity-scale-codec", @@ -4624,8 +4645,8 @@ checksum = "71d96e3f3c0b6325d8ccd83c33b28acb183edcb6c67938ba104ec546854b0882" [[package]] name = "merkle-patricia-trie" -version = "2.3.0" -source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.0#36273a2c8a40c578977c13fb8530089f3de885ac" +version = "2.4.0" +source = "git+https://github.com/darwinia-network/darwinia-common.git?tag=darwinia-v0.11.1#0ab5250bdf9fa2603edabb9a86fef3e7be597c4c" dependencies = [ "array-bytes", "hashbrown 0.9.1", @@ -5021,7 +5042,7 @@ dependencies = [ [[package]] name = "pallet-authority-discovery" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5036,14 +5057,13 @@ dependencies = [ [[package]] name = "pallet-authorship" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", "impl-trait-for-tuples", "parity-scale-codec", "sp-authorship", - "sp-inherents", "sp-runtime", "sp-std", ] @@ -5051,7 +5071,7 @@ dependencies = [ [[package]] name = "pallet-babe" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-benchmarking", "frame-support", @@ -5074,7 +5094,7 @@ dependencies = [ [[package]] name = "pallet-balances" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-benchmarking", "frame-support", @@ -5088,7 +5108,7 @@ dependencies = [ [[package]] name = "pallet-collective" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5103,7 +5123,7 @@ dependencies = [ [[package]] name = "pallet-election-provider-multi-phase" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-election-provider-support", "frame-support", @@ -5121,7 +5141,7 @@ dependencies = [ [[package]] name = "pallet-grandpa" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-benchmarking", "frame-support", @@ -5142,7 +5162,7 @@ dependencies = [ [[package]] name = "pallet-identity" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "enumflags2", "frame-benchmarking", @@ -5157,7 +5177,7 @@ dependencies = [ [[package]] name = "pallet-im-online" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5175,7 +5195,7 @@ dependencies = [ [[package]] name = "pallet-indices" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5190,7 +5210,7 @@ dependencies = [ [[package]] name = "pallet-membership" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-benchmarking", "frame-support", @@ -5205,7 +5225,7 @@ dependencies = [ [[package]] name = "pallet-multisig" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5219,7 +5239,7 @@ dependencies = [ [[package]] name = "pallet-offences" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5235,7 +5255,7 @@ dependencies = [ [[package]] name = "pallet-proxy" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5249,7 +5269,7 @@ dependencies = [ [[package]] name = "pallet-randomness-collective-flip" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5262,7 +5282,7 @@ dependencies = [ [[package]] name = "pallet-recovery" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "enumflags2", "frame-support", @@ -5276,7 +5296,7 @@ dependencies = [ [[package]] name = "pallet-scheduler" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-benchmarking", "frame-support", @@ -5291,7 +5311,7 @@ dependencies = [ [[package]] name = "pallet-session" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5310,7 +5330,7 @@ dependencies = [ [[package]] name = "pallet-society" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5323,7 +5343,7 @@ dependencies = [ [[package]] name = "pallet-sudo" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5336,7 +5356,7 @@ dependencies = [ [[package]] name = "pallet-timestamp" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-benchmarking", "frame-support", @@ -5353,7 +5373,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -5369,7 +5389,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "jsonrpc-core", "jsonrpc-core-client", @@ -5386,7 +5406,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc-runtime-api" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "pallet-transaction-payment", "parity-scale-codec", @@ -5397,7 +5417,7 @@ dependencies = [ [[package]] name = "pallet-utility" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-support", "frame-system", @@ -6285,7 +6305,7 @@ dependencies = [ [[package]] name = "remote-externalities" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "env_logger 0.8.4", "hex-literal", @@ -6521,7 +6541,7 @@ dependencies = [ [[package]] name = "sc-authority-discovery" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "derive_more", @@ -6550,7 +6570,7 @@ dependencies = [ [[package]] name = "sc-basic-authorship" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "futures-timer 3.0.2", @@ -6573,7 +6593,7 @@ dependencies = [ [[package]] name = "sc-block-builder" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sc-client-api", @@ -6589,7 +6609,7 @@ dependencies = [ [[package]] name = "sc-chain-spec" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", @@ -6610,7 +6630,7 @@ dependencies = [ [[package]] name = "sc-chain-spec-derive" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "proc-macro-crate 1.0.0", "proc-macro2", @@ -6621,7 +6641,7 @@ dependencies = [ [[package]] name = "sc-cli" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "chrono", "fdlimit", @@ -6659,7 +6679,7 @@ dependencies = [ [[package]] name = "sc-client-api" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "fnv", @@ -6693,7 +6713,7 @@ dependencies = [ [[package]] name = "sc-client-db" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "blake2-rfc", "hash-db", @@ -6723,7 +6743,7 @@ dependencies = [ [[package]] name = "sc-consensus" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parking_lot 0.11.1", "sc-client-api", @@ -6735,7 +6755,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "derive_more", @@ -6773,7 +6793,6 @@ dependencies = [ "sp-io", "sp-keystore", "sp-runtime", - "sp-timestamp", "sp-utils", "sp-version", "substrate-prometheus-endpoint", @@ -6782,7 +6801,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe-rpc" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "futures 0.3.15", @@ -6806,7 +6825,7 @@ dependencies = [ [[package]] name = "sc-consensus-epochs" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "fork-tree", "parity-scale-codec", @@ -6819,11 +6838,12 @@ dependencies = [ [[package]] name = "sc-consensus-slots" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "futures 0.3.15", "futures-timer 3.0.2", + "impl-trait-for-tuples", "log", "parity-scale-codec", "sc-client-api", @@ -6846,21 +6866,18 @@ dependencies = [ [[package]] name = "sc-consensus-uncles" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ - "log", "sc-client-api", "sp-authorship", - "sp-consensus", - "sp-core", - "sp-inherents", "sp-runtime", + "thiserror", ] [[package]] name = "sc-executor" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "lazy_static", @@ -6890,7 +6907,7 @@ dependencies = [ [[package]] name = "sc-executor-common" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "parity-scale-codec", @@ -6907,7 +6924,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmi" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "log", "parity-scale-codec", @@ -6922,7 +6939,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmtime" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "log", "parity-scale-codec", @@ -6940,7 +6957,7 @@ dependencies = [ [[package]] name = "sc-finality-grandpa" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "derive_more", @@ -6980,7 +6997,7 @@ dependencies = [ [[package]] name = "sc-finality-grandpa-rpc" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "finality-grandpa", @@ -7004,7 +7021,7 @@ dependencies = [ [[package]] name = "sc-informant" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "ansi_term 0.12.1", "futures 0.3.15", @@ -7022,7 +7039,7 @@ dependencies = [ [[package]] name = "sc-keystore" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "derive_more", @@ -7042,7 +7059,7 @@ dependencies = [ [[package]] name = "sc-light" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "hash-db", "lazy_static", @@ -7061,7 +7078,7 @@ dependencies = [ [[package]] name = "sc-network" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-std", "async-trait", @@ -7114,7 +7131,7 @@ dependencies = [ [[package]] name = "sc-network-gossip" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "futures-timer 3.0.2", @@ -7131,7 +7148,7 @@ dependencies = [ [[package]] name = "sc-offchain" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "bytes 0.5.6", "fnv", @@ -7159,7 +7176,7 @@ dependencies = [ [[package]] name = "sc-peerset" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "libp2p", @@ -7172,7 +7189,7 @@ dependencies = [ [[package]] name = "sc-proposer-metrics" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "log", "substrate-prometheus-endpoint", @@ -7181,7 +7198,7 @@ dependencies = [ [[package]] name = "sc-rpc" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "hash-db", @@ -7207,6 +7224,7 @@ dependencies = [ "sp-runtime", "sp-session", "sp-state-machine", + "sp-tracing", "sp-transaction-pool", "sp-utils", "sp-version", @@ -7215,7 +7233,7 @@ dependencies = [ [[package]] name = "sc-rpc-api" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "futures 0.3.15", @@ -7232,6 +7250,7 @@ dependencies = [ "sp-core", "sp-rpc", "sp-runtime", + "sp-tracing", "sp-transaction-pool", "sp-version", ] @@ -7239,7 +7258,7 @@ dependencies = [ [[package]] name = "sc-rpc-server" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.1.31", "jsonrpc-core", @@ -7257,7 +7276,7 @@ dependencies = [ [[package]] name = "sc-service" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "directories", @@ -7321,7 +7340,7 @@ dependencies = [ [[package]] name = "sc-state-db" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "log", "parity-scale-codec", @@ -7336,7 +7355,7 @@ dependencies = [ [[package]] name = "sc-sync-state-rpc" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "jsonrpc-core", "jsonrpc-core-client", @@ -7356,7 +7375,7 @@ dependencies = [ [[package]] name = "sc-telemetry" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "chrono", "futures 0.3.15", @@ -7376,7 +7395,7 @@ dependencies = [ [[package]] name = "sc-tracing" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "ansi_term 0.12.1", "atty", @@ -7387,23 +7406,33 @@ dependencies = [ "parking_lot 0.11.1", "regex", "rustc-hash", + "sc-client-api", + "sc-rpc-server", + "sc-telemetry", "sc-tracing-proc-macro", "serde", "serde_json", + "sp-api", + "sp-block-builder", + "sp-blockchain", + "sp-core", + "sp-rpc", + "sp-runtime", + "sp-storage", "sp-tracing", "thiserror", "tracing", - "tracing-core", "tracing-log", "tracing-subscriber", "wasm-bindgen", + "wasm-timer", "web-sys", ] [[package]] name = "sc-tracing-proc-macro" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "proc-macro-crate 1.0.0", "proc-macro2", @@ -7414,7 +7443,7 @@ dependencies = [ [[package]] name = "sc-transaction-graph" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "futures 0.3.15", @@ -7436,7 +7465,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "futures-diagnose", @@ -7769,6 +7798,15 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f173ac3d1a7e3b28003f40de0b5ce7fe2710f9b9dc3fc38664cebee46b3b6527" +[[package]] +name = "slog" +version = "2.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8347046d4ebd943127157b94d63abb990fcf729dc4e9978927fdf4ac3c998d06" +dependencies = [ + "erased-serde", +] + [[package]] name = "smallvec" version = "0.6.14" @@ -7842,7 +7880,7 @@ dependencies = [ [[package]] name = "sp-allocator" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "log", "sp-core", @@ -7854,7 +7892,7 @@ dependencies = [ [[package]] name = "sp-api" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "hash-db", "log", @@ -7871,7 +7909,7 @@ dependencies = [ [[package]] name = "sp-api-proc-macro" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "blake2-rfc", "proc-macro-crate 1.0.0", @@ -7883,7 +7921,7 @@ dependencies = [ [[package]] name = "sp-application-crypto" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "serde", @@ -7895,7 +7933,7 @@ dependencies = [ [[package]] name = "sp-arithmetic" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "integer-sqrt", "num-traits", @@ -7909,7 +7947,7 @@ dependencies = [ [[package]] name = "sp-authority-discovery" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sp-api", @@ -7921,8 +7959,9 @@ dependencies = [ [[package]] name = "sp-authorship" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ + "async-trait", "parity-scale-codec", "sp-inherents", "sp-runtime", @@ -7932,7 +7971,7 @@ dependencies = [ [[package]] name = "sp-block-builder" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sp-api", @@ -7944,7 +7983,7 @@ dependencies = [ [[package]] name = "sp-blockchain" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "log", @@ -7962,7 +8001,7 @@ dependencies = [ [[package]] name = "sp-chain-spec" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "serde", "serde_json", @@ -7971,7 +8010,7 @@ dependencies = [ [[package]] name = "sp-consensus" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "futures 0.3.15", @@ -7998,8 +8037,9 @@ dependencies = [ [[package]] name = "sp-consensus-babe" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ + "async-trait", "merlin", "parity-scale-codec", "serde", @@ -8019,7 +8059,7 @@ dependencies = [ [[package]] name = "sp-consensus-slots" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sp-arithmetic", @@ -8029,7 +8069,7 @@ dependencies = [ [[package]] name = "sp-consensus-vrf" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "schnorrkel", @@ -8041,7 +8081,7 @@ dependencies = [ [[package]] name = "sp-core" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "base58", "blake2-rfc", @@ -8085,7 +8125,7 @@ dependencies = [ [[package]] name = "sp-database" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "kvdb", "parking_lot 0.11.1", @@ -8094,7 +8134,7 @@ dependencies = [ [[package]] name = "sp-debug-derive" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "proc-macro2", "quote", @@ -8104,7 +8144,7 @@ dependencies = [ [[package]] name = "sp-externalities" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "environmental", "parity-scale-codec", @@ -8115,7 +8155,7 @@ dependencies = [ [[package]] name = "sp-finality-grandpa" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "finality-grandpa", "log", @@ -8132,11 +8172,13 @@ dependencies = [ [[package]] name = "sp-inherents" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ + "async-trait", + "impl-trait-for-tuples", "parity-scale-codec", - "parking_lot 0.11.1", "sp-core", + "sp-runtime", "sp-std", "thiserror", ] @@ -8144,7 +8186,7 @@ dependencies = [ [[package]] name = "sp-io" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "hash-db", @@ -8168,7 +8210,7 @@ dependencies = [ [[package]] name = "sp-keyring" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "lazy_static", "sp-core", @@ -8179,7 +8221,7 @@ dependencies = [ [[package]] name = "sp-keystore" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-trait", "derive_more", @@ -8196,7 +8238,7 @@ dependencies = [ [[package]] name = "sp-maybe-compressed-blob" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "ruzstd", "zstd", @@ -8205,7 +8247,7 @@ dependencies = [ [[package]] name = "sp-npos-elections" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "serde", @@ -8218,7 +8260,7 @@ dependencies = [ [[package]] name = "sp-npos-elections-compact" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "proc-macro-crate 1.0.0", "proc-macro2", @@ -8229,7 +8271,7 @@ dependencies = [ [[package]] name = "sp-offchain" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "sp-api", "sp-core", @@ -8239,7 +8281,7 @@ dependencies = [ [[package]] name = "sp-panic-handler" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "backtrace", ] @@ -8247,16 +8289,18 @@ dependencies = [ [[package]] name = "sp-rpc" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ + "rustc-hash", "serde", "sp-core", + "tracing-core", ] [[package]] name = "sp-runtime" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "either", "hash256-std-hasher", @@ -8277,7 +8321,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", @@ -8294,7 +8338,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface-proc-macro" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "Inflector", "proc-macro-crate 1.0.0", @@ -8306,7 +8350,7 @@ dependencies = [ [[package]] name = "sp-serializer" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "serde", "serde_json", @@ -8315,7 +8359,7 @@ dependencies = [ [[package]] name = "sp-session" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sp-api", @@ -8328,7 +8372,7 @@ dependencies = [ [[package]] name = "sp-staking" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "parity-scale-codec", "sp-runtime", @@ -8338,7 +8382,7 @@ dependencies = [ [[package]] name = "sp-state-machine" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "hash-db", "log", @@ -8353,6 +8397,7 @@ dependencies = [ "sp-std", "sp-trie", "thiserror", + "tracing", "trie-db", "trie-root", ] @@ -8360,12 +8405,12 @@ dependencies = [ [[package]] name = "sp-std" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" [[package]] name = "sp-storage" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "impl-serde", "parity-scale-codec", @@ -8378,7 +8423,7 @@ dependencies = [ [[package]] name = "sp-tasks" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "log", "sp-core", @@ -8391,23 +8436,32 @@ dependencies = [ [[package]] name = "sp-timestamp" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ + "async-trait", + "futures-timer 3.0.2", + "log", "parity-scale-codec", "sp-api", "sp-inherents", "sp-runtime", "sp-std", + "thiserror", "wasm-timer", ] [[package]] name = "sp-tracing" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ + "erased-serde", "log", "parity-scale-codec", + "parking_lot 0.10.2", + "serde", + "serde_json", + "slog", "sp-std", "tracing", "tracing-core", @@ -8417,7 +8471,7 @@ dependencies = [ [[package]] name = "sp-transaction-pool" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "derive_more", "futures 0.3.15", @@ -8433,7 +8487,7 @@ dependencies = [ [[package]] name = "sp-trie" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "hash-db", "memory-db", @@ -8447,7 +8501,7 @@ dependencies = [ [[package]] name = "sp-utils" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "futures 0.3.15", "futures-core", @@ -8459,7 +8513,7 @@ dependencies = [ [[package]] name = "sp-version" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "impl-serde", "parity-scale-codec", @@ -8471,7 +8525,7 @@ dependencies = [ [[package]] name = "sp-wasm-interface" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", @@ -8596,7 +8650,7 @@ dependencies = [ [[package]] name = "substrate-build-script-utils" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "platforms", ] @@ -8613,7 +8667,7 @@ dependencies = [ [[package]] name = "substrate-frame-rpc-system" version = "3.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-system-rpc-runtime-api", "futures 0.3.15", @@ -8636,7 +8690,7 @@ dependencies = [ [[package]] name = "substrate-prometheus-endpoint" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "async-std", "derive_more", @@ -8650,7 +8704,7 @@ dependencies = [ [[package]] name = "substrate-wasm-builder" version = "4.0.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "ansi_term 0.12.1", "atty", @@ -9299,7 +9353,7 @@ checksum = "59547bce71d9c38b83d9c0e92b6066c4253371f15005def0c30d9657f50c7642" [[package]] name = "try-runtime-cli" version = "0.9.0" -source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.0#dc9acd2d74a5451a63e34060a4c7869021780b3e" +source = "git+https://github.com/darwinia-network/substrate.git?tag=darwinia-v0.11.1#3f110196163b5ec03bac5ee188d60bedf3ebd91d" dependencies = [ "frame-try-runtime", "log", diff --git a/cli/Cargo.toml b/cli/Cargo.toml index 1807977f8..84501b1fa 100644 --- a/cli/Cargo.toml +++ b/cli/Cargo.toml @@ -9,41 +9,41 @@ name = "darwinia-cli" repository = "https://github.com/darwinia-network/darwinia/" version = "0.11.0" -[package.metadata.wasm-pack.profile.release] -# `wasm-opt` has some problems on linux, see -# https://github.com/rustwasm/wasm-pack/issues/781 etc. -wasm-opt = false + [package.metadata.wasm-pack.profile.release] + # `wasm-opt` has some problems on linux, see + # https://github.com/rustwasm/wasm-pack/issues/781 etc. + wasm-opt = false [lib] crate-type = ["cdylib", "rlib"] [dependencies] # crates -log = { version = "0.4.14" } -serde = { version = "1.0.126", optional = true } -structopt = { version = "0.3.21" } -tokio = { version = "0.3.7", optional = true, features = ["rt-multi-thread"] } +log = { version = "0.4.14" } +serde = { version = "1.0.126", optional = true } +structopt = { version = "0.3.21" } +tokio = { version = "0.3.7", optional = true, features = ["rt-multi-thread"] } # darwinia client -darwinia-cli = { optional = true, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-cli = { optional = true, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia service darwinia-service = { default-features = false, path = "../node/service" } # substrate client -sc-cli = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-client-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-executor = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-network = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-service = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-tracing = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -try-runtime-cli = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sc-cli = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-client-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-executor = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-network = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-service = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-tracing = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +try-runtime-cli = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sp-core = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sp-core = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # this crate is used only to enable `trie-memory-tracker` feature # see https://github.com/paritytech/substrate/pull/6745 -sp-trie = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sp-trie = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [build-dependencies] -substrate-build-script-utils = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -try-runtime-cli = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +substrate-build-script-utils = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +try-runtime-cli = { optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [features] default = [ @@ -60,10 +60,10 @@ cli = [ "darwinia-cli", "darwinia-service/full-node", ] -db = ["darwinia-service/db"] +db = ["darwinia-service/db"] trie-memory-tracker = ["sp-trie/memory-tracker"] -wasmtime = [ +wasmtime = [ "sc-cli/wasmtime", "trie-memory-tracker", ] diff --git a/cli/src/cli.rs b/cli/src/cli.rs index df9bc0375..628cbb563 100644 --- a/cli/src/cli.rs +++ b/cli/src/cli.rs @@ -66,6 +66,10 @@ pub struct RunCmd { /// to a subset. #[structopt(long = "disable-authority-discovery")] pub authority_discovery_disabled: bool, + + #[allow(missing_docs)] + #[structopt(flatten)] + pub dynamic_fee_parameters: DynamicFeeParameters, } #[allow(missing_docs)] @@ -109,3 +113,14 @@ pub enum Subcommand { #[cfg(feature = "try-runtime")] TryRuntime(try_runtime_cli::TryRuntimeCmd), } + +#[derive(Debug, StructOpt)] +pub struct DynamicFeeParameters { + /// Maximum number of logs in a query. + #[structopt(long, default_value = "10000")] + pub max_past_logs: u32, + + /// The dynamic-fee pallet target gas price set by block author + #[structopt(long, default_value = "1000000000")] + pub target_gas_price: u64, +} diff --git a/cli/src/command.rs b/cli/src/command.rs index b2cbe933a..f18ce7070 100644 --- a/cli/src/command.rs +++ b/cli/src/command.rs @@ -140,6 +140,8 @@ fn set_default_ss58_version(spec: &Box) { /// Parses Darwinia specific CLI arguments and run the service. pub fn run() -> sc_cli::Result<()> { let cli = Cli::from_args(); + let max_past_logs = cli.run.dynamic_fee_parameters.max_past_logs; + let target_gas_price = cli.run.dynamic_fee_parameters.target_gas_price; match &cli.subcommand { None => { @@ -162,8 +164,13 @@ pub fn run() -> sc_cli::Result<()> { Role::Light => { crab::crab_new_light(config).map(|(task_manager, _)| task_manager) } - _ => crab::crab_new_full(config, authority_discovery_disabled) - .map(|(task_manager, _, _)| task_manager), + _ => crab::crab_new_full( + config, + authority_discovery_disabled, + max_past_logs, + target_gas_price, + ) + .map(|(task_manager, _, _)| task_manager), } .map_err(sc_cli::Error::Service) }) @@ -194,7 +201,11 @@ pub fn run() -> sc_cli::Result<()> { if chain_spec.is_crab() { runner.async_run(|mut config| { let (client, _, import_queue, task_manager) = - crab::new_chain_ops::(&mut config)?; + crab::new_chain_ops::( + &mut config, + max_past_logs, + target_gas_price, + )?; Ok((cmd.run(client, import_queue), task_manager)) }) @@ -220,7 +231,11 @@ pub fn run() -> sc_cli::Result<()> { if chain_spec.is_crab() { runner.async_run(|mut config| { let (client, _, _, task_manager) = - crab::new_chain_ops::(&mut config)?; + crab::new_chain_ops::( + &mut config, + max_past_logs, + target_gas_price, + )?; Ok((cmd.run(client, config.database), task_manager)) }) @@ -246,7 +261,11 @@ pub fn run() -> sc_cli::Result<()> { if chain_spec.is_crab() { runner.async_run(|mut config| { let (client, _, _, task_manager) = - crab::new_chain_ops::(&mut config)?; + crab::new_chain_ops::( + &mut config, + max_past_logs, + target_gas_price, + )?; Ok((cmd.run(client, config.chain_spec), task_manager)) }) @@ -272,7 +291,11 @@ pub fn run() -> sc_cli::Result<()> { if chain_spec.is_crab() { runner.async_run(|mut config| { let (client, _, import_queue, task_manager) = - crab::new_chain_ops::(&mut config)?; + crab::new_chain_ops::( + &mut config, + max_past_logs, + target_gas_price, + )?; Ok((cmd.run(client, import_queue), task_manager)) }) @@ -302,7 +325,11 @@ pub fn run() -> sc_cli::Result<()> { if chain_spec.is_crab() { runner.async_run(|mut config| { let (client, backend, _, task_manager) = - crab::new_chain_ops::(&mut config)?; + crab::new_chain_ops::( + &mut config, + max_past_logs, + target_gas_price, + )?; Ok((cmd.run(client, backend), task_manager)) }) diff --git a/node/service/Cargo.toml b/node/service/Cargo.toml index 97821086d..1f03aff77 100644 --- a/node/service/Cargo.toml +++ b/node/service/Cargo.toml @@ -17,16 +17,17 @@ log = { version = "0.4.14" } serde = { version = "1.0.126", features = ["derive"] } serde_json = { version = "1.0.64" } # darwinia frame -darwinia-balances-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-header-mmr-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-balances-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-header-mmr-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # dvm -darwinia-evm = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dc-db = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dc-mapping-sync = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dc-rpc = { features = ["rpc_binary_search_estimate"], git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dp-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dvm-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-evm = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dc-db = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dc-mapping-sync = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dc-rpc = { features = ["rpc_binary_search_estimate"], git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dp-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-dynamic-fee = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia primitives darwinia-primitives = { path = "../../primitives" } # darwinia rpc @@ -35,41 +36,44 @@ darwinia-rpc = { path = "../../rpc" } crab-runtime = { path = "../../runtime/crab" } darwinia-runtime = { path = "../../runtime/darwinia" } # substrate client -sc-authority-discovery = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-basic-authorship = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-chain-spec = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-client-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-client-db = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-consensus = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-executor = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-finality-grandpa = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-network = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-service = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-telemetry = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-transaction-pool = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sc-authority-discovery = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-basic-authorship = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-chain-spec = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-client-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-client-db = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-consensus = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-consensus-uncles = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-executor = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-finality-grandpa = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-network = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-service = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-telemetry = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-transaction-pool = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate frame -frame-system-rpc-runtime-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-im-online = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -substrate-prometheus-endpoint = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +frame-system-rpc-runtime-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-im-online = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +substrate-prometheus-endpoint = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sc-consensus-slots = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-keystore = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-authority-discovery = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-block-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-blockchain = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-consensus = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-core = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-finality-grandpa = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-inherents = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-offchain = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-runtime = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-session = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-transaction-pool = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-trie = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sc-consensus-slots = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-keystore = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-authority-discovery = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-authorship = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-block-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-blockchain = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-consensus = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-core = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-finality-grandpa = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-inherents = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-offchain = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-runtime = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-session = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-timestamp = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-transaction-pool = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-trie = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [features] default = ["db", "full-node"] diff --git a/node/service/src/chain_spec/crab.rs b/node/service/src/chain_spec/crab.rs index 1cdb3b484..54490089a 100644 --- a/node/service/src/chain_spec/crab.rs +++ b/node/service/src/chain_spec/crab.rs @@ -206,6 +206,7 @@ pub fn crab_build_spec_genesis() -> GenesisConfig { accounts: BTreeMap::new(), }, dvm_ethereum: Default::default(), + dvm_dynamic_fee: Default::default(), } } @@ -315,6 +316,7 @@ pub fn crab_testnet_genesis( accounts: BTreeMap::new(), }, dvm_ethereum: Default::default(), + dvm_dynamic_fee: Default::default(), } } diff --git a/node/service/src/service/crab.rs b/node/service/src/service/crab.rs index 7d4e911a3..e809fce67 100644 --- a/node/service/src/service/crab.rs +++ b/node/service/src/service/crab.rs @@ -53,8 +53,7 @@ use sp_api::ConstructRuntimeApi; use sp_consensus::{ import_queue::BasicQueue, CanAuthorWithNativeVersion, DefaultImportQueue, NeverCanAuthor, }; -use sp_inherents::InherentDataProviders; -use sp_runtime::traits::BlakeTwo256; +use sp_runtime::traits::{BlakeTwo256, Block as BlockT}; use sp_trie::PrefixedMemoryDB; // --- darwinia --- use crate::{client::CrabClient, service::*}; @@ -97,6 +96,8 @@ fn open_frontier_backend(config: &Configuration) -> Result>, #[cfg(feature = "full-node")] fn new_partial( config: &mut Configuration, + max_past_logs: u32, + target_gas_price: u64, ) -> Result< PartialComponents< FullClient, @@ -144,7 +145,6 @@ where set_prometheus_registry(config)?; - let inherent_data_providers = InherentDataProviders::new(); let telemetry = config .telemetry_endpoints .clone() @@ -188,13 +188,28 @@ where grandpa_block_import, client.clone(), )?; + let slot_duration = babe_link.config().slot_duration(); let import_queue = sc_consensus_babe::import_queue( babe_link.clone(), babe_import.clone(), Some(Box::new(justification_import)), client.clone(), select_chain.clone(), - inherent_data_providers.clone(), + move |_, ()| async move { + let uncles = + sp_authorship::InherentDataProvider::<::Header>::check_inherents(); + let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); + let slot = + sp_consensus_babe::inherents::InherentDataProvider::from_timestamp_and_duration( + *timestamp, + slot_duration, + ); + let dynamic_fee = dvm_dynamic_fee::InherentDataProvider::from_target_gas_price( + target_gas_price.into(), + ); + + Ok((timestamp, slot, uncles, dynamic_fee)) + }, &task_manager.spawn_essential_handle(), config.prometheus_registry(), CanAuthorWithNativeVersion::new(client.executor().clone()), @@ -254,6 +269,7 @@ where pending_transactions: pending_transactions.clone(), backend: frontier_backend.clone(), filter_pool: filter_pool.clone(), + max_past_logs, // --- dvm ---> }; @@ -269,7 +285,6 @@ where select_chain, import_queue, transaction_pool, - inherent_data_providers, other: ( rpc_extensions_builder, import_setup, @@ -286,6 +301,8 @@ where fn new_full( mut config: Configuration, authority_discovery_disabled: bool, + max_past_logs: u32, + target_gas_price: u64, ) -> Result< ( TaskManager, @@ -317,7 +334,6 @@ where select_chain, import_queue, transaction_pool, - inherent_data_providers, other: ( rpc_extensions_builder, @@ -328,7 +344,7 @@ where frontier_backend, filter_pool, ), - } = new_partial::(&mut config)?; + } = new_partial::(&mut config, max_past_logs, target_gas_price)?; if let Some(url) = &config.keystore_remote { match remote_keystore(url) { @@ -423,6 +439,8 @@ where prometheus_registry.as_ref(), telemetry.as_ref().map(|x| x.handle()), ); + let client_clone = client.clone(); + let slot_duration = babe_link.config().slot_duration(); let babe_config = BabeParams { keystore: keystore_container.sync_keystore(), client: client.clone(), @@ -430,7 +448,26 @@ where block_import, env: proposer, sync_oracle: network.clone(), - inherent_data_providers: inherent_data_providers.clone(), + create_inherent_data_providers: move |parent, ()| { + let client_clone = client_clone.clone(); + async move { + let uncles = sc_consensus_uncles::create_uncles_inherent_data_provider( + &*client_clone, + parent, + )?; + let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); + let slot = + sp_consensus_babe::inherents::InherentDataProvider::from_timestamp_and_duration( + *timestamp, + slot_duration, + ); + let dynamic_fee = dvm_dynamic_fee::InherentDataProvider::from_target_gas_price( + target_gas_price.into(), + ); + + Ok((timestamp, slot, uncles, dynamic_fee)) + } + }, force_authoring, backoff_authoring_blocks, babe_link, @@ -618,15 +655,26 @@ where grandpa_block_import, client.clone(), )?; - let inherent_data_providers = InherentDataProviders::new(); // FIXME: pruning task isn't started since light client doesn't do `AuthoritySetup`. + let slot_duration = babe_link.config().slot_duration(); let import_queue = sc_consensus_babe::import_queue( babe_link, babe_block_import, Some(Box::new(justification_import)), client.clone(), select_chain.clone(), - inherent_data_providers.clone(), + move |_, ()| async move { + let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); + let slot = + sp_consensus_babe::inherents::InherentDataProvider::from_timestamp_and_duration( + *timestamp, + slot_duration, + ); + let uncles = + sp_authorship::InherentDataProvider::<::Header>::check_inherents(); + + Ok((timestamp, slot, uncles)) + }, &task_manager.spawn_essential_handle(), config.prometheus_registry(), NeverCanAuthor, @@ -685,6 +733,8 @@ where #[cfg(feature = "full-node")] pub fn new_chain_ops( config: &mut Configuration, + max_past_logs: u32, + target_gas_price: u64, ) -> Result< ( Arc>, @@ -707,7 +757,7 @@ where import_queue, task_manager, .. - } = new_partial::(config)?; + } = new_partial::(config, max_past_logs, target_gas_price)?; Ok((client, backend, import_queue, task_manager)) } @@ -717,6 +767,8 @@ where pub fn crab_new_full( config: Configuration, authority_discovery_disabled: bool, + max_past_logs: u32, + target_gas_price: u64, ) -> Result< ( TaskManager, @@ -725,8 +777,12 @@ pub fn crab_new_full( ), ServiceError, > { - let (components, client, rpc_handlers) = - new_full::(config, authority_discovery_disabled)?; + let (components, client, rpc_handlers) = new_full::( + config, + authority_discovery_disabled, + max_past_logs, + target_gas_price, + )?; Ok((components, client, rpc_handlers)) } diff --git a/node/service/src/service/darwinia.rs b/node/service/src/service/darwinia.rs index cded57871..c6b0d4e5d 100644 --- a/node/service/src/service/darwinia.rs +++ b/node/service/src/service/darwinia.rs @@ -49,8 +49,7 @@ use sp_api::ConstructRuntimeApi; use sp_consensus::{ import_queue::BasicQueue, CanAuthorWithNativeVersion, DefaultImportQueue, NeverCanAuthor, }; -use sp_inherents::InherentDataProviders; -use sp_runtime::traits::BlakeTwo256; +use sp_runtime::traits::{BlakeTwo256, Block as BlockT}; use sp_trie::PrefixedMemoryDB; // --- darwinia --- use crate::{client::DarwiniaClient, service::*}; @@ -110,7 +109,6 @@ where set_prometheus_registry(config)?; - let inherent_data_providers = InherentDataProviders::new(); let telemetry = config .telemetry_endpoints .clone() @@ -154,13 +152,24 @@ where grandpa_block_import, client.clone(), )?; + let slot_duration = babe_link.config().slot_duration(); let import_queue = sc_consensus_babe::import_queue( babe_link.clone(), babe_import.clone(), Some(Box::new(justification_import)), client.clone(), select_chain.clone(), - inherent_data_providers.clone(), + move |_, ()| async move { + let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); + + let slot = + sp_consensus_babe::inherents::InherentDataProvider::from_timestamp_and_duration( + *timestamp, + slot_duration, + ); + + Ok((timestamp, slot)) + }, &task_manager.spawn_essential_handle(), config.prometheus_registry(), CanAuthorWithNativeVersion::new(client.executor().clone()), @@ -217,7 +226,6 @@ where select_chain, import_queue, transaction_pool, - inherent_data_providers, other: (rpc_extensions_builder, import_setup, rpc_setup, telemetry), }) } @@ -256,7 +264,6 @@ where select_chain, import_queue, transaction_pool, - inherent_data_providers, other: (rpc_extensions_builder, import_setup, rpc_setup, mut telemetry), } = new_partial::(&mut config)?; @@ -338,6 +345,8 @@ where prometheus_registry.as_ref(), telemetry.as_ref().map(|x| x.handle()), ); + let client_clone = client.clone(); + let slot_duration = babe_link.config().slot_duration(); let babe_config = BabeParams { keystore: keystore_container.sync_keystore(), client: client.clone(), @@ -345,7 +354,25 @@ where block_import, env: proposer, sync_oracle: network.clone(), - inherent_data_providers: inherent_data_providers.clone(), + create_inherent_data_providers: move |parent, ()| { + let client_clone = client_clone.clone(); + async move { + let uncles = sc_consensus_uncles::create_uncles_inherent_data_provider( + &*client_clone, + parent, + )?; + + let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); + + let slot = + sp_consensus_babe::inherents::InherentDataProvider::from_timestamp_and_duration( + *timestamp, + slot_duration, + ); + + Ok((timestamp, slot, uncles)) + } + }, force_authoring, backoff_authoring_blocks, babe_link, @@ -494,15 +521,28 @@ where grandpa_block_import, client.clone(), )?; - let inherent_data_providers = InherentDataProviders::new(); // FIXME: pruning task isn't started since light client doesn't do `AuthoritySetup`. + let slot_duration = babe_link.config().slot_duration(); let import_queue = sc_consensus_babe::import_queue( babe_link, babe_block_import, Some(Box::new(justification_import)), client.clone(), select_chain.clone(), - inherent_data_providers.clone(), + move |_, ()| async move { + let timestamp = sp_timestamp::InherentDataProvider::from_system_time(); + + let slot = + sp_consensus_babe::inherents::InherentDataProvider::from_timestamp_and_duration( + *timestamp, + slot_duration, + ); + + let uncles = + sp_authorship::InherentDataProvider::<::Header>::check_inherents(); + + Ok((timestamp, slot, uncles)) + }, &task_manager.spawn_essential_handle(), config.prometheus_registry(), NeverCanAuthor, diff --git a/primitives/Cargo.toml b/primitives/Cargo.toml index 13a8a1f6e..de6c9ae00 100644 --- a/primitives/Cargo.toml +++ b/primitives/Cargo.toml @@ -12,11 +12,11 @@ version = "0.11.0" # crates codec = { package = "parity-scale-codec", version = "2.1.1", default-features = false } # substrate frame -frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sp-application-crypto = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-core = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sp-application-crypto = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-core = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [features] default = ["std"] @@ -27,8 +27,8 @@ std = [ "substrate-primitives-std", ] -crates-std = ["codec/std"] -substrate-frame-std = ["frame-system/std"] +crates-std = ["codec/std"] +substrate-frame-std = ["frame-system/std"] substrate-primitives-std = [ "sp-application-crypto/std", "sp-core/std", diff --git a/rpc/Cargo.toml b/rpc/Cargo.toml index 08e3e5eca..48f8f1ebe 100644 --- a/rpc/Cargo.toml +++ b/rpc/Cargo.toml @@ -14,37 +14,37 @@ code = { package = "parity-scale-codec", version = "2.1.1", default-fe jsonrpc-core = { version = "15.1.0" } jsonrpc-pubsub = { version = "15.1.0" } # darwinia frame -darwinia-balances-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-header-mmr-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dc-db = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dc-rpc = { features = ["rpc_binary_search_estimate"], git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dp-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dvm-ethereum = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dvm-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-balances-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-header-mmr-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dc-db = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dc-rpc = { features = ["rpc_binary_search_estimate"], git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dp-rpc = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-ethereum = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-rpc-runtime-api = { git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia primitives crab-runtime = { path = "../runtime/crab" } darwinia-primitives = { path = "../primitives" } # substrate client -sc-chain-spec = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-client-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-consensus-babe-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-consensus-epochs = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-finality-grandpa = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-finality-grandpa-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sc-sync-state-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sc-chain-spec = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-client-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-consensus-babe-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-consensus-epochs = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-finality-grandpa = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-finality-grandpa-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sc-sync-state-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate frame -pallet-transaction-payment-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -substrate-frame-rpc-system = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +pallet-transaction-payment-rpc = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +substrate-frame-rpc-system = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sc-network = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-block-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-blockchain = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-consensus = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-keystore = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-runtime = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-transaction-pool = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sc-network = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-api = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-block-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-blockchain = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-consensus = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-consensus-babe = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-keystore = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-runtime = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-transaction-pool = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } diff --git a/rpc/src/crab.rs b/rpc/src/crab.rs index 9eedfdee4..7ba39efec 100644 --- a/rpc/src/crab.rs +++ b/rpc/src/crab.rs @@ -22,9 +22,9 @@ // --- std --- use std::{collections::BTreeMap, sync::Arc}; -// --- substrate --- +// --- paritytech --- use sp_api::ProvideRuntimeApi; -// --- darwinia --- +// --- darwinia-network --- use crate::*; use darwinia_primitives::{AccountId, Balance, Nonce, Power}; use dp_rpc::{FilterPool, PendingTransactions}; @@ -46,6 +46,7 @@ pub struct FullDeps { pub babe: BabeDeps, /// GRANDPA specific dependencies. pub grandpa: GrandpaDeps, + // <--- dvm --- /// The Node authority flag pub is_authority: bool, /// Network service @@ -56,6 +57,9 @@ pub struct FullDeps { pub filter_pool: Option, /// Backend. pub backend: Arc>, + /// Maximum number of logs in a query. + pub max_past_logs: u32, + // --- dvm ---> } /// Light client extra dependencies. @@ -81,8 +85,10 @@ where + Sync + ProvideRuntimeApi + sc_client_api::AuxStore + // <--- dvm --- + sc_client_api::BlockchainEvents + sc_client_api::StorageProvider + // --- dvm ---> + sp_blockchain::HeaderBackend + sp_blockchain::HeaderMetadata, C::Api: substrate_frame_rpc_system::AccountNonceApi, @@ -92,28 +98,32 @@ where C::Api: darwinia_balances_rpc::BalancesRuntimeApi, C::Api: darwinia_header_mmr_rpc::HeaderMMRRuntimeApi, C::Api: darwinia_staking_rpc::StakingRuntimeApi, + // <--- dvm --- C::Api: dvm_rpc_runtime_api::EthereumRuntimeRPCApi, + // --- dvm ---> P: 'static + Sync + Send + sp_transaction_pool::TransactionPool, SC: 'static + sp_consensus::SelectChain, B: 'static + Send + Sync + sc_client_api::Backend, B::State: sc_client_api::StateBackend>, { - // --- substrate --- + // --- paritytech --- use pallet_transaction_payment_rpc::{TransactionPayment, TransactionPaymentApi}; use sc_consensus_babe_rpc::{BabeApi, BabeRpcHandler}; use sc_finality_grandpa_rpc::{GrandpaApi, GrandpaRpcHandler}; use sc_sync_state_rpc::{SyncStateRpcApi, SyncStateRpcHandler}; use substrate_frame_rpc_system::{FullSystem, SystemApi}; - // --- darwinia --- + // --- darwinia-network --- use crab_runtime::TransactionConverter; use darwinia_balances_rpc::{Balances, BalancesApi}; use darwinia_header_mmr_rpc::{HeaderMMR, HeaderMMRApi}; use darwinia_staking_rpc::{Staking, StakingApi}; + // <--- dvm --- use dc_rpc::{ EthApi, EthApiServer, EthFilterApi, EthFilterApiServer, EthPubSubApi, EthPubSubApiServer, HexEncodedIdProvider, NetApi, NetApiServer, OverrideHandle, RuntimeApiStorageOverride, SchemaV1Override, StorageOverride, Web3Api, Web3ApiServer, }; + // --- dvm ---> use jsonrpc_pubsub::manager::SubscriptionManager; let FullDeps { @@ -124,11 +134,14 @@ where deny_unsafe, babe, grandpa, + // < --- dvm --- is_authority, network, pending_transactions, filter_pool, backend, + max_past_logs, + // --- dvm ---> } = deps; let mut io = jsonrpc_core::IoHandler::default(); @@ -178,7 +191,7 @@ where io.extend_with(HeaderMMRApi::to_delegate(HeaderMMR::new(client.clone()))); io.extend_with(StakingApi::to_delegate(Staking::new(client.clone()))); - // DVM + // < --- dvm --- let mut overrides_map = BTreeMap::new(); overrides_map.insert( EthereumStorageSchema::V1, @@ -198,6 +211,7 @@ where pending_transactions.clone(), backend, is_authority, + max_past_logs, ))); if let Some(filter_pool) = filter_pool { io.extend_with(EthFilterApiServer::to_delegate(EthFilterApi::new( @@ -205,6 +219,7 @@ where filter_pool.clone(), 500 as usize, // max stored filters overrides.clone(), + max_past_logs, ))); } io.extend_with(EthPubSubApiServer::to_delegate(EthPubSubApi::new( @@ -220,8 +235,11 @@ where io.extend_with(NetApiServer::to_delegate(NetApi::new( client.clone(), network, + // Whether to format the `peer_count` response as Hex (default) or not. + true, ))); io.extend_with(Web3ApiServer::to_delegate(Web3Api::new(client))); + // --- dvm ---> io } @@ -235,7 +253,7 @@ where P: 'static + sp_transaction_pool::TransactionPool, F: 'static + sc_client_api::Fetcher, { - // --- substrate --- + // --- paritytech --- use substrate_frame_rpc_system::{LightSystem, SystemApi}; let LightDeps { diff --git a/runtime/common/Cargo.toml b/runtime/common/Cargo.toml index 6f39b5f4a..c06e2b34b 100644 --- a/runtime/common/Cargo.toml +++ b/runtime/common/Cargo.toml @@ -13,26 +13,26 @@ version = "0.11.0" codec = { package = "parity-scale-codec", version = "2.1.1", default-features = false } static_assertions = { version = "1.1.0" } # darwinia frame -darwinia-balances = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-support = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-treasury = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-balances = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-support = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-treasury = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia primitives darwinia-primitives = { default-features = false, path = "../../primitives" } # substrate frame -frame-support = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-authorship = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-transaction-payment = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +frame-support = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-authorship = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-transaction-payment = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-std = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-std = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [features] default = ["std"] no_std = [] -std = [ +std = [ "crates-std", "darwinia-frame-std", "darwinia-primitives-std", @@ -40,15 +40,15 @@ std = [ "substrate-primitives-std", ] -crates-std = ["codec/std"] -darwinia-frame-std = [ +crates-std = ["codec/std"] +darwinia-frame-std = [ "darwinia-balances/std", "darwinia-staking/std", "darwinia-support/std", "darwinia-treasury/std", ] -darwinia-primitives-std = ["darwinia-primitives/std"] -substrate-frame-std = [ +darwinia-primitives-std = ["darwinia-primitives/std"] +substrate-frame-std = [ "frame-support/std", "frame-system/std", "pallet-authorship/std", diff --git a/runtime/crab/Cargo.toml b/runtime/crab/Cargo.toml index 3393525b5..c8ab2468a 100644 --- a/runtime/crab/Cargo.toml +++ b/runtime/crab/Cargo.toml @@ -18,84 +18,85 @@ serde = { version = "1.0.126", optional = true } smallvec = { version = "1.6.1" } static_assertions = { version = "1.1.0" } # darwinia frame -darwinia-balances = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-balances-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-claims = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-crab-issuing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-democracy = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-elections-phragmen = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-evm = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-evm-precompile-empty = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-evm-precompile-simple = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-evm-precompile-withdraw = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-header-mmr = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-header-mmr-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-support = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-treasury = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-vesting = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dp-storage = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dvm-ethereum = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -dvm-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-balances = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-balances-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-claims = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-crab-issuing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-democracy = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-elections-phragmen = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-evm = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-evm-precompile-empty = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-evm-precompile-simple = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-evm-precompile-withdraw = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-header-mmr = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-header-mmr-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-support = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-treasury = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-vesting = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dp-storage = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-dynamic-fee = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-ethereum = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +dvm-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia primitives darwinia-primitives = { default-features = false, path = "../../primitives" } -ethereum-primitives = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +ethereum-primitives = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia runtime darwinia-runtime-common = { default-features = false, path = "../common" } # substrate frame -frame-executive = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-support = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-system-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-try-runtime = { default-features = false, optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-authorship = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-collective = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-election-provider-multi-phase = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-grandpa = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-identity = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-im-online = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-indices = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-membership = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-multisig = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-offences = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-proxy = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-randomness-collective-flip = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-recovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-scheduler = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-session = { default-features = false, features = ["historical"], git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-society = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-sudo = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-timestamp = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-transaction-payment = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-transaction-payment-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-utility = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +frame-executive = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-support = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-system-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-try-runtime = { default-features = false, optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-authorship = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-collective = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-election-provider-multi-phase = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-grandpa = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-identity = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-im-online = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-indices = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-membership = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-multisig = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-offences = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-proxy = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-randomness-collective-flip = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-recovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-scheduler = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-session = { default-features = false, features = ["historical"], git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-society = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-sudo = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-timestamp = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-transaction-payment = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-transaction-payment-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-utility = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sp-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-block-builder = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-consensus-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-core = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-inherents = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-npos-elections = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-offchain = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-session = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-staking = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-std = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-transaction-pool = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-version = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sp-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-block-builder = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-consensus-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-core = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-inherents = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-npos-elections = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-offchain = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-session = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-staking = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-std = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-transaction-pool = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-version = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [build-dependencies] -substrate-wasm-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +substrate-wasm-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [features] default = ["std"] no_std = [] -std = [ +std = [ "codec/std", "serde", "darwinia-balances/std", @@ -120,6 +121,7 @@ std = [ "darwinia-runtime-common/std", "dp-storage/std", "dvm-ethereum/std", + "dvm-dynamic-fee/std", "dvm-rpc-runtime-api/std", "frame-executive/std", "frame-support/std", diff --git a/runtime/crab/src/lib.rs b/runtime/crab/src/lib.rs index 468342be0..1baa2975c 100644 --- a/runtime/crab/src/lib.rs +++ b/runtime/crab/src/lib.rs @@ -77,7 +77,7 @@ mod weights; use codec::{Decode, Encode}; // --- substrate --- use frame_support::{ - traits::{KeyOwnerProofSystem, OnRuntimeUpgrade, Randomness}, + traits::{KeyOwnerProofSystem, OnRuntimeUpgrade}, weights::Weight, }; use pallet_grandpa::{fg_primitives, AuthorityList as GrandpaAuthorityList}; @@ -101,7 +101,7 @@ use sp_version::NativeVersion; use sp_version::RuntimeVersion; // --- darwinia --- use darwinia_balances_rpc_runtime_api::RuntimeDispatchInfo as BalancesRuntimeDispatchInfo; -use darwinia_evm::{Account as EVMAccount, FeeCalculator, Runner}; +use darwinia_evm::{Account as EVMAccount, Runner}; use darwinia_header_mmr_rpc_runtime_api::RuntimeDispatchInfo as HeaderMMRRuntimeDispatchInfo; use darwinia_primitives::*; use darwinia_runtime_common::*; @@ -255,6 +255,7 @@ frame_support::construct_runtime! { // DVM EVM: darwinia_evm::{Pallet, Call, Storage, Config, Event} = 39, Ethereum: dvm_ethereum::{Pallet, Call, Storage, Config, Event, ValidateUnsigned} = 40, + DynamicFee: dvm_dynamic_fee::{Pallet, Call, Storage, Config, Event, Inherent} = 42, } } @@ -351,10 +352,6 @@ sp_api::impl_runtime_apis! { ) -> sp_inherents::CheckInherentsResult { data.check_extrinsics(&block) } - - fn random_seed() -> ::Hash { - pallet_babe::RandomnessFromOneEpochAgo::::random_seed().0 - } } impl sp_transaction_pool::runtime_api::TaggedTransactionQueue for Runtime { @@ -667,44 +664,6 @@ impl OnRuntimeUpgrade for CustomOnRuntimeUpgrade { } fn on_runtime_upgrade() -> Weight { - migrate() + 0 } } - -fn migrate() -> Weight { - // --- paritytech --- - use frame_support::{migration, storage::StorageMap}; - - const BAD_SCHEDULE_KEY: BlockNumber = 2332800; - - log::info!("Moving storage `Instance0DarwiniaBalances` to `Balances`"); - migration::move_pallet(b"Instance0DarwiniaBalances", b"Balances"); - log::info!("Moving storage `Instance1DarwiniaBalances` to `Kton`"); - migration::move_pallet(b"Instance1DarwiniaBalances", b"Kton"); - - // Tech.Comm to Instance2 - log::info!("Moving storage `Instance1Collective` to `Instance2Collective`"); - migration::move_pallet(b"Instance1Collective", b"Instance2Collective"); - // Council to Instance1 - log::info!("Moving storage `Instance0Collective` to `Instance1Collective`"); - migration::move_pallet(b"Instance0Collective", b"Instance1Collective"); - - log::info!("Moving storage `Instance0Membership` to `Instance1Membership`"); - migration::move_pallet(b"Instance0Membership", b"Instance1Membership"); - - log::info!("Moving storage `DarwiniaPhragmenElection` to `PhragmenElection`"); - migration::move_pallet(b"DarwiniaPhragmenElection", b"PhragmenElection"); - - #[cfg(feature = "try-runtime")] - assert!(>::contains_key( - BAD_SCHEDULE_KEY - )); - log::info!("Removing bad schedule"); - >::remove(BAD_SCHEDULE_KEY); - #[cfg(feature = "try-runtime")] - assert!(!>::contains_key( - BAD_SCHEDULE_KEY - )); - - RuntimeBlockWeights::get().max_block -} diff --git a/runtime/crab/src/pallets/dynamic_fee.rs b/runtime/crab/src/pallets/dynamic_fee.rs new file mode 100644 index 000000000..254992bc0 --- /dev/null +++ b/runtime/crab/src/pallets/dynamic_fee.rs @@ -0,0 +1,14 @@ +// --- paritytech --- +use sp_core::U256; +// --- darwinia-network --- +use crate::*; +use dvm_dynamic_fee::Config; + +frame_support::parameter_types! { + pub BoundDivision: U256 = U256::from(1024); +} + +impl Config for Runtime { + type Event = Event; + type MinGasPriceBoundDivisor = BoundDivision; +} diff --git a/runtime/crab/src/pallets/election_provider_multi_phase.rs b/runtime/crab/src/pallets/election_provider_multi_phase.rs index bee112f01..421cddec9 100644 --- a/runtime/crab/src/pallets/election_provider_multi_phase.rs +++ b/runtime/crab/src/pallets/election_provider_multi_phase.rs @@ -27,6 +27,7 @@ frame_support::parameter_types! { // miner configs pub NposSolutionPriority: TransactionPriority = Perbill::from_percent(90) * TransactionPriority::max_value(); pub const MinerMaxIterations: u32 = 10; + pub const OffchainRepeat: BlockNumber = 5; } impl Config for Runtime { @@ -37,7 +38,8 @@ impl Config for Runtime { type SolutionImprovementThreshold = SolutionImprovementThreshold; type MinerMaxIterations = MinerMaxIterations; type MinerMaxWeight = OffchainSolutionWeightLimit; - type MinerMaxLength = OffchainSolutionLengthLimit; + type MinerMaxLength = OffchainSolutionLengthLimit; // For now use the one from staking. + type OffchainRepeat = OffchainRepeat; type MinerTxPriority = NposSolutionPriority; type DataProvider = Staking; type OnChainAccuracy = Perbill; diff --git a/runtime/crab/src/pallets/evm.rs b/runtime/crab/src/pallets/evm.rs index 21964d127..22fb74ce4 100644 --- a/runtime/crab/src/pallets/evm.rs +++ b/runtime/crab/src/pallets/evm.rs @@ -1,23 +1,10 @@ -// --- substrate --- -use sp_core::{H160, U256}; -use sp_runtime::DispatchResult; -// --- darwinia --- +// --- paritytech --- +use sp_core::U256; +// --- darwinia-network --- use crate::*; -use darwinia_evm::{ - runner::stack::Runner, ConcatAddressMapping, Config, EnsureAddressTruncated, FeeCalculator, - IssuingHandler, -}; +use darwinia_evm::{runner::stack::Runner, ConcatAddressMapping, Config, EnsureAddressTruncated}; use dvm_ethereum::account_basic::{DvmAccountBasic, KtonRemainBalance, RingRemainBalance}; -/// Fixed gas price. -pub struct FixedGasPrice; -impl FeeCalculator for FixedGasPrice { - fn min_gas_price() -> U256 { - // Gas price is always one token per gas. - 1_000_000_000.into() - } -} - pub type CrabPrecompiles = ( darwinia_evm_precompile_simple::ECRecover, // 0x0000000000000000000000000000000000000001 darwinia_evm_precompile_simple::Sha256, // 0x0000000000000000000000000000000000000002 @@ -46,8 +33,9 @@ frame_support::parameter_types! { pub const ChainId: u64 = 44; pub BlockGasLimit: U256 = U256::from(u32::max_value()); } + impl Config for Runtime { - type FeeCalculator = FixedGasPrice; + type FeeCalculator = DynamicFee; type GasWeightMapping = (); type CallOrigin = EnsureAddressTruncated; type AddressMapping = ConcatAddressMapping; @@ -60,12 +48,5 @@ impl Config for Runtime { type RingAccountBasic = DvmAccountBasic; type KtonAccountBasic = DvmAccountBasic; type Runner = Runner; - type IssuingHandler = DisableIssuing; -} - -pub struct DisableIssuing; -impl IssuingHandler for DisableIssuing { - fn handle(_: H160, _: H160, _: &[u8]) -> DispatchResult { - Err("unimplemented".into()) - } + type IssuingHandler = (); } diff --git a/runtime/crab/src/pallets/mod.rs b/runtime/crab/src/pallets/mod.rs index a31e3a7ca..2588410ab 100644 --- a/runtime/crab/src/pallets/mod.rs +++ b/runtime/crab/src/pallets/mod.rs @@ -99,3 +99,6 @@ pub use evm::*; pub mod dvm; pub use dvm::*; + +pub mod dynamic_fee; +pub use dynamic_fee::*; diff --git a/runtime/crab/src/pallets/offences.rs b/runtime/crab/src/pallets/offences.rs index 616cea9b1..42b778cf0 100644 --- a/runtime/crab/src/pallets/offences.rs +++ b/runtime/crab/src/pallets/offences.rs @@ -1,19 +1,11 @@ // --- substrate --- -use frame_support::weights::Weight; use pallet_offences::Config; use pallet_session::historical::IdentificationTuple; -use sp_runtime::Perbill; // --- darwinia --- use crate::*; -frame_support::parameter_types! { - pub OffencesWeightSoftLimit: Weight = Perbill::from_percent(60) - * RuntimeBlockWeights::get().max_block; -} - impl Config for Runtime { type Event = Event; type IdentificationTuple = IdentificationTuple; type OnOffenceHandler = Staking; - type WeightSoftLimit = OffencesWeightSoftLimit; } diff --git a/runtime/crab/src/pallets/staking.rs b/runtime/crab/src/pallets/staking.rs index 5afa21267..07f2e9df8 100644 --- a/runtime/crab/src/pallets/staking.rs +++ b/runtime/crab/src/pallets/staking.rs @@ -32,6 +32,7 @@ frame_support::parameter_types! { pub const Cap: Balance = CAP; pub const TotalPower: Power = TOTAL_POWER; } + impl Config for Runtime { const MAX_NOMINATIONS: u32 = ::LIMIT as u32; type Event = Event; diff --git a/runtime/darwinia/Cargo.toml b/runtime/darwinia/Cargo.toml index fc4b32331..9ec9dc367 100644 --- a/runtime/darwinia/Cargo.toml +++ b/runtime/darwinia/Cargo.toml @@ -18,75 +18,75 @@ serde_json = { version = "1.0.64", optional = true } smallvec = { version = "1.6.1" } static_assertions = { version = "1.1.0" } # darwinia frame -darwinia-balances = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-balances-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-crab-backing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-democracy = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-elections-phragmen = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-ethereum-backing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-ethereum-relay = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-header-mmr = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-header-mmr-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-relay-authorities = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-relay-primitives = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-relayer-game = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-staking-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-support = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-treasury = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-tron-backing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } -darwinia-vesting = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +darwinia-balances = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-balances-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-crab-backing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-democracy = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-elections-phragmen = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-ethereum-backing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-ethereum-relay = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-header-mmr = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-header-mmr-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-relay-authorities = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-relay-primitives = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-relayer-game = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-staking-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-support = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-treasury = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-tron-backing = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } +darwinia-vesting = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia primitives darwinia-primitives = { default-features = false, path = "../../primitives" } -ethereum-primitives = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.0" } +ethereum-primitives = { default-features = false, git = "https://github.com/darwinia-network/darwinia-common.git", tag = "darwinia-v0.11.1" } # darwinia runtime darwinia-runtime-common = { default-features = false, path = "../common" } # substrate frame -frame-executive = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-support = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-system-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -frame-try-runtime = { default-features = false, optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-authorship = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-collective = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-election-provider-multi-phase = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-grandpa = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-identity = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-im-online = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-membership = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-multisig = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-offences = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-proxy = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-randomness-collective-flip = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-recovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-scheduler = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-session = { default-features = false, features = ["historical"], git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-society = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-sudo = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-timestamp = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-transaction-payment = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-transaction-payment-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -pallet-utility = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +frame-executive = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-support = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-system = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-system-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +frame-try-runtime = { default-features = false, optional = true, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-authorship = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-collective = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-election-provider-multi-phase = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-grandpa = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-identity = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-im-online = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-membership = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-multisig = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-offences = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-proxy = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-randomness-collective-flip = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-recovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-scheduler = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-session = { default-features = false, features = ["historical"], git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-society = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-sudo = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-timestamp = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-transaction-payment = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-transaction-payment-rpc-runtime-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +pallet-utility = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } # substrate primitives -sp-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-block-builder = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-consensus-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-core = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-inherents = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-npos-elections = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-offchain = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-session = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-staking = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-std = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-transaction-pool = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } -sp-version = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +sp-api = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-authority-discovery = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-block-builder = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-consensus-babe = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-core = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-inherents = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-npos-elections = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-offchain = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-runtime = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-session = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-staking = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-std = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-transaction-pool = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } +sp-version = { default-features = false, git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [build-dependencies] -substrate-wasm-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.0" } +substrate-wasm-builder = { git = "https://github.com/darwinia-network/substrate.git", tag = "darwinia-v0.11.1" } [features] default = ["std"] diff --git a/runtime/darwinia/src/lib.rs b/runtime/darwinia/src/lib.rs index 91cd73148..423dde373 100644 --- a/runtime/darwinia/src/lib.rs +++ b/runtime/darwinia/src/lib.rs @@ -119,7 +119,7 @@ pub use darwinia_staking::{Forcing, StakerStatus}; use codec::Encode; // --- substrate --- use frame_support::{ - traits::{KeyOwnerProofSystem, OnRuntimeUpgrade, Randomness}, + traits::{KeyOwnerProofSystem, OnRuntimeUpgrade}, weights::Weight, PalletId, }; @@ -395,10 +395,6 @@ impl_runtime_apis! { ) -> sp_inherents::CheckInherentsResult { data.check_extrinsics(&block) } - - fn random_seed() -> ::Hash { - pallet_babe::RandomnessFromOneEpochAgo::::random_seed().0 - } } impl sp_transaction_pool::runtime_api::TaggedTransactionQueue for Runtime { @@ -575,48 +571,10 @@ pub struct CustomOnRuntimeUpgrade; impl OnRuntimeUpgrade for CustomOnRuntimeUpgrade { #[cfg(feature = "try-runtime")] fn pre_upgrade() -> Result<(), &'static str> { - // --- substrate --- - // use frame_support::migration; - Ok(()) } fn on_runtime_upgrade() -> Weight { - // --- substrate --- - use frame_support::migration; - - log::info!("Moving storage `Instance0DarwiniaBalances` to `Balances`"); - migration::move_pallet(b"Instance0DarwiniaBalances", b"Balances"); - log::info!("Moving storage `Instance1DarwiniaBalances` to `Kton`"); - migration::move_pallet(b"Instance1DarwiniaBalances", b"Kton"); - - // Tech.Comm to Instance2 - log::info!("Moving storage `Instance1Collective` to `Instance2Collective`"); - migration::move_pallet(b"Instance1Collective", b"Instance2Collective"); - // Council to Instance1 - log::info!("Moving storage `Instance0Collective` to `Instance1Collective`"); - migration::move_pallet(b"Instance0Collective", b"Instance1Collective"); - - log::info!("Moving storage `Instance0Membership` to `Instance1Membership`"); - migration::move_pallet(b"Instance0Membership", b"Instance1Membership"); - - log::info!("Moving storage `DarwiniaPhragmenElection` to `PhragmenElection`"); - migration::move_pallet(b"DarwiniaPhragmenElection", b"PhragmenElection"); - - log::info!( - "Moving storage `Instance0DarwiniaRelayerGame` to `Instance1DarwiniaRelayerGame`" - ); - migration::move_pallet( - b"Instance0DarwiniaRelayerGame", - b"Instance1DarwiniaRelayerGame", - ); - - log::info!("Moving storage `Instance0DarwiniaRelayAuthorities` to `Instance1DarwiniaRelayAuthorities`"); - migration::move_pallet( - b"Instance0DarwiniaRelayAuthorities", - b"Instance1DarwiniaRelayAuthorities", - ); - - RuntimeBlockWeights::get().max_block + 0 } } diff --git a/runtime/darwinia/src/pallets/election_provider_multi_phase.rs b/runtime/darwinia/src/pallets/election_provider_multi_phase.rs index 6645e7df0..f5e1e3105 100644 --- a/runtime/darwinia/src/pallets/election_provider_multi_phase.rs +++ b/runtime/darwinia/src/pallets/election_provider_multi_phase.rs @@ -28,6 +28,7 @@ frame_support::parameter_types! { // miner configs pub NposSolutionPriority: TransactionPriority = Perbill::from_percent(90) * TransactionPriority::max_value(); pub const MinerMaxIterations: u32 = 10; + pub const OffchainRepeat: BlockNumber = 5; } impl Config for Runtime { @@ -38,7 +39,8 @@ impl Config for Runtime { type SolutionImprovementThreshold = SolutionImprovementThreshold; type MinerMaxIterations = MinerMaxIterations; type MinerMaxWeight = OffchainSolutionWeightLimit; - type MinerMaxLength = OffchainSolutionLengthLimit; + type MinerMaxLength = OffchainSolutionLengthLimit; // For now use the one from staking. + type OffchainRepeat = OffchainRepeat; type MinerTxPriority = NposSolutionPriority; type DataProvider = Staking; type OnChainAccuracy = Perbill; diff --git a/runtime/darwinia/src/pallets/offences.rs b/runtime/darwinia/src/pallets/offences.rs index 616cea9b1..42b778cf0 100644 --- a/runtime/darwinia/src/pallets/offences.rs +++ b/runtime/darwinia/src/pallets/offences.rs @@ -1,19 +1,11 @@ // --- substrate --- -use frame_support::weights::Weight; use pallet_offences::Config; use pallet_session::historical::IdentificationTuple; -use sp_runtime::Perbill; // --- darwinia --- use crate::*; -frame_support::parameter_types! { - pub OffencesWeightSoftLimit: Weight = Perbill::from_percent(60) - * RuntimeBlockWeights::get().max_block; -} - impl Config for Runtime { type Event = Event; type IdentificationTuple = IdentificationTuple; type OnOffenceHandler = Staking; - type WeightSoftLimit = OffencesWeightSoftLimit; }