mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-28 10:57:56 +00:00
Change on-the-wire protocol names to include genesis hash & fork id (#11938)
* Rename transactions protocol to include genesis hash
* Add protocol name generation to sc_network::utils
* Use utils functions for transactions protocol name generation
* Extract protocol name generation into public module
* Use sc_network::protocol_name::standard_protocol_name() for BEEFY and GRANDPA
* minor: add missing newline at EOF
* Change block-announces protocol name to include genesis_hash & fork_id
* Change protocol names to include genesis hash and fork id
Protocols changed:
- sync
- state
- light
- sync/warp
* Revert "Use sc_network::protocol_name::standard_protocol_name() for BEEFY and GRANDPA"
This reverts commit cd60a95a3face397e1b67f4bc95dd0f2b581bfae.
* Get rid of `protocol_name` module
This commit is contained in:
@@ -224,8 +224,16 @@ where
|
||||
fs::create_dir_all(path)?;
|
||||
}
|
||||
|
||||
let transactions_handler_proto =
|
||||
transactions::TransactionsHandlerPrototype::new(params.protocol_id.clone());
|
||||
let transactions_handler_proto = transactions::TransactionsHandlerPrototype::new(
|
||||
params.protocol_id.clone(),
|
||||
params
|
||||
.chain
|
||||
.block_hash(0u32.into())
|
||||
.ok()
|
||||
.flatten()
|
||||
.expect("Genesis block exists; qed"),
|
||||
params.fork_id.clone(),
|
||||
);
|
||||
params
|
||||
.network_config
|
||||
.extra_sets
|
||||
@@ -243,6 +251,7 @@ where
|
||||
From::from(¶ms.role),
|
||||
params.chain.clone(),
|
||||
params.protocol_id.clone(),
|
||||
¶ms.fork_id,
|
||||
¶ms.network_config,
|
||||
iter::once(Vec::new())
|
||||
.chain(
|
||||
|
||||
Reference in New Issue
Block a user