Skip to content

test(backend): carry committed projection obligations into Store conformance - #25832

Merged
Git-on-my-level merged 2 commits into
mainfrom
lane/parity-PL-665
Nov 27, 2026
Merged

Git-on-my-level merged 2 commits into
mainfrom
lane/parity-PL-665

Conversation

@Git-on-my-level

@Git-on-my-level Git-on-my-level commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

What changed and why

Extend the existing Store conformance suite with parity cases PL-665–667 for committed projection obligations from #25724. A lost wake must leave durable work for discovery, due pages must stay bounded and stable, and a stale delivery must be unable to settle a current claim.

The same cases exercise the Python Firestore Store, replacement Postgres Store and in-memory simulator. The Go rewrite can use them as acceptance cases under batch contract B21. Its batch projector remains a separate implementation and verification step.

Product invariants affected

none

How it was verified

  • Ran the Store and recovery-custody suites with OMI_REQUIRE_STORE_BACKENDS=all under a private loopback Firestore emulator and local Postgres. They passed with 326 passes and seven existing backend-specific skips.
  • Reran the final focused selectors across all three required stores. All 18 cases passed, including 15 new cases, with zero skips or xfails. All 11 existing projection-outbox unit cases passed.
  • The existing Emulator Proofs runner requires the simulator and Firestore legs in CI. Its Store proof heading now identifies the committed projection debt sub-suite.

Tests

  • test_pl665_projection_debt_commits_with_result aborts after the real merge has scheduled its writes, then verifies complete rollback and wake-free discovery after restart.
  • test_pl666_projection_due_page_filters_before_limiting checks kind and time exclusion, the inclusive cutoff, ID ties and visibility of the next key after a claim.
  • test_pl667_projection_settlement_checks_lease_and_canonical_state checks exact lease expiry, stale token and revision refusal, bounded retry and canonical completed, erased and held dispositions.

Suite path is backend/tests/integration/test_store_conformance.py.

UI evidence

UI-Evidence: none -- shared backend tests only

Failure class

Failure-Class: FC-unresolved-head-blocks-projection

View guided diff Turn on auto-fix

🤖 Generated with Claude Code

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-27T08:42:54.349485Z a4903d2 New commits
ℹ️ 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.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 72abcb2292

ℹ️ 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".



def test_pl665_projection_debt_commits_with_result(h, monkeypatch):
from utils.batch_pipeline import scheduler as scheduler_module

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Move the scheduler module import to module scope

The new function-local import violates the applicable backend/AGENTS.md requirement that “All imports [be] at module top level — never inside functions.” Move scheduler_module into the module-level imports; the test can still monkeypatch its monotonic attribute without deferring the import.

AGENTS.md reference: backend/AGENTS.md:L168-L168

Useful? React with 👍 / 👎.

@Git-on-my-level
Git-on-my-level merged commit 8075b8c into main Nov 27, 2026
69 checks passed
@Git-on-my-level
Git-on-my-level deleted the lane/parity-PL-665 branch November 27, 2026 10:26
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