Fix auto-import git history backfill bug (bd-4pv)
Auto-import was allowing git history backfill to run, which could incorrectly purge issues. The fix adds NoGitHistory=true to all auto-import code paths: - autoimport.go (importFromGit) - autoflush.go (autoImportIfNewer) - daemon_sync.go (importToJSONLWithStore) Git history backfill is designed to detect deletions that happened after a local DB was created. During auto-import, there is no local work to protect - we are importing from the authoritative JSONL source. Also adds comprehensive tests for NoGitHistory behavior. Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -168,11 +168,11 @@ func autoImportIfNewer() {
|
||||
|
||||
// Use shared import logic (bd-157)
|
||||
opts := ImportOptions{
|
||||
|
||||
DryRun: false,
|
||||
SkipUpdate: false,
|
||||
Strict: false,
|
||||
SkipPrefixValidation: true, // Auto-import is lenient about prefixes
|
||||
NoGitHistory: true, // Skip git history backfill during auto-import (bd-4pv)
|
||||
}
|
||||
|
||||
result, err := importIssuesCore(ctx, dbPath, store, allIssues, opts)
|
||||
|
||||
Reference in New Issue
Block a user