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

workflows/tests: enable merge group builds. #14964

Merged
merged 1 commit into from Mar 15, 2023

Conversation

MikeMcQuaid
Copy link
Member

This will enable the GitHub Merge Queue. Don't bother running online tests as they aren't required, use up the rate limit and are flaky.

This will enable the GitHub Merge Queue. Don't bother running online
tests as they aren't required, use up the rate limit and are flaky.
@BrewTestBot
Copy link
Member

Review period will end on 2023-03-14 at 22:03:39 UTC.

@BrewTestBot BrewTestBot added the waiting for feedback Merging is blocked until sufficient time has passed for review label Mar 13, 2023
Copy link
Member

@issyl0 issyl0 left a comment

Choose a reason for hiding this comment

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

I'm struggling to see the benefit of this for this repo. We already have auto-merge available at the click of a button, we already have the normal merge button, and there's not a production deployment step with lots of people trying to get lots of changes shipped all at once. 🤔

@reitermarkus
Copy link
Member

reitermarkus commented Mar 14, 2023

So does this work like “require pull requests branched to be up-to-date” without having to rebase it before merging? I.e. every pull request is rebased in the merge queue before actually being merged?

@reitermarkus
Copy link
Member

I'm struggling to see the benefit of this for this repo.

If this works like I am thinking it works:

  1. Pull request A adds test for file B not existing. CI passes.
  2. Pull request B adds file B. CI passes.
  3. Both are merged at the same time: Tests fail on master.

If they are added to a merge queue instead, one of them will be merged and the other will fail once it is rebased on the other.

@@ -311,6 +312,7 @@ jobs:
run: sudo chmod -R g-w,o-w /home/linuxbrew/.linuxbrew/Homebrew

- name: Run brew tests
if: github.event_name == 'pull_request' || matrix.name != 'tests (online)'
Copy link
Member

Choose a reason for hiding this comment

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

I think it might actually make more sense to flip this condition.

Running online tests only in the merge queue will make it less likely we hit rate limits if we also limit to one concurrent merge group.

Copy link
Member Author

Choose a reason for hiding this comment

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

@reitermarkus I'm less concerned about rate limits here than the job being flaky and that being annoying before merge. If it flakes when in the merge queue, it'll get kicked out and you need to try and add and rerun all CI again. If it flakes before the merge queue, you can manually rerun.

Copy link
Member

Choose a reason for hiding this comment

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

But what does flaky mean exactly? I think we already retry online tests multiple times to make them more robust, so the only thing that can still fail them is the rate limit.

Can you point to an online test that is flaky for a different reason?

Copy link
Member Author

Choose a reason for hiding this comment

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

@reitermarkus Flaky meaning will fail intermittently and we've been unable to fix that. That applies with pretty much all our online tests.

It's rare for them to fail consistently outside of the rate limit but e.g. third-party services being down/flaky will make them fail/flake too.

Copy link
Member

Choose a reason for hiding this comment

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

My only concern is we don't get the benefit of merge queues when two PRs modify code that needs network access. I guess we'll cross that bridge if we ever get there and add offline tests.

Copy link
Member Author

Choose a reason for hiding this comment

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

@reitermarkus yeh, agreed 👍🏻

@MikeMcQuaid
Copy link
Member Author

So does this work like “require pull requests branched to be up-to-date” without having to rebase it before merging? I.e. every pull request is rebased in the merge queue before actually being merged?

@reitermarkus Yes but with merge commits instead of rebasing.

I'm struggling to see the benefit of this for this repo.

@issyl0 Will need to figure out how to adjust the CI jobs accordingly so it doesn't take too long/be too annoying but:

Both are merged at the same time: Tests fail on master.
If they are added to a merge queue instead, one of them will be merged and the other will fail once it is rebased on the other.

@issyl0 exactly what @reitermarkus has pointed out here. master has gone 🔴 a couple of times in the last months due to these sorts of changes. Merge queue makes it impossible for that to happen.

@BrewTestBot BrewTestBot removed the waiting for feedback Merging is blocked until sufficient time has passed for review label Mar 15, 2023
@BrewTestBot
Copy link
Member

Review period ended.

@MikeMcQuaid MikeMcQuaid merged commit 162075f into Homebrew:master Mar 15, 2023
23 of 25 checks passed
@MikeMcQuaid MikeMcQuaid deleted the merge_group branch March 15, 2023 16:08
@github-actions github-actions bot added the outdated PR was locked due to age label Apr 15, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated PR was locked due to age
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants