Package Details: python2-lxml 4.9.2-1

Git Clone URL: (read-only, click to copy)
Package Base: python2-lxml
Description: Python2 binding for the libxml2 and libxslt libraries
Upstream URL:
Licenses: custom, BSD
Submitter: patlefort
Maintainer: patlefort
Last Packager: patlefort
Votes: 8
Popularity: 0.037421
First Submitted: 2021-06-22 01:52 (UTC)
Last Updated: 2022-12-13 22:26 (UTC)

Latest Comments

1 2 3 Next › Last »

brianzbr commented on 2022-11-04 14:28 (UTC)

New to Arch so please bear with me... whenever I try to build this it gets to this step and then seems to just get stuck there indefinitely. I've let it sit on this for up to an hour:

gcc -fno-strict-aliasing -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -DNDEBUG -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -fPIC -DCYTHON_CLINE_IN_TRACEBACK=0 -Isrc/lxml -Isrc/lxml/includes -I/usr/include/libxml2 -Isrc -I/usr/include/python2.7 -c src/lxml/etree.c -o build/temp.linux-x86_64-2.7/src/lxml/etree.o -w

Here's the full output leading up to that:

Any suggestions?

0b100100 commented on 2022-09-05 20:40 (UTC)

This solves the issue. All tests are in fact successfully completed. Thank you.

patlefort commented on 2022-09-05 12:04 (UTC)

I've removed python2-html5lib from checkdepends as it appears that it's not required.

0b100100 commented on 2022-09-04 21:50 (UTC) (edited on 2022-09-04 22:48 (UTC) by 0b100100)

Hi. Could you please disable the check for now? Some required sub-dependencies like python2-six and python2-packaging got dropped recently.

Edit: Please ignore my request above. I just pushed the dropped python2-six package. A remaining issue is the missing python2-packaging package, which is required by some sub-dependencies for their checks. But this is certainly not your issue. ;)

dreieck commented on 2022-07-10 15:25 (UTC) (edited on 2022-07-10 15:25 (UTC) by dreieck)

Just for information:
I observe that after your recent two changes the installation size got 1.05 MiB smaller.
Anything important missing now because you don't seem to use the Makefile anymore for building?, or just some "junk" not included?


patlefort commented on 2022-07-10 03:47 (UTC)

Ok so it's actually required. Man this package is giving me headaches. His makefile let you presume it's not required.

toddejohnson commented on 2022-07-10 02:40 (UTC)

I think cython2 is needed in makedepends. Errors from makechrootpkg:

==> Starting build()...
Building lxml version 4.9.1.
Traceback (most recent call last):
  File "", line 270, in <module>
  File "", line 164, in setup_extra_options
  File "/build/python2-lxml/src/lxml-lxml-4.9.1/", line 104, in ext_modules
    "is not available (pass --without-cython to ignore this error)." % module)
RuntimeError: ERROR: Trying to build without Cython, but pre-generated 'src/lxml/etree.c' is not available (pass --without-cython to ignore this error).

Works when cython2 is added back.

patlefort commented on 2022-07-09 18:09 (UTC)

python2 build isn't enough, it needs build_ext -i option passed or tests will fail with ImportError: cannot import name etree. I've pushed an updated pkgbuild which should hopefully fix the issue by disabling coverage and cython dependency.

MarsSeed commented on 2022-07-09 15:23 (UTC) (edited on 2022-07-09 15:23 (UTC) by MarsSeed)

Or he can just omit using make altogether, since it is redundant here, and return to the previous way (was used in this PKGBUILD until recently):

python2 build

dreieck commented on 2022-07-09 15:13 (UTC) (edited on 2022-07-10 15:27 (UTC) by dreieck)

I played around with the options to, and I found out that the --coverage option which is passed to the test script in the Makefile ~~causes~~triggers the segmentation fault for me. If I leave it out, I don't get the segmentation fault.

You could use this patch to the Makefile as a workaround to just disable --coverage completely:

--- Makefile    2022-07-01 21:19:44.000000000 +0200
+++ Makefile.nocoverage 2022-07-09 17:06:32.049350771 +0200
@@ -12,2 +12,5 @@
-CYTHON_WITH_COVERAGE?=$(shell $(PYTHON) -c 'import Cython.Coverage; import sys; assert not hasattr(sys, "pypy_version_info")' >/dev/null 2>/dev/null && echo " --coverage" || true)
-CYTHON3_WITH_COVERAGE?=$(shell $(PYTHON3) -c 'import Cython.Coverage; import sys; assert not hasattr(sys, "pypy_version_info")' >/dev/null 2>/dev/null && echo " --coverage" || true)
+## `make test` fails with a segmentation fault when the `--coverage` option is passsed. Disable coverage.
+#CYTHON_WITH_COVERAGE?=$(shell $(PYTHON) -c 'import Cython.Coverage; import sys; assert not hasattr(sys, "pypy_version_info")' >/dev/null 2>/dev/null && echo " --coverage" || true)
+#CYTHON3_WITH_COVERAGE?=$(shell $(PYTHON3) -c 'import Cython.Coverage; import sys; assert not hasattr(sys, "pypy_version_info")' >/dev/null 2>/dev/null && echo " --coverage" || true)