Repository navigation
backend-go: finalization replay oracle, scoped (SCA-3551 lane 7) - #26293
Conversation
Co-authored-by: multica-agent <[email protected]>
Co-authored-by: multica-agent <[email protected]>
Co-authored-by: multica-agent <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 983c0b5194
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Co-authored-by: multica-agent <[email protected]>
Co-authored-by: multica-agent <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1a5d273467
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Co-authored-by: multica-agent <[email protected]>
Co-authored-by: multica-agent <[email protected]>
Co-authored-by: multica-agent <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d8eb9e608f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Co-authored-by: multica-agent <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d18e7dc40a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…hapes Co-authored-by: multica-agent <[email protected]>
Co-authored-by: multica-agent <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 686cebee73
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Co-authored-by: multica-agent <[email protected]>
|
Hey @Git-on-my-level 👋 Thank you so much for taking the time to contribute to Omi! We truly appreciate you putting in the effort to submit this pull request. After careful review, we've decided not to merge this particular PR. Please don't take this personally — we genuinely try to merge as many contributions as possible, but sometimes we have to make tough calls based on:
Before your next PR, please skim:
If this was declined for direction or taste, maintainers should cite an invariant ID or open a proposed one — ask if that citation is missing. Your contribution is still valuable to us, and we'd love to see you contribute again in the future! If you'd like feedback on how to improve this PR or want to discuss alternative approaches, please don't hesitate to reach out. Thank you for being part of the Omi community! |
…-commit meter (SCA-3551 lane 7) (#26322) Follow-up to #26293 (SCA-3551 lane 7, the finalization replay oracle). It's based on `main` at `e060f71e`, the #26293 merge. It touches only replay tooling and no serving path. **Current head: `73f41d0c`**, a merge of main `fd7f1519` into the reviewed `9fa4bc15` (fast-forward of `bdad61e1`). The merge adds no replay changes; it gives the PR a fresh check history on repaired main. It includes the paired-erasure comparison and the two binding/evidence commits below. - `c6dd4765`, from bundle `8ca3e1ae`. The driver now gives both sides the same lifecycle inputs: - **Missing-row fence:** the Python row is deleted after claim, just before the finalizer's first worker read. - **Erasure:** runs after a completed or discarded Python replay. This clears both whole-`/conversation` differences. One conflict in `driver.py` was resolved by hand: the speaker-trace hook from main runs first, then the paired `run_python` wrapper. - `96789fc5`, from bundle `006671ae`. Failed Firestore Commit RPCs are reported per side and per case, outside the R7 total. Preserved Home tokens with same-field pre-run evidence are compared literally. - `2ad9855d` is the FIX-FIRST commit for the CI replay gate. On the erasure fixture, the finalization witnesses (speaker resolver and batch privacy) are read just before the wipe; the main comparison still uses the documents and effects after erasure. CI's `invalid_binding` assertion in `verify.py` is unchanged. - `90d1799f` and `9dcf507b` are FIX-FIRST commits for the speaker witness. The speaker checks read the pre-wipe view on both sides. A departure receipt proves only the erasure. A Go row that existed before the wipe but has no resolver result is reported as `missing_in_go` / `speaker_resolver_unverified`. - Regression tests cover an untraced Go resolver result, an invalid Go speaker envelope, and a missing Go resolver result. - `884221b1` compares the pre-wipe conversation and derived documents across sides with the live rules, emitted under `/before_erasure`. The resolver gap comes from that comparison, once. Regression tests change speaker `assignments`, `structured.title` and the authenticated payload. - The 109 pre-wipe rows from the `cmd/jobd` conformance flow are diagnostic only, like jobd's other raw rows, and aren't counted. The serving `workerd` erasure run is required before integrated zero (SCA-3551). - `2b90f180` keeps effects and erasure checks for proved-absent Go rows and pairs post-wipe account operation receipts by operation type, generation and owner digest. Duplicate and mismatched receipts remain findings. - The current head runs the same binding validator on both pre-wipe views. Regressions cover missing jobs and mismatched fanout on Python and Go, and missing or mismatched Go fence fields. Findings carry a `/before_erasure` prefix. **Scope:** `backend-go/tools/replay/` and `backend/testing/finalization_replay/` only. **Verification** - At `9fa4bc15`, `go test ./tools/replay/...` and all 37 local preflight checks passed. Each of the six pre-wipe binding mutations fails with the previous comparator. The full local `./tools/replay/test.sh` passed on Firestore and Postgres, with 10/10 admission cases, 41/41 active cases completed, zero execution errors, zero `invalid_binding` rows, and the verifier’s negative mutations passing. - The paired serving runner in #26352 reran the pinned worker `0a0640ae` in all 41 cases. R7 held with a minimum margin of +2, zero execution errors, 163 diagnostic gap rows, zero unlabelled, and zero pre-wipe `invalid_binding` rows. - On Studio, at `96789fc5` (`go test ./tools/replay/...` passed again at `2ad9855d`): - `go test ./tools/replay/...` passes. - `pytest testing/finalization_replay`: 40 passed, 1 skipped. - `scripts/backend-python-format --check` is clean. - The managed pre-push gate passed. - Worker 1's emulator replays ran on the separate bundles, not on this combined head: - At `006671ae` with worker `aab6310d`: 41/41 cases, 0 execution errors, R7 41/41 with a minimum margin of +2, 164 diagnostic go_gap rows, 0 unlabelled, 0 failed Commit RPCs. - At `8ca3e1ae`: both `/conversation` rows clear. - At `2ad9855d`, from Worker 1: CI's `./tools/replay/test.sh` step, building `jobd` from this tree, passes with 0 `invalid_binding` rows. On the pinned `aab6310d` worker: R7 41/41 at +2, and 164 diagnostic gaps with 0 unlabelled, the same as at `96789fc5`. - At `9dcf507b`, from Worker 1: CI's `./tools/replay/test.sh` passes with 0 `invalid_binding` rows. On the pinned `aab6310d` worker: R7 41/41 at +2, and 164 diagnostic rows with 0 unlabelled. GitHub CI: all 65 checks pass at `9dcf507b`. - At `884221b1`, from Worker 1: `test.sh` passes with 0 `invalid_binding`. The pinned `aab6310d` run gives R7 41/41 at +2, with 164 rows and 0 unlabelled. - `9dcf507b` passed all 65 checks but didn't compare the pre-wipe views across sides. `2ad9855d` and `90d1799f` are earlier heads, kept for the record. - `96789fc5` is an earlier head, kept for the record: it failed the CI replay gate with 9 `invalid_binding` rows on `erase-removes-owner-and-jobs`. **Open item, outside this PR:** Python leaves a Firestore finalization job at `/effects/erasure/jobs_for_uid` after erasure. It's labelled `python_bug?` and tracked on SCA-4408 (Python fix #26310). Merge goes through Release intake. The Go lead signs off on parity on SCA-3551. 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- This is an auto-generated description by cubic. --> <a href="https://cubic.dev/pr/BasedHardware/omi/pull/26322?utm_source=github" target="_blank" rel="noopener noreferrer" data-no-image-dialog="true"><picture><source media="(prefers-color-scheme: dark)" srcset="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://www.cubic.dev/buttons/review-in-cubic-light.svg"><img alt="View guided diff" src="https://www.cubic.dev/buttons/review-in-cubic-light.svg"></picture></a> <a href="https://www.cubic.dev/action/auto-fix/pr/BasedHardware/omi/26322?returnTo=https%3A%2F%2Fgithub.com%2FBasedHardware%2Fomi%2Fpull%2F26322&source=description" target="_blank" rel="noopener noreferrer" data-no-image-dialog="true"><picture><source media="(prefers-color-scheme: dark)" srcset="https://www.cubic.dev/buttons/turn-on-auto-fix-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://www.cubic.dev/buttons/turn-on-auto-fix-light.svg"><img alt="Turn on auto-fix" src="https://www.cubic.dev/buttons/turn-on-auto-fix-light.svg"></picture></a> <!-- End of auto-generated description by cubic. -->
Scoped replacement for #26031 (SCA-3551 lane 7: the finalization replay oracle). It's based on
mainatf719b056and contains only replay tooling. It touches no serving path.Scope (45 + 1 files)
backend-go/tools/replay/: comparator, labels and witness tests.backend/testing/finalization_replay/: the Python replay harness and diagnostic tests.Makefile: theoracle-diagtarget.#26031 had picked up out-of-lane drift: MCP serving Python, generated API clients and the OpenAPI spec. All of it has been dropped here.
What the oracle encodes
attach_revision,attach_completedandattach_finalizedpresent and null on both sides. A dead letter has all four fields absent.by_design:replay_clockcovers profile clocks, resolver elapsed time, memory expiry (captured_at+ 172800 s) and the group 7 notes hash.by_design:generated_identitycovers group 12, andby_design:encrypted_envelopecovers the encrypted envelopes.Current reviewed head:
ec37b822b948a6e8f6c9b86bf11cbb1af7d2ad7bec37b822with workeraab6310d: 164 diagnostic Go gaps, 0 unlabelled, 0 execution failures. R7 holds on all 41 cases (Go ≤ Python), with a minimum margin of +2.Historical runs (earlier heads, kept for the record; they are not the current head)
672bfca3: two consecutive fresh runs with workeraab6310d. Each passed 41/41 with zero execution errors and zero diagnostic R7 overages. Both produced the same 164 normalized Go gaps, zero unlabelled. Every case matched the baseline Firestore reads, writes and deletes.85ef2d21: one smoke run gave the same 164 gaps and 0 unlabelled. The three terminal memo checks passed.983c0b51then added the pinned-formatter line inordinary_sync_retry.py. The commits after that, up toec37b822, address review findings.Merge goes through Release intake. The Go lead signs off on parity on SCA-3551.
🤖 Generated with Claude Code