mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-01 04:31:02 +00:00
more useful error message (#9014)
This commit is contained in:
@@ -646,9 +646,10 @@ 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(
|
return Err(ConsensusError::ClientImport(format!(
|
||||||
"GRANDPA can only import GRANDPA Justifications.".into(),
|
"Expected GRANDPA Justification, got {}.",
|
||||||
));
|
String::from_utf8_lossy(&justification.0)
|
||||||
|
)));
|
||||||
}
|
}
|
||||||
|
|
||||||
let justification = GrandpaJustification::decode_and_verify_finalizes(
|
let justification = GrandpaJustification::decode_and_verify_finalizes(
|
||||||
|
|||||||
Reference in New Issue
Block a user