1

I have downloaded all the required tools and able to set up environment variable. macOS mojave : version 10.14.3

I have install node, appium and wd:

brew install node
npm install -g appium
npm install wd

when i try yo start appium server using appium & I got following error;

[1] 49460

-bash: appium: command not found

[1]+ Exit 127 appium

Updated:

None of app opens which is installed using npm command. The app installed using npm shows command not found error

It was working fine in macOs Mojave 10.14.2

Logs while using npm install -g appium

$npm install -g appium
npm WARN deprecated fsevents@2.0.1: Not Ready For Production
/Users/infotmt/bin/appium -> /Users/infotmt/lib/node_modules/appium/build/lib/main.js

> appium-chromedriver@4.9.0 install /Users/infotmt/lib/node_modules/appium/node_modules/appium-chromedriver
> node install-npm.js

[18:22:48] [Chromedriver Install] Installing Chromedriver version '2.44' for platform 'mac' and architecture '64'
[18:22:48] [Chromedriver Install] Opening temp file to write 'chromedriver_mac64' to...
[18:22:48] [Chromedriver Install] Opened temp file '/var/folders/ng/_2f_j78n1vg4gf8xnxvx9c780000gn/T/2019025-62054-1018qcf.8dtn/chromedriver_mac64.zip'
[18:22:48] [Chromedriver Install] Downloading https://chromedriver.storage.googleapis.com/2.44/chromedriver_mac64.zip...
[18:22:52] [Chromedriver Install] Writing binary content to /var/folders/ng/_2f_j78n1vg4gf8xnxvx9c780000gn/T/2019025-62054-1018qcf.8dtn/chromedriver_mac64.zip...
[18:22:52] [Chromedriver Install] Extracting /var/folders/ng/_2f_j78n1vg4gf8xnxvx9c780000gn/T/2019025-62054-1018qcf.8dtn/chromedriver_mac64.zip to /var/folders/ng/_2f_j78n1vg4gf8xnxvx9c780000gn/T/2019025-62054-1018qcf.8dtn/chromedriver_mac64
[18:22:52] [Chromedriver Install] Creating /Users/infotmt/lib/node_modules/appium/node_modules/appium-chromedriver/chromedriver/mac...
[18:22:52] [Chromedriver Install] Copying unzipped binary, reading from /var/folders/ng/_2f_j78n1vg4gf8xnxvx9c780000gn/T/2019025-62054-1018qcf.8dtn/chromedriver_mac64/chromedriver...
[18:22:52] [Chromedriver Install] Writing to /Users/infotmt/lib/node_modules/appium/node_modules/appium-chromedriver/chromedriver/mac/chromedriver...
[18:22:52] [Chromedriver Install] /Users/infotmt/lib/node_modules/appium/node_modules/appium-chromedriver/chromedriver/mac/chromedriver successfully put in place

> appium-selendroid-driver@1.13.2 install /Users/infotmt/lib/node_modules/appium/node_modules/appium-selendroid-driver
> node ./bin/install.js

[18:22:54] Java version 1.8.0_202 found
[18:22:55] Ensuring /Users/infotmt/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid/download exists
[18:22:55] Downloading Selendroid standalone server version 0.17.0 from https://repo1.maven.org/maven2/io/selendroid/selendroid-standalone/0.17.0/selendroid-standalone-0.17.0-with-dependencies.jar --> /Users/infotmt/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid/download/selendroid-server-7cf7163ac47f1c46eff95b62f78b58c1dabdec534acc6632da3784739f6e9d82.jar
[18:23:07] Writing binary content to /Users/infotmt/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid/download/selendroid-server.jar.tmp
[18:23:07] Selendroid standalone server downloaded
[18:23:07] Determining AndroidManifest location
[18:23:07] Determining server apk location
[18:23:07] Extracting manifest and apk to /Users/infotmt/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid/download
[18:23:07] Copying manifest and apk to /Users/infotmt/lib/node_modules/appium/node_modules/appium-selendroid-driver/selendroid
[18:23:07] Cleaning up temp files
[18:23:07] Fixing AndroidManifest icon bug

> appium-windows-driver@1.5.1 install /Users/infotmt/lib/node_modules/appium/node_modules/appium-windows-driver
> node install-npm.js

Not installing WinAppDriver since did not detect a Windows system

> fsevents@2.0.1 install /Users/infotmt/lib/node_modules/appium/node_modules/fsevents
> [ -f fsevents.node ] || npm run prepare


> heapdump@0.3.12 install /Users/infotmt/lib/node_modules/appium/node_modules/heapdump
> node-gyp rebuild

  CXX(target) Release/obj.target/addon/src/heapdump.o
In file included from ../src/heapdump.cc:17:
../../nan/nan.h:1064:44: warning: 'ToString' is deprecated: Use maybe version
      [-Wdeprecated-declarations]
      v8::Local<v8::String> string = from->ToString(v8::Isolate::GetCurrent());
                                           ^
/Users/infotmt/.node-gyp/11.7.0/include/node/v8.h:2537:3: note: 'ToString' has
      been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version",
  ^
/Users/infotmt/.node-gyp/11.7.0/include/node/v8config.h:326:29: note: expanded
      from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
1 warning generated.
  SOLINK_MODULE(target) Release/addon.node
+ appium@1.10.1
added 493 packages from 406 contributors and updated 2 packages in 34.024s
Community
  • 1
  • 1
Suban Dhyako
  • 2,436
  • 4
  • 16
  • 38

7 Answers7

1

My advice is as follows:

1. Do not use Homebrew to install Node.js.

The best way to do this is to use the nvm version manager. I had many conflicts with Node.js on MacOS, but nvm is a bulletproof solution.

https://yoember.com/nodejs/the-best-way-to-install-node-js/

2. It is also highly recommended to use version managers for

Version managers take over Node/Ruby/Python/Java management from the system and allow you to install parallel versions and keep consistency of modules/packages/gems etc.

3. Then install the following packages:

npm install -g appium
npm install -g appium-doctor

After that you can check the list of all Appium dependencies:

appium-doctor --ios
appium-doctor --android

Follow the instructions and complete the list.

4. Never install modules/packages/gems... with sudo.

kubano
  • 633
  • 7
  • 10
1

The problem is that i installed the node/npm in very old version of mac. Then i upgraded the mac version to mojave. I solve the issue by factory resetting the mac and then updating it to latest version. After that i install node/npm and then appium. It works fine now.

Suban Dhyako
  • 2,436
  • 4
  • 16
  • 38
0

Are you able to start appium server using desktop client? https://github.com/appium/appium-desktop/releases/tag/v1.10.0

Also did you refer this https://github.com/appium/appium/issues/6738?

M1017108
  • 397
  • 5
  • 14
  • 1
    Appium desktop is working. The problem was I had installed appium server version in the old mac os and then updated it to mojave. I sloved this problem by clearing mac os to its default, and then update the os. After that i installed the appium sever again and it works – Suban Dhyako Feb 18 '19 at 04:26
0

Check your $PATH environment variable for existence of /Users/infotmt/bin.

Geno Chen
  • 4,916
  • 6
  • 21
  • 39
0

Try installing the desktop version from releases: https://github.com/appium/appium-desktop

Did you try to install appium-doctor?

Try running npm install -g appium-doctor as kubano tolds you. I'm currently using it in mojave, so feel free to ask me anything

astorlucas
  • 11
  • 4
0

Try installing appium if you installed using brew brew install appium it will install the appium server on local under user

Thanks!

  • As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community May 31 '22 at 12:04
0

brew install node npm install -g appium npm install wd

If not worked you can write sudo npm install -g appium