Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a protobuf contract for differential fuzzing of Alpenglow Votor consensus-pool behavior.
Changes:
- Models validators, blocks, votes, certificates, and pool events.
- Defines replay normalization, action results, and run statuses.
- Adds fixture metadata integration.
Suppressed comments (2)
proto/votor.proto:103
- A protobuf
oneofmay be unset, so an emptyVotorVoteis valid on the wire and has no RustVotepreimage, contrary to this contract. Because inputs are fuzzer-controlled, define whether such a vote is skipped, maps toINVALID_INPUT, or has another deterministic result so both implementations handle it identically.
A oneof is used rather than a flat kind field because the two vote
shapes carry different fields: this makes it structurally impossible
to attach a block hash to a skip or final vote, so every value of
this message has exactly one `Vote` preimage. The cost is that a
proto/votor.proto:200
- This conflicts with the earlier exhaustive
MUSTnormalization list, which omits reducingslot_offset: one replay harness may follow thisSHOULDand reduce the value while another uses the stated saturating-add semantics. Make modulo reduction mandatory in the normalization list, or direct this recommendation only to corpus/fixture generators.
[0, 2 * SLOTS_PER_EPOCH) = [0, 36000) and any offset at or beyond
36000 makes every vote out of bounds. Harnesses SHOULD reduce this
field modulo 36000 so the corpus is not wasted on degenerate
all-rejected fixtures. Rebasing within the window lets a corpus
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| @@ -0,0 +1,483 @@ | |||
| syntax = "proto3"; | |||
|
|
||
| * `validators` empty -> substitute a single validator with stake 1 | ||
| * `validators` truncated to 2048 (`MAX_SIGNERS`) | ||
| * each stake clamped so the running total saturates below uint64 max |
| vacuously met in release) | ||
| * `own_id` reduced modulo the validator count (`ValidatorEpochInfo::new` | ||
| panics otherwise) | ||
| * `key_seed` and every `block_hash` zero-padded or truncated to 32 bytes |
Comment on lines
+48
to
+50
| * an `add_block` action whose `parent.slot >= block.slot` is SKIPPED | ||
| entirely -- no call, and no entry in `VotorEffects.results` | ||
| (`Pool::add_block` asserts `block.slot > parent.slot`) |
Comment on lines
+153
to
+154
| message VotorAction { | ||
| oneof action { |
lidatong
force-pushed
the
votor
branch
2 times, most recently
from
August 5, 2026 23:28
5b1cfd0 to
a915598
Compare
mjain-jump
approved these changes
Aug 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.