Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
On 11/10/2017 01:04 PM, James Cowgill wrote: > I had a small look :) > > This patch works on s390x. One of the variables passed to > PyArg_ParseTupleAndKeywords was declared with the wrong time. > Unfortunately there's no type checking here. > > James Thanks James, I tried to build it on s390x and it worked indeed with your patch. So I've uploaded the modified package. Let's see how it builds on the buildd network now! :) Thanks once more, Cheers, Thomas Goirand (zigo)
Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
Hi, On 09/11/17 09:42, Thomas Goirand wrote: > On 11/08/2017 10:52 AM, James Cowgill wrote: >> Hi, >> >> On 07/11/17 22:29, Thomas Goirand wrote: >>> Hi James, >>> >>> I tried to build on zelenka.debian.org, which is a s390 porter box (big >>> endian), and it failed even more. >> >> I only tested on mips (where my patch works). Maybe the other failures >> are specific to 64-bit big endian? Eg: s390x, ppc64 and sparc64 all >> failed the same way which is different from the way mips and powerpc fail. >> >> Thanks, >> James > > Hi, > > I tried again, and with or without your patch, there's always 12 unit > test failures on s390x, so I guess you must be right. > > Any chance you could attempt to help again? I had a small look :) This patch works on s390x. One of the variables passed to PyArg_ParseTupleAndKeywords was declared with the wrong time. Unfortunately there's no type checking here. James --- python-lz4-0.10.1+dfsg1.orig/lz4/frame/_frame.c +++ python-lz4-0.10.1+dfsg1/lz4/frame/_frame.c @@ -400,7 +400,7 @@ compress_update (PyObject * Py_UNUSED (s { PyObject *py_context = NULL; const char *source = NULL; - unsigned long source_size = 0; + int source_size = 0; struct compression_context *context; size_t compressed_bound; char *destination_buffer; @@ -630,7 +630,7 @@ get_frame_info (PyObject * Py_UNUSED (se return NULL; } - return Py_BuildValue ("{s:i,s:i,s:i,s:i,s:i}", + return Py_BuildValue ("{s:i,s:i,s:i,s:i,s:K}", "blockSizeID", frame_info.blockSizeID, "blockMode", frame_info.blockMode, "contentChecksumFlag", frame_info.contentChecksumFlag, signature.asc Description: OpenPGP digital signature
Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
On 11/08/2017 10:52 AM, James Cowgill wrote: > Hi, > > On 07/11/17 22:29, Thomas Goirand wrote: >> Hi James, >> >> I tried to build on zelenka.debian.org, which is a s390 porter box (big >> endian), and it failed even more. > > I only tested on mips (where my patch works). Maybe the other failures > are specific to 64-bit big endian? Eg: s390x, ppc64 and sparc64 all > failed the same way which is different from the way mips and powerpc fail. > > Thanks, > James Hi, I tried again, and with or without your patch, there's always 12 unit test failures on s390x, so I guess you must be right. Any chance you could attempt to help again? Cheers, Thomas Goirand (zigo)
Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
Hi, On 07/11/17 22:29, Thomas Goirand wrote: > Hi James, > > I tried to build on zelenka.debian.org, which is a s390 porter box (big > endian), and it failed even more. I only tested on mips (where my patch works). Maybe the other failures are specific to 64-bit big endian? Eg: s390x, ppc64 and sparc64 all failed the same way which is different from the way mips and powerpc fail. Thanks, James signature.asc Description: OpenPGP digital signature
Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
Hi James, I tried to build on zelenka.debian.org, which is a s390 porter box (big endian), and it failed even more. Cheers, Thomas Goirand (zigo)
Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
Control: tags -1 patch Hi, On 07/11/17 14:39, Adrian Bunk wrote: > Source: python-lz4 > Version: 0.10.1+dfsg1-0.1 > Severity: serious > > https://buildd.debian.org/status/package.php?p=python-lz4=sid > > ... >dh_auto_test -a -O--parallel -O--buildsystem=pybuild > I: pybuild base:184: cd > /<>/python-lz4-0.10.1+dfsg1/.pybuild/pythonX.Y_2.7/build; python2.7 > -m nose tests > ..F. > == > FAIL: test_get_frame_info (test_frame.TestLZ4Frame) > -- > Traceback (most recent call last): > File > "/<>/python-lz4-0.10.1+dfsg1/.pybuild/pythonX.Y_2.7/build/tests/test_frame.py", > line 200, in test_get_frame_info > "contentSize":len(input_data) > AssertionError: {'blockMode': 1, 'blockSizeID': 4, 'contentSize': 0, > 'frameType': 0, 'contentChe [truncated]... != {'blockMode': 1, 'blockSizeID': > 4, 'contentSize': 112, 'frameType': 0, 'contentC [truncated]... > {'blockMode': 1, >'blockSizeID': 4, >'contentChecksumFlag': 0, > - 'contentSize': 0, > ? ^ > > + 'contentSize': 112, > ? ^^^ > >'frameType': 0} The attached patch should fix this. contentSize is an "unsigned long long", but was passing the "int" format to Py_BuildValue so it chopped off the lower/upper (depending on endianness) part of the number. James --- a/lz4/frame/_frame.c +++ b/lz4/frame/_frame.c @@ -630,7 +630,7 @@ get_frame_info (PyObject * Py_UNUSED (se return NULL; } - return Py_BuildValue ("{s:i,s:i,s:i,s:i,s:i}", + return Py_BuildValue ("{s:i,s:i,s:i,s:i,s:K}", "blockSizeID", frame_info.blockSizeID, "blockMode", frame_info.blockMode, "contentChecksumFlag", frame_info.contentChecksumFlag, signature.asc Description: OpenPGP digital signature
Processed: Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
Processing control commands: > tags -1 patch Bug #881061 [src:python-lz4] python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame) Added tag(s) patch. -- 881061: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=881061 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
Bug#881061: python-lz4 FTBFS on big endian: FAIL: test_get_frame_info (test_frame.TestLZ4Frame)
Source: python-lz4 Version: 0.10.1+dfsg1-0.1 Severity: serious https://buildd.debian.org/status/package.php?p=python-lz4=sid ... dh_auto_test -a -O--parallel -O--buildsystem=pybuild I: pybuild base:184: cd /<>/python-lz4-0.10.1+dfsg1/.pybuild/pythonX.Y_2.7/build; python2.7 -m nose tests ..F. == FAIL: test_get_frame_info (test_frame.TestLZ4Frame) -- Traceback (most recent call last): File "/<>/python-lz4-0.10.1+dfsg1/.pybuild/pythonX.Y_2.7/build/tests/test_frame.py", line 200, in test_get_frame_info "contentSize":len(input_data) AssertionError: {'blockMode': 1, 'blockSizeID': 4, 'contentSize': 0, 'frameType': 0, 'contentChe [truncated]... != {'blockMode': 1, 'blockSizeID': 4, 'contentSize': 112, 'frameType': 0, 'contentC [truncated]... {'blockMode': 1, 'blockSizeID': 4, 'contentChecksumFlag': 0, - 'contentSize': 0, ? ^ + 'contentSize': 112, ? ^^^ 'frameType': 0} -- Ran 52 tests in 26.027s FAILED (failures=1) E: pybuild pybuild:283: test: plugin distutils failed with: exit code=1: cd /<>/python-lz4-0.10.1+dfsg1/.pybuild/pythonX.Y_2.7/build; python2.7 -m nose tests dh_auto_test: pybuild --test --test-nose -i python{version} -p 2.7 returned exit code 13 debian/rules:10: recipe for target 'build-arch' failed make: *** [build-arch] Error 25