fix[notask]: dispatch runs now cancel previous same-branch run#2809
Open
tobi-legan wants to merge 1 commit into
Open
fix[notask]: dispatch runs now cancel previous same-branch run#2809tobi-legan wants to merge 1 commit into
tobi-legan wants to merge 1 commit into
Conversation
The concurrency group fallback used github.run_id for non-PR triggers, making every workflow_dispatch a unique group. Multiple dispatches on the same branch ran in parallel, competing for the same DF device slots. Switch to github.ref so same-branch dispatches cancel the previous run — the cancel handler already calls stop-run which frees Device Farm devices immediately. Affects all 16 on-pr-*.yml workflows. Co-authored-by: Cursor <cursoragent@cursor.com>
Contributor
Review StatusCurrent Status: ❌ PENDING Pending reviews: Needs 1 Management or Team Lead, and 1 more from Management, Team Lead, or Member. |
Contributor
Author
Test ResultsTested by triggering two
The concurrency group with |
Contributor
Tier-based Approval Status |
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.
Summary
github.run_idfor non-PR triggers (workflow_dispatch), making every dispatch a unique group. Multiple dispatches on the same branch ran in parallel, all competing for the same DF device slots.github.refso same-branch dispatches cancel the previous run. The cancel handler already callsstop-runwhich frees Device Farm devices immediately.on-pr-*.ymlworkflows.Context
Part of QIP: Reduce LLM Mobile CI Run Time. DF device concurrency is the main bottleneck — shards wait up to 78m for a device during working hours. Duplicate dispatch runs waste device slots and make the queue worse for everyone.
Test plan
Related
Made with Cursor