New issue 2844 by santoshd...@gmail.com: The application WebDriver client
(Process org.openqa.selenium.android.app) has stopped unexpectedly
http://code.google.com/p/selenium/issues/detail?id=2844
I am working with ANDROID driver. I have followed instruction mentioned in
below link in detail and followed process mentioned in the page.
http://code.google.com/p/selenium/wiki/AndroidDriver
But i am getting error mentioned below
Symptoms
1) Emulator & Devices both are giving me same error "The application
WebDriver client (Process org.openqa.selenium.android.app) has stopped
unexpectedly.Please try again".
2) It happens every time during run.
3) I am only the one working on this project.
What i have tried so far
1) I have tried to use different versions Emulator & Handset.
Android 2.2 and above, but issue still persist.
Please find attached herewith the screenshot for your reference.
Thanks & Regards
Santosh Dhere.
Attachments:
ErrorScreenshot.ods 531 KB
Comment #1 on issue 2844 by barancev: The application WebDriver client
(Process org.openqa.selenium.android.app) has stopped unexpectedly
http://code.google.com/p/selenium/issues/detail?id=2844
(No comment was entered for this change.)
I have the same issue using Android Emulator ver.2.2,
android-server-2.12.0.apk and selenium-java-2.12.0.zip.
Simple google search test (from main android wiki page) crashes the Android
WebDriver application when trying to execute sendKeys("Cheese!") method.
Android OS LogCat output:
11-15 14:00:48.244: I/AndroidDriverServlet(308): Executing: [send keys: 0
org.openqa.selenium.support.events.EventFiringWebDriver$EventFiringWebElement@dd321f84,
[Cheese!]] at URL: /session/1321365620872/element/0/value)
11-15 14:00:48.414: D/dalvikvm(308): GC_FOR_MALLOC freed 2004 objects /
461032 bytes in 152ms
11-15 14:00:48.544: D/dalvikvm(308): GC_FOR_MALLOC freed 145 objects /
79560 bytes in 123ms
11-15 14:00:49.514: D/dalvikvm(308): GC_FOR_MALLOC freed 125 objects /
459088 bytes in 136ms
11-15 14:00:49.694: D/dalvikvm(308): GC_FOR_MALLOC freed 58 objects /
155616 bytes in 152ms
11-15 14:00:50.024: I/ActivityManager(59): Process com.android.alarmclock
(pid 160) has died.
11-15 14:00:52.094: D/dalvikvm(308): GC_FOR_MALLOC freed 281 objects /
767408 bytes in 141ms
11-15 14:00:53.444: I/dalvikvm(308): Could not find method
android.view.MotionEvent.setSource, referenced from method
org.openqa.selenium.android.EventSender$1.run
11-15 14:00:53.444: W/dalvikvm(308): VFY: unable to resolve virtual method
55: Landroid/view/MotionEvent;.setSource (I)V
11-15 14:00:53.464: D/dalvikvm(308): VFY: replacing opcode 0x6e at 0x0027
11-15 14:00:53.464: D/dalvikvm(308): VFY: dead code 0x002a-0043 in
Lorg/openqa/selenium/android/EventSender$1;.run ()V
11-15 14:00:53.464: D/AndroidRuntime(308): Shutting down VM
11-15 14:00:53.464: W/dalvikvm(308): threadid=1: thread exiting with
uncaught exception (group=0x4001d800)
11-15 14:00:53.484: E/AndroidRuntime(308): FATAL EXCEPTION: main
11-15 14:00:53.484: E/AndroidRuntime(308): java.lang.NoSuchMethodError:
android.view.MotionEvent.setSource
11-15 14:00:53.484: E/AndroidRuntime(308): at
org.openqa.selenium.android.EventSender$1.run(EventSender.java:56)
11-15 14:00:53.484: E/AndroidRuntime(308): at
android.os.Handler.handleCallback(Handler.java:587)
11-15 14:00:53.484: E/AndroidRuntime(308): at
android.os.Handler.dispatchMessage(Handler.java:92)
11-15 14:00:53.484: E/AndroidRuntime(308): at
android.os.Looper.loop(Looper.java:123)
11-15 14:00:53.484: E/AndroidRuntime(308): at
android.app.ActivityThread.main(ActivityThread.java:4627)
11-15 14:00:53.484: E/AndroidRuntime(308): at
java.lang.reflect.Method.invokeNative(Native Method)
11-15 14:00:53.484: E/AndroidRuntime(308): at
java.lang.reflect.Method.invoke(Method.java:521)
11-15 14:00:53.484: E/AndroidRuntime(308): at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
11-15 14:00:53.484: E/AndroidRuntime(308): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
11-15 14:00:53.484: E/AndroidRuntime(308): at
dalvik.system.NativeStart.main(Native Method)
11-15 14:00:53.544: W/ActivityManager(59): Force finishing activity
org.openqa.selenium.android.app/.MainActivity
11-15 14:00:54.174: W/ActivityManager(59): Activity pause timeout for
HistoryRecord{45082848 org.openqa.selenium.android.app/.MainActivity}
11-15 14:00:54.624: I/ARMAssembler(59): generated
scanline__00000077:03515104_00000000_00000000 [ 33 ipp] (47 ins) at
[0x2ef440:0x2ef4fc] in 5943060 ns
11-15 14:01:04.651: W/ActivityManager(59): Activity destroy timeout for
HistoryRecord{45082848 org.openqa.selenium.android.app/.MainActivity}
11-15 14:01:05.464: D/dalvikvm(308): GC_FOR_MALLOC freed 1197 objects /
1184480 bytes in 97ms
11-15 14:01:11.874: I/Process(308): Sending signal. PID: 308 SIG: 9
11-15 14:01:12.044: I/ActivityManager(59): Process
org.openqa.selenium.android.app (pid 308) has died.
11-15 14:01:12.044: I/WindowManager(59): WIN DEATH: Window{450a5770
org.openqa.selenium.android.app/org.openqa.selenium.android.app.MainActivity
paused=false}
JUnit failure trace:
org.openqa.selenium.WebDriverException: Error communicating with the remote
browser. It may have died.
Build info: version: '2.12.0', revision: '14666', time: '2011-11-10
18:36:18'
System info: os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1',
java.version: '1.6.0_26'
Driver info: driver.version: RemoteWebDriver
at
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:412)
at
org.openqa.selenium.remote.RemoteWebElement.execute(RemoteWebElement.java:231)
at
org.openqa.selenium.remote.RemoteWebElement.sendKeys(RemoteWebElement.java:82)
at com.selenium.test.android.SeleniumTest.testGoogle(SeleniumTest.java:64)
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 junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: org.apache.http.NoHttpResponseException: The target server
failed to respond
at
org.apache.http.impl.conn.DefaultResponseParser.parseHead(DefaultResponseParser.java:101)
at
org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:252)
at
org.apache.http.impl.AbstractHttpClientConnection.receiveResponseHeader(AbstractHttpClientConnection.java:281)
at
org.apache.http.impl.conn.DefaultClientConnection.receiveResponseHeader(DefaultClientConnection.java:247)
at
org.apache.http.impl.conn.AbstractClientConnAdapter.receiveResponseHeader(AbstractClientConnAdapter.java:219)
at
org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:298)
at
org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:125)
at
org.apache.http.impl.client.DefaultRequestDirector.tryExecute(DefaultRequestDirector.java:645)
at
org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:464)
at
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:820)
at
org.openqa.selenium.remote.HttpCommandExecutor.fallBackExecute(HttpCommandExecutor.java:391)
at
org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:370)
at
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:398)
... 22 more
It seems that latest versions of Android WebDriver app use
android.view.MotionEvent.setSource method, which is available since API
Level 12 (Android 3.1.x).
I've checked that for Android OS 4.0 simple google search test passes
successfully.
And here is the answer
http://code.google.com/p/selenium/wiki/AndroidDriver#Supported_Platforms:
The current apk works with Honeycomb SDK 3.1 and onwards including ICS
For Android Froyo (2.2), download the apk 2.6.0.
Comment #4 on issue 2844 by berr...@google.com: The application WebDriver
client (Process org.openqa.selenium.android.app) has stopped unexpectedly
http://code.google.com/p/selenium/issues/detail?id=2844
@prattof you are right spot on :), the new APK does not work on Froyo, for
more info take a look at
http://code.google.com/p/selenium/wiki/AndroidDriver#Supported_Platforms
Is there any solution to prevent unexpected stop of WebDriver client?
Thanks,
Dima Star
reproduced under emulator Android 4.0 (API level 14) with installed
android-server-2.13.0.apk
Please see attached snap shot
Attachments:
Unfortunatelly.png 136 KB
log snippet:
12-16 11:38:35.677: I/Process(790): Sending signal. PID: 790 SIG: 9
12-16 11:38:36.017: I/WindowManager(87): WIN DEATH: Window{416a4060
org.openqa.selenium.android.app/org.openqa.selenium.android.app.MainActivity
paused=false}
12-16 11:38:36.017: I/ActivityManager(87): Process
org.openqa.selenium.android.app (pid 790) has died.
Comment #9 on issue 2844 by dawa...@gmail.com: The application WebDriver
client (Process org.openqa.selenium.android.app) has stopped unexpectedly
http://code.google.com/p/selenium/issues/detail?id=2844
(No comment was entered for this change.)
Comment #10 on issue 2844 by berr...@google.com: The application WebDriver
client (Process org.openqa.selenium.android.app) has stopped unexpectedly
http://code.google.com/p/selenium/issues/detail?id=2844
Please open a different bug with repro steps (code/setup/etc), platform, OS
used, and the *full* android logcat :). It's almost imporssible to know
what's going on with simply a screenshot.
Thanks!
Thank you Berr...
I've created this one at
http://code.google.com/p/selenium/issues/detail?id=3088
I'm looking forward to this fix a lot.
BR,
Dima Star
Perhaps following snippets of code will allow you to determine the reason
of this problem.
Attachments:
AndroidTestHelper.java 3.8 KB
AndroidTestSuite.java 5.5 KB
Could you please update the wiki because the 2.16.apk does not work at all
for android 2.2. Neither for a device nor for the emulator.
Thanks in advance.
Hi Robert
This is true that 2.16 does not work with android 2.2. I also tried this on
my android froyo phone, but then i tried android server 2.6.APK file and it
worked well with froyo and android 2.3 well. So you use 2.6.apk for android
2.2. and 2.3.
Thanks
Not sure how 2.16 ended up in the wiki, I've updated the supported
platforms
http://code.google.com/p/selenium/wiki/AndroidDriver#Supported_Platforms
Not sure how 2.16 ended up in the wiki, I've updated the supported
platforms
http://code.google.com/p/selenium/wiki/AndroidDriver#Supported_Platforms