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]: Permanent has_downloads/allow_update_branch diff on archived repository #1793

Closed
1 task done
kristian-lesko opened this issue Jul 13, 2023 · 0 comments · Fixed by #1795
Closed
1 task done
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented

Comments

@kristian-lesko
Copy link
Contributor

Describe the need

We have a few repositories that had been archived before we imported them to Terraform.

When we terraform apply these repositories, the allow_update_branch and has_downloads are updated (see log output below) without any error being reported; however, the subsequent plan always reports the same diff, over and over again.

Looking at previous issues, such as #1325, I believe the fix should be the same, i.e. only setting of the allow_update_branch and has_downloads properties when the repository is not archived.

SDK Version

terraform-provider-github v5.28.0

API Version

No response

Relevant log output

# module.repo["dummy"].github_repository.this will be updated in-place
  ~ resource "github_repository" "this" {
      ~ allow_update_branch         = false -> true
      - has_downloads               = true -> null
        id                          = "dummy"
        name                        = "dummy"
        # (33 unchanged attributes hidden)

        # (2 unchanged blocks hidden)
    }

Code of Conduct

  • I agree to follow this project's Code of Conduct
@kristian-lesko kristian-lesko added Status: Triage This is being looked at and prioritized Type: Maintenance Any dependency, housekeeping, and clean up Issue or PR labels Jul 13, 2023
@kfcampbell kfcampbell added Type: Bug Something isn't working as documented Status: Up for grabs Issues that are ready to be worked on by anyone Priority: Normal and removed Status: Triage This is being looked at and prioritized Type: Maintenance Any dependency, housekeeping, and clean up Issue or PR labels Jul 13, 2023
@kfcampbell kfcampbell moved this from 🆕 Triage to 🔥 Backlog in 🧰 Octokit Active Jul 13, 2023
@github-project-automation github-project-automation bot moved this from 🔥 Backlog to ✅ Done in 🧰 Octokit Active Jul 14, 2023
kfcampbell pushed a commit that referenced this issue Jul 14, 2023
)

Avoid causing a permanent `plan` diff by attempting to change attributes
that can no longer be modified if a repository is archived.

Fixes #1793.
jsifuentes pushed a commit to jsifuentes/terraform-provider-github that referenced this issue Jul 17, 2023
…tegrations#1795)

Avoid causing a permanent `plan` diff by attempting to change attributes
that can no longer be modified if a repository is archived.

Fixes integrations#1793.
felixlut pushed a commit to felixlut/terraform-provider-github that referenced this issue Jul 22, 2023
…tegrations#1795)

Avoid causing a permanent `plan` diff by attempting to change attributes
that can no longer be modified if a repository is archived.

Fixes integrations#1793.
avidspartan1 pushed a commit to avidspartan1/terraform-provider-github that referenced this issue Feb 5, 2024
…tegrations#1795)

Avoid causing a permanent `plan` diff by attempting to change attributes
that can no longer be modified if a repository is archived.

Fixes integrations#1793.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants