beads/internal
Steve Yegge f8df36db5a
fix(storage): skip empty Dolt commit when nothing is staged (re-port of #4288) (#5403)
Maintainer-side re-port of realies' #4288 (substance-approved by maphew
2026-07-27), redone against current main per bd-oibnz. The consolidation
half of the original PR (issues.go hand-rolled DOLT_ADD/DOLT_COMMIT sites
onto doltAddAndCommitInTx) already landed independently via #5341, so this
carries the remaining half: the empty-commit guards.

An idempotent no-op write (INSERT IGNORE duplicate, ON DUPLICATE KEY
re-writing the same value, UPDATE matching nothing) leaves its table clean,
so the selective DOLT_ADD stages nothing and DOLT_COMMIT('-m') fails
server-side with a 'nothing to commit' warning — flooding dolt.log at
reconcile cadence.

- issueops.HasStagedChanges: reports whether dolt_status has staged rows —
  exactly what a '-m' commit would include.
- versioncontrolops.StageAndCommit: global HasPendingChanges fast-path
  before staging, plus the precise HasStagedChanges guard before commit
  (an unrelated dirty table must not trigger an empty '-m' commit).
- DoltStore.doltAddAndCommit / doltAddAndCommitInTx: staged-set guard
  before commit (these stage a fixed table list, so only the staged check
  applies). A guard-read failure in doltAddAndCommit is a plain error, not
  a publication failure: nothing committed, nothing indeterminate.
- Tests: sqlmock discriminators asserting DOLT_COMMIT is NOT issued on an
  empty staged set (they fail if a guard is reverted), integration
  regression tests for no-op dependency writes and claim/close
  over-suppression, and existing commit-boundary/draincall/phase harnesses
  taught to serve the two new dolt_status guard reads.

Co-authored-by: realies <5107843+realies@users.noreply.github.com>
2026-08-07 10:32:31 -07:00
..
ado fix(ado): map parent-child deps to hierarchy links (not Related) (#5129) 2026-07-31 01:45:16 -07:00
atomicfile /internal/atomicfile/atomicfile.go: use io.Copy 2026-05-01 17:03:30 -07:00
audit fix(audit): make JSONL sidecar opt-in (#4688) 2026-07-11 00:09:17 -07:00
beads feat(storage): add extension-safe backend registry seam (#4859) 2026-07-31 03:05:48 -07:00
compact feat: add MiniMax provider support via Anthropic-compatible API (#3610) 2026-08-02 22:23:37 -07:00
config Widen the secret-key predicate now that it gates an unauthenticated wire 2026-08-06 13:24:25 +00:00
configfile Guard and qualify historical upgrades to v1.2 (#4907) 2026-08-06 18:45:04 -07:00
creds chore(creds): drop the two unreferenced credential rungs (#5379) 2026-08-06 07:03:09 -07:00
debug feat(verbosity): wire --quiet into create/close/update (bd-au0.10) (#4058) 2026-07-06 22:35:42 -07:00
doltremote fix(doltremote): fold host case, strip creds, recognize user-less SCP in CanonicalForComparison (#4576) 2026-07-07 12:59:18 -07:00
doltserver perf: snapshot Dolt processes in one pass (bd-1rh.15) (#5326) 2026-08-03 20:49:27 -07:00
fdhygiene fix(doltserver): stop detached children inheriting the caller's fds (#4634) (#5184) 2026-07-31 08:41:41 -07:00
formula fix(formula): validate provided-empty and enum/pattern var values in pour/wisp/bond, not just cook (#5253) 2026-08-01 17:16:57 -07:00
git test(git): restore cwd before temp cleanup (#4935) (#4936) 2026-07-23 18:40:44 -07:00
githooksenv fix(dolt): disable git hooks on the in-process push path too (#4272) (#5186) 2026-07-31 09:42:50 -07:00
github fix(github): content-based dedup on push to stop re-PATCHing every issue (#4214) (#4329) 2026-08-02 22:53:06 -07:00
gitlab feat(gitlab): sync issue dependency links on push (#4294) 2026-07-08 08:00:41 -07:00
hooks test: port Windows hardening fixes (#4600) 2026-07-07 12:59:50 -07:00
httpapi fix(defer): auto-wake expired dated defers on ready-front reads and claims (bd-i8qx8) (#5386) 2026-08-07 04:34:38 -07:00
idgen fix(idgen): correct test vectors in hash_test.go 2025-12-19 18:13:56 -08:00
jira Add append-only provenance_events log and bd provenance CLI (#4461) 2026-08-07 09:43:20 -07:00
linear fix(windows): detect exited processes in liveness helpers (#4980) (#4981) 2026-07-23 18:24:49 -07:00
lockfile Triage and clean up an unreviewed automated commit stream on main (#4418) 2026-06-15 20:24:57 -07:00
memoryapi Put the memory plane behind memoryops, conformance-tested at three backends (#5387) 2026-08-07 03:57:04 -07:00
metrics fix(metrics): skip the detached flusher spawn under BEADS_TEST_MODE (#5248) 2026-08-01 15:20:33 -07:00
migration/legacysqlite Guard and qualify historical upgrades to v1.2 (#4907) 2026-08-06 18:45:04 -07:00
molecules feat(storage): refuse test DBs on production dolt servers (AD-01) (#3632) 2026-07-24 01:28:51 -07:00
notion test: replace Notion config fixtures with recorder (bd-b51np) (#5256) 2026-08-01 19:49:57 -07:00
procid fix(lint): check deferred windows.CloseHandle returns (errcheck) (#5088) 2026-07-26 14:47:37 -07:00
query fix(query): make slash and mixed-case metadata keys queryable (#4896) 2026-07-24 17:52:22 -07:00
recipes [codex] Add Kiro setup recipe (#4535) 2026-07-27 22:28:43 -07:00
remotecache fix: pass remote auth user during clone (#4484) 2026-07-05 11:28:24 -07:00
routing fix(routing): warn when contributor auto-routing swaps bd list/ready to the planning store (#4866) 2026-07-25 22:31:03 -07:00
storage fix(storage): skip empty Dolt commit when nothing is staged (re-port of #4288) (#5403) 2026-08-07 10:32:31 -07:00
telemetry Add append-only provenance_events log and bd provenance CLI (#4461) 2026-08-07 09:43:20 -07:00
templates fix(cli): printed doc paths point at the new docs locations 2026-07-12 10:37:17 -07:00
testutil fix(test): pin DOCKER_HOST from the active docker context before TestMain swaps HOME (bd-84kos) (#5391) 2026-08-07 00:32:40 -07:00
timeparsing fix: normalize parsed timestamps to UTC (#5295) 2026-08-07 07:03:43 -07:00
tracker fix(github): content-based dedup on push to stop re-PATCHing every issue (#4214) (#4329) 2026-08-02 22:53:06 -07:00
types Add append-only provenance_events log and bd provenance CLI (#4461) 2026-08-07 09:43:20 -07:00
ui test(cli): cover --no-color flag handling and ui.DisableColors 2026-07-07 23:32:22 -04:00
uimd fix(cli): render markdown with terminal capability gates (#3881) 2026-06-25 13:55:28 -07:00
utils feat(issueops): add the Reader role and wire both front doors through it 2026-07-31 18:37:25 +00:00
validation fix(close): restore idempotent re-close by ordering, not by clearing the pin (#5236) 2026-08-01 09:04:14 -07:00
workapi Put the memory plane behind memoryops, conformance-tested at three backends (#5387) 2026-08-07 03:57:04 -07:00
workspacegate feat(workspacegate): shared physical-root resolver, beads.OpenGated, and CLI gate wiring (part 2) (#5093) 2026-07-31 01:41:20 -07:00
worktreeremove test: replace worktree removal process matrix (bd-kuqlg.2) (#5280) 2026-08-02 09:34:29 -07:00