From 33064e02bddfb82e4a33f8d2489daabf66465858 Mon Sep 17 00:00:00 2001 From: Steve Yegge Date: Tue, 23 Dec 2025 20:32:47 -0800 Subject: [PATCH] bd sync: 2025-12-23 20:32:47 --- .beads/issues.jsonl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.beads/issues.jsonl b/.beads/issues.jsonl index 537d6bc7..07b1b8c3 100644 --- a/.beads/issues.jsonl +++ b/.beads/issues.jsonl @@ -263,7 +263,7 @@ {"id":"bd-ifuw","title":"test hook pin fix","status":"tombstone","priority":2,"issue_type":"task","assignee":"dave","created_at":"2025-12-23T04:43:15.598698-08:00","updated_at":"2025-12-23T04:51:29.438139-08:00","deleted_at":"2025-12-23T04:51:29.438139-08:00","deleted_by":"daemon","delete_reason":"delete","original_type":"task"} {"id":"bd-iic1","title":"Phase 2.2: Switch bdt storage to TOON format","description":"Currently bdt stores issues in JSONL format in issues.toon file. Phase 2.2 must implement actual TOON format storage - this is the fundamental goal of the bdtoon project.\n\n## Current State (Phase 2.1)\n- issues.toon stores JSONL (intermediate format)\n- --toon flag allows output in TOON format for LLM consumption\n- Problem: We're not actually using TOON as the fundamental storage format\n\n## Required Work (Phase 2.2)\n1. Switch issue file I/O to write TOON format instead of JSONL\n - Update cmd/bdt/storage.go to use EncodeTOON for writing\n - Update cmd/bdt/storage.go to decode TOON (currently decodes JSON)\n - Ensure round-trip: write TOON → read TOON → write TOON is byte-identical\n\n2. Update command implementations\n - cmd/bdt/create.go: Write newly created issues to TOON format\n - cmd/bdt/list.go: Read issues from TOON format\n - cmd/bdt/show.go: Read from TOON format\n - cmd/bdt/import.go: Convert imported JSONL to TOON\n - cmd/bdt/export.go: Export TOON to JSONL (for bd compatibility)\n\n3. Implement TOON parser that handles gotoon's encoder-only limitation\n - Since gotoon doesn't decode TOON, need custom TOON→JSON decoder\n - OR continue storing TOON but decoding via intermediate JSON conversion\n\n4. Git merge driver optimization\n - TOON is line-oriented, better for 3-way merges than binary formats\n - Configure git merge driver for .toon files\n\n5. Comprehensive testing\n - Round-trip tests: Issue → TOON → storage → read → Issue\n - Merge conflict resolution tests with TOON format\n - Large issue set performance tests\n\n## Success Criteria\n- issues.toon stores actual TOON format (not JSONL)\n- bdt list reads from TOON file\n- bdt create writes to TOON file\n- Round-trip: create issue → list → show returns identical data\n- All 65+ tests still passing\n- Performance comparable to JSONL storage","status":"closed","priority":1,"issue_type":"task","created_at":"2025-12-19T14:05:41.394964404-07:00","updated_at":"2025-12-19T14:37:17.879612634-07:00","closed_at":"2025-12-19T14:37:17.879612634-07:00"} {"id":"bd-in7","title":"Test message","description":"Hello world","status":"closed","priority":2,"issue_type":"message","created_at":"2025-12-17T23:16:13.184946-08:00","updated_at":"2025-12-18T17:42:26.000073-08:00","closed_at":"2025-12-17T23:37:38.563369-08:00"} -{"id":"bd-indn","title":"bd template commands fail with daemon mode","description":"The `bd template show` and `bd template instantiate` commands fail with 'Error loading template: no database connection' when daemon is running.\n\n**Reproduction:**\n```bash\nbd daemon --start\nbd template show bd-qqc # Error: no database connection\nbd template show bd-qqc --no-daemon # Works\n```\n\n**Expected:** Template commands should work with daemon like other commands.\n\n**Workaround:** Use `--no-daemon` flag.\n\n**Location:** Likely in cmd/bd/template.go - daemon RPC path not implemented for template operations.","status":"open","priority":2,"issue_type":"bug","created_at":"2025-12-18T22:57:35.16596-08:00","updated_at":"2025-12-18T22:57:35.16596-08:00"} +{"id":"bd-indn","title":"bd template commands fail with daemon mode","description":"The `bd template show` and `bd template instantiate` commands fail with 'Error loading template: no database connection' when daemon is running.\n\n**Reproduction:**\n```bash\nbd daemon --start\nbd template show bd-qqc # Error: no database connection\nbd template show bd-qqc --no-daemon # Works\n```\n\n**Expected:** Template commands should work with daemon like other commands.\n\n**Workaround:** Use `--no-daemon` flag.\n\n**Location:** Likely in cmd/bd/template.go - daemon RPC path not implemented for template operations.","status":"in_progress","priority":2,"issue_type":"bug","assignee":"beads/rictus","created_at":"2025-12-18T22:57:35.16596-08:00","updated_at":"2025-12-23T20:32:46.91642-08:00"} {"id":"bd-io8c","title":"Improve test coverage for internal/syncbranch (33.0% → 70%)","description":"Improve test coverage for internal/syncbranch package from 27% to 70%.\n\n## Current State\n- Coverage: 27.0%\n- Files: syncbranch.go, worktree.go\n- Tests: syncbranch_test.go (basic tests exist)\n\n## Functions Needing Tests\n\n### syncbranch.go (config management)\n- [x] ValidateBranchName - has tests\n- [ ] Get - needs store mock tests\n- [ ] GetFromYAML - needs YAML parsing tests\n- [ ] IsConfigured - needs file system tests\n- [ ] IsConfiguredWithDB - needs DB path tests\n- [ ] Set - needs store mock tests\n- [ ] Unset - needs store mock tests\n\n### worktree.go (git operations) - PRIORITY\n- [ ] CommitToSyncBranch - needs git repo fixture tests\n- [ ] PullFromSyncBranch - needs merge scenario tests\n- [ ] CheckDivergence - needs ahead/behind tests\n- [ ] ResetToRemote - needs reset scenario tests\n- [ ] performContentMerge - needs 3-way merge tests\n- [ ] extractJSONLFromCommit - needs git show tests\n- [ ] hasChangesInWorktree - needs dirty state tests\n- [ ] commitInWorktree - needs commit scenario tests\n\n## Implementation Guide\n\n1. **Use testutil fixtures:**\n ```go\n import \"github.com/steveyegge/beads/internal/testutil/fixtures\"\n \n func TestCommitToSyncBranch(t *testing.T) {\n repo := fixtures.NewGitRepo(t)\n defer repo.Cleanup()\n // ... test scenarios\n }\n ```\n\n2. **Test scenarios for worktree.go:**\n - Clean commit (no conflicts)\n - Non-fast-forward push (diverged)\n - Merge conflict resolution\n - Empty changes (nothing to commit)\n\n3. **Mock storage for syncbranch.go:**\n ```go\n store := memory.New()\n // Set up test config\n syncbranch.Set(ctx, store, \"beads-sync\")\n ```\n\n## Success Criteria\n- Coverage ≥ 70%\n- All public functions have at least one test\n- Edge cases covered for git operations\n- Tests pass with `go test -race ./internal/syncbranch`\n\n## Run Tests\n```bash\ngo test -v -cover ./internal/syncbranch\ngo test -race ./internal/syncbranch\n```","status":"closed","priority":1,"issue_type":"task","assignee":"beads/Syncer","created_at":"2025-12-13T20:43:02.079145-08:00","updated_at":"2025-12-23T13:46:10.191435-08:00","closed_at":"2025-12-23T13:46:10.191435-08:00","close_reason":"Improved coverage from 27% to 67% (close to 70% target)","dependencies":[{"issue_id":"bd-io8c","depends_on_id":"bd-iz5t","type":"parent-child","created_at":"2025-12-23T12:44:07.213092-08:00","created_by":"daemon"}]} {"id":"bd-ipj7","title":"enhance 'bd status' to show recent activity","description":"It would be nice to be able to quickly view the last N changes in the database, to see wha's recently been worked on. I'm imagining something like 'bd status activity'.","status":"closed","priority":3,"issue_type":"task","created_at":"2025-12-21T11:08:50.996541974-07:00","updated_at":"2025-12-21T17:54:00.279039-08:00","closed_at":"2025-12-21T17:54:00.279039-08:00","close_reason":"Already implemented - bd status includes Recent Activity section"} {"id":"bd-ipva","title":"Update go install bd to 0.33.2","description":"Rebuild and install bd to ~/go/bin:\n\n```bash\ngo install ./cmd/bd\n~/go/bin/bd version # Verify shows 0.33.2\n```\n\nNote: If ~/go/bin is in PATH before /opt/homebrew/bin, this is the version that runs by default.","status":"tombstone","priority":1,"issue_type":"task","created_at":"2025-12-21T16:10:13.760715-08:00","updated_at":"2025-12-21T17:29:31.791368-08:00","close_reason":"Local dev build used instead of go install","deleted_at":"2025-12-21T17:29:31.791368-08:00","deleted_by":"batch delete","delete_reason":"batch delete","original_type":"task","wisp":true}