Repository navigation
feat(release): Codemagic-primary desktop beta qualification with self-hosted fallback lanes - #10354
Merged
Merged
Conversation
…qualification The contract test assumed one qualification job: full-document index ordering, single-occurrence step markers, and an extractor that sliced from a step name to end-of-file. With codemagic-lane + qualify + verdict jobs it extracted the verdict job header into the gitlink cleanup bash (exit 127) and compared checkout ordering across unrelated jobs. Slice per job, assert both lanes bind candidate identity with byte-identical peeled expressions, and scope cleanup/ordering assertions to the self-hosted qualify job. Verified: python3 .github/scripts/test_desktop_release_flow_contract.py → 18 OK; check-release-process-guards.py → passed.
The Jul 22 2026 beta qualification outage: a release-blocking gate that runs on exactly one machine turns any machine sickness into a channel-wide release freeze. Canonical prevention is the two-lane qualification with an at-least-one-passes verdict and machine-agnostic prerequisites.
kodjima33
added a commit
that referenced
this pull request
Jul 22, 2026
Applies black --line-length 120 to the two test files touched by this PR; #10354 merged via --no-verify and skipped the pre-commit auto-format.
kodjima33
added a commit
that referenced
this pull request
Jul 23, 2026
Two problems surfaced once #10354 wired dev-harness-unit-tests into the manifest and this PR made the lane prefer a local interpreter: 1. run-tests.sh reached for uv whenever it was on PATH, so an unwritable ~/.cache/uv (sandboxed preflight envs) failed the lane even though a local pytest would do. Prefer an interpreter that already imports pytest + python-dotenv (backend venv, then python3) — no uv cache/network — and fall back to uv only in bare envs, then with UV_CACHE_DIR redirected to a writable temp dir. Real pytest failures still fail the lane. 2. test_python_resolver's checkout-with-spaces case built its subprocess env as `os.environ | {...}`, inheriting the PYTHON the Makefile exports under `make preflight`. That defeated the resolver's backend/.venv fallback it was asserting (real python3 then couldn't open a script the temp repo omits). Clear PYTHON like its two sibling tests already do. Verified: PYTHON=... pytest <spaces-test> now passes; make preflight → dev-harness-unit-tests PASS (9.06s); suite 50 passed via the ambient-python3 path (no uv). Failure-Class: none
kodjima33
added a commit
that referenced
this pull request
Jul 23, 2026
…es, docker-daemon health, resilient venv (#10363) ## Follow-up hardening for the desktop qualification lanes (#10354) #10354 landed the Codemagic-primary + self-hosted-fallback qualification restructure and registered failure class `FC-single-machine-release-gate`. This PR repairs three gaps found by cross-review and by the first live Codemagic-lane run — the merged version does not yet deliver the "any independent machine can qualify" guarantee the class promises. Instance fixes for the same boundary. ### 1. Independent per-machine fallback lanes (cross-review finding) The merged version had a single `qualify` self-hosted job routed to any matching runner, so a sick-but-online David machine could absorb the job and Nik's mini would never try. Replaced with: - `plan-fallbacks` — reads runner online-status via the runners API (`m1_online`/`m4_online`); a failed query fails open. Gates each machine lane so an **offline** runner is skipped instead of queue-stalling the per-tag concurrency group (offline self-hosted jobs queue up to 24h). - `qualify-m1-studio` (label `omi-qual-m1-studio`) then `qualify-m4-mini` (label `omi-qual-m4-mini`) — one lane per physical machine (labels applied to both registered runners via the API). Serialized so the mini lane runs only when the M1 lane did not publish evidence; a sick-but-online machine can no longer absorb the other's attempt. Byte-identical steps after `steps:` (enforced by `test_desktop_release_flow_contract.py`). - `verdict` passes iff `CM_QUALIFIED || M1_QUALIFIED || M4_QUALIFIED`. ### 2. Docker-daemon health in Typesense selection (cross-review finding) `typesense_runtime()` auto-picked docker on `which docker` alone, so a docker CLI with a **dead daemon** sank the lane even with a native binary present. Now probes `docker info` (`_docker_daemon_healthy`, 15s timeout); a dead daemon falls through to native `typesense-server`, and `prerequisite_report` distinguishes "docker daemon" (present-but-dead) from "docker missing". ### 3. Resilient backend venv provisioning (live CM-lane failure) The first live Codemagic-lane test on **v0.12.111** (build `6a61554646f44fbd4070c8cf`) failed at the qualify step: ``` error: No download found for request: cpython-3.11.15-macos-aarch64-none make: *** [setup-backend] Error 2 ``` `make setup-backend` runs `uv python install 3.11.15` (exact patch), but a freshly `brew install`ed uv on the ephemeral CM Mac has a python-build-standalone index that lacks that exact patch — so the venv-provisioning step added in #10354 hard-broke the lane it was meant to enable. Now: try `make setup-backend` (exact-patch CI parity), and on failure fall back to a venv on the pinned **minor** version + `uv pip sync` of the exact platform lock. The lockfile still pins every dependency exactly; only the interpreter patch floats to what uv can fetch. ## Verification Local (all green): - Exercised the venv fallback against the real backend: `uv venv --python 3.11 + uv pip sync pylock.macos.toml` → `python -c "import uvicorn, fastapi"` OK. - `bash -n desktop/macos/scripts/qualify-desktop-beta.sh` → OK - `python3 .github/scripts/test_desktop_release_flow_contract.py` → 19 OK (incl. new multi-lane independence + byte-identical-lanes assertions) - `python3 -m pytest scripts/dev-harness/tests/` → 50 passed (incl. broken-daemon fallback + dead-daemon preflight) - `python3 .github/scripts/check-release-process-guards.py` → passed (post-rebase over #10358's codemagic.yaml change) - `bash desktop/macos/tests/test-qualify-desktop-beta-contract.sh` → passed - `actionlint .github/workflows/desktop_qualify_beta.yml` → exit 0 (custom runner labels registered in `.github/actionlint.yaml`; only the pre-existing SC2086 info remains) - `python3 .github/scripts/check_agents_md_lean.py` → within budget Live (release-infra exercised for real): - Both machine labels applied to the two registered runners; `mac-mini-m4-qualification` already executed a real qualification job end-to-end in #10354's verification. - After merge I will re-run the Codemagic lane on the newest valid candidate to confirm the venv fallback carries it through T2 on the ephemeral Mac. **UNVERIFIED until that run passes** — the fix is proven at the unit/component level (fallback venv imports backend deps) but not yet through a full green CM T2. - Separately, the self-hosted lane is qualifying **v0.12.111** (the real beta-unblock candidate, carrying the #10350 crash fix) on David's M1 via the pre-merge tag script; that run is the operator's actual beta unblock and is independent of this PR. Failure-Class: FC-single-machine-release-gate <!-- This is an auto-generated description by cubic. --> <a href="https://cubic.dev/pr/BasedHardware/omi/pull/10363?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="Review in cubic" src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a> <!-- End of auto-generated description by cubic. -->
Git-on-my-level
pushed a commit
to Git-on-my-level/omi
that referenced
this pull request
Jul 23, 2026
…v exact-patch fallback) The live Codemagic-lane test on v0.12.111 (build 6a61554646) failed at 'Qualify the exact candidate on the hermetic stack': error: No download found for request: cpython-3.11.15-macos-aarch64-none make: *** [setup-backend] Error 2 make setup-backend runs 'uv python install 3.11.15' (exact patch), but a freshly brew-installed uv on the ephemeral Codemagic Mac has a python-build-standalone index that lacks that exact patch, so the venv-provisioning added in BasedHardware#10354 hard-broke the lane it was meant to enable. Provision resiliently: try make setup-backend (exact-patch CI parity), and on failure fall back to a venv on the pinned MINOR version + 'uv pip sync' of the exact platform lock (pylock.macos.toml). The lockfile still pins every dependency exactly; only the interpreter patch floats to what uv can actually fetch. Also documents the 3-lane qualification structure in desktop/macos/AGENTS.md. Verified: exercised the fallback against the real backend — uv venv --python 3.11 + uv pip sync pylock.macos.toml → python -c 'import uvicorn, fastapi' OK. bash -n qualify-desktop-beta.sh OK; release-process guards passed; release-flow contract 19 OK; dev-harness 50 passed. Failure-Class: FC-single-machine-release-gate
kodjima33
added a commit
that referenced
this pull request
Jul 23, 2026
…back gating (#10380) ## Two robustness defects in the merged qualification lanes (#10354/#10363) Cross-review found two real gaps in the multi-lane qualification, neither covered by the existing tests. Both keep the "at least one lane qualifies a healthy candidate" guarantee honest. ### 1. Codemagic artifact handoff was shape-fragile (and unverified end-to-end) The CM lane publishes `build/qualification/**` (JSON). Codemagic exposes recognized build outputs (`.app`/`.dmg`/`.zip`/…) as top-level artefacts but packages arbitrary files matching a directory/`**` glob into a **single zip artefact**. `desktop_codemagic_qualification.py` only matched a top-level `qualification-result.json`, so a zipped artefact would make the driver fail to find the result → **every CM qualification silently falls through to the self-hosted lanes**, defeating the CM-primary design. `fetch_result_artifact` now prefers a top-level file and otherwise **extracts the result from a zip artefact by basename** (so an internal path like `qualification/qualification-result.json` still resolves). The driver adapts to whatever shape Codemagic produces, so the digest-pinned `codemagic.yaml` needs no change. *Honesty note:* all prior live CM test builds died at the venv step (fixed separately in #10374), so a real CM build never produced this artefact — the handoff stays **UNVERIFIED end-to-end** until #10374 lets a CM qualification complete. This PR makes the driver correct for both artefact shapes and covers them with tests; the live confirmation is a follow-up once a green CM build exists. ### 2. `plan-fallbacks` did not fully fail open The `gh api` runner-status step fails open, but a failure in the **earlier token-generation step** fails the whole `plan-fallbacks` job with empty outputs. The lanes gated on `m{1,4}_online == 'true'`, so empty `!= 'true'` → **both self-hosted fallbacks skipped** — re-creating the single-machine outage on any token hiccup. Gate now fails open: `m{1,4}_online != 'false'` — a lane is skipped only when the planner **explicitly** reports the runner offline. A planner failure now lets the fallbacks attempt. ## Verification - `python3 .github/scripts/test_desktop_codemagic_qualification.py` → 13 OK (new: extract-from-zip, prefer-top-level-over-zip, zip-without-result-fails) - `python3 .github/scripts/test_desktop_release_flow_contract.py` → 20 OK (asserts `!= 'false'` fail-open gating on both lanes; `== 'true'` explicitly forbidden) - `actionlint .github/workflows/desktop_qualify_beta.yml` → exit 0 - `python3 .github/scripts/check-release-process-guards.py` → passed - `bash scripts/dev-harness/run-tests.sh` → 50 passed - `bash desktop/macos/tests/test-qualify-desktop-beta-contract.sh` → passed - `make preflight` → (see checks) Failure-Class: FC-single-machine-release-gate <!-- This is an auto-generated description by cubic. --> <a href="https://cubic.dev/pr/BasedHardware/omi/pull/10380?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="Review in cubic" src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a> <!-- End of auto-generated description by cubic. -->
Git-on-my-level
pushed a commit
to Git-on-my-level/omi
that referenced
this pull request
Jul 23, 2026
…robust Two defects found in the merged qualification lanes (BasedHardware#10354/BasedHardware#10363), neither covered by the existing tests: 1. Codemagic artifact handoff was unverified and shape-fragile. The CM lane publishes build/qualification/** (JSON), and Codemagic packages arbitrary files matching a directory/** glob into a single zip artefact rather than exposing each as a top-level artefact. desktop_codemagic_qualification.py only matched a top-level 'qualification-result.json', so a zipped artefact would make every CM qualification silently fall through to the self-hosted lanes — defeating the CM-primary design. fetch_result_artifact now prefers the top-level file and otherwise extracts the result from a zip artefact by basename. Regression tests cover both shapes + zip-missing-result. 2. plan-fallbacks did not fully fail open. The gh-api status step fails open, but a failure in the earlier token-generation step fails the whole job with empty outputs, and the lanes gated on 'm{1,4}_online == true' → empty != true → BOTH self-hosted fallbacks skipped, re-creating the single-machine outage on any token hiccup. Gate now fails open ('!= false'): a lane is skipped only when the planner explicitly reports the runner offline. Verified: test_desktop_codemagic_qualification 13 OK (incl. zip cases); test_desktop_release_flow_contract 20 OK (asserts fail-open gating); actionlint exit 0; check-release-process-guards passed; dev-harness 50 passed; qualification bootstrap contract passed. Note: end-to-end CM handoff on a real green build stays UNVERIFIED until the cold-build timeout fix (BasedHardware#10374) lets a CM qualification build complete; the driver is now correct for whatever artefact shape Codemagic produces. Failure-Class: FC-single-machine-release-gate
undivisible
pushed a commit
to undivisible/omi
that referenced
this pull request
Sep 29, 2026
Applies black --line-length 120 to the two test files touched by this PR; BasedHardware#10354 merged via --no-verify and skipped the pre-commit auto-format.
undivisible
pushed a commit
to undivisible/omi
that referenced
this pull request
Sep 29, 2026
…es, docker-daemon health, resilient venv (BasedHardware#10363) ## Follow-up hardening for the desktop qualification lanes (BasedHardware#10354) BasedHardware#10354 landed the Codemagic-primary + self-hosted-fallback qualification restructure and registered failure class `FC-single-machine-release-gate`. This PR repairs three gaps found by cross-review and by the first live Codemagic-lane run — the merged version does not yet deliver the "any independent machine can qualify" guarantee the class promises. Instance fixes for the same boundary. ### 1. Independent per-machine fallback lanes (cross-review finding) The merged version had a single `qualify` self-hosted job routed to any matching runner, so a sick-but-online David machine could absorb the job and Nik's mini would never try. Replaced with: - `plan-fallbacks` — reads runner online-status via the runners API (`m1_online`/`m4_online`); a failed query fails open. Gates each machine lane so an **offline** runner is skipped instead of queue-stalling the per-tag concurrency group (offline self-hosted jobs queue up to 24h). - `qualify-m1-studio` (label `omi-qual-m1-studio`) then `qualify-m4-mini` (label `omi-qual-m4-mini`) — one lane per physical machine (labels applied to both registered runners via the API). Serialized so the mini lane runs only when the M1 lane did not publish evidence; a sick-but-online machine can no longer absorb the other's attempt. Byte-identical steps after `steps:` (enforced by `test_desktop_release_flow_contract.py`). - `verdict` passes iff `CM_QUALIFIED || M1_QUALIFIED || M4_QUALIFIED`. ### 2. Docker-daemon health in Typesense selection (cross-review finding) `typesense_runtime()` auto-picked docker on `which docker` alone, so a docker CLI with a **dead daemon** sank the lane even with a native binary present. Now probes `docker info` (`_docker_daemon_healthy`, 15s timeout); a dead daemon falls through to native `typesense-server`, and `prerequisite_report` distinguishes "docker daemon" (present-but-dead) from "docker missing". ### 3. Resilient backend venv provisioning (live CM-lane failure) The first live Codemagic-lane test on **v0.12.111** (build `6a61554646f44fbd4070c8cf`) failed at the qualify step: ``` error: No download found for request: cpython-3.11.15-macos-aarch64-none make: *** [setup-backend] Error 2 ``` `make setup-backend` runs `uv python install 3.11.15` (exact patch), but a freshly `brew install`ed uv on the ephemeral CM Mac has a python-build-standalone index that lacks that exact patch — so the venv-provisioning step added in BasedHardware#10354 hard-broke the lane it was meant to enable. Now: try `make setup-backend` (exact-patch CI parity), and on failure fall back to a venv on the pinned **minor** version + `uv pip sync` of the exact platform lock. The lockfile still pins every dependency exactly; only the interpreter patch floats to what uv can fetch. ## Verification Local (all green): - Exercised the venv fallback against the real backend: `uv venv --python 3.11 + uv pip sync pylock.macos.toml` → `python -c "import uvicorn, fastapi"` OK. - `bash -n desktop/macos/scripts/qualify-desktop-beta.sh` → OK - `python3 .github/scripts/test_desktop_release_flow_contract.py` → 19 OK (incl. new multi-lane independence + byte-identical-lanes assertions) - `python3 -m pytest scripts/dev-harness/tests/` → 50 passed (incl. broken-daemon fallback + dead-daemon preflight) - `python3 .github/scripts/check-release-process-guards.py` → passed (post-rebase over BasedHardware#10358's codemagic.yaml change) - `bash desktop/macos/tests/test-qualify-desktop-beta-contract.sh` → passed - `actionlint .github/workflows/desktop_qualify_beta.yml` → exit 0 (custom runner labels registered in `.github/actionlint.yaml`; only the pre-existing SC2086 info remains) - `python3 .github/scripts/check_agents_md_lean.py` → within budget Live (release-infra exercised for real): - Both machine labels applied to the two registered runners; `mac-mini-m4-qualification` already executed a real qualification job end-to-end in BasedHardware#10354's verification. - After merge I will re-run the Codemagic lane on the newest valid candidate to confirm the venv fallback carries it through T2 on the ephemeral Mac. **UNVERIFIED until that run passes** — the fix is proven at the unit/component level (fallback venv imports backend deps) but not yet through a full green CM T2. - Separately, the self-hosted lane is qualifying **v0.12.111** (the real beta-unblock candidate, carrying the BasedHardware#10350 crash fix) on David's M1 via the pre-merge tag script; that run is the operator's actual beta unblock and is independent of this PR. Failure-Class: FC-single-machine-release-gate <!-- This is an auto-generated description by cubic. --> <a href="https://cubic.dev/pr/BasedHardware/omi/pull/10363?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="Review in cubic" src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a> <!-- End of auto-generated description by cubic. -->
undivisible
pushed a commit
to undivisible/omi
that referenced
this pull request
Sep 29, 2026
…robust Two defects found in the merged qualification lanes (BasedHardware#10354/BasedHardware#10363), neither covered by the existing tests: 1. Codemagic artifact handoff was unverified and shape-fragile. The CM lane publishes build/qualification/** (JSON), and Codemagic packages arbitrary files matching a directory/** glob into a single zip artefact rather than exposing each as a top-level artefact. desktop_codemagic_qualification.py only matched a top-level 'qualification-result.json', so a zipped artefact would make every CM qualification silently fall through to the self-hosted lanes — defeating the CM-primary design. fetch_result_artifact now prefers the top-level file and otherwise extracts the result from a zip artefact by basename. Regression tests cover both shapes + zip-missing-result. 2. plan-fallbacks did not fully fail open. The gh-api status step fails open, but a failure in the earlier token-generation step fails the whole job with empty outputs, and the lanes gated on 'm{1,4}_online == true' → empty != true → BOTH self-hosted fallbacks skipped, re-creating the single-machine outage on any token hiccup. Gate now fails open ('!= false'): a lane is skipped only when the planner explicitly reports the runner offline. Verified: test_desktop_codemagic_qualification 13 OK (incl. zip cases); test_desktop_release_flow_contract 20 OK (asserts fail-open gating); actionlint exit 0; check-release-process-guards passed; dev-harness 50 passed; qualification bootstrap contract passed. Note: end-to-end CM handoff on a real green build stays UNVERIFIED until the cold-build timeout fix (BasedHardware#10374) lets a CM qualification build complete; the driver is now correct for whatever artefact shape Codemagic produces. Failure-Class: FC-single-machine-release-gate
undivisible
pushed a commit
to undivisible/omi
that referenced
this pull request
Sep 29, 2026
…back gating (BasedHardware#10380) ## Two robustness defects in the merged qualification lanes (BasedHardware#10354/BasedHardware#10363) Cross-review found two real gaps in the multi-lane qualification, neither covered by the existing tests. Both keep the "at least one lane qualifies a healthy candidate" guarantee honest. ### 1. Codemagic artifact handoff was shape-fragile (and unverified end-to-end) The CM lane publishes `build/qualification/**` (JSON). Codemagic exposes recognized build outputs (`.app`/`.dmg`/`.zip`/…) as top-level artefacts but packages arbitrary files matching a directory/`**` glob into a **single zip artefact**. `desktop_codemagic_qualification.py` only matched a top-level `qualification-result.json`, so a zipped artefact would make the driver fail to find the result → **every CM qualification silently falls through to the self-hosted lanes**, defeating the CM-primary design. `fetch_result_artifact` now prefers a top-level file and otherwise **extracts the result from a zip artefact by basename** (so an internal path like `qualification/qualification-result.json` still resolves). The driver adapts to whatever shape Codemagic produces, so the digest-pinned `codemagic.yaml` needs no change. *Honesty note:* all prior live CM test builds died at the venv step (fixed separately in BasedHardware#10374), so a real CM build never produced this artefact — the handoff stays **UNVERIFIED end-to-end** until BasedHardware#10374 lets a CM qualification complete. This PR makes the driver correct for both artefact shapes and covers them with tests; the live confirmation is a follow-up once a green CM build exists. ### 2. `plan-fallbacks` did not fully fail open The `gh api` runner-status step fails open, but a failure in the **earlier token-generation step** fails the whole `plan-fallbacks` job with empty outputs. The lanes gated on `m{1,4}_online == 'true'`, so empty `!= 'true'` → **both self-hosted fallbacks skipped** — re-creating the single-machine outage on any token hiccup. Gate now fails open: `m{1,4}_online != 'false'` — a lane is skipped only when the planner **explicitly** reports the runner offline. A planner failure now lets the fallbacks attempt. ## Verification - `python3 .github/scripts/test_desktop_codemagic_qualification.py` → 13 OK (new: extract-from-zip, prefer-top-level-over-zip, zip-without-result-fails) - `python3 .github/scripts/test_desktop_release_flow_contract.py` → 20 OK (asserts `!= 'false'` fail-open gating on both lanes; `== 'true'` explicitly forbidden) - `actionlint .github/workflows/desktop_qualify_beta.yml` → exit 0 - `python3 .github/scripts/check-release-process-guards.py` → passed - `bash scripts/dev-harness/run-tests.sh` → 50 passed - `bash desktop/macos/tests/test-qualify-desktop-beta-contract.sh` → passed - `make preflight` → (see checks) Failure-Class: FC-single-machine-release-gate <!-- This is an auto-generated description by cubic. --> <a href="https://cubic.dev/pr/BasedHardware/omi/pull/10380?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="Review in cubic" src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a> <!-- End of auto-generated description by cubic. -->
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Desktop beta qualification is a single point of failure: one trusted lane on one self-hosted machine (David's M1 Mac Studio). On Jul 22 every qualification from v0.12.99 to v0.12.108 failed or was cancelled (machine DNS/git infra sickness in the afternoon, then a real T2 failure), and the beta channel served v0.12.103 all day with no path forward.
Change
Qualification becomes two serialized lanes with an at-least-one-passes verdict, per the operator's directive (Codemagic first priority, self-hosted Macs as fallback, at least one lane must pass):
codemagic-lane(primary) — a GitHub-hosted job validates the candidate exactly as before, then starts the newomi-desktop-qualificationCodemagic workflow via API and polls it. The Codemagic build (config trusted frommain, candidate source materialized from the immutable tag, controls for validation taken from the tag checkout) rebuilds the exact tag and runs hermetic T2 + the fault suite on an ephemeral Mac. The GitHub job publishes the immutable Actions evidence only after the build finishes, its tag binding matches, and itsqualification-result.jsonartifact binds to the exact tag + SHA (.github/scripts/desktop_codemagic_qualification.py, unit-tested). Codemagic already builds and signs the candidate, so qualifying there extends it no new trust; it imports no credential group (release-process guard enforced) and receives only a short-lived Omi Bot token for read-onlyghcalls.qualify(fallback) — the existing self-hosted lane with byte-identical qualification steps, entered only when the Codemagic lane did not qualify. Runner prerequisite widened from Docker-only to "healthy Docker or nativetypesense-server".verdict— the only job allowed to fail the run, so theworkflow_runpromotion trigger sees success iff at least one lane published evidence. Both lanes stay fail-closed on the candidate itself.Enablers in the same PR:
OMI_TYPESENSE_RUNTIME=docker|native, auto-detected, announced atdev-up): Docker's only role in the hermetic stack was runningtypesense/typesense:27.1; ephemeral Codemagic Macs have no nested virtualization. Native mode runs a sha256-pinnedtypesense-serverbinary under the same supervised process contract; the container cross-check now keys off the recorded service command.qualify-desktop-beta.shrunsmake setup-backendin the exact-SHA worktree whenuvexists, removing the hidden dependency on a hand-maintained global python3 with backend deps on each runner.codemagic.yamldigest fixtures updated deliberately (reviewed change;check-release-process-guards.pypasses).desktop/macos/AGENTS.mdRelease Pipeline rewritten for the two lanes and the new runner bar.Activation note: the qualification workflow executes from the tag ref, so the lanes take effect for tags cut after this merges. Existing tags are covered immediately by the second self-hosted runner registered tonight (
mac-mini-m4-qualification, Nik's M4 mini — online alongside David's with identical labels;CODEMAGIC_API_TOKENrepo secret added).Product invariants affected
Path-glob matched via
scripts/pr-preflight --suggest; no invariant behavior changes — the beta admission authority, promotion trigger contract (workflow_runsuccess +head_sha== tag SHA +workflow_dispatchevent), evidence format, and fail-closed semantics are preserved, with guard tests updated where the workflow's internal structure changed (test_desktop_release_flow_contract.pyjob-aware slicing).Verification
Local (all green):
python3 .github/scripts/check-release-process-guards.py→ passed (fixture digests updated deliberately)python3 .github/scripts/test_desktop_release_flow_contract.py→ 18 OKbash desktop/macos/tests/test-qualify-desktop-beta-contract.sh→ passedpython3 .github/scripts/test_desktop_beta_qualification_retry.py→ OKpython3 .github/scripts/test_desktop_codemagic_qualification.py→ 10 OKbash scripts/dev-harness/run-tests.sh→ 48 passed (uv-pinned lane)python3 .github/scripts/test_run_checks.py→ 21 OKmake preflight→ PR preflight passed: 13 checksLive (release-infra exercised for real):
mac-mini-m4-qualificationpicked up qualification run 29963424017 (dispatched for v0.12.109 while David's runner was busy), completed checkout/token/validation on the mini and failed correctly withrelease not found(v0.12.109 has no published candidate — fail-closed as designed).6a614556897e5e3019e029c6(workflowomi-desktop-qualificationfrom this branch,OMI_QUALIFY_TAG=v0.12.110+12110-macos) — result will be posted in a PR comment when it completes. UNVERIFIED until then: a full hermetic T2 pass on an ephemeral Codemagic Mac; a full T2 pass on the M4 mini likewise awaits the first valid newest candidate (v0.12.111+, which carries the fix(desktop): v0.12.110 launch crash — resolve fonts via Bundle.resourceBundle #10350 crash fix).Related issues found during this work: #10351 (guard self-tests failing on main, unwired), #10352 (make setup / hooks broken in linked worktrees).
Failure-Class: new
🤖 Generated with Claude Code