serverless-plugin-typescript icon indicating copy to clipboard operation
serverless-plugin-typescript copied to clipboard

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

Open jrobens opened this issue 4 years ago • 1 comments

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

jrobens avatar Jun 24 '21 01:06 jrobens

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.

x71c9 avatar Nov 14 '22 15:11 x71c9