From bd59254b829396d050919065a879357fd0e994c7 Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Fri, 27 Sep 2024 21:17:21 +0100 Subject: gnu: python-scrapy: Update to 2.11.2, fix build. This is a follow up fixture found during review of . * gnu/packages/python-web.scm (python-scrapy): Update to 2.11.2. [source]: Name for source tarball has been changed in PyPI. [arguments]: <#:test-flags>: Enable more tests which are passing now. <#:phases>: Add 'relax-requirements and 'prepare-test-environment phases. [propagated-inputs]: Add python-defusedxml. [native-inputs]: Add nss-certs-for-test. Change-Id: Ia1e1868b75d679044af83812469c2412b2bab716 --- gnu/packages/python-web.scm | 34 ++++++++++++++++++++-------------- 1 file changed, 20 insertions(+), 14 deletions(-) (limited to 'gnu') diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 8b29f1cd93..f32f15b8b9 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -8686,33 +8686,38 @@ (define-public python-parsel (define-public python-scrapy (package (name "python-scrapy") - (version "2.11.1") + (version "2.11.2") (source (origin (method url-fetch) - (uri (pypi-uri "Scrapy" version)) + (uri (pypi-uri "scrapy" version)) (sha256 - (base32 "1giyyzwcybmh0yf3aq44hhmf9m4k40rva418pxljpr93fjf06fkk")))) + (base32 "07a0nfzkz4vr1353456lavvw36l9s2ia7x91l7mzygzwhi9mdgfz")))) (build-system pyproject-build-system) (arguments (list #:test-flags - ;; Tests fail with DNS lookup or need a display. + ;; Tests requiring a display. #~(list "-k" (string-append "not " (string-join - (list "test_SCRAPY_CHECK_set" - "test_check_all_default_contracts" - "test_check_cb_kwargs_contract" - "test_check_returns_items_contract" - "test_check_returns_requests_contract" - "test_check_scrapes_contract" - "test_pformat" + (list "test_pformat" "test_pformat_old_windows" "test_pformat_windows") - " and not "))))) + " and not "))) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.py" + ;; "defusedxml>=0.7.1" + (("0.7.1") "0.6.0")))) + (add-before 'check 'prepare-test-environment + (lambda _ + (setenv "HOME" "/tmp")))))) (propagated-inputs (list python-botocore ; Optional: For S3FeedStorage class. python-cryptography python-cssselect + python-defusedxml python-itemadapter python-itemloaders python-lxml @@ -8728,10 +8733,11 @@ (define-public python-scrapy python-w3lib python-zope-interface)) (native-inputs - (list python-pexpect + (list nss-certs-for-test + python-pexpect + python-pyftpdlib python-pytest python-pytest-xdist - python-pyftpdlib python-sybil python-testfixtures python-uvloop)) -- cgit v1.2.3