Skip to content

chainguard_image_repos data lookup Value Conversion Error #429

@evantlueck

Description

@evantlueck

The below error occurs when attempting to reference the output of the chainguard_image_repos data source:

╷
│ Error: Value Conversion Error
│ 
│   with data.chainguard_image_repos.this,
│   on main.tf line 40, in data "chainguard_image_repos" "this":
│   40: data "chainguard_image_repos" "this" {}
│ 
│ An unexpected error was encountered trying to convert from struct into an object. This is always an
│ error in the provider. Please report the following to the provider developer:
│ 
│ Mismatch between struct and object type: Struct defines fields not found in object: google, amazon,
│ azure, and grace_period.
│ Struct: provider.syncConfig
│ Object type: types.ObjectType["apko_overlay":basetypes.StringType, "expiration":basetypes.StringType,
│ "source":basetypes.StringType, "unique_tags":basetypes.BoolType]
╵

TF to replicate:

main.tf

terraform {
  required_version = ">= 1.0"
  required_providers {
    chainguard = {
      source  = "chainguard-dev/chainguard"
      version = "0.1.43"
    }
  }
}

provider "chainguard" {}

data "chainguard_image_repos" "this" {}

output "repo_list" {
  value = data.chainguard_image_repos.this
}

Note that on a fresh tenant with no repos, I received no errors (and no repos were listed because there were none to list).
On a tenant with repos, I received the error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions