appium / appium-doctor

[Deprecated] Please use https://github.com/appium/appium/tree/master/packages/doctor
Apache License 2.0
128 stars 34 forks source link

Issue with finding mjpeg-consumer #84

Open NirBY opened 4 years ago

NirBY commented 4 years ago

Warning:

w-cr8:~ cellactqa$ npm ls -g -j mjpeg-consumer
{
  "dependencies": {
    "appium": {
      "version": "1.15.1",
      "from": "appium",
      "resolved": "https://registry.npmjs.org/appium/-/appium-1.15.1.tgz",
      "dependencies": {
        "appium-xcuitest-driver": {
          "version": "2.133.1",
          "from": "appium-xcuitest-driver@2.133.1",
          "resolved": "https://registry.npmjs.org/appium-xcuitest-driver/-/appium-xcuitest-driver-2.133.1.tgz",
          "dependencies": {
            "mjpeg-consumer": {
              "version": "2.0.0",
              "from": "mjpeg-consumer",
              "resolved": "https://registry.npmjs.org/mjpeg-consumer/-/mjpeg-consumer-2.0.0.tgz"
            }
          }
        }
      }
    }
  }
}
w-cr8:~ cellactqa$ 
w-cr8:~ cellactqa$ 
w-cr8:~ cellactqa$ 
w-cr8:~ cellactqa$ appium-doctor
info AppiumDoctor Appium Doctor v.1.12.1
info AppiumDoctor ### Diagnostic for necessary dependencies starting ###
info AppiumDoctor  ✔ The Node.js binary was found at: /usr/local/bin/node
info AppiumDoctor  ✔ Node version is 10.16.3
info AppiumDoctor  ✔ Xcode is installed at: /Applications/Xcode.app/Contents/Developer
info AppiumDoctor  ✔ Xcode Command Line Tools are installed in: /Applications/Xcode.app/Contents/Developer
info AppiumDoctor  ✔ DevToolsSecurity is enabled.
info AppiumDoctor  ✔ The Authorization DB is set up properly.
info AppiumDoctor  ✔ Carthage was found at: /usr/local/bin/carthage. Installed version is: 0.33.0
info AppiumDoctor  ✔ HOME is set to: /Users/cellactqa
info AppiumDoctor  ✔ ANDROID_HOME is set to: /Users/cellactqa/Library/Android/sdk
info AppiumDoctor  ✔ JAVA_HOME is set to: /Library/Java/JavaVirtualMachines/jdk1.8.0_192.jdk/Contents/Home
info AppiumDoctor  ✔ adb exists at: /Users/cellactqa/Library/Android/sdk/platform-tools/adb
info AppiumDoctor  ✔ android exists at: /Users/cellactqa/Library/Android/sdk/tools/android
info AppiumDoctor  ✔ emulator exists at: /Users/cellactqa/Library/Android/sdk/tools/emulator
info AppiumDoctor  ✔ Bin directory of $JAVA_HOME is set
info AppiumDoctor ### Diagnostic for necessary dependencies completed, no fix needed. ###
info AppiumDoctor 
info AppiumDoctor ### Diagnostic for optional dependencies starting ###
info AppiumDoctor  ✔ opencv4nodejs is installed at: /usr/local/lib. Installed version is: 5.4.0
info AppiumDoctor  ✔ ffmpeg is installed at: /usr/local/bin/ffmpeg. ffmpeg version 4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
WARN AppiumDoctor  ✖ mjpeg-consumer cannot be found.
info AppiumDoctor  ✔ idb and idb_companion are installed
info AppiumDoctor  ✔ applesimutils is installed at: /usr/local/bin/applesimutils. Installed versions are: applesimutils 0.7.2
info AppiumDoctor  ✔ bundletool.jar is installed at: /Users/cellactqa/Library/Android/sdk/build-tools/bundletool.jar
info AppiumDoctor ### Diagnostic for optional dependencies completed, one fix possible. ###
info AppiumDoctor 
info AppiumDoctor ### Optional Manual Fixes ###
info AppiumDoctor The configuration can install optionally. Please do the following manually:
WARN AppiumDoctor  ➜ mjpeg-consumer module is required to use MJPEG-over-HTTP features. Please install it with 'npm i -g mjpeg-consumer'.
info AppiumDoctor 
info AppiumDoctor ###
info AppiumDoctor 
info AppiumDoctor Bye! Run appium-doctor again when all manual fixes have been applied!
jlipps commented 4 years ago

Just because mjpeg-consumer is installed globally doesn't make it available to other node projects. You need to add your global node_modules folder to your NODE_PATH env var.

NirBY commented 4 years ago

Didn't worked. Used - https://stackoverflow.com/a/13469613

jlipps commented 4 years ago

what happens if you run node and then in the interpreter, run require('mjpeg-consumer')?

NirBY commented 4 years ago

I have got: image

w-cr8:~ cellactqa$ node const mc = require('mjpeg-consumer'); undefined

imurchie commented 4 years ago

The command appium-doctor is running is

npm ls -g -j -l mjpeg-consumer

What is the output of that? Perhaps there is something odd going on in the parsing...

NirBY commented 4 years ago

Attached: mjpeg-consumer.txt

imurchie commented 4 years ago

It looks like mjpeg-consumer is installed into your Appium installation?

If this is the case, this is not something that appium-doctor will pick up, because it's not the way that it ought to be installed (in this case, every update of Appium would require an update of mjpeg-consumer, which does not make a lot of sense).

Jitu1888 commented 3 years ago

Please help me out from this issue