Skip to content
This repository has been archived by the owner on Sep 28, 2023. It is now read-only.

[DO NOT MERGE] Update to polkadot-v0.9.40 #159

Closed
wants to merge 9 commits into from
94 changes: 47 additions & 47 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -72,77 +72,77 @@ serde_json = { version = "1.0.92" }

# EVM & Ethereum
# (wasm)
evm = { version = "0.37.0", default-features = false }
evm = { version = "0.39.0", default-features = false }
ethereum-types = { version = "0.14", default-features = false }
ethereum = { version = "0.14.0", default-features = false }
evm-gasometer = { version = "0.37.0", default-features = false }
evm-runtime = { version = "0.37.0", default-features = false }
evm-gasometer = { version = "0.39.0", default-features = false }
evm-runtime = { version = "0.39.0", default-features = false }

# jsonrpsee
# (wasm)
jsonrpsee = { version = "0.16.2", default-features = false }

# Substrate
# (wasm)
frame-support = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
frame-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-std = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-arithmetic = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-staking = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-runtime-interface = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-externalities = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-io = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
frame-benchmarking = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
sp-keyring = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
frame-support = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
frame-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-std = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-arithmetic = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-staking = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-runtime-interface = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-externalities = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-io = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
frame-benchmarking = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
sp-keyring = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }

# (native)
sp-consensus-aura = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sp-tracing = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sc-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sc-transaction-pool-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sp-blockchain = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sc-client-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sc-network = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sc-utils = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sp-block-builder = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sp-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39" }
sp-consensus-aura = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sp-tracing = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sc-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sc-transaction-pool-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sp-blockchain = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sc-client-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sc-network = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sc-utils = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sp-block-builder = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }
sp-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40" }

# Substrate pallets
# (wasm)
pallet-contracts = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-contracts-primitives = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-balances = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-timestamp = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-authorship = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-session = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-aura = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-assets = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.39", default-features = false }
pallet-contracts = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-contracts-primitives = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-balances = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-timestamp = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-authorship = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-session = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-aura = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }
pallet-assets = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.40", default-features = false }

# Polkadot
# (wasm)
xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.39", default-features = false }
xcm-executor = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.39", default-features = false }
polkadot-parachain = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.39", default-features = false }
xcm-builder = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.39", default-features = false }
xcm = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.40", default-features = false }
xcm-executor = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.40", default-features = false }
polkadot-parachain = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.40", default-features = false }
xcm-builder = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.40", default-features = false }

# (native)
polkadot-runtime-parachains = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.39" }
polkadot-runtime-parachains = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.40" }

# Frontier
# (wasm)
fp-evm = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39", default-features = false }
pallet-evm = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39", default-features = false, features = ["forbid-evm-reentrancy"] }
fp-evm = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40", default-features = false }
pallet-evm = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40", default-features = false, features = ["forbid-evm-reentrancy"] }

# (native)
fp-rpc = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39" }
fc-rpc-core = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39" }
fc-rpc = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39" }
fc-consensus = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39" }
fc-db = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39" }
fc-storage = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.39" }
fp-rpc = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40" }
fc-rpc-core = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40" }
fc-rpc = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40" }
fc-consensus = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40" }
fc-db = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40" }
fc-storage = { git = "https://github.com/AstarNetwork/frontier", branch = "polkadot-v0.9.40" }

# Local deps
# (wasm)
Expand Down
3 changes: 1 addition & 2 deletions chain-extensions/xvm/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,7 @@ where
pallet_xvm::Pallet::<T>::xvm_bare_call(xvm_context, caller, to, input);

let actual_weight = pallet_xvm::consumed_weight(&call_result);
// TODO: implement proof of size refund.
env.adjust_weight(charged_weight, Weight::from_ref_time(actual_weight));
ashutoshvarma marked this conversation as resolved.
Show resolved Hide resolved
env.adjust_weight(charged_weight, Weight::from_parts(actual_weight, 0));

match call_result {
Ok(success) => {
Expand Down
2 changes: 1 addition & 1 deletion frame/block-reward/src/mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ construct_runtime!(
parameter_types! {
pub const BlockHashCount: u64 = 250;
pub BlockWeights: frame_system::limits::BlockWeights =
frame_system::limits::BlockWeights::simple_max(Weight::from_ref_time(1024));
frame_system::limits::BlockWeights::simple_max(Weight::from_parts(1024, 0));
}

impl frame_system::Config for TestRuntime {
Expand Down
8 changes: 4 additions & 4 deletions frame/block-reward/src/weights.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Proof: BlockReward RewardDistributionConfigStorage (max_values: Some(1), max_size: Some(24), added: 519, mode: MaxEncodedLen)
fn set_configuration() -> Weight {
// Minimum execution time: 9_085 nanoseconds.
Weight::from_ref_time(9_328_000)
.saturating_add(Weight::from_proof_size(0))
Weight::from_parts(9_328_000, 0)
.saturating_add(Weight::from_parts(0, 0))
.saturating_add(T::DbWeight::get().writes(1_u64))
}
}
Expand All @@ -70,8 +70,8 @@ impl WeightInfo for () {
// Proof: BlockReward RewardDistributionConfigStorage (max_values: Some(1), max_size: Some(24), added: 519, mode: MaxEncodedLen)
fn set_configuration() -> Weight {
// Minimum execution time: 9_085 nanoseconds.
Weight::from_ref_time(9_328_000)
.saturating_add(Weight::from_proof_size(0))
Weight::from_parts(9_328_000, 0)
.saturating_add(Weight::from_parts(0, 0))
.saturating_add(RocksDbWeight::get().writes(1_u64))
}
}
1 change: 0 additions & 1 deletion frame/collator-selection/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@ pub mod pallet {
}

#[pallet::pallet]
#[pallet::generate_store(pub(super) trait Store)]
#[pallet::without_storage_info]
pub struct Pallet<T>(_);

Expand Down
Loading