1. May 26, 2021
  2. May 25, 2021
    • Alexander Theißen's avatar
      contracts: Fix some minor bugs around instantiation (#8879) · c92d4a26
      Alexander Theißen authored
      
      
      * Fix output of wrongly outputted error
      
      The "Tombstoned a contract that is below the subsistence threshold: {:?}" was
      triggered when too few balance was provided. It was a false alarm.
      
      * Fix return of wrong code_len
      
      * Split up `NotCallable` into more fine grained errors
      
      * Fix typos in docs
      
      Co-authored-by: default avatarKeith Yeung <[email protected]>
      
      * RentNotPayed -> RentNotPaid
      
      * Fix typo: payed -> paid
      
      It is OK to change the in-storage field name because:
      
      1. The SCALE encoding is not based on names only on position.
      2. The struct is not public (only to the crate).
      
      Co-authored-by: default avatarKeith Yeung <[email protected]>
      c92d4a26
    • Denis_P's avatar
      Fix stderr in new Rust nightly (#8904) · 2928e428
      Denis_P authored
      * CI: revert me
      
      * fix stderr
      
      * CI: revert me
      
      * typo
      
      * more stderr fixes
      
      * Revert "CI: revert me"
      
      This reverts commit 5f47effc4965fa5c0c2a6ed92e434a6adb6b1dce.
      
      * Revert "CI: revert me"
      
      This reverts commit 7f785660c797b703dd36272cbe313056dd7a1858.
      2928e428
  3. May 23, 2021
  4. May 21, 2021
  5. May 20, 2021
  6. May 19, 2021
  7. May 18, 2021
  8. May 17, 2021
  9. May 15, 2021
  10. May 14, 2021
    • Keith Yeung's avatar
      Implement StorageNMap (#8635) · 033d8289
      Keith Yeung authored
      
      
      * Implement StorageNMap
      
      * Change copyright date to 2021
      
      * Rewrite keys to use impl_for_tuples instead of recursion
      
      * Implement prefix iteration on StorageNMap
      
      * Implement EncodeLike for key arguments
      
      * Rename KeyGenerator::Arg to KeyGenerator::KArg
      
      * Support StorageNMap in decl_storage and #[pallet::storage] macros
      
      * Use StorageNMap in assets pallet
      
      * Support migrate_keys in StorageNMap
      
      * Reduce line characters on select files
      
      * Refactor crate imports in decl_storage macros
      
      * Some more line char reductions and doc comment update
      
      * Update UI test expectations
      
      * Revert whitespace changes to untouched files
      
      * Generate Key struct instead of a 1-tuple when only 1 pair of key and hasher is provided
      
      * Revert formatting changes to unrelated files
      
      * Introduce KeyGeneratorInner
      
      * Add tests for StorageNMap in FRAMEv2 pallet macro
      
      * Small fixes to unit tests for StorageNMap
      
      * Bump runtime metadata version
      
      * Remove unused import
      
      * Update tests to use runtime metadata v13
      
      * Introduce and use EncodeLikeTuple as a trait bound for KArg
      
      * Add some rustdocs
      
      * Revert usage of StorageNMap in assets pallet
      
      * Make use of ext::PunctuatedTrailing
      
      * Add rustdoc for final_hash
      
      * Fix StorageNMap proc macro expansions for single key cases
      
      * Create associated const in KeyGenerator for hasher metadata
      
      * Refactor code according to comments from Basti
      
      * Add module docs for generator/nmap.rs
      
      * Re-export storage::Key as NMapKey in pallet prelude
      
      * Seal the EncodeLikeTuple trait
      
      * Extract sealing code out of key.rs
      
      Co-authored-by: default avatarShawn Tabrizi <[email protected]>
      033d8289
  11. May 13, 2021
    • Alexander Theißen's avatar
      contracts: Move `Schedule` from Storage to `Config` (#8773) · 1ac95b6b
      Alexander Theißen authored
      * Move `Schedule` from Storage to Config
      
      * Updated CHANGELOG
      
      * Fix nits from review
      
      * Fix migration
      
      * Print the debug buffer as tracing message
      
      * Use `debug` instead of `trace` and update README
      
      * Add additional assert to test
      
      * Rename `schedule_version` to `instruction_weights_version`
      
      * Fixed typo
      
      * Added more comments to wat fixtures
      
      * Add clarification for the `debug_message` field
      1ac95b6b
  12. May 12, 2021
  13. May 10, 2021
  14. May 08, 2021
  15. May 07, 2021
    • Peter Goodspeed-Niklaus's avatar
      Relax `BoundedVec` trait restrictions (#8749) · b6897901
      Peter Goodspeed-Niklaus authored
      * requiring users to maintain an unchecked invariant is unsafe
      
      * relax trait restrictions on BoundedVec<T, S>
      
      A normal `Vec<T>` can do many things without any particular trait
      bounds on `T`. This commit relaxes the bounds on `BoundedVec<T, S>`
      to give it similar capabilities.
      b6897901
    • Alexander Theißen's avatar
      contracts: Refactor the exec module (#8604) · 9e894ce1
      Alexander Theißen authored
      
      
      * contracts: Add default implementation for Executable::occupied_storage()
      
      * contracts: Refactor the exec module
      
      * Let runtime specify the backing type of the call stack
      
      This removes the need for a runtime check of the specified
      `MaxDepth`. We can now garantuee that we don't need to
      allocate when a new call frame is pushed.
      
      * Fix doc typo
      
      Co-authored-by: default avatarGuillaume Thiolliere <[email protected]>
      
      * 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
      
      * Review nits
      
      * Fix defect in contract info caching behaviour
      
      * Add more docs
      
      * Fix wording and typos
      
      Co-authored-by: default avatarGuillaume Thiolliere <[email protected]>
      Co-authored-by: default avatarParity Benchmarking Bot <[email protected]>
      9e894ce1
    • Peter Goodspeed-Niklaus's avatar
      `#[derive(MaxEncodedLen)]` (#8737) · 17a1997d
      Peter Goodspeed-Niklaus authored
      * impl #[derive(MaxEncodedLen)] for structs
      
      * impl #[derive(MaxEncodedLen)] for enums, unions
      
      * break long comments onto multiple lines
      
      * add doc for public item
      
      * add examples to macro documentation
      
      * move MaxEncodedLen macro docs, un-ignore doc-tests
      17a1997d
  16. May 06, 2021
  17. May 05, 2021