-
Notifications
You must be signed in to change notification settings - Fork 457
ci: Setting up conditional CI runs depending on PR comment trigger #3580
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
base: develop-2.0.0
Are you sure you want to change the base?
Conversation
/ci ngo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know I'm a bit late to the conversation, but I think I'd prefer to have everything run by default, and the /ci ignore
can ignore all the checks, and then /ci ngo
can re-enable the checks. Having to remember to make an extra comment on every PR sounds like it'll frustrate me over time.
@michalChrobot |
hmm, ok, let me see what I can do |
This PR aims to address the issue of "overdoing" the CI tests which due to distribution times often lead to very long wait times.
First thing is that I failed to notice that
targets
anddrafts
conditions are configured as separate items in a list (see PR job trigger changes). In our CI, basic triggers in a list are combined with an OR operator, meaning the job will run if any of the conditions are met. This lead to test being executed on draft PRs. What I'm changing is/ci ngo
or/ci ignore
. You just have to type a comment on the PR with one of those texts to satisfy the required check/ci ngo
then all our usual CI will run. If you will type/ci ignore
then no CI will run and your PR will be green. This can be used when you are changing some things (for example .md file) that you are 100% sure won't affect CI nor anything else. Note that/ci ignore
comment will indicate that YOU TAKE RESPONSIBILITY AND YOU ACKNOWLEDGE that no testing is needed for your PR. Ofc anything will be detected by our daily CI but I just want to mention that we should be careful with using that option/ci ngo
command. In the future I will add DOCS spelling validation etc but for now we don't have it so that's the first stepNote that the PR comment check will be REQUIRED for PRs targeting
develop
,develop-2.0.0
andrelease/
branches BUT you can still use them on ANY branch to trigger PR testing if you want.Note that for draft PRs this check will be there as required but the flow should be that you type
/ci ngo
when you are ready for testing so usually when you move from draft to open stateThis change should improve our workflow with CI as well as save some resources for others
Additional stuff
I also used that occasion to remove disable-burst file. We are not using it and I included more advanced version in #3557 so if we ever need it we can reuse that one. Because of that I will remove it to avoid any confusion
Steps after approval
I will modify the required status checks to pass before merging a given PR (you can see that for this PR it awaits Pull request trigger). I will modify it in a way that merging to
develop
,develop-2.0.0
andrelease/
branches will REQURE the PR comments check.Note that PR comments won't work in this PR (so I need to validate it after merging) because the job definition itself does not exist on the pull request's target branch. CI evaluates PR comments against the job definitions present in the target branch, not the source branch of the PR.
This may be a little disruptive (since such change affects all PRs) so I will do it after approval/when merging
Backport
#3581