fix: filter wisps from sync_export.go (bd-687g)
The sync command's exportToJSONL function was not filtering wisps, causing them to be re-added to JSONL during bd sync re-export step. autoflush.go had wisp filtering but sync_export.go did not. Added the same filtering logic to prevent wisps from being exported to JSONL. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -60,6 +60,18 @@ func exportToJSONL(ctx context.Context, jsonlPath string) error {
|
||||
}
|
||||
}
|
||||
|
||||
// Filter out wisps - they should never be exported to JSONL (bd-687g)
|
||||
// Wisps exist only in SQLite and are shared via .beads/redirect, not JSONL.
|
||||
// This prevents "zombie" issues that resurrect after mol squash deletes them.
|
||||
filteredIssues := make([]*types.Issue, 0, len(issues))
|
||||
for _, issue := range issues {
|
||||
if issue.Wisp {
|
||||
continue
|
||||
}
|
||||
filteredIssues = append(filteredIssues, issue)
|
||||
}
|
||||
issues = filteredIssues
|
||||
|
||||
// Sort by ID for consistent output
|
||||
slices.SortFunc(issues, func(a, b *types.Issue) int {
|
||||
return cmp.Compare(a.ID, b.ID)
|
||||
|
||||
Reference in New Issue
Block a user