serverless / serverless-plugin-typescript

Serverless plugin for zero-config Typescript support
MIT License
782 stars 222 forks source link

Fails with ENOENT with no .build directory and no other information #239

Open jrobens opened 3 years ago

jrobens commented 3 years ago

Maybe the compile failed - there is no .build directory although it works fine under other setup. There is a nuxt here as well.

Debugger attached. Serverless: Running "serverless" installed locally (in service node_modules) Serverless: Compiling with Typescript... Serverless: Using local tsconfig.json Serverless: Typescript compiled.

Error ---------------------------------------------------

Error: ENOENT: no such file or directory, symlink '/site/node_modules' -> '/site/.build/node_modules'

 For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.

Get Support -------------------------------------------- Docs: docs.serverless.com Bugs: github.com/serverless/serverless/issues Issues: forum.serverless.com

Your Environment Information --------------------------- Operating System: darwin Node Version: 14.17.0 Framework Version: 2.47.0 (local) Plugin Version: 5.4.0 SDK Version: 4.2.3 Components Version: 3.12.0

Waiting for the debugger to disconnect...

Process finished with exit code 1

x71c9 commented 1 year ago

In my tsconfig.json I had "noEmit":true.

By changing it to "noEmit":false it solved this issue.

Even though, you will need "noEmit":false since you will need to deploy the transpiled JS.