PePe Amengual 900f00be65 fix: clear pending VCS status when silence flags enabled and no projects 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 be060636) 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
2025-08-14 23:02:10 -07:00
2025-06-26 23:47:34 -04:00
2024-12-28 17:50:53 -05:00
2024-06-09 19:34:20 -04:00
2025-02-19 01:16:36 -05:00

Atlantis

Latest Release SuperDopeBadge Go Report Card Go Reference Slack OpenSSF Scorecard OpenSSF Best Practices

Atlantis Logo

Terraform Pull Request Automation

Resources

What is Atlantis?

A self-hosted golang application that listens for Terraform pull request events via webhooks.

What does it do?

Runs terraform plan, import, apply remotely and comments back on the pull request with the output.

Why should you use it?

  • Make Terraform changes visible to your whole team.
  • Enable non-operations engineers to collaborate on Terraform.
  • Standardize your Terraform workflows.

Stargazers over time

Stargazers over time

Description
Terraform Pull Request Automation
Readme 215 MiB