Terraform error decoding state
Had a really weird error today while applying some Terraform to a dev environment from my local machine:
│ Warning: Failed to decode resource from state │ │ Error decoding "module.something.aws_ecs_service.mirror" from prior state: a number is required ╵ ╷ │ Error: a number is required │ │ with module.something.aws_ecs_service.mirror, │ on .terraform/modules/something/terraform/modules/something_v2/mirror.tf line 100, in resource "aws_ecs_service" "mirror": │ 100: resource "aws_ecs_service" "mirror" { │ Couldn’t find anything with a quick Google, so I went with the trusty TF_LOG=DEBUG and found this: