Description:
When passing a !Ref to a AWS::Serverless::LayerVersion to a nested AWS::Serverless::Application, sam build returns:
Error: Layer is an Invalid Layer Arn.
when using version 1.21.1
This does not happen in version 1.19.1.
I've minimized a test case, which can be found at:
https://github.com/JohanZackrisson/aws-sam-cli-bug
When passing in a arn string instead of a !Ref, it builds.
Steps to reproduce:
In the main folder do:
Non working test:
pip3 install aws-sam-cli -Iv aws-sam-cli==v1.21.1
sam build
Working test:
pip3 install aws-sam-cli -Iv aws-sam-cli==v1.19.1
sam build
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
- OS: Mac OS 11.2.3
sam --version: 1.21.1
- AWS region: eu-west-1