Commit Graph

7174 Commits

Author SHA1 Message Date
dependabot[bot] fa33efedcb Bump ss58-registry from 1.29.0 to 1.34.0 (#12659)
Bumps [ss58-registry](https://github.com/paritytech/ss58-registry) from 1.29.0 to 1.34.0.
- [Release notes](https://github.com/paritytech/ss58-registry/releases)
- [Changelog](https://github.com/paritytech/ss58-registry/blob/main/CHANGELOG.md)
- [Commits](https://github.com/paritytech/ss58-registry/compare/v1.29.0...v1.34.0)

---
updated-dependencies:
- dependency-name: ss58-registry
  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-09 19:31:41 +00:00
Robert Hambrock 53f9735058 Consolidate and deduplicate MMR API methods (#12530)
* histor. batch proof: make best block arg optional

* correct testing range

* make generate_batch_proof stub for historical

* merge generate_{historical_}batch_proof functions

* merge generate_{batch_}proof functions

* merge verify_{batch_}proof functions

* merge verify_{batch_}proof_stateless functions

* remove {Leaf}Proof

Not utilized by API anymore, so superfluous.
Removal consistent with prior changes to just use "batch" proof API.

* rename BatchProof->Proof

no need to qualify if only one universal proof type.

* cleanup

* expose verify_proof rpc api

* document verify_proof

* expose verify_proof_stateless rpc api

* add optional BlockHash to mmr_root rpc api

* fixup! expose verify_proof rpc api

* fix documentation phrasing

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* documentation grammar

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* define mmr error msgs together with error enum

Co-authored-by: Serban Iorga <serban@parity.io>

* fixup! define mmr error msgs together with error enum

* map decoding errors to CallError::InvalidParams

Co-authored-by: Serban Iorga <serban@parity.io>

* fixup! map decoding errors to CallError::InvalidParams

Co-authored-by: Adrian Catangiu <adrian@parity.io>
Co-authored-by: parity-processbot <>
Co-authored-by: Serban Iorga <serban@parity.io>
2022-11-09 14:41:32 +00:00
Qinxuan Chen ad6630ed71 Update some dependencies to prune duplicated crates with different version (#12560)
* sc-client-babe/sp-arithmetic-fuzzer: update num-bigint and num-rational to v0.4

* update lru 0.7.5 ==> v0.8.1

* pallet-example-offchain-worker: update lite-json v0.1.3 ==> v0.2.0

* update hyper 0.14.16 ==> 0.14.20, num-fromat 0.4.0 ==> 0.4.3

* pallet-mmr: update ckb-merkle-mountain-range v0.3.2 ==> v0.5.2

* update handlebars v4.2.2 ==> v4.3.5

* `runtime_cache_size` must always be at least 1

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* default cache size with .min(1)

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* update hyper 0.14.20 ==> 0.14.22

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* update lru 0.8.0 ==> 0.8.1

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Apply suggestions from code review

* Apply suggestions from code review

* Fix Cargo.lock

Signed-off-by: koushiro <koushiro.cqx@gmail.com>
Co-authored-by: Bastian Köcher <git@kchr.de>
Co-authored-by: Bastian Köcher <info@kchr.de>
2022-11-09 11:46:00 +00:00
Ankan 657d99202c Bound Election and Staking by MaxActiveValidators (#12436)
* bounding election provider with kian

* multi phase implement bounded election provider

* election provider blanket implementation

* staking compiles

* fix test for election provider support

* fmt

* fixing epmp tests, does not compile yet

* fix epmp tests

* fix staking tests

* fmt

* fix runtime tests

* fmt

* remove outdated wip tags

* add enum error

* sort and truncate supports

* comment

* error when unsupported number of election winners

* compiling wip after kian's suggestions

* fix TODOs

* remove,fix tags

* ensure validator count does not exceed maxwinners

* clean up

* some more clean up and todos

* handle too many winners

* rename parameter for mock

* todo

* add sort and truncate rule if there are too many winners

* fmt

* fail, not swallow emergency result bound not met

* remove too many winners resolution as it can be guaranteed to be bounded

* fix benchmark

* give MaxWinners more contextual name

* make ready solution generic over T

* kian feedback

* fix stuff

* Kian's way of solvign this

* comment fix

* fix compile

* remove use of BoundedExecution

* fmt

* comment out failing integrity test

* cap validator count increment to max winners

* dont panic

* add test for bad data provider

* Update frame/staking/src/pallet/impls.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* fix namespace conflict and add test for onchain max winners less than desired targets

* defensive unwrap

* early convert to bounded vec

* fix syntax

* fmt

* fix doc

* fix rustdoc

* fmt

* fix maxwinner count for benchmarking

* add instant election for noelection

* fmt

* fix compile

* pr feedbacks

* always error at validator count exceeding max winners

* add useful error message

* pr comments

* import fix

* add checked_desired_targets

* fmt

* fmt

* fix rust doc

Co-authored-by: parity-processbot <>
Co-authored-by: kianenigma <kian@parity.io>
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
2022-11-09 09:11:51 +00:00
Davide Galassi 535c6f2e94 Epoch-Changes tree pruning was lagging by one epoch (#12567)
* Remove all not required nodes from the epoch-changes tree

Some outdated nodes were left there because of the predicate

* Test to excercise the fix

* Add a fork on genesis to the test

* Fix typo in comments
2022-11-09 09:50:36 +01:00
cheme 91ca3a223b update paritydb and remove dev deps on rocksdb (#12641)
* update paritydb and remove dev deps on rocksdb

* feature rocksdb for node testing

* feature decl in node-bench

* revert change to rocksdb inclusion logic

* Update bin/node/bench/Cargo.toml

Co-authored-by: Bastian Köcher <git@kchr.de>

Co-authored-by: parity-processbot <>
Co-authored-by: Bastian Köcher <git@kchr.de>
2022-11-09 09:23:44 +01:00
Bastian Köcher 1e9763cf81 Do not finalize parent twice (#12653)
If the parent block is alread finalized, we don't need to do this again.
2022-11-09 09:22:34 +01:00
zjb0807 8aedd25619 Keep the same name (#12616)
Co-authored-by: x <x@localhost.localdomain>
2022-11-09 07:42:30 +01:00
cheme 8b2ca711b3 Remove partial key size limit from trie codec (#12566)
* remove size limit from trie codec

* test previous upper limit is not enforced anymore

* fmt

* restore test
2022-11-08 21:24:54 +01:00
Shawn Tabrizi 78cddd7631 New Weights for All Pallets (#12325)
* new weights for everything

* fix

* fmt

* new batch

* fmt

* new batch

* Update run_all_benchmarks.sh

* add headers

* update weights

* Update lib.rs

* block and extrinsic weight
2022-11-08 18:50:28 +00:00
Alexander Samusev e4c341e023 [ci] Use ci-linux:production image in ci (#12648) 2022-11-08 18:38:01 +01:00
Kian Paimani c42db93312 Add batching to fast-unstake pallet (#12394)
* implement a brand new batch with all tests passing.

* fix benchmarks as well

* make benchmarks more or less work

* fix migration

* add some testing

* Update frame/fast-unstake/src/benchmarking.rs

Co-authored-by: Roman Useinov <roman.useinov@gmail.com>

* review comments

* some fixes

* fix review comments

* fix build

* fmt

* fix benchmarks

* fmt

* update

Co-authored-by: Roman Useinov <roman.useinov@gmail.com>
2022-11-08 16:15:55 +00:00
Oliver Tale-Yazdi 74b52f9338 Remove duplicate units (#12634)
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2022-11-08 14:01:47 +01:00
Arkadiy Paronyan 617fa6c0ba State-db refactoring (#12239)
* Prune discarded blocks immediately

* state-db refactoring part 1

* Some renames

* Get rid of pending state

* Revert "Prune discarded blocks immediately"

This reverts commit b60d98c569e8af18d99087da93f0911d4f24006e.

* Cleanup

* Make clippy happy

* Minor changes
2022-11-08 10:58:02 +00:00
Bastian Köcher ec6a428ade payment_queryInfo: Make it work with WeightV2 (#12633)
* `payment_queryInfo`: Make it work with `WeighV2`

The runtime api for querying the payment info depends on the `Weight` type and broke for old
runtimes that still use the `WeighV1`. This pull requests fixes this by:

1. Bumping the version of the runtime api.
2. Making the node side code use the correct runtime api function depending on the version of the
runtime api.
3. Make the RPC always return `WeighV1`.

Users of the api should switch to `state_call` and decide based on the version of the runtime api
which `Weight` type is being returned.

* Fix tests

* Review comment
2022-11-08 11:33:43 +01:00
Alexander Samusev 2e22312140 Fix UI tests (#12642) 2022-11-08 11:21:43 +01:00
Bastian Köcher 8fcc6f2e9f sp_trie::Recorder: Fix recording the same key for different tries (#12636)
With `StateVersion::V1` values over a certain size are not inlined and being put into the backend
with their own hash. When accessing a value in the trie with a recorder, we check if the value is maybe already
recorded and thus, we can check the cache. To check if a value is already recorded, we use the key
of the value to differentiate them. The problem is when there are multiple tries, like multiple
child tries that all have different values under the same key. Before this pull request we didn't
have differentiated for which trie we already had recorded a (key, value) pair. This is now done by also taking
the storage root into account in the recorder to differentiate the different (key, value) pair in
the tries.
2022-11-08 10:04:55 +01:00
Alexander Samusev 698f415b85 Pipeline with ci image with rust 1.65 (#12628)
* Pipeline with ci image with rust 1.65

* fix tests

* use image with sha
2022-11-08 09:07:32 +01:00
Aaro Altonen df54463521 Do not update peer information if ancestor search is in progress (#12631)
* Do not update peer information if ancestor search is in progress

If block announcement is received from a peer while ancestor search
for that same peer is still in progress, do not update the peer's best
hash and best number as that causes the ancestor search to yield
different information from what was expected and can cause, for example,
a fork of lower height not be be downloaded.

* Block until peers are in sync
2022-11-07 23:57:29 +01:00
Michal Kucharczyk 1ed70004e7 BlockId removal: &Hash to Hash (#12626)
It changes &Block::Hash argument to Block::Hash.

This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292)
2022-11-07 21:42:16 +00:00
Sam Johnson 7c4bfc9749 Add pallet dev mode (#12536)
* stub for construct_dev_runtime!

* revert

* stub for dev_mode proc macro

* preliminary docs for pallet::dev_mode (attribute) proc macro

* add dev_mode to pallet_macros module

* add docs item for dev_mode to frame_support

* parsing of #[pallet(dev_mode)]

* strip out dev_mode stub since it will be an arg for pallet instead

* make pallet Def struct aware of dev mode

* WIP

* revert changes to call.rs

* pass dev_mode to pallet parsing code

* auto-specify default weights when in dev mode if not specified

* add proof / expect for syn::parse in dev mode weight processing

* set all storages to unbounded when in dev mode

* just use 0

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>

* add invalid pallet arg test

* add passing dev mode pallet test

* add test confirming that dev mode features only work in dev mode

* cargo fmt + clean up

* bump CI

* fix pallet ui test

* add docs for dev mode

* add warning about using dev mode in production circumstances

* remove comment about no other attributes being supported

* fix unneeded assignment

* make warning more explicit

* more explicit warning about using dev mode in production

* simpler assignment for dev_mode boolean

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* add note about MEL requirement

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* add comment specifying why weights can be omitted in example

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* tweak wording of comments

* bump ci

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2022-11-07 21:40:55 +00:00
Michal Kucharczyk cf5c78dbe8 txpool: enactment state forced update (#12632)
* txpool: enactment state forced update

When `tree_route` computation fails, we still need to update the
`enactment_state` to be aligned with last known finalized/best block.

We do not execute enactment phase of maintain procedure, but we do
update the state.

* error -> debug

* test added
2022-11-07 21:12:26 +01:00
Bastian Köcher 81f123b72e Make --db case insensitive again (#12630)
This was broken in the switch to Clap v4.
2022-11-07 14:01:23 +01:00
dependabot[bot] be6f51895b Bump regex from 1.5.5 to 1.6.0 (#12117)
Bumps [regex](https://github.com/rust-lang/regex) from 1.5.5 to 1.6.0.
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.5.5...1.6.0)

---
updated-dependencies:
- dependency-name: regex
  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>
Co-authored-by: parity-processbot <>
2022-11-07 10:17:53 +00:00
cheme d5677cde48 Guard some invalid node for proof decoding. (#12417)
* Guard some invalid node for proof decoding.

* only forbid bitmap with no children.

* change format

* scale error.

* small test

Co-authored-by: parity-processbot <>
2022-11-05 22:26:12 +00:00
shekohex e66339d667 Bump k256 from 0.10.4 to 0.11.4 (#12085)
* Bump `k256` from `0.10.4` to `0.11.4`

* Update Cargo.lock

* Update

Co-authored-by: Bastian Köcher <info@kchr.de>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2022-11-05 11:39:29 +00:00
Sergej Sakac 65b285e632 Move Throughput into sc-sysinfo (#12368)
* move Throughput to sc-sysinfo

* replace u64

* fix in tests

* change Throughput

* refactored Throughput

* fixes

* moved tests & fixes

* custom serializer

* note

* fix serializer

* forgot to remove

* deserialize

* functioning deserialization :)

* try to make clipply happy

* Serialize as function

* test HwBench

* rename

* fix serialization

* deserialize as function

* unused import

* move serialize/deserialize

* don't serialize none

* remove nonsense

* remove nonsense comment :P

* fixes

* remove all the todos

* return enum

* fixes

* fix nit

* improve docs & readability

* Update client/sysinfo/src/sysinfo.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* fix all the nits

* rename

* fix

* Update client/sysinfo/src/sysinfo.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* remove unit from serialization

* Update utils/frame/benchmarking-cli/src/machine/hardware.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2022-11-04 17:13:57 +00:00
Qinxuan Chen 6ba635fcff pallet-sudo: add CheckOnlySudoAccount signed extension (#12496)
* pallet-sudo: add `CheckSudoKey` signed extension

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Rename CheckSudoKey => CheckOnlySudo

Signed-off-by: koushiro <koushiro.cqx@gmail.com>

* Rename extension name and Add some docs

* Apply review suggestions

* Update frame/sudo/src/extension.rs

Co-authored-by: Jegor Sidorenko <5252494+jsidorenko@users.noreply.github.com>

* Update frame/sudo/src/extension.rs

Signed-off-by: koushiro <koushiro.cqx@gmail.com>
Co-authored-by: Bastian Köcher <git@kchr.de>
Co-authored-by: Jegor Sidorenko <5252494+jsidorenko@users.noreply.github.com>
2022-11-03 23:08:24 +00:00
dharjeezy a2e98a943a Introduce DefensiveMin and DefensiveMax (#12554)
* traits for defensive min and defensive max

* defensive min and strict min with tests

* defensive max and strict max with tests

* include docs

* implement partial ord on defensive min and max

* Update frame/support/src/traits/misc.rs

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* wrap lines

* Fix traits

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update frame/support/src/traits/misc.rs

* Update frame/support/src/traits/misc.rs

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: parity-processbot <>
2022-11-03 19:51:18 +00:00
Michal Kucharczyk 11b6409c12 BlockId removal: refactor: Backend::block_indexed_body (#12609)
* BlockId removal: refactor: Backend::block_indexed_body

It changes the arguments of `Backend::block_indexed_body` method from: `BlockId<Block>` to: `&Block::Hash`

This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292)

* trigger CI job
2022-11-03 16:57:10 +00:00
Muharem Ismailov 153399431b Collective benchmark respects DefaultVote configuration (#12612)
* Collective benchmark respects DefaultVote configuration

* ".git/.scripts/bench-bot.sh" pallet dev pallet_collective

Co-authored-by: command-bot <>
2022-11-03 16:52:57 +00:00
Sasha Gryaznov 5e1d421125 stabilize 4 storage host funcs (#12611) 2022-11-03 16:23:05 +00:00
benluelo 7bae412283 Add map and try_map methods (#12581)
Co-authored-by: parity-processbot <>
2022-11-03 11:20:13 +00:00
benluelo 34915840f3 use associated iterator types for InspectEnumerable (#12389)
* use associated iterator types for InspectEnumerable

* Update frame/uniques/src/impl_nonfungibles.rs

Co-authored-by: parity-processbot <>
Co-authored-by: Bastian Köcher <git@kchr.de>
2022-11-02 23:31:04 +00:00
Michal Kucharczyk 84167bd7d4 BlockId removal: refactor: Backend::justifications (#12602)
* BlockId removal: refactor: Backend::justifications

It changes the arguments of `Backend::justifications` method from: `BlockId<Block>` to: `&Block::Hash`

This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292)

* trigger CI job

* trigger CI job

* bug fix

* match -> if

Co-authored-by: Adrian Catangiu <adrian@parity.io>

Co-authored-by: Adrian Catangiu <adrian@parity.io>
2022-11-02 22:15:33 +00:00
Alexander Samusev 8b8675df23 [ci] allow fail skip-if-draft job (#12604) 2022-11-02 14:39:28 +01:00
zjb0807 a5d876f79a Fix fungible unbalanced trait (#12569)
* Fix fungible unbalanced trait

* Add simple decrease_balance test

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix decrease_balance_at_most

* Fix decrease_balance_at_most in fungibles

* Rename free_balanceto balance_on_free

* Use reducible_balance instead of balance_on_free

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2022-11-02 09:56:48 +00:00
Daniel Shiposha 73a65711e8 fix: construct_runtime multiple features (#12594)
* fix: construct_runtime multiple features

* Update frame/support/procedural/src/construct_runtime/mod.rs

Co-authored-by: Bastian Köcher <git@kchr.de>
2022-11-02 00:10:43 +01:00
Michal Kucharczyk 76bcbd09a5 BlockId removal: refactor: Backend::body (#12587)
It changes the arguments of `Backend::body` method from: `BlockId<Block>` to: `&Block::Hash`

This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292)

Co-authored-by: parity-processbot <>
2022-11-01 16:24:09 +00:00
Adrian Catangiu c68bd397d8 client/beefy: fix incorrect BEEFY justifications import test (#12593)
Signed-off-by: Adrian Catangiu <adrian@parity.io>
2022-10-31 17:41:01 +02:00
Michal Kucharczyk a1a3b923ab Added test for Client::block (#12590) 2022-10-31 12:43:36 +01:00
joe petrowski cb20ae7de1 fix some typos (#12584) 2022-10-31 11:20:29 +00:00
Michal Kucharczyk 0ef7e261a3 BlockId removal: refactor: Backend::append_justification (#12551)
* BlockId removal: refactor: Backend::append_justification

It changes the arguments of `Backend::append_justification`
from: block: `BlockId<Block>` to: hash: `&Block::Hash`

This PR is part of `BlockId::Number` refactoring analysis (paritytech/substrate#11292)

* Error message improved

Co-authored-by: Adrian Catangiu <adrian@parity.io>

* single error message in beefy::finalize

* println removed

Co-authored-by: Adrian Catangiu <adrian@parity.io>
2022-10-30 17:58:29 +00:00
Oliver Tale-Yazdi 9bc59da6b3 Use minimum_nominator_bond instead of nominator_bond (#12585)
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2022-10-30 16:00:26 +00:00
Alexander Theißen 9c748c74de WIP: Replace wasm-gc with wasm-opt (#12280)
* Use wasm-opt on runtime

* Optimize for size

* Simplify fn compact_wasm_file

* Run a lighter pass for non production builds

* Disable optimizations and keep name section

* Update wasm-opt

* Remove dward sections

* Update wasm-opt

* Update wasm-opt
2022-10-30 10:09:47 +00:00
Doordashcon a29624ab83 nomination-pools: allow pool-ids to be reused (#12407)
* initial

* logic check

* do_create

* cargo fmt

* fixes

* ensure_signed

* update

* cargo fmt

* remove unused import
2022-10-29 14:57:16 +00:00
Roman Useinov 4bc091f4a9 [Enhancement] Convert fast-unstake to use StakingInterface, decouplin… (#12424)
* [Enhancement] Convert fast-unstake to use StakingInterface, decoupling it from Staking

* Update primitives/staking/src/lib.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update primitives/staking/src/lib.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* fix validator comment

* remove todo

* ideas from Kian (#12474)

Co-authored-by: kianenigma <kian@parity.io>

* Rename StakingInterface -> Staking for nomination-pools

* Staking fixes

* StakingInterface changes

* fix fast-unstake

* fix nomination-pools

* Fix fast-unstake tests

* Fix benches for fast-unstake

* fix is_unbonding

* fix nomination pools

* fix node code

* add mock comments

* fix imports

* remove todo

* more fixes

* more fixes

* bench fixes

* more fixes

* more fixes

* import fix

* more fixes

* more bench fix

* refix

* refix

* Update primitives/staking/src/lib.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* is_unbonding returns a result

* fix

* review fixes

* more review fixes

* more fixes

* more fixes

* Update frame/fast-unstake/src/benchmarking.rs

Co-authored-by: Squirrel <gilescope@gmail.com>

* remove redundant CurrencyBalance from nom-pools

* remove CB

* rephrase

* Apply suggestions from code review

* Update frame/nomination-pools/src/tests.rs

* finish damn renamed

* clippy fix

* fix

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
Co-authored-by: kianenigma <kian@parity.io>
Co-authored-by: parity-processbot <>
Co-authored-by: Squirrel <gilescope@gmail.com>
2022-10-29 09:22:58 +00:00
Koute 3faa0bd20d Treat near-zero intercept values as zero when calculating weights (#12573)
* Treat near-zero intercept values as zero when calculating weights

* Simplify comparison

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update contract weights

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-10-28 20:39:59 +00:00
Sergej Sakac a1f8a74a37 Utility: add more tests for batch/batchAll/forceBatch (#12506)
* Utility: add more tests for batch/batchAll/forceBatch

* remove unnecessary

* batch works with council

* add more tests

* better call examples

* shorter code

* Update frame/utility/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update frame/utility/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* Update frame/utility/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* update TestBaseCallFilter

* fix

* fix?

* fix

Co-authored-by: Bastian Köcher <git@kchr.de>
2022-10-28 15:18:09 +00:00
clangenb 9c1af65012 bump ed25519-zebra; fixes full_crypto feature flag in no_std (#12576) 2022-10-28 15:38:25 +02:00