mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 16:21:02 +00:00
Fix and cleanups (#314)
* Cleanups (remove genesis.wasm & nicer errors) - Pretty errors for version mismatch - Remove the need for genesis wasm * Remove unneeded wasm files * Improve code of conduct * Leaner code * Test fixes * fix tests * Fix consensus checking
This commit is contained in:
committed by
Arkadiy Paronyan
parent
161dce3699
commit
257c6d240f
@@ -200,7 +200,7 @@ mod tests {
|
|||||||
timestamp: Some(Default::default()),
|
timestamp: Some(Default::default()),
|
||||||
};
|
};
|
||||||
|
|
||||||
::client::new_in_mem(LocalDispatch::new(), genesis_config).unwrap()
|
::client::new_in_mem(LocalDispatch::with_heap_pages(8), genesis_config).unwrap()
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|||||||
@@ -56,6 +56,7 @@ fn start_bft<F, C>(
|
|||||||
C: bft::BlockImport<Block> + bft::Authorities<Block> + 'static,
|
C: bft::BlockImport<Block> + bft::Authorities<Block> + 'static,
|
||||||
F::Error: ::std::fmt::Debug,
|
F::Error: ::std::fmt::Debug,
|
||||||
<F::Proposer as bft::Proposer<Block>>::Error: ::std::fmt::Display + Into<error::Error>,
|
<F::Proposer as bft::Proposer<Block>>::Error: ::std::fmt::Display + Into<error::Error>,
|
||||||
|
<F as bft::Environment<Block>>::Error: ::std::fmt::Display
|
||||||
{
|
{
|
||||||
let mut handle = LocalThreadHandle::current();
|
let mut handle = LocalThreadHandle::current();
|
||||||
match bft_service.build_upon(&header) {
|
match bft_service.build_upon(&header) {
|
||||||
@@ -63,7 +64,7 @@ fn start_bft<F, C>(
|
|||||||
debug!(target: "bft", "Couldn't initialize BFT agreement: {:?}", e);
|
debug!(target: "bft", "Couldn't initialize BFT agreement: {:?}", e);
|
||||||
},
|
},
|
||||||
Ok(None) => {},
|
Ok(None) => {},
|
||||||
Err(e) => debug!(target: "bft", "BFT agreement error: {:?}", e),
|
Err(e) => warn!(target: "bft", "BFT agreement error: {}", e),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
@@ -38,7 +38,7 @@ fn staging_testnet_config_genesis() -> GenesisConfig {
|
|||||||
];
|
];
|
||||||
GenesisConfig {
|
GenesisConfig {
|
||||||
consensus: Some(ConsensusConfig {
|
consensus: Some(ConsensusConfig {
|
||||||
code: include_bytes!("../../runtime/wasm/genesis.wasm").to_vec(), // TODO change
|
code: include_bytes!("../../runtime/wasm/target/wasm32-unknown-unknown/release/polkadot_runtime.compact.wasm").to_vec(), // TODO change
|
||||||
authorities: initial_authorities.clone(),
|
authorities: initial_authorities.clone(),
|
||||||
}),
|
}),
|
||||||
system: None,
|
system: None,
|
||||||
|
|||||||
Reference in New Issue
Block a user