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

Cannot run 'serverless package'

Open dl748 opened this issue 6 years ago • 2 comments

I just want say how seamless the serverless offline start is beautiful, love it.

Unfortunately I can seem to run the serverless package because of the following issues

#1 https://github.com/prisma/serverless-plugin-typescript/blob/master/src/index.ts#L169-L172 seems to fail for me EVERY time. I know this process works because if i remove the plugin, I can get it to build. Complains about '.build/.serverless' doesn't exist. It seems like the fs-extra copy method only works if the directory already exists. I put a if( !fs.existsSync(pathtobuildserverless) ) fs.mkdirSync(pathtobuildserverless)

#2 even when i do get past this, it complains that .serverless/deployment.zip doesn't exist, this is because I already have an artifact name defined but its in <rootDir>/deployment.zip not <rootDir>/.serverless/deployment.zip. it doesn't seem to recognize paths in the artifact

Unfortunately, in serverless I haven't found a way to turn off plugins depending on command, currently commenting out when I need to do a build.

dl748 avatar Sep 28 '18 20:09 dl748

Hi @dl748 are you still experiencing this issue with more recent versions?

JackCuthbert avatar Jul 19 '19 00:07 JackCuthbert

Still experiencing this, however, I have stopped using this plugin in favor of using serverless-webpack + ts-loader

dl748 avatar May 03 '21 13:05 dl748