mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 04:41:03 +00:00
Update bridges subtree (#1392)
* Move the bridges subtree under root * Squashed 'bridges/' changes from 277f0d5496..e50398d1c5 e50398d1c5 bridges subtree fixes (#2528) 99af07522d Markdown linter (#1309) (#2526) 733ff0fe7a `polkadot-staging` branch: Use polkadot-sdk dependencies (#2524) e8a59f141e Fix benchmark with new XCM::V3 `MAX_INSTRUCTIONS_TO_DECODE` (#2514) 62b185de15 Backport `polkadot-sdk` changes to `polkadot-staging` (#2518) d9658f4d5b Fix equivocation detection containers startup (#2516) (#2517) d65db28a8f Backport: building images from locally built binaries (#2513) 5fdbaf45f6 Start the equivocation detection loop from the complex relayer (#2507) (#2512) 7fbb67de46 Backport: Implement basic equivocations detection loop (#2375) cb7efe245c Manually update deps in polkadot staging (#2371) d17981fc33 #2351 to polkadot-staging (#2359) git-subtree-dir: bridges git-subtree-split: e50398d1c594e4e96df70b0bd376e565d17e8558 * Reapply diener workspacify * Fix Cargo.toml * Fix test * Adjustments
This commit is contained in:
@@ -25,8 +25,8 @@ pallet-xcm = { path = "../../../../../../polkadot/xcm/pallet-xcm", default-featu
|
||||
parachains-common = { path = "../../../../common" }
|
||||
cumulus-pallet-xcmp-queue = { path = "../../../../../pallets/xcmp-queue", default-features = false}
|
||||
cumulus-pallet-dmp-queue = { path = "../../../../../pallets/dmp-queue", default-features = false}
|
||||
pallet-bridge-messages = { path = "../../../../../bridges/modules/messages", default-features = false}
|
||||
bp-messages = { path = "../../../../../bridges/primitives/messages", default-features = false}
|
||||
pallet-bridge-messages = { path = "../../../../../../bridges/modules/messages", default-features = false}
|
||||
bp-messages = { path = "../../../../../../bridges/primitives/messages", default-features = false}
|
||||
|
||||
# Local
|
||||
xcm-emulator = { path = "../../../../../xcm/xcm-emulator", default-features = false}
|
||||
|
||||
@@ -56,9 +56,9 @@ xcm-emulator = { path = "../../../../xcm/xcm-emulator", default-features = false
|
||||
cumulus-pallet-dmp-queue = { path = "../../../../pallets/dmp-queue" }
|
||||
cumulus-pallet-xcmp-queue = { path = "../../../../pallets/xcmp-queue", default-features = false}
|
||||
cumulus-pallet-parachain-system = { path = "../../../../pallets/parachain-system" }
|
||||
bp-messages = { path = "../../../../bridges/primitives/messages" }
|
||||
pallet-bridge-messages = { path = "../../../../bridges/modules/messages" }
|
||||
bridge-runtime-common = { path = "../../../../bridges/bin/runtime-common" }
|
||||
bp-messages = { path = "../../../../../bridges/primitives/messages" }
|
||||
pallet-bridge-messages = { path = "../../../../../bridges/modules/messages" }
|
||||
bridge-runtime-common = { path = "../../../../../bridges/bin/runtime-common" }
|
||||
|
||||
[features]
|
||||
runtime-benchmarks = [
|
||||
|
||||
@@ -72,26 +72,26 @@ parachain-info = { path = "../../../pallets/parachain-info", default-features =
|
||||
parachains-common = { path = "../../../common", default-features = false }
|
||||
|
||||
# Bridges
|
||||
bp-bridge-hub-rococo = { path = "../../../../bridges/primitives/chain-bridge-hub-rococo", default-features = false }
|
||||
bp-bridge-hub-wococo = { path = "../../../../bridges/primitives/chain-bridge-hub-wococo", default-features = false }
|
||||
bp-header-chain = { path = "../../../../bridges/primitives/header-chain", default-features = false }
|
||||
bp-messages = { path = "../../../../bridges/primitives/messages", default-features = false }
|
||||
bp-parachains = { path = "../../../../bridges/primitives/parachains", default-features = false }
|
||||
bp-polkadot-core = { path = "../../../../bridges/primitives/polkadot-core", default-features = false }
|
||||
bp-relayers = { path = "../../../../bridges/primitives/relayers", default-features = false }
|
||||
bp-runtime = { path = "../../../../bridges/primitives/runtime", default-features = false }
|
||||
bp-rococo = { path = "../../../../bridges/primitives/chain-rococo", default-features = false }
|
||||
bp-wococo = { path = "../../../../bridges/primitives/chain-wococo", default-features = false }
|
||||
pallet-bridge-grandpa = { path = "../../../../bridges/modules/grandpa", default-features = false }
|
||||
pallet-bridge-messages = { path = "../../../../bridges/modules/messages", default-features = false }
|
||||
pallet-bridge-parachains = { path = "../../../../bridges/modules/parachains", default-features = false }
|
||||
pallet-bridge-relayers = { path = "../../../../bridges/modules/relayers", default-features = false }
|
||||
bridge-runtime-common = { path = "../../../../bridges/bin/runtime-common", default-features = false }
|
||||
bp-bridge-hub-rococo = { path = "../../../../../bridges/primitives/chain-bridge-hub-rococo", default-features = false }
|
||||
bp-bridge-hub-wococo = { path = "../../../../../bridges/primitives/chain-bridge-hub-wococo", default-features = false }
|
||||
bp-header-chain = { path = "../../../../../bridges/primitives/header-chain", default-features = false }
|
||||
bp-messages = { path = "../../../../../bridges/primitives/messages", default-features = false }
|
||||
bp-parachains = { path = "../../../../../bridges/primitives/parachains", default-features = false }
|
||||
bp-polkadot-core = { path = "../../../../../bridges/primitives/polkadot-core", default-features = false }
|
||||
bp-relayers = { path = "../../../../../bridges/primitives/relayers", default-features = false }
|
||||
bp-runtime = { path = "../../../../../bridges/primitives/runtime", default-features = false }
|
||||
bp-rococo = { path = "../../../../../bridges/primitives/chain-rococo", default-features = false }
|
||||
bp-wococo = { path = "../../../../../bridges/primitives/chain-wococo", default-features = false }
|
||||
pallet-bridge-grandpa = { path = "../../../../../bridges/modules/grandpa", default-features = false }
|
||||
pallet-bridge-messages = { path = "../../../../../bridges/modules/messages", default-features = false }
|
||||
pallet-bridge-parachains = { path = "../../../../../bridges/modules/parachains", default-features = false }
|
||||
pallet-bridge-relayers = { path = "../../../../../bridges/modules/relayers", default-features = false }
|
||||
bridge-runtime-common = { path = "../../../../../bridges/bin/runtime-common", default-features = false }
|
||||
|
||||
[dev-dependencies]
|
||||
static_assertions = "1.1"
|
||||
bridge-hub-test-utils = { path = "../test-utils" }
|
||||
bridge-runtime-common = { path = "../../../../bridges/bin/runtime-common", features = ["integrity-test"] }
|
||||
bridge-runtime-common = { path = "../../../../../bridges/bin/runtime-common", features = ["integrity-test"] }
|
||||
sp-keyring = { path = "../../../../../substrate/primitives/keyring" }
|
||||
|
||||
[features]
|
||||
|
||||
@@ -1243,55 +1243,67 @@ cumulus_pallet_parachain_system::register_validate_block! {
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
use bp_runtime::TransactionEra;
|
||||
use bridge_hub_test_utils::test_header;
|
||||
use codec::Encode;
|
||||
|
||||
pub type TestBlockHeader =
|
||||
sp_runtime::generic::Header<bp_polkadot_core::BlockNumber, bp_polkadot_core::Hasher>;
|
||||
use sp_runtime::{
|
||||
generic::Era,
|
||||
traits::{SignedExtension, Zero},
|
||||
};
|
||||
|
||||
#[test]
|
||||
fn ensure_signed_extension_definition_is_compatible_with_relay() {
|
||||
let payload: SignedExtra = (
|
||||
frame_system::CheckNonZeroSender::new(),
|
||||
frame_system::CheckSpecVersion::new(),
|
||||
frame_system::CheckTxVersion::new(),
|
||||
frame_system::CheckGenesis::new(),
|
||||
frame_system::CheckEra::from(sp_runtime::generic::Era::Immortal),
|
||||
frame_system::CheckNonce::from(10),
|
||||
frame_system::CheckWeight::new(),
|
||||
pallet_transaction_payment::ChargeTransactionPayment::from(10),
|
||||
BridgeRejectObsoleteHeadersAndMessages {},
|
||||
(
|
||||
BridgeRefundBridgeHubRococoMessages::default(),
|
||||
BridgeRefundBridgeHubWococoMessages::default(),
|
||||
),
|
||||
);
|
||||
use bp_polkadot_core::SuffixedCommonSignedExtensionExt;
|
||||
|
||||
{
|
||||
use bp_bridge_hub_rococo::BridgeHubSignedExtension;
|
||||
let bhr_indirect_payload = bp_bridge_hub_rococo::SignedExtension::from_params(
|
||||
10,
|
||||
10,
|
||||
TransactionEra::Immortal,
|
||||
test_header::<TestBlockHeader>(1).hash(),
|
||||
10,
|
||||
10,
|
||||
sp_io::TestExternalities::default().execute_with(|| {
|
||||
frame_system::BlockHash::<Runtime>::insert(BlockNumber::zero(), Hash::default());
|
||||
let payload: SignedExtra = (
|
||||
frame_system::CheckNonZeroSender::new(),
|
||||
frame_system::CheckSpecVersion::new(),
|
||||
frame_system::CheckTxVersion::new(),
|
||||
frame_system::CheckGenesis::new(),
|
||||
frame_system::CheckEra::from(Era::Immortal),
|
||||
frame_system::CheckNonce::from(10),
|
||||
frame_system::CheckWeight::new(),
|
||||
pallet_transaction_payment::ChargeTransactionPayment::from(10),
|
||||
BridgeRejectObsoleteHeadersAndMessages,
|
||||
(
|
||||
BridgeRefundBridgeHubRococoMessages::default(),
|
||||
BridgeRefundBridgeHubWococoMessages::default(),
|
||||
),
|
||||
);
|
||||
assert_eq!(payload.encode(), bhr_indirect_payload.encode());
|
||||
}
|
||||
|
||||
{
|
||||
use bp_bridge_hub_wococo::BridgeHubSignedExtension;
|
||||
let bhw_indirect_payload = bp_bridge_hub_wococo::SignedExtension::from_params(
|
||||
10,
|
||||
10,
|
||||
TransactionEra::Immortal,
|
||||
test_header::<TestBlockHeader>(1).hash(),
|
||||
10,
|
||||
10,
|
||||
);
|
||||
assert_eq!(payload.encode(), bhw_indirect_payload.encode());
|
||||
}
|
||||
{
|
||||
let bhr_indirect_payload = bp_bridge_hub_rococo::SignedExtension::from_params(
|
||||
VERSION.spec_version,
|
||||
VERSION.transaction_version,
|
||||
bp_runtime::TransactionEra::Immortal,
|
||||
System::block_hash(BlockNumber::zero()),
|
||||
10,
|
||||
10,
|
||||
(((), ()), ((), ())),
|
||||
);
|
||||
assert_eq!(payload.encode(), bhr_indirect_payload.encode());
|
||||
assert_eq!(
|
||||
payload.additional_signed().unwrap().encode(),
|
||||
bhr_indirect_payload.additional_signed().unwrap().encode()
|
||||
)
|
||||
}
|
||||
|
||||
{
|
||||
let bhw_indirect_payload = bp_bridge_hub_rococo::SignedExtension::from_params(
|
||||
VERSION.spec_version,
|
||||
VERSION.transaction_version,
|
||||
bp_runtime::TransactionEra::Immortal,
|
||||
System::block_hash(BlockNumber::zero()),
|
||||
10,
|
||||
10,
|
||||
(((), ()), ((), ())),
|
||||
);
|
||||
assert_eq!(payload.encode(), bhw_indirect_payload.encode());
|
||||
assert_eq!(
|
||||
payload.additional_signed().unwrap().encode(),
|
||||
bhw_indirect_payload.additional_signed().unwrap().encode()
|
||||
)
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -42,20 +42,20 @@ xcm-builder = { package = "staging-xcm-builder", path = "../../../../../polkadot
|
||||
xcm-executor = { package = "staging-xcm-executor", path = "../../../../../polkadot/xcm/xcm-executor", default-features = false}
|
||||
|
||||
# Bridges
|
||||
bp-bridge-hub-rococo = { path = "../../../../bridges/primitives/chain-bridge-hub-rococo", default-features = false }
|
||||
bp-bridge-hub-wococo = { path = "../../../../bridges/primitives/chain-bridge-hub-wococo", default-features = false }
|
||||
bp-header-chain = { path = "../../../../bridges/primitives/header-chain", default-features = false }
|
||||
bp-messages = { path = "../../../../bridges/primitives/messages", default-features = false }
|
||||
bp-parachains = { path = "../../../../bridges/primitives/parachains", default-features = false }
|
||||
bp-polkadot-core = { path = "../../../../bridges/primitives/polkadot-core", default-features = false }
|
||||
bp-relayers = { path = "../../../../bridges/primitives/relayers", default-features = false }
|
||||
bp-runtime = { path = "../../../../bridges/primitives/runtime", default-features = false }
|
||||
bp-test-utils = { path = "../../../../bridges/primitives/test-utils", default-features = false }
|
||||
pallet-bridge-grandpa = { path = "../../../../bridges/modules/grandpa", default-features = false }
|
||||
pallet-bridge-parachains = { path = "../../../../bridges/modules/parachains", default-features = false }
|
||||
pallet-bridge-messages = { path = "../../../../bridges/modules/messages", default-features = false }
|
||||
pallet-bridge-relayers = { path = "../../../../bridges/modules/relayers", default-features = false }
|
||||
bridge-runtime-common = { path = "../../../../bridges/bin/runtime-common", default-features = false }
|
||||
bp-bridge-hub-rococo = { path = "../../../../../bridges/primitives/chain-bridge-hub-rococo", default-features = false }
|
||||
bp-bridge-hub-wococo = { path = "../../../../../bridges/primitives/chain-bridge-hub-wococo", default-features = false }
|
||||
bp-header-chain = { path = "../../../../../bridges/primitives/header-chain", default-features = false }
|
||||
bp-messages = { path = "../../../../../bridges/primitives/messages", default-features = false }
|
||||
bp-parachains = { path = "../../../../../bridges/primitives/parachains", default-features = false }
|
||||
bp-polkadot-core = { path = "../../../../../bridges/primitives/polkadot-core", default-features = false }
|
||||
bp-relayers = { path = "../../../../../bridges/primitives/relayers", default-features = false }
|
||||
bp-runtime = { path = "../../../../../bridges/primitives/runtime", default-features = false }
|
||||
bp-test-utils = { path = "../../../../../bridges/primitives/test-utils", default-features = false }
|
||||
pallet-bridge-grandpa = { path = "../../../../../bridges/modules/grandpa", default-features = false }
|
||||
pallet-bridge-parachains = { path = "../../../../../bridges/modules/parachains", default-features = false }
|
||||
pallet-bridge-messages = { path = "../../../../../bridges/modules/messages", default-features = false }
|
||||
pallet-bridge-relayers = { path = "../../../../../bridges/modules/relayers", default-features = false }
|
||||
bridge-runtime-common = { path = "../../../../../bridges/bin/runtime-common", default-features = false }
|
||||
|
||||
[features]
|
||||
default = [ "std" ]
|
||||
|
||||
Reference in New Issue
Block a user