Guillaume Thiolliere
48810cd75b
Make pallets use construct_runtime ( #7950 )
...
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: David <dvdplm@gmail.com >
2021-01-25 13:20:47 +01:00
Bastian Köcher
e3e651f72c
Happy new year ( #7814 )
...
* Happy new year
Updates the copyright years and fixes wrong license headers.
* Fix the template
* Split HEADER into HEADER-APACHE & HEADER-GPL
2021-01-04 09:03:13 +00:00
Guillaume Thiolliere
1cbfc9257f
Rename pallet trait Trait to Config ( #7599 )
...
* rename Trait to Config
* add test asserting using Trait is still valid.
* fix ui tests
2020-11-30 14:34:54 +00:00
Bastian Köcher
ed1d0fa815
Implements pallet versioning ( #7208 )
...
* Start
* Make macro work
* Rename `ModuleToIndex` to `PalletRuntimeSetup`
Besides the renaming it also adds support getting the name of a pallet
as configured in the runtime.
* Rename it to `PalletInfo`
* Remove accidentally added files
* Some work
* Make everything compile
* Adds a test and fixes some bugs
* Implement ordering for `PalletVersion`
* Apply suggestions from code review
* Review feedback
* Update frame/support/src/dispatch.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
* Update frame/support/src/dispatch.rs
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
* Fix compilation
* Fix test
* Fix doc test
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com >
2020-10-21 19:05:52 +02:00
Guillaume Thiolliere
98951b33a9
Allow pallet in construct_runtime to have fixed index ( #6969 )
...
* implement index for pallet + some tests
* add test and doc
* remove deprecated and document behavior
* update internal doc
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* address review
* use index for all module, break construct_runtime
* fix line length
* implement migration helper funciton in scheduler
* fix start at index 0
* Update frame/scheduler/src/lib.rs
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
* Update frame/support/procedural/src/lib.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* bump frame-metadata crate
* factorize
* avoid some unwrap and remove nightly join
* Update frame/support/src/event.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* fix test
* add test and improve error message
* factorize test
* keep iterator, and use slice instead of vec
* refactor to avoid to have expects
* small refactor
* Test something
* Make sure we update the `Cargo.lock`
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* return 2 error
* Apply suggestions from code review
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
* Update frame/scheduler/src/lib.rs
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
* fix typo
* Revert "fix typo"
This reverts commit f2de8f2db34e8ac72bc9c34437c60dca3fa4ac22.
* Revert "Update frame/scheduler/src/lib.rs"
This reverts commit 6feb4605c6f784b64591e229de7a6fec6dbffb4b.
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com >
Co-authored-by: Bastian Köcher <git@kchr.de >
Co-authored-by: Alexander Popiak <alexander.popiak@parity.io >
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com >
2020-09-22 14:54:03 +00:00
Bastian Köcher
86594727d9
Rename ModuleToIndex to PalletRuntimeSetup ( #7148 )
...
* Rename `ModuleToIndex` to `PalletRuntimeSetup`
Besides the renaming it also adds support getting the name of a pallet
as configured in the runtime.
* Rename it to `PalletInfo`
* Remove accidentally added files
2020-09-22 13:39:56 +00:00
Shawn Tabrizi
50568fcc19
Disambiguate BlockNumber type in decl_module ( #7061 )
...
* Disambiguate `BlockNumber` type in `decl_module`
* fix `frame-support-tests`
* fix ui tests
* fix trait order
2020-09-10 01:47:24 +02:00
Guillaume Thiolliere
622dff9ca7
Impl integrity test for runtime ( #6356 )
...
* impl integrity test for runtime
* Update frame/support/src/traits.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* Update frame/support/procedural/src/construct_runtime/mod.rs
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
* use thread local
* update doc
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Gavin Wood <gavin@parity.io >
2020-06-16 13:10:10 +02:00