-
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
Manually planned projects/directories keep atlantis/apply
check at 0/0
which allows merging without applying
#3852
Comments
I think it is definitely related, but I'm still trying to understand what's going on. This is what I'm seeing: 0.24.0:
0.25.0 (which introduced #3378 to mark as apply successful if nothing to do):
0.26.0 (where I added introduced #3747 to prevent gitlab from being stuck in pending state):
@nitrocode what do you expect to see? Semantically, given #3378, where we are now seems correct to me: after the plan where changes were introduced, we have done 1/1 plans and, having not attempted any applies, we've done 0/0 of them. It might be a subtle gitlab vs github thing; in gitlab "atlantis/apply" shows up from the very beginning, as green. Is that not true in github? |
Thanks @lukemassa for looking into this and providing all the necessary PRs.
I think this is the difference. In github, the |
@lukemassa do you think you could work on a fix for this? and if that is the case document the nuance between gitlab and github for the status too. |
I'm happy to work on this but I'm not sure yet what should be done. If I understand correctly, and if @nitrocode is indeed seeing this starting on 0.25.0, it seems like it might be a "feature not a bug" of #3378. That PR added logic that updated the apply check on the plan run if there were no changes, which I believe would cover this case. Short of reverting that feature, I'm not sure what could be done. I might be missing something though. |
@chroju do you have any input on this? |
Sorry, but I do not understand what this issue is aiming to resolve. I will only explain the changes made by #3378. With the merger of #3378, running I'm not familiar with the situation prior to v0.25.0. I believe that at that time, even if you ran |
This is a huge mistake. It could be acceptable to automatically run apply if plan shows 0 changes, but It feels strange to ask, but can we have a way to require Atlantis actually run |
Before considering any action, we need to understand the problem correctly. There are multiple. The ask to change #3378 is not related to this issue about allowing manual plan/applies of projects unrelated to the PR. It should be a separate issue referencing #3378. This issue is that the apply status checks have different behavior in GitLab vs. GitHub. However, the logic for handling these checks is in the core event logic that affects both VCS providers. It might be best to investigate moving logic to their client implementations respectfully. I want to advocate for not imposing an opinionated way people must run their workflows so we're not constantly ping-ponging on the issue. Workflows in GH vs GL are different and continues to bite us. @lukemassa @chroju @nitrocode Let's continue the discussion around the title of the issue, "Manually planned projects/directories keep atlantis/apply check at 0/0 which allows merging without applying".
This is a good summary by Luke. Do we need to compensate somewhere in GH for the fact the |
Community Note
Overview of the Issue
Prior to v0.26.0 and v0.25.0, atlantis would allow us to plan projects/directories manually and this would prevent the
atlantis/apply
check from being green until anatlantis apply
was commentedReproduction Steps
atlantis/plan
is1/1
andatlantis/apply
is0/0
Logs
Environment details
Additional Context
The text was updated successfully, but these errors were encountered: