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
Given an ALB event with multiValueQueryStringParameters but one of the value fails decodeURIComponent , the promise isnt handled at all. Expectation is that it should return an error and consumers treat that error
Thanks for the report. Serverless Express catches errors and returns to a response to the event source with the error in a format expected by the event source. For example, API Gateway expects a statusCode so it returns 500 along with the error. This is usually what you want, since if the Lambda throws an error, API Gateway returns a different error to the client. See:
If you really want to throw an error, you can do something like const response = await serverlessExpressInstance(event) and inspect it for a 500, and then throw.
Given an ALB event with multiValueQueryStringParameters but one of the value fails
decodeURIComponent
, the promise isnt handled at all. Expectation is that it should return an error and consumers treat that errorserverless-express/src/event-sources/aws/alb.js
Line 40 in 1376bd0
serverless-express/src/event-sources/aws/alb.js
Line 17 in 1376bd0
The below test wont even report the failure since the promise is left unhandled
The text was updated successfully, but these errors were encountered: