Skip to content

[BUG]: Permanent has_downloads/allow_update_branch diff on archived repository #1793

@kristian-lesko

Description

@kristian-lesko

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: Up for grabsIssues that are ready to be worked on by anyoneType: BugSomething isn't working as documented

    Type

    No type

    Projects

    Status

    ✅ Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions