Fragment checksums break PyECLib
The RS unit tests are breaking when performing the fragment header checks with master. I tried with v1.1.1 and everything works fine. This commit appears to be the culprit:
https://bitbucket.org/tsg-/liberasurecode/commits/a6a8d2018d50068f1177ba9f826518b003dc5917
@tsg- I have a pull request that reverts this for now. We can figure out where the problem is, fix it, then re-merge. The pull request also contains a minor commit for a compiler error I was seeing on the latest version of GCC.
Comments (3)
-
reporter -
repo owner @kmgreen2 thanks - glad to know the liberasurecode header changes don't need to be reverted. Did you already have something that fixes this? If not, I will fix the test and submit a PR.
-
repo owner - changed status to invalid
Being taken care of in https://bitbucket.org/kmgreen2/pyeclib/issues/83/unittests-error-with-test_rs.
- Log in to comment
@tsg- OK, I think this is not a bug in liberasurecode, but a bug in the PyECLib tests.
We now return -EBADHEADER from liberasurecode_decode() when any header is borked.
test_rs() in PyECLib (test_pyeclib_api.py) corrupts entire fragments (including the header). We previously asserted decode throws ECInsufficientFragments, but due to the liberasurecode change is now throwing ECInvalidFragmentMetadata.
This means we should assert ECInvalidFragmentMetadata is thrown and add another test to test insufficient fragments with valid headers.