From f95a3c9dc447e71703a65797c1dca7feba98eb59 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 13 Nov 2023 10:01:54 -0700 Subject: [PATCH 01/75] chore: Replace Currency->fungible: update pallet_capacity with fungible --- pallets/capacity/src/benchmarking.rs | 3 +- pallets/capacity/src/lib.rs | 58 +++++++++++++++++++++++----- pallets/capacity/src/types.rs | 10 ++++- runtime/frequency/src/lib.rs | 7 ++-- 4 files changed, 64 insertions(+), 14 deletions(-) diff --git a/pallets/capacity/src/benchmarking.rs b/pallets/capacity/src/benchmarking.rs index 3f6fe24099..6c97e0391f 100644 --- a/pallets/capacity/src/benchmarking.rs +++ b/pallets/capacity/src/benchmarking.rs @@ -26,7 +26,8 @@ pub fn create_funded_account( whitelist_account!(user); let balance = T::Currency::minimum_balance() * balance_factor.into(); let _ = T::Currency::make_free_balance_be(&user, balance); - assert_eq!(T::Currency::free_balance(&user), balance.into()); + // REVIEW: + assert_eq!(T::fungible::Inspect::balance(&user), balance.into()); user } diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 61640341a5..2ac309b89a 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -51,7 +51,7 @@ use frame_support::{ dispatch::DispatchResult, ensure, - traits::{Currency, Get, Hooks, LockIdentifier, LockableCurrency, WithdrawReasons}, + traits::{fungible, Get, Hooks}, weights::{constants::RocksDbWeight, Weight}, }; @@ -82,11 +82,19 @@ mod benchmarking; mod tests; pub mod weights; +// REVIEW: original +// type BalanceOf = +// <::Currency as Currency<::AccountId>>::Balance; -type BalanceOf = - <::Currency as Currency<::AccountId>>::Balance; +// type BalanceOf = +// <::FungibleToken as fungible::Inspect<::AccountId>>::Balance; + +// REVIEW: Mostly working version, except Balance doesn't have EncodeLike +use codec::EncodeLike; +type BalanceOf = <::FungibleToken as frame_support::traits::fungible::Inspect< + ::AccountId, +>>::Balance; -const STAKING_ID: LockIdentifier = *b"netstkng"; use frame_system::pallet_prelude::*; #[frame_support::pallet] pub mod pallet { @@ -95,16 +103,33 @@ pub mod pallet { use frame_support::{pallet_prelude::*, Twox64Concat}; use sp_runtime::traits::{AtLeast32BitUnsigned, MaybeDisplay}; + // REVIEW: Can I put the enum here? + /// A reason for freezing funds. + #[pallet::composite_enum] + pub enum FreezeReason { + // REVIEW: If Id is a type like this, will it fix the EncodeLike issue? + // type Id: codec::Encode + TypeInfo + 'static; + /// The account is staked. + Staked, + } + #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. type RuntimeEvent: From> + IsType<::RuntimeEvent>; + /// The overarching freeze reason. + type RuntimeFreezeReason: From; + /// Weight information for extrinsics in this pallet. type WeightInfo: WeightInfo; /// Function that allows a balance to be locked. - type Currency: LockableCurrency>; + // REVIEW: replace LockableCurrency + // type Currency: LockableCurrency>; + type FungibleToken: fungible::InspectFreeze + + fungible::MutateFreeze + + fungible::Inspect; /// Function that checks if an MSA is a valid target. type TargetValidator: TargetValidator; @@ -473,14 +498,29 @@ impl Pallet { } /// Sets staking account details. - fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) { - T::Currency::set_lock(STAKING_ID, &staker, staking_account.total, WithdrawReasons::all()); - StakingAccountLedger::::insert(staker, staking_account); + fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) + // REVIEW: experimenting with restricting the EncodeLike trait + // where + // <::FungibleToken as frame_support::traits::fungible::Inspect< + // ::AccountId, + // >>::Balance: EncodeLike>, + { + // REVIEW: replace LockableCurrency + // T::Currency::set_lock(STAKING_ID, &staker, staking_account.total, WithdrawReasons::all()); + <::FungibleToken as frame_support::traits::fungible::freeze::Mutate< + T::AccountId, + >>::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total); + StakingAccountLedger::::insert(staker, staking_account.total); } /// Deletes staking account details fn delete_staking_account(staker: &T::AccountId) { - T::Currency::remove_lock(STAKING_ID, &staker); + // REVIEW: replace remove_lock with thaw + // T::FungibleToken::freeze::Mutate::thaw(STAKING_ID, staker); + <::FungibleToken as frame_support::traits::fungible::freeze::Mutate< + T::AccountId, + >>::thaw(&FreezeReason::Staked.into(), staker); + // T::Currency::remove_lock(STAKING_ID, &staker); StakingAccountLedger::::remove(&staker); } diff --git a/pallets/capacity/src/types.rs b/pallets/capacity/src/types.rs index 72f5168cb8..a5a9c86a37 100644 --- a/pallets/capacity/src/types.rs +++ b/pallets/capacity/src/types.rs @@ -49,7 +49,15 @@ impl StakingAccountDetails { staker: &T::AccountId, proposed_amount: BalanceOf, ) -> BalanceOf { - let account_balance = T::Currency::free_balance(&staker); + // REVIEW: experiments at getting the type correct/shorter + // let account_balance = T::Currency::free_balance(&staker); + // let account_balance = <::FungibleToken as frame_support::traits::fungible::Inspect<_>>::balance(&staker); + // let account_balance = T::FungibleToken::fungible::Inspect::balance(&staker); + // let account_balance = BalanceOf::::balance(&staker); + let account_balance = + <::FungibleToken as frame_support::traits::fungible::Inspect< + ::AccountId, + >>::balance(&staker); let available_staking_balance = account_balance.saturating_sub(self.total); available_staking_balance .saturating_sub(T::MinimumTokenBalance::get()) diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 1af8603e70..37421a6ce1 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -406,7 +406,8 @@ impl pallet_msa::Config for Runtime { impl pallet_capacity::Config for Runtime { type RuntimeEvent = RuntimeEvent; type WeightInfo = pallet_capacity::weights::SubstrateWeight; - type Currency = Balances; + // REVIEW: Change Currency->Fungible + type FungibleToken = Balances; type MinimumStakingAmount = CapacityMinimumStakingAmount; type MinimumTokenBalance = CapacityMinimumTokenBalance; type TargetValidator = Msa; @@ -509,7 +510,7 @@ impl pallet_balances::Config for Runtime { type MaxHolds = ConstU32<0>; type MaxFreezes = ConstU32<0>; type RuntimeHoldReason = RuntimeHoldReason; - type FreezeIdentifier = (); + type FreezeIdentifier = RuntimeFreezeReason; } // Needs parameter_types! for the Weight type parameter_types! { @@ -1056,7 +1057,7 @@ construct_runtime!( Messages: pallet_messages::{Pallet, Call, Storage, Event} = 61, Schemas: pallet_schemas::{Pallet, Call, Storage, Event, Config} = 62, StatefulStorage: pallet_stateful_storage::{Pallet, Call, Storage, Event} = 63, - Capacity: pallet_capacity::{Pallet, Call, Storage, Event} = 64, + Capacity: pallet_capacity::{Pallet, Call, Storage, Event, FreezeReason} = 64, FrequencyTxPayment: pallet_frequency_tx_payment::{Pallet, Call, Event} = 65, Handles: pallet_handles::{Pallet, Call, Storage, Event} = 66, } From 72543faee6682abba8af16f58e67cc02559eaa54 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 13 Nov 2023 12:43:28 -0700 Subject: [PATCH 02/75] fix: keep Currency name and update derived trait --- pallets/capacity/src/lib.rs | 31 +++++++++++++++++-------------- pallets/capacity/src/types.rs | 6 ++---- runtime/frequency/src/lib.rs | 2 +- 3 files changed, 20 insertions(+), 19 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 2ac309b89a..652da12edb 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -51,7 +51,12 @@ use frame_support::{ dispatch::DispatchResult, ensure, - traits::{fungible, Get, Hooks}, + traits::{ + fungible::{ + Inspect as FunInspect, InspectFreeze, MutateFreeze, freeze::Mutate + }, + Get, Hooks + }, weights::{constants::RocksDbWeight, Weight}, }; @@ -90,10 +95,10 @@ pub mod weights; // <::FungibleToken as fungible::Inspect<::AccountId>>::Balance; // REVIEW: Mostly working version, except Balance doesn't have EncodeLike -use codec::EncodeLike; -type BalanceOf = <::FungibleToken as frame_support::traits::fungible::Inspect< - ::AccountId, ->>::Balance; +type BalanceOf = <::Currency as FunInspect<::AccountId>>::Balance; +// ::traits::fungible::Inspect< +// ::AccountId, +// >>::Balance; use frame_system::pallet_prelude::*; #[frame_support::pallet] @@ -113,6 +118,8 @@ pub mod pallet { Staked, } + // REVIEW: Why do we need to add EncodeLike to Balance? + // use codec::EncodeLike; #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. @@ -127,9 +134,9 @@ pub mod pallet { /// Function that allows a balance to be locked. // REVIEW: replace LockableCurrency // type Currency: LockableCurrency>; - type FungibleToken: fungible::InspectFreeze - + fungible::MutateFreeze - + fungible::Inspect; + type Currency: InspectFreeze + + MutateFreeze + + FunInspect; /// Function that checks if an MSA is a valid target. type TargetValidator: TargetValidator; @@ -507,9 +514,7 @@ impl Pallet { { // REVIEW: replace LockableCurrency // T::Currency::set_lock(STAKING_ID, &staker, staking_account.total, WithdrawReasons::all()); - <::FungibleToken as frame_support::traits::fungible::freeze::Mutate< - T::AccountId, - >>::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total); + <::Currency as Mutate< T::AccountId, >>::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total); StakingAccountLedger::::insert(staker, staking_account.total); } @@ -517,9 +522,7 @@ impl Pallet { fn delete_staking_account(staker: &T::AccountId) { // REVIEW: replace remove_lock with thaw // T::FungibleToken::freeze::Mutate::thaw(STAKING_ID, staker); - <::FungibleToken as frame_support::traits::fungible::freeze::Mutate< - T::AccountId, - >>::thaw(&FreezeReason::Staked.into(), staker); + <::Currency as Mutate< T::AccountId, >>::thaw(&FreezeReason::Staked.into(), staker); // T::Currency::remove_lock(STAKING_ID, &staker); StakingAccountLedger::::remove(&staker); } diff --git a/pallets/capacity/src/types.rs b/pallets/capacity/src/types.rs index a5a9c86a37..64955ac16e 100644 --- a/pallets/capacity/src/types.rs +++ b/pallets/capacity/src/types.rs @@ -54,10 +54,8 @@ impl StakingAccountDetails { // let account_balance = <::FungibleToken as frame_support::traits::fungible::Inspect<_>>::balance(&staker); // let account_balance = T::FungibleToken::fungible::Inspect::balance(&staker); // let account_balance = BalanceOf::::balance(&staker); - let account_balance = - <::FungibleToken as frame_support::traits::fungible::Inspect< - ::AccountId, - >>::balance(&staker); + let account_balance = T::Currency::balance(&staker); + // <::Currency as nspect<::AccountId>>::balance(&staker); let available_staking_balance = account_balance.saturating_sub(self.total); available_staking_balance .saturating_sub(T::MinimumTokenBalance::get()) diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 37421a6ce1..069266ea88 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -407,7 +407,7 @@ impl pallet_capacity::Config for Runtime { type RuntimeEvent = RuntimeEvent; type WeightInfo = pallet_capacity::weights::SubstrateWeight; // REVIEW: Change Currency->Fungible - type FungibleToken = Balances; + type Currency = Balances; type MinimumStakingAmount = CapacityMinimumStakingAmount; type MinimumTokenBalance = CapacityMinimumTokenBalance; type TargetValidator = Msa; From 478ee54934e40681005be6ac930a2c49566cf18b Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 15 Nov 2023 08:42:03 -0700 Subject: [PATCH 03/75] fix: pallet_capacity tests working with correct types/traits --- pallets/capacity/src/lib.rs | 51 ++++++------------------------ pallets/capacity/src/tests/mock.rs | 9 +++--- pallets/capacity/src/types.rs | 6 ---- 3 files changed, 15 insertions(+), 51 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 652da12edb..1663f329e5 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -52,10 +52,8 @@ use frame_support::{ dispatch::DispatchResult, ensure, traits::{ - fungible::{ - Inspect as FunInspect, InspectFreeze, MutateFreeze, freeze::Mutate - }, - Get, Hooks + tokens::fungible::{Inspect as InspectFungible, MutateFreeze}, + Get, Hooks, }, weights::{constants::RocksDbWeight, Weight}, }; @@ -87,18 +85,8 @@ mod benchmarking; mod tests; pub mod weights; -// REVIEW: original -// type BalanceOf = -// <::Currency as Currency<::AccountId>>::Balance; - -// type BalanceOf = -// <::FungibleToken as fungible::Inspect<::AccountId>>::Balance; - -// REVIEW: Mostly working version, except Balance doesn't have EncodeLike -type BalanceOf = <::Currency as FunInspect<::AccountId>>::Balance; -// ::traits::fungible::Inspect< -// ::AccountId, -// >>::Balance; +type BalanceOf = + <::Currency as InspectFungible<::AccountId>>::Balance; use frame_system::pallet_prelude::*; #[frame_support::pallet] @@ -108,18 +96,13 @@ pub mod pallet { use frame_support::{pallet_prelude::*, Twox64Concat}; use sp_runtime::traits::{AtLeast32BitUnsigned, MaybeDisplay}; - // REVIEW: Can I put the enum here? /// A reason for freezing funds. #[pallet::composite_enum] pub enum FreezeReason { - // REVIEW: If Id is a type like this, will it fix the EncodeLike issue? - // type Id: codec::Encode + TypeInfo + 'static; /// The account is staked. Staked, } - // REVIEW: Why do we need to add EncodeLike to Balance? - // use codec::EncodeLike; #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. @@ -132,11 +115,7 @@ pub mod pallet { type WeightInfo: WeightInfo; /// Function that allows a balance to be locked. - // REVIEW: replace LockableCurrency - // type Currency: LockableCurrency>; - type Currency: InspectFreeze - + MutateFreeze - + FunInspect; + type Currency: MutateFreeze; /// Function that checks if an MSA is a valid target. type TargetValidator: TargetValidator; @@ -505,25 +484,15 @@ impl Pallet { } /// Sets staking account details. - fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) - // REVIEW: experimenting with restricting the EncodeLike trait - // where - // <::FungibleToken as frame_support::traits::fungible::Inspect< - // ::AccountId, - // >>::Balance: EncodeLike>, - { - // REVIEW: replace LockableCurrency - // T::Currency::set_lock(STAKING_ID, &staker, staking_account.total, WithdrawReasons::all()); - <::Currency as Mutate< T::AccountId, >>::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total); - StakingAccountLedger::::insert(staker, staking_account.total); + fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) { + let _ = + T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total); + StakingAccountLedger::::insert(staker, staking_account); } /// Deletes staking account details fn delete_staking_account(staker: &T::AccountId) { - // REVIEW: replace remove_lock with thaw - // T::FungibleToken::freeze::Mutate::thaw(STAKING_ID, staker); - <::Currency as Mutate< T::AccountId, >>::thaw(&FreezeReason::Staked.into(), staker); - // T::Currency::remove_lock(STAKING_ID, &staker); + let _ = T::Currency::thaw(&FreezeReason::Staked.into(), staker); StakingAccountLedger::::remove(&staker); } diff --git a/pallets/capacity/src/tests/mock.rs b/pallets/capacity/src/tests/mock.rs index 1251093e75..c6502ecc0d 100644 --- a/pallets/capacity/src/tests/mock.rs +++ b/pallets/capacity/src/tests/mock.rs @@ -24,7 +24,7 @@ construct_runtime!( System: frame_system::{Pallet, Call, Config, Storage, Event}, Balances: pallet_balances::{Pallet, Call, Storage, Config, Event}, Msa: pallet_msa::{Pallet, Call, Storage, Event}, - Capacity: pallet_capacity::{Pallet, Call, Storage, Event}, + Capacity: pallet_capacity::{Pallet, Call, Storage, Event, FreezeReason}, } ); @@ -64,10 +64,10 @@ impl pallet_balances::Config for Test { type ExistentialDeposit = ConstU64<1>; type AccountStore = System; type WeightInfo = (); - type FreezeIdentifier = (); - type MaxFreezes = ConstU32<0>; - type MaxHolds = ConstU32<0>; + type FreezeIdentifier = RuntimeFreezeReason; + type MaxFreezes = ConstU32<1>; type RuntimeHoldReason = (); + type MaxHolds = ConstU32<0>; } pub type MaxSchemaGrantsPerDelegation = ConstU32<30>; @@ -135,6 +135,7 @@ parameter_types! { impl pallet_capacity::Config for Test { type RuntimeEvent = RuntimeEvent; type WeightInfo = (); + type RuntimeFreezeReason = RuntimeFreezeReason; type Currency = pallet_balances::Pallet; type TargetValidator = Msa; // In test, this must be >= Token:Capacity ratio since unit is plancks diff --git a/pallets/capacity/src/types.rs b/pallets/capacity/src/types.rs index 64955ac16e..c939b2ef6a 100644 --- a/pallets/capacity/src/types.rs +++ b/pallets/capacity/src/types.rs @@ -49,13 +49,7 @@ impl StakingAccountDetails { staker: &T::AccountId, proposed_amount: BalanceOf, ) -> BalanceOf { - // REVIEW: experiments at getting the type correct/shorter - // let account_balance = T::Currency::free_balance(&staker); - // let account_balance = <::FungibleToken as frame_support::traits::fungible::Inspect<_>>::balance(&staker); - // let account_balance = T::FungibleToken::fungible::Inspect::balance(&staker); - // let account_balance = BalanceOf::::balance(&staker); let account_balance = T::Currency::balance(&staker); - // <::Currency as nspect<::AccountId>>::balance(&staker); let available_staking_balance = account_balance.saturating_sub(self.total); available_staking_balance .saturating_sub(T::MinimumTokenBalance::get()) From 1befab1ce992c42b5fdebe4c64b941ab48a39eb5 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 15 Nov 2023 12:34:46 -0700 Subject: [PATCH 04/75] fix: capacity pallet tests passing; update vscode with rust std source maps; --- .vscode/settings.json | 3 +++ pallets/capacity/src/lib.rs | 7 +++++-- pallets/capacity/src/tests/other_tests.rs | 10 ++++++---- .../capacity/src/tests/stake_and_deposit_tests.rs | 14 +++++--------- .../capacity/src/tests/withdraw_unstaked_tests.rs | 12 +++++------- runtime/frequency/src/lib.rs | 1 + 6 files changed, 25 insertions(+), 22 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index dc8bb82b31..639f34b040 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -16,5 +16,8 @@ // Set the features to use for cargo commands "rust-analyzer.cargo.features": [ "frequency-no-relay" + ], + "lldb.launch.preRunCommands": [ + "script lldb.debugger.HandleCommand('settings set target.source-map /rustc/{} \"{}/lib/rustlib/src/rust\"'.format(os.popen('rustc --version --verbose').read().split('commit-hash: ')[1].split('\\n')[0].strip(), os.popen('rustc --print sysroot').readline().strip()))" ] } diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 1663f329e5..ff70702bd9 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -52,7 +52,7 @@ use frame_support::{ dispatch::DispatchResult, ensure, traits::{ - tokens::fungible::{Inspect as InspectFungible, MutateFreeze}, + tokens::fungible::{Inspect as InspectFungible, InspectFreeze, MutateFreeze}, Get, Hooks, }, weights::{constants::RocksDbWeight, Weight}, @@ -100,6 +100,7 @@ pub mod pallet { #[pallet::composite_enum] pub enum FreezeReason { /// The account is staked. + #[codec(index = 0)] Staked, } @@ -115,7 +116,9 @@ pub mod pallet { type WeightInfo: WeightInfo; /// Function that allows a balance to be locked. - type Currency: MutateFreeze; + type Currency: MutateFreeze + + InspectFreeze + + InspectFungible; /// Function that checks if an MSA is a valid target. type TargetValidator: TargetValidator; diff --git a/pallets/capacity/src/tests/other_tests.rs b/pallets/capacity/src/tests/other_tests.rs index 7a32c1a87c..cb0822d082 100644 --- a/pallets/capacity/src/tests/other_tests.rs +++ b/pallets/capacity/src/tests/other_tests.rs @@ -1,11 +1,11 @@ -use frame_support::traits::{Currency, Get}; +use frame_support::traits::{fungible::{InspectFreeze, Inspect}, Get}; use frame_system::pallet_prelude::BlockNumberFor; use sp_runtime::traits::Zero; use common_primitives::{capacity::Nontransferable, msa::MessageSourceId}; use crate::{ - BalanceOf, CapacityDetails, Config, CurrentEpoch, CurrentEpochInfo, EpochInfo, + BalanceOf, CapacityDetails, Config, CurrentEpoch, CurrentEpochInfo, EpochInfo, FreezeReason, StakingAccountDetails, StakingTargetDetails, }; @@ -72,7 +72,9 @@ fn set_staking_account_is_succesful() { Capacity::set_staking_account(&staker, &staking_account); - assert_eq!(Balances::locks(&staker)[0].amount, 55); + let frozen_balance = + ::Currency::balance_frozen(&(FreezeReason::Staked).into(), &staker); + assert_eq!(frozen_balance, 55); }); } @@ -127,7 +129,7 @@ fn it_configures_staking_minimum_greater_than_or_equal_to_existential_deposit() new_test_ext().execute_with(|| { let minimum_staking_balance_config: BalanceOf = ::MinimumStakingAmount::get(); - assert!(minimum_staking_balance_config >= ::Currency::minimum_balance()) + assert!(minimum_staking_balance_config >= ::Currency::minimum_balance()); }); } diff --git a/pallets/capacity/src/tests/stake_and_deposit_tests.rs b/pallets/capacity/src/tests/stake_and_deposit_tests.rs index 95e5b94c8d..c6d83ec924 100644 --- a/pallets/capacity/src/tests/stake_and_deposit_tests.rs +++ b/pallets/capacity/src/tests/stake_and_deposit_tests.rs @@ -1,7 +1,7 @@ use super::{mock::*, testing_utils::*}; -use crate::{BalanceOf, CapacityDetails, Error, Event, StakingAccountDetails}; +use crate::{BalanceOf, CapacityDetails, Config, Error, Event, StakingAccountDetails, FreezeReason}; use common_primitives::{capacity::Nontransferable, msa::MessageSourceId}; -use frame_support::{assert_noop, assert_ok, traits::WithdrawReasons}; +use frame_support::{assert_noop, assert_ok, traits::fungible::InspectFreeze}; use sp_runtime::ArithmeticError; #[test] @@ -39,8 +39,7 @@ fn stake_works() { let events = staking_events(); assert_eq!(events.first().unwrap(), &Event::Staked { account, target, amount, capacity }); - assert_eq!(Balances::locks(&account)[0].amount, amount); - assert_eq!(Balances::locks(&account)[0].reasons, WithdrawReasons::all().into()); + assert_eq!(::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), amount); }); } @@ -100,9 +99,7 @@ fn stake_increase_stake_amount_works() { events.first().unwrap(), &Event::Staked { account, target, amount: initial_amount, capacity } ); - - assert_eq!(Balances::locks(&account)[0].amount, 50); - assert_eq!(Balances::locks(&account)[0].reasons, WithdrawReasons::all().into()); + assert_eq!(::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), 50); assert_ok!(Capacity::set_epoch_length(RuntimeOrigin::root(), 10)); @@ -134,8 +131,7 @@ fn stake_increase_stake_amount_works() { &Event::Staked { account, target, amount: additional_amount, capacity } ); - assert_eq!(Balances::locks(&account)[0].amount, 150); - assert_eq!(Balances::locks(&account)[0].reasons, WithdrawReasons::all().into()); + assert_eq!(::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), 150); }); } diff --git a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs index c8356b86e7..7b49bee425 100644 --- a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs +++ b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs @@ -1,8 +1,8 @@ use super::{mock::*, testing_utils::run_to_block}; -use crate as pallet_capacity; +use crate::{self as pallet_capacity, FreezeReason}; use crate::StakingAccountDetails; -use frame_support::{assert_noop, assert_ok}; -use pallet_capacity::{BalanceOf, Error, Event}; +use frame_support::{assert_noop, assert_ok, traits::fungible::InspectFreeze}; +use pallet_capacity::{BalanceOf, Config, Error, Event}; #[test] fn withdraw_unstaked_happy_path() { @@ -52,8 +52,7 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); Capacity::set_staking_account(&staker, &staking_account); - assert_eq!(1, Balances::locks(&staker).len()); - assert_eq!(10u64, Balances::locks(&staker)[0].amount); + assert_eq!(10u64, ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker)); assert_ok!(Capacity::set_epoch_length(RuntimeOrigin::root(), 10)); @@ -61,8 +60,7 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { run_to_block(31); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); - assert_eq!(1, Balances::locks(&staker).len()); - assert_eq!(7u64, Balances::locks(&staker)[0].amount); + assert_eq!(7u64, ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker)); }) } diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 069266ea88..cbc24f690e 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -418,6 +418,7 @@ impl pallet_capacity::Config for Runtime { type MaxEpochLength = CapacityMaxEpochLength; type EpochNumber = u32; type CapacityPerToken = CapacityPerToken; + type RuntimeFreezeReason = RuntimeFreezeReason; } impl pallet_schemas::Config for Runtime { From 7fbdf01b2ebd5fa9ad7a1b3c3fe7693d89548ae2 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 15 Nov 2023 12:42:18 -0700 Subject: [PATCH 05/75] fix: lint changes; --- pallets/capacity/src/tests/other_tests.rs | 5 ++++- .../src/tests/stake_and_deposit_tests.rs | 19 +++++++++++++++---- .../src/tests/withdraw_unstaked_tests.rs | 13 +++++++++---- 3 files changed, 28 insertions(+), 9 deletions(-) diff --git a/pallets/capacity/src/tests/other_tests.rs b/pallets/capacity/src/tests/other_tests.rs index cb0822d082..387baa0f94 100644 --- a/pallets/capacity/src/tests/other_tests.rs +++ b/pallets/capacity/src/tests/other_tests.rs @@ -1,4 +1,7 @@ -use frame_support::traits::{fungible::{InspectFreeze, Inspect}, Get}; +use frame_support::traits::{ + fungible::{Inspect, InspectFreeze}, + Get, +}; use frame_system::pallet_prelude::BlockNumberFor; use sp_runtime::traits::Zero; diff --git a/pallets/capacity/src/tests/stake_and_deposit_tests.rs b/pallets/capacity/src/tests/stake_and_deposit_tests.rs index c6d83ec924..c43b408dbb 100644 --- a/pallets/capacity/src/tests/stake_and_deposit_tests.rs +++ b/pallets/capacity/src/tests/stake_and_deposit_tests.rs @@ -1,5 +1,7 @@ use super::{mock::*, testing_utils::*}; -use crate::{BalanceOf, CapacityDetails, Config, Error, Event, StakingAccountDetails, FreezeReason}; +use crate::{ + BalanceOf, CapacityDetails, Config, Error, Event, FreezeReason, StakingAccountDetails, +}; use common_primitives::{capacity::Nontransferable, msa::MessageSourceId}; use frame_support::{assert_noop, assert_ok, traits::fungible::InspectFreeze}; use sp_runtime::ArithmeticError; @@ -39,7 +41,10 @@ fn stake_works() { let events = staking_events(); assert_eq!(events.first().unwrap(), &Event::Staked { account, target, amount, capacity }); - assert_eq!(::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), amount); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + amount + ); }); } @@ -99,7 +104,10 @@ fn stake_increase_stake_amount_works() { events.first().unwrap(), &Event::Staked { account, target, amount: initial_amount, capacity } ); - assert_eq!(::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), 50); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + 50 + ); assert_ok!(Capacity::set_epoch_length(RuntimeOrigin::root(), 10)); @@ -131,7 +139,10 @@ fn stake_increase_stake_amount_works() { &Event::Staked { account, target, amount: additional_amount, capacity } ); - assert_eq!(::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), 150); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + 150 + ); }); } diff --git a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs index 7b49bee425..5f0b316c49 100644 --- a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs +++ b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs @@ -1,6 +1,5 @@ use super::{mock::*, testing_utils::run_to_block}; -use crate::{self as pallet_capacity, FreezeReason}; -use crate::StakingAccountDetails; +use crate::{self as pallet_capacity, FreezeReason, StakingAccountDetails}; use frame_support::{assert_noop, assert_ok, traits::fungible::InspectFreeze}; use pallet_capacity::{BalanceOf, Config, Error, Event}; @@ -52,7 +51,10 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); Capacity::set_staking_account(&staker, &staking_account); - assert_eq!(10u64, ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker)); + assert_eq!( + 10u64, + ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker) + ); assert_ok!(Capacity::set_epoch_length(RuntimeOrigin::root(), 10)); @@ -60,7 +62,10 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { run_to_block(31); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); - assert_eq!(7u64, ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker)); + assert_eq!( + 7u64, + ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker) + ); }) } From 7eceac4bd15ff753343d93ae40e653efb70d96a7 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 15 Nov 2023 14:30:53 -0700 Subject: [PATCH 06/75] fix: benchmarks updates for Currency trait --- pallets/capacity/src/benchmarking.rs | 7 +++---- pallets/capacity/src/lib.rs | 3 ++- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/pallets/capacity/src/benchmarking.rs b/pallets/capacity/src/benchmarking.rs index 6c97e0391f..b85f709734 100644 --- a/pallets/capacity/src/benchmarking.rs +++ b/pallets/capacity/src/benchmarking.rs @@ -2,7 +2,7 @@ use super::*; use crate::Pallet as Capacity; use frame_benchmarking::{account, benchmarks, whitelist_account}; -use frame_support::{assert_ok, traits::Currency}; +use frame_support::assert_ok; use frame_system::RawOrigin; use parity_scale_codec::alloc::vec::Vec; @@ -25,9 +25,8 @@ pub fn create_funded_account( let user = account(string, n, SEED); whitelist_account!(user); let balance = T::Currency::minimum_balance() * balance_factor.into(); - let _ = T::Currency::make_free_balance_be(&user, balance); - // REVIEW: - assert_eq!(T::fungible::Inspect::balance(&user), balance.into()); + let _ = T::Currency::set_balance(&user, balance); + assert_eq!(T::Currency::balance(&user), balance.into()); user } diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index ff70702bd9..6cd02d2d95 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -52,7 +52,7 @@ use frame_support::{ dispatch::DispatchResult, ensure, traits::{ - tokens::fungible::{Inspect as InspectFungible, InspectFreeze, MutateFreeze}, + tokens::fungible::{Inspect as InspectFungible, InspectFreeze, Mutate, MutateFreeze}, Get, Hooks, }, weights::{constants::RocksDbWeight, Weight}, @@ -117,6 +117,7 @@ pub mod pallet { /// Function that allows a balance to be locked. type Currency: MutateFreeze + + Mutate + InspectFreeze + InspectFungible; From 1dad90988048a2af4410d7738c9426dbda648627 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Fri, 17 Nov 2023 16:19:57 -0700 Subject: [PATCH 07/75] fix: time-release pallet updated with fungible traits; test working --- pallets/time-release/src/lib.rs | 54 +++++++----- pallets/time-release/src/mock.rs | 10 ++- pallets/time-release/src/tests.rs | 131 ++++++++++++++++++++++-------- runtime/frequency/src/lib.rs | 4 +- 4 files changed, 140 insertions(+), 59 deletions(-) diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index e3048bdcf3..ece108e569 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -40,8 +40,11 @@ use frame_support::{ ensure, pallet_prelude::*, traits::{ - BuildGenesisConfig, Currency, EnsureOrigin, ExistenceRequirement, Get, LockIdentifier, - LockableCurrency, WithdrawReasons, + tokens::{ + fungible::{Inspect as InspectFungible, Mutate, MutateFreeze}, + Balance, Preservation, + }, + BuildGenesisConfig, EnsureOrigin, Get, }, BoundedVec, }; @@ -68,15 +71,13 @@ mod benchmarking; pub use module::*; -/// The lock identifier for timed released transfers. -pub const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; - #[frame_support::pallet] pub mod module { use super::*; - pub(crate) type BalanceOf = - <::Currency as Currency<::AccountId>>::Balance; + pub(crate) type BalanceOf = <::Currency as InspectFungible< + ::AccountId, + >>::Balance; pub(crate) type ReleaseScheduleOf = ReleaseSchedule, BalanceOf>; /// Scheduled item used for configuring genesis. @@ -88,13 +89,30 @@ pub mod module { BalanceOf, ); + /// A reason for freezing funds. + #[pallet::composite_enum] + pub enum FreezeReason { + /// The account is staked. + #[codec(index = 0)] + Staked, + /// An account with time released assets. + TimeReleased, + } #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. type RuntimeEvent: From> + IsType<::RuntimeEvent>; + /// The overarching freeze reason. + type RuntimeFreezeReason: From; + + /// We need MaybeSerializeDeserialize because of the genesis config. + type Balance: Balance + MaybeSerializeDeserialize; + /// The currency trait used to set a lock on a balance. - type Currency: LockableCurrency>; + type Currency: MutateFreeze + + InspectFungible + + Mutate; #[pallet::constant] /// The minimum amount transferred to call `transfer`. @@ -207,15 +225,14 @@ pub mod module { .expect("Invalid release schedule"); assert!( - T::Currency::free_balance(who) >= total_amount, + T::Currency::balance(who) >= total_amount, "Account do not have enough balance" ); - T::Currency::set_lock( - RELEASE_LOCK_ID, + let _ = T::Currency::set_freeze( + &FreezeReason::TimeReleased.into(), who, total_amount, - WithdrawReasons::all(), ); ReleaseSchedules::::insert(who, bounded_schedules); }); @@ -268,7 +285,7 @@ pub mod module { if to == from { ensure!( - T::Currency::free_balance(&from) >= + T::Currency::balance(&from) >= schedule.total_amount().ok_or(ArithmeticError::Overflow)?, Error::::InsufficientBalanceToLock, ); @@ -385,7 +402,7 @@ impl Pallet { .checked_add(&schedule_amount) .ok_or(ArithmeticError::Overflow)?; - T::Currency::transfer(from, to, schedule_amount, ExistenceRequirement::AllowDeath)?; + T::Currency::transfer(from, to, schedule_amount, Preservation::Expendable)?; Self::update_lock(&to, total_amount); @@ -418,10 +435,7 @@ impl Pallet { }, )?; - ensure!( - T::Currency::free_balance(who) >= total_amount, - Error::::InsufficientBalanceToLock, - ); + ensure!(T::Currency::balance(who) >= total_amount, Error::::InsufficientBalanceToLock,); Self::update_lock(&who, total_amount); Self::set_schedules_for(who, bounded_schedules); @@ -430,11 +444,11 @@ impl Pallet { } fn update_lock(who: &T::AccountId, locked: BalanceOf) { - T::Currency::set_lock(RELEASE_LOCK_ID, who, locked, WithdrawReasons::all()); + let _ = T::Currency::set_freeze(&FreezeReason::TimeReleased.into(), who, locked); } fn delete_lock(who: &T::AccountId) { - T::Currency::remove_lock(RELEASE_LOCK_ID, who); + let _ = T::Currency::thaw(&FreezeReason::TimeReleased.into(), who); } fn set_schedules_for( diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index 7234eea925..a55c12b84f 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -50,10 +50,10 @@ impl pallet_balances::Config for Test { type MaxReserves = (); type ReserveIdentifier = [u8; 8]; type WeightInfo = (); - type FreezeIdentifier = (); - type MaxHolds = ConstU32<0>; - type MaxFreezes = ConstU32<0>; + type FreezeIdentifier = RuntimeFreezeReason; + type MaxFreezes = ConstU32<1>; type RuntimeHoldReason = (); + type MaxHolds = ConstU32<0>; } pub struct EnsureAliceOrBob; @@ -99,6 +99,8 @@ impl Config for Test { type WeightInfo = (); type MaxReleaseSchedules = ConstU32<50>; type BlockNumberProvider = MockBlockNumberProvider; + type RuntimeFreezeReason = RuntimeFreezeReason; + type Balance = Balance; } type Block = frame_system::mocking::MockBlockU32; @@ -107,7 +109,7 @@ construct_runtime!( pub enum Test { System: frame_system::{Pallet, Call, Storage, Config, Event}, - TimeRelease: pallet_time_release::{Pallet, Storage, Call, Event, Config}, + TimeRelease: pallet_time_release::{Pallet, Storage, Call, Event, Config, FreezeReason}, PalletBalances: pallet_balances::{Pallet, Call, Storage, Config, Event}, } ); diff --git a/pallets/time-release/src/tests.rs b/pallets/time-release/src/tests.rs index 6b7df0fae3..44dc86804f 100644 --- a/pallets/time-release/src/tests.rs +++ b/pallets/time-release/src/tests.rs @@ -1,9 +1,16 @@ //! Unit tests for the time-release module. use super::*; use chrono::{DateTime, Days, Duration, TimeZone, Utc}; -use frame_support::{assert_noop, assert_ok, error::BadOrigin, traits::Imbalance}; +use frame_support::{ + assert_noop, assert_ok, + error::BadOrigin, + traits::{ + fungible::{Inspect, InspectFreeze}, + tokens::Fortitude, + Currency, WithdrawReasons, + }, +}; use mock::*; -use pallet_balances::{BalanceLock, Reasons}; use sp_runtime::{traits::Dispatchable, SaturatedConversion, TokenError}; #[test] @@ -113,8 +120,8 @@ fn add_new_release_schedule_merges_with_current_locked_balance_and_until() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, another_schedule)); assert_eq!( - PalletBalances::locks(&BOB).get(0), - Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 17u64, reasons: Reasons::All }) + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 17u64 ); }); } @@ -218,10 +225,13 @@ fn claim_works() { assert!(!ReleaseSchedules::::contains_key(BOB)); assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(BOB), ALICE, 10)); // all used up - assert_eq!(PalletBalances::free_balance(BOB), 0); + assert_eq!(::Currency::balance(&BOB), 0); // no locks anymore - assert_eq!(PalletBalances::locks(&BOB), vec![]); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); }); } @@ -235,8 +245,8 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); assert_eq!( - PalletBalances::locks(&BOB).get(0), - Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 20u64, reasons: Reasons::All }) + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 20u64 ); assert!(ReleaseSchedules::::contains_key(&BOB)); @@ -245,7 +255,10 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); // no locks anymore - assert_eq!(PalletBalances::locks(&BOB), vec![]); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); assert!(!ReleaseSchedules::::contains_key(&BOB)); }); } @@ -276,12 +289,15 @@ fn update_release_schedules_works() { // empty release schedules cleanup the storage and unlock the fund assert!(ReleaseSchedules::::contains_key(BOB)); assert_eq!( - PalletBalances::locks(&BOB).get(0), - Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 10u64, reasons: Reasons::All }) + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 10u64 ); assert_ok!(TimeRelease::update_release_schedules(RuntimeOrigin::root(), BOB, vec![])); assert!(!ReleaseSchedules::::contains_key(BOB)); - assert_eq!(PalletBalances::locks(&BOB), vec![]); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); }); } @@ -289,7 +305,8 @@ fn update_release_schedules_works() { fn update_release_schedules_fails_if_unexpected_existing_locks() { ExtBuilder::build().execute_with(|| { assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(ALICE), BOB, 1)); - PalletBalances::set_lock(*b"prelocks", &BOB, 0u64, WithdrawReasons::all()); + let _ = + ::Currency::set_freeze(&FreezeReason::TimeReleased.into(), &BOB, 0u64); }); } @@ -330,7 +347,10 @@ fn multiple_release_schedule_claim_works() { assert!(!ReleaseSchedules::::contains_key(&BOB)); - assert_eq!(PalletBalances::locks(&BOB), vec![]); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); }); } @@ -380,19 +400,25 @@ fn cliff_release_works() { per_period: VESTING_AMOUNT, }; - let balance_lock = - BalanceLock { id: RELEASE_LOCK_ID, amount: VESTING_AMOUNT, reasons: Reasons::All }; - - assert_eq!(PalletBalances::free_balance(BOB), 0); + assert_eq!(::Currency::balance(&BOB), 0); assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, cliff_schedule)); - assert_eq!(PalletBalances::free_balance(BOB), VESTING_AMOUNT); - assert_eq!(PalletBalances::locks(&BOB), vec![balance_lock.clone()]); + assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + VESTING_AMOUNT + ); for i in 1..VESTING_PERIOD { MockBlockNumberProvider::set(i); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!(PalletBalances::free_balance(BOB), VESTING_AMOUNT); - assert_eq!(PalletBalances::locks(&BOB), vec![balance_lock.clone()]); + assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); + assert_eq!( + ::Currency::balance_frozen( + &FreezeReason::TimeReleased.into(), + &BOB + ), + VESTING_AMOUNT + ); assert_noop!( PalletBalances::transfer_allow_death( RuntimeOrigin::signed(BOB), @@ -405,7 +431,10 @@ fn cliff_release_works() { MockBlockNumberProvider::set(VESTING_PERIOD); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert!(PalletBalances::locks(&BOB).is_empty()); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); assert_ok!(PalletBalances::transfer_allow_death( RuntimeOrigin::signed(BOB), CHARLIE, @@ -454,19 +483,36 @@ fn alice_time_releases_schedule() { // Bob starts with zero balance and zero locks. assert_eq!(get_balance::(&BOB), 0); - assert!(PalletBalances::locks(&BOB).is_empty()); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); // Time release transfer is initiated by Alice to Bob. As a result, Bobs free-balance // increases by the total amount scheduled to be time-released. // However, it cannot spent because a lock is put on the balance. assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, schedule)); assert_eq!(get_balance::(&BOB), 24_996); - assert_eq!(PalletBalances::locks(&BOB).len(), 1usize); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 24996 + ); + assert_eq!( + ::Currency::reducible_balance( + &BOB, + Preservation::Expendable, + Fortitude::Polite + ), + 0 + ); // Bob naively attempts to claim the transfer before the scheduled release date // and nothing happens because the schedule release has yet to start. assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, 24_996); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 24_996 + ); let time_release_transfer_data: Vec<(DateTime, _)> = time_release_transfers_data::(); @@ -494,7 +540,10 @@ fn alice_time_releases_schedule() { // Doing a claim does not do anything assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); // Since the first issuance the total amount locked increases by the new transfers: 24_996; - assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, total_locked); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + total_locked + ); let july_2024_sept_2024: Vec> = vec![ Utc.with_ymd_and_hms(2024, 7, 1, 0, 0, 0).unwrap(), @@ -509,7 +558,13 @@ fn alice_time_releases_schedule() { MockBlockNumberProvider::set(date_to_approximate_block_number(month.clone()).into()); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); total_locked -= 4_166 as u64; - assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, total_locked); + assert_eq!( + ::Currency::balance_frozen( + &FreezeReason::TimeReleased.into(), + &BOB + ), + total_locked + ); } // quarter-6: time-release transfer AND monthly claim @@ -530,7 +585,10 @@ fn alice_time_releases_schedule() { // new transfer_total - one_month_of_time_release total_locked += total_transfered; total_locked -= 4_166; - assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, total_locked); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + total_locked + ); // quarter-7-12: time-release transfer AND monthly claim let jan_2025_to_april_2026_quarterly_data = &time_release_transfer_data[6..]; @@ -557,18 +615,23 @@ fn alice_time_releases_schedule() { .into(), ); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!(PalletBalances::locks(&BOB).first(), None); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + 0 + ); }); } fn get_balance(who: &T::AccountId) -> BalanceOf { - T::Currency::free_balance(who) + T::Currency::balance(who) } fn set_balance(who: &T::AccountId, balance: BalanceOf) { - let deposit_result = T::Currency::deposit_creating(who, balance.saturated_into()); - let actual_deposit = deposit_result.peek(); - assert_eq!(balance, actual_deposit); + let _ = T::Currency::mint_into(&who, balance.saturated_into()); + assert_eq!( + T::Currency::balance(who).saturated_into::(), + balance.saturated_into::() + 100u64 + ); } fn build_time_release_schedule( diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index cbc24f690e..5f3a91aa03 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -468,6 +468,7 @@ pub type MaxReleaseSchedules = ConstU32<{ MAX_RELEASE_SCHEDULES }>; // the descriptions of these configs. impl pallet_time_release::Config for Runtime { type RuntimeEvent = RuntimeEvent; + type Balance = Balance; type Currency = Balances; type MinReleaseTransfer = MinReleaseTransfer; type TransferOrigin = EnsureSigned; @@ -477,6 +478,7 @@ impl pallet_time_release::Config for Runtime { type BlockNumberProvider = RelaychainDataProvider; #[cfg(feature = "frequency-no-relay")] type BlockNumberProvider = System; + type RuntimeFreezeReason = RuntimeFreezeReason; } // See https://paritytech.github.io/substrate/master/pallet_timestamp/index.html for @@ -1051,7 +1053,7 @@ construct_runtime!( Multisig: pallet_multisig::{Pallet, Call, Storage, Event} = 30, // FRQC Update - TimeRelease: pallet_time_release::{Pallet, Call, Storage, Event, Config} = 40, + TimeRelease: pallet_time_release::{Pallet, Call, Storage, Event, Config, FreezeReason} = 40, // Frequency related pallets Msa: pallet_msa::{Pallet, Call, Storage, Event} = 60, From 02f57a0b7b5718b13b2d8d89aeea77bc638c819e Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Fri, 17 Nov 2023 16:50:22 -0700 Subject: [PATCH 08/75] fix: time-release runtime-benchmarks errors --- pallets/time-release/src/benchmarking.rs | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/pallets/time-release/src/benchmarking.rs b/pallets/time-release/src/benchmarking.rs index 685d0bcb37..dfc25d4864 100644 --- a/pallets/time-release/src/benchmarking.rs +++ b/pallets/time-release/src/benchmarking.rs @@ -4,7 +4,6 @@ use super::*; use crate::Pallet as TimeReleasePallet; use frame_benchmarking::{account, benchmarks, whitelist_account, whitelisted_caller}; -use frame_support::traits::{Currency, Imbalance}; use frame_system::{pallet_prelude::BlockNumberFor, RawOrigin}; use sp_runtime::{traits::TrailingZeroInput, SaturatedConversion}; use sp_std::prelude::*; @@ -16,10 +15,13 @@ pub type Schedule = ReleaseSchedule, BalanceOf>; const SEED: u32 = 0; +// TODO: this function is duplicated in pallets/time-release/src/mock.rs fn set_balance(who: &T::AccountId, balance: BalanceOf) { - let deposit_result = T::Currency::deposit_creating(who, balance.saturated_into()); - let actual_deposit = deposit_result.peek(); - assert_eq!(balance, actual_deposit); + let _ = T::Currency::mint_into(&who, balance.saturated_into()); + assert_eq!( + T::Currency::balance(who).saturated_into::(), + balance.saturated_into::() + 100u64 + ); } fn lookup_of_account( @@ -76,7 +78,7 @@ benchmarks! { }: _(RawOrigin::Signed(to.clone())) verify { assert_eq!( - T::Currency::free_balance(&to), + T::Currency::balance(&to), schedule.total_amount().unwrap() * BalanceOf::::from(i) , ); } @@ -103,7 +105,7 @@ benchmarks! { }: _(RawOrigin::Root, to_lookup, schedules) verify { assert_eq!( - T::Currency::free_balance(&to), + T::Currency::balance(&to), schedule.total_amount().unwrap() * BalanceOf::::from(i) ); } From 225b3456f37abf2bc985fbf90c53cbb645fb2dd4 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 20 Nov 2023 14:27:31 -0700 Subject: [PATCH 09/75] fix: update comments; rename FreezeReason::TimeReleased --- pallets/capacity/src/lib.rs | 4 ++-- pallets/time-release/src/lib.rs | 12 +++++------ pallets/time-release/src/tests.rs | 36 +++++++++++++++---------------- 3 files changed, 25 insertions(+), 27 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 6cd02d2d95..07cd7e9a15 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -99,7 +99,7 @@ pub mod pallet { /// A reason for freezing funds. #[pallet::composite_enum] pub enum FreezeReason { - /// The account is staked. + /// The account has staked tokens to the Frequency network. #[codec(index = 0)] Staked, } @@ -115,7 +115,7 @@ pub mod pallet { /// Weight information for extrinsics in this pallet. type WeightInfo: WeightInfo; - /// Function that allows a balance to be locked. + /// Functions that allow a fungible balance to be changed or frozen. type Currency: MutateFreeze + Mutate + InspectFreeze diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index ece108e569..593cf18e0c 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -92,11 +92,9 @@ pub mod module { /// A reason for freezing funds. #[pallet::composite_enum] pub enum FreezeReason { - /// The account is staked. + /// Funds are currently locked and are not yet liquid. #[codec(index = 0)] - Staked, - /// An account with time released assets. - TimeReleased, + NotYetVested, } #[pallet::config] pub trait Config: frame_system::Config { @@ -230,7 +228,7 @@ pub mod module { ); let _ = T::Currency::set_freeze( - &FreezeReason::TimeReleased.into(), + &FreezeReason::NotYetVested.into(), who, total_amount, ); @@ -444,11 +442,11 @@ impl Pallet { } fn update_lock(who: &T::AccountId, locked: BalanceOf) { - let _ = T::Currency::set_freeze(&FreezeReason::TimeReleased.into(), who, locked); + let _ = T::Currency::set_freeze(&FreezeReason::NotYetVested.into(), who, locked); } fn delete_lock(who: &T::AccountId) { - let _ = T::Currency::thaw(&FreezeReason::TimeReleased.into(), who); + let _ = T::Currency::thaw(&FreezeReason::NotYetVested.into(), who); } fn set_schedules_for( diff --git a/pallets/time-release/src/tests.rs b/pallets/time-release/src/tests.rs index 44dc86804f..13b1a0f7fe 100644 --- a/pallets/time-release/src/tests.rs +++ b/pallets/time-release/src/tests.rs @@ -120,7 +120,7 @@ fn add_new_release_schedule_merges_with_current_locked_balance_and_until() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, another_schedule)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 17u64 ); }); @@ -229,7 +229,7 @@ fn claim_works() { // no locks anymore assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); }); @@ -245,7 +245,7 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 20u64 ); assert!(ReleaseSchedules::::contains_key(&BOB)); @@ -256,7 +256,7 @@ fn claim_for_works() { // no locks anymore assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); assert!(!ReleaseSchedules::::contains_key(&BOB)); @@ -289,13 +289,13 @@ fn update_release_schedules_works() { // empty release schedules cleanup the storage and unlock the fund assert!(ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 10u64 ); assert_ok!(TimeRelease::update_release_schedules(RuntimeOrigin::root(), BOB, vec![])); assert!(!ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); }); @@ -306,7 +306,7 @@ fn update_release_schedules_fails_if_unexpected_existing_locks() { ExtBuilder::build().execute_with(|| { assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(ALICE), BOB, 1)); let _ = - ::Currency::set_freeze(&FreezeReason::TimeReleased.into(), &BOB, 0u64); + ::Currency::set_freeze(&FreezeReason::NotYetVested.into(), &BOB, 0u64); }); } @@ -348,7 +348,7 @@ fn multiple_release_schedule_claim_works() { assert!(!ReleaseSchedules::::contains_key(&BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); }); @@ -404,7 +404,7 @@ fn cliff_release_works() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, cliff_schedule)); assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), VESTING_AMOUNT ); @@ -414,7 +414,7 @@ fn cliff_release_works() { assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); assert_eq!( ::Currency::balance_frozen( - &FreezeReason::TimeReleased.into(), + &FreezeReason::NotYetVested.into(), &BOB ), VESTING_AMOUNT @@ -432,7 +432,7 @@ fn cliff_release_works() { MockBlockNumberProvider::set(VESTING_PERIOD); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); assert_ok!(PalletBalances::transfer_allow_death( @@ -484,7 +484,7 @@ fn alice_time_releases_schedule() { // Bob starts with zero balance and zero locks. assert_eq!(get_balance::(&BOB), 0); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); @@ -494,7 +494,7 @@ fn alice_time_releases_schedule() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, schedule)); assert_eq!(get_balance::(&BOB), 24_996); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 24996 ); assert_eq!( @@ -510,7 +510,7 @@ fn alice_time_releases_schedule() { // and nothing happens because the schedule release has yet to start. assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 24_996 ); @@ -541,7 +541,7 @@ fn alice_time_releases_schedule() { assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); // Since the first issuance the total amount locked increases by the new transfers: 24_996; assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), total_locked ); @@ -560,7 +560,7 @@ fn alice_time_releases_schedule() { total_locked -= 4_166 as u64; assert_eq!( ::Currency::balance_frozen( - &FreezeReason::TimeReleased.into(), + &FreezeReason::NotYetVested.into(), &BOB ), total_locked @@ -586,7 +586,7 @@ fn alice_time_releases_schedule() { total_locked += total_transfered; total_locked -= 4_166; assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), total_locked ); @@ -616,7 +616,7 @@ fn alice_time_releases_schedule() { ); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleased.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), 0 ); }); From 57d7d949a7b28a3c3e2bec231025be4483afa584 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 21 Nov 2023 08:51:10 -0700 Subject: [PATCH 10/75] fix: enum should be the same; updates; --- pallets/capacity/src/lib.rs | 2 ++ pallets/frequency-tx-payment/src/lib.rs | 5 ++++- pallets/frequency-tx-payment/src/payment.rs | 6 +++--- pallets/frequency-tx-payment/src/tests/mock.rs | 5 +++-- pallets/time-release/src/lib.rs | 5 ++++- pallets/time-release/src/mock.rs | 2 +- runtime/frequency/src/lib.rs | 7 ++++--- 7 files changed, 21 insertions(+), 11 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 07cd7e9a15..463d23baa2 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -102,6 +102,8 @@ pub mod pallet { /// The account has staked tokens to the Frequency network. #[codec(index = 0)] Staked, + /// Funds are currently locked and are not yet liquid. + NotYetVested, } #[pallet::config] diff --git a/pallets/frequency-tx-payment/src/lib.rs b/pallets/frequency-tx-payment/src/lib.rs index 14b90cd066..ba7d6563a7 100644 --- a/pallets/frequency-tx-payment/src/lib.rs +++ b/pallets/frequency-tx-payment/src/lib.rs @@ -26,7 +26,7 @@ use frame_support::{ dispatch::{DispatchInfo, GetDispatchInfo, PostDispatchInfo}, pallet_prelude::*, - traits::{Currency, IsSubType, IsType}, + traits::{IsSubType, IsType, fungible::Inspect as InspectFungible}, weights::{Weight, WeightToFee}, DefaultNoBound, }; @@ -161,6 +161,9 @@ pub mod pallet { + IsSubType> + IsType<::RuntimeCall>; + /// Functions that allow a fungible balance to be changed or frozen. + type Currency: InspectFungible; + /// The type that replenishes and keeps capacity balances. type Capacity: Replenishable + Nontransferable; diff --git a/pallets/frequency-tx-payment/src/payment.rs b/pallets/frequency-tx-payment/src/payment.rs index a0ce583042..1a6b827610 100644 --- a/pallets/frequency-tx-payment/src/payment.rs +++ b/pallets/frequency-tx-payment/src/payment.rs @@ -1,5 +1,5 @@ use common_primitives::msa::MsaValidator; -use frame_support::traits::tokens::Balance; +use frame_support::traits::tokens::{Balance, fungible::Inspect as InspectFungible}; use sp_std::marker::PhantomData; use super::*; @@ -23,7 +23,7 @@ pub struct CapacityAdapter(PhantomData<(Curr, Msa)>); impl OnChargeCapacityTransaction for CapacityAdapter where T: Config, - Curr: Currency<::AccountId>, + Curr: InspectFungible<::AccountId>, Msa: MsaValidator::AccountId>, BalanceOf: Send + Sync + FixedPointOperand + IsType> + MaxEncodedLen, { @@ -36,7 +36,7 @@ where fee: Self::Balance, ) -> Result { ensure!( - Curr::free_balance(key) >= Curr::minimum_balance(), + Curr::balance(key) >= Curr::minimum_balance(), TransactionValidityError::Invalid(InvalidTransaction::Payment) ); diff --git a/pallets/frequency-tx-payment/src/tests/mock.rs b/pallets/frequency-tx-payment/src/tests/mock.rs index 83a1befab8..168841f93b 100644 --- a/pallets/frequency-tx-payment/src/tests/mock.rs +++ b/pallets/frequency-tx-payment/src/tests/mock.rs @@ -33,7 +33,7 @@ frame_support::construct_runtime!( System: frame_system::{Pallet, Call, Config, Storage, Event}, Balances: pallet_balances::{Pallet, Call, Storage, Config, Event}, Msa: pallet_msa::{Pallet, Call, Storage, Event}, - Capacity: pallet_capacity::{Pallet, Call, Storage, Event}, + Capacity: pallet_capacity::{Pallet, Call, Storage, Event, FreezeReason}, TransactionPayment: pallet_transaction_payment::{Pallet, Storage, Event}, FrequencyTxPayment: pallet_frequency_tx_payment::{Pallet, Call, Event}, Utility: pallet_utility::{Pallet, Call, Storage, Event}, @@ -202,7 +202,7 @@ parameter_types! { impl pallet_capacity::Config for Test { type RuntimeEvent = RuntimeEvent; type WeightInfo = (); - type Currency = pallet_balances::Pallet; + type Currency = Self::Currency; type TargetValidator = (); // In test, this must be >= Token:Capacity ratio since unit is plancks type MinimumStakingAmount = ConstU64<10>; @@ -216,6 +216,7 @@ impl pallet_capacity::Config for Test { type MaxEpochLength = ConstU32<100>; type EpochNumber = u32; type CapacityPerToken = TestCapacityPerToken; + type RuntimeFreezeReason = RuntimeFreezeReason; } use pallet_balances::Call as BalancesCall; diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 593cf18e0c..83b49b9923 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -92,10 +92,13 @@ pub mod module { /// A reason for freezing funds. #[pallet::composite_enum] pub enum FreezeReason { - /// Funds are currently locked and are not yet liquid. #[codec(index = 0)] + /// Funds are staked. + Staked, + /// Funds are currently locked and are not yet liquid. NotYetVested, } + // use crate::pallet_capacity::FreezeReason; #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index a55c12b84f..1346f10865 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -93,7 +93,7 @@ impl BlockNumberProvider for MockBlockNumberProvider { impl Config for Test { type RuntimeEvent = RuntimeEvent; - type Currency = PalletBalances; + type Currency = Self::Currency; type MinReleaseTransfer = ConstU64<5>; type TransferOrigin = EnsureAliceOrBob; type WeightInfo = (); diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 5f3a91aa03..1d6113dd44 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -261,7 +261,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("frequency"), impl_name: create_runtime_str!("frequency"), authoring_version: 1, - spec_version: 64, + spec_version: 65, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, @@ -275,7 +275,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("frequency-rococo"), impl_name: create_runtime_str!("frequency"), authoring_version: 1, - spec_version: 64, + spec_version: 65, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, @@ -407,7 +407,7 @@ impl pallet_capacity::Config for Runtime { type RuntimeEvent = RuntimeEvent; type WeightInfo = pallet_capacity::weights::SubstrateWeight; // REVIEW: Change Currency->Fungible - type Currency = Balances; + type Currency = Self::Currency; type MinimumStakingAmount = CapacityMinimumStakingAmount; type MinimumTokenBalance = CapacityMinimumTokenBalance; type TargetValidator = Msa; @@ -794,6 +794,7 @@ impl GetStableWeight for CapacityEligibleCalls { impl pallet_frequency_tx_payment::Config for Runtime { type RuntimeEvent = RuntimeEvent; type RuntimeCall = RuntimeCall; + type Currency = Self::Currency; type Capacity = Capacity; type WeightInfo = pallet_frequency_tx_payment::weights::SubstrateWeight; type CapacityCalls = CapacityEligibleCalls; From 86c6e74a76851460abba87445a7d5b10d369d686 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 21 Nov 2023 12:05:13 -0700 Subject: [PATCH 11/75] fix: update cargo dependencies for common-runtime; --- pallets/capacity/Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pallets/capacity/Cargo.toml b/pallets/capacity/Cargo.toml index 8550f1de76..da119972ea 100644 --- a/pallets/capacity/Cargo.toml +++ b/pallets/capacity/Cargo.toml @@ -39,6 +39,7 @@ default = ["std"] runtime-benchmarks = [ "frame-benchmarking/runtime-benchmarks", "common-primitives/runtime-benchmarks", + "common-runtime/runtime-benchmarks", "pallet-msa/runtime-benchmarks", ] std = [ From bf228b5ef927b3a78a1f0f6bc2f7b624f5ce097e Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 21 Nov 2023 12:39:44 -0700 Subject: [PATCH 12/75] fix: Currency trait was incorrect; --- pallets/frequency-tx-payment/src/tests/mock.rs | 2 +- pallets/time-release/Cargo.toml | 1 + pallets/time-release/src/mock.rs | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/pallets/frequency-tx-payment/src/tests/mock.rs b/pallets/frequency-tx-payment/src/tests/mock.rs index 168841f93b..6c967cff93 100644 --- a/pallets/frequency-tx-payment/src/tests/mock.rs +++ b/pallets/frequency-tx-payment/src/tests/mock.rs @@ -202,7 +202,7 @@ parameter_types! { impl pallet_capacity::Config for Test { type RuntimeEvent = RuntimeEvent; type WeightInfo = (); - type Currency = Self::Currency; + type Currency = pallet_balances::Pallet; type TargetValidator = (); // In test, this must be >= Token:Capacity ratio since unit is plancks type MinimumStakingAmount = ConstU64<10>; diff --git a/pallets/time-release/Cargo.toml b/pallets/time-release/Cargo.toml index df6a05c545..7e209709d8 100644 --- a/pallets/time-release/Cargo.toml +++ b/pallets/time-release/Cargo.toml @@ -42,6 +42,7 @@ std = [ "sp-std/std", "frame-benchmarking/std", "common-primitives/std", + "pallet-balances/std", ] runtime-benchmarks = [ "frame-support/runtime-benchmarks", diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index 1346f10865..a55c12b84f 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -93,7 +93,7 @@ impl BlockNumberProvider for MockBlockNumberProvider { impl Config for Test { type RuntimeEvent = RuntimeEvent; - type Currency = Self::Currency; + type Currency = PalletBalances; type MinReleaseTransfer = ConstU64<5>; type TransferOrigin = EnsureAliceOrBob; type WeightInfo = (); From 72feddc64cde2e843c7b85f69a460c99a8af28ea Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 21 Nov 2023 13:19:51 -0700 Subject: [PATCH 13/75] fix: set_balance logic error; --- pallets/time-release/src/benchmarking.rs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/pallets/time-release/src/benchmarking.rs b/pallets/time-release/src/benchmarking.rs index dfc25d4864..7dafbc1a44 100644 --- a/pallets/time-release/src/benchmarking.rs +++ b/pallets/time-release/src/benchmarking.rs @@ -15,13 +15,9 @@ pub type Schedule = ReleaseSchedule, BalanceOf>; const SEED: u32 = 0; -// TODO: this function is duplicated in pallets/time-release/src/mock.rs fn set_balance(who: &T::AccountId, balance: BalanceOf) { - let _ = T::Currency::mint_into(&who, balance.saturated_into()); - assert_eq!( - T::Currency::balance(who).saturated_into::(), - balance.saturated_into::() + 100u64 - ); + let actual_deposit = T::Currency::mint_into(&who, balance.saturated_into()); + assert_eq!(balance, actual_deposit.unwrap()); } fn lookup_of_account( From 1442a12dfec4186446233aef7e422ce704ea1785 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 21 Nov 2023 14:44:16 -0700 Subject: [PATCH 14/75] fix: revert new Currency type; set FreezeIdentifier in mock; --- pallets/frequency-tx-payment/src/lib.rs | 5 +---- pallets/frequency-tx-payment/src/tests/mock.rs | 2 +- runtime/frequency/src/lib.rs | 4 +--- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/pallets/frequency-tx-payment/src/lib.rs b/pallets/frequency-tx-payment/src/lib.rs index ba7d6563a7..f233dec315 100644 --- a/pallets/frequency-tx-payment/src/lib.rs +++ b/pallets/frequency-tx-payment/src/lib.rs @@ -26,7 +26,7 @@ use frame_support::{ dispatch::{DispatchInfo, GetDispatchInfo, PostDispatchInfo}, pallet_prelude::*, - traits::{IsSubType, IsType, fungible::Inspect as InspectFungible}, + traits::{IsSubType, IsType}, weights::{Weight, WeightToFee}, DefaultNoBound, }; @@ -161,9 +161,6 @@ pub mod pallet { + IsSubType> + IsType<::RuntimeCall>; - /// Functions that allow a fungible balance to be changed or frozen. - type Currency: InspectFungible; - /// The type that replenishes and keeps capacity balances. type Capacity: Replenishable + Nontransferable; diff --git a/pallets/frequency-tx-payment/src/tests/mock.rs b/pallets/frequency-tx-payment/src/tests/mock.rs index 6c967cff93..e0a475a557 100644 --- a/pallets/frequency-tx-payment/src/tests/mock.rs +++ b/pallets/frequency-tx-payment/src/tests/mock.rs @@ -91,7 +91,7 @@ impl pallet_balances::Config for Test { type ExistentialDeposit = ConstU64<1>; type AccountStore = System; type MaxReserves = (); - type FreezeIdentifier = (); + type FreezeIdentifier = RuntimeFreezeReason; type MaxFreezes = ConstU32<0>; type MaxHolds = ConstU32<0>; type RuntimeHoldReason = (); diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 1d6113dd44..bd0572f23b 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -406,8 +406,7 @@ impl pallet_msa::Config for Runtime { impl pallet_capacity::Config for Runtime { type RuntimeEvent = RuntimeEvent; type WeightInfo = pallet_capacity::weights::SubstrateWeight; - // REVIEW: Change Currency->Fungible - type Currency = Self::Currency; + type Currency = Balances; type MinimumStakingAmount = CapacityMinimumStakingAmount; type MinimumTokenBalance = CapacityMinimumTokenBalance; type TargetValidator = Msa; @@ -794,7 +793,6 @@ impl GetStableWeight for CapacityEligibleCalls { impl pallet_frequency_tx_payment::Config for Runtime { type RuntimeEvent = RuntimeEvent; type RuntimeCall = RuntimeCall; - type Currency = Self::Currency; type Capacity = Capacity; type WeightInfo = pallet_frequency_tx_payment::weights::SubstrateWeight; type CapacityCalls = CapacityEligibleCalls; From cda4bc464e076fa8cf5f4d6cfeec30c468f8a99a Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 21 Nov 2023 14:48:52 -0700 Subject: [PATCH 15/75] fix: lints --- pallets/frequency-tx-payment/src/payment.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pallets/frequency-tx-payment/src/payment.rs b/pallets/frequency-tx-payment/src/payment.rs index 1a6b827610..2ccbd99260 100644 --- a/pallets/frequency-tx-payment/src/payment.rs +++ b/pallets/frequency-tx-payment/src/payment.rs @@ -1,5 +1,5 @@ use common_primitives::msa::MsaValidator; -use frame_support::traits::tokens::{Balance, fungible::Inspect as InspectFungible}; +use frame_support::traits::tokens::{fungible::Inspect as InspectFungible, Balance}; use sp_std::marker::PhantomData; use super::*; From d63a55432caf0c078307d437addf61cd63c02323 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 22 Nov 2023 14:01:03 -0800 Subject: [PATCH 16/75] we are erroring silently - Number of freezes exceed MaxFreezes --- e2e/capacity/staking.test.ts | 3 ++- e2e/package-lock.json | 2 +- pallets/capacity/src/lib.rs | 17 ++++++++++------- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/e2e/capacity/staking.test.ts b/e2e/capacity/staking.test.ts index 9766ae576c..ebdb5c11fa 100644 --- a/e2e/capacity/staking.test.ts +++ b/e2e/capacity/staking.test.ts @@ -23,7 +23,7 @@ const tokenMinStake: bigint = 1n * CENTS; const capacityMin: bigint = tokenMinStake / 50n; const fundingSource = getFundingSource('capacity-staking'); -describe('Capacity Staking Tests', function () { +describe.only('Capacity Staking Tests', function () { // The frozen balance is initialized and tracked throughout the staking end to end tests // to accommodate for the fact that withdrawing unstaked token tests are not executed // against a relay chain. Since the length of time to wait for an epoch period to roll over could @@ -45,6 +45,7 @@ describe('Capacity Staking Tests', function () { // Confirm that the tokens were locked in the stakeKeys account using the query API const stakedAcctInfo = await ExtrinsicHelper.getAccountInfo(stakeKeys.address); + console.log("stakedAcctInfo.data.frozen", stakedAcctInfo.data.frozen.toHuman()); assert.equal( stakedAcctInfo.data.frozen, tokenMinStake, diff --git a/e2e/package-lock.json b/e2e/package-lock.json index f2b313a7ce..710887d8ab 100644 --- a/e2e/package-lock.json +++ b/e2e/package-lock.json @@ -260,7 +260,7 @@ "node_modules/@frequency-chain/api-augment": { "version": "0.0.0", "resolved": "file:../js/api-augment/dist/frequency-chain-api-augment-0.0.0.tgz", - "integrity": "sha512-SjELGw36ccBPvWV19CU73HAOU1hiYJfQGqY1G3Qd7MJUuH3EaaB7Qr85dqjKcwIt37L7hYZ29LjddBw9//jRkw==", + "integrity": "sha512-5KaqfY1M25g+JRlCHXEiKpKjimlsGOZPXa1qU/FIW27NKKNMykAw08MpUvukn3RjgOu9khWe8fhxTnCK1lVtiw==", "license": "Apache-2.0", "dependencies": { "@polkadot/api": "^10.9.1", diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 463d23baa2..f1481e96a7 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -370,7 +370,7 @@ pub mod pallet { let amount_withdrawn = staking_account.reap_thawed(current_epoch); ensure!(!amount_withdrawn.is_zero(), Error::::NoUnstakedTokensAvailable); - Self::update_or_delete_staking_account(&staker, &mut staking_account); + Self::update_or_delete_staking_account(&staker, &mut staking_account)?; Self::deposit_event(Event::::StakeWithdrawn { account: staker, amount: amount_withdrawn, @@ -482,7 +482,7 @@ impl Pallet { let mut capacity_details = Self::get_capacity_for(target).unwrap_or_default(); capacity_details.deposit(&amount, &capacity).ok_or(ArithmeticError::Overflow)?; - Self::set_staking_account(&staker, staking_account); + Self::set_staking_account(&staker, staking_account)?; Self::set_target_details_for(&staker, target, target_details); Self::set_capacity_for(target, capacity_details); @@ -490,10 +490,11 @@ impl Pallet { } /// Sets staking account details. - fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) { + fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) -> DispatchResult { let _ = - T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total); + T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total)?; StakingAccountLedger::::insert(staker, staking_account); + Ok(()) } /// Deletes staking account details @@ -506,12 +507,14 @@ impl Pallet { fn update_or_delete_staking_account( staker: &T::AccountId, staking_account: &StakingAccountDetails, - ) { + ) -> DispatchResult { if staking_account.total.is_zero() { Self::delete_staking_account(&staker); } else { - Self::set_staking_account(&staker, &staking_account) + Self::set_staking_account(&staker, &staking_account)?; } + + Ok(()) } /// Sets target account details. @@ -546,7 +549,7 @@ impl Pallet { let unstake_result = staking_account.withdraw(amount, thaw_at)?; - Self::set_staking_account(&unstaker, &staking_account); + Self::set_staking_account(&unstaker, &staking_account)?; Ok(unstake_result) } From 09261a63da14a4f268f23c03a8560a98f2d78e45 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 22 Nov 2023 14:06:12 -0800 Subject: [PATCH 17/75] test pass --- runtime/frequency/src/lib.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index bd0572f23b..6f90e47164 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -510,7 +510,8 @@ impl pallet_balances::Config for Runtime { type MaxReserves = BalancesMaxReserves; type ReserveIdentifier = [u8; 8]; type MaxHolds = ConstU32<0>; - type MaxFreezes = ConstU32<0>; + // TODO: check what this number should be + type MaxFreezes = ConstU32<100>; type RuntimeHoldReason = RuntimeHoldReason; type FreezeIdentifier = RuntimeFreezeReason; } From e855d93844976dbe11f035699eb50a7f7a861e36 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 22 Nov 2023 14:15:48 -0800 Subject: [PATCH 18/75] lint --- pallets/capacity/src/benchmarking.rs | 4 ++-- pallets/capacity/src/lib.rs | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/pallets/capacity/src/benchmarking.rs b/pallets/capacity/src/benchmarking.rs index b85f709734..c40335fd17 100644 --- a/pallets/capacity/src/benchmarking.rs +++ b/pallets/capacity/src/benchmarking.rs @@ -65,7 +65,7 @@ benchmarks! { let new_unlocks: Vec<(u32, u32)> = Vec::from([(50u32, 3u32), (50u32, 5u32)]); assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); - Capacity::::set_staking_account(&caller.clone(), &staking_account); + let _ = Capacity::::set_staking_account(&caller.clone(), &staking_account); CurrentEpoch::::set(T::EpochNumber::from(5u32)); }: _ (RawOrigin::Signed(caller.clone())) @@ -99,7 +99,7 @@ benchmarks! { target_details.deposit(staking_amount, capacity_amount); capacity_details.deposit(&staking_amount, &capacity_amount); - Capacity::::set_staking_account(&caller.clone(), &staking_account); + let _ = Capacity::::set_staking_account(&caller.clone(), &staking_account); Capacity::::set_target_details_for(&caller.clone(), target, target_details); Capacity::::set_capacity_for(target, capacity_details); diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index f1481e96a7..b41371da2b 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -490,7 +490,10 @@ impl Pallet { } /// Sets staking account details. - fn set_staking_account(staker: &T::AccountId, staking_account: &StakingAccountDetails) -> DispatchResult { + fn set_staking_account( + staker: &T::AccountId, + staking_account: &StakingAccountDetails, + ) -> DispatchResult { let _ = T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total)?; StakingAccountLedger::::insert(staker, staking_account); From 6c4e44aa88e22d52a85f484ce91b21bacadb618e Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 27 Nov 2023 09:14:45 -0700 Subject: [PATCH 19/75] fix: remove .only --- e2e/capacity/staking.test.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/e2e/capacity/staking.test.ts b/e2e/capacity/staking.test.ts index ebdb5c11fa..9766ae576c 100644 --- a/e2e/capacity/staking.test.ts +++ b/e2e/capacity/staking.test.ts @@ -23,7 +23,7 @@ const tokenMinStake: bigint = 1n * CENTS; const capacityMin: bigint = tokenMinStake / 50n; const fundingSource = getFundingSource('capacity-staking'); -describe.only('Capacity Staking Tests', function () { +describe('Capacity Staking Tests', function () { // The frozen balance is initialized and tracked throughout the staking end to end tests // to accommodate for the fact that withdrawing unstaked token tests are not executed // against a relay chain. Since the length of time to wait for an epoch period to roll over could @@ -45,7 +45,6 @@ describe.only('Capacity Staking Tests', function () { // Confirm that the tokens were locked in the stakeKeys account using the query API const stakedAcctInfo = await ExtrinsicHelper.getAccountInfo(stakeKeys.address); - console.log("stakedAcctInfo.data.frozen", stakedAcctInfo.data.frozen.toHuman()); assert.equal( stakedAcctInfo.data.frozen, tokenMinStake, From 9079373d31bdd4d3e684b2b17d25b26b574f4c9a Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 27 Nov 2023 14:32:42 -0700 Subject: [PATCH 20/75] fix: coordinate BalancesMaxXXXXX with existing runtime defaults --- pallets/capacity/src/tests/mock.rs | 8 ++++---- pallets/frequency-tx-payment/src/tests/mock.rs | 8 ++++---- pallets/time-release/src/mock.rs | 8 ++++---- runtime/common/src/constants.rs | 2 ++ runtime/frequency/src/lib.rs | 5 ++--- 5 files changed, 16 insertions(+), 15 deletions(-) diff --git a/pallets/capacity/src/tests/mock.rs b/pallets/capacity/src/tests/mock.rs index c6502ecc0d..daeb995b10 100644 --- a/pallets/capacity/src/tests/mock.rs +++ b/pallets/capacity/src/tests/mock.rs @@ -55,9 +55,7 @@ impl frame_system::Config for Test { } impl pallet_balances::Config for Test { - type MaxReserves = (); type ReserveIdentifier = [u8; 8]; - type MaxLocks = ConstU32<10>; type Balance = u64; type RuntimeEvent = RuntimeEvent; type DustRemoval = (); @@ -65,9 +63,11 @@ impl pallet_balances::Config for Test { type AccountStore = System; type WeightInfo = (); type FreezeIdentifier = RuntimeFreezeReason; - type MaxFreezes = ConstU32<1>; + type MaxLocks = ConstU32<50>; + type MaxReserves = ConstU32<50>; + type MaxFreezes = ConstU32<50>; + type MaxHolds = ConstU32<50>; type RuntimeHoldReason = (); - type MaxHolds = ConstU32<0>; } pub type MaxSchemaGrantsPerDelegation = ConstU32<30>; diff --git a/pallets/frequency-tx-payment/src/tests/mock.rs b/pallets/frequency-tx-payment/src/tests/mock.rs index e0a475a557..1d28d74cfc 100644 --- a/pallets/frequency-tx-payment/src/tests/mock.rs +++ b/pallets/frequency-tx-payment/src/tests/mock.rs @@ -85,15 +85,15 @@ impl pallet_balances::Config for Test { type DustRemoval = (); type RuntimeEvent = RuntimeEvent; type Balance = u64; - type MaxLocks = (); type WeightInfo = (); type ReserveIdentifier = [u8; 8]; type ExistentialDeposit = ConstU64<1>; type AccountStore = System; - type MaxReserves = (); + type MaxLocks = ConstU32<50>; + type MaxReserves = ConstU32<50>; + type MaxFreezes = ConstU32<50>; + type MaxHolds = ConstU32<50>; type FreezeIdentifier = RuntimeFreezeReason; - type MaxFreezes = ConstU32<0>; - type MaxHolds = ConstU32<0>; type RuntimeHoldReason = (); } diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index a55c12b84f..2e9d89f7cc 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -46,14 +46,14 @@ impl pallet_balances::Config for Test { type RuntimeEvent = RuntimeEvent; type ExistentialDeposit = ConstU64<1>; type AccountStore = frame_system::Pallet; - type MaxLocks = (); - type MaxReserves = (); type ReserveIdentifier = [u8; 8]; type WeightInfo = (); type FreezeIdentifier = RuntimeFreezeReason; - type MaxFreezes = ConstU32<1>; + type MaxLocks = ConstU32<50>; + type MaxReserves = ConstU32<50>; + type MaxFreezes = ConstU32<50>; + type MaxHolds = ConstU32<50>; type RuntimeHoldReason = (); - type MaxHolds = ConstU32<0>; } pub struct EnsureAliceOrBob; diff --git a/runtime/common/src/constants.rs b/runtime/common/src/constants.rs index c039b939fb..f884133429 100644 --- a/runtime/common/src/constants.rs +++ b/runtime/common/src/constants.rs @@ -135,6 +135,8 @@ pub type AuthorshipUncleGenerations = ZERO; // --- Balances Pallet --- pub type BalancesMaxLocks = FIFTY; pub type BalancesMaxReserves = FIFTY; +pub type BalancesMaxFreezes = FIFTY; +pub type BalancesMaxHolds = FIFTY; // -end- Balances Pallet --- // --- Scheduler Pallet --- diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 6f90e47164..a8ce27e81b 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -509,9 +509,8 @@ impl pallet_balances::Config for Runtime { type WeightInfo = weights::pallet_balances::SubstrateWeight; type MaxReserves = BalancesMaxReserves; type ReserveIdentifier = [u8; 8]; - type MaxHolds = ConstU32<0>; - // TODO: check what this number should be - type MaxFreezes = ConstU32<100>; + type MaxHolds = BalancesMaxHolds; + type MaxFreezes = BalancesMaxFreezes; type RuntimeHoldReason = RuntimeHoldReason; type FreezeIdentifier = RuntimeFreezeReason; } From 52d5ea4858d0213c4cec90802054ab9327160e96 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 27 Nov 2023 16:11:24 -0700 Subject: [PATCH 21/75] fix: add expect to tests that can fail; cargo update; pass through errors for T::Currency::set_freeze/thaw; --- .cargo-deny.toml | 2 +- Cargo.lock | 1289 +++++++++-------- e2e/package-lock.json | 35 +- pallets/capacity/src/benchmarking.rs | 4 +- pallets/capacity/src/lib.rs | 10 +- pallets/capacity/src/tests/other_tests.rs | 3 +- .../src/tests/withdraw_unstaked_tests.rs | 15 +- 7 files changed, 735 insertions(+), 623 deletions(-) diff --git a/.cargo-deny.toml b/.cargo-deny.toml index 563dc8e7ee..5795d9c0b6 100644 --- a/.cargo-deny.toml +++ b/.cargo-deny.toml @@ -273,7 +273,7 @@ allow-git = [] [sources.allow-org] # 1 or more github.com organizations to allow git sources for -github = ["paritytech", "w3f"] +github = ["paritytech", "w3f", "multiformats"] # 1 or more gitlab.com organizations to allow git sources for # gitlab = [""] # 1 or more bitbucket.org organizations to allow git sources for diff --git a/Cargo.lock b/Cargo.lock index e5ccfe2c8f..e3565139c7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -27,7 +27,7 @@ version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" dependencies = [ - "gimli 0.28.0", + "gimli 0.28.1", ] [[package]] @@ -159,7 +159,7 @@ version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5a824f2aa7e75a0c98c5a504fceb80649e9c35265d44525b5f94de4771a395cd" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", "once_cell", "version_check", ] @@ -171,10 +171,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "91429305e9f0a25f6205c5b8e0d2db09e0708a7a6df0f42212bb56c32c8ac97a" dependencies = [ "cfg-if", - "getrandom 0.2.10", + "getrandom 0.2.11", "once_cell", "version_check", - "zerocopy 0.7.21", + "zerocopy 0.7.26", ] [[package]] @@ -519,9 +519,9 @@ dependencies = [ [[package]] name = "array-bytes" -version = "6.1.0" +version = "6.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b1c5a481ec30a5abd8dfbd94ab5cf1bb4e9a66be7f1b3b322f2f1170c200fd" +checksum = "de17a919934ad8c5cc99a1a74de4e2dab95d6121a8f27f94755ff525b630382c" [[package]] name = "arrayref" @@ -634,17 +634,30 @@ dependencies = [ "futures-core", ] +[[package]] +name = "async-channel" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ca33f4bc4ed1babef42cad36cc1f51fa88be00420404e5b1e80ab1b18f7678c" +dependencies = [ + "concurrent-queue", + "event-listener 4.0.0", + "event-listener-strategy", + "futures-core", + "pin-project-lite 0.2.13", +] + [[package]] name = "async-executor" -version = "1.6.0" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b0c4a4f319e45986f347ee47fef8bf5e81c9abc3f6f58dc2391439f30df65f0" +checksum = "17ae5ebefcc48e7452b4987947920dac9450be1110cadf34d1b8c116bdbaf97c" dependencies = [ - "async-lock", + "async-lock 3.1.2", "async-task", "concurrent-queue", "fastrand 2.0.1", - "futures-lite", + "futures-lite 2.0.1", "slab", ] @@ -654,10 +667,10 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "279cf904654eeebfa37ac9bb1598880884924aab82e290aa65c9e77a0e142e06" dependencies = [ - "async-lock", + "async-lock 2.8.0", "autocfg", "blocking", - "futures-lite", + "futures-lite 1.13.0", ] [[package]] @@ -666,11 +679,11 @@ version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" dependencies = [ - "async-lock", + "async-lock 2.8.0", "autocfg", "cfg-if", "concurrent-queue", - "futures-lite", + "futures-lite 1.13.0", "log", "parking", "polling 2.8.0", @@ -682,22 +695,21 @@ dependencies = [ [[package]] name = "async-io" -version = "2.1.0" +version = "2.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10da8f3146014722c89e7859e1d7bb97873125d7346d10ca642ffab794355828" +checksum = "d6d3b15875ba253d1110c740755e246537483f152fa334f91abd7fe84c88b3ff" dependencies = [ - "async-lock", + "async-lock 3.1.2", "cfg-if", "concurrent-queue", "futures-io", - "futures-lite", + "futures-lite 2.0.1", "parking", - "polling 3.3.0", - "rustix 0.38.21", + "polling 3.3.1", + "rustix 0.38.25", "slab", "tracing", - "waker-fn", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -709,6 +721,17 @@ dependencies = [ "event-listener 2.5.3", ] +[[package]] +name = "async-lock" +version = "3.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dea8b3453dd7cc96711834b75400d671b73e3656975fa68d9f277163b7f7e316" +dependencies = [ + "event-listener 4.0.0", + "event-listener-strategy", + "pin-project-lite 0.2.13", +] + [[package]] name = "async-net" version = "1.8.0" @@ -717,7 +740,7 @@ checksum = "0434b1ed18ce1cf5769b8ac540e33f01fa9471058b5e89da9e06f3c882a8c12f" dependencies = [ "async-io 1.13.0", "blocking", - "futures-lite", + "futures-lite 1.13.0", ] [[package]] @@ -727,13 +750,13 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ea6438ba0a08d81529c69b36700fa2f95837bfe3e776ab39cde9c14d9149da88" dependencies = [ "async-io 1.13.0", - "async-lock", + "async-lock 2.8.0", "async-signal", "blocking", "cfg-if", - "event-listener 3.0.1", - "futures-lite", - "rustix 0.38.21", + "event-listener 3.1.0", + "futures-lite 1.13.0", + "rustix 0.38.25", "windows-sys 0.48.0", ] @@ -745,7 +768,7 @@ checksum = "5fd55a5ba1179988837d24ab4c7cc8ed6efdeff578ede0416b4225a5fca35bd0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -754,13 +777,13 @@ version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e47d90f65a225c4527103a8d747001fc56e375203592b25ad103e1ca13124c5" dependencies = [ - "async-io 2.1.0", - "async-lock", + "async-io 2.2.1", + "async-lock 2.8.0", "atomic-waker", "cfg-if", "futures-core", "futures-io", - "rustix 0.38.21", + "rustix 0.38.25", "signal-hook-registry", "slab", "windows-sys 0.48.0", @@ -780,7 +803,7 @@ checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -910,7 +933,7 @@ dependencies = [ [[package]] name = "binary-merkle-tree" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "hash-db", "log", @@ -943,7 +966,7 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -1096,16 +1119,16 @@ checksum = "8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2cae" [[package]] name = "blocking" -version = "1.4.1" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c36a4d0d48574b3dd360b4b7d95cc651d2b6557b6402848a27d4b228a473e2a" +checksum = "6a37913e8dc4ddcc604f0c6d3bf2887c995153af3611de9e23c352b44c1b9118" dependencies = [ - "async-channel", - "async-lock", + "async-channel 2.1.1", + "async-lock 3.1.2", "async-task", "fastrand 2.0.1", "futures-io", - "futures-lite", + "futures-lite 2.0.1", "piper", "tracing", ] @@ -1148,9 +1171,9 @@ dependencies = [ [[package]] name = "bstr" -version = "1.7.0" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c79ad7fb2dd38f3dabd76b09c6a5a20c038fc0213ef1e9afd30eb777f120f019" +checksum = "542f33a8835a0884b006a0c3df3dadd99c0c3f296ed26c2fdc8028e01ad6230c" dependencies = [ "memchr", "serde", @@ -1223,9 +1246,9 @@ dependencies = [ [[package]] name = "cargo-platform" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12024c4645c97566567129c204f65d5815a8c9aecf30fcbe682b2fe034996d36" +checksum = "e34637b3140142bdf929fb439e8aa4ebad7651ebf7b1080b3930aa16ac1459ff" dependencies = [ "serde", ] @@ -1295,18 +1318,6 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" -[[package]] -name = "chacha20" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c80e5460aa66fe3b91d40bcbdab953a597b60053e34d684ac6903f863b680a6" -dependencies = [ - "cfg-if", - "cipher 0.3.0", - "cpufeatures", - "zeroize", -] - [[package]] name = "chacha20" version = "0.9.1" @@ -1320,14 +1331,14 @@ dependencies = [ [[package]] name = "chacha20poly1305" -version = "0.9.1" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a18446b09be63d457bbec447509e85f662f32952b035ce892290396bc0b0cff5" +checksum = "10cd79432192d1c0f4e1a0fef9527696cc039165d729fb41b3f4f4f354c2dc35" dependencies = [ - "aead 0.4.3", - "chacha20 0.8.2", - "cipher 0.3.0", - "poly1305 0.7.2", + "aead 0.5.2", + "chacha20", + "cipher 0.4.4", + "poly1305", "zeroize", ] @@ -1394,6 +1405,7 @@ checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad" dependencies = [ "crypto-common", "inout", + "zeroize", ] [[package]] @@ -1418,9 +1430,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.4.7" +version = "4.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac495e00dcec98c83465d5ad66c5c4fabd652fd6686e7c6269b117e729a6f17b" +checksum = "46ca43acc1b21c6cc2d1d3129c19e323a613935b5bc28fb3b33b5b2e5fb00030" dependencies = [ "clap_builder", "clap_derive", @@ -1428,9 +1440,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.4.7" +version = "4.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c77ed9a32a62e6ca27175d00d29d05ca32e396ea1eb5fb01d8256b669cec7663" +checksum = "63361bae7eef3771745f02d8d892bec2fee5f6e34af316ba556e7f97a7069ff1" dependencies = [ "anstream", "anstyle", @@ -1447,7 +1459,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -1465,9 +1477,9 @@ dependencies = [ [[package]] name = "coarsetime" -version = "0.1.29" +version = "0.1.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a73ef0d00d14301df35d0f13f5ea32344de6b00837485c358458f1e7f2d27db4" +checksum = "71367d3385c716342014ad17e3d19f7788ae514885a1f4c24f500260fb365e1a" dependencies = [ "libc", "once_cell", @@ -1626,7 +1638,7 @@ version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", "once_cell", "tiny-keccak", ] @@ -1811,9 +1823,9 @@ dependencies = [ [[package]] name = "crc-catalog" -version = "2.2.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cace84e55f07e7301bae1c519df89cdad8cc3cd868413d3fdbdeca9ff3db484" +checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" [[package]] name = "crc32fast" @@ -1887,9 +1899,9 @@ dependencies = [ [[package]] name = "crypto-bigint" -version = "0.5.3" +version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "740fe28e594155f10cfc383984cbefd529d7396050557148f79cb0f621204124" +checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" dependencies = [ "generic-array 0.14.7", "rand_core 0.6.4", @@ -1949,7 +1961,7 @@ dependencies = [ [[package]] name = "cumulus-client-cli" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "clap", "parity-scale-codec", @@ -1965,7 +1977,7 @@ dependencies = [ [[package]] name = "cumulus-client-collator" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cumulus-client-consensus-common", "cumulus-client-network", @@ -1988,7 +2000,7 @@ dependencies = [ [[package]] name = "cumulus-client-consensus-aura" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-client-collator", @@ -2030,7 +2042,7 @@ dependencies = [ [[package]] name = "cumulus-client-consensus-common" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-client-pov-recovery", @@ -2059,7 +2071,7 @@ dependencies = [ [[package]] name = "cumulus-client-consensus-proposer" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "anyhow", "async-trait", @@ -2074,7 +2086,7 @@ dependencies = [ [[package]] name = "cumulus-client-network" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-relay-chain-interface", @@ -2097,7 +2109,7 @@ dependencies = [ [[package]] name = "cumulus-client-pov-recovery" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2121,7 +2133,7 @@ dependencies = [ [[package]] name = "cumulus-client-service" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cumulus-client-cli", "cumulus-client-collator", @@ -2156,7 +2168,7 @@ dependencies = [ [[package]] name = "cumulus-pallet-aura-ext" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cumulus-pallet-parachain-system", "frame-support", @@ -2174,7 +2186,7 @@ dependencies = [ [[package]] name = "cumulus-pallet-parachain-system" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bytes", "cumulus-pallet-parachain-system-proc-macro", @@ -2204,18 +2216,18 @@ dependencies = [ [[package]] name = "cumulus-pallet-parachain-system-proc-macro" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "cumulus-pallet-session-benchmarking" version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -2229,7 +2241,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-aura" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "polkadot-core-primitives", @@ -2243,7 +2255,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-core" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "polkadot-core-primitives", @@ -2260,7 +2272,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-parachain-inherent" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2283,7 +2295,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-timestamp" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cumulus-primitives-core", "futures", @@ -2296,7 +2308,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-inprocess-interface" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2320,7 +2332,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-interface" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2338,7 +2350,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-minimal-node" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "async-trait", @@ -2373,7 +2385,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-rpc-interface" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2411,7 +2423,7 @@ dependencies = [ [[package]] name = "cumulus-test-relay-sproof-builder" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cumulus-primitives-core", "parity-scale-codec", @@ -2473,7 +2485,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -2513,7 +2525,7 @@ dependencies = [ "proc-macro2", "quote", "scratch", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -2530,7 +2542,7 @@ checksum = "587663dd5fb3d10932c8aecfe7c844db1bcf0aee93eeab08fac13dc1212c2e7f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -2575,7 +2587,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" dependencies = [ "cfg-if", - "hashbrown 0.14.2", + "hashbrown 0.14.3", "lock_api", "once_cell", "parking_lot_core 0.9.9", @@ -2583,15 +2595,15 @@ dependencies = [ [[package]] name = "data-encoding" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" +checksum = "7e962a19be5cfc3f3bf6dd8f61eb50107f356ad6270fbb3ed41476571db78be5" [[package]] name = "data-encoding-macro" -version = "0.1.13" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c904b33cc60130e1aeea4956ab803d08a3f4a0ca82d64ed757afac3891f2bb99" +checksum = "20c01c06f5f429efdf2bae21eb67c28b3df3cf85b7dd2d8ef09c0838dac5d33e" dependencies = [ "data-encoding", "data-encoding-macro-internal", @@ -2599,9 +2611,9 @@ dependencies = [ [[package]] name = "data-encoding-macro-internal" -version = "0.1.11" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fdf3fce3ce863539ec1d7fd1b6dcc3c645663376b43ed376bbf887733e4f772" +checksum = "0047d07f2c89b17dd631c80450d69841a6b5d7fb17278cbc43d7e4cfcf2576f3" dependencies = [ "data-encoding", "syn 1.0.109", @@ -2822,7 +2834,7 @@ checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -2863,7 +2875,7 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.38", + "syn 2.0.39", "termcolor", "toml 0.7.8", "walkdir", @@ -2910,9 +2922,9 @@ dependencies = [ [[package]] name = "dyn-clone" -version = "1.0.14" +version = "1.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" +checksum = "545b22097d44f8a9581187cdf93de7a71e4722bf51200cfaba810865b49a495d" [[package]] name = "ecdsa" @@ -2928,15 +2940,15 @@ dependencies = [ [[package]] name = "ecdsa" -version = "0.16.8" +version = "0.16.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4b1e0c257a9e9f25f90ff76d7a68360ed497ee519c8e428d1825ef0000799d4" +checksum = "ee27f32b5c5292967d2d4a9d7f1e0b0aed2c15daded5a60300e4abb9d8020bca" dependencies = [ "der 0.7.8", "digest 0.10.7", - "elliptic-curve 0.13.6", + "elliptic-curve 0.13.8", "rfc6979 0.4.0", - "signature 2.1.0", + "signature 2.2.0", "spki 0.7.2", ] @@ -2947,20 +2959,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" dependencies = [ "pkcs8 0.10.2", - "signature 2.1.0", + "signature 2.2.0", ] [[package]] name = "ed25519-dalek" -version = "2.0.0" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7277392b266383ef8396db7fdeb1e77b6c52fed775f5df15bb24f35b72156980" +checksum = "1f628eaec48bfd21b865dc2950cfa014450c01d2fa2b69a86c2fd5844ec523c0" dependencies = [ "curve25519-dalek 4.1.1", "ed25519", "rand_core 0.6.4", "serde", "sha2 0.10.8", + "subtle", "zeroize", ] @@ -2986,7 +2999,7 @@ checksum = "7d9ce6874da5d4415896cd45ffbc4d1cfc0c4f9c079427bd870742c30f2f65a9" dependencies = [ "curve25519-dalek 4.1.1", "ed25519", - "hashbrown 0.14.2", + "hashbrown 0.14.3", "hex", "rand_core 0.6.4", "sha2 0.10.8", @@ -3023,12 +3036,12 @@ dependencies = [ [[package]] name = "elliptic-curve" -version = "0.13.6" +version = "0.13.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d97ca172ae9dc9f9b779a6e3a65d308f2af74e5b8c921299075bdb4a0370e914" +checksum = "b5e6043086bf7973472e0c7dff2142ea0b680d30e18d9cc40f267efbf222bd47" dependencies = [ "base16ct 0.2.0", - "crypto-bigint 0.5.3", + "crypto-bigint 0.5.5", "digest 0.10.7", "ff 0.13.0", "generic-array 0.14.7", @@ -3075,7 +3088,7 @@ checksum = "f95e2801cd355d4a1a3e3953ce6ee5ae9603a5c833455343a8bfe3f44d418246" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -3086,7 +3099,7 @@ checksum = "c2ad8cef1d801a4686bfd8919f0b30eac4c8e48968c437a6405ded4fb5272d2b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -3104,9 +3117,9 @@ dependencies = [ [[package]] name = "env_logger" -version = "0.10.0" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" +checksum = "95b3f3e67048839cb0d0781f445682a35113da7121f7c949db0e2be96a4fbece" dependencies = [ "humantime", "is-terminal", @@ -3129,9 +3142,9 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.5" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3e13f66a2f95e32a39eaa81f6b95d42878ca0e1db0c7543723dfe12557e860" +checksum = "f258a7194e7f7c2a7837a8913aeab7fd8c383457034fa20ce4dd3dcb813e8eb8" dependencies = [ "libc", "windows-sys 0.48.0", @@ -3145,15 +3158,36 @@ checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" [[package]] name = "event-listener" -version = "3.0.1" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01cec0252c2afff729ee6f00e903d479fba81784c8e2bd77447673471fdfaea1" +checksum = "d93877bcde0eb80ca09131a08d23f0a5c18a620b01db137dba666d18cd9b30c2" dependencies = [ "concurrent-queue", "parking", "pin-project-lite 0.2.13", ] +[[package]] +name = "event-listener" +version = "4.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "770d968249b5d99410d61f5bf89057f3199a077a04d087092f58e7d10692baae" +dependencies = [ + "concurrent-queue", + "parking", + "pin-project-lite 0.2.13", +] + +[[package]] +name = "event-listener-strategy" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "958e4d70b6d5e81971bebec42271ec641e7ff4e170a6fa605f2b8a8b65cb97d3" +dependencies = [ + "event-listener 4.0.0", + "pin-project-lite 0.2.13", +] + [[package]] name = "exit-future" version = "0.2.0" @@ -3197,7 +3231,7 @@ dependencies = [ "fs-err", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -3284,7 +3318,7 @@ dependencies = [ [[package]] name = "fflonk" version = "0.1.0" -source = "git+https://github.com/w3f/fflonk#e141d4b6f42fb481aefe1b479788694945b6940d" +source = "git+https://github.com/w3f/fflonk#1beb0585e1c8488956fac7f05da061f9b41e8948" dependencies = [ "ark-ec", "ark-ff", @@ -3296,9 +3330,9 @@ dependencies = [ [[package]] name = "fiat-crypto" -version = "0.2.2" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a481586acf778f1b1455424c343f71124b048ffa5f4fc3f8f6ae9dc432dcb3c7" +checksum = "27573eac26f4dd11e2b1916c3fe1baa56407c83c71a773a8ba17ec0bca03b6b7" [[package]] name = "file-per-thread-logger" @@ -3306,7 +3340,7 @@ version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "84f2e425d9790201ba4af4630191feac6dcc98765b118d4d18e91d23c2353866" dependencies = [ - "env_logger 0.10.0", + "env_logger 0.10.1", "log", ] @@ -3385,16 +3419,16 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] name = "fork-tree" version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", ] [[package]] name = "form_urlencoded" -version = "1.2.0" +version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" dependencies = [ "percent-encoding", ] @@ -3408,7 +3442,7 @@ checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa" [[package]] name = "frame-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-support-procedural", @@ -3433,7 +3467,7 @@ dependencies = [ [[package]] name = "frame-benchmarking-cli" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "Inflector", "array-bytes", @@ -3481,18 +3515,18 @@ dependencies = [ [[package]] name = "frame-election-provider-solution-type" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "frame-election-provider-support" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-election-provider-solution-type", "frame-support", @@ -3509,7 +3543,7 @@ dependencies = [ [[package]] name = "frame-executive" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -3539,7 +3573,7 @@ dependencies = [ [[package]] name = "frame-remote-externalities" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-recursion", "futures", @@ -3561,7 +3595,7 @@ dependencies = [ [[package]] name = "frame-support" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "aquamarine", "bitflags 1.3.2", @@ -3601,7 +3635,7 @@ dependencies = [ [[package]] name = "frame-support-procedural" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "Inflector", "cfg-expr", @@ -3613,35 +3647,35 @@ dependencies = [ "proc-macro-warning", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "frame-support-procedural-tools" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support-procedural-tools-derive", "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "frame-support-procedural-tools-derive" version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "frame-system" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cfg-if", "frame-support", @@ -3660,7 +3694,7 @@ dependencies = [ [[package]] name = "frame-system-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -3675,7 +3709,7 @@ dependencies = [ [[package]] name = "frame-system-rpc-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "sp-api", @@ -3684,7 +3718,7 @@ dependencies = [ [[package]] name = "frame-try-runtime" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "parity-scale-codec", @@ -3923,9 +3957,12 @@ dependencies = [ [[package]] name = "fs-err" -version = "2.9.0" +version = "2.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0845fa252299212f0389d64ba26f34fa32cfe41588355f21ed507c59a0f64541" +checksum = "88a41f105fe1d5b6b34b2055e3dc59bb79b46b48b2040b9e6c7b4b5de097aa41" +dependencies = [ + "autocfg", +] [[package]] name = "fs2" @@ -3943,7 +3980,7 @@ version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eeb4ed9e12f43b7fa0baae3f9cdda28352770132ef2e09a23760c29cae8bd47" dependencies = [ - "rustix 0.38.21", + "rustix 0.38.25", "windows-sys 0.48.0", ] @@ -4017,6 +4054,20 @@ dependencies = [ "waker-fn", ] +[[package]] +name = "futures-lite" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3831c2651acb5177cbd83943f3d9c8912c5ad03c76afcc0e9511ba568ec5ebb" +dependencies = [ + "fastrand 2.0.1", + "futures-core", + "futures-io", + "memchr", + "parking", + "pin-project-lite 0.2.13", +] + [[package]] name = "futures-macro" version = "0.3.29" @@ -4025,7 +4076,7 @@ checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -4127,9 +4178,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.10" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" +checksum = "fe9006bed769170c11f845cf00c7c1e9092aeb3f268e007c3e760ac68008070f" dependencies = [ "cfg-if", "libc", @@ -4169,9 +4220,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.28.0" +version = "0.28.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" +checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253" [[package]] name = "glob" @@ -4181,15 +4232,15 @@ checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" [[package]] name = "globset" -version = "0.4.13" +version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "759c97c1e17c55525b57192c06a267cda0ac5210b222d6b82189a2338fa1c13d" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" dependencies = [ "aho-corasick", "bstr", - "fnv", "log", - "regex", + "regex-automata 0.4.3", + "regex-syntax 0.8.2", ] [[package]] @@ -4216,9 +4267,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.21" +version = "0.3.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91fc23aa11be92976ef4729127f1a74adf36d8436f7816b185d18df956790833" +checksum = "4d6250322ef6e60f93f9a2162799302cd6f68f79f6e5d85c8c16f14d1d958178" dependencies = [ "bytes", "fnv", @@ -4226,7 +4277,7 @@ dependencies = [ "futures-sink", "futures-util", "http", - "indexmap 1.9.3", + "indexmap 2.1.0", "slab", "tokio", "tokio-util", @@ -4235,9 +4286,9 @@ dependencies = [ [[package]] name = "handlebars" -version = "4.4.0" +version = "4.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c39b3bc2a8f715298032cf5087e58573809374b08160aa7d750582bdb82d2683" +checksum = "faa67bab9ff362228eb3d00bd024a4965d8231bbb7921167f0cfa66c6626b225" dependencies = [ "log", "pest", @@ -4292,9 +4343,9 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.2" +version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f93e7192158dbcda357bdec5fb5788eebf8bbac027f3f33e719d29135ae84156" +checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" dependencies = [ "ahash 0.8.6", "allocator-api2", @@ -4405,9 +4456,9 @@ dependencies = [ [[package]] name = "http" -version = "0.2.9" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" +checksum = "8947b1a6fad4393052c7ba1f4cd97bed3e953a95c79c92ad9b051a04611d9fbb" dependencies = [ "bytes", "fnv", @@ -4483,11 +4534,11 @@ dependencies = [ "http", "hyper", "log", - "rustls 0.21.8", + "rustls 0.21.9", "rustls-native-certs", "tokio", "tokio-rustls", - "webpki-roots 0.25.2", + "webpki-roots 0.25.3", ] [[package]] @@ -4532,9 +4583,9 @@ dependencies = [ [[package]] name = "idna" -version = "0.4.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" dependencies = [ "unicode-bidi", "unicode-normalization", @@ -4542,21 +4593,21 @@ dependencies = [ [[package]] name = "if-addrs" -version = "0.7.0" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbc0fa01ffc752e9dbc72818cdb072cd028b86be5e09dd04c5a643704fe101a9" +checksum = "cabb0019d51a643781ff15c9c8a3e5dedc365c47211270f4e8f82812fedd8f0a" dependencies = [ "libc", - "winapi", + "windows-sys 0.48.0", ] [[package]] name = "if-watch" -version = "3.1.0" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbb892e5777fe09e16f3d44de7802f4daa7267ecbe8c466f19d94e25bb0c303e" +checksum = "d6b0422c86d7ce0e97169cc42e04ae643caf278874a7a3c87b8150a220dc7e1e" dependencies = [ - "async-io 1.13.0", + "async-io 2.2.1", "core-foundation", "fnv", "futures", @@ -4635,7 +4686,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" dependencies = [ "equivalent", - "hashbrown 0.14.2", + "hashbrown 0.14.3", ] [[package]] @@ -4751,7 +4802,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" dependencies = [ "hermit-abi 0.3.3", - "rustix 0.38.21", + "rustix 0.38.25", "windows-sys 0.48.0", ] @@ -4799,9 +4850,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.64" +version = "0.3.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" +checksum = "cee9c64da59eae3b50095c18d3e74f8b73c0b86d2792824ff01bbce68ba229ca" dependencies = [ "wasm-bindgen", ] @@ -4839,7 +4890,7 @@ dependencies = [ "tokio-rustls", "tokio-util", "tracing", - "webpki-roots 0.25.2", + "webpki-roots 0.25.3", ] [[package]] @@ -4850,7 +4901,7 @@ checksum = "2b5dde66c53d6dcdc8caea1874a45632ec0fcf5b437789f1e45766a1512ce803" dependencies = [ "anyhow", "arrayvec 0.7.4", - "async-lock", + "async-lock 2.8.0", "async-trait", "beef", "futures-channel", @@ -4952,13 +5003,13 @@ dependencies = [ [[package]] name = "k256" -version = "0.13.1" +version = "0.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cadb76004ed8e97623117f3df85b17aaa6626ab0b0831e6573f104df16cd1bcc" +checksum = "3f01b677d82ef7a676aa37e099defd83a28e15687112cafdd112d60236b6115b" dependencies = [ "cfg-if", - "ecdsa 0.16.8", - "elliptic-curve 0.13.6", + "ecdsa 0.16.9", + "elliptic-curve 0.13.8", "once_cell", "sha2 0.10.8", ] @@ -4975,7 +5026,7 @@ dependencies = [ [[package]] name = "kusama-runtime-constants" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "polkadot-primitives", @@ -5044,9 +5095,9 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.149" +version = "0.2.150" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" +checksum = "89d92a4743f9a61002fae18374ed11e7973f530cb3a3255fb354818118b2203c" [[package]] name = "libflate" @@ -5093,7 +5144,7 @@ dependencies = [ "bytes", "futures", "futures-timer", - "getrandom 0.2.10", + "getrandom 0.2.11", "instant", "libp2p-allow-block-list", "libp2p-connection-limits", @@ -5509,6 +5560,17 @@ dependencies = [ "yamux", ] +[[package]] +name = "libredox" +version = "0.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85c833ca1e66078851dba29046874e38f08b2c883700aa29a03ddd3b23814ee8" +dependencies = [ + "bitflags 2.4.1", + "libc", + "redox_syscall 0.4.1", +] + [[package]] name = "librocksdb-sys" version = "0.11.0+8.1.1" @@ -5630,9 +5692,9 @@ checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" [[package]] name = "linux-raw-sys" -version = "0.4.10" +version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" +checksum = "969488b55f8ac402214f3f5fd243ebb7206cf82de60d3172994707a4bcc2b829" [[package]] name = "lock_api" @@ -5712,7 +5774,7 @@ dependencies = [ "macro_magic_core", "macro_magic_macros", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -5726,7 +5788,7 @@ dependencies = [ "macro_magic_core_macros", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -5737,7 +5799,7 @@ checksum = "d710e1214dffbab3b5dacb21475dde7d6ed84c69ff722b3a47a782668d44fbac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -5748,7 +5810,7 @@ checksum = "b8fb85ec1620619edf2984a7693497d4ec88a9665d8b87e942856884c92dbf2a" dependencies = [ "macro_magic_core", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -5810,7 +5872,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2cffa4ad52c6f791f4f8b15f0c05f9824b2ced1160e88cc393d64fff9a8ac64" dependencies = [ - "rustix 0.38.21", + "rustix 0.38.25", ] [[package]] @@ -5922,7 +5984,7 @@ dependencies = [ [[package]] name = "mmr-gadget" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "log", @@ -5941,7 +6003,7 @@ dependencies = [ [[package]] name = "mmr-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "anyhow", "jsonrpsee", @@ -6444,7 +6506,7 @@ dependencies = [ [[package]] name = "pallet-aura" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -6461,7 +6523,7 @@ dependencies = [ [[package]] name = "pallet-authority-discovery" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -6477,7 +6539,7 @@ dependencies = [ [[package]] name = "pallet-authorship" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -6491,7 +6553,7 @@ dependencies = [ [[package]] name = "pallet-babe" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6515,7 +6577,7 @@ dependencies = [ [[package]] name = "pallet-bags-list" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "aquamarine", "docify", @@ -6537,7 +6599,7 @@ dependencies = [ [[package]] name = "pallet-balances" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6552,7 +6614,7 @@ dependencies = [ [[package]] name = "pallet-beefy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -6572,7 +6634,7 @@ dependencies = [ [[package]] name = "pallet-beefy-mmr" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "binary-merkle-tree", @@ -6597,7 +6659,7 @@ dependencies = [ [[package]] name = "pallet-bounties" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6635,7 +6697,7 @@ dependencies = [ [[package]] name = "pallet-child-bounties" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6654,7 +6716,7 @@ dependencies = [ [[package]] name = "pallet-collator-selection" version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6673,7 +6735,7 @@ dependencies = [ [[package]] name = "pallet-collective" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6690,7 +6752,7 @@ dependencies = [ [[package]] name = "pallet-conviction-voting" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "assert_matches", "frame-benchmarking", @@ -6707,7 +6769,7 @@ dependencies = [ [[package]] name = "pallet-democracy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6725,7 +6787,7 @@ dependencies = [ [[package]] name = "pallet-election-provider-multi-phase" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -6748,7 +6810,7 @@ dependencies = [ [[package]] name = "pallet-election-provider-support-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -6762,7 +6824,7 @@ dependencies = [ [[package]] name = "pallet-elections-phragmen" version = "5.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6781,7 +6843,7 @@ dependencies = [ [[package]] name = "pallet-fast-unstake" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "docify", "frame-benchmarking", @@ -6857,7 +6919,7 @@ dependencies = [ [[package]] name = "pallet-grandpa" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6882,7 +6944,7 @@ name = "pallet-handles" version = "0.0.0" dependencies = [ "common-primitives", - "env_logger 0.10.0", + "env_logger 0.10.1", "frame-benchmarking", "frame-support", "frame-system", @@ -6931,7 +6993,7 @@ dependencies = [ [[package]] name = "pallet-identity" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "enumflags2", "frame-benchmarking", @@ -6947,7 +7009,7 @@ dependencies = [ [[package]] name = "pallet-im-online" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6967,7 +7029,7 @@ dependencies = [ [[package]] name = "pallet-indices" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -6984,7 +7046,7 @@ dependencies = [ [[package]] name = "pallet-membership" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7001,7 +7063,7 @@ dependencies = [ [[package]] name = "pallet-message-queue" version = "7.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7070,7 +7132,7 @@ dependencies = [ [[package]] name = "pallet-mmr" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7143,7 +7205,7 @@ dependencies = [ [[package]] name = "pallet-multisig" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7159,7 +7221,7 @@ dependencies = [ [[package]] name = "pallet-nis" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7175,7 +7237,7 @@ dependencies = [ [[package]] name = "pallet-nomination-pools" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -7194,7 +7256,7 @@ dependencies = [ [[package]] name = "pallet-nomination-pools-benchmarking" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -7214,7 +7276,7 @@ dependencies = [ [[package]] name = "pallet-nomination-pools-runtime-api" version = "1.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "pallet-nomination-pools", "parity-scale-codec", @@ -7225,7 +7287,7 @@ dependencies = [ [[package]] name = "pallet-offences" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -7242,7 +7304,7 @@ dependencies = [ [[package]] name = "pallet-offences-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -7266,7 +7328,7 @@ dependencies = [ [[package]] name = "pallet-preimage" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7283,7 +7345,7 @@ dependencies = [ [[package]] name = "pallet-proxy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7298,7 +7360,7 @@ dependencies = [ [[package]] name = "pallet-ranked-collective" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7316,7 +7378,7 @@ dependencies = [ [[package]] name = "pallet-recovery" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7331,7 +7393,7 @@ dependencies = [ [[package]] name = "pallet-referenda" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "assert_matches", "frame-benchmarking", @@ -7350,7 +7412,7 @@ dependencies = [ [[package]] name = "pallet-scheduler" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "docify", "frame-benchmarking", @@ -7424,7 +7486,7 @@ dependencies = [ [[package]] name = "pallet-session" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -7446,7 +7508,7 @@ dependencies = [ [[package]] name = "pallet-session-benchmarking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7463,7 +7525,7 @@ dependencies = [ [[package]] name = "pallet-society" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7481,7 +7543,7 @@ dependencies = [ [[package]] name = "pallet-staking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -7504,18 +7566,18 @@ dependencies = [ [[package]] name = "pallet-staking-reward-curve" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "pallet-staking-reward-fn" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "log", "sp-arithmetic", @@ -7524,7 +7586,7 @@ dependencies = [ [[package]] name = "pallet-staking-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "sp-api", @@ -7533,7 +7595,7 @@ dependencies = [ [[package]] name = "pallet-state-trie-migration" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7552,7 +7614,7 @@ name = "pallet-stateful-storage" version = "0.0.0" dependencies = [ "common-primitives", - "env_logger 0.10.0", + "env_logger 0.10.1", "frame-benchmarking", "frame-support", "frame-system", @@ -7601,7 +7663,7 @@ dependencies = [ [[package]] name = "pallet-sudo" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7634,7 +7696,7 @@ dependencies = [ [[package]] name = "pallet-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7653,7 +7715,7 @@ dependencies = [ [[package]] name = "pallet-tips" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7672,7 +7734,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -7688,7 +7750,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "jsonrpsee", "pallet-transaction-payment-rpc-runtime-api", @@ -7704,7 +7766,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc-runtime-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "pallet-transaction-payment", "parity-scale-codec", @@ -7716,7 +7778,7 @@ dependencies = [ [[package]] name = "pallet-treasury" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7733,7 +7795,7 @@ dependencies = [ [[package]] name = "pallet-utility" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7749,7 +7811,7 @@ dependencies = [ [[package]] name = "pallet-vesting" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7764,7 +7826,7 @@ dependencies = [ [[package]] name = "pallet-whitelist" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7779,7 +7841,7 @@ dependencies = [ [[package]] name = "pallet-xcm" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bounded-collections", "frame-benchmarking", @@ -7800,7 +7862,7 @@ dependencies = [ [[package]] name = "pallet-xcm-benchmarks" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-benchmarking", "frame-support", @@ -7819,7 +7881,7 @@ dependencies = [ [[package]] name = "parachain-info" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cumulus-primitives-core", "frame-support", @@ -8008,9 +8070,9 @@ dependencies = [ [[package]] name = "percent-encoding" -version = "2.3.0" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pest" @@ -8043,7 +8105,7 @@ dependencies = [ "pest_meta", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -8097,7 +8159,7 @@ dependencies = [ "phf_shared", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -8126,7 +8188,7 @@ checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -8186,14 +8248,14 @@ checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" [[package]] name = "platforms" -version = "3.1.2" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4503fa043bf02cee09a9582e9554b4c6403b2ef55e4612e96561d294419429f8" +checksum = "14e6ab3f592e6fb464fc9712d8d6e6912de6473954635fd76a589d832cffcbb0" [[package]] name = "polkadot-approval-distribution" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "futures-timer", @@ -8211,7 +8273,7 @@ dependencies = [ [[package]] name = "polkadot-availability-bitfield-distribution" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "always-assert", "futures", @@ -8227,7 +8289,7 @@ dependencies = [ [[package]] name = "polkadot-availability-distribution" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "derive_more", "fatality", @@ -8250,7 +8312,7 @@ dependencies = [ [[package]] name = "polkadot-availability-recovery" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "fatality", "futures", @@ -8271,7 +8333,7 @@ dependencies = [ [[package]] name = "polkadot-cli" version = "1.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "clap", "frame-benchmarking-cli", @@ -8298,7 +8360,7 @@ dependencies = [ [[package]] name = "polkadot-collator-protocol" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "fatality", @@ -8320,7 +8382,7 @@ dependencies = [ [[package]] name = "polkadot-core-primitives" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -8332,7 +8394,7 @@ dependencies = [ [[package]] name = "polkadot-dispute-distribution" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "derive_more", "fatality", @@ -8357,7 +8419,7 @@ dependencies = [ [[package]] name = "polkadot-erasure-coding" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "polkadot-node-primitives", @@ -8371,7 +8433,7 @@ dependencies = [ [[package]] name = "polkadot-gossip-support" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "futures-timer", @@ -8392,7 +8454,7 @@ dependencies = [ [[package]] name = "polkadot-network-bridge" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "always-assert", "async-trait", @@ -8415,7 +8477,7 @@ dependencies = [ [[package]] name = "polkadot-node-collation-generation" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "parity-scale-codec", @@ -8433,7 +8495,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-approval-voting" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "derive_more", @@ -8462,7 +8524,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-av-store" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "futures", @@ -8484,7 +8546,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-backing" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "fatality", @@ -8503,7 +8565,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-bitfield-signing" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "polkadot-node-subsystem", @@ -8518,7 +8580,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-candidate-validation" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -8539,7 +8601,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-chain-api" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "polkadot-node-metrics", @@ -8554,7 +8616,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-chain-selection" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "futures-timer", @@ -8571,7 +8633,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-dispute-coordinator" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "fatality", "futures", @@ -8590,7 +8652,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-parachains-inherent" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -8607,7 +8669,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-prospective-parachains" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "fatality", @@ -8624,7 +8686,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-provisioner" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "fatality", @@ -8641,7 +8703,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "always-assert", "futures", @@ -8669,7 +8731,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf-checker" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "polkadot-node-primitives", @@ -8685,7 +8747,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf-common" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "cpu-time", "futures", @@ -8708,7 +8770,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf-prepare-worker" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "libc", @@ -8731,7 +8793,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-runtime-api" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "polkadot-node-metrics", @@ -8746,7 +8808,7 @@ dependencies = [ [[package]] name = "polkadot-node-jaeger" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "lazy_static", "log", @@ -8764,7 +8826,7 @@ dependencies = [ [[package]] name = "polkadot-node-metrics" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bs58 0.5.0", "futures", @@ -8783,9 +8845,9 @@ dependencies = [ [[package]] name = "polkadot-node-network-protocol" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "async-channel", + "async-channel 1.9.0", "async-trait", "bitvec", "derive_more", @@ -8807,7 +8869,7 @@ dependencies = [ [[package]] name = "polkadot-node-primitives" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bounded-vec", "futures", @@ -8829,7 +8891,7 @@ dependencies = [ [[package]] name = "polkadot-node-subsystem" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "polkadot-node-jaeger", "polkadot-node-subsystem-types", @@ -8839,7 +8901,7 @@ dependencies = [ [[package]] name = "polkadot-node-subsystem-types" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "derive_more", @@ -8863,7 +8925,7 @@ dependencies = [ [[package]] name = "polkadot-node-subsystem-util" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "derive_more", @@ -8896,7 +8958,7 @@ dependencies = [ [[package]] name = "polkadot-overseer" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -8919,7 +8981,7 @@ dependencies = [ [[package]] name = "polkadot-parachain-primitives" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bounded-collections", "derive_more", @@ -8936,7 +8998,7 @@ dependencies = [ [[package]] name = "polkadot-performance-test" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "env_logger 0.9.3", "log", @@ -8954,7 +9016,7 @@ dependencies = [ [[package]] name = "polkadot-primitives" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "hex-literal", @@ -8980,7 +9042,7 @@ dependencies = [ [[package]] name = "polkadot-rpc" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "jsonrpsee", "mmr-rpc", @@ -9012,7 +9074,7 @@ dependencies = [ [[package]] name = "polkadot-runtime" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "frame-benchmarking", @@ -9109,7 +9171,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-common" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitvec", "frame-benchmarking", @@ -9155,7 +9217,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-constants" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "polkadot-primitives", @@ -9169,7 +9231,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-metrics" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bs58 0.5.0", "frame-benchmarking", @@ -9182,7 +9244,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-parachains" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bitflags 1.3.2", "bitvec", @@ -9228,7 +9290,7 @@ dependencies = [ [[package]] name = "polkadot-service" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "frame-benchmarking", @@ -9347,7 +9409,7 @@ dependencies = [ [[package]] name = "polkadot-statement-distribution" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "arrayvec 0.7.4", "bitvec", @@ -9371,7 +9433,7 @@ dependencies = [ [[package]] name = "polkadot-statement-table" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "polkadot-primitives", @@ -9396,27 +9458,16 @@ dependencies = [ [[package]] name = "polling" -version = "3.3.0" +version = "3.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e53b6af1f60f36f8c2ac2aad5459d75a5a9b4be1e8cdd40264f315d78193e531" +checksum = "cf63fa624ab313c11656b4cda960bfc46c410187ad493c41f6ba2d8c1e991c9e" dependencies = [ "cfg-if", "concurrent-queue", "pin-project-lite 0.2.13", - "rustix 0.38.21", + "rustix 0.38.25", "tracing", - "windows-sys 0.48.0", -] - -[[package]] -name = "poly1305" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "048aeb476be11a4b6ca432ca569e375810de9294ae78f4774e78ea98a9246ede" -dependencies = [ - "cpufeatures", - "opaque-debug 0.3.0", - "universal-hash 0.4.1", + "windows-sys 0.52.0", ] [[package]] @@ -9529,7 +9580,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" dependencies = [ "proc-macro2", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -9603,14 +9654,14 @@ checksum = "3d1eaa7fa0aa1929ffdf7eeb6eac234dde6268914a14ad44d23521ab6a9b258e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "proc-macro2" -version = "1.0.69" +version = "1.0.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" +checksum = "39278fbbf5fb4f646ce651690877f89d1c5811a3d4acb27700c1cb3cdb78fd3b" dependencies = [ "unicode-ident", ] @@ -9649,7 +9700,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -9852,7 +9903,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", ] [[package]] @@ -9953,12 +10004,12 @@ dependencies = [ [[package]] name = "redox_users" -version = "0.4.3" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" +checksum = "a18479200779601e498ada4e8c1e1f50e3ee19deb0259c25825a98b5603b2cb4" dependencies = [ - "getrandom 0.2.10", - "redox_syscall 0.2.16", + "getrandom 0.2.11", + "libredox", "thiserror", ] @@ -9992,7 +10043,7 @@ checksum = "7f7473c2cfcf90008193dd0e3e16599455cb601a9fce322b5bb55de799664925" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -10119,7 +10170,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb0205304757e5d899b9c2e448b867ffd03ae7f988002e47cd24954391394d0b" dependencies = [ "cc", - "getrandom 0.2.10", + "getrandom 0.2.11", "libc", "spin 0.9.8", "untrusted 0.9.0", @@ -10145,7 +10196,7 @@ dependencies = [ [[package]] name = "rococo-runtime" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "binary-merkle-tree", "frame-benchmarking", @@ -10233,7 +10284,7 @@ dependencies = [ [[package]] name = "rococo-runtime-constants" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "polkadot-primitives", @@ -10246,13 +10297,13 @@ dependencies = [ [[package]] name = "rpassword" -version = "7.2.0" +version = "7.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6678cf63ab3491898c0d021b493c94c9b221d91295294a2a5746eacbe5928322" +checksum = "80472be3c897911d0137b2d2b9055faf6eeac5b14e324073d83bc17b191d7e3f" dependencies = [ "libc", "rtoolbox", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -10283,12 +10334,12 @@ dependencies = [ [[package]] name = "rtoolbox" -version = "0.0.1" +version = "0.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "034e22c514f5c0cb8a10ff341b9b048b5ceb21591f31c8f44c43b960f9b3524a" +checksum = "c247d24e63230cdb56463ae328478bd5eac8b8faa8c69461a77e8e323afac90e" dependencies = [ "libc", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -10371,14 +10422,14 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.21" +version = "0.38.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b426b0506e5d50a7d8dafcf2e81471400deb602392c7dd110815afb4eaf02a3" +checksum = "dc99bc2d4f1fed22595588a013687477aedf3cdcfb26558c559edb67b4d9b22e" dependencies = [ "bitflags 2.4.1", "errno", "libc", - "linux-raw-sys 0.4.10", + "linux-raw-sys 0.4.11", "windows-sys 0.48.0", ] @@ -10409,9 +10460,9 @@ dependencies = [ [[package]] name = "rustls" -version = "0.21.8" +version = "0.21.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "446e14c5cda4f3f30fe71863c34ec70f5ac79d6087097ad0bb433e1be5edf04c" +checksum = "629648aced5775d558af50b2b4c7b02983a04b312126d45eeead26e7caa498b9" dependencies = [ "log", "ring 0.17.5", @@ -10433,9 +10484,9 @@ dependencies = [ [[package]] name = "rustls-pemfile" -version = "1.0.3" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" +checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" dependencies = [ "base64 0.21.5", ] @@ -10505,7 +10556,7 @@ dependencies = [ [[package]] name = "sc-allocator" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "log", "sp-core", @@ -10516,7 +10567,7 @@ dependencies = [ [[package]] name = "sc-authority-discovery" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -10544,7 +10595,7 @@ dependencies = [ [[package]] name = "sc-basic-authorship" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "futures-timer", @@ -10567,7 +10618,7 @@ dependencies = [ [[package]] name = "sc-block-builder" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "sc-client-api", @@ -10582,7 +10633,7 @@ dependencies = [ [[package]] name = "sc-chain-spec" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "memmap2", "sc-chain-spec-derive", @@ -10601,18 +10652,18 @@ dependencies = [ [[package]] name = "sc-chain-spec-derive" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sc-cli" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "chrono", @@ -10651,7 +10702,7 @@ dependencies = [ [[package]] name = "sc-client-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "fnv", "futures", @@ -10677,7 +10728,7 @@ dependencies = [ [[package]] name = "sc-client-db" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "hash-db", "kvdb", @@ -10703,7 +10754,7 @@ dependencies = [ [[package]] name = "sc-consensus" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -10728,7 +10779,7 @@ dependencies = [ [[package]] name = "sc-consensus-aura" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -10757,7 +10808,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "fork-tree", @@ -10793,7 +10844,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe-rpc" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "jsonrpsee", @@ -10815,10 +10866,10 @@ dependencies = [ [[package]] name = "sc-consensus-beefy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", - "async-channel", + "async-channel 1.9.0", "async-trait", "fnv", "futures", @@ -10849,7 +10900,7 @@ dependencies = [ [[package]] name = "sc-consensus-beefy-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "jsonrpsee", @@ -10868,7 +10919,7 @@ dependencies = [ [[package]] name = "sc-consensus-epochs" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "fork-tree", "parity-scale-codec", @@ -10881,7 +10932,7 @@ dependencies = [ [[package]] name = "sc-consensus-grandpa" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ahash 0.8.6", "array-bytes", @@ -10922,7 +10973,7 @@ dependencies = [ [[package]] name = "sc-consensus-grandpa-rpc" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "finality-grandpa", "futures", @@ -10942,7 +10993,7 @@ dependencies = [ [[package]] name = "sc-consensus-manual-seal" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "assert_matches", "async-trait", @@ -10977,7 +11028,7 @@ dependencies = [ [[package]] name = "sc-consensus-slots" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -11000,7 +11051,7 @@ dependencies = [ [[package]] name = "sc-executor" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "parking_lot 0.12.1", @@ -11022,7 +11073,7 @@ dependencies = [ [[package]] name = "sc-executor-common" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "sc-allocator", "sp-maybe-compressed-blob", @@ -11034,7 +11085,7 @@ dependencies = [ [[package]] name = "sc-executor-wasmtime" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "anyhow", "cfg-if", @@ -11051,7 +11102,7 @@ dependencies = [ [[package]] name = "sc-informant" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ansi_term", "futures", @@ -11067,7 +11118,7 @@ dependencies = [ [[package]] name = "sc-keystore" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "parking_lot 0.12.1", @@ -11081,10 +11132,10 @@ dependencies = [ [[package]] name = "sc-network" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", - "async-channel", + "async-channel 1.9.0", "async-trait", "asynchronous-codec", "bytes", @@ -11122,9 +11173,9 @@ dependencies = [ [[package]] name = "sc-network-bitswap" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "async-channel", + "async-channel 1.9.0", "cid 0.9.0", "futures", "libp2p-identity", @@ -11142,7 +11193,7 @@ dependencies = [ [[package]] name = "sc-network-common" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "bitflags 1.3.2", @@ -11159,7 +11210,7 @@ dependencies = [ [[package]] name = "sc-network-gossip" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ahash 0.8.6", "futures", @@ -11177,10 +11228,10 @@ dependencies = [ [[package]] name = "sc-network-light" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", - "async-channel", + "async-channel 1.9.0", "futures", "libp2p-identity", "log", @@ -11198,10 +11249,10 @@ dependencies = [ [[package]] name = "sc-network-sync" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", - "async-channel", + "async-channel 1.9.0", "async-trait", "fork-tree", "futures", @@ -11232,7 +11283,7 @@ dependencies = [ [[package]] name = "sc-network-transactions" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "futures", @@ -11250,7 +11301,7 @@ dependencies = [ [[package]] name = "sc-offchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "bytes", @@ -11284,7 +11335,7 @@ dependencies = [ [[package]] name = "sc-proposer-metrics" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "log", "substrate-prometheus-endpoint", @@ -11293,7 +11344,7 @@ dependencies = [ [[package]] name = "sc-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "jsonrpsee", @@ -11324,7 +11375,7 @@ dependencies = [ [[package]] name = "sc-rpc-api" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -11343,7 +11394,7 @@ dependencies = [ [[package]] name = "sc-rpc-server" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "http", "jsonrpsee", @@ -11358,7 +11409,7 @@ dependencies = [ [[package]] name = "sc-rpc-spec-v2" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "futures", @@ -11386,7 +11437,7 @@ dependencies = [ [[package]] name = "sc-service" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "directories", @@ -11450,7 +11501,7 @@ dependencies = [ [[package]] name = "sc-state-db" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "log", "parity-scale-codec", @@ -11461,7 +11512,7 @@ dependencies = [ [[package]] name = "sc-storage-monitor" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "clap", "fs4", @@ -11475,7 +11526,7 @@ dependencies = [ [[package]] name = "sc-sync-state-rpc" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -11494,7 +11545,7 @@ dependencies = [ [[package]] name = "sc-sysinfo" version = "6.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "libc", @@ -11513,7 +11564,7 @@ dependencies = [ [[package]] name = "sc-telemetry" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "chrono", "futures", @@ -11532,7 +11583,7 @@ dependencies = [ [[package]] name = "sc-tracing" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ansi_term", "atty", @@ -11561,18 +11612,18 @@ dependencies = [ [[package]] name = "sc-tracing-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sc-transaction-pool" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -11598,7 +11649,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -11614,9 +11665,9 @@ dependencies = [ [[package]] name = "sc-utils" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "async-channel", + "async-channel 1.9.0", "futures", "futures-timer", "lazy_static", @@ -11854,22 +11905,22 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" [[package]] name = "serde" -version = "1.0.190" +version = "1.0.193" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91d3c334ca1ee894a2c6f6ad698fe8c435b76d504b13d436f0685d648d6d96f7" +checksum = "25dd9975e68d0cb5aa1120c288333fc98731bd1dd12f561e468ea4728c042b89" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.190" +version = "1.0.193" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67c5609f394e5c2bd7fc51efda478004ea80ef42fee983d5c67a65e34f32c0e3" +checksum = "43576ca501357b9b071ac53cdc7da8ef0cbd9493d8df094cd821777ea6e894d3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -12022,9 +12073,9 @@ dependencies = [ [[package]] name = "signature" -version = "2.1.0" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e1788eed21689f9cf370582dfc467ef36ed9c707f073528ddafa8d83e3b8500" +checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" dependencies = [ "digest 0.10.7", "rand_core 0.6.4", @@ -12067,7 +12118,7 @@ checksum = "826167069c09b99d56f31e9ae5c99049e932a98c9dc2dac47645b08dbbf76ba7" [[package]] name = "slot-range-helper" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "enumn", "parity-scale-codec", @@ -12087,9 +12138,9 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.1" +version = "1.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" +checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "smol" @@ -12097,15 +12148,15 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "13f2b548cd8447f8de0fdf1c592929f70f4fc7039a05e47404b0d096ec6987a1" dependencies = [ - "async-channel", + "async-channel 1.9.0", "async-executor", "async-fs", "async-io 1.13.0", - "async-lock", + "async-lock 2.8.0", "async-net", "async-process", "blocking", - "futures-lite", + "futures-lite 1.13.0", ] [[package]] @@ -12115,22 +12166,22 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0bb30cf57b7b5f6109ce17c3164445e2d6f270af2cb48f6e4d31c2967c9a9f5" dependencies = [ "arrayvec 0.7.4", - "async-lock", + "async-lock 2.8.0", "atomic-take", "base64 0.21.5", "bip39", "blake2-rfc", "bs58 0.5.0", - "chacha20 0.9.1", + "chacha20", "crossbeam-queue", "derive_more", "ed25519-zebra 4.0.3", "either", "event-listener 2.5.3", "fnv", - "futures-lite", + "futures-lite 1.13.0", "futures-util", - "hashbrown 0.14.2", + "hashbrown 0.14.3", "hex", "hmac 0.12.1", "itertools 0.11.0", @@ -12143,7 +12194,7 @@ dependencies = [ "num-traits", "pbkdf2 0.12.2", "pin-project", - "poly1305 0.8.0", + "poly1305", "rand 0.8.5", "rand_chacha 0.3.1", "ruzstd", @@ -12168,8 +12219,8 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "256b5bad1d6b49045e95fe87492ce73d5af81545d8b4d8318a872d2007024c33" dependencies = [ - "async-channel", - "async-lock", + "async-channel 1.9.0", + "async-lock 2.8.0", "base64 0.21.5", "blake2-rfc", "derive_more", @@ -12177,9 +12228,9 @@ dependencies = [ "event-listener 2.5.3", "fnv", "futures-channel", - "futures-lite", + "futures-lite 1.13.0", "futures-util", - "hashbrown 0.14.2", + "hashbrown 0.14.3", "hex", "itertools 0.11.0", "log", @@ -12206,16 +12257,16 @@ checksum = "5e9f0ab6ef7eb7353d9119c170a436d1bf248eea575ac42d19d12f4e34130831" [[package]] name = "snow" -version = "0.9.3" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c9d1425eb528a21de2755c75af4c9b5d57f50a0d4c3b7f1828a4cd03f8ba155" +checksum = "58021967fd0a5eeeb23b08df6cc244a4d4a5b4aec1d27c9e02fad1a58b4cd74e" dependencies = [ - "aes-gcm 0.9.4", + "aes-gcm 0.10.3", "blake2", "chacha20poly1305", "curve25519-dalek 4.1.1", "rand_core 0.6.4", - "ring 0.16.20", + "ring 0.17.5", "rustc_version", "sha2 0.10.8", "subtle", @@ -12261,7 +12312,7 @@ dependencies = [ [[package]] name = "sp-api" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "hash-db", "log", @@ -12282,7 +12333,7 @@ dependencies = [ [[package]] name = "sp-api-proc-macro" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "Inflector", "blake2", @@ -12290,13 +12341,13 @@ dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sp-application-crypto" version = "23.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -12309,7 +12360,7 @@ dependencies = [ [[package]] name = "sp-arithmetic" version = "16.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "integer-sqrt", "num-traits", @@ -12323,7 +12374,7 @@ dependencies = [ [[package]] name = "sp-authority-discovery" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -12336,7 +12387,7 @@ dependencies = [ [[package]] name = "sp-block-builder" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "sp-api", "sp-inherents", @@ -12347,7 +12398,7 @@ dependencies = [ [[package]] name = "sp-blockchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "log", @@ -12365,7 +12416,7 @@ dependencies = [ [[package]] name = "sp-consensus" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "futures", @@ -12380,7 +12431,7 @@ dependencies = [ [[package]] name = "sp-consensus-aura" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "parity-scale-codec", @@ -12397,7 +12448,7 @@ dependencies = [ [[package]] name = "sp-consensus-babe" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "parity-scale-codec", @@ -12416,7 +12467,7 @@ dependencies = [ [[package]] name = "sp-consensus-beefy" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "lazy_static", "parity-scale-codec", @@ -12435,7 +12486,7 @@ dependencies = [ [[package]] name = "sp-consensus-grandpa" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "finality-grandpa", "log", @@ -12453,7 +12504,7 @@ dependencies = [ [[package]] name = "sp-consensus-slots" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -12465,7 +12516,7 @@ dependencies = [ [[package]] name = "sp-core" version = "21.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "arrayvec 0.7.4", @@ -12512,7 +12563,7 @@ dependencies = [ [[package]] name = "sp-core-hashing" version = "9.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "blake2b_simd", "byteorder", @@ -12525,17 +12576,17 @@ dependencies = [ [[package]] name = "sp-core-hashing-proc-macro" version = "9.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "quote", "sp-core-hashing", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sp-database" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "kvdb", "parking_lot 0.12.1", @@ -12544,17 +12595,17 @@ dependencies = [ [[package]] name = "sp-debug-derive" version = "8.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sp-externalities" version = "0.19.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "environmental", "parity-scale-codec", @@ -12565,7 +12616,7 @@ dependencies = [ [[package]] name = "sp-genesis-builder" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "serde_json", "sp-api", @@ -12576,7 +12627,7 @@ dependencies = [ [[package]] name = "sp-inherents" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "impl-trait-for-tuples", @@ -12590,7 +12641,7 @@ dependencies = [ [[package]] name = "sp-io" version = "23.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bytes", "ed25519-dalek", @@ -12614,7 +12665,7 @@ dependencies = [ [[package]] name = "sp-keyring" version = "24.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "lazy_static", "sp-core", @@ -12625,7 +12676,7 @@ dependencies = [ [[package]] name = "sp-keystore" version = "0.27.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "parking_lot 0.12.1", @@ -12637,7 +12688,7 @@ dependencies = [ [[package]] name = "sp-maybe-compressed-blob" version = "4.1.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "thiserror", "zstd 0.12.4", @@ -12646,7 +12697,7 @@ dependencies = [ [[package]] name = "sp-metadata-ir" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-metadata", "parity-scale-codec", @@ -12657,7 +12708,7 @@ dependencies = [ [[package]] name = "sp-mmr-primitives" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ckb-merkle-mountain-range", "log", @@ -12675,7 +12726,7 @@ dependencies = [ [[package]] name = "sp-npos-elections" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -12689,7 +12740,7 @@ dependencies = [ [[package]] name = "sp-offchain" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "sp-api", "sp-core", @@ -12699,7 +12750,7 @@ dependencies = [ [[package]] name = "sp-panic-handler" version = "8.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "backtrace", "lazy_static", @@ -12709,7 +12760,7 @@ dependencies = [ [[package]] name = "sp-rpc" version = "6.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "rustc-hash", "serde", @@ -12719,7 +12770,7 @@ dependencies = [ [[package]] name = "sp-runtime" version = "24.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "either", "hash256-std-hasher", @@ -12741,7 +12792,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "17.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bytes", "impl-trait-for-tuples", @@ -12759,19 +12810,19 @@ dependencies = [ [[package]] name = "sp-runtime-interface-proc-macro" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "Inflector", "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sp-session" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -12786,7 +12837,7 @@ dependencies = [ [[package]] name = "sp-staking" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", @@ -12800,7 +12851,7 @@ dependencies = [ [[package]] name = "sp-state-machine" version = "0.28.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "hash-db", "log", @@ -12821,7 +12872,7 @@ dependencies = [ [[package]] name = "sp-statement-store" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "aes-gcm 0.10.3", "curve25519-dalek 4.1.1", @@ -12845,12 +12896,12 @@ dependencies = [ [[package]] name = "sp-std" version = "8.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" [[package]] name = "sp-storage" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "impl-serde", "parity-scale-codec", @@ -12863,7 +12914,7 @@ dependencies = [ [[package]] name = "sp-timestamp" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "parity-scale-codec", @@ -12876,7 +12927,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "10.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "sp-std", @@ -12888,7 +12939,7 @@ dependencies = [ [[package]] name = "sp-transaction-pool" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "sp-api", "sp-runtime", @@ -12897,7 +12948,7 @@ dependencies = [ [[package]] name = "sp-transaction-storage-proof" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "parity-scale-codec", @@ -12912,7 +12963,7 @@ dependencies = [ [[package]] name = "sp-trie" version = "22.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ahash 0.8.6", "hash-db", @@ -12935,7 +12986,7 @@ dependencies = [ [[package]] name = "sp-version" version = "22.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "impl-serde", "parity-scale-codec", @@ -12952,18 +13003,18 @@ dependencies = [ [[package]] name = "sp-version-proc-macro" version = "8.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "sp-wasm-interface" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "anyhow", "impl-trait-for-tuples", @@ -12976,7 +13027,7 @@ dependencies = [ [[package]] name = "sp-weights" version = "20.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "parity-scale-codec", "scale-info", @@ -13002,9 +13053,9 @@ checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" [[package]] name = "spinners" -version = "4.1.0" +version = "4.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08615eea740067d9899969bc2891c68a19c315cb1f66640af9a9ecb91b13bcab" +checksum = "a0ef947f358b9c238923f764c72a4a9d42f2d637c46e059dbd319d6e7cfb4f82" dependencies = [ "lazy_static", "maplit", @@ -13033,9 +13084,9 @@ dependencies = [ [[package]] name = "ss58-registry" -version = "1.43.0" +version = "1.44.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e6915280e2d0db8911e5032a5c275571af6bdded2916abd691a659be25d3439" +checksum = "35935738370302d5e33963665b77541e4b990a3e919ec904c837a56cfc891de1" dependencies = [ "Inflector", "num-format", @@ -13055,7 +13106,7 @@ checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" [[package]] name = "staging-kusama-runtime" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "binary-merkle-tree", "bitvec", @@ -13161,7 +13212,7 @@ dependencies = [ [[package]] name = "staging-xcm" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "bounded-collections", "derivative", @@ -13178,7 +13229,7 @@ dependencies = [ [[package]] name = "staging-xcm-builder" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "frame-system", @@ -13200,7 +13251,7 @@ dependencies = [ [[package]] name = "staging-xcm-executor" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "environmental", "frame-benchmarking", @@ -13295,7 +13346,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -13333,12 +13384,12 @@ dependencies = [ [[package]] name = "substrate-build-script-utils" version = "3.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" [[package]] name = "substrate-frame-rpc-system" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-system-rpc-runtime-api", "futures", @@ -13357,7 +13408,7 @@ dependencies = [ [[package]] name = "substrate-prometheus-endpoint" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "hyper", "log", @@ -13369,7 +13420,7 @@ dependencies = [ [[package]] name = "substrate-rpc-client" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "jsonrpsee", @@ -13382,7 +13433,7 @@ dependencies = [ [[package]] name = "substrate-state-trie-migration-rpc" version = "4.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -13399,7 +13450,7 @@ dependencies = [ [[package]] name = "substrate-test-client" version = "2.0.1" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "async-trait", @@ -13425,7 +13476,7 @@ dependencies = [ [[package]] name = "substrate-test-runtime" version = "2.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "array-bytes", "frame-executive", @@ -13468,7 +13519,7 @@ dependencies = [ [[package]] name = "substrate-test-runtime-client" version = "2.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "futures", "sc-block-builder", @@ -13486,7 +13537,7 @@ dependencies = [ [[package]] name = "substrate-wasm-builder" version = "5.0.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "ansi_term", "build-helper", @@ -13535,9 +13586,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.38" +version = "2.0.39" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" +checksum = "23e78b90f2fcf45d3e842032ce32e3f2d1545ba6636271dcbf24fa306d87be7a" dependencies = [ "proc-macro2", "quote", @@ -13611,15 +13662,15 @@ dependencies = [ "cfg-if", "fastrand 2.0.1", "redox_syscall 0.4.1", - "rustix 0.38.21", + "rustix 0.38.25", "windows-sys 0.48.0", ] [[package]] name = "termcolor" -version = "1.3.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6093bad37da69aab9d123a8091e4be0aa4a03e4d601ec641c327398315f62b64" +checksum = "ff1bc3d3f05aff0403e8ac0d92ced918ec05b666a43f83297ccef5bea8a3d449" dependencies = [ "winapi-util", ] @@ -13641,22 +13692,22 @@ dependencies = [ [[package]] name = "thiserror-core" -version = "1.0.38" +version = "1.0.50" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d97345f6437bb2004cd58819d8a9ef8e36cdd7661c2abc4bbde0a7c40d9f497" +checksum = "c001ee18b7e5e3f62cbf58c7fe220119e68d902bb7443179c0c8aef30090e999" dependencies = [ "thiserror-core-impl", ] [[package]] name = "thiserror-core-impl" -version = "1.0.38" +version = "1.0.50" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10ac1c5050e43014d16b2f94d0d2ce79e65ffdd8b38d8048f9c8f6a8a6da62ac" +checksum = "e4c60d69f36615a077cc7663b9cb8e42275722d23e58a7fa3d2c7f2915d09d04" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.39", ] [[package]] @@ -13667,7 +13718,7 @@ checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -13813,9 +13864,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.33.0" +version = "1.34.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653" +checksum = "d0c014766411e834f7af5b8f4cf46257aab4036ca95e9d2c144a10f59ad6f5b9" dependencies = [ "backtrace", "bytes", @@ -13832,13 +13883,13 @@ dependencies = [ [[package]] name = "tokio-macros" -version = "2.1.0" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" +checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -13858,7 +13909,7 @@ version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" dependencies = [ - "rustls 0.21.8", + "rustls 0.21.9", "tokio", ] @@ -13993,7 +14044,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -14019,7 +14070,7 @@ dependencies = [ [[package]] name = "tracing-gum" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "coarsetime", "polkadot-node-jaeger", @@ -14031,13 +14082,13 @@ dependencies = [ [[package]] name = "tracing-gum-proc-macro" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "expander 2.0.0", "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -14161,7 +14212,7 @@ checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" [[package]] name = "try-runtime-cli" version = "0.10.0-dev" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "async-trait", "clap", @@ -14345,12 +14396,12 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "url" -version = "2.4.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "143b538f18257fac9cad154828a57c6bf5157e1aa604d4816b5995bf6de87ae5" +checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" dependencies = [ "form_urlencoded", - "idna 0.4.0", + "idna 0.5.0", "percent-encoding", ] @@ -14362,11 +14413,11 @@ checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" [[package]] name = "uuid" -version = "1.5.0" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" +checksum = "5e395fcf16a7a3d8127ec99782007af141946b4795001f876d54fb0d55978560" dependencies = [ - "getrandom 0.2.10", + "getrandom 0.2.11", "serde", ] @@ -14442,9 +14493,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.87" +version = "0.2.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" +checksum = "0ed0d4f68a3015cc185aff4db9506a015f4b96f95303897bfa23f846db54064e" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -14452,24 +14503,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.87" +version = "0.2.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" +checksum = "1b56f625e64f3a1084ded111c4d5f477df9f8c92df113852fa5a374dbda78826" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.37" +version = "0.4.39" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" +checksum = "ac36a15a220124ac510204aec1c3e5db8a22ab06fd6706d881dc6149f8ed9a12" dependencies = [ "cfg-if", "js-sys", @@ -14479,9 +14530,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.87" +version = "0.2.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" +checksum = "0162dbf37223cd2afce98f3d0785506dcb8d266223983e4b5b525859e6e182b2" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -14489,22 +14540,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.87" +version = "0.2.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" +checksum = "f0eb82fcb7930ae6219a7ecfd55b217f5f0893484b7a13022ebb2b2bf20b5283" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.87" +version = "0.2.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" +checksum = "7ab9b36309365056cd639da3134bf87fa8f3d86008abf99e612384a6eecd459f" [[package]] name = "wasm-instrument" @@ -14817,9 +14868,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.64" +version = "0.3.65" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" +checksum = "5db499c5f66323272151db0e666cd34f78617522fb0c1604d31a27c50c206a85" dependencies = [ "js-sys", "wasm-bindgen", @@ -14856,9 +14907,9 @@ dependencies = [ [[package]] name = "webpki-roots" -version = "0.25.2" +version = "0.25.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14247bb57be4f377dfb94c72830b8ce8fc6beac03cf4bf7b9732eadd414123fc" +checksum = "1778a42e8b3b90bff8d0f5032bf22250792889a5cdc752aa0020c84abe3aaf10" [[package]] name = "webrtc" @@ -15071,7 +15122,7 @@ dependencies = [ [[package]] name = "westend-runtime" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "binary-merkle-tree", "bitvec", @@ -15170,7 +15221,7 @@ dependencies = [ [[package]] name = "westend-runtime-constants" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support", "polkadot-primitives", @@ -15190,7 +15241,7 @@ dependencies = [ "either", "home", "once_cell", - "rustix 0.38.21", + "rustix 0.38.25", ] [[package]] @@ -15277,6 +15328,15 @@ dependencies = [ "windows-targets 0.48.5", ] +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.0", +] + [[package]] name = "windows-targets" version = "0.42.2" @@ -15307,6 +15367,21 @@ dependencies = [ "windows_x86_64_msvc 0.48.5", ] +[[package]] +name = "windows-targets" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a18201040b24831fbb9e4eb208f8892e1f50a37feb53cc7ff887feb8f50e7cd" +dependencies = [ + "windows_aarch64_gnullvm 0.52.0", + "windows_aarch64_msvc 0.52.0", + "windows_i686_gnu 0.52.0", + "windows_i686_msvc 0.52.0", + "windows_x86_64_gnu 0.52.0", + "windows_x86_64_gnullvm 0.52.0", + "windows_x86_64_msvc 0.52.0", +] + [[package]] name = "windows_aarch64_gnullvm" version = "0.42.2" @@ -15319,6 +15394,12 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb7764e35d4db8a7921e09562a0304bf2f93e0a51bfccee0bd0bb0b666b015ea" + [[package]] name = "windows_aarch64_msvc" version = "0.42.2" @@ -15331,6 +15412,12 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbaa0368d4f1d2aaefc55b6fcfee13f41544ddf36801e793edbbfd7d7df075ef" + [[package]] name = "windows_i686_gnu" version = "0.42.2" @@ -15343,6 +15430,12 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" +[[package]] +name = "windows_i686_gnu" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a28637cb1fa3560a16915793afb20081aba2c92ee8af57b4d5f28e4b3e7df313" + [[package]] name = "windows_i686_msvc" version = "0.42.2" @@ -15355,6 +15448,12 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" +[[package]] +name = "windows_i686_msvc" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffe5e8e31046ce6230cc7215707b816e339ff4d4d67c65dffa206fd0f7aa7b9a" + [[package]] name = "windows_x86_64_gnu" version = "0.42.2" @@ -15367,6 +15466,12 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6fa32db2bc4a2f5abeacf2b69f7992cd09dca97498da74a151a3132c26befd" + [[package]] name = "windows_x86_64_gnullvm" version = "0.42.2" @@ -15379,6 +15484,12 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a657e1e9d3f514745a572a6846d3c7aa7dbe1658c056ed9c3344c4109a6949e" + [[package]] name = "windows_x86_64_msvc" version = "0.42.2" @@ -15391,11 +15502,17 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" + [[package]] name = "winnow" -version = "0.5.18" +version = "0.5.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "176b6138793677221d420fd2f0aeeced263f197688b36484660da767bca2fa32" +checksum = "829846f3e3db426d4cee4510841b71a8e58aa2a76b1132579487ae430ccd9c7b" dependencies = [ "memchr", ] @@ -15482,12 +15599,12 @@ dependencies = [ [[package]] name = "xcm-procedural" version = "1.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#f60318f68687e601c47de5ad5ca88e2c3f8139a7" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "Inflector", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] @@ -15531,11 +15648,11 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.7.21" +version = "0.7.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "686b7e407015242119c33dab17b8f61ba6843534de936d94368856528eae4dcc" +checksum = "e97e415490559a91254a2979b4829267a57d2fcd741a98eee8b722fb57289aa0" dependencies = [ - "zerocopy-derive 0.7.21", + "zerocopy-derive 0.7.26", ] [[package]] @@ -15546,25 +15663,25 @@ checksum = "855e0f6af9cd72b87d8a6c586f3cb583f5cdcc62c2c80869d8cd7e96fdf7ee20" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "zerocopy-derive" -version = "0.7.21" +version = "0.7.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "020f3dfe25dfc38dfea49ce62d5d45ecdd7f0d8a724fa63eb36b6eba4ec76806" +checksum = "dd7e48ccf166952882ca8bd778a43502c64f33bf94c12ebe2a7f08e5a0f6689f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] name = "zeroize" -version = "1.6.0" +version = "1.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" +checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" dependencies = [ "zeroize_derive", ] @@ -15577,7 +15694,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.39", ] [[package]] diff --git a/e2e/package-lock.json b/e2e/package-lock.json index 710887d8ab..543596b627 100644 --- a/e2e/package-lock.json +++ b/e2e/package-lock.json @@ -257,6 +257,14 @@ "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, + "node_modules/@fastify/busboy": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.1.0.tgz", + "integrity": "sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA==", + "engines": { + "node": ">=14" + } + }, "node_modules/@frequency-chain/api-augment": { "version": "0.0.0", "resolved": "file:../js/api-augment/dist/frequency-chain-api-augment-0.0.0.tgz", @@ -2159,17 +2167,6 @@ "node": ">=6.14.2" } }, - "node_modules/busboy": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/busboy/-/busboy-1.6.0.tgz", - "integrity": "sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==", - "dependencies": { - "streamsearch": "^1.1.0" - }, - "engines": { - "node": ">=10.16.0" - } - }, "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", @@ -5714,14 +5711,6 @@ "resolved": "https://registry.npmjs.org/get-iterator/-/get-iterator-1.0.2.tgz", "integrity": "sha512-v+dm9bNVfOYsY1OrhaCrmyOcYoSeVvbt+hHZ0Au+T+p1y+0Uyj9aMaGIeUTT6xdpRbWzDeYKvfOslPhggQMcsg==" }, - "node_modules/streamsearch": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/streamsearch/-/streamsearch-1.1.0.tgz", - "integrity": "sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==", - "engines": { - "node": ">=10.0.0" - } - }, "node_modules/string_decoder": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", @@ -6020,11 +6009,11 @@ } }, "node_modules/undici": { - "version": "5.25.2", - "resolved": "https://registry.npmjs.org/undici/-/undici-5.25.2.tgz", - "integrity": "sha512-tch8RbCfn1UUH1PeVCXva4V8gDpGAud/w0WubD6sHC46vYQ3KDxL+xv1A2UxK0N6jrVedutuPHxe1XIoqerwMw==", + "version": "5.28.1", + "resolved": "https://registry.npmjs.org/undici/-/undici-5.28.1.tgz", + "integrity": "sha512-xcIIvj1LOQH9zAL54iWFkuDEaIVEjLrru7qRpa3GrEEHk6OBhb/LycuUY2m7VCcTuDeLziXCxobQVyKExyGeIA==", "dependencies": { - "busboy": "^1.6.0" + "@fastify/busboy": "^2.0.0" }, "engines": { "node": ">=14.0" diff --git a/pallets/capacity/src/benchmarking.rs b/pallets/capacity/src/benchmarking.rs index c40335fd17..ef52666b36 100644 --- a/pallets/capacity/src/benchmarking.rs +++ b/pallets/capacity/src/benchmarking.rs @@ -25,7 +25,7 @@ pub fn create_funded_account( let user = account(string, n, SEED); whitelist_account!(user); let balance = T::Currency::minimum_balance() * balance_factor.into(); - let _ = T::Currency::set_balance(&user, balance); + T::Currency::set_balance(&user, balance); assert_eq!(T::Currency::balance(&user), balance.into()); user } @@ -99,7 +99,7 @@ benchmarks! { target_details.deposit(staking_amount, capacity_amount); capacity_details.deposit(&staking_amount, &capacity_amount); - let _ = Capacity::::set_staking_account(&caller.clone(), &staking_account); + Capacity::::set_staking_account(&caller.clone(), &staking_account).expect("Failed to set staking account"); Capacity::::set_target_details_for(&caller.clone(), target, target_details); Capacity::::set_capacity_for(target, capacity_details); diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index b41371da2b..2b29306352 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -494,16 +494,16 @@ impl Pallet { staker: &T::AccountId, staking_account: &StakingAccountDetails, ) -> DispatchResult { - let _ = - T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total)?; + T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, staking_account.total)?; StakingAccountLedger::::insert(staker, staking_account); Ok(()) } /// Deletes staking account details - fn delete_staking_account(staker: &T::AccountId) { - let _ = T::Currency::thaw(&FreezeReason::Staked.into(), staker); + fn delete_staking_account(staker: &T::AccountId) -> DispatchResult { + T::Currency::thaw(&FreezeReason::Staked.into(), staker)?; StakingAccountLedger::::remove(&staker); + Ok(()) } /// If the staking account total is zero we reap storage, otherwise set the account to the new details. @@ -512,7 +512,7 @@ impl Pallet { staking_account: &StakingAccountDetails, ) -> DispatchResult { if staking_account.total.is_zero() { - Self::delete_staking_account(&staker); + Self::delete_staking_account(&staker)?; } else { Self::set_staking_account(&staker, &staking_account)?; } diff --git a/pallets/capacity/src/tests/other_tests.rs b/pallets/capacity/src/tests/other_tests.rs index 387baa0f94..c964777634 100644 --- a/pallets/capacity/src/tests/other_tests.rs +++ b/pallets/capacity/src/tests/other_tests.rs @@ -73,7 +73,8 @@ fn set_staking_account_is_succesful() { let mut staking_account = StakingAccountDetails::::default(); staking_account.deposit(55); - Capacity::set_staking_account(&staker, &staking_account); + Capacity::set_staking_account(&staker, &staking_account) + .expect("Failed to set staking account"); let frozen_balance = ::Currency::balance_frozen(&(FreezeReason::Staked).into(), &staker); diff --git a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs index 5f0b316c49..ec3cdf84cf 100644 --- a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs +++ b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs @@ -18,7 +18,8 @@ fn withdraw_unstaked_happy_path() { staking_account.deposit(10); assert_eq!(true, staking_account.set_unlock_chunks(&unlocks)); assert_eq!(10u64, staking_account.total); - Capacity::set_staking_account(&staker, &staking_account.into()); + Capacity::set_staking_account(&staker, &staking_account.into()) + .expect("Failed to set staking account"); let starting_account = Capacity::get_staking_account_for(&staker).unwrap(); @@ -50,7 +51,8 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { let new_unlocks: Vec<(u32, u32)> = vec![(1u32, 2u32), (2u32, 3u32), (3u32, 4u32)]; assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); - Capacity::set_staking_account(&staker, &staking_account); + Capacity::set_staking_account(&staker, &staking_account) + .expect("Failed to set staking account"); assert_eq!( 10u64, ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker) @@ -81,7 +83,8 @@ fn withdraw_unstaked_cleans_up_storage_and_removes_all_locks_if_no_stake_left() assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); let staker = 500; - Capacity::set_staking_account(&staker, &staking_account); + Capacity::set_staking_account(&staker, &staking_account) + .expect("Failed to set staking account"); assert_ok!(Capacity::set_epoch_length(RuntimeOrigin::root(), 10)); // Epoch Length = 10 and UnstakingThawPeriod = 2 (epochs) @@ -99,7 +102,8 @@ fn withdraw_unstaked_cannot_withdraw_if_no_unstaking_chunks() { let staker = 500; let mut staking_account = StakingAccountDetails::::default(); staking_account.deposit(10); - Capacity::set_staking_account(&staker, &staking_account); + Capacity::set_staking_account(&staker, &staking_account) + .expect("Failed to set staking account"); assert_noop!( Capacity::withdraw_unstaked(RuntimeOrigin::signed(500)), Error::::NoUnstakedTokensAvailable @@ -117,7 +121,8 @@ fn withdraw_unstaked_cannot_withdraw_if_unstaking_chunks_not_thawed() { let new_unlocks: Vec<(u32, u32)> = vec![(1u32, 3u32), (2u32, 40u32), (3u32, 9u32)]; assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); - Capacity::set_staking_account(&staker, &staking_account); + Capacity::set_staking_account(&staker, &staking_account) + .expect("Failed to set staking account"); run_to_block(2); assert_noop!( From da2296f1fda7c778bbbab68497e37bcf0dbe13fb Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 28 Nov 2023 09:58:50 -0700 Subject: [PATCH 22/75] fix: capacity benchmarking should handle errors from set_staking_account() --- pallets/capacity/src/benchmarking.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pallets/capacity/src/benchmarking.rs b/pallets/capacity/src/benchmarking.rs index ef52666b36..ffe28868fa 100644 --- a/pallets/capacity/src/benchmarking.rs +++ b/pallets/capacity/src/benchmarking.rs @@ -65,7 +65,7 @@ benchmarks! { let new_unlocks: Vec<(u32, u32)> = Vec::from([(50u32, 3u32), (50u32, 5u32)]); assert_eq!(true, staking_account.set_unlock_chunks(&new_unlocks)); - let _ = Capacity::::set_staking_account(&caller.clone(), &staking_account); + Capacity::::set_staking_account(&caller.clone(), &staking_account).expect("Failed to set staking account"); CurrentEpoch::::set(T::EpochNumber::from(5u32)); }: _ (RawOrigin::Signed(caller.clone())) From 568582b8164e3a73588d75779403f05722b40032 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 4 Dec 2023 12:11:49 -0700 Subject: [PATCH 23/75] fix: changes for errors from merge from main --- e2e/package-lock.json | 2 +- pallets/capacity/src/benchmarking.rs | 2 +- pallets/capacity/src/lib.rs | 10 ++++------ pallets/capacity/src/tests/other_tests.rs | 2 +- .../capacity/src/tests/stake_and_deposit_tests.rs | 7 ++----- pallets/capacity/src/tests/unstaking_tests.rs | 12 ++++++++---- .../capacity/src/tests/withdraw_unstaked_tests.rs | 15 ++++++--------- 7 files changed, 23 insertions(+), 27 deletions(-) diff --git a/e2e/package-lock.json b/e2e/package-lock.json index 543596b627..7cb7213c20 100644 --- a/e2e/package-lock.json +++ b/e2e/package-lock.json @@ -268,7 +268,7 @@ "node_modules/@frequency-chain/api-augment": { "version": "0.0.0", "resolved": "file:../js/api-augment/dist/frequency-chain-api-augment-0.0.0.tgz", - "integrity": "sha512-5KaqfY1M25g+JRlCHXEiKpKjimlsGOZPXa1qU/FIW27NKKNMykAw08MpUvukn3RjgOu9khWe8fhxTnCK1lVtiw==", + "integrity": "sha512-JmUFMSfpfcDxIgS+IsBpZsMAQZoWJaKu/SV9YTvieviX7UJkFCsjpY9nwWXB17M+2aUMtdh9GCM6nUddLp41NQ==", "license": "Apache-2.0", "dependencies": { "@polkadot/api": "^10.9.1", diff --git a/pallets/capacity/src/benchmarking.rs b/pallets/capacity/src/benchmarking.rs index f9a1debf92..f7a3294015 100644 --- a/pallets/capacity/src/benchmarking.rs +++ b/pallets/capacity/src/benchmarking.rs @@ -2,7 +2,7 @@ use super::*; use crate::Pallet as Capacity; use frame_benchmarking::{account, benchmarks, whitelist_account}; -use frame_support::assert_ok; +use frame_support::{assert_ok, BoundedVec}; use frame_system::RawOrigin; use parity_scale_codec::alloc::vec::Vec; diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index cf61551ce1..1ffbf3b146 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -511,7 +511,7 @@ impl Pallet { .active .checked_add(&unlock_chunks_total::(&unlocks)) .ok_or(ArithmeticError::Overflow)?; - T::Currency::set_freeze(&FreezeReason::Staked, staker, total_to_lock); + T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, total_to_lock)?; Self::set_staking_account(staker, staking_account); Ok(()) } @@ -522,8 +522,6 @@ impl Pallet { } else { StakingAccountLedger::::insert(staker, staking_account); } - - Ok(()) } /// Sets target account details. @@ -581,7 +579,7 @@ impl Pallet { staker: &T::AccountId, proposed_amount: BalanceOf, ) -> BalanceOf { - let account_balance = T::Currency::free_balance(&staker); + let account_balance = T::Currency::balance(&staker); account_balance .saturating_sub(T::MinimumTokenBalance::get()) .min(proposed_amount) @@ -608,9 +606,9 @@ impl Pallet { let staking_account = Self::get_staking_account_for(staker).unwrap_or_default(); let total_locked = staking_account.active.saturating_add(total_unlocking); if total_locked.is_zero() { - T::Currency::remove_lock(STAKING_ID, &staker); + T::Currency::thaw(&FreezeReason::Staked.into(), staker)?; } else { - T::Currency::set_lock(STAKING_ID, &staker, total_locked, WithdrawReasons::all()); + T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, total_locked)?; } Ok(amount_withdrawn) } diff --git a/pallets/capacity/src/tests/other_tests.rs b/pallets/capacity/src/tests/other_tests.rs index 9b1f501a66..91efa28550 100644 --- a/pallets/capacity/src/tests/other_tests.rs +++ b/pallets/capacity/src/tests/other_tests.rs @@ -9,7 +9,7 @@ use common_primitives::{capacity::Nontransferable, msa::MessageSourceId}; use crate::{ BalanceOf, CapacityDetails, Config, CurrentEpoch, CurrentEpochInfo, EpochInfo, FreezeReason, - StakingAccountDetails, StakingTargetDetails, + StakingDetails, StakingTargetDetails, }; use super::{mock::*, testing_utils::*}; diff --git a/pallets/capacity/src/tests/stake_and_deposit_tests.rs b/pallets/capacity/src/tests/stake_and_deposit_tests.rs index ac124831e1..08b2ca18d7 100644 --- a/pallets/capacity/src/tests/stake_and_deposit_tests.rs +++ b/pallets/capacity/src/tests/stake_and_deposit_tests.rs @@ -1,7 +1,5 @@ use super::{mock::*, testing_utils::*}; -use crate::{ - BalanceOf, CapacityDetails, Config, Error, Event, FreezeReason, StakingDetails, -}; +use crate::{BalanceOf, CapacityDetails, Config, Error, Event, FreezeReason, StakingDetails}; use common_primitives::{capacity::Nontransferable, msa::MessageSourceId}; use frame_support::{assert_noop, assert_ok, traits::fungible::InspectFreeze}; use sp_runtime::ArithmeticError; @@ -412,8 +410,7 @@ fn stake_when_there_are_unlocks_sets_lock_correctly() { assert_ok!(Capacity::stake(RuntimeOrigin::signed(staker), target2, 20)); // should all still be locked. - assert_eq!(Balances::locks(&staker)[0].amount, 40); - assert_eq!(Balances::locks(&staker)[0].reasons, WithdrawReasons::all().into()); + assert_eq!(Balances::balance_frozen(&FreezeReason::Staked.into(), &staker), 40); }) } diff --git a/pallets/capacity/src/tests/unstaking_tests.rs b/pallets/capacity/src/tests/unstaking_tests.rs index 8e930cc141..fc7674397b 100644 --- a/pallets/capacity/src/tests/unstaking_tests.rs +++ b/pallets/capacity/src/tests/unstaking_tests.rs @@ -1,8 +1,13 @@ use super::{mock::*, testing_utils::*}; use crate as pallet_capacity; -use crate::{CapacityDetails, StakingDetails, StakingTargetDetails, StakingType, UnlockChunk}; +use crate::{ + CapacityDetails, FreezeReason, StakingDetails, StakingTargetDetails, StakingType, UnlockChunk, +}; use common_primitives::msa::MessageSourceId; -use frame_support::{assert_noop, assert_ok, traits::Get}; +use frame_support::{ + assert_noop, assert_ok, + traits::{fungible::InspectFreeze, Get}, +}; use pallet_capacity::{BalanceOf, Config, Error, Event}; use sp_core::bounded::BoundedVec; @@ -174,8 +179,7 @@ fn unstaking_everything_reaps_staking_account() { run_to_block(1); // unstake everything assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 20)); - assert_eq!(1, Balances::locks(&staker).len()); - assert_eq!(20u64, Balances::locks(&staker)[0].amount); + assert_eq!(20u64, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); // it should reap the staking account right away assert!(Capacity::get_staking_account_for(&staker).is_none()); diff --git a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs index e7eefdd6d9..82095a4b6a 100644 --- a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs +++ b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs @@ -3,11 +3,11 @@ use super::{ testing_utils::{register_provider, run_to_block}, }; use crate::{ - unlock_chunks_from_vec, CurrentEpoch, CurrentEpochInfo, EpochInfo, Error, Event, UnstakeUnlocks, - self as pallet_capacity, FreezeReason, StakingDetails, + self as pallet_capacity, unlock_chunks_from_vec, CurrentEpoch, CurrentEpochInfo, EpochInfo, + Error, Event, FreezeReason, UnstakeUnlocks, }; use frame_support::{assert_noop, assert_ok, traits::fungible::InspectFreeze}; -use pallet_capacity::{BalanceOf, Config, Error, Event}; +use pallet_capacity::Config; #[test] fn withdraw_unstaked_happy_path() { @@ -47,21 +47,18 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { run_to_block(1); assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 1)); - assert_eq!(1, Balances::locks(&staker).len()); - assert_eq!(20u64, Balances::locks(&staker)[0].amount); + assert_eq!(20, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); // thaw period in mock is 2 Epochs * 10 blocks = 20 blocks. run_to_block(21); assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 2)); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); - assert_eq!(1, Balances::locks(&staker).len()); - assert_eq!(19u64, Balances::locks(&staker)[0].amount); + assert_eq!(19u64, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); run_to_block(41); assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 3)); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); - assert_eq!(1, Balances::locks(&staker).len()); - assert_eq!(17u64, Balances::locks(&staker)[0].amount); + assert_eq!(17u64, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); run_to_block(61); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); From 60520424559f9cc4e8dae34421920d497bdde7d5 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 4 Dec 2023 13:03:01 -0700 Subject: [PATCH 24/75] fix: Update spec_version to 66 --- runtime/frequency/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index a8728475db..baebc5cd1b 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -262,7 +262,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("frequency"), impl_name: create_runtime_str!("frequency"), authoring_version: 1, - spec_version: 65, + spec_version: 66, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, @@ -276,7 +276,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("frequency-rococo"), impl_name: create_runtime_str!("frequency"), authoring_version: 1, - spec_version: 65, + spec_version: 66, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, From 9384ed3b96c9b1843bd1d0a13c9031c63cd9838b Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 5 Dec 2023 14:58:41 -0700 Subject: [PATCH 25/75] Fix: thaw error handling in delete_lock function --- pallets/time-release/src/lib.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 83b49b9923..3c2ff9e2d3 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -449,7 +449,14 @@ impl Pallet { } fn delete_lock(who: &T::AccountId) { - let _ = T::Currency::thaw(&FreezeReason::NotYetVested.into(), who); + // thaw returns a DispatchResult from frame::balances::lib.rs::update_freezes() + // which returns Ok(()), but mutate()->try_mutate_account() can return an error if: + // 1. account does not exist + // 2. the closure passed to mutate_account() returns an error (data manipulation error, unlikely) + // 3. there is an error in increasing or decreasing the providers or consumers + // 4. the account balance < ED, and reserved balance is zero ==> dust removal + // We can ignore the error here b/c no matter what the lock will be deleted. + T::Currency::thaw(&FreezeReason::NotYetVested.into(), who).ok(); } fn set_schedules_for( From c77dd4141dc44b2d6b5490fa3c8b3e8c80b10013 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 5 Dec 2023 15:50:26 -0700 Subject: [PATCH 26/75] fix: Update spec_version to 67 --- runtime/frequency/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 91dc53e762..68b8d13515 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -258,7 +258,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("frequency"), impl_name: create_runtime_str!("frequency"), authoring_version: 1, - spec_version: 66, + spec_version: 67, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, @@ -272,7 +272,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("frequency-rococo"), impl_name: create_runtime_str!("frequency"), authoring_version: 1, - spec_version: 66, + spec_version: 67, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, From e9563a6bc3e260b00f4f2ed68b82474a18ca623c Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 6 Dec 2023 13:39:03 -0700 Subject: [PATCH 27/75] fix: refactor FreezeReason to remove unnecessary values --- e2e/package-lock.json | 2 +- pallets/capacity/src/lib.rs | 4 +--- pallets/time-release/src/lib.rs | 6 ++---- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/e2e/package-lock.json b/e2e/package-lock.json index 7cb7213c20..97def836a4 100644 --- a/e2e/package-lock.json +++ b/e2e/package-lock.json @@ -268,7 +268,7 @@ "node_modules/@frequency-chain/api-augment": { "version": "0.0.0", "resolved": "file:../js/api-augment/dist/frequency-chain-api-augment-0.0.0.tgz", - "integrity": "sha512-JmUFMSfpfcDxIgS+IsBpZsMAQZoWJaKu/SV9YTvieviX7UJkFCsjpY9nwWXB17M+2aUMtdh9GCM6nUddLp41NQ==", + "integrity": "sha512-k5W6xrluJIjaNwqzWgTs7pk3g9MtMiar9ktIfI/QXEF0TsGNjJ+FkkmtaYb3g9HUDFsOTdZXC78Cx0Yo+kbgMw==", "license": "Apache-2.0", "dependencies": { "@polkadot/api": "^10.9.1", diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 1ffbf3b146..7c84922af1 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -102,13 +102,11 @@ pub mod pallet { use sp_runtime::traits::{AtLeast32BitUnsigned, MaybeDisplay}; /// A reason for freezing funds. + /// Creates a freeze reason for this pallet that is aggregated by `construct_runtime`. #[pallet::composite_enum] pub enum FreezeReason { /// The account has staked tokens to the Frequency network. - #[codec(index = 0)] Staked, - /// Funds are currently locked and are not yet liquid. - NotYetVested, } /// the storage version for this pallet diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 3c2ff9e2d3..62f2fb8fb2 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -90,15 +90,13 @@ pub mod module { ); /// A reason for freezing funds. + /// Creates a freeze reason for this pallet that is aggregated by `construct_runtime`. #[pallet::composite_enum] pub enum FreezeReason { - #[codec(index = 0)] - /// Funds are staked. - Staked, /// Funds are currently locked and are not yet liquid. NotYetVested, } - // use crate::pallet_capacity::FreezeReason; + #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. From 650e59443ce526d533b827c38f7923aaa98930e9 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 6 Dec 2023 16:22:15 -0700 Subject: [PATCH 28/75] fix: handle errors from set_freeze in building genesis config; update MaxFreezes; update max values --- pallets/capacity/src/tests/mock.rs | 8 ++++---- pallets/frequency-tx-payment/src/tests/mock.rs | 8 ++++---- pallets/time-release/src/lib.rs | 7 ++----- pallets/time-release/src/mock.rs | 8 ++++---- runtime/common/src/constants.rs | 6 +++--- runtime/frequency/src/lib.rs | 2 +- 6 files changed, 18 insertions(+), 21 deletions(-) diff --git a/pallets/capacity/src/tests/mock.rs b/pallets/capacity/src/tests/mock.rs index daeb995b10..75b7ad9314 100644 --- a/pallets/capacity/src/tests/mock.rs +++ b/pallets/capacity/src/tests/mock.rs @@ -55,7 +55,9 @@ impl frame_system::Config for Test { } impl pallet_balances::Config for Test { + type MaxReserves = (); type ReserveIdentifier = [u8; 8]; + type MaxLocks = ConstU32<10>; type Balance = u64; type RuntimeEvent = RuntimeEvent; type DustRemoval = (); @@ -63,10 +65,8 @@ impl pallet_balances::Config for Test { type AccountStore = System; type WeightInfo = (); type FreezeIdentifier = RuntimeFreezeReason; - type MaxLocks = ConstU32<50>; - type MaxReserves = ConstU32<50>; - type MaxFreezes = ConstU32<50>; - type MaxHolds = ConstU32<50>; + type MaxFreezes = ConstU32<1>; + type MaxHolds = ConstU32<0>; type RuntimeHoldReason = (); } diff --git a/pallets/frequency-tx-payment/src/tests/mock.rs b/pallets/frequency-tx-payment/src/tests/mock.rs index 1d28d74cfc..3130a398d8 100644 --- a/pallets/frequency-tx-payment/src/tests/mock.rs +++ b/pallets/frequency-tx-payment/src/tests/mock.rs @@ -85,15 +85,15 @@ impl pallet_balances::Config for Test { type DustRemoval = (); type RuntimeEvent = RuntimeEvent; type Balance = u64; + type MaxLocks = (); type WeightInfo = (); type ReserveIdentifier = [u8; 8]; type ExistentialDeposit = ConstU64<1>; type AccountStore = System; - type MaxLocks = ConstU32<50>; - type MaxReserves = ConstU32<50>; - type MaxFreezes = ConstU32<50>; - type MaxHolds = ConstU32<50>; + type MaxReserves = (); type FreezeIdentifier = RuntimeFreezeReason; + type MaxFreezes = ConstU32<1>; + type MaxHolds = ConstU32<0>; type RuntimeHoldReason = (); } diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 62f2fb8fb2..41529c3b83 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -228,11 +228,8 @@ pub mod module { "Account do not have enough balance" ); - let _ = T::Currency::set_freeze( - &FreezeReason::NotYetVested.into(), - who, - total_amount, - ); + T::Currency::set_freeze(&FreezeReason::NotYetVested.into(), who, total_amount) + .expect("Failed to set freeze"); ReleaseSchedules::::insert(who, bounded_schedules); }); } diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index 2e9d89f7cc..4e42ec48a7 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -46,13 +46,13 @@ impl pallet_balances::Config for Test { type RuntimeEvent = RuntimeEvent; type ExistentialDeposit = ConstU64<1>; type AccountStore = frame_system::Pallet; + type MaxLocks = (); + type MaxReserves = (); type ReserveIdentifier = [u8; 8]; type WeightInfo = (); type FreezeIdentifier = RuntimeFreezeReason; - type MaxLocks = ConstU32<50>; - type MaxReserves = ConstU32<50>; - type MaxFreezes = ConstU32<50>; - type MaxHolds = ConstU32<50>; + type MaxFreezes = ConstU32<1>; + type MaxHolds = ConstU32<0>; type RuntimeHoldReason = (); } diff --git a/runtime/common/src/constants.rs b/runtime/common/src/constants.rs index f884133429..c59bc7b099 100644 --- a/runtime/common/src/constants.rs +++ b/runtime/common/src/constants.rs @@ -68,6 +68,7 @@ pub const MAXIMUM_BLOCK_WEIGHT: Weight = Weight::from_parts(WEIGHT_REF_TIME_PER_ .saturating_div(2) .set_proof_size(cumulus_primitives_core::relay_chain::MAX_POV_SIZE as u64); pub type ZERO = ConstU32<0>; +pub type TWO = ConstU32<2>; pub type FIFTY = ConstU32<50>; pub type HUNDRED = ConstU32<100>; @@ -135,9 +136,8 @@ pub type AuthorshipUncleGenerations = ZERO; // --- Balances Pallet --- pub type BalancesMaxLocks = FIFTY; pub type BalancesMaxReserves = FIFTY; -pub type BalancesMaxFreezes = FIFTY; -pub type BalancesMaxHolds = FIFTY; -// -end- Balances Pallet --- +pub type BalancesMaxFreezes = TWO; // capacity + time-release + // -end- Balances Pallet --- // --- Scheduler Pallet --- pub type SchedulerMaxScheduledPerBlock = FIFTY; diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 68b8d13515..59bb186866 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -506,7 +506,7 @@ impl pallet_balances::Config for Runtime { type WeightInfo = weights::pallet_balances::SubstrateWeight; type MaxReserves = BalancesMaxReserves; type ReserveIdentifier = [u8; 8]; - type MaxHolds = BalancesMaxHolds; + type MaxHolds = ConstU32<0>; type MaxFreezes = BalancesMaxFreezes; type RuntimeHoldReason = RuntimeHoldReason; type FreezeIdentifier = RuntimeFreezeReason; From b95c4cea84fd6cf542ca547ee35c1ed8689948aa Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 7 Dec 2023 08:15:00 -0700 Subject: [PATCH 29/75] fix: propagate errors correctly from set_freeze/thaw --- pallets/time-release/src/lib.rs | 36 ++++++++++++++++++--------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 41529c3b83..0284fdd8dd 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -37,6 +37,7 @@ )] use frame_support::{ + dispatch::DispatchResult, ensure, pallet_prelude::*, traits::{ @@ -51,7 +52,7 @@ use frame_support::{ use frame_system::{ensure_root, ensure_signed, pallet_prelude::*}; use sp_runtime::{ traits::{BlockNumberProvider, CheckedAdd, StaticLookup, Zero}, - ArithmeticError, DispatchResult, + ArithmeticError, }; use sp_std::vec::Vec; @@ -252,7 +253,7 @@ pub mod module { #[pallet::weight(T::WeightInfo::claim(::MaxReleaseSchedules::get() / 2))] pub fn claim(origin: OriginFor) -> DispatchResult { let who = ensure_signed(origin)?; - let locked_amount = Self::do_claim(&who); + let locked_amount = Self::do_claim(&who)?; Self::deposit_event(Event::Claimed { who, amount: locked_amount }); Ok(()) @@ -337,7 +338,7 @@ pub mod module { ) -> DispatchResult { ensure_signed(origin)?; let who = T::Lookup::lookup(dest)?; - let locked_amount = Self::do_claim(&who); + let locked_amount = Self::do_claim(&who)?; Self::deposit_event(Event::Claimed { who, amount: locked_amount }); Ok(()) @@ -346,15 +347,15 @@ pub mod module { } impl Pallet { - fn do_claim(who: &T::AccountId) -> BalanceOf { + fn do_claim(who: &T::AccountId) -> Result, DispatchError> { let locked = Self::prune_and_get_locked_balance(who); if locked.is_zero() { - Self::delete_lock(who); + Self::delete_lock(who)?; } else { - Self::update_lock(who, locked); + Self::update_lock(who, locked)?; } - locked + Ok(locked) } /// Deletes schedules that have released all funds up to a block-number. @@ -400,7 +401,7 @@ impl Pallet { T::Currency::transfer(from, to, schedule_amount, Preservation::Expendable)?; - Self::update_lock(&to, total_amount); + Self::update_lock(&to, total_amount)?; >::try_append(to, schedule) .map_err(|_| Error::::MaxReleaseSchedulesExceeded)?; @@ -418,7 +419,7 @@ impl Pallet { // empty release schedules cleanup the storage and unlock the fund if bounded_schedules.is_empty() { - Self::delete_release_schedules(who); + Self::delete_release_schedules(who)?; return Ok(()) } @@ -433,17 +434,18 @@ impl Pallet { ensure!(T::Currency::balance(who) >= total_amount, Error::::InsufficientBalanceToLock,); - Self::update_lock(&who, total_amount); + Self::update_lock(&who, total_amount)?; Self::set_schedules_for(who, bounded_schedules); Ok(()) } - fn update_lock(who: &T::AccountId, locked: BalanceOf) { - let _ = T::Currency::set_freeze(&FreezeReason::NotYetVested.into(), who, locked); + fn update_lock(who: &T::AccountId, locked: BalanceOf) -> DispatchResult { + T::Currency::set_freeze(&FreezeReason::NotYetVested.into(), who, locked)?; + Ok(()) } - fn delete_lock(who: &T::AccountId) { + fn delete_lock(who: &T::AccountId) -> DispatchResult { // thaw returns a DispatchResult from frame::balances::lib.rs::update_freezes() // which returns Ok(()), but mutate()->try_mutate_account() can return an error if: // 1. account does not exist @@ -451,7 +453,8 @@ impl Pallet { // 3. there is an error in increasing or decreasing the providers or consumers // 4. the account balance < ED, and reserved balance is zero ==> dust removal // We can ignore the error here b/c no matter what the lock will be deleted. - T::Currency::thaw(&FreezeReason::NotYetVested.into(), who).ok(); + T::Currency::thaw(&FreezeReason::NotYetVested.into(), who)?; + Ok(()) } fn set_schedules_for( @@ -461,9 +464,10 @@ impl Pallet { ReleaseSchedules::::insert(who, schedules); } - fn delete_release_schedules(who: &T::AccountId) { + fn delete_release_schedules(who: &T::AccountId) -> DispatchResult { >::remove(who); - Self::delete_lock(who); + Self::delete_lock(who)?; + Ok(()) } } From 798313c2dc1e36090bb87c3900a51a83bddba684 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 7 Dec 2023 08:24:57 -0700 Subject: [PATCH 30/75] fix: Remove unnecessary comments in delete_lock function --- pallets/time-release/src/lib.rs | 7 ------- 1 file changed, 7 deletions(-) diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 0284fdd8dd..8eecf5d217 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -446,13 +446,6 @@ impl Pallet { } fn delete_lock(who: &T::AccountId) -> DispatchResult { - // thaw returns a DispatchResult from frame::balances::lib.rs::update_freezes() - // which returns Ok(()), but mutate()->try_mutate_account() can return an error if: - // 1. account does not exist - // 2. the closure passed to mutate_account() returns an error (data manipulation error, unlikely) - // 3. there is an error in increasing or decreasing the providers or consumers - // 4. the account balance < ED, and reserved balance is zero ==> dust removal - // We can ignore the error here b/c no matter what the lock will be deleted. T::Currency::thaw(&FreezeReason::NotYetVested.into(), who)?; Ok(()) } From 9e4ae1ed2b08ed76e5bfd6aa3bf7e7137af32c35 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 7 Dec 2023 09:52:50 -0700 Subject: [PATCH 31/75] fix: code coverage keeps failing, back off on threads used --- .github/workflows/common/codecov/action.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/common/codecov/action.yml b/.github/workflows/common/codecov/action.yml index 78ed8e2d50..264e144f7d 100644 --- a/.github/workflows/common/codecov/action.yml +++ b/.github/workflows/common/codecov/action.yml @@ -11,15 +11,15 @@ runs: shell: bash run: cargo +nightly-2023-07-13 install grcov - name: Build - shell: bash # Limited to 12 threads max - run: cargo +nightly-2023-07-13 build -j 12 --features frequency-lint-check + shell: bash # Limited to 10 threads max + run: cargo +nightly-2023-07-13 build -j 10 --features frequency-lint-check env: CARGO_INCREMENTAL: '0' RUSTFLAGS: "-Zprofile -Ccodegen-units=1 -Copt-level=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests -Cpanic=abort" RUSTDOCFLAGS: "-Cpanic=abort" - name: Test - shell: bash # Limited to 12 threads max - run: cargo +nightly-2023-07-13 test -j 12 --features frequency-lint-check + shell: bash # Limited to 10 threads max + run: cargo +nightly-2023-07-13 test -j 10 --features frequency-lint-check env: CARGO_INCREMENTAL: '0' RUSTFLAGS: "-Zprofile -Ccodegen-units=1 -Copt-level=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests -Cpanic=abort" From d0982c1b026a293b8457cb303f2fed02b0bb12b3 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Thu, 7 Dec 2023 16:09:10 -0800 Subject: [PATCH 32/75] reset set_balance --- pallets/time-release/src/tests.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pallets/time-release/src/tests.rs b/pallets/time-release/src/tests.rs index 13b1a0f7fe..5e09e42fb2 100644 --- a/pallets/time-release/src/tests.rs +++ b/pallets/time-release/src/tests.rs @@ -627,11 +627,8 @@ fn get_balance(who: &T::AccountId) -> BalanceOf { } fn set_balance(who: &T::AccountId, balance: BalanceOf) { - let _ = T::Currency::mint_into(&who, balance.saturated_into()); - assert_eq!( - T::Currency::balance(who).saturated_into::(), - balance.saturated_into::() + 100u64 - ); + let actual_deposit = T::Currency::mint_into(&who, balance.saturated_into()); + assert_eq!(balance, actual_deposit.unwrap()); } fn build_time_release_schedule( From 00db19c363a4f9fd61bf506d32edf320b6ca7615 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 11 Dec 2023 12:42:26 -0700 Subject: [PATCH 33/75] fix: Rename NotYetVested to TimeReleaseVesting --- pallets/time-release/src/lib.rs | 8 +++---- pallets/time-release/src/tests.rs | 36 +++++++++++++++---------------- 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 8eecf5d217..bb993324fa 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -95,7 +95,7 @@ pub mod module { #[pallet::composite_enum] pub enum FreezeReason { /// Funds are currently locked and are not yet liquid. - NotYetVested, + TimeReleaseVesting, } #[pallet::config] @@ -229,7 +229,7 @@ pub mod module { "Account do not have enough balance" ); - T::Currency::set_freeze(&FreezeReason::NotYetVested.into(), who, total_amount) + T::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), who, total_amount) .expect("Failed to set freeze"); ReleaseSchedules::::insert(who, bounded_schedules); }); @@ -441,12 +441,12 @@ impl Pallet { } fn update_lock(who: &T::AccountId, locked: BalanceOf) -> DispatchResult { - T::Currency::set_freeze(&FreezeReason::NotYetVested.into(), who, locked)?; + T::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), who, locked)?; Ok(()) } fn delete_lock(who: &T::AccountId) -> DispatchResult { - T::Currency::thaw(&FreezeReason::NotYetVested.into(), who)?; + T::Currency::thaw(&FreezeReason::TimeReleaseVesting.into(), who)?; Ok(()) } diff --git a/pallets/time-release/src/tests.rs b/pallets/time-release/src/tests.rs index 5e09e42fb2..a669967c91 100644 --- a/pallets/time-release/src/tests.rs +++ b/pallets/time-release/src/tests.rs @@ -120,7 +120,7 @@ fn add_new_release_schedule_merges_with_current_locked_balance_and_until() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, another_schedule)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 17u64 ); }); @@ -229,7 +229,7 @@ fn claim_works() { // no locks anymore assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); }); @@ -245,7 +245,7 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 20u64 ); assert!(ReleaseSchedules::::contains_key(&BOB)); @@ -256,7 +256,7 @@ fn claim_for_works() { // no locks anymore assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); assert!(!ReleaseSchedules::::contains_key(&BOB)); @@ -289,13 +289,13 @@ fn update_release_schedules_works() { // empty release schedules cleanup the storage and unlock the fund assert!(ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 10u64 ); assert_ok!(TimeRelease::update_release_schedules(RuntimeOrigin::root(), BOB, vec![])); assert!(!ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); }); @@ -306,7 +306,7 @@ fn update_release_schedules_fails_if_unexpected_existing_locks() { ExtBuilder::build().execute_with(|| { assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(ALICE), BOB, 1)); let _ = - ::Currency::set_freeze(&FreezeReason::NotYetVested.into(), &BOB, 0u64); + ::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), &BOB, 0u64); }); } @@ -348,7 +348,7 @@ fn multiple_release_schedule_claim_works() { assert!(!ReleaseSchedules::::contains_key(&BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); }); @@ -404,7 +404,7 @@ fn cliff_release_works() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, cliff_schedule)); assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), VESTING_AMOUNT ); @@ -414,7 +414,7 @@ fn cliff_release_works() { assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); assert_eq!( ::Currency::balance_frozen( - &FreezeReason::NotYetVested.into(), + &FreezeReason::TimeReleaseVesting.into(), &BOB ), VESTING_AMOUNT @@ -432,7 +432,7 @@ fn cliff_release_works() { MockBlockNumberProvider::set(VESTING_PERIOD); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); assert_ok!(PalletBalances::transfer_allow_death( @@ -484,7 +484,7 @@ fn alice_time_releases_schedule() { // Bob starts with zero balance and zero locks. assert_eq!(get_balance::(&BOB), 0); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); @@ -494,7 +494,7 @@ fn alice_time_releases_schedule() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, schedule)); assert_eq!(get_balance::(&BOB), 24_996); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 24996 ); assert_eq!( @@ -510,7 +510,7 @@ fn alice_time_releases_schedule() { // and nothing happens because the schedule release has yet to start. assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 24_996 ); @@ -541,7 +541,7 @@ fn alice_time_releases_schedule() { assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); // Since the first issuance the total amount locked increases by the new transfers: 24_996; assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), total_locked ); @@ -560,7 +560,7 @@ fn alice_time_releases_schedule() { total_locked -= 4_166 as u64; assert_eq!( ::Currency::balance_frozen( - &FreezeReason::NotYetVested.into(), + &FreezeReason::TimeReleaseVesting.into(), &BOB ), total_locked @@ -586,7 +586,7 @@ fn alice_time_releases_schedule() { total_locked += total_transfered; total_locked -= 4_166; assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), total_locked ); @@ -616,7 +616,7 @@ fn alice_time_releases_schedule() { ); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::NotYetVested.into(), &BOB), + ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), 0 ); }); From e55abb15f3507150b11806aa94595bd0c76043e6 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 11 Dec 2023 14:06:24 -0700 Subject: [PATCH 34/75] fix: initial capacity storage migration setup --- pallets/capacity/src/migration/mod.rs | 2 + pallets/capacity/src/migration/v3.rs | 169 ++++++++++++++++++++++++++ 2 files changed, 171 insertions(+) create mode 100644 pallets/capacity/src/migration/v3.rs diff --git a/pallets/capacity/src/migration/mod.rs b/pallets/capacity/src/migration/mod.rs index c34354a101..937d239372 100644 --- a/pallets/capacity/src/migration/mod.rs +++ b/pallets/capacity/src/migration/mod.rs @@ -1,2 +1,4 @@ /// migrations to v2 pub mod v2; +/// migrations to v3 +pub mod v3; diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs new file mode 100644 index 0000000000..6b963e8a7a --- /dev/null +++ b/pallets/capacity/src/migration/v3.rs @@ -0,0 +1,169 @@ +use crate::{ + BalanceOf, Config, FreezeReason, Pallet, StakingType, BlockNumberFor, +}; +use frame_support::{ + pallet_prelude::{GetStorageVersion, Weight, IsType}, + traits::{Get, LockableCurrency, OnRuntimeUpgrade, StorageVersion, LockIdentifier, fungible::MutateFreeze}, +}; +use sp_core::hexdisplay::HexDisplay; +use parity_scale_codec::Encode; + +const LOG_TARGET: &str = "runtime::capacity"; + +#[cfg(feature = "try-runtime")] +use sp_std::{fmt::Debug, vec::Vec}; + +const STAKING_ID: LockIdentifier = *b"netstkng"; + +/// Only contains V2 storage format +pub mod v2 { + use super::*; + use frame_support::{storage_alias, Twox64Concat}; + use parity_scale_codec::{Decode, Encode, MaxEncodedLen}; + use scale_info::TypeInfo; + + #[derive(Encode, Decode, PartialEq, Debug, TypeInfo, Eq, MaxEncodedLen)] + /// The StakingDetails struct + pub struct StakingDetails { + /// The amount a Staker has staked, minus the sum of all tokens in `unlocking`. + pub active: BalanceOf, + /// The type of staking for this staking account + pub staking_type: StakingType, + } + + #[storage_alias] + /// alias to StakingAccountLedger storage + pub(crate) type StakingAccountLedger = StorageMap< + Pallet, + Twox64Concat, + ::AccountId, + StakingDetails, + >; +} + +/// migrate Locks to Freezes +// pub fn migrate_to_v3() -> Weight { +// let on_chain_version = Pallet::::on_chain_storage_version(); // 1r + +// if on_chain_version.lt(&3) { +// log::info!(target: LOG_TARGET, "🔄 Locks->Freezes migration started"); +// let mut maybe_count = 0u32; +// // translate_lock_to_freeze(staker, amount); +// let stakers_and_amount: BoundedVec> = +// v2::StakingDetails::::iter().collect(); + +// stakers_and_amount.into_iter().for_each(|staker| { +// // Check that the capacity ledger value matches the locked value +// assert_eq!(staker.1, T::OldCurrency::locks(&staker)); +// MigrationToV3::::translate_lock_to_freeze(staker, staker.1); +// maybe_count += 1; +// log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); +// }); + +// StorageVersion::new(3).put::>(); // 1 w +// let reads = (maybe_count + 1) as u64; +// let writes = (maybe_count * 2 + 1) as u64; +// log::info!(target: LOG_TARGET, "🔄 migration finished"); +// let weight = T::DbWeight::get().reads_writes(reads, writes); +// log::info!(target: LOG_TARGET, "Migration calculated weight = {:?}", weight); +// weight +// } else { +// // storage was already migrated. +// log::info!(target: LOG_TARGET, "Old Locks->Freezes migration attempted to run. Please remove"); +// T::DbWeight::get().reads(1) +// } +// } +/// The OnRuntimeUpgrade implementation for this storage migration +pub struct MigrationToV3(sp_std::marker::PhantomData<(T, OldCurrency)>); +impl MigrationToV3 +where + T: Config, + OldCurrency: 'static + LockableCurrency>, + OldCurrency::Balance: IsType>, +{ + /// Translate capacity staked locked deposit to frozen deposit + pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { + OldCurrency::remove_lock(STAKING_ID, &account_id); + T::Currency::set_freeze(&FreezeReason::Staked.into(), &account_id, amount.into()) + .unwrap_or_else(|err| { + log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); + }); + } +} + +impl OnRuntimeUpgrade for MigrationToV3 +where + T: Config, + OldCurrency: 'static + LockableCurrency>, + OldCurrency::Balance: IsType>, +{ + fn on_runtime_upgrade() -> Weight { + // migrate_to_v3::() + let on_chain_version = Pallet::::on_chain_storage_version(); // 1r + + if on_chain_version.lt(&3) { + log::info!(target: LOG_TARGET, "🔄 Locks->Freezes migration started"); + let mut maybe_count = 0u32; + // translate_lock_to_freeze(staker, amount); + v2::StakingAccountLedger::::iter() + .map(|(account_id, staking_details)| (account_id, staking_details.active)) + .for_each(|(staker, amount)| { + MigrationToV3::::translate_lock_to_freeze(staker, amount.into()); + maybe_count += 1; + log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); + }); + + // let stakers_and_amount: BoundedVec> = + // v2::StakingAccountLedger::::into_iter(self).collect(); + + // stakers_and_amount.into_iter().for_each(|staker| { + // // Check that the capacity ledger value matches the locked value + // assert_eq!(staker.1, T::OldCurrency::locks(&staker)); + // MigrationToV3::::translate_lock_to_freeze(staker, staker.1); + // maybe_count += 1; + // log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); + // }); + + StorageVersion::new(3).put::>(); // 1 w + let reads = (maybe_count + 1) as u64; + let writes = (maybe_count * 2 + 1) as u64; + log::info!(target: LOG_TARGET, "🔄 migration finished"); + let weight = T::DbWeight::get().reads_writes(reads, writes); + log::info!(target: LOG_TARGET, "Migration calculated weight = {:?}", weight); + weight + } else { + // storage was already migrated. + log::info!(target: LOG_TARGET, "Old Locks->Freezes migration attempted to run. Please remove"); + T::DbWeight::get().reads(1) + } + } + + #[cfg(feature = "try-runtime")] + fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { + use frame_support::storage::generator::StorageMap; + use parity_scale_codec::Encode; + let pallet_prefix = v1::StakingAccountLedger::::module_prefix(); + let storage_prefix = v1::StakingAccountLedger::::storage_prefix(); + assert_eq!(&b"Capacity"[..], pallet_prefix); + assert_eq!(&b"StakingAccountLedger"[..], storage_prefix); + log::info!(target: LOG_TARGET, "Running pre_upgrade..."); + + let count = v1::StakingAccountLedger::::iter().count() as u32; + log::info!(target: LOG_TARGET, "Finish pre_upgrade for {:?} records", count); + Ok(count.encode()) + } + + #[cfg(feature = "try-runtime")] + fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { + use parity_scale_codec::Decode; + let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); + let on_chain_version = Pallet::::on_chain_storage_version(); + + assert_eq!(on_chain_version, crate::pallet::STORAGE_VERSION); + assert_eq!(pre_upgrade_count as usize, StakingAccountLedger::::iter().count()); + assert_eq!(pre_upgrade_count as usize, UnstakeUnlocks::::iter().count()); + + log::info!(target: LOG_TARGET, "✅ migration post_upgrade checks passed"); + Ok(()) + } +} From 7481392169c651c1a18b99c15cd54559719b5808 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 11 Dec 2023 14:08:45 -0700 Subject: [PATCH 35/75] fix: lint --- pallets/capacity/src/migration/v3.rs | 28 ++++++---- pallets/time-release/src/lib.rs | 8 ++- pallets/time-release/src/tests.rs | 82 ++++++++++++++++++++++------ 3 files changed, 87 insertions(+), 31 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 6b963e8a7a..deae9ead4c 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,12 +1,13 @@ -use crate::{ - BalanceOf, Config, FreezeReason, Pallet, StakingType, BlockNumberFor, -}; +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingType}; use frame_support::{ - pallet_prelude::{GetStorageVersion, Weight, IsType}, - traits::{Get, LockableCurrency, OnRuntimeUpgrade, StorageVersion, LockIdentifier, fungible::MutateFreeze}, + pallet_prelude::{GetStorageVersion, IsType, Weight}, + traits::{ + fungible::MutateFreeze, Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, + StorageVersion, + }, }; -use sp_core::hexdisplay::HexDisplay; use parity_scale_codec::Encode; +use sp_core::hexdisplay::HexDisplay; const LOG_TARGET: &str = "runtime::capacity"; @@ -106,12 +107,15 @@ where let mut maybe_count = 0u32; // translate_lock_to_freeze(staker, amount); v2::StakingAccountLedger::::iter() - .map(|(account_id, staking_details)| (account_id, staking_details.active)) - .for_each(|(staker, amount)| { - MigrationToV3::::translate_lock_to_freeze(staker, amount.into()); - maybe_count += 1; - log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); - }); + .map(|(account_id, staking_details)| (account_id, staking_details.active)) + .for_each(|(staker, amount)| { + MigrationToV3::::translate_lock_to_freeze( + staker, + amount.into(), + ); + maybe_count += 1; + log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); + }); // let stakers_and_amount: BoundedVec> = // v2::StakingAccountLedger::::into_iter(self).collect(); diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index bb993324fa..a2caecf6a0 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -229,8 +229,12 @@ pub mod module { "Account do not have enough balance" ); - T::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), who, total_amount) - .expect("Failed to set freeze"); + T::Currency::set_freeze( + &FreezeReason::TimeReleaseVesting.into(), + who, + total_amount, + ) + .expect("Failed to set freeze"); ReleaseSchedules::::insert(who, bounded_schedules); }); } diff --git a/pallets/time-release/src/tests.rs b/pallets/time-release/src/tests.rs index a669967c91..a3e47d3df0 100644 --- a/pallets/time-release/src/tests.rs +++ b/pallets/time-release/src/tests.rs @@ -120,7 +120,10 @@ fn add_new_release_schedule_merges_with_current_locked_balance_and_until() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, another_schedule)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 17u64 ); }); @@ -229,7 +232,10 @@ fn claim_works() { // no locks anymore assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); }); @@ -245,7 +251,10 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 20u64 ); assert!(ReleaseSchedules::::contains_key(&BOB)); @@ -256,7 +265,10 @@ fn claim_for_works() { // no locks anymore assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); assert!(!ReleaseSchedules::::contains_key(&BOB)); @@ -289,13 +301,19 @@ fn update_release_schedules_works() { // empty release schedules cleanup the storage and unlock the fund assert!(ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 10u64 ); assert_ok!(TimeRelease::update_release_schedules(RuntimeOrigin::root(), BOB, vec![])); assert!(!ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); }); @@ -305,8 +323,11 @@ fn update_release_schedules_works() { fn update_release_schedules_fails_if_unexpected_existing_locks() { ExtBuilder::build().execute_with(|| { assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(ALICE), BOB, 1)); - let _ = - ::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), &BOB, 0u64); + let _ = ::Currency::set_freeze( + &FreezeReason::TimeReleaseVesting.into(), + &BOB, + 0u64, + ); }); } @@ -348,7 +369,10 @@ fn multiple_release_schedule_claim_works() { assert!(!ReleaseSchedules::::contains_key(&BOB)); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); }); @@ -404,7 +428,10 @@ fn cliff_release_works() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, cliff_schedule)); assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), VESTING_AMOUNT ); @@ -432,7 +459,10 @@ fn cliff_release_works() { MockBlockNumberProvider::set(VESTING_PERIOD); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); assert_ok!(PalletBalances::transfer_allow_death( @@ -484,7 +514,10 @@ fn alice_time_releases_schedule() { // Bob starts with zero balance and zero locks. assert_eq!(get_balance::(&BOB), 0); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); @@ -494,7 +527,10 @@ fn alice_time_releases_schedule() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, schedule)); assert_eq!(get_balance::(&BOB), 24_996); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 24996 ); assert_eq!( @@ -510,7 +546,10 @@ fn alice_time_releases_schedule() { // and nothing happens because the schedule release has yet to start. assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 24_996 ); @@ -541,7 +580,10 @@ fn alice_time_releases_schedule() { assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); // Since the first issuance the total amount locked increases by the new transfers: 24_996; assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), total_locked ); @@ -586,7 +628,10 @@ fn alice_time_releases_schedule() { total_locked += total_transfered; total_locked -= 4_166; assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), total_locked ); @@ -616,7 +661,10 @@ fn alice_time_releases_schedule() { ); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::TimeReleaseVesting.into(), &BOB), + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &BOB + ), 0 ); }); From 56f3223962be18f4a35343a67895ad1cfd3ee6d4 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 11 Dec 2023 14:19:53 -0700 Subject: [PATCH 36/75] fix: remove comments --- pallets/capacity/src/migration/v3.rs | 43 ---------------------------- 1 file changed, 43 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index deae9ead4c..6496685c4b 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -42,38 +42,6 @@ pub mod v2 { >; } -/// migrate Locks to Freezes -// pub fn migrate_to_v3() -> Weight { -// let on_chain_version = Pallet::::on_chain_storage_version(); // 1r - -// if on_chain_version.lt(&3) { -// log::info!(target: LOG_TARGET, "🔄 Locks->Freezes migration started"); -// let mut maybe_count = 0u32; -// // translate_lock_to_freeze(staker, amount); -// let stakers_and_amount: BoundedVec> = -// v2::StakingDetails::::iter().collect(); - -// stakers_and_amount.into_iter().for_each(|staker| { -// // Check that the capacity ledger value matches the locked value -// assert_eq!(staker.1, T::OldCurrency::locks(&staker)); -// MigrationToV3::::translate_lock_to_freeze(staker, staker.1); -// maybe_count += 1; -// log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); -// }); - -// StorageVersion::new(3).put::>(); // 1 w -// let reads = (maybe_count + 1) as u64; -// let writes = (maybe_count * 2 + 1) as u64; -// log::info!(target: LOG_TARGET, "🔄 migration finished"); -// let weight = T::DbWeight::get().reads_writes(reads, writes); -// log::info!(target: LOG_TARGET, "Migration calculated weight = {:?}", weight); -// weight -// } else { -// // storage was already migrated. -// log::info!(target: LOG_TARGET, "Old Locks->Freezes migration attempted to run. Please remove"); -// T::DbWeight::get().reads(1) -// } -// } /// The OnRuntimeUpgrade implementation for this storage migration pub struct MigrationToV3(sp_std::marker::PhantomData<(T, OldCurrency)>); impl MigrationToV3 @@ -117,17 +85,6 @@ where log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); }); - // let stakers_and_amount: BoundedVec> = - // v2::StakingAccountLedger::::into_iter(self).collect(); - - // stakers_and_amount.into_iter().for_each(|staker| { - // // Check that the capacity ledger value matches the locked value - // assert_eq!(staker.1, T::OldCurrency::locks(&staker)); - // MigrationToV3::::translate_lock_to_freeze(staker, staker.1); - // maybe_count += 1; - // log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); - // }); - StorageVersion::new(3).put::>(); // 1 w let reads = (maybe_count + 1) as u64; let writes = (maybe_count * 2 + 1) as u64; From cf607c2f6ca311ab32106d990b3e6164a12808ba Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 11 Dec 2023 17:27:16 -0700 Subject: [PATCH 37/75] feat: add test for v3 migration--draft --- pallets/capacity/src/lib.rs | 2 +- pallets/capacity/src/migration/v3.rs | 61 ++++++++++++++++++++++++---- 2 files changed, 55 insertions(+), 8 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 7c84922af1..b4f4826471 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -110,7 +110,7 @@ pub mod pallet { } /// the storage version for this pallet - pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(2); + pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(3); #[pallet::config] pub trait Config: frame_system::Config { diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 6496685c4b..3f8689e2b0 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,4 +1,6 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingType}; +use crate::{ + BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger, StakingType, +}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -67,7 +69,7 @@ where OldCurrency::Balance: IsType>, { fn on_runtime_upgrade() -> Weight { - // migrate_to_v3::() + // Self::migrate_to_v3() let on_chain_version = Pallet::::on_chain_storage_version(); // 1r if on_chain_version.lt(&3) { @@ -102,14 +104,14 @@ where #[cfg(feature = "try-runtime")] fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { use frame_support::storage::generator::StorageMap; - use parity_scale_codec::Encode; - let pallet_prefix = v1::StakingAccountLedger::::module_prefix(); - let storage_prefix = v1::StakingAccountLedger::::storage_prefix(); + // use parity_scale_codec::Encode; + let pallet_prefix = v2::StakingAccountLedger::::module_prefix(); + let storage_prefix = v2::StakingAccountLedger::::storage_prefix(); assert_eq!(&b"Capacity"[..], pallet_prefix); assert_eq!(&b"StakingAccountLedger"[..], storage_prefix); log::info!(target: LOG_TARGET, "Running pre_upgrade..."); - let count = v1::StakingAccountLedger::::iter().count() as u32; + let count = v2::StakingAccountLedger::::iter().count() as u32; log::info!(target: LOG_TARGET, "Finish pre_upgrade for {:?} records", count); Ok(count.encode()) } @@ -122,9 +124,54 @@ where assert_eq!(on_chain_version, crate::pallet::STORAGE_VERSION); assert_eq!(pre_upgrade_count as usize, StakingAccountLedger::::iter().count()); - assert_eq!(pre_upgrade_count as usize, UnstakeUnlocks::::iter().count()); log::info!(target: LOG_TARGET, "✅ migration post_upgrade checks passed"); Ok(()) } } +#[cfg(test)] +#[cfg(feature = "try-runtime")] +mod test { + use frame_support::traits::WithdrawReasons; + + use super::*; + use crate::{ + tests::{ + mock::{Test as T, *}, + }, + StakingAccountLedger as OldStakingAccountLedger, StakingDetails as OldStakingDetails, + StakingType::MaximumCapacity, + }; + + type MigrationOf = MigrationToV3>; + + #[test] + fn migration_works() { + new_test_ext().execute_with(|| { + StorageVersion::new(2).put::>(); + // Create some data in the old format + // Grab an account with a balance + let account = 200; + let amount = 50; + + pallet_balances::Pallet::::set_lock( + STAKING_ID, + &account, + amount, + WithdrawReasons::all(), + ); + + let old_record = + OldStakingDetails:: { active: amount, staking_type: MaximumCapacity }; + OldStakingAccountLedger::::insert(account, old_record); + assert_eq!(OldStakingAccountLedger::::iter().count(), 1); + + // Run migration. + let state = MigrationOf::::pre_upgrade().unwrap(); + MigrationOf::::on_runtime_upgrade(); + MigrationOf::::post_upgrade(state).unwrap(); + + // Check that the old staking locks are now freezes + }) + } +} From b17da9f597c6e954a800cdc66b80b573650bf8af Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 11 Dec 2023 17:31:57 -0700 Subject: [PATCH 38/75] fix: lint --- pallets/capacity/src/migration/v3.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 3f8689e2b0..7810e73ad7 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -136,9 +136,7 @@ mod test { use super::*; use crate::{ - tests::{ - mock::{Test as T, *}, - }, + tests::mock::{Test as T, *}, StakingAccountLedger as OldStakingAccountLedger, StakingDetails as OldStakingDetails, StakingType::MaximumCapacity, }; From 4bb2fbc19441e45d6774871807b82aa142b8329d Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 12 Dec 2023 08:58:39 -0700 Subject: [PATCH 39/75] fix: lint --- pallets/capacity/src/migration/v3.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 7810e73ad7..541525e6d5 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,6 +1,4 @@ -use crate::{ - BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger, StakingType, -}; +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingType}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -119,6 +117,7 @@ where #[cfg(feature = "try-runtime")] fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { use parity_scale_codec::Decode; + use crate::StakingAccountLedger; let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); let on_chain_version = Pallet::::on_chain_storage_version(); From d91043f08e400b075fcbac6549391e9626c67a37 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 12 Dec 2023 09:30:57 -0700 Subject: [PATCH 40/75] fix: lint --- pallets/capacity/src/migration/v3.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 541525e6d5..660b23010b 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -116,8 +116,8 @@ where #[cfg(feature = "try-runtime")] fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { - use parity_scale_codec::Decode; use crate::StakingAccountLedger; + use parity_scale_codec::Decode; let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); let on_chain_version = Pallet::::on_chain_storage_version(); From 37c4e4092927844fc87a2ea39f3b82003b8bc29e Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 12 Dec 2023 10:16:59 -0700 Subject: [PATCH 41/75] feat: update v3 migration test for try-runtime --- pallets/capacity/src/migration/v3.rs | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 660b23010b..aea3c56a08 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -67,13 +67,11 @@ where OldCurrency::Balance: IsType>, { fn on_runtime_upgrade() -> Weight { - // Self::migrate_to_v3() let on_chain_version = Pallet::::on_chain_storage_version(); // 1r if on_chain_version.lt(&3) { log::info!(target: LOG_TARGET, "🔄 Locks->Freezes migration started"); let mut maybe_count = 0u32; - // translate_lock_to_freeze(staker, amount); v2::StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) .for_each(|(staker, amount)| { @@ -87,6 +85,7 @@ where StorageVersion::new(3).put::>(); // 1 w let reads = (maybe_count + 1) as u64; + // REVIEW: Are we doing 2 writes per account? let writes = (maybe_count * 2 + 1) as u64; log::info!(target: LOG_TARGET, "🔄 migration finished"); let weight = T::DbWeight::get().reads_writes(reads, writes); @@ -102,7 +101,6 @@ where #[cfg(feature = "try-runtime")] fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { use frame_support::storage::generator::StorageMap; - // use parity_scale_codec::Encode; let pallet_prefix = v2::StakingAccountLedger::::module_prefix(); let storage_prefix = v2::StakingAccountLedger::::storage_prefix(); assert_eq!(&b"Capacity"[..], pallet_prefix); @@ -128,10 +126,11 @@ where Ok(()) } } + #[cfg(test)] #[cfg(feature = "try-runtime")] mod test { - use frame_support::traits::WithdrawReasons; + use frame_support::traits::{tokens::fungible::InspectFreeze, WithdrawReasons}; use super::*; use crate::{ @@ -139,6 +138,7 @@ mod test { StakingAccountLedger as OldStakingAccountLedger, StakingDetails as OldStakingDetails, StakingType::MaximumCapacity, }; + use pallet_balances::{BalanceLock, Reasons}; type MigrationOf = MigrationToV3>; @@ -157,6 +157,11 @@ mod test { amount, WithdrawReasons::all(), ); + // Confirm lock exists + assert_eq!( + pallet_balances::Pallet::::locks(&account).get(0), + Some(&BalanceLock { id: STAKING_ID, amount: 50u64, reasons: Reasons::All }) + ); let old_record = OldStakingDetails:: { active: amount, staking_type: MaximumCapacity }; @@ -169,6 +174,11 @@ mod test { MigrationOf::::post_upgrade(state).unwrap(); // Check that the old staking locks are now freezes + assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); + assert_eq!( + ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + 50u64 + ); }) } } From ca20e2b8022e6720b69fc2ab82ef2de4da24c308 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Tue, 12 Dec 2023 15:59:09 -0700 Subject: [PATCH 42/75] fix: add framework for time-release --- pallets/capacity/src/migration/v3.rs | 8 +- pallets/time-release/Cargo.toml | 3 +- pallets/time-release/src/lib.rs | 6 + pallets/time-release/src/migration/mod.rs | 2 + pallets/time-release/src/migration/v2.rs | 210 ++++++++++++++++++++++ 5 files changed, 224 insertions(+), 5 deletions(-) create mode 100644 pallets/time-release/src/migration/mod.rs create mode 100644 pallets/time-release/src/migration/v2.rs diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index aea3c56a08..c0ff9b883a 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -52,11 +52,11 @@ where { /// Translate capacity staked locked deposit to frozen deposit pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { - OldCurrency::remove_lock(STAKING_ID, &account_id); + OldCurrency::remove_lock(STAKING_ID, &account_id); // 1r + 1w T::Currency::set_freeze(&FreezeReason::Staked.into(), &account_id, amount.into()) .unwrap_or_else(|err| { log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); - }); + }); // 1r } } @@ -70,7 +70,7 @@ where let on_chain_version = Pallet::::on_chain_storage_version(); // 1r if on_chain_version.lt(&3) { - log::info!(target: LOG_TARGET, "🔄 Locks->Freezes migration started"); + log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration started"); let mut maybe_count = 0u32; v2::StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) @@ -93,7 +93,7 @@ where weight } else { // storage was already migrated. - log::info!(target: LOG_TARGET, "Old Locks->Freezes migration attempted to run. Please remove"); + log::info!(target: LOG_TARGET, "Old Capacity Locks->Freezes migration attempted to run. Please remove"); T::DbWeight::get().reads(1) } } diff --git a/pallets/time-release/Cargo.toml b/pallets/time-release/Cargo.toml index 7e209709d8..09a6d80b7a 100644 --- a/pallets/time-release/Cargo.toml +++ b/pallets/time-release/Cargo.toml @@ -23,11 +23,12 @@ sp-io = { workspace = true } sp-runtime = { workspace = true } sp-std = { workspace = true } frame-benchmarking = { workspace = true, optional = true } +sp-core = { workspace = true } +log = { workspace = true, default-features = false } [dev-dependencies] chrono = { workspace = true } pallet-balances = { workspace = true } -sp-core = { workspace = true } common-primitives = { default-features = false, path = "../../common/primitives" } [features] diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index a2caecf6a0..140865595d 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -61,6 +61,9 @@ mod mock; #[cfg(test)] mod tests; +/// storage migrations +pub mod migration; + mod types; pub use types::*; @@ -98,6 +101,9 @@ pub mod module { TimeReleaseVesting, } + /// the storage version for this pallet + pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(2); + #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. diff --git a/pallets/time-release/src/migration/mod.rs b/pallets/time-release/src/migration/mod.rs new file mode 100644 index 0000000000..c34354a101 --- /dev/null +++ b/pallets/time-release/src/migration/mod.rs @@ -0,0 +1,2 @@ +/// migrations to v2 +pub mod v2; diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs new file mode 100644 index 0000000000..24b498d546 --- /dev/null +++ b/pallets/time-release/src/migration/v2.rs @@ -0,0 +1,210 @@ +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet}; +use frame_support::{ + pallet_prelude::{GetStorageVersion, IsType, Weight}, + traits::{ + fungible::MutateFreeze, Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, + StorageVersion, + }, + Blake2_128Concat, +}; +use parity_scale_codec::Encode; +use sp_core::hexdisplay::HexDisplay; +use sp_runtime::traits::Zero; + +const LOG_TARGET: &str = "runtime::capacity"; + +#[cfg(feature = "try-runtime")] +use sp_std::{fmt::Debug, vec::Vec}; + +const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; + +/// Only contains V1 storage format +pub mod v1 { + use super::*; + use frame_support::{pallet_prelude::ValueQuery, storage_alias, BoundedVec, Twox64Concat}; + use parity_scale_codec::{Decode, Encode, HasCompact, MaxEncodedLen}; + use scale_info::TypeInfo; + use sp_runtime::RuntimeDebug; + + pub(crate) type ReleaseScheduleOf = ReleaseSchedule, BalanceOf>; + + /// The release schedule. + /// + /// Benefits would be granted gradually, `per_period` amount every `period` + /// of blocks after `start`. + #[derive(Clone, Encode, Decode, PartialEq, Eq, RuntimeDebug, MaxEncodedLen, TypeInfo)] + pub struct ReleaseSchedule { + /// Vesting starting block + pub start: BlockNumber, + /// Number of blocks between vest + pub period: BlockNumber, + /// Number of vest + pub period_count: u32, + /// Amount of tokens to release per vest + #[codec(compact)] + pub per_period: Balance, + } + + /// Release schedules of an account. + /// + /// ReleaseSchedules: `map AccountId => Vec` + /// alias to ReleaseSchedules storage + #[storage_alias] + pub(crate) type ReleaseSchedules = StorageMap< + Pallet, + Blake2_128Concat, + ::AccountId, + BoundedVec, ::MaxReleaseSchedules>, + ValueQuery, + >; +} + +/// The OnRuntimeUpgrade implementation for this storage migration +pub struct MigrationToV3(sp_std::marker::PhantomData<(T, OldCurrency)>); +impl MigrationToV3 +where + T: Config, + OldCurrency: 'static + LockableCurrency>, + OldCurrency::Balance: IsType>, +{ + /// Translate capacity staked locked deposit to frozen deposit + pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { + OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1r + 1w + // TODO: Can we do anything if set_freeze fails? + T::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), &account_id, amount.into()) + .unwrap_or_else(|err| { + log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); + }); // 1w + } +} + +impl OnRuntimeUpgrade for MigrationToV3 +where + T: Config, + OldCurrency: 'static + LockableCurrency>, + OldCurrency::Balance: IsType>, +{ + fn on_runtime_upgrade() -> Weight { + let on_chain_version = Pallet::::on_chain_storage_version(); // 1r + + if on_chain_version.lt(&2) { + log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); + let mut maybe_count = 0u32; + + // Get all the keys(accounts) from the ReleaseSchedules storage + v1::ReleaseSchedules::::iter().map(|(account_id, _)| account_id).for_each( + |account_id| { + // Get the total amount of tokens in the account's ReleaseSchedules + let total_amount = v1::ReleaseSchedules::::get(&account_id) // 1r + .iter() + .map(|schedule| schedule. + .fold(Zero::zero(), |acc, amount| acc.saturating_add(amount)); + + // Translate the lock to a freeze + MigrationToV3::::translate_lock_to_freeze( + account_id, + total_amount.into(), + ); + maybe_count += 1; + log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); + }, + ); + + StorageVersion::new(2).put::>(); // 1 w + let reads = (maybe_count * 2 + 1) as u64; + // REVIEW: Are we doing 2 writes per account? + let writes = (maybe_count * 2 + 1) as u64; + log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); + let weight = T::DbWeight::get().reads_writes(reads, writes); + log::info!(target: LOG_TARGET, "Time Release Migration calculated weight = {:?}", weight); + weight + } else { + // storage was already migrated. + log::info!(target: LOG_TARGET, "Old Time Release Locks->Freezes migration attempted to run. Please remove"); + T::DbWeight::get().reads(1) + } + } + + #[cfg(feature = "try-runtime")] + fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { + use frame_support::storage::generator::StorageMap; + let pallet_prefix = v1::ReleaseSchedules::::module_prefix(); + let storage_prefix = v1::ReleaseSchedules::::storage_prefix(); + assert_eq!(&b"TimeRelease"[..], pallet_prefix); + assert_eq!(&b"ReleaseSchedules"[..], storage_prefix); + log::info!(target: LOG_TARGET, "Running pre_upgrade..."); + + let count = v1::ReleaseSchedules::::iter().count() as u32; + log::info!(target: LOG_TARGET, "Finish pre_upgrade for {:?} records", count); + Ok(count.encode()) + } + + #[cfg(feature = "try-runtime")] + fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { + use crate::ReleaseSchedules; + use parity_scale_codec::Decode; + let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); + let on_chain_version = Pallet::::on_chain_storage_version(); + + assert_eq!(on_chain_version, crate::module::STORAGE_VERSION); + assert_eq!(pre_upgrade_count as usize, ReleaseSchedules::::iter().count()); + + log::info!(target: LOG_TARGET, "✅ migration post_upgrade checks passed"); + Ok(()) + } +} + +#[cfg(test)] +#[cfg(feature = "try-runtime")] +mod test { + use frame_support::traits::{tokens::fungible::InspectFreeze, WithdrawReasons}; + + use super::*; + use crate::mock::{Test, *}; + use pallet_balances::{BalanceLock, Reasons}; + + type MigrationOf = MigrationToV3>; + + #[test] + fn migration_works() { + new_test_ext().execute_with(|| { + StorageVersion::new(2).put::>(); + // Create some data in the old format + // Grab an account with a balance + let account = 200; + let amount = 50; + + pallet_balances::Pallet::::set_lock( + RELEASE_LOCK_ID, + &account, + amount, + WithdrawReasons::all(), + ); + // Confirm lock exists + assert_eq!( + pallet_balances::Pallet::::locks(&account).get(0), + Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 50u64, reasons: Reasons::All }) + ); + + // let old_record = + // OldStakingDetails:: { active: amount, staking_type: MaximumCapacity }; + // OldStakingAccountLedger::::insert(account, old_record); + // assert_eq!(OldStakingAccountLedger::::iter().count(), 1); + + // Run migration. + let state = MigrationOf::::pre_upgrade().unwrap(); + MigrationOf::::on_runtime_upgrade(); + MigrationOf::::post_upgrade(state).unwrap(); + + // Check that the old staking locks are now freezes + assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); + assert_eq!( + ::Currency::balance_frozen( + &FreezeReason::TimeReleaseVesting.into(), + &account + ), + 50u64 + ); + }) + } +} From 31172f8993cb024db6fcdbc6ebb6652b644e8160 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Tue, 12 Dec 2023 16:48:52 -0800 Subject: [PATCH 43/75] fix compile and total locked --- pallets/time-release/src/migration/v2.rs | 36 ++++++++++++------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 24b498d546..8cca465025 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -1,4 +1,5 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet}; +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, types}; +use sp_runtime::Saturating; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -26,24 +27,24 @@ pub mod v1 { use scale_info::TypeInfo; use sp_runtime::RuntimeDebug; - pub(crate) type ReleaseScheduleOf = ReleaseSchedule, BalanceOf>; + pub(crate) type ReleaseScheduleOf = types::ReleaseSchedule, BalanceOf>; /// The release schedule. /// /// Benefits would be granted gradually, `per_period` amount every `period` /// of blocks after `start`. - #[derive(Clone, Encode, Decode, PartialEq, Eq, RuntimeDebug, MaxEncodedLen, TypeInfo)] - pub struct ReleaseSchedule { - /// Vesting starting block - pub start: BlockNumber, - /// Number of blocks between vest - pub period: BlockNumber, - /// Number of vest - pub period_count: u32, - /// Amount of tokens to release per vest - #[codec(compact)] - pub per_period: Balance, - } + // #[derive(Clone, Encode, Decode, PartialEq, Eq, RuntimeDebug, MaxEncodedLen, TypeInfo)] + // pub struct ReleaseSchedule { + // /// Vesting starting block + // pub start: BlockNumber, + // /// Number of blocks between vest + // pub period: BlockNumber, + // /// Number of vest + // pub period_count: u32, + // /// Amount of tokens to release per vest + // #[codec(compact)] + // pub per_period: Balance, + // } /// Release schedules of an account. /// @@ -97,9 +98,8 @@ where // Get the total amount of tokens in the account's ReleaseSchedules let total_amount = v1::ReleaseSchedules::::get(&account_id) // 1r .iter() - .map(|schedule| schedule. - .fold(Zero::zero(), |acc, amount| acc.saturating_add(amount)); - + .map(|schedule: &types::ReleaseSchedule, BalanceOf>| schedule.total_amount()) + .fold(Zero::zero(), |acc: BalanceOf, amount| acc.saturating_add(amount.unwrap_or(Zero::zero()))); // Translate the lock to a freeze MigrationToV3::::translate_lock_to_freeze( account_id, @@ -167,7 +167,7 @@ mod test { #[test] fn migration_works() { - new_test_ext().execute_with(|| { + ExtBuilder::build().execute_with(|| { StorageVersion::new(2).put::>(); // Create some data in the old format // Grab an account with a balance From f3fbcb7243a97db3005ec43832f9351df49ec867 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 13 Dec 2023 08:42:24 -0700 Subject: [PATCH 44/75] fix: cargo update; time release migration updates --- Cargo.lock | 1502 ++-------- e2e/package-lock.json | 3348 +++++++++++----------- pallets/time-release/src/migration/v2.rs | 25 +- 3 files changed, 2058 insertions(+), 2817 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index e3565139c7..18e956e877 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -42,25 +42,6 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "aae1277d39aeec15cb388266ecc24b11c80469deae6067e17a1a7aa9e5c1f234" -[[package]] -name = "aead" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fc95d1bdb8e6666b2b217308eeeb09f2d6728d104be3e31916cc74d15420331" -dependencies = [ - "generic-array 0.14.7", -] - -[[package]] -name = "aead" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b613b8e1e3cf911a086f53f03bf286f52fd7a7258e4fa606f0ef220d39d8877" -dependencies = [ - "generic-array 0.14.7", - "rand_core 0.6.4", -] - [[package]] name = "aead" version = "0.5.2" @@ -71,29 +52,6 @@ dependencies = [ "generic-array 0.14.7", ] -[[package]] -name = "aes" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "884391ef1066acaa41e766ba8f596341b96e93ce34f9a43e7d24bf0a0eaf0561" -dependencies = [ - "aes-soft", - "aesni", - "cipher 0.2.5", -] - -[[package]] -name = "aes" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" -dependencies = [ - "cfg-if", - "cipher 0.3.0", - "cpufeatures", - "opaque-debug 0.3.0", -] - [[package]] name = "aes" version = "0.8.3" @@ -101,58 +59,24 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" dependencies = [ "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] -[[package]] -name = "aes-gcm" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df5f85a83a7d8b0442b6aa7b504b8212c1733da07b98aae43d4bc21b2cb3cdf6" -dependencies = [ - "aead 0.4.3", - "aes 0.7.5", - "cipher 0.3.0", - "ctr 0.8.0", - "ghash 0.4.4", - "subtle", -] - [[package]] name = "aes-gcm" version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "831010a0f742e1209b3bcea8fab6a8e149051ba6099432c8cb2cc117dec3ead1" dependencies = [ - "aead 0.5.2", - "aes 0.8.3", - "cipher 0.4.4", - "ctr 0.9.2", - "ghash 0.5.0", + "aead", + "aes", + "cipher", + "ctr", + "ghash", "subtle", ] -[[package]] -name = "aes-soft" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be14c7498ea50828a38d0e24a765ed2effe92a705885b57d029cd67d45744072" -dependencies = [ - "cipher 0.2.5", - "opaque-debug 0.3.0", -] - -[[package]] -name = "aesni" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea2e11f5e94c2f7d386164cc2aa1f97823fed6f259e486940a71c174dd01b0ce" -dependencies = [ - "cipher 0.2.5", - "opaque-debug 0.3.0", -] - [[package]] name = "ahash" version = "0.7.7" @@ -174,7 +98,7 @@ dependencies = [ "getrandom 0.2.11", "once_cell", "version_check", - "zerocopy 0.7.26", + "zerocopy 0.7.30", ] [[package]] @@ -224,9 +148,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.4" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ab91ebe16eb252986481c5b62f6098f3b698a45e34b5b98200cf20dd2484a44" +checksum = "d664a92ecae85fd0a7392615844904654d1d5f5514837f471ddef4a057aba1b6" dependencies = [ "anstyle", "anstyle-parse", @@ -244,30 +168,30 @@ checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" [[package]] name = "anstyle-parse" -version = "0.2.2" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317b9a89c1868f5ea6ff1d9539a69f45dffc21ce321ac1fd1160dfa48c8e2140" +checksum = "c75ac65da39e5fe5ab759307499ddad880d724eed2f6ce5b5e8a26f4f387928c" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.0" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" +checksum = "e28923312444cdd728e4738b3f9c9cac739500909bb3d3c94b43551b16517648" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.1" +version = "3.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0699d10d2f4d628a98ee7b57b289abbc98ff3bad977cb3152709d4bf2330628" +checksum = "1cd54b81ec8d6180e24654d0b371ad22fc3dd083b6ff8ba325b72e00c87660a7" dependencies = [ "anstyle", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -314,9 +238,9 @@ dependencies = [ [[package]] name = "aquamarine" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df752953c49ce90719c7bf1fc587bc8227aed04732ea0c0f85e5397d7fdbd1a1" +checksum = "d1da02abba9f9063d786eab1509833ebb2fac0f966862ca59439c76b9c566760" dependencies = [ "include_dir", "itertools 0.10.5", @@ -326,12 +250,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "arc-swap" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bddcadddf5e9015d310179a59bb28c4d4b9920ad0f11e8e14dbadf654890c9a6" - [[package]] name = "ark-bls12-381" version = "0.4.0" @@ -444,9 +362,9 @@ dependencies = [ [[package]] name = "ark-scale" -version = "0.0.11" +version = "0.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51bd73bb6ddb72630987d37fa963e99196896c0d0ea81b7c894567e74a2f83af" +checksum = "5f69c00b3b529be29528a6f2fd5fa7b1790f8bed81b9cdca17e326538545a179" dependencies = [ "ark-ec", "ark-ff", @@ -519,9 +437,9 @@ dependencies = [ [[package]] name = "array-bytes" -version = "6.2.0" +version = "6.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de17a919934ad8c5cc99a1a74de4e2dab95d6121a8f27f94755ff525b630382c" +checksum = "6f840fb7195bcfc5e17ea40c26e5ce6d5b9ce5d584466e17703209657e459ae0" [[package]] name = "arrayref" @@ -550,29 +468,13 @@ version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" -[[package]] -name = "asn1-rs" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30ff05a702273012438132f449575dbc804e27b2f3cbe3069aa237d26c98fa33" -dependencies = [ - "asn1-rs-derive 0.1.0", - "asn1-rs-impl", - "displaydoc", - "nom", - "num-traits", - "rusticata-macros", - "thiserror", - "time", -] - [[package]] name = "asn1-rs" version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f6fd5ddaf0351dff5b8da21b2fb4ff8e08ddd02857f0bf69c47639106c0fff0" dependencies = [ - "asn1-rs-derive 0.4.0", + "asn1-rs-derive", "asn1-rs-impl", "displaydoc", "nom", @@ -582,18 +484,6 @@ dependencies = [ "time", ] -[[package]] -name = "asn1-rs-derive" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db8b7511298d5b7784b40b092d9e9dcd3a627a5707e4b5e507931ab0d44eeebf" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", - "synstructure", -] - [[package]] name = "asn1-rs-derive" version = "0.4.0" @@ -653,11 +543,11 @@ version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "17ae5ebefcc48e7452b4987947920dac9450be1110cadf34d1b8c116bdbaf97c" dependencies = [ - "async-lock 3.1.2", + "async-lock 3.2.0", "async-task", "concurrent-queue", "fastrand 2.0.1", - "futures-lite 2.0.1", + "futures-lite 2.1.0", "slab", ] @@ -695,18 +585,18 @@ dependencies = [ [[package]] name = "async-io" -version = "2.2.1" +version = "2.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6d3b15875ba253d1110c740755e246537483f152fa334f91abd7fe84c88b3ff" +checksum = "6afaa937395a620e33dc6a742c593c01aced20aa376ffb0f628121198578ccc7" dependencies = [ - "async-lock 3.1.2", + "async-lock 3.2.0", "cfg-if", "concurrent-queue", "futures-io", - "futures-lite 2.0.1", + "futures-lite 2.1.0", "parking", "polling 3.3.1", - "rustix 0.38.25", + "rustix 0.38.28", "slab", "tracing", "windows-sys 0.52.0", @@ -723,9 +613,9 @@ dependencies = [ [[package]] name = "async-lock" -version = "3.1.2" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dea8b3453dd7cc96711834b75400d671b73e3656975fa68d9f277163b7f7e316" +checksum = "7125e42787d53db9dd54261812ef17e937c95a51e4d291373b670342fa44310c" dependencies = [ "event-listener 4.0.0", "event-listener-strategy", @@ -756,7 +646,7 @@ dependencies = [ "cfg-if", "event-listener 3.1.0", "futures-lite 1.13.0", - "rustix 0.38.25", + "rustix 0.38.28", "windows-sys 0.48.0", ] @@ -768,7 +658,7 @@ checksum = "5fd55a5ba1179988837d24ab4c7cc8ed6efdeff578ede0416b4225a5fca35bd0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -777,13 +667,13 @@ version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e47d90f65a225c4527103a8d747001fc56e375203592b25ad103e1ca13124c5" dependencies = [ - "async-io 2.2.1", + "async-io 2.2.2", "async-lock 2.8.0", "atomic-waker", "cfg-if", "futures-core", "futures-io", - "rustix 0.38.25", + "rustix 0.38.28", "signal-hook-registry", "slab", "windows-sys 0.48.0", @@ -803,7 +693,7 @@ checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -872,7 +762,7 @@ dependencies = [ "ark-ec", "ark-ed-on-bls12-381-bandersnatch", "ark-ff", - "ark-scale 0.0.11", + "ark-scale 0.0.12", "ark-serialize", "ark-std", "dleq_vrf", @@ -891,12 +781,6 @@ version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4cbbc9d0964165b47557570cce6c952866c2678457aca742aafc9fb771d30270" -[[package]] -name = "base16ct" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "349a06037c7bf932dd7e7d1f653678b2038b9ad46a74102f1fc7bd7872678cce" - [[package]] name = "base16ct" version = "0.2.0" @@ -966,7 +850,7 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -1068,7 +952,7 @@ version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0940dc441f31689269e10ac70eb1002a3a1d3ad1390e030043662eb7fe4688b" dependencies = [ - "block-padding 0.1.5", + "block-padding", "byte-tools", "byteorder", "generic-array 0.12.4", @@ -1092,16 +976,6 @@ dependencies = [ "generic-array 0.14.7", ] -[[package]] -name = "block-modes" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57a0e8073e8baa88212fb5823574c02ebccb395136ba9a164ab89379ec6072f0" -dependencies = [ - "block-padding 0.2.1", - "cipher 0.2.5", -] - [[package]] name = "block-padding" version = "0.1.5" @@ -1111,12 +985,6 @@ dependencies = [ "byte-tools", ] -[[package]] -name = "block-padding" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2cae" - [[package]] name = "blocking" version = "1.5.1" @@ -1124,11 +992,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a37913e8dc4ddcc604f0c6d3bf2887c995153af3611de9e23c352b44c1b9118" dependencies = [ "async-channel 2.1.1", - "async-lock 3.1.2", + "async-lock 3.2.0", "async-task", "fastrand 2.0.1", "futures-io", - "futures-lite 2.0.1", + "futures-lite 2.1.0", "piper", "tracing", ] @@ -1277,17 +1145,6 @@ dependencies = [ "libc", ] -[[package]] -name = "ccm" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aca1a8fbc20b50ac9673ff014abfb2b5f4085ee1a850d408f14a159c5853ac7" -dependencies = [ - "aead 0.3.2", - "cipher 0.2.5", - "subtle", -] - [[package]] name = "cexpr" version = "0.6.0" @@ -1325,7 +1182,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3613f74bd2eac03dad61bd53dbe620703d4371614fe0bc3b9f04dd36fe4e818" dependencies = [ "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] @@ -1335,9 +1192,9 @@ version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "10cd79432192d1c0f4e1a0fef9527696cc039165d729fb41b3f4f4f354c2dc35" dependencies = [ - "aead 0.5.2", + "aead", "chacha20", - "cipher 0.4.4", + "cipher", "poly1305", "zeroize", ] @@ -1379,24 +1236,6 @@ dependencies = [ "unsigned-varint", ] -[[package]] -name = "cipher" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12f8e7987cbd042a63249497f41aed09f8e65add917ea6566effbc56578d6801" -dependencies = [ - "generic-array 0.14.7", -] - -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array 0.14.7", -] - [[package]] name = "cipher" version = "0.4.4" @@ -1430,9 +1269,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.4.9" +version = "4.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46ca43acc1b21c6cc2d1d3129c19e323a613935b5bc28fb3b33b5b2e5fb00030" +checksum = "bfaff671f6b22ca62406885ece523383b9b64022e341e53e009a62ebc47a45f2" dependencies = [ "clap_builder", "clap_derive", @@ -1440,9 +1279,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.4.9" +version = "4.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63361bae7eef3771745f02d8d892bec2fee5f6e34af316ba556e7f97a7069ff1" +checksum = "a216b506622bb1d316cd51328dce24e07bdff4a6128a47c7e7fad11878d5adbb" dependencies = [ "anstream", "anstyle", @@ -1459,7 +1298,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -1597,9 +1436,9 @@ dependencies = [ [[package]] name = "concurrent-queue" -version = "2.3.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f057a694a54f12365049b0958a1685bb52d567f5593b355fbf685838e873d400" +checksum = "d16048cd947b08fa32c24458a22f5dc5e835264f689f4f5653210c69fd107363" dependencies = [ "crossbeam-utils", ] @@ -1663,9 +1502,9 @@ checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" [[package]] name = "core-foundation" -version = "0.9.3" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" dependencies = [ "core-foundation-sys", "libc", @@ -1673,9 +1512,9 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.4" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" [[package]] name = "core2" @@ -1812,21 +1651,6 @@ dependencies = [ "wasmtime-types", ] -[[package]] -name = "crc" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86ec7a15cbe22e59248fc7eadb1907dab5ba09372595da4d73dd805ed4417dfe" -dependencies = [ - "crc-catalog", -] - -[[package]] -name = "crc-catalog" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" - [[package]] name = "crc32fast" version = "1.3.2" @@ -1838,9 +1662,9 @@ dependencies = [ [[package]] name = "crossbeam-deque" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef" +checksum = "fca89a0e215bab21874660c67903c5f143333cab1da83d041c7ded6053774751" dependencies = [ "cfg-if", "crossbeam-epoch", @@ -1849,22 +1673,21 @@ dependencies = [ [[package]] name = "crossbeam-epoch" -version = "0.9.15" +version = "0.9.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7" +checksum = "2d2fe95351b870527a5d09bf563ed3c97c0cffb87cf1c78a591bf48bb218d9aa" dependencies = [ "autocfg", "cfg-if", "crossbeam-utils", "memoffset 0.9.0", - "scopeguard", ] [[package]] name = "crossbeam-queue" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" +checksum = "b9bcf5bdbfdd6030fb4a1c497b5d5fc5921aa2f60d359a17e249c0e6df3de153" dependencies = [ "cfg-if", "crossbeam-utils", @@ -1872,9 +1695,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.16" +version = "0.8.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" +checksum = "c06d96137f14f244c37f989d9fff8f95e6c18b918e71f36638f8c49112e4c78f" dependencies = [ "cfg-if", ] @@ -1885,18 +1708,6 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" -[[package]] -name = "crypto-bigint" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef2b4b23cddf68b89b8f8069890e8c270d54e2d5fe1b143820234805e4cb17ef" -dependencies = [ - "generic-array 0.14.7", - "rand_core 0.6.4", - "subtle", - "zeroize", -] - [[package]] name = "crypto-bigint" version = "0.5.5" @@ -1940,22 +1751,13 @@ dependencies = [ "subtle", ] -[[package]] -name = "ctr" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" -dependencies = [ - "cipher 0.3.0", -] - [[package]] name = "ctr" version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" dependencies = [ - "cipher 0.4.4", + "cipher", ] [[package]] @@ -2218,10 +2020,10 @@ name = "cumulus-pallet-parachain-system-proc-macro" version = "0.1.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -2485,7 +2287,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -2525,7 +2327,7 @@ dependencies = [ "proc-macro2", "quote", "scratch", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -2542,42 +2344,7 @@ checksum = "587663dd5fb3d10932c8aecfe7c844db1bcf0aee93eeab08fac13dc1212c2e7f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", -] - -[[package]] -name = "darling" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "109c1ca6e6b7f82cc233a97004ea8ed7ca123a9af07a8230878fcfda9b158bf0" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" -dependencies = [ - "darling_core", - "quote", - "syn 1.0.109", + "syn 2.0.41", ] [[package]] @@ -2619,17 +2386,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "der" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1a467a65c5e759bce6e65eaf91cc29f466cdc57cb65777bd646872a8a1fd4de" -dependencies = [ - "const-oid", - "pem-rfc7468", - "zeroize", -] - [[package]] name = "der" version = "0.7.8" @@ -2640,27 +2396,13 @@ dependencies = [ "zeroize", ] -[[package]] -name = "der-parser" -version = "7.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe398ac75057914d7d07307bf67dc7f3f574a26783b4fc7805a20ffa9f506e82" -dependencies = [ - "asn1-rs 0.3.1", - "displaydoc", - "nom", - "num-bigint", - "num-traits", - "rusticata-macros", -] - [[package]] name = "der-parser" version = "8.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dbd676fbbab537128ef0278adb5576cf363cff6aa22a7b24effe97347cfab61e" dependencies = [ - "asn1-rs 0.5.2", + "asn1-rs", "displaydoc", "nom", "num-bigint", @@ -2670,9 +2412,9 @@ dependencies = [ [[package]] name = "deranged" -version = "0.3.9" +version = "0.3.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" +checksum = "8eb30d70a07a3b04884d2677f06bec33509dc67ca60d92949e5535352d3191dc" dependencies = [ "powerfmt", ] @@ -2699,37 +2441,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "derive_builder" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d07adf7be193b71cc36b193d0f5fe60b918a3a9db4dad0449f57bcfd519704a3" -dependencies = [ - "derive_builder_macro", -] - -[[package]] -name = "derive_builder_core" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f91d4cfa921f1c05904dc3c57b4a32c38aed3340cce209f3a6fd1478babafc4" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "derive_builder_macro" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f0314b72bed045f3a68671b3c86328386762c93f82d98c65c3cb5e5f573dd68" -dependencies = [ - "derive_builder_core", - "syn 1.0.109", -] - [[package]] name = "derive_more" version = "0.99.17" @@ -2834,7 +2545,7 @@ checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -2856,18 +2567,18 @@ dependencies = [ [[package]] name = "docify" -version = "0.2.6" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4235e9b248e2ba4b92007fe9c646f3adf0ffde16dc74713eacc92b8bc58d8d2f" +checksum = "7cc4fd38aaa9fb98ac70794c82a00360d1e165a87fbf96a8a91f9dfc602aaee2" dependencies = [ "docify_macros", ] [[package]] name = "docify_macros" -version = "0.2.6" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47020e12d7c7505670d1363dd53d6c23724f71a90a3ae32ff8eba40de8404626" +checksum = "63fa215f3a0d40fb2a221b3aa90d8e1fbb8379785a990cb60d62ac71ebdc6460" dependencies = [ "common-path", "derive-syn-parse", @@ -2875,9 +2586,9 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.39", + "syn 2.0.41", "termcolor", - "toml 0.7.8", + "toml 0.8.2", "walkdir", ] @@ -2926,30 +2637,18 @@ version = "1.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "545b22097d44f8a9581187cdf93de7a71e4722bf51200cfaba810865b49a495d" -[[package]] -name = "ecdsa" -version = "0.14.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "413301934810f597c1d19ca71c8710e99a3f1ba28a0d2ebc01551a2daeea3c5c" -dependencies = [ - "der 0.6.1", - "elliptic-curve 0.12.3", - "rfc6979 0.3.1", - "signature 1.6.4", -] - [[package]] name = "ecdsa" version = "0.16.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ee27f32b5c5292967d2d4a9d7f1e0b0aed2c15daded5a60300e4abb9d8020bca" dependencies = [ - "der 0.7.8", + "der", "digest 0.10.7", - "elliptic-curve 0.13.8", - "rfc6979 0.4.0", - "signature 2.2.0", - "spki 0.7.2", + "elliptic-curve", + "rfc6979", + "signature", + "spki", ] [[package]] @@ -2958,8 +2657,8 @@ version = "2.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" dependencies = [ - "pkcs8 0.10.2", - "signature 2.2.0", + "pkcs8", + "signature", ] [[package]] @@ -3012,43 +2711,21 @@ version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" -[[package]] -name = "elliptic-curve" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7bb888ab5300a19b8e5bceef25ac745ad065f3c9f7efc6de1b91958110891d3" -dependencies = [ - "base16ct 0.1.1", - "crypto-bigint 0.4.9", - "der 0.6.1", - "digest 0.10.7", - "ff 0.12.1", - "generic-array 0.14.7", - "group 0.12.1", - "hkdf", - "pem-rfc7468", - "pkcs8 0.9.0", - "rand_core 0.6.4", - "sec1 0.3.0", - "subtle", - "zeroize", -] - [[package]] name = "elliptic-curve" version = "0.13.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b5e6043086bf7973472e0c7dff2142ea0b680d30e18d9cc40f267efbf222bd47" dependencies = [ - "base16ct 0.2.0", - "crypto-bigint 0.5.5", + "base16ct", + "crypto-bigint", "digest 0.10.7", - "ff 0.13.0", + "ff", "generic-array 0.14.7", - "group 0.13.0", - "pkcs8 0.10.2", + "group", + "pkcs8", "rand_core 0.6.4", - "sec1 0.7.3", + "sec1", "subtle", "zeroize", ] @@ -3088,7 +2765,7 @@ checksum = "f95e2801cd355d4a1a3e3953ce6ee5ae9603a5c833455343a8bfe3f44d418246" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3099,7 +2776,7 @@ checksum = "c2ad8cef1d801a4686bfd8919f0b30eac4c8e48968c437a6405ded4fb5272d2b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3142,12 +2819,12 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.7" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f258a7194e7f7c2a7837a8913aeab7fd8c383457034fa20ce4dd3dcb813e8eb8" +checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" dependencies = [ "libc", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -3231,7 +2908,7 @@ dependencies = [ "fs-err", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3279,7 +2956,7 @@ checksum = "f5aa1e3ae159e592ad222dc90c5acbad632b527779ba88486abe92782ab268bd" dependencies = [ "expander 0.0.4", "indexmap 1.9.3", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "syn 1.0.109", @@ -3295,16 +2972,6 @@ dependencies = [ "libc", ] -[[package]] -name = "ff" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d013fc25338cc558c5c2cfbad646908fb23591e2404481826742b651c9af7160" -dependencies = [ - "rand_core 0.6.4", - "subtle", -] - [[package]] name = "ff" version = "0.13.0" @@ -3318,7 +2985,7 @@ dependencies = [ [[package]] name = "fflonk" version = "0.1.0" -source = "git+https://github.com/w3f/fflonk#1beb0585e1c8488956fac7f05da061f9b41e8948" +source = "git+https://github.com/w3f/fflonk#1e854f35e9a65d08b11a86291405cdc95baa0a35" dependencies = [ "ark-ec", "ark-ff", @@ -3346,14 +3013,14 @@ dependencies = [ [[package]] name = "filetime" -version = "0.2.22" +version = "0.2.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4029edd3e734da6fe05b6cd7bd2960760a616bd2ddd0d59a0124746d6272af0" +checksum = "1ee447700ac8aa0b2f2bd7bc4462ad686ba06baa6727ac149a2d6277f0d240fd" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.3.5", - "windows-sys 0.48.0", + "redox_syscall 0.4.1", + "windows-sys 0.52.0", ] [[package]] @@ -3517,10 +3184,10 @@ name = "frame-election-provider-solution-type" version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3647,7 +3314,7 @@ dependencies = [ "proc-macro-warning", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3656,10 +3323,10 @@ version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "frame-support-procedural-tools-derive", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3669,7 +3336,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -3980,7 +3647,7 @@ version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eeb4ed9e12f43b7fa0baae3f9cdda28352770132ef2e09a23760c29cae8bd47" dependencies = [ - "rustix 0.38.25", + "rustix 0.38.28", "windows-sys 0.48.0", ] @@ -4056,14 +3723,13 @@ dependencies = [ [[package]] name = "futures-lite" -version = "2.0.1" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3831c2651acb5177cbd83943f3d9c8912c5ad03c76afcc0e9511ba568ec5ebb" +checksum = "aeee267a1883f7ebef3700f262d2d54de95dfaf38189015a74fdc4e0c7ad8143" dependencies = [ "fastrand 2.0.1", "futures-core", "futures-io", - "memchr", "parking", "pin-project-lite 0.2.13", ] @@ -4076,7 +3742,7 @@ checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -4087,7 +3753,7 @@ checksum = "d2411eed028cdf8c8034eaf21f9915f956b6c3abec4d4c7949ee67f0721127bd" dependencies = [ "futures-io", "rustls 0.20.9", - "webpki 0.22.4", + "webpki", ] [[package]] @@ -4187,16 +3853,6 @@ dependencies = [ "wasi 0.11.0+wasi-snapshot-preview1", ] -[[package]] -name = "ghash" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99" -dependencies = [ - "opaque-debug 0.3.0", - "polyval 0.5.3", -] - [[package]] name = "ghash" version = "0.5.0" @@ -4204,7 +3860,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d930750de5717d2dd0b8c0d42c076c0e884c81a73e6cab859bbd2339c71e3e40" dependencies = [ "opaque-debug 0.3.0", - "polyval 0.6.1", + "polyval", ] [[package]] @@ -4243,24 +3899,13 @@ dependencies = [ "regex-syntax 0.8.2", ] -[[package]] -name = "group" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dfbfb3a6cfbd390d5c9564ab283a0349b9b9fcd46a706c1eb10e0db70bfbac7" -dependencies = [ - "ff 0.12.1", - "rand_core 0.6.4", - "subtle", -] - [[package]] name = "group" version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ - "ff 0.13.0", + "ff", "rand_core 0.6.4", "subtle", ] @@ -4387,9 +4032,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "hkdf" -version = "0.12.3" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" +checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" dependencies = [ "hmac 0.12.1", ] @@ -4467,9 +4112,9 @@ dependencies = [ [[package]] name = "http-body" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" +checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" dependencies = [ "bytes", "http", @@ -4534,7 +4179,7 @@ dependencies = [ "http", "hyper", "log", - "rustls 0.21.9", + "rustls 0.21.10", "rustls-native-certs", "tokio", "tokio-rustls", @@ -4564,12 +4209,6 @@ dependencies = [ "cc", ] -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - [[package]] name = "idna" version = "0.2.3" @@ -4607,7 +4246,7 @@ version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d6b0422c86d7ce0e97169cc42e04ae643caf278874a7a3c87b8150a220dc7e1e" dependencies = [ - "async-io 2.2.1", + "async-io 2.2.2", "core-foundation", "fnv", "futures", @@ -4741,25 +4380,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "interceptor" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e8a11ae2da61704edada656798b61c94b35ecac2c58eb955156987d5e6be90b" -dependencies = [ - "async-trait", - "bytes", - "log", - "rand 0.8.5", - "rtcp", - "rtp", - "thiserror", - "tokio", - "waitgroup", - "webrtc-srtp", - "webrtc-util", -] - [[package]] name = "io-lifetimes" version = "1.0.11" @@ -4802,7 +4422,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" dependencies = [ "hermit-abi 0.3.3", - "rustix 0.38.25", + "rustix 0.38.28", "windows-sys 0.48.0", ] @@ -4835,9 +4455,9 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.9" +version = "1.0.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" +checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" [[package]] name = "jobserver" @@ -4947,7 +4567,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "44e8ab85614a08792b9bff6c8feee23be78c98d0182d4c622c05256ab553892a" dependencies = [ "heck", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "syn 1.0.109", @@ -5008,8 +4628,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3f01b677d82ef7a676aa37e099defd83a28e15687112cafdd112d60236b6115b" dependencies = [ "cfg-if", - "ecdsa 0.16.9", - "elliptic-curve 0.13.8", + "ecdsa", + "elliptic-curve", "once_cell", "sha2 0.10.8", ] @@ -5095,9 +4715,9 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.150" +version = "0.2.151" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89d92a4743f9a61002fae18374ed11e7973f530cb3a3255fb354818118b2203c" +checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" [[package]] name = "libflate" @@ -5137,9 +4757,9 @@ checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" [[package]] name = "libp2p" -version = "0.51.3" +version = "0.51.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f210d259724eae82005b5c48078619b7745edb7b76de370b03f8ba59ea103097" +checksum = "f35eae38201a993ece6bdc823292d6abd1bffed1c4d0f4a3517d2bd8e1d917fe" dependencies = [ "bytes", "futures", @@ -5162,7 +4782,6 @@ dependencies = [ "libp2p-swarm", "libp2p-tcp", "libp2p-wasm-ext", - "libp2p-webrtc", "libp2p-websocket", "libp2p-yamux", "multiaddr", @@ -5474,12 +5093,12 @@ dependencies = [ "futures-rustls", "libp2p-core", "libp2p-identity", - "rcgen 0.10.0", + "rcgen", "ring 0.16.20", "rustls 0.20.9", "thiserror", - "webpki 0.22.4", - "x509-parser 0.14.0", + "webpki", + "x509-parser", "yasna", ] @@ -5497,37 +5116,6 @@ dependencies = [ "wasm-bindgen-futures", ] -[[package]] -name = "libp2p-webrtc" -version = "0.4.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dba48592edbc2f60b4bc7c10d65445b0c3964c07df26fdf493b6880d33be36f8" -dependencies = [ - "async-trait", - "asynchronous-codec", - "bytes", - "futures", - "futures-timer", - "hex", - "if-watch", - "libp2p-core", - "libp2p-identity", - "libp2p-noise", - "log", - "multihash 0.17.0", - "quick-protobuf", - "quick-protobuf-codec", - "rand 0.8.5", - "rcgen 0.9.3", - "serde", - "stun", - "thiserror", - "tinytemplate", - "tokio", - "tokio-util", - "webrtc", -] - [[package]] name = "libp2p-websocket" version = "0.41.0" @@ -5692,9 +5280,9 @@ checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" [[package]] name = "linux-raw-sys" -version = "0.4.11" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "969488b55f8ac402214f3f5fd243ebb7206cf82de60d3172994707a4bcc2b829" +checksum = "c4cd1a83af159aa67994778be9070f0ae1bd732942279cabb14f86f986a21456" [[package]] name = "lock_api" @@ -5774,7 +5362,7 @@ dependencies = [ "macro_magic_core", "macro_magic_macros", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -5788,7 +5376,7 @@ dependencies = [ "macro_magic_core_macros", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -5799,7 +5387,7 @@ checksum = "d710e1214dffbab3b5dacb21475dde7d6ed84c69ff722b3a47a782668d44fbac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -5810,7 +5398,7 @@ checksum = "b8fb85ec1620619edf2984a7693497d4ec88a9665d8b87e942856884c92dbf2a" dependencies = [ "macro_magic_core", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -5850,16 +5438,6 @@ dependencies = [ "rawpointer", ] -[[package]] -name = "md-5" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" -dependencies = [ - "cfg-if", - "digest 0.10.7", -] - [[package]] name = "memchr" version = "2.6.4" @@ -5872,7 +5450,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2cffa4ad52c6f791f4f8b15f0c05f9824b2ced1160e88cc393d64fff9a8ac64" dependencies = [ - "rustix 0.38.25", + "rustix 0.38.28", ] [[package]] @@ -5884,15 +5462,6 @@ dependencies = [ "libc", ] -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - [[package]] name = "memoffset" version = "0.8.0" @@ -5972,9 +5541,9 @@ dependencies = [ [[package]] name = "mio" -version = "0.8.9" +version = "0.8.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" +checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" dependencies = [ "libc", "wasi 0.11.0+wasi-snapshot-preview1", @@ -6106,7 +5675,7 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc076939022111618a5026d3be019fd8b366e76314538ff9a1b59ffbcbf98bcd" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro-error", "proc-macro2", "quote", @@ -6251,7 +5820,6 @@ dependencies = [ "bitflags 1.3.2", "cfg-if", "libc", - "memoffset 0.6.5", ] [[package]] @@ -6392,29 +5960,20 @@ dependencies = [ "memchr", ] -[[package]] -name = "oid-registry" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38e20717fa0541f39bd146692035c37bedfa532b3e5071b35761082407546b2a" -dependencies = [ - "asn1-rs 0.3.1", -] - [[package]] name = "oid-registry" version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9bedf36ffb6ba96c2eb7144ef6270557b52e54b20c0a8e1eb2ff99a6c6959bff" dependencies = [ - "asn1-rs 0.5.2", + "asn1-rs", ] [[package]] name = "once_cell" -version = "1.18.0" +version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" [[package]] name = "oorandom" @@ -6466,7 +6025,7 @@ dependencies = [ "expander 0.0.6", "itertools 0.10.5", "petgraph", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "syn 1.0.109", @@ -6481,28 +6040,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "p256" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51f44edd08f51e2ade572f141051021c5af22677e42b7dd28a88155151c33594" -dependencies = [ - "ecdsa 0.14.8", - "elliptic-curve 0.12.3", - "sha2 0.10.8", -] - -[[package]] -name = "p384" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc8c5bf642dde52bb9e87c0ecd8ca5a76faac2eeed98dedb7c717997e1080aa" -dependencies = [ - "ecdsa 0.14.8", - "elliptic-curve 0.12.3", - "sha2 0.10.8", -] - [[package]] name = "pallet-aura" version = "4.0.0-dev" @@ -7568,10 +7105,10 @@ name = "pallet-staking-reward-curve" version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -7684,6 +7221,7 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", + "log", "pallet-balances", "parity-scale-codec", "scale-info", @@ -7914,9 +7452,9 @@ dependencies = [ [[package]] name = "parity-scale-codec" -version = "3.6.5" +version = "3.6.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dec8a8073036902368c2cdc0387e85ff9a37054d7e7c98e592145e0c92cd4fb" +checksum = "881331e34fa842a2fb61cc2db9643a8fedc615e47cfcc52597d1af0db9a7e8fe" dependencies = [ "arrayvec 0.7.4", "bitvec", @@ -7929,11 +7467,11 @@ dependencies = [ [[package]] name = "parity-scale-codec-derive" -version = "3.6.5" +version = "3.6.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "312270ee71e1cd70289dacf597cab7b207aa107d2f28191c2ae45b2ece18a260" +checksum = "be30eaf4b0a9fba5336683b38de57bb86d179a35862ba6bfcf57625d006bde5b" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 2.0.1", "proc-macro2", "quote", "syn 1.0.109", @@ -8059,15 +7597,6 @@ dependencies = [ "base64 0.13.1", ] -[[package]] -name = "pem-rfc7468" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24d159833a9105500e0398934e205e0773f0b27529557134ecfc51c27646adac" -dependencies = [ - "base64ct", -] - [[package]] name = "percent-encoding" version = "2.3.1" @@ -8105,7 +7634,7 @@ dependencies = [ "pest_meta", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -8159,7 +7688,7 @@ dependencies = [ "phf_shared", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -8188,7 +7717,7 @@ checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -8220,24 +7749,14 @@ dependencies = [ "futures-io", ] -[[package]] -name = "pkcs8" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9eca2c590a5f85da82668fa685c09ce2888b9430e83299debf1f34b65fd4a4ba" -dependencies = [ - "der 0.6.1", - "spki 0.6.0", -] - [[package]] name = "pkcs8" version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" dependencies = [ - "der 0.7.8", - "spki 0.7.2", + "der", + "spki", ] [[package]] @@ -9465,7 +8984,7 @@ dependencies = [ "cfg-if", "concurrent-queue", "pin-project-lite 0.2.13", - "rustix 0.38.25", + "rustix 0.38.28", "tracing", "windows-sys 0.52.0", ] @@ -9478,19 +8997,7 @@ checksum = "8159bd90725d2df49889a078b54f4f79e87f1f8a8444194cdca81d38f5393abf" dependencies = [ "cpufeatures", "opaque-debug 0.3.0", - "universal-hash 0.5.1", -] - -[[package]] -name = "polyval" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" -dependencies = [ - "cfg-if", - "cpufeatures", - "opaque-debug 0.3.0", - "universal-hash 0.4.1", + "universal-hash", ] [[package]] @@ -9502,14 +9009,14 @@ dependencies = [ "cfg-if", "cpufeatures", "opaque-debug 0.3.0", - "universal-hash 0.5.1", + "universal-hash", ] [[package]] name = "portable-atomic" -version = "1.5.1" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3bccab0e7fd7cc19f820a1c8c91720af652d0c88dc9664dd72aef2614f04af3b" +checksum = "7170ef9988bc169ba16dd36a7fa041e5c4cbeb6a35b76d4c03daded371eae7c0" [[package]] name = "powerfmt" @@ -9580,7 +9087,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" dependencies = [ "proc-macro2", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -9619,7 +9126,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" dependencies = [ "once_cell", - "toml_edit", + "toml_edit 0.19.15", +] + +[[package]] +name = "proc-macro-crate" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97dc5fea232fc28d2f597b37c4876b348a40e33f3b02cc975c8d006d78d94b1a" +dependencies = [ + "toml_datetime", + "toml_edit 0.20.2", ] [[package]] @@ -9654,7 +9171,7 @@ checksum = "3d1eaa7fa0aa1929ffdf7eeb6eac234dde6268914a14ad44d23521ab6a9b258e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -9700,7 +9217,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -9826,7 +9343,7 @@ dependencies = [ "thiserror", "tinyvec", "tracing", - "webpki 0.22.4", + "webpki", ] [[package]] @@ -9950,19 +9467,6 @@ dependencies = [ "crossbeam-utils", ] -[[package]] -name = "rcgen" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6413f3de1edee53342e6138e75b56d32e7bc6e332b3bd62d497b1929d4cfbcdd" -dependencies = [ - "pem", - "ring 0.16.20", - "time", - "x509-parser 0.13.2", - "yasna", -] - [[package]] name = "rcgen" version = "0.10.0" @@ -9984,15 +9488,6 @@ dependencies = [ "bitflags 1.3.2", ] -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags 1.3.2", -] - [[package]] name = "redox_syscall" version = "0.4.1" @@ -10043,7 +9538,7 @@ checksum = "7f7473c2cfcf90008193dd0e3e16599455cb601a9fce322b5bb55de799664925" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -10112,17 +9607,6 @@ dependencies = [ "quick-error", ] -[[package]] -name = "rfc6979" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7743f17af12fa0b03b803ba12cd6a8d9483a587e89c69445e3909655c0b9fabb" -dependencies = [ - "crypto-bigint 0.4.9", - "hmac 0.12.1", - "zeroize", -] - [[package]] name = "rfc6979" version = "0.4.0" @@ -10165,9 +9649,9 @@ dependencies = [ [[package]] name = "ring" -version = "0.17.5" +version = "0.17.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb0205304757e5d899b9c2e448b867ffd03ae7f988002e47cd24954391394d0b" +checksum = "688c63d65483050968b2a8937f7995f443e27041a0f7700aa59b0822aedebb74" dependencies = [ "cc", "getrandom 0.2.11", @@ -10306,17 +9790,6 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "rtcp" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1919efd6d4a6a85d13388f9487549bb8e359f17198cc03ffd72f79b553873691" -dependencies = [ - "bytes", - "thiserror", - "webrtc-util", -] - [[package]] name = "rtnetlink" version = "0.10.1" @@ -10342,20 +9815,6 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "rtp" -version = "0.6.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2a095411ff00eed7b12e4c6a118ba984d113e1079582570d56a5ee723f11f80" -dependencies = [ - "async-trait", - "bytes", - "rand 0.8.5", - "serde", - "thiserror", - "webrtc-util", -] - [[package]] name = "rustc-demangle" version = "0.1.23" @@ -10422,28 +9881,15 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.25" +version = "0.38.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc99bc2d4f1fed22595588a013687477aedf3cdcfb26558c559edb67b4d9b22e" +checksum = "72e572a5e8ca657d7366229cdde4bd14c4eb5499a9573d4d366fe1b599daa316" dependencies = [ "bitflags 2.4.1", "errno", "libc", - "linux-raw-sys 0.4.11", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustls" -version = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35edb675feee39aec9c99fa5ff985081995a06d594114ae14cbe797ad7b7a6d7" -dependencies = [ - "base64 0.13.1", - "log", - "ring 0.16.20", - "sct 0.6.1", - "webpki 0.21.4", + "linux-raw-sys 0.4.12", + "windows-sys 0.52.0", ] [[package]] @@ -10454,20 +9900,20 @@ checksum = "1b80e3dec595989ea8510028f30c408a4630db12c9cbb8de34203b89d6577e99" dependencies = [ "log", "ring 0.16.20", - "sct 0.7.1", - "webpki 0.22.4", + "sct", + "webpki", ] [[package]] name = "rustls" -version = "0.21.9" +version = "0.21.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "629648aced5775d558af50b2b4c7b02983a04b312126d45eeead26e7caa498b9" +checksum = "f9d5a6813c0759e4609cd494e8e725babae6a2ca7b62a5536a13daaec6fcb7ba" dependencies = [ "log", - "ring 0.17.5", + "ring 0.17.7", "rustls-webpki", - "sct 0.7.1", + "sct", ] [[package]] @@ -10497,7 +9943,7 @@ version = "0.101.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b6275d1ee7a1cd780b64aca7726599a1dbc893b1e64144529e55c3c2f745765" dependencies = [ - "ring 0.17.5", + "ring 0.17.7", "untrusted 0.9.0", ] @@ -10531,9 +9977,9 @@ dependencies = [ [[package]] name = "ryu" -version = "1.0.15" +version = "1.0.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" +checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" [[package]] name = "safe_arch" @@ -10654,10 +10100,10 @@ name = "sc-chain-spec-derive" version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -11614,10 +11060,10 @@ name = "sc-tracing-proc-macro" version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -11697,7 +11143,7 @@ version = "2.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "abf2c68b89cafb3b8d918dd07b42be0da66ff202cf1155c5739a4e0c1ea0dc19" dependencies = [ - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", "syn 1.0.109", @@ -11769,62 +11215,26 @@ version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a3cf7c11c38cb994f3d40e8a8cde3bbd1f72a435e4c49e85d6553d8312306152" -[[package]] -name = "sct" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b362b83898e0e69f38515b82ee15aa80636befe47c3b6d3d89a911e78fc228ce" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - [[package]] name = "sct" version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "da046153aa2352493d6cb7da4b6e5c0c057d8a1d0a9aa8560baffdd945acd414" dependencies = [ - "ring 0.17.5", + "ring 0.17.7", "untrusted 0.9.0", ] -[[package]] -name = "sdp" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d22a5ef407871893fd72b4562ee15e4742269b173959db4b8df6f538c414e13" -dependencies = [ - "rand 0.8.5", - "substring", - "thiserror", - "url", -] - -[[package]] -name = "sec1" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3be24c1842290c45df0a7bf069e0c268a747ad05a192f2fd7dcfdbc1cba40928" -dependencies = [ - "base16ct 0.1.1", - "der 0.6.1", - "generic-array 0.14.7", - "pkcs8 0.9.0", - "subtle", - "zeroize", -] - [[package]] name = "sec1" version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" dependencies = [ - "base16ct 0.2.0", - "der 0.7.8", + "base16ct", + "der", "generic-array 0.14.7", - "pkcs8 0.10.2", + "pkcs8", "subtle", "zeroize", ] @@ -11920,7 +11330,7 @@ checksum = "43576ca501357b9b071ac53cdc7da8ef0cbd9493d8df094cd821777ea6e894d3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -11980,17 +11390,6 @@ dependencies = [ "opaque-debug 0.3.0", ] -[[package]] -name = "sha1" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - [[package]] name = "sha2" version = "0.8.2" @@ -12061,16 +11460,6 @@ dependencies = [ "libc", ] -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" -dependencies = [ - "digest 0.10.7", - "rand_core 0.6.4", -] - [[package]] name = "signature" version = "2.2.0" @@ -12129,9 +11518,9 @@ dependencies = [ [[package]] name = "slotmap" -version = "1.0.6" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1e08e261d0e8f5c43123b7adf3e4ca1690d655377ac93a03b2c9d3e98de1342" +checksum = "dbff4acf519f630b3a3ddcfaea6c06b42174d9a44bc70c620e9ed1649d58b82a" dependencies = [ "version_check", ] @@ -12251,9 +11640,9 @@ dependencies = [ [[package]] name = "snap" -version = "1.1.0" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e9f0ab6ef7eb7353d9119c170a436d1bf248eea575ac42d19d12f4e34130831" +checksum = "1b6b67fb9a61334225b5b790716f609cd58395f895b3fe8b328786812a40bc3b" [[package]] name = "snow" @@ -12261,12 +11650,12 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "58021967fd0a5eeeb23b08df6cc244a4d4a5b4aec1d27c9e02fad1a58b4cd74e" dependencies = [ - "aes-gcm 0.10.3", + "aes-gcm", "blake2", "chacha20poly1305", "curve25519-dalek 4.1.1", "rand_core 0.6.4", - "ring 0.17.5", + "ring 0.17.7", "rustc_version", "sha2 0.10.8", "subtle", @@ -12338,10 +11727,10 @@ dependencies = [ "Inflector", "blake2", "expander 2.0.0", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -12580,7 +11969,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "quote", "sp-core-hashing", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -12599,7 +11988,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -12813,10 +12202,10 @@ version = "11.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "Inflector", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -12874,7 +12263,7 @@ name = "sp-statement-store" version = "4.0.0-dev" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ - "aes-gcm 0.10.3", + "aes-gcm", "curve25519-dalek 4.1.1", "ed25519-dalek", "hkdf", @@ -13008,7 +12397,7 @@ dependencies = [ "parity-scale-codec", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -13064,22 +12453,12 @@ dependencies = [ [[package]] name = "spki" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67cf02bbac7a337dc36e4f5a693db6c21e7863f45070f7064577eb4367a3212b" -dependencies = [ - "base64ct", - "der 0.6.1", -] - -[[package]] -name = "spki" -version = "0.7.2" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d1e996ef02c474957d681f1b05213dfb0abab947b446a62d37770b23500184a" +checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" dependencies = [ "base64ct", - "der 0.7.8", + "der", ] [[package]] @@ -13346,26 +12725,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.39", -] - -[[package]] -name = "stun" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7e94b1ec00bad60e6410e058b52f1c66de3dc5fe4d62d09b3e52bb7d3b73e25" -dependencies = [ - "base64 0.13.1", - "crc", - "lazy_static", - "md-5", - "rand 0.8.5", - "ring 0.16.20", - "subtle", - "thiserror", - "tokio", - "url", - "webrtc-util", + "syn 2.0.41", ] [[package]] @@ -13552,15 +12912,6 @@ dependencies = [ "wasm-opt", ] -[[package]] -name = "substring" -version = "1.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ee6433ecef213b2e72f587ef64a2f5943e7cd16fbd82dbe8bc07486c534c86" -dependencies = [ - "autocfg", -] - [[package]] name = "subtle" version = "2.4.1" @@ -13586,9 +12937,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.39" +version = "2.0.41" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23e78b90f2fcf45d3e842032ce32e3f2d1545ba6636271dcbf24fa306d87be7a" +checksum = "44c8b28c477cc3bf0e7966561e3460130e1255f7a1cf71931075f1c5e7a7e269" dependencies = [ "proc-macro2", "quote", @@ -13662,7 +13013,7 @@ dependencies = [ "cfg-if", "fastrand 2.0.1", "redox_syscall 0.4.1", - "rustix 0.38.25", + "rustix 0.38.28", "windows-sys 0.48.0", ] @@ -13707,7 +13058,7 @@ checksum = "e4c60d69f36615a077cc7663b9cb8e42275722d23e58a7fa3d2c7f2915d09d04" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -13718,7 +13069,7 @@ checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -13837,16 +13188,6 @@ dependencies = [ "crunchy", ] -[[package]] -name = "tinytemplate" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4d6b5f19ff7664e8c98d03e2139cb510db9b0a60b55f8e8709b689d939b6bc" -dependencies = [ - "serde", - "serde_json", -] - [[package]] name = "tinyvec" version = "1.6.0" @@ -13864,9 +13205,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.34.0" +version = "1.35.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0c014766411e834f7af5b8f4cf46257aab4036ca95e9d2c144a10f59ad6f5b9" +checksum = "841d45b238a16291a4e1584e61820b8ae57d696cc5015c459c229ccc6990cc1c" dependencies = [ "backtrace", "bytes", @@ -13889,7 +13230,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -13909,7 +13250,7 @@ version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" dependencies = [ - "rustls 0.21.9", + "rustls 0.21.10", "tokio", ] @@ -13958,14 +13299,26 @@ dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit", + "toml_edit 0.19.15", +] + +[[package]] +name = "toml" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" +dependencies = [ + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit 0.20.2", ] [[package]] name = "toml_datetime" -version = "0.6.5" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" dependencies = [ "serde", ] @@ -13983,6 +13336,19 @@ dependencies = [ "winnow", ] +[[package]] +name = "toml_edit" +version = "0.20.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +dependencies = [ + "indexmap 2.1.0", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + [[package]] name = "tower" version = "0.4.13" @@ -14044,7 +13410,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -14085,10 +13451,10 @@ version = "1.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.1.0#c8d2251cafadc108ba2f1f8a3208dc547ff38901" dependencies = [ "expander 2.0.0", - "proc-macro-crate", + "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -14205,9 +13571,9 @@ dependencies = [ [[package]] name = "try-lock" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" [[package]] name = "try-runtime-cli" @@ -14251,25 +13617,6 @@ version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f4f195fd851901624eee5a58c4bb2b4f06399148fcd0ed336e6f1cb60a9881df" -[[package]] -name = "turn" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4712ee30d123ec7ae26d1e1b218395a16c87cdbaf4b3925d170d684af62ea5e8" -dependencies = [ - "async-trait", - "base64 0.13.1", - "futures", - "log", - "md-5", - "rand 0.8.5", - "ring 0.16.20", - "stun", - "thiserror", - "tokio", - "webrtc-util", -] - [[package]] name = "twox-hash" version = "1.6.3" @@ -14319,9 +13666,9 @@ dependencies = [ [[package]] name = "unicode-bidi" -version = "0.3.13" +version = "0.3.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" +checksum = "6f2528f27a9eb2b21e69c95319b30bd0efd85d09c379741b0f78ea1d86be2416" [[package]] name = "unicode-ident" @@ -14350,16 +13697,6 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" -[[package]] -name = "universal-hash" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f214e8f697e925001e66ec2c6e37a4ef93f0f78c2eed7814394e10c62025b05" -dependencies = [ - "generic-array 0.14.7", - "subtle", -] - [[package]] name = "universal-hash" version = "0.5.1" @@ -14417,7 +13754,6 @@ version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5e395fcf16a7a3d8127ec99782007af141946b4795001f876d54fb0d55978560" dependencies = [ - "getrandom 0.2.11", "serde", ] @@ -14445,15 +13781,6 @@ version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" -[[package]] -name = "waitgroup" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1f50000a783467e6c0200f9d10642f4bc424e39efc1b770203e88b488f79292" -dependencies = [ - "atomic-waker", -] - [[package]] name = "waker-fn" version = "1.1.1" @@ -14512,7 +13839,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", "wasm-bindgen-shared", ] @@ -14546,7 +13873,7 @@ checksum = "f0eb82fcb7930ae6219a7ecfd55b217f5f0893484b7a13022ebb2b2bf20b5283" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -14623,9 +13950,9 @@ dependencies = [ [[package]] name = "wasmi" -version = "0.31.0" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f341edb80021141d4ae6468cbeefc50798716a347d4085c3811900049ea8945" +checksum = "acfc1e384a36ca532d070a315925887247f3c7e23567e23e0ac9b1c5d6b8bf76" dependencies = [ "smallvec", "spin 0.9.8", @@ -14868,31 +14195,21 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.65" +version = "0.3.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5db499c5f66323272151db0e666cd34f78617522fb0c1604d31a27c50c206a85" +checksum = "50c24a44ec86bb68fbecd1b3efed7e85ea5621b39b35ef2766b66cd984f8010f" dependencies = [ "js-sys", "wasm-bindgen", ] -[[package]] -name = "webpki" -version = "0.21.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8e38c0608262c46d4a56202ebabdeb094cef7e560ca7a226c6bf055188aa4ea" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - [[package]] name = "webpki" version = "0.22.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed63aea5ce73d0ff405984102c42de94fc55a6b75765d621c65262469b3c9b53" dependencies = [ - "ring 0.17.5", + "ring 0.17.7", "untrusted 0.9.0", ] @@ -14902,7 +14219,7 @@ version = "0.22.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87" dependencies = [ - "webpki 0.22.4", + "webpki", ] [[package]] @@ -14911,214 +14228,6 @@ version = "0.25.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1778a42e8b3b90bff8d0f5032bf22250792889a5cdc752aa0020c84abe3aaf10" -[[package]] -name = "webrtc" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3bc9049bdb2cea52f5fd4f6f728184225bdb867ed0dc2410eab6df5bdd67bb" -dependencies = [ - "arc-swap", - "async-trait", - "bytes", - "hex", - "interceptor", - "lazy_static", - "log", - "rand 0.8.5", - "rcgen 0.9.3", - "regex", - "ring 0.16.20", - "rtcp", - "rtp", - "rustls 0.19.1", - "sdp", - "serde", - "serde_json", - "sha2 0.10.8", - "stun", - "thiserror", - "time", - "tokio", - "turn", - "url", - "waitgroup", - "webrtc-data", - "webrtc-dtls", - "webrtc-ice", - "webrtc-mdns", - "webrtc-media", - "webrtc-sctp", - "webrtc-srtp", - "webrtc-util", -] - -[[package]] -name = "webrtc-data" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ef36a4d12baa6e842582fe9ec16a57184ba35e1a09308307b67d43ec8883100" -dependencies = [ - "bytes", - "derive_builder", - "log", - "thiserror", - "tokio", - "webrtc-sctp", - "webrtc-util", -] - -[[package]] -name = "webrtc-dtls" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a00f4242f2db33307347bd5be53263c52a0331c96c14292118c9a6bb48d267" -dependencies = [ - "aes 0.6.0", - "aes-gcm 0.10.3", - "async-trait", - "bincode", - "block-modes", - "byteorder", - "ccm", - "curve25519-dalek 3.2.0", - "der-parser 8.2.0", - "elliptic-curve 0.12.3", - "hkdf", - "hmac 0.12.1", - "log", - "p256", - "p384", - "rand 0.8.5", - "rand_core 0.6.4", - "rcgen 0.10.0", - "ring 0.16.20", - "rustls 0.19.1", - "sec1 0.3.0", - "serde", - "sha1", - "sha2 0.10.8", - "signature 1.6.4", - "subtle", - "thiserror", - "tokio", - "webpki 0.21.4", - "webrtc-util", - "x25519-dalek 2.0.0", - "x509-parser 0.13.2", -] - -[[package]] -name = "webrtc-ice" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "465a03cc11e9a7d7b4f9f99870558fe37a102b65b93f8045392fef7c67b39e80" -dependencies = [ - "arc-swap", - "async-trait", - "crc", - "log", - "rand 0.8.5", - "serde", - "serde_json", - "stun", - "thiserror", - "tokio", - "turn", - "url", - "uuid", - "waitgroup", - "webrtc-mdns", - "webrtc-util", -] - -[[package]] -name = "webrtc-mdns" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f08dfd7a6e3987e255c4dbe710dde5d94d0f0574f8a21afa95d171376c143106" -dependencies = [ - "log", - "socket2 0.4.10", - "thiserror", - "tokio", - "webrtc-util", -] - -[[package]] -name = "webrtc-media" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f72e1650a8ae006017d1a5280efb49e2610c19ccc3c0905b03b648aee9554991" -dependencies = [ - "byteorder", - "bytes", - "rand 0.8.5", - "rtp", - "thiserror", -] - -[[package]] -name = "webrtc-sctp" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d47adcd9427eb3ede33d5a7f3424038f63c965491beafcc20bc650a2f6679c0" -dependencies = [ - "arc-swap", - "async-trait", - "bytes", - "crc", - "log", - "rand 0.8.5", - "thiserror", - "tokio", - "webrtc-util", -] - -[[package]] -name = "webrtc-srtp" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6183edc4c1c6c0175f8812eefdce84dfa0aea9c3ece71c2bf6ddd3c964de3da5" -dependencies = [ - "aead 0.4.3", - "aes 0.7.5", - "aes-gcm 0.9.4", - "async-trait", - "byteorder", - "bytes", - "ctr 0.8.0", - "hmac 0.11.0", - "log", - "rtcp", - "rtp", - "sha-1", - "subtle", - "thiserror", - "tokio", - "webrtc-util", -] - -[[package]] -name = "webrtc-util" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f1db1727772c05cf7a2cfece52c3aca8045ca1e176cd517d323489aa3c6d87" -dependencies = [ - "async-trait", - "bitflags 1.3.2", - "bytes", - "cc", - "ipnet", - "lazy_static", - "libc", - "log", - "nix", - "rand 0.8.5", - "thiserror", - "tokio", - "winapi", -] - [[package]] name = "westend-runtime" version = "1.0.0" @@ -15241,7 +14350,7 @@ dependencies = [ "either", "home", "once_cell", - "rustix 0.38.25", + "rustix 0.38.28", ] [[package]] @@ -15510,9 +14619,9 @@ checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" [[package]] name = "winnow" -version = "0.5.19" +version = "0.5.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "829846f3e3db426d4cee4510841b71a8e58aa2a76b1132579487ae430ccd9c7b" +checksum = "6c830786f7720c2fd27a1a0e27a709dbd3c4d009b56d098fc742d4f4eab91fe2" dependencies = [ "memchr", ] @@ -15559,38 +14668,19 @@ dependencies = [ "zeroize", ] -[[package]] -name = "x509-parser" -version = "0.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb9bace5b5589ffead1afb76e43e34cff39cd0f3ce7e170ae0c29e53b88eb1c" -dependencies = [ - "asn1-rs 0.3.1", - "base64 0.13.1", - "data-encoding", - "der-parser 7.0.0", - "lazy_static", - "nom", - "oid-registry 0.4.0", - "ring 0.16.20", - "rusticata-macros", - "thiserror", - "time", -] - [[package]] name = "x509-parser" version = "0.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e0ecbeb7b67ce215e40e3cc7f2ff902f94a223acf44995934763467e7b1febc8" dependencies = [ - "asn1-rs 0.5.2", + "asn1-rs", "base64 0.13.1", "data-encoding", - "der-parser 8.2.0", + "der-parser", "lazy_static", "nom", - "oid-registry 0.6.1", + "oid-registry", "rusticata-macros", "thiserror", "time", @@ -15604,7 +14694,7 @@ dependencies = [ "Inflector", "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -15648,11 +14738,11 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.7.26" +version = "0.7.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97e415490559a91254a2979b4829267a57d2fcd741a98eee8b722fb57289aa0" +checksum = "306dca4455518f1f31635ec308b6b3e4eb1b11758cefafc782827d0aa7acb5c7" dependencies = [ - "zerocopy-derive 0.7.26", + "zerocopy-derive 0.7.30", ] [[package]] @@ -15663,18 +14753,18 @@ checksum = "855e0f6af9cd72b87d8a6c586f3cb583f5cdcc62c2c80869d8cd7e96fdf7ee20" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] name = "zerocopy-derive" -version = "0.7.26" +version = "0.7.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd7e48ccf166952882ca8bd778a43502c64f33bf94c12ebe2a7f08e5a0f6689f" +checksum = "be912bf68235a88fbefd1b73415cb218405958d1655b2ece9035a19920bdf6ba" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] @@ -15694,7 +14784,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.39", + "syn 2.0.41", ] [[package]] diff --git a/e2e/package-lock.json b/e2e/package-lock.json index 97def836a4..f7ffbdae0c 100644 --- a/e2e/package-lock.json +++ b/e2e/package-lock.json @@ -45,49 +45,53 @@ } }, "node_modules/@achingbrain/nat-port-mapper": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/@achingbrain/nat-port-mapper/-/nat-port-mapper-1.0.11.tgz", - "integrity": "sha512-Y2lwx0zmrwEl+IGu+V/QiVBdcdsWscYq1PMMEjvyuuaXnmnppbLWilO8LK1yoLdncxwJBuS0zZtHbpFeWBusRg==", + "version": "1.0.13", + "resolved": "https://registry.npmjs.org/@achingbrain/nat-port-mapper/-/nat-port-mapper-1.0.13.tgz", + "integrity": "sha512-B5GL6ILDek72OjoEyFGEuuNYaEOYxO06Ulhcaf/5iQ4EO8uaZWS+OkolYST7L+ecJrkjfaSNmSAsWRRuh+1Z5A==", "dependencies": { "@achingbrain/ssdp": "^4.0.1", - "@libp2p/logger": "^3.0.0", + "@libp2p/logger": "^4.0.1", "default-gateway": "^7.2.2", "err-code": "^3.0.1", "it-first": "^3.0.1", "p-defer": "^4.0.0", "p-timeout": "^6.1.1", "xml2js": "^0.6.0" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" + } + }, + "node_modules/@achingbrain/nat-port-mapper/node_modules/@libp2p/interface": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/interface/-/interface-1.0.2.tgz", + "integrity": "sha512-z/3Yyg+7cVyzRXwzdrDkJd7YmNaLE9iZjQaixo5luI/n9uk5OFFjb9ulAsNqpq8V1xylCo2DXIC7f94KClwzVw==", + "dependencies": { + "@multiformats/multiaddr": "^12.1.10", + "it-pushable": "^3.2.1", + "it-stream-types": "^2.0.1", + "multiformats": "^12.1.3", + "uint8arraylist": "^2.4.3" + } + }, + "node_modules/@achingbrain/nat-port-mapper/node_modules/@libp2p/logger": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/logger/-/logger-4.0.2.tgz", + "integrity": "sha512-J9UMtMU9BKXNp+3c5kcI7HyWOPYg2B2E6sn1gEQckiSexTaz0wKJSlgTZ89f9F8bkC3AaC8ybXYuHbFQhwpTIg==", + "dependencies": { + "@libp2p/interface": "^1.0.2", + "@multiformats/multiaddr": "^12.1.10", + "debug": "^4.3.4", + "interface-datastore": "^8.2.0", + "multiformats": "^12.1.3" } }, "node_modules/@achingbrain/ssdp": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@achingbrain/ssdp/-/ssdp-4.0.4.tgz", - "integrity": "sha512-fY/ShiYJmhLdr45Vn2+f88xTqZjBSH3X3F+EJu/89cjB1JIkMCVtD5CQaaS38YknIL8cEcNhjMZM4cdE3ckSSQ==", + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/@achingbrain/ssdp/-/ssdp-4.0.6.tgz", + "integrity": "sha512-Y4JE2L9150i50V6lg/Y8+ilhxRpUZKKv+PKo68Aj7MjPfaUAar6ZHilF9h4/Zb3q0fqGMXNc9o11cQLNI8J8bA==", "dependencies": { "event-iterator": "^2.0.0", "freeport-promise": "^2.0.0", "merge-options": "^3.0.4", - "xml2js": "^0.5.0" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/@achingbrain/ssdp/node_modules/xml2js": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.5.0.tgz", - "integrity": "sha512-drPFnkQJik/O+uPKpqSgr22mpuFHqKdbS835iAQrUC73L2F5WkboIRd63ai/2Yg6I1jzifPFKH2NTK+cfglkIA==", - "dependencies": { - "sax": ">=0.6.0", - "xmlbuilder": "~11.0.0" - }, - "engines": { - "node": ">=4.0.0" + "xml2js": "^0.6.2" } }, "node_modules/@assemblyscript/loader": { @@ -95,18 +99,28 @@ "resolved": "https://registry.npmjs.org/@assemblyscript/loader/-/loader-0.9.4.tgz", "integrity": "sha512-HazVq9zwTVwGmqdwYzu7WyQ6FQVZ7SwET0KKQuKm55jD0IfUpZgN0OPIiZG3zV1iSrVYcN0bdwLRXI/VNCYsUA==" }, + "node_modules/@chainsafe/as-chacha20poly1305": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/@chainsafe/as-chacha20poly1305/-/as-chacha20poly1305-0.1.0.tgz", + "integrity": "sha512-BpNcL8/lji/GM3+vZ/bgRWqJ1q5kwvTFmGPk7pxm/QQZDbaMI98waOHjEymTjq2JmdD/INdNBFOVSyJofXg7ew==" + }, + "node_modules/@chainsafe/as-sha256": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.4.1.tgz", + "integrity": "sha512-IqeeGwQihK6Y2EYLFofqs2eY2ep1I2MvQXHzOAI+5iQN51OZlUkrLgyAugu2x86xZewDk5xas7lNczkzFzF62w==" + }, "node_modules/@chainsafe/is-ip": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/@chainsafe/is-ip/-/is-ip-2.0.2.tgz", "integrity": "sha512-ndGqEMG1W5WkGagaqOZHpPU172AGdxr+LD15sv3WIUvT5oCFUrG1Y0CW/v2Egwj4JXEvSibaIIIqImsm98y1nA==" }, "node_modules/@chainsafe/libp2p-gossipsub": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/@chainsafe/libp2p-gossipsub/-/libp2p-gossipsub-10.1.0.tgz", - "integrity": "sha512-mOVYJAvxYRkh2HeggNFW/7ukEccQDVEI9LPhvlnJk7gnJhyJJ6mhZxUAaytfp3v3qTkmeBRnEL0eJOQBm+MoOA==", + "version": "10.1.1", + "resolved": "https://registry.npmjs.org/@chainsafe/libp2p-gossipsub/-/libp2p-gossipsub-10.1.1.tgz", + "integrity": "sha512-nou65zlGaUIPwlUq7ceEVpszJX4tBWRRanppYaKsJk7rbDeIKRJQla2duATGOI3fwj1+pGSlDQuF2zG7P0VJQw==", "dependencies": { "@libp2p/crypto": "^2.0.0", - "@libp2p/interface": "^0.1.0", + "@libp2p/interface": "^0.1.4", "@libp2p/interface-internal": "^0.1.0", "@libp2p/logger": "^3.0.0", "@libp2p/peer-id": "^3.0.0", @@ -127,15 +141,17 @@ } }, "node_modules/@chainsafe/libp2p-noise": { - "version": "13.0.1", - "resolved": "https://registry.npmjs.org/@chainsafe/libp2p-noise/-/libp2p-noise-13.0.1.tgz", - "integrity": "sha512-eeOFubXyS9sK0oBg/qRfve6LVGzZX1vyULVidaKGTJr8Y4dtyU4+Btqw/aVo3o1lhdvb/qoY+p/Ep2pUsvJKhg==", + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@chainsafe/libp2p-noise/-/libp2p-noise-13.0.5.tgz", + "integrity": "sha512-xXqwrkH4nXlv3cYENHtqOgmIT2M4irPDwi548UvpmxzeC9hqa0kmiqbtAFYMV3v+gJ9pqVBVWFRk2hjs83GNrw==", "dependencies": { + "@chainsafe/as-chacha20poly1305": "^0.1.0", + "@chainsafe/as-sha256": "^0.4.1", "@libp2p/crypto": "^2.0.0", "@libp2p/interface": "^0.1.0", "@libp2p/logger": "^3.0.0", "@libp2p/peer-id": "^3.0.0", - "@noble/ciphers": "^0.3.0", + "@noble/ciphers": "^0.4.0", "@noble/curves": "^1.1.0", "@noble/hashes": "^1.3.1", "it-byte-stream": "^1.0.0", @@ -146,7 +162,8 @@ "it-stream-types": "^2.0.1", "protons-runtime": "^5.0.0", "uint8arraylist": "^2.4.3", - "uint8arrays": "^4.0.4" + "uint8arrays": "^4.0.4", + "wherearewe": "^2.0.1" }, "engines": { "node": ">=16.0.0", @@ -154,21 +171,17 @@ } }, "node_modules/@chainsafe/libp2p-yamux": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/@chainsafe/libp2p-yamux/-/libp2p-yamux-5.0.0.tgz", - "integrity": "sha512-aWTnBPR2hJt0A2y579sMtZVB6IqgSSHlZ6Eg+WDxNZQ0zcexafuruZQDj+z3FUTNPz+E8IeuyCi7tjI4IEehjw==", + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/@chainsafe/libp2p-yamux/-/libp2p-yamux-5.0.4.tgz", + "integrity": "sha512-3cfOjomFde7+6sscoM0gK7cgA5aEm20oYeVXSSonVzaas/UZzNsGP+FnF/bjLATjdyTB+YqhBHJs/KKk1PAy/Q==", "dependencies": { "@libp2p/interface": "^0.1.0", "@libp2p/logger": "^3.0.0", - "abortable-iterator": "^5.0.1", + "get-iterator": "^2.0.1", "it-foreach": "^2.0.3", "it-pipe": "^3.0.1", "it-pushable": "^3.2.0", "uint8arraylist": "^2.4.3" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" } }, "node_modules/@chainsafe/netmask": { @@ -191,16 +204,6 @@ "node": ">=12" } }, - "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { - "version": "0.3.9", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", - "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", - "dev": true, - "dependencies": { - "@jridgewell/resolve-uri": "^3.0.3", - "@jridgewell/sourcemap-codec": "^1.4.10" - } - }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -217,18 +220,18 @@ } }, "node_modules/@eslint-community/regexpp": { - "version": "4.8.1", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.8.1.tgz", - "integrity": "sha512-PWiOzLIUAjN/w5K17PoF4n6sKBw0gqLHPhywmYHP4t1VFQQVYeb1yWsJwnMVEMl3tUHME7X/SJPZLmtG7XBDxQ==", + "version": "4.10.0", + "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.10.0.tgz", + "integrity": "sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA==", "dev": true, "engines": { "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, "node_modules/@eslint/eslintrc": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.3.tgz", - "integrity": "sha512-yZzuIG+jnVu6hNSzFEN07e8BxF3uAzYtQb6uDkaYZLo6oYZDCq454c5kB8zxnzfCYyP4MIuyBn10L0DqwujTmA==", + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.4.tgz", + "integrity": "sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==", "dev": true, "dependencies": { "ajv": "^6.12.4", @@ -249,26 +252,18 @@ } }, "node_modules/@eslint/js": { - "version": "8.53.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.53.0.tgz", - "integrity": "sha512-Kn7K8dx/5U6+cT1yEhpX1w4PCSg0M+XyRILPgvwcEBjerFWCwQj5sbr3/VmxqV0JGHCBCzyd6LxypEuehypY1w==", + "version": "8.55.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.55.0.tgz", + "integrity": "sha512-qQfo2mxH5yVom1kacMtZZJFVdW+E70mqHMJvVg6WTLo+VBuQJ4TojZlfWBjK0ve5BdEeNAVxOsl/nvNMpJOaJA==", "dev": true, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/@fastify/busboy": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.1.0.tgz", - "integrity": "sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA==", - "engines": { - "node": ">=14" - } - }, "node_modules/@frequency-chain/api-augment": { "version": "0.0.0", "resolved": "file:../js/api-augment/dist/frequency-chain-api-augment-0.0.0.tgz", - "integrity": "sha512-k5W6xrluJIjaNwqzWgTs7pk3g9MtMiar9ktIfI/QXEF0TsGNjJ+FkkmtaYb3g9HUDFsOTdZXC78Cx0Yo+kbgMw==", + "integrity": "sha512-APYNkdACbNLXSluVIML0V2rrQKlDTAh7bWNlKyZ6VuMXL8MY9wTQPHfTrdktccpYxkjZ8G4yD6i5rWjr9FB2ow==", "license": "Apache-2.0", "dependencies": { "@polkadot/api": "^10.9.1", @@ -276,10 +271,31 @@ "@polkadot/types": "^10.9.1" } }, + "node_modules/@helia/delegated-routing-v1-http-api-client": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@helia/delegated-routing-v1-http-api-client/-/delegated-routing-v1-http-api-client-1.1.2.tgz", + "integrity": "sha512-u+sVdOxFieusZh/AxC8c0lU1micWfAosju7A80n62rdJ1fr1lclkhhrlfaKWIgVOq+pwonEzoOE7QgnTL22tYw==", + "dependencies": { + "@libp2p/interface": "^0.1.2", + "@libp2p/logger": "^3.0.2", + "@libp2p/peer-id": "^3.0.3", + "@multiformats/multiaddr": "^12.1.3", + "any-signal": "^4.1.1", + "browser-readablestream-to-it": "^2.0.3", + "ipns": "^7.0.1", + "it-first": "^3.0.3", + "it-map": "^3.0.4", + "it-ndjson": "^1.0.4", + "multiformats": "^12.1.1", + "p-defer": "^4.0.0", + "p-queue": "^7.3.4", + "uint8arrays": "^4.0.6" + } + }, "node_modules/@helia/interface": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@helia/interface/-/interface-2.0.0.tgz", - "integrity": "sha512-LW8iRyits8/Tyi6KkZy6I8VydJZvdmeI5kxLanbLNgcCKrgE9bgrlUjR1cQXV5N+CDV8Rn9FRp6I7tYEYnTC0Q==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@helia/interface/-/interface-2.1.0.tgz", + "integrity": "sha512-Z7PwuDIR0BODfSMzYcdzgdTYLsshCawAoPvGuuazvBddWSD9y82/QBmsWp6CTkyM/ziEaWbz5wERmRS+wejDLg==", "dependencies": { "@libp2p/interface": "^0.1.1", "interface-blockstore": "^5.0.0", @@ -291,9 +307,9 @@ } }, "node_modules/@helia/unixfs": { - "version": "1.4.2", - "resolved": "https://registry.npmjs.org/@helia/unixfs/-/unixfs-1.4.2.tgz", - "integrity": "sha512-wH/xg++d2fH16aaUJPmB08snPXTgEDwD13uRXQsYqL1A3lgS32RgSQN64Xtb7qfzZ0SzDBtJLeoZDXNJuXDzoQ==", + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/@helia/unixfs/-/unixfs-1.4.3.tgz", + "integrity": "sha512-jS0En8fGhb01XH+nnxo3kQsmc1lwBEdlttAZFvTo7HCjBGPNFuaYdwTqF9S1wMVWV2fWqj7eS2zBZZa0MDsi1Q==", "dependencies": { "@helia/interface": "^2.0.0", "@ipld/dag-pb": "^4.0.0", @@ -348,53 +364,35 @@ "dev": true }, "node_modules/@ipld/dag-cbor": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/@ipld/dag-cbor/-/dag-cbor-9.0.0.tgz", - "integrity": "sha512-zdsiSiYDEOIDW7mmWOYWC9gukjXO+F8wqxz/LfN7iSwTfIyipC8+UQrCbPupFMRb/33XQTZk8yl3My8vUQBRoA==", + "version": "9.0.6", + "resolved": "https://registry.npmjs.org/@ipld/dag-cbor/-/dag-cbor-9.0.6.tgz", + "integrity": "sha512-3kNab5xMppgWw6DVYx2BzmFq8t7I56AGWfp5kaU1fIPkwHVpBRglJJTYsGtbVluCi/s/q97HZM3bC+aDW4sxbQ==", "dependencies": { - "cborg": "^1.10.0", - "multiformats": "^11.0.0" + "cborg": "^4.0.0", + "multiformats": "^12.0.1" }, "engines": { "node": ">=16.0.0", "npm": ">=7.0.0" } }, - "node_modules/@ipld/dag-cbor/node_modules/multiformats": { - "version": "11.0.2", - "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-11.0.2.tgz", - "integrity": "sha512-b5mYMkOkARIuVZCpvijFj9a6m5wMVLC7cf/jIPd5D/ARDOfLC5+IFkbgDXQgcU2goIsTD/O9NY4DI/Mt4OGvlg==", - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" - } - }, "node_modules/@ipld/dag-json": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/@ipld/dag-json/-/dag-json-10.0.1.tgz", - "integrity": "sha512-XE1Eqw3eNVrSfOhtqCM/gwCxEgYFBzkDlkwhEeMmMvhd0rLBfSyVzXbahZSlv97tiTPEIx5rt41gcFAda3W8zg==", + "version": "10.1.5", + "resolved": "https://registry.npmjs.org/@ipld/dag-json/-/dag-json-10.1.5.tgz", + "integrity": "sha512-AIIDRGPgIqVG2K1O42dPDzNOfP0YWV/suGApzpF+YWZLwkwdGVsxjmXcJ/+rwOhRGdjpuq/xQBKPCu1Ao6rdOQ==", "dependencies": { - "cborg": "^1.10.0", - "multiformats": "^11.0.0" + "cborg": "^4.0.0", + "multiformats": "^12.0.1" }, "engines": { "node": ">=16.0.0", "npm": ">=7.0.0" } }, - "node_modules/@ipld/dag-json/node_modules/multiformats": { - "version": "11.0.2", - "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-11.0.2.tgz", - "integrity": "sha512-b5mYMkOkARIuVZCpvijFj9a6m5wMVLC7cf/jIPd5D/ARDOfLC5+IFkbgDXQgcU2goIsTD/O9NY4DI/Mt4OGvlg==", - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" - } - }, "node_modules/@ipld/dag-pb": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/@ipld/dag-pb/-/dag-pb-4.0.5.tgz", - "integrity": "sha512-El2Jhmv6bWuakhvnw1dl6xOhqLeVhlY8DIAJ06NtZRAoDcOzeGzvOtPzMCszVgCT0EQz+LOctyfgQ5Oszba19A==", + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/@ipld/dag-pb/-/dag-pb-4.0.6.tgz", + "integrity": "sha512-wOij3jfDKZsb9yjhQeHp+TQy0pu1vmUkGv324xciFFZ7xGbDfAGTQW03lSA5aJ/7HBBNYgjEE0nvHmNW1Qjfag==", "dependencies": { "multiformats": "^12.0.1" }, @@ -404,43 +402,53 @@ } }, "node_modules/@jridgewell/resolve-uri": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", - "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz", + "integrity": "sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA==", "dev": true, "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/sourcemap-codec": { - "version": "1.4.14", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", - "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", + "version": "1.4.15", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", + "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", "dev": true }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.9", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", + "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.0.3", + "@jridgewell/sourcemap-codec": "^1.4.10" + } + }, "node_modules/@leichtgewicht/ip-codec": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.4.tgz", "integrity": "sha512-Hcv+nVC0kZnQ3tD9GVu5xSMR4VVYOteQIr/hwFPVEvPdlXqgGEuRjiheChHgdM+JyqdgNcmzZOX/tnl0JOiI7A==" }, "node_modules/@libp2p/bootstrap": { - "version": "9.0.6", - "resolved": "https://registry.npmjs.org/@libp2p/bootstrap/-/bootstrap-9.0.6.tgz", - "integrity": "sha512-YvPQT0jkRpW1meVZQMMaJkQFgRgdJjqpT9dD6GcacOc+EbByAUi+sLB1l0VOA5uNa0UoKUNdv50XHfEsD6BFhg==", + "version": "9.0.12", + "resolved": "https://registry.npmjs.org/@libp2p/bootstrap/-/bootstrap-9.0.12.tgz", + "integrity": "sha512-w/Mzq8tNBy4DQJXlIN4mwged/6ZHltsAr/J2Wpv0mijrKrr3PLEF1XWfQtdvNUb/exOlXOMCNwVRcXfeAha1qg==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-id": "^3.0.2", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-id": "^3.0.6", "@multiformats/mafmt": "^12.1.2", "@multiformats/multiaddr": "^12.1.5" } }, "node_modules/@libp2p/crypto": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@libp2p/crypto/-/crypto-2.0.4.tgz", - "integrity": "sha512-1/PDtJC+k64Sd0bzK4DvGflk8Brj5fGskRCfBOndhNmitjHe8+ewbuA9lldTOerfkVgMn7Zb+sjNsytyr6BqlA==", + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@libp2p/crypto/-/crypto-2.0.8.tgz", + "integrity": "sha512-8e5fh6bsJNpSjhrggtlm8QF+BERjelJswIjRS69aKgxp24R4z2kDM4pRYPkfQjXJDLNDtqWtKNmePgX23+QJsA==", "dependencies": { - "@libp2p/interface": "^0.1.2", + "@libp2p/interface": "^0.1.6", "@noble/curves": "^1.1.0", "@noble/hashes": "^1.3.1", "multiformats": "^12.0.1", @@ -451,9 +459,9 @@ } }, "node_modules/@libp2p/interface": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/@libp2p/interface/-/interface-0.1.2.tgz", - "integrity": "sha512-Q5t27434Mvn+R6AUJlRH+q/jSXarDpP+KXVkyGY7S1fKPI2berqoFPqT61bRRBYsCH2OPZiKBB53VUzxL9uEvg==", + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/@libp2p/interface/-/interface-0.1.6.tgz", + "integrity": "sha512-Lzc5cS/hXuoXhuAbVIxJIHLCYmfPcbU0vVgrpMoiP1Qb2Q3ETU4A46GB8s8mWXgSU6tr9RcqerUqzFYD6+OAag==", "dependencies": { "@multiformats/multiaddr": "^12.1.5", "abortable-iterator": "^5.0.1", @@ -461,58 +469,37 @@ "it-stream-types": "^2.0.1", "multiformats": "^12.0.1", "p-defer": "^4.0.0", + "race-signal": "^1.0.0", "uint8arraylist": "^2.4.3" } }, "node_modules/@libp2p/interface-internal": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/@libp2p/interface-internal/-/interface-internal-0.1.5.tgz", - "integrity": "sha512-h6f1fk2M6BhqjooE4I1iODmY/jorCvJ1bX1IOMHOMNkrbwsMS2BOpDkBJD+u+QlKMoRIA2zEfWezXB4Pa8GASw==", + "version": "0.1.12", + "resolved": "https://registry.npmjs.org/@libp2p/interface-internal/-/interface-internal-0.1.12.tgz", + "integrity": "sha512-tUZ4hxU8fO4397p/GtXNvAANHiLA/Uxdil90TuNNCnlb+GZijDYEEJiqBfnk2zYAdwm7Q9iO0fVxZCpfoW8B7Q==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/peer-collections": "^4.0.4", + "@libp2p/interface": "^0.1.6", + "@libp2p/peer-collections": "^4.0.8", "@multiformats/multiaddr": "^12.1.5", "uint8arraylist": "^2.4.3" } }, - "node_modules/@libp2p/ipni-content-routing": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@libp2p/ipni-content-routing/-/ipni-content-routing-2.0.0.tgz", - "integrity": "sha512-6YY7FUJ4KJ8UcrBosEcaRAaB1n/6iJuQ+etdx/8ON49oYIRoqXfTEUGNDORZweStEoktgS8oT8DLKUuAystm0g==", - "dependencies": { - "@libp2p/interface": "^0.1.1", - "@libp2p/logger": "^3.0.1", - "@libp2p/peer-id": "^3.0.1", - "@multiformats/multiaddr": "^12.1.2", - "any-signal": "^4.1.1", - "browser-readablestream-to-it": "^2.0.2", - "iterable-ndjson": "^1.1.0", - "multiformats": "^12.0.1", - "p-defer": "^4.0.0", - "p-queue": "^7.3.4" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" - } - }, "node_modules/@libp2p/kad-dht": { - "version": "10.0.7", - "resolved": "https://registry.npmjs.org/@libp2p/kad-dht/-/kad-dht-10.0.7.tgz", - "integrity": "sha512-ohwae4w62Y0zqFAwK+74oCLxWVpVdqO7sEwEACfuXuzz93lo/SR1Ynnm2WVGSarrBuBcPh+3nPs9GawakcsrPw==", - "dependencies": { - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/interface-internal": "^0.1.5", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-collections": "^4.0.4", - "@libp2p/peer-id": "^3.0.2", + "version": "10.0.15", + "resolved": "https://registry.npmjs.org/@libp2p/kad-dht/-/kad-dht-10.0.15.tgz", + "integrity": "sha512-S4pQY8t4lXBlicBREThtOHnLn79e07sVgKZPa9SmJ4hC1+i0HFD8XLzrHm3cnKSO/4RhoaF5YdlnZMMjbb7q0w==", + "dependencies": { + "@libp2p/crypto": "^2.0.8", + "@libp2p/interface": "^0.1.6", + "@libp2p/interface-internal": "^0.1.9", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-collections": "^4.0.8", + "@libp2p/peer-id": "^3.0.6", "@multiformats/multiaddr": "^12.1.5", - "@types/sinon": "^10.0.15", + "@types/sinon": "^17.0.0", "abortable-iterator": "^5.0.1", "any-signal": "^4.1.1", "datastore-core": "^9.0.1", - "events": "^3.3.0", "hashlru": "^2.3.0", "interface-datastore": "^8.2.0", "it-all": "^3.0.2", @@ -524,6 +511,7 @@ "it-merge": "^3.0.0", "it-parallel": "^3.0.0", "it-pipe": "^3.0.1", + "it-pushable": "^3.2.1", "it-stream-types": "^2.0.1", "it-take": "^3.0.1", "multiformats": "^12.0.1", @@ -539,14 +527,14 @@ } }, "node_modules/@libp2p/keychain": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@libp2p/keychain/-/keychain-3.0.4.tgz", - "integrity": "sha512-qt9Ttv2lczOpxkbe5YmqwqJx9nty4pWEE9sJ4rY2Ci2k1K+Bt2vMla610BFBzcYq0QqYYqNN4pawFZ33sc3iLg==", - "dependencies": { - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-id": "^3.0.2", + "version": "3.0.8", + "resolved": "https://registry.npmjs.org/@libp2p/keychain/-/keychain-3.0.8.tgz", + "integrity": "sha512-+WmW9bN9WE0uKqTG3DVk+zsd9Np63lLS+uYRhncwCGTvg0HKXq1t+i4Xd8KbZvUv7UVakE8aae1oMezW3nS+2g==", + "dependencies": { + "@libp2p/crypto": "^2.0.8", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-id": "^3.0.6", "interface-datastore": "^8.2.0", "merge-options": "^3.0.4", "sanitize-filename": "^1.6.3", @@ -554,11 +542,11 @@ } }, "node_modules/@libp2p/logger": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@libp2p/logger/-/logger-3.0.2.tgz", - "integrity": "sha512-2JtRGBXiGfm1t5XneUIXQ2JusW7QwyYmxsW7hSAYS5J73RQJUicpt5le5obVRt7+OM39ei+nWEuC6Xvm1ugHkw==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@libp2p/logger/-/logger-3.1.0.tgz", + "integrity": "sha512-qJbJBAhxHVsRBtQSOIkSLi0lskUSFjzE+zm0QvoyxzZKSz+mX41mZLbnofPIVOVauoDQ40dXpe7WDUOq8AbiQQ==", "dependencies": { - "@libp2p/interface": "^0.1.2", + "@libp2p/interface": "^0.1.6", "@multiformats/multiaddr": "^12.1.5", "debug": "^4.3.4", "interface-datastore": "^8.2.0", @@ -566,14 +554,14 @@ } }, "node_modules/@libp2p/mdns": { - "version": "9.0.8", - "resolved": "https://registry.npmjs.org/@libp2p/mdns/-/mdns-9.0.8.tgz", - "integrity": "sha512-RRuMDed11kAeszvSxESFOfMVKwoNOrbm1bLIkaZt/epaLOIXfeyynnQhK5I3vPQc6FHzh+NiGBCtjzKlDj0J3g==", - "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-id": "^3.0.2", - "@libp2p/utils": "^4.0.3", + "version": "9.0.14", + "resolved": "https://registry.npmjs.org/@libp2p/mdns/-/mdns-9.0.14.tgz", + "integrity": "sha512-kS+hEGnA4X3AUknn6N/RiUu72AomiYyD0mwHtyPdcTmYYI6VNKWkniS95wQKXMSaHk+pEN7NAugTXJf478jkRg==", + "dependencies": { + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-id": "^3.0.6", + "@libp2p/utils": "^4.0.7", "@multiformats/multiaddr": "^12.1.5", "@types/multicast-dns": "^7.2.1", "dns-packet": "^5.4.0", @@ -581,12 +569,12 @@ } }, "node_modules/@libp2p/mplex": { - "version": "9.0.6", - "resolved": "https://registry.npmjs.org/@libp2p/mplex/-/mplex-9.0.6.tgz", - "integrity": "sha512-MlfJ7V/mQwLKQtVZJrnWHcPsvvYnY5sUSiO1+rRuYQvmXxy2iFdtm7peAhlsL6a5hTdIAJjPdURBlNSVBxaF4A==", + "version": "9.0.12", + "resolved": "https://registry.npmjs.org/@libp2p/mplex/-/mplex-9.0.12.tgz", + "integrity": "sha512-ll+fsz9zJ9OW3Z14hN4uh5JDQWIfudp2HTsSKoBiiFnKNY58tMH01iijNtHXGyGiVPmFCPeJf01oPlx0j9OgDQ==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", "abortable-iterator": "^5.0.1", "benchmark": "^2.1.4", "it-batched-bytes": "^2.0.2", @@ -599,12 +587,12 @@ } }, "node_modules/@libp2p/multistream-select": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/@libp2p/multistream-select/-/multistream-select-4.0.2.tgz", - "integrity": "sha512-Ss3kPD+1Z8RFLUT+oN9I2ynEtp/Yj2+rOngU1XjIxustg1nt5lq0kk9hvWJyBexzmuML0xCknNjUXovpRbFPgQ==", + "version": "4.0.10", + "resolved": "https://registry.npmjs.org/@libp2p/multistream-select/-/multistream-select-4.0.10.tgz", + "integrity": "sha512-f0BDv96L2yF9SZ0YXdg41JcGWwPBGZNAoeFGkna38SMFtj00NQWBOwAjqVdhrYVF58ymB0Ci6OfMzYv1XHVj/A==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", "abortable-iterator": "^5.0.1", "it-first": "^3.0.1", "it-handshake": "^4.1.3", @@ -614,38 +602,53 @@ "it-pushable": "^3.2.0", "it-reader": "^6.0.1", "it-stream-types": "^2.0.1", + "uint8-varint": "^2.0.0", "uint8arraylist": "^2.4.3", "uint8arrays": "^4.0.6" } }, "node_modules/@libp2p/peer-collections": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@libp2p/peer-collections/-/peer-collections-4.0.4.tgz", - "integrity": "sha512-MGuTtt6a2TLUlr4b1dUAOd43SAe/lxLZX3E9iYeRqI9IWzw6cwvvOzGNTYwAlkBpASCmm0aJpGXDA/r6lpIzMQ==", + "version": "4.0.11", + "resolved": "https://registry.npmjs.org/@libp2p/peer-collections/-/peer-collections-4.0.11.tgz", + "integrity": "sha512-4bHtIm3VfYMm2laRuebkswQukgQmWTUbExnu1sD5vcbI186aCZ7P56QjWyOIMn3XflIoZ0cx9AXX/WuDQSolDA==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/peer-id": "^3.0.2" + "@libp2p/interface": "^0.1.6", + "@libp2p/peer-id": "^3.0.6" } }, "node_modules/@libp2p/peer-id": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@libp2p/peer-id/-/peer-id-3.0.2.tgz", - "integrity": "sha512-133qGXu9UBiqsYm7nBDJaAh4eiKe79DPLKF+/aRu0Z7gKcX7I0+LewEky4kBt3olhYQSF1CAnJIzD8Dmsn40Yw==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@libp2p/peer-id/-/peer-id-3.0.6.tgz", + "integrity": "sha512-iN1Ia5gH2U1V/GOVRmLHmVY6fblxzrOPUoZrMYjHl/K4s+AiI7ym/527WDeQvhQpD7j3TfDwcAYforD2dLGpLw==", "dependencies": { - "@libp2p/interface": "^0.1.2", + "@libp2p/interface": "^0.1.6", "multiformats": "^12.0.1", "uint8arrays": "^4.0.6" } }, - "node_modules/@libp2p/peer-record": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/@libp2p/peer-record/-/peer-record-6.0.5.tgz", - "integrity": "sha512-+nJpi9L6X+cYdu1UWL/W36+3pmL0Ev7/HpX9J/bESsICP8rSN2N1aFlekqJq2v7TW4dJ3VJO7TcMZCcKcLhZCQ==", + "node_modules/@libp2p/peer-id-factory": { + "version": "3.0.11", + "resolved": "https://registry.npmjs.org/@libp2p/peer-id-factory/-/peer-id-factory-3.0.11.tgz", + "integrity": "sha512-BmXKgeyAGezPyoY/uni95t439+AE0eqEKMxjfkfy2Hv/LcJ9gdR3zjRl7Hzci1O12b+yeVFtYVU8DZtBCcsZjQ==", "dependencies": { - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/peer-id": "^3.0.2", - "@libp2p/utils": "^4.0.3", + "@libp2p/crypto": "^2.0.8", + "@libp2p/interface": "^0.1.6", + "@libp2p/peer-id": "^3.0.6", + "multiformats": "^12.0.1", + "protons-runtime": "^5.0.0", + "uint8arraylist": "^2.4.3", + "uint8arrays": "^4.0.6" + } + }, + "node_modules/@libp2p/peer-record": { + "version": "6.0.12", + "resolved": "https://registry.npmjs.org/@libp2p/peer-record/-/peer-record-6.0.12.tgz", + "integrity": "sha512-8IItsbcPeIaFC5QMZD+gGl/dDbwLjE9nrmL7ZAOvMwcfZx+2AVZPN/6nubahO/wQrchpvBYiK3TxaWGnOH8sIA==", + "dependencies": { + "@libp2p/crypto": "^2.0.8", + "@libp2p/interface": "^0.1.6", + "@libp2p/peer-id": "^3.0.6", + "@libp2p/utils": "^4.0.7", "@multiformats/multiaddr": "^12.1.5", "protons-runtime": "^5.0.0", "uint8-varint": "^2.0.0", @@ -654,16 +657,16 @@ } }, "node_modules/@libp2p/peer-store": { - "version": "9.0.5", - "resolved": "https://registry.npmjs.org/@libp2p/peer-store/-/peer-store-9.0.5.tgz", - "integrity": "sha512-LUYN2i58F/eVvrFEYCIfArMNZaCGy2J2xSG9kd3/iHZqHAyLkuQHnYfHdoJLSUJFcS2pZsFo+c9atVvlOD7w5A==", - "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-collections": "^4.0.4", - "@libp2p/peer-id": "^3.0.2", - "@libp2p/peer-id-factory": "^3.0.4", - "@libp2p/peer-record": "^6.0.5", + "version": "9.0.12", + "resolved": "https://registry.npmjs.org/@libp2p/peer-store/-/peer-store-9.0.12.tgz", + "integrity": "sha512-rYpUUhvDI7GTfMFWNJ+HQoEOAVOxfp3t0bgJWLvUFKNtULojEk0znKHa6da7hX2KE06wM7ZEMfF23jZCmrwk1g==", + "dependencies": { + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-collections": "^4.0.8", + "@libp2p/peer-id": "^3.0.6", + "@libp2p/peer-id-factory": "^3.0.8", + "@libp2p/peer-record": "^6.0.9", "@multiformats/multiaddr": "^12.1.5", "interface-datastore": "^8.2.0", "it-all": "^3.0.2", @@ -674,31 +677,17 @@ "uint8arrays": "^4.0.6" } }, - "node_modules/@libp2p/peer-store/node_modules/@libp2p/peer-id-factory": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@libp2p/peer-id-factory/-/peer-id-factory-3.0.4.tgz", - "integrity": "sha512-9xpKb1UdAhKVmPHy/jssOnyJkuyyyIeP5tO3HlaiBQNtDZU66UMQORnEUD6HdYHKfBRInah2JHxTCtm2nUhGcw==", - "dependencies": { - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/peer-id": "^3.0.2", - "multiformats": "^12.0.1", - "protons-runtime": "^5.0.0", - "uint8arraylist": "^2.4.3", - "uint8arrays": "^4.0.6" - } - }, "node_modules/@libp2p/pubsub": { - "version": "8.0.6", - "resolved": "https://registry.npmjs.org/@libp2p/pubsub/-/pubsub-8.0.6.tgz", - "integrity": "sha512-0M53aqvSNHVkMgiyZwyvyrOKP95mJx2ddDedGNYSK8tkvd8Ap98qT1feyI9iT13ihFadkSVJPK5urOLSGLX+3Q==", - "dependencies": { - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/interface-internal": "^0.1.5", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-collections": "^4.0.4", - "@libp2p/peer-id": "^3.0.2", + "version": "8.0.14", + "resolved": "https://registry.npmjs.org/@libp2p/pubsub/-/pubsub-8.0.14.tgz", + "integrity": "sha512-hkNqUC6ef96WxqYFnmG0CKy9Vvb0mum5IrllUypwWiV0iK1zj8PcqO8oyTjLl/waLG56Kuy8CAjahnMov+U3dw==", + "dependencies": { + "@libp2p/crypto": "^2.0.8", + "@libp2p/interface": "^0.1.6", + "@libp2p/interface-internal": "^0.1.9", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-collections": "^4.0.8", + "@libp2p/peer-id": "^3.0.6", "abortable-iterator": "^5.0.1", "it-length-prefixed": "^9.0.1", "it-pipe": "^3.0.1", @@ -710,27 +699,27 @@ } }, "node_modules/@libp2p/tcp": { - "version": "8.0.7", - "resolved": "https://registry.npmjs.org/@libp2p/tcp/-/tcp-8.0.7.tgz", - "integrity": "sha512-VYfIlxxLr7my8qi/vMenMfYQFNCGT63m5/PnM2lMG1THxswT8uKov3XMEWRHFnOCem6WkVBZgw+OrGyEetPcrw==", + "version": "8.0.13", + "resolved": "https://registry.npmjs.org/@libp2p/tcp/-/tcp-8.0.13.tgz", + "integrity": "sha512-uN8p1gONoD7z8NteDE3a7F8yy9HblC3b9zX39L2/ztrqeAPiqRfGpBhXK+osXXj07jjnjhSNLBSVNHJNSmADRg==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/utils": "^4.0.3", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/utils": "^4.0.7", "@multiformats/mafmt": "^12.1.2", "@multiformats/multiaddr": "^12.1.5", - "@types/sinon": "^10.0.15", + "@types/sinon": "^17.0.0", "stream-to-it": "^0.2.2" } }, "node_modules/@libp2p/utils": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/@libp2p/utils/-/utils-4.0.3.tgz", - "integrity": "sha512-jusH8y4G9YluKRm63EPIiN9fNv0hVtfKY7O0nsLI14o0/W/WJhTsQWm+kPOfvoAgCIqAVrxefBqAmFGiiYPnvg==", + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/@libp2p/utils/-/utils-4.0.7.tgz", + "integrity": "sha512-xA6mS4II14870/DmmI3GFRWdNwHeOd2QV3ltatpdVmeEQpdn82jjtCzqn45AChjCugFOskOthXnQiWp+FvdKZg==", "dependencies": { "@chainsafe/is-ip": "^2.0.2", - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", "@multiformats/multiaddr": "^12.1.5", "@multiformats/multiaddr-matcher": "^1.0.1", "is-loopback-addr": "^2.0.1", @@ -740,18 +729,20 @@ } }, "node_modules/@libp2p/webrtc": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/@libp2p/webrtc/-/webrtc-3.2.0.tgz", - "integrity": "sha512-hV2lqEVpinIgXcsRjTmn4lYsx7BjzH3kS8V4YQF4Vqyih0xQNxjNNkayiLAXDBsHOSbU1KsQsu8eUhyAdJyciw==", + "version": "3.2.11", + "resolved": "https://registry.npmjs.org/@libp2p/webrtc/-/webrtc-3.2.11.tgz", + "integrity": "sha512-djp1pgtmIT3zeRaTGMbr6Jl3N7qwcaYlgaNqU3hH5ys/+2SVRIDMwBcsSOuv3414fCM7n0SCRjk3QBYxk0WKNg==", "dependencies": { "@chainsafe/libp2p-noise": "^13.0.0", - "@libp2p/interface": "^0.1.2", - "@libp2p/interface-internal": "^0.1.5", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-id": "^3.0.2", + "@libp2p/interface": "^0.1.6", + "@libp2p/interface-internal": "^0.1.9", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-id": "^3.0.6", "@multiformats/mafmt": "^12.1.2", "@multiformats/multiaddr": "^12.1.5", + "@multiformats/multiaddr-matcher": "^1.0.1", "abortable-iterator": "^5.0.1", + "any-signal": "^4.1.1", "detect-browser": "^5.3.0", "it-length-prefixed": "^9.0.1", "it-pipe": "^3.0.1", @@ -761,22 +752,24 @@ "it-to-buffer": "^4.0.2", "multiformats": "^12.0.1", "multihashes": "^4.0.3", - "node-datachannel": "^0.4.3", + "node-datachannel": "^0.5.0-dev", "p-defer": "^4.0.0", "p-event": "^6.0.0", + "p-timeout": "^6.1.2", "protons-runtime": "^5.0.0", + "race-signal": "^1.0.0", "uint8arraylist": "^2.4.3", "uint8arrays": "^4.0.6" } }, "node_modules/@libp2p/websockets": { - "version": "7.0.7", - "resolved": "https://registry.npmjs.org/@libp2p/websockets/-/websockets-7.0.7.tgz", - "integrity": "sha512-DQvxq9V2Q7VoF5S4j9zZ0VX8QdzdjnLmUNCZ0Ux4IIQ5TU9RAZAvgbYBeIlQEQwL1iK9vFzjMhcSfYZTpTVKFA==", + "version": "7.0.13", + "resolved": "https://registry.npmjs.org/@libp2p/websockets/-/websockets-7.0.13.tgz", + "integrity": "sha512-frRvTtk7++bJ/JLEX8iulpHAMMkEfroWDn2RhiY24SMPwkHWs3CZwm0P6nQ6p0YHft3OQfwPZaqBu0KItxnVHQ==", "dependencies": { - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/utils": "^4.0.3", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/utils": "^4.0.7", "@multiformats/mafmt": "^12.1.2", "@multiformats/multiaddr": "^12.1.5", "@multiformats/multiaddr-to-uri": "^9.0.2", @@ -789,14 +782,14 @@ } }, "node_modules/@libp2p/webtransport": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@libp2p/webtransport/-/webtransport-3.1.0.tgz", - "integrity": "sha512-Au4gEnAM3BaS8e8/Gt6IR/lXEWIU4OxFXGXCfAK6NSTFGw8W0//DcjSXrjg+eDsfBCYdhZL49gvgvo7Lh75YFA==", + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/@libp2p/webtransport/-/webtransport-3.1.10.tgz", + "integrity": "sha512-8bdnqs9Jz1D5Wy+VDMluW9HsD2A712PZMmYTbBXEG4BabDWHI6l2UdJDt4zkaP1rqn+o9YooipA0wZU34MuiSA==", "dependencies": { "@chainsafe/libp2p-noise": "^13.0.0", - "@libp2p/interface": "^0.1.2", - "@libp2p/logger": "^3.0.2", - "@libp2p/peer-id": "^3.0.2", + "@libp2p/interface": "^0.1.6", + "@libp2p/logger": "^3.1.0", + "@libp2p/peer-id": "^3.0.6", "@multiformats/multiaddr": "^12.1.5", "@multiformats/multiaddr-matcher": "^1.0.1", "it-stream-types": "^2.0.1", @@ -819,27 +812,23 @@ } }, "node_modules/@multiformats/multiaddr": { - "version": "12.1.7", - "resolved": "https://registry.npmjs.org/@multiformats/multiaddr/-/multiaddr-12.1.7.tgz", - "integrity": "sha512-MZRj+uUrtF2WqgByrsPolrdyPDSFstw7Fe0ewabWgWl27fcOmfDOSrEt2aUVkSzapXbyCG7JQh0QvimmTF4aMA==", + "version": "12.1.11", + "resolved": "https://registry.npmjs.org/@multiformats/multiaddr/-/multiaddr-12.1.11.tgz", + "integrity": "sha512-CWG9kETEGTTMdr1T+/JEuMwFld3r3fHNP8LkLoUcLvHRy6yr8sWdotVGEDNEdDO/vrKhuD7bQBws3xMSMMyylg==", "dependencies": { "@chainsafe/is-ip": "^2.0.1", "@chainsafe/netmask": "^2.0.0", - "@libp2p/interface": "^0.1.1", - "dns-over-http-resolver": "^2.1.0", + "@libp2p/interface": "^1.0.0", + "dns-over-http-resolver": "3.0.0", "multiformats": "^12.0.1", "uint8-varint": "^2.0.1", "uint8arrays": "^4.0.2" - }, - "engines": { - "node": ">=18.0.0", - "npm": ">=8.6.0" } }, "node_modules/@multiformats/multiaddr-matcher": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@multiformats/multiaddr-matcher/-/multiaddr-matcher-1.0.2.tgz", - "integrity": "sha512-YzviFV31TsDbatWhEmkNnpWC82F/Wfc+alaOBT94Lk6KJeKKfzsaLhYPsjyhElXiUtCKvB3p5e4+WsE5ZYy1kg==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@multiformats/multiaddr-matcher/-/multiaddr-matcher-1.1.0.tgz", + "integrity": "sha512-B/QbKpAxaHYVXFnbTdTgYqPDxmqoF2RYffwYoOv1MWfi2vBCZLdzmEKUBKv6fQr6s+LJFSHn2j2vczmwMFCQIA==", "dependencies": { "@chainsafe/is-ip": "^2.0.1", "@multiformats/multiaddr": "^12.0.0", @@ -858,10 +847,22 @@ "npm": ">=7.0.0" } }, + "node_modules/@multiformats/multiaddr/node_modules/@libp2p/interface": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/interface/-/interface-1.0.2.tgz", + "integrity": "sha512-z/3Yyg+7cVyzRXwzdrDkJd7YmNaLE9iZjQaixo5luI/n9uk5OFFjb9ulAsNqpq8V1xylCo2DXIC7f94KClwzVw==", + "dependencies": { + "@multiformats/multiaddr": "^12.1.10", + "it-pushable": "^3.2.1", + "it-stream-types": "^2.0.1", + "multiformats": "^12.1.3", + "uint8arraylist": "^2.4.3" + } + }, "node_modules/@multiformats/murmur3": { - "version": "2.1.6", - "resolved": "https://registry.npmjs.org/@multiformats/murmur3/-/murmur3-2.1.6.tgz", - "integrity": "sha512-kpJDN+o8B0gJaaqbdV/spIVPj35hqew4rEw8VzPmcITsLpHSgP8pJDeaVaGGVeX/UM8n4IGctLCxw7PBfVks+A==", + "version": "2.1.7", + "resolved": "https://registry.npmjs.org/@multiformats/murmur3/-/murmur3-2.1.7.tgz", + "integrity": "sha512-Yf0UpAaONjed+8PTt5NM/GG4Z4Ai4m1qfT7bqevjnkwRQ12K+0jxtRomirz+VJx4PokpA2St1ZSD1iMkZTqPRQ==", "dependencies": { "multiformats": "^12.0.1", "murmurhash3js-revisited": "^3.0.0" @@ -872,28 +873,28 @@ } }, "node_modules/@noble/ciphers": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/@noble/ciphers/-/ciphers-0.3.0.tgz", - "integrity": "sha512-ldbrnOjmNRwFdXcTM6uXDcxpMIFrbzAWNnpBPp4oTJTFF0XByGD6vf45WrehZGXRQTRVV+Zm8YP+EgEf+e4cWA==", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@noble/ciphers/-/ciphers-0.4.1.tgz", + "integrity": "sha512-QCOA9cgf3Rc33owG0AYBB9wszz+Ul2kramWN8tXG44Gyciud/tbkEqvxRF/IpqQaBpRBNi9f4jdNxqB2CQCIXg==", "funding": { "url": "https://paulmillr.com/funding/" } }, "node_modules/@noble/curves": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.2.0.tgz", - "integrity": "sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==", + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.3.0.tgz", + "integrity": "sha512-t01iSXPuN+Eqzb4eBX0S5oubSqXbK/xXa1Ne18Hj8f9pStxztHCE2gfboSp/dZRLSqfuLpRK2nDXDK+W9puocA==", "dependencies": { - "@noble/hashes": "1.3.2" + "@noble/hashes": "1.3.3" }, "funding": { "url": "https://paulmillr.com/funding/" } }, "node_modules/@noble/hashes": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.2.tgz", - "integrity": "sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==", + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.3.tgz", + "integrity": "sha512-V7/fPHgl+jsVPXqqeOzT8egNj2iBIVt+ECeMMG8TdcnTikP3oaBtUVqpT/gYCR68aEBJSF+XbYUxStjbFMqIIA==", "engines": { "node": ">= 16" }, @@ -1015,44 +1016,36 @@ "node": ">=16" } }, - "node_modules/@polkadot/keyring": { - "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/keyring/-/keyring-12.5.1.tgz", - "integrity": "sha512-u6b+Q7wI6WY/vwmJS9uUHy/5hKZ226nTlVNmxjkj9GvrRsQvUSwS94163yHPJwiZJiIv5xK5m0rwCMyoYu+wjA==", + "node_modules/@polkadot/api/node_modules/@polkadot/rpc-provider": { + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/@polkadot/rpc-provider/-/rpc-provider-10.9.1.tgz", + "integrity": "sha512-4QzT2QzD+320+eT6b79sGAA85Tt3Bb8fQvse4r5Mom2iiBd2SO81vOhxSAOaIe4GUsw25VzFJmsbe7+OObItdg==", "dependencies": { - "@polkadot/util": "12.5.1", - "@polkadot/util-crypto": "12.5.1", - "tslib": "^2.6.2" + "@polkadot/keyring": "^12.3.1", + "@polkadot/types": "10.9.1", + "@polkadot/types-support": "10.9.1", + "@polkadot/util": "^12.3.1", + "@polkadot/util-crypto": "^12.3.1", + "@polkadot/x-fetch": "^12.3.1", + "@polkadot/x-global": "^12.3.1", + "@polkadot/x-ws": "^12.3.1", + "eventemitter3": "^5.0.1", + "mock-socket": "^9.2.1", + "nock": "^13.3.1", + "tslib": "^2.5.3" }, "engines": { "node": ">=16" }, - "peerDependencies": { - "@polkadot/util": "12.5.1", - "@polkadot/util-crypto": "12.5.1" - } - }, - "node_modules/@polkadot/networks": { - "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/networks/-/networks-12.5.1.tgz", - "integrity": "sha512-PP6UUdzz6iHHZH4q96cUEhTcydHj16+61sqeaYEJSF6Q9iY+5WVWQ26+rdjmre/EBdrMQkSS/CKy73mO5z/JkQ==", - "dependencies": { - "@polkadot/util": "12.5.1", - "@substrate/ss58-registry": "^1.43.0", - "tslib": "^2.6.2" - }, - "engines": { - "node": ">=16" + "optionalDependencies": { + "@substrate/connect": "0.7.26" } }, - "node_modules/@polkadot/rpc-augment": { + "node_modules/@polkadot/api/node_modules/@polkadot/types-support": { "version": "10.9.1", - "resolved": "https://registry.npmjs.org/@polkadot/rpc-augment/-/rpc-augment-10.9.1.tgz", - "integrity": "sha512-MaLHkNlyqN20ZRYr6uNd1BZr1OsrnX9qLAmsl0mcrri1vPGRH6VHjfFH1RBLkikpWD82v17g0l2hLwdV1ZHMcw==", + "resolved": "https://registry.npmjs.org/@polkadot/types-support/-/types-support-10.9.1.tgz", + "integrity": "sha512-XsieuLDsszvMZQlleacQBfx07i/JkwQV/UxH9q8Hz7Okmaz9pEVEW1h3ka2/cPuC7a4l32JhaORBUYshBZNdJg==", "dependencies": { - "@polkadot/rpc-core": "10.9.1", - "@polkadot/types": "10.9.1", - "@polkadot/types-codec": "10.9.1", "@polkadot/util": "^12.3.1", "tslib": "^2.5.3" }, @@ -1060,11 +1053,165 @@ "node": ">=16" } }, - "node_modules/@polkadot/rpc-core": { - "version": "10.9.1", - "resolved": "https://registry.npmjs.org/@polkadot/rpc-core/-/rpc-core-10.9.1.tgz", - "integrity": "sha512-ZtA8B8SfXSAwVkBlCcKRHw0eSM7ec/sbiNOM5GasXPeRujUgT7lOwSH2GbUZSqe9RfRDMp6DvO9c2JoGc3LLWw==", - "dependencies": { + "node_modules/@polkadot/api/node_modules/@substrate/connect": { + "version": "0.7.26", + "resolved": "https://registry.npmjs.org/@substrate/connect/-/connect-0.7.26.tgz", + "integrity": "sha512-uuGSiroGuKWj1+38n1kY5HReer5iL9bRwPCzuoLtqAOmI1fGI0hsSI2LlNQMAbfRgr7VRHXOk5MTuQf5ulsFRw==", + "optional": true, + "dependencies": { + "@substrate/connect-extension-protocol": "^1.0.1", + "eventemitter3": "^4.0.7", + "smoldot": "1.0.4" + } + }, + "node_modules/@polkadot/api/node_modules/@substrate/connect/node_modules/eventemitter3": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", + "optional": true + }, + "node_modules/@polkadot/api/node_modules/smoldot": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/smoldot/-/smoldot-1.0.4.tgz", + "integrity": "sha512-N3TazI1C4GGrseFH/piWyZCCCRJTRx2QhDfrUKRT4SzILlW5m8ayZ3QTKICcz1C/536T9cbHHJyP7afxI6Mi1A==", + "optional": true, + "dependencies": { + "pako": "^2.0.4", + "ws": "^8.8.1" + } + }, + "node_modules/@polkadot/keyring": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/keyring/-/keyring-12.6.1.tgz", + "integrity": "sha512-cicTctZr5Jy5vgNT2FsNiKoTZnz6zQkgDoIYv79NI+p1Fhwc9C+DN/iMCnk3Cm9vR2gSAd2fSV+Y5iKVDhAmUw==", + "dependencies": { + "@polkadot/util": "12.6.1", + "@polkadot/util-crypto": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@polkadot/util": "12.6.1", + "@polkadot/util-crypto": "12.6.1" + } + }, + "node_modules/@polkadot/keyring/node_modules/@polkadot/util": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/util/-/util-12.6.1.tgz", + "integrity": "sha512-10ra3VfXtK8ZSnWI7zjhvRrhupg3rd4iFC3zCaXmRpOU+AmfIoCFVEmuUuC66gyXiz2/g6k5E6j0lWQCOProSQ==", + "dependencies": { + "@polkadot/x-bigint": "12.6.1", + "@polkadot/x-global": "12.6.1", + "@polkadot/x-textdecoder": "12.6.1", + "@polkadot/x-textencoder": "12.6.1", + "@types/bn.js": "^5.1.5", + "bn.js": "^5.2.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/keyring/node_modules/@polkadot/x-textdecoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.6.1.tgz", + "integrity": "sha512-IasodJeV1f2Nr/VtA207+LXCQEqYcG8y9qB/EQcRsrEP58NbwwxM5Z2obV0lSjJOxRTJ4/OlhUwnLHwcbIp6+g==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/keyring/node_modules/@polkadot/x-textencoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textencoder/-/x-textencoder-12.6.1.tgz", + "integrity": "sha512-sTq/+tXqBhGe01a1rjieSHFh3y935vuRgtahVgVJZnfqh5SmLPgSN5tTPxZWzyx7gHIfotle8laTJbJarv7V1A==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/networks": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/networks/-/networks-12.6.1.tgz", + "integrity": "sha512-pzyirxTYAnsx+6kyLYcUk26e4TLz3cX6p2KhTgAVW77YnpGX5VTKTbYykyXC8fXFd/migeQsLaa2raFN47mwoA==", + "dependencies": { + "@polkadot/util": "12.6.1", + "@substrate/ss58-registry": "^1.44.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/networks/node_modules/@polkadot/util": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/util/-/util-12.6.1.tgz", + "integrity": "sha512-10ra3VfXtK8ZSnWI7zjhvRrhupg3rd4iFC3zCaXmRpOU+AmfIoCFVEmuUuC66gyXiz2/g6k5E6j0lWQCOProSQ==", + "dependencies": { + "@polkadot/x-bigint": "12.6.1", + "@polkadot/x-global": "12.6.1", + "@polkadot/x-textdecoder": "12.6.1", + "@polkadot/x-textencoder": "12.6.1", + "@types/bn.js": "^5.1.5", + "bn.js": "^5.2.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/networks/node_modules/@polkadot/x-textdecoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.6.1.tgz", + "integrity": "sha512-IasodJeV1f2Nr/VtA207+LXCQEqYcG8y9qB/EQcRsrEP58NbwwxM5Z2obV0lSjJOxRTJ4/OlhUwnLHwcbIp6+g==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/networks/node_modules/@polkadot/x-textencoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textencoder/-/x-textencoder-12.6.1.tgz", + "integrity": "sha512-sTq/+tXqBhGe01a1rjieSHFh3y935vuRgtahVgVJZnfqh5SmLPgSN5tTPxZWzyx7gHIfotle8laTJbJarv7V1A==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-augment": { + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/@polkadot/rpc-augment/-/rpc-augment-10.9.1.tgz", + "integrity": "sha512-MaLHkNlyqN20ZRYr6uNd1BZr1OsrnX9qLAmsl0mcrri1vPGRH6VHjfFH1RBLkikpWD82v17g0l2hLwdV1ZHMcw==", + "dependencies": { + "@polkadot/rpc-core": "10.9.1", + "@polkadot/types": "10.9.1", + "@polkadot/types-codec": "10.9.1", + "@polkadot/util": "^12.3.1", + "tslib": "^2.5.3" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/@polkadot/rpc-core": { + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/@polkadot/rpc-core/-/rpc-core-10.9.1.tgz", + "integrity": "sha512-ZtA8B8SfXSAwVkBlCcKRHw0eSM7ec/sbiNOM5GasXPeRujUgT7lOwSH2GbUZSqe9RfRDMp6DvO9c2JoGc3LLWw==", + "dependencies": { "@polkadot/rpc-augment": "10.9.1", "@polkadot/rpc-provider": "10.9.1", "@polkadot/types": "10.9.1", @@ -1076,7 +1223,7 @@ "node": ">=16" } }, - "node_modules/@polkadot/rpc-provider": { + "node_modules/@polkadot/rpc-core/node_modules/@polkadot/rpc-provider": { "version": "10.9.1", "resolved": "https://registry.npmjs.org/@polkadot/rpc-provider/-/rpc-provider-10.9.1.tgz", "integrity": "sha512-4QzT2QzD+320+eT6b79sGAA85Tt3Bb8fQvse4r5Mom2iiBd2SO81vOhxSAOaIe4GUsw25VzFJmsbe7+OObItdg==", @@ -1101,6 +1248,169 @@ "@substrate/connect": "0.7.26" } }, + "node_modules/@polkadot/rpc-core/node_modules/@polkadot/types-support": { + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/@polkadot/types-support/-/types-support-10.9.1.tgz", + "integrity": "sha512-XsieuLDsszvMZQlleacQBfx07i/JkwQV/UxH9q8Hz7Okmaz9pEVEW1h3ka2/cPuC7a4l32JhaORBUYshBZNdJg==", + "dependencies": { + "@polkadot/util": "^12.3.1", + "tslib": "^2.5.3" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/@polkadot/rpc-core/node_modules/@substrate/connect": { + "version": "0.7.26", + "resolved": "https://registry.npmjs.org/@substrate/connect/-/connect-0.7.26.tgz", + "integrity": "sha512-uuGSiroGuKWj1+38n1kY5HReer5iL9bRwPCzuoLtqAOmI1fGI0hsSI2LlNQMAbfRgr7VRHXOk5MTuQf5ulsFRw==", + "optional": true, + "dependencies": { + "@substrate/connect-extension-protocol": "^1.0.1", + "eventemitter3": "^4.0.7", + "smoldot": "1.0.4" + } + }, + "node_modules/@polkadot/rpc-core/node_modules/@substrate/connect/node_modules/eventemitter3": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", + "optional": true + }, + "node_modules/@polkadot/rpc-core/node_modules/smoldot": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/smoldot/-/smoldot-1.0.4.tgz", + "integrity": "sha512-N3TazI1C4GGrseFH/piWyZCCCRJTRx2QhDfrUKRT4SzILlW5m8ayZ3QTKICcz1C/536T9cbHHJyP7afxI6Mi1A==", + "optional": true, + "dependencies": { + "pako": "^2.0.4", + "ws": "^8.8.1" + } + }, + "node_modules/@polkadot/rpc-provider": { + "version": "10.11.1", + "resolved": "https://registry.npmjs.org/@polkadot/rpc-provider/-/rpc-provider-10.11.1.tgz", + "integrity": "sha512-86aDUOnaG42si0jSOAgn6Fs3F3rz57x+iNBK1JpM0PLL2XvmPuoMZL5dZwzqSIey3nVdGJqRYfnFquWuyQpnOQ==", + "dependencies": { + "@polkadot/keyring": "^12.6.1", + "@polkadot/types": "10.11.1", + "@polkadot/types-support": "10.11.1", + "@polkadot/util": "^12.6.1", + "@polkadot/util-crypto": "^12.6.1", + "@polkadot/x-fetch": "^12.6.1", + "@polkadot/x-global": "^12.6.1", + "@polkadot/x-ws": "^12.6.1", + "eventemitter3": "^5.0.1", + "mock-socket": "^9.3.1", + "nock": "^13.3.8", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@substrate/connect": "0.7.35" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/types": { + "version": "10.11.1", + "resolved": "https://registry.npmjs.org/@polkadot/types/-/types-10.11.1.tgz", + "integrity": "sha512-4uKnzW2GZqNA5qRZpTPJ7z+G/ARTvXI89etv9xXXVttUdfTaYZsMf4rMuMThOAE/mAUn70LoH0JKthZLwzVgNQ==", + "dependencies": { + "@polkadot/keyring": "^12.6.1", + "@polkadot/types-augment": "10.11.1", + "@polkadot/types-codec": "10.11.1", + "@polkadot/types-create": "10.11.1", + "@polkadot/util": "^12.6.1", + "@polkadot/util-crypto": "^12.6.1", + "rxjs": "^7.8.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/types-augment": { + "version": "10.11.1", + "resolved": "https://registry.npmjs.org/@polkadot/types-augment/-/types-augment-10.11.1.tgz", + "integrity": "sha512-Exd5mMCuSOXXz73iWqy8ocScWTrwAPqHz0Kxpz5OWlAu+5usipMuhjoeaZA803FHQntZh9lHUN31fuc50Exhew==", + "dependencies": { + "@polkadot/types": "10.11.1", + "@polkadot/types-codec": "10.11.1", + "@polkadot/util": "^12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/types-codec": { + "version": "10.11.1", + "resolved": "https://registry.npmjs.org/@polkadot/types-codec/-/types-codec-10.11.1.tgz", + "integrity": "sha512-B9Fu2hq3cRpJpGPcgfZ8Qi1OSX9u82J46adlbIG95ktoA+70eZ83VS3Zvtt9ACsdLVGETCJfDjSO25XptjhZKQ==", + "dependencies": { + "@polkadot/util": "^12.6.1", + "@polkadot/x-bigint": "^12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/types-create": { + "version": "10.11.1", + "resolved": "https://registry.npmjs.org/@polkadot/types-create/-/types-create-10.11.1.tgz", + "integrity": "sha512-oeaI185F3XeWSz9/fe//qZ0KsQyE6C6c13WuOa+5cX/Yuz7cSAXawrhl58HRaU+fueaE/ijEHLcuK1sdM6e1JQ==", + "dependencies": { + "@polkadot/types-codec": "10.11.1", + "@polkadot/util": "^12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/util": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/util/-/util-12.6.1.tgz", + "integrity": "sha512-10ra3VfXtK8ZSnWI7zjhvRrhupg3rd4iFC3zCaXmRpOU+AmfIoCFVEmuUuC66gyXiz2/g6k5E6j0lWQCOProSQ==", + "dependencies": { + "@polkadot/x-bigint": "12.6.1", + "@polkadot/x-global": "12.6.1", + "@polkadot/x-textdecoder": "12.6.1", + "@polkadot/x-textencoder": "12.6.1", + "@types/bn.js": "^5.1.5", + "bn.js": "^5.2.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/x-textdecoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.6.1.tgz", + "integrity": "sha512-IasodJeV1f2Nr/VtA207+LXCQEqYcG8y9qB/EQcRsrEP58NbwwxM5Z2obV0lSjJOxRTJ4/OlhUwnLHwcbIp6+g==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/rpc-provider/node_modules/@polkadot/x-textencoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textencoder/-/x-textencoder-12.6.1.tgz", + "integrity": "sha512-sTq/+tXqBhGe01a1rjieSHFh3y935vuRgtahVgVJZnfqh5SmLPgSN5tTPxZWzyx7gHIfotle8laTJbJarv7V1A==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/@polkadot/typegen": { "version": "10.9.1", "resolved": "https://registry.npmjs.org/@polkadot/typegen/-/typegen-10.9.1.tgz", @@ -1134,6 +1444,75 @@ "node": ">=16" } }, + "node_modules/@polkadot/typegen/node_modules/@polkadot/rpc-provider": { + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/@polkadot/rpc-provider/-/rpc-provider-10.9.1.tgz", + "integrity": "sha512-4QzT2QzD+320+eT6b79sGAA85Tt3Bb8fQvse4r5Mom2iiBd2SO81vOhxSAOaIe4GUsw25VzFJmsbe7+OObItdg==", + "dev": true, + "dependencies": { + "@polkadot/keyring": "^12.3.1", + "@polkadot/types": "10.9.1", + "@polkadot/types-support": "10.9.1", + "@polkadot/util": "^12.3.1", + "@polkadot/util-crypto": "^12.3.1", + "@polkadot/x-fetch": "^12.3.1", + "@polkadot/x-global": "^12.3.1", + "@polkadot/x-ws": "^12.3.1", + "eventemitter3": "^5.0.1", + "mock-socket": "^9.2.1", + "nock": "^13.3.1", + "tslib": "^2.5.3" + }, + "engines": { + "node": ">=16" + }, + "optionalDependencies": { + "@substrate/connect": "0.7.26" + } + }, + "node_modules/@polkadot/typegen/node_modules/@polkadot/types-support": { + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/@polkadot/types-support/-/types-support-10.9.1.tgz", + "integrity": "sha512-XsieuLDsszvMZQlleacQBfx07i/JkwQV/UxH9q8Hz7Okmaz9pEVEW1h3ka2/cPuC7a4l32JhaORBUYshBZNdJg==", + "dev": true, + "dependencies": { + "@polkadot/util": "^12.3.1", + "tslib": "^2.5.3" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/@polkadot/typegen/node_modules/@substrate/connect": { + "version": "0.7.26", + "resolved": "https://registry.npmjs.org/@substrate/connect/-/connect-0.7.26.tgz", + "integrity": "sha512-uuGSiroGuKWj1+38n1kY5HReer5iL9bRwPCzuoLtqAOmI1fGI0hsSI2LlNQMAbfRgr7VRHXOk5MTuQf5ulsFRw==", + "dev": true, + "optional": true, + "dependencies": { + "@substrate/connect-extension-protocol": "^1.0.1", + "eventemitter3": "^4.0.7", + "smoldot": "1.0.4" + } + }, + "node_modules/@polkadot/typegen/node_modules/@substrate/connect/node_modules/eventemitter3": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", + "dev": true, + "optional": true + }, + "node_modules/@polkadot/typegen/node_modules/smoldot": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/smoldot/-/smoldot-1.0.4.tgz", + "integrity": "sha512-N3TazI1C4GGrseFH/piWyZCCCRJTRx2QhDfrUKRT4SzILlW5m8ayZ3QTKICcz1C/536T9cbHHJyP7afxI6Mi1A==", + "dev": true, + "optional": true, + "dependencies": { + "pako": "^2.0.4", + "ws": "^8.8.1" + } + }, "node_modules/@polkadot/types": { "version": "10.9.1", "resolved": "https://registry.npmjs.org/@polkadot/types/-/types-10.9.1.tgz", @@ -1209,15 +1588,56 @@ } }, "node_modules/@polkadot/types-support": { - "version": "10.9.1", - "resolved": "https://registry.npmjs.org/@polkadot/types-support/-/types-support-10.9.1.tgz", - "integrity": "sha512-XsieuLDsszvMZQlleacQBfx07i/JkwQV/UxH9q8Hz7Okmaz9pEVEW1h3ka2/cPuC7a4l32JhaORBUYshBZNdJg==", + "version": "10.11.1", + "resolved": "https://registry.npmjs.org/@polkadot/types-support/-/types-support-10.11.1.tgz", + "integrity": "sha512-eCvWjdpELsHvXiTq201DdbIeOIaEr53zTD7HqC2wR/Z1bkQuw79Z+CyIU4sp79GL1vZ1PxS7vUH9M3FKNaTl1Q==", "dependencies": { - "@polkadot/util": "^12.3.1", - "tslib": "^2.5.3" + "@polkadot/util": "^12.6.1", + "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" + } + }, + "node_modules/@polkadot/types-support/node_modules/@polkadot/util": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/util/-/util-12.6.1.tgz", + "integrity": "sha512-10ra3VfXtK8ZSnWI7zjhvRrhupg3rd4iFC3zCaXmRpOU+AmfIoCFVEmuUuC66gyXiz2/g6k5E6j0lWQCOProSQ==", + "dependencies": { + "@polkadot/x-bigint": "12.6.1", + "@polkadot/x-global": "12.6.1", + "@polkadot/x-textdecoder": "12.6.1", + "@polkadot/x-textencoder": "12.6.1", + "@types/bn.js": "^5.1.5", + "bn.js": "^5.2.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/types-support/node_modules/@polkadot/x-textdecoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.6.1.tgz", + "integrity": "sha512-IasodJeV1f2Nr/VtA207+LXCQEqYcG8y9qB/EQcRsrEP58NbwwxM5Z2obV0lSjJOxRTJ4/OlhUwnLHwcbIp6+g==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/types-support/node_modules/@polkadot/x-textencoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textencoder/-/x-textencoder-12.6.1.tgz", + "integrity": "sha512-sTq/+tXqBhGe01a1rjieSHFh3y935vuRgtahVgVJZnfqh5SmLPgSN5tTPxZWzyx7gHIfotle8laTJbJarv7V1A==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" } }, "node_modules/@polkadot/util": { @@ -1238,184 +1658,259 @@ } }, "node_modules/@polkadot/util-crypto": { - "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/util-crypto/-/util-crypto-12.5.1.tgz", - "integrity": "sha512-Y8ORbMcsM/VOqSG3DgqutRGQ8XXK+X9M3C8oOEI2Tji65ZsXbh9Yh+ryPLM0oBp/9vqOXjkLgZJbbVuQceOw0A==", + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/util-crypto/-/util-crypto-12.6.1.tgz", + "integrity": "sha512-2ezWFLmdgeDXqB9NAUdgpp3s2rQztNrZLY+y0SJYNOG4ch+PyodTW/qSksnOrVGVdRhZ5OESRE9xvo9LYV5UAw==", "dependencies": { "@noble/curves": "^1.2.0", "@noble/hashes": "^1.3.2", - "@polkadot/networks": "12.5.1", - "@polkadot/util": "12.5.1", - "@polkadot/wasm-crypto": "^7.2.2", - "@polkadot/wasm-util": "^7.2.2", - "@polkadot/x-bigint": "12.5.1", - "@polkadot/x-randomvalues": "12.5.1", + "@polkadot/networks": "12.6.1", + "@polkadot/util": "12.6.1", + "@polkadot/wasm-crypto": "^7.3.1", + "@polkadot/wasm-util": "^7.3.1", + "@polkadot/x-bigint": "12.6.1", + "@polkadot/x-randomvalues": "12.6.1", "@scure/base": "^1.1.3", "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" }, "peerDependencies": { - "@polkadot/util": "12.5.1" + "@polkadot/util": "12.6.1" } }, - "node_modules/@polkadot/wasm-bridge": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/@polkadot/wasm-bridge/-/wasm-bridge-7.2.2.tgz", - "integrity": "sha512-CgNENd65DVYtackOVXXRA0D1RPoCv5+77IdBCf7kNqu6LeAnR4nfTI6qjaApUdN1xRweUsQjSH7tu7VjkMOA0A==", + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/util": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/util/-/util-12.6.1.tgz", + "integrity": "sha512-10ra3VfXtK8ZSnWI7zjhvRrhupg3rd4iFC3zCaXmRpOU+AmfIoCFVEmuUuC66gyXiz2/g6k5E6j0lWQCOProSQ==", "dependencies": { - "@polkadot/wasm-util": "7.2.2", - "tslib": "^2.6.1" + "@polkadot/x-bigint": "12.6.1", + "@polkadot/x-global": "12.6.1", + "@polkadot/x-textdecoder": "12.6.1", + "@polkadot/x-textencoder": "12.6.1", + "@types/bn.js": "^5.1.5", + "bn.js": "^5.2.1", + "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" + } + }, + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/wasm-bridge": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-bridge/-/wasm-bridge-7.3.2.tgz", + "integrity": "sha512-AJEXChcf/nKXd5Q/YLEV5dXQMle3UNT7jcXYmIffZAo/KI394a+/24PaISyQjoNC0fkzS1Q8T5pnGGHmXiVz2g==", + "dependencies": { + "@polkadot/wasm-util": "7.3.2", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" }, "peerDependencies": { "@polkadot/util": "*", "@polkadot/x-randomvalues": "*" } }, - "node_modules/@polkadot/wasm-crypto": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto/-/wasm-crypto-7.2.2.tgz", - "integrity": "sha512-1ZY1rxUTawYm0m1zylvBMFovNIHYgG2v/XoASNp/EMG5c8FQIxCbhJRaTBA983GVq4lN/IAKREKEp9ZbLLqssA==", + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/wasm-crypto": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto/-/wasm-crypto-7.3.2.tgz", + "integrity": "sha512-+neIDLSJ6jjVXsjyZ5oLSv16oIpwp+PxFqTUaZdZDoA2EyFRQB8pP7+qLsMNk+WJuhuJ4qXil/7XiOnZYZ+wxw==", "dependencies": { - "@polkadot/wasm-bridge": "7.2.2", - "@polkadot/wasm-crypto-asmjs": "7.2.2", - "@polkadot/wasm-crypto-init": "7.2.2", - "@polkadot/wasm-crypto-wasm": "7.2.2", - "@polkadot/wasm-util": "7.2.2", - "tslib": "^2.6.1" + "@polkadot/wasm-bridge": "7.3.2", + "@polkadot/wasm-crypto-asmjs": "7.3.2", + "@polkadot/wasm-crypto-init": "7.3.2", + "@polkadot/wasm-crypto-wasm": "7.3.2", + "@polkadot/wasm-util": "7.3.2", + "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" }, "peerDependencies": { "@polkadot/util": "*", "@polkadot/x-randomvalues": "*" } }, - "node_modules/@polkadot/wasm-crypto-asmjs": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto-asmjs/-/wasm-crypto-asmjs-7.2.2.tgz", - "integrity": "sha512-wKg+cpsWQCTSVhjlHuNeB/184rxKqY3vaklacbLOMbUXieIfuDBav5PJdzS3yeiVE60TpYaHW4iX/5OYHS82gg==", + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/wasm-crypto-init": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto-init/-/wasm-crypto-init-7.3.2.tgz", + "integrity": "sha512-FPq73zGmvZtnuJaFV44brze3Lkrki3b4PebxCy9Fplw8nTmisKo9Xxtfew08r0njyYh+uiJRAxPCXadkC9sc8g==", "dependencies": { - "tslib": "^2.6.1" + "@polkadot/wasm-bridge": "7.3.2", + "@polkadot/wasm-crypto-asmjs": "7.3.2", + "@polkadot/wasm-crypto-wasm": "7.3.2", + "@polkadot/wasm-util": "7.3.2", + "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" }, "peerDependencies": { - "@polkadot/util": "*" + "@polkadot/util": "*", + "@polkadot/x-randomvalues": "*" } }, - "node_modules/@polkadot/wasm-crypto-init": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto-init/-/wasm-crypto-init-7.2.2.tgz", - "integrity": "sha512-vD4iPIp9x+SssUIWUenxWLPw4BVIwhXHNMpsV81egK990tvpyIxL205/EF5QRb1mKn8WfWcNFm5tYwwh9NdnnA==", + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/x-randomvalues": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-randomvalues/-/x-randomvalues-12.6.1.tgz", + "integrity": "sha512-1uVKlfYYbgIgGV5v1Dgn960cGovenWm5pmg+aTMeUGXVYiJwRD2zOpLyC1i/tP454iA74j74pmWb8Nkn0tJZUQ==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@polkadot/util": "12.6.1", + "@polkadot/wasm-util": "*" + } + }, + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/x-textdecoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.6.1.tgz", + "integrity": "sha512-IasodJeV1f2Nr/VtA207+LXCQEqYcG8y9qB/EQcRsrEP58NbwwxM5Z2obV0lSjJOxRTJ4/OlhUwnLHwcbIp6+g==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/util-crypto/node_modules/@polkadot/x-textencoder": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-textencoder/-/x-textencoder-12.6.1.tgz", + "integrity": "sha512-sTq/+tXqBhGe01a1rjieSHFh3y935vuRgtahVgVJZnfqh5SmLPgSN5tTPxZWzyx7gHIfotle8laTJbJarv7V1A==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/@polkadot/util/node_modules/@polkadot/x-bigint": { + "version": "12.5.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-bigint/-/x-bigint-12.5.1.tgz", + "integrity": "sha512-Fw39eoN9v0sqxSzfSC5awaDVdzojIiE7d1hRSQgVSrES+8whWvtbYMR0qwbVhTuW7DvogHmye41P9xKMlXZysg==", + "dependencies": { + "@polkadot/x-global": "12.5.1", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/@polkadot/util/node_modules/@polkadot/x-global": { + "version": "12.5.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-global/-/x-global-12.5.1.tgz", + "integrity": "sha512-6K0YtWEg0eXInDOihU5aSzeb1t9TiDdX9ZuRly+58ALSqw5kPZYmQLbzE1d8HWzyXRXK+YH65GtLzfMGqfYHmw==", "dependencies": { - "@polkadot/wasm-bridge": "7.2.2", - "@polkadot/wasm-crypto-asmjs": "7.2.2", - "@polkadot/wasm-crypto-wasm": "7.2.2", - "@polkadot/wasm-util": "7.2.2", - "tslib": "^2.6.1" + "tslib": "^2.6.2" }, "engines": { "node": ">=16" + } + }, + "node_modules/@polkadot/wasm-crypto-asmjs": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto-asmjs/-/wasm-crypto-asmjs-7.3.2.tgz", + "integrity": "sha512-QP5eiUqUFur/2UoF2KKKYJcesc71fXhQFLT3D4ZjG28Mfk2ZPI0QNRUfpcxVQmIUpV5USHg4geCBNuCYsMm20Q==", + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18" }, "peerDependencies": { - "@polkadot/util": "*", - "@polkadot/x-randomvalues": "*" + "@polkadot/util": "*" } }, "node_modules/@polkadot/wasm-crypto-wasm": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto-wasm/-/wasm-crypto-wasm-7.2.2.tgz", - "integrity": "sha512-3efoIB6jA3Hhv6k0YIBwCtlC8gCSWCk+R296yIXRLLr3cGN415KM/PO/d1JIXYI64lbrRzWRmZRhllw3jf6Atg==", + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-crypto-wasm/-/wasm-crypto-wasm-7.3.2.tgz", + "integrity": "sha512-15wd0EMv9IXs5Abp1ZKpKKAVyZPhATIAHfKsyoWCEFDLSOA0/K0QGOxzrAlsrdUkiKZOq7uzSIgIDgW8okx2Mw==", "dependencies": { - "@polkadot/wasm-util": "7.2.2", - "tslib": "^2.6.1" + "@polkadot/wasm-util": "7.3.2", + "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" }, "peerDependencies": { "@polkadot/util": "*" } }, "node_modules/@polkadot/wasm-util": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/@polkadot/wasm-util/-/wasm-util-7.2.2.tgz", - "integrity": "sha512-N/25960ifCc56sBlJZ2h5UBpEPvxBmMLgwYsl7CUuT+ea2LuJW9Xh8VHDN/guYXwmm92/KvuendYkEUykpm/JQ==", + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/@polkadot/wasm-util/-/wasm-util-7.3.2.tgz", + "integrity": "sha512-bmD+Dxo1lTZyZNxbyPE380wd82QsX+43mgCm40boyKrRppXEyQmWT98v/Poc7chLuskYb6X8IQ6lvvK2bGR4Tg==", "dependencies": { - "tslib": "^2.6.1" + "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" }, "peerDependencies": { "@polkadot/util": "*" } }, "node_modules/@polkadot/x-bigint": { - "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/x-bigint/-/x-bigint-12.5.1.tgz", - "integrity": "sha512-Fw39eoN9v0sqxSzfSC5awaDVdzojIiE7d1hRSQgVSrES+8whWvtbYMR0qwbVhTuW7DvogHmye41P9xKMlXZysg==", + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-bigint/-/x-bigint-12.6.1.tgz", + "integrity": "sha512-YlABeVIlgYQZJ4ZpW/+akFGGxw5jMGt4g5vaP7EumlORGneJHzzWJYDmI5v2y7j1zvC9ofOle7z4tRmtN/QDew==", "dependencies": { - "@polkadot/x-global": "12.5.1", + "@polkadot/x-global": "12.6.1", "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" } }, "node_modules/@polkadot/x-fetch": { - "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/x-fetch/-/x-fetch-12.5.1.tgz", - "integrity": "sha512-Bc019lOKCoQJrthiS+H3LwCahGtl5tNnb2HK7xe3DBQIUx9r2HsF/uEngNfMRUFkUYg5TPCLFbEWU8NIREBS1A==", + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-fetch/-/x-fetch-12.6.1.tgz", + "integrity": "sha512-iyBv0ecfCsqGSv26CPJk9vSoKtry/Fn7x549ysA4hlc9KboraMHxOHTpcNZYC/OdgvbFZl40zIXCY0SA1ai8aw==", "dependencies": { - "@polkadot/x-global": "12.5.1", + "@polkadot/x-global": "12.6.1", "node-fetch": "^3.3.2", "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" } }, "node_modules/@polkadot/x-global": { - "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/x-global/-/x-global-12.5.1.tgz", - "integrity": "sha512-6K0YtWEg0eXInDOihU5aSzeb1t9TiDdX9ZuRly+58ALSqw5kPZYmQLbzE1d8HWzyXRXK+YH65GtLzfMGqfYHmw==", + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-global/-/x-global-12.6.1.tgz", + "integrity": "sha512-w5t19HIdBPuyu7X/AiCyH2DsKqxBF0KpF4Ymolnx8PfcSIgnq9ZOmgs74McPR6FgEmeEkr9uNKujZrsfURi1ug==", "dependencies": { "tslib": "^2.6.2" }, "engines": { - "node": ">=16" + "node": ">=18" } }, - "node_modules/@polkadot/x-randomvalues": { + "node_modules/@polkadot/x-textdecoder": { "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/x-randomvalues/-/x-randomvalues-12.5.1.tgz", - "integrity": "sha512-UsMb1d+77EPNjW78BpHjZLIm4TaIpfqq89OhZP/6gDIoS2V9iE/AK3jOWKm1G7Y2F8XIoX1qzQpuMakjfagFoQ==", + "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.5.1.tgz", + "integrity": "sha512-j2YZGWfwhMC8nHW3BXq10fAPY02ObLL/qoTjCMJ1Cmc/OGq18Ep7k9cXXbjFAq3wf3tUUewt/u/hStKCk3IvfQ==", "dependencies": { "@polkadot/x-global": "12.5.1", "tslib": "^2.6.2" }, "engines": { "node": ">=16" - }, - "peerDependencies": { - "@polkadot/util": "12.5.1", - "@polkadot/wasm-util": "*" } }, - "node_modules/@polkadot/x-textdecoder": { + "node_modules/@polkadot/x-textdecoder/node_modules/@polkadot/x-global": { "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/x-textdecoder/-/x-textdecoder-12.5.1.tgz", - "integrity": "sha512-j2YZGWfwhMC8nHW3BXq10fAPY02ObLL/qoTjCMJ1Cmc/OGq18Ep7k9cXXbjFAq3wf3tUUewt/u/hStKCk3IvfQ==", + "resolved": "https://registry.npmjs.org/@polkadot/x-global/-/x-global-12.5.1.tgz", + "integrity": "sha512-6K0YtWEg0eXInDOihU5aSzeb1t9TiDdX9ZuRly+58ALSqw5kPZYmQLbzE1d8HWzyXRXK+YH65GtLzfMGqfYHmw==", "dependencies": { - "@polkadot/x-global": "12.5.1", "tslib": "^2.6.2" }, "engines": { @@ -1434,19 +1929,30 @@ "node": ">=16" } }, - "node_modules/@polkadot/x-ws": { + "node_modules/@polkadot/x-textencoder/node_modules/@polkadot/x-global": { "version": "12.5.1", - "resolved": "https://registry.npmjs.org/@polkadot/x-ws/-/x-ws-12.5.1.tgz", - "integrity": "sha512-efNMhB3Lh6pW2iTipMkqwrjpuUtb3EwR/jYZftiIGo5tDPB7rqoMOp9s6KRFJEIUfZkLnMUtbkZ5fHzUJaCjmQ==", + "resolved": "https://registry.npmjs.org/@polkadot/x-global/-/x-global-12.5.1.tgz", + "integrity": "sha512-6K0YtWEg0eXInDOihU5aSzeb1t9TiDdX9ZuRly+58ALSqw5kPZYmQLbzE1d8HWzyXRXK+YH65GtLzfMGqfYHmw==", "dependencies": { - "@polkadot/x-global": "12.5.1", - "tslib": "^2.6.2", - "ws": "^8.14.1" + "tslib": "^2.6.2" }, "engines": { "node": ">=16" } }, + "node_modules/@polkadot/x-ws": { + "version": "12.6.1", + "resolved": "https://registry.npmjs.org/@polkadot/x-ws/-/x-ws-12.6.1.tgz", + "integrity": "sha512-fs9V+XekjJLpVLLwxnqq3llqSZu2T/b9brvld8anvzS/htDLPbi7+c5W3VGJ9Po8fS67IsU3HCt0Gu6F6mGrMA==", + "dependencies": { + "@polkadot/x-global": "12.6.1", + "tslib": "^2.6.2", + "ws": "^8.14.2" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/@protobufjs/aspromise": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz", @@ -1502,17 +2008,17 @@ "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==" }, "node_modules/@scure/base": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", - "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==", + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.5.tgz", + "integrity": "sha512-Brj9FiG2W1MRQSTB212YVPRrcbjkv48FoZi/u4l/zds/ieRrqsh7aUf6CLwkAq61oKXr/ZlTzlY66gLIj3TFTQ==", "funding": { "url": "https://paulmillr.com/funding/" } }, "node_modules/@sinonjs/commons": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-2.0.0.tgz", - "integrity": "sha512-uLa0j859mMrg2slwQYdO/AkrOfmH+X6LTVmNTS9CqexuE2IvVORIkSpJLqePAbEnKJ77aMmCwr1NUZ57120Xcg==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.0.tgz", + "integrity": "sha512-jXBtWAF4vmdNmZgD5FoKsVLv3rPgDnLgPbU84LIJ3otV44vJlDRokVng5v8NFJdCf/da9legHcKaRuZs4L7faA==", "dev": true, "dependencies": { "type-detect": "4.0.8" @@ -1527,15 +2033,6 @@ "@sinonjs/commons": "^3.0.0" } }, - "node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.0.tgz", - "integrity": "sha512-jXBtWAF4vmdNmZgD5FoKsVLv3rPgDnLgPbU84LIJ3otV44vJlDRokVng5v8NFJdCf/da9legHcKaRuZs4L7faA==", - "dev": true, - "dependencies": { - "type-detect": "4.0.8" - } - }, "node_modules/@sinonjs/samsam": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/@sinonjs/samsam/-/samsam-8.0.0.tgz", @@ -1547,6 +2044,15 @@ "type-detect": "^4.0.8" } }, + "node_modules/@sinonjs/samsam/node_modules/@sinonjs/commons": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-2.0.0.tgz", + "integrity": "sha512-uLa0j859mMrg2slwQYdO/AkrOfmH+X6LTVmNTS9CqexuE2IvVORIkSpJLqePAbEnKJ77aMmCwr1NUZ57120Xcg==", + "dev": true, + "dependencies": { + "type-detect": "4.0.8" + } + }, "node_modules/@sinonjs/text-encoding": { "version": "0.7.2", "resolved": "https://registry.npmjs.org/@sinonjs/text-encoding/-/text-encoding-0.7.2.tgz", @@ -1554,14 +2060,14 @@ "dev": true }, "node_modules/@substrate/connect": { - "version": "0.7.26", - "resolved": "https://registry.npmjs.org/@substrate/connect/-/connect-0.7.26.tgz", - "integrity": "sha512-uuGSiroGuKWj1+38n1kY5HReer5iL9bRwPCzuoLtqAOmI1fGI0hsSI2LlNQMAbfRgr7VRHXOk5MTuQf5ulsFRw==", + "version": "0.7.35", + "resolved": "https://registry.npmjs.org/@substrate/connect/-/connect-0.7.35.tgz", + "integrity": "sha512-Io8vkalbwaye+7yXfG1Nj52tOOoJln2bMlc7Q9Yy3vEWqZEVkgKmcPVzbwV0CWL3QD+KMPDA2Dnw/X7EdwgoLw==", + "hasInstallScript": true, "optional": true, "dependencies": { "@substrate/connect-extension-protocol": "^1.0.1", - "eventemitter3": "^4.0.7", - "smoldot": "1.0.4" + "smoldot": "2.0.7" } }, "node_modules/@substrate/connect-extension-protocol": { @@ -1570,16 +2076,10 @@ "integrity": "sha512-161JhCC1csjH3GE5mPLEd7HbWtwNSPJBg3p1Ksz9SFlTzj/bgEwudiRN2y5i0MoLGCIJRYKyKGMxVnd29PzNjg==", "optional": true }, - "node_modules/@substrate/connect/node_modules/eventemitter3": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", - "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", - "optional": true - }, "node_modules/@substrate/ss58-registry": { - "version": "1.43.0", - "resolved": "https://registry.npmjs.org/@substrate/ss58-registry/-/ss58-registry-1.43.0.tgz", - "integrity": "sha512-USEkXA46P9sqClL7PZv0QFsit4S8Im97wchKG0/H/9q3AT/S76r40UHfCr4Un7eBJPE23f7fU9BZ0ITpP9MCsA==" + "version": "1.44.0", + "resolved": "https://registry.npmjs.org/@substrate/ss58-registry/-/ss58-registry-1.44.0.tgz", + "integrity": "sha512-7lQ/7mMCzVNSEfDS4BCqnRnKCFKpcOaPrxMeGTXHX1YQzM/m2BBHjbK2C3dJvjv7GYxMiaTq/HdWQj1xS6ss+A==" }, "node_modules/@tsconfig/node10": { "version": "1.0.9", @@ -1600,52 +2100,55 @@ "dev": true }, "node_modules/@tsconfig/node16": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz", - "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz", + "integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==", "dev": true }, "node_modules/@types/bn.js": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-5.1.1.tgz", - "integrity": "sha512-qNrYbZqMx0uJAfKnKclPh+dTwK33KfLHYqtyODwd5HnXOjnkhc4qgn3BrK6RWyGZm5+sIFE7Q7Vz6QQtJB7w7g==", + "version": "5.1.5", + "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-5.1.5.tgz", + "integrity": "sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==", "dependencies": { "@types/node": "*" } }, "node_modules/@types/dns-packet": { - "version": "5.6.1", - "resolved": "https://registry.npmjs.org/@types/dns-packet/-/dns-packet-5.6.1.tgz", - "integrity": "sha512-F8X3srlDYXQSVGfjAWl0lxd9mGfYtkneMA0QFQ3BFBw/BUmBlhlAbpRjmvE7LbW3wIxf01KHi20/bPstYK6ssA==", + "version": "5.6.4", + "resolved": "https://registry.npmjs.org/@types/dns-packet/-/dns-packet-5.6.4.tgz", + "integrity": "sha512-R0ORTvCCeujG+upKfV4JlvozKLdQWlpsducXGd1L6ezBChwpjSj9K84F+KoMDsZQ9RhOLTR1hnNrwJHWagY24g==", "dependencies": { "@types/node": "*" } }, "node_modules/@types/json-schema": { - "version": "7.0.14", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.14.tgz", - "integrity": "sha512-U3PUjAudAdJBeC2pgN8uTIKgxrb4nlDF3SF0++EldXQvQBGkpFZMSnwQiIoDU77tv45VgNkl/L4ouD+rEomujw==", + "version": "7.0.15", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", + "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", "dev": true }, "node_modules/@types/mocha": { - "version": "10.0.2", - "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.2.tgz", - "integrity": "sha512-NaHL0+0lLNhX6d9rs+NSt97WH/gIlRHmszXbQ/8/MV/eVcFNdeJ/GYhrFuUc8K7WuPhRhTSdMkCp8VMzhUq85w==", + "version": "10.0.6", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.6.tgz", + "integrity": "sha512-dJvrYWxP/UcXm36Qn36fxhUKu8A/xMRXVT2cliFF1Z7UA9liG5Psj3ezNSZw+5puH2czDXRLcXQxf8JbJt0ejg==", "dev": true }, "node_modules/@types/multicast-dns": { - "version": "7.2.1", - "resolved": "https://registry.npmjs.org/@types/multicast-dns/-/multicast-dns-7.2.1.tgz", - "integrity": "sha512-A2PmB8MRcNVEkw6wzGT5rtBHqyHOVjiRMkJH+zpJKXipSi+GGkHg6JjNFApDiYK9WefJqkVG0taln1VMl4TGfw==", + "version": "7.2.4", + "resolved": "https://registry.npmjs.org/@types/multicast-dns/-/multicast-dns-7.2.4.tgz", + "integrity": "sha512-ib5K4cIDR4Ro5SR3Sx/LROkMDa0BHz0OPaCBL/OSPDsAXEGZ3/KQeS6poBKYVN7BfjXDL9lWNwzyHVgt/wkyCw==", "dependencies": { "@types/dns-packet": "*", "@types/node": "*" } }, "node_modules/@types/node": { - "version": "18.15.11", - "resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.11.tgz", - "integrity": "sha512-E5Kwq2n4SbMzQOn6wnmBjuK9ouqlURrcZDVfbo9ftDDTFt3nk7ZKK4GMOzoYgnpQJKcxwQw+lGaBvvlMo0qN/Q==" + "version": "20.10.4", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.10.4.tgz", + "integrity": "sha512-D08YG6rr8X90YB56tSIuBaddy/UXAA9RKJoFvrsnogAum/0pmjkgi4+2nx96A330FmioegBWmEYQ+syqCFaveg==", + "dependencies": { + "undici-types": "~5.26.4" + } }, "node_modules/@types/retry": { "version": "0.12.2", @@ -1653,52 +2156,52 @@ "integrity": "sha512-XISRgDJ2Tc5q4TRqvgJtzsRkFYNJzZrhTdtMoGVBttwzzQJkPnS3WWTFc7kuDRoPtPakl+T+OfdEUjYJj7Jbow==" }, "node_modules/@types/semver": { - "version": "7.5.4", - "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.4.tgz", - "integrity": "sha512-MMzuxN3GdFwskAnb6fz0orFvhfqi752yjaXylr0Rp4oDg5H0Zn1IuyRhDVvYOwAXoJirx2xuS16I3WjxnAIHiQ==", + "version": "7.5.6", + "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.6.tgz", + "integrity": "sha512-dn1l8LaMea/IjDoHNd9J52uBbInB796CDffS6VdIxvqYCPSG0V0DzHp76GpaWnlhg88uYyPbXCDIowa86ybd5A==", "dev": true }, "node_modules/@types/sinon": { - "version": "10.0.17", - "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.17.tgz", - "integrity": "sha512-+6ILpcixQ0Ma3dHMTLv4rSycbDXkDljgKL+E0nI2RUxxhYTFyPSjt6RVMxh7jUshvyVcBvicb0Ktj+lAJcjgeA==", + "version": "17.0.2", + "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-17.0.2.tgz", + "integrity": "sha512-Zt6heIGsdqERkxctIpvN5Pv3edgBrhoeb3yHyxffd4InN0AX2SVNKSrhdDZKGQICVOxWP/q4DyhpfPNMSrpIiA==", "dependencies": { "@types/sinonjs__fake-timers": "*" } }, "node_modules/@types/sinonjs__fake-timers": { - "version": "8.1.3", - "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.3.tgz", - "integrity": "sha512-4g+2YyWe0Ve+LBh+WUm1697PD0Kdi6coG1eU0YjQbwx61AZ8XbEpL1zIT6WjuUKrCMCROpEaYQPDjBnDouBVAQ==" + "version": "8.1.5", + "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.5.tgz", + "integrity": "sha512-mQkU2jY8jJEF7YHjHvsQO8+3ughTL1mcnn96igfhONmR+fUPSKIkefQYpSe8bsly2Ep7oQbn/6VG5/9/0qcArQ==" }, "node_modules/@types/workerpool": { - "version": "6.4.5", - "resolved": "https://registry.npmjs.org/@types/workerpool/-/workerpool-6.4.5.tgz", - "integrity": "sha512-HO5cN6S9DBWBx0/C6oGJaYZPjmfSCZxoRbbmnkMYTTbIHrzR6iHZ4aHopAvd/IAJBGFUKD7LCPg9aXCBba9GmQ==", + "version": "6.4.7", + "resolved": "https://registry.npmjs.org/@types/workerpool/-/workerpool-6.4.7.tgz", + "integrity": "sha512-DI2U4obcMzFViyNjLw0xXspim++qkAJ4BWRdYPVMMFtOpTvMr6PAk3UTZEoSqnZnvgUkJ3ck97Ybk+iIfuJHMg==", "dev": true, "dependencies": { "@types/node": "*" } }, "node_modules/@types/ws": { - "version": "8.5.6", - "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.6.tgz", - "integrity": "sha512-8B5EO9jLVCy+B58PLHvLDuOD8DRVMgQzq8d55SjLCOn9kqGyqOvy27exVaTio1q1nX5zLu8/6N0n2ThSxOM6tg==", + "version": "8.5.10", + "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.10.tgz", + "integrity": "sha512-vmQSUcfalpIq0R9q7uTo2lXs6eGIpt9wtnLdMv9LVpIjCA/+ufZRozlVoVelIYixx1ugCBKDhn89vnsEGOCx9A==", "dependencies": { "@types/node": "*" } }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-6.10.0.tgz", - "integrity": "sha512-uoLj4g2OTL8rfUQVx2AFO1hp/zja1wABJq77P6IclQs6I/m9GLrm7jCdgzZkvWdDCQf1uEvoa8s8CupsgWQgVg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-6.14.0.tgz", + "integrity": "sha512-1ZJBykBCXaSHG94vMMKmiHoL0MhNHKSVlcHVYZNw+BKxufhqQVTOawNpwwI1P5nIFZ/4jLVop0mcY6mJJDFNaw==", "dev": true, "dependencies": { "@eslint-community/regexpp": "^4.5.1", - "@typescript-eslint/scope-manager": "6.10.0", - "@typescript-eslint/type-utils": "6.10.0", - "@typescript-eslint/utils": "6.10.0", - "@typescript-eslint/visitor-keys": "6.10.0", + "@typescript-eslint/scope-manager": "6.14.0", + "@typescript-eslint/type-utils": "6.14.0", + "@typescript-eslint/utils": "6.14.0", + "@typescript-eslint/visitor-keys": "6.14.0", "debug": "^4.3.4", "graphemer": "^1.4.0", "ignore": "^5.2.4", @@ -1724,15 +2227,15 @@ } }, "node_modules/@typescript-eslint/parser": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-6.10.0.tgz", - "integrity": "sha512-+sZwIj+s+io9ozSxIWbNB5873OSdfeBEH/FR0re14WLI6BaKuSOnnwCJ2foUiu8uXf4dRp1UqHP0vrZ1zXGrog==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-6.14.0.tgz", + "integrity": "sha512-QjToC14CKacd4Pa7JK4GeB/vHmWFJckec49FR4hmIRf97+KXole0T97xxu9IFiPxVQ1DBWrQ5wreLwAGwWAVQA==", "dev": true, "dependencies": { - "@typescript-eslint/scope-manager": "6.10.0", - "@typescript-eslint/types": "6.10.0", - "@typescript-eslint/typescript-estree": "6.10.0", - "@typescript-eslint/visitor-keys": "6.10.0", + "@typescript-eslint/scope-manager": "6.14.0", + "@typescript-eslint/types": "6.14.0", + "@typescript-eslint/typescript-estree": "6.14.0", + "@typescript-eslint/visitor-keys": "6.14.0", "debug": "^4.3.4" }, "engines": { @@ -1752,13 +2255,13 @@ } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-6.10.0.tgz", - "integrity": "sha512-TN/plV7dzqqC2iPNf1KrxozDgZs53Gfgg5ZHyw8erd6jd5Ta/JIEcdCheXFt9b1NYb93a1wmIIVW/2gLkombDg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-6.14.0.tgz", + "integrity": "sha512-VT7CFWHbZipPncAZtuALr9y3EuzY1b1t1AEkIq2bTXUPKw+pHoXflGNG5L+Gv6nKul1cz1VH8fz16IThIU0tdg==", "dev": true, "dependencies": { - "@typescript-eslint/types": "6.10.0", - "@typescript-eslint/visitor-keys": "6.10.0" + "@typescript-eslint/types": "6.14.0", + "@typescript-eslint/visitor-keys": "6.14.0" }, "engines": { "node": "^16.0.0 || >=18.0.0" @@ -1769,13 +2272,13 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-6.10.0.tgz", - "integrity": "sha512-wYpPs3hgTFblMYwbYWPT3eZtaDOjbLyIYuqpwuLBBqhLiuvJ+9sEp2gNRJEtR5N/c9G1uTtQQL5AhV0fEPJYcg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-6.14.0.tgz", + "integrity": "sha512-x6OC9Q7HfYKqjnuNu5a7kffIYs3No30isapRBJl1iCHLitD8O0lFbRcVGiOcuyN837fqXzPZ1NS10maQzZMKqw==", "dev": true, "dependencies": { - "@typescript-eslint/typescript-estree": "6.10.0", - "@typescript-eslint/utils": "6.10.0", + "@typescript-eslint/typescript-estree": "6.14.0", + "@typescript-eslint/utils": "6.14.0", "debug": "^4.3.4", "ts-api-utils": "^1.0.1" }, @@ -1796,9 +2299,9 @@ } }, "node_modules/@typescript-eslint/types": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-6.10.0.tgz", - "integrity": "sha512-36Fq1PWh9dusgo3vH7qmQAj5/AZqARky1Wi6WpINxB6SkQdY5vQoT2/7rW7uBIsPDcvvGCLi4r10p0OJ7ITAeg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-6.14.0.tgz", + "integrity": "sha512-uty9H2K4Xs8E47z3SnXEPRNDfsis8JO27amp2GNCnzGETEW3yTqEIVg5+AI7U276oGF/tw6ZA+UesxeQ104ceA==", "dev": true, "engines": { "node": "^16.0.0 || >=18.0.0" @@ -1809,13 +2312,13 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-6.10.0.tgz", - "integrity": "sha512-ek0Eyuy6P15LJVeghbWhSrBCj/vJpPXXR+EpaRZqou7achUWL8IdYnMSC5WHAeTWswYQuP2hAZgij/bC9fanBg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-6.14.0.tgz", + "integrity": "sha512-yPkaLwK0yH2mZKFE/bXkPAkkFgOv15GJAUzgUVonAbv0Hr4PK/N2yaA/4XQbTZQdygiDkpt5DkxPELqHguNvyw==", "dev": true, "dependencies": { - "@typescript-eslint/types": "6.10.0", - "@typescript-eslint/visitor-keys": "6.10.0", + "@typescript-eslint/types": "6.14.0", + "@typescript-eslint/visitor-keys": "6.14.0", "debug": "^4.3.4", "globby": "^11.1.0", "is-glob": "^4.0.3", @@ -1836,17 +2339,17 @@ } }, "node_modules/@typescript-eslint/utils": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-6.10.0.tgz", - "integrity": "sha512-v+pJ1/RcVyRc0o4wAGux9x42RHmAjIGzPRo538Z8M1tVx6HOnoQBCX/NoadHQlZeC+QO2yr4nNSFWOoraZCAyg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-6.14.0.tgz", + "integrity": "sha512-XwRTnbvRr7Ey9a1NT6jqdKX8y/atWG+8fAIu3z73HSP8h06i3r/ClMhmaF/RGWGW1tHJEwij1uEg2GbEmPYvYg==", "dev": true, "dependencies": { "@eslint-community/eslint-utils": "^4.4.0", "@types/json-schema": "^7.0.12", "@types/semver": "^7.5.0", - "@typescript-eslint/scope-manager": "6.10.0", - "@typescript-eslint/types": "6.10.0", - "@typescript-eslint/typescript-estree": "6.10.0", + "@typescript-eslint/scope-manager": "6.14.0", + "@typescript-eslint/types": "6.14.0", + "@typescript-eslint/typescript-estree": "6.14.0", "semver": "^7.5.4" }, "engines": { @@ -1861,12 +2364,12 @@ } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-6.10.0.tgz", - "integrity": "sha512-xMGluxQIEtOM7bqFCo+rCMh5fqI+ZxV5RUUOa29iVPz1OgCZrtc7rFnz5cLUazlkPKYqX+75iuDq7m0HQ48nCg==", + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-6.14.0.tgz", + "integrity": "sha512-fB5cw6GRhJUz03MrROVuj5Zm/Q+XWlVdIsFj+Zb1Hvqouc8t+XP2H5y53QYU/MGtd2dPg6/vJJlhoX3xc2ehfw==", "dev": true, "dependencies": { - "@typescript-eslint/types": "6.10.0", + "@typescript-eslint/types": "6.14.0", "eslint-visitor-keys": "^3.4.1" }, "engines": { @@ -1902,9 +2405,9 @@ } }, "node_modules/acorn": { - "version": "8.10.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz", - "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==", + "version": "8.11.2", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.2.tgz", + "integrity": "sha512-nc0Axzp/0FILLEVsm4fNwLCwMttvhEI263QtVPQcbpfZZ3ts0hLsZGOpE6czNlid7CJ9MlyH8reXkpsf3YUY4w==", "dev": true, "bin": { "acorn": "bin/acorn" @@ -1923,9 +2426,9 @@ } }, "node_modules/acorn-walk": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", - "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", + "version": "8.3.1", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.1.tgz", + "integrity": "sha512-TgUZgYvqZprrl7YldZNoa9OciCAyZR+Ejm9eXzKCmjsF5IKp/wgQ7Z/ZpjpGTIUPwrHQIcYeI8qDh4PsEwxMbw==", "dev": true, "engines": { "node": ">=0.4.0" @@ -2076,11 +2579,11 @@ } }, "node_modules/blockstore-core": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/blockstore-core/-/blockstore-core-4.3.4.tgz", - "integrity": "sha512-JecnNXiDPEdeS9AeFWO0PUKKmmRMW0D+ggUb4lgK0XMDOUAWmhkaiDPhgBjEKrlya0n60XOjcgBYhg18CUqOFw==", + "version": "4.3.8", + "resolved": "https://registry.npmjs.org/blockstore-core/-/blockstore-core-4.3.8.tgz", + "integrity": "sha512-Agunhjw9w0I1OoJn012OpzJwBRm3Nf+v64N2FaZSsF3UGhoQAu4RePLuIBsZrPh4XRqT5Yg1rHoBYJGDhDmkWQ==", "dependencies": { - "@libp2p/logger": "^3.0.0", + "@libp2p/logger": "^4.0.1", "err-code": "^3.0.1", "interface-blockstore": "^5.0.0", "interface-store": "^5.0.0", @@ -2089,7 +2592,39 @@ "it-merge": "^3.0.1", "it-pushable": "^3.0.0", "multiformats": "^12.0.1", - "uint8arrays": "^4.0.2" + "uint8arrays": "^5.0.0" + } + }, + "node_modules/blockstore-core/node_modules/@libp2p/interface": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/interface/-/interface-1.0.2.tgz", + "integrity": "sha512-z/3Yyg+7cVyzRXwzdrDkJd7YmNaLE9iZjQaixo5luI/n9uk5OFFjb9ulAsNqpq8V1xylCo2DXIC7f94KClwzVw==", + "dependencies": { + "@multiformats/multiaddr": "^12.1.10", + "it-pushable": "^3.2.1", + "it-stream-types": "^2.0.1", + "multiformats": "^12.1.3", + "uint8arraylist": "^2.4.3" + } + }, + "node_modules/blockstore-core/node_modules/@libp2p/logger": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/logger/-/logger-4.0.2.tgz", + "integrity": "sha512-J9UMtMU9BKXNp+3c5kcI7HyWOPYg2B2E6sn1gEQckiSexTaz0wKJSlgTZ89f9F8bkC3AaC8ybXYuHbFQhwpTIg==", + "dependencies": { + "@libp2p/interface": "^1.0.2", + "@multiformats/multiaddr": "^12.1.10", + "debug": "^4.3.4", + "interface-datastore": "^8.2.0", + "multiformats": "^12.1.3" + } + }, + "node_modules/blockstore-core/node_modules/uint8arrays": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-5.0.0.tgz", + "integrity": "sha512-RWO7gR4x6syxnKDfZO8mDCsaaYs1/BqZCxlHgrcRge50E9GTnLmtoA4kwFSGIL4s3dQkryeTkvtG6oEFEya3yg==", + "dependencies": { + "multiformats": "^12.0.1" } }, "node_modules/bn.js": { @@ -2120,9 +2655,9 @@ } }, "node_modules/browser-readablestream-to-it": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/browser-readablestream-to-it/-/browser-readablestream-to-it-2.0.4.tgz", - "integrity": "sha512-EOjEEA+tJInvKg/Pml6QYxVY6gD8lka/ceLmkUbEeuWlzZx/a5k5ugupVFUUKSfI/88+v0VFs7JSFi5iYpp3IA==" + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/browser-readablestream-to-it/-/browser-readablestream-to-it-2.0.5.tgz", + "integrity": "sha512-obLCT9jnxAeZlbaRWluUiZrcSJEoi2JkM0eoiJqlIP7MFwZwZjcB6giZvD343PXfr96ilD91M/wFqFvyAZq+Gg==" }, "node_modules/browser-stdout": { "version": "1.3.1", @@ -2153,20 +2688,6 @@ "ieee754": "^1.2.1" } }, - "node_modules/bufferutil": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/bufferutil/-/bufferutil-4.0.7.tgz", - "integrity": "sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw==", - "hasInstallScript": true, - "optional": true, - "peer": true, - "dependencies": { - "node-gyp-build": "^4.3.0" - }, - "engines": { - "node": ">=6.14.2" - } - }, "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", @@ -2176,12 +2697,24 @@ "node": ">=6" } }, + "node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/cborg": { - "version": "1.10.1", - "resolved": "https://registry.npmjs.org/cborg/-/cborg-1.10.1.tgz", - "integrity": "sha512-et6Qm8MOUY2kCWa5GKk2MlBVoPjHv0hQBmlzI/Z7+5V3VJCeIkGehIB3vWknNsm2kOkAIs6wEKJFJo8luWQQ/w==", + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/cborg/-/cborg-4.0.5.tgz", + "integrity": "sha512-q8TAjprr8pn9Fp53rOIGp/UFDdFY6os2Nq62YogPSIzczJD9M6g2b6igxMkpCiZZKJ0kn/KzDLDvG+EqBIEeCg==", "bin": { - "cborg": "cli.js" + "cborg": "lib/bin.js" } }, "node_modules/chalk": { @@ -2239,6 +2772,11 @@ "node": ">= 6" } }, + "node_modules/chownr": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", + "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==" + }, "node_modules/cliui": { "version": "8.0.1", "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", @@ -2305,11 +2843,11 @@ } }, "node_modules/datastore-core": { - "version": "9.2.3", - "resolved": "https://registry.npmjs.org/datastore-core/-/datastore-core-9.2.3.tgz", - "integrity": "sha512-jcvrVDt+jp7lUp2WhMXXgX/hoi3VcJebN+z/ZXbIRKOVfNOF4bl8cvr7sQ1y9qITikgC2coXFYd79Wzt/n13ZQ==", + "version": "9.2.6", + "resolved": "https://registry.npmjs.org/datastore-core/-/datastore-core-9.2.6.tgz", + "integrity": "sha512-7Y79V6Iw5v8Ie2jCT6wiDBaWfZuTPzM3NcJxXOyEGRLJT0qgxa24Yxym83tTuu6rTOB+a+yZZWj0jB4F5lyg8w==", "dependencies": { - "@libp2p/logger": "^3.0.0", + "@libp2p/logger": "^4.0.1", "err-code": "^3.0.1", "interface-store": "^5.0.0", "it-all": "^3.0.1", @@ -2321,7 +2859,39 @@ "it-pushable": "^3.0.0", "it-sort": "^3.0.1", "it-take": "^3.0.1", - "uint8arrays": "^4.0.2" + "uint8arrays": "^5.0.0" + } + }, + "node_modules/datastore-core/node_modules/@libp2p/interface": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/interface/-/interface-1.0.2.tgz", + "integrity": "sha512-z/3Yyg+7cVyzRXwzdrDkJd7YmNaLE9iZjQaixo5luI/n9uk5OFFjb9ulAsNqpq8V1xylCo2DXIC7f94KClwzVw==", + "dependencies": { + "@multiformats/multiaddr": "^12.1.10", + "it-pushable": "^3.2.1", + "it-stream-types": "^2.0.1", + "multiformats": "^12.1.3", + "uint8arraylist": "^2.4.3" + } + }, + "node_modules/datastore-core/node_modules/@libp2p/logger": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@libp2p/logger/-/logger-4.0.2.tgz", + "integrity": "sha512-J9UMtMU9BKXNp+3c5kcI7HyWOPYg2B2E6sn1gEQckiSexTaz0wKJSlgTZ89f9F8bkC3AaC8ybXYuHbFQhwpTIg==", + "dependencies": { + "@libp2p/interface": "^1.0.2", + "@multiformats/multiaddr": "^12.1.10", + "debug": "^4.3.4", + "interface-datastore": "^8.2.0", + "multiformats": "^12.1.3" + } + }, + "node_modules/datastore-core/node_modules/uint8arrays": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-5.0.0.tgz", + "integrity": "sha512-RWO7gR4x6syxnKDfZO8mDCsaaYs1/BqZCxlHgrcRge50E9GTnLmtoA4kwFSGIL4s3dQkryeTkvtG6oEFEya3yg==", + "dependencies": { + "multiformats": "^12.0.1" } }, "node_modules/debug": { @@ -2352,6 +2922,28 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "dependencies": { + "mimic-response": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", + "engines": { + "node": ">=4.0.0" + } + }, "node_modules/deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", @@ -2369,34 +2961,15 @@ "node": ">= 16" } }, - "node_modules/default-gateway/node_modules/execa": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/execa/-/execa-7.2.0.tgz", - "integrity": "sha512-UduyVP7TLB5IcAQl+OzLyLcS/l32W/GLg+AhHJ+ow40FOk2U3SAllPwR44v4vmdFwIWqpdwxxpQbF1n5ta9seA==", - "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.1", - "human-signals": "^4.3.0", - "is-stream": "^3.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^5.1.0", - "onetime": "^6.0.0", - "signal-exit": "^3.0.7", - "strip-final-newline": "^3.0.0" - }, + "node_modules/delay": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/delay/-/delay-6.0.0.tgz", + "integrity": "sha512-2NJozoOHQ4NuZuVIr5CWd0iiLVIRSDepakaovIN+9eIDHEhdCAEvSy2cuf1DCrPPQLvHmbqTHODlhHg8UCy4zw==", "engines": { - "node": "^14.18.0 || ^16.14.0 || >=18.0.0" + "node": ">=16" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" - } - }, - "node_modules/default-gateway/node_modules/human-signals": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-4.3.1.tgz", - "integrity": "sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ==", - "engines": { - "node": ">=14.18.0" + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/denque": { @@ -2412,6 +2985,14 @@ "resolved": "https://registry.npmjs.org/detect-browser/-/detect-browser-5.3.0.tgz", "integrity": "sha512-53rsFbGdwMwlF7qvCt0ypLM5V5/Mbl0szB7GPN8y9NCcbknYOeVVXdrXEq+90IwAfrrzt6Hd+u2E2ntakICU8w==" }, + "node_modules/detect-libc": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz", + "integrity": "sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==", + "engines": { + "node": ">=8" + } + }, "node_modules/diff": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz", @@ -2434,18 +3015,12 @@ } }, "node_modules/dns-over-http-resolver": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/dns-over-http-resolver/-/dns-over-http-resolver-2.1.2.tgz", - "integrity": "sha512-Bjbf6aZjr3HMnwGslZnoW3MJVqgbTsh39EZWpikx2yLl9xEjw4eZhlOHCFhkOu89zoWaS4rqe2Go53TXW4Byiw==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/dns-over-http-resolver/-/dns-over-http-resolver-3.0.0.tgz", + "integrity": "sha512-5+BI+B7n8LKhNaEZBYErr+CBd9t5nYtjunByLhrLGtZ+i3TRgiU8yE87pCjEBu2KOwNsD9ljpSXEbZ4S8xih5g==", "dependencies": { - "debug": "^4.3.1", - "native-fetch": "^4.0.2", - "receptacle": "^1.3.2", - "undici": "^5.12.0" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" + "debug": "^4.3.4", + "receptacle": "^1.3.2" } }, "node_modules/dns-packet": { @@ -2477,6 +3052,14 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, + "node_modules/end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dependencies": { + "once": "^1.4.0" + } + }, "node_modules/err-code": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", @@ -2504,15 +3087,15 @@ } }, "node_modules/eslint": { - "version": "8.53.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.53.0.tgz", - "integrity": "sha512-N4VuiPjXDUa4xVeV/GC/RV3hQW9Nw+Y463lkWaKKXKYMvmRiRDAtfpuPFLN+E1/6ZhyR8J2ig+eVREnYgUsiag==", + "version": "8.55.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.55.0.tgz", + "integrity": "sha512-iyUUAM0PCKj5QpwGfmCAG9XXbZCWsqP/eWAWrG/W0umvjuLRBECwSFdt+rCntju0xEH7teIABPwXpahftIaTdA==", "dev": true, "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", "@eslint-community/regexpp": "^4.6.1", - "@eslint/eslintrc": "^2.1.3", - "@eslint/js": "8.53.0", + "@eslint/eslintrc": "^2.1.4", + "@eslint/js": "8.55.0", "@humanwhocodes/config-array": "^0.11.13", "@humanwhocodes/module-importer": "^1.0.1", "@nodelib/fs.walk": "^1.2.8", @@ -2706,6 +3289,36 @@ "node": ">=0.8.x" } }, + "node_modules/execa": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-7.2.0.tgz", + "integrity": "sha512-UduyVP7TLB5IcAQl+OzLyLcS/l32W/GLg+AhHJ+ow40FOk2U3SAllPwR44v4vmdFwIWqpdwxxpQbF1n5ta9seA==", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.1", + "human-signals": "^4.3.0", + "is-stream": "^3.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^5.1.0", + "onetime": "^6.0.0", + "signal-exit": "^3.0.7", + "strip-final-newline": "^3.0.0" + }, + "engines": { + "node": "^14.18.0 || ^16.14.0 || >=18.0.0" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/expand-template": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", + "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", + "engines": { + "node": ">=6" + } + }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -2783,6 +3396,24 @@ "node": "^12.20 || >= 14.13" } }, + "node_modules/fetch-blob/node_modules/node-domexception": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-1.0.0.tgz", + "integrity": "sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/jimmywarting" + }, + { + "type": "github", + "url": "https://paypal.me/jimmywarting" + } + ], + "engines": { + "node": ">=10.5.0" + } + }, "node_modules/file-entry-cache": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", @@ -2833,17 +3464,17 @@ } }, "node_modules/flat-cache": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.1.0.tgz", - "integrity": "sha512-OHx4Qwrrt0E4jEIcI5/Xb+f+QmJYNj2rrK8wiIdQOIrB9WrrJL8cjZvXdXuBTkkEwEqLycb5BeZDV1o2i9bTew==", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", + "integrity": "sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==", "dev": true, "dependencies": { - "flatted": "^3.2.7", + "flatted": "^3.2.9", "keyv": "^4.5.3", "rimraf": "^3.0.2" }, "engines": { - "node": ">=12.0.0" + "node": "^10.12.0 || >=12.0.0" } }, "node_modules/flatted": { @@ -2872,6 +3503,11 @@ "npm": ">=7.0.0" } }, + "node_modules/fs-constants": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", + "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==" + }, "node_modules/fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", @@ -2879,9 +3515,9 @@ "dev": true }, "node_modules/fsevents": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", - "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, "hasInstallScript": true, "optional": true, @@ -2917,6 +3553,11 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/github-from-package": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", + "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==" + }, "node_modules/glob": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", @@ -2950,9 +3591,9 @@ } }, "node_modules/globals": { - "version": "13.23.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.23.0.tgz", - "integrity": "sha512-XAmF0RjlrjY23MA51q3HltdlGxUpXPvg0GioKiD9X6HD28iMjo2dKC8Vqwm7lne4GNr78+RHTfliktR6ZH09wA==", + "version": "13.24.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", + "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", "dev": true, "dependencies": { "type-fest": "^0.20.2" @@ -3004,13 +3645,13 @@ } }, "node_modules/handlebars": { - "version": "4.7.7", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.7.tgz", - "integrity": "sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==", + "version": "4.7.8", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.8.tgz", + "integrity": "sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==", "dev": true, "dependencies": { "minimist": "^1.2.5", - "neo-async": "^2.6.0", + "neo-async": "^2.6.2", "source-map": "^0.6.1", "wordwrap": "^1.0.0" }, @@ -3048,20 +3689,20 @@ } }, "node_modules/helia": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/helia/-/helia-2.0.3.tgz", - "integrity": "sha512-8Uze/U48R9p3013+oh5Eg29RwkzRXpCHDYyKxf7yU1S5GGnVguaWrmEHYJ2pKMMYMCgNasmCvfouurKIQvM+cg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/helia/-/helia-2.1.0.tgz", + "integrity": "sha512-OJOm99WYZC7o3hGRhv2rbWK6nDw2cRWx2+g6uMDF5YL04yZ2vZcE/8xccM3ekhrZFSJhbUGPID4AKGULIaxHbg==", "dependencies": { "@chainsafe/libp2p-gossipsub": "^10.0.0", "@chainsafe/libp2p-noise": "^13.0.0", "@chainsafe/libp2p-yamux": "^5.0.0", - "@helia/interface": "^2.0.0", + "@helia/delegated-routing-v1-http-api-client": "^1.1.0", + "@helia/interface": "^2.1.0", "@ipld/dag-cbor": "^9.0.0", "@ipld/dag-json": "^10.0.1", "@ipld/dag-pb": "^4.0.3", "@libp2p/bootstrap": "^9.0.2", "@libp2p/interface": "^0.1.1", - "@libp2p/ipni-content-routing": "^2.0.0", "@libp2p/kad-dht": "^10.0.2", "@libp2p/logger": "^3.0.1", "@libp2p/mdns": "^9.0.2", @@ -3070,6 +3711,7 @@ "@libp2p/webrtc": "^3.1.3", "@libp2p/websockets": "^7.0.2", "@libp2p/webtransport": "^3.0.3", + "any-signal": "^4.1.1", "blockstore-core": "^4.0.0", "cborg": "^4.0.1", "datastore-core": "^9.0.0", @@ -3091,12 +3733,12 @@ "uint8arrays": "^4.0.3" } }, - "node_modules/helia/node_modules/cborg": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/cborg/-/cborg-4.0.3.tgz", - "integrity": "sha512-poLvpK30KT5KI8gzDx3J/IuVCbsLqMT2fEbOrOuX0H7Hyj8yg5LezeWhRh9aLa5Z6MfPC5sriW3HVJF328M8LQ==", - "bin": { - "cborg": "lib/bin.js" + "node_modules/human-signals": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-4.3.1.tgz", + "integrity": "sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ==", + "engines": { + "node": ">=14.18.0" } }, "node_modules/ieee754": { @@ -3119,9 +3761,9 @@ ] }, "node_modules/ignore": { - "version": "5.2.4", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz", - "integrity": "sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.0.tgz", + "integrity": "sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg==", "dev": true, "engines": { "node": ">= 4" @@ -3167,38 +3809,42 @@ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, + "node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==" + }, "node_modules/interface-blockstore": { - "version": "5.2.6", - "resolved": "https://registry.npmjs.org/interface-blockstore/-/interface-blockstore-5.2.6.tgz", - "integrity": "sha512-Cp6+QPY81kunaxQV/j5BWk3uSW6kpos8dLveJ3P2lbmA/yX2XeMwVlNOnQyGg0evhp1qmMLhf6eCswNiSMW3CA==", + "version": "5.2.7", + "resolved": "https://registry.npmjs.org/interface-blockstore/-/interface-blockstore-5.2.7.tgz", + "integrity": "sha512-B9UplmgUdQg15f/6xDJEbQYcjMm568cnqJsxSZYbDD0s6eQX5gKh58sd9H3aJEMosIy8T4vz9MwWWZuAOc3hQQ==", "dependencies": { "interface-store": "^5.0.0", "multiformats": "^12.0.1" } }, "node_modules/interface-datastore": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/interface-datastore/-/interface-datastore-8.2.0.tgz", - "integrity": "sha512-rDMAcpCGxWMubRk2YQuSEHl11bc0xcZeBZzfLvqhoZJdByUWeo7YDJUdgyRKgD6liGXVYirtDkFU9nyn9xl2hg==", + "version": "8.2.9", + "resolved": "https://registry.npmjs.org/interface-datastore/-/interface-datastore-8.2.9.tgz", + "integrity": "sha512-J/8PN8TnB5xxCRtgu9Vx3zExdOzcTU5/DBF2dlU41deX1GW6/SPpbJo5DRNSnvzfjmwJ7YhUOIFXyccUp8nuAA==", "dependencies": { "interface-store": "^5.0.0", - "nanoid": "^4.0.0", - "uint8arrays": "^4.0.2" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" + "uint8arrays": "^5.0.0" } }, - "node_modules/interface-store": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/interface-store/-/interface-store-5.1.0.tgz", - "integrity": "sha512-mjUwX3XSoreoxCS3sXS3pSRsGnUjl9T06KBqt/T7AgE9Sgp4diH64ZyURJKnj2T5WmCvTbC0Dm+mwQV5hfLSBQ==", - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" + "node_modules/interface-datastore/node_modules/uint8arrays": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-5.0.0.tgz", + "integrity": "sha512-RWO7gR4x6syxnKDfZO8mDCsaaYs1/BqZCxlHgrcRge50E9GTnLmtoA4kwFSGIL4s3dQkryeTkvtG6oEFEya3yg==", + "dependencies": { + "multiformats": "^12.0.1" } }, + "node_modules/interface-store": { + "version": "5.1.5", + "resolved": "https://registry.npmjs.org/interface-store/-/interface-store-5.1.5.tgz", + "integrity": "sha512-X0KnJBk3o+YL13MxZBMwa88/b3Mdrpm0yPzkSTKDDVn9BSPH7UK6W+ZtIPO2bxKOQVmq7zqOwAnYnpfqWjb6/g==" + }, "node_modules/ip-regex": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/ip-regex/-/ip-regex-5.0.0.tgz", @@ -3219,9 +3865,9 @@ } }, "node_modules/ipfs-bitswap": { - "version": "19.0.0", - "resolved": "https://registry.npmjs.org/ipfs-bitswap/-/ipfs-bitswap-19.0.0.tgz", - "integrity": "sha512-X0u7Y9dnRlP57EGNOF+RUtm2UkB3Nrx/NLLeUZ/VEEMWBC5iOFpBDvTxSNdEK366khbG8mXk2NJ1ko8jcKXETw==", + "version": "19.0.2", + "resolved": "https://registry.npmjs.org/ipfs-bitswap/-/ipfs-bitswap-19.0.2.tgz", + "integrity": "sha512-pm0EcnTAwMMkCmdXHw/a7uPXzQ4I/pxVFiQZ6Ebg/R64XxAky/bCOJRzmqsgqH0+prH2bXAOgzS0mOZdL+zFSw==", "dependencies": { "@libp2p/interface": "^0.1.1", "@libp2p/logger": "^3.0.1", @@ -3336,14 +3982,6 @@ "uint8arrays": "^4.0.2" } }, - "node_modules/ipns/node_modules/cborg": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/cborg/-/cborg-4.0.3.tgz", - "integrity": "sha512-poLvpK30KT5KI8gzDx3J/IuVCbsLqMT2fEbOrOuX0H7Hyj8yg5LezeWhRh9aLa5Z6MfPC5sriW3HVJF328M8LQ==", - "bin": { - "cborg": "lib/bin.js" - } - }, "node_modules/is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", @@ -3396,6 +4034,17 @@ "resolved": "https://registry.npmjs.org/is-loopback-addr/-/is-loopback-addr-2.0.2.tgz", "integrity": "sha512-26POf2KRCno/KTNL5Q0b/9TYnL00xEsSaLfiFRmjM7m7Lw7ZMmFybzzuX4CcsLAluZGd+niLUiMRxEooVE3aqg==" }, + "node_modules/is-network-error": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-network-error/-/is-network-error-1.0.0.tgz", + "integrity": "sha512-P3fxi10Aji2FZmHTrMPSNFbNC6nnp4U5juPAIjXPHkUNubi4+qK7vvdsaNpAUwXslhYm9oyjEYTxs1xd/+Ph0w==", + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -3456,83 +4105,66 @@ "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" }, - "node_modules/iso-url": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/iso-url/-/iso-url-1.2.1.tgz", - "integrity": "sha512-9JPDgCN4B7QPkLtYAAOrEuAWvP9rWvR5offAr0/SeF046wIkglqH3VXgYYP6NcsKslH80UIVgmPqNe3j7tG2ng==", - "engines": { - "node": ">=12" - } - }, "node_modules/it-all": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-all/-/it-all-3.0.3.tgz", - "integrity": "sha512-LwEVD1d0b1O5mDwumnZk+80jSBn5sXDxQ41xiD6j6l2lRiWH6lBLdxXx1C6mlKrXQwRHzUQagOZUmqttDUwb0A==" + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-all/-/it-all-3.0.4.tgz", + "integrity": "sha512-UMiy0i9DqCHBdWvMbzdYvVGa5/w4t1cc4nchpbnjdLhklglv8mQeEYnii0gvKESJuL1zV32Cqdb33R6/GPfxpQ==" }, "node_modules/it-batch": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-batch/-/it-batch-3.0.3.tgz", - "integrity": "sha512-KdKVGOZgYhxiHTMphzPKaiNL99yyUgeDoqRmSedbKJr05nP5RxtiIPWX+i1dLCADRjExbGtKfFsrogNgH0h9SA==" + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-batch/-/it-batch-3.0.4.tgz", + "integrity": "sha512-WRu2mqOYIs+T9k7+yxSK9VJdk0UE4R0jKQsWQcti5c6vhb1FhjC2+yCB5XBrctQ9edNfCMU/wVzdDj8qSwimbA==" }, "node_modules/it-batched-bytes": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/it-batched-bytes/-/it-batched-bytes-2.0.4.tgz", - "integrity": "sha512-n4V19XACvFG+b8lCkuvidYvwpyz3++DAolqZGI+9AcDvIPMAhVwwtFCe9SiDIz45OzQnnNYwBgBxbIinHPgraA==", + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/it-batched-bytes/-/it-batched-bytes-2.0.5.tgz", + "integrity": "sha512-2VgeZ+7KPef0SD2ZgkZfWFe+sgZKdxkzNZXbsYG44nGe4NzWSZLJ6lUjkKHW/S5pSKyW88uacosz6B6K++1LDA==", "dependencies": { "p-defer": "^4.0.0", "uint8arraylist": "^2.4.1" } }, "node_modules/it-byte-stream": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/it-byte-stream/-/it-byte-stream-1.0.1.tgz", - "integrity": "sha512-Nu1/y8ObmrEmpHfWBHrWKtla9xwTdnMceB7v1z7tM+H84VP5Ou59wyFiJHsyvuIETLfKFY+TfhEbOJy24FRGjQ==", + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/it-byte-stream/-/it-byte-stream-1.0.7.tgz", + "integrity": "sha512-oWO+TitZNn1a7+Yl0SM4UAyuylhJ3MmnnewVWO5shl0Bs1KQPMWuMB/6d0X0H1ygBlYCLAxF9EJqa19pWCnVRQ==", "dependencies": { - "it-pushable": "^3.2.0", "it-stream-types": "^2.0.1", + "p-defer": "^4.0.0", + "race-signal": "^1.0.1", "uint8arraylist": "^2.4.1" } }, "node_modules/it-drain": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-drain/-/it-drain-3.0.3.tgz", - "integrity": "sha512-l4s+izxUpFAR2axprpFiCaq0EtxK1QMd0LWbEtau5b+OegiZ5xdRtz35iJyh6KZY9QtuwEiQxydiOfYJc7stoA==" + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/it-drain/-/it-drain-3.0.5.tgz", + "integrity": "sha512-qYFe4SWdvs9oJGUY5bSjvmiLUMLzFEODNOQUdYdCIkuIgQF+AUB2INhM4yQ09buJ2rhHKDFxvTD/+yUq6qg0XA==" }, "node_modules/it-filter": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-filter/-/it-filter-3.0.3.tgz", - "integrity": "sha512-2zXUrJuuV6QHM21ahc8NqVUUxkLMVDWXBoUBcj9GCQLQez2OXmddTHN0r0F5B+TkNTpeL618yIgXi1HNPJOxow==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-filter/-/it-filter-3.0.4.tgz", + "integrity": "sha512-e0sz+st4sudK/zH6GZ/gRTRP8A/ADuJFCYDmRgMbZvR79y5+v4ZXav850bBZk5wL9zXaYZFxS1v/6Qi+Vjwh5g==", "dependencies": { "it-peekable": "^3.0.0" } }, - "node_modules/it-filter/node_modules/it-peekable": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/it-peekable/-/it-peekable-3.0.2.tgz", - "integrity": "sha512-nWwUdhNQ1CfAuoJmsaUotNMYUrfNIlY9gBA1jwWfWSu1I0mLY2brwreKHGOUptXLJUiG5pR04He0xYZMWBRiGA==" - }, "node_modules/it-first": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-first/-/it-first-3.0.3.tgz", - "integrity": "sha512-RC8tplctsDpoBUljwsp1viiyaR5fPvMe+FgbbcU0sFjKkJa7iwbB4CCPhHtVYSdjsrREfr0QEotfQrBoGyt7Dw==" + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-first/-/it-first-3.0.4.tgz", + "integrity": "sha512-FtQl84iTNxN5EItP/JgL28V2rzNMkCzTUlNoj41eVdfix2z1DBuLnBqZ0hzYhGGa1rMpbQf0M7CQSA2adlrLJg==" }, "node_modules/it-foreach": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/it-foreach/-/it-foreach-2.0.4.tgz", - "integrity": "sha512-txxcoc09g+KdLyOapxAuB12H9zUb2FuZC/TqSXRT+YR0T5fHnvcDIhspgvx/e/HiPKlKjOR8onA0qtuiAtcXqg==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/it-foreach/-/it-foreach-2.0.6.tgz", + "integrity": "sha512-OVosBHJsdXpAyeFlCbe3IGZia+65UykyAznakNsKXK+b99dbhuu/mOnXxTadDEo1GWhKx+WA8RNanKkMf07zQw==", "dependencies": { "it-peekable": "^3.0.0" } }, - "node_modules/it-foreach/node_modules/it-peekable": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/it-peekable/-/it-peekable-3.0.2.tgz", - "integrity": "sha512-nWwUdhNQ1CfAuoJmsaUotNMYUrfNIlY9gBA1jwWfWSu1I0mLY2brwreKHGOUptXLJUiG5pR04He0xYZMWBRiGA==" - }, "node_modules/it-glob": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/it-glob/-/it-glob-2.0.5.tgz", - "integrity": "sha512-LMigc3F1ODHf8oNY05AcSsU2McT4ecqkmoDcJ93SEEZ3KgmFHzVwsszbyj8j1EFmXreR9gwWH6r53dUnGXboIA==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/it-glob/-/it-glob-2.0.6.tgz", + "integrity": "sha512-4C6ccz4nhqrq7yZMzBr3MsKhyL+rlnLXIPceyGG6ogl3Lx3eeWMv1RtlySJwFi6q+jVcPyTpeYt/xftwI2JEQQ==", "dependencies": { "minimatch": "^9.0.0" } @@ -3576,14 +4208,14 @@ } }, "node_modules/it-last": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-last/-/it-last-3.0.3.tgz", - "integrity": "sha512-veF0zWTMEJ466Otxz7jPbExiJGfJYTOiHYGfg8iGwKPIV558zIGZQJU1WNyjHfugFzAyfuFlIZKsXCCtCl8LgQ==" + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-last/-/it-last-3.0.4.tgz", + "integrity": "sha512-Ns+KTsQWhs0KCvfv5X3Ck3lpoYxHcp4zUp4d+AOdmC8cXXqDuoZqAjfWhgCbxJubXyIYWdfE2nRcfWqgvZHP8Q==" }, "node_modules/it-length": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-length/-/it-length-3.0.3.tgz", - "integrity": "sha512-aLoeonDJV6wMgT1ElEruc61c3FYxGa3yymujfZ0Uk4Up7mUJ15xl1ixxPnGbm+BnMkEQylJXjzp1vNYEY9blvg==" + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-length/-/it-length-3.0.4.tgz", + "integrity": "sha512-RS3thYkvqtWksrV7SaAnTv+pgY7ozpS17HlRvWvcnoRjVyNJMuffdCkIKpKNPTq5uZw9zVnkVKLO077pJn5Yhg==" }, "node_modules/it-length-prefixed": { "version": "9.0.3", @@ -3603,9 +4235,9 @@ } }, "node_modules/it-length-prefixed-stream": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/it-length-prefixed-stream/-/it-length-prefixed-stream-1.0.2.tgz", - "integrity": "sha512-gWevodoctgwWUaRJN9t+xEs1H1GQNYAjLCR7FO50fon9Ph4OJGgrxPKTc26QXKrC/cIQZLkHYClphUw0wl1k2A==", + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/it-length-prefixed-stream/-/it-length-prefixed-stream-1.1.5.tgz", + "integrity": "sha512-r/txldLo3Dq4EqLJY2mSK6y59qY7peRyomdjyhCmBlQYr7fPmiS1UA5A8mLwQV3k+WPD5zK0cu/7EpvzD4T+ew==", "dependencies": { "it-byte-stream": "^1.0.0", "it-length-prefixed": "^9.0.1", @@ -3615,26 +4247,26 @@ } }, "node_modules/it-map": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/it-map/-/it-map-3.0.4.tgz", - "integrity": "sha512-h5zCxovJQ+mzJT75xP4GkJuFrJQ5l7IIdhZ6AOWaE02g5F7T1k1j4CB/uKSRR05LLLOi1LqG+7CrH9bi8GIXYA==", + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/it-map/-/it-map-3.0.5.tgz", + "integrity": "sha512-hB0TDXo/h4KSJJDSRLgAPmDroiXP6Fx1ck4Bzl3US9hHfZweTKsuiP0y4gXuTMcJlS6vj0bb+f70rhkD47ZA3w==", "dependencies": { "it-peekable": "^3.0.0" } }, - "node_modules/it-map/node_modules/it-peekable": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/it-peekable/-/it-peekable-3.0.2.tgz", - "integrity": "sha512-nWwUdhNQ1CfAuoJmsaUotNMYUrfNIlY9gBA1jwWfWSu1I0mLY2brwreKHGOUptXLJUiG5pR04He0xYZMWBRiGA==" - }, "node_modules/it-merge": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/it-merge/-/it-merge-3.0.2.tgz", - "integrity": "sha512-bMk2km8lTz+Rwv30hzDUdGIcqQkOemFJqmGT2wqQZ6/zHKCsYqdRunPrteCqHLV/nIVhUK8nZZkDA2eJ4MJZiA==", + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/it-merge/-/it-merge-3.0.3.tgz", + "integrity": "sha512-FYVU15KC5pb/GQX1Ims+lee8d4pdqGVCpWr0lkNj8o4xuNo7jY71k6GuEiWdP+T7W1bJqewSxX5yoTy5yZpRVA==", "dependencies": { "it-pushable": "^3.2.0" } }, + "node_modules/it-ndjson": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/it-ndjson/-/it-ndjson-1.0.5.tgz", + "integrity": "sha512-2UEROCo458dDu9dABKb9fvD34p2YL6SqV5EOXN8SysX2Fpx0MSN69EiBmLLDDYSpQlrW0I5j3Tm8DtEIL5NsIw==" + }, "node_modules/it-pair": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/it-pair/-/it-pair-2.0.6.tgz", @@ -3649,21 +4281,26 @@ } }, "node_modules/it-parallel": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/it-parallel/-/it-parallel-3.0.4.tgz", - "integrity": "sha512-fuA+SysGxbZc+Yl7EUvzQqZ8bNYQghZ0Mq9zA+fxMQ5eQYzatNg6oJk1y1PvPvNqLgKJMzEInpRO6PbLC3hGAg==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/it-parallel/-/it-parallel-3.0.6.tgz", + "integrity": "sha512-i7UM7I9LTkDJw3YIqXHFAPZX6CWYzGc+X3irdNrVExI4vPazrJdI7t5OqrSVN8CONXLAunCiqaSV/zZRbQR56A==", "dependencies": { "p-defer": "^4.0.0" } }, "node_modules/it-parallel-batch": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/it-parallel-batch/-/it-parallel-batch-3.0.2.tgz", - "integrity": "sha512-8ci62F5gn5aS8/wEC0kvRKWCmenHlIi+R8waEF/SP1ImQhhkve9l4/DXEmoL7UeI5FqJktzkMzZwqDng0ZppKw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-parallel-batch/-/it-parallel-batch-3.0.4.tgz", + "integrity": "sha512-O1omh8ss8+UtXiMjE+8kM5C20DT0Ma4VtKVfrSHOJU0UHZ+iWBXarabzPYEp+WiuQmrv+klDPPlTZ9KaLN9xOA==", "dependencies": { "it-batch": "^3.0.0" } }, + "node_modules/it-peekable": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/it-peekable/-/it-peekable-3.0.3.tgz", + "integrity": "sha512-Wx21JX/rMzTEl9flx3DGHuPV1KQFGOl8uoKfQtmZHgPQtGb89eQ6RyVd82h3HuP9Ghpt0WgBDlmmdWeHXqyx7w==" + }, "node_modules/it-pipe": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/it-pipe/-/it-pipe-3.0.1.tgz", @@ -3679,9 +4316,9 @@ } }, "node_modules/it-protobuf-stream": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/it-protobuf-stream/-/it-protobuf-stream-1.0.2.tgz", - "integrity": "sha512-2lESJIeZS2ZlYJc/1SKs6LL4Y83rCCvZv750xV1e4uuP9114yNkw2MhIGCtSReg+qNWCvzGqOwjQbKV0LFE6wQ==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/it-protobuf-stream/-/it-protobuf-stream-1.1.2.tgz", + "integrity": "sha512-epZBuG+7cPaTxCR/Lf3ApshBdA9qfflGPQLfLLrp9VQ0w67Z2xo4H+SLLetav57/29oPtAXwVaoyemg99JOWzA==", "dependencies": { "it-length-prefixed-stream": "^1.0.0", "it-stream-types": "^2.0.1", @@ -3690,15 +4327,11 @@ } }, "node_modules/it-pushable": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/it-pushable/-/it-pushable-3.2.1.tgz", - "integrity": "sha512-sLFz2Q0oyDCJpTciZog7ipP4vSftfPy3e6JnH6YyztRa1XqkpGQaafK3Jw/JlfEBtCXfnX9uVfcpu3xpSAqCVQ==", + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/it-pushable/-/it-pushable-3.2.3.tgz", + "integrity": "sha512-gzYnXYK8Y5t5b/BnJUr7glfQLO4U5vyb05gPx/TyTw+4Bv1zM9gFk4YsOrnulWefMewlphCjKkakFvj1y99Tcg==", "dependencies": { "p-defer": "^4.0.0" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" } }, "node_modules/it-reader": { @@ -3715,9 +4348,9 @@ } }, "node_modules/it-sort": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-sort/-/it-sort-3.0.3.tgz", - "integrity": "sha512-9BuQc5Y2fmBUNhevQBUDHfItrQmzWoZcnzydJl91V6na6M+RkbNj71UtCPPNIpOt/SQG+va0pe1wMQJ9lP2Oew==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-sort/-/it-sort-3.0.4.tgz", + "integrity": "sha512-tvnC93JZZWjX4UxALy0asow0dzXabkoaRbrPJKClTKhNCqw4gzHr+H5axf1gohcthedRRkqd/ae+wl7WqoxFhw==", "dependencies": { "it-all": "^3.0.0" } @@ -3732,28 +4365,35 @@ } }, "node_modules/it-take": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/it-take/-/it-take-3.0.3.tgz", - "integrity": "sha512-Ay5SXEyrBKD0tO8PQif2QjrStImIsLIg0F50Uu4EeXOw8C9DfVIGfsGL3X9s65F2I9skDp9mLgBzl71IToMxNw==" + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/it-take/-/it-take-3.0.4.tgz", + "integrity": "sha512-RG8HDjAZlvkzz5Nav4xq6gK5zNT+Ff1UTIf+CrSJW8nIl6N1FpBH5e7clUshiCn+MmmMoSdIEpw4UaTolszxhA==" }, "node_modules/it-to-buffer": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/it-to-buffer/-/it-to-buffer-4.0.3.tgz", - "integrity": "sha512-/xdI2hD/LvK7tzS/9DY9oKATmUZ9rg9uG7IfQRBAokM/LLujJ179fqRGneluqwKpXOtCpMRo43LJZXr8aibv6Q==", + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/it-to-buffer/-/it-to-buffer-4.0.5.tgz", + "integrity": "sha512-DoQWOBhYmVHa0ooMauJLVbZ8V8K3AsFgqBs7I+kX7f3KbFMEy0MA9w7TJo9Utd4T4H+iUScyLFwo7REA4dWreA==", "dependencies": { - "uint8arrays": "^4.0.2" + "uint8arrays": "^5.0.0" + } + }, + "node_modules/it-to-buffer/node_modules/uint8arrays": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-5.0.0.tgz", + "integrity": "sha512-RWO7gR4x6syxnKDfZO8mDCsaaYs1/BqZCxlHgrcRge50E9GTnLmtoA4kwFSGIL4s3dQkryeTkvtG6oEFEya3yg==", + "dependencies": { + "multiformats": "^12.0.1" } }, "node_modules/it-ws": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/it-ws/-/it-ws-6.0.5.tgz", - "integrity": "sha512-xp7tF4fHgx8+vN3Qy/8wGiWUKbC9E1U1g9PwtlbdxD7pY4zld71ZyWZVFHLxnxxg14T9mVNK5uO7U9HK11VQ5g==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/it-ws/-/it-ws-6.1.1.tgz", + "integrity": "sha512-oyk4eCeZto2lzWDnJOa3j1S2M+VOGKUh8isEf94ySoaL6IFlyie0T4P9E0ZUaIvX8LyJxYFHFKCt8Zk7Sm/XPQ==", "dependencies": { "@types/ws": "^8.2.2", "event-iterator": "^2.0.0", - "iso-url": "^1.1.2", "it-stream-types": "^2.0.1", - "uint8arrays": "^4.0.2", + "uint8arrays": "^5.0.0", "ws": "^8.4.0" }, "engines": { @@ -3761,12 +4401,12 @@ "npm": ">=7.0.0" } }, - "node_modules/iterable-ndjson": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/iterable-ndjson/-/iterable-ndjson-1.1.0.tgz", - "integrity": "sha512-OOp1Lb0o3k5MkXHx1YaIY5Z0ELosZfTnBaas9f8opJVcZGBIONA2zY/6CYE+LKkqrSDooIneZbrBGgOZnHPkrg==", + "node_modules/it-ws/node_modules/uint8arrays": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-5.0.0.tgz", + "integrity": "sha512-RWO7gR4x6syxnKDfZO8mDCsaaYs1/BqZCxlHgrcRge50E9GTnLmtoA4kwFSGIL4s3dQkryeTkvtG6oEFEya3yg==", "dependencies": { - "string_decoder": "^1.2.0" + "multiformats": "^12.0.1" } }, "node_modules/js-yaml": { @@ -3816,9 +4456,9 @@ "dev": true }, "node_modules/keyv": { - "version": "4.5.3", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.3.tgz", - "integrity": "sha512-QCiSav9WaX1PgETJ+SpNnx2PRRapJ/oRSXM4VO5OGYGSjrxbKPVFVhB3l2OCbLCk329N8qyAtsJjSjvVBWzEug==", + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", + "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", "dev": true, "dependencies": { "json-buffer": "3.0.1" @@ -3838,23 +4478,23 @@ } }, "node_modules/libp2p": { - "version": "0.46.11", - "resolved": "https://registry.npmjs.org/libp2p/-/libp2p-0.46.11.tgz", - "integrity": "sha512-8SHmYA3etA3EGMQ81URhs7z14U8TOT16zmGjivNa25Vj/UpV8O3yNE4gpk5Ybt37zMzHzI8IxVdai6Sn+jXYvw==", + "version": "0.46.21", + "resolved": "https://registry.npmjs.org/libp2p/-/libp2p-0.46.21.tgz", + "integrity": "sha512-p/3vCpw+ciizhlBofpzuez+4Fs8EeVFaVQZUQPwnQwycuOFcWLBhcqkOtv4KlqImFKOk+9TuyW1Xofjmr/wPnA==", "dependencies": { "@achingbrain/nat-port-mapper": "^1.0.9", - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/interface-internal": "^0.1.5", - "@libp2p/keychain": "^3.0.4", - "@libp2p/logger": "^3.0.2", - "@libp2p/multistream-select": "^4.0.2", - "@libp2p/peer-collections": "^4.0.4", - "@libp2p/peer-id": "^3.0.2", - "@libp2p/peer-id-factory": "^3.0.4", - "@libp2p/peer-record": "^6.0.5", - "@libp2p/peer-store": "^9.0.5", - "@libp2p/utils": "^4.0.3", + "@libp2p/crypto": "^2.0.8", + "@libp2p/interface": "^0.1.6", + "@libp2p/interface-internal": "^0.1.9", + "@libp2p/keychain": "^3.0.8", + "@libp2p/logger": "^3.1.0", + "@libp2p/multistream-select": "^4.0.6", + "@libp2p/peer-collections": "^4.0.8", + "@libp2p/peer-id": "^3.0.6", + "@libp2p/peer-id-factory": "^3.0.8", + "@libp2p/peer-record": "^6.0.9", + "@libp2p/peer-store": "^9.0.9", + "@libp2p/utils": "^4.0.7", "@multiformats/mafmt": "^12.1.2", "@multiformats/multiaddr": "^12.1.5", "@multiformats/multiaddr-matcher": "^1.0.0", @@ -3889,31 +4529,6 @@ "xsalsa20": "^1.1.0" } }, - "node_modules/libp2p/node_modules/@libp2p/peer-id-factory": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@libp2p/peer-id-factory/-/peer-id-factory-3.0.4.tgz", - "integrity": "sha512-9xpKb1UdAhKVmPHy/jssOnyJkuyyyIeP5tO3HlaiBQNtDZU66UMQORnEUD6HdYHKfBRInah2JHxTCtm2nUhGcw==", - "dependencies": { - "@libp2p/crypto": "^2.0.4", - "@libp2p/interface": "^0.1.2", - "@libp2p/peer-id": "^3.0.2", - "multiformats": "^12.0.1", - "protons-runtime": "^5.0.0", - "uint8arraylist": "^2.4.3", - "uint8arrays": "^4.0.6" - } - }, - "node_modules/libp2p/node_modules/delay": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/delay/-/delay-6.0.0.tgz", - "integrity": "sha512-2NJozoOHQ4NuZuVIr5CWd0iiLVIRSDepakaovIN+9eIDHEhdCAEvSy2cuf1DCrPPQLvHmbqTHODlhHg8UCy4zw==", - "engines": { - "node": ">=16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/locate-path": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", @@ -3971,7 +4586,6 @@ "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dev": true, "dependencies": { "yallist": "^4.0.0" }, @@ -4034,6 +4648,17 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/minimatch": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", @@ -4054,6 +4679,11 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/mkdirp-classic": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", + "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==" + }, "node_modules/mocha": { "version": "10.2.0", "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz", @@ -4132,18 +4762,6 @@ "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", "dev": true }, - "node_modules/mocha/node_modules/nanoid": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", - "integrity": "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==", - "dev": true, - "bin": { - "nanoid": "bin/nanoid.cjs" - }, - "engines": { - "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" - } - }, "node_modules/mocha/node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -4184,26 +4802,21 @@ } }, "node_modules/mock-socket": { - "version": "9.2.1", - "resolved": "https://registry.npmjs.org/mock-socket/-/mock-socket-9.2.1.tgz", - "integrity": "sha512-aw9F9T9G2zpGipLLhSNh6ZpgUyUl4frcVmRN08uE1NWPWg43Wx6+sGPDbQ7E5iFZZDJW5b5bypMeAEHqTbIFag==", + "version": "9.3.1", + "resolved": "https://registry.npmjs.org/mock-socket/-/mock-socket-9.3.1.tgz", + "integrity": "sha512-qxBgB7Qa2sEQgHFjj0dSigq7fX4k6Saisd5Nelwp2q8mlbAFh5dHV9JTTlF8viYJLSSWgMCZFUom8PJcMNBoJw==", "engines": { "node": ">= 8" } }, "node_modules/mortice": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/mortice/-/mortice-3.0.1.tgz", - "integrity": "sha512-eyDUsl1nCR9+JtNksKnaESLP9MgAXCA4w1LTtsmOSQNsThnv++f36rrBu5fC/fdGIwTJZmbiaR/QewptH93pYA==", + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/mortice/-/mortice-3.0.3.tgz", + "integrity": "sha512-C1maDct5qTPH6dDXEzZg9XP+RteVHsdQ3IRdOF2Halll5qsCKYVwNL1x9FHGs3xOFvB6xerqxY9AG+Ac6aLr6A==", "dependencies": { - "nanoid": "^4.0.0", "observable-webworkers": "^2.0.1", "p-queue": "^7.2.0", "p-timeout": "^6.0.0" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" } }, "node_modules/ms": { @@ -4237,9 +4850,9 @@ } }, "node_modules/multiformats": { - "version": "12.1.1", - "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-12.1.1.tgz", - "integrity": "sha512-GBSToTmri2vJYs8wqcZQ8kB21dCaeTOzHTIAlr8J06C1eL6UbzqURXFZ5Fl0EYm9GAFz1IlYY8SxGOs9G9NJRg==", + "version": "12.1.3", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-12.1.3.tgz", + "integrity": "sha512-eajQ/ZH7qXZQR2AgtfpmSMizQzmyYVmCql7pdhldPuYQi4atACekbJaQplk6dWyIi10jCaFnd6pqvcEFXjbaJw==", "engines": { "node": ">=16.0.0", "npm": ">=7.0.0" @@ -4286,29 +4899,21 @@ } }, "node_modules/nanoid": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-4.0.2.tgz", - "integrity": "sha512-7ZtY5KTCNheRGfEFxnedV5zFiORN1+Y1N6zvPTnHQd8ENUvfaDBeuJDZb2bN/oXwXxu3qkTXDzy57W5vAmDTBw==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", + "integrity": "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==", + "dev": true, "bin": { - "nanoid": "bin/nanoid.js" + "nanoid": "bin/nanoid.cjs" }, "engines": { - "node": "^14 || ^16 || >=18" + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" } }, - "node_modules/native-fetch": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/native-fetch/-/native-fetch-4.0.2.tgz", - "integrity": "sha512-4QcVlKFtv2EYVS5MBgsGX5+NWKtbDbIECdUXDBGDMAZXq3Jkv9zf+y8iS7Ub8fEdga3GpYeazp9gauNqXHJOCg==", - "peerDependencies": { - "undici": "*" - } + "node_modules/napi-build-utils": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-1.0.2.tgz", + "integrity": "sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==" }, "node_modules/natural-compare": { "version": "1.4.0", @@ -4331,9 +4936,9 @@ } }, "node_modules/nise": { - "version": "5.1.4", - "resolved": "https://registry.npmjs.org/nise/-/nise-5.1.4.tgz", - "integrity": "sha512-8+Ib8rRJ4L0o3kfmyVCL7gzrohyDe0cMFTBa2d364yIrEGMEoetznKJx899YxjybU6bL9SQkYPSBBs1gyYs8Xg==", + "version": "5.1.5", + "resolved": "https://registry.npmjs.org/nise/-/nise-5.1.5.tgz", + "integrity": "sha512-VJuPIfUFaXNRzETTQEEItTOP8Y171ijr+JLq42wHes3DiryR8vT+1TXQW/Rx8JNUhyYYWyIvjXTU6dOhJcs9Nw==", "dev": true, "dependencies": { "@sinonjs/commons": "^2.0.0", @@ -4343,267 +4948,32 @@ "path-to-regexp": "^1.7.0" } }, + "node_modules/nise/node_modules/@sinonjs/commons": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-2.0.0.tgz", + "integrity": "sha512-uLa0j859mMrg2slwQYdO/AkrOfmH+X6LTVmNTS9CqexuE2IvVORIkSpJLqePAbEnKJ77aMmCwr1NUZ57120Xcg==", + "dev": true, + "dependencies": { + "type-detect": "4.0.8" + } + }, "node_modules/nock": { - "version": "13.3.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-13.3.1.tgz", - "integrity": "sha512-vHnopocZuI93p2ccivFyGuUfzjq2fxNyNurp7816mlT5V5HF4SzXu8lvLrVzBbNqzs+ODooZ6OksuSUNM7Njkw==", + "version": "13.4.0", + "resolved": "https://registry.npmjs.org/nock/-/nock-13.4.0.tgz", + "integrity": "sha512-W8NVHjO/LCTNA64yxAPHV/K47LpGYcVzgKd3Q0n6owhwvD0Dgoterc25R4rnZbckJEb6Loxz1f5QMuJpJnbSyQ==", "dependencies": { "debug": "^4.1.0", "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.21", "propagate": "^2.0.0" }, "engines": { "node": ">= 10.13" } }, - "node_modules/node-datachannel": { - "version": "0.4.3", - "resolved": "https://registry.npmjs.org/node-datachannel/-/node-datachannel-0.4.3.tgz", - "integrity": "sha512-I2SYzgqNd5gX8B+hQcff0qpGGwNiHZnXJNgsFyW0UXk1A3fbC/4L1PhSKGSuc7z0+Bk3raMN939E0KroJ5CJhA==", - "bundleDependencies": [ - "prebuild-install" - ], - "hasInstallScript": true, - "dependencies": { - "prebuild-install": "^7.0.1" - } - }, - "node_modules/node-datachannel/node_modules/ansi-regex": { - "version": "2.1.1", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/aproba": { - "version": "1.2.0", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/base64-js": { - "version": "1.5.1", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/buffer": { - "version": "5.7.1", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true, - "license": "MIT", - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.1.13" - } - }, - "node_modules/node-datachannel/node_modules/chownr": { - "version": "1.1.4", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/code-point-at": { - "version": "1.1.0", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/console-control-strings": { - "version": "1.1.0", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/core-util-is": { - "version": "1.0.2", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/decompress-response": { - "version": "6.0.0", - "inBundle": true, - "license": "MIT", - "dependencies": { - "mimic-response": "^3.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/node-datachannel/node_modules/deep-extend": { - "version": "0.6.0", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/node-datachannel/node_modules/delegates": { - "version": "1.0.0", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/detect-libc": { - "version": "2.0.1", - "inBundle": true, - "license": "Apache-2.0", - "engines": { - "node": ">=8" - } - }, - "node_modules/node-datachannel/node_modules/end-of-stream": { - "version": "1.4.4", - "inBundle": true, - "license": "MIT", - "dependencies": { - "once": "^1.4.0" - } - }, - "node_modules/node-datachannel/node_modules/expand-template": { - "version": "2.0.3", - "inBundle": true, - "license": "(MIT OR WTFPL)", - "engines": { - "node": ">=6" - } - }, - "node_modules/node-datachannel/node_modules/fs-constants": { - "version": "1.0.0", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/github-from-package": { - "version": "0.0.0", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/has-unicode": { - "version": "2.0.1", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/ieee754": { - "version": "1.2.1", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true, - "license": "BSD-3-Clause" - }, - "node_modules/node-datachannel/node_modules/inherits": { - "version": "2.0.4", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/ini": { - "version": "1.3.8", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/is-fullwidth-code-point": { - "version": "1.0.0", - "inBundle": true, - "license": "MIT", - "dependencies": { - "number-is-nan": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/isarray": { - "version": "1.0.0", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/lru-cache": { - "version": "6.0.0", - "inBundle": true, - "license": "ISC", - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/node-datachannel/node_modules/lru-cache/node_modules/yallist": { - "version": "4.0.0", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/mimic-response": { - "version": "3.1.0", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/node-datachannel/node_modules/minimist": { - "version": "1.2.6", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/mkdirp-classic": { - "version": "0.5.3", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/napi-build-utils": { - "version": "1.0.2", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/node-abi": { - "version": "3.8.0", - "inBundle": true, - "license": "MIT", + "node_modules/node-abi": { + "version": "3.52.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.52.0.tgz", + "integrity": "sha512-JJ98b02z16ILv7859irtXn4oUaFWADtvkzy2c0IAatNVX2Mc9Yoh8z6hZInn3QwvMEYhHuQloYi+TTQy67SIdQ==", "dependencies": { "semver": "^7.3.5" }, @@ -4611,327 +4981,23 @@ "node": ">=10" } }, - "node_modules/node-datachannel/node_modules/node-abi/node_modules/semver": { - "version": "7.3.7", - "inBundle": true, - "license": "ISC", - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/node-datachannel/node_modules/npmlog": { - "version": "4.1.2", - "inBundle": true, - "license": "ISC", - "dependencies": { - "are-we-there-yet": "~1.1.2", - "console-control-strings": "~1.1.0", - "gauge": "~2.7.3", - "set-blocking": "~2.0.0" - } - }, - "node_modules/node-datachannel/node_modules/npmlog/node_modules/are-we-there-yet": { - "version": "1.1.7", - "inBundle": true, - "license": "ISC", - "dependencies": { - "delegates": "^1.0.0", - "readable-stream": "^2.0.6" - } - }, - "node_modules/node-datachannel/node_modules/npmlog/node_modules/gauge": { - "version": "2.7.4", - "inBundle": true, - "license": "ISC", - "dependencies": { - "aproba": "^1.0.3", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.0", - "object-assign": "^4.1.0", - "signal-exit": "^3.0.0", - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1", - "wide-align": "^1.1.0" - } - }, - "node_modules/node-datachannel/node_modules/number-is-nan": { - "version": "1.0.1", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/object-assign": { - "version": "4.1.1", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/once": { - "version": "1.4.0", - "inBundle": true, - "license": "ISC", - "dependencies": { - "wrappy": "1" - } - }, - "node_modules/node-datachannel/node_modules/prebuild-install": { - "version": "7.0.1", - "inBundle": true, - "license": "MIT", - "dependencies": { - "detect-libc": "^2.0.0", - "expand-template": "^2.0.3", - "github-from-package": "0.0.0", - "minimist": "^1.2.3", - "mkdirp-classic": "^0.5.3", - "napi-build-utils": "^1.0.1", - "node-abi": "^3.3.0", - "npmlog": "^4.0.1", - "pump": "^3.0.0", - "rc": "^1.2.7", - "simple-get": "^4.0.0", - "tar-fs": "^2.0.0", - "tunnel-agent": "^0.6.0" - }, - "bin": { - "prebuild-install": "bin.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/node-datachannel/node_modules/process-nextick-args": { - "version": "2.0.1", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/pump": { - "version": "3.0.0", - "inBundle": true, - "license": "MIT", - "dependencies": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - }, - "node_modules/node-datachannel/node_modules/rc": { - "version": "1.2.8", - "inBundle": true, - "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", - "dependencies": { - "deep-extend": "^0.6.0", - "ini": "~1.3.0", - "minimist": "^1.2.0", - "strip-json-comments": "~2.0.1" - }, - "bin": { - "rc": "cli.js" - } - }, - "node_modules/node-datachannel/node_modules/readable-stream": { - "version": "2.3.7", - "inBundle": true, - "license": "MIT", - "dependencies": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "node_modules/node-datachannel/node_modules/safe-buffer": { - "version": "5.1.2", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/set-blocking": { - "version": "2.0.0", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/signal-exit": { - "version": "3.0.3", - "inBundle": true, - "license": "ISC" - }, - "node_modules/node-datachannel/node_modules/simple-concat": { - "version": "1.0.1", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/simple-get": { - "version": "4.0.1", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true, - "license": "MIT", - "dependencies": { - "decompress-response": "^6.0.0", - "once": "^1.3.1", - "simple-concat": "^1.0.0" - } - }, - "node_modules/node-datachannel/node_modules/string_decoder": { - "version": "1.1.1", - "inBundle": true, - "license": "MIT", - "dependencies": { - "safe-buffer": "~5.1.0" - } - }, - "node_modules/node-datachannel/node_modules/string-width": { - "version": "1.0.2", - "inBundle": true, - "license": "MIT", - "dependencies": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/strip-ansi": { - "version": "3.0.1", - "inBundle": true, - "license": "MIT", - "dependencies": { - "ansi-regex": "^2.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/strip-json-comments": { - "version": "2.0.1", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/node-datachannel/node_modules/tar-fs": { - "version": "2.1.1", - "inBundle": true, - "license": "MIT", - "dependencies": { - "chownr": "^1.1.1", - "mkdirp-classic": "^0.5.2", - "pump": "^3.0.0", - "tar-stream": "^2.1.4" - } - }, - "node_modules/node-datachannel/node_modules/tar-stream": { - "version": "2.1.4", - "inBundle": true, - "license": "MIT", - "dependencies": { - "bl": "^4.0.3", - "end-of-stream": "^1.4.1", - "fs-constants": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^3.1.1" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/node-datachannel/node_modules/tar-stream/node_modules/bl": { - "version": "4.1.0", - "inBundle": true, - "license": "MIT", - "dependencies": { - "buffer": "^5.5.0", - "inherits": "^2.0.4", - "readable-stream": "^3.4.0" - } - }, - "node_modules/node-datachannel/node_modules/tar-stream/node_modules/readable-stream": { - "version": "3.6.0", - "inBundle": true, - "license": "MIT", - "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/node-datachannel/node_modules/tunnel-agent": { - "version": "0.6.0", - "inBundle": true, - "license": "Apache-2.0", + "node_modules/node-datachannel": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/node-datachannel/-/node-datachannel-0.5.2.tgz", + "integrity": "sha512-COuQtVSZc80jt7TV2/BlksOiqZyNFbitDENy8MensezoA7pEGB+lmd9Qk3dnmSZ1nr1vyhF44FL7IkKsQ52Mvw==", + "hasInstallScript": true, "dependencies": { - "safe-buffer": "^5.0.1" + "node-domexception": "^2.0.1", + "prebuild-install": "^7.0.1" }, "engines": { - "node": "*" + "node": ">=16.0.0" } }, - "node_modules/node-datachannel/node_modules/util-deprecate": { - "version": "1.0.2", - "inBundle": true, - "license": "MIT" - }, - "node_modules/node-datachannel/node_modules/wide-align": { - "version": "1.1.5", - "inBundle": true, - "license": "ISC", - "dependencies": { - "string-width": "^1.0.2 || 2 || 3 || 4" - } - }, - "node_modules/node-datachannel/node_modules/wrappy": { - "version": "1.0.2", - "inBundle": true, - "license": "ISC" - }, "node_modules/node-domexception": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-1.0.0.tgz", - "integrity": "sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-2.0.1.tgz", + "integrity": "sha512-M85rnSC7WQ7wnfQTARPT4LrK7nwCHLdDFOCcItZMhTQjyCebJH8GciKqYJNgaOFZs9nFmTmd/VMyi3OW5jA47w==", "funding": [ { "type": "github", @@ -4943,7 +5009,7 @@ } ], "engines": { - "node": ">=10.5.0" + "node": ">=16" } }, "node_modules/node-fetch": { @@ -4971,18 +5037,6 @@ "node": ">= 6.13.0" } }, - "node_modules/node-gyp-build": { - "version": "4.6.0", - "resolved": "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-4.6.0.tgz", - "integrity": "sha512-NTZVKn9IylLwUzaKjkas1e4u2DLNcV4rdYagA4PWdPwW87Bi7z+BznyKSRwS/761tV/lzCGXplWsiaMjLqP2zQ==", - "optional": true, - "peer": true, - "bin": { - "node-gyp-build": "bin.js", - "node-gyp-build-optional": "optional.js", - "node-gyp-build-test": "build-test.js" - } - }, "node_modules/normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", @@ -5030,7 +5084,6 @@ "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", - "dev": true, "dependencies": { "wrappy": "1" } @@ -5091,17 +5144,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/p-event/node_modules/p-timeout": { - "version": "6.1.2", - "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-6.1.2.tgz", - "integrity": "sha512-UbD77BuZ9Bc9aABo74gfXhNvzC9Tx7SxtHSh1fxvx3jTLLYvmVhiQZZrJzqqU0jKbN32kb5VOKiLEQI/3bIjgQ==", - "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/p-limit": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", @@ -5133,11 +5175,11 @@ } }, "node_modules/p-queue": { - "version": "7.3.4", - "resolved": "https://registry.npmjs.org/p-queue/-/p-queue-7.3.4.tgz", - "integrity": "sha512-esox8CWt0j9EZECFvkFl2WNPat8LN4t7WWeXq73D9ha0V96qPRufApZi4ZhPwXAln1uVVal429HVVKPa2X0yQg==", + "version": "7.4.1", + "resolved": "https://registry.npmjs.org/p-queue/-/p-queue-7.4.1.tgz", + "integrity": "sha512-vRpMXmIkYF2/1hLBKisKeVYJZ8S2tZ0zEAmIJgdVKP2nq0nh4qCdf8bgw+ZgKrkh71AOCaqzwbJJk1WtdcF3VA==", "dependencies": { - "eventemitter3": "^4.0.7", + "eventemitter3": "^5.0.1", "p-timeout": "^5.0.2" }, "engines": { @@ -5147,11 +5189,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/p-queue/node_modules/eventemitter3": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", - "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==" - }, "node_modules/p-queue/node_modules/p-timeout": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-5.1.0.tgz", @@ -5164,11 +5201,12 @@ } }, "node_modules/p-retry": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/p-retry/-/p-retry-6.0.0.tgz", - "integrity": "sha512-6NuuXu8Upembd4sNdo4PRbs+M6aHgBTrFE6lkH0YKjVzne3cDW4gkncB98ty/bkMxLxLVNeD5bX9FyWjM7WZ+A==", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/p-retry/-/p-retry-6.1.0.tgz", + "integrity": "sha512-fJLEQ2KqYBJRuaA/8cKMnqhulqNM+bpcjYtXNex2t3mOXKRYPitAJt9NacSf8XAFzcYahSAbKpobiWDSqHSh2g==", "dependencies": { "@types/retry": "0.12.2", + "is-network-error": "^1.0.0", "retry": "^0.13.1" }, "engines": { @@ -5179,9 +5217,9 @@ } }, "node_modules/p-timeout": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-6.1.1.tgz", - "integrity": "sha512-yqz2Wi4fiFRpMmK0L2pGAU49naSUaP23fFIQL2Y6YT+qDGPoFwpvgQM/wzc6F8JoenUkIlAFa4Ql7NguXBxI7w==", + "version": "6.1.2", + "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-6.1.2.tgz", + "integrity": "sha512-UbD77BuZ9Bc9aABo74gfXhNvzC9Tx7SxtHSh1fxvx3jTLLYvmVhiQZZrJzqqU0jKbN32kb5VOKiLEQI/3bIjgQ==", "engines": { "node": ">=14.16" }, @@ -5268,6 +5306,31 @@ "resolved": "https://registry.npmjs.org/platform/-/platform-1.3.6.tgz", "integrity": "sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg==" }, + "node_modules/prebuild-install": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.1.tgz", + "integrity": "sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw==", + "dependencies": { + "detect-libc": "^2.0.0", + "expand-template": "^2.0.3", + "github-from-package": "0.0.0", + "minimist": "^1.2.3", + "mkdirp-classic": "^0.5.3", + "napi-build-utils": "^1.0.1", + "node-abi": "^3.3.0", + "pump": "^3.0.0", + "rc": "^1.2.7", + "simple-get": "^4.0.0", + "tar-fs": "^2.0.0", + "tunnel-agent": "^0.6.0" + }, + "bin": { + "prebuild-install": "bin.js" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -5278,9 +5341,9 @@ } }, "node_modules/prettier": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.0.3.tgz", - "integrity": "sha512-L/4pUDMxcNa8R/EthV08Zt42WBO4h1rarVtK0K+QJG0X187OLo7l699jWw0GKuwzkPQ//jMFA/8Xm6Fh3J/DAg==", + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.1.1.tgz", + "integrity": "sha512-22UbSzg8luF4UuZtzgiUOfcGM8s4tjBv6dJRT7j275NXsy2jb4aJa4NNveul5x4eqlF1wuhuR2RElK71RvmVaw==", "dev": true, "bin": { "prettier": "bin/prettier.cjs" @@ -5347,15 +5410,21 @@ } }, "node_modules/protons-runtime": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/protons-runtime/-/protons-runtime-5.0.2.tgz", - "integrity": "sha512-eKppVrIS5dDh+Y61Yj4bDEOs2sQLQbQGIhr7EBiybPQhIMGBynzVXlYILPWl3Td1GDadobc8qevh5D+JwfG9bw==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/protons-runtime/-/protons-runtime-5.2.0.tgz", + "integrity": "sha512-jL3VSbXllgm17zurKQ/z+Ath0w+4BknJ+l/NLocfjAB8hbeASOZTNtb7zK3nDsKq2pHK9YFumNQvpkZ6gFfWhA==", "dependencies": { - "protobufjs": "^7.0.0", - "uint8arraylist": "^2.4.3" - }, - "peerDependencies": { - "uint8arraylist": "^2.3.2" + "uint8arraylist": "^2.4.3", + "uint8arrays": "^4.0.6" + } + }, + "node_modules/pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" } }, "node_modules/punycode": { @@ -5422,6 +5491,11 @@ } } }, + "node_modules/race-signal": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/race-signal/-/race-signal-1.0.2.tgz", + "integrity": "sha512-o3xNv0iTcIDQCXFlF6fPAMEBRjFxssgGoRqLbg06m+AdzEXXLUmoNOoUHTVz2NoBI8hHwKFKoC6IqyNtWr2bww==" + }, "node_modules/rambda": { "version": "7.5.0", "resolved": "https://registry.npmjs.org/rambda/-/rambda-7.5.0.tgz", @@ -5438,9 +5512,31 @@ } }, "node_modules/rate-limiter-flexible": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/rate-limiter-flexible/-/rate-limiter-flexible-3.0.0.tgz", - "integrity": "sha512-janAJkWxWxmLka0hV+XvCTo0M8keeSeOuz8ZL33cTXrkS4ek9mQ2VJm9ri7fm03oTVth19Sfqb1ijCmo7K/vAg==" + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/rate-limiter-flexible/-/rate-limiter-flexible-3.0.6.tgz", + "integrity": "sha512-tlvbee6lyse/XTWmsuBDS4MT8N65FyM151bPmQlFyfhv9+RIHs7d3rSTXoz0j35H910dM01mH0yTIeWYo8+aAw==" + }, + "node_modules/rc": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/rc/node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "engines": { + "node": ">=0.10.0" + } }, "node_modules/readable-stream": { "version": "3.6.2", @@ -5563,10 +5659,23 @@ } }, "node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] }, "node_modules/sanitize-filename": { "version": "1.6.3", @@ -5577,15 +5686,14 @@ } }, "node_modules/sax": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", - "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==" + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.3.0.tgz", + "integrity": "sha512-0s+oAmw9zLl1V1cS9BtZN7JAd0cW5e0QH4W3LWEK6a4LaLEA2OTpGYWDY+6XasBLtz6wkm3u1xRw95mRuJ59WA==" }, "node_modules/semver": { "version": "7.5.4", "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", - "dev": true, "dependencies": { "lru-cache": "^6.0.0" }, @@ -5629,10 +5737,53 @@ "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" }, + "node_modules/simple-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", + "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/simple-get": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-4.0.1.tgz", + "integrity": "sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "decompress-response": "^6.0.0", + "once": "^1.3.1", + "simple-concat": "^1.0.0" + } + }, "node_modules/sinon": { - "version": "16.0.0", - "resolved": "https://registry.npmjs.org/sinon/-/sinon-16.0.0.tgz", - "integrity": "sha512-B8AaZZm9CT5pqe4l4uWJztfD/mOTa7dL8Qo0W4+s+t74xECOgSZDDQCBjNgIK3+n4kyxQrSTv2V5ul8K25qkiQ==", + "version": "16.1.3", + "resolved": "https://registry.npmjs.org/sinon/-/sinon-16.1.3.tgz", + "integrity": "sha512-mjnWWeyxcAf9nC0bXcPmiDut+oE8HYridTNzBbF98AYVLmWwGRp2ISEpyhYflG1ifILT+eNn3BmKUJPxjXUPlA==", "dev": true, "dependencies": { "@sinonjs/commons": "^3.0.0", @@ -5647,15 +5798,6 @@ "url": "https://opencollective.com/sinon" } }, - "node_modules/sinon/node_modules/@sinonjs/commons": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.0.tgz", - "integrity": "sha512-jXBtWAF4vmdNmZgD5FoKsVLv3rPgDnLgPbU84LIJ3otV44vJlDRokVng5v8NFJdCf/da9legHcKaRuZs4L7faA==", - "dev": true, - "dependencies": { - "type-detect": "4.0.8" - } - }, "node_modules/sinon/node_modules/diff": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/diff/-/diff-5.1.0.tgz", @@ -5675,12 +5817,11 @@ } }, "node_modules/smoldot": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/smoldot/-/smoldot-1.0.4.tgz", - "integrity": "sha512-N3TazI1C4GGrseFH/piWyZCCCRJTRx2QhDfrUKRT4SzILlW5m8ayZ3QTKICcz1C/536T9cbHHJyP7afxI6Mi1A==", + "version": "2.0.7", + "resolved": "https://registry.npmjs.org/smoldot/-/smoldot-2.0.7.tgz", + "integrity": "sha512-VAOBqEen6vises36/zgrmAT1GWk2qE3X8AGnO7lmQFdskbKx8EovnwS22rtPAG+Y1Rk23/S22kDJUdPANyPkBA==", "optional": true, "dependencies": { - "pako": "^2.0.4", "ws": "^8.8.1" } }, @@ -5719,25 +5860,6 @@ "safe-buffer": "~5.2.0" } }, - "node_modules/string_decoder/node_modules/safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, "node_modules/string-width": { "version": "4.2.3", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", @@ -5799,6 +5921,65 @@ "node": ">=8" } }, + "node_modules/tar-fs": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz", + "integrity": "sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==", + "dependencies": { + "chownr": "^1.1.1", + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^2.1.4" + } + }, + "node_modules/tar-stream": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", + "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", + "dependencies": { + "bl": "^4.0.3", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/tar-stream/node_modules/bl": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", + "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } + }, + "node_modules/tar-stream/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", @@ -5864,9 +6045,9 @@ } }, "node_modules/ts-node": { - "version": "10.9.1", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", - "integrity": "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==", + "version": "10.9.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.2.tgz", + "integrity": "sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==", "dev": true, "dependencies": { "@cspotcode/source-map-support": "^0.8.0", @@ -5920,6 +6101,17 @@ "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" }, + "node_modules/tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": "*" + } + }, "node_modules/type-check": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", @@ -5954,9 +6146,9 @@ } }, "node_modules/typescript": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.2.2.tgz", - "integrity": "sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w==", + "version": "5.3.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", + "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", "dev": true, "bin": { "tsc": "bin/tsc", @@ -5980,44 +6172,34 @@ } }, "node_modules/uint8-varint": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/uint8-varint/-/uint8-varint-2.0.1.tgz", - "integrity": "sha512-euvmpuulJstK5+xNuI4S1KfnxJnbI5QP52RXIR3GZ3/ZMkOsEK2AgCtFpNvEQLXMxMx2o0qcyevK1fJwOZJagQ==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/uint8-varint/-/uint8-varint-2.0.2.tgz", + "integrity": "sha512-LZXmBT0jiHR7J4oKM1GUhtdLFW1yPauzI8NjJlotXn92TprO9u8VMvEVR4QMk8xhUVUd+2fqfU2/kGbVHYSSWw==", "dependencies": { "uint8arraylist": "^2.0.0", "uint8arrays": "^4.0.2" } }, "node_modules/uint8arraylist": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/uint8arraylist/-/uint8arraylist-2.4.3.tgz", - "integrity": "sha512-oEVZr4/GrH87K0kjNce6z8pSCzLEPqHNLNR5sj8cJOySrTP8Vb/pMIbZKLJGhQKxm1TiZ31atNrpn820Pyqpow==", + "version": "2.4.7", + "resolved": "https://registry.npmjs.org/uint8arraylist/-/uint8arraylist-2.4.7.tgz", + "integrity": "sha512-ohRElqR6C5dd60vRFLq40MCiSnUe1AzkpHvbCEMCGGP6zMoFYECsjdhL6bR1kTK37ONNRDuHQ3RIpScRYcYYIg==", "dependencies": { "uint8arrays": "^4.0.2" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=7.0.0" } }, "node_modules/uint8arrays": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-4.0.6.tgz", - "integrity": "sha512-4ZesjQhqOU2Ip6GPReIwN60wRxIupavL8T0Iy36BBHr2qyMrNxsPJvr7vpS4eFt8F8kSguWUPad6ZM9izs/vyw==", + "version": "4.0.10", + "resolved": "https://registry.npmjs.org/uint8arrays/-/uint8arrays-4.0.10.tgz", + "integrity": "sha512-AnJNUGGDJAgFw/eWu/Xb9zrVKEGlwJJCaeInlf3BkecE/zcTobk5YXYIPNQJO1q5Hh1QZrQQHf0JvcHqz2hqoA==", "dependencies": { "multiformats": "^12.0.1" } }, - "node_modules/undici": { - "version": "5.28.1", - "resolved": "https://registry.npmjs.org/undici/-/undici-5.28.1.tgz", - "integrity": "sha512-xcIIvj1LOQH9zAL54iWFkuDEaIVEjLrru7qRpa3GrEEHk6OBhb/LycuUY2m7VCcTuDeLziXCxobQVyKExyGeIA==", - "dependencies": { - "@fastify/busboy": "^2.0.0" - }, - "engines": { - "node": ">=14.0" - } + "node_modules/undici-types": { + "version": "5.26.5", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", + "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==" }, "node_modules/uri-js": { "version": "4.4.1", @@ -6028,20 +6210,6 @@ "punycode": "^2.1.0" } }, - "node_modules/utf-8-validate": { - "version": "5.0.10", - "resolved": "https://registry.npmjs.org/utf-8-validate/-/utf-8-validate-5.0.10.tgz", - "integrity": "sha512-Z6czzLq4u8fPOyx7TU6X3dvUZVvoJmxSQ+IcrlmagKhilxlhZgxPK6C5Jqbkw1IDUmFTM+cz9QDnnLTwDz/2gQ==", - "hasInstallScript": true, - "optional": true, - "peer": true, - "dependencies": { - "node-gyp-build": "^4.3.0" - }, - "engines": { - "node": ">=6.14.2" - } - }, "node_modules/utf8-byte-length": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/utf8-byte-length/-/utf8-byte-length-1.0.4.tgz", @@ -6159,13 +6327,12 @@ "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "dev": true + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" }, "node_modules/ws": { - "version": "8.14.2", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.14.2.tgz", - "integrity": "sha512-wEBG1ftX4jcglPxgFCMJmZ2PLtSbJ2Peg6TmpJFTbe9GZYOQCDPdMYu/Tm0/bGZkw8paZnJY45J4K2PZrLYq8g==", + "version": "8.15.1", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.15.1.tgz", + "integrity": "sha512-W5OZiCjXEmk0yZ66ZN82beM5Sz7l7coYxpRkzS+p9PP+ToQry8szKh+61eNktr7EA9DOwvFGhfC605jDHbP6QQ==", "engines": { "node": ">=10.0.0" }, @@ -6219,8 +6386,7 @@ "node_modules/yallist": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" }, "node_modules/yargs": { "version": "17.7.2", @@ -6264,18 +6430,6 @@ "node": ">=10" } }, - "node_modules/yargs-unparser/node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/yargs/node_modules/yargs-parser": { "version": "21.1.1", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 8cca465025..5430b9cf09 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -1,5 +1,4 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, types}; -use sp_runtime::Saturating; +use crate::{types, BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -10,7 +9,7 @@ use frame_support::{ }; use parity_scale_codec::Encode; use sp_core::hexdisplay::HexDisplay; -use sp_runtime::traits::Zero; +use sp_runtime::{traits::Zero, Saturating}; const LOG_TARGET: &str = "runtime::capacity"; @@ -22,10 +21,7 @@ const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; /// Only contains V1 storage format pub mod v1 { use super::*; - use frame_support::{pallet_prelude::ValueQuery, storage_alias, BoundedVec, Twox64Concat}; - use parity_scale_codec::{Decode, Encode, HasCompact, MaxEncodedLen}; - use scale_info::TypeInfo; - use sp_runtime::RuntimeDebug; + use frame_support::{pallet_prelude::ValueQuery, storage_alias, BoundedVec}; pub(crate) type ReleaseScheduleOf = types::ReleaseSchedule, BalanceOf>; @@ -98,8 +94,14 @@ where // Get the total amount of tokens in the account's ReleaseSchedules let total_amount = v1::ReleaseSchedules::::get(&account_id) // 1r .iter() - .map(|schedule: &types::ReleaseSchedule, BalanceOf>| schedule.total_amount()) - .fold(Zero::zero(), |acc: BalanceOf, amount| acc.saturating_add(amount.unwrap_or(Zero::zero()))); + .map( + |schedule: &types::ReleaseSchedule, BalanceOf>| { + schedule.total_amount() + }, + ) + .fold(Zero::zero(), |acc: BalanceOf, amount| { + acc.saturating_add(amount.unwrap_or(Zero::zero())) + }); // Translate the lock to a freeze MigrationToV3::::translate_lock_to_freeze( account_id, @@ -186,11 +188,6 @@ mod test { Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 50u64, reasons: Reasons::All }) ); - // let old_record = - // OldStakingDetails:: { active: amount, staking_type: MaximumCapacity }; - // OldStakingAccountLedger::::insert(account, old_record); - // assert_eq!(OldStakingAccountLedger::::iter().count(), 1); - // Run migration. let state = MigrationOf::::pre_upgrade().unwrap(); MigrationOf::::on_runtime_upgrade(); From 4253049144de80352409a414044988ee4bff3faa Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 13 Dec 2023 09:13:05 -0700 Subject: [PATCH 45/75] fix: remove unnecessary mod v2; --- pallets/capacity/src/migration/v3.rs | 51 +++++++--------------------- 1 file changed, 13 insertions(+), 38 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index c0ff9b883a..d0462d9442 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,4 +1,4 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingType}; +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -12,36 +12,10 @@ use sp_core::hexdisplay::HexDisplay; const LOG_TARGET: &str = "runtime::capacity"; #[cfg(feature = "try-runtime")] -use sp_std::{fmt::Debug, vec::Vec}; +use sp_std::vec::Vec; const STAKING_ID: LockIdentifier = *b"netstkng"; -/// Only contains V2 storage format -pub mod v2 { - use super::*; - use frame_support::{storage_alias, Twox64Concat}; - use parity_scale_codec::{Decode, Encode, MaxEncodedLen}; - use scale_info::TypeInfo; - - #[derive(Encode, Decode, PartialEq, Debug, TypeInfo, Eq, MaxEncodedLen)] - /// The StakingDetails struct - pub struct StakingDetails { - /// The amount a Staker has staked, minus the sum of all tokens in `unlocking`. - pub active: BalanceOf, - /// The type of staking for this staking account - pub staking_type: StakingType, - } - - #[storage_alias] - /// alias to StakingAccountLedger storage - pub(crate) type StakingAccountLedger = StorageMap< - Pallet, - Twox64Concat, - ::AccountId, - StakingDetails, - >; -} - /// The OnRuntimeUpgrade implementation for this storage migration pub struct MigrationToV3(sp_std::marker::PhantomData<(T, OldCurrency)>); impl MigrationToV3 @@ -57,6 +31,7 @@ where .unwrap_or_else(|err| { log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); }); // 1r + log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); } } @@ -72,7 +47,8 @@ where if on_chain_version.lt(&3) { log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration started"); let mut maybe_count = 0u32; - v2::StakingAccountLedger::::iter() + // TODO: Update amount to include unlocking chunks as well + StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) .for_each(|(staker, amount)| { MigrationToV3::::translate_lock_to_freeze( @@ -101,20 +77,19 @@ where #[cfg(feature = "try-runtime")] fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { use frame_support::storage::generator::StorageMap; - let pallet_prefix = v2::StakingAccountLedger::::module_prefix(); - let storage_prefix = v2::StakingAccountLedger::::storage_prefix(); + let pallet_prefix = StakingAccountLedger::::module_prefix(); + let storage_prefix = StakingAccountLedger::::storage_prefix(); assert_eq!(&b"Capacity"[..], pallet_prefix); assert_eq!(&b"StakingAccountLedger"[..], storage_prefix); log::info!(target: LOG_TARGET, "Running pre_upgrade..."); - let count = v2::StakingAccountLedger::::iter().count() as u32; + let count = StakingAccountLedger::::iter().count() as u32; log::info!(target: LOG_TARGET, "Finish pre_upgrade for {:?} records", count); Ok(count.encode()) } #[cfg(feature = "try-runtime")] fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { - use crate::StakingAccountLedger; use parity_scale_codec::Decode; let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); let on_chain_version = Pallet::::on_chain_storage_version(); @@ -135,7 +110,7 @@ mod test { use super::*; use crate::{ tests::mock::{Test as T, *}, - StakingAccountLedger as OldStakingAccountLedger, StakingDetails as OldStakingDetails, + StakingAccountLedger, StakingDetails, StakingType::MaximumCapacity, }; use pallet_balances::{BalanceLock, Reasons}; @@ -163,10 +138,10 @@ mod test { Some(&BalanceLock { id: STAKING_ID, amount: 50u64, reasons: Reasons::All }) ); - let old_record = - OldStakingDetails:: { active: amount, staking_type: MaximumCapacity }; - OldStakingAccountLedger::::insert(account, old_record); - assert_eq!(OldStakingAccountLedger::::iter().count(), 1); + let test_record = + StakingDetails:: { active: amount, staking_type: MaximumCapacity }; + StakingAccountLedger::::insert(account, test_record); + assert_eq!(StakingAccountLedger::::iter().count(), 1); // Run migration. let state = MigrationOf::::pre_upgrade().unwrap(); From 2531e17f7141936e9e97a945dcfd1e772f1dde1b Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 13 Dec 2023 11:24:50 -0700 Subject: [PATCH 46/75] fix: locked amount should be --- pallets/capacity/src/lib.rs | 10 ++++++++++ pallets/capacity/src/migration/v3.rs | 14 +++++++------- 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index b4f4826471..8e2985a076 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -583,6 +583,16 @@ impl Pallet { .min(proposed_amount) } + // Calculates the total amount of tokens that are currently unlocked for the given staker. + pub(crate) fn get_unlocking_total_for(staker: &T::AccountId) -> BalanceOf { + let mut total_unlocking: BalanceOf = Zero::zero(); + let unlocks = Self::get_unstake_unlocking_for(staker).unwrap_or_default(); + if !unlocks.is_empty() { + total_unlocking = unlock_chunks_total::(&unlocks); + } + total_unlocking + } + pub(crate) fn do_withdraw_unstaked( staker: &T::AccountId, ) -> Result, DispatchError> { diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index d0462d9442..44d6420194 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -8,6 +8,7 @@ use frame_support::{ }; use parity_scale_codec::Encode; use sp_core::hexdisplay::HexDisplay; +use sp_runtime::Saturating; const LOG_TARGET: &str = "runtime::capacity"; @@ -30,7 +31,7 @@ where T::Currency::set_freeze(&FreezeReason::Staked.into(), &account_id, amount.into()) .unwrap_or_else(|err| { log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); - }); // 1r + }); // 1w log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); } } @@ -47,21 +48,20 @@ where if on_chain_version.lt(&3) { log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration started"); let mut maybe_count = 0u32; - // TODO: Update amount to include unlocking chunks as well StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) - .for_each(|(staker, amount)| { + .for_each(|(staker, mut amount)| { + amount = amount.saturating_add(Pallet::::get_unlocking_total_for(&staker)); // 1r MigrationToV3::::translate_lock_to_freeze( staker, amount.into(), - ); + ); // 1r + 2w maybe_count += 1; - log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); + log::info!(target: LOG_TARGET,"migrated {:?}, amount:{:?}", maybe_count, amount); }); StorageVersion::new(3).put::>(); // 1 w - let reads = (maybe_count + 1) as u64; - // REVIEW: Are we doing 2 writes per account? + let reads = (maybe_count * 2 + 1) as u64; let writes = (maybe_count * 2 + 1) as u64; log::info!(target: LOG_TARGET, "🔄 migration finished"); let weight = T::DbWeight::get().reads_writes(reads, writes); From 1155d3f065daa3e18f4b99d9c02fbb92e314c8c3 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 13 Dec 2023 14:46:07 -0700 Subject: [PATCH 47/75] fix: update mock accounts for testing; --- pallets/time-release/src/migration/v2.rs | 3 ++- pallets/time-release/src/mock.rs | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 5430b9cf09..e44957acdb 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -173,8 +173,9 @@ mod test { StorageVersion::new(2).put::>(); // Create some data in the old format // Grab an account with a balance - let account = 200; + let account = DAVE; let amount = 50; + assert_eq!(pallet_balances::Pallet::::free_balance(&account), DAVE_BALANCE); pallet_balances::Pallet::::set_lock( RELEASE_LOCK_ID, diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index 4e42ec48a7..462ed82219 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -117,9 +117,11 @@ construct_runtime!( pub const ALICE: AccountId = 0; pub const BOB: AccountId = 2; pub const CHARLIE: AccountId = 3; +pub const DAVE: AccountId = 4; pub const ALICE_BALANCE: u64 = 100; pub const CHARLIE_BALANCE: u64 = 50; +pub const DAVE_BALANCE: u64 = 200; #[derive(Default)] pub struct ExtBuilder; @@ -131,7 +133,7 @@ impl ExtBuilder { MockBlockNumberProvider::set(0); pallet_balances::GenesisConfig:: { - balances: vec![(ALICE, ALICE_BALANCE), (CHARLIE, CHARLIE_BALANCE)], + balances: vec![(ALICE, ALICE_BALANCE), (CHARLIE, CHARLIE_BALANCE), (DAVE, DAVE_BALANCE)], } .assimilate_storage(&mut t) .unwrap(); From 672b4ddad8bc6208adbb4bc4cb42a1e47be28fcd Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 16:22:12 -0800 Subject: [PATCH 48/75] add more test for time-release - currently failing --- pallets/time-release/src/migration/v2.rs | 108 +++++++++++++++++++---- 1 file changed, 90 insertions(+), 18 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index e44957acdb..372a8b8ecc 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -68,10 +68,20 @@ where pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1r + 1w // TODO: Can we do anything if set_freeze fails? - T::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), &account_id, amount.into()) - .unwrap_or_else(|err| { - log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); - }); // 1w + T::Currency::set_freeze( + &FreezeReason::TimeReleaseVesting.into(), + &account_id, + amount.into(), + ) + .unwrap_or_else(|err| { + log::error!( + target: LOG_TARGET, + "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", + amount, + HexDisplay::from(&account_id.encode()), + err + ); + }); // 1w } } @@ -108,7 +118,7 @@ where total_amount.into(), ); maybe_count += 1; - log::info!(target: LOG_TARGET,"migrated {:?}", maybe_count); + log::info!(target: LOG_TARGET, "migrated {:?}", maybe_count); }, ); @@ -118,11 +128,18 @@ where let writes = (maybe_count * 2 + 1) as u64; log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); let weight = T::DbWeight::get().reads_writes(reads, writes); - log::info!(target: LOG_TARGET, "Time Release Migration calculated weight = {:?}", weight); + log::info!( + target: LOG_TARGET, + "Time Release Migration calculated weight = {:?}", + weight + ); weight } else { // storage was already migrated. - log::info!(target: LOG_TARGET, "Old Time Release Locks->Freezes migration attempted to run. Please remove"); + log::info!( + target: LOG_TARGET, + "Old Time Release Locks->Freezes migration attempted to run. Please remove" + ); T::DbWeight::get().reads(1) } } @@ -177,17 +194,14 @@ mod test { let amount = 50; assert_eq!(pallet_balances::Pallet::::free_balance(&account), DAVE_BALANCE); - pallet_balances::Pallet::::set_lock( - RELEASE_LOCK_ID, - &account, - amount, - WithdrawReasons::all(), - ); - // Confirm lock exists - assert_eq!( - pallet_balances::Pallet::::locks(&account).get(0), - Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 50u64, reasons: Reasons::All }) - ); + let schedules = vec![ + // who, start, period, period_count, per_period + (DAVE, 2, 3, 1, 5), + ]; + create_schedules(schedules); + + + // Run migration. let state = MigrationOf::::pre_upgrade().unwrap(); @@ -205,4 +219,62 @@ mod test { ); }) } + + fn create_schedules(schedules: Vec<(AccountId, u32, u32, u32, u64)>) { + schedules.iter().for_each(|(who, start, period, period_count, per_period)| { + let mut bounded_schedules = v1::ReleaseSchedules::::get(who); + let new_schedule = types::ReleaseSchedule { + start: *start, + period: *period, + period_count: *period_count, + per_period: *per_period, + }; + + bounded_schedules + .try_push(new_schedule.clone()) + .expect("Max release schedules exceeded"); + + let total_amount = bounded_schedules + .iter() + .fold( + Zero::zero(), + |acc_amount: BalanceOf, schedule| { + acc_amount + .saturating_add(schedule.total_amount().unwrap_or(Zero::zero())) + }, + ); + + assert_eq!(total_amount, new_schedule.total_amount().unwrap_or(Zero::zero())); + + assert!( + pallet_balances::Pallet::::free_balance(who) >= total_amount, + "Account do not have enough balance" + ); + + pallet_balances::Pallet::::set_lock( + RELEASE_LOCK_ID, + &who, + total_amount, + WithdrawReasons::all(), + ); + + assert_eq!( + pallet_balances::Pallet::::locks(&who).get(0), + Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: total_amount, reasons: Reasons::All }) + ); + + v1::ReleaseSchedules::::insert(who, bounded_schedules); + }); + + } } +// 1. we want to test migration is succesful +// when user claims their tokens that lock/thaw (generic) is removed. +// 2. Check that locks are translated to frozen. + +// How to set this up: +// 1. create release schedules for an account +// 2. set the old locks on the account manually ( looks like genesis build function) +// 3. assert that the locks are there. +// 4. run the migration +// 5. assert that the locks are gone and the freezes are there. From b9de9e231a044143dc424233de8eaf60913bd41e Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 17:39:28 -0800 Subject: [PATCH 49/75] update timerelease migration test --- pallets/time-release/src/migration/v2.rs | 85 +++++++++++++----------- 1 file changed, 45 insertions(+), 40 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 372a8b8ecc..e28e94c54a 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -14,7 +14,7 @@ use sp_runtime::{traits::Zero, Saturating}; const LOG_TARGET: &str = "runtime::capacity"; #[cfg(feature = "try-runtime")] -use sp_std::{fmt::Debug, vec::Vec}; +use sp_std::vec::Vec; const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; @@ -92,8 +92,19 @@ where OldCurrency::Balance: IsType>, { fn on_runtime_upgrade() -> Weight { + log::info!(target: LOG_TARGET, "Running storage migration..."); + let onchain_version = Pallet::::on_chain_storage_version(); + let current_version = Pallet::::current_storage_version(); + log::info!( + target: LOG_TARGET, + "onchain_version= {:?}, current_version={:?}", + onchain_version, + current_version + ); + let on_chain_version = Pallet::::on_chain_storage_version(); // 1r + // Pallet::::STORAGE_VERSION.get() if on_chain_version.lt(&2) { log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); let mut maybe_count = 0u32; @@ -101,6 +112,7 @@ where // Get all the keys(accounts) from the ReleaseSchedules storage v1::ReleaseSchedules::::iter().map(|(account_id, _)| account_id).for_each( |account_id| { + println!("account_id {:?}", account_id); // Get the total amount of tokens in the account's ReleaseSchedules let total_amount = v1::ReleaseSchedules::::get(&account_id) // 1r .iter() @@ -112,12 +124,15 @@ where .fold(Zero::zero(), |acc: BalanceOf, amount| { acc.saturating_add(amount.unwrap_or(Zero::zero())) }); + // Translate the lock to a freeze MigrationToV3::::translate_lock_to_freeze( account_id, total_amount.into(), ); maybe_count += 1; + + log::info!(target: LOG_TARGET, "total_amount {:?}", total_amount); log::info!(target: LOG_TARGET, "migrated {:?}", maybe_count); }, ); @@ -187,40 +202,49 @@ mod test { #[test] fn migration_works() { ExtBuilder::build().execute_with(|| { - StorageVersion::new(2).put::>(); - // Create some data in the old format - // Grab an account with a balance - let account = DAVE; - let amount = 50; - assert_eq!(pallet_balances::Pallet::::free_balance(&account), DAVE_BALANCE); + assert_eq!(pallet_balances::Pallet::::free_balance(&DAVE), DAVE_BALANCE); let schedules = vec![ // who, start, period, period_count, per_period (DAVE, 2, 3, 1, 5), ]; - create_schedules(schedules); - + create_schedules_and_set_lock(schedules); + assert_eq!( + pallet_balances::Pallet::::locks(&DAVE) + .iter() + .find(|l| l.id == RELEASE_LOCK_ID), + Some(&BalanceLock { + id: RELEASE_LOCK_ID, + amount: total_amount, + reasons: Reasons::All + }) + ); // Run migration. let state = MigrationOf::::pre_upgrade().unwrap(); MigrationOf::::on_runtime_upgrade(); MigrationOf::::post_upgrade(state).unwrap(); - // Check that the old staking locks are now freezes - assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); + assert_eq!( + pallet_balances::Pallet::::locks(&DAVE), + vec![], + "Locks should be empty" + ); assert_eq!( ::Currency::balance_frozen( &FreezeReason::TimeReleaseVesting.into(), - &account + &DAVE ), - 50u64 + 5u64, + "Frozen balance should be 5 for account {:?}", + DAVE ); }) } - fn create_schedules(schedules: Vec<(AccountId, u32, u32, u32, u64)>) { + fn create_schedules_and_set_lock(schedules: Vec<(AccountId, u32, u32, u32, u64)>) { schedules.iter().for_each(|(who, start, period, period_count, per_period)| { let mut bounded_schedules = v1::ReleaseSchedules::::get(who); let new_schedule = types::ReleaseSchedule { @@ -234,21 +258,18 @@ mod test { .try_push(new_schedule.clone()) .expect("Max release schedules exceeded"); - let total_amount = bounded_schedules - .iter() - .fold( - Zero::zero(), - |acc_amount: BalanceOf, schedule| { - acc_amount - .saturating_add(schedule.total_amount().unwrap_or(Zero::zero())) - }, - ); + let total_amount = bounded_schedules.iter().fold( + Zero::zero(), + |acc_amount: BalanceOf, schedule| { + acc_amount.saturating_add(schedule.total_amount().unwrap_or(Zero::zero())) + }, + ); assert_eq!(total_amount, new_schedule.total_amount().unwrap_or(Zero::zero())); assert!( pallet_balances::Pallet::::free_balance(who) >= total_amount, - "Account do not have enough balance" + "Account does not have enough balance" ); pallet_balances::Pallet::::set_lock( @@ -257,24 +278,8 @@ mod test { total_amount, WithdrawReasons::all(), ); - - assert_eq!( - pallet_balances::Pallet::::locks(&who).get(0), - Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: total_amount, reasons: Reasons::All }) - ); v1::ReleaseSchedules::::insert(who, bounded_schedules); }); - } } -// 1. we want to test migration is succesful -// when user claims their tokens that lock/thaw (generic) is removed. -// 2. Check that locks are translated to frozen. - -// How to set this up: -// 1. create release schedules for an account -// 2. set the old locks on the account manually ( looks like genesis build function) -// 3. assert that the locks are there. -// 4. run the migration -// 5. assert that the locks are gone and the freezes are there. From fbb667116f3f707479575008bfaca8793b00d87d Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 17:53:41 -0800 Subject: [PATCH 50/75] lint --- pallets/time-release/src/migration/v2.rs | 1 - pallets/time-release/src/mock.rs | 6 +++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index e28e94c54a..aa2a8bc698 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -112,7 +112,6 @@ where // Get all the keys(accounts) from the ReleaseSchedules storage v1::ReleaseSchedules::::iter().map(|(account_id, _)| account_id).for_each( |account_id| { - println!("account_id {:?}", account_id); // Get the total amount of tokens in the account's ReleaseSchedules let total_amount = v1::ReleaseSchedules::::get(&account_id) // 1r .iter() diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index 462ed82219..3789cbe8f6 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -133,7 +133,11 @@ impl ExtBuilder { MockBlockNumberProvider::set(0); pallet_balances::GenesisConfig:: { - balances: vec![(ALICE, ALICE_BALANCE), (CHARLIE, CHARLIE_BALANCE), (DAVE, DAVE_BALANCE)], + balances: vec![ + (ALICE, ALICE_BALANCE), + (CHARLIE, CHARLIE_BALANCE), + (DAVE, DAVE_BALANCE), + ], } .assimilate_storage(&mut t) .unwrap(); From bdfc0f202812d4c012c3bdf2598fa68e964fa196 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 17:55:46 -0800 Subject: [PATCH 51/75] rm comment --- pallets/time-release/src/migration/v2.rs | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index aa2a8bc698..be7e0e92cc 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -25,23 +25,6 @@ pub mod v1 { pub(crate) type ReleaseScheduleOf = types::ReleaseSchedule, BalanceOf>; - /// The release schedule. - /// - /// Benefits would be granted gradually, `per_period` amount every `period` - /// of blocks after `start`. - // #[derive(Clone, Encode, Decode, PartialEq, Eq, RuntimeDebug, MaxEncodedLen, TypeInfo)] - // pub struct ReleaseSchedule { - // /// Vesting starting block - // pub start: BlockNumber, - // /// Number of blocks between vest - // pub period: BlockNumber, - // /// Number of vest - // pub period_count: u32, - // /// Amount of tokens to release per vest - // #[codec(compact)] - // pub per_period: Balance, - // } - /// Release schedules of an account. /// /// ReleaseSchedules: `map AccountId => Vec` From 4cf44edb407d4f4b23558521bcc3a79b3cb685e1 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 18:06:46 -0800 Subject: [PATCH 52/75] changes --- pallets/time-release/src/migration/v2.rs | 29 ++++++++---------------- 1 file changed, 10 insertions(+), 19 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index be7e0e92cc..43f067c788 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -40,8 +40,8 @@ pub mod v1 { } /// The OnRuntimeUpgrade implementation for this storage migration -pub struct MigrationToV3(sp_std::marker::PhantomData<(T, OldCurrency)>); -impl MigrationToV3 +pub struct MigrationToV2(sp_std::marker::PhantomData<(T, OldCurrency)>); +impl MigrationToV2 where T: Config, OldCurrency: 'static + LockableCurrency>, @@ -68,7 +68,7 @@ where } } -impl OnRuntimeUpgrade for MigrationToV3 +impl OnRuntimeUpgrade for MigrationToV2 where T: Config, OldCurrency: 'static + LockableCurrency>, @@ -76,19 +76,10 @@ where { fn on_runtime_upgrade() -> Weight { log::info!(target: LOG_TARGET, "Running storage migration..."); - let onchain_version = Pallet::::on_chain_storage_version(); - let current_version = Pallet::::current_storage_version(); - log::info!( - target: LOG_TARGET, - "onchain_version= {:?}, current_version={:?}", - onchain_version, - current_version - ); - - let on_chain_version = Pallet::::on_chain_storage_version(); // 1r - - // Pallet::::STORAGE_VERSION.get() - if on_chain_version.lt(&2) { + + let on_chain_version = Pallet::::on_chain_storage_version(); + + if on_chain_version.lt(&crate::module::STORAGE_VERSION) { log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); let mut maybe_count = 0u32; @@ -108,7 +99,7 @@ where }); // Translate the lock to a freeze - MigrationToV3::::translate_lock_to_freeze( + MigrationToV2::::translate_lock_to_freeze( account_id, total_amount.into(), ); @@ -179,7 +170,7 @@ mod test { use crate::mock::{Test, *}; use pallet_balances::{BalanceLock, Reasons}; - type MigrationOf = MigrationToV3>; + type MigrationOf = MigrationToV2>; #[test] fn migration_works() { @@ -199,7 +190,7 @@ mod test { .find(|l| l.id == RELEASE_LOCK_ID), Some(&BalanceLock { id: RELEASE_LOCK_ID, - amount: total_amount, + amount: 5u64.into(), reasons: Reasons::All }) ); From 8ffb6d6ccbf9a4d19a0dd530832da2b67a126473 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 18:20:09 -0800 Subject: [PATCH 53/75] remove module since storage data structure is not changing --- pallets/time-release/src/migration/v2.rs | 40 ++++++------------------ 1 file changed, 9 insertions(+), 31 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 43f067c788..84102a0498 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -1,11 +1,10 @@ -use crate::{types, BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet}; +use crate::{types, BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, ReleaseSchedules}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ fungible::MutateFreeze, Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, StorageVersion, }, - Blake2_128Concat, }; use parity_scale_codec::Encode; use sp_core::hexdisplay::HexDisplay; @@ -18,27 +17,6 @@ use sp_std::vec::Vec; const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; -/// Only contains V1 storage format -pub mod v1 { - use super::*; - use frame_support::{pallet_prelude::ValueQuery, storage_alias, BoundedVec}; - - pub(crate) type ReleaseScheduleOf = types::ReleaseSchedule, BalanceOf>; - - /// Release schedules of an account. - /// - /// ReleaseSchedules: `map AccountId => Vec` - /// alias to ReleaseSchedules storage - #[storage_alias] - pub(crate) type ReleaseSchedules = StorageMap< - Pallet, - Blake2_128Concat, - ::AccountId, - BoundedVec, ::MaxReleaseSchedules>, - ValueQuery, - >; -} - /// The OnRuntimeUpgrade implementation for this storage migration pub struct MigrationToV2(sp_std::marker::PhantomData<(T, OldCurrency)>); impl MigrationToV2 @@ -64,7 +42,7 @@ where HexDisplay::from(&account_id.encode()), err ); - }); // 1w + }); } } @@ -84,10 +62,10 @@ where let mut maybe_count = 0u32; // Get all the keys(accounts) from the ReleaseSchedules storage - v1::ReleaseSchedules::::iter().map(|(account_id, _)| account_id).for_each( + ReleaseSchedules::::iter().map(|(account_id, _)| account_id).for_each( |account_id| { // Get the total amount of tokens in the account's ReleaseSchedules - let total_amount = v1::ReleaseSchedules::::get(&account_id) // 1r + let total_amount = ReleaseSchedules::::get(&account_id) // 1r .iter() .map( |schedule: &types::ReleaseSchedule, BalanceOf>| { @@ -135,13 +113,13 @@ where #[cfg(feature = "try-runtime")] fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { use frame_support::storage::generator::StorageMap; - let pallet_prefix = v1::ReleaseSchedules::::module_prefix(); - let storage_prefix = v1::ReleaseSchedules::::storage_prefix(); + let pallet_prefix = ReleaseSchedules::::module_prefix(); + let storage_prefix = ReleaseSchedules::::storage_prefix(); assert_eq!(&b"TimeRelease"[..], pallet_prefix); assert_eq!(&b"ReleaseSchedules"[..], storage_prefix); log::info!(target: LOG_TARGET, "Running pre_upgrade..."); - let count = v1::ReleaseSchedules::::iter().count() as u32; + let count = ReleaseSchedules::::iter().count() as u32; log::info!(target: LOG_TARGET, "Finish pre_upgrade for {:?} records", count); Ok(count.encode()) } @@ -219,7 +197,7 @@ mod test { fn create_schedules_and_set_lock(schedules: Vec<(AccountId, u32, u32, u32, u64)>) { schedules.iter().for_each(|(who, start, period, period_count, per_period)| { - let mut bounded_schedules = v1::ReleaseSchedules::::get(who); + let mut bounded_schedules = ReleaseSchedules::::get(who); let new_schedule = types::ReleaseSchedule { start: *start, period: *period, @@ -252,7 +230,7 @@ mod test { WithdrawReasons::all(), ); - v1::ReleaseSchedules::::insert(who, bounded_schedules); + ReleaseSchedules::::insert(who, bounded_schedules); }); } } From 8043a68778027fdbbd7c01f8bfb8842560ea70fb Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 18:46:13 -0800 Subject: [PATCH 54/75] clean up --- pallets/time-release/src/migration/v2.rs | 92 ++++++++++++------------ 1 file changed, 45 insertions(+), 47 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 84102a0498..14fd8d2c82 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -57,57 +57,43 @@ where let on_chain_version = Pallet::::on_chain_storage_version(); - if on_chain_version.lt(&crate::module::STORAGE_VERSION) { - log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); - let mut maybe_count = 0u32; - - // Get all the keys(accounts) from the ReleaseSchedules storage - ReleaseSchedules::::iter().map(|(account_id, _)| account_id).for_each( - |account_id| { - // Get the total amount of tokens in the account's ReleaseSchedules - let total_amount = ReleaseSchedules::::get(&account_id) // 1r - .iter() - .map( - |schedule: &types::ReleaseSchedule, BalanceOf>| { - schedule.total_amount() - }, - ) - .fold(Zero::zero(), |acc: BalanceOf, amount| { - acc.saturating_add(amount.unwrap_or(Zero::zero())) - }); - - // Translate the lock to a freeze - MigrationToV2::::translate_lock_to_freeze( - account_id, - total_amount.into(), - ); - maybe_count += 1; - - log::info!(target: LOG_TARGET, "total_amount {:?}", total_amount); - log::info!(target: LOG_TARGET, "migrated {:?}", maybe_count); - }, - ); - - StorageVersion::new(2).put::>(); // 1 w - let reads = (maybe_count * 2 + 1) as u64; - // REVIEW: Are we doing 2 writes per account? - let writes = (maybe_count * 2 + 1) as u64; - log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); - let weight = T::DbWeight::get().reads_writes(reads, writes); - log::info!( - target: LOG_TARGET, - "Time Release Migration calculated weight = {:?}", - weight - ); - weight - } else { - // storage was already migrated. + // storage was already migrated. + if on_chain_version.ge(&crate::module::STORAGE_VERSION) { log::info!( target: LOG_TARGET, "Old Time Release Locks->Freezes migration attempted to run. Please remove" ); - T::DbWeight::get().reads(1) + return T::DbWeight::get().reads(1); } + + log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); + let mut maybe_count = 0u32; + + // Get all the keys(accounts) from the ReleaseSchedules storage + ReleaseSchedules::::iter() + .map(|(account_id, _)| account_id) + .for_each(|account_id| { + let total_amount = calculate_total_scheduled_locks_for_account::(&account_id); + + MigrationToV2::::translate_lock_to_freeze( + account_id, + total_amount.into(), + ); + + maybe_count += 1; + + log::info!(target: LOG_TARGET, "total_amount {:?}", total_amount); + log::info!(target: LOG_TARGET, "migrated {:?}", maybe_count); + }); + + StorageVersion::new(2).put::>(); + let reads = (maybe_count * 2 + 1) as u64; + // REVIEW: Are we doing 2 writes per account? + let writes = (maybe_count * 2 + 1) as u64; + log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); + let weight = T::DbWeight::get().reads_writes(reads, writes); + log::info!(target: LOG_TARGET, "Time Release Migration calculated weight = {:?}", weight); + weight } #[cfg(feature = "try-runtime")] @@ -126,7 +112,6 @@ where #[cfg(feature = "try-runtime")] fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { - use crate::ReleaseSchedules; use parity_scale_codec::Decode; let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); let on_chain_version = Pallet::::on_chain_storage_version(); @@ -139,6 +124,19 @@ where } } +fn calculate_total_scheduled_locks_for_account( + account_id: &T::AccountId, +) -> BalanceOf { + ReleaseSchedules::::get(&account_id) // 1r + .iter() + .map(|schedule: &types::ReleaseSchedule, BalanceOf>| { + schedule.total_amount() + }) + .fold(Zero::zero(), |acc: BalanceOf, amount| { + acc.saturating_add(amount.unwrap_or(Zero::zero())) + }) +} + #[cfg(test)] #[cfg(feature = "try-runtime")] mod test { From 4c61134f5693ea840ae2be80e23ed40761cd2a6c Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 13 Dec 2023 18:34:47 -0700 Subject: [PATCH 55/75] fix: address pr comments; --- pallets/capacity/src/migration/v3.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 44d6420194..a8e46f8963 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -50,14 +50,14 @@ where let mut maybe_count = 0u32; StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) - .for_each(|(staker, mut amount)| { - amount = amount.saturating_add(Pallet::::get_unlocking_total_for(&staker)); // 1r + .for_each(|(staker, amount)| { + let total_amount = amount.saturating_add(Pallet::::get_unlocking_total_for(&staker)); // 1r MigrationToV3::::translate_lock_to_freeze( - staker, - amount.into(), + staker.clone(), + total_amount.into(), ); // 1r + 2w maybe_count += 1; - log::info!(target: LOG_TARGET,"migrated {:?}, amount:{:?}", maybe_count, amount); + log::info!(target: LOG_TARGET, "migrated amount:{:?} from account 0x{:?}, count: {:?}", total_amount, HexDisplay::from(&staker.encode()), maybe_count); }); StorageVersion::new(3).put::>(); // 1 w From 8a2c5e9486861464cb7d079d175b8f9e87cc0310 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Wed, 13 Dec 2023 19:51:26 -0700 Subject: [PATCH 56/75] fix: rm comments --- pallets/time-release/src/migration/v2.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 14fd8d2c82..aa362aa33f 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -28,7 +28,6 @@ where /// Translate capacity staked locked deposit to frozen deposit pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1r + 1w - // TODO: Can we do anything if set_freeze fails? T::Currency::set_freeze( &FreezeReason::TimeReleaseVesting.into(), &account_id, From 68784a0beedd2705f5eb7f9513d2babd5c59fbf4 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 19:29:58 -0800 Subject: [PATCH 57/75] clean up --- pallets/time-release/src/migration/v2.rs | 53 +++++++++++++++++------- 1 file changed, 39 insertions(+), 14 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 14fd8d2c82..c5a1de7997 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -26,9 +26,20 @@ where OldCurrency::Balance: IsType>, { /// Translate capacity staked locked deposit to frozen deposit - pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { + pub fn translate_lock_to_freeze( + account_id: &T::AccountId, + amount: OldCurrency::Balance, + ) -> Weight { + // 1 read get Locks + // 1 read get Freeze + // 1 read get Account + // 1 write set Account + // 1 write set Locks OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1r + 1w - // TODO: Can we do anything if set_freeze fails? + + // 1 read get Freeze + // 1 read get Locks + // 1 write set Freeze // TODO: Can we do anything if set_freeze fails? T::Currency::set_freeze( &FreezeReason::TimeReleaseVesting.into(), &account_id, @@ -43,6 +54,8 @@ where err ); }); + + T::DbWeight::get().reads_writes(5, 3) } } @@ -67,7 +80,8 @@ where } log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); - let mut maybe_count = 0u32; + let mut total_weight = T::DbWeight::get().reads_writes(0, 0); + let mut total_accounts_migrated = 0u32; // Get all the keys(accounts) from the ReleaseSchedules storage ReleaseSchedules::::iter() @@ -75,25 +89,36 @@ where .for_each(|account_id| { let total_amount = calculate_total_scheduled_locks_for_account::(&account_id); - MigrationToV2::::translate_lock_to_freeze( - account_id, + let weight = MigrationToV2::::translate_lock_to_freeze( + &account_id, total_amount.into(), ); - maybe_count += 1; + total_weight = total_weight.saturating_add(weight); - log::info!(target: LOG_TARGET, "total_amount {:?}", total_amount); - log::info!(target: LOG_TARGET, "migrated {:?}", maybe_count); + total_accounts_migrated += 1; + + log::info!(target: LOG_TARGET, "A total locked amount of {:?} has been migrated from locked to frozen for account: {:?}", total_amount, account_id); }); + log::info!( + target: LOG_TARGET, + "total accounts migrated from locks to frozen {:?}", + total_accounts_migrated + ); + StorageVersion::new(2).put::>(); - let reads = (maybe_count * 2 + 1) as u64; - // REVIEW: Are we doing 2 writes per account? - let writes = (maybe_count * 2 + 1) as u64; + + total_weight.saturating_add(T::DbWeight::get().reads_writes(0, 1)); + log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); - let weight = T::DbWeight::get().reads_writes(reads, writes); - log::info!(target: LOG_TARGET, "Time Release Migration calculated weight = {:?}", weight); - weight + log::info!( + target: LOG_TARGET, + "Time Release Migration calculated weight = {:?}", + total_weight + ); + + total_weight } #[cfg(feature = "try-runtime")] From 0a4e5f6c9610c790132894d545652e378a31122f Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 19:36:13 -0800 Subject: [PATCH 58/75] weights --- pallets/time-release/src/migration/v2.rs | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index c5a1de7997..b6bfb2f596 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -76,7 +76,7 @@ where target: LOG_TARGET, "Old Time Release Locks->Freezes migration attempted to run. Please remove" ); - return T::DbWeight::get().reads(1); + return T::DbWeight::get().reads(1) } log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); @@ -87,14 +87,14 @@ where ReleaseSchedules::::iter() .map(|(account_id, _)| account_id) .for_each(|account_id| { - let total_amount = calculate_total_scheduled_locks_for_account::(&account_id); + let (total_amount, cal_fn_weight) = calculate_total_scheduled_locks_for_account::(&account_id); - let weight = MigrationToV2::::translate_lock_to_freeze( + let trans_fn_weight = MigrationToV2::::translate_lock_to_freeze( &account_id, total_amount.into(), ); - total_weight = total_weight.saturating_add(weight); + total_weight = total_weight.saturating_add(cal_fn_weight).saturating_add(trans_fn_weight); total_accounts_migrated += 1; @@ -151,15 +151,17 @@ where fn calculate_total_scheduled_locks_for_account( account_id: &T::AccountId, -) -> BalanceOf { - ReleaseSchedules::::get(&account_id) // 1r +) -> (BalanceOf, Weight) { + let total = ReleaseSchedules::::get(&account_id) // 1r .iter() .map(|schedule: &types::ReleaseSchedule, BalanceOf>| { schedule.total_amount() }) .fold(Zero::zero(), |acc: BalanceOf, amount| { acc.saturating_add(amount.unwrap_or(Zero::zero())) - }) + }); + + (total, T::DbWeight::get().reads(1)) } #[cfg(test)] From 0852f9d3446c7c05a1a8c7f1d114bce382de0f92 Mon Sep 17 00:00:00 2001 From: Enddy Dumbrique Date: Wed, 13 Dec 2023 19:49:35 -0800 Subject: [PATCH 59/75] remove comment --- pallets/time-release/src/migration/v2.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index b6bfb2f596..66189fcd3b 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -35,11 +35,11 @@ where // 1 read get Account // 1 write set Account // 1 write set Locks - OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1r + 1w + OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1 read get Freeze // 1 read get Locks - // 1 write set Freeze // TODO: Can we do anything if set_freeze fails? + // 1 write set Freeze T::Currency::set_freeze( &FreezeReason::TimeReleaseVesting.into(), &account_id, @@ -108,7 +108,6 @@ where ); StorageVersion::new(2).put::>(); - total_weight.saturating_add(T::DbWeight::get().reads_writes(0, 1)); log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); From e9ee40768a011b4f5d2feca309cb3bf43bcc11b6 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 14 Dec 2023 11:54:56 -0700 Subject: [PATCH 60/75] fix: address pr comments --- pallets/capacity/src/lib.rs | 2 ++ pallets/capacity/src/migration/v2.rs | 6 +++--- pallets/capacity/src/migration/v3.rs | 14 +++++++------- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 8e2985a076..0ba33d978b 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -109,6 +109,8 @@ pub mod pallet { Staked, } + /// the storage version for the v2 migration + pub const STORAGE_VERSION_V2: StorageVersion = StorageVersion::new(2); /// the storage version for this pallet pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(3); diff --git a/pallets/capacity/src/migration/v2.rs b/pallets/capacity/src/migration/v2.rs index 943bd6fa5b..ed9857da48 100644 --- a/pallets/capacity/src/migration/v2.rs +++ b/pallets/capacity/src/migration/v2.rs @@ -1,6 +1,6 @@ use crate::{ types::{StakingDetails, UnlockChunk}, - BalanceOf, Config, Pallet, StakingAccountLedger, StakingType, UnlockChunkList, UnstakeUnlocks, + BalanceOf, Config, Pallet, StakingAccountLedger, StakingType, UnlockChunkList, UnstakeUnlocks, STORAGE_VERSION_V2, }; use frame_support::{ pallet_prelude::{GetStorageVersion, Weight}, @@ -47,7 +47,7 @@ pub mod v1 { pub fn migrate_to_v2() -> Weight { let on_chain_version = Pallet::::on_chain_storage_version(); // 1r - if on_chain_version.lt(&2) { + if on_chain_version.lt(&STORAGE_VERSION_V2) { log::info!(target: LOG_TARGET, "🔄 StakingAccountLedger migration started"); let mut maybe_count = 0u32; StakingAccountLedger::::translate( @@ -105,7 +105,7 @@ impl OnRuntimeUpgrade for MigrateToV2 { let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); let on_chain_version = Pallet::::on_chain_storage_version(); - assert_eq!(on_chain_version, crate::pallet::STORAGE_VERSION); + assert_eq!(on_chain_version, 2); assert_eq!(pre_upgrade_count as usize, StakingAccountLedger::::iter().count()); assert_eq!(pre_upgrade_count as usize, UnstakeUnlocks::::iter().count()); diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index a8e46f8963..e474a33d35 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,4 +1,4 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger}; +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger, STORAGE_VERSION}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -45,9 +45,9 @@ where fn on_runtime_upgrade() -> Weight { let on_chain_version = Pallet::::on_chain_storage_version(); // 1r - if on_chain_version.lt(&3) { + if on_chain_version.lt(&STORAGE_VERSION) { log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration started"); - let mut maybe_count = 0u32; + let mut accounts_migrated_count = 0u32; StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) .for_each(|(staker, amount)| { @@ -56,13 +56,13 @@ where staker.clone(), total_amount.into(), ); // 1r + 2w - maybe_count += 1; - log::info!(target: LOG_TARGET, "migrated amount:{:?} from account 0x{:?}, count: {:?}", total_amount, HexDisplay::from(&staker.encode()), maybe_count); + accounts_migrated_count += 1; + log::info!(target: LOG_TARGET, "migrated amount:{:?} from account 0x{:?}, count: {:?}", total_amount, HexDisplay::from(&staker.encode()), accounts_migrated_count); }); StorageVersion::new(3).put::>(); // 1 w - let reads = (maybe_count * 2 + 1) as u64; - let writes = (maybe_count * 2 + 1) as u64; + let reads = (accounts_migrated_count * 2 + 1) as u64; + let writes = (accounts_migrated_count * 2 + 1) as u64; log::info!(target: LOG_TARGET, "🔄 migration finished"); let weight = T::DbWeight::get().reads_writes(reads, writes); log::info!(target: LOG_TARGET, "Migration calculated weight = {:?}", weight); From aba568e5052194a265dc7cad68ea17d57aa71dfa Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 14 Dec 2023 14:46:47 -0700 Subject: [PATCH 61/75] fix: update migrations correctly --- runtime/frequency/src/lib.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 59bb186866..636ad14f85 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -6,6 +6,7 @@ #[cfg(feature = "std")] include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); +use cumulus_pallet_aura_ext::pallet; #[cfg(any(not(feature = "frequency-no-relay"), feature = "frequency-lint-check"))] use cumulus_pallet_parachain_system::{RelayNumberMonotonicallyIncreases, RelaychainDataProvider}; use sp_api::impl_runtime_apis; @@ -219,7 +220,9 @@ pub type Executive = frame_executive::Executive< ( pallet_messages::migration::v2::MigrateToV2, pallet_capacity::migration::v2::MigrateToV2, + pallet_capacity::migration::v3::MigrationToV3>, pallet_schemas::migration::v3::MigrateToV3, + pallet_time_release::migration::v2::MigrationToV2>, ), >; From f0abb19a44957caffb90ceff73bfd77eb80ab806 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 14 Dec 2023 16:28:05 -0700 Subject: [PATCH 62/75] fix: add migration debugging --- pallets/capacity/src/lib.rs | 6 +-- pallets/capacity/src/migration/notes.txt | 34 ++++++++++++++ pallets/capacity/src/migration/v3.rs | 59 +++++++++++++++++------- runtime/frequency/src/lib.rs | 2 +- 4 files changed, 78 insertions(+), 23 deletions(-) create mode 100644 pallets/capacity/src/migration/notes.txt diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 0ba33d978b..d66d6a8854 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -587,12 +587,8 @@ impl Pallet { // Calculates the total amount of tokens that are currently unlocked for the given staker. pub(crate) fn get_unlocking_total_for(staker: &T::AccountId) -> BalanceOf { - let mut total_unlocking: BalanceOf = Zero::zero(); let unlocks = Self::get_unstake_unlocking_for(staker).unwrap_or_default(); - if !unlocks.is_empty() { - total_unlocking = unlock_chunks_total::(&unlocks); - } - total_unlocking + unlock_chunks_total::(&unlocks) } pub(crate) fn do_withdraw_unstaked( diff --git a/pallets/capacity/src/migration/notes.txt b/pallets/capacity/src/migration/notes.txt new file mode 100644 index 0000000000..f94da8ace3 --- /dev/null +++ b/pallets/capacity/src/migration/notes.txt @@ -0,0 +1,34 @@ +0xac4e66be328c4d235be27fcb0af8ccbe12dce375236f9ccc5516780522bc8870 +Frame System Account: +{ + nonce: 6 + consumers: 2 + providers: 1 + sufficients: 0 + data: { + free: 4,995,970,658 + reserved: 0 + frozen: 1,500,000,000 + flags: 170,141,183,460,469,231,731,687,303,715,884,105,728 + } +} + +StakingAccountLedger +capacity.stakingAccountLedger: Option + [ + [ + 14tvXXF9cHbwqMF8Q5UhEpTWG4YBmi5idQFcsSMPL2MHP4xC + ] + { + active: 1,500,000,000 + total: 1,500,000,000 + unlocking: [] + } + ] + +Balances: Locks: + { + id: netstkng + amount: 1,500,000,000 + reasons: All + } diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index e474a33d35..bd24d8e2d6 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,14 +1,17 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger, STORAGE_VERSION}; +use crate::{ + BalanceOf, BlockNumberFor, Config, Error, FreezeReason, Pallet, StakingAccountLedger, + STORAGE_VERSION, +}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ - fungible::MutateFreeze, Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, - StorageVersion, + fungible::{Inspect, MutateFreeze}, + Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, StorageVersion, }, }; use parity_scale_codec::Encode; use sp_core::hexdisplay::HexDisplay; -use sp_runtime::Saturating; +use sp_runtime::{DispatchError, Saturating}; const LOG_TARGET: &str = "runtime::capacity"; @@ -26,13 +29,28 @@ where OldCurrency::Balance: IsType>, { /// Translate capacity staked locked deposit to frozen deposit - pub fn translate_lock_to_freeze(account_id: T::AccountId, amount: OldCurrency::Balance) { + pub fn translate_lock_to_freeze( + account_id: T::AccountId, + amount: OldCurrency::Balance, + ) -> Result { + log::info!( + "Attempting to migrate {:?} locks for account 0x{:?} total_balance: {:?}, reducible_balance {:?}", + amount, + HexDisplay::from(&account_id.encode()), + ::Currency::total_balance(&account_id), + ::Currency::reducible_balance(&account_id, frame_support::traits::tokens::Preservation::Expendable, frame_support::traits::tokens::Fortitude::Polite), + ); OldCurrency::remove_lock(STAKING_ID, &account_id); // 1r + 1w - T::Currency::set_freeze(&FreezeReason::Staked.into(), &account_id, amount.into()) - .unwrap_or_else(|err| { - log::error!(target: LOG_TARGET, "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); - }); // 1w - log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); + match ::Currency::set_freeze(&FreezeReason::Staked.into(), &account_id, amount.into()) { + Ok(_) => { + log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); + Ok(T::DbWeight::get().reads_writes(2, 1)) + }, + Err(err) => { + log::error!(target: LOG_TARGET, "Failed to freeze {:?} for account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); + Err(err) + }, + } } } @@ -50,14 +68,22 @@ where let mut accounts_migrated_count = 0u32; StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) - .for_each(|(staker, amount)| { - let total_amount = amount.saturating_add(Pallet::::get_unlocking_total_for(&staker)); // 1r - MigrationToV3::::translate_lock_to_freeze( + .try_for_each(|(staker, active_amount)| { + let total_amount = active_amount.saturating_add(Pallet::::get_unlocking_total_for(&staker)); // 1r + match MigrationToV3::::translate_lock_to_freeze( staker.clone(), total_amount.into(), - ); // 1r + 2w - accounts_migrated_count += 1; - log::info!(target: LOG_TARGET, "migrated amount:{:?} from account 0x{:?}, count: {:?}", total_amount, HexDisplay::from(&staker.encode()), accounts_migrated_count); + ) { // 1r + 2w + Ok(_) => { + accounts_migrated_count += 1; + log::info!(target: LOG_TARGET, "migrated count: {:?}", accounts_migrated_count); + Ok(()) + }, + Err(err) => { + log::error!(target: LOG_TARGET, "Failed to migrate account 0x{:?}, reason: {:?}", HexDisplay::from(&staker.encode()), err); + Err(err) + } + } }); StorageVersion::new(3).put::>(); // 1 w @@ -120,7 +146,6 @@ mod test { #[test] fn migration_works() { new_test_ext().execute_with(|| { - StorageVersion::new(2).put::>(); // Create some data in the old format // Grab an account with a balance let account = 200; diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 636ad14f85..dbf809ae4a 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -222,7 +222,7 @@ pub type Executive = frame_executive::Executive< pallet_capacity::migration::v2::MigrateToV2, pallet_capacity::migration::v3::MigrationToV3>, pallet_schemas::migration::v3::MigrateToV3, - pallet_time_release::migration::v2::MigrationToV2>, + pallet_time_release::migration::v2::MigrationToV2,>, ), >; From 578319d8d00a6175870a53c0882aba3ccc7141f6 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Thu, 14 Dec 2023 18:15:53 -0700 Subject: [PATCH 63/75] fix: capacity typo in time release; lint --- pallets/capacity/src/migration/v2.rs | 3 ++- pallets/capacity/src/migration/v3.rs | 6 +++++- pallets/time-release/src/migration/v2.rs | 4 ++-- runtime/frequency/src/lib.rs | 5 ++++- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/pallets/capacity/src/migration/v2.rs b/pallets/capacity/src/migration/v2.rs index ed9857da48..92f922c913 100644 --- a/pallets/capacity/src/migration/v2.rs +++ b/pallets/capacity/src/migration/v2.rs @@ -1,6 +1,7 @@ use crate::{ types::{StakingDetails, UnlockChunk}, - BalanceOf, Config, Pallet, StakingAccountLedger, StakingType, UnlockChunkList, UnstakeUnlocks, STORAGE_VERSION_V2, + BalanceOf, Config, Pallet, StakingAccountLedger, StakingType, UnlockChunkList, UnstakeUnlocks, + STORAGE_VERSION_V2, }; use frame_support::{ pallet_prelude::{GetStorageVersion, Weight}, diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index bd24d8e2d6..209cb2595f 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -41,7 +41,11 @@ where ::Currency::reducible_balance(&account_id, frame_support::traits::tokens::Preservation::Expendable, frame_support::traits::tokens::Fortitude::Polite), ); OldCurrency::remove_lock(STAKING_ID, &account_id); // 1r + 1w - match ::Currency::set_freeze(&FreezeReason::Staked.into(), &account_id, amount.into()) { + match ::Currency::set_freeze( + &FreezeReason::Staked.into(), + &account_id, + amount.into(), + ) { Ok(_) => { log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); Ok(T::DbWeight::get().reads_writes(2, 1)) diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 66189fcd3b..5789e52ad4 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -10,7 +10,7 @@ use parity_scale_codec::Encode; use sp_core::hexdisplay::HexDisplay; use sp_runtime::{traits::Zero, Saturating}; -const LOG_TARGET: &str = "runtime::capacity"; +const LOG_TARGET: &str = "runtime::time-release"; #[cfg(feature = "try-runtime")] use sp_std::vec::Vec; @@ -25,7 +25,7 @@ where OldCurrency: 'static + LockableCurrency>, OldCurrency::Balance: IsType>, { - /// Translate capacity staked locked deposit to frozen deposit + /// Translate time release locked deposit to frozen deposit pub fn translate_lock_to_freeze( account_id: &T::AccountId, amount: OldCurrency::Balance, diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index dbf809ae4a..72cd8f12ad 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -222,7 +222,10 @@ pub type Executive = frame_executive::Executive< pallet_capacity::migration::v2::MigrateToV2, pallet_capacity::migration::v3::MigrationToV3>, pallet_schemas::migration::v3::MigrateToV3, - pallet_time_release::migration::v2::MigrationToV2,>, + pallet_time_release::migration::v2::MigrationToV2< + Runtime, + pallet_balances::Pallet, + >, ), >; From dd3ca324a0cc29c260a77d1e9c1aa0c7e6b953ee Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Fri, 15 Dec 2023 09:33:31 -0700 Subject: [PATCH 64/75] fix: lint; add upgrade_accounts.py script --- pallets/capacity/src/migration/v3.rs | 3 +- runtime/frequency/src/lib.rs | 1 - scripts/upgrade_accounts.py | 99 ++++++++++++++++++++++++++++ 3 files changed, 100 insertions(+), 3 deletions(-) create mode 100644 scripts/upgrade_accounts.py diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 209cb2595f..04b974f4c3 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,6 +1,5 @@ use crate::{ - BalanceOf, BlockNumberFor, Config, Error, FreezeReason, Pallet, StakingAccountLedger, - STORAGE_VERSION, + BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger, STORAGE_VERSION, }; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 72cd8f12ad..5fe26e50d2 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -6,7 +6,6 @@ #[cfg(feature = "std")] include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); -use cumulus_pallet_aura_ext::pallet; #[cfg(any(not(feature = "frequency-no-relay"), feature = "frequency-lint-check"))] use cumulus_pallet_parachain_system::{RelayNumberMonotonicallyIncreases, RelaychainDataProvider}; use sp_api::impl_runtime_apis; diff --git a/scripts/upgrade_accounts.py b/scripts/upgrade_accounts.py new file mode 100644 index 0000000000..1b304e33db --- /dev/null +++ b/scripts/upgrade_accounts.py @@ -0,0 +1,99 @@ +""" +This script is used to upgrade accounts to the new balance storage scheme +introduced in https://github.com/paritytech/substrate/pull/12951 + +Install the dependency https://github.com/polkascan/py-substrate-interface like: + pip install substrate-interface +Then run it: + python3 upgrade-accounts.py +""" + +import json +import os +from substrateinterface import SubstrateInterface, Keypair +from substrateinterface.exceptions import SubstrateRequestException + +chain = SubstrateInterface( + url="wss://rpc.rococo.frequency.xyz", + # Using the public endpoint can get you rate-limited. + # url="wss://kusama-rpc.polkadot.io", + # These Parity internals are not limited. + # url="wss://polkadot-try-runtime-node.parity-chains.parity.io:443" +) + +print(f"Connected to {chain.name}: {chain.chain} v{chain.version}") + +sender_uri = os.getenv('SENDER_URI', '//Alice') +sender = Keypair.create_from_uri(sender_uri) +print(f"Using sender account {sender.ss58_address}") + + +def main(): + """ + […] run though all accounts with reserved/locked funds on the system and call a + particular transaction on them + """ + accounts = [] + account_query = chain.query_map('System', 'Account', page_size=1000) + + NEW_LOGIC_FLAG = 0x80000000_00000000_00000000_00000000 + + for (i, (id, info)) in enumerate(account_query): + account = info['data'] + flags = account['flags'].decode() + + if flags & NEW_LOGIC_FLAG == 0: + accounts.append(id.value) + + if i % 5000 == 0 and i > 0: + percent = round((100 * len(accounts)) / (i + 1), 2) + print( + f"Checked {i} accounts; {len(accounts)} ({percent} %) are eligible for upgrade") + + print(f"Found {len(accounts)} eligible accounts in total") + + out_file = f"upgradable-accs-{chain.chain}.json" + with open(out_file, 'w') as f: + json.dump(accounts, f) + print(f"Wrote accounts to '{out_file}'") + + # How many accounts each call should upgrade. + accs_per_call = 1024 + weight_second = 1e12 + decimals = chain.token_decimals or 0 + + for (i, chunk) in enumerate(chunks(accounts, accs_per_call)): + call = chain.compose_call( + call_module='Balances', + call_function='upgrade_accounts', + call_params={ + 'who': chunk, + } + ) + extrinsic = chain.create_signed_extrinsic(call=call, keypair=sender) + print(f"Extrinsic {i + 1}: upgrading {len(chunk)} accounts") + + try: + receipt = chain.submit_extrinsic( + extrinsic, wait_for_inclusion=True) + print(f"Extrinsic included in block {receipt.block_hash}: " + f"consumed {receipt.weight['ref_time'] / weight_second} seconds of weight and " + f"paid {(receipt.total_fee_amount or 0) / 10**decimals} {chain.token_symbol}") + if len(receipt.triggered_events) < len(chunk): + print( + f"!! Emitted fewer events than expected: {len(receipt.triggered_events)} < {len(chunk)}") + except SubstrateRequestException as e: + print(f"Failed to submit extrinsic: {e}") + raise e + + +def chunks(list, n): + """ + Lazily split 'list' into 'n'-sized chunks. + """ + for i in range(0, len(list), n): + yield list[i:i + n] + + +if __name__ == "__main__": + main() From ff58ee4d389aefd04c7143caf4dfc5c34f99d709 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Fri, 15 Dec 2023 09:37:53 -0700 Subject: [PATCH 65/75] fix: remove debugging notes file --- pallets/capacity/src/migration/notes.txt | 34 ------------------------ 1 file changed, 34 deletions(-) delete mode 100644 pallets/capacity/src/migration/notes.txt diff --git a/pallets/capacity/src/migration/notes.txt b/pallets/capacity/src/migration/notes.txt deleted file mode 100644 index f94da8ace3..0000000000 --- a/pallets/capacity/src/migration/notes.txt +++ /dev/null @@ -1,34 +0,0 @@ -0xac4e66be328c4d235be27fcb0af8ccbe12dce375236f9ccc5516780522bc8870 -Frame System Account: -{ - nonce: 6 - consumers: 2 - providers: 1 - sufficients: 0 - data: { - free: 4,995,970,658 - reserved: 0 - frozen: 1,500,000,000 - flags: 170,141,183,460,469,231,731,687,303,715,884,105,728 - } -} - -StakingAccountLedger -capacity.stakingAccountLedger: Option - [ - [ - 14tvXXF9cHbwqMF8Q5UhEpTWG4YBmi5idQFcsSMPL2MHP4xC - ] - { - active: 1,500,000,000 - total: 1,500,000,000 - unlocking: [] - } - ] - -Balances: Locks: - { - id: netstkng - amount: 1,500,000,000 - reasons: All - } From e12d616549983988381641a0c58c79fe6fd57f4c Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Fri, 15 Dec 2023 15:06:02 -0700 Subject: [PATCH 66/75] fix: refactor translate_lock_to_freeze to remove debug error handling --- pallets/capacity/src/lib.rs | 4 +- pallets/capacity/src/migration/v3.rs | 111 +++++++++++------------ pallets/time-release/src/migration/v2.rs | 2 +- 3 files changed, 55 insertions(+), 62 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index d66d6a8854..0b62ebd7bb 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -586,9 +586,9 @@ impl Pallet { } // Calculates the total amount of tokens that are currently unlocked for the given staker. - pub(crate) fn get_unlocking_total_for(staker: &T::AccountId) -> BalanceOf { + pub(crate) fn get_unlocking_total_for(staker: &T::AccountId) -> (BalanceOf, Weight) { let unlocks = Self::get_unstake_unlocking_for(staker).unwrap_or_default(); - unlock_chunks_total::(&unlocks) + (unlock_chunks_total::(&unlocks), T::DbWeight::get().reads(1)) } pub(crate) fn do_withdraw_unstaked( diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 04b974f4c3..7044bbee7c 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,16 +1,14 @@ -use crate::{ - BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger, STORAGE_VERSION, -}; +use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger}; use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ - fungible::{Inspect, MutateFreeze}, - Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, StorageVersion, + fungible::MutateFreeze, Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, + StorageVersion, }, }; use parity_scale_codec::Encode; use sp_core::hexdisplay::HexDisplay; -use sp_runtime::{DispatchError, Saturating}; +use sp_runtime::Saturating; const LOG_TARGET: &str = "runtime::capacity"; @@ -31,29 +29,21 @@ where pub fn translate_lock_to_freeze( account_id: T::AccountId, amount: OldCurrency::Balance, - ) -> Result { - log::info!( - "Attempting to migrate {:?} locks for account 0x{:?} total_balance: {:?}, reducible_balance {:?}", - amount, - HexDisplay::from(&account_id.encode()), - ::Currency::total_balance(&account_id), - ::Currency::reducible_balance(&account_id, frame_support::traits::tokens::Preservation::Expendable, frame_support::traits::tokens::Fortitude::Polite), - ); - OldCurrency::remove_lock(STAKING_ID, &account_id); // 1r + 1w - match ::Currency::set_freeze( + ) -> Weight { + // TODO: Confirm reads and writes + OldCurrency::remove_lock(STAKING_ID, &account_id); + + ::Currency::set_freeze( &FreezeReason::Staked.into(), &account_id, amount.into(), - ) { - Ok(_) => { - log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); - Ok(T::DbWeight::get().reads_writes(2, 1)) - }, - Err(err) => { - log::error!(target: LOG_TARGET, "Failed to freeze {:?} for account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); - Err(err) - }, - } + ) + .unwrap_or_else(|err| { + log::error!(target: LOG_TARGET, "Failed to freeze {:?} for account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); + }); + + log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); + T::DbWeight::get().reads_writes(5, 3) } } @@ -66,41 +56,44 @@ where fn on_runtime_upgrade() -> Weight { let on_chain_version = Pallet::::on_chain_storage_version(); // 1r - if on_chain_version.lt(&STORAGE_VERSION) { - log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration started"); - let mut accounts_migrated_count = 0u32; - StakingAccountLedger::::iter() - .map(|(account_id, staking_details)| (account_id, staking_details.active)) - .try_for_each(|(staker, active_amount)| { - let total_amount = active_amount.saturating_add(Pallet::::get_unlocking_total_for(&staker)); // 1r - match MigrationToV3::::translate_lock_to_freeze( - staker.clone(), - total_amount.into(), - ) { // 1r + 2w - Ok(_) => { - accounts_migrated_count += 1; - log::info!(target: LOG_TARGET, "migrated count: {:?}", accounts_migrated_count); - Ok(()) - }, - Err(err) => { - log::error!(target: LOG_TARGET, "Failed to migrate account 0x{:?}, reason: {:?}", HexDisplay::from(&staker.encode()), err); - Err(err) - } - } - }); - - StorageVersion::new(3).put::>(); // 1 w - let reads = (accounts_migrated_count * 2 + 1) as u64; - let writes = (accounts_migrated_count * 2 + 1) as u64; - log::info!(target: LOG_TARGET, "🔄 migration finished"); - let weight = T::DbWeight::get().reads_writes(reads, writes); - log::info!(target: LOG_TARGET, "Migration calculated weight = {:?}", weight); - weight - } else { - // storage was already migrated. + if on_chain_version.ge(&crate::pallet::STORAGE_VERSION) { log::info!(target: LOG_TARGET, "Old Capacity Locks->Freezes migration attempted to run. Please remove"); - T::DbWeight::get().reads(1) + return T::DbWeight::get().reads(1) } + + log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration started"); + // The migration started with 1r to get the STORAGE_VERSION + let mut total_weight = T::DbWeight::get().reads_writes(1, 0); + let mut total_accounts_migrated = 0u32; + + // Get all the keys(accounts) from the StakingAccountLedger + StakingAccountLedger::::iter() + .map(|(account_id, staking_details)| (account_id, staking_details.active)) + .for_each(|(account_id, active_amount)| { + let (total_unlocking, cal_fn_weight) = + Pallet::::get_unlocking_total_for(&account_id); + let total_amount = active_amount.saturating_add(total_unlocking); + + let trans_fn_weight = MigrationToV3::::translate_lock_to_freeze( + account_id.clone(), + total_amount.into(), + ); + + total_weight = + total_weight.saturating_add(cal_fn_weight).saturating_add(trans_fn_weight); + + total_accounts_migrated += 1; + }); + + log::info!(target: LOG_TARGET, "total accounts migrated from locks to freezes: {:?}", total_accounts_migrated); + + StorageVersion::new(3).put::>(); // 1 w + total_weight.saturating_add(T::DbWeight::get().reads_writes(0, 1)); + + log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration finished"); + log::info!(target: LOG_TARGET, "Capacity Migration calculated weight = {:?}", total_weight); + + total_weight } #[cfg(feature = "try-runtime")] diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 5789e52ad4..213cbc598e 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -98,7 +98,7 @@ where total_accounts_migrated += 1; - log::info!(target: LOG_TARGET, "A total locked amount of {:?} has been migrated from locked to frozen for account: {:?}", total_amount, account_id); + log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), total_amount); }); log::info!( From 38227925b71b846d2bf7f741ebc8c8ac0763a5fe Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Sat, 16 Dec 2023 10:13:33 -0700 Subject: [PATCH 67/75] fix: update translate_lock_to_freeze weights and comments --- pallets/capacity/src/migration/v3.rs | 18 ++++++++++++++++-- pallets/time-release/src/migration/v2.rs | 9 ++++++--- 2 files changed, 22 insertions(+), 5 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 7044bbee7c..18ad5bf5e1 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -30,9 +30,23 @@ where account_id: T::AccountId, amount: OldCurrency::Balance, ) -> Weight { - // TODO: Confirm reads and writes + // 1 read get Locks: remove_lock: set locks + // 1 read get Freezes + // 1 read get Account + // 1 write set Account: update_locks->try_mutate_account->ensure_upgraded: if account is *not* already upgraded. + // We could avoid this write by calling the upgrade script before running the migration, + // which would ensure that all accounts are upgraded. + // 1 write set Account: update_locks->try_mutate_account: set account data + // 1 read get Locks: update_locks: set existed with `contains_key` + // 1 write set Locks: update_locks->Locks::remove: remove existed OldCurrency::remove_lock(STAKING_ID, &account_id); + // 1 read get Freezes: set_freeze: set locks + // 1 read get Locks: update_freezes: Locks::get().iter() + // 1 write set Account: update_freezes->mutate_account->try_mutate_account->ensure_upgraded: if account is *not* already upgraded. + // 1 write set Account: update_freezes->mutate_account->try_mutate_account: set account data + // 1 write set Freezes: update_freezes: Freezes::insert + ::Currency::set_freeze( &FreezeReason::Staked.into(), &account_id, @@ -43,7 +57,7 @@ where }); log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); - T::DbWeight::get().reads_writes(5, 3) + T::DbWeight::get().reads_writes(6, 4) } } diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs index 213cbc598e..0829a14845 100644 --- a/pallets/time-release/src/migration/v2.rs +++ b/pallets/time-release/src/migration/v2.rs @@ -31,14 +31,16 @@ where amount: OldCurrency::Balance, ) -> Weight { // 1 read get Locks - // 1 read get Freeze + // 1 read get Freezes // 1 read get Account // 1 write set Account + // 1 read get Locks: update_locks: set existed with `contains_key` // 1 write set Locks OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); // 1 read get Freeze // 1 read get Locks + // 1 write set Account: update_freezes->mutate_account->try_mutate_account: set account data // 1 write set Freeze T::Currency::set_freeze( &FreezeReason::TimeReleaseVesting.into(), @@ -55,7 +57,7 @@ where ); }); - T::DbWeight::get().reads_writes(5, 3) + T::DbWeight::get().reads_writes(6, 4) } } @@ -80,7 +82,8 @@ where } log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); - let mut total_weight = T::DbWeight::get().reads_writes(0, 0); + // The migration started with 1r to get the on_chain_storage_version + let mut total_weight = T::DbWeight::get().reads_writes(1, 0); let mut total_accounts_migrated = 0u32; // Get all the keys(accounts) from the ReleaseSchedules storage From 5a0fef5686329ea1c7658e1e9b9d0a8b94b93c03 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 08:09:41 -0700 Subject: [PATCH 68/75] fix: rename symbol for readability --- pallets/capacity/src/migration/v3.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 18ad5bf5e1..65f0d6cdb1 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -159,22 +159,22 @@ mod test { // Create some data in the old format // Grab an account with a balance let account = 200; - let amount = 50; + let locked_amount = 50; pallet_balances::Pallet::::set_lock( STAKING_ID, &account, - amount, + locked_amount, WithdrawReasons::all(), ); // Confirm lock exists assert_eq!( pallet_balances::Pallet::::locks(&account).get(0), - Some(&BalanceLock { id: STAKING_ID, amount: 50u64, reasons: Reasons::All }) + Some(&BalanceLock { id: STAKING_ID, amount: locked_amount, reasons: Reasons::All }) ); let test_record = - StakingDetails:: { active: amount, staking_type: MaximumCapacity }; + StakingDetails:: { active: locked_amount, staking_type: MaximumCapacity }; StakingAccountLedger::::insert(account, test_record); assert_eq!(StakingAccountLedger::::iter().count(), 1); @@ -187,7 +187,7 @@ mod test { assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); assert_eq!( ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), - 50u64 + locked_amount ); }) } From 1a6e122d60035f77466a31dc5db56f5dd80e119f Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 08:25:30 -0700 Subject: [PATCH 69/75] Run benchmarks [run-benchmarks capacity,time-release] From 59be141a830ae0b72ef53bec3c70f1ef7191644e Mon Sep 17 00:00:00 2001 From: "Frequency CI [bot]" Date: Mon, 18 Dec 2023 15:54:57 +0000 Subject: [PATCH 70/75] Update weights for PR #1779 --- pallets/capacity/src/weights.rs | 68 ++++++++++++++++----------------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/pallets/capacity/src/weights.rs b/pallets/capacity/src/weights.rs index c5d7ed84e5..fe1fc49770 100644 --- a/pallets/capacity/src/weights.rs +++ b/pallets/capacity/src/weights.rs @@ -18,9 +18,9 @@ //! Autogenerated weights for pallet_capacity //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-11-30, STEPS: `20`, REPEAT: `10`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-12-18, STEPS: `20`, REPEAT: `10`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `benchmark-runner-44wtw-5slfv`, CPU: `Intel(R) Xeon(R) Platinum 8375C CPU @ 2.90GHz` +//! HOSTNAME: `benchmark-runner-44wtw-wvwrf`, CPU: `Intel(R) Xeon(R) Platinum 8375C CPU @ 2.90GHz` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("frequency-bench"), DB CACHE: 1024 // Executed Command: @@ -69,16 +69,16 @@ impl WeightInfo for SubstrateWeight { /// Proof: `Capacity::CapacityLedger` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`) /// Storage: `Capacity::UnstakeUnlocks` (r:1 w:0) /// Proof: `Capacity::UnstakeUnlocks` (`max_values`: None, `max_size`: Some(121), added: 2596, mode: `MaxEncodedLen`) - /// Storage: `Balances::Locks` (r:1 w:1) + /// Storage: `Balances::Freezes` (r:1 w:1) + /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(85), added: 2560, mode: `MaxEncodedLen`) + /// Storage: `Balances::Locks` (r:1 w:0) /// Proof: `Balances::Locks` (`max_values`: None, `max_size`: Some(1299), added: 3774, mode: `MaxEncodedLen`) - /// Storage: `Balances::Freezes` (r:1 w:0) - /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) fn stake() -> Weight { // Proof Size summary in bytes: // Measured: `223` // Estimated: `6249` - // Minimum execution time: 44_240_000 picoseconds. - Weight::from_parts(45_555_000, 6249) + // Minimum execution time: 43_760_000 picoseconds. + Weight::from_parts(45_156_000, 6249) .saturating_add(T::DbWeight::get().reads(7_u64)) .saturating_add(T::DbWeight::get().writes(4_u64)) } @@ -86,16 +86,16 @@ impl WeightInfo for SubstrateWeight { /// Proof: `Capacity::UnstakeUnlocks` (`max_values`: None, `max_size`: Some(121), added: 2596, mode: `MaxEncodedLen`) /// Storage: `Capacity::StakingAccountLedger` (r:1 w:0) /// Proof: `Capacity::StakingAccountLedger` (`max_values`: None, `max_size`: Some(57), added: 2532, mode: `MaxEncodedLen`) - /// Storage: `Balances::Locks` (r:1 w:1) + /// Storage: `Balances::Freezes` (r:1 w:1) + /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(85), added: 2560, mode: `MaxEncodedLen`) + /// Storage: `Balances::Locks` (r:1 w:0) /// Proof: `Balances::Locks` (`max_values`: None, `max_size`: Some(1299), added: 3774, mode: `MaxEncodedLen`) - /// Storage: `Balances::Freezes` (r:1 w:0) - /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) fn withdraw_unstaked() -> Weight { // Proof Size summary in bytes: // Measured: `285` // Estimated: `6249` - // Minimum execution time: 28_294_000 picoseconds. - Weight::from_parts(29_114_000, 6249) + // Minimum execution time: 29_609_000 picoseconds. + Weight::from_parts(30_663_000, 6249) .saturating_add(T::DbWeight::get().reads(4_u64)) .saturating_add(T::DbWeight::get().writes(2_u64)) } @@ -107,8 +107,8 @@ impl WeightInfo for SubstrateWeight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `2974` - // Minimum execution time: 3_912_000 picoseconds. - Weight::from_parts(4_081_000, 2974) + // Minimum execution time: 4_520_000 picoseconds. + Weight::from_parts(4_587_000, 2974) .saturating_add(T::DbWeight::get().reads(2_u64)) .saturating_add(T::DbWeight::get().writes(1_u64)) } @@ -124,8 +124,8 @@ impl WeightInfo for SubstrateWeight { // Proof Size summary in bytes: // Measured: `271` // Estimated: `5071` - // Minimum execution time: 25_110_000 picoseconds. - Weight::from_parts(25_886_000, 5071) + // Minimum execution time: 27_378_000 picoseconds. + Weight::from_parts(28_128_000, 5071) .saturating_add(T::DbWeight::get().reads(4_u64)) .saturating_add(T::DbWeight::get().writes(4_u64)) } @@ -135,8 +135,8 @@ impl WeightInfo for SubstrateWeight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 6_335_000 picoseconds. - Weight::from_parts(6_662_000, 0) + // Minimum execution time: 6_566_000 picoseconds. + Weight::from_parts(6_931_000, 0) .saturating_add(T::DbWeight::get().writes(1_u64)) } } @@ -153,16 +153,16 @@ impl WeightInfo for () { /// Proof: `Capacity::CapacityLedger` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`) /// Storage: `Capacity::UnstakeUnlocks` (r:1 w:0) /// Proof: `Capacity::UnstakeUnlocks` (`max_values`: None, `max_size`: Some(121), added: 2596, mode: `MaxEncodedLen`) - /// Storage: `Balances::Locks` (r:1 w:1) + /// Storage: `Balances::Freezes` (r:1 w:1) + /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(85), added: 2560, mode: `MaxEncodedLen`) + /// Storage: `Balances::Locks` (r:1 w:0) /// Proof: `Balances::Locks` (`max_values`: None, `max_size`: Some(1299), added: 3774, mode: `MaxEncodedLen`) - /// Storage: `Balances::Freezes` (r:1 w:0) - /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) fn stake() -> Weight { // Proof Size summary in bytes: // Measured: `223` // Estimated: `6249` - // Minimum execution time: 44_240_000 picoseconds. - Weight::from_parts(45_555_000, 6249) + // Minimum execution time: 43_760_000 picoseconds. + Weight::from_parts(45_156_000, 6249) .saturating_add(RocksDbWeight::get().reads(7_u64)) .saturating_add(RocksDbWeight::get().writes(4_u64)) } @@ -170,16 +170,16 @@ impl WeightInfo for () { /// Proof: `Capacity::UnstakeUnlocks` (`max_values`: None, `max_size`: Some(121), added: 2596, mode: `MaxEncodedLen`) /// Storage: `Capacity::StakingAccountLedger` (r:1 w:0) /// Proof: `Capacity::StakingAccountLedger` (`max_values`: None, `max_size`: Some(57), added: 2532, mode: `MaxEncodedLen`) - /// Storage: `Balances::Locks` (r:1 w:1) + /// Storage: `Balances::Freezes` (r:1 w:1) + /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(85), added: 2560, mode: `MaxEncodedLen`) + /// Storage: `Balances::Locks` (r:1 w:0) /// Proof: `Balances::Locks` (`max_values`: None, `max_size`: Some(1299), added: 3774, mode: `MaxEncodedLen`) - /// Storage: `Balances::Freezes` (r:1 w:0) - /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) fn withdraw_unstaked() -> Weight { // Proof Size summary in bytes: // Measured: `285` // Estimated: `6249` - // Minimum execution time: 28_294_000 picoseconds. - Weight::from_parts(29_114_000, 6249) + // Minimum execution time: 29_609_000 picoseconds. + Weight::from_parts(30_663_000, 6249) .saturating_add(RocksDbWeight::get().reads(4_u64)) .saturating_add(RocksDbWeight::get().writes(2_u64)) } @@ -191,8 +191,8 @@ impl WeightInfo for () { // Proof Size summary in bytes: // Measured: `0` // Estimated: `2974` - // Minimum execution time: 3_912_000 picoseconds. - Weight::from_parts(4_081_000, 2974) + // Minimum execution time: 4_520_000 picoseconds. + Weight::from_parts(4_587_000, 2974) .saturating_add(RocksDbWeight::get().reads(2_u64)) .saturating_add(RocksDbWeight::get().writes(1_u64)) } @@ -208,8 +208,8 @@ impl WeightInfo for () { // Proof Size summary in bytes: // Measured: `271` // Estimated: `5071` - // Minimum execution time: 25_110_000 picoseconds. - Weight::from_parts(25_886_000, 5071) + // Minimum execution time: 27_378_000 picoseconds. + Weight::from_parts(28_128_000, 5071) .saturating_add(RocksDbWeight::get().reads(4_u64)) .saturating_add(RocksDbWeight::get().writes(4_u64)) } @@ -219,8 +219,8 @@ impl WeightInfo for () { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 6_335_000 picoseconds. - Weight::from_parts(6_662_000, 0) + // Minimum execution time: 6_566_000 picoseconds. + Weight::from_parts(6_931_000, 0) .saturating_add(RocksDbWeight::get().writes(1_u64)) } } From d659eff89fc3129000f4de1e564a37d68c4119f6 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 14:48:21 -0700 Subject: [PATCH 71/75] fix: split PR into capacity and time-release portions; cargo update --- Cargo.lock | 77 ++++--- pallets/time-release/Cargo.toml | 3 +- pallets/time-release/src/benchmarking.rs | 10 +- pallets/time-release/src/lib.rs | 94 +++----- pallets/time-release/src/migration/mod.rs | 2 - pallets/time-release/src/migration/v2.rs | 263 ---------------------- pallets/time-release/src/mock.rs | 16 +- pallets/time-release/src/tests.rs | 176 +++------------ runtime/frequency/src/lib.rs | 8 +- 9 files changed, 119 insertions(+), 530 deletions(-) delete mode 100644 pallets/time-release/src/migration/mod.rs delete mode 100644 pallets/time-release/src/migration/v2.rs diff --git a/Cargo.lock b/Cargo.lock index 18e956e877..a25b3e2444 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -98,7 +98,7 @@ dependencies = [ "getrandom 0.2.11", "once_cell", "version_check", - "zerocopy 0.7.30", + "zerocopy 0.7.31", ] [[package]] @@ -224,7 +224,7 @@ dependencies = [ "thiserror", "typed-builder", "uuid", - "zerocopy 0.6.5", + "zerocopy 0.6.6", ] [[package]] @@ -681,9 +681,9 @@ dependencies = [ [[package]] name = "async-task" -version = "4.5.0" +version = "4.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4eb2cdb97421e01129ccb49169d8279ed21e829929144f4a22a6e54ac549ca1" +checksum = "e1d90cd0b264dfdd8eb5bad0a2c217c1f88fa96a8573f40e7b12de23fb468f46" [[package]] name = "async-trait" @@ -1458,9 +1458,9 @@ dependencies = [ [[package]] name = "const-oid" -version = "0.9.5" +version = "0.9.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28c122c3980598d243d63d9a704629a2d748d101f278052ff068be5a4423ab6f" +checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" [[package]] name = "const-random" @@ -2305,9 +2305,9 @@ dependencies = [ [[package]] name = "cxx" -version = "1.0.110" +version = "1.0.111" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7129e341034ecb940c9072817cd9007974ea696844fc4dd582dc1653a7fbe2e8" +checksum = "e9fc0c733f71e58dedf4f034cd2a266f80b94cc9ed512729e1798651b68c2cba" dependencies = [ "cc", "cxxbridge-flags", @@ -2317,9 +2317,9 @@ dependencies = [ [[package]] name = "cxx-build" -version = "1.0.110" +version = "1.0.111" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2a24f3f5f8eed71936f21e570436f024f5c2e25628f7496aa7ccd03b90109d5" +checksum = "51bc81d2664db24cf1d35405f66e18a85cffd4d49ab930c71a5c6342a410f38c" dependencies = [ "cc", "codespan-reporting", @@ -2332,15 +2332,15 @@ dependencies = [ [[package]] name = "cxxbridge-flags" -version = "1.0.110" +version = "1.0.111" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06fdd177fc61050d63f67f5bd6351fac6ab5526694ea8e359cd9cd3b75857f44" +checksum = "8511afbe34ea242697784da5cb2c5d4a0afb224ca8b136bdf93bfe180cbe5884" [[package]] name = "cxxbridge-macro" -version = "1.0.110" +version = "1.0.111" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "587663dd5fb3d10932c8aecfe7c844db1bcf0aee93eeab08fac13dc1212c2e7f" +checksum = "5c6888cd161769d65134846d4d4981d5a6654307cc46ec83fb917e530aea5f84" dependencies = [ "proc-macro2", "quote", @@ -4081,11 +4081,11 @@ dependencies = [ [[package]] name = "home" -version = "0.5.5" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" +checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -4147,9 +4147,9 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "0.14.27" +version = "0.14.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" +checksum = "bf96e135eb83a2a8ddf766e426a841d8ddd7449d5f00d34ea02b41d2f19eef80" dependencies = [ "bytes", "futures-channel", @@ -4162,7 +4162,7 @@ dependencies = [ "httpdate", "itoa", "pin-project-lite 0.2.13", - "socket2 0.4.10", + "socket2 0.5.5", "tokio", "tower-service", "tracing", @@ -7221,7 +7221,6 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", - "log", "pallet-balances", "parity-scale-codec", "scale-info", @@ -9523,18 +9522,18 @@ dependencies = [ [[package]] name = "ref-cast" -version = "1.0.20" +version = "1.0.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acde58d073e9c79da00f2b5b84eed919c8326832648a5b109b3fce1bb1175280" +checksum = "53313ec9f12686aeeffb43462c3ac77aa25f590a5f630eb2cde0de59417b29c7" dependencies = [ "ref-cast-impl", ] [[package]] name = "ref-cast-impl" -version = "1.0.20" +version = "1.0.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f7473c2cfcf90008193dd0e3e16599455cb601a9fce322b5bb55de799664925" +checksum = "2566c4bf6845f2c2e83b27043c3f5dfcd5ba8f2937d6c00dc009bfb51a079dc4" dependencies = [ "proc-macro2", "quote", @@ -13034,9 +13033,9 @@ checksum = "3369f5ac52d5eb6ab48c6b4ffdc8efbcad6b89c765749064ba298f2c68a16a76" [[package]] name = "thiserror" -version = "1.0.50" +version = "1.0.51" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2" +checksum = "f11c217e1416d6f036b870f14e0413d480dbf28edbee1f877abaf0206af43bb7" dependencies = [ "thiserror-impl", ] @@ -13063,9 +13062,9 @@ dependencies = [ [[package]] name = "thiserror-impl" -version = "1.0.50" +version = "1.0.51" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" +checksum = "01742297787513b79cf8e29d1056ede1313e2420b7b3b15d0a768b4921f549df" dependencies = [ "proc-macro2", "quote", @@ -14728,28 +14727,28 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96f8f25c15a0edc9b07eb66e7e6e97d124c0505435c382fde1ab7ceb188aa956" +checksum = "854e949ac82d619ee9a14c66a1b674ac730422372ccb759ce0c39cabcf2bf8e6" dependencies = [ "byteorder", - "zerocopy-derive 0.6.5", + "zerocopy-derive 0.6.6", ] [[package]] name = "zerocopy" -version = "0.7.30" +version = "0.7.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "306dca4455518f1f31635ec308b6b3e4eb1b11758cefafc782827d0aa7acb5c7" +checksum = "1c4061bedbb353041c12f413700357bec76df2c7e2ca8e4df8bac24c6bf68e3d" dependencies = [ - "zerocopy-derive 0.7.30", + "zerocopy-derive 0.7.31", ] [[package]] name = "zerocopy-derive" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "855e0f6af9cd72b87d8a6c586f3cb583f5cdcc62c2c80869d8cd7e96fdf7ee20" +checksum = "125139de3f6b9d625c39e2efdd73d41bdac468ccd556556440e322be0e1bbd91" dependencies = [ "proc-macro2", "quote", @@ -14758,9 +14757,9 @@ dependencies = [ [[package]] name = "zerocopy-derive" -version = "0.7.30" +version = "0.7.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be912bf68235a88fbefd1b73415cb218405958d1655b2ece9035a19920bdf6ba" +checksum = "b3c129550b3e6de3fd0ba67ba5c81818f9805e58b8d7fee80a3a59d2c9fc601a" dependencies = [ "proc-macro2", "quote", diff --git a/pallets/time-release/Cargo.toml b/pallets/time-release/Cargo.toml index 09a6d80b7a..7e209709d8 100644 --- a/pallets/time-release/Cargo.toml +++ b/pallets/time-release/Cargo.toml @@ -23,12 +23,11 @@ sp-io = { workspace = true } sp-runtime = { workspace = true } sp-std = { workspace = true } frame-benchmarking = { workspace = true, optional = true } -sp-core = { workspace = true } -log = { workspace = true, default-features = false } [dev-dependencies] chrono = { workspace = true } pallet-balances = { workspace = true } +sp-core = { workspace = true } common-primitives = { default-features = false, path = "../../common/primitives" } [features] diff --git a/pallets/time-release/src/benchmarking.rs b/pallets/time-release/src/benchmarking.rs index 7dafbc1a44..685d0bcb37 100644 --- a/pallets/time-release/src/benchmarking.rs +++ b/pallets/time-release/src/benchmarking.rs @@ -4,6 +4,7 @@ use super::*; use crate::Pallet as TimeReleasePallet; use frame_benchmarking::{account, benchmarks, whitelist_account, whitelisted_caller}; +use frame_support::traits::{Currency, Imbalance}; use frame_system::{pallet_prelude::BlockNumberFor, RawOrigin}; use sp_runtime::{traits::TrailingZeroInput, SaturatedConversion}; use sp_std::prelude::*; @@ -16,8 +17,9 @@ pub type Schedule = ReleaseSchedule, BalanceOf>; const SEED: u32 = 0; fn set_balance(who: &T::AccountId, balance: BalanceOf) { - let actual_deposit = T::Currency::mint_into(&who, balance.saturated_into()); - assert_eq!(balance, actual_deposit.unwrap()); + let deposit_result = T::Currency::deposit_creating(who, balance.saturated_into()); + let actual_deposit = deposit_result.peek(); + assert_eq!(balance, actual_deposit); } fn lookup_of_account( @@ -74,7 +76,7 @@ benchmarks! { }: _(RawOrigin::Signed(to.clone())) verify { assert_eq!( - T::Currency::balance(&to), + T::Currency::free_balance(&to), schedule.total_amount().unwrap() * BalanceOf::::from(i) , ); } @@ -101,7 +103,7 @@ benchmarks! { }: _(RawOrigin::Root, to_lookup, schedules) verify { assert_eq!( - T::Currency::balance(&to), + T::Currency::free_balance(&to), schedule.total_amount().unwrap() * BalanceOf::::from(i) ); } diff --git a/pallets/time-release/src/lib.rs b/pallets/time-release/src/lib.rs index 140865595d..e3048bdcf3 100644 --- a/pallets/time-release/src/lib.rs +++ b/pallets/time-release/src/lib.rs @@ -37,22 +37,18 @@ )] use frame_support::{ - dispatch::DispatchResult, ensure, pallet_prelude::*, traits::{ - tokens::{ - fungible::{Inspect as InspectFungible, Mutate, MutateFreeze}, - Balance, Preservation, - }, - BuildGenesisConfig, EnsureOrigin, Get, + BuildGenesisConfig, Currency, EnsureOrigin, ExistenceRequirement, Get, LockIdentifier, + LockableCurrency, WithdrawReasons, }, BoundedVec, }; use frame_system::{ensure_root, ensure_signed, pallet_prelude::*}; use sp_runtime::{ traits::{BlockNumberProvider, CheckedAdd, StaticLookup, Zero}, - ArithmeticError, + ArithmeticError, DispatchResult, }; use sp_std::vec::Vec; @@ -61,9 +57,6 @@ mod mock; #[cfg(test)] mod tests; -/// storage migrations -pub mod migration; - mod types; pub use types::*; @@ -75,13 +68,15 @@ mod benchmarking; pub use module::*; +/// The lock identifier for timed released transfers. +pub const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; + #[frame_support::pallet] pub mod module { use super::*; - pub(crate) type BalanceOf = <::Currency as InspectFungible< - ::AccountId, - >>::Balance; + pub(crate) type BalanceOf = + <::Currency as Currency<::AccountId>>::Balance; pub(crate) type ReleaseScheduleOf = ReleaseSchedule, BalanceOf>; /// Scheduled item used for configuring genesis. @@ -93,32 +88,13 @@ pub mod module { BalanceOf, ); - /// A reason for freezing funds. - /// Creates a freeze reason for this pallet that is aggregated by `construct_runtime`. - #[pallet::composite_enum] - pub enum FreezeReason { - /// Funds are currently locked and are not yet liquid. - TimeReleaseVesting, - } - - /// the storage version for this pallet - pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(2); - #[pallet::config] pub trait Config: frame_system::Config { /// The overarching event type. type RuntimeEvent: From> + IsType<::RuntimeEvent>; - /// The overarching freeze reason. - type RuntimeFreezeReason: From; - - /// We need MaybeSerializeDeserialize because of the genesis config. - type Balance: Balance + MaybeSerializeDeserialize; - /// The currency trait used to set a lock on a balance. - type Currency: MutateFreeze - + InspectFungible - + Mutate; + type Currency: LockableCurrency>; #[pallet::constant] /// The minimum amount transferred to call `transfer`. @@ -231,16 +207,16 @@ pub mod module { .expect("Invalid release schedule"); assert!( - T::Currency::balance(who) >= total_amount, + T::Currency::free_balance(who) >= total_amount, "Account do not have enough balance" ); - T::Currency::set_freeze( - &FreezeReason::TimeReleaseVesting.into(), + T::Currency::set_lock( + RELEASE_LOCK_ID, who, total_amount, - ) - .expect("Failed to set freeze"); + WithdrawReasons::all(), + ); ReleaseSchedules::::insert(who, bounded_schedules); }); } @@ -263,7 +239,7 @@ pub mod module { #[pallet::weight(T::WeightInfo::claim(::MaxReleaseSchedules::get() / 2))] pub fn claim(origin: OriginFor) -> DispatchResult { let who = ensure_signed(origin)?; - let locked_amount = Self::do_claim(&who)?; + let locked_amount = Self::do_claim(&who); Self::deposit_event(Event::Claimed { who, amount: locked_amount }); Ok(()) @@ -292,7 +268,7 @@ pub mod module { if to == from { ensure!( - T::Currency::balance(&from) >= + T::Currency::free_balance(&from) >= schedule.total_amount().ok_or(ArithmeticError::Overflow)?, Error::::InsufficientBalanceToLock, ); @@ -348,7 +324,7 @@ pub mod module { ) -> DispatchResult { ensure_signed(origin)?; let who = T::Lookup::lookup(dest)?; - let locked_amount = Self::do_claim(&who)?; + let locked_amount = Self::do_claim(&who); Self::deposit_event(Event::Claimed { who, amount: locked_amount }); Ok(()) @@ -357,15 +333,15 @@ pub mod module { } impl Pallet { - fn do_claim(who: &T::AccountId) -> Result, DispatchError> { + fn do_claim(who: &T::AccountId) -> BalanceOf { let locked = Self::prune_and_get_locked_balance(who); if locked.is_zero() { - Self::delete_lock(who)?; + Self::delete_lock(who); } else { - Self::update_lock(who, locked)?; + Self::update_lock(who, locked); } - Ok(locked) + locked } /// Deletes schedules that have released all funds up to a block-number. @@ -409,9 +385,9 @@ impl Pallet { .checked_add(&schedule_amount) .ok_or(ArithmeticError::Overflow)?; - T::Currency::transfer(from, to, schedule_amount, Preservation::Expendable)?; + T::Currency::transfer(from, to, schedule_amount, ExistenceRequirement::AllowDeath)?; - Self::update_lock(&to, total_amount)?; + Self::update_lock(&to, total_amount); >::try_append(to, schedule) .map_err(|_| Error::::MaxReleaseSchedulesExceeded)?; @@ -429,7 +405,7 @@ impl Pallet { // empty release schedules cleanup the storage and unlock the fund if bounded_schedules.is_empty() { - Self::delete_release_schedules(who)?; + Self::delete_release_schedules(who); return Ok(()) } @@ -442,22 +418,23 @@ impl Pallet { }, )?; - ensure!(T::Currency::balance(who) >= total_amount, Error::::InsufficientBalanceToLock,); + ensure!( + T::Currency::free_balance(who) >= total_amount, + Error::::InsufficientBalanceToLock, + ); - Self::update_lock(&who, total_amount)?; + Self::update_lock(&who, total_amount); Self::set_schedules_for(who, bounded_schedules); Ok(()) } - fn update_lock(who: &T::AccountId, locked: BalanceOf) -> DispatchResult { - T::Currency::set_freeze(&FreezeReason::TimeReleaseVesting.into(), who, locked)?; - Ok(()) + fn update_lock(who: &T::AccountId, locked: BalanceOf) { + T::Currency::set_lock(RELEASE_LOCK_ID, who, locked, WithdrawReasons::all()); } - fn delete_lock(who: &T::AccountId) -> DispatchResult { - T::Currency::thaw(&FreezeReason::TimeReleaseVesting.into(), who)?; - Ok(()) + fn delete_lock(who: &T::AccountId) { + T::Currency::remove_lock(RELEASE_LOCK_ID, who); } fn set_schedules_for( @@ -467,10 +444,9 @@ impl Pallet { ReleaseSchedules::::insert(who, schedules); } - fn delete_release_schedules(who: &T::AccountId) -> DispatchResult { + fn delete_release_schedules(who: &T::AccountId) { >::remove(who); - Self::delete_lock(who)?; - Ok(()) + Self::delete_lock(who); } } diff --git a/pallets/time-release/src/migration/mod.rs b/pallets/time-release/src/migration/mod.rs deleted file mode 100644 index c34354a101..0000000000 --- a/pallets/time-release/src/migration/mod.rs +++ /dev/null @@ -1,2 +0,0 @@ -/// migrations to v2 -pub mod v2; diff --git a/pallets/time-release/src/migration/v2.rs b/pallets/time-release/src/migration/v2.rs deleted file mode 100644 index 0829a14845..0000000000 --- a/pallets/time-release/src/migration/v2.rs +++ /dev/null @@ -1,263 +0,0 @@ -use crate::{types, BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, ReleaseSchedules}; -use frame_support::{ - pallet_prelude::{GetStorageVersion, IsType, Weight}, - traits::{ - fungible::MutateFreeze, Get, LockIdentifier, LockableCurrency, OnRuntimeUpgrade, - StorageVersion, - }, -}; -use parity_scale_codec::Encode; -use sp_core::hexdisplay::HexDisplay; -use sp_runtime::{traits::Zero, Saturating}; - -const LOG_TARGET: &str = "runtime::time-release"; - -#[cfg(feature = "try-runtime")] -use sp_std::vec::Vec; - -const RELEASE_LOCK_ID: LockIdentifier = *b"timeRels"; - -/// The OnRuntimeUpgrade implementation for this storage migration -pub struct MigrationToV2(sp_std::marker::PhantomData<(T, OldCurrency)>); -impl MigrationToV2 -where - T: Config, - OldCurrency: 'static + LockableCurrency>, - OldCurrency::Balance: IsType>, -{ - /// Translate time release locked deposit to frozen deposit - pub fn translate_lock_to_freeze( - account_id: &T::AccountId, - amount: OldCurrency::Balance, - ) -> Weight { - // 1 read get Locks - // 1 read get Freezes - // 1 read get Account - // 1 write set Account - // 1 read get Locks: update_locks: set existed with `contains_key` - // 1 write set Locks - OldCurrency::remove_lock(RELEASE_LOCK_ID, &account_id); - - // 1 read get Freeze - // 1 read get Locks - // 1 write set Account: update_freezes->mutate_account->try_mutate_account: set account data - // 1 write set Freeze - T::Currency::set_freeze( - &FreezeReason::TimeReleaseVesting.into(), - &account_id, - amount.into(), - ) - .unwrap_or_else(|err| { - log::error!( - target: LOG_TARGET, - "Failed to freeze {:?} from account 0x{:?}, reason: {:?}", - amount, - HexDisplay::from(&account_id.encode()), - err - ); - }); - - T::DbWeight::get().reads_writes(6, 4) - } -} - -impl OnRuntimeUpgrade for MigrationToV2 -where - T: Config, - OldCurrency: 'static + LockableCurrency>, - OldCurrency::Balance: IsType>, -{ - fn on_runtime_upgrade() -> Weight { - log::info!(target: LOG_TARGET, "Running storage migration..."); - - let on_chain_version = Pallet::::on_chain_storage_version(); - - // storage was already migrated. - if on_chain_version.ge(&crate::module::STORAGE_VERSION) { - log::info!( - target: LOG_TARGET, - "Old Time Release Locks->Freezes migration attempted to run. Please remove" - ); - return T::DbWeight::get().reads(1) - } - - log::info!(target: LOG_TARGET, "🔄 Time Release Locks->Freezes migration started"); - // The migration started with 1r to get the on_chain_storage_version - let mut total_weight = T::DbWeight::get().reads_writes(1, 0); - let mut total_accounts_migrated = 0u32; - - // Get all the keys(accounts) from the ReleaseSchedules storage - ReleaseSchedules::::iter() - .map(|(account_id, _)| account_id) - .for_each(|account_id| { - let (total_amount, cal_fn_weight) = calculate_total_scheduled_locks_for_account::(&account_id); - - let trans_fn_weight = MigrationToV2::::translate_lock_to_freeze( - &account_id, - total_amount.into(), - ); - - total_weight = total_weight.saturating_add(cal_fn_weight).saturating_add(trans_fn_weight); - - total_accounts_migrated += 1; - - log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), total_amount); - }); - - log::info!( - target: LOG_TARGET, - "total accounts migrated from locks to frozen {:?}", - total_accounts_migrated - ); - - StorageVersion::new(2).put::>(); - total_weight.saturating_add(T::DbWeight::get().reads_writes(0, 1)); - - log::info!(target: LOG_TARGET, "🔄 Time Release migration finished"); - log::info!( - target: LOG_TARGET, - "Time Release Migration calculated weight = {:?}", - total_weight - ); - - total_weight - } - - #[cfg(feature = "try-runtime")] - fn pre_upgrade() -> Result, sp_runtime::TryRuntimeError> { - use frame_support::storage::generator::StorageMap; - let pallet_prefix = ReleaseSchedules::::module_prefix(); - let storage_prefix = ReleaseSchedules::::storage_prefix(); - assert_eq!(&b"TimeRelease"[..], pallet_prefix); - assert_eq!(&b"ReleaseSchedules"[..], storage_prefix); - log::info!(target: LOG_TARGET, "Running pre_upgrade..."); - - let count = ReleaseSchedules::::iter().count() as u32; - log::info!(target: LOG_TARGET, "Finish pre_upgrade for {:?} records", count); - Ok(count.encode()) - } - - #[cfg(feature = "try-runtime")] - fn post_upgrade(state: Vec) -> Result<(), sp_runtime::TryRuntimeError> { - use parity_scale_codec::Decode; - let pre_upgrade_count: u32 = Decode::decode(&mut state.as_slice()).unwrap_or_default(); - let on_chain_version = Pallet::::on_chain_storage_version(); - - assert_eq!(on_chain_version, crate::module::STORAGE_VERSION); - assert_eq!(pre_upgrade_count as usize, ReleaseSchedules::::iter().count()); - - log::info!(target: LOG_TARGET, "✅ migration post_upgrade checks passed"); - Ok(()) - } -} - -fn calculate_total_scheduled_locks_for_account( - account_id: &T::AccountId, -) -> (BalanceOf, Weight) { - let total = ReleaseSchedules::::get(&account_id) // 1r - .iter() - .map(|schedule: &types::ReleaseSchedule, BalanceOf>| { - schedule.total_amount() - }) - .fold(Zero::zero(), |acc: BalanceOf, amount| { - acc.saturating_add(amount.unwrap_or(Zero::zero())) - }); - - (total, T::DbWeight::get().reads(1)) -} - -#[cfg(test)] -#[cfg(feature = "try-runtime")] -mod test { - use frame_support::traits::{tokens::fungible::InspectFreeze, WithdrawReasons}; - - use super::*; - use crate::mock::{Test, *}; - use pallet_balances::{BalanceLock, Reasons}; - - type MigrationOf = MigrationToV2>; - - #[test] - fn migration_works() { - ExtBuilder::build().execute_with(|| { - assert_eq!(pallet_balances::Pallet::::free_balance(&DAVE), DAVE_BALANCE); - - let schedules = vec![ - // who, start, period, period_count, per_period - (DAVE, 2, 3, 1, 5), - ]; - - create_schedules_and_set_lock(schedules); - - assert_eq!( - pallet_balances::Pallet::::locks(&DAVE) - .iter() - .find(|l| l.id == RELEASE_LOCK_ID), - Some(&BalanceLock { - id: RELEASE_LOCK_ID, - amount: 5u64.into(), - reasons: Reasons::All - }) - ); - - // Run migration. - let state = MigrationOf::::pre_upgrade().unwrap(); - MigrationOf::::on_runtime_upgrade(); - MigrationOf::::post_upgrade(state).unwrap(); - - assert_eq!( - pallet_balances::Pallet::::locks(&DAVE), - vec![], - "Locks should be empty" - ); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &DAVE - ), - 5u64, - "Frozen balance should be 5 for account {:?}", - DAVE - ); - }) - } - - fn create_schedules_and_set_lock(schedules: Vec<(AccountId, u32, u32, u32, u64)>) { - schedules.iter().for_each(|(who, start, period, period_count, per_period)| { - let mut bounded_schedules = ReleaseSchedules::::get(who); - let new_schedule = types::ReleaseSchedule { - start: *start, - period: *period, - period_count: *period_count, - per_period: *per_period, - }; - - bounded_schedules - .try_push(new_schedule.clone()) - .expect("Max release schedules exceeded"); - - let total_amount = bounded_schedules.iter().fold( - Zero::zero(), - |acc_amount: BalanceOf, schedule| { - acc_amount.saturating_add(schedule.total_amount().unwrap_or(Zero::zero())) - }, - ); - - assert_eq!(total_amount, new_schedule.total_amount().unwrap_or(Zero::zero())); - - assert!( - pallet_balances::Pallet::::free_balance(who) >= total_amount, - "Account does not have enough balance" - ); - - pallet_balances::Pallet::::set_lock( - RELEASE_LOCK_ID, - &who, - total_amount, - WithdrawReasons::all(), - ); - - ReleaseSchedules::::insert(who, bounded_schedules); - }); - } -} diff --git a/pallets/time-release/src/mock.rs b/pallets/time-release/src/mock.rs index 3789cbe8f6..7234eea925 100644 --- a/pallets/time-release/src/mock.rs +++ b/pallets/time-release/src/mock.rs @@ -50,9 +50,9 @@ impl pallet_balances::Config for Test { type MaxReserves = (); type ReserveIdentifier = [u8; 8]; type WeightInfo = (); - type FreezeIdentifier = RuntimeFreezeReason; - type MaxFreezes = ConstU32<1>; + type FreezeIdentifier = (); type MaxHolds = ConstU32<0>; + type MaxFreezes = ConstU32<0>; type RuntimeHoldReason = (); } @@ -99,8 +99,6 @@ impl Config for Test { type WeightInfo = (); type MaxReleaseSchedules = ConstU32<50>; type BlockNumberProvider = MockBlockNumberProvider; - type RuntimeFreezeReason = RuntimeFreezeReason; - type Balance = Balance; } type Block = frame_system::mocking::MockBlockU32; @@ -109,7 +107,7 @@ construct_runtime!( pub enum Test { System: frame_system::{Pallet, Call, Storage, Config, Event}, - TimeRelease: pallet_time_release::{Pallet, Storage, Call, Event, Config, FreezeReason}, + TimeRelease: pallet_time_release::{Pallet, Storage, Call, Event, Config}, PalletBalances: pallet_balances::{Pallet, Call, Storage, Config, Event}, } ); @@ -117,11 +115,9 @@ construct_runtime!( pub const ALICE: AccountId = 0; pub const BOB: AccountId = 2; pub const CHARLIE: AccountId = 3; -pub const DAVE: AccountId = 4; pub const ALICE_BALANCE: u64 = 100; pub const CHARLIE_BALANCE: u64 = 50; -pub const DAVE_BALANCE: u64 = 200; #[derive(Default)] pub struct ExtBuilder; @@ -133,11 +129,7 @@ impl ExtBuilder { MockBlockNumberProvider::set(0); pallet_balances::GenesisConfig:: { - balances: vec![ - (ALICE, ALICE_BALANCE), - (CHARLIE, CHARLIE_BALANCE), - (DAVE, DAVE_BALANCE), - ], + balances: vec![(ALICE, ALICE_BALANCE), (CHARLIE, CHARLIE_BALANCE)], } .assimilate_storage(&mut t) .unwrap(); diff --git a/pallets/time-release/src/tests.rs b/pallets/time-release/src/tests.rs index a3e47d3df0..6b7df0fae3 100644 --- a/pallets/time-release/src/tests.rs +++ b/pallets/time-release/src/tests.rs @@ -1,16 +1,9 @@ //! Unit tests for the time-release module. use super::*; use chrono::{DateTime, Days, Duration, TimeZone, Utc}; -use frame_support::{ - assert_noop, assert_ok, - error::BadOrigin, - traits::{ - fungible::{Inspect, InspectFreeze}, - tokens::Fortitude, - Currency, WithdrawReasons, - }, -}; +use frame_support::{assert_noop, assert_ok, error::BadOrigin, traits::Imbalance}; use mock::*; +use pallet_balances::{BalanceLock, Reasons}; use sp_runtime::{traits::Dispatchable, SaturatedConversion, TokenError}; #[test] @@ -120,11 +113,8 @@ fn add_new_release_schedule_merges_with_current_locked_balance_and_until() { assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, another_schedule)); assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 17u64 + PalletBalances::locks(&BOB).get(0), + Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 17u64, reasons: Reasons::All }) ); }); } @@ -228,16 +218,10 @@ fn claim_works() { assert!(!ReleaseSchedules::::contains_key(BOB)); assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(BOB), ALICE, 10)); // all used up - assert_eq!(::Currency::balance(&BOB), 0); + assert_eq!(PalletBalances::free_balance(BOB), 0); // no locks anymore - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert_eq!(PalletBalances::locks(&BOB), vec![]); }); } @@ -251,11 +235,8 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 20u64 + PalletBalances::locks(&BOB).get(0), + Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 20u64, reasons: Reasons::All }) ); assert!(ReleaseSchedules::::contains_key(&BOB)); @@ -264,13 +245,7 @@ fn claim_for_works() { assert_ok!(TimeRelease::claim_for(RuntimeOrigin::signed(ALICE), BOB)); // no locks anymore - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert_eq!(PalletBalances::locks(&BOB), vec![]); assert!(!ReleaseSchedules::::contains_key(&BOB)); }); } @@ -301,21 +276,12 @@ fn update_release_schedules_works() { // empty release schedules cleanup the storage and unlock the fund assert!(ReleaseSchedules::::contains_key(BOB)); assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 10u64 + PalletBalances::locks(&BOB).get(0), + Some(&BalanceLock { id: RELEASE_LOCK_ID, amount: 10u64, reasons: Reasons::All }) ); assert_ok!(TimeRelease::update_release_schedules(RuntimeOrigin::root(), BOB, vec![])); assert!(!ReleaseSchedules::::contains_key(BOB)); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert_eq!(PalletBalances::locks(&BOB), vec![]); }); } @@ -323,11 +289,7 @@ fn update_release_schedules_works() { fn update_release_schedules_fails_if_unexpected_existing_locks() { ExtBuilder::build().execute_with(|| { assert_ok!(PalletBalances::transfer_allow_death(RuntimeOrigin::signed(ALICE), BOB, 1)); - let _ = ::Currency::set_freeze( - &FreezeReason::TimeReleaseVesting.into(), - &BOB, - 0u64, - ); + PalletBalances::set_lock(*b"prelocks", &BOB, 0u64, WithdrawReasons::all()); }); } @@ -368,13 +330,7 @@ fn multiple_release_schedule_claim_works() { assert!(!ReleaseSchedules::::contains_key(&BOB)); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert_eq!(PalletBalances::locks(&BOB), vec![]); }); } @@ -424,28 +380,19 @@ fn cliff_release_works() { per_period: VESTING_AMOUNT, }; - assert_eq!(::Currency::balance(&BOB), 0); + let balance_lock = + BalanceLock { id: RELEASE_LOCK_ID, amount: VESTING_AMOUNT, reasons: Reasons::All }; + + assert_eq!(PalletBalances::free_balance(BOB), 0); assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, cliff_schedule)); - assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - VESTING_AMOUNT - ); + assert_eq!(PalletBalances::free_balance(BOB), VESTING_AMOUNT); + assert_eq!(PalletBalances::locks(&BOB), vec![balance_lock.clone()]); for i in 1..VESTING_PERIOD { MockBlockNumberProvider::set(i); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!(::Currency::balance(&BOB), VESTING_AMOUNT); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - VESTING_AMOUNT - ); + assert_eq!(PalletBalances::free_balance(BOB), VESTING_AMOUNT); + assert_eq!(PalletBalances::locks(&BOB), vec![balance_lock.clone()]); assert_noop!( PalletBalances::transfer_allow_death( RuntimeOrigin::signed(BOB), @@ -458,13 +405,7 @@ fn cliff_release_works() { MockBlockNumberProvider::set(VESTING_PERIOD); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert!(PalletBalances::locks(&BOB).is_empty()); assert_ok!(PalletBalances::transfer_allow_death( RuntimeOrigin::signed(BOB), CHARLIE, @@ -513,45 +454,19 @@ fn alice_time_releases_schedule() { // Bob starts with zero balance and zero locks. assert_eq!(get_balance::(&BOB), 0); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert!(PalletBalances::locks(&BOB).is_empty()); // Time release transfer is initiated by Alice to Bob. As a result, Bobs free-balance // increases by the total amount scheduled to be time-released. // However, it cannot spent because a lock is put on the balance. assert_ok!(TimeRelease::transfer(RuntimeOrigin::signed(ALICE), BOB, schedule)); assert_eq!(get_balance::(&BOB), 24_996); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 24996 - ); - assert_eq!( - ::Currency::reducible_balance( - &BOB, - Preservation::Expendable, - Fortitude::Polite - ), - 0 - ); + assert_eq!(PalletBalances::locks(&BOB).len(), 1usize); // Bob naively attempts to claim the transfer before the scheduled release date // and nothing happens because the schedule release has yet to start. assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 24_996 - ); + assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, 24_996); let time_release_transfer_data: Vec<(DateTime, _)> = time_release_transfers_data::(); @@ -579,13 +494,7 @@ fn alice_time_releases_schedule() { // Doing a claim does not do anything assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); // Since the first issuance the total amount locked increases by the new transfers: 24_996; - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - total_locked - ); + assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, total_locked); let july_2024_sept_2024: Vec> = vec![ Utc.with_ymd_and_hms(2024, 7, 1, 0, 0, 0).unwrap(), @@ -600,13 +509,7 @@ fn alice_time_releases_schedule() { MockBlockNumberProvider::set(date_to_approximate_block_number(month.clone()).into()); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); total_locked -= 4_166 as u64; - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - total_locked - ); + assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, total_locked); } // quarter-6: time-release transfer AND monthly claim @@ -627,13 +530,7 @@ fn alice_time_releases_schedule() { // new transfer_total - one_month_of_time_release total_locked += total_transfered; total_locked -= 4_166; - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - total_locked - ); + assert_eq!(PalletBalances::locks(&BOB).first().unwrap().amount, total_locked); // quarter-7-12: time-release transfer AND monthly claim let jan_2025_to_april_2026_quarterly_data = &time_release_transfer_data[6..]; @@ -660,23 +557,18 @@ fn alice_time_releases_schedule() { .into(), ); assert_ok!(TimeRelease::claim(RuntimeOrigin::signed(BOB))); - assert_eq!( - ::Currency::balance_frozen( - &FreezeReason::TimeReleaseVesting.into(), - &BOB - ), - 0 - ); + assert_eq!(PalletBalances::locks(&BOB).first(), None); }); } fn get_balance(who: &T::AccountId) -> BalanceOf { - T::Currency::balance(who) + T::Currency::free_balance(who) } fn set_balance(who: &T::AccountId, balance: BalanceOf) { - let actual_deposit = T::Currency::mint_into(&who, balance.saturated_into()); - assert_eq!(balance, actual_deposit.unwrap()); + let deposit_result = T::Currency::deposit_creating(who, balance.saturated_into()); + let actual_deposit = deposit_result.peek(); + assert_eq!(balance, actual_deposit); } fn build_time_release_schedule( diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index 5fe26e50d2..f8a144d47e 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -221,10 +221,6 @@ pub type Executive = frame_executive::Executive< pallet_capacity::migration::v2::MigrateToV2, pallet_capacity::migration::v3::MigrationToV3>, pallet_schemas::migration::v3::MigrateToV3, - pallet_time_release::migration::v2::MigrationToV2< - Runtime, - pallet_balances::Pallet, - >, ), >; @@ -469,7 +465,6 @@ pub type MaxReleaseSchedules = ConstU32<{ MAX_RELEASE_SCHEDULES }>; // the descriptions of these configs. impl pallet_time_release::Config for Runtime { type RuntimeEvent = RuntimeEvent; - type Balance = Balance; type Currency = Balances; type MinReleaseTransfer = MinReleaseTransfer; type TransferOrigin = EnsureSigned; @@ -479,7 +474,6 @@ impl pallet_time_release::Config for Runtime { type BlockNumberProvider = RelaychainDataProvider; #[cfg(feature = "frequency-no-relay")] type BlockNumberProvider = System; - type RuntimeFreezeReason = RuntimeFreezeReason; } // See https://paritytech.github.io/substrate/master/pallet_timestamp/index.html for @@ -1054,7 +1048,7 @@ construct_runtime!( Multisig: pallet_multisig::{Pallet, Call, Storage, Event} = 30, // FRQC Update - TimeRelease: pallet_time_release::{Pallet, Call, Storage, Event, Config, FreezeReason} = 40, + TimeRelease: pallet_time_release::{Pallet, Call, Storage, Event, Config} = 40, // Frequency related pallets Msa: pallet_msa::{Pallet, Call, Storage, Event} = 60, From f009805a1524bb11ae5e604d8be90aa5eb4b6d59 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 16:13:22 -0700 Subject: [PATCH 72/75] fix: address pr comments --- pallets/capacity/src/lib.rs | 8 -------- pallets/capacity/src/migration/v2.rs | 3 ++- pallets/capacity/src/migration/v3.rs | 25 ++++++++++++++++++------- pallets/schemas/src/migration/v3.rs | 2 +- 4 files changed, 21 insertions(+), 17 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index 0b62ebd7bb..b4f4826471 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -109,8 +109,6 @@ pub mod pallet { Staked, } - /// the storage version for the v2 migration - pub const STORAGE_VERSION_V2: StorageVersion = StorageVersion::new(2); /// the storage version for this pallet pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(3); @@ -585,12 +583,6 @@ impl Pallet { .min(proposed_amount) } - // Calculates the total amount of tokens that are currently unlocked for the given staker. - pub(crate) fn get_unlocking_total_for(staker: &T::AccountId) -> (BalanceOf, Weight) { - let unlocks = Self::get_unstake_unlocking_for(staker).unwrap_or_default(); - (unlock_chunks_total::(&unlocks), T::DbWeight::get().reads(1)) - } - pub(crate) fn do_withdraw_unstaked( staker: &T::AccountId, ) -> Result, DispatchError> { diff --git a/pallets/capacity/src/migration/v2.rs b/pallets/capacity/src/migration/v2.rs index 92f922c913..431f616a1b 100644 --- a/pallets/capacity/src/migration/v2.rs +++ b/pallets/capacity/src/migration/v2.rs @@ -1,7 +1,6 @@ use crate::{ types::{StakingDetails, UnlockChunk}, BalanceOf, Config, Pallet, StakingAccountLedger, StakingType, UnlockChunkList, UnstakeUnlocks, - STORAGE_VERSION_V2, }; use frame_support::{ pallet_prelude::{GetStorageVersion, Weight}, @@ -13,6 +12,8 @@ const LOG_TARGET: &str = "runtime::capacity"; #[cfg(feature = "try-runtime")] use sp_std::{fmt::Debug, vec::Vec}; +/// the storage version for the v2 migration +pub const STORAGE_VERSION_V2: StorageVersion = StorageVersion::new(2); /// Only contains V1 storage format pub mod v1 { use super::*; diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 65f0d6cdb1..1cbb3bf560 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -1,4 +1,8 @@ -use crate::{BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, StakingAccountLedger}; +use crate::{ + unlock_chunks_total, BalanceOf, BlockNumberFor, Config, FreezeReason, Pallet, + StakingAccountLedger, UnstakeUnlocks, +}; + use frame_support::{ pallet_prelude::{GetStorageVersion, IsType, Weight}, traits::{ @@ -59,6 +63,12 @@ where log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); T::DbWeight::get().reads_writes(6, 4) } + + /// Calculates the total amount of tokens that are currently unlocked for the given staker. + pub fn get_unlocking_total_for(staker: &T::AccountId) -> BalanceOf { + let unlocks = UnstakeUnlocks::::get(staker).unwrap_or_default(); + unlock_chunks_total::(&unlocks) + } } impl OnRuntimeUpgrade for MigrationToV3 @@ -70,7 +80,7 @@ where fn on_runtime_upgrade() -> Weight { let on_chain_version = Pallet::::on_chain_storage_version(); // 1r - if on_chain_version.ge(&crate::pallet::STORAGE_VERSION) { + if on_chain_version.ge(&3) { log::info!(target: LOG_TARGET, "Old Capacity Locks->Freezes migration attempted to run. Please remove"); return T::DbWeight::get().reads(1) } @@ -84,8 +94,7 @@ where StakingAccountLedger::::iter() .map(|(account_id, staking_details)| (account_id, staking_details.active)) .for_each(|(account_id, active_amount)| { - let (total_unlocking, cal_fn_weight) = - Pallet::::get_unlocking_total_for(&account_id); + let total_unlocking = Self::get_unlocking_total_for(&account_id); let total_amount = active_amount.saturating_add(total_unlocking); let trans_fn_weight = MigrationToV3::::translate_lock_to_freeze( @@ -93,8 +102,10 @@ where total_amount.into(), ); - total_weight = - total_weight.saturating_add(cal_fn_weight).saturating_add(trans_fn_weight); + // Add the read from get_unlocking_total_for() + the weight from translate_lock_to_freeze() + total_weight = total_weight + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(trans_fn_weight); total_accounts_migrated += 1; }); @@ -102,7 +113,7 @@ where log::info!(target: LOG_TARGET, "total accounts migrated from locks to freezes: {:?}", total_accounts_migrated); StorageVersion::new(3).put::>(); // 1 w - total_weight.saturating_add(T::DbWeight::get().reads_writes(0, 1)); + total_weight = total_weight.saturating_add(T::DbWeight::get().reads_writes(0, 1)); log::info!(target: LOG_TARGET, "🔄 Capacity Locks->Freezes migration finished"); log::info!(target: LOG_TARGET, "Capacity Migration calculated weight = {:?}", total_weight); diff --git a/pallets/schemas/src/migration/v3.rs b/pallets/schemas/src/migration/v3.rs index fc0eab93ec..2683bada6a 100644 --- a/pallets/schemas/src/migration/v3.rs +++ b/pallets/schemas/src/migration/v3.rs @@ -116,7 +116,7 @@ pub fn migrate_to_v3() -> Weight { }) }); - log::error!(target: LOG_TARGET, "Finished translating {:?} SchemaInfos!", writes); + log::info!(target: LOG_TARGET, "Finished translating {:?} SchemaInfos!", writes); for (schema_id, schema_name) in known_schemas.iter() { reads.saturating_inc(); From e75f8ab1b97b026e7219e791df5ea1d2f4440166 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 16:42:44 -0700 Subject: [PATCH 73/75] fix: refactor migration test w/o try-runtime --- pallets/capacity/src/migration/v3.rs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 1cbb3bf560..015bcc12c1 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -150,7 +150,6 @@ where } #[cfg(test)] -#[cfg(feature = "try-runtime")] mod test { use frame_support::traits::{tokens::fungible::InspectFreeze, WithdrawReasons}; @@ -160,6 +159,7 @@ mod test { StakingAccountLedger, StakingDetails, StakingType::MaximumCapacity, }; + use frame_support::storage::generator::StorageMap; use pallet_balances::{BalanceLock, Reasons}; type MigrationOf = MigrationToV3>; @@ -190,9 +190,12 @@ mod test { assert_eq!(StakingAccountLedger::::iter().count(), 1); // Run migration. - let state = MigrationOf::::pre_upgrade().unwrap(); + let pre_upgrade_count = StakingAccountLedger::::iter().count() as u32; MigrationOf::::on_runtime_upgrade(); - MigrationOf::::post_upgrade(state).unwrap(); + + let on_chain_version = Pallet::::on_chain_storage_version(); + assert_eq!(on_chain_version, crate::pallet::STORAGE_VERSION); + assert_eq!(pre_upgrade_count as usize, StakingAccountLedger::::iter().count()); // Check that the old staking locks are now freezes assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); From 6f024a2f71e8bbedd956713751c319f9f2f27924 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 16:42:44 -0700 Subject: [PATCH 74/75] fix: refactor migration test w/o try-runtime --- pallets/capacity/src/migration/v3.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 1cbb3bf560..aaad9bc250 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -150,7 +150,6 @@ where } #[cfg(test)] -#[cfg(feature = "try-runtime")] mod test { use frame_support::traits::{tokens::fungible::InspectFreeze, WithdrawReasons}; @@ -190,9 +189,12 @@ mod test { assert_eq!(StakingAccountLedger::::iter().count(), 1); // Run migration. - let state = MigrationOf::::pre_upgrade().unwrap(); + let pre_upgrade_count = StakingAccountLedger::::iter().count() as u32; MigrationOf::::on_runtime_upgrade(); - MigrationOf::::post_upgrade(state).unwrap(); + + let on_chain_version = Pallet::::on_chain_storage_version(); + assert_eq!(on_chain_version, crate::pallet::STORAGE_VERSION); + assert_eq!(pre_upgrade_count as usize, StakingAccountLedger::::iter().count()); // Check that the old staking locks are now freezes assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); From a0070a0f2302d3ef68bca6022ae6c003432ef7b9 Mon Sep 17 00:00:00 2001 From: Matthew Orris <--help> Date: Mon, 18 Dec 2023 18:18:54 -0700 Subject: [PATCH 75/75] fix: set_freeze before removing the locks; update FreezeReason; address comments --- pallets/capacity/src/lib.rs | 8 ++--- pallets/capacity/src/migration/v3.rs | 36 +++++++++---------- pallets/capacity/src/tests/other_tests.rs | 6 ++-- .../src/tests/stake_and_deposit_tests.rs | 17 ++++++--- pallets/capacity/src/tests/unstaking_tests.rs | 2 +- .../src/tests/withdraw_unstaked_tests.rs | 11 +++--- runtime/frequency/src/lib.rs | 1 - 7 files changed, 47 insertions(+), 34 deletions(-) diff --git a/pallets/capacity/src/lib.rs b/pallets/capacity/src/lib.rs index b4f4826471..234a80b2a6 100644 --- a/pallets/capacity/src/lib.rs +++ b/pallets/capacity/src/lib.rs @@ -106,7 +106,7 @@ pub mod pallet { #[pallet::composite_enum] pub enum FreezeReason { /// The account has staked tokens to the Frequency network. - Staked, + CapacityStaking, } /// the storage version for this pallet @@ -509,7 +509,7 @@ impl Pallet { .active .checked_add(&unlock_chunks_total::(&unlocks)) .ok_or(ArithmeticError::Overflow)?; - T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, total_to_lock)?; + T::Currency::set_freeze(&FreezeReason::CapacityStaking.into(), staker, total_to_lock)?; Self::set_staking_account(staker, staking_account); Ok(()) } @@ -604,9 +604,9 @@ impl Pallet { let staking_account = Self::get_staking_account_for(staker).unwrap_or_default(); let total_locked = staking_account.active.saturating_add(total_unlocking); if total_locked.is_zero() { - T::Currency::thaw(&FreezeReason::Staked.into(), staker)?; + T::Currency::thaw(&FreezeReason::CapacityStaking.into(), staker)?; } else { - T::Currency::set_freeze(&FreezeReason::Staked.into(), staker, total_locked)?; + T::Currency::set_freeze(&FreezeReason::CapacityStaking.into(), staker, total_locked)?; } Ok(amount_withdrawn) } diff --git a/pallets/capacity/src/migration/v3.rs b/pallets/capacity/src/migration/v3.rs index 015bcc12c1..9677102d07 100644 --- a/pallets/capacity/src/migration/v3.rs +++ b/pallets/capacity/src/migration/v3.rs @@ -34,25 +34,13 @@ where account_id: T::AccountId, amount: OldCurrency::Balance, ) -> Weight { - // 1 read get Locks: remove_lock: set locks - // 1 read get Freezes - // 1 read get Account - // 1 write set Account: update_locks->try_mutate_account->ensure_upgraded: if account is *not* already upgraded. - // We could avoid this write by calling the upgrade script before running the migration, - // which would ensure that all accounts are upgraded. - // 1 write set Account: update_locks->try_mutate_account: set account data - // 1 read get Locks: update_locks: set existed with `contains_key` - // 1 write set Locks: update_locks->Locks::remove: remove existed - OldCurrency::remove_lock(STAKING_ID, &account_id); - - // 1 read get Freezes: set_freeze: set locks + // 1 read get Freezes: set_freeze: get locks // 1 read get Locks: update_freezes: Locks::get().iter() - // 1 write set Account: update_freezes->mutate_account->try_mutate_account->ensure_upgraded: if account is *not* already upgraded. + // 1 write set Account: update_freezes->mutate_account->try_mutate_account->ensure_upgraded: if account is *not* already upgraded. // 1 write set Account: update_freezes->mutate_account->try_mutate_account: set account data // 1 write set Freezes: update_freezes: Freezes::insert - ::Currency::set_freeze( - &FreezeReason::Staked.into(), + &FreezeReason::CapacityStaking.into(), &account_id, amount.into(), ) @@ -60,11 +48,20 @@ where log::error!(target: LOG_TARGET, "Failed to freeze {:?} for account 0x{:?}, reason: {:?}", amount, HexDisplay::from(&account_id.encode()), err); }); + // 1 read get Locks: remove_lock: set locks + // 1 read get Freezes + // 1 read get Account + // 1 write set Account: update_locks->try_mutate_account->ensure_upgraded: if account is *not* already upgraded. + // 1 write set Account: update_locks->try_mutate_account: set account data + // [Cached] 1 read get Locks: update_locks: set existed with `contains_key` + // 1 write set Locks: update_locks->Locks::remove: remove existed + OldCurrency::remove_lock(STAKING_ID, &account_id); + log::info!(target: LOG_TARGET, "🔄 migrated account 0x{:?}, amount:{:?}", HexDisplay::from(&account_id.encode()), amount.into()); - T::DbWeight::get().reads_writes(6, 4) + T::DbWeight::get().reads_writes(5, 6) } - /// Calculates the total amount of tokens that are currently unlocked for the given staker. + /// Calculates the total amount of tokens that have been unstaked and are not thawed, for the given staker. pub fn get_unlocking_total_for(staker: &T::AccountId) -> BalanceOf { let unlocks = UnstakeUnlocks::::get(staker).unwrap_or_default(); unlock_chunks_total::(&unlocks) @@ -200,7 +197,10 @@ mod test { // Check that the old staking locks are now freezes assert_eq!(pallet_balances::Pallet::::locks(&account), vec![]); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + ::Currency::balance_frozen( + &FreezeReason::CapacityStaking.into(), + &account + ), locked_amount ); }) diff --git a/pallets/capacity/src/tests/other_tests.rs b/pallets/capacity/src/tests/other_tests.rs index 91efa28550..611a598f96 100644 --- a/pallets/capacity/src/tests/other_tests.rs +++ b/pallets/capacity/src/tests/other_tests.rs @@ -76,8 +76,10 @@ fn set_staking_account_is_successful() { Capacity::set_staking_account_and_lock(&staker, &staking_account) .expect("Failed to set staking account and lock"); - let frozen_balance = - ::Currency::balance_frozen(&(FreezeReason::Staked).into(), &staker); + let frozen_balance = ::Currency::balance_frozen( + &(FreezeReason::CapacityStaking).into(), + &staker, + ); assert_eq!(frozen_balance, 55); }); } diff --git a/pallets/capacity/src/tests/stake_and_deposit_tests.rs b/pallets/capacity/src/tests/stake_and_deposit_tests.rs index 08b2ca18d7..ac924bfcb4 100644 --- a/pallets/capacity/src/tests/stake_and_deposit_tests.rs +++ b/pallets/capacity/src/tests/stake_and_deposit_tests.rs @@ -38,7 +38,10 @@ fn stake_works() { assert_eq!(events.first().unwrap(), &Event::Staked { account, target, amount, capacity }); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + ::Currency::balance_frozen( + &FreezeReason::CapacityStaking.into(), + &account + ), amount ); }); @@ -101,7 +104,10 @@ fn stake_increase_stake_amount_works() { &Event::Staked { account, target, amount: initial_amount, capacity } ); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + ::Currency::balance_frozen( + &FreezeReason::CapacityStaking.into(), + &account + ), 50 ); @@ -134,7 +140,10 @@ fn stake_increase_stake_amount_works() { ); assert_eq!( - ::Currency::balance_frozen(&FreezeReason::Staked.into(), &account), + ::Currency::balance_frozen( + &FreezeReason::CapacityStaking.into(), + &account + ), 150 ); }); @@ -410,7 +419,7 @@ fn stake_when_there_are_unlocks_sets_lock_correctly() { assert_ok!(Capacity::stake(RuntimeOrigin::signed(staker), target2, 20)); // should all still be locked. - assert_eq!(Balances::balance_frozen(&FreezeReason::Staked.into(), &staker), 40); + assert_eq!(Balances::balance_frozen(&FreezeReason::CapacityStaking.into(), &staker), 40); }) } diff --git a/pallets/capacity/src/tests/unstaking_tests.rs b/pallets/capacity/src/tests/unstaking_tests.rs index fc7674397b..e001cf8b88 100644 --- a/pallets/capacity/src/tests/unstaking_tests.rs +++ b/pallets/capacity/src/tests/unstaking_tests.rs @@ -179,7 +179,7 @@ fn unstaking_everything_reaps_staking_account() { run_to_block(1); // unstake everything assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 20)); - assert_eq!(20u64, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); + assert_eq!(20u64, Balances::balance_frozen(&FreezeReason::CapacityStaking.into(), &staker)); // it should reap the staking account right away assert!(Capacity::get_staking_account_for(&staker).is_none()); diff --git a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs index 82095a4b6a..5346a766cc 100644 --- a/pallets/capacity/src/tests/withdraw_unstaked_tests.rs +++ b/pallets/capacity/src/tests/withdraw_unstaked_tests.rs @@ -47,24 +47,27 @@ fn withdraw_unstaked_correctly_sets_new_lock_state() { run_to_block(1); assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 1)); - assert_eq!(20, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); + assert_eq!(20, Balances::balance_frozen(&FreezeReason::CapacityStaking.into(), &staker)); // thaw period in mock is 2 Epochs * 10 blocks = 20 blocks. run_to_block(21); assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 2)); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); - assert_eq!(19u64, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); + assert_eq!(19u64, Balances::balance_frozen(&FreezeReason::CapacityStaking.into(), &staker)); run_to_block(41); assert_ok!(Capacity::unstake(RuntimeOrigin::signed(staker), target, 3)); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); - assert_eq!(17u64, Balances::balance_frozen(&FreezeReason::Staked.into(), &staker)); + assert_eq!(17u64, Balances::balance_frozen(&FreezeReason::CapacityStaking.into(), &staker)); run_to_block(61); assert_ok!(Capacity::withdraw_unstaked(RuntimeOrigin::signed(staker))); assert_eq!( 14u64, - ::Currency::balance_frozen(&FreezeReason::Staked.into(), &staker) + ::Currency::balance_frozen( + &FreezeReason::CapacityStaking.into(), + &staker + ) ); }) } diff --git a/runtime/frequency/src/lib.rs b/runtime/frequency/src/lib.rs index f8a144d47e..b31ef72702 100644 --- a/runtime/frequency/src/lib.rs +++ b/runtime/frequency/src/lib.rs @@ -217,7 +217,6 @@ pub type Executive = frame_executive::Executive< Runtime, AllPalletsWithSystem, ( - pallet_messages::migration::v2::MigrateToV2, pallet_capacity::migration::v2::MigrateToV2, pallet_capacity::migration::v3::MigrationToV3>, pallet_schemas::migration::v3::MigrateToV3,