Skip to content
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

Do not allow unresolved tokens to be used in construct IDs #1374

Closed
eladb opened this issue Dec 17, 2018 · 0 comments · Fixed by #1375
Closed

Do not allow unresolved tokens to be used in construct IDs #1374

eladb opened this issue Dec 17, 2018 · 0 comments · Fixed by #1375
Assignees

Comments

@eladb
Copy link
Contributor

eladb commented Dec 17, 2018

This won't work because when we generate the unique logical ID we will treat the stringified token as a normal string and that's not what the user intends. If the need arises, we can technically support "lazy" logical IDs (see API Gateway's LatestDeploymentResource).

eladb pushed a commit that referenced this issue Dec 17, 2018
Relax construct ID constraints to allow "/" (path seprator)
to be used in construct IDs, but convert it to "--" so it won't
collide with path strings.

It's quite rare for people to actually try to find a construct
by their ID (it's mostly "write-only") and the logical ID is eventually
mangled anyway when synthesized to CFN.

Fails if the construct ID contains a token. This won't work because
we mangle the IDs as strings when we generate the logical ID
and the construct's unique ID, and stringified tokens won't be
resolved.

Fixes #1351
Fixes #1374
@eladb eladb self-assigned this Dec 17, 2018
eladb pushed a commit that referenced this issue Dec 17, 2018
…1375)

Relax construct ID constraints to allow "/" (path seprator)
to be used in construct IDs, but convert it to "--" so it won't
collide with path strings.

It's quite rare for people to actually try to find a construct
by their ID (it's mostly "write-only") and the logical ID is eventually
mangled anyway when synthesized to CFN.

Fails if the construct ID contains a token. This won't work because
we mangle the IDs as strings when we generate the logical ID
and the construct's unique ID, and stringified tokens won't be
resolved.

Fixes #1351
Fixes #1374
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant