I'm running into this issue on `new aws.ec2.Instan...
# general
c
I'm running into this issue on
new aws.ec2.Instance
- tags are set to lowercase and sometimes converted to snake_case - has this been fixed?
<https://github.com/pulumi/pulumi-terraform/issues/38>
. I'm also seeing a random extra space after my tag value
Lowercase keys and extra whitespace
I initially tried
tags
as an array of
[{ k: v }]
and that's when my camelCase was converted to snake_case.
w
Definitely an issue here. I believe that as discussed at the end of https://github.com/pulumi/pulumi-terraform/issues/38 - the issue is that
tags
expects an object, not an array. It so happens that passing an array sort of works, but leads to these issues. As further noted in https://github.com/pulumi/pulumi-terraform/issues/147 and https://github.com/pulumi/pulumi-terraform/issues/285, it is our goal to make it a much earlier error to do this - to avoid running into these problems.
Hmm - although re-reading your code - it looks like you are passing an object. Did that code with an object result in hitting the problem here?
c
I've tried tags as an object, a list of objects, as well as passing
tag: [tags]
in the ec2 new instance as someone suggested but neither work
w
What output do you see when you pass an object like in the right side of your screenshot above? Does it really lead to what you show in the left side of that screenshot?
c
Yes
Thats the output, complete with an extra space after application and creator
g
I'm not able to reproduce this and it's strange you don't see this for all the tags. Is it possible you have a hidden character in the tag values in your editor?