New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 607771 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Long OOO (go/where-is-mgiuca)
Closed: Apr 2016
Cc:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug-Regression



Sign in to add a comment

depot_tools: git hyper-blame doesn't use less

Project Member Reported by mgiuca@chromium.org, Apr 29 2016

Issue description

It previously would pipe the output through less if the user is on a TTY, to automatically paginate. It seems to have stopped working and just dumps all the output to stdout.
 

Comment 1 by mgiuca@chromium.org, Apr 29 2016

It seems that https://src.chromium.org/viewvc/chrome?revision=299682&view=revision added a new module called setup_color, and changed git_common.less() to use it instead of sys.stdout.isatty(). Which broke git_hyper_blame because it doesn't initialize setup_color.

I'm guessing I just need to initialize setup_color (like several other modules which call setup_color.init()), but this seems non-ideal to have git_common.less() just not work unless setup_color.init() has been called.

Robert, do you have an opinion about this? I'll put up a CL to init setup_color but maybe there is a better way.
Ah, yes, please init setup_color; it works better under the various
scenarios (cmd, cmd > file, cmd | prog, msysbash, msysbash | less, msysbash

git-hyper-blame when I did the change :(.
Project Member

Comment 4 by bugdroid1@chromium.org, Apr 29 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/tools/depot_tools.git/+/63906bac40d3dd4f772b34b2321d908e1fac906f

commit 63906bac40d3dd4f772b34b2321d908e1fac906f
Author: mgiuca@chromium.org <mgiuca@chromium.org>
Date: Fri Apr 29 01:43:32 2016

git-hyper-blame: Fix pagination (uses less if on a TTY).

This was broken in r299682 (adding setup_color). git_hyper_blame now
initializes setup_color.

BUG= 607771 

Review-Url: https://codereview.chromium.org/1930813003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@300316 0039d316-1c4b-4281-b951-d872f2087c98

[modify] https://crrev.com/63906bac40d3dd4f772b34b2321d908e1fac906f/git_hyper_blame.py

Project Member

Comment 5 by bugdroid1@chromium.org, Apr 29 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/tools/build.git/+/3a9bb2a811b2920c94c530508180bfc341dbec3f

commit 3a9bb2a811b2920c94c530508180bfc341dbec3f
Author: recipe-roller@chromium.org <recipe-roller@chromium.org>
Date: Fri Apr 29 01:56:29 2016

Roll recipe dependencies (trivial).

This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug
(or complain)

depot_tools:
  https://crrev.com/63906bac40d3dd4f772b34b2321d908e1fac906f git-hyper-blame: Fix pagination (uses less if on a TTY). (mgiuca@chromium.org)

R=mgiuca@chromium.org
BUG= 607771 

TBR=martiniss@chromium.org,phajdan.jr@chromium.org

Review-Url: https://codereview.chromium.org/1930313002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/build@300317 0039d316-1c4b-4281-b951-d872f2087c98

[modify] https://crrev.com/3a9bb2a811b2920c94c530508180bfc341dbec3f/infra/config/recipes.cfg

Project Member

Comment 6 by bugdroid1@chromium.org, Apr 29 2016

The following revision refers to this bug:
  http://goto.ext.google.com/viewvc/chrome-internal?view=rev&revision=87196

------------------------------------------------------------------
r87196 | recipe-roller@chromium.org | 2016-04-29T02:03:03.507484Z

-----------------------------------------------------------------

Comment 7 by mgiuca@chromium.org, Apr 29 2016

Status: Fixed (was: Started)

Comment 8 Deleted

Sign in to add a comment