Re: Bug report: 'filtering content' delayed progress message does not respect --quiet

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Mar 21, 2021 at 03:53:07PM -0500, Sean Allred wrote:

> What did you do before the bug happened? (Steps to reproduce your issue)
> 
>   Called `git clone --quiet git://path/to/private/repo`
> 
> What did you expect to happen? (Expected behavior)
> 
>   Expected git to be quiet :-)  Did not expect writes to stderr/stdout.
> 
> What happened instead? (Actual behavior)
> 
>   Received output that looked like
> 
>       Filtering content:  --% (--/--), --.-- MiB | --.-- MiB/s

+cc Lars, who added this in 52f1d62eb4 (convert: display progress for
filtered objects that have been delayed, 2017-08-20).

The message is in finish_delayed_checkout(), which gets only a "struct
checkout" to carry the state. That has a "quiet" field, but I'm not sure
it is set appropriately. E.g., builtin/checkout.c's checkout_worktree()
does not set it at all, and it is unconditionally set in unpack-trees.c's
check_updates().

We should obviously be respecting --quiet, but also checking isatty(2)
before auto-enabling. Probably we need a separate show_progress field.
For unpack-trees, I think it would get set from o->verbose_update, which
is what controls the existing "Updating files" meter. For checkout.c, it
probably comes from checkout_opts.show_progress.

-Peff



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux