Uh oh!
There was an error while loading. Please reload this page.
#147 Fix. The Appium node silent starting - #240
Conversation
TikhomirovSergey
commented
Sep 8, 2015
@Jonahss <developer>
<email>tichomirovsergey@gmail.com</email>
<name>Sergey Tikhomirov</name>
<url>https://github.com/TikhomirovSergey</url>
<id>TikhomirovSergey</id>
</developer>? :) |
TikhomirovSergey
commented
Sep 8, 2015
TikhomirovSergey
commented
Sep 8, 2015
These features send server output to an IDE console also. |
Jonahss
commented
Sep 8, 2015
Oh wow this IS the bomb, way to go. I'm liking it. I'm glad you included good exceptions for if appium or Nodejs aren't installed. @simonk how's it look to you? |
There was a problem hiding this comment.
Is this test going to pass on non-windows?
There was a problem hiding this comment.
It is passees on Mac OS X. But I'll remove this in order to avoid the confusion.
bootstraponline
commented
Sep 8, 2015
This PR is cool 👍 If I understand correctly, java-client is now able to programmatically start the appium node server. |
There was a problem hiding this comment.
Do you think it'd be more concise like this?
thrownewServerNotStartedException("The local appium server has not been started.");The message An unexpected throwable has been caught! isn't very useful to an end user.
TikhomirovSergey
commented
Sep 9, 2015
Thanks @bootstraponline for remarks. I'll make improvements as sson as possible.
Yep! You are exactly right! |
TikhomirovSergey
commented
Sep 9, 2015
@bootstraponline@Jonahss Improvements were done. I added custom_node_path.properties. Here are paths to appium.js installed with Appium desktop application. They are needed for 2-4 tests. Make sure that Appium desktop application is installed on your environment |
bootstraponline
commented
Sep 9, 2015
👍 |
#147 Fix. The Appium node silent starting
saikrishna321
commented
Sep 21, 2015
@TikhomirovSergey i tried running appium-server programmatically from java_client(3.2.0),node version(v0.12.7), i get the below error io.appium.java_client.service.local.InvalidNodeJSInstance: Node.js is not installed |
Jonahss
commented
Sep 21, 2015
@saikrishna321 Sergey is on vacation for the next week or two. You can take a look at the source and try to see whats going wrong with your setup. |
prachi02
commented
Sep 22, 2015
Hi, I am getting the following error ,when trying to do so module.js:340 |
muralidhar1620
commented
Sep 22, 2015
Tried with : Seeing Exception in thread "main" org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure. // ########### Initialization in Script was |
prachi02
commented
Sep 23, 2015
@muralidhar1620 ...first try the default one and see what you are getting |
prachi02
commented
Sep 23, 2015
@muralidhar1620 ...for me this piece of code is working service = AppiumDriverLocalService.buildService(new AppiumServiceBuilder().usingDriverExecutable(new File("C:/Program Files/nodejs/node.exe")).withAppiumJS(new File("D:/appium/Appium/node_modules/appium/bin/appium.js"))); |
prachi02
commented
Sep 23, 2015
@muralidhar1620 ...you have to give path of appium.js not appium.exe.....and another thing in capabilities section give this: Not this: this gives error what you are getting |
muralidhar1620
commented
Sep 23, 2015
@prachi02 Tried mentioned steps and i am seeing Error Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/validator/routines/InetAddressValidator |
prachi02
commented
Sep 23, 2015
@muralidhar1620 ....paste your entire code which you are using |
muralidhar1620
commented
Sep 23, 2015
Thanks @prachi02 for Reply .selenium 2.47.1 and java client 3.2.0 exists but not common validators 1.41 code import java.io.File; import org.openqa.selenium.By; public class PerkTVDriverScript { } |
muralidhar1620
commented
Sep 23, 2015
@prachi02 Also node.js is installedin windows and i am able to launch appium server from that manually.Thanks! |
prachi02
commented
Sep 23, 2015
@muralidhar1620 ...no problem.... |
muralidhar1620
commented
Sep 23, 2015
@prachi02 Did you got the issue ?.Can you please paste all working code and its dependencies.Thanks! |
prachi02
commented
Sep 23, 2015
In this section of code /AppiumDriverLocalService service = AppiumDriverLocalService.buildService(new AppiumServiceBuilder().usingDriverExecutable(new File("C:/Program Files/nodejs/node.exe")).withAppiumJS(new File("E:/AppiumForWindows-1.3.4.1/Appium/node_modules/appium/bin/appium.js"))); Uncomment till service.start() and comment second last line like AppiumDriverLocalService service = AppiumDriverLocalService.buildService(new AppiumServiceBuilder().usingDriverExecutable(new File("C:/Program Files/nodejs/node.exe")).withAppiumJS(new File("E:/AppiumForWindows-1.3.4.1/Appium/node_modules/appium/bin/appium.js"))); Try the above code |
muralidhar1620
commented
Sep 23, 2015
@prachi02 I tried with mentioned code before and now and i am facing with same issue Can connect to my machine Remotely(Teamviewer) and check please Email id : muralidhar230@gmail.com |
prachi02
commented
Sep 23, 2015
@muralidhar1620 ...are you remotely login??..... |
w2a
commented
Sep 24, 2015
I just tried the new 3.2 and the appium server works absolutely fine without any issues. I have recorded a tutorial on the same if anyone needs step by step information can go through the youtube video from below link: Thanks, |
saikrishna321
commented
Sep 25, 2015
@w2a i was able to start the appium by below code appiumDriverLocalService = AppiumDriverLocalService But i have an issue, it says adb could not be located in tools and platform-tools.. I have my ANDROID_HOME set in both .bash_profile and .zshrc profile .. 1.when i run my tests form commandline it works. But when i start the test programmatically appium throws error. Find the below logs 2015-09-25 10:38:23:222 - info: Welcome to Appium v1.4.11 (REV 8cf8311f00e59a2b10fde1834fcf6d5ace6fbcd0) |
w2a
commented
Sep 25, 2015
do you have the androidStudio installed at this location: /Users/saikrisv/Library/Android/sdk/platform-tools and same you have given in the .bash_profile The issue is related to the path variables not configure properly or have you ever installed Android SDK prior to installing the latest one that you are working on? Thanks, |
saikrishna321
commented
Sep 25, 2015
export ANDROID_HOME=/Users/saikrisv/Library/Android/sdk when i do "adb devices" from terminal, i can see devices..... |
muralidhar1620
commented
Sep 26, 2015
mzeljkovic
commented
Sep 28, 2015
Hi All, Awesome work!! Cheers, |
TikhomirovSergey
commented
Sep 29, 2015
Hi guys!
It doesn't work because a path to node.js is not defined in your PATH environment variable. Why? I don't know. Please check it. Here is the example for Win: The same works fine on MAC OS X (I've checked it)/Linux if you download and install Node.js from: https://node js.org. Also the installation process should define the path to the instance in your PATH variable if everything is going properly. Otherwise please open a new issue here: |
TikhomirovSergey
commented
Sep 29, 2015
Here are samples with usuful comments |
VenkateshPS
commented
Nov 19, 2015
can some one post command to start this service on mac Regards, |
savishy
commented
Nov 20, 2015
This is just fantastic! |
VenkateshPS
commented
Nov 21, 2015
my question was how different the arguments for the code will be on mac? as i have installed and using Appium.app 1.4.13 |
saikrishna321
commented
Nov 24, 2015
@VenkateshPS There would b not different in code for mac.. All you need is appium installed from node. |
shivakrishnach31
commented
Dec 3, 2015
HI @saikrishna321 and @w2a , Below is my code: package abc; import java.io.File; import org.openqa.selenium.remote.DesiredCapabilities; import io.appium.java_client.AppiumDriver; public class NewTest { } I got the below error when I run the above code. Could you please help me to get rid of this. [TestNG] Running: �[36minfo�[39m: Welcome to Appium v1.4.13 (REV c75d8adcb66a75818a542fe1891a34260c21f76a) Default suite Total tests run: 1, Failures: 1, Skips: 0[TestNG] Time taken by org.testng.reporters.EmailableReporter2@c46bcd4: 37 ms |
saikrishna321
commented
Dec 4, 2015
@shivakrishnach31 look at the code below |
TikhomirovSergey
commented
Dec 21, 2015
Guys |
daniellozynski
commented
Feb 5, 2016
Hi, one of the server arguments is .withIPAdress() - what would be a scenario where I would change the IP address of the Appium server ? Not sure if I got this right... |

Change list is below:
Requirements
Warning (!!!) Node.js versions which lower than 0.12 are deprecated for Appium server >=1.4.10
Which capabilities these features provide
Proposed features provide abilities and options of the starting of a local Appium node server. End users still able to open apps as usual
when the server has been working locally\remotely. Now they are free to launch a local Appium node server and open their app for the further testing the following way:
How to prepare the local service before the starting
If there is no specific parameters then
If there should be non default parameters specified then
or
Lists of available server side flags are here:
Which parameters also can be defined
or
Some more detailes about this use case. The node server instance which has been installed via npm is supposed to be used by default. This instance can be overridden if an end user defines the "appium.node.path" system property any available way.
Externally defined file path or file path defined at system properties should contain a full path to the appium.js file (!). These server instances should have the proper structure.
How to create an AppiumDriver instance
The common constructor is still available
There are new constructors:
An instance of AppiumDriverLocalService which has passed through constructors will be stopped when
If there is need to keep the service alive during a long time then something like that is available