gnu: python-geventhttpclient: Update to 2.3.3.

* gnu/packages/python-web.scm (python-geventhttpclient): Update to 2.3.3.
[source]: Fetch from git repository; remove snippet.
[build-system]: Use pyproject-build-system.
[arguments]: Use #:test-flags; remove all custom phases.
[native-inputs]: Add python-requests, python-setuptools, and python-wheel.
[propagated-inputs]: Remove python-six.

Change-Id: Ide97ffb7d656f58dd6693bd59ff82706bfea6caa
This commit is contained in:
Ricardo Wurmus 2024-12-19 20:14:37 +01:00
parent ddfa62f104
commit 8992cf4cf1
No known key found for this signature in database
GPG key ID: 197A5888235FACAC

View file

@ -5039,42 +5039,41 @@ for the basic TCP/IP protocols.")
(define-public python-geventhttpclient (define-public python-geventhttpclient
(package (package
(name "python-geventhttpclient") (name "python-geventhttpclient")
(version "2.0.9") (version "2.3.3")
(source (origin (source (origin
(method url-fetch) (method git-fetch)
(uri (pypi-uri "geventhttpclient" version)) (uri (git-reference
(url "https://github.com/geventhttpclient/geventhttpclient")
(commit version)
(recursive? #true)))
(file-name (git-file-name name version))
(sha256 (sha256
(base32 (base32
"04qmcc7qpnif70ph61339dcld4g107fkhpa0gdmbs8z98v9kkg4a")) "1ya0i0fbx054mfx5d1k75fcf64xzp7vva8lkwwzan41xbnc56nyj"))))
(modules '((guix build utils))) (build-system pyproject-build-system)
(snippet
'(begin
;; Delete pre-compiled files.
(for-each delete-file (find-files "src/geventhttpclient"
".*\\.pyc"))))))
(build-system python-build-system)
(arguments (arguments
'(#:phases (list
(modify-phases %standard-phases #:test-flags
(add-after 'unpack 'delete-network-tests ;; Disable network tests.
(lambda _ '(list "-k"
(delete-file "src/geventhttpclient/tests/test_client.py"))) (string-append "not test_client_simple"
(add-after 'unpack 'fix-compatibility-issue " and not test_client_ssl"
;; See: https://github.com/gwik/geventhttpclient/issues/137. " and not test_client_with_default_headers"
(lambda _ " and not test_client_without_leading_slash"
(substitute* "src/geventhttpclient/tests/test_ssl.py" " and not test_download"
((".*sock.last_seen_sni = None.*") " and not test_fail_invalid_ca_certificate"
"")))) " and not test_httpbin_multipart"
(replace 'check " and not test_multi_queries_greenlet_safe"
(lambda* (#:key tests? #:allow-other-keys) " and not test_no_form_encode_header"
(when tests? " and not test_no_form_encoded_header"
(invoke "pytest" "src/geventhttpclient/tests" "-v" " and not test_request_with_headers"
;; Append the test modules to sys.path to avoid " and not test_response_context_manager"
;; namespace conflict which breaks SSL tests. " and not test_urllib_request"))))
"--import-mode=append"))))))) (native-inputs (list nss-certs-for-test
(native-inputs (list nss-certs-for-test python-dpkt python-pytest)) python-dpkt python-pytest python-requests
python-setuptools python-wheel))
(propagated-inputs (list python-brotli python-certifi python-gevent (propagated-inputs (list python-brotli python-certifi python-gevent
python-six python-urllib3)) python-urllib3))
(home-page "https://github.com/geventhttpclient/geventhttpclient") (home-page "https://github.com/geventhttpclient/geventhttpclient")
(synopsis "HTTP client library for gevent") (synopsis "HTTP client library for gevent")
(description "@code{python-geventhttpclient} is a high performance, (description "@code{python-geventhttpclient} is a high performance,