Problem
cora debt reads from .cora/history/*.json file snapshots while cora findings reads from cora.db. This creates a data inconsistency:
| Source |
Reviews |
Findings |
cora debt (file snapshots) |
15 |
16 |
cora findings (cora.db) |
12 |
1 |
The DB is supposed to be the Single Source of Truth (SoT) since v0.8.4.
Expected
cora debt should read from cora.db (reviews + findings tables) instead of file-based snapshots. File snapshots should be deprecated or synced.
Impact
cora debt shows stale/phantom data from old reviews that pre-date DB persistence
- Users see conflicting numbers between
cora debt and cora findings stats
- File-based snapshots are not portable, not queryable, and prone to corruption
Proposed Fix
- Migrate
debt_tracker to read from cora.db reviews/findings tables
- Optionally keep file snapshots as a backup/fallback
- Consider a migration tool to backfill DB from existing snapshot files
Related
Problem
cora debtreads from.cora/history/*.jsonfile snapshots whilecora findingsreads fromcora.db. This creates a data inconsistency:cora debt(file snapshots)cora findings(cora.db)The DB is supposed to be the Single Source of Truth (SoT) since v0.8.4.
Expected
cora debtshould read fromcora.db(reviews + findings tables) instead of file-based snapshots. File snapshots should be deprecated or synced.Impact
cora debtshows stale/phantom data from old reviews that pre-date DB persistencecora debtandcora findings statsProposed Fix
debt_trackerto read fromcora.dbreviews/findings tablesRelated
cora findingsCLI added