[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
54/299: gnu: python-gevent: Update to 24.11.1.
From: |
guix-commits |
Subject: |
54/299: gnu: python-gevent: Update to 24.11.1. |
Date: |
Mon, 13 Jan 2025 07:30:10 -0500 (EST) |
rekado pushed a commit to branch python-team
in repository guix.
commit 50ffc417fc4b9529d6ed462cc7e258bedadfc527
Author: Ricardo Wurmus <rekado@elephly.net>
AuthorDate: Thu Dec 19 15:19:57 2024 +0100
gnu: python-gevent: Update to 24.11.1.
* gnu/packages/python-xyz.scm (python-gevent): Update to 24.11.1.
[build-system]: Use pyproject-build-system.
[arguments]: Use #:test-flags; enable more tests; rename
'add-greenlet-on-C_INCLUDE_PATH to 'augment-C_INCLUDE_PATH.
[propagated-inputs]: Remove python-greenlet.
[native-inputs]: Add python-cffi, python-coverage, python-greenlet,
python-idna, python-requests, python-setuptools, and python-wheel.
[inputs]: Add libuv.
Change-Id: Idd09ca01caf2977783c5a05eac2817b5630df327
---
gnu/packages/python-xyz.scm | 175 +++++++++++++++++++++-----------------------
1 file changed, 82 insertions(+), 93 deletions(-)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index b17e9b2669..a8c5ec7754 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -21823,13 +21823,13 @@ graphviz.")
(define-public python-gevent
(package
(name "python-gevent")
- (version "22.10.2")
+ (version "24.11.1")
(source (origin
(method url-fetch)
(uri (pypi-uri "gevent" version))
(sha256
(base32
- "0ijwwm2yr7jgz8xs1rbvzj6gp7xw1pagf0i7g99b6dzffshiv80w"))
+ "1jhs1k49nfhv59c0li6bcpvkr6pzmxkdgfm56gns7r792j8l3lcb"))
(modules '((guix build utils)))
(snippet
'(begin
@@ -21855,102 +21855,91 @@ graphviz.")
"_greenlet_primitives.c"
"_abstract_linkable.c")
(find-files "." "\\.html$"))))))))
- (build-system python-build-system)
+ (build-system pyproject-build-system)
(arguments
- `(#:modules ((ice-9 ftw)
- (ice-9 match)
- (srfi srfi-26)
- (guix build utils)
- (guix build python-build-system))
- #:phases (modify-phases %standard-phases
- (add-before 'patch-source-shebangs 'patch-hard-coded-paths
- (lambda _
- (substitute* "src/gevent/subprocess.py"
- (("/bin/sh") (which "sh")))
- (for-each (lambda (file)
- (substitute* file
- (("/bin/sh") (which "sh"))
- (("/bin/true") (which "true"))))
- (find-files "src/greentest" "\\.py$"))))
- (add-before 'build 'do-not-use-bundled-sources
- (lambda _
- (setenv "GEVENTSETUP_EMBED" "0")
-
- ;; Prevent building bundled libev.
- (substitute* "setup.py"
- (("run_make=_BUILDING")
- "run_make=False"))))
- (add-before 'build 'add-greenlet-on-C_INCLUDE_PATH
- (lambda* (#:key inputs #:allow-other-keys)
- (let ((greenlet (string-append
- (assoc-ref inputs "python-greenlet")
- "/include")))
- (match (scandir greenlet
- (lambda (item)
- (string-prefix? "python" item)))
- ((python)
- (setenv "C_INCLUDE_PATH"
- (string-append greenlet "/" python ":"
- (or (getenv "C_INCLUDE_PATH")
- ""))))))))
- (add-before 'check 'pretend-to-be-CI
- (lambda _
- ;; A few tests are skipped due to network constraints or
- ;; get longer timeouts when running in a CI environment.
- ;; Piggy-back on that, as we need the same adjustments.
- (setenv "TRAVIS" "1")
- (setenv "APPVEYOR" "1")))
- (add-before 'check 'adjust-tests
- (lambda _
- (let ((disabled-tests
- '(;; These tests relies on networking which is
- ;; not available in the build container.
- "test__getaddrinfo_import.py"
- "test__server_pywsgi.py"
- ;; XXX: These tests borrow functionality from
the
- ;; Python builtin 'test' module, but it is not
- ;; installed with the Guix Python distribution.
- "test_smtpd.py"
- "test_wsgiref.py"
- "test_urllib2.py"
- "test_thread.py"
- "test_threading.py"
- "test__threading_2.py"
- ;; These tests rely on KeyboardInterrupts which
do not
- ;; work inside the build container for some
reason
- ;; (lack of controlling terminal?).
- "test_subprocess.py"
- "test__issues461_471.py"
- ;; TODO: Patch out the tests that use
getprotobyname, etc
- ;; instead of disabling all the tests from
these files.
- "test__resolver_dnspython.py"
- "test__doctests.py"
- "test__all__.py"
- "test___config.py"
- "test__execmodules.py"
- ;; This test contains 'test_unlink', which
- ;; fails on i686 (see:
- ;;
https://github.com/gevent/gevent/issues/1558).
- "test__core_stat.py")))
- (call-with-output-file "skipped_tests.txt"
- (lambda (port)
- (format port "~a~%"
- (string-join disabled-tests "\n")))))))
- (replace 'check
- (lambda _
- ;; Use the build daemons configured number of workers.
- (setenv "NWORKERS" (number->string (parallel-job-count)))
+ (list
+ #:test-flags
+ '(list
+ ;; These tests relies on networking which is
+ ;; not available in the build container.
+ "test__getaddrinfo_import.py"
+ ;; These tests rely on KeyboardInterrupts which do not
+ ;; work inside the build container for some reason
+ ;; (lack of controlling terminal?).
+ "test__issues461_471.py"
+ ;; TODO: Patch out the tests that use getprotobyname, etc
+ ;; instead of disabling all the tests from these files.
+ "test__resolver_dnspython.py"
+ ;; This test contains 'test_unlink', which
+ ;; fails on i686 (see: https://github.com/gevent/gevent/issues/1558).
+ "test__core_stat.py")
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'patch-source-shebangs 'patch-hard-coded-paths
+ (lambda _
+ (substitute* "src/gevent/subprocess.py"
+ (("/bin/sh") (which "sh")))
+ (for-each (lambda (file)
+ (substitute* file
+ (("/bin/sh") (which "sh"))
+ (("/bin/true") (which "true"))))
+ (find-files "src/greentest" "\\.py$"))))
+ (add-before 'build 'do-not-use-bundled-sources
+ (lambda _
+ (setenv "GEVENTSETUP_EMBED" "0")
- (invoke "python" "-m" "gevent.tests" "-unone" "--config"
- "known_failures.py" "--ignore"
"skipped_tests.txt"))))))
+ ;; Prevent building bundled libev.
+ (substitute* "setup.py"
+ (("run_make=_BUILDING")
+ "run_make=False"))))
+ (add-before 'build 'augment-C_INCLUDE_PATH
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let* ((python (dirname (dirname
+ (search-input-file
+ inputs "bin/python"))))
+ (version (python-version python))
+ (greenlet (string-append
+ #$(this-package-native-input "python-greenlet")
+ "/include/python" version)))
+ (setenv "C_INCLUDE_PATH"
+ (string-append greenlet "/:"
+ (or (getenv "C_INCLUDE_PATH")
+ ""))))))
+ (add-before 'check 'pretend-to-be-CI
+ (lambda _
+ ;; A few tests are skipped due to network constraints or
+ ;; get longer timeouts when running in a CI environment.
+ ;; Piggy-back on that, as we need the same adjustments.
+ (setenv "TRAVIS" "1")
+ (setenv "APPVEYOR" "1")))
+ (add-before 'check 'adjust-tests
+ (lambda* (#:key test-flags #:allow-other-keys)
+ (call-with-output-file "skipped_tests.txt"
+ (lambda (port)
+ (format port "~a~%" (string-join test-flags "\n"))))))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ ;; Use the build daemons configured number of workers.
+ (setenv "NWORKERS" (number->string (parallel-job-count)))
+ (invoke "python" "-m" "gevent.tests" "-unone" "--config"
+ "known_failures.py" "--ignore"
"skipped_tests.txt")))))))
(propagated-inputs
- (list python-greenlet python-zope-event python-zope-interface))
+ (list python-zope-event python-zope-interface))
(native-inputs
- (list python-cython
- ;; For tests.
- python-dnspython python-psutil python-objgraph))
+ (list python-cffi
+ python-coverage
+ python-cython
+ python-dnspython
+ python-greenlet
+ python-idna
+ python-objgraph
+ python-psutil
+ python-requests
+ python-setuptools
+ python-wheel))
(inputs
- (list c-ares libev))
+ (list c-ares libev libuv))
(home-page "https://www.gevent.org/")
(synopsis "Coroutine-based network library")
(description
- 235/299: gnu: python-xdoctest: Update to 1.2.0., (continued)
- 235/299: gnu: python-xdoctest: Update to 1.2.0., guix-commits, 2025/01/13
- 280/299: gnu: python-mulpyplexer: Add missing inputs., guix-commits, 2025/01/13
- 191/299: gnu: python-liana-py: Update to 1.4.0., guix-commits, 2025/01/13
- 171/299: gnu: python-anndata: Update to 0.11.1., guix-commits, 2025/01/13
- 210/299: gnu: python-celltypist: Add missing input., guix-commits, 2025/01/13
- 216/299: gnu: python-mathics-django: Add missing inputs., guix-commits, 2025/01/13
- 228/299: gnu: python-multipart: Update to 0.0.20., guix-commits, 2025/01/13
- 36/299: gnu: python-waitress: Update to 3.0.2., guix-commits, 2025/01/13
- 37/299: gnu: python-uvicorn: Update to 0.34.0., guix-commits, 2025/01/13
- 49/299: gnu: python-gast: Update to 0.6.0., guix-commits, 2025/01/13
- 54/299: gnu: python-gevent: Update to 24.11.1.,
guix-commits <=
- 60/299: gnu: python-pydevd: Disable flaky tests., guix-commits, 2025/01/13
- 64/299: gnu: Add rust-jiter-0.2., guix-commits, 2025/01/13
- 124/299: gnu: python-dnspython-1.16: Add missing inputs., guix-commits, 2025/01/13
- 123/299: gnu: python-jose: Fix build., guix-commits, 2025/01/13
- 139/299: gnu: python-kombu: Add missing inputs., guix-commits, 2025/01/13
- 154/299: gnu: Add python-rich-toolkit., guix-commits, 2025/01/13
- 159/299: gnu: python-path-bootstrap: Update to 17.1.0., guix-commits, 2025/01/13
- 156/299: gnu: Add python-fastapi-cli., guix-commits, 2025/01/13
- 152/299: gnu: python-pydantic-core: Update to 2.27.2., guix-commits, 2025/01/13
- 145/299: gnu: python-imageio-ffmpeg: Update to 0.5.1., guix-commits, 2025/01/13