diff --git a/Cargo.lock b/Cargo.lock index 46531927..b6e361a6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -148,9 +148,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.15" +version = "0.6.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" +checksum = "23a1e53f0f5d86382dafe1cf314783b2044280f406e7e1506368220ad11b1338" dependencies = [ "anstyle", "anstyle-parse", @@ -163,43 +163,43 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.8" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" +checksum = "8365de52b16c035ff4fcafe0092ba9390540e3e352870ac09933bebcaa2c8c56" [[package]] name = "anstyle-parse" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" +checksum = "3b2d16507662817a6a20a9ea92df6652ee4f94f914589377d69f3b21bc5798a9" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.1.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" +checksum = "79947af37f4177cfead1110013d678905c37501914fba0efea834c3fe9a8d60c" dependencies = [ - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.4" +version = "3.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" +checksum = "2109dbce0e72be3ec00bed26e6a7479ca384ad226efdd66db8fa2e3a38c83125" dependencies = [ "anstyle", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] name = "anyhow" -version = "1.0.89" +version = "1.0.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86fdf8605db99b54d3cd748a44c6d04df638eb5dafb219b135d0149bd0db01f6" +checksum = "c042108f3ed77fd83760a5fd79b53be043192bb3b9dba91d8c574c0ada7850c8" [[package]] name = "approx" @@ -221,7 +221,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -438,7 +438,7 @@ checksum = "965c2d33e53cb6b267e148a4cb0760bc01f4904c1cd4bb4002a085bb016d1490" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", "synstructure 0.13.1", ] @@ -461,7 +461,7 @@ checksum = "7b18050c2cd6fe86c3a76584ef5e0baf286d038cda203eb6223df2cc413565f7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -502,7 +502,7 @@ dependencies = [ "async-task", "concurrent-queue", "fastrand 2.1.1", - "futures-lite 2.3.0", + "futures-lite 2.4.0", "slab", ] @@ -526,7 +526,7 @@ checksum = "ebcd09b382f40fcd159c2d695175b2ae620ffa5f3bd6f664131efff4e8b9e04a" dependencies = [ "async-lock 3.4.0", "blocking", - "futures-lite 2.3.0", + "futures-lite 2.4.0", ] [[package]] @@ -559,10 +559,10 @@ dependencies = [ "cfg-if", "concurrent-queue", "futures-io", - "futures-lite 2.3.0", + "futures-lite 2.4.0", "parking", "polling 3.7.3", - "rustix 0.38.37", + "rustix 0.38.38", "slab", "tracing", "windows-sys 0.59.0", @@ -607,7 +607,7 @@ checksum = "b948000fad4873c1c9339d60f2623323a0cfd3816e5181033c6a5cb68b2accf7" dependencies = [ "async-io 2.3.4", "blocking", - "futures-lite 2.3.0", + "futures-lite 2.4.0", ] [[package]] @@ -623,7 +623,7 @@ dependencies = [ "cfg-if", "event-listener 3.1.0", "futures-lite 1.13.0", - "rustix 0.38.37", + "rustix 0.38.38", "windows-sys 0.48.0", ] @@ -641,8 +641,8 @@ dependencies = [ "blocking", "cfg-if", "event-listener 5.3.1", - "futures-lite 2.3.0", - "rustix 0.38.37", + "futures-lite 2.4.0", + "rustix 0.38.38", "tracing", ] @@ -658,7 +658,7 @@ dependencies = [ "cfg-if", "futures-core", "futures-io", - "rustix 0.38.37", + "rustix 0.38.38", "signal-hook-registry", "slab", "windows-sys 0.59.0", @@ -683,7 +683,7 @@ checksum = "c7c24de15d275a1ecfd47a380fb4d5ec9bfe0933f309ed5e705b775596a3574d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -700,7 +700,7 @@ checksum = "721cae7de5c34fbb2acd27e21e6d2cf7b886dce0c27388d46c4e6c47ea4318dd" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -759,7 +759,7 @@ dependencies = [ "http 1.1.0", "http-body 1.0.1", "http-body-util", - "hyper 1.4.1", + "hyper 1.5.0", "hyper-util", "itoa", "matchit", @@ -810,7 +810,7 @@ checksum = "57d123550fa8d071b7255cb0cc04dc302baa6c8c4a79f55701552684d8399bce" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -974,13 +974,13 @@ dependencies = [ "lazy_static", "lazycell", "peeking_take_while", - "prettyplease 0.2.22", + "prettyplease 0.2.25", "proc-macro2", "quote", "regex", "rustc-hash", "shlex", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -1154,7 +1154,7 @@ dependencies = [ "async-channel 2.3.1", "async-task", "futures-io", - "futures-lite 2.3.0", + "futures-lite 2.4.0", "piper", ] @@ -1276,9 +1276,9 @@ checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" [[package]] name = "bytemuck" -version = "1.18.0" +version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94bbb0ad554ad961ddc5da507a12a29b14e4ae5bda06b19f575a3e6079d2e2ae" +checksum = "8334215b81e418a0a7bdb8ef0849474f40bb10c8b71f1c4ed315cff49f32494d" [[package]] name = "byteorder" @@ -1288,9 +1288,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.7.2" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "428d9aa8fbc0670b7b8d6030a7fadd0f86151cae55e4dbbece15f3780a3dfaf3" +checksum = "9ac0150caa2ae65ca5bd83f25c7de183dea78d4d366469f148435e2acfbad0da" [[package]] name = "bzip2-sys" @@ -1371,9 +1371,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.1.28" +version = "1.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e80e3b6a3ab07840e1cae9b0666a63970dc28e8ed5ffbcdacbfc760c281bfc1" +checksum = "c2e7962b54006dcfcc61cb72735f4d89bb97061dd6a7ed882ec6b8ee53714c6f" dependencies = [ "jobserver", "libc", @@ -1532,7 +1532,7 @@ checksum = "3147d8272e8fa0ccd29ce51194dd98f79ddfb8191ba9e3409884e751798acf3a" dependencies = [ "core2", "multibase", - "multihash 0.19.1", + "multihash 0.19.2", "parity-scale-codec", "serde", "serde_bytes", @@ -1613,7 +1613,7 @@ dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -1661,14 +1661,14 @@ dependencies = [ "nom", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "colorchoice" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" +checksum = "5b63caa9aa9397e2d9480a9b13673856c78d8ac123288526c37d7839f2a86990" [[package]] name = "combine" @@ -2412,7 +2412,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2725,7 +2725,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2743,9 +2743,9 @@ dependencies = [ [[package]] name = "cxx" -version = "1.0.128" +version = "1.0.129" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54ccead7d199d584d139148b04b4a368d1ec7556a1d9ea2548febb1b9d49f9a4" +checksum = "cbdc8cca144dce1c4981b5c9ab748761619979e515c3d53b5df385c677d1d007" dependencies = [ "cc", "cxxbridge-flags", @@ -2755,9 +2755,9 @@ dependencies = [ [[package]] name = "cxx-build" -version = "1.0.128" +version = "1.0.129" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c77953e99f01508f89f55c494bfa867171ef3a6c8cea03d26975368f2121a5c1" +checksum = "c5764c3142ab44fcf857101d12c0ddf09c34499900557c764f5ad0597159d1fc" dependencies = [ "cc", "codespan-reporting", @@ -2765,24 +2765,24 @@ dependencies = [ "proc-macro2", "quote", "scratch", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "cxxbridge-flags" -version = "1.0.128" +version = "1.0.129" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65777e06cc48f0cb0152024c77d6cf9e4bdb4408e7b48bea993d42fa0f5b02b6" +checksum = "d422aff542b4fa28c2ce8e5cc202d42dbf24702345c1fba3087b2d3f8a1b90ff" [[package]] name = "cxxbridge-macro" -version = "1.0.128" +version = "1.0.129" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98532a60dedaebc4848cb2cba5023337cc9ea3af16a5b062633fabfd9f18fb60" +checksum = "a1719100f31492cd6adeeab9a0f46cdbc846e615fdb66d7b398aa46ec7fdd06f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2830,7 +2830,7 @@ dependencies = [ "proc-macro2", "quote", "strsim 0.11.1", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2852,7 +2852,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ "darling_core 0.20.10", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2960,7 +2960,7 @@ checksum = "d65d7ce8132b7c0e54497a4d9a55a1c2a0912a0d786cf894472ba818fba45762" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2971,7 +2971,7 @@ checksum = "62d671cc41a825ebabc75757b62d3d168c577f9149b2d49ece1dad1f72119d25" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -2984,7 +2984,27 @@ dependencies = [ "proc-macro2", "quote", "rustc_version 0.4.1", - "syn 2.0.79", + "syn 2.0.85", +] + +[[package]] +name = "derive_more" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a9b99b9cbbe49445b21764dc0625032a89b145a2642e67603e1c936f5458d05" +dependencies = [ + "derive_more-impl", +] + +[[package]] +name = "derive_more-impl" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb7330aeadfbe296029522e6c40f315320aba36fc43a5b3632f3795348f3bd22" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.85", ] [[package]] @@ -3079,7 +3099,7 @@ checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3103,7 +3123,7 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.79", + "syn 2.0.85", "termcolor", "toml 0.8.19", "walkdir", @@ -3309,9 +3329,9 @@ checksum = "a357d28ed41a50f9c765dbfe56cbc04a64e53e5fc58ba79fbc34c10ef3df831f" [[package]] name = "encoding_rs" -version = "0.8.34" +version = "0.8.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3" dependencies = [ "cfg-if", ] @@ -3337,7 +3357,7 @@ dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3357,7 +3377,7 @@ checksum = "de0d48a183585823424a4ce1aa132d174a6a81bd540895822eb4c8373a8e49e8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3368,7 +3388,7 @@ checksum = "2f9ed6b3789237c8a0c1c505af1c7eb2c560df6186f01b098c3a1064ea532f38" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3526,7 +3546,7 @@ checksum = "ce8cd46a041ad005ab9c71263f9a0ff5b529eac0fe4cc9b4a20f4f0765d8cf4b" dependencies = [ "execute-command-tokens", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3553,10 +3573,10 @@ dependencies = [ "blake2 0.10.6", "file-guard", "fs-err", - "prettyplease 0.2.22", + "prettyplease 0.2.25", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3613,7 +3633,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -3967,7 +3987,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -4099,7 +4119,7 @@ dependencies = [ "proc-macro2", "quote", "sp-crypto-hashing 0.1.0 (git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1)", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -4111,7 +4131,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -4121,7 +4141,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407 dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -4204,7 +4224,7 @@ version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "29f9df8a11882c4e3335eb2d18a0137c505d9ca927470b0cac9c6f0ae07d28f7" dependencies = [ - "rustix 0.38.37", + "rustix 0.38.38", "windows-sys 0.48.0", ] @@ -4290,9 +4310,9 @@ dependencies = [ [[package]] name = "futures-lite" -version = "2.3.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52527eb5074e35e9339c6b4e8d12600c7128b68fb25dcb9fa9dec18f7c25f3a5" +checksum = "3f1fa2f9765705486b33fd2acf1577f8ec449c2ba1f318ae5447697b7c08d210" dependencies = [ "fastrand 2.1.1", "futures-core", @@ -4309,7 +4329,7 @@ checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -4836,9 +4856,9 @@ dependencies = [ [[package]] name = "hyper" -version = "0.14.30" +version = "0.14.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a152ddd61dfaec7273fe8419ab357f33aee0d914c5f4efbf0d96fa749eea5ec9" +checksum = "8c08302e8fa335b151b788c775ff56e7a03ae64ff85c548ee820fecb70356e85" dependencies = [ "bytes", "futures-channel", @@ -4860,9 +4880,9 @@ dependencies = [ [[package]] name = "hyper" -version = "1.4.1" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50dfd22e0e76d0f662d429a5f80fcaf3855009297eab6a0a9f8543834744ba05" +checksum = "bbbff0a806a4728c99295b254c8838933b5b082d75e3cb70c8dab21fdfbcfa9a" dependencies = [ "bytes", "futures-channel", @@ -4887,7 +4907,7 @@ checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590" dependencies = [ "futures-util", "http 0.2.12", - "hyper 0.14.30", + "hyper 0.14.31", "log", "rustls 0.21.12", "rustls-native-certs 0.6.3", @@ -4903,10 +4923,10 @@ checksum = "08afdbb5c31130e3034af566421053ab03787c640246a446327f550d11bcb333" dependencies = [ "futures-util", "http 1.1.0", - "hyper 1.4.1", + "hyper 1.5.0", "hyper-util", "log", - "rustls 0.23.14", + "rustls 0.23.16", "rustls-pki-types", "tokio", "tokio-rustls 0.26.0", @@ -4919,7 +4939,7 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bbb958482e8c7be4bc3cf272a766a2b0bf1a6755e7a6ae777f017a31d11b13b1" dependencies = [ - "hyper 0.14.30", + "hyper 0.14.31", "pin-project-lite", "tokio", "tokio-io-timeout", @@ -4932,7 +4952,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" dependencies = [ "bytes", - "hyper 0.14.30", + "hyper 0.14.31", "native-tls", "tokio", "tokio-native-tls", @@ -4940,16 +4960,16 @@ dependencies = [ [[package]] name = "hyper-util" -version = "0.1.9" +version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41296eb09f183ac68eec06e03cdbea2e759633d4067b2f6552fc2e009bcad08b" +checksum = "df2dcfbe0677734ab2f3ffa7fa7bfd4706bfdc1ef393f2ee30184aed67e631b4" dependencies = [ "bytes", "futures-channel", "futures-util", "http 1.1.0", "http-body 1.0.1", - "hyper 1.4.1", + "hyper 1.5.0", "pin-project-lite", "socket2 0.5.7", "tokio", @@ -5057,7 +5077,7 @@ dependencies = [ "bytes", "futures", "http 0.2.12", - "hyper 0.14.30", + "hyper 0.14.31", "log", "rand", "tokio", @@ -5359,9 +5379,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.71" +version = "0.3.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0cb94a0ffd3f3ee755c20f7d8752f45cac88605a4dcf808abcff72873296ec7b" +checksum = "6a88f1bda2bd75b0452a14784937d796722fdebfe50df998aeb3f0b7603019a9" dependencies = [ "wasm-bindgen", ] @@ -5450,7 +5470,7 @@ dependencies = [ "http 1.1.0", "jsonrpsee-core 0.23.2", "pin-project", - "rustls 0.23.14", + "rustls 0.23.16", "rustls-pki-types", "rustls-platform-verifier", "soketto 0.8.0", @@ -5473,7 +5493,7 @@ dependencies = [ "beef", "futures-timer", "futures-util", - "hyper 0.14.30", + "hyper 0.14.31", "jsonrpsee-types 0.22.5", "pin-project", "rustc-hash", @@ -5520,7 +5540,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1ccf93fc4a0bfe05d851d37d7c32b7f370fe94336b52a2f0efc5f1981895c2e5" dependencies = [ "async-trait", - "hyper 0.14.30", + "hyper 0.14.31", "hyper-rustls 0.24.2", "jsonrpsee-core 0.22.5", "jsonrpsee-types 0.22.5", @@ -5542,12 +5562,12 @@ dependencies = [ "async-trait", "base64 0.22.1", "http-body 1.0.1", - "hyper 1.4.1", + "hyper 1.5.0", "hyper-rustls 0.27.3", "hyper-util", "jsonrpsee-core 0.23.2", "jsonrpsee-types 0.23.2", - "rustls 0.23.14", + "rustls 0.23.16", "rustls-platform-verifier", "serde", "serde_json", @@ -5568,7 +5588,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -5582,7 +5602,7 @@ dependencies = [ "http 1.1.0", "http-body 1.0.1", "http-body-util", - "hyper 1.4.1", + "hyper 1.5.0", "hyper-util", "jsonrpsee-core 0.23.2", "jsonrpsee-types 0.23.2", @@ -5717,7 +5737,7 @@ dependencies = [ "home", "http 0.2.12", "http-body 0.4.6", - "hyper 0.14.30", + "hyper 0.14.31", "hyper-rustls 0.24.2", "hyper-timeout", "jsonpath-rust", @@ -5845,9 +5865,9 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.159" +version = "0.2.161" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "561d97a539a36e26a9a5fad1ea11a3039a67714694aaa379433e580854bc3dc5" +checksum = "8e9489c2807c139ffd9c1794f4af0ebe86a828db53ecdc7fea2111d0fed085d1" [[package]] name = "libloading" @@ -5861,9 +5881,9 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.8" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" +checksum = "8355be11b20d696c8f18f6cc018c4e372165b1fa8126cef092399c9951984ffa" [[package]] name = "libp2p" @@ -5940,7 +5960,7 @@ dependencies = [ "libp2p-identity", "log", "multiaddr 0.18.2", - "multihash 0.19.1", + "multihash 0.19.2", "multistream-select", "once_cell", "parking_lot 0.12.3", @@ -6002,7 +6022,7 @@ dependencies = [ "bs58 0.5.1", "ed25519-dalek", "hkdf", - "multihash 0.19.1", + "multihash 0.19.2", "quick-protobuf", "rand", "sha2 0.10.8", @@ -6091,7 +6111,7 @@ dependencies = [ "libp2p-identity", "log", "multiaddr 0.18.2", - "multihash 0.19.1", + "multihash 0.19.2", "once_cell", "quick-protobuf", "rand", @@ -6196,7 +6216,7 @@ dependencies = [ "proc-macro-warning 0.4.2", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -6412,9 +6432,9 @@ dependencies = [ [[package]] name = "linregress" -version = "0.5.3" +version = "0.5.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4de04dcecc58d366391f9920245b85ffa684558a5ef6e7736e754347c3aea9c2" +checksum = "a9eda9dcf4f2a99787827661f312ac3219292549c2ee992bf9a6248ffb066bf7" dependencies = [ "nalgebra", ] @@ -6602,7 +6622,7 @@ dependencies = [ "macro_magic_core", "macro_magic_macros", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -6616,7 +6636,7 @@ dependencies = [ "macro_magic_core_macros", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -6627,7 +6647,7 @@ checksum = "b02abfe41815b5bd98dbd4260173db2c116dda171dc0fe7838cb206333b83308" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -6638,7 +6658,7 @@ checksum = "73ea28ee64b88876bf45277ed9a5817c1817df061a74f2b988971a12570e5869" dependencies = [ "macro_magic_core", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -6738,7 +6758,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2cffa4ad52c6f791f4f8b15f0c05f9824b2ced1160e88cc393d64fff9a8ac64" dependencies = [ - "rustix 0.38.37", + "rustix 0.38.38", ] [[package]] @@ -6960,7 +6980,7 @@ dependencies = [ "cfg-if", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -7010,7 +7030,7 @@ dependencies = [ "data-encoding", "libp2p-identity", "multibase", - "multihash 0.19.1", + "multihash 0.19.2", "percent-encoding", "serde", "static_assertions", @@ -7065,25 +7085,25 @@ dependencies = [ [[package]] name = "multihash" -version = "0.19.1" +version = "0.19.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "076d548d76a0e2a0d4ab471d0b1c36c577786dfc4471242035d97a12a735c492" +checksum = "cc41f430805af9d1cf4adae4ed2149c759b877b01d909a1f40256188d09345d2" dependencies = [ "core2", "parity-scale-codec", "serde", - "unsigned-varint 0.7.2", + "unsigned-varint 0.8.0", ] [[package]] name = "multihash-codetable" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c35f0fb09f635b18e95053fc2a9a4843272d3acf898792a14471dcf6f83df0cc" +checksum = "67996849749d25f1da9f238e8ace2ece8f9d6bdf3f9750aaf2ae7de3a5cad8ea" dependencies = [ "blake2b_simd", "core2", - "multihash-derive 0.9.0", + "multihash-derive 0.9.1", ] [[package]] @@ -7102,26 +7122,25 @@ dependencies = [ [[package]] name = "multihash-derive" -version = "0.9.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "890e72cb7396cb99ed98c1246a97b243cc16394470d94e0bc8b0c2c11d84290e" +checksum = "1f1b7edab35d920890b88643a765fc9bd295cf0201f4154dda231bef9b8404eb" dependencies = [ "core2", - "multihash 0.19.1", + "multihash 0.19.2", "multihash-derive-impl", ] [[package]] name = "multihash-derive-impl" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3958713ce794e12f7c6326fac9aa274c68d74c4881dd37b3e2662b8a2046bb19" +checksum = "e3dc7141bd06405929948754f0628d247f5ca1865be745099205e5086da957cb" dependencies = [ - "proc-macro-crate 2.0.0", - "proc-macro-error", + "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", "synstructure 0.13.1", ] @@ -7153,13 +7172,12 @@ dependencies = [ [[package]] name = "nalgebra" -version = "0.32.6" +version = "0.33.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b5c17de023a86f59ed79891b2e5d5a94c705dbe904a5b5c9c952ea6221b03e4" +checksum = "26aecdf64b707efd1310e3544d709c5c0ac61c13756046aaaba41be5c4f66a3b" dependencies = [ "approx", "matrixmultiply", - "nalgebra-macros", "num-complex", "num-rational", "num-traits", @@ -7167,17 +7185,6 @@ dependencies = [ "typenum", ] -[[package]] -name = "nalgebra-macros" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "254a5372af8fc138e36684761d3c0cdb758a4410e938babcff1c860ce14ddbfc" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.79", -] - [[package]] name = "names" version = "0.14.0" @@ -7596,9 +7603,9 @@ dependencies = [ [[package]] name = "openssl" -version = "0.10.66" +version = "0.10.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9529f4786b70a3e8c61e11179af17ab6188ad8d0ded78c5529441ed39d4bd9c1" +checksum = "6174bc48f102d208783c2c84bf931bb75927a617866870de8a4ea85597f871f5" dependencies = [ "bitflags 2.6.0", "cfg-if", @@ -7617,7 +7624,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -7628,18 +7635,18 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-src" -version = "300.3.2+3.3.2" +version = "300.4.0+3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a211a18d945ef7e648cc6e0058f4c548ee46aab922ea203e0d30e966ea23647b" +checksum = "a709e02f2b4aca747929cca5ed248880847c650233cf8b8cdc48f40aaf4898a6" dependencies = [ "cc", ] [[package]] name = "openssl-sys" -version = "0.9.103" +version = "0.9.104" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f9e8deee91df40a943c71b917e5874b951d32a802526c85721ce3b776c929d6" +checksum = "45abf306cbf99debc8195b66b7346498d7b10c210de50418b5ccd7ceba08c741" dependencies = [ "cc", "libc", @@ -8683,7 +8690,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -8983,7 +8990,7 @@ checksum = "4e69bf016dc406eff7d53a7d3f7cf1c2e72c82b9088aac1118591e36dd2cd3e9" dependencies = [ "bitcoin_hashes", "rand", - "rand_core 0.5.1", + "rand_core 0.6.4", "serde", "unicode-normalization", ] @@ -9139,9 +9146,9 @@ checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "pathdiff" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" +checksum = "d61c5ce1153ab5b689d0c074c4e7fc613e942dfb7dd9eea5ab202d2ad91fe361" [[package]] name = "pbkdf2" @@ -9186,9 +9193,9 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pest" -version = "2.7.13" +version = "2.7.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdbef9d1d47087a895abd220ed25eb4ad973a5e26f6a4367b038c25e28dfc2d9" +checksum = "879952a81a83930934cbf1786752d6dedc3b1f29e8f8fb2ad1d0a36f377cf442" dependencies = [ "memchr", "thiserror", @@ -9197,9 +9204,9 @@ dependencies = [ [[package]] name = "pest_derive" -version = "2.7.13" +version = "2.7.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d3a6e3394ec80feb3b6393c725571754c6188490265c61aaf260810d6b95aa0" +checksum = "d214365f632b123a47fd913301e14c946c61d1c183ee245fa76eb752e59a02dd" dependencies = [ "pest", "pest_generator", @@ -9207,22 +9214,22 @@ dependencies = [ [[package]] name = "pest_generator" -version = "2.7.13" +version = "2.7.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94429506bde1ca69d1b5601962c73f4172ab4726571a59ea95931218cb0e930e" +checksum = "eb55586734301717aea2ac313f50b2eb8f60d2fc3dc01d190eefa2e625f60c4e" dependencies = [ "pest", "pest_meta", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "pest_meta" -version = "2.7.13" +version = "2.7.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac8a071862e93690b6e34e9a5fb8e33ff3734473ac0245b27232222c4906a33f" +checksum = "b75da2a70cf4d9cb76833c990ac9cd3923c9a8905a8929789ce347c84564d03d" dependencies = [ "once_cell", "pest", @@ -9241,29 +9248,29 @@ dependencies = [ [[package]] name = "pin-project" -version = "1.1.6" +version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf123a161dde1e524adf36f90bc5d8d3462824a9c43553ad07a8183161189ec" +checksum = "be57f64e946e500c8ee36ef6331845d40a93055567ec57e8fae13efd33759b95" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.6" +version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4502d8515ca9f32f1fb543d987f63d95a14934883db45bdb48060b6b69257f8" +checksum = "3c0f5fad0874fc7abcd4d750e76917eaebbecaa2c20bde22e1dbeeba8beb758c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "pin-project-lite" -version = "0.2.14" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" +checksum = "915a1e146535de9163f3987b8944ed8cf49a18bb0056bcebcdcece385cece4ff" [[package]] name = "pin-utils" @@ -9618,7 +9625,7 @@ name = "polkadot-availability-distribution" version = "17.0.1" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ - "derive_more", + "derive_more 0.99.18", "fatality", "futures", "parity-scale-codec", @@ -9736,7 +9743,7 @@ name = "polkadot-dispute-distribution" version = "17.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ - "derive_more", + "derive_more 0.99.18", "fatality", "futures", "futures-timer", @@ -9839,7 +9846,7 @@ version = "17.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ "bitvec", - "derive_more", + "derive_more 0.99.18", "futures", "futures-timer", "itertools 0.11.0", @@ -10177,7 +10184,7 @@ dependencies = [ "async-channel 1.9.0", "async-trait", "bitvec", - "derive_more", + "derive_more 0.99.18", "fatality", "futures", "hex", @@ -10235,7 +10242,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407 dependencies = [ "async-trait", "bitvec", - "derive_more", + "derive_more 0.99.18", "fatality", "futures", "orchestra", @@ -10264,7 +10271,7 @@ version = "17.1.0" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ "async-trait", - "derive_more", + "derive_more 0.99.18", "fatality", "futures", "futures-channel", @@ -10322,7 +10329,7 @@ version = "14.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ "bounded-collections", - "derive_more", + "derive_more 0.99.18", "parity-scale-codec", "polkadot-core-primitives", "scale-info", @@ -10462,7 +10469,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407 dependencies = [ "bitflags 1.3.2", "bitvec", - "derive_more", + "derive_more 0.99.18", "frame-benchmarking", "frame-support", "frame-system", @@ -10721,7 +10728,7 @@ dependencies = [ "polkavm-common 0.8.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -10733,7 +10740,7 @@ dependencies = [ "polkavm-common 0.9.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -10743,7 +10750,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "15e85319a0d5129dc9f021c62607e0804f5fb777a05cdda44d750ac0732def66" dependencies = [ "polkavm-derive-impl 0.8.0", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -10753,7 +10760,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ba81f7b5faac81e528eb6158a6f3c9e0bb1008e0ffa19653bc8dea925ecb429" dependencies = [ "polkavm-derive-impl 0.9.0", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -10803,7 +10810,7 @@ dependencies = [ "concurrent-queue", "hermit-abi 0.4.0", "pin-project-lite", - "rustix 0.38.37", + "rustix 0.38.38", "tracing", "windows-sys 0.59.0", ] @@ -10925,12 +10932,12 @@ dependencies = [ [[package]] name = "prettyplease" -version = "0.2.22" +version = "0.2.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "479cf940fbbb3426c32c5d5176f62ad57549a0bb84773423ba8be9d089f5faba" +checksum = "64d1ec885c64d0457d564db4ec299b2dae3f9c02808b8ad9c3a089c591b18033" dependencies = [ "proc-macro2", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -10982,7 +10989,7 @@ checksum = "a172e6cc603231f2cf004232eabcecccc0da53ba576ab286ef7baa0cfc7927ad" dependencies = [ "coarsetime", "crossbeam-queue", - "derive_more", + "derive_more 0.99.18", "futures", "futures-timer", "nanorand", @@ -11000,15 +11007,6 @@ dependencies = [ "toml 0.5.11", ] -[[package]] -name = "proc-macro-crate" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e8366a6159044a37876a2b9817124296703c586a5c92e2c53751fa06d8d43e8" -dependencies = [ - "toml_edit 0.20.7", -] - [[package]] name = "proc-macro-crate" version = "3.2.0" @@ -11050,7 +11048,7 @@ checksum = "3d1eaa7fa0aa1929ffdf7eeb6eac234dde6268914a14ad44d23521ab6a9b258e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -11061,14 +11059,14 @@ checksum = "834da187cfe638ae8abb0203f0b33e5ccdb02a28e7199f2f47b3e2754f50edca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "proc-macro2" -version = "1.0.87" +version = "1.0.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3e4daa0dcf6feba26f985457cdf104d4b4256fc5a09547140f3631bb076b19a" +checksum = "f139b0662de085916d1fb67d2b4169d1addddda1919e696f3252b740b629986e" dependencies = [ "unicode-ident", ] @@ -11107,7 +11105,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -11165,11 +11163,11 @@ dependencies = [ "multimap 0.10.0", "once_cell", "petgraph", - "prettyplease 0.2.22", + "prettyplease 0.2.25", "prost 0.12.6", "prost-types 0.12.6", "regex", - "syn 2.0.79", + "syn 2.0.85", "tempfile", ] @@ -11196,7 +11194,7 @@ dependencies = [ "itertools 0.12.1", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -11543,7 +11541,7 @@ version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "87413ebb313323d431e85d0afc5a68222aaed972843537cbfe5f061cf1b4bcab" dependencies = [ - "derive_more", + "derive_more 0.99.18", "fs-err", "static_init", "thiserror", @@ -11566,7 +11564,7 @@ checksum = "bcc303e793d3734489387d205e9b186fac9c6cfacedd98cbb2e8a5943595f3e6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -11596,9 +11594,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.11.0" +version = "1.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38200e5ee88914975b69f657f0801b6f6dccafd44fd9326302a4aaeecfacb1d8" +checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191" dependencies = [ "aho-corasick", "memchr", @@ -11658,7 +11656,7 @@ dependencies = [ "h2 0.3.26", "http 0.2.12", "http-body 0.4.6", - "hyper 0.14.30", + "hyper 0.14.31", "hyper-tls", "ipnet", "js-sys", @@ -11903,7 +11901,7 @@ dependencies = [ "regex", "relative-path", "rustc_version 0.4.1", - "syn 2.0.79", + "syn 2.0.85", "unicode-ident", ] @@ -12023,9 +12021,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.37" +version = "0.38.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8acb788b847c24f28525660c4d7758620a7210875711f79e7f663cc152726811" +checksum = "aa260229e6538e52293eeb577aabd09945a09d6d9cc0fc550ed7529056c2e32a" dependencies = [ "bitflags 2.6.0", "errno 0.3.9", @@ -12073,9 +12071,9 @@ dependencies = [ [[package]] name = "rustls" -version = "0.23.14" +version = "0.23.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "415d9944693cb90382053259f89fbb077ea730ad7273047ec63b19bc9b160ba8" +checksum = "eee87ff5d9b36712a58574e12e9f0ea80f915a5b0ac518d322b24a465617925e" dependencies = [ "log", "once_cell", @@ -12131,9 +12129,9 @@ dependencies = [ [[package]] name = "rustls-pki-types" -version = "1.9.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e696e35370c65c9c541198af4543ccd580cf17fc25d8e05c5a242b202488c55" +checksum = "16f1201b3c9a7ee8039bcadc17b7e605e2945b27eee7631788c1bd2b0643674b" [[package]] name = "rustls-platform-verifier" @@ -12146,7 +12144,7 @@ dependencies = [ "jni", "log", "once_cell", - "rustls 0.23.14", + "rustls 0.23.16", "rustls-native-certs 0.7.3", "rustls-platform-verifier-android", "rustls-webpki 0.102.8", @@ -12185,9 +12183,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955d28af4278de8121b7ebeb796b6a45735dc01436d898801014aced2773a3d6" +checksum = "0e819f2bc632f285be6d7cd36e25940d45b2391dd6d9b939e79de557f7014248" [[package]] name = "ruzstd" @@ -12207,7 +12205,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "58c4eb8a81997cf040a091d1f7e1938aeab6749d3a0dfa73af43cdc32393483d" dependencies = [ "byteorder", - "derive_more", + "derive_more 0.99.18", "twox-hash", ] @@ -12278,7 +12276,7 @@ dependencies = [ "libp2p", "linked_hash_set", "log", - "multihash 0.19.1", + "multihash 0.19.2", "parity-scale-codec", "prost 0.12.6", "prost-build 0.12.6", @@ -12368,7 +12366,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -13033,7 +13031,7 @@ dependencies = [ "litep2p", "log", "multiaddr 0.18.2", - "multihash 0.19.1", + "multihash 0.19.2", "rand", "thiserror", "zeroize", @@ -13049,7 +13047,7 @@ dependencies = [ "fnv", "futures", "futures-timer", - "hyper 0.14.30", + "hyper 0.14.31", "hyper-rustls 0.24.2", "log", "num_cpus", @@ -13144,7 +13142,7 @@ dependencies = [ "governor", "http 1.1.0", "http-body-util", - "hyper 1.4.1", + "hyper 1.5.0", "ip_network", "jsonrpsee 0.23.2", "log", @@ -13300,7 +13298,7 @@ name = "sc-sysinfo" version = "37.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ - "derive_more", + "derive_more 0.99.18", "futures", "libc", "log", @@ -13374,7 +13372,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -13453,7 +13451,7 @@ version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e98f3262c250d90e700bb802eb704e1f841e03331c2eb815e46516c4edbf5b27" dependencies = [ - "derive_more", + "derive_more 0.99.18", "parity-scale-codec", "primitive-types", "scale-bits", @@ -13476,11 +13474,11 @@ dependencies = [ [[package]] name = "scale-encode" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ba0b9c48dc0eb20c60b083c29447c0c4617cb7c4a4c9fef72aa5c5bc539e15e" +checksum = "528464e6ae6c8f98e2b79633bf79ef939552e795e316579dab09c61670d56602" dependencies = [ - "derive_more", + "derive_more 0.99.18", "parity-scale-codec", "primitive-types", "scale-bits", @@ -13491,26 +13489,26 @@ dependencies = [ [[package]] name = "scale-encode-derive" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82ab7e60e2d9c8d47105f44527b26f04418e5e624ffc034f6b4a86c0ba19c5bf" +checksum = "bef2618f123c88da9cd8853b69d766068f1eddc7692146d7dfe9b89e25ce2efd" dependencies = [ - "darling 0.14.4", - "proc-macro-crate 1.1.3", + "darling 0.20.10", + "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] name = "scale-info" -version = "2.11.3" +version = "2.11.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eca070c12893629e2cc820a9761bedf6ce1dcddc9852984d1dc734b8bd9bd024" +checksum = "1aa7ffc1c0ef49b0452c6e2986abf2b07743320641ffd5fc63d552458e3b779b" dependencies = [ "bitvec", "cfg-if", - "derive_more", + "derive_more 1.0.0", "parity-scale-codec", "scale-info-derive", "serde", @@ -13518,14 +13516,14 @@ dependencies = [ [[package]] name = "scale-info-derive" -version = "2.11.3" +version = "2.11.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d35494501194174bda522a32605929eefc9ecf7e0a326c26db1fdd85881eb62" +checksum = "46385cc24172cf615450267463f937c10072516359b3ff1cb24228a4a08bf951" dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] @@ -13547,7 +13545,7 @@ dependencies = [ "proc-macro2", "quote", "scale-info", - "syn 2.0.79", + "syn 2.0.85", "thiserror", ] @@ -13559,7 +13557,7 @@ checksum = "8cd6ab090d823e75cfdb258aad5fe92e13f2af7d04b43a55d607d25fcc38c811" dependencies = [ "base58", "blake2 0.10.6", - "derive_more", + "derive_more 0.99.18", "either", "frame-metadata 15.1.0", "parity-scale-codec", @@ -13781,9 +13779,9 @@ checksum = "cd0b0ec5f1c1ca621c432a25813d8d60c88abe6d3e08a3eb9cf37d97a0fe3d73" [[package]] name = "serde" -version = "1.0.210" +version = "1.0.214" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8e3592472072e6e22e0a54d5904d9febf8508f65fb8552499a1abc7d1078c3a" +checksum = "f55c3193aca71c12ad7890f1785d2b73e1b9f63a0bbc353c08ef26fe03fc56b5" dependencies = [ "serde_derive", ] @@ -13809,13 +13807,13 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.210" +version = "1.0.214" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "243902eda00fad750862fc144cea25caca5e20d615af0a81bee94ca738f1df1f" +checksum = "de523f781f095e28fa605cdce0f8307e451cc0fd14e2eb4cd2e98a355b147766" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -13832,9 +13830,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.128" +version = "1.0.132" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ff5456707a1de34e7e37f2a6fd3d3f808c318259cbd01ab6377795054b483d8" +checksum = "d726bfaff4b320266d395898905d0eba0345aae23b54aee3a737e260fd46db03" dependencies = [ "itoa", "memchr", @@ -14036,9 +14034,9 @@ dependencies = [ [[package]] name = "simba" -version = "0.8.1" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "061507c94fc6ab4ba1c9a0305018408e312e17c041eb63bef8aa726fa33aceae" +checksum = "b3a386a501cd104797982c15ae17aafe8b9261315b5d07e3ec803f2ea26be0fa" dependencies = [ "approx", "num-complex", @@ -14146,7 +14144,7 @@ dependencies = [ "async-net 2.0.0", "async-process 2.3.0", "blocking", - "futures-lite 2.3.0", + "futures-lite 2.4.0", ] [[package]] @@ -14164,7 +14162,7 @@ dependencies = [ "bs58 0.5.1", "chacha20", "crossbeam-queue", - "derive_more", + "derive_more 0.99.18", "ed25519-zebra 4.0.3", "either", "event-listener 2.5.3", @@ -14218,12 +14216,12 @@ dependencies = [ "bs58 0.5.1", "chacha20", "crossbeam-queue", - "derive_more", + "derive_more 0.99.18", "ed25519-zebra 4.0.3", "either", "event-listener 4.0.3", "fnv", - "futures-lite 2.3.0", + "futures-lite 2.4.0", "futures-util", "hashbrown 0.14.5", "hex", @@ -14268,7 +14266,7 @@ dependencies = [ "async-lock 2.8.0", "base64 0.21.7", "blake2-rfc", - "derive_more", + "derive_more 0.99.18", "either", "event-listener 2.5.3", "fnv", @@ -14304,12 +14302,12 @@ dependencies = [ "async-lock 3.4.0", "base64 0.21.7", "blake2-rfc", - "derive_more", + "derive_more 0.99.18", "either", "event-listener 4.0.3", "fnv", "futures-channel", - "futures-lite 2.3.0", + "futures-lite 2.4.0", "futures-util", "hashbrown 0.14.5", "hex", @@ -14437,7 +14435,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -14760,7 +14758,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407 dependencies = [ "quote", "sp-crypto-hashing 0.1.0 (git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1)", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -14780,7 +14778,7 @@ checksum = "48d09fa0a5f7299fb81ee25ae3853d26200f7a348148aed6de76be905c007dbe" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -14790,7 +14788,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407 dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -15128,7 +15126,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -15141,7 +15139,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -15406,7 +15404,7 @@ dependencies = [ "parity-scale-codec", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -15769,6 +15767,7 @@ dependencies = [ "subxt-signer", "thiserror", "tokio", + "tokio-util", "tracing", "tracing-subscriber 0.3.18", "url", @@ -15867,7 +15866,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -15926,7 +15925,7 @@ version = "0.17.0" source = "git+https://github.com/paritytech/polkadot-sdk?tag=polkadot-stable2407-1#16b0fd09d9e9281c20ee0c1d8b87d011e3e3454e" dependencies = [ "http-body-util", - "hyper 1.4.1", + "hyper 1.5.0", "hyper-util", "log", "prometheus", @@ -16040,16 +16039,16 @@ dependencies = [ "scale-info", "scale-typegen", "subxt-metadata", - "syn 2.0.79", + "syn 2.0.85", "thiserror", "tokio", ] [[package]] name = "subxt-core" -version = "0.37.0" +version = "0.37.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59f41eb2e2eea6ed45649508cc735f92c27f1fcfb15229e75f8270ea73177345" +checksum = "3af3b36405538a36b424d229dc908d1396ceb0994c90825ce928709eac1a159a" dependencies = [ "base58", "blake2 0.10.6", @@ -16103,7 +16102,7 @@ dependencies = [ "quote", "scale-typegen", "subxt-codegen", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -16154,9 +16153,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.79" +version = "2.0.85" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89132cd0bf050864e1d38dc3bbc07a0eb8e7530af26344d3d2bbbef83499f590" +checksum = "5023162dfcd14ef8f32034d8bcd4cc5ddc61ef7a247c024a33e24e1f24d21b56" dependencies = [ "proc-macro2", "quote", @@ -16195,7 +16194,7 @@ checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -16260,7 +16259,7 @@ dependencies = [ "cfg-if", "fastrand 2.1.1", "once_cell", - "rustix 0.38.37", + "rustix 0.38.38", "windows-sys 0.59.0", ] @@ -16279,7 +16278,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4f599bd7ca042cfdf8f4512b277c02ba102247820f9d9d4a9f521f496751a6ef" dependencies = [ - "rustix 0.38.37", + "rustix 0.38.38", "windows-sys 0.59.0", ] @@ -16291,9 +16290,9 @@ checksum = "3369f5ac52d5eb6ab48c6b4ffdc8efbcad6b89c765749064ba298f2c68a16a76" [[package]] name = "thiserror" -version = "1.0.64" +version = "1.0.65" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d50af8abc119fb8bb6dbabcfa89656f46f84aa0ac7688088608076ad2b459a84" +checksum = "5d11abd9594d9b38965ef50805c5e469ca9cc6f197f883f717e0269a3057b3d5" dependencies = [ "thiserror-impl", ] @@ -16315,18 +16314,18 @@ checksum = "e4c60d69f36615a077cc7663b9cb8e42275722d23e58a7fa3d2c7f2915d09d04" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "thiserror-impl" -version = "1.0.64" +version = "1.0.65" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08904e7672f5eb876eaaf87e0ce17857500934f4981c4a0ab2b4aa98baac7fc3" +checksum = "ae71770322cbd277e69d762a16c444af02aa0575ac0d174f0b9562d3b37f8602" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -16455,9 +16454,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.40.0" +version = "1.41.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2b070231665d27ad9ec9b8df639893f46727666c6767db40317fbe920a5d998" +checksum = "145f3413504347a2be84393cc8a7d2fb4d863b375909ea59f2158261aa258bbb" dependencies = [ "backtrace", "bytes", @@ -16489,7 +16488,7 @@ checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -16529,7 +16528,7 @@ version = "0.26.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" dependencies = [ - "rustls 0.23.14", + "rustls 0.23.16", "rustls-pki-types", "tokio", ] @@ -16631,17 +16630,6 @@ dependencies = [ "winnow 0.5.40", ] -[[package]] -name = "toml_edit" -version = "0.20.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70f427fce4d84c72b5b732388bf4a9f4531b53f74e2887e3ecb2481f68f66d81" -dependencies = [ - "indexmap 2.6.0", - "toml_datetime", - "winnow 0.5.40", -] - [[package]] name = "toml_edit" version = "0.22.22" @@ -16758,7 +16746,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -16801,7 +16789,7 @@ dependencies = [ "proc-macro-crate 3.2.0", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -17171,9 +17159,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.10.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81dfa00651efa65069b0b6b651f4aaa31ba9e3c3ce0137aaad053604ee7e0314" +checksum = "f8c5f0a0af699448548ad1a2fbf920fb4bee257eae39953ba95cb84891a0446a" dependencies = [ "getrandom", "serde", @@ -17205,9 +17193,9 @@ checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" [[package]] name = "w3f-bls" -version = "0.1.4" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c5da5fa2c6afa2c9158eaa7cd9aee249765eb32b5fb0c63ad8b9e79336a47ec" +checksum = "b2a73d66caed54f10eefbfdaee07baa2ce398a1252ad06cc4fdf99668e36fccf" dependencies = [ "ark-bls12-377", "ark-bls12-381", @@ -17269,9 +17257,9 @@ dependencies = [ [[package]] name = "wasm-bindgen" -version = "0.2.94" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef073ced962d62984fb38a36e5fdc1a2b23c9e0e1fa0689bb97afa4202ef6887" +checksum = "128d1e363af62632b8eb57219c8fd7877144af57558fb2ef0368d0087bddeb2e" dependencies = [ "cfg-if", "once_cell", @@ -17280,24 +17268,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.94" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4bfab14ef75323f4eb75fa52ee0a3fb59611977fd3240da19b2cf36ff85030e" +checksum = "cb6dd4d3ca0ddffd1dd1c9c04f94b868c37ff5fac97c30b97cff2d74fce3a358" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.44" +version = "0.4.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65471f79c1022ffa5291d33520cbbb53b7687b01c2f8e83b57d102eed7ed479d" +checksum = "cc7ec4f8827a71586374db3e87abdb5a2bb3a15afed140221307c3ec06b1f63b" dependencies = [ "cfg-if", "js-sys", @@ -17307,9 +17295,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.94" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7bec9830f60924d9ceb3ef99d55c155be8afa76954edffbb5936ff4509474e7" +checksum = "e79384be7f8f5a9dd5d7167216f022090cf1f9ec128e6e6a482a2cb5c5422c56" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -17317,22 +17305,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.94" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c74f6e152a76a2ad448e223b0fc0b6b5747649c3d769cc6bf45737bf97d0ed6" +checksum = "26c6ab57572f7a24a4985830b120de1594465e5d500f24afe89e16b4e833ef68" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.94" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a42f6c679374623f295a8623adfe63d9284091245c3504bde47c17a3ce2777d9" +checksum = "65fc09f10666a9f147042251e0dda9c18f166ff7de300607007e96bdebc1068d" [[package]] name = "wasm-instrument" @@ -17645,9 +17633,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.71" +version = "0.3.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44188d185b5bdcae1052d08bcbcf9091a5524038d4572cc4f4f2bb9d5554ddd9" +checksum = "f6488b90108c040df0fe62fa815cbdee25124641df01814dd7282749234c6112" dependencies = [ "js-sys", "wasm-bindgen", @@ -17809,7 +17797,7 @@ dependencies = [ "either", "home", "once_cell", - "rustix 0.38.37", + "rustix 0.38.38", ] [[package]] @@ -18219,7 +18207,7 @@ checksum = "8da84f1a25939b27f6820d92aed108f83ff920fdf11a7b19366c27c4cda81d4f" dependencies = [ "libc", "linux-raw-sys 0.4.14", - "rustix 0.38.37", + "rustix 0.38.38", ] [[package]] @@ -18230,7 +18218,7 @@ dependencies = [ "Inflector", "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -18326,7 +18314,7 @@ checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] @@ -18346,14 +18334,14 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.79", + "syn 2.0.85", ] [[package]] name = "zombienet-configuration" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebbfc98adb25076777967f7aad078e74029e129b102eb0812c425432f8c2be7b" +checksum = "c8ab4af5d47f03cb8ae0fa96ffbf3881ca050c51e62367685ebdd3e8ae52b220" dependencies = [ "anyhow", "lazy_static", @@ -18371,9 +18359,9 @@ dependencies = [ [[package]] name = "zombienet-orchestrator" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b17f4d1d05b3aedf02818eb0f4d5a76664da0e07bb2f7e7d02613e0ef0f316a" +checksum = "580e01019655a2bd296e42f48876c2e78c94a989147376e025c0e64daf717cf7" dependencies = [ "anyhow", "async-trait", @@ -18404,9 +18392,9 @@ dependencies = [ [[package]] name = "zombienet-prom-metrics-parser" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7203390ab88919240da3a3eb06b625b6e300e94f98e04ba5141e9138dc663b7d" +checksum = "4d026607c1a6e198b653c5979fb07078740861978ddecfd5460f2c32cdc182b1" dependencies = [ "pest", "pest_derive", @@ -18415,9 +18403,9 @@ dependencies = [ [[package]] name = "zombienet-provider" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee02ee957ec39b698798fa6dc2a0d5ba4524198471c37d57755e9685b67fb50c" +checksum = "55583d8be6b2ca2e679d85ee2e17eb0802fbf8d2ee05c1b326fff81fd6b3b5c3" dependencies = [ "anyhow", "async-trait", @@ -18446,9 +18434,9 @@ dependencies = [ [[package]] name = "zombienet-sdk" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f594e67922182277a3da0926f21b693eb5a0c38b32ca7fd6ef16167809fe5064" +checksum = "300f3f07aa72df21a52611a0df1033325a454252e36d964c4308b0a8b7356f77" dependencies = [ "async-trait", "futures", @@ -18463,9 +18451,9 @@ dependencies = [ [[package]] name = "zombienet-support" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93d3144537df7c8939bbb355cc5245a6dc0078446a6cdaf9272268bd1043c788" +checksum = "e566ea145dab27c6fbb24b13d4c789efa7e675e1fdaf6d007dfe1154d59317c6" dependencies = [ "anyhow", "async-trait", diff --git a/Cargo.toml b/Cargo.toml index f99d46bc..b73e97fc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -88,6 +88,8 @@ rand = { version = "0.8.5", default-features = false } rand_chacha = { version = "0.3.1", default-features = false } rand_xorshift = "0.3" rocksdb = { version = "0.21" } +scale-decode = { version = "0.13.1", default-features = false } +scale-encode = { version = "0.7.1", default-features = false } scale-info = { version = "2.11.1", default-features = false } serde = { version = "1.0.197", default-features = false } serde-big-array = { version = "0.3.2" } @@ -111,9 +113,6 @@ tracing-subscriber = "0.3.18" url = "2.5.0" uuid = "1.8.0" -scale-decode = { version = "0.13.1", default-features = false } -scale-encode = { version = "0.7.1", default-features = false } - # Testing rstest = { version = "0.22.0" } diff --git a/cli/artifacts/metadata.scale b/cli/artifacts/metadata.scale index dbce6c54..c70945c1 100644 Binary files a/cli/artifacts/metadata.scale and b/cli/artifacts/metadata.scale differ diff --git a/cli/polka-storage-provider/server/src/rpc.rs b/cli/polka-storage-provider/server/src/rpc.rs index 24f2b912..f729a0bb 100644 --- a/cli/polka-storage-provider/server/src/rpc.rs +++ b/cli/polka-storage-provider/server/src/rpc.rs @@ -108,26 +108,20 @@ impl StorageProviderRpcServer for RpcServerState { )); } - // TODO(@jmg-duarte,#428,04/10/2024): - // There's a small bug here, currently, xt_client waits for a "full extrisic submission" - // meaning that it will wait until the block where it is included in is finalized - // however, due to https://github.com/paritytech/subxt/issues/1668 it may wrongly fail. - // Fixing this requires the xt_client not wait for the finalization, it's not hard to do - // it just requires some API design - let result = self + let submission_result = self .xt_client - .publish_signed_storage_deals(&self.xt_keypair, vec![deal]) - .await?; - - let published_deals = result - .events - .find::() - .collect::, _>>() - .map_err(|err| RpcError::internal_error(err, None))?; + .publish_signed_storage_deals(&self.xt_keypair, vec![deal], true) + .await? + .expect("requested to return submission-result"); + let events = if let Ok(events) = submission_result { + events + } else { + return Err(RpcError::internal_error("pallet returned an error", None)); + }; // We currently just support a single deal and if there's no published deals, // an error MUST've happened - debug_assert_eq!(published_deals.len(), 1); + debug_assert_eq!(events.len(), 1); let unsealed_dir = self.unsealed_piece_storage_dir.clone(); let sealed_dir = self.sealed_piece_storage_dir.clone(); @@ -173,7 +167,7 @@ impl StorageProviderRpcServer for RpcServerState { tracing::info!("{:?}", precommit_result); }); - Ok(published_deals[0].deal_id) + Ok(events[0].variant.deal_id) } } diff --git a/cli/polka-storage/storagext-cli/src/cmd/market.rs b/cli/polka-storage/storagext-cli/src/cmd/market.rs index d5e74ede..56b86659 100644 --- a/cli/polka-storage/storagext-cli/src/cmd/market.rs +++ b/cli/polka-storage/storagext-cli/src/cmd/market.rs @@ -6,7 +6,7 @@ use primitives_proofs::DealId; use storagext::{ deser::DeserializablePath, multipair::{DebugPair, MultiPairSigner}, - runtime::SubmissionResult, + runtime::{market::events as MktEvents, HashOfPsc, SubmissionResult}, types::market::DealProposal as SxtDealProposal, MarketClientExt, PolkaStorageConfig, }; @@ -15,6 +15,7 @@ use subxt::ext::sp_core::{ }; use url::Url; +use super::display_submission_result; use crate::{missing_keypair_error, operation_takes_a_while, OutputFormat}; #[derive(Debug, Subcommand)] @@ -81,6 +82,7 @@ impl MarketCommand { account_keypair: Option, n_retries: u32, retry_interval: Duration, + wait_for_finalization: bool, output_format: OutputFormat, ) -> Result<(), anyhow::Error> { let client = storagext::Client::new(node_rpc, n_retries, retry_interval).await?; @@ -110,7 +112,12 @@ impl MarketCommand { return Err(missing_keypair_error::().into()); }; else_ - .with_keypair(client, account_keypair, output_format) + .with_keypair( + client, + account_keypair, + wait_for_finalization, + output_format, + ) .await?; } }; @@ -122,26 +129,42 @@ impl MarketCommand { self, client: Client, account_keypair: MultiPairSigner, + wait_for_finalization: bool, output_format: OutputFormat, ) -> Result<(), anyhow::Error> where Client: MarketClientExt, { - operation_takes_a_while(); + if wait_for_finalization { + operation_takes_a_while(); + } - let submission_result = match self { + match self { MarketCommand::AddBalance { amount } => { - Self::add_balance(client, account_keypair, amount).await? + let opt_result = + Self::add_balance(client, account_keypair, amount, wait_for_finalization) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } MarketCommand::SettleDealPayments { deal_ids } => { if deal_ids.is_empty() { bail!("No deals provided to settle"); } - Self::settle_deal_payments(client, account_keypair, deal_ids).await? + let opt_result = Self::settle_deal_payments( + client, + account_keypair, + deal_ids, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } MarketCommand::WithdrawBalance { amount } => { - Self::withdraw_balance(client, account_keypair, amount).await? + let opt_result = + Self::withdraw_balance(client, account_keypair, amount, wait_for_finalization) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } MarketCommand::PublishStorageDeals { deals, @@ -156,34 +179,19 @@ impl MarketCommand { client_ed25519_key.map(DebugPair::into_inner) ) .expect("client is required to submit at least one key, this should've been handled by clap's ArgGroup"); - Self::publish_storage_deals(client, account_keypair, client_keypair, deals).await? + let opt_result = Self::publish_storage_deals( + client, + account_keypair, + client_keypair, + deals, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } _unsigned => unreachable!("unsigned commands should have been previously handled"), }; - let hash = submission_result.hash; - // This monstrosity first converts incoming events into a "generic" (subxt generated) event, - // and then we extract only the Market events. We could probably extract this into a proper - // iterator but the effort to improvement ratio seems low (for 2 pallets at least). - let submission_results = submission_result - .events - .iter() - .flat_map(|event| { - event.map(|details| details.as_root_event::()) - }) - .filter_map(|event| match event { - Ok(storagext::runtime::Event::Market(e)) => Some(Ok(e)), - Err(err) => Some(Err(err)), - _ => None, - }); - for event in submission_results { - let event = event?; - let output = output_format.format(&event)?; - match output_format { - OutputFormat::Plain => println!("[{}] {}", hash, output), - OutputFormat::Json => println!("{}", output), - } - } Ok(()) } @@ -191,18 +199,23 @@ impl MarketCommand { client: Client, account_keypair: MultiPairSigner, amount: u128, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: MarketClientExt, { - let submission_result = client.add_balance(&account_keypair, amount).await?; - tracing::debug!( - "[{}] Successfully added {} to Market Balance", - submission_result.hash, - amount - ); - - Ok(submission_result) + let submission_result = client + .add_balance(&account_keypair, amount, wait_for_finalization) + .await?; + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully added {} to Market Balance", + events[0].hash, + amount + ) + }); + })) } async fn publish_storage_deals( @@ -210,59 +223,75 @@ impl MarketCommand { account_keypair: MultiPairSigner, client_keypair: MultiPairSigner, deals: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: MarketClientExt, { + let n_deals = deals.len(); let submission_result = client .publish_storage_deals( &account_keypair, &client_keypair, deals.into_iter().map(Into::into).collect(), + wait_for_finalization, ) .await?; - tracing::debug!( - "[{}] Successfully published storage deals", - submission_result.hash - ); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully published {} storage deals", + events[0].hash, + n_deals + ) + }); + })) } async fn settle_deal_payments( client: Client, account_keypair: MultiPairSigner, deal_ids: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: MarketClientExt, { + let n_deal_ids = deal_ids.len(); let submission_result = client - .settle_deal_payments(&account_keypair, deal_ids) + .settle_deal_payments(&account_keypair, deal_ids, wait_for_finalization) .await?; - tracing::debug!( - "[{}] Successfully settled deal payments", - submission_result.hash - ); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully settled {} deal payments", + events[0].hash, + n_deal_ids + ) + }); + })) } async fn withdraw_balance( client: Client, account_keypair: MultiPairSigner, amount: u128, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: MarketClientExt, { - let submission_result = client.withdraw_balance(&account_keypair, amount).await?; - tracing::debug!( - "[{}] Successfully withdrew {} from Market Balance", - submission_result.hash, - amount - ); - - Ok(submission_result) + let submission_result = client + .withdraw_balance(&account_keypair, amount, wait_for_finalization) + .await?; + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully withdrew {} from Market Balance", + events[0].hash, + amount + ) + }); + })) } } diff --git a/cli/polka-storage/storagext-cli/src/cmd/mod.rs b/cli/polka-storage/storagext-cli/src/cmd/mod.rs index c0c627bf..e736a24d 100644 --- a/cli/polka-storage/storagext-cli/src/cmd/mod.rs +++ b/cli/polka-storage/storagext-cli/src/cmd/mod.rs @@ -1,3 +1,51 @@ pub mod market; pub mod storage_provider; pub mod system; + +use storagext::runtime::{HashOfPsc, SubmissionResult}; + +use crate::OutputFormat; + +pub(crate) fn display_submission_result( + opt_result: Option>, + output_format: OutputFormat, +) -> Result<(), anyhow::Error> { + if opt_result.is_none() { + return Ok(()); + } + let result = opt_result.expect("expect some, checked before"); + + match result { + Ok(events) => { + events + .iter() + .for_each(|e| println!("[{}] {:?}", e.hash, e.variant)); + match &events[0].event { + storagext::runtime::Event::Market(e) => { + display::<_>(events[0].hash, e, output_format)? + } + storagext::runtime::Event::StorageProvider(e) => { + display::<_>(events[0].hash, e, output_format)? + } + _ => return Ok(()), + } + } + Err(_) => { + println!("Extrinsic failed: {}!", std::any::type_name::()); + } + } + + Ok(()) +} + +fn display(hash: HashOfPsc, event: E, output_format: OutputFormat) -> Result<(), anyhow::Error> +where + E: std::fmt::Display + serde::Serialize, +{ + let output = output_format.format(&event)?; + match output_format { + OutputFormat::Plain => println!("[{}] {}", hash, output), + OutputFormat::Json => println!("{}", output), + } + Ok(()) +} diff --git a/cli/polka-storage/storagext-cli/src/cmd/storage_provider.rs b/cli/polka-storage/storagext-cli/src/cmd/storage_provider.rs index 2d2bfbe8..196ea569 100644 --- a/cli/polka-storage/storagext-cli/src/cmd/storage_provider.rs +++ b/cli/polka-storage/storagext-cli/src/cmd/storage_provider.rs @@ -7,7 +7,7 @@ use storagext::{ multipair::MultiPairSigner, runtime::{ runtime_types::pallet_storage_provider::sector::ProveCommitSector as RuntimeProveCommitSector, - SubmissionResult, + storage_provider::events as SpEvents, HashOfPsc, SubmissionResult, }, types::storage_provider::{ FaultDeclaration as SxtFaultDeclaration, ProveCommitSector as SxtProveCommitSector, @@ -16,10 +16,11 @@ use storagext::{ SubmitWindowedPoStParams as SxtSubmitWindowedPoStParams, TerminationDeclaration as SxtTerminationDeclaration, }, - PolkaStorageConfig, StorageProviderClientExt, + StorageProviderClientExt, }; use url::Url; +use super::display_submission_result; use crate::{missing_keypair_error, operation_takes_a_while, OutputFormat}; fn parse_post_proof(src: &str) -> Result { @@ -102,6 +103,7 @@ impl StorageProviderCommand { account_keypair: Option, n_retries: u32, retry_interval: Duration, + wait_for_finalization: bool, output_format: OutputFormat, ) -> Result<(), anyhow::Error> { let client = storagext::Client::new(node_rpc, n_retries, retry_interval).await?; @@ -130,7 +132,12 @@ impl StorageProviderCommand { return Err(missing_keypair_error::().into()); }; else_ - .with_keypair(client, account_keypair, output_format) + .with_keypair( + client, + account_keypair, + wait_for_finalization, + output_format, + ) .await?; } }; @@ -142,64 +149,92 @@ impl StorageProviderCommand { self, client: Client, account_keypair: MultiPairSigner, + wait_for_finalization: bool, output_format: OutputFormat, ) -> Result<(), anyhow::Error> where Client: StorageProviderClientExt, { - operation_takes_a_while(); + if wait_for_finalization { + operation_takes_a_while(); + } - let submission_result = match self { + match self { StorageProviderCommand::RegisterStorageProvider { peer_id, post_proof, } => { - Self::register_storage_provider(client, account_keypair, peer_id, post_proof) - .await? + let opt_result = Self::register_storage_provider( + client, + account_keypair, + peer_id, + post_proof, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } StorageProviderCommand::PreCommit { pre_commit_sectors } => { - Self::pre_commit(client, account_keypair, pre_commit_sectors).await? + let opt_result = Self::pre_commit( + client, + account_keypair, + pre_commit_sectors, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } StorageProviderCommand::ProveCommit { prove_commit_sectors, - } => Self::prove_commit(client, account_keypair, prove_commit_sectors).await?, + } => { + let opt_result = Self::prove_commit( + client, + account_keypair, + prove_commit_sectors, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; + } StorageProviderCommand::SubmitWindowedProofOfSpaceTime { windowed_post } => { - Self::submit_windowed_post(client, account_keypair, windowed_post).await? + let opt_result = Self::submit_windowed_post( + client, + account_keypair, + windowed_post, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } StorageProviderCommand::DeclareFaults { faults } => { - Self::declare_faults(client, account_keypair, faults).await? + let opt_result = + Self::declare_faults(client, account_keypair, faults, wait_for_finalization) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } StorageProviderCommand::DeclareFaultsRecovered { recoveries } => { - Self::declare_faults_recovered(client, account_keypair, recoveries).await? + let opt_result = Self::declare_faults_recovered( + client, + account_keypair, + recoveries, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } StorageProviderCommand::TerminateSectors { terminations } => { - Self::terminate_sectors(client, account_keypair, terminations).await? + let opt_result = Self::terminate_sectors( + client, + account_keypair, + terminations, + wait_for_finalization, + ) + .await?; + display_submission_result::<_>(opt_result, output_format)?; } _unsigned => unreachable!("unsigned commands should have been previously handled"), - }; - - // This monstrosity first converts incoming events into a "generic" (subxt generated) event, - // and then we extract only the Market events. We could probably extract this into a proper - // iterator but the effort to improvement ratio seems low (for 2 pallets at least). - let submission_results = submission_result - .events - .iter() - .flat_map(|event| { - event.map(|details| details.as_root_event::()) - }) - .filter_map(|event| match event { - Ok(storagext::runtime::Event::StorageProvider(e)) => Some(Ok(e)), - Err(err) => Some(Err(err)), - _ => None, - }); - for event in submission_results { - let event = event?; - let output = output_format.format(&event)?; - match output_format { - OutputFormat::Plain => println!("[{}] {}", submission_result.hash, output), - OutputFormat::Json => println!("{}", output), - } } + Ok(()) } @@ -208,28 +243,40 @@ impl StorageProviderCommand { account_keypair: MultiPairSigner, peer_id: String, post_proof: RegisteredPoStProof, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result< + Option>, + subxt::Error, + > where Client: StorageProviderClientExt, { let submission_result = client - .register_storage_provider(&account_keypair, peer_id.clone(), post_proof) + .register_storage_provider( + &account_keypair, + peer_id.clone(), + post_proof, + wait_for_finalization, + ) .await?; - tracing::debug!( - "[{}] Successfully registered {}, seal: {:?} in Storage Provider Pallet", - submission_result.hash, - peer_id, - post_proof - ); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully registered {}, seal: {:?} in Storage Provider Pallet", + events[0].hash, + peer_id, + post_proof + ) + }); + })) } async fn pre_commit( client: Client, account_keypair: MultiPairSigner, pre_commit_sectors: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: StorageProviderClientExt, { @@ -240,22 +287,25 @@ impl StorageProviderCommand { .unzip(); let submission_result = client - .pre_commit_sectors(&account_keypair, pre_commit_sectors) + .pre_commit_sectors(&account_keypair, pre_commit_sectors, wait_for_finalization) .await?; - tracing::debug!( - "[{}] Successfully pre-commited sectors {:?}.", - submission_result.hash, - sector_numbers - ); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully pre-commited sectors {:?}.", + events[0].hash, + sector_numbers + ) + }); + })) } async fn prove_commit( client: Client, account_keypair: MultiPairSigner, prove_commit_sectors: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: StorageProviderClientExt, { @@ -270,79 +320,115 @@ impl StorageProviderCommand { }) .unzip(); let submission_result = client - .prove_commit_sectors(&account_keypair, prove_commit_sectors) + .prove_commit_sectors( + &account_keypair, + prove_commit_sectors, + wait_for_finalization, + ) .await?; - tracing::debug!( - "[{}] Successfully proven sector {:?}.", - submission_result.hash, - sector_numbers - ); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully proven sector {:?}.", + events[0].hash, + sector_numbers + ) + }); + })) } async fn submit_windowed_post( client: Client, account_keypair: MultiPairSigner, windowed_post: SxtSubmitWindowedPoStParams, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: StorageProviderClientExt, { let submission_result = client - .submit_windowed_post(&account_keypair, windowed_post.into()) + .submit_windowed_post( + &account_keypair, + windowed_post.into(), + wait_for_finalization, + ) .await?; - tracing::debug!("[{}] Successfully submitted proof.", submission_result.hash); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!("[{}] Successfully submitted proof.", events[0].hash) + }); + })) } async fn declare_faults( client: Client, account_keypair: MultiPairSigner, faults: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: StorageProviderClientExt, { - let submission_result = client.declare_faults(&account_keypair, faults).await?; - tracing::debug!("[{}] Successfully declared faults.", submission_result.hash); - - Ok(submission_result) + let n_faults = faults.len(); + let submission_result = client + .declare_faults(&account_keypair, faults, wait_for_finalization) + .await?; + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully declared {} faults.", + events[0].hash, + n_faults + ) + }); + })) } async fn declare_faults_recovered( client: Client, account_keypair: MultiPairSigner, recoveries: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: StorageProviderClientExt, { + let n_recoveries = recoveries.len(); let submission_result = client - .declare_faults_recovered(&account_keypair, recoveries) + .declare_faults_recovered(&account_keypair, recoveries, wait_for_finalization) .await?; - tracing::debug!("[{}] Successfully declared faults.", submission_result.hash); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully declared {} faults.", + events[0].hash, + n_recoveries + ) + }); + })) } async fn terminate_sectors( client: Client, account_keypair: MultiPairSigner, terminations: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Client: StorageProviderClientExt, { + let n_terminations = terminations.len(); let submission_result = client - .terminate_sectors(&account_keypair, terminations) + .terminate_sectors(&account_keypair, terminations, wait_for_finalization) .await?; - tracing::debug!( - "[{}] Successfully terminated sectors.", - submission_result.hash - ); - - Ok(submission_result) + Ok(submission_result.inspect(|sr| { + let _ = sr.as_ref().inspect(|events| { + tracing::trace!( + "[{}] Successfully terminated {} sectors.", + events[0].hash, + n_terminations + ) + }); + })) } } diff --git a/cli/polka-storage/storagext-cli/src/main.rs b/cli/polka-storage/storagext-cli/src/main.rs index b512d357..7c854f28 100644 --- a/cli/polka-storage/storagext-cli/src/main.rs +++ b/cli/polka-storage/storagext-cli/src/main.rs @@ -77,6 +77,10 @@ struct Cli { #[arg(long, env, default_value = DEFAULT_RETRY_INTERVAL_MS, value_parser = parse_ms)] pub retry_interval: Duration, + /// Skip waiting for the extrinsic to be included in a finalized block. + #[arg(long, env)] + pub skip_finalization: bool, + /// Output format. #[arg(long, env, value_parser = OutputFormat::value_parser, default_value_t = OutputFormat::Plain)] pub format: OutputFormat, @@ -101,6 +105,7 @@ impl SubCommand { account_keypair: Option, n_retries: u32, retry_interval: Duration, + wait_for_finalization: bool, output_format: OutputFormat, ) -> Result<(), anyhow::Error> { match self { @@ -110,6 +115,7 @@ impl SubCommand { account_keypair, n_retries, retry_interval, + wait_for_finalization, output_format, ) .await?; @@ -120,6 +126,7 @@ impl SubCommand { account_keypair, n_retries, retry_interval, + wait_for_finalization, output_format, ) .await?; @@ -179,6 +186,7 @@ async fn main() -> Result<(), anyhow::Error> { multi_pair_signer, cli_arguments.n_retries, cli_arguments.retry_interval, + !cli_arguments.skip_finalization, cli_arguments.format, ) .await?; diff --git a/cli/polka-storage/storagext/Cargo.toml b/cli/polka-storage/storagext/Cargo.toml index 8bbb535c..44b21ec6 100644 --- a/cli/polka-storage/storagext/Cargo.toml +++ b/cli/polka-storage/storagext/Cargo.toml @@ -28,7 +28,8 @@ sha2 = { workspace = true } subxt = { workspace = true, features = ["jsonrpsee", "substrate-compat"] } subxt-signer = { workspace = true, features = ["subxt"] } thiserror = { workspace = true } -tokio = { workspace = true, features = ["rt-multi-thread"] } +tokio = { workspace = true, features = ["macros", "rt-multi-thread"] } +tokio-util = { workspace = true } tracing = { workspace = true } tracing-subscriber = { workspace = true, features = ["env-filter"] } url = { workspace = true } diff --git a/cli/polka-storage/storagext/src/clients/market.rs b/cli/polka-storage/storagext/src/clients/market.rs index ee7b9e6e..20ddedf9 100644 --- a/cli/polka-storage/storagext/src/clients/market.rs +++ b/cli/polka-storage/storagext/src/clients/market.rs @@ -6,7 +6,8 @@ use subxt::{ext::sp_core::crypto::Ss58Codec, utils::Static}; use crate::{ runtime::{ self, - client::SubmissionResult, + client::{HashOfPsc, SubmissionResult}, + market::events as MktEvents, runtime_types::pallet_market::pallet::{ BalanceEntry, ClientDealProposal as RuntimeClientDealProposal, }, @@ -34,7 +35,13 @@ pub trait MarketClientExt { &self, account_keypair: &Keypair, amount: Currency, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -43,7 +50,10 @@ pub trait MarketClientExt { &self, account_keypair: &Keypair, amount: Currency, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result>, subxt::Error>, + > where Keypair: subxt::tx::Signer; @@ -54,7 +64,10 @@ pub trait MarketClientExt { &self, account_keypair: &Keypair, deal_ids: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result>, subxt::Error>, + > where Keypair: subxt::tx::Signer; @@ -66,7 +79,13 @@ pub trait MarketClientExt { account_keypair: &Keypair, client_keypair: &ClientKeypair, deals: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer, ClientKeypair: subxt::tx::Signer; @@ -78,7 +97,13 @@ pub trait MarketClientExt { &self, account_keypair: &Keypair, deals: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -102,12 +127,14 @@ impl MarketClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, amount: Currency, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { let payload = runtime::tx().market().withdraw_balance(amount); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, 1) + .await } #[tracing::instrument( @@ -122,12 +149,14 @@ impl MarketClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, amount: Currency, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { let payload = runtime::tx().market().add_balance(amount); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, 1) + .await } #[tracing::instrument( @@ -142,7 +171,8 @@ impl MarketClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, mut deal_ids: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { @@ -160,7 +190,8 @@ impl MarketClientExt for crate::runtime::client::Client { .market() .settle_deal_payments(bounded_unbounded_deal_ids); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, 1) + .await } #[tracing::instrument( @@ -175,11 +206,13 @@ impl MarketClientExt for crate::runtime::client::Client { account_keypair: &Keypair, client_keypair: &ClientKeypair, mut deals: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, ClientKeypair: subxt::tx::Signer, { + let n_deals = deals.len(); if deals.len() > MAX_N_DEALS { tracing::warn!("more than {} deals, truncating", MAX_N_DEALS); deals.truncate(MAX_N_DEALS); @@ -202,7 +235,8 @@ impl MarketClientExt for crate::runtime::client::Client { .market() .publish_storage_deals(bounded_unbounded_deals); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, n_deals) + .await } #[tracing::instrument( @@ -216,7 +250,8 @@ impl MarketClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, mut deals: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { @@ -225,6 +260,7 @@ impl MarketClientExt for crate::runtime::client::Client { deals.truncate(MAX_N_DEALS); } + let n_deals = deals.len(); let deals = deals .into_iter() .map(|deal| SpecializedRuntimeClientDealProposal::from(deal)) @@ -240,7 +276,8 @@ impl MarketClientExt for crate::runtime::client::Client { .market() .publish_storage_deals(bounded_unbounded_deals); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, n_deals) + .await } #[tracing::instrument( diff --git a/cli/polka-storage/storagext/src/clients/storage_provider.rs b/cli/polka-storage/storagext/src/clients/storage_provider.rs index 26ee45c5..a4f64bfe 100644 --- a/cli/polka-storage/storagext/src/clients/storage_provider.rs +++ b/cli/polka-storage/storagext/src/clients/storage_provider.rs @@ -11,25 +11,32 @@ use crate::{ runtime::{ self, bounded_vec::IntoBoundedByteVec, - client::SubmissionResult, + client::{HashOfPsc, SubmissionResult}, runtime_types::pallet_storage_provider::{ proofs::SubmitWindowedPoStParams, sector::ProveCommitSector, storage_provider::StorageProviderState, }, - storage_provider::calls::types::register_storage_provider::PeerId, + storage_provider::{calls::types::register_storage_provider::PeerId, events as SpEvents}, }, types::storage_provider::{ FaultDeclaration, RecoveryDeclaration, SectorPreCommitInfo, TerminationDeclaration, }, BlockNumber, Currency, PolkaStorageConfig, }; + pub trait StorageProviderClientExt { fn register_storage_provider( &self, account_keypair: &Keypair, peer_id: String, post_proof: RegisteredPoStProof, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -37,7 +44,13 @@ pub trait StorageProviderClientExt { &self, account_keypair: &Keypair, sectors: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -45,7 +58,10 @@ pub trait StorageProviderClientExt { &self, account_keypair: &Keypair, sectors: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result>, subxt::Error>, + > where Keypair: subxt::tx::Signer; @@ -53,7 +69,13 @@ pub trait StorageProviderClientExt { &self, account_keypair: &Keypair, windowed_post: SubmitWindowedPoStParams, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -61,7 +83,13 @@ pub trait StorageProviderClientExt { &self, account_keypair: &Keypair, faults: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -69,7 +97,13 @@ pub trait StorageProviderClientExt { &self, account_keypair: &Keypair, recoveries: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -77,7 +111,13 @@ pub trait StorageProviderClientExt { &self, account_keypair: &Keypair, terminations: Vec, - ) -> impl Future, subxt::Error>> + wait_for_finalization: bool, + ) -> impl Future< + Output = Result< + Option>, + subxt::Error, + >, + > where Keypair: subxt::tx::Signer; @@ -106,7 +146,11 @@ impl StorageProviderClientExt for crate::runtime::client::Client { account_keypair: &Keypair, peer_id: String, post_proof: RegisteredPoStProof, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result< + Option>, + subxt::Error, + > where Keypair: subxt::tx::Signer, { @@ -114,7 +158,8 @@ impl StorageProviderClientExt for crate::runtime::client::Client { .storage_provider() .register_storage_provider(peer_id.into_bounded_byte_vec(), post_proof); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, 1) + .await } #[tracing::instrument( @@ -128,14 +173,17 @@ impl StorageProviderClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, sectors: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { + let n_sectors = sectors.len(); let sectors = BoundedVec(sectors.into_iter().map(Into::into).collect()); let payload = runtime::tx().storage_provider().pre_commit_sectors(sectors); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, n_sectors) + .await } #[tracing::instrument( @@ -149,16 +197,19 @@ impl StorageProviderClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, sectors: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { + let n_sectors = sectors.len(); let sectors = BoundedVec(sectors.into_iter().map(Into::into).collect()); let payload = runtime::tx() .storage_provider() .prove_commit_sectors(sectors); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, n_sectors) + .await } #[tracing::instrument( @@ -172,7 +223,8 @@ impl StorageProviderClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, windowed_post: SubmitWindowedPoStParams, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { @@ -180,7 +232,8 @@ impl StorageProviderClientExt for crate::runtime::client::Client { .storage_provider() .submit_windowed_post(windowed_post); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, 1) + .await } #[tracing::instrument( @@ -194,15 +247,18 @@ impl StorageProviderClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, faults: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { + let n_faults = faults.len(); let payload = runtime::tx() .storage_provider() .declare_faults(faults.into()); - self.traced_submission(&payload, account_keypair).await + self.traced_submission(&payload, account_keypair, wait_for_finalization, n_faults) + .await } #[tracing::instrument( @@ -216,15 +272,23 @@ impl StorageProviderClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, recoveries: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { + let n_recoveries = recoveries.len(); let payload = runtime::tx() .storage_provider() .declare_faults_recovered(recoveries.into()); - self.traced_submission(&payload, account_keypair).await + self.traced_submission( + &payload, + account_keypair, + wait_for_finalization, + n_recoveries, + ) + .await } #[tracing::instrument(level = "debug", skip_all)] @@ -232,15 +296,23 @@ impl StorageProviderClientExt for crate::runtime::client::Client { &self, account_keypair: &Keypair, terminations: Vec, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + ) -> Result>, subxt::Error> where Keypair: subxt::tx::Signer, { + let n_terminations = terminations.len(); let payload = runtime::tx() .storage_provider() .terminate_sectors(terminations.into()); - self.traced_submission(&payload, account_keypair).await + self.traced_submission( + &payload, + account_keypair, + wait_for_finalization, + n_terminations, + ) + .await } #[tracing::instrument(level = "debug", skip_all)] diff --git a/cli/polka-storage/storagext/src/lib.rs b/cli/polka-storage/storagext/src/lib.rs index d4da7aed..6db1c592 100644 --- a/cli/polka-storage/storagext/src/lib.rs +++ b/cli/polka-storage/storagext/src/lib.rs @@ -19,7 +19,7 @@ pub type Currency = u128; pub type BlockNumber = u64; /// Parachain configuration for subxt. -#[derive(Debug)] +#[derive(Clone, Debug)] pub enum PolkaStorageConfig {} // Types are fully qualified ON PURPOSE! diff --git a/cli/polka-storage/storagext/src/runtime/client.rs b/cli/polka-storage/storagext/src/runtime/client.rs index 5cf101e7..9f3911e5 100644 --- a/cli/polka-storage/storagext/src/runtime/client.rs +++ b/cli/polka-storage/storagext/src/runtime/client.rs @@ -1,22 +1,40 @@ -use std::time::Duration; +use std::{sync::Arc, time::Duration, vec::Vec}; use hex::ToHex; -use subxt::{blocks::ExtrinsicEvents, OnlineClient}; +use subxt::{blocks::ExtrinsicEvents, error::BlockError, OnlineClient}; +use tokio::sync::RwLock; +use tokio_util::sync::CancellationToken; use crate::PolkaStorageConfig; -/// Helper type for [`Client::traced_submission`] successful results. -pub struct SubmissionResult -where - Config: subxt::Config, -{ - /// Submission block hash. - pub hash: Config::Hash, +/// Helper type to access the hash type of a given subxt configuration. +type HashOf = ::Hash; +/// Hash type of our default used subxt configuration. +pub type HashOfPsc = HashOf; - /// Resulting extrinsic's events. - pub events: ExtrinsicEvents, +/// Helper definition to define a stack for storing collected events with block hash. +type ParaEvents = Arc, ExtrinsicEvents)>>>; + +/// This definition defines one single, successful event of an extrinsic execution. For example, +/// one published deal, or one settled deal. +#[derive(Debug)] +pub struct ExtrinsicEvent { + /// Submission block hash, final enum variant. + pub hash: Hash, + /// Resulting extrinsic's event. + /// This additional more complex type is needed by the formatter `OutputFormat`. + pub event: crate::runtime::Event, + /// Resulting extrinsic's event-variant. + pub variant: Variant, } +/// Helper type for [`Client::traced_submission`] successful results. +/// +/// Currently, our pallet's extrinsic calls do emit either a single event or multiple events. For +/// that reason we need here `Vec>`. If we would harmonize that that way +/// extrinsics are emitting pnly one event per extrinsic call, we could remove the `Vec`. +pub type SubmissionResult = Result>, ()>; + /// Client to interact with a pallet extrinsics. /// You can call any extrinsic via [`Client::traced_submission`]. pub struct Client { @@ -66,40 +84,61 @@ impl Client { /// /// Equivalent to performing [`OnlineClient::sign_and_submit_then_watch_default`], /// followed by [`TxInBlock::wait_for_finalized`] and [`TxInBlock::wait_for_success`]. - pub(crate) async fn traced_submission( + pub(crate) async fn traced_submission( &self, call: &Call, account_keypair: &Keypair, - ) -> Result, subxt::Error> + wait_for_finalization: bool, + expected_events: usize, + ) -> Result>, subxt::Error> where - Call: subxt::tx::Payload, + Call: subxt::tx::Payload + std::fmt::Debug, Keypair: subxt::tx::Signer, + Variant: subxt::events::StaticEvent + std::fmt::Debug, { - tracing::trace!("submitting extrinsic"); - let submission_progress = self - .client - .tx() - .sign_and_submit_then_watch_default(call, account_keypair) + if wait_for_finalization { + let para_events: ParaEvents = Arc::new(RwLock::new(Vec::new())); + let cancel_token = CancellationToken::new(); + + let p_api = self.client.clone(); + let p_events = para_events.clone(); + let p_cancel = cancel_token.clone(); + + let pw_handle = + tokio::spawn(async move { para_watcher(p_api, p_cancel, p_events).await }); + + tracing::trace!("submitting extrinsic"); + let submission_progress = self + .client + .tx() + .sign_and_submit_then_watch_default(call, account_keypair) + .await?; + + let extrinsic_hash = submission_progress.extrinsic_hash(); + tracing::trace!( + "waiting for finalization {}", + extrinsic_hash.encode_hex::(), + ); + + let submission_result = wait_for_para_event::( + para_events.clone(), + extrinsic_hash, + expected_events, + ) .await?; + cancel_token.cancel(); + pw_handle + .await + .map_err(|e| subxt::Error::Other(format!("JoinHandle: {e:?}")))??; - tracing::trace!( - extrinsic_hash = submission_progress.extrinsic_hash().encode_hex::(), - "waiting for finalization" - ); - let finalized_xt = submission_progress.wait_for_finalized().await?; - let block_hash = finalized_xt.block_hash(); - tracing::trace!( - block_hash = block_hash.encode_hex::(), - "successfully submitted extrinsic" - ); - - // finalized != successful - let xt_events = finalized_xt.wait_for_success().await?; - - Ok(SubmissionResult { - hash: block_hash, - events: xt_events, - }) + Ok(Some(submission_result)) + } else { + self.client + .tx() + .sign_and_submit_then_watch_default(call, account_keypair) + .await?; + Ok(None) + } } } @@ -108,3 +147,116 @@ impl From> for Client { Self { client } } } + +/// Methods iterates through the given stack of collected events from the listener and compares for +/// a given expected event type, for example `pallet_market::Event::BalanceAdded`. If the event has +/// been found it will be returned. +async fn wait_for_para_event( + event_stack: ParaEvents, + extrinsic_hash: HashOf, + expected_events: usize, +) -> Result, V>, subxt::Error> +where + C: subxt::Config + Clone + std::fmt::Debug, + V: subxt::events::StaticEvent + std::fmt::Debug, +{ + let mut catched_events = Vec::, V>>::new(); + + loop { + // Check for new events from a finalised block. + let mut events_lock = event_stack.write().await; + while let Some((hash, ex_events)) = events_lock.pop() { + if ex_events.extrinsic_hash() == extrinsic_hash { + for entry in ex_events.iter() { + let entry = entry?; + let event_name = format!("{}::{}", entry.pallet_name(), entry.variant_name()); + + if entry.pallet_name() == V::PALLET && entry.variant_name() == V::EVENT { + let event = + entry + .as_root_event::() + .map_err(|e| { + subxt::Error::Other(format!( + "{event_name}.as_root_event(): {e:?}" + )) + })?; + let variant = entry + .as_event::() + .map_err(|e| { + subxt::Error::Other(format!("{event_name}.as_event() {e:?}")) + })? + .ok_or(subxt::Error::Other(format!( + "{event_name}: inner option error" + )))?; + tracing::trace!( + "Found related event {event_name} to extrinsic with hash {:?}", + extrinsic_hash + ); + catched_events.push(ExtrinsicEvent::, V> { + hash, + event, + variant, + }); + } else if entry.pallet_name() == "System" + && entry.variant_name() == "ExtrinsicFailed" + { + return Ok(Err(())); + } + + if catched_events.len() == expected_events { + return Ok(Ok(catched_events)); + } + } + } + } + drop(events_lock); + + // Blocks are generated only every couple of seconds, so don't waste CPU time. + tokio::time::sleep(std::time::Duration::from_secs(1)).await; + } +} + +/// Method listens to finalised blocks, collects all events and pushes them to a given stack. +async fn para_watcher( + api: OnlineClient, + token: CancellationToken, + events: ParaEvents, +) -> Result<(), subxt::Error> +where + ::Number: std::fmt::Display, +{ + tracing::trace!("start listening to events on finalised blocks"); + let mut blocks_sub = api.blocks().subscribe_finalized().await?; + + loop { + let block = tokio::select! { + _ = token.cancelled() => { + break + } + block = blocks_sub.next() => { + if let Some(block) = block { + block? + } else { + return Err(subxt::Error::Block(BlockError::NotFound("blocks_sub::next() returned None".to_string()))) + } + } + }; + + let block_hash = block.hash(); + + for extrinsic in block.extrinsics().await?.iter() { + match extrinsic { + Ok(extrinsic) => { + let ex_events = extrinsic.events().await?; + events.write().await.push((block_hash, ex_events)); + } + Err(error) => { + tracing::trace!("found error: {:?}", error); + } + } + } + } + + tracing::trace!("stopped event-listener"); + Ok(()) +} diff --git a/cli/polka-storage/storagext/src/runtime/mod.rs b/cli/polka-storage/storagext/src/runtime/mod.rs index 484a1d43..bd6d81bc 100644 --- a/cli/polka-storage/storagext/src/runtime/mod.rs +++ b/cli/polka-storage/storagext/src/runtime/mod.rs @@ -103,7 +103,7 @@ pub mod display; mod polka_storage_runtime {} // Using self keeps the import separate from the others -pub use client::SubmissionResult; +pub use client::{HashOfPsc, SubmissionResult}; pub use self::polka_storage_runtime::*; #[cfg(test)] diff --git a/maat/tests/real_world.rs b/maat/tests/real_world.rs index bb8406fa..5ff55c55 100644 --- a/maat/tests/real_world.rs +++ b/maat/tests/real_world.rs @@ -1,4 +1,8 @@ -use std::{collections::BTreeSet, time::Duration}; +// TODO(@neutrinoks,31.10.24): See issue #477. +#![allow(dead_code)] +#![allow(unused_imports)] + +use std::collections::BTreeSet; use maat::*; use primitives_proofs::SectorSize; @@ -23,21 +27,6 @@ use zombienet_sdk::NetworkConfigExt; /// Network's collator name. Used for logs and so on. const COLLATOR_NAME: &str = "collator"; -const STRATEGIC_SLEEP: Duration = Duration::from_secs(6); - -/// Strategic sleep is a band-aid for [subxt#1668](https://github.com/paritytech/subxt/issues/1668). -/// -/// The proper fix is to way for an event that actually reflects the success status of the operation. -/// A possible fix is shown in [polkadot-sdk#4883](https://github.com/paritytech/polkadot-sdk/pull/4883/files#diff-275b35fb5cb16898b64ab5ba6b7da61a5107b3941aee88303cc298e735acbaa7R131-R151), -/// however, it is not very ergonomic. -async fn strategic_sleep() { - tracing::warn!( - "sleeping for {:?}, for more information, see https://github.com/paritytech/subxt/issues/1668", - STRATEGIC_SLEEP - ); - tokio::time::sleep(STRATEGIC_SLEEP).await; -} - async fn register_storage_provider(client: &storagext::Client, charlie: &Keypair) where Keypair: subxt::tx::Signer, @@ -46,35 +35,34 @@ where let peer_id = "dummy_peer_id".to_string(); let peer_id_bytes = peer_id.as_bytes(); - let result = client + let events = client .register_storage_provider( charlie, peer_id.clone(), primitives_proofs::RegisteredPoStProof::StackedDRGWindow2KiBV1P1, + true, ) .await + .unwrap() + .expect("expected cli to return results") .unwrap(); - for event in result - .events - .find::() - { - let event = event.unwrap(); - - assert_eq!(event.owner, charlie.account_id().clone().into()); - assert_eq!(event.proving_period_start, 63); - assert_eq!(event.info.peer_id.0, peer_id.clone().into_bytes()); - assert_eq!(event.info.sector_size, SectorSize::_2KiB); - assert_eq!( - event.info.window_post_proof_type, - primitives_proofs::RegisteredPoStProof::StackedDRGWindow2KiBV1P1 - ); - assert_eq!( - event.info.window_post_partition_sectors, - primitives_proofs::RegisteredPoStProof::StackedDRGWindow2KiBV1P1 - .window_post_partitions_sector() - ); - } + assert_eq!(events[0].variant.owner, charlie.account_id().clone().into()); + assert_eq!(events[0].variant.proving_period_start, 63); + assert_eq!( + events[0].variant.info.peer_id.0, + peer_id.clone().into_bytes() + ); + assert_eq!(events[0].variant.info.sector_size, SectorSize::_2KiB); + assert_eq!( + events[0].variant.info.window_post_proof_type, + primitives_proofs::RegisteredPoStProof::StackedDRGWindow2KiBV1P1 + ); + assert_eq!( + events[0].variant.info.window_post_partition_sectors, + primitives_proofs::RegisteredPoStProof::StackedDRGWindow2KiBV1P1 + .window_post_partitions_sector() + ); let retrieved_peer_info = client .retrieve_storage_provider(&subxt::utils::AccountId32::from( @@ -94,16 +82,15 @@ async fn add_balance(client: &storagext::Client, account: &Keypair, bal where Keypair: subxt::tx::Signer, { - client.add_balance(account, balance).await.unwrap(); - - let balance_entry = client - .retrieve_balance(account.account_id().clone()) + let events = client + .add_balance(account, balance, true) .await .unwrap() + .expect("expect submission result to be returned") .unwrap(); - assert_eq!(balance_entry.free, balance); - assert_eq!(balance_entry.locked, 0); + assert_eq!(events[0].variant.who, account.account_id().into()); + assert_eq!(events[0].variant.amount, balance); } async fn settle_deal_payments( @@ -113,25 +100,24 @@ async fn settle_deal_payments( ) where Keypair: subxt::tx::Signer, { - let settle_result = client.settle_deal_payments(charlie, vec![0]).await.unwrap(); - - for event in settle_result - .events - .find::() - { - let event = event.unwrap(); - assert!(event.unsuccessful.0.is_empty()); - assert_eq!(event.successful.0[0].deal_id, 0); - assert_eq!(event.successful.0[0].amount, 25_000_000_000); - assert_eq!( - event.successful.0[0].provider, - charlie.account_id().clone().into() - ); - assert_eq!( - event.successful.0[0].client, - alice.account_id().clone().into() - ); - } + let events = client + .settle_deal_payments(charlie, vec![0], true) + .await + .unwrap() + .expect("expect submission-result to be returned") + .unwrap(); + + assert!(events[0].variant.unsuccessful.0.is_empty()); + assert_eq!(events[0].variant.successful.0[0].deal_id, 0); + assert_eq!(events[0].variant.successful.0[0].amount, 25_000_000_000); + assert_eq!( + events[0].variant.successful.0[0].provider, + charlie.account_id().clone().into() + ); + assert_eq!( + events[0].variant.successful.0[0].client, + alice.account_id().clone().into() + ); } async fn publish_storage_deals( client: &storagext::Client, @@ -157,22 +143,19 @@ async fn publish_storage_deals( state: DealState::Published, }; - let deal_result = client - .publish_storage_deals(charlie, alice, vec![husky_storage_deal]) + let events = client + .publish_storage_deals(charlie, alice, vec![husky_storage_deal], true) .await + .unwrap() + .expect("expect submission result to be returned") .unwrap(); - for event in deal_result - .events - .find::() - { - let event = event.unwrap(); - tracing::debug!(?event); - - assert_eq!(event.client, alice.account_id().clone().into()); - assert_eq!(event.provider, charlie.account_id().clone().into()); - assert_eq!(event.deal_id, 0); // first deal ever - } + assert_eq!(events[0].variant.client, alice.account_id().clone().into()); + assert_eq!( + events[0].variant.provider, + charlie.account_id().clone().into() + ); + assert_eq!(events[0].variant.deal_id, 0); // first deal ever } async fn pre_commit_sectors(client: &storagext::Client, charlie: &Keypair) @@ -201,21 +184,15 @@ where seal_randomness_height: 0, }]; - let result = client - .pre_commit_sectors(charlie, sectors_pre_commit_info.clone()) + let events = client + .pre_commit_sectors(charlie, sectors_pre_commit_info.clone(), true) .await + .unwrap() + .expect("expect submission result to be returned") .unwrap(); - for event in result - .events - .find::() - { - let event = event.unwrap(); - tracing::debug!(?event); - - assert_eq!(event.owner, charlie.account_id().clone().into()); - assert_eq!(event.sectors.0, sectors_pre_commit_info); - } + assert_eq!(events[0].variant.owner, charlie.account_id().clone().into()); + assert_eq!(events[0].variant.sectors.0, sectors_pre_commit_info); } async fn prove_commit_sectors(client: &storagext::Client, charlie: &Keypair) @@ -228,7 +205,7 @@ where deadline_idx: 0, }]; - let result = client + let events = client .prove_commit_sectors( charlie, vec![ProveCommitSector { @@ -236,27 +213,22 @@ where proof: vec![0u8; 4], } .into()], + true, ) .await + .unwrap() + .expect("expect submission result to be returned") .unwrap(); - for event in result - .events - .find::() - { - let event = event.unwrap(); - tracing::debug!(?event); - - assert_eq!(event.owner, charlie.account_id().clone().into()); - assert_eq!(event.sectors.0, expected_results); - } + assert_eq!(events[0].variant.owner, charlie.account_id().clone().into()); + assert_eq!(events[0].variant.sectors.0, expected_results); } async fn submit_windowed_post(client: &storagext::Client, charlie: &Keypair) where Keypair: subxt::tx::Signer, { - let windowed_post_result = client + let events = client .submit_windowed_post( charlie, SubmitWindowedPoStParams { @@ -269,18 +241,14 @@ where proof_bytes: "beef".to_string().into_bounded_byte_vec(), }, }, + true, ) .await + .unwrap() + .expect("expect submission result to be returned") .unwrap(); - for event in windowed_post_result - .events - .find::() - { - let event = event.unwrap(); - - assert_eq!(event.owner, charlie.account_id().clone().into()); - } + assert_eq!(events[0].variant.owner, charlie.account_id().clone().into()); } async fn declare_recoveries(client: &storagext::Client, charlie: &Keypair) @@ -292,19 +260,15 @@ where partition: 0, sectors: BTreeSet::from_iter([1u64].into_iter()), }]; - let faults_recovered_result = client - .declare_faults_recovered(charlie, recovery_declarations.clone()) + let events = client + .declare_faults_recovered(charlie, recovery_declarations.clone(), true) .await + .unwrap() + .expect("expect submission result to be returned") .unwrap(); - for event in faults_recovered_result - .events - .find::() - { - let event = event.unwrap(); - assert_eq!(event.owner, charlie.account_id().clone().into()); - assert_eq!(event.recoveries.0, recovery_declarations); - } + assert_eq!(events[0].variant.owner, charlie.account_id().clone().into()); + assert_eq!(events[0].variant.recoveries.0, recovery_declarations); } async fn declare_faults(client: &storagext::Client, charlie: &Keypair) @@ -316,26 +280,20 @@ where partition: 0, sectors: BTreeSet::from_iter([1u64].into_iter()), }]; - let fault_declaration_result = client - .declare_faults(charlie, fault_declarations.clone()) + let events = client + .declare_faults(charlie, fault_declarations.clone(), true) .await + .unwrap() + .expect("expect submission result to be returned") .unwrap(); - for event in fault_declaration_result - .events - .find::() - { - let event = event.unwrap(); - assert_eq!(event.owner, charlie.account_id().clone().into()); - assert_eq!(event.faults.0, fault_declarations); - } + assert_eq!(events[0].variant.owner, charlie.account_id().clone().into()); + assert_eq!(events[0].variant.faults.0, fault_declarations); } /// This test was adapted from a bash script and is timing sensitive. /// While it works right now, it still needs some work to better test the parachain, /// like reading the sector deadlines and so on. -/// -// TODO(@jmg-duarte,#381,17/09/2024): Remove the timing dependencies #[tokio::test] async fn real_world_use_case() { setup_logging(); @@ -357,8 +315,6 @@ async fn real_world_use_case() { tracing::debug!("adding {} balance to charlie", balance); add_balance(&client, &charlie_kp, balance).await; - strategic_sleep().await; - // Add balance to Alice let balance = 25_000_000_000; tracing::debug!("adding {} balance to alice", balance); @@ -367,22 +323,24 @@ async fn real_world_use_case() { publish_storage_deals(&client, &charlie_kp, &alice_kp).await; pre_commit_sectors(&client, &charlie_kp).await; - client.wait_for_height(40, true).await.unwrap(); - prove_commit_sectors(&client, &charlie_kp).await; + // TODO(@neutrinoks,31.10.24): See issue #477. + // client.wait_for_height(40, true).await.unwrap(); + + // prove_commit_sectors(&client, &charlie_kp).await; // These ones wait for a specific block so the strategic sleep shouldn't be needed - client.wait_for_height(63, true).await.unwrap(); - submit_windowed_post(&client, &charlie_kp).await; + // client.wait_for_height(63, true).await.unwrap(); + // submit_windowed_post(&client, &charlie_kp).await; - client.wait_for_height(83, true).await.unwrap(); - declare_faults(&client, &charlie_kp).await; + // client.wait_for_height(83, true).await.unwrap(); + // declare_faults(&client, &charlie_kp).await; - declare_recoveries(&client, &charlie_kp).await; + // declare_recoveries(&client, &charlie_kp).await; - client.wait_for_height(103, true).await.unwrap(); - submit_windowed_post(&client, &charlie_kp).await; + // client.wait_for_height(103, true).await.unwrap(); + // submit_windowed_post(&client, &charlie_kp).await; - client.wait_for_height(115, true).await.unwrap(); - settle_deal_payments(&client, &charlie_kp, &alice_kp).await; + // client.wait_for_height(115, true).await.unwrap(); + // settle_deal_payments(&client, &charlie_kp, &alice_kp).await; }