Terraform v0.15.0
on linux_amd64
I am getting " Error: Provider produced inconsistent final plan "
Some brief scenario, I had successfully applied the operation using source_code_hash = "{data.archive_file.zip.output_base64sha256} " method.
Due to hashing replacement without any changes on the script ( main.py ), I decided to change my syntax to filebase64sha256(“{data.archive_file.zip.output_path}”).
With this action, I am getting an error as below {fyi: plan works but apply return error as below}:
│ When expanding the plan for
│ module.xxxxx.aws_lambda_function.lambda-function to include new values
│ learned so far during apply, provider “registry.terraform.io/hashicorp/aws”
│ produced an invalid new value for .source_code_hash: was
│ cty.StringVal(“xxxxx”), but now
│ cty.StringVal(“xxxx”).
│
│ This is a bug in the provider, which should be reported in the provider’s
│ own issue tracker.
To resolve this issue, I need to delete the existing lambda and create lambda again with the new syntax, which something that I cannot afford to produce on production environment.
Please advise/help to resolve this error. Thank you