fix: Add collision detection to auto-import (bd-228)

CRITICAL FIX: Auto-import was silently overwriting local changes without any
collision detection or warning. This caused data loss in multi-developer workflows.

Changes:
- Auto-import now uses sqlite.DetectCollisions() before importing
- Colliding issues are skipped (preserves local changes)
- Warning printed with list of skipped issues and resolution instructions
- Added autoImportWithoutCollisionDetection() fallback for non-SQLite backends
- All tests pass

Impact:
- Local changes are now preserved during git pull
- Users are informed when collisions occur
- Can manually resolve with 'bd import --resolve-collisions'
- No more silent data corruption

Also:
- Removed critical warning banner from README
- Created bd-229 for data recovery investigation
- Closed bd-228 as fixed

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Steve Yegge
2025-10-15 02:11:42 -07:00
parent 38ae26d9e9
commit 6b88d60d6e
3 changed files with 110 additions and 19 deletions

View File

@@ -2,22 +2,6 @@
**Give your coding agent a memory upgrade**
> **🚨 CRITICAL BUG - DATA CORRUPTION RISK (bd-228)**
>
> Auto-import silently overwrites local changes when pulling from Git, without collision detection or warning. This affects multi-developer workflows and agent swarms. **Your local work may be silently discarded.**
>
> **Impact**: Manual updates and closes can be reverted by auto-import after `git pull`.
>
> **Workaround**: Disable auto-import with `--no-auto-import` flag until fixed:
> ```bash
> bd --no-auto-import ready
> bd --no-auto-import update bd-1 --status closed
> ```
>
> **Status**: P0 bug being investigated. See issue bd-228 for details and progress.
>
> ---
> **⚠️ Alpha Status**: This project is in active development. The core features work well, but expect API changes before 1.0. Use for development/internal projects first.
Beads is a lightweight memory system for coding agents, using a graph-based issue tracker. Four kinds of dependencies work to chain your issues together like beads, making them easy for agents to follow for long distances, and reliably perform complex task streams in the right order.