Skip to content

fix: ignore function files with .ZIP extension #4003

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

Merged
merged 11 commits into from
Jan 12, 2022

Conversation

karagulamos
Copy link
Contributor

@karagulamos karagulamos commented Jan 10, 2022

Fixes #4001

When serving functions via netlify functions:serve, the functions registry incorrectly loads function bundles (i.e. zip archive) created by netlify/zip-it-and-ship-it#637. This results in a cryptic and unrecoverable error when we try to access the functions.

This fix ensures the registry ignores function bundles and logs a helpful message to the console.

@eduardoboucas

image

image

@erezrokah erezrokah added the type: bug code to address defects in shipped code label Jan 10, 2022
eduardoboucas
eduardoboucas previously approved these changes Jan 11, 2022
Co-authored-by: Eduardo Bouças <mail@eduardoboucas.com>
Copy link
Member

@eduardoboucas eduardoboucas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@lukasholzer lukasholzer added the automerge Add to Kodiak auto merge queue label Jan 12, 2022
@kodiakhq kodiakhq bot merged commit e6f5239 into netlify:main Jan 12, 2022
@karagulamos karagulamos deleted the fix/function-serve-ignore-zip-file branch January 12, 2022 12:36
@karagulamos karagulamos restored the fix/function-serve-ignore-zip-file branch January 12, 2022 12:37
@karagulamos karagulamos deleted the fix/function-serve-ignore-zip-file branch January 18, 2022 11:08
@karagulamos karagulamos restored the fix/function-serve-ignore-zip-file branch January 18, 2022 11:09
@karagulamos karagulamos deleted the fix/function-serve-ignore-zip-file branch January 29, 2022 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Add to Kodiak auto merge queue type: bug code to address defects in shipped code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

When encountering a zip file, ignore it and show a log message that we haven't loaded the function
4 participants