mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 20:21:06 +00:00
grandpa: ignore justifications from other consensus engines (#9075)
This commit is contained in:
@@ -646,10 +646,12 @@ where
|
|||||||
initial_sync: bool,
|
initial_sync: bool,
|
||||||
) -> Result<(), ConsensusError> {
|
) -> Result<(), ConsensusError> {
|
||||||
if justification.0 != GRANDPA_ENGINE_ID {
|
if justification.0 != GRANDPA_ENGINE_ID {
|
||||||
return Err(ConsensusError::ClientImport(format!(
|
// TODO: the import queue needs to be refactored to be able dispatch to the correct
|
||||||
"Expected GRANDPA Justification, got {}.",
|
// `JustificationImport` instance based on `ConsensusEngineId`, or we need to build a
|
||||||
String::from_utf8_lossy(&justification.0)
|
// justification import pipeline similar to what we do for `BlockImport`. In the
|
||||||
)));
|
// meantime we'll just drop the justification, since this is only used for BEEFY which
|
||||||
|
// is still WIP.
|
||||||
|
return Ok(());
|
||||||
}
|
}
|
||||||
|
|
||||||
let justification = GrandpaJustification::decode_and_verify_finalizes(
|
let justification = GrandpaJustification::decode_and_verify_finalizes(
|
||||||
|
|||||||
Reference in New Issue
Block a user