From bf0c895719d4188abed15a2357fb4e8882485c4b Mon Sep 17 00:00:00 2001 From: librelois <c@elo.tf> Date: Thu, 10 Dec 2020 02:11:19 +0100 Subject: [PATCH] [deps] upgrade dubp-rs-libs to 0.33.0 --- Cargo.lock | 28 +++++++++---------- Cargo.toml | 2 -- neon/native/Cargo.toml | 2 +- neon/native/src/transaction.rs | 4 +-- rust-bins/duniter-dbex/Cargo.toml | 2 +- rust-libs/duniter-conf/Cargo.toml | 2 +- rust-libs/duniter-dbs-read-ops/Cargo.toml | 2 +- rust-libs/duniter-dbs-write-ops/Cargo.toml | 2 +- rust-libs/duniter-dbs/Cargo.toml | 2 +- rust-libs/duniter-mempools/Cargo.toml | 2 +- rust-libs/duniter-module/Cargo.toml | 2 +- rust-libs/duniter-server/Cargo.toml | 2 +- rust-libs/modules/gva/Cargo.toml | 2 +- rust-libs/modules/gva/db-writer/Cargo.toml | 2 +- rust-libs/modules/gva/dbs-reader/Cargo.toml | 2 +- rust-libs/modules/gva/src/mutations.rs | 4 +-- .../duniter-integration-tests/Cargo.toml | 2 +- 17 files changed, 31 insertions(+), 33 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 858903e22..221be3944 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -958,9 +958,9 @@ checksum = "134951f4028bdadb9b84baf4232681efbf277da25144b9b0ad65df75946c422b" [[package]] name = "dubp" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc9edc056137805e63c68584a3066ff3ad83e00e434a2bfcbac8b5160decc5ac" +checksum = "f2a6192b0248f4b198e9193a59ee73e26ee2feba9b7c4995e628d11d2c19448a" dependencies = [ "dubp-block", "dubp-common", @@ -972,9 +972,9 @@ dependencies = [ [[package]] name = "dubp-block" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9bad4399d077e9d85c6dba2d8f69b7b0088ca3b52564ccc9593ccf8b34f1878" +checksum = "4f59b0253ba66aee87741603f20bab7d67e2ebe11f2bbff58bbc08486b132bb2" dependencies = [ "dubp-documents", "dubp-documents-parser", @@ -987,9 +987,9 @@ dependencies = [ [[package]] name = "dubp-common" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e5079ffa4de9355caa45f098d6a8f92c9dc3df595ba1460a0ceca73b950f626" +checksum = "a927b5f18b8d5f04b6d1ca179a5678f5f559140844268f78c6872d20fd6f6178" dependencies = [ "dup-crypto", "serde", @@ -1000,9 +1000,9 @@ dependencies = [ [[package]] name = "dubp-documents" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03f03022e76dc830f125ec2983ec8e580c6f46dd005473f182ae71b2cd905af5" +checksum = "7ccce9aabcb92de2befbbd4360fc73d806df63dce414274bef427de2a7acb725" dependencies = [ "beef", "dubp-wallet", @@ -1014,9 +1014,9 @@ dependencies = [ [[package]] name = "dubp-documents-parser" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54c812d14ad4df502f96d0f32e7459588314791dd2d04640c4102793f2844c04" +checksum = "abaa735586c05cc4cd1f240eb9531a9762d97e0f55a335e6e11658f4b10f29af" dependencies = [ "dubp-documents", "json-pest-parser", @@ -1028,9 +1028,9 @@ dependencies = [ [[package]] name = "dubp-wallet" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b03ead2777d7845c0e1fc9aa8b5f71c71a31e90e37189c4b515bd21635acf64" +checksum = "0b73e3ae439e2eba8048ca9830a821cd6cbb51010e0049efc72e201433e6a61d" dependencies = [ "byteorder", "dubp-common", @@ -1292,9 +1292,9 @@ dependencies = [ [[package]] name = "dup-crypto" -version = "0.32.3" +version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64160d6011423b13588070b6cd58325536eec930c816ebc367e662bfbd4e23d2" +checksum = "3e577ae936c53b85818749d1eefedf1d1afd6e0a8286b88543cb068396c16069" dependencies = [ "base64", "bs58", diff --git a/Cargo.toml b/Cargo.toml index 01a141218..382b77291 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -50,9 +50,7 @@ members = [ [patch.crates-io] #dubp = { git = "https://git.duniter.org/libs/dubp-rs-libs" } -#dubp-common = { git = "https://git.duniter.org/libs/dubp-rs-libs" } #dubp = { path = "../dubp-rs-libs" } -#dubp-common = { path = "../dubp-rs-libs/common" } #leveldb_minimal = { path = "../../../../rust/leveldb_minimal" } diff --git a/neon/native/Cargo.toml b/neon/native/Cargo.toml index 3d6cb41f1..569c57566 100644 --- a/neon/native/Cargo.toml +++ b/neon/native/Cargo.toml @@ -17,7 +17,7 @@ neon-build = "0.4.0" [dependencies] bincode = "1.2.1" bs58 = "0.3.0" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } dubp-wot = { path = "../../rust-libs/dubp-wot" } duniter-server = { path = "../../rust-libs/duniter-server" } flate2 = "1.0.16" diff --git a/neon/native/src/transaction.rs b/neon/native/src/transaction.rs index 628b32199..5206c3491 100644 --- a/neon/native/src/transaction.rs +++ b/neon/native/src/transaction.rs @@ -34,7 +34,7 @@ pub fn raw_tx_parse_and_verify(mut cx: FunctionContext) -> JsResult<JsValue> { match TransactionDocumentV10::parse_from_raw_text(&raw_tx) { Ok(tx) => { - if let Err(e) = tx.verify(currency_opt) { + if let Err(e) = tx.verify(currency_opt.as_deref()) { cx.throw_error(format!("{}", e)) } else { let tx_stringified = tx.to_string_object(); @@ -57,7 +57,7 @@ pub fn tx_verify(mut cx: FunctionContext) -> JsResult<JsUndefined> { neon_serde::from_value(&mut cx, tx_obj)?; match TransactionDocumentV10::from_string_object(&tx_stringified) { Ok(tx) => { - if let Err(e) = tx.verify(currency_opt) { + if let Err(e) = tx.verify(currency_opt.as_deref()) { cx.throw_error(format!("{}", e)) } else { Ok(cx.undefined()) diff --git a/rust-bins/duniter-dbex/Cargo.toml b/rust-bins/duniter-dbex/Cargo.toml index 4ca70ed24..ec9a94084 100644 --- a/rust-bins/duniter-dbex/Cargo.toml +++ b/rust-bins/duniter-dbex/Cargo.toml @@ -22,7 +22,7 @@ anyhow = "1.0.33" arrayvec = "0.5.1" comfy-table = "1.0.0" dirs = "3.0.1" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-dbs = { path = "../../rust-libs/duniter-dbs", default-features = false, features = ["explorer", "leveldb_backend", "sled_backend"] } duniter-dbs-write-ops = { path = "../../rust-libs/duniter-dbs-write-ops", default-features = false, features = ["explorer", "leveldb_backend", "sled_backend"] } duniter-gva = { path = "../../rust-libs/modules/gva" } diff --git a/rust-libs/duniter-conf/Cargo.toml b/rust-libs/duniter-conf/Cargo.toml index 350c3b2df..86b76c3a5 100644 --- a/rust-libs/duniter-conf/Cargo.toml +++ b/rust-libs/duniter-conf/Cargo.toml @@ -6,5 +6,5 @@ license = "AGPL-3.0" edition = "2018" [dependencies] -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } serde = { version = "1.0.105", features = ["derive"] } diff --git a/rust-libs/duniter-dbs-read-ops/Cargo.toml b/rust-libs/duniter-dbs-read-ops/Cargo.toml index 68ce948f3..908c5339c 100644 --- a/rust-libs/duniter-dbs-read-ops/Cargo.toml +++ b/rust-libs/duniter-dbs-read-ops/Cargo.toml @@ -14,7 +14,7 @@ path = "src/lib.rs" [dependencies] anyhow = "1.0.34" duniter-dbs = { path = "../duniter-dbs" } -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } resiter = "0.4.0" [dev-dependencies] diff --git a/rust-libs/duniter-dbs-write-ops/Cargo.toml b/rust-libs/duniter-dbs-write-ops/Cargo.toml index 6d448f290..387bc8c97 100644 --- a/rust-libs/duniter-dbs-write-ops/Cargo.toml +++ b/rust-libs/duniter-dbs-write-ops/Cargo.toml @@ -13,7 +13,7 @@ path = "src/lib.rs" [dependencies] chrono = "0.4.19" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-dbs = { path = "../duniter-dbs" } fast-threadpool = "0.2.2" log = "0.4.11" diff --git a/rust-libs/duniter-dbs/Cargo.toml b/rust-libs/duniter-dbs/Cargo.toml index eaefccf0f..813fd38fd 100644 --- a/rust-libs/duniter-dbs/Cargo.toml +++ b/rust-libs/duniter-dbs/Cargo.toml @@ -16,7 +16,7 @@ arrayvec = "0.5.1" bincode = "1.2.1" byteorder = "1.3.4" chrono = { version = "0.4.15", optional = true } -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } kv_typed = { path = "../tools/kv_typed", default-features = false } log = "0.4.8" mockall = { version = "0.8.0", optional = true } diff --git a/rust-libs/duniter-mempools/Cargo.toml b/rust-libs/duniter-mempools/Cargo.toml index 9f1d70838..c5bacfe95 100644 --- a/rust-libs/duniter-mempools/Cargo.toml +++ b/rust-libs/duniter-mempools/Cargo.toml @@ -12,7 +12,7 @@ edition = "2018" path = "src/lib.rs" [dependencies] -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-dbs = { path = "../duniter-dbs" } duniter-dbs-read-ops = { path = "../duniter-dbs-read-ops" } duniter-dbs-write-ops = { path = "../duniter-dbs-write-ops" } diff --git a/rust-libs/duniter-module/Cargo.toml b/rust-libs/duniter-module/Cargo.toml index bfb85b0a4..a664eada8 100644 --- a/rust-libs/duniter-module/Cargo.toml +++ b/rust-libs/duniter-module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" [dependencies] anyhow = "1.0.34" async-trait = "0.1.41" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-conf = { path = "../duniter-conf" } duniter-dbs = { path = "../duniter-dbs" } duniter-mempools = { path = "../duniter-mempools" } diff --git a/rust-libs/duniter-server/Cargo.toml b/rust-libs/duniter-server/Cargo.toml index 6a608039f..408ceeb1a 100644 --- a/rust-libs/duniter-server/Cargo.toml +++ b/rust-libs/duniter-server/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" [dependencies] anyhow = "1.0.34" cfg-if = "1.0.0" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-conf = { path = "../duniter-conf" } duniter-dbs = { path = "../duniter-dbs" } duniter-dbs-read-ops = { path = "../duniter-dbs-read-ops" } diff --git a/rust-libs/modules/gva/Cargo.toml b/rust-libs/modules/gva/Cargo.toml index 27bcee0d8..965bf4c17 100644 --- a/rust-libs/modules/gva/Cargo.toml +++ b/rust-libs/modules/gva/Cargo.toml @@ -11,7 +11,7 @@ arrayvec = "0.5.1" async-graphql = "2.0.0" async-mutex = "1.4.0" async-trait = "0.1.41" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-conf = { path = "../../duniter-conf" } duniter-dbs = { path = "../../duniter-dbs" } duniter-dbs-read-ops = { path = "../../duniter-dbs-read-ops" } diff --git a/rust-libs/modules/gva/db-writer/Cargo.toml b/rust-libs/modules/gva/db-writer/Cargo.toml index ed15d1068..424ae6146 100644 --- a/rust-libs/modules/gva/db-writer/Cargo.toml +++ b/rust-libs/modules/gva/db-writer/Cargo.toml @@ -14,7 +14,7 @@ path = "src/lib.rs" [dependencies] anyhow = "1.0.34" duniter-dbs = { path = "../../../duniter-dbs" } -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } resiter = "0.4.0" [dev-dependencies] diff --git a/rust-libs/modules/gva/dbs-reader/Cargo.toml b/rust-libs/modules/gva/dbs-reader/Cargo.toml index 50594d857..78d4956b2 100644 --- a/rust-libs/modules/gva/dbs-reader/Cargo.toml +++ b/rust-libs/modules/gva/dbs-reader/Cargo.toml @@ -14,7 +14,7 @@ path = "src/lib.rs" [dependencies] anyhow = "1.0.34" duniter-dbs = { path = "../../../duniter-dbs" } -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } resiter = "0.4.0" [dev-dependencies] diff --git a/rust-libs/modules/gva/src/mutations.rs b/rust-libs/modules/gva/src/mutations.rs index e98e3133d..ce2f1e1c9 100644 --- a/rust-libs/modules/gva/src/mutations.rs +++ b/rust-libs/modules/gva/src/mutations.rs @@ -32,7 +32,7 @@ impl MutationRoot { let data = ctx.data::<SchemaData>()?; let expected_currency = data.server_meta_data.currency.clone(); - tx.verify(Some(expected_currency))?; + tx.verify(Some(&expected_currency))?; let server_pubkey = data.server_meta_data.self_pubkey; let txs_mempool = data.txs_mempool; @@ -69,7 +69,7 @@ impl MutationRoot { let mut processed_txs = Vec::with_capacity(txs.len()); for tx in txs { - tx.verify(Some(expected_currency.clone()))?; + tx.verify(Some(&expected_currency))?; let tx = data .dbs_pool .execute(move |dbs| { diff --git a/rust-libs/tests/duniter-integration-tests/Cargo.toml b/rust-libs/tests/duniter-integration-tests/Cargo.toml index cf913bcb6..355a6a7aa 100644 --- a/rust-libs/tests/duniter-integration-tests/Cargo.toml +++ b/rust-libs/tests/duniter-integration-tests/Cargo.toml @@ -7,7 +7,7 @@ edition = "2018" [dependencies] anyhow = "1.0.34" -dubp = { version = "0.32.3" } +dubp = { version = "0.33.0" } duniter-conf = { path = "../../duniter-conf" } duniter-dbs = { path = "../../duniter-dbs" } duniter-dbs-read-ops = { path = "../../duniter-dbs-read-ops" } -- GitLab