[testnet] Remove Wococo stuff from BridgeHubRococo/AssetHubRococo (#2300)

Rococo<>Wococo bridge is replaced by Rococo<Westend bridge, so this PR
removes unneeded code.

- [x] update bridges subtree after
https://github.com/paritytech/parity-bridges-common/pull/2692

---------

Co-authored-by: command-bot <>
Co-authored-by: Svyatoslav Nikolsky <svyatonik@gmail.com>
This commit is contained in:
Branislav Kontur
2023-11-15 16:40:07 +01:00
committed by GitHub
parent 824b782390
commit f4bb17cc86
92 changed files with 967 additions and 6394 deletions
@@ -32,7 +32,6 @@ pub type AssetHubWestendChainSpec =
sc_service::GenericChainSpec<asset_hub_westend_runtime::RuntimeGenesisConfig, Extensions>;
pub type AssetHubRococoChainSpec =
sc_service::GenericChainSpec<asset_hub_rococo_runtime::RuntimeGenesisConfig, Extensions>;
pub type AssetHubWococoChainSpec = AssetHubRococoChainSpec;
const ASSET_HUB_POLKADOT_ED: AssetHubBalance =
parachains_common::polkadot::currency::EXISTENTIAL_DEPOSIT;
@@ -433,6 +432,7 @@ pub fn asset_hub_westend_development_config() -> AssetHubWestendChainSpec {
get_account_id_from_seed::<sr25519::Public>("Alice//stash"),
get_account_id_from_seed::<sr25519::Public>("Bob//stash"),
],
parachains_common::westend::currency::UNITS * 1_000_000,
1000.into(),
))
.with_properties(properties)
@@ -478,6 +478,7 @@ pub fn asset_hub_westend_local_config() -> AssetHubWestendChainSpec {
get_account_id_from_seed::<sr25519::Public>("Eve//stash"),
get_account_id_from_seed::<sr25519::Public>("Ferdie//stash"),
],
parachains_common::westend::currency::UNITS * 1_000_000,
1000.into(),
))
.with_properties(properties)
@@ -522,6 +523,7 @@ pub fn asset_hub_westend_config() -> AssetHubWestendChainSpec {
),
],
Vec::new(),
ASSET_HUB_WESTEND_ED * 4096,
1000.into(),
))
.with_properties(properties)
@@ -531,6 +533,7 @@ pub fn asset_hub_westend_config() -> AssetHubWestendChainSpec {
fn asset_hub_westend_genesis(
invulnerables: Vec<(AccountId, AuraId)>,
endowed_accounts: Vec<AccountId>,
endowment: AssetHubBalance,
id: ParaId,
) -> serde_json::Value {
serde_json::json!({
@@ -538,7 +541,7 @@ fn asset_hub_westend_genesis(
"balances": endowed_accounts
.iter()
.cloned()
.map(|k| (k, ASSET_HUB_WESTEND_ED * 4096))
.map(|k| (k, endowment))
.collect::<Vec<_>>(),
},
"parachainInfo": {
@@ -579,19 +582,6 @@ pub fn asset_hub_rococo_development_config() -> AssetHubRococoChainSpec {
)
}
pub fn asset_hub_wococo_development_config() -> AssetHubWococoChainSpec {
let mut properties = sc_chain_spec::Properties::new();
properties.insert("ss58Format".into(), 42.into());
properties.insert("tokenSymbol".into(), "WOC".into());
properties.insert("tokenDecimals".into(), 12.into());
asset_hub_rococo_like_development_config(
properties,
"Wococo Asset Hub Development",
"asset-hub-wococo-dev",
1000,
)
}
fn asset_hub_rococo_like_development_config(
properties: sc_chain_spec::Properties,
name: &str,
@@ -617,6 +607,7 @@ fn asset_hub_rococo_like_development_config(
get_account_id_from_seed::<sr25519::Public>("Alice//stash"),
get_account_id_from_seed::<sr25519::Public>("Bob//stash"),
],
parachains_common::rococo::currency::UNITS * 1_000_000,
para_id.into(),
))
.with_properties(properties)
@@ -636,19 +627,6 @@ pub fn asset_hub_rococo_local_config() -> AssetHubRococoChainSpec {
)
}
pub fn asset_hub_wococo_local_config() -> AssetHubWococoChainSpec {
let mut properties = sc_chain_spec::Properties::new();
properties.insert("ss58Format".into(), 42.into());
properties.insert("tokenSymbol".into(), "WOC".into());
properties.insert("tokenDecimals".into(), 12.into());
asset_hub_rococo_like_local_config(
properties,
"Wococo Asset Hub Local",
"asset-hub-wococo-local",
1000,
)
}
fn asset_hub_rococo_like_local_config(
properties: sc_chain_spec::Properties,
name: &str,
@@ -688,6 +666,7 @@ fn asset_hub_rococo_like_local_config(
get_account_id_from_seed::<sr25519::Public>("Eve//stash"),
get_account_id_from_seed::<sr25519::Public>("Ferdie//stash"),
],
parachains_common::rococo::currency::UNITS * 1_000_000,
para_id.into(),
))
.with_properties(properties)
@@ -735,54 +714,7 @@ pub fn asset_hub_rococo_genesis_config() -> AssetHubRococoChainSpec {
),
],
Vec::new(),
para_id.into(),
))
.with_properties(properties)
.build()
}
pub fn asset_hub_wococo_genesis_config() -> AssetHubWococoChainSpec {
let mut properties = sc_chain_spec::Properties::new();
properties.insert("ss58Format".into(), 42.into());
properties.insert("tokenSymbol".into(), "WOC".into());
properties.insert("tokenDecimals".into(), 12.into());
let para_id = 1000;
AssetHubRococoChainSpec::builder(
asset_hub_rococo_runtime::WASM_BINARY.expect("WASM binary was not built, please build it!"),
Extensions { relay_chain: "wococo".into(), para_id },
)
.with_name("Wococo Asset Hub")
.with_id("asset-hub-wococo")
.with_chain_type(ChainType::Live)
.with_genesis_config_patch(asset_hub_rococo_genesis(
// initial collators.
vec![
// 5C8RGkS8t5K93fB2hkgKbvSYs5iG6AknJMuQmbBDeazon9Lj
(
hex!("02d526f43cf27e94f478f9db785dc86052a77c695e7c855211839d3fde3ce534").into(),
hex!("02d526f43cf27e94f478f9db785dc86052a77c695e7c855211839d3fde3ce534")
.unchecked_into(),
),
// 5GePeDZQeBagXH7kH5QPKnQKi39Z5hoYFB5FmUtEvc4yxKej
(
hex!("caa1f623ca183296c4521b56cc29c484ca017830f8cb538f30f2d4664d631814").into(),
hex!("caa1f623ca183296c4521b56cc29c484ca017830f8cb538f30f2d4664d631814")
.unchecked_into(),
),
// 5CfnTTb9NMJDNKDntA83mHKoedZ7wjDC8ypLCTDd4NwUx3zv
(
hex!("1ac112d635db2bd34e79ae2b99486cf7c0b71a928668e4feb3dc4633d368f965").into(),
hex!("1ac112d635db2bd34e79ae2b99486cf7c0b71a928668e4feb3dc4633d368f965")
.unchecked_into(),
),
// 5EqheiwiG22gvGpN7cvrbeaQzhg7rzsYYVkYK4yj5vRrTQRQ
(
hex!("7ac9d11be07334cd27e9eb849f5fc7677a10ad36b6ab38b377d3c8b2c0b08b66").into(),
hex!("7ac9d11be07334cd27e9eb849f5fc7677a10ad36b6ab38b377d3c8b2c0b08b66")
.unchecked_into(),
),
],
Vec::new(),
ASSET_HUB_ROCOCO_ED * 524_288,
para_id.into(),
))
.with_properties(properties)
@@ -792,6 +724,7 @@ pub fn asset_hub_wococo_genesis_config() -> AssetHubWococoChainSpec {
fn asset_hub_rococo_genesis(
invulnerables: Vec<(AccountId, AuraId)>,
endowed_accounts: Vec<AccountId>,
endowment: AssetHubBalance,
id: ParaId,
) -> serde_json::Value {
serde_json::json!({
@@ -799,7 +732,7 @@ fn asset_hub_rococo_genesis(
balances: endowed_accounts
.iter()
.cloned()
.map(|k| (k, ASSET_HUB_ROCOCO_ED * 524_288))
.map(|k| (k, endowment))
.collect(),
},
"parachainInfo": asset_hub_rococo_runtime::ParachainInfoConfig {