-
Notifications
You must be signed in to change notification settings - Fork 440
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(lib): change the namespace of encoded string, list and number tokens #1148
Conversation
Makes sense.
Not sure about the implications of this.
Don't think Token interop should be a goal at the moment. |
It should just be a different bit mask 😁 I only wanted to explain what happens by using
Agree. I only wanted to be very clear about it, so I included that comment in the commit message. |
…kens To make sure CDK for Terraform tokens don't conflict with AWS CDK tokens we change the namespace of string, list and number tokens. For string tokens we use e.g. `${TFToken[1]}` instead of `${Token[1]}`. Likewise for list tokens (they will become `#{TFToken[1]}`). For number tokens we change the left part of the bitmask from `0xfbff` to `0xfdff` (which results in flipping bit 25 instead of bit 26). This change makes sure that tokens don't get accidentally resolved when e.g. a CDKTF token gets passed to an AWS CDK construct. However, it won't achieve full interoperability between the two token systems.
b72951f
to
943374a
Compare
One build was cancelled due to Docker rate limits
Gonna merge anyway. |
🎉🎉🎉 |
I'm going to lock this pull request because it has been closed for 30 days. This helps our maintainers find and focus on the active issues. If you've found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
To make sure CDK for Terraform tokens don't conflict with AWS CDK
tokens we change the namespace of string, list and number tokens.
For string tokens we use e.g.
${TFToken[1]}
instead of${Token[1]}
.Likewise for list tokens (they will become
#{TFToken[1]}
).For number tokens we change the left part of the bitmask from
0xfbff
to
0xfdff
(which results in flipping bit 25 instead of bit 26).This change makes sure that tokens don't get accidentally resolved
when e.g. a CDKTF token gets passed to an AWS CDK construct. However,
it won't achieve full interoperability between the two token systems.