projects/guix·blob astro-update · refs

15513 lines · 562.1 KiB

1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2015 Eric Dvorsak <[email protected]>
3;;; Copyright © 2015-2025 Efraim Flashner <[email protected]>
4;;; Copyright © 2017 Christopher Baines <[email protected]>
5;;; Copyright © 2017 Muriithi Frederick Muriuki <[email protected]>
6;;; Copyright © 2016, 2017 Danny Milosavljevic <[email protected]>
7;;; Copyright © 2013, 2014, 2015, 2016, 2020, 2023 Andreas Enge <[email protected]>
8;;; Copyright © 2016-2023 Marius Bakke <[email protected]>
9;;; Copyright © 2015-2025 Ricardo Wurmus <[email protected]>
10;;; Copyright © 2017, 2021 Roel Janssen <[email protected]>
11;;; Copyright © 2016, 2017, 2020 Julien Lepiller <[email protected]>
12;;; Copyright © 2016, 2017 Nikita <[email protected]>
13;;; Copyright © 2014, 2017, 2021 Eric Bavier <[email protected]>
14;;; Copyright © 2014, 2015 Mark H Weaver <[email protected]>
15;;; Copyright © 2015 Cyril Roelandt <[email protected]>
16;;; Copyright © 2015, 2016, 2017, 2019 Leo Famulari <[email protected]>
17;;; Copyright © 2016, 2019, 2022, 2025 Hartmut Goebel <[email protected]>
18;;; Copyright © 2016–2021 Tobias Geerinckx-Rice <[email protected]>
19;;; Copyright © 2015, 2017 Ben Woodcroft <[email protected]>
20;;; Copyright © 2015, 2016 Christine Lemmer-Webber <[email protected]>
21;;; Copyright © 2017 Adriano Peluso <[email protected]>
22;;; Copyright © 2016 Dylan Jeffers <sapientech@[email protected]>
23;;; Copyright © 2016 David Craven <[email protected]>
24;;; Copyright © 2017 Oleg Pykhalov <[email protected]>
25;;; Copyright © 2015, 2016 David Thompson <[email protected]>
26;;; Copyright © 2017 Mark Meyer <[email protected]>
27;;; Copyright © 2018 Clément Lassieur <[email protected]>
28;;; Copyright © 2018 Tomáš Čech <[email protected]>
29;;; Copyright © 2018, 2019, 2021, 2024 Nicolas Goaziou <[email protected]>
30;;; Copyright © 2018 Mathieu Othacehe <[email protected]>
31;;; Copyright © 2018, 2020, 2021, 2022, 2023 Maxim Cournoyer <[email protected]>
32;;; Copyright © 2018 swedebugia <[email protected]>
33;;; Copyright © 2019 Vagrant Cascadian <[email protected]>
34;;; Copyright © 2019, 2023 Brendan Tildesley <[email protected]>
35;;; Copyright © 2019 Pierre Langlois <[email protected]>
36;;; Copyright © 2019, 2020 Tanguy Le Carrour <[email protected]>
37;;; Copyright © 2020 Jakub Kądziołka <[email protected]>
38;;; Copyright © 2020 Josh Marshall <[email protected]>
39;;; Copyright © 2020 Evan Straw <[email protected]>
40;;; Copyright © 2020 Alexandros Theodotou <[email protected]>
41;;; Copyright © 2020 Holger Peters <[email protected]>
42;;; Copyright © 2020 Noisytoot <[email protected]>
43;;; Copyright © 2020 Edouard Klein <[email protected]>
44;;; Copyright © 2020, 2021, 2022, 2023, 2025 Vinicius Monego <[email protected]>
45;;; Copyright © 2020 Konrad Hinsen <[email protected]>
46;;; Copyright © 2020, 2022, 2024 Giacomo Leidi <[email protected]>
47;;; Copyright © 2020 Raghav Gururajan <[email protected]>
48;;; Copyright © 2021 Ekaitz Zarraga <[email protected]>
49;;; Copyright © 2021 Greg Hogan <[email protected]>
50;;; Copyright © 2021 Maxime Devos <[email protected]>
51;;; Copyright © 2021 Pradana Aumars <[email protected]>
52;;; Copyright © 2021, 2022, 2024, 2026 Arun Isaac <[email protected]>
53;;; Copyright © 2021-2022, 2024-2025 jgart <[email protected]>
54;;; Copyright © 2021 Alice Brenon <[email protected]>
55;;; Copyright © 2021 Mekeor Melire <[email protected]>
56;;; Copyright © 2022 John Kehayias <[email protected]>
57;;; Copyright © 2022 Denis 'GNUtoo' Carikli <[email protected]>
58;;; Copyright © 2022, 2023, 2025 Felix Gruber <[email protected]>
59;;; Copyright © 2022 Peter Polidoro <[email protected]>
60;;; Copyright © 2022 Antero Mejr <[email protected]>
61;;; Copyright © 2022 Luis Henrique Gomes Higino <[email protected]>
62;;; Copyright © 2022, 2025 Nicolas Graves <[email protected]>
63;;; Copyright © 2022 Tomasz Jeneralczyk <[email protected]>
64;;; Copyright © 2022 msimonin <[email protected]>
65;;; Copyright © 2022 Michael Rohleder <[email protected]>
66;;; Copyright © 2022 Baptiste Strazzulla <[email protected]>
67;;; Copyright © 2023 dan <[email protected]>
68;;; Copyright © 2023 John Kehayias <[email protected]>
69;;; Copyright © 2023 Juliana Sims <[email protected]>
70;;; Copyright © 2023 Ivan Vilata-i-Balaguer <[email protected]>
71;;; Copyright © 2024 Fabio Natali <[email protected]>
72;;; Copyright © 2024 Steve George <[email protected]>
73;;; Copyright © 2024 Troy Figiel <[email protected]>
74;;; Copyright © 2024, 2025 Sharlatan Hellseher <[email protected]>
75;;; Copyright © 2024 normally_js <[email protected]>
76;;; Copyright © 2024 Markku Korkeala <[email protected]>
77;;; Copyright © 2024 Nguyễn Gia Phong <[email protected]>
78;;; Copyright © 2024 Zheng Junjie <[email protected]>
79;;; Copyright © 2024 Spencer King <[email protected]>
80;;; Copyright © 2024 Attila Lendvai <[email protected]>
81;;; Copyright © 2025 Daniel Ziltener <[email protected]>
82;;; Copyright © 2025 gemmaro <[email protected]>
83;;; Copyright © 2025 Sergio Pastor Pérez <[email protected]>
84;;; Copyright © 2025 Jake Forster <[email protected]>
85;;; Copyright © 2025 Janneke Nieuwenhuizen <[email protected]>
86;;; Copyright © 2025 Hugo Buddelmeijer <[email protected]>
87;;; Copyright © 2025-2026 Artur Wroblewski <[email protected]>
88;;; Copyright © 2025, 2026 Allan Adair <[email protected]>
89;;; Copyright © 2025 Aaron Covrig <[email protected]>
90;;; Copyright © 2026 Daniel Khodabakhsh <[email protected]>
91;;; Copyright © 2026 mst <[email protected]>
92;;; Copyright © 2026 Goran Vukoman <[email protected]>
93;;;
94;;; This file is part of GNU Guix.
95;;;
96;;; GNU Guix is free software; you can redistribute it and/or modify it
97;;; under the terms of the GNU General Public License as published by
98;;; the Free Software Foundation; either version 3 of the License, or (at
99;;; your option) any later version.
100;;;
101;;; GNU Guix is distributed in the hope that it will be useful, but
102;;; WITHOUT ANY WARRANTY; without even the implied warranty of
103;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
104;;; GNU General Public License for more details.
105;;;
106;;; You should have received a copy of the GNU General Public License
107;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
108
109(define-module (gnu packages python-web)
110 #:use-module (gnu packages admin)
111 #:use-module (gnu packages base)
112 #:use-module (gnu packages bash)
113 #:use-module (gnu packages build-tools)
114 #:use-module (gnu packages check)
115 #:use-module (gnu packages cmake)
116 #:use-module (gnu packages compression)
117 #:use-module (gnu packages curl)
118 #:use-module (gnu packages databases)
119 #:use-module (gnu packages django)
120 #:use-module (gnu packages dns)
121 #:use-module (gnu packages freedesktop)
122 #:use-module (gnu packages glib)
123 #:use-module (gnu packages gnupg)
124 #:use-module (gnu packages graphviz)
125 #:use-module (gnu packages groff)
126 #:use-module (gnu packages iso-codes)
127 #:use-module (gnu packages libevent)
128 #:use-module (gnu packages libffi)
129 #:use-module (gnu packages libidn)
130 #:use-module (gnu packages linux)
131 #:use-module (gnu packages lsof)
132 #:use-module (gnu packages machine-learning)
133 #:use-module (gnu packages node)
134 #:use-module (gnu packages nss)
135 #:use-module (gnu packages openstack)
136 #:use-module (gnu packages pcre)
137 #:use-module (gnu packages pkg-config)
138 #:use-module (gnu packages protobuf)
139 #:use-module (gnu packages python)
140 #:use-module (gnu packages python-build)
141 #:use-module (gnu packages python-check)
142 #:use-module (gnu packages python-compression)
143 #:use-module (gnu packages python-crypto)
144 #:use-module (gnu packages python-science)
145 #:use-module (gnu packages python-xyz)
146 #:use-module (gnu packages qt)
147 #:use-module (gnu packages rdf)
148 #:use-module (gnu packages rpc)
149 #:use-module (gnu packages rust)
150 #:use-module (gnu packages serialization)
151 #:use-module (gnu packages sphinx)
152 #:use-module (gnu packages texinfo)
153 #:use-module (gnu packages time)
154 #:use-module (gnu packages tls)
155 #:use-module (gnu packages version-control)
156 #:use-module (gnu packages web)
157 #:use-module (gnu packages xml)
158 #:use-module (gnu packages)
159 #:use-module (guix build-system cargo)
160 #:use-module (guix build-system copy)
161 #:use-module (guix build-system pyproject)
162 #:use-module (guix deprecation)
163 #:use-module (guix download)
164 #:use-module (guix gexp)
165 #:use-module (guix git-download)
166 #:use-module ((guix licenses) #:prefix license:)
167 #:use-module (guix packages)
168 #:use-module (guix utils)
169 #:use-module (srfi srfi-1))
170
171(define-public awscli
172 (package
173 ;; Note: updating awscli typically requires updating botocore as well.
174 (name "awscli")
175 (version "1.43.11")
176 (source
177 (origin
178 (method git-fetch)
179 (uri (git-reference
180 (url "https://github.com/aws/aws-cli")
181 (commit version)))
182 (file-name (git-file-name name version))
183 (sha256
184 (base32 "1idvcnc6jw7xr1jqpza472ksj3i2kyk0bv8wr7acz3xnba1v8xmi"))))
185 (build-system pyproject-build-system)
186 (arguments
187 (list
188 ;; tests: 2715 passed, 32 warnings
189 #:test-flags
190 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
191 ;; Complete test suite is huge and compute hungry, run just unit
192 ;; tests.
193 "--ignore=tests/dependencies"
194 "--ignore=tests/functional"
195 "--ignore=tests/integration"
196 ;; TypeError: 'Mock' object is not subscriptable.
197 "-k" "not test_no_groff_or_mandoc_exists")
198 #:phases
199 #~(modify-phases %standard-phases
200 (add-after 'unpack 'fix-reference-to-groff
201 (lambda _
202 ;; XXX: Consider to use wrap-program instead, it tries to parse
203 ;; the PATH.
204 (substitute* "awscli/help.py"
205 (("if self._exists_on_path\\('groff'\\):") "if 'groff':")
206 (("raise ExecutableNotFoundError\\('groff'\\)") "")
207 (("cmdline = \\['groff'")
208 (format #f "cmdline = ['~a/bin/groff'"
209 #$(this-package-input "groff-minimal"))))))
210 (add-before 'check 'set-environment
211 (lambda _
212 ;; PermissionError: [Errno 13] Permission denied:
213 ;; '/homeless-shelter'
214 (setenv "HOME" "/tmp"))))))
215 (native-inputs
216 (list python-pytest
217 python-pytest-xdist
218 python-setuptools
219 python-wheel))
220 (inputs
221 (list groff-minimal
222 python-botocore
223 python-colorama
224 python-docutils-0.19
225 python-pyyaml
226 python-rsa-for-awscli-1
227 python-s3transfer))
228 (home-page "https://aws.amazon.com/cli/")
229 (synopsis "Command line client for AWS")
230 (description
231 "AWS CLI provides a unified command line interface to the Amazon Web
232Services (AWS) API.")
233 (license license:asl2.0)))
234
235(define-public awscli-2
236 (package
237 (inherit awscli)
238 ;; Note: updating awscli-2 typically requires updating python-awscrt.
239 (name "awscli")
240 ;; Upstream practices a very rapid (1h-1d) release cycles try to select
241 ;; any fresh one compatible with current state of dependencies in Guix.
242 (version "2.36.20")
243 (source
244 (origin
245 (method git-fetch)
246 (uri (git-reference
247 (url "https://github.com/aws/aws-cli")
248 (commit version)))
249 (file-name (git-file-name name version))
250 (sha256
251 (base32
252 "1hv2zs5pm86b5bd66j2kfb9r8gz13cqnf8x5hmfv0ddszf9vnfgp"))))
253 (build-system pyproject-build-system)
254 (arguments
255 (list
256 ;; When updating and checking locally be very patient as build phase may
257 ;; hang for 6-8 minutes but eventually passes through.
258 ;;
259 ;; tests: 4189 passed, 1 skipped, 2 warnings
260 #:test-flags
261 '(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
262 ;; Full test suite contains more than 70k tests; ignore network
263 ;; dependent, slow and compute intense tests, keep just unit
264 ;; tests.
265 "--ignore=tests/backends"
266 "--ignore=tests/dependencies"
267 "--ignore=tests/functional"
268 "--ignore=tests/integration"
269 "--ignore=tests/unit/botocore"
270 ;; Flaky, something to do with PATH disappearing from os.environ?
271 ;; Passes when run on its own, so maybe something else is
272 ;; modifying this during the test run.
273 "--ignore=tests/unit/customizations/emr/test_emr_utils.py"
274 ;; TypeError: 'Mock' object is not subscriptable
275 "-k" "not test_no_groff_or_mandoc_exists")
276 #:phases
277 #~(modify-phases %standard-phases
278 (add-after 'unpack 'ignore-deprecations
279 (lambda _
280 (substitute* "pyproject.toml"
281 (("\"error::") "\"ignore::"))))
282 (add-after 'unpack 'fix-reference-to-groff
283 (lambda* (#:key inputs #:allow-other-keys)
284 (substitute* "awscli/help.py"
285 (("if self._exists_on_path\\('groff'\\):") "if True:")
286 (("cmdline = \\['groff'")
287 (string-append "cmdline = ['"
288 (search-input-file inputs "bin/groff")
289 "'")))))
290 (add-before 'check 'pre-check
291 (lambda _ (setenv "HOME" "/tmp"))))))
292 (inputs
293 (list groff
294 ;; less
295 nss-certs-for-test
296 python-awscrt
297 python-colorama
298 python-dateutil
299 python-distro
300 python-docutils
301 python-jmespath
302 python-prompt-toolkit
303 python-ruamel.yaml
304 python-ruamel.yaml.clib
305 python-urllib3
306 python-wcwidth))
307 (native-inputs
308 (list python-flit-core
309 python-pytest
310 python-pytest-xdist))))
311
312;; XXX: This project missed maintainer upstream, see
313;; <https://github.com/joeyespo/grip/issues/387>.
314;; Consider to remove if it keeps failing to build.
315(define-public grip
316 (package
317 (name "grip")
318 (version "4.6.1")
319 (source
320 (origin
321 (method git-fetch)
322 (uri (git-reference
323 (url "https://github.com/joeyespo/grip")
324 (commit (string-append "v" version))))
325 (file-name (git-file-name name version))
326 (sha256
327 (base32 "0vhimd99zw7s1fihwr6yfij6ywahv9gdrfcf5qljvzh75mvzcwh8"))))
328 (build-system pyproject-build-system)
329 (arguments
330 (list
331 #:test-flags
332 ;; All tests fail requiring network access, ignore the whole file.
333 #~(list "--ignore=tests/test_github.py")
334 #:phases
335 #~(modify-phases %standard-phases
336 ;; This fixes the removal of `charset` attribute of requests from
337 ;; Werkzeug 2.3.0.
338 ;; Fixed in grip's commit <2784eb2c1515f1cdb1554d049d48b3bff0f42085>.
339 (add-after 'unpack 'fix-response-encoding
340 (lambda _
341 (substitute* "grip/app.py"
342 (("response.charset")
343 "getattr(response, 'charset', 'utf-8')")))))))
344 (native-inputs
345 (list nss-certs-for-test
346 python-pytest
347 python-responses
348 python-setuptools
349 python-wheel))
350 (propagated-inputs
351 (list python-docopt
352 python-flask
353 python-markdown
354 python-path-and-address
355 python-pygments
356 python-requests))
357 (home-page "https://github.com/joeyespo/grip")
358 (synopsis "Preview Markdown files using the GitHub API")
359 (description
360 "Grip is a command-line server application written in Python that uses
361the GitHub Markdown API to render a local Markdown file. The styles and
362rendering come directly from GitHub, so you'll know exactly how it will
363appear. Changes you make to the file will be instantly reflected in the
364browser without requiring a page refresh.")
365 (license license:expat)))
366
367(define-public gunicorn
368 (package
369 (name "gunicorn")
370 (version "25.3.0")
371 (source
372 (origin
373 (method url-fetch)
374 (uri (pypi-uri "gunicorn" version))
375 (sha256
376 (base32
377 "12g85w735s4dszjfidi4vh786rfxsa5rd60il0fcvxknkwpinkpp"))))
378 (outputs '("out" "doc"))
379 (build-system pyproject-build-system)
380 (arguments
381 `(#:test-flags
382 ;; Disable the geventlet tests because eventlet uses dnspython, which
383 ;; does not work in the build container due to lack of /etc/resolv.conf
384 '("--ignore=tests/workers/test_geventlet.py")
385 #:phases (modify-phases %standard-phases
386 ;; XXX: The wrap phase includes native inputs on PYTHONPATH, (see
387 ;; <https://bugs.gnu.org/25235>), leading to an inflated closure
388 ;; size. Override it to only add the essential entries.
389 (replace 'wrap
390 (lambda* (#:key native-inputs inputs outputs
391 #:allow-other-keys)
392 (let* ((out (assoc-ref outputs "out"))
393 (python (assoc-ref (or native-inputs inputs)
394 "python"))
395 (sitedir (string-append "/lib/python"
396 (python-version python)
397 "/site-packages")))
398 (wrap-program (string-append out "/bin/gunicorn")
399 `("PYTHONPATH" ":" prefix
400 ,(map (lambda (output)
401 (string-append output sitedir))
402 (list python out))))))))))
403 (inputs (list bash-minimal))
404 (native-inputs
405 (list binutils ;for ctypes.util.find_library()
406 python-eventlet
407 python-gevent
408 python-h2
409 python-httpx
410 python-pytest
411 python-pytest-asyncio
412 python-setuptools
413 python-uvloop))
414 (propagated-inputs
415 (list python-packaging
416 python-setuptools
417 python-wheel))
418 (home-page "https://gunicorn.org/")
419 (synopsis "Python WSGI HTTP Server for UNIX")
420 (description
421 "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
422Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
423Unicorn project. The Gunicorn server is broadly compatible with
424various web frameworks, simply implemented, light on server resources,
425and fairly speedy.")
426 (license license:expat)))
427
428;; break cyclic dependency for python-aiohttp, which depends on gunicorn for
429;; its tests
430(define-public gunicorn-bootstrap
431 (package
432 (inherit gunicorn)
433 (name "gunicorn")
434 (arguments `(#:tests? #f))
435 (properties '((hidden? . #t)))
436 (native-inputs `())))
437
438(define-public oauth2ms
439 (let ((commit "a1ef0cabfdea57e9309095954b90134604e21c08")
440 (revision "0"))
441 (package
442 (name "oauth2ms")
443 (version (git-version "0.0.0" revision commit))
444 (source (origin
445 (method git-fetch)
446 (uri (git-reference
447 (url "https://github.com/harishkrupo/oauth2ms")
448 (commit commit)))
449 (file-name (git-file-name name version))
450 (sha256
451 (base32
452 "0dqi6n4npdrvb42r672n4sl1jl8z5lsk554fwiiihpj0faa9dx64"))))
453 (build-system copy-build-system)
454 (arguments
455 (list #:install-plan #~`(("oauth2ms" "bin/oauth2ms")
456 ("." #$(string-append "share/doc/" name "-"
457 version "/")
458 #:include-regexp ("\\.org$")))
459 #:phases #~(modify-phases %standard-phases
460 (add-after 'install 'wrap-pythonpath
461 (lambda* (#:key inputs outputs #:allow-other-keys)
462 (let ((path (getenv "GUIX_PYTHONPATH")))
463 (wrap-program (string-append #$output
464 "/bin/oauth2ms")
465 `("GUIX_PYTHONPATH" ":" prefix
466 (,path)))))))))
467 (inputs (list bash-minimal python python-gnupg python-msal python-pyxdg))
468 (home-page "https://github.com/harishkrupo/oauth2ms")
469 (synopsis "XOAUTH2 compatible Microsoft Office 365 token fetcher")
470 (description
471 "Oauth2ms can be used to fetch OAuth 2.0 tokens from the Microsoft Identity
472endpoint. Additionally, it can encode the token in the XOAUTH2 format to be
473used as authentication in IMAP mail servers.")
474 (license license:asl2.0))))
475
476(define-public python-a2wsgi
477 (package
478 (name "python-a2wsgi")
479 (version "1.10.7")
480 (source (origin
481 (method url-fetch)
482 (uri (pypi-uri "a2wsgi" version))
483 (sha256
484 (base32
485 "13ikyfmkx7hlrbg5rpcdm6kw4wcsy00giil3f72hpb6sw7vjyinf"))))
486 (build-system pyproject-build-system)
487 (arguments
488 (list
489 #:test-flags
490 #~(list "-k" (string-join
491 (list "not test_starlette_stream_response"
492 "test_starlette_base_http_middleware"
493 "test_baize_stream_response"
494 ;; Fails because of harmless whitespace differences.
495 "test_wsgi_post")
496 " and not "))
497 #:build-backend "pdm.backend"))
498 (native-inputs
499 (list python-pdm-backend
500 python-pytest
501 ;; python-baize ; not packed yet
502 python-httpx-bootstrap
503 ;; Cycle: python-a2wsgi->python-uvicorn->
504 ;; python-httpx->python-starlette->python-a2wsgi
505 ;; python-starlette
506 python-pytest-asyncio))
507 (home-page "https://github.com/abersheeran/a2wsgi")
508 (synopsis "Convert WSGI to ASGI or vice versa")
509 (description
510 "This program converts a WSGI program to an ASGI program or the other
511way around. It depends only on the Python standard library.")
512 (license license:asl2.0)))
513
514(define-public python-aioboto3
515 (package
516 (name "python-aioboto3")
517 (version "15.5.0")
518 (source
519 (origin
520 (method git-fetch)
521 (uri (git-reference
522 (url "https://github.com/terricain/aioboto3")
523 (commit (string-append "v" version))))
524 (file-name (git-file-name name version))
525 (sha256
526 (base32 "05644x17f9sl8mv9bp8l0rjcmw5x2ssyd5z1v3xmgcspk5qs6qn8"))))
527 (build-system pyproject-build-system)
528 (arguments
529 (list
530 #:tests? #f ;XXX: all tests faild
531 #:phases
532 #~(modify-phases %standard-phases
533 (add-after 'unpack 'relax-requirements
534 (lambda _
535 (substitute* "pyproject.toml"
536 (("aiobotocore\\[boto3\\]==2.25.1")
537 "aiobotocore >= 2.25.1")))))))
538 (native-inputs
539 (list python-setuptools
540 python-setuptools-scm))
541 (propagated-inputs
542 (list python-aiobotocore
543 python-aiofiles
544 ;; [optional]
545 python-boto3
546 python-cryptography))
547 (home-page "https://github.com/terricain/aioboto3")
548 (synopsis "Async boto3 wrapper")
549 (description
550 "This package is mostly just a wrapper combining the great work of boto3
551and aiobotocore.")
552 (license license:asl2.0)))
553
554(define-public python-aiobotocore
555 (package
556 (name "python-aiobotocore")
557 (version "3.0.0")
558 (source
559 (origin
560 (method url-fetch)
561 (uri (pypi-uri "aiobotocore" version))
562 (sha256
563 (base32 "0bcmnbm30hwaks8l895j8xy08cil0dpjcfpidg2qjawbs4a9s0ra"))))
564 (build-system pyproject-build-system)
565 (arguments
566 ;; TODO: Tests need some setupt, see Makefile.
567 (list #:tests? #f))
568 (native-inputs
569 (list python-setuptools))
570 (propagated-inputs
571 (list python-aiohttp
572 python-aioitertools
573 python-botocore
574 python-dateutil
575 python-jmespath
576 python-multidict
577 python-typing-extensions
578 python-wrapt))
579 (home-page "https://github.com/aio-libs/aiobotocore")
580 (synopsis "Async client for AWS services using botocore and aiohttp")
581 (description "This package provides an async client for Amazon services
582using botocore and aiohttp/asyncio. This library is a mostly full featured
583asynchronous version of botocore.")
584 (license license:asl2.0)))
585
586(define-public python-aiocoap
587 (package
588 (name "python-aiocoap")
589 (version "0.4.14")
590 (source
591 (origin
592 (method git-fetch) ; tests miss data and module files in PyPI release
593 (uri (git-reference
594 (url "https://github.com/chrysn/aiocoap")
595 (commit version)))
596 (file-name (git-file-name name version))
597 (sha256
598 (base32 "0yxvcg5llgmccv0a9hfm4nr7zxv9al4wh257m95a06g5c52v6hxz"))))
599 (build-system pyproject-build-system)
600 (arguments
601 (list
602 #:test-flags
603 ;; OSError: [Errno 98] error while attempting to bind on address ('::1',
604 ;; 8683, 0, 0): address already in use
605 #~(list "--ignore=tests/test_server.py"
606 "-k" (string-join
607 ;; TypeError: can only concatenate str (not "NoneType") to
608 ;; str
609 (list "not test_options"
610 "test_uri_parser"
611 "test_help" ; returned non-zero exit status 1.
612 "test_routing" ; address already in use
613 "test_tls")
614 " and not "))))
615 (native-inputs
616 (list openssl ;for tests/test_tls.py
617 python-pytest
618 python-setuptools
619 python-wheel))
620 (propagated-inputs
621 (list ;; python-cbor-diag
622 python-cbor2
623 python-cryptography
624 ;; python-dtlssocket
625 python-filelock
626 ;; python-ge25519
627 python-pygments
628 python-termcolor
629 python-websockets))
630 (home-page "https://github.com/chrysn/aiocoap")
631 (synopsis "Python CoAP library")
632 (description
633 "The aiocoap package is an implementation of @url{@acronym{CoAP, the
634Constrained Application Protocol}, http://coap.space/}. It facilitates
635writing applications that talk to network enabled embedded
636@acronym{IoT,Internet of Things} devices.")
637 (license license:expat)))
638
639(define-public python-aiodns
640 (package
641 (name "python-aiodns")
642 (version "3.5.0")
643 (source
644 (origin
645 (method git-fetch)
646 (uri (git-reference
647 (url "https://github.com/saghul/aiodns")
648 (commit (string-append "v" version))))
649 (file-name (git-file-name name version))
650 (sha256
651 (base32 "1as7l48962dpk3r4zdsifj761dks5nyr35hxs7m8crvkyb1dg9m9"))))
652 (build-system pyproject-build-system)
653 (arguments
654 (list
655 #:tests? #f)) ;tests require internet access
656 (native-inputs
657 (list python-pytest python-pytest-asyncio python-setuptools))
658 (propagated-inputs (list python-pycares))
659 (home-page "https://github.com/saghul/aiodns")
660 (synopsis "Simple DNS resolver for asyncio")
661 (description
662 "@code{aiodns} provides a simple way for doing asynchronous DNS
663resolutions with a synchronous looking interface by using
664@url{https://github.com/saghul/pycares,pycares}.")
665 (license license:expat)))
666
667(define-public python-aioftp
668 (package
669 (name "python-aioftp")
670 (version "0.27.2")
671 (source
672 (origin
673 (method git-fetch)
674 (uri (git-reference
675 (url "https://github.com/aio-libs/aioftp")
676 (commit version)))
677 (file-name (git-file-name name version))
678 (sha256
679 (base32 "1lshyac5zk1w4x7ygkim3726f8gbkvpvlyiqkn9cs6qjxhxn5bxc"))))
680 (build-system pyproject-build-system)
681 (arguments
682 (list
683 #:phases
684 #~(modify-phases %standard-phases
685 (add-after 'unpack 'use-default-asyncio
686 ;; async_timeout is deprecated, upstream recommends to use
687 ;; asyncio, available since Python 3.11.
688 (lambda _
689 (substitute* "tests/conftest.py"
690 (("async_timeout") "asyncio")))))))
691 (native-inputs
692 (list python-pytest
693 python-pytest-mock
694 python-pytest-asyncio
695 python-setuptools
696 python-siosocks
697 python-trustme))
698 (home-page "https://aioftp.readthedocs.io/")
699 (synopsis "FTP client/server for asyncio in Python")
700 (description
701 "FTP client and server for asyncio (Python 3) Library implementing FTP
702protocol, both client and server for Python asyncio module.
703
704 Supported commands as client: USER, PASS, ACCT, PWD, CWD, CDUP, MKD, RMD,
705 MLSD, MLST, RNFR, RNTO, DELE, STOR, APPE, RETR, TYPE, PASV, ABOR, QUIT,
706 REST, LIST (as fallback).
707
708 Supported commands as server: USER, PASS, QUIT, PWD, CWD, CDUP, MKD, RMD,
709 MLSD, LIST (non-standard), MLST, RNFR, RNTO, DELE, STOR, RETR,
710 TYPE (\"I\" and \"A\"), PASV, ABOR, APPE, REST.")
711 (license license:asl2.0)))
712
713(define-public python-aiohappyeyeballs
714 (package
715 (name "python-aiohappyeyeballs")
716 (properties '((commit . "cc53cf8a1d31f7b460a0114214aac66956f0e2ed")
717 (revision . "0")))
718 (version (git-version "2.6.1"
719 (assoc-ref properties 'revision)
720 (assoc-ref properties 'commit)))
721 (source
722 (origin
723 (method git-fetch)
724 (uri (git-reference
725 (url "https://github.com/aio-libs/aiohappyeyeballs")
726 (commit (assoc-ref properties 'commit))))
727 (file-name (git-file-name name version))
728 (sha256
729 (base32 "0nc723f4sxryg5h9z8paysmy9dnqw2jy4srxp9axrxkv9qrawa7n"))))
730 (build-system pyproject-build-system)
731 (native-inputs
732 (list python-poetry-core
733 python-pytest
734 python-pytest-asyncio))
735 (home-page "https://github.com/aio-libs/aiohappyeyeballs")
736 (synopsis "Happy Eyeballs for asyncio")
737 (description "This library exists to allow connecting with Happy
738Eyeballs (RFC 8305) when you already have a list of @code{addrinfo} and not a
739DNS name.")
740 (license license:psfl)))
741
742(define-public python-aiohttp
743 (package
744 (name "python-aiohttp")
745 (version "3.13.5")
746 (source
747 (origin
748 (method git-fetch)
749 (uri (git-reference
750 (url "https://github.com/aio-libs/aiohttp/")
751 (commit (string-append "v" version))))
752 (file-name (git-file-name name version))
753 (sha256
754 (base32 "0l9jcmhqd2v97gy1bxvimwi3aajxhxqn6jkzzgg7cf42mpyza0vc"))
755 (snippet
756 #~(begin
757 (use-modules ((guix build utils)))
758 (delete-file-recursively "vendor")))))
759 (build-system pyproject-build-system)
760 (arguments
761 (list
762 ;; tests: 4003 passed, 80 skipped, 31 xfailed, 2 subtests passed
763 #:test-flags
764 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
765 ;; This tests requires the 'proxy.py' module, not yet packaged.
766 "--ignore=tests/test_proxy_functional.py"
767 ;; No benchamrks.
768 "--ignore-glob=tests/test_benchmarks_*"
769 "-k"
770 (string-join
771 ;; Combinatin of tests failing with similar errors:
772 ;; - Cannot connect to host example.com:443 ssl:default [Could
773 ;; not contact DNS servers].
774 ;; - aiohttp.http_exceptions.ContentEncodingError: 400.
775 ;; - Can not decode content-encoding: br
776 (list "not test_add_static_path_resolution"
777 "test_empty_header_name"
778 "test_http_payload_brotli"
779 "test_http_payload_zstandard"
780 "test_invalid_header_spacing"
781 "test_payload_decompress_size_limit_brotli"
782 "test_reject_obsolete_line_folding"
783 "test_response_with_precompressed_body_brotli"
784 "test_static_file_custom_content_type_compress"
785 "test_static_file_with_encoding_and_enable_compression"
786 "test_tcp_connector_ssl_shutdown_timeout_nonzero_passed"
787 "test_tcp_connector_ssl_shutdown_timeout_passed_to_"
788 "test_tcp_connector_ssl_shutdown_timeout_zero_not_")
789 " and not "))
790 #:phases
791 #~(modify-phases %standard-phases
792 (add-after 'unpack 'set-libllhtp-pkgconfig
793 (lambda _
794 ;; pkg-config can't find the libllhttp library.
795 (if (getenv "PKG_CONFIG_PATH")
796 (setenv "PKG_CONFIG_PATH"
797 (string-append
798 #$(this-package-input "llhttp") "/lib/pkgconfig"
799 (getenv "PKG_CONFIG_PATH")))
800 (setenv "PKG_CONFIG_PATH"
801 (string-append
802 #$(this-package-input "llhttp") "/lib/pkgconfig")))))
803 (add-after 'unpack 'fix-pytest-config
804 (lambda _
805 (substitute* "setup.cfg"
806 (("--numprocesses=auto") "")
807 (("-p pytest_cov") "")
808 (("--cov=aiohttp") "")
809 (("--cov=tests/") ""))))
810 (add-after 'unpack 'fix-tests
811 (lambda _
812 ;; Make sure the timestamp of this file is > 1990, because a few
813 ;; tests like test_static_file_if_modified_since_past_date
814 ;; depend on it.
815 (let ((late-90s (* 60 60 24 365 30)))
816 (utime "tests/data.unknown_mime_type" late-90s late-90s))))
817 (add-before 'build 'pre-build
818 (lambda _
819 (setenv "USE_SYSTEM_DEPS" "true")
820 ;; Help setup.py to determine project's root.
821 (with-output-to-file ".git"
822 (lambda () (display "")))
823 (substitute* "Makefile"
824 (("cythonize: .install-cython") "cythonize:"))
825 (invoke "make" "cythonize")))
826 (add-before 'check 'remove-local-source
827 (lambda _
828 (delete-file-recursively "aiohttp"))))))
829 (native-inputs
830 (list gunicorn-bootstrap
831 python-freezegun
832 python-cython
833 python-pkgconfig
834 ;; python-proxy-py ;not packaged yet in Guix
835 python-pytest
836 python-pytest-mock
837 python-pytest-xdist
838 python-re-assert
839 python-setuptools
840 python-zlib-ng))
841 (inputs
842 (list llhttp))
843 (propagated-inputs
844 (list python-aiohappyeyeballs
845 python-aiosignal
846 python-attrs
847 python-frozenlist
848 python-multidict
849 python-propcache
850 python-yarl
851 ;; [optional]
852 python-aiodns
853 python-backports-zstd ;Python version < 3.14
854 python-brotli))
855 (home-page "https://github.com/aio-libs/aiohttp/")
856 (synopsis "Async HTTP client/server framework (asyncio)")
857 (description "@code{aiohttp} is an asynchronous HTTP client/server
858framework.
859
860Its main features are:
861@itemize
862@item Supports both client and server side of HTTP protocol.
863@item Supports both client and server Web-Sockets out-of-the-box without the
864Callback Hell.
865@item Web-server has middlewares and pluggable routing.
866@end itemize")
867 (license license:asl2.0)))
868
869(define-public python-aiohttp-client-cache
870 (package
871 (name "python-aiohttp-client-cache")
872 (version "0.14.3")
873 (source
874 (origin
875 (method git-fetch)
876 (uri (git-reference
877 (url "https://github.com/requests-cache/aiohttp-client-cache")
878 (commit (string-append "v" version))))
879 (file-name (git-file-name name version))
880 (sha256
881 (base32
882 "13xbmjjvcbzh3yh5z92mc0gwicwfjfq2av5jbqv09sbfzhggs92y"))))
883 (build-system pyproject-build-system)
884 (arguments
885 (list
886 #:test-flags #~(list "--ignore=test/integration/")))
887 (native-inputs
888 (list python-brotli
889 python-faker
890 python-hatchling
891 python-pytest
892 python-pytest-aiohttp
893 python-pytest-asyncio
894 python-types-aiofiles))
895 (propagated-inputs
896 (list python-aiohttp
897 python-attrs
898 python-itsdangerous
899 python-url-normalize
900 ;; [optional]
901 python-aioboto3
902 python-aiobotocore
903 python-aiofiles
904 python-aiosqlite
905 python-pymongo
906 python-redis))
907 (home-page "https://github.com/requests-cache/aiohttp-client-cache")
908 (synopsis "Persistent cache for aiohttp requests")
909 (description
910 "This package is an asynchronous persistent caching library specifically
911designed for @samp{aiohttp} requests in Python. With support for various
912storage backends, it offers flexibility in how and where the cache is stored.
913Please note that MongoDB and DynamoDB backends are not currently supported due
914to the absence of the @samp{motor} and @samp{aioboto3} package dependencies.")
915 (license license:expat)))
916
917(define-public python-aiohttp-cors
918 (package
919 (name "python-aiohttp-cors")
920 (version "0.8.1")
921 (source
922 (origin
923 (method url-fetch)
924 (uri (pypi-uri "aiohttp_cors" version))
925 (sha256
926 (base32 "00qlzc2y65bkl1a5f5v83mmjlrhzmx3a2ngq2pm3jjdnhk5zkb6c"))))
927 (build-system pyproject-build-system)
928 (arguments
929 (list
930 #:tests? #f)) ; network access is required to run tests
931 (native-inputs
932 (list python-setuptools
933 python-wheel))
934 (propagated-inputs
935 (list python-aiohttp))
936 (home-page "https://github.com/aio-libs/aiohttp-cors")
937 (synopsis "CORS support for aiohttp")
938 (description
939 "This library implements @acronym{CORS, Cross Origin Resource Sharing}
940support for aiohttp asyncio-powered asynchronous HTTP server.")
941 (license license:asl2.0)))
942
943(define-public python-aiohttp-oauthlib
944 (package
945 (name "python-aiohttp-oauthlib")
946 (version "0.1.0")
947 (source
948 (origin
949 (method url-fetch)
950 (uri (pypi-uri "aiohttp-oauthlib" version))
951 (sha256
952 (base32 "1dwk0gby27xm7384qyz2p7zw9dqhjx7m8fhfk172w36xknjx2g49"))))
953 (build-system pyproject-build-system)
954 (arguments (list #:tests? #f)) ; none included
955 (propagated-inputs (list python-aiohttp python-oauthlib))
956 (native-inputs (list python-setuptools python-setuptools-scm))
957 (home-page "https://git.sr.ht/~whynothugo/aiohttp-oauthlib")
958 (synopsis "OAuthlib authentication support for aiohttp")
959 (description "Aiohttp-oauthlib uses the Python aiohttp and OAuthlib libraries to
960provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
961 (license license:isc)))
962
963(define-public python-aiohttp-retry
964 (package
965 (name "python-aiohttp-retry")
966 (version "2.9.1")
967 (source
968 (origin
969 (method git-fetch)
970 (uri (git-reference
971 (url "https://github.com/inyutin/aiohttp_retry")
972 (commit (string-append "v" version))))
973 (file-name (git-file-name name version))
974 (sha256
975 (base32 "0r5lxnxc4s8js7l86pfmdxl455v9lg3m41nz6m1xg4kwwf6j0bpi"))))
976 (build-system pyproject-build-system)
977 (native-inputs
978 (list python-pytest
979 python-pytest-aiohttp
980 python-setuptools))
981 (propagated-inputs
982 (list python-aiohttp))
983 (home-page "https://github.com/inyutin/aiohttp_retry")
984 (synopsis "Simple retry client for aiohttp")
985 (description
986 "This package implements @code{RetryClient} for @code{aiohttp} to retry
987connection to provided endpoint with timeouts logic or use:
988
989@itemize
990@item @code{ExponentialRetry} with exponential backoff
991@item @code{RandomRetry} for random backoff
992@item @code{ListRetry} with backoff you predefine by list
993@item @code{FibonacciRetry} with backoff that looks like fibonacci sequence
994@item @code{JitterRetry} exponential retry with a bit of randomness
995@end itemize")
996 (license license:expat)))
997
998(define-public python-aiohttp-socks
999 (package
1000 (name "python-aiohttp-socks")
1001 (version "0.10.1")
1002 (source
1003 (origin
1004 (method url-fetch)
1005 (uri (pypi-uri "aiohttp_socks" version))
1006 (sha256
1007 (base32
1008 "0s70jpcr9wc8ld2v1w309cz7r8mm2bipf6zbkdqqaa0z0pwf3wj9"))))
1009 (build-system pyproject-build-system)
1010 (arguments (list #:tests? #false)) ;none included
1011 (propagated-inputs
1012 (list python-aiohttp python-socks))
1013 (native-inputs (list python-setuptools python-wheel))
1014 (home-page "https://github.com/romis2012/aiohttp-socks")
1015 (synopsis "SOCKS proxy connector for aiohttp")
1016 (description "This package provides a SOCKS proxy connector for
1017aiohttp. It supports SOCKS4(a) and SOCKS5.")
1018 (license license:asl2.0)))
1019
1020(define-public python-aioitertools
1021 (package
1022 (name "python-aioitertools")
1023 (version "0.12.0")
1024 (source
1025 (origin
1026 (method url-fetch)
1027 (uri (pypi-uri "aioitertools" version))
1028 (sha256
1029 (base32 "0syxv2r90d6410hc68jxhk610pdgx19n1n5rc7shaxxv9xdhbaf2"))))
1030 (build-system pyproject-build-system)
1031 (arguments
1032 (list #:test-backend #~'custom
1033 #:test-flags #~(list "-m" "aioitertools.tests")))
1034 (native-inputs
1035 (list python-flit-core))
1036 (home-page "https://pypi.org/project/aioitertools/")
1037 (synopsis "Itertools and builtins for AsyncIO and mixed iterables")
1038 (description
1039 "This package provides an implementation of itertools, builtins, and more
1040for AsyncIO and mixed-type iterables.")
1041 (license license:expat)))
1042
1043(define-public python-aioquic
1044 (package
1045 (name "python-aioquic")
1046 (version "1.3.0")
1047 (source
1048 (origin
1049 (method git-fetch)
1050 (uri (git-reference
1051 (url "https://github.com/aiortc/aioquic")
1052 (commit version)))
1053 (file-name (git-file-name name version))
1054 (sha256
1055 (base32 "0dyzh8xipxbd7fcykfz8g5bgri38prwg050szqawq2p0pg538dgb"))))
1056 (build-system pyproject-build-system)
1057 (native-inputs
1058 (list nss-certs-for-test
1059 python-pytest
1060 python-setuptools))
1061 (inputs
1062 (list openssl))
1063 (propagated-inputs
1064 (list python-certifi
1065 python-cryptography
1066 python-pylsqpack
1067 python-pyopenssl
1068 python-service-identity))
1069 (home-page "https://github.com/aiortc/aioquic")
1070 (synopsis "QUIC and HTTP3 implementation in Python")
1071 (description
1072 "@code{aioquic} is a library for the QUIC network protocol in Python.
1073It features a minimal TLS 1.3 implementation, a QUIC stack and an HTTP/3 stack.")
1074 (license license:bsd-3)))
1075
1076(define-public python-aiorpcx
1077 (package
1078 (name "python-aiorpcx")
1079 (version "0.25.0")
1080 (source
1081 (origin
1082 (method git-fetch)
1083 ;; PyPI misses the util.py file used for tests.
1084 (uri (git-reference
1085 (url "https://github.com/kyuupichan/aiorpcX")
1086 (commit version)))
1087 (file-name (git-file-name name version))
1088 (sha256
1089 (base32
1090 "0sn4xxlpy0kb5b25bqrjzh2m6bskdyydc6cq8bigb7g5dacksn4q"))))
1091 (build-system pyproject-build-system)
1092 (arguments
1093 (list
1094 #:test-flags
1095 ;; This test opens a remote connection.
1096 #~(list "-k" "not test_create_connection_resolve_good")))
1097 (native-inputs (list python-pytest
1098 python-pytest-asyncio-0.26
1099 python-setuptools))
1100 (propagated-inputs
1101 (list python-attrs python-websockets))
1102 (home-page "https://github.com/kyuupichan/aiorpcX")
1103 (synopsis "Generic asyncio RPC implementation")
1104 (description
1105 "The aiorpcX library is a generic asyncio implementation of RPC suitable
1106for an application that is a client, server or both.
1107
1108The package includes a module with full coverage of JSON RPC versions 1.0 and
11092.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
1110comes with a SOCKS proxy client.")
1111 (license (list license:expat license:bsd-2))))
1112
1113(define-public python-aiosignal
1114 (package
1115 (name "python-aiosignal")
1116 (version "1.4.0")
1117 (source
1118 (origin
1119 (method url-fetch)
1120 (uri (pypi-uri "aiosignal" version))
1121 (sha256
1122 (base32 "1isin9bp256scp59lbr35h48nw5p5i84b6f9kh1c50w08vcyqzpl"))))
1123 (build-system pyproject-build-system)
1124 (arguments
1125 (list
1126 #:phases
1127 #~(modify-phases %standard-phases
1128 (add-after 'unpack 'avoid-pytest-cov-preload
1129 (lambda _
1130 (substitute* "pytest.ini"
1131 (("-p pytest_cov") "")))))))
1132 (native-inputs
1133 (list python-pytest
1134 python-pytest-asyncio
1135 python-setuptools))
1136 (propagated-inputs
1137 (list python-frozenlist))
1138 (home-page "https://github.com/aio-libs/aiosignal")
1139 (synopsis "Callback manager for Python @code{asyncio} projects")
1140 (description "This Python module provides @code{Signal}, an abstraction to
1141register asynchronous callbacks. The @code{Signal} abstraction can be used
1142for adding, removing and dropping callbacks.")
1143 (license license:asl2.0)))
1144
1145(define-public python-aiostream
1146 (package
1147 (name "python-aiostream")
1148 (version "0.7.0")
1149 (source
1150 (origin
1151 (method git-fetch) ;no tests in PyPI archive
1152 (uri (git-reference
1153 (url "https://github.com/vxgmichel/aiostream")
1154 (commit (string-append "v" version))))
1155 (file-name (git-file-name name version))
1156 (sha256
1157 (base32 "1wf89l9f0ivlv796pklpgykx6j6ksfqrmvzikd8w5j6ldln7bv50"))))
1158 (build-system pyproject-build-system)
1159 (native-inputs
1160 (list python-pytest python-pytest-asyncio python-setuptools))
1161 (propagated-inputs
1162 (list python-typing-extensions))
1163 (home-page "https://github.com/vxgmichel/aiostream")
1164 (synopsis "Generator-based operators for asynchronous iteration")
1165 (description "@code{aiostream} provides a collection of stream operators that can
1166be combined to create asynchronous pipelines of operations. It can be seen as an
1167asynchronous version of @code{itertools}, although some aspects are slightly
1168different. All the provided operators return a unified interface called a stream. A
1169stream is an enhanced asynchronous iterable.")
1170 (license license:gpl3)))
1171
1172(define-public python-ajsonrpc
1173 (package
1174 (name "python-ajsonrpc")
1175 (version "1.2.0")
1176 (source
1177 (origin
1178 (method git-fetch)
1179 (uri (git-reference
1180 (url "https://github.com/pavlov99/ajsonrpc")
1181 (commit version)))
1182 (file-name (git-file-name name version))
1183 (sha256
1184 (base32 "0c7jxfkv5q2m95j54dn650gcvdbpag2qcki7phvmrwsgb36w09kd"))))
1185 (build-system pyproject-build-system)
1186 (arguments
1187 (list
1188 #:phases
1189 #~(modify-phases %standard-phases
1190 (add-after 'unpack 'set-version
1191 (lambda _
1192 (substitute* "ajsonrpc/__init__.py"
1193 (("^__version__ = .*")
1194 (string-append "__version__ = \"" #$version "\"\n"))))))))
1195 (native-inputs
1196 (list python-pytest
1197 python-setuptools))
1198 (propagated-inputs
1199 (list python-quart
1200 python-sanic
1201 python-tornado))
1202 (home-page "https://github.com/pavlov99/ajsonrpc")
1203 (synopsis "Async JSON-RPC 2.0 protocol and server")
1204 (description
1205 "This package provides a Python JSON-RPC 2.0 protocol and server powered
1206by asyncio.")
1207 (license license:expat)))
1208
1209(define-public python-alpaca-py
1210 (package
1211 (name "python-alpaca-py")
1212 (version "0.43.5")
1213 (source
1214 (origin
1215 (method git-fetch)
1216 (uri (git-reference
1217 (url "https://github.com/alpacahq/alpaca-py")
1218 (commit (string-append "v" version))))
1219 (file-name (git-file-name name version))
1220 (sha256
1221 (base32 "1kiq8b1v58yj7fypmnfn4mij1n96ym1i9lxsd4gmbv0cgpn10nqv"))))
1222 (build-system pyproject-build-system)
1223 (native-inputs
1224 (list python-poetry-core
1225 python-poetry-dynamic-versioning
1226 python-pytest
1227 python-pytest-asyncio
1228 python-requests-mock))
1229 (propagated-inputs
1230 (list python-msgpack
1231 python-pandas
1232 python-pydantic
1233 python-pytz
1234 python-requests
1235 python-sseclient-py
1236 python-websockets))
1237 (home-page "https://alpaca.markets/sdks/python/")
1238 (synopsis "Alpaca API official Python SDK")
1239 (description
1240 "Alpaca-py provides an interface to REST, WebSocket and SSE endpoints
1241that allow interaction with the @url{https://alpaca.markets/, Alpaca} API.")
1242 (license license:asl2.0)))
1243
1244(define-public python-anaconda-client
1245 (package
1246 (name "python-anaconda-client")
1247 (version "1.13.1")
1248 (source
1249 (origin
1250 (method git-fetch)
1251 (uri (git-reference
1252 (url "https://github.com/Anaconda-Platform/anaconda-client")
1253 (commit version)))
1254 (file-name (git-file-name name version))
1255 (sha256
1256 (base32 "06nn3cwhrrajsbn9pils2539lzplfnyhn9java3xrpm3ksxq9g72"))))
1257 (build-system pyproject-build-system)
1258 (arguments
1259 (list
1260 #:test-flags
1261 #~(list "--deselect=tests/utils/test_conda.py::test_find_conda"
1262 "--deselect=tests/utils/test_conda.py::test_conda_vars")
1263 #:phases
1264 #~(modify-phases %standard-phases
1265 (add-after 'unpack 'fix-pytest-config
1266 (lambda _
1267 (substitute* "setup.cfg"
1268 (("addopts=.*") "addopts=\n")))))))
1269 (native-inputs
1270 (list python-freezegun
1271 python-pytest
1272 python-setuptools))
1273 (propagated-inputs
1274 (list python-anaconda-cli-base
1275 python-conda-package-handling
1276 python-conda-package-streaming
1277 python-dateutil
1278 python-defusedxml
1279 python-nbformat
1280 python-pillow
1281 python-platformdirs
1282 python-pytz
1283 python-pyyaml
1284 python-requests
1285 python-requests-toolbelt
1286 python-setuptools
1287 python-tqdm
1288 python-urllib3))
1289 (home-page "https://github.com/Anaconda-Platform/anaconda-client")
1290 (synopsis "Anaconda Cloud command line client library")
1291 (description
1292 "Anaconda Cloud command line client library provides an interface to
1293Anaconda Cloud. Anaconda Cloud is useful for sharing packages, notebooks and
1294environments.")
1295 (license license:bsd-3)))
1296
1297(define-public python-apiron
1298 (package
1299 (name "python-apiron")
1300 (version "5.1.0")
1301 (source
1302 (origin
1303 (method url-fetch)
1304 (uri (pypi-uri "apiron" version))
1305 (sha256
1306 (base32 "1qwbqn47sf0aqznj1snbv37v8ijx476qqkjf5l9pac7xjkxsr8qk"))))
1307 (build-system pyproject-build-system)
1308 (arguments
1309 (list #:test-flags '(list "-k" "not test_call")))
1310 (propagated-inputs
1311 (list python-requests))
1312 (native-inputs
1313 (list python-pytest
1314 python-setuptools
1315 python-wheel))
1316 (home-page "https://github.com/ithaka/apiron")
1317 (synopsis "Python wrapper for interacting with RESTful APIs")
1318 (description
1319 "@code{apiron} provides a declarative, structured configuration of
1320services and endpoints with a unified interface for interacting with RESTful
1321APIs.")
1322 (license license:expat)))
1323
1324(define-public python-apprise
1325 (package
1326 (name "python-apprise")
1327 (version "1.9.4")
1328 (source
1329 (origin
1330 (method url-fetch)
1331 (uri (pypi-uri "apprise" version))
1332 (sha256
1333 (base32 "126951n9lnlqrw5lbsvs9xs7jzg33bqqxm7cfnqag2csw6p24ca8"))))
1334 (build-system pyproject-build-system)
1335 (arguments
1336 (list
1337 ;; These tests used to be ran with --numprocesses, but that seems to have
1338 ;; made them non-deterministic.
1339 #:test-flags
1340 #~(list "--ignore=tests/test_plugin_macosx.py"
1341 "-k" "not test_plugin_glib_send_raises_generic")))
1342 (native-inputs
1343 (list python-babel
1344 python-pytest
1345 python-pytest-mock
1346 python-setuptools))
1347 (propagated-inputs
1348 (list python-certifi
1349 python-click
1350 python-markdown
1351 python-pygobject
1352 python-pyyaml
1353 python-requests
1354 python-requests-oauthlib))
1355 (home-page "https://github.com/caronc/apprise")
1356 (synopsis "Push notification library")
1357 (description
1358 "Apprise is a Python library that allows sending push notifications to a
1359broad range of notification services, such as Telegram, Discord, Slack, Amazon
1360SNS, Gotify, etc.")
1361 (license license:bsd-2)))
1362
1363(define-public python-arxiv
1364 (package
1365 (name "python-arxiv")
1366 (version "4.0.0")
1367 (source
1368 (origin
1369 (method git-fetch)
1370 (uri (git-reference
1371 (url "https://github.com/lukasschwab/arxiv.py")
1372 (commit version)))
1373 (file-name (git-file-name name version))
1374 (sha256
1375 (base32 "13363igvv3q5aj04jcrrc0cfliinlk8js84h2a9xhpwizsq96l4j"))))
1376 (build-system pyproject-build-system)
1377 (arguments
1378 (list #:test-flags
1379 #~(list "-k" ;to skip intenet connection tests
1380 (string-append "not (TestAPIBugs "
1381 "or TestClient "
1382 "or TestResult "
1383 "or TestDownload)"))
1384 #:phases
1385 #~(modify-phases %standard-phases
1386 (add-after 'unpack 'relax-dependencies
1387 (lambda _
1388 (substitute* "pyproject.toml"
1389 ;; pyproject.toml wants 6.10, guix has 6.02, seems fine
1390 (("\"lxml.*\"") "\"lxml\"")
1391 ;; artificial capped at <2.34 by dependabot
1392 (("\"requests.*\"") "\"requests\"")))))))
1393 (native-inputs
1394 (list python-pytest
1395 python-hatch-vcs
1396 python-hatchling))
1397 (propagated-inputs
1398 (list python-feedparser
1399 python-lxml
1400 python-requests))
1401 (home-page "https://github.com/lukasschwab/arxiv.py")
1402 (synopsis "Python wrapper for the arXiv API")
1403 (description "Python wrapper for the @code{arXiv} API.")
1404 (license license:expat)))
1405
1406(define-public python-asgi-csrf
1407 (package
1408 (name "python-asgi-csrf")
1409 (version "0.11")
1410 (source (origin
1411 (method git-fetch) ;for tests
1412 (uri (git-reference
1413 (url "https://github.com/simonw/asgi-csrf")
1414 (commit version)))
1415 (file-name (git-file-name name version))
1416 (sha256
1417 (base32
1418 "1dn9v47z2b599cnwahxvzsll2w28940ycgh5skxgq04vcqqssf29"))
1419 (patches
1420 (search-patches "python-asgi-csrf-fix-formparser.patch"))))
1421 (build-system pyproject-build-system)
1422 (propagated-inputs (list python-itsdangerous python-multipart))
1423 (native-inputs (list python-asgi-lifespan
1424 python-httpx
1425 python-pytest
1426 python-pytest-asyncio
1427 python-starlette
1428 python-setuptools
1429 python-wheel))
1430 (home-page "https://github.com/simonw/asgi-csrf")
1431 (synopsis "ASGI middleware for protecting against CSRF attacks")
1432 (description "This Asynchronous Server Gateway Interface (ASGI)
1433middleware protects against Cross-site request forgery (CSRF) attacks.
1434It implements the Double Submit Cookie pattern, where a cookie is set
1435that is then compared to a @code{csrftoken} hidden form field or a
1436@code{x-csrftoken} HTTP header.")
1437 (license license:asl2.0)))
1438
1439(define-public python-asgi-lifespan
1440 (package
1441 (name "python-asgi-lifespan")
1442 (version "2.1.0")
1443 (source (origin
1444 (method git-fetch) ;for tests
1445 (uri (git-reference
1446 (url "https://github.com/florimondmanca/asgi-lifespan")
1447 (commit version)))
1448 (file-name (git-file-name name version))
1449 (sha256
1450 (base32
1451 "0iqa3h61gsq1qd6j9v68k989596m9n9k1dx8zv6135rmhzzrs296"))))
1452 (build-system pyproject-build-system)
1453 (arguments
1454 (list
1455 #:test-flags
1456 '(list "-k"
1457 (string-append
1458 ;; XXX: Some tests fail because of "Exceptions from Trio nursery"
1459 "not (test_lifespan_manager[trio-None-None-StartupFailed]"
1460 " or test_lifespan_manager[trio-None-BodyFailed-None]"
1461 " or test_lifespan_manager[trio-None-BodyFailed-StartupFailed]"
1462 " or test_lifespan_manager[trio-ShutdownFailed-None-None]"
1463 " or test_lifespan_manager[trio-ShutdownFailed-None-StartupFailed]"
1464 " or test_lifespan_manager[trio-ShutdownFailed-BodyFailed-StartupFailed]"
1465 " or test_lifespan_timeout[trio-slow_shutdown]"
1466 " or test_lifespan_not_supported[trio-http_only]"
1467 " or test_lifespan_not_supported[trio-http_no_assert]"
1468 " or test_lifespan_not_supported[trio-http_no_assert_before_receive_request]"
1469 ")"))
1470 #:phases
1471 '(modify-phases %standard-phases
1472 (add-after 'unpack 'compatibility
1473 (lambda _
1474 ;; httpx version 0.28.0 removed the "app" shortcut.
1475 (substitute* "tests/test_manager.py"
1476 (("app=manager.app")
1477 "transport=httpx.ASGITransport(manager.app)")))))))
1478 (native-inputs (list python-httpx
1479 python-pytest
1480 python-pytest-asyncio
1481 python-pytest-trio
1482 python-starlette
1483 python-setuptools
1484 python-wheel))
1485 (propagated-inputs (list python-sniffio))
1486 (home-page "https://github.com/florimondmanca/asgi-lifespan")
1487 (synopsis "Programmatic startup/shutdown of ASGI apps")
1488 (description "Programmatically send startup/shutdown lifespan events
1489into Asynchronous Server Gateway Interface (ASGI) applications. When
1490used in combination with an ASGI-capable HTTP client such as HTTPX, this
1491allows mocking or testing ASGI applications without having to spin up an
1492ASGI server.")
1493 (license license:expat)))
1494
1495(define-public python-asgiref
1496 (package
1497 (name "python-asgiref")
1498 (version "3.11.1")
1499 (source
1500 (origin
1501 (method git-fetch)
1502 (uri (git-reference
1503 (url "https://github.com/django/asgiref/")
1504 (commit version)))
1505 (file-name (git-file-name name version))
1506 (sha256
1507 (base32 "19l03mx81dqhnnqa98073x1q243ndlknax0kva7azr9g12ixl69j"))))
1508 (build-system pyproject-build-system)
1509 (native-inputs
1510 (list python-pytest
1511 python-pytest-asyncio
1512 python-setuptools))
1513 (home-page "https://github.com/django/asgiref/")
1514 (synopsis "ASGI specs, helper code, and adapters")
1515 (description
1516 "ASGI is a standard for Python asynchronous web apps and servers to
1517communicate with each other, and positioned as an asynchronous successor to
1518WSGI. This package includes libraries for implementing ASGI servers.")
1519 (license license:bsd-3)))
1520
1521(define-public python-asyncer
1522 (package
1523 (name "python-asyncer")
1524 (version "0.0.17")
1525 (source
1526 (origin
1527 (method git-fetch)
1528 (uri (git-reference
1529 (url "https://github.com/fastapi/asyncer")
1530 (commit version)))
1531 (file-name (git-file-name name version))
1532 (sha256
1533 (base32 "1f4ids6sxwmz89yj98z0qc4qvfkklh0psbxv5px39k807g9aq7p2"))))
1534 (build-system pyproject-build-system)
1535 (native-inputs
1536 (list python-pdm-backend
1537 python-pytest))
1538 (propagated-inputs
1539 (list python-anyio
1540 python-sniffio
1541 python-typing-extensions))
1542 (home-page "https://asyncer.tiangolo.com/")
1543 (synopsis "Asyncer, async and await, focused on developer experience")
1544 (description
1545 "Asyncer is a small library built on top of
1546@url{https://anyio.readthedocs.io/en/stable/, AnyIO}.
1547
1548The main goal of Asyncer is to improve developer experience by providing
1549better support for autocompletion and inline errors in the editor, and more
1550certainty that the code is bug-free by providing better support for type
1551checking tools like mypy.")
1552 (license license:expat)))
1553
1554(define-public python-asyncudp
1555 (package
1556 (name "python-asyncudp")
1557 (version "0.11.0")
1558 (source
1559 (origin
1560 (method git-fetch)
1561 (uri (git-reference
1562 (url "https://github.com/eerimoq/asyncudp")
1563 (commit version)))
1564 (file-name (git-file-name name version))
1565 (sha256
1566 (base32 "1i2s8mmmggzq6vk5aldz3g85jnqfbgxfqi60wl58jpn2lbr8fqlr"))))
1567 (build-system pyproject-build-system)
1568 (native-inputs (list python-pytest python-setuptools))
1569 (home-page (git-reference-url (origin-uri source)))
1570 (synopsis "High level UDP sockets for asyncio")
1571 (description
1572 "This package provides a Python library offering high level UDP sockets
1573for asyncio. Import it alongside asyncio and use its API to send and receive
1574UDP packets.")
1575 (license license:expat)))
1576
1577(define-public python-authlib
1578 (package
1579 (name "python-authlib")
1580 (version "1.6.12")
1581 (source
1582 (origin
1583 (method git-fetch)
1584 (uri (git-reference
1585 (url "https://github.com/authlib/authlib")
1586 (commit (string-append "v" version))))
1587 (file-name (git-file-name name version))
1588 (sha256
1589 (base32 "0vh1kvmipxa8xp3x5jwqg1gzy4zac2skfj1mv5698jsmfzs2zd8w"))))
1590 (build-system pyproject-build-system)
1591 (arguments
1592 (list
1593 #:test-flags
1594 ;; httpx2 has succeed httpx in authlib 1.8.0 (2026-08-30) which requires
1595 ;; cryptography >= 45.0.1; leave it for the next python-team cycle and
1596 ;; ignore httpx tests for now.
1597 #~(list "--ignore=tests/clients/test_httpx/")
1598 #:phases
1599 #~(modify-phases %standard-phases
1600 (add-before 'check 'pre-check
1601 (lambda _
1602 (setenv "DJANGO_SETTINGS_MODULE" "tests.django_settings"))))))
1603 (propagated-inputs
1604 (list python-cryptography
1605 ;; [optional]
1606 python-anyio
1607 python-asgiref
1608 python-cachelib
1609 python-django
1610 python-flask
1611 python-flask-sqlalchemy
1612 python-httpx
1613 python-requests
1614 python-starlette))
1615 (native-inputs
1616 (list python-pytest
1617 python-pytest-asyncio
1618 python-pytest-django
1619 python-setuptools))
1620 (home-page "https://authlib.org/")
1621 (synopsis "Build OAuth and OpenID Connect servers and clients")
1622 (description
1623 "This is a Python library for building OAuth and OpenID Connect servers
1624and clients.")
1625 (license license:bsd-3)))
1626
1627(define-public python-autobahn
1628 (package
1629 (name "python-autobahn")
1630 (version "25.11.1")
1631 (source
1632 (origin
1633 (method url-fetch)
1634 (uri (pypi-uri "autobahn" version))
1635 (sha256
1636 (base32
1637 "1w9wyyqzg1dil8jsjm08n2pnk6jws87scli932drhghcr2f2prjj"))))
1638 (build-system pyproject-build-system)
1639 (arguments
1640 (list
1641 ;; The tests fail to run:
1642 ;; https://github.com/crossbario/autobahn-python/issues/1117
1643 #:tests? #f
1644 #:phases #~(modify-phases %standard-phases
1645 (add-after 'unpack 'relax-zope-interface
1646 (lambda _
1647 ;; python-zope-interface is a world rebuild package
1648 ;; and our one-digit lower minor version seems to be
1649 ;; fine.
1650 (substitute* "setup.py"
1651 (("zope.interface>=5.2.0")
1652 "zope.interface>=5.1.0"))))
1653 (add-after 'unpack 'strip-xbr
1654 (lambda _
1655 ;; Strip new XBR feature which isn't available in Guix.
1656 (setenv "AUTOBAHN_STRIP_XBR" "1"))))))
1657 (native-inputs (list python-setuptools python-wheel))
1658 (propagated-inputs (list python-cbor2
1659 python-cryptography
1660 python-hyperlink
1661 python-msgpack
1662 python-py-ubjson
1663 python-twisted
1664 python-txaio
1665 python-ujson))
1666 (home-page "https://github.com/crossbario/autobahn-python/")
1667 (synopsis "Web Application Messaging Protocol implementation")
1668 (description "This package provides an implementation of the @dfn{Web Application
1669Messaging Protocol} (WAMP). WAMP connects components in distributed
1670applications using Publish and Subscribe (PubSub) and routed Remote Procedure
1671Calls (rRPC). It is ideal for distributed, multi-client and server applications
1672such as IoT applications or multi-user database-driven business applications.")
1673 (license license:expat)))
1674
1675(define-public python-aws-sam-translator
1676 (package
1677 (name "python-aws-sam-translator")
1678 (version "1.107.0")
1679 (source
1680 (origin
1681 (method git-fetch) ; no tests in PyPI release
1682 (uri (git-reference
1683 (url "https://github.com/aws/serverless-application-model")
1684 (commit (string-append "v" version))))
1685 (file-name (git-file-name name version))
1686 (sha256
1687 (base32 "0bx9ha9k6zx6gl1hsgm6cpq4xrfn604v2g1d5dh2d5zq0463gwfq"))))
1688 (build-system pyproject-build-system)
1689 (arguments
1690 (list
1691 #:test-flags
1692 #~(list "--numprocesses" (number->string (parallel-job-count))
1693 "--ignore=tests/bin/test_public_interface.py"
1694 "tests")
1695 #:phases
1696 #~(modify-phases %standard-phases
1697 (add-before 'check 'pre-check
1698 (lambda _
1699 (setenv "AWS_DEFAULT_REGION" "eu-west-3"))))))
1700 (native-inputs
1701 (list python-pytest
1702 python-pytest-rerunfailures
1703 python-pytest-xdist
1704 python-parameterized
1705 python-pyyaml
1706 python-setuptools))
1707 (propagated-inputs
1708 (list python-boto3
1709 python-jsonschema
1710 python-pydantic
1711 python-typing-extensions))
1712 (home-page "https://github.com/aws/serverless-application-model")
1713 (synopsis "Transform AWS SAM templates into AWS CloudFormation templates")
1714 (description
1715 "AWS SAM Translator is a library that transform @dfn{Serverless Application
1716Model} (SAM) templates into AWS CloudFormation templates.")
1717 (license license:asl2.0)))
1718
1719(define-public python-aws-xray-sdk
1720 (package
1721 (name "python-aws-xray-sdk")
1722 (version "2.14.0")
1723 (home-page "https://github.com/aws/aws-xray-sdk-python")
1724 (source (origin
1725 (method git-fetch)
1726 (uri (git-reference (url home-page) (commit version)))
1727 (file-name (git-file-name name version))
1728 (sha256
1729 (base32
1730 "0khm86218rfjmgfw0azk7gnq6y9gkj95i0i30wa5v2li1z4z8qxd"))))
1731 (build-system pyproject-build-system)
1732 (arguments
1733 (list
1734 #:test-flags
1735 '(list ;; Tries to connect to external network resources
1736 "--ignore=tests/ext/aiohttp/test_client.py"
1737 "--ignore=tests/ext/httplib/test_httplib.py"
1738 "--ignore=tests/ext/httpx"
1739 "--ignore=tests/ext/requests/test_requests.py"
1740 ;; TODO: How to configure Django for these tests?
1741 "--ignore=tests/ext/django"
1742 ;; These tests require packages not yet in Guix.
1743 "--ignore=tests/ext/aiobotocore/test_aiobotocore.py"
1744 "--ignore=tests/ext/aiohttp/test_middleware.py"
1745 "--ignore=tests/ext/pg8000/test_pg8000.py"
1746 "--ignore=tests/ext/psycopg2/test_psycopg2.py"
1747 "--ignore=tests/ext/pymysql/test_pymysql.py"
1748 "--ignore=tests/ext/pynamodb/test_pynamodb.py"
1749 "--ignore=tests/ext/sqlalchemy_core/test_postgres.py"
1750 "--ignore=tests/ext/sqlalchemy_core/test_dburl.py"
1751 "--ignore=tests/test_async_recorder.py"
1752 ;; FIXME: module 'sqlalchemy.orm' has no attribute 'DeclarativeBase'.
1753 "--ignore-glob=tests/ext/sqlalchemy*"
1754 "--ignore=tests/ext/flask_sqlalchemy/test_query.py"
1755 ;; FIXME: Why is this failing?
1756 "--ignore=tests/test_patcher.py"
1757 "--ignore=tests/test_lambda_context.py")
1758 #:phases
1759 '(modify-phases %standard-phases
1760 (add-before 'check 'pre-check
1761 (lambda _
1762 ;; Allow "import tests.utils" to work as expected.
1763 (setenv "PYTHONPATH" (getcwd)))))))
1764 (native-inputs
1765 (list ;; These are required for the test suite.
1766 python-aiohttp
1767 python-bottle
1768 python-flask
1769 python-flask-sqlalchemy
1770 python-httpx
1771 python-mock
1772 python-pymysql
1773 python-pytest
1774 python-pytest-asyncio-0.26
1775 python-pytest-benchmark
1776 python-setuptools
1777 python-sqlalchemy
1778 python-webtest))
1779 (propagated-inputs
1780 (list python-botocore
1781 python-jsonpickle
1782 python-requests
1783 python-wrapt))
1784 (synopsis "Profile applications on AWS X-Ray")
1785 (description
1786 "The AWS X-Ray SDK for Python enables Python developers to record and
1787emit information from within their applications to the AWS X-Ray service.")
1788 (license license:asl2.0)))
1789
1790(define-public python-awscrt
1791 (package
1792 (name "python-awscrt")
1793 (version "0.36.0")
1794 (source
1795 (origin
1796 (method url-fetch)
1797 (uri (pypi-uri "awscrt" version))
1798 (sha256
1799 (base32 "0jh6niq9kgv0canm11ad8zibywwirdfxg4bqyd8jhaiv3x39h8dd"))))
1800 (build-system pyproject-build-system)
1801 (arguments
1802 (list
1803 #:test-backend #~'unittest
1804 #:test-flags #~(list "discover" "--verbose")
1805 #:phases
1806 #~(modify-phases %standard-phases
1807 (add-after 'unpack 'disable-broken-tests
1808 (lambda _
1809 ;; Disable broken tests. These tests fail because they depend on
1810 ;; specific DNS configuration and/or AWS credentials, which isn't
1811 ;; available in this context.
1812 (substitute* "test/test_auth.py"
1813 (("def test_default_provider")
1814 "def _test_default_provider"))
1815 (substitute* "test/test_aiohttp_client.py"
1816 (("def test_h2_remote_end_stream_ordering")
1817 "def _test_h2_remote_end_stream_ordering")
1818 (("def test_cross_thread_http2_client")
1819 "def _test_cross_thread_http2_client")
1820 (("def test_h2_client")
1821 "def _test_h2_client")
1822 (("def test_h2_manual_write_exception")
1823 "def _test_h2_manual_write_exception"))
1824 (substitute* "test/test_http_client.py"
1825 (("def test_h2_client")
1826 "def _test_h2_client")
1827 (("def test_h2_remote_end_stream_ordering")
1828 "def _test_h2_remote_end_stream_ordering")
1829 (("def test_h2_manual_write_exception")
1830 "def _test_h2_manual_write_exception"))
1831 (substitute* "test/test_s3.py"
1832 (("def test_sanity")
1833 "def _test_sanity")
1834 (("def test_sanity_secure")
1835 "def _test_sanity_secure")
1836 (("def test_wait_shutdown")
1837 "def _test_wait_shutdown"))
1838 (substitute* "test/test_io.py"
1839 ;; This test seems specifically broken. It waits for a shutdown event
1840 ;; from a group of singletons that will never occur because several of
1841 ;; the singleton references are held beyond the lifetime of this test.
1842 (("def test_shutdown_complete_singleton")
1843 "def _test_shutdown_complete_singleton"))))
1844 (add-after 'unpack 'override-cert-bundle-location
1845 (lambda* (#:key inputs #:allow-other-keys)
1846 (let ((bundle (search-input-file inputs
1847 "/etc/ssl/certs/ca-certificates.crt")))
1848 (setenv "SSL_CERT_FILE" bundle)
1849 (substitute* "awscrt/io.py"
1850 (("( +)opt = TlsContextOptions\\(\\)" m indent)
1851 (string-append m "\n"
1852 indent "import os\n"
1853 indent "\
1854opt.override_default_trust_store_from_path(None, os.getenv('SSL_CERT_FILE')) if os.getenv('SSL_CERT_FILE') else None\n"))
1855 (("^( +)self\\.no_certificate_revocation = False" all indent)
1856 (string-append all "\n"
1857 indent "import os as _os\n"
1858 indent "_ca_file = _os.environ.get('SSL_CERT_FILE')\n"
1859 indent "if _ca_file:\n"
1860 indent " self.override_default_trust_store(_read_binary_file(_ca_file))\n")))
1861 (substitute* "test/appexit_http.py"
1862 (("( +)tls_ctx_opt = awscrt.io.TlsContextOptions.*" m indent)
1863 (string-append m indent
1864 "tls_ctx_opt.override_default_trust_store_from_path(None, '"
1865 bundle "')\n")))
1866 (substitute* "test/test_io.py"
1867 (("( +)opt = TlsContextOptions\\(\\).*" m indent)
1868 (string-append m indent
1869 "opt.override_default_trust_store_from_path(None, '"
1870 bundle "')\n"))))))
1871 (add-after 'unpack 'use-system-libraries
1872 (lambda _
1873 (setenv "AWS_CRT_BUILD_USE_SYSTEM_LIBCRYPTO" "1"))))))
1874 (inputs (list openssl))
1875 (native-inputs (list cmake-minimal
1876 nss-certs-for-test
1877 python-boto3
1878 python-setuptools
1879 python-websockets
1880 python-h2))
1881 (home-page "https://github.com/awslabs/aws-crt-python")
1882 (synopsis "Common runtime for AWS Python projects")
1883 (description
1884 "This package provides a common runtime for AWS Python projects.")
1885 (license license:asl2.0)))
1886
1887(define-public python-azure-common
1888 (package
1889 (name "python-azure-common")
1890 (version "1.1.28")
1891 (source
1892 (origin
1893 (method url-fetch)
1894 (uri (pypi-uri "azure-common" version ".zip"))
1895 (sha256
1896 (base32 "18q4cy1xl2zly3rk7a1sc14w932x59r8c9j4d8dnlsz32hrcvh2a"))))
1897 (build-system pyproject-build-system)
1898 (arguments
1899 (list #:tests? #f)) ;no tests in PyPI archive
1900 (propagated-inputs (list python-azure-nspkg))
1901 (native-inputs (list python-setuptools unzip))
1902 (home-page "https://github.com/Azure/azure-sdk-for-python")
1903 (synopsis "Microsoft Azure Client library for Python")
1904 (description "This package provides the Microsoft Azure Client library for
1905Python.")
1906 (license license:expat)))
1907
1908(define-public python-azure-core
1909 (package
1910 (name "python-azure-core")
1911 (version "1.32.0")
1912 (source
1913 (origin
1914 (method url-fetch)
1915 (uri (pypi-uri "azure_core" version))
1916 (sha256
1917 (base32 "1r9hqyqr5fxiiai0irr0n98gwgzj5f8y46vc1yci9bidddfw7cr2"))))
1918 (build-system pyproject-build-system)
1919 (arguments
1920 (list
1921 #:test-flags
1922 `(list ;; This fails because devtools_testutils doesn't exist.
1923 "--ignore=tests/test_connection_string_parsing.py"
1924 ;; These all need network access.
1925 "--ignore=samples"
1926 "--ignore=tests/async_tests/test_streaming_async.py"
1927 "--ignore=tests/test_streaming.py"
1928 "-m" "not asyncio and not live_test_only"
1929 "-k" ,(string-append
1930 "not test_decompress_plain_no_header"
1931 " and not test_compress_plain_no_header"
1932 " and not test_decompress_compressed_no_header"
1933 " and not test_requests_socket_timeout"))
1934 #:phases
1935 #~(modify-phases %standard-phases
1936 (add-before 'check 'add-test-pythonpath
1937 (lambda* (#:key tests? #:allow-other-keys)
1938 (when tests?
1939 (setenv "PYTHONPATH"
1940 (string-append
1941 (getcwd) "/tests/testserver_tests/coretestserver:"
1942 (getenv "GUIX_PYTHONPATH")))))))))
1943 (propagated-inputs
1944 (list python-aiohttp
1945 python-requests
1946 python-six
1947 python-typing-extensions))
1948 (native-inputs
1949 (list python-flask
1950 python-pytest-8
1951 python-pytest-aiohttp
1952 python-pytest-asyncio
1953 python-pytest-trio
1954 python-setuptools
1955 python-wheel))
1956 (home-page "https://github.com/Azure/azure-sdk-for-python")
1957 (synopsis "Microsoft Azure Core library for Python")
1958 (description "This package provides the Microsoft Azure Core library for
1959Python.")
1960 (license license:expat)))
1961
1962(define-public python-azure-nspkg
1963 (package
1964 (name "python-azure-nspkg")
1965 (version "3.0.2")
1966 (source
1967 (origin
1968 (method url-fetch)
1969 (uri (pypi-uri "azure-nspkg" version ".zip"))
1970 (sha256
1971 (base32
1972 "1l4xwdh0fcnvrv0mzig4g2kgqkfbsy64zjm1ggc6grk3mykcxlz7"))))
1973 (build-system pyproject-build-system)
1974 (arguments (list #:tests? #f)) ;no tests in package
1975 (native-inputs (list unzip python-setuptools))
1976 (home-page "https://github.com/Azure/azure-sdk-for-python")
1977 (synopsis "Azure namespace internals")
1978 (description
1979 "This package is an internal Azure namespace package.")
1980 (license license:expat)))
1981
1982(define-public python-azure-storage-blob
1983 (package
1984 (name "python-azure-storage-blob")
1985 (version "12.27.0")
1986 (source
1987 (origin
1988 (method url-fetch)
1989 (uri (pypi-uri "azure_storage_blob" version))
1990 (sha256
1991 (base32 "16nb17f6bi0k53qlxybwqxdld3nj742hmsk4qcq3jwka5b6y5s4r"))))
1992 (build-system pyproject-build-system)
1993 (arguments
1994 ;; XXX: devtools_testutils is not provided as a proper package on PyPI,
1995 ;; Git does not contains setup.py, setup.cfg or pyproject.toml which makes
1996 ;; it hard to package in Guix.
1997 ;; <https://raw.githubusercontent.com/Azure/azure-sdk-for-python/refs/
1998 ;; heads/main/tools/azure-sdk-tools/devtools_testutils/README.md>.
1999 (list #:tests? #f))
2000 (native-inputs
2001 (list python-setuptools))
2002 (propagated-inputs
2003 (list python-azure-core
2004 python-cryptography
2005 python-isodate
2006 python-typing-extensions))
2007 (home-page "https://github.com/Azure/azure-sdk-for-python/")
2008 (synopsis "Microsoft Azure Blob Storage client library for Python")
2009 (description "This package provides the Microsoft Azure Blob Storage
2010Client Library for Python.")
2011 (license license:expat)))
2012
2013(define-public python-azure-storage-file-datalake
2014 (package
2015 (name "python-azure-storage-file-datalake")
2016 (version "12.22.0")
2017 (source
2018 (origin
2019 (method url-fetch)
2020 (uri (pypi-uri "azure_storage_file_datalake" version))
2021 (sha256
2022 (base32 "0xxg94684b630p8jrz38sg7mdcwp1wa0p5di27mswyrjycshvvcs"))))
2023 (build-system pyproject-build-system)
2024 (arguments
2025 ;; XXX: devtools_testutils is not provided as a proper package on PyPI,
2026 ;; Git does not contains setup.py, setup.cfg or pyproject.toml which makes
2027 ;; it hard to package in Guix.
2028 ;; <https://raw.githubusercontent.com/Azure/azure-sdk-for-python/refs/
2029 ;; heads/main/tools/azure-sdk-tools/devtools_testutils/README.md>.
2030 (list #:tests? #f))
2031 (native-inputs
2032 (list python-setuptools))
2033 (propagated-inputs
2034 (list python-azure-core
2035 python-azure-storage-blob
2036 python-isodate
2037 python-typing-extensions))
2038 (home-page "https://github.com/Azure/azure-sdk-for-python")
2039 (synopsis "Microsoft Azure File DataLake Storage Client Library for Python")
2040 (description
2041 "This package provides the Microsoft Azure File @code{DataLake} Storage
2042Client Library for Python.")
2043 (license license:expat)))
2044
2045(define-public python-azure-storage-nspkg
2046 (package
2047 (name "python-azure-storage-nspkg")
2048 (version "3.1.0")
2049 (source
2050 (origin
2051 (method url-fetch)
2052 (uri (pypi-uri "azure-storage-nspkg" version))
2053 (sha256
2054 (base32 "049qcmgshz7dj9yaqma0fwcgbxwddgwyfcw4gmv45xfmaa3bwfvg"))))
2055 (build-system pyproject-build-system)
2056 (arguments
2057 (list #:tests? #f)) ;no tests in PyPI archive
2058 (native-inputs (list python-setuptools))
2059 (propagated-inputs (list python-azure-nspkg))
2060 (home-page "https://github.com/Azure/azure-storage-python")
2061 (synopsis "Microsoft Azure Storage Namespace package")
2062 (description
2063 "This project provides a client library in Python that makes it easy to
2064communicate with Microsoft Azure Storage services.")
2065 (license license:expat)))
2066
2067(define-public python-behave-web-api
2068 (package
2069 (name "python-behave-web-api")
2070 (version "2.3.0")
2071 (source
2072 (origin
2073 (method git-fetch)
2074 (uri (git-reference
2075 (url "https://github.com/jefersondaniel/behave-web-api")
2076 (commit (string-append "v" version))))
2077 (file-name (git-file-name name version))
2078 (sha256
2079 (base32 "1r8yx8gb5m599cpdqfvk6z9ax3qj26fpvczdr84z8jya0dxfch4p"))))
2080 (build-system pyproject-build-system)
2081 (native-inputs
2082 (list python-pytest
2083 python-setuptools))
2084 (propagated-inputs
2085 (list behave
2086 python-requests))
2087 (home-page "https://github.com/jefersondaniel/behave-web-api")
2088 (synopsis "Provides testing for JSON APIs with Behave for Python")
2089 (description "This package provides testing utility modules for testing
2090JSON APIs with Behave.")
2091 (license license:expat)))
2092
2093(define-public python-beren
2094 (package
2095 (name "python-beren")
2096 (version "0.7.0")
2097 (source
2098 (origin
2099 (method git-fetch)
2100 (uri (git-reference
2101 (url "https://github.com/teffalump/beren")
2102 (commit (string-append "v" version))))
2103 (file-name (git-file-name name version))
2104 (sha256
2105 (base32 "19nnvbjx2wypslqklqi0j9fiwypk1a5qwfw1jcabjw03awm1yyrx"))))
2106 (build-system pyproject-build-system)
2107 (arguments
2108 ;; The test tries to open a connection to a remote server.
2109 `(#:tests? #f))
2110 (native-inputs (list python-setuptools))
2111 (propagated-inputs (list python-apiron))
2112 (home-page "https://github.com/teffalump/beren")
2113 (synopsis "REST client for Orthanc DICOM servers")
2114 (description
2115 "@code{beren} provides a REST client for Orthanc, a DICOM server.")
2116 (license license:gpl3+)))
2117
2118(define-public python-betamax
2119 (package
2120 (name "python-betamax")
2121 (version "0.9.0")
2122 (source
2123 (origin
2124 (method url-fetch)
2125 (uri (pypi-uri "betamax" version))
2126 (sha256
2127 (base32
2128 "152zil1j4gl1whnldi08zwjr4z2bnlbd061kr3ipjs5wg4b6wcc2"))))
2129 (build-system pyproject-build-system)
2130 (arguments
2131 (list
2132 #:test-flags
2133 #~(list "-k" (string-join
2134 ;; Tests require network access to http://httpbin.org/get.
2135 (list "not test_creates_new_cassettes"
2136 "test_placeholders_work"
2137 "test_post_start_hook"
2138 "test_pre_stop_hook"
2139 "test_preplayback_hook"
2140 "test_prerecord_hook"
2141 "test_prerecord_ignoring_hook"
2142 "test_records_new_events_with_existing_cassette"
2143 "test_records_new_interaction"
2144 "test_records_new_interactions"
2145 "test_replaces_old_interactions"
2146 "test_replays_response_from_cassette"
2147 "test_requests_with_json_body"
2148 "test_saves_content_as_gzip"
2149 "test_unicode_is_saved_properly")
2150 " and not "))))
2151 (native-inputs
2152 (list nss-certs-for-test
2153 python-pytest
2154 python-setuptools))
2155 (propagated-inputs
2156 (list python-requests))
2157 (home-page "https://github.com/sigmavirus24/betamax")
2158 (synopsis "Record HTTP interactions with python-requests")
2159 (description
2160 "Betamax will record your test suite's HTTP interactions and replay them
2161during future tests. It is designed to work with python-requests.")
2162 (license license:expat)))
2163
2164(define-public python-betamax-matchers
2165 (package
2166 (name "python-betamax-matchers")
2167 (version "0.4.0")
2168 (source
2169 (origin
2170 (method git-fetch)
2171 (uri (git-reference
2172 (url "https://github.com/sigmavirus24/betamax_matchers")
2173 (commit version)))
2174 (file-name (git-file-name name version))
2175 (sha256
2176 (base32 "0lyg3r91hwfvavyi5k6sddcla37igigycfv1mx40c32byqwl6pq5"))))
2177 (build-system pyproject-build-system)
2178 (native-inputs (list python-pytest python-setuptools))
2179 (propagated-inputs (list python-betamax python-requests-toolbelt))
2180 (home-page "https://github.com/sigmavirus24/betamax_matchers")
2181 (synopsis "VCR imitation for python-requests")
2182 (description "@code{betamax-matchers} provides a set of Matchers for
2183Betamax.")
2184 (license license:asl2.0)))
2185
2186(define-public python-betamax-serializers
2187 (package
2188 (name "python-betamax-serializers")
2189 (version "0.2.1")
2190 (source
2191 (origin
2192 (method git-fetch)
2193 (uri (git-reference
2194 (url "https://gitlab.com/betamax/serializers")
2195 (commit version)))
2196 (file-name (git-file-name name version))
2197 (sha256
2198 (base32 "1p2l5w3vwvjacs2ndahgcjq55qb53i37p8mz1zh85pjxyszdyw2l"))))
2199 (build-system pyproject-build-system)
2200 (arguments (list #:tests? #f)) ; No tests.
2201 (native-inputs (list python-setuptools))
2202 (propagated-inputs (list python-betamax python-pyyaml))
2203 (synopsis "Set of third-party serializers for Betamax")
2204 (description
2205 "Betamax-Serializers are an experimental set of Serializers for Betamax
2206that may possibly end up in the main package.")
2207 (home-page "https://gitlab.com/betamax/serializers")
2208 (license license:asl2.0)))
2209
2210(define-public python-blacksheep
2211 (package
2212 (name "python-blacksheep")
2213 (version "2.6.3")
2214 (source
2215 (origin
2216 (method git-fetch)
2217 (uri (git-reference
2218 (url "https://github.com/Neoteroi/BlackSheep")
2219 (commit (string-append "v" version))))
2220 (file-name (git-file-name name version))
2221 (sha256
2222 (base32 "1k6yqsqnh6nnhi8z5v2yqpxs7qsk35zwd7gcr7cdh825f2vrl7js"))))
2223 (build-system pyproject-build-system)
2224 (arguments
2225 (list
2226 ;; tests: 1821 passed
2227 ;;
2228 ;; Run all unit tests, but do not run integration tests from `itests`
2229 ;; directory.
2230 #:test-flags
2231 #~(list "tests")
2232 #:phases
2233 #~(modify-phases %standard-phases
2234 (add-before 'build 'cythonize
2235 (lambda _
2236 (with-directory-excursion "blacksheep"
2237 (for-each (lambda (file)
2238 (invoke "cython" "-3" file "-I" "."))
2239 (find-files "." ".*\\.pyx$"))))))))
2240 (native-inputs
2241 (list nss-certs-for-test
2242 python-cython
2243 python-defusedxml
2244 python-flask
2245 python-jinja2
2246 python-pydantic
2247 python-pyjwt
2248 python-pytest
2249 python-pytest-asyncio
2250 python-setuptools
2251 python-starlette))
2252 (propagated-inputs
2253 (list python-certifi
2254 python-essentials
2255 python-essentials-openapi
2256 python-guardpost
2257 python-httptools
2258 python-rodi
2259 python-itsdangerous))
2260 (home-page "https://github.com/Neoteroi/BlackSheep")
2261 (synopsis "Asynchronous framework to build event based web applications")
2262 (description
2263 "BlackSheep is a lightweight, asynchronous, event driven Web framework.
2264
2265The framework offers
2266@itemize
2267@item A rich code API, based on dependency injection and inspired by Flask and
2268ASP.NET Core.
2269@item A typing-friendly codebase, which enables a comfortable development
2270experience thanks to hints when coding with IDEs.
2271@item Built-in generation of OpenAPI Documentation, supporting version 3, YAML,
2272and JSON.
2273@item A cross-platform framework, using the most modern versions of Python.
2274@item Good performance.
2275@end itemize")
2276 (license license:expat)))
2277
2278(define-public python-bleach
2279 (package
2280 (name "python-bleach")
2281 (version "6.3.0")
2282 (source
2283 (origin
2284 (method git-fetch)
2285 (uri (git-reference
2286 (url "https://github.com/mozilla/bleach")
2287 (commit (string-append "v" version))))
2288 (file-name (git-file-name name version))
2289 (sha256
2290 (base32 "02abk9ixn010sqpbdsd7nxms0gv4prwv6d3nplb8giq85lpn1kkb"))
2291 (snippet
2292 #~(begin
2293 (use-modules (guix build utils))
2294 (substitute* (find-files "." "\\.py$")
2295 (("bleach\\._vendor\\.html5lib") "html5lib"))
2296 (delete-file-recursively "bleach/_vendor/html5lib")))))
2297 (build-system pyproject-build-system)
2298 (arguments
2299 (list
2300 ;; tests: 448 passed, 1 deselected, 3 xfailed
2301 #:test-flags
2302 #~(list (string-append "--deselect=tests/test_clean.py::"
2303 "test_self_closing_tags_self_close[wbr]"))
2304 #:phases
2305 #~(modify-phases %standard-phases
2306 (add-after 'unpack 'relax-requirements
2307 (lambda _
2308 ;; "tinycss2>=1.1.0,<1.5"
2309 ;; The 'sanity-check of python-nbclassic fails without this.
2310 (substitute* "setup.py"
2311 (("\"tinycss2.*") "")))))))
2312 (native-inputs
2313 (list python-pytest
2314 python-setuptools))
2315 (propagated-inputs
2316 (list python-html5lib
2317 python-tinycss2
2318 python-webencodings))
2319 (home-page "https://github.com/mozilla/bleach")
2320 (synopsis "Whitelist-based HTML-sanitizing tool")
2321 (description "Bleach is an easy whitelist-based HTML-sanitizing tool.")
2322 (license license:asl2.0)))
2323
2324(define-public python-bottle
2325 (package
2326 (name "python-bottle")
2327 (version "0.13.4")
2328 (source
2329 (origin
2330 (method url-fetch)
2331 (uri (pypi-uri "bottle" version))
2332 (sha256
2333 (base32 "0irz5i3h73pqz0ssgp3yk12zx33q7lrlh8p0in9jgchjgqr7hzkq"))))
2334 (build-system pyproject-build-system)
2335 (native-inputs (list python-pytest python-setuptools))
2336 (home-page "https://bottlepy.org/")
2337 (synopsis "WSGI framework for small web-applications")
2338 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
2339 (license license:expat)))
2340
2341(define-public python-branca
2342 (package
2343 (name "python-branca")
2344 (version "0.7.2")
2345 (source
2346 (origin
2347 (method git-fetch) ; no tests in PyPI
2348 (uri (git-reference
2349 (url "https://github.com/python-visualization/branca")
2350 (commit (string-append "v" version))))
2351 (file-name (git-file-name name version))
2352 (sha256
2353 (base32 "1vs94nqa7r6iwm8mj3m29hg090gmgz4ywnayxh8qiz9ij8jv96wa"))))
2354 (build-system pyproject-build-system)
2355 (arguments
2356 ;; This file requires Selenium.
2357 (list #:test-flags #~(list "--ignore" "tests/test_iframe.py"
2358 ;; This test passes but is very slow.
2359 "-k" "not test_color_brewer_extendability")))
2360 (propagated-inputs (list python-jinja2))
2361 (native-inputs
2362 (list python-numpy
2363 python-pytest
2364 python-setuptools
2365 python-setuptools-scm
2366 python-wheel))
2367 (home-page "https://github.com/python-visualization/branca")
2368 (synopsis "Generate complex HTML+JS pages with Python")
2369 (description "This library is a spinoff from @code{folium} that would host
2370the non-map-specific features. It can be used to generate HTML + JS.")
2371 (license license:expat)))
2372
2373(define-public python-btrees
2374 (package
2375 (name "python-btrees")
2376 (version "6.1")
2377 (source
2378 (origin
2379 (method git-fetch)
2380 (uri (git-reference
2381 (url "https://github.com/zopefoundation/BTrees")
2382 (commit version)))
2383 (file-name (git-file-name name version))
2384 (sha256
2385 (base32 "0vcibmd725ddgsl5yzmi8d403day3796h82xlq84w91xbdrbd5d5"))))
2386 (build-system pyproject-build-system)
2387 (arguments
2388 (list
2389 #:phases
2390 #~(modify-phases %standard-phases
2391 (replace 'check
2392 (lambda* (#:key tests? #:allow-other-keys)
2393 (if tests?
2394 (invoke "zope-testrunner" "--test-path=src")
2395 (format #t "test suite not run~%")))))))
2396 (propagated-inputs (list python-persistent python-zope-interface))
2397 (native-inputs (list python-persistent python-transaction
2398 python-zope-testrunner python-setuptools))
2399 (home-page "https://github.com/zopefoundation/BTrees")
2400 (synopsis "Scalable persistent object containers")
2401 (description
2402 "This package contains a set of persistent object containers built around a
2403modified BTree data structure. The trees are optimized for use inside ZODB's
2404\"optimistic concurrency\" paradigm, and include explicit resolution of
2405conflicts detected by that mechanism.")
2406 (license license:zpl2.1)))
2407
2408(define-public python-cachecontrol
2409 (package
2410 (name "python-cachecontrol")
2411 (version "0.14.1")
2412 (source
2413 (origin
2414 (method git-fetch)
2415 (uri (git-reference
2416 (url "https://github.com/ionrock/cachecontrol")
2417 (commit (string-append "v" version))))
2418 (file-name (git-file-name name version))
2419 (sha256
2420 (base32
2421 "07ifs4dhahhsgj4vxgfl5ymnmb4my5l2wb8jiinn6fncszcfmr59"))))
2422 (build-system pyproject-build-system)
2423 (propagated-inputs
2424 (list python-filelock python-msgpack python-requests))
2425 (native-inputs
2426 (list python-cherrypy python-flit-core python-pytest))
2427 (home-page "https://github.com/ionrock/cachecontrol")
2428 (synopsis "The httplib2 caching algorithms for use with requests")
2429 (description "CacheControl is a port of the caching algorithms in
2430@code{httplib2} for use with @code{requests} session objects.")
2431 (license license:asl2.0)))
2432
2433(define-public python-canvasapi
2434 (package
2435 (name "python-canvasapi")
2436 (version "3.4.0")
2437 (source (origin
2438 (method git-fetch)
2439 (uri (git-reference
2440 (url "https://github.com/ucfopen/canvasapi")
2441 (commit (string-append "v" version))))
2442 (file-name (git-file-name name version))
2443 (sha256
2444 (base32
2445 "017gashyd4avxzlz3imwn18vmfd0cjyhbm063isra3d2wk3ivrkx"))))
2446 (build-system pyproject-build-system)
2447 (propagated-inputs (list python-arrow python-pytz python-requests))
2448 (native-inputs (list python-pytest
2449 python-requests-mock
2450 python-setuptools
2451 python-urllib3))
2452 (home-page "https://github.com/ucfopen/canvasapi")
2453 (synopsis "API wrapper for the Canvas LMS")
2454 (description
2455 "CanvasAPI is a Python library for accessing Instructure’s Canvas LMS API.
2456The library enables developers to programmatically manage Canvas courses,
2457users, gradebooks, and more.")
2458 (license license:expat)))
2459
2460(define-public python-cbor2
2461 (package
2462 (name "python-cbor2")
2463 (version "5.4.2.post1")
2464 (source
2465 (origin
2466 (method url-fetch)
2467 (uri (pypi-uri "cbor2" version))
2468 (sha256
2469 (base32 "15y78xcc3zkmvj1mdzz8gyhf3apbl91073kwhzbjk5abc1civwlw"))))
2470 (build-system pyproject-build-system)
2471 (native-inputs
2472 (list python-pytest python-setuptools python-setuptools-scm))
2473 (home-page "https://github.com/agronholm/cbor2")
2474 (synopsis "Concise Binary Object Representation (CBOR) (de)serializer")
2475 (description "This Python library provides encoding and decoding for the
2476Concise Binary Object
2477Representation (CBOR) (@url{https://www.rfc-editor.org/rfc/rfc8949.html, RFC
24788949}) serialization format. The specification is fully compatible with the
2479original RFC 7049. Among its features are:
2480@itemize
2481@item Simple API like the @code{json} or @code{pickle} modules.
2482@item Support many CBOR tags with stdlib objects.
2483@item Generic tag decoding.
2484@item Shared value references including cyclic references.
2485@item String references compact encoding with repeated strings replaced with
2486indices.
2487@item Optional C module backend tested on big- and little-endian architectures.
2488@item Extensible tagged value handling using tag_hook and object_hook on
2489decode and default on encode.
2490@end itemize")
2491 (license license:expat)))
2492
2493(define-public python-cfn-lint
2494 (package
2495 (name "python-cfn-lint")
2496 (version "1.38.1")
2497 (source
2498 (origin
2499 (method git-fetch)
2500 (uri (git-reference
2501 (url "https://github.com/aws-cloudformation/cfn-lint")
2502 (commit (string-append "v" version))))
2503 (file-name (git-file-name name version))
2504 (sha256
2505 (base32 "1crwx0cp50h83xz8lc4ny504mx4dadpk80ln539syd4jd78qplgy"))))
2506 (build-system pyproject-build-system)
2507 (arguments
2508 (list
2509 ;; tests: 2136 passed, 11 deselected, 1 warning
2510 #:test-flags
2511 #~(list "--ignore=test/integration/"
2512 "-k" (string-join
2513 ;; Tests failing on doctest or comparing diff.
2514 (list "not test_build_graph"
2515 "test_good_template"
2516 "test_success_run"
2517 "test_update_docs"
2518 ;; ImportError: Missing optional dependencies sarif
2519 "test_sarif_formatter")
2520 " and not "))
2521 #:phases
2522 #~(modify-phases %standard-phases
2523 (add-after 'unpack 'remove-deprecated
2524 (lambda _
2525 (substitute* "src/cfnlint/data/AdditionalSpecs/LmbdRuntimeLifecycle.json"
2526 (("deprecated\": \"2025")
2527 "deprecated\": \"2125")))))))
2528 (native-inputs
2529 (list python-defusedxml
2530 python-pydot
2531 python-pytest
2532 python-setuptools))
2533 (propagated-inputs
2534 (list python-aws-sam-translator
2535 python-jsonpatch
2536 python-networkx
2537 python-pyyaml
2538 python-regex
2539 python-sympy
2540 python-typing-extensions
2541 ;; [optional]
2542 python-junit-xml))
2543 (home-page "https://github.com/aws-cloudformation/cfn-lint")
2544 (synopsis "Validate CloudFormation templates")
2545 (description
2546 "This package lets you validate CloudFormation YAML/JSON templates against
2547the CloudFormation spec and additional checks. Includes checking valid values
2548for resource properties and best practices.")
2549 (license license:expat)))
2550
2551(define-public python-chalice
2552 (package
2553 (name "python-chalice")
2554 (version "1.33.0")
2555 (source
2556 (origin
2557 (method git-fetch)
2558 (uri (git-reference
2559 (url "https://github.com/aws/chalice")
2560 (commit version)))
2561 (file-name (git-file-name name version))
2562 (sha256
2563 (base32 "06vmwjhksb3nck1wpf7dj9hfnvl45fzzrpy9h1pij5aipj17773k"))))
2564 (build-system pyproject-build-system)
2565 (arguments
2566 (list
2567 ;; tests: 1387 passed, 16 skipped, 1 deselected, 29 warnings
2568 #:test-flags
2569 #~(list "--ignore=chalice/templates"
2570 "--ignore=docs/source/samples/todo-app/code/tests/test_db.py"
2571 ;; Network access and extra credentials are required.
2572 "--ignore=tests/aws/test_features.py"
2573 "--ignore=tests/aws/test_websockets.py"
2574 "--ignore=tests/integration/test_package.py"
2575 (string-append "--deselect=tests/functional/test_awsclient.py"
2576 "::TestUpdateDomainName"
2577 "::test_update_domain_name_failed"))))
2578 (native-inputs
2579 (list python-boto3
2580 python-pytest
2581 python-requests
2582 python-setuptools
2583 python-websocket-client))
2584 (propagated-inputs
2585 (list python-botocore
2586 python-click
2587 python-inquirer ;XXX: move to (gnu packages python-xyz)
2588 python-jmespath
2589 python-pip ;hard dependency
2590 python-pyyaml
2591 python-six)) ;hard dependency
2592 (home-page "https://github.com/aws/chalice")
2593 (synopsis "Python Serverless Microframework")
2594 (description
2595 "Chalice is a Python framework for building serverless applications with
2596AWS Lambda service, enabling quick prototyping and deployment.")
2597 (license license:asl2.0)))
2598
2599(define-public python-cheroot
2600 (package
2601 (name "python-cheroot")
2602 (version "11.1.2")
2603 (source
2604 (origin
2605 (method git-fetch)
2606 (uri (git-reference
2607 (url "https://github.com/cherrypy/cheroot")
2608 (commit (string-append "v" version))))
2609 (file-name (git-file-name name version))
2610 (sha256
2611 (base32 "02rhci01m5fcn8mqpvq3c35rs4n28gxlfvfw2if2f85rgwrji8y8"))
2612 ;; TODO: Remove this patch on next release.
2613 (patches (search-patches "python-cheroot-openssl-test.patch"))))
2614 (build-system pyproject-build-system)
2615 (arguments
2616 (list
2617 ;; tests: 150 passed, 3 xfailed, 7 warnings
2618 #:test-flags
2619 ;; To prevent dependency on python-pypytools which depends on python-py
2620 ;; both marked as deprecated by maintainers, see:
2621 ;; <https://codeberg.org/guix/guix/issues/7475>.
2622 #~(list "--ignore=cheroot/test/test_server.py")
2623 #:phases
2624 #~(modify-phases %standard-phases
2625 (add-after 'unpack 'fix-pytest-config
2626 (lambda _
2627 ;; See: <https://codeberg.org/guix/guix/issues/7476>.
2628 (delete-file "pytest.ini"))))))
2629 (native-inputs
2630 (list python-portend
2631 python-pyopenssl
2632 python-pytest
2633 python-pytest-mock
2634 python-requests
2635 python-requests-toolbelt
2636 python-setuptools
2637 python-setuptools-scm
2638 python-trustme))
2639 (propagated-inputs
2640 (list python-jaraco-functools
2641 python-more-itertools))
2642 (home-page "https://cheroot.cherrypy.dev")
2643 (synopsis "Highly-optimized, pure-python HTTP server")
2644 (description
2645 "Cheroot is a high-performance, pure-Python HTTP server.")
2646 (license license:bsd-3)))
2647
2648(define-public python-cherrypy
2649 (package
2650 (name "python-cherrypy")
2651 (properties '((commit . "1f75bc9eed8e0e385f64f368bd69f58d96fb8c2b")
2652 (revision . "0")))
2653 (version (git-version "18.10.0"
2654 (assoc-ref properties 'revision)
2655 (assoc-ref properties 'commit)))
2656 (source
2657 (origin
2658 (method git-fetch)
2659 (uri (git-reference
2660 (url "https://github.com/cherrypy/cherrypy")
2661 (commit (assoc-ref properties 'commit))))
2662 (file-name (git-file-name name version))
2663 (sha256
2664 (base32 "1l01a4sbfm42s5xp6ngphgqf0yb65ksqbsb27kznvybblyaxfa9p"))))
2665 (build-system pyproject-build-system)
2666 (arguments
2667 (list
2668 ;; tests: 288 passed, 9 skipped, 1 xfailed, 2 xpassed, 15 warnings
2669 #:phases
2670 #~(modify-phases %standard-phases
2671 (add-after 'unpack 'fix-pytest-config
2672 (lambda _
2673 ;; See: <https://codeberg.org/guix/guix/issues/7476>.
2674 (delete-file "pytest.ini")))
2675 (add-after 'unpack 'patch-pyproject
2676 (lambda _
2677 (substitute* "pyproject.toml"
2678 (("\"cherrypy.scaffold\",")
2679 (string-join
2680 (list "\"cherrypy.scaffold\""
2681 "\"cherrypy._private_api\""
2682 "\"cherrypy._private_api.compat\",")
2683 ",\n "))))))))
2684 (propagated-inputs
2685 (list python-cheroot
2686 python-filelock
2687 python-jaraco-collections
2688 python-more-itertools
2689 python-portend))
2690 (native-inputs
2691 (list python-path
2692 python-pytest
2693 python-pytest-services
2694 python-requests
2695 python-requests-toolbelt
2696 python-setuptools
2697 python-setuptools-scm))
2698 (home-page "https://www.cherrypy.dev")
2699 (synopsis "Object-Oriented HTTP framework")
2700 (description
2701 "CherryPy is a pythonic, object-oriented web framework. It helps in
2702building web applications in the same way any other object-oriented Python
2703program would be built.")
2704 (license license:bsd-3)))
2705
2706(define-public python-cloud-init
2707 (package
2708 (name "python-cloud-init")
2709 (version "24.2")
2710 (source
2711 (origin
2712 (method git-fetch)
2713 (uri (git-reference
2714 (url "https://github.com/canonical/cloud-init")
2715 (commit version)))
2716 (file-name (git-file-name name version))
2717 (sha256
2718 (base32 "18872z2y9wkh558y1bx5r0rksb4i584jbc8z4g8marwawhwxq506"))))
2719 (build-system pyproject-build-system)
2720 (arguments
2721 (list
2722 #:test-flags
2723 '(list
2724 ;; This requires usermod
2725 "--ignore=tests/unittests/distros/test_create_users.py"
2726 ;; This writes to /var
2727 "--ignore=tests/unittests/net/test_dhcp.py"
2728 "-k"
2729 (string-append
2730 ;; This test messes with PATH, so it cannot find mkdir
2731 "not test_path_env_gets_set_from_main"
2732 " and not test_apt_configure_sources_list_"
2733 ;; These all fail because /bin/sh doesn't exist. We cannot patch
2734 ;; this because the generated scripts must use /bin/sh as they are
2735 ;; supposed to be run on minimal systems.
2736 " and not test_handler_creates_and_runs_bootcmd_script_with_instance_id"
2737 " and not test_handler_runs_bootcmd_script_with_error"
2738 " and not test_subp_combined_stderr_stdout"
2739 " and not test_handle_part"))
2740 #:phases
2741 #~(modify-phases %standard-phases
2742 (add-after 'unpack 'patch-references
2743 (lambda _
2744 (substitute* "tests/unittests/cmd/test_clean.py"
2745 (("#!/bin/sh") (string-append "#!" (which "sh"))))))
2746 (add-after 'install 'move-files
2747 (lambda* (#:key inputs outputs #:allow-other-keys)
2748 (for-each (lambda (dir)
2749 (let ((source (string-append (site-packages inputs outputs) "/" dir))
2750 (target (string-append #$output "/" (basename dir))))
2751 (copy-recursively source target)
2752 (delete-file-recursively source)))
2753 (list "etc" "lib" "usr/lib" "usr/share")))))))
2754 (propagated-inputs
2755 (list python-configobj
2756 python-jinja2
2757 python-jsonpatch
2758 python-jsonschema
2759 python-netifaces
2760 python-oauthlib
2761 python-pyserial
2762 python-pyyaml
2763 python-responses))
2764 (native-inputs
2765 (list procps ;for ps when running tests
2766 python-pytest
2767 python-pytest-mock
2768 python-passlib
2769 python-setuptools
2770 python-wheel))
2771 (home-page "https://github.com/canonical/cloud-init")
2772 (synopsis "Cloud instance initialization tools")
2773 (description
2774 "Cloud-init is the multi-distribution method for cross-platform cloud
2775instance initialization. It is supported across all major public cloud
2776providers, provisioning systems for private cloud infrastructure, and
2777bare-metal installations.")
2778 ;; Either license can be chosen
2779 (license (list license:asl2.0 license:gpl3))))
2780
2781(define-public python-cloudpathlib
2782 (package
2783 (name "python-cloudpathlib")
2784 (version "0.23.0")
2785 (source
2786 (origin
2787 (method git-fetch)
2788 (uri (git-reference
2789 (url "https://github.com/drivendataorg/cloudpathlib")
2790 (commit (string-append "v" version))))
2791 (file-name (git-file-name name version))
2792 (sha256
2793 (base32 "1dqwml269lpz51drgg3s27sqmvwa1vldw2rj34ssnqppcmc5h5lm"))))
2794 (build-system pyproject-build-system)
2795 (arguments
2796 (list
2797 ;; tests: 977 passed, 15 skipped, 8642 warnings
2798 #:test-flags
2799 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
2800 ;; TODO: Package azure-identity (required for this file)
2801 "--ignore=tests/test_azure_specific.py"
2802 ;; TypeError: Retry.__init__() got an unexpected keyword
2803 ;; argument 'timeout'
2804 "--deselect=tests/test_gs_specific.py::test_timeout_and_retry")))
2805 (native-inputs
2806 (list ;; python-azure-identity
2807 python-dotenv
2808 python-flit-core
2809 python-psutil
2810 python-pydantic
2811 python-pytest
2812 python-pytest-cases
2813 python-pytest-reportlog
2814 python-pytest-xdist
2815 python-shortuuid
2816 python-tenacity))
2817 (propagated-inputs
2818 (list python-azure-storage-blob
2819 python-azure-storage-file-datalake
2820 python-boto3
2821 python-google-cloud-storage
2822 python-typing-extensions))
2823 (home-page "https://github.com/drivendataorg/cloudpathlib")
2824 (synopsis "Pathlib-style classes for cloud storage services")
2825 (description
2826 "This package provides a Python library with classes that mimic
2827@code{pathlib.Path}'s interface for URIs from different cloud storage
2828services.")
2829 (license license:expat)))
2830
2831(define-public python-cloudscraper
2832 (package
2833 (name "python-cloudscraper")
2834 (version "3.0.0")
2835 (source
2836 (origin
2837 (method git-fetch)
2838 (uri (git-reference
2839 (url "https://github.com/VeNoMouS/cloudscraper")
2840 (commit version)))
2841 (file-name (git-file-name name version))
2842 (sha256
2843 (base32 "13w0ywz2y8x0zwpwzrnn46wyq307hfpdcz49zy33yyf46rq9n10n"))
2844 (modules '((guix build utils)))
2845 (snippet
2846 '(with-directory-excursion "cloudscraper"
2847 (for-each delete-file
2848 '("captcha/9kw.py" "captcha/anticaptcha.py"))
2849 (substitute* "__init__.py"
2850 ;; Perhaps it's a joke, but don't promote proprietary software.
2851 (("([Th]is feature is not available) in the .*'" _ prefix)
2852 (string-append prefix ".'")))))))
2853 (build-system pyproject-build-system)
2854 (arguments
2855 (list
2856 #:test-flags
2857 #~(list "-k" "not test_403_handling")
2858 #:phases
2859 #~(modify-phases %standard-phases
2860 (add-after 'unpack 'relax-requirements
2861 (lambda _
2862 ;; XXX: Relax brotli dependency.
2863 (substitute* "pyproject.toml"
2864 (("\"brotli>=.*\"")
2865 "\"brotli\""))
2866 ;; XXX: Dependencies, that have not yet been packaged
2867 ;; and cause an import error when included.
2868 (delete-file "cloudscraper/interpreters/v8.py")))
2869 (add-after 'unpack 'fix-references
2870 (lambda _
2871 (substitute* "cloudscraper/interpreters/nodejs.py"
2872 (("'node'")
2873 (string-append "'" (which "node") "'"))))))))
2874 (inputs (list node-lts))
2875 (propagated-inputs
2876 (list python-pycryptodome
2877 python-brotli
2878 python-js2py
2879 python-polling2
2880 python-requests
2881 python-requests-toolbelt
2882 python-responses
2883 python-pyparsing
2884 python-websocket-client))
2885 (native-inputs (list python-pytest python-setuptools))
2886 (home-page "https://github.com/venomous/cloudscraper")
2887 (synopsis "Cloudflare anti-bot bypass")
2888 (description
2889 "This module acts as a webbrowser solving Cloudflare's Javascript
2890challenges.")
2891 (license license:expat)))
2892
2893(define-public python-conda-package-handling
2894 (package
2895 (name "python-conda-package-handling")
2896 (version "2.4.0")
2897 (source
2898 (origin
2899 (method git-fetch)
2900 (uri (git-reference
2901 (url "https://github.com/conda/conda-package-handling/")
2902 (commit version)))
2903 (file-name (git-file-name name version))
2904 (sha256
2905 (base32 "1l2zbbwlxp9azpshixvxnb9354xajxkn88934grpwl70blgb3yq2"))))
2906 (build-system pyproject-build-system)
2907 (native-inputs
2908 (list python-bottle
2909 python-mock
2910 python-pytest-8
2911 python-pytest-mock
2912 python-setuptools))
2913 (propagated-inputs
2914 (list python-conda-package-streaming))
2915 (home-page "https://conda.io")
2916 (synopsis "Create and extract conda packages of various formats")
2917 (description
2918 "This library is an abstraction of Conda package handling and a tool for
2919extracting, creating, and converting between formats.")
2920 (license license:bsd-3)))
2921
2922(define-public python-conda-package-streaming
2923 (package
2924 (name "python-conda-package-streaming")
2925 (version "0.12.0")
2926 (source
2927 (origin
2928 (method url-fetch)
2929 (uri (pypi-uri "conda_package_streaming" version))
2930 (sha256
2931 (base32 "1fcyx83swx1wfndrl0vdk8c2pixshn54gkjy7xchkra13kw2yas2"))))
2932 (build-system pyproject-build-system)
2933 (arguments
2934 ;; TODO: Cycles with python-conda-package-handling, implement bootstrap.
2935 (list #:tests? #f))
2936 (native-inputs
2937 (list python-flit-core))
2938 (propagated-inputs
2939 (list python-requests
2940 python-zstandard))
2941 (home-page "https://conda.github.io/conda-package-streaming/")
2942 (synopsis "Conda formats (@code{.conda}, @code{.tar.bz2}) reader library")
2943 (description
2944 "This package provides an efficient library to read from new and old format
2945@code{.conda} and @code{.tar.bz2} conda packages.")
2946 (license license:bsd-3)))
2947
2948(define-public python-cross-web
2949 (package
2950 (name "python-cross-web")
2951 (version "0.7.0")
2952 (source
2953 (origin
2954 (method git-fetch)
2955 (uri (git-reference
2956 (url "https://github.com/usecross/cross-web")
2957 (commit version)))
2958 (file-name (git-file-name name version))
2959 (sha256
2960 (base32 "1yx0ii08cjnp311dq7336v02g501ap39kbfh2h62933v9m6k6717"))))
2961 (build-system pyproject-build-system)
2962 (arguments
2963 (list
2964 ;; tests: 114 passed, 1 skipped, 2 deselected
2965 #:test-flags
2966 ;; Tests fail with deprecation on Litestar side.
2967 #~(list (string-append
2968 "--deselect=tests/testing/"
2969 "clients/test_http_clients.py"
2970 "::test_request_adapter_json[http_client_config6]")
2971 (string-append
2972 "--deselect=tests/testing/clients/"
2973 "test_http_clients.py"
2974 "::test_request_adapter_form_data[http_client_config6]"))))
2975 (native-inputs
2976 (list python-django
2977 python-hatchling
2978 python-pytest
2979 python-pytest-asyncio
2980 python-pytest-django
2981 python-sanic-testing))
2982 (propagated-inputs
2983 (list python-typing-extensions
2984 ;; [optional]
2985 python-aiohttp
2986 python-chalice
2987 python-fastapi
2988 python-flask
2989 python-httpx
2990 python-litestar
2991 python-multipart ;PyPI python-mulipart
2992 python-quart
2993 python-sanic
2994 python-starlette
2995 python-werkzeug
2996 python-yarl))
2997 (home-page "https://github.com/usecross/cross-web")
2998 (synopsis "Library for working with web frameworks")
2999 (description
3000 "Cross provides a unified interface for common Python web framework
3001operations,allowing you to write framework-agnostic code that can be easily
3002adapted to work with FastAPI, Flask, Django, and other popular Python web
3003frameworks.")
3004 (license license:expat)))
3005
3006;; A bare minimal package to prevent pulling all bulky Web frameworks at once.
3007(define-public python-cross-web-minimal
3008 (package/inherit python-cross-web
3009 (name "python-cross-web-minimal")
3010 (arguments (list #:tests? #f))
3011 (native-inputs (list python-hatchling))
3012 (propagated-inputs (list python-typing-extensions))))
3013
3014(define-public python-css-html-js-minify
3015 (let ((commit "8f72452960e41bc5476e50d96481f633eff72750")
3016 (revision "0"))
3017 (package
3018 (name "python-css-html-js-minify")
3019 (version (git-version "2.5.5" revision commit))
3020 (source
3021 (origin
3022 (method git-fetch)
3023 (uri (git-reference
3024 (url "https://github.com/juancarlospaco/css-html-js-minify")
3025 (commit commit)))
3026 (file-name (git-file-name name version))
3027 (sha256
3028 (base32 "1lkx03720zk6q16w3d9r3l5kryikd1cmzwrcjzsjxwrq4zfh6vdf"))))
3029 (build-system pyproject-build-system)
3030 (arguments
3031 (list
3032 #:phases
3033 #~(modify-phases %standard-phases
3034 (add-after 'unpack 'relax-requirements
3035 (lambda _
3036 (substitute* "setup.cfg"
3037 (("^tests_require.*") "")))))))
3038 (native-inputs (list python-pytest python-setuptools))
3039 (home-page "https://github.com/juancarlospaco/css-html-js-minify")
3040 (synopsis "CSS/HTML/JS minifier")
3041 (description
3042 "This package provides a single-file minifier for CSS, HTML, and JavaScript.")
3043 ;; XXX: The README just says "GNU GPL and GNU LGPL and MIT". From
3044 ;; <https://github.com/juancarlospaco/css-html-js-minify/issues/9> it
3045 ;; looks like the user can choose a license.
3046 (license (list license:gpl3+ license:lgpl3+ license:expat)))))
3047
3048(define-public python-css-parser
3049 (package
3050 (name "python-css-parser")
3051 (version "1.1.1")
3052 (source
3053 (origin
3054 (method git-fetch)
3055 (uri (git-reference
3056 (url "https://github.com/ebook-utils/css-parser")
3057 (commit (string-append "v" version))))
3058 (file-name (git-file-name name version))
3059 (sha256
3060 (base32 "0514g5a0r972lm883b3aja3b8jsxywmhxn4xpx7ksjpqmx38wga4"))))
3061 (build-system pyproject-build-system)
3062 (native-inputs
3063 (list python-pytest
3064 python-setuptools))
3065 (home-page "https://github.com/ebook-utils/css-parser")
3066 (synopsis "CSS related utilities for Python")
3067 (description
3068 "Css-parser is a Python package for parsing and building CSS
3069Cascading Style Sheets. Currently it provides a DOM only and no rendering
3070options.
3071
3072It's a fork of cssutils 1.0.2, updated and modified for parsing ebooks, due to
3073cssutils not receiving updates as of 1.0.2.")
3074 (license license:lgpl3+)))
3075
3076(define-public python-cssmin
3077 (package
3078 (name "python-cssmin")
3079 (version "0.2.0")
3080 (source
3081 (origin
3082 (method git-fetch)
3083 (uri (git-reference
3084 (url "https://github.com/zacharyvoase/cssmin")
3085 (commit (string-append "v" version))))
3086 (file-name (git-file-name name version))
3087 (sha256
3088 (base32 "04bzpal6j26pjjjf3p7iq6g2wcr61j4g0ygqz6h847h4hsyah9qg"))))
3089 (build-system pyproject-build-system)
3090 (arguments (list #:tests? #f)) ; No tests.
3091 (native-inputs (list python-setuptools))
3092 (home-page "https://github.com/zacharyvoase/cssmin")
3093 (synopsis "Python port of the YUI CSS Compressor")
3094 (description "Python port of the YUI CSS Compressor.")
3095 (license (list license:expat license:bsd-3))))
3096
3097(define-public python-cssselect
3098 (package
3099 (name "python-cssselect")
3100 (version "1.4.0")
3101 (source
3102 (origin
3103 (method git-fetch)
3104 (uri (git-reference
3105 (url "https://github.com/scrapy/cssselect")
3106 (commit (string-append "v" version))))
3107 (file-name (git-file-name name version))
3108 (sha256
3109 (base32 "110l98x1mz1mxcal89xscsg28vg624sc0y6b5x1n2clwa19q5g4y"))))
3110 (build-system pyproject-build-system)
3111 (native-inputs
3112 (list python-hatchling python-lxml python-pytest))
3113 (home-page "https://github.com/scrapy/cssselect")
3114 (synopsis "CSS3 selector parser and translator to XPath 1.0")
3115 (description
3116 "Cssselect ia a Python module that parses CSS3 Selectors and translates
3117them to XPath 1.0 expressions. Such expressions can be used in lxml or
3118another XPath engine to find the matching elements in an XML or HTML document.")
3119 (license license:bsd-3)))
3120
3121(define-public python-cssselect2
3122 (package
3123 (name "python-cssselect2")
3124 (version "0.9.0")
3125 (source
3126 (origin
3127 (method git-fetch)
3128 (uri (git-reference
3129 (url "https://github.com/Kozea/cssselect2")
3130 (commit version)))
3131 (file-name (git-file-name name version))
3132 (sha256
3133 (base32 "1drvb83siq9s6dygyhab6kzk2v2ib6cv51ls42p4jrxs9q8cdiw0"))))
3134 (build-system pyproject-build-system)
3135 (propagated-inputs
3136 (list python-tinycss2))
3137 (native-inputs
3138 (list python-flit-core
3139 python-pytest))
3140 (home-page "https://doc.courtbouillon.org/cssselect2/stable/")
3141 (synopsis "CSS selectors for Python ElementTree")
3142 (description "@code{cssselect2} is a straightforward implementation of
3143CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
3144ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
3145
3146Unlike the Python package @code{cssselect}, it does not translate selectors to
3147XPath and therefore does not have all the correctness corner cases that are
3148hard or impossible to fix in cssselect.")
3149 (license license:bsd-3)))
3150
3151(define-public python-cssutils
3152 (package
3153 (name "python-cssutils")
3154 (version "2.15.0")
3155 (source
3156 (origin
3157 (method url-fetch)
3158 (uri (pypi-uri "cssutils" version))
3159 (sha256
3160 (base32 "08fhyw7x88xzhphm6jc6v72kw3i8iysw91x7rgd3fl4iycvr4wz9"))))
3161 (build-system pyproject-build-system)
3162 (arguments
3163 (list
3164 ;; tests: 399 passed, 2 skipped, 43 xfailed
3165 #:test-flags
3166 ;; Examples try to access http://cthedot.de/not-present.css.
3167 #~(list "--ignore=examples/")))
3168 (native-inputs
3169 (list python-cssselect
3170 python-jaraco-test
3171 python-pytest
3172 python-setuptools))
3173 (propagated-inputs
3174 (list python-encutils python-more-itertools))
3175 (home-page "https://github.com/jaraco/cssutils")
3176 (synopsis "CSS Cascading Style Sheets library for Python")
3177 (description
3178 "Cssutils is a Python package for parsing and building CSS Cascading
3179Style Sheets. Currently it provides a DOM only and no rendering options.")
3180 (license license:lgpl3+)))
3181
3182(define-public python-databricks-cli
3183 (package
3184 (name "python-databricks-cli")
3185 (version "0.18.0")
3186 (home-page "https://github.com/databricks/databricks-cli")
3187 (source (origin
3188 (method git-fetch)
3189 (uri (git-reference (url home-page) (commit version)))
3190 (file-name (git-file-name name version))
3191 (sha256
3192 (base32
3193 "1avag4kwqk2f24r5i0vcmhm6s1gsw6maykhlyj2ixz0qc05pjzvl"))))
3194 (build-system pyproject-build-system)
3195 (arguments
3196 (list #:phases #~(modify-phases %standard-phases
3197 (replace 'check
3198 (lambda _
3199 (invoke "pytest" "tests" "-vv"))))))
3200 (native-inputs
3201 ;; For tests.
3202 (list python-decorator
3203 python-mock
3204 python-pytest
3205 python-requests-mock
3206 python-setuptools
3207 python-wheel))
3208 (propagated-inputs
3209 (list python-click
3210 python-oauthlib
3211 python-pyjwt
3212 python-requests
3213 python-six
3214 python-tabulate))
3215 (synopsis "Command line interface for Databricks")
3216 (description
3217 "The Databricks Command Line Interface is a tool which provides an easy
3218to use interface to the Databricks platform. The CLI is built on top of the
3219Databricks REST APIs.")
3220 (license license:asl2.0)))
3221
3222(define-public python-dependency-groups
3223 (package
3224 (name "python-dependency-groups")
3225 (version "1.3.1")
3226 (source
3227 (origin
3228 (method url-fetch)
3229 (uri (pypi-uri "dependency_groups" version))
3230 (sha256
3231 (base32 "1zgymnk6k984h2wfdpp0vws2ihwqrr9lmxhrij9zs5q5140q61vq"))))
3232 (build-system pyproject-build-system)
3233 (propagated-inputs (list python-packaging python-tomli))
3234 (native-inputs (list python-flit-core python-pytest))
3235 (home-page "https://dependency-groups.readthedocs.io/")
3236 (synopsis "Tools and library for resolving PEP 735 Dependency Group data")
3237 (description
3238 "This package provides a library which is able to parse dependency groups (PEP
3239735), following includes, and provide that data as output.")
3240 (license license:expat)))
3241
3242(define-public python-devpi-client
3243 (package
3244 (name "python-devpi-client")
3245 (version "7.2.0")
3246 (source
3247 (origin
3248 (method url-fetch)
3249 (uri (pypi-uri "devpi-client" version))
3250 (sha256
3251 (base32 "0ywx4ql8lsypb17n2miq39bmkrp232sdk8g6pskqp1y3b223chy1"))))
3252 (build-system pyproject-build-system)
3253 (arguments
3254 (list
3255 #:test-flags
3256 ;; This wants to use pip install
3257 '(list "--ignore=testing/test_upload.py"
3258 ;; These complain about finding distutils. It's not my fault,
3259 ;; mate, setuptools is right there, but you won't pick it!
3260 "--ignore=testing/test_list_remove.py"
3261 "--ignore=testing/test_main.py"
3262 "--ignore=testing/test_install.py"
3263 "--ignore=testing/test_functional.py"
3264 "--ignore=testing/test_test.py")
3265 #:phases
3266 '(modify-phases %standard-phases
3267 (add-after 'unpack 'patch-tests
3268 (lambda _
3269 ;; Do not replace the directory name of the store item.
3270 (substitute* "testing/conftest.py"
3271 (("\"devpi-server\", \"devpi-init\"")
3272 "\"/bin/devpi-server\", \"/bin/devpi-init\""))))
3273 (add-before 'check 'set-HOME
3274 ;; Some tests need this
3275 (lambda _ (setenv "HOME" "/tmp"))))))
3276 (propagated-inputs (list python-pypa-build
3277 python-check-manifest
3278 python-colorama
3279 python-devpi-common
3280 python-iniconfig
3281 python-pkginfo
3282 python-platformdirs
3283 python-pluggy
3284 python-pypitoken
3285 python-tomli))
3286 (native-inputs
3287 (list python-devpi-server
3288 python-pytest
3289 python-setuptools
3290 python-virtualenv))
3291 (home-page "https://github.com/devpi/devpi")
3292 (synopsis "Devpi upload/install/... commands for Python developers")
3293 (description
3294 "The devpi command line tool is typically used in conjunction with
3295devpi-server. It allows uploading, testing and installing packages from devpi
3296indexes.")
3297 (license license:expat)))
3298
3299(define-public python-devpi-common
3300 (package
3301 (name "python-devpi-common")
3302 (version "4.0.4")
3303 (source
3304 (origin
3305 (method url-fetch)
3306 (uri (pypi-uri "devpi_common" version))
3307 (sha256
3308 (base32 "1k217b0fvsc7k2afw6wwlvqr1ksnv1vjzfm61g358vn98nd0lni3"))))
3309 (build-system pyproject-build-system)
3310 (propagated-inputs (list python-lazy python-packaging-legacy
3311 python-requests))
3312 (native-inputs
3313 (list python-pytest
3314 python-setuptools
3315 python-wheel))
3316 (home-page "https://github.com/devpi/devpi")
3317 (synopsis
3318 "Utilities jointly used by devpi-server, devpi-client and others")
3319 (description
3320 "This package provides utilities jointly used by devpi-server,
3321devpi-client and others.")
3322 (license license:expat)))
3323
3324(define-public python-devpi-process
3325 (package
3326 (name "python-devpi-process")
3327 (version "1.0.2")
3328 (source
3329 (origin
3330 (method url-fetch)
3331 (uri (pypi-uri "devpi_process" version))
3332 (sha256
3333 (base32 "0v26i8bs0n8f2ikizwyvq77fw3l0nsyl4wj8yff0r3y351ydqbs1"))))
3334 (build-system pyproject-build-system)
3335 (arguments
3336 (list
3337 #:phases
3338 '(modify-phases %standard-phases
3339 (add-after 'unpack 'relax-requirements
3340 (lambda _
3341 ;; Our package is too old, sorry.
3342 (substitute* "pyproject.toml"
3343 (("typing-extensions>=4.12.2")
3344 "typing-extensions>=4.10.0"))))
3345 (add-after 'unpack 'patch-tool-locations
3346 (lambda* (#:key inputs #:allow-other-keys)
3347 (substitute* "src/devpi_process/__init__.py"
3348 (("_exe\\(\"devpi-init\"\\)")
3349 (string-append "\"" (search-input-file inputs "/bin/devpi-init") "\""))
3350 (("_exe\\(\"devpi-server\"\\)")
3351 (string-append "\"" (search-input-file inputs "/bin/devpi-server") "\""))
3352 (("_exe\\(\"devpi\"\\)")
3353 (string-append "\"" (search-input-file inputs "/bin/devpi") "\""))))))))
3354 (propagated-inputs (list python-devpi-client python-devpi-server
3355 python-typing-extensions))
3356 (native-inputs
3357 (list nss-certs-for-test
3358 python-hatchling
3359 python-hatch-vcs
3360 python-httpx
3361 python-pytest))
3362 (home-page "https://github.com/devpi/devpi")
3363 (synopsis "API to create and use a devpi server process")
3364 (description
3365 "This package provides a programmatic API to create and use a devpi
3366server process.")
3367 (license license:expat)))
3368
3369(define-public python-devpi-server
3370 (package
3371 (name "python-devpi-server")
3372 (version "6.20.3")
3373 (source
3374 (origin
3375 (method git-fetch)
3376 (uri (git-reference
3377 (url "https://github.com/devpi/devpi")
3378 (commit (string-append "server-" version))))
3379 (file-name (git-file-name name version))
3380 (sha256
3381 (base32 "11q1bnd8rl55gcv99xkmg10i8z9l91kvmgrvcz1803mwkcs0isp8"))))
3382 (build-system pyproject-build-system)
3383 (arguments
3384 (list
3385 ;; tests: 1134 passed, 53 skipped, 29 warnings
3386 #:phases
3387 #~(modify-phases %standard-phases
3388 (add-after 'unpack 'chdir
3389 (lambda _
3390 (chdir "server")))
3391 (add-after 'chdir 'relax-requirements
3392 (lambda _
3393 (substitute* "pyproject.toml"
3394 ;; It straggles to check argon2 in passlib on any versions
3395 ;; starting from 6.14.0: UnknownExtra("passlib 1.7.4 has no
3396 ;; such extra feature 'argon2'",).
3397 (("passlib\\[argon2\\]") "passlib")
3398 (("\"py>=1.4.23\",") ""))))
3399 (add-before 'check 'pre-check
3400 (lambda _
3401 (setenv "HOME" "/tmp"))))))
3402 (propagated-inputs (list python-argon2-cffi
3403 python-attrs
3404 python-defusedxml
3405 python-devpi-common
3406 python-httpx
3407 python-itsdangerous
3408 python-lazy
3409 python-passlib
3410 python-platformdirs
3411 python-pluggy
3412 python-pyramid
3413 python-repoze-lru
3414 python-requests
3415 python-ruamel.yaml-0.16 ;FIXME: rename
3416 python-strictyaml
3417 python-waitress))
3418 (native-inputs
3419 (list nss-certs-for-test
3420 python-execnet
3421 python-pytest
3422 python-pytest-asyncio
3423 python-pytest-timeout
3424 python-setuptools
3425 python-webtest))
3426 (home-page "https://devpi.net")
3427 (synopsis "Pypi.org caching server")
3428 (description "This package implements a reliable private and pypi.org
3429caching server.")
3430 (license license:expat)))
3431
3432(define-public python-dicomweb-client
3433 (package
3434 (name "python-dicomweb-client")
3435 (version "0.60.0")
3436 (source
3437 (origin
3438 (method git-fetch)
3439 (uri (git-reference
3440 (url "https://github.com/ImagingDataCommons/dicomweb-client")
3441 (commit (string-append "v" version))))
3442 (file-name (git-file-name name version))
3443 (sha256
3444 (base32 "1zad0905cc4jy4hnh9yhcw63bg25f7xa33x9rj9fhh5r4fznha8d"))))
3445 (build-system pyproject-build-system)
3446 (arguments
3447 (list
3448 #:phases
3449 #~(modify-phases %standard-phases
3450 (add-after 'unpack 'remove-dynamic-versioning
3451 (lambda _
3452 (substitute* "pyproject.toml"
3453 ;; Dynamic versioning via 'uv-dynamic-versioning' is
3454 ;; not suitable for Guix.
3455 (("dynamic = \\[\"version\"\\]")
3456 (string-append "version = \""
3457 #$version "\""))))))))
3458 (native-inputs
3459 (list python-hatchling
3460 python-pytest
3461 python-pytest-localserver))
3462 (propagated-inputs
3463 (list python-numpy
3464 python-pillow
3465 python-pydicom
3466 python-requests
3467 python-retrying))
3468 (home-page "https://github.com/ImagingDataCommons/dicomweb-client")
3469 (synopsis "Python client for DICOMweb RESTful services")
3470 (description
3471 "@code{dicomweb_client} provides client interfaces for DICOMweb RESTful
3472services QIDO-RS, WADO-RS and STOW-RS to search, retrieve and store
3473DICOM objects over the web, respectively.")
3474 (license license:expat)))
3475
3476(define-public python-dnslib
3477 (package
3478 (name "python-dnslib")
3479 (version "0.9.26")
3480 (source
3481 (origin
3482 (method git-fetch)
3483 (uri (git-reference
3484 (url "https://github.com/paulc/dnslib")
3485 (commit version)))
3486 (file-name (git-file-name name version))
3487 (sha256
3488 (base32 "1x1l727qx6x0kw7yhzhxhbm40wgrh367dr3y0vaix0wrhi30qsyk"))))
3489 (build-system pyproject-build-system)
3490 (arguments
3491 (list
3492 #:phases
3493 #~(modify-phases %standard-phases
3494 (replace 'check
3495 (lambda* (#:key tests? #:allow-other-keys)
3496 (when tests?
3497 (invoke "./run_tests.sh")))))))
3498 (native-inputs
3499 (list python-setuptools))
3500 (home-page "https://github.com/paulc/dnslib")
3501 (synopsis "Library to encode/decode DNS wire-format packets")
3502 (description
3503 "This package provides a simple Python library to encode/decode DNS
3504wire-format packets.")
3505 (license license:bsd-3)))
3506
3507(define-public python-docusign-esign
3508 (package
3509 (name "python-docusign-esign")
3510 (version "5.0.0")
3511 (source
3512 (origin
3513 (method url-fetch)
3514 (uri (pypi-uri "docusign-esign" version))
3515 (sha256
3516 (base32 "18n9szjxbmsccz4vlvsl4xa73jn0y16l0c344m83gil25v2amn69"))))
3517 (build-system pyproject-build-system)
3518 ;; Testing requires undocumented setup changes with network access to
3519 ;; <demo.docusign.net>, and so testing is disabled here.
3520 (arguments `(#:tests? #f))
3521 (native-inputs
3522 (list python-setuptools
3523 python-wheel))
3524 (propagated-inputs
3525 (list python-certifi
3526 python-dateutil
3527 python-urllib3
3528 python-pyjwt
3529 python-cryptography))
3530 (home-page "https://developers.docusign.com/")
3531 (synopsis "DocuSign Python Client")
3532 (description
3533 "The Official DocuSign Python Client Library used to interact with the
3534eSign REST API. Send, sign, and approve documents using this client.")
3535 (license license:expat)))
3536
3537(define-public python-domain-connect
3538 (package
3539 (name "python-domain-connect")
3540 (version "0.0.11")
3541 (source
3542 (origin
3543 (method git-fetch) ;no tests in PyPI archive
3544 (uri (git-reference
3545 (url "https://github.com/Domain-Connect/domainconnect_python")
3546 (commit (string-append "v" version))))
3547 (file-name (git-file-name name version))
3548 (sha256
3549 (base32 "1dhqbx15h074g51mj73j9hlyvb11isjnj4s9ih5kbw1g4vf1q1jk"))))
3550 (build-system pyproject-build-system)
3551 (arguments
3552 (list
3553 ;; Check and sanity-check phases require /etc/resolv.conf, which is not
3554 ;; present in container.
3555 #:tests? #f
3556 #:phases #~(modify-phases %standard-phases (delete 'sanity-check))))
3557 (native-inputs
3558 (list python-setuptools))
3559 (propagated-inputs
3560 (list python-cryptography
3561 python-dnspython
3562 python-future
3563 python-publicsuffixlist))
3564 (home-page "https://github.com/Domain-Connect/domainconnect_python")
3565 (synopsis "Client library for Domain Connect protocol")
3566 (description
3567 "This package provides a Service Provider functionality in both Sync and
3568Async mode for @url{https://domainconnect.org/, Domain Connect protocol}.")
3569 (license license:expat)))
3570
3571(define-public python-domain-connect-dyndns
3572 (package
3573 (name "python-domain-connect-dyndns")
3574 (version "0.0.9")
3575 (source
3576 (origin
3577 (method url-fetch)
3578 (uri (pypi-uri "domain-connect-dyndns" version))
3579 (sha256
3580 (base32 "0srrblcb64bp7k5cqqivx4kykqdkmmzmspxwv66vix9k7wxdwqzx"))))
3581 (build-system pyproject-build-system)
3582 (arguments
3583 (list
3584 ;; Check and sanity-check phases require /etc/resolv.conf, which is not
3585 ;; present in container.
3586 #:tests? #f
3587 #:phases #~(modify-phases %standard-phases (delete 'sanity-check))))
3588 (native-inputs
3589 (list python-setuptools
3590 python-wheel))
3591 (propagated-inputs
3592 (list python-dnspython
3593 python-domain-connect
3594 python-requests
3595 python-validators))
3596 (home-page "https://github.com/Domain-Connect/DomainConnectDDNS-Python")
3597 (synopsis "Domain Connect Dynamic DNS in Python")
3598 ;; Project lacks meaningful description in README, see
3599 ;; <https://github.com/Domain-Connect/DomainConnectDDNS-Python/issues/43>.
3600 (description
3601 "Python client library for Dynamic DNS using
3602@url{https://www.domainconnect.org/, Domain Connect} protocol.")
3603 (license license:expat)))
3604
3605(define-public python-dominate
3606 (package
3607 (name "python-dominate")
3608 (version "2.9.1")
3609 (source
3610 (origin
3611 (method git-fetch)
3612 (uri (git-reference
3613 (url "https://github.com/Knio/dominate")
3614 (commit version)))
3615 (file-name (git-file-name name version))
3616 (sha256
3617 (base32 "0kv5ly8w2026pwvgamfjxav1g58wmgim30nr9w9qfwcipfjxwn5c"))))
3618 (build-system pyproject-build-system)
3619 (native-inputs
3620 (list python-pytest
3621 python-setuptools))
3622 (home-page "https://github.com/Knio/dominate")
3623 (synopsis "Python library for creating and manipulating HTML documents")
3624 (description
3625 "Dominate is a Python library for creating and manipulating HTML
3626documents using an elegant DOM API.")
3627 (license license:lgpl3+)))
3628
3629(define-public python-dpkt
3630 (package
3631 (name "python-dpkt")
3632 (version "1.9.8")
3633 (source
3634 (origin
3635 (method git-fetch)
3636 (uri (git-reference
3637 (url "https://github.com/kbandla/dpkt")
3638 (commit (string-append "v" version))))
3639 (file-name (git-file-name name version))
3640 (sha256
3641 (base32 "0dhy8l4sqfxqdda6lishb95g3v6hnw14l20ipqpzb6vaw1vf7mzj"))))
3642 (build-system pyproject-build-system)
3643 (arguments
3644 (list
3645 #:test-flags
3646 #~(list "--pyargs" "dpkt")))
3647 (native-inputs (list python-pytest python-setuptools))
3648 (home-page "https://github.com/kbandla/dpkt")
3649 (synopsis "Packet generator and parser for TCP/IP protocols")
3650 (description
3651 "The dpkt module is a fast, simple packet generator and parser for the
3652basic TCP/IP protocols.")
3653 (license license:bsd-3)))
3654
3655(define-public python-dropbox
3656 (package
3657 (name "python-dropbox")
3658 (version "12.0.2")
3659 (source
3660 (origin
3661 (method git-fetch) ; no tests in PyPI release
3662 (uri (git-reference
3663 (url "https://github.com/dropbox/dropbox-sdk-python")
3664 (commit (string-append "v" version))))
3665 (file-name (git-file-name name version))
3666 (sha256
3667 (base32 "0pyvi2mbibah42kq8804d98ghypm46wr8swqr34apnvnlp9j2nzl"))))
3668 (build-system pyproject-build-system)
3669 (arguments
3670 (list
3671 #:test-flags
3672 #~(list "-k" (string-join
3673 ;; Network access is required.
3674 (list "not test_bad_auth"
3675 "test_app_auth"
3676 "test_bad_pins"
3677 "test_bad_pins_session"
3678 "test_downscope"
3679 "test_multi_auth"
3680 "test_path_root"
3681 "test_path_root_err"
3682 "test_refresh"
3683 "test_rpc"
3684 "test_team"
3685 "test_upload_download"
3686 "test_versioned_route")
3687 " and not "))
3688 #:phases
3689 #~(modify-phases %standard-phases
3690 (add-after 'unpack 'relax-requirements
3691 (lambda _
3692 (substitute* "setup.py"
3693 ;; 'stone>=2,<3.3.3',
3694 ((">=2,<3.3.3") ">=2,<3.4.0"))))
3695 (add-before 'check 'pre-check
3696 (lambda _
3697 ;; Otherwise tests setup erroring.
3698 (setenv "LEGACY_USER_DROPBOX_TOKEN" "guix")
3699 (setenv "LEGACY_USER_CLIENT_ID" "guix")
3700 (setenv "LEGACY_USER_CLIENT_SECRET" "guix")
3701 (setenv "LEGACY_USER_REFRESH_TOKEN" "guix")
3702 (setenv "SCOPED_USER_DROPBOX_TOKEN" "guix")
3703 (setenv "SCOPED_USER_CLIENT_ID" "guix")
3704 (setenv "SCOPED_USER_CLIENT_SECRET" "guix")
3705 (setenv "SCOPED_USER_REFRESH_TOKEN" "guix")
3706 (setenv "SCOPED_TEAM_DROPBOX_TOKEN" "guix")
3707 (setenv "SCOPED_TEAM_CLIENT_ID" "guix")
3708 (setenv "SCOPED_TEAM_CLIENT_SECRET" "guix")
3709 (setenv "SCOPED_TEAM_REFRESH_TOKEN" "guix")
3710 (setenv "DROPBOX_SHARED_LINK" "guix"))))))
3711 (native-inputs
3712 (list nss-certs-for-test
3713 python-mock
3714 python-pytest
3715 python-pytest-mock
3716 python-setuptools
3717 python-wheel))
3718 (propagated-inputs
3719 (list python-requests python-six python-stone))
3720 (home-page "https://www.dropbox.com/developers")
3721 (synopsis "Official Dropbox API Client")
3722 (description "This package provides a Python SDK for integrating with the
3723Dropbox API v2.")
3724 (license license:expat)))
3725
3726(define-public python-dukpy
3727 (package
3728 (name "python-dukpy")
3729 (version "0.5.1")
3730 (source
3731 (origin
3732 (method git-fetch)
3733 (uri (git-reference
3734 (url "https://github.com/amol-/dukpy")
3735 (commit version)))
3736 (file-name (git-file-name name version))
3737 (sha256
3738 (base32 "1qsqfgy12frrdikjf353bsvhln11jixc3qs9rc1zra55k0569036"))))
3739 (build-system pyproject-build-system)
3740 (arguments
3741 (list
3742 #:test-flags
3743 #~(list #$@(map (lambda (test)
3744 (string-append "--deselect=tests/test_installer.py"
3745 "::TestPackageInstaller::"
3746 test))
3747 ;; Network access is required.
3748 (list "test_install_command"
3749 "test_install_command_latest_ver"
3750 "test_install_command_substrate_error"
3751 "test_install_command_without_dest"
3752 "test_install_react"
3753 "test_install_scoped_package"
3754 "test_install_unexisting_package"
3755 "test_install_unexisting_version")))))
3756 (native-inputs
3757 (list python-mock
3758 python-pytest
3759 python-setuptools
3760 python-webassets))
3761 (home-page "https://github.com/amol-/dukpy")
3762 (synopsis "Simple JavaScript interpreter for Python")
3763 (description
3764 "DukPy is a simple JavaScript interpreter for Python built on top of
3765duktape engine without any external dependency. It comes with a bunch of
3766common transpilers built-in for convenience:
3767@itemize
3768@item CoffeeScript
3769@item BabelJS
3770@item TypeScript
3771@item JSX
3772@item LESS
3773@end itemize")
3774 (license license:expat)))
3775
3776(define-public python-elastic-transport
3777 (package
3778 (name "python-elastic-transport")
3779 (version "9.1.0")
3780 (source
3781 (origin
3782 (method url-fetch)
3783 (uri (pypi-uri "elastic_transport" version))
3784 (sha256
3785 (base32 "0g879z8rqrfbwkxsm6xcycjha1swl7gdgs6m0y0j1zmh4m5f940m"))))
3786 (build-system pyproject-build-system)
3787 (arguments
3788 (list
3789 #:test-flags
3790 ;; Deselect failing tests (mostly due to network not reachable)
3791 #~(list "-k"
3792 (string-append
3793 "not .badssl.com"
3794 " and not test_assert_fingerprint_in_cert_chain_failure"))))
3795 (propagated-inputs (list python-certifi python-urllib3))
3796 (native-inputs (list nss-certs-for-test
3797 python-aiohttp
3798 ;; python-furo
3799 python-httpx
3800 python-opentelemetry-api
3801 python-opentelemetry-sdk
3802 python-orjson
3803 python-pytest
3804 python-pytest-asyncio-0.26
3805 ;; python-pytest-cov
3806 python-pytest-httpbin
3807 python-pytest-httpserver
3808 python-pytest-mock
3809 python-requests
3810 python-respx ;test
3811 python-setuptools
3812 ;; python-sphinx
3813 ;; python-sphinx-autodoc-typehints
3814 python-trustme
3815 python-wheel))
3816 (home-page "https://github.com/elastic/elastic-transport-python")
3817 (synopsis "Common library for Python Elastic client libraries")
3818 (description
3819 "This library was lifted from @code{elasticsearch-py} and then transformed to
3820be used across all Elastic services rather than only Elasticsearch. It
3821provides transport classes and utilities shared among Python Elastic client
3822libraries.")
3823 ;; Apache-2.0 in setup.py and LICENSE file.
3824 (license license:asl2.0)))
3825
3826(define-public python-elasticsearch
3827 (package
3828 (name "python-elasticsearch")
3829 (version "9.1.1")
3830 (source
3831 (origin
3832 (method git-fetch) ; no tests in PyPI release
3833 (uri (git-reference
3834 (url "https://github.com/elastic/elasticsearch-py")
3835 (commit (string-append "v" version))))
3836 (file-name (git-file-name name version))
3837 (sha256
3838 (base32 "015x73y84nyigcyg00lh32p2pfrqf834fr7clfnzymgzrrxa73jf"))))
3839 (build-system pyproject-build-system)
3840 (native-inputs
3841 (list nss-certs-for-test
3842 python-aiohttp
3843 python-dateutil
3844 python-mock
3845 python-orjson
3846 python-pytest
3847 python-pytest-asyncio
3848 python-pytz
3849 python-pyyaml
3850 python-requests
3851 python-hatchling))
3852 (propagated-inputs
3853 (list python-certifi
3854 python-elastic-transport))
3855 (home-page "https://github.com/elastic/elasticsearch-py")
3856 (synopsis "Low-level client for Elasticsearch")
3857 (description "Official low-level client for Elasticsearch. Its goal is to
3858provide common ground for all Elasticsearch-related code in Python; because of
3859this it tries to be opinion-free and very extendable.")
3860 ;; Apache-2.0 in setup.py and LICENSE file.
3861 (license license:asl2.0)))
3862
3863(define-public python-engineio
3864 (package
3865 (name "python-engineio")
3866 (version "4.13.4")
3867 (source
3868 (origin
3869 (method git-fetch)
3870 (uri (git-reference
3871 (url "https://github.com/miguelgrinberg/python-engineio/")
3872 (commit (string-append "v" version))))
3873 (file-name (git-file-name name version))
3874 (sha256
3875 (base32 "1ndp68cqssjpvln958v236rg5jgpzy57vs3z45sz7xfscmbi893r"))))
3876 (build-system pyproject-build-system)
3877 (native-inputs
3878 (list python-pytest
3879 python-pytest-asyncio
3880 python-setuptools
3881 python-tornado))
3882 (propagated-inputs
3883 (list python-simple-websocket
3884 ;; [optional]
3885 python-aiohttp
3886 python-requests
3887 python-websocket-client))
3888 (home-page "https://github.com/miguelgrinberg/python-engineio/")
3889 (synopsis "Engine.IO server")
3890 (description "This package provides a Python implementation of the
3891@code{Engine.IO} realtime client and server.")
3892 (license license:expat)))
3893
3894(define-public python-enoslib
3895 (package
3896 (name "python-enoslib")
3897 (version "8.0.1")
3898 (source
3899 (origin
3900 (method git-fetch)
3901 (uri (git-reference
3902 (url "https://gitlab.inria.fr/discovery/enoslib")
3903 (commit (string-append "v" version))))
3904 (file-name (git-file-name name version))
3905 (sha256 "0vs6b0bnlv95mzv0rjbxqwrhzkgjkn91gqipgwdf7y4ffpz8nybg")))
3906 (arguments
3907 (list
3908 #:test-flags
3909 #~(list "enoslib/tests/unit"
3910 "--ignore" "enoslib/tests/unit/infra/test_utils.py"
3911 "--ignore-glob" "enoslib/tests/unit/infra/enos_iotlab/*")
3912 #:phases
3913 #~(modify-phases %standard-phases
3914 (add-before 'check 'pre-check
3915 (lambda* (#:key tests? #:allow-other-keys)
3916 (when tests?
3917 ;; Otherwise Ansible fails to create its config directory.
3918 (setenv "HOME" "/tmp"))))
3919 ;; Disable the sanity check, which fails with the following error:
3920 ;;
3921 ;; ContextualVersionConflict(rich 12.4.1
3922 ;; (/gnu/store/...-python-rich-12.4.1/lib/python3.9/site-packages),
3923 ;; Requirement.parse('rich[jupyter]~=12.0.0'), {'enoslib'})
3924 ;;
3925 ;; The optional jupyter dependency of rich isn't critical for
3926 ;; EnOSlib to work
3927 (delete 'sanity-check))))
3928 (build-system pyproject-build-system)
3929 (native-inputs
3930 (list python-ddt
3931 python-freezegun
3932 python-pytest
3933 python-setuptools
3934 python-wheel))
3935 (propagated-inputs
3936 (list ansible
3937 python-cryptography
3938 python-grid5000
3939 python-jsonschema
3940 python-netaddr
3941 python-packaging
3942 python-requests
3943 python-rich
3944 python-sshtunnel
3945 python-pytz))
3946 (home-page "https://discovery.gitlabpages.inria.fr/enoslib/index.html")
3947 (synopsis "Deploy distributed testbeds on a variety of platforms")
3948 (description
3949 "EnOSlib is a library to build experimental frameworks on various
3950scientific testbeds. It lets you deploy networks of machines on actual
3951hardware on Grid'5000 or via OpenStack, to Vagrant, Chameleon, and more.")
3952 (license license:gpl3+)))
3953
3954(define-public python-ephemeral-port-reserve
3955 (package
3956 (name "python-ephemeral-port-reserve")
3957 (version "1.1.4")
3958 (source
3959 (origin
3960 (method git-fetch)
3961 (uri (git-reference
3962 (url "https://github.com/Yelp/ephemeral-port-reserve")
3963 (commit (string-append "v" version))))
3964 (file-name (git-file-name name version))
3965 (sha256
3966 (base32 "1ifmf5zcw7mhbm73awmf5jwc4rw8lhk81mn4zp797lwkysjm38s7"))))
3967 (build-system pyproject-build-system)
3968 (native-inputs
3969 (list python-pytest
3970 python-setuptools))
3971 (home-page "https://github.com/Yelp/ephemeral-port-reserve/")
3972 (synopsis "Find an unused port, reliably")
3973 (description
3974 "Bind to an ephemeral port, force it into the TIME_WAIT state, and unbind
3975it.")
3976 (license license:expat)))
3977
3978(define-public python-essentials-openapi
3979 (package
3980 (name "python-essentials-openapi")
3981 (version "1.2.1")
3982 (source
3983 (origin
3984 (method git-fetch)
3985 (uri (git-reference
3986 (url "https://github.com/Neoteroi/essentials-openapi")
3987 (commit (string-append "v" version))))
3988 (file-name (git-file-name name version))
3989 (sha256
3990 (base32 "0f3lhpkqhvv8sr1c34cvzdqkc61306m03w3jp0zdih1v6is05j8x"))))
3991 (build-system pyproject-build-system)
3992 (native-inputs
3993 (list python-flask
3994 python-hatchling
3995 python-pydantic
3996 python-pytest
3997 python-rich))
3998 (propagated-inputs
3999 (list python-essentials
4000 python-httpx
4001 python-jinja2
4002 python-markupsafe
4003 python-pyyaml))
4004 (home-page "https://github.com/Neoteroi/essentials-openapi/")
4005 (synopsis "Generator for OpenAPI Documentation")
4006 (description
4007 "Generator for OpenAPI Documentation version 2 and 3, in JSON and YAML
4008formats. Generator for other kinds of documents from OpenAPI Documentation
4009files.")
4010 (license license:expat)))
4011
4012(define-public python-eventlet
4013 (package
4014 (name "python-eventlet")
4015 (version "0.41.0")
4016 (source
4017 (origin
4018 (method git-fetch)
4019 (uri (git-reference
4020 (url "https://github.com/eventlet/eventlet")
4021 (commit version)))
4022 (file-name (git-file-name name version))
4023 (sha256
4024 (base32 "1rn8f5v08n48dh6aycdxfwz17w4xwkgny7bhy5llqn5dl0g2dw43"))))
4025 (build-system pyproject-build-system)
4026 (arguments
4027 (list
4028 ;; tests: 618 passed, 121 skipped, 20 deselected, 52 warnings
4029 #:test-flags
4030 #~(list
4031 #$@(map (lambda (test)
4032 (string-append "--deselect=tests/" test))
4033 (list
4034 ;; dns.resolver.NoResolverConfiguration: cannot open
4035 ;; /etc/resolv.conf
4036 "greendns_test.py::TestProxyResolver::test_clear"
4037 "greendns_test.py::TinyDNSTests::test_noraise_dns_tcp"
4038 "greendns_test.py::TinyDNSTests::test_raise_dns_tcp"
4039 ;; assert <built-in function gethostbyname> is <function
4040 ;; gethostbyname at 0x7ffff3491120>
4041 "socket_test.py::test_dns_methods_are_green"
4042 ;; socket.gaierror: [Errno -8] Servname not supported for
4043 ;; ai_socktype
4044 "greendns_test.py::TestGetaddrinfo::test_getaddrinfo"
4045 "greendns_test.py::TestGetaddrinfo::test_getaddrinfo_idn"
4046 "greendns_test.py::TestGetaddrinfo::test_getaddrinfo_inet"
4047 "greendns_test.py::TestGetaddrinfo::test_getaddrinfo_inet6"
4048 "greendns_test.py::test_hosts_no_network"
4049 ;; AssertionError: Expected single line "pass" in stdout
4050 "asyncio_test.py::test_asyncio_does_not_use_greendns"
4051 "greendns_test.py::test_import_rdtypes_then_eventlet"
4052 "patcher_test.py::test_patcher_existing_logging_module_lock")))
4053 #:phases
4054 #~(modify-phases %standard-phases
4055 (add-after 'unpack 'avoid-OSError
4056 (lambda _
4057 ;; If eventlet tries to load greendns, an OSError is thrown when
4058 ;; getprotobyname is called. Thankfully there is an environment
4059 ;; variable to disable the greendns import, so use it. Note that
4060 ;; this error is propagated to child packages too, so enforce the
4061 ;; changed default.
4062 (substitute* "eventlet/green/socket.py"
4063 (("os\\.environ\\.get\\(\"EVENTLET_NO_GREENDNS\", ''\\)")
4064 "os.environ.get(\"EVENTLET_NO_GREENDNS\", \"yes\")"))))
4065 (add-before 'check 'pre-check
4066 (lambda _
4067 (setenv "EVENTLET_HUB" "asyncio"))))))
4068 (native-inputs
4069 (list python-hatchling
4070 python-hatch-vcs
4071 python-pytest
4072 python-pytest-aiohttp))
4073 (propagated-inputs
4074 (list python-dnspython
4075 python-greenlet))
4076 (home-page "https://eventlet.net")
4077 (synopsis "Concurrent networking library for Python")
4078 (description
4079 "Eventlet is a concurrent networking library for Python that
4080allows you to change how you run your code, not how you write it.
4081It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O.
4082Coroutines ensure that the developer uses a blocking style of programming
4083that is similar to threading, but provide the benefits of non-blocking I/O.
4084The event dispatch is implicit, which means you can easily use @code{Eventlet}
4085from the Python interpreter, or as a small part of a larger application.
4086
4087Note: In Guix, this package assumes the environment variable
4088@code{EVENTLET_NO_GREENDNS} defaults to @code{yes}. To try to use it, set it
4089to anything else.")
4090 (license license:expat)))
4091
4092(define-public python-extruct
4093 (package
4094 (name "python-extruct")
4095 (version "0.18.0")
4096 (source (origin
4097 (method git-fetch) ;for tests
4098 (uri (git-reference
4099 (url "https://github.com/scrapinghub/extruct")
4100 (commit (string-append "v" version))))
4101 (file-name (git-file-name name version))
4102 (sha256
4103 (base32
4104 "03qdldqrvmbsk6klq4nkxvvp3b2a0qqgqg115i3crbmialiaai45"))))
4105 (build-system pyproject-build-system)
4106 (arguments
4107 (list
4108 #:test-flags
4109 ;; 67 passed, 3 deselected
4110 ;; XXX: 3 tests fail with errors in assertion.
4111 #~(list "-k" (string-append
4112 "not test_microformat"
4113 " and not test_microformat"
4114 " and not test_umicroformat"))))
4115 (native-inputs
4116 (list python-pytest
4117 python-setuptools
4118 python-wheel))
4119 (propagated-inputs
4120 (list python-html-text
4121 python-jstyleson
4122 python-lxml
4123 python-mf2py
4124 python-pyrdfa3
4125 python-rdflib
4126 python-w3lib))
4127 (home-page "https://github.com/scrapinghub/extruct")
4128 (synopsis "Extract embedded metadata from HTML markup")
4129 (description "@code{extruct} is a Python library for extracting embedded
4130metadata from HTML markup. Currently, extruct supports:
4131@itemize
4132@item W3C's HTML Microdata
4133@item embedded JSON-LD
4134@item Microformat via mf2py
4135@item Facebook's Open Graph
4136@item (experimental) RDFa via rdflib
4137@item Dublin Core Metadata (DC-HTML-2003)
4138@end itemize")
4139 (license license:bsd-3)))
4140
4141(define-public python-feedgen
4142 (package
4143 (name "python-feedgen")
4144 (version "1.0.0")
4145 (source
4146 (origin
4147 (method git-fetch)
4148 (uri (git-reference
4149 (url "https://github.com/lkiesow/python-feedgen")
4150 (commit (string-append "v" version))))
4151 (file-name (git-file-name name version))
4152 (sha256
4153 (base32
4154 "1ppwxp9yck29pk2p2dlrrad6rz16l9h4fhcajp9yb7ns94fm5v3l"))))
4155 (build-system pyproject-build-system)
4156 (propagated-inputs
4157 (list python-dateutil
4158 python-lxml))
4159 (native-inputs
4160 (list python-pytest
4161 python-setuptools))
4162 (home-page "https://feedgen.kiesow.be")
4163 (synopsis "Atom and RSS feed generator")
4164 (description
4165 "This module can be used to generate web feeds in both Atom and RSS
4166format. It also extensible and comes with an extension to produce podcasts.")
4167 ;; The README says that this package is released under both licenses, and
4168 ;; permits the user to choose whichever is more convenient to them.
4169 (license (list license:bsd-2
4170 license:lgpl3+))))
4171
4172(define-public python-flask-caching
4173 (package
4174 (name "python-flask-caching")
4175 (version "2.3.1")
4176 (source
4177 (origin
4178 (method url-fetch)
4179 (uri (pypi-uri "flask_caching" version))
4180 (sha256
4181 (base32 "1jcqgfzvqhgpngf9nhpfjs129cslh8jyczfy8kw11y7b9qdzvmv5"))))
4182 (build-system pyproject-build-system)
4183 (arguments
4184 (list
4185 #:test-flags
4186 ;; Tests requiring running Redis or dated python-cache.
4187 #~(list "--deselect=tests/test_init.py::test_init_nullcache[MemcachedCache]"
4188 "--deselect=tests/test_init.py::test_init_nullcache[RedisCache]"
4189 "--deselect=tests/test_init.py::test_init_nullcache[RedisSentinelCache]"
4190 "--deselect=tests/test_init.py::test_init_nullcache[SASLMemcachedCache]"
4191 "--deselect=tests/test_init.py::test_init_nullcache[SpreadSASLMemcachedCache]"
4192 "-k" "not test_client_override_reflected_on_cachelib_methods")))
4193 (native-inputs
4194 (list python-pytest
4195 python-pytest-asyncio
4196 python-pytest-xprocess
4197 python-setuptools))
4198 (propagated-inputs
4199 (list python-cachelib
4200 python-flask))
4201 (home-page "https://github.com/pallets-eco/flask-caching")
4202 (synopsis "Caching extension for Flask")
4203 (description
4204 "This package provides a caching support to Flask applications, it's a
4205fort ok https://github.com/thadeusb/flask-cache.")
4206 (license license:bsd-3)))
4207
4208(define-public python-flask-paginate
4209 (package
4210 (name "python-flask-paginate")
4211 (version "2024.4.12")
4212 (source
4213 (origin
4214 (method git-fetch)
4215 (uri (git-reference
4216 (url "https://github.com/lixxu/flask-paginate")
4217 (commit (string-append "v" version))))
4218 (file-name (git-file-name name version))
4219 (sha256
4220 (base32 "1q4ajwk0pzc6934g07gdryjcwi6rd9iqcwv5g5s718dfx2bj1831"))))
4221 (arguments
4222 (list #:test-backend #~'custom
4223 #:test-flags #~(list "tests/tests.py")))
4224 (build-system pyproject-build-system)
4225 (native-inputs
4226 (list python-pytest
4227 python-setuptools))
4228 (propagated-inputs
4229 (list python-flask))
4230 (home-page "https://github.com/lixxu/flask-paginate")
4231 (synopsis "Simple paginate support for Flask")
4232 (description
4233 "Flask-paginate is a simple pagination extension for Flask which is
4234inspired by Ruby's will_paginate library. It supports several CSS frameworks.")
4235 (license license:bsd-3)))
4236
4237(define-public python-flask-limiter
4238 (package
4239 (name "python-flask-limiter")
4240 (version "4.1.1")
4241 (source
4242 (origin
4243 (method git-fetch)
4244 (uri (git-reference
4245 (url "https://github.com/alisaifee/flask-limiter")
4246 (commit version)))
4247 (file-name (git-file-name name version))
4248 (sha256
4249 (base32 "18n12iayzw6qqys26824j5lfbphfcammpmyrvys1k0rn4xcbifln"))))
4250 (build-system pyproject-build-system)
4251 (arguments
4252 (list
4253 ;; tests: 155 passed, 620 deselected
4254 #:test-flags
4255 #~(list "-k" (simple-format #f "not (~a)"
4256 (string-join
4257 (append
4258 ;; The test suite spawns storages in Docker.
4259 '("memcache" "reset_unsupported")
4260 '("mongo")
4261 '("redis" "clear_limits"
4262 "constructor_arguments_over_config"
4263 "custom_key_prefix" "fallback_to_memory"))
4264 " or ")))
4265 #:phases
4266 #~(modify-phases %standard-phases
4267 (add-before 'check 'adjust-tests
4268 (lambda _
4269 (substitute* "pytest.ini"
4270 ((".*--cov=.*") ""))
4271 (substitute* (find-files "tests" "\\.py$")
4272 (("import pymemcache.*") "")
4273 (("import pymongo.*") "")
4274 (("import redis.*") "")))))))
4275 (native-inputs (list python-flask-restful
4276 python-hatch-vcs
4277 python-hatchling
4278 python-hiro
4279 python-pytest
4280 python-pytest-check
4281 python-pytest-mock))
4282 (propagated-inputs (list python-flask
4283 python-limits
4284 python-ordered-set
4285 python-rich))
4286 (home-page "https://flask-limiter.readthedocs.org/")
4287 (synopsis "Rate limiting for Flask applications")
4288 (description
4289 "Flask-Limiter adds rate limiting to Flask applications.
4290Rate limits can be configured at different levels such as:
4291
4292@itemize
4293@item Application wide global limits per user
4294@item Default limits per route
4295@item By blueprints
4296@item By class-based views
4297@item By individual routes
4298@end itemize")
4299 (license license:expat)))
4300
4301(define-public python-gdown
4302 (package
4303 (name "python-gdown")
4304 (version "5.2.0")
4305 (source
4306 (origin
4307 (method url-fetch)
4308 (uri (pypi-uri "gdown" version))
4309 (sha256
4310 (base32 "11y7xx6zjipx15a5626lhiwmwb2jxp4mdcwqrnij0mfqc981ci91"))))
4311 (build-system pyproject-build-system)
4312 (arguments (list #:tests? #f)) ;network access is required
4313 (native-inputs
4314 (list python-hatch-fancy-pypi-readme
4315 python-hatch-vcs
4316 python-hatchling))
4317 (propagated-inputs
4318 (list python-beautifulsoup4
4319 python-filelock
4320 python-requests
4321 python-tqdm))
4322 (home-page "https://github.com/wkentaro/gdown")
4323 (synopsis "Google Drive Public File/Folder Downloader")
4324 (description
4325 "This package implements a functionality to download large files
4326recursively from Google Drive with option to filter them by file
4327formats (PDF/XML/CSV).")
4328 (license license:expat)))
4329
4330(define-public python-globus-sdk
4331 (package
4332 (name "python-globus-sdk")
4333 (version "4.4.0")
4334 (source
4335 (origin
4336 (method git-fetch)
4337 (uri (git-reference
4338 (url "https://github.com/globus/globus-sdk-python")
4339 (commit version)))
4340 (file-name (git-file-name name version))
4341 (sha256
4342 (base32 "1d0zw9dkpdhsf9zdg3nk6b55gqwzc3v2rj76nj7999hjmq8350vh"))))
4343 (build-system pyproject-build-system)
4344 (arguments
4345 (list
4346 #:phases
4347 #~(modify-phases %standard-phases
4348 (add-before 'check 'pre-check
4349 (lambda _ (setenv "HOME" "/tmp"))))))
4350 (native-inputs
4351 (list python-flaky
4352 python-pytest
4353 python-pytest-randomly
4354 python-responses
4355 python-setuptools))
4356 (propagated-inputs
4357 (list python-cryptography
4358 python-importlib-resources
4359 python-pyjwt
4360 python-requests))
4361 (home-page "https://github.com/globus/globus-sdk-python")
4362 (synopsis "Globus SDK for Python")
4363 (description
4364 "This package provides a SDK for convenient Pythonic interface to
4365@url{https://www.globus.org/, Globus} APIs.")
4366 (license license:asl2.0)))
4367
4368(define-public python-guardpost
4369 (package
4370 (name "python-guardpost")
4371 (version "1.0.4")
4372 (source
4373 (origin
4374 (method git-fetch)
4375 (uri (git-reference
4376 (url "https://github.com/Neoteroi/guardpost")
4377 (commit (string-append "v" version))))
4378 (file-name (git-file-name name version))
4379 (sha256
4380 (base32 "1xsakqn36g2h1s5rnbaf1lasx1jn4skqhmb8kdl1k4pgxp5sczyy"))))
4381 (build-system pyproject-build-system)
4382 (arguments
4383 (list
4384 ;; Possible timing issue, see:
4385 ;; <https://github.com/Neoteroi/GuardPost/issues/18>.
4386 #:test-flags '(list "--ignore=tests/test_jwts.py")))
4387 (native-inputs
4388 (list python-flask
4389 python-hatchling
4390 python-pytest
4391 python-pytest-asyncio))
4392 (propagated-inputs
4393 (list python-rodi
4394 ;; [optional]
4395 python-cryptography
4396 python-essentials
4397 python-pyjwt))
4398 (home-page "https://github.com/Neoteroi/GuardPost/")
4399 (synopsis
4400 "Authentication and authorization framework for Python applications")
4401 (description
4402 "GuardPost is a framework to handle authentication and
4403authorization in asynchronous Python applications.
4404
4405Its features include
4406
4407@itemize
4408@item Strategy to implement authentication.
4409@item Strategy to implement authorization.
4410@item Support for dependency injection
4411@item Built-in support for JSON Web Tokens (JWTs) authentication.
4412@end itemize")
4413 (license license:expat)))
4414
4415(define-public python-habanero
4416 (package
4417 (name "python-habanero")
4418 (version "2.3.0")
4419 (source
4420 (origin
4421 (method git-fetch)
4422 (uri (git-reference
4423 (url "https://github.com/sckott/habanero")
4424 (commit (string-append "v" version))))
4425 (file-name (git-file-name name version))
4426 (sha256
4427 (base32 "1a842izcc8l4wb8004v92zsq1h4yc7qc2wi9am6x0f7idlx993sw"))))
4428 (build-system pyproject-build-system)
4429 (arguments
4430 ;; Run only a small portion of unit tests without network access
4431 ;; requirement.
4432 (list #:test-flags #~(list "test/test-filters.py")))
4433 (native-inputs
4434 (list python-hatchling
4435 python-pytest))
4436 (propagated-inputs
4437 (list python-httpx
4438 python-packaging
4439 python-tqdm
4440 python-urllib3))
4441 (home-page "https://github.com/sckott/habanero")
4442 (synopsis "Low Level Client for Crossref Search API")
4443 (description
4444 "Low Level Client for
4445@url{https://api.crossref.org/swagger-ui/index.html, Crossref Search API}.")
4446 (license license:expat)))
4447
4448(define-public python-hookdns
4449 (package
4450 (name "python-hookdns")
4451 (version "2.0.0")
4452 (source
4453 (origin
4454 (method url-fetch)
4455 (uri (pypi-uri "hookdns" version))
4456 (sha256
4457 (base32 "087x12dy6slhyqwqblby2fpjdcy61yk3lqp3fplami0rmbn02fb7"))))
4458 (build-system pyproject-build-system)
4459 (arguments
4460 (list
4461 #:test-flags
4462 #~(list "-k" (string-join
4463 ;; Tests requiring networking.
4464 (list
4465 "not test_patch_contextmanager_with_another_hostname"
4466 "test_patch_contextmanager_with_another_hostname_ipv6"
4467 "test_patch_contextmanager_with_ipv4"
4468 "test_patch_contextmanager_with_name"
4469 "test_patch_contextmanager_with_public_fqdn_and_"
4470 "test_patch_contextmanager_with_unknown_hostname"
4471 "test_patch_decorator_with_another_hostname"
4472 "test_patch_decorator_with_another_hostname_ipv6"
4473 "test_patch_decorator_with_ipv4"
4474 "test_patch_decorator_with_name"
4475 "test_patch_decorator_with_public_fqdn_and_a_name_for_"
4476 "test_patch_decorator_with_unknown_hostname"
4477 "test_real_getaddrinfo_with_name_ipv6"
4478 "test_real_getaddrinfo_with_public_fqdn_ipv4"
4479 "test_real_getaddrinfo_with_public_fqdn_ipv6"
4480 "test_real_gethostbyname_ex_with_public_fqdn"
4481 "test_real_gethostbyname_with_public_fqdn"
4482 "test_real_requests_ip"
4483 "test_real_requests_name"
4484 "test_real_requests_with_public_fqdn"
4485 "test_reentrant")
4486 " and not "))))
4487 (native-inputs
4488 (list python-pytest
4489 python-requests
4490 python-setuptools
4491 python-wheel))
4492 (home-page "https://github.com/cle-b/hookdns")
4493 (synopsis "DNS resolution customization library")
4494 (description
4495 "HookDNS implements functionality that allows for modifying name
4496resolution in a Python script without any changes to the hosts file or the use
4497of a fake DNS resolver.")
4498 (license license:asl2.0)))
4499
4500(define-public python-htgettoken
4501 (package
4502 (name "python-htgettoken")
4503 (version "2.6")
4504 (source
4505 (origin
4506 (method git-fetch)
4507 (uri (git-reference
4508 (url "https://github.com/fermitools/htgettoken")
4509 (commit (string-append "v" version))))
4510 (file-name (git-file-name name version))
4511 (sha256
4512 (base32 "10zf71i1j7w31j03lx1qn4g9kphygqpc5d8yd33s5ysrf578lwlc"))))
4513 (build-system pyproject-build-system)
4514 (arguments (list #:tests? #f)) ;no unit tests are provided
4515 (native-inputs (list python-setuptools))
4516 (propagated-inputs (list python-gssapi python-paramiko python-urllib3))
4517 (home-page "https://github.com/fermitools/htgettoken")
4518 (synopsis "OIDC authentication tokens Python library")
4519 (description
4520 "@code{htgettoken} gets @acronym{OpenID Connect, OIDC} bearer access
4521tokens by interacting with a Hashicorp vault server configured for retrieving
4522and storing OIDC refresh tokens using the
4523@url{https://github.com/fermitools/htvault-config, htvault-config package}.")
4524 (license license:bsd-3)))
4525
4526(define-public python-httpcore2
4527 (package
4528 (name "python-httpcore2")
4529 (version "2.4.0")
4530 (source
4531 (origin
4532 (method git-fetch)
4533 (uri (git-reference
4534 (url "https://github.com/pydantic/httpx2")
4535 (commit (string-append "v" version))))
4536 (file-name (git-file-name name version))
4537 (sha256
4538 (base32 "05mql79icxigldzw01hs77jpgihvzjahvniwncb7ji2rqzhjr42g"))))
4539 (build-system pyproject-build-system)
4540 (arguments
4541 (list
4542 #:phases
4543 #~(modify-phases %standard-phases
4544 (add-after 'unpack 'preparation
4545 (lambda _
4546 (chdir "src/httpcore2")
4547 (copy-recursively "../../tests/httpcore2" "tests")
4548 (substitute* (find-files "tests" "\\.py$")
4549 (("tests\\.httpcore2") "tests")
4550 (("tests/httpcore2") "tests"))))
4551 (add-before 'build 'set-version
4552 (lambda _
4553 (substitute* "pyproject.toml"
4554 ((".*uv-dynamic-versioning>.*") "")
4555 (("source.*uv-dynamic-versioning.*") "source = 'vcs'"))
4556 (substitute* "httpcore2/__init__.py"
4557 ((".*= version\\(.*")
4558 (format #f "__version__ = ~s~%" #$version))))))))
4559 (native-inputs
4560 (list python-hatch-fancy-pypi-readme
4561 python-hatch-vcs
4562 python-hatchling
4563 python-pytest
4564 python-pytest-httpbin
4565 python-pytest-trio))
4566 (propagated-inputs
4567 (list python-h11
4568 python-truststore
4569 ;; [optional]
4570 python-anyio
4571 python-h2
4572 python-socksio
4573 python-trio))
4574 (home-page "https://github.com/pydantic/httpx2")
4575 (synopsis "Minimal low-level HTTP client")
4576 (description
4577 "The HTTP Core package provides a minimal low-level HTTP client, which
4578does one thing only. Sending HTTP requests.
4579
4580Some things HTTP Core does do:
4581@itemize
4582@item Sending HTTP requests.
4583@item Thread-safe / task-safe connection pooling.
4584@item HTTP(S) proxy & SOCKS proxy support.
4585@item Supports HTTP/1.1 and HTTP/2.
4586@item Provides both sync and async interfaces.
4587@item Async backend support for @code{asyncio} and @code{trio}.
4588@end itemize")
4589 (license license:bsd-3)))
4590
4591(define-public python-httpretty
4592 (package
4593 (name "python-httpretty")
4594 (version "1.1.4")
4595 (source
4596 (origin
4597 (method url-fetch)
4598 (uri (pypi-uri "httpretty" version))
4599 (sha256
4600 (base32 "0s1vjdaf3pk2xd0hvi5f7p3jm2rgwpbc734jdp9r50m1smfhxpi0"))))
4601 (build-system pyproject-build-system)
4602 (arguments
4603 (list
4604 #:test-flags
4605 ;; Only run Unit tests.
4606 #~(list "--ignore=tests/bugfixes"
4607 "--ignore=tests/functional"
4608 "--ignore=tests/pyopenssl"
4609 "-k" (string-join
4610 ;; Tests pattern failing with one of these errors:
4611 ;; AttributeError: '(str|bool|bytes|list|tuple)' object
4612 ;; has no attribute 'should'
4613 ;; AttributeError: 'function' object has no attribute
4614 ;; 'when'
4615 ;; AttributeError: 'AssertionBuilder' object has no
4616 ;; attribute 'should_not'
4617 (list "not fake_socket_passes_through"
4618 "fakesock_socket"
4619 "request_parse_body_when"
4620 "test_Entry_class_normalizes_headers"
4621 "test_has_request"
4622 "test_httpretty_should_raise_proper"
4623 "test_parse_request_line_connect"
4624 "test_request_parse_querystring"
4625 "test_request_string_representation"
4626 "test_request_stubs_internals")
4627 " and not "))))
4628 (native-inputs
4629 (list nss-certs-for-test
4630 python-freezegun
4631 python-mock
4632 python-pytest
4633 python-setuptools
4634 python-sure
4635 python-wheel))
4636 (home-page "https://httpretty.readthedocs.io")
4637 (synopsis "HTTP client mock for Python")
4638 (description
4639 "@code{httpretty} is a helper for faking web requests,inspired by Ruby's
4640@code{fakeweb}.")
4641 (license license:expat)))
4642
4643(define-public python-httpx2
4644 (package
4645 (name "python-httpx2")
4646 (version "2.4.0")
4647 (source
4648 (origin
4649 (method git-fetch)
4650 (uri (git-reference
4651 (url "https://github.com/pydantic/httpx2")
4652 (commit (string-append "v" version))))
4653 (file-name (git-file-name name version))
4654 (sha256
4655 (base32 "05mql79icxigldzw01hs77jpgihvzjahvniwncb7ji2rqzhjr42g"))))
4656 (arguments
4657 (list
4658 ;; tests: 1227 passed, 200 deselected
4659 #:test-flags
4660 ;; Networking tests.
4661 #~(list "-k" (string-join
4662 (list "not test_async_proxy_close[asyncio]"
4663 "test_async_proxy_close[trio]"
4664 "test_auth"
4665 "test_binary"
4666 "test_client_decode_text_using_autodetect"
4667 "test_client_decode_text_using_explicit_encoding"
4668 "test_follow_redirects"
4669 "test_get"
4670 "test_idna_url[http_with_custom_port]"
4671 "test_idna_url[http_with_port]"
4672 "test_idna_url[https_with_custom_port]"
4673 "test_idna_url[https_with_port]"
4674 "test_idna_url[https_without_port]"
4675 "test_idna_url[idna_label_after_ascii_label]"
4676 "test_idna_url[unicode_tr46_compat]"
4677 "test_json"
4678 "test_post"
4679 "test_redirects"
4680 "test_response_decode_text_using_autodetect"
4681 "test_sync_proxy_close"
4682 "test_url_malformed_idna_label_after_ascii_label"
4683 "test_url_mixed_valid_and_malformed_idna_labels"
4684 "test_verbose")
4685 " and not "))
4686 #:phases
4687 #~(modify-phases %standard-phases
4688 (add-after 'unpack 'preparation
4689 (lambda _
4690 (chdir "src/httpx2")
4691 (copy-recursively "../../tests/httpx2" "tests")
4692 (substitute* (find-files "tests" "\\.py$")
4693 (("tests\\.httpx2") "tests")
4694 (("tests/httpx2") "tests"))))
4695 (add-before 'build 'set-version
4696 (lambda _
4697 (substitute* "pyproject.toml"
4698 (("\"uv-dynamic-versioning>=0\\.8\\.0\"") "")
4699 (("source.*uv-dynamic-versioning.*") "source = 'vcs'")
4700 (("\\.uv-dynamic-versioning") ".vcs")))))))
4701 (build-system pyproject-build-system)
4702 (native-inputs
4703 (list python-chardet
4704 python-hatch-fancy-pypi-readme
4705 python-hatch-vcs
4706 python-hatchling
4707 python-pytest
4708 python-trustme
4709 python-uvicorn))
4710 (propagated-inputs
4711 (list python-anyio
4712 python-httpcore2
4713 python-idna
4714 python-truststore
4715 python-typing-extensions ;Python version < 3.13
4716 ;; [optional]
4717 python-brotli
4718 python-click
4719 python-h2
4720 python-pygments
4721 python-rich
4722 python-socksio
4723 python-zstandard))
4724 (home-page "https://github.com/pydantic/httpx2")
4725 (synopsis "The next generation HTTP client")
4726 (description
4727 "HTTPX2 is a fully featured HTTP client library for Python. It includes
4728an integrated command line client, has support for both HTTP/1.1 and HTTP/2,
4729and provides both sync and async APIs.")
4730 (license license:bsd-3)))
4731
4732(define-public python-igwn-auth-utils
4733 (package
4734 (name "python-igwn-auth-utils")
4735 (version "1.4.0")
4736 (source
4737 (origin
4738 (method git-fetch)
4739 (uri (git-reference
4740 (url "https://git.ligo.org/computing/software/igwn-auth-utils")
4741 (commit version)))
4742 (file-name (git-file-name name version))
4743 (sha256
4744 (base32 "11h8a3sxlhy226gilprnm55745x8bxxvp927j6fbi5daga8rcpdb"))))
4745 (build-system pyproject-build-system)
4746 (arguments
4747 (list
4748 ;; tests: 112 passed, 1 skipped, 1 deselected
4749 #:test-flags
4750 ;; Failed: DID NOT RAISE <class 'netrc.NetrcParseError'>
4751 #~(list (string-append "--deselect=igwn_auth_utils/tests/"
4752 "test_requests.py"
4753 "::test_get_netrc_auth_permissions"))
4754 #:phases
4755 #~(modify-phases %standard-phases
4756 (add-after 'unpack 'relax-dependencies
4757 (lambda _
4758 (substitute* "pyproject.toml"
4759 (("cryptography >=44.0.1") "cryptography >=44.0.0")))))))
4760 (native-inputs
4761 (list python-gssapi
4762 python-htgettoken
4763 python-pytest
4764 python-requests-mock
4765 python-setuptools
4766 python-setuptools-scm))
4767 (propagated-inputs
4768 (list python-cryptography
4769 python-requests
4770 python-safe-netrc
4771 python-scitokens))
4772 (home-page "https://rtd.igwn.org/projects/igwn-auth-utils/en/stable/")
4773 (synopsis "Authorisation utilities for IGWN")
4774 (description
4775 "This package provides a Python library functions to simplify using
4776@url{https://www.ligo.org/, IGWN} authorisation credentials.")
4777 (license license:bsd-3)))
4778
4779(define-public python-jiter
4780 (package
4781 (name "python-jiter")
4782 (version "0.15.0")
4783 (source
4784 (origin
4785 (method git-fetch)
4786 (uri (git-reference
4787 (url "https://github.com/pydantic/jiter/")
4788 (commit (string-append "v" version))))
4789 (file-name (git-file-name name version))
4790 (sha256
4791 (base32 "1z2ljacsc64yykkxvjnq6rq4z56xwr8jhcw02ckv6b85kc66x63p"))))
4792 (build-system pyproject-build-system)
4793 (arguments
4794 (list
4795 #:imported-modules (append %cargo-build-system-modules
4796 %pyproject-build-system-modules)
4797 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
4798 (guix build pyproject-build-system)
4799 (guix build utils))
4800 #:phases
4801 #~(modify-phases %standard-phases
4802 (add-after 'unpack 'prepare-cargo-build-system
4803 (lambda args
4804 (for-each (lambda (phase)
4805 (format #t "Running cargo phase: ~a~%" phase)
4806 (apply (assoc-ref cargo:%standard-phases phase)
4807 #:cargo-target #$(cargo-triplet)
4808 args))
4809 '(prepare-rust-crates
4810 unpack-rust-crates
4811 configure
4812 check-for-pregenerated-files
4813 patch-cargo-checksums))))
4814 (add-after 'prepare-cargo-build-system 'chdir
4815 (lambda _
4816 (chdir "crates/jiter-python"))))))
4817 (native-inputs
4818 (append (list maturin
4819 python-dirty-equals
4820 python-pytest
4821 rust
4822 `(,rust "cargo"))
4823 (or (and=> (%current-target-system)
4824 (compose list make-rust-sysroot))
4825 '())))
4826 (inputs (cargo-inputs 'jiter))
4827 (home-page "https://github.com/pydantic/jiter/")
4828 (synopsis "Iterable JSON parser")
4829 (description
4830 "This package provides a fast Python iterable JSON parser, backed by Rust
4831libraries.")
4832 (license license:bsd-3)))
4833
4834(define-public python-justhtml
4835 (package
4836 (name "python-justhtml")
4837 (version "1.13.0")
4838 (source
4839 (origin
4840 (method git-fetch)
4841 (uri (git-reference
4842 (url "https://github.com/emilstenstrom/justhtml")
4843 (commit (string-append "v" version))))
4844 (file-name (git-file-name name version))
4845 (sha256
4846 (base32 "1hy5w3lr08sj3pivs46nnlfsvrd9ynmicxcrjk4sxbpg7411lyj5"))))
4847 (build-system pyproject-build-system)
4848 (native-inputs
4849 (list python-hatchling))
4850 (home-page "https://github.com/emilstenstrom/justhtml")
4851 (synopsis "Pure Python HTML5 parser")
4852 (description
4853 "JustHTML is a pure Python HTML5 parser. It has a simple API and does
4854not require C extensions or system dependencies.")
4855 (license license:expat)))
4856
4857(define-public python-hf-xet
4858 (package
4859 (name "python-hf-xet")
4860 (version "1.5.1")
4861 (source
4862 (origin
4863 (method git-fetch)
4864 (uri (git-reference
4865 (url "https://github.com/huggingface/xet-core")
4866 (commit (string-append "v" version))))
4867 (file-name (git-file-name name version))
4868 (sha256
4869 (base32 "0bczy0a8g7fnscpz2plq2pq0b8vapx9q5sny13rs2fa04ypq992f"))
4870 (modules '((guix build utils)))
4871 (snippet #~(for-each delete-file
4872 (find-files "." "Cargo\\.lock$")))))
4873 (build-system pyproject-build-system)
4874 (arguments
4875 (list
4876 #:imported-modules (append %cargo-build-system-modules
4877 %pyproject-build-system-modules)
4878 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
4879 (guix build pyproject-build-system)
4880 (guix build utils))
4881 #:phases
4882 #~(modify-phases %standard-phases
4883 (add-after 'unpack 'prepare-cargo-build-system
4884 (lambda args
4885 (for-each (lambda (phase)
4886 (format #t "Running cargo phase: ~a~%" phase)
4887 (apply (assoc-ref cargo:%standard-phases phase)
4888 #:cargo-target #$(cargo-triplet)
4889 args))
4890 '(prepare-rust-crates
4891 unpack-rust-crates
4892 configure
4893 check-for-pregenerated-files
4894 patch-cargo-checksums))))
4895 (add-after 'prepare-cargo-build-system 'chdir
4896 (lambda _
4897 (chdir "hf_xet"))))))
4898 (native-inputs
4899 (append (list maturin
4900 python-pytest
4901 rust
4902 `(,rust "cargo"))
4903 (or (and=> (%current-target-system)
4904 (compose list make-rust-sysroot))
4905 '())))
4906 (inputs (cargo-inputs 'hf_xet))
4907 (home-page "https://github.com/huggingface/xet-core")
4908 (synopsis "Transfer large files with the Hugging Face Hub")
4909 (description
4910 "This package enables @code{python-huggingface-hub} to utilize xet
4911storage for uploading and downloading to HF Hub. Xet storage provides
4912chunk-based deduplication, efficient storage/retrieval with local disk
4913caching, and backwards compatibility with Git LFS. This library is not meant
4914to be used directly, and is instead intended to be used from
4915@code{python-huggingface-hub}.")
4916 (license license:asl2.0)))
4917
4918(define-public python-huggingface-hub
4919 (package
4920 (name "python-huggingface-hub")
4921 (version "0.36.2")
4922 (source
4923 (origin
4924 (method git-fetch)
4925 (uri (git-reference
4926 (url "https://github.com/huggingface/huggingface_hub")
4927 (commit (string-append "v" version))))
4928 (file-name (git-file-name name version))
4929 (sha256
4930 (base32 "0hgdkfp7472sp0fjm5mwsx2rdlbr2ms8mzfzs0zr501gdwr7jjki"))))
4931 (build-system pyproject-build-system)
4932 (arguments
4933 (list
4934 #:test-flags
4935 ;; We don't have sentence_transformers...
4936 '(list "--ignore=contrib/sentence_transformers/test_sentence_transformers.py"
4937 ;; ...nor do we have InquirerPy...
4938 "--ignore=tests/test_command_delete_cache.py"
4939 ;; ...or timm...
4940 "--ignore=contrib/timm/test_timm.py"
4941 ;; ...or spacy_huggingface_hub
4942 "--ignore=contrib/spacy/test_spacy.py"
4943 ;; These all require internet access
4944 "--ignore=tests/test_cache_no_symlinks.py"
4945 "--ignore=tests/test_cache_layout.py"
4946 "--ignore=tests/test_commit_scheduler.py"
4947 "--ignore=tests/test_file_download.py"
4948 "--ignore=tests/test_hf_api.py"
4949 "--ignore=tests/test_hf_file_system.py"
4950 "--ignore=tests/test_inference_api.py"
4951 "--ignore=tests/test_inference_async_client.py"
4952 "--ignore=tests/test_inference_client.py"
4953 "--ignore=tests/test_inference_text_generation.py"
4954 "--ignore=tests/test_login_utils.py"
4955 "--ignore=tests/test_offline_utils.py"
4956 "--ignore=tests/test_repocard.py"
4957 "--ignore=tests/test_repository.py"
4958 "--ignore=tests/test_snapshot_download.py"
4959 "--ignore=tests/test_utils_cache.py"
4960 "--ignore=tests/test_utils_git_credentials.py"
4961 "--ignore=tests/test_utils_http.py"
4962 "--ignore=tests/test_utils_pagination.py"
4963 "--ignore=tests/test_webhooks_server.py"
4964 "-k" (string-append
4965 "not test_push_to_hub"
4966 " and not test_from_pretrained_model_id_only"
4967 " and not test_from_pretrained_model_id_and_revision"
4968 ;; These all require internet access
4969 " and not test_auth"
4970 " and not test_oauth"
4971 " and not test_utils_sha"
4972 " and not test_inference_providers"
4973 " and not test_xet"))
4974 #:phases
4975 '(modify-phases %standard-phases
4976 (add-before 'check 'pre-check
4977 ;; Some tests need to write to HOME.
4978 (lambda _ (setenv "HOME" "/tmp"))))))
4979 (propagated-inputs
4980 (list python-filelock
4981 python-fsspec
4982 python-hf-xet
4983 python-packaging
4984 python-pyyaml
4985 python-requests
4986 python-tqdm
4987 python-typing-extensions))
4988 (native-inputs
4989 (list python-aiohttp
4990 python-fastapi
4991 python-jedi
4992 python-jinja2
4993 python-numpy
4994 python-pillow
4995 python-pydantic
4996 python-pytest
4997 python-pytest-asyncio
4998 python-pytest-env
4999 python-pytest-mock
5000 python-pytest-rerunfailures
5001 python-pytest-vcr
5002 python-pytest-xdist
5003 python-setuptools
5004 python-types-requests
5005 python-types-toml
5006 python-types-urllib3
5007 python-typing-extensions
5008 python-urllib3))
5009 (home-page "https://huggingface.co/docs/huggingface_hub/")
5010 (synopsis "Client library for accessing the huggingface.co hub")
5011 (description
5012 "This package provides a client library to download and publish models,
5013datasets and other repos on the @url{huggingface.co} hub.")
5014 (license license:asl2.0)))
5015
5016(define-public python-kubernetes
5017 (package
5018 (name "python-kubernetes")
5019 (version "35.0.0")
5020 (source
5021 (origin
5022 (method url-fetch)
5023 (uri (pypi-uri "kubernetes" version))
5024 (sha256
5025 (base32 "1vh9bzq175fzv9av3v37lcfh37yzss2d9vxrb0a84fa2ji2d601x"))))
5026 (build-system pyproject-build-system)
5027 (arguments
5028 (list
5029 #:test-flags
5030 #~(list
5031 ;; The following tests expect a local running Kubernetes cluster.
5032 "--ignore=kubernetes/e2e_test"
5033 "--ignore=kubernetes/dynamic")))
5034 (native-inputs
5035 (list python-pytest
5036 python-setuptools))
5037 (propagated-inputs
5038 (list python-certifi
5039 python-dateutil
5040 python-durationpy
5041 python-google-auth
5042 python-pyyaml
5043 python-requests
5044 python-requests-oauthlib
5045 python-six ;XXX: hard dependency
5046 python-urllib3
5047 python-websocket-client))
5048 (home-page "https://github.com/kubernetes-client/python")
5049 (synopsis "Python client for Kubernetes")
5050 (description
5051 "This package provides an official Python client library for
5052@url{http://kubernetes.io, Kubernetes}.")
5053 (license license:asl2.0)))
5054
5055(define-public python-lazr-restfulclient
5056 (package
5057 (name "python-lazr-restfulclient")
5058 (version "0.14.6")
5059 (source
5060 (origin
5061 (method url-fetch)
5062 (uri (pypi-uri "lazr.restfulclient" version))
5063 (sha256
5064 (base32 "1nzzmp9aaaxh25jy3wm71cpf9dfw56s4g303c8a3nij874fjmwa3"))))
5065 (build-system pyproject-build-system)
5066 (arguments
5067 (list
5068 #:phases
5069 #~(modify-phases %standard-phases
5070 ;; Disable part of the test suite to avoid the lazr.authentication
5071 ;; requirement, which requires 'oauth', a Python 2 only library.
5072 (add-after 'unpack 'remove-some-checks
5073 (lambda _
5074 (with-directory-excursion "src/lazr/restfulclient/tests"
5075 (for-each delete-file '("test_oauth.py" "test_docs.py")))
5076 (substitute* "setup.py"
5077 (("\"(oauth|lazr\\.(authentication|restful>=0\\.11\\.0))\",")
5078 ""))))
5079 (replace 'check
5080 (lambda* (#:key tests? #:allow-other-keys)
5081 (if tests?
5082 (invoke "zope-testrunner" "--test-path=src")
5083 (format #t "test suite not run~%")))))))
5084 (native-inputs
5085 (list python-setuptools
5086 python-testtools
5087 python-wheel
5088 python-wsgi-intercept
5089 python-zope-testrunner))
5090 (propagated-inputs
5091 (list python-distro
5092 python-httplib2
5093 python-oauthlib
5094 python-pyparsing
5095 python-setuptools
5096 python-six
5097 python-wadllib))
5098 (home-page "https://launchpad.net/lazr.restfulclient")
5099 (synopsis "Web client Python library extending wadlib")
5100 (description "This package provides a programmable client library that
5101adds functionality on top of @code{wadlib}.")
5102 (license license:lgpl3+)))
5103
5104(define-public python-launchpadlib
5105 (package
5106 (name "python-launchpadlib")
5107 (version "2.1.0")
5108 (source
5109 (origin
5110 (method url-fetch)
5111 (uri (pypi-uri "launchpadlib" version))
5112 (sha256
5113 (base32 "0br4j76l83lvyrhm8psml9cqmdsn65rx48w1q1a0s1bmpf85ihml"))))
5114 (build-system pyproject-build-system)
5115 (arguments
5116 (list #:phases #~(modify-phases %standard-phases
5117 (add-before 'check 'set-home
5118 (lambda _
5119 ;; Tests require a writable home.
5120 (setenv "HOME" "/tmp"))))))
5121 (propagated-inputs
5122 (list python-httplib2 python-lazr-restfulclient python-lazr-uri))
5123 (native-inputs (list python-pytest python-testresources python-wadllib
5124 python-setuptools python-wheel))
5125 (home-page "https://documentation.ubuntu.com/launchpad")
5126 (synopsis "Python client library for Launchpad's web service")
5127 (description "@code{launchpadlib} is a Python library that allows
5128scripting Launchpad via its the web service API.")
5129 (license license:lgpl3+)))
5130
5131(define-public python-lazr-uri
5132 (package
5133 (name "python-lazr-uri")
5134 (version "1.0.7")
5135 (source
5136 (origin
5137 (method url-fetch)
5138 (uri (pypi-uri "lazr_uri" version))
5139 (sha256
5140 (base32 "1vm34pw8fksc6m8fnqwh215sqdlw546cxcdga93i2l746grzc37d"))))
5141 (build-system pyproject-build-system)
5142 (arguments
5143 (list
5144 #:phases
5145 #~(modify-phases %standard-phases
5146 (replace 'check
5147 (lambda* (#:key tests? #:allow-other-keys)
5148 (if tests?
5149 (invoke "zope-testrunner" "--test-path=src")
5150 (format #t "test suite not run~%")))))))
5151 (native-inputs (list python-setuptools python-zope-testrunner))
5152 (home-page "https://launchpad.net/lazr.uri")
5153 (synopsis "Python URI manipulation library")
5154 (description "This Python package provides a self-contained, easily
5155reusable library for parsing, manipulating, and generating URIs.")
5156 (license license:lgpl3)))
5157
5158(define-public python-ldaptor
5159 (package
5160 (name "python-ldaptor")
5161 (version "21.2.0")
5162 (source
5163 (origin
5164 (method url-fetch)
5165 (uri (pypi-uri "ldaptor" version))
5166 (sha256
5167 (base32 "0n53czn5pyh8923y282spdb7xc8c9rhn0n43bczanjjx6wcynjcc"))))
5168 (build-system pyproject-build-system)
5169 (arguments
5170 (list
5171 #:test-flags
5172 #~(list "-m" "twisted.trial"
5173 (string-append "-j" (number->string (parallel-job-count)))
5174 "ldaptor")
5175 #:phases
5176 #~(modify-phases %standard-phases
5177 (add-after 'unpack 'python-3.12-patch
5178 (lambda _
5179 (substitute* "ldaptor/config.py"
5180 (("SafeConfigParser")
5181 "ConfigParser"))))
5182 (add-before 'check 'disable-failing-tests
5183 (lambda _
5184 ;; Testing with Twisted 22.4 results in infinite loop creating
5185 ;; temporary config files, see
5186 ;; <https://github.com/twisted/ldaptor/issues/238>.
5187 (delete-file "ldaptor/test/test_config.py")))
5188 (replace 'check
5189 (lambda* (#:key tests? test-flags #:allow-other-keys)
5190 (when tests?
5191 (apply invoke "python" test-flags)))))))
5192 (native-inputs
5193 (list python-setuptools
5194 python-wheel))
5195 (propagated-inputs
5196 (list python-passlib
5197 python-pyopenssl
5198 python-service-identity ; to pass sanity check, for Twisted[tls]
5199 python-pyparsing
5200 python-twisted
5201 python-zope-interface))
5202 (home-page "https://github.com/twisted/ldaptor")
5203 (synopsis "Pure-Python Twisted library for LDAP")
5204 (description
5205 "This package provides a Python Twisted library for LDAP, which key
5206feaatures are:
5207@itemize
5208@item LDAP client logic
5209@item separately-accessible LDAP and BER protocol message generation/parsing
5210@item ASCII-format LDAP filter generation and parsing
5211@item LDIF format data generation
5212@item Samba password changing logic
5213@end itemize")
5214 (license license:expat)))
5215
5216(define-public python-legacy-cgi
5217 (package
5218 (name "python-legacy-cgi")
5219 (version "2.6.1")
5220 (source
5221 (origin
5222 (method url-fetch)
5223 (uri (pypi-uri "legacy_cgi" version))
5224 (sha256
5225 (base32 "0hksizyq7awmwh3337zy0rmj47x6b5igzam6ffj74gbwfjfakbgj"))))
5226 (build-system pyproject-build-system)
5227 (native-inputs (list python-poetry-core python-pytest))
5228 (home-page "https://github.com/jackrosenthal/legacy-cgi")
5229 (synopsis "Fork of the legacy standard library cgi and cgitb modules")
5230 (description
5231 "This is a fork of the standard library modules @code{cgi} and
5232@code{cgitb}. They are slated to be removed from the Python standard library
5233in Python 3.13 by PEP-594.")
5234 (license license:psfl)))
5235
5236(define-public python-librouteros
5237 (package
5238 (name "python-librouteros")
5239 (version "4.0.0")
5240 (source
5241 (origin
5242 (method git-fetch)
5243 (uri (git-reference
5244 (url "https://github.com/luqasz/librouteros")
5245 (commit version)))
5246 (file-name (git-file-name name version))
5247 (sha256
5248 (base32 "0in952b2idb5j8v6sxfm21gqbr5i5776w5ir0hdsxjrl2f29305v"))))
5249 (build-system pyproject-build-system)
5250 (arguments
5251 (list
5252 #:build-backend "hatchling.build"
5253 #:test-flags
5254 #~(list "tests/unit")))
5255 (native-inputs
5256 (list python-hatchling
5257 python-pytest
5258 python-pytest-asyncio
5259 python-stamina))
5260 (home-page "https://github.com/luqasz/librouteros")
5261 (synopsis "Python implementation of MikroTik RouterOS API")
5262 (description
5263 "This package implements MikroTik's @code{RouterOS} API.")
5264 (license license:gpl2+)))
5265
5266(define-public python-litestar
5267 (package
5268 (name "python-litestar")
5269 (version "2.24.0")
5270 (source
5271 (origin
5272 (method git-fetch)
5273 (uri (git-reference
5274 (url "https://github.com/litestar-org/litestar")
5275 (commit (string-append "v" version))))
5276 (file-name (git-file-name name version))
5277 (sha256
5278 (base32 "0yg49qjhhq2vv6qnn4b1sizp71vjl2qd16j44370n1af6fxzfssa"))))
5279 (build-system pyproject-build-system)
5280 (arguments
5281 (list
5282 ;; tests: 3332 passed, 45 skipped, 1 xfailed, 8 warnings, 3 rerun
5283 #:test-flags
5284 #~(list "--numprocesses" (number->string (parallel-job-count))
5285 "--timeout=10"
5286 "--reruns=3"
5287 "--ignore=tests/e2e/"
5288 "--ignore=tests/examples/"
5289 "--ignore=tests/unit/test_middleware/"
5290 "--ignore=tests/unit/test_plugins/"
5291 ;; Tests hang.
5292 "--ignore=tests/unit/test_testing/test_sub_client/"
5293 ;; Tests miss optional dependencies.
5294 "--ignore=tests/unit/test_app.py"
5295 "--ignore=tests/unit/test_channels/test_backends.py"
5296 "--ignore=tests/unit/test_contrib/test_minijinja.py"
5297 "--ignore=tests/unit/test_contrib/test_opentelemetry.py"
5298 "--ignore=tests/unit/test_contrib/test_prometheus.py"
5299 "--ignore=tests/unit/test_contrib/test_sqlalchemy.py"
5300 "--ignore=tests/unit/test_dto/test_factory/test_integration.py"
5301 "--ignore=tests/unit/test_repository/test_generic_mock_repository.py"
5302 "--ignore=tests/unit/test_template/test_built_in.py"
5303 "--ignore=tests/unit/test_template/test_builtin_functions.py"
5304 "--ignore=tests/unit/test_template/test_context.py"
5305 "--ignore=tests/unit/test_template/test_csrf_token.py"
5306 "--ignore=tests/unit/test_template/test_template.py"
5307 "--ignore=tests/unit/test_testing/test_test_client.py"
5308 ;; Tests require Docker.
5309 "--ignore=tests/docker_service_fixtures.py"
5310 ;; XXX: Tests need running Redis, PostgreSQL and Valkey.
5311 "--ignore=tests/unit/test_stores.py"
5312 "--ignore=tests/unit/test_channels/test_plugin.py"
5313 ;; Assert 'export namespace API.
5314 (string-append "--deselect=tests/unit/test_openapi/"
5315 "test_typescript_converter/"
5316 "test_converter.py"
5317 "::test_openapi_to_typescript_converter")
5318 ;; Tests fail find correct version or on deprecation warnings.
5319 #$@(map (lambda (ls) (string-append "--deselect=tests/unit/"
5320 (string-join ls "::")))
5321 '(("test_cli/test_suggestions.py"
5322 "test_suggest_version")
5323 ("test_connection/test_request.py"
5324 "test_request_headers")
5325 ("test_connection/test_websocket.py"
5326 "test_websocket_headers")
5327 ("test_deprecations.py"
5328 "test_contrib_minijnja_deprecation")
5329 ("test_deprecations.py"
5330 "test_minijinja_from_state_deprecation")))
5331 "tests")))
5332 (native-inputs
5333 (list python-aiosqlite
5334 python-asyncpg
5335 ;; python-beanie ;not packaged yet in Guix
5336 python-beautifulsoup4
5337 python-fsspec
5338 python-hatchling
5339 python-httpx-sse
5340 python-psutil
5341 python-psycopg
5342 python-pytest
5343 python-pytest-asyncio
5344 python-pytest-lazy-fixtures
5345 python-pytest-mock
5346 python-pytest-rerunfailures
5347 python-pytest-timeout
5348 python-pytest-xdist
5349 python-starlette
5350 python-time-machine-2
5351 python-trio))
5352 (propagated-inputs
5353 (list python-anyio
5354 python-click
5355 python-httpx
5356 python-litestar-htmx
5357 python-msgspec
5358 python-multidict
5359 python-multipart/defnull
5360 python-polyfactory
5361 python-pyyaml
5362 python-rich
5363 python-rich-click
5364 python-sniffio
5365 python-typing-extensions
5366 ;; [optional]
5367 python-advanced-alchemy
5368 python-annotated-types
5369 python-attrs
5370 python-brotli
5371 python-cryptography
5372 python-email-validator
5373 python-jinja2
5374 python-jsbeautifier
5375 python-mako
5376 ;; python-minijinja ;not packaged yet in Guix
5377 ;; python-opentelemetry-instrumentation-asgi
5378 python-opentelemetry-sdk
5379 python-piccolo
5380 python-pydantic
5381 python-pydantic-extra-types
5382 python-pyjwt
5383 python-redis
5384 python-structlog
5385 python-valkey
5386 python-uvicorn))
5387 (home-page "https://litestar.dev/")
5388 (synopsis "Light ASGI framework")
5389 (description
5390 "Litestar is a powerful,flexible yet opinionated ASGI framework, focused
5391on building APIs. It offers high-performance data validation, dependency
5392injection, first-class ORM integration, authorization primitives, a rich
5393plugin API, middleware, and much more that's needed to get applications up and
5394running.")
5395 (license license:expat)))
5396
5397;; A bare minimal package, mainly to use in tests and reduce closure size.
5398;; Tests are left out in the main package to slim down native-inputs and
5399;; propagated-inputs.
5400(define-public python-litestar-minimal
5401 (package/inherit python-litestar
5402 (name "python-litestar-minimal")
5403 (arguments (list #:tests? #f))
5404 (native-inputs
5405 (list python-hatchling))
5406 (propagated-inputs
5407 (list python-anyio
5408 python-click
5409 python-httpx
5410 python-litestar-htmx
5411 python-msgspec
5412 python-multidict
5413 python-multipart/defnull
5414 python-polyfactory
5415 python-pyyaml
5416 python-rich
5417 python-rich-click
5418 python-sniffio
5419 python-typing-extensions))))
5420
5421(define-public python-litestar-htmx
5422 (package
5423 (name "python-litestar-htmx")
5424 (version "0.5.0")
5425 (source
5426 (origin
5427 (method git-fetch)
5428 (uri (git-reference
5429 (url "https://github.com/litestar-org/litestar-htmx")
5430 (commit (string-append "v" version))))
5431 (file-name (git-file-name name version))
5432 (sha256
5433 (base32 "0brz2w2xk67v69rrj0cj0yd76x152vkyflq5cb6x3km2xn7cdgqw"))))
5434 (build-system pyproject-build-system)
5435 (arguments (list #:tests? #f)) ;cycles with python-litestar
5436 (native-inputs (list python-hatchling))
5437 (home-page "https://github.com/litestar-org/litestar-htmx")
5438 (synopsis "Litestar plugin for HTMX")
5439 (description
5440 "This package provides @url{https://htmx.org/, HTMX} Integration for
5441Litestar.")
5442 (license license:expat)))
5443
5444(define-public python-multipart/defnull
5445 (package
5446 (name "python-multipart-defnull")
5447 (version "2.0.1")
5448 (source
5449 (origin
5450 (method git-fetch)
5451 (uri (git-reference
5452 (url "https://github.com/defnull/multipart")
5453 (commit (string-append "v" version))))
5454 (file-name (git-file-name name version))
5455 (sha256
5456 (base32 "1kga8h03rk44nipks2dal9lrs455alfdh4rl1dmpr8q1l8fkcnia"))))
5457 (build-system pyproject-build-system)
5458 (native-inputs (list python-flit-core python-pytest))
5459 (home-page "https://multipart.readthedocs.io/")
5460 (synopsis "Multipart/form-data parser for Python")
5461 (description
5462 "This package provides a fast incremental non-blocking parser for
5463multipart/form-data [HTML5, @url{https://www.rfc-editor.org/rfc/rfc7578,
5464RFC7578}], as well as blocking alternatives for easier use in WSGI or CGI
5465applications:
5466
5467@itemize
5468@item PushMultipartParser: Fast SansIO (incremental, non-blocking) parser
5469suitable for ASGI, asyncio and other IO, time or memory constrained
5470environments.
5471
5472@item MultipartParser: Streaming parser that reads from a byte stream and
5473yields memory- or disk-buffered MultipartPart instances.
5474
5475@item WSGI Helper: High-level functions and containers for WSGI or CGI
5476applications with support for both multipart and urlencoded form submissions.
5477@end itemize
5478
5479It is hosted in PyPI as @url{https://pypi.org/project/multipart/,
5480multipart}.")
5481 (license license:expat)))
5482
5483(define-public python-opentelemetry-api
5484 (package
5485 (name "python-opentelemetry-api")
5486 (version "1.37.0")
5487 (source
5488 (origin
5489 (method url-fetch)
5490 (uri (pypi-uri "opentelemetry_api" version))
5491 (sha256
5492 (base32 "19yr3hfwdc9sv8df4vydxcsxnpld3xi57siq4w8xanrm42qka1sl"))))
5493 (build-system pyproject-build-system)
5494 (propagated-inputs (list python-importlib-metadata
5495 python-typing-extensions))
5496 (native-inputs (list python-hatchling
5497 python-opentelemetry-test-utils-bootstrap))
5498 (home-page "https://opentelemetry.io/docs/languages/python/")
5499 (synopsis "OpenTelemetry Python API")
5500 (description "@code{OpenTelemetry} Python API.")
5501 (license license:asl2.0)))
5502
5503(define-public python-opentelemetry-api-bootstrap
5504 (hidden-package
5505 (package/inherit python-opentelemetry-api
5506 (name "python-opentelemetry-api-bootstrap")
5507 (arguments
5508 (list
5509 #:tests? #f))
5510 (native-inputs (list python-hatchling)))))
5511
5512(define-public python-opentelemetry-sdk
5513 (package
5514 (name "python-opentelemetry-sdk")
5515 (version "1.37.0")
5516 (source
5517 (origin
5518 (method url-fetch)
5519 (uri (pypi-uri "opentelemetry_sdk" version))
5520 (sha256
5521 (base32 "19fx8vf35kcss43i17zqngqhmglb36dnddasbdvfsgcm22f0i3nc"))))
5522 (build-system pyproject-build-system)
5523 (propagated-inputs (list python-opentelemetry-api
5524 python-opentelemetry-semantic-conventions
5525 python-typing-extensions))
5526 (native-inputs (list python-hatchling
5527 python-opentelemetry-test-utils-bootstrap
5528 python-pytest))
5529 (home-page "https://opentelemetry.io/docs/languages/python/")
5530 (synopsis "OpenTelemetry Python SDK")
5531 (description "@code{OpenTelemetry} Python SDK.")
5532 (license license:asl2.0)))
5533
5534(define-public python-opentelemetry-sdk-bootstrap
5535 (hidden-package
5536 (package/inherit python-opentelemetry-sdk
5537 (name "python-opentelemetry-sdk-bootstrap")
5538 (arguments (list #:tests? #f))
5539 (propagated-inputs (list python-opentelemetry-api-bootstrap
5540 python-opentelemetry-semantic-conventions-bootstrap))
5541 (native-inputs (list python-hatchling)))))
5542
5543(define-public python-opentelemetry-semantic-conventions
5544 (package
5545 (name "python-opentelemetry-semantic-conventions")
5546 (version "0.58b0")
5547 (source
5548 (origin
5549 (method url-fetch)
5550 (uri (pypi-uri "opentelemetry_semantic_conventions" version))
5551 (sha256
5552 (base32 "098czakcawikaspl46vy6vickw80mm2bnrspflrw8ya24r8nzm3b"))))
5553 (build-system pyproject-build-system)
5554 (propagated-inputs (list python-opentelemetry-api python-typing-extensions))
5555 (native-inputs (list python-hatchling))
5556 (home-page "https://opentelemetry.io/docs/languages/python/")
5557 (synopsis "OpenTelemetry Semantic Conventions")
5558 (description "@code{OpenTelemetry} Semantic Conventions.")
5559 (license license:asl2.0)))
5560
5561(define-public python-opentelemetry-semantic-conventions-bootstrap
5562 (hidden-package
5563 (package/inherit python-opentelemetry-semantic-conventions
5564 (name "python-opentelemetry-semantic-conventions-bootstrap")
5565 (arguments
5566 (list
5567 #:tests? #f))
5568 (propagated-inputs (list python-opentelemetry-api-bootstrap
5569 python-typing-extensions)))))
5570
5571(define-public python-opentelemetry-test-utils
5572 (package
5573 (name "python-opentelemetry-test-utils")
5574 (version "0.58b0")
5575 (source
5576 (origin
5577 (method url-fetch)
5578 (uri (pypi-uri "opentelemetry_test_utils" version))
5579 (sha256
5580 (base32 "0xjp04zjn7m79xsda9wp79rqyzy2c10347s967vp7xvmndwwa0ds"))))
5581 (build-system pyproject-build-system)
5582 (arguments (list #:tests? #f)) ; No tests in the wheel.
5583 (propagated-inputs
5584 (list python-asgiref
5585 python-opentelemetry-api
5586 python-opentelemetry-sdk))
5587 (native-inputs (list python-hatchling))
5588 (home-page "https://opentelemetry.io/docs/languages/python/")
5589 (synopsis "Test utilities for OpenTelemetry unit tests")
5590 (description "Test utilities for @code{OpenTelemetry} unit tests.")
5591 (license license:asl2.0)))
5592
5593(define-public python-opentelemetry-test-utils-bootstrap
5594 (hidden-package
5595 (package/inherit python-opentelemetry-test-utils
5596 (name "python-opentelemetry-test-utils-bootstrap")
5597 (propagated-inputs
5598 (list python-asgiref
5599 python-opentelemetry-api-bootstrap
5600 python-opentelemetry-sdk-bootstrap)))))
5601
5602(define-public python-pathy
5603 (package
5604 (name "python-pathy")
5605 (version "0.11.0")
5606 (source
5607 (origin
5608 (method url-fetch)
5609 (uri (pypi-uri "pathy" version))
5610 (sha256
5611 (base32 "0vbhcfg8g74g90bzmdgxr1jyvwhadvlr2w9wyvs6xxwb1dmhwgdv"))))
5612 (build-system pyproject-build-system)
5613 (native-inputs
5614 (list python-mock
5615 python-pytest
5616 python-setuptools))
5617 (propagated-inputs
5618 (list python-pathlib-abc-for-python-pathy
5619 python-smart-open-6
5620 python-typer))
5621 (home-page "https://github.com/justindujardin/pathy")
5622 (synopsis "Path interface for local and cloud bucket storage")
5623 (description "Pathy is a python package (with type annotations) for
5624working with Cloud Bucket storage providers using a @code{pathlib} interface.
5625It provides @code{pathlib.Path} subclasses for local and cloud bucket
5626storage.")
5627 (license license:asl2.0)))
5628
5629(define-public python-portend
5630 (package
5631 (name "python-portend")
5632 (version "3.2.1")
5633 (source
5634 (origin
5635 (method url-fetch)
5636 (uri (pypi-uri "portend" version))
5637 (sha256
5638 (base32 "12b4ikxyv32n33mvm4brp74igl1mvw825x01sjvvs54y3yml17da"))))
5639 (build-system pyproject-build-system)
5640 ;; Do not test pyproject.toml with python-pytest-checkdocs as it tries to
5641 ;; download dependencies.
5642 (arguments
5643 '(#:test-flags '("-k" "not project")))
5644 (native-inputs
5645 (list python-pytest
5646 python-setuptools
5647 python-setuptools-scm))
5648 (propagated-inputs
5649 (list python-tempora))
5650 (home-page "https://github.com/jaraco/portend")
5651 (synopsis "Monitor TCP ports for bound or unbound states")
5652 (description
5653 "@code{python-portend} can be used to monitor TCP ports for bound or
5654unbound states. For example, waiting for a port to be occupied or freed
5655within a set timeout. @code{python-portend} can also be used directly from
5656the command line.")
5657 (license license:expat)))
5658
5659(define-public python-prawcore
5660 (package
5661 (name "python-prawcore")
5662 (version "4.0.0")
5663 (source
5664 (origin
5665 (method git-fetch)
5666 (uri (git-reference
5667 (url "https://github.com/praw-dev/prawcore")
5668 (commit (string-append "v" version))))
5669 (file-name (git-file-name name version))
5670 (sha256
5671 (base32 "1kqqv1n9bibxfgagbyd8vl0yzrd4lr58xl59swz5v70w0kfap5fm"))))
5672 (build-system pyproject-build-system)
5673 (arguments
5674 (list
5675 ;; This test fails with a str rather than a bytes-like object.
5676 #:test-flags #~(list "-k" "not test_request__service_unavailable")))
5677 (native-inputs
5678 (list nss-certs-for-test
5679 python-betamax
5680 python-betamax-matchers
5681 python-betamax-serializers
5682 python-hatchling
5683 python-mock
5684 python-pytest
5685 python-testfixtures
5686 python-vcrpy))
5687 (propagated-inputs
5688 (list python-requests))
5689 (synopsis "Core component of PRAW")
5690 (description "PRAWcore is a low-level communication layer used by PRAW.")
5691 (home-page "https://praw.readthedocs.io/en/latest/")
5692 (license license:bsd-2)))
5693
5694(define-public python-praw
5695 (package
5696 (name "python-praw")
5697 (version "8.0.2")
5698 (source
5699 (origin
5700 (method git-fetch)
5701 (uri (git-reference
5702 (url "https://github.com/praw-dev/praw")
5703 (commit (string-append "v" version))))
5704 (file-name (git-file-name name version))
5705 (sha256
5706 (base32 "15kwvkc6ag83p3mrfnq6ffyvbw4d3njx0dl0vv00y7724b2rpqxw"))))
5707 (build-system pyproject-build-system)
5708 (arguments
5709 (list #:test-flags
5710 #~(list "--ignore=tests/units/models"
5711 "--ignore=tests/integration/models"
5712 "--ignore=tests/unit/test_config.py"
5713 "--ignore=tests/integration/test_reddit.py")))
5714 (native-inputs
5715 (list nss-certs-for-test
5716 python-betamax
5717 python-betamax-matchers
5718 python-hatchling
5719 python-pytest
5720 python-vcrpy))
5721 (propagated-inputs
5722 (list python-defusedxml
5723 python-prawcore
5724 python-update-checker
5725 python-websocket-client))
5726 (synopsis "Python Reddit API Wrapper")
5727 (description "PRAW is a Python package that allows for simple access to
5728Reddit’s API. It aims to be easy to use and internally follows all of Reddit’s
5729API rules.")
5730 (home-page "https://praw.readthedocs.io/en/latest/")
5731 (license license:bsd-2)))
5732
5733(define-public python-frozenlist
5734 (package
5735 (name "python-frozenlist")
5736 (version "1.8.0")
5737 (source
5738 (origin
5739 (method git-fetch)
5740 (uri (git-reference
5741 (url "https://github.com/aio-libs/frozenlist")
5742 (commit (string-append "v" version))))
5743 (file-name (git-file-name name version))
5744 (sha256
5745 (base32 "0r1kxf5b562zrn04nl912i6a8y1fyc891l1284v0zj9llb97limy"))))
5746 ;; XXX: Without "wheel", the 'install phase can't find the wheel.
5747 (outputs (list "out" "wheel"))
5748 (build-system pyproject-build-system)
5749 ;; The configuration contains explicit early calls to pytest_cov.
5750 (arguments (list #:test-flags #~(list "-o" "addopts=''")))
5751 (native-inputs
5752 (list python-cython
5753 python-expandvars
5754 python-pytest
5755 python-setuptools
5756 python-tomli))
5757 (home-page "https://github.com/aio-libs/frozenlist")
5758 (synopsis "List-like data structure for Python")
5759 (description "@code{frozenlist.FrozenList} is a list-like structure which
5760implements @code{collections.abc.MutableSequence}. It can be made immutable
5761by calling @code{FrozenList.freeze}.")
5762 (license license:asl2.0)))
5763
5764(define-public python-httpauth
5765 (package
5766 (name "python-httpauth")
5767 (version "0.4.1")
5768 (source (origin
5769 (method url-fetch)
5770 (uri (pypi-uri "httpauth" version))
5771 (sha256
5772 (base32
5773 "1m6rwvivg61l3h34hf6p6gkqmr69sb1c4k5ha379nxq0p8bfgahb"))))
5774 (build-system pyproject-build-system)
5775 (native-inputs (list python-pytest python-setuptools python-wheel))
5776 (home-page "https://github.com/jonashaag/httpauth")
5777 (synopsis "WSGI HTTP Digest Authentication middleware")
5778 (description "@code{python-httpauth} is WSGI middleware that secures some/all
5779routes using HTTP Digest Authentication.")
5780 (license license:bsd-2)))
5781
5782(define-public python-publicsuffixlist
5783 (package
5784 (name "python-publicsuffixlist")
5785 (version "1.0.2.20250202")
5786 (source
5787 (origin
5788 (method url-fetch)
5789 (uri (pypi-uri "publicsuffixlist" version))
5790 (sha256
5791 (base32 "0llam7g7sv08lcfgy18iph8br8ldjmy2qbjaykc9pd3z4iisb0yd"))))
5792 (build-system pyproject-build-system)
5793 (arguments (list #:test-backend #~'unittest))
5794 (native-inputs (list python-setuptools))
5795 (home-page "https://github.com/ko-zu/psl")
5796 (synopsis "Public suffix list for Python")
5797 (description
5798 "This package provides an implementation of
5799@url{https://publicsuffix.org/, Public Suffix List } as Python library.
5800
5801Features:
5802@itemize
5803@item supports IDN (unicode and punycoded)
5804@item shipped with built-in PSL and an updater script
5805@item written in Pure Python with no library dependencies
5806@end itemize")
5807 (license license:mpl2.0)))
5808
5809(define-public python-pycognito
5810 (package
5811 (name "python-pycognito")
5812 (version "2024.5.1")
5813 (source
5814 (origin
5815 (method url-fetch)
5816 (uri (pypi-uri "pycognito" version))
5817 (sha256
5818 (base32 "1r1sq87spqcfgg17khgpqc2ga8m9nk10flg9h23drhy2k1kcc4g2"))))
5819 (build-system pyproject-build-system)
5820 (arguments
5821 ;; XXX: cycles with python-moto, bootstrap/minimal variant is required.
5822 (list #:tests? #f))
5823 (native-inputs
5824 (list python-setuptools))
5825 (propagated-inputs
5826 (list python-boto3
5827 python-envs
5828 python-pyjwt
5829 python-requests))
5830 (home-page "https://github.com/pvizeli/pycognito")
5831 (synopsis "Python library for using AWS Cognito")
5832 (description
5833 "This package provides a Python class to integrate Boto3's Cognito
5834client so it is easy to login users, with @acronym{Secure Remote Password,
5835SRP} support.")
5836 (license license:asl2.0)))
5837
5838(define-public python-pydap
5839 (package
5840 (name "python-pydap")
5841 (version "3.5.10")
5842 (source
5843 (origin
5844 (method git-fetch)
5845 (uri (git-reference
5846 (url "https://github.com/pydap/pydap")
5847 (commit version)))
5848 (file-name (git-file-name name version))
5849 (sha256
5850 (base32 "000b7jqjpx71miwxhbi07amyjyijq925x9x3paa7kzrr268klc2z"))))
5851 (build-system pyproject-build-system)
5852 (arguments
5853 (list
5854 ;; tests: 435 passed, 6 skipped
5855 #:test-flags
5856 ;; Tests need extra packaging.
5857 #~(list "--ignore=src/pydap/tests/test_wsgi_functions.py"
5858 "--ignore=src/pydap/tests/test_wsgi_ssf.py"
5859 ;; Network access is required.
5860 "--ignore=src/pydap/tests/test_client.py"
5861 "--ignore=src/pydap/tests/test_handlers_dap.py"
5862 "--ignore=src/pydap/tests/test_open_dap4_url.py"
5863 "--ignore=src/pydap/tests/test_virtualizarr.py")))
5864 (native-inputs
5865 (list nss-certs-for-test
5866 python-requests-mock
5867 python-pytest
5868 python-setuptools
5869 python-setuptools-scm
5870 python-webtest))
5871 (propagated-inputs
5872 (list python-beautifulsoup4
5873 python-jinja2
5874 python-lxml
5875 python-numpy
5876 python-requests
5877 python-requests-cache
5878 python-scipy
5879 python-webob
5880 ;; [optional]
5881 gunicorn
5882 python-docopt-ng
5883 ;; python-coards ;not packaged yet in Guix
5884 python-fastparquet
5885 ;; python-gsw ;not packaged yet in Guix
5886 python-netcdf4
5887 python-openpyxl
5888 python-pastedeploy
5889 python-werkzeug))
5890 (home-page "https://pydap.github.io/pydap/en/intro.html")
5891 (synopsis "Data Access Protocol implementation in Python")
5892 (description
5893 "This package provides a pure Python implementation of the Data Access
5894Protocol (DAP, aka OPeNDAP).")
5895 (license license:expat)))
5896
5897(define-public python-pyrate-limiter
5898 (package
5899 (name "python-pyrate-limiter")
5900 (version "4.5.0")
5901 (source
5902 (origin
5903 (method git-fetch)
5904 (uri (git-reference
5905 (url "https://github.com/vutran1710/PyrateLimiter")
5906 (commit (string-append "v" version))))
5907 (file-name (git-file-name name version))
5908 (sha256
5909 (base32 "1hl1zv8r87dcpw68772xmy7x7q5nsb5bgdgk0iz9cwa2i5pmfhsi"))))
5910 (build-system pyproject-build-system)
5911 (arguments
5912 (list
5913 #:test-flags
5914 #~(list "--retries=0"
5915 ;; These tests have fragile timing assumptions and may fail or
5916 ;; hang under load.
5917 ;; See: <https://github.com/vutran1710/PyrateLimiter#247>.
5918 #$@(map (lambda (test)
5919 (string-append "--deselect=tests/" test))
5920 '("test_bucket_all.py::test_bucket_leak[create_sqlite_bucket]"
5921 "test_bucket_all.py::test_bucket_flush[create_sqlite_bucket]"
5922 "test_bucket_all.py::test_bucket_waiting"
5923 "test_bucket_factory.py::test_factory_leak[create_sqlite_bucket]"
5924 "test_limiter.py::test_limiter_01"
5925 "test_multiprocessing.py::test_bucket_full"
5926 "test_multiprocessing.py::test_limiter_delay"
5927 ;; Covers the other test_mp_bucket variants as well.
5928 "test_multiprocessing.py::test_mp_bucket"
5929 "test_multiprocessing.py::test_sqlite_filelock_bucket"))
5930 ;; Keep the separate weight-zero factory test enabled.
5931 "-k" (string-append "not test_limiter_async_factory_get"
5932 " or test_limiter_async_factory_get_weight0"))
5933 #:phases
5934 #~(modify-phases %standard-phases
5935 (add-before 'build 'set-version
5936 (lambda _
5937 (substitute* "pyproject.toml"
5938 ((".*uv-dynamic-versioning>.*") "")
5939 (("source.*uv-dynamic-versioning.*") "source = 'vcs'"))))
5940 (add-before 'check 'start-test-services
5941 (lambda* (#:key tests? #:allow-other-keys)
5942 (when tests?
5943 (invoke "redis-server" "--daemonize" "yes")
5944 (let ((dbdir (string-append (getcwd) "/pgdata")))
5945 (invoke "initdb" "-D" dbdir "-A" "trust" "-U" "postgres")
5946 (invoke "pg_ctl" "-D" dbdir
5947 "-o" "-h 127.0.0.1 -p 5432 -k /tmp"
5948 "-l" (string-append dbdir "/server.log")
5949 "start"))))))))
5950 (native-inputs
5951 (list postgresql
5952 python-hatchling
5953 python-hatch-vcs
5954 python-pytest
5955 python-pytest-asyncio
5956 python-pytest-retry
5957 python-schedule
5958 redis))
5959 (propagated-inputs
5960 (list python-aiohttp
5961 python-filelock
5962 python-httpx
5963 python-httpx2
5964 python-psycopg
5965 python-psycopg-pool
5966 python-redis
5967 python-requests))
5968 (home-page "https://github.com/vutran1710/PyrateLimiter")
5969 (synopsis "Rate limiting for Python applications")
5970 (description
5971 "PyrateLimiter implements rate limiting using a leaky bucket algorithm,
5972with support for multiple limits and storage backends.")
5973 (license license:expat)))
5974
5975(define-public python-python3-saml
5976 (package
5977 (name "python-python3-saml")
5978 (version "1.16.0")
5979 (source
5980 (origin
5981 (method git-fetch)
5982 (uri (git-reference
5983 (url "https://github.com/SAML-Toolkits/python3-saml")
5984 (commit (string-append "v" version))))
5985 (file-name (git-file-name name version))
5986 (sha256
5987 (base32 "1isisymhk8zblj5942jfl0zq392q5fpjikx52nywvzb0m2dcc81b"))))
5988 (build-system pyproject-build-system)
5989 (arguments
5990 (list
5991 ;; 214 tests pass, 50 fail; many fail because of required Internet
5992 ;; access or because of assumptions about the location of test files.
5993 #:tests? #false))
5994 (native-inputs
5995 (list python-freezegun
5996 python-poetry-core))
5997 (inputs
5998 (list xmlsec-openssl))
5999 (propagated-inputs
6000 (list python-isodate
6001 python-lxml
6002 python-xmlsec))
6003 (home-page "https://github.com/SAML-Toolkits/python3-saml")
6004 (synopsis "Saml Python toolkit")
6005 (description
6006 "The SAML Python Toolkit lets you add SAML support to your Python
6007software.")
6008 (license license:expat)))
6009
6010(define-public python-ovh
6011 (package
6012 (name "python-ovh")
6013 (version "1.1.0")
6014 (source (origin
6015 (method url-fetch)
6016 (uri (pypi-uri "ovh" version))
6017 (sha256
6018 (base32
6019 "0ygniv12lixh9rvnjcd01gzbzk2b5xwcg2a59b7964a77dd9p3qh"))))
6020 (build-system pyproject-build-system)
6021 (arguments (list #:tests? #f)) ; XXX: tests require networking
6022 (propagated-inputs (list python-requests))
6023 (native-inputs (list python-setuptools))
6024 (home-page "https://api.ovh.com")
6025 (synopsis "Interact with OVHcloud APIs")
6026 (description "This package provides the official module to perform HTTP requests
6027to the OVHcloud APIs.")
6028 (license license:bsd-3)))
6029
6030(define-public python-pyzabbix
6031 (package
6032 (name "python-pyzabbix")
6033 (version "1.3.1")
6034 (source
6035 (origin
6036 (method git-fetch)
6037 (uri (git-reference
6038 (url "https://github.com/lukecyca/pyzabbix")
6039 (commit version)))
6040 (file-name (git-file-name name version))
6041 (sha256
6042 (base32 "1dbs3bz1mjlvlg46ikhg5j7agwni61ljlpiziknklv95yp29n86v"))))
6043 (build-system pyproject-build-system)
6044 (arguments
6045 (list #:test-flags #~(list "tests")))
6046 (native-inputs
6047 (list python-pytest
6048 python-requests-mock
6049 python-setuptools))
6050 (propagated-inputs
6051 (list python-packaging
6052 python-requests))
6053 (home-page "https://github.com/lukecyca/pyzabbix")
6054 (synopsis "Python interface to the Zabbix API")
6055 (description
6056 "@code{pyzabbix} is a Python module for working with the Zabbix API.")
6057 (license license:lgpl2.1+)))
6058
6059(define-public python-requests-cache
6060 (package
6061 (name "python-requests-cache")
6062 (version "1.3.2")
6063 (source
6064 (origin
6065 (method git-fetch)
6066 (uri (git-reference
6067 (url "https://github.com/requests-cache/requests-cache")
6068 (commit (string-append "v" version))))
6069 (file-name (git-file-name name version))
6070 (sha256
6071 (base32 "1yhvidmmd02c95i1hamyy34rb3wfzgzxil2k8ay1p4r4kv7pjada"))))
6072 (build-system pyproject-build-system)
6073 (arguments
6074 (list
6075 ;; tests: 429 passed, 1051 warnings
6076 #:test-flags
6077 #~(list "--numprocesses" (number->string (parallel-job-count))
6078 ;; These tests require access to external services, e.g. MongoDB
6079 ;; and Redis.
6080 "--ignore=tests/integration")
6081 #:phases
6082 #~(modify-phases %standard-phases
6083 (add-before 'check 'pre-check
6084 (lambda _
6085 ;; PermissionError: [Errno 13] Permission denied:
6086 ;; '/homeless-shelter'
6087 (setenv "HOME" "/tmp"))))))
6088 (native-inputs
6089 (list python-hatchling
6090 python-pytest
6091 python-pytest-rerunfailures
6092 python-pytest-xdist
6093 python-requests-mock
6094 python-responses
6095 python-rich
6096 python-tenacity
6097 python-time-machine
6098 python-timeout-decorator))
6099 (propagated-inputs
6100 (list python-attrs
6101 python-cattrs
6102 python-platformdirs
6103 python-requests
6104 python-url-normalize
6105 python-urllib3
6106 ;; [optional]
6107 python-boto3
6108 python-botocore
6109 python-itsdangerous
6110 python-orjson ;Python version < 3.14
6111 python-pymongo
6112 python-pyyaml
6113 python-redis
6114 python-ujson))
6115 (home-page "https://github.com/requests-cache/requests-cache")
6116 (synopsis "Persistent HTTP cache for Python requests")
6117 (description
6118 "This package provides a drop-in replacement for @code{requests.Session}
6119with caching offload to SQLite, Redis, MongoDB and AWS DynamoDB or save
6120responses as planin JSON/YAML file or save responses as plain JSON/YAML
6121files.")
6122 (license license:bsd-2)))
6123
6124(define-public python-requests-futures
6125 (package
6126 (name "python-requests-futures")
6127 (version "1.0.2")
6128 (source
6129 (origin
6130 (method url-fetch)
6131 (uri (pypi-uri "requests_futures" version))
6132 (sha256
6133 (base32 "1njqfjmd72l5f32jvcppg2afrvb0cd8angdwmq7q0vik81wvazkb"))))
6134 (build-system pyproject-build-system)
6135 (native-inputs
6136 (list python-greenlet
6137 python-pytest
6138 python-pytest-httpbin
6139 python-setuptools
6140 python-werkzeug))
6141 (propagated-inputs (list python-requests))
6142 (home-page "https://github.com/ross/requests-futures")
6143 (synopsis "Asynchronous Python HTTP for Humans")
6144 (description
6145 "This package provides and add-on the Python Requests HTTP library to run
6146code asynchronously.")
6147 (license license:asl2.0)))
6148
6149(define-public python-requests-ratelimiter
6150 (package
6151 (name "python-requests-ratelimiter")
6152 (version "0.10.0")
6153 (source
6154 (origin
6155 (method url-fetch)
6156 (uri (pypi-uri "requests_ratelimiter" version))
6157 (sha256
6158 (base32 "0cvs1rydmaca85508dcc5jz2klqnpld38v0s477mrakcckbph6lw"))))
6159 (build-system pyproject-build-system)
6160 (native-inputs
6161 (list python-hatchling
6162 python-pytest
6163 python-requests-cache
6164 python-requests-mock))
6165 (propagated-inputs
6166 (list python-pyrate-limiter
6167 python-requests))
6168 (home-page "https://github.com/JWCook/requests-ratelimiter")
6169 (synopsis "Rate limiting for Python Requests")
6170 (description
6171 "Requests-Ratelimiter adds per-host rate limiting to Python's Requests
6172library using PyrateLimiter.")
6173 (license license:expat)))
6174
6175(define-public python-requests-unixsocket
6176 (package
6177 (name "python-requests-unixsocket")
6178 (version "0.4.1")
6179 (source
6180 (origin
6181 (method git-fetch)
6182 (uri (git-reference
6183 (url "https://github.com/msabramo/requests-unixsocket")
6184 (commit (string-append "v" version))))
6185 (file-name (git-file-name name version))
6186 (sha256
6187 (base32 "1f0pi31xqzm3cdag4s4gpdj36x169jwc8ibqvcwqz6h9c0pklf3n"))))
6188 (build-system pyproject-build-system)
6189 (native-inputs
6190 (list python-pytest
6191 python-setuptools
6192 python-setuptools-scm
6193 python-waitress))
6194 (propagated-inputs
6195 (list python-requests))
6196 (home-page "https://github.com/msabramo/requests-unixsocket")
6197 (synopsis "Use requests to talk HTTP via a UNIX domain socket")
6198 (description
6199 "This package provides an extension to @code{requests} which let it talk
6200HTTP via a UNIX domain socket.")
6201 (license license:asl2.0)))
6202
6203(define-public python-s3path
6204 (package
6205 (name "python-s3path")
6206 (version "0.6.4")
6207 (source
6208 (origin
6209 (method url-fetch)
6210 (uri (pypi-uri "s3path" version))
6211 (sha256
6212 (base32 "1lp5243jjf9ngqmajgnfr1px1kmpkfmgh248xlqz0nkww4wcy1hh"))))
6213 (build-system pyproject-build-system)
6214 (arguments
6215 (list
6216 ;; XXX: All tests fail with error: fixture 's3_mock' not found.
6217 #:tests? #f))
6218 (native-inputs
6219 (list python-setuptools
6220 python-wheel))
6221 (propagated-inputs
6222 (list python-boto3
6223 python-smart-open))
6224 (home-page "https://github.com/liormizr/s3path")
6225 (synopsis "Pathlib extension for AWS S3 Service")
6226 (description
6227 "S3Path provide a Python convenient File-System/Path like interface for
6228AWS S3 Service using boto3 S3 resource as a driver.")
6229 (license license:asl2.0)))
6230
6231(define-public python-falcon
6232 (package
6233 (name "python-falcon")
6234 (version "4.0.2")
6235 (source
6236 (origin
6237 ;; Use git, as there are some test files missing from the PyPI release,
6238 ;; such as 'examples' directory.
6239 (method git-fetch)
6240 (uri (git-reference
6241 (url "https://github.com/falconry/falcon")
6242 (commit version)))
6243 (file-name (git-file-name name version))
6244 (sha256
6245 (base32
6246 "1zhyvfbz4c1bxd4vbsgk19dzih6kkzgin10lmsr32x3b4qgnwqxs"))))
6247 (build-system pyproject-build-system)
6248 (arguments
6249 (list
6250 #:test-flags
6251 '(list "-k" "not slow"
6252 "--ignore-glob=examples/*" "--ignore-glob=bench/*" "tests")
6253 #:phases
6254 '(modify-phases %standard-phases
6255 (add-before 'check 'pre-check
6256 (lambda _
6257 (setenv "FALCON_ASGI_WRAP_NON_COROUTINES" "Y")
6258 (setenv "FALCON_TESTING_SESSION" "Y")
6259 (setenv "PYTHONASYNCIODEBUG" "1")
6260 (setenv "HOME" "/tmp"))))))
6261 (propagated-inputs
6262 (list python-mimeparse))
6263 (native-inputs
6264 (list python-aiofiles
6265 python-cbor2
6266 python-cython ;for faster binaries
6267 python-fakeredis
6268 python-httpx
6269 python-mujson
6270 python-msgpack
6271 python-orjson
6272 python-pecan
6273 python-pillow
6274 python-pytest
6275 python-pytest-asyncio
6276 python-pyyaml
6277 python-rapidjson
6278 python-requests
6279 python-setuptools
6280 python-testtools
6281 python-ujson
6282 python-websockets
6283 python-wheel))
6284 (home-page "https://falconframework.org")
6285 (synopsis "Web framework for building APIs and application backends")
6286 (description "Falcon is a web API framework for building microservices,
6287application backends and higher-level frameworks. Among its features are:
6288@itemize
6289@item Optimized and extensible code base
6290@item Routing via URI templates and REST-inspired resource
6291classes
6292@item Access to headers and bodies through request and response
6293classes
6294@item Request processing via middleware components and hooks
6295@item Idiomatic HTTP error responses
6296@item Straightforward exception handling
6297@item Unit testing support through WSGI helpers and mocks
6298@item Compatible with both CPython and PyPy
6299@item Cython support for better performance when used with CPython
6300@end itemize")
6301 (license license:asl2.0)))
6302
6303(define-public python-falcon-cors
6304 (package
6305 (name "python-falcon-cors")
6306 (properties '((commit . "41e9f075e193c1f76b26c0a8c67ad6e87462dfa6")
6307 (revision . "0")))
6308 (version (git-version "1.1.7"
6309 (assoc-ref properties 'revision)
6310 (assoc-ref properties 'commit)))
6311 (source
6312 (origin
6313 (method git-fetch)
6314 (uri (git-reference
6315 (url "https://github.com/lwcolton/falcon-cors")
6316 (commit (assoc-ref properties 'commit))))
6317 (file-name (git-file-name name version))
6318 (sha256
6319 (base32 "0iqz1i1p5xr32n34j77p2a86jmrkg1w90d2wcmmy1mhi5mgdm5gx"))))
6320 (build-system pyproject-build-system)
6321 (arguments
6322 (list
6323 ;; XXX: The last commit's tests are incompatible with the more recent
6324 ;; version of python-falcon.
6325 #:tests? #f))
6326 (native-inputs
6327 (list python-falcon python-mock python-pynose python-setuptools))
6328 (home-page "https://github.com/lwcolton/falcon-cors")
6329 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
6330 (description
6331 "This middleware provides @dfn{cross-origin resource sharing} (CORS)
6332support for Falcon. It allows applying a specially crafted CORS object to the
6333incoming requests, enabling the ability to serve resources over a different
6334origin than that of the web application.")
6335 (license license:asl2.0)))
6336
6337(define-public python-furl
6338 (package
6339 (name "python-furl")
6340 (version "2.1.4")
6341 (source
6342 (origin
6343 (method url-fetch)
6344 (uri (pypi-uri "furl" version))
6345 (sha256
6346 (base32 "05b058xisv8kghvcpaxvssml2jjkh1cmzyrrjwk2kjb62985fxl7"))))
6347 (build-system pyproject-build-system)
6348 (arguments
6349 (list #:test-flags
6350 #~(list "-k" (string-append "not test_hosts"
6351 " and not test_netloc"
6352 " and not test_odd_urls"))))
6353 (propagated-inputs
6354 (list python-orderedmultidict python-six))
6355 (native-inputs
6356 (list python-pytest python-setuptools python-wheel))
6357 (home-page "https://github.com/gruns/furl")
6358 (synopsis "URL manipulation in Python")
6359 (description "Furl provides an easy-to-use alternative to the
6360@code{urllib} and @code{urlparse} modules for manipulating URLs.")
6361 (license license:unlicense)))
6362
6363(define-public python-httplib2
6364 (package
6365 (name "python-httplib2")
6366 (version "0.31.2")
6367 (source
6368 (origin
6369 (method git-fetch)
6370 (uri (git-reference
6371 (url "https://github.com/httplib2/httplib2")
6372 (commit (string-append "v" version))))
6373 (file-name (git-file-name name version))
6374 (sha256
6375 (base32
6376 "0wdnf4rhw9ar8b15lzvif11ibnnpqkfif3alkhkfywy3ikk8nrxb"))))
6377 (build-system pyproject-build-system)
6378 (arguments
6379 (list
6380 #:phases
6381 #~(modify-phases %standard-phases
6382 (add-after 'unpack 'adjust-test-requirements
6383 (lambda _
6384 (substitute* "requirements-test.txt"
6385 (("==") ">=")))))))
6386 (propagated-inputs
6387 (list python-pyparsing
6388 python-pysocks))
6389 (native-inputs
6390 (list python-cryptography
6391 python-mock
6392 python-pytest
6393 python-pytest-randomly
6394 python-pytest-timeout
6395 python-setuptools))
6396 (home-page "https://github.com/httplib2/httplib2")
6397 (synopsis "Comprehensive HTTP client library")
6398 (description
6399 "A comprehensive HTTP client library supporting many features left out of
6400other HTTP libraries.")
6401 (license license:expat)))
6402
6403(define-public python-parfive
6404 (package
6405 (name "python-parfive")
6406 (version "2.3.1")
6407 (source
6408 (origin
6409 (method git-fetch)
6410 (uri (git-reference
6411 (url "https://github.com/Cadair/parfive")
6412 (commit (string-append "v" version))))
6413 (file-name (git-file-name name version))
6414 (sha256
6415 (base32 "09kkh7kp9qy8m26zk6p7zc84yrc81pjgsi594kaa1v1n83mprl4b"))))
6416 (build-system pyproject-build-system)
6417 (arguments
6418 (list
6419 #:test-flags
6420 ;; Disable tests requiring network access.
6421 #~(list "-k" (string-join
6422 (list "not test_ftp"
6423 "test_ftp_http"
6424 "test_ftp_pasv_command"
6425 "test_problematic_http_urls")
6426 " and not "))))
6427 (native-inputs
6428 (list python-aiofiles
6429 python-pytest
6430 python-pytest-asyncio
6431 python-pytest-localserver
6432 python-pytest-socket
6433 python-setuptools
6434 python-setuptools-scm))
6435 (propagated-inputs
6436 (list python-aiohttp
6437 python-tqdm
6438 ;; [optional]
6439 python-aioftp))
6440 (home-page "https://parfive.readthedocs.io/")
6441 (synopsis "HTTP and FTP parallel file downloader")
6442 (description
6443 "This package provides CLI tool and Python library @code{parallel} file
6444downloader using asyncio. parfive can handle downloading multiple files in
6445parallel as well as downloading each file in a number of chunks.
6446
6447asciicast demo of parfive parfive works by creating a downloader object,
6448appending files to it and then running the download. parfive has a synchronous
6449API, but uses asyncio to parallelise downloading the files.")
6450 (license license:expat)))
6451
6452(define-public python-html2text
6453 (package
6454 (name "python-html2text")
6455 (version "2020.1.16")
6456 (source
6457 (origin
6458 (method url-fetch)
6459 (uri (pypi-uri "html2text" version))
6460 (sha256
6461 (base32 "1fvv4z6dblii2wk1x82981ag8yhxbim1v2ksgywxsndh2s7335p2"))))
6462 (build-system pyproject-build-system)
6463 (native-inputs (list python-pytest python-setuptools python-wheel))
6464 (home-page "https://github.com/Alir3z4/html2text")
6465 (synopsis "Convert HTML into plain text")
6466 (description
6467 "html2text takes HTML and converts it into plain ASCII text
6468which is also valid markdown. html2text was originally written by Aaron
6469Swartz.")
6470 (license license:gpl3+)))
6471
6472(define-public python-jose
6473 (package
6474 (name "python-jose")
6475 (version "3.5.0")
6476 (home-page "https://github.com/mpdavis/python-jose")
6477 (source (origin
6478 (method git-fetch)
6479 (uri (git-reference (url home-page) (commit version)))
6480 (file-name (git-file-name name version))
6481 (sha256
6482 (base32
6483 "0frv7r6q43mjl7s82hh8qvqpdgyfvmyq2b6aq4402riq2i238d7h"))))
6484 (build-system pyproject-build-system)
6485 (native-inputs
6486 (list python-pyasn1 python-pytest python-setuptools))
6487 (propagated-inputs
6488 (list python-cryptography python-ecdsa python-rsa))
6489 (synopsis "JOSE implementation in Python")
6490 (description
6491 "The @dfn{JavaScript Object Signing and Encryption} (JOSE) technologies
6492- JSON Web Signature (JWS), JSON Web Encryption (JWE), JSON Web Key (JWK), and
6493JSON Web Algorithms (JWA) - collectively can be used to encrypt and/or sign
6494content using a variety of algorithms.")
6495 (license license:expat)))
6496
6497(define-public python-joserfc
6498 (package
6499 (name "python-joserfc")
6500 (version "1.5.0")
6501 (source
6502 (origin
6503 (method url-fetch)
6504 (uri (pypi-uri "joserfc" version))
6505 (sha256
6506 (base32 "0mhwx7znnhhvxfd6l1imwga2lid8vpb5v8b10lvivv08rxbxg22f"))))
6507 (build-system pyproject-build-system)
6508 (propagated-inputs (list python-cryptography))
6509 (native-inputs
6510 (list python-pycryptodome python-pytest python-setuptools))
6511 (home-page "https://github.com/authlib/joserfc")
6512 (synopsis "Python library for JOSE RFCs")
6513 (description
6514 "This package provides a Python library for JOSE RFCs, including JWS,
6515JWE, JWK, JWA, and JWT.")
6516 (license license:bsd-3)))
6517
6518(define-public python-jwcrypto
6519 (package
6520 (name "python-jwcrypto")
6521 (version "1.5.6")
6522 (source
6523 (origin
6524 (method url-fetch)
6525 (uri (pypi-uri "jwcrypto" version))
6526 (sha256
6527 (base32 "0fdhn5jrsdxqr1yr6rmh585q4j08z1aajn392vk1l20c59v8f6kp"))))
6528 (build-system pyproject-build-system)
6529 (native-inputs
6530 (list python-pytest
6531 python-setuptools))
6532 (propagated-inputs
6533 (list python-cryptography
6534 python-typing-extensions))
6535 (home-page "https://github.com/latchset/jwcrypto")
6536 (synopsis "Implementation of JOSE Web standards")
6537 (description
6538 "WCrypto is an implementation of the @dfn{Javascript Object Signing and
6539Encryption} (JOSE) Web Standards.")
6540 (license license:lgpl3+)))
6541
6542(define-public python-pypitoken
6543 (package
6544 (name "python-pypitoken")
6545 (version "7.0.1")
6546 (source
6547 (origin
6548 (method url-fetch)
6549 (uri (pypi-uri "pypitoken" version))
6550 (sha256
6551 (base32 "18hhwmdfs9y5ypl1n8z2h2ys2f52mv5xr043gzgb34mpmg0wi46x"))))
6552 (build-system pyproject-build-system)
6553 ;; There are no tests.
6554 (arguments (list #:tests? #false))
6555 (propagated-inputs (list python-jsonschema python-pymacaroons
6556 python-typing-extensions))
6557 (native-inputs (list python-poetry-core))
6558 (home-page "https://pypitoken.readthedocs.io/en/latest/")
6559 (synopsis "Manipulate PyPI API tokens")
6560 (description "This package lets you manipulate PyPI API tokens.")
6561 (license license:expat)))
6562
6563(define-public python-jsonpickle
6564 (package
6565 (name "python-jsonpickle")
6566 (version "4.0.0")
6567 (source (origin
6568 (method url-fetch)
6569 (uri (pypi-uri "jsonpickle" version))
6570 (sha256
6571 (base32
6572 "0dipys8p4hkqnp9nwkpysfv7mhws2hrr73wgn00pdmq4n990hrzw"))))
6573 (build-system pyproject-build-system)
6574 (arguments
6575 (list
6576 #:test-flags '(list "tests")
6577 #:phases
6578 '(modify-phases %standard-phases
6579 (add-before 'check 'pre-check
6580 (lambda* (#:key inputs #:allow-other-keys)
6581 (setenv "TZ" "UTC")
6582 (setenv "TZDIR"
6583 (search-input-directory inputs "share/zoneinfo")))))))
6584 (native-inputs
6585 (list python-bson
6586 python-ecdsa
6587 python-feedparser
6588 python-pymongo
6589 python-pytest
6590 python-pytest-benchmark
6591 python-pytest-enabler
6592 python-setuptools
6593 python-setuptools-scm
6594 python-simplejson
6595 python-sqlalchemy
6596 python-ujson
6597 python-wheel
6598 tzdata-for-tests))
6599 (home-page "https://jsonpickle.github.io/")
6600 (synopsis "Serialize object graphs into JSON")
6601 (description
6602 "This package provides a Python library for serializing any arbitrary
6603object graph to and from JSON.")
6604 (license license:bsd-3)))
6605
6606(define-public python-mcp
6607 (package
6608 (name "python-mcp")
6609 (version "1.25.0")
6610 (source
6611 (origin
6612 (method url-fetch)
6613 (uri (pypi-uri "mcp" version))
6614 (sha256
6615 (base32 "00k87bl4jvnh7hrmicwb2m715fwccvvlanwf8cnlwdphxdhh6can"))))
6616 (build-system pyproject-build-system)
6617 (arguments
6618 (list
6619 ;; XXX: 186 failed, 648 passed, 94 skipped, 54 errors
6620 ;; A lot of tests fail for unclear reasons.
6621 #:tests? #f))
6622 (propagated-inputs
6623 (list python-httpx
6624 python-httpx-sse
6625 python-pydantic
6626 python-sse-starlette))
6627 (native-inputs
6628 (list python-hatchling
6629 python-jsonschema
6630 python-pydantic-settings
6631 python-pytest
6632 python-pytest-examples
6633 python-pytest-xdist
6634 python-starlette
6635 python-typer
6636 python-typing-inspection
6637 python-uvicorn))
6638 (home-page "https://modelcontextprotocol.io")
6639 (synopsis "Model Context Protocol SDK")
6640 (description
6641 "This package provides a Python Software Development Kit for the Model
6642Context Protocol (MCP).")
6643 (license license:expat)))
6644
6645(define-public python-mechanicalsoup
6646 (package
6647 (name "python-mechanicalsoup")
6648 (version "1.4.0")
6649 (source
6650 (origin
6651 (method url-fetch)
6652 (uri (pypi-uri "mechanicalsoup" version))
6653 (sha256
6654 (base32 "0k1ac77ld6jyjm5fsr44399l5gmiwnz5w6s74i3qqx2scfbsgs6w"))))
6655 (build-system pyproject-build-system)
6656 (arguments
6657 (list
6658 #:test-flags
6659 ;; Unclear why test fails.
6660 #~(list "-k" "not test_select_form_associated_elements")
6661 ;; The following dependencies are not directly required, the developer
6662 ;; only pinned versions because of vulnerabilities. They also break
6663 ;; sanity-check because it checks for a python-certifi version which is
6664 ;; more recent than the one available in Guix.
6665 #:phases #~(modify-phases %standard-phases
6666 (add-after 'unpack 'relax-dependencies
6667 (lambda _
6668 (substitute* "requirements.txt"
6669 (("certifi.*") "")
6670 (("urllib3.*") "")))))))
6671 (propagated-inputs
6672 (list python-beautifulsoup4 python-lxml python-requests))
6673 (native-inputs
6674 (list python-pytest
6675 python-pytest-flake8
6676 python-pytest-httpbin
6677 python-pytest-mock
6678 python-requests-mock
6679 python-setuptools
6680 python-wheel))
6681 (home-page "https://mechanicalsoup.readthedocs.io/")
6682 (synopsis "Python library for automating website interaction")
6683 (description
6684 "MechanicalSoup is a Python library for automating interaction with
6685websites. It automatically stores and sends cookies, follows redirects, and can
6686follow links and submit forms. It doesn’t do JavaScript.")
6687 (license license:expat)))
6688
6689(define-public python-hypercorn
6690 (package
6691 (name "python-hypercorn")
6692 (version "0.18.0")
6693 (source
6694 (origin
6695 (method git-fetch)
6696 (uri (git-reference
6697 (url "https://github.com/pgjones/hypercorn")
6698 (commit version)))
6699 (file-name (git-file-name name version))
6700 (sha256
6701 (base32 "0jdi05n5isxn0rysq242p198lz03gbwsnizzb9yp6rxr7ajapns4"))))
6702 (build-system pyproject-build-system)
6703 (propagated-inputs
6704 (list python-aioquic
6705 python-h11
6706 python-h2
6707 python-priority
6708 python-pydata-sphinx-theme
6709 python-sphinxcontrib-mermaid
6710 python-tomli
6711 python-trio
6712 python-typing-extensions
6713 python-uvloop
6714 python-wsproto))
6715 (native-inputs
6716 (list nss-certs-for-test
6717 python-httpx
6718 python-pdm-backend
6719 python-pytest
6720 python-pytest-asyncio
6721 python-pytest-cov
6722 python-pytest-trio))
6723 (home-page "https://github.com/pgjones/hypercorn")
6724 (synopsis "ASGI Server based on Hyper libraries")
6725 (description
6726 "This package provides an ASGI (Asynchronous Server Gateway Interface)
6727Server based on Hyper libraries and inspired by @code{python-gunicorn}.")
6728 (license license:expat)))
6729
6730(define-public python-hyperframe
6731 (package
6732 (name "python-hyperframe")
6733 (version "6.1.0")
6734 (source
6735 (origin
6736 (method url-fetch)
6737 (uri (pypi-uri "hyperframe" version))
6738 (sha256
6739 (base32 "021v58w1b7mbwqkvbz11p3a4qk1sj91jnf6nmgg7ljl502590c7n"))))
6740 (build-system pyproject-build-system)
6741 (native-inputs
6742 (list python-pytest python-setuptools))
6743 (home-page "https://github.com/python-hyper/hyperframe")
6744 (synopsis "HTTP/2 framing layer for Python")
6745 (description
6746 "This library contains the HTTP/2 framing code used in the hyper project.
6747It provides a pure-Python codebase that is capable of decoding a binary stream
6748into HTTP/2 frames.")
6749 (license license:expat)))
6750
6751(define-public python-hpack
6752 (package
6753 (name "python-hpack")
6754 (version "4.1.0")
6755 (source
6756 (origin
6757 ;; PyPI tarball is missing some files necessary for the tests.
6758 (method git-fetch)
6759 (uri (git-reference
6760 (url "https://github.com/python-hyper/hpack")
6761 (commit (string-append "v" version))))
6762 (file-name (git-file-name name version))
6763 (sha256
6764 (base32 "1kgbx38p3a48iz914dqbx7av750a3s3x5kj3rvpcbh23ah75zg5x"))))
6765 (build-system pyproject-build-system)
6766 (native-inputs
6767 (list python-pytest python-setuptools))
6768 (home-page "https://hyper.rtfd.org")
6769 (synopsis "Pure-Python HPACK header compression")
6770 (description
6771 "This module contains a pure-Python HTTP/2 header encoding (HPACK) logic
6772for use in Python programs that implement HTTP/2.")
6773 (license license:expat)))
6774
6775(define-public python-h11
6776 (package
6777 (name "python-h11")
6778 (version "0.16.0")
6779 (source
6780 (origin
6781 (method url-fetch)
6782 (uri (pypi-uri "h11" version))
6783 (sha256
6784 (base32 "1wazxq4b4jg5001h5ypvz9pvrg80pagyd1aqm962wya5rxbbjdaf"))))
6785 (build-system pyproject-build-system)
6786 (native-inputs
6787 (list python-pytest python-setuptools))
6788 (home-page "https://github.com/python-hyper/h11")
6789 (synopsis "Pure-Python, bring-your-own-I/O implementation of HTTP/1.1")
6790 (description
6791 "This is a little HTTP/1.1 library written from scratch in Python, heavily
6792inspired by hyper-h2. It's a bring-your-own-I/O library; h11 contains no IO
6793code whatsoever. This means you can hook h11 up to your favorite network API,
6794and that could be anything you want.")
6795 (license license:expat)))
6796
6797(define-public python-h2
6798 (package
6799 (name "python-h2")
6800 (version "4.3.0")
6801 (source
6802 (origin
6803 (method git-fetch)
6804 (uri (git-reference
6805 (url "https://github.com/python-hyper/h2")
6806 (commit (string-append "v" version))))
6807 (file-name (git-file-name name version))
6808 (sha256
6809 (base32 "00rf0ii4xgdczx5xmv1k6b65q1axvxizbnl20d5vpr512zdix36k"))))
6810 (build-system pyproject-build-system)
6811 (arguments
6812 (list
6813 ;; tests: 1594 passed, 5 deselected
6814 ;; AssertionError: assert '<RemoteSettingsChanged
6815 ;; changed_settings:{ChangedSetting(setting=4, original_value=65536,
6816 ;; new_value=32768)}>' == '<RemoteSettingsChanged
6817 ;; changed_settings:{ChangedSetting(setting=SettingCodes.INITIAL_WINDOW_SIZE,
6818 ;; original_value=65536, new_value=32768)}>'
6819 #:test-flags
6820 #~(list "-k"
6821 (string-join
6822 (list "not test_remotesettingschanged_repr"
6823 ;; This test exceededs the Hypothesis deadline.
6824 #$@(if (target-riscv64?)
6825 #~("test_changing_max_frame_size")
6826 #~())
6827 "test_streamreset_repr"
6828 "test_settingsacknowledged_repr"
6829 "test_connectionterminated_repr[None-None]"
6830 "test_connectionterminated_repr[some"
6831 "test_remotesettingschanged_repr"
6832 "test_streamreset_repr"
6833 "test_settingsacknowledged_repr"
6834 "test_connectionterminated_repr[None-None]"
6835 "test_connectionterminated_repr[some")
6836 " and not "))))
6837 (native-inputs
6838 (list python-pytest
6839 python-setuptools))
6840 (propagated-inputs
6841 (list python-hpack
6842 python-hyperframe))
6843 (home-page "https://github.com/python-hyper/h2")
6844 (synopsis "HTTP/2 State-Machine based protocol implementation")
6845 (description
6846 "This module contains a pure-Python implementation of a HTTP/2 protocol
6847stack. It does not provide a parsing layer, a network layer, or any rules
6848about concurrency. Instead, it's a purely in-memory solution, defined in
6849terms of data actions and HTTP/2 frames. This is one building block of a full
6850Python HTTP implementation.")
6851 (license license:expat)))
6852
6853(define-public python-scitokens
6854 (package
6855 (name "python-scitokens")
6856 (version "1.9.7")
6857 (source
6858 (origin
6859 (method git-fetch)
6860 (uri (git-reference
6861 (url "https://github.com/scitokens/scitokens")
6862 (commit (string-append "v" version))))
6863 (file-name (git-file-name name version))
6864 (sha256
6865 (base32 "1yfgv6f6xx2s0bnbzhzs8hqpq6d1v5bkvqdza4zl4f375flb961m"))))
6866 (build-system pyproject-build-system)
6867 (arguments
6868 (list
6869 #:test-flags
6870 #~(map (lambda (lst) (string-append "--deselect=tests/"
6871 (string-join lst "::")))
6872 ;; Network access is required.
6873 '(("test_demo.py" "TestToken" "test_empty_payload")
6874 ("test_demo.py" "TestToken" "test_valid_payload")
6875 ("test_demo.py" "TestParsedToken" "test_empty_parsed")
6876 ("test_demo.py" "TestParsedToken" "test_valid_parsed")
6877 ("test_keycache_threadsafe.py" "TestKeyCache"
6878 "test_clients_calling_valid_keys")
6879 ("test_with_http.py" "TestDeserialization"
6880 "test_deserialization")
6881 ("test_with_http.py" "TestDeserialization"
6882 "test_ec_deserialization")))))
6883 (native-inputs
6884 (list python-pytest python-setuptools))
6885 (propagated-inputs
6886 (list python-cryptography python-pyjwt python-requests))
6887 (home-page "https://scitokens.org")
6888 (synopsis "SciToken reference implementation library")
6889 (description
6890 "This package provides a Python library aiming to be a reference
6891implementation of the SciTokens' JSON Web Token (JWT) token format.
6892
6893SciTokens is built on top of the PyJWT and cryptography libraries. It aims to
6894provide a safe, high-level interface for token manipulation, avoiding common
6895pitfalls of using the underling libraries directly.")
6896 (license license:asl2.0)))
6897
6898(define-public python-slixmpp
6899 (package
6900 (name "python-slixmpp")
6901 (version "1.17.0")
6902 (source
6903 (origin
6904 (method git-fetch)
6905 (uri (git-reference
6906 (url "https://codeberg.org/poezio/slixmpp")
6907 (commit (string-append "slix-" version))))
6908 (file-name (git-file-name name version))
6909 (sha256
6910 (base32 "0ml590qs3siajz00f40pdxcz27d41i25ld30819qrf0n9ilqlc6n"))))
6911 (build-system pyproject-build-system)
6912 (arguments
6913 (list
6914 ;; Use the upstream runner: it collects only tests/, skips itests/
6915 ;; which need a live XMPP server, and additionally runs the doctests.
6916 #:test-backend #~'custom
6917 #:test-flags #~'("run_tests.py")
6918 #:phases
6919 #~(modify-phases %standard-phases
6920 (add-after 'unpack 'disable-rust-extension
6921 ;; Upstream marks the Rust JID implementation as optional; skip
6922 ;; it and use the pure Python one in slixmpp/jid.py to avoid
6923 ;; pulling in the Cargo dependency tree.
6924 (lambda _
6925 (substitute* "pyproject.toml"
6926 (("\"setuptools-rust\", ") "")
6927 (("\\[\\[tool\\.setuptools-rust\\.ext-modules\\]\\]")
6928 "[tool.slixmpp-rust-disabled]"))))
6929 (add-before 'build 'set-version
6930 ;; setuptools-scm cannot determine the version without .git.
6931 (lambda _
6932 (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" #$version))))))
6933 (native-inputs
6934 (list gnupg ; 'gnupg' is required by the XEP-0027 tests.
6935 python-setuptools
6936 python-setuptools-scm))
6937 (propagated-inputs
6938 (list python-aiodns
6939 python-aiohttp
6940 python-cryptography
6941 python-defusedxml
6942 python-emoji
6943 python-pyasn1
6944 python-pyasn1-modules))
6945 (home-page "https://codeberg.org/poezio/slixmpp")
6946 (synopsis "XMPP library without threads")
6947 (description
6948 "Slixmpp is a XMPP library for Python 3.11+. It is a fork of SleekXMPP.
6949Its goal is to only rewrite the core of the library (the low level socket
6950handling, the timers, the events dispatching) in order to remove all
6951threads.")
6952 (license license:expat)))
6953
6954(define-public python-sockjs-tornado
6955 (package
6956 (name "python-sockjs-tornado")
6957 (version "1.0.6")
6958 (source
6959 (origin
6960 (method git-fetch)
6961 (uri (git-reference
6962 (url "https://github.com/mrjoes/sockjs-tornado/")
6963 (commit (string-append "v" version))))
6964 (file-name (git-file-name name version))
6965 (sha256
6966 (base32 "1y4wjca1776nvd0b79pz4d52i312xsyb2vahb883qmrw6s56mynk"))))
6967 (build-system pyproject-build-system)
6968 (arguments
6969 (list
6970 #:tests? #f)) ;The only test in examples/test/test.py runs a server.
6971 (native-inputs (list python-setuptools))
6972 (propagated-inputs (list python-tornado))
6973 (home-page "https://github.com/mrjoes/sockjs-tornado/")
6974 (synopsis
6975 "SockJS Python server implementation on top of the Tornado framework")
6976 (description
6977 "SockJS-tornado provides the server-side counterpart to a SockJS client
6978library, through the Tornado framework.
6979
6980SockJS provides a low-latency, full-duplex, cross-domain communication channel
6981between a web browser and web server.")
6982 (license license:expat)))
6983
6984(define-public python-flask-assets
6985 ;; The latest release still depends on the abandoned flask-script, whereas
6986 ;; at this later commit (already 2 years old at the time of this writing)
6987 ;; the dependency has been lifted.
6988 (let ((commit "62efd23fe95ee6a86fc1cfaa98fc1e2152093557")
6989 (revision "1"))
6990 (package
6991 (name "python-flask-assets")
6992 (version (git-version "2.1.0" revision commit))
6993 (source
6994 (origin
6995 (method git-fetch)
6996 (uri (git-reference
6997 (url "https://github.com/miracle2k/flask-assets/")
6998 (commit commit)))
6999 (file-name (git-file-name name version))
7000 (sha256
7001 (base32 "11q8vm2ipj4xrvawy9vl1l4k8kb4r72ghy1n8xrzci52v6lx8960"))))
7002 (build-system pyproject-build-system)
7003 (propagated-inputs
7004 (list python-flask python-webassets))
7005 (native-inputs
7006 (list nss-certs-for-test python-pytest python-setuptools python-wheel))
7007 (home-page "https://github.com/miracle2k/flask-assets")
7008 (synopsis "Asset management for Flask")
7009 (description "This package integrates @code{webassets} with Flask, adding
7010support for merging, minifying and compiling CSS and Javascript files.")
7011 (license license:bsd-2))))
7012
7013(define-public python-flask-babel
7014 (package
7015 (name "python-flask-babel")
7016 (version "4.0.0")
7017 (source
7018 (origin
7019 (method git-fetch) ;no tests in pypi release
7020 (uri (git-reference
7021 (url "https://github.com/python-babel/flask-babel")
7022 (commit (string-append "v" version))))
7023 (sha256
7024 (base32
7025 "19yq3f5rixbwhv7wxdarvi9hdj98a9dq8y76in9c1q3jxaigw104"))))
7026 (build-system pyproject-build-system)
7027 (native-inputs
7028 (list python-poetry-core
7029 python-pytest
7030 python-pytest-mock))
7031 (propagated-inputs
7032 (list python-babel
7033 python-flask
7034 python-jinja2
7035 python-pytz))
7036 (home-page "https://github.com/python-babel/flask-babel")
7037 (synopsis "Add i18n/l10n support to Flask applications")
7038 (description "This package implements internationalization and localization
7039support for Flask. This is based on the Python babel module as well as pytz -
7040both of which are installed automatically if you install this library.")
7041 (license license:bsd-3)))
7042
7043(define-public python-flask-cors
7044 (package
7045 (name "python-flask-cors")
7046 (version "6.0.2")
7047 (source
7048 (origin
7049 (method git-fetch) ;no tests in PyPI archive
7050 (uri (git-reference
7051 (url "https://github.com/CoryDolphin/flask-cors")
7052 (commit version)))
7053 (file-name (git-file-name name version))
7054 (sha256
7055 (base32 "02y740h951dscgkm7ghsss1bc0m8ymsfdpsimm1j0nkl0zjl6sgm"))))
7056 (build-system pyproject-build-system)
7057 (arguments
7058 (list
7059 #:phases
7060 #~(modify-phases %standard-phases
7061 (add-after 'unpack 'fix-version
7062 (lambda _
7063 ;; Otherwise sanity-check of dependents will fail.
7064 (substitute* "pyproject.toml"
7065 (("version = \"0\\.0\\.1\"" all)
7066 (string-append "version = \"" #$version "\""))))))))
7067 (native-inputs
7068 (list python-pytest
7069 python-setuptools))
7070 (propagated-inputs
7071 (list python-flask
7072 python-werkzeug))
7073 (home-page "https://flask-cors.readthedocs.io/en/latest/")
7074 (synopsis "Handle Cross-Origin Resource Sharing with Flask")
7075 (description
7076 "This package provides a Flask extension for handling @acronym{CORS,Cross
7077Origin Resource Sharing}, making cross-origin AJAX possible.")
7078 (license license:expat)))
7079
7080(define-public python-flask-markdown
7081 (package
7082 (name "python-flask-markdown")
7083 (version "0.3")
7084 (source
7085 (origin
7086 (method git-fetch)
7087 (uri (git-reference
7088 (url "https://github.com/dcolish/flask-markdown")
7089 (commit version)))
7090 (file-name (git-file-name name version))
7091 (sha256
7092 (base32 "1rqqmvjc4rjal6l4y3caxw9b3157pl923h4i1ihbm0gziqv3g2hl"))))
7093 (build-system pyproject-build-system)
7094 (arguments
7095 (list
7096 #:tests? #f ;Tests seem to be incompatible with latest python
7097 #:phases
7098 #~(modify-phases %standard-phases
7099 (add-after 'unpack 'set-version
7100 (lambda _
7101 (substitute* "setup.py"
7102 (("dev")
7103 #$version)))))))
7104 (propagated-inputs (list python-markdown python-flask))
7105 (native-inputs (list python-pynose python-setuptools))
7106 (home-page "https://github.com/dcolish/flask-markdown")
7107 (synopsis "Small extension to help with using Markdown in Flask")
7108 (description
7109 "Flask-Markdown supports several extensions for Markdown and integrates
7110into Jinja2 by default.")
7111 (license license:bsd-3)))
7112
7113(define-public python-flask-session
7114 (package
7115 (name "python-flask-session")
7116 (version "0.8.0")
7117 (source
7118 (origin
7119 (method url-fetch)
7120 (uri (pypi-uri "flask_session" version))
7121 (sha256
7122 (base32
7123 "1zs20zpq6gxz9gsccbd2jrrbbcfvh0x9z9741gkr8dhh07mlbq10"))))
7124 (build-system pyproject-build-system)
7125 (arguments
7126 '(#:tests? #f)) ; Tests require the various storage backends to be present
7127 (native-inputs (list python-flit-core))
7128 (propagated-inputs
7129 (list python-cachelib python-flask python-msgspec))
7130 (home-page "https://github.com/pallets-eco/flask-session")
7131 (synopsis "Adds server-side session support to your Flask application")
7132 (description
7133 "Flask-Session is an extension for Flask that adds support for
7134Server-side sessions, with a variety of different backends for session
7135storage.")
7136 (license license:bsd-3)))
7137
7138(define-public python-html5lib
7139 (package
7140 (name "python-html5lib")
7141 (version "1.1")
7142 (source
7143 (origin
7144 (method url-fetch)
7145 (uri (pypi-uri "html5lib" version))
7146 (sha256
7147 (base32 "0vqlhk0hgbsfkh7ybmby93xhlx8dq6pr5blf356ka3z2c41b9rdj"))))
7148 (build-system pyproject-build-system)
7149 (arguments
7150 '(#:tests? #f)) ;tests depend on dated pytest-expect
7151 (native-inputs
7152 (list python-setuptools))
7153 (propagated-inputs
7154 (list python-six
7155 python-webencodings
7156 ;; Required by Calibre 5.
7157 python-chardet))
7158 (home-page "https://github.com/html5lib/html5lib-python")
7159 (synopsis "Python HTML parser based on the WHATWG HTML specification")
7160 (description
7161 "Html5lib is an HTML parser based on the WHATWG HTML specification
7162and written in Python.")
7163 (license license:expat)))
7164
7165(define-public python-html5-parser
7166 (package
7167 (name "python-html5-parser")
7168 (version "0.4.12")
7169 (source
7170 (origin
7171 (method git-fetch)
7172 (uri (git-reference
7173 (url "https://github.com/kovidgoyal/html5-parser")
7174 (commit (string-append "v" version))))
7175 (file-name (git-file-name name version))
7176 (sha256
7177 (base32 "0axrz2x67nhsh3kijy68wwy5hx8h8418d8g2qz6f3pyxix7gw2fi"))))
7178 (build-system pyproject-build-system)
7179 (arguments
7180 (list
7181 #:phases
7182 #~(modify-phases %standard-phases
7183 (add-before 'build 'set-configure-flags
7184 (lambda _
7185 (setenv "CFLAGS" "-Wno-error=implicit-function-declaration"))))))
7186 (native-inputs (list pkg-config python-setuptools))
7187 (inputs (list libxml2))
7188 (propagated-inputs (list python-lxml python-beautifulsoup4 python-chardet))
7189 (home-page "https://html5-parser.readthedocs.io")
7190 (synopsis "Fast C-based HTML5 parsing for Python")
7191 (description
7192 "This package provides a fast implementation of the HTML5 parsing spec
7193for Python. Parsing is done in C using a variant of the gumbo parser. The
7194gumbo parse tree is then transformed into an lxml tree, also in C, yielding
7195parse times that can be a thirtieth of the html5lib parse times.")
7196 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
7197 ;; indicate ASL2.0, including the LICENSE file for the whole project.
7198 (license (list license:asl2.0 license:gpl3))))
7199
7200(define-public python-html5tagger
7201 (package
7202 (name "python-html5tagger")
7203 (version "2.0.0")
7204 (source (origin
7205 (method url-fetch)
7206 (uri (pypi-uri "html5tagger" version))
7207 (sha256
7208 (base32
7209 "090nmjhr0yj3x5iy9zmbmv07dpxn234dqpi2lglk0fa4aj83rvhd"))))
7210 (build-system pyproject-build-system)
7211 (arguments
7212 (list #:tests? #f)) ;no tests in PyPI or Git
7213 (native-inputs
7214 (list python-hatch-vcs python-hatchling))
7215 (home-page "https://github.com/sanic-org/html5tagger")
7216 (synopsis "Create HTML documents from Python")
7217 (description
7218 "@code{html5tagger} provides a simplified HTML5 syntax that can
7219be written directly in Python without templates.")
7220 (license license:unlicense)))
7221
7222(define-public python-minio
7223 (package
7224 (name "python-minio")
7225 (version "7.1.9")
7226 (source
7227 (origin
7228 (method git-fetch)
7229 (uri (git-reference
7230 (url "https://github.com/minio/minio-py")
7231 (commit version)))
7232 (file-name (git-file-name name version))
7233 (sha256
7234 (base32 "01734ki3p7844dya366hy1kvmmgy3xr0l0zbkchnnv4p611510vc"))))
7235 (build-system pyproject-build-system)
7236 (arguments
7237 (list
7238 #:test-flags
7239 ;; XXX: requires network access.
7240 #~(list "--ignore=tests/unit/credentials_test.py")))
7241 (native-inputs (list python-pytest python-setuptools))
7242 (propagated-inputs
7243 (list python-certifi python-dateutil python-pytz python-urllib3))
7244 (home-page "https://github.com/minio/minio-py")
7245 (synopsis "Programmatically access Amazon S3 from Python")
7246 (description
7247 "This package provides a Python library for interacting with any
7248Amazon S3 compatible object storage server.")
7249 (license license:asl2.0)))
7250
7251(define-public python-pycrdt
7252 (package
7253 (name "python-pycrdt")
7254 (version "0.13.0")
7255 (source
7256 (origin
7257 (method git-fetch)
7258 (uri (git-reference
7259 (url "https://github.com/y-crdt/pycrdt")
7260 (commit version)))
7261 (file-name (git-file-name name version))
7262 (sha256
7263 (base32 "18mnjbxdlra1w3jl42bf1jb25z9j3inh6s61qighqrvnylgxvxc1"))))
7264 (build-system pyproject-build-system)
7265 (arguments
7266 (list
7267 #:imported-modules `(,@%cargo-build-system-modules
7268 ,@%pyproject-build-system-modules)
7269 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
7270 (guix build pyproject-build-system)
7271 (guix build utils))
7272 #:test-flags #~(list "--ignore=tests/test_types.py")
7273 #:phases
7274 #~(modify-phases %standard-phases
7275 (add-after 'unpack 'relax-requirements
7276 (lambda _
7277 (substitute* "pyproject.toml"
7278 (("requires = \\[\"maturin>=.*\"\\]")
7279 "requires = [\"maturin\"]"))))
7280 (add-after 'unpack 'prepare-cargo-build-system
7281 (lambda args
7282 (for-each
7283 (lambda (phase)
7284 (format #t "Running cargo phase: ~a~%" phase)
7285 (apply (assoc-ref cargo:%standard-phases phase)
7286 #:cargo-target #$(cargo-triplet)
7287 args))
7288 '(unpack-rust-crates
7289 configure
7290 check-for-pregenerated-files
7291 patch-cargo-checksums)))))))
7292 (propagated-inputs
7293 (list python-anyio
7294 python-typing-extensions))
7295 (inputs (cargo-inputs 'pycrdt))
7296 (native-inputs
7297 (append
7298 (list maturin
7299 python-pydantic
7300 python-pytest
7301 rust
7302 `(,rust "cargo"))
7303 (or (and=> (%current-target-system)
7304 (compose list make-rust-sysroot))
7305 '())))
7306 (home-page "https://github.com/y-crdt/pycrdt")
7307 (synopsis "Python CRDTs library ported from Yjs framework")
7308 (description
7309 "Conflict-free Replicated Data Types (CRDTs) allow creating shared
7310documents that can automatically merge changes made concurrently on different
7311copies of the data. When the data lives on different machines, they make it
7312possible to build distributed systems that work with local data, leaving the
7313synchronization and conflict resolution with remote data to the CRDT
7314algorithm, which ensures that all data replicas eventually converge to the
7315same state.
7316
7317This is a Python CRDT library that provides bindings for Yrs, the Rust port of
7318the Yjs framework.")
7319 (license license:expat)))
7320
7321(define-public python-pycrdt-store
7322 (package
7323 (name "python-pycrdt-store")
7324 (version "0.1.3")
7325 (source
7326 (origin
7327 (method git-fetch)
7328 (uri (git-reference
7329 (url "https://github.com/y-crdt/pycrdt-store")
7330 (commit version)))
7331 (file-name (git-file-name name version))
7332 (sha256
7333 (base32 "18yvv5lgxb4v0qlbi8bbkcm1666nxbkmhbx445sxpzab7027fl1a"))))
7334 (build-system pyproject-build-system)
7335 (propagated-inputs
7336 (list python-anyio
7337 python-pycrdt
7338 python-sqlite-anyio))
7339 (native-inputs
7340 (list python-hatchling
7341 python-pytest
7342 python-pytest-rerunfailures
7343 python-trio))
7344 (home-page "https://github.com/y-crdt/pycrdt-store")
7345 (synopsis "Persistent storage for pycrdt")
7346 (description
7347 "This package provides a persistent storage feature for
7348@code{python-pycrdt}.")
7349 (license license:expat)))
7350
7351(define-public python-pycrdt-websocket
7352 (package
7353 (name "python-pycrdt-websocket")
7354 (version "0.16.0")
7355 (source
7356 (origin
7357 (method git-fetch)
7358 (uri (git-reference
7359 (url "https://github.com/y-crdt/pycrdt-websocket")
7360 (commit version)))
7361 (file-name (git-file-name name version))
7362 (sha256
7363 (base32 "1bcxivdra0v5fwlz3hcz98vxi61884bfvcwifsdp3mji28iprv22"))))
7364 (build-system pyproject-build-system)
7365 (arguments
7366 (list
7367 ;; These tests require the unpackaged Yjs.
7368 #:test-flags #~(list "--deselect=tests/test_pycrdt_yjs.py")))
7369 (propagated-inputs
7370 (list python-anyio
7371 python-pycrdt
7372 python-pycrdt-store))
7373 (native-inputs
7374 (list nss-certs-for-test
7375 python-hatchling
7376 python-hypercorn
7377 python-httpx-ws
7378 python-pytest))
7379 (home-page "https://github.com/y-crdt/pycrdt-websocket")
7380 (synopsis "WebSocket connector for pycrdt")
7381 (description "This package provides an asynchronous @code{WebSocket}
7382connector for @code{python-pycrdt}.")
7383 (license license:expat)))
7384
7385(define-public python-pycurl
7386 (package
7387 (name "python-pycurl")
7388 (version "7.48.0")
7389 (source
7390 (origin
7391 (method git-fetch)
7392 (uri (git-reference
7393 (url "https://github.com/pycurl/pycurl")
7394 (commit (string-append
7395 "REL_" (string-replace-substring version "." "_")))))
7396 (file-name (git-file-name name version))
7397 (sha256
7398 (base32 "06d6fji6qmiimfnfgfxqnq4hj245q5ipcfvr1csm53ly1sa3jcfy"))))
7399 (build-system pyproject-build-system)
7400 (arguments
7401 '(#:test-flags
7402 ;; The test suite is not thread safe:
7403 ;; - some tests want to use the same port: address already in use
7404 ;; - some tests use signal.Signal, i.e. main-thread only
7405 (list "-k" (string-append
7406 ;; OSError: tests/fake-curl/libcurl/with_gnutls.so: cannot
7407 ;; open shared object file: No such file or directory
7408 "not test_libcurl_ssl_gnutls"
7409 ;; OSError: tests/fake-curl/libcurl/with_nss.so: cannot
7410 ;; open shared object file: No such file or directory
7411 " and not test_libcurl_ssl_nss"
7412 ;; OSError: tests/fake-curl/libcurl/with_openssl.so: cannot
7413 ;; open shared object file: No such file or directory
7414 " and not test_libcurl_ssl_openssl"
7415 ;; AssertionError: proc.returncode == 130
7416 " and not test_sigint"))
7417 #:phases (modify-phases %standard-phases
7418 (add-before 'build 'configure-tls-backend
7419 (lambda _
7420 ;; XXX: PycURL fails to automatically determine which
7421 ;; TLS backend to use when cURL is built with
7422 ;; --disable-static. See setup.py and
7423 ;; <https://github.com/pycurl/pycurl/pull/147>.
7424 (setenv "PYCURL_SSL_LIBRARY" "gnutls"))))))
7425 (native-inputs
7426 (list python-bottle
7427 python-flaky
7428 python-flask
7429 python-numpy
7430 python-pytest
7431 python-setuptools
7432 python-websockets))
7433 (inputs
7434 (list curl gnutls))
7435 (home-page "https://pycurl.github.io/")
7436 (synopsis "Lightweight Python wrapper around libcurl")
7437 (description "Pycurl is a lightweight wrapper around libcurl. It provides
7438high-speed transfers via libcurl and frequently outperforms alternatives.")
7439
7440 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
7441 ;; under the terms of LGPLv2.1+ or Expat.
7442 (license (list license:lgpl2.1+ license:expat))))
7443
7444(define-public python-stamina
7445 (package
7446 (name "python-stamina")
7447 (version "25.2.0")
7448 (source
7449 (origin
7450 (method git-fetch)
7451 (uri (git-reference
7452 (url "https://github.com/hynek/stamina")
7453 (commit version)))
7454 (file-name (git-file-name name version))
7455 (sha256
7456 (base32 "100iadhzmxbavk0ras3srnagh9af5pxbqrm4mrrkyy69knih9jiy"))))
7457 (build-system pyproject-build-system)
7458 (native-inputs
7459 (list python-pytest
7460 python-anyio
7461 python-dirty-equals
7462 python-hatch-fancy-pypi-readme
7463 python-hatch-vcs
7464 python-hatchling
7465 python-structlog))
7466 (propagated-inputs
7467 (list python-tenacity
7468 python-typing-extensions))
7469 (home-page "https://github.com/hynek/stamina")
7470 (synopsis "Retries library for Python")
7471 (description
7472 "@code{stamina} is an opinionated wrapper around the
7473@url{https://tenacity.readthedocs.io/en/latest/, Tenacity} package.")
7474 (license license:expat)))
7475
7476(define-public python-stripe
7477 (package
7478 (name "python-stripe")
7479 (version "13.2.0")
7480 (source
7481 (origin
7482 (method git-fetch)
7483 (uri (git-reference
7484 (url "https://github.com/stripe/stripe-python")
7485 (commit (string-append "v" version))))
7486 (file-name (git-file-name name version))
7487 (sha256
7488 (base32 "0f0d1hqias3qylrhk56w055lqrlzjs9s7wxva30v54ykmn9nj6dx"))))
7489 (build-system pyproject-build-system)
7490 (arguments
7491 '(#:tests? #f)) ;; tests require network
7492 (native-inputs
7493 (list python-flit-core))
7494 (propagated-inputs
7495 (list python-httpx
7496 python-requests))
7497 (home-page "https://github.com/stripe/stripe-python")
7498 (synopsis "Python bindings for the Stripe financial services' API")
7499 (description "This package provides access to the Stripe financial
7500services' API. It includes a pre-defined set of classes for API resources
7501that initialize themselves dynamically from API responses which makes it
7502compatible with a wide range of versions of the Stripe API.")
7503 (license license:expat)))
7504
7505(define-public python-stripe-12
7506 (hidden-package
7507 (package/inherit python-stripe
7508 (name "python-stripe")
7509 (version "12.5.1")
7510 (source
7511 (origin
7512 (inherit (package-source python-stripe))
7513 (uri (git-reference
7514 (url "https://github.com/stripe/stripe-python")
7515 (commit (string-append "v" version))))
7516 (file-name (git-file-name name version))
7517 (sha256 (base32
7518 "0jgixfb8ydlx387vm7rdaqrzsiqbvi99nszrpb1ghjqyn755xigd"))))
7519 (native-inputs
7520 (list python-setuptools)))))
7521
7522(define-public python-tldextract
7523 (package
7524 (name "python-tldextract")
7525 (version "5.3.0")
7526 (source
7527 (origin
7528 (method url-fetch)
7529 (uri (pypi-uri "tldextract" version))
7530 (sha256
7531 (base32 "02c6cyh8f3dagcw786m9nl5y0n3xa98p5mb7d7xfr84l2l5bglmk"))))
7532 (build-system pyproject-build-system)
7533 (arguments
7534 (list
7535 #:phases
7536 #~(modify-phases %standard-phases
7537 (add-after 'unpack 'relax-requirements
7538 (lambda _
7539 (substitute* "pyproject.toml"
7540 (("\"requests-file.*\",")
7541 "\"requests-file\",")))))))
7542 (native-inputs
7543 (list nss-certs-for-test
7544 python-pytest
7545 python-pytest-mock
7546 python-responses
7547 python-setuptools
7548 python-setuptools-scm
7549 python-syrupy))
7550 (propagated-inputs
7551 (list python-filelock
7552 python-idna
7553 python-requests
7554 python-requests-file))
7555 (home-page "https://github.com/john-kurkowski/tldextract")
7556 (synopsis
7557 "Separate the TLD from the registered domain and subdomains of a URL")
7558 (description
7559 "TLDExtract accurately separates the TLD from the registered domain and
7560subdomains of a URL, using the Public Suffix List. By default, this includes
7561the public ICANN TLDs and their exceptions. It can optionally support the
7562Public Suffix List's private domains as well.")
7563 (license license:bsd-3)))
7564
7565(define-public python-tracerite
7566 (package
7567 (name "python-tracerite")
7568 (version "2.5.2")
7569 (source
7570 (origin
7571 (method url-fetch)
7572 (uri (pypi-uri "tracerite" version))
7573 (sha256
7574 (base32 "087i51ybbj62nx5jzx8znhqb6cd7279mi7v9j6lrxf8lhb81nr3r"))))
7575 (build-system pyproject-build-system)
7576 (arguments
7577 (list #:tests? #f)) ;no tests in PyPI or Git
7578 (native-inputs
7579 (list python-hatch-vcs python-hatchling))
7580 (propagated-inputs
7581 (list python-html5tagger))
7582 (home-page "https://github.com/sanic-org/tracerite")
7583 (synopsis "Human-readable HTML tracebacks")
7584 (description
7585 "@code{tracerite} converts Python tracebacks into useful error messages
7586in human-readable HTML format.")
7587 (license license:unlicense)))
7588
7589(define-public python-trio-websocket
7590 (package
7591 (name "python-trio-websocket")
7592 (version "0.12.2")
7593 (source
7594 (origin
7595 (method git-fetch)
7596 (uri (git-reference
7597 (url "https://github.com/HyperionGray/trio-websocket")
7598 (commit version)))
7599 (file-name (git-file-name name version))
7600 (sha256
7601 (base32 "1lm712gakpskcn3adna22kj8m1hspz9l68pmlziklr0ycphmyqac"))))
7602 (build-system pyproject-build-system)
7603 (native-inputs
7604 (list python-pytest
7605 python-pytest-trio
7606 python-setuptools
7607 python-trustme))
7608 (propagated-inputs
7609 (list python-outcome
7610 python-trio
7611 python-wsproto))
7612 (home-page "https://github.com/HyperionGray/trio-websocket")
7613 (synopsis "WebSocket library for Trio")
7614 (description "This library implements both server and client aspects of
7615the @url{https://tools.ietf.org/html/rfc6455, the WebSocket protocol},
7616striving for safety, correctness, and ergonomics. It is based on the
7617@url{https://wsproto.readthedocs.io/en/latest/, wsproto project}, which is a
7618@url{https://sans-io.readthedocs.io/, Sans-IO} state machine that implements
7619the majority of the WebSocket protocol, including framing, codecs, and events.
7620This library handles I/O using @url{https://trio.readthedocs.io/en/latest/,
7621the Trio framework}.")
7622 (license license:expat)))
7623
7624(define-public python-txacme
7625 ;; 0.9.3 tag was placed in 2020 and there a lot of changes providing
7626 ;; compatibility with twisted, use the latest commit from trunk branch.
7627 ;;
7628 ;;See: <https://github.com/twisted/txacme/issues/165>.
7629 (let ((commit "ac18f92f6dde971a6b38f2ecfae44665815db583")
7630 (revision "0"))
7631 (package
7632 (name "python-txacme")
7633 (version (git-version "0.9.3" revision commit))
7634 (source
7635 (origin
7636 (method git-fetch) ;no fresh release in PyPI
7637 (uri (git-reference
7638 (url "https://github.com/twisted/txacme")
7639 (commit commit)))
7640 (file-name (git-file-name name version))
7641 (sha256
7642 (base32 "0mgdfxldv8qflbn75ywslbarnd4i3l7c4krs4aibl2dpryclsjzs"))))
7643 (build-system pyproject-build-system)
7644 (arguments
7645 (list #:test-backend #~'custom
7646 #:test-flags #~(list "-m" "twisted.trial" "txacme")))
7647 (native-inputs
7648 (list python-setuptools))
7649 (propagated-inputs
7650 (list python-acme
7651 python-attrs
7652 python-eliot
7653 python-josepy
7654 python-pem
7655 python-treq
7656 python-twisted
7657 python-txsni))
7658 (home-page "https://github.com/twisted/txacme")
7659 (synopsis "Twisted implexmentation of the ACME protocol")
7660 (description
7661 "ACME is Automatic Certificate Management Environment, a protocol that
7662allows clients and certificate authorities to automate verification and
7663certificate issuance. The ACME protocol is used by the free Let's Encrypt
7664Certificate Authority.
7665
7666txacme is an implementation of the protocol for Twisted, the event-driven
7667networking engine for Python.")
7668 (license license:expat))))
7669
7670(define-public python-txaio
7671 (package
7672 (name "python-txaio")
7673 (version "25.9.2")
7674 (source
7675 (origin
7676 (method url-fetch)
7677 (uri (pypi-uri "txaio" version))
7678 (sha256
7679 (base32 "16ch62yk2gdikkak113h6qw13ns9ksca817hky0vabn0fyh08874"))))
7680 (build-system pyproject-build-system)
7681 (native-inputs
7682 (list python-pytest
7683 python-setuptools))
7684 (home-page "https://github.com/crossbario/txaio")
7685 (synopsis "Compatibility layer between Python asyncio and Twisted")
7686 (description
7687 "Txaio provides a compatibility layer between the Python @code{asyncio}
7688 bsmodule and @code{Twisted}.")
7689 (license license:expat)))
7690
7691;; XXX: Potentially abandonware since 2017, consider to remove when nothing
7692;; depends on it or fails to build.
7693(define-public python-txamqp
7694 (package
7695 (name "python-txamqp")
7696 (version "0.8.2")
7697 (source
7698 (origin
7699 (method url-fetch)
7700 (uri (pypi-uri "txAMQP" version))
7701 (sha256
7702 (base32 "0jd9864k3csc06kipiwzjlk9mq4054s8kzk5q1cfnxj8572s4iv4"))))
7703 (build-system pyproject-build-system)
7704 (arguments
7705 (list #:tests? #f)) ;all tests failed
7706 (native-inputs
7707 (list python-setuptools))
7708 (propagated-inputs
7709 (list python-six python-twisted))
7710 (home-page "https://github.com/txamqp/txamqp")
7711 (synopsis "Communicate with AMQP peers and brokers using Twisted")
7712 (description
7713 "This package provides a Python library for communicating with AMQP peers
7714and brokers using the asynchronous networking framework Twisted. It contains
7715all the necessary code to connect, send and receive messages to/from an
7716AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It
7717also includes support for using Thrift RPC over AMQP in Twisted
7718applications.")
7719 (license license:asl2.0)))
7720
7721(define-public python-txsni
7722 (package
7723 (name "python-txsni")
7724 (version "0.2.0")
7725 (source
7726 (origin
7727 (method git-fetch)
7728 (uri (git-reference
7729 (url "https://github.com/glyph/txsni")
7730 (commit (string-append "v" version))))
7731 (file-name (git-file-name name version))
7732 (sha256
7733 (base32 "1fl8xi7vl24hwbva5v41l6nsrbkj2l2mlsgcvdjxgph61aznwywq"))))
7734 (build-system pyproject-build-system)
7735 (arguments
7736 (list #:test-backend #~'custom
7737 #:test-flags #~(list "-m" "twisted.trial"
7738 "--temp-directory=/tmp/_trial_temp"
7739 "txsni")))
7740 (native-inputs
7741 (list python-setuptools))
7742 (propagated-inputs
7743 (list python-pyopenssl
7744 python-service-identity
7745 python-twisted))
7746 (home-page "https://github.com/glyph/txsni")
7747 (synopsis "Run TLS servers with Twisted")
7748 (description
7749 "This package provides an easy-to-use SNI endpoint for use with the
7750Twisted web framework.")
7751 (license license:expat)))
7752
7753(define-public python-txtorcon
7754 (package
7755 (name "python-txtorcon")
7756 (version "24.8.0")
7757 (source
7758 (origin
7759 (method url-fetch)
7760 (uri (pypi-uri "txtorcon" version))
7761 (sha256
7762 (base32 "1l4ajw4h7nay4vmllh6cs7zh3hnh8vj4yvgfnq3m734wil9ikzmy"))))
7763 (build-system pyproject-build-system)
7764 (native-inputs
7765 (list python-pytest
7766 python-setuptools
7767 python-wheel))
7768 (inputs
7769 (list lsof))
7770 (propagated-inputs
7771 (list python-automat
7772 python-idna
7773 python-incremental
7774 python-pyopenssl
7775 python-service-identity
7776 python-twisted
7777 python-zope-interface))
7778 (home-page "https://github.com/meejah/txtorcon")
7779 (synopsis "Twisted-based Tor controller client")
7780 (description
7781 "This package provides a Twisted-based Tor controller client,with
7782state-tracking and configuration abstractions.")
7783 (license license:expat)))
7784
7785(define-public python-url-normalize
7786 (package
7787 (name "python-url-normalize")
7788 (version "2.2.1")
7789 (source
7790 (origin
7791 (method git-fetch) ; no tests in PyPI release
7792 (uri (git-reference
7793 (url "https://github.com/niksite/url-normalize")
7794 (commit (string-append "v" version))))
7795 (file-name (git-file-name name version))
7796 (sha256
7797 (base32 "1yhsf4sk6l6nznpnqigisbfz690a4g342dsk2n6dggh7q4l3amk4"))))
7798 (build-system pyproject-build-system)
7799 (arguments
7800 (list
7801 #:test-flags #~(list "--ignore=tests/test_cli.py")))
7802 (native-inputs
7803 (list python-pytest python-pytest-socket python-setuptools))
7804 (propagated-inputs
7805 (list python-idna))
7806 (home-page "https://github.com/niksite/url-normalize")
7807 (synopsis "URL normalization for Python")
7808 (description
7809 "This package provides a URI Normalization function with following
7810features:
7811@itemize
7812@item take care of IDN domains
7813@item always provide the URI scheme in lowercase characters
7814@item always provide the host, if any, in lowercase characters
7815@item only perform percent-encoding where it is essential
7816@item always use uppercase A-through-F characters when percent-encoding
7817@item prevent dot-segments appearing in non-relative URI paths
7818@item for schemes that define a default authority, use an empty authority if
7819the default is desired
7820@item for schemes that define an empty path to be equivalent to a path of
7821@code{/}, use @code{/}
7822@item for schemes that define a port, use an empty port if the default is
7823desired
7824@item all portions of the URI must be utf-8 encoded NFC from Unicode strings
7825@end itemize")
7826 (license license:expat)))
7827
7828(define-public python-waitress
7829 (package
7830 (name "python-waitress")
7831 (version "3.0.2")
7832 (source
7833 (origin
7834 (method url-fetch)
7835 (uri (pypi-uri "waitress" version))
7836 (sha256
7837 (base32
7838 "07y3xyx2006f2ni5d55byh3y7w4kcg9xww7vmfjasi0cmzralak8"))))
7839 (build-system pyproject-build-system)
7840 (arguments
7841 (list
7842 ;; https://github.com/Pylons/waitress/issues/443
7843 #:test-flags #~(list "-k" "not test_service_port")))
7844 (native-inputs (list python-pytest python-setuptools))
7845 (home-page "https://github.com/Pylons/waitress")
7846 (synopsis "Waitress WSGI server")
7847 (description
7848 "Waitress is meant to be a production-quality pure-Python WSGI server
7849with very acceptable performance.")
7850 (license license:zpl2.1)))
7851
7852(define-public python-weasel
7853 (package
7854 (name "python-weasel")
7855 (version "1.0.0")
7856 (source
7857 (origin
7858 (method git-fetch)
7859 (uri (git-reference
7860 (url "https://github.com/explosion/weasel/")
7861 (commit (string-append "release-v" version))))
7862 (file-name (git-file-name name version))
7863 (sha256
7864 (base32 "1sxcxri9hl9rs1kvdrv81g6mlg7lifhq9xacskracz63v4nyh8na"))))
7865 (build-system pyproject-build-system)
7866 (arguments
7867 (list
7868 #:test-flags
7869 ;; This test raises an error, but not the one expected by pytest.
7870 #~(list (string-append "--deselect=weasel/tests/test_validation.py::"
7871 "test_project_config_interpolation[10_0]")
7872 ;; Network access is required.
7873 #$@(map (lambda (test) (string-append "--deselect="
7874 "weasel/tests/cli/"
7875 test))
7876 (list "test_cli.py::test_project_git_dir_asset"
7877 "test_cli.py::test_project_git_file_asset"
7878 "test_cli_app.py::test_project_assets")))))
7879 (native-inputs
7880 (list python-pytest
7881 python-setuptools))
7882 (propagated-inputs
7883 (list python-cloudpathlib
7884 python-confection
7885 python-httpx
7886 python-packaging
7887 python-pydantic
7888 python-smart-open
7889 python-srsly
7890 python-typer
7891 python-wasabi))
7892 (home-page "https://github.com/explosion/weasel/")
7893 (synopsis "Small and easy workflow system")
7894 (description
7895 "This package provides a minimalistic workflow system to manage and
7896share end-to-end workflows for different use cases and domains.")
7897 (license license:expat)))
7898
7899(define-public python-webencodings
7900 (package
7901 (name "python-webencodings")
7902 (version "0.5.1")
7903 (source
7904 (origin
7905 (method url-fetch)
7906 (uri (pypi-uri "webencodings" version))
7907 (sha256
7908 (base32 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
7909 (build-system pyproject-build-system)
7910 (arguments
7911 (list #:test-flags #~(list "webencodings/tests.py")))
7912 (native-inputs
7913 (list python-pytest python-setuptools))
7914 (home-page "https://github.com/SimonSapin/python-webencodings")
7915 (synopsis "Character encoding aliases for legacy web content")
7916 (description
7917 "In order to be compatible with legacy web content when interpreting
7918something like @code{Content-Type: text/html; charset=latin1}, tools need to
7919use a particular set of aliases for encoding labels as well as some overriding
7920rules. For example, @code{US-ASCII} and @code{iso-8859-1} on the web are
7921actually aliases for @code{windows-1252}, and a @code{UTF-8} or @code{UTF-16}
7922BOM takes precedence over any other encoding declaration. The WHATWG
7923@url{https://encoding.spec.whatwg.org/,Encoding} standard defines all such
7924details so that implementations do not have to reverse-engineer each other.
7925
7926This module implements the Encoding standard and has encoding labels and BOM
7927detection, but the actual implementation for encoders and decoders is
7928Python’s.")
7929 (license license:bsd-3)))
7930
7931(define-public python-omnipath
7932 (package
7933 (name "python-omnipath")
7934 (version "1.0.10")
7935 (source
7936 (origin
7937 (method git-fetch)
7938 (uri (git-reference
7939 (url "https://github.com/saezlab/omnipath/")
7940 (commit (string-append "v" version))))
7941 (file-name (git-file-name name version))
7942 (sha256
7943 (base32 "0jnc7nsn6n5hqx5wlk928b7xmg0mpfqy8al9w2p707ihcwh4s1rf"))))
7944 (build-system pyproject-build-system)
7945 (arguments
7946 (list
7947 #:test-flags '(list "-k"
7948 (string-append
7949 ;; These require internet access
7950 "not test_download_homologene"
7951 " and not test_complex_genes"
7952 ;; These tests are not compatible with pandas 3
7953 " and not test_no_dtype_conversion"
7954 " and not test_strip_resource_label_no_func"
7955 " and not test_split_unique_join_no_func"
7956 " and not test_auto_dtype"))
7957 #:phases
7958 #~(modify-phases %standard-phases
7959 (add-after 'unpack 'set-home
7960 (lambda _
7961 (setenv "HOME" "/tmp"))))))
7962 (propagated-inputs (list python-attrs
7963 python-docrep
7964 python-inflect
7965 python-networkx
7966 python-packaging
7967 python-pandas
7968 python-requests
7969 python-tqdm
7970 python-typing-extensions
7971 python-urllib3
7972 python-wrapt))
7973 (native-inputs (list nss-certs-for-test
7974 python-bump2version
7975 python-hatchling
7976 python-pytest
7977 python-pytest-mock
7978 python-pytest-socket
7979 python-requests-mock))
7980 (home-page "https://omnipathdb.org/")
7981 (synopsis "Python client for the OmniPath web service")
7982 (description "This package provides a Python client for the OmniPath web
7983service.")
7984 (license license:expat)))
7985
7986(define-public python-openai
7987 (package
7988 (name "python-openai")
7989 (version "2.42.0")
7990 (source
7991 (origin
7992 (method git-fetch)
7993 (uri (git-reference
7994 (url "https://github.com/openai/openai-python")
7995 (commit (string-append "v" version))))
7996 (file-name (git-file-name name version))
7997 (sha256
7998 (base32 "1p0vzy34cx2gfkhsqg2kxzam51cjlpa99q0skzj4426sx2hsw3g6"))))
7999 (build-system pyproject-build-system)
8000 (arguments
8001 (list
8002 #:test-flags
8003 ;; These require internet access and an openai API key.
8004 #~(list "--ignore=openai/tests/asyncio/test_endpoints.py"
8005 "--ignore=openai/tests/test_endpoints.py"
8006 "--ignore-glob=tests/api_resources/*")))
8007 (propagated-inputs
8008 (list python-aiohttp
8009 python-distro
8010 python-httpx
8011 python-jiter
8012 python-pydantic
8013 python-requests
8014 python-tqdm
8015 python-typing-extensions))
8016 (native-inputs
8017 (list nss-certs-for-test
8018 python-dirty-equals
8019 python-hatchling
8020 python-hatch-fancy-pypi-readme
8021 python-inline-snapshot
8022 python-pytest
8023 python-pytest-asyncio
8024 python-pytest-mock
8025 python-pytest-xdist
8026 python-respx
8027 python-rich
8028 python-setuptools))
8029 (home-page "https://github.com/openai/openai-python")
8030 (synopsis "Python client library for the OpenAI API")
8031 (description "This package provides a Python client library for the
8032OpenAI API.")
8033 (license license:expat)))
8034
8035(define-public python-openapi-schema-validator
8036 (package
8037 (name "python-openapi-schema-validator")
8038 (version "0.6.2")
8039 (source
8040 (origin
8041 (method git-fetch) ;no tests in pypi release
8042 (uri (git-reference
8043 (url "https://github.com/p1c2u/openapi-schema-validator")
8044 (commit version)))
8045 (file-name (git-file-name name version))
8046 (sha256
8047 (base32
8048 "0pgsm1x7lhc5ryj4l45ik8m5x9gqyi50dkflaiqqr4fnl0bsbx09"))))
8049 (build-system pyproject-build-system)
8050 (arguments
8051 (list
8052 #:test-flags
8053 ;; This one returns 5 instead of 4 elements
8054 '(list "-k" "not test_array_prefixitems_invalid")
8055 #:phases
8056 #~(modify-phases %standard-phases
8057 ;; See https://github.com/python-openapi/openapi-schema-validator/issues/204
8058 (add-after 'unpack 'relax-requirements
8059 (lambda _
8060 (substitute* "pyproject.toml"
8061 (("jsonschema-specifications.*")
8062 "jsonschema-specifications = \">=2023.5.2\"\n")))))))
8063 (native-inputs (list python-poetry-core python-pytest))
8064 (propagated-inputs
8065 (list python-isodate
8066 python-jsonschema
8067 python-rfc3339-validator
8068 python-strict-rfc3339))
8069 (home-page "https://github.com/p1c2u/openapi-schema-validator")
8070 (synopsis "OpenAPI schema validation library for Python")
8071 (description "Openapi-schema-validator is a Python library that validates
8072a schema against:
8073@itemize
8074@item OpenAPI Schema Specification v3.0 which is an extended subset of the
8075JSON Schema Specification Wright Draft 00.
8076@item OpenAPI Schema Specification v3.1 which is an extended superset of the
8077JSON Schema Specification Draft 2020-12.
8078@end itemize")
8079 (license license:bsd-3)))
8080
8081(define-public python-openapi-spec-validator
8082 (package
8083 (name "python-openapi-spec-validator")
8084 (version "0.7.1")
8085 (source
8086 (origin
8087 (method git-fetch) ;no tests in pypi release
8088 (uri (git-reference
8089 (url "https://github.com/p1c2u/openapi-spec-validator")
8090 (commit version)))
8091 (file-name (git-file-name name version))
8092 (sha256
8093 (base32
8094 "0s5yd4dbr6knwd2g1g4v2931k14n1lm80l11n2ija18yfis8yisz"))))
8095 (build-system pyproject-build-system)
8096 (arguments
8097 (list
8098 ;; These tests attempt to fetch resources from the Internet
8099 #:test-flags '(list "--ignore-glob=tests/integration/validation/**"
8100 "-k" "not example")))
8101 (native-inputs
8102 (list python-poetry-core
8103 python-pytest))
8104 (propagated-inputs
8105 (list python-jsonschema
8106 python-jsonschema-path
8107 python-lazy-object-proxy
8108 python-openapi-schema-validator
8109 python-pyyaml
8110 python-requests
8111 python-setuptools))
8112 (home-page "https://github.com/p1c2u/openapi-spec-validator")
8113 (synopsis "OpenAPI spec validator")
8114 (description "OpenAPI Spec Validator is a Python library that validates an
8115OpenAPI specification against the OpenAPI 2.0 (also known as Swagger), OpenAPI
81163.0 and OpenAPI 3.1 specifications. The validator aims to check for full
8117compliance with the specification.")
8118 (license license:asl2.0)))
8119
8120(define-public python-openapi-core
8121 (package
8122 (name "python-openapi-core")
8123 (version "0.19.4")
8124 (source
8125 (origin
8126 (method git-fetch)
8127 (uri (git-reference
8128 (url "https://github.com/p1c2u/openapi-core")
8129 (commit version)))
8130 (file-name (git-file-name name version))
8131 (sha256
8132 (base32
8133 "092sj2933jmvq5r76khr0vphih490vls1ga3s43gz8i47aqaxx96"))))
8134 (build-system pyproject-build-system)
8135 (arguments
8136 (list
8137 #:test-flags
8138 '(list "tests/unit"
8139 "-k" "not test_chars_valid")))
8140 (native-inputs (list python-django
8141 python-falcon
8142 python-flask
8143 python-mock
8144 python-poetry-core
8145 python-pytest
8146 python-pytest-asyncio
8147 python-responses))
8148 (propagated-inputs
8149 (list python-attrs
8150 python-aiohttp
8151 python-isodate
8152 python-jsonschema
8153 python-lazy-object-proxy
8154 python-more-itertools
8155 python-openapi-schema-validator
8156 python-openapi-spec-validator
8157 python-parse
8158 python-six
8159 python-werkzeug))
8160 (home-page "https://github.com/p1c2u/openapi-core")
8161 (synopsis "OpenAPI core library")
8162 (description "Openapi-core is a Python library that adds client-side and
8163server-side support for the OpenAPI Specification v3. It has features such
8164as:
8165@itemize
8166@item Validation of requests and responses
8167@item Schema casting and unmarshalling
8168@item Media type and parameters deserialization
8169@item Security providers (API keys, Cookie, Basic and Bearer HTTP
8170authentications)
8171@item Custom deserializers and formats
8172@item Integration with libraries and frameworks.
8173@end itemize")
8174 (license license:bsd-3)))
8175
8176(define-public python-openid
8177 (package
8178 (name "python-openid")
8179 (version "3.2.0")
8180 (source
8181 (origin
8182 (method git-fetch)
8183 (uri (git-reference
8184 (url "https://github.com/necaris/python3-openid")
8185 (commit (string-append "v" version))))
8186 (file-name (git-file-name name version))
8187 (sha256
8188 (base32 "1b50wmwb7k5k61zlc7d2b982i20410vp472zgl2yx8gxdnfvn8g1"))))
8189 (build-system pyproject-build-system)
8190 (arguments
8191 (list #:test-backend #~'unittest
8192 #:test-flags #~(list "openid.test.test_suite")))
8193 (propagated-inputs
8194 (list python-defusedxml))
8195 (native-inputs
8196 (list python-psycopg2 python-django python-setuptools))
8197 (home-page "https://github.com/necaris/python3-openid")
8198 (synopsis "OpenID support for servers and consumers")
8199 (description "This library provides OpenID authentication for Python, both
8200for clients and servers.")
8201 (license license:asl2.0)))
8202
8203(define-public python-openid-cla
8204 ;; XXX: Last updated in 2015.
8205 (package
8206 (name "python-openid-cla")
8207 (version "1.2")
8208 (source
8209 (origin
8210 (method url-fetch)
8211 (uri (pypi-uri "python-openid-cla" version))
8212 (sha256
8213 (base32
8214 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
8215 (build-system pyproject-build-system)
8216 (arguments '(#:tests? #f)) ; No tests.
8217 (native-inputs (list python-setuptools python-wheel))
8218 (propagated-inputs (list python-openid python-six))
8219 (home-page "https://github.com/puiterwijk/python-openid-cla/")
8220 (synopsis "Implementation of the OpenID CLA extension for python-openid")
8221 (description "@code{openid-cla} is an implementation of the OpenID
8222contributor license agreement extension for python-openid.")
8223 (license license:bsd-3)))
8224
8225(define-public python-openid-teams
8226 ;; XXX: Last updated in 2018.
8227 (package
8228 (name "python-openid-teams")
8229 (version "1.1")
8230 (source
8231 (origin
8232 (method url-fetch)
8233 (uri (pypi-uri "python-openid-teams" version))
8234 (sha256
8235 (base32
8236 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
8237 (build-system pyproject-build-system)
8238 (arguments '(#:tests? #f)) ; No tests.
8239 (native-inputs (list python-setuptools python-wheel))
8240 (propagated-inputs (list python-openid python-six))
8241 (home-page "https://github.com/puiterwijk/python-openid-teams/")
8242 (synopsis "Implementation of the OpenID teams extension for python-openid")
8243 (description
8244 "@code{openid-teams} is an implementation of the OpenID
8245teams extension for python-openid.")
8246 (license license:bsd-3)))
8247
8248(define-public python-priority
8249 (package
8250 (name "python-priority")
8251 (version "2.0.0")
8252 (source
8253 (origin
8254 (method url-fetch)
8255 (uri (pypi-uri "priority" version))
8256 (sha256
8257 (base32 "1h0qpa949bxx7za95v1apwnngkrngi695cwx8wchn3cd3d7xarf9"))))
8258 (build-system pyproject-build-system)
8259 (native-inputs
8260 (list python-pytest python-setuptools python-wheel))
8261 (home-page "https://python-hyper.org/projects/priority/en/latest/")
8262 (synopsis "Pure-Python implementation of the HTTP/2 priority tree")
8263 (description
8264 "Priority is a pure-Python implementation of the priority logic for HTTP/2,
8265set out in RFC 7540 Section 5.3 (Stream Priority).")
8266 (license license:expat)))
8267
8268(define-public python-weblate-language-data
8269 (package
8270 (name "python-weblate-language-data")
8271 (version "2025.8")
8272 (source
8273 (origin
8274 (method url-fetch)
8275 (uri (pypi-uri "weblate_language_data" version))
8276 (sha256
8277 (base32 "0byj1xl6xldam790b6wg62dk1b4i6qdlsp4lqzlv65wnp2klvrkf"))))
8278 (build-system pyproject-build-system)
8279 (arguments (list #:tests? #f)) ;not tests, just data files
8280 (native-inputs
8281 (list python-setuptools))
8282 (propagated-inputs
8283 (list python-translate-toolkit))
8284 (home-page "https://github.com/WeblateOrg/language-data")
8285 (synopsis "Language definitions for Weblate")
8286 (description
8287 "This package provides language definitions used by
8288@url{https://weblate.org/, Weblate}i.")
8289 (license license:expat)))
8290
8291(define-public python-wikidata
8292 (package
8293 (name "python-wikidata")
8294 (version "0.8.1")
8295 (source
8296 (origin
8297 (method git-fetch)
8298 (uri (git-reference
8299 (url "https://github.com/dahlia/wikidata")
8300 (commit version)))
8301 (file-name (git-file-name name version))
8302 (sha256
8303 (base32 "06zg74h249phszn1znfcjdz6c3lz350fiabdzn7iqb2xg4xh69a5"))))
8304 (build-system pyproject-build-system)
8305 (native-inputs
8306 (list python-pytest python-setuptools))
8307 (home-page "https://github.com/dahlia/wikidata")
8308 (synopsis "Wikidata client library")
8309 (description
8310 "This package provides a Python interface to @url{https://www.wikidata.org/,
8311Wikidata}.")
8312 (license license:gpl3+)))
8313
8314(define-public python-wsproto
8315 (package
8316 (name "python-wsproto")
8317 (version "1.3.2")
8318 (source
8319 (origin
8320 (method git-fetch)
8321 (uri (git-reference
8322 (url "https://github.com/python-hyper/wsproto/")
8323 (commit version)))
8324 (file-name (git-file-name name version))
8325 (sha256
8326 (base32 "1n67xnnq3mvnxp61r4d8730hh8hzrq8i9bdrv8jivhj369fhndn9"))))
8327 (build-system pyproject-build-system)
8328 (native-inputs
8329 (list python-pytest
8330 python-setuptools))
8331 (propagated-inputs
8332 (list python-h11))
8333 (home-page "https://github.com/python-hyper/wsproto/")
8334 (synopsis "WebSockets state-machine based protocol implementation")
8335 (description
8336 "@code{wsproto} is a pure-Python implementation of a WebSocket protocol
8337stack. It's written from the ground up to be embeddable in whatever program
8338you choose to use, ensuring that you can communicate via WebSockets, as
8339defined in RFC6455, regardless of your programming paradigm.")
8340 (license license:expat)))
8341
8342(define-public hypercorn
8343 (package
8344 (name "hypercorn")
8345 (version "0.18.0")
8346 (source
8347 (origin
8348 (method git-fetch) ;PyPI does not have tests
8349 (uri (git-reference
8350 (url "https://github.com/pgjones/hypercorn")
8351 (commit version)))
8352 (file-name (git-file-name name version))
8353 (sha256
8354 (base32 "0jdi05n5isxn0rysq242p198lz03gbwsnizzb9yp6rxr7ajapns4"))))
8355 (build-system pyproject-build-system)
8356 ;; Propagate because Hypercorn also exposes functionality over a module.
8357 (propagated-inputs (list python-h11
8358 python-h2
8359 python-priority
8360 python-tomli
8361 python-wsproto))
8362 (native-inputs (list nss-certs-for-test
8363 python-httpx
8364 python-pdm-backend
8365 python-poetry-core
8366 python-pytest
8367 python-pytest-asyncio
8368 python-pytest-trio
8369 python-trio))
8370 (home-page "https://gitlab.com/pgjones/hypercorn/")
8371 (synopsis "ASGI Server based on Hyper libraries")
8372 (description
8373 "Hypercorn is an ASGI web server based on the sans-io hyper, h11, h2, and
8374wsproto libraries and inspired by Gunicorn. It supports HTTP/1, HTTP/2,
8375WebSockets (over HTTP/1 and HTTP/2), ASGI/2, and ASGI/3 specifications. It
8376can utilise asyncio, uvloop, or trio worker types.")
8377 (license license:expat)))
8378
8379(define-public python-querystring-parser
8380 (package
8381 (name "python-querystring-parser")
8382 (version "1.2.4")
8383 (source
8384 (origin
8385 (method git-fetch)
8386 (uri (git-reference
8387 (url "https://github.com/bernii/querystring-parser")
8388 (commit version)))
8389 (file-name (git-file-name name version))
8390 (sha256
8391 (base32 "15n89bf1x9dgp1vi697pa238nvn0vbqp3ghf0xrcyqqa9gn1l6fb"))))
8392 (build-system pyproject-build-system)
8393 (arguments
8394 (list
8395 #:test-backend #~'custom
8396 #:test-flags #~(list "querystring_parser/tests.py")
8397 #:phases
8398 #~(modify-phases %standard-phases
8399 (add-after 'unpack 'fix-python-incompatibilities
8400 (lambda _
8401 (substitute* "querystring_parser/tests.py"
8402 ;; XXX FIXME: This test is broken with Python 3.7:
8403 ;; https://github.com/bernii/querystring-parser/issues/35
8404 (("self\\.assertEqual\\(self\\.knownValuesNormalized, result\\)")
8405 "True")
8406 ;; Removed in Python 3.12.
8407 (("assertEquals")
8408 "assertEqual")))))))
8409 (native-inputs (list python-setuptools))
8410 (propagated-inputs (list python-six))
8411 (home-page "https://github.com/bernii/querystring-parser")
8412 (synopsis "QueryString parser that correctly handles nested dictionaries")
8413 (description
8414 "This package provides a query string parser for Python and Django
8415projects that correctly creates nested dictionaries from sent form/querystring
8416data.")
8417 (license license:expat)))
8418
8419(define-public python-tornado
8420 (package
8421 (name "python-tornado")
8422 (version "6.4.2")
8423 (source
8424 (origin
8425 (method url-fetch)
8426 (uri (pypi-uri "tornado" version))
8427 (sha256
8428 (base32 "02v2mlvr58xg0l0gh08nswl53z73wkf23sziggypk63ffjsdbflj"))))
8429 (build-system pyproject-build-system)
8430 (arguments
8431 (list
8432 #:test-flags
8433 ;; AttributeError: 'TestIOStreamWebMixin' object has no attribute 'io_loop'
8434 #~(list "--ignore=tornado/test/iostream_test.py")))
8435 (native-inputs
8436 (list python-certifi
8437 python-pytest
8438 python-setuptools))
8439 (home-page "https://www.tornadoweb.org/")
8440 (synopsis "Python web framework and asynchronous networking library")
8441 (description
8442 "Tornado is a Python web framework and asynchronous networking library,
8443originally developed at FriendFeed. By using non-blocking network I/O,
8444Tornado can scale to tens of thousands of open connections, making it ideal
8445for long polling, WebSockets, and other applications that require a long-lived
8446connection to each user.")
8447 (license license:asl2.0)))
8448
8449(define-public python-tornado-http-auth
8450 (package
8451 (name "python-tornado-http-auth")
8452 (version "1.1.1")
8453 (source
8454 (origin
8455 (method git-fetch)
8456 (uri (git-reference
8457 (url "https://github.com/gvalkov/tornado-http-auth")
8458 (commit (string-append "v" version))))
8459 (file-name (git-file-name name version))
8460 (sha256
8461 (base32 "1v9sin1zlck9wvkwx0ldqb1b271xlkq63562w8g1yb7v6qka9q4f"))))
8462 (build-system pyproject-build-system)
8463 ;; XXX: This version is incompatible with current tornado.testing.
8464 (arguments (list #:tests? #f))
8465 (native-inputs (list python-setuptools))
8466 (propagated-inputs (list python-tornado))
8467 (home-page "https://github.com/gvalkov/tornado-http-auth")
8468 (synopsis "Digest and basic authentication module for Tornado")
8469 (description
8470 "Provides support for adding authentication to services using the Tornado
8471web framework, either via the basic or digest authentication schemes.")
8472 (license license:asl2.0)))
8473
8474(define-public python-wsgi-intercept
8475 (package
8476 (name "python-wsgi-intercept")
8477 (version "1.13.1")
8478 (source (origin
8479 (method url-fetch)
8480 (uri (pypi-uri "wsgi_intercept" version))
8481 (sha256
8482 (base32
8483 "1h94dj7h7n7zdj3ll4imqjhq5vk21yidk2niwnmpw7xik9inrgbr"))))
8484 (build-system pyproject-build-system)
8485 (arguments
8486 (list
8487 ;; XXX: tests required internet access
8488 #:tests? #f))
8489 (propagated-inputs
8490 (list python-six))
8491 (native-inputs
8492 (list python-httplib2
8493 python-pytest
8494 python-requests
8495 python-setuptools
8496 python-urllib3
8497 python-wheel))
8498 (synopsis "Puts a WSGI application in place of a real URI for testing")
8499 (description "Wsgi_intercept installs a WSGI application in place of a real
8500URI for testing. Testing a WSGI application normally involves starting a
8501server at a local host and port, then pointing your test code to that address.
8502Instead, this library lets you intercept calls to any specific host/port
8503combination and redirect them into a WSGI application importable by your test
8504program. Thus, you can avoid spawning multiple processes or threads to test
8505your Web app.")
8506 (home-page "https://github.com/cdent/wsgi-intercept")
8507 (license license:expat)))
8508
8509(define-public python-webob
8510 (package
8511 (name "python-webob")
8512 (version "1.8.10")
8513 (source
8514 (origin
8515 (method url-fetch)
8516 (uri (pypi-uri "webob" version))
8517 (sha256
8518 (base32
8519 "0avwfsqqva46aix1p61jbwjsw7kh6zkxvfds9xi3zg07yc8km5hw"))))
8520 (build-system pyproject-build-system)
8521 ;; tests: 2394 passed, 9 skipped, 1 xfailed, 35 warnings
8522 (native-inputs
8523 (list python-pytest
8524 python-setuptools))
8525 (home-page "https://webob.org/")
8526 (synopsis "WSGI request and response object")
8527 (description
8528 "WebOb provides wrappers around the WSGI request environment, and an
8529object to help create WSGI responses.")
8530 (license license:expat)))
8531
8532(define-public python-yewtube-search
8533 (package
8534 (name "python-yewtube-search")
8535 ;; Original repository for python-youtube-search package is archived, see:
8536 ;; <https://github.com/alexmercerind/youtube-search-python/issues/189>.
8537 ;; The most promising fork was
8538 ;; <https://github.com/ahmedayyad-dev/youtube-search-python-fork> which is
8539 ;; archived since <2026-04-04>. This is another fork with a different PyPI
8540 ;; name for python-yewtube.
8541 (version "1.6.7")
8542 (source
8543 (origin
8544 (method url-fetch)
8545 (uri (pypi-uri "yewtube_search_python" version))
8546 (sha256
8547 (base32 "0vjh4wrlqx4lv9qi6572jx2d0rsp6gkvaqf0f2ar4npdz0ldgl47"))))
8548 (build-system pyproject-build-system)
8549 (arguments (list #:tests? #f)) ;no tests in repository
8550 (native-inputs
8551 (list python-setuptools))
8552 (propagated-inputs
8553 (list python-httpx))
8554 (home-page "https://github.com/iamtalhaasghar/youtube-search-python")
8555 (synopsis "Search for YouTube videos, channels & playlists")
8556 (description
8557 "This package provides tools to search for @code{YouTube} videos,
8558channels and playlists; as well as getting video metadata from links. This
8559package does not rely on the @code{YouTube} Data API v3.")
8560 (license license:expat)))
8561
8562(define-public python-zc-lockfile
8563 (package
8564 (name "python-zc-lockfile")
8565 (version "4.0")
8566 (source
8567 (origin
8568 (method git-fetch)
8569 (uri (git-reference
8570 (url "https://github.com/zopefoundation/zc.lockfile")
8571 (commit version)))
8572 (file-name (git-file-name name version))
8573 (sha256
8574 (base32 "0b1kkwx2d4wf392sd3bfjvzgkdrknwsxg9mby121mq8zl7c490gg"))))
8575 (build-system pyproject-build-system)
8576 (arguments
8577 (list
8578 #:phases
8579 #~(modify-phases %standard-phases
8580 (replace 'check
8581 (lambda* (#:key tests? #:allow-other-keys)
8582 (if tests?
8583 (invoke "zope-testrunner" "--test-path=src")
8584 (format #t "test suite not run~%")))))))
8585 (native-inputs (list python-zope-testing python-zope-testrunner
8586 python-setuptools))
8587 (home-page "https://github.com/zopefoundation/zc.lockfile")
8588 (synopsis "Interprocess locks using lock files")
8589 (description
8590 "This package provides an implementation of interprocess locks using lock
8591files. These locks can also be used to mediate access to other files.")
8592 (license license:zpl2.1)))
8593
8594(define-public python-zconfig
8595 (package
8596 (name "python-zconfig")
8597 (version "4.3")
8598 (source
8599 (origin
8600 (method git-fetch)
8601 (uri (git-reference
8602 (url "https://github.com/zopefoundation/ZConfig/")
8603 (commit version)))
8604 (file-name (git-file-name name version))
8605 (sha256
8606 (base32 "06c4vffk51fw03q87r31s81b0xbxg2qqvjfmcl2z4hg21fr088c2"))))
8607 (build-system pyproject-build-system)
8608 (arguments
8609 (list
8610 #:phases
8611 #~(modify-phases %standard-phases
8612 (replace 'check
8613 (lambda* (#:key tests? #:allow-other-keys)
8614 (if tests?
8615 (begin
8616 ;; This test assumes we still have setup.py in the
8617 ;; directory from which we import zconfig, which
8618 ;; does not work after installing the package.
8619 (delete-file-recursively
8620 "src/ZConfig/tests/test_readme.py")
8621 (invoke "zope-testrunner" "-vv" "--test-path=src" "--all"))
8622 (format #t "test suite not run~%")))))))
8623 (native-inputs (list python-docutils python-manuel python-zope-exceptions
8624 python-zope-testrunner python-setuptools))
8625 (home-page "https://github.com/zopefoundation/ZConfig/")
8626 (synopsis "Structured configuration library intended for general use")
8627 (description
8628 "@code{zconfig} is a configuration library intended for general use. It
8629supports a hierarchical schema-driven configuration model that allows a schema
8630to specify data conversion routines written in Python. Its model is very
8631different from the model supported by the @code{configparser} module found in
8632Python's standard library, and is more suitable to configuration-intensive
8633applications.")
8634 (license license:zpl2.1)))
8635
8636(define-public python-zodb
8637 (package
8638 (name "python-zodb")
8639 (version "6.0.1")
8640 (source
8641 (origin
8642 (method url-fetch)
8643 (uri (pypi-uri "zodb" version))
8644 (sha256
8645 (base32 "02cmvf8j2nin5z26wvy2vq2k9mj12hqrr4276lj3w4jj32p0zxw9"))))
8646 (build-system pyproject-build-system)
8647 (arguments
8648 (list
8649 #:phases
8650 #~(modify-phases %standard-phases
8651 (replace 'check
8652 (lambda* (#:key tests? #:allow-other-keys)
8653 (if tests?
8654 (begin
8655 ;; This test does not work after installing the
8656 ;; package, since it expects the ZODB source code
8657 ;; to reside in the src/ directory.
8658 (delete-file-recursively
8659 "src/ZODB/tests/testdocumentation.py")
8660 (invoke "zope-testrunner" "-vv" "--test-path=src"
8661 "--all"))
8662 (format #t "test suite not run~%")))))))
8663 (native-inputs
8664 (list python-manuel
8665 python-wheel
8666 python-zope-testing
8667 python-zope-testrunner))
8668 (propagated-inputs
8669 (list python-btrees
8670 python-persistent
8671 python-transaction
8672 python-zc-lockfile
8673 python-zconfig
8674 python-zodbpickle
8675 python-zope-interface))
8676 (home-page "http://zodb-docs.readthedocs.io")
8677 (synopsis "Object-oriented database for Python")
8678 (description
8679 "@code{ZODB} provides an object-oriented and @acronym{ACID,
8680Atomicity Consistency Isolation Durability} compliant database for Python with
8681a high degree of transparency. @code{ZODB} is an object-oriented database,
8682not an object-relational mapping. This comes with several advantaged:
8683
8684@itemize
8685@item no separate language for database operations
8686@item very little impact on your code to make objects persistent
8687@item no database mapper that partially hides the database.
8688@item almost no seam between code and database.
8689@end itemize")
8690 (license license:zpl2.1)))
8691
8692(define-public python-zodbpickle
8693 (package
8694 (name "python-zodbpickle")
8695 (version "3.2")
8696 (source
8697 (origin
8698 (method url-fetch)
8699 (uri (pypi-uri "zodbpickle" version))
8700 (sha256
8701 (base32 "035bjrksl4h92mvjkx6id4gjcpc1k4mbci8ryjl6l9mki7ihx77b"))))
8702 (build-system pyproject-build-system)
8703 (arguments
8704 '(#:phases (modify-phases %standard-phases
8705 (replace 'check
8706 (lambda* (#:key tests? #:allow-other-keys)
8707 (if tests?
8708 (invoke "zope-testrunner" "-vv" "--test-path=src"
8709 "--all")
8710 (format #t "test suite not run~%")))))))
8711 (native-inputs (list python-zope-testrunner python-setuptools python-wheel))
8712 (home-page "https://github.com/zopefoundation/zodbpickle")
8713 (synopsis "Uniform pickling interface for @code{zodb}")
8714 (description
8715 "This package is a fork of the @code{pickle} module (and the
8716supporting C extension) from both Python 3.2 and Python 3.3. The fork adds
8717support for the @code{noload} operations used by @code{zodb}.")
8718 (license (list license:psfl license:zpl2.1))))
8719
8720(define-public python-zope-dottedname
8721 (package
8722 (name "python-zope-dottedname")
8723 (version "7.0")
8724 (source
8725 (origin
8726 (method git-fetch)
8727 (uri (git-reference
8728 (url "https://github.com/zopefoundation/zope.dottedname")
8729 (commit version)))
8730 (file-name (git-file-name name version))
8731 (sha256
8732 (base32 "0h7a637zsl1a3f0rpb2nw41mzxv0pqyj8ahn6h60n2c1px912rbd"))))
8733 (build-system pyproject-build-system)
8734 (arguments
8735 (list #:test-backend #~'custom
8736 #:test-flags #~(list "src/zope/dottedname/tests.py")))
8737 (native-inputs (list python-setuptools))
8738 (home-page "https://zopedottedname.readthedocs.io")
8739 (synopsis "Resolver for Python dotted names")
8740 (description
8741 "This package provides a @code{resolve()} function that resolves strings
8742containing dotted names into the appropriate Python object.")
8743 (license license:zpl2.1)))
8744
8745(define-public python-zope-event
8746 (package
8747 (name "python-zope-event")
8748 (version "6.0")
8749 (source
8750 (origin
8751 (method git-fetch)
8752 (uri (git-reference
8753 (url "https://github.com/zopefoundation/zope.event")
8754 (commit version)))
8755 (file-name (git-file-name name version))
8756 (sha256
8757 (base32 "0la3q47c59aq50s036q468bhnmzgs71f1cygv89w6qkk1hkn35ym"))))
8758 (build-system pyproject-build-system)
8759 (arguments
8760 (list
8761 #:test-flags
8762 #~(list "src/zope/event/tests.py")))
8763 (native-inputs (list python-pytest python-setuptools))
8764 (home-page "https://zopeevent.readthedocs.io/en/latest/")
8765 (synopsis "Event publishing system for Python")
8766 (description
8767 "Zope.event provides an event publishing API, intended for use by
8768applications which are unaware of any subscribers to their events. It is a
8769simple event-dispatching system on which more sophisticated event dispatching
8770systems can be built.")
8771 (license license:zpl2.1)))
8772
8773(define-public python-zope-interface
8774 (package
8775 (name "python-zope-interface")
8776 (version "7.2")
8777 (source
8778 (origin
8779 (method git-fetch)
8780 (uri (git-reference
8781 (url "https://github.com/zopefoundation/zope.interface")
8782 (commit version)))
8783 (file-name (git-file-name name version))
8784 (sha256
8785 (base32 "01snm1lbqhx3ird4m76nciaqasxvf8dd6817zm35v684g5hbzd2s"))))
8786 (build-system pyproject-build-system)
8787 (arguments
8788 ;; XXX: test suite can't find python-zope-testing
8789 (list #:tests? #f))
8790 (native-inputs (list python-setuptools))
8791 (home-page "https://zopeinterface.readthedocs.io")
8792 (synopsis "\"Design by contract\" methodology in Python")
8793 (description
8794 "Zope.interface provides an implementation of \"object interfaces\" for
8795Python. Interfaces are a mechanism for labeling objects as conforming to a
8796given API or contract.")
8797 (license license:zpl2.1)))
8798
8799(define-public python-zope-exceptions
8800 (package
8801 (name "python-zope-exceptions")
8802 (version "6.0")
8803 (source
8804 (origin
8805 (method git-fetch)
8806 (uri (git-reference
8807 (url "https://github.com/zopefoundation/zope.exceptions")
8808 (commit version)))
8809 (file-name (git-file-name name version))
8810 (sha256
8811 (base32 "0fmsw2j8islaiv6zf2mxh2s43y7virqny6s8gk8v2zkcxpy95cic"))))
8812 (build-system pyproject-build-system)
8813 (arguments
8814 (list
8815 #:phases
8816 #~(modify-phases %standard-phases
8817 (replace 'check
8818 (lambda* (#:key tests? #:allow-other-keys)
8819 (if tests?
8820 (invoke "zope-testrunner" "--test-path=src")
8821 (format #t "test suite not run~%")))))))
8822 (native-inputs (list python-setuptools python-zope-testrunner-bootstrap))
8823 (propagated-inputs (list python-zope-interface))
8824 (home-page "https://github.com/zopefoundation/zope.exceptions")
8825 (synopsis "Zope exceptions")
8826 (description
8827 "Zope.exceptions provides general-purpose exception types that have uses
8828outside of the Zope framework.")
8829 (license license:zpl2.1)))
8830
8831(define (python-zope-bootstrap-package orig)
8832 (package
8833 (inherit orig)
8834 (name (string-append (package-name orig) "-bootstrap"))
8835 (arguments
8836 (if (null? (package-arguments orig))
8837 (list
8838 #:tests? #f
8839 #:phases #~(modify-phases %standard-phases
8840 (delete 'sanity-check)))
8841 (substitute-keyword-arguments arguments
8842 ((#:tests? _ #f) #f)
8843 ((#:phases phases '%standard-phases)
8844 #~(modify-phases #$phases
8845 (delete 'sanity-check))))))
8846 (propagated-inputs `())
8847 (native-inputs (list python-setuptools))
8848 (properties `((hidden? . #t)))))
8849
8850(define-public python-zope-exceptions-bootstrap
8851 (python-zope-bootstrap-package python-zope-exceptions))
8852
8853(define-public python-zope-testing
8854 (package
8855 (name "python-zope-testing")
8856 (version "6.0")
8857 (source
8858 (origin
8859 (method git-fetch)
8860 (uri (git-reference
8861 (url "https://github.com/zopefoundation/zope.testing")
8862 (commit version)))
8863 (file-name (git-file-name name version))
8864 (sha256
8865 (base32 "0zqipsgv7qj7f8hrd3x6xpqwszdiac8vpjdm8ak5kljl5napw7d7"))))
8866 (build-system pyproject-build-system)
8867 (arguments
8868 (list
8869 #:phases
8870 #~(modify-phases %standard-phases
8871 (replace 'check
8872 (lambda* (#:key tests? #:allow-other-keys)
8873 (if tests?
8874 (invoke "zope-testrunner" "--test-path=src")
8875 (format #t "test suite not run~%")))))))
8876 (native-inputs (list python-setuptools
8877 python-zope-interface
8878 python-zope-testrunner-bootstrap))
8879 (home-page "https://zopetesting.readthedocs.io/")
8880 (synopsis "Zope testing helpers")
8881 (description
8882 "Zope.testing provides a number of testing utilities for HTML forms, HTTP
8883servers, regular expressions, and more.")
8884 (license license:zpl2.1)))
8885
8886(define-public python-zope-testrunner
8887 (package
8888 (name "python-zope-testrunner")
8889 (version "7.4")
8890 (source
8891 (origin
8892 (method git-fetch)
8893 (uri (git-reference
8894 (url "https://github.com/zopefoundation/zope.testrunner")
8895 (commit version)))
8896 (file-name (git-file-name name version))
8897 (sha256
8898 (base32 "0gd5rnzw6vzbx766jxqr4zc6qx7gk75r2c0nqqvhkb12hzk5ca2g"))))
8899 (build-system pyproject-build-system)
8900 (arguments
8901 (list
8902 #:phases
8903 #~(modify-phases %standard-phases
8904 (add-after 'unpack 'remove-problematic-test
8905 (lambda _
8906 ;; This test contains invalid syntax, which breaks bytecode
8907 ;; compilation. For simplicity just remove it.
8908 (delete-file
8909 "src/zope/testrunner/tests/testrunner-ex/sample2/badsyntax.py")))
8910 (replace 'check
8911 (lambda* (#:key tests? #:allow-other-keys)
8912 (if tests?
8913 (invoke "zope-testrunner" "--test-path=src")
8914 (format #t "test suite not run~%")))))))
8915 (native-inputs (list python-setuptools python-zope-testing))
8916 (propagated-inputs (list python-zope-exceptions python-zope-interface))
8917 (home-page "https://zopetestrunner.readthedocs.io")
8918 (synopsis "Zope testrunner script")
8919 (description "This package provides a script for running Python tests.")
8920 (license license:zpl2.1)))
8921
8922(define-public python-zope-testrunner-bootstrap
8923 (package
8924 (inherit (python-zope-bootstrap-package python-zope-testrunner))
8925 (propagated-inputs
8926 (list python-six python-zope-exceptions-bootstrap))
8927 (properties `((hidden? . #t)))))
8928
8929(define-public python-zope-i18nmessageid
8930 (package
8931 (name "python-zope-i18nmessageid")
8932 (version "7.0")
8933 (source
8934 (origin
8935 (method git-fetch)
8936 (uri (git-reference
8937 (url "https://github.com/zopefoundation/zope.i18nmessageid")
8938 (commit version)))
8939 (file-name (git-file-name name version))
8940 (sha256
8941 (base32 "192ixj8r9n467avbxrmhakmqiaflc1vw37k08z096ajcjgbfrm5d"))))
8942 (build-system pyproject-build-system)
8943 (arguments
8944 (list
8945 #:phases
8946 #~(modify-phases %standard-phases
8947 (replace 'check
8948 (lambda* (#:key tests? #:allow-other-keys)
8949 (if tests?
8950 (invoke "zope-testrunner" "--test-path=src")
8951 (format #t "test suite not run~%")))))))
8952 (native-inputs (list python-setuptools python-zope-testrunner))
8953 (home-page "https://zopei18nmessageid.readthedocs.io")
8954 (synopsis "Message identifiers for internationalization")
8955 (description "Zope.i18nmessageid provides facilities for declaring
8956internationalized messages within program source text.")
8957 (license license:zpl2.1)))
8958
8959(define-public python-zope-schema
8960 (package
8961 (name "python-zope-schema")
8962 (version "7.0.1")
8963 (source
8964 (origin
8965 (method git-fetch)
8966 (uri (git-reference
8967 (url "https://github.com/zopefoundation/zope.schema")
8968 (commit version)))
8969 (file-name (git-file-name name version))
8970 (sha256
8971 (base32 "1hj6j0gqgvv9a5pyaz54wbn8n7wf9lyg4njb2cfs980z0d5faj39"))))
8972 (build-system pyproject-build-system)
8973 (arguments
8974 (list
8975 #:phases
8976 #~(modify-phases %standard-phases
8977 (replace 'check
8978 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
8979 (add-installed-pythonpath inputs outputs)
8980 (if tests?
8981 (invoke "zope-testrunner" "--test-path=src")
8982 (format #t "test suite not run.~%")))))))
8983 (propagated-inputs (list python-zope-event python-zope-interface))
8984 (native-inputs (list python-zope-i18nmessageid python-zope-testing
8985 python-zope-testrunner python-setuptools))
8986 (home-page "https://zopeschema.readthedocs.io")
8987 (synopsis "Zope data schemas")
8988 (description "Zope.scheme provides extensions to zope.interface for
8989defining data schemas.")
8990 (license license:zpl2.1)))
8991
8992(define-public python-zope-sqlalchemy
8993 (package
8994 (name "python-zope-sqlalchemy")
8995 (version "1.6")
8996 (source
8997 (origin
8998 (method git-fetch)
8999 (uri (git-reference
9000 (url "https://github.com/zopefoundation/zope.sqlalchemy")
9001 (commit version)))
9002 (file-name (git-file-name name version))
9003 (sha256
9004 (base32 "1z4gw4i95dyqxsvrahk4fav008045n8kyxpn3fa887snmpvcjhng"))))
9005 (build-system pyproject-build-system)
9006 (arguments
9007 (list
9008 #:phases
9009 #~(modify-phases %standard-phases
9010 (replace 'check
9011 (lambda* (#:key tests? #:allow-other-keys)
9012 (if tests?
9013 (invoke "zope-testrunner" "--test-path=src")
9014 (format #t "test suite not run~%")))))))
9015 (propagated-inputs (list python-sqlalchemy python-transaction
9016 python-zope-interface))
9017 (native-inputs (list python-zope-testing python-zope-testrunner
9018 python-setuptools))
9019 (home-page "https://github.com/zopefoundation/zope.sqlalchemy")
9020 (synopsis "Minimal SQLAlchemy transaction integration for Zope")
9021 (description
9022 "The aim of this package is to unify the plethora of existing packages
9023integrating SQLAlchemy with Zope's transaction management. As such,it only
9024provides a data manager and makes no attempt to define a @i{zopeish} way to
9025configure engines.")
9026 (license license:zpl2.1)))
9027
9028(define-public python-zope-configuration
9029 (package
9030 (name "python-zope-configuration")
9031 (version "7.0")
9032 (source
9033 (origin
9034 (method git-fetch)
9035 (uri (git-reference
9036 (url "https://github.com/zopefoundation/zope.configuration")
9037 (commit version)))
9038 (file-name (git-file-name name version))
9039 (sha256
9040 (base32 "11lr6z3jpz9835a1if89g3x7k31sviq2d0xvvic5xi4c980dbkhv"))))
9041 (build-system pyproject-build-system)
9042 (arguments
9043 (list
9044 #:phases
9045 #~(modify-phases %standard-phases
9046 (replace 'check
9047 (lambda* (#:key tests? #:allow-other-keys)
9048 (if tests?
9049 (invoke "zope-testrunner" "--test-path=src")
9050 (format #t "test suite not run~%")))))))
9051 (native-inputs (list python-manuel python-setuptools python-zope-testing
9052 python-zope-testrunner))
9053 (propagated-inputs (list python-zope-i18nmessageid python-zope-interface
9054 python-zope-schema))
9055 (home-page "https://zopeconfiguration.readthedocs.io")
9056 (synopsis "Zope Configuration Markup Language")
9057 (description "Zope.configuration implements ZCML, the Zope Configuration
9058Markup Language.")
9059 (license license:zpl2.1)))
9060
9061(define-public python-zope-configuration-bootstrap
9062 (python-zope-bootstrap-package python-zope-configuration))
9063
9064(define-public python-zope-copy
9065 (package
9066 (name "python-zope-copy")
9067 (version "6.0")
9068 (source
9069 (origin
9070 (method git-fetch)
9071 (uri (git-reference
9072 (url "https://github.com/zopefoundation/zope.copy")
9073 (commit version)))
9074 (file-name (git-file-name name version))
9075 (sha256
9076 (base32 "1ym82p9scpfi3rflxnlv55v0a7hra3rq4rrlw759maq05i8qp1w5"))))
9077 (build-system pyproject-build-system)
9078 (arguments
9079 (list
9080 #:phases
9081 #~(modify-phases %standard-phases
9082 (replace 'check
9083 (lambda* (#:key tests? #:allow-other-keys)
9084 (if tests?
9085 (invoke "zope-testrunner" "--test-path=src")
9086 (format #t "test suite not run~%")))))))
9087 (propagated-inputs (list python-zope-interface))
9088 (native-inputs
9089 (list python-zodbpickle
9090 python-zope-component-bootstrap
9091 python-zope-location-bootstrap
9092 python-zope-proxy
9093 python-zope-schema
9094 python-zope-testing
9095 python-zope-testrunner
9096 python-setuptools))
9097 (home-page "https://zopecopy.readthedocs.io")
9098 (synopsis "Pluggable object copying mechanism")
9099 (description
9100 "This package provides a pluggable mechanism for copying persistent objects.")
9101 (license license:zpl2.1)))
9102
9103(define-public python-zope-proxy
9104 (package
9105 (name "python-zope-proxy")
9106 (version "7.0")
9107 (source
9108 (origin
9109 (method git-fetch)
9110 (uri (git-reference
9111 (url "https://github.com/zopefoundation/zope.proxy")
9112 (commit version)))
9113 (file-name (git-file-name name version))
9114 (sha256
9115 (base32 "00r9f4n0cl3fyc5gyf5l43zh95cmzx1gz6wr04k17d7wm2gmivyn"))))
9116 (build-system pyproject-build-system)
9117 (arguments
9118 (list
9119 #:phases
9120 #~(modify-phases %standard-phases
9121 (replace 'check
9122 (lambda* (#:key tests? #:allow-other-keys)
9123 (if tests?
9124 (invoke "zope-testrunner" "--test-path=src")
9125 (format #t "test suite not run~%")))))))
9126 (native-inputs
9127 (list python-zope-location-bootstrap
9128 python-zope-security-bootstrap
9129 python-zope-testrunner
9130 python-setuptools))
9131 (propagated-inputs (list python-zope-interface))
9132 (home-page "https://zopeproxy.readthedocs.io")
9133 (synopsis "Generic, transparent proxies")
9134 (description
9135 "Zope.proxy provides generic, transparent proxies for Python. Proxies are
9136special objects which serve as mostly-transparent wrappers around another
9137object, intervening in the apparent behavior of the wrapped object only when
9138necessary to apply the policy (e.g., access checking, location brokering,
9139etc.) for which the proxy is responsible.")
9140 (license license:zpl2.1)))
9141
9142(define-public python-zope-proxy-bootstrap
9143 (python-zope-bootstrap-package python-zope-proxy))
9144
9145(define-public python-zope-hookable
9146 (package
9147 (name "python-zope-hookable")
9148 (version "7.0")
9149 (source
9150 (origin
9151 (method git-fetch)
9152 (uri (git-reference
9153 (url "https://github.com/zopefoundation/zope.hookable")
9154 (commit version)))
9155 (file-name (git-file-name name version))
9156 (sha256
9157 (base32 "1l94xzzpyslpgv2ghvl5qzpfcsq02kp04fmvl95d6jcmivmmr4m8"))))
9158 (build-system pyproject-build-system)
9159 (arguments
9160 (list
9161 #:phases
9162 #~(modify-phases %standard-phases
9163 (replace 'check
9164 (lambda* (#:key tests? #:allow-other-keys)
9165 (if tests?
9166 (invoke "zope-testrunner" "--test-path=src")
9167 (format #t "test suite not run~%")))))))
9168 (native-inputs (list python-zope-testing python-zope-testrunner
9169 python-setuptools))
9170 (home-page "https://zopehookable.readthedocs.io")
9171 (synopsis "Zope hookable")
9172 (description
9173 "This package supports the efficient creation of hookable objects, which
9174are callable objects that are meant to be optionally replaced. The idea is
9175that you create a function that does some default thing and make i hookable.
9176Later, someone can modify what it does by calling its sethook method and
9177changing its implementation. All users of the function, including those that
9178imported it, will see the change.")
9179 (license license:zpl2.1)))
9180
9181(define-public python-zope-location
9182 (package
9183 (name "python-zope-location")
9184 (version "6.0")
9185 (source
9186 (origin
9187 (method git-fetch)
9188 (uri (git-reference
9189 (url "https://github.com/zopefoundation/zope.location")
9190 (commit version)))
9191 (file-name (git-file-name name version))
9192 (sha256
9193 (base32 "1jfsmbxj6hz7kmk5b0351b63ssm7qfkgqmz9v7xb7wwlmxsxkcdk"))))
9194 (build-system pyproject-build-system)
9195 (arguments
9196 (list
9197 #:phases
9198 #~(modify-phases %standard-phases
9199 (replace 'check
9200 (lambda* (#:key tests? #:allow-other-keys)
9201 (if tests?
9202 (invoke "zope-testrunner" "--test-path=src")
9203 (format #t "test suite not run~%")))))))
9204 (native-inputs (list python-zope-testrunner python-setuptools))
9205 (propagated-inputs (list python-zope-interface python-zope-proxy
9206 python-zope-schema))
9207 (home-page "https://zopelocation.readthedocs.io")
9208 (synopsis "Zope location library")
9209 (description
9210 "Zope.location implements the concept of \"locations\" in Zope3, which
9211are are special objects that have a structural location.")
9212 (license license:zpl2.1)))
9213
9214(define-public python-zope-location-bootstrap
9215 (python-zope-bootstrap-package python-zope-location))
9216
9217(define-public python-zope-security
9218 (package
9219 (name "python-zope-security")
9220 (version "7.3")
9221 (source
9222 (origin
9223 (method git-fetch)
9224 (uri (git-reference
9225 (url "https://github.com/zopefoundation/zope.security")
9226 (commit version)))
9227 (file-name (git-file-name name version))
9228 (sha256
9229 (base32 "06x6qcls2mdl05xnsyy5h70mbgij8xb6ksxbawzrc23cq04nkvx7"))))
9230 (build-system pyproject-build-system)
9231 (arguments
9232 (list
9233 #:phases
9234 #~(modify-phases %standard-phases
9235 (replace 'check
9236 (lambda* (#:key tests? #:allow-other-keys)
9237 (if tests?
9238 (invoke "zope-testrunner" "--test-path=src")
9239 (format #t "test suite not run~%")))))))
9240 (propagated-inputs
9241 (list python-zope-component
9242 python-zope-i18nmessageid
9243 python-zope-interface
9244 python-zope-location
9245 python-zope-proxy
9246 python-zope-schema))
9247 (native-inputs
9248 (list python-btrees
9249 python-zope-component-bootstrap
9250 python-zope-configuration-bootstrap
9251 python-zope-location-bootstrap
9252 python-zope-testing
9253 python-zope-testrunner
9254 python-setuptools))
9255 (home-page "https://zopesecurity.readthedocs.io")
9256 (synopsis "Zope security framework")
9257 (description "Zope.security provides a generic mechanism to implement
9258security policies on Python objects.")
9259 (license license:zpl2.1)))
9260
9261(define-public python-zope-security-bootstrap
9262 (package
9263 (inherit (python-zope-bootstrap-package python-zope-security))
9264 (propagated-inputs
9265 (list python-zope-i18nmessageid
9266 python-zope-interface
9267 python-zope-proxy-bootstrap
9268 python-zope-schema))))
9269
9270(define-public python-zope-component
9271 (package
9272 (name "python-zope-component")
9273 (version "7.0")
9274 (source
9275 (origin
9276 (method git-fetch)
9277 (uri (git-reference
9278 (url "https://github.com/zopefoundation/zope.component")
9279 (commit version)))
9280 (file-name (git-file-name name version))
9281 (sha256
9282 (base32 "1jygzhcg9rppsrd8cwvm0944naq1ldjf0vcpgsz0glwcdnr7cyfw"))))
9283 (build-system pyproject-build-system)
9284 (arguments
9285 (list
9286 #:phases
9287 #~(modify-phases %standard-phases
9288 (replace 'check
9289 (lambda* (#:key tests? #:allow-other-keys)
9290 (if tests?
9291 (invoke "zope-testrunner" "--test-path=src")
9292 (format #t "test suite not run~%")))))))
9293 (native-inputs
9294 (list python-persistent
9295 python-zope-configuration-bootstrap
9296 python-zope-i18nmessageid
9297 python-zope-location-bootstrap
9298 python-zope-proxy-bootstrap
9299 python-zope-security-bootstrap
9300 python-zope-testing
9301 python-zope-testrunner
9302 python-setuptools))
9303 (propagated-inputs
9304 (list python-zope-deferredimport python-zope-deprecation
9305 python-zope-event python-zope-hookable python-zope-interface))
9306 (home-page "https://zopecomponent.readthedocs.io")
9307 (synopsis "Zope Component Architecture")
9308 (description
9309 "Zope.component represents the core of the Zope Component Architecture.
9310Together with the zope.interface package, it provides facilities for defining,
9311registering and looking up components.")
9312 (license license:zpl2.1)))
9313
9314(define-public python-zope-component-bootstrap
9315 (python-zope-bootstrap-package python-zope-component))
9316
9317(define-public python-zope-deferredimport
9318 (package
9319 (name "python-zope-deferredimport")
9320 (version "6.0")
9321 (source
9322 (origin
9323 (method git-fetch)
9324 (uri (git-reference
9325 (url "https://github.com/zopefoundation/zope.deferredimport")
9326 (commit version)))
9327 (file-name (git-file-name name version))
9328 (sha256
9329 (base32 "08j728nn1la570nny1xz1xvxcm9hf2mcc3im1bzcxxrrxh4kw3zd"))))
9330 (build-system pyproject-build-system)
9331 (arguments
9332 (list
9333 #:phases
9334 #~(modify-phases %standard-phases
9335 (replace 'check
9336 (lambda* (#:key tests? #:allow-other-keys)
9337 (if tests?
9338 (invoke "zope-testrunner" "--test-path=src")
9339 (format #t "test suite not run~%")))))))
9340 (propagated-inputs (list python-zope-proxy))
9341 (native-inputs (list python-zope-testrunner python-setuptools))
9342 (home-page "https://zopedeferredimport.readthedocs.io")
9343 (synopsis "Defer imports until used by code")
9344 (description
9345 "Often, especially for package modules, you want to import names for
9346convenience, but not actually perform the imports until necessary. The
9347@code{zope.deferredimport} package provided facilities for defining names in
9348modules that will be imported from somewhere else when used. You can also cause
9349deprecation warnings to be issued when a variable is used.")
9350 (license license:zpl2.1)))
9351
9352(define-public python-ndg-httpsclient
9353 (package
9354 (name "python-ndg-httpsclient")
9355 (version "0.5.1")
9356 (source
9357 (origin
9358 (method git-fetch)
9359 (uri (git-reference
9360 (url "https://github.com/cedadev/ndg_httpsclient/")
9361 (commit version)))
9362 (file-name (git-file-name name version))
9363 (sha256
9364 (base32 "0lhsgs4am4xyjssng5p0vkfwqncczj1dpa0vss4lrhzq86mnn5rz"))))
9365 (build-system pyproject-build-system)
9366 (arguments
9367 (list
9368 #:tests? #f)) ;Tests appear to require networking.
9369 (native-inputs (list python-setuptools))
9370 (propagated-inputs (list python-pyasn1 python-pyopenssl))
9371 (synopsis "HTTPS support for Python's httplib and urllib2")
9372 (description
9373 "This is a HTTPS client implementation for httplib and urllib2 based on
9374PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation over
9375the default provided with Python and, importantly, enables full verification
9376of the SSL peer.")
9377 (home-page "https://github.com/cedadev/ndg_httpsclient/")
9378 (license license:bsd-3)))
9379
9380(define-public python-netaddr
9381 (package
9382 (name "python-netaddr")
9383 (version "1.3.0")
9384 (source
9385 (origin
9386 (method url-fetch)
9387 (uri (pypi-uri "netaddr" version))
9388 (sha256
9389 (base32 "12p4ysgawhgkka0sz1dkwgwc2za80dxdp9wvfxivfldmjnc3sg2w"))))
9390 (build-system pyproject-build-system)
9391 (native-inputs (list python-poetry-core
9392 python-pytest
9393 python-setuptools
9394 python-wheel))
9395 (home-page "https://netaddr.readthedocs.io")
9396 (synopsis "Pythonic manipulation of network addresses")
9397 (description
9398 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
9399and MAC network addresses.")
9400 (license license:bsd-3)))
9401
9402(define-public python-nh3
9403 (package
9404 (name "python-nh3")
9405 (version "0.2.20")
9406 (source
9407 (origin
9408 (method url-fetch)
9409 (uri (pypi-uri "nh3" version))
9410 (sha256
9411 (base32 "1mcf3y5294glji9lhzh57wymw4srbvzdg0kcakm0p2pqgwnw81cp"))))
9412 (build-system pyproject-build-system)
9413 (arguments
9414 (list
9415 #:imported-modules `(,@%cargo-build-system-modules
9416 ,@%pyproject-build-system-modules)
9417 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
9418 (guix build pyproject-build-system)
9419 (guix build utils))
9420 #:phases
9421 #~(modify-phases %standard-phases
9422 (add-after 'unpack 'prepare-cargo-build-system
9423 (lambda args
9424 (for-each
9425 (lambda (phase)
9426 (format #t "Running cargo phase: ~a~%" phase)
9427 (apply (assoc-ref cargo:%standard-phases phase)
9428 #:cargo-target #$(cargo-triplet)
9429 args))
9430 '(unpack-rust-crates
9431 configure
9432 check-for-pregenerated-files
9433 patch-cargo-checksums)))))))
9434 (native-inputs
9435 (append
9436 (list maturin python-pytest rust `(,rust "cargo"))
9437 (or (and=> (%current-target-system)
9438 (compose list make-rust-sysroot))
9439 '())))
9440 (inputs (cargo-inputs 'python-nh3))
9441 (home-page "https://nh3.readthedocs.io")
9442 (synopsis "Python bindings to Ammonia HTML sanitization library")
9443 (description "This package provides Python bindings to Ammonia HTML
9444sanitizer Rust crate.")
9445 (license license:expat)))
9446
9447(define-public python-noiseprotocol
9448 (package
9449 (name "python-noiseprotocol")
9450 (version "0.3.1")
9451 (source
9452 (origin
9453 (method git-fetch)
9454 (uri (git-reference
9455 (url "https://github.com/plizonczyk/noiseprotocol")
9456 (commit (string-append "v" version))))
9457 (file-name (git-file-name name version))
9458 (sha256
9459 (base32 "1mk0rqpjifdv3v1cjwkdnjbrfmzzjm9f3qqs1r8vii4j2wvhm6am"))))
9460 (build-system pyproject-build-system)
9461 (propagated-inputs (list python-cryptography))
9462 (native-inputs (list python-setuptools python-pytest))
9463 (home-page "https://github.com/plizonczyk/noiseprotocol")
9464 (synopsis "Implementation of Noise Protocol Framework")
9465 (description
9466 "This package provides an implementation of Noise Protocol Framework.")
9467 (license license:expat)))
9468
9469(define-public python-webrtcvad-wheels
9470 (package
9471 (name "python-webrtcvad-wheels")
9472 (version "2.0.14")
9473 (source
9474 (origin
9475 (method git-fetch)
9476 (uri (git-reference
9477 (url "https://github.com/daanzu/py-webrtcvad-wheels")
9478 (commit (string-append "v" version))))
9479 (file-name (git-file-name name version))
9480 (sha256
9481 (base32 "0sqgg8jmg2j14f4h96h0rs42kr460v65lhanps6lhdvj5zp81cbh"))))
9482 (build-system pyproject-build-system)
9483 (native-inputs (list python-psutil python-pytest python-setuptools))
9484 (home-page "https://github.com/daanzu/py-webrtcvad-wheels")
9485 (synopsis "Python interface to the WebRTC Voice Activity Detector (VAD)")
9486 (description
9487 "This package provides a Python interface to the Google
9488@url{https://webrtc.org/, WebRTC} @acronym{VAD, Voice Activity Detector}.")
9489 (license license:expat)))
9490
9491(define-public python-websocket-client
9492 (package
9493 (name "python-websocket-client")
9494 (version "1.8.0")
9495 (source
9496 (origin
9497 (method url-fetch)
9498 (uri (pypi-uri "websocket_client" version))
9499 (sha256
9500 (base32 "1nn3qi5g59j55wfy2z02j6lq2cm281fq0wi406b2yqys8jgxyf9j"))))
9501 (build-system pyproject-build-system)
9502 (arguments
9503 (list
9504 #:test-flags
9505 ;; This test requires networking.
9506 '(list "-k" "not testConnect")))
9507 (native-inputs
9508 (list python-pysocks
9509 python-pytest
9510 python-setuptools
9511 python-websockets
9512 python-wheel))
9513 (home-page "https://github.com/websocket-client/websocket-client")
9514 (synopsis "WebSocket client for Python")
9515 (description "The Websocket-client module provides the low level APIs for
9516WebSocket usage in Python programs.")
9517 (license license:lgpl2.1+)))
9518
9519(define-public python-websocket-client-0.59
9520 (package
9521 (inherit python-websocket-client)
9522 (version "0.59.0")
9523 (source
9524 (origin
9525 (method url-fetch)
9526 (uri (pypi-uri "websocket-client" version))
9527 (sha256
9528 (base32 "0p0cz2mdissq7iw1n7jrmsfir0jfmgs1dvnpnrx477ffx9hbsxnk"))))
9529 (native-inputs
9530 (modify-inputs native-inputs
9531 (append python-six)))))
9532
9533(define-public python-purl
9534 (package
9535 (name "python-purl")
9536 (version "1.6")
9537 (source
9538 (origin
9539 (method git-fetch)
9540 (uri (git-reference
9541 (url "https://github.com/codeinthehole/purl")
9542 (commit version)))
9543 (file-name (git-file-name name version))
9544 (sha256
9545 (base32 "01zngf0s0qfsrsk0skn57frbzyscwv8467pfjk6hxdfgdx2wkg95"))))
9546 (build-system pyproject-build-system)
9547 (arguments
9548 (list
9549 #:test-flags #~(list "--pyargs" "./tests")))
9550 (native-inputs (list python-pytest python-setuptools))
9551 (propagated-inputs (list python-six))
9552 (home-page "https://github.com/codeinthehole/purl")
9553 (synopsis "Python package for URL manipulation")
9554 (description "Purl is a Python package for handling URLs.")
9555 (license license:expat)))
9556
9557(define-public python-requests
9558 (package
9559 (name "python-requests")
9560 (version "2.34.2")
9561 (source (origin
9562 (method url-fetch)
9563 (uri (pypi-uri "requests" version))
9564 (sha256
9565 (base32
9566 "1vdrc3lq9x848760n7mdhn8whsfslk30pmnnk0v4caafmr69527j"))))
9567 (build-system pyproject-build-system)
9568 (arguments
9569 (list #:test-flags
9570 ;; These require internet access
9571 '(list "--ignore=tests/test_requests.py"
9572 "-k" (string-append "not test_use_proxy_from_environment"
9573 " and not requests.sessions.Session"
9574 " and not requests.models.PreparedRequest"
9575 " and not requests.api.request")
9576 "tests/")))
9577 (propagated-inputs
9578 (list python-certifi
9579 python-charset-normalizer
9580 python-idna
9581 python-urllib3))
9582 (native-inputs
9583 (list python-pytest
9584 python-pytest-mock
9585 python-setuptools))
9586 (home-page "https://requests.readthedocs.io/")
9587 (synopsis "Python HTTP library")
9588 (description
9589 "Requests is a Python HTTP client library. It aims to be easier to use
9590than Python’s urllib2 library.")
9591 (license license:asl2.0)))
9592
9593(define-public python-requests-kerberos
9594 (package
9595 (name "python-requests-kerberos")
9596 (version "0.14.0")
9597 ;; No tests in the PyPI tarball.
9598 (source
9599 (origin
9600 (method git-fetch)
9601 (uri (git-reference
9602 (url "https://github.com/requests/requests-kerberos")
9603 (commit (string-append "v" version))))
9604 (file-name (git-file-name name version))
9605 (sha256
9606 (base32 "0s30pcnlir3j2jmf7yh065f294cf3x0x5i3ldskn8mm0a3657mv3"))))
9607 (build-system pyproject-build-system)
9608 (propagated-inputs (list python-cryptography
9609 python-pyspnego
9610 python-requests))
9611 (native-inputs (list python-pytest python-pytest-mock python-setuptools
9612 python-wheel))
9613 (home-page "https://github.com/requests/requests-kerberos")
9614 (synopsis "Kerberos authentication handler for python-requests")
9615 (description "This package provides a Kerberos authentication handler for
9616python-requests.")
9617 (license license:isc)))
9618
9619(define-public python-requests-unixsocket2
9620 (package
9621 (name "python-requests-unixsocket2")
9622 (version "1.0.1")
9623 (source
9624 (origin
9625 (method git-fetch)
9626 (uri (git-reference
9627 (url "https://gitlab.com/thelabnyc/requests-unixsocket2")
9628 (commit (string-append "v" version))))
9629 (sha256
9630 (base32 "0wb8ckagal9d6lfyl3pf9m45xn1krq6vg8kzciwv12chq9wwh0ra"))))
9631 (build-system pyproject-build-system)
9632 (native-inputs
9633 (list nss-certs-for-test
9634 python-hatchling
9635 python-pytest
9636 python-waitress))
9637 (propagated-inputs
9638 (list python-requests
9639 python-urllib3))
9640 (home-page "https://gitlab.com/thelabnyc/requests-unixsocket2")
9641 (synopsis "Talk HTTP via a UNIX domain socket")
9642 (description
9643 "This Python package lets you use the @code{requests} library to talk
9644HTTP via a UNIX domain socket.")
9645 (license license:asl2.0)))
9646
9647(define-public python-requests-ntlm
9648 (package
9649 (name "python-requests-ntlm")
9650 (version "1.3.0")
9651 (source
9652 (origin
9653 (method git-fetch)
9654 (uri (git-reference
9655 (url "https://github.com/requests/requests-ntlm")
9656 (commit (string-append "v" version))))
9657 (file-name (git-file-name name version))
9658 (sha256
9659 (base32 "0snsk66zdihdlyfjz2zgpyfgdyjg814m3cc4g3my09hdnb5xvagv"))))
9660 (build-system pyproject-build-system)
9661 (arguments
9662 (list
9663 #:test-flags
9664 ;; XXX: Connection refused.
9665 #~(list "-k" (string-join
9666 (list "not test_ntlm_http_with_cbt"
9667 "test_ntlm_http_without_cbt"
9668 "test_ntlm_https_with_cbt"
9669 "test_ntlm_https_without_cbt")
9670 " and not "))
9671 #:phases
9672 #~(modify-phases %standard-phases
9673 (add-before 'check 'spawn-test-server
9674 (lambda _
9675 ;; Taken from .github/workflows/ci.yml.
9676 (spawn "python"
9677 (list "python" "-m" "tests.test_server")))))))
9678 (propagated-inputs
9679 (list python-cryptography python-pyspnego python-requests))
9680 (native-inputs (list python-flask python-pytest python-setuptools))
9681 (home-page "https://github.com/requests/requests-ntlm")
9682 (synopsis "NTLM authentication support for Requests")
9683 (description
9684 "This package allows for HTTP NTLM authentication using the requests
9685library.")
9686 (license license:isc)))
9687
9688(define-public python-requests-mock
9689 (package
9690 (name "python-requests-mock")
9691 (version "1.12.1")
9692 (source
9693 (origin
9694 (method url-fetch)
9695 (uri (pypi-uri "requests-mock" version))
9696 (sha256
9697 (base32 "008l6xysgs6ax56lairg1li5i4bb04i2z19w5bl5claj7crjxqg9"))))
9698 (build-system pyproject-build-system)
9699 (native-inputs
9700 (list python-purl
9701 python-pytest
9702 python-requests-futures
9703 python-setuptools
9704 python-setuptools-scm
9705 python-testtools))
9706 (propagated-inputs
9707 (list python-requests))
9708 (home-page "https://requests-mock.readthedocs.org/")
9709 (synopsis "Mock out responses from the requests package")
9710 (description
9711 "This module provides a building block to stub out the HTTP requests
9712portions of your testing code.")
9713 (license license:asl2.0)))
9714
9715(define-public python-requests-toolbelt
9716 (package
9717 (name "python-requests-toolbelt")
9718 (version "1.0.0")
9719 (source
9720 (origin
9721 (method url-fetch)
9722 (uri (pypi-uri "requests-toolbelt" version))
9723 (sha256
9724 (base32 "1ijvip427ki177ycrblcn1mfgsq7ixzpvqqfvidjn0a7s2is10bn"))))
9725 (build-system pyproject-build-system)
9726 (arguments
9727 (list
9728 #:test-flags
9729 ;; Requiring networking or fail due not valid certs: AttributeError:
9730 ;; 'MockHTTPResponse' object has no attribute 'close'
9731 #~(list "-k" (string-append "not test_dump_all"
9732 " and not test_dump_response"
9733 " and not test_prepared_request_override_base"
9734 " and not test_prepared_request_with_base"
9735 " and not test_request_override_base"
9736 " and not test_request_with_base"))))
9737 (native-inputs
9738 (list python-betamax
9739 python-mock
9740 python-pyopenssl
9741 python-pytest
9742 python-setuptools
9743 python-trustme
9744 python-wheel))
9745 (propagated-inputs
9746 (list python-requests))
9747 (synopsis "Extensions to python-requests")
9748 (description "This is a toolbelt of useful classes and functions to be used
9749with python-requests.")
9750 (home-page "https://github.com/requests/toolbelt/")
9751 (license license:asl2.0)))
9752
9753(define-public python-requests-ftp
9754 (package
9755 (name "python-requests-ftp")
9756 (version "0.3.1")
9757 (source
9758 (origin
9759 (method git-fetch)
9760 (uri (git-reference
9761 (url "https://github.com/Lukasa/requests-ftp")
9762 (commit (string-append "v" version))))
9763 (file-name (git-file-name name version))
9764 (sha256
9765 (base32 "1c7xbz2fxb12ldaw2pkfg5qd29g6slf4a2gavhqvz26cd1r82ny7"))))
9766 (build-system pyproject-build-system)
9767 (arguments
9768 ;; XXX: No connection adapters found.
9769 (list #:test-flags #~(list "--ignore=tests/test_ftp_proxy.py")))
9770 (native-inputs
9771 (list python-pyftpdlib python-pytest python-setuptools python-six))
9772 (propagated-inputs (list python-requests))
9773 (home-page "https://github.com/Lukasa/requests-ftp")
9774 (synopsis "FTP Transport Adapter for Requests")
9775 (description "Requests-FTP is an implementation of a simple FTP transport
9776adapter for use with the Requests library.")
9777 (license license:asl2.0)))
9778
9779(define-public python-mohawk
9780 (let ((commit "b7899166880e890f01cf2531b5686094ba08df8f")
9781 (revision "0"))
9782 (package
9783 (name "python-mohawk")
9784 (version (git-version "1.1.0" revision commit))
9785 (source
9786 (origin
9787 (method git-fetch)
9788 (uri (git-reference
9789 (url "https://github.com/kumar303/mohawk")
9790 (commit commit)))
9791 (file-name (git-file-name name version))
9792 (sha256
9793 (base32 "00y9fimcj851rk2770wqk61fac9pnxfnzca4fvsci57zw18i50m6"))
9794 (patches
9795 (search-patches "python-mohawk-pytest.patch"))))
9796 (build-system pyproject-build-system)
9797 (arguments
9798 (list #:test-flags #~(list "mohawk/tests.py")))
9799 (native-inputs (list python-pytest python-setuptools))
9800 (propagated-inputs (list python-six)) ;TODO: remove python-mohawk when
9801 ;python-six is removed?
9802 (home-page "https://github.com/kumar303/mohawk")
9803 (synopsis "Library for Hawk HTTP authorization")
9804 (description
9805 "Mohawk is an alternate Python implementation of the Hawk HTTP
9806authorization scheme.")
9807 (license license:bsd-3))))
9808
9809(define-public python-msal
9810 (package
9811 (name "python-msal")
9812 (version "1.34.0")
9813 (home-page
9814 "https://github.com/AzureAD/microsoft-authentication-library-for-python")
9815 (source
9816 (origin
9817 (method git-fetch)
9818 (uri (git-reference
9819 (url home-page)
9820 (commit version)))
9821 (file-name (git-file-name name version))
9822 (sha256
9823 (base32 "1xcyiv742ihnzypjw7syamnhqffdy6wsvvv0f5jcl3pap0apbk0z"))
9824 (patches (search-patches "python-msal-requests.patch"))))
9825 (build-system pyproject-build-system)
9826 (arguments
9827 (list
9828 #:test-flags
9829 #~(list
9830 "--ignore=tests/test_benchmark.py"
9831 ;; XXX: Ignoring cryptography version scheme tests.
9832 "-k"
9833 "not test_ceiling_should_be_latest_cryptography_version_plus_three"
9834 ;; XXX: These tests try to access the network.
9835 "--ignore=tests/test_application.py"
9836 "--ignore=tests/test_ccs.py"
9837 ;; XXX: These tests assume they are run on Windows.
9838 "--ignore=tests/test_mi.py")
9839 #:phases
9840 #~(modify-phases %standard-phases
9841 (add-after 'unpack 'set-cryptography-version
9842 (lambda _
9843 (substitute* "tests/test_cryptography.py"
9844 (("^latest_cryptography_version = @version@")
9845 (format #f "latest_cryptography_version = ~s"
9846 #$(package-version
9847 (this-package-input "python-cryptography")))))))
9848 (add-before 'check 'configure-tests
9849 (lambda* (#:key tests? #:allow-other-keys)
9850 (when tests?
9851 (setenv "TRAVIS_TAG" "1")))))))
9852 (native-inputs
9853 (list nss-certs-for-test python-mock python-pytest python-setuptools))
9854 (propagated-inputs (list python-cryptography python-pyjwt python-requests))
9855 (synopsis "Microsoft Authentication Library (MSAL) for Python")
9856 (description
9857 "The Microsoft Authentication Library for Python enables applications to
9858integrate with the Microsoft identity platform. It allows you to sign in
9859users or apps with Microsoft identities (Azure AD, Microsoft Accounts and
9860Azure AD B2C accounts) and obtain tokens to call Microsoft APIs such as
9861Microsoft Graph or your own APIs registered with the Microsoft identity
9862platform. It is built using industry standard OAuth2 and OpenID Connect
9863protocols.")
9864 (license license:expat)))
9865
9866(define-public python-oauthlib
9867 (package
9868 (name "python-oauthlib")
9869 (version "3.3.1")
9870 (source
9871 (origin
9872 (method git-fetch)
9873 (uri (git-reference
9874 (url "https://github.com/oauthlib/oauthlib")
9875 (commit (string-append "v" version))))
9876 (file-name (git-file-name name version))
9877 (sha256
9878 (base32 "0aa38lpa6s1k56v7w7kw2w4l159kaz4gn03m698a8hfdjkx92fb5"))))
9879 (build-system pyproject-build-system)
9880 (native-inputs (list python-pytest python-mock python-setuptools))
9881 (propagated-inputs (list python-cryptography python-pyjwt python-blinker))
9882 (home-page "https://github.com/oauthlib/oauthlib")
9883 (synopsis "OAuth implementation for Python")
9884 (description
9885 "Oauthlib is a generic, spec-compliant, thorough implementation of the
9886OAuth request-signing logic.")
9887 (license license:bsd-3)))
9888
9889(define-public python-urllib3
9890 (package
9891 (name "python-urllib3")
9892 (version "2.7.0")
9893 (source
9894 (origin
9895 (method url-fetch)
9896 (uri (pypi-uri "urllib3" version))
9897 (sha256
9898 (base32
9899 "0k2za0kdl4y8mdhay0wbnf6522n4ybr61gk7gik19srwnv1hw7i3"))))
9900 (build-system pyproject-build-system)
9901 (arguments `(#:tests? #f))
9902 (native-inputs
9903 (list python-hatch-vcs
9904 python-hatchling
9905 python-setuptools-scm))
9906 (propagated-inputs
9907 (append
9908 ;; These 5 inputs are used to build urrlib3[secure]
9909 (list python-certifi
9910 python-idna
9911 python-pysocks)
9912 (if (member (%current-system)
9913 (package-transitive-supported-systems python-cryptography))
9914 (list python-cryptography)
9915 '())
9916 (if (member (%current-system)
9917 (package-transitive-supported-systems python-pyopenssl))
9918 (list python-pyopenssl)
9919 '())))
9920 (home-page "https://urllib3.readthedocs.io/")
9921 (synopsis "HTTP library with thread-safe connection pooling")
9922 (description
9923 "Urllib3 supports features left out of urllib and urllib2 libraries. It
9924can reuse the same socket connection for multiple requests, it can POST files,
9925supports url redirection and retries, and also gzip and deflate decoding.")
9926 (license license:expat)))
9927
9928(define-public python-urllib3-1.26
9929 (package
9930 (inherit python-urllib3)
9931 (version "1.26.17")
9932 (source
9933 (origin
9934 (method url-fetch)
9935 (uri (pypi-uri "urllib3" version))
9936 (sha256
9937 (base32
9938 "08fzhaf77kbjj5abpl9xag6fpfxkdp1k5s7sqd3ayacdq91a5mi4"))))
9939 (native-inputs
9940 (list python-setuptools
9941 python-wheel))))
9942
9943(define-public python-wsgiproxy2
9944 (package
9945 (name "python-wsgiproxy2")
9946 (version "0.5.1")
9947 (source
9948 (origin
9949 (method git-fetch)
9950 (uri (git-reference
9951 (url "https://github.com/gawel/WSGIProxy2/")
9952 (commit version)))
9953 (file-name (git-file-name name version))
9954 (sha256
9955 (base32 "0aw9ibla2cqzlbm3vzyk1yk3d8pccpbpdkqx99q30hq1fz1izsm2"))))
9956 (build-system pyproject-build-system)
9957 (arguments (list #:test-backend #~'unittest))
9958 (native-inputs (list python-webtest python-setuptools))
9959 (propagated-inputs (list python-requests python-six python-urllib3
9960 python-webob))
9961 (home-page "https://github.com/gawel/WSGIProxy2/")
9962 (synopsis "WSGI Proxy with various http client backends")
9963 (description
9964 "WSGI turns HTTP requests into WSGI function calls. WSGIProxy turns WSGI
9965function calls into HTTP requests. It also includes code to sign requests and
9966pass private data, and to spawn subprocesses to handle requests.")
9967 (license license:expat)))
9968
9969(define-public python-pastedeploy
9970 (package
9971 (name "python-pastedeploy")
9972 (version "3.1.0")
9973 (source
9974 (origin
9975 (method url-fetch)
9976 (uri (pypi-uri "PasteDeploy" version))
9977 (sha256
9978 (base32 "15as15mgz9xn33abwrp0x0mbj537ib3q47z8ky5475c05wasznwx"))))
9979 (build-system pyproject-build-system)
9980 (native-inputs (list python-pytest python-setuptools))
9981 (home-page "https://pylonsproject.org/")
9982 (synopsis "Load, configure, and compose WSGI applications and servers")
9983 (description
9984 "This tool provides code to load WSGI applications and servers from URIs;
9985these URIs can refer to Python Eggs for INI-style configuration files. Paste
9986Script provides commands to serve applications based on this configuration
9987file.")
9988 (license license:expat)))
9989
9990(define-public python-webtest
9991 (package
9992 (name "python-webtest")
9993 (version "3.0.6")
9994 (source
9995 (origin
9996 (method url-fetch)
9997 (uri (pypi-uri "webtest" version))
9998 (sha256
9999 (base32 "0jwl8i9xvm5xim1h2jrwfbqac1g3fpiazfdwfp2md3s4899gsmj2"))))
10000 (build-system pyproject-build-system)
10001 (arguments
10002 ;; Tests require python-pyquery, which creates a circular dependency.
10003 `(#:tests? #f))
10004 (native-inputs
10005 (list python-setuptools))
10006 (propagated-inputs
10007 (list python-beautifulsoup4
10008 python-waitress
10009 python-webob))
10010 (home-page "https://docs.pylonsproject.org/projects/webtest/")
10011 (synopsis "Helper to test WSGI applications")
10012 (description
10013 "Webtest allows you to test your Python web applications without
10014starting an HTTP server. It supports anything that supports the minimum of
10015WSGI.")
10016 (license license:expat)))
10017
10018(define-public python-flask
10019 (package
10020 (name "python-flask")
10021 (version "3.1.3")
10022 (source
10023 (origin
10024 (method git-fetch)
10025 (uri (git-reference
10026 (url "https://github.com/pallets/flask")
10027 (commit version)))
10028 (file-name (git-file-name name version))
10029 (sha256
10030 (base32 "006s5rm4syg48ymmwlnrkx8f8j758waksvhdsfiqx51zv52c0p8l"))))
10031 (build-system pyproject-build-system)
10032 (arguments
10033 (list
10034 #:test-flags
10035 ;; assert 404 == 400
10036 ;; This test is removed on master branch.
10037 #~(list (string-append "--deselect=tests/test_reqctx.py"
10038 "::test_bad_environ_raises_bad_request"))))
10039 (native-inputs
10040 (list python-flit-core
10041 python-pytest))
10042 (propagated-inputs
10043 (list python-blinker
10044 python-click
10045 python-itsdangerous
10046 python-jinja2
10047 python-markupsafe
10048 python-werkzeug
10049 ;; [optional]
10050 python-asgiref
10051 python-dotenv))
10052 (home-page "https://palletsprojects.com/p/flask/")
10053 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
10054 (description "Flask is a micro web framework based on the Werkzeug toolkit
10055and Jinja2 template engine. It is called a micro framework because it does not
10056presume or force a developer to use a particular tool or library.")
10057 (license license:bsd-3)))
10058
10059(define-public python-flask-compress
10060 (package
10061 (name "python-flask-compress")
10062 (version "1.24")
10063 (source
10064 (origin
10065 (method git-fetch)
10066 (uri (git-reference
10067 (url "https://github.com/colour-science/flask-compress")
10068 (commit (string-append "v" version))))
10069 (file-name (git-file-name name version))
10070 (sha256
10071 (base32 "0mid5c34r75vax1r7l2l5sjjhs6bl8rbsdmhc7kz39snq6xw3cr5"))))
10072 (build-system pyproject-build-system)
10073 (native-inputs
10074 (list python-flask-caching
10075 python-pytest
10076 python-setuptools
10077 python-setuptools-scm))
10078 (propagated-inputs
10079 (list python-backports-zstd
10080 python-brotli
10081 python-flask))
10082 (home-page "https://github.com/colour-science/flask-compress")
10083 (synopsis "Compress responses in a Flask app")
10084 (description
10085 "This package lets you compress Flask application responses and static
10086files with gzip, deflate or brotli. Flask-Compress both adds the various
10087headers required for a compressed response and compresses the response data.")
10088 (license license:expat)))
10089
10090(define-public python-flask-seasurf
10091 (package
10092 (name "python-flask-seasurf")
10093 (version "2.0.0")
10094 (source (origin
10095 (method url-fetch)
10096 (uri (pypi-uri "Flask-SeaSurf" version))
10097 (sha256
10098 (base32
10099 "0g5dsm2ikv8q4qcrb2446pbs972l5wkxyfmxsriqdsl02nz06h4f"))))
10100 (build-system pyproject-build-system)
10101 (arguments
10102 (list #:tests? #false)) ;there are none
10103 (propagated-inputs (list python-flask))
10104 (native-inputs (list python-setuptools python-wheel))
10105 (home-page "https://github.com/maxcountryman/flask-seasurf/")
10106 (synopsis "CSRF extension for Flask")
10107 (description "SeaSurf is a Flask extension for preventing cross-site
10108request forgery (CSRF). CSRF attacks are problematic because the mechanism
10109they use is relatively easy to exploit. This extension attempts to aid you in
10110securing your application from such attacks. This extension is based on the
10111Django middleware.")
10112 (license license:bsd-3)))
10113
10114(define-public python-flask-wtf
10115 (package
10116 (name "python-flask-wtf")
10117 (version "1.2.2")
10118 (source
10119 (origin
10120 (method url-fetch)
10121 (uri (pypi-uri "Flask-WTF" version))
10122 (sha256
10123 (base32
10124 "0sv6hjva1fdizb7sr46230pplx8qz8rnb4bxrfy71xbc8cgfxlkr"))))
10125 (build-system pyproject-build-system)
10126 (propagated-inputs
10127 (list python-flask python-flask python-itsdangerous python-wtforms))
10128 (native-inputs
10129 (list python-hatchling python-pytest))
10130 (home-page "https://github.com/lepture/flask-wtf")
10131 (synopsis "Simple integration of Flask and WTForms")
10132 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
10133upload, and reCAPTCHA.")
10134 (license license:bsd-3)))
10135
10136(define-public python-flask-multistatic
10137 (package
10138 (name "python-flask-multistatic")
10139 (version "1.0")
10140 (source
10141 (origin
10142 (method url-fetch)
10143 (uri (pypi-uri "flask-multistatic" version))
10144 (sha256
10145 (base32
10146 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
10147 (build-system pyproject-build-system)
10148 (arguments (list #:tests? #f)) ; No tests upstream.
10149 (native-inputs (list python-setuptools))
10150 (propagated-inputs (list python-flask))
10151 (home-page "https://pagure.io/flask-multistatic")
10152 (synopsis "Flask plugin to allow overriding static files")
10153 (description "@code{flask-multistatic} is a flask plugin that adds support
10154for overriding static files.")
10155 (license license:gpl3+)))
10156
10157(define-public python-responses
10158 (package
10159 (name "python-responses")
10160 (version "0.25.3")
10161 (source (origin
10162 (method url-fetch)
10163 (uri (pypi-uri "responses" version))
10164 (sha256
10165 (base32
10166 "1fld6lsa143md4lxccwxq9iyqm9d8a05i9sp7lqjibnrmd3r4yv1"))))
10167 (build-system pyproject-build-system)
10168 (native-inputs
10169 (list python-pytest
10170 python-pytest-asyncio
10171 python-pytest-httpserver
10172 python-setuptools
10173 python-tomli
10174 python-tomli-w
10175 python-wheel))
10176 (propagated-inputs
10177 (list python-requests
10178 python-pyyaml
10179 python-urllib3))
10180 (home-page "https://github.com/getsentry/responses")
10181 (synopsis "Utility for mocking out the `requests` Python library")
10182 (description "A utility library for mocking out the `requests` Python
10183library.")
10184 (license license:asl2.0)))
10185
10186(define-public python-grequests
10187 (let ((commit "60f70e99e942a2df378b4e4f6202dcf862754c2d")
10188 (revision "0"))
10189 (package
10190 (name "python-grequests")
10191 (version (git-version "0.7.0" revision commit))
10192 (source
10193 (origin
10194 (method git-fetch)
10195 (uri (git-reference
10196 (url "https://github.com/kennethreitz/grequests")
10197 (commit commit)))
10198 (file-name (git-file-name name version))
10199 (sha256
10200 (base32 "0132yv1rr4pmrmwasrnasqbnd80pi6rgy52608731p7lidkmxz9a"))))
10201 (build-system pyproject-build-system)
10202 (arguments
10203 (list
10204 ;; XXX: Most failing tests seem to be caused by network access,
10205 ;; but there is no easy/flag way to disable tests selectively.
10206 #:tests? #f
10207 #:test-backend #~'unittest
10208 #:test-flags #~(list "tests.py")))
10209 (propagated-inputs (list python-gevent python-requests))
10210 (native-inputs (list python-setuptools))
10211 (home-page "https://github.com/kennethreitz/grequests")
10212 (synopsis "Python library for asynchronous HTTP requests")
10213 (description
10214 "GRequests is a Python library that allows you to use @code{Requests}
10215with @code{Gevent} to make asynchronous HTTP Requests easily.")
10216 (license license:bsd-2))))
10217
10218(define-public python-gwebsockets
10219 (package
10220 (name "python-gwebsockets")
10221 (version "0.7")
10222 (source
10223 (origin
10224 (method git-fetch)
10225 (uri (git-reference
10226 (url "https://github.com/sugarlabs/gwebsockets")
10227 (commit (string-append "v" version))))
10228 (file-name (git-file-name name version))
10229 (sha256
10230 (base32 "0w422yz0qdix5xb6aqrrci1s1hy4whncspwb03m9ankqww0s1yv2"))))
10231 (build-system pyproject-build-system)
10232 (arguments (list #:tests? #f)) ; No tests upstream.
10233 (native-inputs (list python-setuptools))
10234 (propagated-inputs (list python-pygobject))
10235 (home-page "https://github.com/sugarlabs/gwebsockets")
10236 (synopsis "GLib based websockets server")
10237 (description
10238 "This package provides a websocket server written in Python. It uses GIO
10239for network communication and hence it easily integrates with the GLib
10240mainloop.")
10241 (license license:asl2.0)))
10242
10243(define-public python-geventhttpclient
10244 (package
10245 (name "python-geventhttpclient")
10246 (version "2.3.9")
10247 (source (origin
10248 (method git-fetch)
10249 (uri (git-reference
10250 (url "https://github.com/geventhttpclient/geventhttpclient")
10251 (commit version)
10252 (recursive? #true)))
10253 (file-name (git-file-name name version))
10254 (sha256
10255 (base32
10256 "1diq6n9sr92rsqbpxlbhbn1d22hrlzp6swykz9bfzh7sxpywa6j8"))))
10257 (build-system pyproject-build-system)
10258 (arguments
10259 (list
10260 #:test-flags
10261 ;; Disable network tests.
10262 '(list "-k"
10263 (string-append "not test_client_simple"
10264 " and not test_client_ssl"
10265 " and not test_client_with_default_headers"
10266 " and not test_client_without_leading_slash"
10267 " and not test_download"
10268 " and not test_fail_invalid_ca_certificate"
10269 " and not test_httpbin_multipart"
10270 " and not test_multi_queries_greenlet_safe"
10271 " and not test_no_form_encode_header"
10272 " and not test_no_form_encoded_header"
10273 " and not test_request_with_headers"
10274 " and not test_response_context_manager"
10275 " and not test_urllib_request"))))
10276 (native-inputs (list nss-certs-for-test
10277 python-dpkt python-pytest python-requests
10278 python-setuptools python-wheel))
10279 (propagated-inputs (list python-brotli python-certifi python-gevent
10280 python-urllib3))
10281 (home-page "https://github.com/geventhttpclient/geventhttpclient")
10282 (synopsis "HTTP client library for gevent")
10283 (description "@code{python-geventhttpclient} is a high performance,
10284concurrent HTTP client library for python using @code{gevent}.")
10285 (license license:expat)))
10286
10287(define-public python-gevent-websocket
10288 (package
10289 (name "python-gevent-websocket")
10290 (version "0.10.1")
10291 (source
10292 (origin
10293 (method url-fetch)
10294 (uri (pypi-uri "gevent-websocket" version))
10295 (sha256
10296 (base32 "1c2zv2rahp1gil3cj66hfsqgy0n35hz9fny3ywhr2319d0lz7bky"))))
10297 (build-system pyproject-build-system)
10298 (arguments
10299 (list #:tests? #f)) ; no tests in PyPI or git
10300 (native-inputs
10301 (list python-setuptools
10302 python-wheel))
10303 (propagated-inputs
10304 (list python-gevent))
10305 (home-page "https://gitlab.com/noppo/gevent-websocket")
10306 (synopsis "Websocket handler for the gevent pywsgi server")
10307 (description
10308 "Websocket handler for the gevent pywsgi server, a Python network
10309library.
10310
10311Features include:
10312@itemize
10313@item integration on both socket level or using an abstract interface
10314@item RPC and PubSub framework using @acronym{WebSocket Application Messaging
10315Protocol, WAMP}
10316@item easily extendible using a simple WebSocket protocol plugin API
10317@end itemize")
10318 (license license:asl2.0)))
10319
10320(define-public python-requests-oauthlib
10321 (package
10322 (name "python-requests-oauthlib")
10323 (version "2.0.0")
10324 (source
10325 (origin
10326 (method git-fetch)
10327 (uri (git-reference (url
10328 "https://github.com/requests/requests-oauthlib")
10329 (commit (string-append "v" version))))
10330 (file-name (git-file-name name version))
10331 (sha256 (base32 "0i0vnanxqilnf2rgng7n96rl8fzq0dbcl3rpl7zkxj50kv66nqwl"))))
10332 (build-system pyproject-build-system)
10333 (arguments
10334 (list
10335 #:test-flags
10336 #~(list
10337 "--ignore=tests/test_core.py" ; requires network access.
10338 "--ignore=tests/examples/test_native_spa_pkce_auth0.py"
10339 "-k" "not test_fetch_access_token"))) ; flaky tests.
10340 (native-inputs
10341 (list python-requests-mock python-pytest python-setuptools))
10342 (propagated-inputs
10343 (list python-oauthlib python-requests))
10344 (home-page "https://github.com/requests/requests-oauthlib")
10345 (synopsis "OAuthlib authentication support for Requests")
10346 (description
10347 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
10348provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
10349 (license license:isc)))
10350
10351(define-public python-s3fs
10352 (package
10353 (name "python-s3fs")
10354 (version "2026.1.0")
10355 (source
10356 (origin
10357 (method url-fetch)
10358 (uri (pypi-uri "s3fs" version))
10359 (sha256
10360 (base32 "17fhx4qnpcwhrfckn27wdjvlxink1kcpaiganxij4fjmp7gm58xp"))))
10361 (build-system pyproject-build-system)
10362 ;; TODO: Many tests fail with "No such file or directory" raised by the
10363 ;; HTTP client.
10364 (arguments (list #:tests? #false))
10365 (native-inputs
10366 (list python-setuptools))
10367 (propagated-inputs
10368 (list python-aiobotocore
10369 python-aiohttp
10370 python-fsspec))
10371 (home-page "https://github.com/fsspec/s3fs/")
10372 (synopsis "Convenient filesystem interface over S3")
10373 (description "This package provides a convenient filesystem interface over
10374S3.")
10375 (license license:bsd-3)))
10376
10377(define-public python-s3transfer
10378 (package
10379 (name "python-s3transfer")
10380 (version "0.16.0")
10381 (source
10382 (origin
10383 (method url-fetch)
10384 (uri (pypi-uri "s3transfer" version))
10385 (sha256
10386 (base32 "087rmdwsn9drkh5rwwbfym5p8qvirc8gllnd54i7j9c04q9hz6cf"))))
10387 (build-system pyproject-build-system)
10388 (arguments
10389 (list
10390 ;; tests: 630 passed, 51 skipped
10391 #:test-flags
10392 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
10393 ;; Tests require networking.
10394 "--ignore" "tests/integration")))
10395 (native-inputs
10396 (list python-pytest
10397 python-pytest-xdist
10398 python-setuptools))
10399 (propagated-inputs
10400 (list python-botocore))
10401 (home-page "https://github.com/boto/s3transfer")
10402 (synopsis "Amazon S3 Transfer Manager")
10403 (description
10404 "S3transfer is a Python library for managing Amazon S3 transfers.")
10405 (license license:asl2.0)))
10406
10407(define-public python-flask-restful
10408 (package
10409 (name "python-flask-restful")
10410 (version "0.3.10")
10411 (source
10412 (origin
10413 (method url-fetch)
10414 (uri (pypi-uri "Flask-RESTful" version))
10415 (sha256
10416 (base32
10417 "0dzckjjz3aw8nmisr5g9mnv02s2nqlhblykr9ydqzpr703pz4jpy"))))
10418 (build-system pyproject-build-system)
10419 (arguments
10420 ;; See <https://github.com/flask-restful/flask-restful/issues/980>.
10421 (list #:tests? #f))
10422 (propagated-inputs
10423 (list python-aniso8601 python-flask python-pytz))
10424 (native-inputs
10425 (list python-blinker
10426 python-mock
10427 python-pytest
10428 python-setuptools
10429 python-six))
10430 (home-page "https://github.com/flask-restful/flask-restful/")
10431 (synopsis "Flask module for creating REST APIs")
10432 (description
10433 "This package contains a Flask module for creating REST APIs.")
10434 (license license:bsd-3)))
10435
10436(define-public python-flask-sqlalchemy
10437 (package
10438 (name "python-flask-sqlalchemy")
10439 ;; Released version fails tests in Python 3.12.
10440 (properties '((commit . "168cb4b7b50fe5176307a10d873781bfafc6eeda")
10441 (revision . "0")))
10442 (version (git-version "3.1.1"
10443 (assoc-ref properties 'revision)
10444 (assoc-ref properties 'commit)))
10445 (source
10446 (origin
10447 (method git-fetch)
10448 (uri (git-reference
10449 (url "https://github.com/pallets-eco/flask-sqlalchemy")
10450 (commit (assoc-ref properties 'commit))))
10451 (file-name (git-file-name name version))
10452 (sha256
10453 (base32
10454 "0xw8v1540m21x9crpgb0i3rxyhh1d24ldg354vndw9cif74ls5p6"))))
10455 (build-system pyproject-build-system)
10456 (arguments
10457 (list
10458 #:test-flags
10459 #~(list "-k" (string-append "not test_explicit_table[db2]"
10460 " and not test_explicit_table[db4]")
10461 "-W" "ignore::DeprecationWarning")))
10462 (native-inputs
10463 (list python-flit-core
10464 python-pytest))
10465 (propagated-inputs
10466 (list python-flask
10467 python-sqlalchemy-2))
10468 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
10469 (synopsis "Module adding SQLAlchemy support to your Flask application")
10470 (description
10471 "This package adds SQLAlchemy support to your Flask application.")
10472 (license license:bsd-3)))
10473
10474(define-public python-flask-restful-swagger
10475 (package
10476 (name "python-flask-restful-swagger")
10477 (version "0.20.1")
10478 ;; XXX: Unbundle minified javascript.
10479 (source
10480 (origin
10481 (method git-fetch)
10482 (uri (git-reference
10483 (url "https://github.com/rantav/flask-restful-swagger")
10484 (commit version)))
10485 (file-name (git-file-name name version))
10486 (sha256
10487 (base32 "1ppdwn25ijf8b3zchxkvwj4ipc68v3p522i8mm51jm0w6mg5bvsh"))))
10488 (build-system pyproject-build-system)
10489 (arguments (list #:tests? #f)) ; No tests.
10490 (native-inputs (list python-setuptools))
10491 (propagated-inputs (list python-flask-restful python-six))
10492 (home-page "https://github.com/rantav/flask-restful-swagger")
10493 (synopsis "Extract Swagger specs from Flask-Restful projects")
10494 (description "This package lets you extract Swagger API documentation
10495specs from your Flask-Restful projects.")
10496 (license license:expat)))
10497
10498(define-public python-htmlmin
10499 (package
10500 (name "python-htmlmin")
10501 (version "0.1.12")
10502 (source
10503 (origin
10504 (method url-fetch)
10505 (uri (pypi-uri "htmlmin" version))
10506 (sha256
10507 (base32
10508 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
10509 (build-system pyproject-build-system)
10510 (arguments
10511 (list #:tests? #f)) ; no tests
10512 (native-inputs (list python-setuptools))
10513 (home-page "https://htmlmin.readthedocs.org/en/latest/")
10514 (synopsis "HTML minifier")
10515 (description "@code{htmlmin} is an HTML minifier that just works.
10516It comes with safe defaults and easily configurable options.")
10517 (license license:bsd-3)))
10518
10519;; XXX: Forked renamed and updated version.
10520(define-public python-htmlmin2
10521 (package/inherit python-htmlmin
10522 (name "python-htmlmin2")
10523 (version "0.1.13")
10524 (source
10525 (origin
10526 (method git-fetch)
10527 (uri (git-reference
10528 (url "https://github.com/wilhelmer/htmlmin")
10529 (commit (string-append "v" version))))
10530 (file-name (git-file-name name version))
10531 (sha256
10532 (base32 "1y7mcx8d451hwa1wrg2lffg7ccdy3w5m7xwb5xqp8h2852pypfh2"))))
10533 (build-system pyproject-build-system)
10534 (arguments (list #:test-backend #~'unittest))
10535 (native-inputs (list python-setuptools))
10536 (home-page "https://github.com/wilhelmer/htmlmin")
10537 (description
10538 "@code{htmlmin2} is an HTML minifier that just works. It comes with safe
10539defaults and easily configurable options. This variant is an updated fork of
10540the original @code{python-htmlmin}.")
10541 (license license:bsd-3)))
10542
10543(define-public python-flask-htmlmin
10544 (package
10545 (name "python-flask-htmlmin")
10546 (version "3.0.0")
10547 (source
10548 (origin
10549 (method git-fetch)
10550 (uri (git-reference
10551 (url "https://github.com/hamidfzm/Flask-HTMLmin")
10552 (commit (string-append "v" version))))
10553 (file-name (git-file-name name version))
10554 (sha256
10555 (base32 "0ybqssnqwa9zgv61azp5r1grgnq28ypfhr80p9rp61x2z0y0zl32"))))
10556 (build-system pyproject-build-system)
10557 (native-inputs (list python-pytest python-setuptools))
10558 (propagated-inputs (list python-cssmin python-flask python-htmlmin2))
10559 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
10560 (synopsis "HTML response minifier for Flask")
10561 (description
10562 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
10563 (license license:bsd-3)))
10564
10565(define-public python-jsmin
10566 (package
10567 (name "python-jsmin")
10568 (version "3.0.1")
10569 (source
10570 (origin
10571 (method url-fetch)
10572 (uri (pypi-uri "jsmin" version))
10573 (sha256
10574 (base32
10575 "1z1brjsvni0260bypldkl8a05sgp0qk18x560zl44igr3q99m5f0"))))
10576 (build-system pyproject-build-system)
10577 (arguments (list #:test-backend #~'unittest))
10578 (native-inputs
10579 (list python-setuptools))
10580 (home-page "https://github.com/tikitu/jsmin/")
10581 (synopsis "Python JavaScript minifier")
10582 (description
10583 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
10584on the command line.")
10585 (license license:expat)))
10586
10587(define-public python-flask-login
10588 (let ((commit "c8bba84b9ba6768e878317fc46c54bd13fa1ac07")
10589 (revision "0"))
10590 (package
10591 (name "python-flask-login")
10592 (version (git-version "0.6.3" revision commit))
10593 (source
10594 (origin
10595 (method git-fetch)
10596 (uri (git-reference
10597 (url "https://github.com/maxcountryman/flask-login")
10598 (commit commit)))
10599 (file-name (git-file-name name version))
10600 (sha256
10601 (base32 "0q0ga1zwm06kvpnsf50ckmsc77959i1spx7z2y3jkbwaa4klsyli"))))
10602 (build-system pyproject-build-system)
10603 (propagated-inputs
10604 (list python-flask))
10605 (native-inputs
10606 ;; For tests.
10607 (list python-blinker
10608 python-flit-core
10609 python-mock
10610 python-pytest
10611 python-semantic-version
10612 python-werkzeug))
10613 (home-page "https://github.com/maxcountryman/flask-login")
10614 (synopsis "User session management for Flask")
10615 (description
10616 "@code{Flask-Login} provides user session management for Flask. It
10617handles the common tasks of logging in, logging out, and remembering your
10618users' sessions over extended periods of time.")
10619 (license license:expat))))
10620
10621(define-public python-oauth2client
10622 (package
10623 (name "python-oauth2client")
10624 (version "4.1.3")
10625 (source
10626 (origin
10627 (method git-fetch)
10628 (uri (git-reference
10629 (url "https://github.com/google/oauth2client/")
10630 (commit (string-append "v" version))))
10631 (file-name (git-file-name name version))
10632 (sha256
10633 (base32 "0xm19dv5kmi82zzrx3d4mp326irr3x37q818hlspz514dzjq2ad1"))))
10634 (build-system pyproject-build-system)
10635 (arguments
10636 (list #:tests? #f))
10637 (native-inputs
10638 (list python-setuptools))
10639 (propagated-inputs
10640 (list python-httplib2
10641 python-pyasn1
10642 python-pyasn1-modules
10643 python-pyparsing
10644 python-rsa
10645 python-six))
10646 (home-page "https://github.com/google/oauth2client/")
10647 (synopsis "OAuth 2.0 client library")
10648 (description "@code{python-oauth2client} provides an OAuth 2.0 client
10649library for Python")
10650 (license license:asl2.0)))
10651
10652(define-public python-flask-oidc
10653 ;; XXX: Project is unmaintained since 2022, see:
10654 ;; <https://github.com/puiterwijk/flask-oidc/issues/146>.
10655 (package
10656 (name "python-flask-oidc")
10657 (version "2.4.0")
10658 (source
10659 (origin
10660 (method url-fetch)
10661 (uri (pypi-uri "flask_oidc" version))
10662 (sha256
10663 (base32
10664 "0lr15s5y61qkgic54pln1j82l2c32wgscdj8hymwr44gxby7h8z7"))))
10665 (build-system pyproject-build-system)
10666 (arguments
10667 (list
10668 #:test-flags
10669 #~(list (string-append "--deselect=tests/test_flask_oidc.py"
10670 "::test_accept_token_no_token"))))
10671 (propagated-inputs
10672 (list python-authlib
10673 python-blinker
10674 python-flask
10675 python-requests
10676 python-responses))
10677 (native-inputs
10678 (list python-pytest python-poetry-core))
10679 (home-page "https://github.com/puiterwijk/flask-oidc")
10680 (synopsis "OpenID Connect extension for Flask")
10681 (description "@code{python-flask-oidc} provides an OpenID Connect extension
10682for Flask.")
10683 (license license:bsd-2)))
10684
10685(define-public python-webassets
10686 (package
10687 (name "python-webassets")
10688 (version "3.0.0")
10689 (source
10690 (origin
10691 (method git-fetch)
10692 (uri (git-reference
10693 (url "https://github.com/miracle2k/webassets")
10694 (commit version)))
10695 (file-name (git-file-name name version))
10696 (sha256
10697 (base32 "11hxvdqw86q6r665iryjzwx21ys8jh2c63mw016ldr6j49l0zyyh"))))
10698 (build-system pyproject-build-system)
10699 (propagated-inputs (list python-pyyaml python-zope-dottedname))
10700 (native-inputs (list python-hatchling python-pytest))
10701 (home-page "https://github.com/miracle2k/webassets")
10702 (synopsis "Media asset management")
10703 (description
10704 "This package provides utilities to merge, minify and compress Javascript
10705and CSS files,supporting a variety of different filters, including YUI, jsmin,
10706jspacker or CSS tidy. It also supports URL rewriting in CSS files.")
10707 (license license:bsd-2)))
10708
10709(define-public python-flask-migrate
10710 (package
10711 (name "python-flask-migrate")
10712 (version "4.1.0")
10713 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
10714 (source (origin
10715 (method git-fetch)
10716 (uri (git-reference (url home-page)
10717 (commit (string-append "v" version))))
10718 (file-name (git-file-name name version))
10719 (sha256
10720 (base32
10721 "09qw1hhyssa5gahm199x67d55c55m3k9m23xp2bdacwsiv8jw57g"))))
10722 (build-system pyproject-build-system)
10723 (propagated-inputs
10724 (list python-flask python-alembic python-flask-sqlalchemy))
10725 (native-inputs
10726 (list python-pytest python-setuptools python-wheel))
10727 (synopsis "SQLAlchemy database migrations for Flask programs using
10728Alembic")
10729 (description "This package contains SQLAlchemy database migration tools
10730for Flask programs that are using @code{python-alembic}.")
10731 (license license:expat)))
10732
10733(define-public python-genshi
10734 (package
10735 (name "python-genshi")
10736 (version "0.7.10")
10737 (source
10738 (origin
10739 (method git-fetch)
10740 (uri (git-reference
10741 (url "https://github.com/edgewall/genshi")
10742 (commit version)))
10743 (file-name (git-file-name name version))
10744 (sha256
10745 (base32 "1dmf0ggp0s3371jv483kjriw9jscawxcik6q70a0wqjdfh5383i6"))))
10746 (build-system pyproject-build-system)
10747 (arguments (list #:test-backend #~'unittest))
10748 (native-inputs (list python-setuptools))
10749 (propagated-inputs (list python-six))
10750 (home-page "https://genshi.edgewall.org/")
10751 (synopsis "Toolkit for generation of output for the web")
10752 (description "Genshi is a Python library that provides an integrated set
10753of components for parsing, generating, and processing HTML, XML or other
10754textual content for output generation on the web.")
10755 (license license:bsd-3)))
10756
10757(define-public python-flask-principal
10758 (package
10759 (name "python-flask-principal")
10760 (version "0.4.0")
10761 (source
10762 (origin
10763 (method git-fetch)
10764 (uri (git-reference
10765 (url "https://github.com/pallets-eco/flask-principal")
10766 (commit version)))
10767 (file-name (git-file-name name version))
10768 (sha256
10769 (base32 "0hcqcj768inmyfsw1y2vk6pa9p22dh138ll809rhpz9vjz6spnqk"))))
10770 (build-system pyproject-build-system)
10771 (propagated-inputs (list python-blinker))
10772 (native-inputs (list python-flask python-pynose python-setuptools))
10773 (home-page "https://github.com/pallets-eco/flask-principal")
10774 (synopsis "Identity management for Flask")
10775 (description
10776 "@code{flask_principal} is a identity management library for Flask. It
10777supports managing both authentication and authorization data in a thread-local
10778variable.")
10779 (license license:expat)))
10780
10781(define-public python-flask-httpauth
10782 (package
10783 (name "python-flask-httpauth")
10784 (version "4.8.0")
10785 (source
10786 (origin
10787 (method url-fetch)
10788 (uri (pypi-uri "Flask-HTTPAuth" version))
10789 (sha256
10790 (base32
10791 "0yh9fn6pak64has89pcy03f1cn198vkil872y5jjr53kph2qlmk6"))))
10792 (build-system pyproject-build-system)
10793 (propagated-inputs (list python-flask))
10794 (native-inputs
10795 (list nss-certs-for-test
10796 python-pytest
10797 python-setuptools
10798 python-wheel))
10799 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
10800 (synopsis "Basic and Digest HTTP authentication for Flask routes")
10801 (description "@code{flask_httpauth} provides Basic and Digest HTTP
10802authentication for Flask routes.")
10803 (license license:expat)))
10804
10805(define-public python-uritemplate
10806 (package
10807 (name "python-uritemplate")
10808 (version "4.2.0")
10809 (source
10810 (origin
10811 (method url-fetch)
10812 (uri (pypi-uri "uritemplate" version))
10813 (sha256
10814 (base32
10815 "03lxxkk0kjn6z7z1f9hqvsaqfrny1qds7vi36f35b2c7h38jw328"))))
10816 (build-system pyproject-build-system)
10817 (native-inputs (list python-pytest python-setuptools))
10818 (home-page "https://uritemplate.readthedocs.io/")
10819 (synopsis "Library to deal with URI Templates")
10820 (description "@code{uritemplate} provides Python library to deal with URI
10821Templates.")
10822 ;; The software is made available under the terms of *either* of the
10823 ;; licenses found in LICENSE.APACHE or LICENSE.BSD. Contributions
10824 ;; are made under *both* licenses (excerpt from the LICENSE file).
10825 (license (list license:bsd-2 license:asl2.0))))
10826
10827(define-public python-uritemplate-3
10828 (package
10829 (inherit python-uritemplate)
10830 (name "python-uritemplate")
10831 (version "3.0.1")
10832 (source (origin
10833 (method url-fetch)
10834 (uri (pypi-uri "uritemplate" version))
10835 (sha256
10836 (base32 "1bkwmgr0ia9gcn4bszs2xlvml79f0bi2s4a87xg22ky9rq8avy2s"))))))
10837
10838(define-public python-publicsuffix2
10839 (package
10840 (name "python-publicsuffix2")
10841 (version "2.2019-12-21")
10842 (source
10843 (origin
10844 (method git-fetch)
10845 (uri (git-reference
10846 (url "https://github.com/pombredanne/python-publicsuffix2")
10847 (commit (string-append "release-" version))))
10848 (file-name (git-file-name name version))
10849 (sha256
10850 (base32 "1dkvfvl0izq9hqzilnw8ipkbgjs9xyad9p21i3864hzinbh0wp9r"))))
10851 (build-system pyproject-build-system)
10852 (arguments
10853 (list
10854 #:tests? #f ;the test suite requires network access
10855 #:phases
10856 #~(modify-phases %standard-phases
10857 (add-after 'unpack 'ignore-maintainer-inputs
10858 (lambda _
10859 ;; Comment out a demand for python-requests, which is used only by
10860 ;; the unused ‘update_psl’ helper command.
10861 (substitute* "setup.py"
10862 (("'requests " match)
10863 (format #f "# ~a" match))))))))
10864 (native-inputs (list python-setuptools))
10865 (home-page "https://github.com/pombredanne/python-publicsuffix2")
10866 (synopsis
10867 "Get a public suffix for a domain name using the Public Suffix List")
10868 (description
10869 "Get a public suffix for a domain name using the Public Suffix List.
10870Forked from and using the same API as the publicsuffix package.")
10871 (license (list license:expat license:mpl2.0))))
10872
10873(define-public python-werkzeug
10874 (package
10875 (name "python-werkzeug")
10876 (version "3.1.8")
10877 (source
10878 (origin
10879 (method git-fetch)
10880 (uri (git-reference
10881 (url "https://github.com/pallets/werkzeug")
10882 (commit version)))
10883 (file-name (git-file-name name version))
10884 (sha256
10885 (base32 "1jwrrjv50n5rcfzax4qf0237znkcpcafd17hx0r77f997yv3ghlv"))))
10886 (build-system pyproject-build-system)
10887 (arguments
10888 (list
10889 #:test-flags
10890 #~(list "-m" "not dev_server")))
10891 (native-inputs
10892 (list python-ephemeral-port-reserve
10893 python-flit-core
10894 python-pytest
10895 python-pytest-timeout
10896 python-watchdog))
10897 (propagated-inputs
10898 (list python-markupsafe))
10899 (home-page "https://palletsprojects.com/p/werkzeug/")
10900 (synopsis "Utilities for WSGI applications")
10901 (description "One of the most advanced WSGI utility modules. It includes a
10902powerful debugger, full-featured request and response objects, HTTP utilities to
10903handle entity tags, cache control headers, HTTP dates, cookie handling, file
10904uploads, a powerful URL routing system and a bunch of community-contributed
10905addon modules.")
10906 (license license:x11)))
10907
10908(define-public python-werkzeug-1.0
10909 (package
10910 (inherit python-werkzeug)
10911 (version "1.0.1")
10912 (source (origin
10913 (method url-fetch)
10914 (uri (pypi-uri "Werkzeug" version))
10915 (sha256
10916 (base32
10917 "0z74sa1xw5h20yin9faj0vvdbq713cgbj84klc72jr9nmpjv303c"))
10918 (patches (search-patches "python-werkzeug-tests.patch"))))
10919 (arguments
10920 (list
10921 #:phases
10922 '(modify-phases %standard-phases
10923 (add-after 'unpack 'ignore-warnings
10924 (lambda _
10925 (substitute* "setup.cfg"
10926 ((" error.*") "")))))))
10927 (propagated-inputs
10928 (list python-requests))
10929 (native-inputs
10930 (list python-pytest python-pytest-timeout python-setuptools
10931 python-wheel))))
10932
10933(define-public python-wtforms
10934 (package
10935 (name "python-wtforms")
10936 (version "3.2.2")
10937 (source
10938 (origin
10939 (method url-fetch)
10940 (uri (pypi-uri "wtforms" version))
10941 (sha256
10942 (base32 "14qbayp2gfmahaqn5migwyz2h1cq3gcdr4q2vd75vwvhhqzwf03v"))))
10943 (build-system pyproject-build-system)
10944 (native-inputs
10945 (list python-babel
10946 python-email-validator
10947 python-hatchling
10948 python-pytest
10949 python-setuptools))
10950 (propagated-inputs (list python-markupsafe))
10951 (home-page "https://wtforms.readthedocs.io/")
10952 (synopsis
10953 "Form validation and rendering library for Python web development")
10954 (description
10955 "WTForms is a flexible forms validation and rendering library
10956for Python web development. It is very similar to the web form API
10957available in Django, but is a standalone package.")
10958 (license license:bsd-3)))
10959
10960(define-public python-wtforms-sqlalchemy
10961 (package
10962 (name "python-wtforms-sqlalchemy")
10963 (version "0.4.1")
10964 (source
10965 (origin
10966 (method url-fetch)
10967 (uri (pypi-uri "WTForms-SQLAlchemy" version))
10968 (sha256
10969 (base32 "1nx4x0ifanlbrzh3f9ns8ihnchlkzf54ilvqmgcgcz2j72vm43rp"))))
10970 (build-system pyproject-build-system)
10971 (native-inputs (list python-pytest python-setuptools python-wheel))
10972 (propagated-inputs (list python-sqlalchemy python-wtforms))
10973 (home-page "https://github.com/wtforms/wtforms-sqlalchemy/")
10974 (synopsis "SQLAlchemy tools for WTForms")
10975 (description
10976 "WTForms-SQLAlchemy is a fork of the @code{wtforms.ext.sqlalchemy}
10977package from WTForms. The package has been renamed to
10978@code{wtforms_sqlalchemy} but otherwise should function the same as
10979@code{wtforms.ext.sqlalchemy} did.")
10980 (license license:bsd-3)))
10981
10982(define-public python-urlgrabber
10983 (package
10984 (name "python-urlgrabber")
10985 (version "4.1.0")
10986 (source
10987 (origin
10988 (method url-fetch)
10989 (uri (pypi-uri "urlgrabber" version))
10990 (sha256
10991 (base32 "0fg16zlw49cw7pjq9dhpc5vd35d5zz1mlki55m464qxfmfpzhnh7"))))
10992 (build-system pyproject-build-system)
10993 (arguments
10994 (list
10995 #:tests? #f ; Most tests require network access.
10996 #:phases
10997 #~(modify-phases %standard-phases
10998 (replace 'check
10999 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
11000 (when tests?
11001 (invoke "python" "test/runtests.py")))))))
11002 (native-inputs (list python-setuptools))
11003 (propagated-inputs
11004 (list python-pycurl python-setuptools python-six))
11005 (home-page "http://urlgrabber.baseurl.org/") ; no HTTPS
11006 (synopsis "High-level cross protocol url-grabber")
11007 (description
11008 "@code{urlgrabber} is a library that unifies access to files available on
11009the web, FTP or locally. It supports HTTP, FTP and file:// protocols, it
11010supports features like HTTP keep-alive, reget, throttling and more.")
11011 (license license:lgpl2.1+)))
11012
11013(define-public python-pycares
11014 (package
11015 (name "python-pycares")
11016 (version "4.11.0")
11017 (source
11018 (origin
11019 (method git-fetch)
11020 (uri (git-reference
11021 (url "https://github.com/saghul/pycares")
11022 (commit (string-append "v" version))))
11023 (file-name (git-file-name name version))
11024 (sha256
11025 (base32 "18syxp9bpm70zfiw427p7cpp6wg0ybrw6b32c1zvdp2i8jgd82xl"))
11026 (snippet #~(begin
11027 (rmdir "deps/c-ares")))))
11028 (build-system pyproject-build-system)
11029 (arguments
11030 (list
11031 ;; XXX: Half of the tests require internet access
11032 ;; There is currently no markers to avoid running them.
11033 #:tests? #f
11034 #:phases
11035 #~(modify-phases %standard-phases
11036 (add-after 'unpack 'configure-system-lib
11037 (lambda _
11038 (setenv "PYCARES_USE_SYSTEM_LIB" "1"))))))
11039 (native-inputs (list python-pytest python-setuptools))
11040 (inputs (list c-ares))
11041 (propagated-inputs (list python-cffi))
11042 (home-page "https://github.com/saghul/pycares")
11043 (synopsis "Python interface for @code{c-ares}")
11044 (description
11045 "@code{pycares} is a Python module which provides an interface to
11046@code{c-ares}, a C library that performs DNS requests and name resolutions
11047asynchronously.")
11048 (license license:expat)))
11049
11050(define-public python-yarl
11051 (package
11052 (name "python-yarl")
11053 (version "1.18.3")
11054 (source
11055 (origin
11056 (method url-fetch)
11057 (uri (pypi-uri "yarl" version))
11058 (sha256
11059 (base32
11060 "1qfj6kvdxr8bzka4lp0bh0xfgr5mzx7zzvj2jb4vcxxzbk20265c"))))
11061 (build-system pyproject-build-system)
11062 (arguments
11063 (list
11064 #:test-flags '(list "--ignore-glob=tests/test_*_benchmarks.py")
11065 #:phases
11066 '(modify-phases %standard-phases
11067 (add-after 'unpack 'avoid-pytest-cov-preload
11068 (lambda _
11069 (substitute* "pytest.ini"
11070 (("-p pytest_cov") ""))))
11071 (add-after 'unpack 'patch-build-system
11072 (lambda _
11073 ;; XXX: I don't know how to tell it to build the extensions in
11074 ;; place.
11075 (substitute* "packaging/pep517_backend/_backend.py"
11076 (("build_inplace=False") "build_inplace=True")))))))
11077 (native-inputs
11078 (list python-cython
11079 python-expandvars
11080 python-pytest
11081 python-pytest-xdist
11082 python-setuptools
11083 python-tomli))
11084 (propagated-inputs
11085 (list python-packaging python-idna python-multidict python-propcache))
11086 (home-page "https://github.com/aio-libs/yarl/")
11087 (synopsis "Yet another URL library")
11088 (description "@code{yarl} module provides handy @code{URL} class
11089for URL parsing and changing.")
11090 (license license:asl2.0)))
11091
11092(define-public python-google
11093 (package
11094 (name "python-google")
11095 (version "3.0.0")
11096 (source
11097 (origin
11098 (method url-fetch)
11099 (uri (pypi-uri "google" version))
11100 (sha256
11101 (base32 "1gncv3l11za0mpxvmpaf5n5j3jzp282rz62yml4ha4z55q930d8l"))))
11102 (build-system pyproject-build-system)
11103 (arguments (list #:tests? #f)) ;There are no tests.
11104 (native-inputs (list python-setuptools))
11105 (propagated-inputs (list python-beautifulsoup4))
11106 (home-page "https://breakingcode.wordpress.com/")
11107 (synopsis "Python bindings to the Google search engine")
11108 (description
11109 "This package provides Python bindings for using the Google search
11110engine. Its module is called @code{googlesearch}.")
11111 (license license:bsd-3)))
11112
11113(define-public python-google-api-client
11114 (package
11115 (name "python-google-api-client")
11116 (version "2.198.0")
11117 (source
11118 (origin
11119 (method git-fetch)
11120 (uri (git-reference
11121 (url "https://github.com/google/google-api-python-client")
11122 (commit (string-append "v" version))))
11123 (file-name (git-file-name name version))
11124 (sha256
11125 (base32 "1adjr3ylp8bwbvywxm11hs4y913pvaga0dn6nwmb3622y62zxfhg"))))
11126 (build-system pyproject-build-system)
11127 (arguments
11128 (list
11129 #:test-flags
11130 #~(list
11131 "-k"
11132 (string-join
11133 (list
11134 ;; XXX: Deprecated behavior.
11135 "not test_client_options_universe_configured_with_mtls"
11136 "test_universe_env_var_configured_with_mtls"
11137 ;; XXX: Requires CA certificates.
11138 "test_credentials_and_credentials_file_mutually_exclusive")
11139 " and not ")
11140 "tests")))
11141 (native-inputs
11142 (list python-parameterized
11143 python-pytest
11144 python-setuptools))
11145 (propagated-inputs
11146 (list python-google-api-core
11147 python-google-auth
11148 python-google-auth-httplib2
11149 python-httplib2
11150 python-pyparsing
11151 python-uritemplate-3))
11152 (home-page "https://github.com/google/google-api-python-client")
11153 (synopsis "Core Python library for accessing Google APIs")
11154 (description "Python client library for Google's discovery based APIs")
11155 (license license:asl2.0)))
11156
11157(define-public python-google-auth-httplib2
11158 (package
11159 (name "python-google-auth-httplib2")
11160 (version "0.4.0")
11161 (source (origin
11162 (method url-fetch)
11163 (uri (pypi-uri "google_auth_httplib2" version))
11164 (sha256
11165 (base32 "0dgdzy2ps3z71dc2b4s1fhmyx094nq0sg75sagav995p0ji31c6m"))))
11166 (build-system pyproject-build-system)
11167 (propagated-inputs
11168 (list python-google-auth python-httplib2))
11169 (native-inputs
11170 (list python-pytest
11171 python-pyparsing
11172 python-pytest-localserver
11173 python-flask
11174 python-setuptools))
11175 (home-page "https://github.com/googleapis/google-cloud-python")
11176 (synopsis "Google Authentication Library: httplib2 transport")
11177 (description "This package provides a Google Authentication Library plugin
11178for httplib2 transport.")
11179 (license license:asl2.0)))
11180
11181(define-public python-google-auth-oauthlib
11182 (package
11183 (name "python-google-auth-oauthlib")
11184 (version "1.2.4")
11185 (home-page
11186 "https://github.com/GoogleCloudPlatform/\
11187google-auth-library-python-oauthlib")
11188 (source
11189 (origin
11190 (method git-fetch)
11191 (uri (git-reference
11192 (url home-page)
11193 (commit (string-append "v" version))))
11194 (file-name (git-file-name name version))
11195 (sha256
11196 (base32 "1j25kdbs2j1x23pdv4n49xl9pz2ppn55vsav65ir796kq4lf9nca"))))
11197 (build-system pyproject-build-system)
11198 (propagated-inputs (list python-google-auth python-requests-oauthlib))
11199 (native-inputs
11200 (list python-click python-mock python-pytest python-setuptools))
11201 (synopsis "Google Authentication Library: oauthlib")
11202 (description "This package provides a Google Authentication Library plugin
11203with oauthlib.")
11204 (license license:asl2.0)))
11205
11206(define-public whoogle-search
11207 (package
11208 (name "whoogle-search")
11209 (version "0.8.4")
11210 (source (origin
11211 (method url-fetch)
11212 (uri (pypi-uri "whoogle-search" version))
11213 (sha256
11214 (base32
11215 "0hsy4l98nzj6i1lf63wvqd0yharkaz44zsxh863ymy47rxnwimz7"))))
11216 (build-system pyproject-build-system)
11217 (arguments
11218 (list
11219 ;; The tests need network access
11220 #:tests? #f))
11221 (propagated-inputs
11222 (list python-beautifulsoup4
11223 python-brotli
11224 python-cryptography
11225 python-cssutils
11226 python-defusedxml
11227 python-flask
11228 python-dotenv
11229 python-requests
11230 python-stem
11231 python-validators
11232 python-waitress))
11233 (native-inputs (list python-setuptools python-wheel))
11234 (home-page "https://github.com/benbusby/whoogle-search")
11235 (synopsis "Self-hosted, ad-free, privacy-respecting metasearch engine")
11236 (description
11237 "Get Google results, but without any ads, javascript, AMP links,
11238cookies, or IP address tracking. Quick and simple to implement as a primary
11239search engine replacement on both desktop and mobile.")
11240 (license license:expat)))
11241
11242(define-public python-hawkauthlib
11243 (package
11244 (name "python-hawkauthlib")
11245 (version "2.0.0")
11246 (source
11247 (origin
11248 (method git-fetch)
11249 (uri (git-reference
11250 (url "https://github.com/mozilla-services/hawkauthlib")
11251 (commit (string-append "v" version))))
11252 (file-name (git-file-name name version))
11253 (sha256
11254 (base32 "0pdpk3fp87ngfsyp4lm2z7z8b203jxsmvbz59q6r6xgg9sp4cl3l"))))
11255 (build-system pyproject-build-system)
11256 (arguments
11257 (list
11258 #:test-backend #~'unittest
11259 #:phases
11260 #~(modify-phases %standard-phases
11261 (add-after 'unpack 'fix-python-incompatibilities
11262 (lambda _
11263 (substitute* (find-files "hawkauthlib/tests" "\\.py$")
11264 (("assertEquals") "assertEqual")))))))
11265 (native-inputs (list python-setuptools))
11266 (propagated-inputs (list python-requests python-webob))
11267 (home-page "https://github.com/mozilla-services/hawkauthlib")
11268 (synopsis "Hawk Access Authentication protocol")
11269 (description
11270 "This is a low-level Python library for implementing Hawk Access
11271Authentication, a simple HTTP request-signing scheme.")
11272 (license license:mpl2.0)))
11273
11274(define-public python-pybrowserid
11275 (package
11276 (name "python-pybrowserid")
11277 (version "0.14.0")
11278 (source
11279 (origin
11280 (method git-fetch)
11281 (uri (git-reference
11282 (url "https://github.com/mozilla/PyBrowserID")
11283 (commit version)))
11284 (file-name (git-file-name name version))
11285 (sha256
11286 (base32 "0in0sbj56wrz5mlrj6wkd3h7rrp7714c5rkxvkfwp60s2hr6ynj6"))))
11287 (build-system pyproject-build-system)
11288 (arguments
11289 (list
11290 #:test-backend #~'unittest
11291 #:phases
11292 #~(modify-phases %standard-phases
11293 (add-after 'unpack 'python-3.12-compatibility
11294 (lambda _
11295 (substitute* (find-files "browserid/tests" "\\.py")
11296 (("assertEquals") "assertEqual")))))))
11297 (propagated-inputs (list python-requests))
11298 (native-inputs (list python-mock python-setuptools))
11299 (home-page "https://github.com/mozilla/PyBrowserID")
11300 (synopsis "Python library for the BrowserID protocol")
11301 (description
11302 "This is a Python client library for the BrowserID protocol that
11303underlies Mozilla Persona.")
11304 (license license:mpl2.0)))
11305
11306(define-public python-pyfxa
11307 (package
11308 (name "python-pyfxa")
11309 (version "0.8.1")
11310 (source
11311 (origin
11312 (method git-fetch)
11313 (uri (git-reference
11314 (url "https://github.com/mozilla/PyFxA")
11315 (commit (string-append "v" version))))
11316 (file-name (git-file-name name version))
11317 (sha256
11318 (base32 "11iaw50x5ic9cqp3jwkvhk8mz00dhg8xhl1kkx45zrb8nnrfw2vs"))))
11319 (build-system pyproject-build-system)
11320 (arguments
11321 (list
11322 ;; These tests require network access
11323 #:test-flags #~(list "--ignore=fxa/tests/test_core.py")))
11324 (propagated-inputs
11325 (list python-cryptography
11326 python-pyjwt
11327 python-parameterized
11328 python-hawkauthlib
11329 python-requests))
11330 (native-inputs
11331 (list python-grequests
11332 python-hatchling
11333 python-mock
11334 python-pytest
11335 python-responses))
11336 (home-page "https://github.com/mozilla/PyFxA")
11337 (synopsis "Firefox Accounts client library for Python")
11338 (description
11339 "This is a Python library for interacting with the Firefox Accounts
11340ecosystem.")
11341 (license license:mpl2.0)))
11342
11343(define-public python-hyperlink
11344 (package
11345 (name "python-hyperlink")
11346 (version "21.0.0")
11347 (source
11348 (origin
11349 (method url-fetch)
11350 (uri (pypi-uri "hyperlink" version))
11351 (sha256
11352 (base32
11353 "0sx50lkivsfjxx9zr4yh7l9gll2l9kvl0v0w8w4wk2x5v9bzjyj2"))))
11354 (build-system pyproject-build-system)
11355 (arguments
11356 (list #:phases
11357 #~(modify-phases %standard-phases
11358 (add-before 'check 'pretend-to-be-CI
11359 (lambda _
11360 ;; Pretend to be a CI system to skip flaky tests.
11361 (setenv "CI" "true"))))))
11362 (native-inputs
11363 (list python-pytest python-setuptools python-wheel))
11364 (propagated-inputs
11365 (list python-idna))
11366 (home-page "https://github.com/python-hyper/hyperlink")
11367 (synopsis "Python module to create immutable URLs according to spec")
11368 (description "This package provides a Python module to create immutable, and
11369correct URLs for Python according to RFCs 3986 and 3987.")
11370 (license license:expat)))
11371
11372(define-public python-treq
11373 (package
11374 (name "python-treq")
11375 (version "24.9.1")
11376 (source
11377 (origin
11378 (method url-fetch)
11379 (uri (pypi-uri "treq" version))
11380 (sha256
11381 (base32
11382 "1a7yrq2m7hf77fia4fc0c6zanvwnykpgirdbs1cyvr7k0k27znhm"))))
11383 (build-system pyproject-build-system)
11384 (native-inputs
11385 (list python-httpbin
11386 python-pytest
11387 python-service-identity
11388 python-setuptools
11389 python-wheel))
11390 (propagated-inputs
11391 (list python-attrs
11392 python-hyperlink
11393 python-incremental
11394 python-requests
11395 python-twisted
11396 python-typing-extensions))
11397 (home-page "https://github.com/twisted/treq")
11398 (synopsis "Requests-like API built on top of twisted.web's Agent")
11399 (description "This package provides an HTTP library inspired by
11400@code{requests} but written on top of Twisted's @code{Agents}. It offers a
11401high level API for making HTTP requests when using Twisted.")
11402 (license license:expat)))
11403
11404(define-public python-ws4py
11405 (package
11406 (name "python-ws4py")
11407 (version "0.6.0")
11408 (source
11409 (origin
11410 (method git-fetch)
11411 (uri (git-reference
11412 (url "https://github.com/Lawouach/WebSocket-for-Python")
11413 (commit version)))
11414 (file-name (git-file-name name version))
11415 (sha256
11416 (base32
11417 "00y6s8gk20936njqbxr8vjliviiz7r7pqrlwg7xi8zzs6903xvv6"))))
11418 (build-system pyproject-build-system)
11419 (arguments
11420 (list
11421 #:phases
11422 #~(modify-phases %standard-phases
11423 (add-after 'unpack 'remove-cherrypy-support
11424 (lambda _
11425 (delete-file "ws4py/server/cherrypyserver.py")
11426 (delete-file "test/test_cherrypy.py"))))))
11427 (native-inputs (list python-setuptools python-pytest))
11428 (propagated-inputs
11429 (list python-gevent python-tornado))
11430 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
11431 (synopsis "WebSocket client and server library")
11432 (description
11433 "This package provides a WebSocket client and server library for Python.")
11434 (license license:bsd-3)))
11435
11436(define-public python-slowapi
11437 (package
11438 (name "python-slowapi")
11439 (version "0.1.9")
11440 (source
11441 (origin
11442 (method git-fetch)
11443 (uri (git-reference
11444 (url "https://github.com/laurents/slowapi")
11445 (commit (string-append "v" version))))
11446 (file-name (git-file-name name version))
11447 (sha256
11448 (base32 "1lc1n6lvh01dhhrc507qri9rz1w72l2riii03ixh7n7n1gwjpws7"))))
11449 (build-system pyproject-build-system)
11450 (arguments
11451 (list
11452 #:test-flags
11453 ;; These tests fail because the timestamp contains more decimal points
11454 ;; than expected, so a simple equality comparison fails.
11455 '(list "-k" (string-append "not test_headers_no_breach"
11456 " and not test_headers_breach"))))
11457 (propagated-inputs (list python-limits python-redis))
11458 (native-inputs
11459 (list python-fastapi
11460 python-hiro
11461 python-mock
11462 python-poetry-core
11463 python-pytest))
11464 (home-page "https://github.com/laurents/slowapi")
11465 (synopsis "Rate limiting extension for Starlette and Fastapi")
11466 (description
11467 "This package provides a rate limiting extension for Starlette and
11468Fastapi.")
11469 (license license:expat)))
11470
11471(define-public python-slugify
11472 (package
11473 (name "python-slugify")
11474 (version "8.0.4")
11475 (source
11476 (origin
11477 (method git-fetch)
11478 (uri (git-reference
11479 (url "https://github.com/un33k/python-slugify")
11480 (commit (string-append "v" version))))
11481 (file-name (git-file-name name version))
11482 (sha256
11483 (base32 "0z83nwy7acc72mb2jv3516nfplah1wm61wkmnzl71dh8i4q985yd"))))
11484 (build-system pyproject-build-system)
11485 (arguments (list #:test-backend #~'unittest))
11486 (native-inputs (list python-setuptools))
11487 (propagated-inputs (list python-unidecode python-text-unidecode))
11488 (home-page "https://github.com/un33k/python-slugify")
11489 (synopsis "Python Slugify application that handles Unicode")
11490 (description "This package provides a @command{slufigy} command and
11491library to create slugs from unicode strings while keeping it DRY.")
11492 (license license:expat)))
11493
11494(define-public python-tinycss2
11495 (package
11496 (name "python-tinycss2")
11497 (version "1.5.1")
11498 (source
11499 (origin
11500 (method git-fetch)
11501 (uri (git-reference
11502 (url "https://github.com/Kozea/tinycss2")
11503 (commit (string-append "v" version))
11504 (recursive? #true)))
11505 (file-name (git-file-name name version))
11506 (sha256
11507 (base32 "1ww5m8rmpva9mq04cz1h9rx76vg2h5nnijzi0vprf5wzp8g9snb5"))))
11508 (build-system pyproject-build-system)
11509 (native-inputs
11510 (list python-flit-core
11511 python-pytest))
11512 (propagated-inputs
11513 (list python-webencodings))
11514 (home-page "https://doc.courtbouillon.org/tinycss2/stable/")
11515 (synopsis "Low-level CSS parser for Python")
11516 (description "@code{tinycss2} can parse strings, return Python objects
11517representing tokens and blocks, and generate CSS strings corresponding to
11518these objects.
11519
11520Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
11521grammar of CSS but doesn’t know specific rules, properties or values supported
11522in various CSS modules.")
11523 (license license:bsd-3)))
11524
11525(define-public python-tinyhtml5
11526 (package
11527 (name "python-tinyhtml5")
11528 (version "2.1.0")
11529 (source
11530 (origin
11531 (method git-fetch)
11532 (uri (git-reference
11533 (url "https://github.com/CourtBouillon/tinyhtml5")
11534 (commit version)))
11535 (file-name (git-file-name name version))
11536 (sha256
11537 (base32 "1q8z2ym2q6083ky0f9vwf73k3gimffnbfwlpmd69bp6anc4fa81x"))))
11538 (build-system pyproject-build-system)
11539 (propagated-inputs
11540 (list python-webencodings))
11541 (native-inputs
11542 (list python-flit-core
11543 python-pytest))
11544 (home-page "https://github.com/CourtBouillon/tinyhtml5")
11545 (synopsis "Small HTML parser based on the WHATWG HTML specification")
11546 (description "This Python module is a HTML5 parser that transforms a
11547possibly malformed HTML document into an ElementTree tree. This module is a
11548simplified fork of html5lib.")
11549 (license license:expat)))
11550
11551(define-public python-uvloop
11552 (package
11553 (name "python-uvloop")
11554 (version "0.22.1")
11555 (source
11556 (origin
11557 (method git-fetch)
11558 (uri (git-reference
11559 (url "https://github.com/MagicStack/uvloop")
11560 (commit (string-append "v" version))))
11561 (file-name (git-file-name name version))
11562 (sha256
11563 (base32 "1qbykwwz4ac3f7472g22z4i5rrd5kcr8hmxn5kswmja57j1nxlpl"))
11564 (modules '((guix build utils)))
11565 (snippet
11566 '(begin
11567 (delete-file-recursively "vendor")))))
11568 (build-system pyproject-build-system)
11569 (arguments
11570 (list
11571 ;; tests: 470 passed, 32 skipped, 8 deselected, 5 warnings, 104 subtests passed
11572 #:test-flags
11573 ;; The tests are prone to get stuck. Use pytest-timeout’s --timeout flag
11574 ;; to get a meaningful idea about where.
11575 #~(list "--timeout=300"
11576 "--timeout-method=thread"
11577 "-k" (string-join
11578 (list
11579 ;; Timeout, because SIGINT cannot be sent to child.
11580 "not test_signals_sigint_pycode_continue"
11581 "test_signals_sigint_pycode_stop"
11582 "test_signals_sigint_uvcode"
11583 "test_signals_sigint_uvcode_two_loop_runs"
11584 #$@(if (target-riscv64?)
11585 `("test_renegotiation")
11586 `()))
11587 " and not "))
11588 #:phases
11589 #~(modify-phases %standard-phases
11590 (add-after 'unpack 'preparations
11591 (lambda _
11592 ;; Use packaged libuv.
11593 (substitute* "setup.py" (("self.use_system_libuv = False")
11594 "self.use_system_libuv = True"))
11595 ;; Replace hardcoded shell command.
11596 (substitute* "uvloop/loop.pyx"
11597 (("b'/bin/sh'") (string-append "b'" (which "sh") "'")))
11598 (substitute* "tests/test_process.py"
11599 (("'env'") (string-append "'" (which "env") "'")))))
11600 #$@(if (target-riscv64?)
11601 `((add-after 'unpack 'adjust-test-timeouts
11602 (lambda _
11603 (substitute* '("tests/test_tcp.py"
11604 "tests/test_unix.py")
11605 (("SSL_HANDSHAKE_TIMEOUT = 15\\.0")
11606 "SSL_HANDSHAKE_TIMEOUT = 30.0")))))
11607 '())
11608 (add-before 'check 'pre-check
11609 (lambda* (#:key tests? #:allow-other-keys)
11610 (when tests?
11611 ;; Remove Python module, which conflicts with the installed
11612 ;; version, but lacks the built C module.
11613 (delete-file-recursively "uvloop")))))))
11614 (native-inputs
11615 (list python-aiohttp
11616 python-cython
11617 python-psutil
11618 python-pyopenssl
11619 python-pytest
11620 python-pytest-timeout
11621 python-setuptools))
11622 (inputs
11623 (list libuv))
11624 (home-page "https://github.com/MagicStack/uvloop")
11625 (synopsis "Fast implementation of asyncio event loop on top of libuv")
11626 (description
11627 "@code{uvloop} is a fast, drop-in replacement of the built-in asyncio
11628event loop. It is implemented in Cython and uses libuv under the hood.")
11629 (license license:expat)))
11630
11631(define-public python-httptools
11632 (package
11633 (name "python-httptools")
11634 (version "0.7.1")
11635 (source
11636 (origin
11637 ;; PyPI tarball comes with a vendored http-parser and no tests.
11638 (method git-fetch)
11639 (uri (git-reference
11640 (url "https://github.com/MagicStack/httptools")
11641 (commit (string-append "v" version))))
11642 (file-name (git-file-name name version))
11643 (sha256
11644 (base32 "0j9c1av3y1smg6lgh0i031l07i9plzbvv14jj53vpzm35sy7kbl7"))
11645 (modules '((guix build utils)))
11646 (snippet
11647 #~(begin (delete-file-recursively "vendor")))))
11648 (build-system pyproject-build-system)
11649 (arguments
11650 (list
11651 #:test-flags
11652 ;; XXX: AssertionError: HttpParserError not raised.
11653 #~(list "-k" "not test_parser_response_leninent_headers_1")
11654 #:phases
11655 #~(modify-phases %standard-phases
11656 (add-after 'unpack 'configure-build-ext
11657 (lambda _
11658 (with-output-to-file "setup.cfg"
11659 (lambda ()
11660 (display "\
11661[build_ext]
11662use_system_llhttp = true
11663use_system_http_parser = true
11664cython_always = true"))))))))
11665 (native-inputs
11666 (list python-cython
11667 python-pytest
11668 python-setuptools))
11669 (inputs
11670 (list http-parser
11671 llhttp))
11672 (home-page "https://github.com/MagicStack/httptools")
11673 (synopsis "Collection of framework independent HTTP protocol utils")
11674 (description
11675 "@code{httptools} is a Python binding for the nodejs HTTP parser.")
11676 (license license:expat)))
11677
11678(define-public python-uvicorn
11679 (package
11680 (name "python-uvicorn")
11681 ;; 0.49.0 (2026-06-03), release does not work with python-websockets 16.0,
11682 ;; see: <https://github.com/Kludex/uvicorn/pull/2985>.
11683 (properties '((commit . "e8a31bca03254b8457c4c89596e310282cc33edc")
11684 (revision . "0")))
11685 (version (git-version "0.49.0"
11686 (assoc-ref properties 'revision)
11687 (assoc-ref properties 'commit)))
11688 (source
11689 (origin
11690 (method git-fetch)
11691 (uri (git-reference
11692 (url "https://github.com/encode/uvicorn")
11693 (commit (assoc-ref properties 'commit))))
11694 (file-name (git-file-name name version))
11695 (sha256
11696 (base32 "1vd1680a1k3jcdgc3jd5p3a6zmhz4r8bgzb7v7zhpxrkkdsisrxj"))))
11697 (build-system pyproject-build-system)
11698 (arguments
11699 (list
11700 #:test-flags
11701 #~(list "--ignore=tests/benchmarks"
11702 #$@(cond
11703 ((or (target-aarch64?)
11704 (target-riscv64?))
11705 '("-k not test_send_binary_data_to_server_bigger_than_default_on_websockets"))
11706 (#t '())))))
11707 (native-inputs
11708 (list nss-certs-for-test
11709 python-a2wsgi
11710 python-hatchling
11711 python-httpx-bootstrap
11712 python-pytest
11713 python-pytest-asyncio
11714 python-pytest-mock
11715 python-pytest-xdist
11716 python-requests
11717 python-trustme
11718 python-wsproto))
11719 (propagated-inputs
11720 (list python-a2wsgi
11721 python-click
11722 python-dotenv
11723 python-h11
11724 python-httptools
11725 python-pyyaml
11726 python-uvloop
11727 python-watchfiles
11728 python-websockets))
11729 (home-page "https://github.com/encode/uvicorn")
11730 (synopsis "Fast ASGI server implementation")
11731 (description
11732 "@code{uvicorn} is a fast ASGI server implementation, using @code{uvloop}
11733and @code{httptools}. It currently supports HTTP/1.1 and WebSockets. Support
11734for HTTP/2 is planned.")
11735 (license license:bsd-3)))
11736
11737(define-public python-translation-finder
11738 (package
11739 (name "python-translation-finder")
11740 (version "2.22")
11741 (source
11742 (origin
11743 (method url-fetch)
11744 (uri (pypi-uri "translation_finder" version))
11745 (sha256
11746 (base32 "1hav99ccijvk2w8wpvba2pc7ba1z150vja2wvaimd069mc08pjd2"))))
11747 (build-system pyproject-build-system)
11748 (arguments
11749 (list
11750 #:test-flags
11751 ;; AssertionError: 31 != 30 : Mismatched count of results
11752 #~(list "--deselect=translation_finder/test_api.py::APITest::test_discover_file")))
11753 (native-inputs
11754 (list python-pytest
11755 python-setuptools))
11756 (propagated-inputs
11757 (list python-charset-normalizer
11758 python-ruamel.yaml
11759 python-weblate-language-data))
11760 (home-page "https://weblate.org/")
11761 (synopsis "Translation file finder for Weblate")
11762 (description "This package provides a function to find translation file in
11763the source code of a project. It supports many translation file formats and
11764is part of the Weblate translation platform.")
11765 (license license:gpl3+)))
11766
11767(define-public python-gitlab
11768 (package
11769 (name "python-gitlab")
11770 (version "7.0.0")
11771 (source
11772 (origin
11773 (method git-fetch)
11774 (uri (git-reference
11775 (url "https://github.com/python-gitlab/python-gitlab")
11776 (commit (string-append "v" version))))
11777 (file-name (git-file-name name version))
11778 (sha256
11779 (base32 "0rf1hz5n724f8sfc7g3fzfz96jsv9y145pi6gc8qscsjq3z4vi37"))))
11780 (build-system pyproject-build-system)
11781 (arguments
11782 (list
11783 #:test-flags
11784 #~(list "--ignore=tests/unit/test_graphql.py"
11785 ;; XXX: Missing helper script.
11786 "-k" "not test_data_from_helper" "tests/unit")))
11787 (native-inputs
11788 (list python-anyio
11789 python-pytest
11790 python-responses
11791 python-setuptools))
11792 (propagated-inputs (list python-requests python-requests-toolbelt))
11793 (home-page "https://github.com/python-gitlab/python-gitlab")
11794 (synopsis "Interact with GitLab API")
11795 (description "This package provides an extended library for interacting
11796with GitLab instances through their API.")
11797 (license license:lgpl3+)))
11798
11799(define-public python-path-and-address
11800 (package
11801 (name "python-path-and-address")
11802 (version "2.0.1")
11803 (source
11804 (origin
11805 (method git-fetch)
11806 (uri (git-reference
11807 (url "https://github.com/joeyespo/path-and-address")
11808 (commit (string-append "v" version))))
11809 (file-name (git-file-name name version))
11810 (sha256
11811 (base32 "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6"))))
11812 (build-system pyproject-build-system)
11813 (native-inputs
11814 (list python-pytest python-setuptools))
11815 (home-page "https://github.com/joeyespo/path-and-address")
11816 (synopsis "Functions for command-line server tools used by humans")
11817 (description "Path-and-address resolves ambiguities of command-line
11818interfaces, inferring which argument is the path, and which is the address.")
11819 (license license:expat)))
11820
11821(define-public python-port-for
11822 (package
11823 (name "python-port-for")
11824 (version "0.7.4")
11825 (source
11826 (origin
11827 (method url-fetch)
11828 (uri (pypi-uri "port_for" version))
11829 (sha256
11830 (base32 "13826s2d4hzzmv69wws6a7ryhminclv2bqaw6cpl929gnbki6xzw"))))
11831 (build-system pyproject-build-system)
11832 (propagated-inputs
11833 (list python-urllib3))
11834 (native-inputs
11835 (list python-pytest python-setuptools python-wheel))
11836 (home-page "https://github.com/kmike/port-for/")
11837 (synopsis "TCP localhost port finder and association manager")
11838 (description
11839 "This package provides a utility that helps with local TCP ports
11840management. It can find an unused TCP localhost port and remember the
11841association.")
11842 (license license:expat)))
11843
11844(define-public python-livereload
11845 (package
11846 (name "python-livereload")
11847 (version "2.7.1")
11848 (source
11849 (origin
11850 (method git-fetch)
11851 (uri (git-reference
11852 (url "https://github.com/lepture/python-livereload")
11853 (commit (string-append "v" version))))
11854 (file-name (git-file-name name version))
11855 (sha256
11856 (base32 "19wkdd1grw6mcd4qi8iaw4jdr207h3m24951vgy69j7g904lynjq"))))
11857 (build-system pyproject-build-system)
11858 (arguments (list #:test-backend #~'unittest))
11859 (native-inputs (list python-django-minimal python-setuptools))
11860 (propagated-inputs (list python-tornado))
11861 (home-page "https://github.com/lepture/python-livereload")
11862 (synopsis "Python LiveReload")
11863 (description
11864 "Python LiveReload provides a command line utility, @command{livereload},
11865for starting a web server in a directory. It can trigger arbitrary commands
11866and serve updated contents upon changes to the directory.")
11867 (license license:bsd-3)))
11868
11869(define-public python-vf-1
11870 (package
11871 (name "python-vf-1")
11872 (version "1.0.0")
11873 (source
11874 (origin
11875 (method git-fetch)
11876 (uri (git-reference
11877 (url "https://git.sr.ht/~solderpunk/VF-1")
11878 (commit (string-append "v" version))))
11879 (file-name (git-file-name name version))
11880 (sha256
11881 (base32 "1j8l4xivm6rs8jms1ixx0i9fz4yxr84hbz1pdc498jgkgzy1v8ih"))))
11882 (build-system pyproject-build-system)
11883 (arguments (list #:tests? #f)) ; No tests.
11884 (native-inputs (list python-setuptools))
11885 (home-page "https://git.sr.ht/~solderpunk/VF-1")
11886 (synopsis "Command line gopher client")
11887 (description "@code{VF-1} is a command line gopher client with
11888@acronym{TLS, Transport Layer Security} support.")
11889 (license license:bsd-2)))
11890
11891(define-public python-httpcore
11892 (package
11893 (name "python-httpcore")
11894 (version "1.0.9")
11895 (source
11896 (origin
11897 ;; PyPI tarball does not contain tests.
11898 (method git-fetch)
11899 (uri (git-reference
11900 (url "https://github.com/encode/httpcore")
11901 (commit version)))
11902 (file-name (git-file-name name version))
11903 (sha256
11904 (base32 "0yhm2n8qflpwjsjggyj757m0gw3n68al0my0ljybndwp933ipl32"))))
11905 (build-system pyproject-build-system)
11906 (native-inputs
11907 (list nss-certs-for-test
11908 python-hatch-fancy-pypi-readme
11909 python-hatchling
11910 python-pytest
11911 python-pytest-asyncio
11912 python-pytest-httpbin
11913 python-pytest-trio
11914 python-uvicorn
11915 python-trustme))
11916 (propagated-inputs
11917 (list python-anyio
11918 python-certifi
11919 python-h11
11920 python-h2
11921 python-sniffio
11922 python-socksio
11923 python-trio
11924 python-trio-typing))
11925 (home-page "https://github.com/encode/httpcore")
11926 (synopsis "Minimal, low-level HTTP client")
11927 (description
11928 "HTTP Core provides a minimal and low-level HTTP client, which does one
11929thing only: send HTTP requests.
11930
11931Some things HTTP Core does do:
11932
11933@itemize
11934@item Sending HTTP requests.
11935@item Provides both sync and async interfaces.
11936@item Supports HTTP/1.1 and HTTP/2.
11937@item Async backend support for asyncio and trio.
11938@item Automatic connection pooling.
11939@item HTTP(S) proxy support.
11940@end itemize")
11941 (license license:bsd-3)))
11942
11943;;; Variant used to break a cycle between python-httpx and python-uvicorn.
11944(define-public python-httpcore-bootstrap
11945 (hidden-package
11946 (package/inherit python-httpcore
11947 (name "python-httpcore-bootstrap")
11948 (arguments (list #:tests? #f))
11949 (native-inputs (list python-hatchling
11950 python-hatch-fancy-pypi-readme)))))
11951
11952(define-public python-httpx
11953 (package
11954 (name "python-httpx")
11955 (version "0.28.1")
11956 (source
11957 (origin
11958 ;; PyPI tarball does not contain tests.
11959 (method git-fetch)
11960 (uri (git-reference
11961 (url "https://github.com/encode/httpx")
11962 (commit version)))
11963 (file-name (git-file-name name version))
11964 (sha256
11965 (base32 "00d6rb21xwazwb0sj68zhra0qxxcwkd0vv7bg3k1jg94dmk2w7xl"))))
11966 (build-system pyproject-build-system)
11967 (arguments
11968 (list
11969 ;; 1401 passed, 1 skipped, 5 deselected
11970 #:test-flags
11971 #~(list "-o" "asyncio_mode=auto"
11972 ;; CLI tests are broken.
11973 "--ignore=tests/test_main.py"
11974 "-k" (string-join
11975 ;; These tests try to open an outgoing connection.
11976 (list "not test_async_proxy_close"
11977 "test_sync_proxy_clos"
11978 "test_write_timeout")
11979 " and not "))))
11980 (native-inputs
11981 (list nss-certs-for-test
11982 python-chardet
11983 python-cryptography
11984 python-hatch-fancy-pypi-readme
11985 python-hatchling
11986 python-pytest
11987 python-pytest-asyncio
11988 python-pytest-trio
11989 python-setuptools
11990 python-trio
11991 python-trustme
11992 python-uvicorn))
11993 (propagated-inputs
11994 (list python-anyio
11995 python-certifi
11996 python-httpcore
11997 python-idna
11998 ;; [brotli]
11999 python-brotli
12000 ;; [http2]
12001 python-h2
12002 ;; [socks]
12003 python-socksio
12004 ;; [zstd]
12005 python-zstandard
12006 ;; For trio, see:
12007 ;; <https://github.com/python-trio/trio/issues/2802>.
12008 python-sniffio))
12009 (home-page "https://www.python-httpx.org/")
12010 (synopsis "HTTP client for Python")
12011 (description
12012 "HTTPX is a fully featured HTTP client for Python 3, which provides sync
12013and async APIs, and support for both HTTP/1.1 and HTTP/2.
12014
12015HTTPX builds on the well-established usability of requests, and gives you:
12016
12017@itemize
12018@item A broadly requests-compatible API.
12019@item Standard synchronous interface, but with async support if you need it.
12020@item HTTP/1.1 and HTTP/2 support.
12021@item Ability to make requests directly to WSGI applications or ASGI applications.
12022@item Strict timeouts everywhere.
12023@item Fully type annotated.
12024@item 99% test coverage.
12025@end itemize
12026
12027Plus all the standard features of requests:
12028
12029@itemize
12030@item International Domains and URLs
12031@item Keep-Alive & Connection Pooling
12032@item Sessions with Cookie Persistence
12033@item Browser-style SSL Verification
12034@item Basic/Digest Authentication
12035@item Elegant Key/Value Cookies
12036@item Automatic Decompression
12037@item Automatic Content Decoding
12038@item Unicode Response Bodies
12039@item Multipart File Uploads
12040@item HTTP(S) Proxy Support
12041@item Connection Timeouts
12042@item Streaming Downloads
12043@item .netrc Support
12044@item Chunked Requests
12045@end itemize")
12046 (license license:bsd-3)))
12047
12048;;; Variant used to break a cycle with python-uvicorn.
12049(define-public python-httpx-bootstrap
12050 (hidden-package
12051 (package/inherit python-httpx
12052 (name "python-httpx-bootstrap")
12053 (arguments (list #:tests? #f))
12054 (native-inputs
12055 (list python-hatchling
12056 python-hatch-fancy-pypi-readme))
12057 (propagated-inputs
12058 (modify-inputs propagated-inputs
12059 (replace "python-httpcore" python-httpcore-bootstrap))))))
12060
12061(define-public python-httpx-sse
12062 (package
12063 (name "python-httpx-sse")
12064 (version "0.4.3")
12065 (source
12066 (origin
12067 (method git-fetch)
12068 (uri (git-reference
12069 (url "https://github.com/florimondmanca/httpx-sse")
12070 (commit version)))
12071 (file-name (git-file-name name version))
12072 (sha256
12073 (base32 "0zliqd1rkvc0mjppscvqmg8j17hsiwvxn439yhn6qbjvk5ydncz8"))))
12074 (build-system pyproject-build-system)
12075 (native-inputs
12076 (list python-pytest
12077 python-pytest-asyncio
12078 python-setuptools
12079 python-setuptools-scm
12080 python-sse-starlette))
12081 (propagated-inputs (list python-httpx))
12082 (home-page "https://github.com/florimondmanca/httpx-sse")
12083 (synopsis "Consume Server-Sent Event (SSE) messages with HTTPX.")
12084 (description "Consume Server-Sent Event (SSE) messages with HTTPX.")
12085 (license license:expat)))
12086
12087(define-public python-httpx-ws
12088 (package
12089 (name "python-httpx-ws")
12090 (version "0.9.0")
12091 (source
12092 (origin
12093 (method git-fetch)
12094 (uri (git-reference
12095 (url "https://github.com/frankie567/httpx-ws")
12096 (commit (string-append "v" version))))
12097 (file-name (git-file-name name version))
12098 (sha256
12099 (base32 "1hin6fndvfnx3mjgy30x0ghgjalikxavyj24klcknnly9sqzg83v"))))
12100 (build-system pyproject-build-system)
12101 (propagated-inputs
12102 (list python-anyio
12103 python-httpcore
12104 python-httpx
12105 python-wsproto))
12106 (native-inputs
12107 (list nss-certs-for-test
12108 python-hatch-regex-commit
12109 python-hatchling
12110 python-pytest
12111 python-pytest-cov
12112 python-starlette
12113 python-uvicorn))
12114 (home-page "https://github.com/frankie567/httpx-ws")
12115 (synopsis "WebSockets support for HTTPX")
12116 (description "This package provides @code{WebSockets} support for HTTPX.")
12117 (license license:expat)))
12118
12119(define-public python-wsgiprox
12120 (package
12121 (name "python-wsgiprox")
12122 (version "1.5.2")
12123 (source
12124 (origin
12125 (method url-fetch)
12126 (uri (pypi-uri "wsgiprox" version))
12127 (sha256
12128 (base32 "11fsm199pvwbmqx2lccznvws65aam1rqqv0w79gal8hispwgd5rs"))))
12129 (build-system pyproject-build-system)
12130 (arguments
12131 ;; The test suite hangs (see:
12132 ;; https://github.com/webrecorder/wsgiprox/issues/6).
12133 (list
12134 #:tests? #f
12135 #:phases
12136 #~(modify-phases %standard-phases
12137 (add-after 'unpack 'fix-pytest-argument
12138 (lambda _
12139 ;; See: https://github.com/webrecorder/wsgiprox/issues/7.
12140 (substitute* "setup.py"
12141 (("--doctest-module")
12142 "--doctest-modules")))))))
12143 (propagated-inputs
12144 (list python-certauth
12145 python-gevent
12146 python-six
12147 python-websocket-client))
12148 (native-inputs
12149 (list python-mock python-waitress python-setuptools))
12150 (home-page "https://github.com/webrecorder/wsgiprox")
12151 (synopsis "HTTP/S proxy with WebSockets over WSGI")
12152 (description
12153 "@code{wsgiprox} is a Python WSGI (Web Server Gateway Interface)
12154middle-ware for adding HTTP and HTTPS proxy support to a WSGI application.
12155The library accepts HTTP and HTTPS proxy connections, and routes them to a
12156designated prefix.")
12157 (license license:asl2.0)))
12158
12159(define-public python-warcio
12160 ;; The PyPI release is missing some test support files (see:
12161 ;; https://github.com/webrecorder/warcio/issues/132).
12162 (package
12163 (name "python-warcio")
12164 (version "1.8.1")
12165 (source
12166 (origin
12167 (method git-fetch)
12168 (uri (git-reference
12169 (url "https://github.com/webrecorder/warcio")
12170 (commit (string-append "v" version))))
12171 (file-name (git-file-name name version))
12172 (sha256
12173 (base32
12174 "19wwg7zmx33c942dbahdkng1byiwr4c9cd1ayrsh13f818n17zps"))))
12175 (build-system pyproject-build-system)
12176 (arguments
12177 (list
12178 #:test-flags ; These tests fail due to networking requirements.
12179 '(list "-k" (format #f "not ~a"
12180 (string-join
12181 '("test_post_chunked"
12182 "test_remote"
12183 "test_capture_http_proxy"
12184 "test_capture_https_proxy"
12185 "test_capture_https_proxy_same_session")
12186 " and not "))
12187 ; The following test requires the hookdns package.
12188 "--ignore=test/test_capture_http_proxy.py")))
12189 (native-inputs
12190 (list python-httpbin
12191 python-pytest
12192 python-requests
12193 python-setuptools
12194 python-wsgiprox))
12195 (home-page "https://github.com/webrecorder/warcio")
12196 (synopsis "Streaming web archival archive (WARC) library")
12197 (description "warcio is a Python library to read and write the WARC format
12198commonly used in Web archives. It is designed for fast, low-level access to
12199web archival content, oriented around a stream of WARC records rather than
12200files.")
12201 (license license:asl2.0)))
12202
12203(define-public python-websockets
12204 (package
12205 (name "python-websockets")
12206 (version "16.0")
12207 (source
12208 (origin
12209 (method git-fetch)
12210 (uri (git-reference
12211 (url "https://github.com/aaugustin/websockets")
12212 (commit version)))
12213 (file-name (git-file-name name version))
12214 (sha256
12215 (base32
12216 "1f71siwmjxn8b671x8lkkxx56q3xm99f2kmjqpzfcv3air9n94gg"))))
12217 (build-system pyproject-build-system)
12218 (arguments
12219 (list #:test-backend #~'unittest
12220 #:phases
12221 #~(modify-phases %standard-phases
12222 (add-before 'check 'extend-test-timeout
12223 (lambda _
12224 ;; Some architectures need an even longer timeout. Make it
12225 ;; long enough that it should never fail due to timeout.
12226 #$@(if (target-riscv64?)
12227 #~((setenv "WEBSOCKETS_TESTS_TIMEOUT_FACTOR" "100"))
12228 #~((setenv "WEBSOCKETS_TESTS_TIMEOUT_FACTOR" "10"))))))))
12229 (native-inputs
12230 (list python-setuptools))
12231 (home-page "https://github.com/aaugustin/websockets")
12232 (synopsis
12233 "Python implementation of the WebSocket Protocol (RFC 6455 & 7692)")
12234 (description
12235 "@code{websockets} is a library for building WebSocket servers and clients
12236in Python with a focus on correctness and simplicity.
12237
12238Built on top of @code{asyncio}, Python's standard asynchronous I/O framework,
12239it provides an elegant coroutine-based API.")
12240 (license license:bsd-3)))
12241
12242(define-public selenium-manager
12243 (package
12244 (name "selenium-manager")
12245 (version "4.34.2")
12246 (source
12247 (origin
12248 (method git-fetch)
12249 (uri (git-reference
12250 (url "https://github.com/SeleniumHQ/selenium")
12251 (commit (string-append "selenium-" version "-python"))))
12252 (file-name (git-file-name name version))
12253 (sha256
12254 (base32 "14fg8r4rm9d7169rlm29l5yn08wgllmqk1zc6six3dlrzzf5mxil"))))
12255 (build-system cargo-build-system)
12256 (arguments
12257 (list
12258 ;; XXX: Almost all tests require either browsers or network access.
12259 #:tests? #f
12260 #:install-source? #f ; Most likely intended as a leaf.
12261 #:phases
12262 #~(modify-phases %standard-phases
12263 (add-after 'unpack 'chdir
12264 (lambda _
12265 (chdir "rust"))))))
12266 (native-inputs (list pkg-config))
12267 (inputs (cons* (list zstd "lib") xz
12268 (cargo-inputs 'selenium-manager)))
12269 (home-page "https://www.selenium.dev")
12270 (synopsis "CLI tool to manager the browser test infrastructure")
12271 (description
12272 "Selenium simplifies web browser automation. It specifically provides
12273infrastructure for the W3C WebDriver specification — a platform and
12274language-neutral coding interface compatible with all major web browsers.
12275
12276Selenium Manager is a CLI tool that automatically manages the browser/driver
12277infrastructure required by Selenium.")
12278 (license license:asl2.0)))
12279
12280(define-public python-selenium
12281 (package/inherit selenium-manager
12282 (name "python-selenium")
12283 (build-system pyproject-build-system)
12284 (arguments
12285 (list
12286 ;; XXX: Disable failing tests.
12287 #:test-flags
12288 #~(list "--ignore-glob=test/selenium/webdriver/*"
12289 ;; Probably requires those.
12290 "--ignore-glob=test/unit/selenium/webdriver/chrome/*"
12291 "--ignore-glob=test/unit/selenium/webdriver/firefox/*"
12292 ;; XXX: SSL certificates access.
12293 "--ignore=test/unit/selenium/webdriver/remote/remote_connection_tests.py"
12294 "-k" "not test_missing_cdp_devtools_version_falls_back")
12295 #:phases
12296 #~(modify-phases %standard-phases
12297 (add-after 'unpack 'chdir
12298 (lambda _
12299 (chdir "py")))
12300 (add-after 'chdir 'inject-selenium-manager-binary
12301 (lambda* (#:key inputs #:allow-other-keys)
12302 (substitute* "selenium/webdriver/common/selenium_manager.py"
12303 (("compiled_path = Path.*")
12304 (format #f "return Path(~s)~%"
12305 (search-input-file inputs "bin/selenium-manager"))))
12306 (substitute* "pyproject.toml"
12307 (("\\[\\[tool\\.setuptools-rust\\.bins\\]\\]")
12308 "")
12309 (("target = \"selenium\\.webdriver\\.common.*\"")
12310 ""))))
12311 (add-after 'chdir 'relax-requirements
12312 (lambda _
12313 (substitute* "pyproject.toml"
12314 (("\"(typing_extensions|trio|urllib3.*)~=.*\"," _ target)
12315 (format #f "~s," target))))))))
12316 (propagated-inputs (list python-certifi
12317 python-trio
12318 python-trio-websocket
12319 python-typing-extensions
12320 python-urllib3
12321 python-websocket-client))
12322 (inputs (list selenium-manager))
12323 (native-inputs (list python-filetype
12324 python-pytest
12325 python-pytest-mock
12326 python-pytest-trio
12327 python-setuptools
12328 python-setuptools-rust))
12329 (synopsis "Python bindings for Selenium")
12330 (description
12331 "Selenium enables web browser automation. It specifically provides
12332infrastructure for the W3C WebDriver specification — a platform and
12333language-neutral coding interface compatible with all major web browsers.")))
12334
12335(define-public python-rapidjson
12336 (package
12337 (name "python-rapidjson")
12338 (version "1.23")
12339 (source
12340 (origin
12341 (method git-fetch)
12342 (uri (git-reference
12343 (url "https://github.com/python-rapidjson/python-rapidjson")
12344 (commit (string-append "v" version))))
12345 (file-name (git-file-name name version))
12346 (sha256
12347 (base32 "0ajf919gg3qmi68jb0m6v80al2n65cn2ac36qz46s0h6zh92cl86"))
12348 (modules '((guix build utils)))
12349 (snippet
12350 '(delete-file-recursively "rapidjson"))))
12351 (build-system pyproject-build-system)
12352 (arguments
12353 (list
12354 #:test-flags '(list "tests")
12355 #:phases
12356 #~(modify-phases %standard-phases
12357 ;; We cannot seem to use #:configure-flags with the
12358 ;; pyproject-build-system to override rj_include_dir.
12359 (add-after 'unpack 'override-rapidjson-sources
12360 (lambda _
12361 (substitute* "setup.py"
12362 (("^rj_include_dir =.*")
12363 (string-append "rj_include_dir = '"
12364 #$(this-package-native-input "rapidjson")
12365 "/include/rapidjson" "'"))
12366 (("if not os.path.isdir.*") "if False:")))))))
12367 (native-inputs
12368 (list rapidjson python-pytest python-pytz python-setuptools))
12369 (home-page "https://github.com/python-rapidjson/python-rapidjson")
12370 (synopsis "Python wrapper around rapidjson")
12371 (description "This package provides a python wrapper around rapidjson.")
12372 (license license:expat)))
12373
12374(define-public python-venusian
12375 (package
12376 (name "python-venusian")
12377 (version "3.1.1")
12378 (source
12379 (origin
12380 (method url-fetch)
12381 (uri (pypi-uri "venusian" version))
12382 (sha256
12383 (base32 "0h8cdwx5x6i1ydc9s0hxwvy73l6iwlqijn2l77mq74k6anrv6ksk"))))
12384 (build-system pyproject-build-system)
12385 (native-inputs
12386 (list python-pytest
12387 python-setuptools))
12388 (home-page "https://docs.pylonsproject.org/projects/venusian")
12389 (synopsis "Library for deferring decorator actions")
12390 (description
12391 "Venusian is a library which allows framework authors to defer decorator
12392actions. Instead of taking actions when a function (or class) decorator is
12393executed at import time, you can defer the action usually taken by the
12394decorator until a separate scan phase.")
12395 (license license:repoze)))
12396
12397(define-public python-zope-deprecation
12398 (package
12399 (name "python-zope-deprecation")
12400 (version "6.0")
12401 (source (origin
12402 (method url-fetch)
12403 (uri (pypi-uri "zope_deprecation" version))
12404 (sha256
12405 (base32
12406 "0pzimp7xr8m0836bbsrx8wa9ybl58s5hwacas95nsfp6m2ypwwhq"))))
12407 (build-system pyproject-build-system)
12408 (arguments
12409 (list #:tests? #f)) ;no tests in PyPI
12410 (native-inputs
12411 (list python-setuptools))
12412 (home-page "https://zopedeprecation.readthedocs.io/")
12413 (synopsis "Function for marking deprecations")
12414 (description "The @code{zope.deprecation} module provides a function for
12415marking modules, classes, functions, methods and properties as deprecated,
12416displaying warnings when usaged in application code.")
12417 (license license:zpl2.1)))
12418
12419(define-public python-translationstring
12420 (package
12421 (name "python-translationstring")
12422 (version "1.4")
12423 (source (origin
12424 (method url-fetch)
12425 (uri (pypi-uri "translationstring" version))
12426 (sha256
12427 (base32
12428 "1wvncdzi1wj37x226qcf0yycz7js6l83na0pmc9blsbfsww7b55z"))))
12429 (build-system pyproject-build-system)
12430 (native-inputs
12431 (list python-pytest
12432 python-setuptools))
12433 (home-page "https://docs.pylonsproject.org/projects/translationstring")
12434 (synopsis "Internationalization tooling for the Pylons project")
12435 (description "This package provides a library used by various Pylons
12436project packages for internationalization (i18n) duties related to
12437translation.")
12438 (license license:repoze)))
12439
12440(define-public python-plaster
12441 (package
12442 (name "python-plaster")
12443 (version "1.1.2")
12444 (source (origin
12445 (method url-fetch)
12446 (uri (pypi-uri "plaster" version))
12447 (sha256
12448 (base32
12449 "167gfh0ahdll9m96ypgasji6yry2hkn9f0ml1b0lf4ccpxagrgpq"))))
12450 (build-system pyproject-build-system)
12451 (native-inputs
12452 (list python-pytest
12453 python-setuptools))
12454 (home-page "https://docs.pylonsproject.org/projects/plaster/en/latest/")
12455 (synopsis "Configuration loader for multiple config file formats")
12456 (description
12457 "Plaster is a loader interface around multiple config file formats. It
12458exists to define a common API for applications to use when they wish to load
12459configuration. The library itself does not aim to handle anything except a
12460basic API that applications may use to find and load configuration settings.
12461Any specific constraints should be implemented in a pluggable loader which can
12462be registered via an entrypoint.")
12463 (license license:repoze)))
12464
12465(define-public python-plaster-pastedeploy
12466 (package
12467 (name "python-plaster-pastedeploy")
12468 (version "1.0.1")
12469 (source (origin
12470 (method url-fetch)
12471 (uri (pypi-uri "plaster_pastedeploy" version))
12472 (sha256
12473 (base32
12474 "04hl71p76wnwiy195p5w51bn3c6ba0lgx8nsfm42d9s15rnjw9my"))))
12475 (build-system pyproject-build-system)
12476 (native-inputs
12477 (list python-pytest
12478 python-setuptools))
12479 (propagated-inputs
12480 (list python-plaster python-pastedeploy))
12481 (home-page "https://github.com/Pylons/plaster_pastedeploy")
12482 (synopsis "Plugin for python-plaster adding PasteDeploy syntax")
12483 (description
12484 "This plugin for @code{python-plaster} adds support for PasteDeploy
12485syntax, it provides a plaster @code{Loader} object that can parse ini files
12486according to the standard set by PasteDeploy")
12487 (license license:expat)))
12488
12489(define-public python-hupper
12490 (package
12491 (name "python-hupper")
12492 (version "1.12.1")
12493 (source
12494 (origin
12495 (method url-fetch)
12496 (uri (pypi-uri "hupper" version))
12497 (sha256
12498 (base32 "1srj7sqxdgxr0nnhh9lw8jmp64chwgg8iwfm9b4g9v7l1wbm9gq6"))))
12499 (build-system pyproject-build-system)
12500 (arguments
12501 (list
12502 ;; RuntimeError: timeout waiting for change to
12503 ;; file=/tmp/guix-build-python-hupper-1.12.1.drv-0/tmpm9n4697p
12504 #:test-flags #~(list "--ignore=tests/test_it.py")))
12505 (native-inputs
12506 (list python-pytest python-setuptools python-wheel))
12507 (propagated-inputs
12508 (list python-watchdog))
12509 (home-page "https://readthedocs.org/projects/hupper")
12510 (synopsis "Integrated process monitor tracking changes to imported Python files")
12511 (description
12512 "Hupper is an integrated process monitor that will track changes to any
12513imported Python files in sys.modules as well as custom paths. When files are
12514changed the process is restarted.")
12515 (license license:expat)))
12516
12517(define-public python-pyowm
12518 (package
12519 (name "python-pyowm")
12520 (version "3.3.0")
12521 (source
12522 (origin
12523 (method git-fetch)
12524 (uri (git-reference
12525 (url "https://github.com/csparpa/pyowm")
12526 (commit version)))
12527 (file-name (git-file-name name version))
12528 (sha256
12529 (base32
12530 "1ha4pp96y3jk33qnyir5851cnj4dc06q6wqn1b0w54l3fsds28vi"))))
12531 (build-system pyproject-build-system)
12532 (arguments (list #:test-flags #~(list "tests/unit")))
12533 (native-inputs (list python-pytest python-setuptools python-wheel))
12534 (propagated-inputs
12535 (list python-geojson-for-pyowm
12536 python-pysocks
12537 python-requests))
12538 (home-page "https://github.com/csparpa/pyowm")
12539 (synopsis "Python wrapper around OpenWeatherMap web APIs")
12540 (description
12541 "This package provides a Python wrapper around OpenWeatherMap web APIs.")
12542 (license license:expat)))
12543
12544(define-public python-pyramid
12545 (package
12546 (name "python-pyramid")
12547 (version "2.1")
12548 (source
12549 (origin
12550 (method git-fetch)
12551 (uri (git-reference
12552 (url "https://github.com/Pylons/pyramid")
12553 (commit version)))
12554 (file-name (git-file-name name version))
12555 (sha256
12556 (base32 "0my03b81009w9zqx5cdn9qixh0jah49hr0379n98kx2j3b8cfk1p"))))
12557 (build-system pyproject-build-system)
12558 (native-inputs
12559 (list python-pytest
12560 python-setuptools
12561 python-webtest
12562 python-zope-component))
12563 (propagated-inputs
12564 (list python-hupper
12565 python-plaster
12566 python-plaster-pastedeploy
12567 python-translationstring
12568 python-venusian
12569 python-webob
12570 python-zope-deprecation
12571 python-zope-interface))
12572 (home-page "https://trypyramid.com/")
12573 (synopsis "Python web-framework suitable for small and large sites")
12574 (description
12575 "Pyramid makes it easy to write web applications. From minimal
12576request/response web apps to larger, grown applications.")
12577 (license license:repoze)))
12578
12579(define-public python-pyramid-chameleon
12580 ;; PyPI lacks a fresh release, use the latest commit associated with
12581 ;; unrleased version, see:
12582 ;; <https://github.com/Pylons/pyramid_chameleon/issues/27>
12583 (let ((commit "956c77ba37120c430e871c834d3cd4ed5ac8dccf")
12584 (revision "0"))
12585 (package
12586 (name "python-pyramid-chameleon")
12587 (version (git-version "0.4.dev0" revision commit))
12588 (source
12589 (origin
12590 (method git-fetch)
12591 (uri (git-reference
12592 (url "https://github.com/Pylons/pyramid_chameleon")
12593 (commit commit)))
12594 (file-name (git-file-name name version))
12595 (sha256
12596 (base32 "0rsb921xi7736h1xikc904bq2zzmrj1g8qgyimjw5wxdcd8927b1"))))
12597 (build-system pyproject-build-system)
12598 (native-inputs
12599 (list python-pytest
12600 python-setuptools))
12601 (propagated-inputs
12602 (list python-chameleon
12603 python-pyramid))
12604 (home-page "https://github.com/Pylons/pyramid_chameleon")
12605 (synopsis "Chameleon template compiler for pyramid")
12606 (description
12607 "These package provides bindings for the Chameleon templating system
12608 for the Pyramid web framework.")
12609 (license license:repoze))))
12610
12611(define-public python-pyramid-debugtoolbar
12612 (package
12613 (name "python-pyramid-debugtoolbar")
12614 (version "4.12.1")
12615 (source
12616 (origin
12617 (method git-fetch)
12618 (uri (git-reference
12619 (url "https://github.com/Pylons/pyramid_debugtoolbar")
12620 (commit version)))
12621 (file-name (git-file-name name version))
12622 (sha256
12623 (base32 "0kalb5rsrlcz62zv9a39kp28mvwg9j6gymvzxbybdnvk51v9if56"))))
12624 (build-system pyproject-build-system)
12625 (arguments
12626 (list
12627 #:test-flags
12628 ;; Large diff assertion not equal faileurs.
12629 #~(list #$@(map (lambda (test)
12630 (string-append "--deselect=tests"
12631 "/test_panels/test_sqla.py::" test))
12632 (list "TestSimpleSelect::test_panel"
12633 "TestTransactionCommit::test_panel"
12634 "TestTransactionRollback::test_panel")))))
12635 (native-inputs
12636 (list python-pytest
12637 python-setuptools
12638 python-webtest))
12639 (propagated-inputs
12640 (list python-pyramid
12641 python-pyramid-chameleon
12642 python-pyramid-jinja2
12643 python-pyramid-mako
12644 python-selenium
12645 python-sqlalchemy
12646 python-waitress))
12647 (home-page "https://github.com/Pylons/pyramid_debugtoolbar")
12648 (synopsis "Pyramid debug toolbar")
12649 (description
12650 "This package provides an interactive HTML debugger for Pyramid
12651application development.")
12652 (license license:bsd-3)))
12653
12654(define-public python-pyramid-jinja2
12655 (package
12656 (name "python-pyramid-jinja2")
12657 (version "2.10.1")
12658 (source
12659 (origin
12660 (method url-fetch)
12661 (uri (pypi-uri "pyramid_jinja2" version))
12662 (sha256
12663 (base32 "0xqnqbqhx9bkrg2ic3blflsk8xc8kh7i2dm2kha9apqkbjrqql4c"))))
12664 (build-system pyproject-build-system)
12665 (arguments
12666 (list
12667 #:test-flags
12668 ;; Two tests failed with assertion not equal.
12669 #~(list "-k" "not test_it_relative_to_package and not test_options")))
12670 (native-inputs
12671 (list python-pytest
12672 python-setuptools
12673 python-webtest))
12674 (propagated-inputs
12675 (list python-jinja2
12676 python-markupsafe
12677 python-pyramid
12678 python-zope-deprecation))
12679 (home-page "https://github.com/Pylons/pyramid_jinja2")
12680 (synopsis "Jinja2 template bindings for the Pyramid web framework")
12681 (description "This package provides Jinja2 template bindings for the
12682Pyramid web framework.")
12683 (license license:repoze)))
12684
12685(define-public python-pyramid-mako
12686 ;; 1.1.0 was released in 2019, there a lot of compatibility changes on
12687 ;; master, us the latest commit for now.
12688 (let ((commit "1a6f4c00c7134530d2975f34d904b64a41b28b21")
12689 (revision "0"))
12690 (package
12691 (name "python-pyramid-mako")
12692 (version (git-version "1.1.0" revision commit))
12693 (source
12694 (origin
12695 (method git-fetch)
12696 (uri (git-reference
12697 (url "https://github.com/Pylons/pyramid_mako")
12698 (commit commit)))
12699 (file-name (git-file-name name version))
12700 (sha256
12701 (base32 "0v0571z2gby4apsalkdk83gs0d5mw79d56518h3bwwxzbq32kkns"))))
12702 (build-system pyproject-build-system)
12703 (native-inputs
12704 (list python-pytest
12705 python-setuptools))
12706 (propagated-inputs
12707 (list python-mako
12708 python-pyramid))
12709 (home-page "https://github.com/Pylons/pyramid_mako")
12710 (synopsis "Mako template bindings for the Pyramid web framework")
12711 (description
12712 "This package provides Mako template bindings for the Pyramid web
12713framework.")
12714 (license license:repoze))))
12715
12716(define-public python-pyramid-retry
12717 (package
12718 (name "python-pyramid-retry")
12719 (version "2.1.1")
12720 (source
12721 (origin
12722 (method url-fetch)
12723 (uri (pypi-uri "pyramid_retry" version))
12724 (sha256
12725 (base32 "1jf07v6zhli0abgm2qajzfwg68bl9zy4xygjwl4svawbwrm2ga5s"))))
12726 (build-system pyproject-build-system)
12727 (native-inputs
12728 (list python-pytest
12729 python-setuptools
12730 python-webtest))
12731 (propagated-inputs
12732 (list python-pyramid
12733 python-zope-interface))
12734 (home-page "https://github.com/Pylons/pyramid_retry")
12735 (synopsis "Pyramid execution policy supporting retrying failed requests")
12736 (description
12737 "@code{pyramid_retry} is an execution policy for Pyramid that wraps requests
12738and can retry them a configurable number of times under certain \"retryable\"
12739error conditions before indicating a failure to the client.")
12740 (license license:expat)))
12741
12742(define-public python-pyramid-tm
12743 (package
12744 (name "python-pyramid-tm")
12745 (version "2.6")
12746 (source
12747 (origin
12748 (method url-fetch)
12749 (uri (pypi-uri "pyramid_tm" version))
12750 (sha256
12751 (base32 "173hg16hldfh5n3mn482xx64nldk308dzri31jd0qa4528cx4j41"))))
12752 (build-system pyproject-build-system)
12753 (native-inputs
12754 (list python-pytest
12755 python-setuptools
12756 python-webtest))
12757 (propagated-inputs
12758 (list python-pyramid
12759 python-transaction))
12760 (home-page "https://github.com/Pylons/pyramid_tm")
12761 (synopsis "Centralized transaction management for Pyramid")
12762 (description
12763 "@code{pyramid_tm} is a package which allows Pyramid requests to join the
12764active @url{https://pypi.org/project/transaction/, transaction} as provided by
12765the Python transaction package.")
12766 (license license:repoze)))
12767
12768(define-public python-random-user-agent
12769 (package
12770 (name "python-random-user-agent")
12771 (version "1.0.1")
12772 (source
12773 (origin
12774 (method url-fetch)
12775 (uri (pypi-uri "random_user_agent" version))
12776 (sha256
12777 (base32 "04nhzdh2ki7ybhjrmghxci6hcm6i03vvin2q2ynj87fbr1pa534g"))))
12778 (build-system pyproject-build-system)
12779 (arguments (list #:tests? #f)) ; No tests.
12780 (native-inputs (list python-setuptools))
12781 (home-page "https://github.com/Luqman-Ud-Din/random_user_agent")
12782 (synopsis "List of user agents")
12783 (description
12784 "This package provides a list of user agents, from a collection of more
12785than 326,000 known user-agents. Users can pick a random one, or select one
12786based on filters.")
12787 (license license:expat)))
12788
12789(define-public python-rangehttpserver
12790 (package
12791 (name "python-rangehttpserver")
12792 (version "1.4.0")
12793 (source
12794 (origin
12795 (method git-fetch)
12796 (uri (git-reference
12797 (url "https://github.com/danvk/RangeHTTPServer")
12798 (commit version)))
12799 (file-name (git-file-name name version))
12800 (sha256
12801 (base32 "1dx533fsbq1mbz3by7qkm5bh2c253nwvm8214pqbwbfq07kqkwf2"))))
12802 (build-system pyproject-build-system)
12803 (native-inputs
12804 (list python-pytest
12805 python-requests
12806 python-setuptools))
12807 (home-page "https://github.com/danvk/RangeHTTPServer")
12808 (synopsis "SimpleHTTPServer with support for range requests")
12809 (description
12810 "This tool provides a simple HTTP server with support for Range
12811requests.")
12812 (license license:asl2.0)))
12813
12814(define-public python-flask-restx
12815 (package
12816 (name "python-flask-restx")
12817 (version "1.3.0")
12818 (source
12819 (origin
12820 (method git-fetch) ;no tests in PyPI archive
12821 (uri (git-reference
12822 (url "https://github.com/python-restx/flask-restx")
12823 (commit version)))
12824 (file-name (git-file-name name version))
12825 (sha256
12826 (base32 "1qmm3i1cdv0bvzsc1gn4ql2dsf1fbx85fk69vcmzpsdxzczmw508"))))
12827 (build-system pyproject-build-system)
12828 (arguments
12829 (list
12830 ;; 1214 passed, 6 skipped, 16 deselected, 3 warnings
12831 #:test-flags
12832 #~(list "--benchmark-skip"
12833 ;; ValueError: http://www.google.com is not a valid URL. Domain
12834 ;; does not exists.
12835 "--deselect=tests/test_inputs.py::URLTest::test_check"
12836 "-k" (string-join
12837 ;; See: <https://github.com/python-restx/flask-restx/issues/620>.
12838 (list "not test_rfc822_value"
12839 "test_iso8601_value"
12840 ;; assert 404 == 2000
12841 "test_specs_endpoint_host_and_subdomain"
12842 ;; ValueError: [email protected] is not a valid email
12843 "test_valid_value_check")
12844 " and not "))))
12845 (native-inputs
12846 (list python-blinker
12847 python-faker
12848 python-pytest
12849 python-pytest-benchmark
12850 python-pytest-flask
12851 python-pytest-mock
12852 python-setuptools))
12853 (propagated-inputs
12854 (list python-aniso8601
12855 python-flask
12856 python-importlib-resources
12857 python-jsonschema
12858 python-pytz
12859 python-werkzeug))
12860 (home-page "https://github.com/python-restx/flask-restx")
12861 (synopsis
12862 "Framework for fast, easy and documented API development with Flask")
12863 (description
12864 "Flask-RESTX is an extension for Flask that adds support for quickly building
12865REST APIs. Flask-RESTX encourages best practices with minimal setup. If you are familiar
12866 with Flask, Flask-RESTX should be easy to pick up. It provides a coherent collection of
12867decorators and tools to describe your API and expose its documentation properly using
12868Swagger.")
12869 (license license:bsd-3)))
12870
12871(define-public python-flask-socketio
12872 (package
12873 (name "python-flask-socketio")
12874 (version "5.6.1")
12875 (source
12876 (origin
12877 (method git-fetch)
12878 (uri (git-reference
12879 (url "https://github.com/miguelgrinberg/Flask-SocketIO/")
12880 (commit (string-append "v" version))))
12881 (file-name (git-file-name name version))
12882 (sha256
12883 (base32 "1bs594bxggwn78yhf86whv6bcs8gb7mhrm5dnk5x4c3jb20nhfmm"))))
12884 (build-system pyproject-build-system)
12885 (native-inputs
12886 (list python-pytest
12887 python-redis
12888 python-setuptools))
12889 (propagated-inputs
12890 (list python-flask
12891 python-socketio))
12892 (home-page "https://github.com/miguelgrinberg/Flask-SocketIO/")
12893 (synopsis "Socket.IO integration for Flask applications")
12894 (description "Socket.IO integration for Flask applications")
12895 (license license:expat)))
12896
12897(define-public python-manuel
12898 (package
12899 (name "python-manuel")
12900 (version "1.13.0")
12901 (source
12902 (origin
12903 (method url-fetch)
12904 (uri (pypi-uri "manuel" version))
12905 (sha256
12906 (base32 "0nl8psji3fizbxw34gdg22dndlg9lf5f56mnh1vr4vgsx06i4qsx"))))
12907 (build-system pyproject-build-system)
12908 (arguments
12909 (list
12910 ;; FIXME: Tests are broken, see: <https://github.com/benji-york/manuel/pull/32>.
12911 #:tests? #f))
12912 (propagated-inputs
12913 (list python-setuptools)) ;install requires
12914 (home-page "https://pypi.org/project/manuel/")
12915 (synopsis "Build tested documentation")
12916 (description
12917 "Manuel lets you mix and match traditional doctests with custom test syntax.")
12918 (license license:asl2.0)))
12919
12920(define-public python-marshmallow-jsonapi
12921 (package
12922 (name "python-marshmallow-jsonapi")
12923 (version "0.26.0")
12924 (source
12925 (origin
12926 (method git-fetch)
12927 (uri (git-reference
12928 ;; XXX: Deprecated upstream: This repository has been archived
12929 ;; by the owner on Jun 6, 2024. It is now read-only.
12930 ;; Using a maintained fork. The pypi name of this fork
12931 ;; is marshmallow-jsonapi-minfork.
12932 (url "https://github.com/tadams42/marshmallow-jsonapi")
12933 (commit version)))
12934 (file-name (git-file-name name version))
12935 (sha256
12936 (base32 "07sizh4m03rrk1139ci3psh5npk42cdsdfsdp574pz1fd5ncrq91"))))
12937 (build-system pyproject-build-system)
12938 (native-inputs
12939 (list python-faker
12940 python-flask
12941 python-pytest
12942 python-setuptools))
12943 (propagated-inputs (list python-marshmallow))
12944 (home-page "https://github.com/marshmallow-code/marshmallow-jsonapi")
12945 (synopsis "JSON:API 1.0 formatting with Marshmallow")
12946 (description
12947 "The marshmallow-jsonapi package provides a simple way to produce
12948@uref{https://jsonapi.org, JSON:API}-compliant data in any Python Web
12949framework. It includes optional utilities to integrate with Flask. This is a
12950forked version whose pypi name is @code{marshmallow_jsonapi_minfork}.")
12951 (license license:expat)))
12952
12953(define-public python-pecan
12954 (package
12955 (name "python-pecan")
12956 (version "1.8.0")
12957 (source
12958 (origin
12959 (method git-fetch)
12960 (uri (git-reference
12961 (url "https://github.com/pecan/pecan")
12962 (commit version)))
12963 (file-name (git-file-name name version))
12964 (sha256
12965 (base32 "0w693jpnjy358992f3jrrlf31knkqn0jvz2jx0iz7ziikprc61p8"))))
12966 (build-system pyproject-build-system)
12967 (arguments
12968 (list
12969 #:test-flags '(list "--pyargs" "pecan")))
12970 (native-inputs
12971 (list gunicorn
12972 python-genshi
12973 python-jinja2
12974 python-pytest
12975 python-sqlalchemy-2
12976 python-webtest))
12977 (propagated-inputs
12978 (list python-mako
12979 python-webob))
12980 (home-page "http://github.com/pecan/pecan")
12981 (synopsis "WSGI object-dispatching web framework")
12982 (description "This package provides a WSGI object-dispatching web
12983framework, designed to be lean and fast, with few dependencies.")
12984 (license license:bsd-3)))
12985
12986(define-public python-persistent
12987 (package
12988 (name "python-persistent")
12989 (version "6.1.1")
12990 (source
12991 (origin
12992 (method git-fetch)
12993 (uri (git-reference
12994 (url "https://github.com/zopefoundation/persistent/")
12995 (commit version)))
12996 (file-name (git-file-name name version))
12997 (sha256
12998 (base32 "19qwqg49zql2c8l4vjxjb9haw0bzd6lk8p4v3hip2irch6a4578a"))))
12999 (build-system pyproject-build-system)
13000 (arguments
13001 (list
13002 #:phases
13003 #~(modify-phases %standard-phases
13004 (replace 'check
13005 (lambda* (#:key tests? #:allow-other-keys)
13006 (if tests?
13007 (invoke "zope-testrunner" "--test-path=src"
13008 ;; XXX: Ignore doc tests.
13009 "!persistent.tests.test_docs")
13010 (format #t "test suite not run~%")))))))
13011 (propagated-inputs
13012 (list python-cffi
13013 python-zope-deferredimport
13014 python-zope-interface
13015 python-zope-testrunner))
13016 (native-inputs
13017 (list python-manuel python-zope-testrunner python-setuptools))
13018 (home-page "https://github.com/zopefoundation/persistent/")
13019 (synopsis "Translucent persistent objects")
13020 (description
13021 "This package contains a generic persistence implementation for Python.
13022It forms the core protocol for making objects interact \"transparently\" with
13023a database such as the ZODB.")
13024 (license license:zpl2.1)))
13025
13026(define-public python-transaction
13027 (package
13028 (name "python-transaction")
13029 (version "5.0")
13030 (source
13031 (origin
13032 (method url-fetch)
13033 (uri (pypi-uri "transaction" version))
13034 (sha256
13035 (base32 "0x0i5graxb93aa8bwf5rmm9zq7d7r6q2b4pw358wph5whbbpnvhh"))))
13036 (build-system pyproject-build-system)
13037 (native-inputs
13038 (list python-pytest
13039 python-setuptools))
13040 (propagated-inputs
13041 (list python-zope-interface))
13042 (home-page "https://github.com/zopefoundation/transaction")
13043 (synopsis "Transaction management for Python")
13044 (description "This package contains a generic transaction implementation
13045for Python. It is mainly used by the ZODB.")
13046 (license license:zpl2.1)))
13047
13048(define-public python-truststore
13049 (package
13050 (name "python-truststore")
13051 (version "0.10.4")
13052 (source
13053 (origin
13054 (method url-fetch)
13055 (uri (pypi-uri "truststore" version))
13056 (sha256
13057 (base32 "00f3xc7720rkddsn291yrw871kfnimi6d9xbwi75xbb3ci1vv4cx"))))
13058 (build-system pyproject-build-system)
13059 (arguments
13060 (list #:tests? #f)) ;all tests require Internet access
13061 (native-inputs
13062 (list python-flit-core))
13063 (home-page "https://github.com/sethmlarson/truststore")
13064 (synopsis "Verify certificates using native system trust stores")
13065 (description
13066 "Truststore is a library which exposes native system certificate stores (ie
13067\"trust stores\") through an @code{ssl.SSLContext-like} API. This means that
13068Python applications no longer need to rely on certifi as a root certificate
13069store.")
13070 (license license:expat)))
13071
13072(define-public python-robot-detection
13073 (package
13074 (name "python-robot-detection")
13075 (version "0.4.0")
13076 (source
13077 (origin
13078 (method git-fetch)
13079 (uri (git-reference
13080 (url "https://github.com/rory/robot-detection")
13081 (commit (string-append "v" version))))
13082 (file-name (git-file-name name version))
13083 (sha256
13084 (base32 "1gxk13rn0gw5pfc4abhfnzg8qi05xa0ygs26pgkp0swygkzq6wsq"))))
13085 (build-system pyproject-build-system)
13086 (arguments (list #:test-backend #~'unittest))
13087 (native-inputs (list python-setuptools))
13088 (propagated-inputs (list python-six))
13089 (home-page "https://github.com/rory/robot-detection")
13090 (synopsis "Detect web crawlers")
13091 (description
13092 "@code{robot_detection} is a python module to detect if a given HTTP User
13093Agent is a web crawler. It uses the list of registered robots from
13094@url{http://www.robotstxt.org}.")
13095 (license license:gpl3+)))
13096
13097(define-public python-robotframework-requests
13098 (package
13099 (name "python-robotframework-requests")
13100 (version "0.9.7")
13101 (source
13102 (origin
13103 (method git-fetch) ; no tests in PyPI release
13104 (uri (git-reference
13105 (url "https://github.com/MarketSquare/robotframework-requests")
13106 (commit (string-append "v" version))))
13107 (file-name (git-file-name name version))
13108 (sha256
13109 (base32 "077j8p5k41v53slyv8h32fcmqfi7m6z3r4gmyqqaawm5szfmy61m"))))
13110 (build-system pyproject-build-system)
13111 (native-inputs
13112 (list python-pytest
13113 python-setuptools
13114 python-wheel))
13115 (propagated-inputs
13116 (list python-requests
13117 python-robotframework))
13118 (home-page "https://github.com/MarketSquare/robotframework-requests")
13119 (synopsis "Robot Framework keyword library wrapper around requests")
13120 (description
13121 "@code{RequestsLibrary} is a @url{https://robotframework.org/, Robot
13122Framework} library aimed to provide HTTP API testing functionalities by
13123wrapping the @code{requests} Python library.")
13124 (license license:expat)))
13125
13126(define-public python-pysolr
13127 (package
13128 (name "python-pysolr")
13129 (version "3.10.0")
13130 (source
13131 (origin
13132 (method url-fetch)
13133 (uri (pypi-uri "pysolr" version))
13134 (sha256
13135 (base32 "02gl1sma5cnpd7srpri1g68lpsg3s5n3lr462p5ll8v9s4nllyqj"))))
13136 (build-system pyproject-build-system)
13137 (arguments
13138 '(#:tests? #f)) ; Tests require network access.
13139 (native-inputs
13140 (list python-setuptools
13141 python-setuptools-scm
13142 python-wheel))
13143 (propagated-inputs
13144 (list python-requests))
13145 (home-page "https://github.com/django-haystack/pysolr/")
13146 (synopsis "Lightweight python wrapper for Apache Solr")
13147 (description
13148 "This module provides an interface that queries the Apache Solr server
13149using a pure Python implementation.")
13150 (license license:bsd-3)))
13151
13152(define-public python-pyjsparser
13153 ;; XXX: This project is potentially abandonware, consider to remove in next
13154 ;; refresh cycle, see:
13155 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/28>,
13156 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/39>, and
13157 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/40>.
13158 (package
13159 (name "python-pyjsparser")
13160 (version "2.7.1")
13161 (source
13162 (origin
13163 (method url-fetch)
13164 (uri (pypi-uri "pyjsparser" version))
13165 (sha256
13166 (base32 "0ycmf9fsvwliqmm1n6sfz7x71y7i2kbfgn39d8lsbiccfxmxlq5y"))))
13167 (build-system pyproject-build-system)
13168 (arguments
13169 '(#:tests? #f)) ;no tests in PyPI
13170 (native-inputs (list python-setuptools))
13171 (home-page "https://github.com/PiotrDabkowski/pyjsparser")
13172 (synopsis "Fast JavaScript parser")
13173 (description
13174 "This package provides a fast JavaScript parser (based on esprima.js)")
13175 (license license:expat)))
13176
13177(define-public python-js2py
13178 (package
13179 (name "python-js2py")
13180 (properties '((commit . "2e017b86e2f18a6c8a842293b1687f2ce7baa12e")
13181 (revision . "0")))
13182 (version (git-version "0.74"
13183 (assoc-ref properties 'revision)
13184 (assoc-ref properties 'commit)))
13185 (source
13186 (origin
13187 (method git-fetch)
13188 (uri (git-reference
13189 (url "https://github.com/PiotrDabkowski/Js2Py")
13190 (commit (assoc-ref properties 'commit))))
13191 (file-name (git-file-name name version))
13192 (sha256
13193 (base32 "0rsac03shkm0yxq91hzxdvhb96wy168bxdw8azi25bvlm8s3l27p"))
13194 (patches
13195 (list
13196 (origin
13197 (method url-fetch)
13198 (uri (string-append "https://github.com/PiotrDabkowski/Js2Py/commit"
13199 "/fd7df4a91fb08060914c7b1d9e94583d18f3371b"
13200 ".patch"))
13201 (file-name (string-append name "-" version "-pull-327.patch"))
13202 (sha256
13203 (base32 "14v89v8qqrsq0d63xbilkvx19l1rk59mlrbxvd4sj138lk7160ki")))))))
13204 (build-system pyproject-build-system)
13205 (arguments
13206 (list #:tests? #f)) ; tests require Node
13207 (native-inputs
13208 (list python-setuptools))
13209 (propagated-inputs
13210 (list python-pyjsparser
13211 python-six
13212 python-tzlocal))
13213 (home-page "https://github.com/PiotrDabkowski/Js2Py")
13214 (synopsis "JavaScript to Python translator")
13215 (description
13216 "This package provides a JavaScript to Python translator and a JavaScript
13217interpreter written in pure Python.")
13218 (license license:expat)))
13219
13220(define-public python-http-ece
13221 (package
13222 (name "python-http-ece")
13223 (version "1.2.1")
13224 (source
13225 (origin
13226 (method git-fetch)
13227 (uri (git-reference
13228 (url "https://github.com/web-push-libs/encrypted-content-encoding")
13229 (commit (string-append "v" version))))
13230 (file-name (git-file-name name version))
13231 (sha256
13232 (base32 "16kd9dsfpyfvq4iw6bbrrqrvsnf5lwgwa6p9f3b1y56ab18y0kzx"))))
13233 (build-system pyproject-build-system)
13234 (arguments
13235 `(#:phases
13236 (modify-phases %standard-phases
13237 (add-after 'unpack 'change-directory
13238 (lambda _ (chdir "python") #t)))))
13239 (native-inputs
13240 (list python-pytest python-setuptools))
13241 (propagated-inputs
13242 (list python-cryptography))
13243 (home-page "https://github.com/web-push-libs/encrypted-content-encoding")
13244 (synopsis "Encrypted Content Encoding for HTTP")
13245 (description
13246 "This package provides a simple implementation of Encrypted Content
13247Encoding for HTTP.")
13248 (license license:expat)))
13249
13250(define-public python-imap-tools
13251 (package
13252 (name "python-imap-tools")
13253 (version "1.9.0")
13254 (source
13255 (origin
13256 (method git-fetch) ; no tests in PyPI release
13257 (uri (git-reference
13258 (url "https://github.com/ikvk/imap_tools")
13259 (commit (string-append "v" version))))
13260 (file-name (git-file-name name version))
13261 (sha256
13262 (base32 "0iawc6shxn8p0ysiqiahfic5rp1r16f7rfn11c8y2fl8falckynr"))))
13263 (arguments
13264 (list
13265 #:test-flags
13266 ;; Tests require a network connection
13267 #~(list "-k" (string-append "not test_action"
13268 " and not test_attributes"
13269 " and not test_connection"
13270 " and not test_folders"
13271 " and not test_idle"
13272 " and not test_live"))))
13273 (build-system pyproject-build-system)
13274 (native-inputs
13275 (list python-pytest python-setuptools python-wheel))
13276 (home-page "https://github.com/ikvk/imap_tools")
13277 (synopsis "Work with email and mailbox by IMAP")
13278 (description
13279 "This Python library provides tools to deal with email and mailboxes
13280over IMAP:
13281
13282@itemize
13283@item Parsed email message attributes
13284@item Query builder for searching emails
13285@item Work with emails in folders (copy, delete, flag, move, seen)
13286@item Work with mailbox folders (list, set, get, create, exists, rename, delete, status)
13287@end itemize")
13288 (license license:asl2.0)))
13289
13290(define-public python-giturlparse
13291 (package
13292 (name "python-giturlparse")
13293 (version "0.12.0")
13294 (source
13295 (origin
13296 (method git-fetch)
13297 (uri (git-reference
13298 (url "https://github.com/nephila/giturlparse")
13299 (commit version)))
13300 (file-name (git-file-name name version))
13301 (sha256
13302 (base32 "1fdbxp176p17sn5xc1418mz2vk00hlcsd5qmi2fdcfphqal6raan"))))
13303 (build-system pyproject-build-system)
13304 (native-inputs (list python-pytest python-setuptools))
13305 (home-page "https://github.com/nephila/giturlparse")
13306 (synopsis "Git URL parsing module")
13307 (description
13308 "This package provides a git URL parsing module which supports parsing
13309and rewriting of remote git URLs from various hosting providers.")
13310 (license license:asl2.0)))
13311
13312(define-public python-hstspreload
13313 (package
13314 (name "python-hstspreload")
13315 (version "2025.1.1")
13316 (source
13317 (origin
13318 (method git-fetch)
13319 (uri (git-reference
13320 (url "https://github.com/sethmlarson/hstspreload")
13321 (commit version)))
13322 (file-name (git-file-name name version))
13323 (sha256
13324 (base32 "02mdzhgdz3sprgc26qb084zy639h2zw2yc8d2vm1r18ap9k51ayq"))))
13325 (build-system pyproject-build-system)
13326 (arguments (list #:tests? #f)) ; tests require external resources.
13327 (native-inputs (list python-setuptools))
13328 (home-page "https://github.com/sethmlarson/hstspreload")
13329 (synopsis "Chromium HSTS Preload list as a Python package")
13330 (description
13331 "@code{python-hstspreload} contains Chromium HSTS Preload list
13332as a Python package.")
13333 (license license:bsd-3)))
13334
13335(define-public python-sanic-routing
13336 (package
13337 (name "python-sanic-routing")
13338 (version "23.12.0")
13339 (source
13340 (origin
13341 (method url-fetch)
13342 (uri (pypi-uri "sanic-routing" version))
13343 (sha256
13344 (base32 "014bhkharcgyprdvlk7wjxhjp1pr0cva1nwj4f2qrr23qiidrjhx"))))
13345 (build-system pyproject-build-system)
13346 (arguments
13347 ;; PyPi sources does not contain tests, recursive dependency on
13348 ;; python-sanic.
13349 (list #:tests? #f))
13350 (native-inputs (list python-setuptools python-wheel))
13351 (home-page "https://github.com/sanic-org/sanic-routing/")
13352 (synopsis "Routing component for Sanic")
13353 (description "Internal package for @code{python-sanic}, which provides
13354the @code{BasicRouter}.")
13355 (license license:expat)))
13356
13357(define-public python-sanic-testing
13358 (package
13359 (name "python-sanic-testing")
13360 (version "24.6.0")
13361 (source
13362 (origin
13363 (method git-fetch)
13364 (uri (git-reference
13365 (url "https://github.com/sanic-org/sanic-testing/")
13366 (commit (string-append "v" version))))
13367 (file-name (git-file-name name version))
13368 (sha256
13369 (base32 "0jk8ji3zjkb0jz15jxmn98yydvzk8djqm2iwcg0d281cmp2j09bf"))))
13370 (build-system pyproject-build-system)
13371 (propagated-inputs (list python-httpx))
13372 (native-inputs
13373 (list python-pytest
13374 python-pytest-asyncio
13375 python-sanic-minimal
13376 python-setuptools))
13377 (home-page "https://github.com/sanic-org/sanic-testing/")
13378 (synopsis "Test clients for Sanic")
13379 (description "Internal package for @code{python-sanic}, which is
13380meant to be the core testing utility and clients for testing Sanic
13381applications.")
13382 (license license:expat)))
13383
13384(define-public python-sanic
13385 (package
13386 (name "python-sanic")
13387 (version "25.12.1")
13388 (source
13389 (origin
13390 (method url-fetch)
13391 (uri (pypi-uri "sanic" version))
13392 (sha256
13393 (base32 "0zxll83cvmcpiad3rri7cn9y8wi8xn7x0b00dimg0c20irhbylbv"))
13394 ;; Loosen requirements for both python-sanic and python-sanic-bootstrap.
13395 (modules '((guix build utils)))
13396 (snippet #~(substitute* "setup.py"
13397 (("setuptools>=[0-9.]*")
13398 "setuptools")))))
13399 (build-system pyproject-build-system)
13400 (arguments
13401 (list
13402 #:test-flags
13403 #~(list "--asyncio-mode=auto"
13404 "--ignore=tests/benchmark/"
13405 "--ignore=tests/typing/test_typing.py"
13406 ;; Most tests hang or fail
13407 "--ignore=tests/test_cli.py"
13408 "--ignore=tests/worker/test_worker_serve.py"
13409 "-k"
13410 (string-append
13411 ;; PyPi sources lack examples module.
13412 "not test_gunicorn_"
13413 ;; Does not expect brotli and reordered headers.
13414 " and not test_raw_headers"
13415 ;; These look like buggy testcases.
13416 " and not test_zero_downtime"
13417 " and not test_non_default_uvloop_config_raises_warning"
13418 " and not test_listeners_triggered"
13419 " and not test_keep_alive_connection_context"
13420 " and not test_keep_alive_client_timeout"
13421 " and not test_conflicting_body_methods_overload"
13422 " and not test_unix_connection"
13423 ;; Unclear why they fail since core-updates merge.
13424 " and not test_missing_sni"
13425 " and not test_no_matching_cert"
13426 " and not test_wildcards"
13427 ;; These tests fail because subprotocols appear to be
13428 ;; parameterized as None
13429 " and not test_websocket_route_with_subprotocols"
13430 ;; AF_UNIX path too long
13431 " and not test_setup_and_teardown_unix"
13432 " and not test_configure_socket"
13433 ;; Freezes
13434 " and not test_server_run_with_repl"
13435 " and not test_server_run"
13436 " and not test_no_workers"
13437 ;; Raises DaemonError: Group 'root' does not exist
13438 " and not test_validate_user_sets_uid_and_gid"
13439 " and not test_validate_group_sets_gid"
13440 ;; Raises AssertionError:
13441 ;; assert 'text/xml; charset=utf-8' == 'application/xml'
13442 " and not test_guess_content_type"
13443 ;; Don't know.
13444 " and not test_chained_exception_handler"))))
13445 (propagated-inputs
13446 (list python-aiofiles
13447 python-aioquic
13448 python-html5tagger
13449 python-httptools
13450 python-multidict
13451 python-sanic-routing
13452 python-tracerite
13453 python-typing-extensions
13454 python-ujson
13455 python-uvloop
13456 python-websockets))
13457 (native-inputs
13458 (list python-bandit
13459 python-beautifulsoup4
13460 python-chardet
13461 python-cryptography
13462 python-docutils
13463 python-pygments
13464 python-pytest
13465 python-pytest-asyncio
13466 python-pytest-benchmark
13467 python-pytest-sanic
13468 python-pytest-xdist
13469 python-sanic-testing
13470 python-setuptools
13471 python-slotscheck
13472 python-towncrier
13473 python-types-ujson
13474 python-uvicorn))
13475 (home-page "https://github.com/sanic-org/sanic/")
13476 (synopsis "Async Python web server/framework")
13477 (description
13478 "Sanic is a Python web server and web framework that's written to go
13479fast. It allows the usage of the @code{async/await} syntax added in Python
134803.5, which makes your code non-blocking and speedy.")
13481 (license license:expat)))
13482
13483;; A bare minimal package, mainly to use in tests and reduce closure size.
13484;; Tests are left out in the main package to slim down native-inputs and
13485;; propagated-inputs.
13486(define-public python-sanic-minimal
13487 (package/inherit python-sanic
13488 (name "python-sanic-minimal")
13489 (arguments (list #:tests? #f))
13490 (native-inputs (list python-setuptools))
13491 (propagated-inputs
13492 (list python-aiofiles
13493 python-html5tagger
13494 python-httptools
13495 python-multidict
13496 python-sanic-routing
13497 python-tracerite
13498 python-typing-extensions
13499 python-ujson
13500 python-uvloop
13501 python-websockets))))
13502
13503;;; Deprecated on <2026-10-08>.
13504(define-deprecated-package python-sanic-bootstrap python-sanic-minimal)
13505
13506(define-public python-socketio
13507 (package
13508 (name "python-socketio")
13509 (version "5.16.4")
13510 (source
13511 (origin
13512 (method git-fetch)
13513 (uri (git-reference
13514 (url "https://github.com/miguelgrinberg/python-socketio/")
13515 (commit (string-append "v" version))))
13516 (file-name (git-file-name name version))
13517 (sha256
13518 (base32 "0695mq1nijlljkmpgn3nk6gfv34rzpgxrdsld1l1vix6gxyxna0y"))))
13519 (build-system pyproject-build-system)
13520 (arguments
13521 (list
13522 ;; tests: 642 passed, 5 warnings
13523 #:test-flags
13524 ;; Tests freeze.
13525 #~(list "--ignore=tests/async/test_admin.py"
13526 "--ignore=tests/common/test_admin.py")))
13527 (native-inputs
13528 (list python-msgpack
13529 python-pytest
13530 python-pytest-asyncio
13531 python-pytest-timeout
13532 python-redis
13533 python-setuptools
13534 python-uvicorn
13535 python-valkey))
13536 (propagated-inputs
13537 (list python-bidict
13538 python-engineio
13539 ;; [optional]
13540 python-aiohttp
13541 python-requests
13542 python-websocket-client))
13543 (home-page "https://github.com/miguelgrinberg/python-socketio/")
13544 (synopsis "Python Socket.IO server")
13545 (description
13546 "This package provides a Python implementation of the @code{Socket.IO}
13547realtime client and server.")
13548 (license license:expat)))
13549
13550(define-public python-socks
13551 (package
13552 (name "python-socks")
13553 (version "2.8.1")
13554 (source
13555 (origin
13556 (method git-fetch)
13557 (uri (git-reference
13558 (url "https://github.com/romis2012/python-socks")
13559 (commit (string-append "v" version))))
13560 (file-name (git-file-name name version))
13561 (sha256
13562 (base32 "1x95i9w3izivdgz6hadh5kiil12i4ljk4ashgh3g0rjv2rw33vhj"))))
13563 (build-system pyproject-build-system)
13564 (propagated-inputs (list python-trio))
13565 (native-inputs
13566 (list python-anyio
13567 python-flask
13568 python-pytest
13569 python-pytest-asyncio
13570 python-pytest-trio
13571 python-setuptools
13572 python-tiny-proxy
13573 python-trustme
13574 python-yarl))
13575 (home-page "https://github.com/romis2012/python-socks")
13576 (synopsis
13577 "Core proxy (SOCKS4, SOCKS5, HTTP tunneling) functionality for Python")
13578 (description
13579 "Socks is a library providing core proxy (SOCKS4, SOCKS5, HTTP tunneling)
13580 functionality.")
13581 (license license:asl2.0)))
13582
13583(define-public python-socksio
13584 (package
13585 (name "python-socksio")
13586 (version "1.0.0")
13587 (source
13588 (origin
13589 (method url-fetch)
13590 (uri (pypi-uri "socksio" version))
13591 (sha256
13592 (base32 "1b64j45w35jzhjhnq44bnyad9ydh1iyyd7a6j2c8phxmllyyp2zq"))))
13593 (build-system pyproject-build-system)
13594 (native-inputs
13595 (list python-flit-core python-pytest))
13596 (home-page "https://github.com/sethmlarson/socksio")
13597 (synopsis "Sans-I/O implementation of SOCKS4, SOCKS4A, and SOCKS5")
13598 (description "The @code{socksio} Python module is a client-side sans-I/O
13599SOCKS proxy implementation. It supports SOCKS4, SOCKS4A, and SOCKS5.
13600@code{socksio} is a sans-I/O library similar to @code{h11} or @code{h2}; this
13601means the library itself does not handle the actual sending of the bytes
13602through the network, it only deals with the implementation details of the
13603SOCKS protocols. It can be paired with any I/O library.")
13604 (license license:expat)))
13605
13606(define-public python-simple-websocket
13607 (package
13608 (name "python-simple-websocket")
13609 (version "1.1.0")
13610 (source
13611 (origin
13612 (method url-fetch)
13613 (uri (pypi-uri "simple_websocket" version))
13614 (sha256
13615 (base32 "1r1all55d5dimiw3qwdhj53cxj9yjgnskcysmcscarx0g9726fbr"))))
13616 (build-system pyproject-build-system)
13617 (arguments
13618 ;; Requires Internet access to resolve example.com
13619 (list #:test-flags '(list "--ignore=tests/test_client.py")))
13620 (propagated-inputs (list python-wsproto))
13621 (native-inputs (list python-pytest
13622 python-setuptools))
13623 (home-page "https://github.com/miguelgrinberg/simple-websocket")
13624 (synopsis "Simple WebSocket server and client for Python")
13625 (description "This package provides a simple @code{WebSocket} server and
13626client for Python.")
13627 (license license:expat)))
13628
13629(define-public python-siosocks
13630 (package
13631 (name "python-siosocks")
13632 (version "0.3.0")
13633 (source
13634 (origin
13635 (method git-fetch)
13636 (uri (git-reference
13637 (url "https://github.com/pohmelie/siosocks")
13638 (commit (string-append "v" version))))
13639 (file-name (git-file-name name version))
13640 (sha256
13641 (base32 "0zcib4j5bfxlryfa412wmlkk8ivsiwxrfbpij5s7ag839ii2lxa5"))))
13642 (build-system pyproject-build-system)
13643 (native-inputs
13644 (list python-pytest
13645 python-pytest-asyncio
13646 python-pytest-trio
13647 python-setuptools))
13648 (propagated-inputs (list python-trio))
13649 (home-page "https://github.com/pohmelie/siosocks")
13650 (synopsis "SOCKSv4 & SOCKSv5 TCP proxy protocol implementation in Python")
13651 (description
13652 "This package provides a Python module and framework for sans-io socks proxy
13653client/server with couple io backends.
13654
13655Features:
13656@itemize
13657@item Only TCP connect (no BIND, no UDP)
13658@item Both client and server
13659@item SOCKS versions: 4, 4a, 5
13660@item SOCKSv5 auth: no auth, username/password
13661@item Couple io backends: @code{asyncio}, @code{trio}, @code{socketserver}
13662@item One-shot socks server (@code{python -m siosocks})
13663@end itemize")
13664 (license license:expat)))
13665
13666(define-public python-tiny-proxy
13667 (package
13668 (name "python-tiny-proxy")
13669 (version "0.2.1")
13670 (source
13671 (origin
13672 (method url-fetch)
13673 (uri (pypi-uri "tiny_proxy" version))
13674 (sha256
13675 (base32 "05nq62fn3p7s1a6dkdvnrzmk39d9ddrzb3pqbbli025qs3m9j1bq"))))
13676 (build-system pyproject-build-system)
13677 ;; There are only a handful of tests and they require the as yet
13678 ;; unpackaged httpx_socks.
13679 (arguments (list #:tests? #false))
13680 (propagated-inputs (list python-anyio))
13681 (native-inputs
13682 (list python-httpx
13683 python-pytest
13684 python-setuptools
13685 python-wheel))
13686 (home-page "https://github.com/romis2012/tiny-proxy")
13687 (synopsis "Simple proxy server (SOCKS4(a), SOCKS5(h), HTTP tunnel)")
13688 (description "This package provides a simple proxy server (SOCKS4(a),
13689SOCKS5(h), HTTP tunnel).")
13690 (license license:asl2.0)))
13691
13692(define-public python-google-auth
13693 (package
13694 (name "python-google-auth")
13695 (version "2.56.0")
13696 (source
13697 (origin
13698 (method url-fetch)
13699 (uri (pypi-uri "google_auth" version))
13700 (sha256
13701 (base32 "0lx5cw49lfjqvd9vx1vlslrxyh9q0xd6d46np5a2dab9nlqa03zr"))))
13702 (build-system pyproject-build-system)
13703 (propagated-inputs
13704 (list python-aiohttp
13705 python-cryptography
13706 python-pyasn1-modules
13707 python-requests
13708 python-rsa
13709 python-urllib3))
13710 (native-inputs
13711 (list nss-certs-for-test
13712 python-aiohttp
13713 python-aioresponses
13714 python-flask
13715 python-freezegun
13716 python-grpcio
13717 python-oauth2client
13718 python-packaging
13719 python-pyjwt
13720 python-pyopenssl
13721 python-pytest
13722 python-pytest-asyncio
13723 python-pytest-localserver
13724 python-pyu2f
13725 python-requests
13726 python-responses
13727 python-rsa
13728 python-setuptools
13729 python-urllib3))
13730 (home-page "https://github.com/googleapis/google-auth-library-python")
13731 (synopsis "Google Authentication Library")
13732 (description "This library simplifies using Google's various
13733server-to-server authentication mechanisms to access Google APIs.")
13734 (license license:asl2.0)))
13735
13736(define-public python-google-resumable-media
13737 (package
13738 (name "python-google-resumable-media")
13739 (version "2.8.0")
13740 (source
13741 (origin
13742 (method git-fetch)
13743 (uri (git-reference
13744 (url
13745 "https://github.com/googleapis/google-resumable-media-python")
13746 (commit (string-append "v" version))))
13747 (file-name (git-file-name name version))
13748 (sha256
13749 (base32 "0ndida5yr06bal0m09yri80bvf8x7yy690b14ywnxl4ixi8rlh6s"))))
13750 (build-system pyproject-build-system)
13751 (arguments
13752 (list
13753 #:test-flags
13754 #~(list
13755 ;; XXX: Missing test_utils.retry.
13756 "--ignore-glob=tests*/system/"
13757 ;; XXX: md5_hash is not mock.sentinel.md5_hash
13758 "-k" (string-join
13759 (list "not test_brotli"
13760 "test_constructor"
13761 "test_decompress")
13762 " and not "))))
13763 (propagated-inputs (list python-google-crc32c))
13764 (native-inputs
13765 (list python-google-auth
13766 python-mock
13767 python-pytest
13768 python-pytest-asyncio
13769 python-setuptools
13770 python-test-utils))
13771 (home-page "https://github.com/googleapis/google-resumable-media-python")
13772 (synopsis "Utilities for Google Media Downloads and Resumable Uploads")
13773 (description "This package provides utilities for Google Media Downloads
13774and Resumable Uploads.")
13775 (license license:asl2.0)))
13776
13777(define-public python-googleapis-common-protos
13778 (package
13779 (name "python-googleapis-common-protos")
13780 (version "1.66.0")
13781 (source
13782 (origin
13783 (method git-fetch)
13784 (uri (git-reference
13785 (url "https://github.com/googleapis/python-api-common-protos")
13786 (commit (string-append "v" version))))
13787 (file-name (git-file-name name version))
13788 (sha256
13789 (base32 "1fb7bcmjngmwwhqrldslli6r5z3s6r2kj4ywjmdjj92d1i51c29r"))))
13790 (build-system pyproject-build-system)
13791 (propagated-inputs (list python-protobuf))
13792 (native-inputs (list python-pytest python-setuptools))
13793 (home-page "https://github.com/googleapis/python-api-common-protos")
13794 (synopsis "Common protobufs used in Google APIs")
13795 (description
13796 "This package contains Python classes generated from the common protos in
13797the @code{googleapis/api-common-protos} repository.")
13798 (license license:asl2.0)))
13799
13800(define-public python-google-api-core
13801 (package
13802 (name "python-google-api-core")
13803 (version "2.29.0")
13804 (source
13805 (origin
13806 (method git-fetch)
13807 (uri (git-reference
13808 (url "https://github.com/googleapis/python-api-core")
13809 (commit (string-append "v" version))))
13810 (file-name (git-file-name name version))
13811 (sha256
13812 (base32 "0ahs8abyl7719paarlnspqp8yds149w7vm3w7zz6f7q04sscd862"))))
13813 (build-system pyproject-build-system)
13814 (arguments
13815 (list
13816 #:test-flags
13817 ;; XXX: DeprecationWarning: datetime.datetime.utcfromtimestamp() is
13818 ;; deprecated and scheduled for removal in a future version. Use
13819 ;; timezone-aware objects to represent datetimes in UTC:
13820 ;; datetime.datetime.fromtimestamp(timestamp, datetime.UTC).
13821 #~(list "-W" "ignore::DeprecationWarning")))
13822 (propagated-inputs
13823 (list python-google-auth
13824 python-googleapis-common-protos
13825 python-protobuf
13826 python-proto-plus
13827 python-requests))
13828 (native-inputs
13829 (list python-mock
13830 python-pytest
13831 python-pytest-asyncio
13832 python-pytest-mock
13833 python-setuptools))
13834 (home-page "https://github.com/googleapis/python-api-core")
13835 (synopsis "Google API client core library")
13836 (description
13837 "This library defines common helpers used by all Google API clients.")
13838 (license license:asl2.0)))
13839
13840(define-public python-google-cloud-core
13841 (package
13842 (name "python-google-cloud-core")
13843 (version "2.5.0")
13844 (source
13845 (origin
13846 (method git-fetch)
13847 (uri (git-reference
13848 (url "https://github.com/googleapis/python-cloud-core")
13849 (commit (string-append "v" version))))
13850 (file-name (git-file-name name version))
13851 (sha256
13852 (base32 "1d7li74cakgl9vghxfir9nxwy36980alvxwgwjg0zyla3hgj07cq"))))
13853 (build-system pyproject-build-system)
13854 (arguments
13855 (list
13856 #:test-flags
13857 ;; XXX: DeprecationWarning: datetime.datetime.utcfromtimestamp() is
13858 ;; deprecated and scheduled for removal in a future version. Use
13859 ;; timezone-aware objects to represent datetimes in UTC:
13860 ;; datetime.datetime.fromtimestamp(timestamp, datetime.UTC).
13861 #~(list "-W" "ignore::DeprecationWarning")))
13862 (propagated-inputs (list python-google-api-core python-google-auth))
13863 (native-inputs
13864 (list python-grpcio
13865 python-grpcio-status
13866 python-pytest
13867 python-setuptools))
13868 (home-page "https://github.com/googleapis/python-cloud-core")
13869 (synopsis "Google Cloud API client core library")
13870 (description
13871 "This library defines common helpers (e.g. base @code{Client} classes)
13872used by all of the @code{google-cloud-*} packages.")
13873 (license license:asl2.0)))
13874
13875(define-public python-google-cloud-storage
13876 (package
13877 (name "python-google-cloud-storage")
13878 (version "2.19.0")
13879 (source
13880 (origin
13881 (method git-fetch)
13882 (uri (git-reference
13883 (url "https://github.com/googleapis/python-storage")
13884 (commit (string-append "v" version))))
13885 (file-name (git-file-name name version))
13886 (sha256
13887 (base32 "19w10v2j4ciwlf8j2ylm77f8z1b0kqzg8lkh9rvh2swv1zrhydpj"))))
13888 (build-system pyproject-build-system)
13889 (arguments
13890 (list
13891 #:test-flags
13892 #~(list
13893 ;; XXX: Missing test_utils.retry.
13894 "--ignore=tests/system/"
13895 ;; Needs docker.
13896 "--ignore=tests/conformance/"
13897 ;; XXX: Deprecations.
13898 "-k" (string-join
13899 (list "not test_set_api_request_attr"
13900 "test_create_bucket_w_custom_endpoint"
13901 "test_ctor_w_api_endpoint_override"
13902 "test_ctor_w_custom_endpoint_use_auth"
13903 "test_list_buckets_w_custom_endpoint")
13904 " and not ")
13905 "tests")))
13906 (native-inputs
13907 (list python-googleapis-common-protos
13908 python-mock
13909 python-pytest
13910 python-test-utils
13911 python-setuptools))
13912 (propagated-inputs
13913 (list python-google-api-core
13914 python-google-auth
13915 python-google-cloud-core
13916 python-google-resumable-media
13917 python-protobuf
13918 python-requests))
13919 (home-page "https://github.com/googleapis/python-storage")
13920 (synopsis "Google Cloud Storage API client library")
13921 (description
13922 "Google Cloud Storage allows you to store data on Google infrastructure,
13923and it can be used to distribute large data objects to users via direct
13924download. This package provides a Google Cloud Storage API client library for
13925Python.")
13926 (license license:asl2.0)))
13927
13928(define-public python-smart-open
13929 (package
13930 (name "python-smart-open")
13931 (version "7.3.0")
13932 (source
13933 (origin
13934 (method git-fetch) ;no tests in PyPI archive
13935 (uri (git-reference
13936 (url "https://github.com/piskvorky/smart_open")
13937 (commit (string-append "v" version))))
13938 (file-name (git-file-name name version))
13939 (sha256
13940 (base32 "1jk3dj0j7idv94g1ga5wyvybakj4l150g26cbsjkrjfpy017vxab"))))
13941 (build-system pyproject-build-system)
13942 (arguments
13943 (list
13944 #:test-flags
13945 #~(list "--ignore=ci_helpers/"
13946 "--ignore=integration-tests/"
13947 ;; FIXME: Enable when guix/guix#1436 is resolved.
13948 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri"
13949 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri_contains_question_mark"
13950 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri_contains_slash"
13951 "--deselect=tests/test_smart_open.py::ParseUriTest::test_scheme"
13952 "--ignore=tests/test_gcs.py")))
13953 (propagated-inputs
13954 (list python-azure-common
13955 python-azure-core
13956 python-azure-storage-blob
13957 python-boto3
13958 ;; python-google-cloud-storage ;see guix/guix#1436
13959 python-paramiko
13960 python-requests
13961 python-wrapt
13962 python-zstandard))
13963 (native-inputs
13964 (list python-numpy
13965 python-moto
13966 python-pytest
13967 python-pytest-rerunfailures
13968 python-responses
13969 python-setuptools
13970 python-setuptools-scm
13971 python-wheel))
13972 (home-page "https://github.com/piskvorky/smart_open")
13973 (synopsis "Utilities for streaming large files")
13974 (description
13975 "This package provides utilities for streaming large files (S3, HDFS,
13976GCS, Azure Blob Storage, gzip, bz2, etc.)")
13977 (license license:expat)))
13978
13979(define-public python-smart-open-6
13980 (package
13981 (inherit python-smart-open)
13982 (name "python-smart-open")
13983 (version "6.4.0")
13984 (source
13985 (origin
13986 (method git-fetch)
13987 (uri (git-reference
13988 (url "https://github.com/piskvorky/smart_open")
13989 (commit (string-append "v" version))))
13990 (file-name (git-file-name name version))
13991 (sha256
13992 (base32 "1vpx37b6lsb6iwi59776ywjrqk1czv8arlhaf9073lrsbilqvj3x"))))
13993 (arguments
13994 (list
13995 ;; XXX: Tests need some older native inputs, disable for now.
13996 #:tests? #f))))
13997
13998(define-public python-w3lib
13999 (package
14000 (name "python-w3lib")
14001 (version "2.3.1")
14002 (source
14003 (origin
14004 (method url-fetch)
14005 (uri (pypi-uri "w3lib" version))
14006 (sha256
14007 (base32
14008 "1929layzxwdnf43hhrz7rabv388b2yibj7mnq9s62mr760mc12jw"))))
14009 (build-system pyproject-build-system)
14010 (native-inputs
14011 (list python-pytest python-setuptools python-wheel))
14012 (home-page "https://github.com/scrapy/w3lib")
14013 (synopsis "Python library of web-related functions")
14014 (description
14015 "This is a Python library of web-related functions, such as: remove
14016comments, or tags from HTML snippets, extract base url from HTML snippets,
14017translate entities on HTML strings, among other things.")
14018 (license license:bsd-3)))
14019
14020(define-public python-webcolors
14021 (package
14022 (name "python-webcolors")
14023 (version "25.10.0")
14024 (source
14025 (origin
14026 (method git-fetch)
14027 (uri (git-reference
14028 (url "https://github.com/ubernostrum/webcolors")
14029 (commit version)))
14030 (sha256
14031 (base32 "1wknzir5252y30wcpwxb04ngmrdw1llzqmrpiajyhkm81x2lgrym"))))
14032 (build-system pyproject-build-system)
14033 (native-inputs
14034 (list python-pdm-backend python-pytest))
14035 (home-page "https://github.com/ubernostrum/webcolors")
14036 (synopsis "HTML/CSS color definitions library")
14037 (description "@code{python-webcolors} is a module for working with
14038HTML/CSS color definitions. Normalizing and converting between the following
14039formats is supported.
14040@itemize
14041@item Specification-defined color names
14042@item Six-digit hexadecimal
14043@item Three-digit hexadecimal
14044@item Integer rgb() triplet
14045@item Percentage rgb() triplet
14046@end itemize
14047Only the RGB colorspace is supported. Conversion to/from the HSL colorspace
14048can be handled by the @code{colorsys} module in the Python standard library.")
14049 (license license:bsd-3)))
14050
14051(define-public python-woob
14052 ;; TODO: woob requires backends which are currently installed on the fly in
14053 ;; ~/.local/share/woob/modules/3.7/woob_modules/ , perhaps we should install
14054 ;; them in the store instead. Many modules are included in the modules
14055 ;; directory in the source tree, but it is unclear how to install them.
14056 ;; Many modules require extra dependencies though, so maybe they should be
14057 ;; packaged independently of woob itself.
14058 (package
14059 (name "python-woob")
14060 (version "3.7")
14061 (source
14062 (origin
14063 (method git-fetch)
14064 (uri (git-reference
14065 (url "https://gitlab.com/woob/woob.git")
14066 (commit version)))
14067 (file-name (git-file-name name version))
14068 (sha256
14069 (base32 "1sy0aykff56xs4dnc7ak6m8is2zgz9fprf3i1pk8n861xz1z748i"))))
14070 (build-system pyproject-build-system)
14071 (arguments
14072 (list
14073 #:test-flags
14074 ;; Deselect tests that require DNS lookup.
14075 #~(list
14076 "--deselect=tests/browser/adapters.py::TestAdapter::test_ciphers"
14077 "--deselect=tests/browser/browsers.py::TestBrowser::test_verify")
14078 #:phases
14079 #~(modify-phases %standard-phases
14080 (add-before 'build 'relax-requirements
14081 (lambda _
14082 (substitute* "pyproject.toml"
14083 ;; packaging ~= 23.0
14084 (("\"packaging .*\",")
14085 "")
14086 ;; rich~=13.0
14087 (("\"rich .*\",")
14088 "\"rich\",")))))))
14089 (native-inputs
14090 (list nss-certs-for-test
14091 python-pytest
14092 python-setuptools))
14093 (propagated-inputs
14094 (list python-babel
14095 python-colorama
14096 python-cssselect
14097 python-dateutil
14098 python-feedparser
14099 python-html2text
14100 python-lxml
14101 python-packaging
14102 python-pillow
14103 python-prettytable
14104 python-pycountry
14105 python-pyyaml
14106 python-requests
14107 python-responses
14108 python-rich
14109 python-termcolor
14110 python-unidecode))
14111 (home-page "https://woob.tech/")
14112 (synopsis "Woob, Web Outside Of Browsers")
14113 (description
14114 "Woob is a collection of applications able to interact with
14115websites, without requiring the user to open them in a browser. It also
14116provides well-defined APIs to talk to websites lacking one.")
14117 (license license:lgpl3+)))
14118
14119(define-public python-flask-combo-jsonapi
14120 (let ((commit "3cfff98ecdbadc45d25a3fd443ad67d3743be6f5")
14121 (revision "0"))
14122 (package
14123 (name "python-flask-combo-jsonapi")
14124 (version (git-version "1.1.0" revision commit))
14125 (source
14126 (origin
14127 (method git-fetch)
14128 (uri (git-reference
14129 (url "https://github.com/AdCombo/flask-combo-jsonapi")
14130 (commit commit)))
14131 (file-name (git-file-name name version))
14132 (sha256
14133 (base32 "1lp81v96qh9hdj3c95kvfaq0vy5vd8cm55j03aszc93bs8z5jg7h"))))
14134 (build-system pyproject-build-system)
14135 (arguments
14136 (list
14137 #:test-flags
14138 #~(list
14139 "-k"
14140 (string-join
14141 (list
14142 ;; XXX: This tests a feature that doesn't make sense when dropping
14143 ;; marshmallow < 3 support.
14144 "not test_compute_schema_propagate_context"
14145 ;; The following tests fail for unknown reasons (see:
14146 ;; https://github.com/AdCombo/flask-combo-jsonapi/issues/66).
14147 "test_get_list_with_simple_filter_relationship_custom_qs_api"
14148 "test_get_list_with_simple_filter_relationship_error")
14149 " and not "))
14150 #:phases
14151 #~(modify-phases %standard-phases
14152 (add-after 'unpack 'loosen-requirements
14153 (lambda _
14154 ;; Don't pin specific versions of dependencies.
14155 (substitute* "requirements.txt"
14156 (("^(sqlalchemy|marshmallow|Flask)[=<>].*" _ dep)
14157 (string-append dep "\n"))
14158 (("^marshmallow_jsonapi[=<>].*")
14159 "marshmallow_jsonapi_minfork\n"))
14160 ;; Drop support for marshmallow < 3.
14161 (substitute* (list "flask_combo_jsonapi/data_layers/alchemy.py"
14162 "flask_combo_jsonapi/schema.py")
14163 (("from marshmallow\\.base import SchemaABC")
14164 "from marshmallow import Schema")
14165 (("if isinstance\\(related_schema_cls, SchemaABC\\):")
14166 "if isinstance(related_schema_cls, Schema):"))
14167 (substitute* "tests/test_sqlalchemy_data_layer.py"
14168 (("default=None")
14169 "dump_default=None")
14170 (("missing=")
14171 "load_default=")))))))
14172 (propagated-inputs
14173 (list python-flask
14174 python-marshmallow
14175 python-marshmallow-jsonapi
14176 python-simplejson
14177 python-sqlalchemy
14178 python-apispec
14179 python-simplejson
14180 python-six))
14181 (native-inputs
14182 (list python-pytest python-setuptools))
14183 (home-page "https://github.com/AdCombo/flask-combo-jsonapi")
14184 (synopsis "Flask extension to quickly create JSON:API 1.0 REST Web APIs")
14185 (description
14186 "Flask-COMBO-JSONAPI is a Python Flask extension for building REST Web
14187APIs compliant with the @uref{https://jsonapi.org, JSON:API 1.0}
14188specification.
14189
14190It tries to combine the power of Flask-Restless with the flexibility of
14191Flask-RESTful to quickly build APIs that fit the complexity of existing
14192real-life projects with legacy data and diverse storage providers.")
14193 (license license:expat))))
14194
14195(define-public python-mwparserfromhell
14196 (package
14197 (name "python-mwparserfromhell")
14198 (version "0.7.2")
14199 (source
14200 (origin
14201 (method git-fetch)
14202 (uri (git-reference
14203 (url "https://github.com/earwig/mwparserfromhell")
14204 (commit (string-append "v" version))))
14205 (file-name (git-file-name name version))
14206 (sha256
14207 (base32 "083ir0nccm14431mmn243862gq731ww98fwpd95zm1yccvpzdy68"))))
14208 (build-system pyproject-build-system)
14209 (native-inputs (list python-pytest python-setuptools))
14210 (home-page "https://github.com/earwig/mwparserfromhell")
14211 (synopsis "Python parser for MediaWiki wikicode")
14212 (description
14213 "The MediaWiki Parser From Hell is a python library package that provides
14214a parser for MediaWiki.
14215
14216It exposes parses as normal string objects with additional methods giving
14217access to the special Wikicode features it contains (hyperlinks, tags,
14218templates…). The parser doesn't interpolate strings at all, it remains at a
14219purely formal level.
14220
14221Full documentation may be found at
14222@uref{https://mwparserfromhell.readthedocs.io, ReadTheDocs}")
14223 (license license:expat)))
14224
14225(define-public python-tweepy
14226 (package
14227 (name "python-tweepy")
14228 (version "4.16.0")
14229 (source
14230 (origin
14231 (method git-fetch)
14232 (uri
14233 (git-reference
14234 (url "https://github.com/tweepy/tweepy")
14235 (commit (string-append "v" version))))
14236 (file-name (git-file-name name version))
14237 (sha256
14238 (base32 "1k99qf0h1ykz0c56wdnlsyvd6zrcsrc4rl7rnlaxrpjppxjnpcpn"))))
14239 (build-system pyproject-build-system)
14240 (arguments
14241 ;; tests: 149 passed, 3 skipped, 1 warning
14242 (list #:test-backend #~'unittest
14243 #:test-flags #~(list "discover" "tests")))
14244 (native-inputs
14245 (list nss-certs-for-test
14246 python-flit-core
14247 python-urllib3-1.26
14248 python-vcrpy))
14249 (propagated-inputs
14250 (list python-aiohttp
14251 python-async-lru
14252 python-oauthlib
14253 python-requests
14254 python-requests-oauthlib))
14255 (home-page "https://www.tweepy.org/")
14256 (synopsis "Twitter library for Python")
14257 (description
14258 "This package provides @code{Tweepy}, an easy-to-use Python library for
14259accessing the Twitter API.")
14260 (license license:expat)))
14261
14262(define-public python-quart
14263 (package
14264 (name "python-quart")
14265 (version "0.20.0")
14266 (source
14267 (origin
14268 (method git-fetch)
14269 (uri (git-reference
14270 (url "https://github.com/pallets/quart")
14271 (commit version)))
14272 (file-name (git-file-name name version))
14273 (sha256
14274 (base32 "1gk6vg2cwpn70aald3m50xibjqjamgpz7an11h82w1fig6zmw2il"))))
14275 (build-system pyproject-build-system)
14276 (arguments
14277 (list
14278 #:test-flags
14279 ;; Not sure why test fails; related to a change in dependencies.
14280 #~(list "-k" "not test_cli_blueprints[cli_group2-args2]")))
14281 (native-inputs
14282 (list python-flit-core
14283 python-pytest
14284 python-pytest-asyncio))
14285 (propagated-inputs
14286 (list hypercorn
14287 python-aiofiles
14288 python-blinker
14289 python-click
14290 python-dotenv
14291 python-flask
14292 python-itsdangerous
14293 python-jinja2
14294 python-markupsafe
14295 python-toml
14296 python-werkzeug))
14297 (home-page "https://gitlab.com/pgjones/quart/")
14298 (synopsis "Python ASGI web microframework with the same API as Flask")
14299 (description
14300 "This package provides a Python ASGI web microframework with the same API
14301as Flask.")
14302 (license license:expat)))
14303
14304(define-public python-quart-trio
14305 (package
14306 (name "python-quart-trio")
14307 (version "0.12.0")
14308 (source
14309 (origin
14310 (method url-fetch)
14311 (uri (pypi-uri "quart_trio" version))
14312 (sha256
14313 (base32 "130r8hdk7xxjp380z1r3m28lw86q2a6g9rf0mgp9gs6hk04q9v02"))))
14314 (build-system pyproject-build-system)
14315 (arguments
14316 (list
14317 #:phases
14318 #~(modify-phases %standard-phases
14319 (add-after 'unpack 'remove-coverage-pytest-options
14320 (lambda _
14321 (substitute* "pyproject.toml"
14322 (("--no-cov-on-fail") "")))))))
14323 (native-inputs
14324 (list python-pdm-backend
14325 python-pytest
14326 python-pytest-sugar
14327 python-pytest-trio))
14328 (propagated-inputs
14329 (list hypercorn
14330 python-quart
14331 python-trio))
14332 (home-page "https://github.com/pgjones/quart-trio")
14333 (synopsis "Extension for Quart to support the Trio event loop")
14334 (description
14335 "This package provides a Quart extension to provide Trio support. This
14336is an alternative to using the asyncio event loop present in the Python
14337standard library and supported by default in Quart.")
14338 (license license:expat)))
14339
14340(define-public python-protego
14341 (package
14342 (name "python-protego")
14343 (version "0.4.0")
14344 (source
14345 (origin
14346 (method url-fetch)
14347 (uri (pypi-uri "protego" version))
14348 (sha256
14349 (base32 "1xn2aska8v94jqnbyv4ywczb55gaqvr298q8ybhs168knrifd9ck"))))
14350 (build-system pyproject-build-system)
14351 (native-inputs (list python-pytest python-setuptools python-wheel))
14352 (home-page "https://github.com/scrapy/protego")
14353 (synopsis "Python robots.txt parser with support for modern conventions")
14354 (description "Protego is a pure-Python @file{robots.txt} parser with support
14355for modern conventions.")
14356 (license license:bsd-3)))
14357
14358(define-public python-parsel
14359 (package
14360 (name "python-parsel")
14361 (version "1.10.0")
14362 (source
14363 (origin
14364 (method url-fetch)
14365 (uri (pypi-uri "parsel" version))
14366 (sha256
14367 (base32 "1050v20gzijfcaxpm1d4bvxqw2l7xhyf9pxrawrv8lczanwpvw8l"))))
14368 (build-system pyproject-build-system)
14369 (propagated-inputs
14370 (list python-cssselect
14371 python-jmespath
14372 python-lxml
14373 python-typing-extensions
14374 python-w3lib))
14375 (native-inputs
14376 (list python-psutil python-pytest python-setuptools python-wheel))
14377 (home-page "https://github.com/scrapy/parsel")
14378 (synopsis "Extract data from HTML and XML using XPath and CSS selectors")
14379 (description "Parsel is a library to extract and remove data from
14380HTML and XML using XPath and CSS selectors, optionally combined with
14381regular expressions.")
14382 (license license:bsd-3)))
14383
14384(define-public python-scrapy
14385 (package
14386 (name "python-scrapy")
14387 (version "2.13.3")
14388 (source
14389 (origin
14390 (method url-fetch)
14391 (uri (pypi-uri "scrapy" version))
14392 (sha256
14393 (base32 "0k90pni6vkj7axx3cji0b2x7yg4yfh5kh1csqiq9ssp42265h5xz"))))
14394 (build-system pyproject-build-system)
14395 (arguments
14396 (list #:test-flags
14397 #~(list "--numprocesses" (number->string (parallel-job-count))
14398 "-k" (string-join
14399 ;; ConnectionRefusedError: [Errno 111] Connection
14400 ;; refused
14401 (list "not test_append"
14402 "test_append_active_mode"
14403 "test_overwrite"
14404 "test_overwrite_active_mode"
14405 "test_persist"
14406 ;; AssertionError
14407 "test_start_deprecated_super")
14408 " and not ")
14409 ;; Skip documentation testing.
14410 "--ignore=docs")
14411 #:phases
14412 #~(modify-phases %standard-phases
14413 (add-before 'check 'prepare-test-environment
14414 (lambda _
14415 (setenv "HOME" "/tmp"))))))
14416 (propagated-inputs
14417 (list python-cryptography
14418 python-cssselect
14419 python-defusedxml
14420 python-itemadapter
14421 python-itemloaders
14422 python-lxml
14423 python-packaging
14424 python-parsel
14425 python-protego
14426 python-pydispatcher
14427 python-pyopenssl
14428 python-pypydispatcher
14429 python-queuelib
14430 python-service-identity
14431 python-tldextract
14432 python-twisted
14433 python-w3lib
14434 python-zope-interface))
14435 (native-inputs
14436 (list nss-certs-for-test
14437 python-hatchling
14438 python-pexpect
14439 python-pytest
14440 python-pytest-xdist
14441 python-setuptools
14442 python-sybil
14443 python-testfixtures))
14444 (home-page "https://scrapy.org")
14445 (synopsis "High-level Web crawling and Web scraping framework")
14446 (description "Scrapy is a fast high-level web crawling and web
14447scraping framework, used to crawl websites and extract structured data
14448from their pages. It can be used for a wide range of purposes, from data
14449mining to monitoring and automated testing.")
14450 (license license:bsd-3)))
14451
14452(define sdmx-test-data
14453 (let* ((commit "cd7899341b46e179e9f19b638478d70197e12c74")
14454 (revision "1")
14455 (name "sdmx-test-data")
14456 (version (git-version "0" revision commit)))
14457 (origin
14458 (method git-fetch)
14459 (uri (git-reference
14460 (url "https://github.com/khaeru/sdmx-test-data")
14461 (commit commit)))
14462 (file-name (git-file-name name version))
14463 (sha256
14464 (base32 "1n9y83raxxpgljbi0wjj27lhmyn19fnc2325a6cchwsa3b65ywv7")))))
14465
14466(define-public python-sdmx1
14467 (package
14468 (name "python-sdmx1")
14469 (version "2.26.0")
14470 (source
14471 (origin
14472 (method git-fetch)
14473 (uri (git-reference
14474 (url "https://github.com/khaeru/sdmx")
14475 (commit (string-append "v" version))))
14476 (file-name (git-file-name name version))
14477 (sha256
14478 (base32 "096c60pxzcw71bc9fj3hpjprrdiia365rqalapxx56g6g1vkgka9"))))
14479 (build-system pyproject-build-system)
14480 (arguments
14481 (list
14482 #:test-flags
14483 #~(list
14484 ;; 804 passed, 122 skipped, 28 deselected, 23 xfailed, 1 xpassed, 3 warnings
14485 ;; XXX: 'Version' object has no attribute 'pre'
14486 "--ignore=sdmx/tests/model/test_version.py"
14487 ;; Most of these tests require network connection.
14488 "--ignore=sdmx/tests/test_client.py"
14489 "--ignore=sdmx/tests/test_sources.py"
14490 "--ignore=sdmx/tests/test_docs.py"
14491 "--ignore=sdmx/tests/test_session.py"
14492 "--ignore=sdmx/tests/writer/test_xml.py"
14493 "--ignore=sdmx/tests/reader/test_xml_v21.py"
14494 "--deselect=sdmx/tests/convert/test_pandas.py::test_dataset_constraint"
14495 ;; Wrong python-flaky version
14496 "--deselect=sdmx/tests/format/test_xml.py::test_install_schemas_in_user_cache"
14497 "--deselect=sdmx/tests/format/test_xml.py::test_install_schemas"
14498 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_from_v2_1_samples"
14499 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_from_v3_0_samples"
14500 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_invalid_doc"
14501 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_invalid_message_type"
14502 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_max_errors"
14503 ;; sqlite3.OperationalError
14504 "--deselect=sdmx/tests/util/test_requests.py::TestOfflineAdapter::test_raises")
14505 #:phases
14506 #~(modify-phases %standard-phases
14507 (add-after 'unpack 'fix-version
14508 (lambda _
14509 ;; versioningit needs git tags; patch pyproject.toml to use
14510 ;; static version and create _version.py directly.
14511 (substitute* "pyproject.toml"
14512 (("version.source = \"versioningit\"")
14513 "
14514[tool.hatch.version]
14515path = \"sdmx/_version.py\"")
14516 ((", \"versioningit\"")
14517 ""))
14518 (call-with-output-file "sdmx/_version.py"
14519 (lambda (port)
14520 (format port "__version__ = \"~a\"~%" #$version)))))
14521 (add-before 'check 'pre-check
14522 (lambda _
14523 (setenv "SDMX_TEST_DATA" #$sdmx-test-data)
14524 (setenv "HOME" (dirname (getcwd))))))))
14525 (propagated-inputs
14526 (list python-dateutil
14527 python-lxml
14528 python-pandas
14529 python-platformdirs
14530 python-requests))
14531 (native-inputs
14532 (list python-filelock
14533 python-flaky
14534 python-hatchling
14535 python-jinja2
14536 python-pyarrow
14537 python-pytest
14538 python-pytest-cov
14539 python-pytest-xdist
14540 python-requests-mock
14541 python-requests-cache
14542 python-responses))
14543 (home-page "https://sdmx1.readthedocs.io")
14544 (synopsis "Statistical Data and Metadata eXchange (SDMX) for Python")
14545 (description "This package provides a Python implementation of the
14546SDMX 2.1 and 3.0 standards for Statistical Data and Metadata eXchange.
14547These standards are developed and used by statistical agencies and
14548international organisations. This package can be used to:
14549@itemize
14550@item Explore and retrieve data available from SDMX-REST web services
14551operated by providers including the World Bank, International Monetary
14552Fund, Eurostat, OECD, and United Nations;
14553@item Read and write data and metadata in file formats including
14554SDMX-ML (XML), SDMX-JSON, and SDMX-CSV;
14555@item Convert data and metadata into @code{python-pandas} objects, for
14556use with the analysis, plotting, and other tools in the Python data
14557science ecosystem;
14558@item Apply the SDMX information model (IM) to structure and publish
14559your own data.
14560@end itemize")
14561 (license license:asl2.0)))
14562
14563(define-public python-jstyleson
14564 (let ((commit "8c47cc9e665b3b1744cccfaa7a650de5f3c575dd")
14565 (revision "0"))
14566 (package
14567 (name "python-jstyleson")
14568 (version (git-version "0.0.2" revision commit))
14569 (source
14570 (origin
14571 (method git-fetch)
14572 (uri (git-reference
14573 (url "https://github.com/linjackson78/jstyleson")
14574 (commit commit)))
14575 (file-name (git-file-name name version))
14576 (sha256
14577 (base32 "0r72mq7h294w5icpdbjd202w25kwr1dz7nh79f6m74xisc9cixia"))))
14578 (build-system pyproject-build-system)
14579 (native-inputs (list python-pytest python-setuptools))
14580 (home-page "https://github.com/linjackson78/jstyleson")
14581 (synopsis "JSON parser supporting js-style comments")
14582 (description
14583 "@code{jstyleson} is a Python library to parse JSON. Contrary to the
14584standard Python @code{json} library, it understands js-style comments.
14585Trailing comma is also supported.")
14586 (license license:expat))))
14587
14588(define-public python-html-text
14589 (package
14590 (name "python-html-text")
14591 (version "0.7.0")
14592 (source
14593 (origin
14594 (method url-fetch)
14595 (uri (pypi-uri "html_text" version))
14596 (sha256
14597 (base32 "10lixghras86av966ha9piqfl1iscf7nffg69dmz13sxjh371jrx"))))
14598 (build-system pyproject-build-system)
14599 (native-inputs
14600 (list python-pytest
14601 python-setuptools
14602 python-wheel))
14603 (propagated-inputs
14604 (list python-lxml
14605 python-lxml-html-clean))
14606 (home-page "https://github.com/TeamHG-Memex/html-text")
14607 (synopsis "Extract text from HTML")
14608 (description "HTML to Text is a Python library for extract text from HTML.
14609Contrary to other solution such as LXML or Beautiful Soup, the text extracted
14610with @code{html_text} does not contain elements such as JavaScript or inline
14611styles not normally visible to users. It also normalizes white space
14612characters in a smarter, more visually pleasing style.")
14613 (license license:expat)))
14614
14615(define-public python-mf2py
14616 (package
14617 (name "python-mf2py")
14618 (version "2.0.1")
14619 (source
14620 (origin
14621 (method git-fetch)
14622 (uri (git-reference
14623 (url "https://github.com/microformats/mf2py")
14624 (commit (string-append "v" version))))
14625 (file-name (git-file-name name version))
14626 (sha256
14627 (base32 "0ajnf0zrh1l48fvix9fbs1qvgbqhiljqnrm51rx44p7dbarpw4ls"))))
14628 (build-system pyproject-build-system)
14629 (native-inputs (list python-mock python-poetry-core python-pytest))
14630 (propagated-inputs
14631 (list python-beautifulsoup4 python-html5lib python-requests))
14632 (home-page "https://github.com/microformats/mf2py")
14633 (synopsis "Python Microformats2 parser")
14634 (description
14635 "This Python library provides a Microformats2 parser implementing the
14636full Microformats2 (mf2) specification, including backward compatibility with
14637Microformats1 (mf1).")
14638 (license license:expat)))
14639
14640(define-public python-wadllib
14641 (package
14642 (name "python-wadllib")
14643 (version "2.0.0")
14644 (source
14645 (origin
14646 (method url-fetch)
14647 (uri (pypi-uri "wadllib" version))
14648 (sha256
14649 (base32 "09vlfg4mzdmkqk6br7j8ms3116qk5am0nf4v1jkzwd7swhisznqy"))))
14650 (build-system pyproject-build-system)
14651 (arguments
14652 (list
14653 ;; XXX: Doctests are currently failing.
14654 #:tests? #f
14655 #:phases
14656 #~(modify-phases %standard-phases
14657 (replace 'check
14658 (lambda* (#:key tests? #:allow-other-keys)
14659 (if tests?
14660 (invoke "zope-testrunner" "--test-path=src")
14661 (format #t "test suite not run~%")))))))
14662 (native-inputs
14663 (list python-multipart python-setuptools python-zope-testrunner))
14664 (propagated-inputs (list python-lazr-uri))
14665 (home-page "https://launchpad.net/wadllib")
14666 (synopsis "Web Application Description Language (WADL) navigation library")
14667 (description "The @code{wadllib} Python library allows navigating HTTP
14668resources using Web Application Description Language (WADL) files as guides.")
14669 (license license:lgpl3)))
14670
14671(define-public python-zeep
14672 (package
14673 (name "python-zeep")
14674 (version "4.3.1")
14675 (source
14676 (origin
14677 (method url-fetch)
14678 (uri (pypi-uri "zeep" version))
14679 (sha256
14680 (base32 "0vm0asfak0pxfa9i753imcy72hk8gkxbj6pmw185b7dhw7lqalzl"))))
14681 (build-system pyproject-build-system)
14682 (arguments
14683 (list
14684 #:phases
14685 '(modify-phases %standard-phases
14686 (add-after 'unpack 'compatibility
14687 (lambda _
14688 ;; Relax requests-file requirement.
14689 (substitute* "pyproject.toml"
14690 (("\"requests-file.*\",")
14691 "\"requests-file\","))
14692 ;; httpx removed the "proxies" keyword. It's now either "mounts"
14693 ;; or "proxy". See https://github.com/encode/httpx/pull/2879.
14694 (substitute* "src/zeep/transports.py"
14695 (("proxies=") "proxy="))))
14696 ;; One test requires write access
14697 (add-before 'check 'set-HOME
14698 (lambda _ (setenv "HOME" (getcwd)))))))
14699 (propagated-inputs
14700 (list python-attrs
14701 python-isodate
14702 python-lxml
14703 python-platformdirs
14704 python-pytz
14705 python-requests
14706 python-requests-file
14707 python-requests-toolbelt))
14708 (native-inputs
14709 (list nss-certs-for-test
14710 python-freezegun
14711 python-pretend
14712 python-pytest
14713 python-pytest-asyncio
14714 python-pytest-httpx
14715 python-requests-mock
14716 python-setuptools
14717 python-wheel))
14718 (home-page "https://docs.python-zeep.org/en/stable/")
14719 (synopsis "Python SOAP client based on lxml / requests")
14720 (description "Zeep is a Python SOAP client. Highlights:
14721
14722@itemize
14723@item Build on top of @code{lxml} and @code{requests}.
14724@item Support for Soap 1.1, Soap 1.2 and HTTP bindings.
14725@item Support for WS-Addressing headers.
14726@item Support for WSSE (UserNameToken / x.509 signing).
14727@item Support for @code{asyncio} via @code{httpx}.
14728@item Experimental support for XOP messages.
14729@end itemize")
14730 (license license:expat)))
14731
14732(define-public python-http-client
14733 (package
14734 (name "python-http-client")
14735 (version "3.3.7")
14736 (source
14737 (origin
14738 (method git-fetch)
14739 (uri (git-reference
14740 (url "https://github.com/sendgrid/python-http-client")
14741 (commit version)))
14742 (file-name (git-file-name name version))
14743 (sha256
14744 (base32 "0z0ziw3f4zw5fj4spiwhhs2x8qs3i5999ry2p6a5sc8b1lkkj2zi"))))
14745 (build-system pyproject-build-system)
14746 (arguments
14747 (list
14748 #:test-backend #~'unittest
14749 #:phases
14750 #~(modify-phases %standard-phases
14751 (add-after 'unpack 'fix-tests
14752 (lambda _
14753 ;; The test expects the copyright to be updated each year.
14754 (substitute* "tests/test_daterange.py"
14755 (("time\\.strftime\\(\"%Y\"\\)") "2022")))))))
14756 (native-inputs
14757 (list python-setuptools))
14758 (home-page "https://github.com/sendgrid/python-http-client")
14759 (synopsis "HTTP REST client for Python")
14760 (description
14761 "This package provides access to any RESTful or RESTful-like API.")
14762 (license license:expat)))
14763
14764(define-public python-sendgrid
14765 (package
14766 (name "python-sendgrid")
14767 (version "6.9.7")
14768 (source
14769 (origin
14770 (method git-fetch)
14771 (uri (git-reference
14772 (url "https://github.com/sendgrid/sendgrid-python")
14773 (commit version)))
14774 (file-name (git-file-name name version))
14775 (sha256
14776 (base32 "0kvp4gm3bpcsj2mkv05pgvlcv1jlsfhcljcv61wz5kq9d273h7rg"))))
14777 (build-system pyproject-build-system)
14778 (arguments
14779 (list
14780 #:test-flags
14781 #~(list "--ignore=test/integ"
14782 ;; Network access is required.
14783 "--ignore=live_test.py")))
14784 (native-inputs
14785 (list python-pytest
14786 python-setuptools))
14787 (propagated-inputs
14788 (list python-cryptography
14789 python-http-client
14790 python-flask
14791 python-pyyaml
14792 python-six ;hard dependency
14793 python-starkbank-ecdsa
14794 python-werkzeug))
14795 (home-page "https://github.com/sendgrid/sendgrid-python/")
14796 (synopsis "SendGrid API library for Python")
14797 (description
14798 "The @code{sendgrid} Python library allows access to the
14799SendGrid Web API v3. Version 3+ of the library provides full support for all
14800SendGrid Web API v3 endpoints, including the new v3 /mail/send.")
14801 (license license:expat)))
14802
14803(define-public python-sse-starlette
14804 (package
14805 (name "python-sse-starlette")
14806 (version "3.4.4")
14807 (source
14808 (origin
14809 (method git-fetch)
14810 (uri (git-reference
14811 (url "https://github.com/sysid/sse-starlette")
14812 (commit (string-append "v" version))))
14813 (file-name (git-file-name name version))
14814 (sha256
14815 (base32 "0jzy3mjszl7fr524cggyf8k97x6jpykvmxldmm2ckmrqjpyj8jmz"))))
14816 (build-system pyproject-build-system)
14817 (arguments
14818 (list
14819 #:test-flags
14820 #~(list
14821 ;; XXX: Server fails to start.
14822 "--ignore=tests/experimentation/test_multiple_consumers_asyncio.py"
14823 "--ignore=tests/experimentation/test_multiple_consumers_threads.py"
14824 ;; XXX: Missing test dependency - testcontainers, Docker is required.
14825 "--ignore=tests/integration/test_multiple_consumers.py")))
14826 (native-inputs
14827 (list python-asgi-lifespan
14828 python-httpx
14829 python-portend
14830 python-pytest
14831 python-pytest-asyncio
14832 python-psutil
14833 python-setuptools
14834 python-tenacity
14835 python-uvicorn))
14836 (propagated-inputs
14837 (list python-anyio
14838 python-starlette))
14839 (home-page "https://github.com/sysid/sse-starlette")
14840 (synopsis "SSE plugin for Starlette")
14841 (description
14842 "This package provides SSE plugin for Starlette.")
14843 (license license:bsd-3)))
14844
14845(define-public python-sseclient-py
14846 (package
14847 (name "python-sseclient-py")
14848 (version "1.9.0")
14849 (source
14850 (origin
14851 (method git-fetch)
14852 (uri (git-reference
14853 (url "https://github.com/mpetazzoni/sseclient")
14854 (commit (string-append "sseclient-py-" version))))
14855 (file-name (git-file-name name version))
14856 (sha256
14857 (base32 "1yi2v8z89mygsr1vzyc4r3j7flr3jrh6a6kzqfdh86i5a5j5v280"))))
14858 (build-system pyproject-build-system)
14859 (native-inputs (list python-hatchling python-pytest))
14860 (arguments
14861 (list
14862 #:test-backend #~'unittest
14863 #:test-flags #~'("discover" "--verbose" "tests")))
14864 (home-page "https://github.com/mpetazzoni/sseclient")
14865 (synopsis "Pure-Python Server Side Events (SSE) client")
14866 (description
14867 "This package provides a Python client for SSE event sources that
14868seamlessly integrates with @code{urllib3} and @code{requests}.")
14869 (license license:asl2.0)))
14870
14871(define-public python-starlette
14872 (package
14873 (name "python-starlette")
14874 (version "0.49.1")
14875 (source (origin
14876 (method git-fetch)
14877 (uri (git-reference
14878 (url "https://github.com/encode/starlette")
14879 (commit version)))
14880 (file-name (git-file-name name version))
14881 (sha256
14882 (base32
14883 "0w9cyaxpc2p99hqrfw164iypacx3i1gsmn2z0xywgd21alva82ji"))))
14884 (build-system pyproject-build-system)
14885 (propagated-inputs (list python-anyio
14886 python-typing-extensions
14887 ;; [all] extra dependencies:
14888 python-itsdangerous
14889 python-jinja2
14890 python-multipart
14891 python-pyyaml
14892 python-requests))
14893 (native-inputs (list python-hatchling
14894 python-httpx
14895 python-pytest
14896 python-typing-extensions))
14897 (home-page "https://github.com/encode/starlette")
14898 (synopsis "Little ASGI library")
14899 (description
14900 "Starlette is a lightweight ASGI (Asynchronous Server Gateway
14901Interface) framework/toolkit for building async web services in Python.")
14902 (license license:bsd-3)))
14903
14904(define-public python-starsessions
14905 (package
14906 (name "python-starsessions")
14907 (version "1.3.0")
14908 (source (origin
14909 (method git-fetch)
14910 (uri (git-reference
14911 (url "https://github.com/alex-oleshkevich/starsessions")
14912 (commit (string-append "v" version))))
14913 (file-name (git-file-name name version))
14914 (sha256
14915 (base32
14916 "00dkdhp22vfmcn0w4y7f2ii8m1xj5i7409x58g3l8lvk6v5ng2nf"))))
14917 (build-system pyproject-build-system)
14918 (arguments
14919 (list
14920 #:test-flags
14921 ;; These tests require a running redis server
14922 '(list "--ignore=tests/backends/test_redis.py"
14923 ;; XXX: this failure indicates a real compatibility problem, but
14924 ;; it seems restricted to the tests only.
14925 ;; AttributeError: 'Cookies' object has no attribute
14926 ;; 'clear_session_cookies'
14927 "-k"
14928 (string-append "not test_session_clears_on_tab_close"
14929 ;; This fails because an error is not raised.
14930 " and not test_session_wants_secret_key"))
14931 #:phases
14932 '(modify-phases %standard-phases
14933 (add-after 'unpack 'compatibilitiy
14934 (lambda _
14935 ;; aioredis has been renamed
14936 (substitute* "starsessions/backends/redis.py"
14937 (("aioredis") "redis")))))))
14938 (propagated-inputs
14939 (list python-redis
14940 python-itsdangerous
14941 python-starlette))
14942 (native-inputs
14943 (list python-httpx
14944 python-poetry-core
14945 python-pytest
14946 python-pytest-asyncio
14947 python-requests))
14948 (home-page "https://github.com/alex-oleshkevich/starsessions")
14949 (synopsis "Pluggable session support for Starlette and FastAPI")
14950 (description
14951 "This package adds pluggable session backends and ships default
14952@code{InMemoryBackend} and @code{CookieBackend} implementations for Starlette
14953and FastAPI.")
14954 (license license:expat)))
14955
14956(define-public python-whereismyip
14957 (package
14958 (name "python-whereismyip")
14959 (version "0.1.0")
14960 (source
14961 (origin
14962 (method url-fetch)
14963 (uri (pypi-uri "whereismyip" version))
14964 (sha256
14965 (base32 "0psrlvax8249ccs2rvgdygpckzz22vxjcyzr2pql06d48k61gk54"))))
14966 (build-system pyproject-build-system)
14967 (arguments (list #:tests? #false)) ; There are no tests.
14968 (native-inputs (list python-setuptools))
14969 (home-page "https://pypi.org/project/whereismyip/")
14970 (synopsis "Queries multiple geolocation services until one succeeds")
14971 (description
14972 "This package provides a simple Python library that queries multiple geolocation
14973services until one succeeds.")
14974 (license license:gpl3)))
14975
14976(define-public python-whitenoise
14977 (package
14978 (name "python-whitenoise")
14979 (version "6.12.0")
14980 (source
14981 (origin
14982 (method git-fetch)
14983 (uri (git-reference
14984 (url "https://github.com/evansd/whitenoise")
14985 (commit version)))
14986 (file-name (git-file-name name version))
14987 (sha256
14988 (base32 "1v4hdglf0zhvc1d6h836myz8pnxyp3x2r6j1amvqvxq8gbzrmp58"))))
14989 (build-system pyproject-build-system)
14990 (arguments
14991 (list
14992 #:test-flags #~(list "-k" "not test_modified"))) ; HTTP 304 error
14993 (native-inputs
14994 (list python-brotli
14995 python-django-minimal
14996 python-requests
14997 python-pytest
14998 python-setuptools))
14999 (home-page "https://github.com/evansd/whitenoise")
15000 (synopsis "Static file serving for WSGI applications")
15001 (description
15002 "WhiteNoise allows your web app to serve its own static files, making it
15003a self-contained unit that can be deployed anywhere without relying on nginx,
15004Amazon S3 or any other external service.")
15005 (license license:expat)))
15006
15007(define-public python-suds
15008 (package
15009 (name "python-suds")
15010 (version "1.2.0")
15011 (source
15012 (origin
15013 (method url-fetch)
15014 (uri (pypi-uri "suds" version))
15015 (sha256
15016 (base32 "1byyg7b2ixpr8hc849a6dd0qn5daxqawz6lb3php8lrmsb1n5cc3"))))
15017 (build-system pyproject-build-system)
15018 (arguments
15019 (list #:phases
15020 #~(modify-phases %standard-phases
15021 ;; XXX: chirp expects suds instead of suds_community
15022 (add-after 'install 'add-custom-dist-info
15023 (lambda _
15024 (for-each
15025 (lambda (dir)
15026 (with-directory-excursion (dirname dir)
15027 (symlink
15028 (basename dir)
15029 (string-append "suds-" #$version ".dist-info"))))
15030 (find-files #$output
15031 (lambda (file stat)
15032 (string-suffix? ".dist-info" file))
15033 #:directories? #t)))))))
15034 (native-inputs
15035 (list python-pytest
15036 python-setuptools
15037 python-wheel))
15038 (home-page "https://github.com/suds-community/suds")
15039 (synopsis "Lightweight SOAP python client for consuming Web Services")
15040 (description
15041 "Suds is a lightweight SOAP-based web service client for Python.")
15042 (license license:lgpl3+)))
15043
15044(define-public python-fastapi
15045 (package
15046 (name "python-fastapi")
15047 (version "0.137.1")
15048 (source
15049 (origin
15050 (method url-fetch)
15051 (uri (pypi-uri "fastapi" version))
15052 (sha256
15053 (base32 "072lzn48rwf9rjix4nqb5ym6hnaj2fb3jxclilym7n9h89q608w2"))))
15054 (build-system pyproject-build-system)
15055 (arguments
15056 (list
15057 ;; tests: 1126 passed, 12 skipped, 2 deselected
15058 #:test-backend #~'custom
15059 #:test-flags
15060 #~(list
15061 ;; Cannot import 'scripts' with just 'pytest'.
15062 "-m" "pytest"
15063 ;; Needs strawberry and sqlmodel.
15064 "--ignore=tests/test_tutorial/"
15065 ;; Fails due to failure to capture stdout.
15066 "--ignore=tests/test_fastapi_cli.py")))
15067 (native-inputs
15068 (list python-anyio
15069 python-dirty-equals
15070 python-flask
15071 python-inline-snapshot
15072 python-pdm-backend
15073 ;; python-pwdlib
15074 python-pyjwt
15075 python-pytest
15076 python-pytest-timeout
15077 python-pytest-xdist
15078 python-sqlalchemy-2
15079 ;; python-sqlmodel
15080 python-types-orjson
15081 python-types-ujson))
15082 (propagated-inputs
15083 (list python-starlette
15084 python-pydantic
15085 python-typing-extensions
15086 python-annotated-doc
15087 ;; [optional]
15088 python-email-validator
15089 python-fastapi-cli
15090 ;; python-fastar
15091 python-httpx
15092 python-itsdangerous
15093 python-jinja2
15094 python-multipart
15095 python-orjson
15096 python-pydantic
15097 python-pydantic-extra-types
15098 python-pydantic-settings
15099 python-pyyaml
15100 python-ujson
15101 python-uvicorn))
15102 (home-page "https://github.com/fastapi/fastapi")
15103 (synopsis "Web framework based on type hints")
15104 (description "FastAPI provides a web API framework based on pydantic and
15105starlette.")
15106 (license license:expat)))
15107
15108;; A bare minimal package, mainly to use in tests and reduce closure size.
15109;; Tests are left out in the main package to slim down native-inputs and
15110;; propagated-inputs.
15111(define-public python-fastapi-minimal
15112 (package/inherit python-fastapi
15113 (name "python-fastapi-minimal")
15114 (arguments
15115 (substitute-keyword-arguments arguments
15116 ((#:tests? #t #t) #f)))
15117 (native-inputs
15118 (list python-pdm-backend))
15119 (propagated-inputs
15120 (list python-annotated-doc
15121 python-opentelemetry-api
15122 python-pydantic
15123 python-starlette
15124 python-typing-extensions
15125 python-typing-inspection))))
15126
15127(define-public python-fastapi-csrf-protect
15128 (package
15129 (name "python-fastapi-csrf-protect")
15130 (version "0.3.3")
15131 (source (origin
15132 (method git-fetch)
15133 (uri (git-reference
15134 (url "https://github.com/aekasitt/fastapi-csrf-protect")
15135 (commit (string-append "v" version))))
15136 (file-name (git-file-name name version))
15137 (sha256
15138 (base32
15139 "181yawlbpd4709mamsradr9zj0jrbp4qvwfvmggs80pd36iiwyy8"))))
15140 (build-system pyproject-build-system)
15141 (propagated-inputs
15142 (list python-fastapi python-itsdangerous
15143 python-pydantic))
15144 (native-inputs
15145 (list python-poetry-core
15146 python-pytest))
15147 (home-page "https://github.com/aekasitt/fastapi-csrf-protect")
15148 (synopsis "Cross-Site Request Forgery (XSRF) protection")
15149 (description
15150 "This package provides a stateless implementation of @dfn{Cross-Site
15151Request Forgery} (XSRF) Protection by using the Double Submit Cookie mitigation
15152pattern.")
15153 (license license:expat)))
15154
15155(define-public python-fastapi-pagination-minimal
15156 (package
15157 (name "python-fastapi-pagination-minimal")
15158 (version "0.15.15")
15159 (source (origin
15160 (method git-fetch)
15161 (uri (git-reference
15162 (url "https://github.com/uriyyo/fastapi-pagination")
15163 (commit version)))
15164 (file-name (git-file-name name version))
15165 (sha256
15166 (base32
15167 "0jfmk5m2yrki9rw9izci2fxamam45mk36gl77rwbd5hnngkqbahv"))))
15168 (build-system pyproject-build-system)
15169 ;; We run the tests in python-fastapi-pagination only.
15170 (arguments (list #:tests? #false))
15171 ;; These are the only required dependencies,
15172 ;; please add all optional dependencies to the
15173 ;; full python-fastapi-pagination below.
15174 (propagated-inputs (list python-fastapi python-pydantic))
15175 (native-inputs (list python-hatchling))
15176 (home-page "https://github.com/uriyyo/fastapi-pagination")
15177 (synopsis "FastAPI pagination library")
15178 (description "@code{fastapi-pagination} is a Python library designed to
15179simplify pagination in FastAPI applications. It provides a set of utility
15180functions and data models to help you paginate your database queries and
15181return paginated responses to your clients.")
15182 (license license:expat)))
15183
15184(define-public python-fastapi-pagination
15185 (package
15186 (inherit python-fastapi-pagination-minimal)
15187 (name "python-fastapi-pagination")
15188 (arguments
15189 (list
15190 #:test-flags
15191 #~(list "--asyncio-mode=auto"
15192 "--ignore=tests/ext"
15193 ;; Netwok access is required.
15194 "-k" (string-join
15195 (list "not test_optional_params[postgres-default]"
15196 "test_optional_params[postgres-limit-offset]"
15197 "test_optional_params[sqlite-default]"
15198 "test_optional_params[sqlite-limit-offset]")
15199 " and not "))
15200 #:phases
15201 '(modify-phases %standard-phases
15202 (add-after 'unpack 'patch-tests
15203 (lambda _
15204 ;; We don't have a package for python-cassandra or motor, but we
15205 ;; also don't need them as we only run the unit tests anyway.
15206 (substitute* "tests/conftest.py"
15207 (("from cassandra.*") "")
15208 (("from motor.*") "")))))))
15209 (propagated-inputs
15210 (modify-inputs (package-propagated-inputs
15211 python-fastapi-pagination-minimal)
15212 (prepend python-asyncpg
15213 python-databases
15214 python-django
15215 python-fastapi
15216 python-pydantic
15217 python-sqlalchemy
15218 (package
15219 (inherit python-tortoise-orm)
15220 (arguments
15221 (substitute-keyword-arguments (package-arguments
15222 python-tortoise-orm)
15223 ((#:phases phases '%standard-phases)
15224 `(modify-phases ,phases
15225 (delete 'sanity-check)))))
15226 (propagated-inputs
15227 (modify-inputs propagated-inputs
15228 (replace "python-aiosqlite" python-aiosqlite)))))))
15229 (native-inputs
15230 (list python-aiosqlite
15231 python-asgi-lifespan
15232 python-asyncpg
15233 python-dirty-equals
15234 python-faker
15235 python-hatchling
15236 python-httpx
15237 python-pytest
15238 python-pytest-asyncio
15239 python-sqlalchemy
15240 python-typing-extensions))
15241 (description
15242 (string-append (package-description python-fastapi-pagination-minimal)
15243 "
15244
15245This package, as opposed to @code{python-fastapi-pagination-minimal}, depends on
15246all available optional dependencies supported by mainline
15247@code{fastapi-pagination}."))))
15248
15249(define-public python-fastapi-cli
15250 (package
15251 (name "python-fastapi-cli")
15252 (version "0.0.7")
15253 (source
15254 (origin
15255 (method url-fetch)
15256 (uri (pypi-uri "fastapi_cli" version))
15257 (sha256
15258 (base32 "0pk0ldmymc25ys4v6mslzd5vsjh9r69hfylh2ljl29pmarcvdcq2"))))
15259 (build-system pyproject-build-system)
15260 ;; Tests require fastapi, which depends on this package.
15261 (arguments (list #:tests? #false))
15262 (propagated-inputs (list python-rich-toolkit python-typer python-uvicorn))
15263 (native-inputs
15264 (list python-inline-snapshot python-pdm-backend python-pytest))
15265 (home-page "https://pypi.org/project/fastapi-cli/")
15266 (synopsis
15267 "Run and manage FastAPI apps from the command line with FastAPI CLI")
15268 (description
15269 "FastAPI CLI is a command line program fastapi that you can use to serve
15270your FastAPI app, manage your FastAPI project, and more.")
15271 (license license:expat)))
15272
15273(define-public python-pyactiveresource
15274 (package
15275 (name "python-pyactiveresource")
15276 (version "2.2.2")
15277 (source
15278 (origin
15279 (method git-fetch)
15280 (uri (git-reference
15281 (url "https://github.com/Shopify/pyactiveresource")
15282 (commit (string-append "v" version))))
15283 (file-name (git-file-name name version))
15284 (sha256
15285 (base32 "03pw6fwqjn09fbd6xmng0arlz75pp6ykw25c8d1snp4bxlzkrwqf"))))
15286 (build-system pyproject-build-system)
15287 ;; XXX: The package is fine, but the tests started failing on [email protected].
15288 ;; The package is not actively maintained, consider removing it once leaf.
15289 (arguments (list #:tests? #f))
15290 (native-inputs
15291 (list python-dateutil python-pytest python-pyyaml python-setuptools))
15292 (propagated-inputs (list python-six))
15293 (home-page "https://github.com/Shopify/pyactiveresource/")
15294 (synopsis "ActiveResource for Python")
15295 (description
15296 "This package provides a Python port of the ActiveResource project.
15297
15298Active Resource attempts to provide a coherent wrapper object-relational
15299mapping for REST web services. It follows the same philosophy as Active
15300Record, in that one of its prime aims is to reduce the amount of code needed
15301to map to these resources. This is made possible by relying on a number of
15302code- and protocol-based conventions that make it easy for Active Resource to
15303infer complex relations and structures.")
15304 (license license:expat)))
15305
15306(define-public python-shopifyapi
15307 (package
15308 (name "python-shopifyapi")
15309 (version "12.7.0")
15310 (source
15311 (origin
15312 (method git-fetch)
15313 (uri (git-reference
15314 (url "https://github.com/Shopify/shopify_python_api")
15315 (commit (string-append "v" version))))
15316 (file-name (git-file-name name version))
15317 (sha256
15318 (base32 "11zjm3aspb247wwlmfmq6wwk6lv3xyv3lqnd78sczjg9anba3779"))))
15319 (build-system pyproject-build-system)
15320 (arguments
15321 (list
15322 #:test-flags
15323 #~'("-k"
15324 ;; Disable a failing test.
15325 "not test_raises_if_aud_doesnt_match_api_key")))
15326 (native-inputs (list python-mock python-pytest python-setuptools))
15327 (propagated-inputs (list python-pyactiveresource python-pyjwt
15328 python-pyyaml python-six))
15329 (home-page "https://github.com/Shopify/shopify_python_api")
15330 (synopsis "Shopify API for Python")
15331 (description
15332 "This package provides the Shopify API for Python.
15333
15334The ShopifyAPI library allows Python developers to programmatically access the
15335admin section of stores using an ActiveResource-like interface similar the
15336ruby Shopify API gem. The library makes HTTP requests to Shopify in order to
15337list, create, update, or delete resources (e.g. Order, Product, Collection).")
15338 (license license:expat)))
15339
15340(define-public python-pybadges
15341 (package
15342 (name "python-pybadges")
15343 (version "3.0.1")
15344 (source (origin
15345 (method git-fetch)
15346 (uri (git-reference
15347 (url "https://github.com/google/pybadges")
15348 (commit version)))
15349 (file-name (git-file-name name version))
15350 (sha256
15351 "1zgb9idz7m3mzf8wvik0gwmyrxp753axqjv2pab326cr5myj1s4b")))
15352 (build-system pyproject-build-system)
15353 (arguments
15354 (list
15355 #:test-flags
15356 #~'("-k"
15357 ;; Disable network dependent tests.
15358 "not test_changes and not test_not_image_url and not test_http_url")))
15359 (propagated-inputs (list python-jinja2 python-requests python-setuptools))
15360 (native-inputs (list python-flask
15361 python-fonttools
15362 python-pillow
15363 python-pytest
15364 python-wheel
15365 python-xmldiff))
15366 (home-page "https://github.com/google/pybadges")
15367 (synopsis "Generate Github-style badges on the command-line")
15368 (description
15369 "This package provides @code{python-pybadges}: a library and command-line
15370tool for generating Github-style badges as SVG images.")
15371 (license license:asl2.0)))
15372
15373(define-public python-grid5000
15374 (package
15375 (name "python-grid5000")
15376 (version "1.2.4")
15377 (source (origin
15378 (method git-fetch)
15379 (uri (git-reference
15380 (url "https://gitlab.inria.fr/msimonin/python-grid5000")
15381 (commit (string-append "v" version))))
15382 (file-name (git-file-name name version))
15383 (sha256
15384 "0px5dr6kn7i5dyy4g42vqap1zpkc4hdvg7prrxdkkl57lfhz5w61")))
15385 (build-system pyproject-build-system)
15386 (arguments
15387 (list #:tests? #f)) ; No tests.
15388 (native-inputs (list python-setuptools))
15389 (propagated-inputs (list python-requests python-ipython python-pyyaml))
15390 (home-page "https://pypi.org/project/python-grid5000/")
15391 (synopsis "Grid5000 python client")
15392 (description
15393 "python-grid5000 is a python package wrapping the Grid5000 REST API.
15394You can use it as a library in your python project or you can explore the
15395Grid5000 resources interactively using the embedded shell.")
15396 (license license:gpl3+)))
15397
15398(define-public python-pynetbox
15399 (package
15400 (name "python-pynetbox")
15401 (version "7.4.1")
15402 (source (origin
15403 (method url-fetch)
15404 (uri (pypi-uri "pynetbox" version))
15405 (sha256
15406 (base32
15407 "1hq0mqykwdsmcrj61fxxzdkpc7wnld4grhkcxy560ym79jbbb0iz"))))
15408 (build-system pyproject-build-system)
15409 (arguments
15410 (list
15411 #:test-flags
15412 ;; Integration tests depend on docker.
15413 '(list "--ignore=tests/integration")))
15414 (propagated-inputs (list python-packaging python-requests))
15415 (native-inputs
15416 (list python-pytest
15417 python-setuptools
15418 python-setuptools-scm
15419 python-wheel))
15420 (home-page "https://github.com/netbox-community/pynetbox")
15421 (synopsis "NetBox API client library")
15422 (description "Python module to query and edit data stored in a
15423@url{https://netbox.dev,NetBox} instance.")
15424 (license license:asl2.0)))
15425
15426(define-public python-waybackpack
15427 (package
15428 (name "python-waybackpack")
15429 (version "0.6.4")
15430 (source
15431 (origin
15432 (method url-fetch)
15433 (uri (pypi-uri "waybackpack" version))
15434 (sha256
15435 (base32 "16lcr2hv7gmp199fh3psrnv68j20pfxria8v6gchrpl1jqx9f923"))))
15436 (build-system pyproject-build-system)
15437 (arguments
15438 (list #:tests? #f)) ; would require network (and SSL certificates)
15439 (propagated-inputs (list python-requests))
15440 (native-inputs (list python-pytest python-setuptools python-wheel))
15441 (home-page "https://github.com/jsvine/waybackpack")
15442 (synopsis
15443 "Download the entire Wayback Machine archive for a given URL")
15444 (description
15445 "This package provides a library and a command-line tool that lets
15446you download the entire Wayback Machine archive for a given URL.")
15447 (license license:expat)))
15448
15449(define-public python-xyzservices
15450 (package
15451 (name "python-xyzservices")
15452 (version "2025.4.0")
15453 (source
15454 (origin
15455 (method url-fetch)
15456 (uri (pypi-uri "xyzservices" version))
15457 (sha256
15458 (base32 "1n096zg9bd4n6w6axcm16m9sxdkc6qy1mipva0scbyj86rqn9rvg"))))
15459 (build-system pyproject-build-system)
15460 (arguments
15461 (list
15462 #:test-flags #~(list "-m" "not request")))
15463 (native-inputs
15464 (list python-pytest
15465 python-mercantile
15466 python-requests
15467 python-setuptools
15468 python-setuptools-scm))
15469 (home-page "https://github.com/geopandas/xyzservices")
15470 (synopsis "Source of XYZ tiles providers")
15471 (description "@code{xyzservices} is a lightweight library providing a
15472repository of available XYZ services offering raster basemap tiles. The
15473repository is provided via Python API and as a compressed JSON file.")
15474 (license license:bsd-3)))
15475
15476(define-public s3cmd
15477 (package
15478 (name "s3cmd")
15479 (version "2.4.0")
15480 (source
15481 (origin
15482 (method git-fetch)
15483 (uri (git-reference
15484 (url "https://github.com/s3tools/s3cmd")
15485 (commit (string-append "v" version))))
15486 (file-name (git-file-name name version))
15487 (sha256
15488 (base32 "168c49d1v8r7azv66zz0w07jalf434c2jpg2xzads5jnxzmiy73k"))))
15489 (build-system pyproject-build-system)
15490 (arguments
15491 (list
15492 #:tests? #f ; XXX: Tests require network access.
15493 #:phases
15494 #~(modify-phases %standard-phases
15495 (add-after 'unpack 'hide-wrapping
15496 (lambda _
15497 (substitute* "S3/MultiPart.py"
15498 (("sys\\.argv\\[0\\]")
15499 "\"s3cmd\""))
15500 (substitute* "s3cmd"
15501 (("optparser\\.get_prog_name\\(\\)")
15502 "\"s3cmd\"")))))))
15503 (native-inputs (list python-setuptools))
15504 (inputs (list python-dateutil python-magic))
15505 (home-page "https://s3tools.org/s3cmd")
15506 (synopsis "Command line tool for S3-compatible storage services")
15507 (description
15508 "S3cmd is a command line tool for uploading, retrieving and managing data
15509in storage services that are compatible with the Amazon Simple Storage
15510Service (S3) protocol, including S3 itself. It supports rsync-like backup,
15511GnuPG encryption, and more. It also supports management of Amazon's
15512CloudFront content delivery network.")
15513 (license license:gpl2+)))