You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've tried out your example and noticed that the camelcase dependency for the "random" package doesn't actually get hoisted.
When you add a dependency that does get hoisted, ie bluebird, it seems to break serverless' packaging logic. Serverless depends on 'npm ls --production=true --parseable=true' when it is excluding dev dependencies. It looks like the 'npm ls' command gets confused when it tries to find @org/random's new bluebird dependency, since it is hoisted and does not exist in @org/random/node_modules, even though it is in sls-random/node_modules.
My current workaround is to manually build my own list of 'include' files, write the list to a json file, and then reference that json file in the serverless.yml file.
The text was updated successfully, but these errors were encountered:
I ended up taking a different approach where I recursively parsed the package.json files for production dependencies, built a json file, and referenced that file when setting the package configuration.
I've tried out your example and noticed that the camelcase dependency for the "random" package doesn't actually get hoisted.
When you add a dependency that does get hoisted, ie bluebird, it seems to break serverless' packaging logic. Serverless depends on 'npm ls --production=true --parseable=true' when it is excluding dev dependencies. It looks like the 'npm ls' command gets confused when it tries to find @org/random's new bluebird dependency, since it is hoisted and does not exist in @org/random/node_modules, even though it is in sls-random/node_modules.
My current workaround is to manually build my own list of 'include' files, write the list to a json file, and then reference that json file in the serverless.yml file.
The text was updated successfully, but these errors were encountered: