-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Fixed Lambda handler for compiled languages #7129
Conversation
…l/vercel into fixed-handler-for-compiled
Codecov Report
@@ Coverage Diff @@
## main #7129 +/- ##
=======================================
Coverage 51.49% 51.49%
=======================================
Files 128 128
Lines 4979 4979
Branches 1212 1212
=======================================
Hits 2564 2564
Misses 2403 2403
Partials 12 12 Continue to review full report at Codecov.
|
Co-authored-by: Andy <AndyBitz@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good but it should add a new test, perhaps for Go, to prove it works correctly
…l/vercel into fixed-handler-for-compiled
Sounds great — I'll add some tests for all three shortly, once they work in production. |
Interpreted languages deployed to AWS Lambda use the following format for the
handler
of a Lambda:Compiled languages, on the other hand, use this format:
The latter previously wasn't supported at all, but after this change, it will be.
The logic does not rely on actually knowing whether a compiled or interpreted language is used. Instead, it just checks if the
handler
exists as-is on the file system, and if it does, it's considered a compiled language. If that's not the case, the first format is assumed and used instead.After this change, the error shown on the "Errors" tab of this Deployment should disappear.
It works with
vercel-plugin-go
,vercel-plugin-ruby
, andvercel-plugin-python
.Tests
yarn test-unit
Code Review