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

Split check labels to action with label-based triggers #20064

Draft
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

tgolsson
Copy link
Contributor

I think it makes more sense to run the label-check job based on labels and not based on pushes. Also means that if a PR is opened and we add a label that job goes green immediately without having to rerun the CI. Downside is we'll need another required status check in the branch protection rules.

@tgolsson tgolsson changed the title split out check labels to separate run-file with label-based triggers Split check labels to action with label-based triggers Oct 21, 2023
@tgolsson tgolsson added the category:internal CI, fixes for not-yet-released features, etc. label Oct 21, 2023
@tgolsson tgolsson marked this pull request as ready for review October 21, 2023 10:23
@tgolsson tgolsson marked this pull request as draft October 21, 2023 10:24
@tgolsson tgolsson marked this pull request as ready for review October 21, 2023 10:35
@gauthamnair
Copy link
Contributor

+1 for this @tgolsson

@thejcannon
Copy link
Member

Can you have generate_github_workflows.py generate this workflow, please? It's intended to share some boilerplate and also catch YAML issues.

otherwise, +1 to the idea 😄

@tgolsson tgolsson marked this pull request as draft October 24, 2023 21:31
@tgolsson tgolsson added category:internal CI, fixes for not-yet-released features, etc. and removed category:internal CI, fixes for not-yet-released features, etc. labels Nov 2, 2023
@tgolsson tgolsson marked this pull request as ready for review November 2, 2023 21:06
@tgolsson
Copy link
Contributor Author

tgolsson commented Nov 2, 2023

@thejcannon Fixed!

Copy link
Member

@thejcannon thejcannon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For my own understanding, once this goes in, I (or any admin) needs to edit the repo settings that says "these checks must pass before merging", yeah?

src/python/pants_release/generate_github_workflows.py Outdated Show resolved Hide resolved
@tgolsson tgolsson added category:internal CI, fixes for not-yet-released features, etc. and removed category:internal CI, fixes for not-yet-released features, etc. labels Nov 10, 2023
@tgolsson
Copy link
Contributor Author

I have found a fatal flaw in this setup which I think is a show-stopper. GitHub statuses can only exist on commits. That means when a new commit is added, the category check has to run in order to exist for the last commit on the branch. Will have a think...

@tgolsson tgolsson marked this pull request as draft November 10, 2023 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:internal CI, fixes for not-yet-released features, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants