Improve handling utf-8 errors#1503
Merged
bcl merged 4 commits intoweldr:rhel10-branchfrom Feb 6, 2026
Merged
Conversation
This allows it to properly handle unicode output from the process that is being run. I have been able to reproduce the failure by running lorax in a VM with a modified runtime-postinstall that calls a python program that outputs unicode, or with glib2-2.85.3-1.fc43 -- but I am unable to cause it to fail in the test suite. (cherry picked from commit 3a53278) Related: RHEL-121650
This allows unicode to be passed to the logfiles without raising an error. (cherry picked from commit 24d17f8) Related: RHEL-121650
This was never used in lorax, is always set to false, and now with encoding set to UTF8 for these functions it wouldn't be binary anyway. Also sets text=True in the _run_program call to startProgram, previously the old universal_newlines was set from the state of binary_output. (cherry picked from commit 42786c2) Related: RHEL-121650
We have no control over the data stream so if what we receive from the program (anaconda, or whatever) is broken the best we can do is ignore errors and not crash because of a decode error. Resolves: RHEL-121650
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport more patches, and ignore utf-8 decode errors.