-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
apply fails with apply_requirements mergeable on gitlab < 15.6 #3258
Comments
also confirmed workaround is to roll back to |
Yes, Atlantis only supports gitlab version 15.6 and higher due to the detailed merge status flag due to using the latest go gitlab package. |
Hi @nitrocode Furthermore, as gitlab still supports 14.x & 13.x, I'm guessing there are a number of teams like ours where they may not be able to immediately upgrade to latest 15.x for reasons. In our case another team manages gitlab instance, and coordinating & planning can take some time. Regarding possible solutions, another thought would be that Anyhow, we have a workaround for the short-term (v0.22.2), until our team maintaining gitlab are able to upgrade to 15.6+. |
See #2960 for more details on why the check was modified and the error thrown before modification Please feel free to propose a pr. The maintainers would be happy to review |
Community Note
Overview of the Issue
error received when attempting to do
atlantis apply
on a gitlab MR with approvals, andrepo has Merge Checks "Pipelines must succeed" enabled, and
atlantis is configured with
apply_requirements
ofmergeable
atlantis error:
Failure running apply operation: Pull request must be mergeable before running apply.
I am suspecting it's due to recent changes in atlantis to use the detailed merge request status instead of merge request status field of merge requests endpoint
71738f1#diff-22d1bafb2e6e476aabe2f33484daa3f74932c6e0266f0830d7d948b8b9f60183R224
however, the underlying gitlab api endpoint supporting the new field
detailed_merge_status
is newly added in gitlab 15.6:https://docs.gitlab.com/ee/api/merge_requests.html#merge-status
So currently, on gitlab versions older than 15.6 (e.g. 14.x), newest (?) versions of atlantis apply will not work with
apply_requirements
mergeable
and repo merge checks of "pipelines must succeed" enabled.Environment details
relevant repo section of
atlantis.yaml
file:atlantis helm chart 4.12.1
atlantis version v0.23.3
gitlab ee 14.10.5
Suggestion
as atlantis does appear to be aware of the gitlab version, perhaps retain previous/older behavior w.r.t. merge_status vs detailed_merge_status fields, for gitlab < 15.6
The text was updated successfully, but these errors were encountered: