Xiliang Chen
327934c19e
impl Zero and One for fixed point numbers ( #8647 )
...
* impl Zero and One for fixed point numbers
* update librocksdb-sys to support M1
* fix build
* trigger CI
2021-04-22 22:02:54 +00:00
Tomasz Drwięga
f7ed5a2481
Off-chain indexing is independent from workers ( #8659 )
...
* Pff-chain indexing is independent from worker.
* Remove unauthorized changes.
* 🤦
2021-04-22 21:37:03 +00:00
Alexander Theißen
166568b029
contracts: Allow () -> (i32) for backwards compatibility ( #8656 )
2021-04-22 10:44:35 +00:00
Niklas Adolfsson
70f008b9f1
update jsonrpsee to 0.2.0-alpha.5 ( #8644 )
2021-04-21 10:59:15 +00:00
Pierre Krieger
54ae55f439
Revert "Properly close notification substreams ( #8534 )" ( #8646 )
...
This reverts commit 6c9c687a31 .
Co-authored-by: André Silva <andrerfosilva@gmail.com >
2021-04-20 18:39:07 +00:00
Pierre Krieger
86c5dc848f
Authority-discovery no longer publishes non-global IP addresses ( #8643 )
...
* Authority-discovery no longer publishes non-global IP addresses
* Cargo.lock
* Update client/authority-discovery/src/lib.rs
Co-authored-by: Andronik Ordian <write@reusable.software >
Co-authored-by: Andronik Ordian <write@reusable.software >
2021-04-20 13:42:58 +00:00
Pierre Krieger
3a72631439
Enable --no-private-ipv4 by default for live chains ( #8642 )
...
* Enable --no-private-ipv4 by default for live chains
* Make the selection a bit easier to read
* Update client/cli/src/params/network_params.rs
Co-authored-by: Andronik Ordian <write@reusable.software >
Co-authored-by: Andronik Ordian <write@reusable.software >
2021-04-20 13:42:11 +00:00
André Silva
a52adf448b
client: remove time unit from block time loaded message ( #8639 )
2021-04-19 20:29:43 +00:00
Alexander Theißen
18000a9ae8
Update dependencies of pallet_contracts ( #8637 )
...
* Update parity-wasm
* Cleanup Cargo.toml files
- Sort dependencies
- Remove minor and fix version where they are not necessary
* Update pretty_assertions
* Update rand
2021-04-19 10:47:46 +00:00
Guillaume Thiolliere
ea10494ca9
Make pallet macro generate accessor to PalletInfo information on pallet placeholder ( #8630 )
...
* generate accessor to PalletInfo information on pallet placeholder
* remove unused
* use trait, and add tests
* less verbose doc
* add PalletInfoAccess to prelude for ease usage
2021-04-19 10:09:23 +00:00
Pierre Krieger
d64f79924a
Update to libp2p 0.37 ( #8625 )
...
* Update to libp2p 0.37
* Line widths
* Fix tests
2021-04-18 08:04:45 +00:00
Kian Paimani
b6b107030d
Add benchmarks for pallet-membership ( #8596 )
...
* Add benchmakrs for membership
* Update frame/membership/src/lib.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
* Make it all work
* Add mock weights
* Update frame/membership/src/lib.rs
* Update frame/membership/src/lib.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
* cargo run --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_membership --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/membership/src/weights.rs --template=./.maintain/frame-weight-template.hbs
* cargo run --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_membership --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/membership/src/weights.rs --template=./.maintain/frame-weight-template.hbs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
2021-04-18 04:52:05 +00:00
ferrell-code
92630df143
Authority Discovery to FRAME v2 ( #8620 )
...
* migrate to new macro
* formatting
* Apply suggestions from code review
* Update frame/authority-discovery/src/lib.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
2021-04-18 02:23:27 +00:00
Guillaume Thiolliere
bb343c7c26
fix doc and dyn ( #8631 )
2021-04-17 17:01:31 +02:00
Denis Pisarev
4dcbac4b58
CI updates ( #8633 )
...
* CI: opt bench jobs; add bench to triggered job
* CI: no need in manual builds; build=publish
* CI: more logs to the trigger job
* CI: DAGs and louts
2021-04-16 21:35:08 +02:00
Bastian Köcher
c8136bd1df
Remove serde requirement from FRAME macros ( #8628 )
...
* Remove `serde` requirement from FRAME macros
Currently there is some implicit requirement on `serde` being present in
the `Cargo.toml` of a pallet when `GenesisConfig` is used. This pr
removes this requirement by using the serde attribute `serde(crate = "..")`.
* build a unique reexport of serde in impl_opaque_keys, by abusing paste doc concatenation
* Optimize
Co-authored-by: thiolliere <gui.thiolliere@gmail.com >
2021-04-16 12:42:37 +02:00
Daniel Olano
7527bd758c
Make pallet Assets instantiable ( #8483 )
...
* Make pallet Assets instantiable
* use instantiable benchmarks
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2021-04-16 08:51:26 +00:00
Kian Paimani
6bcf5f21c4
BoundedVec + Shims for Append/DecodeLength ( #8556 )
...
* prototype for shawn
* Clean and document it
* Add more docs
* Move imports
* Some changes for easier compat.
* revert exmaple pallet
* rename
* BoundedVec for AccountLocks (#8580 )
* Example with balances
* Fix tests
* Make it indexable
* fix
* Fix tests
* fix test
* Fix collective as well
* Fix test
* Update frame/support/src/storage/mod.rs
Co-authored-by: Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com >
* Repot and add for value
* Add for map and double map
* Final touches.
* Update frame/support/src/storage/bounded_vec.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
* Add a few more tests
* Add import
Co-authored-by: Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com >
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
2021-04-16 06:06:05 +00:00
Pierre Krieger
6c9c687a31
Properly close notification substreams ( #8534 )
...
* Properly close notification substreams
* Some debug asserts
* Fix state inconsistency
* Remove erroneous debug_assert!
* Some comments
2021-04-15 10:42:47 +00:00
Bastian Köcher
14b5acab86
Introduce a "dynamic" block size limit for proposing ( #8588 )
...
* Introduce a "dynamic" block size limit for proposing
This adds support for using a dynamic block size limit per call to
`propose`. This is required for Cumulus/Parachains to always use stay in
the limits of the maximum allowed PoV size.
As described in the docs, the block limit is only checked in the process
of pushing transactions. As we normally do some other operations in
`on_finalize`, it can happen that the block size still grows when there
is some proof being collected (as we do for parachains). This means,
that the given block limit needs to be rather conservative on the actual
value and should not be the upper limit.
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: Andronik Ordian <write@reusable.software >
* More future proof encoded size updating
* Use `ProofRecorderInner`
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/consensus/slots/src/lib.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/consensus/slots/src/slots.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
* Update client/basic-authorship/src/basic_authorship.rs
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
Co-authored-by: Andronik Ordian <write@reusable.software >
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com >
2021-04-14 17:56:22 +00:00
Pierre Krieger
2fa6f2fbd5
Fix debug_assertion failing in authority discovery ( #8599 )
...
* Fix debug_assertion failing in authority discovery
* Improve test
* Change the map_or for invalid addresses
* Remove debug_assertion
2021-04-14 13:19:33 +00:00
Pierre Krieger
c227ff78d8
Increase metric only if actually publishing ( #8618 )
2021-04-14 12:40:18 +00:00
Pierre Krieger
fa89371a17
Make non-validators listen on /ws by default ( #8609 )
...
* Make non-validators listen on /ws by default
* Fix WS path
2021-04-14 09:44:09 +00:00
Vladislav
d0933c4634
Add Sora network SS58 Address ( #8261 )
...
* Add Sora network SS58 Address
Signed-off-by: Vladislav Markushin <negigic@gmail.com >
* Update Sora network SS58 Address to `69`
Signed-off-by: Vladislav Markushin <negigic@gmail.com >
Co-authored-by: thiolliere <gui.thiolliere@gmail.com >
2021-04-14 09:16:12 +00:00
André Silva
fd0700abad
build: update shell.nix ( #8616 )
2021-04-14 08:58:26 +00:00
Peter Goodspeed-Niklaus
33425ce21f
Trim compact solution for length during preparation ( #8317 )
...
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2021-04-13 15:17:32 +02:00
Xiliang Chen
3351cb8869
expose set_timestamp for runtime benchmarks ( #8601 )
...
* expose set_timestamp for runtime benchmarks
* Update frame/timestamp/src/lib.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
2021-04-13 13:52:20 +02:00
Alexander Theißen
f854194139
contracts: Add RPC that allows instantiating of a contract ( #8451 )
...
* contracts: Add RPC that allows instantiating of a contract
* Encode `debug_message` as bytes because usage of `String` is forbidden
* Remove erroneous derive attribute
* Fix rpc tests for new `debug_message` encoding
* Fix typo
Co-authored-by: Andrew Jones <ascjones@gmail.com >
Co-authored-by: Andrew Jones <ascjones@gmail.com >
2021-04-13 11:26:52 +00:00
Falco Hirschenberger
24311eee3e
Change assert(is_err()) to assert_noop to check state consistency on errors ( #8587 )
...
* Change is_err() asserts in tests to assert_noop to check state consistency
fixes #8545
* Update frame/transaction-payment/src/lib.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
* Update frame/contracts/src/exec.rs
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
* Update frame/democracy/src/benchmarking.rs
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
* Update frame/transaction-payment/src/lib.rs
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
* Don't assert no-changing state.
see: https://github.com/paritytech/substrate/pull/8587#issuecomment-817137906
* fix expected error
* Fix non-extrinsic-call asserts
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
2021-04-13 10:44:27 +00:00
Chris D'Costa
b9ed6e01b3
Change i8 to u8 on WithdrawReasons #8586 ( #8591 )
2021-04-13 10:10:14 +00:00
Guillaume Thiolliere
a4ed9bb9b2
Ensure inherent are first ( #8173 )
...
* impl
* fix tests
* impl in execute_block
* fix tests
* add a test in frame-executive
* fix some panic warning
* use trait to get call from extrinsic
* remove unused
* fix test
* fix testing
* fix tests
* return index of extrinsic on error
* fix test
* Update primitives/inherents/src/lib.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
* address comments
rename trait, and refactor
* refactor + doc improvment
* fix tests
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2021-04-13 09:30:13 +00:00
Denis Pisarev
6679b88af8
WIP: fix Simnet trigger ( #8493 )
...
* CI: trigger guard [skip ci]
* CI: variables and dotenv [skip ci]
* CI: correct variable for simnet trigger
* CI: correct rules for simnet trigger
* fix linting issue :)
* CI: trigger simnet via API
Co-authored-by: radupopa2010 <radupopa2010@yahoo.com >
2021-04-13 01:29:21 +02:00
Bastian Köcher
6378a4ee78
Pallet macro support frame_system::Config with args ( #8606 )
2021-04-12 19:11:23 +00:00
Chris D'Costa
0cbd3b4f46
#8597 Update features resolver wasm build ( #8598 )
2021-04-12 18:43:22 +00:00
Keith Yeung
3b8a0ffa6a
Fix buggy string comparison in OCW pallet example ( #8602 )
2021-04-12 20:40:20 +02:00
Bastian Köcher
59b900bae3
Fix parameter_types! macro ( #8594 )
...
Make it work with different kinds of parameter types when
`static` is one of them.
2021-04-12 19:37:35 +02:00
Gavin Wood
29864b255c
Purify Contains, add IsInVec, All and SortedMembers ( #8589 )
...
* IsInVec
* Purify `Contains`, introduce SortedMembers
2021-04-11 00:04:02 +02:00
Shawn Tabrizi
fe775ab954
Benchmark Transfer PoV Size with Increasing Numbers of Users ( #8571 )
...
* write benchmark for transfer increasing users
* cargo run --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
Co-authored-by: Parity Benchmarking Bot <admin@parity.io >
2021-04-10 12:31:45 +00:00
Pierre Krieger
8608c2eae4
Cap the warp sync proof by size, not by fragments ( #8578 )
...
* Cap the warp sync proof by size, not by fragments
* Add a final debug assert
* Check size after
2021-04-09 15:22:47 +00:00
Kian Paimani
373e3a4ddc
clean arithmetic and unify names with the new api ( #8581 )
2021-04-09 16:36:06 +02:00
Liu-Cheng Xu
7e59d172b8
Add trivial improvements to transaction pool ( #8572 )
...
* Add trival improvements to transaction pool
* .
* Add trival improvements to transaction pool
* Update client/transaction-pool/graph/src/future.rs
* Update client/transaction-pool/graph/src/base_pool.rs
* Fix transaction_debug test
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-04-09 11:37:40 +00:00
Gavin Wood
9fa684f2a4
Backing/GetBacking: Abstraction over pluralistic origins for XCM. ( #8579 )
...
* Backing/GetBacking: Abstraction over pluralistic origins for XCM.
* Update frame/support/src/traits/misc.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
* Update frame/support/src/traits/misc.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2021-04-09 11:38:03 +02:00
Xavier Lau
d6f0ce0551
ModuleId to PalletId - part of #8372 ( #8477 )
...
* `ModuleId` to `PalletId` - part of #8372
* fix doc
* move `PalletId` to `frame-support`
* fix compile
* fix tests
* `ModuleId` to `PalletId`
* subcommand `moduleid` to `palletid`
2021-04-09 09:15:40 +00:00
Vladimir Istyufeev
c675310227
Disallow failure for node-bench-regression-guard job ( #8577 )
2021-04-08 22:10:14 +03:00
Gavin Wood
f935dfc1a1
Allow lossless matching for Origin ( #8576 )
...
* Allow lossless matching for Origin
Without these changes, it's difficult/impossible to not lose any filters
when making fine-grained matches against origin.
* whilespace
* Apply suggestions from code review
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2021-04-08 20:06:09 +02:00
Vladimir Istyufeev
d440ef322b
Introduce node-bench-regression-guard to Substrate's pipeline ( #8519 )
...
* Integrate `node-bench-regression-guard` into the pipeline
* Apply @TriplEight's review suggestions
2021-04-08 19:14:36 +02:00
Pierre Krieger
1b939bcb53
Check every minute whether authority-discovery key has changed ( #8575 )
...
* Check every minute whether authority-discovery key has changed
* Fix test
* Fix comment
* Use HashSet for latest_published_keys
* More fixing
* God I'm tired, sorry
2021-04-08 16:41:23 +00:00
Robert Habermeier
1f67933afc
remove real-overseer from polkadot compilation flags ( #8560 )
...
* remove real-overseer
* remove unneeded
2021-04-08 15:13:12 +02:00
Kian Paimani
524fc7d500
Add DefaultNoBound ( #8542 )
...
* Add DefaultNoBound
* Add tests
* Fix
2021-04-08 11:23:55 +00:00
Shawn Tabrizi
c04b44b0a3
Add PoV Tracking to Benchmarking Pipeline ( #8559 )
...
* Added a function to estimate proof size for benchmarking
* integrate proof_size into benchmarking pipeline
* Update client/db/src/bench.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Update client/db/src/bench.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* fix tests
* one more test
* Update bench.rs
* Update utils/frame/benchmarking-cli/src/writer.rs
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
* Update utils/frame/benchmarking-cli/src/command.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
Co-authored-by: arkpar <arkady.paronyan@gmail.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2021-04-08 12:54:46 +02:00