New issue
Advanced search Search tips

Issue 762146 link

Starred by 0 users

Issue metadata

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



Sign in to add a comment

Allow newline in CHROMEOS_LKGM

Project Member Reported by achuith@chromium.org, Sep 5 2017

Issue description

If the file ends with a newline, you get:
https://build.chromium.org/p/tryserver.chromium.linux/builders/chromeos_amd64-generic_chromium_compile_only_ng/builds/412821

cros chrome-sdk fails with:
2:44:01: WARNING: Clearing the SDK cache.
12:44:43: ERROR: cros chrome-sdk failed before completing.
12:44:43: ERROR: Trying to print a string with a newline in it.


 
By pure coincidence I just happened to be annoyed by that. :)

I believe the following does the trick:

https://chromium-review.googlesource.com/651612
Owner: acourbot@chromium.org
Status: Started (was: Untriaged)
https://chromium-review.googlesource.com/c/chromiumos/chromite/+/651612
Project Member

Comment 3 by bugdroid1@chromium.org, Sep 6 2017

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

commit f8fd58541d8d4252b65d24ac0d09001aa5568ea0
Author: Alexandre Courbot <acourbot@chromium.org>
Date: Wed Sep 06 10:15:23 2017

CHROME_LKGM: allow trailing newline in file

Many editors automatically add a trailing newline at the end of files.
This makes manually editing CHROME_LKGM hazardous, since cros chrome-sdk
would then fail with the following error:

   ToGNString
       raise GNException("Trying to print a string with a newline in it.")

Strip trailing newline/whitespaces characters in CHROME_LKGM to cover
that case.

BUG= chromium:762146 
TEST=tried cros chrome-sdk with a CHROME_LKGM ending by a newline,
confirmed it worked.

Change-Id: I6f5daeedf1f7f852b38ea963e5d649a8967fab82
Reviewed-on: https://chromium-review.googlesource.com/651612
Commit-Ready: Alexandre Courbot <acourbot@chromium.org>
Tested-by: Alexandre Courbot <acourbot@chromium.org>
Reviewed-by: Achuith Bhandarkar <achuith@chromium.org>
Reviewed-by: Steven Bennetts <stevenjb@chromium.org>

[modify] https://crrev.com/f8fd58541d8d4252b65d24ac0d09001aa5568ea0/cli/cros/cros_chrome_sdk.py

Status: Fixed (was: Started)
Fix is merged, closing.

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

Status: Archived (was: Fixed)

Comment 6 by dchan@chromium.org, Jan 23 2018

Status: Fixed (was: Archived)

Sign in to add a comment