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

'…:tgz' does not have mandatory providers 'PackageArtifactInfo' #10

Closed
chrisirhc opened this issue Nov 11, 2024 · 1 comment · Fixed by #12
Closed

'…:tgz' does not have mandatory providers 'PackageArtifactInfo' #10

chrisirhc opened this issue Nov 11, 2024 · 1 comment · Fixed by #12

Comments

@chrisirhc
Copy link
Contributor

chrisirhc commented Nov 11, 2024

Tried to replicate the terraform setup in https://github.com/yanndegat/rules_tf/tree/main/tests/bcr but I'm getting:

ERROR: //experimental/terraform_spike/canary/BUILD.bazel:12:10: in package attribute of tf_artifact rule //experimental/terraform_spike/canary:canary: '//experimental/terraform_spike/canary:tgz' does not have mandatory providers: 'PackageArtifactInfo'. Since this rule was created by the macro 'tf_module', the error might have been caused by the macro implementation

BUILD file:

load("@rules_tf//tf:def.bzl", "tf_providers_versions", "tf_module")

tf_providers_versions(
    name = "providers",
    tf_version = "1.2.3",
    providers = {
        "random" : "hashicorp/random:>=3.3",
        "null"   : "hashicorp/null:>=3.1",
    },
)

tf_module(
    name = "canary",
    providers = [
        # "random",
    ],
    deps = [
        # "//tf/modules/mod-a",
    ],
    providers_versions = ":providers",
)
@chrisirhc
Copy link
Contributor Author

chrisirhc commented Nov 11, 2024

Ah figured it out, rules_pkg 0.10 removes PackageArtifactInfo: bazelbuild/rules_pkg#752 and I'm using 0.10.1 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant