# How to handle this exception? Error communicating with the remote browser. It may have died

**URL:** <https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075>\
**Category:** Support\
**Created:** [September 12, 2016, 5:25am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075 "2016-09-12T05:25:28Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rajesh\_Ravuri](https://discuss.appium.io/letter_avatar_proxy/v4/letter/r/ac8455/32.png) [@Rajesh\_Ravuri](https://discuss.appium.io/u/Rajesh_Ravuri)\
**Post date:** [September 12, 2016, 5:25am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/1 "2016-09-12T05:25:28Z")

</div>

I was trying to launch the app and click on an element, and I see the below error.

org.openqa.selenium.remote.UnreachableBrowserException: Error communicating with the remote browser. It may have died.  
Build info: version: ‘unknown’, revision: ‘c7b525d’, time: ‘2016-09-01 14:52:30 -0700’  
System info: host: ‘Raja’, ip: ‘192.168.89.1’, os.name: ‘Windows 10’, os.arch: ‘amd64’, os.version: ‘10.0’, java.version: ‘1.8.0\_91’  
Driver info: driver.version: RemoteWebDriver  
Capabilities [{app=C:\Users\Rajesh\workspace\Android\_Test\Src\BookMyShow.apk, networkConnectionEnabled=true, warnings={}, databaseEnabled=false, deviceName=emulator-5554, platform=LINUX, desired={app=C:\Users\Rajesh\workspace\Android\_Test\Src\BookMyShow.apk, newCommandTimeout=100, platformName=Android, deviceName=Android Emulator}, newCommandTimeout=100, platformVersion=6.0, webStorageEnabled=false, locationContextEnabled=false, browserName=Android, takesScreenshot=true, javascriptEnabled=true, platformName=Android}]  
Session ID: bbf72b8d-d2af-491b-8cf5-bac5ed733033  
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:618)  
at io.appium.java\_client.AppiumDriver.execute(AppiumDriver.java:180)  
at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:369)  
at org.openqa.selenium.remote.RemoteWebDriver.findElementById(RemoteWebDriver.java:418)  
at BookMy.test(BookMy.java:28)  
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)  
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)  
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)  
at java.lang.reflect.Method.invoke(Unknown Source)  
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)  
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)  
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)  
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)  
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)  
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)  
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)  
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)  
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)  
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)  
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)  
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)  
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)  
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)  
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)  
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)  
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)  
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)  
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)  
Caused by: org.openqa.selenium.WebDriverException: No command or response codec has been defined. Unable to proceed  
Build info: version: ‘unknown’, revision: ‘c7b525d’, time: ‘2016-09-01 14:52:30 -0700’  
System info: host: ‘Raja’, ip: ‘192.168.89.1’, os.name: ‘Windows 10’, os.arch: ‘amd64’, os.version: ‘10.0’, java.version: ‘1.8.0\_91’  
Driver info: driver.version: RemoteWebDriver  
at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:153)  
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:597)  
… 27 more

Below are the details of the applications used and their versions along with code.

Appium: 1.4.16.1

Android Studio: 2.1

Android Version: 6.0(Marshmallow) - API 23(Rev 1)

Emulator Version: 25.1.17

Windows Version: 10 Home

Eclipse Version: Mars.2 Release (4.5.2)

Selenium Jar: JAVA 3.0.0-beta3 (PS: There is only 1 jar file downloaded from selenium website “client-combined-3.0.0-beta3-nodeps.jar”).

Below is the source code.

```
import static org.junit.Assert.*;
import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
import org.junit.Test;
import org.openqa.selenium.remote.DesiredCapabilities;
import io.appium.java_client.android.AndroidDriver;
import io.appium.java_client.remote.MobileCapabilityType;
import io.appium.java_client.remote.MobilePlatform;
 
public class BookMy {
 @Test public void test() throws MalformedURLException { 
 
File dir=new File("Src");
 File app=new File(dir, "BookMyShow.apk");  
 
DesiredCapabilities cap=new DesiredCapabilities(); 
cap.setCapability(MobileCapabilityType.PLATFORM_NAME, MobilePlatform.ANDROID); 
cap.setCapability(MobileCapabilityType.DEVICE_NAME, "Android Emulator"); 
cap.setCapability(MobileCapabilityType.NEW_COMMAND_TIMEOUT, "100"); 
cap.setCapability(MobileCapabilityType.APP, app.getAbsolutePath()); 
AndroidDriver driver=new AndroidDriver(new URL("http://127.0.0.1:4723/wd/hub"), cap); 
driver.findElementByName("Login").click();  
}
}
```

---

<div class="post-metadata">

**Author:** ![ajithsebastian94](https://discuss.appium.io/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@ajithsebastian94](https://discuss.appium.io/u/ajithsebastian94)\
**Post date:** [October 7, 2016, 7:09am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/2 "2016-10-07T07:09:13Z")

</div>

facing the same issue

---

<div class="post-metadata">

**Author:** ![ajithsebastian94](https://discuss.appium.io/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@ajithsebastian94](https://discuss.appium.io/u/ajithsebastian94)\
**Post date:** [October 7, 2016, 7:09am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/3 "2016-10-07T07:09:49Z")

</div>

please help to resolve the same issue

---

<div class="post-metadata">

**Author:** ![shabana-parveen](https://discuss.appium.io/letter_avatar_proxy/v4/letter/s/dfb087/32.png) [@shabana-parveen](https://discuss.appium.io/u/shabana-parveen)\
**Post date:** [October 12, 2016, 6:16am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/4 "2016-10-12T06:16:48Z")

</div>

Appium version 1.5.1, Android emulator Nexus 5.1, facing the same issue : -

[AndroidBootstrap] [BOOTSTRAP LOG] [debug] Using: UiSelector[INSTANCE=0, RESOURCE\_ID=com.net.shine:id/progress\_text]  
[AndroidBootstrap] [BOOTSTRAP LOG] [debug] Returning result: {“status”:0,“value”:{“ELEMENT”:“59”}}  
[debug] [AndroidBootstrap] Received command result from bootstrap  
[MJSONWP] Responding to client with driver.findElement() result: {“ELEMENT”:“59”}  
[HTTP] \<-- POST /wd/hub/session/b3371f08-6806-43b6-be4f-b3376a0eaefb/element 200 10 ms - 88  
[HTTP] --\> GET /wd/hub/session/b3371f08-6806-43b6-be4f-b3376a0eaefb/element/59/text {}  
[MJSONWP] Calling AppiumDriver.getText() with args: [“59”,“b3371f08-6806-43b6-be4f-b3376a0eaefb”]  
[debug] [AndroidBootstrap] Sending command to android: {“cmd”:“action”,“action”:“element:getText”,“params”:{“elementId”:“59”}}  
[AndroidBootstrap] [BOOTSTRAP LOG] [debug] Got data from client: {“cmd”:“action”,“action”:“element:getText”,“params”:{“elementId”:“59”}}  
[AndroidBootstrap] [BOOTSTRAP LOG] [debug] Got command of type ACTION  
[AndroidBootstrap] [BOOTSTRAP LOG] [debug] Got command action: getText  
[AndroidBootstrap] [BOOTSTRAP LOG] [debug] Returning result: {“status”:0,“value”:“Loading…”}  
[debug] [AndroidBootstrap] Received command result from bootstrap  
[MJSONWP] Responding to client with driver.getText() result: “Loading…”  
[HTTP] \<-- GET /wd/hub/session/b3371f08-6806-43b6-be4f-b3376a0eaefb/element/59/text 200 10 ms - 84  
^C

---

<div class="post-metadata">

**Author:** ![ajithsebastian94](https://discuss.appium.io/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@ajithsebastian94](https://discuss.appium.io/u/ajithsebastian94)\
**Post date:** [October 12, 2016, 11:31am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/5 "2016-10-12T11:31:45Z")

</div>

Please try with latest latest appium driver  
[https://search.maven.org/#search|ga|1|g%3A"io.appium"](https://search.maven.org/#search%7Cga%7C1%7Cg%3A%22io.appium%22)…

it worked for me

---

<div class="post-metadata">

**Author:** ![ajithsebastian94](https://discuss.appium.io/letter_avatar_proxy/v4/letter/a/f08c70/32.png) [@ajithsebastian94](https://discuss.appium.io/u/ajithsebastian94)\
**Post date:** [October 12, 2016, 11:49am UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/6 "2016-10-12T11:49:55Z")

</div>

please uses the latest appium jar file in eclipse

---

<div class="post-metadata">

**Author:** ![vaibhav\_khachane](https://discuss.appium.io/letter_avatar_proxy/v4/letter/v/b782af/32.png) [@vaibhav\_khachane](https://discuss.appium.io/u/vaibhav_khachane)\
**Post date:** [October 12, 2016, 12:03pm UTC](https://discuss.appium.io/t/how-to-handle-this-exception-error-communicating-with-the-remote-browser-it-may-have-died/12075/7 "2016-10-12T12:03:11Z")

</div>

@Rajesh_Ravuri:- Have u add java-client-3.2.0.jar library?  
[https://search.maven.org/#search|ga|1|g%3Aio.appium%20a%3Ajava-client](https://search.maven.org/#search%7Cga%7C1%7Cg%3Aio.appium%20a%3Ajava-client)
