Closed Maar-io closed 1 year ago
The Weights
are now a struct with a u64
field named ref_time
. I think some of the build errors can be fixed by using the Weights::from_ref_time(u64)
. Here is the file https://github.com/paritytech/substrate/blob/c6ebc1e73f85deba349db0ea785ad53addb6f69f/frame/support/src/weights/weight_v2.rs#L45
Need to remove the commented out code. I'll run this in my environment. Do the integration tests pass, as well?
Another thought is on downstream implementations. These chains will need to be notified so they do the appropriate storage migrations for the changes to Storage.
Other than these items, it LGTM. Nice work Maario
This PR introduces benchmark test for
pallet-rmrk-core
The major change in the most of the files is that following construct could not be used in the
benchmark!
macropallet-uniques
associated typeCollectionId
does not supportFrom<u32>
and it is therefore used asT::CollectionId
replacing the use of locally definedCollectionId
.pallet-uniques
associated typeItemId
does not supportFrom<u32>
and it is therefore used asT::ItemId
replacing the use of locally definedNftId
.ExtBuilder::default()
in order to accommodate benchmark unit tests.Another big change is the removal of
CollectionIndex
storage item and allowing caller to give the collection_id as an argument. It is not likely that rmrk pallets will be sole user of the uniques ids. Second reason for removingCollectionIndex
is due to change ofcollection_id
type fromu32
to Unique's associated typeT::CollectionId,
After this change try_mutate will not work over CollectionIndexremoved storage item
CollectionIndex
removed rpc call
last_collection_idx()
see above[x] unittest updated and passing
[x] benchmark tests work on runtime and on MockRuntime
[x] runtime lib updated with Weights
Next steps