New issue
Advanced search Search tips

Issue 905910 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: Nov 16
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

Locale error message in logcat during CTS

Project Member Reported by ntfschr@chromium.org, Nov 16

Issue description

Was looking at some CTS runs and I saw this logcat:

11-15 17:10:22.121  6942  6942 E chromium: [ERROR:rtl.cc(147)] Failed to set the ICU default locale to . Falling back to en-US.

Is this a bug in WebView?

Example run: https://luci-milo.appspot.com/p/chromium/builders/luci.chromium.ci/Android%20WebView%20N%20%28dbg%29/20788
... and the corresopnding logcat: https://logs.chromium.org/v/?s=chromium%2Fbuildbucket%2Fcr-buildbucket.appspot.com%2F8929767321918952960%2F%2B%2Flogcat_logcat_android.webkit.cts.CookieManagerTest.testAcceptCookie_20181115T190140-UTC_01e0d05fa22db28f

^ note the example run doesn't fail, so perhaps there's no serious bug to worry about? It would still be nice to make sure we're not violating rtl.cc's expectations by passing bad input.

CC'ing some team members--do you know if our CTS bots are in some weird locale?
 
Cc: ctzsm@chromium.org
I think this won't affect most of our CTS tests. It might cause problem for editing/selection though. As the log message indicated, it falls back to en-US, so unless the default language is rtl language, we won't see much behavior difference.

The logcat message shows |locale_string| is an empty string, which might be not correct, so yeah we need to figure out how to repro this locally by figuring out what's the settings of our CTS bots.
Owner: boliu@chromium.org
Status: Assigned (was: Untriaged)
I see the same error log on my physical devices, so I don't think this is a config issue. One is en-US (English) and one is es-US (Spanish). This repros when I just launch WebView shell to an arbitrary web site, so this also isn't CTS specific.

I narrowed the regression range to https://chromium.googlesource.com/chromium/src/+log/72.0.3585.0..72.0.3586.0, and the CL that stands out is https://chromium.googlesource.com/chromium/src/+/13d3a82271aff7c6476afab4d4ab8dca7eb02dce. Locally reverting the CL seems to fix the issue--hence, passing this to boliu@.

We enter PreSandboxStartup() twice. The first time (browser process?) the switch value is empty, the second time (renderer?) the switch value has the correct locale. The first time triggers the error message, and I would guess the second time is what we needed to fix  issue 895871 .
Thanks for the investigation, Nate!

Bo, do you know why we enter PreSandboxStartup() twice?
Nate is right. That class is shared init code for all processes.
Project Member

Comment 5 by bugdroid1@chromium.org, Nov 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fa21144c2e723d67148f24c15bb8802642ee7b63

commit fa21144c2e723d67148f24c15bb8802642ee7b63
Author: Bo Liu <boliu@chromium.org>
Date: Fri Nov 16 21:37:08 2018

aw: Avoid setting empty icu locale

PreSandboxStartup is called in browser process as well where there is no
kLang argument. For browser, the locale is set in
PostEarlyInitialization.

So check for browser process (empty kProcessType) and skip setting icu
locale in PreSandboxStartup.

Bug:  905910 
Change-Id: Ie2dd1f84b81a61479ae87d96f02c36ea40780bb6
Reviewed-on: https://chromium-review.googlesource.com/c/1340562
Reviewed-by: Nate Fischer <ntfschr@chromium.org>
Commit-Queue: Bo <boliu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#608960}
[modify] https://crrev.com/fa21144c2e723d67148f24c15bb8802642ee7b63/android_webview/lib/aw_main_delegate.cc

Status: Verified (was: Assigned)

Sign in to add a comment