-
Notifications
You must be signed in to change notification settings - Fork 5
Cmoyes/snapshot #89
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
Draft
ibhatt-jumptrading
wants to merge
2
commits into
main
Choose a base branch
from
cmoyes/snapshot
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Cmoyes/snapshot #89
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,109 @@ | ||
| syntax = "proto3"; | ||
| package org.solana.sealevel.v1; | ||
| import "context.proto"; | ||
| import "block.proto"; | ||
| import "metadata.proto"; | ||
|
|
||
| // Snapshot deserialization input with explicit version selection | ||
| message SnapshotContext { | ||
| // Snapshot format version (e.g. maps to DeserializableVersionedBank variants) | ||
| uint64 version = 1; | ||
|
|
||
| // Raw serialized snapshot bank data (bincode) | ||
| bytes data = 2; | ||
| } | ||
|
|
||
| message HardFork { | ||
| uint64 slot = 1; | ||
| uint64 count = 2; | ||
| } | ||
|
|
||
| message RentCollector { | ||
| uint64 epoch = 1; | ||
| EpochSchedule epoch_schedule = 2; | ||
| double slots_per_year = 3; | ||
| Rent rent = 4; | ||
| } | ||
|
|
||
| // Deserialized snapshot bank fields for comparison. | ||
| // Mirrors DeserializableVersionedBank (Agave) / fd_snapshot_manifest (Firedancer). | ||
| message SnapshotEffects { | ||
| int32 result = 1; | ||
|
|
||
| // Blockhash queue (ordered from oldest to newest, up to 301 entries) | ||
| repeated BlockhashQueueEntry blockhash_queue = 2; | ||
|
|
||
| // Ancestor slots (being removed in Agave v4.0 reads, zeroed in v4.1) | ||
| repeated uint64 ancestors = 3; | ||
|
|
||
| // Bank hash (32 bytes) | ||
| bytes hash = 4; | ||
|
|
||
| // Parent bank hash (32 bytes) | ||
| bytes parent_hash = 5; | ||
|
|
||
| uint64 parent_slot = 6; | ||
|
|
||
| repeated HardFork hard_forks = 7; | ||
|
|
||
| uint64 transaction_count = 8; | ||
|
|
||
| uint64 tick_height = 9; | ||
|
|
||
| uint64 signature_count = 10; | ||
|
|
||
| uint64 capitalization = 11; | ||
|
|
||
| uint64 max_tick_height = 12; | ||
|
|
||
| // None encoded as 0 with has_hashes_per_tick = false | ||
| bool has_hashes_per_tick = 13; | ||
| uint64 hashes_per_tick = 14; | ||
|
|
||
| uint64 ticks_per_slot = 15; | ||
|
|
||
| // uint128 encoded as 16 bytes little-endian | ||
| bytes ns_per_slot = 16; | ||
|
|
||
| int64 genesis_creation_time = 17; | ||
|
|
||
| double slots_per_year = 18; | ||
|
|
||
| uint64 accounts_data_len = 19; | ||
|
|
||
| uint64 slot = 20; | ||
|
|
||
| // Being removed in Agave v4.0 reads, zeroed in v4.1 | ||
| uint64 epoch = 21; | ||
|
|
||
| uint64 block_height = 22; | ||
|
|
||
| // Collector pubkey (32 bytes) | ||
| bytes collector_id = 23; | ||
|
|
||
| // Being removed in Agave v4.0 reads, zeroed in v4.1 | ||
| uint64 collector_fees = 24; | ||
|
|
||
| FeeRateGovernor fee_rate_governor = 25; | ||
|
|
||
| // Being removed in Agave v4.0 reads, zeroed in v4.1 | ||
| RentCollector rent_collector = 26; | ||
|
|
||
| EpochSchedule epoch_schedule = 27; | ||
|
|
||
| Inflation inflation = 28; | ||
|
|
||
| repeated StakeDelegation stake_delegations = 29; | ||
|
|
||
| repeated PrevVoteAccount vote_accounts = 30; | ||
|
|
||
| bool is_delta = 31; | ||
|
|
||
| uint64 lamports_per_signature = 32; | ||
| } | ||
|
|
||
| message SnapshotFixture { | ||
| FixtureMetadata metadata = 1; | ||
| SnapshotContext input = 2; | ||
| SnapshotEffects output = 3; | ||
| } | ||
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe use stakescache/epoch_stakes agave-ish types here