Skip to content
This repository has been archived by the owner on Oct 22, 2024. It is now read-only.

Commit

Permalink
fixes after rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
claravanstaden authored and claravanstaden committed Oct 29, 2023
1 parent 4f5d693 commit 506b6b1
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 16 deletions.
3 changes: 1 addition & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -550,6 +550,7 @@ impl snowbridge_outbound_queue::Config for Runtime {
type DeliveryFeePerGas = DeliveryFeePerGas;
type DeliveryRefundPerGas = DeliveryRefundPerGas;
type DeliveryReward = DeliveryReward;
type WeightToFee = WeightToFee;
type WeightInfo = weights::snowbridge_outbound_queue::WeightInfo<Runtime>;
}

Expand Down Expand Up @@ -981,10 +982,14 @@ impl_runtime_apis! {
}
}

impl snowbridge_outbound_queue_runtime_api::OutboundQueueApi<Block> for Runtime {
impl snowbridge_outbound_queue_runtime_api::OutboundQueueApi<Block, Balance> for Runtime {
fn prove_message(leaf_index: u64) -> Option<snowbridge_outbound_queue::MerkleProof> {
snowbridge_outbound_queue::api::prove_message::<Runtime>(leaf_index)
}

fn calculate_fee(message: Message) -> Option<Balance> {
snowbridge_outbound_queue::api::calculate_fee::<Runtime>(message)
}
}

#[cfg(feature = "try-runtime")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,24 +41,32 @@ impl<T: frame_system::Config> snowbridge_outbound_queue::WeightInfo for WeightIn
// Proof Size summary in bytes:
// Measured: `42`
// Estimated: `3485`
// Minimum execution time: 38_000_000 picoseconds.
Weight::from_parts(38_000_000, 0)
.saturating_add(Weight::from_parts(0, 3485))
.saturating_add(T::DbWeight::get().reads(4))
.saturating_add(T::DbWeight::get().writes(4))
// Minimum execution time: 39_000_000 picoseconds.
Weight::from_parts(39_000_000, 3485)
.saturating_add(T::DbWeight::get().reads(4_u64))
.saturating_add(T::DbWeight::get().writes(4_u64))
}
/// Storage: EthereumOutboundQueue MessageLeaves (r:1 w:0)
/// Proof Skipped: EthereumOutboundQueue MessageLeaves (max_values: Some(1), max_size: None, mode: Measured)
/// Storage: System Digest (r:1 w:1)
/// Proof Skipped: System Digest (max_values: Some(1), max_size: None, mode: Measured)
fn on_finalize() -> Weight {
fn commit_messages() -> Weight {
// Proof Size summary in bytes:
// Measured: `1094`
// Estimated: `2579`
// Minimum execution time: 28_000_000 picoseconds.
Weight::from_parts(28_000_000, 0)
.saturating_add(Weight::from_parts(0, 2579))
.saturating_add(T::DbWeight::get().reads(2))
.saturating_add(T::DbWeight::get().writes(1))
Weight::from_parts(28_000_000, 2579)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(1_u64))
}

fn commit_one_message() -> Weight {
// Proof Size summary in bytes:
// Measured: `1094`
// Estimated: `2579`
// Minimum execution time: 9_000_000 picoseconds.
Weight::from_parts(9_000_000, 1586)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(1_u64))
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -224,13 +224,10 @@ impl Contains<RuntimeCall> for SafeCallFilter {
>::initialize { .. }) |
RuntimeCall::EthereumBeaconClient(
snowbridge_ethereum_beacon_client::Call::force_checkpoint { .. } |
snowbridge_ethereum_beacon_client::Call::set_owner { .. } |
snowbridge_ethereum_beacon_client::Call::set_operating_mode { .. },
) | RuntimeCall::EthereumInboundQueue(
snowbridge_inbound_queue::Call::set_owner { .. } |
snowbridge_inbound_queue::Call::set_operating_mode { .. },
) | RuntimeCall::EthereumOutboundQueue(
snowbridge_outbound_queue::Call::set_owner { .. } |
snowbridge_outbound_queue::Call::set_operating_mode { .. },
) | RuntimeCall::EthereumControl(..)
)
Expand Down

0 comments on commit 506b6b1

Please sign in to comment.