Skip to content

id(event_store): no test reaches an Ingest::Voided disposition through a range session #2414

Open

Description

@dezren39

Follow-up to PR #2214 / issue #179 (queue task 2970).

event_store::sync::Outcome now carries voided, mapped from the range session's Tally (event_store/sync.rs, Tally::add → Ingest::Voided). Ingest::Voided is produced when an arrival is stored but not applied (event_store/ingest.rs, Staged::finish: is_applied == false).

Nothing tests that path end to end:

  • The range-session test that was meant to (test_a_range_session_counts_voided_events, commit 2316d85f on id(sync): split serve range sessions onto /id-range-sync/1 (#179) #2214) actually built the fork into the receiving store before the session, so its arrivals were refused as frozen (db.voided = 0, db.refused = 2). That test now pins the frozen shape under its real name, test_a_range_session_counts_frozen_arrivals_as_refused.
  • No test anywhere asserts an Ingest::Voided outcome today (grep 'Ingest::Voided' finds only the label arms in event_store/sync.rs and log_sync.rs).

What is needed: a shape where an event is stored without being applied and reported as Voided — plausibly an event released from the waiting pool by a fork decided in the same batch (Staged::Stored → finish) — driven through event_store::sync and asserted on Outcome::voided, plus the same for log_sync's tally. If no such shape is reachable, the voided field is dead and should say so in its doc comment instead.

Acceptance criteria

  • A range-session test drives an arrival that is stored but not applied through a real range session and asserts the session tally / Outcome::voided reflects it (a voided count greater than zero), distinct from the frozen-refusal shape the current mis-built test pins.
  • The same voided accounting is covered for the log_sync tally, or the gap is explicitly documented in the test/PR.
  • If no stored-but-not-applied shape is reachable through a range session, the voided field is documented as dead in its doc comment instead of gaining a forced test.

Activity

  1. added
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    on Oct 29, 2026
  2. developing-today commented on Oct 29, 2026

    @developing-today
    Contributor
  3. added
    kind/testTest coverage, test infrastructure, or test-only fixes
    source/queue-workerFiled or worked by the queue/worker pilot
    priority/normalOrdinary priority (the default)
    effort/sSmall: expected under 2 hours of work
    meta/enrichedIntake review done: acceptance criteria, links, and normalized labels added
    on Oct 29, 2026
  4. dezren39 commented on Oct 29, 2026

    @dezren39
    MemberAuthor

    Intake review

  5. added
    queue/queuedHas a queued task in the Supabase agent queue
    task/triageQueue packet kind: verify, reproduce, and route this item
    on Nov 3, 2026
  6. dezren39 commented on Nov 3, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · triaged

    • Agent: repo queue worker, lane code-c (task 7918)
    • Task: TRIAGED — issue id(event_store): no test reaches an Ingest::Voided disposition through a range session #2414 is still live at current main, its blocker has landed, and the test gap is exactly as filed. A small_fix (test-only) follow-up task is enqueued from this triage.
    • Blocker cleared: the intake review (2026-10-29) noted this gap becomes closable when PR id(sync): split serve range sessions onto /id-range-sync/1 (#179) #2214 lands; PR id(sync): split serve range sessions onto /id-range-sync/1 (#179) #2214 is now MERGED (2026-10-30T01:00:10Z), and the voided plumbing is on main: Tally::add maps Ingest::Voided in pkgs/id/src/event_store/sync.rs (line 152, surfaced as Outcome::voided at line 702) and in pkgs/id/src/log_sync.rs (line 166, surfaced at line 398).
    • Gap verified at main eef89b9 (2026-11-03): in event_store/sync.rs the only range-session voided assertion is db.voided == 0 inside test_a_range_session_counts_frozen_arrivals_as_refused (line 1234) — the frozen/refused shape, not a stored-but-not-applied arrival. No range-session test asserts a voided count above zero, and log_sync.rs has no test-side voided assertion at all (only the tally arm and the Outcome field). Direct-ingest Voided assertions exist (pkgs/id/tests/production_ingest.rs, pkgs/id/tests/crash/store.rs) but neither drives a range session, so they do not close this issue.
    • Scope for the fix (test-only unless reachability answers otherwise): construct a stored-but-not-applied arrival — plausibly an event released from the waiting pool by a fork decided in the same batch (Staged::Stored → Staged::finish with is_applied == false) — drive it through a real event_store::sync range session, and assert Outcome::voided > 0 with refused unchanged; mirror the same accounting assertion for the log_sync tally. Assert the tally fields explicitly so the test cannot pin the neighbouring frozen shape under the voided name (the original failure). If no such shape is reachable through a range session, document the voided field as dead in its doc comment instead of forcing a test, per the issue's third acceptance term.
  7. developing-today commented on Nov 3, 2026

    @developing-today
    Contributor

    agent-note:v1
    state: triaged (coverage pass)
    Coverage pass 2026-11-03: reviewed in the fleet-wide per-issue pass (drift / overlap / already-handled / stale / blockers / ordering). Verdict: still live; queued in repo-health-code-pilot as triage at priority 40 (priority/normal). If this is already handled at current main, the triage closes it with evidence; if it needs splitting, the triage files the split.
    Found via: coverage pass 2026-11-03

  8. dezren39 commented on Nov 3, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · picked up

  9. added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed
    queue/queuedHas a queued task in the Supabase agent queue
    on Nov 3, 2026
  10. dezren39 commented on Nov 3, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · done — PR opened

    • Agent: queue worker (repo-worker-code), lane G (code-g)
    • Session / ID: task 8530
    • Task: PR test(id): drive an Ingest::Voided disposition through a range session (#2414) #5124 opened: test(id): drive an Ingest::Voided disposition through a range session (#2414) #5124 (branch queue/8530-2414-voided-range-test, head 3d35eec, MERGEABLE, test-only, 201 insertions in pkgs/id/src/event_store/sync.rs + pkgs/id/src/log_sync.rs).
    • What it does: drives an Ingest::Voided disposition through a real range session in both tallies. Shape: both stores hold a group create (A/B/C managers) and D's group operation adding E — stored but voided, since D is not a member. Only the sender holds D's content event naming the voided operation in after; by resolve rule 3 it is stored without applying at the receiver: received == 1, voided == 1, accepted == 0, refused == 0, distinct from the frozen-refusal shape. The log_sync mirror runs the same shape through a LogSync-protocol range session (LogAndRange).
    • Tests (laptop): both new test_a_range_session_counts_a_stored_but_unapplied_arrival_as_voided tests pass; event_store::sync:: suite 22 passed / 0 failed; log_sync:: suite 22 passed / 0 failed; git diff --check clean; no fmt diff in added code.
    • State: task 8530 completes as pr_opened. Merge follows the standing criteria once PR test(id): drive an Ingest::Voided disposition through a range session (#2414) #5124's Codex findings (if any) are dispositioned; the issue stays open until the PR merges.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/sSmall: expected under 2 hours of workkind/testTest coverage, test infrastructure, or test-only fixesmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/normalOrdinary priority (the default)source/queue-workerFiled or worked by the queue/worker pilottask/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions