-
Notifications
You must be signed in to change notification settings - Fork 417
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
v2.2.0 -> v2.2.1 broke my deployment workflow #202
Comments
Thanks for creating the issue. Can you post your webpack config and the function definitions from serverless.yml? Do the function handler definitions match the actual handler files, and finally which provider do you use (AWS, Google, OpenWhisk, etc.)? |
BTW: Do you see the new warning |
config:
func defs:
handler: yes, matching
Provider: AWS No, I don't see that warning in either version. |
Ok. The only difference between 2.2.0 and 2.2.1 is the warning message to prevent a crash in case the handler entry is not parseable or not set (see git diff). There was no change in any of the other parts of the code. I'm not sure where the changes you experience come from. What is strange is, that your chunk name is named
WAIT: I think the default output filename might have changed to [name].js to adapt the automatic entry point behavior! Before it used handler.js as fixed name, which is not flexible. Sorry for that - seems that commit was not published with 2.2.0 which it should have been. What you can do is to add an explicit output configuration in your webpack config like this:
Or you switch to webpack 2 or webpack 3 and use the automatic entry detection with slsw.lib.entries that will automatically set up things for you. |
Updated the comment above. |
Thanks for checking! Just quick-fixed with the output section for now. |
@bebbi Ok. Thanks for the feedback. I'm not sure if I should revert the default output settings as 2.2.1 is only a bugfix release and should not change behavior or lead to failing builds. What is your opinion on that? |
Looking in more detail at the diff 2.2.0 -> 2.2.1, it looks like there is a change in behaviour. It is introduced by this diff
where in 2.2.0, Whereas in 2.2.1, I haven't debugged what is name but it most likely is the chunk name, i.e. It would probably be easiest to simply fix this part in a 2.2.2 if that's possible. |
Oh, your comment update didn't show for me until now. |
Maybe best to revert in 2.2.2 and update + doc in 3? |
Yep I'll revert the change and release a 2.2.2 |
Just committed a fix and will release it now. The new behavior is pretty well documented in V3 and the now preferred automatic entry resolution as well. It was good that you've encountered it so quickly 👍 |
@bebbi Released! Can you do a sanity check if it now works again and then close the issue please? |
works, thanks much! |
This is a (Bug Report / Feature Proposal)
Bug
Description
[email protected] (and all versions before):
serverless webpack
bundles into the path .webpack/handler.js[email protected]
serverless webpack
bundles into the path .webpack/main.jsNo handler.js, and all functions relying on webpack don't work anymore.
(
serverless deploy
,serverless offline start
,serverless webpack
..)For bug reports:
serverless-webpack bundles into main.js
serverless-webpack bundles into handler.js
The same as ever. Change easily observable here when installing 2.2.0 vs 2.2.1
and running serverless webpack. The output with 2.2.1 is:
vs 2.2.0:
For feature proposals:
Similar or dependent issue(s):
Additional Data
2.2.1
1.13.3
1.19.0
The text was updated successfully, but these errors were encountered: