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

Invalid E1019 error with nested Transform function #3210

Closed
szechyjs opened this issue May 3, 2024 · 2 comments
Closed

Invalid E1019 error with nested Transform function #3210

szechyjs opened this issue May 3, 2024 · 2 comments

Comments

@szechyjs
Copy link

szechyjs commented May 3, 2024

CloudFormation Lint Version

0.87.1

What operating system are you using?

Ubuntu

Describe the bug

Receive the following error E1019 Sub parameter should use a valid function for Resources/FooS3Bucket/Properties/BucketName/Fn::Sub however the following template is valid and builds just fine in CF.

Expected behavior

It should not be an error. I suspect Fn::Transform needs added to the list of allowable functions here: https://github.com/aws-cloudformation/cfn-lint/blob/main/src/cfnlint/rules/functions/Sub.py#L32

Reproduction template

BucketName: !Sub
  - "${EnvironmentLower}-foo-bar"
  - EnvironmentLower:
      Fn::Transform:
        Name: String
        Parameters:
          InputString: !Ref Environment
          Operation: Lower
@kddejong
Copy link
Contributor

kddejong commented May 3, 2024

We may be able to create a workaround for this one but in general we are tracking transform issues here #476

@kddejong
Copy link
Contributor

kddejong commented May 9, 2024

Fn Transform in a sub shouldn't toss an error anymore.

@kddejong kddejong closed this as completed May 9, 2024
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

No branches or pull requests

2 participants