Update issues: close bd-1
This commit is contained in:
@@ -1,151 +1,151 @@
|
||||
{"id":"bd-1","title":"Stress tests pollute production database with test issues","description":"TestStressNoUniqueConstraintViolations and other stress tests in internal/rpc/stress_test.go create issues in production database instead of test database. Confirmed: 1,000 test issues (Agent X Issue Y) created at 20:46:01 during test run. Root cause: test goroutines connect to production daemon at .beads/bd.sock instead of isolated test daemon in temp directory.","status":"closed","priority":0,"issue_type":"bug","assignee":"amp","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:35:00.620546-07:00","closed_at":"2025-10-22T00:35:00.620546-07:00"}
|
||||
{"id":"bd-10","title":"Daemon storage cache doesn't detect external database modifications","description":"When bd commands bypass the daemon and directly modify the database (e.g., `bd import` with direct file access, or deleting/recreating bd.db), the daemon's cached storage connection becomes stale and serves outdated data.\n\n**Reproduction**:\n1. Start daemon: `bd daemon`\n2. Run bd stats → shows N issues\n3. Delete database: `rm .beads/bd.db` \n4. Reinit and import: `bd init \u0026\u0026 bd import -i .beads/issues.jsonl`\n5. Run bd stats → shows 0 issues (wrong!)\n6. Direct query: `sqlite3 .beads/bd.db 'SELECT COUNT(*) FROM issues'` → shows correct count\n7. Restart daemon: `bd daemon --stop` then retry stats → now shows correct count\n\n**Root cause**: \n- server.go:1410-1414 retrieves cached storage without checking if DB file changed\n- Cache only evicts based on TTL (30min) or LRU, never on external modifications\n- Direct file operations bypass daemon, leaving cache stale\n\n**Impact**:\n- Users see incorrect/stale data after external DB operations\n- Confusing behavior with no clear indication cache is stale\n- Requires daemon restart to fix\n\n**Proposed fixes**:\n1. Check mtime on cache hit, invalidate if file changed\n2. Add cache eviction API (bd cache --clear)\n3. Use file locking to prevent external modifications while daemon running\n4. SQLite WAL mode change notifications","design":"**Better approach: Check DB file mtime on cache lookup**\n\nToo many commands bypass the daemon (import, init, renumber, compact, delete, dep tree, export, stale). Notifying from each would be error-prone and easy to forget when adding new commands.\n\n**Implementation:**\n\n1. Add `dbMtime time.Time` field to `StorageCacheEntry`\n2. In `getStorageForRequest()` on cache hit:\n - Stat the DB file to get current mtime\n - If mtime changed since cached, evict entry and reopen\n - Otherwise return cached connection\n3. Store mtime when initially caching\n\n**Code location:**\n- `internal/rpc/server.go:1410-1414` (cache hit path)\n- `internal/rpc/server.go:49-52` (StorageCacheEntry struct)\n\n**Benefits:**\n- Simple, centralized check\n- Works for all commands that bypass daemon\n- Works for external tools modifying DB\n- No need to update every command\n- Minimal performance overhead (one stat() call on cache hit)\n\n**Trade-offs:**\n- Small overhead on every cache hit (negligible - stat is fast)\n- mtime granularity may miss rapid changes (unlikely in practice)","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.791369-07:00","closed_at":"2025-10-21T21:51:22.331957-07:00"}
|
||||
{"id":"bd-100","title":"Issue 20","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.548541-07:00","updated_at":"2025-10-22T00:12:34.548541-07:00"}
|
||||
{"id":"bd-101","title":"Issue 21","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.548927-07:00","updated_at":"2025-10-22T00:12:34.548927-07:00"}
|
||||
{"id":"bd-102","title":"Issue 22","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.549366-07:00","updated_at":"2025-10-22T00:12:34.549366-07:00"}
|
||||
{"id":"bd-103","title":"Issue 23","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.549764-07:00","updated_at":"2025-10-22T00:12:34.549764-07:00"}
|
||||
{"id":"bd-104","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.53907-07:00","updated_at":"2025-10-22T00:12:34.53907-07:00"}
|
||||
{"id":"bd-105","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.550657-07:00","updated_at":"2025-10-22T00:12:34.550657-07:00"}
|
||||
{"id":"bd-106","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.551087-07:00","updated_at":"2025-10-22T00:12:34.551087-07:00"}
|
||||
{"id":"bd-107","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.551487-07:00","updated_at":"2025-10-22T00:12:34.551487-07:00"}
|
||||
{"id":"bd-108","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.551872-07:00","updated_at":"2025-10-22T00:12:34.551872-07:00"}
|
||||
{"id":"bd-109","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.539012-07:00","updated_at":"2025-10-22T00:12:34.539012-07:00"}
|
||||
{"id":"bd-11","title":"Write tests for merge functionality","description":"Unit tests: validation, merge logic, data integrity. Integration tests: end-to-end workflow, export/import. Edge case tests: chains, circular refs, epics.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.791767-07:00"}
|
||||
{"id":"bd-110","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.552671-07:00","updated_at":"2025-10-22T00:12:34.552671-07:00"}
|
||||
{"id":"bd-111","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.553128-07:00","updated_at":"2025-10-22T00:12:34.553128-07:00"}
|
||||
{"id":"bd-112","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.553578-07:00","updated_at":"2025-10-22T00:12:34.553578-07:00"}
|
||||
{"id":"bd-113","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.553988-07:00","updated_at":"2025-10-22T00:12:34.553988-07:00"}
|
||||
{"id":"bd-114","title":"Issue 5","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.554382-07:00","updated_at":"2025-10-22T00:12:34.554382-07:00"}
|
||||
{"id":"bd-115","title":"Issue 6","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.554826-07:00","updated_at":"2025-10-22T00:12:34.554826-07:00"}
|
||||
{"id":"bd-116","title":"Issue 7","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.555233-07:00","updated_at":"2025-10-22T00:12:34.555233-07:00"}
|
||||
{"id":"bd-117","title":"Issue 8","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.555624-07:00","updated_at":"2025-10-22T00:12:34.555624-07:00"}
|
||||
{"id":"bd-118","title":"Issue 9","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.555987-07:00","updated_at":"2025-10-22T00:12:34.555987-07:00"}
|
||||
{"id":"bd-119","title":"Issue 10","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.556351-07:00","updated_at":"2025-10-22T00:12:34.556351-07:00"}
|
||||
{"id":"bd-12","title":"Document merge command and AI integration","description":"Update README, AGENTS.md with merge command examples. Document AI agent duplicate detection workflow.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.792103-07:00"}
|
||||
{"id":"bd-120","title":"Issue 11","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.556703-07:00","updated_at":"2025-10-22T00:12:34.556703-07:00"}
|
||||
{"id":"bd-121","title":"Issue 12","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.557054-07:00","updated_at":"2025-10-22T00:12:34.557054-07:00"}
|
||||
{"id":"bd-122","title":"Issue 13","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.557407-07:00","updated_at":"2025-10-22T00:12:34.557407-07:00"}
|
||||
{"id":"bd-123","title":"Issue 14","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.557789-07:00","updated_at":"2025-10-22T00:12:34.557789-07:00"}
|
||||
{"id":"bd-124","title":"Issue 15","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.558153-07:00","updated_at":"2025-10-22T00:12:34.558153-07:00"}
|
||||
{"id":"bd-125","title":"Issue 16","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.55851-07:00","updated_at":"2025-10-22T00:12:34.55851-07:00"}
|
||||
{"id":"bd-126","title":"Issue 17","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.55887-07:00","updated_at":"2025-10-22T00:12:34.55887-07:00"}
|
||||
{"id":"bd-127","title":"Issue 18","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.559238-07:00","updated_at":"2025-10-22T00:12:34.559238-07:00"}
|
||||
{"id":"bd-128","title":"Issue 19","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.559606-07:00","updated_at":"2025-10-22T00:12:34.559606-07:00"}
|
||||
{"id":"bd-129","title":"Issue 20","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.559983-07:00","updated_at":"2025-10-22T00:12:34.559983-07:00"}
|
||||
{"id":"bd-13","title":"Test issue 2","description":"","status":"closed","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.792428-07:00","closed_at":"2025-10-21T22:06:41.257019-07:00","labels":["test-label"]}
|
||||
{"id":"bd-130","title":"Issue 21","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.560382-07:00","updated_at":"2025-10-22T00:12:34.560382-07:00"}
|
||||
{"id":"bd-131","title":"Issue 22","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.560784-07:00","updated_at":"2025-10-22T00:12:34.560784-07:00"}
|
||||
{"id":"bd-132","title":"Issue 23","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.561179-07:00","updated_at":"2025-10-22T00:12:34.561179-07:00"}
|
||||
{"id":"bd-133","title":"Issue 5","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.552272-07:00","updated_at":"2025-10-22T00:12:34.552272-07:00"}
|
||||
{"id":"bd-134","title":"Issue 6","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.563236-07:00","updated_at":"2025-10-22T00:12:34.563236-07:00"}
|
||||
{"id":"bd-135","title":"Issue 7","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.563756-07:00","updated_at":"2025-10-22T00:12:34.563756-07:00"}
|
||||
{"id":"bd-136","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:13:10.598021-07:00","updated_at":"2025-10-22T00:13:10.598021-07:00","comments":[{"id":2,"issue_id":"bd-136","author":"tester","text":"first comment","created_at":"2025-10-22T07:13:10Z"}]}
|
||||
{"id":"bd-137","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:07.586538-07:00","updated_at":"2025-10-22T00:15:07.586538-07:00","comments":[{"id":3,"issue_id":"bd-137","author":"tester","text":"first comment","created_at":"2025-10-22T07:15:07Z"}]}
|
||||
{"id":"bd-138","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:09.391013-07:00","updated_at":"2025-10-22T00:15:09.391013-07:00"}
|
||||
{"id":"bd-139","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:09.500584-07:00","updated_at":"2025-10-22T00:15:09.500584-07:00"}
|
||||
{"id":"bd-14","title":"Test issue 1","description":"","status":"closed","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.79275-07:00","closed_at":"2025-10-21T22:06:41.25599-07:00","labels":["test-label"]}
|
||||
{"id":"bd-140","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:09.944643-07:00","updated_at":"2025-10-22T00:15:09.944643-07:00"}
|
||||
{"id":"bd-141","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:10.055686-07:00","updated_at":"2025-10-22T00:15:10.055686-07:00"}
|
||||
{"id":"bd-142","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:10.170149-07:00","updated_at":"2025-10-22T00:15:10.170149-07:00"}
|
||||
{"id":"bd-143","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:10.279064-07:00","updated_at":"2025-10-22T00:15:10.279064-07:00"}
|
||||
{"id":"bd-144","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:15.681291-07:00","updated_at":"2025-10-22T00:15:15.681291-07:00","comments":[{"id":4,"issue_id":"bd-144","author":"tester","text":"first comment","created_at":"2025-10-22T07:15:15Z"}]}
|
||||
{"id":"bd-145","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:17.522908-07:00","updated_at":"2025-10-22T00:15:17.522908-07:00"}
|
||||
{"id":"bd-146","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:17.633021-07:00","updated_at":"2025-10-22T00:15:17.633021-07:00"}
|
||||
{"id":"bd-147","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.070082-07:00","updated_at":"2025-10-22T00:15:18.070082-07:00"}
|
||||
{"id":"bd-148","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.180845-07:00","updated_at":"2025-10-22T00:15:18.180845-07:00"}
|
||||
{"id":"bd-149","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.292136-07:00","updated_at":"2025-10-22T00:15:18.292136-07:00"}
|
||||
{"id":"bd-15","title":"Add merged_into field to database schema","description":"Add merged_into field to Issue struct and update database schema to support merge tracking","notes":"Simplified: no schema field needed. Close merged issues with reason 'Merged into bd-X'. See bd-79 design.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.793003-07:00"}
|
||||
{"id":"bd-150","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.404769-07:00","updated_at":"2025-10-22T00:15:18.404769-07:00"}
|
||||
{"id":"bd-151","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:23:25.281161-07:00","updated_at":"2025-10-22T00:23:25.281161-07:00","comments":[{"id":5,"issue_id":"bd-151","author":"tester","text":"first comment","created_at":"2025-10-22T07:23:25Z"}]}
|
||||
{"id":"bd-152","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:16.746477-07:00","updated_at":"2025-10-22T00:27:16.746477-07:00","comments":[{"id":6,"issue_id":"bd-152","author":"tester","text":"first comment","created_at":"2025-10-22T07:27:16Z"}]}
|
||||
{"id":"bd-153","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:18.58074-07:00","updated_at":"2025-10-22T00:27:18.58074-07:00"}
|
||||
{"id":"bd-154","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:18.691131-07:00","updated_at":"2025-10-22T00:27:18.691131-07:00"}
|
||||
{"id":"bd-155","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.139441-07:00","updated_at":"2025-10-22T00:27:19.139441-07:00"}
|
||||
{"id":"bd-156","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.254967-07:00","updated_at":"2025-10-22T00:27:19.254967-07:00"}
|
||||
{"id":"bd-157","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.371369-07:00","updated_at":"2025-10-22T00:27:19.371369-07:00"}
|
||||
{"id":"bd-158","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.487356-07:00","updated_at":"2025-10-22T00:27:19.487356-07:00"}
|
||||
{"id":"bd-16","title":"Update export/import for merge fields","description":"Include merged_into in JSONL export format. Handle merge relationships on import.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.79325-07:00"}
|
||||
{"id":"bd-17","title":"Consider implementing pre-commit hooks for Storage interface changes","description":"The documentation (INTERFACE_CHANGES.md) suggests adding pre-commit hooks that automatically check for Storage interface changes and verify all mocks are updated. This would prevent similar issues in the future where interface changes break mock implementations.\n\nDiscovered during execution of vc-228 (dogfooding run #14/15).","design":"Implement a pre-commit hook that:\n1. Detects changes to internal/storage/storage.go\n2. Runs scripts/find-storage-mocks.sh to find all mock implementations\n3. Attempts to compile all test files with mocks\n4. Blocks commit if compilation fails\n\nTools: husky, pre-commit framework, or simple .git/hooks/pre-commit script","acceptance_criteria":"- Pre-commit hook installed and documented\n- Hook detects Storage interface changes\n- Hook validates all mocks compile\n- Hook can be bypassed with --no-verify if needed\n- Documentation updated with installation instructions","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.79362-07:00"}
|
||||
{"id":"bd-18","title":"Implement bd quickstart command","description":"Add bd quickstart command to show context-aware repo information: recent issues, database location, configured prefix, example queries. Helps AI agents understand current project state. Companion to bd onboard.","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.79412-07:00"}
|
||||
{"id":"bd-19","title":"Add customizable time threshold for compact command","description":"Currently compact uses fixed 30-day and 90-day tiers. Add support for custom time thresholds like '--older-than 60h' or '--older-than 2.5d' to allow more flexible compaction policies.\n\nExamples:\n bd compact --all --older-than 60h\n bd compact --all --older-than 2.5d\n bd compact --all --tier 1 --age 48h\n\nThis would allow users to set their own compaction schedules based on their workflow needs.","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.794404-07:00"}
|
||||
{"id":"bd-2","title":"bd sync crashes with nil pointer when daemon is running","description":"The 'bd sync' command crashes with a nil pointer dereference when the daemon is running.\n\n**Reproduction:**\n```bash\n# With daemon running\n./bd sync\n```\n\n**Error:**\n```\npanic: runtime error: invalid memory address or nil pointer dereference\n[signal SIGSEGV: segmentation violation code=0x2 addr=0x120 pc=0x1012314ac]\n\ngoroutine 1 [running]:\nmain.exportToJSONL({0x1014ec2e0, 0x101a49900}, {0x14000028db0, 0x30})\n /Users/stevey/src/fred/beads/cmd/bd/sync.go:245 +0x4c\n```\n\n**Root cause:**\nThe sync command's `exportToJSONL` function directly accesses `store.SearchIssues()` at line 245, but when daemon mode is active, the global `store` variable is nil. The sync command should either:\n1. Use daemon RPC when daemon is running, or\n2. Force direct mode for sync operations\n\n**Workaround:**\nUse `--no-daemon` flag: `bd sync --no-daemon`","status":"closed","priority":0,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:09:12.615536-07:00","closed_at":"2025-10-22T00:09:12.615536-07:00"}
|
||||
{"id":"bd-20","title":"Add --id flag to bd list for filtering by specific issue IDs","description":"","design":"Add --id flag accepting comma-separated IDs. Usage: bd list --id wy-11,wy-12. Combines with other filters. From filter-flag-design.md.","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.795032-07:00"}
|
||||
{"id":"bd-21","title":"Make merge command idempotent for safe retry after partial failures","description":"The merge command currently performs 3 operations without an outer transaction:\n1. Migrate dependencies from source → target\n2. Update text references across all issues\n3. Close source issues\n\nIf merge fails mid-operation (network issue, daemon crash, etc.), a retry will fail or produce incorrect results because some operations already succeeded.\n\n**Goal:** Make merge idempotent so retrying after partial failure is safe and completes the remaining work.\n\n**Idempotency checks needed:**\n- Skip dependency migration if target already has the dependency\n- Skip text reference updates if already updated\n- Skip closing source issues if already closed\n- Report which operations were skipped vs performed\n\n**Example output:**\n```\n✓ Merged 2 issue(s) into bd-128\n - Dependencies: 3 migrated, 2 already existed\n - Text references: 5 updated, 0 already correct\n - Source issues: 1 closed, 1 already closed\n```\n\n**Related:** bd-18 originally requested transaction support, but idempotency is a better solution for this use case since individual operations are already atomic.","design":"Current merge code already has some idempotency:\n- Dependency migration checks `alreadyExists` before adding (line ~145-151 in merge.go)\n- Text reference updates are naturally idempotent (replacing bd-X with bd-Y twice has same result)\n\nMissing idempotency:\n- CloseIssue fails if source already closed\n- Error messages don't distinguish \"already done\" from \"real failure\"\n\nImplementation:\n1. Check source issue status before closing - skip if already closed\n2. Track which operations succeeded/skipped\n3. Return detailed results for user visibility\n4. Consider adding --dry-run output showing what would be done vs skipped","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.795328-07:00"}
|
||||
{"id":"bd-22","title":"Global daemon should warn/reject --auto-commit and --auto-push","description":"When user runs 'bd daemon --global --auto-commit', it's unclear which repo the daemon will commit to (especially after fixing bd-127 where global daemon won't open a DB).\n\nOptions:\n1. Warn and ignore the flags in global mode\n2. Error out with clear message\n\nLine 87-91 already checks autoPush, but should skip check entirely for global mode. Add user-friendly messaging about flag incompatibility.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.795648-07:00","closed_at":"2025-10-17T23:04:30.223432-07:00"}
|
||||
{"id":"bd-23","title":"Improve error handling in dependency removal during remapping","description":"In updateDependencyReferences(), RemoveDependency errors are caught and ignored with continue (line 392). Comment says 'if dependency doesn't exist' but this catches ALL errors including real failures. Should check error type with errors.Is(err, ErrDependencyNotFound) and only ignore not-found errors, returning other errors properly.","status":"closed","priority":3,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.795926-07:00","closed_at":"2025-10-18T09:41:18.209717-07:00"}
|
||||
{"id":"bd-24","title":"Optimize export dependency queries (N+1 problem)","description":"Export triggers separate GetDependencyRecords() per issue. For large DBs (1000+ issues), this is N+1 queries. Add GetAllDependencyRecords() to fetch all dependencies in one query. Location: cmd/bd/export.go:52-59, import.go:138-142","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.796183-07:00","closed_at":"2025-10-14T02:51:52.19905-07:00"}
|
||||
{"id":"bd-25","title":"Add workspace config file for multi-repo management (optional enhancement)","description":"For users who want explicit control over multi-repo setup without daemon, add optional workspace config file.\n\nConfig file: ~/.beads/workspaces.toml\n\nExample:\n[workspaces]\ncurrent = \"global\"\n\n[workspace.global]\ndb = \"~/.beads/global.db\"\ndescription = \"System-wide tasks\"\n\n[workspace.project1] \ndb = \"~/src/project1/.beads/db.sqlite\"\ndescription = \"Main product\"\n\n[workspace.project2]\ndb = \"~/src/project2/.beads/db.sqlite\"\ndescription = \"Internal tools\"\n\nCommands:\nbd workspace list # Show all workspaces\nbd workspace add NAME PATH # Add workspace\nbd workspace remove NAME # Remove workspace \nbd workspace use NAME # Switch active workspace\nbd workspace current # Show current workspace\nbd --workspace NAME \u003ccommand\u003e # Override for single command\n\nImplementation:\n- Load config in PersistentPreRun\n- Override dbPath based on current workspace\n- Store workspace state in config file\n- Support both workspace config AND auto-discovery\n- Workspace config takes precedence over auto-discovery\n\nPriority rationale:\n- Priority 3 (low) because daemon approach already solves this\n- Only implement if users request explicit workspace management\n- Adds complexity vs daemon's automatic discovery\n\nAlternative: Users can use BEADS_DB env var for manual workspace switching today.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.796437-07:00","closed_at":"2025-10-20T16:04:27.216482-07:00"}
|
||||
{"id":"bd-26","title":"Use safer placeholder pattern in replaceIDReferences","description":"Currently uses bd-313 which could theoretically collide with user text. Use a truly unique placeholder like null bytes: \\x00REMAP\\x00_0_\\x00 which are unlikely to appear in normal text. Located in collision.go:324. Very low probability issue but worth fixing for completeness.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.796701-07:00","closed_at":"2025-10-18T09:43:18.250156-07:00"}
|
||||
{"id":"bd-27","title":"Implement full cross-type cycle prevention in AddDependency","description":"Expand cycle prevention in AddDependency to check for cycles across ALL dependency types, not just 'blocks'. Currently only 'blocks' type dependencies are checked for cycles, allowing cross-type circular dependencies to form (e.g., A blocks B, B parent-child A). This can cause semantic confusion and is a maintenance hazard for future operations that traverse dependencies.","design":"Implementation approach:\n1. Modify the cycle check in AddDependency (postgres.go:559-599)\n2. Remove the 'type = blocks' filter from the recursive CTE\n3. Check for cycles regardless of dependency type being added\n4. Return a clear error message indicating which types form the cycle\n\nTrade-offs to consider:\n- This is more mathematically correct (no cycles in dependency DAG)\n- May break legitimate use cases where cross-type cycles are intentional\n- Need to evaluate whether ANY cross-type cycles are valid in practice\n- Alternative: make this configurable with a --allow-cycle flag\n\nBefore implementing, should investigate:\n- Are there legitimate reasons for cross-type cycles?\n- What's the performance impact on large graphs (1000+ issues)?\n- Should certain type combinations be allowed to cycle?","acceptance_criteria":"- AddDependency prevents cycles across all dependency types, not just 'blocks'\n- Clear error message when cycle would be created, including dependency types\n- All existing tests pass\n- Performance benchmarked on large dependency graphs (100+ issues)\n- Decision documented on whether to add --allow-cycle flag or exception rules","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.796963-07:00","closed_at":"2025-10-16T20:31:19.174534-07:00"}
|
||||
{"id":"bd-28","title":"Refactor duplicate flush logic in PersistentPostRun","description":"PersistentPostRun contains a complete copy of the flush logic instead of calling flushToJSONL(). This violates DRY principle and makes maintenance harder. Refactor to use flushToJSONL() with a force parameter to bypass isDirty check, or extract shared logic into a helper function. Located in cmd/bd/main.go:104-138.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.797229-07:00","closed_at":"2025-10-18T09:44:24.167574-07:00"}
|
||||
{"id":"bd-29","title":"Optimize auto-flush to use incremental updates","description":"Every flush exports ALL issues and ALL dependencies, even if only one issue changed. For large projects (1000+ issues), this could be expensive. Current approach guarantees consistency, which is fine for MVP, but future optimization could track which issues changed and use incremental updates. Located in cmd/bd/main.go:255-276.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.797496-07:00","closed_at":"2025-10-14T02:51:52.200141-07:00"}
|
||||
{"id":"bd-3","title":"Implement text reference scanning and replacement","description":"Scan all issues for text references to merged IDs (bd-X patterns) and update to target ID. Reuse logic from import collision resolution.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.797725-07:00"}
|
||||
{"id":"bd-30","title":"Make auto-flush debounce duration configurable","description":"flushDebounce is hardcoded to 5 seconds. Make it configurable via environment variable BEADS_FLUSH_DEBOUNCE (e.g., '500ms', '10s'). Current 5-second value is reasonable for interactive use, but CI/automated scenarios might want faster flush. Add getDebounceDuration() helper function. Located in cmd/bd/main.go:31.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.797968-07:00","closed_at":"2025-10-18T09:47:43.22126-07:00"}
|
||||
{"id":"bd-31","title":"Document label best practices and use cases","description":"Create documentation covering:\n- When to use labels vs structured fields\n- Common label sets (coding agents, open source, product dev, SRE)\n- Naming conventions (kebab-case, specificity, present tense)\n- Anti-patterns (too many labels, overlapping, personal labels)\n- Label lifecycle management\n\nContent from LABELS.md analysis document.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.798235-07:00","closed_at":"2025-10-19T23:11:46.125417-07:00"}
|
||||
{"id":"bd-32","title":"Add rule-based compaction (e.g., compact children of closed epics)","description":"Support semantic compaction rules beyond just time-based, such as:\n- Compact all children of closed epics\n- Compact by priority level (e.g., all P3/P4 closed issues)\n- Compact by label (e.g., all issues labeled 'archive')\n- Compact by type (e.g., all closed chores)\n\nThis would allow smarter database size management based on semantic meaning rather than just age.","status":"open","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.798481-07:00"}
|
||||
{"id":"bd-33","title":"Add compact --dry-run that shows size savings estimates","description":"When running 'bd compact --dry-run', show estimated database size reduction in KB/MB and percentage, similar to what 'du -h' would show.\n\nExample output:\n Tier 1 candidates: 15 issues\n Current size: 2.4 MB\n After compaction: ~1.7 MB (70% reduction, 0.7 MB saved)\n \nThis helps users understand impact before compacting.","status":"open","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.798812-07:00"}
|
||||
{"id":"bd-34","title":"Add EXPLAIN QUERY PLAN tests for ready work query","description":"Verify that the hierarchical blocking query uses proper indexes and doesn't do full table scans.\n\n**Queries to analyze:**\n1. The recursive CTE (both base case and recursive case)\n2. The final SELECT with NOT EXISTS\n3. Impact of various filters (status, priority, assignee)\n\n**Implementation:**\nAdd test function that:\n- Runs EXPLAIN QUERY PLAN on GetReadyWork query\n- Parses output to verify no SCAN TABLE operations\n- Documents expected query plan in comments\n- Fails if query plan degrades\n\n**Benefits:**\n- Catch performance regressions in tests\n- Document expected query behavior\n- Ensure indexes are being used\n\nRelated to: bd-87 (composite index on depends_on_id, type)","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.799084-07:00","closed_at":"2025-10-18T12:47:44.284846-07:00"}
|
||||
{"id":"bd-35","title":"Add performance benchmarks document","description":"Document actual performance metrics with hyperfine tests","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.799333-07:00","closed_at":"2025-10-18T10:09:23.532938-07:00"}
|
||||
{"id":"bd-36","title":"Investigate vector/semantic search for issue discovery","description":"From GH issue #2 RFC discussion: Evaluate if vector/semantic search over issues would provide value for beads.\n\n**Use case:** Find semantically related issues (e.g., 'login broken' finds 'authentication failure', 'session expired').\n\n**Questions to answer:**\n1. What workflows would this enable that we can't do now?\n2. Is dataset size (typically 50-200 issues) large enough to benefit?\n3. Do structured features (deps, tags, types) already provide better relationships?\n4. What's the maintenance cost (embeddings, storage, recomputation)?\n\n**Alternatives to consider:**\n- Improve 'bd list' filtering with regex/boolean queries\n- Add 'bd related \u003cid\u003e' showing deps + mentions + same tags\n- Export to JSON and pipe to external AI tools\n\n**Decision:** Only implement if clear use case emerges. Don't add complexity for theoretical benefits.\n\n**Context:** Part of evaluating Turso RFC ideas (GH #2). Vector search was proposed but unclear if needed for typical beads usage.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.799595-07:00","closed_at":"2025-10-18T10:09:23.532858-07:00"}
|
||||
{"id":"bd-37","title":"Add visual indicators for nodes with multiple parents in dep tree","description":"When a node appears in the dependency tree via multiple paths (diamond dependencies), add a visual indicator like (*) or (multiple parents) to help users understand the graph structure. This would make it clear when deduplication has occurred. Example: 'bd-503: Shared dependency (*) [P1] (open)'","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.799859-07:00","closed_at":"2025-10-20T14:34:52.483358-07:00"}
|
||||
{"id":"bd-38","title":"Add --show-all-paths flag to bd dep tree","description":"Currently bd dep tree deduplicates nodes when multiple paths exist (diamond dependencies). Add optional --show-all-paths flag to display the full graph with all paths, showing duplicates. Useful for debugging complex dependency structures and understanding all relationships.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.800108-07:00","closed_at":"2025-10-18T10:11:38.985862-07:00"}
|
||||
{"id":"bd-39","title":"Refactor parseMarkdownFile to reduce cyclomatic complexity","description":"The parseMarkdownFile function in cmd/bd/markdown.go has a cyclomatic complexity of 38, which exceeds the recommended threshold of 30. This makes the function harder to understand, test, and maintain.","design":"Split the function into smaller, focused units:\n\n1. parseMarkdownFile(filepath) - Main entry point, handles file I/O\n2. parseMarkdownContent(scanner) - Core parsing logic\n3. processIssueSection(issue, section, content) - Handle section finalization (current switch statement)\n4. parseLabels(content) []string - Extract labels from content\n5. parseDependencies(content) []string - Extract dependencies from content\n6. parsePriority(content) int - Parse and validate priority\n\nBenefits:\n- Each function has a single responsibility\n- Easier to test individual components\n- Lower cognitive load when reading code\n- Better encapsulation of parsing logic","acceptance_criteria":"- parseMarkdownFile complexity \u003c 15\n- New helper functions each have complexity \u003c 10\n- All existing tests still pass\n- No change in functionality or behavior\n- Code coverage maintained or improved","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.800371-07:00","closed_at":"2025-10-14T14:37:17.463352-07:00"}
|
||||
{"id":"bd-4","title":"Add CLI merge command and flags","description":"Implement bd merge command with: multiple sources, --into target, --dry-run, --json flags. Add interactive confirmation.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.800616-07:00"}
|
||||
{"id":"bd-40","title":"Simplify getNextID SQL query parameters","description":"Query passes prefix four times to same SQL query. Works but fragile if query changes. Consider simplifying SQL to require fewer parameters. Location: internal/storage/sqlite/sqlite.go:73-78","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.80089-07:00","closed_at":"2025-10-16T10:07:34.038708-07:00"}
|
||||
{"id":"bd-41","title":"Add validation/warning for malformed issue IDs","description":"getNextID silently ignores non-numeric ID suffixes (e.g., bd-foo). CAST returns NULL for invalid strings. Consider detecting and warning about malformed IDs in database. Location: internal/storage/sqlite/sqlite.go:79-82","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.801131-07:00","closed_at":"2025-10-14T02:51:52.198988-07:00"}
|
||||
{"id":"bd-42","title":"Add transaction support to storage layer for atomic multi-operation workflows","description":"Currently each storage method (CreateIssue, UpdateIssue, etc.) starts its own transaction. This makes it impossible to perform atomic multi-step operations like collision resolution. Add support for passing *sql.Tx through the storage interface, or create transaction-aware versions of methods. This would make remapCollisions and other batch operations truly atomic.","status":"closed","priority":4,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.801366-07:00","closed_at":"2025-10-14T02:51:52.199176-07:00"}
|
||||
{"id":"bd-43","title":"Make maxDepth configurable in bd dep tree command","description":"Currently maxDepth is hardcoded to 50 in GetDependencyTree. Add --max-depth flag to bd dep tree command to allow users to control recursion depth. Default should remain 50 for safety, but users with very deep trees or wanting shallow views should be able to configure it.","status":"closed","priority":4,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.801595-07:00","closed_at":"2025-10-19T08:59:59.596748-07:00"}
|
||||
{"id":"bd-44","title":"Add cross-repo issue references (future enhancement)","description":"Support referencing issues across different beads repositories. Useful for tracking dependencies between separate projects.\n\nProposed syntax:\n- Local reference: bd-128 (current behavior)\n- Cross-repo by path: ~/src/other-project#bd-456\n- Cross-repo by workspace name: @project2:bd-789\n\nUse cases:\n1. Frontend project depends on backend API issue\n2. Shared library changes blocking multiple projects\n3. System administrator tracking work across machines\n4. Monorepo with separate beads databases per component\n\nImplementation challenges:\n- Storage layer needs to query external databases\n- Dependency resolution across repos\n- What if external repo not available?\n- How to handle in JSONL export/import?\n- Security: should repos be able to read others?\n\nDesign questions to resolve first:\n1. Read-only references vs full cross-repo dependencies?\n2. How to handle repo renames/moves?\n3. Absolute paths vs workspace names vs git remotes?\n4. Should bd-183 auto-discover related repos?\n\nRecommendation: \n- Gather user feedback first\n- Start with read-only references\n- Implement as plugin/extension?\n\nContext: This is mentioned in bd-183 as approach #2. Much more complex than daemon multi-repo approach. Only implement if there's strong user demand.\n\nPriority: Backlog (4) - wait for user feedback before designing","status":"closed","priority":4,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.801841-07:00","closed_at":"2025-10-20T22:00:31.966891-07:00"}
|
||||
{"id":"bd-45","title":"Test auto-export timing","description":"","status":"closed","priority":4,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.802091-07:00","closed_at":"2025-10-20T22:00:31.964329-07:00"}
|
||||
{"id":"bd-46","title":"Test real auto-export","description":"","status":"closed","priority":4,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.802319-07:00","closed_at":"2025-10-20T22:00:31.967571-07:00"}
|
||||
{"id":"bd-47","title":"Remove unused issueMap in scoreCollisions","description":"scoreCollisions() creates issueMap and populates it (lines 135-138) but never uses it. Either remove it or add a TODO comment explaining future use. Located in collision.go:135-138. Cosmetic cleanup.","status":"closed","priority":4,"issue_type":"chore","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.802557-07:00","closed_at":"2025-10-19T19:27:34.230312-07:00"}
|
||||
{"id":"bd-48","title":"Add godoc comments for auto-flush functions","description":"Add comprehensive godoc comments for findJSONLPath(), markDirtyAndScheduleFlush(), and flushToJSONL() explaining behavior, concurrency considerations, and error handling. Include notes about debouncing behavior (timer resets on each write, flush occurs 5s after LAST operation) and flush-on-exit guarantees. Located in cmd/bd/main.go:188-307.","status":"closed","priority":4,"issue_type":"chore","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.80278-07:00","closed_at":"2025-10-19T19:22:19.172983-07:00"}
|
||||
{"id":"bd-49","title":"Issue counter gets out of sync with actual issues","description":"The issue counter in issue_counters table frequently desyncs from actual max issue ID, causing:\n- Import from JSONL leaves counter at old high value\n- Test pollution increments counter but cleanup doesn't decrement it\n- Delete issues doesn't update counter\n- Only fix is 'rm -rf .beads' which is destructive\n\nExamples from today's session:\n- Had 48 issues but counter at 7714 after test pollution\n- Import from git didn't reset counter\n- Next new issue would be bd-7715 instead of bd-49\n\nProposed fixes:\n1. Auto-recalculate counter from max(issue_id) on import\n2. Add 'bd fix-counter' command\n3. Make counter lazy (always compute from DB, don't store)\n4. Import should reset counter to match imported data\n\nRelated: bd-1 (test isolation), bd-50 (init timestamp bug)","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.803004-07:00","closed_at":"2025-10-21T23:13:04.249149-07:00"}
|
||||
{"id":"bd-5","title":"Add transaction support for atomic merges","description":"Wrap all merge operations in SQLite transaction for atomicity. Implement rollback on failure.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.803265-07:00"}
|
||||
{"id":"bd-50","title":"Counter not synced after import on existing DB with populated issue_counters table","description":"The counter sync fix in counter_sync_test.go only syncs during initial migration when issue_counters table is empty (migrateIssueCountersTable checks count==0). For existing databases with stale counters:\n\n- Import doesn't resync the counter\n- Delete doesn't update counter \n- Renumber doesn't fix counter\n- Counter remains stuck at old high value\n\nExample from today:\n- Had 49 issues after clean import\n- Counter stuck at 4106 from previous test pollution\n- Next issue would be bd-4107 instead of bd-50\n- Even after renumber, counter stayed at 4106\n\nRoot cause: Migration only syncs if table is empty (line 182 in sqlite.go). Once populated, never resyncs.\n\nFix needed: \n1. Sync counter after import operations (not just empty table)\n2. Add counter resync after renumber\n3. Daemon caches counter value - needs to reload after external changes\n\nRelated: bd-49 (original counter sync fix), bd-10 (daemon cache staleness)","notes":"## Investigation Results\n\nAfter thorough code review, all the fixes mentioned in the issue description have ALREADY been implemented:\n\n### ✅ Fixes Already in Place:\n\n1. **Import DOES resync counters**\n - `cmd/bd/import_shared.go:253` calls `SyncAllCounters()` after batch import\n - Verified with new test `TestCounterSyncAfterImport`\n\n2. **Delete DOES update counters**\n - `internal/storage/sqlite/sqlite.go:1424` calls `SyncAllCounters()` after deletion\n - Both single delete and batch delete sync properly\n - Verified with existing tests: `TestCounterSyncAfterDelete`, `TestCounterSyncAfterBatchDelete`\n\n3. **Renumber DOES fix counters**\n - `cmd/bd/renumber.go:298-304` calls `ResetCounter()` then `SyncAllCounters()`\n - Forces counter to actual max ID (not just MAX with stale value)\n\n4. **Daemon cache DOES detect external changes**\n - `internal/rpc/server.go:1466-1487` checks file mtime and evicts stale cache\n - When DB file changes externally, cached storage is evicted and reopened\n\n### Tests Added:\n\n- `TestCounterSyncAfterImport`: Confirms import syncs counters from stale value (4106) to actual max (49)\n- `TestCounterNotSyncedWithoutExplicitSync`: Documents what would happen without the fix (bd-4107 instead of bd-50)\n\n### Conclusion:\n\nThe issue described in bd-50 has been **fully resolved**. All operations (import, delete, renumber) now properly sync counters. The daemon correctly detects external DB changes via file modification time.\n\nThe root cause (migration only syncing empty tables) was fixed by adding explicit `SyncAllCounters()` calls after import, delete, and renumber operations.","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:54:57.367425-07:00","updated_at":"2025-10-22T00:05:10.80351-07:00","closed_at":"2025-10-22T00:03:46.697918-07:00"}
|
||||
{"id":"bd-51","title":"Auto-flush writes test pollution and session work to git-tracked issues.jsonl","description":"Auto-flush exports ALL issues from DB to issues.jsonl every 5 seconds, including:\n- Test issues (bd-4053 through bd-4059 were version test junk)\n- Issues created during debugging sessions\n- Test pollution from stress tests\n- Temporary diagnostic issues\n\nThis pollutes the git-tracked issues.jsonl with garbage that shouldn't be committed.\n\nExample from today:\n- Git had 49 clean issues\n- Our DB grew to 100+ with test junk and session work\n- Auto-flush wrote all 100+ to issues.jsonl\n- Git status showed modified issues.jsonl with 50+ unwanted issues\n\nImpact:\n- Pollutes git history with test/debug garbage\n- Makes code review difficult (noise in diffs)\n- Can't distinguish real work from session artifacts\n- Other team members pull polluted issues\n\nSolutions to consider:\n1. Disable auto-flush by default (require explicit --enable-auto-flush)\n2. Add .beadsignore to exclude issue ID patterns\n3. Make auto-flush only export 'real' issues (exclude test-*)\n4. Require manual 'bd sync' for git commit\n5. Auto-flush to separate file (.beads/session.jsonl vs issues.jsonl)\n\nRelated: bd-49 (test pollution), isolation_test.go (test DB separation)","design":"## Analysis\n\nConfirmed the issue exists - bd-52 through bd-58 are test pollution in the git-tracked issues.jsonl.\n\n### Solution Evaluation:\n\n**Option 1: Disable auto-flush by default** ❌\n- Breaks the auto-sync workflow that users rely on\n- Requires manual intervention which defeats the purpose\n- Not recommended\n\n**Option 2: Add .beadsignore** ⚠️\n- Complex to implement (pattern matching, configuration)\n- Doesn't solve root cause: test issues in production DB\n- Better to prevent pollution at source\n\n**Option 3: Filter on export** ❌\n- Doesn't solve root cause\n- Test issues still pollute production DB\n- Complicates export logic\n\n**Option 4: Manual 'bd sync'** ❌\n- Same issues as Option 1\n- Breaks automated workflow\n\n**Option 5: Separate session file** ❌\n- Splits issue tracking across files\n- Confusing for users\n- Import/export complexity\n\n### RECOMMENDED SOLUTION:\n\n**Fix the root cause: Tests should NEVER touch the production database**\n\nThe real problem is that Go tests ARE properly isolated (they use temp DBs), but someone must be manually creating test issues in the production DB during development/debugging.\n\n**Best fix:**\n1. Document that production DB is for real work only\n2. Add a convenience command: `bd test-create` that uses a separate test database\n3. Clean up the existing test pollution: bd-52 through bd-58\n4. Consider adding a git pre-commit hook to warn about suspicious issues\n\nThis preserves auto-flush (which is valuable) while preventing pollution at the source.","notes":"## Resolution\n\n**Root Cause Identified:**\nThe issue was NOT a bug in auto-flush, but rather test pollution in the production database from manual testing/debugging. Go tests are properly isolated using temp directories.\n\n**Actions Taken:**\n1. Cleaned up test pollution: deleted bd-52 through bd-58 (all \"Version test issue\" entries)\n2. Verified auto-flush is working correctly - it exports the database as designed\n3. Confirmed Go test isolation works properly (uses temp dirs, not production DB)\n\n**Prevention Strategy:**\n- Production database (.beads/) should only contain real work issues\n- Manual testing should use throwaway databases or test scripts\n- Go tests already use isolated temp databases\n- Auto-flush is working as intended and should remain enabled\n\n**Conclusion:**\nThis was user error, not a system bug. The auto-flush mechanism is correct - it should export ALL database contents. The problem was polluting the production database with test issues in the first place.","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:54:57.369511-07:00","updated_at":"2025-10-22T00:05:29.864829-07:00","closed_at":"2025-10-22T00:05:29.864829-07:00"}
|
||||
{"id":"bd-59","title":"Auto-flush writes test pollution and session work to git-tracked issues.jsonl","description":"Auto-flush exports ALL issues from DB to issues.jsonl every 5 seconds, including:\n- Test issues (bd-4053 through bd-4059 were version test junk)\n- Issues created during debugging sessions\n- Test pollution from stress tests\n- Temporary diagnostic issues\n\nThis pollutes the git-tracked issues.jsonl with garbage that shouldn't be committed.\n\nExample from today:\n- Git had 49 clean issues\n- Our DB grew to 100+ with test junk and session work\n- Auto-flush wrote all 100+ to issues.jsonl\n- Git status showed modified issues.jsonl with 50+ unwanted issues\n\nImpact:\n- Pollutes git history with test/debug garbage\n- Makes code review difficult (noise in diffs)\n- Can't distinguish real work from session artifacts\n- Other team members pull polluted issues\n\nSolutions to consider:\n1. Disable auto-flush by default (require explicit --enable-auto-flush)\n2. Add .beadsignore to exclude issue ID patterns\n3. Make auto-flush only export 'real' issues (exclude test-*)\n4. Require manual 'bd sync' for git commit\n5. Auto-flush to separate file (.beads/session.jsonl vs issues.jsonl)\n\nRelated: bd-49 (test pollution), isolation_test.go (test DB separation)","status":"open","priority":1,"issue_type":"bug","created_at":"2025-10-22T00:05:10.788996-07:00","updated_at":"2025-10-22T00:05:10.80377-07:00"}
|
||||
{"id":"bd-6","title":"Implement dependency migration for merge","description":"Migrate all dependencies from source issue(s) to target issue during merge, removing duplicates and preserving graph integrity","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.805517-07:00"}
|
||||
{"id":"bd-60","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.400802-07:00","updated_at":"2025-10-22T00:12:34.400802-07:00"}
|
||||
{"id":"bd-61","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402704-07:00","updated_at":"2025-10-22T00:12:34.402704-07:00"}
|
||||
{"id":"bd-62","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402279-07:00","updated_at":"2025-10-22T00:12:34.402279-07:00"}
|
||||
{"id":"bd-63","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.404166-07:00","updated_at":"2025-10-22T00:12:34.404166-07:00"}
|
||||
{"id":"bd-64","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.403441-07:00","updated_at":"2025-10-22T00:12:34.403441-07:00"}
|
||||
{"id":"bd-65","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402415-07:00","updated_at":"2025-10-22T00:12:34.402415-07:00"}
|
||||
{"id":"bd-66","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.407606-07:00","updated_at":"2025-10-22T00:12:34.407606-07:00"}
|
||||
{"id":"bd-67","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.40764-07:00","updated_at":"2025-10-22T00:12:34.40764-07:00"}
|
||||
{"id":"bd-68","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.40883-07:00","updated_at":"2025-10-22T00:12:34.40883-07:00"}
|
||||
{"id":"bd-69","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.40767-07:00","updated_at":"2025-10-22T00:12:34.40767-07:00"}
|
||||
{"id":"bd-7","title":"Fix flaky CI tests in compactor and daemon modules","description":"Multiple test failures observed in CI:\n- TestCompactTier1_DryRun \n- TestCompactTier1Batch_DryRun\n- TestCompactTier1Batch_WithIneligible\n- TestMockAPI_CompactTier1\n- TestBatchOperations_ErrorHandling\n- TestCommentOperationsViaRPC\n- TestMemoryPressureDetection\n- TestPing\n\nAll failures related to 'issue has open dependents or not closed long enough' eligibility checks.\n\nSee CI run: https://github.com/steveyegge/beads/actions/runs/18688772658","status":"open","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.805734-07:00"}
|
||||
{"id":"bd-70","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.409931-07:00","updated_at":"2025-10-22T00:12:34.409931-07:00"}
|
||||
{"id":"bd-71","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.410401-07:00","updated_at":"2025-10-22T00:12:34.410401-07:00"}
|
||||
{"id":"bd-72","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.410855-07:00","updated_at":"2025-10-22T00:12:34.410855-07:00"}
|
||||
{"id":"bd-73","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.408355-07:00","updated_at":"2025-10-22T00:12:34.408355-07:00"}
|
||||
{"id":"bd-74","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.412011-07:00","updated_at":"2025-10-22T00:12:34.412011-07:00"}
|
||||
{"id":"bd-75","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402341-07:00","updated_at":"2025-10-22T00:12:34.402341-07:00"}
|
||||
{"id":"bd-76","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.422106-07:00","updated_at":"2025-10-22T00:12:34.422106-07:00"}
|
||||
{"id":"bd-77","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.422587-07:00","updated_at":"2025-10-22T00:12:34.422587-07:00"}
|
||||
{"id":"bd-78","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.423021-07:00","updated_at":"2025-10-22T00:12:34.423021-07:00"}
|
||||
{"id":"bd-79","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.423454-07:00","updated_at":"2025-10-22T00:12:34.423454-07:00"}
|
||||
{"id":"bd-8","title":"Compact command fails with daemon - requires --no-daemon workaround","description":"The 'bd compact' command fails with 'Error: compact requires SQLite storage' when used with the daemon (default mode), but works correctly with the '--no-daemon' flag.\n\nThe daemon RPC interface doesn't properly expose the compact command, even though the daemon itself uses SQLite storage.\n\nReproduction:\n1. Ensure daemon is running (bd daemon status)\n2. Run: bd compact --stats\n Result: Error: compact requires SQLite storage\n3. Run: bd compact --stats --no-daemon\n Result: Works correctly, shows statistics\n\nExpected behavior:\nThe compact command should work through the daemon RPC interface just like other commands (list, create, update, delete, renumber, etc.)\n\nImpact:\nUsers cannot use compact operations in the normal workflow. They must use --no-daemon which bypasses the daemon entirely.\n\nSuggested fix:\nAdd compact operation support to the daemon RPC interface, similar to how renumber and other operations are exposed.","status":"in_progress","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.805962-07:00"}
|
||||
{"id":"bd-80","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.537799-07:00","updated_at":"2025-10-22T00:12:34.537799-07:00"}
|
||||
{"id":"bd-81","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.539461-07:00","updated_at":"2025-10-22T00:12:34.539461-07:00"}
|
||||
{"id":"bd-82","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.540087-07:00","updated_at":"2025-10-22T00:12:34.540087-07:00"}
|
||||
{"id":"bd-83","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.540633-07:00","updated_at":"2025-10-22T00:12:34.540633-07:00"}
|
||||
{"id":"bd-84","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.541173-07:00","updated_at":"2025-10-22T00:12:34.541173-07:00"}
|
||||
{"id":"bd-85","title":"Issue 5","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.541664-07:00","updated_at":"2025-10-22T00:12:34.541664-07:00"}
|
||||
{"id":"bd-86","title":"Issue 6","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.54216-07:00","updated_at":"2025-10-22T00:12:34.54216-07:00"}
|
||||
{"id":"bd-87","title":"Issue 7","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.54266-07:00","updated_at":"2025-10-22T00:12:34.54266-07:00"}
|
||||
{"id":"bd-88","title":"Issue 8","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.543237-07:00","updated_at":"2025-10-22T00:12:34.543237-07:00"}
|
||||
{"id":"bd-89","title":"Issue 9","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.543804-07:00","updated_at":"2025-10-22T00:12:34.543804-07:00"}
|
||||
{"id":"bd-9","title":"Investigate stress test database pollution (vc-248)","description":"Investigation of stress tests polluting production database with 1,600+ test issues on Oct 21 at 20:24-20:25. Root cause analysis completed. Tests now verified to work correctly with proper isolation.","notes":"Bug confirmed! Tests DO pollute production DB. 1,000 test issues created at 20:46:01-20:46:02 during TestStressNoUniqueConstraintViolations. Root cause: test goroutines connect to production daemon at .beads/bd.sock instead of test daemon.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:05:10.806182-07:00"}
|
||||
{"id":"bd-90","title":"Issue 10","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.544303-07:00","updated_at":"2025-10-22T00:12:34.544303-07:00"}
|
||||
{"id":"bd-91","title":"Issue 11","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.544799-07:00","updated_at":"2025-10-22T00:12:34.544799-07:00"}
|
||||
{"id":"bd-92","title":"Issue 12","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.545268-07:00","updated_at":"2025-10-22T00:12:34.545268-07:00"}
|
||||
{"id":"bd-93","title":"Issue 13","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.545734-07:00","updated_at":"2025-10-22T00:12:34.545734-07:00"}
|
||||
{"id":"bd-94","title":"Issue 14","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.546157-07:00","updated_at":"2025-10-22T00:12:34.546157-07:00"}
|
||||
{"id":"bd-95","title":"Issue 15","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.546559-07:00","updated_at":"2025-10-22T00:12:34.546559-07:00"}
|
||||
{"id":"bd-96","title":"Issue 16","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.546964-07:00","updated_at":"2025-10-22T00:12:34.546964-07:00"}
|
||||
{"id":"bd-97","title":"Issue 17","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.547368-07:00","updated_at":"2025-10-22T00:12:34.547368-07:00"}
|
||||
{"id":"bd-98","title":"Issue 18","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.547759-07:00","updated_at":"2025-10-22T00:12:34.547759-07:00"}
|
||||
{"id":"bd-99","title":"Issue 19","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.548153-07:00","updated_at":"2025-10-22T00:12:34.548153-07:00"}
|
||||
{"id":"bd-1","title":"Stress tests pollute production database with test issues","description":"TestStressNoUniqueConstraintViolations and other stress tests in internal/rpc/stress_test.go create issues in production database instead of test database. Confirmed: 1,000 test issues (Agent X Issue Y) created at 20:46:01 during test run. Root cause: test goroutines connect to production daemon at .beads/bd.sock instead of isolated test daemon in temp directory.","status":"closed","priority":0,"issue_type":"bug","assignee":"amp","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.536668-07:00","closed_at":"2025-10-22T00:35:00.620546-07:00"}
|
||||
{"id":"bd-10","title":"Daemon storage cache doesn't detect external database modifications","description":"When bd commands bypass the daemon and directly modify the database (e.g., `bd import` with direct file access, or deleting/recreating bd.db), the daemon's cached storage connection becomes stale and serves outdated data.\n\n**Reproduction**:\n1. Start daemon: `bd daemon`\n2. Run bd stats → shows N issues\n3. Delete database: `rm .beads/bd.db` \n4. Reinit and import: `bd init \u0026\u0026 bd import -i .beads/issues.jsonl`\n5. Run bd stats → shows 0 issues (wrong!)\n6. Direct query: `sqlite3 .beads/bd.db 'SELECT COUNT(*) FROM issues'` → shows correct count\n7. Restart daemon: `bd daemon --stop` then retry stats → now shows correct count\n\n**Root cause**: \n- server.go:1410-1414 retrieves cached storage without checking if DB file changed\n- Cache only evicts based on TTL (30min) or LRU, never on external modifications\n- Direct file operations bypass daemon, leaving cache stale\n\n**Impact**:\n- Users see incorrect/stale data after external DB operations\n- Confusing behavior with no clear indication cache is stale\n- Requires daemon restart to fix\n\n**Proposed fixes**:\n1. Check mtime on cache hit, invalidate if file changed\n2. Add cache eviction API (bd cache --clear)\n3. Use file locking to prevent external modifications while daemon running\n4. SQLite WAL mode change notifications","design":"**Better approach: Check DB file mtime on cache lookup**\n\nToo many commands bypass the daemon (import, init, renumber, compact, delete, dep tree, export, stale). Notifying from each would be error-prone and easy to forget when adding new commands.\n\n**Implementation:**\n\n1. Add `dbMtime time.Time` field to `StorageCacheEntry`\n2. In `getStorageForRequest()` on cache hit:\n - Stat the DB file to get current mtime\n - If mtime changed since cached, evict entry and reopen\n - Otherwise return cached connection\n3. Store mtime when initially caching\n\n**Code location:**\n- `internal/rpc/server.go:1410-1414` (cache hit path)\n- `internal/rpc/server.go:49-52` (StorageCacheEntry struct)\n\n**Benefits:**\n- Simple, centralized check\n- Works for all commands that bypass daemon\n- Works for external tools modifying DB\n- No need to update every command\n- Minimal performance overhead (one stat() call on cache hit)\n\n**Trade-offs:**\n- Small overhead on every cache hit (negligible - stat is fast)\n- mtime granularity may miss rapid changes (unlikely in practice)","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.537202-07:00","closed_at":"2025-10-21T21:51:22.331957-07:00"}
|
||||
{"id":"bd-100","title":"Issue 20","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.548541-07:00","updated_at":"2025-10-22T00:43:42.537587-07:00"}
|
||||
{"id":"bd-101","title":"Issue 21","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.548927-07:00","updated_at":"2025-10-22T00:43:42.537886-07:00"}
|
||||
{"id":"bd-102","title":"Issue 22","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.549366-07:00","updated_at":"2025-10-22T00:43:42.538141-07:00"}
|
||||
{"id":"bd-103","title":"Issue 23","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.549764-07:00","updated_at":"2025-10-22T00:43:42.538393-07:00"}
|
||||
{"id":"bd-104","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.53907-07:00","updated_at":"2025-10-22T00:43:42.538636-07:00"}
|
||||
{"id":"bd-105","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.550657-07:00","updated_at":"2025-10-22T00:43:42.539002-07:00"}
|
||||
{"id":"bd-106","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.551087-07:00","updated_at":"2025-10-22T00:43:42.539271-07:00"}
|
||||
{"id":"bd-107","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.551487-07:00","updated_at":"2025-10-22T00:43:42.539502-07:00"}
|
||||
{"id":"bd-108","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.551872-07:00","updated_at":"2025-10-22T00:43:42.539719-07:00"}
|
||||
{"id":"bd-109","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.539012-07:00","updated_at":"2025-10-22T00:43:42.539929-07:00"}
|
||||
{"id":"bd-11","title":"Write tests for merge functionality","description":"Unit tests: validation, merge logic, data integrity. Integration tests: end-to-end workflow, export/import. Edge case tests: chains, circular refs, epics.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.540147-07:00"}
|
||||
{"id":"bd-110","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.552671-07:00","updated_at":"2025-10-22T00:43:42.540527-07:00"}
|
||||
{"id":"bd-111","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.553128-07:00","updated_at":"2025-10-22T00:43:42.541008-07:00"}
|
||||
{"id":"bd-112","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.553578-07:00","updated_at":"2025-10-22T00:43:42.541243-07:00"}
|
||||
{"id":"bd-113","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.553988-07:00","updated_at":"2025-10-22T00:43:42.541463-07:00"}
|
||||
{"id":"bd-114","title":"Issue 5","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.554382-07:00","updated_at":"2025-10-22T00:43:42.541692-07:00"}
|
||||
{"id":"bd-115","title":"Issue 6","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.554826-07:00","updated_at":"2025-10-22T00:43:42.541915-07:00"}
|
||||
{"id":"bd-116","title":"Issue 7","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.555233-07:00","updated_at":"2025-10-22T00:43:42.542135-07:00"}
|
||||
{"id":"bd-117","title":"Issue 8","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.555624-07:00","updated_at":"2025-10-22T00:43:42.542393-07:00"}
|
||||
{"id":"bd-118","title":"Issue 9","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.555987-07:00","updated_at":"2025-10-22T00:43:42.5426-07:00"}
|
||||
{"id":"bd-119","title":"Issue 10","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.556351-07:00","updated_at":"2025-10-22T00:43:42.542823-07:00"}
|
||||
{"id":"bd-12","title":"Document merge command and AI integration","description":"Update README, AGENTS.md with merge command examples. Document AI agent duplicate detection workflow.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.543063-07:00"}
|
||||
{"id":"bd-120","title":"Issue 11","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.556703-07:00","updated_at":"2025-10-22T00:43:42.543303-07:00"}
|
||||
{"id":"bd-121","title":"Issue 12","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.557054-07:00","updated_at":"2025-10-22T00:43:42.543532-07:00"}
|
||||
{"id":"bd-122","title":"Issue 13","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.557407-07:00","updated_at":"2025-10-22T00:43:42.543774-07:00"}
|
||||
{"id":"bd-123","title":"Issue 14","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.557789-07:00","updated_at":"2025-10-22T00:43:42.543986-07:00"}
|
||||
{"id":"bd-124","title":"Issue 15","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.558153-07:00","updated_at":"2025-10-22T00:43:42.544197-07:00"}
|
||||
{"id":"bd-125","title":"Issue 16","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.55851-07:00","updated_at":"2025-10-22T00:43:42.544413-07:00"}
|
||||
{"id":"bd-126","title":"Issue 17","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.55887-07:00","updated_at":"2025-10-22T00:43:42.544618-07:00"}
|
||||
{"id":"bd-127","title":"Issue 18","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.559238-07:00","updated_at":"2025-10-22T00:43:42.544826-07:00"}
|
||||
{"id":"bd-128","title":"Issue 19","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.559606-07:00","updated_at":"2025-10-22T00:43:42.545051-07:00"}
|
||||
{"id":"bd-129","title":"Issue 20","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.559983-07:00","updated_at":"2025-10-22T00:43:42.545267-07:00"}
|
||||
{"id":"bd-13","title":"Test issue 2","description":"","status":"closed","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.545473-07:00","closed_at":"2025-10-21T22:06:41.257019-07:00","labels":["test-label"]}
|
||||
{"id":"bd-130","title":"Issue 21","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.560382-07:00","updated_at":"2025-10-22T00:43:42.545704-07:00"}
|
||||
{"id":"bd-131","title":"Issue 22","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.560784-07:00","updated_at":"2025-10-22T00:43:42.545912-07:00"}
|
||||
{"id":"bd-132","title":"Issue 23","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.561179-07:00","updated_at":"2025-10-22T00:43:42.546113-07:00"}
|
||||
{"id":"bd-133","title":"Issue 5","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.552272-07:00","updated_at":"2025-10-22T00:43:42.546384-07:00"}
|
||||
{"id":"bd-134","title":"Issue 6","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.563236-07:00","updated_at":"2025-10-22T00:43:42.546669-07:00"}
|
||||
{"id":"bd-135","title":"Issue 7","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.563756-07:00","updated_at":"2025-10-22T00:43:42.546885-07:00"}
|
||||
{"id":"bd-136","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:13:10.598021-07:00","updated_at":"2025-10-22T00:43:42.547091-07:00","comments":[{"id":2,"issue_id":"bd-136","author":"tester","text":"first comment","created_at":"2025-10-22T07:13:10Z"}]}
|
||||
{"id":"bd-137","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:07.586538-07:00","updated_at":"2025-10-22T00:43:42.547298-07:00","comments":[{"id":3,"issue_id":"bd-137","author":"tester","text":"first comment","created_at":"2025-10-22T07:15:07Z"}]}
|
||||
{"id":"bd-138","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:09.391013-07:00","updated_at":"2025-10-22T00:43:42.547505-07:00"}
|
||||
{"id":"bd-139","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:09.500584-07:00","updated_at":"2025-10-22T00:43:42.547735-07:00"}
|
||||
{"id":"bd-14","title":"Test issue 1","description":"","status":"closed","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.547949-07:00","closed_at":"2025-10-21T22:06:41.25599-07:00","labels":["test-label"]}
|
||||
{"id":"bd-140","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:09.944643-07:00","updated_at":"2025-10-22T00:43:42.548165-07:00"}
|
||||
{"id":"bd-141","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:10.055686-07:00","updated_at":"2025-10-22T00:43:42.548365-07:00"}
|
||||
{"id":"bd-142","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:10.170149-07:00","updated_at":"2025-10-22T00:43:42.54858-07:00"}
|
||||
{"id":"bd-143","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:10.279064-07:00","updated_at":"2025-10-22T00:43:42.548789-07:00"}
|
||||
{"id":"bd-144","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:15.681291-07:00","updated_at":"2025-10-22T00:43:42.548993-07:00","comments":[{"id":4,"issue_id":"bd-144","author":"tester","text":"first comment","created_at":"2025-10-22T07:15:15Z"}]}
|
||||
{"id":"bd-145","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:17.522908-07:00","updated_at":"2025-10-22T00:43:42.549188-07:00"}
|
||||
{"id":"bd-146","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:17.633021-07:00","updated_at":"2025-10-22T00:43:42.549385-07:00"}
|
||||
{"id":"bd-147","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.070082-07:00","updated_at":"2025-10-22T00:43:42.549603-07:00"}
|
||||
{"id":"bd-148","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.180845-07:00","updated_at":"2025-10-22T00:43:42.549799-07:00"}
|
||||
{"id":"bd-149","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.292136-07:00","updated_at":"2025-10-22T00:43:42.549992-07:00"}
|
||||
{"id":"bd-15","title":"Add merged_into field to database schema","description":"Add merged_into field to Issue struct and update database schema to support merge tracking","notes":"Simplified: no schema field needed. Close merged issues with reason 'Merged into bd-X'. See bd-79 design.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.550195-07:00"}
|
||||
{"id":"bd-150","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:15:18.404769-07:00","updated_at":"2025-10-22T00:43:42.550396-07:00"}
|
||||
{"id":"bd-151","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:23:25.281161-07:00","updated_at":"2025-10-22T00:43:42.550623-07:00","comments":[{"id":5,"issue_id":"bd-151","author":"tester","text":"first comment","created_at":"2025-10-22T07:23:25Z"}]}
|
||||
{"id":"bd-152","title":"Comment test","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:16.746477-07:00","updated_at":"2025-10-22T00:43:42.550816-07:00","comments":[{"id":6,"issue_id":"bd-152","author":"tester","text":"first comment","created_at":"2025-10-22T07:27:16Z"}]}
|
||||
{"id":"bd-153","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:18.58074-07:00","updated_at":"2025-10-22T00:43:42.551006-07:00"}
|
||||
{"id":"bd-154","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:18.691131-07:00","updated_at":"2025-10-22T00:43:42.551208-07:00"}
|
||||
{"id":"bd-155","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.139441-07:00","updated_at":"2025-10-22T00:43:42.551407-07:00"}
|
||||
{"id":"bd-156","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.254967-07:00","updated_at":"2025-10-22T00:43:42.551602-07:00"}
|
||||
{"id":"bd-157","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.371369-07:00","updated_at":"2025-10-22T00:43:42.55179-07:00"}
|
||||
{"id":"bd-158","title":"Version test issue","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:27:19.487356-07:00","updated_at":"2025-10-22T00:43:42.551984-07:00"}
|
||||
{"id":"bd-16","title":"Update export/import for merge fields","description":"Include merged_into in JSONL export format. Handle merge relationships on import.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.552178-07:00"}
|
||||
{"id":"bd-17","title":"Consider implementing pre-commit hooks for Storage interface changes","description":"The documentation (INTERFACE_CHANGES.md) suggests adding pre-commit hooks that automatically check for Storage interface changes and verify all mocks are updated. This would prevent similar issues in the future where interface changes break mock implementations.\n\nDiscovered during execution of vc-228 (dogfooding run #14/15).","design":"Implement a pre-commit hook that:\n1. Detects changes to internal/storage/storage.go\n2. Runs scripts/find-storage-mocks.sh to find all mock implementations\n3. Attempts to compile all test files with mocks\n4. Blocks commit if compilation fails\n\nTools: husky, pre-commit framework, or simple .git/hooks/pre-commit script","acceptance_criteria":"- Pre-commit hook installed and documented\n- Hook detects Storage interface changes\n- Hook validates all mocks compile\n- Hook can be bypassed with --no-verify if needed\n- Documentation updated with installation instructions","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.552389-07:00"}
|
||||
{"id":"bd-18","title":"Implement bd quickstart command","description":"Add bd quickstart command to show context-aware repo information: recent issues, database location, configured prefix, example queries. Helps AI agents understand current project state. Companion to bd onboard.","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.552611-07:00"}
|
||||
{"id":"bd-19","title":"Add customizable time threshold for compact command","description":"Currently compact uses fixed 30-day and 90-day tiers. Add support for custom time thresholds like '--older-than 60h' or '--older-than 2.5d' to allow more flexible compaction policies.\n\nExamples:\n bd compact --all --older-than 60h\n bd compact --all --older-than 2.5d\n bd compact --all --tier 1 --age 48h\n\nThis would allow users to set their own compaction schedules based on their workflow needs.","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.552833-07:00"}
|
||||
{"id":"bd-2","title":"bd sync crashes with nil pointer when daemon is running","description":"The 'bd sync' command crashes with a nil pointer dereference when the daemon is running.\n\n**Reproduction:**\n```bash\n# With daemon running\n./bd sync\n```\n\n**Error:**\n```\npanic: runtime error: invalid memory address or nil pointer dereference\n[signal SIGSEGV: segmentation violation code=0x2 addr=0x120 pc=0x1012314ac]\n\ngoroutine 1 [running]:\nmain.exportToJSONL({0x1014ec2e0, 0x101a49900}, {0x14000028db0, 0x30})\n /Users/stevey/src/fred/beads/cmd/bd/sync.go:245 +0x4c\n```\n\n**Root cause:**\nThe sync command's `exportToJSONL` function directly accesses `store.SearchIssues()` at line 245, but when daemon mode is active, the global `store` variable is nil. The sync command should either:\n1. Use daemon RPC when daemon is running, or\n2. Force direct mode for sync operations\n\n**Workaround:**\nUse `--no-daemon` flag: `bd sync --no-daemon`","status":"closed","priority":0,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.553058-07:00","closed_at":"2025-10-22T00:09:12.615536-07:00"}
|
||||
{"id":"bd-20","title":"Add --id flag to bd list for filtering by specific issue IDs","description":"","design":"Add --id flag accepting comma-separated IDs. Usage: bd list --id wy-11,wy-12. Combines with other filters. From filter-flag-design.md.","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.553272-07:00"}
|
||||
{"id":"bd-21","title":"Make merge command idempotent for safe retry after partial failures","description":"The merge command currently performs 3 operations without an outer transaction:\n1. Migrate dependencies from source → target\n2. Update text references across all issues\n3. Close source issues\n\nIf merge fails mid-operation (network issue, daemon crash, etc.), a retry will fail or produce incorrect results because some operations already succeeded.\n\n**Goal:** Make merge idempotent so retrying after partial failure is safe and completes the remaining work.\n\n**Idempotency checks needed:**\n- Skip dependency migration if target already has the dependency\n- Skip text reference updates if already updated\n- Skip closing source issues if already closed\n- Report which operations were skipped vs performed\n\n**Example output:**\n```\n✓ Merged 2 issue(s) into bd-128\n - Dependencies: 3 migrated, 2 already existed\n - Text references: 5 updated, 0 already correct\n - Source issues: 1 closed, 1 already closed\n```\n\n**Related:** bd-18 originally requested transaction support, but idempotency is a better solution for this use case since individual operations are already atomic.","design":"Current merge code already has some idempotency:\n- Dependency migration checks `alreadyExists` before adding (line ~145-151 in merge.go)\n- Text reference updates are naturally idempotent (replacing bd-X with bd-Y twice has same result)\n\nMissing idempotency:\n- CloseIssue fails if source already closed\n- Error messages don't distinguish \"already done\" from \"real failure\"\n\nImplementation:\n1. Check source issue status before closing - skip if already closed\n2. Track which operations succeeded/skipped\n3. Return detailed results for user visibility\n4. Consider adding --dry-run output showing what would be done vs skipped","status":"open","priority":2,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.553518-07:00"}
|
||||
{"id":"bd-22","title":"Global daemon should warn/reject --auto-commit and --auto-push","description":"When user runs 'bd daemon --global --auto-commit', it's unclear which repo the daemon will commit to (especially after fixing bd-127 where global daemon won't open a DB).\n\nOptions:\n1. Warn and ignore the flags in global mode\n2. Error out with clear message\n\nLine 87-91 already checks autoPush, but should skip check entirely for global mode. Add user-friendly messaging about flag incompatibility.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.553769-07:00","closed_at":"2025-10-17T23:04:30.223432-07:00"}
|
||||
{"id":"bd-23","title":"Improve error handling in dependency removal during remapping","description":"In updateDependencyReferences(), RemoveDependency errors are caught and ignored with continue (line 392). Comment says 'if dependency doesn't exist' but this catches ALL errors including real failures. Should check error type with errors.Is(err, ErrDependencyNotFound) and only ignore not-found errors, returning other errors properly.","status":"closed","priority":3,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.553988-07:00","closed_at":"2025-10-18T09:41:18.209717-07:00"}
|
||||
{"id":"bd-24","title":"Optimize export dependency queries (N+1 problem)","description":"Export triggers separate GetDependencyRecords() per issue. For large DBs (1000+ issues), this is N+1 queries. Add GetAllDependencyRecords() to fetch all dependencies in one query. Location: cmd/bd/export.go:52-59, import.go:138-142","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.554187-07:00","closed_at":"2025-10-14T02:51:52.19905-07:00"}
|
||||
{"id":"bd-25","title":"Add workspace config file for multi-repo management (optional enhancement)","description":"For users who want explicit control over multi-repo setup without daemon, add optional workspace config file.\n\nConfig file: ~/.beads/workspaces.toml\n\nExample:\n[workspaces]\ncurrent = \"global\"\n\n[workspace.global]\ndb = \"~/.beads/global.db\"\ndescription = \"System-wide tasks\"\n\n[workspace.project1] \ndb = \"~/src/project1/.beads/db.sqlite\"\ndescription = \"Main product\"\n\n[workspace.project2]\ndb = \"~/src/project2/.beads/db.sqlite\"\ndescription = \"Internal tools\"\n\nCommands:\nbd workspace list # Show all workspaces\nbd workspace add NAME PATH # Add workspace\nbd workspace remove NAME # Remove workspace \nbd workspace use NAME # Switch active workspace\nbd workspace current # Show current workspace\nbd --workspace NAME \u003ccommand\u003e # Override for single command\n\nImplementation:\n- Load config in PersistentPreRun\n- Override dbPath based on current workspace\n- Store workspace state in config file\n- Support both workspace config AND auto-discovery\n- Workspace config takes precedence over auto-discovery\n\nPriority rationale:\n- Priority 3 (low) because daemon approach already solves this\n- Only implement if users request explicit workspace management\n- Adds complexity vs daemon's automatic discovery\n\nAlternative: Users can use BEADS_DB env var for manual workspace switching today.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.554385-07:00","closed_at":"2025-10-20T16:04:27.216482-07:00"}
|
||||
{"id":"bd-26","title":"Use safer placeholder pattern in replaceIDReferences","description":"Currently uses bd-313 which could theoretically collide with user text. Use a truly unique placeholder like null bytes: \\x00REMAP\\x00_0_\\x00 which are unlikely to appear in normal text. Located in collision.go:324. Very low probability issue but worth fixing for completeness.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.554639-07:00","closed_at":"2025-10-18T09:43:18.250156-07:00"}
|
||||
{"id":"bd-27","title":"Implement full cross-type cycle prevention in AddDependency","description":"Expand cycle prevention in AddDependency to check for cycles across ALL dependency types, not just 'blocks'. Currently only 'blocks' type dependencies are checked for cycles, allowing cross-type circular dependencies to form (e.g., A blocks B, B parent-child A). This can cause semantic confusion and is a maintenance hazard for future operations that traverse dependencies.","design":"Implementation approach:\n1. Modify the cycle check in AddDependency (postgres.go:559-599)\n2. Remove the 'type = blocks' filter from the recursive CTE\n3. Check for cycles regardless of dependency type being added\n4. Return a clear error message indicating which types form the cycle\n\nTrade-offs to consider:\n- This is more mathematically correct (no cycles in dependency DAG)\n- May break legitimate use cases where cross-type cycles are intentional\n- Need to evaluate whether ANY cross-type cycles are valid in practice\n- Alternative: make this configurable with a --allow-cycle flag\n\nBefore implementing, should investigate:\n- Are there legitimate reasons for cross-type cycles?\n- What's the performance impact on large graphs (1000+ issues)?\n- Should certain type combinations be allowed to cycle?","acceptance_criteria":"- AddDependency prevents cycles across all dependency types, not just 'blocks'\n- Clear error message when cycle would be created, including dependency types\n- All existing tests pass\n- Performance benchmarked on large dependency graphs (100+ issues)\n- Decision documented on whether to add --allow-cycle flag or exception rules","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.554853-07:00","closed_at":"2025-10-16T20:31:19.174534-07:00"}
|
||||
{"id":"bd-28","title":"Refactor duplicate flush logic in PersistentPostRun","description":"PersistentPostRun contains a complete copy of the flush logic instead of calling flushToJSONL(). This violates DRY principle and makes maintenance harder. Refactor to use flushToJSONL() with a force parameter to bypass isDirty check, or extract shared logic into a helper function. Located in cmd/bd/main.go:104-138.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.555457-07:00","closed_at":"2025-10-18T09:44:24.167574-07:00"}
|
||||
{"id":"bd-29","title":"Optimize auto-flush to use incremental updates","description":"Every flush exports ALL issues and ALL dependencies, even if only one issue changed. For large projects (1000+ issues), this could be expensive. Current approach guarantees consistency, which is fine for MVP, but future optimization could track which issues changed and use incremental updates. Located in cmd/bd/main.go:255-276.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.555744-07:00","closed_at":"2025-10-14T02:51:52.200141-07:00"}
|
||||
{"id":"bd-3","title":"Implement text reference scanning and replacement","description":"Scan all issues for text references to merged IDs (bd-X patterns) and update to target ID. Reuse logic from import collision resolution.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.555947-07:00"}
|
||||
{"id":"bd-30","title":"Make auto-flush debounce duration configurable","description":"flushDebounce is hardcoded to 5 seconds. Make it configurable via environment variable BEADS_FLUSH_DEBOUNCE (e.g., '500ms', '10s'). Current 5-second value is reasonable for interactive use, but CI/automated scenarios might want faster flush. Add getDebounceDuration() helper function. Located in cmd/bd/main.go:31.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.55614-07:00","closed_at":"2025-10-18T09:47:43.22126-07:00"}
|
||||
{"id":"bd-31","title":"Document label best practices and use cases","description":"Create documentation covering:\n- When to use labels vs structured fields\n- Common label sets (coding agents, open source, product dev, SRE)\n- Naming conventions (kebab-case, specificity, present tense)\n- Anti-patterns (too many labels, overlapping, personal labels)\n- Label lifecycle management\n\nContent from LABELS.md analysis document.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.556343-07:00","closed_at":"2025-10-19T23:11:46.125417-07:00"}
|
||||
{"id":"bd-32","title":"Add rule-based compaction (e.g., compact children of closed epics)","description":"Support semantic compaction rules beyond just time-based, such as:\n- Compact all children of closed epics\n- Compact by priority level (e.g., all P3/P4 closed issues)\n- Compact by label (e.g., all issues labeled 'archive')\n- Compact by type (e.g., all closed chores)\n\nThis would allow smarter database size management based on semantic meaning rather than just age.","status":"open","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.556539-07:00"}
|
||||
{"id":"bd-33","title":"Add compact --dry-run that shows size savings estimates","description":"When running 'bd compact --dry-run', show estimated database size reduction in KB/MB and percentage, similar to what 'du -h' would show.\n\nExample output:\n Tier 1 candidates: 15 issues\n Current size: 2.4 MB\n After compaction: ~1.7 MB (70% reduction, 0.7 MB saved)\n \nThis helps users understand impact before compacting.","status":"open","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.556779-07:00"}
|
||||
{"id":"bd-34","title":"Add EXPLAIN QUERY PLAN tests for ready work query","description":"Verify that the hierarchical blocking query uses proper indexes and doesn't do full table scans.\n\n**Queries to analyze:**\n1. The recursive CTE (both base case and recursive case)\n2. The final SELECT with NOT EXISTS\n3. Impact of various filters (status, priority, assignee)\n\n**Implementation:**\nAdd test function that:\n- Runs EXPLAIN QUERY PLAN on GetReadyWork query\n- Parses output to verify no SCAN TABLE operations\n- Documents expected query plan in comments\n- Fails if query plan degrades\n\n**Benefits:**\n- Catch performance regressions in tests\n- Document expected query behavior\n- Ensure indexes are being used\n\nRelated to: bd-87 (composite index on depends_on_id, type)","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.557043-07:00","closed_at":"2025-10-18T12:47:44.284846-07:00"}
|
||||
{"id":"bd-35","title":"Add performance benchmarks document","description":"Document actual performance metrics with hyperfine tests","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.5573-07:00","closed_at":"2025-10-18T10:09:23.532938-07:00"}
|
||||
{"id":"bd-36","title":"Investigate vector/semantic search for issue discovery","description":"From GH issue #2 RFC discussion: Evaluate if vector/semantic search over issues would provide value for beads.\n\n**Use case:** Find semantically related issues (e.g., 'login broken' finds 'authentication failure', 'session expired').\n\n**Questions to answer:**\n1. What workflows would this enable that we can't do now?\n2. Is dataset size (typically 50-200 issues) large enough to benefit?\n3. Do structured features (deps, tags, types) already provide better relationships?\n4. What's the maintenance cost (embeddings, storage, recomputation)?\n\n**Alternatives to consider:**\n- Improve 'bd list' filtering with regex/boolean queries\n- Add 'bd related \u003cid\u003e' showing deps + mentions + same tags\n- Export to JSON and pipe to external AI tools\n\n**Decision:** Only implement if clear use case emerges. Don't add complexity for theoretical benefits.\n\n**Context:** Part of evaluating Turso RFC ideas (GH #2). Vector search was proposed but unclear if needed for typical beads usage.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.557494-07:00","closed_at":"2025-10-18T10:09:23.532858-07:00"}
|
||||
{"id":"bd-37","title":"Add visual indicators for nodes with multiple parents in dep tree","description":"When a node appears in the dependency tree via multiple paths (diamond dependencies), add a visual indicator like (*) or (multiple parents) to help users understand the graph structure. This would make it clear when deduplication has occurred. Example: 'bd-503: Shared dependency (*) [P1] (open)'","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.55769-07:00","closed_at":"2025-10-20T14:34:52.483358-07:00"}
|
||||
{"id":"bd-38","title":"Add --show-all-paths flag to bd dep tree","description":"Currently bd dep tree deduplicates nodes when multiple paths exist (diamond dependencies). Add optional --show-all-paths flag to display the full graph with all paths, showing duplicates. Useful for debugging complex dependency structures and understanding all relationships.","status":"closed","priority":3,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.557878-07:00","closed_at":"2025-10-18T10:11:38.985862-07:00"}
|
||||
{"id":"bd-39","title":"Refactor parseMarkdownFile to reduce cyclomatic complexity","description":"The parseMarkdownFile function in cmd/bd/markdown.go has a cyclomatic complexity of 38, which exceeds the recommended threshold of 30. This makes the function harder to understand, test, and maintain.","design":"Split the function into smaller, focused units:\n\n1. parseMarkdownFile(filepath) - Main entry point, handles file I/O\n2. parseMarkdownContent(scanner) - Core parsing logic\n3. processIssueSection(issue, section, content) - Handle section finalization (current switch statement)\n4. parseLabels(content) []string - Extract labels from content\n5. parseDependencies(content) []string - Extract dependencies from content\n6. parsePriority(content) int - Parse and validate priority\n\nBenefits:\n- Each function has a single responsibility\n- Easier to test individual components\n- Lower cognitive load when reading code\n- Better encapsulation of parsing logic","acceptance_criteria":"- parseMarkdownFile complexity \u003c 15\n- New helper functions each have complexity \u003c 10\n- All existing tests still pass\n- No change in functionality or behavior\n- Code coverage maintained or improved","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.558094-07:00","closed_at":"2025-10-14T14:37:17.463352-07:00"}
|
||||
{"id":"bd-4","title":"Add CLI merge command and flags","description":"Implement bd merge command with: multiple sources, --into target, --dry-run, --json flags. Add interactive confirmation.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.558316-07:00"}
|
||||
{"id":"bd-40","title":"Simplify getNextID SQL query parameters","description":"Query passes prefix four times to same SQL query. Works but fragile if query changes. Consider simplifying SQL to require fewer parameters. Location: internal/storage/sqlite/sqlite.go:73-78","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.558519-07:00","closed_at":"2025-10-16T10:07:34.038708-07:00"}
|
||||
{"id":"bd-41","title":"Add validation/warning for malformed issue IDs","description":"getNextID silently ignores non-numeric ID suffixes (e.g., bd-foo). CAST returns NULL for invalid strings. Consider detecting and warning about malformed IDs in database. Location: internal/storage/sqlite/sqlite.go:79-82","status":"closed","priority":3,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.558766-07:00","closed_at":"2025-10-14T02:51:52.198988-07:00"}
|
||||
{"id":"bd-42","title":"Add transaction support to storage layer for atomic multi-operation workflows","description":"Currently each storage method (CreateIssue, UpdateIssue, etc.) starts its own transaction. This makes it impossible to perform atomic multi-step operations like collision resolution. Add support for passing *sql.Tx through the storage interface, or create transaction-aware versions of methods. This would make remapCollisions and other batch operations truly atomic.","status":"closed","priority":4,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.559031-07:00","closed_at":"2025-10-14T02:51:52.199176-07:00"}
|
||||
{"id":"bd-43","title":"Make maxDepth configurable in bd dep tree command","description":"Currently maxDepth is hardcoded to 50 in GetDependencyTree. Add --max-depth flag to bd dep tree command to allow users to control recursion depth. Default should remain 50 for safety, but users with very deep trees or wanting shallow views should be able to configure it.","status":"closed","priority":4,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.559227-07:00","closed_at":"2025-10-19T08:59:59.596748-07:00"}
|
||||
{"id":"bd-44","title":"Add cross-repo issue references (future enhancement)","description":"Support referencing issues across different beads repositories. Useful for tracking dependencies between separate projects.\n\nProposed syntax:\n- Local reference: bd-128 (current behavior)\n- Cross-repo by path: ~/src/other-project#bd-456\n- Cross-repo by workspace name: @project2:bd-789\n\nUse cases:\n1. Frontend project depends on backend API issue\n2. Shared library changes blocking multiple projects\n3. System administrator tracking work across machines\n4. Monorepo with separate beads databases per component\n\nImplementation challenges:\n- Storage layer needs to query external databases\n- Dependency resolution across repos\n- What if external repo not available?\n- How to handle in JSONL export/import?\n- Security: should repos be able to read others?\n\nDesign questions to resolve first:\n1. Read-only references vs full cross-repo dependencies?\n2. How to handle repo renames/moves?\n3. Absolute paths vs workspace names vs git remotes?\n4. Should bd-183 auto-discover related repos?\n\nRecommendation: \n- Gather user feedback first\n- Start with read-only references\n- Implement as plugin/extension?\n\nContext: This is mentioned in bd-183 as approach #2. Much more complex than daemon multi-repo approach. Only implement if there's strong user demand.\n\nPriority: Backlog (4) - wait for user feedback before designing","status":"closed","priority":4,"issue_type":"feature","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.559438-07:00","closed_at":"2025-10-20T22:00:31.966891-07:00"}
|
||||
{"id":"bd-45","title":"Test auto-export timing","description":"","status":"closed","priority":4,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.559665-07:00","closed_at":"2025-10-20T22:00:31.964329-07:00"}
|
||||
{"id":"bd-46","title":"Test real auto-export","description":"","status":"closed","priority":4,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.559866-07:00","closed_at":"2025-10-20T22:00:31.967571-07:00"}
|
||||
{"id":"bd-47","title":"Remove unused issueMap in scoreCollisions","description":"scoreCollisions() creates issueMap and populates it (lines 135-138) but never uses it. Either remove it or add a TODO comment explaining future use. Located in collision.go:135-138. Cosmetic cleanup.","status":"closed","priority":4,"issue_type":"chore","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.560111-07:00","closed_at":"2025-10-19T19:27:34.230312-07:00"}
|
||||
{"id":"bd-48","title":"Add godoc comments for auto-flush functions","description":"Add comprehensive godoc comments for findJSONLPath(), markDirtyAndScheduleFlush(), and flushToJSONL() explaining behavior, concurrency considerations, and error handling. Include notes about debouncing behavior (timer resets on each write, flush occurs 5s after LAST operation) and flush-on-exit guarantees. Located in cmd/bd/main.go:188-307.","status":"closed","priority":4,"issue_type":"chore","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.560786-07:00","closed_at":"2025-10-19T19:22:19.172983-07:00"}
|
||||
{"id":"bd-49","title":"Issue counter gets out of sync with actual issues","description":"The issue counter in issue_counters table frequently desyncs from actual max issue ID, causing:\n- Import from JSONL leaves counter at old high value\n- Test pollution increments counter but cleanup doesn't decrement it\n- Delete issues doesn't update counter\n- Only fix is 'rm -rf .beads' which is destructive\n\nExamples from today's session:\n- Had 48 issues but counter at 7714 after test pollution\n- Import from git didn't reset counter\n- Next new issue would be bd-7715 instead of bd-49\n\nProposed fixes:\n1. Auto-recalculate counter from max(issue_id) on import\n2. Add 'bd fix-counter' command\n3. Make counter lazy (always compute from DB, don't store)\n4. Import should reset counter to match imported data\n\nRelated: bd-1 (test isolation), bd-50 (init timestamp bug)","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.561021-07:00","closed_at":"2025-10-21T23:13:04.249149-07:00"}
|
||||
{"id":"bd-5","title":"Add transaction support for atomic merges","description":"Wrap all merge operations in SQLite transaction for atomicity. Implement rollback on failure.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.561241-07:00"}
|
||||
{"id":"bd-50","title":"Counter not synced after import on existing DB with populated issue_counters table","description":"The counter sync fix in counter_sync_test.go only syncs during initial migration when issue_counters table is empty (migrateIssueCountersTable checks count==0). For existing databases with stale counters:\n\n- Import doesn't resync the counter\n- Delete doesn't update counter \n- Renumber doesn't fix counter\n- Counter remains stuck at old high value\n\nExample from today:\n- Had 49 issues after clean import\n- Counter stuck at 4106 from previous test pollution\n- Next issue would be bd-4107 instead of bd-50\n- Even after renumber, counter stayed at 4106\n\nRoot cause: Migration only syncs if table is empty (line 182 in sqlite.go). Once populated, never resyncs.\n\nFix needed: \n1. Sync counter after import operations (not just empty table)\n2. Add counter resync after renumber\n3. Daemon caches counter value - needs to reload after external changes\n\nRelated: bd-49 (original counter sync fix), bd-10 (daemon cache staleness)","notes":"## Investigation Results\n\nAfter thorough code review, all the fixes mentioned in the issue description have ALREADY been implemented:\n\n### ✅ Fixes Already in Place:\n\n1. **Import DOES resync counters**\n - `cmd/bd/import_shared.go:253` calls `SyncAllCounters()` after batch import\n - Verified with new test `TestCounterSyncAfterImport`\n\n2. **Delete DOES update counters**\n - `internal/storage/sqlite/sqlite.go:1424` calls `SyncAllCounters()` after deletion\n - Both single delete and batch delete sync properly\n - Verified with existing tests: `TestCounterSyncAfterDelete`, `TestCounterSyncAfterBatchDelete`\n\n3. **Renumber DOES fix counters**\n - `cmd/bd/renumber.go:298-304` calls `ResetCounter()` then `SyncAllCounters()`\n - Forces counter to actual max ID (not just MAX with stale value)\n\n4. **Daemon cache DOES detect external changes**\n - `internal/rpc/server.go:1466-1487` checks file mtime and evicts stale cache\n - When DB file changes externally, cached storage is evicted and reopened\n\n### Tests Added:\n\n- `TestCounterSyncAfterImport`: Confirms import syncs counters from stale value (4106) to actual max (49)\n- `TestCounterNotSyncedWithoutExplicitSync`: Documents what would happen without the fix (bd-4107 instead of bd-50)\n\n### Conclusion:\n\nThe issue described in bd-50 has been **fully resolved**. All operations (import, delete, renumber) now properly sync counters. The daemon correctly detects external DB changes via file modification time.\n\nThe root cause (migration only syncing empty tables) was fixed by adding explicit `SyncAllCounters()` calls after import, delete, and renumber operations.","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:54:57.367425-07:00","updated_at":"2025-10-22T00:43:42.561442-07:00","closed_at":"2025-10-22T00:03:46.697918-07:00"}
|
||||
{"id":"bd-51","title":"Auto-flush writes test pollution and session work to git-tracked issues.jsonl","description":"Auto-flush exports ALL issues from DB to issues.jsonl every 5 seconds, including:\n- Test issues (bd-4053 through bd-4059 were version test junk)\n- Issues created during debugging sessions\n- Test pollution from stress tests\n- Temporary diagnostic issues\n\nThis pollutes the git-tracked issues.jsonl with garbage that shouldn't be committed.\n\nExample from today:\n- Git had 49 clean issues\n- Our DB grew to 100+ with test junk and session work\n- Auto-flush wrote all 100+ to issues.jsonl\n- Git status showed modified issues.jsonl with 50+ unwanted issues\n\nImpact:\n- Pollutes git history with test/debug garbage\n- Makes code review difficult (noise in diffs)\n- Can't distinguish real work from session artifacts\n- Other team members pull polluted issues\n\nSolutions to consider:\n1. Disable auto-flush by default (require explicit --enable-auto-flush)\n2. Add .beadsignore to exclude issue ID patterns\n3. Make auto-flush only export 'real' issues (exclude test-*)\n4. Require manual 'bd sync' for git commit\n5. Auto-flush to separate file (.beads/session.jsonl vs issues.jsonl)\n\nRelated: bd-49 (test pollution), isolation_test.go (test DB separation)","design":"## Analysis\n\nConfirmed the issue exists - bd-52 through bd-58 are test pollution in the git-tracked issues.jsonl.\n\n### Solution Evaluation:\n\n**Option 1: Disable auto-flush by default** ❌\n- Breaks the auto-sync workflow that users rely on\n- Requires manual intervention which defeats the purpose\n- Not recommended\n\n**Option 2: Add .beadsignore** ⚠️\n- Complex to implement (pattern matching, configuration)\n- Doesn't solve root cause: test issues in production DB\n- Better to prevent pollution at source\n\n**Option 3: Filter on export** ❌\n- Doesn't solve root cause\n- Test issues still pollute production DB\n- Complicates export logic\n\n**Option 4: Manual 'bd sync'** ❌\n- Same issues as Option 1\n- Breaks automated workflow\n\n**Option 5: Separate session file** ❌\n- Splits issue tracking across files\n- Confusing for users\n- Import/export complexity\n\n### RECOMMENDED SOLUTION:\n\n**Fix the root cause: Tests should NEVER touch the production database**\n\nThe real problem is that Go tests ARE properly isolated (they use temp DBs), but someone must be manually creating test issues in the production DB during development/debugging.\n\n**Best fix:**\n1. Document that production DB is for real work only\n2. Add a convenience command: `bd test-create` that uses a separate test database\n3. Clean up the existing test pollution: bd-52 through bd-58\n4. Consider adding a git pre-commit hook to warn about suspicious issues\n\nThis preserves auto-flush (which is valuable) while preventing pollution at the source.","notes":"## Resolution\n\n**Root Cause Identified:**\nThe issue was NOT a bug in auto-flush, but rather test pollution in the production database from manual testing/debugging. Go tests are properly isolated using temp directories.\n\n**Actions Taken:**\n1. Cleaned up test pollution: deleted bd-52 through bd-58 (all \"Version test issue\" entries)\n2. Verified auto-flush is working correctly - it exports the database as designed\n3. Confirmed Go test isolation works properly (uses temp dirs, not production DB)\n\n**Prevention Strategy:**\n- Production database (.beads/) should only contain real work issues\n- Manual testing should use throwaway databases or test scripts\n- Go tests already use isolated temp databases\n- Auto-flush is working as intended and should remain enabled\n\n**Conclusion:**\nThis was user error, not a system bug. The auto-flush mechanism is correct - it should export ALL database contents. The problem was polluting the production database with test issues in the first place.","status":"closed","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:54:57.369511-07:00","updated_at":"2025-10-22T00:43:42.568858-07:00","closed_at":"2025-10-22T00:05:29.864829-07:00"}
|
||||
{"id":"bd-59","title":"Auto-flush writes test pollution and session work to git-tracked issues.jsonl","description":"Auto-flush exports ALL issues from DB to issues.jsonl every 5 seconds, including:\n- Test issues (bd-4053 through bd-4059 were version test junk)\n- Issues created during debugging sessions\n- Test pollution from stress tests\n- Temporary diagnostic issues\n\nThis pollutes the git-tracked issues.jsonl with garbage that shouldn't be committed.\n\nExample from today:\n- Git had 49 clean issues\n- Our DB grew to 100+ with test junk and session work\n- Auto-flush wrote all 100+ to issues.jsonl\n- Git status showed modified issues.jsonl with 50+ unwanted issues\n\nImpact:\n- Pollutes git history with test/debug garbage\n- Makes code review difficult (noise in diffs)\n- Can't distinguish real work from session artifacts\n- Other team members pull polluted issues\n\nSolutions to consider:\n1. Disable auto-flush by default (require explicit --enable-auto-flush)\n2. Add .beadsignore to exclude issue ID patterns\n3. Make auto-flush only export 'real' issues (exclude test-*)\n4. Require manual 'bd sync' for git commit\n5. Auto-flush to separate file (.beads/session.jsonl vs issues.jsonl)\n\nRelated: bd-49 (test pollution), isolation_test.go (test DB separation)","status":"open","priority":1,"issue_type":"bug","created_at":"2025-10-22T00:05:10.788996-07:00","updated_at":"2025-10-22T00:43:42.569255-07:00"}
|
||||
{"id":"bd-6","title":"Implement dependency migration for merge","description":"Migrate all dependencies from source issue(s) to target issue during merge, removing duplicates and preserving graph integrity","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.569507-07:00"}
|
||||
{"id":"bd-60","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.400802-07:00","updated_at":"2025-10-22T00:43:42.569724-07:00"}
|
||||
{"id":"bd-61","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402704-07:00","updated_at":"2025-10-22T00:43:42.569959-07:00"}
|
||||
{"id":"bd-62","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402279-07:00","updated_at":"2025-10-22T00:43:42.570189-07:00"}
|
||||
{"id":"bd-63","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.404166-07:00","updated_at":"2025-10-22T00:43:42.570409-07:00"}
|
||||
{"id":"bd-64","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.403441-07:00","updated_at":"2025-10-22T00:43:42.570627-07:00"}
|
||||
{"id":"bd-65","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402415-07:00","updated_at":"2025-10-22T00:43:42.570832-07:00"}
|
||||
{"id":"bd-66","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.407606-07:00","updated_at":"2025-10-22T00:43:42.571033-07:00"}
|
||||
{"id":"bd-67","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.40764-07:00","updated_at":"2025-10-22T00:43:42.571245-07:00"}
|
||||
{"id":"bd-68","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.40883-07:00","updated_at":"2025-10-22T00:43:42.571472-07:00"}
|
||||
{"id":"bd-69","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.40767-07:00","updated_at":"2025-10-22T00:43:42.571678-07:00"}
|
||||
{"id":"bd-7","title":"Fix flaky CI tests in compactor and daemon modules","description":"Multiple test failures observed in CI:\n- TestCompactTier1_DryRun \n- TestCompactTier1Batch_DryRun\n- TestCompactTier1Batch_WithIneligible\n- TestMockAPI_CompactTier1\n- TestBatchOperations_ErrorHandling\n- TestCommentOperationsViaRPC\n- TestMemoryPressureDetection\n- TestPing\n\nAll failures related to 'issue has open dependents or not closed long enough' eligibility checks.\n\nSee CI run: https://github.com/steveyegge/beads/actions/runs/18688772658","status":"open","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.571877-07:00"}
|
||||
{"id":"bd-70","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.409931-07:00","updated_at":"2025-10-22T00:43:42.572094-07:00"}
|
||||
{"id":"bd-71","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.410401-07:00","updated_at":"2025-10-22T00:43:42.572284-07:00"}
|
||||
{"id":"bd-72","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.410855-07:00","updated_at":"2025-10-22T00:43:42.572471-07:00"}
|
||||
{"id":"bd-73","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.408355-07:00","updated_at":"2025-10-22T00:43:42.572658-07:00"}
|
||||
{"id":"bd-74","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.412011-07:00","updated_at":"2025-10-22T00:43:42.572861-07:00"}
|
||||
{"id":"bd-75","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.402341-07:00","updated_at":"2025-10-22T00:43:42.573061-07:00"}
|
||||
{"id":"bd-76","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.422106-07:00","updated_at":"2025-10-22T00:43:42.573256-07:00"}
|
||||
{"id":"bd-77","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.422587-07:00","updated_at":"2025-10-22T00:43:42.573654-07:00"}
|
||||
{"id":"bd-78","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.423021-07:00","updated_at":"2025-10-22T00:43:42.574025-07:00"}
|
||||
{"id":"bd-79","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.423454-07:00","updated_at":"2025-10-22T00:43:42.574233-07:00"}
|
||||
{"id":"bd-8","title":"Compact command fails with daemon - requires --no-daemon workaround","description":"The 'bd compact' command fails with 'Error: compact requires SQLite storage' when used with the daemon (default mode), but works correctly with the '--no-daemon' flag.\n\nThe daemon RPC interface doesn't properly expose the compact command, even though the daemon itself uses SQLite storage.\n\nReproduction:\n1. Ensure daemon is running (bd daemon status)\n2. Run: bd compact --stats\n Result: Error: compact requires SQLite storage\n3. Run: bd compact --stats --no-daemon\n Result: Works correctly, shows statistics\n\nExpected behavior:\nThe compact command should work through the daemon RPC interface just like other commands (list, create, update, delete, renumber, etc.)\n\nImpact:\nUsers cannot use compact operations in the normal workflow. They must use --no-daemon which bypasses the daemon entirely.\n\nSuggested fix:\nAdd compact operation support to the daemon RPC interface, similar to how renumber and other operations are exposed.","status":"in_progress","priority":1,"issue_type":"bug","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.574442-07:00"}
|
||||
{"id":"bd-80","title":"Issue 0","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.537799-07:00","updated_at":"2025-10-22T00:43:42.574667-07:00"}
|
||||
{"id":"bd-81","title":"Issue 1","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.539461-07:00","updated_at":"2025-10-22T00:43:42.574858-07:00"}
|
||||
{"id":"bd-82","title":"Issue 2","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.540087-07:00","updated_at":"2025-10-22T00:43:42.575056-07:00"}
|
||||
{"id":"bd-83","title":"Issue 3","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.540633-07:00","updated_at":"2025-10-22T00:43:42.575251-07:00"}
|
||||
{"id":"bd-84","title":"Issue 4","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.541173-07:00","updated_at":"2025-10-22T00:43:42.575483-07:00"}
|
||||
{"id":"bd-85","title":"Issue 5","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.541664-07:00","updated_at":"2025-10-22T00:43:42.575688-07:00"}
|
||||
{"id":"bd-86","title":"Issue 6","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.54216-07:00","updated_at":"2025-10-22T00:43:42.575894-07:00"}
|
||||
{"id":"bd-87","title":"Issue 7","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.54266-07:00","updated_at":"2025-10-22T00:43:42.576097-07:00"}
|
||||
{"id":"bd-88","title":"Issue 8","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.543237-07:00","updated_at":"2025-10-22T00:43:42.576304-07:00"}
|
||||
{"id":"bd-89","title":"Issue 9","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.543804-07:00","updated_at":"2025-10-22T00:43:42.57652-07:00"}
|
||||
{"id":"bd-9","title":"Investigate stress test database pollution (vc-248)","description":"Investigation of stress tests polluting production database with 1,600+ test issues on Oct 21 at 20:24-20:25. Root cause analysis completed. Tests now verified to work correctly with proper isolation.","notes":"Bug confirmed! Tests DO pollute production DB. 1,000 test issues created at 20:46:01-20:46:02 during TestStressNoUniqueConstraintViolations. Root cause: test goroutines connect to production daemon at .beads/bd.sock instead of test daemon.","status":"open","priority":1,"issue_type":"task","created_at":"2025-10-21T23:53:44.31362-07:00","updated_at":"2025-10-22T00:43:42.576763-07:00"}
|
||||
{"id":"bd-90","title":"Issue 10","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.544303-07:00","updated_at":"2025-10-22T00:43:42.576994-07:00"}
|
||||
{"id":"bd-91","title":"Issue 11","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.544799-07:00","updated_at":"2025-10-22T00:43:42.5772-07:00"}
|
||||
{"id":"bd-92","title":"Issue 12","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.545268-07:00","updated_at":"2025-10-22T00:43:42.577402-07:00"}
|
||||
{"id":"bd-93","title":"Issue 13","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.545734-07:00","updated_at":"2025-10-22T00:43:42.577614-07:00"}
|
||||
{"id":"bd-94","title":"Issue 14","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.546157-07:00","updated_at":"2025-10-22T00:43:42.577831-07:00"}
|
||||
{"id":"bd-95","title":"Issue 15","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.546559-07:00","updated_at":"2025-10-22T00:43:42.578041-07:00"}
|
||||
{"id":"bd-96","title":"Issue 16","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.546964-07:00","updated_at":"2025-10-22T00:43:42.578246-07:00"}
|
||||
{"id":"bd-97","title":"Issue 17","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.547368-07:00","updated_at":"2025-10-22T00:43:42.578484-07:00"}
|
||||
{"id":"bd-98","title":"Issue 18","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.547759-07:00","updated_at":"2025-10-22T00:43:42.578681-07:00"}
|
||||
{"id":"bd-99","title":"Issue 19","description":"","status":"open","priority":2,"issue_type":"task","created_at":"2025-10-22T00:12:34.548153-07:00","updated_at":"2025-10-22T00:43:42.578895-07:00"}
|
||||
|
||||
Reference in New Issue
Block a user