Skip to content
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

[BUG]: The github_repository resource churns on vulnerability_alerts if not explicitly set #2489

Open
1 task done
stevehipwell opened this issue Dec 3, 2024 · 2 comments · May be fixed by #2501
Open
1 task done
Labels
Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented

Comments

@stevehipwell
Copy link
Contributor

Expected Behavior

When creating a new repository with the github_repository resource, this should not churn if vulnerability_alerts is not set.

Actual Behavior

If vulnerability_alerts is not set it will constantly churn.

Terraform Version

n/a

Affected Resource(s)

  • github_repository

Terraform Configuration Files

resource "github_repository" "test" {
  name         = "test"
}

Steps to Reproduce

Apply the above resource and then run a plan.

This issue is being caused by a missing Computed: true value on the schema. I'll open a PR to fix this, but long term this attribute should be deprecated and handled by it's own resource.

Debug Output

No response

Panic Output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@stevehipwell stevehipwell added Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented labels Dec 3, 2024
@github-project-automation github-project-automation bot moved this to 🆕 Triage in 🧰 Octokit Active Dec 3, 2024
@stevehipwell
Copy link
Contributor Author

It also looks like if a repository is created with an explicit value for vulnerability_alerts that doesn't match the default it will also churn.

@stevehipwell stevehipwell changed the title [BUG]: Repository data source churns on vulnerability_alerts if not explicitly set [BUG]: The github_repository resource churns on vulnerability_alerts if not explicitly set Dec 4, 2024
@stevehipwell
Copy link
Contributor Author

The code to fix this is currently in #2476 but I'm planning on opening a seperate PR for this change before that gets merged.

@stevehipwell stevehipwell linked a pull request Dec 5, 2024 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant