git.delta.rocks / unique-network / refs/commits / 0cdaf2ed2223

difftreelog

Benchmark

str-mv2020-10-20parent: #11a433f.patch.diff
in: master

11 files changed

modifiedCargo.lockdiffbeforeafterboth
16source = "registry+https://github.com/rust-lang/crates.io-index"16source = "registry+https://github.com/rust-lang/crates.io-index"
17checksum = "1b6a2d3371669ab3ca9797670853d61402b03d0b4b9ebf33d677dfa720203072"17checksum = "1b6a2d3371669ab3ca9797670853d61402b03d0b4b9ebf33d677dfa720203072"
18dependencies = [18dependencies = [
19 "gimli",19 "gimli 0.22.0",
20]20]
2121
22[[package]]22[[package]]
361 "cfg-if 1.0.0",361 "cfg-if 1.0.0",
362 "libc",362 "libc",
363 "miniz_oxide",363 "miniz_oxide",
364 "object",364 "object 0.21.1",
365 "rustc-demangle",365 "rustc-demangle",
366]366]
367367
383source = "registry+https://github.com/rust-lang/crates.io-index"383source = "registry+https://github.com/rust-lang/crates.io-index"
384checksum = "3441f0f7b02788e948e47f457ca01f1d7e6d92c693bc132c22b087d3141c03ff"384checksum = "3441f0f7b02788e948e47f457ca01f1d7e6d92c693bc132c22b087d3141c03ff"
385
386[[package]]
387name = "bincode"
388version = "1.3.1"
389source = "registry+https://github.com/rust-lang/crates.io-index"
390checksum = "f30d3a39baa26f9651f17b375061f3233dde33424a8b72b0dbe93a68a0bc896d"
391dependencies = [
392 "byteorder 1.3.4",
393 "serde",
394]
385395
386[[package]]396[[package]]
387name = "bindgen"397name = "bindgen"
790source = "registry+https://github.com/rust-lang/crates.io-index"800source = "registry+https://github.com/rust-lang/crates.io-index"
791checksum = "8aebca1129a03dc6dc2b127edd729435bbc4a37e1d5f4d7513165089ceb02634"801checksum = "8aebca1129a03dc6dc2b127edd729435bbc4a37e1d5f4d7513165089ceb02634"
802
803[[package]]
804name = "cranelift-bforest"
805version = "0.66.0"
806source = "registry+https://github.com/rust-lang/crates.io-index"
807checksum = "8dcc286b052ee24a1e5a222e7c1125e6010ad35b0f248709b9b3737a8fedcfdf"
808dependencies = [
809 "cranelift-entity",
810]
811
812[[package]]
813name = "cranelift-codegen"
814version = "0.66.0"
815source = "registry+https://github.com/rust-lang/crates.io-index"
816checksum = "9d9badfe36176cb653506091693bc2bb1970c9bddfcd6ec7fac404f7eaec6f38"
817dependencies = [
818 "byteorder 1.3.4",
819 "cranelift-bforest",
820 "cranelift-codegen-meta",
821 "cranelift-codegen-shared",
822 "cranelift-entity",
823 "gimli 0.21.0",
824 "log",
825 "regalloc",
826 "serde",
827 "smallvec 1.4.2",
828 "target-lexicon",
829 "thiserror",
830]
831
832[[package]]
833name = "cranelift-codegen-meta"
834version = "0.66.0"
835source = "registry+https://github.com/rust-lang/crates.io-index"
836checksum = "3c3f460031861e4f4ad510be62b2ae50bba6cc886b598a36f9c0a970feab9598"
837dependencies = [
838 "cranelift-codegen-shared",
839 "cranelift-entity",
840]
841
842[[package]]
843name = "cranelift-codegen-shared"
844version = "0.66.0"
845source = "registry+https://github.com/rust-lang/crates.io-index"
846checksum = "76ad12409e922e7697cd0bdc7dc26992f64a77c31880dfe5e3c7722f4710206d"
847
848[[package]]
849name = "cranelift-entity"
850version = "0.66.0"
851source = "registry+https://github.com/rust-lang/crates.io-index"
852checksum = "d97cdc58972ea065d107872cfb9079f4c92ade78a8af85aaff519a65b5d13f71"
853dependencies = [
854 "serde",
855]
856
857[[package]]
858name = "cranelift-frontend"
859version = "0.66.0"
860source = "registry+https://github.com/rust-lang/crates.io-index"
861checksum = "2ef419efb4f94ecc02e5d9fbcc910d2bb7f0040e2de570e63a454f883bc891d6"
862dependencies = [
863 "cranelift-codegen",
864 "log",
865 "smallvec 1.4.2",
866 "target-lexicon",
867]
868
869[[package]]
870name = "cranelift-native"
871version = "0.66.0"
872source = "registry+https://github.com/rust-lang/crates.io-index"
873checksum = "6e69d44d59826eef6794066ac2c0f4ad3975f02d97030c60dbc04e3886adf36e"
874dependencies = [
875 "cranelift-codegen",
876 "raw-cpuid",
877 "target-lexicon",
878]
879
880[[package]]
881name = "cranelift-wasm"
882version = "0.66.0"
883source = "registry+https://github.com/rust-lang/crates.io-index"
884checksum = "979df666b1304624abe99738e9e0e7c7479ee5523ba4b8b237df9ff49996acbb"
885dependencies = [
886 "cranelift-codegen",
887 "cranelift-entity",
888 "cranelift-frontend",
889 "log",
890 "serde",
891 "thiserror",
892 "wasmparser 0.59.0",
893]
792894
793[[package]]895[[package]]
794name = "crc32fast"896name = "crc32fast"
1078 "serde",1180 "serde",
1079]1181]
1182
1183[[package]]
1184name = "errno"
1185version = "0.2.6"
1186source = "registry+https://github.com/rust-lang/crates.io-index"
1187checksum = "6eab5ee3df98a279d9b316b1af6ac95422127b1290317e6d18c1743c99418b01"
1188dependencies = [
1189 "errno-dragonfly",
1190 "libc",
1191 "winapi 0.3.9",
1192]
1193
1194[[package]]
1195name = "errno-dragonfly"
1196version = "0.1.1"
1197source = "registry+https://github.com/rust-lang/crates.io-index"
1198checksum = "14ca354e36190500e1e1fb267c647932382b54053c50b14970856c0b00a35067"
1199dependencies = [
1200 "gcc",
1201 "libc",
1202]
10801203
1081[[package]]1204[[package]]
1082name = "event-listener"1205name = "event-listener"
1121source = "registry+https://github.com/rust-lang/crates.io-index"1244source = "registry+https://github.com/rust-lang/crates.io-index"
1122checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed"1245checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed"
1246
1247[[package]]
1248name = "fallible-iterator"
1249version = "0.2.0"
1250source = "registry+https://github.com/rust-lang/crates.io-index"
1251checksum = "4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7"
11231252
1124[[package]]1253[[package]]
1125name = "fastrand"1254name = "fastrand"
1139 "libc",1268 "libc",
1140]1269]
1270
1271[[package]]
1272name = "file-per-thread-logger"
1273version = "0.1.4"
1274source = "registry+https://github.com/rust-lang/crates.io-index"
1275checksum = "4fdbe0d94371f9ce939b555dd342d0686cc4c0cadbcd4b61d70af5ff97eb4126"
1276dependencies = [
1277 "env_logger",
1278 "log",
1279]
11411280
1142[[package]]1281[[package]]
1143name = "finality-grandpa"1282name = "finality-grandpa"
1217 "sp-storage",1356 "sp-storage",
1218]1357]
1358
1359[[package]]
1360name = "frame-benchmarking-cli"
1361version = "2.0.0"
1362source = "git+https://github.com/usetech-llc/substrate.git?branch=v2.0.0_release#a200cdb93c6af5763b9c7bf313fa708764ac88ca"
1363dependencies = [
1364 "frame-benchmarking",
1365 "parity-scale-codec",
1366 "sc-cli",
1367 "sc-client-db",
1368 "sc-executor",
1369 "sc-service",
1370 "sp-core",
1371 "sp-externalities",
1372 "sp-runtime",
1373 "sp-state-machine",
1374 "structopt",
1375]
12191376
1220[[package]]1377[[package]]
1221name = "frame-executive"1378name = "frame-executive"
1318 "sp-version",1475 "sp-version",
1319]1476]
1477
1478[[package]]
1479name = "frame-system-benchmarking"
1480version = "2.0.0"
1481source = "git+https://github.com/usetech-llc/substrate.git?branch=v2.0.0_release#a200cdb93c6af5763b9c7bf313fa708764ac88ca"
1482dependencies = [
1483 "frame-benchmarking",
1484 "frame-support",
1485 "frame-system",
1486 "parity-scale-codec",
1487 "sp-core",
1488 "sp-runtime",
1489 "sp-std",
1490]
13201491
1321[[package]]1492[[package]]
1322name = "frame-system-rpc-runtime-api"1493name = "frame-system-rpc-runtime-api"
1634 "polyval",1805 "polyval",
1635]1806]
1807
1808[[package]]
1809name = "gimli"
1810version = "0.21.0"
1811source = "registry+https://github.com/rust-lang/crates.io-index"
1812checksum = "bcc8e0c9bce37868955864dbecd2b1ab2bdf967e6f28066d65aaac620444b65c"
1813dependencies = [
1814 "fallible-iterator",
1815 "indexmap",
1816 "stable_deref_trait",
1817]
16361818
1637[[package]]1819[[package]]
1638name = "gimli"1820name = "gimli"
2013dependencies = [2195dependencies = [
2014 "autocfg 1.0.1",2196 "autocfg 1.0.1",
2015 "hashbrown 0.9.1",2197 "hashbrown 0.9.1",
2198 "serde",
2016]2199]
20172200
2018[[package]]2201[[package]]
2073 "either",2256 "either",
2074]2257]
2258
2259[[package]]
2260name = "itertools"
2261version = "0.9.0"
2262source = "registry+https://github.com/rust-lang/crates.io-index"
2263checksum = "284f18f85651fe11e8a991b2adb42cb078325c996ed026d994719efcfca1d54b"
2264dependencies = [
2265 "either",
2266]
20752267
2076[[package]]2268[[package]]
2077name = "itoa"2269name = "itoa"
2295source = "registry+https://github.com/rust-lang/crates.io-index"2487source = "registry+https://github.com/rust-lang/crates.io-index"
2296checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55"2488checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55"
2489
2490[[package]]
2491name = "leb128"
2492version = "0.2.4"
2493source = "registry+https://github.com/rust-lang/crates.io-index"
2494checksum = "3576a87f2ba00f6f106fdfcd16db1d698d648a26ad8e0573cad8537c3c362d2a"
22972495
2298[[package]]2496[[package]]
2299name = "libc"2497name = "libc"
2851source = "registry+https://github.com/rust-lang/crates.io-index"3049source = "registry+https://github.com/rust-lang/crates.io-index"
2852checksum = "adb241df5c4caeb888755363fc95f8a896618dc0d435e9e775f7930cb099beab"3050checksum = "adb241df5c4caeb888755363fc95f8a896618dc0d435e9e775f7930cb099beab"
3051
3052[[package]]
3053name = "mach"
3054version = "0.3.2"
3055source = "registry+https://github.com/rust-lang/crates.io-index"
3056checksum = "b823e83b2affd8f40a9ee8c29dbc56404c1e34cd2710921f2801e2cf29527afa"
3057dependencies = [
3058 "libc",
3059]
28533060
2854[[package]]3061[[package]]
2855name = "matchers"3062name = "matchers"
3041 "winapi 0.3.9",3248 "winapi 0.3.9",
3042]3249]
3250
3251[[package]]
3252name = "more-asserts"
3253version = "0.2.1"
3254source = "registry+https://github.com/rust-lang/crates.io-index"
3255checksum = "0debeb9fcf88823ea64d64e4a815ab1643f33127d995978e099942ce38f25238"
30433256
3044[[package]]3257[[package]]
3045name = "multihash"3258name = "multihash"
3127name = "nft"3340name = "nft"
3128version = "2.0.0"3341version = "2.0.0"
3129dependencies = [3342dependencies = [
3343 "frame-benchmarking",
3344 "frame-benchmarking-cli",
3130 "futures 0.3.6",3345 "futures 0.3.6",
3131 "jsonrpc-core",3346 "jsonrpc-core",
3132 "log",3347 "log",
3165name = "nft-runtime"3380name = "nft-runtime"
3166version = "2.0.0"3381version = "2.0.0"
3167dependencies = [3382dependencies = [
3383 "frame-benchmarking",
3168 "frame-executive",3384 "frame-executive",
3169 "frame-support",3385 "frame-support",
3170 "frame-system",3386 "frame-system",
3387 "frame-system-benchmarking",
3171 "frame-system-rpc-runtime-api",3388 "frame-system-rpc-runtime-api",
3389 "hex-literal",
3172 "pallet-aura",3390 "pallet-aura",
3173 "pallet-balances",3391 "pallet-balances",
3174 "pallet-contracts",3392 "pallet-contracts",
3295 "libc",3513 "libc",
3296]3514]
3515
3516[[package]]
3517name = "object"
3518version = "0.19.0"
3519source = "registry+https://github.com/rust-lang/crates.io-index"
3520checksum = "9cbca9424c482ee628fa549d9c812e2cd22f1180b9222c9200fdfa6eb31aecb2"
3521
3522[[package]]
3523name = "object"
3524version = "0.20.0"
3525source = "registry+https://github.com/rust-lang/crates.io-index"
3526checksum = "1ab52be62400ca80aa00285d25253d7f7c437b7375c4de678f5405d3afe82ca5"
3527dependencies = [
3528 "crc32fast",
3529 "indexmap",
3530 "wasmparser 0.57.0",
3531]
32973532
3298[[package]]3533[[package]]
3299name = "object"3534name = "object"
3569 "parity-scale-codec",3804 "parity-scale-codec",
3570 "serde",3805 "serde",
3571 "sp-inherents",3806 "sp-inherents",
3807 "sp-io",
3572 "sp-runtime",3808 "sp-runtime",
3573 "sp-std",3809 "sp-std",
3574 "sp-timestamp",3810 "sp-timestamp",
4098dependencies = [4334dependencies = [
4099 "bytes 0.5.6",4335 "bytes 0.5.6",
4100 "heck",4336 "heck",
4101 "itertools",4337 "itertools 0.8.2",
4102 "log",4338 "log",
4103 "multimap",4339 "multimap",
4104 "petgraph",4340 "petgraph",
4115checksum = "537aa19b95acde10a12fec4301466386f757403de4cd4e5b4fa78fb5ecb18f72"4351checksum = "537aa19b95acde10a12fec4301466386f757403de4cd4e5b4fa78fb5ecb18f72"
4116dependencies = [4352dependencies = [
4117 "anyhow",4353 "anyhow",
4118 "itertools",4354 "itertools 0.8.2",
4119 "proc-macro2",4355 "proc-macro2",
4120 "quote",4356 "quote",
4121 "syn",4357 "syn",
4367 "rand_core 0.3.1",4603 "rand_core 0.3.1",
4368]4604]
4605
4606[[package]]
4607name = "raw-cpuid"
4608version = "7.0.3"
4609source = "registry+https://github.com/rust-lang/crates.io-index"
4610checksum = "b4a349ca83373cfa5d6dbb66fd76e58b2cca08da71a5f6400de0a0a6a9bceeaf"
4611dependencies = [
4612 "bitflags",
4613 "cc",
4614 "rustc_version",
4615]
43694616
4370[[package]]4617[[package]]
4371name = "rawpointer"4618name = "rawpointer"
4444 "syn",4691 "syn",
4445]4692]
4693
4694[[package]]
4695name = "regalloc"
4696version = "0.0.27"
4697source = "registry+https://github.com/rust-lang/crates.io-index"
4698checksum = "b9ba8aaf5fe7cf307c6dbdaeed85478961d29e25e3bee5169e11b92fa9f027a8"
4699dependencies = [
4700 "log",
4701 "rustc-hash",
4702 "smallvec 1.4.2",
4703]
44464704
4447[[package]]4705[[package]]
4448name = "regex"4706name = "regex"
4472source = "registry+https://github.com/rust-lang/crates.io-index"4730source = "registry+https://github.com/rust-lang/crates.io-index"
4473checksum = "8cab7a364d15cde1e505267766a2d3c4e22a843e1a601f0fa7564c0f82ced11c"4731checksum = "8cab7a364d15cde1e505267766a2d3c4e22a843e1a601f0fa7564c0f82ced11c"
4732
4733[[package]]
4734name = "region"
4735version = "2.2.0"
4736source = "registry+https://github.com/rust-lang/crates.io-index"
4737checksum = "877e54ea2adcd70d80e9179344c97f93ef0dffd6b03e1f4529e6e83ab2fa9ae0"
4738dependencies = [
4739 "bitflags",
4740 "libc",
4741 "mach",
4742 "winapi 0.3.9",
4743]
44744744
4475[[package]]4745[[package]]
4476name = "remove_dir_all"4746name = "remove_dir_all"
4895 "parking_lot 0.10.2",5165 "parking_lot 0.10.2",
4896 "sc-executor-common",5166 "sc-executor-common",
4897 "sc-executor-wasmi",5167 "sc-executor-wasmi",
5168 "sc-executor-wasmtime",
4898 "sp-api",5169 "sp-api",
4899 "sp-core",5170 "sp-core",
4900 "sp-externalities",5171 "sp-externalities",
4940 "wasmi",5211 "wasmi",
4941]5212]
5213
5214[[package]]
5215name = "sc-executor-wasmtime"
5216version = "0.8.0"
5217source = "git+https://github.com/usetech-llc/substrate.git?branch=v2.0.0_release#a200cdb93c6af5763b9c7bf313fa708764ac88ca"
5218dependencies = [
5219 "log",
5220 "parity-scale-codec",
5221 "parity-wasm",
5222 "pwasm-utils",
5223 "sc-executor-common",
5224 "scoped-tls",
5225 "sp-allocator",
5226 "sp-core",
5227 "sp-runtime-interface",
5228 "sp-wasm-interface",
5229 "wasmtime",
5230]
49425231
4943[[package]]5232[[package]]
4944name = "sc-finality-grandpa"5233name = "sc-finality-grandpa"
5413 "zeroize",5702 "zeroize",
5414]5703]
5704
5705[[package]]
5706name = "scoped-tls"
5707version = "1.0.0"
5708source = "registry+https://github.com/rust-lang/crates.io-index"
5709checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2"
54155710
5416[[package]]5711[[package]]
5417name = "scopeguard"5712name = "scopeguard"
5425source = "registry+https://github.com/rust-lang/crates.io-index"5720source = "registry+https://github.com/rust-lang/crates.io-index"
5426checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd"5721checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd"
5722
5723[[package]]
5724name = "scroll"
5725version = "0.10.2"
5726source = "registry+https://github.com/rust-lang/crates.io-index"
5727checksum = "fda28d4b4830b807a8b43f7b0e6b5df875311b3e7621d84577188c175b6ec1ec"
5728dependencies = [
5729 "scroll_derive",
5730]
5731
5732[[package]]
5733name = "scroll_derive"
5734version = "0.10.3"
5735source = "registry+https://github.com/rust-lang/crates.io-index"
5736checksum = "6dfde5d1531034db129e95c76ac857e2baecea3443579d493d02224950b0fb6d"
5737dependencies = [
5738 "proc-macro2",
5739 "quote",
5740 "syn",
5741]
54275742
5428[[package]]5743[[package]]
5429name = "sct"5744name = "sct"
6458[[package]]6773[[package]]
6459name = "substrate-wasm-builder-runner"6774name = "substrate-wasm-builder-runner"
6460version = "1.0.6"6775version = "1.0.6"
6461source = "git+https://github.com/usetech-llc/substrate.git?branch=v2.0.0_release#a200cdb93c6af5763b9c7bf313fa708764ac88ca"6776source = "registry+https://github.com/rust-lang/crates.io-index"
6777checksum = "d2a965994514ab35d3893e9260245f2947fd1981cdd4fffd2c6e6d1a9ce02e6a"
64626778
6463[[package]]6779[[package]]
6464name = "subtle"6780name = "subtle"
6501source = "registry+https://github.com/rust-lang/crates.io-index"6817source = "registry+https://github.com/rust-lang/crates.io-index"
6502checksum = "f764005d11ee5f36500a149ace24e00e3da98b0158b3e2d53a7495660d3f4d60"6818checksum = "f764005d11ee5f36500a149ace24e00e3da98b0158b3e2d53a7495660d3f4d60"
6819
6820[[package]]
6821name = "target-lexicon"
6822version = "0.10.0"
6823source = "registry+https://github.com/rust-lang/crates.io-index"
6824checksum = "ab0e7238dcc7b40a7be719a25365910f6807bd864f4cce6b2e6b873658e2b19d"
65036825
6504[[package]]6826[[package]]
6505name = "tempfile"6827name = "tempfile"
7324 "parity-wasm",7646 "parity-wasm",
7325]7647]
7648
7649[[package]]
7650name = "wasmparser"
7651version = "0.57.0"
7652source = "registry+https://github.com/rust-lang/crates.io-index"
7653checksum = "32fddd575d477c6e9702484139cf9f23dcd554b06d185ed0f56c857dd3a47aa6"
7654
7655[[package]]
7656name = "wasmparser"
7657version = "0.59.0"
7658source = "registry+https://github.com/rust-lang/crates.io-index"
7659checksum = "a950e6a618f62147fd514ff445b2a0b53120d382751960797f85f058c7eda9b9"
7660
7661[[package]]
7662name = "wasmtime"
7663version = "0.19.0"
7664source = "registry+https://github.com/rust-lang/crates.io-index"
7665checksum = "1cd3c4f449382779ef6e0a7c3ec6752ae614e20a42e4100000c3efdc973100e2"
7666dependencies = [
7667 "anyhow",
7668 "backtrace",
7669 "cfg-if 0.1.10",
7670 "lazy_static",
7671 "libc",
7672 "log",
7673 "region",
7674 "rustc-demangle",
7675 "smallvec 1.4.2",
7676 "target-lexicon",
7677 "wasmparser 0.59.0",
7678 "wasmtime-environ",
7679 "wasmtime-jit",
7680 "wasmtime-profiling",
7681 "wasmtime-runtime",
7682 "wat",
7683 "winapi 0.3.9",
7684]
7685
7686[[package]]
7687name = "wasmtime-debug"
7688version = "0.19.0"
7689source = "registry+https://github.com/rust-lang/crates.io-index"
7690checksum = "6e634af9067a3af6cf2c7d33dc3b84767ddaf5d010ba68e80eecbcea73d4a349"
7691dependencies = [
7692 "anyhow",
7693 "gimli 0.21.0",
7694 "more-asserts",
7695 "object 0.20.0",
7696 "target-lexicon",
7697 "thiserror",
7698 "wasmparser 0.59.0",
7699 "wasmtime-environ",
7700]
7701
7702[[package]]
7703name = "wasmtime-environ"
7704version = "0.19.0"
7705source = "registry+https://github.com/rust-lang/crates.io-index"
7706checksum = "08f85619a94ee4034bd5bb87fc3dcf71fd2237b81c840809da1201061eec9ab3"
7707dependencies = [
7708 "anyhow",
7709 "base64 0.12.3",
7710 "bincode",
7711 "cfg-if 0.1.10",
7712 "cranelift-codegen",
7713 "cranelift-entity",
7714 "cranelift-frontend",
7715 "cranelift-wasm",
7716 "directories",
7717 "errno",
7718 "file-per-thread-logger",
7719 "indexmap",
7720 "libc",
7721 "log",
7722 "more-asserts",
7723 "rayon",
7724 "serde",
7725 "sha2 0.8.2",
7726 "thiserror",
7727 "toml",
7728 "wasmparser 0.59.0",
7729 "winapi 0.3.9",
7730 "zstd",
7731]
7732
7733[[package]]
7734name = "wasmtime-jit"
7735version = "0.19.0"
7736source = "registry+https://github.com/rust-lang/crates.io-index"
7737checksum = "e914c013c7a9f15f4e429d5431f2830fb8adb56e40567661b69c5ec1d645be23"
7738dependencies = [
7739 "anyhow",
7740 "cfg-if 0.1.10",
7741 "cranelift-codegen",
7742 "cranelift-entity",
7743 "cranelift-frontend",
7744 "cranelift-native",
7745 "cranelift-wasm",
7746 "gimli 0.21.0",
7747 "log",
7748 "more-asserts",
7749 "object 0.20.0",
7750 "region",
7751 "target-lexicon",
7752 "thiserror",
7753 "wasmparser 0.59.0",
7754 "wasmtime-debug",
7755 "wasmtime-environ",
7756 "wasmtime-obj",
7757 "wasmtime-profiling",
7758 "wasmtime-runtime",
7759 "winapi 0.3.9",
7760]
7761
7762[[package]]
7763name = "wasmtime-obj"
7764version = "0.19.0"
7765source = "registry+https://github.com/rust-lang/crates.io-index"
7766checksum = "e81d8e02e9bc9fe2da9b6d48bbc217f96e089f7df613f11a28a3958abc44641e"
7767dependencies = [
7768 "anyhow",
7769 "more-asserts",
7770 "object 0.20.0",
7771 "target-lexicon",
7772 "wasmtime-debug",
7773 "wasmtime-environ",
7774]
7775
7776[[package]]
7777name = "wasmtime-profiling"
7778version = "0.19.0"
7779source = "registry+https://github.com/rust-lang/crates.io-index"
7780checksum = "1e8d4d1af8dd5f7096cfcc89dd668d358e52980c38cce199643372ffd6590e27"
7781dependencies = [
7782 "anyhow",
7783 "cfg-if 0.1.10",
7784 "gimli 0.21.0",
7785 "lazy_static",
7786 "libc",
7787 "object 0.19.0",
7788 "scroll",
7789 "serde",
7790 "target-lexicon",
7791 "wasmtime-environ",
7792 "wasmtime-runtime",
7793]
7794
7795[[package]]
7796name = "wasmtime-runtime"
7797version = "0.19.0"
7798source = "registry+https://github.com/rust-lang/crates.io-index"
7799checksum = "3a25f140bbbaadb07c531cba99ce1a966dba216138dc1b2a0ddecec851a01a93"
7800dependencies = [
7801 "backtrace",
7802 "cc",
7803 "cfg-if 0.1.10",
7804 "indexmap",
7805 "lazy_static",
7806 "libc",
7807 "log",
7808 "memoffset",
7809 "more-asserts",
7810 "region",
7811 "thiserror",
7812 "wasmtime-environ",
7813 "winapi 0.3.9",
7814]
7815
7816[[package]]
7817name = "wast"
7818version = "26.0.0"
7819source = "registry+https://github.com/rust-lang/crates.io-index"
7820checksum = "d54b3678343bfdf1768c16308a4b53823b70f7bb148d3d38225123d4306ec731"
7821dependencies = [
7822 "leb128",
7823]
7824
7825[[package]]
7826name = "wat"
7827version = "1.0.27"
7828source = "registry+https://github.com/rust-lang/crates.io-index"
7829checksum = "26b2dccbce4d0e14875091846e110a2369267b18ddd0d6423479b88dad914d71"
7830dependencies = [
7831 "wast",
7832]
73267833
7327[[package]]7834[[package]]
7328name = "web-sys"7835name = "web-sys"
7490 "synstructure",7997 "synstructure",
7491]7998]
7999
8000[[package]]
8001name = "zstd"
8002version = "0.5.3+zstd.1.4.5"
8003source = "registry+https://github.com/rust-lang/crates.io-index"
8004checksum = "01b32eaf771efa709e8308605bbf9319bf485dc1503179ec0469b611937c0cd8"
8005dependencies = [
8006 "zstd-safe",
8007]
8008
8009[[package]]
8010name = "zstd-safe"
8011version = "2.0.5+zstd.1.4.5"
8012source = "registry+https://github.com/rust-lang/crates.io-index"
8013checksum = "1cfb642e0d27f64729a639c52db457e0ae906e7bc6f5fe8f5c453230400f1055"
8014dependencies = [
8015 "libc",
8016 "zstd-sys",
8017]
8018
8019[[package]]
8020name = "zstd-sys"
8021version = "1.4.17+zstd.1.4.5"
8022source = "registry+https://github.com/rust-lang/crates.io-index"
8023checksum = "b89249644df056b522696b1bb9e7c18c87e8ffa3e2f0dc3b0155875d6498f01b"
8024dependencies = [
8025 "cc",
8026 "glob",
8027 "itertools 0.9.0",
8028 "libc",
8029]
74928030
modifiednode/Cargo.tomldiffbeforeafterboth
27structopt = '0.3.8'27structopt = '0.3.8'
28jsonrpc-core = '15.0.0'28jsonrpc-core = '15.0.0'
2929
30[dependencies.nft-runtime]30# Substrate dependencies
31path = '../runtime'31nft-runtime = { path = '../runtime', version = '2.0.0' }
32version = '2.0.0'32frame-benchmarking = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
3333frame-benchmarking-cli = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
34[dependencies.sc-basic-authorship]34pallet-transaction-payment-rpc = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
35git = 'https://github.com/usetech-llc/substrate.git'35sc-basic-authorship = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
36branch = 'v2.0.0_release'36sc-cli = { features = ['wasmtime'], version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
37version = '0.8.0'37sc-client-api = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
3838sc-consensus = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
39[dependencies.sc-cli]39sc-consensus-aura = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
40git = 'https://github.com/usetech-llc/substrate.git'40sc-executor = { features = ['wasmtime'], version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
41branch = 'v2.0.0_release'41sc-finality-grandpa = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
42version = '0.8.0'42sc-rpc = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
4343sc-rpc-api = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
44[dependencies.sc-client-api]44sc-service = { features = ['wasmtime'], version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
45git = 'https://github.com/usetech-llc/substrate.git'45sc-transaction-pool = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
46branch = 'v2.0.0_release'46sp-api = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
47version = '2.0.0'47sp-block-builder = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
4848sp-blockchain = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
49[dependencies.sc-consensus]49sp-consensus = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
50git = 'https://github.com/usetech-llc/substrate.git'50sp-consensus-aura = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
51branch = 'v2.0.0_release'51sp-core = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
52version = '0.8.0'52sp-finality-grandpa = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
5353sp-inherents = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
54[dependencies.pallet-contracts-rpc]54sp-runtime = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
55git = 'https://github.com/usetech-llc/substrate.git'55sp-transaction-pool = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
56version = '0.8.0'56sc-network = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
57branch = 'v2.0.0_release'57substrate-frame-rpc-system = {version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
5858pallet-contracts-rpc = {version = '0.8.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release'}
59[dependencies.sc-rpc]
60git = 'https://github.com/usetech-llc/substrate.git'
61version = '2.0.0'
62branch = 'v2.0.0_release'
63
64[dependencies.sp-api]
65git = 'https://github.com/usetech-llc/substrate.git'
66version = '2.0.0'
67branch = 'v2.0.0_release'
68
69[dependencies.sp-blockchain]
70git = 'https://github.com/usetech-llc/substrate.git'
71version = '2.0.0'
72branch = 'v2.0.0_release'
73
74[dependencies.sp-block-builder]
75git = 'https://github.com/usetech-llc/substrate.git'
76version = '2.0.0'
77branch = 'v2.0.0_release'
78
79[dependencies.sc-rpc-api]
80git = 'https://github.com/usetech-llc/substrate.git'
81version = '0.8.0'
82branch = 'v2.0.0_release'
83
84[dependencies.substrate-frame-rpc-system]
85git = 'https://github.com/usetech-llc/substrate.git'
86version = '2.0.0'
87branch = 'v2.0.0_release'
88
89[dependencies.pallet-transaction-payment-rpc]
90git = 'https://github.com/usetech-llc/substrate.git'
91version = '2.0.0'
92branch = 'v2.0.0_release'
93
94[dependencies.sc-consensus-aura]
95git = 'https://github.com/usetech-llc/substrate.git'
96branch = 'v2.0.0_release'
97version = '0.8.0'
98
99[dependencies.sc-executor]
100git = 'https://github.com/usetech-llc/substrate.git'
101branch = 'v2.0.0_release'
102version = '0.8.0'
103
104[dependencies.sc-finality-grandpa]
105git = 'https://github.com/usetech-llc/substrate.git'
106branch = 'v2.0.0_release'
107version = '0.8.0'
108
109[dependencies.sc-network]
110git = 'https://github.com/usetech-llc/substrate.git'
111branch = 'v2.0.0_release'
112version = '0.8.0'
113
114[dependencies.sc-service]
115git = 'https://github.com/usetech-llc/substrate.git'
116branch = 'v2.0.0_release'
117version = '0.8.0'
118
119[dependencies.sc-transaction-pool]
120git = 'https://github.com/usetech-llc/substrate.git'
121branch = 'v2.0.0_release'
122version = '2.0.0'
123
124[dependencies.sp-consensus]
125git = 'https://github.com/usetech-llc/substrate.git'
126branch = 'v2.0.0_release'
127version = '0.8.0'
128
129[dependencies.sp-consensus-aura]
130git = 'https://github.com/usetech-llc/substrate.git'
131branch = 'v2.0.0_release'
132version = '0.8.0'
133
134[dependencies.sp-core]
135git = 'https://github.com/usetech-llc/substrate.git'
136branch = 'v2.0.0_release'
137version = '2.0.0'
138
139[dependencies.sp-finality-grandpa]
140git = 'https://github.com/usetech-llc/substrate.git'
141branch = 'v2.0.0_release'
142version = '2.0.0'
143
144[dependencies.sp-inherents]
145git = 'https://github.com/usetech-llc/substrate.git'
146branch = 'v2.0.0_release'
147version = '2.0.0'
148
149[dependencies.sp-runtime]
150git = 'https://github.com/usetech-llc/substrate.git'
151branch = 'v2.0.0_release'
152version = '2.0.0'
15359
154[dependencies.sp-transaction-pool]60[features]
155git = 'https://github.com/usetech-llc/substrate.git'61default = []
156branch = 'v2.0.0_release'62runtime-benchmarks = ['nft-runtime/runtime-benchmarks']
157version = '2.0.0'
15863
modifiednode/src/chain_spec.rsdiffbeforeafterboth
39}39}
4040
41pub fn development_config() -> Result<ChainSpec, String> {41pub fn development_config() -> Result<ChainSpec, String> {
42 let wasm_binary = WASM_BINARY.ok_or("Development wasm binary not available".to_string())?;
43
42 Ok(ChainSpec::from_genesis(44 Ok(ChainSpec::from_genesis(
45 // Name
43 "Development",46 "Development",
47 // ID
44 "dev",48 "dev",
45 ChainType::Development,49 ChainType::Development,
46 || {50 move || testnet_genesis(
47 testnet_genesis(51 wasm_binary,
52 // Initial PoA authorities
48 vec![authority_keys_from_seed("Alice")],53 vec![
54 authority_keys_from_seed("Alice"),
55 ],
56 // Sudo account
49 get_account_id_from_seed::<sr25519::Public>("Alice"),57 get_account_id_from_seed::<sr25519::Public>("Alice"),
58 // Pre-funded accounts
50 vec![59 vec![
51 get_account_id_from_seed::<sr25519::Public>("Alice"),60 get_account_id_from_seed::<sr25519::Public>("Alice"),
52 get_account_id_from_seed::<sr25519::Public>("Bob"),61 get_account_id_from_seed::<sr25519::Public>("Bob"),
55 ],64 ],
56 true,65 true,
57 )66 ),
58 },67 // Bootnodes
59 vec![],68 vec![],
69 // Telemetry
60 None,70 None,
71 // Protocol ID
61 None,72 None,
73 // Properties
62 None,74 None,
75 // Extensions
63 None,76 None,
64 ))77 ))
65}78}
6679
67pub fn local_testnet_config() -> Result<ChainSpec, String> {80pub fn local_testnet_config() -> Result<ChainSpec, String> {
81 let wasm_binary = WASM_BINARY.ok_or("Development wasm binary not available".to_string())?;
82
68 Ok(ChainSpec::from_genesis(83 Ok(ChainSpec::from_genesis(
84 // Name
69 "Local Testnet",85 "Local Testnet",
86 // ID
70 "local_testnet",87 "local_testnet",
71 ChainType::Local,88 ChainType::Local,
72 || {89 move || testnet_genesis(
73 testnet_genesis(90 wasm_binary,
91 // Initial PoA authorities
74 vec![92 vec![
75 authority_keys_from_seed("Alice"),93 authority_keys_from_seed("Alice"),
76 authority_keys_from_seed("Bob"),94 authority_keys_from_seed("Bob"),
77 ],95 ],
96 // Sudo account
78 get_account_id_from_seed::<sr25519::Public>("Alice"),97 get_account_id_from_seed::<sr25519::Public>("Alice"),
98 // Pre-funded accounts
79 vec![99 vec![
80 get_account_id_from_seed::<sr25519::Public>("Alice"),100 get_account_id_from_seed::<sr25519::Public>("Alice"),
81 get_account_id_from_seed::<sr25519::Public>("Bob"),101 get_account_id_from_seed::<sr25519::Public>("Bob"),
92 ],112 ],
93 true,113 true,
94 )114 ),
95 },115 // Bootnodes
96 vec![],116 vec![],
117 // Telemetry
97 None,118 None,
119 // Protocol ID
98 None,120 None,
121 // Properties
99 None,122 None,
123 // Extensions
100 None,124 None,
101 ))125 ))
102}126}
103127
104fn testnet_genesis(128fn testnet_genesis(
129 wasm_binary: &[u8],
105 initial_authorities: Vec<(AuraId, GrandpaId)>,130 initial_authorities: Vec<(AuraId, GrandpaId)>,
106 root_key: AccountId,131 root_key: AccountId,
107 endowed_accounts: Vec<AccountId>,132 endowed_accounts: Vec<AccountId>,
108 enable_println: bool,133 enable_println: bool,
109) -> GenesisConfig {134) -> GenesisConfig {
110 GenesisConfig {135 GenesisConfig {
111 system: Some(SystemConfig {136 system: Some(SystemConfig {
112 code: WASM_BINARY.to_vec(),137 code: wasm_binary.to_vec(),
113 changes_trie_config: Default::default(),138 changes_trie_config: Default::default(),
114 }),139 }),
115 balances: Some(BalancesConfig {140 pallet_balances: Some(BalancesConfig {
116 balances: endowed_accounts141 balances: endowed_accounts
117 .iter()142 .iter()
118 .cloned()143 .cloned()
119 .map(|k| (k, 1 << 100))144 .map(|k| (k, 1 << 100))
120 .collect(),145 .collect(),
121 }),146 }),
122 aura: Some(AuraConfig {147 pallet_aura: Some(AuraConfig {
123 authorities: initial_authorities.iter().map(|x| (x.0.clone())).collect(),148 authorities: initial_authorities.iter().map(|x| (x.0.clone())).collect(),
124 }),149 }),
125 grandpa: Some(GrandpaConfig {150 pallet_grandpa: Some(GrandpaConfig {
126 authorities: initial_authorities151 authorities: initial_authorities
127 .iter()152 .iter()
128 .map(|x| (x.1.clone(), 1))153 .map(|x| (x.1.clone(), 1))
129 .collect(),154 .collect(),
130 }),155 }),
131 sudo: Some(SudoConfig { key: root_key }),156 pallet_sudo: Some(SudoConfig { key: root_key }),
132 nft: Some(NftConfig {157 pallet_nft: Some(NftConfig {
133 collection: vec![(158 collection: vec![(
134 1,159 1,
135 CollectionType {160 CollectionType {
160 refungible_sponsor_transfer_timeout: 15,185 refungible_sponsor_transfer_timeout: 15,
161 },186 },
162 }),187 }),
163 contracts: Some(ContractsConfig {188 pallet_contracts: Some(ContractsConfig {
164 current_schedule: ContractsSchedule {189 current_schedule: ContractsSchedule {
165 enable_println,190 enable_println,
166 ..Default::default()191 ..Default::default()
modifiednode/src/cli.rsdiffbeforeafterboth
34 Revert(sc_cli::RevertCmd),34 Revert(sc_cli::RevertCmd),
3535
36 // The custom benchmark subcommmand benchmarking runtime pallets.36 // The custom benchmark subcommmand benchmarking runtime pallets.
37 // #[structopt(name = "benchmark", about = "Benchmark runtime pallets.")]37 #[structopt(name = "benchmark", about = "Benchmark runtime pallets.")]
38 // Benchmark(frame_benchmarking_cli::BenchmarkCmd),38 Benchmark(frame_benchmarking_cli::BenchmarkCmd),
39}39}
4040
modifiednode/src/command.rsdiffbeforeafterboth
19use crate::cli::{Cli, Subcommand};19use crate::cli::{Cli, Subcommand};
20use sc_cli::{SubstrateCli, RuntimeVersion, Role, ChainSpec};20use sc_cli::{SubstrateCli, RuntimeVersion, Role, ChainSpec};
21use sc_service::PartialComponents;21use sc_service::PartialComponents;
22// use nft_runtime::Block;22use nft_runtime::Block;
2323
24impl SubstrateCli for Cli {24impl SubstrateCli for Cli {
25 fn impl_name() -> String {25 fn impl_name() -> String {
114 Ok((cmd.run(client, backend), task_manager))114 Ok((cmd.run(client, backend), task_manager))
115 })115 })
116 },116 },
117 // Some(Subcommand::Benchmark(cmd)) => {117 Some(Subcommand::Benchmark(cmd)) => {
118 // if cfg!(feature = "runtime-benchmarks") {118 if cfg!(feature = "runtime-benchmarks") {
119 // let runner = cli.create_runner(cmd)?;119 let runner = cli.create_runner(cmd)?;
120120
121 // runner.sync_run(|config| cmd.run::<Block, service::Executor>(config))121 runner.sync_run(|config| cmd.run::<Block, service::Executor>(config))
122 // } else {122 } else {
123 // Err("Benchmarking wasn't enabled when building the node. \123 Err("Benchmarking wasn't enabled when building the node. \
124 // You can enable it with `--features runtime-benchmarks`.".into())124 You can enable it with `--features runtime-benchmarks`.".into())
125 // }125 }
126 // },126 },
127 None => {127 None => {
128 let runner = cli.create_runner(&cli.run)?;128 let runner = cli.create_runner(&cli.run)?;
129 runner.run_node_until_exit(|config| match config.role {129 runner.run_node_until_exit(|config| match config.role {
modifiednode/src/service.rsdiffbeforeafterboth
16 pub Executor,16 pub Executor,
17 nft_runtime::api::dispatch,17 nft_runtime::api::dispatch,
18 nft_runtime::native_version,18 nft_runtime::native_version,
19 // frame_benchmarking::benchmarking::HostFunctions,19 frame_benchmarking::benchmarking::HostFunctions,
20);20);
2121
22type FullClient = sc_service::TFullClient<Block, RuntimeApi, Executor>;22type FullClient = sc_service::TFullClient<Block, RuntimeApi, Executor>;
modifiedpallets/nft/Cargo.tomldiffbeforeafterboth
1[package]
2authors = ['Substrate DevHub <https://github.com/substrate-developer-hub>']
3description = 'FRAME pallet nft'
4edition = '2018'
5homepage = 'https://substrate.io'
6license = 'Unlicense'
7name = 'pallet-nft'
8repository = 'https://github.com/substrate-developer-hub/nft/'
9version = '2.0.0'
10
11[package.metadata.docs.rs]
12targets = ['x86_64-unknown-linux-gnu']
13
14# alias "parity-scale-code" to "codec"
1[dependencies.codec]15[dependencies.codec]
2default-features = false16default-features = false
3features = ['derive']17features = ['derive']
4package = 'parity-scale-codec'18package = 'parity-scale-codec'
5version = '1.3.0'19version = '1.3.4'
620
7[dependencies.frame-support]21[dependencies.frame-support]
8default-features = false22default-features = false
27branch = 'v2.0.0_release'42branch = 'v2.0.0_release'
28version = '2.0.0'43version = '2.0.0'
2944
30[dependencies.sp-runtime]45[dev-dependencies.sp-runtime]
31default-features = false46default-features = false
32git = 'https://github.com/usetech-llc/substrate.git'47git = 'https://github.com/usetech-llc/substrate.git'
33branch = 'v2.0.0_release'48branch = 'v2.0.0_release'
51branch = 'v2.0.0_release'66branch = 'v2.0.0_release'
52version = '2.0.0'67version = '2.0.0'
53
54[package]
55authors = ['Substrate DevHub <https://github.com/substrate-developer-hub>']
56description = 'FRAME pallet nft'
57edition = '2018'
58homepage = 'https://substrate.io'
59license = 'Unlicense'
60name = 'pallet-nft'
61repository = 'https://github.com/substrate-developer-hub/nft/'
62version = '2.0.0'
63[package.metadata.docs.rs]
64targets = ['x86_64-unknown-linux-gnu']
6568
66[features]69[features]
67default = ['std']70default = ['std']
70 "serde/std",73 "serde/std",
71 'frame-support/std',74 'frame-support/std',
72 'frame-system/std',75 'frame-system/std',
73 'sp-runtime/std',
74 'sp-std/std',76 'sp-std/std',
75]77]
7678
modifiedpallets/nft/src/mock.rsdiffbeforeafterboth
35}35}
3636
37impl system::Trait for Test {37impl system::Trait for Test {
38 type BaseCallFilter = ();
38 type Origin = Origin;39 type Origin = Origin;
39 type Call = ();40 type Call = ();
40 type Index = u64;41 type Index = u64;
47 type Event = ();48 type Event = ();
48 type BlockHashCount = BlockHashCount;49 type BlockHashCount = BlockHashCount;
49 type MaximumBlockWeight = MaximumBlockWeight;50 type MaximumBlockWeight = MaximumBlockWeight;
50 type MaximumBlockLength = MaximumBlockLength;51 type DbWeight = ();
51 type AvailableBlockRatio = AvailableBlockRatio;52 type BlockExecutionWeight = ();
52 type BaseCallFilter = ();53 type ExtrinsicBaseWeight = ();
53 type DbWeight = RocksDbWeight;54 type MaximumExtrinsicWeight = MaximumBlockWeight;
54 type BlockExecutionWeight = BlockExecutionWeight;55 type MaximumBlockLength = MaximumBlockLength;
55 type ExtrinsicBaseWeight = ExtrinsicBaseWeight;56 type AvailableBlockRatio = AvailableBlockRatio;
56 type MaximumExtrinsicWeight = MaximumExtrinsicWeight;
57 type Version = ();57 type Version = ();
58 type ModuleToIndex = ();58 type PalletInfo = ();
59 type AccountData = ();59 type AccountData = ();
60 type OnNewAccount = ();60 type OnNewAccount = ();
61 type OnKilledAccount = ();61 type OnKilledAccount = ();
62 type SystemWeightInfo = ();
62}63}
63impl Trait for Test {64impl Trait for Test {
64 type Event = ();65 type Event = ();
modifiedruntime/Cargo.tomldiffbeforeafterboth
1[dependencies.aura]
2default-features = false
3git = 'https://github.com/usetech-llc/substrate.git'
4package = 'pallet-aura'
5branch = 'v2.0.0_release'
6version = '2.0.0'
7
8[dependencies.balances]
9default-features = false
10git = 'https://github.com/usetech-llc/substrate.git'
11package = 'pallet-balances'
12branch = 'v2.0.0_release'
13version = '2.0.0'
14
15[dependencies.codec]
16default-features = false
17features = ['derive']
18package = 'parity-scale-codec'
19version = '1.3.0'
20
21[dependencies.contracts]
22git = 'https://github.com/usetech-llc/substrate.git'
23default-features = false
24package = 'pallet-contracts'
25branch = 'v2.0.0_release'
26version = '2.0.0'
27
28[dependencies.contracts-primitives]
29git = 'https://github.com/usetech-llc/substrate.git'
30default-features = false
31package = 'pallet-contracts-primitives'
32branch = 'v2.0.0_release'
33version = '2.0.0'
34
35[dependencies.contracts-rpc-runtime-api]
36git = 'https://github.com/usetech-llc/substrate.git'
37default-features = false
38package = 'pallet-contracts-rpc-runtime-api'
39version = '0.8.0'
40branch = 'v2.0.0_release'
41
42[dependencies.frame-executive]
43default-features = false
44git = 'https://github.com/usetech-llc/substrate.git'
45branch = 'v2.0.0_release'
46version = '2.0.0'
47
48[dependencies.frame-support]
49default-features = false
50git = 'https://github.com/usetech-llc/substrate.git'
51branch = 'v2.0.0_release'
52version = '2.0.0'
53
54[dependencies.grandpa]
55default-features = false
56git = 'https://github.com/usetech-llc/substrate.git'
57package = 'pallet-grandpa'
58branch = 'v2.0.0_release'
59version = '2.0.0'
60
61[dependencies.randomness-collective-flip]
62default-features = false
63git = 'https://github.com/usetech-llc/substrate.git'
64package = 'pallet-randomness-collective-flip'
65branch = 'v2.0.0_release'
66version = '2.0.0'
67
68[dependencies.serde]
69features = ['derive']
70optional = true
71version = '1.0.101'
72
73[dependencies.sp-api]
74default-features = false
75git = 'https://github.com/usetech-llc/substrate.git'
76branch = 'v2.0.0_release'
77version = '2.0.0'
78
79[dependencies.sp-block-builder]
80default-features = false
81git = 'https://github.com/usetech-llc/substrate.git'
82branch = 'v2.0.0_release'
83version = '2.0.0'
84
85[dependencies.sp-consensus-aura]
86default-features = false
87git = 'https://github.com/usetech-llc/substrate.git'
88branch = 'v2.0.0_release'
89version = '0.8.0'
90
91[dependencies.sp-core]
92default-features = false
93git = 'https://github.com/usetech-llc/substrate.git'
94branch = 'v2.0.0_release'
95version = '2.0.0'
96
97[dependencies.sp-inherents]
98default-features = false
99git = 'https://github.com/usetech-llc/substrate.git'
100branch = 'v2.0.0_release'
101version = '2.0.0'
102
103[dependencies.sp-offchain]
104default-features = false
105git = 'https://github.com/usetech-llc/substrate.git'
106branch = 'v2.0.0_release'
107version = '2.0.0'
108
109[dependencies.sp-runtime]
110default-features = false
111git = 'https://github.com/usetech-llc/substrate.git'
112branch = 'v2.0.0_release'
113version = '2.0.0'
114
115[dependencies.sp-session]
116default-features = false
117git = 'https://github.com/usetech-llc/substrate.git'
118branch = 'v2.0.0_release'
119version = '2.0.0'
120
121[dependencies.sp-std]
122default-features = false
123git = 'https://github.com/usetech-llc/substrate.git'
124branch = 'v2.0.0_release'
125version = '2.0.0'
126
127[dependencies.sp-transaction-pool]
128default-features = false
129git = 'https://github.com/usetech-llc/substrate.git'
130branch = 'v2.0.0_release'
131version = '2.0.0'
132
133[dependencies.sp-version]
134default-features = false
135git = 'https://github.com/usetech-llc/substrate.git'
136branch = 'v2.0.0_release'
137version = '2.0.0'
138
139[dependencies.sudo]
140default-features = false
141git = 'https://github.com/usetech-llc/substrate.git'
142package = 'pallet-sudo'
143branch = 'v2.0.0_release'
144version = '2.0.0'
145
146[dependencies.system]
147default-features = false
148git = 'https://github.com/usetech-llc/substrate.git'
149package = 'frame-system'
150branch = 'v2.0.0_release'
151version = '2.0.0'
152
153[dependencies.nft]
154default-features = false
155package = 'pallet-nft'
156path = '../pallets/nft'
157version = '2.0.0'
158
159[dependencies.timestamp]
160default-features = false
161git = 'https://github.com/usetech-llc/substrate.git'
162package = 'pallet-timestamp'
163branch = 'v2.0.0_release'
164version = '2.0.0'
165
166[dependencies.transaction-payment]
167default-features = false
168git = 'https://github.com/usetech-llc/substrate.git'
169package = 'pallet-transaction-payment'
170branch = 'v2.0.0_release'
171version = '2.0.0'
172
173[dependencies.frame-system-rpc-runtime-api]
174default-features = false
175git = 'https://github.com/usetech-llc/substrate.git'
176version = '2.0.0'
177branch = 'v2.0.0_release'
178
179[dependencies.transaction-payment-rpc-runtime-api]
180default-features = false
181git = 'https://github.com/usetech-llc/substrate.git'
182package = 'pallet-transaction-payment-rpc-runtime-api'
183version = '2.0.0'
184branch = 'v2.0.0_release'
185
186[build-dependencies.wasm-builder-runner]
187git = 'https://github.com/usetech-llc/substrate.git'
188package = 'substrate-wasm-builder-runner'
189version = '1.0.5'
190branch = 'v2.0.0_release'
191
192[package]1[package]
193authors = ['Substrate DevHub <https://github.com/substrate-developer-hub>']2authors = ['Substrate DevHub <https://github.com/substrate-developer-hub>']
201[package.metadata.docs.rs]10[package.metadata.docs.rs]
202targets = ['x86_64-unknown-linux-gnu']11targets = ['x86_64-unknown-linux-gnu']
12
13[build-dependencies]
14wasm-builder-runner = { package = 'substrate-wasm-builder-runner', version = '1.0.5' }
15
16# alias "parity-scale-code" to "codec"
17[dependencies.codec]
18default-features = false
19features = ['derive']
20package = 'parity-scale-codec'
21version = '1.3.4'
22
23[dependencies]
24hex-literal = { optional = true, version = '0.3.1' }
25serde = { features = ['derive'], optional = true, version = '1.0.101' }
26
27# local dependencies
28pallet-nft = { path = '../pallets/nft', default-features = false, version = '2.0.0' }
29
30# Substrate dependencies
31frame-benchmarking = { default-features = false, optional = true, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
32frame-executive = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
33frame-support = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
34frame-system = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
35frame-system-benchmarking = { default-features = false, optional = true, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
36frame-system-rpc-runtime-api = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
37pallet-aura = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
38pallet-balances = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
39pallet-contracts = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
40pallet-contracts-primitives = { default-features = false, version = '2.0.0', git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
41pallet-contracts-rpc-runtime-api = { default-features = false, version = '0.8.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
42pallet-grandpa = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
43pallet-randomness-collective-flip = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
44pallet-sudo = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
45pallet-timestamp = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
46pallet-transaction-payment = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
47pallet-transaction-payment-rpc-runtime-api = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
48sp-api = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
49sp-block-builder = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
50sp-consensus-aura = { default-features = false, version = '0.8.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
51sp-core = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
52sp-inherents = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
53sp-offchain = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
54sp-runtime = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
55sp-session = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
56sp-std = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
57sp-transaction-pool = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
58sp-version = { default-features = false, version = '2.0.0' , git = 'https://github.com/usetech-llc/substrate.git', branch = 'v2.0.0_release' }
20359
204[features]60[features]
205default = ['std']61default = ['std']
62runtime-benchmarks = [
63 'hex-literal',
64 'frame-benchmarking',
65 'frame-support/runtime-benchmarks',
66 'frame-system-benchmarking',
67 'frame-system/runtime-benchmarks',
68 'pallet-balances/runtime-benchmarks',
69 'pallet-timestamp/runtime-benchmarks',
70 'sp-runtime/runtime-benchmarks',
71]
206std = [72std = [
207 'aura/std',
208 'balances/std',
209 'codec/std',73 'codec/std',
210 'contracts/std',74 'serde',
211 'contracts-primitives/std',
212 'contracts-rpc-runtime-api/std',
213 'frame-executive/std',75 'frame-executive/std',
214 'frame-support/std',76 'frame-support/std',
77 'frame-system/std',
215 'frame-system-rpc-runtime-api/std',78 'frame-system-rpc-runtime-api/std',
79 'pallet-aura/std',
80 'pallet-balances/std',
81 'pallet-contracts/std',
82 'pallet-contracts-primitives/std',
83 'pallet-contracts-rpc-runtime-api/std',
216 'grandpa/std',84 'pallet-grandpa/std',
217 'randomness-collective-flip/std',85 'pallet-randomness-collective-flip/std',
218 'serde',86 'pallet-sudo/std',
87 'pallet-timestamp/std',
88 'pallet-transaction-payment/std',
89 'pallet-transaction-payment-rpc-runtime-api/std',
90 'pallet-nft/std',
219 'sp-api/std',91 'sp-api/std',
220 'sp-block-builder/std',92 'sp-block-builder/std',
221 'sp-consensus-aura/std',93 'sp-consensus-aura/std',
227 'sp-std/std',99 'sp-std/std',
228 'sp-transaction-pool/std',100 'sp-transaction-pool/std',
229 'sp-version/std',101 'sp-version/std',
230 'sudo/std',
231 'system/std',
232 'timestamp/std',
233 'transaction-payment/std',
234 'transaction-payment-rpc-runtime-api/std',
235 'nft/std',
236]102]
237103
modifiedruntime/build.rsdiffbeforeafterboth
3fn main() {3fn main() {
4 WasmBuilder::new()4 WasmBuilder::new()
5 .with_current_project()5 .with_current_project()
6 .with_wasm_builder_from_crates("1.0.11")6 .with_wasm_builder_from_crates("2.0.0")
7 .export_heap_base()7 .export_heap_base()
8 .import_memory()8 .import_memory()
9 .build()9 .build()
modifiedruntime/src/lib.rsdiffbeforeafterboth
8#[cfg(feature = "std")]8#[cfg(feature = "std")]
9include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));9include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));
1010
11use contracts_rpc_runtime_api::ContractExecResult;11use pallet_contracts_rpc_runtime_api::ContractExecResult;
12use grandpa::fg_primitives;12use pallet_grandpa::fg_primitives;
13use grandpa::{AuthorityId as GrandpaId, AuthorityList as GrandpaAuthorityList};13use pallet_grandpa::{AuthorityId as GrandpaId, AuthorityList as GrandpaAuthorityList};
14use sp_api::impl_runtime_apis;14use sp_api::impl_runtime_apis;
15use sp_consensus_aura::sr25519::AuthorityId as AuraId;15use sp_consensus_aura::sr25519::AuthorityId as AuraId;
16use sp_core::{crypto::KeyTypeId, OpaqueMetadata};16use sp_core::{crypto::KeyTypeId, OpaqueMetadata};
29use sp_version::RuntimeVersion;29use sp_version::RuntimeVersion;
3030
31// A few exports that help ease life for downstream crates.31// A few exports that help ease life for downstream crates.
32pub use balances::Call as BalancesCall;32pub use pallet_balances::Call as BalancesCall;
33pub use contracts::Schedule as ContractsSchedule;33pub use pallet_contracts::Schedule as ContractsSchedule;
34pub use frame_support::{34pub use frame_support::{
35 construct_runtime,35 construct_runtime,
36 dispatch::DispatchResult,36 dispatch::DispatchResult,
49#[cfg(any(feature = "std", test))]49#[cfg(any(feature = "std", test))]
50pub use sp_runtime::BuildStorage;50pub use sp_runtime::BuildStorage;
51use sp_runtime::Perbill;51use sp_runtime::Perbill;
52use system::{self as system};52use frame_system::{self as system};
5353
54pub use timestamp::Call as TimestampCall;54pub use pallet_timestamp::Call as TimestampCall;
5555
56/// Re-export a nft pallet56/// Re-export a nft pallet
57/// TODO: Check this re-export. Is this safe and good style?57/// TODO: Check this re-export. Is this safe and good style?
58extern crate nft;58extern crate pallet_nft;
59pub use nft::*;59pub use pallet_nft::*;
6060
61/// An index to a block.61/// An index to a block.
62pub type BlockNumber = u32;62pub type BlockNumber = u32;
201 /// What to do if an account is fully reaped from the system.201 /// What to do if an account is fully reaped from the system.
202 type OnKilledAccount = ();202 type OnKilledAccount = ();
203 /// The data to be stored in an account.203 /// The data to be stored in an account.
204 type AccountData = balances::AccountData<Balance>;204 type AccountData = pallet_balances::AccountData<Balance>;
205 /// Weight information for the extrinsics of this pallet.205 /// Weight information for the extrinsics of this pallet.
206 type SystemWeightInfo = ();206 type SystemWeightInfo = ();
207}207}
208208
209impl aura::Trait for Runtime {209impl pallet_aura::Trait for Runtime {
210 type AuthorityId = AuraId;210 type AuthorityId = AuraId;
211}211}
212212
213impl grandpa::Trait for Runtime {213impl pallet_grandpa::Trait for Runtime {
214 type Event = Event;214 type Event = Event;
215 type Call = Call;215 type Call = Call;
216216
233 pub const MinimumPeriod: u64 = SLOT_DURATION / 2;233 pub const MinimumPeriod: u64 = SLOT_DURATION / 2;
234}234}
235235
236impl timestamp::Trait for Runtime {236impl pallet_timestamp::Trait for Runtime {
237 /// A timestamp: milliseconds since the unix epoch.237 /// A timestamp: milliseconds since the unix epoch.
238 type Moment = u64;238 type Moment = u64;
239 type OnTimestampSet = Aura;239 type OnTimestampSet = Aura;
247 pub const MaxLocks: u32 = 50;247 pub const MaxLocks: u32 = 50;
248}248}
249249
250impl balances::Trait for Runtime {250impl pallet_balances::Trait for Runtime {
251 type MaxLocks = MaxLocks;251 type MaxLocks = MaxLocks;
252 /// The type for recording an account's balance.252 /// The type for recording an account's balance.
253 type Balance = Balance;253 type Balance = Balance;
270 pub const SurchargeReward: Balance = 150 * MILLICENTS;270 pub const SurchargeReward: Balance = 150 * MILLICENTS;
271}271}
272272
273impl contracts::Trait for Runtime {273impl pallet_contracts::Trait for Runtime {
274 type Time = Timestamp;274 type Time = Timestamp;
275 type Randomness = RandomnessCollectiveFlip;275 type Randomness = RandomnessCollectiveFlip;
276 type Currency = Balances;276 type Currency = Balances;
277 type Event = Event;277 type Event = Event;
278 type DetermineContractAddress = contracts::SimpleAddressDeterminer<Runtime>;278 type DetermineContractAddress = pallet_contracts::SimpleAddressDeterminer<Runtime>;
279 type TrieIdGenerator = contracts::TrieIdFromParentCounter<Runtime>;279 type TrieIdGenerator = pallet_contracts::TrieIdFromParentCounter<Runtime>;
280 type RentPayment = ();280 type RentPayment = ();
281 type SignedClaimHandicap = contracts::DefaultSignedClaimHandicap;281 type SignedClaimHandicap = pallet_contracts::DefaultSignedClaimHandicap;
282 type TombstoneDeposit = TombstoneDeposit;282 type TombstoneDeposit = TombstoneDeposit;
283 type StorageSizeOffset = contracts::DefaultStorageSizeOffset;283 type StorageSizeOffset = pallet_contracts::DefaultStorageSizeOffset;
284 type RentByteFee = RentByteFee;284 type RentByteFee = RentByteFee;
285 type RentDepositOffset = RentDepositOffset;285 type RentDepositOffset = RentDepositOffset;
286 type SurchargeReward = SurchargeReward;286 type SurchargeReward = SurchargeReward;
287 type MaxDepth = contracts::DefaultMaxDepth;287 type MaxDepth = pallet_contracts::DefaultMaxDepth;
288 type MaxValueSize = contracts::DefaultMaxValueSize;288 type MaxValueSize = pallet_contracts::DefaultMaxValueSize;
289 type WeightPrice = transaction_payment::Module<Self>;289 type WeightPrice = pallet_transaction_payment::Module<Self>;
290}290}
291291
292parameter_types! {292parameter_types! {
293 pub const TransactionByteFee: Balance = 1;293 pub const TransactionByteFee: Balance = 1;
294}294}
295295
296impl transaction_payment::Trait for Runtime {296impl pallet_transaction_payment::Trait for Runtime {
297 type Currency = balances::Module<Runtime>;297 type Currency = pallet_balances::Module<Runtime>;
298 type OnTransactionPayment = ();298 type OnTransactionPayment = ();
299 type TransactionByteFee = TransactionByteFee;299 type TransactionByteFee = TransactionByteFee;
300 type WeightToFee = IdentityFee<Balance>;300 type WeightToFee = IdentityFee<Balance>;
301 type FeeMultiplierUpdate = ();301 type FeeMultiplierUpdate = ();
302}302}
303303
304impl sudo::Trait for Runtime {304impl pallet_sudo::Trait for Runtime {
305 type Event = Event;305 type Event = Event;
306 type Call = Call;306 type Call = Call;
307}307}
308308
309/// Used for the module nft in `./nft.rs`309/// Used for the module nft in `./nft.rs`
310impl nft::Trait for Runtime {310impl pallet_nft::Trait for Runtime {
311 type Event = Event;311 type Event = Event;
312}312}
313313
318 UncheckedExtrinsic = UncheckedExtrinsic318 UncheckedExtrinsic = UncheckedExtrinsic
319 {319 {
320 System: system::{Module, Call, Config, Storage, Event<T>},320 System: system::{Module, Call, Config, Storage, Event<T>},
321 RandomnessCollectiveFlip: randomness_collective_flip::{Module, Call, Storage},321 RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Module, Call, Storage},
322 Contracts: contracts::{Module, Call, Config, Storage, Event<T>},322 Contracts: pallet_contracts::{Module, Call, Config, Storage, Event<T>},
323 Timestamp: timestamp::{Module, Call, Storage, Inherent},323 Timestamp: pallet_timestamp::{Module, Call, Storage, Inherent},
324 Aura: aura::{Module, Config<T>, Inherent},324 Aura: pallet_aura::{Module, Config<T>, Inherent},
325 Grandpa: grandpa::{Module, Call, Storage, Config, Event},325 Grandpa: pallet_grandpa::{Module, Call, Storage, Config, Event},
326 Balances: balances::{Module, Call, Storage, Config<T>, Event<T>},326 Balances: pallet_balances::{Module, Call, Storage, Config<T>, Event<T>},
327 TransactionPayment: transaction_payment::{Module, Storage},327 TransactionPayment: pallet_transaction_payment::{Module, Storage},
328 Sudo: sudo::{Module, Call, Config<T>, Storage, Event<T>},328 Sudo: pallet_sudo::{Module, Call, Config<T>, Storage, Event<T>},
329 Nft: nft::{Module, Call, Config<T>, Storage, Event<T>},329 Nft: pallet_nft::{Module, Call, Config<T>, Storage, Event<T>},
330 }330 }
331);331);
332332
348 system::CheckEra<Runtime>,348 system::CheckEra<Runtime>,
349 system::CheckNonce<Runtime>,349 system::CheckNonce<Runtime>,
350 system::CheckWeight<Runtime>,350 system::CheckWeight<Runtime>,
351 nft::ChargeTransactionPayment<Runtime>,351 pallet_nft::ChargeTransactionPayment<Runtime>,
352);352);
353/// Unchecked extrinsic type as expected by this runtime.353/// Unchecked extrinsic type as expected by this runtime.
354pub type UncheckedExtrinsic = generic::UncheckedExtrinsic<Address, Call, Signature, SignedExtra>;354pub type UncheckedExtrinsic = generic::UncheckedExtrinsic<Address, Call, Signature, SignedExtra>;
360360
361impl_runtime_apis! {361impl_runtime_apis! {
362362
363 impl contracts_rpc_runtime_api::ContractsApi<Block, AccountId, Balance, BlockNumber>363 impl pallet_contracts_rpc_runtime_api::ContractsApi<Block, AccountId, Balance, BlockNumber>
364 for Runtime364 for Runtime
365 {365 {
366 fn call(366 fn call(
385 fn get_storage(385 fn get_storage(
386 address: AccountId,386 address: AccountId,
387 key: [u8; 32],387 key: [u8; 32],
388 ) -> contracts_primitives::GetStorageResult {388 ) -> pallet_contracts_primitives::GetStorageResult {
389 Contracts::get_storage(address, key)389 Contracts::get_storage(address, key)
390 }390 }
391391
392 fn rent_projection(392 fn rent_projection(
393 address: AccountId,393 address: AccountId,
394 ) -> contracts_primitives::RentProjectionResult<BlockNumber> {394 ) -> pallet_contracts_primitives::RentProjectionResult<BlockNumber> {
395 Contracts::rent_projection(address)395 Contracts::rent_projection(address)
396 }396 }
397 }397 }
510 }510 }
511 }511 }
512512
513 impl transaction_payment_rpc_runtime_api::TransactionPaymentApi<Block, Balance> for Runtime {513 impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi<Block, Balance> for Runtime {
514 fn query_info(514 fn query_info(
515 uxt: <Block as BlockT>::Extrinsic,515 uxt: <Block as BlockT>::Extrinsic,
516 len: u32,516 len: u32,
517 ) -> transaction_payment_rpc_runtime_api::RuntimeDispatchInfo<Balance> {517 ) -> pallet_transaction_payment_rpc_runtime_api::RuntimeDispatchInfo<Balance> {
518 TransactionPayment::query_info(uxt, len)518 TransactionPayment::query_info(uxt, len)
519 }519 }
520 }520 }
521521
522 #[cfg(feature = "runtime-benchmarks")]
523 impl frame_benchmarking::Benchmark<Block> for Runtime {
524 fn dispatch_benchmark(
525 config: frame_benchmarking::BenchmarkConfig
526 ) -> Result<Vec<frame_benchmarking::BenchmarkBatch>, sp_runtime::RuntimeString> {
527 use frame_benchmarking::{Benchmarking, BenchmarkBatch, add_benchmark, TrackedStorageKey};
528
529 use frame_system_benchmarking::Module as SystemBench;
530 impl frame_system_benchmarking::Trait for Runtime {}
531
532 let mut whitelist: Vec<TrackedStorageKey> = vec![
533 // Block Number
534 hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(),
535 // Total Issuance
536 hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(),
537 // Execution Phase
538 hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(),
539 // Event Count
540 hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(),
541 // System Events
542 hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(),
543 ];
544
545 let mut batches = Vec::<BenchmarkBatch>::new();
546 let params = (&config, &whitelist);
547
548 add_benchmark!(params, batches, frame_system, SystemBench::<Runtime>);
549 add_benchmark!(params, batches, pallet_balances, Balances);
550 add_benchmark!(params, batches, pallet_timestamp, Timestamp);
551
552 if batches.is_empty() { return Err("Benchmark not found for this pallet.".into()) }
553 Ok(batches)
554 }
555 }
522}556}
523557