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

chore(sequencer): add snapshots for storage values to enforce non-state-breaking changes #1985

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ethanoroshiba
Copy link
Contributor

@ethanoroshiba ethanoroshiba commented Feb 19, 2025

Summary

Added snapshot tests for all storage values to ensure that future changes do not break state.

Background

The addition of the BridgeTransfer action revealed how inserting a value into the storage ValueImpl is a breaking change, since deserialization would then fail. New values, such as BridgeTransferFees need to be appended instead of inserted. Adding snapshots for each storage variant's discriminant ensures that there is an extra level of protection against making a state breaking change.

Changes

  • Added snapshots for the discriminant of every ValueImpl variant and every StoredValue variant.

Testing

Manually reviewed every discriminant.

Changelogs

No updates required.

Related Issues

closes #1982

@ethanoroshiba ethanoroshiba added the sequencer pertaining to the astria-sequencer crate label Feb 19, 2025
Base automatically changed from joroshiba/fix-fee-storage-value to main February 20, 2025 01:38
@ethanoroshiba ethanoroshiba marked this pull request as ready for review February 20, 2025 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sequencer pertaining to the astria-sequencer crate
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants