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]: Error: Invalid address to set: []string{"create_default_maintainer"} trying to import github_team_members #2124

Closed
1 task done
richjyoung opened this issue Jan 31, 2024 · 1 comment · Fixed by #2126
Labels
Status: Stale Used by stalebot to clean house Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented

Comments

@richjyoung
Copy link
Contributor

richjyoung commented Jan 31, 2024

Expected Behavior

Importing an existing team's members fails with an error. The team already exists and has been imported prior to this, with terraform plan showing no changes required. The existing team has members already added, and the github_team_members resource has been set up to match before import.

Actual Behavior

Running terraform import ... yields the following error:

> terraform import github_team_members.existing_team existing_team
github_team_members.existing_team: Importing from ID "existing_team"...
╷
│ Error: Invalid address to set: []string{"create_default_maintainer"}

Terraform Version

Terraform v1.7.1
on darwin_amd64

  • provider registry.terraform.io/integrations/github v6.0.0-beta

Affected Resource(s)

  • github_team_members

Terraform Configuration Files

resource "github_team" "existing_team" {
  name = "Existing Team"
  privacy = "closed"
  create_default_maintainer = false
}

resource "github_team_members" "existing_team" {
  team_id = github_team.existing_team.id

  members {
    username = "an-existing-user"
    role     = "maintainer"
  }
  members {
    username = "another-existing-user"
    role     = "member"
  }
}

Steps to Reproduce

  1. Manually create a Team or use an existing one
  2. Import the team into terraform
  3. Manually add users to the Team
  4. Attempt to import team members using:
$ terraform import github_team_members.existing_team existing_team

Debug Output

No response

Panic Output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@richjyoung richjyoung added Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented labels Jan 31, 2024
@kfcampbell kfcampbell added Status: Up for grabs Issues that are ready to be worked on by anyone and removed Status: Triage This is being looked at and prioritized labels Feb 2, 2024
@kfcampbell kfcampbell moved this from 🆕 Triage to 🔥 Backlog in 🧰 Octokit Active Feb 2, 2024
Copy link

👋 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 github-actions bot added the Status: Stale Used by stalebot to clean house label Oct 30, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Nov 7, 2024
@github-project-automation github-project-automation bot moved this from 🔥 Backlog to ✅ Done in 🧰 Octokit Active Nov 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Stale Used by stalebot to clean house 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
2 participants