* Emit a PaymentParameters event once per block
This contains per-block paramaters need to calculate
fees off-chain.
* Add WeightToFee trait
* Add documentation to polynomial types
* Ignore pseudo code snippet for doc tests
* Use `Mul` implementation of Perbill
* Add tests for WeightToFeePolynomial
* Revert "Emit a PaymentParameters event once per block"
This reverts commit 6c4763baff3d8179676a3c1660fe7063fd56a8ca.
Co-authored-by: Gavin Wood <gavin@parity.io>
* Move weight values to `frame_support`
* more accurate comment
* update balances
* vesting
* update util
* Add weight to time constants
* use weight constants in weights
* update tests
* Introduce `BlockExectionWeight` and `ExtrinsicBaseWeight`
* Add new traits everywhere
* Missed one update
* fix tests
* Update `check_weight` logic
* introduce `max_extrinsic_weight` function
* fix + add tests
* format nits
* remove println
* make test a bit more clear
* Remove minimum weight
* newlines left over from find/replace
* Fix test, improve clarity
* Fix executor tests
* Extrinsic base weight same as old `MINIMUM_WEIGHT`
* fix example test
* Expose constants
* Add test for full block with operational and normal
* Initiate test environment with `BlockExecutionWeight` weight
* format nit
* Update frame/system/src/lib.rs
Co-Authored-By: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
* Replace `TransactionBaseFee` with `ExtrinsicBaseWeight` (#5761)
* Replace `TransactionBaseFee` with `ExtrinsicBaseFee`
* Fix stuff
* Fix and make tests better
* Forgot to update this test
* Fix priority number in test
* Remove minimum weight from merge
* Fix weight in contracts
* remove `TransactionBaseFee` from contract tests
* Let `register_extra_weight_unchecked` go past `MaximumBlockWeight`
* address feedback
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
This reduces the usage of `Blake2Hasher` in the code base and replaces
it with `BlakeTwo256`. The most important change is the removal of the
custom extern function for `Blake2Hasher`. The runtime `Hash` trait is
now also simplified and directly requires that the implementing type
implements `Hashable`.
* Initially scoping out of the problem
* Remove need for exiry in balance locks.
* Remove expiry from locks.
* Remove supefluous balance test
* Amalgamate pieces of balance module
* Split out vesting
* Fix tests
* Fixes for vesting.
* Docs.
* Weight docs.
* Refactor things in terms of set_balances.
* Switch out ED to be free + reserved.
* Remove on_free_balance_zero and some docs.
* Build fixes
* Update frame/vesting/src/lib.rs
Co-Authored-By: Xiliang Chen <xlchen1291@gmail.com>
* Update frame/vesting/src/lib.rs
Co-Authored-By: Xiliang Chen <xlchen1291@gmail.com>
* Migration
* Remove superfluous code.
* Test fixes
* Fix some tests
* Fix repatriate reserve
* Fixes
* Add test for migration
* Final cleanups
* Fix
* Indentation.
* Undo unneeded referencing
* Bump runtime version
* Fixes
Co-authored-by: Xiliang Chen <xlchen1291@gmail.com>
* Extend `Proposer` to optionally generate a proof of the proposal
* Something
* Refactor sr-api to not depend on client anymore
* Fix benches
* Apply suggestions from code review
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Apply suggestions from code review
* Introduce new `into_storage_changes` function
* Switch to runtime api for `execute_block` and don't require `H256`
anywhere in the code
* Put the `StorageChanges` into the `Proposal`
* Move the runtime api error to its own trait
* Adds `StorageTransactionCache` to the runtime api
This requires that we add `type NodeBlock = ` to the
`impl_runtime_apis!` macro to work around some bugs in rustc :(
* Remove `type NodeBlock` and switch to a "better" hack
* Start using the transaction cache from the runtime api
* Make it compile
* Move `InMemory` to its own file
* Make all tests work again
* Return block, storage_changes and proof from Blockbuilder::bake()
* Make sure that we use/set `storage_changes` when possible
* Add test
* Fix deadlock
* Remove accidentally added folders
* Introduce `RecordProof` as argument type to be more explicit
* Update client/src/client.rs
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Update primitives/state-machine/src/ext.rs
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Integrates review feedback
* Remove `unsafe` usage
* Update client/block-builder/src/lib.rs
Co-Authored-By: Benjamin Kampmann <ben@gnunicorn.org>
* Update client/src/call_executor.rs
* Bump versions
Co-authored-by: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
Co-authored-by: Benjamin Kampmann <ben.kampmann@googlemail.com>