Sergei Shulepov
c816ebc4b3
Explicitly support memory size changing in between allocations ( #9477 )
...
Co-authored-by: Bastian Köcher <info@kchr.de >
2021-08-03 16:22:01 +02:00
Bastian Köcher
3b471704d9
Use correct ExecutionContext for check_inherents ( #9483 )
...
Before we used the `other` context, while we are actually either in the
import or sync context.
2021-08-03 11:12:21 +00:00
André Silva
0240efde58
aura, babe: don't allow disabled validators to build blocks ( #9414 )
...
* frame-support: add trait for checking disabled validators
* pallet-session: implement DisabledValidators trait
* pallet-babe: check for disabled validators
* pallet-babe: add test for disabled validators
* pallet-aura: check for disabled validators
* pallet-aura: add test for disabled validators
* runtime: fix missing DisableValidator
* test-runtime: add missing DisabledValidators
* frame-support: clean up doc
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-08-03 10:57:08 +00:00
Dan Shields
c9ffce0f9c
Add a matrix chat badge to the README ( #9476 )
...
* Add a matrix chat badge to the README
This is a fun addition for connecting users to our dedicated Substrate chat & to visualize the number of members there.
```
[](https://matrix.to/#/#substrate-technical:matrix.org )
```
https://img.shields.io/matrix/substrate-technical:matrix.org can be viewed directly to see the count before merging the PR here.
* Update README.md
2021-08-02 21:52:34 +00:00
Eric Miller
28c76a1de4
#9386 : copy rustfmt.toml to node-template ( #9461 )
...
* copying rustfmt from root to node-template build.
Also, running rustfmt on this.
* Update .maintain/node-template-release/src/main.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Add some important events to batch & staking to ensure ease of analysis (#9462 )
* Add some important events to batch & staking to ensure ease of analysis
* Update frame/staking/src/pallet/mod.rs
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
* Update lib.rs
* fix test
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
* Move client consensus parts out of primitives and into client/consensus/api (#9319 )
* moved client code out of primitives
* bump ci
* Fixup from merge.
* Removed unused deps thanks to review feedback
* Removing unneeded deps
* updating lock file
* note about rustfmt
* fixed typo to bump ci
* Move lonely CacheKeyId to parent
* cargo fmt
* updating import style
* Update docs/STYLE_GUIDE.md
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Refactor Benchmarks for Less Wasm Memory Usage (#9373 )
* extract repeat out of benchmark
* remove r
* unused
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* use linked map to keep order
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* Delete pallet_balances.rs
* Delete out
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* steps and repeat to tuple (current_*, total_*)
* idea for list command
* fmt
* use benchmark list in cli
* handle steps in cli
* move log update to cli
* fmt
* remove old todo
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* benchmark metadata function
* don't need this warm up
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* fix warnings
* fix node-template
* fix
* fmt
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* improve docs
* improve cli
* fix format
* fix bug?
* Revert "fix bug?"
This reverts commit 8051bf1bf9bae862ff28dfff386e7045cd3f045e.
* skip frame-metadata
* extract repeat out of benchmark
* remove r
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* use linked map to keep order
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* Delete pallet_balances.rs
* Delete out
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* steps and repeat to tuple (current_*, total_*)
* idea for list command
* fmt
* use benchmark list in cli
* handle steps in cli
* move log update to cli
* remove old todo
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* benchmark metadata function
* don't need this warm up
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* fix warnings
* fix node-template
* fix
* fmt
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* improve docs
* improve cli
* fix format
* fix bug?
* Revert "fix bug?"
This reverts commit 8051bf1bf9bae862ff28dfff386e7045cd3f045e.
* skip frame-metadata
* Update .gitlab-ci.yml
* fix import
* Update .gitlab-ci.yml
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
* Warp sync part I (#9227 )
* Started warp sync
* BABE & GRANDPA recovery
* Warp sync protocol
* Sync warp proofs first
* Added basic documentation
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Style changes
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* fmt
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Fixed chage trie pruning wrt missing blocks
* Restore parent finalization
* fmt
* fmt
* Revert pwasm-utils bump
* Change error type & check API version
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Build fix
* Fixed target block check
* Formatting
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Add rustfmt skip to default frame benchmarking template (#9473 )
This was missed in the introduction pr of rustfmt. There we only had
updated the Substrate local template.
* CI: stop publishing to crates.io until unleash is fixed (#9474 )
* CI: stop publishing to crates.io until unleash is fixed; allow restarting k8s runners
* CI: fix CI if ci-release tag is pushed
Co-authored-by: Eric Miller <emiller@lirio.co >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Gavin Wood <gavin@parity.io >
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
Co-authored-by: Squirrel <gilescope@gmail.com >
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
Co-authored-by: Arkadiy Paronyan <arkady.paronyan@gmail.com >
Co-authored-by: Denis Pisarev <denis.pisarev@parity.io >
2021-08-02 23:46:53 +02:00
Sergei Shulepov
92b8e0680c
Limit the maximum number of wasm memory pages a runtime can have ( #9308 )
...
* Limit the maximum number of wasm memory pages a runtime can have
* Switch the argument order
* fmt
2021-08-02 19:15:07 +00:00
Denis Pisarev
b14d4f07aa
CI: stop publishing to crates.io until unleash is fixed ( #9474 )
...
* CI: stop publishing to crates.io until unleash is fixed; allow restarting k8s runners
* CI: fix CI if ci-release tag is pushed
2021-08-02 16:58:47 +02:00
Bastian Köcher
e6910534ff
Add rustfmt skip to default frame benchmarking template ( #9473 )
...
This was missed in the introduction pr of rustfmt. There we only had
updated the Substrate local template.
2021-08-02 09:17:30 +00:00
Arkadiy Paronyan
f56232602f
Warp sync part I ( #9227 )
...
* Started warp sync
* BABE & GRANDPA recovery
* Warp sync protocol
* Sync warp proofs first
* Added basic documentation
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Style changes
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* fmt
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Fixed chage trie pruning wrt missing blocks
* Restore parent finalization
* fmt
* fmt
* Revert pwasm-utils bump
* Change error type & check API version
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Build fix
* Fixed target block check
* Formatting
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-08-02 08:27:18 +00:00
Shawn Tabrizi
fa8c6274ac
Refactor Benchmarks for Less Wasm Memory Usage ( #9373 )
...
* extract repeat out of benchmark
* remove r
* unused
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* use linked map to keep order
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* Delete pallet_balances.rs
* Delete out
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* steps and repeat to tuple (current_*, total_*)
* idea for list command
* fmt
* use benchmark list in cli
* handle steps in cli
* move log update to cli
* fmt
* remove old todo
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* benchmark metadata function
* don't need this warm up
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* fix warnings
* fix node-template
* fix
* fmt
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* improve docs
* improve cli
* fix format
* fix bug?
* Revert "fix bug?"
This reverts commit 8051bf1bf9bae862ff28dfff386e7045cd3f045e.
* skip frame-metadata
* extract repeat out of benchmark
* remove r
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* use linked map to keep order
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* Delete pallet_balances.rs
* Delete out
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* steps and repeat to tuple (current_*, total_*)
* idea for list command
* fmt
* use benchmark list in cli
* handle steps in cli
* move log update to cli
* remove old todo
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* benchmark metadata function
* don't need this warm up
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* fix warnings
* fix node-template
* fix
* fmt
* line width
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* improve docs
* improve cli
* fix format
* fix bug?
* Revert "fix bug?"
This reverts commit 8051bf1bf9bae862ff28dfff386e7045cd3f045e.
* skip frame-metadata
* Update .gitlab-ci.yml
* fix import
* Update .gitlab-ci.yml
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
2021-08-01 18:13:58 +00:00
Squirrel
df59596ec0
Move client consensus parts out of primitives and into client/consensus/api ( #9319 )
...
* moved client code out of primitives
* bump ci
* Fixup from merge.
* Removed unused deps thanks to review feedback
* Removing unneeded deps
* updating lock file
* note about rustfmt
* fixed typo to bump ci
* Move lonely CacheKeyId to parent
* cargo fmt
* updating import style
* Update docs/STYLE_GUIDE.md
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
2021-07-30 13:27:17 +00:00
Gavin Wood
8a44bec2dc
Add some important events to batch & staking to ensure ease of analysis ( #9462 )
...
* Add some important events to batch & staking to ensure ease of analysis
* Update frame/staking/src/pallet/mod.rs
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
* Update lib.rs
* fix test
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2021-07-29 20:02:28 +00:00
Squirrel
060d564fc3
Remove old benchmark ( #9457 )
...
Apparently this should be rewritten when we need it again.
2021-07-29 13:19:26 +01:00
André Silva
44ace31bee
build: nix-shell: use mozilla/nixpkgs-mozilla repo ( #9456 )
2021-07-29 11:13:08 +00:00
Bastian Köcher
f07f69301a
Improve state related logs to use a more uniform format ( #9452 )
...
* Improve `state` related logs to use a more uniform format
The logging before wasn't that uniform and not that great to read/parse.
Now we are using a uniform format for all the logs. Besides these
changes, there are some minor changes around the code that calls the
state machine.
* Make CI happy
* Use HexDisplay for `ext_id`
2021-07-29 11:43:03 +02:00
Dan Forbes
76611ba6a3
Add nonfungibles::Create Trait & Implement for Uniques ( #9438 )
...
* Add nonfungibles::Create Trait & Implement for Uniques
Closes #9419
* Formatting
* Remove default implementation (`TokenError::Unsupported`) from `Create` trait
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Formatting
* Do not wrap parameters in Options
* Formatting
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-07-28 13:39:04 +00:00
dependabot[bot]
52aa9c2ef7
Bump walkdir from 2.3.1 to 2.3.2 ( #9453 )
...
Bumps [walkdir](https://github.com/BurntSushi/walkdir ) from 2.3.1 to 2.3.2.
- [Release notes](https://github.com/BurntSushi/walkdir/releases )
- [Commits](https://github.com/BurntSushi/walkdir/compare/2.3.1...2.3.2 )
---
updated-dependencies:
- dependency-name: walkdir
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>
2021-07-28 11:23:36 +00:00
Alex Pozhylenkov
a8e5744985
Round robin on_idle execution ( #9432 )
...
* update on_idle tuple implemenration
* add test
* fix
* fix fmt
* update
* update
* fix fmt
* Update frame/support/src/traits/hooks.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* update
* update
* fix pallet_ui tests
* Update frame/support/src/traits/hooks.rs
* fix
* Update frame/support/src/traits/hooks.rs
* update
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-07-28 13:22:45 +02:00
dependabot[bot]
79052e281a
Bump proc-macro2 from 1.0.26 to 1.0.28 ( #9451 )
...
Bumps [proc-macro2](https://github.com/alexcrichton/proc-macro2 ) from 1.0.26 to 1.0.28.
- [Release notes](https://github.com/alexcrichton/proc-macro2/releases )
- [Commits](https://github.com/alexcrichton/proc-macro2/compare/1.0.26...1.0.28 )
---
updated-dependencies:
- dependency-name: proc-macro2
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>
2021-07-28 09:43:58 +00:00
Zeke Mostov
c5be63ce6d
pallet-staking: Reorg migration, pallet and pallet impls ( #9410 )
...
* Reorg migration and pallet and pallet impls
* Fix imports in untouched modules
* Add file headers
* Add header for migrations
* Improve comment
* Move OnOffenceHandler impl for Pallet to impl.rs
* fmt
2021-07-27 23:23:01 +00:00
Bastian Köcher
4fe55f0bcb
Move PalletVersion away from the crate version ( #9165 )
...
* Move `PalletVersion` away from the crate version
Before this pr, `PalletVersion` was referring to the crate version that
hosted the pallet. This pr introduces a custom `package.metadata.frame`
section in the `Cargo.toml` that can contain a `pallet-version` key
value pair. While the value is expected to be a valid u16. If this
key/value pair isn't given, the version is set to 1.
It also changes the `PalletVersion` declaration. We now only have one
`u16` that represents the version. Not a major/minor/patch version. As
the old `PalletVersion` was starting with the `u16` major, decoding the
old values will work.
* Overhaul the entire implementation
- Drop PalletVersion
- Introduce StorageVersion
- StorageVersion needs to be set in the crate and set for the macros
- Added migration
* Fix migrations
* Review feedback
* Remove unneeded dep
* remove pub consts
* Brings back logging and implements `GetStorageVersion`
* Return weight from migration
* Fmt and remove unused import
* Update frame/support/src/dispatch.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
* Update frame/support/src/traits/metadata.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
2021-07-27 21:21:27 +00:00
Guillaume Thiolliere
988c399983
fix codec ( #9445 )
2021-07-27 23:02:55 +02:00
wangjj9219
32fe61306b
check can_dec_provider when transfer allow death ( #9411 )
2021-07-27 17:59:34 +01:00
Guillaume Thiolliere
23e8088c1c
Make allocator limit available for the runtime ( #9393 )
...
* make allocator limit available
* better inner doc
* move const
* fmt
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2021-07-27 13:04:11 +00:00
Bastian Köcher
9c173724fa
Update trybuild to get better normalization ( #9444 )
...
The old `trybuild` version didn't normalized cargo registry paths, but
this is now done :)
2021-07-27 11:01:28 +00:00
Squirrel
ca3ee2e2a5
IDEs like rust-src ( #9443 )
...
Co-authored-by: Giles Cope <giles.cope@gmail.com >
2021-07-27 10:00:06 +00:00
Liu-Cheng Xu
6b75ec92a7
More readable help for --sync option ( #9441 )
2021-07-27 10:43:27 +02:00
Keith Yeung
845e6a5ff1
Add methods to PrefixIterator to support iterating from a specific key ( #9313 )
...
* Add methods to PrefixIterator to support iterating from a specific key
* Expose the decode functions used in iterators for storage maps
* Use associated decode function in tests
* Revert "Expose the decode functions used in iterators for storage maps"
This reverts commit 34f57d92db89646d0c98ea1880df58d58e523b09.
* Fix documentation for next_key
* Add API for iterating from a specified key for all storage map types
* Enhance pagination test
* Add API methods to storage map types
* Rename next_key to last_key
* Rename last_key to last_raw_key
* Specify that iteration starts after starting_raw_key
* Update documentation on iteration ordering
* Rename next_key to previous_key
* Enhance pagination unit test
* Create unit tests for all kinds of iter_from methods
* Define iter_from in terms of iter rather than vice versa
* Cargo fmt
2021-07-27 00:43:15 +00:00
Squirrel
492523f1ae
post rustfmt whitespace fixup ( #9436 )
...
Taking best bits of rustfmt's format_strings
Co-authored-by: Alexander Popiak <alexander.popiak@gmail.com >
2021-07-26 14:18:27 +01:00
Squirrel
ec047abbcf
clippy fixes ( #9173 )
2021-07-26 14:12:18 +01:00
Falco Hirschenberger
17c6477683
Simplify returnvalue creation ( #9429 )
2021-07-26 10:31:07 +02:00
Falco Hirschenberger
b7dc3bc6f2
Don't return misleading result with PostInfo in proxy-pallet ( #9426 )
...
also autoformatting two unrelated files
fixes #9421
2021-07-24 18:00:29 +00:00
asymmetric
4e653bfa3c
Clarify Prometheus exporter options ( #9427 )
...
The 'data source' term does not represent a Prometheus concept. What we are exposing here is an exporter.
2021-07-23 20:00:08 +00:00
cheme
ade667f928
State machine local child root cache. ( #9107 )
...
* cache root for child api.
* minimal testing
* Reset cache on test 'set_root'.
* Update primitives/state-machine/src/trie_backend_essence.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Update primitives/state-machine/src/trie_backend_essence.rs
* Update primitives/state-machine/src/trie_backend_essence.rs
* Renaming to 'reset_cache'.
* correct rust fmt
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-07-23 11:30:00 +00:00
Alex Pozhylenkov
fc2dd61f14
Staking refactor. Change *_or() to *_or_else() ( #9400 )
...
* update
* update
* update
* fix fmt
2021-07-23 11:06:18 +00:00
Squirrel
b3d16c9442
example typo ( #9416 )
...
* Think these types should be switched reading the doc.
* Update frame/support/procedural/src/lib.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-07-23 09:15:39 +00:00
Kian Paimani
c2e246d372
Estimate call fee ( #9395 )
...
* Estimate call fee
* More fix
* Fix
* Update frame/support/src/traits/misc.rs
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
* try and fix fmt stuff
* fmt aain
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
Co-authored-by: Zeke Mostov <32168567+emostov@users.noreply.github.com >
2021-07-23 08:53:32 +00:00
Logan Saether
d18c6a5200
Add Zeitgeist ss58 prefix 73 reservation ( #8509 )
2021-07-22 20:53:57 -04:00
Xiliang Chen
b0857ce226
add CheckedRem ( #9412 )
...
* add CheckedRem
* fix
2021-07-22 12:59:23 +00:00
Squirrel
aafe64315a
Remove extra commas made redundent after rustfmt ( #9404 )
...
* Remove extra commas made redundent after rustfmt
2021-07-22 11:06:17 +01:00
Guillaume Thiolliere
e18f388dac
Benchmarking also benchmark for decoding the call ( #9343 )
...
* benchmark for decoding of call
* better names
* fix benchmarks
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_lottery --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/lottery/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_utility --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/utility/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --quiet --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=frame_system --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/system/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* Update frame/system/src/weights.rs
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2021-07-22 09:29:44 +00:00
Arkadiy Paronyan
c5f5c9c28c
Fix db metadata updates for existing headers ( #9403 )
...
* Fix metadata updates on existing headers
* Fail set_head on ancient blocks
* Fmt unrelated code
2021-07-21 20:35:58 +00:00
Zeke Mostov
ec6d711b38
Run cargo +nightly fmt ( #9406 )
2021-07-21 20:35:24 +00:00
Bastian Köcher
7b56ab15b4
Run cargo fmt on the whole code base ( #9394 )
...
* Run cargo fmt on the whole code base
* Second run
* Add CI check
* Fix compilation
* More unnecessary braces
* Handle weights
* Use --all
* Use correct attributes...
* Fix UI tests
* AHHHHHHHHH
* 🤦
* Docs
* Fix compilation
* 🤷
* Please stop
* 🤦 x 2
* More
* make rustfmt.toml consistent with polkadot
Co-authored-by: André Silva <andrerfosilva@gmail.com >
2021-07-21 14:32:32 +00:00
Bastian Köcher
d451c38c1c
Fix custom on runtime upgrade not being called ( #9399 )
...
When the `Executive` was used through the `ExecuteBlock` trait, the
custom on runtime upgrade wasn't called. This happened because we forgot
to forward the type and it instead used default type `()` that doesn't
do anything. This pr fixes it by forwarding the type and also adds a
regression test.
2021-07-20 22:20:34 +00:00
Denis Pisarev
f6b5c7c3f0
CI: fix docs pub ( #9341 )
...
* CI: debug
* CI: debug aws sync
* exclude locfile
* exclude locfile 2
* exclude doesn't work
* root files
* CI: remove lockfile
* CI: satisfy aws cli
* CI: typo
* CI: undebug
* CI: undebug docs jobs
2021-07-20 18:37:58 +02:00
Alexander Popiak
f538174847
Balance to Asset Balance Conversion ( #9076 )
...
* add BalanceConversion trait and implementation
* derive some useful traits on Imbalance
* Update frame/support/src/traits/tokens/fungibles/imbalance.rs
Co-authored-by: Xiliang Chen <xlchen1291@gmail.com >
* make BalanceConversion error type configurable
* add RuntimeDebug import and derive traits on other Imbalance
* formatting
* move BalanceConversion trait to frame-support
* add necessary trait import
Co-authored-by: Xiliang Chen <xlchen1291@gmail.com >
2021-07-20 14:55:54 +00:00
Xiliang Chen
e17a014627
include dispatch result in the Executed event ( #9315 )
...
* include dispatch result in the Executed event
* fix
* trigger CI
2021-07-20 14:40:11 +00:00
Bastian Köcher
2b282a9435
Remove IncRefError, DecRefError and StoredMapError ( #9384 )
...
All of them are a subset of `DispatchError` anyway, no need to have
special errors IMHO.
2021-07-20 10:39:26 +02:00
Ashley
6d9e05cb9a
Add a rustfmt.toml ( #8982 )
...
* Force push to clean up PR mess
* Update rustfmt.toml
Co-authored-by: Squirrel <gilescope@gmail.com >
* Run `cargo fmt` again with Giles' changes
* Unformat utils
Co-authored-by: Squirrel <gilescope@gmail.com >
2021-07-19 13:43:08 +00:00