Repository navigation
fix(store): graph-neutral operation conflicts repair without full replay (#9101) - #6334
schickling-assistant wants to merge 3 commits into
Conversation
agent-identity: agent/compoundingtech/st-conversations agent-persona: generalist agent-supervisor: unavailable agent-tool: unknown agent-runtime: unknown agent-model: unknown
agent-identity: agent/compoundingtech/st-conversations agent-persona: generalist agent-supervisor: unavailable agent-tool: unknown agent-runtime: unknown agent-model: unknown
|
FPL GO for #6334 at head 11bd608. The same GO covers the hotfix commit a42f5cf (branch Source review
Hotfix equivalence
Conditions
Limit: a host whose graph is already stale at receipt still replays once. Cases (a)-(d) remain open (#6330). Posted on behalf of @schickling
|
|
FPL: my GO for the hotfix commit a42f5cf is WITHDRAWN. Its gate-slot test at that SHA failed: Posted on behalf of @schickling
|
|
FPL: my GO for #6334 at 11bd608 is WITHDRAWN. Reasons:
The next head needs:
If the test fails because the test setup delivers nothing ("listing 0 identities"), the fix must make the test non-vacuous: it must assert that both claims arrived before it asserts anything else. Posted on behalf of @schickling
|
agent-identity: unknown agent-persona: unknown agent-supervisor: unavailable agent-tool: unknown agent-runtime: unknown agent-model: unknown
|
FPL delta GO for #6334 at head af65763 (delta from 11bd608; test and release note only). This GO replaces the withdrawn GO. Root cause accepted: the parity test was vacuous. It received envelopes but never ran
The production code is unchanged since 11bd608. Note: the production path is now tested for the first time. Conditions:
Hotfix: Posted on behalf of @schickling
|
Problem
Two observers can write
github.eventclaims with the samegithub-event:{subject}key but different observer, time, detail, and head SHA (dotfiles incident #9101). The operation conflict previously returnedReplayWithContext, causing a full replay under the writer and long freezes even when the structural graph was unaffected.Goal
Healthy-live prevention for graph-neutral operation conflicts: reconcile the affected operation incrementally, with the same canonical result as a full replay.
Decisions
!replay_projects_kind(kind)take the existingmessage.sentreconcile path only when every claim and checkpoint tombstone in that operation's indexed history is also graph-neutral:repair_operations_tx, indexed operation history, the full replay's reducer, and per-chunk deduplication. Structural kinds keepReplayWithContext.repair_operations_txwhen their indexed history is entirely graph-neutral; mixed structural history keepsReplayWithContext. This includes the normal first-claim path, covered by position 0 in the parity test, as well as checkpoint tombstones whose stored claim and operations row are absent.Verification
Local source guards passed:
python3 scripts/propose-sqlite-large-valueswas run; the three new SQL sites are checkpoint-test fixtures with reviewed adjacent markers and inventory entries.Corrected regression root cause
The initial hotfix run failed the first variant (checkpointed=false, order=[0,1]): the test called receive_replication_exchange and projection but omitted validate_replication_backlog. Receive persists envelopes; admission materializes claims. Consequently neither received claim was materialized, the old parity checks compared empty operation states, and the final conflict assertion found no operations row. This was a test bug, not evidence of a production reducer failure; the earlier parity evidence was vacuous.
The corrected test explicitly validates admission and asserts each claim exists. It requires the operation to be missing/active before projection and active/conflict afterwards, with FULL_REPLAYS unchanged. Both claims must have been admitted and the incremental repair must have produced conflict before any full-replay parity check. This covers both arrival orders and both retained-claim/checkpoint-tombstone variants. The cross-kind test already used the sync helper, which validates admission, followed by direct append_claim_record_tx writes; its explicit fallback and naming-conflict assertions were not vacuous.
The corrected main head is af65763. Focused local tests on the exact corrected main/hotfix heads are queued in the normal build lane; they have not passed yet. Hosted linux-tests must be green at this exact main head. The successful evidence-gate-rust-tests job on the prior head only decided to run tests and was not test-pass evidence. The previous Product Lead GO is withdrawn pending these corrected-head results.
Added/affected tests:
graph_neutral_operation_conflicts_match_replay_in_both_orders_and_after_checkpoint: actual GitHub event replication in both arrival orders, with and without checkpoint tombstones/no operations row; unchangedFULL_REPLAYS; operations and allprojection_digestsequal a replay from nothing, explicitly includingcustom_*andclaim_sources.full_replay_logs_every_guard_and_incremental_error_once: the operation-conflict fixture now uses a structural kind, preserving fallback coverage.mixed_structural_and_neutral_operation_history_requires_replay_in_both_orders: an actual rename and a graph-neutral receipt sharing an operation are rejected by the narrow path in both orders; naming becomes conflict-blocked and all projection digests match a replay from nothing.Before → intended after: a healthy graph-neutral operation conflict requests a whole-graph replay → only that operation's indexed canonical receipt is repaired. Runtime validation is pending hosted CI.
Complexity
No new abstraction or dependency. Reuses the existing reducer and chunk-local dedupe set; Six affected files, including neutral-only, checkpoint, and mixed-structural regression coverage.
Concerns
NOT covered: remaining replay paths
Replay("unhealthy-projection")before this branch, and the driver replays under the writer.replay_replication_graphstill performs a full replay.This is a narrow prevention step, not a complete remedy for writer-held replay freezes.
Friction & bottlenecks
The normal local build queue has 53 waiting tickets. The initial hotfix run exposed missing admission in the new test; verification is now explicitly nonvacuous and pending on the corrected heads. No performance timing is claimed.
Follow-ups
The broad replay fix is #6330, which lands after this PR and remains separate.
References
Models
gpt-6.1-sol, harness subagent).ReviewNarrow), source GO at11bd608e83dc9aa7fe56132a247945696e20208bafter the P2 mixed-structural-history fix; corrected-test-head verification is pending.Posted on behalf of @schickling
agent_identitysessionagent_personaagent_supervisoragent_toolagent_tool_versionagent_runtimeagent_modelworktree