Skip to content

forbid scientific notation in numfmt #11655#11721

Merged
cakebaker merged 8 commits into
uutils:mainfrom
Devel08:fix-numfmt-#11655
Apr 10, 2026
Merged

forbid scientific notation in numfmt #11655#11721
cakebaker merged 8 commits into
uutils:mainfrom
Devel08:fix-numfmt-#11655

Conversation

@Devel08

@Devel08 Devel08 commented Apr 9, 2026

Copy link
Copy Markdown
Contributor

This PR forbids scientific notation in input of numfmt and should resolve #11655. Sorry for opening and closing so much PR's, but I am new in using git with github. That'll be the last one, I swear!
Passes all checks with cargo test .
Thanks!

@github-actions

github-actions Bot commented Apr 9, 2026

Copy link
Copy Markdown

GNU testsuite comparison:

GNU test failed: tests/misc/io-errors. tests/misc/io-errors is passing on 'main'. Maybe you have to rebase?
Skip an intermittent issue tests/date/date-locale-hour (fails in this run but passes in the 'main' branch)
Congrats! The gnu test tests/cut/cut-huge-range is now passing!

@cakebaker

Copy link
Copy Markdown
Contributor

Can you please enable the corresponding test in tests/by_util/test_numfmt.rs and run cargo fmt? Thanks.

@Devel08

Devel08 commented Apr 9, 2026

Copy link
Copy Markdown
Contributor Author

@cakebaker Done, I even edited my solution a bit, I enabled the test, but I think errormsg's name may not sound good, however, I'll wait for your review!

@github-actions

github-actions Bot commented Apr 9, 2026

Copy link
Copy Markdown

GNU testsuite comparison:

Skip an intermittent issue tests/date/date-locale-hour (fails in this run but passes in the 'main' branch)
Skip an intermittent issue tests/rm/isatty (fails in this run but passes in the 'main' branch)
Skipping an intermittent issue tests/pr/bounded-memory (passes in this run but fails in the 'main' branch)
Skipping an intermittent issue tests/tty/tty-eof (passes in this run but fails in the 'main' branch)
Note: The gnu test tests/cut/bounded-memory is now being skipped but was previously passing.
Note: The gnu test tests/tail/tail-n0f is now being skipped but was previously passing.
Congrats! The gnu test tests/cut/cut-huge-range is now passing!

@codspeed-hq

codspeed-hq Bot commented Apr 10, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 309 untouched benchmarks
⏩ 46 skipped benchmarks1


Comparing Devel08:fix-numfmt-#11655 (28f75e2) with main (ceacc67)

Open in CodSpeed

Footnotes

  1. 46 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@github-actions

Copy link
Copy Markdown

GNU testsuite comparison:

GNU test failed: tests/tail/retry. tests/tail/retry is passing on 'main'. Maybe you have to rebase?
Skip an intermittent issue tests/tty/tty-eof (fails in this run but passes in the 'main' branch)
Skipping an intermittent issue tests/pr/bounded-memory (passes in this run but fails in the 'main' branch)

Comment thread src/uu/numfmt/src/numfmt.rs Outdated
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
Comment thread src/uu/numfmt/src/numfmt.rs Outdated
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
@github-actions

Copy link
Copy Markdown

GNU testsuite comparison:

Skip an intermittent issue tests/tail/symlink (fails in this run but passes in the 'main' branch)
Skipping an intermittent issue tests/tail/tail-n0f (passes in this run but fails in the 'main' branch)
Note: The gnu test tests/expand/bounded-memory is now being skipped but was previously passing.
Congrats! The gnu test tests/cut/bounded-memory is now passing!
Skip an intermittent issue tests/pr/bounded-memory (was skipped on 'main', now failing)

@cakebaker cakebaker merged commit b352f83 into uutils:main Apr 10, 2026
167 of 169 checks passed
@cakebaker

Copy link
Copy Markdown
Contributor

Thanks for your PR!

@Devel08 Devel08 deleted the fix-numfmt-#11655 branch April 10, 2026 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

numfmt: accepts scientific notation (e.g. 1e9) where GNU rejects as invalid suffix

2 participants