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

Fix/discourage use of Yarn with serverless-webpack #316

dpiatek opened this Issue Feb 1, 2018 · 2 comments


None yet
2 participants
Copy link

dpiatek commented Feb 1, 2018

This is a Bug Report


We have a fairly straightforward serverless app that uses this package, yarn for module installation and the externals auto-packing config as described here .

We deploy our app from CircleCi which uses node 6.10.3/npm 3.x. We have a lambda that has npm dependencies, and within node_modules they are being hoisted as they are shared. When serverless-webpack does auto-packing it runs an npm install which results in an incomplete package - the lambda fails because the hoisted dependencies are not there.

Our fix was to upgrade to npm 5.x on CircleCI, which creates the package-lock.json, but really it would be great if the docs were explicit that this is going on behind the scenes - or ideally, support yarn.

Happy to help with this and many thanks for your hard work.

Additional Data

  • Serverless-Webpack Version you're using: 4.0.0
  • Webpack version you're using: 3.8.1
  • Serverless Framework Version you're using: 1.24.0
  • Operating System: Ubuntu 14.04

This comment has been minimized.

Copy link

HyperBrain commented Feb 1, 2018

@dpiatek Thanks for the suggestion, fully agree with that 👍

There is already a feature task #286 that targets exactly the solution for the problem.

Maybe for now, until the feature is there, it would help to explicitly state possible problems and safe solutions in the README. This issue could be used for a README improvement though.

As you are deeply involved with the yarn issue, could you add a PR for a proper README extension, that will help users to workaround the problem for now? 😄


This comment has been minimized.

Copy link
Contributor Author

dpiatek commented Feb 1, 2018

Yes, saw that @HyperBrain ! Thought I'll add a separate issue for people who might encounter it.

Happy to do the README PR :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment