lgallard / terraform-aws-secrets-manager

Terraform module to create Amazon Secrets Manager resources.
Apache License 2.0
63 stars 50 forks source link

terraform version constraint is wrong #54

Closed stevie- closed 4 months ago

stevie- commented 4 months ago

the new added TF version constraint is wrong.

Initializing modules...
  Downloading registry.terraform.io/lgallard/secrets-manager/aws 0.11.3 for secrets_unmanaged...
  - secrets_unmanaged in .terraform/modules/secrets_unmanaged
  ╷
  │ Error: Unsupported Terraform Core version
  │ 
  │   on .terraform/modules/secrets_unmanaged/versions.tf line 2, in terraform:
  │    2:   required_version = "~> v0.13.7"
  │ 
  │ Module module.secrets_unmanaged (from
  │ registry.terraform.io/lgallard/secrets-manager/aws) does not support
  │ Terraform version 1.5.7. To proceed, either choose another supported
  │ Terraform version or update this version constraint. Version constraints
  │ are normally set for good reason, so updating the constraint may lead to
  │ other errors or unexpected behavior.

Better just set minium version and not limit to only patch in a module. Also Dependabot doesn't check which verison is the minimum to be accepted and always suggest the latest version as minimum. this shouldn't be done in a module.

Suggestion:

required_version = ">= 1.0"
lgallard commented 4 months ago

@stevie- Thanks for the head-up. You are right. The latest release changes the constraints as suggested.