projects/guix·blob science-team · refs

14792 lines · 533.4 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;;;
93;;; This file is part of GNU Guix.
94;;;
95;;; GNU Guix is free software; you can redistribute it and/or modify it
96;;; under the terms of the GNU General Public License as published by
97;;; the Free Software Foundation; either version 3 of the License, or (at
98;;; your option) any later version.
99;;;
100;;; GNU Guix is distributed in the hope that it will be useful, but
101;;; WITHOUT ANY WARRANTY; without even the implied warranty of
102;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
103;;; GNU General Public License for more details.
104;;;
105;;; You should have received a copy of the GNU General Public License
106;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
107
108(define-module (gnu packages python-web)
109 #:use-module (gnu packages admin)
110 #:use-module (gnu packages base)
111 #:use-module (gnu packages bash)
112 #:use-module (gnu packages check)
113 #:use-module (gnu packages cmake)
114 #:use-module (gnu packages compression)
115 #:use-module (gnu packages curl)
116 #:use-module (gnu packages databases)
117 #:use-module (gnu packages django)
118 #:use-module (gnu packages dns)
119 #:use-module (gnu packages freedesktop)
120 #:use-module (gnu packages glib)
121 #:use-module (gnu packages gnupg)
122 #:use-module (gnu packages graphviz)
123 #:use-module (gnu packages groff)
124 #:use-module (gnu packages iso-codes)
125 #:use-module (gnu packages libevent)
126 #:use-module (gnu packages libffi)
127 #:use-module (gnu packages libidn)
128 #:use-module (gnu packages linux)
129 #:use-module (gnu packages lsof)
130 #:use-module (gnu packages node)
131 #:use-module (gnu packages nss)
132 #:use-module (gnu packages openstack)
133 #:use-module (gnu packages pcre)
134 #:use-module (gnu packages pkg-config)
135 #:use-module (gnu packages protobuf)
136 #:use-module (gnu packages python)
137 #:use-module (gnu packages python-build)
138 #:use-module (gnu packages python-check)
139 #:use-module (gnu packages python-compression)
140 #:use-module (gnu packages python-crypto)
141 #:use-module (gnu packages python-science)
142 #:use-module (gnu packages python-xyz)
143 #:use-module (gnu packages qt)
144 #:use-module (gnu packages rdf)
145 #:use-module (gnu packages rpc)
146 #:use-module (gnu packages rust)
147 #:use-module (gnu packages rust-apps)
148 #:use-module (gnu packages serialization)
149 #:use-module (gnu packages sphinx)
150 #:use-module (gnu packages texinfo)
151 #:use-module (gnu packages time)
152 #:use-module (gnu packages tls)
153 #:use-module (gnu packages version-control)
154 #:use-module (gnu packages web)
155 #:use-module (gnu packages xml)
156 #:use-module (gnu packages)
157 #:use-module (guix build-system cargo)
158 #:use-module (guix build-system copy)
159 #:use-module (guix build-system pyproject)
160 #:use-module (guix deprecation)
161 #:use-module (guix download)
162 #:use-module (guix gexp)
163 #:use-module (guix git-download)
164 #:use-module ((guix licenses) #:prefix license:)
165 #:use-module (guix packages)
166 #:use-module (guix utils)
167 #:use-module (srfi srfi-1))
168
169(define-public python-aioboto3
170 (package
171 (name "python-aioboto3")
172 (version "15.5.0")
173 (source
174 (origin
175 (method git-fetch)
176 (uri (git-reference
177 (url "https://github.com/terricain/aioboto3")
178 (commit (string-append "v" version))))
179 (file-name (git-file-name name version))
180 (sha256
181 (base32 "05644x17f9sl8mv9bp8l0rjcmw5x2ssyd5z1v3xmgcspk5qs6qn8"))))
182 (build-system pyproject-build-system)
183 (arguments
184 (list
185 #:tests? #f ;XXX: all tests faild
186 #:phases
187 #~(modify-phases %standard-phases
188 (add-after 'unpack 'relax-requirements
189 (lambda _
190 (substitute* "pyproject.toml"
191 (("aiobotocore\\[boto3\\]==2.25.1")
192 "aiobotocore >= 2.25.1")))))))
193 (native-inputs
194 (list python-setuptools
195 python-setuptools-scm))
196 (propagated-inputs
197 (list python-aiobotocore
198 python-aiofiles
199 ;; [optional]
200 python-boto3
201 python-cryptography))
202 (home-page "https://github.com/terricain/aioboto3")
203 (synopsis "Async boto3 wrapper")
204 (description
205 "This package is mostly just a wrapper combining the great work of boto3
206and aiobotocore.")
207 (license license:asl2.0)))
208
209(define-public python-aiocoap
210 (package
211 (name "python-aiocoap")
212 (version "0.4.14")
213 (source
214 (origin
215 (method git-fetch) ; tests miss data and module files in PyPI release
216 (uri (git-reference
217 (url "https://github.com/chrysn/aiocoap")
218 (commit version)))
219 (file-name (git-file-name name version))
220 (sha256
221 (base32 "0yxvcg5llgmccv0a9hfm4nr7zxv9al4wh257m95a06g5c52v6hxz"))))
222 (build-system pyproject-build-system)
223 (arguments
224 (list
225 #:test-flags
226 ;; OSError: [Errno 98] error while attempting to bind on address ('::1',
227 ;; 8683, 0, 0): address already in use
228 #~(list "--ignore=tests/test_server.py"
229 "-k" (string-join
230 ;; TypeError: can only concatenate str (not "NoneType") to
231 ;; str
232 (list "not test_options"
233 "test_uri_parser"
234 "test_help" ; returned non-zero exit status 1.
235 "test_routing" ; address already in use
236 "test_tls")
237 " and not "))))
238 (native-inputs
239 (list openssl ;for tests/test_tls.py
240 python-pytest
241 python-setuptools
242 python-wheel))
243 (propagated-inputs
244 (list ;; python-cbor-diag
245 python-cbor2
246 python-cryptography
247 ;; python-dtlssocket
248 python-filelock
249 ;; python-ge25519
250 python-pygments
251 python-termcolor
252 python-websockets))
253 (home-page "https://github.com/chrysn/aiocoap")
254 (synopsis "Python CoAP library")
255 (description
256 "The aiocoap package is an implementation of @url{@acronym{CoAP, the
257Constrained Application Protocol}, http://coap.space/}. It facilitates
258writing applications that talk to network enabled embedded
259@acronym{IoT,Internet of Things} devices.")
260 (license license:expat)))
261
262(define-public python-alpaca-py
263 (package
264 (name "python-alpaca-py")
265 (version "0.43.2")
266 (source
267 (origin
268 (method git-fetch)
269 (uri (git-reference
270 (url "https://github.com/alpacahq/alpaca-py")
271 (commit (string-append "v" version))))
272 (file-name (git-file-name name version))
273 (sha256
274 (base32 "0majn27r2s2z5nbqvkpmw04kswhj9xkmvmm0rkvb3fga9lwwivlb"))))
275 (build-system pyproject-build-system)
276 (native-inputs
277 (list python-poetry-core
278 python-poetry-dynamic-versioning
279 python-pytest
280 python-pytest-asyncio
281 python-requests-mock))
282 (propagated-inputs
283 (list python-msgpack
284 python-pandas
285 python-pydantic
286 python-requests
287 python-sseclient-py
288 python-websockets))
289 (home-page "https://alpaca.markets/sdks/python/")
290 (synopsis "Alpaca API official Python SDK")
291 (description
292 "Alpaca-py provides an interface to REST, WebSocket and SSE endpoints
293that allow interaction with the @url{https://alpaca.markets/, Alpaca} API.")
294 (license license:asl2.0)))
295
296(define-public python-anaconda-client
297 (package
298 (name "python-anaconda-client")
299 (version "1.13.1")
300 (source
301 (origin
302 (method git-fetch)
303 (uri (git-reference
304 (url "https://github.com/Anaconda-Platform/anaconda-client")
305 (commit version)))
306 (file-name (git-file-name name version))
307 (sha256
308 (base32 "06nn3cwhrrajsbn9pils2539lzplfnyhn9java3xrpm3ksxq9g72"))))
309 (build-system pyproject-build-system)
310 (arguments
311 (list
312 #:test-flags
313 #~(list "--deselect=tests/utils/test_conda.py::test_find_conda"
314 "--deselect=tests/utils/test_conda.py::test_conda_vars")
315 #:phases
316 #~(modify-phases %standard-phases
317 (add-after 'unpack 'fix-pytest-config
318 (lambda _
319 (substitute* "setup.cfg"
320 (("addopts=.*") "addopts=\n")))))))
321 (native-inputs
322 (list python-freezegun
323 python-pytest
324 python-setuptools))
325 (propagated-inputs
326 (list python-anaconda-cli-base
327 python-conda-package-handling
328 python-conda-package-streaming
329 python-dateutil
330 python-defusedxml
331 python-nbformat
332 python-pillow
333 python-platformdirs
334 python-pytz
335 python-pyyaml
336 python-requests
337 python-requests-toolbelt
338 python-setuptools
339 python-tqdm
340 python-urllib3))
341 (home-page "https://github.com/Anaconda-Platform/anaconda-client")
342 (synopsis "Anaconda Cloud command line client library")
343 (description
344 "Anaconda Cloud command line client library provides an interface to
345Anaconda Cloud. Anaconda Cloud is useful for sharing packages, notebooks and
346environments.")
347 (license license:bsd-3)))
348
349(define-public python-apprise
350 (package
351 (name "python-apprise")
352 (version "1.9.4")
353 (source
354 (origin
355 (method url-fetch)
356 (uri (pypi-uri "apprise" version))
357 (sha256
358 (base32 "126951n9lnlqrw5lbsvs9xs7jzg33bqqxm7cfnqag2csw6p24ca8"))))
359 (build-system pyproject-build-system)
360 (arguments
361 (list
362 ;; These tests used to be ran with --numprocesses, but that seems to have
363 ;; made them non-deterministic.
364 #:test-flags
365 #~(list "--ignore=tests/test_plugin_macosx.py"
366 "-k" "not test_plugin_glib_send_raises_generic")))
367 (native-inputs
368 (list python-babel
369 python-pytest
370 python-pytest-mock
371 python-setuptools))
372 (propagated-inputs
373 (list python-certifi
374 python-click
375 python-markdown
376 python-pygobject
377 python-pyyaml
378 python-requests
379 python-requests-oauthlib))
380 (home-page "https://github.com/caronc/apprise")
381 (synopsis "Push notification library")
382 (description
383 "Apprise is a Python library that allows sending push notifications to a
384broad range of notification services, such as Telegram, Discord, Slack, Amazon
385SNS, Gotify, etc.")
386 (license license:bsd-2)))
387
388(define-public python-arxiv
389 (package
390 (name "python-arxiv")
391 (version "3.0.0")
392 (source
393 (origin
394 (method git-fetch)
395 (uri (git-reference
396 (url "https://github.com/lukasschwab/arxiv.py")
397 (commit version)))
398 (file-name (git-file-name name version))
399 (sha256
400 (base32 "18kn8q1lbql1w8jm5clla6za2zpijhs5hi2kpz41x5skps96lrd3"))))
401 (build-system pyproject-build-system)
402 (arguments
403 (list #:test-flags
404 #~(list "-k" ;to skip intenet connection tests
405 (string-append "not (TestAPIBugs "
406 "or TestClient "
407 "or TestResult "
408 "or TestDownload)"))))
409 (native-inputs
410 (list python-pytest
411 python-hatch-vcs
412 python-hatchling))
413 (propagated-inputs
414 (list python-feedparser
415 python-requests))
416 (home-page "https://github.com/lukasschwab/arxiv.py")
417 (synopsis "Python wrapper for the arXiv API")
418 (description "Python wrapper for the @code{arXiv} API.")
419 (license license:expat)))
420
421(define-public python-asyncer
422 (package
423 (name "python-asyncer")
424 (version "0.0.17")
425 (source
426 (origin
427 (method git-fetch)
428 (uri (git-reference
429 (url "https://github.com/fastapi/asyncer")
430 (commit version)))
431 (file-name (git-file-name name version))
432 (sha256
433 (base32 "1f4ids6sxwmz89yj98z0qc4qvfkklh0psbxv5px39k807g9aq7p2"))))
434 (build-system pyproject-build-system)
435 (native-inputs
436 (list python-pdm-backend
437 python-pytest))
438 (propagated-inputs
439 (list python-anyio
440 python-sniffio
441 python-typing-extensions))
442 (home-page "https://asyncer.tiangolo.com/")
443 (synopsis "Asyncer, async and await, focused on developer experience")
444 (description
445 "Asyncer is a small library built on top of
446@url{https://anyio.readthedocs.io/en/stable/, AnyIO}.
447
448The main goal of Asyncer is to improve developer experience by providing
449better support for autocompletion and inline errors in the editor, and more
450certainty that the code is bug-free by providing better support for type
451checking tools like mypy.")
452 (license license:expat)))
453
454(define-public python-asyncudp
455 (package
456 (name "python-asyncudp")
457 (version "0.11.0")
458 (source
459 (origin
460 (method git-fetch)
461 (uri (git-reference
462 (url "https://github.com/eerimoq/asyncudp")
463 (commit version)))
464 (file-name (git-file-name name version))
465 (sha256
466 (base32 "1i2s8mmmggzq6vk5aldz3g85jnqfbgxfqi60wl58jpn2lbr8fqlr"))))
467 (build-system pyproject-build-system)
468 (native-inputs (list python-pytest python-setuptools))
469 (home-page (git-reference-url (origin-uri source)))
470 (synopsis "High level UDP sockets for asyncio")
471 (description
472 "This package provides a Python library offering high level UDP sockets
473for asyncio. Import it alongside asyncio and use its API to send and receive
474UDP packets.")
475 (license license:expat)))
476
477(define-public python-behave-web-api
478 (package
479 (name "python-behave-web-api")
480 (version "2.3.0")
481 (source
482 (origin
483 (method git-fetch)
484 (uri (git-reference
485 (url "https://github.com/jefersondaniel/behave-web-api")
486 (commit (string-append "v" version))))
487 (file-name (git-file-name name version))
488 (sha256
489 (base32 "1r8yx8gb5m599cpdqfvk6z9ax3qj26fpvczdr84z8jya0dxfch4p"))))
490 (build-system pyproject-build-system)
491 (native-inputs
492 (list python-pytest
493 python-setuptools))
494 (propagated-inputs
495 (list behave
496 python-requests))
497 (home-page "https://github.com/jefersondaniel/behave-web-api")
498 (synopsis "Provides testing for JSON APIs with Behave for Python")
499 (description "This package provides testing utility modules for testing
500JSON APIs with Behave.")
501 (license license:expat)))
502
503(define-public python-blacksheep
504 (package
505 (name "python-blacksheep")
506 (version "2.6.3")
507 (source
508 (origin
509 (method git-fetch)
510 (uri (git-reference
511 (url "https://github.com/Neoteroi/BlackSheep")
512 (commit (string-append "v" version))))
513 (file-name (git-file-name name version))
514 (sha256
515 (base32 "1k6yqsqnh6nnhi8z5v2yqpxs7qsk35zwd7gcr7cdh825f2vrl7js"))))
516 (build-system pyproject-build-system)
517 (arguments
518 (list
519 ;; tests: 1821 passed
520 ;;
521 ;; Run all unit tests, but do not run integration tests from `itests`
522 ;; directory.
523 #:test-flags
524 #~(list "tests")
525 #:phases
526 #~(modify-phases %standard-phases
527 (add-before 'build 'cythonize
528 (lambda _
529 (with-directory-excursion "blacksheep"
530 (for-each (lambda (file)
531 (invoke "cython" "-3" file "-I" "."))
532 (find-files "." ".*\\.pyx$"))))))))
533 (native-inputs
534 (list nss-certs-for-test
535 python-cython
536 python-defusedxml
537 python-flask
538 python-jinja2
539 python-pydantic
540 python-pyjwt
541 python-pytest
542 python-pytest-asyncio
543 python-setuptools
544 python-starlette))
545 (propagated-inputs
546 (list python-certifi
547 python-essentials
548 python-essentials-openapi
549 python-guardpost
550 python-httptools
551 python-rodi
552 python-itsdangerous))
553 (home-page "https://github.com/Neoteroi/BlackSheep")
554 (synopsis "Asynchronous framework to build event based web applications")
555 (description
556 "BlackSheep is a lightweight, asynchronous, event driven Web framework.
557
558The framework offers
559@itemize
560@item A rich code API, based on dependency injection and inspired by Flask and
561ASP.NET Core.
562@item A typing-friendly codebase, which enables a comfortable development
563experience thanks to hints when coding with IDEs.
564@item Built-in generation of OpenAPI Documentation, supporting version 3, YAML,
565and JSON.
566@item A cross-platform framework, using the most modern versions of Python.
567@item Good performance.
568@end itemize")
569 (license license:expat)))
570
571(define-public python-bleach
572 (package
573 (name "python-bleach")
574 (version "6.3.0")
575 (source
576 (origin
577 (method git-fetch)
578 (uri (git-reference
579 (url "https://github.com/mozilla/bleach")
580 (commit (string-append "v" version))))
581 (file-name (git-file-name name version))
582 (sha256
583 (base32 "02abk9ixn010sqpbdsd7nxms0gv4prwv6d3nplb8giq85lpn1kkb"))
584 (snippet
585 #~(begin
586 (use-modules (guix build utils))
587 (substitute* (find-files "." "\\.py$")
588 (("bleach\\._vendor\\.html5lib") "html5lib"))
589 (delete-file-recursively "bleach/_vendor/html5lib")))))
590 (build-system pyproject-build-system)
591 (arguments
592 (list
593 ;; tests: 448 passed, 1 deselected, 3 xfailed
594 #:test-flags
595 #~(list (string-append "--deselect=tests/test_clean.py::"
596 "test_self_closing_tags_self_close[wbr]"))
597 #:phases
598 #~(modify-phases %standard-phases
599 (add-after 'unpack 'relax-requirements
600 (lambda _
601 ;; "tinycss2>=1.1.0,<1.5"
602 ;; The 'sanity-check of python-nbclassic fails without this.
603 (substitute* "setup.py"
604 (("\"tinycss2.*") "")))))))
605 (native-inputs
606 (list python-pytest
607 python-setuptools))
608 (propagated-inputs
609 (list python-html5lib
610 python-tinycss2
611 python-webencodings))
612 (home-page "https://github.com/mozilla/bleach")
613 (synopsis "Whitelist-based HTML-sanitizing tool")
614 (description "Bleach is an easy whitelist-based HTML-sanitizing tool.")
615 (license license:asl2.0)))
616
617(define-public python-cloudpathlib
618 (package
619 (name "python-cloudpathlib")
620 (version "0.23.0")
621 (source
622 (origin
623 (method git-fetch)
624 (uri (git-reference
625 (url "https://github.com/drivendataorg/cloudpathlib")
626 (commit (string-append "v" version))))
627 (file-name (git-file-name name version))
628 (sha256
629 (base32 "1dqwml269lpz51drgg3s27sqmvwa1vldw2rj34ssnqppcmc5h5lm"))))
630 (build-system pyproject-build-system)
631 (arguments
632 (list
633 ;; tests: 977 passed, 15 skipped, 8642 warnings
634 #:test-flags
635 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
636 ;; TODO: Package azure-identity (required for this file)
637 "--ignore=tests/test_azure_specific.py"
638 ;; TypeError: Retry.__init__() got an unexpected keyword
639 ;; argument 'timeout'
640 "--deselect=tests/test_gs_specific.py::test_timeout_and_retry")))
641 (native-inputs
642 (list ;; python-azure-identity
643 python-dotenv
644 python-flit-core
645 python-psutil
646 python-pydantic
647 python-pytest
648 python-pytest-cases
649 python-pytest-reportlog
650 python-pytest-xdist
651 python-shortuuid
652 python-tenacity))
653 (propagated-inputs
654 (list python-azure-storage-blob
655 python-azure-storage-file-datalake
656 python-boto3
657 python-google-cloud-storage
658 python-typing-extensions))
659 (home-page "https://github.com/drivendataorg/cloudpathlib")
660 (synopsis "Pathlib-style classes for cloud storage services")
661 (description
662 "This package provides a Python library with classes that mimic
663@code{pathlib.Path}'s interface for URIs from different cloud storage
664services.")
665 (license license:expat)))
666
667(define-public python-conda-package-handling
668 (package
669 (name "python-conda-package-handling")
670 (version "2.4.0")
671 (source
672 (origin
673 (method git-fetch)
674 (uri (git-reference
675 (url "https://github.com/conda/conda-package-handling/")
676 (commit version)))
677 (file-name (git-file-name name version))
678 (sha256
679 (base32 "1l2zbbwlxp9azpshixvxnb9354xajxkn88934grpwl70blgb3yq2"))))
680 (build-system pyproject-build-system)
681 (native-inputs
682 (list python-bottle
683 python-mock
684 python-pytest-8
685 python-pytest-mock
686 python-setuptools))
687 (propagated-inputs
688 (list python-conda-package-streaming))
689 (home-page "https://conda.io")
690 (synopsis "Create and extract conda packages of various formats")
691 (description
692 "This library is an abstraction of Conda package handling and a tool for
693extracting, creating, and converting between formats.")
694 (license license:bsd-3)))
695
696(define-public python-conda-package-streaming
697 (package
698 (name "python-conda-package-streaming")
699 (version "0.12.0")
700 (source
701 (origin
702 (method url-fetch)
703 (uri (pypi-uri "conda_package_streaming" version))
704 (sha256
705 (base32 "1fcyx83swx1wfndrl0vdk8c2pixshn54gkjy7xchkra13kw2yas2"))))
706 (build-system pyproject-build-system)
707 (arguments
708 ;; TODO: Cycles with python-conda-package-handling, implement bootstrap.
709 (list #:tests? #f))
710 (native-inputs
711 (list python-flit-core))
712 (propagated-inputs
713 (list python-requests
714 python-zstandard))
715 (home-page "https://conda.github.io/conda-package-streaming/")
716 (synopsis "Conda formats (@code{.conda}, @code{.tar.bz2}) reader library")
717 (description
718 "This package provides an efficient library to read from new and old format
719@code{.conda} and @code{.tar.bz2} conda packages.")
720 (license license:bsd-3)))
721
722(define-public python-dependency-groups
723 (package
724 (name "python-dependency-groups")
725 (version "1.3.1")
726 (source
727 (origin
728 (method url-fetch)
729 (uri (pypi-uri "dependency_groups" version))
730 (sha256
731 (base32 "1zgymnk6k984h2wfdpp0vws2ihwqrr9lmxhrij9zs5q5140q61vq"))))
732 (build-system pyproject-build-system)
733 (propagated-inputs (list python-packaging python-tomli))
734 (native-inputs (list python-flit-core python-pytest))
735 (home-page "https://dependency-groups.readthedocs.io/")
736 (synopsis "Tools and library for resolving PEP 735 Dependency Group data")
737 (description
738 "This package provides a library which is able to parse dependency groups (PEP
739735), following includes, and provide that data as output.")
740 (license license:expat)))
741
742(define-public python-devpi-common
743 (package
744 (name "python-devpi-common")
745 (version "4.0.4")
746 (source
747 (origin
748 (method url-fetch)
749 (uri (pypi-uri "devpi_common" version))
750 (sha256
751 (base32 "1k217b0fvsc7k2afw6wwlvqr1ksnv1vjzfm61g358vn98nd0lni3"))))
752 (build-system pyproject-build-system)
753 (propagated-inputs (list python-lazy python-packaging-legacy
754 python-requests))
755 (native-inputs
756 (list python-pytest
757 python-setuptools
758 python-wheel))
759 (home-page "https://github.com/devpi/devpi")
760 (synopsis
761 "Utilities jointly used by devpi-server, devpi-client and others")
762 (description
763 "This package provides utilities jointly used by devpi-server,
764devpi-client and others.")
765 (license license:expat)))
766
767(define-public python-devpi-client
768 (package
769 (name "python-devpi-client")
770 (version "7.2.0")
771 (source
772 (origin
773 (method url-fetch)
774 (uri (pypi-uri "devpi-client" version))
775 (sha256
776 (base32 "0ywx4ql8lsypb17n2miq39bmkrp232sdk8g6pskqp1y3b223chy1"))))
777 (build-system pyproject-build-system)
778 (arguments
779 (list
780 #:test-flags
781 ;; This wants to use pip install
782 '(list "--ignore=testing/test_upload.py"
783 ;; These complain about finding distutils. It's not my fault,
784 ;; mate, setuptools is right there, but you won't pick it!
785 "--ignore=testing/test_list_remove.py"
786 "--ignore=testing/test_main.py"
787 "--ignore=testing/test_install.py"
788 "--ignore=testing/test_functional.py"
789 "--ignore=testing/test_test.py")
790 #:phases
791 '(modify-phases %standard-phases
792 (add-after 'unpack 'patch-tests
793 (lambda _
794 ;; Do not replace the directory name of the store item.
795 (substitute* "testing/conftest.py"
796 (("\"devpi-server\", \"devpi-init\"")
797 "\"/bin/devpi-server\", \"/bin/devpi-init\""))))
798 (add-before 'check 'set-HOME
799 ;; Some tests need this
800 (lambda _ (setenv "HOME" "/tmp"))))))
801 (propagated-inputs (list python-pypa-build
802 python-check-manifest
803 python-colorama
804 python-devpi-common
805 python-iniconfig
806 python-pkginfo
807 python-platformdirs
808 python-pluggy
809 python-pypitoken
810 python-tomli))
811 (native-inputs
812 (list python-devpi-server
813 python-pytest
814 python-setuptools
815 python-virtualenv))
816 (home-page "https://github.com/devpi/devpi")
817 (synopsis "Devpi upload/install/... commands for Python developers")
818 (description
819 "The devpi command line tool is typically used in conjunction with
820devpi-server. It allows uploading, testing and installing packages from devpi
821indexes.")
822 (license license:expat)))
823
824(define-public python-devpi-process
825 (package
826 (name "python-devpi-process")
827 (version "1.0.2")
828 (source
829 (origin
830 (method url-fetch)
831 (uri (pypi-uri "devpi_process" version))
832 (sha256
833 (base32 "0v26i8bs0n8f2ikizwyvq77fw3l0nsyl4wj8yff0r3y351ydqbs1"))))
834 (build-system pyproject-build-system)
835 (arguments
836 (list
837 #:phases
838 '(modify-phases %standard-phases
839 (add-after 'unpack 'relax-requirements
840 (lambda _
841 ;; Our package is too old, sorry.
842 (substitute* "pyproject.toml"
843 (("typing-extensions>=4.12.2")
844 "typing-extensions>=4.10.0"))))
845 (add-after 'unpack 'patch-tool-locations
846 (lambda* (#:key inputs #:allow-other-keys)
847 (substitute* "src/devpi_process/__init__.py"
848 (("_exe\\(\"devpi-init\"\\)")
849 (string-append "\"" (search-input-file inputs "/bin/devpi-init") "\""))
850 (("_exe\\(\"devpi-server\"\\)")
851 (string-append "\"" (search-input-file inputs "/bin/devpi-server") "\""))
852 (("_exe\\(\"devpi\"\\)")
853 (string-append "\"" (search-input-file inputs "/bin/devpi") "\""))))))))
854 (propagated-inputs (list python-devpi-client python-devpi-server
855 python-typing-extensions))
856 (native-inputs
857 (list nss-certs-for-test
858 python-hatchling
859 python-hatch-vcs
860 python-httpx
861 python-pytest))
862 (home-page "https://github.com/devpi/devpi")
863 (synopsis "API to create and use a devpi server process")
864 (description
865 "This package provides a programmatic API to create and use a devpi
866server process.")
867 (license license:expat)))
868
869(define-public python-devpi-server
870 (package
871 (name "python-devpi-server")
872 (version "6.17.0")
873 (source
874 (origin
875 (method url-fetch)
876 (uri (pypi-uri "devpi_server" version))
877 (sha256
878 (base32 "13lybrw8j6zjxwvx6sk7bw6854hd2m18s1xcvl0q100j4n06p6ml"))))
879 (build-system pyproject-build-system)
880 (arguments
881 (list
882 #:test-flags
883 ;; These all fail with: "module 'py' has no attribute 'io'"
884 #~(list "--ignore=test_devpi_server/test_importexport.py"
885 "--ignore=test_devpi_server/test_main.py"
886 "--ignore=test_devpi_server/test_genconfig.py")
887 #:phases
888 #~(modify-phases %standard-phases
889 (add-after 'unpack 'relax-requirements
890 (lambda _
891 (substitute* "pyproject.toml"
892 ;; It straggles to check argon2 in passlib on any versions
893 ;; starting from 6.14.0: UnknownExtra("passlib 1.7.4 has no
894 ;; such extra feature 'argon2'",).
895 (("passlib\\[argon2\\]") "passlib")))))))
896 (propagated-inputs (list python-argon2-cffi
897 python-attrs
898 python-defusedxml
899 python-devpi-common
900 python-httpx
901 python-itsdangerous
902 python-lazy
903 python-legacy-cgi
904 python-passlib
905 python-platformdirs
906 python-pluggy
907 python-py
908 python-pyramid
909 python-repoze-lru
910 python-ruamel.yaml-0.16 ;FIXME: rename
911 python-strictyaml
912 python-waitress))
913 (native-inputs
914 (list python-execnet
915 python-pytest
916 python-pytest-asyncio
917 python-pytest-timeout
918 python-setuptools
919 python-webtest))
920 (home-page "https://devpi.net")
921 (synopsis "Pypi.org caching server")
922 (description "This package implements a reliable private and pypi.org
923caching server.")
924 (license license:expat)))
925
926(define-public python-dicomweb-client
927 (package
928 (name "python-dicomweb-client")
929 (version "0.60.0")
930 (source
931 (origin
932 (method git-fetch)
933 (uri (git-reference
934 (url "https://github.com/ImagingDataCommons/dicomweb-client")
935 (commit (string-append "v" version))))
936 (file-name (git-file-name name version))
937 (sha256
938 (base32 "1zad0905cc4jy4hnh9yhcw63bg25f7xa33x9rj9fhh5r4fznha8d"))))
939 (build-system pyproject-build-system)
940 (arguments
941 (list
942 #:phases
943 #~(modify-phases %standard-phases
944 (add-after 'unpack 'remove-dynamic-versioning
945 (lambda _
946 (substitute* "pyproject.toml"
947 ;; Dynamic versioning via 'uv-dynamic-versioning' is
948 ;; not suitable for Guix.
949 (("dynamic = \\[\"version\"\\]")
950 (string-append "version = \""
951 #$version "\""))))))))
952 (native-inputs
953 (list python-hatchling
954 python-pytest
955 python-pytest-localserver))
956 (propagated-inputs
957 (list python-numpy
958 python-pillow
959 python-pydicom
960 python-requests
961 python-retrying))
962 (home-page "https://github.com/ImagingDataCommons/dicomweb-client")
963 (synopsis "Python client for DICOMweb RESTful services")
964 (description
965 "@code{dicomweb_client} provides client interfaces for DICOMweb RESTful
966services QIDO-RS, WADO-RS and STOW-RS to search, retrieve and store
967DICOM objects over the web, respectively.")
968 (license license:expat)))
969
970(define-public python-dnslib
971 (package
972 (name "python-dnslib")
973 (version "0.9.26")
974 (source
975 (origin
976 (method git-fetch)
977 (uri (git-reference
978 (url "https://github.com/paulc/dnslib")
979 (commit version)))
980 (file-name (git-file-name name version))
981 (sha256
982 (base32 "1x1l727qx6x0kw7yhzhxhbm40wgrh367dr3y0vaix0wrhi30qsyk"))))
983 (build-system pyproject-build-system)
984 (arguments
985 (list
986 #:phases
987 #~(modify-phases %standard-phases
988 (replace 'check
989 (lambda* (#:key tests? #:allow-other-keys)
990 (when tests?
991 (invoke "./run_tests.sh")))))))
992 (native-inputs
993 (list python-setuptools))
994 (home-page "https://github.com/paulc/dnslib")
995 (synopsis "Library to encode/decode DNS wire-format packets")
996 (description
997 "This package provides a simple Python library to encode/decode DNS
998wire-format packets.")
999 (license license:bsd-3)))
1000
1001(define-public python-docusign-esign
1002 (package
1003 (name "python-docusign-esign")
1004 (version "5.0.0")
1005 (source
1006 (origin
1007 (method url-fetch)
1008 (uri (pypi-uri "docusign-esign" version))
1009 (sha256
1010 (base32 "18n9szjxbmsccz4vlvsl4xa73jn0y16l0c344m83gil25v2amn69"))))
1011 (build-system pyproject-build-system)
1012 ;; Testing requires undocumented setup changes with network access to
1013 ;; <demo.docusign.net>, and so testing is disabled here.
1014 (arguments `(#:tests? #f))
1015 (native-inputs
1016 (list python-setuptools
1017 python-wheel))
1018 (propagated-inputs
1019 (list python-certifi
1020 python-dateutil
1021 python-urllib3
1022 python-pyjwt
1023 python-cryptography))
1024 (home-page "https://developers.docusign.com/")
1025 (synopsis "DocuSign Python Client")
1026 (description
1027 "The Official DocuSign Python Client Library used to interact with the
1028eSign REST API. Send, sign, and approve documents using this client.")
1029 (license license:expat)))
1030
1031(define-public python-domain-connect
1032 (package
1033 (name "python-domain-connect")
1034 (version "0.0.11")
1035 (source
1036 (origin
1037 (method git-fetch) ;no tests in PyPI archive
1038 (uri (git-reference
1039 (url "https://github.com/Domain-Connect/domainconnect_python")
1040 (commit (string-append "v" version))))
1041 (file-name (git-file-name name version))
1042 (sha256
1043 (base32 "1dhqbx15h074g51mj73j9hlyvb11isjnj4s9ih5kbw1g4vf1q1jk"))))
1044 (build-system pyproject-build-system)
1045 (arguments
1046 (list
1047 ;; Check and sanity-check phases require /etc/resolv.conf, which is not
1048 ;; present in container.
1049 #:tests? #f
1050 #:phases #~(modify-phases %standard-phases (delete 'sanity-check))))
1051 (native-inputs
1052 (list python-setuptools))
1053 (propagated-inputs
1054 (list python-cryptography
1055 python-dnspython
1056 python-future
1057 python-publicsuffixlist))
1058 (home-page "https://github.com/Domain-Connect/domainconnect_python")
1059 (synopsis "Client library for Domain Connect protocol")
1060 (description
1061 "This package provides a Service Provider functionality in both Sync and
1062Async mode for @url{https://domainconnect.org/, Domain Connect protocol}.")
1063 (license license:expat)))
1064
1065(define-public python-domain-connect-dyndns
1066 (package
1067 (name "python-domain-connect-dyndns")
1068 (version "0.0.9")
1069 (source
1070 (origin
1071 (method url-fetch)
1072 (uri (pypi-uri "domain-connect-dyndns" version))
1073 (sha256
1074 (base32 "0srrblcb64bp7k5cqqivx4kykqdkmmzmspxwv66vix9k7wxdwqzx"))))
1075 (build-system pyproject-build-system)
1076 (arguments
1077 (list
1078 ;; Check and sanity-check phases require /etc/resolv.conf, which is not
1079 ;; present in container.
1080 #:tests? #f
1081 #:phases #~(modify-phases %standard-phases (delete 'sanity-check))))
1082 (native-inputs
1083 (list python-setuptools
1084 python-wheel))
1085 (propagated-inputs
1086 (list python-dnspython
1087 python-domain-connect
1088 python-requests
1089 python-validators))
1090 (home-page "https://github.com/Domain-Connect/DomainConnectDDNS-Python")
1091 (synopsis "Domain Connect Dynamic DNS in Python")
1092 ;; Project lacks meaningful description in README, see
1093 ;; <https://github.com/Domain-Connect/DomainConnectDDNS-Python/issues/43>.
1094 (description
1095 "Python client library for Dynamic DNS using
1096@url{https://www.domainconnect.org/, Domain Connect} protocol.")
1097 (license license:expat)))
1098
1099(define-public python-dominate
1100 (package
1101 (name "python-dominate")
1102 (version "2.9.1")
1103 (source
1104 (origin
1105 (method git-fetch)
1106 (uri (git-reference
1107 (url "https://github.com/Knio/dominate")
1108 (commit version)))
1109 (file-name (git-file-name name version))
1110 (sha256
1111 (base32 "0kv5ly8w2026pwvgamfjxav1g58wmgim30nr9w9qfwcipfjxwn5c"))))
1112 (build-system pyproject-build-system)
1113 (native-inputs
1114 (list python-pytest
1115 python-setuptools))
1116 (home-page "https://github.com/Knio/dominate")
1117 (synopsis "Python library for creating and manipulating HTML documents")
1118 (description
1119 "Dominate is a Python library for creating and manipulating HTML
1120documents using an elegant DOM API.")
1121 (license license:lgpl3+)))
1122
1123(define-public python-dropbox
1124 (package
1125 (name "python-dropbox")
1126 (version "12.0.2")
1127 (source
1128 (origin
1129 (method git-fetch) ; no tests in PyPI release
1130 (uri (git-reference
1131 (url "https://github.com/dropbox/dropbox-sdk-python")
1132 (commit (string-append "v" version))))
1133 (file-name (git-file-name name version))
1134 (sha256
1135 (base32 "0pyvi2mbibah42kq8804d98ghypm46wr8swqr34apnvnlp9j2nzl"))))
1136 (build-system pyproject-build-system)
1137 (arguments
1138 (list
1139 #:test-flags
1140 #~(list "-k" (string-join
1141 ;; Network access is required.
1142 (list "not test_bad_auth"
1143 "test_app_auth"
1144 "test_bad_pins"
1145 "test_bad_pins_session"
1146 "test_downscope"
1147 "test_multi_auth"
1148 "test_path_root"
1149 "test_path_root_err"
1150 "test_refresh"
1151 "test_rpc"
1152 "test_team"
1153 "test_upload_download"
1154 "test_versioned_route")
1155 " and not "))
1156 #:phases
1157 #~(modify-phases %standard-phases
1158 (add-after 'unpack 'relax-requirements
1159 (lambda _
1160 (substitute* "setup.py"
1161 ;; 'stone>=2,<3.3.3',
1162 ((">=2,<3.3.3") ">=2,<3.4.0"))))
1163 (add-before 'check 'pre-check
1164 (lambda _
1165 ;; Otherwise tests setup erroring.
1166 (setenv "LEGACY_USER_DROPBOX_TOKEN" "guix")
1167 (setenv "LEGACY_USER_CLIENT_ID" "guix")
1168 (setenv "LEGACY_USER_CLIENT_SECRET" "guix")
1169 (setenv "LEGACY_USER_REFRESH_TOKEN" "guix")
1170 (setenv "SCOPED_USER_DROPBOX_TOKEN" "guix")
1171 (setenv "SCOPED_USER_CLIENT_ID" "guix")
1172 (setenv "SCOPED_USER_CLIENT_SECRET" "guix")
1173 (setenv "SCOPED_USER_REFRESH_TOKEN" "guix")
1174 (setenv "SCOPED_TEAM_DROPBOX_TOKEN" "guix")
1175 (setenv "SCOPED_TEAM_CLIENT_ID" "guix")
1176 (setenv "SCOPED_TEAM_CLIENT_SECRET" "guix")
1177 (setenv "SCOPED_TEAM_REFRESH_TOKEN" "guix")
1178 (setenv "DROPBOX_SHARED_LINK" "guix"))))))
1179 (native-inputs
1180 (list nss-certs-for-test
1181 python-mock
1182 python-pytest
1183 python-pytest-mock
1184 python-setuptools
1185 python-wheel))
1186 (propagated-inputs
1187 (list python-requests python-six python-stone))
1188 (home-page "https://www.dropbox.com/developers")
1189 (synopsis "Official Dropbox API Client")
1190 (description "This package provides a Python SDK for integrating with the
1191Dropbox API v2.")
1192 (license license:expat)))
1193
1194(define-public python-dukpy
1195 (package
1196 (name "python-dukpy")
1197 (version "0.5.1")
1198 (source
1199 (origin
1200 (method git-fetch)
1201 (uri (git-reference
1202 (url "https://github.com/amol-/dukpy")
1203 (commit version)))
1204 (file-name (git-file-name name version))
1205 (sha256
1206 (base32 "1qsqfgy12frrdikjf353bsvhln11jixc3qs9rc1zra55k0569036"))))
1207 (build-system pyproject-build-system)
1208 (arguments
1209 (list
1210 #:test-flags
1211 #~(list #$@(map (lambda (test)
1212 (string-append "--deselect=tests/test_installer.py"
1213 "::TestPackageInstaller::"
1214 test))
1215 ;; Network access is required.
1216 (list "test_install_command"
1217 "test_install_command_latest_ver"
1218 "test_install_command_substrate_error"
1219 "test_install_command_without_dest"
1220 "test_install_react"
1221 "test_install_scoped_package"
1222 "test_install_unexisting_package"
1223 "test_install_unexisting_version")))))
1224 (native-inputs
1225 (list python-mock
1226 python-pytest
1227 python-setuptools
1228 python-webassets))
1229 (home-page "https://github.com/amol-/dukpy")
1230 (synopsis "Simple JavaScript interpreter for Python")
1231 (description
1232 "DukPy is a simple JavaScript interpreter for Python built on top of
1233duktape engine without any external dependency. It comes with a bunch of
1234common transpilers built-in for convenience:
1235@itemize
1236@item CoffeeScript
1237@item BabelJS
1238@item TypeScript
1239@item JSX
1240@item LESS
1241@end itemize")
1242 (license license:expat)))
1243
1244(define-public python-essentials-openapi
1245 (package
1246 (name "python-essentials-openapi")
1247 (version "1.2.1")
1248 (source
1249 (origin
1250 (method git-fetch)
1251 (uri (git-reference
1252 (url "https://github.com/Neoteroi/essentials-openapi")
1253 (commit (string-append "v" version))))
1254 (file-name (git-file-name name version))
1255 (sha256
1256 (base32 "0f3lhpkqhvv8sr1c34cvzdqkc61306m03w3jp0zdih1v6is05j8x"))))
1257 (build-system pyproject-build-system)
1258 (native-inputs
1259 (list python-flask
1260 python-hatchling
1261 python-pydantic
1262 python-pytest
1263 python-rich))
1264 (propagated-inputs
1265 (list python-essentials
1266 python-httpx
1267 python-jinja2
1268 python-markupsafe
1269 python-pyyaml))
1270 (home-page "https://github.com/Neoteroi/essentials-openapi/")
1271 (synopsis "Generator for OpenAPI Documentation")
1272 (description
1273 "Generator for OpenAPI Documentation version 2 and 3, in JSON and YAML
1274formats. Generator for other kinds of documents from OpenAPI Documentation
1275files.")
1276 (license license:expat)))
1277
1278(define-public python-eventlet
1279 (package
1280 (name "python-eventlet")
1281 (version "0.40.4")
1282 (source
1283 (origin
1284 (method url-fetch)
1285 (uri (pypi-uri "eventlet" version))
1286 (sha256
1287 (base32
1288 "0vzjrb7n3x7gdrxiw4dacdxvz0m8saaw9w7n1n9v865yn49gggk9"))))
1289 (build-system pyproject-build-system)
1290 (arguments
1291 (list
1292 #:test-flags
1293 '(list "-k"
1294 (string-append
1295 "not TestGetaddrinfo"
1296 " and not TestProxyResolver"
1297 " and not test_noraise_dns_tcp"
1298 " and not test_raise_dns_tcp"
1299 " and not test_hosts_no_network"
1300 " and not test_import_rdtypes_then_eventlet"
1301 " and not test_patcher_existing_locks"
1302 " and not test_dns_methods_are_green"))
1303 #:phases
1304 #~(modify-phases %standard-phases
1305 (add-after 'unpack 'avoid-OSError
1306 (lambda _
1307 ;; If eventlet tries to load greendns, an OSError is thrown when
1308 ;; getprotobyname is called. Thankfully there is an environment
1309 ;; variable to disable the greendns import, so use it. Note that
1310 ;; this error is propagated to child packages too, so enforce the
1311 ;; changed default.
1312 (substitute* "eventlet/green/socket.py"
1313 (("os\\.environ\\.get\\(\"EVENTLET_NO_GREENDNS\", ''\\)")
1314 "os.environ.get(\"EVENTLET_NO_GREENDNS\", \"yes\")")))))))
1315 (native-inputs
1316 (list python-hatchling
1317 python-hatch-vcs
1318 python-pytest))
1319 (propagated-inputs
1320 (list python-dnspython python-greenlet))
1321 (home-page "https://eventlet.net")
1322 (synopsis "Concurrent networking library for Python")
1323 (description
1324 "Eventlet is a concurrent networking library for Python that
1325allows you to change how you run your code, not how you write it.
1326It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O.
1327Coroutines ensure that the developer uses a blocking style of programming
1328that is similar to threading, but provide the benefits of non-blocking I/O.
1329The event dispatch is implicit, which means you can easily use @code{Eventlet}
1330from the Python interpreter, or as a small part of a larger application.
1331
1332Note: In Guix, this package assumes the environment variable
1333@code{EVENTLET_NO_GREENDNS} defaults to @code{yes}. To try to use it, set it
1334to anything else.")
1335 (license license:expat)))
1336
1337(define-public python-feedgen
1338 (package
1339 (name "python-feedgen")
1340 (version "1.0.0")
1341 (source
1342 (origin
1343 (method git-fetch)
1344 (uri (git-reference
1345 (url "https://github.com/lkiesow/python-feedgen")
1346 (commit (string-append "v" version))))
1347 (file-name (git-file-name name version))
1348 (sha256
1349 (base32
1350 "1ppwxp9yck29pk2p2dlrrad6rz16l9h4fhcajp9yb7ns94fm5v3l"))))
1351 (build-system pyproject-build-system)
1352 (propagated-inputs
1353 (list python-dateutil
1354 python-lxml))
1355 (native-inputs
1356 (list python-pytest
1357 python-setuptools))
1358 (home-page "https://feedgen.kiesow.be")
1359 (synopsis "Atom and RSS feed generator")
1360 (description
1361 "This module can be used to generate web feeds in both Atom and RSS
1362format. It also extensible and comes with an extension to produce podcasts.")
1363 ;; The README says that this package is released under both licenses, and
1364 ;; permits the user to choose whichever is more convenient to them.
1365 (license (list license:bsd-2
1366 license:lgpl3+))))
1367
1368(define-public python-flask-caching
1369 (package
1370 (name "python-flask-caching")
1371 (version "2.3.1")
1372 (source
1373 (origin
1374 (method url-fetch)
1375 (uri (pypi-uri "flask_caching" version))
1376 (sha256
1377 (base32 "1jcqgfzvqhgpngf9nhpfjs129cslh8jyczfy8kw11y7b9qdzvmv5"))))
1378 (build-system pyproject-build-system)
1379 (arguments
1380 (list
1381 #:test-flags
1382 ;; Tests requiring running Redis or dated python-cache.
1383 #~(list "--deselect=tests/test_init.py::test_init_nullcache[MemcachedCache]"
1384 "--deselect=tests/test_init.py::test_init_nullcache[RedisCache]"
1385 "--deselect=tests/test_init.py::test_init_nullcache[RedisSentinelCache]"
1386 "--deselect=tests/test_init.py::test_init_nullcache[SASLMemcachedCache]"
1387 "--deselect=tests/test_init.py::test_init_nullcache[SpreadSASLMemcachedCache]"
1388 "-k" "not test_client_override_reflected_on_cachelib_methods")))
1389 (native-inputs
1390 (list python-pytest
1391 python-pytest-asyncio
1392 python-pytest-xprocess
1393 python-setuptools))
1394 (propagated-inputs
1395 (list python-cachelib
1396 python-flask))
1397 (home-page "https://github.com/pallets-eco/flask-caching")
1398 (synopsis "Caching extension for Flask")
1399 (description
1400 "This package provides a caching support to Flask applications, it's a
1401fort ok https://github.com/thadeusb/flask-cache.")
1402 (license license:bsd-3)))
1403
1404(define-public python-flask-paginate
1405 (package
1406 (name "python-flask-paginate")
1407 (version "2024.4.12")
1408 (source
1409 (origin
1410 (method git-fetch)
1411 (uri (git-reference
1412 (url "https://github.com/lixxu/flask-paginate")
1413 (commit (string-append "v" version))))
1414 (file-name (git-file-name name version))
1415 (sha256
1416 (base32 "1q4ajwk0pzc6934g07gdryjcwi6rd9iqcwv5g5s718dfx2bj1831"))))
1417 (arguments
1418 (list #:test-backend #~'custom
1419 #:test-flags #~(list "tests/tests.py")))
1420 (build-system pyproject-build-system)
1421 (native-inputs
1422 (list python-pytest
1423 python-setuptools))
1424 (propagated-inputs
1425 (list python-flask))
1426 (home-page "https://github.com/lixxu/flask-paginate")
1427 (synopsis "Simple paginate support for Flask")
1428 (description
1429 "Flask-paginate is a simple pagination extension for Flask which is
1430inspired by Ruby's will_paginate library. It supports several CSS frameworks.")
1431 (license license:bsd-3)))
1432
1433(define-public python-flask-limiter
1434 (package
1435 (name "python-flask-limiter")
1436 (version "4.1.1")
1437 (source
1438 (origin
1439 (method git-fetch)
1440 (uri (git-reference
1441 (url "https://github.com/alisaifee/flask-limiter")
1442 (commit version)))
1443 (file-name (git-file-name name version))
1444 (sha256
1445 (base32 "18n12iayzw6qqys26824j5lfbphfcammpmyrvys1k0rn4xcbifln"))))
1446 (build-system pyproject-build-system)
1447 (arguments
1448 (list
1449 ;; tests: 155 passed, 620 deselected
1450 #:test-flags
1451 #~(list "-k" (simple-format #f "not (~a)"
1452 (string-join
1453 (append
1454 ;; The test suite spawns storages in Docker.
1455 '("memcache" "reset_unsupported")
1456 '("mongo")
1457 '("redis" "clear_limits"
1458 "constructor_arguments_over_config"
1459 "custom_key_prefix" "fallback_to_memory"))
1460 " or ")))
1461 #:phases
1462 #~(modify-phases %standard-phases
1463 (add-before 'check 'adjust-tests
1464 (lambda _
1465 (substitute* "pytest.ini"
1466 ((".*--cov=.*") ""))
1467 (substitute* (find-files "tests" "\\.py$")
1468 (("import pymemcache.*") "")
1469 (("import pymongo.*") "")
1470 (("import redis.*") "")))))))
1471 (native-inputs (list python-flask-restful
1472 python-hatch-vcs
1473 python-hatchling
1474 python-hiro
1475 python-pytest
1476 python-pytest-check
1477 python-pytest-mock))
1478 (propagated-inputs (list python-flask
1479 python-limits
1480 python-ordered-set
1481 python-rich))
1482 (home-page "https://flask-limiter.readthedocs.org/")
1483 (synopsis "Rate limiting for Flask applications")
1484 (description
1485 "Flask-Limiter adds rate limiting to Flask applications.
1486Rate limits can be configured at different levels such as:
1487
1488@itemize
1489@item Application wide global limits per user
1490@item Default limits per route
1491@item By blueprints
1492@item By class-based views
1493@item By individual routes
1494@end itemize")
1495 (license license:expat)))
1496
1497(define-public python-gdown
1498 (package
1499 (name "python-gdown")
1500 (version "5.2.0")
1501 (source
1502 (origin
1503 (method url-fetch)
1504 (uri (pypi-uri "gdown" version))
1505 (sha256
1506 (base32 "11y7xx6zjipx15a5626lhiwmwb2jxp4mdcwqrnij0mfqc981ci91"))))
1507 (build-system pyproject-build-system)
1508 (arguments (list #:tests? #f)) ;network access is required
1509 (native-inputs
1510 (list python-hatch-fancy-pypi-readme
1511 python-hatch-vcs
1512 python-hatchling))
1513 (propagated-inputs
1514 (list python-beautifulsoup4
1515 python-filelock
1516 python-requests
1517 python-tqdm))
1518 (home-page "https://github.com/wkentaro/gdown")
1519 (synopsis "Google Drive Public File/Folder Downloader")
1520 (description
1521 "This package implements a functionality to download large files
1522recursively from Google Drive with option to filter them by file
1523formats (PDF/XML/CSV).")
1524 (license license:expat)))
1525
1526(define-public python-globus-sdk
1527 (package
1528 (name "python-globus-sdk")
1529 (version "4.4.0")
1530 (source
1531 (origin
1532 (method git-fetch)
1533 (uri (git-reference
1534 (url "https://github.com/globus/globus-sdk-python")
1535 (commit version)))
1536 (file-name (git-file-name name version))
1537 (sha256
1538 (base32 "1d0zw9dkpdhsf9zdg3nk6b55gqwzc3v2rj76nj7999hjmq8350vh"))))
1539 (build-system pyproject-build-system)
1540 (arguments
1541 (list
1542 #:phases
1543 #~(modify-phases %standard-phases
1544 (add-before 'check 'pre-check
1545 (lambda _ (setenv "HOME" "/tmp"))))))
1546 (native-inputs
1547 (list python-flaky
1548 python-pytest
1549 python-pytest-randomly
1550 python-responses
1551 python-setuptools))
1552 (propagated-inputs
1553 (list python-cryptography
1554 python-importlib-resources
1555 python-pyjwt
1556 python-requests))
1557 (home-page "https://github.com/globus/globus-sdk-python")
1558 (synopsis "Globus SDK for Python")
1559 (description
1560 "This package provides a SDK for convenient Pythonic interface to
1561@url{https://www.globus.org/, Globus} APIs.")
1562 (license license:asl2.0)))
1563
1564(define-public python-guardpost
1565 (package
1566 (name "python-guardpost")
1567 (version "1.0.4")
1568 (source
1569 (origin
1570 (method git-fetch)
1571 (uri (git-reference
1572 (url "https://github.com/Neoteroi/guardpost")
1573 (commit (string-append "v" version))))
1574 (file-name (git-file-name name version))
1575 (sha256
1576 (base32 "1xsakqn36g2h1s5rnbaf1lasx1jn4skqhmb8kdl1k4pgxp5sczyy"))))
1577 (build-system pyproject-build-system)
1578 (arguments
1579 (list
1580 ;; Possible timing issue, see:
1581 ;; <https://github.com/Neoteroi/GuardPost/issues/18>.
1582 #:test-flags '(list "--ignore=tests/test_jwts.py")))
1583 (native-inputs
1584 (list python-flask
1585 python-hatchling
1586 python-pytest
1587 python-pytest-asyncio))
1588 (propagated-inputs
1589 (list python-rodi
1590 ;; [optional]
1591 python-cryptography
1592 python-essentials
1593 python-pyjwt))
1594 (home-page "https://github.com/Neoteroi/GuardPost/")
1595 (synopsis
1596 "Authentication and authorization framework for Python applications")
1597 (description
1598 "GuardPost is a framework to handle authentication and
1599authorization in asynchronous Python applications.
1600
1601Its features include
1602
1603@itemize
1604@item Strategy to implement authentication.
1605@item Strategy to implement authorization.
1606@item Support for dependency injection
1607@item Built-in support for JSON Web Tokens (JWTs) authentication.
1608@end itemize")
1609 (license license:expat)))
1610
1611(define-public python-habanero
1612 (package
1613 (name "python-habanero")
1614 (version "2.3.0")
1615 (source
1616 (origin
1617 (method git-fetch)
1618 (uri (git-reference
1619 (url "https://github.com/sckott/habanero")
1620 (commit (string-append "v" version))))
1621 (file-name (git-file-name name version))
1622 (sha256
1623 (base32 "1a842izcc8l4wb8004v92zsq1h4yc7qc2wi9am6x0f7idlx993sw"))))
1624 (build-system pyproject-build-system)
1625 (arguments
1626 ;; Run only a small portion of unit tests without network access
1627 ;; requirement.
1628 (list #:test-flags #~(list "test/test-filters.py")))
1629 (native-inputs
1630 (list python-hatchling
1631 python-pytest))
1632 (propagated-inputs
1633 (list python-httpx
1634 python-packaging
1635 python-tqdm
1636 python-urllib3))
1637 (home-page "https://github.com/sckott/habanero")
1638 (synopsis "Low Level Client for Crossref Search API")
1639 (description
1640 "Low Level Client for
1641@url{https://api.crossref.org/swagger-ui/index.html, Crossref Search API}.")
1642 (license license:expat)))
1643
1644(define-public python-hookdns
1645 (package
1646 (name "python-hookdns")
1647 (version "2.0.0")
1648 (source
1649 (origin
1650 (method url-fetch)
1651 (uri (pypi-uri "hookdns" version))
1652 (sha256
1653 (base32 "087x12dy6slhyqwqblby2fpjdcy61yk3lqp3fplami0rmbn02fb7"))))
1654 (build-system pyproject-build-system)
1655 (arguments
1656 (list
1657 #:test-flags
1658 #~(list "-k" (string-join
1659 ;; Tests requiring networking.
1660 (list
1661 "not test_patch_contextmanager_with_another_hostname"
1662 "test_patch_contextmanager_with_another_hostname_ipv6"
1663 "test_patch_contextmanager_with_ipv4"
1664 "test_patch_contextmanager_with_name"
1665 "test_patch_contextmanager_with_public_fqdn_and_"
1666 "test_patch_contextmanager_with_unknown_hostname"
1667 "test_patch_decorator_with_another_hostname"
1668 "test_patch_decorator_with_another_hostname_ipv6"
1669 "test_patch_decorator_with_ipv4"
1670 "test_patch_decorator_with_name"
1671 "test_patch_decorator_with_public_fqdn_and_a_name_for_"
1672 "test_patch_decorator_with_unknown_hostname"
1673 "test_real_getaddrinfo_with_name_ipv6"
1674 "test_real_getaddrinfo_with_public_fqdn_ipv4"
1675 "test_real_getaddrinfo_with_public_fqdn_ipv6"
1676 "test_real_gethostbyname_ex_with_public_fqdn"
1677 "test_real_gethostbyname_with_public_fqdn"
1678 "test_real_requests_ip"
1679 "test_real_requests_name"
1680 "test_real_requests_with_public_fqdn"
1681 "test_reentrant")
1682 " and not "))))
1683 (native-inputs
1684 (list python-pytest
1685 python-requests
1686 python-setuptools
1687 python-wheel))
1688 (home-page "https://github.com/cle-b/hookdns")
1689 (synopsis "DNS resolution customization library")
1690 (description
1691 "HookDNS implements functionality that allows for modifying name
1692resolution in a Python script without any changes to the hosts file or the use
1693of a fake DNS resolver.")
1694 (license license:asl2.0)))
1695
1696(define-public python-httpcore2
1697 (package
1698 (name "python-httpcore2")
1699 (version "2.4.0")
1700 (source
1701 (origin
1702 (method git-fetch)
1703 (uri (git-reference
1704 (url "https://github.com/pydantic/httpx2")
1705 (commit (string-append "v" version))))
1706 (file-name (git-file-name name version))
1707 (sha256
1708 (base32 "05mql79icxigldzw01hs77jpgihvzjahvniwncb7ji2rqzhjr42g"))))
1709 (build-system pyproject-build-system)
1710 (arguments
1711 (list
1712 #:phases
1713 #~(modify-phases %standard-phases
1714 (add-after 'unpack 'preparation
1715 (lambda _
1716 (chdir "src/httpcore2")
1717 (copy-recursively "../../tests/httpcore2" "tests")
1718 (substitute* (find-files "tests" "\\.py$")
1719 (("tests\\.httpcore2") "tests")
1720 (("tests/httpcore2") "tests"))))
1721 (add-before 'build 'set-version
1722 (lambda _
1723 (substitute* "pyproject.toml"
1724 ((".*uv-dynamic-versioning>.*") "")
1725 (("source.*uv-dynamic-versioning.*") "source = 'vcs'"))
1726 (substitute* "httpcore2/__init__.py"
1727 ((".*= version\\(.*")
1728 (format #f "__version__ = ~s~%" #$version))))))))
1729 (native-inputs
1730 (list python-hatch-fancy-pypi-readme
1731 python-hatch-vcs
1732 python-hatchling
1733 python-pytest
1734 python-pytest-httpbin
1735 python-pytest-trio))
1736 (propagated-inputs
1737 (list python-h11
1738 python-truststore
1739 ;; [optional]
1740 python-anyio
1741 python-h2
1742 python-socksio
1743 python-trio))
1744 (home-page "https://github.com/pydantic/httpx2")
1745 (synopsis "Minimal low-level HTTP client")
1746 (description
1747 "The HTTP Core package provides a minimal low-level HTTP client, which
1748does one thing only. Sending HTTP requests.
1749
1750Some things HTTP Core does do:
1751@itemize
1752@item Sending HTTP requests.
1753@item Thread-safe / task-safe connection pooling.
1754@item HTTP(S) proxy & SOCKS proxy support.
1755@item Supports HTTP/1.1 and HTTP/2.
1756@item Provides both sync and async interfaces.
1757@item Async backend support for @code{asyncio} and @code{trio}.
1758@end itemize")
1759 (license license:bsd-3)))
1760
1761(define-public python-httpretty
1762 (package
1763 (name "python-httpretty")
1764 (version "1.1.4")
1765 (source
1766 (origin
1767 (method url-fetch)
1768 (uri (pypi-uri "httpretty" version))
1769 (sha256
1770 (base32 "0s1vjdaf3pk2xd0hvi5f7p3jm2rgwpbc734jdp9r50m1smfhxpi0"))))
1771 (build-system pyproject-build-system)
1772 (arguments
1773 (list
1774 #:test-flags
1775 ;; Only run Unit tests.
1776 #~(list "--ignore=tests/bugfixes"
1777 "--ignore=tests/functional"
1778 "--ignore=tests/pyopenssl"
1779 "-k" (string-join
1780 ;; Tests pattern failing with one of these errors:
1781 ;; AttributeError: '(str|bool|bytes|list|tuple)' object
1782 ;; has no attribute 'should'
1783 ;; AttributeError: 'function' object has no attribute
1784 ;; 'when'
1785 ;; AttributeError: 'AssertionBuilder' object has no
1786 ;; attribute 'should_not'
1787 (list "not fake_socket_passes_through"
1788 "fakesock_socket"
1789 "request_parse_body_when"
1790 "test_Entry_class_normalizes_headers"
1791 "test_has_request"
1792 "test_httpretty_should_raise_proper"
1793 "test_parse_request_line_connect"
1794 "test_request_parse_querystring"
1795 "test_request_string_representation"
1796 "test_request_stubs_internals")
1797 " and not "))))
1798 (native-inputs
1799 (list nss-certs-for-test
1800 python-freezegun
1801 python-mock
1802 python-pytest
1803 python-setuptools
1804 python-sure
1805 python-wheel))
1806 (home-page "https://httpretty.readthedocs.io")
1807 (synopsis "HTTP client mock for Python")
1808 (description
1809 "@code{httpretty} is a helper for faking web requests,inspired by Ruby's
1810@code{fakeweb}.")
1811 (license license:expat)))
1812
1813(define-public python-httpx2
1814 (package
1815 (name "python-httpx2")
1816 (version "2.4.0")
1817 (source
1818 (origin
1819 (method git-fetch)
1820 (uri (git-reference
1821 (url "https://github.com/pydantic/httpx2")
1822 (commit (string-append "v" version))))
1823 (file-name (git-file-name name version))
1824 (sha256
1825 (base32 "05mql79icxigldzw01hs77jpgihvzjahvniwncb7ji2rqzhjr42g"))))
1826 (arguments
1827 (list
1828 ;; tests: 1227 passed, 200 deselected
1829 #:test-flags
1830 ;; Networking tests.
1831 #~(list "-k" (string-join
1832 (list "not test_async_proxy_close[asyncio]"
1833 "test_async_proxy_close[trio]"
1834 "test_auth"
1835 "test_binary"
1836 "test_client_decode_text_using_autodetect"
1837 "test_client_decode_text_using_explicit_encoding"
1838 "test_follow_redirects"
1839 "test_get"
1840 "test_idna_url[http_with_custom_port]"
1841 "test_idna_url[http_with_port]"
1842 "test_idna_url[https_with_custom_port]"
1843 "test_idna_url[https_with_port]"
1844 "test_idna_url[https_without_port]"
1845 "test_idna_url[idna_label_after_ascii_label]"
1846 "test_idna_url[unicode_tr46_compat]"
1847 "test_json"
1848 "test_post"
1849 "test_redirects"
1850 "test_response_decode_text_using_autodetect"
1851 "test_sync_proxy_close"
1852 "test_url_malformed_idna_label_after_ascii_label"
1853 "test_url_mixed_valid_and_malformed_idna_labels"
1854 "test_verbose")
1855 " and not "))
1856 #:phases
1857 #~(modify-phases %standard-phases
1858 (add-after 'unpack 'preparation
1859 (lambda _
1860 (chdir "src/httpx2")
1861 (copy-recursively "../../tests/httpx2" "tests")
1862 (substitute* (find-files "tests" "\\.py$")
1863 (("tests\\.httpx2") "tests")
1864 (("tests/httpx2") "tests"))))
1865 (add-before 'build 'set-version
1866 (lambda _
1867 (substitute* "pyproject.toml"
1868 (("\"uv-dynamic-versioning>=0\\.8\\.0\"") "")
1869 (("source.*uv-dynamic-versioning.*") "source = 'vcs'")
1870 (("\\.uv-dynamic-versioning") ".vcs")))))))
1871 (build-system pyproject-build-system)
1872 (native-inputs
1873 (list python-chardet
1874 python-hatch-fancy-pypi-readme
1875 python-hatch-vcs
1876 python-hatchling
1877 python-pytest
1878 python-trustme
1879 python-uvicorn))
1880 (propagated-inputs
1881 (list python-anyio
1882 python-httpcore2
1883 python-idna
1884 python-truststore
1885 python-typing-extensions ;Python version < 3.13
1886 ;; [optional]
1887 python-brotli
1888 python-click
1889 python-h2
1890 python-pygments
1891 python-rich
1892 python-socksio
1893 python-zstandard))
1894 (home-page "https://github.com/pydantic/httpx2")
1895 (synopsis "The next generation HTTP client")
1896 (description
1897 "HTTPX2 is a fully featured HTTP client library for Python. It includes
1898an integrated command line client, has support for both HTTP/1.1 and HTTP/2,
1899and provides both sync and async APIs.")
1900 (license license:bsd-3)))
1901
1902(define-public python-jiter
1903 (package
1904 (name "python-jiter")
1905 (version "0.15.0")
1906 (source
1907 (origin
1908 (method git-fetch)
1909 (uri (git-reference
1910 (url "https://github.com/pydantic/jiter/")
1911 (commit (string-append "v" version))))
1912 (file-name (git-file-name name version))
1913 (sha256
1914 (base32 "1z2ljacsc64yykkxvjnq6rq4z56xwr8jhcw02ckv6b85kc66x63p"))))
1915 (build-system pyproject-build-system)
1916 (arguments
1917 (list
1918 #:imported-modules (append %cargo-build-system-modules
1919 %pyproject-build-system-modules)
1920 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
1921 (guix build pyproject-build-system)
1922 (guix build utils))
1923 #:phases
1924 #~(modify-phases %standard-phases
1925 (add-after 'unpack 'prepare-cargo-build-system
1926 (lambda args
1927 (for-each (lambda (phase)
1928 (format #t "Running cargo phase: ~a~%" phase)
1929 (apply (assoc-ref cargo:%standard-phases phase)
1930 #:cargo-target #$(cargo-triplet)
1931 args))
1932 '(prepare-rust-crates
1933 unpack-rust-crates
1934 configure
1935 check-for-pregenerated-files
1936 patch-cargo-checksums))))
1937 (add-after 'prepare-cargo-build-system 'chdir
1938 (lambda _
1939 (chdir "crates/jiter-python"))))))
1940 (native-inputs
1941 (append (list maturin
1942 python-dirty-equals
1943 python-pytest
1944 rust
1945 `(,rust "cargo"))
1946 (or (and=> (%current-target-system)
1947 (compose list make-rust-sysroot))
1948 '())))
1949 (inputs (cargo-inputs 'jiter))
1950 (home-page "https://github.com/pydantic/jiter/")
1951 (synopsis "Iterable JSON parser")
1952 (description
1953 "This package provides a fast Python iterable JSON parser, backed by Rust
1954libraries.")
1955 (license license:bsd-3)))
1956
1957(define-public python-justhtml
1958 (package
1959 (name "python-justhtml")
1960 (version "1.13.0")
1961 (source
1962 (origin
1963 (method git-fetch)
1964 (uri (git-reference
1965 (url "https://github.com/emilstenstrom/justhtml")
1966 (commit (string-append "v" version))))
1967 (file-name (git-file-name name version))
1968 (sha256
1969 (base32 "1hy5w3lr08sj3pivs46nnlfsvrd9ynmicxcrjk4sxbpg7411lyj5"))))
1970 (build-system pyproject-build-system)
1971 (native-inputs
1972 (list python-hatchling))
1973 (home-page "https://github.com/emilstenstrom/justhtml")
1974 (synopsis "Pure Python HTML5 parser")
1975 (description
1976 "JustHTML is a pure Python HTML5 parser. It has a simple API and does
1977not require C extensions or system dependencies.")
1978 (license license:expat)))
1979
1980(define-public python-huggingface-hub
1981 (package
1982 (name "python-huggingface-hub")
1983 (version "0.31.4")
1984 (source
1985 (origin
1986 (method git-fetch)
1987 (uri (git-reference
1988 (url "https://github.com/huggingface/huggingface_hub")
1989 (commit (string-append "v" version))))
1990 (file-name (git-file-name name version))
1991 (sha256
1992 (base32 "1rjkrmvvyzxlbnbndrg4v9qq39grn46c26zrdjgpf114gci5pwap"))))
1993 (build-system pyproject-build-system)
1994 (arguments
1995 (list
1996 #:test-flags
1997 ;; We don't have sentence_transformers...
1998 '(list "--ignore=contrib/sentence_transformers/test_sentence_transformers.py"
1999 ;; ...nor do we have InquirerPy...
2000 "--ignore=tests/test_command_delete_cache.py"
2001 ;; ...or timm...
2002 "--ignore=contrib/timm/test_timm.py"
2003 ;; ...or spacy_huggingface_hub
2004 "--ignore=contrib/spacy/test_spacy.py"
2005 ;; These all require internet access
2006 "--ignore=tests/test_cache_no_symlinks.py"
2007 "--ignore=tests/test_cache_layout.py"
2008 "--ignore=tests/test_commit_scheduler.py"
2009 "--ignore=tests/test_file_download.py"
2010 "--ignore=tests/test_hf_api.py"
2011 "--ignore=tests/test_hf_file_system.py"
2012 "--ignore=tests/test_inference_api.py"
2013 "--ignore=tests/test_inference_async_client.py"
2014 "--ignore=tests/test_inference_client.py"
2015 "--ignore=tests/test_inference_text_generation.py"
2016 "--ignore=tests/test_login_utils.py"
2017 "--ignore=tests/test_offline_utils.py"
2018 "--ignore=tests/test_repocard.py"
2019 "--ignore=tests/test_repository.py"
2020 "--ignore=tests/test_snapshot_download.py"
2021 "--ignore=tests/test_utils_cache.py"
2022 "--ignore=tests/test_utils_git_credentials.py"
2023 "--ignore=tests/test_utils_http.py"
2024 "--ignore=tests/test_utils_pagination.py"
2025 "--ignore=tests/test_webhooks_server.py"
2026 "-k" (string-append
2027 "not test_push_to_hub"
2028 " and not test_from_pretrained_model_id_only"
2029 " and not test_from_pretrained_model_id_and_revision"
2030 ;; These all require internet access
2031 " and not test_auth"
2032 " and not test_oauth"
2033 " and not test_utils_sha"
2034 " and not test_inference_providers"
2035 " and not test_xet"))
2036 #:phases
2037 '(modify-phases %standard-phases
2038 (add-before 'check 'pre-check
2039 ;; Some tests need to write to HOME.
2040 (lambda _ (setenv "HOME" "/tmp"))))))
2041 (propagated-inputs
2042 (list python-filelock
2043 python-fsspec
2044 python-packaging
2045 python-pyyaml
2046 python-requests
2047 python-tqdm
2048 python-typing-extensions))
2049 (native-inputs
2050 (list python-aiohttp
2051 python-fastapi
2052 python-jedi
2053 python-jinja2
2054 python-numpy
2055 python-pillow
2056 python-pydantic
2057 python-pytest
2058 python-pytest-asyncio
2059 python-pytest-env
2060 python-pytest-mock
2061 python-pytest-rerunfailures
2062 python-pytest-vcr
2063 python-pytest-xdist
2064 python-setuptools
2065 python-types-requests
2066 python-types-toml
2067 python-types-urllib3
2068 python-typing-extensions
2069 python-urllib3
2070 python-wheel))
2071 (home-page "https://huggingface.co/docs/huggingface_hub/")
2072 (synopsis "Client library for accessing the huggingface.co hub")
2073 (description
2074 "This package provides a client library to download and publish models,
2075datasets and other repos on the @url{huggingface.co} hub.")
2076 (license license:asl2.0)))
2077
2078(define-public python-kubernetes
2079 (package
2080 (name "python-kubernetes")
2081 (version "35.0.0")
2082 (source
2083 (origin
2084 (method url-fetch)
2085 (uri (pypi-uri "kubernetes" version))
2086 (sha256
2087 (base32 "1vh9bzq175fzv9av3v37lcfh37yzss2d9vxrb0a84fa2ji2d601x"))))
2088 (build-system pyproject-build-system)
2089 (arguments
2090 (list
2091 #:test-flags
2092 #~(list
2093 ;; The following tests expect a local running Kubernetes cluster.
2094 "--ignore=kubernetes/e2e_test"
2095 "--ignore=kubernetes/dynamic")))
2096 (native-inputs
2097 (list python-pytest
2098 python-setuptools))
2099 (propagated-inputs
2100 (list python-certifi
2101 python-dateutil
2102 python-durationpy
2103 python-google-auth
2104 python-pyyaml
2105 python-requests
2106 python-requests-oauthlib
2107 python-six ;XXX: hard dependency
2108 python-urllib3
2109 python-websocket-client))
2110 (home-page "https://github.com/kubernetes-client/python")
2111 (synopsis "Python client for Kubernetes")
2112 (description
2113 "This package provides an official Python client library for
2114@url{http://kubernetes.io, Kubernetes}.")
2115 (license license:asl2.0)))
2116
2117(define-public python-lazr-restfulclient
2118 (package
2119 (name "python-lazr-restfulclient")
2120 (version "0.14.6")
2121 (source
2122 (origin
2123 (method url-fetch)
2124 (uri (pypi-uri "lazr.restfulclient" version))
2125 (sha256
2126 (base32 "1nzzmp9aaaxh25jy3wm71cpf9dfw56s4g303c8a3nij874fjmwa3"))))
2127 (build-system pyproject-build-system)
2128 (arguments
2129 (list
2130 #:phases
2131 #~(modify-phases %standard-phases
2132 ;; Disable part of the test suite to avoid the lazr.authentication
2133 ;; requirement, which requires 'oauth', a Python 2 only library.
2134 (add-after 'unpack 'remove-some-checks
2135 (lambda _
2136 (with-directory-excursion "src/lazr/restfulclient/tests"
2137 (for-each delete-file '("test_oauth.py" "test_docs.py")))
2138 (substitute* "setup.py"
2139 (("\"(oauth|lazr\\.(authentication|restful>=0\\.11\\.0))\",")
2140 ""))))
2141 (replace 'check
2142 (lambda* (#:key tests? #:allow-other-keys)
2143 (if tests?
2144 (invoke "zope-testrunner" "--test-path=src")
2145 (format #t "test suite not run~%")))))))
2146 (native-inputs
2147 (list python-setuptools
2148 python-testtools
2149 python-wheel
2150 python-wsgi-intercept
2151 python-zope-testrunner))
2152 (propagated-inputs
2153 (list python-distro
2154 python-httplib2
2155 python-oauthlib
2156 python-pyparsing
2157 python-setuptools
2158 python-six
2159 python-wadllib))
2160 (home-page "https://launchpad.net/lazr.restfulclient")
2161 (synopsis "Web client Python library extending wadlib")
2162 (description "This package provides a programmable client library that
2163adds functionality on top of @code{wadlib}.")
2164 (license license:lgpl3+)))
2165
2166(define-public python-launchpadlib
2167 (package
2168 (name "python-launchpadlib")
2169 (version "2.1.0")
2170 (source
2171 (origin
2172 (method url-fetch)
2173 (uri (pypi-uri "launchpadlib" version))
2174 (sha256
2175 (base32 "0br4j76l83lvyrhm8psml9cqmdsn65rx48w1q1a0s1bmpf85ihml"))))
2176 (build-system pyproject-build-system)
2177 (arguments
2178 (list #:phases #~(modify-phases %standard-phases
2179 (add-before 'check 'set-home
2180 (lambda _
2181 ;; Tests require a writable home.
2182 (setenv "HOME" "/tmp"))))))
2183 (propagated-inputs
2184 (list python-httplib2 python-lazr-restfulclient python-lazr-uri))
2185 (native-inputs (list python-pytest python-testresources python-wadllib
2186 python-setuptools python-wheel))
2187 (home-page "https://documentation.ubuntu.com/launchpad")
2188 (synopsis "Python client library for Launchpad's web service")
2189 (description "@code{launchpadlib} is a Python library that allows
2190scripting Launchpad via its the web service API.")
2191 (license license:lgpl3+)))
2192
2193(define-public python-lazr-uri
2194 (package
2195 (name "python-lazr-uri")
2196 (version "1.0.7")
2197 (source
2198 (origin
2199 (method url-fetch)
2200 (uri (pypi-uri "lazr_uri" version))
2201 (sha256
2202 (base32 "1vm34pw8fksc6m8fnqwh215sqdlw546cxcdga93i2l746grzc37d"))))
2203 (build-system pyproject-build-system)
2204 (arguments
2205 (list
2206 #:phases
2207 #~(modify-phases %standard-phases
2208 (replace 'check
2209 (lambda* (#:key tests? #:allow-other-keys)
2210 (if tests?
2211 (invoke "zope-testrunner" "--test-path=src")
2212 (format #t "test suite not run~%")))))))
2213 (native-inputs (list python-setuptools python-zope-testrunner))
2214 (home-page "https://launchpad.net/lazr.uri")
2215 (synopsis "Python URI manipulation library")
2216 (description "This Python package provides a self-contained, easily
2217reusable library for parsing, manipulating, and generating URIs.")
2218 (license license:lgpl3)))
2219
2220(define-public python-ldaptor
2221 (package
2222 (name "python-ldaptor")
2223 (version "21.2.0")
2224 (source
2225 (origin
2226 (method url-fetch)
2227 (uri (pypi-uri "ldaptor" version))
2228 (sha256
2229 (base32 "0n53czn5pyh8923y282spdb7xc8c9rhn0n43bczanjjx6wcynjcc"))))
2230 (build-system pyproject-build-system)
2231 (arguments
2232 (list
2233 #:test-flags
2234 #~(list "-m" "twisted.trial"
2235 (string-append "-j" (number->string (parallel-job-count)))
2236 "ldaptor")
2237 #:phases
2238 #~(modify-phases %standard-phases
2239 (add-after 'unpack 'python-3.12-patch
2240 (lambda _
2241 (substitute* "ldaptor/config.py"
2242 (("SafeConfigParser")
2243 "ConfigParser"))))
2244 (add-before 'check 'disable-failing-tests
2245 (lambda _
2246 ;; Testing with Twisted 22.4 results in infinite loop creating
2247 ;; temporary config files, see
2248 ;; <https://github.com/twisted/ldaptor/issues/238>.
2249 (delete-file "ldaptor/test/test_config.py")))
2250 (replace 'check
2251 (lambda* (#:key tests? test-flags #:allow-other-keys)
2252 (when tests?
2253 (apply invoke "python" test-flags)))))))
2254 (native-inputs
2255 (list python-setuptools
2256 python-wheel))
2257 (propagated-inputs
2258 (list python-passlib
2259 python-pyopenssl
2260 python-service-identity ; to pass sanity check, for Twisted[tls]
2261 python-pyparsing
2262 python-twisted
2263 python-zope-interface))
2264 (home-page "https://github.com/twisted/ldaptor")
2265 (synopsis "Pure-Python Twisted library for LDAP")
2266 (description
2267 "This package provides a Python Twisted library for LDAP, which key
2268feaatures are:
2269@itemize
2270@item LDAP client logic
2271@item separately-accessible LDAP and BER protocol message generation/parsing
2272@item ASCII-format LDAP filter generation and parsing
2273@item LDIF format data generation
2274@item Samba password changing logic
2275@end itemize")
2276 (license license:expat)))
2277
2278(define-public python-legacy-cgi
2279 (package
2280 (name "python-legacy-cgi")
2281 (version "2.6.1")
2282 (source
2283 (origin
2284 (method url-fetch)
2285 (uri (pypi-uri "legacy_cgi" version))
2286 (sha256
2287 (base32 "0hksizyq7awmwh3337zy0rmj47x6b5igzam6ffj74gbwfjfakbgj"))))
2288 (build-system pyproject-build-system)
2289 (native-inputs (list python-poetry-core python-pytest))
2290 (home-page "https://github.com/jackrosenthal/legacy-cgi")
2291 (synopsis "Fork of the legacy standard library cgi and cgitb modules")
2292 (description
2293 "This is a fork of the standard library modules @code{cgi} and
2294@code{cgitb}. They are slated to be removed from the Python standard library
2295in Python 3.13 by PEP-594.")
2296 (license license:psfl)))
2297
2298(define-public python-librouteros
2299 (package
2300 (name "python-librouteros")
2301 (version "4.0.0")
2302 (source
2303 (origin
2304 (method git-fetch)
2305 (uri (git-reference
2306 (url "https://github.com/luqasz/librouteros")
2307 (commit version)))
2308 (file-name (git-file-name name version))
2309 (sha256
2310 (base32 "0in952b2idb5j8v6sxfm21gqbr5i5776w5ir0hdsxjrl2f29305v"))))
2311 (build-system pyproject-build-system)
2312 (arguments
2313 (list
2314 #:build-backend "hatchling.build"
2315 #:test-flags
2316 #~(list "tests/unit")))
2317 (native-inputs
2318 (list python-hatchling
2319 python-pytest
2320 python-pytest-asyncio
2321 python-stamina))
2322 (home-page "https://github.com/luqasz/librouteros")
2323 (synopsis "Python implementation of MikroTik RouterOS API")
2324 (description
2325 "This package implements MikroTik's @code{RouterOS} API.")
2326 (license license:gpl2+)))
2327
2328(define-public python-opentelemetry-api
2329 (package
2330 (name "python-opentelemetry-api")
2331 (version "1.37.0")
2332 (source
2333 (origin
2334 (method url-fetch)
2335 (uri (pypi-uri "opentelemetry_api" version))
2336 (sha256
2337 (base32 "19yr3hfwdc9sv8df4vydxcsxnpld3xi57siq4w8xanrm42qka1sl"))))
2338 (build-system pyproject-build-system)
2339 (propagated-inputs (list python-importlib-metadata
2340 python-typing-extensions))
2341 (native-inputs (list python-hatchling
2342 python-opentelemetry-test-utils-bootstrap))
2343 (home-page "https://opentelemetry.io/docs/languages/python/")
2344 (synopsis "OpenTelemetry Python API")
2345 (description "@code{OpenTelemetry} Python API.")
2346 (license license:asl2.0)))
2347
2348(define-public python-opentelemetry-api-bootstrap
2349 (hidden-package
2350 (package/inherit python-opentelemetry-api
2351 (name "python-opentelemetry-api-bootstrap")
2352 (arguments
2353 (list
2354 #:tests? #f))
2355 (native-inputs (list python-hatchling)))))
2356
2357(define-public python-opentelemetry-sdk
2358 (package
2359 (name "python-opentelemetry-sdk")
2360 (version "1.37.0")
2361 (source
2362 (origin
2363 (method url-fetch)
2364 (uri (pypi-uri "opentelemetry_sdk" version))
2365 (sha256
2366 (base32 "19fx8vf35kcss43i17zqngqhmglb36dnddasbdvfsgcm22f0i3nc"))))
2367 (build-system pyproject-build-system)
2368 (propagated-inputs (list python-opentelemetry-api
2369 python-opentelemetry-semantic-conventions
2370 python-typing-extensions))
2371 (native-inputs (list python-hatchling
2372 python-opentelemetry-test-utils-bootstrap
2373 python-pytest))
2374 (home-page "https://opentelemetry.io/docs/languages/python/")
2375 (synopsis "OpenTelemetry Python SDK")
2376 (description "@code{OpenTelemetry} Python SDK.")
2377 (license license:asl2.0)))
2378
2379(define-public python-opentelemetry-sdk-bootstrap
2380 (hidden-package
2381 (package/inherit python-opentelemetry-sdk
2382 (name "python-opentelemetry-sdk-bootstrap")
2383 (arguments (list #:tests? #f))
2384 (propagated-inputs (list python-opentelemetry-api-bootstrap
2385 python-opentelemetry-semantic-conventions-bootstrap))
2386 (native-inputs (list python-hatchling)))))
2387
2388(define-public python-opentelemetry-semantic-conventions
2389 (package
2390 (name "python-opentelemetry-semantic-conventions")
2391 (version "0.58b0")
2392 (source
2393 (origin
2394 (method url-fetch)
2395 (uri (pypi-uri "opentelemetry_semantic_conventions" version))
2396 (sha256
2397 (base32 "098czakcawikaspl46vy6vickw80mm2bnrspflrw8ya24r8nzm3b"))))
2398 (build-system pyproject-build-system)
2399 (propagated-inputs (list python-opentelemetry-api python-typing-extensions))
2400 (native-inputs (list python-hatchling))
2401 (home-page "https://opentelemetry.io/docs/languages/python/")
2402 (synopsis "OpenTelemetry Semantic Conventions")
2403 (description "@code{OpenTelemetry} Semantic Conventions.")
2404 (license license:asl2.0)))
2405
2406(define-public python-opentelemetry-semantic-conventions-bootstrap
2407 (hidden-package
2408 (package/inherit python-opentelemetry-semantic-conventions
2409 (name "python-opentelemetry-semantic-conventions-bootstrap")
2410 (arguments
2411 (list
2412 #:tests? #f))
2413 (propagated-inputs (list python-opentelemetry-api-bootstrap
2414 python-typing-extensions)))))
2415
2416(define-public python-opentelemetry-test-utils
2417 (package
2418 (name "python-opentelemetry-test-utils")
2419 (version "0.58b0")
2420 (source
2421 (origin
2422 (method url-fetch)
2423 (uri (pypi-uri "opentelemetry_test_utils" version))
2424 (sha256
2425 (base32 "0xjp04zjn7m79xsda9wp79rqyzy2c10347s967vp7xvmndwwa0ds"))))
2426 (build-system pyproject-build-system)
2427 (arguments (list #:tests? #f)) ; No tests in the wheel.
2428 (propagated-inputs
2429 (list python-asgiref
2430 python-opentelemetry-api
2431 python-opentelemetry-sdk))
2432 (native-inputs (list python-hatchling))
2433 (home-page "https://opentelemetry.io/docs/languages/python/")
2434 (synopsis "Test utilities for OpenTelemetry unit tests")
2435 (description "Test utilities for @code{OpenTelemetry} unit tests.")
2436 (license license:asl2.0)))
2437
2438(define-public python-opentelemetry-test-utils-bootstrap
2439 (hidden-package
2440 (package/inherit python-opentelemetry-test-utils
2441 (name "python-opentelemetry-test-utils-bootstrap")
2442 (propagated-inputs
2443 (list python-asgiref
2444 python-opentelemetry-api-bootstrap
2445 python-opentelemetry-sdk-bootstrap)))))
2446
2447(define-public python-pathy
2448 (package
2449 (name "python-pathy")
2450 (version "0.11.0")
2451 (source
2452 (origin
2453 (method url-fetch)
2454 (uri (pypi-uri "pathy" version))
2455 (sha256
2456 (base32 "0vbhcfg8g74g90bzmdgxr1jyvwhadvlr2w9wyvs6xxwb1dmhwgdv"))))
2457 (build-system pyproject-build-system)
2458 (native-inputs
2459 (list python-mock
2460 python-pytest
2461 python-setuptools))
2462 (propagated-inputs
2463 (list python-pathlib-abc-for-python-pathy
2464 python-smart-open-6
2465 python-typer))
2466 (home-page "https://github.com/justindujardin/pathy")
2467 (synopsis "Path interface for local and cloud bucket storage")
2468 (description "Pathy is a python package (with type annotations) for
2469working with Cloud Bucket storage providers using a @code{pathlib} interface.
2470It provides @code{pathlib.Path} subclasses for local and cloud bucket
2471storage.")
2472 (license license:asl2.0)))
2473
2474(define-public python-portend
2475 (package
2476 (name "python-portend")
2477 (version "3.2.1")
2478 (source
2479 (origin
2480 (method url-fetch)
2481 (uri (pypi-uri "portend" version))
2482 (sha256
2483 (base32 "12b4ikxyv32n33mvm4brp74igl1mvw825x01sjvvs54y3yml17da"))))
2484 (build-system pyproject-build-system)
2485 ;; Do not test pyproject.toml with python-pytest-checkdocs as it tries to
2486 ;; download dependencies.
2487 (arguments
2488 '(#:test-flags '("-k" "not project")))
2489 (native-inputs
2490 (list python-pytest
2491 python-setuptools
2492 python-setuptools-scm))
2493 (propagated-inputs
2494 (list python-tempora))
2495 (home-page "https://github.com/jaraco/portend")
2496 (synopsis "Monitor TCP ports for bound or unbound states")
2497 (description
2498 "@code{python-portend} can be used to monitor TCP ports for bound or
2499unbound states. For example, waiting for a port to be occupied or freed
2500within a set timeout. @code{python-portend} can also be used directly from
2501the command line.")
2502 (license license:expat)))
2503
2504(define-public python-prawcore
2505 (package
2506 (name "python-prawcore")
2507 (version "2.4.0")
2508 (source
2509 (origin
2510 (method git-fetch)
2511 (uri (git-reference
2512 (url "https://github.com/praw-dev/prawcore")
2513 (commit (string-append "v" version))))
2514 (file-name (git-file-name name version))
2515 (sha256
2516 (base32 "1y7gh7kk002b2h1ppkr1llb2gjfnby28zvx11j4ji0wm3r3rjh5l"))))
2517 (build-system pyproject-build-system)
2518 (arguments
2519 ;; XXX: These tests fail with an incomplete request response.
2520 (list #:test-flags
2521 #~'("-k" #$(string-append
2522 "not test_revoke__access_token_with_refresh_set"
2523 " and not test_revoke__access_token_without_refresh_set"
2524 " and not test_revoke__refresh_token_with_access_set"
2525 " and not test_refresh__with_scopes"
2526 " and not test_request__patch"))))
2527 (native-inputs
2528 (list python-betamax
2529 python-betamax-matchers
2530 python-betamax-serializers
2531 python-flit-core
2532 python-mock
2533 python-pytest
2534 python-testfixtures))
2535 (propagated-inputs
2536 (list python-requests))
2537 (synopsis "Core component of PRAW")
2538 (description "PRAWcore is a low-level communication layer used by PRAW.")
2539 (home-page "https://praw.readthedocs.io/en/latest/")
2540 (license license:bsd-2)))
2541
2542(define-public python-praw
2543 (package
2544 (name "python-praw")
2545 (version "7.8.1")
2546 (source
2547 (origin
2548 (method git-fetch)
2549 (uri (git-reference
2550 (url "https://github.com/praw-dev/praw")
2551 (commit (string-append "v" version))))
2552 (file-name (git-file-name name version))
2553 (sha256
2554 (base32 "05qq43l4334cq8r8k731qnb45nq12vvfdxwbr6q84a1hafp7n4cg"))))
2555 (build-system pyproject-build-system)
2556 (arguments
2557 (list #:test-flags
2558 #~(list "--ignore=tests/units/models"
2559 "--ignore=tests/integration/models"
2560 "--ignore=tests/unit/test_config.py"
2561 "--ignore=tests/integration/test_reddit.py")))
2562 (native-inputs
2563 (list python-betamax
2564 python-betamax-matchers
2565 python-flit-core
2566 python-pytest))
2567 (propagated-inputs
2568 (list python-prawcore python-update-checker python-websocket-client))
2569 (synopsis "Python Reddit API Wrapper")
2570 (description "PRAW is a Python package that allows for simple access to
2571Reddit’s API. It aims to be easy to use and internally follows all of Reddit’s
2572API rules.")
2573 (home-page "https://praw.readthedocs.io/en/latest/")
2574 (license license:bsd-2)))
2575
2576(define-public python-frozenlist
2577 (package
2578 (name "python-frozenlist")
2579 (version "1.8.0")
2580 (source
2581 (origin
2582 (method git-fetch)
2583 (uri (git-reference
2584 (url "https://github.com/aio-libs/frozenlist")
2585 (commit (string-append "v" version))))
2586 (file-name (git-file-name name version))
2587 (sha256
2588 (base32 "0r1kxf5b562zrn04nl912i6a8y1fyc891l1284v0zj9llb97limy"))))
2589 ;; XXX: Without "wheel", the 'install phase can't find the wheel.
2590 (outputs (list "out" "wheel"))
2591 (build-system pyproject-build-system)
2592 ;; The configuration contains explicit early calls to pytest_cov.
2593 (arguments (list #:test-flags #~(list "-o" "addopts=''")))
2594 (native-inputs
2595 (list python-cython
2596 python-expandvars
2597 python-pytest
2598 python-setuptools
2599 python-tomli))
2600 (home-page "https://github.com/aio-libs/frozenlist")
2601 (synopsis "List-like data structure for Python")
2602 (description "@code{frozenlist.FrozenList} is a list-like structure which
2603implements @code{collections.abc.MutableSequence}. It can be made immutable
2604by calling @code{FrozenList.freeze}.")
2605 (license license:asl2.0)))
2606
2607(define-public python-aiobotocore
2608 (package
2609 (name "python-aiobotocore")
2610 (version "3.0.0")
2611 (source
2612 (origin
2613 (method url-fetch)
2614 (uri (pypi-uri "aiobotocore" version))
2615 (sha256
2616 (base32 "0bcmnbm30hwaks8l895j8xy08cil0dpjcfpidg2qjawbs4a9s0ra"))))
2617 (build-system pyproject-build-system)
2618 (arguments
2619 ;; TODO: Tests need some setupt, see Makefile.
2620 (list #:tests? #f))
2621 (native-inputs
2622 (list python-setuptools))
2623 (propagated-inputs
2624 (list python-aiohttp
2625 python-aioitertools
2626 python-botocore
2627 python-dateutil
2628 python-jmespath
2629 python-multidict
2630 python-typing-extensions
2631 python-wrapt))
2632 (home-page "https://github.com/aio-libs/aiobotocore")
2633 (synopsis "Async client for AWS services using botocore and aiohttp")
2634 (description "This package provides an async client for Amazon services
2635using botocore and aiohttp/asyncio. This library is a mostly full featured
2636asynchronous version of botocore.")
2637 (license license:asl2.0)))
2638
2639(define-public python-aiohappyeyeballs
2640 (package
2641 (name "python-aiohappyeyeballs")
2642 (properties '((commit . "cc53cf8a1d31f7b460a0114214aac66956f0e2ed")
2643 (revision . "0")))
2644 (version (git-version "2.6.1"
2645 (assoc-ref properties 'revision)
2646 (assoc-ref properties 'commit)))
2647 (source
2648 (origin
2649 (method git-fetch)
2650 (uri (git-reference
2651 (url "https://github.com/aio-libs/aiohappyeyeballs")
2652 (commit (assoc-ref properties 'commit))))
2653 (file-name (git-file-name name version))
2654 (sha256
2655 (base32 "0nc723f4sxryg5h9z8paysmy9dnqw2jy4srxp9axrxkv9qrawa7n"))))
2656 (build-system pyproject-build-system)
2657 (native-inputs
2658 (list python-poetry-core
2659 python-pytest
2660 python-pytest-asyncio))
2661 (home-page "https://github.com/aio-libs/aiohappyeyeballs")
2662 (synopsis "Happy Eyeballs for asyncio")
2663 (description "This library exists to allow connecting with Happy
2664Eyeballs (RFC 8305) when you already have a list of @code{addrinfo} and not a
2665DNS name.")
2666 (license license:psfl)))
2667
2668(define-public python-aioitertools
2669 (package
2670 (name "python-aioitertools")
2671 (version "0.12.0")
2672 (source
2673 (origin
2674 (method url-fetch)
2675 (uri (pypi-uri "aioitertools" version))
2676 (sha256
2677 (base32 "0syxv2r90d6410hc68jxhk610pdgx19n1n5rc7shaxxv9xdhbaf2"))))
2678 (build-system pyproject-build-system)
2679 (arguments
2680 (list #:test-backend #~'custom
2681 #:test-flags #~(list "-m" "aioitertools.tests")))
2682 (native-inputs
2683 (list python-flit-core))
2684 (home-page "https://pypi.org/project/aioitertools/")
2685 (synopsis "Itertools and builtins for AsyncIO and mixed iterables")
2686 (description
2687 "This package provides an implementation of itertools, builtins, and more
2688for AsyncIO and mixed-type iterables.")
2689 (license license:expat)))
2690
2691(define-public python-aiosignal
2692 (package
2693 (name "python-aiosignal")
2694 (version "1.4.0")
2695 (source
2696 (origin
2697 (method url-fetch)
2698 (uri (pypi-uri "aiosignal" version))
2699 (sha256
2700 (base32 "1isin9bp256scp59lbr35h48nw5p5i84b6f9kh1c50w08vcyqzpl"))))
2701 (build-system pyproject-build-system)
2702 (arguments
2703 (list
2704 #:phases
2705 #~(modify-phases %standard-phases
2706 (add-after 'unpack 'avoid-pytest-cov-preload
2707 (lambda _
2708 (substitute* "pytest.ini"
2709 (("-p pytest_cov") "")))))))
2710 (native-inputs
2711 (list python-pytest
2712 python-pytest-asyncio
2713 python-setuptools))
2714 (propagated-inputs
2715 (list python-frozenlist))
2716 (home-page "https://github.com/aio-libs/aiosignal")
2717 (synopsis "Callback manager for Python @code{asyncio} projects")
2718 (description "This Python module provides @code{Signal}, an abstraction to
2719register asynchronous callbacks. The @code{Signal} abstraction can be used
2720for adding, removing and dropping callbacks.")
2721 (license license:asl2.0)))
2722
2723(define-public python-aiohttp
2724 (package
2725 (name "python-aiohttp")
2726 ;; TODO: Newer versions require zlib-ng:
2727 ;; <https://github.com/zlib-ng/zlib-ng>,
2728 ;; <https://github.com/pycompression/python-zlib-ng>.
2729 (version "3.11.18")
2730 (source
2731 (origin
2732 (method url-fetch)
2733 (uri (pypi-uri "aiohttp" version))
2734 (sha256
2735 (base32 "12jmkxkc5nnk6ma6m7rrs0w4vzswfc47ffxn5m0pwav1708nx1df"))
2736 (snippet
2737 #~(begin
2738 (use-modules ((guix build utils)))
2739 ;; TODO: Unbundle the llhttp sources.
2740 ;; (delete-file-recursively "vendor")
2741 (delete-file "aiohttp/_http_parser.c")
2742 (delete-file "aiohttp/_http_writer.c")))))
2743 (build-system pyproject-build-system)
2744 (arguments
2745 (list
2746 ;; tests: 3045 passed, 32 skipped, 29 xfailed, 2 subtests passed
2747 #:test-flags
2748 '(list
2749 "-o" "addopts=''" ; Avoid -p pytest_cov.
2750 "-m" "not dev_mode"
2751 "--numprocesses" (number->string (parallel-job-count))
2752 "--ignore=aiohttp/test_utils.py"
2753 ;; This tests requires the 'proxy.py' module, not yet packaged.
2754 "--ignore=tests/test_proxy_functional.py"
2755 ;; These tests need brotli.
2756 "--ignore=tests/test_web_sendfile_functional.py"
2757 "--ignore=tests/test_web_functional.py"
2758 ;; These tests need pytest_codspeed
2759 "--ignore-glob=tests/test_benchmarks*"
2760 ;; These tests need python_on_whales
2761 "--ignore=tests/autobahn/test_autobahn.py"
2762 "-k"
2763 ;; These tests fail for unknown reasons (see:
2764 ;; https://github.com/aio-libs/aiohttp/issues/7130)
2765 (string-append
2766 "not test_no_warnings "
2767 "and not test_default_loop "
2768 "and not test_ctor_global_loop "
2769 "and not test_set_loop_default_loop "
2770
2771 ;; Disable brotli tests, because we’re not providing that optional
2772 ;; library.
2773 "and not test_feed_eof_no_err_brotli "
2774
2775 ;; Disable the following tests as they require
2776 ;; networking.
2777 "and not TestDeflateBuffer "
2778 "and not test_client_session_timeout_zero "
2779 "and not test_empty_body "
2780 "and not test_mark_formdata_as_processed[pyloop] "
2781 "and not test_receive_runtime_err[pyloop] "
2782
2783 ;; assert 'gzip, deflate' == 'gzip, deflate, br'
2784 "and not test_headers[pyloop] "
2785 ;; ~/.. does not resolve
2786 "and not test_add_static_path_resolution"))
2787 #:phases
2788 '(modify-phases %standard-phases
2789 (add-after 'unpack 'fix-tests
2790 (lambda _
2791 ;; Make sure the timestamp of this file is > 1990, because a few
2792 ;; tests like test_static_file_if_modified_since_past_date depend
2793 ;; on it.
2794 (let ((late-90s (* 60 60 24 365 30)))
2795 (utime "tests/data.unknown_mime_type" late-90s late-90s))))
2796 (add-before 'build 'cythonize
2797 (lambda _
2798 ;; Adapted from the Makefile.
2799 (with-directory-excursion "aiohttp"
2800 (for-each
2801 (lambda (file)
2802 (invoke "cython" "-3"
2803 file "-I" "."))
2804 (find-files "." "_.*\\.pyx$"))))))))
2805 (propagated-inputs
2806 (list python-aiohappyeyeballs
2807 python-aiosignal
2808 python-attrs
2809 python-frozenlist
2810 python-multidict
2811 python-propcache
2812 python-yarl))
2813 (native-inputs
2814 (list gunicorn-bootstrap
2815 python-cython
2816 python-freezegun
2817 python-isal
2818 python-pytest
2819 python-pytest-mock
2820 python-pytest-xdist
2821 python-re-assert
2822 python-setuptools))
2823 (home-page "https://github.com/aio-libs/aiohttp/")
2824 (synopsis "Async HTTP client/server framework (asyncio)")
2825 (description "@code{aiohttp} is an asynchronous HTTP client/server
2826framework.
2827
2828Its main features are:
2829@itemize
2830@item Supports both client and server side of HTTP protocol.
2831@item Supports both client and server Web-Sockets out-of-the-box without the
2832Callback Hell.
2833@item Web-server has middlewares and pluggable routing.
2834@end itemize")
2835 (license license:asl2.0)))
2836
2837(define-public python-aiohttp-oauthlib
2838 (package
2839 (name "python-aiohttp-oauthlib")
2840 (version "0.1.0")
2841 (source
2842 (origin
2843 (method url-fetch)
2844 (uri (pypi-uri "aiohttp-oauthlib" version))
2845 (sha256
2846 (base32 "1dwk0gby27xm7384qyz2p7zw9dqhjx7m8fhfk172w36xknjx2g49"))))
2847 (build-system pyproject-build-system)
2848 (arguments (list #:tests? #f)) ; none included
2849 (propagated-inputs (list python-aiohttp python-oauthlib))
2850 (native-inputs (list python-setuptools python-setuptools-scm))
2851 (home-page "https://git.sr.ht/~whynothugo/aiohttp-oauthlib")
2852 (synopsis "OAuthlib authentication support for aiohttp")
2853 (description "Aiohttp-oauthlib uses the Python aiohttp and OAuthlib libraries to
2854provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
2855 (license license:isc)))
2856
2857(define-public python-aiohttp-client-cache
2858 (package
2859 (name "python-aiohttp-client-cache")
2860 (version "0.14.3")
2861 (source
2862 (origin
2863 (method git-fetch)
2864 (uri (git-reference
2865 (url "https://github.com/requests-cache/aiohttp-client-cache")
2866 (commit (string-append "v" version))))
2867 (file-name (git-file-name name version))
2868 (sha256
2869 (base32
2870 "13xbmjjvcbzh3yh5z92mc0gwicwfjfq2av5jbqv09sbfzhggs92y"))))
2871 (build-system pyproject-build-system)
2872 (arguments
2873 (list
2874 #:test-flags #~(list "--ignore=test/integration/")))
2875 (native-inputs
2876 (list python-brotli
2877 python-faker
2878 python-hatchling
2879 python-pytest
2880 python-pytest-aiohttp
2881 python-pytest-asyncio
2882 python-types-aiofiles))
2883 (propagated-inputs
2884 (list python-aiohttp
2885 python-attrs
2886 python-itsdangerous
2887 python-url-normalize
2888 ;; [optional]
2889 python-aioboto3
2890 python-aiobotocore
2891 python-aiofiles
2892 python-aiosqlite
2893 python-pymongo
2894 python-redis))
2895 (home-page "https://github.com/requests-cache/aiohttp-client-cache")
2896 (synopsis "Persistent cache for aiohttp requests")
2897 (description
2898 "This package is an asynchronous persistent caching library specifically
2899designed for @samp{aiohttp} requests in Python. With support for various
2900storage backends, it offers flexibility in how and where the cache is stored.
2901Please note that MongoDB and DynamoDB backends are not currently supported due
2902to the absence of the @samp{motor} and @samp{aioboto3} package dependencies.")
2903 (license license:expat)))
2904
2905(define-public python-aiohttp-cors
2906 (package
2907 (name "python-aiohttp-cors")
2908 (version "0.8.1")
2909 (source
2910 (origin
2911 (method url-fetch)
2912 (uri (pypi-uri "aiohttp_cors" version))
2913 (sha256
2914 (base32 "00qlzc2y65bkl1a5f5v83mmjlrhzmx3a2ngq2pm3jjdnhk5zkb6c"))))
2915 (build-system pyproject-build-system)
2916 (arguments
2917 (list
2918 #:tests? #f)) ; network access is required to run tests
2919 (native-inputs
2920 (list python-setuptools
2921 python-wheel))
2922 (propagated-inputs
2923 (list python-aiohttp))
2924 (home-page "https://github.com/aio-libs/aiohttp-cors")
2925 (synopsis "CORS support for aiohttp")
2926 (description
2927 "This library implements @acronym{CORS, Cross Origin Resource Sharing}
2928support for aiohttp asyncio-powered asynchronous HTTP server.")
2929 (license license:asl2.0)))
2930
2931(define-public python-aiohttp-retry
2932 (package
2933 (name "python-aiohttp-retry")
2934 (version "2.9.1")
2935 (source
2936 (origin
2937 (method git-fetch)
2938 (uri (git-reference
2939 (url "https://github.com/inyutin/aiohttp_retry")
2940 (commit (string-append "v" version))))
2941 (file-name (git-file-name name version))
2942 (sha256
2943 (base32 "0r5lxnxc4s8js7l86pfmdxl455v9lg3m41nz6m1xg4kwwf6j0bpi"))))
2944 (build-system pyproject-build-system)
2945 (native-inputs
2946 (list python-pytest
2947 python-pytest-aiohttp
2948 python-setuptools))
2949 (propagated-inputs
2950 (list python-aiohttp))
2951 (home-page "https://github.com/inyutin/aiohttp_retry")
2952 (synopsis "Simple retry client for aiohttp")
2953 (description
2954 "This package implements @code{RetryClient} for @code{aiohttp} to retry
2955connection to provided endpoint with timeouts logic or use:
2956
2957@itemize
2958@item @code{ExponentialRetry} with exponential backoff
2959@item @code{RandomRetry} for random backoff
2960@item @code{ListRetry} with backoff you predefine by list
2961@item @code{FibonacciRetry} with backoff that looks like fibonacci sequence
2962@item @code{JitterRetry} exponential retry with a bit of randomness
2963@end itemize")
2964 (license license:expat)))
2965
2966(define-public python-aiohttp-socks
2967 (package
2968 (name "python-aiohttp-socks")
2969 (version "0.10.1")
2970 (source
2971 (origin
2972 (method url-fetch)
2973 (uri (pypi-uri "aiohttp_socks" version))
2974 (sha256
2975 (base32
2976 "0s70jpcr9wc8ld2v1w309cz7r8mm2bipf6zbkdqqaa0z0pwf3wj9"))))
2977 (build-system pyproject-build-system)
2978 (arguments (list #:tests? #false)) ;none included
2979 (propagated-inputs
2980 (list python-aiohttp python-socks))
2981 (native-inputs (list python-setuptools python-wheel))
2982 (home-page "https://github.com/romis2012/aiohttp-socks")
2983 (synopsis "SOCKS proxy connector for aiohttp")
2984 (description "This package provides a SOCKS proxy connector for
2985aiohttp. It supports SOCKS4(a) and SOCKS5.")
2986 (license license:asl2.0)))
2987
2988(define-public python-aiodns
2989 (package
2990 (name "python-aiodns")
2991 (version "3.5.0")
2992 (source
2993 (origin
2994 (method git-fetch)
2995 (uri (git-reference
2996 (url "https://github.com/saghul/aiodns")
2997 (commit (string-append "v" version))))
2998 (file-name (git-file-name name version))
2999 (sha256
3000 (base32 "1as7l48962dpk3r4zdsifj761dks5nyr35hxs7m8crvkyb1dg9m9"))))
3001 (build-system pyproject-build-system)
3002 (arguments
3003 (list
3004 #:tests? #f)) ;tests require internet access
3005 (native-inputs
3006 (list python-pytest python-pytest-asyncio python-setuptools))
3007 (propagated-inputs (list python-pycares))
3008 (home-page "https://github.com/saghul/aiodns")
3009 (synopsis "Simple DNS resolver for asyncio")
3010 (description
3011 "@code{aiodns} provides a simple way for doing asynchronous DNS
3012resolutions with a synchronous looking interface by using
3013@url{https://github.com/saghul/pycares,pycares}.")
3014 (license license:expat)))
3015
3016(define-public python-aioquic
3017 (package
3018 (name "python-aioquic")
3019 (version "1.2.0")
3020 (source
3021 (origin
3022 (method url-fetch)
3023 (uri (pypi-uri "aioquic" version))
3024 (sha256
3025 (base32 "16bigrn5b46c7nmpzxhnlhh4y03hwc7dbd0mi5f8r53i7yxn64pr"))))
3026 (build-system pyproject-build-system)
3027 (arguments
3028 (list
3029 #:test-flags
3030 #~(list "-k" (string-join
3031 ;; AssertionError: AlertBadCertificate not raised
3032 (list "not test_verify_subject_no_subjaltname"
3033 ;; AttributeError: module
3034 ;; 'service_identity.cryptography' has no attribute
3035 ;; 'extract_patterns'
3036 "test_verify_subject_with_subjaltname"
3037 ;; AttributeError: module
3038 ;; 'service_identity.cryptography' has no attribute
3039 ;; 'extract_patterns'
3040 "test_verify_subject_with_subjaltname_ipaddress")
3041 " and not "))))
3042 (native-inputs
3043 (list nss-certs-for-test
3044 python-pytest
3045 python-setuptools
3046 python-wheel))
3047 (inputs
3048 (list openssl))
3049 (propagated-inputs
3050 (list python-certifi
3051 python-pylsqpack
3052 python-pyopenssl
3053 python-service-identity))
3054 (home-page "https://github.com/aiortc/aioquic")
3055 (synopsis "QUIC and HTTP3 implementation in Python")
3056 (description
3057 "@code{aioquic} is a library for the QUIC network protocol in Python.
3058It features a minimal TLS 1.3 implementation, a QUIC stack and an HTTP/3 stack.")
3059 (license license:bsd-3)))
3060
3061(define-public python-aiorpcx
3062 (package
3063 (name "python-aiorpcx")
3064 (version "0.25.0")
3065 (source
3066 (origin
3067 (method git-fetch)
3068 ;; PyPI misses the util.py file used for tests.
3069 (uri (git-reference
3070 (url "https://github.com/kyuupichan/aiorpcX")
3071 (commit version)))
3072 (file-name (git-file-name name version))
3073 (sha256
3074 (base32
3075 "0sn4xxlpy0kb5b25bqrjzh2m6bskdyydc6cq8bigb7g5dacksn4q"))))
3076 (build-system pyproject-build-system)
3077 (arguments
3078 (list
3079 #:test-flags
3080 ;; This test opens a remote connection.
3081 #~(list "-k" "not test_create_connection_resolve_good")))
3082 (native-inputs (list python-pytest
3083 python-pytest-asyncio-0.26
3084 python-setuptools))
3085 (propagated-inputs
3086 (list python-attrs python-websockets))
3087 (home-page "https://github.com/kyuupichan/aiorpcX")
3088 (synopsis "Generic asyncio RPC implementation")
3089 (description
3090 "The aiorpcX library is a generic asyncio implementation of RPC suitable
3091for an application that is a client, server or both.
3092
3093The package includes a module with full coverage of JSON RPC versions 1.0 and
30942.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
3095comes with a SOCKS proxy client.")
3096 (license (list license:expat license:bsd-2))))
3097
3098(define-public python-aiostream
3099 (package
3100 (name "python-aiostream")
3101 (version "0.7.0")
3102 (source
3103 (origin
3104 (method git-fetch) ;no tests in PyPI archive
3105 (uri (git-reference
3106 (url "https://github.com/vxgmichel/aiostream")
3107 (commit (string-append "v" version))))
3108 (file-name (git-file-name name version))
3109 (sha256
3110 (base32 "1wf89l9f0ivlv796pklpgykx6j6ksfqrmvzikd8w5j6ldln7bv50"))))
3111 (build-system pyproject-build-system)
3112 (native-inputs
3113 (list python-pytest python-pytest-asyncio python-setuptools))
3114 (propagated-inputs
3115 (list python-typing-extensions))
3116 (home-page "https://github.com/vxgmichel/aiostream")
3117 (synopsis "Generator-based operators for asynchronous iteration")
3118 (description "@code{aiostream} provides a collection of stream operators that can
3119be combined to create asynchronous pipelines of operations. It can be seen as an
3120asynchronous version of @code{itertools}, although some aspects are slightly
3121different. All the provided operators return a unified interface called a stream. A
3122stream is an enhanced asynchronous iterable.")
3123 (license license:gpl3)))
3124
3125(define-public python-asgiref
3126 (package
3127 (name "python-asgiref")
3128 (version "3.8.1")
3129 (source (origin
3130 (method url-fetch)
3131 (uri (pypi-uri "asgiref" version))
3132 (sha256
3133 (base32 "146mhkn3zp2bqf7j6r3chdlvfzgs5x1lrnqahsllgjdyl20bshy3"))))
3134 (build-system pyproject-build-system)
3135 (native-inputs
3136 (list python-pytest
3137 python-pytest-asyncio
3138 python-setuptools
3139 python-wheel))
3140 (home-page "https://github.com/django/asgiref/")
3141 (synopsis "ASGI specs, helper code, and adapters")
3142 (description
3143 "ASGI is a standard for Python asynchronous web apps and servers to
3144communicate with each other, and positioned as an asynchronous successor to
3145WSGI. This package includes libraries for implementing ASGI servers.")
3146 (license license:bsd-3)))
3147
3148(define-public python-asgi-csrf
3149 (package
3150 (name "python-asgi-csrf")
3151 (version "0.11")
3152 (source (origin
3153 (method git-fetch) ;for tests
3154 (uri (git-reference
3155 (url "https://github.com/simonw/asgi-csrf")
3156 (commit version)))
3157 (file-name (git-file-name name version))
3158 (sha256
3159 (base32
3160 "1dn9v47z2b599cnwahxvzsll2w28940ycgh5skxgq04vcqqssf29"))))
3161 (build-system pyproject-build-system)
3162 (propagated-inputs (list python-itsdangerous python-multipart))
3163 (native-inputs (list python-asgi-lifespan
3164 python-httpx
3165 python-pytest
3166 python-pytest-asyncio
3167 python-starlette
3168 python-setuptools
3169 python-wheel))
3170 (home-page "https://github.com/simonw/asgi-csrf")
3171 (synopsis "ASGI middleware for protecting against CSRF attacks")
3172 (description "This Asynchronous Server Gateway Interface (ASGI)
3173middleware protects against Cross-site request forgery (CSRF) attacks.
3174It implements the Double Submit Cookie pattern, where a cookie is set
3175that is then compared to a @code{csrftoken} hidden form field or a
3176@code{x-csrftoken} HTTP header.")
3177 (license license:asl2.0)))
3178
3179(define-public python-asgi-lifespan
3180 (package
3181 (name "python-asgi-lifespan")
3182 (version "2.1.0")
3183 (source (origin
3184 (method git-fetch) ;for tests
3185 (uri (git-reference
3186 (url "https://github.com/florimondmanca/asgi-lifespan")
3187 (commit version)))
3188 (file-name (git-file-name name version))
3189 (sha256
3190 (base32
3191 "0iqa3h61gsq1qd6j9v68k989596m9n9k1dx8zv6135rmhzzrs296"))))
3192 (build-system pyproject-build-system)
3193 (arguments
3194 (list
3195 #:test-flags
3196 '(list "-k"
3197 (string-append
3198 ;; XXX: Some tests fail because of "Exceptions from Trio nursery"
3199 "not (test_lifespan_manager[trio-None-None-StartupFailed]"
3200 " or test_lifespan_manager[trio-None-BodyFailed-None]"
3201 " or test_lifespan_manager[trio-None-BodyFailed-StartupFailed]"
3202 " or test_lifespan_manager[trio-ShutdownFailed-None-None]"
3203 " or test_lifespan_manager[trio-ShutdownFailed-None-StartupFailed]"
3204 " or test_lifespan_manager[trio-ShutdownFailed-BodyFailed-StartupFailed]"
3205 " or test_lifespan_timeout[trio-slow_shutdown]"
3206 " or test_lifespan_not_supported[trio-http_only]"
3207 " or test_lifespan_not_supported[trio-http_no_assert]"
3208 " or test_lifespan_not_supported[trio-http_no_assert_before_receive_request]"
3209 ")"))
3210 #:phases
3211 '(modify-phases %standard-phases
3212 (add-after 'unpack 'compatibility
3213 (lambda _
3214 ;; httpx version 0.28.0 removed the "app" shortcut.
3215 (substitute* "tests/test_manager.py"
3216 (("app=manager.app")
3217 "transport=httpx.ASGITransport(manager.app)")))))))
3218 (native-inputs (list python-httpx
3219 python-pytest
3220 python-pytest-asyncio
3221 python-pytest-trio
3222 python-starlette
3223 python-setuptools
3224 python-wheel))
3225 (propagated-inputs (list python-sniffio))
3226 (home-page "https://github.com/florimondmanca/asgi-lifespan")
3227 (synopsis "Programmatic startup/shutdown of ASGI apps")
3228 (description "Programmatically send startup/shutdown lifespan events
3229into Asynchronous Server Gateway Interface (ASGI) applications. When
3230used in combination with an ASGI-capable HTTP client such as HTTPX, this
3231allows mocking or testing ASGI applications without having to spin up an
3232ASGI server.")
3233 (license license:expat)))
3234
3235(define-public python-a2wsgi
3236 (package
3237 (name "python-a2wsgi")
3238 (version "1.10.7")
3239 (source (origin
3240 (method url-fetch)
3241 (uri (pypi-uri "a2wsgi" version))
3242 (sha256
3243 (base32
3244 "13ikyfmkx7hlrbg5rpcdm6kw4wcsy00giil3f72hpb6sw7vjyinf"))))
3245 (build-system pyproject-build-system)
3246 (arguments
3247 (list
3248 #:test-flags
3249 #~(list "-k" (string-join
3250 (list "not test_starlette_stream_response"
3251 "test_starlette_base_http_middleware"
3252 "test_baize_stream_response"
3253 ;; Fails because of harmless whitespace differences.
3254 "test_wsgi_post")
3255 " and not "))
3256 #:build-backend "pdm.backend"))
3257 (native-inputs
3258 (list python-pdm-backend
3259 python-pytest
3260 ;; python-baize ; not packed yet
3261 python-httpx-bootstrap
3262 ;; Cycle: python-a2wsgi->python-uvicorn->
3263 ;; python-httpx->python-starlette->python-a2wsgi
3264 ;; python-starlette
3265 python-pytest-asyncio))
3266 (home-page "https://github.com/abersheeran/a2wsgi")
3267 (synopsis "Convert WSGI to ASGI or vice versa")
3268 (description
3269 "This program converts a WSGI program to an ASGI program or the other
3270way around. It depends only on the Python standard library.")
3271 (license license:asl2.0)))
3272
3273(define-public python-httpauth
3274 (package
3275 (name "python-httpauth")
3276 (version "0.4.1")
3277 (source (origin
3278 (method url-fetch)
3279 (uri (pypi-uri "httpauth" version))
3280 (sha256
3281 (base32
3282 "1m6rwvivg61l3h34hf6p6gkqmr69sb1c4k5ha379nxq0p8bfgahb"))))
3283 (build-system pyproject-build-system)
3284 (native-inputs (list python-pytest python-setuptools python-wheel))
3285 (home-page "https://github.com/jonashaag/httpauth")
3286 (synopsis "WSGI HTTP Digest Authentication middleware")
3287 (description "@code{python-httpauth} is WSGI middleware that secures some/all
3288routes using HTTP Digest Authentication.")
3289 (license license:bsd-2)))
3290
3291(define-public python-css-html-js-minify
3292 (let ((commit "8f72452960e41bc5476e50d96481f633eff72750")
3293 (revision "0"))
3294 (package
3295 (name "python-css-html-js-minify")
3296 (version (git-version "2.5.5" revision commit))
3297 (source
3298 (origin
3299 (method git-fetch)
3300 (uri (git-reference
3301 (url "https://github.com/juancarlospaco/css-html-js-minify")
3302 (commit commit)))
3303 (file-name (git-file-name name version))
3304 (sha256
3305 (base32 "1lkx03720zk6q16w3d9r3l5kryikd1cmzwrcjzsjxwrq4zfh6vdf"))))
3306 (build-system pyproject-build-system)
3307 (arguments
3308 (list
3309 #:phases
3310 #~(modify-phases %standard-phases
3311 (add-after 'unpack 'relax-requirements
3312 (lambda _
3313 (substitute* "setup.cfg"
3314 (("^tests_require.*") "")))))))
3315 (native-inputs (list python-pytest python-setuptools))
3316 (home-page "https://github.com/juancarlospaco/css-html-js-minify")
3317 (synopsis "CSS/HTML/JS minifier")
3318 (description
3319 "This package provides a single-file minifier for CSS, HTML, and JavaScript.")
3320 ;; XXX: The README just says "GNU GPL and GNU LGPL and MIT". From
3321 ;; <https://github.com/juancarlospaco/css-html-js-minify/issues/9> it
3322 ;; looks like the user can choose a license.
3323 (license (list license:gpl3+ license:lgpl3+ license:expat)))))
3324
3325(define-public python-aws-sam-translator
3326 (package
3327 (name "python-aws-sam-translator")
3328 (version "1.107.0")
3329 (source
3330 (origin
3331 (method git-fetch) ; no tests in PyPI release
3332 (uri (git-reference
3333 (url "https://github.com/aws/serverless-application-model")
3334 (commit (string-append "v" version))))
3335 (file-name (git-file-name name version))
3336 (sha256
3337 (base32 "0bx9ha9k6zx6gl1hsgm6cpq4xrfn604v2g1d5dh2d5zq0463gwfq"))))
3338 (build-system pyproject-build-system)
3339 (arguments
3340 (list
3341 #:test-flags
3342 #~(list "--numprocesses" (number->string (parallel-job-count))
3343 "--ignore=tests/bin/test_public_interface.py"
3344 "tests")
3345 #:phases
3346 #~(modify-phases %standard-phases
3347 (add-before 'check 'pre-check
3348 (lambda _
3349 (setenv "AWS_DEFAULT_REGION" "eu-west-3"))))))
3350 (native-inputs
3351 (list python-pytest
3352 python-pytest-rerunfailures
3353 python-pytest-xdist
3354 python-parameterized
3355 python-pyyaml
3356 python-setuptools))
3357 (propagated-inputs
3358 (list python-boto3
3359 python-jsonschema
3360 python-pydantic
3361 python-typing-extensions))
3362 (home-page "https://github.com/aws/serverless-application-model")
3363 (synopsis "Transform AWS SAM templates into AWS CloudFormation templates")
3364 (description
3365 "AWS SAM Translator is a library that transform @dfn{Serverless Application
3366Model} (SAM) templates into AWS CloudFormation templates.")
3367 (license license:asl2.0)))
3368
3369(define-public python-aws-xray-sdk
3370 (package
3371 (name "python-aws-xray-sdk")
3372 (version "2.14.0")
3373 (home-page "https://github.com/aws/aws-xray-sdk-python")
3374 (source (origin
3375 (method git-fetch)
3376 (uri (git-reference (url home-page) (commit version)))
3377 (file-name (git-file-name name version))
3378 (sha256
3379 (base32
3380 "0khm86218rfjmgfw0azk7gnq6y9gkj95i0i30wa5v2li1z4z8qxd"))))
3381 (build-system pyproject-build-system)
3382 (arguments
3383 (list
3384 #:test-flags
3385 '(list ;; Tries to connect to external network resources
3386 "--ignore=tests/ext/aiohttp/test_client.py"
3387 "--ignore=tests/ext/httplib/test_httplib.py"
3388 "--ignore=tests/ext/httpx"
3389 "--ignore=tests/ext/requests/test_requests.py"
3390 ;; TODO: How to configure Django for these tests?
3391 "--ignore=tests/ext/django"
3392 ;; These tests require packages not yet in Guix.
3393 "--ignore=tests/ext/aiobotocore/test_aiobotocore.py"
3394 "--ignore=tests/ext/aiohttp/test_middleware.py"
3395 "--ignore=tests/ext/pg8000/test_pg8000.py"
3396 "--ignore=tests/ext/psycopg2/test_psycopg2.py"
3397 "--ignore=tests/ext/pymysql/test_pymysql.py"
3398 "--ignore=tests/ext/pynamodb/test_pynamodb.py"
3399 "--ignore=tests/ext/sqlalchemy_core/test_postgres.py"
3400 "--ignore=tests/ext/sqlalchemy_core/test_dburl.py"
3401 "--ignore=tests/test_async_recorder.py"
3402 ;; FIXME: module 'sqlalchemy.orm' has no attribute 'DeclarativeBase'.
3403 "--ignore-glob=tests/ext/sqlalchemy*"
3404 "--ignore=tests/ext/flask_sqlalchemy/test_query.py"
3405 ;; FIXME: Why is this failing?
3406 "--ignore=tests/test_patcher.py"
3407 "--ignore=tests/test_lambda_context.py")
3408 #:phases
3409 '(modify-phases %standard-phases
3410 (add-before 'check 'pre-check
3411 (lambda _
3412 ;; Allow "import tests.utils" to work as expected.
3413 (setenv "PYTHONPATH" (getcwd)))))))
3414 (native-inputs
3415 (list ;; These are required for the test suite.
3416 python-aiohttp
3417 python-bottle
3418 python-flask
3419 python-flask-sqlalchemy
3420 python-httpx
3421 python-mock
3422 python-pymysql
3423 python-pytest
3424 python-pytest-asyncio-0.26
3425 python-pytest-benchmark
3426 python-setuptools
3427 python-sqlalchemy
3428 python-webtest))
3429 (propagated-inputs
3430 (list python-botocore
3431 python-jsonpickle
3432 python-requests
3433 python-wrapt))
3434 (synopsis "Profile applications on AWS X-Ray")
3435 (description
3436 "The AWS X-Ray SDK for Python enables Python developers to record and
3437emit information from within their applications to the AWS X-Ray service.")
3438 (license license:asl2.0)))
3439
3440(define-public python-publicsuffixlist
3441 (package
3442 (name "python-publicsuffixlist")
3443 (version "1.0.2.20250202")
3444 (source
3445 (origin
3446 (method url-fetch)
3447 (uri (pypi-uri "publicsuffixlist" version))
3448 (sha256
3449 (base32 "0llam7g7sv08lcfgy18iph8br8ldjmy2qbjaykc9pd3z4iisb0yd"))))
3450 (build-system pyproject-build-system)
3451 (arguments (list #:test-backend #~'unittest))
3452 (native-inputs (list python-setuptools))
3453 (home-page "https://github.com/ko-zu/psl")
3454 (synopsis "Public suffix list for Python")
3455 (description
3456 "This package provides an implementation of
3457@url{https://publicsuffix.org/, Public Suffix List } as Python library.
3458
3459Features:
3460@itemize
3461@item supports IDN (unicode and punycoded)
3462@item shipped with built-in PSL and an updater script
3463@item written in Pure Python with no library dependencies
3464@end itemize")
3465 (license license:mpl2.0)))
3466
3467(define-public python-pycognito
3468 (package
3469 (name "python-pycognito")
3470 (version "2024.5.1")
3471 (source
3472 (origin
3473 (method url-fetch)
3474 (uri (pypi-uri "pycognito" version))
3475 (sha256
3476 (base32 "1r1sq87spqcfgg17khgpqc2ga8m9nk10flg9h23drhy2k1kcc4g2"))))
3477 (build-system pyproject-build-system)
3478 (arguments
3479 ;; XXX: cycles with python-moto, bootstrap/minimal variant is required.
3480 (list #:tests? #f))
3481 (native-inputs
3482 (list python-setuptools))
3483 (propagated-inputs
3484 (list python-boto3
3485 python-envs
3486 python-pyjwt
3487 python-requests))
3488 (home-page "https://github.com/pvizeli/pycognito")
3489 (synopsis "Python library for using AWS Cognito")
3490 (description
3491 "This package provides a Python class to integrate Boto3's Cognito
3492client so it is easy to login users, with @acronym{Secure Remote Password,
3493SRP} support.")
3494 (license license:asl2.0)))
3495
3496(define-public python-pydap
3497 (package
3498 (name "python-pydap")
3499 (version "3.5.10")
3500 (source
3501 (origin
3502 (method git-fetch)
3503 (uri (git-reference
3504 (url "https://github.com/pydap/pydap")
3505 (commit version)))
3506 (file-name (git-file-name name version))
3507 (sha256
3508 (base32 "000b7jqjpx71miwxhbi07amyjyijq925x9x3paa7kzrr268klc2z"))))
3509 (build-system pyproject-build-system)
3510 (arguments
3511 (list
3512 ;; tests: 435 passed, 6 skipped
3513 #:test-flags
3514 ;; Tests need extra packaging.
3515 #~(list "--ignore=src/pydap/tests/test_wsgi_functions.py"
3516 "--ignore=src/pydap/tests/test_wsgi_ssf.py"
3517 ;; Network access is required.
3518 "--ignore=src/pydap/tests/test_client.py"
3519 "--ignore=src/pydap/tests/test_handlers_dap.py"
3520 "--ignore=src/pydap/tests/test_open_dap4_url.py"
3521 "--ignore=src/pydap/tests/test_virtualizarr.py")))
3522 (native-inputs
3523 (list nss-certs-for-test
3524 python-requests-mock
3525 python-pytest
3526 python-setuptools
3527 python-setuptools-scm
3528 python-webtest))
3529 (propagated-inputs
3530 (list python-beautifulsoup4
3531 python-jinja2
3532 python-lxml
3533 python-numpy
3534 python-requests
3535 python-requests-cache
3536 python-scipy
3537 python-webob
3538 ;; [optional]
3539 gunicorn
3540 python-docopt-ng
3541 ;; python-coards ;not packaged yet in Guix
3542 python-fastparquet
3543 ;; python-gsw ;not packaged yet in Guix
3544 python-netcdf4
3545 python-openpyxl
3546 python-pastedeploy
3547 python-werkzeug))
3548 (home-page "https://pydap.github.io/pydap/en/intro.html")
3549 (synopsis "Data Access Protocol implementation in Python")
3550 (description
3551 "This package provides a pure Python implementation of the Data Access
3552Protocol (DAP, aka OPeNDAP).")
3553 (license license:expat)))
3554
3555(define-public python-python3-saml
3556 (package
3557 (name "python-python3-saml")
3558 (version "1.16.0")
3559 (source
3560 (origin
3561 (method git-fetch)
3562 (uri (git-reference
3563 (url "https://github.com/SAML-Toolkits/python3-saml")
3564 (commit (string-append "v" version))))
3565 (file-name (git-file-name name version))
3566 (sha256
3567 (base32 "1isisymhk8zblj5942jfl0zq392q5fpjikx52nywvzb0m2dcc81b"))))
3568 (build-system pyproject-build-system)
3569 (arguments
3570 (list
3571 ;; 214 tests pass, 50 fail; many fail because of required Internet
3572 ;; access or because of assumptions about the location of test files.
3573 #:tests? #false))
3574 (native-inputs
3575 (list python-freezegun
3576 python-poetry-core))
3577 (inputs
3578 (list xmlsec-openssl))
3579 (propagated-inputs
3580 (list python-isodate
3581 python-lxml
3582 python-xmlsec))
3583 (home-page "https://github.com/SAML-Toolkits/python3-saml")
3584 (synopsis "Saml Python toolkit")
3585 (description
3586 "The SAML Python Toolkit lets you add SAML support to your Python
3587software.")
3588 (license license:expat)))
3589
3590(define-public python-ovh
3591 (package
3592 (name "python-ovh")
3593 (version "1.1.0")
3594 (source (origin
3595 (method url-fetch)
3596 (uri (pypi-uri "ovh" version))
3597 (sha256
3598 (base32
3599 "0ygniv12lixh9rvnjcd01gzbzk2b5xwcg2a59b7964a77dd9p3qh"))))
3600 (build-system pyproject-build-system)
3601 (arguments (list #:tests? #f)) ; XXX: tests require networking
3602 (propagated-inputs (list python-requests))
3603 (native-inputs (list python-setuptools))
3604 (home-page "https://api.ovh.com")
3605 (synopsis "Interact with OVHcloud APIs")
3606 (description "This package provides the official module to perform HTTP requests
3607to the OVHcloud APIs.")
3608 (license license:bsd-3)))
3609
3610(define-public python-cbor2
3611 (package
3612 (name "python-cbor2")
3613 (version "5.4.2.post1")
3614 (source
3615 (origin
3616 (method url-fetch)
3617 (uri (pypi-uri "cbor2" version))
3618 (sha256
3619 (base32 "15y78xcc3zkmvj1mdzz8gyhf3apbl91073kwhzbjk5abc1civwlw"))))
3620 (build-system pyproject-build-system)
3621 (native-inputs
3622 (list python-pytest python-setuptools python-setuptools-scm))
3623 (home-page "https://github.com/agronholm/cbor2")
3624 (synopsis "Concise Binary Object Representation (CBOR) (de)serializer")
3625 (description "This Python library provides encoding and decoding for the
3626Concise Binary Object
3627Representation (CBOR) (@url{https://www.rfc-editor.org/rfc/rfc8949.html, RFC
36288949}) serialization format. The specification is fully compatible with the
3629original RFC 7049. Among its features are:
3630@itemize
3631@item Simple API like the @code{json} or @code{pickle} modules.
3632@item Support many CBOR tags with stdlib objects.
3633@item Generic tag decoding.
3634@item Shared value references including cyclic references.
3635@item String references compact encoding with repeated strings replaced with
3636indices.
3637@item Optional C module backend tested on big- and little-endian architectures.
3638@item Extensible tagged value handling using tag_hook and object_hook on
3639decode and default on encode.
3640@end itemize")
3641 (license license:expat)))
3642
3643(define-public python-cfn-lint
3644 (package
3645 (name "python-cfn-lint")
3646 (version "1.38.1")
3647 (source
3648 (origin
3649 (method git-fetch)
3650 (uri (git-reference
3651 (url "https://github.com/aws-cloudformation/cfn-lint")
3652 (commit (string-append "v" version))))
3653 (file-name (git-file-name name version))
3654 (sha256
3655 (base32 "1crwx0cp50h83xz8lc4ny504mx4dadpk80ln539syd4jd78qplgy"))))
3656 (build-system pyproject-build-system)
3657 (arguments
3658 (list
3659 ;; tests: 2136 passed, 11 deselected, 1 warning
3660 #:test-flags
3661 #~(list "--ignore=test/integration/"
3662 "-k" (string-join
3663 ;; Tests failing on doctest or comparing diff.
3664 (list "not test_build_graph"
3665 "test_good_template"
3666 "test_success_run"
3667 "test_update_docs"
3668 ;; ImportError: Missing optional dependencies sarif
3669 "test_sarif_formatter")
3670 " and not "))
3671 #:phases
3672 #~(modify-phases %standard-phases
3673 (add-after 'unpack 'remove-deprecated
3674 (lambda _
3675 (substitute* "src/cfnlint/data/AdditionalSpecs/LmbdRuntimeLifecycle.json"
3676 (("deprecated\": \"2025")
3677 "deprecated\": \"2125")))))))
3678 (native-inputs
3679 (list python-defusedxml
3680 python-pydot
3681 python-pytest
3682 python-setuptools))
3683 (propagated-inputs
3684 (list python-aws-sam-translator
3685 python-jsonpatch
3686 python-networkx
3687 python-pyyaml
3688 python-regex
3689 python-sympy
3690 python-typing-extensions
3691 ;; [optional]
3692 python-junit-xml))
3693 (home-page "https://github.com/aws-cloudformation/cfn-lint")
3694 (synopsis "Validate CloudFormation templates")
3695 (description
3696 "This package lets you validate CloudFormation YAML/JSON templates against
3697the CloudFormation spec and additional checks. Includes checking valid values
3698for resource properties and best practices.")
3699 (license license:expat)))
3700
3701(define-public python-pyzabbix
3702 (package
3703 (name "python-pyzabbix")
3704 (version "1.3.1")
3705 (source
3706 (origin
3707 (method git-fetch)
3708 (uri (git-reference
3709 (url "https://github.com/lukecyca/pyzabbix")
3710 (commit version)))
3711 (file-name (git-file-name name version))
3712 (sha256
3713 (base32 "1dbs3bz1mjlvlg46ikhg5j7agwni61ljlpiziknklv95yp29n86v"))))
3714 (build-system pyproject-build-system)
3715 (arguments
3716 (list #:test-flags #~(list "tests")))
3717 (native-inputs
3718 (list python-pytest
3719 python-requests-mock
3720 python-setuptools))
3721 (propagated-inputs
3722 (list python-packaging
3723 python-requests))
3724 (home-page "https://github.com/lukecyca/pyzabbix")
3725 (synopsis "Python interface to the Zabbix API")
3726 (description
3727 "@code{pyzabbix} is a Python module for working with the Zabbix API.")
3728 (license license:lgpl2.1+)))
3729
3730(define-public python-requests-cache
3731 (package
3732 (name "python-requests-cache")
3733 (version "1.2.1")
3734 (source
3735 (origin
3736 (method url-fetch)
3737 (uri (pypi-uri "requests_cache" version))
3738 (sha256
3739 (base32 "1l8i4l2pd26gbrlcdb5z056wvsqfr3vvbyqq2f8x1f65zn3ckav8"))))
3740 (build-system pyproject-build-system)
3741 (arguments
3742 (list
3743 #:test-flags
3744 #~(list "--numprocesses" (number->string (parallel-job-count))
3745 ;; These tests require access to external services, e.g. MongoDB
3746 ;; and Redis.
3747 "--ignore=tests/integration"
3748 ;; AttributeError: <class 'requests.adapters.HTTPAdapter'> does
3749 ;; not have the attribute 'get_connection_with_tls_context'
3750 "-k" "not test_mock_session")
3751 #:phases
3752 #~(modify-phases %standard-phases
3753 (add-before 'check 'pre-check
3754 (lambda _
3755 ;; PermissionError: [Errno 13] Permission denied:
3756 ;; '/homeless-shelter'
3757 (setenv "HOME" "/tmp"))))))
3758 (native-inputs
3759 (list python-poetry-core
3760 python-pytest
3761 python-pytest-rerunfailures
3762 python-pytest-xdist
3763 python-requests-mock
3764 python-responses
3765 python-rich
3766 python-tenacity
3767 python-time-machine
3768 python-timeout-decorator))
3769 (propagated-inputs
3770 (list python-attrs
3771 python-boto3
3772 python-bson
3773 python-cattrs
3774 python-itsdangerous
3775 python-orjson
3776 python-platformdirs
3777 python-pymongo
3778 python-pyyaml
3779 python-redis
3780 python-requests
3781 python-ujson
3782 python-url-normalize
3783 python-urllib3))
3784 (home-page "https://github.com/requests-cache/requests-cache")
3785 (synopsis "Persistent HTTP cache for Python requests")
3786 (description
3787 "This package provides a drop-in replacement for @code{requests.Session}
3788with caching offload to SQLite, Redis, MongoDB and AWS DynamoDB or save
3789responses as planin JSON/YAML file or save responses as plain JSON/YAML
3790files.")
3791 (license license:bsd-2)))
3792
3793(define-public python-requests-futures
3794 (package
3795 (name "python-requests-futures")
3796 (version "1.0.2")
3797 (source
3798 (origin
3799 (method url-fetch)
3800 (uri (pypi-uri "requests_futures" version))
3801 (sha256
3802 (base32 "1njqfjmd72l5f32jvcppg2afrvb0cd8angdwmq7q0vik81wvazkb"))))
3803 (build-system pyproject-build-system)
3804 (native-inputs
3805 (list python-greenlet
3806 python-pytest
3807 python-pytest-httpbin
3808 python-setuptools
3809 python-werkzeug))
3810 (propagated-inputs (list python-requests))
3811 (home-page "https://github.com/ross/requests-futures")
3812 (synopsis "Asynchronous Python HTTP for Humans")
3813 (description
3814 "This package provides and add-on the Python Requests HTTP library to run
3815code asynchronously.")
3816 (license license:asl2.0)))
3817
3818(define-public python-requests-unixsocket
3819 (package
3820 (name "python-requests-unixsocket")
3821 (version "0.4.1")
3822 (source
3823 (origin
3824 (method git-fetch)
3825 (uri (git-reference
3826 (url "https://github.com/msabramo/requests-unixsocket")
3827 (commit (string-append "v" version))))
3828 (file-name (git-file-name name version))
3829 (sha256
3830 (base32 "1f0pi31xqzm3cdag4s4gpdj36x169jwc8ibqvcwqz6h9c0pklf3n"))))
3831 (build-system pyproject-build-system)
3832 (native-inputs
3833 (list python-pytest
3834 python-setuptools
3835 python-setuptools-scm
3836 python-waitress))
3837 (propagated-inputs
3838 (list python-requests))
3839 (home-page "https://github.com/msabramo/requests-unixsocket")
3840 (synopsis "Use requests to talk HTTP via a UNIX domain socket")
3841 (description
3842 "This package provides an extension to @code{requests} which let it talk
3843HTTP via a UNIX domain socket.")
3844 (license license:asl2.0)))
3845
3846(define-public python-s3path
3847 (package
3848 (name "python-s3path")
3849 (version "0.6.4")
3850 (source
3851 (origin
3852 (method url-fetch)
3853 (uri (pypi-uri "s3path" version))
3854 (sha256
3855 (base32 "1lp5243jjf9ngqmajgnfr1px1kmpkfmgh248xlqz0nkww4wcy1hh"))))
3856 (build-system pyproject-build-system)
3857 (arguments
3858 (list
3859 ;; XXX: All tests fail with error: fixture 's3_mock' not found.
3860 #:tests? #f))
3861 (native-inputs
3862 (list python-setuptools
3863 python-wheel))
3864 (propagated-inputs
3865 (list python-boto3
3866 python-smart-open))
3867 (home-page "https://github.com/liormizr/s3path")
3868 (synopsis "Pathlib extension for AWS S3 Service")
3869 (description
3870 "S3Path provide a Python convenient File-System/Path like interface for
3871AWS S3 Service using boto3 S3 resource as a driver.")
3872 (license license:asl2.0)))
3873
3874(define-public python-falcon
3875 (package
3876 (name "python-falcon")
3877 (version "4.0.2")
3878 (source
3879 (origin
3880 ;; Use git, as there are some test files missing from the PyPI release,
3881 ;; such as 'examples' directory.
3882 (method git-fetch)
3883 (uri (git-reference
3884 (url "https://github.com/falconry/falcon")
3885 (commit version)))
3886 (file-name (git-file-name name version))
3887 (sha256
3888 (base32
3889 "1zhyvfbz4c1bxd4vbsgk19dzih6kkzgin10lmsr32x3b4qgnwqxs"))))
3890 (build-system pyproject-build-system)
3891 (arguments
3892 (list
3893 #:test-flags
3894 '(list "-k" "not slow"
3895 "--ignore-glob=examples/*" "--ignore-glob=bench/*" "tests")
3896 #:phases
3897 '(modify-phases %standard-phases
3898 (add-before 'check 'pre-check
3899 (lambda _
3900 (setenv "FALCON_ASGI_WRAP_NON_COROUTINES" "Y")
3901 (setenv "FALCON_TESTING_SESSION" "Y")
3902 (setenv "PYTHONASYNCIODEBUG" "1")
3903 (setenv "HOME" "/tmp"))))))
3904 (propagated-inputs
3905 (list python-mimeparse))
3906 (native-inputs
3907 (list python-aiofiles
3908 python-cbor2
3909 python-cython ;for faster binaries
3910 python-fakeredis
3911 python-httpx
3912 python-mujson
3913 python-msgpack
3914 python-orjson
3915 python-pecan
3916 python-pillow
3917 python-pytest
3918 python-pytest-asyncio
3919 python-pyyaml
3920 python-rapidjson
3921 python-requests
3922 python-setuptools
3923 python-testtools
3924 python-ujson
3925 python-websockets
3926 python-wheel))
3927 (home-page "https://falconframework.org")
3928 (synopsis "Web framework for building APIs and application backends")
3929 (description "Falcon is a web API framework for building microservices,
3930application backends and higher-level frameworks. Among its features are:
3931@itemize
3932@item Optimized and extensible code base
3933@item Routing via URI templates and REST-inspired resource
3934classes
3935@item Access to headers and bodies through request and response
3936classes
3937@item Request processing via middleware components and hooks
3938@item Idiomatic HTTP error responses
3939@item Straightforward exception handling
3940@item Unit testing support through WSGI helpers and mocks
3941@item Compatible with both CPython and PyPy
3942@item Cython support for better performance when used with CPython
3943@end itemize")
3944 (license license:asl2.0)))
3945
3946(define-public python-falcon-cors
3947 (package
3948 (name "python-falcon-cors")
3949 (properties '((commit . "41e9f075e193c1f76b26c0a8c67ad6e87462dfa6")
3950 (revision . "0")))
3951 (version (git-version "1.1.7"
3952 (assoc-ref properties 'revision)
3953 (assoc-ref properties 'commit)))
3954 (source
3955 (origin
3956 (method git-fetch)
3957 (uri (git-reference
3958 (url "https://github.com/lwcolton/falcon-cors")
3959 (commit (assoc-ref properties 'commit))))
3960 (file-name (git-file-name name version))
3961 (sha256
3962 (base32 "0iqz1i1p5xr32n34j77p2a86jmrkg1w90d2wcmmy1mhi5mgdm5gx"))))
3963 (build-system pyproject-build-system)
3964 (arguments
3965 (list
3966 ;; XXX: The last commit's tests are incompatible with the more recent
3967 ;; version of python-falcon.
3968 #:tests? #f))
3969 (native-inputs
3970 (list python-falcon python-mock python-pynose python-setuptools))
3971 (home-page "https://github.com/lwcolton/falcon-cors")
3972 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
3973 (description
3974 "This middleware provides @dfn{cross-origin resource sharing} (CORS)
3975support for Falcon. It allows applying a specially crafted CORS object to the
3976incoming requests, enabling the ability to serve resources over a different
3977origin than that of the web application.")
3978 (license license:asl2.0)))
3979
3980(define-public python-furl
3981 (package
3982 (name "python-furl")
3983 (version "2.1.4")
3984 (source
3985 (origin
3986 (method url-fetch)
3987 (uri (pypi-uri "furl" version))
3988 (sha256
3989 (base32 "05b058xisv8kghvcpaxvssml2jjkh1cmzyrrjwk2kjb62985fxl7"))))
3990 (build-system pyproject-build-system)
3991 (arguments
3992 (list #:test-flags
3993 #~(list "-k" (string-append "not test_hosts"
3994 " and not test_netloc"
3995 " and not test_odd_urls"))))
3996 (propagated-inputs
3997 (list python-orderedmultidict python-six))
3998 (native-inputs
3999 (list python-pytest python-setuptools python-wheel))
4000 (home-page "https://github.com/gruns/furl")
4001 (synopsis "URL manipulation in Python")
4002 (description "Furl provides an easy-to-use alternative to the
4003@code{urllib} and @code{urlparse} modules for manipulating URLs.")
4004 (license license:unlicense)))
4005
4006(define-public python-httplib2
4007 (package
4008 (name "python-httplib2")
4009 (version "0.31.2")
4010 (source
4011 (origin
4012 (method git-fetch)
4013 (uri (git-reference
4014 (url "https://github.com/httplib2/httplib2")
4015 (commit (string-append "v" version))))
4016 (file-name (git-file-name name version))
4017 (sha256
4018 (base32
4019 "0wdnf4rhw9ar8b15lzvif11ibnnpqkfif3alkhkfywy3ikk8nrxb"))))
4020 (build-system pyproject-build-system)
4021 (arguments
4022 (list
4023 #:phases
4024 #~(modify-phases %standard-phases
4025 (add-after 'unpack 'adjust-test-requirements
4026 (lambda _
4027 (substitute* "requirements-test.txt"
4028 (("==") ">=")))))))
4029 (propagated-inputs
4030 (list python-pyparsing
4031 python-pysocks))
4032 (native-inputs
4033 (list python-cryptography
4034 python-mock
4035 python-pytest
4036 python-pytest-randomly
4037 python-pytest-timeout
4038 python-setuptools))
4039 (home-page "https://github.com/httplib2/httplib2")
4040 (synopsis "Comprehensive HTTP client library")
4041 (description
4042 "A comprehensive HTTP client library supporting many features left out of
4043other HTTP libraries.")
4044 (license license:expat)))
4045
4046(define-public python-cheroot
4047 (package
4048 (name "python-cheroot")
4049 (version "11.1.2")
4050 (source
4051 (origin
4052 (method git-fetch)
4053 (uri (git-reference
4054 (url "https://github.com/cherrypy/cheroot")
4055 (commit (string-append "v" version))))
4056 (file-name (git-file-name name version))
4057 (sha256
4058 (base32 "02rhci01m5fcn8mqpvq3c35rs4n28gxlfvfw2if2f85rgwrji8y8"))))
4059 (build-system pyproject-build-system)
4060 (arguments
4061 (list
4062 #:phases
4063 #~(modify-phases %standard-phases
4064 (add-after 'unpack 'fix-pytest-config
4065 (lambda _
4066 ;; See: <https://codeberg.org/guix/guix/issues/7476>.
4067 (delete-file "pytest.ini"))))))
4068 (native-inputs
4069 (list python-portend
4070 python-pyopenssl
4071 python-pypytools
4072 python-pytest
4073 python-pytest-mock
4074 python-requests
4075 python-requests-toolbelt
4076 python-requests-unixsocket2
4077 python-setuptools
4078 python-setuptools-scm
4079 python-trustme))
4080 (propagated-inputs
4081 (list python-jaraco-functools
4082 python-more-itertools))
4083 (home-page "https://cheroot.cherrypy.dev")
4084 (synopsis "Highly-optimized, pure-python HTTP server")
4085 (description
4086 "Cheroot is a high-performance, pure-Python HTTP server.")
4087 (license license:bsd-3)))
4088
4089(define-public python-cherrypy
4090 (package
4091 (name "python-cherrypy")
4092 (properties '((commit . "1f75bc9eed8e0e385f64f368bd69f58d96fb8c2b")
4093 (revision . "0")))
4094 (version (git-version "18.10.0"
4095 (assoc-ref properties 'revision)
4096 (assoc-ref properties 'commit)))
4097 (source
4098 (origin
4099 (method git-fetch)
4100 (uri (git-reference
4101 (url "https://github.com/cherrypy/cherrypy")
4102 (commit (assoc-ref properties 'commit))))
4103 (file-name (git-file-name name version))
4104 (sha256
4105 (base32 "1l01a4sbfm42s5xp6ngphgqf0yb65ksqbsb27kznvybblyaxfa9p"))))
4106 (build-system pyproject-build-system)
4107 (arguments
4108 (list
4109 #:test-flags
4110 #~(map
4111 (lambda (test)
4112 (string-append "--deselect=cherrypy/test/" test))
4113 (list
4114 ;; Requires bumping python-flaky.
4115 "test_bus.py::test_wait_publishes_periodically"
4116 "test_bus.py::test_block"
4117 "test_bus.py::test_start_with_callback"
4118 "test_refleaks.py::ReferenceTests::test_threadlocal_garbage"
4119 "test_session.py::SessionTest::test_0_Session"
4120 "test_session.py::SessionTest::test_2_File_Concurrency"
4121 ;; assert b'RamSession' == b'FileSession' or FileNotFoundError
4122 "test_session.py::SessionTest::test_3_Redirect"
4123 "test_session.py::SessionTest::test_4_File_deletion"))
4124 #:phases
4125 #~(modify-phases %standard-phases
4126 (add-after 'unpack 'fix-pytest-config
4127 (lambda _
4128 ;; See: <https://codeberg.org/guix/guix/issues/7476>.
4129 (delete-file "pytest.ini")))
4130 (add-after 'unpack 'patch-pyproject
4131 (lambda _
4132 (substitute* "pyproject.toml"
4133 (("\"cherrypy.scaffold\",")
4134 (string-join
4135 (list "\"cherrypy.scaffold\""
4136 "\"cherrypy._private_api\""
4137 "\"cherrypy._private_api.compat\",")
4138 ",\n "))))))))
4139 (propagated-inputs
4140 (list python-cheroot
4141 python-filelock
4142 python-jaraco-collections
4143 python-more-itertools
4144 python-portend
4145 python-zc-lockfile))
4146 (native-inputs
4147 (list python-flaky
4148 python-objgraph
4149 python-path
4150 python-pytest
4151 python-pytest-forked
4152 python-pytest-services
4153 python-pytest-sugar
4154 python-requests-toolbelt
4155 python-setuptools
4156 python-setuptools-scm))
4157 (home-page "https://www.cherrypy.dev")
4158 (synopsis "Object-Oriented HTTP framework")
4159 (description
4160 "CherryPy is a pythonic, object-oriented web framework. It helps in
4161building web applications in the same way any other object-oriented Python
4162program would be built.")
4163 (license license:bsd-3)))
4164
4165(define-public python-parfive
4166 (package
4167 (name "python-parfive")
4168 (version "2.3.1")
4169 (source
4170 (origin
4171 (method git-fetch)
4172 (uri (git-reference
4173 (url "https://github.com/Cadair/parfive")
4174 (commit (string-append "v" version))))
4175 (file-name (git-file-name name version))
4176 (sha256
4177 (base32 "09kkh7kp9qy8m26zk6p7zc84yrc81pjgsi594kaa1v1n83mprl4b"))))
4178 (build-system pyproject-build-system)
4179 (arguments
4180 (list
4181 #:test-flags
4182 ;; Disable tests requiring network access.
4183 #~(list "-k" (string-join
4184 (list "not test_ftp"
4185 "test_ftp_http"
4186 "test_ftp_pasv_command"
4187 "test_problematic_http_urls")
4188 " and not "))))
4189 (native-inputs
4190 (list python-aiofiles
4191 python-pytest
4192 python-pytest-asyncio
4193 python-pytest-localserver
4194 python-pytest-socket
4195 python-setuptools
4196 python-setuptools-scm))
4197 (propagated-inputs
4198 (list python-aiohttp
4199 python-tqdm
4200 ;; [optional]
4201 python-aioftp))
4202 (home-page "https://parfive.readthedocs.io/")
4203 (synopsis "HTTP and FTP parallel file downloader")
4204 (description
4205 "This package provides CLI tool and Python library @code{parallel} file
4206downloader using asyncio. parfive can handle downloading multiple files in
4207parallel as well as downloading each file in a number of chunks.
4208
4209asciicast demo of parfive parfive works by creating a downloader object,
4210appending files to it and then running the download. parfive has a synchronous
4211API, but uses asyncio to parallelise downloading the files.")
4212 (license license:expat)))
4213
4214(define-public python-html2text
4215 (package
4216 (name "python-html2text")
4217 (version "2020.1.16")
4218 (source
4219 (origin
4220 (method url-fetch)
4221 (uri (pypi-uri "html2text" version))
4222 (sha256
4223 (base32 "1fvv4z6dblii2wk1x82981ag8yhxbim1v2ksgywxsndh2s7335p2"))))
4224 (build-system pyproject-build-system)
4225 (native-inputs (list python-pytest python-setuptools python-wheel))
4226 (home-page "https://github.com/Alir3z4/html2text")
4227 (synopsis "Convert HTML into plain text")
4228 (description
4229 "html2text takes HTML and converts it into plain ASCII text
4230which is also valid markdown. html2text was originally written by Aaron
4231Swartz.")
4232 (license license:gpl3+)))
4233
4234(define-public python-jose
4235 (package
4236 (name "python-jose")
4237 (version "3.5.0")
4238 (home-page "https://github.com/mpdavis/python-jose")
4239 (source (origin
4240 (method git-fetch)
4241 (uri (git-reference (url home-page) (commit version)))
4242 (file-name (git-file-name name version))
4243 (sha256
4244 (base32
4245 "0frv7r6q43mjl7s82hh8qvqpdgyfvmyq2b6aq4402riq2i238d7h"))))
4246 (build-system pyproject-build-system)
4247 (native-inputs
4248 (list python-pyasn1 python-pytest python-setuptools))
4249 (propagated-inputs
4250 (list python-cryptography python-ecdsa python-rsa))
4251 (synopsis "JOSE implementation in Python")
4252 (description
4253 "The @dfn{JavaScript Object Signing and Encryption} (JOSE) technologies
4254- JSON Web Signature (JWS), JSON Web Encryption (JWE), JSON Web Key (JWK), and
4255JSON Web Algorithms (JWA) - collectively can be used to encrypt and/or sign
4256content using a variety of algorithms.")
4257 (license license:expat)))
4258
4259(define-public python-joserfc
4260 (package
4261 (name "python-joserfc")
4262 (version "1.0.1")
4263 (source
4264 (origin
4265 (method url-fetch)
4266 (uri (pypi-uri "joserfc" version))
4267 (sha256
4268 (base32 "11m600bmj70bp96wxhwvyj4d57w0zahzq3vic7s4a4k85pl7nl64"))))
4269 (build-system pyproject-build-system)
4270 (arguments
4271 (list
4272 #:test-flags
4273 ;; No module named 'Crypto'
4274 '(list "--ignore=tests/jwe/test_chacha20.py"
4275 ;; Deprecation warnings are not raised.
4276 "-k" (string-append "not test_guess_bytes_key"
4277 " and not test_guess_callable_key"
4278 " and not test_guess_str_key"))))
4279 (propagated-inputs (list python-cryptography))
4280 (native-inputs (list python-pytest python-setuptools python-wheel))
4281 (home-page "https://github.com/authlib/joserfc")
4282 (synopsis "Python library for JOSE RFCs")
4283 (description
4284 "This package provides a Python library for JOSE RFCs, including JWS,
4285JWE, JWK, JWA, and JWT.")
4286 (license license:bsd-3)))
4287
4288(define-public python-jwcrypto
4289 (package
4290 (name "python-jwcrypto")
4291 (version "1.5.6")
4292 (source
4293 (origin
4294 (method url-fetch)
4295 (uri (pypi-uri "jwcrypto" version))
4296 (sha256
4297 (base32 "0fdhn5jrsdxqr1yr6rmh585q4j08z1aajn392vk1l20c59v8f6kp"))))
4298 (build-system pyproject-build-system)
4299 (native-inputs
4300 (list python-pytest
4301 python-setuptools))
4302 (propagated-inputs
4303 (list python-cryptography
4304 python-typing-extensions))
4305 (home-page "https://github.com/latchset/jwcrypto")
4306 (synopsis "Implementation of JOSE Web standards")
4307 (description
4308 "WCrypto is an implementation of the @dfn{Javascript Object Signing and
4309Encryption} (JOSE) Web Standards.")
4310 (license license:lgpl3+)))
4311
4312(define-public python-pypitoken
4313 (package
4314 (name "python-pypitoken")
4315 (version "7.0.1")
4316 (source
4317 (origin
4318 (method url-fetch)
4319 (uri (pypi-uri "pypitoken" version))
4320 (sha256
4321 (base32 "18hhwmdfs9y5ypl1n8z2h2ys2f52mv5xr043gzgb34mpmg0wi46x"))))
4322 (build-system pyproject-build-system)
4323 ;; There are no tests.
4324 (arguments (list #:tests? #false))
4325 (propagated-inputs (list python-jsonschema python-pymacaroons
4326 python-typing-extensions))
4327 (native-inputs (list python-poetry-core))
4328 (home-page "https://pypitoken.readthedocs.io/en/latest/")
4329 (synopsis "Manipulate PyPI API tokens")
4330 (description "This package lets you manipulate PyPI API tokens.")
4331 (license license:expat)))
4332
4333(define-public python-pyscss
4334 ;; XXX: no fresh release supporting Python 3.11, use the latest commit, see
4335 ;; <https://github.com/Kronuz/pyScss/issues/428>,
4336 ;; <https://github.com/Kronuz/pyScss/issues/431>.
4337 (let ((commit "73559d047706ccd4593cf6aa092de71f35164723")
4338 (revision "0"))
4339 (package
4340 (name "python-pyscss")
4341 (version (git-version "1.4.0" revision commit))
4342 (source
4343 (origin
4344 (method git-fetch) ; no tests in PyPI release
4345 (uri (git-reference
4346 (url "https://github.com/Kronuz/pyScss")
4347 (commit commit)))
4348 (file-name (git-file-name name version))
4349 (sha256
4350 (base32 "00msypxf5dm57gyfp3jxvjinigi4km84v33w83635pms9li2k3y7"))))
4351 (build-system pyproject-build-system)
4352 (native-inputs
4353 (list python-pytest-8
4354 python-setuptools))
4355 (inputs
4356 (list pcre))
4357 (propagated-inputs
4358 (list python-six)) ;hard dependency in scss/compiler.py
4359 (home-page "https://github.com/Kronuz/pyScss")
4360 (synopsis "Scss compiler for Python")
4361 (description
4362 "@code{pyScss} is a compiler for Sass, a superset language of
4363CSS3 that adds programming capabilities and some other syntactic sugar.")
4364 (license license:expat))))
4365
4366(define-public python-jsonpickle
4367 (package
4368 (name "python-jsonpickle")
4369 (version "4.0.0")
4370 (source (origin
4371 (method url-fetch)
4372 (uri (pypi-uri "jsonpickle" version))
4373 (sha256
4374 (base32
4375 "0dipys8p4hkqnp9nwkpysfv7mhws2hrr73wgn00pdmq4n990hrzw"))))
4376 (build-system pyproject-build-system)
4377 (arguments
4378 (list
4379 #:test-flags '(list "tests")
4380 #:phases
4381 '(modify-phases %standard-phases
4382 (add-before 'check 'pre-check
4383 (lambda* (#:key inputs #:allow-other-keys)
4384 (setenv "TZ" "UTC")
4385 (setenv "TZDIR"
4386 (search-input-directory inputs "share/zoneinfo")))))))
4387 (native-inputs
4388 (list python-bson
4389 python-ecdsa
4390 python-feedparser
4391 python-pymongo
4392 python-pytest
4393 python-pytest-benchmark
4394 python-pytest-enabler
4395 python-setuptools
4396 python-setuptools-scm
4397 python-simplejson
4398 python-sqlalchemy
4399 python-ujson
4400 python-wheel
4401 tzdata-for-tests))
4402 (home-page "https://jsonpickle.github.io/")
4403 (synopsis "Serialize object graphs into JSON")
4404 (description
4405 "This package provides a Python library for serializing any arbitrary
4406object graph to and from JSON.")
4407 (license license:bsd-3)))
4408
4409(define-public python-mcp
4410 (package
4411 (name "python-mcp")
4412 (version "1.25.0")
4413 (source
4414 (origin
4415 (method url-fetch)
4416 (uri (pypi-uri "mcp" version))
4417 (sha256
4418 (base32 "00k87bl4jvnh7hrmicwb2m715fwccvvlanwf8cnlwdphxdhh6can"))))
4419 (build-system pyproject-build-system)
4420 (arguments
4421 (list
4422 ;; XXX: 186 failed, 648 passed, 94 skipped, 54 errors
4423 ;; A lot of tests fail for unclear reasons.
4424 #:tests? #f))
4425 (propagated-inputs (list python-httpx python-pydantic))
4426 (native-inputs
4427 (list python-hatchling
4428 python-httpx-sse
4429 python-jsonschema
4430 python-pydantic-settings
4431 python-pytest
4432 python-pytest-examples
4433 python-pytest-xdist
4434 python-sse-starlette
4435 python-starlette
4436 python-typer
4437 python-typing-inspection
4438 python-uvicorn))
4439 (home-page "https://modelcontextprotocol.io")
4440 (synopsis "Model Context Protocol SDK")
4441 (description
4442 "This package provides a Python Software Development Kit for the Model
4443Context Protocol (MCP).")
4444 (license license:expat)))
4445
4446(define-public python-mechanicalsoup
4447 (package
4448 (name "python-mechanicalsoup")
4449 (version "1.4.0")
4450 (source
4451 (origin
4452 (method url-fetch)
4453 (uri (pypi-uri "mechanicalsoup" version))
4454 (sha256
4455 (base32 "0k1ac77ld6jyjm5fsr44399l5gmiwnz5w6s74i3qqx2scfbsgs6w"))))
4456 (build-system pyproject-build-system)
4457 (arguments
4458 (list
4459 #:test-flags
4460 ;; Unclear why test fails.
4461 #~(list "-k" "not test_select_form_associated_elements")
4462 ;; The following dependencies are not directly required, the developer
4463 ;; only pinned versions because of vulnerabilities. They also break
4464 ;; sanity-check because it checks for a python-certifi version which is
4465 ;; more recent than the one available in Guix.
4466 #:phases #~(modify-phases %standard-phases
4467 (add-after 'unpack 'relax-dependencies
4468 (lambda _
4469 (substitute* "requirements.txt"
4470 (("certifi.*") "")
4471 (("urllib3.*") "")))))))
4472 (propagated-inputs
4473 (list python-beautifulsoup4 python-lxml python-requests))
4474 (native-inputs
4475 (list python-pytest
4476 python-pytest-flake8
4477 python-pytest-httpbin
4478 python-pytest-mock
4479 python-requests-mock
4480 python-setuptools
4481 python-wheel))
4482 (home-page "https://mechanicalsoup.readthedocs.io/")
4483 (synopsis "Python library for automating website interaction")
4484 (description
4485 "MechanicalSoup is a Python library for automating interaction with
4486websites. It automatically stores and sends cookies, follows redirects, and can
4487follow links and submit forms. It doesn’t do JavaScript.")
4488 (license license:expat)))
4489
4490(define-public python-hypercorn
4491 (package
4492 (name "python-hypercorn")
4493 (version "0.18.0")
4494 (source
4495 (origin
4496 (method git-fetch)
4497 (uri (git-reference
4498 (url "https://github.com/pgjones/hypercorn")
4499 (commit version)))
4500 (file-name (git-file-name name version))
4501 (sha256
4502 (base32 "0jdi05n5isxn0rysq242p198lz03gbwsnizzb9yp6rxr7ajapns4"))))
4503 (build-system pyproject-build-system)
4504 (propagated-inputs
4505 (list python-aioquic
4506 python-h11
4507 python-h2
4508 python-priority
4509 python-pydata-sphinx-theme
4510 python-sphinxcontrib-mermaid
4511 python-tomli
4512 python-trio
4513 python-typing-extensions
4514 python-uvloop
4515 python-wsproto))
4516 (native-inputs
4517 (list nss-certs-for-test
4518 python-httpx
4519 python-pdm-backend
4520 python-pytest
4521 python-pytest-asyncio
4522 python-pytest-cov
4523 python-pytest-trio))
4524 (home-page "https://github.com/pgjones/hypercorn")
4525 (synopsis "ASGI Server based on Hyper libraries")
4526 (description
4527 "This package provides an ASGI (Asynchronous Server Gateway Interface)
4528Server based on Hyper libraries and inspired by @code{python-gunicorn}.")
4529 (license license:expat)))
4530
4531(define-public python-hyperframe
4532 (package
4533 (name "python-hyperframe")
4534 (version "6.1.0")
4535 (source
4536 (origin
4537 (method url-fetch)
4538 (uri (pypi-uri "hyperframe" version))
4539 (sha256
4540 (base32 "021v58w1b7mbwqkvbz11p3a4qk1sj91jnf6nmgg7ljl502590c7n"))))
4541 (build-system pyproject-build-system)
4542 (native-inputs
4543 (list python-pytest python-setuptools))
4544 (home-page "https://github.com/python-hyper/hyperframe")
4545 (synopsis "HTTP/2 framing layer for Python")
4546 (description
4547 "This library contains the HTTP/2 framing code used in the hyper project.
4548It provides a pure-Python codebase that is capable of decoding a binary stream
4549into HTTP/2 frames.")
4550 (license license:expat)))
4551
4552(define-public python-hpack
4553 (package
4554 (name "python-hpack")
4555 (version "4.1.0")
4556 (source
4557 (origin
4558 ;; PyPI tarball is missing some files necessary for the tests.
4559 (method git-fetch)
4560 (uri (git-reference
4561 (url "https://github.com/python-hyper/hpack")
4562 (commit (string-append "v" version))))
4563 (file-name (git-file-name name version))
4564 (sha256
4565 (base32 "1kgbx38p3a48iz914dqbx7av750a3s3x5kj3rvpcbh23ah75zg5x"))))
4566 (build-system pyproject-build-system)
4567 (native-inputs
4568 (list python-pytest python-setuptools))
4569 (home-page "https://hyper.rtfd.org")
4570 (synopsis "Pure-Python HPACK header compression")
4571 (description
4572 "This module contains a pure-Python HTTP/2 header encoding (HPACK) logic
4573for use in Python programs that implement HTTP/2.")
4574 (license license:expat)))
4575
4576(define-public python-h11
4577 (package
4578 (name "python-h11")
4579 (version "0.16.0")
4580 (source
4581 (origin
4582 (method url-fetch)
4583 (uri (pypi-uri "h11" version))
4584 (sha256
4585 (base32 "1wazxq4b4jg5001h5ypvz9pvrg80pagyd1aqm962wya5rxbbjdaf"))))
4586 (build-system pyproject-build-system)
4587 (native-inputs
4588 (list python-pytest python-setuptools))
4589 (home-page "https://github.com/python-hyper/h11")
4590 (synopsis "Pure-Python, bring-your-own-I/O implementation of HTTP/1.1")
4591 (description
4592 "This is a little HTTP/1.1 library written from scratch in Python, heavily
4593inspired by hyper-h2. It's a bring-your-own-I/O library; h11 contains no IO
4594code whatsoever. This means you can hook h11 up to your favorite network API,
4595and that could be anything you want.")
4596 (license license:expat)))
4597
4598(define-public python-h2
4599 (package
4600 (name "python-h2")
4601 (version "4.1.0")
4602 (source
4603 (origin
4604 (method url-fetch)
4605 (uri (pypi-uri "h2" version))
4606 (sha256
4607 (base32 "1fraip114fm1ha5w37pdc0sk8dn9pb0ck267zrwwpap7zc4clfm8"))))
4608 (build-system pyproject-build-system)
4609 (arguments
4610 (list
4611 ;; AssertionError: assert '<RemoteSettingsChanged
4612 ;; changed_settings:{ChangedSetting(setting=4, original_value=65536,
4613 ;; new_value=32768)}>' == '<RemoteSettingsChanged
4614 ;; changed_settings:{ChangedSetting(setting=SettingCodes.INITIAL_WINDOW_SIZE,
4615 ;; original_value=65536, new_value=32768)}>'
4616 #:test-flags
4617 #~(list "-k"
4618 (string-join
4619 (list "not test_remotesettingschanged_repr"
4620 ;; This test exceededs the Hypothesis deadline.
4621 #$@(if (target-riscv64?)
4622 #~("test_changing_max_frame_size")
4623 #~())
4624 "test_streamreset_repr"
4625 "test_settingsacknowledged_repr"
4626 "test_connectionterminated_repr[None-None]"
4627 "test_connectionterminated_repr[some"
4628 "test_remotesettingschanged_repr"
4629 "test_streamreset_repr"
4630 "test_settingsacknowledged_repr"
4631 "test_connectionterminated_repr[None-None]"
4632 "test_connectionterminated_repr[some")
4633 " and not "))))
4634 (native-inputs
4635 (list python-pytest
4636 python-setuptools
4637 python-wheel))
4638 (propagated-inputs
4639 (list python-hpack
4640 python-hyperframe))
4641 (home-page "https://github.com/python-hyper/h2")
4642 (synopsis "HTTP/2 State-Machine based protocol implementation")
4643 (description
4644 "This module contains a pure-Python implementation of a HTTP/2 protocol
4645stack. It does not provide a parsing layer, a network layer, or any rules
4646about concurrency. Instead, it's a purely in-memory solution, defined in
4647terms of data actions and HTTP/2 frames. This is one building block of a full
4648Python HTTP implementation.")
4649 (license license:expat)))
4650
4651(define-public python-slixmpp
4652 (package
4653 (name "python-slixmpp")
4654 (version "1.8.6") ; XXX: The latest version which does not require Rust
4655 (source
4656 (origin
4657 (method git-fetch)
4658 (uri (git-reference
4659 (url "https://codeberg.org/poezio/slixmpp")
4660 (commit (string-append "slix-" version))))
4661 (file-name (git-file-name name version))
4662 (sha256
4663 (base32 "0gpy6arwyk4lsx1hbcwbllxs6qbwn58adkp1rm1cfvfrjdv5kxx7"))))
4664 (build-system pyproject-build-system)
4665 (arguments
4666 (list
4667 #:phases
4668 #~(modify-phases %standard-phases
4669 (add-after 'unpack 'patch-setup.py
4670 (lambda _
4671 (substitute* "setup.py"
4672 (("'CC', 'cc'")
4673 "'CC', 'gcc'")))))))
4674 (native-inputs
4675 (list gnupg
4676 pkg-config
4677 python-cython
4678 python-setuptools
4679 python-wheel))
4680 (inputs
4681 (list libidn
4682 python)) ; We are building a Python extension.
4683 (propagated-inputs
4684 (list python-aiodns
4685 python-aiohttp
4686 python-cryptography
4687 python-defusedxml
4688 python-emoji
4689 python-pyasn1
4690 python-pyasn1-modules))
4691 (home-page "https://lab.louiz.org/poezio/slixmpp")
4692 (synopsis "XMPP library without threads")
4693 (description
4694 "Slixmpp is a XMPP library for Python 3.7+. It is a fork of SleekXMPP.
4695Its goal is to only rewrite the core of the library (the low level socket
4696handling, the timers, the events dispatching) in order to remove all
4697threads.")
4698 (license license:expat)))
4699
4700(define-public python-sockjs-tornado
4701 (package
4702 (name "python-sockjs-tornado")
4703 (version "1.0.6")
4704 (source
4705 (origin
4706 (method git-fetch)
4707 (uri (git-reference
4708 (url "https://github.com/mrjoes/sockjs-tornado/")
4709 (commit (string-append "v" version))))
4710 (file-name (git-file-name name version))
4711 (sha256
4712 (base32 "1y4wjca1776nvd0b79pz4d52i312xsyb2vahb883qmrw6s56mynk"))))
4713 (build-system pyproject-build-system)
4714 (arguments
4715 (list
4716 #:tests? #f)) ;The only test in examples/test/test.py runs a server.
4717 (native-inputs (list python-setuptools))
4718 (propagated-inputs (list python-tornado))
4719 (home-page "https://github.com/mrjoes/sockjs-tornado/")
4720 (synopsis
4721 "SockJS Python server implementation on top of the Tornado framework")
4722 (description
4723 "SockJS-tornado provides the server-side counterpart to a SockJS client
4724library, through the Tornado framework.
4725
4726SockJS provides a low-latency, full-duplex, cross-domain communication channel
4727between a web browser and web server.")
4728 (license license:expat)))
4729
4730(define-public python-flask-assets
4731 ;; The latest release still depends on the abandoned flask-script, whereas
4732 ;; at this later commit (already 2 years old at the time of this writing)
4733 ;; the dependency has been lifted.
4734 (let ((commit "62efd23fe95ee6a86fc1cfaa98fc1e2152093557")
4735 (revision "1"))
4736 (package
4737 (name "python-flask-assets")
4738 (version (git-version "2.1.0" revision commit))
4739 (source
4740 (origin
4741 (method git-fetch)
4742 (uri (git-reference
4743 (url "https://github.com/miracle2k/flask-assets/")
4744 (commit commit)))
4745 (file-name (git-file-name name version))
4746 (sha256
4747 (base32 "11q8vm2ipj4xrvawy9vl1l4k8kb4r72ghy1n8xrzci52v6lx8960"))))
4748 (build-system pyproject-build-system)
4749 (propagated-inputs
4750 (list python-flask python-webassets))
4751 (native-inputs
4752 (list nss-certs-for-test python-pytest python-setuptools python-wheel))
4753 (home-page "https://github.com/miracle2k/flask-assets")
4754 (synopsis "Asset management for Flask")
4755 (description "This package integrates @code{webassets} with Flask, adding
4756support for merging, minifying and compiling CSS and Javascript files.")
4757 (license license:bsd-2))))
4758
4759(define-public python-flask-babel
4760 (package
4761 (name "python-flask-babel")
4762 (version "4.0.0")
4763 (source
4764 (origin
4765 (method git-fetch) ;no tests in pypi release
4766 (uri (git-reference
4767 (url "https://github.com/python-babel/flask-babel")
4768 (commit (string-append "v" version))))
4769 (sha256
4770 (base32
4771 "19yq3f5rixbwhv7wxdarvi9hdj98a9dq8y76in9c1q3jxaigw104"))))
4772 (build-system pyproject-build-system)
4773 (native-inputs
4774 (list python-poetry-core
4775 python-pytest
4776 python-pytest-mock))
4777 (propagated-inputs
4778 (list python-babel
4779 python-flask
4780 python-jinja2
4781 python-pytz))
4782 (home-page "https://github.com/python-babel/flask-babel")
4783 (synopsis "Add i18n/l10n support to Flask applications")
4784 (description "This package implements internationalization and localization
4785support for Flask. This is based on the Python babel module as well as pytz -
4786both of which are installed automatically if you install this library.")
4787 (license license:bsd-3)))
4788
4789(define-public python-flask-cors
4790 (package
4791 (name "python-flask-cors")
4792 (version "6.0.2")
4793 (source
4794 (origin
4795 (method git-fetch) ;no tests in PyPI archive
4796 (uri (git-reference
4797 (url "https://github.com/CoryDolphin/flask-cors")
4798 (commit version)))
4799 (file-name (git-file-name name version))
4800 (sha256
4801 (base32 "02y740h951dscgkm7ghsss1bc0m8ymsfdpsimm1j0nkl0zjl6sgm"))))
4802 (build-system pyproject-build-system)
4803 (arguments
4804 (list
4805 #:phases
4806 #~(modify-phases %standard-phases
4807 (add-after 'unpack 'fix-version
4808 (lambda _
4809 ;; Otherwise sanity-check of dependents will fail.
4810 (substitute* "pyproject.toml"
4811 (("version = \"0\\.0\\.1\"" all)
4812 (string-append "version = \"" #$version "\""))))))))
4813 (native-inputs
4814 (list python-pytest
4815 python-setuptools))
4816 (propagated-inputs
4817 (list python-flask
4818 python-werkzeug))
4819 (home-page "https://flask-cors.readthedocs.io/en/latest/")
4820 (synopsis "Handle Cross-Origin Resource Sharing with Flask")
4821 (description
4822 "This package provides a Flask extension for handling @acronym{CORS,Cross
4823Origin Resource Sharing}, making cross-origin AJAX possible.")
4824 (license license:expat)))
4825
4826(define-public python-flask-markdown
4827 (package
4828 (name "python-flask-markdown")
4829 (version "0.3")
4830 (source
4831 (origin
4832 (method git-fetch)
4833 (uri (git-reference
4834 (url "https://github.com/dcolish/flask-markdown")
4835 (commit version)))
4836 (file-name (git-file-name name version))
4837 (sha256
4838 (base32 "1rqqmvjc4rjal6l4y3caxw9b3157pl923h4i1ihbm0gziqv3g2hl"))))
4839 (build-system pyproject-build-system)
4840 (arguments
4841 (list
4842 #:tests? #f ;Tests seem to be incompatible with latest python
4843 #:phases
4844 #~(modify-phases %standard-phases
4845 (add-after 'unpack 'set-version
4846 (lambda _
4847 (substitute* "setup.py"
4848 (("dev")
4849 #$version)))))))
4850 (propagated-inputs (list python-markdown python-flask))
4851 (native-inputs (list python-pynose python-setuptools))
4852 (home-page "https://github.com/dcolish/flask-markdown")
4853 (synopsis "Small extension to help with using Markdown in Flask")
4854 (description
4855 "Flask-Markdown supports several extensions for Markdown and integrates
4856into Jinja2 by default.")
4857 (license license:bsd-3)))
4858
4859(define-public python-flask-session
4860 (package
4861 (name "python-flask-session")
4862 (version "0.8.0")
4863 (source
4864 (origin
4865 (method url-fetch)
4866 (uri (pypi-uri "flask_session" version))
4867 (sha256
4868 (base32
4869 "1zs20zpq6gxz9gsccbd2jrrbbcfvh0x9z9741gkr8dhh07mlbq10"))))
4870 (build-system pyproject-build-system)
4871 (arguments
4872 '(#:tests? #f)) ; Tests require the various storage backends to be present
4873 (native-inputs (list python-flit-core))
4874 (propagated-inputs
4875 (list python-cachelib python-flask python-msgspec))
4876 (home-page "https://github.com/pallets-eco/flask-session")
4877 (synopsis "Adds server-side session support to your Flask application")
4878 (description
4879 "Flask-Session is an extension for Flask that adds support for
4880Server-side sessions, with a variety of different backends for session
4881storage.")
4882 (license license:bsd-3)))
4883
4884(define-public python-html5lib
4885 (package
4886 (name "python-html5lib")
4887 (version "1.1")
4888 (source
4889 (origin
4890 (method url-fetch)
4891 (uri (pypi-uri "html5lib" version))
4892 (sha256
4893 (base32 "0vqlhk0hgbsfkh7ybmby93xhlx8dq6pr5blf356ka3z2c41b9rdj"))))
4894 (build-system pyproject-build-system)
4895 (arguments
4896 '(#:tests? #f)) ;tests depend on dated pytest-expect
4897 (native-inputs
4898 (list python-setuptools))
4899 (propagated-inputs
4900 (list python-six
4901 python-webencodings
4902 ;; Required by Calibre 5.
4903 python-chardet))
4904 (home-page "https://github.com/html5lib/html5lib-python")
4905 (synopsis "Python HTML parser based on the WHATWG HTML specification")
4906 (description
4907 "Html5lib is an HTML parser based on the WHATWG HTML specification
4908and written in Python.")
4909 (license license:expat)))
4910
4911(define-public python-html5-parser
4912 (package
4913 (name "python-html5-parser")
4914 (version "0.4.12")
4915 (source
4916 (origin
4917 (method git-fetch)
4918 (uri (git-reference
4919 (url "https://github.com/kovidgoyal/html5-parser")
4920 (commit (string-append "v" version))))
4921 (file-name (git-file-name name version))
4922 (sha256
4923 (base32 "0axrz2x67nhsh3kijy68wwy5hx8h8418d8g2qz6f3pyxix7gw2fi"))))
4924 (build-system pyproject-build-system)
4925 (arguments
4926 (list
4927 #:phases
4928 #~(modify-phases %standard-phases
4929 (add-before 'build 'set-configure-flags
4930 (lambda _
4931 (setenv "CFLAGS" "-Wno-error=implicit-function-declaration"))))))
4932 (native-inputs (list pkg-config python-setuptools))
4933 (inputs (list libxml2))
4934 (propagated-inputs (list python-lxml python-beautifulsoup4 python-chardet))
4935 (home-page "https://html5-parser.readthedocs.io")
4936 (synopsis "Fast C-based HTML5 parsing for Python")
4937 (description
4938 "This package provides a fast implementation of the HTML5 parsing spec
4939for Python. Parsing is done in C using a variant of the gumbo parser. The
4940gumbo parse tree is then transformed into an lxml tree, also in C, yielding
4941parse times that can be a thirtieth of the html5lib parse times.")
4942 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
4943 ;; indicate ASL2.0, including the LICENSE file for the whole project.
4944 (license (list license:asl2.0 license:gpl3))))
4945
4946(define-public python-html5tagger
4947 (package
4948 (name "python-html5tagger")
4949 (version "1.3.0")
4950 (source (origin
4951 (method url-fetch)
4952 (uri (pypi-uri "html5tagger" version))
4953 (sha256
4954 (base32
4955 "1acd1a4f66gi4plqnsml7cf33qp83mxsnmnqpdwkpj7597xkvyl4"))))
4956 (build-system pyproject-build-system)
4957 (arguments
4958 (list #:tests? #f)) ;no tests in PyPI or Git
4959 (native-inputs
4960 (list python-setuptools python-setuptools-scm python-wheel))
4961 (home-page "https://github.com/sanic-org/html5tagger")
4962 (synopsis "Create HTML documents from Python")
4963 (description
4964 "@code{html5tagger} provides a simplified HTML5 syntax that can
4965be written directly in Python without templates.")
4966 (license license:unlicense)))
4967
4968(define-public python-minio
4969 (package
4970 (name "python-minio")
4971 (version "7.1.9")
4972 (source
4973 (origin
4974 (method git-fetch)
4975 (uri (git-reference
4976 (url "https://github.com/minio/minio-py")
4977 (commit version)))
4978 (file-name (git-file-name name version))
4979 (sha256
4980 (base32 "01734ki3p7844dya366hy1kvmmgy3xr0l0zbkchnnv4p611510vc"))))
4981 (build-system pyproject-build-system)
4982 (arguments
4983 (list
4984 #:test-flags
4985 ;; XXX: requires network access.
4986 #~(list "--ignore=tests/unit/credentials_test.py")))
4987 (native-inputs (list python-pytest python-setuptools))
4988 (propagated-inputs
4989 (list python-certifi python-dateutil python-pytz python-urllib3))
4990 (home-page "https://github.com/minio/minio-py")
4991 (synopsis "Programmatically access Amazon S3 from Python")
4992 (description
4993 "This package provides a Python library for interacting with any
4994Amazon S3 compatible object storage server.")
4995 (license license:asl2.0)))
4996
4997(define-public python-pycrdt
4998 (package
4999 (name "python-pycrdt")
5000 (version "0.13.0")
5001 (source
5002 (origin
5003 (method git-fetch)
5004 (uri (git-reference
5005 (url "https://github.com/y-crdt/pycrdt")
5006 (commit version)))
5007 (file-name (git-file-name name version))
5008 (sha256
5009 (base32 "18mnjbxdlra1w3jl42bf1jb25z9j3inh6s61qighqrvnylgxvxc1"))))
5010 (build-system pyproject-build-system)
5011 (arguments
5012 (list
5013 #:imported-modules `(,@%cargo-build-system-modules
5014 ,@%pyproject-build-system-modules)
5015 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
5016 (guix build pyproject-build-system)
5017 (guix build utils))
5018 #:test-flags #~(list "--ignore=tests/test_types.py")
5019 #:phases
5020 #~(modify-phases %standard-phases
5021 (add-after 'unpack 'relax-requirements
5022 (lambda _
5023 (substitute* "pyproject.toml"
5024 (("requires = \\[\"maturin>=.*\"\\]")
5025 "requires = [\"maturin\"]"))))
5026 (add-after 'unpack 'prepare-cargo-build-system
5027 (lambda args
5028 (for-each
5029 (lambda (phase)
5030 (format #t "Running cargo phase: ~a~%" phase)
5031 (apply (assoc-ref cargo:%standard-phases phase)
5032 #:cargo-target #$(cargo-triplet)
5033 args))
5034 '(unpack-rust-crates
5035 configure
5036 check-for-pregenerated-files
5037 patch-cargo-checksums)))))))
5038 (propagated-inputs
5039 (list python-anyio
5040 python-typing-extensions))
5041 (inputs (cargo-inputs 'pycrdt))
5042 (native-inputs
5043 (append
5044 (list maturin
5045 python-pydantic
5046 python-pytest
5047 rust
5048 `(,rust "cargo"))
5049 (or (and=> (%current-target-system)
5050 (compose list make-rust-sysroot))
5051 '())))
5052 (home-page "https://github.com/y-crdt/pycrdt")
5053 (synopsis "Python CRDTs library ported from Yjs framework")
5054 (description
5055 "Conflict-free Replicated Data Types (CRDTs) allow creating shared
5056documents that can automatically merge changes made concurrently on different
5057copies of the data. When the data lives on different machines, they make it
5058possible to build distributed systems that work with local data, leaving the
5059synchronization and conflict resolution with remote data to the CRDT
5060algorithm, which ensures that all data replicas eventually converge to the
5061same state.
5062
5063This is a Python CRDT library that provides bindings for Yrs, the Rust port of
5064the Yjs framework.")
5065 (license license:expat)))
5066
5067(define-public python-pycrdt-store
5068 (package
5069 (name "python-pycrdt-store")
5070 (version "0.1.3")
5071 (source
5072 (origin
5073 (method git-fetch)
5074 (uri (git-reference
5075 (url "https://github.com/y-crdt/pycrdt-store")
5076 (commit version)))
5077 (file-name (git-file-name name version))
5078 (sha256
5079 (base32 "18yvv5lgxb4v0qlbi8bbkcm1666nxbkmhbx445sxpzab7027fl1a"))))
5080 (build-system pyproject-build-system)
5081 (propagated-inputs
5082 (list python-anyio
5083 python-pycrdt
5084 python-sqlite-anyio))
5085 (native-inputs
5086 (list python-hatchling
5087 python-pytest
5088 python-pytest-rerunfailures
5089 python-trio))
5090 (home-page "https://github.com/y-crdt/pycrdt-store")
5091 (synopsis "Persistent storage for pycrdt")
5092 (description
5093 "This package provides a persistent storage feature for
5094@code{python-pycrdt}.")
5095 (license license:expat)))
5096
5097(define-public python-pycrdt-websocket
5098 (package
5099 (name "python-pycrdt-websocket")
5100 (version "0.16.0")
5101 (source
5102 (origin
5103 (method git-fetch)
5104 (uri (git-reference
5105 (url "https://github.com/y-crdt/pycrdt-websocket")
5106 (commit version)))
5107 (file-name (git-file-name name version))
5108 (sha256
5109 (base32 "1bcxivdra0v5fwlz3hcz98vxi61884bfvcwifsdp3mji28iprv22"))))
5110 (build-system pyproject-build-system)
5111 (arguments
5112 (list
5113 ;; These tests require the unpackaged Yjs.
5114 #:test-flags #~(list "--deselect=tests/test_pycrdt_yjs.py")))
5115 (propagated-inputs
5116 (list python-anyio
5117 python-pycrdt
5118 python-pycrdt-store))
5119 (native-inputs
5120 (list nss-certs-for-test
5121 python-hatchling
5122 python-hypercorn
5123 python-httpx-ws
5124 python-pytest))
5125 (home-page "https://github.com/y-crdt/pycrdt-websocket")
5126 (synopsis "WebSocket connector for pycrdt")
5127 (description "This package provides an asynchronous @code{WebSocket}
5128connector for @code{python-pycrdt}.")
5129 (license license:expat)))
5130
5131(define-public python-pycurl
5132 (package
5133 (name "python-pycurl")
5134 (version "7.45.4")
5135 (source
5136 (origin
5137 (method git-fetch)
5138 (uri (git-reference
5139 (url "https://github.com/pycurl/pycurl")
5140 (commit (string-append
5141 "REL_" (string-replace-substring version "." "_")))))
5142 (file-name (git-file-name name version))
5143 (sha256
5144 (base32 "00cd1l0lsml0708hpv5k4qyhqfv0qphb0p317j9aci2wdspn1mpl"))))
5145 (build-system pyproject-build-system)
5146 (arguments
5147 '(#:test-flags
5148 ;; The test suite is not thread safe:
5149 ;; - some tests want to use the same port: address already in use
5150 ;; - some tests use signal.Signal, i.e. main-thread only
5151 (list "-k" (string-append
5152 ;; Disable hanginging tests
5153 "not test_multi_socket_select"
5154 ;; E assert None is not None
5155 ;; E+ where None =
5156 ;; <tests.multi_callback_test.MultiCallbackTest
5157 ;; testMethod=test_multi_socket_action>.timer_result
5158 " and not test_multi_socket_action"
5159 ;; OSError: tests/fake-curl/libcurl/with_gnutls.so: cannot
5160 ;; open shared object file: No such file or directory
5161 " and not test_libcurl_ssl_gnutls"
5162 ;; OSError: tests/fake-curl/libcurl/with_nss.so: cannot
5163 ;; open shared object file: No such file or directory
5164 " and not test_libcurl_ssl_nss"
5165 ;; OSError: tests/fake-curl/libcurl/with_openssl.so: cannot
5166 ;; open shared object file: No such file or directory
5167 " and not test_libcurl_ssl_openssl"
5168 ;; Probably due to an expired CA
5169 " and not test_request_without_certinfo"
5170 ;; "A libcurl function was given a bad argument"
5171 " and not test_proxy_tlsauth"))
5172 #:phases (modify-phases %standard-phases
5173 (add-before 'build 'configure-tls-backend
5174 (lambda _
5175 ;; XXX: PycURL fails to automatically determine which
5176 ;; TLS backend to use when cURL is built with
5177 ;; --disable-static. See setup.py and
5178 ;; <https://github.com/pycurl/pycurl/pull/147>.
5179 (setenv "PYCURL_SSL_LIBRARY" "gnutls"))))))
5180 (native-inputs
5181 (list python-bottle
5182 python-flaky
5183 python-flask
5184 python-pytest
5185 python-setuptools
5186 python-wheel))
5187 (inputs
5188 (list curl gnutls))
5189 (home-page "http://pycurl.io/")
5190 (synopsis "Lightweight Python wrapper around libcurl")
5191 (description "Pycurl is a lightweight wrapper around libcurl. It provides
5192high-speed transfers via libcurl and frequently outperforms alternatives.")
5193
5194 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
5195 ;; under the terms of LGPLv2.1+ or Expat.
5196 (license (list license:lgpl2.1+ license:expat))))
5197
5198(define-public python-stamina
5199 (package
5200 (name "python-stamina")
5201 (version "25.2.0")
5202 (source
5203 (origin
5204 (method git-fetch)
5205 (uri (git-reference
5206 (url "https://github.com/hynek/stamina")
5207 (commit version)))
5208 (file-name (git-file-name name version))
5209 (sha256
5210 (base32 "100iadhzmxbavk0ras3srnagh9af5pxbqrm4mrrkyy69knih9jiy"))))
5211 (build-system pyproject-build-system)
5212 (native-inputs
5213 (list python-pytest
5214 python-anyio
5215 python-dirty-equals
5216 python-hatch-fancy-pypi-readme
5217 python-hatch-vcs
5218 python-hatchling
5219 python-structlog))
5220 (propagated-inputs
5221 (list python-tenacity
5222 python-typing-extensions))
5223 (home-page "https://github.com/hynek/stamina")
5224 (synopsis "Retries library for Python")
5225 (description
5226 "@code{stamina} is an opinionated wrapper around the
5227@url{https://tenacity.readthedocs.io/en/latest/, Tenacity} package.")
5228 (license license:expat)))
5229
5230(define-public python-stripe
5231 (package
5232 (name "python-stripe")
5233 (version "13.2.0")
5234 (source
5235 (origin
5236 (method git-fetch)
5237 (uri (git-reference
5238 (url "https://github.com/stripe/stripe-python")
5239 (commit (string-append "v" version))))
5240 (file-name (git-file-name name version))
5241 (sha256
5242 (base32 "0f0d1hqias3qylrhk56w055lqrlzjs9s7wxva30v54ykmn9nj6dx"))))
5243 (build-system pyproject-build-system)
5244 (arguments
5245 '(#:tests? #f)) ;; tests require network
5246 (native-inputs
5247 (list python-flit-core))
5248 (propagated-inputs
5249 (list python-httpx
5250 python-requests))
5251 (home-page "https://github.com/stripe/stripe-python")
5252 (synopsis "Python bindings for the Stripe financial services' API")
5253 (description "This package provides access to the Stripe financial
5254services' API. It includes a pre-defined set of classes for API resources
5255that initialize themselves dynamically from API responses which makes it
5256compatible with a wide range of versions of the Stripe API.")
5257 (license license:expat)))
5258
5259(define-public python-stripe-12
5260 (hidden-package
5261 (package/inherit python-stripe
5262 (name "python-stripe")
5263 (version "12.5.1")
5264 (source
5265 (origin
5266 (inherit (package-source python-stripe))
5267 (uri (git-reference
5268 (url "https://github.com/stripe/stripe-python")
5269 (commit (string-append "v" version))))
5270 (file-name (git-file-name name version))
5271 (sha256 (base32
5272 "0jgixfb8ydlx387vm7rdaqrzsiqbvi99nszrpb1ghjqyn755xigd"))))
5273 (native-inputs
5274 (list python-setuptools)))))
5275
5276(define-public python-tldextract
5277 (package
5278 (name "python-tldextract")
5279 (version "5.3.0")
5280 (source
5281 (origin
5282 (method url-fetch)
5283 (uri (pypi-uri "tldextract" version))
5284 (sha256
5285 (base32 "02c6cyh8f3dagcw786m9nl5y0n3xa98p5mb7d7xfr84l2l5bglmk"))))
5286 (build-system pyproject-build-system)
5287 (arguments
5288 (list
5289 #:phases
5290 #~(modify-phases %standard-phases
5291 (add-after 'unpack 'relax-requirements
5292 (lambda _
5293 (substitute* "pyproject.toml"
5294 (("\"requests-file.*\",")
5295 "\"requests-file\",")))))))
5296 (native-inputs
5297 (list nss-certs-for-test
5298 python-pytest
5299 python-pytest-mock
5300 python-responses
5301 python-setuptools
5302 python-setuptools-scm
5303 python-syrupy))
5304 (propagated-inputs
5305 (list python-filelock
5306 python-idna
5307 python-requests
5308 python-requests-file))
5309 (home-page "https://github.com/john-kurkowski/tldextract")
5310 (synopsis
5311 "Separate the TLD from the registered domain and subdomains of a URL")
5312 (description
5313 "TLDExtract accurately separates the TLD from the registered domain and
5314subdomains of a URL, using the Public Suffix List. By default, this includes
5315the public ICANN TLDs and their exceptions. It can optionally support the
5316Public Suffix List's private domains as well.")
5317 (license license:bsd-3)))
5318
5319(define-public python-tracerite
5320 (package
5321 (name "python-tracerite")
5322 (version "1.1.3")
5323 (source
5324 (origin
5325 (method url-fetch)
5326 (uri (pypi-uri "tracerite" version))
5327 (sha256
5328 (base32 "07mkg0sl0h335kj6yjvxki2c19gxhb7rkks1zgzh7aj0y83c17qi"))))
5329 (build-system pyproject-build-system)
5330 (arguments
5331 (list #:tests? #f)) ;no tests in PyPI or Git
5332 (native-inputs
5333 (list python-setuptools
5334 python-setuptools-scm))
5335 (propagated-inputs
5336 (list python-html5tagger))
5337 (home-page "https://github.com/sanic-org/tracerite")
5338 (synopsis "Human-readable HTML tracebacks")
5339 (description
5340 "@code{tracerite} converts Python tracebacks into useful error messages
5341in human-readable HTML format.")
5342 (license license:unlicense)))
5343
5344(define-public python-trio-websocket
5345 (package
5346 (name "python-trio-websocket")
5347 (version "0.12.2")
5348 (source
5349 (origin
5350 (method git-fetch)
5351 (uri (git-reference
5352 (url "https://github.com/HyperionGray/trio-websocket")
5353 (commit version)))
5354 (file-name (git-file-name name version))
5355 (sha256
5356 (base32 "1lm712gakpskcn3adna22kj8m1hspz9l68pmlziklr0ycphmyqac"))))
5357 (build-system pyproject-build-system)
5358 (native-inputs
5359 (list python-pytest
5360 python-pytest-trio
5361 python-setuptools
5362 python-trustme))
5363 (propagated-inputs
5364 (list python-outcome
5365 python-trio
5366 python-wsproto))
5367 (home-page "https://github.com/HyperionGray/trio-websocket")
5368 (synopsis "WebSocket library for Trio")
5369 (description "This library implements both server and client aspects of
5370the @url{https://tools.ietf.org/html/rfc6455, the WebSocket protocol},
5371striving for safety, correctness, and ergonomics. It is based on the
5372@url{https://wsproto.readthedocs.io/en/latest/, wsproto project}, which is a
5373@url{https://sans-io.readthedocs.io/, Sans-IO} state machine that implements
5374the majority of the WebSocket protocol, including framing, codecs, and events.
5375This library handles I/O using @url{https://trio.readthedocs.io/en/latest/,
5376the Trio framework}.")
5377 (license license:expat)))
5378
5379(define-public python-txacme
5380 ;; 0.9.3 tag was placed in 2020 and there a lot of changes providing
5381 ;; compatibility with twisted, use the latest commit from trunk branch.
5382 ;;
5383 ;;See: <https://github.com/twisted/txacme/issues/165>.
5384 (let ((commit "ac18f92f6dde971a6b38f2ecfae44665815db583")
5385 (revision "0"))
5386 (package
5387 (name "python-txacme")
5388 (version (git-version "0.9.3" revision commit))
5389 (source
5390 (origin
5391 (method git-fetch) ;no fresh release in PyPI
5392 (uri (git-reference
5393 (url "https://github.com/twisted/txacme")
5394 (commit commit)))
5395 (file-name (git-file-name name version))
5396 (sha256
5397 (base32 "0mgdfxldv8qflbn75ywslbarnd4i3l7c4krs4aibl2dpryclsjzs"))))
5398 (build-system pyproject-build-system)
5399 (arguments
5400 (list #:test-backend #~'custom
5401 #:test-flags #~(list "-m" "twisted.trial" "txacme")))
5402 (native-inputs
5403 (list python-setuptools))
5404 (propagated-inputs
5405 (list python-acme
5406 python-attrs
5407 python-eliot
5408 python-josepy
5409 python-pem
5410 python-treq
5411 python-twisted
5412 python-txsni))
5413 (home-page "https://github.com/twisted/txacme")
5414 (synopsis "Twisted implexmentation of the ACME protocol")
5415 (description
5416 "ACME is Automatic Certificate Management Environment, a protocol that
5417allows clients and certificate authorities to automate verification and
5418certificate issuance. The ACME protocol is used by the free Let's Encrypt
5419Certificate Authority.
5420
5421txacme is an implementation of the protocol for Twisted, the event-driven
5422networking engine for Python.")
5423 (license license:expat))))
5424
5425(define-public python-txaio
5426 (package
5427 (name "python-txaio")
5428 (version "25.9.2")
5429 (source
5430 (origin
5431 (method url-fetch)
5432 (uri (pypi-uri "txaio" version))
5433 (sha256
5434 (base32 "16ch62yk2gdikkak113h6qw13ns9ksca817hky0vabn0fyh08874"))))
5435 (build-system pyproject-build-system)
5436 (native-inputs
5437 (list python-pytest
5438 python-setuptools))
5439 (home-page "https://github.com/crossbario/txaio")
5440 (synopsis "Compatibility layer between Python asyncio and Twisted")
5441 (description
5442 "Txaio provides a compatibility layer between the Python @code{asyncio}
5443 bsmodule and @code{Twisted}.")
5444 (license license:expat)))
5445
5446;; XXX: Potentially abandonware since 2017, consider to remove when nothing
5447;; depends on it or fails to build.
5448(define-public python-txamqp
5449 (package
5450 (name "python-txamqp")
5451 (version "0.8.2")
5452 (source
5453 (origin
5454 (method url-fetch)
5455 (uri (pypi-uri "txAMQP" version))
5456 (sha256
5457 (base32 "0jd9864k3csc06kipiwzjlk9mq4054s8kzk5q1cfnxj8572s4iv4"))))
5458 (build-system pyproject-build-system)
5459 (arguments
5460 (list #:tests? #f)) ;all tests failed
5461 (native-inputs
5462 (list python-setuptools))
5463 (propagated-inputs
5464 (list python-six python-twisted))
5465 (home-page "https://github.com/txamqp/txamqp")
5466 (synopsis "Communicate with AMQP peers and brokers using Twisted")
5467 (description
5468 "This package provides a Python library for communicating with AMQP peers
5469and brokers using the asynchronous networking framework Twisted. It contains
5470all the necessary code to connect, send and receive messages to/from an
5471AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It
5472also includes support for using Thrift RPC over AMQP in Twisted
5473applications.")
5474 (license license:asl2.0)))
5475
5476(define-public python-txsni
5477 (package
5478 (name "python-txsni")
5479 (version "0.2.0")
5480 (source
5481 (origin
5482 (method git-fetch)
5483 (uri (git-reference
5484 (url "https://github.com/glyph/txsni")
5485 (commit (string-append "v" version))))
5486 (file-name (git-file-name name version))
5487 (sha256
5488 (base32 "1fl8xi7vl24hwbva5v41l6nsrbkj2l2mlsgcvdjxgph61aznwywq"))))
5489 (build-system pyproject-build-system)
5490 (arguments
5491 (list #:test-backend #~'custom
5492 #:test-flags #~(list "-m" "twisted.trial"
5493 "--temp-directory=/tmp/_trial_temp"
5494 "txsni")))
5495 (native-inputs
5496 (list python-setuptools))
5497 (propagated-inputs
5498 (list python-pyopenssl
5499 python-service-identity
5500 python-twisted))
5501 (home-page "https://github.com/glyph/txsni")
5502 (synopsis "Run TLS servers with Twisted")
5503 (description
5504 "This package provides an easy-to-use SNI endpoint for use with the
5505Twisted web framework.")
5506 (license license:expat)))
5507
5508(define-public python-txtorcon
5509 (package
5510 (name "python-txtorcon")
5511 (version "24.8.0")
5512 (source
5513 (origin
5514 (method url-fetch)
5515 (uri (pypi-uri "txtorcon" version))
5516 (sha256
5517 (base32 "1l4ajw4h7nay4vmllh6cs7zh3hnh8vj4yvgfnq3m734wil9ikzmy"))))
5518 (build-system pyproject-build-system)
5519 (native-inputs
5520 (list python-pytest
5521 python-setuptools
5522 python-wheel))
5523 (inputs
5524 (list lsof))
5525 (propagated-inputs
5526 (list python-automat
5527 python-idna
5528 python-incremental
5529 python-pyopenssl
5530 python-service-identity
5531 python-twisted
5532 python-zope-interface))
5533 (home-page "https://github.com/meejah/txtorcon")
5534 (synopsis "Twisted-based Tor controller client")
5535 (description
5536 "This package provides a Twisted-based Tor controller client,with
5537state-tracking and configuration abstractions.")
5538 (license license:expat)))
5539
5540(define-public python-url-normalize
5541 (package
5542 (name "python-url-normalize")
5543 (version "2.2.1")
5544 (source
5545 (origin
5546 (method git-fetch) ; no tests in PyPI release
5547 (uri (git-reference
5548 (url "https://github.com/niksite/url-normalize")
5549 (commit (string-append "v" version))))
5550 (file-name (git-file-name name version))
5551 (sha256
5552 (base32 "1yhsf4sk6l6nznpnqigisbfz690a4g342dsk2n6dggh7q4l3amk4"))))
5553 (build-system pyproject-build-system)
5554 (arguments
5555 (list
5556 #:test-flags #~(list "--ignore=tests/test_cli.py")))
5557 (native-inputs
5558 (list python-pytest python-pytest-socket python-setuptools))
5559 (propagated-inputs
5560 (list python-idna))
5561 (home-page "https://github.com/niksite/url-normalize")
5562 (synopsis "URL normalization for Python")
5563 (description
5564 "This package provides a URI Normalization function with following
5565features:
5566@itemize
5567@item take care of IDN domains
5568@item always provide the URI scheme in lowercase characters
5569@item always provide the host, if any, in lowercase characters
5570@item only perform percent-encoding where it is essential
5571@item always use uppercase A-through-F characters when percent-encoding
5572@item prevent dot-segments appearing in non-relative URI paths
5573@item for schemes that define a default authority, use an empty authority if
5574the default is desired
5575@item for schemes that define an empty path to be equivalent to a path of
5576@code{/}, use @code{/}
5577@item for schemes that define a port, use an empty port if the default is
5578desired
5579@item all portions of the URI must be utf-8 encoded NFC from Unicode strings
5580@end itemize")
5581 (license license:expat)))
5582
5583(define-public python-waitress
5584 (package
5585 (name "python-waitress")
5586 (version "3.0.2")
5587 (source
5588 (origin
5589 (method url-fetch)
5590 (uri (pypi-uri "waitress" version))
5591 (sha256
5592 (base32
5593 "07y3xyx2006f2ni5d55byh3y7w4kcg9xww7vmfjasi0cmzralak8"))))
5594 (build-system pyproject-build-system)
5595 (arguments
5596 (list
5597 ;; https://github.com/Pylons/waitress/issues/443
5598 #:test-flags #~(list "-k" "not test_service_port")))
5599 (native-inputs (list python-pytest python-setuptools))
5600 (home-page "https://github.com/Pylons/waitress")
5601 (synopsis "Waitress WSGI server")
5602 (description
5603 "Waitress is meant to be a production-quality pure-Python WSGI server
5604with very acceptable performance.")
5605 (license license:zpl2.1)))
5606
5607(define-public python-weasel
5608 (package
5609 (name "python-weasel")
5610 (version "1.0.0")
5611 (source
5612 (origin
5613 (method git-fetch)
5614 (uri (git-reference
5615 (url "https://github.com/explosion/weasel/")
5616 (commit (string-append "release-v" version))))
5617 (file-name (git-file-name name version))
5618 (sha256
5619 (base32 "1sxcxri9hl9rs1kvdrv81g6mlg7lifhq9xacskracz63v4nyh8na"))))
5620 (build-system pyproject-build-system)
5621 (arguments
5622 (list
5623 #:test-flags
5624 ;; This test raises an error, but not the one expected by pytest.
5625 #~(list (string-append "--deselect=weasel/tests/test_validation.py::"
5626 "test_project_config_interpolation[10_0]")
5627 ;; Network access is required.
5628 #$@(map (lambda (test) (string-append "--deselect="
5629 "weasel/tests/cli/"
5630 test))
5631 (list "test_cli.py::test_project_git_dir_asset"
5632 "test_cli.py::test_project_git_file_asset"
5633 "test_cli_app.py::test_project_assets")))))
5634 (native-inputs
5635 (list python-pytest
5636 python-setuptools))
5637 (propagated-inputs
5638 (list python-cloudpathlib
5639 python-confection
5640 python-httpx
5641 python-packaging
5642 python-pydantic
5643 python-smart-open
5644 python-srsly
5645 python-typer
5646 python-wasabi))
5647 (home-page "https://github.com/explosion/weasel/")
5648 (synopsis "Small and easy workflow system")
5649 (description
5650 "This package provides a minimalistic workflow system to manage and
5651share end-to-end workflows for different use cases and domains.")
5652 (license license:expat)))
5653
5654(define-public python-webencodings
5655 (package
5656 (name "python-webencodings")
5657 (version "0.5.1")
5658 (source
5659 (origin
5660 (method url-fetch)
5661 (uri (pypi-uri "webencodings" version))
5662 (sha256
5663 (base32 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
5664 (build-system pyproject-build-system)
5665 (arguments
5666 (list #:test-flags #~(list "webencodings/tests.py")))
5667 (native-inputs
5668 (list python-pytest python-setuptools))
5669 (home-page "https://github.com/SimonSapin/python-webencodings")
5670 (synopsis "Character encoding aliases for legacy web content")
5671 (description
5672 "In order to be compatible with legacy web content when interpreting
5673something like @code{Content-Type: text/html; charset=latin1}, tools need to
5674use a particular set of aliases for encoding labels as well as some overriding
5675rules. For example, @code{US-ASCII} and @code{iso-8859-1} on the web are
5676actually aliases for @code{windows-1252}, and a @code{UTF-8} or @code{UTF-16}
5677BOM takes precedence over any other encoding declaration. The WHATWG
5678@url{https://encoding.spec.whatwg.org/,Encoding} standard defines all such
5679details so that implementations do not have to reverse-engineer each other.
5680
5681This module implements the Encoding standard and has encoding labels and BOM
5682detection, but the actual implementation for encoders and decoders is
5683Python’s.")
5684 (license license:bsd-3)))
5685
5686(define-public python-omnipath
5687 (package
5688 (name "python-omnipath")
5689 (version "1.0.10")
5690 (source
5691 (origin
5692 (method git-fetch)
5693 (uri (git-reference
5694 (url "https://github.com/saezlab/omnipath/")
5695 (commit (string-append "v" version))))
5696 (file-name (git-file-name name version))
5697 (sha256
5698 (base32 "0jnc7nsn6n5hqx5wlk928b7xmg0mpfqy8al9w2p707ihcwh4s1rf"))))
5699 (build-system pyproject-build-system)
5700 (arguments
5701 (list
5702 #:test-flags '(list "-k"
5703 (string-append
5704 ;; These require internet access
5705 "not test_download_homologene"
5706 " and not test_complex_genes"))
5707 #:phases
5708 #~(modify-phases %standard-phases
5709 (add-after 'unpack 'set-home
5710 (lambda _
5711 (setenv "HOME" "/tmp"))))))
5712 (propagated-inputs (list python-attrs
5713 python-docrep
5714 python-inflect
5715 python-networkx
5716 python-packaging
5717 python-pandas
5718 python-requests
5719 python-tqdm
5720 python-typing-extensions
5721 python-urllib3
5722 python-wrapt))
5723 (native-inputs (list nss-certs-for-test
5724 python-bump2version
5725 python-hatchling
5726 python-pytest
5727 python-pytest-mock
5728 python-pytest-socket
5729 python-requests-mock))
5730 (home-page "https://omnipathdb.org/")
5731 (synopsis "Python client for the OmniPath web service")
5732 (description "This package provides a Python client for the OmniPath web
5733service.")
5734 (license license:expat)))
5735
5736(define-public python-openai
5737 (package
5738 (name "python-openai")
5739 (version "2.42.0")
5740 (source
5741 (origin
5742 (method git-fetch)
5743 (uri (git-reference
5744 (url "https://github.com/openai/openai-python")
5745 (commit (string-append "v" version))))
5746 (file-name (git-file-name name version))
5747 (sha256
5748 (base32 "1p0vzy34cx2gfkhsqg2kxzam51cjlpa99q0skzj4426sx2hsw3g6"))))
5749 (build-system pyproject-build-system)
5750 (arguments
5751 (list
5752 #:test-flags
5753 ;; These require internet access and an openai API key.
5754 #~(list "--ignore=openai/tests/asyncio/test_endpoints.py"
5755 "--ignore=openai/tests/test_endpoints.py"
5756 "--ignore-glob=tests/api_resources/*")))
5757 (propagated-inputs
5758 (list python-aiohttp
5759 python-distro
5760 python-httpx
5761 python-jiter
5762 python-pydantic
5763 python-requests
5764 python-tqdm
5765 python-typing-extensions))
5766 (native-inputs
5767 (list nss-certs-for-test
5768 python-dirty-equals
5769 python-hatchling
5770 python-hatch-fancy-pypi-readme
5771 python-inline-snapshot
5772 python-pytest
5773 python-pytest-asyncio
5774 python-pytest-mock
5775 python-pytest-xdist
5776 python-respx
5777 python-rich
5778 python-setuptools))
5779 (home-page "https://github.com/openai/openai-python")
5780 (synopsis "Python client library for the OpenAI API")
5781 (description "This package provides a Python client library for the
5782OpenAI API.")
5783 (license license:expat)))
5784
5785(define-public python-openapi-schema-validator
5786 (package
5787 (name "python-openapi-schema-validator")
5788 (version "0.6.2")
5789 (source
5790 (origin
5791 (method git-fetch) ;no tests in pypi release
5792 (uri (git-reference
5793 (url "https://github.com/p1c2u/openapi-schema-validator")
5794 (commit version)))
5795 (file-name (git-file-name name version))
5796 (sha256
5797 (base32
5798 "0pgsm1x7lhc5ryj4l45ik8m5x9gqyi50dkflaiqqr4fnl0bsbx09"))))
5799 (build-system pyproject-build-system)
5800 (arguments
5801 (list
5802 #:test-flags
5803 ;; This one returns 5 instead of 4 elements
5804 '(list "-k" "not test_array_prefixitems_invalid")
5805 #:phases
5806 #~(modify-phases %standard-phases
5807 ;; See https://github.com/python-openapi/openapi-schema-validator/issues/204
5808 (add-after 'unpack 'relax-requirements
5809 (lambda _
5810 (substitute* "pyproject.toml"
5811 (("jsonschema-specifications.*")
5812 "jsonschema-specifications = \">=2023.5.2\"\n")))))))
5813 (native-inputs (list python-poetry-core python-pytest))
5814 (propagated-inputs
5815 (list python-isodate
5816 python-jsonschema
5817 python-rfc3339-validator
5818 python-strict-rfc3339))
5819 (home-page "https://github.com/p1c2u/openapi-schema-validator")
5820 (synopsis "OpenAPI schema validation library for Python")
5821 (description "Openapi-schema-validator is a Python library that validates
5822a schema against:
5823@itemize
5824@item OpenAPI Schema Specification v3.0 which is an extended subset of the
5825JSON Schema Specification Wright Draft 00.
5826@item OpenAPI Schema Specification v3.1 which is an extended superset of the
5827JSON Schema Specification Draft 2020-12.
5828@end itemize")
5829 (license license:bsd-3)))
5830
5831(define-public python-openapi-spec-validator
5832 (package
5833 (name "python-openapi-spec-validator")
5834 (version "0.7.1")
5835 (source
5836 (origin
5837 (method git-fetch) ;no tests in pypi release
5838 (uri (git-reference
5839 (url "https://github.com/p1c2u/openapi-spec-validator")
5840 (commit version)))
5841 (file-name (git-file-name name version))
5842 (sha256
5843 (base32
5844 "0s5yd4dbr6knwd2g1g4v2931k14n1lm80l11n2ija18yfis8yisz"))))
5845 (build-system pyproject-build-system)
5846 (arguments
5847 (list
5848 ;; These tests attempt to fetch resources from the Internet
5849 #:test-flags '(list "--ignore-glob=tests/integration/validation/**"
5850 "-k" "not example")))
5851 (native-inputs
5852 (list python-poetry-core
5853 python-pytest))
5854 (propagated-inputs
5855 (list python-jsonschema
5856 python-jsonschema-path
5857 python-lazy-object-proxy
5858 python-openapi-schema-validator
5859 python-pyyaml
5860 python-requests
5861 python-setuptools))
5862 (home-page "https://github.com/p1c2u/openapi-spec-validator")
5863 (synopsis "OpenAPI spec validator")
5864 (description "OpenAPI Spec Validator is a Python library that validates an
5865OpenAPI specification against the OpenAPI 2.0 (also known as Swagger), OpenAPI
58663.0 and OpenAPI 3.1 specifications. The validator aims to check for full
5867compliance with the specification.")
5868 (license license:asl2.0)))
5869
5870(define-public python-openapi-core
5871 (package
5872 (name "python-openapi-core")
5873 (version "0.19.4")
5874 (source
5875 (origin
5876 (method git-fetch)
5877 (uri (git-reference
5878 (url "https://github.com/p1c2u/openapi-core")
5879 (commit version)))
5880 (file-name (git-file-name name version))
5881 (sha256
5882 (base32
5883 "092sj2933jmvq5r76khr0vphih490vls1ga3s43gz8i47aqaxx96"))))
5884 (build-system pyproject-build-system)
5885 (arguments
5886 (list
5887 #:test-flags
5888 '(list "tests/unit"
5889 "-k" "not test_chars_valid")))
5890 (native-inputs (list python-django
5891 python-falcon
5892 python-flask
5893 python-mock
5894 python-poetry-core
5895 python-pytest
5896 python-pytest-asyncio
5897 python-responses))
5898 (propagated-inputs
5899 (list python-attrs
5900 python-aiohttp
5901 python-isodate
5902 python-jsonschema
5903 python-lazy-object-proxy
5904 python-more-itertools
5905 python-openapi-schema-validator
5906 python-openapi-spec-validator
5907 python-parse
5908 python-six
5909 python-werkzeug))
5910 (home-page "https://github.com/p1c2u/openapi-core")
5911 (synopsis "OpenAPI core library")
5912 (description "Openapi-core is a Python library that adds client-side and
5913server-side support for the OpenAPI Specification v3. It has features such
5914as:
5915@itemize
5916@item Validation of requests and responses
5917@item Schema casting and unmarshalling
5918@item Media type and parameters deserialization
5919@item Security providers (API keys, Cookie, Basic and Bearer HTTP
5920authentications)
5921@item Custom deserializers and formats
5922@item Integration with libraries and frameworks.
5923@end itemize")
5924 (license license:bsd-3)))
5925
5926(define-public python-openid
5927 (package
5928 (name "python-openid")
5929 (version "3.2.0")
5930 (source
5931 (origin
5932 (method url-fetch)
5933 (uri (pypi-uri "python3-openid" version))
5934 (sha256
5935 (base32
5936 "1bxf9a3ny1js422j962zfzl4a9dhj192pvai05whn7j0iy9gdyrk"))))
5937 (build-system pyproject-build-system)
5938 (arguments
5939 `(#:phases
5940 (modify-phases %standard-phases
5941 (replace 'check
5942 (lambda* (#:key tests? #:allow-other-keys)
5943 (when tests?
5944 (invoke "python" "-m" "unittest" "openid.test.test_suite")))))))
5945 (propagated-inputs
5946 (list python-defusedxml))
5947 (native-inputs
5948 (list python-psycopg2 python-django python-setuptools python-wheel))
5949 (home-page "https://github.com/necaris/python3-openid")
5950 (synopsis "OpenID support for servers and consumers")
5951 (description "This library provides OpenID authentication for Python, both
5952for clients and servers.")
5953 (license license:asl2.0)))
5954
5955(define-public python-cssutils
5956 (package
5957 (name "python-cssutils")
5958 (version "2.11.1")
5959 (source
5960 (origin
5961 (method url-fetch)
5962 (uri (pypi-uri "cssutils" version))
5963 (sha256
5964 (base32
5965 "1qpq7xvzqp4cfcb8837rnd30x4hws3rkp33qpvmnxbxn2djsfqq5"))))
5966 (build-system pyproject-build-system)
5967 (arguments
5968 (list
5969 #:phases
5970 #~(modify-phases %standard-phases
5971 (replace 'check
5972 (lambda _
5973 (invoke "pytest" "-vv" "-k"
5974 (string-append "not encutils "
5975 "and not website.logging")))))))
5976 (native-inputs
5977 (list python-cssselect
5978 python-jaraco-test
5979 python-lxml
5980 python-pytest
5981 python-setuptools
5982 python-wheel))
5983 (propagated-inputs
5984 (list python-more-itertools))
5985 (home-page "https://github.com/jaraco/cssutils")
5986 (synopsis
5987 "CSS Cascading Style Sheets library for Python")
5988 (description
5989 "Cssutils is a Python package for parsing and building CSS
5990Cascading Style Sheets. Currently it provides a DOM only and no rendering
5991options.")
5992 (license license:lgpl3+)))
5993
5994(define-public python-css-parser
5995 (package
5996 (inherit python-cssutils)
5997 (name "python-css-parser")
5998 (version "1.0.10")
5999 (source
6000 (origin
6001 (method url-fetch)
6002 (uri (pypi-uri "css-parser" version))
6003 (sha256
6004 (base32 "0qs375slcwqd7slizh6hzkwxx7cdj36v8kwn0qrfji1kscm9f7mz"))))
6005 (home-page "https://github.com/ebook-utils/css-parser")
6006 (synopsis "Fork of cssutils modified for parsing ebooks")
6007 (description
6008 "Css-parser is a Python package for parsing and building CSS
6009Cascading Style Sheets. Currently it provides a DOM only and no rendering
6010options.
6011
6012It's a fork of cssutils 1.0.2, updated and modified for parsing ebooks, due to
6013cssutils not receiving updates as of 1.0.2.")
6014 (license license:lgpl3+)))
6015
6016(define-public python-cssselect
6017 (package
6018 (name "python-cssselect")
6019 (version "1.2.0")
6020 (source (origin
6021 ;; The PyPI release does not contain tests.
6022 (method git-fetch)
6023 (uri (git-reference
6024 (url "https://github.com/scrapy/cssselect")
6025 (commit (string-append "v" version))))
6026 (file-name (git-file-name name version))
6027 (sha256
6028 (base32
6029 "1x4nrvb1p1byi1whmspik7lbh303akdlh762dayfxam3hycsh5kk"))))
6030 (build-system pyproject-build-system)
6031 (native-inputs
6032 (list python-lxml python-pytest python-setuptools python-wheel))
6033 (home-page "https://github.com/scrapy/cssselect")
6034 (synopsis "CSS3 selector parser and translator to XPath 1.0")
6035 (description
6036 "Cssselect ia a Python module that parses CSS3 Selectors and translates
6037them to XPath 1.0 expressions. Such expressions can be used in lxml or
6038another XPath engine to find the matching elements in an XML or HTML document.")
6039 (license license:bsd-3)))
6040
6041(define-public python-databricks-cli
6042 (package
6043 (name "python-databricks-cli")
6044 (version "0.18.0")
6045 (home-page "https://github.com/databricks/databricks-cli")
6046 (source (origin
6047 (method git-fetch)
6048 (uri (git-reference (url home-page) (commit version)))
6049 (file-name (git-file-name name version))
6050 (sha256
6051 (base32
6052 "1avag4kwqk2f24r5i0vcmhm6s1gsw6maykhlyj2ixz0qc05pjzvl"))))
6053 (build-system pyproject-build-system)
6054 (arguments
6055 (list #:phases #~(modify-phases %standard-phases
6056 (replace 'check
6057 (lambda _
6058 (invoke "pytest" "tests" "-vv"))))))
6059 (native-inputs
6060 ;; For tests.
6061 (list python-decorator
6062 python-mock
6063 python-pytest
6064 python-requests-mock
6065 python-setuptools
6066 python-wheel))
6067 (propagated-inputs
6068 (list python-click
6069 python-oauthlib
6070 python-pyjwt
6071 python-requests
6072 python-six
6073 python-tabulate))
6074 (synopsis "Command line interface for Databricks")
6075 (description
6076 "The Databricks Command Line Interface is a tool which provides an easy
6077to use interface to the Databricks platform. The CLI is built on top of the
6078Databricks REST APIs.")
6079 (license license:asl2.0)))
6080
6081(define-public python-openid-cla
6082 ;; XXX: Last updated in 2015.
6083 (package
6084 (name "python-openid-cla")
6085 (version "1.2")
6086 (source
6087 (origin
6088 (method url-fetch)
6089 (uri (pypi-uri "python-openid-cla" version))
6090 (sha256
6091 (base32
6092 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
6093 (build-system pyproject-build-system)
6094 (arguments '(#:tests? #f)) ; No tests.
6095 (native-inputs (list python-setuptools python-wheel))
6096 (propagated-inputs (list python-openid python-six))
6097 (home-page "https://github.com/puiterwijk/python-openid-cla/")
6098 (synopsis "Implementation of the OpenID CLA extension for python-openid")
6099 (description "@code{openid-cla} is an implementation of the OpenID
6100contributor license agreement extension for python-openid.")
6101 (license license:bsd-3)))
6102
6103(define-public python-openid-teams
6104 ;; XXX: Last updated in 2018.
6105 (package
6106 (name "python-openid-teams")
6107 (version "1.1")
6108 (source
6109 (origin
6110 (method url-fetch)
6111 (uri (pypi-uri "python-openid-teams" version))
6112 (sha256
6113 (base32
6114 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
6115 (build-system pyproject-build-system)
6116 (arguments '(#:tests? #f)) ; No tests.
6117 (native-inputs (list python-setuptools python-wheel))
6118 (propagated-inputs (list python-openid python-six))
6119 (home-page "https://github.com/puiterwijk/python-openid-teams/")
6120 (synopsis "Implementation of the OpenID teams extension for python-openid")
6121 (description
6122 "@code{openid-teams} is an implementation of the OpenID
6123teams extension for python-openid.")
6124 (license license:bsd-3)))
6125
6126(define-public python-priority
6127 (package
6128 (name "python-priority")
6129 (version "2.0.0")
6130 (source
6131 (origin
6132 (method url-fetch)
6133 (uri (pypi-uri "priority" version))
6134 (sha256
6135 (base32 "1h0qpa949bxx7za95v1apwnngkrngi695cwx8wchn3cd3d7xarf9"))))
6136 (build-system pyproject-build-system)
6137 (native-inputs
6138 (list python-pytest python-setuptools python-wheel))
6139 (home-page "https://python-hyper.org/projects/priority/en/latest/")
6140 (synopsis "Pure-Python implementation of the HTTP/2 priority tree")
6141 (description
6142 "Priority is a pure-Python implementation of the priority logic for HTTP/2,
6143set out in RFC 7540 Section 5.3 (Stream Priority).")
6144 (license license:expat)))
6145
6146(define-public python-weblate-language-data
6147 (package
6148 (name "python-weblate-language-data")
6149 (version "2025.8")
6150 (source
6151 (origin
6152 (method url-fetch)
6153 (uri (pypi-uri "weblate_language_data" version))
6154 (sha256
6155 (base32 "0byj1xl6xldam790b6wg62dk1b4i6qdlsp4lqzlv65wnp2klvrkf"))))
6156 (build-system pyproject-build-system)
6157 (arguments (list #:tests? #f)) ;not tests, just data files
6158 (native-inputs
6159 (list python-setuptools))
6160 (propagated-inputs
6161 (list python-translate-toolkit))
6162 (home-page "https://github.com/WeblateOrg/language-data")
6163 (synopsis "Language definitions for Weblate")
6164 (description
6165 "This package provides language definitions used by
6166@url{https://weblate.org/, Weblate}i.")
6167 (license license:expat)))
6168
6169(define-public python-wikidata
6170 (package
6171 (name "python-wikidata")
6172 (version "0.8.1")
6173 (source
6174 (origin
6175 (method git-fetch)
6176 (uri (git-reference
6177 (url "https://github.com/dahlia/wikidata")
6178 (commit version)))
6179 (file-name (git-file-name name version))
6180 (sha256
6181 (base32 "06zg74h249phszn1znfcjdz6c3lz350fiabdzn7iqb2xg4xh69a5"))))
6182 (build-system pyproject-build-system)
6183 (native-inputs
6184 (list python-pytest python-setuptools))
6185 (home-page "https://github.com/dahlia/wikidata")
6186 (synopsis "Wikidata client library")
6187 (description
6188 "This package provides a Python interface to @url{https://www.wikidata.org/,
6189Wikidata}.")
6190 (license license:gpl3+)))
6191
6192(define-public python-wsproto
6193 (package
6194 (name "python-wsproto")
6195 (version "1.2.0")
6196 (source
6197 (origin
6198 (method url-fetch)
6199 (uri (pypi-uri "wsproto" version))
6200 (sha256
6201 (base32 "0rahm1j9danv1l6i6as80acwv16ycihxkhrvwjiqh9drxhk5ymmd"))))
6202 (build-system pyproject-build-system)
6203 (native-inputs
6204 (list python-pytest python-setuptools python-wheel))
6205 (propagated-inputs
6206 (list python-h11))
6207 (home-page "https://github.com/python-hyper/wsproto/")
6208 (synopsis "WebSockets state-machine based protocol implementation")
6209 (description
6210 "@code{wsproto} is a pure-Python implementation of a WebSocket protocol
6211stack. It's written from the ground up to be embeddable in whatever program you
6212choose to use, ensuring that you can communicate via WebSockets, as defined in
6213RFC6455, regardless of your programming paradigm.")
6214 (license license:expat)))
6215
6216(define-public hypercorn
6217 (package
6218 (name "hypercorn")
6219 (version "0.18.0")
6220 (source
6221 (origin
6222 (method git-fetch) ;PyPI does not have tests
6223 (uri (git-reference
6224 (url "https://github.com/pgjones/hypercorn")
6225 (commit version)))
6226 (file-name (git-file-name name version))
6227 (sha256
6228 (base32 "0jdi05n5isxn0rysq242p198lz03gbwsnizzb9yp6rxr7ajapns4"))))
6229 (build-system pyproject-build-system)
6230 ;; Propagate because Hypercorn also exposes functionality over a module.
6231 (propagated-inputs (list python-h11
6232 python-h2
6233 python-priority
6234 python-tomli
6235 python-wsproto))
6236 (native-inputs (list nss-certs-for-test
6237 python-httpx
6238 python-pdm-backend
6239 python-poetry-core
6240 python-pytest
6241 python-pytest-asyncio
6242 python-pytest-trio
6243 python-trio))
6244 (home-page "https://gitlab.com/pgjones/hypercorn/")
6245 (synopsis "ASGI Server based on Hyper libraries")
6246 (description
6247 "Hypercorn is an ASGI web server based on the sans-io hyper, h11, h2, and
6248wsproto libraries and inspired by Gunicorn. It supports HTTP/1, HTTP/2,
6249WebSockets (over HTTP/1 and HTTP/2), ASGI/2, and ASGI/3 specifications. It
6250can utilise asyncio, uvloop, or trio worker types.")
6251 (license license:expat)))
6252
6253(define-public python-querystring-parser
6254 (package
6255 (name "python-querystring-parser")
6256 (version "1.2.4")
6257 (source
6258 (origin
6259 (method git-fetch)
6260 (uri (git-reference
6261 (url "https://github.com/bernii/querystring-parser")
6262 (commit version)))
6263 (file-name (git-file-name name version))
6264 (sha256
6265 (base32 "15n89bf1x9dgp1vi697pa238nvn0vbqp3ghf0xrcyqqa9gn1l6fb"))))
6266 (build-system pyproject-build-system)
6267 (arguments
6268 (list
6269 #:test-backend #~'custom
6270 #:test-flags #~(list "querystring_parser/tests.py")
6271 #:phases
6272 #~(modify-phases %standard-phases
6273 (add-after 'unpack 'fix-python-incompatibilities
6274 (lambda _
6275 (substitute* "querystring_parser/tests.py"
6276 ;; XXX FIXME: This test is broken with Python 3.7:
6277 ;; https://github.com/bernii/querystring-parser/issues/35
6278 (("self\\.assertEqual\\(self\\.knownValuesNormalized, result\\)")
6279 "True")
6280 ;; Removed in Python 3.12.
6281 (("assertEquals")
6282 "assertEqual")))))))
6283 (native-inputs (list python-setuptools))
6284 (propagated-inputs (list python-six))
6285 (home-page "https://github.com/bernii/querystring-parser")
6286 (synopsis "QueryString parser that correctly handles nested dictionaries")
6287 (description
6288 "This package provides a query string parser for Python and Django
6289projects that correctly creates nested dictionaries from sent form/querystring
6290data.")
6291 (license license:expat)))
6292
6293(define-public python-tornado
6294 (package
6295 (name "python-tornado")
6296 (version "6.4.2")
6297 (source
6298 (origin
6299 (method url-fetch)
6300 (uri (pypi-uri "tornado" version))
6301 (sha256
6302 (base32 "02v2mlvr58xg0l0gh08nswl53z73wkf23sziggypk63ffjsdbflj"))))
6303 (build-system pyproject-build-system)
6304 (arguments
6305 (list
6306 #:test-flags
6307 ;; AttributeError: 'TestIOStreamWebMixin' object has no attribute 'io_loop'
6308 #~(list "--ignore=tornado/test/iostream_test.py")))
6309 (native-inputs
6310 (list python-certifi
6311 python-pytest
6312 python-setuptools))
6313 (home-page "https://www.tornadoweb.org/")
6314 (synopsis "Python web framework and asynchronous networking library")
6315 (description
6316 "Tornado is a Python web framework and asynchronous networking library,
6317originally developed at FriendFeed. By using non-blocking network I/O,
6318Tornado can scale to tens of thousands of open connections, making it ideal
6319for long polling, WebSockets, and other applications that require a long-lived
6320connection to each user.")
6321 (license license:asl2.0)))
6322
6323;; XXX: Deprecated on <2026-01-23>.
6324(define-deprecated-package python-tornado-6 python-tornado)
6325
6326(define-public python-tornado-http-auth
6327 (package
6328 (name "python-tornado-http-auth")
6329 (version "1.1.1")
6330 (source
6331 (origin
6332 (method git-fetch)
6333 (uri (git-reference
6334 (url "https://github.com/gvalkov/tornado-http-auth")
6335 (commit (string-append "v" version))))
6336 (file-name (git-file-name name version))
6337 (sha256
6338 (base32 "1v9sin1zlck9wvkwx0ldqb1b271xlkq63562w8g1yb7v6qka9q4f"))))
6339 (build-system pyproject-build-system)
6340 ;; XXX: This version is incompatible with current tornado.testing.
6341 (arguments (list #:tests? #f))
6342 (native-inputs (list python-setuptools))
6343 (propagated-inputs (list python-tornado))
6344 (home-page "https://github.com/gvalkov/tornado-http-auth")
6345 (synopsis "Digest and basic authentication module for Tornado")
6346 (description
6347 "Provides support for adding authentication to services using the Tornado
6348web framework, either via the basic or digest authentication schemes.")
6349 (license license:asl2.0)))
6350
6351(define-public python-wsgi-intercept
6352 (package
6353 (name "python-wsgi-intercept")
6354 (version "1.13.1")
6355 (source (origin
6356 (method url-fetch)
6357 (uri (pypi-uri "wsgi_intercept" version))
6358 (sha256
6359 (base32
6360 "1h94dj7h7n7zdj3ll4imqjhq5vk21yidk2niwnmpw7xik9inrgbr"))))
6361 (build-system pyproject-build-system)
6362 (arguments
6363 (list
6364 ;; XXX: tests required internet access
6365 #:tests? #f))
6366 (propagated-inputs
6367 (list python-six))
6368 (native-inputs
6369 (list python-httplib2
6370 python-pytest
6371 python-requests
6372 python-setuptools
6373 python-urllib3
6374 python-wheel))
6375 (synopsis "Puts a WSGI application in place of a real URI for testing")
6376 (description "Wsgi_intercept installs a WSGI application in place of a real
6377URI for testing. Testing a WSGI application normally involves starting a
6378server at a local host and port, then pointing your test code to that address.
6379Instead, this library lets you intercept calls to any specific host/port
6380combination and redirect them into a WSGI application importable by your test
6381program. Thus, you can avoid spawning multiple processes or threads to test
6382your Web app.")
6383 (home-page "https://github.com/cdent/wsgi-intercept")
6384 (license license:expat)))
6385
6386(define-public python-webob
6387 (package
6388 (name "python-webob")
6389 (version "1.8.10")
6390 (source
6391 (origin
6392 (method url-fetch)
6393 (uri (pypi-uri "webob" version))
6394 (sha256
6395 (base32
6396 "0avwfsqqva46aix1p61jbwjsw7kh6zkxvfds9xi3zg07yc8km5hw"))))
6397 (build-system pyproject-build-system)
6398 ;; tests: 2394 passed, 9 skipped, 1 xfailed, 35 warnings
6399 (native-inputs
6400 (list python-pytest
6401 python-setuptools))
6402 (home-page "https://webob.org/")
6403 (synopsis "WSGI request and response object")
6404 (description
6405 "WebOb provides wrappers around the WSGI request environment, and an
6406object to help create WSGI responses.")
6407 (license license:expat)))
6408
6409(define-public python-yewtube-search
6410 (package
6411 (name "python-yewtube-search")
6412 ;; Original repository for python-youtube-search package is archived, see:
6413 ;; <https://github.com/alexmercerind/youtube-search-python/issues/189>.
6414 ;; The most promising fork was
6415 ;; <https://github.com/ahmedayyad-dev/youtube-search-python-fork> which is
6416 ;; archived since <2026-04-04>. This is another fork with a different PyPI
6417 ;; name for python-yewtube.
6418 (version "1.6.7")
6419 (source
6420 (origin
6421 (method url-fetch)
6422 (uri (pypi-uri "yewtube_search_python" version))
6423 (sha256
6424 (base32 "0vjh4wrlqx4lv9qi6572jx2d0rsp6gkvaqf0f2ar4npdz0ldgl47"))))
6425 (build-system pyproject-build-system)
6426 (arguments (list #:tests? #f)) ;no tests in repository
6427 (native-inputs
6428 (list python-setuptools))
6429 (propagated-inputs
6430 (list python-httpx))
6431 (home-page "https://github.com/iamtalhaasghar/youtube-search-python")
6432 (synopsis "Search for YouTube videos, channels & playlists")
6433 (description
6434 "This package provides tools to search for @code{YouTube} videos,
6435channels and playlists; as well as getting video metadata from links. This
6436package does not rely on the @code{YouTube} Data API v3.")
6437 (license license:expat)))
6438
6439(define-public python-zc-lockfile
6440 (package
6441 (name "python-zc-lockfile")
6442 (version "4.0")
6443 (source
6444 (origin
6445 (method git-fetch)
6446 (uri (git-reference
6447 (url "https://github.com/zopefoundation/zc.lockfile")
6448 (commit version)))
6449 (file-name (git-file-name name version))
6450 (sha256
6451 (base32 "0b1kkwx2d4wf392sd3bfjvzgkdrknwsxg9mby121mq8zl7c490gg"))))
6452 (build-system pyproject-build-system)
6453 (arguments
6454 (list
6455 #:phases
6456 #~(modify-phases %standard-phases
6457 (replace 'check
6458 (lambda* (#:key tests? #:allow-other-keys)
6459 (if tests?
6460 (invoke "zope-testrunner" "--test-path=src")
6461 (format #t "test suite not run~%")))))))
6462 (native-inputs (list python-zope-testing python-zope-testrunner
6463 python-setuptools))
6464 (home-page "https://github.com/zopefoundation/zc.lockfile")
6465 (synopsis "Interprocess locks using lock files")
6466 (description
6467 "This package provides an implementation of interprocess locks using lock
6468files. These locks can also be used to mediate access to other files.")
6469 (license license:zpl2.1)))
6470
6471(define-public python-zconfig
6472 (package
6473 (name "python-zconfig")
6474 (version "4.3")
6475 (source
6476 (origin
6477 (method git-fetch)
6478 (uri (git-reference
6479 (url "https://github.com/zopefoundation/ZConfig/")
6480 (commit version)))
6481 (file-name (git-file-name name version))
6482 (sha256
6483 (base32 "06c4vffk51fw03q87r31s81b0xbxg2qqvjfmcl2z4hg21fr088c2"))))
6484 (build-system pyproject-build-system)
6485 (arguments
6486 (list
6487 #:phases
6488 #~(modify-phases %standard-phases
6489 (replace 'check
6490 (lambda* (#:key tests? #:allow-other-keys)
6491 (if tests?
6492 (begin
6493 ;; This test assumes we still have setup.py in the
6494 ;; directory from which we import zconfig, which
6495 ;; does not work after installing the package.
6496 (delete-file-recursively
6497 "src/ZConfig/tests/test_readme.py")
6498 (invoke "zope-testrunner" "-vv" "--test-path=src" "--all"))
6499 (format #t "test suite not run~%")))))))
6500 (native-inputs (list python-docutils python-manuel python-zope-exceptions
6501 python-zope-testrunner python-setuptools))
6502 (home-page "https://github.com/zopefoundation/ZConfig/")
6503 (synopsis "Structured configuration library intended for general use")
6504 (description
6505 "@code{zconfig} is a configuration library intended for general use. It
6506supports a hierarchical schema-driven configuration model that allows a schema
6507to specify data conversion routines written in Python. Its model is very
6508different from the model supported by the @code{configparser} module found in
6509Python's standard library, and is more suitable to configuration-intensive
6510applications.")
6511 (license license:zpl2.1)))
6512
6513(define-public python-zodb
6514 (package
6515 (name "python-zodb")
6516 (version "6.0.1")
6517 (source
6518 (origin
6519 (method url-fetch)
6520 (uri (pypi-uri "zodb" version))
6521 (sha256
6522 (base32 "02cmvf8j2nin5z26wvy2vq2k9mj12hqrr4276lj3w4jj32p0zxw9"))))
6523 (build-system pyproject-build-system)
6524 (arguments
6525 (list
6526 #:phases
6527 #~(modify-phases %standard-phases
6528 (replace 'check
6529 (lambda* (#:key tests? #:allow-other-keys)
6530 (if tests?
6531 (begin
6532 ;; This test does not work after installing the
6533 ;; package, since it expects the ZODB source code
6534 ;; to reside in the src/ directory.
6535 (delete-file-recursively
6536 "src/ZODB/tests/testdocumentation.py")
6537 (invoke "zope-testrunner" "-vv" "--test-path=src"
6538 "--all"))
6539 (format #t "test suite not run~%")))))))
6540 (native-inputs
6541 (list python-manuel
6542 python-wheel
6543 python-zope-testing
6544 python-zope-testrunner))
6545 (propagated-inputs
6546 (list python-btrees
6547 python-persistent
6548 python-transaction
6549 python-zc-lockfile
6550 python-zconfig
6551 python-zodbpickle
6552 python-zope-interface))
6553 (home-page "http://zodb-docs.readthedocs.io")
6554 (synopsis "Object-oriented database for Python")
6555 (description
6556 "@code{ZODB} provides an object-oriented and @acronym{ACID,
6557Atomicity Consistency Isolation Durability} compliant database for Python with
6558a high degree of transparency. @code{ZODB} is an object-oriented database,
6559not an object-relational mapping. This comes with several advantaged:
6560
6561@itemize
6562@item no separate language for database operations
6563@item very little impact on your code to make objects persistent
6564@item no database mapper that partially hides the database.
6565@item almost no seam between code and database.
6566@end itemize")
6567 (license license:zpl2.1)))
6568
6569(define-public python-zodbpickle
6570 (package
6571 (name "python-zodbpickle")
6572 (version "3.2")
6573 (source
6574 (origin
6575 (method url-fetch)
6576 (uri (pypi-uri "zodbpickle" version))
6577 (sha256
6578 (base32 "035bjrksl4h92mvjkx6id4gjcpc1k4mbci8ryjl6l9mki7ihx77b"))))
6579 (build-system pyproject-build-system)
6580 (arguments
6581 '(#:phases (modify-phases %standard-phases
6582 (replace 'check
6583 (lambda* (#:key tests? #:allow-other-keys)
6584 (if tests?
6585 (invoke "zope-testrunner" "-vv" "--test-path=src"
6586 "--all")
6587 (format #t "test suite not run~%")))))))
6588 (native-inputs (list python-zope-testrunner python-setuptools python-wheel))
6589 (home-page "https://github.com/zopefoundation/zodbpickle")
6590 (synopsis "Uniform pickling interface for @code{zodb}")
6591 (description
6592 "This package is a fork of the @code{pickle} module (and the
6593supporting C extension) from both Python 3.2 and Python 3.3. The fork adds
6594support for the @code{noload} operations used by @code{zodb}.")
6595 (license (list license:psfl license:zpl2.1))))
6596
6597(define-public python-zope-dottedname
6598 (package
6599 (name "python-zope-dottedname")
6600 (version "7.0")
6601 (source
6602 (origin
6603 (method git-fetch)
6604 (uri (git-reference
6605 (url "https://github.com/zopefoundation/zope.dottedname")
6606 (commit version)))
6607 (file-name (git-file-name name version))
6608 (sha256
6609 (base32 "0h7a637zsl1a3f0rpb2nw41mzxv0pqyj8ahn6h60n2c1px912rbd"))))
6610 (build-system pyproject-build-system)
6611 (arguments
6612 (list #:test-backend #~'custom
6613 #:test-flags #~(list "src/zope/dottedname/tests.py")))
6614 (native-inputs (list python-setuptools))
6615 (home-page "https://zopedottedname.readthedocs.io")
6616 (synopsis "Resolver for Python dotted names")
6617 (description
6618 "This package provides a @code{resolve()} function that resolves strings
6619containing dotted names into the appropriate Python object.")
6620 (license license:zpl2.1)))
6621
6622(define-public python-zope-event
6623 (package
6624 (name "python-zope-event")
6625 (version "6.0")
6626 (source
6627 (origin
6628 (method git-fetch)
6629 (uri (git-reference
6630 (url "https://github.com/zopefoundation/zope.event")
6631 (commit version)))
6632 (file-name (git-file-name name version))
6633 (sha256
6634 (base32 "0la3q47c59aq50s036q468bhnmzgs71f1cygv89w6qkk1hkn35ym"))))
6635 (build-system pyproject-build-system)
6636 (arguments
6637 (list
6638 #:test-flags
6639 #~(list "src/zope/event/tests.py")))
6640 (native-inputs (list python-pytest python-setuptools))
6641 (home-page "https://zopeevent.readthedocs.io/en/latest/")
6642 (synopsis "Event publishing system for Python")
6643 (description
6644 "Zope.event provides an event publishing API, intended for use by
6645applications which are unaware of any subscribers to their events. It is a
6646simple event-dispatching system on which more sophisticated event dispatching
6647systems can be built.")
6648 (license license:zpl2.1)))
6649
6650(define-public python-zope-interface
6651 (package
6652 (name "python-zope-interface")
6653 (version "7.2")
6654 (source
6655 (origin
6656 (method git-fetch)
6657 (uri (git-reference
6658 (url "https://github.com/zopefoundation/zope.interface")
6659 (commit version)))
6660 (file-name (git-file-name name version))
6661 (sha256
6662 (base32 "01snm1lbqhx3ird4m76nciaqasxvf8dd6817zm35v684g5hbzd2s"))))
6663 (build-system pyproject-build-system)
6664 (arguments
6665 ;; XXX: test suite can't find python-zope-testing
6666 (list #:tests? #f))
6667 (native-inputs (list python-setuptools))
6668 (home-page "https://zopeinterface.readthedocs.io")
6669 (synopsis "\"Design by contract\" methodology in Python")
6670 (description
6671 "Zope.interface provides an implementation of \"object interfaces\" for
6672Python. Interfaces are a mechanism for labeling objects as conforming to a
6673given API or contract.")
6674 (license license:zpl2.1)))
6675
6676(define-public python-zope-exceptions
6677 (package
6678 (name "python-zope-exceptions")
6679 (version "6.0")
6680 (source
6681 (origin
6682 (method git-fetch)
6683 (uri (git-reference
6684 (url "https://github.com/zopefoundation/zope.exceptions")
6685 (commit version)))
6686 (file-name (git-file-name name version))
6687 (sha256
6688 (base32 "0fmsw2j8islaiv6zf2mxh2s43y7virqny6s8gk8v2zkcxpy95cic"))))
6689 (build-system pyproject-build-system)
6690 (arguments
6691 (list
6692 #:phases
6693 #~(modify-phases %standard-phases
6694 (replace 'check
6695 (lambda* (#:key tests? #:allow-other-keys)
6696 (if tests?
6697 (invoke "zope-testrunner" "--test-path=src")
6698 (format #t "test suite not run~%")))))))
6699 (native-inputs (list python-setuptools python-zope-testrunner-bootstrap))
6700 (propagated-inputs (list python-zope-interface))
6701 (home-page "https://github.com/zopefoundation/zope.exceptions")
6702 (synopsis "Zope exceptions")
6703 (description
6704 "Zope.exceptions provides general-purpose exception types that have uses
6705outside of the Zope framework.")
6706 (license license:zpl2.1)))
6707
6708(define (python-zope-bootstrap-package orig)
6709 (package
6710 (inherit orig)
6711 (name (string-append (package-name orig) "-bootstrap"))
6712 (arguments
6713 (if (null? (package-arguments orig))
6714 (list
6715 #:tests? #f
6716 #:phases #~(modify-phases %standard-phases
6717 (delete 'sanity-check)))
6718 (substitute-keyword-arguments arguments
6719 ((#:tests? _ #f) #f)
6720 ((#:phases phases '%standard-phases)
6721 #~(modify-phases #$phases
6722 (delete 'sanity-check))))))
6723 (propagated-inputs `())
6724 (native-inputs (list python-setuptools))
6725 (properties `((hidden? . #t)))))
6726
6727(define-public python-zope-exceptions-bootstrap
6728 (python-zope-bootstrap-package python-zope-exceptions))
6729
6730(define-public python-zope-testing
6731 (package
6732 (name "python-zope-testing")
6733 (version "6.0")
6734 (source
6735 (origin
6736 (method git-fetch)
6737 (uri (git-reference
6738 (url "https://github.com/zopefoundation/zope.testing")
6739 (commit version)))
6740 (file-name (git-file-name name version))
6741 (sha256
6742 (base32 "0zqipsgv7qj7f8hrd3x6xpqwszdiac8vpjdm8ak5kljl5napw7d7"))))
6743 (build-system pyproject-build-system)
6744 (arguments
6745 (list
6746 #:phases
6747 #~(modify-phases %standard-phases
6748 (replace 'check
6749 (lambda* (#:key tests? #:allow-other-keys)
6750 (if tests?
6751 (invoke "zope-testrunner" "--test-path=src")
6752 (format #t "test suite not run~%")))))))
6753 (native-inputs (list python-setuptools
6754 python-zope-interface
6755 python-zope-testrunner-bootstrap))
6756 (home-page "https://zopetesting.readthedocs.io/")
6757 (synopsis "Zope testing helpers")
6758 (description
6759 "Zope.testing provides a number of testing utilities for HTML forms, HTTP
6760servers, regular expressions, and more.")
6761 (license license:zpl2.1)))
6762
6763(define-public python-zope-testrunner
6764 (package
6765 (name "python-zope-testrunner")
6766 (version "7.4")
6767 (source
6768 (origin
6769 (method git-fetch)
6770 (uri (git-reference
6771 (url "https://github.com/zopefoundation/zope.testrunner")
6772 (commit version)))
6773 (file-name (git-file-name name version))
6774 (sha256
6775 (base32 "0gd5rnzw6vzbx766jxqr4zc6qx7gk75r2c0nqqvhkb12hzk5ca2g"))))
6776 (build-system pyproject-build-system)
6777 (arguments
6778 (list
6779 #:phases
6780 #~(modify-phases %standard-phases
6781 (add-after 'unpack 'remove-problematic-test
6782 (lambda _
6783 ;; This test contains invalid syntax, which breaks bytecode
6784 ;; compilation. For simplicity just remove it.
6785 (delete-file
6786 "src/zope/testrunner/tests/testrunner-ex/sample2/badsyntax.py")))
6787 (replace 'check
6788 (lambda* (#:key tests? #:allow-other-keys)
6789 (if tests?
6790 (invoke "zope-testrunner" "--test-path=src")
6791 (format #t "test suite not run~%")))))))
6792 (native-inputs (list python-setuptools python-zope-testing))
6793 (propagated-inputs (list python-zope-exceptions python-zope-interface))
6794 (home-page "https://zopetestrunner.readthedocs.io")
6795 (synopsis "Zope testrunner script")
6796 (description "This package provides a script for running Python tests.")
6797 (license license:zpl2.1)))
6798
6799(define-public python-zope-testrunner-bootstrap
6800 (package
6801 (inherit (python-zope-bootstrap-package python-zope-testrunner))
6802 (propagated-inputs
6803 (list python-six python-zope-exceptions-bootstrap))
6804 (properties `((hidden? . #t)))))
6805
6806(define-public python-zope-i18nmessageid
6807 (package
6808 (name "python-zope-i18nmessageid")
6809 (version "7.0")
6810 (source
6811 (origin
6812 (method git-fetch)
6813 (uri (git-reference
6814 (url "https://github.com/zopefoundation/zope.i18nmessageid")
6815 (commit version)))
6816 (file-name (git-file-name name version))
6817 (sha256
6818 (base32 "192ixj8r9n467avbxrmhakmqiaflc1vw37k08z096ajcjgbfrm5d"))))
6819 (build-system pyproject-build-system)
6820 (arguments
6821 (list
6822 #:phases
6823 #~(modify-phases %standard-phases
6824 (replace 'check
6825 (lambda* (#:key tests? #:allow-other-keys)
6826 (if tests?
6827 (invoke "zope-testrunner" "--test-path=src")
6828 (format #t "test suite not run~%")))))))
6829 (native-inputs (list python-setuptools python-zope-testrunner))
6830 (home-page "https://zopei18nmessageid.readthedocs.io")
6831 (synopsis "Message identifiers for internationalization")
6832 (description "Zope.i18nmessageid provides facilities for declaring
6833internationalized messages within program source text.")
6834 (license license:zpl2.1)))
6835
6836(define-public python-zope-schema
6837 (package
6838 (name "python-zope-schema")
6839 (version "7.0.1")
6840 (source
6841 (origin
6842 (method git-fetch)
6843 (uri (git-reference
6844 (url "https://github.com/zopefoundation/zope.schema")
6845 (commit version)))
6846 (file-name (git-file-name name version))
6847 (sha256
6848 (base32 "1hj6j0gqgvv9a5pyaz54wbn8n7wf9lyg4njb2cfs980z0d5faj39"))))
6849 (build-system pyproject-build-system)
6850 (arguments
6851 (list
6852 #:phases
6853 #~(modify-phases %standard-phases
6854 (replace 'check
6855 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
6856 (add-installed-pythonpath inputs outputs)
6857 (if tests?
6858 (invoke "zope-testrunner" "--test-path=src")
6859 (format #t "test suite not run.~%")))))))
6860 (propagated-inputs (list python-zope-event python-zope-interface))
6861 (native-inputs (list python-zope-i18nmessageid python-zope-testing
6862 python-zope-testrunner python-setuptools))
6863 (home-page "https://zopeschema.readthedocs.io")
6864 (synopsis "Zope data schemas")
6865 (description "Zope.scheme provides extensions to zope.interface for
6866defining data schemas.")
6867 (license license:zpl2.1)))
6868
6869(define-public python-zope-sqlalchemy
6870 (package
6871 (name "python-zope-sqlalchemy")
6872 (version "1.6")
6873 (source
6874 (origin
6875 (method git-fetch)
6876 (uri (git-reference
6877 (url "https://github.com/zopefoundation/zope.sqlalchemy")
6878 (commit version)))
6879 (file-name (git-file-name name version))
6880 (sha256
6881 (base32 "1z4gw4i95dyqxsvrahk4fav008045n8kyxpn3fa887snmpvcjhng"))))
6882 (build-system pyproject-build-system)
6883 (arguments
6884 (list
6885 #:phases
6886 #~(modify-phases %standard-phases
6887 (replace 'check
6888 (lambda* (#:key tests? #:allow-other-keys)
6889 (if tests?
6890 (invoke "zope-testrunner" "--test-path=src")
6891 (format #t "test suite not run~%")))))))
6892 (propagated-inputs (list python-sqlalchemy python-transaction
6893 python-zope-interface))
6894 (native-inputs (list python-zope-testing python-zope-testrunner
6895 python-setuptools))
6896 (home-page "https://github.com/zopefoundation/zope.sqlalchemy")
6897 (synopsis "Minimal SQLAlchemy transaction integration for Zope")
6898 (description
6899 "The aim of this package is to unify the plethora of existing packages
6900integrating SQLAlchemy with Zope's transaction management. As such,it only
6901provides a data manager and makes no attempt to define a @i{zopeish} way to
6902configure engines.")
6903 (license license:zpl2.1)))
6904
6905(define-public python-zope-configuration
6906 (package
6907 (name "python-zope-configuration")
6908 (version "7.0")
6909 (source
6910 (origin
6911 (method git-fetch)
6912 (uri (git-reference
6913 (url "https://github.com/zopefoundation/zope.configuration")
6914 (commit version)))
6915 (file-name (git-file-name name version))
6916 (sha256
6917 (base32 "11lr6z3jpz9835a1if89g3x7k31sviq2d0xvvic5xi4c980dbkhv"))))
6918 (build-system pyproject-build-system)
6919 (arguments
6920 (list
6921 #:phases
6922 #~(modify-phases %standard-phases
6923 (replace 'check
6924 (lambda* (#:key tests? #:allow-other-keys)
6925 (if tests?
6926 (invoke "zope-testrunner" "--test-path=src")
6927 (format #t "test suite not run~%")))))))
6928 (native-inputs (list python-manuel python-setuptools python-zope-testing
6929 python-zope-testrunner))
6930 (propagated-inputs (list python-zope-i18nmessageid python-zope-interface
6931 python-zope-schema))
6932 (home-page "https://zopeconfiguration.readthedocs.io")
6933 (synopsis "Zope Configuration Markup Language")
6934 (description "Zope.configuration implements ZCML, the Zope Configuration
6935Markup Language.")
6936 (license license:zpl2.1)))
6937
6938(define-public python-zope-configuration-bootstrap
6939 (python-zope-bootstrap-package python-zope-configuration))
6940
6941(define-public python-zope-copy
6942 (package
6943 (name "python-zope-copy")
6944 (version "6.0")
6945 (source
6946 (origin
6947 (method git-fetch)
6948 (uri (git-reference
6949 (url "https://github.com/zopefoundation/zope.copy")
6950 (commit version)))
6951 (file-name (git-file-name name version))
6952 (sha256
6953 (base32 "1ym82p9scpfi3rflxnlv55v0a7hra3rq4rrlw759maq05i8qp1w5"))))
6954 (build-system pyproject-build-system)
6955 (arguments
6956 (list
6957 #:phases
6958 #~(modify-phases %standard-phases
6959 (replace 'check
6960 (lambda* (#:key tests? #:allow-other-keys)
6961 (if tests?
6962 (invoke "zope-testrunner" "--test-path=src")
6963 (format #t "test suite not run~%")))))))
6964 (propagated-inputs (list python-zope-interface))
6965 (native-inputs
6966 (list python-zodbpickle
6967 python-zope-component-bootstrap
6968 python-zope-location-bootstrap
6969 python-zope-proxy
6970 python-zope-schema
6971 python-zope-testing
6972 python-zope-testrunner
6973 python-setuptools))
6974 (home-page "https://zopecopy.readthedocs.io")
6975 (synopsis "Pluggable object copying mechanism")
6976 (description
6977 "This package provides a pluggable mechanism for copying persistent objects.")
6978 (license license:zpl2.1)))
6979
6980(define-public python-zope-proxy
6981 (package
6982 (name "python-zope-proxy")
6983 (version "7.0")
6984 (source
6985 (origin
6986 (method git-fetch)
6987 (uri (git-reference
6988 (url "https://github.com/zopefoundation/zope.proxy")
6989 (commit version)))
6990 (file-name (git-file-name name version))
6991 (sha256
6992 (base32 "00r9f4n0cl3fyc5gyf5l43zh95cmzx1gz6wr04k17d7wm2gmivyn"))))
6993 (build-system pyproject-build-system)
6994 (arguments
6995 (list
6996 #:phases
6997 #~(modify-phases %standard-phases
6998 (replace 'check
6999 (lambda* (#:key tests? #:allow-other-keys)
7000 (if tests?
7001 (invoke "zope-testrunner" "--test-path=src")
7002 (format #t "test suite not run~%")))))))
7003 (native-inputs
7004 (list python-zope-location-bootstrap
7005 python-zope-security-bootstrap
7006 python-zope-testrunner
7007 python-setuptools))
7008 (propagated-inputs (list python-zope-interface))
7009 (home-page "https://zopeproxy.readthedocs.io")
7010 (synopsis "Generic, transparent proxies")
7011 (description
7012 "Zope.proxy provides generic, transparent proxies for Python. Proxies are
7013special objects which serve as mostly-transparent wrappers around another
7014object, intervening in the apparent behavior of the wrapped object only when
7015necessary to apply the policy (e.g., access checking, location brokering,
7016etc.) for which the proxy is responsible.")
7017 (license license:zpl2.1)))
7018
7019(define-public python-zope-proxy-bootstrap
7020 (python-zope-bootstrap-package python-zope-proxy))
7021
7022(define-public python-zope-hookable
7023 (package
7024 (name "python-zope-hookable")
7025 (version "7.0")
7026 (source
7027 (origin
7028 (method git-fetch)
7029 (uri (git-reference
7030 (url "https://github.com/zopefoundation/zope.hookable")
7031 (commit version)))
7032 (file-name (git-file-name name version))
7033 (sha256
7034 (base32 "1l94xzzpyslpgv2ghvl5qzpfcsq02kp04fmvl95d6jcmivmmr4m8"))))
7035 (build-system pyproject-build-system)
7036 (arguments
7037 (list
7038 #:phases
7039 #~(modify-phases %standard-phases
7040 (replace 'check
7041 (lambda* (#:key tests? #:allow-other-keys)
7042 (if tests?
7043 (invoke "zope-testrunner" "--test-path=src")
7044 (format #t "test suite not run~%")))))))
7045 (native-inputs (list python-zope-testing python-zope-testrunner
7046 python-setuptools))
7047 (home-page "https://zopehookable.readthedocs.io")
7048 (synopsis "Zope hookable")
7049 (description
7050 "This package supports the efficient creation of hookable objects, which
7051are callable objects that are meant to be optionally replaced. The idea is
7052that you create a function that does some default thing and make i hookable.
7053Later, someone can modify what it does by calling its sethook method and
7054changing its implementation. All users of the function, including those that
7055imported it, will see the change.")
7056 (license license:zpl2.1)))
7057
7058(define-public python-zope-location
7059 (package
7060 (name "python-zope-location")
7061 (version "6.0")
7062 (source
7063 (origin
7064 (method git-fetch)
7065 (uri (git-reference
7066 (url "https://github.com/zopefoundation/zope.location")
7067 (commit version)))
7068 (file-name (git-file-name name version))
7069 (sha256
7070 (base32 "1jfsmbxj6hz7kmk5b0351b63ssm7qfkgqmz9v7xb7wwlmxsxkcdk"))))
7071 (build-system pyproject-build-system)
7072 (arguments
7073 (list
7074 #:phases
7075 #~(modify-phases %standard-phases
7076 (replace 'check
7077 (lambda* (#:key tests? #:allow-other-keys)
7078 (if tests?
7079 (invoke "zope-testrunner" "--test-path=src")
7080 (format #t "test suite not run~%")))))))
7081 (native-inputs (list python-zope-testrunner python-setuptools))
7082 (propagated-inputs (list python-zope-interface python-zope-proxy
7083 python-zope-schema))
7084 (home-page "https://zopelocation.readthedocs.io")
7085 (synopsis "Zope location library")
7086 (description
7087 "Zope.location implements the concept of \"locations\" in Zope3, which
7088are are special objects that have a structural location.")
7089 (license license:zpl2.1)))
7090
7091(define-public python-zope-location-bootstrap
7092 (python-zope-bootstrap-package python-zope-location))
7093
7094(define-public python-zope-security
7095 (package
7096 (name "python-zope-security")
7097 (version "7.3")
7098 (source
7099 (origin
7100 (method git-fetch)
7101 (uri (git-reference
7102 (url "https://github.com/zopefoundation/zope.security")
7103 (commit version)))
7104 (file-name (git-file-name name version))
7105 (sha256
7106 (base32 "06x6qcls2mdl05xnsyy5h70mbgij8xb6ksxbawzrc23cq04nkvx7"))))
7107 (build-system pyproject-build-system)
7108 (arguments
7109 (list
7110 #:phases
7111 #~(modify-phases %standard-phases
7112 (replace 'check
7113 (lambda* (#:key tests? #:allow-other-keys)
7114 (if tests?
7115 (invoke "zope-testrunner" "--test-path=src")
7116 (format #t "test suite not run~%")))))))
7117 (propagated-inputs
7118 (list python-zope-component
7119 python-zope-i18nmessageid
7120 python-zope-interface
7121 python-zope-location
7122 python-zope-proxy
7123 python-zope-schema))
7124 (native-inputs
7125 (list python-btrees
7126 python-zope-component-bootstrap
7127 python-zope-configuration-bootstrap
7128 python-zope-location-bootstrap
7129 python-zope-testing
7130 python-zope-testrunner
7131 python-setuptools))
7132 (home-page "https://zopesecurity.readthedocs.io")
7133 (synopsis "Zope security framework")
7134 (description "Zope.security provides a generic mechanism to implement
7135security policies on Python objects.")
7136 (license license:zpl2.1)))
7137
7138(define-public python-zope-security-bootstrap
7139 (package
7140 (inherit (python-zope-bootstrap-package python-zope-security))
7141 (propagated-inputs
7142 (list python-zope-i18nmessageid
7143 python-zope-interface
7144 python-zope-proxy-bootstrap
7145 python-zope-schema))))
7146
7147(define-public python-zope-component
7148 (package
7149 (name "python-zope-component")
7150 (version "7.0")
7151 (source
7152 (origin
7153 (method git-fetch)
7154 (uri (git-reference
7155 (url "https://github.com/zopefoundation/zope.component")
7156 (commit version)))
7157 (file-name (git-file-name name version))
7158 (sha256
7159 (base32 "1jygzhcg9rppsrd8cwvm0944naq1ldjf0vcpgsz0glwcdnr7cyfw"))))
7160 (build-system pyproject-build-system)
7161 (arguments
7162 (list
7163 #:phases
7164 #~(modify-phases %standard-phases
7165 (replace 'check
7166 (lambda* (#:key tests? #:allow-other-keys)
7167 (if tests?
7168 (invoke "zope-testrunner" "--test-path=src")
7169 (format #t "test suite not run~%")))))))
7170 (native-inputs
7171 (list python-persistent
7172 python-zope-configuration-bootstrap
7173 python-zope-i18nmessageid
7174 python-zope-location-bootstrap
7175 python-zope-proxy-bootstrap
7176 python-zope-security-bootstrap
7177 python-zope-testing
7178 python-zope-testrunner
7179 python-setuptools))
7180 (propagated-inputs
7181 (list python-zope-deferredimport python-zope-deprecation
7182 python-zope-event python-zope-hookable python-zope-interface))
7183 (home-page "https://zopecomponent.readthedocs.io")
7184 (synopsis "Zope Component Architecture")
7185 (description
7186 "Zope.component represents the core of the Zope Component Architecture.
7187Together with the zope.interface package, it provides facilities for defining,
7188registering and looking up components.")
7189 (license license:zpl2.1)))
7190
7191(define-public python-zope-component-bootstrap
7192 (python-zope-bootstrap-package python-zope-component))
7193
7194(define-public python-zope-deferredimport
7195 (package
7196 (name "python-zope-deferredimport")
7197 (version "6.0")
7198 (source
7199 (origin
7200 (method git-fetch)
7201 (uri (git-reference
7202 (url "https://github.com/zopefoundation/zope.deferredimport")
7203 (commit version)))
7204 (file-name (git-file-name name version))
7205 (sha256
7206 (base32 "08j728nn1la570nny1xz1xvxcm9hf2mcc3im1bzcxxrrxh4kw3zd"))))
7207 (build-system pyproject-build-system)
7208 (arguments
7209 (list
7210 #:phases
7211 #~(modify-phases %standard-phases
7212 (replace 'check
7213 (lambda* (#:key tests? #:allow-other-keys)
7214 (if tests?
7215 (invoke "zope-testrunner" "--test-path=src")
7216 (format #t "test suite not run~%")))))))
7217 (propagated-inputs (list python-zope-proxy))
7218 (native-inputs (list python-zope-testrunner python-setuptools))
7219 (home-page "https://zopedeferredimport.readthedocs.io")
7220 (synopsis "Defer imports until used by code")
7221 (description
7222 "Often, especially for package modules, you want to import names for
7223convenience, but not actually perform the imports until necessary. The
7224@code{zope.deferredimport} package provided facilities for defining names in
7225modules that will be imported from somewhere else when used. You can also cause
7226deprecation warnings to be issued when a variable is used.")
7227 (license license:zpl2.1)))
7228
7229(define-public python-ndg-httpsclient
7230 (package
7231 (name "python-ndg-httpsclient")
7232 (version "0.5.1")
7233 (source
7234 (origin
7235 (method git-fetch)
7236 (uri (git-reference
7237 (url "https://github.com/cedadev/ndg_httpsclient/")
7238 (commit version)))
7239 (file-name (git-file-name name version))
7240 (sha256
7241 (base32 "0lhsgs4am4xyjssng5p0vkfwqncczj1dpa0vss4lrhzq86mnn5rz"))))
7242 (build-system pyproject-build-system)
7243 (arguments
7244 (list
7245 #:tests? #f)) ;Tests appear to require networking.
7246 (native-inputs (list python-setuptools))
7247 (propagated-inputs (list python-pyasn1 python-pyopenssl))
7248 (synopsis "HTTPS support for Python's httplib and urllib2")
7249 (description
7250 "This is a HTTPS client implementation for httplib and urllib2 based on
7251PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation over
7252the default provided with Python and, importantly, enables full verification
7253of the SSL peer.")
7254 (home-page "https://github.com/cedadev/ndg_httpsclient/")
7255 (license license:bsd-3)))
7256
7257(define-public python-netaddr
7258 (package
7259 (name "python-netaddr")
7260 (version "1.3.0")
7261 (source
7262 (origin
7263 (method url-fetch)
7264 (uri (pypi-uri "netaddr" version))
7265 (sha256
7266 (base32 "12p4ysgawhgkka0sz1dkwgwc2za80dxdp9wvfxivfldmjnc3sg2w"))))
7267 (build-system pyproject-build-system)
7268 (native-inputs (list python-poetry-core
7269 python-pytest
7270 python-setuptools
7271 python-wheel))
7272 (home-page "https://netaddr.readthedocs.io")
7273 (synopsis "Pythonic manipulation of network addresses")
7274 (description
7275 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
7276and MAC network addresses.")
7277 (license license:bsd-3)))
7278
7279(define-public python-nh3
7280 (package
7281 (name "python-nh3")
7282 (version "0.2.20")
7283 (source
7284 (origin
7285 (method url-fetch)
7286 (uri (pypi-uri "nh3" version))
7287 (sha256
7288 (base32 "1mcf3y5294glji9lhzh57wymw4srbvzdg0kcakm0p2pqgwnw81cp"))))
7289 (build-system pyproject-build-system)
7290 (arguments
7291 (list
7292 #:imported-modules `(,@%cargo-build-system-modules
7293 ,@%pyproject-build-system-modules)
7294 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
7295 (guix build pyproject-build-system)
7296 (guix build utils))
7297 #:phases
7298 #~(modify-phases %standard-phases
7299 (add-after 'unpack 'prepare-cargo-build-system
7300 (lambda args
7301 (for-each
7302 (lambda (phase)
7303 (format #t "Running cargo phase: ~a~%" phase)
7304 (apply (assoc-ref cargo:%standard-phases phase)
7305 #:cargo-target #$(cargo-triplet)
7306 args))
7307 '(unpack-rust-crates
7308 configure
7309 check-for-pregenerated-files
7310 patch-cargo-checksums)))))))
7311 (native-inputs
7312 (append
7313 (list maturin python-pytest rust `(,rust "cargo"))
7314 (or (and=> (%current-target-system)
7315 (compose list make-rust-sysroot))
7316 '())))
7317 (inputs (cargo-inputs 'python-nh3))
7318 (home-page "https://nh3.readthedocs.io")
7319 (synopsis "Python bindings to Ammonia HTML sanitization library")
7320 (description "This package provides Python bindings to Ammonia HTML
7321sanitizer Rust crate.")
7322 (license license:expat)))
7323
7324(define-public python-noiseprotocol
7325 (package
7326 (name "python-noiseprotocol")
7327 (version "0.3.1")
7328 (source
7329 (origin
7330 (method git-fetch)
7331 (uri (git-reference
7332 (url "https://github.com/plizonczyk/noiseprotocol")
7333 (commit (string-append "v" version))))
7334 (file-name (git-file-name name version))
7335 (sha256
7336 (base32 "1mk0rqpjifdv3v1cjwkdnjbrfmzzjm9f3qqs1r8vii4j2wvhm6am"))))
7337 (build-system pyproject-build-system)
7338 (propagated-inputs (list python-cryptography))
7339 (native-inputs (list python-setuptools python-pytest))
7340 (home-page "https://github.com/plizonczyk/noiseprotocol")
7341 (synopsis "Implementation of Noise Protocol Framework")
7342 (description
7343 "This package provides an implementation of Noise Protocol Framework.")
7344 (license license:expat)))
7345
7346(define-public python-webrtcvad-wheels
7347 (package
7348 (name "python-webrtcvad-wheels")
7349 (version "2.0.14")
7350 (source
7351 (origin
7352 (method git-fetch)
7353 (uri (git-reference
7354 (url "https://github.com/daanzu/py-webrtcvad-wheels")
7355 (commit (string-append "v" version))))
7356 (file-name (git-file-name name version))
7357 (sha256
7358 (base32 "0sqgg8jmg2j14f4h96h0rs42kr460v65lhanps6lhdvj5zp81cbh"))))
7359 (build-system pyproject-build-system)
7360 (native-inputs (list python-psutil python-pytest python-setuptools))
7361 (home-page "https://github.com/daanzu/py-webrtcvad-wheels")
7362 (synopsis "Python interface to the WebRTC Voice Activity Detector (VAD)")
7363 (description
7364 "This package provides a Python interface to the Google
7365@url{https://webrtc.org/, WebRTC} @acronym{VAD, Voice Activity Detector}.")
7366 (license license:expat)))
7367
7368(define-public python-websocket-client
7369 (package
7370 (name "python-websocket-client")
7371 (version "1.8.0")
7372 (source
7373 (origin
7374 (method url-fetch)
7375 (uri (pypi-uri "websocket_client" version))
7376 (sha256
7377 (base32 "1nn3qi5g59j55wfy2z02j6lq2cm281fq0wi406b2yqys8jgxyf9j"))))
7378 (build-system pyproject-build-system)
7379 (arguments
7380 (list
7381 #:test-flags
7382 ;; This test requires networking.
7383 '(list "-k" "not testConnect")))
7384 (native-inputs
7385 (list python-pysocks
7386 python-pytest
7387 python-setuptools
7388 python-websockets
7389 python-wheel))
7390 (home-page "https://github.com/websocket-client/websocket-client")
7391 (synopsis "WebSocket client for Python")
7392 (description "The Websocket-client module provides the low level APIs for
7393WebSocket usage in Python programs.")
7394 (license license:lgpl2.1+)))
7395
7396(define-public python-websocket-client-0.59
7397 (package
7398 (inherit python-websocket-client)
7399 (version "0.59.0")
7400 (source
7401 (origin
7402 (method url-fetch)
7403 (uri (pypi-uri "websocket-client" version))
7404 (sha256
7405 (base32 "0p0cz2mdissq7iw1n7jrmsfir0jfmgs1dvnpnrx477ffx9hbsxnk"))))
7406 (native-inputs
7407 (modify-inputs native-inputs
7408 (append python-six)))))
7409
7410(define-public python-purl
7411 (package
7412 (name "python-purl")
7413 (version "1.6")
7414 (source
7415 (origin
7416 (method git-fetch)
7417 (uri (git-reference
7418 (url "https://github.com/codeinthehole/purl")
7419 (commit version)))
7420 (file-name (git-file-name name version))
7421 (sha256
7422 (base32 "01zngf0s0qfsrsk0skn57frbzyscwv8467pfjk6hxdfgdx2wkg95"))))
7423 (build-system pyproject-build-system)
7424 (arguments
7425 (list
7426 #:test-flags #~(list "--pyargs" "./tests")))
7427 (native-inputs (list python-pytest python-setuptools))
7428 (propagated-inputs (list python-six))
7429 (home-page "https://github.com/codeinthehole/purl")
7430 (synopsis "Python package for URL manipulation")
7431 (description "Purl is a Python package for handling URLs.")
7432 (license license:expat)))
7433
7434(define-public python-apiron
7435 (package
7436 (name "python-apiron")
7437 (version "5.1.0")
7438 (source
7439 (origin
7440 (method url-fetch)
7441 (uri (pypi-uri "apiron" version))
7442 (sha256
7443 (base32 "1qwbqn47sf0aqznj1snbv37v8ijx476qqkjf5l9pac7xjkxsr8qk"))))
7444 (build-system pyproject-build-system)
7445 (arguments
7446 (list #:test-flags '(list "-k" "not test_call")))
7447 (propagated-inputs
7448 (list python-requests))
7449 (native-inputs
7450 (list python-pytest
7451 python-setuptools
7452 python-wheel))
7453 (home-page "https://github.com/ithaka/apiron")
7454 (synopsis "Python wrapper for interacting with RESTful APIs")
7455 (description
7456 "@code{apiron} provides a declarative, structured configuration of
7457services and endpoints with a unified interface for interacting with RESTful
7458APIs.")
7459 (license license:expat)))
7460
7461(define-public python-beren
7462 (package
7463 (name "python-beren")
7464 (version "0.7.0")
7465 (source
7466 (origin
7467 (method git-fetch)
7468 (uri (git-reference
7469 (url "https://github.com/teffalump/beren")
7470 (commit (string-append "v" version))))
7471 (file-name (git-file-name name version))
7472 (sha256
7473 (base32 "19nnvbjx2wypslqklqi0j9fiwypk1a5qwfw1jcabjw03awm1yyrx"))))
7474 (build-system pyproject-build-system)
7475 (arguments
7476 ;; The test tries to open a connection to a remote server.
7477 `(#:tests? #f))
7478 (native-inputs (list python-setuptools))
7479 (propagated-inputs (list python-apiron))
7480 (home-page "https://github.com/teffalump/beren")
7481 (synopsis "REST client for Orthanc DICOM servers")
7482 (description
7483 "@code{beren} provides a REST client for Orthanc, a DICOM server.")
7484 (license license:gpl3+)))
7485
7486(define-public python-requests
7487 (package
7488 (name "python-requests")
7489 (version "2.32.5")
7490 (source (origin
7491 (method url-fetch)
7492 (uri (pypi-uri "requests" version))
7493 (sha256
7494 (base32
7495 "1kypqz701x9s7j4shm1pdnzy4pzx9lmvhwgan0yqa071asn0pfnv"))))
7496 (build-system pyproject-build-system)
7497 (arguments
7498 (list #:test-flags
7499 ;; These require internet access
7500 '(list "--ignore=tests/test_requests.py"
7501 "-k" (string-append "not test_use_proxy_from_environment"
7502 " and not requests.sessions.Session"
7503 " and not requests.models.PreparedRequest"
7504 " and not requests.api.request")
7505 "tests/")))
7506 (propagated-inputs
7507 (list python-certifi
7508 python-charset-normalizer
7509 python-idna
7510 python-urllib3))
7511 (native-inputs
7512 (list python-pytest
7513 python-pytest-mock
7514 python-setuptools))
7515 (home-page "https://requests.readthedocs.io/")
7516 (synopsis "Python HTTP library")
7517 (description
7518 "Requests is a Python HTTP client library. It aims to be easier to use
7519than Python’s urllib2 library.")
7520 (license license:asl2.0)))
7521
7522(define-public python-requests-kerberos
7523 (package
7524 (name "python-requests-kerberos")
7525 (version "0.14.0")
7526 ;; No tests in the PyPI tarball.
7527 (source
7528 (origin
7529 (method git-fetch)
7530 (uri (git-reference
7531 (url "https://github.com/requests/requests-kerberos")
7532 (commit (string-append "v" version))))
7533 (file-name (git-file-name name version))
7534 (sha256
7535 (base32 "0s30pcnlir3j2jmf7yh065f294cf3x0x5i3ldskn8mm0a3657mv3"))))
7536 (build-system pyproject-build-system)
7537 (propagated-inputs (list python-cryptography
7538 python-pyspnego
7539 python-requests))
7540 (native-inputs (list python-pytest python-pytest-mock python-setuptools
7541 python-wheel))
7542 (home-page "https://github.com/requests/requests-kerberos")
7543 (synopsis "Kerberos authentication handler for python-requests")
7544 (description "This package provides a Kerberos authentication handler for
7545python-requests.")
7546 (license license:isc)))
7547
7548(define-public python-requests-unixsocket2
7549 (package
7550 (name "python-requests-unixsocket2")
7551 (version "1.0.1")
7552 (source
7553 (origin
7554 (method git-fetch)
7555 (uri (git-reference
7556 (url "https://gitlab.com/thelabnyc/requests-unixsocket2")
7557 (commit (string-append "v" version))))
7558 (sha256
7559 (base32 "0wb8ckagal9d6lfyl3pf9m45xn1krq6vg8kzciwv12chq9wwh0ra"))))
7560 (build-system pyproject-build-system)
7561 (native-inputs
7562 (list nss-certs-for-test
7563 python-hatchling
7564 python-pytest
7565 python-waitress))
7566 (propagated-inputs
7567 (list python-requests
7568 python-urllib3))
7569 (home-page "https://gitlab.com/thelabnyc/requests-unixsocket2")
7570 (synopsis "Talk HTTP via a UNIX domain socket")
7571 (description
7572 "This Python package lets you use the @code{requests} library to talk
7573HTTP via a UNIX domain socket.")
7574 (license license:asl2.0)))
7575
7576(define-public python-requests-ntlm
7577 (package
7578 (name "python-requests-ntlm")
7579 (version "1.3.0")
7580 (source
7581 (origin
7582 (method git-fetch)
7583 (uri (git-reference
7584 (url "https://github.com/requests/requests-ntlm")
7585 (commit (string-append "v" version))))
7586 (file-name (git-file-name name version))
7587 (sha256
7588 (base32 "0snsk66zdihdlyfjz2zgpyfgdyjg814m3cc4g3my09hdnb5xvagv"))))
7589 (build-system pyproject-build-system)
7590 (arguments
7591 (list
7592 #:test-flags
7593 ;; XXX: Connection refused.
7594 #~(list "-k" (string-join
7595 (list "not test_ntlm_http_with_cbt"
7596 "test_ntlm_http_without_cbt"
7597 "test_ntlm_https_with_cbt"
7598 "test_ntlm_https_without_cbt")
7599 " and not "))
7600 #:phases
7601 #~(modify-phases %standard-phases
7602 (add-before 'check 'spawn-test-server
7603 (lambda _
7604 ;; Taken from .github/workflows/ci.yml.
7605 (spawn "python"
7606 (list "python" "-m" "tests.test_server")))))))
7607 (propagated-inputs
7608 (list python-cryptography python-pyspnego python-requests))
7609 (native-inputs (list python-flask python-pytest python-setuptools))
7610 (home-page "https://github.com/requests/requests-ntlm")
7611 (synopsis "NTLM authentication support for Requests")
7612 (description
7613 "This package allows for HTTP NTLM authentication using the requests
7614library.")
7615 (license license:isc)))
7616
7617(define-public python-requests-mock
7618 (package
7619 (name "python-requests-mock")
7620 (version "1.12.1")
7621 (source
7622 (origin
7623 (method url-fetch)
7624 (uri (pypi-uri "requests-mock" version))
7625 (sha256
7626 (base32 "008l6xysgs6ax56lairg1li5i4bb04i2z19w5bl5claj7crjxqg9"))))
7627 (build-system pyproject-build-system)
7628 (native-inputs
7629 (list python-purl
7630 python-pytest
7631 python-requests-futures
7632 python-setuptools
7633 python-setuptools-scm
7634 python-testtools))
7635 (propagated-inputs
7636 (list python-requests))
7637 (home-page "https://requests-mock.readthedocs.org/")
7638 (synopsis "Mock out responses from the requests package")
7639 (description
7640 "This module provides a building block to stub out the HTTP requests
7641portions of your testing code.")
7642 (license license:asl2.0)))
7643
7644(define-public python-requests-toolbelt
7645 (package
7646 (name "python-requests-toolbelt")
7647 (version "1.0.0")
7648 (source
7649 (origin
7650 (method url-fetch)
7651 (uri (pypi-uri "requests-toolbelt" version))
7652 (sha256
7653 (base32 "1ijvip427ki177ycrblcn1mfgsq7ixzpvqqfvidjn0a7s2is10bn"))))
7654 (build-system pyproject-build-system)
7655 (arguments
7656 (list
7657 #:test-flags
7658 ;; Requiring networking or fail due not valid certs: AttributeError:
7659 ;; 'MockHTTPResponse' object has no attribute 'close'
7660 #~(list "-k" (string-append "not test_dump_all"
7661 " and not test_dump_response"
7662 " and not test_prepared_request_override_base"
7663 " and not test_prepared_request_with_base"
7664 " and not test_request_override_base"
7665 " and not test_request_with_base"))))
7666 (native-inputs
7667 (list python-betamax
7668 python-mock
7669 python-pyopenssl
7670 python-pytest
7671 python-setuptools
7672 python-trustme
7673 python-wheel))
7674 (propagated-inputs
7675 (list python-requests))
7676 (synopsis "Extensions to python-requests")
7677 (description "This is a toolbelt of useful classes and functions to be used
7678with python-requests.")
7679 (home-page "https://github.com/requests/toolbelt/")
7680 (license license:asl2.0)))
7681
7682(define-public python-requests-ftp
7683 (package
7684 (name "python-requests-ftp")
7685 (version "0.3.1")
7686 (source
7687 (origin
7688 (method git-fetch)
7689 (uri (git-reference
7690 (url "https://github.com/Lukasa/requests-ftp")
7691 (commit (string-append "v" version))))
7692 (file-name (git-file-name name version))
7693 (sha256
7694 (base32 "1c7xbz2fxb12ldaw2pkfg5qd29g6slf4a2gavhqvz26cd1r82ny7"))))
7695 (build-system pyproject-build-system)
7696 (arguments
7697 ;; XXX: No connection adapters found.
7698 (list #:test-flags #~(list "--ignore=tests/test_ftp_proxy.py")))
7699 (native-inputs
7700 (list python-pyftpdlib python-pytest python-setuptools python-six))
7701 (propagated-inputs (list python-requests))
7702 (home-page "https://github.com/Lukasa/requests-ftp")
7703 (synopsis "FTP Transport Adapter for Requests")
7704 (description "Requests-FTP is an implementation of a simple FTP transport
7705adapter for use with the Requests library.")
7706 (license license:asl2.0)))
7707
7708(define-public python-aioftp
7709 (package
7710 (name "python-aioftp")
7711 (version "0.27.2")
7712 (source
7713 (origin
7714 (method git-fetch)
7715 (uri (git-reference
7716 (url "https://github.com/aio-libs/aioftp")
7717 (commit version)))
7718 (file-name (git-file-name name version))
7719 (sha256
7720 (base32 "1lshyac5zk1w4x7ygkim3726f8gbkvpvlyiqkn9cs6qjxhxn5bxc"))))
7721 (build-system pyproject-build-system)
7722 (arguments
7723 (list
7724 #:phases
7725 #~(modify-phases %standard-phases
7726 (add-after 'unpack 'use-default-asyncio
7727 ;; async_timeout is deprecated, upstream recommends to use
7728 ;; asyncio, available since Python 3.11.
7729 (lambda _
7730 (substitute* "tests/conftest.py"
7731 (("async_timeout") "asyncio")))))))
7732 (native-inputs
7733 (list python-pytest
7734 python-pytest-mock
7735 python-pytest-asyncio
7736 python-setuptools
7737 python-siosocks
7738 python-trustme))
7739 (home-page "https://aioftp.readthedocs.io/")
7740 (synopsis "FTP client/server for asyncio in Python")
7741 (description
7742 "FTP client and server for asyncio (Python 3) Library implementing FTP
7743protocol, both client and server for Python asyncio module.
7744
7745 Supported commands as client: USER, PASS, ACCT, PWD, CWD, CDUP, MKD, RMD,
7746 MLSD, MLST, RNFR, RNTO, DELE, STOR, APPE, RETR, TYPE, PASV, ABOR, QUIT,
7747 REST, LIST (as fallback).
7748
7749 Supported commands as server: USER, PASS, QUIT, PWD, CWD, CDUP, MKD, RMD,
7750 MLSD, LIST (non-standard), MLST, RNFR, RNTO, DELE, STOR, RETR,
7751 TYPE (\"I\" and \"A\"), PASV, ABOR, APPE, REST.")
7752 (license license:asl2.0)))
7753
7754(define-public python-mohawk
7755 (let ((commit "b7899166880e890f01cf2531b5686094ba08df8f")
7756 (revision "0"))
7757 (package
7758 (name "python-mohawk")
7759 (version (git-version "1.1.0" revision commit))
7760 (source
7761 (origin
7762 (method git-fetch)
7763 (uri (git-reference
7764 (url "https://github.com/kumar303/mohawk")
7765 (commit commit)))
7766 (file-name (git-file-name name version))
7767 (sha256
7768 (base32 "00y9fimcj851rk2770wqk61fac9pnxfnzca4fvsci57zw18i50m6"))
7769 (patches
7770 (search-patches "python-mohawk-pytest.patch"))))
7771 (build-system pyproject-build-system)
7772 (arguments
7773 (list #:test-flags #~(list "mohawk/tests.py")))
7774 (native-inputs (list python-pytest python-setuptools))
7775 (propagated-inputs (list python-six)) ;TODO: remove python-mohawk when
7776 ;python-six is removed?
7777 (home-page "https://github.com/kumar303/mohawk")
7778 (synopsis "Library for Hawk HTTP authorization")
7779 (description
7780 "Mohawk is an alternate Python implementation of the Hawk HTTP
7781authorization scheme.")
7782 (license license:bsd-3))))
7783
7784(define-public python-msal
7785 (package
7786 (name "python-msal")
7787 (version "1.34.0")
7788 (home-page
7789 "https://github.com/AzureAD/microsoft-authentication-library-for-python")
7790 (source
7791 (origin
7792 (method git-fetch)
7793 (uri (git-reference
7794 (url home-page)
7795 (commit version)))
7796 (file-name (git-file-name name version))
7797 (sha256
7798 (base32 "1xcyiv742ihnzypjw7syamnhqffdy6wsvvv0f5jcl3pap0apbk0z"))
7799 (patches (search-patches "python-msal-requests.patch"))))
7800 (build-system pyproject-build-system)
7801 (arguments
7802 (list
7803 #:test-flags
7804 #~(list
7805 "--ignore=tests/test_benchmark.py"
7806 ;; XXX: Ignoring cryptography version scheme tests.
7807 "-k"
7808 "not test_ceiling_should_be_latest_cryptography_version_plus_three"
7809 ;; XXX: These tests try to access the network.
7810 "--ignore=tests/test_application.py"
7811 "--ignore=tests/test_ccs.py"
7812 ;; XXX: These tests assume they are run on Windows.
7813 "--ignore=tests/test_mi.py")
7814 #:phases
7815 #~(modify-phases %standard-phases
7816 (add-after 'unpack 'set-cryptography-version
7817 (lambda _
7818 (substitute* "tests/test_cryptography.py"
7819 (("^latest_cryptography_version = @version@")
7820 (format #f "latest_cryptography_version = ~s"
7821 #$(package-version
7822 (this-package-input "python-cryptography")))))))
7823 (add-before 'check 'configure-tests
7824 (lambda* (#:key tests? #:allow-other-keys)
7825 (when tests?
7826 (setenv "TRAVIS_TAG" "1")))))))
7827 (native-inputs
7828 (list nss-certs-for-test python-mock python-pytest python-setuptools))
7829 (propagated-inputs (list python-cryptography python-pyjwt python-requests))
7830 (synopsis "Microsoft Authentication Library (MSAL) for Python")
7831 (description
7832 "The Microsoft Authentication Library for Python enables applications to
7833integrate with the Microsoft identity platform. It allows you to sign in
7834users or apps with Microsoft identities (Azure AD, Microsoft Accounts and
7835Azure AD B2C accounts) and obtain tokens to call Microsoft APIs such as
7836Microsoft Graph or your own APIs registered with the Microsoft identity
7837platform. It is built using industry standard OAuth2 and OpenID Connect
7838protocols.")
7839 (license license:expat)))
7840
7841(define-public oauth2ms
7842 (let ((commit "a1ef0cabfdea57e9309095954b90134604e21c08")
7843 (revision "0"))
7844 (package
7845 (name "oauth2ms")
7846 (version (git-version "0.0.0" revision commit))
7847 (source (origin
7848 (method git-fetch)
7849 (uri (git-reference
7850 (url "https://github.com/harishkrupo/oauth2ms")
7851 (commit commit)))
7852 (file-name (git-file-name name version))
7853 (sha256
7854 (base32
7855 "0dqi6n4npdrvb42r672n4sl1jl8z5lsk554fwiiihpj0faa9dx64"))))
7856 (build-system copy-build-system)
7857 (arguments
7858 (list #:install-plan #~`(("oauth2ms" "bin/oauth2ms")
7859 ("." #$(string-append "share/doc/" name "-"
7860 version "/")
7861 #:include-regexp ("\\.org$")))
7862 #:phases #~(modify-phases %standard-phases
7863 (add-after 'install 'wrap-pythonpath
7864 (lambda* (#:key inputs outputs #:allow-other-keys)
7865 (let ((path (getenv "GUIX_PYTHONPATH")))
7866 (wrap-program (string-append #$output
7867 "/bin/oauth2ms")
7868 `("GUIX_PYTHONPATH" ":" prefix
7869 (,path)))))))))
7870 (inputs (list bash-minimal python python-gnupg python-msal python-pyxdg))
7871 (home-page "https://github.com/harishkrupo/oauth2ms")
7872 (synopsis "XOAUTH2 compatible Microsoft Office 365 token fetcher")
7873 (description
7874 "Oauth2ms can be used to fetch OAuth 2.0 tokens from the Microsoft Identity
7875endpoint. Additionally, it can encode the token in the XOAUTH2 format to be
7876used as authentication in IMAP mail servers.")
7877 (license license:asl2.0))))
7878
7879(define-public python-oauthlib
7880 (package
7881 (name "python-oauthlib")
7882 (version "3.3.1")
7883 (source
7884 (origin
7885 (method git-fetch)
7886 (uri (git-reference
7887 (url "https://github.com/oauthlib/oauthlib")
7888 (commit (string-append "v" version))))
7889 (file-name (git-file-name name version))
7890 (sha256
7891 (base32 "0aa38lpa6s1k56v7w7kw2w4l159kaz4gn03m698a8hfdjkx92fb5"))))
7892 (build-system pyproject-build-system)
7893 (native-inputs (list python-pytest python-mock python-setuptools))
7894 (propagated-inputs (list python-cryptography python-pyjwt python-blinker))
7895 (home-page "https://github.com/oauthlib/oauthlib")
7896 (synopsis "OAuth implementation for Python")
7897 (description
7898 "Oauthlib is a generic, spec-compliant, thorough implementation of the
7899OAuth request-signing logic.")
7900 (license license:bsd-3)))
7901
7902(define-public python-urllib3
7903 (package
7904 (name "python-urllib3")
7905 (version "2.5.0")
7906 (source
7907 (origin
7908 (method url-fetch)
7909 (uri (pypi-uri "urllib3" version))
7910 (sha256
7911 (base32
7912 "0q17z6zlpyjv9ax5c3d30qwp9fwhz2sc4gbb7yyd86g4qwrpgi1z"))))
7913 (build-system pyproject-build-system)
7914 (arguments `(#:tests? #f))
7915 (native-inputs
7916 (list python-hatch-vcs
7917 python-hatchling
7918 python-setuptools-scm))
7919 (propagated-inputs
7920 (append
7921 ;; These 5 inputs are used to build urrlib3[secure]
7922 (list python-certifi)
7923 (if (member (%current-system)
7924 (package-transitive-supported-systems python-cryptography))
7925 (list python-cryptography)
7926 '())
7927 (list python-idna)
7928 (if (member (%current-system)
7929 (package-transitive-supported-systems python-pyopenssl))
7930 (list python-pyopenssl)
7931 '())
7932 (list python-pysocks)))
7933 (home-page "https://urllib3.readthedocs.io/")
7934 (synopsis "HTTP library with thread-safe connection pooling")
7935 (description
7936 "Urllib3 supports features left out of urllib and urllib2 libraries. It
7937can reuse the same socket connection for multiple requests, it can POST files,
7938supports url redirection and retries, and also gzip and deflate decoding.")
7939 (license license:expat)))
7940
7941(define-public python-urllib3-1.26
7942 (package
7943 (inherit python-urllib3)
7944 (version "1.26.17")
7945 (source
7946 (origin
7947 (method url-fetch)
7948 (uri (pypi-uri "urllib3" version))
7949 (sha256
7950 (base32
7951 "08fzhaf77kbjj5abpl9xag6fpfxkdp1k5s7sqd3ayacdq91a5mi4"))))
7952 (native-inputs
7953 (list python-setuptools
7954 python-wheel))))
7955
7956(define-public python-awscrt
7957 (package
7958 (name "python-awscrt")
7959 (version "0.26.1")
7960 (source
7961 (origin
7962 (method url-fetch)
7963 (uri (pypi-uri "awscrt" version))
7964 (sha256
7965 (base32 "0plkc0i0gc6z8fqnyy8kbg43sv3jnv8shcavcz0wb134riykmmm8"))))
7966 (build-system pyproject-build-system)
7967 (arguments
7968 (list
7969 #:test-backend #~'unittest
7970 #:test-flags #~(list "discover" "--verbose")
7971 #:phases
7972 #~(modify-phases %standard-phases
7973 (add-after 'unpack 'disable-broken-tests
7974 (lambda _
7975 ;; Disable broken tests. These tests fail because the
7976 ;; certificate bundle at the default location does not exist.
7977 (substitute* "test/test_auth.py"
7978 (("def test_default_provider")
7979 "def _test_default_provider"))
7980 (substitute* "test/test_http_client.py"
7981 (("def test_h2_client")
7982 "def _test_h2_client"))
7983 (substitute* "test/test_s3.py"
7984 (("def test_sanity")
7985 "def _test_sanity")
7986 (("def test_sanity_secure")
7987 "def _test_sanity_secure")
7988 (("def test_wait_shutdown")
7989 "def _test_wait_shutdown"))))
7990 (add-after 'unpack 'override-cert-bundle-location
7991 (lambda* (#:key inputs #:allow-other-keys)
7992 (let ((bundle (search-input-file inputs
7993 "/etc/ssl/certs/ca-certificates.crt")))
7994 (setenv "SSL_CERT_FILE" bundle)
7995 (substitute* "awscrt/io.py"
7996 (("( +)opt = TlsContextOptions\\(\\)" m indent)
7997 (string-append m "\n"
7998 indent "import os\n"
7999 indent "\
8000opt.override_default_trust_store_from_path(None, os.getenv('SSL_CERT_FILE')) if os.getenv('SSL_CERT_FILE') else None\n")))
8001 (substitute* "test/appexit_http.py"
8002 (("( +)tls_ctx_opt = awscrt.io.TlsContextOptions.*" m indent)
8003 (string-append m indent
8004 "tls_ctx_opt.override_default_trust_store_from_path(None, '"
8005 bundle "')\n")))
8006 (substitute* "test/test_io.py"
8007 (("( +)opt = TlsContextOptions\\(\\).*" m indent)
8008 (string-append m indent
8009 "opt.override_default_trust_store_from_path(None, '"
8010 bundle "')\n"))))))
8011 (add-after 'unpack 'use-system-libraries
8012 (lambda _
8013 (setenv "AWS_CRT_BUILD_USE_SYSTEM_LIBCRYPTO" "1"))))))
8014 (inputs (list openssl))
8015 (native-inputs (list cmake-minimal
8016 nss-certs-for-test
8017 python-boto3
8018 python-setuptools
8019 python-websockets))
8020 (home-page "https://github.com/awslabs/aws-crt-python")
8021 (synopsis "Common runtime for AWS Python projects")
8022 (description
8023 "This package provides a common runtime for AWS Python projects.")
8024 (license license:asl2.0)))
8025
8026(define-public awscli
8027 (package
8028 ;; Note: updating awscli typically requires updating botocore as well.
8029 (name "awscli")
8030 (version "1.43.11")
8031 (source
8032 (origin
8033 (method git-fetch)
8034 (uri (git-reference
8035 (url "https://github.com/aws/aws-cli")
8036 (commit version)))
8037 (file-name (git-file-name name version))
8038 (sha256
8039 (base32 "1idvcnc6jw7xr1jqpza472ksj3i2kyk0bv8wr7acz3xnba1v8xmi"))))
8040 (build-system pyproject-build-system)
8041 (arguments
8042 (list
8043 ;; tests: 2715 passed, 32 warnings
8044 #:test-flags
8045 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
8046 ;; Complete test suite is huge and compute hungry, run just unit
8047 ;; tests.
8048 "--ignore=tests/dependencies"
8049 "--ignore=tests/functional"
8050 "--ignore=tests/integration"
8051 ;; TypeError: 'Mock' object is not subscriptable.
8052 "-k" "not test_no_groff_or_mandoc_exists")
8053 #:phases
8054 #~(modify-phases %standard-phases
8055 (add-after 'unpack 'fix-reference-to-groff
8056 (lambda _
8057 ;; XXX: Consider to use wrap-program instead, it tries to parse
8058 ;; the PATH.
8059 (substitute* "awscli/help.py"
8060 (("if self._exists_on_path\\('groff'\\):") "if 'groff':")
8061 (("raise ExecutableNotFoundError\\('groff'\\)") "")
8062 (("cmdline = \\['groff'")
8063 (format #f "cmdline = ['~a/bin/groff'"
8064 #$(this-package-input "groff-minimal"))))))
8065 (add-before 'check 'set-environment
8066 (lambda _
8067 ;; PermissionError: [Errno 13] Permission denied:
8068 ;; '/homeless-shelter'
8069 (setenv "HOME" "/tmp"))))))
8070 (native-inputs
8071 (list python-pytest
8072 python-pytest-xdist
8073 python-setuptools
8074 python-wheel))
8075 (inputs
8076 (list groff-minimal
8077 python-botocore
8078 python-colorama
8079 python-docutils-0.19
8080 python-pyyaml
8081 python-rsa-for-awscli-1
8082 python-s3transfer))
8083 (home-page "https://aws.amazon.com/cli/")
8084 (synopsis "Command line client for AWS")
8085 (description
8086 "AWS CLI provides a unified command line interface to the Amazon Web
8087Services (AWS) API.")
8088 (license license:asl2.0)))
8089
8090(define-public awscli-2
8091 (package
8092 (inherit awscli)
8093 ;; Note: updating awscli-2 typically requires updating python-awscrt.
8094 (name "awscli")
8095 ;; Upstream practices a very rapid (1h-1d) release cycles try to select
8096 ;; any fresh one compatible with current state of dependencies in Guix.
8097 (version "2.28.0")
8098 (source
8099 (origin
8100 (method git-fetch)
8101 (uri (git-reference
8102 (url "https://github.com/aws/aws-cli")
8103 (commit version)))
8104 (file-name (git-file-name name version))
8105 (sha256
8106 (base32
8107 "1a1jzvdm434x46yh7ir11lw0nzc64ns4qvxhp5wfra3rh5ykf36j"))))
8108 (build-system pyproject-build-system)
8109 (arguments
8110 (list
8111 ;; When updating and checking locally be very patient as build phase may
8112 ;; hang for 6-8 minutes but eventually passes through.
8113 ;;
8114 ;; tests: 4189 passed, 1 skipped, 2 warnings
8115 #:test-flags
8116 '(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
8117 ;; Full test suite contains more than 70k tests; ignore network
8118 ;; dependent, slow and compute intense tests, keep just unit
8119 ;; tests.
8120 "--ignore=tests/backends"
8121 "--ignore=tests/dependencies"
8122 "--ignore=tests/functional"
8123 "--ignore=tests/integration"
8124 "--ignore=tests/unit/botocore"
8125 ;; Flaky, something to do with PATH disappearing from os.environ?
8126 ;; Passes when run on its own, so maybe something else is
8127 ;; modifying this during the test run.
8128 "--ignore=tests/unit/customizations/emr/test_emr_utils.py"
8129 ;; TypeError: 'Mock' object is not subscriptable
8130 "-k" "not test_no_groff_or_mandoc_exists")
8131 #:phases
8132 #~(modify-phases %standard-phases
8133 (add-after 'unpack 'ignore-deprecations
8134 (lambda _
8135 (substitute* "pyproject.toml"
8136 (("\"error::") "\"ignore::"))))
8137 (add-after 'unpack 'fix-reference-to-groff
8138 (lambda* (#:key inputs #:allow-other-keys)
8139 (substitute* "awscli/help.py"
8140 (("if self._exists_on_path\\('groff'\\):") "if True:")
8141 (("cmdline = \\['groff'")
8142 (string-append "cmdline = ['"
8143 (search-input-file inputs "bin/groff")
8144 "'")))))
8145 (add-before 'check 'pre-check
8146 (lambda _ (setenv "HOME" "/tmp"))))))
8147 (inputs
8148 (list groff
8149 ;; less
8150 nss-certs-for-test
8151 python-awscrt
8152 python-colorama
8153 python-dateutil
8154 python-distro
8155 python-docutils
8156 python-jmespath
8157 python-prompt-toolkit
8158 python-ruamel.yaml
8159 python-ruamel.yaml.clib
8160 python-urllib3))
8161 (native-inputs
8162 (list python-flit-core
8163 python-pytest
8164 python-pytest-xdist))))
8165
8166(define-public python-wsgiproxy2
8167 (package
8168 (name "python-wsgiproxy2")
8169 (version "0.5.1")
8170 (source
8171 (origin
8172 (method git-fetch)
8173 (uri (git-reference
8174 (url "https://github.com/gawel/WSGIProxy2/")
8175 (commit version)))
8176 (file-name (git-file-name name version))
8177 (sha256
8178 (base32 "0aw9ibla2cqzlbm3vzyk1yk3d8pccpbpdkqx99q30hq1fz1izsm2"))))
8179 (build-system pyproject-build-system)
8180 (arguments (list #:test-backend #~'unittest))
8181 (native-inputs (list python-webtest python-setuptools))
8182 (propagated-inputs (list python-requests python-six python-urllib3
8183 python-webob))
8184 (home-page "https://github.com/gawel/WSGIProxy2/")
8185 (synopsis "WSGI Proxy with various http client backends")
8186 (description
8187 "WSGI turns HTTP requests into WSGI function calls. WSGIProxy turns WSGI
8188function calls into HTTP requests. It also includes code to sign requests and
8189pass private data, and to spawn subprocesses to handle requests.")
8190 (license license:expat)))
8191
8192(define-public python-pastedeploy
8193 (package
8194 (name "python-pastedeploy")
8195 (version "3.1.0")
8196 (source
8197 (origin
8198 (method url-fetch)
8199 (uri (pypi-uri "PasteDeploy" version))
8200 (sha256
8201 (base32 "15as15mgz9xn33abwrp0x0mbj537ib3q47z8ky5475c05wasznwx"))))
8202 (build-system pyproject-build-system)
8203 (native-inputs (list python-pytest python-setuptools))
8204 (home-page "https://pylonsproject.org/")
8205 (synopsis "Load, configure, and compose WSGI applications and servers")
8206 (description
8207 "This tool provides code to load WSGI applications and servers from URIs;
8208these URIs can refer to Python Eggs for INI-style configuration files. Paste
8209Script provides commands to serve applications based on this configuration
8210file.")
8211 (license license:expat)))
8212
8213(define-public python-webtest
8214 (package
8215 (name "python-webtest")
8216 (version "3.0.6")
8217 (source
8218 (origin
8219 (method url-fetch)
8220 (uri (pypi-uri "webtest" version))
8221 (sha256
8222 (base32 "0jwl8i9xvm5xim1h2jrwfbqac1g3fpiazfdwfp2md3s4899gsmj2"))))
8223 (build-system pyproject-build-system)
8224 (arguments
8225 ;; Tests require python-pyquery, which creates a circular dependency.
8226 `(#:tests? #f))
8227 (native-inputs
8228 (list python-setuptools))
8229 (propagated-inputs
8230 (list python-beautifulsoup4
8231 python-waitress
8232 python-webob))
8233 (home-page "https://docs.pylonsproject.org/projects/webtest/")
8234 (synopsis "Helper to test WSGI applications")
8235 (description
8236 "Webtest allows you to test your Python web applications without
8237starting an HTTP server. It supports anything that supports the minimum of
8238WSGI.")
8239 (license license:expat)))
8240
8241(define-public python-flask
8242 (package
8243 (name "python-flask")
8244 (version "3.1.0")
8245 (source
8246 (origin
8247 (method url-fetch)
8248 (uri (pypi-uri "flask" version))
8249 (sha256
8250 (base32 "1b1nb250jxrjplbs21wnwq69250vs3iz2pdhs7cwi5y8hi8kr1sz"))))
8251 (build-system pyproject-build-system)
8252 (native-inputs
8253 (list python-flit-core
8254 python-pytest))
8255 (propagated-inputs
8256 (list python-asgiref ;async extra
8257 python-click
8258 python-blinker
8259 python-itsdangerous
8260 python-jinja2
8261 python-werkzeug))
8262 (home-page "https://palletsprojects.com/p/flask/")
8263 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
8264 (description "Flask is a micro web framework based on the Werkzeug toolkit
8265and Jinja2 template engine. It is called a micro framework because it does not
8266presume or force a developer to use a particular tool or library.")
8267 (license license:bsd-3)))
8268
8269(define-public python-flask-compress
8270 (package
8271 (name "python-flask-compress")
8272 (version "1.18")
8273 (source (origin
8274 (method url-fetch)
8275 (uri (pypi-uri "flask_compress" version))
8276 (sha256
8277 (base32
8278 "0fj1r0ixsjls7z3a2zzamxppjz4qcf8q4jcmn74gsk9kisyy3fpx"))))
8279 (build-system pyproject-build-system)
8280 (native-inputs
8281 (list python-flask-caching
8282 python-pytest
8283 python-setuptools
8284 python-setuptools-scm))
8285 (propagated-inputs
8286 (list python-brotli
8287 python-flask
8288 python-pyzstd))
8289 (home-page "https://github.com/colour-science/flask-compress")
8290 (synopsis "Compress responses in a Flask app")
8291 (description
8292 "This package lets you compress Flask application responses and static
8293files with gzip, deflate or brotli. Flask-Compress both adds the various
8294headers required for a compressed response and compresses the response data.")
8295 (license license:expat)))
8296
8297(define-public python-flask-seasurf
8298 (package
8299 (name "python-flask-seasurf")
8300 (version "2.0.0")
8301 (source (origin
8302 (method url-fetch)
8303 (uri (pypi-uri "Flask-SeaSurf" version))
8304 (sha256
8305 (base32
8306 "0g5dsm2ikv8q4qcrb2446pbs972l5wkxyfmxsriqdsl02nz06h4f"))))
8307 (build-system pyproject-build-system)
8308 (arguments
8309 (list #:tests? #false)) ;there are none
8310 (propagated-inputs (list python-flask))
8311 (native-inputs (list python-setuptools python-wheel))
8312 (home-page "https://github.com/maxcountryman/flask-seasurf/")
8313 (synopsis "CSRF extension for Flask")
8314 (description "SeaSurf is a Flask extension for preventing cross-site
8315request forgery (CSRF). CSRF attacks are problematic because the mechanism
8316they use is relatively easy to exploit. This extension attempts to aid you in
8317securing your application from such attacks. This extension is based on the
8318Django middleware.")
8319 (license license:bsd-3)))
8320
8321(define-public python-flask-wtf
8322 (package
8323 (name "python-flask-wtf")
8324 (version "1.2.2")
8325 (source
8326 (origin
8327 (method url-fetch)
8328 (uri (pypi-uri "Flask-WTF" version))
8329 (sha256
8330 (base32
8331 "0sv6hjva1fdizb7sr46230pplx8qz8rnb4bxrfy71xbc8cgfxlkr"))))
8332 (build-system pyproject-build-system)
8333 (propagated-inputs
8334 (list python-flask python-flask python-itsdangerous python-wtforms))
8335 (native-inputs
8336 (list python-hatchling python-pytest))
8337 (home-page "https://github.com/lepture/flask-wtf")
8338 (synopsis "Simple integration of Flask and WTForms")
8339 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
8340upload, and reCAPTCHA.")
8341 (license license:bsd-3)))
8342
8343(define-public python-flask-multistatic
8344 (package
8345 (name "python-flask-multistatic")
8346 (version "1.0")
8347 (source
8348 (origin
8349 (method url-fetch)
8350 (uri (pypi-uri "flask-multistatic" version))
8351 (sha256
8352 (base32
8353 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
8354 (build-system pyproject-build-system)
8355 (arguments (list #:tests? #f)) ; No tests upstream.
8356 (native-inputs (list python-setuptools))
8357 (propagated-inputs (list python-flask))
8358 (home-page "https://pagure.io/flask-multistatic")
8359 (synopsis "Flask plugin to allow overriding static files")
8360 (description "@code{flask-multistatic} is a flask plugin that adds support
8361for overriding static files.")
8362 (license license:gpl3+)))
8363
8364(define-public python-responses
8365 (package
8366 (name "python-responses")
8367 (version "0.25.3")
8368 (source (origin
8369 (method url-fetch)
8370 (uri (pypi-uri "responses" version))
8371 (sha256
8372 (base32
8373 "1fld6lsa143md4lxccwxq9iyqm9d8a05i9sp7lqjibnrmd3r4yv1"))))
8374 (build-system pyproject-build-system)
8375 (native-inputs
8376 (list python-pytest
8377 python-pytest-asyncio
8378 python-pytest-httpserver
8379 python-setuptools
8380 python-tomli
8381 python-tomli-w
8382 python-wheel))
8383 (propagated-inputs
8384 (list python-requests
8385 python-pyyaml
8386 python-urllib3))
8387 (home-page "https://github.com/getsentry/responses")
8388 (synopsis "Utility for mocking out the `requests` Python library")
8389 (description "A utility library for mocking out the `requests` Python
8390library.")
8391 (license license:asl2.0)))
8392
8393(define-public python-grequests
8394 (let ((commit "60f70e99e942a2df378b4e4f6202dcf862754c2d")
8395 (revision "0"))
8396 (package
8397 (name "python-grequests")
8398 (version (git-version "0.7.0" revision commit))
8399 (source
8400 (origin
8401 (method git-fetch)
8402 (uri (git-reference
8403 (url "https://github.com/kennethreitz/grequests")
8404 (commit commit)))
8405 (file-name (git-file-name name version))
8406 (sha256
8407 (base32 "0132yv1rr4pmrmwasrnasqbnd80pi6rgy52608731p7lidkmxz9a"))))
8408 (build-system pyproject-build-system)
8409 (arguments
8410 (list
8411 ;; XXX: Most failing tests seem to be caused by network access,
8412 ;; but there is no easy/flag way to disable tests selectively.
8413 #:tests? #f
8414 #:test-backend #~'unittest
8415 #:test-flags #~(list "tests.py")))
8416 (propagated-inputs (list python-gevent python-requests))
8417 (native-inputs (list python-setuptools))
8418 (home-page "https://github.com/kennethreitz/grequests")
8419 (synopsis "Python library for asynchronous HTTP requests")
8420 (description
8421 "GRequests is a Python library that allows you to use @code{Requests}
8422with @code{Gevent} to make asynchronous HTTP Requests easily.")
8423 (license license:bsd-2))))
8424
8425(define-public python-gwebsockets
8426 (package
8427 (name "python-gwebsockets")
8428 (version "0.7")
8429 (source
8430 (origin
8431 (method git-fetch)
8432 (uri (git-reference
8433 (url "https://github.com/sugarlabs/gwebsockets")
8434 (commit (string-append "v" version))))
8435 (file-name (git-file-name name version))
8436 (sha256
8437 (base32 "0w422yz0qdix5xb6aqrrci1s1hy4whncspwb03m9ankqww0s1yv2"))))
8438 (build-system pyproject-build-system)
8439 (arguments (list #:tests? #f)) ; No tests upstream.
8440 (native-inputs (list python-setuptools))
8441 (propagated-inputs (list python-pygobject))
8442 (home-page "https://github.com/sugarlabs/gwebsockets")
8443 (synopsis "GLib based websockets server")
8444 (description
8445 "This package provides a websocket server written in Python. It uses GIO
8446for network communication and hence it easily integrates with the GLib
8447mainloop.")
8448 (license license:asl2.0)))
8449
8450(define-public python-dpkt
8451 (package
8452 (name "python-dpkt")
8453 (version "1.9.8")
8454 (source
8455 (origin
8456 (method git-fetch)
8457 (uri (git-reference
8458 (url "https://github.com/kbandla/dpkt")
8459 (commit (string-append "v" version))))
8460 (file-name (git-file-name name version))
8461 (sha256
8462 (base32 "0dhy8l4sqfxqdda6lishb95g3v6hnw14l20ipqpzb6vaw1vf7mzj"))))
8463 (build-system pyproject-build-system)
8464 (arguments
8465 (list
8466 #:test-flags
8467 #~(list "--pyargs" "dpkt")))
8468 (native-inputs (list python-pytest python-setuptools))
8469 (home-page "https://github.com/kbandla/dpkt")
8470 (synopsis "Packet generator and parser for TCP/IP protocols")
8471 (description
8472 "The dpkt module is a fast, simple packet generator and parser for the
8473basic TCP/IP protocols.")
8474 (license license:bsd-3)))
8475
8476(define-public python-geventhttpclient
8477 (package
8478 (name "python-geventhttpclient")
8479 (version "2.3.9")
8480 (source (origin
8481 (method git-fetch)
8482 (uri (git-reference
8483 (url "https://github.com/geventhttpclient/geventhttpclient")
8484 (commit version)
8485 (recursive? #true)))
8486 (file-name (git-file-name name version))
8487 (sha256
8488 (base32
8489 "1diq6n9sr92rsqbpxlbhbn1d22hrlzp6swykz9bfzh7sxpywa6j8"))))
8490 (build-system pyproject-build-system)
8491 (arguments
8492 (list
8493 #:test-flags
8494 ;; Disable network tests.
8495 '(list "-k"
8496 (string-append "not test_client_simple"
8497 " and not test_client_ssl"
8498 " and not test_client_with_default_headers"
8499 " and not test_client_without_leading_slash"
8500 " and not test_download"
8501 " and not test_fail_invalid_ca_certificate"
8502 " and not test_httpbin_multipart"
8503 " and not test_multi_queries_greenlet_safe"
8504 " and not test_no_form_encode_header"
8505 " and not test_no_form_encoded_header"
8506 " and not test_request_with_headers"
8507 " and not test_response_context_manager"
8508 " and not test_urllib_request"))))
8509 (native-inputs (list nss-certs-for-test
8510 python-dpkt python-pytest python-requests
8511 python-setuptools python-wheel))
8512 (propagated-inputs (list python-brotli python-certifi python-gevent
8513 python-urllib3))
8514 (home-page "https://github.com/geventhttpclient/geventhttpclient")
8515 (synopsis "HTTP client library for gevent")
8516 (description "@code{python-geventhttpclient} is a high performance,
8517concurrent HTTP client library for python using @code{gevent}.")
8518 (license license:expat)))
8519
8520(define-public python-gevent-websocket
8521 (package
8522 (name "python-gevent-websocket")
8523 (version "0.10.1")
8524 (source
8525 (origin
8526 (method url-fetch)
8527 (uri (pypi-uri "gevent-websocket" version))
8528 (sha256
8529 (base32 "1c2zv2rahp1gil3cj66hfsqgy0n35hz9fny3ywhr2319d0lz7bky"))))
8530 (build-system pyproject-build-system)
8531 (arguments
8532 (list #:tests? #f)) ; no tests in PyPI or git
8533 (native-inputs
8534 (list python-setuptools
8535 python-wheel))
8536 (propagated-inputs
8537 (list python-gevent))
8538 (home-page "https://gitlab.com/noppo/gevent-websocket")
8539 (synopsis "Websocket handler for the gevent pywsgi server")
8540 (description
8541 "Websocket handler for the gevent pywsgi server, a Python network
8542library.
8543
8544Features include:
8545@itemize
8546@item integration on both socket level or using an abstract interface
8547@item RPC and PubSub framework using @acronym{WebSocket Application Messaging
8548Protocol, WAMP}
8549@item easily extendible using a simple WebSocket protocol plugin API
8550@end itemize")
8551 (license license:asl2.0)))
8552
8553(define-public python-requests-oauthlib
8554 (package
8555 (name "python-requests-oauthlib")
8556 (version "2.0.0")
8557 (source
8558 (origin
8559 (method git-fetch)
8560 (uri (git-reference (url
8561 "https://github.com/requests/requests-oauthlib")
8562 (commit (string-append "v" version))))
8563 (file-name (git-file-name name version))
8564 (sha256 (base32 "0i0vnanxqilnf2rgng7n96rl8fzq0dbcl3rpl7zkxj50kv66nqwl"))))
8565 (build-system pyproject-build-system)
8566 (arguments
8567 (list
8568 #:test-flags
8569 #~(list
8570 "--ignore=tests/test_core.py" ; requires network access.
8571 "--ignore=tests/examples/test_native_spa_pkce_auth0.py"
8572 "-k" "not test_fetch_access_token"))) ; flaky tests.
8573 (native-inputs
8574 (list python-requests-mock python-pytest python-setuptools))
8575 (propagated-inputs
8576 (list python-oauthlib python-requests))
8577 (home-page "https://github.com/requests/requests-oauthlib")
8578 (synopsis "OAuthlib authentication support for Requests")
8579 (description
8580 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
8581provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
8582 (license license:isc)))
8583
8584(define-public python-cachecontrol
8585 (package
8586 (name "python-cachecontrol")
8587 (version "0.14.1")
8588 (source
8589 (origin
8590 (method git-fetch)
8591 (uri (git-reference
8592 (url "https://github.com/ionrock/cachecontrol")
8593 (commit (string-append "v" version))))
8594 (file-name (git-file-name name version))
8595 (sha256
8596 (base32
8597 "07ifs4dhahhsgj4vxgfl5ymnmb4my5l2wb8jiinn6fncszcfmr59"))))
8598 (build-system pyproject-build-system)
8599 (propagated-inputs
8600 (list python-filelock python-msgpack python-requests))
8601 (native-inputs
8602 (list python-cherrypy python-flit-core python-pytest))
8603 (home-page "https://github.com/ionrock/cachecontrol")
8604 (synopsis "The httplib2 caching algorithms for use with requests")
8605 (description "CacheControl is a port of the caching algorithms in
8606@code{httplib2} for use with @code{requests} session objects.")
8607 (license license:asl2.0)))
8608
8609(define-public python-betamax
8610 (package
8611 (name "python-betamax")
8612 (version "0.9.0")
8613 (source
8614 (origin
8615 (method url-fetch)
8616 (uri (pypi-uri "betamax" version))
8617 (sha256
8618 (base32
8619 "152zil1j4gl1whnldi08zwjr4z2bnlbd061kr3ipjs5wg4b6wcc2"))))
8620 (build-system pyproject-build-system)
8621 (arguments
8622 (list
8623 #:test-flags
8624 #~(list "-k" (string-join
8625 ;; Tests require network access to http://httpbin.org/get.
8626 (list "not test_creates_new_cassettes"
8627 "test_placeholders_work"
8628 "test_post_start_hook"
8629 "test_pre_stop_hook"
8630 "test_preplayback_hook"
8631 "test_prerecord_hook"
8632 "test_prerecord_ignoring_hook"
8633 "test_records_new_events_with_existing_cassette"
8634 "test_records_new_interaction"
8635 "test_records_new_interactions"
8636 "test_replaces_old_interactions"
8637 "test_replays_response_from_cassette"
8638 "test_requests_with_json_body"
8639 "test_saves_content_as_gzip"
8640 "test_unicode_is_saved_properly")
8641 " and not "))))
8642 (native-inputs
8643 (list nss-certs-for-test
8644 python-pytest
8645 python-setuptools))
8646 (propagated-inputs
8647 (list python-requests))
8648 (home-page "https://github.com/sigmavirus24/betamax")
8649 (synopsis "Record HTTP interactions with python-requests")
8650 (description
8651 "Betamax will record your test suite's HTTP interactions and replay them
8652during future tests. It is designed to work with python-requests.")
8653 (license license:expat)))
8654
8655(define-public python-betamax-matchers
8656 (package
8657 (name "python-betamax-matchers")
8658 (version "0.4.0")
8659 (source
8660 (origin
8661 (method git-fetch)
8662 (uri (git-reference
8663 (url "https://github.com/sigmavirus24/betamax_matchers")
8664 (commit version)))
8665 (file-name (git-file-name name version))
8666 (sha256
8667 (base32 "0lyg3r91hwfvavyi5k6sddcla37igigycfv1mx40c32byqwl6pq5"))))
8668 (build-system pyproject-build-system)
8669 (native-inputs (list python-pytest python-setuptools))
8670 (propagated-inputs (list python-betamax python-requests-toolbelt))
8671 (home-page "https://github.com/sigmavirus24/betamax_matchers")
8672 (synopsis "VCR imitation for python-requests")
8673 (description "@code{betamax-matchers} provides a set of Matchers for
8674Betamax.")
8675 (license license:asl2.0)))
8676
8677(define-public python-betamax-serializers
8678 (package
8679 (name "python-betamax-serializers")
8680 (version "0.2.1")
8681 (source
8682 (origin
8683 (method git-fetch)
8684 (uri (git-reference
8685 (url "https://gitlab.com/betamax/serializers")
8686 (commit version)))
8687 (file-name (git-file-name name version))
8688 (sha256
8689 (base32 "1p2l5w3vwvjacs2ndahgcjq55qb53i37p8mz1zh85pjxyszdyw2l"))))
8690 (build-system pyproject-build-system)
8691 (arguments (list #:tests? #f)) ; No tests.
8692 (native-inputs (list python-setuptools))
8693 (propagated-inputs (list python-betamax python-pyyaml))
8694 (synopsis "Set of third-party serializers for Betamax")
8695 (description
8696 "Betamax-Serializers are an experimental set of Serializers for Betamax
8697that may possibly end up in the main package.")
8698 (home-page "https://gitlab.com/betamax/serializers")
8699 (license license:asl2.0)))
8700
8701(define-public python-s3fs
8702 (package
8703 (name "python-s3fs")
8704 (version "2026.1.0")
8705 (source
8706 (origin
8707 (method url-fetch)
8708 (uri (pypi-uri "s3fs" version))
8709 (sha256
8710 (base32 "17fhx4qnpcwhrfckn27wdjvlxink1kcpaiganxij4fjmp7gm58xp"))))
8711 (build-system pyproject-build-system)
8712 ;; TODO: Many tests fail with "No such file or directory" raised by the
8713 ;; HTTP client.
8714 (arguments (list #:tests? #false))
8715 (native-inputs
8716 (list python-setuptools))
8717 (propagated-inputs
8718 (list python-aiobotocore
8719 python-aiohttp
8720 python-fsspec))
8721 (home-page "https://github.com/fsspec/s3fs/")
8722 (synopsis "Convenient filesystem interface over S3")
8723 (description "This package provides a convenient filesystem interface over
8724S3.")
8725 (license license:bsd-3)))
8726
8727(define-public python-s3transfer
8728 (package
8729 (name "python-s3transfer")
8730 (version "0.16.0")
8731 (source
8732 (origin
8733 (method url-fetch)
8734 (uri (pypi-uri "s3transfer" version))
8735 (sha256
8736 (base32 "087rmdwsn9drkh5rwwbfym5p8qvirc8gllnd54i7j9c04q9hz6cf"))))
8737 (build-system pyproject-build-system)
8738 (arguments
8739 (list
8740 ;; tests: 630 passed, 51 skipped
8741 #:test-flags
8742 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
8743 ;; Tests require networking.
8744 "--ignore" "tests/integration")))
8745 (native-inputs
8746 (list python-pytest
8747 python-pytest-xdist
8748 python-setuptools))
8749 (propagated-inputs
8750 (list python-botocore))
8751 (home-page "https://github.com/boto/s3transfer")
8752 (synopsis "Amazon S3 Transfer Manager")
8753 (description
8754 "S3transfer is a Python library for managing Amazon S3 transfers.")
8755 (license license:asl2.0)))
8756
8757(define-public python-flask-restful
8758 (package
8759 (name "python-flask-restful")
8760 (version "0.3.10")
8761 (source
8762 (origin
8763 (method url-fetch)
8764 (uri (pypi-uri "Flask-RESTful" version))
8765 (sha256
8766 (base32
8767 "0dzckjjz3aw8nmisr5g9mnv02s2nqlhblykr9ydqzpr703pz4jpy"))))
8768 (build-system pyproject-build-system)
8769 (arguments
8770 ;; See <https://github.com/flask-restful/flask-restful/issues/980>.
8771 (list #:tests? #f))
8772 (propagated-inputs
8773 (list python-aniso8601 python-flask python-pytz))
8774 (native-inputs
8775 (list python-blinker
8776 python-mock
8777 python-pytest
8778 python-setuptools
8779 python-wheel))
8780 (home-page "https://github.com/flask-restful/flask-restful/")
8781 (synopsis "Flask module for creating REST APIs")
8782 (description
8783 "This package contains a Flask module for creating REST APIs.")
8784 (license license:bsd-3)))
8785
8786(define-public python-flask-sqlalchemy
8787 (package
8788 (name "python-flask-sqlalchemy")
8789 ;; Released version fails tests in Python 3.12.
8790 (properties '((commit . "168cb4b7b50fe5176307a10d873781bfafc6eeda")
8791 (revision . "0")))
8792 (version (git-version "3.1.1"
8793 (assoc-ref properties 'revision)
8794 (assoc-ref properties 'commit)))
8795 (source
8796 (origin
8797 (method git-fetch)
8798 (uri (git-reference
8799 (url "https://github.com/pallets-eco/flask-sqlalchemy")
8800 (commit (assoc-ref properties 'commit))))
8801 (file-name (git-file-name name version))
8802 (sha256
8803 (base32
8804 "0xw8v1540m21x9crpgb0i3rxyhh1d24ldg354vndw9cif74ls5p6"))))
8805 (build-system pyproject-build-system)
8806 (arguments
8807 (list
8808 #:test-flags
8809 #~(list "-k" (string-append "not test_explicit_table[db2]"
8810 " and not test_explicit_table[db4]")
8811 "-W" "ignore::DeprecationWarning")))
8812 (native-inputs
8813 (list python-flit-core
8814 python-pytest))
8815 (propagated-inputs
8816 (list python-flask
8817 python-sqlalchemy-2))
8818 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
8819 (synopsis "Module adding SQLAlchemy support to your Flask application")
8820 (description
8821 "This package adds SQLAlchemy support to your Flask application.")
8822 (license license:bsd-3)))
8823
8824(define-public python-flask-restful-swagger
8825 (package
8826 (name "python-flask-restful-swagger")
8827 (version "0.20.1")
8828 ;; XXX: Unbundle minified javascript.
8829 (source
8830 (origin
8831 (method git-fetch)
8832 (uri (git-reference
8833 (url "https://github.com/rantav/flask-restful-swagger")
8834 (commit version)))
8835 (file-name (git-file-name name version))
8836 (sha256
8837 (base32 "1ppdwn25ijf8b3zchxkvwj4ipc68v3p522i8mm51jm0w6mg5bvsh"))))
8838 (build-system pyproject-build-system)
8839 (arguments (list #:tests? #f)) ; No tests.
8840 (native-inputs (list python-setuptools))
8841 (propagated-inputs (list python-flask-restful python-six))
8842 (home-page "https://github.com/rantav/flask-restful-swagger")
8843 (synopsis "Extract Swagger specs from Flask-Restful projects")
8844 (description "This package lets you extract Swagger API documentation
8845specs from your Flask-Restful projects.")
8846 (license license:expat)))
8847
8848(define-public python-htmlmin
8849 (package
8850 (name "python-htmlmin")
8851 (version "0.1.12")
8852 (source
8853 (origin
8854 (method url-fetch)
8855 (uri (pypi-uri "htmlmin" version))
8856 (sha256
8857 (base32
8858 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
8859 (build-system pyproject-build-system)
8860 (arguments
8861 (list #:tests? #f)) ; no tests
8862 (native-inputs (list python-setuptools))
8863 (home-page "https://htmlmin.readthedocs.org/en/latest/")
8864 (synopsis "HTML minifier")
8865 (description "@code{htmlmin} is an HTML minifier that just works.
8866It comes with safe defaults and easily configurable options.")
8867 (license license:bsd-3)))
8868
8869;; XXX: Forked renamed and updated version.
8870(define-public python-htmlmin2
8871 (package/inherit python-htmlmin
8872 (name "python-htmlmin2")
8873 (version "0.1.13")
8874 (source
8875 (origin
8876 (method git-fetch)
8877 (uri (git-reference
8878 (url "https://github.com/wilhelmer/htmlmin")
8879 (commit (string-append "v" version))))
8880 (file-name (git-file-name name version))
8881 (sha256
8882 (base32 "1y7mcx8d451hwa1wrg2lffg7ccdy3w5m7xwb5xqp8h2852pypfh2"))))
8883 (build-system pyproject-build-system)
8884 (arguments (list #:test-backend #~'unittest))
8885 (native-inputs (list python-setuptools))
8886 (home-page "https://github.com/wilhelmer/htmlmin")
8887 (description
8888 "@code{htmlmin2} is an HTML minifier that just works. It comes with safe
8889defaults and easily configurable options. This variant is an updated fork of
8890the original @code{python-htmlmin}.")
8891 (license license:bsd-3)))
8892
8893(define-public python-flask-htmlmin
8894 (package
8895 (name "python-flask-htmlmin")
8896 (version "3.0.0")
8897 (source
8898 (origin
8899 (method git-fetch)
8900 (uri (git-reference
8901 (url "https://github.com/hamidfzm/Flask-HTMLmin")
8902 (commit (string-append "v" version))))
8903 (file-name (git-file-name name version))
8904 (sha256
8905 (base32 "0ybqssnqwa9zgv61azp5r1grgnq28ypfhr80p9rp61x2z0y0zl32"))))
8906 (build-system pyproject-build-system)
8907 (native-inputs (list python-pytest python-setuptools))
8908 (propagated-inputs (list python-cssmin python-flask python-htmlmin2))
8909 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
8910 (synopsis "HTML response minifier for Flask")
8911 (description
8912 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
8913 (license license:bsd-3)))
8914
8915(define-public python-jsmin
8916 (package
8917 (name "python-jsmin")
8918 (version "3.0.1")
8919 (source
8920 (origin
8921 (method url-fetch)
8922 (uri (pypi-uri "jsmin" version))
8923 (sha256
8924 (base32
8925 "1z1brjsvni0260bypldkl8a05sgp0qk18x560zl44igr3q99m5f0"))))
8926 (build-system pyproject-build-system)
8927 (arguments (list #:test-backend #~'unittest))
8928 (native-inputs
8929 (list python-setuptools))
8930 (home-page "https://github.com/tikitu/jsmin/")
8931 (synopsis "Python JavaScript minifier")
8932 (description
8933 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
8934on the command line.")
8935 (license license:expat)))
8936
8937(define-public python-flask-login
8938 (let ((commit "c8bba84b9ba6768e878317fc46c54bd13fa1ac07")
8939 (revision "0"))
8940 (package
8941 (name "python-flask-login")
8942 (version (git-version "0.6.3" revision commit))
8943 (source
8944 (origin
8945 (method git-fetch)
8946 (uri (git-reference
8947 (url "https://github.com/maxcountryman/flask-login")
8948 (commit commit)))
8949 (file-name (git-file-name name version))
8950 (sha256
8951 (base32 "0q0ga1zwm06kvpnsf50ckmsc77959i1spx7z2y3jkbwaa4klsyli"))))
8952 (build-system pyproject-build-system)
8953 (propagated-inputs
8954 (list python-flask))
8955 (native-inputs
8956 ;; For tests.
8957 (list python-blinker
8958 python-flit-core
8959 python-mock
8960 python-pytest
8961 python-semantic-version
8962 python-werkzeug))
8963 (home-page "https://github.com/maxcountryman/flask-login")
8964 (synopsis "User session management for Flask")
8965 (description
8966 "@code{Flask-Login} provides user session management for Flask. It
8967handles the common tasks of logging in, logging out, and remembering your
8968users' sessions over extended periods of time.")
8969 (license license:expat))))
8970
8971(define-public python-oauth2client
8972 (package
8973 (name "python-oauth2client")
8974 (version "4.1.3")
8975 (source
8976 (origin
8977 (method git-fetch)
8978 (uri (git-reference
8979 (url "https://github.com/google/oauth2client/")
8980 (commit (string-append "v" version))))
8981 (file-name (git-file-name name version))
8982 (sha256
8983 (base32 "0xm19dv5kmi82zzrx3d4mp326irr3x37q818hlspz514dzjq2ad1"))))
8984 (build-system pyproject-build-system)
8985 (arguments
8986 (list #:tests? #f))
8987 (native-inputs
8988 (list python-setuptools))
8989 (propagated-inputs
8990 (list python-httplib2
8991 python-pyasn1
8992 python-pyasn1-modules
8993 python-pyparsing
8994 python-rsa
8995 python-six))
8996 (home-page "https://github.com/google/oauth2client/")
8997 (synopsis "OAuth 2.0 client library")
8998 (description "@code{python-oauth2client} provides an OAuth 2.0 client
8999library for Python")
9000 (license license:asl2.0)))
9001
9002(define-public python-authlib
9003 (package
9004 (name "python-authlib")
9005 (version "1.5.1")
9006 (source
9007 (origin
9008 (method url-fetch)
9009 (uri (pypi-uri "authlib" version))
9010 (sha256
9011 (base32 "0blpvz2v2r8yvsgm1yr3n61mhwxvh1b0kyf2rp0i4wv6n3n8bg2w"))))
9012 (build-system pyproject-build-system)
9013 ;; No tests target.
9014 (arguments (list #:tests? #false))
9015 (propagated-inputs
9016 (list python-cryptography
9017 python-django
9018 python-flask
9019 python-httpx
9020 python-requests
9021 python-sqlalchemy-2
9022 python-starlette
9023 python-werkzeug))
9024 (native-inputs (list python-pytest python-setuptools python-wheel))
9025 (home-page "https://pypi.org/project/Authlib/1")
9026 (synopsis "Build OAuth and OpenID Connect servers and clients")
9027 (description
9028 "This is a Python library for building OAuth and OpenID Connect servers
9029and clients.")
9030 (license license:bsd-3)))
9031
9032(define-public python-flask-oidc
9033 (package
9034 (name "python-flask-oidc")
9035 (version "2.3.1")
9036 (source
9037 (origin
9038 (method url-fetch)
9039 (uri (pypi-uri "flask_oidc" version))
9040 (sha256
9041 (base32
9042 "1200xhqiqlqfmrq54v2p6cf3nny86njjw8r7sk5j59hlk9a683zk"))))
9043 (build-system pyproject-build-system)
9044 (propagated-inputs
9045 (list python-authlib
9046 python-blinker
9047 python-flask
9048 python-requests
9049 python-responses))
9050 (native-inputs
9051 (list python-pytest python-poetry-core))
9052 (home-page "https://github.com/puiterwijk/flask-oidc")
9053 (synopsis "OpenID Connect extension for Flask")
9054 (description "@code{python-flask-oidc} provides an OpenID Connect extension
9055for Flask.")
9056 (license license:bsd-2)))
9057
9058(define-public python-webassets
9059 (package
9060 (name "python-webassets")
9061 (version "3.0.0")
9062 (source
9063 (origin
9064 (method git-fetch)
9065 (uri (git-reference
9066 (url "https://github.com/miracle2k/webassets")
9067 (commit version)))
9068 (file-name (git-file-name name version))
9069 (sha256
9070 (base32 "11hxvdqw86q6r665iryjzwx21ys8jh2c63mw016ldr6j49l0zyyh"))))
9071 (build-system pyproject-build-system)
9072 (propagated-inputs (list python-pyyaml python-zope-dottedname))
9073 (native-inputs (list python-hatchling python-pytest))
9074 (home-page "https://github.com/miracle2k/webassets")
9075 (synopsis "Media asset management")
9076 (description
9077 "This package provides utilities to merge, minify and compress Javascript
9078and CSS files,supporting a variety of different filters, including YUI, jsmin,
9079jspacker or CSS tidy. It also supports URL rewriting in CSS files.")
9080 (license license:bsd-2)))
9081
9082(define-public python-cssmin
9083 (package
9084 (name "python-cssmin")
9085 (version "0.2.0")
9086 (source
9087 (origin
9088 (method git-fetch)
9089 (uri (git-reference
9090 (url "https://github.com/zacharyvoase/cssmin")
9091 (commit (string-append "v" version))))
9092 (file-name (git-file-name name version))
9093 (sha256
9094 (base32 "04bzpal6j26pjjjf3p7iq6g2wcr61j4g0ygqz6h847h4hsyah9qg"))))
9095 (build-system pyproject-build-system)
9096 (arguments (list #:tests? #f)) ; No tests.
9097 (native-inputs (list python-setuptools))
9098 (home-page "https://github.com/zacharyvoase/cssmin")
9099 (synopsis "Python port of the YUI CSS Compressor")
9100 (description "Python port of the YUI CSS Compressor.")
9101 (license (list license:expat license:bsd-3))))
9102
9103(define-public python-elastic-transport
9104 (package
9105 (name "python-elastic-transport")
9106 (version "9.1.0")
9107 (source
9108 (origin
9109 (method url-fetch)
9110 (uri (pypi-uri "elastic_transport" version))
9111 (sha256
9112 (base32 "0g879z8rqrfbwkxsm6xcycjha1swl7gdgs6m0y0j1zmh4m5f940m"))))
9113 (build-system pyproject-build-system)
9114 (arguments
9115 (list
9116 #:test-flags
9117 ;; Deselect failing tests (mostly due to network not reachable)
9118 #~(list "-k"
9119 (string-append
9120 "not .badssl.com"
9121 " and not test_assert_fingerprint_in_cert_chain_failure"))))
9122 (propagated-inputs (list python-certifi python-urllib3))
9123 (native-inputs (list nss-certs-for-test
9124 python-aiohttp
9125 ;; python-furo
9126 python-httpx
9127 python-opentelemetry-api
9128 python-opentelemetry-sdk
9129 python-orjson
9130 python-pytest
9131 python-pytest-asyncio-0.26
9132 ;; python-pytest-cov
9133 python-pytest-httpbin
9134 python-pytest-httpserver
9135 python-pytest-mock
9136 python-requests
9137 python-respx ;test
9138 python-setuptools
9139 ;; python-sphinx
9140 ;; python-sphinx-autodoc-typehints
9141 python-trustme
9142 python-wheel))
9143 (home-page "https://github.com/elastic/elastic-transport-python")
9144 (synopsis "Common library for Python Elastic client libraries")
9145 (description
9146 "This library was lifted from @code{elasticsearch-py} and then transformed to
9147be used across all Elastic services rather than only Elasticsearch. It
9148provides transport classes and utilities shared among Python Elastic client
9149libraries.")
9150 ;; Apache-2.0 in setup.py and LICENSE file.
9151 (license license:asl2.0)))
9152
9153(define-public python-elasticsearch
9154 (package
9155 (name "python-elasticsearch")
9156 (version "9.1.1")
9157 (source
9158 (origin
9159 (method git-fetch) ; no tests in PyPI release
9160 (uri (git-reference
9161 (url "https://github.com/elastic/elasticsearch-py")
9162 (commit (string-append "v" version))))
9163 (file-name (git-file-name name version))
9164 (sha256
9165 (base32 "015x73y84nyigcyg00lh32p2pfrqf834fr7clfnzymgzrrxa73jf"))))
9166 (build-system pyproject-build-system)
9167 (native-inputs
9168 (list nss-certs-for-test
9169 python-aiohttp
9170 python-dateutil
9171 python-mock
9172 python-orjson
9173 python-pytest
9174 python-pytest-asyncio
9175 python-pytz
9176 python-pyyaml
9177 python-requests
9178 python-hatchling))
9179 (propagated-inputs
9180 (list python-certifi
9181 python-elastic-transport))
9182 (home-page "https://github.com/elastic/elasticsearch-py")
9183 (synopsis "Low-level client for Elasticsearch")
9184 (description "Official low-level client for Elasticsearch. Its goal is to
9185provide common ground for all Elasticsearch-related code in Python; because of
9186this it tries to be opinion-free and very extendable.")
9187 ;; Apache-2.0 in setup.py and LICENSE file.
9188 (license license:asl2.0)))
9189
9190(define-public python-engineio
9191 (package
9192 (name "python-engineio")
9193 (version "4.12.2")
9194 (source
9195 (origin
9196 (method url-fetch)
9197 (uri (pypi-uri "python_engineio" version))
9198 (sha256
9199 (base32
9200 "1ynyf3n29biwkm6nwzzwzhr4m19lsir1x5azxq2nl7xyw7zi5rz7"))))
9201 (build-system pyproject-build-system)
9202 (arguments
9203 (list
9204 #:test-flags
9205 #~(list "-k"
9206 "not test_static_file_routing and not test_static_files")))
9207 (native-inputs
9208 (list python-pytest
9209 python-pytest-asyncio
9210 python-setuptools
9211 python-tornado))
9212 (propagated-inputs
9213 (list python-aiohttp
9214 python-requests
9215 python-simple-websocket
9216 python-websocket-client))
9217 (home-page "https://github.com/miguelgrinberg/python-engineio/")
9218 (synopsis "Engine.IO server")
9219 (description "This package provides a Python implementation of the
9220@code{Engine.IO} realtime client and server.")
9221 (license license:expat)))
9222
9223(define-public python-ephemeral-port-reserve
9224 (package
9225 (name "python-ephemeral-port-reserve")
9226 (version "1.1.4")
9227 (source
9228 (origin
9229 (method git-fetch) ;no tests in PyPI archive
9230 (uri (git-reference
9231 (url "https://github.com/Yelp/ephemeral-port-reserve")
9232 (commit (string-append "v" version))))
9233 (file-name (git-file-name name version))
9234 (sha256
9235 (base32 "1ifmf5zcw7mhbm73awmf5jwc4rw8lhk81mn4zp797lwkysjm38s7"))))
9236 (build-system pyproject-build-system)
9237 (native-inputs
9238 (list python-pytest
9239 python-setuptools
9240 python-wheel))
9241 (home-page "https://github.com/Yelp/ephemeral-port-reserve/")
9242 (synopsis "Find an unused port, reliably")
9243 (description
9244 "Bind to an ephemeral port, force it into the TIME_WAIT state, and unbind
9245it.")
9246 (license license:expat)))
9247
9248(define-public python-flask-migrate
9249 (package
9250 (name "python-flask-migrate")
9251 (version "4.1.0")
9252 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
9253 (source (origin
9254 (method git-fetch)
9255 (uri (git-reference (url home-page)
9256 (commit (string-append "v" version))))
9257 (file-name (git-file-name name version))
9258 (sha256
9259 (base32
9260 "09qw1hhyssa5gahm199x67d55c55m3k9m23xp2bdacwsiv8jw57g"))))
9261 (build-system pyproject-build-system)
9262 (propagated-inputs
9263 (list python-flask python-alembic python-flask-sqlalchemy))
9264 (native-inputs
9265 (list python-pytest python-setuptools python-wheel))
9266 (synopsis "SQLAlchemy database migrations for Flask programs using
9267Alembic")
9268 (description "This package contains SQLAlchemy database migration tools
9269for Flask programs that are using @code{python-alembic}.")
9270 (license license:expat)))
9271
9272(define-public python-genshi
9273 (package
9274 (name "python-genshi")
9275 (version "0.7.10")
9276 (source
9277 (origin
9278 (method git-fetch)
9279 (uri (git-reference
9280 (url "https://github.com/edgewall/genshi")
9281 (commit version)))
9282 (file-name (git-file-name name version))
9283 (sha256
9284 (base32 "1dmf0ggp0s3371jv483kjriw9jscawxcik6q70a0wqjdfh5383i6"))))
9285 (build-system pyproject-build-system)
9286 (arguments (list #:test-backend #~'unittest))
9287 (native-inputs (list python-setuptools))
9288 (propagated-inputs (list python-six))
9289 (home-page "https://genshi.edgewall.org/")
9290 (synopsis "Toolkit for generation of output for the web")
9291 (description "Genshi is a Python library that provides an integrated set
9292of components for parsing, generating, and processing HTML, XML or other
9293textual content for output generation on the web.")
9294 (license license:bsd-3)))
9295
9296(define-public python-flask-principal
9297 (package
9298 (name "python-flask-principal")
9299 (version "0.4.0")
9300 (source
9301 (origin
9302 (method git-fetch)
9303 (uri (git-reference
9304 (url "https://github.com/pallets-eco/flask-principal")
9305 (commit version)))
9306 (file-name (git-file-name name version))
9307 (sha256
9308 (base32 "0hcqcj768inmyfsw1y2vk6pa9p22dh138ll809rhpz9vjz6spnqk"))))
9309 (build-system pyproject-build-system)
9310 (propagated-inputs (list python-blinker))
9311 (native-inputs (list python-flask python-pynose python-setuptools))
9312 (home-page "https://github.com/pallets-eco/flask-principal")
9313 (synopsis "Identity management for Flask")
9314 (description
9315 "@code{flask_principal} is a identity management library for Flask. It
9316supports managing both authentication and authorization data in a thread-local
9317variable.")
9318 (license license:expat)))
9319
9320(define-public python-flask-httpauth
9321 (package
9322 (name "python-flask-httpauth")
9323 (version "4.8.0")
9324 (source
9325 (origin
9326 (method url-fetch)
9327 (uri (pypi-uri "Flask-HTTPAuth" version))
9328 (sha256
9329 (base32
9330 "0yh9fn6pak64has89pcy03f1cn198vkil872y5jjr53kph2qlmk6"))))
9331 (build-system pyproject-build-system)
9332 (propagated-inputs (list python-flask))
9333 (native-inputs
9334 (list nss-certs-for-test
9335 python-pytest
9336 python-setuptools
9337 python-wheel))
9338 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
9339 (synopsis "Basic and Digest HTTP authentication for Flask routes")
9340 (description "@code{flask_httpauth} provides Basic and Digest HTTP
9341authentication for Flask routes.")
9342 (license license:expat)))
9343
9344(define-public python-uritemplate
9345 (package
9346 (name "python-uritemplate")
9347 (version "4.2.0")
9348 (source
9349 (origin
9350 (method url-fetch)
9351 (uri (pypi-uri "uritemplate" version))
9352 (sha256
9353 (base32
9354 "03lxxkk0kjn6z7z1f9hqvsaqfrny1qds7vi36f35b2c7h38jw328"))))
9355 (build-system pyproject-build-system)
9356 (native-inputs (list python-pytest python-setuptools))
9357 (home-page "https://uritemplate.readthedocs.io/")
9358 (synopsis "Library to deal with URI Templates")
9359 (description "@code{uritemplate} provides Python library to deal with URI
9360Templates.")
9361 ;; The software is made available under the terms of *either* of the
9362 ;; licenses found in LICENSE.APACHE or LICENSE.BSD. Contributions
9363 ;; are made under *both* licenses (excerpt from the LICENSE file).
9364 (license (list license:bsd-2 license:asl2.0))))
9365
9366(define-public python-uritemplate-3
9367 (package
9368 (inherit python-uritemplate)
9369 (name "python-uritemplate")
9370 (version "3.0.1")
9371 (source (origin
9372 (method url-fetch)
9373 (uri (pypi-uri "uritemplate" version))
9374 (sha256
9375 (base32 "1bkwmgr0ia9gcn4bszs2xlvml79f0bi2s4a87xg22ky9rq8avy2s"))))))
9376
9377(define-public python-publicsuffix2
9378 (package
9379 (name "python-publicsuffix2")
9380 (version "2.2019-12-21")
9381 (source
9382 (origin
9383 (method git-fetch)
9384 (uri (git-reference
9385 (url "https://github.com/pombredanne/python-publicsuffix2")
9386 (commit (string-append "release-" version))))
9387 (file-name (git-file-name name version))
9388 (sha256
9389 (base32 "1dkvfvl0izq9hqzilnw8ipkbgjs9xyad9p21i3864hzinbh0wp9r"))))
9390 (build-system pyproject-build-system)
9391 (arguments
9392 (list
9393 #:tests? #f ;the test suite requires network access
9394 #:phases
9395 #~(modify-phases %standard-phases
9396 (add-after 'unpack 'ignore-maintainer-inputs
9397 (lambda _
9398 ;; Comment out a demand for python-requests, which is used only by
9399 ;; the unused ‘update_psl’ helper command.
9400 (substitute* "setup.py"
9401 (("'requests " match)
9402 (format #f "# ~a" match))))))))
9403 (native-inputs (list python-setuptools))
9404 (home-page "https://github.com/pombredanne/python-publicsuffix2")
9405 (synopsis
9406 "Get a public suffix for a domain name using the Public Suffix List")
9407 (description
9408 "Get a public suffix for a domain name using the Public Suffix List.
9409Forked from and using the same API as the publicsuffix package.")
9410 (license (list license:expat license:mpl2.0))))
9411
9412(define-public python-werkzeug
9413 (package
9414 (name "python-werkzeug")
9415 (version "3.1.3")
9416 (source
9417 (origin
9418 (method url-fetch)
9419 (uri (pypi-uri "werkzeug" version))
9420 (sha256
9421 (base32
9422 "0ij7si3aa3ykac7k7fz481h4majqqwn2iqwhjxkji4y18plkqwk0"))))
9423 (build-system pyproject-build-system)
9424 (arguments
9425 (list
9426 #:test-flags
9427 ;; Test requiring networking setup.
9428 #~(list "--ignore=tests/test_serving.py"
9429 "--deselect=tests/test_debug.py::test_basic"
9430 "--deselect=tests/test_exceptions.py::test_response_body"
9431 "--deselect=tests/middleware/test_http_proxy.py::test_http_proxy")))
9432 (native-inputs
9433 (list python-flit-core
9434 python-pytest
9435 python-watchdog
9436 python-ephemeral-port-reserve
9437 python-pytest-timeout
9438 python-pytest-xprocess))
9439 (propagated-inputs
9440 (list python-markupsafe
9441 python-requests))
9442 (home-page "https://palletsprojects.com/p/werkzeug/")
9443 (synopsis "Utilities for WSGI applications")
9444 (description "One of the most advanced WSGI utility modules. It includes a
9445powerful debugger, full-featured request and response objects, HTTP utilities to
9446handle entity tags, cache control headers, HTTP dates, cookie handling, file
9447uploads, a powerful URL routing system and a bunch of community-contributed
9448addon modules.")
9449 (license license:x11)))
9450
9451(define-public python-werkzeug-1.0
9452 (package
9453 (inherit python-werkzeug)
9454 (version "1.0.1")
9455 (source (origin
9456 (method url-fetch)
9457 (uri (pypi-uri "Werkzeug" version))
9458 (sha256
9459 (base32
9460 "0z74sa1xw5h20yin9faj0vvdbq713cgbj84klc72jr9nmpjv303c"))
9461 (patches (search-patches "python-werkzeug-tests.patch"))))
9462 (arguments
9463 (list
9464 #:phases
9465 '(modify-phases %standard-phases
9466 (add-after 'unpack 'ignore-warnings
9467 (lambda _
9468 (substitute* "setup.cfg"
9469 ((" error.*") "")))))))
9470 (propagated-inputs
9471 (list python-requests))
9472 (native-inputs
9473 (list python-pytest python-pytest-timeout python-setuptools
9474 python-wheel))))
9475
9476(define-public python-bottle
9477 (package
9478 (name "python-bottle")
9479 (version "0.13.4")
9480 (source
9481 (origin
9482 (method url-fetch)
9483 (uri (pypi-uri "bottle" version))
9484 (sha256
9485 (base32 "0irz5i3h73pqz0ssgp3yk12zx33q7lrlh8p0in9jgchjgqr7hzkq"))))
9486 (build-system pyproject-build-system)
9487 (native-inputs (list python-pytest python-setuptools))
9488 (home-page "https://bottlepy.org/")
9489 (synopsis "WSGI framework for small web-applications")
9490 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
9491 (license license:expat)))
9492
9493(define-public python-wtforms
9494 (package
9495 (name "python-wtforms")
9496 (version "3.2.2")
9497 (source
9498 (origin
9499 (method url-fetch)
9500 (uri (pypi-uri "wtforms" version))
9501 (sha256
9502 (base32 "14qbayp2gfmahaqn5migwyz2h1cq3gcdr4q2vd75vwvhhqzwf03v"))))
9503 (build-system pyproject-build-system)
9504 (native-inputs
9505 (list python-babel
9506 python-email-validator
9507 python-hatchling
9508 python-pytest
9509 python-setuptools))
9510 (propagated-inputs (list python-markupsafe))
9511 (home-page "https://wtforms.readthedocs.io/")
9512 (synopsis
9513 "Form validation and rendering library for Python web development")
9514 (description
9515 "WTForms is a flexible forms validation and rendering library
9516for Python web development. It is very similar to the web form API
9517available in Django, but is a standalone package.")
9518 (license license:bsd-3)))
9519
9520(define-public python-wtforms-sqlalchemy
9521 (package
9522 (name "python-wtforms-sqlalchemy")
9523 (version "0.4.1")
9524 (source
9525 (origin
9526 (method url-fetch)
9527 (uri (pypi-uri "WTForms-SQLAlchemy" version))
9528 (sha256
9529 (base32 "1nx4x0ifanlbrzh3f9ns8ihnchlkzf54ilvqmgcgcz2j72vm43rp"))))
9530 (build-system pyproject-build-system)
9531 (native-inputs (list python-pytest python-setuptools python-wheel))
9532 (propagated-inputs (list python-sqlalchemy python-wtforms))
9533 (home-page "https://github.com/wtforms/wtforms-sqlalchemy/")
9534 (synopsis "SQLAlchemy tools for WTForms")
9535 (description
9536 "WTForms-SQLAlchemy is a fork of the @code{wtforms.ext.sqlalchemy}
9537package from WTForms. The package has been renamed to
9538@code{wtforms_sqlalchemy} but otherwise should function the same as
9539@code{wtforms.ext.sqlalchemy} did.")
9540 (license license:bsd-3)))
9541
9542(define-public python-urlgrabber
9543 (package
9544 (name "python-urlgrabber")
9545 (version "4.1.0")
9546 (source
9547 (origin
9548 (method url-fetch)
9549 (uri (pypi-uri "urlgrabber" version))
9550 (sha256
9551 (base32 "0fg16zlw49cw7pjq9dhpc5vd35d5zz1mlki55m464qxfmfpzhnh7"))))
9552 (build-system pyproject-build-system)
9553 (arguments
9554 (list
9555 #:tests? #f ; Most tests require network access.
9556 #:phases
9557 #~(modify-phases %standard-phases
9558 (replace 'check
9559 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
9560 (when tests?
9561 (invoke "python" "test/runtests.py")))))))
9562 (native-inputs (list python-setuptools))
9563 (propagated-inputs
9564 (list python-pycurl python-setuptools python-six))
9565 (home-page "http://urlgrabber.baseurl.org/") ; no HTTPS
9566 (synopsis "High-level cross protocol url-grabber")
9567 (description
9568 "@code{urlgrabber} is a library that unifies access to files available on
9569the web, FTP or locally. It supports HTTP, FTP and file:// protocols, it
9570supports features like HTTP keep-alive, reget, throttling and more.")
9571 (license license:lgpl2.1+)))
9572
9573(define-public python-pycares
9574 (package
9575 (name "python-pycares")
9576 (version "4.11.0")
9577 (source
9578 (origin
9579 (method git-fetch)
9580 (uri (git-reference
9581 (url "https://github.com/saghul/pycares")
9582 (commit (string-append "v" version))))
9583 (file-name (git-file-name name version))
9584 (sha256
9585 (base32 "18syxp9bpm70zfiw427p7cpp6wg0ybrw6b32c1zvdp2i8jgd82xl"))
9586 (snippet #~(begin
9587 (rmdir "deps/c-ares")))))
9588 (build-system pyproject-build-system)
9589 (arguments
9590 (list
9591 ;; XXX: Half of the tests require internet access
9592 ;; There is currently no markers to avoid running them.
9593 #:tests? #f
9594 #:phases
9595 #~(modify-phases %standard-phases
9596 (add-after 'unpack 'configure-system-lib
9597 (lambda _
9598 (setenv "PYCARES_USE_SYSTEM_LIB" "1"))))))
9599 (native-inputs (list python-pytest python-setuptools))
9600 (inputs (list c-ares))
9601 (propagated-inputs (list python-cffi))
9602 (home-page "https://github.com/saghul/pycares")
9603 (synopsis "Python interface for @code{c-ares}")
9604 (description
9605 "@code{pycares} is a Python module which provides an interface to
9606@code{c-ares}, a C library that performs DNS requests and name resolutions
9607asynchronously.")
9608 (license license:expat)))
9609
9610(define-public python-yarl
9611 (package
9612 (name "python-yarl")
9613 (version "1.18.3")
9614 (source
9615 (origin
9616 (method url-fetch)
9617 (uri (pypi-uri "yarl" version))
9618 (sha256
9619 (base32
9620 "1qfj6kvdxr8bzka4lp0bh0xfgr5mzx7zzvj2jb4vcxxzbk20265c"))))
9621 (build-system pyproject-build-system)
9622 (arguments
9623 (list
9624 #:test-flags '(list "--ignore-glob=tests/test_*_benchmarks.py")
9625 #:phases
9626 '(modify-phases %standard-phases
9627 (add-after 'unpack 'avoid-pytest-cov-preload
9628 (lambda _
9629 (substitute* "pytest.ini"
9630 (("-p pytest_cov") ""))))
9631 (add-after 'unpack 'patch-build-system
9632 (lambda _
9633 ;; XXX: I don't know how to tell it to build the extensions in
9634 ;; place.
9635 (substitute* "packaging/pep517_backend/_backend.py"
9636 (("build_inplace=False") "build_inplace=True")))))))
9637 (native-inputs
9638 (list python-cython
9639 python-expandvars
9640 python-pytest
9641 python-pytest-xdist
9642 python-setuptools
9643 python-tomli))
9644 (propagated-inputs
9645 (list python-packaging python-idna python-multidict python-propcache))
9646 (home-page "https://github.com/aio-libs/yarl/")
9647 (synopsis "Yet another URL library")
9648 (description "@code{yarl} module provides handy @code{URL} class
9649for URL parsing and changing.")
9650 (license license:asl2.0)))
9651
9652(define-public python-canvasapi
9653 (package
9654 (name "python-canvasapi")
9655 (version "3.4.0")
9656 (source (origin
9657 (method git-fetch)
9658 (uri (git-reference
9659 (url "https://github.com/ucfopen/canvasapi")
9660 (commit (string-append "v" version))))
9661 (file-name (git-file-name name version))
9662 (sha256
9663 (base32
9664 "017gashyd4avxzlz3imwn18vmfd0cjyhbm063isra3d2wk3ivrkx"))))
9665 (build-system pyproject-build-system)
9666 (propagated-inputs (list python-arrow python-pytz python-requests))
9667 (native-inputs (list python-pytest
9668 python-requests-mock
9669 python-setuptools
9670 python-urllib3))
9671 (home-page "https://github.com/ucfopen/canvasapi")
9672 (synopsis "API wrapper for the Canvas LMS")
9673 (description
9674 "CanvasAPI is a Python library for accessing Instructure’s Canvas LMS API.
9675The library enables developers to programmatically manage Canvas courses,
9676users, gradebooks, and more.")
9677 (license license:expat)))
9678
9679(define-public python-google
9680 (package
9681 (name "python-google")
9682 (version "3.0.0")
9683 (source
9684 (origin
9685 (method url-fetch)
9686 (uri (pypi-uri "google" version))
9687 (sha256
9688 (base32 "1gncv3l11za0mpxvmpaf5n5j3jzp282rz62yml4ha4z55q930d8l"))))
9689 (build-system pyproject-build-system)
9690 (arguments (list #:tests? #f)) ;There are no tests.
9691 (native-inputs (list python-setuptools))
9692 (propagated-inputs (list python-beautifulsoup4))
9693 (home-page "https://breakingcode.wordpress.com/")
9694 (synopsis "Python bindings to the Google search engine")
9695 (description
9696 "This package provides Python bindings for using the Google search
9697engine. Its module is called @code{googlesearch}.")
9698 (license license:bsd-3)))
9699
9700(define-public python-google-api-client
9701 (package
9702 (name "python-google-api-client")
9703 (version "2.187.0")
9704 (source
9705 (origin
9706 (method git-fetch)
9707 (uri (git-reference
9708 (url "https://github.com/google/google-api-python-client")
9709 (commit (string-append "v" version))))
9710 (file-name (git-file-name name version))
9711 (sha256
9712 (base32 "09vq5d32avri0gl8c7nn5dv2xds1jzjms7vqk3gn66nm2m37x8mv"))))
9713 (build-system pyproject-build-system)
9714 (arguments
9715 (list
9716 #:test-flags
9717 #~(list
9718 "-k"
9719 (string-join
9720 (list
9721 ;; XXX: Deprecated behavior.
9722 "not test_client_options_universe_configured_with_mtls"
9723 "test_universe_env_var_configured_with_mtls"
9724 ;; XXX: Requires CA certificates.
9725 "test_credentials_and_credentials_file_mutually_exclusive")
9726 " and not ")
9727 "tests")))
9728 (native-inputs
9729 (list python-parameterized
9730 python-pytest
9731 python-setuptools))
9732 (propagated-inputs
9733 (list python-google-api-core
9734 python-google-auth
9735 python-google-auth-httplib2
9736 python-httplib2
9737 python-pyparsing
9738 python-uritemplate-3))
9739 (home-page "https://github.com/google/google-api-python-client")
9740 (synopsis "Core Python library for accessing Google APIs")
9741 (description "Python client library for Google's discovery based APIs")
9742 (license license:asl2.0)))
9743
9744(define-public python-google-auth-httplib2
9745 (package
9746 (name "python-google-auth-httplib2")
9747 (version "0.2.0")
9748 (source (origin
9749 (method url-fetch)
9750 (uri (pypi-uri "google-auth-httplib2" version))
9751 (sha256
9752 (base32 "018fckshilc6z2qpj1pclh8haanbq3lr85w6p4g4z5wgyjnppaiq"))))
9753 (build-system pyproject-build-system)
9754 (propagated-inputs
9755 (list python-google-auth python-httplib2))
9756 (native-inputs
9757 (list python-pytest
9758 python-pyparsing
9759 python-pytest-localserver
9760 python-flask
9761 python-setuptools))
9762 (home-page
9763 "https://github.com/GoogleCloudPlatform/google-auth-library-python-httplib2")
9764 (synopsis "Google Authentication Library: httplib2 transport")
9765 (description "This package provides a Google Authentication Library plugin
9766for httplib2 transport.")
9767 (license license:asl2.0)))
9768
9769(define-public python-google-auth-oauthlib
9770 (package
9771 (name "python-google-auth-oauthlib")
9772 (version "1.2.4")
9773 (home-page
9774 "https://github.com/GoogleCloudPlatform/\
9775google-auth-library-python-oauthlib")
9776 (source
9777 (origin
9778 (method git-fetch)
9779 (uri (git-reference
9780 (url home-page)
9781 (commit (string-append "v" version))))
9782 (file-name (git-file-name name version))
9783 (sha256
9784 (base32 "1j25kdbs2j1x23pdv4n49xl9pz2ppn55vsav65ir796kq4lf9nca"))))
9785 (build-system pyproject-build-system)
9786 (propagated-inputs (list python-google-auth python-requests-oauthlib))
9787 (native-inputs
9788 (list python-click python-mock python-pytest python-setuptools))
9789 (synopsis "Google Authentication Library: oauthlib")
9790 (description "This package provides a Google Authentication Library plugin
9791with oauthlib.")
9792 (license license:asl2.0)))
9793
9794(define-public whoogle-search
9795 (package
9796 (name "whoogle-search")
9797 (version "0.8.4")
9798 (source (origin
9799 (method url-fetch)
9800 (uri (pypi-uri "whoogle-search" version))
9801 (sha256
9802 (base32
9803 "0hsy4l98nzj6i1lf63wvqd0yharkaz44zsxh863ymy47rxnwimz7"))))
9804 (build-system pyproject-build-system)
9805 (arguments
9806 (list
9807 ;; The tests need network access
9808 #:tests? #f))
9809 (propagated-inputs
9810 (list python-beautifulsoup4
9811 python-brotli
9812 python-cryptography
9813 python-cssutils
9814 python-defusedxml
9815 python-flask
9816 python-dotenv
9817 python-requests
9818 python-stem
9819 python-validators
9820 python-waitress))
9821 (native-inputs (list python-setuptools python-wheel))
9822 (home-page "https://github.com/benbusby/whoogle-search")
9823 (synopsis "Self-hosted, ad-free, privacy-respecting metasearch engine")
9824 (description
9825 "Get Google results, but without any ads, javascript, AMP links,
9826cookies, or IP address tracking. Quick and simple to implement as a primary
9827search engine replacement on both desktop and mobile.")
9828 (license license:expat)))
9829
9830(define-public python-hawkauthlib
9831 (package
9832 (name "python-hawkauthlib")
9833 (version "2.0.0")
9834 (source
9835 (origin
9836 (method git-fetch)
9837 (uri (git-reference
9838 (url "https://github.com/mozilla-services/hawkauthlib")
9839 (commit (string-append "v" version))))
9840 (file-name (git-file-name name version))
9841 (sha256
9842 (base32 "0pdpk3fp87ngfsyp4lm2z7z8b203jxsmvbz59q6r6xgg9sp4cl3l"))))
9843 (build-system pyproject-build-system)
9844 (arguments
9845 (list
9846 #:test-backend #~'unittest
9847 #:phases
9848 #~(modify-phases %standard-phases
9849 (add-after 'unpack 'fix-python-incompatibilities
9850 (lambda _
9851 (substitute* (find-files "hawkauthlib/tests" "\\.py$")
9852 (("assertEquals") "assertEqual")))))))
9853 (native-inputs (list python-setuptools))
9854 (propagated-inputs (list python-requests python-webob))
9855 (home-page "https://github.com/mozilla-services/hawkauthlib")
9856 (synopsis "Hawk Access Authentication protocol")
9857 (description
9858 "This is a low-level Python library for implementing Hawk Access
9859Authentication, a simple HTTP request-signing scheme.")
9860 (license license:mpl2.0)))
9861
9862(define-public python-pybrowserid
9863 (package
9864 (name "python-pybrowserid")
9865 (version "0.14.0")
9866 (source
9867 (origin
9868 (method git-fetch)
9869 (uri (git-reference
9870 (url "https://github.com/mozilla/PyBrowserID")
9871 (commit version)))
9872 (file-name (git-file-name name version))
9873 (sha256
9874 (base32 "0in0sbj56wrz5mlrj6wkd3h7rrp7714c5rkxvkfwp60s2hr6ynj6"))))
9875 (build-system pyproject-build-system)
9876 (arguments
9877 (list
9878 #:test-backend #~'unittest
9879 #:phases
9880 #~(modify-phases %standard-phases
9881 (add-after 'unpack 'python-3.12-compatibility
9882 (lambda _
9883 (substitute* (find-files "browserid/tests" "\\.py")
9884 (("assertEquals") "assertEqual")))))))
9885 (propagated-inputs (list python-requests))
9886 (native-inputs (list python-mock python-setuptools))
9887 (home-page "https://github.com/mozilla/PyBrowserID")
9888 (synopsis "Python library for the BrowserID protocol")
9889 (description
9890 "This is a Python client library for the BrowserID protocol that
9891underlies Mozilla Persona.")
9892 (license license:mpl2.0)))
9893
9894(define-public python-pyfxa
9895 (package
9896 (name "python-pyfxa")
9897 (version "0.8.1")
9898 (source
9899 (origin
9900 (method git-fetch)
9901 (uri (git-reference
9902 (url "https://github.com/mozilla/PyFxA")
9903 (commit (string-append "v" version))))
9904 (file-name (git-file-name name version))
9905 (sha256
9906 (base32 "11iaw50x5ic9cqp3jwkvhk8mz00dhg8xhl1kkx45zrb8nnrfw2vs"))))
9907 (build-system pyproject-build-system)
9908 (arguments
9909 (list
9910 ;; These tests require network access
9911 #:test-flags #~(list "--ignore=fxa/tests/test_core.py")))
9912 (propagated-inputs
9913 (list python-cryptography
9914 python-pyjwt
9915 python-parameterized
9916 python-hawkauthlib
9917 python-requests))
9918 (native-inputs
9919 (list python-grequests
9920 python-hatchling
9921 python-mock
9922 python-pytest
9923 python-responses))
9924 (home-page "https://github.com/mozilla/PyFxA")
9925 (synopsis "Firefox Accounts client library for Python")
9926 (description
9927 "This is a Python library for interacting with the Firefox Accounts
9928ecosystem.")
9929 (license license:mpl2.0)))
9930
9931(define-public python-hyperlink
9932 (package
9933 (name "python-hyperlink")
9934 (version "21.0.0")
9935 (source
9936 (origin
9937 (method url-fetch)
9938 (uri (pypi-uri "hyperlink" version))
9939 (sha256
9940 (base32
9941 "0sx50lkivsfjxx9zr4yh7l9gll2l9kvl0v0w8w4wk2x5v9bzjyj2"))))
9942 (build-system pyproject-build-system)
9943 (arguments
9944 (list #:phases
9945 #~(modify-phases %standard-phases
9946 (add-before 'check 'pretend-to-be-CI
9947 (lambda _
9948 ;; Pretend to be a CI system to skip flaky tests.
9949 (setenv "CI" "true"))))))
9950 (native-inputs
9951 (list python-pytest python-setuptools python-wheel))
9952 (propagated-inputs
9953 (list python-idna))
9954 (home-page "https://github.com/python-hyper/hyperlink")
9955 (synopsis "Python module to create immutable URLs according to spec")
9956 (description "This package provides a Python module to create immutable, and
9957correct URLs for Python according to RFCs 3986 and 3987.")
9958 (license license:expat)))
9959
9960(define-public python-treq
9961 (package
9962 (name "python-treq")
9963 (version "24.9.1")
9964 (source
9965 (origin
9966 (method url-fetch)
9967 (uri (pypi-uri "treq" version))
9968 (sha256
9969 (base32
9970 "1a7yrq2m7hf77fia4fc0c6zanvwnykpgirdbs1cyvr7k0k27znhm"))))
9971 (build-system pyproject-build-system)
9972 (native-inputs
9973 (list python-httpbin
9974 python-pytest
9975 python-service-identity
9976 python-setuptools
9977 python-wheel))
9978 (propagated-inputs
9979 (list python-attrs
9980 python-hyperlink
9981 python-incremental
9982 python-requests
9983 python-twisted
9984 python-typing-extensions))
9985 (home-page "https://github.com/twisted/treq")
9986 (synopsis "Requests-like API built on top of twisted.web's Agent")
9987 (description "This package provides an HTTP library inspired by
9988@code{requests} but written on top of Twisted's @code{Agents}. It offers a
9989high level API for making HTTP requests when using Twisted.")
9990 (license license:expat)))
9991
9992(define-public python-autobahn
9993 (package
9994 (name "python-autobahn")
9995 (version "25.11.1")
9996 (source
9997 (origin
9998 (method url-fetch)
9999 (uri (pypi-uri "autobahn" version))
10000 (sha256
10001 (base32
10002 "1w9wyyqzg1dil8jsjm08n2pnk6jws87scli932drhghcr2f2prjj"))))
10003 (build-system pyproject-build-system)
10004 (arguments
10005 (list
10006 ;; The tests fail to run:
10007 ;; https://github.com/crossbario/autobahn-python/issues/1117
10008 #:tests? #f
10009 #:phases #~(modify-phases %standard-phases
10010 (add-after 'unpack 'relax-zope-interface
10011 (lambda _
10012 ;; python-zope-interface is a world rebuild package
10013 ;; and our one-digit lower minor version seems to be
10014 ;; fine.
10015 (substitute* "setup.py"
10016 (("zope.interface>=5.2.0")
10017 "zope.interface>=5.1.0"))))
10018 (add-after 'unpack 'strip-xbr
10019 (lambda _
10020 ;; Strip new XBR feature which isn't available in Guix.
10021 (setenv "AUTOBAHN_STRIP_XBR" "1"))))))
10022 (native-inputs (list python-setuptools python-wheel))
10023 (propagated-inputs (list python-cbor2
10024 python-cryptography
10025 python-hyperlink
10026 python-msgpack
10027 python-py-ubjson
10028 python-twisted
10029 python-txaio
10030 python-ujson))
10031 (home-page "https://github.com/crossbario/autobahn-python/")
10032 (synopsis "Web Application Messaging Protocol implementation")
10033 (description "This package provides an implementation of the @dfn{Web Application
10034Messaging Protocol} (WAMP). WAMP connects components in distributed
10035applications using Publish and Subscribe (PubSub) and routed Remote Procedure
10036Calls (rRPC). It is ideal for distributed, multi-client and server applications
10037such as IoT applications or multi-user database-driven business applications.")
10038 (license license:expat)))
10039
10040(define-public python-ws4py
10041 (package
10042 (name "python-ws4py")
10043 (version "0.6.0")
10044 (source
10045 (origin
10046 (method git-fetch)
10047 (uri (git-reference
10048 (url "https://github.com/Lawouach/WebSocket-for-Python")
10049 (commit version)))
10050 (file-name (git-file-name name version))
10051 (sha256
10052 (base32
10053 "00y6s8gk20936njqbxr8vjliviiz7r7pqrlwg7xi8zzs6903xvv6"))))
10054 (build-system pyproject-build-system)
10055 (arguments
10056 (list
10057 #:phases
10058 #~(modify-phases %standard-phases
10059 (add-after 'unpack 'remove-cherrypy-support
10060 (lambda _
10061 (delete-file "ws4py/server/cherrypyserver.py")
10062 (delete-file "test/test_cherrypy.py"))))))
10063 (native-inputs (list python-setuptools python-pytest))
10064 (propagated-inputs
10065 (list python-gevent python-tornado))
10066 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
10067 (synopsis "WebSocket client and server library")
10068 (description
10069 "This package provides a WebSocket client and server library for Python.")
10070 (license license:bsd-3)))
10071
10072(define-public python-slowapi
10073 (package
10074 (name "python-slowapi")
10075 (version "0.1.9")
10076 (source
10077 (origin
10078 (method git-fetch)
10079 (uri (git-reference
10080 (url "https://github.com/laurents/slowapi")
10081 (commit (string-append "v" version))))
10082 (file-name (git-file-name name version))
10083 (sha256
10084 (base32 "1lc1n6lvh01dhhrc507qri9rz1w72l2riii03ixh7n7n1gwjpws7"))))
10085 (build-system pyproject-build-system)
10086 (arguments
10087 (list
10088 #:test-flags
10089 ;; These tests fail because the timestamp contains more decimal points
10090 ;; than expected, so a simple equality comparison fails.
10091 '(list "-k" (string-append "not test_headers_no_breach"
10092 " and not test_headers_breach"))))
10093 (propagated-inputs (list python-limits python-redis))
10094 (native-inputs
10095 (list python-fastapi
10096 python-hiro
10097 python-mock
10098 python-poetry-core
10099 python-pytest))
10100 (home-page "https://github.com/laurents/slowapi")
10101 (synopsis "Rate limiting extension for Starlette and Fastapi")
10102 (description
10103 "This package provides a rate limiting extension for Starlette and
10104Fastapi.")
10105 (license license:expat)))
10106
10107(define-public python-slugify
10108 (package
10109 (name "python-slugify")
10110 (version "8.0.4")
10111 (source
10112 (origin
10113 (method git-fetch)
10114 (uri (git-reference
10115 (url "https://github.com/un33k/python-slugify")
10116 (commit (string-append "v" version))))
10117 (file-name (git-file-name name version))
10118 (sha256
10119 (base32 "0z83nwy7acc72mb2jv3516nfplah1wm61wkmnzl71dh8i4q985yd"))))
10120 (build-system pyproject-build-system)
10121 (arguments (list #:test-backend #~'unittest))
10122 (native-inputs (list python-setuptools))
10123 (propagated-inputs (list python-unidecode python-text-unidecode))
10124 (home-page "https://github.com/un33k/python-slugify")
10125 (synopsis "Python Slugify application that handles Unicode")
10126 (description "This package provides a @command{slufigy} command and
10127library to create slugs from unicode strings while keeping it DRY.")
10128 (license license:expat)))
10129
10130(define-public python-branca
10131 (package
10132 (name "python-branca")
10133 (version "0.7.2")
10134 (source
10135 (origin
10136 (method git-fetch) ; no tests in PyPI
10137 (uri (git-reference
10138 (url "https://github.com/python-visualization/branca")
10139 (commit (string-append "v" version))))
10140 (file-name (git-file-name name version))
10141 (sha256
10142 (base32 "1vs94nqa7r6iwm8mj3m29hg090gmgz4ywnayxh8qiz9ij8jv96wa"))))
10143 (build-system pyproject-build-system)
10144 (arguments
10145 ;; This file requires Selenium.
10146 (list #:test-flags #~(list "--ignore" "tests/test_iframe.py"
10147 ;; This test passes but is very slow.
10148 "-k" "not test_color_brewer_extendability")))
10149 (propagated-inputs (list python-jinja2))
10150 (native-inputs
10151 (list python-numpy
10152 python-pytest
10153 python-setuptools
10154 python-setuptools-scm
10155 python-wheel))
10156 (home-page "https://github.com/python-visualization/branca")
10157 (synopsis "Generate complex HTML+JS pages with Python")
10158 (description "This library is a spinoff from @code{folium} that would host
10159the non-map-specific features. It can be used to generate HTML + JS.")
10160 (license license:expat)))
10161
10162(define-public python-tinycss2
10163 (package
10164 (name "python-tinycss2")
10165 (version "1.5.1")
10166 (source
10167 (origin
10168 (method git-fetch)
10169 (uri (git-reference
10170 (url "https://github.com/Kozea/tinycss2")
10171 (commit (string-append "v" version))
10172 (recursive? #true)))
10173 (file-name (git-file-name name version))
10174 (sha256
10175 (base32 "1ww5m8rmpva9mq04cz1h9rx76vg2h5nnijzi0vprf5wzp8g9snb5"))))
10176 (build-system pyproject-build-system)
10177 (native-inputs
10178 (list python-flit
10179 python-pytest))
10180 (propagated-inputs
10181 (list python-webencodings))
10182 (home-page "https://doc.courtbouillon.org/tinycss2/stable/")
10183 (synopsis "Low-level CSS parser for Python")
10184 (description "@code{tinycss2} can parse strings, return Python objects
10185representing tokens and blocks, and generate CSS strings corresponding to
10186these objects.
10187
10188Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
10189grammar of CSS but doesn’t know specific rules, properties or values supported
10190in various CSS modules.")
10191 (license license:bsd-3)))
10192
10193(define-public python-tinyhtml5
10194 (package
10195 (name "python-tinyhtml5")
10196 (version "2.1.0")
10197 (source
10198 (origin
10199 (method git-fetch)
10200 (uri (git-reference
10201 (url "https://github.com/CourtBouillon/tinyhtml5")
10202 (commit version)))
10203 (file-name (git-file-name name version))
10204 (sha256
10205 (base32 "1q8z2ym2q6083ky0f9vwf73k3gimffnbfwlpmd69bp6anc4fa81x"))))
10206 (build-system pyproject-build-system)
10207 (propagated-inputs
10208 (list python-webencodings))
10209 (native-inputs
10210 (list python-flit-core
10211 python-pytest))
10212 (home-page "https://github.com/CourtBouillon/tinyhtml5")
10213 (synopsis "Small HTML parser based on the WHATWG HTML specification")
10214 (description "This Python module is a HTML5 parser that transforms a
10215possibly malformed HTML document into an ElementTree tree. This module is a
10216simplified fork of html5lib.")
10217 (license license:expat)))
10218
10219(define-public python-cssselect2
10220 (package
10221 (name "python-cssselect2")
10222 (version "0.9.0")
10223 (source
10224 (origin
10225 (method git-fetch)
10226 (uri (git-reference
10227 (url "https://github.com/Kozea/cssselect2")
10228 (commit version)))
10229 (file-name (git-file-name name version))
10230 (sha256
10231 (base32 "1drvb83siq9s6dygyhab6kzk2v2ib6cv51ls42p4jrxs9q8cdiw0"))))
10232 (build-system pyproject-build-system)
10233 (propagated-inputs
10234 (list python-tinycss2))
10235 (native-inputs
10236 (list python-flit-core
10237 python-pytest))
10238 (home-page "https://doc.courtbouillon.org/cssselect2/stable/")
10239 (synopsis "CSS selectors for Python ElementTree")
10240 (description "@code{cssselect2} is a straightforward implementation of
10241CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
10242ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
10243
10244Unlike the Python package @code{cssselect}, it does not translate selectors to
10245XPath and therefore does not have all the correctness corner cases that are
10246hard or impossible to fix in cssselect.")
10247 (license license:bsd-3)))
10248
10249(define-public python-uvloop
10250 (package
10251 (name "python-uvloop")
10252 (version "0.21.0")
10253 (source
10254 (origin
10255 (method url-fetch)
10256 (uri (pypi-uri "uvloop" version))
10257 (sha256
10258 (base32 "1qq46ym3ymzfn4j6fnykfmr1f4qnb7x7p15dlw37hi38v87jpw9v"))
10259 (modules '((guix build utils)))
10260 (snippet
10261 '(begin (delete-file-recursively "vendor")
10262 (delete-file "uvloop/loop.c")))))
10263 (build-system pyproject-build-system)
10264 (arguments
10265 (list
10266 #:test-flags
10267 ;; The tests are prone to get stuck. Use pytest-timeout’s --timeout flag
10268 ;; to get a meaningful idea about where.
10269 #~(list "--timeout=300"
10270 "--timeout-method=thread"
10271 "-k" (string-join
10272 (list
10273 ;; Timeout, because SIGINT cannot be sent to child.
10274 "not test_signals_sigint_pycode_continue"
10275 "test_signals_sigint_pycode_stop"
10276 "test_signals_sigint_uvcode"
10277 "test_signals_sigint_uvcode_two_loop_runs"
10278 ;; This test is racy and prone to get stuck on
10279 ;; various platforms, possibly a aiohttp issue:
10280 ;; https://github.com/MagicStack/uvloop/issues/412
10281 "test_remote_shutdown_receives_trailing_data"
10282 ;; It looks like pytest is preventing
10283 ;; custom stdout/stderr redirection,
10284 ;; even with -s.
10285 "test_process_streams_redirect"
10286 ;; FileNotFoundError: [Errno 2] No such file or
10287 ;; directory
10288 "test_process_env_2"
10289 ;; socket.gaierror: [Errno -2] Name or service not known
10290 "test_getaddrinfo_21"
10291 #$@(if (target-riscv64?)
10292 `("test_renegotiation")
10293 `()))
10294 " and not "))
10295 #:phases
10296 #~(modify-phases %standard-phases
10297 (add-after 'unpack 'preparations
10298 (lambda _
10299 ;; Use packaged libuv.
10300 (substitute* "setup.py" (("self.use_system_libuv = False")
10301 "self.use_system_libuv = True"))
10302 ;; Replace hardcoded shell command.
10303 (substitute* "uvloop/loop.pyx"
10304 (("b'/bin/sh'") (string-append "b'" (which "sh") "'")))))
10305 #$@(if (target-riscv64?)
10306 `((add-after 'unpack 'adjust-test-timeouts
10307 (lambda _
10308 (substitute* '("tests/test_tcp.py"
10309 "tests/test_unix.py")
10310 (("SSL_HANDSHAKE_TIMEOUT = 15\\.0")
10311 "SSL_HANDSHAKE_TIMEOUT = 30.0")))))
10312 '())
10313 (add-before 'check 'pre-check
10314 (lambda* (#:key tests? #:allow-other-keys)
10315 (when tests?
10316 ;; Remove Python module, which conflicts with the installed
10317 ;; version, but lacks the built C module.
10318 (delete-file-recursively "uvloop")))))))
10319 (native-inputs
10320 (list python-aiohttp
10321 python-cython
10322 python-psutil
10323 python-pyopenssl
10324 python-pytest
10325 python-pytest-timeout
10326 python-setuptools
10327 python-wheel))
10328 (inputs
10329 (list libuv))
10330 (home-page "https://github.com/MagicStack/uvloop")
10331 (synopsis "Fast implementation of asyncio event loop on top of libuv")
10332 (description
10333 "@code{uvloop} is a fast, drop-in replacement of the built-in asyncio
10334event loop. It is implemented in Cython and uses libuv under the hood.")
10335 (license license:expat)))
10336
10337(define-public gunicorn
10338 (package
10339 (name "gunicorn")
10340 (version "25.3.0")
10341 (source
10342 (origin
10343 (method url-fetch)
10344 (uri (pypi-uri "gunicorn" version))
10345 (sha256
10346 (base32
10347 "12g85w735s4dszjfidi4vh786rfxsa5rd60il0fcvxknkwpinkpp"))))
10348 (outputs '("out" "doc"))
10349 (build-system pyproject-build-system)
10350 (arguments
10351 `(#:test-flags
10352 ;; Disable the geventlet tests because eventlet uses dnspython, which
10353 ;; does not work in the build container due to lack of /etc/resolv.conf
10354 '("--ignore=tests/workers/test_geventlet.py")
10355 #:phases (modify-phases %standard-phases
10356 ;; XXX: The wrap phase includes native inputs on PYTHONPATH, (see
10357 ;; <https://bugs.gnu.org/25235>), leading to an inflated closure
10358 ;; size. Override it to only add the essential entries.
10359 (replace 'wrap
10360 (lambda* (#:key native-inputs inputs outputs
10361 #:allow-other-keys)
10362 (let* ((out (assoc-ref outputs "out"))
10363 (python (assoc-ref (or native-inputs inputs)
10364 "python"))
10365 (sitedir (string-append "/lib/python"
10366 (python-version python)
10367 "/site-packages")))
10368 (wrap-program (string-append out "/bin/gunicorn")
10369 `("PYTHONPATH" ":" prefix
10370 ,(map (lambda (output)
10371 (string-append output sitedir))
10372 (list python out))))))))))
10373 (inputs (list bash-minimal))
10374 (native-inputs
10375 (list binutils ;for ctypes.util.find_library()
10376 python-eventlet
10377 python-gevent
10378 python-h2
10379 python-httpx
10380 python-pytest
10381 python-pytest-asyncio
10382 python-setuptools
10383 python-uvloop))
10384 (propagated-inputs
10385 (list python-packaging
10386 python-setuptools
10387 python-wheel))
10388 (home-page "https://gunicorn.org/")
10389 (synopsis "Python WSGI HTTP Server for UNIX")
10390 (description
10391 "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
10392Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
10393Unicorn project. The Gunicorn server is broadly compatible with
10394various web frameworks, simply implemented, light on server resources,
10395and fairly speedy.")
10396 (license license:expat)))
10397
10398;; break cyclic dependency for python-aiohttp, which depends on gunicorn for
10399;; its tests
10400(define-public gunicorn-bootstrap
10401 (package
10402 (inherit gunicorn)
10403 (name "gunicorn")
10404 (arguments `(#:tests? #f))
10405 (properties '((hidden? . #t)))
10406 (native-inputs `())))
10407
10408(define-public python-httptools
10409 (package
10410 (name "python-httptools")
10411 (version "0.7.1")
10412 (source
10413 (origin
10414 ;; PyPI tarball comes with a vendored http-parser and no tests.
10415 (method git-fetch)
10416 (uri (git-reference
10417 (url "https://github.com/MagicStack/httptools")
10418 (commit (string-append "v" version))))
10419 (file-name (git-file-name name version))
10420 (sha256
10421 (base32 "0j9c1av3y1smg6lgh0i031l07i9plzbvv14jj53vpzm35sy7kbl7"))
10422 (modules '((guix build utils)))
10423 (snippet
10424 #~(begin (delete-file-recursively "vendor")))))
10425 (build-system pyproject-build-system)
10426 (arguments
10427 (list
10428 #:test-flags
10429 ;; XXX: AssertionError: HttpParserError not raised.
10430 #~(list "-k" "not test_parser_response_leninent_headers_1")
10431 #:phases
10432 #~(modify-phases %standard-phases
10433 (add-after 'unpack 'configure-build-ext
10434 (lambda _
10435 (with-output-to-file "setup.cfg"
10436 (lambda ()
10437 (display "\
10438[build_ext]
10439use_system_llhttp = true
10440use_system_http_parser = true
10441cython_always = true"))))))))
10442 (native-inputs
10443 (list python-cython
10444 python-pytest
10445 python-setuptools))
10446 (inputs
10447 (list http-parser
10448 llhttp))
10449 (home-page "https://github.com/MagicStack/httptools")
10450 (synopsis "Collection of framework independent HTTP protocol utils")
10451 (description
10452 "@code{httptools} is a Python binding for the nodejs HTTP parser.")
10453 (license license:expat)))
10454
10455(define-public python-uvicorn
10456 (package
10457 (name "python-uvicorn")
10458 (version "0.40.0")
10459 (source
10460 (origin
10461 (method git-fetch)
10462 (uri (git-reference
10463 (url "https://github.com/encode/uvicorn")
10464 (commit version)))
10465 (file-name (git-file-name name version))
10466 (sha256
10467 (base32 "0laplrb2sf9jxv4prhrsqf8kpynipqml2idqq4fr7ikij8qsz6b2"))))
10468 (build-system pyproject-build-system)
10469 (arguments
10470 (list
10471 #:test-flags
10472 #~(list "-o" "asyncio_mode=auto"
10473 ;; After tests have been passed successfully some sockets leave
10474 ;; unclosed, causing Pytest to raise warning on teardown.
10475 "-W" "ignore::ResourceWarning"
10476 "-W" "ignore::pytest.PytestUnraisableExceptionWarning"
10477 ;; For some reason tests stacked in infinity re-invocation loop:
10478 ;; AssertionError where is_alive =
10479 ;; <uvicorn.supervisors.multiprocess.Process object at
10480 ;; 0x7ffff39b6110>.is_alive.
10481 ;; Maybe this <https://github.com/encode/uvicorn/issues/2466>.
10482 "--ignore=tests/supervisors/test_multiprocess.py"
10483
10484 #$@(cond
10485 ((or (target-aarch64?)
10486 (target-riscv64?))
10487 '("-k not test_send_binary_data_to_server_bigger_than_default_on_websockets"))
10488 (#t '())))))
10489 (native-inputs
10490 (list nss-certs-for-test
10491 python-a2wsgi
10492 python-hatchling
10493 python-httpx-bootstrap
10494 python-pytest
10495 python-pytest-asyncio
10496 python-pytest-mock
10497 python-pytest-xdist
10498 python-requests
10499 python-trustme
10500 python-wsproto))
10501 (propagated-inputs
10502 (list python-a2wsgi
10503 python-click
10504 python-dotenv
10505 python-h11
10506 python-httptools
10507 python-pyyaml
10508 python-uvloop
10509 python-watchfiles
10510 python-websockets))
10511 (home-page "https://github.com/encode/uvicorn")
10512 (synopsis "Fast ASGI server implementation")
10513 (description
10514 "@code{uvicorn} is a fast ASGI server implementation, using @code{uvloop}
10515and @code{httptools}. It currently supports HTTP/1.1 and WebSockets. Support
10516for HTTP/2 is planned.")
10517 (license license:bsd-3)))
10518
10519(define-public python-translation-finder
10520 (package
10521 (name "python-translation-finder")
10522 (version "2.22")
10523 (source
10524 (origin
10525 (method url-fetch)
10526 (uri (pypi-uri "translation_finder" version))
10527 (sha256
10528 (base32 "1hav99ccijvk2w8wpvba2pc7ba1z150vja2wvaimd069mc08pjd2"))))
10529 (build-system pyproject-build-system)
10530 (arguments
10531 (list
10532 #:test-flags
10533 ;; AssertionError: 31 != 30 : Mismatched count of results
10534 #~(list "--deselect=translation_finder/test_api.py::APITest::test_discover_file")))
10535 (native-inputs
10536 (list python-pytest
10537 python-setuptools))
10538 (propagated-inputs
10539 (list python-charset-normalizer
10540 python-ruamel.yaml
10541 python-weblate-language-data))
10542 (home-page "https://weblate.org/")
10543 (synopsis "Translation file finder for Weblate")
10544 (description "This package provides a function to find translation file in
10545the source code of a project. It supports many translation file formats and
10546is part of the Weblate translation platform.")
10547 (license license:gpl3+)))
10548
10549(define-public python-gitlab
10550 (package
10551 (name "python-gitlab")
10552 (version "7.0.0")
10553 (source
10554 (origin
10555 (method git-fetch)
10556 (uri (git-reference
10557 (url "https://github.com/python-gitlab/python-gitlab")
10558 (commit (string-append "v" version))))
10559 (file-name (git-file-name name version))
10560 (sha256
10561 (base32 "0rf1hz5n724f8sfc7g3fzfz96jsv9y145pi6gc8qscsjq3z4vi37"))))
10562 (build-system pyproject-build-system)
10563 (arguments
10564 (list
10565 #:test-flags
10566 #~(list "--ignore=tests/unit/test_graphql.py"
10567 ;; XXX: Missing helper script.
10568 "-k" "not test_data_from_helper" "tests/unit")))
10569 (native-inputs
10570 (list python-anyio
10571 python-pytest
10572 python-responses
10573 python-setuptools))
10574 (propagated-inputs (list python-requests python-requests-toolbelt))
10575 (home-page "https://github.com/python-gitlab/python-gitlab")
10576 (synopsis "Interact with GitLab API")
10577 (description "This package provides an extended library for interacting
10578with GitLab instances through their API.")
10579 (license license:lgpl3+)))
10580
10581(define-public python-path-and-address
10582 (package
10583 (name "python-path-and-address")
10584 (version "2.0.1")
10585 (source
10586 (origin
10587 (method git-fetch)
10588 (uri (git-reference
10589 (url "https://github.com/joeyespo/path-and-address")
10590 (commit (string-append "v" version))))
10591 (file-name (git-file-name name version))
10592 (sha256
10593 (base32 "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6"))))
10594 (build-system pyproject-build-system)
10595 (native-inputs
10596 (list python-pytest python-setuptools))
10597 (home-page "https://github.com/joeyespo/path-and-address")
10598 (synopsis "Functions for command-line server tools used by humans")
10599 (description "Path-and-address resolves ambiguities of command-line
10600interfaces, inferring which argument is the path, and which is the address.")
10601 (license license:expat)))
10602
10603;; XXX: This project missed maintainer upstream, see
10604;; <https://github.com/joeyespo/grip/issues/387>.
10605;; Consider to remove if it keeps failing to build.
10606(define-public grip
10607 (package
10608 (name "grip")
10609 (version "4.6.1")
10610 (source
10611 (origin
10612 (method git-fetch)
10613 (uri (git-reference
10614 (url "https://github.com/joeyespo/grip")
10615 (commit (string-append "v" version))))
10616 (file-name (git-file-name name version))
10617 (sha256
10618 (base32 "0vhimd99zw7s1fihwr6yfij6ywahv9gdrfcf5qljvzh75mvzcwh8"))))
10619 (build-system pyproject-build-system)
10620 (arguments
10621 (list
10622 #:test-flags
10623 ;; All tests fail requiring network access, ignore the whole file.
10624 #~(list "--ignore=tests/test_github.py")
10625 #:phases
10626 #~(modify-phases %standard-phases
10627 ;; This fixes the removal of `charset` attribute of requests from
10628 ;; Werkzeug 2.3.0.
10629 ;; Fixed in grip's commit <2784eb2c1515f1cdb1554d049d48b3bff0f42085>.
10630 (add-after 'unpack 'fix-response-encoding
10631 (lambda _
10632 (substitute* "grip/app.py"
10633 (("response.charset")
10634 "getattr(response, 'charset', 'utf-8')")))))))
10635 (native-inputs
10636 (list nss-certs-for-test
10637 python-pytest
10638 python-responses
10639 python-setuptools
10640 python-wheel))
10641 (propagated-inputs
10642 (list python-docopt
10643 python-flask
10644 python-markdown
10645 python-path-and-address
10646 python-pygments
10647 python-requests))
10648 (home-page "https://github.com/joeyespo/grip")
10649 (synopsis "Preview Markdown files using the GitHub API")
10650 (description
10651 "Grip is a command-line server application written in Python that uses
10652the GitHub Markdown API to render a local Markdown file. The styles and
10653rendering come directly from GitHub, so you'll know exactly how it will
10654appear. Changes you make to the file will be instantly reflected in the
10655browser without requiring a page refresh.")
10656 (license license:expat)))
10657
10658(define-public python-port-for
10659 (package
10660 (name "python-port-for")
10661 (version "0.7.4")
10662 (source
10663 (origin
10664 (method url-fetch)
10665 (uri (pypi-uri "port_for" version))
10666 (sha256
10667 (base32 "13826s2d4hzzmv69wws6a7ryhminclv2bqaw6cpl929gnbki6xzw"))))
10668 (build-system pyproject-build-system)
10669 (propagated-inputs
10670 (list python-urllib3))
10671 (native-inputs
10672 (list python-pytest python-setuptools python-wheel))
10673 (home-page "https://github.com/kmike/port-for/")
10674 (synopsis "TCP localhost port finder and association manager")
10675 (description
10676 "This package provides a utility that helps with local TCP ports
10677management. It can find an unused TCP localhost port and remember the
10678association.")
10679 (license license:expat)))
10680
10681(define-public python-livereload
10682 (package
10683 (name "python-livereload")
10684 (version "2.7.1")
10685 (source
10686 (origin
10687 (method git-fetch)
10688 (uri (git-reference
10689 (url "https://github.com/lepture/python-livereload")
10690 (commit (string-append "v" version))))
10691 (file-name (git-file-name name version))
10692 (sha256
10693 (base32 "19wkdd1grw6mcd4qi8iaw4jdr207h3m24951vgy69j7g904lynjq"))))
10694 (build-system pyproject-build-system)
10695 (arguments (list #:test-backend #~'unittest))
10696 (native-inputs (list python-django python-setuptools))
10697 (propagated-inputs (list python-tornado))
10698 (home-page "https://github.com/lepture/python-livereload")
10699 (synopsis "Python LiveReload")
10700 (description
10701 "Python LiveReload provides a command line utility, @command{livereload},
10702for starting a web server in a directory. It can trigger arbitrary commands
10703and serve updated contents upon changes to the directory.")
10704 (license license:bsd-3)))
10705
10706(define-public python-vf-1
10707 (package
10708 (name "python-vf-1")
10709 (version "1.0.0")
10710 (source
10711 (origin
10712 (method git-fetch)
10713 (uri (git-reference
10714 (url "https://git.sr.ht/~solderpunk/VF-1")
10715 (commit (string-append "v" version))))
10716 (file-name (git-file-name name version))
10717 (sha256
10718 (base32 "1j8l4xivm6rs8jms1ixx0i9fz4yxr84hbz1pdc498jgkgzy1v8ih"))))
10719 (build-system pyproject-build-system)
10720 (arguments (list #:tests? #f)) ; No tests.
10721 (native-inputs (list python-setuptools))
10722 (home-page "https://git.sr.ht/~solderpunk/VF-1")
10723 (synopsis "Command line gopher client")
10724 (description "@code{VF-1} is a command line gopher client with
10725@acronym{TLS, Transport Layer Security} support.")
10726 (license license:bsd-2)))
10727
10728(define-public python-httpcore
10729 (package
10730 (name "python-httpcore")
10731 (version "1.0.9")
10732 (source
10733 (origin
10734 ;; PyPI tarball does not contain tests.
10735 (method git-fetch)
10736 (uri (git-reference
10737 (url "https://github.com/encode/httpcore")
10738 (commit version)))
10739 (file-name (git-file-name name version))
10740 (sha256
10741 (base32 "0yhm2n8qflpwjsjggyj757m0gw3n68al0my0ljybndwp933ipl32"))))
10742 (build-system pyproject-build-system)
10743 (native-inputs
10744 (list nss-certs-for-test
10745 python-hatch-fancy-pypi-readme
10746 python-hatchling
10747 python-pytest
10748 python-pytest-asyncio
10749 python-pytest-httpbin
10750 python-pytest-trio
10751 python-uvicorn
10752 python-trustme))
10753 (propagated-inputs
10754 (list python-anyio
10755 python-certifi
10756 python-h11
10757 python-h2
10758 python-sniffio
10759 python-socksio
10760 python-trio
10761 python-trio-typing))
10762 (home-page "https://github.com/encode/httpcore")
10763 (synopsis "Minimal, low-level HTTP client")
10764 (description
10765 "HTTP Core provides a minimal and low-level HTTP client, which does one
10766thing only: send HTTP requests.
10767
10768Some things HTTP Core does do:
10769
10770@itemize
10771@item Sending HTTP requests.
10772@item Provides both sync and async interfaces.
10773@item Supports HTTP/1.1 and HTTP/2.
10774@item Async backend support for asyncio and trio.
10775@item Automatic connection pooling.
10776@item HTTP(S) proxy support.
10777@end itemize")
10778 (license license:bsd-3)))
10779
10780;;; Variant used to break a cycle between python-httpx and python-uvicorn.
10781(define-public python-httpcore-bootstrap
10782 (hidden-package
10783 (package/inherit python-httpcore
10784 (name "python-httpcore-bootstrap")
10785 (arguments (list #:tests? #f))
10786 (native-inputs (list python-hatchling
10787 python-hatch-fancy-pypi-readme)))))
10788
10789(define-public python-httpx
10790 (package
10791 (name "python-httpx")
10792 (version "0.28.1")
10793 (source
10794 (origin
10795 ;; PyPI tarball does not contain tests.
10796 (method git-fetch)
10797 (uri (git-reference
10798 (url "https://github.com/encode/httpx")
10799 (commit version)))
10800 (file-name (git-file-name name version))
10801 (sha256
10802 (base32 "00d6rb21xwazwb0sj68zhra0qxxcwkd0vv7bg3k1jg94dmk2w7xl"))))
10803 (build-system pyproject-build-system)
10804 (arguments
10805 (list
10806 ;; 1401 passed, 1 skipped, 5 deselected
10807 #:test-flags
10808 #~(list "-o" "asyncio_mode=auto"
10809 ;; CLI tests are broken.
10810 "--ignore=tests/test_main.py"
10811 "-k" (string-join
10812 ;; These tests try to open an outgoing connection.
10813 (list "not test_async_proxy_close"
10814 "test_sync_proxy_clos"
10815 "test_write_timeout")
10816 " and not "))))
10817 (native-inputs
10818 (list nss-certs-for-test
10819 python-chardet
10820 python-cryptography
10821 python-hatch-fancy-pypi-readme
10822 python-hatchling
10823 python-pytest
10824 python-pytest-asyncio
10825 python-pytest-trio
10826 python-setuptools
10827 python-trio
10828 python-trustme
10829 python-uvicorn))
10830 (propagated-inputs
10831 (list python-anyio
10832 python-certifi
10833 python-httpcore
10834 python-idna
10835 ;; [brotli]
10836 python-brotli
10837 ;; [http2]
10838 python-h2
10839 ;; [socks]
10840 python-socksio
10841 ;; [zstd]
10842 python-zstandard
10843 ;; For trio, see:
10844 ;; <https://github.com/python-trio/trio/issues/2802>.
10845 python-sniffio))
10846 (home-page "https://www.python-httpx.org/")
10847 (synopsis "HTTP client for Python")
10848 (description
10849 "HTTPX is a fully featured HTTP client for Python 3, which provides sync
10850and async APIs, and support for both HTTP/1.1 and HTTP/2.
10851
10852HTTPX builds on the well-established usability of requests, and gives you:
10853
10854@itemize
10855@item A broadly requests-compatible API.
10856@item Standard synchronous interface, but with async support if you need it.
10857@item HTTP/1.1 and HTTP/2 support.
10858@item Ability to make requests directly to WSGI applications or ASGI applications.
10859@item Strict timeouts everywhere.
10860@item Fully type annotated.
10861@item 99% test coverage.
10862@end itemize
10863
10864Plus all the standard features of requests:
10865
10866@itemize
10867@item International Domains and URLs
10868@item Keep-Alive & Connection Pooling
10869@item Sessions with Cookie Persistence
10870@item Browser-style SSL Verification
10871@item Basic/Digest Authentication
10872@item Elegant Key/Value Cookies
10873@item Automatic Decompression
10874@item Automatic Content Decoding
10875@item Unicode Response Bodies
10876@item Multipart File Uploads
10877@item HTTP(S) Proxy Support
10878@item Connection Timeouts
10879@item Streaming Downloads
10880@item .netrc Support
10881@item Chunked Requests
10882@end itemize")
10883 (license license:bsd-3)))
10884
10885;;; Variant used to break a cycle with python-uvicorn.
10886(define-public python-httpx-bootstrap
10887 (hidden-package
10888 (package/inherit python-httpx
10889 (name "python-httpx-bootstrap")
10890 (arguments (list #:tests? #f))
10891 (native-inputs
10892 (list python-hatchling
10893 python-hatch-fancy-pypi-readme))
10894 (propagated-inputs
10895 (modify-inputs propagated-inputs
10896 (replace "python-httpcore" python-httpcore-bootstrap))))))
10897
10898(define-public python-httpx-sse
10899 (package
10900 (name "python-httpx-sse")
10901 (version "0.4.3")
10902 (source
10903 (origin
10904 (method git-fetch)
10905 (uri (git-reference
10906 (url "https://github.com/florimondmanca/httpx-sse")
10907 (commit version)))
10908 (file-name (git-file-name name version))
10909 (sha256
10910 (base32 "0zliqd1rkvc0mjppscvqmg8j17hsiwvxn439yhn6qbjvk5ydncz8"))))
10911 (build-system pyproject-build-system)
10912 (native-inputs
10913 (list python-pytest
10914 python-pytest-asyncio
10915 python-setuptools
10916 python-setuptools-scm
10917 python-sse-starlette))
10918 (propagated-inputs (list python-httpx))
10919 (home-page "https://github.com/florimondmanca/httpx-sse")
10920 (synopsis "Consume Server-Sent Event (SSE) messages with HTTPX.")
10921 (description "Consume Server-Sent Event (SSE) messages with HTTPX.")
10922 (license license:expat)))
10923
10924(define-public python-httpx-ws
10925 (package
10926 (name "python-httpx-ws")
10927 (version "0.9.0")
10928 (source
10929 (origin
10930 (method git-fetch)
10931 (uri (git-reference
10932 (url "https://github.com/frankie567/httpx-ws")
10933 (commit (string-append "v" version))))
10934 (file-name (git-file-name name version))
10935 (sha256
10936 (base32 "1hin6fndvfnx3mjgy30x0ghgjalikxavyj24klcknnly9sqzg83v"))))
10937 (build-system pyproject-build-system)
10938 (propagated-inputs
10939 (list python-anyio
10940 python-httpcore
10941 python-httpx
10942 python-wsproto))
10943 (native-inputs
10944 (list nss-certs-for-test
10945 python-hatch-regex-commit
10946 python-hatchling
10947 python-pytest
10948 python-pytest-cov
10949 python-starlette
10950 python-uvicorn))
10951 (home-page "https://github.com/frankie567/httpx-ws")
10952 (synopsis "WebSockets support for HTTPX")
10953 (description "This package provides @code{WebSockets} support for HTTPX.")
10954 (license license:expat)))
10955
10956(define-public python-wsgiprox
10957 (package
10958 (name "python-wsgiprox")
10959 (version "1.5.2")
10960 (source
10961 (origin
10962 (method url-fetch)
10963 (uri (pypi-uri "wsgiprox" version))
10964 (sha256
10965 (base32 "11fsm199pvwbmqx2lccznvws65aam1rqqv0w79gal8hispwgd5rs"))))
10966 (build-system pyproject-build-system)
10967 (arguments
10968 ;; The test suite hangs (see:
10969 ;; https://github.com/webrecorder/wsgiprox/issues/6).
10970 (list
10971 #:tests? #f
10972 #:phases
10973 #~(modify-phases %standard-phases
10974 (add-after 'unpack 'fix-pytest-argument
10975 (lambda _
10976 ;; See: https://github.com/webrecorder/wsgiprox/issues/7.
10977 (substitute* "setup.py"
10978 (("--doctest-module")
10979 "--doctest-modules")))))))
10980 (propagated-inputs
10981 (list python-certauth python-gevent python-websocket-client))
10982 (native-inputs
10983 (list python-mock python-waitress python-setuptools))
10984 (home-page "https://github.com/webrecorder/wsgiprox")
10985 (synopsis "HTTP/S proxy with WebSockets over WSGI")
10986 (description
10987 "@code{wsgiprox} is a Python WSGI (Web Server Gateway Interface)
10988middle-ware for adding HTTP and HTTPS proxy support to a WSGI application.
10989The library accepts HTTP and HTTPS proxy connections, and routes them to a
10990designated prefix.")
10991 (license license:asl2.0)))
10992
10993(define-public python-warcio
10994 ;; The PyPI release is missing some test support files (see:
10995 ;; https://github.com/webrecorder/warcio/issues/132).
10996 (package
10997 (name "python-warcio")
10998 (version "1.8.1")
10999 (source
11000 (origin
11001 (method git-fetch)
11002 (uri (git-reference
11003 (url "https://github.com/webrecorder/warcio")
11004 (commit (string-append "v" version))))
11005 (file-name (git-file-name name version))
11006 (sha256
11007 (base32
11008 "19wwg7zmx33c942dbahdkng1byiwr4c9cd1ayrsh13f818n17zps"))))
11009 (build-system pyproject-build-system)
11010 (arguments
11011 (list
11012 #:test-flags ; These tests fail due to networking requirements.
11013 '(list "-k" (format #f "not ~a"
11014 (string-join
11015 '("test_post_chunked"
11016 "test_remote"
11017 "test_capture_http_proxy"
11018 "test_capture_https_proxy"
11019 "test_capture_https_proxy_same_session")
11020 " and not "))
11021 ; The following test requires the hookdns package.
11022 "--ignore=test/test_capture_http_proxy.py")))
11023 (native-inputs
11024 (list python-httpbin
11025 python-pytest
11026 python-requests
11027 python-setuptools
11028 python-wsgiprox))
11029 (home-page "https://github.com/webrecorder/warcio")
11030 (synopsis "Streaming web archival archive (WARC) library")
11031 (description "warcio is a Python library to read and write the WARC format
11032commonly used in Web archives. It is designed for fast, low-level access to
11033web archival content, oriented around a stream of WARC records rather than
11034files.")
11035 (license license:asl2.0)))
11036
11037(define-public python-websockets
11038 (package
11039 (name "python-websockets")
11040 (version "13.1")
11041 (source
11042 (origin
11043 (method git-fetch)
11044 (uri (git-reference
11045 (url "https://github.com/aaugustin/websockets")
11046 (commit version)))
11047 (file-name (git-file-name name version))
11048 (sha256
11049 (base32
11050 "1dx3rf6fmg4ir9cfcn1fil446qz879cwrjq2rcz5zvl71xkw6hb3"))))
11051 (build-system pyproject-build-system)
11052 (arguments
11053 (list #:test-backend #~'unittest
11054 #:phases
11055 #~(modify-phases %standard-phases
11056 (add-before 'check 'extend-test-timeout
11057 (lambda _
11058 ;; Some architectures need an even longer timeout. Make it
11059 ;; long enough that it should never fail due to timeout.
11060 #$@(if (target-riscv64?)
11061 #~((setenv "WEBSOCKETS_TESTS_TIMEOUT_FACTOR" "100"))
11062 #~((setenv "WEBSOCKETS_TESTS_TIMEOUT_FACTOR" "10"))))))))
11063 (native-inputs
11064 (list python-setuptools
11065 python-wheel))
11066 (home-page "https://github.com/aaugustin/websockets")
11067 (synopsis
11068 "Python implementation of the WebSocket Protocol (RFC 6455 & 7692)")
11069 (description
11070 "@code{websockets} is a library for building WebSocket servers and clients
11071in Python with a focus on correctness and simplicity.
11072
11073Built on top of @code{asyncio}, Python's standard asynchronous I/O framework,
11074it provides an elegant coroutine-based API.")
11075 (license license:bsd-3)))
11076
11077(define-public selenium-manager
11078 (package
11079 (name "selenium-manager")
11080 (version "4.34.2")
11081 (source
11082 (origin
11083 (method git-fetch)
11084 (uri (git-reference
11085 (url "https://github.com/SeleniumHQ/selenium")
11086 (commit (string-append "selenium-" version "-python"))))
11087 (file-name (git-file-name name version))
11088 (sha256
11089 (base32 "14fg8r4rm9d7169rlm29l5yn08wgllmqk1zc6six3dlrzzf5mxil"))))
11090 (build-system cargo-build-system)
11091 (arguments
11092 (list
11093 ;; XXX: Almost all tests require either browsers or network access.
11094 #:tests? #f
11095 #:install-source? #f ; Most likely intended as a leaf.
11096 #:phases
11097 #~(modify-phases %standard-phases
11098 (add-after 'unpack 'chdir
11099 (lambda _
11100 (chdir "rust"))))))
11101 (native-inputs (list pkg-config))
11102 (inputs (cons* (list zstd "lib") xz
11103 (cargo-inputs 'selenium-manager)))
11104 (home-page "https://www.selenium.dev")
11105 (synopsis "CLI tool to manager the browser test infrastructure")
11106 (description
11107 "Selenium simplifies web browser automation. It specifically provides
11108infrastructure for the W3C WebDriver specification — a platform and
11109language-neutral coding interface compatible with all major web browsers.
11110
11111Selenium Manager is a CLI tool that automatically manages the browser/driver
11112infrastructure required by Selenium.")
11113 (license license:asl2.0)))
11114
11115(define-public python-selenium
11116 (package/inherit selenium-manager
11117 (name "python-selenium")
11118 (build-system pyproject-build-system)
11119 (arguments
11120 (list
11121 ;; XXX: Disable failing tests.
11122 #:test-flags
11123 #~(list "--ignore-glob=test/selenium/webdriver/*"
11124 ;; Probably requires those.
11125 "--ignore-glob=test/unit/selenium/webdriver/chrome/*"
11126 "--ignore-glob=test/unit/selenium/webdriver/firefox/*"
11127 ;; XXX: SSL certificates access.
11128 "--ignore=test/unit/selenium/webdriver/remote/remote_connection_tests.py"
11129 "-k" "not test_missing_cdp_devtools_version_falls_back")
11130 #:phases
11131 #~(modify-phases %standard-phases
11132 (add-after 'unpack 'chdir
11133 (lambda _
11134 (chdir "py")))
11135 (add-after 'chdir 'inject-selenium-manager-binary
11136 (lambda* (#:key inputs #:allow-other-keys)
11137 (substitute* "selenium/webdriver/common/selenium_manager.py"
11138 (("compiled_path = Path.*")
11139 (format #f "return Path(~s)~%"
11140 (search-input-file inputs "bin/selenium-manager"))))
11141 (substitute* "pyproject.toml"
11142 (("\\[\\[tool\\.setuptools-rust\\.bins\\]\\]")
11143 "")
11144 (("target = \"selenium\\.webdriver\\.common.*\"")
11145 ""))))
11146 (add-after 'chdir 'relax-requirements
11147 (lambda _
11148 (substitute* "pyproject.toml"
11149 (("\"(typing_extensions|trio)~=.*\"," _ target)
11150 (format #f "~s," target))))))))
11151 (propagated-inputs (list python-certifi
11152 python-trio
11153 python-trio-websocket
11154 python-typing-extensions
11155 python-urllib3
11156 python-websocket-client))
11157 (inputs (list selenium-manager))
11158 (native-inputs (list python-filetype
11159 python-pytest
11160 python-pytest-mock
11161 python-pytest-trio
11162 python-setuptools
11163 python-setuptools-rust))
11164 (synopsis "Python bindings for Selenium")
11165 (description
11166 "Selenium enables web browser automation. It specifically provides
11167infrastructure for the W3C WebDriver specification — a platform and
11168language-neutral coding interface compatible with all major web browsers.")))
11169
11170(define-public python-rapidjson
11171 (package
11172 (name "python-rapidjson")
11173 (version "1.23")
11174 (source
11175 (origin
11176 (method git-fetch)
11177 (uri (git-reference
11178 (url "https://github.com/python-rapidjson/python-rapidjson")
11179 (commit (string-append "v" version))))
11180 (file-name (git-file-name name version))
11181 (sha256
11182 (base32 "0ajf919gg3qmi68jb0m6v80al2n65cn2ac36qz46s0h6zh92cl86"))
11183 (modules '((guix build utils)))
11184 (snippet
11185 '(delete-file-recursively "rapidjson"))))
11186 (build-system pyproject-build-system)
11187 (arguments
11188 (list
11189 #:test-flags '(list "tests")
11190 #:phases
11191 #~(modify-phases %standard-phases
11192 ;; We cannot seem to use #:configure-flags with the
11193 ;; pyproject-build-system to override rj_include_dir.
11194 (add-after 'unpack 'override-rapidjson-sources
11195 (lambda _
11196 (substitute* "setup.py"
11197 (("^rj_include_dir =.*")
11198 (string-append "rj_include_dir = '"
11199 #$(this-package-native-input "rapidjson")
11200 "/include/rapidjson" "'"))
11201 (("if not os.path.isdir.*") "if False:")))))))
11202 (native-inputs
11203 (list rapidjson python-pytest python-pytz python-setuptools))
11204 (home-page "https://github.com/python-rapidjson/python-rapidjson")
11205 (synopsis "Python wrapper around rapidjson")
11206 (description "This package provides a python wrapper around rapidjson.")
11207 (license license:expat)))
11208
11209(define-public python-venusian
11210 (package
11211 (name "python-venusian")
11212 (version "3.1.1")
11213 (source
11214 (origin
11215 (method url-fetch)
11216 (uri (pypi-uri "venusian" version))
11217 (sha256
11218 (base32 "0h8cdwx5x6i1ydc9s0hxwvy73l6iwlqijn2l77mq74k6anrv6ksk"))))
11219 (build-system pyproject-build-system)
11220 (native-inputs
11221 (list python-pytest
11222 python-setuptools))
11223 (home-page "https://docs.pylonsproject.org/projects/venusian")
11224 (synopsis "Library for deferring decorator actions")
11225 (description
11226 "Venusian is a library which allows framework authors to defer decorator
11227actions. Instead of taking actions when a function (or class) decorator is
11228executed at import time, you can defer the action usually taken by the
11229decorator until a separate scan phase.")
11230 (license license:repoze)))
11231
11232(define-public python-zope-deprecation
11233 (package
11234 (name "python-zope-deprecation")
11235 (version "6.0")
11236 (source (origin
11237 (method url-fetch)
11238 (uri (pypi-uri "zope_deprecation" version))
11239 (sha256
11240 (base32
11241 "0pzimp7xr8m0836bbsrx8wa9ybl58s5hwacas95nsfp6m2ypwwhq"))))
11242 (build-system pyproject-build-system)
11243 (arguments
11244 (list #:tests? #f)) ;no tests in PyPI
11245 (native-inputs
11246 (list python-setuptools))
11247 (home-page "https://zopedeprecation.readthedocs.io/")
11248 (synopsis "Function for marking deprecations")
11249 (description "The @code{zope.deprecation} module provides a function for
11250marking modules, classes, functions, methods and properties as deprecated,
11251displaying warnings when usaged in application code.")
11252 (license license:zpl2.1)))
11253
11254(define-public python-translationstring
11255 (package
11256 (name "python-translationstring")
11257 (version "1.4")
11258 (source (origin
11259 (method url-fetch)
11260 (uri (pypi-uri "translationstring" version))
11261 (sha256
11262 (base32
11263 "1wvncdzi1wj37x226qcf0yycz7js6l83na0pmc9blsbfsww7b55z"))))
11264 (build-system pyproject-build-system)
11265 (native-inputs
11266 (list python-pytest
11267 python-setuptools))
11268 (home-page "https://docs.pylonsproject.org/projects/translationstring")
11269 (synopsis "Internationalization tooling for the Pylons project")
11270 (description "This package provides a library used by various Pylons
11271project packages for internationalization (i18n) duties related to
11272translation.")
11273 (license license:repoze)))
11274
11275(define-public python-plaster
11276 (package
11277 (name "python-plaster")
11278 (version "1.1.2")
11279 (source (origin
11280 (method url-fetch)
11281 (uri (pypi-uri "plaster" version))
11282 (sha256
11283 (base32
11284 "167gfh0ahdll9m96ypgasji6yry2hkn9f0ml1b0lf4ccpxagrgpq"))))
11285 (build-system pyproject-build-system)
11286 (native-inputs
11287 (list python-pytest
11288 python-setuptools))
11289 (home-page "https://docs.pylonsproject.org/projects/plaster/en/latest/")
11290 (synopsis "Configuration loader for multiple config file formats")
11291 (description
11292 "Plaster is a loader interface around multiple config file formats. It
11293exists to define a common API for applications to use when they wish to load
11294configuration. The library itself does not aim to handle anything except a
11295basic API that applications may use to find and load configuration settings.
11296Any specific constraints should be implemented in a pluggable loader which can
11297be registered via an entrypoint.")
11298 (license license:repoze)))
11299
11300(define-public python-plaster-pastedeploy
11301 (package
11302 (name "python-plaster-pastedeploy")
11303 (version "1.0.1")
11304 (source (origin
11305 (method url-fetch)
11306 (uri (pypi-uri "plaster_pastedeploy" version))
11307 (sha256
11308 (base32
11309 "04hl71p76wnwiy195p5w51bn3c6ba0lgx8nsfm42d9s15rnjw9my"))))
11310 (build-system pyproject-build-system)
11311 (native-inputs
11312 (list python-pytest
11313 python-setuptools))
11314 (propagated-inputs
11315 (list python-plaster python-pastedeploy))
11316 (home-page "https://github.com/Pylons/plaster_pastedeploy")
11317 (synopsis "Plugin for python-plaster adding PasteDeploy syntax")
11318 (description
11319 "This plugin for @code{python-plaster} adds support for PasteDeploy
11320syntax, it provides a plaster @code{Loader} object that can parse ini files
11321according to the standard set by PasteDeploy")
11322 (license license:expat)))
11323
11324(define-public python-hupper
11325 (package
11326 (name "python-hupper")
11327 (version "1.12.1")
11328 (source
11329 (origin
11330 (method url-fetch)
11331 (uri (pypi-uri "hupper" version))
11332 (sha256
11333 (base32 "1srj7sqxdgxr0nnhh9lw8jmp64chwgg8iwfm9b4g9v7l1wbm9gq6"))))
11334 (build-system pyproject-build-system)
11335 (arguments
11336 (list
11337 ;; RuntimeError: timeout waiting for change to
11338 ;; file=/tmp/guix-build-python-hupper-1.12.1.drv-0/tmpm9n4697p
11339 #:test-flags #~(list "--ignore=tests/test_it.py")))
11340 (native-inputs
11341 (list python-pytest python-setuptools python-wheel))
11342 (propagated-inputs
11343 (list python-watchdog))
11344 (home-page "https://readthedocs.org/projects/hupper")
11345 (synopsis "Integrated process monitor tracking changes to imported Python files")
11346 (description
11347 "Hupper is an integrated process monitor that will track changes to any
11348imported Python files in sys.modules as well as custom paths. When files are
11349changed the process is restarted.")
11350 (license license:expat)))
11351
11352(define-public python-pyowm
11353 (package
11354 (name "python-pyowm")
11355 (version "3.3.0")
11356 (source
11357 (origin
11358 (method git-fetch)
11359 (uri (git-reference
11360 (url "https://github.com/csparpa/pyowm")
11361 (commit version)))
11362 (file-name (git-file-name name version))
11363 (sha256
11364 (base32
11365 "1ha4pp96y3jk33qnyir5851cnj4dc06q6wqn1b0w54l3fsds28vi"))))
11366 (build-system pyproject-build-system)
11367 (arguments (list #:test-flags #~(list "tests/unit")))
11368 (native-inputs (list python-pytest python-setuptools python-wheel))
11369 (propagated-inputs
11370 (list python-geojson-for-pyowm
11371 python-pysocks
11372 python-requests))
11373 (home-page "https://github.com/csparpa/pyowm")
11374 (synopsis "Python wrapper around OpenWeatherMap web APIs")
11375 (description
11376 "This package provides a Python wrapper around OpenWeatherMap web APIs.")
11377 (license license:expat)))
11378
11379(define-public python-pyramid
11380 (package
11381 (name "python-pyramid")
11382 (version "2.1")
11383 (source
11384 (origin
11385 (method git-fetch)
11386 (uri (git-reference
11387 (url "https://github.com/Pylons/pyramid")
11388 (commit version)))
11389 (file-name (git-file-name name version))
11390 (sha256
11391 (base32 "0my03b81009w9zqx5cdn9qixh0jah49hr0379n98kx2j3b8cfk1p"))))
11392 (build-system pyproject-build-system)
11393 (native-inputs
11394 (list python-pytest
11395 python-setuptools
11396 python-webtest
11397 python-zope-component))
11398 (propagated-inputs
11399 (list python-hupper
11400 python-plaster
11401 python-plaster-pastedeploy
11402 python-translationstring
11403 python-venusian
11404 python-webob
11405 python-zope-deprecation
11406 python-zope-interface))
11407 (home-page "https://trypyramid.com/")
11408 (synopsis "Python web-framework suitable for small and large sites")
11409 (description
11410 "Pyramid makes it easy to write web applications. From minimal
11411request/response web apps to larger, grown applications.")
11412 (license license:repoze)))
11413
11414(define-public python-pyramid-chameleon
11415 ;; PyPI lacks a fresh release, use the latest commit associated with
11416 ;; unrleased version, see:
11417 ;; <https://github.com/Pylons/pyramid_chameleon/issues/27>
11418 (let ((commit "956c77ba37120c430e871c834d3cd4ed5ac8dccf")
11419 (revision "0"))
11420 (package
11421 (name "python-pyramid-chameleon")
11422 (version (git-version "0.4.dev0" revision commit))
11423 (source
11424 (origin
11425 (method git-fetch)
11426 (uri (git-reference
11427 (url "https://github.com/Pylons/pyramid_chameleon")
11428 (commit commit)))
11429 (file-name (git-file-name name version))
11430 (sha256
11431 (base32 "0rsb921xi7736h1xikc904bq2zzmrj1g8qgyimjw5wxdcd8927b1"))))
11432 (build-system pyproject-build-system)
11433 (native-inputs
11434 (list python-pytest
11435 python-setuptools))
11436 (propagated-inputs
11437 (list python-chameleon
11438 python-pyramid))
11439 (home-page "https://github.com/Pylons/pyramid_chameleon")
11440 (synopsis "Chameleon template compiler for pyramid")
11441 (description
11442 "These package provides bindings for the Chameleon templating system
11443 for the Pyramid web framework.")
11444 (license license:repoze))))
11445
11446(define-public python-pyramid-debugtoolbar
11447 (package
11448 (name "python-pyramid-debugtoolbar")
11449 (version "4.12.1")
11450 (source
11451 (origin
11452 (method git-fetch)
11453 (uri (git-reference
11454 (url "https://github.com/Pylons/pyramid_debugtoolbar")
11455 (commit version)))
11456 (file-name (git-file-name name version))
11457 (sha256
11458 (base32 "0kalb5rsrlcz62zv9a39kp28mvwg9j6gymvzxbybdnvk51v9if56"))))
11459 (build-system pyproject-build-system)
11460 (arguments
11461 (list
11462 #:test-flags
11463 ;; Large diff assertion not equal faileurs.
11464 #~(list #$@(map (lambda (test)
11465 (string-append "--deselect=tests"
11466 "/test_panels/test_sqla.py::" test))
11467 (list "TestSimpleSelect::test_panel"
11468 "TestTransactionCommit::test_panel"
11469 "TestTransactionRollback::test_panel")))))
11470 (native-inputs
11471 (list python-pytest
11472 python-setuptools
11473 python-webtest))
11474 (propagated-inputs
11475 (list python-pyramid
11476 python-pyramid-chameleon
11477 python-pyramid-jinja2
11478 python-pyramid-mako
11479 python-selenium
11480 python-sqlalchemy
11481 python-waitress))
11482 (home-page "https://github.com/Pylons/pyramid_debugtoolbar")
11483 (synopsis "Pyramid debug toolbar")
11484 (description
11485 "This package provides an interactive HTML debugger for Pyramid
11486application development.")
11487 (license license:bsd-3)))
11488
11489(define-public python-pyramid-jinja2
11490 (package
11491 (name "python-pyramid-jinja2")
11492 (version "2.10.1")
11493 (source
11494 (origin
11495 (method url-fetch)
11496 (uri (pypi-uri "pyramid_jinja2" version))
11497 (sha256
11498 (base32 "0xqnqbqhx9bkrg2ic3blflsk8xc8kh7i2dm2kha9apqkbjrqql4c"))))
11499 (build-system pyproject-build-system)
11500 (arguments
11501 (list
11502 #:test-flags
11503 ;; Two tests failed with assertion not equal.
11504 #~(list "-k" "not test_it_relative_to_package and not test_options")))
11505 (native-inputs
11506 (list python-pytest
11507 python-setuptools
11508 python-webtest))
11509 (propagated-inputs
11510 (list python-jinja2
11511 python-markupsafe
11512 python-pyramid
11513 python-zope-deprecation))
11514 (home-page "https://github.com/Pylons/pyramid_jinja2")
11515 (synopsis "Jinja2 template bindings for the Pyramid web framework")
11516 (description "This package provides Jinja2 template bindings for the
11517Pyramid web framework.")
11518 (license license:repoze)))
11519
11520(define-public python-pyramid-mako
11521 ;; 1.1.0 was released in 2019, there a lot of compatibility changes on
11522 ;; master, us the latest commit for now.
11523 (let ((commit "1a6f4c00c7134530d2975f34d904b64a41b28b21")
11524 (revision "0"))
11525 (package
11526 (name "python-pyramid-mako")
11527 (version (git-version "1.1.0" revision commit))
11528 (source
11529 (origin
11530 (method git-fetch)
11531 (uri (git-reference
11532 (url "https://github.com/Pylons/pyramid_mako")
11533 (commit commit)))
11534 (file-name (git-file-name name version))
11535 (sha256
11536 (base32 "0v0571z2gby4apsalkdk83gs0d5mw79d56518h3bwwxzbq32kkns"))))
11537 (build-system pyproject-build-system)
11538 (native-inputs
11539 (list python-pytest
11540 python-setuptools))
11541 (propagated-inputs
11542 (list python-mako
11543 python-pyramid))
11544 (home-page "https://github.com/Pylons/pyramid_mako")
11545 (synopsis "Mako template bindings for the Pyramid web framework")
11546 (description
11547 "This package provides Mako template bindings for the Pyramid web
11548framework.")
11549 (license license:repoze))))
11550
11551(define-public python-pyramid-retry
11552 (package
11553 (name "python-pyramid-retry")
11554 (version "2.1.1")
11555 (source
11556 (origin
11557 (method url-fetch)
11558 (uri (pypi-uri "pyramid_retry" version))
11559 (sha256
11560 (base32 "1jf07v6zhli0abgm2qajzfwg68bl9zy4xygjwl4svawbwrm2ga5s"))))
11561 (build-system pyproject-build-system)
11562 (native-inputs
11563 (list python-pytest
11564 python-setuptools
11565 python-webtest))
11566 (propagated-inputs
11567 (list python-pyramid
11568 python-zope-interface))
11569 (home-page "https://github.com/Pylons/pyramid_retry")
11570 (synopsis "Pyramid execution policy supporting retrying failed requests")
11571 (description
11572 "@code{pyramid_retry} is an execution policy for Pyramid that wraps requests
11573and can retry them a configurable number of times under certain \"retryable\"
11574error conditions before indicating a failure to the client.")
11575 (license license:expat)))
11576
11577(define-public python-pyramid-tm
11578 (package
11579 (name "python-pyramid-tm")
11580 (version "2.6")
11581 (source
11582 (origin
11583 (method url-fetch)
11584 (uri (pypi-uri "pyramid_tm" version))
11585 (sha256
11586 (base32 "173hg16hldfh5n3mn482xx64nldk308dzri31jd0qa4528cx4j41"))))
11587 (build-system pyproject-build-system)
11588 (native-inputs
11589 (list python-pytest
11590 python-setuptools
11591 python-webtest))
11592 (propagated-inputs
11593 (list python-pyramid
11594 python-transaction))
11595 (home-page "https://github.com/Pylons/pyramid_tm")
11596 (synopsis "Centralized transaction management for Pyramid")
11597 (description
11598 "@code{pyramid_tm} is a package which allows Pyramid requests to join the
11599active @url{https://pypi.org/project/transaction/, transaction} as provided by
11600the Python transaction package.")
11601 (license license:repoze)))
11602
11603(define-public python-random-user-agent
11604 (package
11605 (name "python-random-user-agent")
11606 (version "1.0.1")
11607 (source
11608 (origin
11609 (method url-fetch)
11610 (uri (pypi-uri "random_user_agent" version))
11611 (sha256
11612 (base32 "04nhzdh2ki7ybhjrmghxci6hcm6i03vvin2q2ynj87fbr1pa534g"))))
11613 (build-system pyproject-build-system)
11614 (arguments (list #:tests? #f)) ; No tests.
11615 (native-inputs (list python-setuptools))
11616 (home-page "https://github.com/Luqman-Ud-Din/random_user_agent")
11617 (synopsis "List of user agents")
11618 (description
11619 "This package provides a list of user agents, from a collection of more
11620than 326,000 known user-agents. Users can pick a random one, or select one
11621based on filters.")
11622 (license license:expat)))
11623
11624(define-public python-rangehttpserver
11625 (package
11626 (name "python-rangehttpserver")
11627 (version "1.4.0")
11628 (source
11629 (origin
11630 (method git-fetch)
11631 (uri (git-reference
11632 (url "https://github.com/danvk/RangeHTTPServer")
11633 (commit version)))
11634 (file-name (git-file-name name version))
11635 (sha256
11636 (base32 "1dx533fsbq1mbz3by7qkm5bh2c253nwvm8214pqbwbfq07kqkwf2"))))
11637 (build-system pyproject-build-system)
11638 (native-inputs
11639 (list python-pytest
11640 python-requests
11641 python-setuptools))
11642 (home-page "https://github.com/danvk/RangeHTTPServer")
11643 (synopsis "SimpleHTTPServer with support for range requests")
11644 (description
11645 "This tool provides a simple HTTP server with support for Range
11646requests.")
11647 (license license:asl2.0)))
11648
11649(define-public python-flask-restx
11650 (package
11651 (name "python-flask-restx")
11652 (version "1.3.0")
11653 (source
11654 (origin
11655 (method git-fetch) ;no tests in PyPI archive
11656 (uri (git-reference
11657 (url "https://github.com/python-restx/flask-restx")
11658 (commit version)))
11659 (file-name (git-file-name name version))
11660 (sha256
11661 (base32 "1qmm3i1cdv0bvzsc1gn4ql2dsf1fbx85fk69vcmzpsdxzczmw508"))))
11662 (build-system pyproject-build-system)
11663 (arguments
11664 (list
11665 ;; 1214 passed, 6 skipped, 16 deselected, 3 warnings
11666 #:test-flags
11667 #~(list "--benchmark-skip"
11668 ;; ValueError: http://www.google.com is not a valid URL. Domain
11669 ;; does not exists.
11670 "--deselect=tests/test_inputs.py::URLTest::test_check"
11671 "-k" (string-join
11672 ;; See: <https://github.com/python-restx/flask-restx/issues/620>.
11673 (list "not test_rfc822_value"
11674 "test_iso8601_value"
11675 ;; assert 404 == 2000
11676 "test_specs_endpoint_host_and_subdomain"
11677 ;; ValueError: [email protected] is not a valid email
11678 "test_valid_value_check")
11679 " and not "))))
11680 (native-inputs
11681 (list python-blinker
11682 python-faker
11683 python-pytest
11684 python-pytest-benchmark
11685 python-pytest-flask
11686 python-pytest-mock
11687 python-setuptools))
11688 (propagated-inputs
11689 (list python-aniso8601
11690 python-flask
11691 python-importlib-resources
11692 python-jsonschema
11693 python-pytz
11694 python-werkzeug))
11695 (home-page "https://github.com/python-restx/flask-restx")
11696 (synopsis
11697 "Framework for fast, easy and documented API development with Flask")
11698 (description
11699 "Flask-RESTX is an extension for Flask that adds support for quickly building
11700REST APIs. Flask-RESTX encourages best practices with minimal setup. If you are familiar
11701 with Flask, Flask-RESTX should be easy to pick up. It provides a coherent collection of
11702decorators and tools to describe your API and expose its documentation properly using
11703Swagger.")
11704 (license license:bsd-3)))
11705
11706(define-deprecated-package python-flask-restplus
11707 python-flask-restx)
11708
11709(define-public python-flask-socketio
11710 (package
11711 (name "python-flask-socketio")
11712 (version "5.5.1")
11713 (source
11714 (origin
11715 (method url-fetch)
11716 (uri (pypi-uri "flask_socketio" version))
11717 (sha256
11718 (base32
11719 "1i0yqn39b4v4r2whppx47sg7iicvqzssd1clx7cclk07l52cjinr"))))
11720 (build-system pyproject-build-system)
11721 (propagated-inputs
11722 (list python-flask python-socketio))
11723 (native-inputs
11724 (list python-pytest python-redis python-setuptools python-wheel))
11725 (home-page "https://github.com/miguelgrinberg/Flask-SocketIO/")
11726 (synopsis "Socket.IO integration for Flask applications")
11727 (description "Socket.IO integration for Flask applications")
11728 (license license:expat)))
11729
11730(define-public python-manuel
11731 (package
11732 (name "python-manuel")
11733 (version "1.13.0")
11734 (source
11735 (origin
11736 (method url-fetch)
11737 (uri (pypi-uri "manuel" version))
11738 (sha256
11739 (base32 "0nl8psji3fizbxw34gdg22dndlg9lf5f56mnh1vr4vgsx06i4qsx"))))
11740 (build-system pyproject-build-system)
11741 (arguments
11742 (list
11743 ;; FIXME: Tests are broken, see: <https://github.com/benji-york/manuel/pull/32>.
11744 #:tests? #f))
11745 (propagated-inputs
11746 (list python-setuptools)) ;install requires
11747 (home-page "https://pypi.org/project/manuel/")
11748 (synopsis "Build tested documentation")
11749 (description
11750 "Manuel lets you mix and match traditional doctests with custom test syntax.")
11751 (license license:asl2.0)))
11752
11753(define-public python-marshmallow-jsonapi
11754 (package
11755 (name "python-marshmallow-jsonapi")
11756 (version "0.26.0")
11757 (source
11758 (origin
11759 (method git-fetch)
11760 (uri (git-reference
11761 ;; XXX: Deprecated upstream: This repository has been archived
11762 ;; by the owner on Jun 6, 2024. It is now read-only.
11763 ;; Using a maintained fork. The pypi name of this fork
11764 ;; is marshmallow-jsonapi-minfork.
11765 (url "https://github.com/tadams42/marshmallow-jsonapi")
11766 (commit version)))
11767 (file-name (git-file-name name version))
11768 (sha256
11769 (base32 "07sizh4m03rrk1139ci3psh5npk42cdsdfsdp574pz1fd5ncrq91"))))
11770 (build-system pyproject-build-system)
11771 (native-inputs
11772 (list python-faker
11773 python-flask
11774 python-pytest
11775 python-setuptools))
11776 (propagated-inputs (list python-marshmallow))
11777 (home-page "https://github.com/marshmallow-code/marshmallow-jsonapi")
11778 (synopsis "JSON:API 1.0 formatting with Marshmallow")
11779 (description
11780 "The marshmallow-jsonapi package provides a simple way to produce
11781@uref{https://jsonapi.org, JSON:API}-compliant data in any Python Web
11782framework. It includes optional utilities to integrate with Flask. This is a
11783forked version whose pypi name is @code{marshmallow_jsonapi_minfork}.")
11784 (license license:expat)))
11785
11786(define-public python-pecan
11787 (package
11788 (name "python-pecan")
11789 (version "1.8.0")
11790 (source
11791 (origin
11792 (method git-fetch)
11793 (uri (git-reference
11794 (url "https://github.com/pecan/pecan")
11795 (commit version)))
11796 (file-name (git-file-name name version))
11797 (sha256
11798 (base32 "0w693jpnjy358992f3jrrlf31knkqn0jvz2jx0iz7ziikprc61p8"))))
11799 (build-system pyproject-build-system)
11800 (arguments
11801 (list
11802 #:test-flags '(list "--pyargs" "pecan")))
11803 (native-inputs
11804 (list gunicorn
11805 python-genshi
11806 python-jinja2
11807 python-pytest
11808 python-sqlalchemy-2
11809 python-webtest))
11810 (propagated-inputs
11811 (list python-mako
11812 python-webob))
11813 (home-page "http://github.com/pecan/pecan")
11814 (synopsis "WSGI object-dispatching web framework")
11815 (description "This package provides a WSGI object-dispatching web
11816framework, designed to be lean and fast, with few dependencies.")
11817 (license license:bsd-3)))
11818
11819(define-public python-persistent
11820 (package
11821 (name "python-persistent")
11822 (version "6.1.1")
11823 (source
11824 (origin
11825 (method git-fetch)
11826 (uri (git-reference
11827 (url "https://github.com/zopefoundation/persistent/")
11828 (commit version)))
11829 (file-name (git-file-name name version))
11830 (sha256
11831 (base32 "19qwqg49zql2c8l4vjxjb9haw0bzd6lk8p4v3hip2irch6a4578a"))))
11832 (build-system pyproject-build-system)
11833 (arguments
11834 (list
11835 #:phases
11836 #~(modify-phases %standard-phases
11837 (replace 'check
11838 (lambda* (#:key tests? #:allow-other-keys)
11839 (if tests?
11840 (invoke "zope-testrunner" "--test-path=src"
11841 ;; XXX: Ignore doc tests.
11842 "!persistent.tests.test_docs")
11843 (format #t "test suite not run~%")))))))
11844 (propagated-inputs
11845 (list python-cffi
11846 python-zope-deferredimport
11847 python-zope-interface
11848 python-zope-testrunner))
11849 (native-inputs
11850 (list python-manuel python-zope-testrunner python-setuptools))
11851 (home-page "https://github.com/zopefoundation/persistent/")
11852 (synopsis "Translucent persistent objects")
11853 (description
11854 "This package contains a generic persistence implementation for Python.
11855It forms the core protocol for making objects interact \"transparently\" with
11856a database such as the ZODB.")
11857 (license license:zpl2.1)))
11858
11859(define-public python-btrees
11860 (package
11861 (name "python-btrees")
11862 (version "6.1")
11863 (source
11864 (origin
11865 (method git-fetch)
11866 (uri (git-reference
11867 (url "https://github.com/zopefoundation/BTrees")
11868 (commit version)))
11869 (file-name (git-file-name name version))
11870 (sha256
11871 (base32 "0vcibmd725ddgsl5yzmi8d403day3796h82xlq84w91xbdrbd5d5"))))
11872 (build-system pyproject-build-system)
11873 (arguments
11874 (list
11875 #:phases
11876 #~(modify-phases %standard-phases
11877 (replace 'check
11878 (lambda* (#:key tests? #:allow-other-keys)
11879 (if tests?
11880 (invoke "zope-testrunner" "--test-path=src")
11881 (format #t "test suite not run~%")))))))
11882 (propagated-inputs (list python-persistent python-zope-interface))
11883 (native-inputs (list python-persistent python-transaction
11884 python-zope-testrunner python-setuptools))
11885 (home-page "https://github.com/zopefoundation/BTrees")
11886 (synopsis "Scalable persistent object containers")
11887 (description
11888 "This package contains a set of persistent object containers built around a
11889modified BTree data structure. The trees are optimized for use inside ZODB's
11890\"optimistic concurrency\" paradigm, and include explicit resolution of
11891conflicts detected by that mechanism.")
11892 (license license:zpl2.1)))
11893
11894(define-public python-transaction
11895 (package
11896 (name "python-transaction")
11897 (version "5.0")
11898 (source
11899 (origin
11900 (method url-fetch)
11901 (uri (pypi-uri "transaction" version))
11902 (sha256
11903 (base32 "0x0i5graxb93aa8bwf5rmm9zq7d7r6q2b4pw358wph5whbbpnvhh"))))
11904 (build-system pyproject-build-system)
11905 (native-inputs
11906 (list python-pytest
11907 python-setuptools))
11908 (propagated-inputs
11909 (list python-zope-interface))
11910 (home-page "https://github.com/zopefoundation/transaction")
11911 (synopsis "Transaction management for Python")
11912 (description "This package contains a generic transaction implementation
11913for Python. It is mainly used by the ZODB.")
11914 (license license:zpl2.1)))
11915
11916(define-public python-truststore
11917 (package
11918 (name "python-truststore")
11919 (version "0.10.4")
11920 (source
11921 (origin
11922 (method url-fetch)
11923 (uri (pypi-uri "truststore" version))
11924 (sha256
11925 (base32 "00f3xc7720rkddsn291yrw871kfnimi6d9xbwi75xbb3ci1vv4cx"))))
11926 (build-system pyproject-build-system)
11927 (arguments
11928 (list #:tests? #f)) ;all tests require Internet access
11929 (native-inputs
11930 (list python-flit-core))
11931 (home-page "https://github.com/sethmlarson/truststore")
11932 (synopsis "Verify certificates using native system trust stores")
11933 (description
11934 "Truststore is a library which exposes native system certificate stores (ie
11935\"trust stores\") through an @code{ssl.SSLContext-like} API. This means that
11936Python applications no longer need to rely on certifi as a root certificate
11937store.")
11938 (license license:expat)))
11939
11940(define-public python-robot-detection
11941 (package
11942 (name "python-robot-detection")
11943 (version "0.4.0")
11944 (source
11945 (origin
11946 (method git-fetch)
11947 (uri (git-reference
11948 (url "https://github.com/rory/robot-detection")
11949 (commit (string-append "v" version))))
11950 (file-name (git-file-name name version))
11951 (sha256
11952 (base32 "1gxk13rn0gw5pfc4abhfnzg8qi05xa0ygs26pgkp0swygkzq6wsq"))))
11953 (build-system pyproject-build-system)
11954 (arguments (list #:test-backend #~'unittest))
11955 (native-inputs (list python-setuptools))
11956 (propagated-inputs (list python-six))
11957 (home-page "https://github.com/rory/robot-detection")
11958 (synopsis "Detect web crawlers")
11959 (description
11960 "@code{robot_detection} is a python module to detect if a given HTTP User
11961Agent is a web crawler. It uses the list of registered robots from
11962@url{http://www.robotstxt.org}.")
11963 (license license:gpl3+)))
11964
11965(define-public python-robotframework-requests
11966 (package
11967 (name "python-robotframework-requests")
11968 (version "0.9.7")
11969 (source
11970 (origin
11971 (method git-fetch) ; no tests in PyPI release
11972 (uri (git-reference
11973 (url "https://github.com/MarketSquare/robotframework-requests")
11974 (commit (string-append "v" version))))
11975 (file-name (git-file-name name version))
11976 (sha256
11977 (base32 "077j8p5k41v53slyv8h32fcmqfi7m6z3r4gmyqqaawm5szfmy61m"))))
11978 (build-system pyproject-build-system)
11979 (native-inputs
11980 (list python-pytest
11981 python-setuptools
11982 python-wheel))
11983 (propagated-inputs
11984 (list python-requests
11985 python-robotframework))
11986 (home-page "https://github.com/MarketSquare/robotframework-requests")
11987 (synopsis "Robot Framework keyword library wrapper around requests")
11988 (description
11989 "@code{RequestsLibrary} is a @url{https://robotframework.org/, Robot
11990Framework} library aimed to provide HTTP API testing functionalities by
11991wrapping the @code{requests} Python library.")
11992 (license license:expat)))
11993
11994(define-public python-pysolr
11995 (package
11996 (name "python-pysolr")
11997 (version "3.10.0")
11998 (source
11999 (origin
12000 (method url-fetch)
12001 (uri (pypi-uri "pysolr" version))
12002 (sha256
12003 (base32 "02gl1sma5cnpd7srpri1g68lpsg3s5n3lr462p5ll8v9s4nllyqj"))))
12004 (build-system pyproject-build-system)
12005 (arguments
12006 '(#:tests? #f)) ; Tests require network access.
12007 (native-inputs
12008 (list python-setuptools
12009 python-setuptools-scm
12010 python-wheel))
12011 (propagated-inputs
12012 (list python-requests))
12013 (home-page "https://github.com/django-haystack/pysolr/")
12014 (synopsis "Lightweight python wrapper for Apache Solr")
12015 (description
12016 "This module provides an interface that queries the Apache Solr server
12017using a pure Python implementation.")
12018 (license license:bsd-3)))
12019
12020(define-public python-pyjsparser
12021 ;; XXX: This project is potentially abandonware, consider to remove in next
12022 ;; refresh cycle, see:
12023 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/28>,
12024 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/39>, and
12025 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/40>.
12026 (package
12027 (name "python-pyjsparser")
12028 (version "2.7.1")
12029 (source
12030 (origin
12031 (method url-fetch)
12032 (uri (pypi-uri "pyjsparser" version))
12033 (sha256
12034 (base32 "0ycmf9fsvwliqmm1n6sfz7x71y7i2kbfgn39d8lsbiccfxmxlq5y"))))
12035 (build-system pyproject-build-system)
12036 (arguments
12037 '(#:tests? #f)) ;no tests in PyPI
12038 (native-inputs (list python-setuptools))
12039 (home-page "https://github.com/PiotrDabkowski/pyjsparser")
12040 (synopsis "Fast JavaScript parser")
12041 (description
12042 "This package provides a fast JavaScript parser (based on esprima.js)")
12043 (license license:expat)))
12044
12045(define-public python-js2py
12046 (package
12047 (name "python-js2py")
12048 (properties '((commit . "2e017b86e2f18a6c8a842293b1687f2ce7baa12e")
12049 (revision . "0")))
12050 (version (git-version "0.74"
12051 (assoc-ref properties 'revision)
12052 (assoc-ref properties 'commit)))
12053 (source
12054 (origin
12055 (method git-fetch)
12056 (uri (git-reference
12057 (url "https://github.com/PiotrDabkowski/Js2Py")
12058 (commit (assoc-ref properties 'commit))))
12059 (file-name (git-file-name name version))
12060 (sha256
12061 (base32 "0rsac03shkm0yxq91hzxdvhb96wy168bxdw8azi25bvlm8s3l27p"))
12062 (patches
12063 (list
12064 (origin
12065 (method url-fetch)
12066 (uri (string-append "https://github.com/PiotrDabkowski/Js2Py/commit"
12067 "/fd7df4a91fb08060914c7b1d9e94583d18f3371b"
12068 ".patch"))
12069 (file-name (string-append name "-" version "-pull-327.patch"))
12070 (sha256
12071 (base32 "14v89v8qqrsq0d63xbilkvx19l1rk59mlrbxvd4sj138lk7160ki")))))))
12072 (build-system pyproject-build-system)
12073 (arguments
12074 (list #:tests? #f)) ; tests require Node
12075 (native-inputs
12076 (list python-setuptools))
12077 (propagated-inputs
12078 (list python-pyjsparser
12079 python-six
12080 python-tzlocal))
12081 (home-page "https://github.com/PiotrDabkowski/Js2Py")
12082 (synopsis "JavaScript to Python translator")
12083 (description
12084 "This package provides a JavaScript to Python translator and a JavaScript
12085interpreter written in pure Python.")
12086 (license license:expat)))
12087
12088(define-public python-http-ece
12089 (package
12090 (name "python-http-ece")
12091 (version "1.2.1")
12092 (source
12093 (origin
12094 (method git-fetch)
12095 (uri (git-reference
12096 (url "https://github.com/web-push-libs/encrypted-content-encoding")
12097 (commit (string-append "v" version))))
12098 (file-name (git-file-name name version))
12099 (sha256
12100 (base32 "16kd9dsfpyfvq4iw6bbrrqrvsnf5lwgwa6p9f3b1y56ab18y0kzx"))))
12101 (build-system pyproject-build-system)
12102 (arguments
12103 `(#:phases
12104 (modify-phases %standard-phases
12105 (add-after 'unpack 'change-directory
12106 (lambda _ (chdir "python") #t)))))
12107 (native-inputs
12108 (list python-pytest python-setuptools))
12109 (propagated-inputs
12110 (list python-cryptography))
12111 (home-page "https://github.com/web-push-libs/encrypted-content-encoding")
12112 (synopsis "Encrypted Content Encoding for HTTP")
12113 (description
12114 "This package provides a simple implementation of Encrypted Content
12115Encoding for HTTP.")
12116 (license license:expat)))
12117
12118(define-public python-cloud-init
12119 (package
12120 (name "python-cloud-init")
12121 (version "24.2")
12122 (source
12123 (origin
12124 (method git-fetch)
12125 (uri (git-reference
12126 (url "https://github.com/canonical/cloud-init")
12127 (commit version)))
12128 (file-name (git-file-name name version))
12129 (sha256
12130 (base32 "18872z2y9wkh558y1bx5r0rksb4i584jbc8z4g8marwawhwxq506"))))
12131 (build-system pyproject-build-system)
12132 (arguments
12133 (list
12134 #:test-flags
12135 '(list
12136 ;; This requires usermod
12137 "--ignore=tests/unittests/distros/test_create_users.py"
12138 ;; This writes to /var
12139 "--ignore=tests/unittests/net/test_dhcp.py"
12140 "-k"
12141 (string-append
12142 ;; This test messes with PATH, so it cannot find mkdir
12143 "not test_path_env_gets_set_from_main"
12144 " and not test_apt_configure_sources_list_"
12145 ;; These all fail because /bin/sh doesn't exist. We cannot patch
12146 ;; this because the generated scripts must use /bin/sh as they are
12147 ;; supposed to be run on minimal systems.
12148 " and not test_handler_creates_and_runs_bootcmd_script_with_instance_id"
12149 " and not test_handler_runs_bootcmd_script_with_error"
12150 " and not test_subp_combined_stderr_stdout"
12151 " and not test_handle_part"))
12152 #:phases
12153 #~(modify-phases %standard-phases
12154 (add-after 'unpack 'patch-references
12155 (lambda _
12156 (substitute* "tests/unittests/cmd/test_clean.py"
12157 (("#!/bin/sh") (string-append "#!" (which "sh"))))))
12158 (add-after 'install 'move-files
12159 (lambda* (#:key inputs outputs #:allow-other-keys)
12160 (for-each (lambda (dir)
12161 (let ((source (string-append (site-packages inputs outputs) "/" dir))
12162 (target (string-append #$output "/" (basename dir))))
12163 (copy-recursively source target)
12164 (delete-file-recursively source)))
12165 (list "etc" "lib" "usr/lib" "usr/share")))))))
12166 (propagated-inputs
12167 (list python-configobj
12168 python-jinja2
12169 python-jsonpatch
12170 python-jsonschema
12171 python-netifaces
12172 python-oauthlib
12173 python-pyserial
12174 python-pyyaml
12175 python-responses))
12176 (native-inputs
12177 (list procps ;for ps when running tests
12178 python-pytest
12179 python-pytest-mock
12180 python-passlib
12181 python-setuptools
12182 python-wheel))
12183 (home-page "https://github.com/canonical/cloud-init")
12184 (synopsis "Cloud instance initialization tools")
12185 (description
12186 "Cloud-init is the multi-distribution method for cross-platform cloud
12187instance initialization. It is supported across all major public cloud
12188providers, provisioning systems for private cloud infrastructure, and
12189bare-metal installations.")
12190 ;; Either license can be chosen
12191 (license (list license:asl2.0 license:gpl3))))
12192
12193(define-public python-cloudscraper
12194 (package
12195 (name "python-cloudscraper")
12196 (version "3.0.0")
12197 (source
12198 (origin
12199 (method git-fetch)
12200 (uri (git-reference
12201 (url "https://github.com/VeNoMouS/cloudscraper")
12202 (commit version)))
12203 (file-name (git-file-name name version))
12204 (sha256
12205 (base32 "13w0ywz2y8x0zwpwzrnn46wyq307hfpdcz49zy33yyf46rq9n10n"))
12206 (modules '((guix build utils)))
12207 (snippet
12208 '(with-directory-excursion "cloudscraper"
12209 (for-each delete-file
12210 '("captcha/9kw.py" "captcha/anticaptcha.py"))
12211 (substitute* "__init__.py"
12212 ;; Perhaps it's a joke, but don't promote proprietary software.
12213 (("([Th]is feature is not available) in the .*'" _ prefix)
12214 (string-append prefix ".'")))))))
12215 (build-system pyproject-build-system)
12216 (arguments
12217 (list
12218 #:test-flags
12219 #~(list "-k" "not test_403_handling")
12220 #:phases
12221 #~(modify-phases %standard-phases
12222 (add-after 'unpack 'relax-requirements
12223 (lambda _
12224 ;; XXX: Relax brotli dependency.
12225 (substitute* "pyproject.toml"
12226 (("\"brotli>=.*\"")
12227 "\"brotli\""))
12228 ;; XXX: Dependencies, that have not yet been packaged
12229 ;; and cause an import error when included.
12230 (delete-file "cloudscraper/interpreters/v8.py")))
12231 (add-after 'unpack 'fix-references
12232 (lambda _
12233 (substitute* "cloudscraper/interpreters/nodejs.py"
12234 (("'node'")
12235 (string-append "'" (which "node") "'"))))))))
12236 (inputs (list node-lts))
12237 (propagated-inputs
12238 (list python-pycryptodome
12239 python-brotli
12240 python-js2py
12241 python-polling2
12242 python-requests
12243 python-requests-toolbelt
12244 python-responses
12245 python-pyparsing
12246 python-websocket-client))
12247 (native-inputs (list python-pytest python-setuptools))
12248 (home-page "https://github.com/venomous/cloudscraper")
12249 (synopsis "Cloudflare anti-bot bypass")
12250 (description
12251 "This module acts as a webbrowser solving Cloudflare's Javascript
12252challenges.")
12253 (license license:expat)))
12254
12255(define-public python-imap-tools
12256 (package
12257 (name "python-imap-tools")
12258 (version "1.9.0")
12259 (source
12260 (origin
12261 (method git-fetch) ; no tests in PyPI release
12262 (uri (git-reference
12263 (url "https://github.com/ikvk/imap_tools")
12264 (commit (string-append "v" version))))
12265 (file-name (git-file-name name version))
12266 (sha256
12267 (base32 "0iawc6shxn8p0ysiqiahfic5rp1r16f7rfn11c8y2fl8falckynr"))))
12268 (arguments
12269 (list
12270 #:test-flags
12271 ;; Tests require a network connection
12272 #~(list "-k" (string-append "not test_action"
12273 " and not test_attributes"
12274 " and not test_connection"
12275 " and not test_folders"
12276 " and not test_idle"
12277 " and not test_live"))))
12278 (build-system pyproject-build-system)
12279 (native-inputs
12280 (list python-pytest python-setuptools python-wheel))
12281 (home-page "https://github.com/ikvk/imap_tools")
12282 (synopsis "Work with email and mailbox by IMAP")
12283 (description
12284 "This Python library provides tools to deal with email and mailboxes
12285over IMAP:
12286
12287@itemize
12288@item Parsed email message attributes
12289@item Query builder for searching emails
12290@item Work with emails in folders (copy, delete, flag, move, seen)
12291@item Work with mailbox folders (list, set, get, create, exists, rename, delete, status)
12292@end itemize")
12293 (license license:asl2.0)))
12294
12295(define-public python-giturlparse
12296 (package
12297 (name "python-giturlparse")
12298 (version "0.12.0")
12299 (source
12300 (origin
12301 (method git-fetch)
12302 (uri (git-reference
12303 (url "https://github.com/nephila/giturlparse")
12304 (commit version)))
12305 (file-name (git-file-name name version))
12306 (sha256
12307 (base32 "1fdbxp176p17sn5xc1418mz2vk00hlcsd5qmi2fdcfphqal6raan"))))
12308 (build-system pyproject-build-system)
12309 (native-inputs (list python-pytest python-setuptools))
12310 (home-page "https://github.com/nephila/giturlparse")
12311 (synopsis "Git URL parsing module")
12312 (description
12313 "This package provides a git URL parsing module which supports parsing
12314and rewriting of remote git URLs from various hosting providers.")
12315 (license license:asl2.0)))
12316
12317(define-public python-hstspreload
12318 (package
12319 (name "python-hstspreload")
12320 (version "2025.1.1")
12321 (source
12322 (origin
12323 (method git-fetch)
12324 (uri (git-reference
12325 (url "https://github.com/sethmlarson/hstspreload")
12326 (commit version)))
12327 (file-name (git-file-name name version))
12328 (sha256
12329 (base32 "02mdzhgdz3sprgc26qb084zy639h2zw2yc8d2vm1r18ap9k51ayq"))))
12330 (build-system pyproject-build-system)
12331 (arguments (list #:tests? #f)) ; tests require external resources.
12332 (native-inputs (list python-setuptools))
12333 (home-page "https://github.com/sethmlarson/hstspreload")
12334 (synopsis "Chromium HSTS Preload list as a Python package")
12335 (description
12336 "@code{python-hstspreload} contains Chromium HSTS Preload list
12337as a Python package.")
12338 (license license:bsd-3)))
12339
12340(define-public python-sanic-routing
12341 (package
12342 (name "python-sanic-routing")
12343 (version "23.12.0")
12344 (source
12345 (origin
12346 (method url-fetch)
12347 (uri (pypi-uri "sanic-routing" version))
12348 (sha256
12349 (base32 "014bhkharcgyprdvlk7wjxhjp1pr0cva1nwj4f2qrr23qiidrjhx"))))
12350 (build-system pyproject-build-system)
12351 (arguments
12352 ;; PyPi sources does not contain tests, recursive dependency on
12353 ;; python-sanic.
12354 (list #:tests? #f))
12355 (native-inputs (list python-setuptools python-wheel))
12356 (home-page "https://github.com/sanic-org/sanic-routing/")
12357 (synopsis "Routing component for Sanic")
12358 (description "Internal package for @code{python-sanic}, which provides
12359the @code{BasicRouter}.")
12360 (license license:expat)))
12361
12362(define-public python-sanic-testing
12363 (package
12364 (name "python-sanic-testing")
12365 (version "23.12.0")
12366 (source
12367 (origin
12368 (method url-fetch)
12369 (uri (pypi-uri "sanic-testing" version))
12370 (sha256
12371 (base32 "0gqkzv90sbj9rw7yfly9c58lq9dq30g5hhcgjl3ihzjb66vm571b"))))
12372 (build-system pyproject-build-system)
12373 (arguments
12374 ;; PyPi sources does not contain tests, recursive dependency on
12375 ;; python-sanic.
12376 (list #:tests? #f))
12377 (propagated-inputs (list python-httpx python-sanic-bootstrap))
12378 (native-inputs (list python-setuptools python-wheel))
12379 (home-page "https://github.com/sanic-org/sanic-testing/")
12380 (synopsis "Test clients for Sanic")
12381 (description "Internal package for @code{python-sanic}, which is
12382meant to be the core testing utility and clients for testing Sanic
12383applications.")
12384 (license license:expat)))
12385
12386(define-public python-sanic
12387 (package
12388 (name "python-sanic")
12389 (version "25.3.0")
12390 (source
12391 (origin
12392 (method url-fetch)
12393 (uri (pypi-uri "sanic" version))
12394 (sha256
12395 (base32 "1fv9wgsj54scbr7qhmwdgc4zqnqpwacpakcfxhsg10gc04h54pbp"))
12396 ;; Loosen requirements for both python-sanic and python-sanic-bootstrap.
12397 (modules '((guix build utils)))
12398 (snippet #~(substitute* "setup.py"
12399 (("setuptools>=[0-9.]*")
12400 "setuptools")))))
12401 (build-system pyproject-build-system)
12402 (arguments
12403 (list
12404 #:test-flags
12405 #~(list "--asyncio-mode=auto"
12406 "--ignore=tests/benchmark/"
12407 "--ignore=tests/typing/test_typing.py"
12408 ;; Most tests hang or fail
12409 "--ignore=tests/test_cli.py"
12410 "--ignore=tests/worker/test_worker_serve.py"
12411 "-k"
12412 (string-append
12413 ;; PyPi sources lack examples module.
12414 "not test_gunicorn_"
12415 ;; Does not expect brotli and reordered headers.
12416 " and not test_raw_headers"
12417 ;; These look like buggy testcases.
12418 " and not test_zero_downtime"
12419 " and not test_non_default_uvloop_config_raises_warning"
12420 " and not test_listeners_triggered"
12421 " and not test_keep_alive_connection_context"
12422 " and not test_keep_alive_client_timeout"
12423 " and not test_conflicting_body_methods_overload"
12424 " and not test_unix_connection"
12425 ;; Unclear why they fail since core-updates merge.
12426 " and not test_missing_sni"
12427 " and not test_no_matching_cert"
12428 " and not test_wildcards"
12429 ;; These tests fail because subprotocols appear to be
12430 ;; parameterized as None
12431 " and not test_websocket_route_with_subprotocols"
12432 ;; AF_UNIX path too long
12433 " and not test_setup_and_teardown_unix"
12434 " and not test_configure_socket"
12435 ;; Freezes
12436 " and not test_server_run_with_repl"
12437 " and not test_server_run"
12438 " and not test_no_workers"))))
12439 (propagated-inputs
12440 (list python-aiofiles
12441 python-aioquic
12442 python-html5tagger
12443 python-httptools
12444 python-multidict
12445 python-sanic-routing
12446 python-tracerite
12447 python-typing-extensions
12448 python-ujson
12449 python-uvloop
12450 python-websockets))
12451 (native-inputs
12452 (list python-beautifulsoup4
12453 python-chardet
12454 python-cryptography
12455 python-docutils
12456 python-mypy
12457 python-pygments
12458 python-pytest
12459 python-pytest-asyncio
12460 python-pytest-benchmark
12461 python-pytest-sanic
12462 python-sanic-testing
12463 python-setuptools
12464 python-slotscheck
12465 python-towncrier
12466 python-types-ujson
12467 python-uvicorn
12468 python-wheel))
12469 (home-page "https://github.com/sanic-org/sanic/")
12470 (synopsis "Async Python web server/framework")
12471 (description
12472 "Sanic is a Python web server and web framework that's written to go
12473fast. It allows the usage of the @code{async/await} syntax added in Python
124743.5, which makes your code non-blocking and speedy.")
12475 (license license:expat)))
12476
12477(define-public python-sanic-bootstrap
12478 (package
12479 (inherit python-sanic)
12480 (name "python-sanic-bootstrap")
12481 (arguments (list #:tests? #f))
12482 (native-inputs (list python-setuptools python-wheel))))
12483
12484(define-public python-socketio
12485 (package
12486 (name "python-socketio")
12487 (version "5.12.1")
12488 (source
12489 (origin
12490 (method url-fetch)
12491 (uri (pypi-uri "python_socketio" version))
12492 (sha256
12493 (base32
12494 "175sd3fdld3s477i6b3v49yhf1alsbm1vaxzq44nqrqb8wgzz682"))))
12495 (build-system pyproject-build-system)
12496 (arguments
12497 (list #:test-flags
12498 '(list "--timeout=60"
12499 ;; These tests freeze.
12500 "--ignore-glob=tests/async/*")))
12501 (propagated-inputs
12502 (list python-bidict python-engineio python-msgpack))
12503 (native-inputs
12504 (list python-pytest
12505 python-pytest-asyncio
12506 python-pytest-timeout
12507 python-setuptools
12508 python-uvicorn
12509 python-wheel))
12510 (home-page "https://github.com/miguelgrinberg/python-socketio/")
12511 (synopsis "Python Socket.IO server")
12512 (description
12513 "This package provides a Python implementation of the @code{Socket.IO}
12514realtime client and server.")
12515 (license license:expat)))
12516
12517(define-public python-socks
12518 (package
12519 (name "python-socks")
12520 (version "2.8.1")
12521 (source
12522 (origin
12523 (method git-fetch)
12524 (uri (git-reference
12525 (url "https://github.com/romis2012/python-socks")
12526 (commit (string-append "v" version))))
12527 (file-name (git-file-name name version))
12528 (sha256
12529 (base32 "1x95i9w3izivdgz6hadh5kiil12i4ljk4ashgh3g0rjv2rw33vhj"))))
12530 (build-system pyproject-build-system)
12531 (propagated-inputs (list python-trio))
12532 (native-inputs
12533 (list python-anyio
12534 python-flask
12535 python-pytest
12536 python-pytest-asyncio
12537 python-pytest-trio
12538 python-setuptools
12539 python-tiny-proxy
12540 python-trustme
12541 python-yarl))
12542 (home-page "https://github.com/romis2012/python-socks")
12543 (synopsis
12544 "Core proxy (SOCKS4, SOCKS5, HTTP tunneling) functionality for Python")
12545 (description
12546 "Socks is a library providing core proxy (SOCKS4, SOCKS5, HTTP tunneling)
12547 functionality.")
12548 (license license:asl2.0)))
12549
12550(define-public python-socksio
12551 (package
12552 (name "python-socksio")
12553 (version "1.0.0")
12554 (source
12555 (origin
12556 (method url-fetch)
12557 (uri (pypi-uri "socksio" version))
12558 (sha256
12559 (base32 "1b64j45w35jzhjhnq44bnyad9ydh1iyyd7a6j2c8phxmllyyp2zq"))))
12560 (build-system pyproject-build-system)
12561 (native-inputs
12562 (list python-flit-core python-pytest))
12563 (home-page "https://github.com/sethmlarson/socksio")
12564 (synopsis "Sans-I/O implementation of SOCKS4, SOCKS4A, and SOCKS5")
12565 (description "The @code{socksio} Python module is a client-side sans-I/O
12566SOCKS proxy implementation. It supports SOCKS4, SOCKS4A, and SOCKS5.
12567@code{socksio} is a sans-I/O library similar to @code{h11} or @code{h2}; this
12568means the library itself does not handle the actual sending of the bytes
12569through the network, it only deals with the implementation details of the
12570SOCKS protocols. It can be paired with any I/O library.")
12571 (license license:expat)))
12572
12573(define-public python-simple-websocket
12574 (package
12575 (name "python-simple-websocket")
12576 (version "1.1.0")
12577 (source
12578 (origin
12579 (method url-fetch)
12580 (uri (pypi-uri "simple_websocket" version))
12581 (sha256
12582 (base32 "1r1all55d5dimiw3qwdhj53cxj9yjgnskcysmcscarx0g9726fbr"))))
12583 (build-system pyproject-build-system)
12584 (arguments
12585 ;; Requires Internet access to resolve example.com
12586 (list #:test-flags '(list "--ignore=tests/test_client.py")))
12587 (propagated-inputs (list python-wsproto))
12588 (native-inputs (list python-pytest
12589 python-setuptools))
12590 (home-page "https://github.com/miguelgrinberg/simple-websocket")
12591 (synopsis "Simple WebSocket server and client for Python")
12592 (description "This package provides a simple @code{WebSocket} server and
12593client for Python.")
12594 (license license:expat)))
12595
12596(define-public python-siosocks
12597 (package
12598 (name "python-siosocks")
12599 (version "0.3.0")
12600 (source
12601 (origin
12602 (method git-fetch)
12603 (uri (git-reference
12604 (url "https://github.com/pohmelie/siosocks")
12605 (commit (string-append "v" version))))
12606 (file-name (git-file-name name version))
12607 (sha256
12608 (base32 "0zcib4j5bfxlryfa412wmlkk8ivsiwxrfbpij5s7ag839ii2lxa5"))))
12609 (build-system pyproject-build-system)
12610 (native-inputs
12611 (list python-pytest
12612 python-pytest-asyncio
12613 python-pytest-trio
12614 python-setuptools))
12615 (propagated-inputs (list python-trio))
12616 (home-page "https://github.com/pohmelie/siosocks")
12617 (synopsis "SOCKSv4 & SOCKSv5 TCP proxy protocol implementation in Python")
12618 (description
12619 "This package provides a Python module and framework for sans-io socks proxy
12620client/server with couple io backends.
12621
12622Features:
12623@itemize
12624@item Only TCP connect (no BIND, no UDP)
12625@item Both client and server
12626@item SOCKS versions: 4, 4a, 5
12627@item SOCKSv5 auth: no auth, username/password
12628@item Couple io backends: @code{asyncio}, @code{trio}, @code{socketserver}
12629@item One-shot socks server (@code{python -m siosocks})
12630@end itemize")
12631 (license license:expat)))
12632
12633(define-public python-tiny-proxy
12634 (package
12635 (name "python-tiny-proxy")
12636 (version "0.2.1")
12637 (source
12638 (origin
12639 (method url-fetch)
12640 (uri (pypi-uri "tiny_proxy" version))
12641 (sha256
12642 (base32 "05nq62fn3p7s1a6dkdvnrzmk39d9ddrzb3pqbbli025qs3m9j1bq"))))
12643 (build-system pyproject-build-system)
12644 ;; There are only a handful of tests and they require the as yet
12645 ;; unpackaged httpx_socks.
12646 (arguments (list #:tests? #false))
12647 (propagated-inputs (list python-anyio))
12648 (native-inputs
12649 (list python-httpx
12650 python-pytest
12651 python-setuptools
12652 python-wheel))
12653 (home-page "https://github.com/romis2012/tiny-proxy")
12654 (synopsis "Simple proxy server (SOCKS4(a), SOCKS5(h), HTTP tunnel)")
12655 (description "This package provides a simple proxy server (SOCKS4(a),
12656SOCKS5(h), HTTP tunnel).")
12657 (license license:asl2.0)))
12658
12659(define-public python-azure-nspkg
12660 (package
12661 (name "python-azure-nspkg")
12662 (version "3.0.2")
12663 (source
12664 (origin
12665 (method url-fetch)
12666 (uri (pypi-uri "azure-nspkg" version ".zip"))
12667 (sha256
12668 (base32
12669 "1l4xwdh0fcnvrv0mzig4g2kgqkfbsy64zjm1ggc6grk3mykcxlz7"))))
12670 (build-system pyproject-build-system)
12671 (arguments (list #:tests? #f)) ;no tests in package
12672 (native-inputs (list unzip python-setuptools))
12673 (home-page "https://github.com/Azure/azure-sdk-for-python")
12674 (synopsis "Azure namespace internals")
12675 (description
12676 "This package is an internal Azure namespace package.")
12677 (license license:expat)))
12678
12679(define-public python-azure-storage-nspkg
12680 (package
12681 (name "python-azure-storage-nspkg")
12682 (version "3.1.0")
12683 (source
12684 (origin
12685 (method url-fetch)
12686 (uri (pypi-uri "azure-storage-nspkg" version))
12687 (sha256
12688 (base32 "049qcmgshz7dj9yaqma0fwcgbxwddgwyfcw4gmv45xfmaa3bwfvg"))))
12689 (build-system pyproject-build-system)
12690 (arguments
12691 (list #:tests? #f)) ;no tests in PyPI archive
12692 (native-inputs (list python-setuptools))
12693 (propagated-inputs (list python-azure-nspkg))
12694 (home-page "https://github.com/Azure/azure-storage-python")
12695 (synopsis "Microsoft Azure Storage Namespace package")
12696 (description
12697 "This project provides a client library in Python that makes it easy to
12698communicate with Microsoft Azure Storage services.")
12699 (license license:expat)))
12700
12701(define-public python-azure-common
12702 (package
12703 (name "python-azure-common")
12704 (version "1.1.28")
12705 (source
12706 (origin
12707 (method url-fetch)
12708 (uri (pypi-uri "azure-common" version ".zip"))
12709 (sha256
12710 (base32 "18q4cy1xl2zly3rk7a1sc14w932x59r8c9j4d8dnlsz32hrcvh2a"))))
12711 (build-system pyproject-build-system)
12712 (arguments
12713 (list #:tests? #f)) ;no tests in PyPI archive
12714 (propagated-inputs (list python-azure-nspkg))
12715 (native-inputs (list python-setuptools unzip))
12716 (home-page "https://github.com/Azure/azure-sdk-for-python")
12717 (synopsis "Microsoft Azure Client library for Python")
12718 (description "This package provides the Microsoft Azure Client library for
12719Python.")
12720 (license license:expat)))
12721
12722(define-public python-azure-core
12723 (package
12724 (name "python-azure-core")
12725 (version "1.32.0")
12726 (source
12727 (origin
12728 (method url-fetch)
12729 (uri (pypi-uri "azure_core" version))
12730 (sha256
12731 (base32 "1r9hqyqr5fxiiai0irr0n98gwgzj5f8y46vc1yci9bidddfw7cr2"))))
12732 (build-system pyproject-build-system)
12733 (arguments
12734 (list
12735 #:test-flags
12736 `(list ;; This fails because devtools_testutils doesn't exist.
12737 "--ignore=tests/test_connection_string_parsing.py"
12738 ;; These all need network access.
12739 "--ignore=samples"
12740 "--ignore=tests/async_tests/test_streaming_async.py"
12741 "--ignore=tests/test_streaming.py"
12742 "-m" "not asyncio and not live_test_only"
12743 "-k" ,(string-append
12744 "not test_decompress_plain_no_header"
12745 " and not test_compress_plain_no_header"
12746 " and not test_decompress_compressed_no_header"
12747 " and not test_requests_socket_timeout"))
12748 #:phases
12749 #~(modify-phases %standard-phases
12750 (add-before 'check 'add-test-pythonpath
12751 (lambda* (#:key tests? #:allow-other-keys)
12752 (when tests?
12753 (setenv "PYTHONPATH"
12754 (string-append
12755 (getcwd) "/tests/testserver_tests/coretestserver:"
12756 (getenv "GUIX_PYTHONPATH")))))))))
12757 (propagated-inputs
12758 (list python-aiohttp
12759 python-requests
12760 python-six
12761 python-typing-extensions))
12762 (native-inputs
12763 (list python-flask
12764 python-pytest-8
12765 python-pytest-aiohttp
12766 python-pytest-asyncio
12767 python-pytest-trio
12768 python-setuptools
12769 python-wheel))
12770 (home-page "https://github.com/Azure/azure-sdk-for-python")
12771 (synopsis "Microsoft Azure Core library for Python")
12772 (description "This package provides the Microsoft Azure Core library for
12773Python.")
12774 (license license:expat)))
12775
12776(define-public python-azure-storage-blob
12777 (package
12778 (name "python-azure-storage-blob")
12779 (version "12.27.0")
12780 (source
12781 (origin
12782 (method url-fetch)
12783 (uri (pypi-uri "azure_storage_blob" version))
12784 (sha256
12785 (base32 "16nb17f6bi0k53qlxybwqxdld3nj742hmsk4qcq3jwka5b6y5s4r"))))
12786 (build-system pyproject-build-system)
12787 (arguments
12788 ;; XXX: devtools_testutils is not provided as a proper package on PyPI,
12789 ;; Git does not contains setup.py, setup.cfg or pyproject.toml which makes
12790 ;; it hard to package in Guix.
12791 ;; <https://raw.githubusercontent.com/Azure/azure-sdk-for-python/refs/
12792 ;; heads/main/tools/azure-sdk-tools/devtools_testutils/README.md>.
12793 (list #:tests? #f))
12794 (native-inputs
12795 (list python-setuptools))
12796 (propagated-inputs
12797 (list python-azure-core
12798 python-cryptography
12799 python-isodate
12800 python-typing-extensions))
12801 (home-page "https://github.com/Azure/azure-sdk-for-python/")
12802 (synopsis "Microsoft Azure Blob Storage client library for Python")
12803 (description "This package provides the Microsoft Azure Blob Storage
12804Client Library for Python.")
12805 (license license:expat)))
12806
12807(define-public python-azure-storage-file-datalake
12808 (package
12809 (name "python-azure-storage-file-datalake")
12810 (version "12.22.0")
12811 (source
12812 (origin
12813 (method url-fetch)
12814 (uri (pypi-uri "azure_storage_file_datalake" version))
12815 (sha256
12816 (base32 "0xxg94684b630p8jrz38sg7mdcwp1wa0p5di27mswyrjycshvvcs"))))
12817 (build-system pyproject-build-system)
12818 (arguments
12819 ;; XXX: devtools_testutils is not provided as a proper package on PyPI,
12820 ;; Git does not contains setup.py, setup.cfg or pyproject.toml which makes
12821 ;; it hard to package in Guix.
12822 ;; <https://raw.githubusercontent.com/Azure/azure-sdk-for-python/refs/
12823 ;; heads/main/tools/azure-sdk-tools/devtools_testutils/README.md>.
12824 (list #:tests? #f))
12825 (native-inputs
12826 (list python-setuptools))
12827 (propagated-inputs
12828 (list python-azure-core
12829 python-azure-storage-blob
12830 python-isodate
12831 python-typing-extensions))
12832 (home-page "https://github.com/Azure/azure-sdk-for-python")
12833 (synopsis "Microsoft Azure File DataLake Storage Client Library for Python")
12834 (description
12835 "This package provides the Microsoft Azure File @code{DataLake} Storage
12836Client Library for Python.")
12837 (license license:expat)))
12838
12839(define-public python-google-auth
12840 (package
12841 (name "python-google-auth")
12842 (version "2.48.0")
12843 (source
12844 (origin
12845 (method url-fetch)
12846 (uri (pypi-uri "google_auth" version))
12847 (sha256
12848 (base32 "1kj1r3vp2jk2wv1mc0a5lpdnsivsqciah68ajhyql86k1imp0zjg"))))
12849 (build-system pyproject-build-system)
12850 (arguments
12851 (list
12852 #:test-flags
12853 ;; This one test uses crypto.sign with an outdated calling convention.
12854 '(list "--ignore=tests/transport/test__mtls_helper.py")))
12855 (propagated-inputs
12856 (list python-aiohttp
12857 python-cryptography
12858 python-pyasn1-modules
12859 python-requests
12860 python-rsa
12861 python-urllib3))
12862 (native-inputs
12863 (list nss-certs-for-test
12864 python-aiohttp
12865 python-aioresponses
12866 python-flask
12867 python-freezegun
12868 python-grpcio
12869 python-oauth2client
12870 python-packaging
12871 python-pyjwt
12872 python-pyopenssl
12873 python-pytest
12874 python-pytest-asyncio
12875 python-pytest-localserver
12876 python-pyu2f
12877 python-requests
12878 python-responses
12879 python-rsa
12880 python-setuptools
12881 python-urllib3))
12882 (home-page "https://github.com/googleapis/google-auth-library-python")
12883 (synopsis "Google Authentication Library")
12884 (description "This library simplifies using Google's various
12885server-to-server authentication mechanisms to access Google APIs.")
12886 (license license:asl2.0)))
12887
12888(define-public python-google-resumable-media
12889 (package
12890 (name "python-google-resumable-media")
12891 (version "2.8.0")
12892 (source
12893 (origin
12894 (method git-fetch)
12895 (uri (git-reference
12896 (url
12897 "https://github.com/googleapis/google-resumable-media-python")
12898 (commit (string-append "v" version))))
12899 (file-name (git-file-name name version))
12900 (sha256
12901 (base32 "0ndida5yr06bal0m09yri80bvf8x7yy690b14ywnxl4ixi8rlh6s"))))
12902 (build-system pyproject-build-system)
12903 (arguments
12904 (list
12905 #:test-flags
12906 #~(list
12907 ;; XXX: Missing test_utils.retry.
12908 "--ignore-glob=tests*/system/"
12909 ;; XXX: md5_hash is not mock.sentinel.md5_hash
12910 "-k" (string-join
12911 (list "not test_brotli"
12912 "test_constructor"
12913 "test_decompress")
12914 " and not "))))
12915 (propagated-inputs (list python-google-crc32c))
12916 (native-inputs
12917 (list python-google-auth
12918 python-mock
12919 python-pytest
12920 python-pytest-asyncio
12921 python-setuptools
12922 python-test-utils))
12923 (home-page "https://github.com/googleapis/google-resumable-media-python")
12924 (synopsis "Utilities for Google Media Downloads and Resumable Uploads")
12925 (description "This package provides utilities for Google Media Downloads
12926and Resumable Uploads.")
12927 (license license:asl2.0)))
12928
12929(define-public python-googleapis-common-protos
12930 (package
12931 (name "python-googleapis-common-protos")
12932 (version "1.66.0")
12933 (source
12934 (origin
12935 (method git-fetch)
12936 (uri (git-reference
12937 (url "https://github.com/googleapis/python-api-common-protos")
12938 (commit (string-append "v" version))))
12939 (file-name (git-file-name name version))
12940 (sha256
12941 (base32 "1fb7bcmjngmwwhqrldslli6r5z3s6r2kj4ywjmdjj92d1i51c29r"))))
12942 (build-system pyproject-build-system)
12943 (propagated-inputs (list python-protobuf))
12944 (native-inputs (list python-pytest python-setuptools))
12945 (home-page "https://github.com/googleapis/python-api-common-protos")
12946 (synopsis "Common protobufs used in Google APIs")
12947 (description
12948 "This package contains Python classes generated from the common protos in
12949the @code{googleapis/api-common-protos} repository.")
12950 (license license:asl2.0)))
12951
12952(define-public python-google-api-core
12953 (package
12954 (name "python-google-api-core")
12955 (version "2.29.0")
12956 (source
12957 (origin
12958 (method git-fetch)
12959 (uri (git-reference
12960 (url "https://github.com/googleapis/python-api-core")
12961 (commit (string-append "v" version))))
12962 (file-name (git-file-name name version))
12963 (sha256
12964 (base32 "0ahs8abyl7719paarlnspqp8yds149w7vm3w7zz6f7q04sscd862"))))
12965 (build-system pyproject-build-system)
12966 (arguments
12967 (list
12968 #:test-flags
12969 ;; XXX: DeprecationWarning: datetime.datetime.utcfromtimestamp() is
12970 ;; deprecated and scheduled for removal in a future version. Use
12971 ;; timezone-aware objects to represent datetimes in UTC:
12972 ;; datetime.datetime.fromtimestamp(timestamp, datetime.UTC).
12973 #~(list "-W" "ignore::DeprecationWarning")))
12974 (propagated-inputs
12975 (list python-google-auth
12976 python-googleapis-common-protos
12977 python-protobuf
12978 python-proto-plus
12979 python-requests))
12980 (native-inputs
12981 (list python-mock
12982 python-pytest
12983 python-pytest-asyncio
12984 python-pytest-mock
12985 python-setuptools))
12986 (home-page "https://github.com/googleapis/python-api-core")
12987 (synopsis "Google API client core library")
12988 (description
12989 "This library defines common helpers used by all Google API clients.")
12990 (license license:asl2.0)))
12991
12992(define-public python-google-cloud-core
12993 (package
12994 (name "python-google-cloud-core")
12995 (version "2.5.0")
12996 (source
12997 (origin
12998 (method git-fetch)
12999 (uri (git-reference
13000 (url "https://github.com/googleapis/python-cloud-core")
13001 (commit (string-append "v" version))))
13002 (file-name (git-file-name name version))
13003 (sha256
13004 (base32 "1d7li74cakgl9vghxfir9nxwy36980alvxwgwjg0zyla3hgj07cq"))))
13005 (build-system pyproject-build-system)
13006 (arguments
13007 (list
13008 #:test-flags
13009 ;; XXX: DeprecationWarning: datetime.datetime.utcfromtimestamp() is
13010 ;; deprecated and scheduled for removal in a future version. Use
13011 ;; timezone-aware objects to represent datetimes in UTC:
13012 ;; datetime.datetime.fromtimestamp(timestamp, datetime.UTC).
13013 #~(list "-W" "ignore::DeprecationWarning")))
13014 (propagated-inputs (list python-google-api-core python-google-auth))
13015 (native-inputs
13016 (list python-grpcio
13017 python-grpcio-status
13018 python-pytest
13019 python-setuptools))
13020 (home-page "https://github.com/googleapis/python-cloud-core")
13021 (synopsis "Google Cloud API client core library")
13022 (description
13023 "This library defines common helpers (e.g. base @code{Client} classes)
13024used by all of the @code{google-cloud-*} packages.")
13025 (license license:asl2.0)))
13026
13027(define-public python-google-cloud-storage
13028 (package
13029 (name "python-google-cloud-storage")
13030 (version "2.19.0")
13031 (source
13032 (origin
13033 (method git-fetch)
13034 (uri (git-reference
13035 (url "https://github.com/googleapis/python-storage")
13036 (commit (string-append "v" version))))
13037 (file-name (git-file-name name version))
13038 (sha256
13039 (base32 "19w10v2j4ciwlf8j2ylm77f8z1b0kqzg8lkh9rvh2swv1zrhydpj"))))
13040 (build-system pyproject-build-system)
13041 (arguments
13042 (list
13043 #:test-flags
13044 #~(list
13045 ;; XXX: Missing test_utils.retry.
13046 "--ignore=tests/system/"
13047 ;; Needs docker.
13048 "--ignore=tests/conformance/"
13049 ;; XXX: Deprecations.
13050 "-k" (string-join
13051 (list "not test_set_api_request_attr"
13052 "test_create_bucket_w_custom_endpoint"
13053 "test_ctor_w_api_endpoint_override"
13054 "test_ctor_w_custom_endpoint_use_auth"
13055 "test_list_buckets_w_custom_endpoint")
13056 " and not ")
13057 "tests")))
13058 (native-inputs
13059 (list python-googleapis-common-protos
13060 python-mock
13061 python-pytest
13062 python-test-utils
13063 python-setuptools))
13064 (propagated-inputs
13065 (list python-google-api-core
13066 python-google-auth
13067 python-google-cloud-core
13068 python-google-resumable-media
13069 python-protobuf
13070 python-requests))
13071 (home-page "https://github.com/googleapis/python-storage")
13072 (synopsis "Google Cloud Storage API client library")
13073 (description
13074 "Google Cloud Storage allows you to store data on Google infrastructure,
13075and it can be used to distribute large data objects to users via direct
13076download. This package provides a Google Cloud Storage API client library for
13077Python.")
13078 (license license:asl2.0)))
13079
13080(define-public python-smart-open
13081 (package
13082 (name "python-smart-open")
13083 (version "7.3.0")
13084 (source
13085 (origin
13086 (method git-fetch) ;no tests in PyPI archive
13087 (uri (git-reference
13088 (url "https://github.com/piskvorky/smart_open")
13089 (commit (string-append "v" version))))
13090 (file-name (git-file-name name version))
13091 (sha256
13092 (base32 "1jk3dj0j7idv94g1ga5wyvybakj4l150g26cbsjkrjfpy017vxab"))))
13093 (build-system pyproject-build-system)
13094 (arguments
13095 (list
13096 #:test-flags
13097 #~(list "--ignore=ci_helpers/"
13098 "--ignore=integration-tests/"
13099 ;; FIXME: Enable when guix/guix#1436 is resolved.
13100 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri"
13101 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri_contains_question_mark"
13102 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri_contains_slash"
13103 "--deselect=tests/test_smart_open.py::ParseUriTest::test_scheme"
13104 "--ignore=tests/test_gcs.py")))
13105 (propagated-inputs
13106 (list python-azure-common
13107 python-azure-core
13108 python-azure-storage-blob
13109 python-boto3
13110 ;; python-google-cloud-storage ;see guix/guix#1436
13111 python-paramiko
13112 python-requests
13113 python-wrapt
13114 python-zstandard))
13115 (native-inputs
13116 (list python-numpy
13117 python-moto
13118 python-pytest
13119 python-pytest-rerunfailures
13120 python-responses
13121 python-setuptools
13122 python-setuptools-scm
13123 python-wheel))
13124 (home-page "https://github.com/piskvorky/smart_open")
13125 (synopsis "Utilities for streaming large files")
13126 (description
13127 "This package provides utilities for streaming large files (S3, HDFS,
13128GCS, Azure Blob Storage, gzip, bz2, etc.)")
13129 (license license:expat)))
13130
13131(define-public python-smart-open-6
13132 (package
13133 (inherit python-smart-open)
13134 (name "python-smart-open")
13135 (version "6.4.0")
13136 (source
13137 (origin
13138 (method git-fetch)
13139 (uri (git-reference
13140 (url "https://github.com/piskvorky/smart_open")
13141 (commit (string-append "v" version))))
13142 (file-name (git-file-name name version))
13143 (sha256
13144 (base32 "1vpx37b6lsb6iwi59776ywjrqk1czv8arlhaf9073lrsbilqvj3x"))))
13145 (arguments
13146 (list
13147 ;; XXX: Tests need some older native inputs, disable for now.
13148 #:tests? #f))))
13149
13150(define-public python-w3lib
13151 (package
13152 (name "python-w3lib")
13153 (version "2.3.1")
13154 (source
13155 (origin
13156 (method url-fetch)
13157 (uri (pypi-uri "w3lib" version))
13158 (sha256
13159 (base32
13160 "1929layzxwdnf43hhrz7rabv388b2yibj7mnq9s62mr760mc12jw"))))
13161 (build-system pyproject-build-system)
13162 (native-inputs
13163 (list python-pytest python-setuptools python-wheel))
13164 (home-page "https://github.com/scrapy/w3lib")
13165 (synopsis "Python library of web-related functions")
13166 (description
13167 "This is a Python library of web-related functions, such as: remove
13168comments, or tags from HTML snippets, extract base url from HTML snippets,
13169translate entities on HTML strings, among other things.")
13170 (license license:bsd-3)))
13171
13172(define-public python-webcolors
13173 (package
13174 (name "python-webcolors")
13175 (version "24.11.1")
13176 (source
13177 (origin
13178 (method url-fetch)
13179 (uri (pypi-uri "webcolors" version))
13180 (sha256
13181 (base32 "1xl0vn4xa03vjwx6fj19q9kgb94g65gvdf3p0ivsy0i2ydldgczc"))))
13182 (build-system pyproject-build-system)
13183 (arguments
13184 (list
13185 #:phases
13186 '(modify-phases %standard-phases
13187 (add-after 'unpack 'patch-pyproject
13188 (lambda _
13189 ;; XXX Our version of python-pdm-backend does not recognize
13190 ;; "dependency-groups", but is fine with the bogus
13191 ;; "tool.whatever".
13192 (substitute* "pyproject.toml"
13193 (("\\[dependency-groups\\]") "[tool.whatever]")))))))
13194 (native-inputs
13195 (list python-pdm-backend python-pytest))
13196 (home-page "https://github.com/ubernostrum/webcolors")
13197 (synopsis "HTML/CSS color definitions library")
13198 (description "@code{python-webcolors} is a module for working with
13199HTML/CSS color definitions. Normalizing and converting between the following
13200formats is supported.
13201@itemize
13202@item Specification-defined color names
13203@item Six-digit hexadecimal
13204@item Three-digit hexadecimal
13205@item Integer rgb() triplet
13206@item Percentage rgb() triplet
13207@end itemize
13208Only the RGB colorspace is supported. Conversion to/from the HSL colorspace
13209can be handled by the @code{colorsys} module in the Python standard library.")
13210 (license license:bsd-3)))
13211
13212(define-public python-woob
13213 ;; TODO: woob requires backends which are currently installed on the fly in
13214 ;; ~/.local/share/woob/modules/3.7/woob_modules/ , perhaps we should install
13215 ;; them in the store instead. Many modules are included in the modules
13216 ;; directory in the source tree, but it is unclear how to install them.
13217 ;; Many modules require extra dependencies though, so maybe they should be
13218 ;; packaged independently of woob itself.
13219 (package
13220 (name "python-woob")
13221 (version "3.7")
13222 (source
13223 (origin
13224 (method git-fetch)
13225 (uri (git-reference
13226 (url "https://gitlab.com/woob/woob.git")
13227 (commit version)))
13228 (file-name (git-file-name name version))
13229 (sha256
13230 (base32 "1sy0aykff56xs4dnc7ak6m8is2zgz9fprf3i1pk8n861xz1z748i"))))
13231 (build-system pyproject-build-system)
13232 (arguments
13233 (list
13234 #:test-flags
13235 ;; Deselect tests that require DNS lookup.
13236 #~(list
13237 "--deselect=tests/browser/adapters.py::TestAdapter::test_ciphers"
13238 "--deselect=tests/browser/browsers.py::TestBrowser::test_verify")
13239 #:phases
13240 #~(modify-phases %standard-phases
13241 (add-before 'build 'relax-requirements
13242 (lambda _
13243 (substitute* "pyproject.toml"
13244 ;; packaging ~= 23.0
13245 (("\"packaging .*\",")
13246 "")
13247 ;; rich~=13.0
13248 (("\"rich .*\",")
13249 "\"rich\",")))))))
13250 (native-inputs
13251 (list nss-certs-for-test
13252 python-pytest
13253 python-setuptools))
13254 (propagated-inputs
13255 (list python-babel
13256 python-colorama
13257 python-cssselect
13258 python-dateutil
13259 python-feedparser
13260 python-html2text
13261 python-lxml
13262 python-packaging
13263 python-pillow
13264 python-prettytable
13265 python-pycountry
13266 python-pyyaml
13267 python-requests
13268 python-responses
13269 python-rich
13270 python-termcolor
13271 python-unidecode))
13272 (home-page "https://woob.tech/")
13273 (synopsis "Woob, Web Outside Of Browsers")
13274 (description
13275 "Woob is a collection of applications able to interact with
13276websites, without requiring the user to open them in a browser. It also
13277provides well-defined APIs to talk to websites lacking one.")
13278 (license license:lgpl3+)))
13279
13280(define-public python-flask-combo-jsonapi
13281 (let ((commit "3cfff98ecdbadc45d25a3fd443ad67d3743be6f5")
13282 (revision "0"))
13283 (package
13284 (name "python-flask-combo-jsonapi")
13285 (version (git-version "1.1.0" revision commit))
13286 (source
13287 (origin
13288 (method git-fetch)
13289 (uri (git-reference
13290 (url "https://github.com/AdCombo/flask-combo-jsonapi")
13291 (commit commit)))
13292 (file-name (git-file-name name version))
13293 (sha256
13294 (base32 "1lp81v96qh9hdj3c95kvfaq0vy5vd8cm55j03aszc93bs8z5jg7h"))))
13295 (build-system pyproject-build-system)
13296 (arguments
13297 (list
13298 #:test-flags
13299 #~(list
13300 "-k"
13301 (string-join
13302 (list
13303 ;; XXX: This tests a feature that doesn't make sense when dropping
13304 ;; marshmallow < 3 support.
13305 "not test_compute_schema_propagate_context"
13306 ;; The following tests fail for unknown reasons (see:
13307 ;; https://github.com/AdCombo/flask-combo-jsonapi/issues/66).
13308 "test_get_list_with_simple_filter_relationship_custom_qs_api"
13309 "test_get_list_with_simple_filter_relationship_error")
13310 " and not "))
13311 #:phases
13312 #~(modify-phases %standard-phases
13313 (add-after 'unpack 'loosen-requirements
13314 (lambda _
13315 ;; Don't pin specific versions of dependencies.
13316 (substitute* "requirements.txt"
13317 (("^(sqlalchemy|marshmallow|Flask)[=<>].*" _ dep)
13318 (string-append dep "\n"))
13319 (("^marshmallow_jsonapi[=<>].*")
13320 "marshmallow_jsonapi_minfork\n"))
13321 ;; Drop support for marshmallow < 3.
13322 (substitute* (list "flask_combo_jsonapi/data_layers/alchemy.py"
13323 "flask_combo_jsonapi/schema.py")
13324 (("from marshmallow\\.base import SchemaABC")
13325 "from marshmallow import Schema")
13326 (("if isinstance\\(related_schema_cls, SchemaABC\\):")
13327 "if isinstance(related_schema_cls, Schema):"))
13328 (substitute* "tests/test_sqlalchemy_data_layer.py"
13329 (("default=None")
13330 "dump_default=None")
13331 (("missing=")
13332 "load_default=")))))))
13333 (propagated-inputs
13334 (list python-flask
13335 python-marshmallow
13336 python-marshmallow-jsonapi
13337 python-simplejson
13338 python-sqlalchemy
13339 python-apispec
13340 python-simplejson
13341 python-six))
13342 (native-inputs
13343 (list python-pytest python-setuptools))
13344 (home-page "https://github.com/AdCombo/flask-combo-jsonapi")
13345 (synopsis "Flask extension to quickly create JSON:API 1.0 REST Web APIs")
13346 (description
13347 "Flask-COMBO-JSONAPI is a Python Flask extension for building REST Web
13348APIs compliant with the @uref{https://jsonapi.org, JSON:API 1.0}
13349specification.
13350
13351It tries to combine the power of Flask-Restless with the flexibility of
13352Flask-RESTful to quickly build APIs that fit the complexity of existing
13353real-life projects with legacy data and diverse storage providers.")
13354 (license license:expat))))
13355
13356(define-public python-mwparserfromhell
13357 (package
13358 (name "python-mwparserfromhell")
13359 (version "0.7.2")
13360 (source
13361 (origin
13362 (method git-fetch)
13363 (uri (git-reference
13364 (url "https://github.com/earwig/mwparserfromhell")
13365 (commit (string-append "v" version))))
13366 (file-name (git-file-name name version))
13367 (sha256
13368 (base32 "083ir0nccm14431mmn243862gq731ww98fwpd95zm1yccvpzdy68"))))
13369 (build-system pyproject-build-system)
13370 (native-inputs (list python-pytest python-setuptools))
13371 (home-page "https://github.com/earwig/mwparserfromhell")
13372 (synopsis "Python parser for MediaWiki wikicode")
13373 (description
13374 "The MediaWiki Parser From Hell is a python library package that provides
13375a parser for MediaWiki.
13376
13377It exposes parses as normal string objects with additional methods giving
13378access to the special Wikicode features it contains (hyperlinks, tags,
13379templates…). The parser doesn't interpolate strings at all, it remains at a
13380purely formal level.
13381
13382Full documentation may be found at
13383@uref{https://mwparserfromhell.readthedocs.io, ReadTheDocs}")
13384 (license license:expat)))
13385
13386(define-public python-tweepy
13387 (package
13388 (name "python-tweepy")
13389 (version "4.16.0")
13390 (source
13391 (origin
13392 (method git-fetch)
13393 (uri
13394 (git-reference
13395 (url "https://github.com/tweepy/tweepy")
13396 (commit (string-append "v" version))))
13397 (file-name (git-file-name name version))
13398 (sha256
13399 (base32 "1k99qf0h1ykz0c56wdnlsyvd6zrcsrc4rl7rnlaxrpjppxjnpcpn"))))
13400 (build-system pyproject-build-system)
13401 (arguments
13402 ;; tests: 149 passed, 3 skipped, 1 warning
13403 (list #:test-backend #~'unittest
13404 #:test-flags #~(list "discover" "tests")))
13405 (native-inputs
13406 (list nss-certs-for-test
13407 python-flit-core
13408 python-urllib3-1.26
13409 python-vcrpy))
13410 (propagated-inputs
13411 (list python-aiohttp
13412 python-async-lru
13413 python-oauthlib
13414 python-requests
13415 python-requests-oauthlib))
13416 (home-page "https://www.tweepy.org/")
13417 (synopsis "Twitter library for Python")
13418 (description
13419 "This package provides @code{Tweepy}, an easy-to-use Python library for
13420accessing the Twitter API.")
13421 (license license:expat)))
13422
13423(define-public python-quart
13424 (package
13425 (name "python-quart")
13426 (version "0.19.9")
13427 (source
13428 (origin
13429 (method git-fetch) ; no tests in PyPI release
13430 (uri (git-reference
13431 (url "https://github.com/pallets/quart")
13432 (commit version)))
13433 (file-name (git-file-name name version))
13434 (sha256
13435 (base32 "1h5ifv8g9dc9m07vj4v7dfalam83v38545d845vvgys1gan1pscd"))))
13436 (build-system pyproject-build-system)
13437 (native-inputs
13438 (list python-poetry-core
13439 python-pytest
13440 python-pytest-asyncio))
13441 (propagated-inputs
13442 (list hypercorn
13443 python-aiofiles
13444 python-blinker
13445 python-click
13446 python-dotenv
13447 python-flask
13448 python-itsdangerous
13449 python-jinja2
13450 python-markupsafe
13451 python-toml
13452 python-werkzeug))
13453 (home-page "https://gitlab.com/pgjones/quart/")
13454 (synopsis "Python ASGI web microframework with the same API as Flask")
13455 (description
13456 "This package provides a Python ASGI web microframework with the same API
13457as Flask.")
13458 (license license:expat)))
13459
13460(define-public python-quart-trio
13461 (package
13462 (name "python-quart-trio")
13463 (version "0.12.0")
13464 (source
13465 (origin
13466 (method url-fetch)
13467 (uri (pypi-uri "quart_trio" version))
13468 (sha256
13469 (base32 "130r8hdk7xxjp380z1r3m28lw86q2a6g9rf0mgp9gs6hk04q9v02"))))
13470 (build-system pyproject-build-system)
13471 (arguments
13472 (list
13473 #:phases
13474 #~(modify-phases %standard-phases
13475 (add-after 'unpack 'remove-coverage-pytest-options
13476 (lambda _
13477 (substitute* "pyproject.toml"
13478 (("--no-cov-on-fail") "")))))))
13479 (native-inputs
13480 (list python-pdm-backend
13481 python-pytest
13482 python-pytest-sugar
13483 python-pytest-trio))
13484 (propagated-inputs
13485 (list hypercorn
13486 python-quart
13487 python-trio))
13488 (home-page "https://github.com/pgjones/quart-trio")
13489 (synopsis "Extension for Quart to support the Trio event loop")
13490 (description
13491 "This package provides a Quart extension to provide Trio support. This
13492is an alternative to using the asyncio event loop present in the Python
13493standard library and supported by default in Quart.")
13494 (license license:expat)))
13495
13496(define-public python-ajsonrpc
13497 (package
13498 (name "python-ajsonrpc")
13499 (version "1.2.0")
13500 (source
13501 (origin
13502 (method git-fetch)
13503 (uri (git-reference
13504 (url "https://github.com/pavlov99/ajsonrpc")
13505 (commit version)))
13506 (file-name (git-file-name name version))
13507 (sha256
13508 (base32 "0c7jxfkv5q2m95j54dn650gcvdbpag2qcki7phvmrwsgb36w09kd"))))
13509 (build-system pyproject-build-system)
13510 (arguments
13511 (list
13512 #:phases
13513 #~(modify-phases %standard-phases
13514 (add-after 'unpack 'set-version
13515 (lambda _
13516 (substitute* "ajsonrpc/__init__.py"
13517 (("^__version__ = .*")
13518 (string-append "__version__ = \"" #$version "\"\n"))))))))
13519 (native-inputs
13520 (list python-pytest
13521 python-setuptools))
13522 (propagated-inputs
13523 (list python-quart
13524 python-sanic
13525 python-tornado))
13526 (home-page "https://github.com/pavlov99/ajsonrpc")
13527 (synopsis "Async JSON-RPC 2.0 protocol and server")
13528 (description
13529 "This package provides a Python JSON-RPC 2.0 protocol and server powered
13530by asyncio.")
13531 (license license:expat)))
13532
13533(define-public python-protego
13534 (package
13535 (name "python-protego")
13536 (version "0.4.0")
13537 (source
13538 (origin
13539 (method url-fetch)
13540 (uri (pypi-uri "protego" version))
13541 (sha256
13542 (base32 "1xn2aska8v94jqnbyv4ywczb55gaqvr298q8ybhs168knrifd9ck"))))
13543 (build-system pyproject-build-system)
13544 (native-inputs (list python-pytest python-setuptools python-wheel))
13545 (home-page "https://github.com/scrapy/protego")
13546 (synopsis "Python robots.txt parser with support for modern conventions")
13547 (description "Protego is a pure-Python @file{robots.txt} parser with support
13548for modern conventions.")
13549 (license license:bsd-3)))
13550
13551(define-public python-parsel
13552 (package
13553 (name "python-parsel")
13554 (version "1.10.0")
13555 (source
13556 (origin
13557 (method url-fetch)
13558 (uri (pypi-uri "parsel" version))
13559 (sha256
13560 (base32 "1050v20gzijfcaxpm1d4bvxqw2l7xhyf9pxrawrv8lczanwpvw8l"))))
13561 (build-system pyproject-build-system)
13562 (propagated-inputs
13563 (list python-cssselect
13564 python-jmespath
13565 python-lxml
13566 python-typing-extensions
13567 python-w3lib))
13568 (native-inputs
13569 (list python-psutil python-pytest python-setuptools python-wheel))
13570 (home-page "https://github.com/scrapy/parsel")
13571 (synopsis "Extract data from HTML and XML using XPath and CSS selectors")
13572 (description "Parsel is a library to extract and remove data from
13573HTML and XML using XPath and CSS selectors, optionally combined with
13574regular expressions.")
13575 (license license:bsd-3)))
13576
13577(define-public python-scrapy
13578 (package
13579 (name "python-scrapy")
13580 (version "2.13.3")
13581 (source
13582 (origin
13583 (method url-fetch)
13584 (uri (pypi-uri "scrapy" version))
13585 (sha256
13586 (base32 "0k90pni6vkj7axx3cji0b2x7yg4yfh5kh1csqiq9ssp42265h5xz"))))
13587 (build-system pyproject-build-system)
13588 (arguments
13589 (list #:test-flags
13590 #~(list "--numprocesses" (number->string (parallel-job-count))
13591 "-k" (string-join
13592 ;; ConnectionRefusedError: [Errno 111] Connection
13593 ;; refused
13594 (list "not test_append"
13595 "test_append_active_mode"
13596 "test_overwrite"
13597 "test_overwrite_active_mode"
13598 "test_persist"
13599 ;; AssertionError
13600 "test_start_deprecated_super")
13601 " and not ")
13602 ;; Skip documentation testing.
13603 "--ignore=docs")
13604 #:phases
13605 #~(modify-phases %standard-phases
13606 (add-before 'check 'prepare-test-environment
13607 (lambda _
13608 (setenv "HOME" "/tmp"))))))
13609 (propagated-inputs
13610 (list python-cryptography
13611 python-cssselect
13612 python-defusedxml
13613 python-itemadapter
13614 python-itemloaders
13615 python-lxml
13616 python-packaging
13617 python-parsel
13618 python-protego
13619 python-pydispatcher
13620 python-pyopenssl
13621 python-pypydispatcher
13622 python-queuelib
13623 python-service-identity
13624 python-tldextract
13625 python-twisted
13626 python-w3lib
13627 python-zope-interface))
13628 (native-inputs
13629 (list nss-certs-for-test
13630 python-hatchling
13631 python-pexpect
13632 python-pytest
13633 python-pytest-xdist
13634 python-setuptools
13635 python-sybil
13636 python-testfixtures))
13637 (home-page "https://scrapy.org")
13638 (synopsis "High-level Web crawling and Web scraping framework")
13639 (description "Scrapy is a fast high-level web crawling and web
13640scraping framework, used to crawl websites and extract structured data
13641from their pages. It can be used for a wide range of purposes, from data
13642mining to monitoring and automated testing.")
13643 (license license:bsd-3)))
13644
13645(define sdmx-test-data
13646 (let* ((commit "cd7899341b46e179e9f19b638478d70197e12c74")
13647 (revision "1")
13648 (name "sdmx-test-data")
13649 (version (git-version "0" revision commit)))
13650 (origin
13651 (method git-fetch)
13652 (uri (git-reference
13653 (url "https://github.com/khaeru/sdmx-test-data")
13654 (commit commit)))
13655 (file-name (git-file-name name version))
13656 (sha256
13657 (base32 "1n9y83raxxpgljbi0wjj27lhmyn19fnc2325a6cchwsa3b65ywv7")))))
13658
13659(define-public python-sdmx1
13660 (package
13661 (name "python-sdmx1")
13662 (version "2.26.0")
13663 (source
13664 (origin
13665 (method git-fetch)
13666 (uri (git-reference
13667 (url "https://github.com/khaeru/sdmx")
13668 (commit (string-append "v" version))))
13669 (file-name (git-file-name name version))
13670 (sha256
13671 (base32 "096c60pxzcw71bc9fj3hpjprrdiia365rqalapxx56g6g1vkgka9"))))
13672 (build-system pyproject-build-system)
13673 (arguments
13674 (list
13675 #:test-flags
13676 #~(list
13677 ;; 804 passed, 122 skipped, 28 deselected, 23 xfailed, 1 xpassed, 3 warnings
13678 ;; XXX: 'Version' object has no attribute 'pre'
13679 "--ignore=sdmx/tests/model/test_version.py"
13680 ;; Most of these tests require network connection.
13681 "--ignore=sdmx/tests/test_client.py"
13682 "--ignore=sdmx/tests/test_sources.py"
13683 "--ignore=sdmx/tests/test_docs.py"
13684 "--ignore=sdmx/tests/test_session.py"
13685 "--ignore=sdmx/tests/writer/test_xml.py"
13686 "--ignore=sdmx/tests/reader/test_xml_v21.py"
13687 "--deselect=sdmx/tests/convert/test_pandas.py::test_dataset_constraint"
13688 ;; Wrong python-flaky version
13689 "--deselect=sdmx/tests/format/test_xml.py::test_install_schemas_in_user_cache"
13690 "--deselect=sdmx/tests/format/test_xml.py::test_install_schemas"
13691 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_from_v2_1_samples"
13692 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_from_v3_0_samples"
13693 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_invalid_doc"
13694 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_invalid_message_type"
13695 "--deselect=sdmx/tests/format/test_xml.py::test_validate_xml_max_errors"
13696 ;; sqlite3.OperationalError
13697 "--deselect=sdmx/tests/util/test_requests.py::TestOfflineAdapter::test_raises")
13698 #:phases
13699 #~(modify-phases %standard-phases
13700 (add-after 'unpack 'fix-version
13701 (lambda _
13702 ;; versioningit needs git tags; patch pyproject.toml to use
13703 ;; static version and create _version.py directly.
13704 (substitute* "pyproject.toml"
13705 (("version.source = \"versioningit\"")
13706 "
13707[tool.hatch.version]
13708path = \"sdmx/_version.py\"")
13709 ((", \"versioningit\"")
13710 ""))
13711 (call-with-output-file "sdmx/_version.py"
13712 (lambda (port)
13713 (format port "__version__ = \"~a\"~%" #$version)))))
13714 (add-before 'check 'pre-check
13715 (lambda _
13716 (setenv "SDMX_TEST_DATA" #$sdmx-test-data)
13717 (setenv "HOME" (dirname (getcwd))))))))
13718 (propagated-inputs
13719 (list python-dateutil
13720 python-lxml
13721 python-pandas
13722 python-platformdirs
13723 python-requests))
13724 (native-inputs
13725 (list python-filelock
13726 python-flaky
13727 python-hatchling
13728 python-jinja2
13729 python-pyarrow
13730 python-pytest
13731 python-pytest-cov
13732 python-pytest-xdist
13733 python-requests-mock
13734 python-requests-cache
13735 python-responses))
13736 (home-page "https://sdmx1.readthedocs.io")
13737 (synopsis "Statistical Data and Metadata eXchange (SDMX) for Python")
13738 (description "This package provides a Python implementation of the
13739SDMX 2.1 and 3.0 standards for Statistical Data and Metadata eXchange.
13740These standards are developed and used by statistical agencies and
13741international organisations. This package can be used to:
13742@itemize
13743@item Explore and retrieve data available from SDMX-REST web services
13744operated by providers including the World Bank, International Monetary
13745Fund, Eurostat, OECD, and United Nations;
13746@item Read and write data and metadata in file formats including
13747SDMX-ML (XML), SDMX-JSON, and SDMX-CSV;
13748@item Convert data and metadata into @code{python-pandas} objects, for
13749use with the analysis, plotting, and other tools in the Python data
13750science ecosystem;
13751@item Apply the SDMX information model (IM) to structure and publish
13752your own data.
13753@end itemize")
13754 (license license:asl2.0)))
13755
13756(define-public python-jstyleson
13757 (let ((commit "8c47cc9e665b3b1744cccfaa7a650de5f3c575dd")
13758 (revision "0"))
13759 (package
13760 (name "python-jstyleson")
13761 (version (git-version "0.0.2" revision commit))
13762 (source
13763 (origin
13764 (method git-fetch)
13765 (uri (git-reference
13766 (url "https://github.com/linjackson78/jstyleson")
13767 (commit commit)))
13768 (file-name (git-file-name name version))
13769 (sha256
13770 (base32 "0r72mq7h294w5icpdbjd202w25kwr1dz7nh79f6m74xisc9cixia"))))
13771 (build-system pyproject-build-system)
13772 (native-inputs (list python-pytest python-setuptools))
13773 (home-page "https://github.com/linjackson78/jstyleson")
13774 (synopsis "JSON parser supporting js-style comments")
13775 (description
13776 "@code{jstyleson} is a Python library to parse JSON. Contrary to the
13777standard Python @code{json} library, it understands js-style comments.
13778Trailing comma is also supported.")
13779 (license license:expat))))
13780
13781(define-public python-html-text
13782 (package
13783 (name "python-html-text")
13784 (version "0.7.0")
13785 (source
13786 (origin
13787 (method url-fetch)
13788 (uri (pypi-uri "html_text" version))
13789 (sha256
13790 (base32 "10lixghras86av966ha9piqfl1iscf7nffg69dmz13sxjh371jrx"))))
13791 (build-system pyproject-build-system)
13792 (native-inputs
13793 (list python-pytest
13794 python-setuptools
13795 python-wheel))
13796 (propagated-inputs
13797 (list python-lxml
13798 python-lxml-html-clean))
13799 (home-page "https://github.com/TeamHG-Memex/html-text")
13800 (synopsis "Extract text from HTML")
13801 (description "HTML to Text is a Python library for extract text from HTML.
13802Contrary to other solution such as LXML or Beautiful Soup, the text extracted
13803with @code{html_text} does not contain elements such as JavaScript or inline
13804styles not normally visible to users. It also normalizes white space
13805characters in a smarter, more visually pleasing style.")
13806 (license license:expat)))
13807
13808(define-public python-mf2py
13809 (package
13810 (name "python-mf2py")
13811 (version "2.0.1")
13812 (source
13813 (origin
13814 (method git-fetch)
13815 (uri (git-reference
13816 (url "https://github.com/microformats/mf2py")
13817 (commit (string-append "v" version))))
13818 (file-name (git-file-name name version))
13819 (sha256
13820 (base32 "0ajnf0zrh1l48fvix9fbs1qvgbqhiljqnrm51rx44p7dbarpw4ls"))))
13821 (build-system pyproject-build-system)
13822 (native-inputs (list python-mock python-poetry-core python-pytest))
13823 (propagated-inputs
13824 (list python-beautifulsoup4 python-html5lib python-requests))
13825 (home-page "https://github.com/microformats/mf2py")
13826 (synopsis "Python Microformats2 parser")
13827 (description
13828 "This Python library provides a Microformats2 parser implementing the
13829full Microformats2 (mf2) specification, including backward compatibility with
13830Microformats1 (mf1).")
13831 (license license:expat)))
13832
13833(define-public python-extruct
13834 (package
13835 (name "python-extruct")
13836 (version "0.18.0")
13837 (source (origin
13838 (method git-fetch) ;for tests
13839 (uri (git-reference
13840 (url "https://github.com/scrapinghub/extruct")
13841 (commit (string-append "v" version))))
13842 (file-name (git-file-name name version))
13843 (sha256
13844 (base32
13845 "03qdldqrvmbsk6klq4nkxvvp3b2a0qqgqg115i3crbmialiaai45"))))
13846 (build-system pyproject-build-system)
13847 (arguments
13848 (list
13849 #:test-flags
13850 ;; 67 passed, 3 deselected
13851 ;; XXX: 3 tests fail with errors in assertion.
13852 #~(list "-k" (string-append
13853 "not test_microformat"
13854 " and not test_microformat"
13855 " and not test_umicroformat"))))
13856 (native-inputs
13857 (list python-pytest
13858 python-setuptools
13859 python-wheel))
13860 (propagated-inputs
13861 (list python-html-text
13862 python-jstyleson
13863 python-lxml
13864 python-mf2py
13865 python-pyrdfa3
13866 python-rdflib
13867 python-w3lib))
13868 (home-page "https://github.com/scrapinghub/extruct")
13869 (synopsis "Extract embedded metadata from HTML markup")
13870 (description "@code{extruct} is a Python library for extracting embedded
13871metadata from HTML markup. Currently, extruct supports:
13872@itemize
13873@item W3C's HTML Microdata
13874@item embedded JSON-LD
13875@item Microformat via mf2py
13876@item Facebook's Open Graph
13877@item (experimental) RDFa via rdflib
13878@item Dublin Core Metadata (DC-HTML-2003)
13879@end itemize")
13880 (license license:bsd-3)))
13881
13882(define-public python-wadllib
13883 (package
13884 (name "python-wadllib")
13885 (version "2.0.0")
13886 (source
13887 (origin
13888 (method url-fetch)
13889 (uri (pypi-uri "wadllib" version))
13890 (sha256
13891 (base32 "09vlfg4mzdmkqk6br7j8ms3116qk5am0nf4v1jkzwd7swhisznqy"))))
13892 (build-system pyproject-build-system)
13893 (arguments
13894 (list
13895 ;; XXX: Doctests are currently failing.
13896 #:tests? #f
13897 #:phases
13898 #~(modify-phases %standard-phases
13899 (replace 'check
13900 (lambda* (#:key tests? #:allow-other-keys)
13901 (if tests?
13902 (invoke "zope-testrunner" "--test-path=src")
13903 (format #t "test suite not run~%")))))))
13904 (native-inputs
13905 (list python-multipart python-setuptools python-zope-testrunner))
13906 (propagated-inputs (list python-lazr-uri))
13907 (home-page "https://launchpad.net/wadllib")
13908 (synopsis "Web Application Description Language (WADL) navigation library")
13909 (description "The @code{wadllib} Python library allows navigating HTTP
13910resources using Web Application Description Language (WADL) files as guides.")
13911 (license license:lgpl3)))
13912
13913(define-public python-zeep
13914 (package
13915 (name "python-zeep")
13916 (version "4.3.1")
13917 (source
13918 (origin
13919 (method url-fetch)
13920 (uri (pypi-uri "zeep" version))
13921 (sha256
13922 (base32 "0vm0asfak0pxfa9i753imcy72hk8gkxbj6pmw185b7dhw7lqalzl"))))
13923 (build-system pyproject-build-system)
13924 (arguments
13925 (list
13926 #:phases
13927 '(modify-phases %standard-phases
13928 (add-after 'unpack 'compatibility
13929 (lambda _
13930 ;; Relax requests-file requirement.
13931 (substitute* "pyproject.toml"
13932 (("\"requests-file.*\",")
13933 "\"requests-file\","))
13934 ;; httpx removed the "proxies" keyword. It's now either "mounts"
13935 ;; or "proxy". See https://github.com/encode/httpx/pull/2879.
13936 (substitute* "src/zeep/transports.py"
13937 (("proxies=") "proxy="))))
13938 ;; One test requires write access
13939 (add-before 'check 'set-HOME
13940 (lambda _ (setenv "HOME" (getcwd)))))))
13941 (propagated-inputs
13942 (list python-attrs
13943 python-isodate
13944 python-lxml
13945 python-platformdirs
13946 python-pytz
13947 python-requests
13948 python-requests-file
13949 python-requests-toolbelt))
13950 (native-inputs
13951 (list nss-certs-for-test
13952 python-freezegun
13953 python-pretend
13954 python-pytest
13955 python-pytest-asyncio
13956 python-pytest-httpx
13957 python-requests-mock
13958 python-setuptools
13959 python-wheel))
13960 (home-page "https://docs.python-zeep.org/en/stable/")
13961 (synopsis "Python SOAP client based on lxml / requests")
13962 (description "Zeep is a Python SOAP client. Highlights:
13963
13964@itemize
13965@item Build on top of @code{lxml} and @code{requests}.
13966@item Support for Soap 1.1, Soap 1.2 and HTTP bindings.
13967@item Support for WS-Addressing headers.
13968@item Support for WSSE (UserNameToken / x.509 signing).
13969@item Support for @code{asyncio} via @code{httpx}.
13970@item Experimental support for XOP messages.
13971@end itemize")
13972 (license license:expat)))
13973
13974(define-public python-http-client
13975 (package
13976 (name "python-http-client")
13977 (version "3.3.7")
13978 (source
13979 (origin
13980 (method git-fetch)
13981 (uri (git-reference
13982 (url "https://github.com/sendgrid/python-http-client")
13983 (commit version)))
13984 (file-name (git-file-name name version))
13985 (sha256
13986 (base32 "0z0ziw3f4zw5fj4spiwhhs2x8qs3i5999ry2p6a5sc8b1lkkj2zi"))))
13987 (build-system pyproject-build-system)
13988 (arguments
13989 (list
13990 #:test-backend #~'unittest
13991 #:phases
13992 #~(modify-phases %standard-phases
13993 (add-after 'unpack 'fix-tests
13994 (lambda _
13995 ;; The test expects the copyright to be updated each year.
13996 (substitute* "tests/test_daterange.py"
13997 (("time\\.strftime\\(\"%Y\"\\)") "2022")))))))
13998 (native-inputs
13999 (list python-setuptools))
14000 (home-page "https://github.com/sendgrid/python-http-client")
14001 (synopsis "HTTP REST client for Python")
14002 (description
14003 "This package provides access to any RESTful or RESTful-like API.")
14004 (license license:expat)))
14005
14006(define-public python-sendgrid
14007 (package
14008 (name "python-sendgrid")
14009 (version "6.9.7")
14010 (source
14011 (origin
14012 (method git-fetch)
14013 (uri (git-reference
14014 (url "https://github.com/sendgrid/sendgrid-python")
14015 (commit version)))
14016 (file-name (git-file-name name version))
14017 (sha256
14018 (base32 "0kvp4gm3bpcsj2mkv05pgvlcv1jlsfhcljcv61wz5kq9d273h7rg"))))
14019 (build-system pyproject-build-system)
14020 (arguments
14021 (list
14022 #:test-flags
14023 #~(list "--ignore=test/integ"
14024 ;; Network access is required.
14025 "--ignore=live_test.py")))
14026 (native-inputs
14027 (list python-pytest
14028 python-setuptools))
14029 (propagated-inputs
14030 (list python-cryptography
14031 python-http-client
14032 python-flask
14033 python-pyyaml
14034 python-six ;hard dependency
14035 python-starkbank-ecdsa
14036 python-werkzeug))
14037 (home-page "https://github.com/sendgrid/sendgrid-python/")
14038 (synopsis "SendGrid API library for Python")
14039 (description
14040 "The @code{sendgrid} Python library allows access to the
14041SendGrid Web API v3. Version 3+ of the library provides full support for all
14042SendGrid Web API v3 endpoints, including the new v3 /mail/send.")
14043 (license license:expat)))
14044
14045(define-public python-sse-starlette
14046 (package
14047 (name "python-sse-starlette")
14048 (version "3.4.4")
14049 (source
14050 (origin
14051 (method git-fetch)
14052 (uri (git-reference
14053 (url "https://github.com/sysid/sse-starlette")
14054 (commit (string-append "v" version))))
14055 (file-name (git-file-name name version))
14056 (sha256
14057 (base32 "0jzy3mjszl7fr524cggyf8k97x6jpykvmxldmm2ckmrqjpyj8jmz"))))
14058 (build-system pyproject-build-system)
14059 (arguments
14060 (list
14061 #:test-flags
14062 #~(list
14063 ;; XXX: Server fails to start.
14064 "--ignore=tests/experimentation/test_multiple_consumers_asyncio.py"
14065 "--ignore=tests/experimentation/test_multiple_consumers_threads.py"
14066 ;; XXX: Missing test dependency - testcontainers, Docker is required.
14067 "--ignore=tests/integration/test_multiple_consumers.py")))
14068 (native-inputs
14069 (list python-asgi-lifespan
14070 python-httpx
14071 python-portend
14072 python-pytest
14073 python-pytest-asyncio
14074 python-psutil
14075 python-setuptools
14076 python-tenacity
14077 python-uvicorn))
14078 (propagated-inputs
14079 (list python-anyio
14080 python-starlette))
14081 (home-page "https://github.com/sysid/sse-starlette")
14082 (synopsis "SSE plugin for Starlette")
14083 (description
14084 "This package provides SSE plugin for Starlette.")
14085 (license license:bsd-3)))
14086
14087(define-public python-sseclient-py
14088 (package
14089 (name "python-sseclient-py")
14090 (version "1.9.0")
14091 (source
14092 (origin
14093 (method git-fetch)
14094 (uri (git-reference
14095 (url "https://github.com/mpetazzoni/sseclient")
14096 (commit (string-append "sseclient-py-" version))))
14097 (file-name (git-file-name name version))
14098 (sha256
14099 (base32 "1yi2v8z89mygsr1vzyc4r3j7flr3jrh6a6kzqfdh86i5a5j5v280"))))
14100 (build-system pyproject-build-system)
14101 (native-inputs (list python-hatchling python-pytest))
14102 (arguments
14103 (list
14104 #:test-backend #~'unittest
14105 #:test-flags #~'("discover" "--verbose" "tests")))
14106 (home-page "https://github.com/mpetazzoni/sseclient")
14107 (synopsis "Pure-Python Server Side Events (SSE) client")
14108 (description
14109 "This package provides a Python client for SSE event sources that
14110seamlessly integrates with @code{urllib3} and @code{requests}.")
14111 (license license:asl2.0)))
14112
14113(define-public python-starlette
14114 (package
14115 (name "python-starlette")
14116 (version "0.49.1")
14117 (source (origin
14118 (method git-fetch)
14119 (uri (git-reference
14120 (url "https://github.com/encode/starlette")
14121 (commit version)))
14122 (file-name (git-file-name name version))
14123 (sha256
14124 (base32
14125 "0w9cyaxpc2p99hqrfw164iypacx3i1gsmn2z0xywgd21alva82ji"))))
14126 (build-system pyproject-build-system)
14127 (propagated-inputs (list python-anyio
14128 python-typing-extensions
14129 ;; [all] extra dependencies:
14130 python-itsdangerous
14131 python-jinja2
14132 python-multipart
14133 python-pyyaml
14134 python-requests))
14135 (native-inputs (list python-hatchling
14136 python-httpx
14137 python-pytest
14138 python-typing-extensions))
14139 (home-page "https://github.com/encode/starlette")
14140 (synopsis "Little ASGI library")
14141 (description
14142 "Starlette is a lightweight ASGI (Asynchronous Server Gateway
14143Interface) framework/toolkit for building async web services in Python.")
14144 (license license:bsd-3)))
14145
14146(define-public python-starsessions
14147 (package
14148 (name "python-starsessions")
14149 (version "1.3.0")
14150 (source (origin
14151 (method git-fetch)
14152 (uri (git-reference
14153 (url "https://github.com/alex-oleshkevich/starsessions")
14154 (commit (string-append "v" version))))
14155 (file-name (git-file-name name version))
14156 (sha256
14157 (base32
14158 "00dkdhp22vfmcn0w4y7f2ii8m1xj5i7409x58g3l8lvk6v5ng2nf"))))
14159 (build-system pyproject-build-system)
14160 (arguments
14161 (list
14162 #:test-flags
14163 ;; These tests require a running redis server
14164 '(list "--ignore=tests/backends/test_redis.py"
14165 ;; XXX: this failure indicates a real compatibility problem, but
14166 ;; it seems restricted to the tests only.
14167 ;; AttributeError: 'Cookies' object has no attribute
14168 ;; 'clear_session_cookies'
14169 "-k"
14170 (string-append "not test_session_clears_on_tab_close"
14171 ;; This fails because an error is not raised.
14172 " and not test_session_wants_secret_key"))
14173 #:phases
14174 '(modify-phases %standard-phases
14175 (add-after 'unpack 'compatibilitiy
14176 (lambda _
14177 ;; aioredis has been renamed
14178 (substitute* "starsessions/backends/redis.py"
14179 (("aioredis") "redis")))))))
14180 (propagated-inputs
14181 (list python-redis
14182 python-itsdangerous
14183 python-starlette))
14184 (native-inputs
14185 (list python-httpx
14186 python-poetry-core
14187 python-pytest
14188 python-pytest-asyncio
14189 python-requests))
14190 (home-page "https://github.com/alex-oleshkevich/starsessions")
14191 (synopsis "Pluggable session support for Starlette and FastAPI")
14192 (description
14193 "This package adds pluggable session backends and ships default
14194@code{InMemoryBackend} and @code{CookieBackend} implementations for Starlette
14195and FastAPI.")
14196 (license license:expat)))
14197
14198(define-public python-whereismyip
14199 (package
14200 (name "python-whereismyip")
14201 (version "0.1.0")
14202 (source
14203 (origin
14204 (method url-fetch)
14205 (uri (pypi-uri "whereismyip" version))
14206 (sha256
14207 (base32 "0psrlvax8249ccs2rvgdygpckzz22vxjcyzr2pql06d48k61gk54"))))
14208 (build-system pyproject-build-system)
14209 (arguments (list #:tests? #false)) ; There are no tests.
14210 (native-inputs (list python-setuptools))
14211 (home-page "https://pypi.org/project/whereismyip/")
14212 (synopsis "Queries multiple geolocation services until one succeeds")
14213 (description
14214 "This package provides a simple Python library that queries multiple geolocation
14215services until one succeeds.")
14216 (license license:gpl3)))
14217
14218(define-public python-whitenoise
14219 (package
14220 (name "python-whitenoise")
14221 (version "6.9.0")
14222 (source (origin
14223 (method git-fetch) ; PyPI missing test fails
14224 (uri (git-reference
14225 (url "https://github.com/evansd/whitenoise")
14226 (commit version)))
14227 (file-name (git-file-name name version))
14228 (sha256
14229 (base32
14230 "0y00a59ww9f631m51d5db5xcnbckzcwfm64wabp5vamn7l1kqqsj"))))
14231 (build-system pyproject-build-system)
14232 (arguments
14233 (list
14234 #:test-flags #~(list "-k" "not test_modified"))) ; HTTP 304 error
14235 (native-inputs (list python-brotli
14236 python-django
14237 python-requests
14238 python-pytest
14239 python-setuptools
14240 python-wheel))
14241 (home-page "https://github.com/evansd/whitenoise")
14242 (synopsis "Static file serving for WSGI applications")
14243 (description
14244 "WhiteNoise allows your web app to serve its own static files, making it
14245a self-contained unit that can be deployed anywhere without relying on nginx,
14246Amazon S3 or any other external service.")
14247 (license license:expat)))
14248
14249(define-public python-suds
14250 (package
14251 (name "python-suds")
14252 (version "1.2.0")
14253 (source
14254 (origin
14255 (method url-fetch)
14256 (uri (pypi-uri "suds" version))
14257 (sha256
14258 (base32 "1byyg7b2ixpr8hc849a6dd0qn5daxqawz6lb3php8lrmsb1n5cc3"))))
14259 (build-system pyproject-build-system)
14260 (arguments
14261 (list #:phases
14262 #~(modify-phases %standard-phases
14263 ;; XXX: chirp expects suds instead of suds_community
14264 (add-after 'install 'add-custom-dist-info
14265 (lambda _
14266 (for-each
14267 (lambda (dir)
14268 (with-directory-excursion (dirname dir)
14269 (symlink
14270 (basename dir)
14271 (string-append "suds-" #$version ".dist-info"))))
14272 (find-files #$output
14273 (lambda (file stat)
14274 (string-suffix? ".dist-info" file))
14275 #:directories? #t)))))))
14276 (native-inputs
14277 (list python-pytest
14278 python-setuptools
14279 python-wheel))
14280 (home-page "https://github.com/suds-community/suds")
14281 (synopsis "Lightweight SOAP python client for consuming Web Services")
14282 (description
14283 "Suds is a lightweight SOAP-based web service client for Python.")
14284 (license license:lgpl3+)))
14285
14286(define-public python-fastapi
14287 (package
14288 (name "python-fastapi")
14289 (version "0.131.0")
14290 (source
14291 (origin
14292 (method url-fetch)
14293 (uri (pypi-uri "fastapi" version))
14294 (sha256
14295 (base32 "1zs80pz8p04akxxmyfihqgii1wjhhad6qx1cjfd8kqmya9g1acb5"))))
14296 (build-system pyproject-build-system)
14297 (arguments
14298 (list
14299 ;; tests: 1126 passed, 12 skipped, 2 deselected
14300 #:test-backend #~'custom
14301 #:test-flags
14302 #~(list
14303 ;; Cannot import 'scripts' with just 'pytest'.
14304 "-m" "pytest"
14305 ;; Needs strawberry and sqlmodel.
14306 "--ignore=tests/test_tutorial/"
14307 ;; Fails due to failure to capture stdout.
14308 "--ignore=tests/test_fastapi_cli.py")))
14309 (native-inputs
14310 (list python-anyio
14311 python-dirty-equals
14312 python-flask
14313 python-inline-snapshot
14314 python-pdm-backend
14315 ;; python-pwdlib
14316 python-pyjwt
14317 python-pytest
14318 python-sqlalchemy-2
14319 ;; python-sqlmodel
14320 python-types-orjson
14321 python-types-ujson))
14322 (propagated-inputs
14323 (list python-starlette
14324 python-pydantic
14325 python-typing-extensions
14326 python-annotated-doc
14327 ;; [optional]
14328 python-email-validator
14329 python-fastapi-cli
14330 python-httpx
14331 python-itsdangerous
14332 python-jinja2
14333 python-multipart
14334 python-orjson
14335 python-pydantic-extra-types
14336 python-pydantic-settings
14337 python-pyyaml
14338 python-ujson
14339 python-uvicorn))
14340 (home-page "https://github.com/fastapi/fastapi")
14341 (synopsis "Web framework based on type hints")
14342 (description "FastAPI provides a web API framework based on pydantic and
14343starlette.")
14344 (license license:expat)))
14345
14346(define-public python-fastapi-csrf-protect
14347 (package
14348 (name "python-fastapi-csrf-protect")
14349 (version "0.3.3")
14350 (source (origin
14351 (method git-fetch)
14352 (uri (git-reference
14353 (url "https://github.com/aekasitt/fastapi-csrf-protect")
14354 (commit (string-append "v" version))))
14355 (file-name (git-file-name name version))
14356 (sha256
14357 (base32
14358 "181yawlbpd4709mamsradr9zj0jrbp4qvwfvmggs80pd36iiwyy8"))))
14359 (build-system pyproject-build-system)
14360 (propagated-inputs
14361 (list python-fastapi python-itsdangerous
14362 python-pydantic))
14363 (native-inputs
14364 (list python-poetry-core
14365 python-pytest))
14366 (home-page "https://github.com/aekasitt/fastapi-csrf-protect")
14367 (synopsis "Cross-Site Request Forgery (XSRF) protection")
14368 (description
14369 "This package provides a stateless implementation of @dfn{Cross-Site
14370Request Forgery} (XSRF) Protection by using the Double Submit Cookie mitigation
14371pattern.")
14372 (license license:expat)))
14373
14374(define-public python-fastapi-pagination-minimal
14375 (package
14376 (name "python-fastapi-pagination-minimal")
14377 (version "0.15.6")
14378 (source (origin
14379 (method git-fetch)
14380 (uri (git-reference
14381 (url "https://github.com/uriyyo/fastapi-pagination")
14382 (commit version)))
14383 (file-name (git-file-name name version))
14384 (sha256
14385 (base32
14386 "1ndazaqi1na0lj6fi42d7mi9lmpxdak0wq0pd97fb3b23ml8rlg6"))))
14387 (build-system pyproject-build-system)
14388 ;; We run the tests in python-fastapi-pagination only.
14389 (arguments (list #:tests? #false))
14390 ;; These are the only required dependencies,
14391 ;; please add all optional dependencies to the
14392 ;; full python-fastapi-pagination below.
14393 (propagated-inputs (list python-fastapi python-pydantic))
14394 (native-inputs (list python-hatchling))
14395 (home-page "https://github.com/uriyyo/fastapi-pagination")
14396 (synopsis "FastAPI pagination library")
14397 (description "@code{fastapi-pagination} is a Python library designed to
14398simplify pagination in FastAPI applications. It provides a set of utility
14399functions and data models to help you paginate your database queries and
14400return paginated responses to your clients.")
14401 (license license:expat)))
14402
14403(define-public python-fastapi-pagination
14404 (package
14405 (inherit python-fastapi-pagination-minimal)
14406 (name "python-fastapi-pagination")
14407 (arguments
14408 (list
14409 #:test-flags
14410 #~(list "--asyncio-mode=auto"
14411 "--ignore=tests/ext"
14412 ;; Netwok access is required.
14413 "-k" (string-join
14414 (list "not test_optional_params[postgres-default]"
14415 "test_optional_params[postgres-limit-offset]"
14416 "test_optional_params[sqlite-default]"
14417 "test_optional_params[sqlite-limit-offset]")
14418 " and not "))
14419 #:phases
14420 '(modify-phases %standard-phases
14421 (add-after 'unpack 'patch-tests
14422 (lambda _
14423 ;; We don't have a package for python-cassandra or motor, but we
14424 ;; also don't need them as we only run the unit tests anyway.
14425 (substitute* "tests/conftest.py"
14426 (("from cassandra.*") "")
14427 (("from motor.*") "")))))))
14428 (propagated-inputs
14429 (modify-inputs (package-propagated-inputs
14430 python-fastapi-pagination-minimal)
14431 (prepend python-asyncpg
14432 python-databases
14433 python-django
14434 python-fastapi
14435 python-pydantic
14436 python-sqlalchemy
14437 (package
14438 (inherit python-tortoise-orm)
14439 (arguments
14440 (substitute-keyword-arguments (package-arguments
14441 python-tortoise-orm)
14442 ((#:phases phases '%standard-phases)
14443 `(modify-phases ,phases
14444 (delete 'sanity-check)))))
14445 (propagated-inputs
14446 (modify-inputs propagated-inputs
14447 (replace "python-aiosqlite" python-aiosqlite)))))))
14448 (native-inputs
14449 (list python-aiosqlite
14450 python-asgi-lifespan
14451 python-asyncpg
14452 python-dirty-equals
14453 python-faker
14454 python-hatchling
14455 python-httpx
14456 python-pytest
14457 python-pytest-asyncio
14458 python-sqlalchemy
14459 python-typing-extensions))
14460 (description
14461 (string-append (package-description python-fastapi-pagination-minimal)
14462 "
14463
14464This package, as opposed to @code{python-fastapi-pagination-minimal}, depends on
14465all available optional dependencies supported by mainline
14466@code{fastapi-pagination}."))))
14467
14468(define-public python-fastapi-cli
14469 (package
14470 (name "python-fastapi-cli")
14471 (version "0.0.7")
14472 (source
14473 (origin
14474 (method url-fetch)
14475 (uri (pypi-uri "fastapi_cli" version))
14476 (sha256
14477 (base32 "0pk0ldmymc25ys4v6mslzd5vsjh9r69hfylh2ljl29pmarcvdcq2"))))
14478 (build-system pyproject-build-system)
14479 ;; Tests require fastapi, which depends on this package.
14480 (arguments (list #:tests? #false))
14481 (propagated-inputs (list python-rich-toolkit python-typer python-uvicorn))
14482 (native-inputs
14483 (list python-inline-snapshot python-pdm-backend python-pytest))
14484 (home-page "https://pypi.org/project/fastapi-cli/")
14485 (synopsis
14486 "Run and manage FastAPI apps from the command line with FastAPI CLI")
14487 (description
14488 "FastAPI CLI is a command line program fastapi that you can use to serve
14489your FastAPI app, manage your FastAPI project, and more.")
14490 (license license:expat)))
14491
14492(define-public python-pyactiveresource
14493 (package
14494 (name "python-pyactiveresource")
14495 (version "2.2.2")
14496 (source
14497 (origin
14498 (method git-fetch)
14499 (uri (git-reference
14500 (url "https://github.com/Shopify/pyactiveresource")
14501 (commit (string-append "v" version))))
14502 (file-name (git-file-name name version))
14503 (sha256
14504 (base32 "03pw6fwqjn09fbd6xmng0arlz75pp6ykw25c8d1snp4bxlzkrwqf"))))
14505 (build-system pyproject-build-system)
14506 ;; XXX: The package is fine, but the tests started failing on [email protected].
14507 ;; The package is not actively maintained, consider removing it once leaf.
14508 (arguments (list #:tests? #f))
14509 (native-inputs
14510 (list python-dateutil python-pytest python-pyyaml python-setuptools))
14511 (propagated-inputs (list python-six))
14512 (home-page "https://github.com/Shopify/pyactiveresource/")
14513 (synopsis "ActiveResource for Python")
14514 (description
14515 "This package provides a Python port of the ActiveResource project.
14516
14517Active Resource attempts to provide a coherent wrapper object-relational
14518mapping for REST web services. It follows the same philosophy as Active
14519Record, in that one of its prime aims is to reduce the amount of code needed
14520to map to these resources. This is made possible by relying on a number of
14521code- and protocol-based conventions that make it easy for Active Resource to
14522infer complex relations and structures.")
14523 (license license:expat)))
14524
14525(define-public python-shopifyapi
14526 (package
14527 (name "python-shopifyapi")
14528 (version "12.7.0")
14529 (source
14530 (origin
14531 (method git-fetch)
14532 (uri (git-reference
14533 (url "https://github.com/Shopify/shopify_python_api")
14534 (commit (string-append "v" version))))
14535 (file-name (git-file-name name version))
14536 (sha256
14537 (base32 "11zjm3aspb247wwlmfmq6wwk6lv3xyv3lqnd78sczjg9anba3779"))))
14538 (build-system pyproject-build-system)
14539 (arguments
14540 (list
14541 #:test-flags
14542 #~'("-k"
14543 ;; Disable a failing test.
14544 "not test_raises_if_aud_doesnt_match_api_key")))
14545 (native-inputs (list python-mock python-pytest python-setuptools))
14546 (propagated-inputs (list python-pyactiveresource python-pyjwt
14547 python-pyyaml python-six))
14548 (home-page "https://github.com/Shopify/shopify_python_api")
14549 (synopsis "Shopify API for Python")
14550 (description
14551 "This package provides the Shopify API for Python.
14552
14553The ShopifyAPI library allows Python developers to programmatically access the
14554admin section of stores using an ActiveResource-like interface similar the
14555ruby Shopify API gem. The library makes HTTP requests to Shopify in order to
14556list, create, update, or delete resources (e.g. Order, Product, Collection).")
14557 (license license:expat)))
14558
14559(define-public python-pybadges
14560 (package
14561 (name "python-pybadges")
14562 (version "3.0.1")
14563 (source (origin
14564 (method git-fetch)
14565 (uri (git-reference
14566 (url "https://github.com/google/pybadges")
14567 (commit version)))
14568 (file-name (git-file-name name version))
14569 (sha256
14570 "1zgb9idz7m3mzf8wvik0gwmyrxp753axqjv2pab326cr5myj1s4b")))
14571 (build-system pyproject-build-system)
14572 (arguments
14573 (list
14574 #:test-flags
14575 #~'("-k"
14576 ;; Disable network dependent tests.
14577 "not test_changes and not test_not_image_url and not test_http_url")))
14578 (propagated-inputs (list python-jinja2 python-requests python-setuptools))
14579 (native-inputs (list python-flask
14580 python-fonttools
14581 python-pillow
14582 python-pytest
14583 python-wheel
14584 python-xmldiff))
14585 (home-page "https://github.com/google/pybadges")
14586 (synopsis "Generate Github-style badges on the command-line")
14587 (description
14588 "This package provides @code{python-pybadges}: a library and command-line
14589tool for generating Github-style badges as SVG images.")
14590 (license license:asl2.0)))
14591
14592(define-public python-grid5000
14593 (package
14594 (name "python-grid5000")
14595 (version "1.2.4")
14596 (source (origin
14597 (method git-fetch)
14598 (uri (git-reference
14599 (url "https://gitlab.inria.fr/msimonin/python-grid5000")
14600 (commit (string-append "v" version))))
14601 (file-name (git-file-name name version))
14602 (sha256
14603 "0px5dr6kn7i5dyy4g42vqap1zpkc4hdvg7prrxdkkl57lfhz5w61")))
14604 (build-system pyproject-build-system)
14605 (arguments
14606 (list #:tests? #f)) ; No tests.
14607 (native-inputs (list python-setuptools))
14608 (propagated-inputs (list python-requests python-ipython python-pyyaml))
14609 (home-page "https://pypi.org/project/python-grid5000/")
14610 (synopsis "Grid5000 python client")
14611 (description
14612 "python-grid5000 is a python package wrapping the Grid5000 REST API.
14613You can use it as a library in your python project or you can explore the
14614Grid5000 resources interactively using the embedded shell.")
14615 (license license:gpl3+)))
14616
14617(define-public python-enoslib
14618 (package
14619 (name "python-enoslib")
14620 (version "8.0.1")
14621 (source
14622 (origin
14623 (method git-fetch)
14624 (uri (git-reference
14625 (url "https://gitlab.inria.fr/discovery/enoslib")
14626 (commit (string-append "v" version))))
14627 (file-name (git-file-name name version))
14628 (sha256 "0vs6b0bnlv95mzv0rjbxqwrhzkgjkn91gqipgwdf7y4ffpz8nybg")))
14629 (arguments
14630 (list
14631 #:test-flags
14632 #~(list "enoslib/tests/unit"
14633 "--ignore" "enoslib/tests/unit/infra/test_utils.py"
14634 "--ignore-glob" "enoslib/tests/unit/infra/enos_iotlab/*")
14635 #:phases
14636 #~(modify-phases %standard-phases
14637 (add-before 'check 'pre-check
14638 (lambda* (#:key tests? #:allow-other-keys)
14639 (when tests?
14640 ;; Otherwise Ansible fails to create its config directory.
14641 (setenv "HOME" "/tmp"))))
14642 ;; Disable the sanity check, which fails with the following error:
14643 ;;
14644 ;; ContextualVersionConflict(rich 12.4.1
14645 ;; (/gnu/store/...-python-rich-12.4.1/lib/python3.9/site-packages),
14646 ;; Requirement.parse('rich[jupyter]~=12.0.0'), {'enoslib'})
14647 ;;
14648 ;; The optional jupyter dependency of rich isn't critical for
14649 ;; EnOSlib to work
14650 (delete 'sanity-check))))
14651 (build-system pyproject-build-system)
14652 (native-inputs
14653 (list python-ddt
14654 python-freezegun
14655 python-pytest
14656 python-setuptools
14657 python-wheel))
14658 (propagated-inputs
14659 (list ansible
14660 python-cryptography
14661 python-grid5000
14662 python-jsonschema
14663 python-netaddr
14664 python-packaging
14665 python-requests
14666 python-rich
14667 python-sshtunnel
14668 python-pytz))
14669 (home-page "https://discovery.gitlabpages.inria.fr/enoslib/index.html")
14670 (synopsis "Deploy distributed testbeds on a variety of platforms")
14671 (description
14672 "EnOSlib is a library to build experimental frameworks on various
14673scientific testbeds. It lets you deploy networks of machines on actual
14674hardware on Grid'5000 or via OpenStack, to Vagrant, Chameleon, and more.")
14675 (license license:gpl3+)))
14676
14677(define-public python-pynetbox
14678 (package
14679 (name "python-pynetbox")
14680 (version "7.4.1")
14681 (source (origin
14682 (method url-fetch)
14683 (uri (pypi-uri "pynetbox" version))
14684 (sha256
14685 (base32
14686 "1hq0mqykwdsmcrj61fxxzdkpc7wnld4grhkcxy560ym79jbbb0iz"))))
14687 (build-system pyproject-build-system)
14688 (arguments
14689 (list
14690 #:test-flags
14691 ;; Integration tests depend on docker.
14692 '(list "--ignore=tests/integration")))
14693 (propagated-inputs (list python-packaging python-requests))
14694 (native-inputs
14695 (list python-pytest
14696 python-setuptools
14697 python-setuptools-scm
14698 python-wheel))
14699 (home-page "https://github.com/netbox-community/pynetbox")
14700 (synopsis "NetBox API client library")
14701 (description "Python module to query and edit data stored in a
14702@url{https://netbox.dev,NetBox} instance.")
14703 (license license:asl2.0)))
14704
14705(define-public python-waybackpack
14706 (package
14707 (name "python-waybackpack")
14708 (version "0.6.4")
14709 (source
14710 (origin
14711 (method url-fetch)
14712 (uri (pypi-uri "waybackpack" version))
14713 (sha256
14714 (base32 "16lcr2hv7gmp199fh3psrnv68j20pfxria8v6gchrpl1jqx9f923"))))
14715 (build-system pyproject-build-system)
14716 (arguments
14717 (list #:tests? #f)) ; would require network (and SSL certificates)
14718 (propagated-inputs (list python-requests))
14719 (native-inputs (list python-pytest python-setuptools python-wheel))
14720 (home-page "https://github.com/jsvine/waybackpack")
14721 (synopsis
14722 "Download the entire Wayback Machine archive for a given URL")
14723 (description
14724 "This package provides a library and a command-line tool that lets
14725you download the entire Wayback Machine archive for a given URL.")
14726 (license license:expat)))
14727
14728(define-public python-xyzservices
14729 (package
14730 (name "python-xyzservices")
14731 (version "2025.4.0")
14732 (source
14733 (origin
14734 (method url-fetch)
14735 (uri (pypi-uri "xyzservices" version))
14736 (sha256
14737 (base32 "1n096zg9bd4n6w6axcm16m9sxdkc6qy1mipva0scbyj86rqn9rvg"))))
14738 (build-system pyproject-build-system)
14739 (arguments
14740 (list
14741 #:test-flags #~(list "-m" "not request")))
14742 (native-inputs
14743 (list python-pytest
14744 python-mercantile
14745 python-requests
14746 python-setuptools
14747 python-setuptools-scm))
14748 (home-page "https://github.com/geopandas/xyzservices")
14749 (synopsis "Source of XYZ tiles providers")
14750 (description "@code{xyzservices} is a lightweight library providing a
14751repository of available XYZ services offering raster basemap tiles. The
14752repository is provided via Python API and as a compressed JSON file.")
14753 (license license:bsd-3)))
14754
14755(define-public s3cmd
14756 (package
14757 (name "s3cmd")
14758 (version "2.4.0")
14759 (source
14760 (origin
14761 (method git-fetch)
14762 (uri (git-reference
14763 (url "https://github.com/s3tools/s3cmd")
14764 (commit (string-append "v" version))))
14765 (file-name (git-file-name name version))
14766 (sha256
14767 (base32 "168c49d1v8r7azv66zz0w07jalf434c2jpg2xzads5jnxzmiy73k"))))
14768 (build-system pyproject-build-system)
14769 (arguments
14770 (list
14771 #:tests? #f ; XXX: Tests require network access.
14772 #:phases
14773 #~(modify-phases %standard-phases
14774 (add-after 'unpack 'hide-wrapping
14775 (lambda _
14776 (substitute* "S3/MultiPart.py"
14777 (("sys\\.argv\\[0\\]")
14778 "\"s3cmd\""))
14779 (substitute* "s3cmd"
14780 (("optparser\\.get_prog_name\\(\\)")
14781 "\"s3cmd\"")))))))
14782 (native-inputs (list python-setuptools))
14783 (inputs (list python-dateutil python-magic))
14784 (home-page "https://s3tools.org/s3cmd")
14785 (synopsis "Command line tool for S3-compatible storage services")
14786 (description
14787 "S3cmd is a command line tool for uploading, retrieving and managing data
14788in storage services that are compatible with the Amazon Simple Storage
14789Service (S3) protocol, including S3 itself. It supports rsync-like backup,
14790GnuPG encryption, and more. It also supports management of Amazon's
14791CloudFront content delivery network.")
14792 (license license:gpl2+)))