5

When installing mfpdev-cli via npm I'm receiving the following error:

$ npm install -g mfpdev-cli@latest
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-adapter-actions
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-android-support
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-config
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-preview
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-pull
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-push
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-register
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-webencrypt
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-app-webupdate
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-cmd-adapter
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-cmd-app
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-cmd-config
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-cmd-info
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-cmd-server
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-cordova-support
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-errors
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-exec
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-ios-support
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-browser-support
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-mbs
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-server-support
npm ERR! addLocal Could not install /usr/local/lib/node_modules/mdo-windows-support
npm ERR! addLocal Could not install /usr/local/lib/node_modules/platform-manager
npm ERR! fetch failed https://registry.npmjs.org/ibm-strings/-/ibm-strings-0.1.4.tgz
npm WARN retry will retry, error on last attempt: Error: fetch failed with status code 404
npm ERR! fetch failed https://registry.npmjs.org/mfp-config-xml/-/mfp-config-xml-0.0.3.tgz
npm WARN retry will retry, error on last attempt: Error: fetch failed with status code 404
npm ERR! fetch failed https://registry.npmjs.org/pluggington/-/pluggington-0.3.3.tgz
npm WARN retry will retry, error on last attempt: Error: fetch failed with status code 404

Any ideas on how to get around this and install the latest version of the MobileFirst CLI? I'm running npm version 3.10.7 on Mac OS X 10.11.6 and my node version is 4.2.4.

Thanks for your help,

John

John Gerken
  • 686
  • 6
  • 13

3 Answers3

3

I have experienced the same issue.

I checked my npm version and it was 3.10.9. I downgraded it to 2.14.7, what has resolved my issues regarding the 404 error.

dirtydanee
  • 6,081
  • 2
  • 27
  • 43
Haris
  • 31
  • 1
3

Source: https://portal2portal.blogspot.in/2017/12/ibm-mobilefirst-8-commanding-cli.html

May 2018, npm install -g mfpdev-cli is still not working but I have found a way to make it work. The node version must be 7.3.0 and npm version must be 3.10.10.

Steps : 1. Downgrade (or Upgrade) node to 7.3.0. Copy and paste these commands to remove node.

$ sudo rm -rf /usr/local/{lib/node{,/.npm,_modules},bin,share/man}/{npm*,node*,man1/node*}

$ sudo apt autoremove

2. Now install the required version of node(7.3.0) using nvm or n or whatever you like. I have nvm installed so I did it with nvm

$ nvm install 7.3.0

With this command node and npm will automatically be installed to the required version. Verify npm and node before running the final command:

$ npm install -g mfpdev-cli

or :

$ sudo npm install -g mfpdev-cli

In my case it did not work with sudo. But it can work in your case maybe.

The credit goes to the original poster in that link. Kudos!

Mohd Naved
  • 448
  • 6
  • 20
2

It turns out that there was a change in the most recent version of npm in that only version 3.10.7 causes this issue to appear. The work-around is to regress your version of npm to 3.10.6.

The MobileFirst development team is working on a fix and I'll update this answer with that information once that occurs.

Please post below if you have any questions about this.

Thanks,

John Gerken

John Gerken
  • 686
  • 6
  • 13