beads/internal/storage
Steve Yegge 508d359211 fix(automerge): tell a no-op merge write from a vanished row (wy-o8swn)
The conflict resolvers read res.RowsAffected()==0 after their UPDATE as
proof the row had been deleted concurrently, and aborted the whole merge
saying so. But doltutil/dsn.go sets parseTime and multiStatements and NOT
clientFoundRows, so RowsAffected is rows CHANGED, not rows MATCHED: a
merged write the backend normalizes to the bytes already stored reports
zero exactly as a vanished row does, and a correct merge died on a
message about a deletion that never happened.

Ask instead. conflictTargetStillPresent is the matched-rows check both
sites lacked, and it covers the operator path too — resolveOneConflictRow
(bd conflicts resolve --theirs <id>) carried the identical conflation,
where a misleading abort is worse because the operator named the row. It
confirms only that the key still resolves to a row, which is the honest
postcondition: comparing the written values would reintroduce the very
normalization sensitivity this exists to absorb. A check that cannot be
run refuses rather than clearing a conflict it could not confirm.

Second half: the bulk load never rejected duplicate conflict rows sharing
one our-side key the way loadConflictRow does for the single-row path. If
dolt ever emits two, the first DELETE ... WHERE our_id = ? clears both
and the next iteration aborts on "no conflict row deleted" — again a
message about the wrong thing, after a row was resolved without ever
being merged. duplicateConflictKey now catches that shape, and the
pre-screens DECLINE on it rather than erroring: an error out of
issuesConflictsAreFieldMergeable is swallowed by SettleMerge's abort path
and would turn a reportable conflict into an opaque pull failure, where a
decline still builds the MergeConflictsError that names the tables an
operator has to look at. Rows whose our side is NULL (delete/modify) are
skipped — they are never the target of a keyed delete.

Neither shape is known to fire today; both were left unfixed at the tail
of the wy-jpd3.6 diff (F7) rather than patched in a hurry.
2026-07-25 04:50:05 -07:00
..
conformance fix(lint): replace reclaim_scope eq closure with slices.Equal (gosec G602) (#5010) 2026-07-24 06:41:26 -07:00
contextinfo /{cmd,internal}: bd context proxied-server support 2026-06-24 13:04:48 -07:00
dberrors feat(engine): guarded write ops — atomic metadata merge, row-version CAS, typed dep errors + events, bd close delegation (#4911) 2026-07-21 18:13:03 -07:00
dbproxy Use Snappy output for Dolt garbage collection (#4986) 2026-07-23 08:55:29 -07:00
depid fix(deps): deterministic dependency primary keys for cross-clone merge-safety (#4259) 2026-06-07 14:47:58 -07:00
dolt feat(conflicts): dolt-backed conflict tests, --conclude, merge-blocker visibility (wy-36ilm) 2026-07-25 01:54:49 -07:00
doltutil perf(dolt): eliminate 12s slow path on bd commands when .local_version is stale (#3710) 2026-07-24 00:53:06 -07:00
domain feat(leases): replica-aware leases — record the granting node, refuse cross-replica reclaim (wy-jpd3.7) 2026-07-24 23:53:34 -07:00
embeddeddolt fix(leases): make the replica guard opt-in — drop the hostname fallback (wy-jpd3.7) 2026-07-25 02:32:31 -07:00
fs /{cmd,internal}: refactoring 2026-05-19 15:37:37 -07:00
git /{cmd,internal}: refactoring 2026-05-19 15:37:37 -07:00
issueops fix(leases): keep node_id off the committed config; tighten the replica guard (wy-jpd3.7) 2026-07-25 02:32:31 -07:00
kvkeys fix(dolt): pre-pull commit must include config (kv.memory.* pull-wedge) (#4412) 2026-06-19 21:31:33 -07:00
rowid fix(schema): drop dormant DEFAULT (UUID()) from aux and wisp table ids (bd-2rd37) 2026-06-11 07:32:57 -04:00
schema feat(leases): replica-aware leases — record the granting node, refuse cross-replica reclaim (wy-jpd3.7) 2026-07-24 23:53:34 -07:00
sqlbuild feat(leases): replica-aware leases — record the granting node, refuse cross-replica reclaim (wy-jpd3.7) 2026-07-24 23:53:34 -07:00
uow feat: support compact/gc/ping/dolt clean-databases in proxied-server mode (#5003) 2026-07-23 22:42:02 -07:00
versioncontrolops fix(automerge): tell a no-op merge write from a vanished row (wy-o8swn) 2026-07-25 04:50:05 -07:00
advanced_queries.go /internal/storage: add interfaces for methods not covered by Storage 2026-03-06 15:30:10 -08:00
annotation_queries.go Update internal/storage/annotation_queries.go 2026-03-06 15:40:56 -08:00
batch.go fix(import): equal-timestamp upsert keeps the local row; report what import changed (bd-hj85c) 2026-06-12 17:58:40 -04:00
bulk_issues.go feat(reclaim): scope filters --label/--label-any/--exclude-label/--assignee/--id (wy-jpd3.3) 2026-07-24 05:31:23 -07:00
child_counter_reservation.go fix(create): commit labels during initial issue creation (#4149) 2026-05-24 19:23:46 -07:00
compaction.go fix(compact): archive content before destructive compaction; make restore work (#4464) 2026-06-20 14:12:07 -07:00
config_metadata.go feat: custom status categories (active/wip/done/frozen) 2026-03-21 12:35:03 -07:00
dependency_queries.go feat(storage): events + dependents reads, batched blocked, public claim surface (#4926) 2026-07-22 07:41:47 -07:00
errors_unsupported.go Reapply "Simplify the supported backends: roll back the direct PostgreSQL and MySQL adapters" (#4857) 2026-07-18 02:43:56 +00:00
event_queries.go feat(storage): events + dependents reads, batched blocked, public claim surface (#4926) 2026-07-22 07:41:47 -07:00
federation.go /internal/storage: add interfaces for methods not covered by Storage 2026-03-06 15:30:10 -08:00
history_viewer.go feat(storage): add ExternalRefHistoryQuerier capability for external-ref history (#4733) 2026-07-12 13:43:27 -07:00
hook_decorator.go feat(engine): guarded write ops — atomic metadata merge, row-version CAS, typed dep errors + events, bd close delegation (#4911) 2026-07-21 18:13:03 -07:00
hook_decorator_internal_test.go feat(engine): guarded write ops — atomic metadata merge, row-version CAS, typed dep errors + events, bd close delegation (#4911) 2026-07-21 18:13:03 -07:00
hook_decorator_test.go fix(telemetry): wire WrapStorage decorator into bd storage chain (#3858) 2026-07-06 22:27:32 -07:00
iter.go Reapply "Simplify the supported backends: roll back the direct PostgreSQL and MySQL adapters" (#4857) 2026-07-18 02:43:56 +00:00
merge_slot.go feat: add MergeSlot methods to Storage interface (fix-merge PR #2787) 2026-03-26 19:34:21 -07:00
metadata.go fix(query): make slash and mixed-case metadata keys queryable (#4896) 2026-07-24 17:52:22 -07:00
metadata_jsonpath_test.go fix(query): make slash and mixed-case metadata keys queryable (#4896) 2026-07-24 17:52:22 -07:00
metadata_schema_test.go feat: config-driven metadata schema enforcement (GH#1416 Phase 2) (#2027) 2026-02-24 22:24:56 -08:00
metadata_test.go feat: allow UpdateIssue metadata updates via json.RawMessage/[]byte (#1417) 2026-02-03 17:55:23 -08:00
remote.go feat: add --remote flag to bd dolt push/pull commands (#3211) 2026-04-20 18:02:33 -07:00
storage.go feat(update): conditional compare-and-set guards --if-assignee/--if-status (bd-wsqvw) (#5008) 2026-07-24 09:11:15 -07:00
sync.go /internal/storage: add interfaces for methods not covered by Storage 2026-03-06 15:30:10 -08:00
version_control.go feat(conflicts): dolt-backed conflict tests, --conclude, merge-blocker visibility (wy-36ilm) 2026-07-25 01:54:49 -07:00
versioned.go feat(conflicts): bd conflicts list|show|resolve — issue-oriented merge conflicts (wy-jpd3.5) 2026-07-24 19:47:16 -07:00