-
Notifications
You must be signed in to change notification settings - Fork 8k
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
- gh version: 1.13.1
- OS: macOS 10.15
When showing some outputs with table writer, width of some cell is wrong. For example:
In this example, the start position of 'about 3 hours ago' at issue #19 is wrong. This is because issue labels are colorized with ANSI color sequences like \x1b[38;2;215;58;74mbug\x1b[0m and the logic to calculate display width of text does not consider the sequences.
Steps to reproduce the behavior
- Checkout some repository which has two open issues. And those issues should have different number of labels.
- Run
gh issue list - See output and confirm the start position of column of issue date is wrong
Expected vs actual behavior
- Expected: Width of display text must consider ANSI escape sequences since such sequences are actually not rendered on terminal
- Actual: ANSI escape sequences are included in display text. For example, width of
(\x1b[38;2;162;238;239menhancement\x1b[0m)is calculated as 34.
Logs
U'w') { gh issue list
Showing 2 of 2 open issues in rhysd/actionlint
#19 Feature Request: checking for Untrusted input (enhancement) about 3 hours ago
#18 "is not defined in object type" error with marketplace action (bug, false-positive) about 53 minutes ago
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
