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
This results in webpack trying to run on the src/functions/pytest/handler.py file (using serverless invoke local -f pytest):
Serverless: Bundling with Webpack...
asset src/functions/pytest/handler.js 1.14 KiB [emitted] (name: src/functions/pytest/handler) 1 related asset
./src/functions/pytest/handler.py 310 bytes [built] [code generated] [1 error]
ERROR in ./src/functions/pytest/handler.py 4:0
Module parse failed: Unexpected token (4:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|
|
> def pytest(event, context):
| body = {
| "message": "Your function executed successfully!",
Expected:
serverless-webpack should identify that the function does not have a node runtime and skip webpack compilation.
(Note: common is simply another typescript file with some of our common configurations used across multiple services)
Additional Data
Serverless-Webpack 5.4.1:
Webpack 5.23.0:
Serverless Framework 2.30.3:
Operating System macOS Catalina 10.15.7 19H15 x86_64:
The text was updated successfully, but these errors were encountered:
Bug Report
Description
when using a Typescript file for serverless configuration, the feature described in PR doesn't seem to check for Node runtimes.
Example serverless.ts:
This results in webpack trying to run on the
src/functions/pytest/handler.py
file (usingserverless invoke local -f pytest
):Expected:
serverless-webpack
should identify that the function does not have anode
runtime and skip webpack compilation.(Note:
common
is simply another typescript file with some of our common configurations used across multiple services)Additional Data
The text was updated successfully, but these errors were encountered: