Delete 1D weight ctors and set explicit deprecation dates (#14397)

* Delete old weight functions

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add explicit removal dates

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Upate UI tests

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
This commit is contained in:
Oliver Tale-Yazdi
2023-06-16 14:09:28 +02:00
committed by GitHub
parent ebf7c1c478
commit 0895f4904f
10 changed files with 17 additions and 34 deletions
+1 -1
View File
@@ -899,7 +899,7 @@ impl<T> PaysFee<T> for (u64, Pays) {
/// in an externalities-provided environment. Implement
/// [`IntegrityTest`](./trait.IntegrityTest.html) trait.
#[macro_export]
#[deprecated(note = "Will be removed soon; use the attribute `#[pallet]` macro instead.
#[deprecated(note = "Will be removed after July 2023; use the attribute `#[pallet]` macro instead.
For more info, see: <https://github.com/paritytech/substrate/pull/13705>")]
macro_rules! decl_module {
// Entry point #1.
+1 -1
View File
@@ -67,7 +67,7 @@ pub use sp_runtime::traits::{BadOrigin, LookupError};
/// For instantiable modules you also need to give the instance generic type and bound to the
/// error declaration.
#[macro_export]
#[deprecated(note = "Will be removed soon; use the attribute `#[pallet]` macro instead.
#[deprecated(note = "Will be removed after July 2023; use the attribute `#[pallet]` macro instead.
For more info, see: <https://github.com/paritytech/substrate/pull/13705>")]
macro_rules! decl_error {
(
+1 -1
View File
@@ -101,7 +101,7 @@
/// # fn main() {}
/// ```
#[macro_export]
#[deprecated(note = "Will be removed soon; use the attribute `#[pallet]` macro instead.
#[deprecated(note = "Will be removed after July 2023; use the attribute `#[pallet]` macro instead.
For more info, see: <https://github.com/paritytech/substrate/pull/13705>")]
macro_rules! decl_event {
(
@@ -37,18 +37,16 @@ pub struct StorageIterator<T> {
impl<T> StorageIterator<T> {
/// Construct iterator to iterate over map items in `module` for the map called `item`.
#[deprecated(
note = "Please use the storage_iter or storage_iter_with_suffix functions instead"
)]
#[deprecated(note = "Will be removed after July 2023; Please use the storage_iter or \
storage_iter_with_suffix functions instead")]
pub fn new(module: &[u8], item: &[u8]) -> Self {
#[allow(deprecated)]
Self::with_suffix(module, item, &[][..])
}
/// Construct iterator to iterate over map items in `module` for the map called `item`.
#[deprecated(
note = "Please use the storage_iter or storage_iter_with_suffix functions instead"
)]
#[deprecated(note = "Will be removed after July 2023; Please use the storage_iter or \
storage_iter_with_suffix functions instead")]
pub fn with_suffix(module: &[u8], item: &[u8], suffix: &[u8]) -> Self {
let mut prefix = Vec::new();
let storage_prefix = storage_prefix(module, item);
@@ -102,18 +100,16 @@ pub struct StorageKeyIterator<K, T, H: ReversibleStorageHasher> {
impl<K, T, H: ReversibleStorageHasher> StorageKeyIterator<K, T, H> {
/// Construct iterator to iterate over map items in `module` for the map called `item`.
#[deprecated(
note = "Please use the storage_key_iter or storage_key_iter_with_suffix functions instead"
)]
#[deprecated(note = "Will be removed after July 2023; Please use the storage_key_iter or \
storage_key_iter_with_suffix functions instead")]
pub fn new(module: &[u8], item: &[u8]) -> Self {
#[allow(deprecated)]
Self::with_suffix(module, item, &[][..])
}
/// Construct iterator to iterate over map items in `module` for the map called `item`.
#[deprecated(
note = "Please use the storage_key_iter or storage_key_iter_with_suffix functions instead"
)]
#[deprecated(note = "Will be removed after July 2023; Please use the storage_key_iter or \
storage_key_iter_with_suffix functions instead")]
pub fn with_suffix(module: &[u8], item: &[u8], suffix: &[u8]) -> Self {
let mut prefix = Vec::new();
let storage_prefix = storage_prefix(module, item);