From cbba94c31073825e3c2378f60a7a5f52e6f980e1 Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Wed, 9 Oct 2019 11:18:24 -0400 Subject: [PATCH 01/12] Upgrade dependencies The hard work was done by `cargo upgrade`. Split out by request of @niklasad1. --- contract-address/Cargo.toml | 4 ++-- ethbloom/Cargo.toml | 12 ++++++------ ethereum-types/Cargo.toml | 4 ++-- fixed-hash/Cargo.toml | 14 +++++++------- fixed-hash/src/hash.rs | 1 - keccak-hash/Cargo.toml | 6 +++--- kvdb-memorydb/Cargo.toml | 4 ++-- kvdb-rocksdb/Cargo.toml | 20 ++++++++++---------- kvdb-web/Cargo.toml | 12 ++++++------ kvdb/Cargo.toml | 4 ++-- parity-bytes/Cargo.toml | 2 +- parity-crypto/Cargo.toml | 18 +++++++++--------- parity-path/Cargo.toml | 4 ++-- parity-util-mem/Cargo.toml | 24 ++++++++++++------------ plain_hasher/Cargo.toml | 6 +++--- primitive-types/Cargo.toml | 4 ++-- primitive-types/impls/codec/Cargo.toml | 4 ++-- primitive-types/impls/rlp/Cargo.toml | 2 +- primitive-types/impls/serde/Cargo.toml | 6 +++--- rlp/Cargo.toml | 8 ++++---- trace-time/Cargo.toml | 4 ++-- transaction-pool/Cargo.toml | 8 ++++---- triehash/Cargo.toml | 16 ++++++++-------- uint/Cargo.toml | 16 ++++++++-------- uint/fuzz/Cargo.toml | 2 +- 25 files changed, 102 insertions(+), 103 deletions(-) diff --git a/contract-address/Cargo.toml b/contract-address/Cargo.toml index 83cd3ed13..f0a147ba3 100644 --- a/contract-address/Cargo.toml +++ b/contract-address/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "contract-address" -version = "0.3.0" +version = "0.3.1" authors = ["Parity Technologies "] license = "MIT" homepage = "https://github.com/paritytech/parity-common" @@ -11,7 +11,7 @@ edition = "2018" readme = "README.md" [dependencies] -ethereum-types = { version = "0.8", path = "../ethereum-types" } +ethereum-types = { version = "0.8.0", path = "../ethereum-types" } rlp = { version = "0.4", path = "../rlp" } keccak-hash = { version = "0.4", path = "../keccak-hash", default-features = false } diff --git a/ethbloom/Cargo.toml b/ethbloom/Cargo.toml index 829e2ac73..b65c88813 100644 --- a/ethbloom/Cargo.toml +++ b/ethbloom/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ethbloom" -version = "0.8.0" +version = "0.8.1" authors = ["Parity Technologies "] description = "Ethereum bloom filter" license = "MIT" @@ -10,16 +10,16 @@ repository = "https://github.com/paritytech/parity-common" edition = "2018" [dependencies] -tiny-keccak = "1.5" -crunchy = { version = "0.2", default-features = false, features = ["limit_256"] } +tiny-keccak = "1.5.0" +crunchy = { version = "0.2.2", default-features = false, features = ["limit_256"] } fixed-hash = { path = "../fixed-hash", version = "0.5", default-features = false } impl-serde = { path = "../primitive-types/impls/serde", version = "0.2", default-features = false, optional = true } impl-rlp = { path = "../primitive-types/impls/rlp", version = "0.2", default-features = false } [dev-dependencies] -criterion = "0.3" -rand = "0.7" -hex-literal = "0.2" +criterion = "0.3.0" +rand = "0.7.2" +hex-literal = "0.2.1" [features] default = ["std", "serialize", "libc", "rustc-hex"] diff --git a/ethereum-types/Cargo.toml b/ethereum-types/Cargo.toml index ae5550d23..18bb2927a 100644 --- a/ethereum-types/Cargo.toml +++ b/ethereum-types/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ethereum-types" -version = "0.8.0" +version = "0.8.1" authors = ["Parity Technologies "] license = "MIT" homepage = "https://github.com/paritytech/parity-common" @@ -16,7 +16,7 @@ impl-serde = { path = "../primitive-types/impls/serde", version = "0.2", default impl-rlp = { path = "../primitive-types/impls/rlp", version = "0.2", default-features = false } [dev-dependencies] -serde_json = "1.0" +serde_json = "1.0.41" [features] default = ["std", "serialize"] diff --git a/fixed-hash/Cargo.toml b/fixed-hash/Cargo.toml index 8672c6d31..5b019ecd9 100644 --- a/fixed-hash/Cargo.toml +++ b/fixed-hash/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fixed-hash" -version = "0.5.0" +version = "0.5.1" authors = ["Parity Technologies "] license = "MIT" homepage = "https://github.com/paritytech/parity-common" @@ -14,17 +14,17 @@ edition = "2018" features = ["quickcheck", "api-dummy"] [dependencies] -rand = { version = "0.7", optional = true, default-features = false } -rustc-hex = { version = "2.0", optional = true, default-features = false } -quickcheck = { version = "0.9", optional = true } -byteorder = { version = "1.2", optional = true, default-features = false } -static_assertions = "0.3" +rand = { version = "0.7.2", optional = true, default-features = false } +rustc-hex = { version = "2.0.1", optional = true, default-features = false } +quickcheck = { version = "0.9.0", optional = true } +byteorder = { version = "1.3.2", optional = true, default-features = false } +static_assertions = "1.0.0" [dev-dependencies] rand_xorshift = "0.2.0" [target.'cfg(not(target_os = "unknown"))'.dependencies] -libc = { version = "0.2", optional = true, default-features = false } +libc = { version = "0.2.62", optional = true, default-features = false } [features] default = ["std", "libc", "rand", "rustc-hex", "byteorder"] diff --git a/fixed-hash/src/hash.rs b/fixed-hash/src/hash.rs index f8ffcb426..393b4cc93 100644 --- a/fixed-hash/src/hash.rs +++ b/fixed-hash/src/hash.rs @@ -779,7 +779,6 @@ macro_rules! impl_ops_for_hash { macro_rules! impl_fixed_hash_conversions { ($large_ty:ident, $small_ty:ident) => { $crate::static_assertions::const_assert!( - VALID_SIZES; $crate::core_::mem::size_of::<$small_ty>() < $crate::core_::mem::size_of::<$large_ty>() ); diff --git a/keccak-hash/Cargo.toml b/keccak-hash/Cargo.toml index 365ea5805..d90da7964 100644 --- a/keccak-hash/Cargo.toml +++ b/keccak-hash/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "keccak-hash" -version = "0.4.0" +version = "0.4.1" description = "`keccak-hash` is a set of utility functions to facilitate working with Keccak hashes (256/512 bits long)." authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" @@ -9,11 +9,11 @@ license = "GPL-3.0" edition = "2018" [dependencies] -tiny-keccak = "1.4" +tiny-keccak = "1.5.0" primitive-types = { path = "../primitive-types", version = "0.6", default-features = false } [dev-dependencies] -tempdir = "0.3" +tempdir = "0.3.7" [features] default = ["std"] diff --git a/kvdb-memorydb/Cargo.toml b/kvdb-memorydb/Cargo.toml index 22312e8c0..d734e5865 100644 --- a/kvdb-memorydb/Cargo.toml +++ b/kvdb-memorydb/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kvdb-memorydb" -version = "0.1.2" +version = "0.1.3" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "A key-value in-memory database that implements the `KeyValueDB` trait" @@ -8,5 +8,5 @@ license = "GPL-3.0" edition = "2018" [dependencies] -parking_lot = "0.9" +parking_lot = "0.9.0" kvdb = { version = "0.1", path = "../kvdb" } diff --git a/kvdb-rocksdb/Cargo.toml b/kvdb-rocksdb/Cargo.toml index 76b2ed9ea..cda3cc24b 100644 --- a/kvdb-rocksdb/Cargo.toml +++ b/kvdb-rocksdb/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kvdb-rocksdb" -version = "0.1.5" +version = "0.1.6" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "kvdb implementation backed by rocksDB" @@ -8,16 +8,16 @@ license = "GPL-3.0" edition = "2018" [dependencies] -elastic-array = "0.10" +elastic-array = "0.10.2" fs-swap = "0.2.4" -interleaved-ordered = "0.1.0" +interleaved-ordered = "0.1.1" kvdb = { version = "0.1", path = "../kvdb" } -log = "0.4" -num_cpus = "1.10" -parking_lot = "0.9" -regex = "1.3" -parity-rocksdb = "0.5" +log = "0.4.8" +num_cpus = "1.10.1" +parking_lot = "0.9.0" +regex = "1.3.1" +parity-rocksdb = "0.5.1" [dev-dependencies] -tempdir = "0.3" -ethereum-types = { version = "0.8", path = "../ethereum-types" } +tempdir = "0.3.7" +ethereum-types = { version = "0.8.0", path = "../ethereum-types" } diff --git a/kvdb-web/Cargo.toml b/kvdb-web/Cargo.toml index 0774f586d..7a9e3d45e 100644 --- a/kvdb-web/Cargo.toml +++ b/kvdb-web/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kvdb-web" -version = "0.1.0" +version = "0.1.1" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "A key-value database for use in browsers" @@ -9,16 +9,16 @@ license = "GPL-3.0" edition = "2018" [dependencies] -wasm-bindgen = "0.2.49" -js-sys = "0.3.26" +wasm-bindgen = "0.2.51" +js-sys = "0.3.28" kvdb = { version = "0.1", path = "../kvdb" } kvdb-memorydb = { version = "0.1", path = "../kvdb-memorydb" } -futures-preview = "0.3.0-alpha.18" +futures-preview = "0.3.0-alpha.19" log = "0.4.8" send_wrapper = "0.2.0" [dependencies.web-sys] -version = "0.3.26" +version = "0.3.28" features = [ 'console', 'Window', @@ -38,6 +38,6 @@ features = [ [dev-dependencies] wasm-bindgen-test = "0.2.49" -futures-preview = { version = "0.3.0-alpha.18", features = ['compat'] } +futures-preview = { version = "0.3.0-alpha.19", features = ['compat'] } futures01 = { package = "futures", version = "0.1" } console_log = "0.1.2" diff --git a/kvdb/Cargo.toml b/kvdb/Cargo.toml index e0306dfe2..db7badb98 100644 --- a/kvdb/Cargo.toml +++ b/kvdb/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kvdb" -version = "0.1.0" +version = "0.1.1" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "Generic key-value trait" @@ -8,5 +8,5 @@ license = "GPL-3.0" edition = "2018" [dependencies] -elastic-array = "0.10" +elastic-array = "0.10.2" bytes = { package = "parity-bytes", version = "0.1", path = "../parity-bytes" } diff --git a/parity-bytes/Cargo.toml b/parity-bytes/Cargo.toml index 38be22ced..e49adce31 100644 --- a/parity-bytes/Cargo.toml +++ b/parity-bytes/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "parity-bytes" -version = "0.1.0" +version = "0.1.1" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "byte utilities for Parity" diff --git a/parity-crypto/Cargo.toml b/parity-crypto/Cargo.toml index 5bfda0aca..185a4cb15 100644 --- a/parity-crypto/Cargo.toml +++ b/parity-crypto/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "parity-crypto" -version = "0.4.1" +version = "0.4.2" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "Crypto utils used by ethstore and network." @@ -14,19 +14,19 @@ harness = false [dependencies] -tiny-keccak = "1.4" -scrypt = { version = "0.2", default-features = false } +tiny-keccak = "1.5.0" +scrypt = { version = "0.2.0", default-features = false } ripemd160 = "0.8.0" sha2 = "0.8.0" -digest = "0.8" -hmac = "0.7" +digest = "0.8.1" +hmac = "0.7.1" aes = "0.3.2" aes-ctr = "0.3.0" block-modes = "0.3.3" pbkdf2 = "0.3.0" -subtle = "2.1" -zeroize = "0.9.1" +subtle = "2.2.1" +zeroize = "0.10.1" [dev-dependencies] -criterion = "0.2" -hex-literal = "0.2" +criterion = "0.3.0" +hex-literal = "0.2.1" diff --git a/parity-path/Cargo.toml b/parity-path/Cargo.toml index b19b176c4..bf67c5f77 100644 --- a/parity-path/Cargo.toml +++ b/parity-path/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "parity-path" -version = "0.1.2" +version = "0.1.3" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "Path utilities" @@ -8,4 +8,4 @@ license = "GPL-3.0" edition = "2018" [dependencies] -home = "0.5" +home = "0.5.0" diff --git a/parity-util-mem/Cargo.toml b/parity-util-mem/Cargo.toml index a73d23c0a..8701598f0 100644 --- a/parity-util-mem/Cargo.toml +++ b/parity-util-mem/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "parity-util-mem" -version = "0.2.0" +version = "0.2.1" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "Collection of memory related utilities" @@ -8,27 +8,27 @@ license = "GPL-3.0" edition = "2018" [dependencies] -cfg-if = "0.1.6" +cfg-if = "0.1.10" malloc_size_of_derive = "0.1.0" -dlmalloc = { version = "0.1", features = ["global"], optional = true } -wee_alloc = { version = "0.4", optional = true } +dlmalloc = { version = "0.1.3", features = ["global"], optional = true } +wee_alloc = { version = "0.4.5", optional = true } # from https://github.com/microsoft/mimalloc: # mimalloc can be built in secure mode, # adding guard pages, randomized allocation, encrypted free lists, etc. # to protect against various heap vulnerabilities. # The performance penalty is only around 3% on average over our benchmarks. -mimallocator = { version = "0.1", features = ["secure"], optional = true } -mimalloc-sys = { version = "0.1", optional = true } +mimallocator = { version = "0.1.3", features = ["secure"], optional = true } +mimalloc-sys = { version = "0.1.6", optional = true } -elastic-array = { version = "0", optional = true } -ethereum-types = { version = "0", optional = true } -parking_lot = { version = "0", optional = true } +elastic-array = { version = "0.10.2", optional = true } +ethereum-types = { version = "0.8.0", optional = true, path = "../ethereum-types" } +parking_lot = { version = "0.9.0", optional = true } -[target.'cfg(target_os = "windows")'.dependencies.winapi] -version = "0.3.4" +[target.'cfg(target_os = "windows")'.dependencies] +winapi = "0.3.8" [target.'cfg(not(target_os = "windows"))'.dependencies.jemallocator] -version = "0.1" +version = "0.3.2" optional = true [features] diff --git a/plain_hasher/Cargo.toml b/plain_hasher/Cargo.toml index 2228b4a91..2a7f94989 100644 --- a/plain_hasher/Cargo.toml +++ b/plain_hasher/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "plain_hasher" description = "Hasher for 32-byte keys." -version = "0.2.1" +version = "0.2.2" authors = ["Parity Technologies "] license = "MIT" keywords = ["hash", "hasher"] @@ -10,10 +10,10 @@ categories = ["no-std"] edition = "2018" [dependencies] -crunchy = { version = "0.2", default-features = false } +crunchy = { version = "0.2.2", default-features = false } [dev-dependencies] -criterion = "0.3" +criterion = "0.3.0" [features] default = ["std"] diff --git a/primitive-types/Cargo.toml b/primitive-types/Cargo.toml index a73b00644..69b296cc2 100644 --- a/primitive-types/Cargo.toml +++ b/primitive-types/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "primitive-types" -version = "0.6.0" +version = "0.6.1" authors = ["Parity Technologies "] license = "Apache-2.0/MIT" homepage = "https://github.com/paritytech/parity-common" @@ -8,7 +8,7 @@ description = "Primitive types shared by Ethereum and Substrate" [dependencies] fixed-hash = { version = "0.5", path = "../fixed-hash", default-features = false } -uint = { version = "0.8", path = "../uint", default-features = false } +uint = { version = "0.8.1", default-features = false } impl-serde = { version = "0.2.1", path = "impls/serde", default-features = false, optional = true } impl-codec = { version = "0.4.1", path = "impls/codec", default-features = false, optional = true } impl-rlp = { version = "0.2", path = "impls/rlp", default-features = false, optional = true } diff --git a/primitive-types/impls/codec/Cargo.toml b/primitive-types/impls/codec/Cargo.toml index cc35994f1..d4527aa48 100644 --- a/primitive-types/impls/codec/Cargo.toml +++ b/primitive-types/impls/codec/Cargo.toml @@ -1,13 +1,13 @@ [package] name = "impl-codec" -version = "0.4.1" +version = "0.4.2" authors = ["Parity Technologies "] license = "Apache-2.0/MIT" homepage = "https://github.com/paritytech/parity-common" description = "Parity Codec serialization support for uint and fixed hash." [dependencies] -parity-scale-codec = { version = "1.0.3", default-features = false } +parity-scale-codec = { version = "1.0.6", default-features = false } [features] default = ["std"] diff --git a/primitive-types/impls/rlp/Cargo.toml b/primitive-types/impls/rlp/Cargo.toml index f2de4e8ba..6f6f469cd 100644 --- a/primitive-types/impls/rlp/Cargo.toml +++ b/primitive-types/impls/rlp/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "impl-rlp" -version = "0.2.0" +version = "0.2.1" authors = ["Parity Technologies "] license = "Apache-2.0/MIT" homepage = "https://github.com/paritytech/parity-common" diff --git a/primitive-types/impls/serde/Cargo.toml b/primitive-types/impls/serde/Cargo.toml index 77a70be6c..72295f334 100644 --- a/primitive-types/impls/serde/Cargo.toml +++ b/primitive-types/impls/serde/Cargo.toml @@ -1,18 +1,18 @@ [package] name = "impl-serde" -version = "0.2.1" +version = "0.2.2" authors = ["Parity Technologies "] license = "Apache-2.0/MIT" homepage = "https://github.com/paritytech/parity-common" description = "Serde serialization support for uint and fixed hash." [dependencies] -serde = "1.0" +serde = "1.0.101" [dev-dependencies] criterion = "0.3.0" uint = "0.8.1" -serde_json = "1.0.40" +serde_json = "1.0.41" [[bench]] name = "impl_serde" diff --git a/rlp/Cargo.toml b/rlp/Cargo.toml index 83900e213..0fd6e9b5b 100644 --- a/rlp/Cargo.toml +++ b/rlp/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rlp" -version = "0.4.2" +version = "0.4.3" description = "Recursive-length prefix encoding, decoding, and compression" repository = "https://github.com/paritytech/parity-common" license = "MIT/Apache-2.0" @@ -8,11 +8,11 @@ authors = ["Parity Technologies "] edition = "2018" [dependencies] -rustc-hex = { version = "2.0", default-features = false } +rustc-hex = { version = "2.0.1", default-features = false } [dev-dependencies] -criterion = "0.3" -hex-literal = "0.2" +criterion = "0.3.0" +hex-literal = "0.2.1" primitive-types = { path = "../primitive-types", version = "0.6", features = ["impl-rlp"] } [features] diff --git a/trace-time/Cargo.toml b/trace-time/Cargo.toml index 5dad32a52..f1ec6e9a1 100644 --- a/trace-time/Cargo.toml +++ b/trace-time/Cargo.toml @@ -1,11 +1,11 @@ [package] name = "trace-time" description = "Easily trace time to execute a scope." -version = "0.1.1" +version = "0.1.2" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" license = "GPL-3.0" edition = "2018" [dependencies] -log = "0.4" +log = "0.4.8" diff --git a/transaction-pool/Cargo.toml b/transaction-pool/Cargo.toml index fb442756c..844607efa 100644 --- a/transaction-pool/Cargo.toml +++ b/transaction-pool/Cargo.toml @@ -1,16 +1,16 @@ [package] description = "Generic transaction pool." name = "transaction-pool" -version = "2.0.1" +version = "2.0.2" license = "GPL-3.0" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" edition = "2018" [dependencies] -log = "0.4" -smallvec = "0.6" +log = "0.4.8" +smallvec = "0.6.10" trace-time = { path = "../trace-time", version = "0.1" } [dev-dependencies] -ethereum-types = { version = "0.8", path = "../ethereum-types" } +ethereum-types = { version = "0.8.0", path = "../ethereum-types" } diff --git a/triehash/Cargo.toml b/triehash/Cargo.toml index ff2133d13..6342f7d03 100644 --- a/triehash/Cargo.toml +++ b/triehash/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "triehash" -version = "0.8.0" +version = "0.8.1" authors = ["Parity Technologies "] description = "In-memory patricia trie operations" repository = "https://github.com/paritytech/parity-common" @@ -8,16 +8,16 @@ license = "GPL-3.0" edition = "2018" [dependencies] -hash-db = "0.15" +hash-db = "0.15.2" rlp = { version = "0.4", path = "../rlp" } [dev-dependencies] -criterion = "0.3" -keccak-hasher = "0.15" -ethereum-types = { version = "0.8", path = "../ethereum-types" } -tiny-keccak = "1.5" -trie-standardmap = "0.15" -hex-literal = "0.2" +criterion = "0.3.0" +keccak-hasher = "0.15.2" +ethereum-types = { version = "0.8.0", path = "../ethereum-types" } +tiny-keccak = "1.5.0" +trie-standardmap = "0.15.2" +hex-literal = "0.2.1" [[bench]] name = "triehash" diff --git a/uint/Cargo.toml b/uint/Cargo.toml index e35d809b6..96e062d37 100644 --- a/uint/Cargo.toml +++ b/uint/Cargo.toml @@ -4,16 +4,16 @@ homepage = "http://parity.io" repository = "https://github.com/paritytech/parity-common" license = "MIT/Apache-2.0" name = "uint" -version = "0.8.1" +version = "0.8.2" authors = ["Parity Technologies "] readme = "README.md" edition = "2018" [dependencies] -byteorder = { version = "1", default-features = false } -rustc-hex = { version = "2.0", default-features = false } -quickcheck = { version = "0.6", optional = true } -crunchy = { version = "0.2", default-features = true } +byteorder = { version = "1.3.2", default-features = false } +rustc-hex = { version = "2.0.1", default-features = false } +quickcheck = { version = "0.9.0", optional = true } +crunchy = { version = "0.2.2", default-features = true } [features] default = ["std"] @@ -27,11 +27,11 @@ name = "uint_tests" required-features = ["std"] [dev-dependencies] -criterion = "0.2.11" -num-bigint = "0.2" +criterion = "0.3.0" +num-bigint = "0.2.3" [target.'cfg(unix)'.dev-dependencies] -rug = { version = "1.4", default-features = false, features = ["integer"] } +rug = { version = "1.6.0", default-features = false, features = ["integer"] } [[bench]] name = "bigint" diff --git a/uint/fuzz/Cargo.toml b/uint/fuzz/Cargo.toml index 151c851cb..3a78a5b09 100644 --- a/uint/fuzz/Cargo.toml +++ b/uint/fuzz/Cargo.toml @@ -2,7 +2,7 @@ name = "uint-fuzz" description = "Fuzzers for uint algorithms" publish = false -version = "0.1.0" +version = "0.1.1" authors = ["Parity Technologies "] edition = "2018" From 4539e5897338dc323b8d3461804ae9c00c3325a7 Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Wed, 9 Oct 2019 15:58:53 -0400 Subject: [PATCH 02/12] try to fix compile errors --- contract-address/Cargo.toml | 2 +- parity-crypto/Cargo.toml | 2 +- primitive-types/Cargo.toml | 2 +- uint/Cargo.toml | 3 ++- uint/examples/modular.rs | 2 ++ uint/src/uint.rs | 2 +- uint/tests/uint_tests.rs | 2 ++ 7 files changed, 10 insertions(+), 5 deletions(-) diff --git a/contract-address/Cargo.toml b/contract-address/Cargo.toml index f0a147ba3..2436c4e85 100644 --- a/contract-address/Cargo.toml +++ b/contract-address/Cargo.toml @@ -11,7 +11,7 @@ edition = "2018" readme = "README.md" [dependencies] -ethereum-types = { version = "0.8.0", path = "../ethereum-types" } +ethereum-types = { version = "0.8.1", path = "../ethereum-types" } rlp = { version = "0.4", path = "../rlp" } keccak-hash = { version = "0.4", path = "../keccak-hash", default-features = false } diff --git a/parity-crypto/Cargo.toml b/parity-crypto/Cargo.toml index 185a4cb15..530d16ba4 100644 --- a/parity-crypto/Cargo.toml +++ b/parity-crypto/Cargo.toml @@ -25,7 +25,7 @@ aes-ctr = "0.3.0" block-modes = "0.3.3" pbkdf2 = "0.3.0" subtle = "2.2.1" -zeroize = "0.10.1" +zeroize = { version = "0.10.1", default-features = false } [dev-dependencies] criterion = "0.3.0" diff --git a/primitive-types/Cargo.toml b/primitive-types/Cargo.toml index 69b296cc2..46fa7317e 100644 --- a/primitive-types/Cargo.toml +++ b/primitive-types/Cargo.toml @@ -8,7 +8,7 @@ description = "Primitive types shared by Ethereum and Substrate" [dependencies] fixed-hash = { version = "0.5", path = "../fixed-hash", default-features = false } -uint = { version = "0.8.1", default-features = false } +uint = { version = "0.8.1", path = "../uint", default-features = false } impl-serde = { version = "0.2.1", path = "impls/serde", default-features = false, optional = true } impl-codec = { version = "0.4.1", path = "impls/codec", default-features = false, optional = true } impl-rlp = { version = "0.2", path = "impls/rlp", default-features = false, optional = true } diff --git a/uint/Cargo.toml b/uint/Cargo.toml index 96e062d37..1b69a226c 100644 --- a/uint/Cargo.toml +++ b/uint/Cargo.toml @@ -13,7 +13,7 @@ edition = "2018" byteorder = { version = "1.3.2", default-features = false } rustc-hex = { version = "2.0.1", default-features = false } quickcheck = { version = "0.9.0", optional = true } -crunchy = { version = "0.2.2", default-features = true } +crunchy = { version = "0.2.2", default-features = false } [features] default = ["std"] @@ -29,6 +29,7 @@ required-features = ["std"] [dev-dependencies] criterion = "0.3.0" num-bigint = "0.2.3" +rand = "0.7.2" [target.'cfg(unix)'.dev-dependencies] rug = { version = "1.6.0", default-features = false, features = ["integer"] } diff --git a/uint/examples/modular.rs b/uint/examples/modular.rs index 6cd9f7409..1728110cb 100644 --- a/uint/examples/modular.rs +++ b/uint/examples/modular.rs @@ -11,6 +11,8 @@ extern crate core; #[macro_use] extern crate uint; +extern crate rand; +use rand::Rng; construct_uint! { pub struct U256(4); diff --git a/uint/src/uint.rs b/uint/src/uint.rs index cc58ee220..7f655fc66 100644 --- a/uint/src/uint.rs +++ b/uint/src/uint.rs @@ -1577,7 +1577,7 @@ macro_rules! impl_quickcheck_arbitrary_for_uint { fn arbitrary(g: &mut G) -> Self { let mut res = [0u8; $n_bytes]; - let p = g.next_f64(); + let p: f64 = rand::rngs::OsRng.gen(); // make it more likely to generate smaller numbers that // don't use up the full $n_bytes let range = diff --git a/uint/tests/uint_tests.rs b/uint/tests/uint_tests.rs index de77b828e..1ff5b4a3a 100644 --- a/uint/tests/uint_tests.rs +++ b/uint/tests/uint_tests.rs @@ -14,6 +14,7 @@ use core::u64::MAX; use core::str::FromStr; use core::convert::TryInto; use uint::{FromDecStrErr}; +extern crate rand; construct_uint! { pub struct U256(4); @@ -1101,6 +1102,7 @@ fn trailing_zeros() { #[cfg(feature="quickcheck")] pub mod laws { + use super::Rng; macro_rules! uint_laws { ($mod_name:ident, $uint_ty:ident) => { mod $mod_name { From 8bc96c015e697e6c27a14579fd5fb9f814662e1b Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Wed, 9 Oct 2019 16:29:33 -0400 Subject: [PATCH 03/12] fix silly wrong import --- uint/tests/uint_tests.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/uint/tests/uint_tests.rs b/uint/tests/uint_tests.rs index 1ff5b4a3a..cad5206db 100644 --- a/uint/tests/uint_tests.rs +++ b/uint/tests/uint_tests.rs @@ -1102,7 +1102,7 @@ fn trailing_zeros() { #[cfg(feature="quickcheck")] pub mod laws { - use super::Rng; + use crate::rand::Rng; macro_rules! uint_laws { ($mod_name:ident, $uint_ty:ident) => { mod $mod_name { From 6c2a08787e398b03e394127258b36e83eb6e3a0d Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Wed, 9 Oct 2019 17:03:20 -0400 Subject: [PATCH 04/12] =?UTF-8?q?Don=E2=80=99t=20require=20users=20of=20`u?= =?UTF-8?q?int`=20to=20import=20`rand`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit unless they use `rand` themselves. --- uint/Cargo.toml | 4 ++-- uint/examples/modular.rs | 2 -- uint/src/uint.rs | 6 +++++- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/uint/Cargo.toml b/uint/Cargo.toml index 1b69a226c..e62e04fa2 100644 --- a/uint/Cargo.toml +++ b/uint/Cargo.toml @@ -14,10 +14,11 @@ byteorder = { version = "1.3.2", default-features = false } rustc-hex = { version = "2.0.1", default-features = false } quickcheck = { version = "0.9.0", optional = true } crunchy = { version = "0.2.2", default-features = false } +rand = { version = "0.7.2", default-features = false } [features] default = ["std"] -std = ["byteorder/std", "rustc-hex/std", "crunchy/std"] +std = ["byteorder/std", "rustc-hex/std", "crunchy/std", "rand/std"] [[example]] name = "modular" @@ -29,7 +30,6 @@ required-features = ["std"] [dev-dependencies] criterion = "0.3.0" num-bigint = "0.2.3" -rand = "0.7.2" [target.'cfg(unix)'.dev-dependencies] rug = { version = "1.6.0", default-features = false, features = ["integer"] } diff --git a/uint/examples/modular.rs b/uint/examples/modular.rs index 1728110cb..6cd9f7409 100644 --- a/uint/examples/modular.rs +++ b/uint/examples/modular.rs @@ -11,8 +11,6 @@ extern crate core; #[macro_use] extern crate uint; -extern crate rand; -use rand::Rng; construct_uint! { pub struct U256(4); diff --git a/uint/src/uint.rs b/uint/src/uint.rs index 7f655fc66..6bcd78ab9 100644 --- a/uint/src/uint.rs +++ b/uint/src/uint.rs @@ -38,6 +38,9 @@ pub enum FromDecStrErr { InvalidLength, } +#[doc(hidden)] +pub extern crate rand; + #[macro_export] #[doc(hidden)] macro_rules! impl_map_from { @@ -1577,7 +1580,8 @@ macro_rules! impl_quickcheck_arbitrary_for_uint { fn arbitrary(g: &mut G) -> Self { let mut res = [0u8; $n_bytes]; - let p: f64 = rand::rngs::OsRng.gen(); + use $crate::rand::Rng; + let p: f64 = $crate::rand::rngs::OsRng.gen(); // make it more likely to generate smaller numbers that // don't use up the full $n_bytes let range = From 2c32f26234e0601354df614f43d8845ac4c9986f Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Tue, 15 Oct 2019 15:45:14 -0400 Subject: [PATCH 05/12] Remove spurious version bump and extern crate --- contract-address/Cargo.toml | 2 +- ethereum-types/Cargo.toml | 2 +- uint/tests/uint_tests.rs | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/contract-address/Cargo.toml b/contract-address/Cargo.toml index 2436c4e85..f0a147ba3 100644 --- a/contract-address/Cargo.toml +++ b/contract-address/Cargo.toml @@ -11,7 +11,7 @@ edition = "2018" readme = "README.md" [dependencies] -ethereum-types = { version = "0.8.1", path = "../ethereum-types" } +ethereum-types = { version = "0.8.0", path = "../ethereum-types" } rlp = { version = "0.4", path = "../rlp" } keccak-hash = { version = "0.4", path = "../keccak-hash", default-features = false } diff --git a/ethereum-types/Cargo.toml b/ethereum-types/Cargo.toml index 18bb2927a..eb1a85e20 100644 --- a/ethereum-types/Cargo.toml +++ b/ethereum-types/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ethereum-types" -version = "0.8.1" +version = "0.8.0" authors = ["Parity Technologies "] license = "MIT" homepage = "https://github.com/paritytech/parity-common" diff --git a/uint/tests/uint_tests.rs b/uint/tests/uint_tests.rs index cad5206db..3ab11877e 100644 --- a/uint/tests/uint_tests.rs +++ b/uint/tests/uint_tests.rs @@ -14,7 +14,6 @@ use core::u64::MAX; use core::str::FromStr; use core::convert::TryInto; use uint::{FromDecStrErr}; -extern crate rand; construct_uint! { pub struct U256(4); From 67b3008f0e383765d7c33737ea1cfb71a05ac2ae Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Tue, 15 Oct 2019 16:56:52 -0400 Subject: [PATCH 06/12] Fix silly bogus import path --- uint/src/uint.rs | 2 +- uint/tests/uint_tests.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/uint/src/uint.rs b/uint/src/uint.rs index 6bcd78ab9..3ba7d8b18 100644 --- a/uint/src/uint.rs +++ b/uint/src/uint.rs @@ -39,7 +39,7 @@ pub enum FromDecStrErr { } #[doc(hidden)] -pub extern crate rand; +pub use rand; #[macro_export] #[doc(hidden)] diff --git a/uint/tests/uint_tests.rs b/uint/tests/uint_tests.rs index 3ab11877e..9a8e1921f 100644 --- a/uint/tests/uint_tests.rs +++ b/uint/tests/uint_tests.rs @@ -1101,7 +1101,7 @@ fn trailing_zeros() { #[cfg(feature="quickcheck")] pub mod laws { - use crate::rand::Rng; + use crate::uint::rand::Rng; macro_rules! uint_laws { ($mod_name:ident, $uint_ty:ident) => { mod $mod_name { From d93ce329f09d9825f8c30a2d3dbd2241d55df7c0 Mon Sep 17 00:00:00 2001 From: Demi Obenour <48690212+DemiMarie-parity@users.noreply.github.com> Date: Wed, 16 Oct 2019 10:59:47 -0400 Subject: [PATCH 07/12] =?UTF-8?q?Don=E2=80=99t=20bump=20crate=20versions?= =?UTF-8?q?=20unnecessarily?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Andronik Ordian --- contract-address/Cargo.toml | 2 +- kvdb-memorydb/Cargo.toml | 2 +- parity-path/Cargo.toml | 2 +- primitive-types/impls/rlp/Cargo.toml | 2 +- uint/fuzz/Cargo.toml | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/contract-address/Cargo.toml b/contract-address/Cargo.toml index f0a147ba3..8b4f05682 100644 --- a/contract-address/Cargo.toml +++ b/contract-address/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "contract-address" -version = "0.3.1" +version = "0.3.0" authors = ["Parity Technologies "] license = "MIT" homepage = "https://github.com/paritytech/parity-common" diff --git a/kvdb-memorydb/Cargo.toml b/kvdb-memorydb/Cargo.toml index d734e5865..4ee909d4a 100644 --- a/kvdb-memorydb/Cargo.toml +++ b/kvdb-memorydb/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kvdb-memorydb" -version = "0.1.3" +version = "0.1.2" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "A key-value in-memory database that implements the `KeyValueDB` trait" diff --git a/parity-path/Cargo.toml b/parity-path/Cargo.toml index bf67c5f77..7839635ca 100644 --- a/parity-path/Cargo.toml +++ b/parity-path/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "parity-path" -version = "0.1.3" +version = "0.1.2" authors = ["Parity Technologies "] repository = "https://github.com/paritytech/parity-common" description = "Path utilities" diff --git a/primitive-types/impls/rlp/Cargo.toml b/primitive-types/impls/rlp/Cargo.toml index 6f6f469cd..f2de4e8ba 100644 --- a/primitive-types/impls/rlp/Cargo.toml +++ b/primitive-types/impls/rlp/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "impl-rlp" -version = "0.2.1" +version = "0.2.0" authors = ["Parity Technologies "] license = "Apache-2.0/MIT" homepage = "https://github.com/paritytech/parity-common" diff --git a/uint/fuzz/Cargo.toml b/uint/fuzz/Cargo.toml index 3a78a5b09..151c851cb 100644 --- a/uint/fuzz/Cargo.toml +++ b/uint/fuzz/Cargo.toml @@ -2,7 +2,7 @@ name = "uint-fuzz" description = "Fuzzers for uint algorithms" publish = false -version = "0.1.1" +version = "0.1.0" authors = ["Parity Technologies "] edition = "2018" From c1cd0f6c0c12bfccac10cbcc834098a052c8c2cb Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Wed, 16 Oct 2019 11:25:00 -0400 Subject: [PATCH 08/12] =?UTF-8?q?Don=E2=80=99t=20explicitly=20depend=20on?= =?UTF-8?q?=20`rand`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- uint/Cargo.toml | 3 +-- uint/src/uint.rs | 6 +----- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/uint/Cargo.toml b/uint/Cargo.toml index e62e04fa2..98c3fee1c 100644 --- a/uint/Cargo.toml +++ b/uint/Cargo.toml @@ -14,11 +14,10 @@ byteorder = { version = "1.3.2", default-features = false } rustc-hex = { version = "2.0.1", default-features = false } quickcheck = { version = "0.9.0", optional = true } crunchy = { version = "0.2.2", default-features = false } -rand = { version = "0.7.2", default-features = false } [features] default = ["std"] -std = ["byteorder/std", "rustc-hex/std", "crunchy/std", "rand/std"] +std = ["byteorder/std", "rustc-hex/std", "crunchy/std"] [[example]] name = "modular" diff --git a/uint/src/uint.rs b/uint/src/uint.rs index 3ba7d8b18..6f2928280 100644 --- a/uint/src/uint.rs +++ b/uint/src/uint.rs @@ -38,9 +38,6 @@ pub enum FromDecStrErr { InvalidLength, } -#[doc(hidden)] -pub use rand; - #[macro_export] #[doc(hidden)] macro_rules! impl_map_from { @@ -1580,8 +1577,7 @@ macro_rules! impl_quickcheck_arbitrary_for_uint { fn arbitrary(g: &mut G) -> Self { let mut res = [0u8; $n_bytes]; - use $crate::rand::Rng; - let p: f64 = $crate::rand::rngs::OsRng.gen(); + let p = G::gen(); // make it more likely to generate smaller numbers that // don't use up the full $n_bytes let range = From 96c5a329fd00ce8f3c99e0c2165282933be2cf29 Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Wed, 16 Oct 2019 18:45:08 -0400 Subject: [PATCH 09/12] =?UTF-8?q?Revert=20"Don=E2=80=99t=20explicitly=20de?= =?UTF-8?q?pend=20on=20`rand`"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit c1cd0f6c0c12bfccac10cbcc834098a052c8c2cb. --- uint/Cargo.toml | 3 ++- uint/src/uint.rs | 6 +++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/uint/Cargo.toml b/uint/Cargo.toml index 98c3fee1c..e62e04fa2 100644 --- a/uint/Cargo.toml +++ b/uint/Cargo.toml @@ -14,10 +14,11 @@ byteorder = { version = "1.3.2", default-features = false } rustc-hex = { version = "2.0.1", default-features = false } quickcheck = { version = "0.9.0", optional = true } crunchy = { version = "0.2.2", default-features = false } +rand = { version = "0.7.2", default-features = false } [features] default = ["std"] -std = ["byteorder/std", "rustc-hex/std", "crunchy/std"] +std = ["byteorder/std", "rustc-hex/std", "crunchy/std", "rand/std"] [[example]] name = "modular" diff --git a/uint/src/uint.rs b/uint/src/uint.rs index 70db7a011..baf226503 100644 --- a/uint/src/uint.rs +++ b/uint/src/uint.rs @@ -38,6 +38,9 @@ pub enum FromDecStrErr { InvalidLength, } +#[doc(hidden)] +pub use rand; + #[macro_export] #[doc(hidden)] macro_rules! impl_map_from { @@ -1582,7 +1585,8 @@ macro_rules! impl_quickcheck_arbitrary_for_uint { fn arbitrary(g: &mut G) -> Self { let mut res = [0u8; $n_bytes]; - let p = G::gen(); + use $crate::rand::Rng; + let p: f64 = $crate::rand::rngs::OsRng.gen(); // make it more likely to generate smaller numbers that // don't use up the full $n_bytes let range = From f7cccb8867eef08655487495a472886f3efc8709 Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Sat, 19 Oct 2019 18:57:45 -0400 Subject: [PATCH 10/12] Avoid depending explicitly on `rand`. --- uint/Cargo.toml | 7 ++++--- uint/src/lib.rs | 6 +++++- uint/src/uint.rs | 7 ++----- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/uint/Cargo.toml b/uint/Cargo.toml index e62e04fa2..b57395864 100644 --- a/uint/Cargo.toml +++ b/uint/Cargo.toml @@ -12,13 +12,14 @@ edition = "2018" [dependencies] byteorder = { version = "1.3.2", default-features = false } rustc-hex = { version = "2.0.1", default-features = false } -quickcheck = { version = "0.9.0", optional = true } +qc = { package = "quickcheck", version = "0.9.0", optional = true } crunchy = { version = "0.2.2", default-features = false } -rand = { version = "0.7.2", default-features = false } +rand = { version = "0.7.2", default-features = false, optional = true } [features] default = ["std"] -std = ["byteorder/std", "rustc-hex/std", "crunchy/std", "rand/std"] +std = ["byteorder/std", "rustc-hex/std", "crunchy/std"] +quickcheck = ["qc", "rand"] [[example]] name = "modular" diff --git a/uint/src/lib.rs b/uint/src/lib.rs index 5f803a271..44bcab34c 100644 --- a/uint/src/lib.rs +++ b/uint/src/lib.rs @@ -23,7 +23,11 @@ pub use rustc_hex; #[cfg(feature="quickcheck")] #[doc(hidden)] -pub use quickcheck; +pub use qc; + +#[cfg(feature="quickcheck")] +#[doc(hidden)] +pub use rand; #[doc(hidden)] pub use crunchy::unroll; diff --git a/uint/src/uint.rs b/uint/src/uint.rs index baf226503..cf339d7ab 100644 --- a/uint/src/uint.rs +++ b/uint/src/uint.rs @@ -38,9 +38,6 @@ pub enum FromDecStrErr { InvalidLength, } -#[doc(hidden)] -pub use rand; - #[macro_export] #[doc(hidden)] macro_rules! impl_map_from { @@ -1581,8 +1578,8 @@ macro_rules! impl_std_for_uint { #[doc(hidden)] macro_rules! impl_quickcheck_arbitrary_for_uint { ($uint: ty, $n_bytes: tt) => { - impl $crate::quickcheck::Arbitrary for $uint { - fn arbitrary(g: &mut G) -> Self { + impl $crate::qc::Arbitrary for $uint { + fn arbitrary(g: &mut G) -> Self { let mut res = [0u8; $n_bytes]; use $crate::rand::Rng; From 3ef8426cc061a1986869763ea372779d5d8a6a41 Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Sat, 19 Oct 2019 19:05:24 -0400 Subject: [PATCH 11/12] Bump `send_wrapper` --- kvdb-web/Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kvdb-web/Cargo.toml b/kvdb-web/Cargo.toml index 7a9e3d45e..aaf237da8 100644 --- a/kvdb-web/Cargo.toml +++ b/kvdb-web/Cargo.toml @@ -15,7 +15,7 @@ kvdb = { version = "0.1", path = "../kvdb" } kvdb-memorydb = { version = "0.1", path = "../kvdb-memorydb" } futures-preview = "0.3.0-alpha.19" log = "0.4.8" -send_wrapper = "0.2.0" +send_wrapper = "0.3.0" [dependencies.web-sys] version = "0.3.28" From 2142fc65195a41ff37f7433efb2809d482a289f0 Mon Sep 17 00:00:00 2001 From: "Demi M. Obenour" Date: Mon, 21 Oct 2019 10:27:02 -0400 Subject: [PATCH 12/12] Fix silly mistake in tests as pointed out by @ordin. --- uint/tests/uint_tests.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/uint/tests/uint_tests.rs b/uint/tests/uint_tests.rs index 7f36b6a65..0dedc0723 100644 --- a/uint/tests/uint_tests.rs +++ b/uint/tests/uint_tests.rs @@ -1102,7 +1102,7 @@ pub mod laws { macro_rules! uint_laws { ($mod_name:ident, $uint_ty:ident) => { mod $mod_name { - use quickcheck::{TestResult, quickcheck}; + use qc::{TestResult, quickcheck}; use super::$uint_ty; quickcheck! {