AshenCrow
AshenCrow

Reputation: 165

Serverless Framework stuck downloading template

I'm starting a serverless project to learn it on windows, installed it with npm, ran serverless on PowerShell, selected the aws-node-express-dynamodb-api template, the problem is, it keeps stuck in Downloading aws-node-express-dynamodb-api template... forever and never finishes it or actually downloads anything, the only error in instalation was the following:

msvs_version not set from command line or npm config
gyp ERR! find VS VCINSTALLDIR not set, not running in VS Command Prompt
gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - not found
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the "Desktop development with C++" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************

It appears to be trying to configure Visual Studio, but I didn't worried since I don't use it.

Upvotes: 2

Views: 2370

Answers (1)

joematune
joematune

Reputation: 2080

My fix was to uninstall serverless and install again with a different version of Node. Look for npm warnings when you install serverless. For example,

$ npm install -g serverless
npm WARN npm npm does not support Node.js v14.0.0
...

The following version worked for me: node v15.0.1. You can download and install specific versions of Node with Node Version Manager.

$ nvm use 15.0.1
Now using node v15.0.1 (npm v7.0.3)

Alternatively, try a different install method: https://serverless.com/install

Upvotes: 2

Related Questions