Bug 1862007

Summary: dnf history list output has a too long lines
Product: [Fedora] Fedora Reporter: Boyan Anastasov <btanastasov>
Component: dnfAssignee: Nicola Sella <nsella>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: low    
Version: 32CC: dmach, jmracek, jrohel, mblaha, mhatina, packaging-team-maint, pkratoch, rpm-software-management, vmukhame
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-10-26 18:01:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Boyan Anastasov 2020-07-30 06:52:07 UTC
Description of problem:
The output of dnf history list shows too long lines when redirected to file or piped to less:
dnf history list|less
or
dnf history list > file

The output is with long lines, and you need to scroll very much actually to see any output.

Version-Release number of selected component (if applicable):
dnf-4.2.23-1.fc32.noarch

How reproducible:
Run:
dnf history list - the output looks fine

Compare the output with
dnf history list|less
or
dnf history list > output_history.txt

Additional info:
You can workaround the problem with less, but it would be better to be like it was before (It probably changed around F32/color output maybe is the problem?).
dnf history list|less
and press -S, and then Page-Down/Page-Up to see the output

Comment 1 Nicola Sella 2020-10-26 18:01:02 UTC
There is a fix here [1] for a similar issue. The solution should fix redirection to `less` and to file.
I am closing the bug as duplicate. If the solution does not fit feel free to reopen it. 

[1] https://github.com/rpm-software-management/dnf/pull/1636

*** This bug has been marked as a duplicate of bug 1852577 ***