fix(ci): prove Unity cleanup before lock release#270
Conversation
…ce-lifecycle # Conflicts: # .github/workflows/perf-numbers.yml # .github/workflows/release.yml # .github/workflows/unity-benchmarks.yml # .github/workflows/unity-gameci-experiment.yml # .github/workflows/unity-tests.yml # scripts/__tests__/ci-aggregate-workflow.test.js
|
Copilot review Please review cleanup proof classification, non-masking timeout behavior, and all lock-window contracts. |
|
Cursor (@cursor) review Please review cleanup proof classification, non-masking timeout behavior, and all lock-window contracts. |
There was a problem hiding this comment.
Pull request overview
This PR strengthens CI’s licensed Unity “lock window” lifecycle by emitting a fail-closed cleanup proof from the return-unity-license composite action and wiring that proof into lock release steps across all Unity-licensed workflows, with contract tests enforcing the acquire → work → cleanup → release ordering.
Changes:
- Add a fail-closed
resource-safeoutput to.github/actions/return-unity-license(defaultsfalse, flipstrueonly on proven successful return conditions, and still never fails the job). - Update all six Unity lock windows to: assign an explicit
idto the return step, bound it with a 5-minute step timeout, and passresource-safeintorelease-build-lock@v1. - Extend
scripts/__tests__/ci-aggregate-workflow.test.jswith workflow-contract tests for ordering and for return-action proof classifications.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
scripts/__tests__/ci-aggregate-workflow.test.js |
Adds contract tests enforcing six Unity lock windows’ lifecycle ordering and proof wiring, plus proof-classification assertions for the return action. |
.github/workflows/unity-tests.yml |
Adds return_unity_license step id + timeout and forwards resource-safe into the lock release step. |
.github/workflows/unity-gameci-experiment.yml |
Updates comment to reflect proof limitations, adds return step id + timeout, forwards resource-safe into lock release. |
.github/workflows/unity-benchmarks.yml |
Adds return step id + timeout and forwards resource-safe into the lock release step. |
.github/workflows/release.yml |
Adds return step id + timeout in both Unity jobs and forwards resource-safe into each lock release step. |
.github/workflows/perf-numbers.yml |
Adds return step id + timeout and forwards resource-safe into the lock release step. |
.github/actions/return-unity-license/action.yml |
Introduces resource-safe composite output and sets it fail-closed unless return is proven successful. |
Addressed in 2f8866c: the six bounded |
|
Copilot review Please review exact head: all cleanup timeouts are non-masking, and the GameCI cleanup documentation now matches its provisioned-editor proof behavior. |
|
Cursor (@cursor) review Please review exact head: all cleanup timeouts are non-masking, and the GameCI cleanup documentation now matches its provisioned-editor proof behavior. |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit b2e9793. Configure here.
Reviewed exact head
|
|
Copilot review Please review exact head: the lifecycle contract now explicitly rejects any missing acquire/work/cleanup/release step before checking order. |
|
Cursor (@cursor) review Please review exact head: the lifecycle contract now explicitly rejects any missing acquire/work/cleanup/release step before checking order. |
Dispatch throughput (Unity 6000.3.16f1)Runner: 13th Gen Intel(R) Core(TM) i9-13900KF, 24C/32T @ 3000MHz; 64GB DDR5@4200; NVIDIA GeForce RTX 3060; Microsoft Windows 11 Pro N (10.0.26200) Regenerated by CI from commit Latest CI benchmark run: Unity 6000.3.16f1, commit Runner: 13th Gen Intel(R) Core(TM) i9-13900KF, 24C/32T @ 3000MHz; 64GB DDR5@4200; NVIDIA GeForce RTX 3060; Microsoft Windows 11 Pro N (10.0.26200) Dispatch throughput - Standalone (IL2CPP)Platform: Standalone IL2CPP x64 Release (WindowsPlayer; Unity 6000.3.16f1).
Dispatch throughput - PlayMode (Mono)Platform: Editor PlayMode Mono x64 Release (WindowsEditor; Unity 6000.3.16f1).
Library comparison - throughput (Standalone (IL2CPP))
Library comparison - GC allocations per 10k ops (PlayMode (Mono))
Library comparison - GC allocated bytes per 10k ops (PlayMode (Mono))
|
DxMessaging perf deltas vs master baseline (Unity 6000.3.16f1, Standalone IL2CPP)Regenerated by CI (run logs). Changed beyond tolerance: yes. Regression gate: passed. Reading the Delta column: the sign is normalized so
|
Confirmed in |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 12dc1b1. Configure here.
|
Cursor (@cursor) review Please review exact head 957e109: cross-workflow missing-job diagnostics now include file and job id. |
Confirmed in |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 957e109. Configure here.
Summary
Verification
Depends on Ambiguous-Interactive/ambiguous-organization-build-lock#25.
Note
Medium Risk
Changes how org Unity locks are released when license return is unproven (depends on ambiguous-organization-build-lock#25); mis-signaling could quarantine runners or leak seats, though return steps remain non-fatal to job outcome.
Overview
Adds fail-closed Unity license cleanup proof so organization lock release can tell a confirmed seat return from an uncertain one, without making the return step fail the job.
The
return-unity-licensecomposite now exposes aresource-safeoutput (defaultsfalse; only settrueon exit code 0 or the existing allowlisted nonzero log pattern). Unity workflows give the return step anid, a 5-minute timeout,continue-on-error: true, and passresource-safeintorelease-build-lock@v1on the following Release organization Unity lock step. The same pattern is applied across six licensed windows (unity-tests, benchmarks, perf, release editmode/unitypackage, GameCI experiment); GameCI’s comment now treats the backstop as real using the provisioned editor path instead of documenting a no-op.ci-aggregate-workflow.test.jslocks in acquire → licensed work → return → release ordering and the return action’s non-maskingexit 0contract.Reviewed by Cursor Bugbot for commit 957e109. Bugbot is set up for automated code reviews on this repo. Configure here.