serverless-plugin-aws-alerts icon indicating copy to clipboard operation
serverless-plugin-aws-alerts copied to clipboard

Cannot install plugin due to Husky `command sh -c husky install`

Open kylez-ithaka opened this issue 3 years ago • 2 comments

This is a Bug Report

Description

For bug reports:

What went wrong?

Trying to install serverless plugin - it fails due to husky command Other serverless plugins install fine Tried a variety of install commands

  • npm install [email protected] --only=production
  • npm i serverless-plugin-aws-alerts
  • npm install serverless-plugin-aws-alerts --save-dev
  • npm install --save serverless-plugin-aws-alerts

What did you expect should have happened?

The plugin would install

What was the config you used?

Tried against working serverless projects - Node JS, and a Java one

What stacktrace or error message from your provider did you see?

$ npm i serverless-plugin-aws-alerts
npm ERR! code 1
npm ERR! path /.../node_modules/serverless-plugin-aws-alerts
npm ERR! command failed
npm ERR! command sh -c husky install
npm ERR! .git can't be found (see https://git.io/Jc3F9)

Additional Data

NPM version

$ npm --version
7.20.5
  • Serverless Framework Version:
$ serverless --version
Framework Core: 2.44.0 (standalone)
Plugin: 5.2.0
SDK: 4.2.3
Components: 3.11.0
  • Stack Trace:
  • Provider Error messages:

kylez-ithaka avatar Aug 11 '21 16:08 kylez-ithaka

Any movement on this issue? Looks like there may have been some changes to the post install handling in npm7 - I tested installing serverless-plugin-aws-alerts with several versions of npm7, but as soon as I downgraded to the latest npm v6 install worked fine.

unimaginativeGitHub avatar Sep 08 '21 17:09 unimaginativeGitHub

I had the same issue. Tried rolling back npm to the latest version of the 6.XX line (6.14.15) and then it worked. I'm not sure if it's an issue with all versions of 7 or just some recent version.

DavidRigglemanININ avatar Sep 08 '21 17:09 DavidRigglemanININ