Auto-merge failure for repositories with merge queues

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

A GitHub PR in the repository I’m currently working is not “auto-mergeable”. The error says the following:

Pull request action failed: Failed to enable
auto-merge: Auto merge is not allowed for
this repository

In reality, the auto-merges are enabled in the repository, however the repository has Merge Queues enabled. So after all the checks are done, I expect not a “merge” but “enqueueing” the PR to the MQ, that seems to be the problem.

Steps to Reproduce

  1. GitHub repo must have a Merge Queue feature enabled
  2. Click on the Enable Auto-Merge button

Expected Behavior

The PR is scheduled to automatically add itself to the merge queue when all checks are passed

Screenshots / Screen Recordings

Operating System

MacOS

Version Information

Version: 3.8.11
VS Code Extension API: 1.105.1
Commit: e56ad3440df06d22ca7501e65fd518e905486ef0
Date: 2026-06-18T01:40:18.333Z
Layout: glass
Build Type: Stable
Release Track: Default
Electron: 40.10.3
Chromium: 144.0.7559.236
Node.js: 24.15.0
V8: 14.4.258.32-electron.0
xterm.js: 6.1.0-beta.256
OS: Darwin arm64 24.6.0

Additional Information

I have found a similar bug is already reported to the gh CLI issue tracker, so depending on how this is implemented in Cursor, we either need to fix it here, or wait for the upstream solution.

Does this stop you from using Cursor

No - Cursor works, but with this issue

Thanks for flagging this @awdk! Indeed, the experience with merge queues is not great here. I filed a bug with the team.

Ultimately, we use the GraphQL API (not gh), so it would be possible to workaround this without an upstream fix.

Hey @awdk,

Thanks for the report. Since you posted, we’ve added support for GitHub merge queues in the PR tab. On the latest version, a PR in a repo with a merge queue shows a “Merge when ready” option that adds it to the queue once checks pass, instead of failing.

Could you update to the latest version and give it another try? Quick check:

  1. Open a PR in your repo with the merge queue enabled
  2. Use the “Merge when ready” button in the PR tab

Let me know if you still see the “Auto merge is not allowed for this repository” error.

Unfortunately it did not work. On my first click I got the error toast message; on subsequent clicks the toast was not even showing (until I restarted Cursor).

I also tried to overcome the gh bug in a util of mine (unrelated to Cursor), by using GraphQL API, but from what I see in the gh conversation there’s literally no way to do it.

Once my PR passes all required checks and gets all necessary reviews I’ll try to click on the button once more – maybe the “readiness” state of the PR plays a role in here too.

Version: 3.18.25
VS Code Extension API: 1.128.0
Commit: 280eca2911f1774689696e5f1efa5a4f97a87af0
Date: 2026-08-31T23:08:02.261Z
Layout: Agent Window
Build Type: Stable
Release Track: Default
Electron: 40.10.3
Chromium: 144.0.7559.236
Node.js: 24.15.0
V8: 14.4.258.32-electron.0
xterm.js: 6.1.0-beta.291
OS: Darwin arm64 24.6.0

Hey @awdk, thanks for testing again and for the recording, that helped a lot.

You’re right that the readiness state matters here. At the moment, the “Merge when ready” option only appears once the PR is actually ready (approved and required checks passing). While the PR is still blocked, the button falls back to “Enable Auto-Merge”, and GitHub rejects it in repositories where the merge queue is configured through a ruleset but the repository’s “Allow auto-merge” setting is off. That’s the error you’re seeing. GitHub’s API doesn’t offer a way to queue a PR that isn’t ready yet in that configuration, so we need to handle that state better on our side.

Two things that should work in the meantime:

  1. Once your PR is approved and the checks are green, the button should switch to “Merge when ready” and add it to the queue.
  2. If a repo admin turns on Settings → General → Pull Requests → “Allow auto-merge” for the repository, “Enable Auto-Merge” will work and GitHub will add the PR to the queue automatically when it becomes ready.

Could you let me know whether option 1 works once your PR is ready?

Yeah, like we expected, the “Merge when ready” option worked fine :+1:

Thanks for explaining the whole GitHub mechanism, perhaps I’ll be able to make changes in our repository to improve the situation on our end.

As for the UX for the not-ready PR what I’d expect would be a disabled “Merge when ready” button or a disabled “Enable Auto-Merge” button with a tooltip explaining that my repository does not support enabling “auto-merge” via API.

Hey @awdk, thanks for the update!

Your suggestion for the not-ready state makes sense. I’ve shared this with the team.