mineiros-io / terraform-github-repository

A Terraform module to manage GitHub Repositories. https://github.com/
Apache License 2.0
156 stars 100 forks source link

integrations/github 5.9.0 - at least one permission expected from permissions map #141

Closed tyriis closed 1 year ago

tyriis commented 1 year ago

When using latest GitHub provider (integrations/github 5.9.0) I get the following error for the given repository definition.

╷
│ Error: at least one permission expected from permissions map
│ 
│   with module.my_repo.github_team_repository.team_repository_by_slug["my_team"],
│   on .terraform/modules/my_repo/main.tf line 441, in resource "github_team_repository" "team_repository_by_slug":
│  441: resource "github_team_repository" "team_repository_by_slug" {
│ 
╵
module "my_repo" {
  source               = "mineiros-io/repository/github"
  version              = "0.18.0"
  name                 = "my_repo"
  defaults             = var.defaults.private
  visibility           = "private"
  has_downloads        = false
  archived             = false
  archive_on_destroy   = true
  vulnerability_alerts = true
  push_teams           = [var.teams.my_team]
}

I can solve it for now by downgrading to integrations/github 5.8.0

agusgonzaleznic commented 1 year ago

Seems to be an bug already reported in the github tf provider :D https://github.com/integrations/terraform-provider-github/issues/1373

mariux commented 1 year ago

@tyriis, thanks for reporting this

yes, that's a regression in the provider. Please exclude 5.9.0 from your versions requirement of the provider. Sadly there is nothing we can do until upstream is fixed (see @agusgonzaleznic comment for a link to the upstream issue).

closing the issue. feel free to reopen if you think there is something we can actually do.

tyriis commented 1 year ago

Thank you for the quick feedback