Add table of always enabled feature gates
Author: ripatel-fdCreated Jan 12, 2024Updated Jan 13, 2025
Labelsstale
Problem
After each feature gate gets activated, in the next minor release, the code gets simplified to only keep logic in the feature gate activated state.
Every time this happens, that new release of the ledger tool might lose the ability to validate some old epochs. However, the code does not keep track of which feature gates are hard-enabled.
Creating these issues:
- Replaying old ledgers fails with the cryptic error "Bank hash mismatch", and is not gracefully handled
- It is difficult to do Labs<>Firedancer compatibility testing (such as checking for differences executing instruction processing test vectors), because we don't know whether Labs and Firedancer implement the required intersection of feature sets for those tests
Proposed Solution
- In
feature_set.rs, add a table of always-enabled feature gates - Adjust the feature gate activation process to keep this table maintained
- When replaying old ledgers, gracefully error if the old ledger lacks an activated feature account for any of the hardcoded feature IDs
Source: solana-labs/solana