IntersectMBO / IntersectMBO/lsm-tree

Custom error datatype for snapshot version mismatches

Open Beginner friendly
#862 0 comments 0 reactions 0 assignees View on GitHub
enhancement good first issue lsm-tree priority: medium
Dominant language
Haskell
Stars
53
Forks
17
Avg merge
2d 3h
Merged PRs (30d)
4

Description

When opening a snapshot with an incompatible version number, we currently throw a `SnapshotCorruptedError`. It would be useful if a version mismatch was its own error datatype, so that it is easier for users to catch such exceptions and act on them.

https://github.com/IntersectMBO/lsm-tree/blob/934503f5f8f12014b8ac23a4212bfc280a1365e0/lsm-tree/src-core/Database/LSMTree/Internal/Snapshot/Codec.hs#L193-L208

Contributor guide

Open the contributing guide

Research direction

Start in lsm-tree/src-core/Database/LSMTree/Internal/Snapshot/Codec.hs at lines 193–208 and trace how incompatible snapshot versions are handled. Done means version mismatches use a distinct error datatype rather than SnapshotCorruptedError, with coverage for callers to distinguish the mismatch.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
databases
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.