Skip to content

fix(testing): verify Sync worker fencing under processing hold - #23935

Merged
Git-on-my-level merged 4 commits into
mainfrom
lane/gauntlet-holdfix
Oct 29, 2026
Merged

Git-on-my-level merged 4 commits into
mainfrom
lane/gauntlet-holdfix

Conversation

@Git-on-my-level

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

Copy link
Copy Markdown
Member

The Sync Cloud Tasks concurrency gauntlet must hold paid STT inside the upload worker lease. PR #23919 (merge 0dee519a) deferred full note processing until merge settlement, so waiting for that processor could never enter the gate. Current main already moved the call to STT; this finishes that fixture contract and makes the hold behavior executable.

  • Rename the gate, evidence and diagnostics to STT throughout the fixture and its callers.
  • Pin SYNC_PROCESSING_HOLD_ENABLED=true for normal scenarios. The held concurrency scenario verifies one STT call, Redis fencing before pipeline work and during STT, completed upload/ledger readback, pending conversation hold, and a durable deferred enrichment obligation with zero full-processor calls.
  • Run the same concurrency scenario with the hold disabled and require exactly one eagerly persisted full-processing result. Terminal duplicate delivery must repeat neither STT nor full processing in either mode.

Product behavior, worker budgets and CI timeouts are unchanged.

Failure-Class: none

This is test-fixture phase drift after a deliberate product scheduling change; no existing semantic failure class describes it. Why isn't this a shared primitive instead? Both hold modes use the same STT gate and _assert_full_processing_policy verifier in the existing blocking emulator gauntlet, rather than adding a separate guard. The regression instance is merged PR #23919, with the supplied bisect showing its parent passes and merge fails waiting for the processor gate.

Product invariants affected

none (test harness and fixture only)

Validation

  • Related units: 154 passed across test_sync_cloud_tasks_stack_ci_wiring.py, test_sync_stack_postgres_hook.py, test_sync_processing_hold.py and test_sync_reprocess_coalesce.py (separate pytest processes).
  • Full gauntlet: passed via nice -n 10 backend/testing/sync_cloud_tasks_stack/run.sh --state-dir /Volumes/Ephemeral/scratch/gauntlet-holdfix-20261029/full, under omi-heavy (both hold modes, all legacy Sync and batch scenarios, plus 5 passing Firestore shard-spread integration tests).
  • Preflight: make preflight passed all 33 selected checks; scripts/pr-preflight --pr-body-file also passed all 33 checks on commit d3981e1de54.
  • GCP tier: none; all services are local emulators/fakes.

🤖 Generated with Claude Code

View guided diff Turn on auto-fix

Main CI follow-up

The backend unit failure is independent of the Sync gauntlet: main currently fails tests/unit/test_app_client_schema_inventory.py::test_inventory_separates_generated_backed_adapters_from_raw_manual_dtos because account deletion is the remaining manual Dart response adapter after #23873/#23897. The fix is split into PR #23936. This PR excludes the app change; its unit checks need a rerun after the main-branch fix lands.

Make the gauntlet gate explicitly STT-owned and exercise concurrent deliveries with the processing hold enabled and disabled. Verify durable deferred enrichment versus eager full processing, including terminal duplicate delivery.

Failure-Class: none

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

chatgpt-codex-connector Bot commented Oct 29, 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-29T03:53:11.814287Z 72b616b 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.

Git-on-my-level and others added 2 commits October 29, 2026 09:57
Register the existing OpenAPI deletion response schemas in the users wire generator and use them in the account-deletion adapter. Preserve the conservative legacy normalization for grace, deadlines, counts and pending deletion acknowledgements.

This fixes the sole pre-existing CI failure on the Sync stack gauntlet PR without relaxing the zero-manual-DTO assertion.

Failure-Class: none

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This reverts commit 4fae5f1. The account-deletion wire-model repair is independent of the Sync gauntlet and is being sent in its own PR to clear the existing main unit failure.

Failure-Class: none

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Git-on-my-level added a commit that referenced this pull request Oct 29, 2026
…23936)

## Summary

- Generate Dart wire models for the account deletion status, action, and
restore responses already defined in OpenAPI.
- Decode account deletion API responses through those generated types
while preserving legacy aliases and conservative normalization.
- Add coverage for generated-backed responses and preserve the existing
deletion behavior.

This is separate from #23935: it fixes an existing main-branch backend
unit failure after the account deletion API changes in #23873 and
#23897.
`test_app_client_schema_inventory.py::test_inventory_separates_generated_backed_adapters_from_raw_manual_dtos`
reported one remaining manual Dart response adapter,
`account_deletion.dart`.

## Verification

- `backend/test.sh` with
`BACKEND_UNIT_TEST_FILE_LIST=tests/unit/test_app_client_schema_inventory.py`
under `nice`: 14 passed.
- `cd app && flutter test
test/unit/backend/http/deletion_contract_test.dart`: 6 passed.
- `cd backend && .venv/bin/python scripts/generate_dart_models.py
--group users --check`: passed.
- `cd app && dart run build_runner build --delete-conflicting-outputs`:
completed; no tracked generated-file changes.

## Metadata

Product invariants affected: none

Failure-Class: none

UI-Evidence: none


<!-- This is an auto-generated description by cubic. -->
<a
href="https://cubic.dev/pr/BasedHardware/omi/pull/23936?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/23936?returnTo=https%3A%2F%2Fgithub.com%2FBasedHardware%2Fomi%2Fpull%2F23936&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. -->
@Git-on-my-level
Git-on-my-level merged commit 1013e10 into main Oct 29, 2026
56 checks passed
@Git-on-my-level
Git-on-my-level deleted the lane/gauntlet-holdfix branch October 29, 2026 04:05
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