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
bytecheck: Test failed on s390x arch #13
Comments
Taking a look at this. Out of curiosity, do you know if the tests passed for the last published version? I believe you were involved in packaging before the latest release. I did have some minor code changes, but made larger changes to the tests to eliminate some bad behavior under miri. This might just be me goofing up the code for some tests. |
I use the version 0.6.4 in fedora for the first repo import. That should be the latest, but I don't know if it changes the test result, since fedora Corp s390x support is unreliable. |
Okay, thanks for the help. I'll see if I can pick this one apart a little better and update when I know more. |
Alright, I think this is a pretty simple endianness issue. In order to validate that bytecheck can accept/reject byte buffers properly, the tests validate byte arrays. A while ago, the tests in the tests crate were updated to use different byte arrays for little- and big-endian architectures. The doctests were never updated to have the same. The fix for this should just be providing two byte arrays to validate for each test in that doctest, one for little-endian machines and one for big-endian machines. I will verify that the error is reproduced on a big-endian architecture then proceed to make the doctest fix and publish a new version. Thanks for the report and sorry for the inconvenience! |
I am having a lot of trouble testing this one. The error in question is specific to big-endian machines and while I can easily ensure that the code compiles on big-endian architectures, it is difficult for me to test. I'll be looking into more ways to test this. In the meantime, I have pushed a tentative fix in df6420a and published version 0.6.5 with the change. Please reopen this issue or file a new one if that fix does not work, I would really like to get everything working for you. |
Test work now! Thanks. |
Hi. Test doesn't pass on fedora koji. https://kojipkgs.fedoraproject.org//work/tasks/8977/73358977/build.log
Doc-tests bytecheck
Running
/usr/bin/rustdoc --edition=2018 --crate-type lib --crate-name bytecheck --test /builddir/build/BUILD/bytecheck-0.6.4/src/lib.rs -L dependency=/builddir/build/BUILD/bytecheck-0.6.4/target/release/deps -L dependency=/builddir/build/BUILD/bytecheck-0.6.4/target/release/deps --extern bytecheck=/builddir/build/BUILD/bytecheck-0.6.4/target/release/deps/libbytecheck-6182913b9b122bd5.rlib --extern bytecheck_derive=/builddir/build/BUILD/bytecheck-0.6.4/target/release/deps/libbytecheck_derive-ae0ba2c0d5d67af6.so --extern ptr_meta=/builddir/build/BUILD/bytecheck-0.6.4/target/release/deps/libptr_meta-10321bd094699b9d.rlib -C embed-bitcode=no --cfg 'feature="default"' --cfg 'feature="std"' --error-format human
running 1 test
test src/lib.rs - (line 23) ... FAILED
failures:
---- src/lib.rs - (line 23) stdout ----
Test executable failed (exit code 101).
stderr:
thread 'main' panicked at 'called
Result::unwrap()
on anErr
value: StructCheckError { field_name: "c", inner: CharCheckError { invalid_value: 2013265920 } }', src/lib.rs:33:7note: run with
RUST_BACKTRACE=1
environment variable to display a backtraceThe text was updated successfully, but these errors were encountered: