Skip to content

[BUG]: terraform apply error with github_emu_group_mapping resource on v6.11.0 #3160

Closed

Description

@jamesfernando94

Expected Behavior

When running a "terraform apply" with a github_emu_group_mapping resource I expect no errors

Actual Behavior

We see the following redacted error:

Error: -05T14:36:40.197Z [INFO]  provider.terraform-provider-github_v6.11.0: 2026/02/05 14:36:40 [ERROR] setting state: team_id: '' expected type 'string', got unconvertible type 'int64', value: '*******': timestamp=2026-02-05T14:36:40.197Z
Error: -05T14:36:40.197Z [ERROR] provider.terraform-provider-github_v6.11.0: Response contains error diagnostic: diagnostic_summary="team_id: '' expected type 'string', got unconvertible type 'int64', value: '******'" tf_proto_version=5.10 tf_resource_type=github_emu_group_mapping @module=sdk.proto tf_provider_addr=provider tf_req_id=*** tf_rpc=ApplyResourceChange @caller=github.com/hashicorp/[email protected]/tfprotov5/internal/diag/diagnostics.go:58 diagnostic_detail="" diagnostic_severity=ERROR timestamp=2026-02-05T14:36:40.197Z
Error: -05T14:36:40.198Z [ERROR] vertex "module.module_name.github_emu_group_mapping.github_emu_mapping_resource" error: team_id: '' expected type 'string', got unconvertible type 'int64', value: '***'
 ╷
│ Error: team_id: '' expected type 'string', got unconvertible type 'int64', value: '*******'
│ 
│   with module.module_name.github_emu_group_mapping.github_emu_mapping_resource,
│   on modules/module_name/main.tf line 69, in resource "github_emu_group_mapping" "github_emu_mapping_resource":
│   22: resource "github_emu_group_mapping" "github_emu_mapping_resource" {
│ 
╵

Terraform Version

Terraform 1.10 (Also tested on 1.14)
integrations/github Version 6.11.0 (Works on 6.10.2)

Affected Resource(s)

  • github_emu_group_mapping

Terraform Configuration Files

data "github_external_groups" "groups" {}

locals {
  map_of_groups = {
    for group in data.github_external_groups.groups.external_groups : group.group_name => group
  }
}

resource "github_team" "users" {
  name        = "users"
  description = "Team of users mapped to AD Group ${var.ad_group}"
  privacy     = "closed"
}

resource "github_emu_group_mapping" "github_emu_mapping_resource" {
  team_slug = github_team.users.slug
  group_id  = tostring(local.map_of_groups[var.ad_group].group_id)
}

Steps to Reproduce

No response

Debug Output

Error: -05T14:36:40.197Z [INFO]  provider.terraform-provider-github_v6.11.0: 2026/02/05 14:36:40 [ERROR] setting state: team_id: '' expected type 'string', got unconvertible type 'int64', value: '*******': timestamp=2026-02-05T14:36:40.197Z
Error: -05T14:36:40.197Z [ERROR] provider.terraform-provider-github_v6.11.0: Response contains error diagnostic: diagnostic_summary="team_id: '' expected type 'string', got unconvertible type 'int64', value: '******'" tf_proto_version=5.10 tf_resource_type=github_emu_group_mapping @module=sdk.proto tf_provider_addr=provider tf_req_id=*** tf_rpc=ApplyResourceChange @caller=github.com/hashicorp/[email protected]/tfprotov5/internal/diag/diagnostics.go:58 diagnostic_detail="" diagnostic_severity=ERROR timestamp=2026-02-05T14:36:40.197Z
Error: -05T14:36:40.198Z [ERROR] vertex "module.module_name.github_emu_group_mapping.github_emu_mapping_resource" error: team_id: '' expected type 'string', got unconvertible type 'int64', value: '***'
 ╷
│ Error: team_id: '' expected type 'string', got unconvertible type 'int64', value: '*******'
│ 
│   with module.module_name.github_emu_group_mapping.github_emu_mapping_resource,
│   on modules/module_name/main.tf line 69, in resource "github_emu_group_mapping" "github_emu_mapping_resource":
│   22: resource "github_emu_group_mapping" "github_emu_mapping_resource" {
│

Panic Output

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

  1. added
    Type: Bug
    Status: Triage
    on Feb 5, 2026
  2. github-actions commented on Feb 5, 2026

    @github-actions

    👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labeled with Status: Up for grabs. You & others like you are the reason all of this works! So thank you & happy coding! 🚀

  3. jamesfernando94 commented on Feb 5, 2026

    @jamesfernando94
    Author

    Apologies, I updated to version 1.14 of terraform and that fixed the issue

  4. meridius commented on Feb 6, 2026

    @meridius

    This is actually still happening for me with TF 1.14.3 and provider 6.11.0.

  5. fulder commented on Feb 6, 2026

    @fulder

    Same here, provider 6.11.0 seems to have this problem again, but downgrading to 6.10.2 works. So maybe this bug was re-introduced in the newest version.

  6. deiga commented on Feb 6, 2026

    @deiga
    Collaborator

    @meridius @fulder
    I'm sorry to hear that you are having issues. Could you share error messages, configuration examples and debug logs?

  7. kpocius commented on Feb 6, 2026

    @kpocius
    Contributor

    Can we have this issue reopened?

    The odd thing is that resources seem to be created. Also seems to only affect newly created mappings -- existing ones don't error out.

  8. deiga commented on Feb 7, 2026

    @deiga
    Collaborator

    Can we have this issue reopened?

    The odd thing is that resources seem to be created. Also seems to only affect newly created mappings -- existing ones don't error out.

    @kpocius Please add details of the issue you are seeing, otherwise it's hard for us to determine what the problem is

  9. kpocius commented on Feb 7, 2026

    @kpocius
    Contributor

    It's exactly as reported originally. What additional information can we provide to help? Full debug logs?

  10. reopened this on Feb 7, 2026
  11. deiga commented on Feb 8, 2026

    @deiga
    Collaborator

    We now have a PR which most likely addresses the issue, but are temporarily lacking access to an EMU group to verify this with

  12. fulder commented on Feb 8, 2026

    @fulder

    Thanks for the quick responses and fixes.

    I just tried out the PR/branch and looks like it works much better and solves these issues for me. All resources were still created successfully and I didn't get the errors anymore. 👍

  13. removed
    Status: Triage
    on Feb 9, 2026
  14. added this to the v6.11.1 Patch milestone on Feb 9, 2026
  15. anttijman commented on Feb 12, 2026

    @anttijman

    I've got an error related to github_emu_group_mapping resource which was introduced in 6.11.0. It does not work with 6.11.1 either. I had to revert to 6.10.2.

    I get:

    Error: GET https://api.github.com](https://api.github.com/orgs... 404 Not Found
    with github_emu_group_mapping...
    
  16. deiga commented on Feb 12, 2026

    @deiga
    Collaborator

    @anttijman Could you provide more details about what's going on?

    Preferrably example tarraform config and DEBUG level output from the whole terraform command you are running

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type: Bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions