GNU bug report logs - #28102
Bug when using the --color option

Previous Next

Package: grep;

Reported by: Jason P Thurman <jason.thurman <at> gm.com>

Date: Tue, 15 Aug 2017 19:53:02 UTC

Severity: normal

Tags: moreinfo

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 28102 in the body.
You can then email your comments to 28102 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-grep <at> gnu.org:
bug#28102; Package grep. (Tue, 15 Aug 2017 19:53:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jason P Thurman <jason.thurman <at> gm.com>:
New bug report received and forwarded. Copy sent to bug-grep <at> gnu.org. (Tue, 15 Aug 2017 19:53:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Jason P Thurman <jason.thurman <at> gm.com>
To: "bug-grep <at> gnu.org" <bug-grep <at> gnu.org>
Subject: Bug when using the --color option
Date: Tue, 15 Aug 2017 19:27:29 +0000
[Message part 1 (text/plain, inline)]
When using the --color option of grep, if the final character matching your grep pattern is on the final column of the terminal, then the character is not displayed. For example:

[cid:image001.png <at> 01D315DB.011830A0]

If I make the terminal 1 character wider or narrower, the line and the colored pattern are printed correctly.


Jason Thurman
General Motors
28405 Van Dyke Avenue
Warren, MI 48093-7132
Cell: +1 (586) 634-4132
Email: jason.thurman <at> gm.com<mailto:jason.thurman <at> gm.com>



Nothing in this message is intended to constitute an electronic signature unless a specific statement to the contrary is included in this message.

Confidentiality Note: This message is intended only for the person or entity to which it is addressed. It may contain confidential and/or privileged material. Any review, transmission, dissemination or other use, or taking of any action in reliance upon this message by persons or entities other than the intended recipient is prohibited and may be unlawful. If you received this message in error, please contact the sender and delete it from your computer.
[Message part 2 (text/html, inline)]
[image001.png (image/png, inline)]

Information forwarded to bug-grep <at> gnu.org:
bug#28102; Package grep. (Sat, 02 Nov 2019 16:11:02 GMT) Full text and rfc822 format available.

Message #8 received at 28102 <at> debbugs.gnu.org (full text, mbox):

From: josef radinger <cheese <at> nosuchhost.net>
To: 28102 <at> debbugs.gnu.org
Subject: additional examples
Date: Sat, 02 Nov 2019 14:04:38 +0100
[Message part 1 (text/plain, inline)]
3 examples:

*) grepping for X with in a wide enough xterm
*) a problematic xterm: 
**) grepping without color -> correct
**) grepping with color -> missing characters from the result

pasteing the result shows that there "is" no X in the result.

yours
josef

[greperror.png (image/png, attachment)]

Information forwarded to bug-grep <at> gnu.org:
bug#28102; Package grep. (Sat, 02 Nov 2019 16:24:02 GMT) Full text and rfc822 format available.

Message #11 received at 28102 <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: josef radinger <cheese <at> nosuchhost.net>
Cc: Jason P Thurman <jason.thurman <at> gm.com>, 28102 <at> debbugs.gnu.org
Subject: Re: bug#28102: additional examples
Date: Sat, 2 Nov 2019 09:22:46 -0700
On 11/2/19 6:04 AM, josef radinger wrote:
> 3 examples:
> 
> *) grepping for X with in a wide enough xterm
> *) a problematic xterm:
> **) grepping without color -> correct
> **) grepping with color -> missing characters from the result
> 
> pasteing the result shows that there "is" no X in the result.

Surely this is a bug in xterm, not in grep. Try this:

ps auxww | grep --color=always X >foo
cat foo

If you still see the problem, look at foo this way:

od -cx foo

and see what color-change commands 'grep' is issuing.




Added tag(s) moreinfo. Request was from Paul Eggert <eggert <at> cs.ucla.edu> to control <at> debbugs.gnu.org. (Sat, 02 Nov 2019 16:24:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-grep <at> gnu.org:
bug#28102; Package grep. (Sun, 03 Nov 2019 21:51:01 GMT) Full text and rfc822 format available.

Message #16 received at 28102 <at> debbugs.gnu.org (full text, mbox):

From: josef radinger <cheese <at> nosuchhost.net>
To: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: Jason P Thurman <jason.thurman <at> gm.com>, 28102 <at> debbugs.gnu.org
Subject: Re: bug#28102: additional examples
Date: Sun, 03 Nov 2019 20:39:33 +0100
thanks
checked with 2 other terminals (xfce terminal and terminator). both
work OK.

joe

On Sat, 2019-11-02 at 09:22 -0700, Paul Eggert wrote:
> On 11/2/19 6:04 AM, josef radinger wrote:
> > 3 examples:
> > 
> > *) grepping for X with in a wide enough xterm
> > *) a problematic xterm:
> > **) grepping without color -> correct
> > **) grepping with color -> missing characters from the result
> > 
> > pasteing the result shows that there "is" no X in the result.
> 
> Surely this is a bug in xterm, not in grep. Try this:
> 
> ps auxww | grep --color=always X >foo
> cat foo
> 
> If you still see the problem, look at foo this way:
> 
> od -cx foo
> 
> and see what color-change commands 'grep' is issuing.
> 





Reply sent to Paul Eggert <eggert <at> cs.ucla.edu>:
You have taken responsibility. (Mon, 04 Nov 2019 00:59:02 GMT) Full text and rfc822 format available.

Notification sent to Jason P Thurman <jason.thurman <at> gm.com>:
bug acknowledged by developer. (Mon, 04 Nov 2019 00:59:02 GMT) Full text and rfc822 format available.

Message #21 received at 28102-done <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: josef radinger <cheese <at> nosuchhost.net>
Cc: Jason P Thurman <jason.thurman <at> gm.com>, 28102-done <at> debbugs.gnu.org
Subject: Re: bug#28102: additional examples
Date: Sun, 3 Nov 2019 16:58:24 -0800
On 11/3/19 11:39 AM, josef radinger wrote:
> checked with 2 other terminals (xfce terminal and terminator). both
> work OK.

Thanks for checking. Closing the bug report.




Information forwarded to bug-grep <at> gnu.org:
bug#28102; Package grep. (Tue, 05 Nov 2019 18:18:01 GMT) Full text and rfc822 format available.

Message #24 received at 28102-done <at> debbugs.gnu.org (full text, mbox):

From: Jason P Thurman <jason.thurman <at> gm.com>
To: Paul Eggert <eggert <at> cs.ucla.edu>, josef radinger <cheese <at> nosuchhost.net>
Cc: "28102-done <at> debbugs.gnu.org" <28102-done <at> debbugs.gnu.org>
Subject: RE: [EXTERNAL] Re: bug#28102: additional examples
Date: Tue, 5 Nov 2019 18:17:25 +0000
Thanks for your help in this. My original test was in Putty (as you can see in the screenshot)

I checked two other terminals:
* Gnome terminal - no issues
* Xterm - Same issue as Putty

So, it may not be a bug with grep, but it is more widespread than just 1 terminal. I will see if I can report the issue to Putty or xterm.

Thanks for the help!


-----Original Message-----
From: Paul Eggert <eggert <at> cs.ucla.edu>
Sent: Sunday, November 03, 2019 7:58 PM
To: josef radinger <cheese <at> nosuchhost.net>
Cc: 28102-done <at> debbugs.gnu.org; Jason P Thurman <jason.thurman <at> gm.com>
Subject: [EXTERNAL] Re: bug#28102: additional examples

ATTENTION: This email originated from outside of GM.




On 11/3/19 11:39 AM, josef radinger wrote:
> checked with 2 other terminals (xfce terminal and terminator). both
> work OK.

Thanks for checking. Closing the bug report.


Nothing in this message is intended to constitute an electronic signature unless a specific statement to the contrary is included in this message.

Confidentiality Note: This message is intended only for the person or entity to which it is addressed. It may contain confidential and/or privileged material. Any review, transmission, dissemination or other use, or taking of any action in reliance upon this message by persons or entities other than the intended recipient is prohibited and may be unlawful. If you received this message in error, please contact the sender and delete it from your computer.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 04 Dec 2019 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 145 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.