Android WebView telemetry should warn about not switching webview providers |
|||||||
Issue descriptionI was trying to run telemetry for Android WebView so built/installed monochrome_public_apk. Everything appeared to work except telemetry wasn't using webview from MonochromePublic.apk I had installed. This was on a Pixel C version 8.1.0. Steps to reproduce: $ ninja -C out/droid monochrome_public_apk $ out/droid/bin/monochrome_public_apk install -v $ ./tools/perf/run_benchmark run -v --browser=android-webview --pageset-repeat=1 --also-run-disabled-tests --story-filter=browse.media.youtube --chromium-output-directory=/chrome/src/out/droid system_health.common_mobile The telemetry benchmark ran and there was a log line that seemed like it was using MonochromePublic.apk. "Installing /chrome/src/out/droid/apks/MonochromePublic.apk on device if needed." However the benchmark wasn't using MonochromePublic.apk. I was able add CHECK(false) in key areas and it didn't crash. Telemetry used some other version of webview without my changes. Trying to switch the webview implementation via adb fails: $ adb shell cmd webviewupdate set-webview-implementation org.chromium.chrome Failed to switch to org.chromium.chrome, the WebView implementation is now provided by com.android.chrome. It was probably user error and I'm not sure what I was doing wrong with monochrome_public_apk. perezju@ pointed me at instructions for replacing SystemWebView.apk and that worked as expected. perezju@ also asked that I file a bug about telemetry warning if not able to switch webview providers.
,
Jun 20 2018
,
Jun 21 2018
From Telemetry's side, one of the errors is that we only update the webview provider for Monochrome.apk, but we don't do it for MonochromePublic.apk: https://cs.chromium.org/chromium/src/third_party/catapult/telemetry/telemetry/internal/backends/chrome/android_browser_finder.py?rcl=a2cee4816d7bfcc19abd3653e455a745cff1e9b4&l=286 This is not a problem on bots (because the provisioning script does this for us), but users trying to test locally are hit by this without warning.
,
Jul 19
Reminder to self: this came up when talking to v8 folks, and we should make sure the correct webview provider selection is done for any monochrome based apk; it doesn't matter if we intend to launch chrome or webview.
,
Nov 23
I think the error here was allowing to use MonochromePublic.apk, since that does not work as a webview provider at all. Also still need to add the check to fail when Telemetry can't set the webview provider.
,
Nov 23
,
Jan 16
(6 days ago)
,
Jan 16
(6 days ago)
|
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by kylec...@chromium.org
, Jun 20 2018