Skip to content

Configure required GHA jobs for merge_group #196

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

Merged
merged 1 commit into from
Apr 24, 2025

Conversation

ptgott
Copy link
Contributor

@ptgott ptgott commented Apr 23, 2025

We recently configured docs-website to use merge queues, and have one job with a merge_group trigger. Since the required checks do not have a merge_group trigger, though, merge queues time out waiting for checks to be reported.

  • Move the docs build check into Amplify Preview. A job called "Amplify Preview" is required to run. Move the "Check the docs build" step into the docs preview workflow. Run one of two "Amplify Preview" jobs depending on the event type.

  • Trigger all expected workflows on the merge_group event, but add an if condition so they pass if the event is merge_group

Copy link

github-actions bot commented Apr 23, 2025

Amplify deployment status

Branch Commit Job ID Status Preview Updated (UTC)
paul.gottschling/2025-04-23-merge-group b3f907f 3 ✅SUCCEED paul-gottschling-2025-04-23-merge-group 2025-04-24 21:07:19


jobs:
run-tests:
name: Run tests
if: ${{ github.event_name != 'merge_group' }}
Copy link
Contributor

Choose a reason for hiding this comment

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

We could probably run this on merge queue as well, it won't hurt I guess.

@taraspos taraspos added this pull request to the merge queue Apr 24, 2025
@taraspos
Copy link
Contributor

I just tried to add it to the merge queue and seems like it didn't work for CodeQL and Dependency Check workflows.

Screenshot 2025-04-24 at 08 22 49

@taraspos taraspos removed this pull request from the merge queue due to a manual request Apr 24, 2025
@ptgott ptgott force-pushed the paul.gottschling/2025-04-23-merge-group branch from 3bdbd0e to 729030f Compare April 24, 2025 20:43
We recently configured docs-website to use merge queues, and have one
job with a `merge_group` trigger. Since the required checks do not have a
`merge_group` trigger, though, merge queues time out waiting for checks
to be reported.

- Move the docs build check into Amplify Preview. A job called "Amplify
  Preview" is required to run. Move the "Check the docs build" step into
  the docs preview workflow. Run one of two "Amplify Preview" jobs
  depending on the event type.

- Trigger all expected workflows on the `merge_group` event, but add an
  `if` condition so they pass if the event is merge_group. Do not add an
  `if` condition to the `Dependency Review` job, since it seems to
  conflict with the `uses` field. The job takes < 30s, so there is not
  much harm in running it on `merge_group`.
@ptgott ptgott force-pushed the paul.gottschling/2025-04-23-merge-group branch from 729030f to b3f907f Compare April 24, 2025 20:53
@ptgott ptgott enabled auto-merge April 24, 2025 20:58
@ptgott ptgott added this pull request to the merge queue Apr 24, 2025
Merged via the queue into main with commit ae2f960 Apr 24, 2025
6 checks passed
@ptgott ptgott deleted the paul.gottschling/2025-04-23-merge-group branch April 24, 2025 21:16
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