Fix bd-346: Auto-flush after renumber/rename-prefix now does full export
Problem: Incremental flush merged dirty issues with existing JSONL, leaving old IDs when issues were renamed (e.g., test-3 remained after renumbering to test-2). Solution: - Add needsFullExport flag to force complete JSONL rebuild from DB - Skip loading existing JSONL when fullExport=true (start with empty map) - Use markDirtyAndScheduleFullExport() in renumber and rename-prefix commands - PersistentPostRun flushes immediately before process exits (respects fullExport) Test: Verified renumber with gaps correctly exports only current IDs to JSONL
This commit is contained in:
@@ -128,8 +128,8 @@ Risks:
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Schedule auto-flush to export changes
|
||||
markDirtyAndScheduleFlush()
|
||||
// Schedule full export (IDs changed, incremental won't work)
|
||||
markDirtyAndScheduleFullExport()
|
||||
|
||||
fmt.Printf("%s Successfully renumbered %d issues\n", green("✓"), len(issues))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user