Repository navigation
Conversation
limadog9
force-pushed
the
fix/pr-non-utf8-filenames-12997
branch
from
October 18, 2026 19:46
14a29e3 to
9a11cbb
Compare
sylvestre
reviewed
Oct 18, 2026
| .find_position(|x| x.to_str().is_some_and(|x| e_regex.is_match(x.trim()))); | ||
| if let Some((pos, value)) = expand_tabs_option { | ||
| arguments[pos] = format!("{}\t8", value.trim()); | ||
| arguments[pos] = format!("{}\t8", value.to_str().unwrap().trim()).into(); |
Contributor
There was a problem hiding this comment.
could we avoid this unwrap? e.g. keep the &str from find_position
sylvestre
reviewed
Oct 18, 2026
| |s| s.as_str(), | ||
| ) | ||
| .to_string(); | ||
| paths[0].to_string_lossy().into_owned() |
Contributor
There was a problem hiding this comment.
the header will show U+FFFD here, GNU prints the raw bytes
all the new tests use -t, so could you please add one without it?
sylvestre
reviewed
Oct 18, 2026
| .arg(name) | ||
| .arg("right") | ||
| .succeeds() | ||
| .stdout_contains("left") |
Contributor
There was a problem hiding this comment.
stdout_contains is weak here, could you please check the merged line?
Contributor
|
please also check the header of a non-UTF-8 file, see the inline comments. thanks |
limadog9
force-pushed
the
fix/pr-non-utf8-filenames-12997
branch
3 times, most recently
from
October 19, 2026 11:36
2d736aa to
056a65c
Compare
|
GNU testsuite comparison: |
sylvestre
reviewed
Oct 24, 2026
| } | ||
|
|
||
| #[test] | ||
| #[cfg(target_os = "linux")] |
Contributor
There was a problem hiding this comment.
why only linux here when the header test runs on every unix except apple? could the gates match?
limadog9
force-pushed
the
fix/pr-non-utf8-filenames-12997
branch
from
October 24, 2026 12:04
056a65c to
a108039
Compare
Keep filename bytes through argument preprocessing, metadata lookup, and input reads. Non-UTF-8 operands are no longer silently discarded in favor of standard input. Add regression tests for existing and missing filenames and merged input. All 87 pr integration tests pass. Closes uutils#12997.
sylvestre
force-pushed
the
fix/pr-non-utf8-filenames-12997
branch
from
October 25, 2026 09:41
a108039 to
09e05a5
Compare
This branch has not been deployed
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.
Keep filename bytes through argument preprocessing, metadata lookup, and input reads. Non-UTF-8 operands are no longer silently discarded in favor of standard input.
Add regression tests for existing and missing filenames and merged input. All 87 pr integration tests pass.
Closes #12997.