serverless-layers
serverless-layers copied to clipboard
Lambda layer install skipped because it has no other layers
Hi, after setup my layers pointing to a bucket I'm getting this warning:
Serverless: [ LayersPlugin ]: => default
... ○ Uploading layer package...
... ○ OK...
... ○ New layer version published...
... ○ Uploading remote /Users/scastro/Projects/Samuel/my-project/package.json...
... ○ OK...
... ○ Adding layers...
... ✓ provider - arn:aws:lambda:us-east-1:*********:my-project-dev-nodejs-default:1
... x (Skipped) function.function1 - because it has no other layers
... x (Skipped) function.function2 - because it has no other layers
... x (Skipped) function.function3 - because it has no other layers
... x (Skipped) function.function4 - because it has no other layers
... x (Skipped) function.function5 - because it has no other layers
...
...
This is my setup:
serverless-layers:
layersDeploymentBucket: ${ssm:/my-project/${self:custom.stage}/layer-deployment-bucket}
Versions:
"serverless": "2.69.1",
"serverless-layers": "^2.5.4",
Any thoughts?
Getting the same message - layer is being successfully built but is NOT attaching to any functions, despite explicitly listing them
serverless-layers:
dependenciesPath: ./requirements.txt
functions:
- login
- getnonce
- contracts
- cookie-authorizer
... x (Skipped) function.login - because it has no other layers
... x (Skipped) function.getnonce - because it has no other layers
... x (Skipped) function.contracts - because it has no other layers
... x (Skipped) function.cookie-authorizer - because it has no other layers`
[ LayersPlugin ]: => Layers Info
... ∅ (skipped) function.login
... ∅ (skipped) function.getnonce
... ∅ (skipped) function.contracts
... ∅ (skipped) function.cookie-authorizer
Downgrading to 2.5.3 fixes that issue, seems to be related to a change that was done here: https://github.com/agutoli/serverless-layers/commit/5a3c6b7635f5198dd9b930955a80eea505d288c8#diff-bfe9874d239014961b1ae4e89875a6155667db834a410aaaa2ebe3cf89820556R411
That if check is not correct, this now makes it so functions are always skipped
npm install -D [email protected] --save
helped
new version 2.6.1