Commit graph

140 commits

Author SHA1 Message Date
maphew
21c55f489f fix(create): handle dependency aliases in --deps
Carry forward the useful CLI dependency parsing fix from gastownhall/beads PR #3560 while excluding unrelated governance/template and Dolt subsystem changes.

blocked-by:<id> and depends-on:<id> now store a blocks dependency from the new issue to the target, while explicit blocks:<id> continues to invert direction so the target depends on the new issue.

Also reject unknown create --deps dependency types using the centralized well-known dependency type policy.

Co-authored-by: kev <kglynn@pryoninc.com>
2026-05-02 14:08:01 -07:00
coffeegoddd☕️✨
7e0d09cbf8 /{internal,cmd}: fix CommitPending 2026-05-01 11:15:02 -07:00
coffeegoddd☕️✨
73f2ab613b /{cmd,internal}: maybe fix tool tip closed store bug 2026-04-29 16:35:16 -07:00
matt wilkie
d8d298dc1e
refactor: extract create issue build and dry-run render helpers (bd-itp.4) (#3295) 2026-04-15 16:10:40 -07:00
matt wilkie
1ba4ff31b7
fix: write metadata.json in ensureBeadsDirForPath + contributor tests (#2988) (#2996)
Two fixes for the contributor mode "no database selected" bug:

1. store_factory.go: Default to "beads" when metadata.json is missing
   (same fix as the standalone PR for the unit-level regression).

2. create.go (ensureBeadsDirForPath): Write metadata.json after creating
   the target store so that newDoltStoreFromConfig can find the correct
   database name on subsequent opens. Also sanitize the prefix for SQL
   database names (hyphens → underscores), matching bd init behavior.

Adds embedded Dolt contributor mode tests that exercise the full
init --contributor → create → show flow, covering:
- Issue routing to planning repo (the #2988 regression scenario)
- Issue isolation (not in project store)
- bd show reads routed issues
- Multiple sequential creates

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 12:08:36 -07:00
Julian Knutsen
73409d51d4
feat: move hook firing into storage layer via decorator (#2891)
* feat: move hook firing into storage layer via decorator

Add HookFiringStore decorator that wraps DoltStorage and automatically
fires on_create/on_update/on_close hooks after successful mutations.
This replaces manual hookRunner.Run() calls scattered across 8+ CLI
command files, ensuring ALL mutations fire hooks — including future
commands that haven't been written yet.

Key features:
- Decorator pattern: storage layer stays clean (no hooks dependency)
- Transaction support: hookTrackingTransaction accumulates pending
  hooks during RunInTransaction, fires them only after successful
  commit. Rollback = no hooks.
- Covers all mutation methods: CreateIssue(s), UpdateIssue, CloseIssue,
  ReopenIssue, UpdateIssueType, Add/RemoveDependency, Add/RemoveLabel,
  AddIssueComment
- DeleteIssue intentionally skipped (destructive, no issue to pass)
- Nil runner safe (passthrough only, no panics)

Removed hookRunner.Run() from: create.go, update.go, close.go,
note.go, assign.go, tag.go, priority.go.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat: add BD_NO_HOOKS env var to disable all hook firing

Allows opting out of the HookFiringStore decorator entirely via
BD_NO_HOOKS=1. Useful for bulk imports, migrations, or environments
where eventing should not run.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 14:32:01 -07:00
matt wilkie
fe08e3074b fix(create): remove description warning and gate test-issue warning on DB size
- Remove the "Creating issue without description" warning that fires on
  the default happy path. Descriptions are optional; the quickstart guide
  tells users to run `bd create "My first issue"` without one. Teams that
  want mandatory descriptions can use create.require-description config.

- Only show "Creating test issue in production database" warning when the
  database already has ≥5 issues. A brand-new repo with zero issues is
  not a "production database" and the warning confuses new users.

Closes #2897
Closes #2898

Amp-Thread-ID: https://ampcode.com/threads/T-019d3afe-92cc-74bc-a917-f8e92e21060f
Co-authored-by: Amp <amp@ampcode.com>
2026-03-29 14:03:47 -07:00
coffeegoddd☕️✨
a35edfd28e /{internal,cmd,.goreleaser,.github}: embedded mode by default 2026-03-28 13:47:20 -07:00
beads/crew/emma
d7629204f9 refactor: remove multi-rig routing from beads
Remove the entire multi-rig routing engine (routes.go, route resolution,
prefix-based dispatch) and cross-rig commands (move, refile). All bd
commands now operate on the local rig only.

Deleted: internal/routing/routes.go, cmd/bd/move.go, cmd/bd/refile.go,
and 5 associated test files.

Simplified: routed.go, close.go, create.go, dep.go, gate.go, list.go,
ready.go, promote.go, show.go, show_display.go.

Retained: contributor routing (routing.go, routing_read.go) is unchanged.

Resolves: bd-8hc5

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-27 19:53:13 -07:00
Bella-Giraffety
199c55c5fa
Fix routed town-root drift in nested worktrees (#2816)
* fix: anchor routed town root to active beads dir (bd-e3q)

* fix: fail closed for authoritative routed contexts (bd-e3q)

---------

Co-authored-by: obsidian <thalia.geraghty@fiserv.com>
2026-03-27 15:32:05 -07:00
julianknutsen
05a967c0d7 refactor: move graph-apply to bd create --graph
Replace standalone `bd graph-apply` subcommand with `bd create --graph
<plan-file>` flag, consistent with the existing `bd create -f` (markdown)
pattern. The graph plan format and transactional execution are unchanged.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-27 12:32:10 -07:00
mrmaxsteel
541b68412c
feat: add remote URL support to multi-repo hydration (PR #2827)
* /{cmd,internal}: add remote URL support to multi-repo hydration

Multi-repo hydration (`bd repo sync`) reads issues.jsonl from local
filesystem paths, predating beads' dolt remote support. This adds
remote URL support so hydration, `--repo`, and `bd repo add` can
accept dolt remote URLs (dolthub://, https://, s3://, etc.) alongside
local paths.

New internal/remotecache package manages cached dolt clones at
~/.cache/beads/remotes/<hash>/ with clone/pull/push lifecycle and
file-based locking for concurrent access.

Closes #2826

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: address review issues in remote hydration PR

- Fix gosec G306: tighten meta file permissions from 0644 to 0600
- Make lock polling context-aware (respects Ctrl+C / ctx cancellation)
- Replace defer cache.Push with explicit call (FatalError calls os.Exit,
  which skips deferred functions — silent data loss on remote creates)
- Log remoteStore.Close() errors as warnings instead of discarding
- Quantify CacheKey birthday-bound collision risk in comment

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix(remotecache): address code review findings from #2827

- Fix lock file race: remove os.Remove in releaseLock to prevent TOCTOU
  race where another process's lock gets deleted; stale lock cleanup in
  acquireLock handles orphaned files
- Add debug.Logf to writeMeta for error visibility
- Rename cacheErr to idiomatic err in repo sync remote block
- Escalate remote push failure to FatalError in create (silent warning
  meant the remote never received the issue)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix(remotecache): defer store close, add Push test, add freshness TTL

- Replace defer-in-loop with eager close in repo sync (defer inside a
  for loop leaks connections until function return)
- Add FreshFor TTL to Cache (default 30s) — Ensure() skips pull when
  last pull is within the window, FreshFor=0 preserves always-pull
- Add TestPush: full round-trip integration test (clone → insert → push
  → re-clone → verify data)
- Add TestEnsureFreshFor: validates TTL skip and FreshFor=0 bypass
- Add concurrency doc comment to OpenStore

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 19:31:40 -07:00
Harry
a82d500129 cleanup: remove remaining Gas Town terminology from help text, docs, and comments
Replace Gas Town-specific terminology with generic equivalents across
user-facing help text, documentation, code comments, MCP integration,
and scripts.

Terminology replacements:
- polecat → agent/worker
- witness → observer
- deacon → patrol system
- refinery → processor
- mayor → coordinator
- crew → assistant
- gt (command) → bd
- Gas Town role lists → generic role descriptions

Changes by category:
- User-facing help text (7 files): create.go, state.go, mol_bond.go,
  gate.go, mol_ready_gated.go, memory.go, swarm.go
- Documentation (5 files): dolt-concurrency.md (reframed for standalone
  beads), MOLECULES.md, LABELS.md, CLI_REFERENCE.md,
  CONTRIBUTOR_NAMESPACE_ISOLATION.md
- Code comments (5 files): dolt.go, doctor/artifacts.go,
  fix/artifacts.go, store.go, queries.go, formula/types.go
- MCP integration (2 files): tools.py comments, test docstring
- Scripts (1 file): release.sh

Backwards compatibility: Doctor artifact detection patterns for
polecats/crew/refinery directories are retained with updated comments
noting they exist for orchestrator backwards compatibility. MCP redirect
test paths also retained for the same reason.

Fixes #2758

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-22 13:27:43 -07:00
garnet
3dae6bb3df refactor: remove gastown/Gas Town string references from beads code and docs (bd-1ue8)
Replace gastown-specific references with generic alternatives throughout
the codebase:

- Rename --gastown flag to --orchestrator in bd doctor
- Rename gastownMode/gastownThreshold params to orchestratorMode/orchestratorThreshold
- Rename isGasTownTownRoot() to isOrchestratorRoot()
- Replace "gastown" in CLI examples with generic rig names (my-project, other-project)
- Update comments replacing "Gas Town" with "orchestrator" or "multi-agent workspace"
- Update active docs (DOLT.md, CONFIG.md, ADVANCED.md, etc.)
- Update test data to use generic names instead of "gastown"
- Update role templates (deacon, witness, refinery) to use generic language

Preserved as historical (not changed):
- CHANGELOG.md entries (historical record)
- ARTICLES.md (links to real published articles)
- info.go version notes (historical release notes)
- gastown/ file path references in dolt-concurrency.md (point to actual repo)
2026-03-20 18:39:50 -07:00
quartz
0bd598ce53 refactor: remove agent-as-bead subsystem from beads (bd-4vw2)
Remove the entire agent-as-bead subsystem which treated agents as beads
with GT-specific state management. This is pure Gas Town infrastructure
that belongs in GT, not in the beads issue tracker.

Deleted files:
- cmd/bd/agent.go (state, heartbeat, show, backfill-labels commands)
- cmd/bd/slot.go (hook/role slot management)
- cmd/bd/merge_slot.go (merge queue slot primitives)
- All associated test files

Removed from types.Issue:
- AgentState, HookBead, RoleBead, LastActivity, RoleType, Rig, Holder
- AgentState type definition and constants

Removed from storage layer:
- 6 agent columns from DB schema (hook_bead, role_bead, agent_state,
  last_activity, role_type, rig)
- Agent field scanning, insertion, and update allowlisting

Cleaned up references in:
- show_format.go (agent identity and slot display sections)
- create.go (--agent-rig flag and agent label auto-add)
- move.go, refile.go (RoleType/Rig field copying)
- doctor/deep.go (agent bead integrity check)
- config.go (agent role configuration functions)
2026-03-20 18:38:54 -07:00
emma
63432acf64 fix: --validate checks --acceptance field, add validation.on-close config (PR #2654)
Three fixes for validation consistency:

1. bd create --validate now uses LintIssue() instead of ValidateTemplate(),
   bringing it to parity with bd lint. A non-empty --acceptance field now
   satisfies the "Acceptance Criteria" requirement without needing the
   heading in --description. (GH#2468 parity)

2. --dry-run no longer bypasses --validate. Validation now runs before the
   dry-run exit, so users get feedback on template issues during preview.

3. New validation.on-close config option (none|warn|error, default: none).
   When enabled, warns on terse close reasons (<20 chars) or default
   "Closed" reasons. Mirrors existing validation.on-create pattern.

Co-Authored-By: seanmartinsmith <114885497+seanmartinsmith@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 22:21:23 -07:00
coffeegoddd☕️✨
d6c54cb629 /{cmd,internal}: refactor again 2026-03-17 18:11:37 -07:00
coffeegoddd☕️✨
a693ac4559 /{cmd,internal}: pr feedback 2026-03-17 17:26:35 -07:00
coffeegoddd☕️✨
afb6e44283 /{cmd,internal}: add test and commit pending 2026-03-17 16:44:48 -07:00
coffeegoddd☕️✨
c36c5fcaca /{cmd,internal}: maybe create 2026-03-17 16:24:24 -07:00
coffeegoddd☕️✨
58915b13e7 /{cmd,internal}: update global store to be interface 2026-03-17 13:26:17 -07:00
beads/crew/emma
de5f0b986a Merge PR #2622: feat: add --no-history flag to separate Dolt commit skipping from GC eligibility
Separates two concerns bundled by --ephemeral: skipping Dolt commit
history and GC eligibility. NoHistory beads route to wisps table
(no DOLT_COMMIT) but remain non-GC-eligible. Fixes agent identity
beads being incorrectly garbage collected.

Also adds --exclude-type to wisp gc, --type filter to wisp list,
and fixes ExcludeTypes self-join subquery.

Closes #2619

PR: https://github.com/steveyegge/beads/pull/2622
Author: mmlac
2026-03-15 18:33:32 -07:00
mayor
869cc17fcd feat: add --no-history flag to bd create — skip Dolt commits without GC eligibility
Separates "no git history" from "garbage-collectible" for beads stored in the
wisps table. Previously --ephemeral bundled both behaviors, causing agent identity
beads to be incorrectly GC'd.

Changes:
- Add NoHistory field to types.Issue and wisps/issues schema (migration 011)
- Route NoHistory issues to wisps table, skip DOLT_COMMIT, but leave ephemeral=0
- Wire --no-history flag in bd create and bd update (with --history to undo)
- Add --exclude-type flag to bd mol wisp gc
- Add --type filter flag to bd mol wisp list
- Include type and labels in wisp list JSON output
- Move ephemeral/no-history mutual exclusion to validation layer
- Migrate issues between tables when --no-history/--ephemeral set on update
- Fix ExcludeTypes filter self-join subquery inefficiency
- Ensure JSONL export/import roundtrip preserves no_history
- Remove dead AllEphemeral function (superseded by AllWisps)
- Comprehensive test coverage for all new flags and edge cases

Resolves: steveyegge/beads#2619
Refs: steveyegge/gastown#2768

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-15 19:28:48 +00:00
Your Name
ecad137f51 feat: add --claim-next to close and --skills/--context to create 2026-03-15 01:28:54 +09:00
Matthew Endsley
71d7ae593b
feat: add --design-file flag for reading design from files
Adds support for reading design content from files or stdin, making it easier to manage longer design notes.

The new `--design-file` flag is mutually exclusive with the inline `--design` flag. Includes comprehensive tests for all code paths.
2026-03-11 12:25:23 -07:00
beads/crew/emma
8386380437 fix: YAML config prefix takes precedence over DB in shared-server mode (GH#2469)
In shared-server mode, the DB issue_prefix belongs to whichever project
initialized first. This caused all projects sharing a server to use the
wrong prefix for issue creation, ID generation, and imports.

Fix: YAML config.yaml issue-prefix now takes precedence over the DB value
in create.go, github.go, gitlab.go, linear.go, orphans.go, and merge_slot.go
(which already had the correct pattern).

Also: EnsureRunning() now calls KillStaleServers() before starting a new
server, cleaning up orphaned dolt sql-server processes that accumulate when
parent processes crash without graceful shutdown (GH#2372).

Also: add cross-project data isolation tests (5 tests covering read isolation,
port collision, same-prefix isolation, concurrent writes, and concurrent
read-write mix). Based on tests by @PabloLION (PR #2472).

Co-Authored-By: PabloLION <dev@pablolion.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 19:18:19 -07:00
beads/crew/emma
84494b7e1a cleanup: remove daemon infrastructure remnants (GH#2431)
Remove all BEADS_NO_DAEMON env var handling from test files (dead code
since daemon removal in v0.50.0), delete stopRepoDaemon() and daemon
file guards from test setup, remove no-daemon config key from tests,
and update daemon→server wording in docs and comments.

37 files changed, -193 lines net.

Co-Authored-By: davetashner <davetashner@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 15:24:27 -07:00
Osamu Okano
fc03c6be0b
fix(read): apply contributor routing to list and ready 2026-03-02 20:25:52 +09:00
Osamu Okano
f430b97059
fix(create): read contributor routing config from DB fallback 2026-03-02 20:22:32 +09:00
jade
2874b8160a fix: replace stale beads.db check with metadata.json in ensureBeadsDirForPath (bd-rev6)
ensureBeadsDirForPath checked for beads.db (SQLite artifact) to detect
existing databases. With Dolt, storage is under .beads/dolt/, so the
check always failed, causing unnecessary re-initialization attempts.

- Check for metadata.json instead of beads.db as the canonical marker
- Use dolt.NewFromConfigWithOptions instead of dolt.New with stale path

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/polecats/jade
Rig: beads
Role: polecats
2026-03-01 10:58:52 -08:00
garnet
9bf46a4ba6 fix: update stale JSONL and SQLite references to Dolt semantics (bd-cg90)
- create.go: replace BEADS_DB/.db recommendation with --db flag
- mol_bond.go: replace JSONL export references with dolt_ignore/Dolt sync
- mol_test.go: update wisp comment from SQLite/JSONL to dolt_ignore table
- dep_test.go: replace raw SQLite error references with raw database error
- hooks.go: update hook descriptions from generic sync to Dolt commit/sync

Executed-By: beads/polecats/garnet
Rig: beads
Role: polecats
2026-03-01 10:33:46 -08:00
Aaron Lippold
63418ae549 fix: guard CREATE DATABASE to prevent shadow databases on wrong server
bd unconditionally ran CREATE DATABASE IF NOT EXISTS on every connection.
When connecting to the wrong server (auto-started from .beads/dolt/ or
Homebrew default), this created an empty shadow database hiding real data.

Changes:
- Add CreateIfMissing field to Config — only bd init sets it true
- SHOW DATABASES LIKE check before CREATE (with underscore escaping)
- Network error handling for SHOW DATABASES failure
- Suppress auto-start when metadata.json has explicit dolt_server_port
- Fix backup git push across .beads/redirect (findGitRoot)
- Fix macOS CanonicalizePath case resolution (walk dirs, not realpath)
- Add CreateIfMissing to all migration and create paths
- 10 regression tests covering guard, auto-start, ReadOnly, underscore
- CHANGELOG and TROUBLESHOOTING docs

Authored by: Aaron Lippold<lippold@gmail.com>
2026-02-28 13:29:51 -05:00
Daniel DeChiara
9a2eea88a9
feat(labels): inherit parent labels on child creation
Adds automatic label inheritance when creating child issues via --parent flag.
New bd label propagate command pushes labels to existing children.
Includes --no-inherit-labels escape hatch.

PR: https://github.com/steveyegge/beads/pull/2177
Author: dechiad1
2026-02-27 17:39:13 -08:00
onyx
83b3991d4c fix: reject flag-like positional args in bd create (bd-2c0)
When --help or other flags bypass Cobra flag parsing (e.g., programmatic
invocation), they end up as positional title arguments, creating garbage
issues. Add a guard that rejects positional titles starting with - and
directs users to --title flag if intentional.

Executed-By: beads/polecats/onyx
Rig: beads
Role: polecats
2026-02-27 16:58:07 -08:00
Pablo LION
a3dd6531d3 feat(cli): show titles in command feedback (GH#1384) 2026-02-26 12:47:36 +01:00
mayor
a22da6f46f fix(dolt): remove auto-push from create and repo sync
Per-operation pushes to git remotes caused 22GB of git-remote-cache
bloat with dozens of agents creating wisps constantly. Push is now
only done by the daemon periodic task (every 15min) or explicitly
via `bd dolt push`. Cross-rig creates still commit pending changes
but skip the push. (hq-glw)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-25 13:33:18 -08:00
Joseph Turian
1c6f37360c
feat: add --metadata flag to bd create (GH#1406)
Add --metadata flag to bd create, matching the existing bd update --metadata interface.
Supports inline JSON and @file.json syntax. Wired through both direct and cross-rig paths.

Co-Authored-By: Joseph Turian <turian@gmail.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 12:23:26 -08:00
Xexr
322a084956
fix(create): commit post-create metadata (deps, labels) to Dolt (GH#2009) (#2055)
fix(create): commit post-create metadata (deps, labels) to Dolt

Fixes #2009
2026-02-23 10:06:58 -08:00
gastown/crew/george
01500d78b1 refactor(jsonl): remove cross-rig JSONL flush from create and rename-prefix (gt-vemg9q.4)
Replace flushRoutedRepo JSONL export in bd create with dolt commit+push
for cross-rig sync. Remove parseJSONLFile and JSONL safety import/export
from bd rename-prefix. Delete obsolete create_routing_flush_test.go.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: gastown/crew/george
Rig: gastown
Role: crew
2026-02-21 17:49:38 -08:00
beads/crew/jane
bfc49fec49 perf(dolt): batch N+1 queries, per-invocation caching, sentinel errors (#1874)
Batch N+1 query patterns in GetBlockedIssues, GetEpicsEligibleForClosure,
GetMoleculeProgress, and GetStatistics with IN-clause batch operations.

Add per-invocation caching for custom statuses, custom types, and blocked
IDs (invalidated on writes). Introduce storage.ErrNotFound sentinel error
replacing the (nil, nil) not-found pattern across all callers.

Comprehensive unit tests for queries.go and compact.go (2209 new lines).

PR: https://github.com/steveyegge/beads/pull/1874
Author: Steven Syrek <sjsyrek@users.noreply.github.com>
Reviewed-by: beads/crew/jane

Co-Authored-By: Steven Syrek <sjsyrek@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 14:26:13 -08:00
beads/crew/emma
ff0b469154 chore: Clean up stale daemon references in code comments and doctor messages
Update comments and user-facing messages across 17 production files to
reflect the current Dolt-native architecture (no daemon):

- Gitignore template: reorganized, daemon/SQLite entries moved to legacy section
- Doctor fix messages: removed references to non-existent bd daemon commands
- Doctor federation: updated fix suggestions to use gt dolt start / server mode
- Doctor integrity: removed "daemon won't start" messaging
- Code comments: replaced daemon mode references with current architecture terms
- Lock handling: marked daemon.lock as legacy cleanup

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/crew/emma
Rig: beads
Role: crew
2026-02-16 19:25:17 -08:00
beads/crew/emma
5ffd625b40 refactor: Phase 8 CLI & config cleanup - remove SQLite/daemon remnants (dolt-1s40.8)
Remove all vestiges of the SQLite backend, daemon system, and JSONL auto-sync
from CLI flags, config keys, doctor checks, init flows, and the bd backend command.

Key changes:
- Delete bd backend command and tests (backend selection obsolete)
- Remove --backend, --skip-merge-driver flags from bd init
- Remove --lock-timeout flag from main; use fixed 30s default
- Remove deprecated config keys: no-daemon, no-auto-flush, no-auto-import,
  auto-start-daemon, lock-timeout, daemon.* keys
- Remove auto-sync daemon setup wizard (Step 4) from bd init --team
- Clean up doctor checks: remove SQLite mtime divergence check, SQLite-only
  migrations, obsolete boolean config validation
- Replace all "bd init --backend dolt" references with "bd init"
- Simplify storage/dolt/open.go to always create Dolt store
- Change configfile.GetBackend() default from SQLite to Dolt
- Fix pre-existing build errors: AsVersioned removal, duplicate imports,
  missing compact/dirty stubs, signature mismatches, undefined functions

Also adds bridge/stub files for functions removed in prior phases:
- sync_bridge.go: exportToJSONL, importFromJSONL, doSyncFromMain, etc.
- import_shared.go: ImportOptions, ImportResult, importIssuesCore
- stubs.go: findJSONLPath, clearAutoFlushState, readFromGitRef
- dolt/compact.go, dolt/dirty_issues.go: no-op method stubs

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/crew/emma
Rig: beads
Role: crew
2026-02-15 15:43:11 -08:00
beads/crew/emma
12f9037d87 refactor: replace factory/memory imports with direct dolt calls (Phase 7 cleanup)
Phase 7 (a5da57e3) deleted internal/storage/factory/ and internal/storage/memory/
but left 30+ files still importing them. This commit fixes all broken references:

- Created internal/storage/dolt/open.go with NewFromConfig/NewFromConfigWithOptions
- Replaced all factory.New/NewFromConfig/NewWithOptions with dolt equivalents
- Broke import cycles in dolt/bootstrap.go (routing/utils/audit → local types)
- Removed dead storage.Config struct
- Converted all test files from memory.New() to dolt.New() test stores
- Removed tests that depended on deleted detectPrefix/LoadFromIssues/mockRemoteStore

46 files changed, 249 insertions(+), 851 deletions(-)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/crew/emma
Rig: beads
Role: crew
2026-02-15 13:22:06 -08:00
Steve Yegge
d6e0a8576e
Merge pull request #1742 from sjsyrek/fix/create-deps-and-message-type
fix(create): fix --deps blocks: direction + add message type
2026-02-15 12:17:30 -08:00
beads/crew/emma
a5da57e39b refactor: remove storage factory, memory backend, and provider abstraction (Phase 7)
Strip out the multi-backend storage layer: factory pattern, memory/in-memory
provider, connection string parsing, local provider, and associated tests.
Inline Dolt as the sole storage backend. Part of Dolt-Native Beads v2 epic.

WIP - SQLite removal in progress, more cleanup phases to follow.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/crew/emma
Rig: beads
Role: crew
2026-02-15 11:27:39 -08:00
beads/crew/emma
7eed8b8a1e refactor: remove tombstone/soft-delete system (Phase 4)
Remove the tombstone soft-delete mechanism across the codebase. Dolt handles
delete propagation natively, making tombstones obsolete.

Key changes:
- Remove StatusTombstone constant and all status checks
- Remove DeletedAt/DeletedBy/DeleteReason/OriginalType fields from Issue struct
- Remove resurrection mechanism (JSONL parent recovery), replace with existence checks
- Simplify schema CHECK constraint (2 clauses instead of 3)
- Remove compact_tombstone.go, resurrection.go, migrate_tombstones.go
- Remove tombstone-specific tests (resurrection, expired tombstones, migration)
- Update doctor/fix validation to skip tombstone-specific checks
- Preserve migration files for backward compatibility with existing databases
- 104 files changed, 6117 deletions, 422 insertions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/crew/emma
Rig: beads
Role: crew
2026-02-14 21:22:24 -08:00
jasper
619f34a441 chore: add explanatory comments to silently ignored errors across codebase
Code health review found 30+ instances of error suppression using blank
identifier without explanation. Added comments to 82 files explaining WHY
each error is safely ignored (best-effort cleanup, advisory operations,
safe defaults, etc.) to improve code maintainability.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/polecats/jasper
Rig: beads
Role: polecats
2026-02-14 17:16:43 -08:00
Steven Syrek
0c6ef53e94 fix(create): swap dependency direction for explicit blocks: prefix
When a user specifies --deps blocks:X, they mean "the new issue blocks X",
but the code was creating the dependency with the wrong direction (X blocks
the new issue). This swaps IssueID and DependsOnID when the user explicitly
uses the blocks: prefix so the semantics match intent.

Also adds "depends-on" as a recognized alias for the default dependency
direction.

Fixes #1369

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-02-14 18:51:06 +01:00
Steven Syrek
1f63bd73bf fix(cli): show only base types in --type flag help text
The help text for `bd create --type` and `bd update --type` listed
Gas Town types (molecule, gate, convoy, etc.) as valid options, but
they fail with 'invalid issue type' unless types.custom is configured.
Show only the six built-in types and note that custom types require
configuration.

Closes #1727

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-02-14 16:48:19 +01:00
beads/crew/emma
a5205a7851 feat: frictionless beads init workflow (cherry-picked from PR #1685)
Cherry-picked UX improvements from maphew init workflow PR:
- Better test issue detection with shared isTestIssue() helper
- Non-interactive stdin detection in doctor fix/validate (prevents CI hangs)
- Initialize last_import_time and version tracking during bd init
- Set default beads.role when interactive prompt is skipped
- Warn about missing git upstream at init time
- Remove stale --no-daemon from doctor fix commands
- Context-aware Claude Plugin suggestion (only in Claude Code)
- Actionable error hints for database not initialized via FatalErrorWithHint
- Compile test-prefix regex once at package level instead of per-call

Dropped from original PR: auto-commit during init (needs opt-out flag),
daemon_deprecated.go stubs, accidentally restored deleted files (queries.go,
dirty.go from pre-Dolt transition branch base), release playbook docs.

Co-authored-by: maphew <maphew@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Executed-By: beads/crew/emma
Rig: beads
Role: crew
2026-02-11 18:28:50 -08:00