New issue
Advanced search Search tips

Issue 704696 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Mar 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

Can't override hardcoded Chrome --vmodule patterns via /etc/chrome_dev.conf

Project Member Reported by derat@chromium.org, Mar 23 2017

Issue description

Sergey noticed that it's apparently impossible to use /etc/chrome_dev.conf to override a pattern added to Chrome's --vmodule flag using chrome_setup.cc in session_manager. Apparently Chrome's logging code just uses the first matching pattern that it finds. I think that this is VlogInfo::GetVlogLevel() in base/vlog.cc.

I think that a quick fix for this would be to make ChromiumCommandBuilder in libchromeos-ui prepend patterns to the flag's value instead of appending them. I suspect that this is more likely to align with developers' expectations of later patterns taking precedence over earlier ones, too.
 

Comment 1 by derat@chromium.org, Mar 23 2017

As a quick workaround (if you don't mind dropping other --vmodule patterns), I think you can just add "!--vmodule" at the beginning of chrome_dev.conf to clear the patterns that are hardcoded in session_manager.
Project Member

Comment 3 by bugdroid1@chromium.org, Mar 25 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/ff65302b1886220da7782b6c06b7fc11d0a69e39

commit ff65302b1886220da7782b6c06b7fc11d0a69e39
Author: Daniel Erat <derat@chromium.org>
Date: Sat Mar 25 02:38:22 2017

libchromeos-ui: Prepend patterns to --vmodule.

Make ChromiumCommandBuilder::AddVmodulePattern() and the
"vmodule=" directive in /etc/chrome_dev.conf prepend
patterns to the --vmodule flag instead of appending them.

Chrome uses the first matching pattern that it finds, so
without prepending there's no easy way to use
chrome_dev.conf to override a hardcoded pattern that was
previously added via AddVmodulePattern().

BUG= chromium:704696 
TEST=updated tests; also manually checked that i can now use
     /etc/chrome_dev.conf to increase the verbosity of a
     module that's already matched by a pattern added by
     session_manager's chrome_setup.cc file

Change-Id: If6023450c0a6160406de08d17eb596828591a4c9
Reviewed-on: https://chromium-review.googlesource.com/458797
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sergey Poromov <poromov@chromium.org>

[modify] https://crrev.com/ff65302b1886220da7782b6c06b7fc11d0a69e39/libchromeos-ui/chromeos/ui/chromium_command_builder.cc
[modify] https://crrev.com/ff65302b1886220da7782b6c06b7fc11d0a69e39/libchromeos-ui/chromeos/ui/chromium_command_builder.h
[modify] https://crrev.com/ff65302b1886220da7782b6c06b7fc11d0a69e39/libchromeos-ui/chromeos/ui/chromium_command_builder_unittest.cc

Comment 4 by derat@chromium.org, Mar 25 2017

Status: Fixed (was: Started)

Comment 5 by dchan@google.com, May 30 2017

Labels: VerifyIn-60

Comment 6 by dchan@chromium.org, Aug 1 2017

Labels: VerifyIn-61

Comment 7 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Sign in to add a comment