amplify-cli: Amplify CLI Plugin Scan Failed

Note: If your question is regarding the AWS Amplify Console service, please log it in the official AWS Amplify Console forum

Which Category is your question related to? Amplify CLI Plugin scan failed.

Amplify CLI Version

You can use amplify -v to check the amplify cli version on your system

~/D/4/taskmaster   notifications ±  amplify -v Scanning for plugins… Plugin scan failed. Plugin scan failed. Error: Plugin scan failed. at scan (/usr/local/lib/node_modules/@aws-amplify/cli/src/plugin-manager.ts:137:11) ~/D/4/taskmaster   notifications ± 

What AWS Services are you utilizing?

Provide additional details e.g. code snippets

I uninstalled and reinstalled Amplify CLI. Keep getting the same errors over and over.

~/D/4/taskmaster   notifications ±  amplify -v Scanning for plugins… Plugin scan failed. Plugin scan failed. Error: Plugin scan failed. at scan (/usr/local/lib/node_modules/@aws-amplify/cli/src/plugin-manager.ts:137:11) ~/D/4/taskmaster   notifications ± 

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 2
  • Comments: 21 (7 by maintainers)

Most upvoted comments

Or, simply

sudo chown -R <user> ~/.amplify

I’m having the same issue as OP. Node version: 12.16.1 NPM version: 6.13.14 yarn version: 1.22.0 OS: Windows 10 Home, Version 1809, OS Build 17763.1039

I installed the amplify cli in my root directory C:\npm install -g @aws-amplify/cli I successfully got to the post-install.js, “Successfully installed the Amplify CLI…Javascript Getting Started…”. Anytime I run an amplify command, I receive the same error as OP. This includes amplify init, amplify -v, etc. This is the same error whether I run them in the root directory or my project directory.

I’ve tried reinstalling node, npm, yarn, webstorm, and amplify, and have also deleted and re-cloned my project from github. The set-up has worked for other members of my team without issue, but does not work on my environment, although it was working roughly 2 months ago when we began the project. Error started last week when we re-visited the project (I did have to pull it from master this time around.)

Willing to provide any other information necessary to assist with troubleshooting 😃

It seems the CLI does not have the permission to open the file ~/.amplify/plugins.json. This can be caused by reasons like, the file is open by some other program, or you didn’t grant the CLI permission to access it. You can remove that file (which will be regenerated by the CLI upon scan), and then run amplify plugin scan with admin right.

Hi @kaustavghosh06 . unfortunately that didnt do it for me. Here is my output:


Successfully installed the Amplify CLI

Javascript Getting Started - https://aws-amplify.github.io/docs/js/start

Android Getting Started - https://aws-amplify.github.io/docs/android/start

iOS Getting Started - https://aws-amplify.github.io/docs/ios/start

  • @aws-amplify/cli@4.14.1 updated 1 package in 30.37s ➜ healthisland git:(develop) ✗ amplify configure Scanning for plugins… Plugin scan failed. Plugin scan failed. Error: Plugin scan failed. at scan (/usr/local/lib/node_modules/@aws-amplify/cli/src/plugin-manager.ts:137:11) ➜ healthisland git:(develop) ✗ amplify -v Scanning for plugins… Plugin scan failed. Plugin scan failed. Error: Plugin scan failed. at scan (/usr/local/lib/node_modules/@aws-amplify/cli/src/plugin-manager.ts:137:11)