Loading...
Loading...
### Terraform Version ```shell Terraform v1.6.2 on windows_amd64 + provider registry.terraform.io/hashicorp/aws v5.22.0 ``` ### Terraform Configuration Files ``` import { to = aws_instance.name id = "i-xxxxxxxxxxxx" } ``` ### Debug Output will provide if needed. ### Expected Behavior Should be able to create generated.tf ### Actual Behavior Not able to create generated.tf ``` terraform plan -generate-config-out="generated.tf" aws_instance.name: Preparing import... [id=i-xxxxxxxxxxxxxx] aws_instance.name: Refreshing state... [id=i-xxxxxxxxxxxxxx] Planning failed. Terraform encountered an error while generating this plan. ╷ │ Error: Invalid character │ │ on generated.tf line 33: │ (source code not available) │ │ This character is not used within the language. ╵ ╷ │ Error: Invalid expression │ │ on generated.tf line 33: │ (source code not available) │ │ Expected the start of an expression, but found an invalid expression token. ╵ ╷ │ Error: Invalid character │ │ on generated.tf line 43: │ (source code not available) │ │ This character is not used within the language. ``` ### Steps to Reproduce ``` terraform init terraform plan -generate-config-out=generated.tf ``` ### Additional Context The EC2 instance I am trying for was migrated from bare metal to AWS using AWS migration service. ### References _No response_
Click on a version to see all relevant bugs
Terraform Integration
Learn more about where this data comes from
Bug Scrub Advisor
Streamline upgrades with automated vendor bug scrubs
BugZero Enterprise
Wish you caught this bug sooner? Get proactive today.