Skip to content

[Merged by Bors] - ci: do not let bors run if the awaiting-CI label is present#6068

Closed
eric-wieser wants to merge 1 commit intomasterfrom
eric-wieser-patch-1
Closed

[Merged by Bors] - ci: do not let bors run if the awaiting-CI label is present#6068
eric-wieser wants to merge 1 commit intomasterfrom
eric-wieser-patch-1

Conversation

@eric-wieser
Copy link
Copy Markdown
Member

@eric-wieser eric-wieser commented Jul 23, 2023

We already did this in mathlib3.

This forward-ports leanprover-community/mathlib3#9478, which was created a few days after this file was ported in #52.


Open in Gitpod

@eric-wieser eric-wieser added CI Modifies the continuous integration setup or other automation awaiting-review easy < 20s of review time. See the lifecycle page for guidelines. labels Jul 23, 2023
@alexjbest
Copy link
Copy Markdown
Member

Is there a way to make this do the stronger thing of not running until ci actually passes?

@eric-wieser
Copy link
Copy Markdown
Member Author

Not as far as I know. Either way, I think there's benefit to merging this PR as is; it means that it's not possible to merge something without CI unless you consciously remove a label. @kbuzzard did so accidentally earlier today.

@alexjbest
Copy link
Copy Markdown
Member

But if people never add the label in the first place we still have an issue is my point. Perhaps we need an action to automatically add the label if bors cannot be conditional on ci passing itself.

@alexjbest
Copy link
Copy Markdown
Member

Looking at the bors reference https://bors.tech/documentation/ the pr_status config option sounds like it might do the right thing. I'm on a plane so I can't check the bors source right now to confirm but if that option does allow us to actually wait for status checks rather than a label (which can be misapplied) that sounds a far better but equally simple fix than what you propose here

@alexjbest
Copy link
Copy Markdown
Member

https://github.com/bors-ng/bors-ng/blob/390d99890d16a9fa34691728812d0052e99131f4/lib/worker/batcher.ex#L972

Looks like it does do the right thing, waiting on any statuses mentioned there to be not in process or unset, and erroring if they fail.

@eric-wieser
Copy link
Copy Markdown
Member Author

Sometimes we want to override that deliberately though, which I assume that does not let us do? I still think the approach we had in mathlib 3 and that this PR enables, while not perfect, is better than what we have now.

@alexjbest
Copy link
Copy Markdown
Member

I don't know why we would want to override it? Just to get something into master <=1hr faster? I assume priorities would still be helpful in such a situation, or at worst pushing directly to master if something that the maintainers truly wanted in master instantly came up?
We can put it to a vote on zulip perhaps, I'd say enforcing this rule is an improvement over the old behaviour, as tags are basically just human curated at the end of the day.

@eric-wieser
Copy link
Copy Markdown
Member Author

I don't know why we would want to override it? Just to get something into master <=1hr faster?

Yes: for instance if a PR is green but someone requests a typo fix in documentation, there's little point in waiting for a CI run. It would of course be better if the CI run could also be cancelled to save resources.

@eric-wieser eric-wieser added the mathlib3-pair This PR is a forward-port of a mathlib3 PR or part of one, either under review or recently merged label Jul 24, 2023
@eric-wieser
Copy link
Copy Markdown
Member Author

eric-wieser commented Jul 24, 2023

pr_status has been discussed before on Zulip, but didn't work in leanprover-community/mathlib3#11609.

I worked out why this option is missing from mathlib4; it was added in mathlib3 a day or two after the mathlib4 repo was set up, so I've labelled this with mathlib-pair as this is a forward-port!

@kim-em
Copy link
Copy Markdown
Contributor

kim-em commented Jul 24, 2023

bors merge

@github-actions github-actions bot added ready-to-merge This PR has been sent to bors. and removed awaiting-review labels Jul 24, 2023
bors bot pushed a commit that referenced this pull request Jul 24, 2023
We already did this in mathlib3.

This forward-ports leanprover-community/mathlib3#9478, which was created a few days after this file was ported in #52.
@bors
Copy link
Copy Markdown

bors bot commented Jul 24, 2023

Pull request successfully merged into master.

Build succeeded!

The publicly hosted instance of bors-ng is deprecated and will go away soon.

If you want to self-host your own instance, instructions are here.
For more help, visit the forum.

If you want to switch to GitHub's built-in merge queue, visit their help page.

@bors bors bot changed the title ci: do not let bors run if the awaiting-CI label is present [Merged by Bors] - ci: do not let bors run if the awaiting-CI label is present Jul 24, 2023
@bors bors bot closed this Jul 24, 2023
@bors bors bot deleted the eric-wieser-patch-1 branch July 24, 2023 14:02
fgdorais pushed a commit that referenced this pull request Jul 25, 2023
We already did this in mathlib3.

This forward-ports leanprover-community/mathlib3#9478, which was created a few days after this file was ported in #52.
kim-em pushed a commit that referenced this pull request Aug 14, 2023
We already did this in mathlib3.

This forward-ports leanprover-community/mathlib3#9478, which was created a few days after this file was ported in #52.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI Modifies the continuous integration setup or other automation easy < 20s of review time. See the lifecycle page for guidelines. mathlib3-pair This PR is a forward-port of a mathlib3 PR or part of one, either under review or recently merged ready-to-merge This PR has been sent to bors.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants