Hi @dayo,
Based on this symptom I think you are using the terraform_remote_state
data source in a situation where the reader of the state snapshot (the configuration with the data source) is running an older version of Terraform than the writer of the state snapshot (the configuration whose state is being read).
Unfortunately some older versions of Terraform cannot decode state snapshots that include a record of whether the validation
rules in input variables passed or failed, and that leads to this error.
If I’ve correctly guessed the cause, then you can avoid the problem by upgrading the version of Terraform used by the configuration containing the data source. The latest patch release in the following minor releases has been updated to support this new information in the state:
- v1.3 (upgrade to v1.3.10)
- v1.4 (upgrade to v1.4.7)
- v1.5 (upgrade to v1.5.7)
Terraform v1.2 and earlier are not affected, and Terraform v1.6 and later are not affected.
In the above I’ve specified the earliest possible version you could upgrade to to avoid the problem, but it sould also work to upgrade directly to the latest minor release of Terraform v1.6 or later, if you’d prefer to upgrade all in one step rather than performing a patch release upgrade followed by a minor release upgrade. If you do upgrade to a newer minor release, I suggest also reviewing the upgrade guides (select earlier versions from the version selector to find the guides for each minor version boundary you are crossing) to make sure you aren’t affected by some of the less-common situations that require special attention while upgrading.