New issue
Advanced search Search tips

Issue 607489 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Apr 2016
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

instrumentation test android_webview_test_apk is flaky

Project Member Reported by hong.zh...@intel.com, Apr 28 2016

Issue description

Tryjobs failed for CL https://codereview.chromium.org/1749073002 
The detail is in
https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng/builds/61751

In instrumentation test android_webview_test_apk (with patch)
There are below 5 sub tests fail:
org.chromium.android_webview.test.AwContentsTest#testCreateLoadDestroyManyTimes
org.chromium.android_webview.test.AwContentsClientShouldInterceptRequestTest#testDoesNotCrashOnSlowStream
org.chromium.android_webview.test.AwContentsClientShouldOverrideUrlLoadingTest#testCallDestroyInCallback
org.chromium.android_webview.test.AwContentsTest#testCreateLoadPageDestroy
org.chromium.android_webview.test.AwContentsTest#testUseAwSettingsAfterDestroy

I tried the instrumentation test with the CL in my local, but can't reproduce the failure. I think the CL couldn't have caused it. Full stdout is attached.

Because this is blocking valid CQ jobs, could you please help to fix it?
 
stdio.htm
4.9 MB View Download

Comment 1 by torne@chromium.org, Apr 28 2016

Status: WontFix (was: Unconfirmed)
It looks to me like this *is* caused by your CL - the exact same five tests crash in the retry (which suggests they aren't flaky if the same ones crash repeatedly), and the flakiness dashboard doesn't show any failures for these tests on the main waterfall.

At least some of the crashes have stacks that look very related to the code you are changing (copypasted one below), so I think this is a problem with your code.

signal 11 (SIGSEGV) at 0xfbadbeef (code=1), thread 7509 (d_webview.shell)
pid: 7509, tid: 7509, name: d_webview.shell  >>> org.chromium.android_webview.shell <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr fbadbeef
     r0 bee87098  r1 fffffffe  r2 02c38e17  r3 fbadbeef
     r4 00000000  r5 7b3eb300  r6 79106048  r7 4012c384
     r8 7910604c  r9 bee87168  sl 41d60470  fp bee874f4
     ip 76747eb9  sp bee87138  lr 76747edf  pc 7778c3c8

Stack Trace:
  RELADDR   FUNCTION                                                                                                   FILE:LINE
  01feb3c8  blink::V8PerIsolateData::addEndOfScopeTask(WTF::PassOwnPtr<blink::V8PerIsolateData::EndOfScopeTask>)+68    /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  023310e3  content::RenderThreadImpl::ScheduleIdleHandler(long long)+78                                               /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  003c5bf1  base::MemoryPressureListener::NotifyMemoryPressure(base::MemoryPressureListener::MemoryPressureLevel)+276  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  003c5c79  base::RefCountedString::size() const+8                                                                     /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  00297a75  android_webview::AwContents::~AwContents()+308                                                             /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  00297be9  android_webview::AwContents::GetOpaqueState(_JNIEnv*, base::android::JavaParamRef<_jobject*> const&)+80    /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  00291f3f  Java_org_chromium_android_1webview_AwContents_nativeSetAwGLFunctor+90                                      /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  0001dbcc  dvmPlatformInvoke+112                                                                                      /system/lib/libdvm.so
  0004e123  dvmCallJNIMethod(unsigned int const*, JValue*, Method const*, Thread*)+398                                 /system/lib/libdvm.so
  0004fb0d  dvmResolveNativeMethod(unsigned int const*, JValue*, Method const*, Thread*)+184                           /system/lib/libdvm.so
  00026fe0  <unknown>                                                                                                  /system/lib/libdvm.so
  0002dfa0  dvmMterpStd(Thread*)+76                                                                                    /system/lib/libdvm.so
  0002b638  dvmInterpret(Thread*, Method const*, JValue*)+184                                                          /system/lib/libdvm.so
  00060861  dvmInvokeMethod(Object*, Method const*, ArrayObject*, ArrayObject*, ClassObject*, bool)+392                /system/lib/libdvm.so
  000687c3  <unknown>                                                                                                  /system/lib/libdvm.so
  00026fe0  <unknown>                                                                                                  /system/lib/libdvm.so
  0002dfa0  dvmMterpStd(Thread*)+76                                                                                    /system/lib/libdvm.so
  0002b638  dvmInterpret(Thread*, Method const*, JValue*)+184                                                          /system/lib/libdvm.so
  0006057d  dvmCallMethodV(Thread*, Method const*, Object*, bool, JValue*, std::__va_list)+336                         /system/lib/libdvm.so
  00049d0b  <unknown>                                                                                                  /system/lib/libdvm.so
  0004d2b3  <unknown>                                                                                                  /system/lib/libandroid_runtime.so
  0004dfd7  android::AndroidRuntime::start(char const*, char const*)+354                                               /system/lib/libandroid_runtime.so
  0000105b  <unknown>                                                                                                  /system/bin/app_process
  0000e34b  __libc_init+50                                                                                             /system/lib/libc.so
  00000d7c  <unknown>                                                                                                  /system/bin/app_process

Stack Data:
  ADDR      VALUE     FUNCTION   FILE:LINE
  bee870f8  bee87138             [stack]
  bee870fc  bee8712c             [stack]
  bee87100  00000000             
  bee87104  7b3eb300  <unknown>  [anon:libc_malloc]
  bee87108  79106048             
  bee8710c  41d60470             [heap]
  bee87110  bee874f4             [stack]
  bee87114  76747e49  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87118  77f939d8  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee8711c  bee8712c             [stack]
  bee87120  0000004f             
  bee87124  02c38e17             
  bee87128  77f939d8  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee8712c  00000000             
  bee87130  4012c384             
  bee87134  7778c3c7  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87138  00000002             
  bee8713c  77ad20e5  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87140  77ad20db  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87144  bee87174             [stack]
  bee87148  00000002             
  bee8714c  75b66bf3  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87150  bee87164             [stack]
  bee87154  765c28a7  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87158  02c38e17             
  bee8715c  00000002             
  bee87160  bee87170             [stack]
  bee87164  00000002             
  bee87168  00000002             
  bee8716c  75b481d5  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so
  bee87170  00000000             
  bee87174  7b3e5418  <unknown>  [anon:libc_malloc]
  bee87178  7b628e00  <unknown>  [anon:libc_malloc]
  bee8717c  00000001             
  bee87180  ffffffff             
  bee87184  41d60470             [heap]
  bee87188  bee874f4             [stack]
  bee8718c  75bac907  <unknown>  /data/app-lib/org.chromium.android_webview.shell-1/libstandalonelibwebviewchromium.so

Thanks torne. 
According to your comments, it looks like that the crash is caused by my CL. But I can't reproduce the crash in local, as the expert could you please give me some advice to reproduce it? 
In addition, how can i get the crash stack? I don't find it in stdio.

Comment 3 by torne@chromium.org, Apr 28 2016

I don't know how you would reproduce this locally if just running the same command as the bot doesn't work. Are you using the same OS version? Same test runner command?

stdio isn't particularly useful on android bots as it only includes output from the test runner - what you want to look at also is the logcat dump (which is the entire logcat from the whole test run), available from a step near the end of the build, and the later steps which run the "stack" tool on the logcat dump to symbolise the crashes. It's not always easy to figure out which part of logcat/stack output actually corresponds to which actual test, though. I don't do this very often so don't have particularly good advice here - other people who run tests on android more frequently might have more ideas. Probably email chromium-dev@ if you want to ask general questions about how to debug test failures on android :)
Thanks very much for your reply. It is the first time for me to meet test failure. At the beginning, I didn't know how to debug it. Fortunately I gain your help:-)

I run run_android_webview_test_apk in local for failed sub test, for example
./out/Release/bin/run_android_webview_test_apk -f AwContentsClientShouldOverrideUrlLoadingTest#testCallDestroyInCallback
I don't know if above command is enough to run sub test or not?
In addition, I run the test on an internal Android device. How can I get the try bot device information, such as device/OS version?

Thanks again!

From: torne@chromium.org via Monorail [mailto:monorail@chromium.org]
Sent: Thursday, April 28, 2016 7:48 PM
To: Zheng, Hong <hong.zheng@intel.com>
Subject:  Issue 607489  in chromium: instrumentation test android_webview_test_apk is flaky

Comment 5 by torne@chromium.org, Apr 28 2016

See "device_status_check" step - they are hammerheads running KTU84P on this bot.

Command seems reasonable to me, but I don't run tests that much :)
Got it. Thanks

From: torne@chromium.org via Monorail [mailto:monorail@chromium.org]
Sent: Thursday, April 28, 2016 8:30 PM
To: Zheng, Hong <hong.zheng@intel.com>
Subject:  Issue 607489  in chromium: instrumentation test android_webview_test_apk is flaky

Comment 7 by boliu@chromium.org, Apr 28 2016

Does your local build match the bot exactly? Eg trybots build with dcheck_always_on, ie DCHECKs are enabled even though it's a release bot.

Comment 8 by boliu@chromium.org, Apr 28 2016

This is the assertion failure you are hitting:

7c4ac:  04-28 03:50:19.649  5245  5245 W WebKit  : ASSERTION FAILED: isMainThread()
7c4ac:  04-28 03:50:19.649  5245  5245 W WebKit  : ../../third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp(79) : static v8::Isolate* blink::V8PerIsolateData::mainThreadIsolate()
Thank bo...@chromium.org reminding. I will rebuild android_webview_test_apk to try to reproduce the issue in local. In addition, assertion failure information is very useful, thanks very much.

Sign in to add a comment