Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decoding of BEEFY justifications: VersionedFinalityProof, not Option<SignedCommitment> #929

Open
Lederstrumpf opened this issue Aug 22, 2023 · 0 comments

Comments

@Lederstrumpf
Copy link
Contributor

BEEFY justifications are encoded as VersionedFinalityProofs.
Snowbridge's commitment scanner currently parses these BEEFY justifications as OptionalSignedCommitment here.
This inadvertently works because the first byte of an encoded VersionedFinalityProof signals the version (currently strictly 1), which overlaps with the 1 used to signal Some(..) in an encoded option.
However, it will break once we add new VersionedFinalityProof versions, such as required for paritytech/polkadot-sdk#1119.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant