From a23a8f7616eba15e286d7ca98110a991e97f4bfd Mon Sep 17 00:00:00 2001 From: Guangyu Zhu Date: Tue, 13 Apr 2021 14:31:35 +0800 Subject: [PATCH] [vm] upgrade to release 1.2 (#2387) * [vm] upgrade to release 1.2 - update rustc to 1.51 - update x tool - update move prover --- Cargo.lock | 723 ++++++++++-------- chain/api/src/errors.rs | 1 + chain/api/src/message.rs | 1 + chain/tests/test_block_chain.rs | 6 + cmd/starcoin/Cargo.toml | 4 +- cmd/starcoin/src/chain/stat/tps.rs | 2 + cmd/starcoin/src/chain/tps.rs | 2 + .../uncle/epoch_uncle_summary_by_number.rs | 5 +- cmd/starcoin/src/debug/txpool_status.rs | 2 +- cmd/starcoin/src/dev/get_coin_cmd.rs | 2 +- cmd/starcoin/src/dev/sign_txn_helper.rs | 4 +- cmd/starcoin/src/txpool/mod.rs | 2 +- commons/accumulator/src/inmemory/mod.rs | 2 +- commons/bcs_ext/src/lib.rs | 1 + commons/crypto/Cargo.toml | 4 +- .../crypto/src/multi_ed25519/multi_shard.rs | 3 + commons/forkable-jellyfish-merkle/src/lib.rs | 2 +- .../src/node_type/node_type_test.rs | 1 + .../src/tree_cache/mod.rs | 1 + commons/logger/src/lib.rs | 2 +- commons/proptest-helpers/Cargo.toml | 2 +- commons/scmd/src/result.rs | 1 + .../tests/common/shared_data_service.rs | 1 + config/Cargo.toml | 2 +- config/src/genesis_config.rs | 3 + config/src/lib.rs | 1 + config/src/network_config.rs | 1 + config/src/rpc_config.rs | 1 + devtools/x/Cargo.toml | 8 +- devtools/x/src/main.rs | 8 + devtools/x/src/test.rs | 18 +- executor/src/account.rs | 2 + genesis/src/lib.rs | 4 +- network-p2p/src/service.rs | 6 +- network-p2p/types/src/lib.rs | 1 + network-rpc/api/src/lib.rs | 1 + network-rpc/core/tests/rpc_gen_test.rs | 2 + network-rpc/derive/src/to_client.rs | 2 +- network/api/src/messages.rs | 2 + rpc/api/src/types.rs | 4 + rpc/server/src/module/account_rpc.rs | 4 +- rpc/server/src/module/chain_rpc.rs | 8 +- rpc/server/src/module/mod.rs | 2 + rust-toolchain | 2 +- state/statedb/src/lib.rs | 1 + storage/src/block/mod.rs | 1 + storage/src/db_storage/mod.rs | 1 + storage/src/metrics.rs | 1 + storage/src/storage.rs | 4 + .../src/block_connector/test_illegal_block.rs | 10 + sync/src/tasks/block_sync_task.rs | 1 + txpool/src/pool/queue.rs | 1 + types/src/account_state.rs | 1 + types/src/block.rs | 4 + types/src/peer_info.rs | 1 + types/src/state_set.rs | 1 + types/src/stress_test.rs | 1 + types/uint/src/lib.rs | 1 + vm/compiler/Cargo.toml | 4 +- vm/functional-tests/Cargo.toml | 4 +- vm/functional-tests/src/errors.rs | 1 + vm/move-coverage/Cargo.toml | 4 +- vm/move-explain/Cargo.toml | 4 +- vm/move-prover/Cargo.toml | 28 +- vm/move-prover/src/cli.rs | 76 +- vm/move-prover/src/lib.rs | 17 +- vm/move-prover/src/pipelines.rs | 2 +- .../src/prelude_template_helpers.rs | 59 -- .../tests/sources/functional/hash_model.move | 93 --- .../functional/hash_model_invalid.move | 37 - .../sources/functional/return_values.move | 66 -- vm/stdlib/Cargo.toml | 4 +- vm/transaction-builder-generator/Cargo.toml | 2 +- vm/types/Cargo.toml | 12 +- vm/types/src/access_path.rs | 1 + vm/types/src/genesis_config.rs | 1 + vm/types/src/on_chain_config/dao_config.rs | 3 +- vm/types/src/on_chain_config/mod.rs | 2 + vm/types/src/on_chain_config/vm_config.rs | 2 + vm/types/src/token/stc.rs | 1 + vm/types/src/token/token_code.rs | 1 + vm/types/src/transaction/authenticator.rs | 4 + vm/types/src/transaction/mod.rs | 2 + vm/types/src/transaction/script.rs | 5 + vm/vm-runtime/Cargo.toml | 2 +- vm/vm-runtime/src/starcoin_vm.rs | 5 +- 86 files changed, 650 insertions(+), 677 deletions(-) delete mode 100644 vm/move-prover/src/prelude_template_helpers.rs delete mode 100644 vm/move-prover/tests/sources/functional/hash_model.move delete mode 100644 vm/move-prover/tests/sources/functional/hash_model_invalid.move delete mode 100644 vm/move-prover/tests/sources/functional/return_values.move diff --git a/Cargo.lock b/Cargo.lock index 0a37eefea9..c424026abd 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1,11 +1,9 @@ # This file is automatically @generated by Cargo. # It is not intended for manual editing. -version = 3 - [[package]] name = "abigen" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bcs", @@ -36,7 +34,7 @@ dependencies = [ "log 0.4.14", "once_cell", "parking_lot 0.11.1", - "pin-project 0.4.27", + "pin-project 0.4.28", "smallvec 1.6.1", "tokio 0.2.25", "tokio-util 0.3.1", @@ -51,7 +49,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4ca8ce00b267af8ccebbd647de0d61e0674b6e61185cc7a592ff88772bed655" dependencies = [ "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -92,7 +90,7 @@ checksum = "b95aceadaf327f18f0df5962fedc1bde2f870566a0b9f65c89508a3b1f79334c" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -364,7 +362,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0d0864d84b8e07b145449be9a8537db86bf9de5ce03b913214694643b4743502" dependencies = [ "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -500,7 +498,7 @@ checksum = "36ea56748e10732c49404c153638a15ec3d6211ec5ff35d9bb20e13b93576adf" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -662,7 +660,7 @@ dependencies = [ "anyhow", "criterion", "forkable-jellyfish-merkle", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "network-api", "parking_lot 0.11.1", @@ -849,7 +847,7 @@ dependencies = [ [[package]] name = "boogie-backend" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "async-trait", @@ -858,7 +856,7 @@ dependencies = [ "codespan", "codespan-reporting", "diem-workspace-hack", - "futures 0.3.12", + "futures 0.3.13", "handlebars", "itertools 0.10.0", "log 0.4.14", @@ -871,14 +869,14 @@ dependencies = [ "regex", "serde", "serde_json", - "tokio 1.3.0", + "tokio 1.4.0", "vm", ] [[package]] name = "boogie-backend-v2" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "async-trait", @@ -886,7 +884,7 @@ dependencies = [ "codespan", "codespan-reporting", "diem-workspace-hack", - "futures 0.3.12", + "futures 0.3.13", "handlebars", "itertools 0.10.0", "log 0.4.14", @@ -899,14 +897,14 @@ dependencies = [ "regex", "serde", "serde_json", - "tokio 1.3.0", + "tokio 1.4.0", "vm", ] [[package]] name = "borrow-graph" version = "0.0.1" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "mirai-annotations", @@ -961,7 +959,7 @@ checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" [[package]] name = "bytecode" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "borrow-graph", "bytecode-verifier", @@ -983,7 +981,7 @@ dependencies = [ [[package]] name = "bytecode-source-map" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bcs", @@ -999,7 +997,7 @@ dependencies = [ [[package]] name = "bytecode-verifier" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "borrow-graph", @@ -1061,9 +1059,9 @@ checksum = "631ae5198c9be5e753e5cc215e1bd73c2b466a3565173db433f52bb9d3e66dba" [[package]] name = "camino" -version = "1.0.3" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fb25ad5c4211e3c7abded8f00b480e6d1608845dcf14157e9e81d5432e9ac16" +checksum = "d4648c6d00a709aa069a236adcaae4f605a6241c72bf5bee79331a4b625921a9" dependencies = [ "serde", ] @@ -1246,7 +1244,7 @@ dependencies = [ "proc-macro-error", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1522,7 +1520,7 @@ dependencies = [ "cfg-if 1.0.0", "crossbeam-utils 0.8.3", "lazy_static", - "memoffset 0.6.1", + "memoffset 0.6.3", "scopeguard", ] @@ -1639,12 +1637,12 @@ dependencies = [ [[package]] name = "ctor" -version = "0.1.19" +version = "0.1.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8f45d9ad417bcef4817d614a501ab55cdd96a6fdb24f49aab89a54acfd66b19" +checksum = "5e98e2ad1a782e33928b96fc3948e7c355e5af34ba4de7670fe8bac2a3b2006d" dependencies = [ "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1764,7 +1762,7 @@ dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", "strsim 0.9.3", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1778,7 +1776,7 @@ dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", "strsim 0.10.0", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1800,7 +1798,7 @@ checksum = "d9b5a2f4ac4969822c62224815d069952656cadc7084fdca9751e6d959189b72" dependencies = [ "darling_core 0.10.2", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1811,7 +1809,7 @@ checksum = "c0220073ce504f12a70efc4e7cdaea9e9b1b324872e7ad96a208056d7a638b81" dependencies = [ "darling_core 0.12.2", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1853,7 +1851,7 @@ checksum = "3ee2393c4a91429dffb4bedf19f4d6abf27d8a732c8ce4980305d782e5426d57" [[package]] name = "datatest-stable" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "regex", @@ -1870,7 +1868,7 @@ checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1907,7 +1905,7 @@ dependencies = [ "convert_case", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -1930,7 +1928,7 @@ dependencies = [ [[package]] name = "diem-crypto" version = "0.0.1" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "aes-gcm 0.8.0", "anyhow", @@ -1961,17 +1959,17 @@ dependencies = [ [[package]] name = "diem-crypto-derive" version = "0.0.1" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] name = "diem-infallible" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", ] @@ -1979,18 +1977,18 @@ dependencies = [ [[package]] name = "diem-log-derive" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] name = "diem-logger" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "backtrace", "chrono", @@ -2008,7 +2006,7 @@ dependencies = [ [[package]] name = "diem-proptest-helpers" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "crossbeam 0.8.0", "diem-workspace-hack", @@ -2019,7 +2017,7 @@ dependencies = [ [[package]] name = "diem-temppath" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "hex", @@ -2029,7 +2027,7 @@ dependencies = [ [[package]] name = "diem-types" version = "0.0.1" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "aes-gcm 0.8.0", "anyhow", @@ -2054,7 +2052,7 @@ dependencies = [ [[package]] name = "diem-workspace-hack" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "byteorder 1.4.3", "bytes 1.0.1", @@ -2066,14 +2064,13 @@ dependencies = [ "crossbeam-utils 0.8.3", "either", "fail", - "futures 0.3.12", + "futures 0.3.13", "futures-channel", "futures-core", "futures-io", "futures-sink", - "futures-task", "futures-util", - "hyper 0.14.4", + "hyper 0.14.5", "indexmap", "itertools 0.10.0", "itoa", @@ -2097,9 +2094,9 @@ dependencies = [ "standback", "subtle 2.4.0", "syn 0.15.44", - "syn 1.0.64", - "tokio 1.3.0", - "tokio-util 0.6.4", + "syn 1.0.68", + "tokio 1.4.0", + "tokio-util 0.6.5", "toml", "tracing", "warp", @@ -2193,7 +2190,7 @@ dependencies = [ [[package]] name = "docgen" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bytecode", @@ -2211,9 +2208,21 @@ dependencies = [ [[package]] name = "dtoa" -version = "0.4.7" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88d7ed2934d741c6b37e33e3832298e8850b53fd2d2bea03873375596c7cea4e" +checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" + +[[package]] +name = "duct" +version = "0.13.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fc6a0a59ed0888e0041cf708e66357b7ae1a82f1c67247e1f93b5e0818f7d8d" +dependencies = [ + "libc", + "once_cell", + "os_pipe", + "shared_child", +] [[package]] name = "dyn-clone" @@ -2315,7 +2324,7 @@ dependencies = [ "heck", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -2356,7 +2365,7 @@ dependencies = [ [[package]] name = "errmapgen" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bcs", @@ -2412,7 +2421,7 @@ checksum = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed" [[package]] name = "fallible" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "thiserror", @@ -2559,9 +2568,9 @@ checksum = "3a471a38ef8ed83cd6e40aa59c1ffe17db6855c18e3604d9c4ed8c08ebc28678" [[package]] name = "futures" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da9052a1a50244d8d5aa9bf55cbc2fb6f357c86cc52e46c62ed390a7180cf150" +checksum = "7f55667319111d593ba876406af7c409c0ebb44dc4be6132a783ccf163ea14c1" dependencies = [ "futures-channel", "futures-core", @@ -2605,9 +2614,9 @@ checksum = "b35b6263fb1ef523c3056565fa67b1d16f0a8604ff12b11b08c25f28a734c60a" [[package]] name = "futures-executor" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9e59fdc009a4b3096bf94f740a0f2424c082521f20a9b08c5c07c48d90fd9b9" +checksum = "891a4b7b96d84d5940084b2a37632dd65deeae662c114ceaa2c879629c9c0ad1" dependencies = [ "futures-core", "futures-task", @@ -2638,14 +2647,14 @@ dependencies = [ [[package]] name = "futures-macro" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c287d25add322d9f9abdcdc5927ca398917996600182178774032e9f8258fedd" +checksum = "ea405816a5139fb39af82c2beb921d52143f556038378d6db21183a5c37fbfb7" dependencies = [ "proc-macro-hack", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -2654,8 +2663,8 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "759bfe7464299589f02197a973e0e01f17c4cdcef87b454579af8b0629ba7420" dependencies = [ - "futures 0.3.12", - "pin-project 0.4.27", + "futures 0.3.13", + "pin-project 0.4.28", "tokio 0.2.25", ] @@ -2678,12 +2687,9 @@ checksum = "85754d98985841b7d4f5e8e6fbfa4a4ac847916893ec511a2917ccd8525b8bb3" [[package]] name = "futures-task" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13de07eb8ea81ae445aca7b69f5f7bf15d7bf4912d8ca37d6645c77ae8a58d86" -dependencies = [ - "once_cell", -] +checksum = "fa189ef211c15ee602667a6fcfe1c1fd9e07d42250d2156382820fba33c9df80" [[package]] name = "futures-timer" @@ -2693,9 +2699,9 @@ checksum = "e64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2c" [[package]] name = "futures-util" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "632a8cd0f2a4b3fdea1657f08bde063848c3bd00f9bbf6e256b8be78802e624b" +checksum = "1812c7ab8aedf8d6f2701a43e1243acdbcc2b36ab26e2ad421eb99ac963d96d1" dependencies = [ "futures 0.1.31", "futures-channel", @@ -2827,7 +2833,7 @@ dependencies = [ "proc-macro-hack", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -2879,7 +2885,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "06c5d2f987ee8f6dff3fa1a352058dc59b990e447e4c7846aa7d804971314f7b" dependencies = [ "dashmap", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "no-std-compat", "nonzero_ext", @@ -2949,9 +2955,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.1" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d832b01df74254fe364568d6ddc294443f61cbec82816b60904303af87efae78" +checksum = "fc018e188373e2777d0ef2467ebff62a08e66c3f5857b23c8fbec3018210dc00" dependencies = [ "bytes 1.0.1", "fnv", @@ -2961,8 +2967,8 @@ dependencies = [ "http", "indexmap", "slab", - "tokio 1.3.0", - "tokio-util 0.6.4", + "tokio 1.4.0", + "tokio-util 0.6.5", "tracing", ] @@ -2992,9 +2998,9 @@ checksum = "62aca2aba2d62b4a7f5b33f3712cb1b0692779a56fb510499d5c0aa594daeaf3" [[package]] name = "handlebars" -version = "3.5.3" +version = "3.5.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdb0867bbc5a3da37a753e78021d5fcf8a4db00e18dd2dd90fd36e24190e162d" +checksum = "580b6f551b29a3a02436318aed09ba1c58eea177dc49e39beac627ad356730a5" dependencies = [ "log 0.4.14", "pest 2.1.3", @@ -3147,12 +3153,13 @@ dependencies = [ [[package]] name = "http-body" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2861bd27ee074e5ee891e8b539837a9430012e249d7f0ca2d795650f579c1994" +checksum = "5dfb77c123b4e2f72a2069aeae0b4b4949cc7e966df277813fc16347e7549737" dependencies = [ "bytes 1.0.1", "http", + "pin-project-lite 0.2.6", ] [[package]] @@ -3217,8 +3224,8 @@ dependencies = [ "httparse", "httpdate", "itoa", - "pin-project 1.0.5", - "socket2", + "pin-project 1.0.6", + "socket2 0.3.19", "tokio 0.2.25", "tower-service", "tracing", @@ -3227,23 +3234,23 @@ dependencies = [ [[package]] name = "hyper" -version = "0.14.4" +version = "0.14.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8e946c2b1349055e0b72ae281b238baf1a3ea7307c7e9f9d64673bdd9c26ac7" +checksum = "8bf09f61b52cfcf4c00de50df88ae423d6c02354e385a86341133b5338630ad1" dependencies = [ "bytes 1.0.1", "futures-channel", "futures-core", "futures-util", - "h2 0.3.1", + "h2 0.3.2", "http", - "http-body 0.4.0", + "http-body 0.4.1", "httparse", "httpdate", "itoa", - "pin-project 1.0.5", - "socket2", - "tokio 1.3.0", + "pin-project 1.0.6", + "socket2 0.4.0", + "tokio 1.4.0", "tower-service", "tracing", "want", @@ -3269,9 +3276,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" dependencies = [ "bytes 1.0.1", - "hyper 0.14.4", + "hyper 0.14.5", "native-tls", - "tokio 1.3.0", + "tokio 1.4.0", "tokio-native-tls", ] @@ -3331,7 +3338,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "97b8538953a3f0d0d3868f0a706eb4273535e10d72acb5c82c1c23ae48835c85" dependencies = [ "async-io", - "futures 0.3.12", + "futures 0.3.13", "futures-lite", "if-addrs", "ipnet", @@ -3379,7 +3386,7 @@ dependencies = [ "proc-macro-hack", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -3440,7 +3447,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f7e2f18aece9709094573a9f24f483c4f65caa4298e2f7ae1b71cc65d853fad7" dependencies = [ - "socket2", + "socket2 0.3.19", "widestring", "winapi 0.3.9", "winreg 0.6.2", @@ -3455,7 +3462,7 @@ checksum = "47be2f14c678be2fdcab04ab1171db51b2762ce6f0a8ee87c8dd4a04ed216135" [[package]] name = "ir-to-bytecode" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bytecode-source-map", @@ -3474,7 +3481,7 @@ dependencies = [ [[package]] name = "ir-to-bytecode-syntax" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "codespan", @@ -3537,9 +3544,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.48" +version = "0.3.50" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc9f84f9b115ce7843d60706df1422a916680bfdfcbdb0447c5614ff9d7e4d78" +checksum = "2d99f9e3e84b8f67f846ef5b4cbbc3b1c29f6c759fcbce6f01aa0e73d932a24c" dependencies = [ "wasm-bindgen", ] @@ -3564,7 +3571,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "15b6c6ad01c7354d60de493148c30ac8a82b759e22ae678c8705e9b8e0c566a4" dependencies = [ "derive_more", - "futures 0.3.12", + "futures 0.3.13", "hyper 0.13.10", "hyper-tls 0.4.3", "jsonrpc-core", @@ -3585,7 +3592,7 @@ version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "07569945133257ff557eb37b015497104cea61a2c9edaf126c1cbd6e8332397f" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "log 0.4.14", "serde", "serde_derive", @@ -3598,7 +3605,7 @@ version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7ac9d56dc729912796637c30f475bbf834594607b27740dfea6e5fa7ba40d1f1" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "jsonrpc-client-transports", ] @@ -3611,7 +3618,7 @@ dependencies = [ "proc-macro-crate", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -3620,7 +3627,7 @@ version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eff2303c4f0562afcbd2dae75e3e21815095f8994749a80fbcd365877e44ed64" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "hyper 0.13.10", "jsonrpc-core", "jsonrpc-server-utils", @@ -3636,7 +3643,7 @@ version = "17.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "14c4cd89e5ea7e7f0884e828fc35bb83591a371b92439675eae28efa66c24a97" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "jsonrpc-core", "jsonrpc-server-utils", "log 0.4.14", @@ -3651,7 +3658,7 @@ version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c48dbebce7a9c88ab272a4db7d6478aa4c6d9596e6c086366e89efc4e9ed89e" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "jsonrpc-core", "lazy_static", "log 0.4.14", @@ -3667,7 +3674,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f4207cce738bf713a82525065b750a008f28351324f438f56b33d698ada95bb4" dependencies = [ "bytes 0.5.6", - "futures 0.3.12", + "futures 0.3.13", "globset", "jsonrpc-core", "lazy_static", @@ -3696,7 +3703,7 @@ version = "17.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "abe06e1385e4a912711703123ba44f735627d666f87e5fec764ad1338ec617dc" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "jsonrpc-core", "jsonrpc-server-utils", "log 0.4.14", @@ -3795,7 +3802,7 @@ checksum = "adc225a49973cf9ab10d0cdd6a4b8f0cda299df9b760824bbb623f15f8f0c95a" dependencies = [ "atomic", "bytes 1.0.1", - "futures 0.3.12", + "futures 0.3.13", "lazy_static", "libp2p-core", "libp2p-dns", @@ -3814,7 +3821,7 @@ dependencies = [ "libp2p-yamux", "parity-multiaddr", "parking_lot 0.11.1", - "pin-project 1.0.5", + "pin-project 1.0.6", "smallvec 1.6.1", "wasm-timer", ] @@ -3830,7 +3837,7 @@ dependencies = [ "ed25519-dalek", "either", "fnv", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "lazy_static", "libsecp256k1", @@ -3839,7 +3846,7 @@ dependencies = [ "multistream-select", "parity-multiaddr", "parking_lot 0.11.1", - "pin-project 1.0.5", + "pin-project 1.0.6", "prost", "prost-build", "rand 0.7.3", @@ -3859,7 +3866,7 @@ version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5153b6db68fd4baa3b304e377db744dd8fea8ff4e4504509ee636abcde88d3e3" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "log 0.4.14", ] @@ -3870,7 +3877,7 @@ version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b40fb36a059b7a8cce1514bd8b546fa612e006c9937caa7f5950cb20021fe91e" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "libp2p-swarm", "log 0.4.14", @@ -3891,7 +3898,7 @@ dependencies = [ "bytes 1.0.1", "either", "fnv", - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "libp2p-swarm", "log 0.4.14", @@ -3915,7 +3922,7 @@ dependencies = [ "async-io", "data-encoding", "dns-parser", - "futures 0.3.12", + "futures 0.3.13", "if-watch", "lazy_static", "libp2p-core", @@ -3923,7 +3930,7 @@ dependencies = [ "log 0.4.14", "rand 0.7.3", "smallvec 1.6.1", - "socket2", + "socket2 0.3.19", "void", ] @@ -3935,7 +3942,7 @@ checksum = "350ce8b3923594aedabd5d6e3f875d058435052a29c3f32df378bc70d10be464" dependencies = [ "asynchronous-codec 0.6.0", "bytes 1.0.1", - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "log 0.4.14", "nohash-hasher", @@ -3953,7 +3960,7 @@ checksum = "4aca322b52a0c5136142a7c3971446fb1e9964923a526c9cc6ef3b7c94e57778" dependencies = [ "bytes 1.0.1", "curve25519-dalek", - "futures 0.3.12", + "futures 0.3.13", "lazy_static", "libp2p-core", "log 0.4.14", @@ -3973,7 +3980,7 @@ version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6f3813276d0708c8db0f500d8beda1bda9ad955723b9cb272c41f4727256f73c" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "libp2p-swarm", "log 0.4.14", @@ -3990,7 +3997,7 @@ checksum = "10e5552827c33d8326502682da73a0ba4bfa40c1b55b216af3c303f32169dd89" dependencies = [ "async-trait", "bytes 1.0.1", - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "libp2p-swarm", "log 0.4.14", @@ -4009,7 +4016,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7955b973e1fd2bd61ffd43ce261c1223f61f4aacd5bae362a924993f9a25fd98" dependencies = [ "either", - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "log 0.4.14", "rand 0.7.3", @@ -4025,7 +4032,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c564ebaa36a64839f51eaddb0243aaaa29ce64affb56129193cc3248b72af273" dependencies = [ "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -4035,14 +4042,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "88a5aef80e519a6cb8e2663605142f97baaaea1a252eecbf8756184765f7471b" dependencies = [ "async-io", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "if-watch", "ipnet", "libc", "libp2p-core", "log 0.4.14", - "socket2", + "socket2 0.3.19", ] [[package]] @@ -4051,7 +4058,7 @@ version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6149c46cb76935c80bc8be6ec6e3ebd5f5e1679765a255fb34331d54610f15dd" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "js-sys", "libp2p-core", "parity-send-wrapper", @@ -4066,7 +4073,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3b1c6a3431045da8b925ed83384e4c5163e14b990572307fca9c507435d4d22" dependencies = [ "either", - "futures 0.3.12", + "futures 0.3.13", "futures-rustls", "libp2p-core", "log 0.4.14", @@ -4083,7 +4090,7 @@ version = "0.30.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4819358c542a86ff95f6ae691efb4b94ddaf477079b01a686f5705b79bfc232a" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "libp2p-core", "parking_lot 0.11.1", "thiserror", @@ -4155,9 +4162,9 @@ dependencies = [ [[package]] name = "lock_api" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd96ffd135b2fd7b973ac026d28085defbe8983df057ced3eb4f2130b0831312" +checksum = "5a3c91c24eae6777794bb1997ad98bbb87daf92890acab859f7eaa4320333176" dependencies = [ "scopeguard", ] @@ -4294,9 +4301,9 @@ dependencies = [ [[package]] name = "memoffset" -version = "0.6.1" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "157b4208e3059a8f9e78d559edc658e13df41410cb3ae03979c83130067fdd87" +checksum = "f83fb6581e8ed1f85fd45c116db8405483899489e38406156c25eb743554361d" dependencies = [ "autocfg 1.0.1", ] @@ -4380,7 +4387,7 @@ checksum = "19ce18b5423c573a13e80cb3046ea0af6379ef725dc3af4886bdb8f4e5093068" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -4414,13 +4421,13 @@ dependencies = [ [[package]] name = "mio" -version = "0.7.10" +version = "0.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2182a122f3b7f3f5329cb1972cee089ba2459a0a80a56935e6e674f096f8d839" +checksum = "cf80d3e903b34e0bd7282b218398aec54e082c840d9baf8339e0080a0c542956" dependencies = [ "libc", "log 0.4.14", - "miow 0.3.6", + "miow 0.3.7", "ntapi", "winapi 0.3.9", ] @@ -4445,7 +4452,7 @@ checksum = "0840c1c50fd55e521b247f949c241c9997709f23bd7f023b9762cd561e935656" dependencies = [ "log 0.4.14", "mio 0.6.23", - "miow 0.3.6", + "miow 0.3.7", "winapi 0.3.9", ] @@ -4474,11 +4481,10 @@ dependencies = [ [[package]] name = "miow" -version = "0.3.6" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a33c1b55807fbed163481b5ba66db4b2fa6cde694a5027be10fb724206c5897" +checksum = "b9f1c5b025cda876f66ef43a113f91ebc9f4ccef34843000e0adf6ebbab84e21" dependencies = [ - "socket2", "winapi 0.3.9", ] @@ -4491,7 +4497,7 @@ checksum = "b48e78b8626927bd980dff38d8147006323f5d7634d7bc9e31c3a59e07da1b28" [[package]] name = "move-core-types" version = "0.0.1" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bcs", @@ -4527,7 +4533,7 @@ dependencies = [ [[package]] name = "move-ir-types" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "codespan", @@ -4541,7 +4547,7 @@ dependencies = [ [[package]] name = "move-lang" version = "0.0.1" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bcs", @@ -4569,7 +4575,7 @@ dependencies = [ [[package]] name = "move-lang-test-utils" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "datatest-stable", "diem-workspace-hack", @@ -4578,7 +4584,7 @@ dependencies = [ [[package]] name = "move-model" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "bytecode-source-map", @@ -4616,7 +4622,7 @@ dependencies = [ "diem-temppath", "docgen", "errmapgen", - "futures 0.3.12", + "futures 0.3.13", "handlebars", "hex", "itertools 0.10.0", @@ -4642,7 +4648,7 @@ dependencies = [ [[package]] name = "move-prover-test-utils" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "diem-workspace-hack", @@ -4653,7 +4659,7 @@ dependencies = [ [[package]] name = "move-vm-natives" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-crypto", "diem-workspace-hack", @@ -4669,7 +4675,7 @@ dependencies = [ [[package]] name = "move-vm-runtime" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "bytecode-verifier", "diem-crypto", @@ -4688,7 +4694,7 @@ dependencies = [ [[package]] name = "move-vm-types" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "bcs", "diem-crypto", @@ -4725,7 +4731,7 @@ dependencies = [ "proc-macro-error", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", "synstructure", ] @@ -4760,9 +4766,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7d91ec0a2440aaff5f78ec35631a7027d50386c6163aa975f7caa0d5da4b6ff8" dependencies = [ "bytes 1.0.1", - "futures 0.3.12", + "futures 0.3.13", "log 0.4.14", - "pin-project 1.0.5", + "pin-project 1.0.6", "smallvec 1.6.1", "unsigned-varint 0.7.0", ] @@ -4796,12 +4802,12 @@ dependencies = [ [[package]] name = "nb-connect" -version = "1.0.3" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "670361df1bc2399ee1ff50406a0d422587dd3bb0da596e1978fe8e05dabddf4f" +checksum = "a19900e7eee95eb2b3c2e26d12a874cc80aaf750e31be6fcbe743ead369fa45d" dependencies = [ "libc", - "socket2", + "socket2 0.4.0", ] [[package]] @@ -4828,7 +4834,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "hex", "itertools 0.10.0", "network-p2p-types", @@ -4856,7 +4862,7 @@ dependencies = [ "derive_more", "either", "fnv", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "ip_network", @@ -4868,7 +4874,7 @@ dependencies = [ "network-p2p-types", "once_cell", "parking_lot 0.11.1", - "pin-project 0.4.27", + "pin-project 0.4.28", "prometheus", "rand 0.8.3", "sc-peerset", @@ -4907,7 +4913,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "log 0.4.14", "network-rpc-derive", "num_enum", @@ -4923,7 +4929,7 @@ dependencies = [ "anyhow", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5055,7 +5061,7 @@ checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5103,12 +5109,12 @@ dependencies = [ [[package]] name = "num-variants" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5140,7 +5146,7 @@ dependencies = [ "proc-macro-crate", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5215,6 +5221,16 @@ dependencies = [ "num-traits", ] +[[package]] +name = "os_pipe" +version = "0.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb233f06c2307e1f5ce2ecad9f8121cffbbee2c95428f44ea85222e460d0d213" +dependencies = [ + "libc", + "winapi 0.3.9", +] + [[package]] name = "os_str_bytes" version = "2.4.0" @@ -5223,9 +5239,9 @@ checksum = "afb2e1c3ee07430c2cf76151675e583e0f19985fa6efae47d6848a3e2c824f85" [[package]] name = "parity-multiaddr" -version = "0.11.1" +version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2c6805f98667a3828afb2ec2c396a8d610497e8d546f5447188aae47c5a79ec" +checksum = "58341485071825827b7f03cf7efd1cb21e6a709bea778fb50227fd45d2f361b4" dependencies = [ "arrayref", "bs58 0.4.0", @@ -5251,11 +5267,11 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd7f6c69d7687501b2205fe51ade1d7b8797bb3aa141fe5bf13dd78c0483bc89" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "libc", "log 0.4.14", "mio-named-pipes", - "miow 0.3.6", + "miow 0.3.7", "rand 0.7.3", "tokio 0.2.25", "winapi 0.3.9", @@ -5303,7 +5319,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6d7744ac029df22dca6284efe4e898991d28e3085c706c972bcd7da4a27a15eb" dependencies = [ "instant", - "lock_api 0.4.2", + "lock_api 0.4.3", "parking_lot_core 0.8.3", ] @@ -5427,7 +5443,7 @@ dependencies = [ "pest_meta", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5453,42 +5469,42 @@ dependencies = [ [[package]] name = "pin-project" -version = "0.4.27" +version = "0.4.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ffbc8e94b38ea3d2d8ba92aea2983b503cd75d0888d75b86bb37970b5698e15" +checksum = "918192b5c59119d51e0cd221f4d49dde9112824ba717369e903c97d076083d0f" dependencies = [ - "pin-project-internal 0.4.27", + "pin-project-internal 0.4.28", ] [[package]] name = "pin-project" -version = "1.0.5" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96fa8ebb90271c4477f144354485b8068bd8f6b78b428b01ba892ca26caf0b63" +checksum = "bc174859768806e91ae575187ada95c91a29e96a98dc5d2cd9a1fed039501ba6" dependencies = [ - "pin-project-internal 1.0.5", + "pin-project-internal 1.0.6", ] [[package]] name = "pin-project-internal" -version = "0.4.27" +version = "0.4.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65ad2ae56b6abe3a1ee25f15ee605bacadb9a764edaba9c2bf4103800d4a1895" +checksum = "3be26700300be6d9d23264c73211d8190e755b6b5ca7a1b28230025511b52a5e" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] name = "pin-project-internal" -version = "1.0.5" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "758669ae3558c6f74bd2a18b41f7ac0b5a195aea6639d6a9b5e5d1ad5ba24c0b" +checksum = "a490329918e856ed1b083f244e3bfe2d8c4f336407e4ea9e1a9f479ff09049e5" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5545,11 +5561,11 @@ dependencies = [ [[package]] name = "polling" -version = "2.0.2" +version = "2.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2a7bc6b2a29e632e45451c941832803a18cce6781db04de8a04696cdca8bde4" +checksum = "4fc12d774e799ee9ebae13f4076ca003b40d18a11ac0f3641e6f899618580b7b" dependencies = [ - "cfg-if 0.1.10", + "cfg-if 1.0.0", "libc", "log 0.4.14", "wepoll-sys", @@ -5658,7 +5674,7 @@ dependencies = [ "proc-macro-error-attr", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", "version_check 0.9.3", ] @@ -5789,7 +5805,7 @@ dependencies = [ "itertools 0.9.0", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -5804,9 +5820,9 @@ dependencies = [ [[package]] name = "protobuf" -version = "2.22.0" +version = "2.22.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73f72884896d22e0da0e5b266cb9a780b791f6c3b2f5beab6368d6cd4f0dbb86" +checksum = "1b7f4a129bb3754c25a4e04032a90173c68f85168f77118ac4cb4936e7f06f92" [[package]] name = "psutil" @@ -5845,6 +5861,25 @@ version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3ac73b1112776fc109b2e61909bc46c7e1bf0d7f690ffb1676553acce16d5cda" +[[package]] +name = "quick-junit" +version = "0.1.0" +source = "git+https://github.com/diem/diem-devtools?branch=main#bf9dae41f8afc8b27fbf7a2f7bb5834b7f8e6db9" +dependencies = [ + "chrono", + "indexmap", + "quick-xml", +] + +[[package]] +name = "quick-xml" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8533f14c8382aaad0d592c812ac3b826162128b65662331e1127b45c3d18536b" +dependencies = [ + "memchr", +] + [[package]] name = "quicksink" version = "0.1.2" @@ -6215,7 +6250,7 @@ checksum = "4c38e3aecd2b21cb3959637b883bb3714bc7e43f0268b9a29d3743ee3e55cdd2" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -6272,7 +6307,7 @@ checksum = "475e68978dc5b743f2f40d8e0a8fdc83f1c5e78cbf4b8fa5e74e73beebc340de" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -6324,8 +6359,8 @@ dependencies = [ "futures-core", "futures-util", "http", - "http-body 0.4.0", - "hyper 0.14.4", + "http-body 0.4.1", + "hyper 0.14.5", "hyper-tls 0.5.0", "ipnet", "js-sys", @@ -6338,7 +6373,7 @@ dependencies = [ "serde", "serde_json", "serde_urlencoded", - "tokio 1.3.0", + "tokio 1.4.0", "tokio-native-tls", "url 2.2.1", "wasm-bindgen", @@ -6447,7 +6482,7 @@ dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", "rust-embed-utils", - "syn 1.0.64", + "syn 1.0.68", "walkdir", ] @@ -6511,6 +6546,12 @@ dependencies = [ "webpki", ] +[[package]] +name = "rustversion" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb5d2a036dc6d2d8fd16fde3498b04306e29bd193bf306a57427019b823d5acd" + [[package]] name = "rusty-fork" version = "0.3.0" @@ -6552,8 +6593,8 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4da5fcb054c46f5a5dff833b129285a93d3f0179531735e6c866e8cc307d2020" dependencies = [ - "futures 0.3.12", - "pin-project 0.4.27", + "futures 0.3.13", + "pin-project 0.4.28", "static_assertions", ] @@ -6582,7 +6623,7 @@ dependencies = [ name = "sc-peerset" version = "1.0.0-beta.4" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "libp2p", "log 0.4.14", "rand 0.8.3", @@ -6643,9 +6684,9 @@ dependencies = [ [[package]] name = "security-framework" -version = "2.1.2" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d493c5f39e02dfb062cd8f33301f90f9b13b650e8c1b1d0fd75c19dd64bff69d" +checksum = "3670b1d2fdf6084d192bc71ead7aabe6c06aa2ea3fbd9cc3ac111fa5c2b1bd84" dependencies = [ "bitflags", "core-foundation", @@ -6656,9 +6697,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee48cdde5ed250b0d3252818f646e174ab414036edb884dde62d80a3ac6082d" +checksum = "3676258fd3cfe2c9a0ec99ce3038798d847ce3e4bb17746373eb9f0f1ac16339" dependencies = [ "core-foundation-sys", "libc", @@ -6802,7 +6843,7 @@ checksum = "b093b7a2bb58203b5da3056c05b4ec1fed827dcfdb37347a8841695263b3d06d" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -6831,10 +6872,11 @@ dependencies = [ [[package]] name = "serde_with" -version = "1.6.4" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b44be9227e214a0420707c9ca74c2d4991d9955bae9415a8f93f05cebf561be5" +checksum = "e557c650adfb38b32a5aec07082053253c703bc3cec654b27a5dbcf61995bb9b" dependencies = [ + "rustversion", "serde", "serde_with_macros", ] @@ -6848,7 +6890,7 @@ dependencies = [ "darling 0.12.2", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -6931,6 +6973,16 @@ dependencies = [ "opaque-debug 0.3.0", ] +[[package]] +name = "shared_child" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6be9f7d5565b1483af3e72975e2dee33879b3b86bd48c0929fccf6585d79e65a" +dependencies = [ + "libc", + "winapi 0.3.9", +] + [[package]] name = "shell-words" version = "1.0.0" @@ -6956,7 +7008,7 @@ checksum = "7fdf1b9db47230893d76faad238fd6097fd6d6a9245cd7a4d90dbd639536bbd2" [[package]] name = "short-hex-str" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "diem-workspace-hack", "mirai-annotations", @@ -6965,6 +7017,16 @@ dependencies = [ "thiserror", ] +[[package]] +name = "signal-hook" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef33d6d0cd06e0840fba9985aab098c147e67e05cee14d412d3345ed14ff30ac" +dependencies = [ + "libc", + "signal-hook-registry", +] + [[package]] name = "signal-hook-registry" version = "1.3.0" @@ -7056,6 +7118,16 @@ dependencies = [ "winapi 0.3.9", ] +[[package]] +name = "socket2" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e3dfc207c526015c632472a77be09cf1b6e46866581aecae5cc38fb4235dea2" +dependencies = [ + "libc", + "winapi 0.3.9", +] + [[package]] name = "soketto" version = "0.4.2" @@ -7065,7 +7137,7 @@ dependencies = [ "base64 0.12.3", "bytes 0.5.6", "flate2", - "futures 0.3.12", + "futures 0.3.13", "httparse", "log 0.4.14", "rand 0.7.3", @@ -7076,7 +7148,7 @@ dependencies = [ name = "sp-utils" version = "1.0.0-beta.4" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "futures-core", "lazy_static", "once_cell", @@ -7099,9 +7171,9 @@ checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" [[package]] name = "standback" -version = "0.2.15" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2beb4d1860a61f571530b3f855a1b538d0200f7871c63331ecd6f17b1f014f8" +checksum = "e113fb6f3de07a243d434a56ec6f186dfd51cb08448239fe7bcae73f87ff28ff" dependencies = [ "version_check 0.9.3", ] @@ -7113,7 +7185,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "hex", "parking_lot 0.11.1", "rand 0.8.3", @@ -7135,7 +7207,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "async-trait", - "futures 0.3.12", + "futures 0.3.13", "hex", "rand 0.8.3", "rand_core 0.6.2", @@ -7154,7 +7226,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "starcoin-account", "starcoin-account-api", "starcoin-chain-notify", @@ -7195,7 +7267,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "hex", "network-api", "once_cell", @@ -7261,7 +7333,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "async-trait", - "futures 0.3.12", + "futures 0.3.13", "network-api", "rand 0.8.3", "rand_core 0.6.2", @@ -7281,7 +7353,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "once_cell", "parking_lot 0.11.1", @@ -7325,7 +7397,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "async-trait", - "futures 0.3.12", + "futures 0.3.13", "rand 0.8.3", "rand_core 0.6.2", "serde", @@ -7353,7 +7425,7 @@ dependencies = [ "crossbeam-channel 0.5.1", "errmapgen", "forkable-jellyfish-merkle", - "futures 0.3.12", + "futures 0.3.13", "hex", "network-api", "network-p2p-types", @@ -7433,7 +7505,7 @@ dependencies = [ "anyhow", "byteorder 1.4.3", "cryptonight-rs", - "futures 0.3.12", + "futures 0.3.13", "hex", "once_cell", "proptest", @@ -7476,7 +7548,7 @@ version = "1.0.0-beta.4" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -7584,7 +7656,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "ascii", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "rust-embed", @@ -7637,7 +7709,7 @@ name = "starcoin-generator" version = "1.0.0-beta.4" dependencies = [ "anyhow", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "scmd", @@ -7722,7 +7794,7 @@ name = "starcoin-metrics" version = "1.0.0-beta.4" dependencies = [ "anyhow", - "futures 0.3.12", + "futures 0.3.13", "hyper 0.13.10", "once_cell", "prometheus", @@ -7738,7 +7810,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "once_cell", @@ -7787,7 +7859,7 @@ dependencies = [ "async-std", "byteorder 1.4.3", "dyn-clone", - "futures 0.3.12", + "futures 0.3.13", "futures-channel", "futures-timer", "hex", @@ -7853,7 +7925,7 @@ dependencies = [ "bytes 1.0.1", "derive_more", "fnv", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "log 0.4.14", @@ -7894,7 +7966,7 @@ dependencies = [ "api-limiter", "bcs-ext", "bytes 1.0.1", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "network-api", @@ -7938,7 +8010,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "network-rpc-core", "network-rpc-derive", "once_cell", @@ -7962,7 +8034,7 @@ dependencies = [ "async-trait", "backtrace", "chrono", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "network-api", "network-rpc-core", @@ -8010,7 +8082,7 @@ dependencies = [ "anyhow", "async-trait", "backtrace", - "futures 0.3.12", + "futures 0.3.13", "serde", "starcoin-config", "starcoin-consensus", @@ -8031,7 +8103,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "once_cell", "parking_lot 0.11.1", "starcoin-accumulator", @@ -8091,7 +8163,7 @@ dependencies = [ "anyhow", "async-trait", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "hex", "jsonrpc-core", "jsonrpc-core-client", @@ -8126,7 +8198,7 @@ dependencies = [ "anyhow", "async-std", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "jsonrpc-client-transports", @@ -8165,7 +8237,7 @@ name = "starcoin-rpc-middleware" version = "1.0.0-beta.4" dependencies = [ "anyhow", - "futures 0.3.12", + "futures 0.3.13", "jsonrpc-core", "once_cell", "rand 0.8.3", @@ -8185,7 +8257,7 @@ dependencies = [ "api-limiter", "bcs-ext", "dashmap", - "futures 0.3.12", + "futures 0.3.13", "futures-channel", "governor", "hex", @@ -8253,7 +8325,7 @@ dependencies = [ "anyhow", "async-std", "async-trait", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "log 0.4.14", "once_cell", @@ -8284,7 +8356,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "async-trait", - "futures 0.3.12", + "futures 0.3.13", "starcoin-config", "starcoin-crypto", "starcoin-logger", @@ -8378,7 +8450,7 @@ dependencies = [ "async-trait", "bcs-ext", "forkable-jellyfish-merkle", - "futures 0.3.12", + "futures 0.3.13", "futures-retry", "futures-timer", "hex", @@ -8387,7 +8459,7 @@ dependencies = [ "network-rpc-core", "once_cell", "parking_lot 0.11.1", - "pin-project 1.0.5", + "pin-project 1.0.6", "pin-utils", "rand 0.8.3", "starcoin-account-api", @@ -8472,7 +8544,7 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "ctrlc", - "futures 0.3.12", + "futures 0.3.13", "starcoin-account-api", "starcoin-config", "starcoin-crypto", @@ -8493,7 +8565,7 @@ dependencies = [ "anyhow", "async-trait", "forkable-jellyfish-merkle", - "futures 0.3.12", + "futures 0.3.13", "futures-channel", "linked-hash-map", "log 0.4.14", @@ -8562,7 +8634,7 @@ dependencies = [ "byteorder 1.4.3", "bytes 1.0.1", "forkable-jellyfish-merkle", - "futures 0.3.12", + "futures 0.3.13", "hex", "itertools 0.10.0", "mirai-annotations", @@ -8710,7 +8782,7 @@ dependencies = [ "actix", "actix-rt", "anyhow", - "futures 0.3.12", + "futures 0.3.13", "log 0.4.14", "starcoin-logger", "stest-macro", @@ -8727,7 +8799,7 @@ dependencies = [ "darling 0.10.2", "quote 1.0.9", "stest", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -8746,12 +8818,12 @@ version = "1.0.0-beta.4" dependencies = [ "anyhow", "async-std", - "futures 0.3.12", + "futures 0.3.13", "futures-retry", "futures-timer", "log 0.4.14", "parking_lot 0.11.1", - "pin-project 0.4.27", + "pin-project 0.4.28", "pin-utils", "serde", "starcoin-logger", @@ -8826,7 +8898,7 @@ dependencies = [ "proc-macro-error", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -8871,9 +8943,9 @@ dependencies = [ [[package]] name = "syn" -version = "1.0.64" +version = "1.0.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fd9d1e9976102a03c542daa2eff1b43f9d72306342f3f8b3ed5fb8908195d6f" +checksum = "3ce15dd3ed8aa2f8eeac4716d6ef5ab58b6b9256db41d7e1a0224c2788e8fd87" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", @@ -8897,7 +8969,7 @@ checksum = "b834f2d66f734cb897113e34aaff2f1ab4719ca946f9a7358dba8f8064148701" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", "unicode-xid 0.2.1", ] @@ -8994,7 +9066,7 @@ dependencies = [ "async-trait", "backtrace", "bcs-ext", - "futures 0.3.12", + "futures 0.3.13", "futures-timer", "hex", "network-api", @@ -9044,6 +9116,28 @@ dependencies = [ "tokio 0.2.25", ] +[[package]] +name = "testrunner" +version = "0.1.0" +source = "git+https://github.com/diem/diem-devtools?branch=main#bf9dae41f8afc8b27fbf7a2f7bb5834b7f8e6db9" +dependencies = [ + "aho-corasick", + "anyhow", + "atty", + "camino", + "crossbeam-channel 0.5.1", + "duct", + "num_cpus", + "once_cell", + "quick-junit", + "rayon", + "serde", + "serde_json", + "signal-hook", + "structopt 0.3.21", + "termcolor", +] + [[package]] name = "testsuite" version = "1.0.0-beta.4" @@ -9126,7 +9220,7 @@ checksum = "7765189610d8241a44529806d6fd1f2e0a08734313a35d5b3a556f92b381f3c0" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -9220,9 +9314,9 @@ dependencies = [ [[package]] name = "tinyvec" -version = "1.1.1" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317cca572a0e89c3ce0ca1f1bdc9369547fe318a683418e42ac8f59d14701023" +checksum = "5b5220f05bb7de7f3f53c7c065e1199b3172696fe2db9f9c4d8ad9b4ee74c342" dependencies = [ "tinyvec_macros", ] @@ -9259,15 +9353,15 @@ dependencies = [ [[package]] name = "tokio" -version = "1.3.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d56477f6ed99e10225f38f9f75f872f29b8b8bd8c0b946f63345bb144e9eeda" +checksum = "134af885d758d645f0f0505c9a8b3f9bf8a348fd822e112ab5248138348f1722" dependencies = [ "autocfg 1.0.1", "bytes 1.0.1", "libc", "memchr", - "mio 0.7.10", + "mio 0.7.11", "num_cpus", "once_cell", "parking_lot 0.11.1", @@ -9328,7 +9422,7 @@ checksum = "e44da00bfc73a25f814cd8d7e57a68a5c31b74b3152a0a1d1f590c97ed06265a" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -9339,7 +9433,7 @@ checksum = "caf7b11a536f46a809a8a9f0bb4237020f70ecbf115b842360afb127ea2fda57" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -9349,7 +9443,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f7d995660bd2b7f8c1568414c1126076c13fbb725c40112dc0120b78eb9b717b" dependencies = [ "native-tls", - "tokio 1.3.0", + "tokio 1.4.0", ] [[package]] @@ -9378,19 +9472,19 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc6844de72e57df1980054b38be3a9f4702aba4858be64dd700181a8a6d0e1b6" dependencies = [ "rustls", - "tokio 1.3.0", + "tokio 1.4.0", "webpki", ] [[package]] name = "tokio-stream" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c535f53c0cfa1acace62995a8994fc9cc1f12d202420da96ff306ee24d576469" +checksum = "e177a5d8c3bf36de9ebe6d58537d8879e964332f93fb3339e43f618c81361af0" dependencies = [ "futures-core", "pin-project-lite 0.2.6", - "tokio 1.3.0", + "tokio 1.4.0", ] [[package]] @@ -9457,8 +9551,8 @@ checksum = "e1a5f475f1b9d077ea1017ecbc60890fda8e54942d680ca0b1d2b47cfa2d861b" dependencies = [ "futures-util", "log 0.4.14", - "pin-project 1.0.5", - "tokio 1.3.0", + "pin-project 1.0.6", + "tokio 1.4.0", "tungstenite", ] @@ -9479,9 +9573,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.6.4" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec31e5cc6b46e653cf57762f36f71d5e6386391d88a72fd6db4508f8f676fb29" +checksum = "5143d049e85af7fbc36f5454d990e62c2df705b3589f123b71f441b6b59f443f" dependencies = [ "bytes 1.0.1", "futures-core", @@ -9489,7 +9583,7 @@ dependencies = [ "futures-sink", "log 0.4.14", "pin-project-lite 0.2.6", - "tokio 1.3.0", + "tokio 1.4.0", ] [[package]] @@ -9537,7 +9631,7 @@ checksum = "c42e6fa53307c8a17e4ccd4dc81cf5ec38db9209f59b222210375b54ee40d1e2" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", ] [[package]] @@ -9555,7 +9649,7 @@ version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2" dependencies = [ - "pin-project 1.0.5", + "pin-project 1.0.6", "tracing", ] @@ -9604,7 +9698,7 @@ dependencies = [ "async-trait", "cfg-if 1.0.0", "enum-as-inner", - "futures 0.3.12", + "futures 0.3.13", "idna 0.2.2", "lazy_static", "log 0.4.14", @@ -9622,7 +9716,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "710f593b371175db53a26d0b38ed2978fafb9e9e8d3868b1acd753ea18df0ceb" dependencies = [ "cfg-if 0.1.10", - "futures 0.3.12", + "futures 0.3.13", "ipconfig", "lazy_static", "log 0.4.14", @@ -9912,9 +10006,9 @@ checksum = "b00bca6106a5e23f3eee943593759b7fcddb00554332e856d990c893966879fb" [[package]] name = "vec-arena" -version = "1.0.0" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eafc1b9b2dfc6f5529177b62cf806484db55b32dc7c9658a118e11bbeb33061d" +checksum = "34b2f665b594b07095e3ac3f718e13c2197143416fae4c5706cffb7b1af8d7f1" [[package]] name = "vec_map" @@ -9937,7 +10031,7 @@ checksum = "5fecdca9a5291cc2b8dcf7dc02453fee791a280f3743cb0905f8822ae463b3fe" [[package]] name = "vm" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "diem-crypto", @@ -9975,9 +10069,9 @@ checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" [[package]] name = "walkdir" -version = "2.3.1" +version = "2.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "777182bc735b6424e1a57516d35ed72cb8019d85c8c9bf536dccb3445c1a2f7d" +checksum = "808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56" dependencies = [ "same-file", "winapi 0.3.9", @@ -9996,33 +10090,32 @@ dependencies = [ [[package]] name = "warp" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dafd0aac2818a94a34df0df1100a7356c493d8ede4393875fd0b5c51bb6bc80" +checksum = "332d47745e9a0c38636dbd454729b147d16bd1ed08ae67b3ab281c4506771054" dependencies = [ "bytes 1.0.1", - "futures 0.3.12", + "futures 0.3.13", "headers", "http", - "hyper 0.14.4", + "hyper 0.14.5", "log 0.4.14", "mime 0.3.16", "mime_guess", "multipart", "percent-encoding 2.1.0", - "pin-project 1.0.5", + "pin-project 1.0.6", "scoped-tls", "serde", "serde_json", "serde_urlencoded", - "tokio 1.3.0", + "tokio 1.4.0", "tokio-rustls", "tokio-stream", "tokio-tungstenite", - "tokio-util 0.6.4", + "tokio-util 0.6.5", "tower-service", "tracing", - "tracing-futures", ] [[package]] @@ -10039,9 +10132,9 @@ checksum = "1a143597ca7c7793eff794def352d41792a93c481eb1042423ff7ff72ba2c31f" [[package]] name = "wasm-bindgen" -version = "0.2.71" +version = "0.2.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee1280240b7c461d6a0071313e08f34a60b0365f14260362e5a2b17d1d31aa7" +checksum = "83240549659d187488f91f33c0f8547cbfef0b2088bc470c116d1d260ef623d9" dependencies = [ "cfg-if 1.0.0", "serde", @@ -10051,24 +10144,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.71" +version = "0.2.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b7d8b6942b8bb3a9b0e73fc79b98095a27de6fa247615e59d096754a3bc2aa8" +checksum = "ae70622411ca953215ca6d06d3ebeb1e915f0f6613e3b495122878d7ebec7dae" dependencies = [ "bumpalo", "lazy_static", "log 0.4.14", "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.21" +version = "0.4.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e67a5806118af01f0d9045915676b22aaebecf4178ae7021bc171dab0b897ab" +checksum = "81b8b767af23de6ac18bf2168b690bed2902743ddf0fb39252e36f9e2bfc63ea" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -10078,9 +10171,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.71" +version = "0.2.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5ac38da8ef716661f0f36c0d8320b89028efe10c7c0afde65baffb496ce0d3b" +checksum = "3e734d91443f177bfdb41969de821e15c516931c3c3db3d318fa1b68975d0f6f" dependencies = [ "quote 1.0.9", "wasm-bindgen-macro-support", @@ -10088,22 +10181,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.71" +version = "0.2.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc053ec74d454df287b9374ee8abb36ffd5acb95ba87da3ba5b7d3fe20eb401e" +checksum = "d53739ff08c8a68b0fdbcd54c372b8ab800b1449ab3c9d706503bc7dd1621b2c" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.71" +version = "0.2.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d6f8ec44822dd71f5f221a5847fb34acd9060535c1211b70a05844c0f6383b1" +checksum = "d9a543ae66aa233d14bb765ed9af4a33e81b8b58d1584cf1b47ff8cd0b9e4489" [[package]] name = "wasm-timer" @@ -10111,7 +10204,7 @@ version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "be0ecb0db480561e9a7642b5d3e4187c128914e58aa84330b9493e3eb68c5e7f" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "js-sys", "parking_lot 0.11.1", "pin-utils", @@ -10122,9 +10215,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.48" +version = "0.3.50" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec600b26223b2948cedfde2a0aa6756dcf1fef616f43d7b3097aaf53a6c4d92b" +checksum = "a905d57e488fec8861446d3393670fb50d27a262344013181c2cdf9fff5481be" dependencies = [ "js-sys", "wasm-bindgen", @@ -10142,9 +10235,9 @@ dependencies = [ [[package]] name = "webpki-roots" -version = "0.21.0" +version = "0.21.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82015b7e0b8bad8185994674a13a93306bea76cf5a16c5a181382fd3a5ec2376" +checksum = "aabe153544e473b775453675851ecc86863d2a81d786d741f6b76778f2a48940" dependencies = [ "webpki", ] @@ -10304,10 +10397,11 @@ checksum = "85e60b0d1b5f99db2556934e21937020776a5d31520bf169e851ac44e6420214" [[package]] name = "x" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "anyhow", "camino", + "cargo_metadata", "chrono", "colored-diff", "determinator", @@ -10323,6 +10417,7 @@ dependencies = [ "serde", "serde_json", "structopt 0.3.21", + "testrunner", "toml", "x-core", "x-lint", @@ -10331,7 +10426,7 @@ dependencies = [ [[package]] name = "x-core" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "camino", "determinator", @@ -10349,7 +10444,7 @@ dependencies = [ [[package]] name = "x-lint" version = "0.1.0" -source = "git+https://github.com/starcoinorg/diem?rev=f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425#f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" +source = "git+https://github.com/starcoinorg/diem?rev=bfd7b336d14858d288e908636853949693642bcf#bfd7b336d14858d288e908636853949693642bcf" dependencies = [ "camino", "guppy", @@ -10397,7 +10492,7 @@ version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1cc7bd8c983209ed5d527f44b01c41b7dc146fd960c61cf9e1d25399841dc271" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "log 0.4.14", "nohash-hasher", "parking_lot 0.11.1", @@ -10411,7 +10506,7 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e7d9028f208dd5e63c614be69f115c1b53cacc1111437d4c765185856666c107" dependencies = [ - "futures 0.3.12", + "futures 0.3.13", "log 0.4.14", "nohash-hasher", "parking_lot 0.11.1", @@ -10436,6 +10531,6 @@ checksum = "c3f369ddb18862aba61aa49bf31e74d29f0f162dec753063200e1dc084345d16" dependencies = [ "proc-macro2 1.0.26", "quote 1.0.9", - "syn 1.0.64", + "syn 1.0.68", "synstructure", ] diff --git a/chain/api/src/errors.rs b/chain/api/src/errors.rs index 4d35867c0e..1b0a8cfc06 100644 --- a/chain/api/src/errors.rs +++ b/chain/api/src/errors.rs @@ -63,6 +63,7 @@ pub enum ConnectBlockError { VerifyBlockFailed(VerifyBlockField, Error), } +#[allow(clippy::from_over_into)] impl Into for &ConnectBlockError { fn into(self) -> ReputationChange { match self { diff --git a/chain/api/src/message.rs b/chain/api/src/message.rs index abb946d47b..a31b75358e 100644 --- a/chain/api/src/message.rs +++ b/chain/api/src/message.rs @@ -62,6 +62,7 @@ impl ServiceRequest for ChainRequest { type Response = Result; } +#[allow(clippy::upper_case_acronyms)] pub enum ChainResponse { BlockTemplate(Box), Block(Box), diff --git a/chain/tests/test_block_chain.rs b/chain/tests/test_block_chain.rs index 12121ffcb3..e294568464 100644 --- a/chain/tests/test_block_chain.rs +++ b/chain/tests/test_block_chain.rs @@ -205,6 +205,7 @@ fn product_a_block(branch: &BlockChain, miner: &AccountInfo, uncles: Vec, } +#[allow(clippy::upper_case_acronyms)] pub struct TPSCommand; impl CommandAction for TPSCommand { diff --git a/cmd/starcoin/src/chain/uncle/epoch_uncle_summary_by_number.rs b/cmd/starcoin/src/chain/uncle/epoch_uncle_summary_by_number.rs index 0991486b45..e027749200 100644 --- a/cmd/starcoin/src/chain/uncle/epoch_uncle_summary_by_number.rs +++ b/cmd/starcoin/src/chain/uncle/epoch_uncle_summary_by_number.rs @@ -25,9 +25,8 @@ impl CommandAction for EpochUncleSummaryByNumberCommand { &self, ctx: &ExecContext, ) -> Result { - Ok(ctx - .state() + ctx.state() .client() - .epoch_uncle_summary_by_number(ctx.opt().number)?) + .epoch_uncle_summary_by_number(ctx.opt().number) } } diff --git a/cmd/starcoin/src/debug/txpool_status.rs b/cmd/starcoin/src/debug/txpool_status.rs index 4dbff060db..671eaf4015 100644 --- a/cmd/starcoin/src/debug/txpool_status.rs +++ b/cmd/starcoin/src/debug/txpool_status.rs @@ -26,6 +26,6 @@ impl CommandAction for TxPoolStatusCommand { ctx: &ExecContext, ) -> Result { let client = ctx.state().client(); - Ok(client.txpool_status()?) + client.txpool_status() } } diff --git a/cmd/starcoin/src/dev/get_coin_cmd.rs b/cmd/starcoin/src/dev/get_coin_cmd.rs index 881f6a7da3..5ad2fd642b 100644 --- a/cmd/starcoin/src/dev/get_coin_cmd.rs +++ b/cmd/starcoin/src/dev/get_coin_cmd.rs @@ -98,6 +98,6 @@ impl CommandAction for GetCoinCommand { if !opt.no_blocking { ctx.state().watch_txn(id)?; } - Ok(txn.try_into()?) + txn.try_into() } } diff --git a/cmd/starcoin/src/dev/sign_txn_helper.rs b/cmd/starcoin/src/dev/sign_txn_helper.rs index 6842a96320..bbaaf5d3c1 100644 --- a/cmd/starcoin/src/dev/sign_txn_helper.rs +++ b/cmd/starcoin/src/dev/sign_txn_helper.rs @@ -69,7 +69,7 @@ pub fn get_dao_config(cli_state: &CliState) -> Result { let client = cli_state.client(); let chain_state_reader = RemoteStateReader::new(client)?; let account_state_reader = AccountStateReader::new(&chain_state_reader); - Ok(account_state_reader + account_state_reader .get_on_chain_config::()? - .ok_or_else(|| format_err!("DaoConfig not exist on chain."))?) + .ok_or_else(|| format_err!("DaoConfig not exist on chain.")) } diff --git a/cmd/starcoin/src/txpool/mod.rs b/cmd/starcoin/src/txpool/mod.rs index 2bd7ee36e7..cacc9f07df 100644 --- a/cmd/starcoin/src/txpool/mod.rs +++ b/cmd/starcoin/src/txpool/mod.rs @@ -85,6 +85,6 @@ impl CommandAction for TxPoolStatusCommand { ctx: &ExecContext, ) -> Result { let client = ctx.state().client(); - Ok(client.txpool_status()?) + client.txpool_status() } } diff --git a/commons/accumulator/src/inmemory/mod.rs b/commons/accumulator/src/inmemory/mod.rs index 472c1911cb..4ebc38784c 100644 --- a/commons/accumulator/src/inmemory/mod.rs +++ b/commons/accumulator/src/inmemory/mod.rs @@ -230,7 +230,7 @@ impl InMemoryAccumulator { current_num_leaves += remaining_new_leaves; current_subtree_roots.extend(subtree_iter); - Ok(Self::new(current_subtree_roots, current_num_leaves)?) + Self::new(current_subtree_roots, current_num_leaves) } /// Returns the root hash of the accumulator. diff --git a/commons/bcs_ext/src/lib.rs b/commons/bcs_ext/src/lib.rs index 071f9d152c..b2c7fad328 100644 --- a/commons/bcs_ext/src/lib.rs +++ b/commons/bcs_ext/src/lib.rs @@ -24,6 +24,7 @@ where bcs::from_bytes(bytes).map_err(|e| e.into()) } +#[allow(clippy::upper_case_acronyms)] pub trait BCSCodec<'a>: Sized { fn encode(&self) -> Result>; fn decode(bytes: &'a [u8]) -> Result; diff --git a/commons/crypto/Cargo.toml b/commons/crypto/Cargo.toml index b8e5a27fe5..9081b213a8 100644 --- a/commons/crypto/Cargo.toml +++ b/commons/crypto/Cargo.toml @@ -11,8 +11,8 @@ serde = { version = "1.0.125" } serde_bytes = "0.11.5" hex = "0.4.3" anyhow = "1.0" -diem-crypto = { package="diem-crypto", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425", features = ["fuzzing"] } -diem-crypto-derive = { package="diem-crypto-derive", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +diem-crypto = { package="diem-crypto", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf", features = ["fuzzing"] } +diem-crypto-derive = { package="diem-crypto-derive", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } bcs-ext = { package="bcs-ext", path = "../bcs_ext" } crypto-macro = { package="starcoin-crypto-macro", path = "./crypto-macro"} rand = "0.8.3" diff --git a/commons/crypto/src/multi_ed25519/multi_shard.rs b/commons/crypto/src/multi_ed25519/multi_shard.rs index d780560516..72402946a4 100644 --- a/commons/crypto/src/multi_ed25519/multi_shard.rs +++ b/commons/crypto/src/multi_ed25519/multi_shard.rs @@ -145,6 +145,7 @@ impl MultiEd25519KeyShard { impl ValidCryptoMaterial for MultiEd25519KeyShard { /// Serialize a MultiEd25519PrivateKeyShard. + #[allow(clippy::vec_init_then_push)] fn to_bytes(&self) -> Vec { let mut bytes: Vec = vec![]; bytes.push(self.public_keys.len() as u8); @@ -320,6 +321,7 @@ impl MultiEd25519SignatureShard { } } +#[allow(clippy::from_over_into)] impl Into> for &MultiEd25519SignatureShard { fn into(self) -> Vec<(Ed25519Signature, u8)> { let signatures = self.signature.signatures(); @@ -339,6 +341,7 @@ impl Into> for &MultiEd25519SignatureShard { } } +#[allow(clippy::from_over_into)] impl Into for MultiEd25519SignatureShard { fn into(self) -> MultiEd25519Signature { self.signature diff --git a/commons/forkable-jellyfish-merkle/src/lib.rs b/commons/forkable-jellyfish-merkle/src/lib.rs index f187b722bc..f22e58a40c 100644 --- a/commons/forkable-jellyfish-merkle/src/lib.rs +++ b/commons/forkable-jellyfish-merkle/src/lib.rs @@ -551,7 +551,7 @@ where } else { // Else create the new leaf node with the same address but new blob content. tree_cache.delete_node(&node_key, true /* is_leaf */); - return Ok(Self::create_leaf_node(key, blob, tree_cache)?); + return Self::create_leaf_node(key, blob, tree_cache); } } diff --git a/commons/forkable-jellyfish-merkle/src/node_type/node_type_test.rs b/commons/forkable-jellyfish-merkle/src/node_type/node_type_test.rs index 474ac6c7b5..d755f5e7a6 100644 --- a/commons/forkable-jellyfish-merkle/src/node_type/node_type_test.rs +++ b/commons/forkable-jellyfish-merkle/src/node_type/node_type_test.rs @@ -722,6 +722,7 @@ impl NaiveInternalNode { BinaryTreeNode::new_internal(begin, width, left, right) } + #[allow(clippy::vec_init_then_push)] fn get_child_with_siblings(&self, n: u8) -> (Option, Vec) { let mut current_node = Rc::clone(&self.root); let mut siblings = Vec::new(); diff --git a/commons/forkable-jellyfish-merkle/src/tree_cache/mod.rs b/commons/forkable-jellyfish-merkle/src/tree_cache/mod.rs index d0addd6b01..cacf67335b 100644 --- a/commons/forkable-jellyfish-merkle/src/tree_cache/mod.rs +++ b/commons/forkable-jellyfish-merkle/src/tree_cache/mod.rs @@ -261,6 +261,7 @@ where } } +#[allow(clippy::from_over_into)] impl<'a, R, K> Into<(Vec, TreeUpdateBatch)> for TreeCache<'a, R, K> where R: 'a + TreeReader, diff --git a/commons/logger/src/lib.rs b/commons/logger/src/lib.rs index 1e5e73fe12..38b8d9ce1b 100644 --- a/commons/logger/src/lib.rs +++ b/commons/logger/src/lib.rs @@ -320,7 +320,7 @@ pub fn init_with_default_level( let config = build_config(arg.clone()).expect("build log config fail."); let handle = match log4rs::init_config(config) { Ok(handle) => handle, - Err(e) => panic!(e.to_string()), + Err(e) => panic!("{}", e.to_string()), }; let logger_handle = LoggerHandle::new(arg, handle); diff --git a/commons/proptest-helpers/Cargo.toml b/commons/proptest-helpers/Cargo.toml index bfc9c54ffc..ce22f2de58 100644 --- a/commons/proptest-helpers/Cargo.toml +++ b/commons/proptest-helpers/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" [dependencies] crossbeam = "0.7.3" -diem-proptest-helpers = { package="diem-proptest-helpers", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +diem-proptest-helpers = { package="diem-proptest-helpers", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } proptest = "1.0.0" proptest-derive = "0.3.0" diff --git a/commons/scmd/src/result.rs b/commons/scmd/src/result.rs index 971b58738d..490ff812e7 100644 --- a/commons/scmd/src/result.rs +++ b/commons/scmd/src/result.rs @@ -9,6 +9,7 @@ use serde_json::{json, Value}; use std::str::FromStr; #[derive(Copy, Clone, Debug)] +#[allow(clippy::upper_case_acronyms)] pub enum OutputFormat { JSON, TABLE, diff --git a/commons/service-registry/tests/common/shared_data_service.rs b/commons/service-registry/tests/common/shared_data_service.rs index 263ad39606..3fdba671b8 100644 --- a/commons/service-registry/tests/common/shared_data_service.rs +++ b/commons/service-registry/tests/common/shared_data_service.rs @@ -9,6 +9,7 @@ use std::collections::HashMap; use std::sync::{Arc, Mutex}; #[derive(Default)] +#[allow(clippy::upper_case_acronyms)] pub struct DB { data: Mutex>, } diff --git a/config/Cargo.toml b/config/Cargo.toml index f9477b44f4..af2d979eea 100644 --- a/config/Cargo.toml +++ b/config/Cargo.toml @@ -30,7 +30,7 @@ starcoin-vm-types = { path = "../vm/types" } starcoin-uint = { path = "../types/uint" } network-p2p-types = { path = "../network-p2p/types"} starcoin-logger = {path = "../commons/logger", package="starcoin-logger"} -diem-temppath = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +diem-temppath = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } starcoin-system = {path = "../commons/system", package="starcoin-system"} network-api = {path = "../network/api", package="network-api"} stdlib = { path = "../vm/stdlib"} diff --git a/config/src/genesis_config.rs b/config/src/genesis_config.rs index 068b869965..8b8c25222a 100644 --- a/config/src/genesis_config.rs +++ b/config/src/genesis_config.rs @@ -53,6 +53,7 @@ use std::sync::Arc; Serialize, )] #[repr(u8)] +#[allow(clippy::upper_case_acronyms)] pub enum BuiltinNetworkID { /// A ephemeral network just for unit test. Test = 255, @@ -195,6 +196,7 @@ impl From for ChainNetwork { } #[derive(Clone, Debug, PartialEq, Deserialize, Serialize)] +#[allow(clippy::upper_case_acronyms)] pub struct CustomNetworkID { chain_name: String, chain_id: ChainId, @@ -238,6 +240,7 @@ impl FromStr for CustomNetworkID { } #[derive(Clone, Debug, PartialEq)] +#[allow(clippy::upper_case_acronyms)] pub enum ChainNetworkID { Builtin(BuiltinNetworkID), Custom(CustomNetworkID), diff --git a/config/src/lib.rs b/config/src/lib.rs index 741b1b4e53..c7d5fd52bf 100644 --- a/config/src/lib.rs +++ b/config/src/lib.rs @@ -127,6 +127,7 @@ where } #[derive(Debug, Clone, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub enum Connect { /// Connect by ipc file path, if Path is absent, use default ipc file. IPC(Option), diff --git a/config/src/network_config.rs b/config/src/network_config.rs index 1cc2d42e26..2d0fa0ebb9 100644 --- a/config/src/network_config.rs +++ b/config/src/network_config.rs @@ -148,6 +148,7 @@ impl FromStr for Seeds { Ok(Seeds(seeds)) } } +#[allow(clippy::from_over_into)] impl Into> for Seeds { fn into(self) -> Vec { self.0 diff --git a/config/src/rpc_config.rs b/config/src/rpc_config.rs index 031ae1a71b..f5d46ae83e 100644 --- a/config/src/rpc_config.rs +++ b/config/src/rpc_config.rs @@ -382,6 +382,7 @@ impl ListenAddress { } } +#[allow(clippy::from_over_into)] impl Into for ListenAddress { fn into(self) -> SocketAddr { SocketAddr::new(self.address, self.port) diff --git a/devtools/x/Cargo.toml b/devtools/x/Cargo.toml index bd4b42f2d6..56742964f0 100644 --- a/devtools/x/Cargo.toml +++ b/devtools/x/Cargo.toml @@ -23,7 +23,7 @@ globset = "0.4.6" regex = "1.4.3" rayon = "1.5.0" indexmap = "1.6.2" -x-core = { package="x-core", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -x-lint = { package="x-lint", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -diem-workspace-hack = { package="diem-workspace-hack", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -diem-x = { package="x", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +x-core = { package="x-core", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +x-lint = { package="x-lint", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +diem-workspace-hack = { package="diem-workspace-hack", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +diem-x = { package="x", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } diff --git a/devtools/x/src/main.rs b/devtools/x/src/main.rs index 48fcf26c86..3a5b854f63 100644 --- a/devtools/x/src/main.rs +++ b/devtools/x/src/main.rs @@ -57,6 +57,10 @@ pub mod playground { } pub mod test; +pub mod nextest { + pub use diem_x::nextest::*; +} + pub mod cargo { pub use diem_x::cargo::*; } @@ -105,6 +109,9 @@ enum Command { #[structopt(name = "test")] /// Run tests Test(test::Args), + #[structopt(name = "nextest")] + /// Run tests with new test runner + Nextest(nextest::Args), #[structopt(name = "tools")] /// Run tests Tools(tools::Args), @@ -148,6 +155,7 @@ fn main() -> Result<()> { match args.cmd { Command::Tools(args) => tools::run(args, xctx), Command::Test(args) => test::run(args, xctx), + Command::Nextest(args) => nextest::run(args, xctx), Command::Build(args) => build::run(args, xctx), Command::ChangedSince(args) => changed_since::run(args, xctx), Command::Check(args) => check::run(args, xctx), diff --git a/devtools/x/src/test.rs b/devtools/x/src/test.rs index fb80916b23..f1c34e892e 100644 --- a/devtools/x/src/test.rs +++ b/devtools/x/src/test.rs @@ -15,7 +15,7 @@ use log::info; use std::{ ffi::OsString, fs::create_dir_all, - path::PathBuf, + path::{Path, PathBuf}, process::{Command, Stdio}, }; use structopt::StructOpt; @@ -27,6 +27,9 @@ pub struct Args { #[structopt(long, short)] /// Skip running expensive diem testsuite integration tests unit: bool, + #[structopt(long)] + /// Only run doctests + doc: bool, #[structopt(flatten)] pub(crate) build_args: BuildArgs, #[structopt(long)] @@ -94,6 +97,9 @@ pub fn run(mut args: Args, xctx: XContext) -> Result<()> { if args.no_fail_fast { direct_args.push(OsString::from("--no-fail-fast")); }; + if args.doc { + direct_args.push(OsString::from("--doc")); + } let cmd = CargoCommand::Test { cargo_config: xctx.config().cargo_config(), @@ -124,7 +130,7 @@ pub fn run(mut args: Args, xctx: XContext) -> Result<()> { cmd_result } -fn exec_lcov_genhtml(html_lcov_path: &PathBuf) -> Result<()> { +fn exec_lcov_genhtml(html_lcov_path: &Path) -> Result<()> { let mut genhtml = Command::new("genhtml"); let mut lcov_file_path = PathBuf::new(); lcov_file_path.push(html_lcov_path); @@ -151,7 +157,7 @@ fn exec_lcov_genhtml(html_lcov_path: &PathBuf) -> Result<()> { } } -fn exec_lcov(html_lcov_path: &PathBuf) -> Result<()> { +fn exec_lcov(html_lcov_path: &Path) -> Result<()> { let debug_dir = project_root().join("target/debug/"); let mut lcov_file_path = PathBuf::new(); lcov_file_path.push(html_lcov_path); @@ -189,7 +195,7 @@ fn exec_lcov(html_lcov_path: &PathBuf) -> Result<()> { } } -fn exec_grcov(html_cov_path: &PathBuf) -> Result<()> { +fn exec_grcov(html_cov_path: &Path) -> Result<()> { let debug_dir = project_root().join("target/debug/"); let mut grcov_html = Command::new("grcov"); grcov_html @@ -209,10 +215,6 @@ fn exec_grcov(html_cov_path: &PathBuf) -> Result<()> { .arg("--ignore") .arg("x/*") .arg("--ignore") - .arg("benchmarks/*") - .arg("--ignore") - .arg("vm/transaction-builder-generator") - .arg("--ignore") .arg("testsuite/*") .arg("--ignore-not-existing") .arg("-o") diff --git a/executor/src/account.rs b/executor/src/account.rs index 73f8c98ef7..ad0229fa1e 100644 --- a/executor/src/account.rs +++ b/executor/src/account.rs @@ -647,6 +647,7 @@ impl KeyRotationCapability { /// Returns a transaction to transfer coin from one account to another (possibly new) one, with the /// given arguments. +#[allow(clippy::vec_init_then_push)] pub fn peer_to_peer_txn( sender: &Account, receiver: &Account, @@ -680,6 +681,7 @@ pub fn peer_to_peer_txn( } /// Returns a transaction to create a new account with the given arguments. +#[allow(clippy::vec_init_then_push)] pub fn create_account_txn_sent_as_association( new_account: &Account, seq_num: u64, diff --git a/genesis/src/lib.rs b/genesis/src/lib.rs index d1843b9a2f..dffbc916d7 100644 --- a/genesis/src/lib.rs +++ b/genesis/src/lib.rs @@ -241,9 +241,9 @@ impl Genesis { )?; let startup_info = StartupInfo::new(genesis_chain.current_header().id()); storage.save_startup_info(startup_info)?; - Ok(storage + storage .get_chain_info()? - .ok_or_else(|| format_err!("ChainInfo should exist after genesis block executed."))?) + .ok_or_else(|| format_err!("ChainInfo should exist after genesis block executed.")) } pub fn save

(&self, data_dir: P) -> Result<()> diff --git a/network-p2p/src/service.rs b/network-p2p/src/service.rs index 366c5fcad2..3ad524b5ce 100644 --- a/network-p2p/src/service.rs +++ b/network-p2p/src/service.rs @@ -666,7 +666,7 @@ impl NetworkService { let (tx, rx) = oneshot::channel(); let _ = self .to_worker - .unbounded_send(ServiceToWorkerMsg::AddressByPeerID(peer_id, tx)); + .unbounded_send(ServiceToWorkerMsg::AddressByPeerId(peer_id, tx)); match rx.await { Ok(t) => t, Err(e) => { @@ -953,7 +953,7 @@ enum ServiceToWorkerMsg { NetworkState(oneshot::Sender), KnownPeers(oneshot::Sender>), UpdateChainStatus(Box), - AddressByPeerID(PeerId, oneshot::Sender>), + AddressByPeerId(PeerId, oneshot::Sender>), } /// Main network worker. Must be polled in order for the network to advance. @@ -1041,7 +1041,7 @@ impl Future for NetworkWorker { .user_protocol_mut() .update_chain_status(*status); } - ServiceToWorkerMsg::AddressByPeerID(peer_id, tx) => { + ServiceToWorkerMsg::AddressByPeerId(peer_id, tx) => { let _ = tx.send(this.network_service.get_address(&peer_id)); } } diff --git a/network-p2p/types/src/lib.rs b/network-p2p/types/src/lib.rs index 87fdeefb17..0e9d32a1db 100644 --- a/network-p2p/types/src/lib.rs +++ b/network-p2p/types/src/lib.rs @@ -125,6 +125,7 @@ impl TryFrom for MultiaddrWithPeerId { } } +#[allow(clippy::from_over_into)] impl Into for MultiaddrWithPeerId { fn into(self) -> Multiaddr { self.concat() diff --git a/network-rpc/api/src/lib.rs b/network-rpc/api/src/lib.rs index 25a80d520a..e1c1c10646 100644 --- a/network-rpc/api/src/lib.rs +++ b/network-rpc/api/src/lib.rs @@ -67,6 +67,7 @@ impl RpcRequest for GetBlockHeadersByNumber { } } +#[allow(clippy::from_over_into)] impl Into> for GetBlockHeadersByNumber { fn into(self) -> Vec { let mut numbers = Vec::new(); diff --git a/network-rpc/core/tests/rpc_gen_test.rs b/network-rpc/core/tests/rpc_gen_test.rs index 4f5544e68e..15f539d163 100644 --- a/network-rpc/core/tests/rpc_gen_test.rs +++ b/network-rpc/core/tests/rpc_gen_test.rs @@ -19,6 +19,7 @@ pub struct EchoStruct { } #[net_rpc(client, server)] +#[allow(clippy::upper_case_acronyms)] pub trait KVRpc: Sized + Send + Sync { fn echo_str(&self, peer_id: PeerId, req: String) -> BoxFuture>; fn echo_struct(&self, peer_id: PeerId, req: EchoStruct) -> BoxFuture>; @@ -26,6 +27,7 @@ pub trait KVRpc: Sized + Send + Sync { } #[derive(Default)] +#[allow(clippy::upper_case_acronyms)] struct KVRpcImpl {} impl gen_server::KVRpc for KVRpcImpl { diff --git a/network-rpc/derive/src/to_client.rs b/network-rpc/derive/src/to_client.rs index 40103aeac0..ab2d308da1 100644 --- a/network-rpc/derive/src/to_client.rs +++ b/network-rpc/derive/src/to_client.rs @@ -17,7 +17,7 @@ pub fn generate_client_module(rpc_trait: &ItemTrait) -> anyhow::Result r, - Err(e) => panic!(e) + Err(e) => panic!("{}", e) }; if arg_names.len() < 2 { panic!("network Rpc method must has at least two argument"); diff --git a/network/api/src/messages.rs b/network/api/src/messages.rs index 0483c30afa..841b68d6a2 100644 --- a/network/api/src/messages.rs +++ b/network/api/src/messages.rs @@ -174,6 +174,7 @@ impl PeerTransactionsMessage { } } +#[allow(clippy::from_over_into)] impl Into for PeerTransactionsMessage { fn into(self) -> PeerMessage { PeerMessage::new_transactions(self.peer_id, self.message) @@ -193,6 +194,7 @@ impl PeerCompactBlockMessage { } } +#[allow(clippy::from_over_into)] impl Into for PeerCompactBlockMessage { fn into(self) -> PeerMessage { PeerMessage::new_compact_block(self.peer_id, self.message) diff --git a/rpc/api/src/types.rs b/rpc/api/src/types.rs index 53d08d7771..30bd996841 100644 --- a/rpc/api/src/types.rs +++ b/rpc/api/src/types.rs @@ -174,6 +174,7 @@ pub struct DryRunTransactionRequest { } #[derive(Clone, Debug, Eq, PartialEq)] +#[allow(clippy::upper_case_acronyms)] pub enum ArgumentsView { HumanReadable(Vec), BCS(Vec>>), @@ -257,6 +258,7 @@ impl ScriptData { } } } +#[allow(clippy::from_over_into)] impl Into for ScriptData { fn into(self) -> TransactionPayload { match self.into_data() { @@ -485,6 +487,7 @@ impl From for BlockMetadataView { } } } +#[allow(clippy::from_over_into)] impl Into for BlockMetadataView { fn into(self) -> BlockMetadata { let BlockMetadataView { @@ -695,6 +698,7 @@ impl TransactionInfoView { } #[derive(Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub enum TransactionVMStatus { Executed, OutOfGas, diff --git a/rpc/server/src/module/account_rpc.rs b/rpc/server/src/module/account_rpc.rs index 9bf3339477..e34f7e629e 100644 --- a/rpc/server/src/module/account_rpc.rs +++ b/rpc/server/src/module/account_rpc.rs @@ -230,9 +230,9 @@ where ) -> FutureResult<()> { let account_service = self.account.clone(); let fut = async move { - Ok(account_service + account_service .change_account_password(address, new_password) - .await?) + .await }; Box::pin(fut.map_err(map_err).boxed()) } diff --git a/rpc/server/src/module/chain_rpc.rs b/rpc/server/src/module/chain_rpc.rs index 0da8b3d068..0ddbad2709 100644 --- a/rpc/server/src/module/chain_rpc.rs +++ b/rpc/server/src/module/chain_rpc.rs @@ -68,7 +68,7 @@ where let fut = async move { let result = service.get_block_by_hash(hash).await?; - Ok(result.map(|b| b.try_into()).transpose()?) + result.map(|b| b.try_into()).transpose() } .map_err(map_err); @@ -80,7 +80,7 @@ where let fut = async move { let result = service.main_block_by_number(number).await?; - Ok(result.map(|b| b.try_into()).transpose()?) + result.map(|b| b.try_into()).transpose() } .map_err(map_err); @@ -122,10 +122,10 @@ where } let block = service.main_blocks_by_number(number, count).await?; - Ok(block + block .into_iter() .map(|blk| BlockView::try_from_block(blk, true)) - .collect::, _>>()?) + .collect::, _>>() } .map_err(map_err); diff --git a/rpc/server/src/module/mod.rs b/rpc/server/src/module/mod.rs index 5095326cd2..6dc3ddd11d 100644 --- a/rpc/server/src/module/mod.rs +++ b/rpc/server/src/module/mod.rs @@ -71,6 +71,8 @@ fn convert_to_rpc_error>(err: T) -> jsonrpc_core::Error { /// only traits defined in the current crate can be implemented for arbitrary types. #[derive(Debug)] struct RpcError(jsonrpc_core::Error); + +#[allow(clippy::from_over_into)] impl Into for RpcError { fn into(self) -> jsonrpc_core::Error { self.0 diff --git a/rust-toolchain b/rust-toolchain index ce92a2d3c1..d2d62553b3 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -1 +1 @@ -1.50.0 \ No newline at end of file +1.51.0 \ No newline at end of file diff --git a/state/statedb/src/lib.rs b/state/statedb/src/lib.rs index dc4216673c..9c7f1d9bf0 100644 --- a/state/statedb/src/lib.rs +++ b/state/statedb/src/lib.rs @@ -205,6 +205,7 @@ impl AccountStateObject { } } +#[allow(clippy::upper_case_acronyms)] pub struct ChainStateDB { store: Arc, ///global state tree. diff --git a/storage/src/block/mod.rs b/storage/src/block/mod.rs index a55f8b3150..f58ce9a035 100644 --- a/storage/src/block/mod.rs +++ b/storage/src/block/mod.rs @@ -21,6 +21,7 @@ pub struct FailedBlock { failed: String, } +#[allow(clippy::from_over_into)] impl Into<(Block, Option, String)> for FailedBlock { fn into(self) -> (Block, Option, String) { (self.block, self.peer_id, self.failed) diff --git a/storage/src/db_storage/mod.rs b/storage/src/db_storage/mod.rs index 201ddd778d..115249362d 100644 --- a/storage/src/db_storage/mod.rs +++ b/storage/src/db_storage/mod.rs @@ -13,6 +13,7 @@ use std::collections::HashSet; use std::marker::PhantomData; use std::path::Path; +#[allow(clippy::upper_case_acronyms)] pub struct DBStorage { db: DB, cfs: Vec, diff --git a/storage/src/metrics.rs b/storage/src/metrics.rs index d2ccd75a7f..06c482694a 100644 --- a/storage/src/metrics.rs +++ b/storage/src/metrics.rs @@ -40,6 +40,7 @@ pub static STORAGE_TIMES: Lazy = Lazy::new(|| { pub static CACHE_ITEMS: Lazy = Lazy::new(|| register_uint_gauge!("starcoin_cache_items", "How many items in cache").unwrap()); +#[allow(clippy::upper_case_acronyms)] pub enum ResultType { NONE, SOME, diff --git a/storage/src/storage.rs b/storage/src/storage.rs index 675fdcc29d..cb6f8b0f60 100644 --- a/storage/src/storage.rs +++ b/storage/src/storage.rs @@ -17,6 +17,7 @@ use std::sync::Arc; /// Type alias to improve readability. pub type ColumnFamilyName = &'static str; +#[allow(clippy::upper_case_acronyms)] pub trait KVStore: Send + Sync { fn get(&self, key: &[u8]) -> Result>>; fn multiple_get(&self, keys: Vec>) -> Result>>> { @@ -60,6 +61,7 @@ impl From<&CacheObject> for Option> { ///Storage instance type define #[derive(Clone)] +#[allow(clippy::upper_case_acronyms)] pub enum StorageInstance { CACHE { cache: Arc, @@ -378,6 +380,7 @@ where } } +#[allow(clippy::upper_case_acronyms)] pub trait CodecKVStore: std::marker::Send + std::marker::Sync where K: KeyCodec, @@ -413,6 +416,7 @@ impl KeyCodec for u64 { Ok(self.to_be_bytes().to_vec()) } + #[allow(clippy::redundant_slicing)] fn decode_key(data: &[u8]) -> Result { Ok((&data[..]).read_u64::()?) } diff --git a/sync/src/block_connector/test_illegal_block.rs b/sync/src/block_connector/test_illegal_block.rs index 6d27038ed1..21ecd0842e 100644 --- a/sync/src/block_connector/test_illegal_block.rs +++ b/sync/src/block_connector/test_illegal_block.rs @@ -331,6 +331,7 @@ async fn test_verify_new_epoch_block_uncle_should_none_failed() { } #[stest::test] +#[allow(clippy::vec_init_then_push)] async fn test_verify_can_not_be_uncle_is_member_failed() { let times = 5; let (mut writeable_block_chain_service, node_config, storage) = @@ -362,6 +363,7 @@ async fn test_verify_can_not_be_uncle_is_member_failed() { } #[stest::test] +#[allow(clippy::vec_init_then_push)] async fn test_verify_can_not_be_uncle_check_ancestor_failed() { // 1. chain let times = 7; @@ -418,6 +420,7 @@ async fn test_verify_can_not_be_uncle_check_ancestor_failed() { } } +#[allow(clippy::vec_init_then_push)] async fn test_verify_illegal_uncle_future_timestamp(succ: bool) -> Result { let count = 5; let (mut uncle_header, mut writeable_block_chain_service, node_config, storage) = @@ -450,6 +453,7 @@ async fn test_verify_illegal_uncle_future_timestamp_failed() { } } +#[allow(clippy::vec_init_then_push)] async fn test_verify_illegal_uncle_consensus(succ: bool) -> Result<()> { let mut genesis_config = BuiltinNetworkID::Test.genesis_config().clone(); genesis_config.genesis_block_parameter = @@ -570,6 +574,7 @@ async fn test_verify_block_used_gas_failed() { } #[stest::test] +#[allow(clippy::vec_init_then_push)] async fn test_verify_txn_count_failed() { // TODO: fix me let (mut new_block, mut main) = new_block_and_main().await; @@ -695,6 +700,7 @@ async fn test_verify_uncles_count_failed() { debug!("expect apply failed : {:?}", apply_failed.err().unwrap()); } +#[allow(clippy::vec_init_then_push)] async fn test_verify_uncles_number(succ: bool) -> Result { let count = 5; let (mut uncle_header, mut writeable_block_chain_service, node_config, storage) = @@ -731,6 +737,7 @@ async fn test_verify_uncles_number_failed() { } } +#[allow(clippy::vec_init_then_push)] async fn test_verify_uncles_in_old_epoch(begin_epoch: bool) -> Result { let count = 5; let (uncle_header, mut writeable_block_chain_service, node_config, storage) = @@ -792,6 +799,7 @@ async fn test_verify_uncles_in_old_epoch_failed() { } #[stest::test] +#[allow(clippy::vec_init_then_push)] async fn test_verify_uncles_uncle_exist_failed() { let count = 5; let (uncle_header, mut writeable_block_chain_service, node_config, storage) = @@ -869,6 +877,7 @@ async fn test_some_uncles_in_block_failed() { } #[stest::test] +#[allow(clippy::vec_init_then_push)] async fn test_verify_uncle_and_parent_number_failed() { let count = 5; let (mut uncle_header, mut writeable_block_chain_service, node_config, storage) = @@ -926,6 +935,7 @@ async fn test_verify_uncle_and_parent_number_failed() { } #[stest::test] +#[allow(clippy::vec_init_then_push)] async fn test_verify_uncle_which_parent_is_end_block_in_last_epoch() { let count = TEST_CONFIG.consensus_config.epoch_block_count; let (uncle_header, mut writeable_block_chain_service, node_config, storage) = diff --git a/sync/src/tasks/block_sync_task.rs b/sync/src/tasks/block_sync_task.rs index fa666d6a9b..1f4f489ec1 100644 --- a/sync/src/tasks/block_sync_task.rs +++ b/sync/src/tasks/block_sync_task.rs @@ -37,6 +37,7 @@ impl SyncBlockData { } } +#[allow(clippy::from_over_into)] impl Into<(Block, Option, Option)> for SyncBlockData { fn into(self) -> (Block, Option, Option) { (self.block, self.info, self.peer_id) diff --git a/txpool/src/pool/queue.rs b/txpool/src/pool/queue.rs index 2e6b4ea95e..961443a0f4 100644 --- a/txpool/src/pool/queue.rs +++ b/txpool/src/pool/queue.rs @@ -84,6 +84,7 @@ impl fmt::Display for Status { } } +#[allow(clippy::from_over_into)] impl Into for Status { fn into(self) -> TxPoolStatus { TxPoolStatus { diff --git a/types/src/account_state.rs b/types/src/account_state.rs index 4e97bd6cc2..35fdd112e0 100644 --- a/types/src/account_state.rs +++ b/types/src/account_state.rs @@ -38,6 +38,7 @@ impl AccountState { } } +#[allow(clippy::from_over_into)] impl Into>> for AccountState { fn into(self) -> Vec> { self.storage_roots diff --git a/types/src/block.rs b/types/src/block.rs index bf24045387..3f3f00c51e 100644 --- a/types/src/block.rs +++ b/types/src/block.rs @@ -403,6 +403,7 @@ impl Sample for BlockHeader { } } +#[allow(clippy::from_over_into)] impl Into for BlockHeader { fn into(self) -> RawBlockHeader { RawBlockHeader { @@ -583,6 +584,7 @@ impl BlockBody { } } +#[allow(clippy::from_over_into)] impl Into for Vec { fn into(self) -> BlockBody { BlockBody { @@ -592,6 +594,7 @@ impl Into for Vec { } } +#[allow(clippy::from_over_into)] impl Into> for BlockBody { fn into(self) -> Vec { self.transactions @@ -1004,6 +1007,7 @@ impl From for BlockSummary { } } +#[allow(clippy::from_over_into)] impl Into<(BlockHeader, Vec)> for BlockSummary { fn into(self) -> (BlockHeader, Vec) { (self.block_header, self.uncles) diff --git a/types/src/peer_info.rs b/types/src/peer_info.rs index 03c86da93e..89c722190e 100644 --- a/types/src/peer_info.rs +++ b/types/src/peer_info.rs @@ -76,6 +76,7 @@ impl PeerId { } } +#[allow(clippy::from_over_into)] impl Into for PeerId { fn into(self) -> network_p2p_types::PeerId { self.0 diff --git a/types/src/state_set.rs b/types/src/state_set.rs index 26375061aa..85c9857afe 100644 --- a/types/src/state_set.rs +++ b/types/src/state_set.rs @@ -50,6 +50,7 @@ impl<'a> IntoIterator for &'a StateSet { } } +#[allow(clippy::from_over_into)] impl Into, Vec)>> for StateSet { fn into(self) -> Vec<(Vec, Vec)> { self.0 diff --git a/types/src/stress_test.rs b/types/src/stress_test.rs index 57950155ed..a5b6d83d00 100644 --- a/types/src/stress_test.rs +++ b/types/src/stress_test.rs @@ -1,6 +1,7 @@ use serde::{Deserialize, Serialize}; #[derive(Eq, PartialEq, Deserialize, Serialize, Clone, Debug)] +#[allow(clippy::upper_case_acronyms)] pub struct TPS { total_txns: u64, duration: u64, diff --git a/types/uint/src/lib.rs b/types/uint/src/lib.rs index cc73b61c9b..48c8d45f6b 100644 --- a/types/uint/src/lib.rs +++ b/types/uint/src/lib.rs @@ -137,6 +137,7 @@ impl From for U256 { } } +#[allow(clippy::from_over_into)] impl Into for U256 { fn into(self) -> HashValue { let mut bytes = [0u8; 32]; diff --git a/vm/compiler/Cargo.toml b/vm/compiler/Cargo.toml index 8fafe31a6d..5b071326e6 100644 --- a/vm/compiler/Cargo.toml +++ b/vm/compiler/Cargo.toml @@ -11,8 +11,8 @@ anyhow = "1.0.40" once_cell = "1.7.2" tempfile = "3.1.0" regex = { version = "1.4.3", default-features = false, features = ["std", "perf"] } -move-lang = { package="move-lang", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-lang-test-utils = { package="move-lang-test-utils", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +move-lang = { package="move-lang", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +move-lang-test-utils = { package="move-lang-test-utils", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } starcoin-crypto = { path = "../../commons/crypto"} starcoin-vm-types = { path = "../types"} starcoin-logger = { path = "../../commons/logger"} diff --git a/vm/functional-tests/Cargo.toml b/vm/functional-tests/Cargo.toml index f96a3fd157..7d7a8db303 100644 --- a/vm/functional-tests/Cargo.toml +++ b/vm/functional-tests/Cargo.toml @@ -9,7 +9,7 @@ edition = "2018" [dependencies] anyhow = "1.0.40" tempfile = "3.1.0" -datatest-stable = {git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +datatest-stable = {git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } stdlib = { package="stdlib", path = "../stdlib"} once_cell = "1.7.2" regex = { version = "1.4.3", default-features = false, features = ["std", "perf"] } @@ -30,7 +30,7 @@ executor = { package="starcoin-executor", path = "../../executor"} starcoin-genesis = { path = "../../genesis" } starcoin-consensus = { path = "../../consensus" } starcoin-account-api = { path = "../../account/api" } -move-lang = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +move-lang = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } [dev-dependencies] starcoin-vm-types = { path = "../types"} diff --git a/vm/functional-tests/src/errors.rs b/vm/functional-tests/src/errors.rs index 5047e921aa..b4fd1c38b7 100644 --- a/vm/functional-tests/src/errors.rs +++ b/vm/functional-tests/src/errors.rs @@ -8,6 +8,7 @@ use thiserror::Error; /// Defines all errors in this crate. #[derive(Clone, Debug, Error)] +#[allow(clippy::upper_case_acronyms)] pub enum ErrorKind { #[error( "an error occurred when executing the transaction, vm status {:?}, txn status {:?}", diff --git a/vm/move-coverage/Cargo.toml b/vm/move-coverage/Cargo.toml index 587c434983..2a30a24be3 100644 --- a/vm/move-coverage/Cargo.toml +++ b/vm/move-coverage/Cargo.toml @@ -18,8 +18,8 @@ colored = "2.0.0" bcs-ext = { package="bcs-ext", path = "../../commons/bcs_ext" } starcoin-types = { path = "../../types"} starcoin-vm-types = { path = "../types"} -bytecode-source-map = { package = "bytecode-source-map", version = "0.1.0", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -bytecode-verifier = { package = "bytecode-verifier", version = "0.1.0", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +bytecode-source-map = { package = "bytecode-source-map", version = "0.1.0", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +bytecode-verifier = { package = "bytecode-verifier", version = "0.1.0", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } [features] default = [] diff --git a/vm/move-explain/Cargo.toml b/vm/move-explain/Cargo.toml index 225de716a7..ad07044fcf 100644 --- a/vm/move-explain/Cargo.toml +++ b/vm/move-explain/Cargo.toml @@ -12,8 +12,8 @@ edition = "2018" [dependencies] structopt = "0.3.21" stdlib = { package="stdlib", path = "../stdlib"} -errmapgen = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-core-types = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +errmapgen = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +move-core-types = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf" } bcs-ext = { package="bcs-ext", path = "../../commons/bcs_ext" } [features] diff --git a/vm/move-prover/Cargo.toml b/vm/move-prover/Cargo.toml index a3f45b8f0d..2df6b341de 100644 --- a/vm/move-prover/Cargo.toml +++ b/vm/move-prover/Cargo.toml @@ -8,18 +8,18 @@ license = "Apache-2.0" [dependencies] # diem dependencies -boogie-backend = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -boogie-backend-v2 = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-lang = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-model = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -docgen = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -errmapgen = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -bytecode = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -vm = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -diem-temppath = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -bytecode-source-map = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-ir-types = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -abigen = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +boogie-backend = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +boogie-backend-v2 = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +move-lang = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +move-model = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +docgen = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +errmapgen = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +bytecode = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +vm = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +diem-temppath = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +bytecode-source-map = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +move-ir-types = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +abigen = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } # external dependencies async-trait = "0.1.48" @@ -44,8 +44,8 @@ tokio = { version = "0.2", features = ["full"] } toml = "0.5.8" [dev-dependencies] -datatest-stable = {git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-prover-test-utils = {git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +datatest-stable = {git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } +move-prover-test-utils = {git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } shell-words = "1.0.0" [[test]] diff --git a/vm/move-prover/src/cli.rs b/vm/move-prover/src/cli.rs index 22e3aa2f1b..e190f4ca13 100644 --- a/vm/move-prover/src/cli.rs +++ b/vm/move-prover/src/cli.rs @@ -17,7 +17,7 @@ use simplelog::{ }; use abigen::AbigenOptions; -use boogie_backend_v2::options::BoogieOptions; +use boogie_backend_v2::options::{BoogieOptions, VectorTheory}; use bytecode::options::ProverOptions; use docgen::DocgenOptions; use errmapgen::ErrmapOptions; @@ -34,6 +34,10 @@ static TEST_MODE: AtomicBool = AtomicBool::new(false); /// Represents options provided to the tool. Most of those options are configured via a toml /// source; some over the command line flags. +/// +/// NOTE: any fields carrying structured data must appear at the end for making +/// toml printing work. When changing this config, use `mvp --print-config` to +/// verify this works. #[derive(Debug, Clone, Deserialize, Serialize)] #[serde(default, deny_unknown_fields)] pub struct Options { @@ -59,26 +63,27 @@ pub struct Options { /// The paths to any dependencies for the Move sources. Those will not be verified but /// can be used by `move_sources`. pub move_deps: Vec, - /// Options for the prover. - pub prover: ProverOptions, - /// Options for the prover backend. - pub backend: BoogieOptions, + /// Whether to run experimental pipeline + pub experimental_pipeline: bool, + /// Whether to use exclusively weak edges in borrow analysis + pub weak_edges: bool, + /// Whether to use the next major version instead of the current one + pub vnext: bool, /// Whether to use the v2 invariant scheme. pub inv_v2: bool, + /// BEGIN OF STRUCTURED OPTIONS /// Options for the documentation generator. pub docgen: DocgenOptions, + /// Options for the prover. + pub prover: ProverOptions, + /// Options for the prover backend. + pub backend: BoogieOptions, /// Options for the ABI generator. pub abigen: AbigenOptions, /// Options for the error map generator. /// TODO: this currently create errors during deserialization, so skip them for this. #[serde(skip_serializing)] pub errmapgen: ErrmapOptions, - /// Whether to run experimental pipeline - pub experimental_pipeline: bool, - /// Whether to use strong edges in borrow analysis - pub strong_edges: bool, - /// Whether to use the next major version instead of the current one - pub vnext: bool, } impl Default for Options { @@ -101,8 +106,8 @@ impl Default for Options { abigen: AbigenOptions::default(), errmapgen: ErrmapOptions::default(), experimental_pipeline: false, - strong_edges: false, vnext: false, + weak_edges: false, } } } @@ -175,7 +180,15 @@ impl Options { .long("verbose") .takes_value(true) .possible_values(&["error", "warn", "info", "debug"]) - .help("verbosity level."), + .help("verbosity level"), + ) + .arg( + Arg::with_name("vector-theory") + .long("vector-theory") + .takes_value(true) + .possible_values(&["BoogieArray", "BoogieArrayIntern", + "SmtArray", "SmtArrayExt", "SmtSeq"]) + .help("vector theory to use"), ) .arg( Arg::with_name("generate-only") @@ -375,9 +388,9 @@ impl Options { .help("whether to run experimental pipeline") ) .arg( - Arg::with_name("strong_edges") - .long("strong_edges") - .help("whether to use strong edges in borrow analysis") + Arg::with_name("weak-edges") + .long("weak-edges") + .help("whether to use exclusively weak edges in borrow analysis") ) .arg( Arg::with_name("exp_mut_param") @@ -389,6 +402,14 @@ impl Options { .long("check-inconsistency") .help("checks whether there is any inconsistency") ) + .arg( + Arg::with_name("verify-only") + .long("verify-only") + .takes_value(true) + .value_name("FUNCTION_NAME") + .help("only generate verification condition for one function. \ + This overrides verification scope and can be overriden by the pragma verify=false") + ) .after_help("More options available via `--config file` or `--config-str str`. \ Use `--print-config` to see format and current values. \ See `move-prover/src/cli.rs::Option` for documentation."); @@ -433,6 +454,17 @@ impl Options { _ => unreachable!("should not happen"), } } + if matches.is_present("vector-theory") { + options.backend.vector_theory = match matches.value_of("vector-theory").unwrap() { + "BoogieArray" => VectorTheory::BoogieArray, + "BoogieArrayIntern" => VectorTheory::BoogieArrayIntern, + "SmtArray" => VectorTheory::SmtArray, + "SmtArrayExt" => VectorTheory::SmtArrayExt, + "SmtSeq" => VectorTheory::SmtSeq, + _ => unreachable!("should not happen"), + } + } + if matches.is_present("generate-only") { options.prover.generate_only = true; } @@ -515,8 +547,8 @@ impl Options { if matches.is_present("experimental_pipeline") { options.experimental_pipeline = true; } - if matches.is_present("strong_edges") { - options.strong_edges = true; + if matches.is_present("weak-edges") { + options.weak_edges = true; } if matches.is_present("timeout") { options.backend.vc_timeout = matches.value_of("timeout").unwrap().parse::()?; @@ -542,6 +574,14 @@ impl Options { if matches.is_present("check-inconsistency") { options.prover.check_inconsistency = true; } + + if matches.is_present("verify-only") { + options.prover.verify_scope = + VerificationScope::Only(matches.value_of("verify-only").unwrap().to_string()); + } + + options.backend.derive_options(); + if matches.is_present("print-config") { println!("{}", toml::to_string(&options).unwrap()); Err(anyhow!("exiting")) diff --git a/vm/move-prover/src/lib.rs b/vm/move-prover/src/lib.rs index c943cae2f9..1330d1f5f8 100644 --- a/vm/move-prover/src/lib.rs +++ b/vm/move-prover/src/lib.rs @@ -3,13 +3,11 @@ #![forbid(unsafe_code)] -use crate::{ - cli::{Options, INLINE_PRELUDE}, - prelude_template_helpers::StratificationHelper, -}; +use crate::cli::{Options, INLINE_PRELUDE}; use abigen::Abigen; use anyhow::anyhow; use boogie_backend::{boogie_wrapper::BoogieWrapper, bytecode_translator::BoogieTranslator}; +use boogie_backend_v2::prelude_template_helpers::StratificationHelper; use bytecode::{ data_invariant_instrumentation::DataInvariantInstrumentationProcessor, debug_instrumentation::DebugInstrumenter, @@ -41,7 +39,6 @@ use std::{ pub mod cli; mod pipelines; -mod prelude_template_helpers; // ================================================================================================= // Entry Point @@ -111,8 +108,8 @@ pub fn run_move_prover( return Err(anyhow!("exiting with analysis errors")); } let writer = CodeWriter::new(env.internal_loc()); - add_prelude(&options, &writer)?; if options.vnext { + boogie_backend_v2::add_prelude(&options.backend, &writer)?; let mut translator = boogie_backend_v2::bytecode_translator::BoogieTranslator::new( &env, &options.backend, @@ -121,6 +118,7 @@ pub fn run_move_prover( ); translator.translate(); } else { + add_prelude(&options, &writer)?; let mut translator = BoogieTranslator::new(&env, &options.backend, &targets, &writer); translator.translate(); } @@ -281,16 +279,13 @@ fn add_prelude(options: &Options, writer: &CodeWriter) -> anyhow::Result<()> { emit!(writer, "\n// ** prelude from {}\n\n", &options.prelude_path); let content = if options.prelude_path == INLINE_PRELUDE { debug!("using inline prelude"); - if options.vnext { - String::from_utf8_lossy(boogie_backend_v2::DEFAULT_PRELUDE).to_string() - } else { - String::from_utf8_lossy(DEFAULT_PRELUDE).to_string() - } + String::from_utf8_lossy(DEFAULT_PRELUDE).to_string() } else { debug!("using prelude at {}", &options.prelude_path); fs::read_to_string(&options.prelude_path)? }; let mut handlebars = Handlebars::new(); + handlebars.set_strict_mode(true); handlebars.register_helper( "stratified", Box::new(StratificationHelper::new( diff --git a/vm/move-prover/src/pipelines.rs b/vm/move-prover/src/pipelines.rs index 36566ad623..493aa95b35 100644 --- a/vm/move-prover/src/pipelines.rs +++ b/vm/move-prover/src/pipelines.rs @@ -21,7 +21,7 @@ pub fn pipelines(options: &Options) -> Vec> { MutRefInstrumenter::new(), ReachingDefProcessor::new(), LiveVarAnalysisProcessor::new(), - BorrowAnalysisProcessor::new(options.strong_edges), + BorrowAnalysisProcessor::new(options.weak_edges), MemoryInstrumentationProcessor::new(), CleanAndOptimizeProcessor::new(), UsageProcessor::new(), diff --git a/vm/move-prover/src/prelude_template_helpers.rs b/vm/move-prover/src/prelude_template_helpers.rs deleted file mode 100644 index 8f9fc735c3..0000000000 --- a/vm/move-prover/src/prelude_template_helpers.rs +++ /dev/null @@ -1,59 +0,0 @@ -// Copyright (c) The Diem Core Contributors -// SPDX-License-Identifier: Apache-2.0 - -use handlebars::{ - to_json, BlockContext, Context, Handlebars, Helper, HelperDef, HelperResult, Output, - RenderContext, RenderError, Renderable, -}; - -#[derive(Clone, Copy)] -pub struct StratificationHelper { - depth: usize, -} - -impl StratificationHelper { - pub fn new(depth: usize) -> Self { - Self { depth } - } -} - -impl HelperDef for StratificationHelper { - fn call<'reg: 'rc, 'rc>( - &self, - h: &Helper<'reg, 'rc>, - r: &'reg Handlebars, - ctx: &'rc Context, - rc: &mut RenderContext<'reg, 'rc>, - out: &mut dyn Output, - ) -> HelperResult { - if !h.params().is_empty() { - return Err(RenderError::new("helper cannot have parameters")); - } - let templ = h - .template() - .ok_or_else(|| RenderError::new("expected block template"))?; - let inverse = h - .inverse() - .ok_or_else(|| RenderError::new("expected else template"))?; - - for i in 0..self.depth { - let this_suffix = if i == 0 { - "stratified".to_owned() - } else { - format!("level{}", i) - }; - let next_suffix = format!("level{}", i + 1); - rc.push_block(BlockContext::new()); - let block = rc.block_mut().expect("block defined"); - block.set_local_var("@this_suffix".to_owned(), to_json(this_suffix)); - block.set_local_var("@next_suffix".to_owned(), to_json(next_suffix)); - block.set_local_var("@this_level".to_owned(), to_json(i)); - if i == self.depth - 1 { - inverse.render(r, ctx, rc, out)?; - } else { - templ.render(r, ctx, rc, out)?; - } - } - Ok(()) - } -} diff --git a/vm/move-prover/tests/sources/functional/hash_model.move b/vm/move-prover/tests/sources/functional/hash_model.move deleted file mode 100644 index c083f38d94..0000000000 --- a/vm/move-prover/tests/sources/functional/hash_model.move +++ /dev/null @@ -1,93 +0,0 @@ -module TestHash { - use 0x1::Hash; - - - spec module { - pragma verify = true; - } - - // ----------- - // SHA-2 Tests - // ----------- - - fun hash_test1(v1: vector, v2: vector): (vector, vector) - { - let h1 = Hash::sha2_256(v1); - let h2 = Hash::sha2_256(v2); - (h1, h2) - } - spec fun hash_test1 { - aborts_if false; - ensures result_1 == result_2 ==> v1 == v2; - ensures v1 == v2 ==> result_1 == result_2; - ensures len(result_1) == 32; - // it knows result is vector - ensures len(result_1) > 0 ==> result_1[0] <= max_u8(); - } - - fun hash_test2(v1: vector, v2: vector): bool - { - let h1 = Hash::sha2_256(v1); - let h2 = Hash::sha2_256(v2); - h1 == h2 - } - spec fun hash_test2 { - aborts_if false; - ensures result == (v1 == v2); - } - - fun hash_test1_incorrect(v1: vector, v2: vector): (vector, vector) - { - let h1 = Hash::sha2_256(v1); - let h2 = Hash::sha2_256(v2); - (h1, h2) - } - spec fun hash_test1_incorrect { - aborts_if false; - // ensures result_1 == result_2; // TODO: uncomment this after fixing the non-determinism issue of Boogie - ensures len(result_1) > 0 ==> result_1[0] < max_u8(); // should be <= - } - - - // ----------- - // SHA-3 Tests - // ----------- - - fun hash_test3(v1: vector, v2: vector): (vector, vector) - { - let h1 = Hash::sha3_256(v1); - let h2 = Hash::sha3_256(v2); - (h1, h2) - } - spec fun hash_test3 { - aborts_if false; - ensures result_1 == result_2 ==> v1 == v2; - ensures v1 == v2 ==> result_1 == result_2; - ensures len(result_1) == 32; - // it knows result is vector - ensures len(result_1) > 0 ==> result_1[0] <= max_u8(); - } - - fun hash_test4(v1: vector, v2: vector): bool - { - let h1 = Hash::sha3_256(v1); - let h2 = Hash::sha3_256(v2); - h1 == h2 - } - spec fun hash_test4 { - aborts_if false; - ensures result == (v1 == v2); - } - - fun hash_test2_incorrect(v1: vector, v2: vector): (vector, vector) - { - let h1 = Hash::sha2_256(v1); - let h2 = Hash::sha2_256(v2); - (h1, h2) - } - spec fun hash_test2_incorrect { - aborts_if false; - // ensures result_1 == result_2; // TODO: uncomment this after fixing the non-determinism issue of Boogie - ensures len(result_1) > 0 ==> result_1[0] < max_u8(); - } -} diff --git a/vm/move-prover/tests/sources/functional/hash_model_invalid.move b/vm/move-prover/tests/sources/functional/hash_model_invalid.move deleted file mode 100644 index cbb68982f0..0000000000 --- a/vm/move-prover/tests/sources/functional/hash_model_invalid.move +++ /dev/null @@ -1,37 +0,0 @@ -module TestHash { - use 0x1::Hash; - - - spec module { - pragma verify = true; - } - - - // sha2 test - fun hash_test1(v1: vector, v2: vector): (vector, vector) - { - let h1 = Hash::sha2_256(v1); - let h2 = Hash::sha2_256(v2); - (h1, h2) - } - spec fun hash_test1 { - aborts_if false; - // TODO: two failing ensures seem to create non-determinism; one time the first, the next the - // second is reported. Investigate whether this is caused by boogie_wrapper or by inherent to boogie. - // ensures result_1 == result_2; - ensures len(result_1) > 0 ==> result_1[0] < max_u8(); // should be <= - } - - // sha3 test - fun hash_test2(v1: vector, v2: vector): (vector, vector) - { - let h1 = Hash::sha3_256(v1); - let h2 = Hash::sha3_256(v2); - (h1, h2) - } - spec fun hash_test2 { - aborts_if false; - // ensures result_1 == result_2; - ensures len(result_1) > 0 ==> result_1[0] < max_u8(); - } -} diff --git a/vm/move-prover/tests/sources/functional/return_values.move b/vm/move-prover/tests/sources/functional/return_values.move deleted file mode 100644 index c8ba740d05..0000000000 --- a/vm/move-prover/tests/sources/functional/return_values.move +++ /dev/null @@ -1,66 +0,0 @@ -module TestReturnValue { - - public fun one_two(): (u64, u64) { - (1, 2) - } - spec fun one_two { - aborts_if false; - ensures result_1 == 1; - ensures result_2 == 2; - } - - public fun one_two_incorrect(): (u64, u64) { - (1, 2) - } - spec fun one_two_wrapper_incorrect { - aborts_if false; - ensures result_1 == 2; - ensures result_2 == 1; - } - - public fun one_two_wrapper(): (u64, u64) { - one_two() - } - spec fun one_two_wrapper { - aborts_if false; - ensures result_1 == 1; - ensures result_2 == 2; - } - - public fun one_two_wrapper_incorrect(): (u64, u64) { - one_two() - } - spec fun one_two_wrapper_incorrect { - aborts_if false; - ensures result_1 == 2; - ensures result_2 == 1; - } - - public fun true_one(): (bool, u64) { - (true, 1) - } - spec fun true_one { - aborts_if false; - ensures result_1 == true; - ensures result_2 == 1; - } - - public fun true_one_wrapper(): (bool, u64) { - true_one() - } - spec fun true_one_wrapper { - ensures result_1 == true; - ensures result_2 == 1; - } - - public fun true_one_wrapper_incorrect(): (bool, u64) { - true_one() - } - spec fun true_one_wrapper_incorrect { - ensures false; - ensures result_1 == true; - ensures result_1 == false; - ensures result_2 == 0; - ensures result_2 == 1; - } -} diff --git a/vm/stdlib/Cargo.toml b/vm/stdlib/Cargo.toml index d0b928fc0c..b0b0ad2c08 100644 --- a/vm/stdlib/Cargo.toml +++ b/vm/stdlib/Cargo.toml @@ -8,8 +8,8 @@ edition = "2018" [dependencies] anyhow = "1.0.40" -bytecode-verifier = { package="bytecode-verifier", git = "https://github.com/starcoinorg/diem", version = "0.1.0",rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -datatest-stable = { package="datatest-stable", git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +bytecode-verifier = { package="bytecode-verifier", git = "https://github.com/starcoinorg/diem", version = "0.1.0",rev="bfd7b336d14858d288e908636853949693642bcf" } +datatest-stable = { package="datatest-stable", git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } starcoin-crypto = { path = "../../commons/crypto"} starcoin-vm-types = { path = "../types"} bcs-ext = { package="bcs-ext", path = "../../commons/bcs_ext" } diff --git a/vm/transaction-builder-generator/Cargo.toml b/vm/transaction-builder-generator/Cargo.toml index e87e503862..fa823c0cbb 100644 --- a/vm/transaction-builder-generator/Cargo.toml +++ b/vm/transaction-builder-generator/Cargo.toml @@ -19,7 +19,7 @@ serde-generate = {git="https://github.com/starcoinorg/serde-reflection" , rev="f serde-reflection = {git="https://github.com/starcoinorg/serde-reflection" , rev="f2b44e0455ca19cda822523e3038d6b6bae78b28"} starcoin-vm-types = { path = "../types"} -move-core-types = {git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +move-core-types = {git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } bcs = "0.1.2" [dev-dependencies] diff --git a/vm/types/Cargo.toml b/vm/types/Cargo.toml index b7f26dbfb2..036110264b 100644 --- a/vm/types/Cargo.toml +++ b/vm/types/Cargo.toml @@ -22,11 +22,11 @@ log = "0.4.14" proptest = { version = "1.0.0", default-features = false, optional = true } proptest-derive = { version = "0.3.0", default-features = false, optional = true } -move-core-types = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -move-vm-types = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -bytecode-verifier = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } -vm = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425"} -move-ir-types = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +move-core-types = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf" } +move-vm-types = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf" } +bytecode-verifier = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf" } +vm = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf"} +move-ir-types = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf" } bcs-ext = { package = "bcs-ext", path = "../../commons/bcs_ext" } starcoin-proptest-helpers = { path = "../../commons/proptest-helpers", optional = true } @@ -37,7 +37,7 @@ forkable-jellyfish-merkle = { path = "../../commons/forkable-jellyfish-merkle"} [dev-dependencies] proptest = "1.0.0" proptest-derive = "0.3.0" -vm = { git = "https://github.com/starcoinorg/diem", rev = "f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425", features = ["fuzzing"]} +vm = { git = "https://github.com/starcoinorg/diem", rev = "bfd7b336d14858d288e908636853949693642bcf", features = ["fuzzing"]} starcoin-crypto = { path = "../../commons/crypto", features = ["fuzzing"] } starcoin-proptest-helpers = { path = "../../commons/proptest-helpers"} diff --git a/vm/types/src/access_path.rs b/vm/types/src/access_path.rs index 4b4591a5e2..97166adbaa 100644 --- a/vm/types/src/access_path.rs +++ b/vm/types/src/access_path.rs @@ -198,6 +198,7 @@ impl From<&ResourceKey> for AccessPath { Debug, )] #[repr(u8)] +#[allow(clippy::upper_case_acronyms)] pub enum DataType { CODE, RESOURCE, diff --git a/vm/types/src/genesis_config.rs b/vm/types/src/genesis_config.rs index 27a0ca0a87..a7d73a22fc 100644 --- a/vm/types/src/genesis_config.rs +++ b/vm/types/src/genesis_config.rs @@ -154,6 +154,7 @@ impl From for ChainId { } } +#[allow(clippy::from_over_into)] impl Into for ChainId { fn into(self) -> u8 { self.id diff --git a/vm/types/src/on_chain_config/dao_config.rs b/vm/types/src/on_chain_config/dao_config.rs index 34e43806a1..1c49f54467 100644 --- a/vm/types/src/on_chain_config/dao_config.rs +++ b/vm/types/src/on_chain_config/dao_config.rs @@ -22,8 +22,7 @@ impl OnChainConfig for DaoConfig { const CONF_IDENTIFIER: &'static str = "DaoConfig"; fn type_params() -> Vec { - let mut params = vec![]; - params.push(stc_type_tag()); + let params = vec![stc_type_tag()]; params } } diff --git a/vm/types/src/on_chain_config/mod.rs b/vm/types/src/on_chain_config/mod.rs index ee8d077094..697a89ff6b 100644 --- a/vm/types/src/on_chain_config/mod.rs +++ b/vm/types/src/on_chain_config/mod.rs @@ -35,6 +35,7 @@ pub use crate::on_chain_resource::GlobalTimeOnChain; /// 2. Add the config's `ConfigID` to `ON_CHAIN_CONFIG_REGISTRY` #[derive(Clone, Debug, Eq, Hash, PartialEq)] #[allow(clippy::box_vec)] +#[allow(clippy::upper_case_acronyms)] pub struct ConfigID(&'static str, &'static str, &'static str, Vec); impl ConfigID { @@ -48,6 +49,7 @@ impl ConfigID { } } +#[allow(clippy::vec_init_then_push)] pub static ON_CHAIN_CONFIG_REGISTRY: Lazy> = Lazy::new(|| { let mut configs: Vec = Vec::new(); configs.push(VMConfig::config_id()); diff --git a/vm/types/src/on_chain_config/vm_config.rs b/vm/types/src/on_chain_config/vm_config.rs index c853d99fe6..b525a13166 100644 --- a/vm/types/src/on_chain_config/vm_config.rs +++ b/vm/types/src/on_chain_config/vm_config.rs @@ -78,6 +78,7 @@ impl OnChainConfig for TransactionPublishOption { /// Defines all the on chain configuration data needed by VM. #[derive(Clone, Debug, Deserialize, PartialEq, Serialize)] +#[allow(clippy::upper_case_acronyms)] pub struct VMConfig { pub gas_schedule: CostTable, } @@ -90,6 +91,7 @@ struct CostTableInner { } #[derive(Clone, Debug, Deserialize, PartialEq, Serialize)] +#[allow(clippy::upper_case_acronyms)] struct VMConfigInner { pub gas_schedule: CostTableInner, } diff --git a/vm/types/src/token/stc.rs b/vm/types/src/token/stc.rs index 60ea240704..3d9af2c84b 100644 --- a/vm/types/src/token/stc.rs +++ b/vm/types/src/token/stc.rs @@ -41,6 +41,7 @@ pub static SCALE_MILLISTC: u32 = 6; pub static SCALE_STC: u32 = 9; #[derive(Clone, Copy, Debug)] +#[allow(clippy::upper_case_acronyms)] pub enum STCUnit { NanoSTC, MicroSTC, diff --git a/vm/types/src/token/token_code.rs b/vm/types/src/token/token_code.rs index 9a0d3b2f25..532186b23c 100644 --- a/vm/types/src/token/token_code.rs +++ b/vm/types/src/token/token_code.rs @@ -78,6 +78,7 @@ impl FromStr for TokenCode { } } +#[allow(clippy::from_over_into)] impl Into for TokenCode { fn into(self) -> TypeTag { TypeTag::Struct(StructTag { diff --git a/vm/types/src/transaction/authenticator.rs b/vm/types/src/transaction/authenticator.rs index e3b97a3acd..673816755d 100644 --- a/vm/types/src/transaction/authenticator.rs +++ b/vm/types/src/transaction/authenticator.rs @@ -418,12 +418,14 @@ impl TryFrom<&[u8]> for AccountPublicKey { } } +#[allow(clippy::from_over_into)] impl Into for Ed25519PublicKey { fn into(self) -> AccountPublicKey { AccountPublicKey::Single(self) } } +#[allow(clippy::from_over_into)] impl Into for MultiEd25519PublicKey { fn into(self) -> AccountPublicKey { AccountPublicKey::Multi(self) @@ -459,12 +461,14 @@ impl AccountPrivateKey { } } +#[allow(clippy::from_over_into)] impl Into for Ed25519PrivateKey { fn into(self) -> AccountPrivateKey { AccountPrivateKey::Single(self) } } +#[allow(clippy::from_over_into)] impl Into for MultiEd25519KeyShard { fn into(self) -> AccountPrivateKey { AccountPrivateKey::Multi(self) diff --git a/vm/types/src/transaction/mod.rs b/vm/types/src/transaction/mod.rs index 513eaecce9..1e84bacbcf 100644 --- a/vm/types/src/transaction/mod.rs +++ b/vm/types/src/transaction/mod.rs @@ -732,6 +732,8 @@ impl Deref for BlockTransactionInfo { &self.txn_info } } + +#[allow(clippy::from_over_into)] impl Into<(HashValue, TransactionInfo)> for BlockTransactionInfo { fn into(self) -> (HashValue, TransactionInfo) { (self.block_id, self.txn_info) diff --git a/vm/types/src/transaction/script.rs b/vm/types/src/transaction/script.rs index db37a5fd39..c8ea135b40 100644 --- a/vm/types/src/transaction/script.rs +++ b/vm/types/src/transaction/script.rs @@ -70,12 +70,14 @@ impl Sample for Script { /// How to call a particular Move script (aka. an "ABI"). #[derive(Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub enum ScriptABI { TransactionScript(TransactionScriptABI), ScriptFunction(ScriptFunctionABI), } #[derive(Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub struct ScriptFunctionABI { /// The public name of the script. name: String, @@ -90,6 +92,7 @@ pub struct ScriptFunctionABI { } #[derive(Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub struct TransactionScriptABI { /// The public name of the script. name: String, @@ -106,6 +109,7 @@ pub struct TransactionScriptABI { /// The description of a (regular) argument in a script. #[derive(Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub struct ArgumentABI { /// The name of the argument. name: String, @@ -116,6 +120,7 @@ pub struct ArgumentABI { /// The description of a type argument in a script. #[derive(Clone, Debug, Hash, Eq, PartialEq, Serialize, Deserialize)] +#[allow(clippy::upper_case_acronyms)] pub struct TypeArgumentABI { /// The name of the argument. name: String, diff --git a/vm/vm-runtime/Cargo.toml b/vm/vm-runtime/Cargo.toml index 43e1980b2d..214a8d7895 100644 --- a/vm/vm-runtime/Cargo.toml +++ b/vm/vm-runtime/Cargo.toml @@ -11,7 +11,7 @@ anyhow = "1.0.40" once_cell = "1.7.2" prometheus = "0.12.0" starcoin-types = { path = "../../types"} -move-vm-runtime = { git = "https://github.com/starcoinorg/diem", rev="f71f37c1b0ba5b24fa8c88893d3aa2adaf08a425" } +move-vm-runtime = { git = "https://github.com/starcoinorg/diem", rev="bfd7b336d14858d288e908636853949693642bcf" } starcoin-config = { path = "../../config"} starcoin-logger = {path = "../../commons/logger"} num_enum = "0.5.1" diff --git a/vm/vm-runtime/src/starcoin_vm.rs b/vm/vm-runtime/src/starcoin_vm.rs index 9fa28acdd9..6bb0fecb89 100644 --- a/vm/vm-runtime/src/starcoin_vm.rs +++ b/vm/vm-runtime/src/starcoin_vm.rs @@ -56,6 +56,7 @@ use std::convert::TryFrom; use std::sync::Arc; #[derive(Clone)] +#[allow(clippy::upper_case_acronyms)] /// Wrapper of MoveVM pub struct StarcoinVM { move_vm: Arc, @@ -609,13 +610,13 @@ impl StarcoinVM { .map(|_return_vals| ()) .or_else(convert_prologue_runtime_error)?; BLOCK_UNCLES.observe(uncles as f64); - Ok(get_transaction_output( + get_transaction_output( &mut (), session, &cost_strategy, max_gas_amount, KeptVMStatus::Executed, - )?) + ) } fn execute_user_transaction(