-
Notifications
You must be signed in to change notification settings - Fork 1.1k
fix: Pre Workflow Hook VCS Combined Status Check Set to Pending Twice #5242
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
Merged
X-Guardian
merged 7 commits into
runatlantis:main
from
X-Guardian:pre-workflow-hook-status-check-fix
Feb 1, 2025
Merged
fix: Pre Workflow Hook VCS Combined Status Check Set to Pending Twice #5242
X-Guardian
merged 7 commits into
runatlantis:main
from
X-Guardian:pre-workflow-hook-status-check-fix
Feb 1, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: X-Guardian <[email protected]>
Signed-off-by: X-Guardian <[email protected]>
Signed-off-by: X-Guardian <[email protected]>
Signed-off-by: X-Guardian <[email protected]>
lukemassa
approved these changes
Feb 1, 2025
bub3n
pushed a commit
to bub3n/atlantis
that referenced
this pull request
Feb 3, 2025
…runatlantis#5242) Signed-off-by: X-Guardian <[email protected]> Signed-off-by: Petr Bubenik <[email protected]>
1 task
bub3n
pushed a commit
to bub3n/atlantis
that referenced
this pull request
Feb 4, 2025
…runatlantis#5242) Signed-off-by: X-Guardian <[email protected]> Signed-off-by: Petr Bubenik <[email protected]>
This was referenced Feb 13, 2025
jamengual
added a commit
that referenced
this pull request
Aug 15, 2025
…cts found This fixes issue #5389 where PRs were getting stuck with pending status when ATLANTIS_SILENCE_VCS_STATUS_NO_PLANS and ATLANTIS_SILENCE_VCS_STATUS_NO_PROJECTS were enabled and no projects matched when_modified patterns. Root cause: - PR #5242 (commit be06063) introduced early pending status setting in command_runner.go - When silence flags are enabled and no projects are found, the pending status was never cleared - This left PRs stuck in pending state, blocking auto-merge functionality Solution: - Modified plan_command_runner.go to clear pending status even when silence flags are enabled - Added else blocks to both autoplan and manual plan paths - When silence is enabled but no projects found, update status to success (0/0) to clear pending - Added comprehensive test to prevent regression Testing: - Updated existing test expectation for silence flag behavior - Added new test TestPlanCommandRunner_SilenceFlagsClearsPendingStatus - All existing tests continue to pass
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
what
Fix the VCS combined status check from being set to pending twice when pre-workflow hooks are configured.
The
CommitStatusUpdater.UpdateCombined
function calls have been moved out of theRunPreHooks
andplan/apply
Run
functions and adding to the upstreamRunAutoplanCommand
,RunCommentCommand
,ApiPlan
andApiApply
functions.why
tests
Logs Before
Logs After
references