integrations / terraform-provider-github

Terraform GitHub provider
https://www.terraform.io/docs/providers/github/
MIT License
906 stars 746 forks source link

"github_team_repository.write.0: At least one permission expected from permissions map." #131

Closed benabineri closed 6 months ago

benabineri commented 6 years ago

Terraform Version

Terraform v0.11.7

Affected Resource(s)

Terraform Configuration Files

resource "github_repository" "repository" {
  name         = "${var.name}"
  description  = "${local.description}"
  homepage_url = "${local.homepage_url}"

  private            = true
  has_issues         = true
  has_wiki           = false
  allow_merge_commit = false
  allow_squash_merge = true
  allow_rebase_merge = true
  has_downloads      = false
  auto_init          = true
  archived           = "${var.archived}"
}

resource "github_team_repository" "write" {
  team_id    = "${element(var.write_teams, count.index)}"
  repository = "${github_repository.repository.name}"
  permission = "push"

  count = "${var.write_teams_count}"
}

Debug Output

Can provide.

Panic Output

No panic.

Expected Behavior

github_team_repository.write permission should be set.

Actual Behavior

Fails with the error below (but only for some repos)

* module.<module name>.github_team_repository.write[0]: github_team_repository.write.0: At least one permission expected from permissions map.

Steps to Reproduce

Try to create a github_team_repository.

Thanks.

radeksimko commented 6 years ago

Hi @benabineri thanks for the report.

I was unfortunately unable to reproduce the bug though. Do you mind providing the debug log from terraform commands you ran (minus any secrets)?

You can create a gist (instead of pasting it directly to the thread here). Also feel free to use our GPG key to encrypt it if you feel the need for it.

Thanks.

github-actions[bot] commented 1 year ago

šŸ‘‹ Hey Friends, this issue has been automatically marked as stale because it has no recent activity. It will be closed if no further activity occurs. Please add the Status: Pinned label if you feel that this issue needs to remain open/active. Thank you for your contributions and help in keeping things tidy!

github-actions[bot] commented 6 months ago

šŸ‘‹ Hey Friends, this issue has been automatically marked as stale because it has no recent activity. It will be closed if no further activity occurs. Please add the Status: Pinned label if you feel that this issue needs to remain open/active. Thank you for your contributions and help in keeping things tidy!