Skip to content

test(backend): preserve recovery custody across job-store migration - #23648

Closed
Git-on-my-level wants to merge 4 commits into
mainfrom
lane/parity-pl049-pl050
Closed

Git-on-my-level wants to merge 4 commits into
mainfrom
lane/parity-pl049-pl050

Conversation

@Git-on-my-level

@Git-on-my-level Git-on-my-level commented Oct 26, 2026 •

Copy link
Copy Markdown
Member

Empty independent ASR recovery must keep positive speech in custody, and a stale GPU worker must not write evidence that can later authorize disposal. Port PL-049/050 from the backend target architecture parity ledger into the existing sim/Firestore/Postgres Store matrix.

The tests run the production scheduler, recovery coordinator, policy pinning, paid-intent protocol and privacy checks. They cover sub-second through near-full-unit speech, repeated delivery, genuine silence, unknown versus measured-zero VAD, foreign/expired leases, invalid input-bound receipts and racing privacy erasure. The existing emulator proof runner executes the new suite and now requires the emulator leg by default. No workflow or runtime behavior changes.

Rework 2026-11-01 (archmission, Plan A owner; lead c3d056):

  • Merged origin/main. No rebase and no force push. Conflicts resolved:
    • The recap fixture hunk is dropped. Main already pins that clock (_AT 18:00 UTC), so this branch's RECAP_AT change duplicated a landed fix. test_open_loops_recap_integration.py now equals main.
    • listen_pusher_pipeline.mdx keeps both additive sections.
  • PL-049 follows main's one Soniox second chance. Main a866d27 (10-30) gives Modulate-empty held units with positive speech one independent second chance, so the 10-26 assertion "no second provider at all" failed on every store. The case now pins the new contract: the second chance is spent at most once across repeated sweeps, and an uncertain call keeps audio, intent and custody held. Measured silence still settles without any paid call.

Why isn't this a shared primitive instead? These are migration acceptance tests over the existing shared Store, Scheduler and RecoveryStore primitives. They carry the #23603 incident prevention across implementations without adding another state machine or validator.

Validation:

  • Rework: OMI_REQUIRE_STORE_BACKENDS=all under a loopback Firestore emulator, with local Postgres 16 (glibc), via bin/omi-heavy. The run covered test_recovery_custody_conformance.py, test_store_conformance.py and the recap test: 140 passed, 1 skipped (the pre-existing simulator concurrency skip).
  • Original: 36 passed on all three stores, plus mutation checks. Allowing positive-speech terminal disposal makes all three simulator speech cases fail; dropping input-hash validation makes the foreign-input case fail.

Limits: vendor/strict-VAD/artifact boundaries are synthetic; this does not qualify real ASR quality or a deployed service. The Postgres factory uses its existing harness-only customer tables, so it does not prove the serving A4 cross-database bridge. No production access, deploy, config write or merge.

Product invariants affected

none

Failure-Class: FC-empty-asr-without-context-recovery
UI-Evidence: none -- backend conformance tests and their runner only

🤖 Generated with Claude Code

Failure-Class: FC-empty-asr-without-context-recovery

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-26T00:54:02.220639Z 1c0cab8 PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Git-on-my-level and others added 3 commits October 25, 2026 21:06
The unmodified main test fails five assertions before noon because its fixture and recap selection use different dates. Pass one explicit afternoon instant through the existing production input seam; keep every assertion and production behavior unchanged.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Conflict resolution only:
- backend/tests/unit/test_open_loops_recap_integration.py: take main's version. Main already pins the
  recap clock (_AT 18:00 UTC); this branch's RECAP_AT hunk duplicated that fix.
- backend/docs/listen_pusher_pipeline.mdx: keep both additive sections (PL-049/050 qualification note,
  then main's manual-merge completion section).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…second chance

Main a866d27 (10-30) gives Modulate-empty held units with positive speech one independent Soniox
second chance. The PL-049 case written 10-26 asserted no second provider at all, so it failed on every
store after the merge. It now pins the new contract: the second chance is spent at most once across
repeated sweeps, and an uncertain call keeps audio, intent and custody held. Measured silence still
settles without any paid call.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@Git-on-my-level

Copy link
Copy Markdown
Member Author

Folded into survivor #24591 (lane/lcinv, pushed head b8e0b1e0b3). As part of consolidating the open PR batch, origin/main and every other listed PR were merged into the survivor branch; all tests were kept. This PR is being closed as folded — its content lives on in #24591.

Carried as-is: test_recovery_custody_conformance.py, and the job-store run_proof line in run-emulator-proofs.sh (unioned with the newer PL-141 wording from #23929, keeping both the custody test and the sim,emulator requirement).

@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

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:

  • Project standards — Ensuring consistency across the codebase
  • User needs — Making sure changes align with what our users need
  • Code best practices — Maintaining code quality and maintainability
  • Project direction — Keeping aligned with our product principles and locked invariants

Before your next PR, please skim:

  • PRODUCT.md — product north star
  • Product invariants — locked rules (shared chat, memory tiers, agent control plane, integrations, brand)

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!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant