-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
checksum: prepare further behavior fix with a rework #6822
Conversation
Depending on the feedback on this discussion, I might split the What do you think ? |
It sounds good to me. |
7898120
to
aa5f0c0
Compare
GNU testsuite comparison:
|
734dd51
to
9854090
Compare
I've finally decided to keep the splitting in several files for later, because it's a nightmare to mix changes and file architecture when you have to rebase to keep a sound change history. |
b33e635
to
0d02461
Compare
GNU testsuite comparison:
|
I'm not sure why the macos test failed. Is it just flakey or have I touched something ? |
flaky:
|
0d02461
to
598537a
Compare
GNU testsuite comparison:
|
@cakebaker Both of your comments address the details of implementation I came to when working on it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall good job with this refactoring :)
598537a
to
155f4ae
Compare
155f4ae
to
191c1a8
Compare
GNU testsuite comparison:
|
191c1a8
to
4599888
Compare
GNU testsuite comparison:
|
Up @cakebaker |
This PR might have been forgotten, just pinging maintainers for final review/merge @cakebaker @sylvestre ^^ |
…, LineCheckError> - Treat digest mismatch as an error
test(cksum): add test for blake length gessing test(cksum): add test for hexa/base64 confusion test(cksum): add test for error handling on incorrectly formatted checksum test(cksum): add test for trailing spaces making a line improperly formatted test(cksum): Re-implement GNU test 'cksum-base64' in the testsuite
4599888
to
0bc22e8
Compare
thanks for the ping :) |
GNU testsuite comparison:
|
Now that #6782, #6793 and #6815 have landed, it is time to achieve the rework of
checksum.rs
started in #6654.This will allow us to fix #6572, #6614 and #6653.
This PR mainly tries to split the massive
perform_checksum_verification
in smaller functions, and to get rid of the&mut ChecksumResult
that is passed everywhere, which makes it very difficult to understand where the global state of the program is modified.Also, it adds ignored tests for future features (it will prevent too many conflicts when rebasing future PRs on each other).
Next PRs will focus on reworking the algorithm detection behavior, in particular for blake2b size guessing,
Regex detection behavior which for now prevents us from encountering both hexa and base64 digits in the same file.