Skip to content

feat(ci): add merge queue support#2195

Open
osterman wants to merge 1 commit intomainfrom
osterman/merge-queue-ci
Open

feat(ci): add merge queue support#2195
osterman wants to merge 1 commit intomainfrom
osterman/merge-queue-ci

Conversation

@osterman
Copy link
Member

@osterman osterman commented Mar 14, 2026

what

  • Add merge_group event trigger to test.yml, pre-commit.yml, and codeql.yml workflows
  • Update lint-golangci job to run for both pull_request and merge_group events
  • Fix pre-commit.yml to use merge_group.base_sha as fallback when pull_request.base.sha is unavailable

why

GitHub merge queues require workflows to explicitly listen for the merge_group event. Without these triggers, required checks never fire when a PR enters the queue, causing the merge queue to timeout after 1 hour. This follows the established pattern from Cloud Posse's terraform-components repositories.

references

Aligns with Cloud Posse merge queue implementation in cloudposse-terraform-components/aws-account and other component repos. Enables merge queue feature for safer, batched merges on the main branch.

Summary by CodeRabbit

  • Chores
    • Enhanced CI/CD workflow configuration to support additional merge validation checks, improving the continuous integration pipeline's robustness and coverage.

Enable GitHub merge queue on main branch by adding merge_group triggers to test.yml, pre-commit.yml, and codeql.yml. Updates lint-golangci conditional to run for both pull_request and merge_group events. Fixes base SHA reference in pre-commit to use merge_group.base_sha fallback.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@osterman osterman requested a review from a team as a code owner March 14, 2026 16:37
@github-actions github-actions bot added the size/s Small size PR label Mar 14, 2026
@mergify
Copy link

mergify bot commented Mar 14, 2026

Important

Cloud Posse Engineering Team Review Required

This pull request modifies files that require Cloud Posse's review. Please be patient, and a core maintainer will review your changes.

To expedite this process, reach out to us on Slack in the #pr-reviews channel.

@mergify mergify bot added the needs-cloudposse Needs Cloud Posse assistance label Mar 14, 2026
@github-actions
Copy link

Dependency Review

✅ No vulnerabilities or license issues found.

Scanned Files

None

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 14, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 01d69e30-a972-4710-9b5d-f49b00b7ca35

📥 Commits

Reviewing files that changed from the base of the PR and between 76a269b and 0ec79be.

📒 Files selected for processing (3)
  • .github/workflows/codeql.yml
  • .github/workflows/pre-commit.yml
  • .github/workflows/test.yml

📝 Walkthrough

Walkthrough

The PR adds merge_group event triggers to three GitHub Actions workflows (codeql.yml, pre-commit.yml, test.yml) with checks_requested type. The lint-golangci job condition in codeql.yml is extended to support the merge_group event type, and pre-commit.yml updates its base ref logic to fallback to merge_group.base_sha.

Changes

Cohort / File(s) Summary
GitHub Actions merge_group trigger support
.github/workflows/codeql.yml, .github/workflows/pre-commit.yml, .github/workflows/test.yml
Adds merge_group trigger with checks_requested type to all three workflows. Extends lint-golangci job condition in codeql.yml to run on 'pull_request' or 'merge_group'. Updates pre-commit.yml base ref resolution to fallback from base.sha to merge_group.base_sha when needed.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

  • #1078: Modifies lint-golangci job setup in test.yml alongside this PR's trigger and condition updates
  • #890: Configures Mergify workflow dispatch, complementary to this PR's new merge_group triggers
  • #1137: Also modifies merge_group trigger and lint-golangci condition in codeql.yml

Suggested labels

no-release

Suggested reviewers

  • aknysh
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding merge queue support to CI workflows across three workflow files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch osterman/merge-queue-ci
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@codecov
Copy link

codecov bot commented Mar 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.30%. Comparing base (bbac3f8) to head (0ec79be).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2195   +/-   ##
=======================================
  Coverage   77.29%   77.30%           
=======================================
  Files         960      960           
  Lines       91088    91088           
=======================================
+ Hits        70410    70415    +5     
+ Misses      16593    16589    -4     
+ Partials     4085     4084    -1     
Flag Coverage Δ
unittests 77.30% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.
see 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@osterman osterman added the no-release Do not create a new release (wait for additional code changes) label Mar 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-cloudposse Needs Cloud Posse assistance no-release Do not create a new release (wait for additional code changes) size/s Small size PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant