Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cancel outdated builds to reduce queueing #165

Merged
merged 3 commits into from
Dec 29, 2024

Conversation

pirj
Copy link
Member

@pirj pirj commented Dec 28, 2024

Run CI only for the last push on each branch.

Prevents branch builds from stacking on multiple subsequent pushes by canceling older builds.

https://docs.github.com/en/actions/using-jobs/using-concurrency
https://github.blog/changelog/2021-04-19-github-actions-limit-workflow-run-or-job-concurrency/

Scavenged from rubocop/rubocop-rspec#1539

Problem:
image

@pirj pirj self-assigned this Dec 28, 2024
@JonRowe JonRowe merged commit 6f542a4 into main Dec 29, 2024
40 checks passed
@JonRowe JonRowe deleted the cancel-in-progress-to-reduce-queueing branch December 29, 2024 18:22
@JonRowe JonRowe restored the cancel-in-progress-to-reduce-queueing branch December 29, 2024 18:32
@JonRowe JonRowe deleted the cancel-in-progress-to-reduce-queueing branch December 29, 2024 18:32
JonRowe added a commit that referenced this pull request Dec 29, 2024
@JonRowe
Copy link
Member

JonRowe commented Dec 29, 2024

Reverting because it doesn't work, apologies, should have insisted on checking it before merging but it causes only one of the gems to be run.

@pirj
Copy link
Member Author

pirj commented Dec 30, 2024

It must be the “group” signature that messes things up, I’ll experiment with it. Thanks for reverting.

@JonRowe
Copy link
Member

JonRowe commented Dec 30, 2024

I think each gem / rubocop needs to have a different name (remembering that the rspec one runs multiple times) it looks like the workflow part of the name also is blank hence also caught rubocop

@pirj
Copy link
Member Author

pirj commented Dec 30, 2024

That makes sense since we always schedule the same set of builds jobs.

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.

2 participants