feat(activity): handle cache corruption with integrity check and recovery #320
No reviewers
Labels
No labels
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
thwap/steeper!320
Loading…
Reference in a new issue
No description provided.
Delete branch "phase06-cache-integrity"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Add SQLite integrity checking and corruption recovery, completing #254 and Phase 6.
Changes
PRAGMA integrity_check, returnsErrCorruptedsentinel error on failure with detailsCheckIntegrity()after migration; closes DB and returnsErrCorruptedif check failsOpen(): ifErrCorrupted, deletes the corrupted DB file and retries with a fresh database. Passes through other errors.Phase 6 complete
References: #254, #251, #252, #253
Testing
go test -race ./...— all passReview
Result: Approved — no blocking issues.
Summary: Adds SQLite integrity checking and recovery.
ErrCorruptedsentinel error forerrors.Is()detection.CheckIntegrity()runsPRAGMA integrity_check— called duringOpen()after migration.OpenWithRecovery()wrapsOpen(): on corruption, deletes corrupted file and retries with fresh DB. ROADMAP2.md updated — Phase 6 fully complete.Non-blocking:
ErrCorrupted,CheckIntegrity,OpenWithRecoveryChecklist:
go test -racepassese8dae173cad4c802afd8New commits pushed, approval review dismissed automatically according to repository settings
Re-Review
Result: Approved — unchanged from previous review. Rebase-only update.
Previous review findings still apply — no blocking issues. #321 filed for missing godocs.