Finalize persistent-Mac compile fallback routing
Summary
Finish the persistent-Mac compile pilot on top of #13411 without carrying the stale history from #13425.
- keep the required hosted
macOS compile admissionjob off the persistent-route critical path; - allocate the hosted macOS runner immediately, restore exact reusable products first, then perform a ready-only producer observation from inside that already-running job; queued/running/absent producers fall through to hosted compilation immediately;
- publish an explicit GitHub-selected source-identity validity bit and gate persistent request/observation on it, so ambiguous/octopus source identity falls cleanly to hosted admission;
- preserve the default-branch router as the only Actions-write/dispatch owner;
- keep the current cancellation-aware
RetryWaitimplementation for the default-branch dispatcher while the required hosted path uses a nonblocking ready-only observation; - close the mapping-form self-hosted runner guard gap by inspecting
group:andlabels:lines and exempting only the exact persistent producer mapping; - update focused contract tests and operator docs.
The canonical workload implementation remains source-exact: source commits older than #13411 lack the profile registry and intentionally fall back hosted. No newer semantic runner is injected into an older SOURCE_SHA.
Supersedes the remaining landing delta from #13425 once #13411 is merged.
Related: #13198, #13411, #13425. Glaeda: teamleaderleo/glaeda#1084.
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.
Summary by cubic
Finalizes the persistent-Mac compile pilot so the required hosted macOS admission job no longer waits on a separate route job. The admission job allocates the macOS runner immediately, restores any exact reusable product first, and then makes a single nonblocking, read-only check of the persistent producer from inside the already-running job.
- Removes the
persistent-mac-compile-routejob and moves its observe-only logic intomacos-compile-admission, keeping the default-branch router as the only workflow with Actions write/dispatch authority. - Adds a
--ready-onlyobservation mode that uses the producer only when its compile job is already completed, falling back hosted for absent, queued, or running producers, and to the producer conclusion when completed unsuccessfully. Ready-only observation drops the queue and execution wait budgets entirely and refuses to run without--observe-only. - Adds an explicit
source_identity_validbit from thechangesjob and gates persistent request/observation on it, so ambiguous or octopus source identities fall back cleanly to hosted admission instead of failing the step. - Extends the self-hosted runner guard to treat
cmux-persistent-compileas a fleet selector and inspect mapping-formgroup:andlabels:selection lines, exempting only the exact persistent producer mapping. - Fixes admission timing accounting so route observation is no longer double-counted now that it runs inside the already-allocated admission job.