GitLab: a merge request marked as merged manually
GitLab can mark a merge request as merged with a merged manually system note even though nobody used the Merge button. It happens when the changes reach the target branch another way. Less often a merge request stays Open after its changes are in (GitLab docs: merge request troubleshooting, checked November 19, 2026).
Two causes
- Merged outside GitLab. Someone ran
git mergeand pushed the result to the target branch, and GitLab noticed. This is possible when direct pushes to the target branch are allowed. To stop it, protect the target branch and set Allowed to push and merge to No one, so changes only arrive through merge requests. - Merged as part of another merge request. The commits were already merged through a different merge request. If the branch is protected, they were approved under its protected branch settings. GitLab documents no fix, because it is expected behavior.
To see whether a merge request is still open, and what GitLab says about it: Merge Request (MR) Review Inbox for GitLab, a plugin for JetBrains IDEs, lists the merge checks from detailed_merge_status with the blocking ones first.
The reverse: still "Open" after the merge
If a merge request stays Open although its changes are merged, an administrator can fix the state from the Rails console with MergeRequests::PostMergeService (look up the user, project and merge request by IID). GitLab warns that the merge request then shows "merged into branch-name" even if it still had unmerged changes, and that direct data changes can do damage, so test elsewhere first and keep a backup. GitLab documents similar console steps for closing a merge request (MergeRequests::CloseService) and deleting one (Issuable::DestroyService) when the page and API cannot.
Other messages from the same page
Merge request cannot retrieve the pipeline status: Sidekiq did not process the CI state change fast enough. Wait a few seconds; the status updates by itself.Pipeline status cannot be retrieved: after a sequence of create, close, change the project, reopen. Close and reopen the merge request.- The reference
refs/merge-requests/:iid/headof a merge request is deleted 14 days after it is closed or merged; the merge request can still be reopened and its source branch checked out.
GitLab merge requests in IntelliJ IDEA
Merge Request (MR) Review Inbox for GitLab, a plugin by Lesstep for JetBrains IDEs 2024.1 or later, lists the merge requests waiting for you and shows each one's state, and the list refreshes every 5 minutes while it is open. Reading is free; approving, commenting and merging are Pro (US$1.50 a month, with a 30-day trial).
Get it on JetBrains Marketplace
GITLAB is a trademark of GitLab Inc.; IntelliJ IDEA is a trademark of JetBrains s.r.o. This page is not affiliated with or endorsed by GitLab Inc. or JetBrains.
More: GitLab merge refused (405, 409, 422) · GitLab rebase refused or failed (403, 409) · GitLab "Something went wrong during merge pre-receive hook" · GitLab "A CI/CD pipeline must run and be successful before merge"