Unable to run appium-doctor

Viewed 31

I'm new to appium and during installation faced problem with appium-doctor. While running npm install appium-doctor -g and npm fund it gave me the following output:

├── https://github.com/sponsors/isaacs
│   └── glob@7.2.3
├── https://github.com/sponsors/feross
│   └── safe-buffer@5.2.1, buffer@5.7.1, base64-js@1.5.1, ieee754@1.2.1
└── https://github.com/sponsors/epoberezkin
    └── ajv@6.12.6

and after I've run appium-doctor command it ended up like this:

node:internal/modules/cjs/loader:959
  throw err;
  ^

Error: Cannot find module './build/bin/appium-doctor'
Require stack:
- /opt/homebrew/lib/node_modules/appium-doctor/appium-doctor.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:956:15)
    at Function.Module._load (node:internal/modules/cjs/loader:804:27)
    at Module.require (node:internal/modules/cjs/loader:1028:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Object.<anonymous> (/opt/homebrew/lib/node_modules/appium-doctor/appium-doctor.js:3:1)
    at Module._compile (node:internal/modules/cjs/loader:1126:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1180:10)
    at Module.load (node:internal/modules/cjs/loader:1004:32)
    at Function.Module._load (node:internal/modules/cjs/loader:839:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/opt/homebrew/lib/node_modules/appium-doctor/appium-doctor.js' ]
}

I've tried to reinstall both node and appium-doctor but it didn't helped.

M1 Monterey 12.5.1 | Homebrew 3.6.1 | node v16.17.0 | npm 8.19.1

1 Answers

Try to install their newest version, your current one is deprecated

npm install @appium/doctor -g
Related