* feat(migrate): add --force flag as CLI twin of BD_ALLOW_REMOTE_MIGRATE The remote-migrate gate (#4259) refuses to auto-apply pending schema migrations to a remote-backed database because two clones migrating independently fork the schema unrecoverably. Until now the only unlock was the env var BD_ALLOW_REMOTE_MIGRATE=1, which is awkward at the CLI and can leak into child processes (git hooks, dolt subprocesses). The --force flag is the natural CLI form of the designated-migrator escape hatch: it is set before both autoMigrateOnVersionBump and the main store open in the root PersistentPreRunE via a package-level bool, so it never leaks out of the process. The env var remains supported for scripted/CI use and is documented as a parenthetical alongside the new primary form. Agent-Signature: claude-sonnet-4-6-high on behalf of matt wilkie * fix(embeddeddolt): point lenient-gate guidance at bd migrate --force The soft-fail (warn-and-continue) gate warning for read-only and working-set-reconcile opens still named the env-var escape hatch; align it with the new primary form introduced for the strict gate. Agent-Signature: claude-fable-5-high on behalf of matt wilkie * fix(migrate): reject --force with preview flags; harden override lifecycle Review findings on the --force flag (cross-vendor: codex gpt-5.5 + claude opus): - --force combined with --dry-run/--inspect must fail before the store opens: with the gate overridden, the open itself applies pending migrations, so the preview flag would be honored only after the destructive work it exists to prevent (codex P2). - Set-or-clear the override unconditionally so it is self-clearing under any future in-process root-command reuse (reviewer nit). - Lock the agent-safety contract against the new flag form: AgentDirective must not embed 'bd migrate --force' any more than the env form (nit). Agent-Signature: claude-fable-5-high on behalf of matt wilkie |
||
|---|---|---|
| .. | ||
| architecture | ||
| cli-reference | ||
| core-concepts | ||
| getting-started | ||
| integrations | ||
| multi-agent | ||
| recovery | ||
| reference | ||
| workflows | ||
| community-tools.md | ||
| intro.md | ||