mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 22:11:02 +00:00
Get dispatch weight from the target chain (when DispatchFeePayment::AtTargetChain is used) (#1430)
* reintroduce From<SourceChain>InboundLaneApi * impl From<Chain>InboundLaneApi for testnet runtimes * use inboundlaneapi in relay * remove unused OutboundXcmWeigher * spelling * added the only test to messages pallet * fmt
This commit is contained in:
committed by
Bastian Köcher
parent
78a43c561a
commit
f0d05de080
@@ -893,15 +893,25 @@ impl_runtime_apis! {
|
||||
lane: bp_messages::LaneId,
|
||||
begin: bp_messages::MessageNonce,
|
||||
end: bp_messages::MessageNonce,
|
||||
) -> Vec<bp_messages::MessageDetails<Balance>> {
|
||||
) -> Vec<bp_messages::OutboundMessageDetails<Balance>> {
|
||||
bridge_runtime_common::messages_api::outbound_message_details::<
|
||||
Runtime,
|
||||
WithMillauMessagesInstance,
|
||||
WithMillauMessageBridge,
|
||||
xcm_config::OutboundXcmWeigher,
|
||||
>(lane, begin, end)
|
||||
}
|
||||
}
|
||||
|
||||
impl bp_millau::FromMillauInboundLaneApi<Block, bp_millau::Balance> for Runtime {
|
||||
fn message_details(
|
||||
lane: bp_messages::LaneId,
|
||||
messages: Vec<(bp_messages::MessagePayload, bp_messages::OutboundMessageDetails<bp_millau::Balance>)>,
|
||||
) -> Vec<bp_messages::InboundMessageDetails> {
|
||||
bridge_runtime_common::messages_api::inbound_message_details::<
|
||||
Runtime,
|
||||
WithMillauMessagesInstance,
|
||||
>(lane, messages)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
||||
@@ -122,8 +122,6 @@ pub type Barrier = (
|
||||
AllowKnownQueryResponses<XcmPallet>,
|
||||
);
|
||||
|
||||
/// Outbound XCM weigher type.
|
||||
pub type OutboundXcmWeigher = xcm_builder::FixedWeightBounds<BaseXcmWeight, (), MaxInstructions>;
|
||||
/// Incoming XCM weigher type.
|
||||
pub type XcmWeigher = xcm_builder::FixedWeightBounds<BaseXcmWeight, Call, MaxInstructions>;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user