- Jul 15, 2024
-
-
Jun Jiang authored
It says `Will be removed after July 2023` but that's not true
--------- Co-authored-by:Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
- Jul 12, 2024
-
-
dharjeezy authored
Part of: https://github.com/paritytech/polkadot-sdk/issues/239 Polkadot address: 12GyGD3QhT4i2JJpNzvMf96sxxBLWymz4RdGCxRH5Rj5agKW --------- Signed-off-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Bastian Köcher authored
This improves logging in the xcm-executor to have better debugability when executing a XCM message.
-
- Jul 10, 2024
-
-
Kian Paimani authored
Explains one of the annoying parts of FRAME storage that we have seen multiple times in PBA everyone gets stuck on. I have not updated the other two templates for now, and only reflected it in the parachain template. That can happen in a follow-up. - [x] Update possible answers in SE about the same topic. --------- Co-authored-by:
Serban Iorga <serban@parity.io> Co-authored-by: command-bot <>
-
- Jul 07, 2024
-
-
Muharem Ismailov authored
Functions `can_decrease` and `can_increase` do not return successful consequence results for assets undergoing destruction; instead, they return the `UnknownAsset` consequence variant. This update aligns their behavior with similar functions, such as `reducible_balance`, `increase_balance`, `decrease_balance`, and `burn`, which return an `AssetNotLive` error for assets in the process of being destroyed.
-
- Jul 06, 2024
-
-
Deepak Chaudhary authored
### ISSUE Link to the issue: https://github.com/paritytech/polkadot-sdk/issues/3326 cc @muraca Deliverables - [Deprecation] remove pallet::getter usage from all pallet-babe ### Test Outcomes ___ Successful tests by running `cargo test -p pallet-babe --features runtime-benchmarks` running 32 tests test mock::__pallet_staking_reward_curve_test_module::reward_curve_piece_count ... ok test mock::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test mock::test_genesis_config_builds ... ok 2024-06-28T17:02:11.158812Z ERROR runtime::storage: Corrupted state at `0x1cb6f36e027abb2091cfb5110ab5087f9aab0a5b63b359512deee557c9f4cf63`: Error { cause: Some(Error { cause: None, desc: "Could not decode `NextConfigDescriptor`, variant doesn't exist" }), desc: "Could not decode `Option::Some(T)`" } 2024-06-28T17:02:11.159752Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::add_epoch_configurations_migration_works ... ok test tests::author_vrf_output_for_secondary_vrf ... ok test benchmarking::bench_check_equivocation_proof ... ok 2024-06-28T17:02:11.160537Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::can_estimate_current_epoch_progress ... ok test tests::author_vrf_output_for_primary ... ok test tests::authority_index ... ok 2024-06-28T17:02:11.162327Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::empty_randomness_is_correct ... ok test tests::check_module ... ok 2024-06-28T17:02:11.163492Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::current_slot_is_processed_on_initialization ... ok test tests::can_enact_next_config ... ok 2024-06-28T17:02:11.164987Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.165007Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::can_predict_next_epoch_change ... ok test tests::first_block_epoch_zero_start ... ok test tests::initial_values ... ok 2024-06-28T17:02:11.168430Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.168685Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.170982Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.171220Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::only_root_can_enact_config_change ... ok test tests::no_author_vrf_output_for_secondary_plain ... ok test tests::can_fetch_current_and_next_epoch_data ... ok 2024-06-28T17:02:11.172960Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::report_equivocation_has_valid_weight ... ok 2024-06-28T17:02:11.173873Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.177084Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::report_equivocation_after_skipped_epochs_works ... 2024-06-28T17:02:11.177694Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.177703Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.177925Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.177927Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 ok 2024-06-28T17:02:11.179678Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.181446Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.183665Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.183874Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.185732Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.185951Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.189332Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.189559Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.189587Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::generate_equivocation_report_blob ... ok test tests::disabled_validators_cannot_author_blocks - should panic ... ok 2024-06-28T17:02:11.190552Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.192279Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.194735Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.196136Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.197240Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::skipping_over_epochs_works ... ok 2024-06-28T17:02:11.202783Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.202846Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.203029Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.205242Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::tracks_block_numbers_when_current_and_previous_epoch_started ... ok 2024-06-28T17:02:11.208965Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::report_equivocation_current_session_works ... ok test tests::report_equivocation_invalid_key_owner_proof ... ok 2024-06-28T17:02:11.216431Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 2024-06-28T17:02:11.216855Z ERROR runtime::timestamp: `pallet_timestamp::UnixTime::now` is called at genesis, invalid value returned: 0 test tests::report_equivocation_validate_unsigned_prevents_duplicates ... ok test tests::report_equivocation_invalid_equivocation_proof ... ok test tests::valid_equivocation_reports_dont_pay_fees ... ok test tests::report_equivocation_old_session_works ... ok test mock::__pallet_staking_reward_curve_test_module::reward_curve_precision ... ok test result: ok. 32 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.20s Doc-tests pallet-babe running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s --- Polkadot Address: 16htXkeVhfroBhL6nuqiwknfXKcT6WadJPZqEi2jRf9z4XPY
-
Deepak Chaudhary authored
### ISSUE Link to the issue: https://github.com/paritytech/polkadot-sdk/issues/3326 cc @muraca Deliverables - [Deprecation] remove pallet::getter usage from pallet-transaction-storage ### Test Outcomes ___ cargo test -p pallet-transaction-storage --features runtime-benchmarks running 9 tests test mock::test_genesis_config_builds ... ok test tests::burns_fee ... ok test mock::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test tests::discards_data ... ok test tests::renews_data ... ok test benchmarking::bench_renew ... ok test benchmarking::bench_store ... ok test tests::checks_proof ... ok test benchmarking::bench_check_proof_max has been running for over 60 seconds test benchmarking::bench_check_proof_max ... ok test result: ok. 9 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 72.57s Doc-tests pallet-transaction-storage running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s --- Polkadot Address: 16htXkeVhfroBhL6nuqiwknfXKcT6WadJPZqEi2jRf9z4XPY
-
Tomás Senovilla Polo authored
Hi! In the course of a talk with @shawntabrizi in Singapore, we realized the documentation related to freeze balances' a little bit confusing. It stated that a frozen amount is released at some specified block number, which isn't true in general. This PR fixes that typo and further specifies that the frozen balance may exceed the available balance, according to what we learned at the PBA. This feature was not specified in the documentation AFAIK. This is the first time I submit something to the polkadot SDK repo, so please feel free to rephrase the docs I added in case I messed up! --------- Co-authored-by:
Shawn Tabrizi <shawntabrizi@gmail.com> Co-authored-by: command-bot <>
-
- Jul 05, 2024
-
-
Deepak Chaudhary authored
### ISSUE Link to the issue: https://github.com/paritytech/polkadot-sdk/issues/3326 cc @muraca Deliverables - [Deprecation] remove pallet::getter usage from all pallet-vesting ### Test Outcomes ___ Successful tests by running `cargo test -p pallet-vesting --features runtime-benchmarks` running 45 tests test benchmarking::bench_force_vested_transfer ... ok test benchmarking::bench_vest_other_locked ... ok test mock::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test benchmarking::bench_not_unlocking_merge_schedules ... ok test benchmarking::bench_unlocking_merge_schedules ... ok test mock::test_genesis_config_builds ... ok test tests::build_genesis_has_storage_version_v1 ... ok test tests::check_vesting_status ... ok test benchmarking::bench_force_remove_vesting_schedule ... ok test tests::check_vesting_status_for_multi_schedule_account ... ok test benchmarking::bench_vest_locked ... ok test tests::extra_balance_should_transfer ... ok test tests::generates_multiple_schedules_from_genesis_config ... ok test tests::force_vested_transfer_allows_max_schedules ... ok test tests::force_vested_transfer_correctly_fails ... ok test tests::force_vested_transfer_works ... ok test tests::liquid_funds_should_transfer_with_delayed_vesting ... ok test tests::merge_finished_and_ongoing_schedules ... ok test benchmarking::bench_vest_unlocked ... ok test tests::merge_finished_and_yet_to_be_started_schedules ... ok test tests::merge_finishing_schedules_does_not_create_a_new_one ... ok test tests::merge_ongoing_and_yet_to_be_started_schedules ... ok test benchmarking::bench_vest_other_unlocked ... ok test tests::merge_ongoing_schedules ... ok test tests::merge_schedules_that_have_not_started ... ok test tests::merge_vesting_handles_per_block_0 ... ok test tests::per_block_works ... ok test tests::merge_schedules_throws_proper_errors ... ok test tests::multiple_schedules_from_genesis_config_errors - should panic ... ok test tests::merging_shifts_other_schedules_index ... ok test tests::non_vested_cannot_vest_other ... ok test tests::unvested_balance_should_not_transfer ... ok test tests::non_vested_cannot_vest ... ok test tests::vested_balance_should_transfer ... ok test tests::remove_vesting_schedule ... ok test tests::vested_transfer_correctly_fails ... ok test tests::vested_balance_should_transfer_with_multi_sched ... ok test tests::vested_balance_should_transfer_using_vest_other ... ok test tests::vested_transfer_less_than_existential_deposit_fails ... ok test tests::vesting_info_ending_block_as_balance_works ... ok test tests::vesting_info_validate_works ... ok test tests::vested_balance_should_transfer_using_vest_other_with_multi_sched ... ok test tests::vested_transfer_works ... ok test tests::vested_transfer_allows_max_schedules ... ok test benchmarking::bench_vested_transfer ... ok test result: ok. 45 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.10s --- Polkadot Address: 16htXkeVhfroBhL6nuqiwknfXKcT6WadJPZqEi2jRf9z4XPY
-
- Jul 03, 2024
-
-
polka.dom authored
As per #3326, removes pallet::getter macro usage from the pallet-insecure-randomness-collective-flip. The syntax `StorageItem::<T, I>::get()` should be used instead. Explicitly implements the getters that were removed as well, following #223 Also makes the storage values public and converts some syntax to turbo cc @muraca --------- Co-authored-by:
Bastian Köcher <git@kchr.de> Co-authored-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
-
Deepak Chaudhary authored
### ISSUE Link to the issue: https://github.com/paritytech/polkadot-sdk/issues/3326 cc @muraca Deliverables - [Deprecation] remove pallet::getter usage from all pallet-tips ### Test Outcomes ___ Successful tests by running `cargo test -p pallet-tips --features runtime-benchmarks` running 26 tests test tests::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test benchmarking::bench_retract_tip ... ok test tests::equal_entries_invariant ... ok test benchmarking::bench_tip ... ok test tests::finders_fee_invariant ... ok test tests::genesis_config_works ... ok test tests::genesis_funding_works ... ok test benchmarking::bench_slash_tip ... ok test tests::reasons_invariant ... ok test benchmarking::bench_report_awesome ... ok test tests::close_tip_works ... ok test tests::report_awesome_from_beneficiary_and_tip_works ... ok test tests::test_genesis_config_builds ... ok test tests::test_last_reward_migration ... ok test benchmarking::bench_tip_new ... ok test benchmarking::bench_close_tip ... ok test tests::test_migration_v4 ... ok test tests::slash_tip_works ... ok test tests::report_awesome_and_tip_works_second_instance ... ok test tests::report_awesome_and_tip_works ... ok test tests::tip_changing_works ... ok test tests::zero_base_deposit_prohibited - should panic ... ok test tests::tip_median_calculation_works ... ok test tests::tip_new_cannot_be_used_twice ... ok test tests::tip_large_should_fail ... ok test tests::retract_tip_works ... ok test result: ok. 26 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.02s Doc-tests pallet_tips running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s --- Polkadot Address: 16htXkeVhfroBhL6nuqiwknfXKcT6WadJPZqEi2jRf9z4XPY --------- Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Ankan authored
Related: https://github.com/paritytech/polkadot-sdk/pull/4804. Fixes the try state error in Westend: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/6564522. Passes here: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/6580393 ## Context Currently in Kusama and Polkadot, an account can do both, directly stake, and join a pool. With the migration of pools to `DelegateStake` (See https://github.com/paritytech/polkadot-sdk/pull/3905), the funds of pool members are locked in a different way than for direct stakers. - Pool member funds uses `holds`. - `pallet-staking` uses deprecated locks (analogous to freeze) which can overlap with holds. An existing delegator can stake directly since pallet-staking only uses free balance. But once an account becomes staker, we cannot allow them to be delegator as this risks an account to use already staked (frozen) funds in pools. When an account gets into a situation where it is participating in both pools and staking, it would no longer would be able to add any extra bond to the pool but they can still withdraw funds. ## Changes - Add test for the above scenario. - Removes the assumption that a delegator cannot be a staker.
-
Serban Iorga authored
Related to https://github.com/paritytech/polkadot-sdk/issues/4523 Extracting part of https://github.com/paritytech/polkadot-sdk/pull/1903 (credits to @Lederstrumpf for the high-level strategy), but also introducing significant adjustments both to the approach and to the code. The main adjustment is the fact that the `ForkVotingProof` accepts only one vote, compared to the original version which accepted a `vec![]`. With this approach more calls are needed in order to report multiple equivocated votes on the same commit, but it simplifies a lot the checking logic. We can add support for reporting multiple signatures at once in the future. There are 2 things that are missing in order to consider this issue done, but I would propose to do them in a separate PR since this one is already pretty big: - benchmarks/computing a weight for the new extrinsic (this wasn't present in https://github.com/paritytech/polkadot-sdk/pull/1903 either) - exposing an API for generating the ancestry proof. I'm not sure if we should do this in the Mmr pallet or in the Beefy pallet Co-authored-by:
Robert Hambrock <roberthambrock@gmail.com> --------- Co-authored-by:
Adrian Catangiu <adrian@parity.io>
-
gupnik authored
This PR fixes the unused warnings in `frame-support-procedural` crate, raised by the latest stable rust release.
-
- Jul 01, 2024
-
-
polka.dom authored
As per #3326 , removes pallet::getter macro usage from pallet-membership. The syntax StorageItem::<T, I>::get() should be used instead. Also converts some syntax to turbo and reimplements the removed getters, following #223 cc @muraca --------- Co-authored-by:
Dónal Murray <donalm@seadanda.dev> Co-authored-by:
Kian Paimani <5588131+kianenigma@users.noreply.github.com>
-
- Jun 27, 2024
-
-
Serban Iorga authored
Ensure that the key ownership proof doesn't contain duplicate or unneeded nodes. We already have these checks for the bridge messages proof. Just making them more generic and performing them also for the key ownership proof. --------- Co-authored-by:
Adrian Catangiu <adrian@parity.io>
-
Bastian Köcher authored
Co-authored-by:
gupnik <mail.guptanikhil@gmail.com>
-
- Jun 26, 2024
-
-
Muharem Ismailov authored
Introduce an optional auto-increment setup for the IDs of new assets. --------- Co-authored-by:
joe petrowski <25483142+joepetrowski@users.noreply.github.com> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Anton Vilhelm Ásgeirsson authored
Enables the `request_revenue` and `notify_revenue` parts of [RFC 5 - Coretime Interface](https://polkadot-fellows.github.io/RFCs/approved/0005-coretime-interface.html) TODO: - [x] Finish first pass at implementation - [x] ~~Need to explicitly burn uncollected and dropped revenue~~ Accumulate it instead - [x] Confirm working on zombienet - [x] Tests - [ ] Enable XCM `request_revenue` sending on Coretime chain on Kusama and Polkadot Fixes: #2209 --------- Co-authored-by:
Dmitry Sinyavin <dmitry.sinyavin@parity.io> Co-authored-by: command-bot <> Co-authored-by:
s0me0ne-unkn0wn <48632512+s0me0ne-unkn0wn@users.noreply.github.com> Co-authored-by:
Dónal Murray <donal.murray@parity.io> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Oliver Tale-Yazdi authored
Add a `promote_fast` extrinsic to the `core-fellowship` pallet to allow promotions that ignore the promotion cooldown. It comes with a new `FastPromoteOrigin`. Supersedes https://github.com/paritytech/polkadot-sdk/pull/4778 --------- Signed-off-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by:
joe petrowski <25483142+joepetrowski@users.noreply.github.com> Co-authored-by: command-bot <>
-
Muharem Ismailov authored
Introduce migration type to remove data associated with a specific storage of a pallet. Based on existing `RemovePallet` migration type. Required for https://github.com/paritytech/polkadot-sdk/pull/3820 --------- Co-authored-by:
Liam Aharon <liam.aharon@hotmail.com> Co-authored-by:
Kian Paimani <5588131+kianenigma@users.noreply.github.com>
-
- Jun 25, 2024
-
-
gupnik authored
Fixes https://github.com/paritytech/polkadot-sdk/issues/4723. Also, closes https://github.com/paritytech/polkadot-sdk/issues/4622 As stated in the linked issue, this PR adds the ability to use a real rust type for pallet alias in the new `runtime` macro: ```rust #[runtime::pallet_index(0)] pub type System = frame_system::Pallet<Runtime>; ``` Please note that the current syntax still continues to be supported. CC: @shawntabrizi @Kianenigma --------- Co-authored-by: command-bot <> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
- Jun 24, 2024
-
-
dashangcun authored
Signed-off-by:
dashangcun <jchaodaohang@foxmail.com> Co-authored-by:
dashangcun <jchaodaohang@foxmail.com>
-
Muharem Ismailov authored
Remove unused config parameters `ApproveOrigin` and `OnSlash` from the treasury pallet. Add `OnSlash` config parameter to the bounties and tips pallets. part of https://github.com/paritytech/polkadot-sdk/issues/3800
-
Muharem Ismailov authored
Configuration for the maximum member count per rank, with the option for no limit.
-
Oliver Tale-Yazdi authored
After preparing in https://github.com/paritytech/polkadot-sdk/pull/4633, we can lift also all internal dependencies up to the workspace. This does not actually change anything, but uses `workspace = true` for all dependencies. You can check it with: ```bash git checkout -q $(git merge-base oty-lift-all-deps origin/master) cargo tree -e features > master.out git checkout -q oty-lift-all-deps cargo tree -e features > new.out diff master.out new.out ``` It did not yet lift 100% of dependencies, some inside of `target.*` or some that had conflicting aliases introduced recently. But i will do these together in a follow-up with CI checks. Can be reproduced with [zepter](https://github.com/ggwpez/zepter/): `zepter transpose d lift-to-workspace "regex:.*" --version-resolver highest --skip-package "polkadot-sdk" --ignore-errors --fix`. --------- Signed-off-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
-
Bastian Köcher authored
When `min_enactment_period == 0` and `desired == At(n)` where `n` is smaller than the current block number, the scheduling would fail. This happened for example here: https://collectives.subsquare.io/fellowship/referenda/126 To ensure that this doesn't happen again, ensure that the earliest allowed block is at minimum the next block.
-
Deepak Chaudhary authored
### ISSUE Link to the issue: https://github.com/paritytech/polkadot-sdk/issues/1143 Deliverables - Implement trait `ContainsLengthBound` for pallet-membership ### Test Outcomes ___ Successful tests by running `cargo test -p pallet-membership --features runtime-benchmarks` running 22 tests test tests::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test benchmark::bench_clear_prime ... ok test tests::add_member_works ... ok test tests::change_key_with_same_caller_as_argument_changes_nothing ... ok test tests::change_key_works ... ok test benchmark::bench_set_prime ... ok test benchmark::bench_remove_member ... ok test benchmark::bench_change_key ... ok test tests::change_key_works_that_does_not_change_order ... ok test benchmark::bench_reset_members ... ok test benchmark::bench_add_member ... ok test tests::genesis_build_panics_with_duplicate_members - should panic ... ok test benchmark::bench_swap_member ... ok test tests::query_membership_works ... ok test tests::prime_member_works ... ok test tests::test_genesis_config_builds ... ok test tests::remove_member_works ... ok test tests::migration_v4 ... ok test tests::swap_member_with_identical_arguments_changes_nothing ... ok test tests::swap_member_works_that_does_not_change_order ... ok test tests::swap_member_works ... ok test tests::reset_members_works ... ok test result: ok. 22 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.01s Doc-tests pallet_membership running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s --------- Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Oliver Tale-Yazdi authored
Signed-off-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
-
- Jun 23, 2024
-
-
polka.dom authored
As per #3326, removes pallet::getter macro usage from the pallet-elections-phragmen. The syntax `StorageItem::<T, I>::get()` should be used instead. cc @muraca --------- Co-authored-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
-
- Jun 22, 2024
-
-
Muharem Ismailov authored
`Consideration` trait generic over `Footprint` and indicates zero cost for a give footprint. `Consideration` trait is generic over `Footprint` (currently defined over the type with the same name). This makes it possible to setup a custom footprint (e.g. current number of proposals in the storage). `Consideration::new` and `Consideration::update` return an `Option<Self>` instead `Self`, this make it possible to indicate a no cost for a specific footprint (e.g. if current number of proposals in the storage < max_proposal_count / 2 then no cost). These cases need to be handled for https://github.com/paritytech/polkadot-sdk/pull/3151
-
- Jun 21, 2024
-
-
Pablo Andrés Dorado Suárez authored
Closes #3342 cc/ @liamaharon TODO: - [x] Improve docs. - [x] Define public interface (See #3342). In case we define public calls to the pallet implementation: - Implement public calls. - Benchmarks. polkadot address: 12gMhxHw8QjEwLQvnqsmMVY1z5gFa54vND74aMUbhhwN6mJR --------- Co-authored-by: command-bot <> Co-authored-by:
Liam Aharon <liam.aharon@hotmail.com>
-
José Molina Colmenero authored
This PR: - Adds extra functionality to pallet-nfts's `BenchmarkHelper` to provide signers and sign message. - Abstracts away the explicit link with Sr25519 schema in the benchmarks, allowing parachains with a different one to be able to run them and calculate the weights. - Adds a default implementation for the empty tuple that leaves the code equivalent.
-
- Jun 18, 2024
-
-
Tin Chung authored
# ISSUE - Link to issue: https://github.com/paritytech/polkadot-sdk/issues/3617 # Description > Any set parameter / update config call with multiple arguments should have each argument to be an Option field. Please put this to some best practice document. This allows new update config call does not need to duplicate the fields that does not need to update. It also makes concurrent votes of update call possible, otherwise there will be race condition. It also helps with review such proposal otherwise reviewers need to check the other fields should remain the same. - [ ] Concurrent call & race condition testing - [x] Each argument of the `ParamsType` is an `Option` field. Introduce through ```rust pub type PartialParamsOf<T, I> = ParamsType<Option<<T as Config<I>>::Balance>, Option<BlockNumberFor<T>>, RANK_COUNT>; ``` # Outcome ```rust let params = ParamsType { active_salary: [None; 9], passive_salary: [None; 9], demotion_period: [None, Some(10), None, None, None, None, None, None, None], min_promotion_period: [None; 9], offboard_timeout: Some(1), }; CoreFellowship::set_partial_params(signed(2), Box::new(params.clone())), ``` Test coverage ```diff running 21 tests test tests::unit::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test tests::unit::basic_stuff ... ok test tests::integration::test_genesis_config_builds ... ok test tests::integration::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test tests::unit::auto_demote_offboard_works ... ok test tests::unit::auto_demote_works ... ok test tests::unit::get_salary_works ... ok test tests::unit::active_changing_get_salary_works ... ok test tests::integration::swap_bad_noops ... ok test tests::unit::promote_postpones_auto_demote ... ok test tests::unit::infinite_demotion_period_works ... ok test tests::unit::proof_postpones_auto_demote ... ok test tests::unit::induct_works ... ok test tests::unit::set_params_works ... ok test tests::unit::test_genesis_config_builds ... ok test tests::unit::offboard_works ... ok test tests::unit::sync_works ... ok + test tests::unit::set_partial_params_works ... ok test tests::integration::swap_exhaustive_works ... ok test tests::unit::promote_works ... ok test tests::integration::swap_simple_works ... ok test result: ok. 21 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.01s Doc-tests pallet_core_fellowship running 0 tests test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s ``` polkadot address: 19nSqFQorfF2HxD3oBzWM3oCh4SaCRKWt1yvmgaPYGCo71J --------- Co-authored-by:
Dónal Murray <donalm@seadanda.dev> Co-authored-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Tin Chung authored
# ISSUE - Link to the issue: https://github.com/paritytech/polkadot-sdk/issues/3800 # Deliverables - [x] remove deprecated calls; (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/d579b673) - [x] set explicit coded indexes for Error and Event enums, remove unused variants and keep the same indexes for the rest; (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/d579b673) - [x] remove unused Config's type parameters; (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/d579b673) - [x] remove irrelevant tests and adopt relevant using old api; (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/d579b673) - [x] remove benchmarks for removed calls; (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/1a3d5f1f) - [x] prdoc (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/d579b673) - [x] remove deprecated methods from the `treasury/README.md` and add up-to-date dispatchable functions documentation (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/d579b673) - [x] remove deprecated weight functions (https://github.com/paritytech/polkadot-sdk/pull/3820/commits/8f74134b) > ### Separated to other issues > - [ ] remove storage items like Proposals and ProposalCount, that are not used anymore Adjust all treasury pallet instances within polkadot-sdk - [x] `pallet_bounty`, `tip`, `child_bounties`: https://github.com/openguild-labs/polkadot-sdk/pull/3 - [x] Remove deprecated treasury weight functions used in Westend and Rococo runtime `collective-westend`, `collective-rococo` Add migration for westend and rococo to clean the data from removed storage items - [ ] https://github.com/paritytech/polkadot-sdk/pull/3828 # Test Outcomes Successful tests by running `cargo test --features runtime-benchmarks` ``` running 38 tests test tests::__construct_runtime_integrity_test::runtime_integrity_tests ... ok test benchmarking::benchmarks::bench_check_status ... ok test benchmarking::benchmarks::bench_payout ... ok test benchmarking::benchmarks::bench_spend_local ... ok test tests::accepted_spend_proposal_enacted_on_spend_period ... ok test benchmarking::benchmarks::bench_spend ... ok test tests::accepted_spend_proposal_ignored_outside_spend_period ... ok test benchmarking::benchmarks::bench_void_spend ... ok test benchmarking::benchmarks::bench_remove_approval ... ok test tests::genesis_funding_works ... ok test tests::genesis_config_works ... ok test tests::inexistent_account_works ... ok test tests::minting_works ... ok test tests::check_status_works ... ok test tests::payout_retry_works ... ok test tests::pot_underflow_should_not_diminish ... ok test tests::remove_already_removed_approval_fails ... ok test tests::spend_local_origin_permissioning_works ... ok test tests::spend_valid_from_works ... ok test tests::spend_expires ... ok test tests::spend_works ... ok test tests::test_genesis_config_builds ... ok test tests::spend_payout_works ... ok test tests::spend_local_origin_works ... ok test tests::spend_origin_works ... ok test tests::spending_local_in_batch_respects_max_total ... ok test tests::spending_in_batch_respects_max_total ... ok test tests::try_state_proposals_invariant_2_works ... ok test tests::try_state_proposals_invariant_1_works ... ok test tests::try_state_spends_invariant_2_works ... ok test tests::try_state_spends_invariant_1_works ... ok test tests::treasury_account_doesnt_get_deleted ... ok test tests::try_state_spends_invariant_3_works ... ok test tests::unused_pot_should_diminish ... ok test tests::void_spend_works ... ok test tests::try_state_proposals_invariant_3_works ... ok test tests::max_approvals_limited ... ok test benchmarking::benchmarks::bench_on_initialize_proposals ... ok test result: ok. 38 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.08s Doc-tests pallet_treasury running 2 tests test substrate/frame/treasury/src/lib.rs - (line 52) ... ignored test substrate/frame/treasury/src/lib.rs - (line 79) ... ignored test result: ok. 0 passed; 0 failed; 2 ignored; 0 measured; 0 filtered out; finished in 0.00s ``` polkadot address: 19nSqFQorfF2HxD3oBzWM3oCh4SaCRKWt1yvmgaPYGCo71J
-
Andrei Sandu authored
Glutton currently is useful mostly for stress testing relay chain validators. It is unusable for testing the collator networking and block announcement and import scenarios. This PR resolves that by improving glutton pallet to also buff up the blocks, up to the runtime configured `BlockLength`. ### How it works Includes an additional inherent in each parachain block. The `garbage` argument passed to the inherent is filled with trash data. It's size is computed by applying the newly introduced `block_length` percentage to the maximum block length for mandatory dispatch class. After https://github.com/paritytech/polkadot-sdk/pull/4765 is merged, the length of inherent extrinsic will be added to the total block proof size. The remaining weight is burnt in `on_idle` as configured by the `storage` percentage parameter. TODO: - [x] PRDoc - [x] Readme update - [x] Add tests --------- Signed-off-by:
Andrei Sandu <andrei-mihail@parity.io>
-
- Jun 17, 2024
-
-
Kantapat chankasem authored
this pr is a part of #3326 --------- Co-authored-by:
Kian Paimani <5588131+kianenigma@users.noreply.github.com> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
Ankan authored
-
- Jun 14, 2024
-
-
Andrei Sandu authored
Fix https://github.com/paritytech/polkadot-sdk/issues/4743 which allows us to remove the defensive limit on pov size in Cumulus after relay chain gets upgraded with these changes. Also add unit test to ensure `CheckWeight` - `StorageWeightReclaim` integration works. TODO: - [x] PRDoc - [x] Add a len to all the other tests in storage weight reclaim and call `CheckWeight::pre_dispatch` --------- Signed-off-by:
Andrei Sandu <andrei-mihail@parity.io>
-
- Jun 13, 2024
-
-
Branislav Kontur authored
This PR aligns the settings for `MaxFreezes`, `RuntimeFreezeReason`, and `FreezeIdentifier`. #### Future work and improvements https://github.com/paritytech/polkadot-sdk/issues/2997 (remove `MaxFreezes` and `FreezeIdentifier`)
-