Unreachable Browser Exception using Appium -


i automating android app using appium. getting exception while using androiddriver(). below code snippet.

  public class test1 {  public static androiddriver driver;  public static void main(string[] args) throws exception {      file appdir= new file(system.getproperty("user.dir")+"/app/");      system.out.println(appdir);      file app=new file(appdir,"android-debug.apk");      desiredcapabilities cap=new desiredcapabilities();      cap.setcapability(mobilecapabilitytype.app,app.getabsolutepath());      cap.setcapability(mobilecapabilitytype.platform,mobileplatform.android);      cap.setcapability(mobilecapabilitytype.platform_name,"android");      cap.setcapability(mobilecapabilitytype.device_name,"my phone");      cap.setcapability(mobilecapabilitytype.version,"5.0.2");      cap.setcapability(androidmobilecapabilitytype.app_package,"com.ionicframework.appsix821050" );      cap.setcapability(androidmobilecapabilitytype.app_activity,"com.ionicframework.appsix821050.mainactivity" );      url url=new url("http:127.0.0.1:4723/wd/hub");      try     {     driver = new androiddriver(url, cap);     }     catch(exception e)     {         e.printstacktrace();     }  } 

}

following error found while running above code

org.openqa.selenium.remote.unreachablebrowserexception: not start new session. possible causes invalid address of remote server or browser start-up failure. build info: version: '2.39.0', revision: '14fa800511cc5d66d426e08b0b2ab926c7ed7398', time: '2013-12-16 13:18:38' system info: host: 'mindpro1-pc', ip: '192.168.0.103', os.name: 'windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.8.0_112' driver info: driver.version: androiddriver @ org.openqa.selenium.remote.remotewebdriver.execute(remotewebdriver.java:548) @ org.openqa.selenium.remote.remotewebdriver.startsession(remotewebdriver.java:216) @ org.openqa.selenium.remote.remotewebdriver.(remotewebdriver.java:111) @ org.openqa.selenium.remote.remotewebdriver.(remotewebdriver.java:129) @ org.openqa.selenium.android.androiddriver.(androiddriver.java:89) @ test1.main(test1.java:52) caused by: org.apache.http.client.clientprotocolexception @ org.apache.http.impl.client.abstracthttpclient.doexecute(abstracthttpclient.java:888) @ org.apache.http.impl.client.closeablehttpclient.execute(closeablehttpclient.java:71) @ org.apache.http.impl.client.closeablehttpclient.execute(closeablehttpclient.java:55) @ org.openqa.selenium.remote.httpcommandexecutor.fallbackexecute(httpcommandexecutor.java:319) @ org.openqa.selenium.remote.httpcommandexecutor.execute(httpcommandexecutor.java:298) @ org.openqa.selenium.remote.remotewebdriver.execute(remotewebdriver.java:527) ... 5 more caused by: org.apache.http.httpexception: cannot convert host uri: http:// @ org.apache.http.impl.conn.proxyselectorrouteplanner.determineproxy(proxyselectorrouteplanner.java:185) @ org.apache.http.impl.conn.proxyselectorrouteplanner.determineroute(proxyselectorrouteplanner.java:139) @ org.apache.http.impl.client.defaultrequestdirector.determineroute(defaultrequestdirector.java:763) @ org.apache.http.impl.client.defaultrequestdirector.execute(defaultrequestdirector.java:382) @ org.apache.http.impl.client.abstracthttpclient.doexecute(abstracthttpclient.java:884) ... 10 more caused by: java.net.urisyntaxexception: expected authority @ index 7: http:// @ java.net.uri$parser.fail(unknown source) @ java.net.uri$parser.failexpecting(unknown source) @ java.net.uri$parser.parsehierarchical(unknown source) @ java.net.uri$parser.parse(unknown source) @ java.net.uri.(unknown source) @ org.apache.http.impl.conn.proxyselectorrouteplanner.determineproxy(proxyselectorrouteplanner.java:183) ... 14 more`


Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -