Skip to content

Conversation

@jasagredo
Copy link
Contributor

Closes #1708

-->
### Breaking

- Legacy snapshots will be rejected and deleted, instead of crashing consensus.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the code, I see that we check if the snapshot is a file and, if so, infer that it is in the legacy format and throw and exception. Is the deletion already done when we handle this exception? Where can I find this code, if it exists?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah I see, it's not in Consensus, the exception need to be handled in the node. In that case, I think this changelog entry needs to be reformulated:

Suggested change
- Legacy snapshots will be rejected and deleted, instead of crashing consensus.
- Legacy snapshots will be rejected instead of crashing Consensus, and an error will be signaled upstream, so that `cardano-node` could choose what to do with the incompatible snapshot.

Copy link
Contributor Author

@jasagredo jasagredo Nov 26, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right. I think I like the approach of emitting a warning and suggesting the convert the snapshot, as you've described in #1708, but if you think that deleting is fine, then let's delete.

Copy link
Contributor

@geo2a geo2a left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved with a suggesting to reformulate the changelog entry.

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

Successfully merging this pull request may close these issues.

Proper handling of malformed snapshots

3 participants