Squirrel
be8e626806
Set clippy lints in workspace (requires rust 1.74) ( #2390 )
...
We currently use a bit of a hack in `.cargo/config` to make sure that
clippy isn't too annoying by specifying the list of lints.
There is now a stable way to define lints for a workspace. The only down
side is that every crate seems to have to opt into this so there's a
*few* files modified in this PR.
Dependencies:
- [x] PR that upgrades CI to use rust 1.74 is merged.
---------
Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
Co-authored-by: Branislav Kontur <bkontur@gmail.com >
Co-authored-by: Liam Aharon <liam.aharon@hotmail.com >
2023-12-13 15:11:07 +01:00
Sam Johnson
ac3f14d23b
Tasks: general system for recognizing and executing service work ( #1343 )
...
`polkadot-sdk` version of original tasks PR located here:
https://github.com/paritytech/substrate/pull/14329
Fixes #206
## Status
- [x] Generic `Task` trait
- [x] `RuntimeTask` aggregated enum, compatible with
`construct_runtime!`
- [x] Casting between `Task` and `RuntimeTask` without needing `dyn` or
`Box`
- [x] Tasks Example pallet
- [x] Runtime tests for Tasks example pallet
- [x] Parsing for task-related macros
- [x] Retrofit parsing to make macros optional
- [x] Expansion for task-related macros
- [x] Adds support for args in tasks
- [x] Retrofit tasks example pallet to use macros instead of manual
syntax
- [x] Weights
- [x] Cleanup
- [x] UI tests
- [x] Docs
## Target Syntax
Adapted from
https://github.com/paritytech/polkadot-sdk/issues/206#issue-1865172283
```rust
// NOTE: this enum is optional and is auto-generated by the other macros if not present
#[pallet::task]
pub enum Task<T: Config> {
AddNumberIntoTotal {
i: u32,
}
}
/// Some running total.
#[pallet::storage]
pub(super) type Total<T: Config<I>, I: 'static = ()> =
StorageValue<_, (u32, u32), ValueQuery>;
/// Numbers to be added into the total.
#[pallet::storage]
pub(super) type Numbers<T: Config<I>, I: 'static = ()> =
StorageMap<_, Twox64Concat, u32, u32, OptionQuery>;
#[pallet::tasks_experimental]
impl<T: Config<I>, I: 'static> Pallet<T, I> {
/// Add a pair of numbers into the totals and remove them.
#[pallet::task_list(Numbers::<T, I>::iter_keys())]
#[pallet::task_condition(|i| Numbers::<T, I>::contains_key(i))]
#[pallet::task_index(0)]
pub fn add_number_into_total(i: u32) -> DispatchResult {
let v = Numbers::<T, I>::take(i).ok_or(Error::<T, I>::NotFound)?;
Total::<T, I>::mutate(|(total_keys, total_values)| {
*total_keys += i;
*total_values += v;
});
Ok(())
}
}
```
---------
Co-authored-by: Nikhil Gupta <17176722+gupnik@users.noreply.github.com >
Co-authored-by: kianenigma <kian@parity.io >
Co-authored-by: Nikhil Gupta <>
Co-authored-by: Gavin Wood <gavin@parity.io >
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: gupnik <nikhilgupta.iitk@gmail.com >
2023-12-08 11:10:26 +05:30
Liam Aharon
4a293bc5a2
Enforce consistent and correct toml formatting ( #2518 )
...
Using taplo, fixes all our broken and inconsistent toml formatting and
adds CI to keep them tidy.
If people want we can customise the format rules as described here
https://taplo.tamasfe.dev/configuration/formatter-options.html
@ggwpez, I suggest zepter is used only for checking features are
propagated, and leave formatting for taplo to avoid duplicate work and
conflicts.
TODO
- [x] Use `exclude = [...]` syntax in taplo file to ignore zombienet
tests instead of deleting the dir
---------
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 >
2023-12-01 07:38:02 +00:00
georgepisaltu
7d735fc8ae
Add simple collator election mechanism ( #1340 )
...
Fixes https://github.com/paritytech/polkadot-sdk/issues/106
Port of cumulus PR https://github.com/paritytech/cumulus/pull/2960
This PR adds the ability to bid for collator slots even after the max
number of collators have already registered. This eliminates the first
come, first served mechanism that was in place before.
Key changes:
- added `update_bond` extrinsic to allow registered candidates to adjust
their bonds in order to dynamically control their bids
- added `take_candidate_slot` extrinsic to try to replace an already
existing candidate by bidding more than them
- candidates are now kept in a sorted list in the pallet storage, where
the top `DesiredCandidates` out of `MaxCandidates` candidates in the
list will be selected by the session pallet as collators
- if the candidacy bond is increased through a `set_candidacy_bond`
call, candidates which don't meet the new bond requirements are kicked
# Checklist
- [ ] My PR includes a detailed description as outlined in the
"Description" section above
- [ ] My PR follows the [labeling
requirements](https://github.com/paritytech/polkadot-sdk/blob/master/docs/CONTRIBUTING.md#process )
of this project (at minimum one label for `T` required)
- [ ] I have made corresponding changes to the documentation (if
applicable)
- [ ] I have added tests that prove my fix is effective or that my
feature works (if applicable)
- [ ] If this PR alters any external APIs or interfaces used by
Polkadot, the corresponding Polkadot PR is ready as well as the
corresponding Cumulus PR (optional)
---------
Signed-off-by: georgepisaltu <george.pisaltu@parity.io >
2023-11-14 18:22:30 +02:00
Kian Paimani
35eb133baa
Ensure correct variant count in Runtime[Hold/Freeze]Reason ( #1900 )
...
closes https://github.com/paritytech/polkadot-sdk/issues/1882
## Breaking Changes
This PR introduces a new item to `pallet_balances::Config`:
```diff
trait Config {
++ type RuntimeFreezeReasons;
}
```
This value is only used to check it against `type MaxFreeze`. A similar
check has been added for `MaxHolds` against `RuntimeHoldReasons`, which
is already given to `pallet_balances`.
In all contexts, you should pass the real `RuntimeFreezeReasons`
generated by `construct_runtime` to `type RuntimeFreezeReasons`. Passing
`()` would also work, but it would imply that the runtime uses no
freezes at all.
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-10-24 12:01:04 +02:00
Bastian Köcher
f3bf5c1acd
xcm: Change TypeInfo::path to not include staging (#1948 )
...
The `xcm` crate was renamed to `staging-xcm` to be able to publish it to
crates.io as someone as squatted `xcm`. The problem with this rename is
that the `TypeInfo` includes the crate name which ultimately lands in
the metadata. The metadata is consumed by downstream users like
`polkadot-js` or people building on top of `polkadot-js`. These people
are using the entire `path` to find the type in the type registry. Thus,
their code would break as the type path would now be [`staging_xcm`,
`VersionedXcm`] instead of [`xcm`, `VersionedXcm`]. This pull request
fixes this by renaming the path segment `staging_xcm` to `xcm`.
This requires: https://github.com/paritytech/scale-info/pull/197
---------
Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com >
2023-10-20 11:21:19 +02:00
Chevdor
a30092ab42
Markdown linter ( #1309 )
...
* Add markdown linting
- add linter default rules
- adapt rules to current code
- fix the code for linting to pass
- add CI check
fix #1243
* Fix markdown for Substrate
* Fix tooling install
* Fix workflow
* Add documentation
* Remove trailing spaces
* Update .github/.markdownlint.yaml
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Fix mangled markdown/lists
* Fix captalization issues on known words
2023-09-04 12:02:32 +03:00
Przemek Rzad
bfb241d7f3
Add missing licenses and tune the scanning workflow ( #1288 )
...
* Add missing Cumulus licenses
* Typo
* Add missing Substrate licenses
* Single job checking the sub-repos in steps
* Remove dates
* Remove dates
* Add missing (C)
* Update FRAME UI tests
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Update more UI tests
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-08-30 15:45:49 +03:00
Oliver Tale-Yazdi
dcda0e50f5
Fix build profiles ( #1229 )
...
* Fix build profiles
Closes https://github.com/paritytech/polkadot-sdk/issues/1155
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Manually set version to 1.0.0
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Use workspace repo
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* 'Authors and Edition from workspace
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-08-29 13:39:41 +02:00
Oliver Tale-Yazdi
0400ed9075
Fix features ( #1194 )
...
* Manually fix conflicting ?
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Remove duplicates
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Autofix feature propagation
zepter lint propagate-feature --feature try-runtime --left-side-feature-missing=ignore --workspace --fix --feature-enables-dep="try-runtime:frame-try-runtime"
zepter lint propagate-feature --feature runtime-benchmarks --left-side-feature-missing=ignore --workspace --fix --feature-enables-dep="runtime-benchmarks:frame-benchmarking"
zepter lint propagate-feature --feature std --left-side-feature-missing=ignore --workspace --fix
zepter f f
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Bump zepter
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Add some duplicates
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Revert "Add some duplicates"
This reverts commit c6ce627273881c478f5b34f23d3a67db632dbebf.
* Remove default enabled features
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Bump Zepter
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Bump in correct location 🤦
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* DNM: Add some mistakes
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* DNM: Add some mistakes
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Revert "DNM: Add some mistakes"
This reverts commit d469b3f0ba2aaed5f35f6ff5995f99e682da5800.
* Revert "DNM: Add some mistakes"
This reverts commit d892a73a35cac01e3721bdba74574b88bd04f83c.
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-08-28 22:27:48 +03:00
Alexander Samusev
e49493442a
Add CI for monorepo ( #1145 )
...
* Add CI for monorepo
* fix frame tests
* Format features
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* add note for skipping tests and disable test-linux-stable-all
* Fix tests and compile issues (#1152 )
* Fix feature dependant import
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Bump test timeout
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Remove feature gate
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Add resolver 2
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Remove old lockfile
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Format features
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Fix check-dependency-rules
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* rm test-runtime
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Actually fix script
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* enable cargo-check-each-crate-macos
* Run check-each-crate on 6 machines (#1163 )
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-08-25 16:35:22 +02:00
alvicsam
f441a5fc93
Diener workspacify
...
Signed-off-by: alvicsam <alvicsam@gmail.com >
2023-08-25 11:05:17 +02:00
Oliver Tale-Yazdi
811189174d
Fix experimental aura config and comment tests ( #3057 )
...
* Fix aura config
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Fix Cargo.toml files
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Ignore feature-dependant tests
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Allow dead code
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-08-24 18:39:32 +00:00
Juan
8349c8d18a
Companion: restructure macro related exports ( #3015 )
...
* restructure macro related exports
* restructure macro related exports
* wip
* wip
* update cargo lock
* refactor RuntimeDebug on unincluded segment
* fmt
* Companion: restructure `benchmarking` macro related exports (#3039 )
* wip
* wip
* restructure benchmarking macro related exports
* add cargo lock
---------
Co-authored-by: parity-processbot <>
2023-08-23 11:35:12 +00:00
dependabot[bot]
6b07f1306f
Bump log from 0.4.19 to 0.4.20 ( #3009 )
...
Bumps [log](https://github.com/rust-lang/log ) from 0.4.19 to 0.4.20.
- [Release notes](https://github.com/rust-lang/log/releases )
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-lang/log/compare/0.4.19...0.4.20 )
---
updated-dependencies:
- dependency-name: log
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-15 23:02:53 +02:00
Oliver Tale-Yazdi
6c79b58567
Use same fmt and clippy configs as in Polkadot ( #3004 )
...
* Copy rustfmt.toml from Polkadot master
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Format with new config
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Add Polkadot clippy config
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Update Cargo.lock
Looks like https://github.com/paritytech/polkadot/pull/7611 did not
correctly update the lockfile. Maybe a different Rust Version?!
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-08-14 20:30:12 +00:00
georgepisaltu
9ec80090f5
Use benchmarking::v2 in collator selection pallet ( #2904 )
...
* Use benchmarking v2 in collator selection pallet
Signed-off-by: georgepisaltu <george.pisaltu@parity.io >
* Use extrinsic_call syntax
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Replace `block` with `extrinsic_call` syntax
Signed-off-by: georgepisaltu <george.pisaltu@parity.io >
---------
Signed-off-by: georgepisaltu <george.pisaltu@parity.io >
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-07-20 12:09:12 +00:00
Juan
3513b7e019
Replace Index for Nonce ( #2740 )
...
* replace Index for Nonce
* update lockfile for {"substrate", "polkadot"}
---------
Co-authored-by: parity-processbot <>
2023-07-14 08:46:49 +00:00
gupnik
24d6e46ad0
Moves Block to frame_system instead of construct_runtime and removes Header and BlockNumber ( #2790 )
...
* Fixes
* Removes unused import
* Uses Block and removes BlockNumber/Header from Chain
* Fixes bridges
* Fixes
* Removes unused import
* Fixes build
* Uses correct RelayBlock
* Minor fix
* Fixes glutton-kusama
* Uses correct RelayBlock
* Minor fix
* Fixes benchmark for pallet-bridge-parachains
* Adds appropriate constraints
* Minor fixes
* Removes unused import
* Fixes integrity tests
* Minor fixes
* Updates trait bounds
* Uses custom bound for AsPrimitive
* Fixes trait bounds
* Revert "Fixes trait bounds"
This reverts commit 0b0f42f583f3a616a88afe45fcd06d31e7d9a06f.
* Revert "Uses custom bound for AsPrimitive"
This reverts commit 838e5281adf8b6e9632a2abb9cd550db4ae24126.
* No AsPrimitive trait bound for now
* Removes bounds on Number
* update lockfile for {"substrate", "polkadot"}
* Formatting
* ".git/.scripts/commands/fmt/fmt.sh"
* Minor fix
---------
Co-authored-by: parity-processbot <>
2023-07-13 13:30:28 +00:00
Michal Kucharczyk
94d2e4bc28
GenesisBuild<T,I> deprecated. BuildGenesisConfig added (#2757 )
...
* GenesisBuild<T,I> deprecated. BuildGenesisConfig added
* ".git/.scripts/commands/fmt/fmt.sh"
* integration-tests/emulated: ..Default::default added to genesis configs
* Cargo.lock updated
* Cargo.lock updated
* update lockfile for {"polkadot", "substrate"}
* clippy fixes
* clippy fixes
* clippy fixes again
---------
Co-authored-by: command-bot <>
2023-07-12 12:00:17 +00:00
Bastian Köcher
43a4f0345e
collator-selection: Optimize length decoding ( #2851 )
...
Instead of loading always the entire `Vec` into the runtime to just decode the length, we can
directly use `decode_len` to get this info.
2023-07-11 15:15:04 +02:00
joe petrowski
5a8134029a
Better Handling of Candidates Who Become Invulnerable ( #2801 )
...
* remove candidate when to invulnerable
* fix
* candidates to collators
* make parameters consistent and more reasonable
* add call to kick invulnerable candidates
* factor removal into weight
* fix: use accrue instead of add
* make set_invulnerables non-atomic
* benchmark add_invulnerable to account for candidate removal
* don't remove from candidates with set_invulnerables
* fix bounds on benchmarking
* protect against zero min invulnerables underflow
* extra event and tests
* make candidates/invulnerables self-cleaning on session change
* add integrity test
* unused imports
* make rococo-contracts have 1 collator
2023-07-07 11:18:27 +00:00
dependabot[bot]
c5fd43cee2
Bump scale-info from 2.8.0 to 2.9.0 ( #2815 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.8.0 to 2.9.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/compare/v2.8.0...v2.9.0 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-03 23:52:08 +02:00
dependabot[bot]
ca058e9e8b
Bump scale-info from 2.7.0 to 2.8.0 ( #2768 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.7.0 to 2.8.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/compare/v2.7.0...v2.8.0 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-22 12:23:04 +02:00
Guillaume Yu Thiolliere
c519c78809
minor refactor ( #2733 )
2023-06-14 12:43:41 +00:00
dependabot[bot]
49815cee3c
Bump log from 0.4.18 to 0.4.19 ( #2728 )
...
Bumps [log](https://github.com/rust-lang/log ) from 0.4.18 to 0.4.19.
- [Release notes](https://github.com/rust-lang/log/releases )
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-lang/log/compare/0.4.18...0.4.19 )
---
updated-dependencies:
- dependency-name: log
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-13 12:38:47 +02:00
asynchronous rob
08d0acf10e
Update all uses of pallet-aura to disallow multiple blocks per slot ( #2707 )
...
* Update all uses of pallet-aura to disallow multiple blocks per slot
* use ConstBool
* update lockfile for {"substrate", "polkadot"}
---------
Co-authored-by: parity-processbot <>
2023-06-09 21:47:35 +00:00
Robert La Ferla
2e43d25a4f
Fix max > T::MaxCandidates benchmark warning ( #2716 )
2023-06-09 00:25:28 +02:00
dependabot[bot]
0c5038e556
Bump log from 0.4.17 to 0.4.18 ( #2651 )
...
Bumps [log](https://github.com/rust-lang/log ) from 0.4.17 to 0.4.18.
- [Release notes](https://github.com/rust-lang/log/releases )
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-lang/log/compare/0.4.17...0.4.18 )
---
updated-dependencies:
- dependency-name: log
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-31 04:51:12 +00:00
joe petrowski
23584c7b42
Add Ability to Add/Remove Invulnerable Collators ( #2596 )
...
* add add and remove invulnerable dispatchables
* add migration
* fix benchmarking code
* add weights
* add migration to runtimes
* clippy
* pass SafeCallFilter
* make try-runtime work
* typos
Co-authored-by: Ankan <10196091+Ank4n@users.noreply.github.com >
* better insert and added test
* fix try-runtime update
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <git@kchr.de >
* Update pallets/collator-selection/src/migration.rs
* check events in test
* Update pallets/collator-selection/src/migration.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
* just dispatchresult
* only sp_std for try-runtime
---------
Co-authored-by: Ankan <10196091+Ank4n@users.noreply.github.com >
Co-authored-by: Bastian Köcher <git@kchr.de >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2023-05-29 13:03:48 +00:00
Michal Kucharczyk
4909cbb5b1
pallets: implement Default for GenesisConfig in no_std ( #2624 )
...
* pallets: implement Default for GenesisConfig in no_std
This change is follow-up of: https://github.com/paritytech/substrate/pull/14108
It is a step towards: https://github.com/paritytech/substrate/issues/13334
* ".git/.scripts/commands/fmt/fmt.sh"
* update lockfile for {"substrate", "polkadot"}
---------
Co-authored-by: command-bot <>
2023-05-25 23:03:13 +00:00
Bastian Köcher
490ab62a6d
Companion for: Substrate#13869 ( #2631 )
...
* Companion for: Substrate#13869
https://github.com/paritytech/substrate/pull/13869
* Fix
* Warning
* update lockfile for {"polkadot", "substrate"}
---------
Co-authored-by: parity-processbot <>
2023-05-24 23:19:28 +00:00
dependabot[bot]
5fb86be53f
Bump scale-info from 2.6.0 to 2.7.0 ( #2587 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.6.0 to 2.7.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/commits/v2.7.0 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-17 22:06:40 +02:00
Oliver Tale-Yazdi
299d25ba4b
Fix Clippy ( #2522 )
...
* Import Clippy config from Polkadot
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Auto clippy fix
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* No tabs in comments
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Prefer matches
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Dont drop references
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Trivial
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Refactor
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* fmt
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* add clippy to ci
* Clippy reborrow
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Update client/pov-recovery/src/lib.rs
Co-authored-by: Bastian Köcher <git@kchr.de >
* Update client/pov-recovery/src/lib.rs
Co-authored-by: Bastian Köcher <git@kchr.de >
* Partially revert 'Prefer matches'
Using matches! instead of match does give less compiler
checks as per review from @chevdor.
Partially reverts 8c0609677f3ea040f77fffd5be6facf7c3fec95c
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Update .cargo/config.toml
Co-authored-by: Chevdor <chevdor@users.noreply.github.com >
* Revert revert 💩
Should be fine to use matches! macro since it is an explicit whitelist,
not wildcard matching.
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: alvicsam <alvicsam@gmail.com >
Co-authored-by: Bastian Köcher <git@kchr.de >
Co-authored-by: Chevdor <chevdor@users.noreply.github.com >
Co-authored-by: parity-processbot <>
2023-05-06 08:01:03 +02:00
dependabot[bot]
70bb6badc3
Bump scale-info from 2.5.0 to 2.6.0 ( #2500 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.5.0 to 2.6.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/commits )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-02 10:08:28 +02:00
dependabot[bot]
4781d07bd0
Bump scale-info from 2.4.0 to 2.5.0 ( #2404 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.4.0 to 2.5.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/compare/v2.4.0...v2.5.0 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-30 16:06:58 +02:00
dependabot[bot]
bd5d804644
Bump scale-info from 2.3.1 to 2.4.0 ( #2386 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.3.1 to 2.4.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/compare/v2.3.1...v2.4.0 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-28 11:08:38 +02:00
Gavin Wood
3b8978f1bd
Deprecate Currency: Companion for #12951 ( #2334 )
...
* Fix APIs
* Reflect API changes
* Everything builds
* Fixes
* Fixes
* Update Cargo.toml
* Fixes
* Fixes
* No networks use freezes/holds
* update lockfile for {"polkadot", "substrate"}
* Fix test
ED cannot be zero anymore.
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Fix test
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: parity-processbot <>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-03-20 16:52:21 +00:00
Vivek Pandya
9f09109eaf
Remove use of trait Store ( #2286 )
...
* Remove use of Store trait from xcmp-queue pallet
* Remove Store trait usage from dmp-queue pallet
* Remove Store trait usage from parachain-system pallet
* Remove use of Store trait from cumulus
* Run cargo fmt
2023-03-13 22:30:20 +01:00
Oliver Tale-Yazdi
70a0864e4c
Migrate to Weight::from_parts ( #2245 )
...
* Migrate to from_parts
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Fix remaining files
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* cargo update -p polkadot-primitives
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* cargo update -p sp-io
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* Use Master Cargo.lock
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* cargo update -p polkadot-primitives
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
* cargo update -p sp-io
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2023-03-03 12:47:23 +00:00
Muharem Ismailov
0494cefc72
Update benchmark's successful origin api ( #2122 )
...
* Update benchmark's successful origin api
* update lockfile for {"substrate", "polkadot"}
---------
Co-authored-by: parity-processbot <>
2023-01-29 23:34:59 +00:00
Bastian Köcher
51f1833cce
Companion: Remove uncles related code ( #2126 )
...
* Companion: Remove `uncles` related code
https://github.com/paritytech/substrate/pull/13216
* update lockfile for {"polkadot", "substrate"}
---------
Co-authored-by: parity-processbot <>
2023-01-29 22:17:24 +00:00
Squirrel
fbce6fe120
Expect less chaos: use explicit call indices ( #1984 )
...
* Expect less chaos: set call index explicitly.
* mark test pallet as dev mode so explicit call indicies are not required.
* Fix 'dev_mode' syntax
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io >
2022-12-20 12:04:56 +00:00
dependabot[bot]
0b228b9e68
Bump scale-info from 2.3.0 to 2.3.1 ( #1978 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.3.0 to 2.3.1.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/compare/v2.3.0...v2.3.1 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-16 09:50:50 +01:00
Branislav Kontur
c3df7db394
BridgeHubKusama - initial setup - (chain_spec + basic runtime without any bridging pallets) ( #1764 )
...
* [BridgeHub] Setup Rococo backbone parachain
* [BridgeHub] Setup Wococo parachain backbone (reused from Rococo)
[Bridge-Backport] Rebase-fix
BridgeHub] Added zombienet startup tomls for Rococo/Wococo
Fix typo
* [BridgeHub] Added chain_spec for live Rococo/Wococo
* [BridgeHub] Clean bridge-hub-rococo runtime
* [BridgeHub] Add bridge-hub-rococo to CI pipelines
* [BridgeHub] Added bridge-hub-kusama - empty runtime/chain_spec setup
* Fixes
* Fixes for BH
* Fixes for other runtimes - align all
* Fixes - const
* Fixes const
* Fixes
* Fix kusama-local
* Sample zombienet runs
* Fixes
* Fixes for benchmarking
* Fixes CI
* Fixes
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs frame_system
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_collator_selection
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_balances
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_session
* Fixes name
* Fixes readme
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_timestamp
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs cumulus_pallet_xcmp_queue
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_collator_selection
* Fixes
* Fixes
* rustfmt
* Fixes
* Added pallet_utility/pallet_multisig
* Blind try for regex pr-custom-review.yml (added bridge-hub-kusama + collectives-polkadot)
* Fixes
* Fixes
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_utility
* ".git/.scripts/bench-bot.sh" pallet bridge-hub-kusama bridge-hubs pallet_multisig
* Trying to fix sed expression?
* Added license headers + correct "DAG:" desc
Co-authored-by: command-bot <>
2022-12-02 14:06:39 +01:00
dependabot[bot]
8dbab74430
Bump scale-info from 2.2.0 to 2.3.0 ( #1809 )
...
Bumps [scale-info](https://github.com/paritytech/scale-info ) from 2.2.0 to 2.3.0.
- [Release notes](https://github.com/paritytech/scale-info/releases )
- [Changelog](https://github.com/paritytech/scale-info/blob/master/CHANGELOG.md )
- [Commits](https://github.com/paritytech/scale-info/commits/v2.3.0 )
---
updated-dependencies:
- dependency-name: scale-info
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-01 13:18:24 +01:00
Kai
4f632887eb
only register MaxCandidates-1 candidates initially ( #1714 )
2022-10-03 13:00:53 +00:00
Branislav Kontur
fd5571647c
Removed unused deps with cargo machete ( #1680 )
...
* Removed unused deps with `cargo machete`
* Removed unused deps with `cargo machete` for parachain-template
2022-09-29 13:44:08 +02:00
dependabot[bot]
5f827884aa
Bump serde from 1.0.144 to 1.0.145 ( #1677 )
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.144 to 1.0.145.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.144...v1.0.145 )
---
updated-dependencies:
- dependency-name: serde
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-27 14:41:43 +00:00
Sergej Sakac
d53444ef81
Rename Origin ( #1628 )
...
* Rename Origin
* more renaming
* fixes
* fix errors
* last fix?
* rename
* Update mock.rs
* update lockfile for {"polkadot", "substrate"}
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
Co-authored-by: parity-processbot <>
2022-09-20 23:17:31 +00:00