mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 11:41:02 +00:00
Companion for substrate#11523 (#1390)
* Align to changes in substrate: `sp_io::storage::get` now returns `Bytes`
* Update substrate and polkadot to the newest master
* update lockfile for {"substrate", "polkadot"}
Co-authored-by: parity-processbot <>
This commit is contained in:
Generated
+373
-414
File diff suppressed because it is too large
Load Diff
@@ -6,6 +6,7 @@ edition = "2021"
|
|||||||
description = "Base pallet for cumulus-based parachains"
|
description = "Base pallet for cumulus-based parachains"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
bytes = { version = "1.1.0", default-features = false }
|
||||||
codec = { package = "parity-scale-codec", version = "3.0.0", default-features = false, features = ["derive"] }
|
codec = { package = "parity-scale-codec", version = "3.0.0", default-features = false, features = ["derive"] }
|
||||||
environmental = { version = "1.1.2", default-features = false }
|
environmental = { version = "1.1.2", default-features = false }
|
||||||
impl-trait-for-tuples = "0.2.1"
|
impl-trait-for-tuples = "0.2.1"
|
||||||
|
|||||||
@@ -205,8 +205,8 @@ fn host_storage_set(key: &[u8], value: &[u8]) {
|
|||||||
with_externalities(|ext| ext.place_storage(key.to_vec(), Some(value.to_vec())))
|
with_externalities(|ext| ext.place_storage(key.to_vec(), Some(value.to_vec())))
|
||||||
}
|
}
|
||||||
|
|
||||||
fn host_storage_get(key: &[u8]) -> Option<Vec<u8>> {
|
fn host_storage_get(key: &[u8]) -> Option<bytes::Bytes> {
|
||||||
with_externalities(|ext| ext.storage(key).clone())
|
with_externalities(|ext| ext.storage(key).map(|value| value.into()))
|
||||||
}
|
}
|
||||||
|
|
||||||
fn host_storage_exists(key: &[u8]) -> bool {
|
fn host_storage_exists(key: &[u8]) -> bool {
|
||||||
|
|||||||
@@ -347,7 +347,7 @@ pub struct TestOnRuntimeUpgrade;
|
|||||||
|
|
||||||
impl OnRuntimeUpgrade for TestOnRuntimeUpgrade {
|
impl OnRuntimeUpgrade for TestOnRuntimeUpgrade {
|
||||||
fn on_runtime_upgrade() -> frame_support::weights::Weight {
|
fn on_runtime_upgrade() -> frame_support::weights::Weight {
|
||||||
assert_eq!(sp_io::storage::get(TEST_RUNTIME_UPGRADE_KEY), Some(vec![1, 2, 3, 4]));
|
assert_eq!(sp_io::storage::get(TEST_RUNTIME_UPGRADE_KEY), Some(vec![1, 2, 3, 4].into()));
|
||||||
|
|
||||||
1
|
1
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user