- Apr 13, 2021
-
-
Alexander Theißen authored
* 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 <[email protected]> Co-authored-by: Andrew Jones <[email protected]>
-
Falco Hirschenberger authored
* 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 <[email protected]> * Update frame/contracts/src/exec.rs Co-authored-by: Shawn Tabrizi <[email protected]> * Update frame/democracy/src/benchmarking.rs Co-authored-by: Shawn Tabrizi <[email protected]> * Update frame/transaction-payment/src/lib.rs Co-authored-by: Shawn Tabrizi <[email protected]> * 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 <[email protected]> Co-authored-by: Shawn Tabrizi <[email protected]>
-
- Apr 09, 2021
-
-
Kian Paimani authored
-
- Apr 07, 2021
-
-
Falco Hirschenberger authored
* Add more asserts and debug_asserts fixing #8106 * Remove assignments * convert debug_assert to runtime assert
-
- Apr 01, 2021
-
-
Gavin Wood authored
* Introduce OnSetCode type into system config trait. * Docs. * Fixes * Fixes
-
- Mar 24, 2021
-
-
Alexander Theißen authored
* contracts: Remove types and storage from the public interface * contracts: Remove current_schedule() getter * contracts: Improve documentation * Update README.md * Fix integration test
-
- Mar 23, 2021
-
-
thiolliere authored
-
Alexander Theißen authored
* Allow contract callable functions to specify the module * Add new version of `seal_random` * Fix overlong lines * Fix benchmarking code * Update README.md * Replace Module by Pallet
-
Alexander Theißen authored
-
- Mar 21, 2021
-
-
Alexander Theißen authored
-
- Mar 18, 2021
-
-
sacha-l authored
-
Shaun Wang authored
* Use 'Pallet' struct in construct_runtime. * Fix genesis and metadata macro. * Fix 'Pallet' type alias. * Replace 'Module' with 'Pallet' for all construct_runtime use cases. * Replace more deprecated 'Module' struct. * Bring back AllModules and AllPalletsWithSystem type, but deprecate them. * Replace deprecated 'Module' struct from merge master. * Minor fix. * Fix UI tests. * Revert UI override in derive_no_bound. * Fix more deprecated 'Module' use from master branch. * Fix more deprecated 'Module' use from master branch.
-
- Mar 16, 2021
-
-
Bastian Köcher authored
-
Gavin Wood authored
* Initial abstraction * Alter rest of APIs * Fixes * Some extra getters in Gilt pallet. * Refactor Gilt to avoid u128 conversions * Simplify and improve pow in per_things * Add scalar division to per_things * Renaming from_fraction -> from_float, drop _approximation * Fixes * Fixes * Fixes * Fixes * Make stuff build * Fixes * Fixes * Fixes * Fixes * Update .gitignore Co-authored-by: Kian Paimani <[email protected]> * Update frame/gilt/src/lib.rs Co-authored-by: Kian Paimani <[email protected]> * Update frame/gilt/src/mock.rs Co-authored-by: Kian Paimani <[email protected]> * Fixes * Fixes * Fixes Co-authored-by: Shawn Tabrizi <[email protected]> Co-authored-by: Kian Paimani <[email protected]>
-
- Mar 12, 2021
-
-
Alexander Theißen authored
* contracts: Expose rent parameter to contracts * cargo run --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs * Fix typos * Improve comments * Add rent parameter weights * Allow deploying a new schedule with the same version * Add storage migration for new schedule * Only decode the schedule version in storage migration * Remove confusing docs * Replace original_code_len() by aggregate_code_len() Co-authored-by: Parity Benchmarking Bot <[email protected]>
-
- Mar 10, 2021
-
-
asynchronous rob authored
* more clear randomness API for BABE * babe: move randomness utilities to its own file * node: use babe::RandomnessFromOneEpochAgo in random_seed implementation * frame-support: annotate randomness trait with block number * pallet-randomness-collective-flip: fix for new randomness trait * pallet-society: fix randomness usage * pallet-lottery: fix randomness usage * pallet-contracts: fix randomness usage * pallet-babe: fix randomness usage we need to track when the current and previous epoch started so that we know the block number by each existing on-chain was known * node: fix random_seed * node-template: fix random_seed * frame-support: extend docs * babe: add test for epoch starting block number tracking * babe: fix epoch randomness docs * frame: add todos for dealing with randomness api changes Co-authored-by: André Silva <[email protected]>
-
- Mar 05, 2021
-
-
thiolliere authored
* implement * make default pre/post_upgrade * simplify Cargo.toml * revert removal of outdated/private links * link in pallet-mmr
-
- Mar 02, 2021
-
-
Alexander Theißen authored
* contracts: Use unstable sort for topics * Add warning about non-determinism
-
- Mar 01, 2021
-
-
Bastian Köcher authored
* Init `RuntimeLogger` automatically for each runtime api call This pr change the runtime api in such a way to always and automatically enable the `RuntimeLogger`. This enables the user to use `log` or `tracing` from inside the runtime to create log messages. As logging introduces some extra code and especially increases the size of the wasm blob. It is advised to disable all logging completely with `sp-api/disable-logging` when doing the wasm builds for the on-chain wasm runtime. Besides these changes, the pr also brings most of the logging found in frame to the same format "runtime::*". * Update frame/im-online/src/lib.rs Co-authored-by: Guillaume Thiolliere <[email protected]> * Update test-utils/runtime/Cargo.toml * Fix test * Don't use tracing in the runtime, as we don't support it :D * Fixes Co-authored-by: Guillaume Thiolliere <[email protected]>
-
- Feb 26, 2021
-
-
yjh authored
-
- Feb 25, 2021
-
-
Alexander Theißen authored
* contracts: Update README * contracts: Add CHANGELOG.md * contracts: Bump version to v3.0.0 and allow publish * Typos Co-authored-by: Andrew Jones <[email protected]> * Improve wording in the changelog * contracts: Add reserved field to ContractInfoOf for future proofing * also bump frame-benchmarking * update lockfile Co-authored-by: Andrew Jones <[email protected]> Co-authored-by: Benjamin Kampmann <[email protected]>
-
Benjamin Kampmann authored
* Releasing frame-benchmarking 3.1 * bump in the entire dependency tree
-
thiolliere authored
-
- Feb 22, 2021
-
-
Shawn Tabrizi authored
* Initial piping of returning amount of keys killed * One more test for `None` limit * forgot to update * fix return value * use version 3 * Update to return `KillOutcome` * Update name to KillChildStorageResult
-
Alexander Theißen authored
* contracts: Convert to framev2 * Reduce the API surface of the crate * Remove unused import * Merge import block * Use pallet::metadata to reduce metadata diff * Remove the explicit "Null" from AccountCounter
-
Alexander Theißen authored
* contracts: Consider contract size in weights * Bump spec version * Whitespace fix Co-authored-by: Guillaume Thiolliere <[email protected]> * Correct pre-charged code weight even in the error case * Use the instrumented code size in weight calculation * Charge the cost of re-instrumentation from the gas meter * Fix benchmark * cargo run --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs * Better documentation of return types Co-authored-by: Guillaume Thiolliere <[email protected]> Co-authored-by: Parity Benchmarking Bot <[email protected]>
-
- Feb 16, 2021
-
-
Peter Goodspeed-Niklaus authored
* Create a macro which automates creation of benchmark test suites. * bump impl_version * allow unused on test_bench_by_name * use proper doctest ignore attribute * Explicitly hand the Module to the test suite Much better practice than depending on it showing up implicitly in the namespace. * explicitly import what we need into `mod tests` * bench_module is `ident` not `tt` Co-authored-by: Guillaume Thiolliere <[email protected]> * allow end users to specify arguments for new_test_ext This turned out to be surprisingly easy. On reflection, it turns out that of course the compiler can't eagerly evaluate the function call, but needs to paste it in everywhere desired. * enable explicitly specifying the path to the benchmarks invocation also enable optional trailing commas * Revert "bump impl_version" This reverts commit 0209e4de33fd43873f8cfc6875815d0fd6151e63. * list failing benchmark tests and the errors which caused the failure * harden benchmark tests against internal panics * suppress warning about ignored profiles unfortunately, setting the profile here doesn't do anything; we'd need to set it in every leaf package anyway. However, as this was just making the default explicit anyway, I think it's safe enough to remove entirely. * impl_benchmark_test_suite for assets * impl_benchmark_test_suite for balances * impl_benchmark_test_suite for bounties * impl_benchmark_test_suite for Collective * impl_benchmark_test_suite for Contracts * impl_benchmark_test_suite for Democracy * don't impl_benchmark_test_suite for Elections-Phragmen * impl_benchmark_test_suite for Identity Note that Identity tests currently fail. They failed in an identical way before this change, so as far as I'm concerned, the status quo is good enough for now. * impl_benchmark_test_suite for ImOnline * impl_benchmark_test_suite for indices For this crate also, the test suite fails identically with and without this change, so we can say that this change is not the cause of the tests' failure to compile. * impl_benchmark_test_suite for lottery * impl_benchmark_test_suite for merkle-mountain-range * impl_benchmark_test_suite for Multisig These tests fail identically with and without the change, so the change seems unlikely to be the origin of the failures. * impl_benchmark_test_suite for offences * impl_benchmark_test_suite for Proxy Fails identically with and without this change. * impl_benchmark_test_suite for scheduler * impl_benchmark_test_suite for session It turns out to be important to be able to exclude items marked `#[extra]` sometimes. Who knew? * impl_benchmark_test_suite for staking * impl_benchmark_test_suite for system * impl_benchmark_test_suite for timestamp * impl_benchmark_test_suite for tips * impl_benchmark_test_suite for treasury * impl_benchmark_test_suite for utility Note that benchmark tests fail identically before and after this change. * impl_benchmark_test_suite for vesting * fix wrong module name in impl_benchmark_test_suite in Offences * address line length nits * enable optional keyword argument: exec_name Took a _lot_ of macro-wrangling to get the functionality that I want, but now you have the option to pass in ```rust impl_benchmark_test_suite!( Elections, crate::tests::ExtBuilder::default().desired_members(13).desired_runners_up(7), crate::tests::Test, exec_name = build_and_execute, ); ``` and have it expand out properly. A selected fragment of the expansion: ```rust fn test_benchmarks() { crate::tests::ExtBuilder::default() .desired_members(13) .desired_runners_up(7) .build_and_execute(|| { ``` * get rid of dead code Co-authored-by: Guillaume Thiolliere <[email protected]>
-
- Feb 10, 2021
-
-
Benjamin Kampmann authored
* bumping version for next release * add changelog * add guide
-
Andrew Jones authored
* Initial migration of balances pallet * Fix some errors * Remove unused imports * Formatting and removing some todos * Delete Subtrait * Add genesis builder impls for tests * Fix GenesisConfig impl * Make set_balance visible to tests, rename RawEvent to Event * Fix tests with Event rename etc. * More test RawEvent renames * Even more RawEvent renames * Rename module to pallet in comments * Add PalletInfo impl to avid storage collision, fixes tests * Apply review suggestion: remove trailing a Co-authored-by: David <[email protected]> * BalancesEvent alias * Remove BalancesEvent alias * Review suggestion: remove redundant comment * Apply review suggestion: make vis super * Fis doc links * Add RawEvent alias * Add missing Instance parameter to deprecated RawEvent alias * Fix RawEvent deprecation warnings Co-authored-by: David <[email protected]>
-
- Feb 05, 2021
-
-
Alexander Theißen authored
* contracts: Remove ConfigCache * cargo run --release --features=runtime-benchmarks --manifest-path=bin/node/cli/Cargo.toml -- benchmark --chain=dev --steps=50 --repeat=20 --pallet=pallet_contracts --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./frame/contracts/src/weights.rs --template=./.maintain/frame-weight-template.hbs * Fixup test Co-authored-by: Parity Benchmarking Bot <[email protected]>
-
- Feb 04, 2021
-
-
Andrew Jones authored
* Migrate bounties tests to use construct_runtime * Migrate contracts tests to use construct_runtime * Migrate democracy tests to use construct_runtime * review: rename TreasuryEvent -> TreasuryError
-
Alexander Theißen authored
* contracts: Implement refcounting for wasm code * contracts: Charge rent for code storage * contracts: Fix dispatchables erroneously refunding base costs * Fixed typos in comments. Co-authored-by: Andrew Jones <[email protected]> * Remove awkward empty line * Fix more typos in docs * Fix typos in docs Co-authored-by: Andrew Jones <[email protected]> * Split up complicated expression Co-authored-by: Andrew Jones <[email protected]> * review: Remove unused return value * Fix typos Co-authored-by: Andrew Jones <[email protected]> * review: Fix refcount being reset to one on re-instrumentation * Document evictable_code parameter * Make Executable::execute consume and store itself * Added comments about stale values * Disregard struct size in occupied_storage() Co-authored-by: Andrew Jones <[email protected]>
-
- Feb 03, 2021
-
-
Alexander Theißen authored
-
- Feb 02, 2021
-
-
Alexander Theißen authored
* contracts: Document seal_input * contracts: Improve `ReturnCode` docs. * contracts: Improve seal_restore_to docs * review: Improved wording
-
Alexander Theißen authored
* contracts: Remove redundant bool argument from the eviction event * contracts: Improve event documentation * contracts: Emit event on contract termination
-
- Feb 01, 2021
-
-
yjh authored
-
- Jan 29, 2021
-
-
thiolliere authored
* update cargo.toml * use 2.0 in mmmr
-
- Jan 20, 2021
-
-
Andrew Jones authored
* PRINT_PALLET_UPGRADE=1 cargo check -p frame-system * Copy attributes, imports, mods and type defs * Copy Config trait * Annotate constants * Tabify * Migrate hooks * Upgrade template rename interface to hooks * Migrate pallet call * Migrate Event * Migrate Error * Migrate Origin * Remove optional validate_unsigned * Remove remaining TODO_MAYBE_WHERE_CLAUSE * Overwrite original lib.rs with migrated lib2.rs. * Add required Event IsType constraint * Add disable supertrait check * Fix leftover Trait trait * Add missing pallet prefix for weight attributes * Add missing Error type parameter * Add missing Hooks type parameter * Private call visibility, restore original helper types and helpers etc * Fix hooks type parameter * Rename RawEvent to Event * Add missing storage type annotations * Remove unused imports * Add GenesisConfig helpers for compat * Fix unused import warnings * Update frame/support/procedural/src/storage/print_pallet_upgrade.rs Co-authored-by: Guillaume Thiolliere <[email protected]> * Fix test errors and warnings * Fix remaining errors and warnings * Apply review suggestion: fix formatting Co-authored-by: Guillaume Thiolliere <[email protected]> * Apply review suggestion: annotate BlockLength as constant Co-authored-by: Guillaume Thiolliere <[email protected]> * Apply review suggestion: add triling comma Co-authored-by: Guillaume Thiolliere <[email protected]> * Apply review suggestion: add triling comma Co-authored-by: Guillaume Thiolliere <[email protected]> * Apply review suggestion: add trailing comma Co-authored-by: Guillaume Thiolliere <[email protected]> * Apply review suggestion: fix storage type indentation * Apply review suggestion: remove redundant Origin type alias * Add missing codec derives for BlockLength * Restore module docs * Module -> Pallet renamel * Revert "Update frame/support/procedural/src/storage/print_pallet_upgrade.rs" This reverts commit d2a2d5b6 * Apply review suggestion: merge crate imports Co-authored-by: Alexander Theißen <[email protected]> * Revert "Upgrade template rename interface to hooks" This reverts commit 306f0239 * Single line import * Refactor generated genesis build * Import sp_io::storage * Revert previous, fully qualify sp_io::storage * Fix ui tests * Fix errors after merge, missing changes * Set UpgradedToDualRefCount to true in genesis build * Annotated Runtime version with constant, exposing it via metadata * Add metadata attribute Co-authored-by: Guillaume Thiolliere <[email protected]> Co-authored-by: Alexander Theißen <[email protected]>
-
- Jan 14, 2021
-
-
Alexander Theißen authored
-
Alexander Theißen authored
* Add rent_payed field to the contract info * Don't pay out more as reward as was spent in rent * Make successful evictions free * Add tests to check that surcharge reward is capped by rent payed * review: Fixed docs
-