projects/guix·blob librewolf-updates · refs

13895 lines · 501.9 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 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 ((guix licenses) #:prefix license:)
110 #:use-module (guix build-system cargo)
111 #:use-module (guix build-system copy)
112 #:use-module (guix build-system pyproject)
113 #:use-module (guix build-system python)
114 #:use-module (guix deprecation)
115 #:use-module (guix download)
116 #:use-module (guix gexp)
117 #:use-module (guix git-download)
118 #:use-module (guix packages)
119 #:use-module (guix utils)
120 #:use-module (gnu packages admin)
121 #:use-module (gnu packages adns)
122 #:use-module (gnu packages base)
123 #:use-module (gnu packages bash)
124 #:use-module (gnu packages nss)
125 #:use-module (gnu packages check)
126 #:use-module (gnu packages cmake)
127 #:use-module (gnu packages compression)
128 #:use-module (gnu packages curl)
129 #:use-module (gnu packages databases)
130 #:use-module (gnu packages django)
131 #:use-module (gnu packages freedesktop)
132 #:use-module (gnu packages glib)
133 #:use-module (gnu packages gnupg)
134 #:use-module (gnu packages graphviz)
135 #:use-module (gnu packages groff)
136 #:use-module (gnu packages iso-codes)
137 #:use-module (gnu packages libevent)
138 #:use-module (gnu packages libffi)
139 #:use-module (gnu packages libidn)
140 #:use-module (gnu packages linux)
141 #:use-module (gnu packages lsof)
142 #:use-module (gnu packages node)
143 #:use-module (gnu packages openstack)
144 #:use-module (gnu packages pcre)
145 #:use-module (gnu packages pkg-config)
146 #:use-module (gnu packages protobuf)
147 #:use-module (gnu packages python)
148 #:use-module (gnu packages python-build)
149 #:use-module (gnu packages python-check)
150 #:use-module (gnu packages python-compression)
151 #:use-module (gnu packages python-crypto)
152 #:use-module (gnu packages python-science)
153 #:use-module (gnu packages python-xyz)
154 #:use-module (gnu packages qt)
155 #:use-module (gnu packages rdf)
156 #:use-module (gnu packages rpc)
157 #:use-module (gnu packages rust)
158 #:use-module (gnu packages rust-apps)
159 #:use-module (gnu packages serialization)
160 #:use-module (gnu packages sphinx)
161 #:use-module (gnu packages texinfo)
162 #:use-module (gnu packages time)
163 #:use-module (gnu packages tls)
164 #:use-module (gnu packages version-control)
165 #:use-module (gnu packages web)
166 #:use-module (gnu packages xml)
167 #:use-module (gnu packages)
168 #:use-module (srfi srfi-1))
169
170(define-public python-aiocoap
171 (package
172 (name "python-aiocoap")
173 (version "0.4.14")
174 (source
175 (origin
176 (method git-fetch) ; tests miss data and module files in PyPI release
177 (uri (git-reference
178 (url "https://github.com/chrysn/aiocoap")
179 (commit version)))
180 (file-name (git-file-name name version))
181 (sha256
182 (base32 "0yxvcg5llgmccv0a9hfm4nr7zxv9al4wh257m95a06g5c52v6hxz"))))
183 (build-system pyproject-build-system)
184 (arguments
185 (list
186 #:test-flags
187 ;; OSError: [Errno 98] error while attempting to bind on address ('::1',
188 ;; 8683, 0, 0): address already in use
189 #~(list "--ignore=tests/test_server.py"
190 "-k" (string-join
191 ;; TypeError: can only concatenate str (not "NoneType") to
192 ;; str
193 (list "not test_options"
194 "test_uri_parser"
195 "test_help" ; returned non-zero exit status 1.
196 "test_routing" ; address already in use
197 "test_tls")
198 " and not "))))
199 (native-inputs
200 (list openssl ;for tests/test_tls.py
201 python-pytest
202 python-setuptools
203 python-wheel))
204 (propagated-inputs
205 (list ;; python-cbor-diag
206 python-cbor2
207 python-cryptography
208 ;; python-dtlssocket
209 python-filelock
210 ;; python-ge25519
211 python-pygments
212 python-termcolor
213 python-websockets))
214 (home-page "https://github.com/chrysn/aiocoap")
215 (synopsis "Python CoAP library")
216 (description
217 "The aiocoap package is an implementation of @url{@acronym{CoAP, the
218Constrained Application Protocol}, http://coap.space/}. It facilitates
219writing applications that talk to network enabled embedded
220@acronym{IoT,Internet of Things} devices.")
221 (license license:expat)))
222
223(define-public python-alpaca-py
224 (package
225 (name "python-alpaca-py")
226 (version "0.43.2")
227 (source
228 (origin
229 (method git-fetch)
230 (uri (git-reference
231 (url "https://github.com/alpacahq/alpaca-py")
232 (commit (string-append "v" version))))
233 (file-name (git-file-name name version))
234 (sha256
235 (base32 "0majn27r2s2z5nbqvkpmw04kswhj9xkmvmm0rkvb3fga9lwwivlb"))))
236 (build-system pyproject-build-system)
237 (arguments
238 (list
239 #:phases
240 #~(modify-phases %standard-phases
241 (add-before 'build 'set-version
242 (lambda _
243 (setenv "POETRY_DYNAMIC_VERSIONING_BYPASS"
244 #$(version-major+minor+point version)))))))
245 (native-inputs
246 (list python-poetry-core
247 python-poetry-dynamic-versioning
248 python-pytest
249 python-pytest-asyncio
250 python-requests-mock))
251 (propagated-inputs
252 (list python-msgpack
253 python-pandas
254 python-pydantic
255 python-requests
256 python-sseclient-py
257 python-websockets))
258 (home-page "https://alpaca.markets/sdks/python/")
259 (synopsis "Alpaca API official Python SDK")
260 (description
261 "Alpaca-py provides an interface to REST, WebSocket and SSE endpoints
262that allow interaction with the @url{https://alpaca.markets/, Alpaca} API.")
263 (license license:asl2.0)))
264
265(define-public python-anaconda-client
266 (package
267 (name "python-anaconda-client")
268 (version "1.13.1")
269 (source
270 (origin
271 (method git-fetch)
272 (uri (git-reference
273 (url "https://github.com/Anaconda-Platform/anaconda-client")
274 (commit version)))
275 (file-name (git-file-name name version))
276 (sha256
277 (base32 "06nn3cwhrrajsbn9pils2539lzplfnyhn9java3xrpm3ksxq9g72"))))
278 (build-system pyproject-build-system)
279 (arguments
280 (list
281 #:test-flags
282 #~(list "--deselect=tests/utils/test_conda.py::test_find_conda"
283 "--deselect=tests/utils/test_conda.py::test_conda_vars")
284 #:phases
285 #~(modify-phases %standard-phases
286 (add-after 'unpack 'fix-pytest-config
287 (lambda _
288 (substitute* "setup.cfg"
289 (("addopts=.*") "addopts=\n")))))))
290 (native-inputs
291 (list python-freezegun
292 python-pytest
293 python-setuptools))
294 (propagated-inputs
295 (list python-anaconda-cli-base
296 python-conda-package-handling
297 python-conda-package-streaming
298 python-dateutil
299 python-defusedxml
300 python-nbformat
301 python-pillow
302 python-platformdirs
303 python-pytz
304 python-pyyaml
305 python-requests
306 python-requests-toolbelt
307 python-setuptools
308 python-tqdm
309 python-urllib3))
310 (home-page "https://github.com/Anaconda-Platform/anaconda-client")
311 (synopsis "Anaconda Cloud command line client library")
312 (description
313 "Anaconda Cloud command line client library provides an interface to
314Anaconda Cloud. Anaconda Cloud is useful for sharing packages, notebooks and
315environments.")
316 (license license:bsd-3)))
317
318(define-public python-apprise
319 (package
320 (name "python-apprise")
321 (version "1.9.4")
322 (source
323 (origin
324 (method url-fetch)
325 (uri (pypi-uri "apprise" version))
326 (sha256
327 (base32 "126951n9lnlqrw5lbsvs9xs7jzg33bqqxm7cfnqag2csw6p24ca8"))))
328 (build-system pyproject-build-system)
329 (arguments
330 (list
331 ;; These tests used to be ran with --numprocesses, but that seems to have
332 ;; made them non-deterministic.
333 #:test-flags
334 #~(list "--ignore=tests/test_plugin_macosx.py"
335 "-k" "not test_plugin_glib_send_raises_generic")))
336 (native-inputs
337 (list python-babel
338 python-pytest
339 python-pytest-mock
340 python-setuptools))
341 (propagated-inputs
342 (list python-certifi
343 python-click
344 python-markdown
345 python-pygobject
346 python-pyyaml
347 python-requests
348 python-requests-oauthlib))
349 (home-page "https://github.com/caronc/apprise")
350 (synopsis "Push notification library")
351 (description
352 "Apprise is a Python library that allows sending push notifications to a
353broad range of notification services, such as Telegram, Discord, Slack, Amazon
354SNS, Gotify, etc.")
355 (license license:bsd-2)))
356
357(define-public python-asyncudp
358 (package
359 (name "python-asyncudp")
360 (version "0.11.0")
361 (source
362 (origin
363 (method git-fetch)
364 (uri (git-reference
365 (url "https://github.com/eerimoq/asyncudp")
366 (commit version)))
367 (file-name (git-file-name name version))
368 (sha256
369 (base32 "1i2s8mmmggzq6vk5aldz3g85jnqfbgxfqi60wl58jpn2lbr8fqlr"))))
370 (build-system pyproject-build-system)
371 (native-inputs (list python-pytest python-setuptools))
372 (home-page (git-reference-url (origin-uri source)))
373 (synopsis "High level UDP sockets for asyncio")
374 (description
375 "This package provides a Python library offering high level UDP sockets
376for asyncio. Import it alongside asyncio and use its API to send and receive
377UDP packets.")
378 (license license:expat)))
379
380(define-public python-behave-web-api
381 (package
382 (name "python-behave-web-api")
383 (version "2.3.0")
384 (source
385 (origin
386 (method git-fetch)
387 (uri (git-reference
388 (url "https://github.com/jefersondaniel/behave-web-api")
389 (commit (string-append "v" version))))
390 (file-name (git-file-name name version))
391 (sha256
392 (base32 "1r8yx8gb5m599cpdqfvk6z9ax3qj26fpvczdr84z8jya0dxfch4p"))))
393 (build-system pyproject-build-system)
394 (native-inputs
395 (list python-pytest
396 python-setuptools))
397 (propagated-inputs
398 (list behave
399 python-requests))
400 (home-page "https://github.com/jefersondaniel/behave-web-api")
401 (synopsis "Provides testing for JSON APIs with Behave for Python")
402 (description "This package provides testing utility modules for testing
403JSON APIs with Behave.")
404 (license license:expat)))
405
406(define-public python-blacksheep
407 (package
408 (name "python-blacksheep")
409 (version "2.4.6")
410 (source
411 (origin
412 (method git-fetch)
413 (uri (git-reference
414 (url "https://github.com/Neoteroi/BlackSheep")
415 (commit (string-append "v" version))))
416 (file-name (git-file-name name version))
417 (sha256
418 (base32 "120q6hrhfjxdsqav8h5z8yqfi0iiacwxbkryjk7kb20ic2879vqh"))))
419 (build-system pyproject-build-system)
420 (arguments
421 (list
422 ;; tests: 1821 passed
423 ;;
424 ;; Run all unit tests, but do not run integration tests from `itests`
425 ;; directory.
426 #:test-flags
427 #~(list "tests")
428 #:phases
429 #~(modify-phases %standard-phases
430 (add-before 'build 'cythonize
431 (lambda _
432 (with-directory-excursion "blacksheep"
433 (for-each (lambda (file)
434 (invoke "cython" "-3" file "-I" "."))
435 (find-files "." ".*\\.pyx$"))))))))
436 (native-inputs
437 (list nss-certs-for-test
438 python-cython
439 python-flask
440 python-jinja2
441 python-pydantic
442 python-pyjwt
443 python-pytest
444 python-pytest-asyncio
445 python-setuptools))
446 (propagated-inputs
447 (list python-certifi
448 python-essentials
449 python-essentials-openapi
450 python-guardpost
451 python-httptools
452 python-rodi
453 python-itsdangerous))
454 (home-page "https://github.com/Neoteroi/BlackSheep")
455 (synopsis "Asynchronous framework to build event based web applications")
456 (description
457 "BlackSheep is a lightweight, asynchronous, event driven Web framework.
458
459The framework offers
460@itemize
461@item A rich code API, based on dependency injection and inspired by Flask and
462ASP.NET Core.
463@item A typing-friendly codebase, which enables a comfortable development
464experience thanks to hints when coding with IDEs.
465@item Built-in generation of OpenAPI Documentation, supporting version 3, YAML,
466and JSON.
467@item A cross-platform framework, using the most modern versions of Python.
468@item Good performance.
469@end itemize")
470 (license license:expat)))
471
472(define-public python-cloudpathlib
473 (package
474 (name "python-cloudpathlib")
475 (version "0.23.0")
476 (source
477 (origin
478 (method git-fetch)
479 (uri (git-reference
480 (url "https://github.com/drivendataorg/cloudpathlib")
481 (commit (string-append "v" version))))
482 (file-name (git-file-name name version))
483 (sha256
484 (base32 "1dqwml269lpz51drgg3s27sqmvwa1vldw2rj34ssnqppcmc5h5lm"))))
485 (build-system pyproject-build-system)
486 (arguments
487 (list
488 ;; tests: 977 passed, 15 skipped, 8642 warnings
489 #:test-flags
490 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
491 ;; TODO: Package azure-identity (required for this file)
492 "--ignore=tests/test_azure_specific.py"
493 ;; TypeError: Retry.__init__() got an unexpected keyword
494 ;; argument 'timeout'
495 "--deselect=tests/test_gs_specific.py::test_timeout_and_retry")
496 #:phases
497 #~(modify-phases %standard-phases
498 (add-after 'unpack 'fix-pytest-config
499 (lambda _
500 (substitute* "pyproject.toml"
501 (("addopts =.*") "")))))))
502 (native-inputs
503 (list ;; python-azure-identity
504 python-dotenv
505 python-flit-core
506 python-psutil
507 python-pydantic
508 python-pytest
509 python-pytest-cases
510 python-pytest-xdist
511 python-shortuuid
512 python-tenacity))
513 (propagated-inputs
514 (list python-azure-storage-blob
515 python-azure-storage-file-datalake
516 python-boto3
517 python-google-cloud-storage
518 python-typing-extensions))
519 (home-page "https://github.com/drivendataorg/cloudpathlib")
520 (synopsis "Pathlib-style classes for cloud storage services")
521 (description
522 "This package provides a Python library with classes that mimic
523@code{pathlib.Path}'s interface for URIs from different cloud storage
524services.")
525 (license license:expat)))
526
527(define-public python-conda-package-handling
528 (package
529 (name "python-conda-package-handling")
530 (version "2.4.0")
531 (source
532 (origin
533 (method git-fetch)
534 (uri (git-reference
535 (url "https://github.com/conda/conda-package-handling/")
536 (commit version)))
537 (file-name (git-file-name name version))
538 (sha256
539 (base32 "1l2zbbwlxp9azpshixvxnb9354xajxkn88934grpwl70blgb3yq2"))))
540 (build-system pyproject-build-system)
541 (native-inputs
542 (list python-bottle
543 python-mock
544 python-pytest-8
545 python-pytest-cov
546 python-pytest-mock
547 python-setuptools))
548 (propagated-inputs
549 (list python-conda-package-streaming))
550 (home-page "https://conda.io")
551 (synopsis "Create and extract conda packages of various formats")
552 (description
553 "This library is an abstraction of Conda package handling and a tool for
554extracting, creating, and converting between formats.")
555 (license license:bsd-3)))
556
557(define-public python-conda-package-streaming
558 (package
559 (name "python-conda-package-streaming")
560 (version "0.12.0")
561 (source
562 (origin
563 (method url-fetch)
564 (uri (pypi-uri "conda_package_streaming" version))
565 (sha256
566 (base32 "1fcyx83swx1wfndrl0vdk8c2pixshn54gkjy7xchkra13kw2yas2"))))
567 (build-system pyproject-build-system)
568 (arguments
569 ;; TODO: Cycles with python-conda-package-handling, implement bootstrap.
570 (list #:tests? #f))
571 (native-inputs
572 (list python-flit-core))
573 (propagated-inputs
574 (list python-requests
575 python-zstandard))
576 (home-page "https://conda.github.io/conda-package-streaming/")
577 (synopsis "Conda formats (@code{.conda}, @code{.tar.bz2}) reader library")
578 (description
579 "This package provides an efficient library to read from new and old format
580@code{.conda} and @code{.tar.bz2} conda packages.")
581 (license license:bsd-3)))
582
583(define-public python-dependency-groups
584 (package
585 (name "python-dependency-groups")
586 (version "1.3.1")
587 (source
588 (origin
589 (method url-fetch)
590 (uri (pypi-uri "dependency_groups" version))
591 (sha256
592 (base32 "1zgymnk6k984h2wfdpp0vws2ihwqrr9lmxhrij9zs5q5140q61vq"))))
593 (build-system pyproject-build-system)
594 (propagated-inputs (list python-packaging python-tomli))
595 (native-inputs (list python-flit-core python-pytest))
596 (home-page "https://dependency-groups.readthedocs.io/")
597 (synopsis "Tools and library for resolving PEP 735 Dependency Group data")
598 (description
599 "This package provides a library which is able to parse dependency groups (PEP
600735), following includes, and provide that data as output.")
601 (license license:expat)))
602
603(define-public python-devpi-common
604 (package
605 (name "python-devpi-common")
606 (version "4.0.4")
607 (source
608 (origin
609 (method url-fetch)
610 (uri (pypi-uri "devpi_common" version))
611 (sha256
612 (base32 "1k217b0fvsc7k2afw6wwlvqr1ksnv1vjzfm61g358vn98nd0lni3"))))
613 (build-system pyproject-build-system)
614 (propagated-inputs (list python-lazy python-packaging-legacy
615 python-requests))
616 (native-inputs
617 (list python-pytest
618 python-setuptools
619 python-wheel))
620 (home-page "https://github.com/devpi/devpi")
621 (synopsis
622 "Utilities jointly used by devpi-server, devpi-client and others")
623 (description
624 "This package provides utilities jointly used by devpi-server,
625devpi-client and others.")
626 (license license:expat)))
627
628(define-public python-devpi-client
629 (package
630 (name "python-devpi-client")
631 (version "7.2.0")
632 (source
633 (origin
634 (method url-fetch)
635 (uri (pypi-uri "devpi-client" version))
636 (sha256
637 (base32 "0ywx4ql8lsypb17n2miq39bmkrp232sdk8g6pskqp1y3b223chy1"))))
638 (build-system pyproject-build-system)
639 (arguments
640 (list
641 #:test-flags
642 ;; This wants to use pip install
643 '(list "--ignore=testing/test_upload.py"
644 ;; These complain about finding distutils. It's not my fault,
645 ;; mate, setuptools is right there, but you won't pick it!
646 "--ignore=testing/test_list_remove.py"
647 "--ignore=testing/test_main.py"
648 "--ignore=testing/test_install.py"
649 "--ignore=testing/test_functional.py"
650 "--ignore=testing/test_test.py")
651 #:phases
652 '(modify-phases %standard-phases
653 (add-after 'unpack 'patch-tests
654 (lambda _
655 ;; Do not replace the directory name of the store item.
656 (substitute* "testing/conftest.py"
657 (("\"devpi-server\", \"devpi-init\"")
658 "\"/bin/devpi-server\", \"/bin/devpi-init\""))))
659 (add-before 'check 'set-HOME
660 ;; Some tests need this
661 (lambda _ (setenv "HOME" "/tmp"))))))
662 (propagated-inputs (list python-pypa-build
663 python-check-manifest
664 python-colorama
665 python-devpi-common
666 python-iniconfig
667 python-pkginfo
668 python-platformdirs
669 python-pluggy
670 python-pypitoken
671 python-tomli))
672 (native-inputs
673 (list python-devpi-server
674 python-pytest
675 python-setuptools
676 python-virtualenv))
677 (home-page "https://github.com/devpi/devpi")
678 (synopsis "Devpi upload/install/... commands for Python developers")
679 (description
680 "The devpi command line tool is typically used in conjunction with
681devpi-server. It allows uploading, testing and installing packages from devpi
682indexes.")
683 (license license:expat)))
684
685(define-public python-devpi-process
686 (package
687 (name "python-devpi-process")
688 (version "1.0.2")
689 (source
690 (origin
691 (method url-fetch)
692 (uri (pypi-uri "devpi_process" version))
693 (sha256
694 (base32 "0v26i8bs0n8f2ikizwyvq77fw3l0nsyl4wj8yff0r3y351ydqbs1"))))
695 (build-system pyproject-build-system)
696 (arguments
697 (list
698 #:phases
699 '(modify-phases %standard-phases
700 (add-after 'unpack 'relax-requirements
701 (lambda _
702 ;; Our package is too old, sorry.
703 (substitute* "pyproject.toml"
704 (("typing-extensions>=4.12.2")
705 "typing-extensions>=4.10.0"))))
706 (add-after 'unpack 'patch-tool-locations
707 (lambda* (#:key inputs #:allow-other-keys)
708 (substitute* "src/devpi_process/__init__.py"
709 (("_exe\\(\"devpi-init\"\\)")
710 (string-append "\"" (search-input-file inputs "/bin/devpi-init") "\""))
711 (("_exe\\(\"devpi-server\"\\)")
712 (string-append "\"" (search-input-file inputs "/bin/devpi-server") "\""))
713 (("_exe\\(\"devpi\"\\)")
714 (string-append "\"" (search-input-file inputs "/bin/devpi") "\""))))))))
715 (propagated-inputs (list python-devpi-client python-devpi-server
716 python-typing-extensions))
717 (native-inputs
718 (list nss-certs-for-test
719 python-hatchling
720 python-hatch-vcs
721 python-httpx
722 python-pytest
723 python-pytest-cov))
724 (home-page "https://github.com/devpi/devpi")
725 (synopsis "API to create and use a devpi server process")
726 (description
727 "This package provides a programmatic API to create and use a devpi
728server process.")
729 (license license:expat)))
730
731(define-public python-devpi-server
732 (package
733 (name "python-devpi-server")
734 (version "6.17.0")
735 (source
736 (origin
737 (method url-fetch)
738 (uri (pypi-uri "devpi_server" version))
739 (sha256
740 (base32 "13lybrw8j6zjxwvx6sk7bw6854hd2m18s1xcvl0q100j4n06p6ml"))))
741 (build-system pyproject-build-system)
742 (arguments
743 (list
744 #:test-flags
745 ;; These all fail with: "module 'py' has no attribute 'io'"
746 #~(list "--ignore=test_devpi_server/test_importexport.py"
747 "--ignore=test_devpi_server/test_main.py"
748 "--ignore=test_devpi_server/test_genconfig.py")
749 #:phases
750 #~(modify-phases %standard-phases
751 (add-after 'unpack 'relax-requirements
752 (lambda _
753 (substitute* "pyproject.toml"
754 ;; It straggles to check argon2 in passlib on any versions
755 ;; starting from 6.14.0: UnknownExtra("passlib 1.7.4 has no
756 ;; such extra feature 'argon2'",).
757 (("passlib\\[argon2\\]") "passlib")))))))
758 (propagated-inputs (list python-argon2-cffi
759 python-attrs
760 python-defusedxml
761 python-devpi-common
762 python-httpx
763 python-itsdangerous
764 python-lazy
765 python-legacy-cgi
766 python-passlib
767 python-platformdirs
768 python-pluggy
769 python-py
770 python-pyramid
771 python-repoze-lru
772 python-ruamel.yaml-0.16 ;FIXME: rename
773 python-strictyaml
774 python-waitress))
775 (native-inputs
776 (list python-execnet
777 python-pytest
778 python-pytest-asyncio
779 python-pytest-timeout
780 python-setuptools
781 python-webtest))
782 (home-page "https://devpi.net")
783 (synopsis "Pypi.org caching server")
784 (description "This package implements a reliable private and pypi.org
785caching server.")
786 (license license:expat)))
787
788(define-public python-dicomweb-client
789 (package
790 (name "python-dicomweb-client")
791 (version "0.60.0")
792 (source
793 (origin
794 (method git-fetch)
795 (uri (git-reference
796 (url "https://github.com/ImagingDataCommons/dicomweb-client")
797 (commit (string-append "v" version))))
798 (file-name (git-file-name name version))
799 (sha256
800 (base32 "1zad0905cc4jy4hnh9yhcw63bg25f7xa33x9rj9fhh5r4fznha8d"))))
801 (build-system pyproject-build-system)
802 (arguments
803 (list
804 #:phases
805 #~(modify-phases %standard-phases
806 (add-after 'unpack 'remove-dynamic-versioning
807 (lambda _
808 (substitute* "pyproject.toml"
809 ;; Dynamic versioning via 'uv-dynamic-versioning' is
810 ;; not suitable for Guix.
811 (("dynamic = \\[\"version\"\\]")
812 (string-append "version = \""
813 #$version "\""))))))))
814 (native-inputs
815 (list python-hatchling
816 python-pytest
817 python-pytest-localserver))
818 (propagated-inputs
819 (list python-numpy
820 python-pillow
821 python-pydicom
822 python-requests
823 python-retrying))
824 (home-page "https://github.com/ImagingDataCommons/dicomweb-client")
825 (synopsis "Python client for DICOMweb RESTful services")
826 (description
827 "@code{dicomweb_client} provides client intefaces for DICOMweb RESTful
828services QIDO-RS, WADO-RS and STOW-RS to search, retrieve and store
829DICOM objects over the web, respectively.")
830 (license license:expat)))
831
832(define-public python-docusign-esign
833 (package
834 (name "python-docusign-esign")
835 (version "5.0.0")
836 (source
837 (origin
838 (method url-fetch)
839 (uri (pypi-uri "docusign-esign" version))
840 (sha256
841 (base32 "18n9szjxbmsccz4vlvsl4xa73jn0y16l0c344m83gil25v2amn69"))))
842 (build-system pyproject-build-system)
843 ;; Testing requires undocumented setup changes with network access to
844 ;; <demo.docusign.net>, and so testing is disabled here.
845 (arguments `(#:tests? #f))
846 (native-inputs
847 (list python-setuptools
848 python-wheel))
849 (propagated-inputs
850 (list python-certifi
851 python-dateutil
852 python-urllib3
853 python-pyjwt
854 python-cryptography))
855 (home-page "https://developers.docusign.com/")
856 (synopsis "DocuSign Python Client")
857 (description
858 "The Official DocuSign Python Client Library used to interact with the
859eSign REST API. Send, sign, and approve documents using this client.")
860 (license license:expat)))
861
862(define-public python-domain-connect
863 (package
864 (name "python-domain-connect")
865 (version "0.0.11")
866 (source
867 (origin
868 (method git-fetch) ;no tests in PyPI archive
869 (uri (git-reference
870 (url "https://github.com/Domain-Connect/domainconnect_python")
871 (commit (string-append "v" version))))
872 (file-name (git-file-name name version))
873 (sha256
874 (base32 "1dhqbx15h074g51mj73j9hlyvb11isjnj4s9ih5kbw1g4vf1q1jk"))))
875 (build-system pyproject-build-system)
876 (arguments
877 (list
878 ;; Check and sanity-check phases require /etc/resolv.conf, which is not
879 ;; present in container.
880 #:tests? #f
881 #:phases #~(modify-phases %standard-phases (delete 'sanity-check))))
882 (native-inputs
883 (list python-setuptools))
884 (propagated-inputs
885 (list python-cryptography
886 python-dnspython
887 python-future
888 python-publicsuffixlist))
889 (home-page "https://github.com/Domain-Connect/domainconnect_python")
890 (synopsis "Client library for Domain Connect protocol")
891 (description
892 "This package provides a Service Provider functionality in both Sync and
893Async mode for @url{https://domainconnect.org/, Domain Connect protocol}.")
894 (license license:expat)))
895
896(define-public python-domain-connect-dyndns
897 (package
898 (name "python-domain-connect-dyndns")
899 (version "0.0.9")
900 (source
901 (origin
902 (method url-fetch)
903 (uri (pypi-uri "domain-connect-dyndns" version))
904 (sha256
905 (base32 "0srrblcb64bp7k5cqqivx4kykqdkmmzmspxwv66vix9k7wxdwqzx"))))
906 (build-system pyproject-build-system)
907 (arguments
908 (list
909 ;; Check and sanity-check phases require /etc/resolv.conf, which is not
910 ;; present in container.
911 #:tests? #f
912 #:phases #~(modify-phases %standard-phases (delete 'sanity-check))))
913 (native-inputs
914 (list python-setuptools
915 python-wheel))
916 (propagated-inputs
917 (list python-dnspython
918 python-domain-connect
919 python-requests
920 python-validators))
921 (home-page "https://github.com/Domain-Connect/DomainConnectDDNS-Python")
922 (synopsis "Domain Connect Dynamic DNS in Python")
923 ;; Project lacks meaningful description in README, see
924 ;; <https://github.com/Domain-Connect/DomainConnectDDNS-Python/issues/43>.
925 (description
926 "Python client library for Dynamic DNS using
927@url{https://www.domainconnect.org/, Domain Connect} protocol.")
928 (license license:expat)))
929
930(define-public python-dropbox
931 (package
932 (name "python-dropbox")
933 (version "12.0.2")
934 (source
935 (origin
936 (method git-fetch) ; no tests in PyPI release
937 (uri (git-reference
938 (url "https://github.com/dropbox/dropbox-sdk-python")
939 (commit (string-append "v" version))))
940 (file-name (git-file-name name version))
941 (sha256
942 (base32 "0pyvi2mbibah42kq8804d98ghypm46wr8swqr34apnvnlp9j2nzl"))))
943 (build-system pyproject-build-system)
944 (arguments
945 (list
946 #:test-flags
947 #~(list "-k" (string-join
948 ;; Network access is required.
949 (list "not test_bad_auth"
950 "test_app_auth"
951 "test_bad_pins"
952 "test_bad_pins_session"
953 "test_downscope"
954 "test_multi_auth"
955 "test_path_root"
956 "test_path_root_err"
957 "test_refresh"
958 "test_rpc"
959 "test_team"
960 "test_upload_download"
961 "test_versioned_route")
962 " and not "))
963 #:phases
964 #~(modify-phases %standard-phases
965 (add-after 'unpack 'relax-requirements
966 (lambda _
967 (substitute* "setup.py"
968 ;; 'stone>=2,<3.3.3',
969 ((">=2,<3.3.3") ">=2,<3.4.0"))))
970 (add-before 'check 'pre-check
971 (lambda _
972 ;; Otherwise tests setup erroring.
973 (setenv "LEGACY_USER_DROPBOX_TOKEN" "guix")
974 (setenv "LEGACY_USER_CLIENT_ID" "guix")
975 (setenv "LEGACY_USER_CLIENT_SECRET" "guix")
976 (setenv "LEGACY_USER_REFRESH_TOKEN" "guix")
977 (setenv "SCOPED_USER_DROPBOX_TOKEN" "guix")
978 (setenv "SCOPED_USER_CLIENT_ID" "guix")
979 (setenv "SCOPED_USER_CLIENT_SECRET" "guix")
980 (setenv "SCOPED_USER_REFRESH_TOKEN" "guix")
981 (setenv "SCOPED_TEAM_DROPBOX_TOKEN" "guix")
982 (setenv "SCOPED_TEAM_CLIENT_ID" "guix")
983 (setenv "SCOPED_TEAM_CLIENT_SECRET" "guix")
984 (setenv "SCOPED_TEAM_REFRESH_TOKEN" "guix")
985 (setenv "DROPBOX_SHARED_LINK" "guix"))))))
986 (native-inputs
987 (list nss-certs-for-test
988 python-mock
989 python-pytest
990 python-pytest-mock
991 python-setuptools
992 python-wheel))
993 (propagated-inputs
994 (list python-requests python-six python-stone))
995 (home-page "https://www.dropbox.com/developers")
996 (synopsis "Official Dropbox API Client")
997 (description "This package provides a Python SDK for integrating with the
998Dropbox API v2.")
999 (license license:expat)))
1000
1001(define-public python-essentials-openapi
1002 (package
1003 (name "python-essentials-openapi")
1004 (version "1.2.1")
1005 (source
1006 (origin
1007 (method git-fetch)
1008 (uri (git-reference
1009 (url "https://github.com/Neoteroi/essentials-openapi")
1010 (commit (string-append "v" version))))
1011 (file-name (git-file-name name version))
1012 (sha256
1013 (base32 "0f3lhpkqhvv8sr1c34cvzdqkc61306m03w3jp0zdih1v6is05j8x"))))
1014 (build-system pyproject-build-system)
1015 (native-inputs
1016 (list python-flask
1017 python-hatchling
1018 python-pydantic
1019 python-pytest
1020 python-rich))
1021 (propagated-inputs
1022 (list python-essentials
1023 python-httpx
1024 python-jinja2
1025 python-markupsafe
1026 python-pyyaml))
1027 (home-page "https://github.com/Neoteroi/essentials-openapi/")
1028 (synopsis "Generator for OpenAPI Documentation")
1029 (description
1030 "Generator for OpenAPI Documentation version 2 and 3, in JSON and YAML
1031formats. Generator for other kinds of documents from OpenAPI Documentation
1032files.")
1033 (license license:expat)))
1034
1035(define-public python-eventlet
1036 (package
1037 (name "python-eventlet")
1038 (version "0.40.2")
1039 (source
1040 (origin
1041 (method url-fetch)
1042 (uri (pypi-uri "eventlet" version))
1043 (sha256
1044 (base32
1045 "1c6qr1cnam79wxm1sh5y04061iyy3shs02yd0mlh47bngwknqqs2"))))
1046 (build-system pyproject-build-system)
1047 (arguments
1048 (list
1049 #:test-flags
1050 '(list "-k"
1051 (string-append
1052 "not TestGetaddrinfo"
1053 " and not TestProxyResolver"
1054 " and not test_noraise_dns_tcp"
1055 " and not test_raise_dns_tcp"
1056 " and not test_hosts_no_network"
1057 " and not test_import_rdtypes_then_eventlet"
1058 " and not test_patcher_existing_locks"
1059 " and not test_dns_methods_are_green"))
1060 #:phases
1061 #~(modify-phases %standard-phases
1062 (add-after 'unpack 'avoid-OSError
1063 (lambda _
1064 ;; If eventlet tries to load greendns, an OSError is thrown when
1065 ;; getprotobyname is called. Thankfully there is an environment
1066 ;; variable to disable the greendns import, so use it. Note that
1067 ;; this error is propagated to child packages too, so enforce the
1068 ;; changed default.
1069 (substitute* "eventlet/green/socket.py"
1070 (("os\\.environ\\.get\\(\"EVENTLET_NO_GREENDNS\", ''\\)")
1071 "os.environ.get(\"EVENTLET_NO_GREENDNS\", \"yes\")")))))))
1072 (native-inputs
1073 (list python-pypa-build
1074 python-hatch-vcs
1075 python-hatchling
1076 python-pytest))
1077 (propagated-inputs
1078 (list python-dnspython python-greenlet))
1079 (home-page "https://eventlet.net")
1080 (synopsis "Concurrent networking library for Python")
1081 (description
1082 "Eventlet is a concurrent networking library for Python that
1083allows you to change how you run your code, not how you write it.
1084It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O.
1085Coroutines ensure that the developer uses a blocking style of programming
1086that is similar to threading, but provide the benefits of non-blocking I/O.
1087The event dispatch is implicit, which means you can easily use @code{Eventlet}
1088from the Python interpreter, or as a small part of a larger application.
1089
1090Note: In Guix, this package assumes the environment variable
1091@code{EVENTLET_NO_GREENDNS} defaults to @code{yes}. To try to use it, set it
1092to anything else.")
1093 (license license:expat)))
1094
1095(define-public python-flask-caching
1096 (package
1097 (name "python-flask-caching")
1098 (version "2.3.1")
1099 (source
1100 (origin
1101 (method url-fetch)
1102 (uri (pypi-uri "flask_caching" version))
1103 (sha256
1104 (base32 "1jcqgfzvqhgpngf9nhpfjs129cslh8jyczfy8kw11y7b9qdzvmv5"))))
1105 (build-system pyproject-build-system)
1106 (arguments
1107 (list
1108 #:test-flags
1109 ;; Tests requiring running Redis or dated python-cache.
1110 #~(list "--deselect=tests/test_init.py::test_init_nullcache[MemcachedCache]"
1111 "--deselect=tests/test_init.py::test_init_nullcache[RedisCache]"
1112 "--deselect=tests/test_init.py::test_init_nullcache[RedisSentinelCache]"
1113 "--deselect=tests/test_init.py::test_init_nullcache[SASLMemcachedCache]"
1114 "--deselect=tests/test_init.py::test_init_nullcache[SpreadSASLMemcachedCache]"
1115 "-k" "not test_client_override_reflected_on_cachelib_methods")))
1116 (native-inputs
1117 (list python-pytest
1118 python-pytest-asyncio
1119 python-pytest-xprocess
1120 python-setuptools))
1121 (propagated-inputs
1122 (list python-cachelib
1123 python-flask))
1124 (home-page "https://github.com/pallets-eco/flask-caching")
1125 (synopsis "Caching extension for Flask")
1126 (description
1127 "This package provides a caching support to Flask applications, it's a
1128fort ok https://github.com/thadeusb/flask-cache.")
1129 (license license:bsd-3)))
1130
1131(define-public python-flask-paginate
1132 (package
1133 (name "python-flask-paginate")
1134 (version "2024.4.12")
1135 (source
1136 (origin
1137 (method git-fetch)
1138 (uri (git-reference
1139 (url "https://github.com/lixxu/flask-paginate")
1140 (commit (string-append "v" version))))
1141 (file-name (git-file-name name version))
1142 (sha256
1143 (base32 "1q4ajwk0pzc6934g07gdryjcwi6rd9iqcwv5g5s718dfx2bj1831"))))
1144 (arguments
1145 (list #:test-backend #~'custom
1146 #:test-flags #~(list "tests/tests.py")))
1147 (build-system pyproject-build-system)
1148 (native-inputs
1149 (list python-pytest
1150 python-setuptools))
1151 (propagated-inputs
1152 (list python-flask))
1153 (home-page "https://github.com/lixxu/flask-paginate")
1154 (synopsis "Simple paginate support for Flask")
1155 (description
1156 "Flask-paginate is a simple pagination extension for Flask which is
1157inspired by Ruby's will_paginate library. It supports several CSS frameworks.")
1158 (license license:bsd-3)))
1159
1160(define-public python-gdown
1161 (package
1162 (name "python-gdown")
1163 (version "5.2.0")
1164 (source
1165 (origin
1166 (method url-fetch)
1167 (uri (pypi-uri "gdown" version))
1168 (sha256
1169 (base32 "11y7xx6zjipx15a5626lhiwmwb2jxp4mdcwqrnij0mfqc981ci91"))))
1170 (build-system pyproject-build-system)
1171 (arguments (list #:tests? #f)) ;network access is required
1172 (native-inputs
1173 (list python-hatch-fancy-pypi-readme
1174 python-hatch-vcs
1175 python-hatchling))
1176 (propagated-inputs
1177 (list python-beautifulsoup4
1178 python-filelock
1179 python-requests
1180 python-tqdm))
1181 (home-page "https://github.com/wkentaro/gdown")
1182 (synopsis "Google Drive Public File/Folder Downloader")
1183 (description
1184 "This package implements a functionality to download large files
1185recursivly from Google Drive with option to filter them by file
1186formats (PDF/XML/CSV).")
1187 (license license:expat)))
1188
1189(define-public python-globus-sdk
1190 (package
1191 (name "python-globus-sdk")
1192 (version "4.4.0")
1193 (source
1194 (origin
1195 (method git-fetch)
1196 (uri (git-reference
1197 (url "https://github.com/globus/globus-sdk-python")
1198 (commit version)))
1199 (file-name (git-file-name name version))
1200 (sha256
1201 (base32 "1d0zw9dkpdhsf9zdg3nk6b55gqwzc3v2rj76nj7999hjmq8350vh"))))
1202 (build-system pyproject-build-system)
1203 (arguments
1204 (list
1205 #:phases
1206 #~(modify-phases %standard-phases
1207 (add-before 'check 'pre-check
1208 (lambda _ (setenv "HOME" "/tmp"))))))
1209 (native-inputs
1210 (list python-flaky
1211 python-pytest
1212 python-pytest-randomly
1213 python-responses
1214 python-setuptools))
1215 (propagated-inputs
1216 (list python-cryptography
1217 python-importlib-resources
1218 python-pyjwt
1219 python-requests))
1220 (home-page "https://github.com/globus/globus-sdk-python")
1221 (synopsis "Globus SDK for Python")
1222 (description
1223 "This package provides a SDK for convenient Pythonic interface to
1224@url{https://www.globus.org/, Globus} APIs.")
1225 (license license:asl2.0)))
1226
1227(define-public python-guardpost
1228 (package
1229 (name "python-guardpost")
1230 (version "1.0.4")
1231 (source
1232 (origin
1233 (method git-fetch)
1234 (uri (git-reference
1235 (url "https://github.com/Neoteroi/guardpost")
1236 (commit (string-append "v" version))))
1237 (file-name (git-file-name name version))
1238 (sha256
1239 (base32 "1xsakqn36g2h1s5rnbaf1lasx1jn4skqhmb8kdl1k4pgxp5sczyy"))))
1240 (build-system pyproject-build-system)
1241 (arguments
1242 (list
1243 ;; Possible timing issue, see:
1244 ;; <https://github.com/Neoteroi/GuardPost/issues/18>.
1245 #:test-flags '(list "--ignore=tests/test_jwts.py")))
1246 (native-inputs
1247 (list python-flask
1248 python-hatchling
1249 python-pytest
1250 python-pytest-asyncio))
1251 (propagated-inputs
1252 (list python-rodi
1253 ;; [optional]
1254 python-cryptography
1255 python-essentials
1256 python-pyjwt))
1257 (home-page "https://github.com/Neoteroi/GuardPost/")
1258 (synopsis
1259 "Authentication and authorization framework for Python applications")
1260 (description
1261 "GuardPost is a framework to handle authentication and
1262authorization in asynchronous Python applications.
1263
1264Its features include
1265
1266@itemize
1267@item Strategy to implement authentication.
1268@item Strategy to implement authorization.
1269@item Support for dependency injection
1270@item Built-in support for JSON Web Tokens (JWTs) authentication.
1271@end itemize")
1272 (license license:expat)))
1273
1274(define-public python-hookdns
1275 (package
1276 (name "python-hookdns")
1277 (version "2.0.0")
1278 (source
1279 (origin
1280 (method url-fetch)
1281 (uri (pypi-uri "hookdns" version))
1282 (sha256
1283 (base32 "087x12dy6slhyqwqblby2fpjdcy61yk3lqp3fplami0rmbn02fb7"))))
1284 (build-system pyproject-build-system)
1285 (arguments
1286 (list
1287 #:test-flags
1288 #~(list "-k" (string-join
1289 ;; Tests requiring networking.
1290 (list
1291 "not test_patch_contextmanager_with_another_hostname"
1292 "test_patch_contextmanager_with_another_hostname_ipv6"
1293 "test_patch_contextmanager_with_ipv4"
1294 "test_patch_contextmanager_with_name"
1295 "test_patch_contextmanager_with_public_fqdn_and_"
1296 "test_patch_contextmanager_with_unknown_hostname"
1297 "test_patch_decorator_with_another_hostname"
1298 "test_patch_decorator_with_another_hostname_ipv6"
1299 "test_patch_decorator_with_ipv4"
1300 "test_patch_decorator_with_name"
1301 "test_patch_decorator_with_public_fqdn_and_a_name_for_"
1302 "test_patch_decorator_with_unknown_hostname"
1303 "test_real_getaddrinfo_with_name_ipv6"
1304 "test_real_getaddrinfo_with_public_fqdn_ipv4"
1305 "test_real_getaddrinfo_with_public_fqdn_ipv6"
1306 "test_real_gethostbyname_ex_with_public_fqdn"
1307 "test_real_gethostbyname_with_public_fqdn"
1308 "test_real_requests_ip"
1309 "test_real_requests_name"
1310 "test_real_requests_with_public_fqdn"
1311 "test_reentrant")
1312 " and not "))))
1313 (native-inputs
1314 (list python-pytest
1315 python-requests
1316 python-setuptools
1317 python-wheel))
1318 (home-page "https://github.com/cle-b/hookdns")
1319 (synopsis "DNS resolution customization library")
1320 (description
1321 "HookDNS implements functionality that allows for modifying name
1322resolution in a Python script without any changes to the hosts file or the use
1323of a fake DNS resolver.")
1324 (license license:asl2.0)))
1325
1326(define-public python-httpretty
1327 (package
1328 (name "python-httpretty")
1329 (version "1.1.4")
1330 (source
1331 (origin
1332 (method url-fetch)
1333 (uri (pypi-uri "httpretty" version))
1334 (sha256
1335 (base32 "0s1vjdaf3pk2xd0hvi5f7p3jm2rgwpbc734jdp9r50m1smfhxpi0"))))
1336 (build-system pyproject-build-system)
1337 (arguments
1338 (list
1339 #:test-flags
1340 ;; Only run Unit tests.
1341 #~(list "--ignore=tests/bugfixes"
1342 "--ignore=tests/functional"
1343 "--ignore=tests/pyopenssl"
1344 "-k" (string-join
1345 ;; Tests pattern failing with one of these errors:
1346 ;; AttributeError: '(str|bool|bytes|list|tuple)' object
1347 ;; has no attribute 'should'
1348 ;; AttributeError: 'function' object has no attribute
1349 ;; 'when'
1350 ;; AttributeError: 'AssertionBuilder' object has no
1351 ;; attribute 'should_not'
1352 (list "not fake_socket_passes_through"
1353 "fakesock_socket"
1354 "request_parse_body_when"
1355 "test_Entry_class_normalizes_headers"
1356 "test_has_request"
1357 "test_httpretty_should_raise_proper"
1358 "test_parse_request_line_connect"
1359 "test_request_parse_querystring"
1360 "test_request_string_representation"
1361 "test_request_stubs_internals")
1362 " and not "))))
1363 (native-inputs
1364 (list nss-certs-for-test
1365 python-freezegun
1366 python-mock
1367 python-pytest
1368 python-setuptools
1369 python-sure
1370 python-wheel))
1371 (home-page "https://httpretty.readthedocs.io")
1372 (synopsis "HTTP client mock for Python")
1373 (description
1374 "@code{httpretty} is a helper for faking web requests,inspired by Ruby's
1375@code{fakeweb}.")
1376 (license license:expat)))
1377
1378(define-public python-huggingface-hub
1379 (package
1380 (name "python-huggingface-hub")
1381 (version "0.31.4")
1382 (source
1383 (origin
1384 (method git-fetch)
1385 (uri (git-reference
1386 (url "https://github.com/huggingface/huggingface_hub")
1387 (commit (string-append "v" version))))
1388 (file-name (git-file-name name version))
1389 (sha256
1390 (base32 "1rjkrmvvyzxlbnbndrg4v9qq39grn46c26zrdjgpf114gci5pwap"))))
1391 (build-system pyproject-build-system)
1392 (arguments
1393 (list
1394 #:test-flags
1395 ;; We don't have sentence_transformers...
1396 '(list "--ignore=contrib/sentence_transformers/test_sentence_transformers.py"
1397 ;; ...nor do we have InquirerPy...
1398 "--ignore=tests/test_command_delete_cache.py"
1399 ;; ...or timm...
1400 "--ignore=contrib/timm/test_timm.py"
1401 ;; ...or spacy_huggingface_hub
1402 "--ignore=contrib/spacy/test_spacy.py"
1403 ;; These all require internet access
1404 "--ignore=tests/test_cache_no_symlinks.py"
1405 "--ignore=tests/test_cache_layout.py"
1406 "--ignore=tests/test_commit_scheduler.py"
1407 "--ignore=tests/test_file_download.py"
1408 "--ignore=tests/test_hf_api.py"
1409 "--ignore=tests/test_hf_file_system.py"
1410 "--ignore=tests/test_inference_api.py"
1411 "--ignore=tests/test_inference_async_client.py"
1412 "--ignore=tests/test_inference_client.py"
1413 "--ignore=tests/test_inference_text_generation.py"
1414 "--ignore=tests/test_login_utils.py"
1415 "--ignore=tests/test_offline_utils.py"
1416 "--ignore=tests/test_repocard.py"
1417 "--ignore=tests/test_repository.py"
1418 "--ignore=tests/test_snapshot_download.py"
1419 "--ignore=tests/test_utils_cache.py"
1420 "--ignore=tests/test_utils_git_credentials.py"
1421 "--ignore=tests/test_utils_http.py"
1422 "--ignore=tests/test_utils_pagination.py"
1423 "--ignore=tests/test_webhooks_server.py"
1424 "-k" (string-append
1425 "not test_push_to_hub"
1426 " and not test_from_pretrained_model_id_only"
1427 " and not test_from_pretrained_model_id_and_revision"
1428 ;; These all require internet access
1429 " and not test_auth"
1430 " and not test_oauth"
1431 " and not test_utils_sha"
1432 " and not test_inference_providers"
1433 " and not test_xet"))
1434 #:phases
1435 '(modify-phases %standard-phases
1436 (add-before 'check 'pre-check
1437 ;; Some tests need to write to HOME.
1438 (lambda _ (setenv "HOME" "/tmp"))))))
1439 (propagated-inputs
1440 (list python-filelock
1441 python-fsspec
1442 python-packaging
1443 python-pyyaml
1444 python-requests
1445 python-tqdm
1446 python-typing-extensions))
1447 (native-inputs
1448 (list python-aiohttp
1449 python-fastapi
1450 python-jedi
1451 python-jinja2
1452 python-numpy
1453 python-pillow
1454 python-pydantic
1455 python-pytest
1456 python-pytest-asyncio
1457 python-pytest-cov
1458 python-pytest-env
1459 python-pytest-mock
1460 python-pytest-rerunfailures
1461 python-pytest-vcr
1462 python-pytest-xdist
1463 python-setuptools
1464 python-types-requests
1465 python-types-toml
1466 python-types-urllib3
1467 python-typing-extensions
1468 python-urllib3
1469 python-wheel))
1470 (home-page "https://huggingface.co/docs/huggingface_hub/")
1471 (synopsis "Client library for accessing the huggingface.co hub")
1472 (description
1473 "This package provides a client library to download and publish models,
1474datasets and other repos on the @url{huggingface.co} hub.")
1475 (license license:asl2.0)))
1476
1477(define-public python-kubernetes
1478 (package
1479 (name "python-kubernetes")
1480 (version "35.0.0")
1481 (source
1482 (origin
1483 (method url-fetch)
1484 (uri (pypi-uri "kubernetes" version))
1485 (sha256
1486 (base32 "1vh9bzq175fzv9av3v37lcfh37yzss2d9vxrb0a84fa2ji2d601x"))))
1487 (build-system pyproject-build-system)
1488 (arguments
1489 (list
1490 #:test-flags
1491 #~(list
1492 ;; The following tests expect a local running Kubernetes cluster.
1493 "--ignore=kubernetes/e2e_test"
1494 "--ignore=kubernetes/dynamic")))
1495 (native-inputs
1496 (list python-pytest
1497 python-setuptools))
1498 (propagated-inputs
1499 (list python-certifi
1500 python-dateutil
1501 python-durationpy
1502 python-google-auth
1503 python-pyyaml
1504 python-requests
1505 python-requests-oauthlib
1506 python-six ;XXX: hard dependency
1507 python-urllib3
1508 python-websocket-client))
1509 (home-page "https://github.com/kubernetes-client/python")
1510 (synopsis "Python client for Kubernetes")
1511 (description
1512 "This package provides an official Python client library for
1513@url{http://kubernetes.io, Kubernetes}.")
1514 (license license:asl2.0)))
1515
1516(define-public python-lazr-restfulclient
1517 (package
1518 (name "python-lazr-restfulclient")
1519 (version "0.14.6")
1520 (source
1521 (origin
1522 (method url-fetch)
1523 (uri (pypi-uri "lazr.restfulclient" version))
1524 (sha256
1525 (base32 "1nzzmp9aaaxh25jy3wm71cpf9dfw56s4g303c8a3nij874fjmwa3"))))
1526 (build-system pyproject-build-system)
1527 (arguments
1528 (list
1529 #:phases
1530 #~(modify-phases %standard-phases
1531 ;; Disable part of the test suite to avoid the lazr.authentication
1532 ;; requirement, which requires 'oauth', a Python 2 only library.
1533 (add-after 'unpack 'remove-some-checks
1534 (lambda _
1535 (with-directory-excursion "src/lazr/restfulclient/tests"
1536 (for-each delete-file '("test_oauth.py" "test_docs.py")))
1537 (substitute* "setup.py"
1538 (("\"(oauth|lazr\\.(authentication|restful>=0\\.11\\.0))\",")
1539 ""))))
1540 (replace 'check
1541 (lambda* (#:key tests? #:allow-other-keys)
1542 (if tests?
1543 (invoke "zope-testrunner" "--test-path=src")
1544 (format #t "test suite not run~%")))))))
1545 (native-inputs
1546 (list python-setuptools
1547 python-testtools
1548 python-wheel
1549 python-wsgi-intercept
1550 python-zope-testrunner))
1551 (propagated-inputs
1552 (list python-distro
1553 python-httplib2
1554 python-oauthlib
1555 python-pyparsing
1556 python-setuptools
1557 python-six
1558 python-wadllib))
1559 (home-page "https://launchpad.net/lazr.restfulclient")
1560 (synopsis "Web client Python library extending wadlib")
1561 (description "This package provides a programmable client library that
1562adds functionality on top of @code{wadlib}.")
1563 (license license:lgpl3+)))
1564
1565(define-public python-launchpadlib
1566 (package
1567 (name "python-launchpadlib")
1568 (version "2.1.0")
1569 (source
1570 (origin
1571 (method url-fetch)
1572 (uri (pypi-uri "launchpadlib" version))
1573 (sha256
1574 (base32 "0br4j76l83lvyrhm8psml9cqmdsn65rx48w1q1a0s1bmpf85ihml"))))
1575 (build-system pyproject-build-system)
1576 (arguments
1577 (list #:phases #~(modify-phases %standard-phases
1578 (add-before 'check 'set-home
1579 (lambda _
1580 ;; Tests require a writable home.
1581 (setenv "HOME" "/tmp"))))))
1582 (propagated-inputs
1583 (list python-httplib2 python-lazr-restfulclient python-lazr-uri))
1584 (native-inputs (list python-pytest python-testresources python-wadllib
1585 python-setuptools python-wheel))
1586 (home-page "https://documentation.ubuntu.com/launchpad")
1587 (synopsis "Python client library for Launchpad's web service")
1588 (description "@code{launchpadlib} is a Python library that allows
1589scripting Launchpad via its the web service API.")
1590 (license license:lgpl3+)))
1591
1592(define-public python-lazr-uri
1593 (package
1594 (name "python-lazr-uri")
1595 (version "1.0.7")
1596 (source
1597 (origin
1598 (method url-fetch)
1599 (uri (pypi-uri "lazr_uri" version))
1600 (sha256
1601 (base32 "1vm34pw8fksc6m8fnqwh215sqdlw546cxcdga93i2l746grzc37d"))))
1602 (build-system pyproject-build-system)
1603 (arguments
1604 (list
1605 #:phases
1606 #~(modify-phases %standard-phases
1607 (replace 'check
1608 (lambda* (#:key tests? #:allow-other-keys)
1609 (if tests?
1610 (invoke "zope-testrunner" "--test-path=src")
1611 (format #t "test suite not run~%")))))))
1612 (native-inputs (list python-setuptools python-zope-testrunner))
1613 (home-page "https://launchpad.net/lazr.uri")
1614 (synopsis "Python URI manipulation library")
1615 (description "This Python package provides a self-contained, easily
1616reusable library for parsing, manipulating, and generating URIs.")
1617 (license license:lgpl3)))
1618
1619(define-public python-ldaptor
1620 (package
1621 (name "python-ldaptor")
1622 (version "21.2.0")
1623 (source
1624 (origin
1625 (method url-fetch)
1626 (uri (pypi-uri "ldaptor" version))
1627 (sha256
1628 (base32 "0n53czn5pyh8923y282spdb7xc8c9rhn0n43bczanjjx6wcynjcc"))))
1629 (build-system pyproject-build-system)
1630 (arguments
1631 (list
1632 #:test-flags
1633 #~(list "-m" "twisted.trial"
1634 (string-append "-j" (number->string (parallel-job-count)))
1635 "ldaptor")
1636 #:phases
1637 #~(modify-phases %standard-phases
1638 (add-before 'check 'disable-failing-tests
1639 (lambda _
1640 ;; Testing with Twisted 22.4 results in infinite loop creating
1641 ;; temporary config files, see
1642 ;; <https://github.com/twisted/ldaptor/issues/238>.
1643 (delete-file "ldaptor/test/test_config.py")))
1644 (replace 'check
1645 (lambda* (#:key tests? test-flags #:allow-other-keys)
1646 (when tests?
1647 (apply invoke "python" test-flags)))))))
1648 (native-inputs
1649 (list python-setuptools
1650 python-wheel))
1651 (propagated-inputs
1652 (list python-passlib
1653 python-pyopenssl
1654 python-service-identity ; to pass sanity check, for Twisted[tls]
1655 python-pyparsing
1656 python-twisted
1657 python-zope-interface))
1658 (home-page "https://github.com/twisted/ldaptor")
1659 (synopsis "Pure-Python Twisted library for LDAP")
1660 (description
1661 "This package provides a Python Twisted library for LDAP, which key
1662feaatures are:
1663@itemize
1664@item LDAP client logic
1665@item separately-accessible LDAP and BER protocol message generation/parsing
1666@item ASCII-format LDAP filter generation and parsing
1667@item LDIF format data generation
1668@item Samba password changing logic
1669@end itemize")
1670 (license license:expat)))
1671
1672(define-public python-legacy-cgi
1673 (package
1674 (name "python-legacy-cgi")
1675 (version "2.6.1")
1676 (source
1677 (origin
1678 (method url-fetch)
1679 (uri (pypi-uri "legacy_cgi" version))
1680 (sha256
1681 (base32 "0hksizyq7awmwh3337zy0rmj47x6b5igzam6ffj74gbwfjfakbgj"))))
1682 (build-system pyproject-build-system)
1683 (native-inputs (list python-poetry-core python-pytest))
1684 (home-page "https://github.com/jackrosenthal/legacy-cgi")
1685 (synopsis "Fork of the legacy standard library cgi and cgitb modules")
1686 (description
1687 "This is a fork of the standard library modules @code{cgi} and
1688@code{cgitb}. They are slated to be removed from the Python standard library
1689in Python 3.13 by PEP-594.")
1690 (license license:psfl)))
1691
1692(define-public python-librouteros
1693 (package
1694 (name "python-librouteros")
1695 (version "4.0.0")
1696 (source
1697 (origin
1698 (method git-fetch)
1699 (uri (git-reference
1700 (url "https://github.com/luqasz/librouteros")
1701 (commit version)))
1702 (file-name (git-file-name name version))
1703 (sha256
1704 (base32 "0in952b2idb5j8v6sxfm21gqbr5i5776w5ir0hdsxjrl2f29305v"))))
1705 (build-system pyproject-build-system)
1706 (arguments
1707 (list
1708 #:build-backend "hatchling.build"
1709 #:test-flags
1710 #~(list "tests/unit")))
1711 (native-inputs
1712 (list python-hatchling
1713 python-pytest
1714 python-pytest-asyncio
1715 python-stamina))
1716 (home-page "https://github.com/luqasz/librouteros")
1717 (synopsis "Python implementation of MikroTik RouterOS API")
1718 (description
1719 "This package implements MikroTik's @code{RouterOS} API.")
1720 (license license:gpl2+)))
1721
1722(define-public python-opentelemetry-api
1723 (package
1724 (name "python-opentelemetry-api")
1725 (version "1.37.0")
1726 (source
1727 (origin
1728 (method url-fetch)
1729 (uri (pypi-uri "opentelemetry_api" version))
1730 (sha256
1731 (base32 "19yr3hfwdc9sv8df4vydxcsxnpld3xi57siq4w8xanrm42qka1sl"))))
1732 (build-system pyproject-build-system)
1733 (propagated-inputs (list python-importlib-metadata
1734 python-typing-extensions))
1735 (native-inputs (list python-hatchling
1736 python-opentelemetry-test-utils-bootstrap))
1737 (home-page "https://opentelemetry.io/docs/languages/python/")
1738 (synopsis "OpenTelemetry Python API")
1739 (description "@code{OpenTelemetry} Python API.")
1740 (license license:asl2.0)))
1741
1742(define-public python-opentelemetry-api-bootstrap
1743 (hidden-package
1744 (package/inherit python-opentelemetry-api
1745 (name "python-opentelemetry-api-bootstrap")
1746 (arguments
1747 (list
1748 #:tests? #f))
1749 (native-inputs (list python-hatchling)))))
1750
1751(define-public python-opentelemetry-sdk
1752 (package
1753 (name "python-opentelemetry-sdk")
1754 (version "1.37.0")
1755 (source
1756 (origin
1757 (method url-fetch)
1758 (uri (pypi-uri "opentelemetry_sdk" version))
1759 (sha256
1760 (base32 "19fx8vf35kcss43i17zqngqhmglb36dnddasbdvfsgcm22f0i3nc"))))
1761 (build-system pyproject-build-system)
1762 (propagated-inputs (list python-opentelemetry-api
1763 python-opentelemetry-semantic-conventions
1764 python-typing-extensions))
1765 (native-inputs (list python-hatchling
1766 python-opentelemetry-test-utils-bootstrap
1767 python-pytest))
1768 (home-page "https://opentelemetry.io/docs/languages/python/")
1769 (synopsis "OpenTelemetry Python SDK")
1770 (description "@code{OpenTelemetry} Python SDK.")
1771 (license license:asl2.0)))
1772
1773(define-public python-opentelemetry-sdk-bootstrap
1774 (hidden-package
1775 (package/inherit python-opentelemetry-sdk
1776 (name "python-opentelemetry-sdk-bootstrap")
1777 (arguments (list #:tests? #f))
1778 (propagated-inputs (list python-opentelemetry-api-bootstrap
1779 python-opentelemetry-semantic-conventions-bootstrap))
1780 (native-inputs (list python-hatchling)))))
1781
1782(define-public python-opentelemetry-semantic-conventions
1783 (package
1784 (name "python-opentelemetry-semantic-conventions")
1785 (version "0.58b0")
1786 (source
1787 (origin
1788 (method url-fetch)
1789 (uri (pypi-uri "opentelemetry_semantic_conventions" version))
1790 (sha256
1791 (base32 "098czakcawikaspl46vy6vickw80mm2bnrspflrw8ya24r8nzm3b"))))
1792 (build-system pyproject-build-system)
1793 (propagated-inputs (list python-opentelemetry-api python-typing-extensions))
1794 (native-inputs (list python-hatchling))
1795 (home-page "https://opentelemetry.io/docs/languages/python/")
1796 (synopsis "OpenTelemetry Semantic Conventions")
1797 (description "@code{OpenTelemetry} Semantic Conventions.")
1798 (license license:asl2.0)))
1799
1800(define-public python-opentelemetry-semantic-conventions-bootstrap
1801 (hidden-package
1802 (package/inherit python-opentelemetry-semantic-conventions
1803 (name "python-opentelemetry-semantic-conventions-bootstrap")
1804 (arguments
1805 (list
1806 #:tests? #f))
1807 (propagated-inputs (list python-opentelemetry-api-bootstrap
1808 python-typing-extensions)))))
1809
1810(define-public python-opentelemetry-test-utils
1811 (package
1812 (name "python-opentelemetry-test-utils")
1813 (version "0.58b0")
1814 (source
1815 (origin
1816 (method url-fetch)
1817 (uri (pypi-uri "opentelemetry_test_utils" version))
1818 (sha256
1819 (base32 "0xjp04zjn7m79xsda9wp79rqyzy2c10347s967vp7xvmndwwa0ds"))))
1820 (build-system pyproject-build-system)
1821 (propagated-inputs (list python-asgiref python-opentelemetry-api
1822 python-opentelemetry-sdk))
1823 (native-inputs (list python-hatchling))
1824 (home-page "https://opentelemetry.io/docs/languages/python/")
1825 (synopsis "Test utilities for OpenTelemetry unit tests")
1826 (description "Test utilities for @code{OpenTelemetry} unit tests.")
1827 (license license:asl2.0)))
1828
1829(define-public python-opentelemetry-test-utils-bootstrap
1830 (hidden-package
1831 (package/inherit python-opentelemetry-test-utils
1832 (name "python-opentelemetry-test-utils-bootstrap")
1833 (arguments
1834 (list
1835 #:tests? #f))
1836 (propagated-inputs (list python-asgiref
1837 python-opentelemetry-api-bootstrap
1838 python-opentelemetry-sdk-bootstrap))
1839 (native-inputs (list python-hatchling)))))
1840
1841(define-public python-pathy
1842 (package
1843 (name "python-pathy")
1844 (version "0.11.0")
1845 (source
1846 (origin
1847 (method url-fetch)
1848 (uri (pypi-uri "pathy" version))
1849 (sha256
1850 (base32 "0vbhcfg8g74g90bzmdgxr1jyvwhadvlr2w9wyvs6xxwb1dmhwgdv"))))
1851 (build-system pyproject-build-system)
1852 (native-inputs
1853 (list python-mock
1854 python-pytest
1855 python-setuptools))
1856 (propagated-inputs
1857 (list python-pathlib-abc-for-python-pathy
1858 python-smart-open-6
1859 python-typer))
1860 (home-page "https://github.com/justindujardin/pathy")
1861 (synopsis "Path interface for local and cloud bucket storage")
1862 (description "Pathy is a python package (with type annotations) for
1863working with Cloud Bucket storage providers using a @code{pathlib} interface.
1864It provides @code{pathlib.Path} subclasses for local and cloud bucket
1865storage.")
1866 (license license:asl2.0)))
1867
1868(define-public python-portend
1869 (package
1870 (name "python-portend")
1871 (version "3.2.1")
1872 (source
1873 (origin
1874 (method url-fetch)
1875 (uri (pypi-uri "portend" version))
1876 (sha256
1877 (base32 "12b4ikxyv32n33mvm4brp74igl1mvw825x01sjvvs54y3yml17da"))))
1878 (build-system pyproject-build-system)
1879 ;; Do not test pyproject.toml with python-pytest-checkdocs as it tries to
1880 ;; download dependencies.
1881 (arguments
1882 '(#:test-flags '("-k" "not project")))
1883 (native-inputs
1884 (list python-pytest
1885 python-setuptools
1886 python-setuptools-scm))
1887 (propagated-inputs
1888 (list python-tempora))
1889 (home-page "https://github.com/jaraco/portend")
1890 (synopsis "Monitor TCP ports for bound or unbound states")
1891 (description
1892 "@code{python-portend} can be used to monitor TCP ports for bound or
1893unbound states. For example, waiting for a port to be occupied or freed
1894within a set timeout. @code{python-portend} can also be used directly from
1895the command line.")
1896 (license license:expat)))
1897
1898(define-public python-prawcore
1899 (package
1900 (name "python-prawcore")
1901 (version "2.4.0")
1902 (source
1903 (origin
1904 (method git-fetch)
1905 (uri (git-reference
1906 (url "https://github.com/praw-dev/prawcore")
1907 (commit (string-append "v" version))))
1908 (file-name (git-file-name name version))
1909 (sha256
1910 (base32 "1y7gh7kk002b2h1ppkr1llb2gjfnby28zvx11j4ji0wm3r3rjh5l"))))
1911 (build-system pyproject-build-system)
1912 (arguments
1913 ;; XXX: These tests fail with an incomplete request response.
1914 (list #:test-flags
1915 #~'("-k" #$(string-append
1916 "not test_revoke__access_token_with_refresh_set"
1917 " and not test_revoke__access_token_without_refresh_set"
1918 " and not test_revoke__refresh_token_with_access_set"
1919 " and not test_refresh__with_scopes"
1920 " and not test_request__patch"))))
1921 (native-inputs
1922 (list python-betamax
1923 python-betamax-matchers
1924 python-betamax-serializers
1925 python-flit-core
1926 python-mock
1927 python-pytest
1928 python-testfixtures))
1929 (propagated-inputs
1930 (list python-requests))
1931 (synopsis "Core component of PRAW")
1932 (description "PRAWcore is a low-level communication layer used by PRAW.")
1933 (home-page "https://praw.readthedocs.io/en/latest/")
1934 (license license:bsd-2)))
1935
1936(define-public python-praw
1937 (package
1938 (name "python-praw")
1939 (version "7.8.1")
1940 (source
1941 (origin
1942 (method git-fetch)
1943 (uri (git-reference
1944 (url "https://github.com/praw-dev/praw")
1945 (commit (string-append "v" version))))
1946 (file-name (git-file-name name version))
1947 (sha256
1948 (base32 "05qq43l4334cq8r8k731qnb45nq12vvfdxwbr6q84a1hafp7n4cg"))))
1949 (build-system pyproject-build-system)
1950 (arguments
1951 (list #:test-flags
1952 #~(list "--ignore=tests/units/models"
1953 "--ignore=tests/integration/models"
1954 "--ignore=tests/unit/test_config.py"
1955 "--ignore=tests/integration/test_reddit.py")))
1956 (native-inputs
1957 (list python-betamax
1958 python-betamax-matchers
1959 python-flit-core
1960 python-pytest))
1961 (propagated-inputs
1962 (list python-prawcore python-update-checker python-websocket-client))
1963 (synopsis "Python Reddit API Wrapper")
1964 (description "PRAW is a Python package that allows for simple access to
1965Reddit’s API. It aims to be easy to use and internally follows all of Reddit’s
1966API rules.")
1967 (home-page "https://praw.readthedocs.io/en/latest/")
1968 (license license:bsd-2)))
1969
1970(define-public python-frozenlist
1971 (package
1972 (name "python-frozenlist")
1973 (version "1.8.0")
1974 (source
1975 (origin
1976 (method git-fetch)
1977 (uri (git-reference
1978 (url "https://github.com/aio-libs/frozenlist")
1979 (commit (string-append "v" version))))
1980 (file-name (git-file-name name version))
1981 (sha256
1982 (base32 "0r1kxf5b562zrn04nl912i6a8y1fyc891l1284v0zj9llb97limy"))))
1983 ;; XXX: Without "wheel", the 'install phase can't find the wheel.
1984 (outputs (list "out" "wheel"))
1985 (build-system pyproject-build-system)
1986 ;; The configuration contains explicit calls to pytest_cov.
1987 (arguments (list #:test-flags #~(list "-c" "/dev/null")))
1988 (native-inputs
1989 (list python-cython
1990 python-expandvars
1991 python-pytest
1992 python-setuptools
1993 python-tomli))
1994 (home-page "https://github.com/aio-libs/frozenlist")
1995 (synopsis "List-like data structure for Python")
1996 (description "@code{frozenlist.FrozenList} is a list-like structure which
1997implements @code{collections.abc.MutableSequence}. It can be made immutable
1998by calling @code{FrozenList.freeze}.")
1999 (license license:asl2.0)))
2000
2001(define-public python-aiobotocore
2002 (package
2003 (name "python-aiobotocore")
2004 (version "3.0.0")
2005 (source
2006 (origin
2007 (method url-fetch)
2008 (uri (pypi-uri "aiobotocore" version))
2009 (sha256
2010 (base32 "0bcmnbm30hwaks8l895j8xy08cil0dpjcfpidg2qjawbs4a9s0ra"))))
2011 (build-system pyproject-build-system)
2012 (arguments
2013 ;; TODO: Tests need some setupt, see Makefile.
2014 (list #:tests? #f))
2015 (native-inputs
2016 (list python-setuptools))
2017 (propagated-inputs
2018 (list python-aiohttp
2019 python-aioitertools
2020 python-botocore
2021 python-dateutil
2022 python-jmespath
2023 python-multidict
2024 python-typing-extensions
2025 python-wrapt))
2026 (home-page "https://github.com/aio-libs/aiobotocore")
2027 (synopsis "Async client for AWS services using botocore and aiohttp")
2028 (description "This package provides an async client for Amazon services
2029using botocore and aiohttp/asyncio. This library is a mostly full featured
2030asynchronous version of botocore.")
2031 (license license:asl2.0)))
2032
2033(define-public python-aiohappyeyeballs
2034 (package
2035 (name "python-aiohappyeyeballs")
2036 (version "2.6.1")
2037 (source
2038 (origin
2039 (method url-fetch)
2040 (uri (pypi-uri "aiohappyeyeballs" version))
2041 (sha256
2042 (base32 "0n1mjip846fprc34ik6if9m8xisva2m0ygyzvz53r013648x1yf3"))))
2043 (build-system pyproject-build-system)
2044 (native-inputs
2045 (list python-poetry-core
2046 python-pytest
2047 python-pytest-asyncio-0.26
2048 python-pytest-cov))
2049 (home-page "https://github.com/aio-libs/aiohappyeyeballs")
2050 (synopsis "Happy Eyeballs for asyncio")
2051 (description "This library exists to allow connecting with Happy
2052Eyeballs (RFC 8305) when you already have a list of @code{addrinfo} and not a
2053DNS name.")
2054 (license license:psfl)))
2055
2056(define-public python-aioitertools
2057 (package
2058 (name "python-aioitertools")
2059 (version "0.12.0")
2060 (source
2061 (origin
2062 (method url-fetch)
2063 (uri (pypi-uri "aioitertools" version))
2064 (sha256
2065 (base32 "0syxv2r90d6410hc68jxhk610pdgx19n1n5rc7shaxxv9xdhbaf2"))))
2066 (build-system pyproject-build-system)
2067 (arguments
2068 (list #:test-backend #~'custom
2069 #:test-flags #~(list "-m" "aioitertools.tests")))
2070 (native-inputs
2071 (list python-flit-core))
2072 (home-page "https://pypi.org/project/aioitertools/")
2073 (synopsis "Itertools and builtins for AsyncIO and mixed iterables")
2074 (description
2075 "This package provides an implementation of itertools, builtins, and more
2076for AsyncIO and mixed-type iterables.")
2077 (license license:expat)))
2078
2079(define-public python-aiosignal
2080 (package
2081 (name "python-aiosignal")
2082 (version "1.4.0")
2083 (source
2084 (origin
2085 (method url-fetch)
2086 (uri (pypi-uri "aiosignal" version))
2087 (sha256
2088 (base32 "1isin9bp256scp59lbr35h48nw5p5i84b6f9kh1c50w08vcyqzpl"))))
2089 (build-system pyproject-build-system)
2090 (native-inputs
2091 (list python-pytest
2092 python-pytest-asyncio
2093 python-pytest-cov
2094 python-setuptools
2095 python-wheel))
2096 (propagated-inputs
2097 (list python-frozenlist))
2098 (home-page "https://github.com/aio-libs/aiosignal")
2099 (synopsis "Callback manager for Python @code{asyncio} projects")
2100 (description "This Python module provides @code{Signal}, an abstraction to
2101register asynchronous callbacks. The @code{Signal} abstraction can be used
2102for adding, removing and dropping callbacks.")
2103 (license license:asl2.0)))
2104
2105(define-public python-aiohttp
2106 (package
2107 (name "python-aiohttp")
2108 ;; TODO: Newer versions require zlib-ng:
2109 ;; <https://github.com/zlib-ng/zlib-ng>,
2110 ;; <https://github.com/pycompression/python-zlib-ng>.
2111 (version "3.11.18")
2112 (source
2113 (origin
2114 (method url-fetch)
2115 (uri (pypi-uri "aiohttp" version))
2116 (sha256
2117 (base32 "12jmkxkc5nnk6ma6m7rrs0w4vzswfc47ffxn5m0pwav1708nx1df"))
2118 (snippet
2119 #~(begin
2120 (use-modules ((guix build utils)))
2121 ;; TODO: Unbundle the llhttp sources.
2122 ;; (delete-file-recursively "vendor")
2123 (delete-file "aiohttp/_http_parser.c")
2124 (delete-file "aiohttp/_http_writer.c")))))
2125 (build-system pyproject-build-system)
2126 (arguments
2127 (list
2128 ;; tests: 3045 passed, 32 skipped, 29 xfailed, 2 subtests passed
2129 #:test-flags
2130 '(list
2131 "--numprocesses" (number->string (parallel-job-count))
2132 ;; This tests requires the 'proxy.py' module, not yet packaged.
2133 "--ignore=tests/test_proxy_functional.py"
2134 ;; These tests need brotli.
2135 "--ignore=tests/test_web_sendfile_functional.py"
2136 "--ignore=tests/test_web_functional.py"
2137 ;; These tests need pytest_codspeed
2138 "--ignore-glob=tests/test_benchmarks*"
2139 ;; These tests need python_on_whales
2140 "--ignore=tests/autobahn/test_autobahn.py"
2141 "-k"
2142 ;; These tests fail for unknown reasons (see:
2143 ;; https://github.com/aio-libs/aiohttp/issues/7130)
2144 (string-append
2145 "not test_no_warnings "
2146 "and not test_default_loop "
2147 "and not test_ctor_global_loop "
2148 "and not test_set_loop_default_loop "
2149
2150 ;; Disable brotli tests, because we’re not providing that optional
2151 ;; library.
2152 "and not test_feed_eof_no_err_brotli "
2153
2154 ;; Disable the following tests as they require
2155 ;; networking.
2156 "and not TestDeflateBuffer "
2157 "and not test_client_session_timeout_zero "
2158 "and not test_empty_body "
2159 "and not test_mark_formdata_as_processed[pyloop] "
2160 "and not test_receive_runtime_err[pyloop] "
2161
2162 ;; assert 'gzip, deflate' == 'gzip, deflate, br'
2163 "and not test_headers[pyloop] "
2164 ;; ~/.. does not resolve
2165 "and not test_add_static_path_resolution"))
2166 #:phases
2167 '(modify-phases %standard-phases
2168 (add-after 'unpack 'fix-pytest-config
2169 (lambda _
2170 (substitute* "setup.cfg"
2171 (("--numprocesses=auto") "")
2172 (("-p pytest_cov") "")
2173 (("--cov.*") ""))))
2174 (add-after 'unpack 'fix-tests
2175 (lambda _
2176 ;; Make sure the timestamp of this file is > 1990, because a few
2177 ;; tests like test_static_file_if_modified_since_past_date depend
2178 ;; on it.
2179 (let ((late-90s (* 60 60 24 365 30)))
2180 (utime "tests/data.unknown_mime_type" late-90s late-90s))))
2181 (add-before 'build 'cythonize
2182 (lambda _
2183 ;; Adapted from the Makefile.
2184 (with-directory-excursion "aiohttp"
2185 (for-each
2186 (lambda (file)
2187 (invoke "cython" "-3"
2188 file "-I" "."))
2189 (find-files "." "_.*\\.pyx$"))))))))
2190 (propagated-inputs
2191 (list python-aiohappyeyeballs
2192 python-aiosignal
2193 python-attrs
2194 python-frozenlist
2195 python-multidict
2196 python-propcache
2197 python-yarl))
2198 (native-inputs
2199 (list gunicorn-bootstrap
2200 python-cython
2201 python-freezegun
2202 python-isal
2203 python-pytest
2204 python-pytest-mock
2205 python-pytest-xdist
2206 python-re-assert
2207 python-setuptools))
2208 (home-page "https://github.com/aio-libs/aiohttp/")
2209 (synopsis "Async HTTP client/server framework (asyncio)")
2210 (description "@code{aiohttp} is an asynchronous HTTP client/server
2211framework.
2212
2213Its main features are:
2214@itemize
2215@item Supports both client and server side of HTTP protocol.
2216@item Supports both client and server Web-Sockets out-of-the-box without the
2217Callback Hell.
2218@item Web-server has middlewares and pluggable routing.
2219@end itemize")
2220 (license license:asl2.0)))
2221
2222(define-public python-aiohttp-oauthlib
2223 (package
2224 (name "python-aiohttp-oauthlib")
2225 (version "0.1.0")
2226 (source
2227 (origin
2228 (method url-fetch)
2229 (uri (pypi-uri "aiohttp-oauthlib" version))
2230 (sha256
2231 (base32 "1dwk0gby27xm7384qyz2p7zw9dqhjx7m8fhfk172w36xknjx2g49"))))
2232 (build-system pyproject-build-system)
2233 (arguments (list #:tests? #f)) ; none included
2234 (propagated-inputs (list python-aiohttp python-oauthlib))
2235 (native-inputs (list python-setuptools python-setuptools-scm))
2236 (home-page "https://git.sr.ht/~whynothugo/aiohttp-oauthlib")
2237 (synopsis "OAuthlib authentication support for aiohttp")
2238 (description "Aiohttp-oauthlib uses the Python aiohttp and OAuthlib libraries to
2239provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
2240 (license license:isc)))
2241
2242(define-public python-aiohttp-client-cache
2243 (package
2244 (name "python-aiohttp-client-cache")
2245 (version "0.14.2")
2246 (source
2247 (origin
2248 (method git-fetch)
2249 (uri (git-reference
2250 (url "https://github.com/requests-cache/aiohttp-client-cache")
2251 (commit (string-append "v" version))))
2252 (file-name (git-file-name name version))
2253 (sha256
2254 (base32
2255 "17qa2sh63wa7b9ma40y2b6k9sjscc5vfwlmf46sv36l1mz9rmd4y"))))
2256 (build-system pyproject-build-system)
2257 (arguments
2258 (list
2259 #:test-flags
2260 ;; Run unit tests only which not require networking or additional setup.
2261 #~(list "--ignore=test/integration")))
2262 (native-inputs
2263 (list python-hatchling
2264 ;; TODO: Missing packages: pytest-clarity,
2265 ;; nox-poetry, types-aiofiles.
2266 python-async-timeout
2267 python-brotli
2268 python-faker
2269 python-pytest
2270 python-pytest-aiohttp
2271 python-pytest-asyncio
2272 python-pytest-xdist))
2273 (propagated-inputs
2274 (list python-aiofiles
2275 python-aiohttp
2276 python-aiosqlite
2277 python-attrs
2278 python-itsdangerous
2279 python-redis
2280 python-url-normalize))
2281 (home-page "https://github.com/requests-cache/aiohttp-client-cache")
2282 (synopsis "Persistent cache for aiohttp requests")
2283 (description
2284 "This package is an asynchronous persistent caching library specifically
2285designed for @samp{aiohttp} requests in Python. With support for various
2286storage backends, it offers flexibility in how and where the cache is stored.
2287Please note that MongoDB and DynamoDB backends are not currently supported due
2288to the absence of the @samp{motor} and @samp{aioboto3} package dependencies.")
2289 (license license:expat)))
2290
2291(define-public python-aiohttp-cors
2292 (package
2293 (name "python-aiohttp-cors")
2294 (version "0.8.1")
2295 (source
2296 (origin
2297 (method url-fetch)
2298 (uri (pypi-uri "aiohttp_cors" version))
2299 (sha256
2300 (base32 "00qlzc2y65bkl1a5f5v83mmjlrhzmx3a2ngq2pm3jjdnhk5zkb6c"))))
2301 (build-system pyproject-build-system)
2302 (arguments
2303 (list
2304 #:tests? #f)) ; network access is required to run tests
2305 (native-inputs
2306 (list python-setuptools
2307 python-wheel))
2308 (propagated-inputs
2309 (list python-aiohttp))
2310 (home-page "https://github.com/aio-libs/aiohttp-cors")
2311 (synopsis "CORS support for aiohttp")
2312 (description
2313 "This library implements @acronym{CORS, Cross Origin Resource Sharing}
2314support for aiohttp asyncio-powered asynchronous HTTP server.")
2315 (license license:asl2.0)))
2316
2317(define-public python-aiohttp-retry
2318 (package
2319 (name "python-aiohttp-retry")
2320 (version "2.9.1")
2321 (source
2322 (origin
2323 (method git-fetch)
2324 (uri (git-reference
2325 (url "https://github.com/inyutin/aiohttp_retry")
2326 (commit (string-append "v" version))))
2327 (file-name (git-file-name name version))
2328 (sha256
2329 (base32 "0r5lxnxc4s8js7l86pfmdxl455v9lg3m41nz6m1xg4kwwf6j0bpi"))))
2330 (build-system pyproject-build-system)
2331 (native-inputs
2332 (list python-pytest
2333 python-pytest-aiohttp
2334 python-setuptools))
2335 (propagated-inputs
2336 (list python-aiohttp))
2337 (home-page "https://github.com/inyutin/aiohttp_retry")
2338 (synopsis "Simple retry client for aiohttp")
2339 (description
2340 "This package implements @code{RetryClient} for @code{aiohttp} to retry
2341connection to provided endpoint with timeouts logic or use:
2342
2343@itemize
2344@item @code{ExponentialRetry} with exponential backoff
2345@item @code{RandomRetry} for random backoff
2346@item @code{ListRetry} with backoff you predefine by list
2347@item @code{FibonacciRetry} with backoff that looks like fibonacci sequence
2348@item @code{JitterRetry} exponential retry with a bit of randomness
2349@end itemize")
2350 (license license:expat)))
2351
2352(define-public python-aiohttp-socks
2353 (package
2354 (name "python-aiohttp-socks")
2355 (version "0.10.1")
2356 (source
2357 (origin
2358 (method url-fetch)
2359 (uri (pypi-uri "aiohttp_socks" version))
2360 (sha256
2361 (base32
2362 "0s70jpcr9wc8ld2v1w309cz7r8mm2bipf6zbkdqqaa0z0pwf3wj9"))))
2363 (build-system pyproject-build-system)
2364 (arguments (list #:tests? #false)) ;none included
2365 (propagated-inputs
2366 (list python-aiohttp python-socks))
2367 (native-inputs (list python-setuptools python-wheel))
2368 (home-page "https://github.com/romis2012/aiohttp-socks")
2369 (synopsis "SOCKS proxy connector for aiohttp")
2370 (description "This package provides a SOCKS proxy connector for
2371aiohttp. It supports SOCKS4(a) and SOCKS5.")
2372 (license license:asl2.0)))
2373
2374(define-public python-aiodns
2375 (package
2376 (name "python-aiodns")
2377 (version "3.5.0")
2378 (source
2379 (origin
2380 (method git-fetch)
2381 (uri (git-reference
2382 (url "https://github.com/saghul/aiodns")
2383 (commit (string-append "v" version))))
2384 (file-name (git-file-name name version))
2385 (sha256
2386 (base32 "1as7l48962dpk3r4zdsifj761dks5nyr35hxs7m8crvkyb1dg9m9"))))
2387 (build-system pyproject-build-system)
2388 (arguments
2389 (list
2390 #:tests? #f)) ;tests require internet access
2391 (native-inputs
2392 (list python-pytest
2393 python-pytest-cov
2394 python-pytest-asyncio
2395 python-setuptools))
2396 (propagated-inputs (list python-pycares))
2397 (home-page "https://github.com/saghul/aiodns")
2398 (synopsis "Simple DNS resolver for asyncio")
2399 (description
2400 "@code{aiodns} provides a simple way for doing asynchronous DNS
2401resolutions with a synchronous looking interface by using
2402@url{https://github.com/saghul/pycares,pycares}.")
2403 (license license:expat)))
2404
2405(define-public python-aioquic
2406 (package
2407 (name "python-aioquic")
2408 (version "1.2.0")
2409 (source
2410 (origin
2411 (method url-fetch)
2412 (uri (pypi-uri "aioquic" version))
2413 (sha256
2414 (base32 "16bigrn5b46c7nmpzxhnlhh4y03hwc7dbd0mi5f8r53i7yxn64pr"))))
2415 (build-system pyproject-build-system)
2416 (arguments
2417 (list
2418 #:test-flags
2419 #~(list "-k" (string-join
2420 ;; AssertionError: AlertBadCertificate not raised
2421 (list "not test_verify_subject_no_subjaltname"
2422 ;; AttributeError: module
2423 ;; 'service_identity.cryptography' has no attribute
2424 ;; 'extract_patterns'
2425 "test_verify_subject_with_subjaltname"
2426 ;; AttributeError: module
2427 ;; 'service_identity.cryptography' has no attribute
2428 ;; 'extract_patterns'
2429 "test_verify_subject_with_subjaltname_ipaddress")
2430 " and not "))))
2431 (native-inputs
2432 (list nss-certs-for-test
2433 python-pytest
2434 python-setuptools
2435 python-wheel))
2436 (inputs
2437 (list openssl))
2438 (propagated-inputs
2439 (list python-certifi
2440 python-pylsqpack
2441 python-pyopenssl
2442 python-service-identity))
2443 (home-page "https://github.com/aiortc/aioquic")
2444 (synopsis "QUIC and HTTP3 implementation in Python")
2445 (description
2446 "@code{aioquic} is a library for the QUIC network protocol in Python.
2447It features a minimal TLS 1.3 implementation, a QUIC stack and an HTTP/3 stack.")
2448 (license license:bsd-3)))
2449
2450(define-public python-aiorpcx
2451 (package
2452 (name "python-aiorpcx")
2453 (version "0.25.0")
2454 (source
2455 (origin
2456 (method git-fetch)
2457 ;; PyPI misses the util.py file used for tests.
2458 (uri (git-reference
2459 (url "https://github.com/kyuupichan/aiorpcX")
2460 (commit version)))
2461 (file-name (git-file-name name version))
2462 (sha256
2463 (base32
2464 "0sn4xxlpy0kb5b25bqrjzh2m6bskdyydc6cq8bigb7g5dacksn4q"))))
2465 (build-system pyproject-build-system)
2466 (arguments
2467 (list
2468 #:test-flags
2469 ;; This test opens a remote connection.
2470 #~(list "-k" "not test_create_connection_resolve_good")))
2471 (native-inputs (list python-pytest
2472 python-pytest-asyncio-0.26
2473 python-setuptools))
2474 (propagated-inputs
2475 (list python-attrs python-websockets))
2476 (home-page "https://github.com/kyuupichan/aiorpcX")
2477 (synopsis "Generic asyncio RPC implementation")
2478 (description
2479 "The aiorpcX library is a generic asyncio implementation of RPC suitable
2480for an application that is a client, server or both.
2481
2482The package includes a module with full coverage of JSON RPC versions 1.0 and
24832.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
2484comes with a SOCKS proxy client.")
2485 (license (list license:expat license:bsd-2))))
2486
2487(define-public python-aiostream
2488 (package
2489 (name "python-aiostream")
2490 (version "0.7.0")
2491 (source
2492 (origin
2493 (method git-fetch) ;no tests in PyPI archvie
2494 (uri (git-reference
2495 (url "https://github.com/vxgmichel/aiostream")
2496 (commit (string-append "v" version))))
2497 (file-name (git-file-name name version))
2498 (sha256
2499 (base32 "1wf89l9f0ivlv796pklpgykx6j6ksfqrmvzikd8w5j6ldln7bv50"))))
2500 (build-system pyproject-build-system)
2501 (native-inputs
2502 (list python-pytest
2503 python-pytest-cov
2504 python-pytest-asyncio
2505 python-setuptools))
2506 (propagated-inputs
2507 (list python-typing-extensions))
2508 (home-page "https://github.com/vxgmichel/aiostream")
2509 (synopsis "Generator-based operators for asynchronous iteration")
2510 (description "@code{aiostream} provides a collection of stream operators that can
2511be combined to create asynchronous pipelines of operations. It can be seen as an
2512asynchronous version of @code{itertools}, although some aspects are slightly
2513different. All the provided operators return a unified interface called a stream. A
2514stream is an enhanced asynchronous iterable.")
2515 (license license:gpl3)))
2516
2517(define-public python-asgiref
2518 (package
2519 (name "python-asgiref")
2520 (version "3.8.1")
2521 (source (origin
2522 (method url-fetch)
2523 (uri (pypi-uri "asgiref" version))
2524 (sha256
2525 (base32 "146mhkn3zp2bqf7j6r3chdlvfzgs5x1lrnqahsllgjdyl20bshy3"))))
2526 (build-system pyproject-build-system)
2527 (native-inputs
2528 (list python-pytest
2529 python-pytest-asyncio
2530 python-setuptools
2531 python-wheel))
2532 (home-page "https://github.com/django/asgiref/")
2533 (synopsis "ASGI specs, helper code, and adapters")
2534 (description
2535 "ASGI is a standard for Python asynchronous web apps and servers to
2536communicate with each other, and positioned as an asynchronous successor to
2537WSGI. This package includes libraries for implementing ASGI servers.")
2538 (license license:bsd-3)))
2539
2540(define-public python-asgi-csrf
2541 (package
2542 (name "python-asgi-csrf")
2543 (version "0.11")
2544 (source (origin
2545 (method git-fetch) ;for tests
2546 (uri (git-reference
2547 (url "https://github.com/simonw/asgi-csrf")
2548 (commit version)))
2549 (file-name (git-file-name name version))
2550 (sha256
2551 (base32
2552 "1dn9v47z2b599cnwahxvzsll2w28940ycgh5skxgq04vcqqssf29"))))
2553 (build-system pyproject-build-system)
2554 (propagated-inputs (list python-itsdangerous python-multipart))
2555 (native-inputs (list python-asgi-lifespan
2556 python-httpx
2557 python-pytest
2558 python-pytest-asyncio
2559 python-starlette
2560 python-setuptools
2561 python-wheel))
2562 (home-page "https://github.com/simonw/asgi-csrf")
2563 (synopsis "ASGI middleware for protecting against CSRF attacks")
2564 (description "This Asynchronous Server Gateway Interface (ASGI)
2565middleware protects against Cross-site request forgery (CSRF) attacks.
2566It implements the Double Submit Cookie pattern, where a cookie is set
2567that is then compared to a @code{csrftoken} hidden form field or a
2568@code{x-csrftoken} HTTP header.")
2569 (license license:asl2.0)))
2570
2571(define-public python-asgi-lifespan
2572 (package
2573 (name "python-asgi-lifespan")
2574 (version "2.1.0")
2575 (source (origin
2576 (method git-fetch) ;for tests
2577 (uri (git-reference
2578 (url "https://github.com/florimondmanca/asgi-lifespan")
2579 (commit version)))
2580 (file-name (git-file-name name version))
2581 (sha256
2582 (base32
2583 "0iqa3h61gsq1qd6j9v68k989596m9n9k1dx8zv6135rmhzzrs296"))))
2584 (build-system pyproject-build-system)
2585 (arguments
2586 (list
2587 #:test-flags
2588 '(list "-c" "/dev/null" ;ignore coverage-related options
2589 "-k"
2590 (string-append
2591 ;; XXX: Some tests fail because of "Exceptions from Trio nursery"
2592 "not (test_lifespan_manager[trio-None-None-StartupFailed]"
2593 " or test_lifespan_manager[trio-None-BodyFailed-None]"
2594 " or test_lifespan_manager[trio-None-BodyFailed-StartupFailed]"
2595 " or test_lifespan_manager[trio-ShutdownFailed-None-None]"
2596 " or test_lifespan_manager[trio-ShutdownFailed-None-StartupFailed]"
2597 " or test_lifespan_manager[trio-ShutdownFailed-BodyFailed-StartupFailed]"
2598 " or test_lifespan_timeout[trio-slow_shutdown]"
2599 " or test_lifespan_not_supported[trio-http_only]"
2600 " or test_lifespan_not_supported[trio-http_no_assert]"
2601 " or test_lifespan_not_supported[trio-http_no_assert_before_receive_request]"
2602 ")"))
2603 #:phases
2604 '(modify-phases %standard-phases
2605 (add-after 'unpack 'compatibility
2606 (lambda _
2607 ;; httpx version 0.28.0 removed the "app" shortcut.
2608 (substitute* "tests/test_manager.py"
2609 (("app=manager.app")
2610 "transport=httpx.ASGITransport(manager.app)")))))))
2611 (native-inputs (list python-httpx
2612 python-pytest
2613 python-pytest-asyncio
2614 python-pytest-trio
2615 python-starlette
2616 python-setuptools
2617 python-wheel))
2618 (propagated-inputs (list python-sniffio))
2619 (home-page "https://github.com/florimondmanca/asgi-lifespan")
2620 (synopsis "Programmatic startup/shutdown of ASGI apps")
2621 (description "Programmatically send startup/shutdown lifespan events
2622into Asynchronous Server Gateway Interface (ASGI) applications. When
2623used in combination with an ASGI-capable HTTP client such as HTTPX, this
2624allows mocking or testing ASGI applications without having to spin up an
2625ASGI server.")
2626 (license license:expat)))
2627
2628(define-public python-a2wsgi
2629 (package
2630 (name "python-a2wsgi")
2631 (version "1.10.7")
2632 (source (origin
2633 (method url-fetch)
2634 (uri (pypi-uri "a2wsgi" version))
2635 (sha256
2636 (base32
2637 "13ikyfmkx7hlrbg5rpcdm6kw4wcsy00giil3f72hpb6sw7vjyinf"))))
2638 (build-system pyproject-build-system)
2639 (arguments
2640 (list
2641 #:test-flags
2642 #~(list "-k" (string-join
2643 (list "not test_starlette_stream_response"
2644 "test_starlette_base_http_middleware"
2645 "test_baize_stream_response"
2646 ;; Fails because of harmless whitespace differences.
2647 "test_wsgi_post")
2648 " and not "))
2649 #:build-backend "pdm.backend"))
2650 (native-inputs
2651 (list python-pdm-backend
2652 python-pytest
2653 ;; python-baize ; not packed yet
2654 python-httpx-bootstrap
2655 ;; Cycle: python-a2wsgi->python-uvicorn->
2656 ;; python-httpx->python-starlette->python-a2wsgi
2657 ;; python-starlette
2658 python-pytest-asyncio))
2659 (home-page "https://github.com/abersheeran/a2wsgi")
2660 (synopsis "Convert WSGI to ASGI or vice versa")
2661 (description
2662 "This program converts a WSGI program to an ASGI program or the other
2663way around. It depends only on the Python standard library.")
2664 (license license:asl2.0)))
2665
2666(define-public python-httpauth
2667 (package
2668 (name "python-httpauth")
2669 (version "0.4.1")
2670 (source (origin
2671 (method url-fetch)
2672 (uri (pypi-uri "httpauth" version))
2673 (sha256
2674 (base32
2675 "1m6rwvivg61l3h34hf6p6gkqmr69sb1c4k5ha379nxq0p8bfgahb"))))
2676 (build-system pyproject-build-system)
2677 (native-inputs (list python-pytest python-setuptools python-wheel))
2678 (home-page "https://github.com/jonashaag/httpauth")
2679 (synopsis "WSGI HTTP Digest Authentication middleware")
2680 (description "@code{python-httpauth} is WSGI middleware that secures some/all
2681routes using HTTP Digest Authentication.")
2682 (license license:bsd-2)))
2683
2684(define-public python-css-html-js-minify
2685 (let ((commit "8f72452960e41bc5476e50d96481f633eff72750")
2686 (revision "0"))
2687 (package
2688 (name "python-css-html-js-minify")
2689 (version (git-version "2.5.5" revision commit))
2690 (source
2691 (origin
2692 (method git-fetch)
2693 (uri (git-reference
2694 (url "https://github.com/juancarlospaco/css-html-js-minify")
2695 (commit commit)))
2696 (file-name (git-file-name name version))
2697 (sha256
2698 (base32 "1lkx03720zk6q16w3d9r3l5kryikd1cmzwrcjzsjxwrq4zfh6vdf"))))
2699 (build-system pyproject-build-system)
2700 (arguments
2701 (list
2702 #:phases
2703 #~(modify-phases %standard-phases
2704 (add-after 'unpack 'relax-requirements
2705 (lambda _
2706 (substitute* "setup.cfg"
2707 (("^tests_require.*") "")))))))
2708 (native-inputs (list python-pytest python-setuptools))
2709 (home-page "https://github.com/juancarlospaco/css-html-js-minify")
2710 (synopsis "CSS/HTML/JS minifier")
2711 (description
2712 "This package provides a single-file minifier for CSS, HTML, and JavaScript.")
2713 ;; XXX: The README just says "GNU GPL and GNU LGPL and MIT". From
2714 ;; <https://github.com/juancarlospaco/css-html-js-minify/issues/9> it
2715 ;; looks like the user can choose a license.
2716 (license (list license:gpl3+ license:lgpl3+ license:expat)))))
2717
2718(define-public python-aws-sam-translator
2719 (package
2720 (name "python-aws-sam-translator")
2721 (version "1.107.0")
2722 (source
2723 (origin
2724 (method git-fetch) ; no tests in PyPI release
2725 (uri (git-reference
2726 (url "https://github.com/aws/serverless-application-model")
2727 (commit (string-append "v" version))))
2728 (file-name (git-file-name name version))
2729 (sha256
2730 (base32 "0bx9ha9k6zx6gl1hsgm6cpq4xrfn604v2g1d5dh2d5zq0463gwfq"))))
2731 (build-system pyproject-build-system)
2732 (arguments
2733 (list
2734 #:test-flags
2735 #~(list "--numprocesses" (number->string (parallel-job-count))
2736 "--ignore=tests/bin/test_public_interface.py"
2737 "tests")
2738 #:phases
2739 #~(modify-phases %standard-phases
2740 (add-after 'unpack 'fix-pytest-config
2741 (lambda _
2742 ;; Drop test coverage requirements.
2743 (substitute* "pytest.ini"
2744 ((".*addopts.*") ""))))
2745 (add-before 'check 'pre-check
2746 (lambda _
2747 (setenv "AWS_DEFAULT_REGION" "eu-west-3"))))))
2748 (native-inputs
2749 (list python-pytest
2750 python-pytest-xdist
2751 python-parameterized
2752 python-pyyaml
2753 python-setuptools))
2754 (propagated-inputs
2755 (list python-boto3
2756 python-jsonschema
2757 python-pydantic
2758 python-typing-extensions))
2759 (home-page "https://github.com/aws/serverless-application-model")
2760 (synopsis "Transform AWS SAM templates into AWS CloudFormation templates")
2761 (description
2762 "AWS SAM Translator is a library that transform @dfn{Serverless Application
2763Model} (SAM) templates into AWS CloudFormation templates.")
2764 (license license:asl2.0)))
2765
2766(define-public python-aws-xray-sdk
2767 (package
2768 (name "python-aws-xray-sdk")
2769 (version "2.14.0")
2770 (home-page "https://github.com/aws/aws-xray-sdk-python")
2771 (source (origin
2772 (method git-fetch)
2773 (uri (git-reference (url home-page) (commit version)))
2774 (file-name (git-file-name name version))
2775 (sha256
2776 (base32
2777 "0khm86218rfjmgfw0azk7gnq6y9gkj95i0i30wa5v2li1z4z8qxd"))))
2778 (build-system pyproject-build-system)
2779 (arguments
2780 (list
2781 #:test-flags
2782 '(list ;; Tries to connect to external network resources
2783 "--ignore=tests/ext/aiohttp/test_client.py"
2784 "--ignore=tests/ext/httplib/test_httplib.py"
2785 "--ignore=tests/ext/httpx"
2786 "--ignore=tests/ext/requests/test_requests.py"
2787 ;; TODO: How to configure Django for these tests?
2788 "--ignore=tests/ext/django"
2789 ;; These tests require packages not yet in Guix.
2790 "--ignore=tests/ext/aiobotocore/test_aiobotocore.py"
2791 "--ignore=tests/ext/aiohttp/test_middleware.py"
2792 "--ignore=tests/ext/pg8000/test_pg8000.py"
2793 "--ignore=tests/ext/psycopg2/test_psycopg2.py"
2794 "--ignore=tests/ext/pymysql/test_pymysql.py"
2795 "--ignore=tests/ext/pynamodb/test_pynamodb.py"
2796 "--ignore=tests/ext/sqlalchemy_core/test_postgres.py"
2797 "--ignore=tests/ext/sqlalchemy_core/test_dburl.py"
2798 "--ignore=tests/test_async_recorder.py"
2799 ;; FIXME: module 'sqlalchemy.orm' has no attribute 'DeclarativeBase'.
2800 "--ignore-glob=tests/ext/sqlalchemy*"
2801 "--ignore=tests/ext/flask_sqlalchemy/test_query.py"
2802 ;; FIXME: Why is this failing?
2803 "--ignore=tests/test_patcher.py"
2804 "--ignore=tests/test_lambda_context.py")
2805 #:phases
2806 '(modify-phases %standard-phases
2807 (add-before 'check 'pre-check
2808 (lambda _
2809 ;; Allow "import tests.utils" to work as expected.
2810 (setenv "PYTHONPATH" (getcwd)))))))
2811 (native-inputs
2812 (list ;; These are required for the test suite.
2813 python-aiohttp
2814 python-bottle
2815 python-flask
2816 python-flask-sqlalchemy
2817 python-httpx
2818 python-mock
2819 python-pymysql
2820 python-pytest
2821 python-pytest-asyncio-0.26
2822 python-pytest-benchmark
2823 python-setuptools
2824 python-sqlalchemy
2825 python-webtest))
2826 (propagated-inputs
2827 (list python-botocore
2828 python-jsonpickle
2829 python-requests
2830 python-wrapt))
2831 (synopsis "Profile applications on AWS X-Ray")
2832 (description
2833 "The AWS X-Ray SDK for Python enables Python developers to record and
2834emit information from within their applications to the AWS X-Ray service.")
2835 (license license:asl2.0)))
2836
2837(define-public python-publicsuffixlist
2838 (package
2839 (name "python-publicsuffixlist")
2840 (version "1.0.2.20250202")
2841 (source
2842 (origin
2843 (method url-fetch)
2844 (uri (pypi-uri "publicsuffixlist" version))
2845 (sha256
2846 (base32 "0llam7g7sv08lcfgy18iph8br8ldjmy2qbjaykc9pd3z4iisb0yd"))))
2847 (build-system pyproject-build-system)
2848 (arguments (list #:test-backend #~'unittest))
2849 (native-inputs (list python-setuptools))
2850 (home-page "https://github.com/ko-zu/psl")
2851 (synopsis "Public suffix list for Python")
2852 (description
2853 "This package provides an implementation of
2854@url{https://publicsuffix.org/, Public Suffix List } as Python library.
2855
2856Features:
2857@itemize
2858@item supports IDN (unicode and punycoded)
2859@item shipped with built-in PSL and an updater script
2860@item written in Pure Python with no library dependencies
2861@end itemize")
2862 (license license:mpl2.0)))
2863
2864(define-public python-pycognito
2865 (package
2866 (name "python-pycognito")
2867 (version "2024.5.1")
2868 (source
2869 (origin
2870 (method url-fetch)
2871 (uri (pypi-uri "pycognito" version))
2872 (sha256
2873 (base32 "1r1sq87spqcfgg17khgpqc2ga8m9nk10flg9h23drhy2k1kcc4g2"))))
2874 (build-system pyproject-build-system)
2875 (arguments
2876 ;; XXX: cycles with python-moto, bootstrap/minimal variant is required.
2877 (list #:tests? #f))
2878 (native-inputs
2879 (list python-setuptools))
2880 (propagated-inputs
2881 (list python-boto3
2882 python-envs
2883 python-pyjwt
2884 python-requests))
2885 (home-page "https://github.com/pvizeli/pycognito")
2886 (synopsis "Python library for using AWS Cognito")
2887 (description
2888 "This package provides a Python class to integrate Boto3's Cognito
2889client so it is easy to login users, with @acronym{Secure Remote Password,
2890SRP} support.")
2891 (license license:asl2.0)))
2892
2893(define-public python-python3-saml
2894 (package
2895 (name "python-python3-saml")
2896 (version "1.16.0")
2897 (source
2898 (origin
2899 (method git-fetch)
2900 (uri (git-reference
2901 (url "https://github.com/SAML-Toolkits/python3-saml")
2902 (commit (string-append "v" version))))
2903 (file-name (git-file-name name version))
2904 (sha256
2905 (base32 "1isisymhk8zblj5942jfl0zq392q5fpjikx52nywvzb0m2dcc81b"))))
2906 (build-system pyproject-build-system)
2907 (arguments
2908 (list
2909 ;; 214 tests pass, 50 fail; many fail because of required Internet
2910 ;; access or because of assumptions about the location of test files.
2911 #:tests? #false))
2912 (native-inputs
2913 (list python-freezegun
2914 python-poetry-core))
2915 (inputs
2916 (list xmlsec-openssl))
2917 (propagated-inputs
2918 (list python-isodate
2919 python-lxml
2920 python-xmlsec))
2921 (home-page "https://github.com/SAML-Toolkits/python3-saml")
2922 (synopsis "Saml Python toolkit")
2923 (description
2924 "The SAML Python Toolkit lets you add SAML support to your Python
2925software.")
2926 (license license:expat)))
2927
2928(define-public python-ovh
2929 (package
2930 (name "python-ovh")
2931 (version "1.1.0")
2932 (source (origin
2933 (method url-fetch)
2934 (uri (pypi-uri "ovh" version))
2935 (sha256
2936 (base32
2937 "0ygniv12lixh9rvnjcd01gzbzk2b5xwcg2a59b7964a77dd9p3qh"))))
2938 (build-system pyproject-build-system)
2939 (arguments (list #:tests? #f)) ; XXX: tests require networking
2940 (propagated-inputs (list python-requests))
2941 (native-inputs (list python-setuptools))
2942 (home-page "https://api.ovh.com")
2943 (synopsis "Interact with OVHcloud APIs")
2944 (description "This package provides the official module to perform HTTP requests
2945to the OVHcloud APIs.")
2946 (license license:bsd-3)))
2947
2948(define-public python-cbor2
2949 (package
2950 (name "python-cbor2")
2951 (version "5.4.2.post1")
2952 (source
2953 (origin
2954 (method url-fetch)
2955 (uri (pypi-uri "cbor2" version))
2956 (sha256
2957 (base32 "15y78xcc3zkmvj1mdzz8gyhf3apbl91073kwhzbjk5abc1civwlw"))))
2958 (build-system pyproject-build-system)
2959 (native-inputs
2960 (list python-pytest
2961 python-pytest-cov
2962 python-setuptools
2963 python-setuptools-scm
2964 python-wheel))
2965 (home-page "https://github.com/agronholm/cbor2")
2966 (synopsis "Concise Binary Object Representation (CBOR) (de)serializer")
2967 (description "This Python library provides encoding and decoding for the
2968Concise Binary Object
2969Representation (CBOR) (@url{https://www.rfc-editor.org/rfc/rfc8949.html, RFC
29708949}) serialization format. The specification is fully compatible with the
2971original RFC 7049. Among its features are:
2972@itemize
2973@item Simple API like the @code{json} or @code{pickle} modules.
2974@item Support many CBOR tags with stdlib objects.
2975@item Generic tag decoding.
2976@item Shared value references including cyclic references.
2977@item String references compact encoding with repeated strings replaced with
2978indices.
2979@item Optional C module backend tested on big- and little-endian architectures.
2980@item Extensible tagged value handling using tag_hook and object_hook on
2981decode and default on encode.
2982@end itemize")
2983 (license license:expat)))
2984
2985(define-public python-cfn-lint
2986 (package
2987 (name "python-cfn-lint")
2988 (version "1.38.1")
2989 (source
2990 (origin
2991 (method git-fetch)
2992 (uri (git-reference
2993 (url "https://github.com/aws-cloudformation/cfn-lint")
2994 (commit (string-append "v" version))))
2995 (file-name (git-file-name name version))
2996 (sha256
2997 (base32 "1crwx0cp50h83xz8lc4ny504mx4dadpk80ln539syd4jd78qplgy"))))
2998 (build-system pyproject-build-system)
2999 (arguments
3000 (list
3001 ;; tests: 2136 passed, 11 deselected, 1 warning
3002 #:test-flags
3003 #~(list "--ignore=test/integration/"
3004 "-k" (string-join
3005 ;; Tests failing on doctest or comparing diff.
3006 (list "not test_build_graph"
3007 "test_good_template"
3008 "test_success_run"
3009 "test_update_docs"
3010 ;; ImportError: Missing optional dependencies sarif
3011 "test_sarif_formatter")
3012 " and not "))
3013 #:phases
3014 #~(modify-phases %standard-phases
3015 (add-after 'unpack 'remove-deprecated
3016 (lambda _
3017 (substitute* "src/cfnlint/data/AdditionalSpecs/LmbdRuntimeLifecycle.json"
3018 (("deprecated\": \"2025")
3019 "deprecated\": \"2125")))))))
3020 (native-inputs
3021 (list python-defusedxml
3022 python-pydot
3023 python-pytest
3024 python-setuptools))
3025 (propagated-inputs
3026 (list python-aws-sam-translator
3027 python-jsonpatch
3028 python-networkx
3029 python-pyyaml
3030 python-regex
3031 python-sympy
3032 python-typing-extensions
3033 ;; [optional]
3034 python-junit-xml))
3035 (home-page "https://github.com/aws-cloudformation/cfn-lint")
3036 (synopsis "Validate CloudFormation templates")
3037 (description
3038 "This package lets you validate CloudFormation YAML/JSON templates against
3039the CloudFormation spec and additional checks. Includes checking valid values
3040for resource properties and best practices.")
3041 (license license:expat)))
3042
3043(define-public python-pyzabbix
3044 (package
3045 (name "python-pyzabbix")
3046 (version "1.3.1")
3047 (source
3048 (origin
3049 (method git-fetch)
3050 (uri (git-reference
3051 (url "https://github.com/lukecyca/pyzabbix")
3052 (commit version)))
3053 (file-name (git-file-name name version))
3054 (sha256
3055 (base32 "1dbs3bz1mjlvlg46ikhg5j7agwni61ljlpiziknklv95yp29n86v"))))
3056 (build-system pyproject-build-system)
3057 (arguments
3058 (list #:test-flags #~(list "tests")))
3059 (native-inputs
3060 (list python-pytest
3061 python-requests-mock
3062 python-setuptools))
3063 (propagated-inputs
3064 (list python-packaging
3065 python-requests))
3066 (home-page "https://github.com/lukecyca/pyzabbix")
3067 (synopsis "Python interface to the Zabbix API")
3068 (description
3069 "@code{pyzabbix} is a Python module for working with the Zabbix API.")
3070 (license license:lgpl2.1+)))
3071
3072(define-public python-requests-cache
3073 (package
3074 (name "python-requests-cache")
3075 (version "1.2.1")
3076 (source
3077 (origin
3078 (method url-fetch)
3079 (uri (pypi-uri "requests_cache" version))
3080 (sha256
3081 (base32 "1l8i4l2pd26gbrlcdb5z056wvsqfr3vvbyqq2f8x1f65zn3ckav8"))))
3082 (build-system pyproject-build-system)
3083 (arguments
3084 (list
3085 #:test-flags
3086 #~(list "--numprocesses" (number->string (parallel-job-count))
3087 ;; These tests require access to external services, e.g. MongoDB
3088 ;; and Redis.
3089 "--ignore=tests/integration"
3090 ;; AttributeError: <class 'requests.adapters.HTTPAdapter'> does
3091 ;; not have the attribute 'get_connection_with_tls_context'
3092 "-k" "not test_mock_session")
3093 #:phases
3094 #~(modify-phases %standard-phases
3095 (add-before 'check 'pre-check
3096 (lambda _
3097 ;; PermissionError: [Errno 13] Permission denied:
3098 ;; '/homeless-shelter'
3099 (setenv "HOME" "/tmp"))))))
3100 (native-inputs
3101 (list python-poetry-core
3102 python-pytest
3103 python-pytest-rerunfailures
3104 python-pytest-xdist
3105 python-requests-mock
3106 python-responses
3107 python-rich
3108 python-tenacity
3109 python-time-machine
3110 python-timeout-decorator))
3111 (propagated-inputs
3112 (list python-attrs
3113 python-boto3
3114 python-bson
3115 python-cattrs
3116 python-itsdangerous
3117 python-orjson
3118 python-platformdirs
3119 python-pymongo
3120 python-pyyaml
3121 python-redis
3122 python-requests
3123 python-ujson
3124 python-url-normalize
3125 python-urllib3))
3126 (home-page "https://github.com/requests-cache/requests-cache")
3127 (synopsis "Persistent HTTP cache for Python requests")
3128 (description
3129 "This package provides a drop-in replacement for @code{requests.Session}
3130with caching offload to SQLite, Redis, MongoDB and AWS DynamoDB or save
3131responses as planin JSON/YAML file or save responses as plain JSON/YAML
3132files.")
3133 (license license:bsd-2)))
3134
3135(define-public python-requests-futures
3136 (package
3137 (name "python-requests-futures")
3138 (version "1.0.2")
3139 (source
3140 (origin
3141 (method url-fetch)
3142 (uri (pypi-uri "requests_futures" version))
3143 (sha256
3144 (base32 "1njqfjmd72l5f32jvcppg2afrvb0cd8angdwmq7q0vik81wvazkb"))))
3145 (build-system pyproject-build-system)
3146 (native-inputs
3147 (list python-greenlet
3148 python-pytest
3149 python-pytest-httpbin
3150 python-setuptools
3151 python-werkzeug))
3152 (propagated-inputs (list python-requests))
3153 (home-page "https://github.com/ross/requests-futures")
3154 (synopsis "Asynchronous Python HTTP for Humans")
3155 (description
3156 "This package provides and add-on the Python Requests HTTP library to run
3157code asynchronously.")
3158 (license license:asl2.0)))
3159
3160(define-public python-s3path
3161 (package
3162 (name "python-s3path")
3163 (version "0.6.4")
3164 (source
3165 (origin
3166 (method url-fetch)
3167 (uri (pypi-uri "s3path" version))
3168 (sha256
3169 (base32 "1lp5243jjf9ngqmajgnfr1px1kmpkfmgh248xlqz0nkww4wcy1hh"))))
3170 (build-system pyproject-build-system)
3171 (arguments
3172 (list
3173 ;; XXX: All tests fail with error: fixture 's3_mock' not found.
3174 #:tests? #f))
3175 (native-inputs
3176 (list python-setuptools
3177 python-wheel))
3178 (propagated-inputs
3179 (list python-boto3
3180 python-smart-open))
3181 (home-page "https://github.com/liormizr/s3path")
3182 (synopsis "Pathlib extension for AWS S3 Service")
3183 (description
3184 "S3Path provide a Python convenient File-System/Path like interface for
3185AWS S3 Service using boto3 S3 resource as a driver.")
3186 (license license:asl2.0)))
3187
3188(define-public python-falcon
3189 (package
3190 (name "python-falcon")
3191 (version "4.0.2")
3192 (source
3193 (origin
3194 ;; Use git, as there are some test files missing from the PyPI release,
3195 ;; such as 'examples' directory.
3196 (method git-fetch)
3197 (uri (git-reference
3198 (url "https://github.com/falconry/falcon")
3199 (commit version)))
3200 (file-name (git-file-name name version))
3201 (sha256
3202 (base32
3203 "1zhyvfbz4c1bxd4vbsgk19dzih6kkzgin10lmsr32x3b4qgnwqxs"))))
3204 (build-system pyproject-build-system)
3205 (arguments
3206 (list
3207 #:test-flags
3208 '(list "-k" "not slow"
3209 "--ignore-glob=examples/*" "--ignore-glob=bench/*" "tests")
3210 #:phases
3211 '(modify-phases %standard-phases
3212 (add-before 'check 'pre-check
3213 (lambda _
3214 (setenv "FALCON_ASGI_WRAP_NON_COROUTINES" "Y")
3215 (setenv "FALCON_TESTING_SESSION" "Y")
3216 (setenv "PYTHONASYNCIODEBUG" "1")
3217 (setenv "HOME" "/tmp"))))))
3218 (propagated-inputs
3219 (list python-mimeparse))
3220 (native-inputs
3221 (list python-aiofiles
3222 python-cbor2
3223 python-cython ;for faster binaries
3224 python-fakeredis
3225 python-httpx
3226 python-mujson
3227 python-msgpack
3228 python-orjson
3229 python-pecan
3230 python-pillow
3231 python-pytest
3232 python-pytest-asyncio
3233 python-pytest-runner
3234 python-pyyaml
3235 python-rapidjson
3236 python-requests
3237 python-setuptools
3238 python-testtools
3239 python-ujson
3240 python-websockets
3241 python-wheel))
3242 (home-page "https://falconframework.org")
3243 (synopsis "Web framework for building APIs and application backends")
3244 (description "Falcon is a web API framework for building microservices,
3245application backends and higher-level frameworks. Among its features are:
3246@itemize
3247@item Optimized and extensible code base
3248@item Routing via URI templates and REST-inspired resource
3249classes
3250@item Access to headers and bodies through request and response
3251classes
3252@item Request processing via middleware components and hooks
3253@item Idiomatic HTTP error responses
3254@item Straightforward exception handling
3255@item Unit testing support through WSGI helpers and mocks
3256@item Compatible with both CPython and PyPy
3257@item Cython support for better performance when used with CPython
3258@end itemize")
3259 (license license:asl2.0)))
3260
3261(define-public python-falcon-cors
3262 (package
3263 (name "python-falcon-cors")
3264 (properties '((commit . "41e9f075e193c1f76b26c0a8c67ad6e87462dfa6")
3265 (revision . "0")))
3266 (version (git-version "1.1.7"
3267 (assoc-ref properties 'revision)
3268 (assoc-ref properties 'commit)))
3269 (source
3270 (origin
3271 (method git-fetch)
3272 (uri (git-reference
3273 (url "https://github.com/lwcolton/falcon-cors")
3274 (commit (assoc-ref properties 'commit))))
3275 (file-name (git-file-name name version))
3276 (sha256
3277 (base32 "0iqz1i1p5xr32n34j77p2a86jmrkg1w90d2wcmmy1mhi5mgdm5gx"))))
3278 (build-system pyproject-build-system)
3279 (arguments
3280 (list
3281 ;; XXX: The last commit's tests are uncompatible with the more recent
3282 ;; version of python-falcon.
3283 #:tests? #f))
3284 (native-inputs
3285 (list python-falcon python-mock python-pynose python-setuptools))
3286 (home-page "https://github.com/lwcolton/falcon-cors")
3287 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
3288 (description
3289 "This middleware provides @dfn{cross-origin resource sharing} (CORS)
3290support for Falcon. It allows applying a specially crafted CORS object to the
3291incoming requests, enabling the ability to serve resources over a different
3292origin than that of the web application.")
3293 (license license:asl2.0)))
3294
3295(define-public python-furl
3296 (package
3297 (name "python-furl")
3298 (version "2.1.4")
3299 (source
3300 (origin
3301 (method url-fetch)
3302 (uri (pypi-uri "furl" version))
3303 (sha256
3304 (base32 "05b058xisv8kghvcpaxvssml2jjkh1cmzyrrjwk2kjb62985fxl7"))))
3305 (build-system pyproject-build-system)
3306 (arguments
3307 (list #:test-flags
3308 #~(list "-k" (string-append "not test_hosts"
3309 " and not test_netloc"
3310 " and not test_odd_urls"))))
3311 (propagated-inputs
3312 (list python-orderedmultidict python-six))
3313 (native-inputs
3314 (list python-pytest python-setuptools python-wheel))
3315 (home-page "https://github.com/gruns/furl")
3316 (synopsis "URL manipulation in Python")
3317 (description "Furl provides an easy-to-use alternative to the
3318@code{urllib} and @code{urlparse} modules for manipulating URLs.")
3319 (license license:unlicense)))
3320
3321(define-public python-httplib2
3322 (package
3323 (name "python-httplib2")
3324 (version "0.22.0")
3325 (source
3326 (origin
3327 ;; Tests not included in the release tarball.
3328 (method git-fetch)
3329 (uri (git-reference
3330 (url "https://github.com/httplib2/httplib2")
3331 (commit (string-append "v" version))))
3332 (file-name (git-file-name name version))
3333 (sha256
3334 (base32
3335 "1zkp3glv0iha7p68p5m0sb8mrrammkdc0mx32517xry52s4iva7g"))))
3336 (build-system pyproject-build-system)
3337 (arguments
3338 (list
3339 #:phases
3340 #~(modify-phases %standard-phases
3341 (add-after 'unpack 'adjust-test-requirements
3342 (lambda _
3343 (substitute* "requirements-test.txt"
3344 (("==") ">=")))))))
3345 (native-inputs
3346 (list python-cryptography
3347 python-future
3348 python-mock
3349 python-pyparsing
3350 python-pytest
3351 python-pytest-cov
3352 python-pytest-randomly
3353 python-pytest-timeout
3354 python-setuptools))
3355 (home-page "https://github.com/httplib2/httplib2")
3356 (synopsis "Comprehensive HTTP client library")
3357 (description
3358 "A comprehensive HTTP client library supporting many features left out of
3359other HTTP libraries.")
3360 (license license:expat)))
3361
3362(define-public python-cheroot
3363 (package
3364 (name "python-cheroot")
3365 (version "10.0.1")
3366 (source
3367 (origin
3368 (method url-fetch)
3369 (uri (pypi-uri "cheroot" version))
3370 (sha256
3371 (base32
3372 "0h0p3fnpa4dxi589s7ljlzb6p3mhqdivb3pc2f36pljqfrwjzf70"))))
3373 (build-system pyproject-build-system)
3374 (arguments
3375 (list
3376 #:test-flags
3377 #~(list "--cov=cheroot"
3378 ;; Tests are flaky in parallel invocation.
3379 ;; "--numprocesses=auto"
3380 "--doctest-modules"
3381 "--showlocals"
3382 "-k" (string-append
3383 ;; Disable test requiring networking.
3384 "not test_tls_client_auth"
3385 ;; TypeError: HTTPConnection.request() got an unexpected keyword
3386 ;; argument 'chunked'
3387 " and not test_peercreds_unix_sock"
3388 " and not test_peercreds_unix_sock_with_lookup"))
3389 #:phases
3390 #~(modify-phases %standard-phases
3391 (replace 'check
3392 (lambda* (#:key tests? test-flags #:allow-other-keys)
3393 (when tests?
3394 (with-directory-excursion "/tmp"
3395 (apply invoke "pytest" "-v"
3396 (append test-flags (list #$output))))))))))
3397 (propagated-inputs
3398 (list python-jaraco-functools python-more-itertools))
3399 (native-inputs
3400 (list python-jaraco-text
3401 python-portend
3402 python-pyopenssl
3403 python-pypytools
3404 python-pytest-cov
3405 python-pytest-mock
3406 python-requests
3407 python-requests-toolbelt
3408 python-requests-unixsocket2
3409 python-setuptools
3410 python-setuptools-scm
3411 python-trustme
3412 python-wheel))
3413 (home-page "https://cheroot.cherrypy.dev")
3414 (synopsis "Highly-optimized, pure-python HTTP server")
3415 (description
3416 "Cheroot is a high-performance, pure-Python HTTP server.")
3417 (license license:bsd-3)))
3418
3419(define-public python-cherrypy
3420 (package
3421 (name "python-cherrypy")
3422 (version "18.10.0")
3423 (source
3424 (origin
3425 (method git-fetch)
3426 (uri (git-reference
3427 (url "https://github.com/cherrypy/cherrypy")
3428 (commit (string-append "v" version))))
3429 (file-name (git-file-name name version))
3430 (sha256
3431 (base32 "1mhs64z75mj3rk4rgxc3xm1yksaj253rj9czhk4632blz5yi0kbn"))))
3432 (build-system pyproject-build-system)
3433 (arguments
3434 (list
3435 #:test-flags
3436 #~(map
3437 (lambda (test)
3438 (string-append "--deselect=cherrypy/test/" test))
3439 (list
3440 ;; XXX: Unraisable exceptions.
3441 "test_config_server.py::ServerConfigTests::testMaxRequestSize"
3442 "test_core.py::CoreRequestHandlingTest::testRanges"
3443 "test_core.py::CoreRequestHandlingTest::testRedirect"
3444 "test_encoding.py::EncodingTests::\
3445test_multipart_decoding_bigger_maxrambytes"
3446 "test_encoding.py::EncodingTests::\
3447test_test_http.py::HTTPTests::test_post_filename_with_special_characters"
3448 "test_http.py::HTTPTests::test_post_multipart"
3449 "test_http.py::HTTPTests::test_post_filename_with_special_characters"
3450 "test_mime.py::SafeMultipartHandlingTest::test_Flash_Upload"
3451 "test_tutorials.py::TutorialTest::test09Files"))))
3452 (propagated-inputs
3453 (list python-cheroot
3454 python-jaraco-collections
3455 python-more-itertools
3456 python-portend
3457 python-zc-lockfile))
3458 (native-inputs
3459 (list python-objgraph
3460 python-path
3461 python-pytest
3462 python-pytest-cov
3463 python-pytest-forked
3464 python-pytest-services
3465 python-pytest-sugar
3466 python-requests-toolbelt
3467 python-setuptools))
3468 (home-page "https://www.cherrypy.dev")
3469 (synopsis "Object-Oriented HTTP framework")
3470 (description
3471 "CherryPy is a pythonic, object-oriented web framework. It helps in
3472building web applications in the same way any other object-oriented Python
3473program would be built.")
3474 (license license:bsd-3)))
3475
3476(define-public httpie
3477 (package
3478 (name "httpie")
3479 (version "3.2.4")
3480 (source
3481 (origin
3482 (method git-fetch)
3483 (uri (git-reference
3484 (url "https://github.com/httpie/cli")
3485 (commit version)))
3486 (file-name (git-file-name name version))
3487 (sha256
3488 (base32 "0ii11xfqkbawg1v8dlli4fqq5k3yc2v65z3j7k3p4gng998s94mr"))))
3489 (build-system pyproject-build-system)
3490 (arguments
3491 (list
3492 #:phases
3493 #~(modify-phases %standard-phases
3494 (add-before 'build 'remove-unnecessary-dependencies
3495 ;; Remove pip and setuptools dependencies so sanity-check.py passes.
3496 (lambda _
3497 (substitute* "setup.cfg"
3498 (("(pip|setuptools)") "")))))
3499 ;; tests: 951 passed, 23 skipped, 6 deselected, 4 xfailed, 122 warnings
3500 #:test-flags
3501 ;; test_plugins_cli.py communicates through subprocesses
3502 ;; mocking stdin, which does not work in the build container.
3503 ;; test_ssl.py cannot find the SSL certificates.
3504 ;; test_binary.py fails for an unknown reason.
3505 #~(list "--ignore=tests/test_plugins_cli.py"
3506 "--ignore=tests/test_ssl.py"
3507 "--ignore=tests/test_binary.py"
3508 ;; Assertion failed to compare Unicode characters.
3509 (string-append
3510 "--deselect=tests/test_encoding.py"
3511 "::test_terminal_output_request_charset_detection")
3512 (string-append
3513 "--deselect=tests/test_encoding.py"
3514 "::test_terminal_output_response_charset_detection"))))
3515 (native-inputs (list python-pytest
3516 python-pytest-httpbin
3517 python-pytest-mock
3518 python-responses
3519 python-setuptools
3520 python-werkzeug))
3521 (propagated-inputs
3522 (list python-charset-normalizer
3523 python-defusedxml
3524 python-multidict
3525 python-pygments
3526 python-requests
3527 python-requests-toolbelt
3528 python-rich))
3529 (home-page "https://httpie.io")
3530 (synopsis "Modern, user-friendly command-line HTTP client for the API era")
3531 (description
3532 "A command line HTTP client with an intuitive UI, JSON support,
3533syntax highlighting, wget-like downloads, plugins, and more. It consists of
3534a single http command designed for painless debugging and interaction with
3535HTTP servers, RESTful APIs, and web services.")
3536 ;; CVE-2019-10751 was fixed in 1.0.3.
3537 (properties `((lint-hidden-cve "CVE-2019-10751")))
3538 (license license:bsd-3)))
3539
3540(define-public python-parfive
3541 (package
3542 (name "python-parfive")
3543 (version "2.2.0")
3544 (source
3545 (origin
3546 (method url-fetch)
3547 (uri (pypi-uri "parfive" version))
3548 (sha256
3549 (base32 "16rf02jhjr9lij8s2gqmvs01vx8kiv9f2535dnnziqwqv14d21yy"))))
3550 (build-system pyproject-build-system)
3551 (arguments
3552 (list
3553 #:test-flags
3554 ;; Disable tests requiring network access.
3555 #~(list "-k" (string-join
3556 (list "not test_ftp"
3557 "test_ftp_pasv_command"
3558 "test_ftp_http")
3559 " and not "))))
3560 (native-inputs
3561 (list python-pytest
3562 python-pytest-asyncio
3563 python-pytest-cov
3564 python-pytest-localserver
3565 python-pytest-socket
3566 python-setuptools
3567 python-setuptools-scm
3568 python-wheel))
3569 (propagated-inputs
3570 (list python-aiofiles
3571 python-aioftp
3572 python-aiohttp
3573 python-tqdm))
3574 (home-page "https://parfive.readthedocs.io/")
3575 (synopsis "HTTP and FTP parallel file downloader")
3576 (description
3577 "This package provides CLI tool and Python library @code{parallel} file
3578downloader using asyncio. parfive can handle downloading multiple files in
3579parallel as well as downloading each file in a number of chunks.
3580
3581asciicast demo of parfive parfive works by creating a downloader object,
3582appending files to it and then running the download. parfive has a synchronous
3583API, but uses asyncio to parallelise downloading the files.")
3584 (license license:expat)))
3585
3586(define-public python-html2text
3587 (package
3588 (name "python-html2text")
3589 (version "2020.1.16")
3590 (source
3591 (origin
3592 (method url-fetch)
3593 (uri (pypi-uri "html2text" version))
3594 (sha256
3595 (base32 "1fvv4z6dblii2wk1x82981ag8yhxbim1v2ksgywxsndh2s7335p2"))))
3596 (build-system pyproject-build-system)
3597 (native-inputs (list python-pytest python-setuptools python-wheel))
3598 (home-page "https://github.com/Alir3z4/html2text")
3599 (synopsis "Convert HTML into plain text")
3600 (description
3601 "html2text takes HTML and converts it into plain ASCII text
3602which is also valid markdown. html2text was originally written by Aaron
3603Swartz.")
3604 (license license:gpl3+)))
3605
3606(define-public python-jose
3607 (package
3608 (name "python-jose")
3609 (version "3.5.0")
3610 (home-page "https://github.com/mpdavis/python-jose")
3611 (source (origin
3612 (method git-fetch)
3613 (uri (git-reference (url home-page) (commit version)))
3614 (file-name (git-file-name name version))
3615 (sha256
3616 (base32
3617 "0frv7r6q43mjl7s82hh8qvqpdgyfvmyq2b6aq4402riq2i238d7h"))))
3618 (build-system pyproject-build-system)
3619 (native-inputs
3620 (list python-pyasn1 python-pytest python-setuptools))
3621 (propagated-inputs
3622 (list python-cryptography python-ecdsa python-rsa))
3623 (synopsis "JOSE implementation in Python")
3624 (description
3625 "The @dfn{JavaScript Object Signing and Encryption} (JOSE) technologies
3626- JSON Web Signature (JWS), JSON Web Encryption (JWE), JSON Web Key (JWK), and
3627JSON Web Algorithms (JWA) - collectively can be used to encrypt and/or sign
3628content using a variety of algorithms.")
3629 (license license:expat)))
3630
3631(define-public python-joserfc
3632 (package
3633 (name "python-joserfc")
3634 (version "1.0.1")
3635 (source
3636 (origin
3637 (method url-fetch)
3638 (uri (pypi-uri "joserfc" version))
3639 (sha256
3640 (base32 "11m600bmj70bp96wxhwvyj4d57w0zahzq3vic7s4a4k85pl7nl64"))))
3641 (build-system pyproject-build-system)
3642 (arguments
3643 (list
3644 #:test-flags
3645 ;; No module named 'Crypto'
3646 '(list "--ignore=tests/jwe/test_chacha20.py"
3647 ;; Deprecation warnings are not raised.
3648 "-k" (string-append "not test_guess_bytes_key"
3649 " and not test_guess_callable_key"
3650 " and not test_guess_str_key"))))
3651 (propagated-inputs (list python-cryptography))
3652 (native-inputs (list python-pytest python-setuptools python-wheel))
3653 (home-page "https://github.com/authlib/joserfc")
3654 (synopsis "Python library for JOSE RFCs")
3655 (description
3656 "This package provides a Python library for JOSE RFCs, including JWS,
3657JWE, JWK, JWA, and JWT.")
3658 (license license:bsd-3)))
3659
3660(define-public python-jwcrypto
3661 (package
3662 (name "python-jwcrypto")
3663 (version "1.5.6")
3664 (source
3665 (origin
3666 (method url-fetch)
3667 (uri (pypi-uri "jwcrypto" version))
3668 (sha256
3669 (base32 "0fdhn5jrsdxqr1yr6rmh585q4j08z1aajn392vk1l20c59v8f6kp"))))
3670 (build-system pyproject-build-system)
3671 (native-inputs
3672 (list python-pytest
3673 python-setuptools))
3674 (propagated-inputs
3675 (list python-cryptography
3676 python-typing-extensions))
3677 (home-page "https://github.com/latchset/jwcrypto")
3678 (synopsis "Implementation of JOSE Web standards")
3679 (description
3680 "WCrypto is an implementation of the @dfn{Javascript Object Signing and
3681Encryption} (JOSE) Web Standards.")
3682 (license license:lgpl3+)))
3683
3684(define-public python-pypitoken
3685 (package
3686 (name "python-pypitoken")
3687 (version "7.0.1")
3688 (source
3689 (origin
3690 (method url-fetch)
3691 (uri (pypi-uri "pypitoken" version))
3692 (sha256
3693 (base32 "18hhwmdfs9y5ypl1n8z2h2ys2f52mv5xr043gzgb34mpmg0wi46x"))))
3694 (build-system pyproject-build-system)
3695 ;; There are no tests.
3696 (arguments (list #:tests? #false))
3697 (propagated-inputs (list python-jsonschema python-pymacaroons
3698 python-typing-extensions))
3699 (native-inputs (list python-poetry-core))
3700 (home-page "https://pypitoken.readthedocs.io/en/latest/")
3701 (synopsis "Manipulate PyPI API tokens")
3702 (description "This package lets you manipulate PyPI API tokens.")
3703 (license license:expat)))
3704
3705(define-public python-pyscss
3706 ;; XXX: no fresh release supporting Python 3.11, use the latest commit, see
3707 ;; <https://github.com/Kronuz/pyScss/issues/428>,
3708 ;; <https://github.com/Kronuz/pyScss/issues/431>.
3709 (let ((commit "73559d047706ccd4593cf6aa092de71f35164723")
3710 (revision "0"))
3711 (package
3712 (name "python-pyscss")
3713 (version (git-version "1.4.0" revision commit))
3714 (source
3715 (origin
3716 (method git-fetch) ; no tests in PyPI release
3717 (uri (git-reference
3718 (url "https://github.com/Kronuz/pyScss")
3719 (commit commit)))
3720 (file-name (git-file-name name version))
3721 (sha256
3722 (base32 "00msypxf5dm57gyfp3jxvjinigi4km84v33w83635pms9li2k3y7"))))
3723 (build-system pyproject-build-system)
3724 (native-inputs
3725 (list python-pytest-8
3726 python-setuptools))
3727 (inputs
3728 (list pcre))
3729 (propagated-inputs
3730 (list python-six)) ;hard dependency in scss/compiler.py
3731 (home-page "https://github.com/Kronuz/pyScss")
3732 (synopsis "Scss compiler for Python")
3733 (description
3734 "@code{pyScss} is a compiler for Sass, a superset language of
3735CSS3 that adds programming capabilities and some other syntactic sugar.")
3736 (license license:expat))))
3737
3738(define-public python-jsonpickle
3739 (package
3740 (name "python-jsonpickle")
3741 (version "4.0.0")
3742 (source (origin
3743 (method url-fetch)
3744 (uri (pypi-uri "jsonpickle" version))
3745 (sha256
3746 (base32
3747 "0dipys8p4hkqnp9nwkpysfv7mhws2hrr73wgn00pdmq4n990hrzw"))))
3748 (build-system pyproject-build-system)
3749 (arguments
3750 (list
3751 #:test-flags
3752 ;; Prevent running the flake8 and black pytest plugins, which only tests
3753 ;; style and frequently causes harmless failures.
3754 '(list "-o" "addopts=''" "tests")
3755 #:phases
3756 '(modify-phases %standard-phases
3757 (add-before 'check 'pre-check
3758 (lambda* (#:key inputs #:allow-other-keys)
3759 (setenv "TZ" "UTC")
3760 (setenv "TZDIR"
3761 (search-input-directory inputs "share/zoneinfo")))))))
3762 (native-inputs
3763 (list python-bson
3764 python-ecdsa
3765 python-feedparser
3766 python-pymongo
3767 python-pytest
3768 python-pytest-benchmark
3769 python-pytest-cov
3770 python-pytest-enabler
3771 python-setuptools
3772 python-setuptools-scm
3773 python-simplejson
3774 python-sqlalchemy
3775 python-ujson
3776 python-wheel
3777 tzdata-for-tests))
3778 (home-page "https://jsonpickle.github.io/")
3779 (synopsis "Serialize object graphs into JSON")
3780 (description
3781 "This package provides a Python library for serializing any arbitrary
3782object graph to and from JSON.")
3783 (license license:bsd-3)))
3784
3785(define-public python-mcp
3786 (package
3787 (name "python-mcp")
3788 (version "1.25.0")
3789 (source
3790 (origin
3791 (method url-fetch)
3792 (uri (pypi-uri "mcp" version))
3793 (sha256
3794 (base32 "00k87bl4jvnh7hrmicwb2m715fwccvvlanwf8cnlwdphxdhh6can"))))
3795 (build-system pyproject-build-system)
3796 (arguments
3797 (list
3798 ;; XXX: 186 failed, 648 passed, 94 skipped, 54 errors
3799 ;; A lot of tests fail for unclear reasons.
3800 #:tests? #f))
3801 (propagated-inputs (list python-httpx python-pydantic))
3802 (native-inputs
3803 (list python-hatchling
3804 python-httpx-sse
3805 python-jsonschema
3806 python-pydantic-settings
3807 python-pytest
3808 python-pytest-examples
3809 python-pytest-xdist
3810 python-sse-starlette
3811 python-starlette
3812 python-typer
3813 python-typing-inspection
3814 python-uvicorn))
3815 (home-page "https://modelcontextprotocol.io")
3816 (synopsis "Model Context Protocol SDK")
3817 (description
3818 "This package provides a Python Software Development Kit for the Model
3819Context Protocol (MCP).")
3820 (license license:expat)))
3821
3822(define-public python-mechanicalsoup
3823 (package
3824 (name "python-mechanicalsoup")
3825 (version "1.4.0")
3826 (source
3827 (origin
3828 (method url-fetch)
3829 (uri (pypi-uri "mechanicalsoup" version))
3830 (sha256
3831 (base32 "0k1ac77ld6jyjm5fsr44399l5gmiwnz5w6s74i3qqx2scfbsgs6w"))))
3832 (build-system pyproject-build-system)
3833 (arguments
3834 (list
3835 #:test-flags
3836 ;; Unclear why test fails.
3837 #~(list "-k" "not test_select_form_associated_elements")
3838 ;; The following dependencies are not directly required, the developer
3839 ;; only pinned versions because of vulnerabilities. They also break
3840 ;; sanity-check because it checks for a python-certifi version which is
3841 ;; more recent than the one available in Guix.
3842 #:phases #~(modify-phases %standard-phases
3843 (add-after 'unpack 'relax-dependencies
3844 (lambda _
3845 (substitute* "requirements.txt"
3846 (("certifi.*") "")
3847 (("urllib3.*") "")))))))
3848 (propagated-inputs
3849 (list python-beautifulsoup4 python-lxml python-requests))
3850 (native-inputs
3851 (list python-pytest
3852 python-pytest-cov
3853 python-pytest-flake8
3854 python-pytest-httpbin
3855 python-pytest-mock
3856 python-requests-mock
3857 python-setuptools
3858 python-wheel))
3859 (home-page "https://mechanicalsoup.readthedocs.io/")
3860 (synopsis "Python library for automating website interaction")
3861 (description
3862 "MechanicalSoup is a Python library for automating interaction with
3863websites. It automatically stores and sends cookies, follows redirects, and can
3864follow links and submit forms. It doesn’t do JavaScript.")
3865 (license license:expat)))
3866
3867(define-public python-hyperframe
3868 (package
3869 (name "python-hyperframe")
3870 (version "6.1.0")
3871 (source
3872 (origin
3873 (method url-fetch)
3874 (uri (pypi-uri "hyperframe" version))
3875 (sha256
3876 (base32 "021v58w1b7mbwqkvbz11p3a4qk1sj91jnf6nmgg7ljl502590c7n"))))
3877 (build-system pyproject-build-system)
3878 (native-inputs
3879 (list python-pytest python-setuptools))
3880 (home-page "https://github.com/python-hyper/hyperframe")
3881 (synopsis "HTTP/2 framing layer for Python")
3882 (description
3883 "This library contains the HTTP/2 framing code used in the hyper project.
3884It provides a pure-Python codebase that is capable of decoding a binary stream
3885into HTTP/2 frames.")
3886 (license license:expat)))
3887
3888(define-public python-hpack
3889 (package
3890 (name "python-hpack")
3891 (version "4.1.0")
3892 (source
3893 (origin
3894 ;; PyPI tarball is missing some files necessary for the tests.
3895 (method git-fetch)
3896 (uri (git-reference
3897 (url "https://github.com/python-hyper/hpack")
3898 (commit (string-append "v" version))))
3899 (file-name (git-file-name name version))
3900 (sha256
3901 (base32 "1kgbx38p3a48iz914dqbx7av750a3s3x5kj3rvpcbh23ah75zg5x"))))
3902 (build-system pyproject-build-system)
3903 (native-inputs
3904 (list python-pytest python-setuptools))
3905 (home-page "https://hyper.rtfd.org")
3906 (synopsis "Pure-Python HPACK header compression")
3907 (description
3908 "This module contains a pure-Python HTTP/2 header encoding (HPACK) logic
3909for use in Python programs that implement HTTP/2.")
3910 (license license:expat)))
3911
3912(define-public python-h11
3913 (package
3914 (name "python-h11")
3915 (version "0.16.0")
3916 (source
3917 (origin
3918 (method url-fetch)
3919 (uri (pypi-uri "h11" version))
3920 (sha256
3921 (base32 "1wazxq4b4jg5001h5ypvz9pvrg80pagyd1aqm962wya5rxbbjdaf"))))
3922 (build-system pyproject-build-system)
3923 (native-inputs
3924 (list python-pytest python-setuptools))
3925 (home-page "https://github.com/python-hyper/h11")
3926 (synopsis "Pure-Python, bring-your-own-I/O implementation of HTTP/1.1")
3927 (description
3928 "This is a little HTTP/1.1 library written from scratch in Python, heavily
3929inspired by hyper-h2. It's a bring-your-own-I/O library; h11 contains no IO
3930code whatsoever. This means you can hook h11 up to your favorite network API,
3931and that could be anything you want.")
3932 (license license:expat)))
3933
3934(define-public python-h2
3935 (package
3936 (name "python-h2")
3937 (version "4.1.0")
3938 (source
3939 (origin
3940 (method url-fetch)
3941 (uri (pypi-uri "h2" version))
3942 (sha256
3943 (base32 "1fraip114fm1ha5w37pdc0sk8dn9pb0ck267zrwwpap7zc4clfm8"))))
3944 (build-system pyproject-build-system)
3945 (arguments
3946 (list
3947 ;; AssertionError: assert '<RemoteSettingsChanged
3948 ;; changed_settings:{ChangedSetting(setting=4, original_value=65536,
3949 ;; new_value=32768)}>' == '<RemoteSettingsChanged
3950 ;; changed_settings:{ChangedSetting(setting=SettingCodes.INITIAL_WINDOW_SIZE,
3951 ;; original_value=65536, new_value=32768)}>'
3952 #:test-flags
3953 #~(list "-k"
3954 (string-join
3955 (list "not test_remotesettingschanged_repr"
3956 ;; This test exceededs the Hypothesis deadline.
3957 #$@(if (target-riscv64?)
3958 #~("test_changing_max_frame_size")
3959 #~())
3960 "test_streamreset_repr"
3961 "test_settingsacknowledged_repr"
3962 "test_connectionterminated_repr[None-None]"
3963 "test_connectionterminated_repr[some"
3964 "test_remotesettingschanged_repr"
3965 "test_streamreset_repr"
3966 "test_settingsacknowledged_repr"
3967 "test_connectionterminated_repr[None-None]"
3968 "test_connectionterminated_repr[some")
3969 " and not "))))
3970 (native-inputs
3971 (list python-pytest
3972 python-setuptools
3973 python-wheel))
3974 (propagated-inputs
3975 (list python-hpack
3976 python-hyperframe))
3977 (home-page "https://github.com/python-hyper/h2")
3978 (synopsis "HTTP/2 State-Machine based protocol implementation")
3979 (description
3980 "This module contains a pure-Python implementation of a HTTP/2 protocol
3981stack. It does not provide a parsing layer, a network layer, or any rules
3982about concurrency. Instead, it's a purely in-memory solution, defined in
3983terms of data actions and HTTP/2 frames. This is one building block of a full
3984Python HTTP implementation.")
3985 (license license:expat)))
3986
3987(define-public python-slixmpp
3988 (package
3989 (name "python-slixmpp")
3990 (version "1.8.6") ; XXX: The latest version which does not requrie Rust
3991 (source
3992 (origin
3993 (method git-fetch)
3994 (uri (git-reference
3995 (url "https://codeberg.org/poezio/slixmpp")
3996 (commit (string-append "slix-" version))))
3997 (file-name (git-file-name name version))
3998 (sha256
3999 (base32 "0gpy6arwyk4lsx1hbcwbllxs6qbwn58adkp1rm1cfvfrjdv5kxx7"))))
4000 (build-system pyproject-build-system)
4001 (arguments
4002 (list
4003 #:phases
4004 #~(modify-phases %standard-phases
4005 (add-after 'unpack 'patch-setup.py
4006 (lambda _
4007 (substitute* "setup.py"
4008 (("'CC', 'cc'")
4009 "'CC', 'gcc'")))))))
4010 (native-inputs
4011 (list gnupg
4012 pkg-config
4013 python-cython
4014 python-setuptools
4015 python-wheel))
4016 (inputs
4017 (list libidn
4018 python)) ; We are building a Python extension.
4019 (propagated-inputs
4020 (list python-aiodns
4021 python-aiohttp
4022 python-cryptography
4023 python-defusedxml
4024 python-emoji
4025 python-pyasn1
4026 python-pyasn1-modules))
4027 (home-page "https://lab.louiz.org/poezio/slixmpp")
4028 (synopsis "XMPP library without threads")
4029 (description
4030 "Slixmpp is a XMPP library for Python 3.7+. It is a fork of SleekXMPP.
4031Its goal is to only rewrite the core of the library (the low level socket
4032handling, the timers, the events dispatching) in order to remove all
4033threads.")
4034 (license license:expat)))
4035
4036(define-public python-sockjs-tornado
4037 (package
4038 (name "python-sockjs-tornado")
4039 (version "1.0.6")
4040 (source
4041 (origin
4042 (method git-fetch)
4043 (uri (git-reference
4044 (url "https://github.com/mrjoes/sockjs-tornado/")
4045 (commit (string-append "v" version))))
4046 (file-name (git-file-name name version))
4047 (sha256
4048 (base32 "1y4wjca1776nvd0b79pz4d52i312xsyb2vahb883qmrw6s56mynk"))))
4049 (build-system pyproject-build-system)
4050 (arguments
4051 (list
4052 #:tests? #f)) ;The only test in examples/test/test.py runs a server.
4053 (native-inputs (list python-setuptools))
4054 (propagated-inputs (list python-tornado))
4055 (home-page "https://github.com/mrjoes/sockjs-tornado/")
4056 (synopsis
4057 "SockJS Python server implementation on top of the Tornado framework")
4058 (description
4059 "SockJS-tornado provides the server-side counterpart to a SockJS client
4060library, through the Tornado framework.
4061
4062SockJS provides a low-latency, full-duplex, cross-domain communication channel
4063between a web browser and web server.")
4064 (license license:expat)))
4065
4066(define-public python-flask-assets
4067 ;; The latest release still depends on the abandoned flask-script, whereas
4068 ;; at this later commit (already 2 years old at the time of this writing)
4069 ;; the dependency has been lifted.
4070 (let ((commit "62efd23fe95ee6a86fc1cfaa98fc1e2152093557")
4071 (revision "1"))
4072 (package
4073 (name "python-flask-assets")
4074 (version (git-version "2.1.0" revision commit))
4075 (source
4076 (origin
4077 (method git-fetch)
4078 (uri (git-reference
4079 (url "https://github.com/miracle2k/flask-assets/")
4080 (commit commit)))
4081 (file-name (git-file-name name version))
4082 (sha256
4083 (base32 "11q8vm2ipj4xrvawy9vl1l4k8kb4r72ghy1n8xrzci52v6lx8960"))))
4084 (build-system pyproject-build-system)
4085 (propagated-inputs
4086 (list python-flask python-webassets))
4087 (native-inputs
4088 (list nss-certs-for-test python-pytest python-setuptools python-wheel))
4089 (home-page "https://github.com/miracle2k/flask-assets")
4090 (synopsis "Asset management for Flask")
4091 (description "This package integrates @code{webassets} with Flask, adding
4092support for merging, minifying and compiling CSS and Javascript files.")
4093 (license license:bsd-2))))
4094
4095(define-public python-flask-babel
4096 (package
4097 (name "python-flask-babel")
4098 (version "4.0.0")
4099 (source
4100 (origin
4101 (method git-fetch) ;no tests in pypi release
4102 (uri (git-reference
4103 (url "https://github.com/python-babel/flask-babel")
4104 (commit (string-append "v" version))))
4105 (sha256
4106 (base32
4107 "19yq3f5rixbwhv7wxdarvi9hdj98a9dq8y76in9c1q3jxaigw104"))))
4108 (build-system pyproject-build-system)
4109 (native-inputs
4110 (list python-poetry-core
4111 python-pytest
4112 python-pytest-cov
4113 python-pytest-mock))
4114 (propagated-inputs
4115 (list python-babel
4116 python-flask
4117 python-jinja2
4118 python-pytz))
4119 (home-page "https://github.com/python-babel/flask-babel")
4120 (synopsis "Add i18n/l10n support to Flask applications")
4121 (description "This package implements internationalization and localization
4122support for Flask. This is based on the Python babel module as well as pytz -
4123both of which are installed automatically if you install this library.")
4124 (license license:bsd-3)))
4125
4126(define-public python-flask-cors
4127 (package
4128 (name "python-flask-cors")
4129 (version "6.0.2")
4130 (source
4131 (origin
4132 (method git-fetch) ;no tests in PyPI archive
4133 (uri (git-reference
4134 (url "https://github.com/CoryDolphin/flask-cors")
4135 (commit version)))
4136 (file-name (git-file-name name version))
4137 (sha256
4138 (base32 "02y740h951dscgkm7ghsss1bc0m8ymsfdpsimm1j0nkl0zjl6sgm"))))
4139 (build-system pyproject-build-system)
4140 (arguments
4141 (list
4142 #:phases
4143 #~(modify-phases %standard-phases
4144 (add-after 'unpack 'fix-version
4145 (lambda _
4146 ;; Otherwise sanity-check of dependents will fail.
4147 (substitute* "pyproject.toml"
4148 (("version = \"0\\.0\\.1\"" all)
4149 (string-append "version = \"" #$version "\""))))))))
4150 (native-inputs
4151 (list python-pytest
4152 python-setuptools))
4153 (propagated-inputs
4154 (list python-flask
4155 python-werkzeug))
4156 (home-page "https://flask-cors.readthedocs.io/en/latest/")
4157 (synopsis "Handle Cross-Origin Resource Sharing with Flask")
4158 (description
4159 "This package provides a Flask extension for handling @acronym{CORS,Cross
4160Origin Resource Sharing}, making cross-origin AJAX possible.")
4161 (license license:expat)))
4162
4163(define-public python-flask-markdown
4164 (package
4165 (name "python-flask-markdown")
4166 (version "0.3")
4167 (source
4168 (origin
4169 (method git-fetch)
4170 (uri (git-reference
4171 (url "https://github.com/dcolish/flask-markdown")
4172 (commit version)))
4173 (file-name (git-file-name name version))
4174 (sha256
4175 (base32 "1rqqmvjc4rjal6l4y3caxw9b3157pl923h4i1ihbm0gziqv3g2hl"))))
4176 (build-system pyproject-build-system)
4177 (arguments
4178 (list
4179 #:tests? #f ;Tests seem to be incompatible with latest python
4180 #:phases
4181 #~(modify-phases %standard-phases
4182 (add-after 'unpack 'set-version
4183 (lambda _
4184 (substitute* "setup.py"
4185 (("dev")
4186 #$version)))))))
4187 (propagated-inputs (list python-markdown python-flask))
4188 (native-inputs (list python-pynose python-setuptools))
4189 (home-page "https://github.com/dcolish/flask-markdown")
4190 (synopsis "Small extension to help with using Markdown in Flask")
4191 (description
4192 "Flask-Markdown supports several extensions for Markdown and integrates
4193into Jinja2 by default.")
4194 (license license:bsd-3)))
4195
4196(define-public python-flask-session
4197 (package
4198 (name "python-flask-session")
4199 (version "0.8.0")
4200 (source
4201 (origin
4202 (method url-fetch)
4203 (uri (pypi-uri "flask_session" version))
4204 (sha256
4205 (base32
4206 "1zs20zpq6gxz9gsccbd2jrrbbcfvh0x9z9741gkr8dhh07mlbq10"))))
4207 (build-system pyproject-build-system)
4208 (arguments
4209 '(#:tests? #f)) ; Tests require the various storage backends to be present
4210 (native-inputs (list python-flit-core))
4211 (propagated-inputs
4212 (list python-cachelib python-flask python-msgspec))
4213 (home-page "https://github.com/pallets-eco/flask-session")
4214 (synopsis "Adds server-side session support to your Flask application")
4215 (description
4216 "Flask-Session is an extension for Flask that adds support for
4217Server-side sessions, with a variety of different backends for session
4218storage.")
4219 (license license:bsd-3)))
4220
4221(define-public python-html5lib
4222 (package
4223 (name "python-html5lib")
4224 (version "1.1")
4225 (source
4226 (origin
4227 (method url-fetch)
4228 (uri (pypi-uri "html5lib" version))
4229 (sha256
4230 (base32 "0vqlhk0hgbsfkh7ybmby93xhlx8dq6pr5blf356ka3z2c41b9rdj"))))
4231 (build-system pyproject-build-system)
4232 (arguments
4233 '(#:tests? #f)) ;tests depent on dated pytest-expect
4234 (native-inputs
4235 (list python-setuptools))
4236 (propagated-inputs
4237 (list python-six
4238 python-webencodings
4239 ;; Required by Calibre 5.
4240 python-chardet))
4241 (home-page "https://github.com/html5lib/html5lib-python")
4242 (synopsis "Python HTML parser based on the WHATWG HTML specification")
4243 (description
4244 "Html5lib is an HTML parser based on the WHATWG HTML specification
4245and written in Python.")
4246 (license license:expat)))
4247
4248(define-public python-html5-parser
4249 (package
4250 (name "python-html5-parser")
4251 (version "0.4.12")
4252 (source
4253 (origin
4254 (method git-fetch)
4255 (uri (git-reference
4256 (url "https://github.com/kovidgoyal/html5-parser")
4257 (commit (string-append "v" version))))
4258 (file-name (git-file-name name version))
4259 (sha256
4260 (base32 "0axrz2x67nhsh3kijy68wwy5hx8h8418d8g2qz6f3pyxix7gw2fi"))))
4261 (build-system pyproject-build-system)
4262 (arguments
4263 (list
4264 #:phases
4265 #~(modify-phases %standard-phases
4266 (add-before 'build 'set-configure-flags
4267 (lambda _
4268 (setenv "CFLAGS" "-Wno-error=implicit-function-declaration"))))))
4269 (native-inputs (list pkg-config python-setuptools))
4270 (inputs (list libxml2))
4271 (propagated-inputs (list python-lxml python-beautifulsoup4 python-chardet))
4272 (home-page "https://html5-parser.readthedocs.io")
4273 (synopsis "Fast C-based HTML5 parsing for Python")
4274 (description
4275 "This package provides a fast implementation of the HTML5 parsing spec
4276for Python. Parsing is done in C using a variant of the gumbo parser. The
4277gumbo parse tree is then transformed into an lxml tree, also in C, yielding
4278parse times that can be a thirtieth of the html5lib parse times.")
4279 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
4280 ;; indicate ASL2.0, including the LICENSE file for the whole project.
4281 (license (list license:asl2.0 license:gpl3))))
4282
4283(define-public python-html5tagger
4284 (package
4285 (name "python-html5tagger")
4286 (version "1.3.0")
4287 (source (origin
4288 (method url-fetch)
4289 (uri (pypi-uri "html5tagger" version))
4290 (sha256
4291 (base32
4292 "1acd1a4f66gi4plqnsml7cf33qp83mxsnmnqpdwkpj7597xkvyl4"))))
4293 (build-system pyproject-build-system)
4294 (arguments
4295 (list #:tests? #f)) ;no tests in PyPI or Git
4296 (native-inputs
4297 (list python-setuptools python-setuptools-scm python-wheel))
4298 (home-page "https://github.com/sanic-org/html5tagger")
4299 (synopsis "Create HTML documents from Python")
4300 (description
4301 "@code{html5tagger} provides a simplified HTML5 syntax that can
4302be written directly in Python without templates.")
4303 (license license:unlicense)))
4304
4305(define-public python-minio
4306 (package
4307 (name "python-minio")
4308 (version "7.1.9")
4309 (source
4310 (origin
4311 (method git-fetch)
4312 (uri (git-reference
4313 (url "https://github.com/minio/minio-py")
4314 (commit version)))
4315 (file-name (git-file-name name version))
4316 (sha256
4317 (base32 "01734ki3p7844dya366hy1kvmmgy3xr0l0zbkchnnv4p611510vc"))))
4318 (build-system pyproject-build-system)
4319 (arguments
4320 (list
4321 #:test-flags
4322 ;; XXX: requires network access.
4323 #~(list "--ignore=tests/unit/credentials_test.py")))
4324 (native-inputs (list python-pytest python-setuptools))
4325 (propagated-inputs
4326 (list python-certifi python-dateutil python-pytz python-urllib3))
4327 (home-page "https://github.com/minio/minio-py")
4328 (synopsis "Programmatically access Amazon S3 from Python")
4329 (description
4330 "This package provides a Python library for interacting with any
4331Amazon S3 compatible object storage server.")
4332 (license license:asl2.0)))
4333
4334(define-public python-pycurl
4335 (package
4336 (name "python-pycurl")
4337 (version "7.45.4")
4338 (source
4339 (origin
4340 (method git-fetch)
4341 (uri (git-reference
4342 (url "https://github.com/pycurl/pycurl")
4343 (commit (string-append
4344 "REL_" (string-replace-substring version "." "_")))))
4345 (file-name (git-file-name name version))
4346 (sha256
4347 (base32 "00cd1l0lsml0708hpv5k4qyhqfv0qphb0p317j9aci2wdspn1mpl"))))
4348 (build-system pyproject-build-system)
4349 (arguments
4350 '(#:test-flags
4351 ;; The test suite is not thread safe:
4352 ;; - some tests want to use the same port: address already in use
4353 ;; - some tests use signal.Signal, i.e. main-thread only
4354 (list "-k" (string-append
4355 ;; Disable hanginging tests
4356 "not test_multi_socket_select"
4357 ;; E assert None is not None
4358 ;; E+ where None =
4359 ;; <tests.multi_callback_test.MultiCallbackTest
4360 ;; testMethod=test_multi_socket_action>.timer_result
4361 " and not test_multi_socket_action"
4362 ;; OSError: tests/fake-curl/libcurl/with_gnutls.so: cannot
4363 ;; open shared object file: No such file or directory
4364 " and not test_libcurl_ssl_gnutls"
4365 ;; OSError: tests/fake-curl/libcurl/with_nss.so: cannot
4366 ;; open shared object file: No such file or directory
4367 " and not test_libcurl_ssl_nss"
4368 ;; OSError: tests/fake-curl/libcurl/with_openssl.so: cannot
4369 ;; open shared object file: No such file or directory
4370 " and not test_libcurl_ssl_openssl"
4371 ;; Probably due to an expired CA
4372 " and not test_request_without_certinfo"
4373 ;; "A libcurl function was given a bad argument"
4374 " and not test_proxy_tlsauth"))
4375 #:phases (modify-phases %standard-phases
4376 (add-before 'build 'configure-tls-backend
4377 (lambda _
4378 ;; XXX: PycURL fails to automatically determine which
4379 ;; TLS backend to use when cURL is built with
4380 ;; --disable-static. See setup.py and
4381 ;; <https://github.com/pycurl/pycurl/pull/147>.
4382 (setenv "PYCURL_SSL_LIBRARY" "gnutls"))))))
4383 (native-inputs
4384 (list python-bottle
4385 python-flaky
4386 python-flask
4387 python-pytest
4388 python-setuptools
4389 python-wheel))
4390 (inputs
4391 (list curl gnutls))
4392 (home-page "http://pycurl.io/")
4393 (synopsis "Lightweight Python wrapper around libcurl")
4394 (description "Pycurl is a lightweight wrapper around libcurl. It provides
4395high-speed transfers via libcurl and frequently outperforms alternatives.")
4396
4397 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
4398 ;; under the terms of LGPLv2.1+ or Expat.
4399 (license (list license:lgpl2.1+ license:expat))))
4400
4401(define-public python-stamina
4402 (package
4403 (name "python-stamina")
4404 (version "25.2.0")
4405 (source
4406 (origin
4407 (method git-fetch)
4408 (uri (git-reference
4409 (url "https://github.com/hynek/stamina")
4410 (commit version)))
4411 (file-name (git-file-name name version))
4412 (sha256
4413 (base32 "100iadhzmxbavk0ras3srnagh9af5pxbqrm4mrrkyy69knih9jiy"))))
4414 (build-system pyproject-build-system)
4415 (native-inputs
4416 (list python-pytest
4417 python-anyio
4418 python-dirty-equals
4419 python-hatch-fancy-pypi-readme
4420 python-hatch-vcs
4421 python-hatchling
4422 python-structlog))
4423 (propagated-inputs
4424 (list python-tenacity
4425 python-typing-extensions))
4426 (home-page "https://github.com/hynek/stamina")
4427 (synopsis "Retries library for Python")
4428 (description
4429 "@code{stamina} is an opinionated wrapper around the
4430@url{https://tenacity.readthedocs.io/en/latest/, Tenacity} package.")
4431 (license license:expat)))
4432
4433(define-public python-stripe
4434 (package
4435 (name "python-stripe")
4436 (version "13.2.0")
4437 (source
4438 (origin
4439 (method git-fetch)
4440 (uri (git-reference
4441 (url "https://github.com/stripe/stripe-python")
4442 (commit (string-append "v" version))))
4443 (file-name (git-file-name name version))
4444 (sha256
4445 (base32 "0f0d1hqias3qylrhk56w055lqrlzjs9s7wxva30v54ykmn9nj6dx"))))
4446 (build-system pyproject-build-system)
4447 (arguments
4448 '(#:tests? #f)) ;; tests require network
4449 (native-inputs
4450 (list python-flit-core))
4451 (propagated-inputs
4452 (list python-httpx
4453 python-requests))
4454 (home-page "https://github.com/stripe/stripe-python")
4455 (synopsis "Python bindings for the Stripe financial services' API")
4456 (description "This package provides access to the Stripe financial
4457services' API. It includes a pre-defined set of classes for API resources
4458that initialize themselves dynamically from API responses which makes it
4459compatible with a wide range of versions of the Stripe API.")
4460 (license license:expat)))
4461
4462(define-public python-stripe-12
4463 (hidden-package
4464 (package/inherit python-stripe
4465 (name "python-stripe")
4466 (version "12.5.1")
4467 (source
4468 (origin
4469 (inherit (package-source python-stripe))
4470 (uri (git-reference
4471 (url "https://github.com/stripe/stripe-python")
4472 (commit (string-append "v" version))))
4473 (file-name (git-file-name name version))
4474 (sha256 (base32
4475 "0jgixfb8ydlx387vm7rdaqrzsiqbvi99nszrpb1ghjqyn755xigd"))))
4476 (native-inputs
4477 (list python-setuptools)))))
4478
4479(define-public python-tldextract
4480 (package
4481 (name "python-tldextract")
4482 (version "5.3.0")
4483 (source
4484 (origin
4485 (method url-fetch)
4486 (uri (pypi-uri "tldextract" version))
4487 (sha256
4488 (base32 "02c6cyh8f3dagcw786m9nl5y0n3xa98p5mb7d7xfr84l2l5bglmk"))))
4489 (build-system pyproject-build-system)
4490 (arguments
4491 (list
4492 #:phases
4493 #~(modify-phases %standard-phases
4494 (add-after 'unpack 'relax-requirements
4495 (lambda _
4496 (substitute* "pyproject.toml"
4497 (("\"requests-file.*\",")
4498 "\"requests-file\",")))))))
4499 (native-inputs
4500 (list nss-certs-for-test
4501 python-pytest
4502 python-pytest-mock
4503 python-responses
4504 python-setuptools
4505 python-setuptools-scm
4506 python-syrupy))
4507 (propagated-inputs
4508 (list python-filelock
4509 python-idna
4510 python-requests
4511 python-requests-file))
4512 (home-page "https://github.com/john-kurkowski/tldextract")
4513 (synopsis
4514 "Separate the TLD from the registered domain and subdomains of a URL")
4515 (description
4516 "TLDExtract accurately separates the TLD from the registered domain and
4517subdomains of a URL, using the Public Suffix List. By default, this includes
4518the public ICANN TLDs and their exceptions. It can optionally support the
4519Public Suffix List's private domains as well.")
4520 (license license:bsd-3)))
4521
4522(define-public python-tracerite
4523 (package
4524 (name "python-tracerite")
4525 (version "1.1.3")
4526 (source
4527 (origin
4528 (method url-fetch)
4529 (uri (pypi-uri "tracerite" version))
4530 (sha256
4531 (base32 "07mkg0sl0h335kj6yjvxki2c19gxhb7rkks1zgzh7aj0y83c17qi"))))
4532 (build-system pyproject-build-system)
4533 (arguments
4534 (list #:tests? #f)) ;no tests in PyPI or Git
4535 (native-inputs
4536 (list python-setuptools
4537 python-setuptools-scm))
4538 (propagated-inputs
4539 (list python-html5tagger))
4540 (home-page "https://github.com/sanic-org/tracerite")
4541 (synopsis "Human-readable HTML tracebacks")
4542 (description
4543 "@code{tracerite} converts Python tracebacks into useful error messages
4544in human-readable HTML format.")
4545 (license license:unlicense)))
4546
4547(define-public python-trio-websocket
4548 (package
4549 (name "python-trio-websocket")
4550 (version "0.12.2")
4551 (source
4552 (origin
4553 (method git-fetch)
4554 (uri (git-reference
4555 (url "https://github.com/HyperionGray/trio-websocket")
4556 (commit version)))
4557 (file-name (git-file-name name version))
4558 (sha256
4559 (base32 "1lm712gakpskcn3adna22kj8m1hspz9l68pmlziklr0ycphmyqac"))))
4560 (build-system pyproject-build-system)
4561 (native-inputs
4562 (list python-pytest
4563 python-pytest-trio
4564 python-setuptools
4565 python-trustme))
4566 (propagated-inputs
4567 (list python-outcome
4568 python-trio
4569 python-wsproto))
4570 (home-page "https://github.com/HyperionGray/trio-websocket")
4571 (synopsis "WebSocket library for Trio")
4572 (description "This library implements both server and client aspects of
4573the @url{https://tools.ietf.org/html/rfc6455, the WebSocket protocol},
4574striving for safety, correctness, and ergonomics. It is based on the
4575@url{https://wsproto.readthedocs.io/en/latest/, wsproto project}, which is a
4576@url{https://sans-io.readthedocs.io/, Sans-IO} state machine that implements
4577the majority of the WebSocket protocol, including framing, codecs, and events.
4578This library handles I/O using @url{https://trio.readthedocs.io/en/latest/,
4579the Trio framework}.")
4580 (license license:expat)))
4581
4582(define-public python-txacme
4583 ;; 0.9.3 tag was placed in 2020 and there a lot of changes providing
4584 ;; compatibility wit twisted, use the latest commit from trunk branch.
4585 ;;
4586 ;;See: <https://github.com/twisted/txacme/issues/165>.
4587 (let ((commit "ac18f92f6dde971a6b38f2ecfae44665815db583")
4588 (revision "0"))
4589 (package
4590 (name "python-txacme")
4591 (version (git-version "0.9.3" revision commit))
4592 (source
4593 (origin
4594 (method git-fetch) ;no fresh release in PyPI
4595 (uri (git-reference
4596 (url "https://github.com/twisted/txacme")
4597 (commit commit)))
4598 (file-name (git-file-name name version))
4599 (sha256
4600 (base32 "0mgdfxldv8qflbn75ywslbarnd4i3l7c4krs4aibl2dpryclsjzs"))))
4601 (build-system pyproject-build-system)
4602 (arguments
4603 (list #:test-backend #~'custom
4604 #:test-flags #~(list "-m" "twisted.trial" "txacme")))
4605 (native-inputs
4606 (list python-setuptools))
4607 (propagated-inputs
4608 (list python-acme
4609 python-attrs
4610 python-eliot
4611 python-josepy
4612 python-pem
4613 python-treq
4614 python-twisted
4615 python-txsni))
4616 (home-page "https://github.com/twisted/txacme")
4617 (synopsis "Twisted implexmentation of the ACME protocol")
4618 (description
4619 "ACME is Automatic Certificate Management Environment, a protocol that
4620allows clients and certificate authorities to automate verification and
4621certificate issuance. The ACME protocol is used by the free Let's Encrypt
4622Certificate Authority.
4623
4624txacme is an implementation of the protocol for Twisted, the event-driven
4625networking engine for Python.")
4626 (license license:expat))))
4627
4628(define-public python-txaio
4629 (package
4630 (name "python-txaio")
4631 (version "25.9.2")
4632 (source
4633 (origin
4634 (method url-fetch)
4635 (uri (pypi-uri "txaio" version))
4636 (sha256
4637 (base32 "16ch62yk2gdikkak113h6qw13ns9ksca817hky0vabn0fyh08874"))))
4638 (build-system pyproject-build-system)
4639 (native-inputs
4640 (list python-pytest
4641 python-setuptools))
4642 (home-page "https://github.com/crossbario/txaio")
4643 (synopsis "Compatibility layer between Python asyncio and Twisted")
4644 (description
4645 "Txaio provides a compatibility layer between the Python @code{asyncio}
4646 bsmodule and @code{Twisted}.")
4647 (license license:expat)))
4648
4649;; XXX: Potentially abandonware since 2017, consider to remove when nothing
4650;; depends on it or fails to build.
4651(define-public python-txamqp
4652 (package
4653 (name "python-txamqp")
4654 (version "0.8.2")
4655 (source
4656 (origin
4657 (method url-fetch)
4658 (uri (pypi-uri "txAMQP" version))
4659 (sha256
4660 (base32 "0jd9864k3csc06kipiwzjlk9mq4054s8kzk5q1cfnxj8572s4iv4"))))
4661 (build-system pyproject-build-system)
4662 (arguments
4663 (list #:tests? #f)) ;all tests failed
4664 (native-inputs
4665 (list python-setuptools))
4666 (propagated-inputs
4667 (list python-six python-twisted))
4668 (home-page "https://github.com/txamqp/txamqp")
4669 (synopsis "Communicate with AMQP peers and brokers using Twisted")
4670 (description
4671 "This package provides a Python library for communicating with AMQP peers
4672and brokers using the asynchronous networking framework Twisted. It contains
4673all the necessary code to connect, send and receive messages to/from an
4674AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It
4675also includes support for using Thrift RPC over AMQP in Twisted
4676applications.")
4677 (license license:asl2.0)))
4678
4679(define-public python-txsni
4680 (package
4681 (name "python-txsni")
4682 (version "0.2.0")
4683 (source
4684 (origin
4685 (method git-fetch)
4686 (uri (git-reference
4687 (url "https://github.com/glyph/txsni")
4688 (commit (string-append "v" version))))
4689 (file-name (git-file-name name version))
4690 (sha256
4691 (base32 "1fl8xi7vl24hwbva5v41l6nsrbkj2l2mlsgcvdjxgph61aznwywq"))))
4692 (build-system pyproject-build-system)
4693 (arguments
4694 (list #:test-backend #~'custom
4695 #:test-flags #~(list "-m" "twisted.trial"
4696 "--temp-directory=/tmp/_trial_temp"
4697 "txsni")))
4698 (native-inputs
4699 (list python-setuptools))
4700 (propagated-inputs
4701 (list python-pyopenssl
4702 python-service-identity
4703 python-twisted))
4704 (home-page "https://github.com/glyph/txsni")
4705 (synopsis "Run TLS servers with Twisted")
4706 (description
4707 "This package provides an easy-to-use SNI endpoint for use with the
4708Twisted web framework.")
4709 (license license:expat)))
4710
4711(define-public python-txtorcon
4712 (package
4713 (name "python-txtorcon")
4714 (version "24.8.0")
4715 (source
4716 (origin
4717 (method url-fetch)
4718 (uri (pypi-uri "txtorcon" version))
4719 (sha256
4720 (base32 "1l4ajw4h7nay4vmllh6cs7zh3hnh8vj4yvgfnq3m734wil9ikzmy"))))
4721 (build-system pyproject-build-system)
4722 (native-inputs
4723 (list python-pytest
4724 python-setuptools
4725 python-wheel))
4726 (inputs
4727 (list lsof))
4728 (propagated-inputs
4729 (list python-automat
4730 python-idna
4731 python-incremental
4732 python-pyopenssl
4733 python-service-identity
4734 python-twisted
4735 python-zope-interface))
4736 (home-page "https://github.com/meejah/txtorcon")
4737 (synopsis "Twisted-based Tor controller client")
4738 (description
4739 "This package provides a Twisted-based Tor controller client,with
4740state-tracking and configuration abstractions.")
4741 (license license:expat)))
4742
4743(define-public python-url-normalize
4744 (package
4745 (name "python-url-normalize")
4746 (version "2.2.1")
4747 (source
4748 (origin
4749 (method git-fetch) ; no tests in PyPI release
4750 (uri (git-reference
4751 (url "https://github.com/niksite/url-normalize")
4752 (commit (string-append "v" version))))
4753 (file-name (git-file-name name version))
4754 (sha256
4755 (base32 "1yhsf4sk6l6nznpnqigisbfz690a4g342dsk2n6dggh7q4l3amk4"))))
4756 (build-system pyproject-build-system)
4757 (arguments
4758 (list
4759 #:test-flags #~(list "--ignore=tests/test_cli.py")))
4760 (native-inputs
4761 (list python-pytest
4762 python-pytest-cov
4763 python-pytest-socket
4764 python-setuptools))
4765 (propagated-inputs
4766 (list python-idna))
4767 (home-page "https://github.com/niksite/url-normalize")
4768 (synopsis "URL normalization for Python")
4769 (description
4770 "This package provides a URI Normalization function with following
4771features:
4772@itemize
4773@item take care of IDN domains
4774@item always provide the URI scheme in lowercase characters
4775@item always provide the host, if any, in lowercase characters
4776@item only perform percent-encoding where it is essential
4777@item always use uppercase A-through-F characters when percent-encoding
4778@item prevent dot-segments appearing in non-relative URI paths
4779@item for schemes that define a default authority, use an empty authority if
4780the default is desired
4781@item for schemes that define an empty path to be equivalent to a path of
4782@code{/}, use @code{/}
4783@item for schemes that define a port, use an empty port if the default is
4784desired
4785@item all portions of the URI must be utf-8 encoded NFC from Unicode strings
4786@end itemize")
4787 (license license:expat)))
4788
4789(define-public python-waitress
4790 (package
4791 (name "python-waitress")
4792 (version "3.0.2")
4793 (source
4794 (origin
4795 (method url-fetch)
4796 (uri (pypi-uri "waitress" version))
4797 (sha256
4798 (base32
4799 "07y3xyx2006f2ni5d55byh3y7w4kcg9xww7vmfjasi0cmzralak8"))))
4800 (build-system pyproject-build-system)
4801 (arguments
4802 ;; https://github.com/Pylons/waitress/issues/443
4803 (list #:test-flags #~(list "-k" "not test_service_port")))
4804 (native-inputs
4805 (list python-pytest
4806 python-pytest-cov
4807 python-setuptools))
4808 (home-page "https://github.com/Pylons/waitress")
4809 (synopsis "Waitress WSGI server")
4810 (description
4811 "Waitress is meant to be a production-quality pure-Python WSGI server
4812with very acceptable performance.")
4813 (license license:zpl2.1)))
4814
4815(define-public python-weasel
4816 (package
4817 (name "python-weasel")
4818 (version "0.4.1")
4819 (source
4820 (origin
4821 (method url-fetch)
4822 (uri (pypi-uri "weasel" version))
4823 (sha256
4824 (base32 "1aas113r29y6yxrmdlsw80rj8w4kgw1jhfjw9rsgc4rf0w7j3g5a"))))
4825 (build-system pyproject-build-system)
4826 (arguments
4827 (list
4828 #:test-flags
4829 ;; Network access is required.
4830 #~(list #$@(map (lambda (test) (string-append "--deselect="
4831 "weasel/tests/cli/"
4832 test))
4833 (list "test_cli.py::test_project_git_dir_asset"
4834 "test_cli.py::test_project_git_file_asset"
4835 "test_cli_app.py::test_project_assets")))))
4836 (native-inputs
4837 (list python-pytest
4838 python-setuptools))
4839 (propagated-inputs
4840 (list python-cloudpathlib
4841 python-confection
4842 python-packaging
4843 python-pydantic
4844 python-requests
4845 python-smart-open
4846 python-srsly
4847 python-typer
4848 python-wasabi))
4849 (home-page "https://github.com/explosion/weasel/")
4850 (synopsis "Small and easy workflow system")
4851 (description
4852 "This package provides a minimalistic workflow system to manage and
4853share end-to-end workflows for different use cases and domains.")
4854 (license license:expat)))
4855
4856(define-public python-webencodings
4857 (package
4858 (name "python-webencodings")
4859 (version "0.5.1")
4860 (source
4861 (origin
4862 (method url-fetch)
4863 (uri (pypi-uri "webencodings" version))
4864 (sha256
4865 (base32 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
4866 (build-system pyproject-build-system)
4867 (arguments
4868 (list #:test-flags #~(list "webencodings/tests.py")))
4869 (native-inputs
4870 (list python-pytest python-setuptools))
4871 (home-page "https://github.com/SimonSapin/python-webencodings")
4872 (synopsis "Character encoding aliases for legacy web content")
4873 (description
4874 "In order to be compatible with legacy web content when interpreting
4875something like @code{Content-Type: text/html; charset=latin1}, tools need to
4876use a particular set of aliases for encoding labels as well as some overriding
4877rules. For example, @code{US-ASCII} and @code{iso-8859-1} on the web are
4878actually aliases for @code{windows-1252}, and a @code{UTF-8} or @code{UTF-16}
4879BOM takes precedence over any other encoding declaration. The WHATWG
4880@url{https://encoding.spec.whatwg.org/,Encoding} standard defines all such
4881details so that implementations do not have to reverse-engineer each other.
4882
4883This module implements the Encoding standard and has encoding labels and BOM
4884detection, but the actual implementation for encoders and decoders is
4885Python’s.")
4886 (license license:bsd-3)))
4887
4888(define-public python-omnipath
4889 (package
4890 (name "python-omnipath")
4891 (version "1.0.10")
4892 (source
4893 (origin
4894 (method git-fetch)
4895 (uri (git-reference
4896 (url "https://github.com/saezlab/omnipath/")
4897 (commit (string-append "v" version))))
4898 (file-name (git-file-name name version))
4899 (sha256
4900 (base32 "0jnc7nsn6n5hqx5wlk928b7xmg0mpfqy8al9w2p707ihcwh4s1rf"))))
4901 (build-system pyproject-build-system)
4902 (arguments
4903 (list
4904 #:test-flags '(list "-k"
4905 (string-append
4906 ;; These require internet access
4907 "not test_download_homologene"
4908 " and not test_complex_genes"))
4909 #:phases
4910 #~(modify-phases %standard-phases
4911 (add-after 'unpack 'set-home
4912 (lambda _
4913 (setenv "HOME" "/tmp"))))))
4914 (propagated-inputs (list python-attrs
4915 python-docrep
4916 python-inflect
4917 python-networkx
4918 python-packaging
4919 python-pandas
4920 python-requests
4921 python-tqdm
4922 python-typing-extensions
4923 python-urllib3
4924 python-wrapt))
4925 (native-inputs (list nss-certs-for-test
4926 python-bump2version
4927 python-hatchling
4928 python-pytest
4929 python-pytest-mock
4930 python-pytest-socket
4931 python-requests-mock))
4932 (home-page "https://omnipathdb.org/")
4933 (synopsis "Python client for the OmniPath web service")
4934 (description "This package provides a Python client for the OmniPath web
4935service.")
4936 (license license:expat)))
4937
4938(define-public python-openai
4939 (package
4940 (name "python-openai")
4941 (version "1.3.5")
4942 (source (origin
4943 (method git-fetch)
4944 (uri (git-reference
4945 (url "https://github.com/openai/openai-python")
4946 (commit (string-append "v" version))))
4947 (file-name (git-file-name name version))
4948 (sha256
4949 (base32
4950 "0k1rwhj7v22x5bnv9xbk9nj9grxqmmclh9538qqjadgqxfn5x74q"))))
4951 (build-system pyproject-build-system)
4952 (arguments
4953 (list
4954 #:test-flags
4955 ;; These require internet access and an openai API key.
4956 '(list "--ignore=openai/tests/asyncio/test_endpoints.py"
4957 "--ignore=openai/tests/test_endpoints.py"
4958 "--ignore-glob=tests/api_resources/*"
4959 ;; Needs respx
4960 "--ignore=tests/api_resources/audio/test_speech.py"
4961 "--ignore=tests/api_resources/test_files.py"
4962 "--ignore=tests/test_client.py"
4963 "-k" "not test_requestor_cycle_sessions\
4964 and not test_requestor_sets_request_id\
4965 and not test_file_cli\
4966 and not test_basic_async\
4967 and not test_async\
4968 and not test_datetime_with_alias\
4969 and not test_pydantic")
4970 #:phases
4971 '(modify-phases %standard-phases
4972 (add-after 'unpack 'relax-requirements
4973 (lambda _
4974 (substitute* "pyproject.toml"
4975 (("distro>=1.7.0") "distro>=1.6.0")
4976 (("anyio>=3.5.0, <4") "anyio"))))
4977 (add-after 'unpack 'httpx-compatibility
4978 (lambda _
4979 (substitute* "src/openai/_base_client.py"
4980 (("proxies=proxies,") "")
4981 (("self._proxies = proxies") "")
4982 (("proxies: ProxiesTypes . None,") "")))))))
4983 (propagated-inputs
4984 (list python-aiohttp
4985 python-distro
4986 python-httpx
4987 python-pydantic
4988 python-requests
4989 python-tqdm
4990 python-typing-extensions))
4991 (native-inputs (list nss-certs-for-test
4992 python-dirty-equals
4993 python-hatchling
4994 python-pytest python-pytest-asyncio
4995 python-pytest-mock python-setuptools python-wheel))
4996 (home-page "https://github.com/openai/openai-python")
4997 (synopsis "Python client library for the OpenAI API")
4998 (description "This package provides a Python client library for the
4999OpenAI API.")
5000 (license license:expat)))
5001
5002(define-public python-openapi-schema-validator
5003 (package
5004 (name "python-openapi-schema-validator")
5005 (version "0.6.2")
5006 (source
5007 (origin
5008 (method git-fetch) ;no tests in pypi release
5009 (uri (git-reference
5010 (url "https://github.com/p1c2u/openapi-schema-validator")
5011 (commit version)))
5012 (file-name (git-file-name name version))
5013 (sha256
5014 (base32
5015 "0pgsm1x7lhc5ryj4l45ik8m5x9gqyi50dkflaiqqr4fnl0bsbx09"))))
5016 (build-system pyproject-build-system)
5017 (arguments
5018 (list
5019 #:test-flags
5020 ;; This one returns 5 instead of 4 elements
5021 '(list "-k" "not test_array_prefixitems_invalid")
5022 #:phases
5023 #~(modify-phases %standard-phases
5024 (add-after 'unpack 'remove-coverage-pytest-options
5025 (lambda _
5026 (substitute* "pyproject.toml"
5027 (("^--cov.*") ""))))
5028 ;; See https://github.com/python-openapi/openapi-schema-validator/issues/204
5029 (add-after 'unpack 'relax-requirements
5030 (lambda _
5031 (substitute* "pyproject.toml"
5032 (("jsonschema-specifications.*")
5033 "jsonschema-specifications = \">=2023.5.2\"\n")))))))
5034 (native-inputs (list python-poetry-core python-pytest))
5035 (propagated-inputs
5036 (list python-isodate
5037 python-jsonschema
5038 python-rfc3339-validator
5039 python-strict-rfc3339))
5040 (home-page "https://github.com/p1c2u/openapi-schema-validator")
5041 (synopsis "OpenAPI schema validation library for Python")
5042 (description "Openapi-schema-validator is a Python library that validates
5043a schema against:
5044@itemize
5045@item OpenAPI Schema Specification v3.0 which is an extended subset of the
5046JSON Schema Specification Wright Draft 00.
5047@item OpenAPI Schema Specification v3.1 which is an extended superset of the
5048JSON Schema Specification Draft 2020-12.
5049@end itemize")
5050 (license license:bsd-3)))
5051
5052(define-public python-openapi-spec-validator
5053 (package
5054 (name "python-openapi-spec-validator")
5055 (version "0.7.1")
5056 (source
5057 (origin
5058 (method git-fetch) ;no tests in pypi release
5059 (uri (git-reference
5060 (url "https://github.com/p1c2u/openapi-spec-validator")
5061 (commit version)))
5062 (file-name (git-file-name name version))
5063 (sha256
5064 (base32
5065 "0s5yd4dbr6knwd2g1g4v2931k14n1lm80l11n2ija18yfis8yisz"))))
5066 (build-system pyproject-build-system)
5067 (arguments
5068 (list
5069 ;; These tests attempt to fetch resources from the Internet
5070 #:test-flags '(list "--ignore-glob=tests/integration/validation/**"
5071 "-k" "not example")
5072 #:phases
5073 #~(modify-phases %standard-phases
5074 (add-after 'unpack 'remove-coverage-pytest-options
5075 (lambda _
5076 (substitute* "pyproject.toml"
5077 (("^--cov.*") "")))))))
5078 (native-inputs
5079 (list python-poetry-core
5080 python-pytest))
5081 (propagated-inputs
5082 (list python-jsonschema
5083 python-jsonschema-path
5084 python-lazy-object-proxy
5085 python-openapi-schema-validator
5086 python-pyyaml
5087 python-requests
5088 python-setuptools))
5089 (home-page "https://github.com/p1c2u/openapi-spec-validator")
5090 (synopsis "OpenAPI spec validator")
5091 (description "OpenAPI Spec Validator is a Python library that validates an
5092OpenAPI specification against the OpenAPI 2.0 (also known as Swagger), OpenAPI
50933.0 and OpenAPI 3.1 specifications. The validator aims to check for full
5094compliance with the specification.")
5095 (license license:asl2.0)))
5096
5097(define-public python-openapi-core
5098 (package
5099 (name "python-openapi-core")
5100 (version "0.19.4")
5101 (source
5102 (origin
5103 (method git-fetch)
5104 (uri (git-reference
5105 (url "https://github.com/p1c2u/openapi-core")
5106 (commit version)))
5107 (file-name (git-file-name name version))
5108 (sha256
5109 (base32
5110 "092sj2933jmvq5r76khr0vphih490vls1ga3s43gz8i47aqaxx96"))))
5111 (build-system pyproject-build-system)
5112 (arguments
5113 (list
5114 #:test-flags
5115 '(list "tests/unit"
5116 ;; Ignore Pytest configuration in setup.cfg that adds
5117 ;; unwanted flake8 and coverage options.
5118 "-c" "/dev/null"
5119 "-k" "not test_chars_valid")))
5120 (native-inputs (list python-django
5121 python-falcon
5122 python-flask
5123 python-mock
5124 python-poetry-core
5125 python-pytest
5126 python-responses))
5127 (propagated-inputs
5128 (list python-attrs
5129 python-aiohttp
5130 python-isodate
5131 python-jsonschema
5132 python-lazy-object-proxy
5133 python-more-itertools
5134 python-openapi-schema-validator
5135 python-openapi-spec-validator
5136 python-parse
5137 python-six
5138 python-werkzeug))
5139 (home-page "https://github.com/p1c2u/openapi-core")
5140 (synopsis "OpenAPI core library")
5141 (description "Openapi-core is a Python library that adds client-side and
5142server-side support for the OpenAPI Specification v3. It has features such
5143as:
5144@itemize
5145@item Validation of requests and responses
5146@item Schema casting and unmarshalling
5147@item Media type and parameters deserialization
5148@item Security providers (API keys, Cookie, Basic and Bearer HTTP
5149authentications)
5150@item Custom deserializers and formats
5151@item Integration with libraries and frameworks.
5152@end itemize")
5153 (license license:bsd-3)))
5154
5155(define-public python-openid
5156 (package
5157 (name "python-openid")
5158 (version "3.2.0")
5159 (source
5160 (origin
5161 (method url-fetch)
5162 (uri (pypi-uri "python3-openid" version))
5163 (sha256
5164 (base32
5165 "1bxf9a3ny1js422j962zfzl4a9dhj192pvai05whn7j0iy9gdyrk"))))
5166 (build-system pyproject-build-system)
5167 (arguments
5168 `(#:phases
5169 (modify-phases %standard-phases
5170 (replace 'check
5171 (lambda* (#:key tests? #:allow-other-keys)
5172 (when tests?
5173 (invoke "python" "-m" "unittest" "openid.test.test_suite")))))))
5174 (propagated-inputs
5175 (list python-defusedxml))
5176 (native-inputs
5177 (list python-psycopg2 python-django python-setuptools python-wheel))
5178 (home-page "https://github.com/necaris/python3-openid")
5179 (synopsis "OpenID support for servers and consumers")
5180 (description "This library provides OpenID authentication for Python, both
5181for clients and servers.")
5182 (license license:asl2.0)))
5183
5184(define-public python-cssutils
5185 (package
5186 (name "python-cssutils")
5187 (version "2.11.1")
5188 (source
5189 (origin
5190 (method url-fetch)
5191 (uri (pypi-uri "cssutils" version))
5192 (sha256
5193 (base32
5194 "1qpq7xvzqp4cfcb8837rnd30x4hws3rkp33qpvmnxbxn2djsfqq5"))))
5195 (build-system pyproject-build-system)
5196 (arguments
5197 (list
5198 #:phases
5199 #~(modify-phases %standard-phases
5200 (replace 'check
5201 (lambda _
5202 (invoke "pytest" "-vv" "-k"
5203 (string-append "not encutils "
5204 "and not website.logging")))))))
5205 (native-inputs
5206 (list python-cssselect
5207 python-jaraco-test
5208 python-lxml
5209 python-pytest
5210 python-setuptools
5211 python-wheel))
5212 (propagated-inputs
5213 (list python-more-itertools))
5214 (home-page "https://github.com/jaraco/cssutils")
5215 (synopsis
5216 "CSS Cascading Style Sheets library for Python")
5217 (description
5218 "Cssutils is a Python package for parsing and building CSS
5219Cascading Style Sheets. Currently it provides a DOM only and no rendering
5220options.")
5221 (license license:lgpl3+)))
5222
5223(define-public python-css-parser
5224 (package
5225 (inherit python-cssutils)
5226 (name "python-css-parser")
5227 (version "1.0.10")
5228 (source
5229 (origin
5230 (method url-fetch)
5231 (uri (pypi-uri "css-parser" version))
5232 (sha256
5233 (base32 "0qs375slcwqd7slizh6hzkwxx7cdj36v8kwn0qrfji1kscm9f7mz"))))
5234 (home-page "https://github.com/ebook-utils/css-parser")
5235 (synopsis "Fork of cssutils modified for parsing ebooks")
5236 (description
5237 "Css-parser is a Python package for parsing and building CSS
5238Cascading Style Sheets. Currently it provides a DOM only and no rendering
5239options.
5240
5241It's a fork of cssutils 1.0.2, updated and modified for parsing ebooks, due to
5242cssutils not receiving updates as of 1.0.2.")
5243 (license license:lgpl3+)))
5244
5245(define-public python-cssselect
5246 (package
5247 (name "python-cssselect")
5248 (version "1.2.0")
5249 (source (origin
5250 ;; The PyPI release does not contain tests.
5251 (method git-fetch)
5252 (uri (git-reference
5253 (url "https://github.com/scrapy/cssselect")
5254 (commit (string-append "v" version))))
5255 (file-name (git-file-name name version))
5256 (sha256
5257 (base32
5258 "1x4nrvb1p1byi1whmspik7lbh303akdlh762dayfxam3hycsh5kk"))))
5259 (build-system pyproject-build-system)
5260 (native-inputs
5261 (list python-lxml python-pytest python-setuptools python-wheel))
5262 (home-page "https://github.com/scrapy/cssselect")
5263 (synopsis "CSS3 selector parser and translator to XPath 1.0")
5264 (description
5265 "Cssselect ia a Python module that parses CSS3 Selectors and translates
5266them to XPath 1.0 expressions. Such expressions can be used in lxml or
5267another XPath engine to find the matching elements in an XML or HTML document.")
5268 (license license:bsd-3)))
5269
5270(define-public python-databricks-cli
5271 (package
5272 (name "python-databricks-cli")
5273 (version "0.18.0")
5274 (home-page "https://github.com/databricks/databricks-cli")
5275 (source (origin
5276 (method git-fetch)
5277 (uri (git-reference (url home-page) (commit version)))
5278 (file-name (git-file-name name version))
5279 (sha256
5280 (base32
5281 "1avag4kwqk2f24r5i0vcmhm6s1gsw6maykhlyj2ixz0qc05pjzvl"))))
5282 (build-system pyproject-build-system)
5283 (arguments
5284 (list #:phases #~(modify-phases %standard-phases
5285 (replace 'check
5286 (lambda _
5287 (invoke "pytest" "tests" "-vv"))))))
5288 (native-inputs
5289 ;; For tests.
5290 (list python-decorator
5291 python-mock
5292 python-pytest
5293 python-requests-mock
5294 python-setuptools
5295 python-wheel))
5296 (propagated-inputs
5297 (list python-click
5298 python-oauthlib
5299 python-pyjwt
5300 python-requests
5301 python-six
5302 python-tabulate))
5303 (synopsis "Command line interface for Databricks")
5304 (description
5305 "The Databricks Command Line Interface is a tool which provides an easy
5306to use interface to the Databricks platform. The CLI is built on top of the
5307Databricks REST APIs.")
5308 (license license:asl2.0)))
5309
5310(define-public python-openid-cla
5311 ;; XXX: Last updated in 2015.
5312 (package
5313 (name "python-openid-cla")
5314 (version "1.2")
5315 (source
5316 (origin
5317 (method url-fetch)
5318 (uri (pypi-uri "python-openid-cla" version))
5319 (sha256
5320 (base32
5321 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
5322 (build-system pyproject-build-system)
5323 (arguments '(#:tests? #f)) ; No tests.
5324 (native-inputs (list python-setuptools python-wheel))
5325 (propagated-inputs (list python-openid python-six))
5326 (home-page "https://github.com/puiterwijk/python-openid-cla/")
5327 (synopsis "Implementation of the OpenID CLA extension for python-openid")
5328 (description "@code{openid-cla} is an implementation of the OpenID
5329contributor license agreement extension for python-openid.")
5330 (license license:bsd-3)))
5331
5332(define-public python-openid-teams
5333 ;; XXX: Last updated in 2018.
5334 (package
5335 (name "python-openid-teams")
5336 (version "1.1")
5337 (source
5338 (origin
5339 (method url-fetch)
5340 (uri (pypi-uri "python-openid-teams" version))
5341 (sha256
5342 (base32
5343 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
5344 (build-system pyproject-build-system)
5345 (arguments '(#:tests? #f)) ; No tests.
5346 (native-inputs (list python-setuptools python-wheel))
5347 (propagated-inputs (list python-openid python-six))
5348 (home-page "https://github.com/puiterwijk/python-openid-teams/")
5349 (synopsis "Implementation of the OpenID teams extension for python-openid")
5350 (description
5351 "@code{openid-teams} is an implementation of the OpenID
5352teams extension for python-openid.")
5353 (license license:bsd-3)))
5354
5355(define-public python-priority
5356 (package
5357 (name "python-priority")
5358 (version "2.0.0")
5359 (source
5360 (origin
5361 (method url-fetch)
5362 (uri (pypi-uri "priority" version))
5363 (sha256
5364 (base32 "1h0qpa949bxx7za95v1apwnngkrngi695cwx8wchn3cd3d7xarf9"))))
5365 (build-system pyproject-build-system)
5366 (native-inputs
5367 (list python-pytest python-setuptools python-wheel))
5368 (home-page "https://python-hyper.org/projects/priority/en/latest/")
5369 (synopsis "Pure-Python implementation of the HTTP/2 priority tree")
5370 (description
5371 "Priority is a pure-Python implementation of the priority logic for HTTP/2,
5372set out in RFC 7540 Section 5.3 (Stream Priority).")
5373 (license license:expat)))
5374
5375(define-public python-weblate-language-data
5376 (package
5377 (name "python-weblate-language-data")
5378 (version "2025.8")
5379 (source
5380 (origin
5381 (method url-fetch)
5382 (uri (pypi-uri "weblate_language_data" version))
5383 (sha256
5384 (base32 "0byj1xl6xldam790b6wg62dk1b4i6qdlsp4lqzlv65wnp2klvrkf"))))
5385 (build-system pyproject-build-system)
5386 (arguments (list #:tests? #f)) ;not tests, just data files
5387 (native-inputs
5388 (list python-setuptools))
5389 (propagated-inputs
5390 (list python-translate-toolkit))
5391 (home-page "https://github.com/WeblateOrg/language-data")
5392 (synopsis "Language definitions for Weblate")
5393 (description
5394 "This package provides language definitions used by
5395@url{https://weblate.org/, Weblate}i.")
5396 (license license:expat)))
5397
5398(define-public python-wikidata
5399 (package
5400 (name "python-wikidata")
5401 (version "0.8.1")
5402 (source
5403 (origin
5404 (method git-fetch)
5405 (uri (git-reference
5406 (url "https://github.com/dahlia/wikidata")
5407 (commit version)))
5408 (file-name (git-file-name name version))
5409 (sha256
5410 (base32 "06zg74h249phszn1znfcjdz6c3lz350fiabdzn7iqb2xg4xh69a5"))))
5411 (build-system pyproject-build-system)
5412 (native-inputs
5413 (list python-pytest python-setuptools))
5414 (home-page "https://github.com/dahlia/wikidata")
5415 (synopsis "Wikidata client library")
5416 (description
5417 "This package provides a Python interface to @url{https://www.wikidata.org/,
5418Wikidata}.")
5419 (license license:gpl3+)))
5420
5421(define-public python-wsproto
5422 (package
5423 (name "python-wsproto")
5424 (version "1.2.0")
5425 (source
5426 (origin
5427 (method url-fetch)
5428 (uri (pypi-uri "wsproto" version))
5429 (sha256
5430 (base32 "0rahm1j9danv1l6i6as80acwv16ycihxkhrvwjiqh9drxhk5ymmd"))))
5431 (build-system pyproject-build-system)
5432 (native-inputs
5433 (list python-pytest python-setuptools python-wheel))
5434 (propagated-inputs
5435 (list python-h11))
5436 (home-page "https://github.com/python-hyper/wsproto/")
5437 (synopsis "WebSockets state-machine based protocol implementation")
5438 (description
5439 "@code{wsproto} is a pure-Python implementation of a WebSocket protocol
5440stack. It's written from the ground up to be embeddable in whatever program you
5441choose to use, ensuring that you can communicate via WebSockets, as defined in
5442RFC6455, regardless of your programming paradigm.")
5443 (license license:expat)))
5444
5445(define-public hypercorn
5446 (package
5447 (name "hypercorn")
5448 (version "0.18.0")
5449 (source
5450 (origin
5451 (method git-fetch) ;PyPI does not have tests
5452 (uri (git-reference
5453 (url "https://github.com/pgjones/hypercorn")
5454 (commit version)))
5455 (file-name (git-file-name name version))
5456 (sha256
5457 (base32 "0jdi05n5isxn0rysq242p198lz03gbwsnizzb9yp6rxr7ajapns4"))))
5458 (build-system pyproject-build-system)
5459 ;; Propagate because Hypercorn also exposes functionality over a module.
5460 (propagated-inputs (list python-h11
5461 python-h2
5462 python-priority
5463 python-tomli
5464 python-wsproto))
5465 (native-inputs (list nss-certs-for-test
5466 python-httpx
5467 python-pdm-backend
5468 python-poetry-core
5469 python-pytest
5470 python-pytest-asyncio
5471 python-pytest-cov
5472 python-pytest-trio
5473 python-trio))
5474 (home-page "https://gitlab.com/pgjones/hypercorn/")
5475 (synopsis "ASGI Server based on Hyper libraries")
5476 (description
5477 "Hypercorn is an ASGI web server based on the sans-io hyper, h11, h2, and
5478wsproto libraries and inspired by Gunicorn. It supports HTTP/1, HTTP/2,
5479WebSockets (over HTTP/1 and HTTP/2), ASGI/2, and ASGI/3 specifications. It
5480can utilise asyncio, uvloop, or trio worker types.")
5481 (license license:expat)))
5482
5483(define-public python-querystring-parser
5484 (package
5485 (name "python-querystring-parser")
5486 (version "1.2.4")
5487 (source
5488 (origin
5489 (method git-fetch)
5490 (uri (git-reference
5491 (url "https://github.com/bernii/querystring-parser")
5492 (commit version)))
5493 (file-name (git-file-name name version))
5494 (sha256
5495 (base32 "15n89bf1x9dgp1vi697pa238nvn0vbqp3ghf0xrcyqqa9gn1l6fb"))))
5496 (build-system pyproject-build-system)
5497 (arguments
5498 (list
5499 #:phases
5500 #~(modify-phases %standard-phases
5501 (replace 'check
5502 (lambda _
5503 ;; XXX FIXME: This test is broken with Python 3.7:
5504 ;; https://github.com/bernii/querystring-parser/issues/35
5505 (substitute* "querystring_parser/tests.py"
5506 (("self\\.assertEqual\\(self\\.knownValuesNormalized, result\\)")
5507 "True"))
5508 (invoke "python" "querystring_parser/tests.py"))))))
5509 (native-inputs (list python-setuptools))
5510 (propagated-inputs (list python-six))
5511 (home-page "https://github.com/bernii/querystring-parser")
5512 (synopsis "QueryString parser that correctly handles nested dictionaries")
5513 (description
5514 "This package provides a query string parser for Python and Django
5515projects that correctly creates nested dictionaries from sent form/querystring
5516data.")
5517 (license license:expat)))
5518
5519(define-public python-tornado
5520 (package
5521 (name "python-tornado")
5522 (version "6.4.2")
5523 (source
5524 (origin
5525 (method url-fetch)
5526 (uri (pypi-uri "tornado" version))
5527 (sha256
5528 (base32 "02v2mlvr58xg0l0gh08nswl53z73wkf23sziggypk63ffjsdbflj"))))
5529 (build-system pyproject-build-system)
5530 (arguments
5531 (list
5532 #:test-flags
5533 ;; AttributeError: 'TestIOStreamWebMixin' object has no attribute 'io_loop'
5534 #~(list "--ignore=tornado/test/iostream_test.py")))
5535 (native-inputs
5536 (list python-certifi
5537 python-pytest
5538 python-setuptools))
5539 (home-page "https://www.tornadoweb.org/")
5540 (synopsis "Python web framework and asynchronous networking library")
5541 (description
5542 "Tornado is a Python web framework and asynchronous networking library,
5543originally developed at FriendFeed. By using non-blocking network I/O,
5544Tornado can scale to tens of thousands of open connections, making it ideal
5545for long polling, WebSockets, and other applications that require a long-lived
5546connection to each user.")
5547 (license license:asl2.0)))
5548
5549(define-public python-tornado-5
5550 (package
5551 (inherit python-tornado)
5552 (version "5.1.1")
5553 (source
5554 (origin
5555 (method url-fetch)
5556 (uri (pypi-uri "tornado" version))
5557 (sha256
5558 (base32
5559 "02clqk2116jbnq8lnaqmdw3p52nqrd9ib59r4xz2ll43fpcmhlaf"))))
5560 (build-system pyproject-build-system)
5561 (arguments
5562 (list
5563 #:phases
5564 '(modify-phases %standard-phases
5565 (add-after 'unpack 'fix-collections
5566 (lambda _
5567 (substitute* "tornado/httputil.py"
5568 (("collections.MutableMapping")
5569 "collections.abc.MutableMapping"))))
5570 (replace 'check
5571 (lambda* (#:key tests? #:allow-other-keys)
5572 (when tests?
5573 (substitute* "tornado/test/runtests.py"
5574 (("\"error\", category=DeprecationWarning")
5575 "\"ignore\", category=DeprecationWarning")
5576 ;; Disable tests that use SSL.
5577 (("'tornado.test.simple_httpclient_test',") "")
5578 (("'tornado.test.iostream_test',") "")
5579 (("'tornado.test.httpserver_test',") "")
5580 ;; Some timeouts are triggered in these two modules
5581 (("'tornado.test.queues_test',") "")
5582 (("'tornado.test.locks_test',") ""))
5583 ;; Skip all network tests
5584 (setenv "NO_NETWORK" "1")
5585 ;; Skip timing-relevant tests
5586 (setenv "TRAVIS" "1")
5587 (invoke "python" "-m" "tornado.test.runtests"
5588 "--verbose=yes")))))))
5589 (native-inputs
5590 (list python-certifi
5591 python-setuptools))))
5592
5593;; XXX: Deprecated on <2026-01-23>.
5594(define-deprecated-package python-tornado-6 python-tornado)
5595
5596(define-public python-tornado-http-auth
5597 (package
5598 (name "python-tornado-http-auth")
5599 (version "1.1.1")
5600 (source
5601 (origin
5602 (method git-fetch)
5603 (uri (git-reference
5604 (url "https://github.com/gvalkov/tornado-http-auth")
5605 (commit (string-append "v" version))))
5606 (file-name (git-file-name name version))
5607 (sha256
5608 (base32 "1v9sin1zlck9wvkwx0ldqb1b271xlkq63562w8g1yb7v6qka9q4f"))))
5609 (build-system pyproject-build-system)
5610 ;; XXX: This version is incompatible with current tornado.testing.
5611 (arguments (list #:tests? #f))
5612 (native-inputs (list python-setuptools))
5613 (propagated-inputs (list python-tornado))
5614 (home-page "https://github.com/gvalkov/tornado-http-auth")
5615 (synopsis "Digest and basic authentication module for Tornado")
5616 (description
5617 "Provides support for adding authentication to services using the Tornado
5618web framework, either via the basic or digest authentication schemes.")
5619 (license license:asl2.0)))
5620
5621(define-public python-wsgi-intercept
5622 (package
5623 (name "python-wsgi-intercept")
5624 (version "1.13.1")
5625 (source (origin
5626 (method url-fetch)
5627 (uri (pypi-uri "wsgi_intercept" version))
5628 (sha256
5629 (base32
5630 "1h94dj7h7n7zdj3ll4imqjhq5vk21yidk2niwnmpw7xik9inrgbr"))))
5631 (build-system pyproject-build-system)
5632 (arguments
5633 (list
5634 ;; XXX: tests required internet access
5635 #:tests? #f))
5636 (propagated-inputs
5637 (list python-six))
5638 (native-inputs
5639 (list python-httplib2
5640 python-pytest
5641 python-requests
5642 python-setuptools
5643 python-urllib3
5644 python-wheel))
5645 (synopsis "Puts a WSGI application in place of a real URI for testing")
5646 (description "Wsgi_intercept installs a WSGI application in place of a real
5647URI for testing. Testing a WSGI application normally involves starting a
5648server at a local host and port, then pointing your test code to that address.
5649Instead, this library lets you intercept calls to any specific host/port
5650combination and redirect them into a WSGI application importable by your test
5651program. Thus, you can avoid spawning multiple processes or threads to test
5652your Web app.")
5653 (home-page "https://github.com/cdent/wsgi-intercept")
5654 (license license:expat)))
5655
5656(define-public python-webob
5657 (package
5658 (name "python-webob")
5659 (version "1.8.9")
5660 (source
5661 (origin
5662 (method url-fetch)
5663 (uri (pypi-uri "webob" version))
5664 (sha256
5665 (base32
5666 "12b5sl10yzzzz3g11kij3rdzk9y6583ywggc6h9nsxmnxpi7hq5d"))))
5667 (build-system pyproject-build-system)
5668 ;; tests: 2380 passed, 9 skipped, 1 xfailed, 12 warnings
5669 (native-inputs
5670 (list python-pytest
5671 python-setuptools))
5672 (home-page "https://webob.org/")
5673 (synopsis "WSGI request and response object")
5674 (description
5675 "WebOb provides wrappers around the WSGI request environment, and an
5676object to help create WSGI responses.")
5677 (license license:expat)))
5678
5679(define-public python-zc-lockfile
5680 (package
5681 (name "python-zc-lockfile")
5682 (version "4.0")
5683 (source
5684 (origin
5685 (method git-fetch)
5686 (uri (git-reference
5687 (url "https://github.com/zopefoundation/zc.lockfile")
5688 (commit version)))
5689 (file-name (git-file-name name version))
5690 (sha256
5691 (base32 "0b1kkwx2d4wf392sd3bfjvzgkdrknwsxg9mby121mq8zl7c490gg"))))
5692 (build-system pyproject-build-system)
5693 (arguments
5694 (list
5695 #:phases
5696 #~(modify-phases %standard-phases
5697 (replace 'check
5698 (lambda* (#:key tests? #:allow-other-keys)
5699 (if tests?
5700 (invoke "zope-testrunner" "--test-path=src")
5701 (format #t "test suite not run~%")))))))
5702 (native-inputs (list python-zope-testing python-zope-testrunner
5703 python-setuptools))
5704 (home-page "https://github.com/zopefoundation/zc.lockfile")
5705 (synopsis "Interprocess locks using lock files")
5706 (description
5707 "This package provides an implementation of interprocess locks using lock
5708files. These locks can also be used to mediate access to other files.")
5709 (license license:zpl2.1)))
5710
5711(define-public python-zconfig
5712 (package
5713 (name "python-zconfig")
5714 (version "4.0")
5715 (source
5716 (origin
5717 (method git-fetch)
5718 (uri (git-reference
5719 (url "https://github.com/zopefoundation/ZConfig/")
5720 (commit version)))
5721 (file-name (git-file-name name version))
5722 (sha256
5723 (base32 "1x502hyfijh6fc8n85cm046c44spwfmwcn2lnxa1axg8n0n5rsbp"))))
5724 (build-system pyproject-build-system)
5725 (arguments
5726 (list
5727 #:phases
5728 #~(modify-phases %standard-phases
5729 (replace 'check
5730 (lambda* (#:key tests? #:allow-other-keys)
5731 (if tests?
5732 (begin
5733 ;; This test assumes we still have setup.py in the
5734 ;; directory from which we import zconfig, which
5735 ;; does not work after installing the package.
5736 (delete-file-recursively
5737 "src/ZConfig/tests/test_readme.py")
5738 (invoke "zope-testrunner" "-vv" "--test-path=src" "--all"))
5739 (format #t "test suite not run~%")))))))
5740 (native-inputs (list python-docutils python-manuel python-zope-exceptions
5741 python-zope-testrunner python-setuptools))
5742 (home-page "https://github.com/zopefoundation/ZConfig/")
5743 (synopsis "Structured configuration library intended for general use")
5744 (description
5745 "@code{zconfig} is a configuration library intended for general use. It
5746supports a hierarchical schema-driven configuration model that allows a schema
5747to specify data conversion routines written in Python. Its model is very
5748different from the model supported by the @code{configparser} module found in
5749Python's standard library, and is more suitable to configuration-intensive
5750applications.")
5751 (license license:zpl2.1)))
5752
5753(define-public python-zodb
5754 (package
5755 (name "python-zodb")
5756 (version "6.0.1")
5757 (source
5758 (origin
5759 (method url-fetch)
5760 (uri (pypi-uri "zodb" version))
5761 (sha256
5762 (base32 "02cmvf8j2nin5z26wvy2vq2k9mj12hqrr4276lj3w4jj32p0zxw9"))))
5763 (build-system pyproject-build-system)
5764 (arguments
5765 (list
5766 #:phases
5767 #~(modify-phases %standard-phases
5768 (replace 'check
5769 (lambda* (#:key tests? #:allow-other-keys)
5770 (if tests?
5771 (begin
5772 ;; This test does not work after installing the
5773 ;; package, since it expects the ZODB source code
5774 ;; to reside in the src/ directory.
5775 (delete-file-recursively
5776 "src/ZODB/tests/testdocumentation.py")
5777 (invoke "zope-testrunner" "-vv" "--test-path=src"
5778 "--all"))
5779 (format #t "test suite not run~%")))))))
5780 (native-inputs
5781 (list python-manuel
5782 python-wheel
5783 python-zope-testing
5784 python-zope-testrunner))
5785 (propagated-inputs
5786 (list python-btrees
5787 python-persistent
5788 python-transaction
5789 python-zc-lockfile
5790 python-zconfig
5791 python-zodbpickle
5792 python-zope-interface))
5793 (home-page "http://zodb-docs.readthedocs.io")
5794 (synopsis "Object-oriented database for Python")
5795 (description
5796 "@code{ZODB} provides an object-oriented and @acronym{ACID,
5797Atomicity Consistency Isolation Durability} compliant database for Python with
5798a high degree of transparency. @code{ZODB} is an object-oriented database,
5799not an object-relational mapping. This comes with several advantaged:
5800
5801@itemize
5802@item no separate language for database operations
5803@item very little impact on your code to make objects persistent
5804@item no database mapper that partially hides the database.
5805@item almost no seam between code and database.
5806@end itemize")
5807 (license license:zpl2.1)))
5808
5809(define-public python-zodbpickle
5810 (package
5811 (name "python-zodbpickle")
5812 (version "3.2")
5813 (source
5814 (origin
5815 (method url-fetch)
5816 (uri (pypi-uri "zodbpickle" version))
5817 (sha256
5818 (base32 "035bjrksl4h92mvjkx6id4gjcpc1k4mbci8ryjl6l9mki7ihx77b"))))
5819 (build-system pyproject-build-system)
5820 (arguments
5821 '(#:phases (modify-phases %standard-phases
5822 (replace 'check
5823 (lambda* (#:key tests? #:allow-other-keys)
5824 (if tests?
5825 (invoke "zope-testrunner" "-vv" "--test-path=src"
5826 "--all")
5827 (format #t "test suite not run~%")))))))
5828 (native-inputs (list python-zope-testrunner python-setuptools python-wheel))
5829 (home-page "https://github.com/zopefoundation/zodbpickle")
5830 (synopsis "Uniform pickling interface for @code{zodb}")
5831 (description
5832 "This package is a fork of the @code{pickle} module (and the
5833supporting C extension) from both Python 3.2 and Python 3.3. The fork adds
5834support for the @code{noload} operations used by @code{zodb}.")
5835 (license (list license:psfl license:zpl2.1))))
5836
5837(define-public python-zope-dottedname
5838 (package
5839 (name "python-zope-dottedname")
5840 (version "7.0")
5841 (source
5842 (origin
5843 (method git-fetch)
5844 (uri (git-reference
5845 (url "https://github.com/zopefoundation/zope.dottedname")
5846 (commit version)))
5847 (file-name (git-file-name name version))
5848 (sha256
5849 (base32 "0h7a637zsl1a3f0rpb2nw41mzxv0pqyj8ahn6h60n2c1px912rbd"))))
5850 (build-system pyproject-build-system)
5851 (arguments
5852 (list #:test-backend #~'custom
5853 #:test-flags #~(list "src/zope/dottedname/tests.py")))
5854 (native-inputs (list python-setuptools))
5855 (home-page "https://zopedottedname.readthedocs.io")
5856 (synopsis "Resolver for Python dotted names")
5857 (description
5858 "This package provides a @code{resolve()} function that resolves strings
5859containing dotted names into the appropriate Python object.")
5860 (license license:zpl2.1)))
5861
5862(define-public python-zope-event
5863 (package
5864 (name "python-zope-event")
5865 (version "6.0")
5866 (source
5867 (origin
5868 (method git-fetch)
5869 (uri (git-reference
5870 (url "https://github.com/zopefoundation/zope.event")
5871 (commit version)))
5872 (file-name (git-file-name name version))
5873 (sha256
5874 (base32 "0la3q47c59aq50s036q468bhnmzgs71f1cygv89w6qkk1hkn35ym"))))
5875 (build-system pyproject-build-system)
5876 (arguments
5877 (list
5878 #:test-flags
5879 #~(list "src/zope/event/tests.py")))
5880 (native-inputs (list python-pytest python-setuptools))
5881 (home-page "https://zopeevent.readthedocs.io/en/latest/")
5882 (synopsis "Event publishing system for Python")
5883 (description
5884 "Zope.event provides an event publishing API, intended for use by
5885applications which are unaware of any subscribers to their events. It is a
5886simple event-dispatching system on which more sophisticated event dispatching
5887systems can be built.")
5888 (license license:zpl2.1)))
5889
5890(define-public python-zope-interface
5891 (package
5892 (name "python-zope-interface")
5893 (version "7.2")
5894 (source
5895 (origin
5896 (method git-fetch)
5897 (uri (git-reference
5898 (url "https://github.com/zopefoundation/zope.interface")
5899 (commit version)))
5900 (file-name (git-file-name name version))
5901 (sha256
5902 (base32 "01snm1lbqhx3ird4m76nciaqasxvf8dd6817zm35v684g5hbzd2s"))))
5903 (build-system pyproject-build-system)
5904 (arguments
5905 ;; XXX: test suite can't find python-zope-testing
5906 (list #:tests? #f))
5907 (native-inputs (list python-setuptools))
5908 (home-page "https://zopeinterface.readthedocs.io")
5909 (synopsis "\"Design by contract\" methodology in Python")
5910 (description
5911 "Zope.interface provides an implementation of \"object interfaces\" for
5912Python. Interfaces are a mechanism for labeling objects as conforming to a
5913given API or contract.")
5914 (license license:zpl2.1)))
5915
5916(define-public python-zope-exceptions
5917 (package
5918 (name "python-zope-exceptions")
5919 (version "6.0")
5920 (source
5921 (origin
5922 (method git-fetch)
5923 (uri (git-reference
5924 (url "https://github.com/zopefoundation/zope.exceptions")
5925 (commit version)))
5926 (file-name (git-file-name name version))
5927 (sha256
5928 (base32 "0fmsw2j8islaiv6zf2mxh2s43y7virqny6s8gk8v2zkcxpy95cic"))))
5929 (build-system pyproject-build-system)
5930 (arguments
5931 (list
5932 #:phases
5933 #~(modify-phases %standard-phases
5934 (replace 'check
5935 (lambda* (#:key tests? #:allow-other-keys)
5936 (if tests?
5937 (invoke "zope-testrunner" "--test-path=src")
5938 (format #t "test suite not run~%")))))))
5939 (native-inputs (list python-setuptools python-zope-testrunner-bootstrap))
5940 (propagated-inputs (list python-zope-interface))
5941 (home-page "https://github.com/zopefoundation/zope.exceptions")
5942 (synopsis "Zope exceptions")
5943 (description
5944 "Zope.exceptions provides general-purpose exception types that have uses
5945outside of the Zope framework.")
5946 (license license:zpl2.1)))
5947
5948(define (python-zope-bootstrap-package orig)
5949 (package
5950 (inherit orig)
5951 (name (string-append (package-name orig) "-bootstrap"))
5952 (arguments
5953 (if (null? (package-arguments orig))
5954 (list
5955 #:tests? #f
5956 #:phases #~(modify-phases %standard-phases
5957 (delete 'sanity-check)))
5958 (substitute-keyword-arguments (package-arguments orig)
5959 ((#:tests? _ #f) #f)
5960 ((#:phases phases '%standard-phases)
5961 #~(modify-phases #$phases
5962 (delete 'sanity-check))))))
5963 (propagated-inputs `())
5964 (native-inputs (list python-setuptools))
5965 (properties `((hidden? . #t)))))
5966
5967(define-public python-zope-exceptions-bootstrap
5968 (python-zope-bootstrap-package python-zope-exceptions))
5969
5970(define-public python-zope-testing
5971 (package
5972 (name "python-zope-testing")
5973 (version "6.0")
5974 (source
5975 (origin
5976 (method git-fetch)
5977 (uri (git-reference
5978 (url "https://github.com/zopefoundation/zope.testing")
5979 (commit version)))
5980 (file-name (git-file-name name version))
5981 (sha256
5982 (base32 "0zqipsgv7qj7f8hrd3x6xpqwszdiac8vpjdm8ak5kljl5napw7d7"))))
5983 (build-system pyproject-build-system)
5984 (arguments
5985 (list
5986 #:phases
5987 #~(modify-phases %standard-phases
5988 (replace 'check
5989 (lambda* (#:key tests? #:allow-other-keys)
5990 (if tests?
5991 (invoke "zope-testrunner" "--test-path=src")
5992 (format #t "test suite not run~%")))))))
5993 (native-inputs (list python-setuptools
5994 python-zope-interface
5995 python-zope-testrunner-bootstrap))
5996 (home-page "https://zopetesting.readthedocs.io/")
5997 (synopsis "Zope testing helpers")
5998 (description
5999 "Zope.testing provides a number of testing utilities for HTML forms, HTTP
6000servers, regular expressions, and more.")
6001 (license license:zpl2.1)))
6002
6003(define-public python-zope-testrunner
6004 (package
6005 (name "python-zope-testrunner")
6006 (version "7.4")
6007 (source
6008 (origin
6009 (method git-fetch)
6010 (uri (git-reference
6011 (url "https://github.com/zopefoundation/zope.testrunner")
6012 (commit version)))
6013 (file-name (git-file-name name version))
6014 (sha256
6015 (base32 "0gd5rnzw6vzbx766jxqr4zc6qx7gk75r2c0nqqvhkb12hzk5ca2g"))))
6016 (build-system pyproject-build-system)
6017 (arguments
6018 (list
6019 #:phases
6020 #~(modify-phases %standard-phases
6021 (add-after 'unpack 'remove-problematic-test
6022 (lambda _
6023 ;; This test contains invalid syntax, which breaks bytecode
6024 ;; compilation. For simplicity just remove it.
6025 (delete-file
6026 "src/zope/testrunner/tests/testrunner-ex/sample2/badsyntax.py")))
6027 (replace 'check
6028 (lambda* (#:key tests? #:allow-other-keys)
6029 (if tests?
6030 (invoke "zope-testrunner" "--test-path=src")
6031 (format #t "test suite not run~%")))))))
6032 (native-inputs (list python-setuptools python-zope-testing))
6033 (propagated-inputs (list python-zope-exceptions python-zope-interface))
6034 (home-page "https://zopetestrunner.readthedocs.io")
6035 (synopsis "Zope testrunner script")
6036 (description "This package provides a script for running Python tests.")
6037 (license license:zpl2.1)))
6038
6039(define-public python-zope-testrunner-bootstrap
6040 (package
6041 (inherit (python-zope-bootstrap-package python-zope-testrunner))
6042 (propagated-inputs
6043 (list python-six python-zope-exceptions-bootstrap))
6044 (properties `((hidden? . #t)))))
6045
6046(define-public python-zope-i18nmessageid
6047 (package
6048 (name "python-zope-i18nmessageid")
6049 (version "7.0")
6050 (source
6051 (origin
6052 (method git-fetch)
6053 (uri (git-reference
6054 (url "https://github.com/zopefoundation/zope.i18nmessageid")
6055 (commit version)))
6056 (file-name (git-file-name name version))
6057 (sha256
6058 (base32 "192ixj8r9n467avbxrmhakmqiaflc1vw37k08z096ajcjgbfrm5d"))))
6059 (build-system pyproject-build-system)
6060 (arguments
6061 (list
6062 #:phases
6063 #~(modify-phases %standard-phases
6064 (replace 'check
6065 (lambda* (#:key tests? #:allow-other-keys)
6066 (if tests?
6067 (invoke "zope-testrunner" "--test-path=src")
6068 (format #t "test suite not run~%")))))))
6069 (native-inputs (list python-setuptools python-zope-testrunner))
6070 (home-page "https://zopei18nmessageid.readthedocs.io")
6071 (synopsis "Message identifiers for internationalization")
6072 (description "Zope.i18nmessageid provides facilities for declaring
6073internationalized messages within program source text.")
6074 (license license:zpl2.1)))
6075
6076(define-public python-zope-schema
6077 (package
6078 (name "python-zope-schema")
6079 (version "7.0.1")
6080 (source
6081 (origin
6082 (method git-fetch)
6083 (uri (git-reference
6084 (url "https://github.com/zopefoundation/zope.schema")
6085 (commit version)))
6086 (file-name (git-file-name name version))
6087 (sha256
6088 (base32 "1hj6j0gqgvv9a5pyaz54wbn8n7wf9lyg4njb2cfs980z0d5faj39"))))
6089 (build-system pyproject-build-system)
6090 (arguments
6091 (list
6092 #:phases
6093 #~(modify-phases %standard-phases
6094 (replace 'check
6095 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
6096 (add-installed-pythonpath inputs outputs)
6097 (if tests?
6098 (invoke "zope-testrunner" "--test-path=src")
6099 (format #t "test suite not run.~%")))))))
6100 (propagated-inputs (list python-zope-event python-zope-interface))
6101 (native-inputs (list python-zope-i18nmessageid python-zope-testing
6102 python-zope-testrunner python-setuptools))
6103 (home-page "https://zopeschema.readthedocs.io")
6104 (synopsis "Zope data schemas")
6105 (description "Zope.scheme provides extensions to zope.interface for
6106defining data schemas.")
6107 (license license:zpl2.1)))
6108
6109(define-public python-zope-sqlalchemy
6110 (package
6111 (name "python-zope-sqlalchemy")
6112 (version "1.6")
6113 (source
6114 (origin
6115 (method git-fetch)
6116 (uri (git-reference
6117 (url "https://github.com/zopefoundation/zope.sqlalchemy")
6118 (commit version)))
6119 (file-name (git-file-name name version))
6120 (sha256
6121 (base32 "1z4gw4i95dyqxsvrahk4fav008045n8kyxpn3fa887snmpvcjhng"))))
6122 (build-system pyproject-build-system)
6123 (arguments
6124 (list
6125 #:phases
6126 #~(modify-phases %standard-phases
6127 (replace 'check
6128 (lambda* (#:key tests? #:allow-other-keys)
6129 (if tests?
6130 (invoke "zope-testrunner" "--test-path=src")
6131 (format #t "test suite not run~%")))))))
6132 (propagated-inputs (list python-sqlalchemy python-transaction
6133 python-zope-interface))
6134 (native-inputs (list python-zope-testing python-zope-testrunner
6135 python-setuptools))
6136 (home-page "https://github.com/zopefoundation/zope.sqlalchemy")
6137 (synopsis "Minimal SQLAlchemy transaction integration for Zope")
6138 (description
6139 "The aim of this package is to unify the plethora of existing packages
6140integrating SQLAlchemy with Zope's transaction management. As such,it only
6141provides a data manager and makes no attempt to define a @i{zopeish} way to
6142configure engines.")
6143 (license license:zpl2.1)))
6144
6145(define-public python-zope-configuration
6146 (package
6147 (name "python-zope-configuration")
6148 (version "7.0")
6149 (source
6150 (origin
6151 (method git-fetch)
6152 (uri (git-reference
6153 (url "https://github.com/zopefoundation/zope.configuration")
6154 (commit version)))
6155 (file-name (git-file-name name version))
6156 (sha256
6157 (base32 "11lr6z3jpz9835a1if89g3x7k31sviq2d0xvvic5xi4c980dbkhv"))))
6158 (build-system pyproject-build-system)
6159 (arguments
6160 (list
6161 #:phases
6162 #~(modify-phases %standard-phases
6163 (replace 'check
6164 (lambda* (#:key tests? #:allow-other-keys)
6165 (if tests?
6166 (invoke "zope-testrunner" "--test-path=src")
6167 (format #t "test suite not run~%")))))))
6168 (native-inputs (list python-manuel python-setuptools python-zope-testing
6169 python-zope-testrunner))
6170 (propagated-inputs (list python-zope-i18nmessageid python-zope-interface
6171 python-zope-schema))
6172 (home-page "https://zopeconfiguration.readthedocs.io")
6173 (synopsis "Zope Configuration Markup Language")
6174 (description "Zope.configuration implements ZCML, the Zope Configuration
6175Markup Language.")
6176 (license license:zpl2.1)))
6177
6178(define-public python-zope-configuration-bootstrap
6179 (python-zope-bootstrap-package python-zope-configuration))
6180
6181(define-public python-zope-copy
6182 (package
6183 (name "python-zope-copy")
6184 (version "6.0")
6185 (source
6186 (origin
6187 (method git-fetch)
6188 (uri (git-reference
6189 (url "https://github.com/zopefoundation/zope.copy")
6190 (commit version)))
6191 (file-name (git-file-name name version))
6192 (sha256
6193 (base32 "1ym82p9scpfi3rflxnlv55v0a7hra3rq4rrlw759maq05i8qp1w5"))))
6194 (build-system pyproject-build-system)
6195 (arguments
6196 (list
6197 #:phases
6198 #~(modify-phases %standard-phases
6199 (replace 'check
6200 (lambda* (#:key tests? #:allow-other-keys)
6201 (if tests?
6202 (invoke "zope-testrunner" "--test-path=src")
6203 (format #t "test suite not run~%")))))))
6204 (propagated-inputs (list python-zope-interface))
6205 (native-inputs
6206 (list python-zodbpickle
6207 python-zope-component-bootstrap
6208 python-zope-location-bootstrap
6209 python-zope-proxy
6210 python-zope-schema
6211 python-zope-testing
6212 python-zope-testrunner
6213 python-setuptools))
6214 (home-page "https://zopecopy.readthedocs.io")
6215 (synopsis "Pluggable object copying mechanism")
6216 (description
6217 "This package provides a pluggable mechanism for copying persistent objects.")
6218 (license license:zpl2.1)))
6219
6220(define-public python-zope-proxy
6221 (package
6222 (name "python-zope-proxy")
6223 (version "7.0")
6224 (source
6225 (origin
6226 (method git-fetch)
6227 (uri (git-reference
6228 (url "https://github.com/zopefoundation/zope.proxy")
6229 (commit version)))
6230 (file-name (git-file-name name version))
6231 (sha256
6232 (base32 "00r9f4n0cl3fyc5gyf5l43zh95cmzx1gz6wr04k17d7wm2gmivyn"))))
6233 (build-system pyproject-build-system)
6234 (arguments
6235 (list
6236 #:phases
6237 #~(modify-phases %standard-phases
6238 (replace 'check
6239 (lambda* (#:key tests? #:allow-other-keys)
6240 (if tests?
6241 (invoke "zope-testrunner" "--test-path=src")
6242 (format #t "test suite not run~%")))))))
6243 (native-inputs
6244 (list python-zope-location-bootstrap
6245 python-zope-security-bootstrap
6246 python-zope-testrunner
6247 python-setuptools))
6248 (propagated-inputs (list python-zope-interface))
6249 (home-page "https://zopeproxy.readthedocs.io")
6250 (synopsis "Generic, transparent proxies")
6251 (description
6252 "Zope.proxy provides generic, transparent proxies for Python. Proxies are
6253special objects which serve as mostly-transparent wrappers around another
6254object, intervening in the apparent behavior of the wrapped object only when
6255necessary to apply the policy (e.g., access checking, location brokering,
6256etc.) for which the proxy is responsible.")
6257 (license license:zpl2.1)))
6258
6259(define-public python-zope-proxy-bootstrap
6260 (python-zope-bootstrap-package python-zope-proxy))
6261
6262(define-public python-zope-hookable
6263 (package
6264 (name "python-zope-hookable")
6265 (version "7.0")
6266 (source
6267 (origin
6268 (method git-fetch)
6269 (uri (git-reference
6270 (url "https://github.com/zopefoundation/zope.hookable")
6271 (commit version)))
6272 (file-name (git-file-name name version))
6273 (sha256
6274 (base32 "1l94xzzpyslpgv2ghvl5qzpfcsq02kp04fmvl95d6jcmivmmr4m8"))))
6275 (build-system pyproject-build-system)
6276 (arguments
6277 (list
6278 #:phases
6279 #~(modify-phases %standard-phases
6280 (replace 'check
6281 (lambda* (#:key tests? #:allow-other-keys)
6282 (if tests?
6283 (invoke "zope-testrunner" "--test-path=src")
6284 (format #t "test suite not run~%")))))))
6285 (native-inputs (list python-zope-testing python-zope-testrunner
6286 python-setuptools))
6287 (home-page "https://zopehookable.readthedocs.io")
6288 (synopsis "Zope hookable")
6289 (description
6290 "This package supports the efficient creation of hookable objects, which
6291are callable objects that are meant to be optionally replaced. The idea is
6292that you create a function that does some default thing and make i hookable.
6293Later, someone can modify what it does by calling its sethook method and
6294changing its implementation. All users of the function, including those that
6295imported it, will see the change.")
6296 (license license:zpl2.1)))
6297
6298(define-public python-zope-location
6299 (package
6300 (name "python-zope-location")
6301 (version "6.0")
6302 (source
6303 (origin
6304 (method git-fetch)
6305 (uri (git-reference
6306 (url "https://github.com/zopefoundation/zope.location")
6307 (commit version)))
6308 (file-name (git-file-name name version))
6309 (sha256
6310 (base32 "1jfsmbxj6hz7kmk5b0351b63ssm7qfkgqmz9v7xb7wwlmxsxkcdk"))))
6311 (build-system pyproject-build-system)
6312 (arguments
6313 (list
6314 #:phases
6315 #~(modify-phases %standard-phases
6316 (replace 'check
6317 (lambda* (#:key tests? #:allow-other-keys)
6318 (if tests?
6319 (invoke "zope-testrunner" "--test-path=src")
6320 (format #t "test suite not run~%")))))))
6321 (native-inputs (list python-zope-testrunner python-setuptools))
6322 (propagated-inputs (list python-zope-interface python-zope-proxy
6323 python-zope-schema))
6324 (home-page "https://zopelocation.readthedocs.io")
6325 (synopsis "Zope location library")
6326 (description
6327 "Zope.location implements the concept of \"locations\" in Zope3, which
6328are are special objects that have a structural location.")
6329 (license license:zpl2.1)))
6330
6331(define-public python-zope-location-bootstrap
6332 (python-zope-bootstrap-package python-zope-location))
6333
6334(define-public python-zope-security
6335 (package
6336 (name "python-zope-security")
6337 (version "7.3")
6338 (source
6339 (origin
6340 (method git-fetch)
6341 (uri (git-reference
6342 (url "https://github.com/zopefoundation/zope.security")
6343 (commit version)))
6344 (file-name (git-file-name name version))
6345 (sha256
6346 (base32 "06x6qcls2mdl05xnsyy5h70mbgij8xb6ksxbawzrc23cq04nkvx7"))))
6347 (build-system pyproject-build-system)
6348 (arguments
6349 (list
6350 #:phases
6351 #~(modify-phases %standard-phases
6352 (replace 'check
6353 (lambda* (#:key tests? #:allow-other-keys)
6354 (if tests?
6355 (invoke "zope-testrunner" "--test-path=src")
6356 (format #t "test suite not run~%")))))))
6357 (propagated-inputs
6358 (list python-zope-component
6359 python-zope-i18nmessageid
6360 python-zope-interface
6361 python-zope-location
6362 python-zope-proxy
6363 python-zope-schema))
6364 (native-inputs
6365 (list python-btrees
6366 python-zope-component-bootstrap
6367 python-zope-configuration-bootstrap
6368 python-zope-location-bootstrap
6369 python-zope-testing
6370 python-zope-testrunner
6371 python-setuptools))
6372 (home-page "https://zopesecurity.readthedocs.io")
6373 (synopsis "Zope security framework")
6374 (description "Zope.security provides a generic mechanism to implement
6375security policies on Python objects.")
6376 (license license:zpl2.1)))
6377
6378(define-public python-zope-security-bootstrap
6379 (package
6380 (inherit (python-zope-bootstrap-package python-zope-security))
6381 (propagated-inputs
6382 (list python-zope-i18nmessageid
6383 python-zope-interface
6384 python-zope-proxy-bootstrap
6385 python-zope-schema))))
6386
6387(define-public python-zope-component
6388 (package
6389 (name "python-zope-component")
6390 (version "7.0")
6391 (source
6392 (origin
6393 (method git-fetch)
6394 (uri (git-reference
6395 (url "https://github.com/zopefoundation/zope.component")
6396 (commit version)))
6397 (file-name (git-file-name name version))
6398 (sha256
6399 (base32 "1jygzhcg9rppsrd8cwvm0944naq1ldjf0vcpgsz0glwcdnr7cyfw"))))
6400 (build-system pyproject-build-system)
6401 (arguments
6402 (list
6403 #:phases
6404 #~(modify-phases %standard-phases
6405 (replace 'check
6406 (lambda* (#:key tests? #:allow-other-keys)
6407 (if tests?
6408 (invoke "zope-testrunner" "--test-path=src")
6409 (format #t "test suite not run~%")))))))
6410 (native-inputs
6411 (list python-persistent
6412 python-zope-configuration-bootstrap
6413 python-zope-i18nmessageid
6414 python-zope-location-bootstrap
6415 python-zope-proxy-bootstrap
6416 python-zope-security-bootstrap
6417 python-zope-testing
6418 python-zope-testrunner
6419 python-setuptools))
6420 (propagated-inputs
6421 (list python-zope-deferredimport python-zope-deprecation
6422 python-zope-event python-zope-hookable python-zope-interface))
6423 (home-page "https://zopecomponent.readthedocs.io")
6424 (synopsis "Zope Component Architecture")
6425 (description
6426 "Zope.component represents the core of the Zope Component Architecture.
6427Together with the zope.interface package, it provides facilities for defining,
6428registering and looking up components.")
6429 (license license:zpl2.1)))
6430
6431(define-public python-zope-component-bootstrap
6432 (python-zope-bootstrap-package python-zope-component))
6433
6434(define-public python-zope-deferredimport
6435 (package
6436 (name "python-zope-deferredimport")
6437 (version "6.0")
6438 (source
6439 (origin
6440 (method git-fetch)
6441 (uri (git-reference
6442 (url "https://github.com/zopefoundation/zope.deferredimport")
6443 (commit version)))
6444 (file-name (git-file-name name version))
6445 (sha256
6446 (base32 "08j728nn1la570nny1xz1xvxcm9hf2mcc3im1bzcxxrrxh4kw3zd"))))
6447 (build-system pyproject-build-system)
6448 (arguments
6449 (list
6450 #:phases
6451 #~(modify-phases %standard-phases
6452 (replace 'check
6453 (lambda* (#:key tests? #:allow-other-keys)
6454 (if tests?
6455 (invoke "zope-testrunner" "--test-path=src")
6456 (format #t "test suite not run~%")))))))
6457 (propagated-inputs (list python-zope-proxy))
6458 (native-inputs (list python-zope-testrunner python-setuptools))
6459 (home-page "https://zopedeferredimport.readthedocs.io")
6460 (synopsis "Defer imports until used by code")
6461 (description
6462 "Often, especially for package modules, you want to import names for
6463convenience, but not actually perform the imports until necessary. The
6464@code{zope.deferredimport} package provided facilities for defining names in
6465modules that will be imported from somewhere else when used. You can also cause
6466deprecation warnings to be issued when a variable is used.")
6467 (license license:zpl2.1)))
6468
6469(define-public python-ndg-httpsclient
6470 (package
6471 (name "python-ndg-httpsclient")
6472 (version "0.5.1")
6473 (source
6474 (origin
6475 (method git-fetch)
6476 (uri (git-reference
6477 (url "https://github.com/cedadev/ndg_httpsclient/")
6478 (commit version)))
6479 (file-name (git-file-name name version))
6480 (sha256
6481 (base32 "0lhsgs4am4xyjssng5p0vkfwqncczj1dpa0vss4lrhzq86mnn5rz"))))
6482 (build-system pyproject-build-system)
6483 (arguments
6484 (list
6485 #:tests? #f)) ;Tests appear to require networking.
6486 (native-inputs (list python-setuptools))
6487 (propagated-inputs (list python-pyasn1 python-pyopenssl))
6488 (synopsis "HTTPS support for Python's httplib and urllib2")
6489 (description
6490 "This is a HTTPS client implementation for httplib and urllib2 based on
6491PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation over
6492the default provided with Python and, importantly, enables full verification
6493of the SSL peer.")
6494 (home-page "https://github.com/cedadev/ndg_httpsclient/")
6495 (license license:bsd-3)))
6496
6497(define-public python-netaddr
6498 (package
6499 (name "python-netaddr")
6500 (version "1.3.0")
6501 (source
6502 (origin
6503 (method url-fetch)
6504 (uri (pypi-uri "netaddr" version))
6505 (sha256
6506 (base32 "12p4ysgawhgkka0sz1dkwgwc2za80dxdp9wvfxivfldmjnc3sg2w"))))
6507 (build-system pyproject-build-system)
6508 (native-inputs (list python-poetry-core
6509 python-pytest
6510 python-setuptools
6511 python-wheel))
6512 (home-page "https://netaddr.readthedocs.io")
6513 (synopsis "Pythonic manipulation of network addresses")
6514 (description
6515 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
6516and MAC network addresses.")
6517 (license license:bsd-3)))
6518
6519(define-public python-nh3
6520 (package
6521 (name "python-nh3")
6522 (version "0.2.20")
6523 (source
6524 (origin
6525 (method url-fetch)
6526 (uri (pypi-uri "nh3" version))
6527 (sha256
6528 (base32 "1mcf3y5294glji9lhzh57wymw4srbvzdg0kcakm0p2pqgwnw81cp"))))
6529 (build-system pyproject-build-system)
6530 (arguments
6531 (list
6532 #:imported-modules `(,@%cargo-build-system-modules
6533 ,@%pyproject-build-system-modules)
6534 #:modules '(((guix build cargo-build-system) #:prefix cargo:)
6535 (guix build pyproject-build-system)
6536 (guix build utils))
6537 #:phases
6538 #~(modify-phases %standard-phases
6539 (add-after 'unpack 'prepare-cargo-build-system
6540 (lambda args
6541 (for-each
6542 (lambda (phase)
6543 (format #t "Running cargo phase: ~a~%" phase)
6544 (apply (assoc-ref cargo:%standard-phases phase)
6545 #:cargo-target #$(cargo-triplet)
6546 args))
6547 '(unpack-rust-crates
6548 configure
6549 check-for-pregenerated-files
6550 patch-cargo-checksums)))))))
6551 (native-inputs
6552 (append
6553 (list maturin python-pytest rust `(,rust "cargo"))
6554 (or (and=> (%current-target-system)
6555 (compose list make-rust-sysroot))
6556 '())))
6557 (inputs (cargo-inputs 'python-nh3))
6558 (home-page "https://nh3.readthedocs.io")
6559 (synopsis "Python bindings to Ammonia HTML sanitization library")
6560 (description "This package provides Python bindings to Ammonia HTML
6561sanitizer Rust crate.")
6562 (license license:expat)))
6563
6564(define-public python-noiseprotocol
6565 (package
6566 (name "python-noiseprotocol")
6567 (version "0.3.1")
6568 (source
6569 (origin
6570 (method git-fetch)
6571 (uri (git-reference
6572 (url "https://github.com/plizonczyk/noiseprotocol")
6573 (commit (string-append "v" version))))
6574 (file-name (git-file-name name version))
6575 (sha256
6576 (base32 "1mk0rqpjifdv3v1cjwkdnjbrfmzzjm9f3qqs1r8vii4j2wvhm6am"))))
6577 (build-system pyproject-build-system)
6578 (propagated-inputs (list python-cryptography))
6579 (native-inputs (list python-setuptools python-pytest))
6580 (home-page "https://github.com/plizonczyk/noiseprotocol")
6581 (synopsis "Implementation of Noise Protocol Framework")
6582 (description
6583 "This package provides an implementation of Noise Protocol Framework.")
6584 (license license:expat)))
6585
6586(define-public python-webrtcvad-wheels
6587 (package
6588 (name "python-webrtcvad-wheels")
6589 (version "2.0.14")
6590 (source
6591 (origin
6592 (method git-fetch)
6593 (uri (git-reference
6594 (url "https://github.com/daanzu/py-webrtcvad-wheels")
6595 (commit (string-append "v" version))))
6596 (file-name (git-file-name name version))
6597 (sha256
6598 (base32 "0sqgg8jmg2j14f4h96h0rs42kr460v65lhanps6lhdvj5zp81cbh"))))
6599 (build-system pyproject-build-system)
6600 (native-inputs (list python-psutil python-pytest python-setuptools))
6601 (home-page "https://github.com/daanzu/py-webrtcvad-wheels")
6602 (synopsis "Python interface to the WebRTC Voice Activity Detector (VAD)")
6603 (description
6604 "This package provides a Python interface to the Google
6605@url{https://webrtc.org/, WebRTC} @acronym{VAD, Voice Activity Detector}.")
6606 (license license:expat)))
6607
6608(define-public python-websocket-client
6609 (package
6610 (name "python-websocket-client")
6611 (version "1.8.0")
6612 (source
6613 (origin
6614 (method url-fetch)
6615 (uri (pypi-uri "websocket_client" version))
6616 (sha256
6617 (base32 "1nn3qi5g59j55wfy2z02j6lq2cm281fq0wi406b2yqys8jgxyf9j"))))
6618 (build-system pyproject-build-system)
6619 (arguments
6620 (list
6621 #:test-flags
6622 ;; This test requires networking.
6623 '(list "-k" "not testConnect")))
6624 (native-inputs
6625 (list python-pysocks
6626 python-pytest
6627 python-setuptools
6628 python-websockets
6629 python-wheel))
6630 (home-page "https://github.com/websocket-client/websocket-client")
6631 (synopsis "WebSocket client for Python")
6632 (description "The Websocket-client module provides the low level APIs for
6633WebSocket usage in Python programs.")
6634 (license license:lgpl2.1+)))
6635
6636(define-public python-websocket-client-0.59
6637 (package
6638 (inherit python-websocket-client)
6639 (version "0.59.0")
6640 (source
6641 (origin
6642 (method url-fetch)
6643 (uri (pypi-uri "websocket-client" version))
6644 (sha256
6645 (base32 "0p0cz2mdissq7iw1n7jrmsfir0jfmgs1dvnpnrx477ffx9hbsxnk"))))
6646 (native-inputs
6647 (modify-inputs (package-native-inputs python-websocket-client)
6648 (append python-six)))))
6649
6650(define-public python-purl
6651 (package
6652 (name "python-purl")
6653 (version "1.6")
6654 (source
6655 (origin
6656 (method git-fetch)
6657 (uri (git-reference
6658 (url "https://github.com/codeinthehole/purl")
6659 (commit version)))
6660 (file-name (git-file-name name version))
6661 (sha256
6662 (base32 "01zngf0s0qfsrsk0skn57frbzyscwv8467pfjk6hxdfgdx2wkg95"))))
6663 (build-system pyproject-build-system)
6664 (arguments
6665 (list
6666 #:test-flags #~(list "--pyargs" "./tests")))
6667 (native-inputs (list python-pytest python-setuptools))
6668 (propagated-inputs (list python-six))
6669 (home-page "https://github.com/codeinthehole/purl")
6670 (synopsis "Python package for URL manipulation")
6671 (description "Purl is a Python package for handling URLs.")
6672 (license license:expat)))
6673
6674(define-public python-apiron
6675 (package
6676 (name "python-apiron")
6677 (version "5.1.0")
6678 (source
6679 (origin
6680 (method url-fetch)
6681 (uri (pypi-uri "apiron" version))
6682 (sha256
6683 (base32 "1qwbqn47sf0aqznj1snbv37v8ijx476qqkjf5l9pac7xjkxsr8qk"))))
6684 (build-system pyproject-build-system)
6685 (arguments
6686 (list #:test-flags '(list "-k" "not test_call")))
6687 (propagated-inputs
6688 (list python-requests))
6689 (native-inputs
6690 (list python-pytest python-pytest-cov
6691 python-setuptools python-wheel))
6692 (home-page "https://github.com/ithaka/apiron")
6693 (synopsis "Python wrapper for interacting with RESTful APIs")
6694 (description
6695 "@code{apiron} provides a declarative, structured configuration of
6696services and endpoints with a unified interface for interacting with RESTful
6697APIs.")
6698 (license license:expat)))
6699
6700(define-public python-beren
6701 (package
6702 (name "python-beren")
6703 (version "0.7.0")
6704 (source
6705 (origin
6706 (method git-fetch)
6707 (uri (git-reference
6708 (url "https://github.com/teffalump/beren")
6709 (commit (string-append "v" version))))
6710 (file-name (git-file-name name version))
6711 (sha256
6712 (base32 "19nnvbjx2wypslqklqi0j9fiwypk1a5qwfw1jcabjw03awm1yyrx"))))
6713 (build-system pyproject-build-system)
6714 (arguments
6715 ;; The test tries to open a connection to a remote server.
6716 `(#:tests? #f))
6717 (native-inputs (list python-setuptools))
6718 (propagated-inputs (list python-apiron))
6719 (home-page "https://github.com/teffalump/beren")
6720 (synopsis "REST client for Orthanc DICOM servers")
6721 (description
6722 "@code{beren} provides a REST client for Orthanc, a DICOM server.")
6723 (license license:gpl3+)))
6724
6725(define-public python-requests
6726 (package
6727 (name "python-requests")
6728 (version "2.32.5")
6729 (source (origin
6730 (method url-fetch)
6731 (uri (pypi-uri "requests" version))
6732 (sha256
6733 (base32
6734 "1kypqz701x9s7j4shm1pdnzy4pzx9lmvhwgan0yqa071asn0pfnv"))))
6735 (build-system pyproject-build-system)
6736 (arguments
6737 (list #:test-flags
6738 ;; These require internet access
6739 '(list "--ignore=tests/test_requests.py"
6740 "-k" (string-append "not test_use_proxy_from_environment"
6741 " and not requests.sessions.Session"
6742 " and not requests.models.PreparedRequest"
6743 " and not requests.api.request")
6744 "tests/")))
6745 (propagated-inputs
6746 (list python-certifi
6747 python-charset-normalizer
6748 python-idna
6749 python-urllib3))
6750 (native-inputs
6751 (list python-pytest
6752 python-pytest-mock
6753 python-setuptools))
6754 (home-page "https://requests.readthedocs.io/")
6755 (synopsis "Python HTTP library")
6756 (description
6757 "Requests is a Python HTTP client library. It aims to be easier to use
6758than Python’s urllib2 library.")
6759 (license license:asl2.0)))
6760
6761(define-public python-requests-kerberos
6762 (package
6763 (name "python-requests-kerberos")
6764 (version "0.14.0")
6765 ;; No tests in the PyPI tarball.
6766 (source
6767 (origin
6768 (method git-fetch)
6769 (uri (git-reference
6770 (url "https://github.com/requests/requests-kerberos")
6771 (commit (string-append "v" version))))
6772 (file-name (git-file-name name version))
6773 (sha256
6774 (base32 "0s30pcnlir3j2jmf7yh065f294cf3x0x5i3ldskn8mm0a3657mv3"))))
6775 (build-system pyproject-build-system)
6776 (propagated-inputs (list python-cryptography
6777 python-pyspnego
6778 python-requests))
6779 (native-inputs (list python-pytest python-pytest-mock python-setuptools
6780 python-wheel))
6781 (home-page "https://github.com/requests/requests-kerberos")
6782 (synopsis "Kerberos authentication handler for python-requests")
6783 (description "This package provides a Kerberos authentication handler for
6784python-requests.")
6785 (license license:isc)))
6786
6787(define-public python-requests-unixsocket2
6788 (package
6789 (name "python-requests-unixsocket2")
6790 (version "1.0.1")
6791 (source
6792 (origin
6793 (method git-fetch)
6794 (uri (git-reference
6795 (url "https://gitlab.com/thelabnyc/requests-unixsocket2")
6796 (commit (string-append "v" version))))
6797 (sha256
6798 (base32 "0wb8ckagal9d6lfyl3pf9m45xn1krq6vg8kzciwv12chq9wwh0ra"))))
6799 (build-system pyproject-build-system)
6800 (native-inputs
6801 (list nss-certs-for-test
6802 python-hatchling
6803 python-pytest
6804 python-waitress))
6805 (propagated-inputs
6806 (list python-requests
6807 python-urllib3))
6808 (home-page "https://gitlab.com/thelabnyc/requests-unixsocket2")
6809 (synopsis "Talk HTTP via a UNIX domain socket")
6810 (description
6811 "This Python package lets you use the @code{requests} library to talk
6812HTTP via a UNIX domain socket.")
6813 (license license:asl2.0)))
6814
6815(define-public python-requests-ntlm
6816 (package
6817 (name "python-requests-ntlm")
6818 (version "1.3.0")
6819 (source
6820 (origin
6821 (method git-fetch)
6822 (uri (git-reference
6823 (url "https://github.com/requests/requests-ntlm")
6824 (commit (string-append "v" version))))
6825 (file-name (git-file-name name version))
6826 (sha256
6827 (base32 "0snsk66zdihdlyfjz2zgpyfgdyjg814m3cc4g3my09hdnb5xvagv"))))
6828 (build-system pyproject-build-system)
6829 (arguments
6830 (list
6831 #:test-flags
6832 ;; XXX: Connection refused.
6833 #~(list "-k" (string-join
6834 (list "not test_ntlm_http_with_cbt"
6835 "test_ntlm_http_without_cbt"
6836 "test_ntlm_https_with_cbt"
6837 "test_ntlm_https_without_cbt")
6838 " and not "))
6839 #:phases
6840 #~(modify-phases %standard-phases
6841 (add-before 'check 'spawn-test-server
6842 (lambda _
6843 ;; Taken from .github/workflows/ci.yml.
6844 (spawn "python"
6845 (list "python" "-m" "tests.test_server")))))))
6846 (propagated-inputs
6847 (list python-cryptography python-pyspnego python-requests))
6848 (native-inputs (list python-flask python-pytest python-setuptools))
6849 (home-page "https://github.com/requests/requests-ntlm")
6850 (synopsis "NTLM authentication support for Requests")
6851 (description
6852 "This package allows for HTTP NTLM authentication using the requests
6853library.")
6854 (license license:isc)))
6855
6856(define-public python-requests-mock
6857 (package
6858 (name "python-requests-mock")
6859 (version "1.12.1")
6860 (source
6861 (origin
6862 (method url-fetch)
6863 (uri (pypi-uri "requests-mock" version))
6864 (sha256
6865 (base32 "008l6xysgs6ax56lairg1li5i4bb04i2z19w5bl5claj7crjxqg9"))))
6866 (build-system pyproject-build-system)
6867 (native-inputs
6868 (list python-purl
6869 python-pytest
6870 python-requests-futures
6871 python-setuptools
6872 python-setuptools-scm
6873 python-testtools))
6874 (propagated-inputs
6875 (list python-requests))
6876 (home-page "https://requests-mock.readthedocs.org/")
6877 (synopsis "Mock out responses from the requests package")
6878 (description
6879 "This module provides a building block to stub out the HTTP requests
6880portions of your testing code.")
6881 (license license:asl2.0)))
6882
6883(define-public python-requests-toolbelt
6884 (package
6885 (name "python-requests-toolbelt")
6886 (version "1.0.0")
6887 (source
6888 (origin
6889 (method url-fetch)
6890 (uri (pypi-uri "requests-toolbelt" version))
6891 (sha256
6892 (base32 "1ijvip427ki177ycrblcn1mfgsq7ixzpvqqfvidjn0a7s2is10bn"))))
6893 (build-system pyproject-build-system)
6894 (arguments
6895 (list
6896 #:test-flags
6897 ;; Requiring networking or fail due not valid certs: AttributeError:
6898 ;; 'MockHTTPResponse' object has no attribute 'close'
6899 #~(list "-k" (string-append "not test_dump_all"
6900 " and not test_dump_response"
6901 " and not test_prepared_request_override_base"
6902 " and not test_prepared_request_with_base"
6903 " and not test_request_override_base"
6904 " and not test_request_with_base"))))
6905 (native-inputs
6906 (list python-betamax
6907 python-mock
6908 python-pyopenssl
6909 python-pytest
6910 python-setuptools
6911 python-trustme
6912 python-wheel))
6913 (propagated-inputs
6914 (list python-requests))
6915 (synopsis "Extensions to python-requests")
6916 (description "This is a toolbelt of useful classes and functions to be used
6917with python-requests.")
6918 (home-page "https://github.com/requests/toolbelt/")
6919 (license license:asl2.0)))
6920
6921(define-public python-requests-ftp
6922 (package
6923 (name "python-requests-ftp")
6924 (version "0.3.1")
6925 (source
6926 (origin
6927 (method git-fetch)
6928 (uri (git-reference
6929 (url "https://github.com/Lukasa/requests-ftp")
6930 (commit (string-append "v" version))))
6931 (file-name (git-file-name name version))
6932 (sha256
6933 (base32 "1c7xbz2fxb12ldaw2pkfg5qd29g6slf4a2gavhqvz26cd1r82ny7"))))
6934 (build-system pyproject-build-system)
6935 (arguments
6936 ;; XXX: No connection adapters found.
6937 (list #:test-flags #~(list "--ignore=tests/test_ftp_proxy.py")))
6938 (native-inputs
6939 (list python-pyftpdlib python-pytest python-setuptools python-six))
6940 (propagated-inputs (list python-requests))
6941 (home-page "https://github.com/Lukasa/requests-ftp")
6942 (synopsis "FTP Transport Adapter for Requests")
6943 (description "Requests-FTP is an implementation of a simple FTP transport
6944adapter for use with the Requests library.")
6945 (license license:asl2.0)))
6946
6947(define-public python-aioftp
6948 (package
6949 (name "python-aioftp")
6950 (version "0.22.3")
6951 (source (origin
6952 (method url-fetch)
6953 (uri (pypi-uri "aioftp" version))
6954 (sha256
6955 (base32
6956 "0w621mg956m9rn7v39jpwi4gpnpl90pprwl29cp640dahqqv38ms"))))
6957 (build-system pyproject-build-system)
6958 (native-inputs
6959 (list python-async-timeout
6960 python-pytest
6961 python-pytest-asyncio
6962 python-pytest-cov
6963 python-setuptools
6964 python-trustme
6965 python-wheel))
6966 (propagated-inputs (list python-siosocks))
6967 (home-page "https://aioftp.readthedocs.io/")
6968 (synopsis "FTP client/server for asyncio in Python")
6969 (description
6970 "FTP client and server for asyncio (Python 3) Library implementing FTP
6971protocol, both client and server for Python asyncio module.
6972
6973 Supported commands as client: USER, PASS, ACCT, PWD, CWD, CDUP, MKD, RMD,
6974 MLSD, MLST, RNFR, RNTO, DELE, STOR, APPE, RETR, TYPE, PASV, ABOR, QUIT,
6975 REST, LIST (as fallback).
6976
6977 Supported commands as server: USER, PASS, QUIT, PWD, CWD, CDUP, MKD, RMD,
6978 MLSD, LIST (non-standard), MLST, RNFR, RNTO, DELE, STOR, RETR,
6979 TYPE (\"I\" and \"A\"), PASV, ABOR, APPE, REST.")
6980 (license license:asl2.0)))
6981
6982(define-public python-mohawk
6983 (let ((commit "b7899166880e890f01cf2531b5686094ba08df8f")
6984 (revision "0"))
6985 (package
6986 (name "python-mohawk")
6987 (version (git-version "1.1.0" revision commit))
6988 (source
6989 (origin
6990 (method git-fetch)
6991 (uri (git-reference
6992 (url "https://github.com/kumar303/mohawk")
6993 (commit commit)))
6994 (file-name (git-file-name name version))
6995 (sha256
6996 (base32 "00y9fimcj851rk2770wqk61fac9pnxfnzca4fvsci57zw18i50m6"))
6997 (patches
6998 (search-patches "python-mohawk-pytest.patch"))))
6999 (build-system pyproject-build-system)
7000 (arguments
7001 (list #:test-flags #~(list "mohawk/tests.py")))
7002 (native-inputs (list python-pytest python-setuptools))
7003 (propagated-inputs (list python-six)) ;TODO: remove python-mohawk when
7004 ;python-six is removed?
7005 (home-page "https://github.com/kumar303/mohawk")
7006 (synopsis "Library for Hawk HTTP authorization")
7007 (description
7008 "Mohawk is an alternate Python implementation of the Hawk HTTP
7009authorization scheme.")
7010 (license license:bsd-3))))
7011
7012(define-public python-msal
7013 (package
7014 (name "python-msal")
7015 (version "1.34.0")
7016 (home-page
7017 "https://github.com/AzureAD/microsoft-authentication-library-for-python")
7018 (source
7019 (origin
7020 (method git-fetch)
7021 (uri (git-reference
7022 (url home-page)
7023 (commit version)))
7024 (file-name (git-file-name name version))
7025 (sha256
7026 (base32 "1xcyiv742ihnzypjw7syamnhqffdy6wsvvv0f5jcl3pap0apbk0z"))
7027 (patches (search-patches "python-msal-requests.patch"))))
7028 (build-system pyproject-build-system)
7029 (arguments
7030 (list
7031 #:test-flags
7032 #~(list
7033 "--ignore=tests/test_benchmark.py"
7034 ;; XXX: Ignoring cryptography version scheme tests.
7035 "-k"
7036 "not test_ceiling_should_be_latest_cryptography_version_plus_three"
7037 ;; XXX: These tests try to access the network.
7038 "--ignore=tests/test_application.py"
7039 "--ignore=tests/test_ccs.py"
7040 ;; XXX: These tests assume they are run on Windows.
7041 "--ignore=tests/test_mi.py")
7042 #:phases
7043 #~(modify-phases %standard-phases
7044 (add-after 'unpack 'set-cryptography-version
7045 (lambda _
7046 (substitute* "tests/test_cryptography.py"
7047 (("^latest_cryptography_version = @version@")
7048 (format #f "latest_cryptography_version = ~s"
7049 #$(package-version
7050 (this-package-input "python-cryptography")))))))
7051 (add-before 'check 'configure-tests
7052 (lambda* (#:key tests? #:allow-other-keys)
7053 (when tests?
7054 (setenv "TRAVIS_TAG" "1")))))))
7055 (native-inputs
7056 (list nss-certs-for-test python-mock python-pytest python-setuptools))
7057 (propagated-inputs (list python-cryptography python-pyjwt python-requests))
7058 (synopsis "Microsoft Authentication Library (MSAL) for Python")
7059 (description
7060 "The Microsoft Authentication Library for Python enables applications to
7061integrate with the Microsoft identity platform. It allows you to sign in
7062users or apps with Microsoft identities (Azure AD, Microsoft Accounts and
7063Azure AD B2C accounts) and obtain tokens to call Microsoft APIs such as
7064Microsoft Graph or your own APIs registered with the Microsoft identity
7065platform. It is built using industry standard OAuth2 and OpenID Connect
7066protocols.")
7067 (license license:expat)))
7068
7069(define-public oauth2ms
7070 (let ((commit "a1ef0cabfdea57e9309095954b90134604e21c08")
7071 (revision "0"))
7072 (package
7073 (name "oauth2ms")
7074 (version (git-version "0.0.0" revision commit))
7075 (source (origin
7076 (method git-fetch)
7077 (uri (git-reference
7078 (url "https://github.com/harishkrupo/oauth2ms")
7079 (commit commit)))
7080 (file-name (git-file-name name version))
7081 (sha256
7082 (base32
7083 "0dqi6n4npdrvb42r672n4sl1jl8z5lsk554fwiiihpj0faa9dx64"))))
7084 (build-system copy-build-system)
7085 (arguments
7086 (list #:install-plan #~`(("oauth2ms" "bin/oauth2ms")
7087 ("." #$(string-append "share/doc/" name "-"
7088 version "/")
7089 #:include-regexp ("\\.org$")))
7090 #:phases #~(modify-phases %standard-phases
7091 (add-after 'install 'wrap-pythonpath
7092 (lambda* (#:key inputs outputs #:allow-other-keys)
7093 (let ((path (getenv "GUIX_PYTHONPATH")))
7094 (wrap-program (string-append #$output
7095 "/bin/oauth2ms")
7096 `("GUIX_PYTHONPATH" ":" prefix
7097 (,path)))))))))
7098 (inputs (list bash-minimal python python-gnupg python-msal python-pyxdg))
7099 (home-page "https://github.com/harishkrupo/oauth2ms")
7100 (synopsis "XOAUTH2 compatible Microsoft Office 365 token fetcher")
7101 (description
7102 "Oauth2ms can be used to fetch OAuth 2.0 tokens from the Microsoft Identity
7103endpoint. Additionally, it can encode the token in the XOAUTH2 format to be
7104used as authentication in IMAP mail servers.")
7105 (license license:asl2.0))))
7106
7107(define-public python-oauthlib
7108 (package
7109 (name "python-oauthlib")
7110 (version "3.3.1")
7111 (source
7112 (origin
7113 (method git-fetch)
7114 (uri (git-reference
7115 (url "https://github.com/oauthlib/oauthlib")
7116 (commit (string-append "v" version))))
7117 (file-name (git-file-name name version))
7118 (sha256
7119 (base32 "0aa38lpa6s1k56v7w7kw2w4l159kaz4gn03m698a8hfdjkx92fb5"))))
7120 (build-system pyproject-build-system)
7121 (native-inputs (list python-pytest python-pytest-cov python-mock
7122 python-setuptools))
7123 (propagated-inputs (list python-cryptography python-pyjwt python-blinker))
7124 (home-page "https://github.com/oauthlib/oauthlib")
7125 (synopsis "OAuth implementation for Python")
7126 (description
7127 "Oauthlib is a generic, spec-compliant, thorough implementation of the
7128OAuth request-signing logic.")
7129 (license license:bsd-3)))
7130
7131(define-public python-urllib3
7132 (package
7133 (name "python-urllib3")
7134 (version "2.5.0")
7135 (source
7136 (origin
7137 (method url-fetch)
7138 (uri (pypi-uri "urllib3" version))
7139 (sha256
7140 (base32
7141 "0q17z6zlpyjv9ax5c3d30qwp9fwhz2sc4gbb7yyd86g4qwrpgi1z"))))
7142 (build-system pyproject-build-system)
7143 (arguments `(#:tests? #f))
7144 (native-inputs
7145 (list python-hatch-vcs
7146 python-hatchling
7147 python-setuptools-scm))
7148 (propagated-inputs
7149 (append
7150 ;; These 5 inputs are used to build urrlib3[secure]
7151 (list python-certifi)
7152 (if (member (%current-system)
7153 (package-transitive-supported-systems python-cryptography))
7154 (list python-cryptography)
7155 '())
7156 (list python-idna)
7157 (if (member (%current-system)
7158 (package-transitive-supported-systems python-pyopenssl))
7159 (list python-pyopenssl)
7160 '())
7161 (list python-pysocks)))
7162 (home-page "https://urllib3.readthedocs.io/")
7163 (synopsis "HTTP library with thread-safe connection pooling")
7164 (description
7165 "Urllib3 supports features left out of urllib and urllib2 libraries. It
7166can reuse the same socket connection for multiple requests, it can POST files,
7167supports url redirection and retries, and also gzip and deflate decoding.")
7168 (license license:expat)))
7169
7170(define-public python-urllib3-1.25
7171 (package
7172 (inherit python-urllib3)
7173 (version "1.25.19")
7174 (source
7175 (origin
7176 (method url-fetch)
7177 (uri (pypi-uri "urllib3" version))
7178 (sha256
7179 (base32
7180 "09rmjqm5syhhc8fx3v06h3yv6cqy0b1081jg8wm5grpwpr72j61h"))))
7181 (native-inputs
7182 (list python-setuptools
7183 python-wheel))))
7184
7185(define-public python-urllib3-1.26
7186 (package
7187 (inherit python-urllib3)
7188 (version "1.26.17")
7189 (source
7190 (origin
7191 (method url-fetch)
7192 (uri (pypi-uri "urllib3" version))
7193 (sha256
7194 (base32
7195 "08fzhaf77kbjj5abpl9xag6fpfxkdp1k5s7sqd3ayacdq91a5mi4"))))
7196 (native-inputs
7197 (list python-setuptools
7198 python-wheel))))
7199
7200(define-public python-awscrt
7201 (package
7202 (name "python-awscrt")
7203 (version "0.26.1")
7204 (source
7205 (origin
7206 (method url-fetch)
7207 (uri (pypi-uri "awscrt" version))
7208 (sha256
7209 (base32 "0plkc0i0gc6z8fqnyy8kbg43sv3jnv8shcavcz0wb134riykmmm8"))))
7210 (build-system pyproject-build-system)
7211 (arguments
7212 (list
7213 #:test-backend #~'unittest
7214 #:test-flags #~(list "discover" "--verbose")
7215 #:phases
7216 #~(modify-phases %standard-phases
7217 (add-after 'unpack 'disable-broken-tests
7218 (lambda _
7219 ;; Disable broken tests. These tests fail because the
7220 ;; certificate bundle at the default location does not exist.
7221 (substitute* "test/test_auth.py"
7222 (("def test_default_provider")
7223 "def _test_default_provider"))
7224 (substitute* "test/test_http_client.py"
7225 (("def test_h2_client")
7226 "def _test_h2_client"))
7227 (substitute* "test/test_s3.py"
7228 (("def test_sanity")
7229 "def _test_sanity")
7230 (("def test_sanity_secure")
7231 "def _test_sanity_secure")
7232 (("def test_wait_shutdown")
7233 "def _test_wait_shutdown"))))
7234 (add-after 'unpack 'override-cert-bundle-location
7235 (lambda* (#:key inputs #:allow-other-keys)
7236 (let ((bundle (search-input-file inputs
7237 "/etc/ssl/certs/ca-certificates.crt")))
7238 (setenv "SSL_CERT_FILE" bundle)
7239 (substitute* "awscrt/io.py"
7240 (("( +)opt = TlsContextOptions\\(\\)" m indent)
7241 (string-append m "\n"
7242 indent "import os\n"
7243 indent "\
7244opt.override_default_trust_store_from_path(None, os.getenv('SSL_CERT_FILE')) if os.getenv('SSL_CERT_FILE') else None\n")))
7245 (substitute* "test/appexit_http.py"
7246 (("( +)tls_ctx_opt = awscrt.io.TlsContextOptions.*" m indent)
7247 (string-append m indent
7248 "tls_ctx_opt.override_default_trust_store_from_path(None, '"
7249 bundle "')\n")))
7250 (substitute* "test/test_io.py"
7251 (("( +)opt = TlsContextOptions\\(\\).*" m indent)
7252 (string-append m indent
7253 "opt.override_default_trust_store_from_path(None, '"
7254 bundle "')\n"))))))
7255 (add-after 'unpack 'use-system-libraries
7256 (lambda _
7257 (setenv "AWS_CRT_BUILD_USE_SYSTEM_LIBCRYPTO" "1"))))))
7258 (inputs (list openssl))
7259 (native-inputs (list cmake-minimal
7260 nss-certs-for-test
7261 python-boto3
7262 python-setuptools
7263 python-websockets))
7264 (home-page "https://github.com/awslabs/aws-crt-python")
7265 (synopsis "Common runtime for AWS Python projects")
7266 (description
7267 "This package provides a common runtime for AWS Python projects.")
7268 (license license:asl2.0)))
7269
7270(define-public awscli
7271 (package
7272 ;; Note: updating awscli typically requires updating botocore as well.
7273 (name "awscli")
7274 (version "1.43.11")
7275 (source
7276 (origin
7277 (method git-fetch)
7278 (uri (git-reference
7279 (url "https://github.com/aws/aws-cli")
7280 (commit version)))
7281 (file-name (git-file-name name version))
7282 (sha256
7283 (base32 "1idvcnc6jw7xr1jqpza472ksj3i2kyk0bv8wr7acz3xnba1v8xmi"))))
7284 (build-system pyproject-build-system)
7285 (arguments
7286 (list
7287 ;; tests: 2715 passed, 32 warnings
7288 #:test-flags
7289 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
7290 ;; Complete test suite is huge and compute hungry, run just unit
7291 ;; tests.
7292 "--ignore=tests/dependencies"
7293 "--ignore=tests/functional"
7294 "--ignore=tests/integration"
7295 ;; TypeError: 'Mock' object is not subscriptable.
7296 "-k" "not test_no_groff_or_mandoc_exists")
7297 #:phases
7298 #~(modify-phases %standard-phases
7299 (add-after 'unpack 'fix-reference-to-groff
7300 (lambda _
7301 ;; XXX: Consider to use wrap-program instead, it tries to parse
7302 ;; the PATH.
7303 (substitute* "awscli/help.py"
7304 (("if self._exists_on_path\\('groff'\\):") "if 'groff':")
7305 (("raise ExecutableNotFoundError\\('groff'\\)") "")
7306 (("cmdline = \\['groff'")
7307 (format #f "cmdline = ['~a/bin/groff'"
7308 #$(this-package-input "groff-minimal"))))))
7309 (add-before 'check 'set-environment
7310 (lambda _
7311 ;; PermissionError: [Errno 13] Permission denied:
7312 ;; '/homeless-shelter'
7313 (setenv "HOME" "/tmp"))))))
7314 (native-inputs
7315 (list python-pytest
7316 python-pytest-xdist
7317 python-setuptools
7318 python-wheel))
7319 (inputs
7320 (list groff-minimal
7321 python-botocore
7322 python-colorama
7323 python-docutils-0.19
7324 python-pyyaml
7325 python-rsa-for-awscli-1
7326 python-s3transfer))
7327 (home-page "https://aws.amazon.com/cli/")
7328 (synopsis "Command line client for AWS")
7329 (description
7330 "AWS CLI provides a unified command line interface to the Amazon Web
7331Services (AWS) API.")
7332 (license license:asl2.0)))
7333
7334(define-public awscli-2
7335 (package
7336 (inherit awscli)
7337 ;; Note: updating awscli-2 typically requires updating python-awscrt.
7338 (name "awscli")
7339 ;; Upstream practices a very rapid (1h-1d) release cycles try to select
7340 ;; any fresh one compatible with current state of dependencies in Guix.
7341 (version "2.28.0")
7342 (source
7343 (origin
7344 (method git-fetch)
7345 (uri (git-reference
7346 (url "https://github.com/aws/aws-cli")
7347 (commit version)))
7348 (file-name (git-file-name name version))
7349 (sha256
7350 (base32
7351 "1a1jzvdm434x46yh7ir11lw0nzc64ns4qvxhp5wfra3rh5ykf36j"))))
7352 (build-system pyproject-build-system)
7353 (arguments
7354 (list
7355 ;; When updating and checking locally be very patient as build phase may
7356 ;; hang for 6-8 minutes but eventually passes through.
7357 ;;
7358 ;; tests: 4189 passed, 1 skipped, 2 warnings
7359 #:test-flags
7360 '(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
7361 ;; Full test suite contains more than 70k tests; ignore network
7362 ;; dependent, slow and compute intense tests, keep just unit
7363 ;; tests.
7364 "--ignore=tests/backends"
7365 "--ignore=tests/dependencies"
7366 "--ignore=tests/functional"
7367 "--ignore=tests/integration"
7368 "--ignore=tests/unit/botocore"
7369 ;; Flaky, something to do with PATH disappearing from os.environ?
7370 ;; Passes when run on its own, so maybe something else is
7371 ;; modifying this during the test run.
7372 "--ignore=tests/unit/customizations/emr/test_emr_utils.py"
7373 ;; TypeError: 'Mock' object is not subscriptable
7374 "-k" "not test_no_groff_or_mandoc_exists")
7375 #:phases
7376 #~(modify-phases %standard-phases
7377 (add-after 'unpack 'ignore-deprecations
7378 (lambda _
7379 (substitute* "pyproject.toml"
7380 (("\"error::") "\"ignore::"))))
7381 (add-after 'unpack 'fix-reference-to-groff
7382 (lambda* (#:key inputs #:allow-other-keys)
7383 (substitute* "awscli/help.py"
7384 (("if self._exists_on_path\\('groff'\\):") "if True:")
7385 (("cmdline = \\['groff'")
7386 (string-append "cmdline = ['"
7387 (search-input-file inputs "bin/groff")
7388 "'")))))
7389 (add-before 'check 'pre-check
7390 (lambda _ (setenv "HOME" "/tmp"))))))
7391 (inputs
7392 (list groff
7393 ;; less
7394 nss-certs-for-test
7395 python-awscrt
7396 python-colorama
7397 python-dateutil
7398 python-distro
7399 python-docutils
7400 python-jmespath
7401 python-prompt-toolkit
7402 python-ruamel.yaml
7403 python-ruamel.yaml.clib
7404 python-urllib3))
7405 (native-inputs
7406 (list python-flit-core
7407 python-pytest
7408 python-pytest-xdist))))
7409
7410(define-public python-wsgiproxy2
7411 (package
7412 (name "python-wsgiproxy2")
7413 (version "0.5.1")
7414 (source
7415 (origin
7416 (method git-fetch)
7417 (uri (git-reference
7418 (url "https://github.com/gawel/WSGIProxy2/")
7419 (commit version)))
7420 (file-name (git-file-name name version))
7421 (sha256
7422 (base32 "0aw9ibla2cqzlbm3vzyk1yk3d8pccpbpdkqx99q30hq1fz1izsm2"))))
7423 (build-system pyproject-build-system)
7424 (arguments (list #:test-backend #~'unittest))
7425 (native-inputs (list python-webtest python-setuptools))
7426 (propagated-inputs (list python-requests python-six python-urllib3
7427 python-webob))
7428 (home-page "https://github.com/gawel/WSGIProxy2/")
7429 (synopsis "WSGI Proxy with various http client backends")
7430 (description
7431 "WSGI turns HTTP requests into WSGI function calls. WSGIProxy turns WSGI
7432function calls into HTTP requests. It also includes code to sign requests and
7433pass private data, and to spawn subprocesses to handle requests.")
7434 (license license:expat)))
7435
7436(define-public python-pastedeploy
7437 (package
7438 (name "python-pastedeploy")
7439 (version "3.1.0")
7440 (source
7441 (origin
7442 (method url-fetch)
7443 (uri (pypi-uri "PasteDeploy" version))
7444 (sha256
7445 (base32 "15as15mgz9xn33abwrp0x0mbj537ib3q47z8ky5475c05wasznwx"))))
7446 (build-system pyproject-build-system)
7447 (native-inputs (list python-pytest python-pytest-cov python-setuptools))
7448 (home-page "https://pylonsproject.org/")
7449 (synopsis "Load, configure, and compose WSGI applications and servers")
7450 (description
7451 "This tool provides code to load WSGI applications and servers from URIs;
7452these URIs can refer to Python Eggs for INI-style configuration files. Paste
7453Script provides commands to serve applications based on this configuration
7454file.")
7455 (license license:expat)))
7456
7457(define-public python-webtest
7458 (package
7459 (name "python-webtest")
7460 (version "3.0.6")
7461 (source
7462 (origin
7463 (method url-fetch)
7464 (uri (pypi-uri "webtest" version))
7465 (sha256
7466 (base32 "0jwl8i9xvm5xim1h2jrwfbqac1g3fpiazfdwfp2md3s4899gsmj2"))))
7467 (build-system pyproject-build-system)
7468 (arguments
7469 ;; Tests require python-pyquery, which creates a circular dependency.
7470 `(#:tests? #f))
7471 (native-inputs
7472 (list python-setuptools))
7473 (propagated-inputs
7474 (list python-beautifulsoup4
7475 python-waitress
7476 python-webob))
7477 (home-page "https://docs.pylonsproject.org/projects/webtest/")
7478 (synopsis "Helper to test WSGI applications")
7479 (description
7480 "Webtest allows you to test your Python web applications without
7481starting an HTTP server. It supports anything that supports the minimum of
7482WSGI.")
7483 (license license:expat)))
7484
7485(define-public python-flask
7486 (package
7487 (name "python-flask")
7488 (version "3.1.0")
7489 (source
7490 (origin
7491 (method url-fetch)
7492 (uri (pypi-uri "flask" version))
7493 (sha256
7494 (base32 "1b1nb250jxrjplbs21wnwq69250vs3iz2pdhs7cwi5y8hi8kr1sz"))))
7495 (build-system pyproject-build-system)
7496 (native-inputs
7497 (list python-flit-core
7498 python-pytest))
7499 (propagated-inputs
7500 (list python-asgiref ;async extra
7501 python-click
7502 python-blinker
7503 python-itsdangerous
7504 python-jinja2
7505 python-werkzeug))
7506 (home-page "https://palletsprojects.com/p/flask/")
7507 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
7508 (description "Flask is a micro web framework based on the Werkzeug toolkit
7509and Jinja2 template engine. It is called a micro framework because it does not
7510presume or force a developer to use a particular tool or library.")
7511 (license license:bsd-3)))
7512
7513(define-public python-flask-compress
7514 (package
7515 (name "python-flask-compress")
7516 (version "1.18")
7517 (source (origin
7518 (method url-fetch)
7519 (uri (pypi-uri "flask_compress" version))
7520 (sha256
7521 (base32
7522 "0fj1r0ixsjls7z3a2zzamxppjz4qcf8q4jcmn74gsk9kisyy3fpx"))))
7523 (build-system pyproject-build-system)
7524 (native-inputs
7525 (list python-flask-caching
7526 python-pytest
7527 python-setuptools
7528 python-setuptools-scm))
7529 (propagated-inputs
7530 (list python-brotli
7531 python-flask
7532 python-pyzstd))
7533 (home-page "https://github.com/colour-science/flask-compress")
7534 (synopsis "Compress responses in a Flask app")
7535 (description
7536 "This package lets you compress Flask application responses and static
7537files with gzip, deflate or brotli. Flask-Compress both adds the various
7538headers required for a compressed response and compresses the response data.")
7539 (license license:expat)))
7540
7541(define-public python-flask-seasurf
7542 (package
7543 (name "python-flask-seasurf")
7544 (version "2.0.0")
7545 (source (origin
7546 (method url-fetch)
7547 (uri (pypi-uri "Flask-SeaSurf" version))
7548 (sha256
7549 (base32
7550 "0g5dsm2ikv8q4qcrb2446pbs972l5wkxyfmxsriqdsl02nz06h4f"))))
7551 (build-system pyproject-build-system)
7552 (arguments
7553 (list #:tests? #false)) ;there are none
7554 (propagated-inputs (list python-flask))
7555 (native-inputs (list python-setuptools python-wheel))
7556 (home-page "https://github.com/maxcountryman/flask-seasurf/")
7557 (synopsis "CSRF extension for Flask")
7558 (description "SeaSurf is a Flask extension for preventing cross-site
7559request forgery (CSRF). CSRF attacks are problematic because the mechanism
7560they use is relatively easy to exploit. This extension attempts to aid you in
7561securing your application from such attacks. This extension is based on the
7562Django middleware.")
7563 (license license:bsd-3)))
7564
7565(define-public python-flask-wtf
7566 (package
7567 (name "python-flask-wtf")
7568 (version "1.2.2")
7569 (source
7570 (origin
7571 (method url-fetch)
7572 (uri (pypi-uri "Flask-WTF" version))
7573 (sha256
7574 (base32
7575 "0sv6hjva1fdizb7sr46230pplx8qz8rnb4bxrfy71xbc8cgfxlkr"))))
7576 (build-system pyproject-build-system)
7577 (propagated-inputs
7578 (list python-flask python-flask python-itsdangerous python-wtforms))
7579 (native-inputs
7580 (list python-hatchling python-pytest))
7581 (home-page "https://github.com/lepture/flask-wtf")
7582 (synopsis "Simple integration of Flask and WTForms")
7583 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
7584upload, and reCAPTCHA.")
7585 (license license:bsd-3)))
7586
7587(define-public python-flask-multistatic
7588 (package
7589 (name "python-flask-multistatic")
7590 (version "1.0")
7591 (source
7592 (origin
7593 (method url-fetch)
7594 (uri (pypi-uri "flask-multistatic" version))
7595 (sha256
7596 (base32
7597 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
7598 (build-system pyproject-build-system)
7599 (arguments (list #:tests? #f)) ; No tests upstream.
7600 (native-inputs (list python-setuptools))
7601 (propagated-inputs (list python-flask))
7602 (home-page "https://pagure.io/flask-multistatic")
7603 (synopsis "Flask plugin to allow overriding static files")
7604 (description "@code{flask-multistatic} is a flask plugin that adds support
7605for overriding static files.")
7606 (license license:gpl3+)))
7607
7608(define-public python-responses
7609 (package
7610 (name "python-responses")
7611 (version "0.25.3")
7612 (source (origin
7613 (method url-fetch)
7614 (uri (pypi-uri "responses" version))
7615 (sha256
7616 (base32
7617 "1fld6lsa143md4lxccwxq9iyqm9d8a05i9sp7lqjibnrmd3r4yv1"))))
7618 (build-system pyproject-build-system)
7619 (native-inputs
7620 (list python-pytest
7621 python-pytest-asyncio
7622 python-pytest-httpserver
7623 python-setuptools
7624 python-tomli
7625 python-tomli-w
7626 python-wheel))
7627 (propagated-inputs
7628 (list python-requests
7629 python-pyyaml
7630 python-urllib3))
7631 (home-page "https://github.com/getsentry/responses")
7632 (synopsis "Utility for mocking out the `requests` Python library")
7633 (description "A utility library for mocking out the `requests` Python
7634library.")
7635 (license license:asl2.0)))
7636
7637(define-public python-grequests
7638 (let ((commit "60f70e99e942a2df378b4e4f6202dcf862754c2d")
7639 (revision "0"))
7640 (package
7641 (name "python-grequests")
7642 (version (git-version "0.7.0" revision commit))
7643 (source
7644 (origin
7645 (method git-fetch)
7646 (uri (git-reference
7647 (url "https://github.com/kennethreitz/grequests")
7648 (commit commit)))
7649 (file-name (git-file-name name version))
7650 (sha256
7651 (base32 "0132yv1rr4pmrmwasrnasqbnd80pi6rgy52608731p7lidkmxz9a"))))
7652 (build-system pyproject-build-system)
7653 (arguments
7654 (list
7655 ;; XXX: Most failing tests seem to be caused by network access,
7656 ;; but there is no easy/flag way to disable tests selectively.
7657 #:tests? #f
7658 #:test-backend #~'unittest
7659 #:test-flags #~(list "tests.py")))
7660 (propagated-inputs (list python-gevent python-requests))
7661 (native-inputs (list python-setuptools))
7662 (home-page "https://github.com/kennethreitz/grequests")
7663 (synopsis "Python library for asynchronous HTTP requests")
7664 (description
7665 "GRequests is a Python library that allows you to use @code{Requests}
7666with @code{Gevent} to make asynchronous HTTP Requests easily.")
7667 (license license:bsd-2))))
7668
7669(define-public python-gwebsockets
7670 (package
7671 (name "python-gwebsockets")
7672 (version "0.7")
7673 (source
7674 (origin
7675 (method git-fetch)
7676 (uri (git-reference
7677 (url "https://github.com/sugarlabs/gwebsockets")
7678 (commit (string-append "v" version))))
7679 (file-name (git-file-name name version))
7680 (sha256
7681 (base32 "0w422yz0qdix5xb6aqrrci1s1hy4whncspwb03m9ankqww0s1yv2"))))
7682 (build-system pyproject-build-system)
7683 (arguments (list #:tests? #f)) ; No tests upstream.
7684 (native-inputs (list python-setuptools))
7685 (propagated-inputs (list python-pygobject))
7686 (home-page "https://github.com/sugarlabs/gwebsockets")
7687 (synopsis "GLib based websockets server")
7688 (description
7689 "This package provides a websocket server written in Python. It uses GIO
7690for network communication and hence it easily integrates with the GLib
7691mainloop.")
7692 (license license:asl2.0)))
7693
7694(define-public python-dpkt
7695 (package
7696 (name "python-dpkt")
7697 (version "1.9.8")
7698 (source
7699 (origin
7700 (method git-fetch)
7701 (uri (git-reference
7702 (url "https://github.com/kbandla/dpkt")
7703 (commit (string-append "v" version))))
7704 (file-name (git-file-name name version))
7705 (sha256
7706 (base32 "0dhy8l4sqfxqdda6lishb95g3v6hnw14l20ipqpzb6vaw1vf7mzj"))))
7707 (build-system pyproject-build-system)
7708 (arguments
7709 (list
7710 #:test-flags
7711 #~(list "--pyargs" "dpkt")))
7712 (native-inputs (list python-pytest python-pytest-cov python-setuptools))
7713 (home-page "https://github.com/kbandla/dpkt")
7714 (synopsis "Packet generator and parser for TCP/IP protocols")
7715 (description
7716 "The dpkt module is a fast, simple packet generator and parser for the
7717basic TCP/IP protocols.")
7718 (license license:bsd-3)))
7719
7720(define-public python-geventhttpclient
7721 (package
7722 (name "python-geventhttpclient")
7723 (version "2.3.3")
7724 (source (origin
7725 (method git-fetch)
7726 (uri (git-reference
7727 (url "https://github.com/geventhttpclient/geventhttpclient")
7728 (commit version)
7729 (recursive? #true)))
7730 (file-name (git-file-name name version))
7731 (sha256
7732 (base32
7733 "1ya0i0fbx054mfx5d1k75fcf64xzp7vva8lkwwzan41xbnc56nyj"))))
7734 (build-system pyproject-build-system)
7735 (arguments
7736 (list
7737 #:test-flags
7738 ;; Disable network tests.
7739 '(list "-k"
7740 (string-append "not test_client_simple"
7741 " and not test_client_ssl"
7742 " and not test_client_with_default_headers"
7743 " and not test_client_without_leading_slash"
7744 " and not test_download"
7745 " and not test_fail_invalid_ca_certificate"
7746 " and not test_httpbin_multipart"
7747 " and not test_multi_queries_greenlet_safe"
7748 " and not test_no_form_encode_header"
7749 " and not test_no_form_encoded_header"
7750 " and not test_request_with_headers"
7751 " and not test_response_context_manager"
7752 " and not test_urllib_request"))))
7753 (native-inputs (list nss-certs-for-test
7754 python-dpkt python-pytest python-requests
7755 python-setuptools python-wheel))
7756 (propagated-inputs (list python-brotli python-certifi python-gevent
7757 python-urllib3))
7758 (home-page "https://github.com/geventhttpclient/geventhttpclient")
7759 (synopsis "HTTP client library for gevent")
7760 (description "@code{python-geventhttpclient} is a high performance,
7761concurrent HTTP client library for python using @code{gevent}.")
7762 (license license:expat)))
7763
7764(define-public python-gevent-websocket
7765 (package
7766 (name "python-gevent-websocket")
7767 (version "0.10.1")
7768 (source
7769 (origin
7770 (method url-fetch)
7771 (uri (pypi-uri "gevent-websocket" version))
7772 (sha256
7773 (base32 "1c2zv2rahp1gil3cj66hfsqgy0n35hz9fny3ywhr2319d0lz7bky"))))
7774 (build-system pyproject-build-system)
7775 (arguments
7776 (list #:tests? #f)) ; no tests in PyPI or git
7777 (native-inputs
7778 (list python-setuptools
7779 python-wheel))
7780 (propagated-inputs
7781 (list python-gevent))
7782 (home-page "https://gitlab.com/noppo/gevent-websocket")
7783 (synopsis "Websocket handler for the gevent pywsgi server")
7784 (description
7785 "Websocket handler for the gevent pywsgi server, a Python network
7786library.
7787
7788Features include:
7789@itemize
7790@item integration on both socket level or using an abstract interface
7791@item RPC and PubSub framework using @acronym{WebSocket Application Messaging
7792Protocol, WAMP}
7793@item easily extendible using a simple WebSocket protocol plugin API
7794@end itemize")
7795 (license license:asl2.0)))
7796
7797(define-public python-requests-oauthlib
7798 (package
7799 (name "python-requests-oauthlib")
7800 (version "2.0.0")
7801 (source
7802 (origin
7803 (method git-fetch)
7804 (uri (git-reference (url
7805 "https://github.com/requests/requests-oauthlib")
7806 (commit (string-append "v" version))))
7807 (file-name (git-file-name name version))
7808 (sha256 (base32 "0i0vnanxqilnf2rgng7n96rl8fzq0dbcl3rpl7zkxj50kv66nqwl"))))
7809 (build-system pyproject-build-system)
7810 (arguments
7811 (list
7812 #:test-flags
7813 #~(list
7814 "--ignore=tests/test_core.py" ; requires network access.
7815 "--ignore=tests/examples/test_native_spa_pkce_auth0.py"
7816 "-k" "not test_fetch_access_token"))) ; flaky tests.
7817 (native-inputs
7818 (list python-requests-mock python-pytest python-setuptools))
7819 (propagated-inputs
7820 (list python-oauthlib python-requests))
7821 (home-page "https://github.com/requests/requests-oauthlib")
7822 (synopsis "OAuthlib authentication support for Requests")
7823 (description
7824 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
7825provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
7826 (license license:isc)))
7827
7828(define-public python-cachecontrol
7829 (package
7830 (name "python-cachecontrol")
7831 (version "0.14.1")
7832 (source
7833 (origin
7834 (method git-fetch)
7835 ;; Pypi does not have tests.
7836 (uri (git-reference
7837 (url "https://github.com/ionrock/cachecontrol")
7838 (commit (string-append "v" version))))
7839 (file-name (git-file-name name version))
7840 (sha256
7841 (base32
7842 "07ifs4dhahhsgj4vxgfl5ymnmb4my5l2wb8jiinn6fncszcfmr59"))))
7843 (build-system pyproject-build-system)
7844 (arguments
7845 ;; Versions > 0.11.6 depend on CherryPy for testing.
7846 ;; It's too much work to package CherryPy for now.
7847 `(#:tests? #f))
7848 (propagated-inputs
7849 (list python-filelock python-msgpack python-requests))
7850 (native-inputs
7851 (list python-flit-core))
7852 (home-page "https://github.com/ionrock/cachecontrol")
7853 (synopsis "The httplib2 caching algorithms for use with requests")
7854 (description "CacheControl is a port of the caching algorithms in
7855@code{httplib2} for use with @code{requests} session objects.")
7856 (license license:asl2.0)))
7857
7858(define-public python-betamax
7859 (package
7860 (name "python-betamax")
7861 (version "0.9.0")
7862 (source
7863 (origin
7864 (method url-fetch)
7865 (uri (pypi-uri "betamax" version))
7866 (sha256
7867 (base32
7868 "152zil1j4gl1whnldi08zwjr4z2bnlbd061kr3ipjs5wg4b6wcc2"))))
7869 (build-system pyproject-build-system)
7870 (arguments
7871 (list
7872 #:test-flags
7873 #~(list "-k" (string-join
7874 ;; Tests require network access to http://httpbin.org/get.
7875 (list "not test_creates_new_cassettes"
7876 "test_placeholders_work"
7877 "test_post_start_hook"
7878 "test_pre_stop_hook"
7879 "test_preplayback_hook"
7880 "test_prerecord_hook"
7881 "test_prerecord_ignoring_hook"
7882 "test_records_new_events_with_existing_cassette"
7883 "test_records_new_interaction"
7884 "test_records_new_interactions"
7885 "test_replaces_old_interactions"
7886 "test_replays_response_from_cassette"
7887 "test_requests_with_json_body"
7888 "test_saves_content_as_gzip"
7889 "test_unicode_is_saved_properly")
7890 " and not "))))
7891 (native-inputs
7892 (list nss-certs-for-test
7893 python-pytest
7894 python-setuptools))
7895 (propagated-inputs
7896 (list python-requests))
7897 (home-page "https://github.com/sigmavirus24/betamax")
7898 (synopsis "Record HTTP interactions with python-requests")
7899 (description
7900 "Betamax will record your test suite's HTTP interactions and replay them
7901during future tests. It is designed to work with python-requests.")
7902 (license license:expat)))
7903
7904(define-public python-betamax-matchers
7905 (package
7906 (name "python-betamax-matchers")
7907 (version "0.4.0")
7908 (source
7909 (origin
7910 (method git-fetch)
7911 (uri (git-reference
7912 (url "https://github.com/sigmavirus24/betamax_matchers")
7913 (commit version)))
7914 (file-name (git-file-name name version))
7915 (sha256
7916 (base32 "0lyg3r91hwfvavyi5k6sddcla37igigycfv1mx40c32byqwl6pq5"))))
7917 (build-system pyproject-build-system)
7918 (native-inputs (list python-pytest python-setuptools))
7919 (propagated-inputs (list python-betamax python-requests-toolbelt))
7920 (home-page "https://github.com/sigmavirus24/betamax_matchers")
7921 (synopsis "VCR imitation for python-requests")
7922 (description "@code{betamax-matchers} provides a set of Matchers for
7923Betamax.")
7924 (license license:asl2.0)))
7925
7926(define-public python-betamax-serializers
7927 (package
7928 (name "python-betamax-serializers")
7929 (version "0.2.1")
7930 (source
7931 (origin
7932 (method git-fetch)
7933 (uri (git-reference
7934 (url "https://gitlab.com/betamax/serializers")
7935 (commit version)))
7936 (file-name (git-file-name name version))
7937 (sha256
7938 (base32 "1p2l5w3vwvjacs2ndahgcjq55qb53i37p8mz1zh85pjxyszdyw2l"))))
7939 (build-system pyproject-build-system)
7940 (arguments (list #:tests? #f)) ; No tests.
7941 (native-inputs (list python-setuptools))
7942 (propagated-inputs (list python-betamax python-pyyaml))
7943 (synopsis "Set of third-party serializers for Betamax")
7944 (description
7945 "Betamax-Serializers are an experimental set of Serializers for Betamax
7946that may possibly end up in the main package.")
7947 (home-page "https://gitlab.com/betamax/serializers")
7948 (license license:asl2.0)))
7949
7950(define-public python-s3fs
7951 (package
7952 (name "python-s3fs")
7953 (version "2026.1.0")
7954 (source
7955 (origin
7956 (method url-fetch)
7957 (uri (pypi-uri "s3fs" version))
7958 (sha256
7959 (base32 "17fhx4qnpcwhrfckn27wdjvlxink1kcpaiganxij4fjmp7gm58xp"))))
7960 (build-system pyproject-build-system)
7961 ;; TODO: Many tests fail with "No such file or directory" raised by the
7962 ;; HTTP client.
7963 (arguments (list #:tests? #false))
7964 (native-inputs
7965 (list python-setuptools))
7966 (propagated-inputs
7967 (list python-aiobotocore
7968 python-aiohttp
7969 python-fsspec))
7970 (home-page "https://github.com/fsspec/s3fs/")
7971 (synopsis "Convenient filesystem interface over S3")
7972 (description "This package provides a convenient filesystem interface over
7973S3.")
7974 (license license:bsd-3)))
7975
7976(define-public python-s3transfer
7977 (package
7978 (name "python-s3transfer")
7979 (version "0.16.0")
7980 (source
7981 (origin
7982 (method url-fetch)
7983 (uri (pypi-uri "s3transfer" version))
7984 (sha256
7985 (base32 "087rmdwsn9drkh5rwwbfym5p8qvirc8gllnd54i7j9c04q9hz6cf"))))
7986 (build-system pyproject-build-system)
7987 (arguments
7988 (list
7989 ;; tests: 630 passed, 51 skipped
7990 #:test-flags
7991 #~(list "--numprocesses" (number->string (min 8 (parallel-job-count)))
7992 ;; Tests require networking.
7993 "--ignore" "tests/integration")))
7994 (native-inputs
7995 (list python-pytest
7996 python-pytest-xdist
7997 python-setuptools))
7998 (propagated-inputs
7999 (list python-botocore))
8000 (home-page "https://github.com/boto/s3transfer")
8001 (synopsis "Amazon S3 Transfer Manager")
8002 (description
8003 "S3transfer is a Python library for managing Amazon S3 transfers.")
8004 (license license:asl2.0)))
8005
8006(define-public python-flask-restful
8007 (package
8008 (name "python-flask-restful")
8009 (version "0.3.10")
8010 (source
8011 (origin
8012 (method url-fetch)
8013 (uri (pypi-uri "Flask-RESTful" version))
8014 (sha256
8015 (base32
8016 "0dzckjjz3aw8nmisr5g9mnv02s2nqlhblykr9ydqzpr703pz4jpy"))))
8017 (build-system pyproject-build-system)
8018 (arguments
8019 ;; See <https://github.com/flask-restful/flask-restful/issues/980>.
8020 (list #:tests? #f))
8021 (propagated-inputs
8022 (list python-aniso8601 python-flask python-pytz))
8023 (native-inputs
8024 (list python-blinker
8025 python-mock
8026 python-pytest
8027 python-setuptools
8028 python-wheel))
8029 (home-page "https://github.com/flask-restful/flask-restful/")
8030 (synopsis "Flask module for creating REST APIs")
8031 (description
8032 "This package contains a Flask module for creating REST APIs.")
8033 (license license:bsd-3)))
8034
8035(define-public python-flask-sqlalchemy
8036 (package
8037 (name "python-flask-sqlalchemy")
8038 (version "3.1.1")
8039 (source (origin
8040 (method url-fetch)
8041 (uri (pypi-uri "flask_sqlalchemy" version))
8042 (sha256
8043 (base32
8044 "04l3dfivznlpvk9p9f20zdbyxl869k42z2w7glddlbc0h6w8pdp4"))))
8045 (build-system pyproject-build-system)
8046 (arguments
8047 (list
8048 #:test-flags
8049 #~(list "-k" (string-append "not test_explicit_table[db2]"
8050 " and not test_explicit_table[db4]"))))
8051 (native-inputs
8052 (list python-flit-core
8053 python-pytest))
8054 (propagated-inputs
8055 (list python-flask
8056 python-sqlalchemy-2))
8057 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
8058 (synopsis "Module adding SQLAlchemy support to your Flask application")
8059 (description
8060 "This package adds SQLAlchemy support to your Flask application.")
8061 (license license:bsd-3)))
8062
8063(define-public python-flask-restful-swagger
8064 (package
8065 (name "python-flask-restful-swagger")
8066 (version "0.20.1")
8067 ;; XXX: Unbundle minified javascript.
8068 (source
8069 (origin
8070 (method git-fetch)
8071 (uri (git-reference
8072 (url "https://github.com/rantav/flask-restful-swagger")
8073 (commit version)))
8074 (file-name (git-file-name name version))
8075 (sha256
8076 (base32 "1ppdwn25ijf8b3zchxkvwj4ipc68v3p522i8mm51jm0w6mg5bvsh"))))
8077 (build-system pyproject-build-system)
8078 (arguments (list #:tests? #f)) ; No tests.
8079 (native-inputs (list python-setuptools))
8080 (propagated-inputs (list python-flask-restful python-six))
8081 (home-page "https://github.com/rantav/flask-restful-swagger")
8082 (synopsis "Extract Swagger specs from Flask-Restful projects")
8083 (description "This package lets you extract Swagger API documentation
8084specs from your Flask-Restful projects.")
8085 (license license:expat)))
8086
8087(define-public python-htmlmin
8088 (package
8089 (name "python-htmlmin")
8090 (version "0.1.12")
8091 (source
8092 (origin
8093 (method url-fetch)
8094 (uri (pypi-uri "htmlmin" version))
8095 (sha256
8096 (base32
8097 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
8098 (build-system pyproject-build-system)
8099 (arguments
8100 (list #:tests? #f)) ; no tests
8101 (native-inputs (list python-setuptools))
8102 (home-page "https://htmlmin.readthedocs.org/en/latest/")
8103 (synopsis "HTML minifier")
8104 (description "@code{htmlmin} is an HTML minifier that just works.
8105It comes with safe defaults and easily configurable options.")
8106 (license license:bsd-3)))
8107
8108;; XXX: Forked renamed and updated version.
8109(define-public python-htmlmin2
8110 (package/inherit python-htmlmin
8111 (name "python-htmlmin2")
8112 (version "0.1.13")
8113 (source
8114 (origin
8115 (method git-fetch)
8116 (uri (git-reference
8117 (url "https://github.com/wilhelmer/htmlmin")
8118 (commit (string-append "v" version))))
8119 (file-name (git-file-name name version))
8120 (sha256
8121 (base32 "1y7mcx8d451hwa1wrg2lffg7ccdy3w5m7xwb5xqp8h2852pypfh2"))))
8122 (build-system pyproject-build-system)
8123 (arguments (list #:test-backend #~'unittest))
8124 (native-inputs (list python-setuptools))
8125 (home-page "https://github.com/wilhelmer/htmlmin")
8126 (description
8127 "@code{htmlmin2} is an HTML minifier that just works. It comes with safe
8128defaults and easily configurable options. This variant is an updated fork of
8129the original @code{python-htmlmin}.")
8130 (license license:bsd-3)))
8131
8132(define-public python-flask-htmlmin
8133 (package
8134 (name "python-flask-htmlmin")
8135 (version "3.0.0")
8136 (source
8137 (origin
8138 (method git-fetch)
8139 (uri (git-reference
8140 (url "https://github.com/hamidfzm/Flask-HTMLmin")
8141 (commit (string-append "v" version))))
8142 (file-name (git-file-name name version))
8143 (sha256
8144 (base32 "0ybqssnqwa9zgv61azp5r1grgnq28ypfhr80p9rp61x2z0y0zl32"))))
8145 (build-system pyproject-build-system)
8146 (native-inputs (list python-pytest python-setuptools))
8147 (propagated-inputs (list python-cssmin python-flask python-htmlmin2))
8148 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
8149 (synopsis "HTML response minifier for Flask")
8150 (description
8151 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
8152 (license license:bsd-3)))
8153
8154(define-public python-jsmin
8155 (package
8156 (name "python-jsmin")
8157 (version "3.0.1")
8158 (source
8159 (origin
8160 (method url-fetch)
8161 (uri (pypi-uri "jsmin" version))
8162 (sha256
8163 (base32
8164 "1z1brjsvni0260bypldkl8a05sgp0qk18x560zl44igr3q99m5f0"))))
8165 (build-system pyproject-build-system)
8166 (arguments (list #:test-backend #~'unittest))
8167 (native-inputs
8168 (list python-setuptools))
8169 (home-page "https://github.com/tikitu/jsmin/")
8170 (synopsis "Python JavaScript minifier")
8171 (description
8172 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
8173on the command line.")
8174 (license license:expat)))
8175
8176(define-public python-flask-login
8177 (package
8178 (name "python-flask-login")
8179 (version "0.6.3")
8180 (source
8181 (origin
8182 (method git-fetch)
8183 (uri (git-reference
8184 (url "https://github.com/maxcountryman/flask-login")
8185 (commit version)))
8186 (file-name (git-file-name name version))
8187 (sha256
8188 (base32 "0wk3dni5qssmbn8ii3hsh89qa3kwr97i92k27bzgsgxvvsfwwzja"))))
8189 (build-system pyproject-build-system)
8190 (propagated-inputs
8191 (list python-flask))
8192 (native-inputs
8193 ;; For tests.
8194 (list python-blinker
8195 python-mock
8196 python-pytest
8197 python-semantic-version
8198 python-setuptools
8199 python-werkzeug
8200 python-wheel))
8201 (home-page "https://github.com/maxcountryman/flask-login")
8202 (synopsis "User session management for Flask")
8203 (description
8204 "@code{Flask-Login} provides user session management for Flask. It
8205handles the common tasks of logging in, logging out, and remembering your
8206users' sessions over extended periods of time.")
8207 (license license:expat)))
8208
8209(define-public python-oauth2client
8210 (package
8211 (name "python-oauth2client")
8212 (version "4.1.3")
8213 (source
8214 (origin
8215 (method git-fetch)
8216 (uri (git-reference
8217 (url "https://github.com/google/oauth2client/")
8218 (commit (string-append "v" version))))
8219 (file-name (git-file-name name version))
8220 (sha256
8221 (base32 "0xm19dv5kmi82zzrx3d4mp326irr3x37q818hlspz514dzjq2ad1"))))
8222 (build-system pyproject-build-system)
8223 (arguments
8224 (list #:tests? #f))
8225 (native-inputs
8226 (list python-setuptools))
8227 (propagated-inputs
8228 (list python-httplib2
8229 python-pyasn1
8230 python-pyasn1-modules
8231 python-pyparsing
8232 python-rsa
8233 python-six))
8234 (home-page "https://github.com/google/oauth2client/")
8235 (synopsis "OAuth 2.0 client library")
8236 (description "@code{python-oauth2client} provides an OAuth 2.0 client
8237library for Python")
8238 (license license:asl2.0)))
8239
8240(define-public python-authlib
8241 (package
8242 (name "python-authlib")
8243 (version "1.5.1")
8244 (source
8245 (origin
8246 (method url-fetch)
8247 (uri (pypi-uri "authlib" version))
8248 (sha256
8249 (base32 "0blpvz2v2r8yvsgm1yr3n61mhwxvh1b0kyf2rp0i4wv6n3n8bg2w"))))
8250 (build-system pyproject-build-system)
8251 ;; No tests target.
8252 (arguments (list #:tests? #false))
8253 (propagated-inputs
8254 (list python-cryptography
8255 python-django
8256 python-flask
8257 python-httpx
8258 python-requests
8259 python-sqlalchemy-2
8260 python-starlette
8261 python-werkzeug))
8262 (native-inputs (list python-pytest python-setuptools python-wheel))
8263 (home-page "https://pypi.org/project/Authlib/1")
8264 (synopsis "Build OAuth and OpenID Connect servers and clients")
8265 (description
8266 "This is a Python library for building OAuth and OpenID Connect servers
8267and clients.")
8268 (license license:bsd-3)))
8269
8270(define-public python-flask-oidc
8271 (package
8272 (name "python-flask-oidc")
8273 (version "2.3.1")
8274 (source
8275 (origin
8276 (method url-fetch)
8277 (uri (pypi-uri "flask_oidc" version))
8278 (sha256
8279 (base32
8280 "1200xhqiqlqfmrq54v2p6cf3nny86njjw8r7sk5j59hlk9a683zk"))))
8281 (build-system pyproject-build-system)
8282 (propagated-inputs
8283 (list python-authlib
8284 python-blinker
8285 python-flask
8286 python-requests
8287 python-responses))
8288 (native-inputs
8289 (list python-pytest python-poetry-core))
8290 (home-page "https://github.com/puiterwijk/flask-oidc")
8291 (synopsis "OpenID Connect extension for Flask")
8292 (description "@code{python-flask-oidc} provides an OpenID Connect extension
8293for Flask.")
8294 (license license:bsd-2)))
8295
8296(define-public python-webassets
8297 (package
8298 (name "python-webassets")
8299 (version "3.0.0")
8300 (source
8301 (origin
8302 (method git-fetch)
8303 (uri (git-reference
8304 (url "https://github.com/miracle2k/webassets")
8305 (commit version)))
8306 (file-name (git-file-name name version))
8307 (sha256
8308 (base32 "11hxvdqw86q6r665iryjzwx21ys8jh2c63mw016ldr6j49l0zyyh"))))
8309 (build-system pyproject-build-system)
8310 (propagated-inputs (list python-pyyaml python-zope-dottedname))
8311 (native-inputs (list python-hatchling python-pytest))
8312 (home-page "https://github.com/miracle2k/webassets")
8313 (synopsis "Media asset management")
8314 (description
8315 "This package provides utilities to merge, minify and compress Javascript
8316and CSS files,supporting a variety of different filters, including YUI, jsmin,
8317jspacker or CSS tidy. It also supports URL rewriting in CSS files.")
8318 (license license:bsd-2)))
8319
8320(define-public python-cssmin
8321 (package
8322 (name "python-cssmin")
8323 (version "0.2.0")
8324 (source
8325 (origin
8326 (method git-fetch)
8327 (uri (git-reference
8328 (url "https://github.com/zacharyvoase/cssmin")
8329 (commit (string-append "v" version))))
8330 (file-name (git-file-name name version))
8331 (sha256
8332 (base32 "04bzpal6j26pjjjf3p7iq6g2wcr61j4g0ygqz6h847h4hsyah9qg"))))
8333 (build-system pyproject-build-system)
8334 (arguments (list #:tests? #f)) ; No tests.
8335 (native-inputs (list python-setuptools))
8336 (home-page "https://github.com/zacharyvoase/cssmin")
8337 (synopsis "Python port of the YUI CSS Compressor")
8338 (description "Python port of the YUI CSS Compressor.")
8339 (license (list license:expat license:bsd-3))))
8340
8341(define-public python-elastic-transport
8342 (package
8343 (name "python-elastic-transport")
8344 (version "9.1.0")
8345 (source
8346 (origin
8347 (method url-fetch)
8348 (uri (pypi-uri "elastic_transport" version))
8349 (sha256
8350 (base32 "0g879z8rqrfbwkxsm6xcycjha1swl7gdgs6m0y0j1zmh4m5f940m"))))
8351 (build-system pyproject-build-system)
8352 (arguments
8353 (list
8354 #:test-flags
8355 ;; Deselect failing tests (mostly due to network not reachable)
8356 #~(list "-k"
8357 (string-append
8358 "not .badssl.com"
8359 " and not test_assert_fingerprint_in_cert_chain_failure"))
8360 #:phases
8361 #~(modify-phases %standard-phases
8362 (add-after 'unpack 'fix-pytest-config
8363 (lambda _
8364 ;; Drop test coverage requirements.
8365 (substitute* "setup.cfg"
8366 (("--cov(-[^ ]*)?=[^ ]*") "\n")))))))
8367 (propagated-inputs (list python-certifi python-urllib3))
8368 (native-inputs (list nss-certs-for-test
8369 python-aiohttp
8370 ;; python-furo
8371 python-httpx
8372 python-opentelemetry-api
8373 python-opentelemetry-sdk
8374 python-orjson
8375 python-pytest
8376 python-pytest-asyncio-0.26
8377 ;; python-pytest-cov
8378 python-pytest-httpbin
8379 python-pytest-httpserver
8380 python-pytest-mock
8381 python-requests
8382 python-respx ;test
8383 python-setuptools
8384 ;; python-sphinx
8385 ;; python-sphinx-autodoc-typehints
8386 python-trustme
8387 python-wheel))
8388 (home-page "https://github.com/elastic/elastic-transport-python")
8389 (synopsis "Common library for Python Elastic client libraries")
8390 (description
8391 "This library was lifted from @code{elasticsearch-py} and then transformed to
8392be used across all Elastic services rather than only Elasticsearch. It
8393provides transport classes and utilities shared among Python Elastic client
8394libraries.")
8395 ;; Apache-2.0 in setup.py and LICENSE file.
8396 (license license:asl2.0)))
8397
8398(define-public python-elasticsearch
8399 (package
8400 (name "python-elasticsearch")
8401 (version "9.1.1")
8402 (source
8403 (origin
8404 (method git-fetch) ; no tests in PyPI release
8405 (uri (git-reference
8406 (url "https://github.com/elastic/elasticsearch-py")
8407 (commit (string-append "v" version))))
8408 (file-name (git-file-name name version))
8409 (sha256
8410 (base32 "015x73y84nyigcyg00lh32p2pfrqf834fr7clfnzymgzrrxa73jf"))))
8411 (build-system pyproject-build-system)
8412 (native-inputs
8413 (list nss-certs-for-test
8414 python-aiohttp
8415 python-dateutil
8416 python-mock
8417 python-orjson
8418 python-pytest
8419 python-pytest-asyncio
8420 python-pytest-cov
8421 python-pytz
8422 python-pyyaml
8423 python-requests
8424 python-hatchling))
8425 (propagated-inputs
8426 (list python-certifi
8427 python-elastic-transport))
8428 (home-page "https://github.com/elastic/elasticsearch-py")
8429 (synopsis "Low-level client for Elasticsearch")
8430 (description "Official low-level client for Elasticsearch. Its goal is to
8431provide common ground for all Elasticsearch-related code in Python; because of
8432this it tries to be opinion-free and very extendable.")
8433 ;; Apache-2.0 in setup.py and LICENSE file.
8434 (license license:asl2.0)))
8435
8436(define-public python-engineio
8437 (package
8438 (name "python-engineio")
8439 (version "4.12.2")
8440 (source
8441 (origin
8442 (method url-fetch)
8443 (uri (pypi-uri "python_engineio" version))
8444 (sha256
8445 (base32
8446 "1ynyf3n29biwkm6nwzzwzhr4m19lsir1x5azxq2nl7xyw7zi5rz7"))))
8447 (build-system pyproject-build-system)
8448 (arguments
8449 (list
8450 #:test-flags
8451 #~(list "-k"
8452 "not test_static_file_routing and not test_static_files")))
8453 (native-inputs
8454 (list python-pytest
8455 python-pytest-asyncio
8456 python-setuptools
8457 python-tornado))
8458 (propagated-inputs
8459 (list python-aiohttp
8460 python-requests
8461 python-simple-websocket
8462 python-websocket-client))
8463 (home-page "https://github.com/miguelgrinberg/python-engineio/")
8464 (synopsis "Engine.IO server")
8465 (description "This package provides a Python implementation of the
8466@code{Engine.IO} realtime client and server.")
8467 (license license:expat)))
8468
8469(define-public python-ephemeral-port-reserve
8470 (package
8471 (name "python-ephemeral-port-reserve")
8472 (version "1.1.4")
8473 (source
8474 (origin
8475 (method git-fetch) ;no tests in PyPI archvie
8476 (uri (git-reference
8477 (url "https://github.com/Yelp/ephemeral-port-reserve")
8478 (commit (string-append "v" version))))
8479 (file-name (git-file-name name version))
8480 (sha256
8481 (base32 "1ifmf5zcw7mhbm73awmf5jwc4rw8lhk81mn4zp797lwkysjm38s7"))))
8482 (build-system pyproject-build-system)
8483 (native-inputs
8484 (list python-pytest
8485 python-setuptools
8486 python-wheel))
8487 (home-page "https://github.com/Yelp/ephemeral-port-reserve/")
8488 (synopsis "Find an unused port, reliably")
8489 (description
8490 "Bind to an ephemeral port, force it into the TIME_WAIT state, and unbind
8491it.")
8492 (license license:expat)))
8493
8494(define-public python-flask-migrate
8495 (package
8496 (name "python-flask-migrate")
8497 (version "4.1.0")
8498 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
8499 (source (origin
8500 (method git-fetch)
8501 (uri (git-reference (url home-page)
8502 (commit (string-append "v" version))))
8503 (file-name (git-file-name name version))
8504 (sha256
8505 (base32
8506 "09qw1hhyssa5gahm199x67d55c55m3k9m23xp2bdacwsiv8jw57g"))))
8507 (build-system pyproject-build-system)
8508 (propagated-inputs
8509 (list python-flask python-alembic python-flask-sqlalchemy))
8510 (native-inputs
8511 (list python-pytest python-setuptools python-wheel))
8512 (synopsis "SQLAlchemy database migrations for Flask programs using
8513Alembic")
8514 (description "This package contains SQLAlchemy database migration tools
8515for Flask programs that are using @code{python-alembic}.")
8516 (license license:expat)))
8517
8518(define-public python-genshi
8519 (package
8520 (name "python-genshi")
8521 (version "0.7.10")
8522 (source
8523 (origin
8524 (method git-fetch)
8525 (uri (git-reference
8526 (url "https://github.com/edgewall/genshi")
8527 (commit version)))
8528 (file-name (git-file-name name version))
8529 (sha256
8530 (base32 "1dmf0ggp0s3371jv483kjriw9jscawxcik6q70a0wqjdfh5383i6"))))
8531 (build-system pyproject-build-system)
8532 (arguments (list #:test-backend #~'unittest))
8533 (native-inputs (list python-setuptools))
8534 (propagated-inputs (list python-six))
8535 (home-page "https://genshi.edgewall.org/")
8536 (synopsis "Toolkit for generation of output for the web")
8537 (description "Genshi is a Python library that provides an integrated set
8538of components for parsing, generating, and processing HTML, XML or other
8539textual content for output generation on the web.")
8540 (license license:bsd-3)))
8541
8542(define-public python-flask-principal
8543 (package
8544 (name "python-flask-principal")
8545 (version "0.4.0")
8546 (source
8547 (origin
8548 (method git-fetch)
8549 (uri (git-reference
8550 (url "https://github.com/pallets-eco/flask-principal")
8551 (commit version)))
8552 (file-name (git-file-name name version))
8553 (sha256
8554 (base32 "0hcqcj768inmyfsw1y2vk6pa9p22dh138ll809rhpz9vjz6spnqk"))))
8555 (build-system pyproject-build-system)
8556 (propagated-inputs (list python-blinker))
8557 (native-inputs (list python-flask python-pynose python-setuptools))
8558 (home-page "https://github.com/pallets-eco/flask-principal")
8559 (synopsis "Identity management for Flask")
8560 (description
8561 "@code{flask_principal} is a identity management library for Flask. It
8562supports managing both authentication and authorization data in a thread-local
8563variable.")
8564 (license license:expat)))
8565
8566(define-public python-flask-httpauth
8567 (package
8568 (name "python-flask-httpauth")
8569 (version "4.8.0")
8570 (source
8571 (origin
8572 (method url-fetch)
8573 (uri (pypi-uri "Flask-HTTPAuth" version))
8574 (sha256
8575 (base32
8576 "0yh9fn6pak64has89pcy03f1cn198vkil872y5jjr53kph2qlmk6"))))
8577 (build-system pyproject-build-system)
8578 (propagated-inputs (list python-flask))
8579 (native-inputs
8580 (list nss-certs-for-test
8581 python-pytest
8582 python-setuptools
8583 python-wheel))
8584 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
8585 (synopsis "Basic and Digest HTTP authentication for Flask routes")
8586 (description "@code{flask_httpauth} provides Basic and Digest HTTP
8587authentication for Flask routes.")
8588 (license license:expat)))
8589
8590(define-public python-uritemplate
8591 (package
8592 (name "python-uritemplate")
8593 (version "4.2.0")
8594 (source
8595 (origin
8596 (method url-fetch)
8597 (uri (pypi-uri "uritemplate" version))
8598 (sha256
8599 (base32
8600 "03lxxkk0kjn6z7z1f9hqvsaqfrny1qds7vi36f35b2c7h38jw328"))))
8601 (build-system pyproject-build-system)
8602 (native-inputs (list python-pytest python-setuptools))
8603 (home-page "https://uritemplate.readthedocs.io/")
8604 (synopsis "Library to deal with URI Templates")
8605 (description "@code{uritemplate} provides Python library to deal with URI
8606Templates.")
8607 ;; The software is made available under the terms of *either* of the
8608 ;; licenses found in LICENSE.APACHE or LICENSE.BSD. Contributions
8609 ;; are made under *both* licenses (excerpt from the LICENSE file).
8610 (license (list license:bsd-2 license:asl2.0))))
8611
8612(define-public python-uritemplate-3
8613 (package
8614 (inherit python-uritemplate)
8615 (name "python-uritemplate")
8616 (version "3.0.1")
8617 (source (origin
8618 (method url-fetch)
8619 (uri (pypi-uri "uritemplate" version))
8620 (sha256
8621 (base32 "1bkwmgr0ia9gcn4bszs2xlvml79f0bi2s4a87xg22ky9rq8avy2s"))))))
8622
8623(define-public python-publicsuffix2
8624 (package
8625 (name "python-publicsuffix2")
8626 (version "2.2019-12-21")
8627 (source
8628 (origin
8629 (method git-fetch)
8630 (uri (git-reference
8631 (url "https://github.com/pombredanne/python-publicsuffix2")
8632 (commit (string-append "release-" version))))
8633 (file-name (git-file-name name version))
8634 (sha256
8635 (base32 "1dkvfvl0izq9hqzilnw8ipkbgjs9xyad9p21i3864hzinbh0wp9r"))))
8636 (build-system pyproject-build-system)
8637 (arguments
8638 (list
8639 #:tests? #f ;the test suite requires network access
8640 #:phases
8641 #~(modify-phases %standard-phases
8642 (add-after 'unpack 'ignore-maintainer-inputs
8643 (lambda _
8644 ;; Comment out a demand for python-requests, which is used only by
8645 ;; the unused ‘update_psl’ helper command.
8646 (substitute* "setup.py"
8647 (("'requests " match)
8648 (format #f "# ~a" match))))))))
8649 (native-inputs (list python-setuptools))
8650 (home-page "https://github.com/pombredanne/python-publicsuffix2")
8651 (synopsis
8652 "Get a public suffix for a domain name using the Public Suffix List")
8653 (description
8654 "Get a public suffix for a domain name using the Public Suffix List.
8655Forked from and using the same API as the publicsuffix package.")
8656 (license (list license:expat license:mpl2.0))))
8657
8658(define-public python-werkzeug
8659 (package
8660 (name "python-werkzeug")
8661 (version "3.1.3")
8662 (source
8663 (origin
8664 (method url-fetch)
8665 (uri (pypi-uri "werkzeug" version))
8666 (sha256
8667 (base32
8668 "0ij7si3aa3ykac7k7fz481h4majqqwn2iqwhjxkji4y18plkqwk0"))))
8669 (build-system pyproject-build-system)
8670 (arguments
8671 (list
8672 #:test-flags
8673 ;; Test requiring networking setup.
8674 #~(list "--ignore=tests/test_serving.py"
8675 "--deselect=tests/test_debug.py::test_basic"
8676 "--deselect=tests/test_exceptions.py::test_response_body"
8677 "--deselect=tests/middleware/test_http_proxy.py::test_http_proxy")))
8678 (native-inputs
8679 (list python-flit-core
8680 python-pytest
8681 python-watchdog
8682 python-ephemeral-port-reserve
8683 python-pytest-timeout
8684 python-pytest-xprocess))
8685 (propagated-inputs
8686 (list python-markupsafe
8687 python-requests))
8688 (home-page "https://palletsprojects.com/p/werkzeug/")
8689 (synopsis "Utilities for WSGI applications")
8690 (description "One of the most advanced WSGI utility modules. It includes a
8691powerful debugger, full-featured request and response objects, HTTP utilities to
8692handle entity tags, cache control headers, HTTP dates, cookie handling, file
8693uploads, a powerful URL routing system and a bunch of community-contributed
8694addon modules.")
8695 (license license:x11)))
8696
8697(define-public python-werkzeug-1.0
8698 (package
8699 (inherit python-werkzeug)
8700 (version "1.0.1")
8701 (source (origin
8702 (method url-fetch)
8703 (uri (pypi-uri "Werkzeug" version))
8704 (sha256
8705 (base32
8706 "0z74sa1xw5h20yin9faj0vvdbq713cgbj84klc72jr9nmpjv303c"))
8707 (patches (search-patches "python-werkzeug-tests.patch"))))
8708 (arguments
8709 (list
8710 #:phases
8711 '(modify-phases %standard-phases
8712 (add-after 'unpack 'ignore-warnings
8713 (lambda _
8714 (substitute* "setup.cfg"
8715 ((" error.*") "")))))))
8716 (propagated-inputs
8717 (list python-requests))
8718 (native-inputs
8719 (list python-pytest python-pytest-timeout python-setuptools
8720 python-wheel))))
8721
8722(define-public python-bottle
8723 (package
8724 (name "python-bottle")
8725 (version "0.13.4")
8726 (source
8727 (origin
8728 (method url-fetch)
8729 (uri (pypi-uri "bottle" version))
8730 (sha256
8731 (base32 "0irz5i3h73pqz0ssgp3yk12zx33q7lrlh8p0in9jgchjgqr7hzkq"))))
8732 (build-system pyproject-build-system)
8733 (native-inputs (list python-pytest python-setuptools))
8734 (home-page "https://bottlepy.org/")
8735 (synopsis "WSGI framework for small web-applications")
8736 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
8737 (license license:expat)))
8738
8739(define-public python-wtforms
8740 (package
8741 (name "python-wtforms")
8742 (version "3.1.2")
8743 (source
8744 (origin
8745 (method url-fetch)
8746 (uri (pypi-uri "wtforms" version))
8747 (sha256
8748 (base32 "1fblnkzvs6339glwx8bskdjy7nhn2ap90y9g6b399713sy063mzq"))))
8749 (build-system pyproject-build-system)
8750 (native-inputs (list python-hatchling python-pytest))
8751 (propagated-inputs (list python-babel python-email-validator
8752 python-markupsafe))
8753 (home-page "https://wtforms.readthedocs.io/")
8754 (synopsis
8755 "Form validation and rendering library for Python web development")
8756 (description
8757 "WTForms is a flexible forms validation and rendering library
8758for Python web development. It is very similar to the web form API
8759available in Django, but is a standalone package.")
8760 (license license:bsd-3)))
8761
8762(define-public python-wtforms-sqlalchemy
8763 (package
8764 (name "python-wtforms-sqlalchemy")
8765 (version "0.4.1")
8766 (source
8767 (origin
8768 (method url-fetch)
8769 (uri (pypi-uri "WTForms-SQLAlchemy" version))
8770 (sha256
8771 (base32 "1nx4x0ifanlbrzh3f9ns8ihnchlkzf54ilvqmgcgcz2j72vm43rp"))))
8772 (build-system pyproject-build-system)
8773 (native-inputs (list python-pytest python-setuptools python-wheel))
8774 (propagated-inputs (list python-sqlalchemy python-wtforms))
8775 (home-page "https://github.com/wtforms/wtforms-sqlalchemy/")
8776 (synopsis "SQLAlchemy tools for WTForms")
8777 (description
8778 "WTForms-SQLAlchemy is a fork of the @code{wtforms.ext.sqlalchemy}
8779package from WTForms. The package has been renamed to
8780@code{wtforms_sqlalchemy} but otherwise should function the same as
8781@code{wtforms.ext.sqlalchemy} did.")
8782 (license license:bsd-3)))
8783
8784(define-public python-urlgrabber
8785 (package
8786 (name "python-urlgrabber")
8787 (version "4.1.0")
8788 (source
8789 (origin
8790 (method url-fetch)
8791 (uri (pypi-uri "urlgrabber" version))
8792 (sha256
8793 (base32 "0fg16zlw49cw7pjq9dhpc5vd35d5zz1mlki55m464qxfmfpzhnh7"))))
8794 (build-system pyproject-build-system)
8795 (arguments
8796 (list
8797 #:tests? #f ; Most tests require network access.
8798 #:phases
8799 #~(modify-phases %standard-phases
8800 (replace 'check
8801 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
8802 (when tests?
8803 (invoke "python" "test/runtests.py")))))))
8804 (native-inputs (list python-setuptools))
8805 (propagated-inputs
8806 (list python-pycurl python-setuptools python-six))
8807 (home-page "http://urlgrabber.baseurl.org/") ; no HTTPS
8808 (synopsis "High-level cross protocol url-grabber")
8809 (description
8810 "@code{urlgrabber} is a library that unifies access to files available on
8811the web, FTP or locally. It supports HTTP, FTP and file:// protocols, it
8812supports features like HTTP keep-alive, reget, throttling and more.")
8813 (license license:lgpl2.1+)))
8814
8815(define-public python-pycares
8816 (package
8817 (name "python-pycares")
8818 (version "4.11.0")
8819 (source
8820 (origin
8821 (method git-fetch)
8822 (uri (git-reference
8823 (url "https://github.com/saghul/pycares")
8824 (commit (string-append "v" version))))
8825 (file-name (git-file-name name version))
8826 (sha256
8827 (base32 "18syxp9bpm70zfiw427p7cpp6wg0ybrw6b32c1zvdp2i8jgd82xl"))
8828 (snippet #~(begin
8829 (rmdir "deps/c-ares")))))
8830 (build-system pyproject-build-system)
8831 (arguments
8832 (list
8833 ;; XXX: Half of the tests require internet access
8834 ;; There is currently no markers to avoid running them.
8835 #:tests? #f
8836 #:phases
8837 #~(modify-phases %standard-phases
8838 (add-after 'unpack 'configure-system-lib
8839 (lambda _
8840 (setenv "PYCARES_USE_SYSTEM_LIB" "1"))))))
8841 (native-inputs (list python-pytest python-setuptools))
8842 (inputs (list c-ares))
8843 (propagated-inputs (list python-cffi))
8844 (home-page "https://github.com/saghul/pycares")
8845 (synopsis "Python interface for @code{c-ares}")
8846 (description
8847 "@code{pycares} is a Python module which provides an interface to
8848@code{c-ares}, a C library that performs DNS requests and name resolutions
8849asynchronously.")
8850 (license license:expat)))
8851
8852(define-public python-yarl
8853 (package
8854 (name "python-yarl")
8855 (version "1.18.3")
8856 (source
8857 (origin
8858 (method url-fetch)
8859 (uri (pypi-uri "yarl" version))
8860 (sha256
8861 (base32
8862 "1qfj6kvdxr8bzka4lp0bh0xfgr5mzx7zzvj2jb4vcxxzbk20265c"))))
8863 (build-system pyproject-build-system)
8864 (arguments
8865 (list
8866 #:test-flags '(list "--ignore-glob=tests/test_*_benchmarks.py")
8867 #:phases
8868 '(modify-phases %standard-phases
8869 (add-after 'unpack 'patch-build-system
8870 (lambda _
8871 ;; XXX: I don't know how to tell it to build the extensions in
8872 ;; place.
8873 (substitute* "packaging/pep517_backend/_backend.py"
8874 (("build_inplace=False") "build_inplace=True")))))))
8875 (native-inputs
8876 (list python-covdefaults
8877 python-cython
8878 python-expandvars
8879 python-pytest
8880 python-pytest-cov
8881 python-pytest-xdist
8882 python-setuptools
8883 python-tomli
8884 python-wheel))
8885 (propagated-inputs
8886 (list python-packaging python-idna python-multidict python-propcache))
8887 (home-page "https://github.com/aio-libs/yarl/")
8888 (synopsis "Yet another URL library")
8889 (description "@code{yarl} module provides handy @code{URL} class
8890for URL parsing and changing.")
8891 (license license:asl2.0)))
8892
8893(define-public python-canvasapi
8894 (package
8895 (name "python-canvasapi")
8896 (version "3.4.0")
8897 (source (origin
8898 (method git-fetch)
8899 (uri (git-reference
8900 (url "https://github.com/ucfopen/canvasapi")
8901 (commit (string-append "v" version))))
8902 (file-name (git-file-name name version))
8903 (sha256
8904 (base32
8905 "017gashyd4avxzlz3imwn18vmfd0cjyhbm063isra3d2wk3ivrkx"))))
8906 (build-system pyproject-build-system)
8907 (propagated-inputs (list python-arrow python-pytz python-requests))
8908 (native-inputs (list python-pytest
8909 python-requests-mock
8910 python-setuptools
8911 python-urllib3))
8912 (home-page "https://github.com/ucfopen/canvasapi")
8913 (synopsis "API wrapper for the Canvas LMS")
8914 (description
8915 "CanvasAPI is a Python library for accessing Instructure’s Canvas LMS API.
8916The library enables developers to programmatically manage Canvas courses,
8917users, gradebooks, and more.")
8918 (license license:expat)))
8919
8920(define-public python-google
8921 (package
8922 (name "python-google")
8923 (version "3.0.0")
8924 (source
8925 (origin
8926 (method url-fetch)
8927 (uri (pypi-uri "google" version))
8928 (sha256
8929 (base32 "1gncv3l11za0mpxvmpaf5n5j3jzp282rz62yml4ha4z55q930d8l"))))
8930 (build-system pyproject-build-system)
8931 (arguments (list #:tests? #f)) ;There are no tests.
8932 (native-inputs (list python-setuptools))
8933 (propagated-inputs (list python-beautifulsoup4))
8934 (home-page "https://breakingcode.wordpress.com/")
8935 (synopsis "Python bindings to the Google search engine")
8936 (description
8937 "This package provides Python bindings for using the Google search
8938engine. Its module is called @code{googlesearch}.")
8939 (license license:bsd-3)))
8940
8941(define-public python-google-api-client
8942 (package
8943 (name "python-google-api-client")
8944 (version "2.187.0")
8945 (source
8946 (origin
8947 (method git-fetch)
8948 (uri (git-reference
8949 (url "https://github.com/google/google-api-python-client")
8950 (commit (string-append "v" version))))
8951 (file-name (git-file-name name version))
8952 (sha256
8953 (base32 "09vq5d32avri0gl8c7nn5dv2xds1jzjms7vqk3gn66nm2m37x8mv"))))
8954 (build-system pyproject-build-system)
8955 (arguments
8956 (list
8957 #:test-flags
8958 #~(list
8959 "-k"
8960 (string-join
8961 (list
8962 ;; XXX: Deprecated behavior.
8963 "not test_client_options_universe_configured_with_mtls"
8964 "test_universe_env_var_configured_with_mtls"
8965 ;; XXX: Requires CA certificates.
8966 "test_credentials_and_credentials_file_mutually_exclusive")
8967 " and not ")
8968 "tests")))
8969 (native-inputs
8970 (list python-parameterized
8971 python-pytest
8972 python-setuptools))
8973 (propagated-inputs
8974 (list python-google-api-core
8975 python-google-auth
8976 python-google-auth-httplib2
8977 python-httplib2
8978 python-pyparsing
8979 python-uritemplate-3))
8980 (home-page "https://github.com/google/google-api-python-client")
8981 (synopsis "Core Python library for accessing Google APIs")
8982 (description "Python client library for Google's discovery based APIs")
8983 (license license:asl2.0)))
8984
8985(define-public python-google-auth-httplib2
8986 (package
8987 (name "python-google-auth-httplib2")
8988 (version "0.2.0")
8989 (source (origin
8990 (method url-fetch)
8991 (uri (pypi-uri "google-auth-httplib2" version))
8992 (sha256
8993 (base32 "018fckshilc6z2qpj1pclh8haanbq3lr85w6p4g4z5wgyjnppaiq"))))
8994 (build-system pyproject-build-system)
8995 (propagated-inputs
8996 (list python-google-auth python-httplib2))
8997 (native-inputs
8998 (list python-pytest
8999 python-pyparsing
9000 python-pytest-localserver
9001 python-flask
9002 python-setuptools))
9003 (home-page
9004 "https://github.com/GoogleCloudPlatform/google-auth-library-python-httplib2")
9005 (synopsis "Google Authentication Library: httplib2 transport")
9006 (description "This package provides a Google Authentication Library plugin
9007for httplib2 transport.")
9008 (license license:asl2.0)))
9009
9010(define-public python-google-auth-oauthlib
9011 (package
9012 (name "python-google-auth-oauthlib")
9013 (version "1.2.4")
9014 (home-page
9015 "https://github.com/GoogleCloudPlatform/\
9016google-auth-library-python-oauthlib")
9017 (source
9018 (origin
9019 (method git-fetch)
9020 (uri (git-reference
9021 (url home-page)
9022 (commit (string-append "v" version))))
9023 (file-name (git-file-name name version))
9024 (sha256
9025 (base32 "1j25kdbs2j1x23pdv4n49xl9pz2ppn55vsav65ir796kq4lf9nca"))))
9026 (build-system pyproject-build-system)
9027 (propagated-inputs (list python-google-auth python-requests-oauthlib))
9028 (native-inputs
9029 (list python-click python-mock python-pytest python-setuptools))
9030 (synopsis "Google Authentication Library: oauthlib")
9031 (description "This package provides a Google Authentication Library plugin
9032with oauthlib.")
9033 (license license:asl2.0)))
9034
9035(define-public whoogle-search
9036 (package
9037 (name "whoogle-search")
9038 (version "0.8.4")
9039 (source (origin
9040 (method url-fetch)
9041 (uri (pypi-uri "whoogle-search" version))
9042 (sha256
9043 (base32
9044 "0hsy4l98nzj6i1lf63wvqd0yharkaz44zsxh863ymy47rxnwimz7"))))
9045 (build-system pyproject-build-system)
9046 (arguments
9047 (list
9048 ;; The tests need network access
9049 #:tests? #f))
9050 (propagated-inputs
9051 (list python-beautifulsoup4
9052 python-brotli
9053 python-cryptography
9054 python-cssutils
9055 python-defusedxml
9056 python-flask
9057 python-dotenv
9058 python-requests
9059 python-stem
9060 python-validators
9061 python-waitress))
9062 (native-inputs (list python-setuptools python-wheel))
9063 (home-page "https://github.com/benbusby/whoogle-search")
9064 (synopsis "Self-hosted, ad-free, privacy-respecting metasearch engine")
9065 (description
9066 "Get Google results, but without any ads, javascript, AMP links,
9067cookies, or IP address tracking. Quick and simple to implement as a primary
9068search engine replacement on both desktop and mobile.")
9069 (license license:expat)))
9070
9071(define-public python-hawkauthlib
9072 (package
9073 (name "python-hawkauthlib")
9074 (version "2.0.0")
9075 (source
9076 (origin
9077 (method git-fetch)
9078 (uri (git-reference
9079 (url "https://github.com/mozilla-services/hawkauthlib")
9080 (commit (string-append "v" version))))
9081 (file-name (git-file-name name version))
9082 (sha256
9083 (base32 "0pdpk3fp87ngfsyp4lm2z7z8b203jxsmvbz59q6r6xgg9sp4cl3l"))))
9084 (build-system pyproject-build-system)
9085 (arguments (list #:test-backend #~'unittest))
9086 (native-inputs (list python-setuptools))
9087 (propagated-inputs (list python-requests python-webob))
9088 (home-page "https://github.com/mozilla-services/hawkauthlib")
9089 (synopsis "Hawk Access Authentication protocol")
9090 (description
9091 "This is a low-level Python library for implementing Hawk Access
9092Authentication, a simple HTTP request-signing scheme.")
9093 (license license:mpl2.0)))
9094
9095(define-public python-pybrowserid
9096 (package
9097 (name "python-pybrowserid")
9098 (version "0.14.0")
9099 (source
9100 (origin
9101 (method git-fetch)
9102 (uri (git-reference
9103 (url "https://github.com/mozilla/PyBrowserID")
9104 (commit version)))
9105 (file-name (git-file-name name version))
9106 (sha256
9107 (base32 "0in0sbj56wrz5mlrj6wkd3h7rrp7714c5rkxvkfwp60s2hr6ynj6"))))
9108 (build-system pyproject-build-system)
9109 (arguments (list #:test-backend #~'unittest))
9110 (propagated-inputs (list python-requests))
9111 (native-inputs (list python-mock python-setuptools))
9112 (home-page "https://github.com/mozilla/PyBrowserID")
9113 (synopsis "Python library for the BrowserID protocol")
9114 (description
9115 "This is a Python client library for the BrowserID protocol that
9116underlies Mozilla Persona.")
9117 (license license:mpl2.0)))
9118
9119(define-public python-pyfxa
9120 (package
9121 (name "python-pyfxa")
9122 (version "0.8.1")
9123 (source
9124 (origin
9125 (method git-fetch)
9126 (uri (git-reference
9127 (url "https://github.com/mozilla/PyFxA")
9128 (commit (string-append "v" version))))
9129 (file-name (git-file-name name version))
9130 (sha256
9131 (base32 "11iaw50x5ic9cqp3jwkvhk8mz00dhg8xhl1kkx45zrb8nnrfw2vs"))))
9132 (build-system pyproject-build-system)
9133 (arguments
9134 (list
9135 ;; These tests require network access
9136 #:test-flags #~(list "--ignore=fxa/tests/test_core.py")))
9137 (propagated-inputs
9138 (list python-cryptography
9139 python-pyjwt
9140 python-parameterized
9141 python-hawkauthlib
9142 python-requests))
9143 (native-inputs
9144 (list python-grequests
9145 python-hatchling
9146 python-mock
9147 python-pytest
9148 python-responses))
9149 (home-page "https://github.com/mozilla/PyFxA")
9150 (synopsis "Firefox Accounts client library for Python")
9151 (description
9152 "This is a Python library for interacting with the Firefox Accounts
9153ecosystem.")
9154 (license license:mpl2.0)))
9155
9156(define-public python-hyperlink
9157 (package
9158 (name "python-hyperlink")
9159 (version "21.0.0")
9160 (source
9161 (origin
9162 (method url-fetch)
9163 (uri (pypi-uri "hyperlink" version))
9164 (sha256
9165 (base32
9166 "0sx50lkivsfjxx9zr4yh7l9gll2l9kvl0v0w8w4wk2x5v9bzjyj2"))))
9167 (build-system pyproject-build-system)
9168 (arguments
9169 (list #:phases
9170 #~(modify-phases %standard-phases
9171 (add-before 'check 'pretend-to-be-CI
9172 (lambda _
9173 ;; Pretend to be a CI system to skip flaky tests.
9174 (setenv "CI" "true"))))))
9175 (native-inputs
9176 (list python-pytest python-setuptools python-wheel))
9177 (propagated-inputs
9178 (list python-idna))
9179 (home-page "https://github.com/python-hyper/hyperlink")
9180 (synopsis "Python module to create immutable URLs according to spec")
9181 (description "This package provides a Python module to create immutable, and
9182correct URLs for Python according to RFCs 3986 and 3987.")
9183 (license license:expat)))
9184
9185(define-public python-treq
9186 (package
9187 (name "python-treq")
9188 (version "24.9.1")
9189 (source
9190 (origin
9191 (method url-fetch)
9192 (uri (pypi-uri "treq" version))
9193 (sha256
9194 (base32
9195 "1a7yrq2m7hf77fia4fc0c6zanvwnykpgirdbs1cyvr7k0k27znhm"))))
9196 (build-system pyproject-build-system)
9197 (native-inputs
9198 (list python-httpbin
9199 python-pytest
9200 python-service-identity
9201 python-setuptools
9202 python-wheel))
9203 (propagated-inputs
9204 (list python-attrs
9205 python-hyperlink
9206 python-incremental
9207 python-requests
9208 python-twisted
9209 python-typing-extensions))
9210 (home-page "https://github.com/twisted/treq")
9211 (synopsis "Requests-like API built on top of twisted.web's Agent")
9212 (description "This package provides an HTTP library inspired by
9213@code{requests} but written on top of Twisted's @code{Agents}. It offers a
9214high level API for making HTTP requests when using Twisted.")
9215 (license license:expat)))
9216
9217(define-public python-autobahn
9218 (package
9219 (name "python-autobahn")
9220 (version "25.11.1")
9221 (source
9222 (origin
9223 (method url-fetch)
9224 (uri (pypi-uri "autobahn" version))
9225 (sha256
9226 (base32
9227 "1w9wyyqzg1dil8jsjm08n2pnk6jws87scli932drhghcr2f2prjj"))))
9228 (build-system pyproject-build-system)
9229 (arguments
9230 (list
9231 ;; The tests fail to run:
9232 ;; https://github.com/crossbario/autobahn-python/issues/1117
9233 #:tests? #f
9234 #:phases #~(modify-phases %standard-phases
9235 (add-after 'unpack 'relax-zope-interface
9236 (lambda _
9237 ;; python-zope-interface is a world rebuild package
9238 ;; and our one-digit lower minor version seems to be
9239 ;; fine.
9240 (substitute* "setup.py"
9241 (("zope.interface>=5.2.0")
9242 "zope.interface>=5.1.0"))))
9243 (add-after 'unpack 'strip-xbr
9244 (lambda _
9245 ;; Strip new XBR feature which isn't available in Guix.
9246 (setenv "AUTOBAHN_STRIP_XBR" "1"))))))
9247 (native-inputs (list python-setuptools python-wheel))
9248 (propagated-inputs (list python-cbor2
9249 python-cryptography
9250 python-hyperlink
9251 python-msgpack
9252 python-py-ubjson
9253 python-twisted
9254 python-txaio
9255 python-ujson))
9256 (home-page "https://github.com/crossbario/autobahn-python/")
9257 (synopsis "Web Application Messaging Protocol implementation")
9258 (description "This package provides an implementation of the @dfn{Web Application
9259Messaging Protocol} (WAMP). WAMP connects components in distributed
9260applications using Publish and Subscribe (PubSub) and routed Remote Procedure
9261Calls (rRPC). It is ideal for distributed, multi-client and server applications
9262such as IoT applications or multi-user database-driven business applications.")
9263 (license license:expat)))
9264
9265(define-public python-ws4py
9266 (package
9267 (name "python-ws4py")
9268 (version "0.6.0")
9269 (source
9270 (origin
9271 (method git-fetch)
9272 (uri (git-reference
9273 (url "https://github.com/Lawouach/WebSocket-for-Python")
9274 (commit version)))
9275 (file-name (git-file-name name version))
9276 (sha256
9277 (base32
9278 "00y6s8gk20936njqbxr8vjliviiz7r7pqrlwg7xi8zzs6903xvv6"))))
9279 (build-system pyproject-build-system)
9280 (arguments
9281 (list
9282 #:phases
9283 #~(modify-phases %standard-phases
9284 (add-after 'unpack 'remove-cherrypy-support
9285 (lambda _
9286 (delete-file "ws4py/server/cherrypyserver.py")
9287 (delete-file "test/test_cherrypy.py"))))))
9288 (native-inputs (list python-setuptools python-pytest))
9289 (propagated-inputs
9290 (list python-gevent python-tornado))
9291 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
9292 (synopsis "WebSocket client and server library")
9293 (description
9294 "This package provides a WebSocket client and server library for Python.")
9295 (license license:bsd-3)))
9296
9297(define-public python-slowapi
9298 (package
9299 (name "python-slowapi")
9300 (version "0.1.9")
9301 (source
9302 (origin
9303 (method git-fetch)
9304 (uri (git-reference
9305 (url "https://github.com/laurents/slowapi")
9306 (commit (string-append "v" version))))
9307 (file-name (git-file-name name version))
9308 (sha256
9309 (base32 "1lc1n6lvh01dhhrc507qri9rz1w72l2riii03ixh7n7n1gwjpws7"))))
9310 (build-system pyproject-build-system)
9311 (arguments
9312 (list
9313 #:test-flags
9314 ;; These tests fail because the timestamp contains more decimal points
9315 ;; than expected, so a simple equality comparison fails.
9316 '(list "-k" (string-append "not test_headers_no_breach"
9317 " and not test_headers_breach"))))
9318 (propagated-inputs (list python-limits python-redis))
9319 (native-inputs
9320 (list python-fastapi
9321 python-hiro
9322 python-mock
9323 python-poetry-core
9324 python-pytest))
9325 (home-page "https://github.com/laurents/slowapi")
9326 (synopsis "Rate limiting extension for Starlette and Fastapi")
9327 (description
9328 "This package provides a rate limiting extension for Starlette and
9329Fastapi.")
9330 (license license:expat)))
9331
9332(define-public python-slugify
9333 (package
9334 (name "python-slugify")
9335 (version "8.0.4")
9336 (source
9337 (origin
9338 (method git-fetch)
9339 (uri (git-reference
9340 (url "https://github.com/un33k/python-slugify")
9341 (commit (string-append "v" version))))
9342 (file-name (git-file-name name version))
9343 (sha256
9344 (base32 "0z83nwy7acc72mb2jv3516nfplah1wm61wkmnzl71dh8i4q985yd"))))
9345 (build-system pyproject-build-system)
9346 (arguments (list #:test-backend #~'unittest))
9347 (native-inputs (list python-setuptools))
9348 (propagated-inputs (list python-unidecode python-text-unidecode))
9349 (home-page "https://github.com/un33k/python-slugify")
9350 (synopsis "Python Slugify application that handles Unicode")
9351 (description "This package provides a @command{slufigy} command and
9352library to create slugs from unicode strings while keeping it DRY.")
9353 (license license:expat)))
9354
9355(define-public python-branca
9356 (package
9357 (name "python-branca")
9358 (version "0.7.2")
9359 (source
9360 (origin
9361 (method git-fetch) ; no tests in PyPI
9362 (uri (git-reference
9363 (url "https://github.com/python-visualization/branca")
9364 (commit (string-append "v" version))))
9365 (file-name (git-file-name name version))
9366 (sha256
9367 (base32 "1vs94nqa7r6iwm8mj3m29hg090gmgz4ywnayxh8qiz9ij8jv96wa"))))
9368 (build-system pyproject-build-system)
9369 (arguments
9370 ;; This file requires Selenium.
9371 (list #:test-flags #~(list "--ignore" "tests/test_iframe.py"
9372 ;; This test passes but is very slow.
9373 "-k" "not test_color_brewer_extendability")))
9374 (propagated-inputs (list python-jinja2))
9375 (native-inputs
9376 (list python-numpy
9377 python-pytest
9378 python-setuptools
9379 python-setuptools-scm
9380 python-wheel))
9381 (home-page "https://github.com/python-visualization/branca")
9382 (synopsis "Generate complex HTML+JS pages with Python")
9383 (description "This library is a spinoff from @code{folium} that would host
9384the non-map-specific features. It can be used to generate HTML + JS.")
9385 (license license:expat)))
9386
9387(define-public python-tinycss2
9388 (package
9389 (name "python-tinycss2")
9390 (version "1.4.0")
9391 (source
9392 (origin
9393 (method git-fetch)
9394 (uri (git-reference
9395 (url "https://github.com/Kozea/tinycss2")
9396 (commit (string-append "v" version))
9397 (recursive? #true)))
9398 (file-name (git-file-name name version))
9399 (sha256
9400 (base32 "11m5vhpdz6zlzq2lqqklkhd0h4jxblpvcrdf9cc4s06nhr9acp0r"))))
9401 (build-system pyproject-build-system)
9402 (native-inputs
9403 (list python-flit
9404 python-pytest
9405 python-pytest-cov))
9406 (propagated-inputs
9407 (list python-webencodings))
9408 (home-page "https://tinycss2.readthedocs.io/")
9409 (synopsis "Low-level CSS parser for Python")
9410 (description "@code{tinycss2} can parse strings, return Python objects
9411representing tokens and blocks, and generate CSS strings corresponding to
9412these objects.
9413
9414Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
9415grammar of CSS but doesn’t know specific rules, properties or values supported
9416in various CSS modules.")
9417 (license license:bsd-3)))
9418
9419(define-public python-cssselect2
9420 (package
9421 (name "python-cssselect2")
9422 (version "0.4.1")
9423 (source
9424 (origin
9425 (method url-fetch)
9426 (uri (pypi-uri "cssselect2" version))
9427 (sha256
9428 (base32 "1j2fcr217rsvkipsg6zjq03rl64rxnvb5hqqpx0dv58fhspvkywk"))))
9429 (build-system pyproject-build-system)
9430 (arguments
9431 `(#:phases
9432 (modify-phases %standard-phases
9433 (add-after 'unpack 'disable-linters
9434 ;; Their check fails; none of our business.
9435 (lambda _
9436 (substitute* '("setup.py" "pyproject.toml")
9437 (("'pytest-flake8',") "")
9438 (("'pytest-isort',") "")
9439 (("--flake8") "")
9440 (("--isort") "")))))))
9441 (propagated-inputs
9442 (list python-tinycss2))
9443 (native-inputs
9444 (list python-flit python-pytest-cov python-pytest-runner))
9445 (home-page "https://cssselect2.readthedocs.io/")
9446 (synopsis "CSS selectors for Python ElementTree")
9447 (description "@code{cssselect2} is a straightforward implementation of
9448CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
9449ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
9450
9451Unlike the Python package @code{cssselect}, it does not translate selectors to
9452XPath and therefore does not have all the correctness corner cases that are
9453hard or impossible to fix in cssselect.")
9454 (license license:bsd-3)))
9455
9456(define-public python-uvloop
9457 (package
9458 (name "python-uvloop")
9459 (version "0.21.0")
9460 (source
9461 (origin
9462 (method url-fetch)
9463 (uri (pypi-uri "uvloop" version))
9464 (sha256
9465 (base32 "1qq46ym3ymzfn4j6fnykfmr1f4qnb7x7p15dlw37hi38v87jpw9v"))
9466 (modules '((guix build utils)))
9467 (snippet
9468 '(begin (delete-file-recursively "vendor")
9469 (delete-file "uvloop/loop.c")))))
9470 (build-system pyproject-build-system)
9471 (arguments
9472 (list
9473 #:test-flags
9474 ;; The tests are prone to get stuck. Use pytest-timeout’s --timeout flag
9475 ;; to get a meaningful idea about where.
9476 #~(list "--timeout=300"
9477 "--timeout-method=thread"
9478 "-k" (string-join
9479 (list
9480 ;; Timeout, because SIGINT cannot be sent to child.
9481 "not test_signals_sigint_pycode_continue"
9482 "test_signals_sigint_pycode_stop"
9483 "test_signals_sigint_uvcode"
9484 "test_signals_sigint_uvcode_two_loop_runs"
9485 ;; This test is racy and prone to get stuck on
9486 ;; various platforms, possibly a aiohttp issue:
9487 ;; https://github.com/MagicStack/uvloop/issues/412
9488 "test_remote_shutdown_receives_trailing_data"
9489 ;; It looks like pytest is preventing
9490 ;; custom stdout/stderr redirection,
9491 ;; even with -s.
9492 "test_process_streams_redirect"
9493 ;; FileNotFoundError: [Errno 2] No such file or
9494 ;; directory
9495 "test_process_env_2"
9496 ;; socket.gaierror: [Errno -2] Name or service not known
9497 "test_getaddrinfo_21"
9498 #$@(if (target-riscv64?)
9499 `("test_renegotiation")
9500 `()))
9501 " and not "))
9502 #:phases
9503 #~(modify-phases %standard-phases
9504 (add-after 'unpack 'preparations
9505 (lambda _
9506 ;; Use packaged libuv.
9507 (substitute* "setup.py" (("self.use_system_libuv = False")
9508 "self.use_system_libuv = True"))
9509 ;; Replace hardcoded shell command.
9510 (substitute* "uvloop/loop.pyx"
9511 (("b'/bin/sh'") (string-append "b'" (which "sh") "'")))))
9512 #$@(if (target-riscv64?)
9513 `((add-after 'unpack 'adjust-test-timeouts
9514 (lambda _
9515 (substitute* '("tests/test_tcp.py"
9516 "tests/test_unix.py")
9517 (("SSL_HANDSHAKE_TIMEOUT = 15\\.0")
9518 "SSL_HANDSHAKE_TIMEOUT = 30.0")))))
9519 '())
9520 (add-before 'check 'pre-check
9521 (lambda* (#:key tests? #:allow-other-keys)
9522 (when tests?
9523 ;; Remove Python module, which conflicts with the installed
9524 ;; version, but lacks the built C module.
9525 (delete-file-recursively "uvloop")))))))
9526 (native-inputs
9527 (list python-aiohttp
9528 python-cython
9529 python-psutil
9530 python-pyopenssl
9531 python-pytest
9532 python-pytest-timeout
9533 python-setuptools
9534 python-wheel))
9535 (inputs
9536 (list libuv))
9537 (home-page "https://github.com/MagicStack/uvloop")
9538 (synopsis "Fast implementation of asyncio event loop on top of libuv")
9539 (description
9540 "@code{uvloop} is a fast, drop-in replacement of the built-in asyncio
9541event loop. It is implemented in Cython and uses libuv under the hood.")
9542 (license license:expat)))
9543
9544(define-public gunicorn
9545 (package
9546 (name "gunicorn")
9547 (version "22.0.0")
9548 (source
9549 (origin
9550 (method url-fetch)
9551 (uri (pypi-uri "gunicorn" version))
9552 (sha256
9553 (base32
9554 "0qzc3ghayc137hlwrqqwkkhaf8f5h9ja21qwy4rznxpz75i462sa"))))
9555 ;; CVE-2024-1135 is fixed in version 22.0.0.
9556 (properties `((lint-hidden-cve . ("CVE-2024-1135"))))
9557 (outputs '("out" "doc"))
9558 (build-system pyproject-build-system)
9559 (arguments
9560 `(#:test-flags
9561 ;; Disable the geventlet tests because eventlet uses dnspython, which
9562 ;; does not work in the build container due to lack of /etc/resolv.conf
9563 '("--ignore=tests/workers/test_geventlet.py")
9564 #:phases (modify-phases %standard-phases
9565 (add-after 'build 'build-doc
9566 (lambda _
9567 (invoke "make"
9568 "-C"
9569 "docs"
9570 "PAPER=a4"
9571 "html"
9572 "info")
9573 (delete-file "docs/build/texinfo/Makefile")
9574 (delete-file "docs/build/texinfo/Gunicorn.texi")))
9575 (add-after 'install 'install-doc
9576 (lambda* (#:key outputs #:allow-other-keys)
9577 (let* ((doc (string-append (assoc-ref outputs "doc")
9578 "/share/doc/"
9579 ,name "-"
9580 ,version))
9581 (html (string-append doc "/html"))
9582 (info (string-append doc "/info"))
9583 (examples (string-append doc "/examples")))
9584 (mkdir-p html)
9585 (mkdir-p info)
9586 (mkdir-p examples)
9587 (copy-recursively "docs/build/html" html)
9588 (copy-recursively "docs/build/texinfo" info)
9589 (copy-recursively "examples" examples)
9590 (for-each (lambda (file)
9591 (copy-file file
9592 (string-append doc "/" file)))
9593 '("README.rst" "NOTICE" "LICENSE" "THANKS")))))
9594 ;; XXX: The wrap phase includes native inputs on PYTHONPATH, (see
9595 ;; <https://bugs.gnu.org/25235>), leading to an inflated closure
9596 ;; size. Override it to only add the essential entries.
9597 (replace 'wrap
9598 (lambda* (#:key native-inputs inputs outputs
9599 #:allow-other-keys)
9600 (let* ((out (assoc-ref outputs "out"))
9601 (python (assoc-ref (or native-inputs inputs)
9602 "python"))
9603 (sitedir (string-append "/lib/python"
9604 (python-version python)
9605 "/site-packages")))
9606 (wrap-program (string-append out "/bin/gunicorn")
9607 `("PYTHONPATH" ":" prefix
9608 ,(map (lambda (output)
9609 (string-append output sitedir))
9610 (list python out))))))))))
9611 (inputs (list bash-minimal))
9612 (native-inputs (list binutils ;for ctypes.util.find_library()
9613 python-aiohttp
9614 python-gevent
9615 python-pytest
9616 python-pytest-cov
9617 python-sphinx
9618 texinfo))
9619 (propagated-inputs (list python-packaging python-setuptools python-wheel))
9620 (home-page "https://gunicorn.org/")
9621 (synopsis "Python WSGI HTTP Server for UNIX")
9622 (description
9623 "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
9624Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
9625Unicorn project. The Gunicorn server is broadly compatible with
9626various web frameworks, simply implemented, light on server resources,
9627and fairly speedy.")
9628 (license license:expat)))
9629
9630;; break cyclic dependency for python-aiohttp, which depends on gunicorn for
9631;; its tests
9632(define-public gunicorn-bootstrap
9633 (package
9634 (inherit gunicorn)
9635 (name "gunicorn")
9636 (arguments `(#:tests? #f))
9637 (properties '((hidden? . #t)))
9638 (native-inputs `())))
9639
9640(define-public python-httptools
9641 (package
9642 (name "python-httptools")
9643 (version "0.7.1")
9644 (source
9645 (origin
9646 ;; PyPI tarball comes with a vendored http-parser and no tests.
9647 (method git-fetch)
9648 (uri (git-reference
9649 (url "https://github.com/MagicStack/httptools")
9650 (commit (string-append "v" version))))
9651 (file-name (git-file-name name version))
9652 (sha256
9653 (base32 "0j9c1av3y1smg6lgh0i031l07i9plzbvv14jj53vpzm35sy7kbl7"))
9654 (modules '((guix build utils)))
9655 (snippet
9656 #~(begin (delete-file-recursively "vendor")))))
9657 (build-system pyproject-build-system)
9658 (arguments
9659 (list
9660 #:test-flags
9661 ;; XXX: AssertionError: HttpParserError not raised.
9662 #~(list "-k" "not test_parser_response_leninent_headers_1")
9663 #:phases
9664 #~(modify-phases %standard-phases
9665 (add-after 'unpack 'configure-build-ext
9666 (lambda _
9667 (with-output-to-file "setup.cfg"
9668 (lambda ()
9669 (display "\
9670[build_ext]
9671use_system_llhttp = true
9672use_system_http_parser = true
9673cython_always = true"))))))))
9674 (native-inputs
9675 (list python-cython
9676 python-pytest
9677 python-setuptools))
9678 (inputs
9679 (list http-parser
9680 llhttp))
9681 (home-page "https://github.com/MagicStack/httptools")
9682 (synopsis "Collection of framework independent HTTP protocol utils")
9683 (description
9684 "@code{httptools} is a Python binding for the nodejs HTTP parser.")
9685 (license license:expat)))
9686
9687(define-public python-uvicorn
9688 (package
9689 (name "python-uvicorn")
9690 (version "0.34.0")
9691 (source
9692 (origin
9693 ;; PyPI tarball has no tests.
9694 (method git-fetch)
9695 (uri (git-reference
9696 (url "https://github.com/encode/uvicorn")
9697 (commit version)))
9698 (file-name (git-file-name name version))
9699 (sha256
9700 (base32 "05lkxnpzmr0kik81kdcvavjvvc4d1lgmw88mr4vbwsqk147wgqbc"))))
9701 (build-system pyproject-build-system)
9702 (arguments
9703 (list
9704 #:test-flags
9705 #~(list "-o" "asyncio_mode=auto"
9706 ;; For some reason tests stacked in infinity re-invocation loop:
9707 ;; AssertionError where is_alive =
9708 ;; <uvicorn.supervisors.multiprocess.Process object at
9709 ;; 0x7ffff39b6110>.is_alive.
9710 ;; Maybe this <https://github.com/encode/uvicorn/issues/2466>.
9711 "--ignore=tests/supervisors/test_multiprocess.py"
9712
9713 #$@(cond
9714 ((or (target-aarch64?)
9715 (target-riscv64?))
9716 '("-k not test_send_binary_data_to_server_bigger_than_default_on_websockets"))
9717 (#t '())))))
9718 (native-inputs
9719 (list nss-certs-for-test
9720 python-a2wsgi
9721 python-hatchling
9722 python-httpx-bootstrap
9723 python-pytest
9724 python-pytest-asyncio-0.26
9725 python-pytest-mock
9726 python-requests
9727 python-trustme
9728 python-wsproto))
9729 (propagated-inputs
9730 (list python-a2wsgi
9731 python-click
9732 python-dotenv
9733 python-h11
9734 python-httptools
9735 python-pyyaml
9736 python-uvloop
9737 python-watchfiles
9738 python-websockets))
9739 (home-page "https://github.com/encode/uvicorn")
9740 (synopsis "Fast ASGI server implementation")
9741 (description
9742 "@code{uvicorn} is a fast ASGI server implementation, using @code{uvloop}
9743and @code{httptools}. It currently supports HTTP/1.1 and WebSockets. Support
9744for HTTP/2 is planned.")
9745 (license license:bsd-3)))
9746
9747(define-public python-translation-finder
9748 (package
9749 (name "python-translation-finder")
9750 (version "2.22")
9751 (source
9752 (origin
9753 (method url-fetch)
9754 (uri (pypi-uri "translation_finder" version))
9755 (sha256
9756 (base32 "1hav99ccijvk2w8wpvba2pc7ba1z150vja2wvaimd069mc08pjd2"))))
9757 (build-system pyproject-build-system)
9758 (arguments
9759 (list
9760 #:test-flags
9761 ;; AssertionError: 31 != 30 : Mismatched count of results
9762 #~(list "--deselect=translation_finder/test_api.py::APITest::test_discover_file")))
9763 (native-inputs
9764 (list python-pytest
9765 python-setuptools))
9766 (propagated-inputs
9767 (list python-charset-normalizer
9768 python-ruamel.yaml
9769 python-weblate-language-data))
9770 (home-page "https://weblate.org/")
9771 (synopsis "Translation file finder for Weblate")
9772 (description "This package provides a function to find translation file in
9773the source code of a project. It supports many translation file formats and
9774is part of the Weblate translation platform.")
9775 (license license:gpl3+)))
9776
9777(define-public python-gitlab
9778 (package
9779 (name "python-gitlab")
9780 (version "7.0.0")
9781 (source
9782 (origin
9783 (method git-fetch)
9784 (uri (git-reference
9785 (url "https://github.com/python-gitlab/python-gitlab")
9786 (commit (string-append "v" version))))
9787 (file-name (git-file-name name version))
9788 (sha256
9789 (base32 "0rf1hz5n724f8sfc7g3fzfz96jsv9y145pi6gc8qscsjq3z4vi37"))))
9790 (build-system pyproject-build-system)
9791 (arguments
9792 (list
9793 #:test-flags
9794 #~(list "--ignore=tests/unit/test_graphql.py"
9795 ;; XXX: Missing helper script.
9796 "-k" "not test_data_from_helper" "tests/unit")))
9797 (native-inputs
9798 (list python-anyio
9799 python-pytest
9800 python-responses
9801 python-setuptools))
9802 (propagated-inputs (list python-requests python-requests-toolbelt))
9803 (home-page "https://github.com/python-gitlab/python-gitlab")
9804 (synopsis "Interact with GitLab API")
9805 (description "This package provides an extended library for interacting
9806with GitLab instances through their API.")
9807 (license license:lgpl3+)))
9808
9809(define-public python-path-and-address
9810 (package
9811 (name "python-path-and-address")
9812 (version "2.0.1")
9813 (source
9814 (origin
9815 (method git-fetch)
9816 (uri (git-reference
9817 (url "https://github.com/joeyespo/path-and-address")
9818 (commit (string-append "v" version))))
9819 (file-name (git-file-name name version))
9820 (sha256
9821 (base32 "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6"))))
9822 (build-system pyproject-build-system)
9823 (native-inputs
9824 (list python-pytest python-setuptools))
9825 (home-page "https://github.com/joeyespo/path-and-address")
9826 (synopsis "Functions for command-line server tools used by humans")
9827 (description "Path-and-address resolves ambiguities of command-line
9828interfaces, inferring which argument is the path, and which is the address.")
9829 (license license:expat)))
9830
9831;; XXX: This project missed maintainer upstream, see
9832;; <https://github.com/joeyespo/grip/issues/387>.
9833;; Consider to remove if it keeps failing to build.
9834(define-public grip
9835 (package
9836 (name "grip")
9837 (version "4.6.1")
9838 (source
9839 (origin
9840 (method git-fetch)
9841 (uri (git-reference
9842 (url "https://github.com/joeyespo/grip")
9843 (commit (string-append "v" version))))
9844 (file-name (git-file-name name version))
9845 (sha256
9846 (base32 "0vhimd99zw7s1fihwr6yfij6ywahv9gdrfcf5qljvzh75mvzcwh8"))))
9847 (build-system pyproject-build-system)
9848 (arguments
9849 (list
9850 #:test-flags
9851 ;; All tests fail requiring network access, ignore the whole file.
9852 #~(list "--ignore=tests/test_github.py")
9853 #:phases
9854 #~(modify-phases %standard-phases
9855 ;; This fixes the removal of `charset` attribute of requests from
9856 ;; Werkzeug 2.3.0.
9857 ;; Fixed in grip's commit <2784eb2c1515f1cdb1554d049d48b3bff0f42085>.
9858 (add-after 'unpack 'fix-response-encoding
9859 (lambda _
9860 (substitute* "grip/app.py"
9861 (("response.charset")
9862 "getattr(response, 'charset', 'utf-8')")))))))
9863 (native-inputs
9864 (list nss-certs-for-test
9865 python-pytest
9866 python-responses
9867 python-setuptools
9868 python-wheel))
9869 (propagated-inputs
9870 (list python-docopt
9871 python-flask
9872 python-markdown
9873 python-path-and-address
9874 python-pygments
9875 python-requests))
9876 (home-page "https://github.com/joeyespo/grip")
9877 (synopsis "Preview Markdown files using the GitHub API")
9878 (description
9879 "Grip is a command-line server application written in Python that uses
9880the GitHub Markdown API to render a local Markdown file. The styles and
9881rendering come directly from GitHub, so you'll know exactly how it will
9882appear. Changes you make to the file will be instantly reflected in the
9883browser without requiring a page refresh.")
9884 (license license:expat)))
9885
9886(define-public python-port-for
9887 (package
9888 (name "python-port-for")
9889 (version "0.7.4")
9890 (source
9891 (origin
9892 (method url-fetch)
9893 (uri (pypi-uri "port_for" version))
9894 (sha256
9895 (base32 "13826s2d4hzzmv69wws6a7ryhminclv2bqaw6cpl929gnbki6xzw"))))
9896 (build-system pyproject-build-system)
9897 (propagated-inputs
9898 (list python-urllib3))
9899 (native-inputs
9900 (list python-pytest python-setuptools python-wheel))
9901 (home-page "https://github.com/kmike/port-for/")
9902 (synopsis "TCP localhost port finder and association manager")
9903 (description
9904 "This package provides a utility that helps with local TCP ports
9905management. It can find an unused TCP localhost port and remember the
9906association.")
9907 (license license:expat)))
9908
9909(define-public python-livereload
9910 (package
9911 (name "python-livereload")
9912 (version "2.7.1")
9913 (source
9914 (origin
9915 (method git-fetch)
9916 (uri (git-reference
9917 (url "https://github.com/lepture/python-livereload")
9918 (commit (string-append "v" version))))
9919 (file-name (git-file-name name version))
9920 (sha256
9921 (base32 "19wkdd1grw6mcd4qi8iaw4jdr207h3m24951vgy69j7g904lynjq"))))
9922 (build-system pyproject-build-system)
9923 (arguments (list #:test-backend #~'unittest))
9924 (native-inputs (list python-django python-setuptools))
9925 (propagated-inputs (list python-tornado))
9926 (home-page "https://github.com/lepture/python-livereload")
9927 (synopsis "Python LiveReload")
9928 (description
9929 "Python LiveReload provides a command line utility, @command{livereload},
9930for starting a web server in a directory. It can trigger arbitrary commands
9931and serve updated contents upon changes to the directory.")
9932 (license license:bsd-3)))
9933
9934(define-public python-vf-1
9935 (package
9936 (name "python-vf-1")
9937 (version "1.0.0")
9938 (source
9939 (origin
9940 (method git-fetch)
9941 (uri (git-reference
9942 (url "https://git.sr.ht/~solderpunk/VF-1")
9943 (commit (string-append "v" version))))
9944 (file-name (git-file-name name version))
9945 (sha256
9946 (base32 "1j8l4xivm6rs8jms1ixx0i9fz4yxr84hbz1pdc498jgkgzy1v8ih"))))
9947 (build-system pyproject-build-system)
9948 (arguments (list #:tests? #f)) ; No tests.
9949 (native-inputs (list python-setuptools))
9950 (home-page "https://git.sr.ht/~solderpunk/VF-1")
9951 (synopsis "Command line gopher client")
9952 (description "@code{VF-1} is a command line gopher client with
9953@acronym{TLS, Transport Layer Security} support.")
9954 (license license:bsd-2)))
9955
9956(define-public python-httpcore
9957 (package
9958 (name "python-httpcore")
9959 (version "1.0.9")
9960 (source
9961 (origin
9962 ;; PyPI tarball does not contain tests.
9963 (method git-fetch)
9964 (uri (git-reference
9965 (url "https://github.com/encode/httpcore")
9966 (commit version)))
9967 (file-name (git-file-name name version))
9968 (sha256
9969 (base32 "0yhm2n8qflpwjsjggyj757m0gw3n68al0my0ljybndwp933ipl32"))))
9970 (build-system pyproject-build-system)
9971 (native-inputs
9972 (list nss-certs-for-test
9973 python-hatch-fancy-pypi-readme
9974 python-hatchling
9975 python-pytest
9976 python-pytest-asyncio
9977 python-pytest-httpbin
9978 python-pytest-trio
9979 python-uvicorn
9980 python-trustme))
9981 (propagated-inputs
9982 (list python-anyio
9983 python-certifi
9984 python-h11
9985 python-h2
9986 python-sniffio
9987 python-socksio
9988 python-trio
9989 python-trio-typing))
9990 (home-page "https://github.com/encode/httpcore")
9991 (synopsis "Minimal, low-level HTTP client")
9992 (description
9993 "HTTP Core provides a minimal and low-level HTTP client, which does one
9994thing only: send HTTP requests.
9995
9996Some things HTTP Core does do:
9997
9998@itemize
9999@item Sending HTTP requests.
10000@item Provides both sync and async interfaces.
10001@item Supports HTTP/1.1 and HTTP/2.
10002@item Async backend support for asyncio and trio.
10003@item Automatic connection pooling.
10004@item HTTP(S) proxy support.
10005@end itemize")
10006 (license license:bsd-3)))
10007
10008;;; Variant used to break a cycle between python-httpx and python-uvicorn.
10009(define-public python-httpcore-bootstrap
10010 (hidden-package
10011 (package/inherit python-httpcore
10012 (name "python-httpcore-bootstrap")
10013 (arguments (list #:tests? #f))
10014 (native-inputs (list python-hatchling
10015 python-hatch-fancy-pypi-readme)))))
10016
10017(define-public python-httpx
10018 (package
10019 (name "python-httpx")
10020 (version "0.28.1")
10021 (source
10022 (origin
10023 ;; PyPI tarball does not contain tests.
10024 (method git-fetch)
10025 (uri (git-reference
10026 (url "https://github.com/encode/httpx")
10027 (commit version)))
10028 (file-name (git-file-name name version))
10029 (sha256
10030 (base32 "00d6rb21xwazwb0sj68zhra0qxxcwkd0vv7bg3k1jg94dmk2w7xl"))))
10031 (build-system pyproject-build-system)
10032 (arguments
10033 (list
10034 ;; 1401 passed, 1 skipped, 5 deselected
10035 #:test-flags
10036 #~(list "-o" "asyncio_mode=auto"
10037 ;; CLI tests are broken.
10038 "--ignore=tests/test_main.py"
10039 "-k" (string-join
10040 ;; These tests try to open an outgoing connection.
10041 (list "not test_async_proxy_close"
10042 "test_sync_proxy_clos"
10043 "test_write_timeout")
10044 " and not "))))
10045 (native-inputs
10046 (list nss-certs-for-test
10047 python-chardet
10048 python-cryptography
10049 python-hatch-fancy-pypi-readme
10050 python-hatchling
10051 python-pytest
10052 python-pytest-asyncio
10053 python-pytest-trio
10054 python-setuptools
10055 python-trio
10056 python-trustme
10057 python-uvicorn))
10058 (propagated-inputs
10059 (list python-anyio
10060 python-certifi
10061 python-httpcore
10062 python-idna
10063 ;; [brotli]
10064 python-brotli
10065 ;; [http2]
10066 python-h2
10067 ;; [socks]
10068 python-socksio
10069 ;; [zstd]
10070 python-zstandard
10071 ;; For trio, see:
10072 ;; <https://github.com/python-trio/trio/issues/2802>.
10073 python-sniffio))
10074 (home-page "https://www.python-httpx.org/")
10075 (synopsis "HTTP client for Python")
10076 (description
10077 "HTTPX is a fully featured HTTP client for Python 3, which provides sync
10078and async APIs, and support for both HTTP/1.1 and HTTP/2.
10079
10080HTTPX builds on the well-established usability of requests, and gives you:
10081
10082@itemize
10083@item A broadly requests-compatible API.
10084@item Standard synchronous interface, but with async support if you need it.
10085@item HTTP/1.1 and HTTP/2 support.
10086@item Ability to make requests directly to WSGI applications or ASGI applications.
10087@item Strict timeouts everywhere.
10088@item Fully type annotated.
10089@item 99% test coverage.
10090@end itemize
10091
10092Plus all the standard features of requests:
10093
10094@itemize
10095@item International Domains and URLs
10096@item Keep-Alive & Connection Pooling
10097@item Sessions with Cookie Persistence
10098@item Browser-style SSL Verification
10099@item Basic/Digest Authentication
10100@item Elegant Key/Value Cookies
10101@item Automatic Decompression
10102@item Automatic Content Decoding
10103@item Unicode Response Bodies
10104@item Multipart File Uploads
10105@item HTTP(S) Proxy Support
10106@item Connection Timeouts
10107@item Streaming Downloads
10108@item .netrc Support
10109@item Chunked Requests
10110@end itemize")
10111 (license license:bsd-3)))
10112
10113;;; Variant used to break a cycle with python-uvicorn.
10114(define-public python-httpx-bootstrap
10115 (hidden-package
10116 (package/inherit python-httpx
10117 (name "python-httpx-bootstrap")
10118 (arguments (list #:tests? #f))
10119 (native-inputs
10120 (list python-hatchling
10121 python-hatch-fancy-pypi-readme))
10122 (propagated-inputs
10123 (modify-inputs (package-propagated-inputs python-httpx)
10124 (replace "python-httpcore" python-httpcore-bootstrap))))))
10125
10126(define-public python-httpx-sse
10127 (package
10128 (name "python-httpx-sse")
10129 (version "0.4.3")
10130 (source
10131 (origin
10132 (method git-fetch)
10133 (uri (git-reference
10134 (url "https://github.com/florimondmanca/httpx-sse")
10135 (commit version)))
10136 (file-name (git-file-name name version))
10137 (sha256
10138 (base32 "0zliqd1rkvc0mjppscvqmg8j17hsiwvxn439yhn6qbjvk5ydncz8"))))
10139 (build-system pyproject-build-system)
10140 (arguments
10141 (list
10142 ;; XXX: Avoids python-pytest-cov dependency.
10143 #:test-flags #~(list "-c" "/dev/null")))
10144 (native-inputs
10145 (list python-pytest
10146 python-pytest-asyncio
10147 python-setuptools
10148 python-setuptools-scm
10149 python-sse-starlette))
10150 (propagated-inputs (list python-httpx))
10151 (home-page "https://github.com/florimondmanca/httpx-sse")
10152 (synopsis "Consume Server-Sent Event (SSE) messages with HTTPX.")
10153 (description "Consume Server-Sent Event (SSE) messages with HTTPX.")
10154 (license license:expat)))
10155
10156(define-public python-wsgiprox
10157 (package
10158 (name "python-wsgiprox")
10159 (version "1.5.2")
10160 (source
10161 (origin
10162 (method url-fetch)
10163 (uri (pypi-uri "wsgiprox" version))
10164 (sha256
10165 (base32 "11fsm199pvwbmqx2lccznvws65aam1rqqv0w79gal8hispwgd5rs"))))
10166 (build-system pyproject-build-system)
10167 (arguments
10168 ;; The test suite hangs (see:
10169 ;; https://github.com/webrecorder/wsgiprox/issues/6).
10170 (list
10171 #:tests? #f
10172 #:phases
10173 #~(modify-phases %standard-phases
10174 (add-after 'unpack 'fix-pytest-argument
10175 (lambda _
10176 ;; See: https://github.com/webrecorder/wsgiprox/issues/7.
10177 (substitute* "setup.py"
10178 (("--doctest-module")
10179 "--doctest-modules")))))))
10180 (propagated-inputs
10181 (list python-certauth python-gevent python-websocket-client))
10182 (native-inputs
10183 (list python-mock python-pytest-cov python-waitress python-setuptools))
10184 (home-page "https://github.com/webrecorder/wsgiprox")
10185 (synopsis "HTTP/S proxy with WebSockets over WSGI")
10186 (description
10187 "@code{wsgiprox} is a Python WSGI (Web Server Gateway Interface)
10188middle-ware for adding HTTP and HTTPS proxy support to a WSGI application.
10189The library accepts HTTP and HTTPS proxy connections, and routes them to a
10190designated prefix.")
10191 (license license:asl2.0)))
10192
10193(define-public python-warcio
10194 ;; The PyPI release is missing some test support files (see:
10195 ;; https://github.com/webrecorder/warcio/issues/132).
10196 (package
10197 (name "python-warcio")
10198 (version "1.7.5")
10199 (source
10200 (origin
10201 (method git-fetch)
10202 (uri (git-reference
10203 (url "https://github.com/webrecorder/warcio")
10204 (commit (string-append "v" version))))
10205 (file-name (git-file-name name version))
10206 (sha256
10207 (base32
10208 "0r3kijsm8wsbipi5pxsrqpg5nn4w8iaw5i8010b0ligmfxnxamlb"))))
10209 (build-system pyproject-build-system)
10210 (arguments
10211 (list
10212 #:test-flags ; These tests fail due to networking requirements.
10213 '(list "-k" (format #f "not ~a"
10214 (string-join
10215 '("test_post_chunked"
10216 "test_remote"
10217 "test_capture_http_proxy"
10218 "test_capture_https_proxy"
10219 "test_capture_https_proxy_same_session")
10220 " and not "))
10221 ; The following test requires the hookdns package.
10222 "--ignore=test/test_capture_http_proxy.py")))
10223 (native-inputs
10224 ;; These inputs are required for the test suite.
10225 (list python-httpbin
10226 python-pytest-cov
10227 python-requests
10228 python-setuptools
10229 python-wheel
10230 python-wsgiprox))
10231 (home-page "https://github.com/webrecorder/warcio")
10232 (synopsis "Streaming web archival archive (WARC) library")
10233 (description "warcio is a Python library to read and write the WARC format
10234commonly used in Web archives. It is designed for fast, low-level access to
10235web archival content, oriented around a stream of WARC records rather than
10236files.")
10237 (license license:asl2.0)))
10238
10239(define-public python-websockets
10240 (package
10241 (name "python-websockets")
10242 (version "13.1")
10243 (source
10244 (origin
10245 (method git-fetch)
10246 (uri (git-reference
10247 (url "https://github.com/aaugustin/websockets")
10248 (commit version)))
10249 (file-name (git-file-name name version))
10250 (sha256
10251 (base32
10252 "1dx3rf6fmg4ir9cfcn1fil446qz879cwrjq2rcz5zvl71xkw6hb3"))))
10253 (build-system pyproject-build-system)
10254 (arguments
10255 (list #:test-backend #~'unittest
10256 #:phases
10257 #~(modify-phases %standard-phases
10258 (add-before 'check 'extend-test-timeout
10259 (lambda _
10260 ;; Some architectures need an even longer timeout. Make it
10261 ;; long enough that it should never fail due to timeout.
10262 #$@(if (target-riscv64?)
10263 #~((setenv "WEBSOCKETS_TESTS_TIMEOUT_FACTOR" "100"))
10264 #~((setenv "WEBSOCKETS_TESTS_TIMEOUT_FACTOR" "10"))))))))
10265 (native-inputs
10266 (list python-setuptools
10267 python-wheel))
10268 (home-page "https://github.com/aaugustin/websockets")
10269 (synopsis
10270 "Python implementation of the WebSocket Protocol (RFC 6455 & 7692)")
10271 (description
10272 "@code{websockets} is a library for building WebSocket servers and clients
10273in Python with a focus on correctness and simplicity.
10274
10275Built on top of @code{asyncio}, Python's standard asynchronous I/O framework,
10276it provides an elegant coroutine-based API.")
10277 (license license:bsd-3)))
10278
10279(define-public selenium-manager
10280 (package
10281 (name "selenium-manager")
10282 (version "4.34.2")
10283 (source
10284 (origin
10285 (method git-fetch)
10286 (uri (git-reference
10287 (url "https://github.com/SeleniumHQ/selenium")
10288 (commit (string-append "selenium-" version "-python"))))
10289 (file-name (git-file-name name version))
10290 (sha256
10291 (base32 "14fg8r4rm9d7169rlm29l5yn08wgllmqk1zc6six3dlrzzf5mxil"))))
10292 (build-system cargo-build-system)
10293 (arguments
10294 (list
10295 ;; XXX: Almost all tests require either browsers or network access.
10296 #:tests? #f
10297 #:install-source? #f ; Most likely intended as a leaf.
10298 #:phases
10299 #~(modify-phases %standard-phases
10300 (add-after 'unpack 'chdir
10301 (lambda _
10302 (chdir "rust"))))))
10303 (native-inputs (list pkg-config))
10304 (inputs (cons* (list zstd "lib") xz
10305 (cargo-inputs 'selenium-manager)))
10306 (home-page "https://www.selenium.dev")
10307 (synopsis "CLI tool to manager the browser test infrastructure")
10308 (description
10309 "Selenium simplifies web browser automation. It specifically provides
10310infrastructure for the W3C WebDriver specification — a platform and
10311language-neutral coding interface compatible with all major web browsers.
10312
10313Selenium Manager is a CLI tool that automatically manages the browser/driver
10314infrastructure required by Selenium.")
10315 (license license:asl2.0)))
10316
10317(define-public python-selenium
10318 (package/inherit selenium-manager
10319 (name "python-selenium")
10320 (build-system pyproject-build-system)
10321 (arguments
10322 (list
10323 ;; XXX: Disable failing tests.
10324 #:test-flags
10325 #~(list "--ignore-glob=test/selenium/webdriver/*"
10326 ;; Probably requires those.
10327 "--ignore-glob=test/unit/selenium/webdriver/chrome/*"
10328 "--ignore-glob=test/unit/selenium/webdriver/firefox/*"
10329 ;; XXX: SSL certificates access.
10330 "--ignore=test/unit/selenium/webdriver/remote/remote_connection_tests.py"
10331 "-k" "not test_missing_cdp_devtools_version_falls_back")
10332 #:phases
10333 #~(modify-phases %standard-phases
10334 (add-after 'unpack 'chdir
10335 (lambda _
10336 (chdir "py")))
10337 (add-after 'chdir 'inject-selenium-manager-binary
10338 (lambda* (#:key inputs #:allow-other-keys)
10339 (substitute* "selenium/webdriver/common/selenium_manager.py"
10340 (("compiled_path = Path.*")
10341 (format #f "return Path(~s)~%"
10342 (search-input-file inputs "bin/selenium-manager"))))
10343 (substitute* "pyproject.toml"
10344 (("\\[\\[tool\\.setuptools-rust\\.bins\\]\\]")
10345 "")
10346 (("target = \"selenium\\.webdriver\\.common.*\"")
10347 ""))))
10348 (add-after 'chdir 'relax-requirements
10349 (lambda _
10350 (substitute* "pyproject.toml"
10351 (("\"(typing_extensions|trio)~=.*\"," _ target)
10352 (format #f "~s," target))))))))
10353 (propagated-inputs (list python-certifi
10354 python-trio
10355 python-trio-websocket
10356 python-typing-extensions
10357 python-urllib3
10358 python-websocket-client))
10359 (inputs (list selenium-manager))
10360 (native-inputs (list python-filetype
10361 python-pytest
10362 python-pytest-mock
10363 python-pytest-trio
10364 python-setuptools
10365 python-setuptools-rust))
10366 (synopsis "Python bindings for Selenium")
10367 (description
10368 "Selenium enables web browser automation. It specifically provides
10369infrastructure for the W3C WebDriver specification — a platform and
10370language-neutral coding interface compatible with all major web browsers.")))
10371
10372(define-public python-rapidjson
10373 (package
10374 (name "python-rapidjson")
10375 (version "1.10")
10376 (source
10377 (origin
10378 (method url-fetch)
10379 (uri (pypi-uri "python-rapidjson" version))
10380 (sha256
10381 (base32
10382 "0h1m9m4a5rlf5hw6ak7z3qbgdhmqarzxw9d140mcf7mrxpswpzmc"))
10383 (modules '((guix build utils)))
10384 (snippet
10385 '(delete-file-recursively "rapidjson"))))
10386 (build-system pyproject-build-system)
10387 (arguments
10388 (list
10389 #:test-flags '(list "tests")
10390 #:phases
10391 #~(modify-phases %standard-phases
10392 ;; We cannot seem to use #:configure-flags with the
10393 ;; pyproject-build-system to override rj_include_dir.
10394 (add-after 'unpack 'override-rapidjson-sources
10395 (lambda _
10396 (substitute* "setup.py"
10397 (("^rj_include_dir =.*")
10398 (string-append "rj_include_dir = '"
10399 #$(this-package-native-input "rapidjson")
10400 "/include/rapidjson" "'"))
10401 (("if not os.path.isdir.*") "if False:")))))))
10402 (native-inputs
10403 (list rapidjson python-pytest python-pytz python-setuptools python-wheel))
10404 (home-page "https://github.com/python-rapidjson/python-rapidjson")
10405 (synopsis "Python wrapper around rapidjson")
10406 (description "This package provides a python wrapper around rapidjson.")
10407 (license license:expat)))
10408
10409(define-public python-venusian
10410 (package
10411 (name "python-venusian")
10412 (version "3.1.1")
10413 (source
10414 (origin
10415 (method url-fetch)
10416 (uri (pypi-uri "venusian" version))
10417 (sha256
10418 (base32 "0h8cdwx5x6i1ydc9s0hxwvy73l6iwlqijn2l77mq74k6anrv6ksk"))))
10419 (build-system pyproject-build-system)
10420 (arguments
10421 (list
10422 #:phases
10423 #~(modify-phases %standard-phases
10424 (add-after 'unpack 'fix-pytest-config
10425 (lambda _
10426 (substitute* "setup.cfg"
10427 (("--cov --cov-report=term-missing ") "")))))))
10428 (native-inputs
10429 (list python-pytest
10430 python-setuptools))
10431 (home-page "https://docs.pylonsproject.org/projects/venusian")
10432 (synopsis "Library for deferring decorator actions")
10433 (description
10434 "Venusian is a library which allows framework authors to defer decorator
10435actions. Instead of taking actions when a function (or class) decorator is
10436executed at import time, you can defer the action usually taken by the
10437decorator until a separate scan phase.")
10438 (license license:repoze)))
10439
10440(define-public python-zope-deprecation
10441 (package
10442 (name "python-zope-deprecation")
10443 (version "6.0")
10444 (source (origin
10445 (method url-fetch)
10446 (uri (pypi-uri "zope_deprecation" version))
10447 (sha256
10448 (base32
10449 "0pzimp7xr8m0836bbsrx8wa9ybl58s5hwacas95nsfp6m2ypwwhq"))))
10450 (build-system pyproject-build-system)
10451 (arguments
10452 (list #:tests? #f)) ;no tests in PyPI
10453 (native-inputs
10454 (list python-setuptools))
10455 (home-page "https://zopedeprecation.readthedocs.io/")
10456 (synopsis "Function for marking deprecations")
10457 (description "The @code{zope.deprecation} module provides a function for
10458marking modules, classes, functions, methods and properties as deprecated,
10459displaying warnings when usaged in application code.")
10460 (license license:zpl2.1)))
10461
10462(define-public python-translationstring
10463 (package
10464 (name "python-translationstring")
10465 (version "1.4")
10466 (source (origin
10467 (method url-fetch)
10468 (uri (pypi-uri "translationstring" version))
10469 (sha256
10470 (base32
10471 "1wvncdzi1wj37x226qcf0yycz7js6l83na0pmc9blsbfsww7b55z"))))
10472 (build-system pyproject-build-system)
10473 (native-inputs
10474 (list python-pytest
10475 python-setuptools))
10476 (home-page "https://docs.pylonsproject.org/projects/translationstring")
10477 (synopsis "Internationalization tooling for the Pylons project")
10478 (description "This package provides a library used by various Pylons
10479project packages for internationalization (i18n) duties related to
10480translation.")
10481 (license license:repoze)))
10482
10483(define-public python-plaster
10484 (package
10485 (name "python-plaster")
10486 (version "1.1.2")
10487 (source (origin
10488 (method url-fetch)
10489 (uri (pypi-uri "plaster" version))
10490 (sha256
10491 (base32
10492 "167gfh0ahdll9m96ypgasji6yry2hkn9f0ml1b0lf4ccpxagrgpq"))))
10493 (build-system pyproject-build-system)
10494 (native-inputs
10495 (list python-pytest
10496 python-setuptools))
10497 (home-page "https://docs.pylonsproject.org/projects/plaster/en/latest/")
10498 (synopsis "Configuration loader for multiple config file formats")
10499 (description
10500 "Plaster is a loader interface around multiple config file formats. It
10501exists to define a common API for applications to use when they wish to load
10502configuration. The library itself does not aim to handle anything except a
10503basic API that applications may use to find and load configuration settings.
10504Any specific constraints should be implemented in a pluggable loader which can
10505be registered via an entrypoint.")
10506 (license license:repoze)))
10507
10508(define-public python-plaster-pastedeploy
10509 (package
10510 (name "python-plaster-pastedeploy")
10511 (version "1.0.1")
10512 (source (origin
10513 (method url-fetch)
10514 (uri (pypi-uri "plaster_pastedeploy" version))
10515 (sha256
10516 (base32
10517 "04hl71p76wnwiy195p5w51bn3c6ba0lgx8nsfm42d9s15rnjw9my"))))
10518 (build-system pyproject-build-system)
10519 (native-inputs
10520 (list python-pytest
10521 python-setuptools))
10522 (propagated-inputs
10523 (list python-plaster python-pastedeploy))
10524 (home-page "https://github.com/Pylons/plaster_pastedeploy")
10525 (synopsis "Plugin for python-plaster adding PasteDeploy syntax")
10526 (description
10527 "This plugin for @code{python-plaster} adds support for PasteDeploy
10528syntax, it provides a plaster @code{Loader} object that can parse ini files
10529according to the standard set by PasteDeploy")
10530 (license license:expat)))
10531
10532(define-public python-hupper
10533 (package
10534 (name "python-hupper")
10535 (version "1.12.1")
10536 (source
10537 (origin
10538 (method url-fetch)
10539 (uri (pypi-uri "hupper" version))
10540 (sha256
10541 (base32 "1srj7sqxdgxr0nnhh9lw8jmp64chwgg8iwfm9b4g9v7l1wbm9gq6"))))
10542 (build-system pyproject-build-system)
10543 (arguments
10544 (list
10545 ;; RuntimeError: timeout waiting for change to
10546 ;; file=/tmp/guix-build-python-hupper-1.12.1.drv-0/tmpm9n4697p
10547 #:test-flags #~(list "--ignore=tests/test_it.py")))
10548 (native-inputs
10549 (list python-pytest
10550 python-pytest-cov
10551 python-setuptools
10552 python-wheel))
10553 (propagated-inputs
10554 (list python-watchdog))
10555 (home-page "https://readthedocs.org/projects/hupper")
10556 (synopsis "Integrated process monitor tracking changes to imported Python files")
10557 (description
10558 "Hupper is an integrated process monitor that will track changes to any
10559imported Python files in sys.modules as well as custom paths. When files are
10560changed the process is restarted.")
10561 (license license:expat)))
10562
10563(define-public python-pyowm
10564 (package
10565 (name "python-pyowm")
10566 (version "3.3.0")
10567 (source
10568 (origin
10569 (method git-fetch)
10570 (uri (git-reference
10571 (url "https://github.com/csparpa/pyowm")
10572 (commit version)))
10573 (file-name (git-file-name name version))
10574 (sha256
10575 (base32
10576 "1ha4pp96y3jk33qnyir5851cnj4dc06q6wqn1b0w54l3fsds28vi"))))
10577 (build-system pyproject-build-system)
10578 (arguments (list #:test-flags #~(list "tests/unit")))
10579 (native-inputs (list python-pytest python-setuptools python-wheel))
10580 (propagated-inputs
10581 (list python-geojson-for-pyowm
10582 python-pysocks
10583 python-requests))
10584 (home-page "https://github.com/csparpa/pyowm")
10585 (synopsis "Python wrapper around OpenWeatherMap web APIs")
10586 (description
10587 "This package provides a Python wrapper around OpenWeatherMap web APIs.")
10588 (license license:expat)))
10589
10590(define-public python-pyramid
10591 (package
10592 (name "python-pyramid")
10593 (version "2.0.2")
10594 (source (origin
10595 (method url-fetch)
10596 (uri (pypi-uri "pyramid" version))
10597 (sha256
10598 (base32
10599 "1phqdz068hl3zda263qkjp5am8fmvmpcxp3nrhsna8g472kkh89p"))))
10600 (build-system pyproject-build-system)
10601 (propagated-inputs
10602 (list python-hupper
10603 python-plaster
10604 python-plaster-pastedeploy
10605 python-setuptools
10606 python-translationstring
10607 python-venusian
10608 python-webob
10609 python-zope-component
10610 python-zope-deprecation
10611 python-zope-interface))
10612 (native-inputs (list python-pytest python-webtest python-wheel))
10613 (home-page "https://trypyramid.com/")
10614 (synopsis "Python web-framework suitable for small and large sites")
10615 (description
10616 "Pyramid makes it easy to write web applications. From minimal
10617request/response web apps to larger, grown applications.")
10618 (license license:repoze)))
10619
10620(define-public python-pyramid-chameleon
10621 ;; PyPI lacks a fresh release, use the latest commit assosiated with
10622 ;; unrleased version, see:
10623 ;; <https://github.com/Pylons/pyramid_chameleon/issues/27>
10624 (let ((commit "956c77ba37120c430e871c834d3cd4ed5ac8dccf")
10625 (revision "0"))
10626 (package
10627 (name "python-pyramid-chameleon")
10628 (version (git-version "0.4.dev0" revision commit))
10629 (source
10630 (origin
10631 (method git-fetch)
10632 (uri (git-reference
10633 (url "https://github.com/Pylons/pyramid_chameleon")
10634 (commit commit)))
10635 (file-name (git-file-name name version))
10636 (sha256
10637 (base32 "0rsb921xi7736h1xikc904bq2zzmrj1g8qgyimjw5wxdcd8927b1"))))
10638 (build-system pyproject-build-system)
10639 (native-inputs
10640 (list python-pytest
10641 python-setuptools))
10642 (propagated-inputs
10643 (list python-chameleon
10644 python-pyramid))
10645 (home-page "https://github.com/Pylons/pyramid_chameleon")
10646 (synopsis "Chameleon template compiler for pyramid")
10647 (description
10648 "These package provides bindings for the Chameleon templating system
10649 for the Pyramid web framework.")
10650 (license license:repoze))))
10651
10652(define-public python-pyramid-debugtoolbar
10653 (package
10654 (name "python-pyramid-debugtoolbar")
10655 (version "4.12.1")
10656 (source
10657 (origin
10658 (method url-fetch)
10659 (uri (pypi-uri "pyramid_debugtoolbar" version))
10660 (sha256
10661 (base32 "0gdlc7vcga4vzma53h5csnhh4gwfmv3w8v9y5fhwqpy8979qis3i"))))
10662 (build-system pyproject-build-system)
10663 (arguments
10664 (list
10665 #:test-flags
10666 ;; Large diff assertion not equal faileurs.
10667 #~(list #$@(map (lambda (test)
10668 (string-append "--deselect=tests"
10669 "/test_panels/test_sqla.py::" test))
10670 (list "TestSimpleSelect::test_panel"
10671 "TestTransactionCommit::test_panel"
10672 "TestTransactionRollback::test_panel")))))
10673 (native-inputs
10674 (list python-pytest
10675 python-setuptools
10676 python-webtest))
10677 (propagated-inputs
10678 (list python-pyramid
10679 python-pyramid-chameleon
10680 python-pyramid-jinja2
10681 python-pyramid-mako
10682 ;; python-selenium ; see: guix/guix#3478
10683 python-sqlalchemy
10684 python-waitress))
10685 (home-page "https://github.com/Pylons/pyramid_debugtoolbar")
10686 (synopsis "Pyramid debug toolbar")
10687 (description
10688 "This package provides an interactive HTML debugger for Pyramid application
10689development.")
10690 (license license:bsd-3)))
10691
10692(define-public python-pyramid-jinja2
10693 (package
10694 (name "python-pyramid-jinja2")
10695 (version "2.10.1")
10696 (source
10697 (origin
10698 (method url-fetch)
10699 (uri (pypi-uri "pyramid_jinja2" version))
10700 (sha256
10701 (base32 "0xqnqbqhx9bkrg2ic3blflsk8xc8kh7i2dm2kha9apqkbjrqql4c"))))
10702 (build-system pyproject-build-system)
10703 (arguments
10704 (list
10705 #:test-flags
10706 ;; Two tests failed with assertion not equal.
10707 #~(list "-k" "not test_it_relative_to_package and not test_options")
10708 #:phases
10709 #~(modify-phases %standard-phases
10710 (add-after 'unpack 'fix-pytest-config
10711 (lambda _
10712 (substitute* "setup.cfg"
10713 ((" --cov") "")))))))
10714 (native-inputs
10715 (list python-pytest
10716 python-setuptools
10717 python-webtest))
10718 (propagated-inputs
10719 (list python-jinja2
10720 python-markupsafe
10721 python-pyramid
10722 python-zope-deprecation))
10723 (home-page "https://github.com/Pylons/pyramid_jinja2")
10724 (synopsis "Jinja2 template bindings for the Pyramid web framework")
10725 (description "This package provides Jinja2 template bindings for the
10726Pyramid web framework.")
10727 (license license:repoze)))
10728
10729(define-public python-pyramid-mako
10730 ;; 1.1.0 was released in 2019, there a lot of compatability changes on
10731 ;; master, us the latest commit for now.
10732 (let ((commit "1a6f4c00c7134530d2975f34d904b64a41b28b21")
10733 (revision "0"))
10734 (package
10735 (name "python-pyramid-mako")
10736 (version (git-version "1.1.0" revision commit))
10737 (source
10738 (origin
10739 (method git-fetch)
10740 (uri (git-reference
10741 (url "https://github.com/Pylons/pyramid_mako")
10742 (commit commit)))
10743 (file-name (git-file-name name version))
10744 (sha256
10745 (base32 "0v0571z2gby4apsalkdk83gs0d5mw79d56518h3bwwxzbq32kkns"))))
10746 (build-system pyproject-build-system)
10747 (arguments
10748 (list
10749 #:phases
10750 #~(modify-phases %standard-phases
10751 (add-after 'unpack 'fix-pytest-config
10752 (lambda _
10753 (substitute* "pyproject.toml"
10754 ((" --cov --cov-report=term-missing") "")))))))
10755 (native-inputs
10756 (list python-pytest
10757 python-setuptools))
10758 (propagated-inputs
10759 (list python-mako
10760 python-pyramid))
10761 (home-page "https://github.com/Pylons/pyramid_mako")
10762 (synopsis "Mako template bindings for the Pyramid web framework")
10763 (description
10764 "This package provides Mako template bindings for the Pyramid web
10765framework.")
10766 (license license:repoze))))
10767
10768(define-public python-pyramid-retry
10769 (package
10770 (name "python-pyramid-retry")
10771 (version "2.1.1")
10772 (source
10773 (origin
10774 (method url-fetch)
10775 (uri (pypi-uri "pyramid_retry" version))
10776 (sha256
10777 (base32 "1jf07v6zhli0abgm2qajzfwg68bl9zy4xygjwl4svawbwrm2ga5s"))))
10778 (build-system pyproject-build-system)
10779 (native-inputs
10780 (list python-pytest
10781 python-setuptools
10782 python-webtest))
10783 (propagated-inputs
10784 (list python-pyramid
10785 python-zope-interface))
10786 (home-page "https://github.com/Pylons/pyramid_retry")
10787 (synopsis "Pyramid execution policy supporting retrying failed requests")
10788 (description
10789 "@code{pyramid_retry} is an execution policy for Pyramid that wraps requests
10790and can retry them a configurable number of times under certain \"retryable\"
10791error conditions before indicating a failure to the client.")
10792 (license license:expat)))
10793
10794(define-public python-pyramid-tm
10795 (package
10796 (name "python-pyramid-tm")
10797 (version "2.6")
10798 (source
10799 (origin
10800 (method url-fetch)
10801 (uri (pypi-uri "pyramid_tm" version))
10802 (sha256
10803 (base32 "173hg16hldfh5n3mn482xx64nldk308dzri31jd0qa4528cx4j41"))))
10804 (build-system pyproject-build-system)
10805 (arguments
10806 (list
10807 #:phases
10808 #~(modify-phases %standard-phases
10809 (add-after 'unpack 'fix-pytest-config
10810 (lambda _
10811 (substitute* "setup.cfg"
10812 ((" --cov") "")))))))
10813 (native-inputs
10814 (list python-pytest
10815 python-setuptools
10816 python-webtest))
10817 (propagated-inputs
10818 (list python-pyramid
10819 python-transaction))
10820 (home-page "https://github.com/Pylons/pyramid_tm")
10821 (synopsis "Centralized transaction management for Pyramid")
10822 (description
10823 "@code{pyramid_tm} is a package which allows Pyramid requests to join the
10824active @url{https://pypi.org/project/transaction/, transaction} as provided by
10825the Python transaction package.")
10826 (license license:repoze)))
10827
10828(define-public python-random-user-agent
10829 (package
10830 (name "python-random-user-agent")
10831 (version "1.0.1")
10832 (source
10833 (origin
10834 (method url-fetch)
10835 (uri (pypi-uri "random_user_agent" version))
10836 (sha256
10837 (base32 "04nhzdh2ki7ybhjrmghxci6hcm6i03vvin2q2ynj87fbr1pa534g"))))
10838 (build-system pyproject-build-system)
10839 (arguments (list #:tests? #f)) ; No tests.
10840 (native-inputs (list python-setuptools))
10841 (home-page "https://github.com/Luqman-Ud-Din/random_user_agent")
10842 (synopsis "List of user agents")
10843 (description
10844 "This package provides a list of user agents, from a collection of more
10845than 326,000 known user-agents. Users can pick a random one, or select one
10846based on filters.")
10847 (license license:expat)))
10848
10849(define-public python-rangehttpserver
10850 (package
10851 (name "python-rangehttpserver")
10852 (version "1.4.0")
10853 (source
10854 (origin
10855 (method git-fetch)
10856 (uri (git-reference
10857 (url "https://github.com/danvk/RangeHTTPServer")
10858 (commit version)))
10859 (file-name (git-file-name name version))
10860 (sha256
10861 (base32 "1dx533fsbq1mbz3by7qkm5bh2c253nwvm8214pqbwbfq07kqkwf2"))))
10862 (build-system pyproject-build-system)
10863 (native-inputs
10864 (list python-pytest
10865 python-requests
10866 python-setuptools))
10867 (home-page "https://github.com/danvk/RangeHTTPServer")
10868 (synopsis "SimpleHTTPServer with support for range requests")
10869 (description
10870 "This tool provides a simple HTTP server with support for Range
10871requests.")
10872 (license license:asl2.0)))
10873
10874(define-public python-flask-restx
10875 (package
10876 (name "python-flask-restx")
10877 (version "1.3.0")
10878 (source
10879 (origin
10880 (method git-fetch) ;no tests in PyPI archive
10881 (uri (git-reference
10882 (url "https://github.com/python-restx/flask-restx")
10883 (commit version)))
10884 (file-name (git-file-name name version))
10885 (sha256
10886 (base32 "1qmm3i1cdv0bvzsc1gn4ql2dsf1fbx85fk69vcmzpsdxzczmw508"))))
10887 (build-system pyproject-build-system)
10888 (arguments
10889 (list
10890 ;; 1214 passed, 6 skipped, 16 deselected, 3 warnings
10891 #:test-flags
10892 #~(list "--benchmark-skip"
10893 ;; ValueError: http://www.google.com is not a valid URL. Domain
10894 ;; does not exists.
10895 "--deselect=tests/test_inputs.py::URLTest::test_check"
10896 "-k" (string-join
10897 ;; See: <https://github.com/python-restx/flask-restx/issues/620>.
10898 (list "not test_rfc822_value"
10899 "test_iso8601_value"
10900 ;; assert 404 == 2000
10901 "test_specs_endpoint_host_and_subdomain"
10902 ;; ValueError: [email protected] is not a valid email
10903 "test_valid_value_check")
10904 " and not "))))
10905 (native-inputs
10906 (list python-blinker
10907 python-faker
10908 python-pytest
10909 python-pytest-benchmark
10910 python-pytest-flask
10911 python-pytest-mock
10912 python-setuptools))
10913 (propagated-inputs
10914 (list python-aniso8601
10915 python-flask
10916 python-importlib-resources
10917 python-jsonschema
10918 python-pytz
10919 python-werkzeug))
10920 (home-page "https://github.com/python-restx/flask-restx")
10921 (synopsis
10922 "Framework for fast, easy and documented API development with Flask")
10923 (description
10924 "Flask-RESTX is an extension for Flask that adds support for quickly building
10925REST APIs. Flask-RESTX encourages best practices with minimal setup. If you are familiar
10926 with Flask, Flask-RESTX should be easy to pick up. It provides a coherent collection of
10927decorators and tools to describe your API and expose its documentation properly using
10928Swagger.")
10929 (license license:bsd-3)))
10930
10931(define-deprecated-package python-flask-restplus
10932 python-flask-restx)
10933
10934(define-public python-flask-socketio
10935 (package
10936 (name "python-flask-socketio")
10937 (version "5.5.1")
10938 (source
10939 (origin
10940 (method url-fetch)
10941 (uri (pypi-uri "flask_socketio" version))
10942 (sha256
10943 (base32
10944 "1i0yqn39b4v4r2whppx47sg7iicvqzssd1clx7cclk07l52cjinr"))))
10945 (build-system pyproject-build-system)
10946 (propagated-inputs
10947 (list python-flask python-socketio))
10948 (native-inputs
10949 (list python-pytest python-redis python-setuptools python-wheel))
10950 (home-page "https://github.com/miguelgrinberg/Flask-SocketIO/")
10951 (synopsis "Socket.IO integration for Flask applications")
10952 (description "Socket.IO integration for Flask applications")
10953 (license license:expat)))
10954
10955(define-public python-manuel
10956 (package
10957 (name "python-manuel")
10958 (version "1.13.0")
10959 (source
10960 (origin
10961 (method url-fetch)
10962 (uri (pypi-uri "manuel" version))
10963 (sha256
10964 (base32 "0nl8psji3fizbxw34gdg22dndlg9lf5f56mnh1vr4vgsx06i4qsx"))))
10965 (build-system pyproject-build-system)
10966 (arguments
10967 (list
10968 ;; FIXME: Tests are broken, see: <https://github.com/benji-york/manuel/pull/32>.
10969 #:tests? #f))
10970 (propagated-inputs
10971 (list python-setuptools)) ;install requires
10972 (home-page "https://pypi.org/project/manuel/")
10973 (synopsis "Build tested documentation")
10974 (description
10975 "Manuel lets you mix and match traditional doctests with custom test syntax.")
10976 (license license:asl2.0)))
10977
10978(define-public python-marshmallow-jsonapi
10979 (package
10980 (name "python-marshmallow-jsonapi")
10981 (version "0.26.0")
10982 (source
10983 (origin
10984 (method git-fetch)
10985 (uri (git-reference
10986 ;; XXX: Deprecated upstream: This repository has been archived
10987 ;; by the owner on Jun 6, 2024. It is now read-only.
10988 ;; Using a maintained fork. The pypi name of this fork
10989 ;; is marshmallow-jsonapi-minfork.
10990 (url "https://github.com/tadams42/marshmallow-jsonapi")
10991 (commit version)))
10992 (file-name (git-file-name name version))
10993 (sha256
10994 (base32 "07sizh4m03rrk1139ci3psh5npk42cdsdfsdp574pz1fd5ncrq91"))))
10995 (build-system pyproject-build-system)
10996 (native-inputs
10997 (list python-faker
10998 python-flask
10999 python-pytest
11000 python-setuptools))
11001 (propagated-inputs (list python-marshmallow))
11002 (home-page "https://github.com/marshmallow-code/marshmallow-jsonapi")
11003 (synopsis "JSON:API 1.0 formatting with Marshmallow")
11004 (description
11005 "The marshmallow-jsonapi package provides a simple way to produce
11006@uref{https://jsonapi.org, JSON:API}-compliant data in any Python Web
11007framework. It includes optional utilities to integrate with Flask. This is a
11008forked version whose pypi name is @code{marshmallow_jsonapi_minfork}.")
11009 (license license:expat)))
11010
11011(define-public python-pecan
11012 (package
11013 (name "python-pecan")
11014 (version "1.6.1")
11015 (source
11016 (origin
11017 (method git-fetch) ;no tests in pypi release
11018 (uri (git-reference
11019 (url "https://github.com/pecan/pecan")
11020 (commit version)))
11021 (file-name (git-file-name name version))
11022 (sha256
11023 (base32
11024 "1ybjvpws741bvxd7aq5hh8gv5sk9836hb9afgalqsm0lxsq0li3a"))))
11025 (build-system pyproject-build-system)
11026 (arguments
11027 (list
11028 #:test-flags '(list "--pyargs" "pecan")))
11029 (native-inputs
11030 (list gunicorn
11031 python-genshi
11032 python-jinja2
11033 python-pytest
11034 python-sqlalchemy))
11035 (propagated-inputs
11036 (list python-logutils
11037 python-mako
11038 python-six
11039 python-webob
11040 python-webtest))
11041 (home-page "http://github.com/pecan/pecan")
11042 (synopsis "WSGI object-dispatching web framework")
11043 (description "This package provides a WSGI object-dispatching web
11044framework, designed to be lean and fast, with few dependencies.")
11045 (license license:bsd-3)))
11046
11047(define-public python-persistent
11048 (package
11049 (name "python-persistent")
11050 (version "6.1.1")
11051 (source
11052 (origin
11053 (method git-fetch)
11054 (uri (git-reference
11055 (url "https://github.com/zopefoundation/persistent/")
11056 (commit version)))
11057 (file-name (git-file-name name version))
11058 (sha256
11059 (base32 "19qwqg49zql2c8l4vjxjb9haw0bzd6lk8p4v3hip2irch6a4578a"))))
11060 (build-system pyproject-build-system)
11061 (arguments
11062 (list
11063 #:phases
11064 #~(modify-phases %standard-phases
11065 (replace 'check
11066 (lambda* (#:key tests? #:allow-other-keys)
11067 (if tests?
11068 (invoke "zope-testrunner" "--test-path=src"
11069 ;; XXX: Ignore doc tests.
11070 "!persistent.tests.test_docs")
11071 (format #t "test suite not run~%")))))))
11072 (propagated-inputs
11073 (list python-cffi
11074 python-zope-deferredimport
11075 python-zope-interface
11076 python-zope-testrunner))
11077 (native-inputs
11078 (list python-manuel python-zope-testrunner python-setuptools))
11079 (home-page "https://github.com/zopefoundation/persistent/")
11080 (synopsis "Translucent persistent objects")
11081 (description
11082 "This package contains a generic persistence implementation for Python.
11083It forms the core protocol for making objects interact \"transparently\" with
11084a database such as the ZODB.")
11085 (license license:zpl2.1)))
11086
11087(define-public python-btrees
11088 (package
11089 (name "python-btrees")
11090 (version "6.1")
11091 (source
11092 (origin
11093 (method git-fetch)
11094 (uri (git-reference
11095 (url "https://github.com/zopefoundation/BTrees")
11096 (commit version)))
11097 (file-name (git-file-name name version))
11098 (sha256
11099 (base32 "0vcibmd725ddgsl5yzmi8d403day3796h82xlq84w91xbdrbd5d5"))))
11100 (build-system pyproject-build-system)
11101 (arguments
11102 (list
11103 #:phases
11104 #~(modify-phases %standard-phases
11105 (replace 'check
11106 (lambda* (#:key tests? #:allow-other-keys)
11107 (if tests?
11108 (invoke "zope-testrunner" "--test-path=src")
11109 (format #t "test suite not run~%")))))))
11110 (propagated-inputs (list python-persistent python-zope-interface))
11111 (native-inputs (list python-persistent python-transaction
11112 python-zope-testrunner python-setuptools))
11113 (home-page "https://github.com/zopefoundation/BTrees")
11114 (synopsis "Scalable persistent object containers")
11115 (description
11116 "This package contains a set of persistent object containers built around a
11117modified BTree data structure. The trees are optimized for use inside ZODB's
11118\"optimistic concurrency\" paradigm, and include explicit resolution of
11119conflicts detected by that mechanism.")
11120 (license license:zpl2.1)))
11121
11122(define-public python-transaction
11123 (package
11124 (name "python-transaction")
11125 (version "5.0")
11126 (source
11127 (origin
11128 (method url-fetch)
11129 (uri (pypi-uri "transaction" version))
11130 (sha256
11131 (base32 "0x0i5graxb93aa8bwf5rmm9zq7d7r6q2b4pw358wph5whbbpnvhh"))))
11132 (build-system pyproject-build-system)
11133 (native-inputs
11134 (list python-pytest
11135 python-setuptools))
11136 (propagated-inputs
11137 (list python-zope-interface))
11138 (home-page "https://github.com/zopefoundation/transaction")
11139 (synopsis "Transaction management for Python")
11140 (description "This package contains a generic transaction implementation
11141for Python. It is mainly used by the ZODB.")
11142 (license license:zpl2.1)))
11143
11144(define-public python-truststore
11145 (package
11146 (name "python-truststore")
11147 (version "0.10.4")
11148 (source
11149 (origin
11150 (method url-fetch)
11151 (uri (pypi-uri "truststore" version))
11152 (sha256
11153 (base32 "00f3xc7720rkddsn291yrw871kfnimi6d9xbwi75xbb3ci1vv4cx"))))
11154 (build-system pyproject-build-system)
11155 (arguments
11156 (list #:tests? #f)) ;all tests require Internet access
11157 (native-inputs
11158 (list python-flit-core))
11159 (home-page "https://github.com/sethmlarson/truststore")
11160 (synopsis "Verify certificates using native system trust stores")
11161 (description
11162 "Truststore is a library which exposes native system certificate stores (ie
11163\"trust stores\") through an @code{ssl.SSLContext-like} API. This means that
11164Python applications no longer need to rely on certifi as a root certificate
11165store.")
11166 (license license:expat)))
11167
11168(define-public python-robot-detection
11169 (package
11170 (name "python-robot-detection")
11171 (version "0.4.0")
11172 (source
11173 (origin
11174 (method git-fetch)
11175 (uri (git-reference
11176 (url "https://github.com/rory/robot-detection")
11177 (commit (string-append "v" version))))
11178 (file-name (git-file-name name version))
11179 (sha256
11180 (base32 "1gxk13rn0gw5pfc4abhfnzg8qi05xa0ygs26pgkp0swygkzq6wsq"))))
11181 (build-system pyproject-build-system)
11182 (arguments (list #:test-backend #~'unittest))
11183 (native-inputs (list python-setuptools))
11184 (propagated-inputs (list python-six))
11185 (home-page "https://github.com/rory/robot-detection")
11186 (synopsis "Detect web crawlers")
11187 (description
11188 "@code{robot_detection} is a python module to detect if a given HTTP User
11189Agent is a web crawler. It uses the list of registered robots from
11190@url{http://www.robotstxt.org}.")
11191 (license license:gpl3+)))
11192
11193(define-public python-robotframework-requests
11194 (package
11195 (name "python-robotframework-requests")
11196 (version "0.9.7")
11197 (source
11198 (origin
11199 (method git-fetch) ; no tests in PyPI release
11200 (uri (git-reference
11201 (url "https://github.com/MarketSquare/robotframework-requests")
11202 (commit (string-append "v" version))))
11203 (file-name (git-file-name name version))
11204 (sha256
11205 (base32 "077j8p5k41v53slyv8h32fcmqfi7m6z3r4gmyqqaawm5szfmy61m"))))
11206 (build-system pyproject-build-system)
11207 (native-inputs
11208 (list python-pytest
11209 python-setuptools
11210 python-wheel))
11211 (propagated-inputs
11212 (list python-requests
11213 python-robotframework))
11214 (home-page "https://github.com/MarketSquare/robotframework-requests")
11215 (synopsis "Robot Framework keyword library wrapper around requests")
11216 (description
11217 "@code{RequestsLibrary} is a @url{https://robotframework.org/, Robot
11218Framework} library aimed to provide HTTP API testing functionalities by
11219wrapping the @code{requests} Python library.")
11220 (license license:expat)))
11221
11222(define-public python-pysolr
11223 (package
11224 (name "python-pysolr")
11225 (version "3.10.0")
11226 (source
11227 (origin
11228 (method url-fetch)
11229 (uri (pypi-uri "pysolr" version))
11230 (sha256
11231 (base32 "02gl1sma5cnpd7srpri1g68lpsg3s5n3lr462p5ll8v9s4nllyqj"))))
11232 (build-system pyproject-build-system)
11233 (arguments
11234 '(#:tests? #f)) ; Tests require network access.
11235 (native-inputs
11236 (list python-setuptools
11237 python-setuptools-scm
11238 python-wheel))
11239 (propagated-inputs
11240 (list python-requests))
11241 (home-page "https://github.com/django-haystack/pysolr/")
11242 (synopsis "Lightweight python wrapper for Apache Solr")
11243 (description
11244 "This module provides an interface that queries the Apache Solr server
11245using a pure Python implementation.")
11246 (license license:bsd-3)))
11247
11248(define-public python-pyjsparser
11249 ;; XXX: This project is potentially abandonware, consider to remove in next
11250 ;; refresh cycle, see:
11251 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/28>,
11252 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/39>, and
11253 ;; <https://github.com/PiotrDabkowski/pyjsparser/issues/40>.
11254 (package
11255 (name "python-pyjsparser")
11256 (version "2.7.1")
11257 (source
11258 (origin
11259 (method url-fetch)
11260 (uri (pypi-uri "pyjsparser" version))
11261 (sha256
11262 (base32 "0ycmf9fsvwliqmm1n6sfz7x71y7i2kbfgn39d8lsbiccfxmxlq5y"))))
11263 (build-system pyproject-build-system)
11264 (arguments
11265 '(#:tests? #f)) ;no tests in PyPI
11266 (native-inputs (list python-setuptools))
11267 (home-page "https://github.com/PiotrDabkowski/pyjsparser")
11268 (synopsis "Fast JavaScript parser")
11269 (description
11270 "This package provides a fast JavaScript parser (based on esprima.js)")
11271 (license license:expat)))
11272
11273(define-public python-js2py
11274 (package
11275 (name "python-js2py")
11276 (version "0.74")
11277 (source
11278 (origin
11279 (method url-fetch)
11280 (uri (pypi-uri "Js2Py" version))
11281 (sha256
11282 (base32 "0bwpp23qpx9amzqisiqvzlr17hr7vxqp4ry8lgxhw639hjmadwrr"))))
11283 (build-system pyproject-build-system)
11284 (arguments
11285 (list #:tests? #f)) ; tests require Node
11286 (native-inputs
11287 (list python-setuptools))
11288 (propagated-inputs
11289 (list python-pyjsparser
11290 python-six
11291 python-tzlocal))
11292 (home-page "https://github.com/PiotrDabkowski/Js2Py")
11293 (synopsis "JavaScript to Python translator")
11294 (description
11295 "This package provides a JavaScript to Python translator and a JavaScript
11296interpreter written in pure Python.")
11297 (license license:expat)))
11298
11299(define-public python-http-ece
11300 (package
11301 (name "python-http-ece")
11302 (version "1.2.1")
11303 (source
11304 (origin
11305 (method git-fetch)
11306 (uri (git-reference
11307 (url "https://github.com/web-push-libs/encrypted-content-encoding")
11308 (commit (string-append "v" version))))
11309 (file-name (git-file-name name version))
11310 (sha256
11311 (base32 "16kd9dsfpyfvq4iw6bbrrqrvsnf5lwgwa6p9f3b1y56ab18y0kzx"))))
11312 (build-system pyproject-build-system)
11313 (arguments
11314 `(#:phases
11315 (modify-phases %standard-phases
11316 (add-after 'unpack 'change-directory
11317 (lambda _ (chdir "python") #t)))))
11318 (native-inputs
11319 (list python-pytest
11320 python-pytest-cov
11321 python-setuptools))
11322 (propagated-inputs
11323 (list python-cryptography))
11324 (home-page "https://github.com/web-push-libs/encrypted-content-encoding")
11325 (synopsis "Encrypted Content Encoding for HTTP")
11326 (description
11327 "This package provides a simple implementation of Encrypted Content
11328Encoding for HTTP.")
11329 (license license:expat)))
11330
11331(define-public python-cloud-init
11332 (package
11333 (name "python-cloud-init")
11334 (version "24.2")
11335 (source
11336 (origin
11337 (method git-fetch)
11338 (uri (git-reference
11339 (url "https://github.com/canonical/cloud-init")
11340 (commit version)))
11341 (file-name (git-file-name name version))
11342 (sha256
11343 (base32 "18872z2y9wkh558y1bx5r0rksb4i584jbc8z4g8marwawhwxq506"))))
11344 (build-system pyproject-build-system)
11345 (arguments
11346 (list
11347 #:test-flags
11348 '(list
11349 ;; This requires usermod
11350 "--ignore=tests/unittests/distros/test_create_users.py"
11351 ;; This writes to /var
11352 "--ignore=tests/unittests/net/test_dhcp.py"
11353 "-k"
11354 (string-append
11355 ;; This test messes with PATH, so it cannot find mkdir
11356 "not test_path_env_gets_set_from_main"
11357 " and not test_apt_configure_sources_list_"
11358 ;; These all fail because /bin/sh doesn't exist. We cannot patch
11359 ;; this because the generated scripts must use /bin/sh as they are
11360 ;; supposed to be run on minimal systems.
11361 " and not test_handler_creates_and_runs_bootcmd_script_with_instance_id"
11362 " and not test_handler_runs_bootcmd_script_with_error"
11363 " and not test_subp_combined_stderr_stdout"
11364 " and not test_handle_part"))
11365 #:phases
11366 #~(modify-phases %standard-phases
11367 (add-after 'unpack 'patch-references
11368 (lambda _
11369 (substitute* "tests/unittests/cmd/test_clean.py"
11370 (("#!/bin/sh") (string-append "#!" (which "sh"))))))
11371 (add-after 'install 'move-files
11372 (lambda* (#:key inputs outputs #:allow-other-keys)
11373 (for-each (lambda (dir)
11374 (let ((source (string-append (site-packages inputs outputs) "/" dir))
11375 (target (string-append #$output "/" (basename dir))))
11376 (copy-recursively source target)
11377 (delete-file-recursively source)))
11378 (list "etc" "lib" "usr/lib" "usr/share")))))))
11379 (propagated-inputs
11380 (list python-configobj
11381 python-jinja2
11382 python-jsonpatch
11383 python-jsonschema
11384 python-netifaces
11385 python-oauthlib
11386 python-pyserial
11387 python-pyyaml
11388 python-responses))
11389 (native-inputs
11390 (list procps ;for ps when running tests
11391 python-pytest
11392 python-pytest-cov
11393 python-pytest-mock
11394 python-passlib
11395 python-setuptools
11396 python-wheel))
11397 (home-page "https://github.com/canonical/cloud-init")
11398 (synopsis "Cloud instance initialization tools")
11399 (description
11400 "Cloud-init is the multi-distribution method for cross-platform cloud
11401instance initialization. It is supported across all major public cloud
11402providers, provisioning systems for private cloud infrastructure, and
11403bare-metal installations.")
11404 ;; Either license can be chosen
11405 (license (list license:asl2.0 license:gpl3))))
11406
11407(define-public python-cloudscraper
11408 (package
11409 (name "python-cloudscraper")
11410 (version "3.0.0")
11411 (source
11412 (origin
11413 (method git-fetch)
11414 (uri (git-reference
11415 (url "https://github.com/VeNoMouS/cloudscraper")
11416 (commit version)))
11417 (file-name (git-file-name name version))
11418 (sha256
11419 (base32 "13w0ywz2y8x0zwpwzrnn46wyq307hfpdcz49zy33yyf46rq9n10n"))
11420 (modules '((guix build utils)))
11421 (snippet
11422 '(with-directory-excursion "cloudscraper"
11423 (for-each delete-file
11424 '("captcha/9kw.py" "captcha/anticaptcha.py"))
11425 (substitute* "__init__.py"
11426 ;; Perhaps it's a joke, but don't promote proprietary software.
11427 (("([Th]is feature is not available) in the .*'" _ prefix)
11428 (string-append prefix ".'")))))))
11429 (build-system pyproject-build-system)
11430 (arguments
11431 (list
11432 #:test-flags
11433 #~(list "-k" "not test_403_handling")
11434 #:phases
11435 #~(modify-phases %standard-phases
11436 (add-after 'unpack 'relax-requirements
11437 (lambda _
11438 ;; XXX: Relax brotli dependency.
11439 (substitute* "pyproject.toml"
11440 (("\"brotli>=.*\"")
11441 "\"brotli\""))
11442 ;; XXX: Dependencies, that have not yet been packaged
11443 ;; and cause an import error when included.
11444 (delete-file "cloudscraper/interpreters/v8.py")))
11445 (add-after 'unpack 'fix-references
11446 (lambda _
11447 (substitute* "cloudscraper/interpreters/nodejs.py"
11448 (("'node'")
11449 (string-append "'" (which "node") "'"))))))))
11450 (inputs (list node-lts))
11451 (propagated-inputs
11452 (list python-pycryptodome
11453 python-brotli
11454 python-js2py
11455 python-polling2
11456 python-requests
11457 python-requests-toolbelt
11458 python-responses
11459 python-pyparsing
11460 python-websocket-client))
11461 (native-inputs (list python-pytest python-setuptools))
11462 (home-page "https://github.com/venomous/cloudscraper")
11463 (synopsis "Cloudflare anti-bot bypass")
11464 (description
11465 "This module acts as a webbrowser solving Cloudflare's Javascript
11466challenges.")
11467 (license license:expat)))
11468
11469(define-public python-imap-tools
11470 (package
11471 (name "python-imap-tools")
11472 (version "1.9.0")
11473 (source
11474 (origin
11475 (method git-fetch) ; no tests in PyPI release
11476 (uri (git-reference
11477 (url "https://github.com/ikvk/imap_tools")
11478 (commit (string-append "v" version))))
11479 (file-name (git-file-name name version))
11480 (sha256
11481 (base32 "0iawc6shxn8p0ysiqiahfic5rp1r16f7rfn11c8y2fl8falckynr"))))
11482 (arguments
11483 (list
11484 #:test-flags
11485 ;; Tests require a network connection
11486 #~(list "-k" (string-append "not test_action"
11487 " and not test_attributes"
11488 " and not test_connection"
11489 " and not test_folders"
11490 " and not test_idle"
11491 " and not test_live"))))
11492 (build-system pyproject-build-system)
11493 (native-inputs
11494 (list python-pytest python-setuptools python-wheel))
11495 (home-page "https://github.com/ikvk/imap_tools")
11496 (synopsis "Work with email and mailbox by IMAP")
11497 (description
11498 "This Python library provides tools to deal with email and mailboxes
11499over IMAP:
11500
11501@itemize
11502@item Parsed email message attributes
11503@item Query builder for searching emails
11504@item Work with emails in folders (copy, delete, flag, move, seen)
11505@item Work with mailbox folders (list, set, get, create, exists, rename, delete, status)
11506@end itemize")
11507 (license license:asl2.0)))
11508
11509(define-public python-giturlparse
11510 (package
11511 (name "python-giturlparse")
11512 (version "0.12.0")
11513 (source
11514 (origin
11515 (method git-fetch)
11516 (uri (git-reference
11517 (url "https://github.com/nephila/giturlparse")
11518 (commit version)))
11519 (file-name (git-file-name name version))
11520 (sha256
11521 (base32 "1fdbxp176p17sn5xc1418mz2vk00hlcsd5qmi2fdcfphqal6raan"))))
11522 (build-system pyproject-build-system)
11523 (native-inputs (list python-pytest python-setuptools))
11524 (home-page "https://github.com/nephila/giturlparse")
11525 (synopsis "Git URL parsing module")
11526 (description
11527 "This package provides a git URL parsing module which supports parsing
11528and rewriting of remote git URLs from various hosting providers.")
11529 (license license:asl2.0)))
11530
11531(define-public python-hstspreload
11532 (package
11533 (name "python-hstspreload")
11534 (version "2025.1.1")
11535 (source
11536 (origin
11537 (method git-fetch)
11538 (uri (git-reference
11539 (url "https://github.com/sethmlarson/hstspreload")
11540 (commit version)))
11541 (file-name (git-file-name name version))
11542 (sha256
11543 (base32 "02mdzhgdz3sprgc26qb084zy639h2zw2yc8d2vm1r18ap9k51ayq"))))
11544 (build-system pyproject-build-system)
11545 (arguments (list #:tests? #f)) ; tests require external resources.
11546 (native-inputs (list python-setuptools))
11547 (home-page "https://github.com/sethmlarson/hstspreload")
11548 (synopsis "Chromium HSTS Preload list as a Python package")
11549 (description
11550 "@code{python-hstspreload} contains Chromium HSTS Preload list
11551as a Python package.")
11552 (license license:bsd-3)))
11553
11554(define-public python-sanic-routing
11555 (package
11556 (name "python-sanic-routing")
11557 (version "23.12.0")
11558 (source
11559 (origin
11560 (method url-fetch)
11561 (uri (pypi-uri "sanic-routing" version))
11562 (sha256
11563 (base32 "014bhkharcgyprdvlk7wjxhjp1pr0cva1nwj4f2qrr23qiidrjhx"))))
11564 (build-system pyproject-build-system)
11565 (arguments
11566 ;; PyPi sources does not contain tests, recursive dependency on
11567 ;; python-sanic.
11568 (list #:tests? #f))
11569 (native-inputs (list python-setuptools python-wheel))
11570 (home-page "https://github.com/sanic-org/sanic-routing/")
11571 (synopsis "Routing component for Sanic")
11572 (description "Internal package for @code{python-sanic}, which provides
11573the @code{BasicRouter}.")
11574 (license license:expat)))
11575
11576(define-public python-sanic-testing
11577 (package
11578 (name "python-sanic-testing")
11579 (version "23.12.0")
11580 (source
11581 (origin
11582 (method url-fetch)
11583 (uri (pypi-uri "sanic-testing" version))
11584 (sha256
11585 (base32 "0gqkzv90sbj9rw7yfly9c58lq9dq30g5hhcgjl3ihzjb66vm571b"))))
11586 (build-system pyproject-build-system)
11587 (arguments
11588 ;; PyPi sources does not contain tests, recursive dependency on
11589 ;; python-sanic.
11590 (list #:tests? #f))
11591 (propagated-inputs (list python-httpx python-sanic-bootstrap))
11592 (native-inputs (list python-setuptools python-wheel))
11593 (home-page "https://github.com/sanic-org/sanic-testing/")
11594 (synopsis "Test clients for Sanic")
11595 (description "Internal package for @code{python-sanic}, which is
11596meant to be the core testing utility and clients for testing Sanic
11597applications.")
11598 (license license:expat)))
11599
11600(define-public python-sanic
11601 (package
11602 (name "python-sanic")
11603 (version "25.3.0")
11604 (source
11605 (origin
11606 (method url-fetch)
11607 (uri (pypi-uri "sanic" version))
11608 (sha256
11609 (base32 "1fv9wgsj54scbr7qhmwdgc4zqnqpwacpakcfxhsg10gc04h54pbp"))
11610 ;; Loosen requirements for both python-sanic and python-sanic-bootstrap.
11611 (modules '((guix build utils)))
11612 (snippet #~(substitute* "setup.py"
11613 (("setuptools>=[0-9.]*")
11614 "setuptools")))))
11615 (build-system pyproject-build-system)
11616 (arguments
11617 (list
11618 #:test-flags
11619 #~(list "--asyncio-mode=auto"
11620 "--ignore=tests/benchmark/"
11621 "--ignore=tests/typing/test_typing.py"
11622 ;; Most tests hang or fail
11623 "--ignore=tests/test_cli.py"
11624 "--ignore=tests/worker/test_worker_serve.py"
11625 "-k"
11626 (string-append
11627 ;; PyPi sources lack examples module.
11628 "not test_gunicorn_"
11629 ;; Does not expect brotli and reordered headers.
11630 " and not test_raw_headers"
11631 ;; These look like buggy testcases.
11632 " and not test_zero_downtime"
11633 " and not test_non_default_uvloop_config_raises_warning"
11634 " and not test_listeners_triggered"
11635 " and not test_keep_alive_connection_context"
11636 " and not test_keep_alive_client_timeout"
11637 " and not test_conflicting_body_methods_overload"
11638 " and not test_unix_connection"
11639 ;; Unclear why they fail since core-updates merge.
11640 " and not test_missing_sni"
11641 " and not test_no_matching_cert"
11642 " and not test_wildcards"
11643 ;; These tests fail because subprotocols appear to be
11644 ;; parameterized as None
11645 " and not test_websocket_route_with_subprotocols"
11646 ;; AF_UNIX path too long
11647 " and not test_setup_and_teardown_unix"
11648 " and not test_configure_socket"
11649 ;; Freezes
11650 " and not test_server_run_with_repl"
11651 " and not test_server_run"
11652 " and not test_no_workers"))))
11653 (propagated-inputs
11654 (list python-aiofiles
11655 python-aioquic
11656 python-html5tagger
11657 python-httptools
11658 python-multidict
11659 python-sanic-routing
11660 python-tracerite
11661 python-typing-extensions
11662 python-ujson
11663 python-uvloop
11664 python-websockets))
11665 (native-inputs
11666 (list python-beautifulsoup4
11667 python-chardet
11668 python-cryptography
11669 python-docutils
11670 python-mypy
11671 python-pygments
11672 python-pytest
11673 python-pytest-asyncio
11674 python-pytest-benchmark
11675 python-pytest-sanic
11676 python-sanic-testing
11677 python-setuptools
11678 python-slotscheck
11679 python-towncrier
11680 python-types-ujson
11681 python-uvicorn
11682 python-wheel))
11683 (home-page "https://github.com/sanic-org/sanic/")
11684 (synopsis "Async Python web server/framework")
11685 (description
11686 "Sanic is a Python web server and web framework that's written to go
11687fast. It allows the usage of the @code{async/await} syntax added in Python
116883.5, which makes your code non-blocking and speedy.")
11689 (license license:expat)))
11690
11691(define-public python-sanic-bootstrap
11692 (package
11693 (inherit python-sanic)
11694 (name "python-sanic-bootstrap")
11695 (arguments (list #:tests? #f))
11696 (native-inputs (list python-setuptools python-wheel))))
11697
11698(define-public python-socketio
11699 (package
11700 (name "python-socketio")
11701 (version "5.12.1")
11702 (source
11703 (origin
11704 (method url-fetch)
11705 (uri (pypi-uri "python_socketio" version))
11706 (sha256
11707 (base32
11708 "175sd3fdld3s477i6b3v49yhf1alsbm1vaxzq44nqrqb8wgzz682"))))
11709 (build-system pyproject-build-system)
11710 (arguments
11711 (list #:test-flags
11712 '(list "--timeout=60"
11713 ;; These tests freeze.
11714 "--ignore-glob=tests/async/*")))
11715 (propagated-inputs
11716 (list python-bidict python-engineio python-msgpack))
11717 (native-inputs
11718 (list python-pytest
11719 python-pytest-asyncio
11720 python-pytest-timeout
11721 python-setuptools
11722 python-uvicorn
11723 python-wheel))
11724 (home-page "https://github.com/miguelgrinberg/python-socketio/")
11725 (synopsis "Python Socket.IO server")
11726 (description
11727 "This package provides a Python implementation of the @code{Socket.IO}
11728realtime client and server.")
11729 (license license:expat)))
11730
11731(define-public python-socks
11732 (package
11733 (name "python-socks")
11734 (version "2.7.2")
11735 (source
11736 (origin
11737 (method git-fetch)
11738 (uri (git-reference
11739 (url "https://github.com/romis2012/python-socks")
11740 (commit (string-append "v" version))))
11741 (file-name (git-file-name name version))
11742 (sha256
11743 (base32 "1alrfjkir69006qmr2ax3inrffk2bllpljwmprwczb44r0mya77m"))))
11744 (build-system pyproject-build-system)
11745 (propagated-inputs (list python-trio))
11746 (native-inputs
11747 (list python-anyio
11748 python-async-timeout
11749 python-flask
11750 python-pytest
11751 python-pytest-asyncio
11752 python-pytest-trio
11753 python-setuptools
11754 python-tiny-proxy
11755 python-trustme
11756 python-yarl))
11757 (home-page "https://github.com/romis2012/python-socks")
11758 (synopsis
11759 "Core proxy (SOCKS4, SOCKS5, HTTP tunneling) functionality for Python")
11760 (description
11761 "Socks is a library providing core proxy (SOCKS4, SOCKS5, HTTP tunneling)
11762 functionality.")
11763 (license license:asl2.0)))
11764
11765(define-public python-socksio
11766 (package
11767 (name "python-socksio")
11768 (version "1.0.0")
11769 (source
11770 (origin
11771 (method url-fetch)
11772 (uri (pypi-uri "socksio" version))
11773 (sha256
11774 (base32 "1b64j45w35jzhjhnq44bnyad9ydh1iyyd7a6j2c8phxmllyyp2zq"))))
11775 (build-system pyproject-build-system)
11776 (native-inputs
11777 (list python-flit-core
11778 python-pytest
11779 python-pytest-cov))
11780 (home-page "https://github.com/sethmlarson/socksio")
11781 (synopsis "Sans-I/O implementation of SOCKS4, SOCKS4A, and SOCKS5")
11782 (description "The @code{socksio} Python module is a client-side sans-I/O
11783SOCKS proxy implementation. It supports SOCKS4, SOCKS4A, and SOCKS5.
11784@code{socksio} is a sans-I/O library similar to @code{h11} or @code{h2}; this
11785means the library itself does not handle the actual sending of the bytes
11786through the network, it only deals with the implementation details of the
11787SOCKS protocols. It can be paired with any I/O library.")
11788 (license license:expat)))
11789
11790(define-public python-simple-websocket
11791 (package
11792 (name "python-simple-websocket")
11793 (version "1.1.0")
11794 (source
11795 (origin
11796 (method url-fetch)
11797 (uri (pypi-uri "simple_websocket" version))
11798 (sha256
11799 (base32 "1r1all55d5dimiw3qwdhj53cxj9yjgnskcysmcscarx0g9726fbr"))))
11800 (build-system pyproject-build-system)
11801 (arguments
11802 ;; Requires Internet access to resolve example.com
11803 (list #:test-flags '(list "--ignore=tests/test_client.py")))
11804 (propagated-inputs (list python-wsproto))
11805 (native-inputs (list python-pytest
11806 python-setuptools))
11807 (home-page "https://github.com/miguelgrinberg/simple-websocket")
11808 (synopsis "Simple WebSocket server and client for Python")
11809 (description "This package provides a simple @code{WebSocket} server and
11810client for Python.")
11811 (license license:expat)))
11812
11813(define-public python-siosocks
11814 (package
11815 (name "python-siosocks")
11816 (version "0.3.0")
11817 (source
11818 (origin
11819 (method git-fetch)
11820 (uri (git-reference
11821 (url "https://github.com/pohmelie/siosocks")
11822 (commit (string-append "v" version))))
11823 (file-name (git-file-name name version))
11824 (sha256
11825 (base32 "0zcib4j5bfxlryfa412wmlkk8ivsiwxrfbpij5s7ag839ii2lxa5"))))
11826 (build-system pyproject-build-system)
11827 (native-inputs
11828 (list python-pytest
11829 python-pytest-asyncio
11830 python-pytest-cov
11831 python-pytest-trio
11832 python-setuptools))
11833 (propagated-inputs (list python-trio))
11834 (home-page "https://github.com/pohmelie/siosocks")
11835 (synopsis "SOCKSv4 & SOCKSv5 TCP proxy protocol implementation in Python")
11836 (description
11837 "This package provides a Python module and framework for sans-io socks proxy
11838client/server with couple io backends.
11839
11840Features:
11841@itemize
11842@item Only TCP connect (no BIND, no UDP)
11843@item Both client and server
11844@item SOCKS versions: 4, 4a, 5
11845@item SOCKSv5 auth: no auth, username/password
11846@item Couple io backends: @code{asyncio}, @code{trio}, @code{socketserver}
11847@item One-shot socks server (@code{python -m siosocks})
11848@end itemize")
11849 (license license:expat)))
11850
11851(define-public python-tiny-proxy
11852 (package
11853 (name "python-tiny-proxy")
11854 (version "0.2.1")
11855 (source
11856 (origin
11857 (method url-fetch)
11858 (uri (pypi-uri "tiny_proxy" version))
11859 (sha256
11860 (base32 "05nq62fn3p7s1a6dkdvnrzmk39d9ddrzb3pqbbli025qs3m9j1bq"))))
11861 (build-system pyproject-build-system)
11862 ;; There are only a handful of tests and they require the as yet
11863 ;; unpackaged httpx_socks.
11864 (arguments (list #:tests? #false))
11865 (propagated-inputs (list python-anyio))
11866 (native-inputs
11867 (list python-httpx
11868 python-pytest
11869 python-setuptools
11870 python-wheel))
11871 (home-page "https://github.com/romis2012/tiny-proxy")
11872 (synopsis "Simple proxy server (SOCKS4(a), SOCKS5(h), HTTP tunnel)")
11873 (description "This package provides a simple proxy server (SOCKS4(a),
11874SOCKS5(h), HTTP tunnel).")
11875 (license license:asl2.0)))
11876
11877(define-public python-azure-nspkg
11878 (package
11879 (name "python-azure-nspkg")
11880 (version "3.0.2")
11881 (source
11882 (origin
11883 (method url-fetch)
11884 (uri (pypi-uri "azure-nspkg" version ".zip"))
11885 (sha256
11886 (base32
11887 "1l4xwdh0fcnvrv0mzig4g2kgqkfbsy64zjm1ggc6grk3mykcxlz7"))))
11888 (build-system pyproject-build-system)
11889 (arguments (list #:tests? #f)) ;no tests in package
11890 (native-inputs (list unzip python-setuptools))
11891 (home-page "https://github.com/Azure/azure-sdk-for-python")
11892 (synopsis "Azure namespace internals")
11893 (description
11894 "This package is an internal Azure namespace package.")
11895 (license license:expat)))
11896
11897(define-public python-azure-storage-nspkg
11898 (package
11899 (name "python-azure-storage-nspkg")
11900 (version "3.1.0")
11901 (source
11902 (origin
11903 (method url-fetch)
11904 (uri (pypi-uri "azure-storage-nspkg" version))
11905 (sha256
11906 (base32 "049qcmgshz7dj9yaqma0fwcgbxwddgwyfcw4gmv45xfmaa3bwfvg"))))
11907 (build-system pyproject-build-system)
11908 (arguments
11909 (list #:tests? #f)) ;no tests in PyPI archive
11910 (native-inputs (list python-setuptools))
11911 (propagated-inputs (list python-azure-nspkg))
11912 (home-page "https://github.com/Azure/azure-storage-python")
11913 (synopsis "Microsoft Azure Storage Namespace package")
11914 (description
11915 "This project provides a client library in Python that makes it easy to
11916communicate with Microsoft Azure Storage services.")
11917 (license license:expat)))
11918
11919(define-public python-azure-common
11920 (package
11921 (name "python-azure-common")
11922 (version "1.1.28")
11923 (source
11924 (origin
11925 (method url-fetch)
11926 (uri (pypi-uri "azure-common" version ".zip"))
11927 (sha256
11928 (base32 "18q4cy1xl2zly3rk7a1sc14w932x59r8c9j4d8dnlsz32hrcvh2a"))))
11929 (build-system pyproject-build-system)
11930 (arguments
11931 (list #:tests? #f)) ;no tests in PyPI archive
11932 (propagated-inputs (list python-azure-nspkg))
11933 (native-inputs (list python-setuptools unzip))
11934 (home-page "https://github.com/Azure/azure-sdk-for-python")
11935 (synopsis "Microsoft Azure Client library for Python")
11936 (description "This package provides the Microsoft Azure Client library for
11937Python.")
11938 (license license:expat)))
11939
11940(define-public python-azure-core
11941 (package
11942 (name "python-azure-core")
11943 (version "1.32.0")
11944 (source
11945 (origin
11946 (method url-fetch)
11947 (uri (pypi-uri "azure_core" version))
11948 (sha256
11949 (base32 "1r9hqyqr5fxiiai0irr0n98gwgzj5f8y46vc1yci9bidddfw7cr2"))))
11950 (build-system pyproject-build-system)
11951 (arguments
11952 (list
11953 #:test-flags
11954 `(list ;; This fails because devtools_testutils doesn't exist.
11955 "--ignore=tests/test_connection_string_parsing.py"
11956 ;; These all need network access.
11957 "--ignore=samples"
11958 "--ignore=tests/async_tests/test_streaming_async.py"
11959 "--ignore=tests/test_streaming.py"
11960 "-m" "not asyncio and not live_test_only"
11961 "-k" ,(string-append
11962 "not test_decompress_plain_no_header"
11963 " and not test_compress_plain_no_header"
11964 " and not test_decompress_compressed_no_header"
11965 " and not test_requests_socket_timeout"))
11966 #:phases
11967 #~(modify-phases %standard-phases
11968 (add-before 'check 'add-test-pythonpath
11969 (lambda* (#:key tests? #:allow-other-keys)
11970 (when tests?
11971 (setenv "PYTHONPATH"
11972 (string-append
11973 (getcwd) "/tests/testserver_tests/coretestserver:"
11974 (getenv "GUIX_PYTHONPATH")))))))))
11975 (propagated-inputs
11976 (list python-aiohttp
11977 python-requests
11978 python-six
11979 python-typing-extensions))
11980 (native-inputs
11981 (list python-flask
11982 python-pytest-8
11983 python-pytest-aiohttp
11984 python-pytest-asyncio
11985 python-pytest-trio
11986 python-setuptools
11987 python-wheel))
11988 (home-page "https://github.com/Azure/azure-sdk-for-python")
11989 (synopsis "Microsoft Azure Core library for Python")
11990 (description "This package provides the Microsoft Azure Core library for
11991Python.")
11992 (license license:expat)))
11993
11994(define-public python-azure-storage-blob
11995 (package
11996 (name "python-azure-storage-blob")
11997 (version "12.27.0")
11998 (source
11999 (origin
12000 (method url-fetch)
12001 (uri (pypi-uri "azure_storage_blob" version))
12002 (sha256
12003 (base32 "16nb17f6bi0k53qlxybwqxdld3nj742hmsk4qcq3jwka5b6y5s4r"))))
12004 (build-system pyproject-build-system)
12005 (arguments
12006 ;; XXX: devtools_testutils is not provided as a proper package on PyPI,
12007 ;; Git does not contains setup.py, setup.cfg or pyproject.toml which makes
12008 ;; it hard to package in Guix.
12009 ;; <https://raw.githubusercontent.com/Azure/azure-sdk-for-python/refs/
12010 ;; heads/main/tools/azure-sdk-tools/devtools_testutils/README.md>.
12011 (list #:tests? #f))
12012 (native-inputs
12013 (list python-setuptools))
12014 (propagated-inputs
12015 (list python-azure-core
12016 python-cryptography
12017 python-isodate
12018 python-typing-extensions))
12019 (home-page "https://github.com/Azure/azure-sdk-for-python/")
12020 (synopsis "Microsoft Azure Blob Storage client library for Python")
12021 (description "This package provides the Microsoft Azure Blob Storage
12022Client Library for Python.")
12023 (license license:expat)))
12024
12025(define-public python-azure-storage-file-datalake
12026 (package
12027 (name "python-azure-storage-file-datalake")
12028 (version "12.22.0")
12029 (source
12030 (origin
12031 (method url-fetch)
12032 (uri (pypi-uri "azure_storage_file_datalake" version))
12033 (sha256
12034 (base32 "0xxg94684b630p8jrz38sg7mdcwp1wa0p5di27mswyrjycshvvcs"))))
12035 (build-system pyproject-build-system)
12036 (arguments
12037 ;; XXX: devtools_testutils is not provided as a proper package on PyPI,
12038 ;; Git does not contains setup.py, setup.cfg or pyproject.toml which makes
12039 ;; it hard to package in Guix.
12040 ;; <https://raw.githubusercontent.com/Azure/azure-sdk-for-python/refs/
12041 ;; heads/main/tools/azure-sdk-tools/devtools_testutils/README.md>.
12042 (list #:tests? #f))
12043 (native-inputs
12044 (list python-setuptools))
12045 (propagated-inputs
12046 (list python-azure-core
12047 python-azure-storage-blob
12048 python-isodate
12049 python-typing-extensions))
12050 (home-page "https://github.com/Azure/azure-sdk-for-python")
12051 (synopsis "Microsoft Azure File DataLake Storage Client Library for Python")
12052 (description
12053 "This package provides the Microsoft Azure File @code{DataLake} Storage
12054Client Library for Python.")
12055 (license license:expat)))
12056
12057(define-public python-google-auth
12058 (package
12059 (name "python-google-auth")
12060 (version "2.48.0")
12061 (source
12062 (origin
12063 (method url-fetch)
12064 (uri (pypi-uri "google_auth" version))
12065 (sha256
12066 (base32 "1kj1r3vp2jk2wv1mc0a5lpdnsivsqciah68ajhyql86k1imp0zjg"))))
12067 (build-system pyproject-build-system)
12068 (arguments
12069 (list
12070 #:test-flags
12071 ;; This one test uses crypto.sign with an outdated calling convention.
12072 '(list "--ignore=tests/transport/test__mtls_helper.py")))
12073 (propagated-inputs
12074 (list python-aiohttp
12075 python-cryptography
12076 python-pyasn1-modules
12077 python-requests
12078 python-rsa
12079 python-urllib3))
12080 (native-inputs
12081 (list nss-certs-for-test
12082 python-aiohttp
12083 python-aioresponses
12084 python-flask
12085 python-freezegun
12086 python-grpcio
12087 python-oauth2client
12088 python-packaging
12089 python-pyjwt
12090 python-pyopenssl
12091 python-pytest
12092 python-pytest-asyncio
12093 python-pytest-localserver
12094 python-pyu2f
12095 python-requests
12096 python-responses
12097 python-rsa
12098 python-setuptools
12099 python-urllib3))
12100 (home-page "https://github.com/googleapis/google-auth-library-python")
12101 (synopsis "Google Authentication Library")
12102 (description "This library simplifies using Google's various
12103server-to-server authentication mechanisms to access Google APIs.")
12104 (license license:asl2.0)))
12105
12106(define-public python-google-resumable-media
12107 (package
12108 (name "python-google-resumable-media")
12109 (version "2.8.0")
12110 (source
12111 (origin
12112 (method git-fetch)
12113 (uri (git-reference
12114 (url
12115 "https://github.com/googleapis/google-resumable-media-python")
12116 (commit (string-append "v" version))))
12117 (file-name (git-file-name name version))
12118 (sha256
12119 (base32 "0ndida5yr06bal0m09yri80bvf8x7yy690b14ywnxl4ixi8rlh6s"))))
12120 (build-system pyproject-build-system)
12121 (arguments
12122 (list
12123 #:test-flags
12124 #~(list
12125 ;; XXX: Missing test_utils.retry.
12126 "--ignore-glob=tests*/system/"
12127 ;; XXX: md5_hash is not mock.sentinel.md5_hash
12128 "-k" (string-join
12129 (list "not test_brotli"
12130 "test_constructor"
12131 "test_decompress")
12132 " and not "))))
12133 (propagated-inputs (list python-google-crc32c))
12134 (native-inputs
12135 (list python-google-auth
12136 python-mock
12137 python-pytest
12138 python-pytest-asyncio
12139 python-setuptools
12140 python-test-utils))
12141 (home-page "https://github.com/googleapis/google-resumable-media-python")
12142 (synopsis "Utilities for Google Media Downloads and Resumable Uploads")
12143 (description "This package provides utilities for Google Media Downloads
12144and Resumable Uploads.")
12145 (license license:asl2.0)))
12146
12147(define-public python-googleapis-common-protos
12148 (package
12149 (name "python-googleapis-common-protos")
12150 (version "1.66.0")
12151 (source
12152 (origin
12153 (method git-fetch)
12154 (uri (git-reference
12155 (url "https://github.com/googleapis/python-api-common-protos")
12156 (commit (string-append "v" version))))
12157 (file-name (git-file-name name version))
12158 (sha256
12159 (base32 "1fb7bcmjngmwwhqrldslli6r5z3s6r2kj4ywjmdjj92d1i51c29r"))))
12160 (build-system pyproject-build-system)
12161 (propagated-inputs (list python-protobuf))
12162 (native-inputs (list python-pytest python-setuptools))
12163 (home-page "https://github.com/googleapis/python-api-common-protos")
12164 (synopsis "Common protobufs used in Google APIs")
12165 (description
12166 "This package contains Python classes generated from the common protos in
12167the @code{googleapis/api-common-protos} repository.")
12168 (license license:asl2.0)))
12169
12170(define-public python-google-api-core
12171 (package
12172 (name "python-google-api-core")
12173 (version "2.29.0")
12174 (source
12175 (origin
12176 (method git-fetch)
12177 (uri (git-reference
12178 (url "https://github.com/googleapis/python-api-core")
12179 (commit (string-append "v" version))))
12180 (file-name (git-file-name name version))
12181 (sha256
12182 (base32 "0ahs8abyl7719paarlnspqp8yds149w7vm3w7zz6f7q04sscd862"))))
12183 (build-system pyproject-build-system)
12184 (propagated-inputs
12185 (list python-google-auth
12186 python-googleapis-common-protos
12187 python-protobuf
12188 python-proto-plus
12189 python-requests))
12190 (native-inputs
12191 (list python-mock
12192 python-pytest
12193 python-pytest-asyncio
12194 python-pytest-mock
12195 python-setuptools))
12196 (home-page "https://github.com/googleapis/python-api-core")
12197 (synopsis "Google API client core library")
12198 (description
12199 "This library defines common helpers used by all Google API clients.")
12200 (license license:asl2.0)))
12201
12202(define-public python-google-cloud-core
12203 (package
12204 (name "python-google-cloud-core")
12205 (version "2.5.0")
12206 (source
12207 (origin
12208 (method git-fetch)
12209 (uri (git-reference
12210 (url "https://github.com/googleapis/python-cloud-core")
12211 (commit (string-append "v" version))))
12212 (file-name (git-file-name name version))
12213 (sha256
12214 (base32 "1d7li74cakgl9vghxfir9nxwy36980alvxwgwjg0zyla3hgj07cq"))))
12215 (build-system pyproject-build-system)
12216 (propagated-inputs (list python-google-api-core python-google-auth))
12217 (native-inputs
12218 (list python-grpcio
12219 python-grpcio-status
12220 python-pytest
12221 python-setuptools))
12222 (home-page "https://github.com/googleapis/python-cloud-core")
12223 (synopsis "Google Cloud API client core library")
12224 (description
12225 "This library defines common helpers (e.g. base @code{Client} classes)
12226used by all of the @code{google-cloud-*} packages.")
12227 (license license:asl2.0)))
12228
12229(define-public python-google-cloud-storage
12230 (package
12231 (name "python-google-cloud-storage")
12232 (version "2.19.0")
12233 (source
12234 (origin
12235 (method git-fetch)
12236 (uri (git-reference
12237 (url "https://github.com/googleapis/python-storage")
12238 (commit (string-append "v" version))))
12239 (file-name (git-file-name name version))
12240 (sha256
12241 (base32 "19w10v2j4ciwlf8j2ylm77f8z1b0kqzg8lkh9rvh2swv1zrhydpj"))))
12242 (build-system pyproject-build-system)
12243 (arguments
12244 (list
12245 #:test-flags
12246 #~(list
12247 ;; XXX: Missing test_utils.retry.
12248 "--ignore=tests/system/"
12249 ;; Needs docker.
12250 "--ignore=tests/conformance/"
12251 ;; XXX: Deprecations.
12252 "-k" (string-join
12253 (list "not test_set_api_request_attr"
12254 "test_create_bucket_w_custom_endpoint"
12255 "test_ctor_w_api_endpoint_override"
12256 "test_ctor_w_custom_endpoint_use_auth"
12257 "test_list_buckets_w_custom_endpoint")
12258 " and not ")
12259 "tests")))
12260 (native-inputs
12261 (list python-googleapis-common-protos
12262 python-mock
12263 python-pytest
12264 python-test-utils
12265 python-setuptools))
12266 (propagated-inputs
12267 (list python-google-api-core
12268 python-google-auth
12269 python-google-cloud-core
12270 python-google-resumable-media
12271 python-protobuf
12272 python-requests))
12273 (home-page "https://github.com/googleapis/python-storage")
12274 (synopsis "Google Cloud Storage API client library")
12275 (description
12276 "Google Cloud Storage allows you to store data on Google infrastructure,
12277and it can be used to distribute large data objects to users via direct
12278download. This package provides a Google Cloud Storage API client library for
12279Python.")
12280 (license license:asl2.0)))
12281
12282(define-public python-smart-open
12283 (package
12284 (name "python-smart-open")
12285 (version "7.3.0")
12286 (source
12287 (origin
12288 (method git-fetch) ;no tests in PyPI archive
12289 (uri (git-reference
12290 (url "https://github.com/piskvorky/smart_open")
12291 (commit (string-append "v" version))))
12292 (file-name (git-file-name name version))
12293 (sha256
12294 (base32 "1jk3dj0j7idv94g1ga5wyvybakj4l150g26cbsjkrjfpy017vxab"))))
12295 (build-system pyproject-build-system)
12296 (arguments
12297 (list
12298 #:test-flags
12299 #~(list "--ignore=ci_helpers/"
12300 "--ignore=integration-tests/"
12301 ;; FIXME: Enable when guix/guix#1436 is resolved.
12302 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri"
12303 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri_contains_question_mark"
12304 "--deselect=tests/test_smart_open.py::ParseUriTest::test_gs_uri_contains_slash"
12305 "--deselect=tests/test_smart_open.py::ParseUriTest::test_scheme"
12306 "--ignore=tests/test_gcs.py")))
12307 (propagated-inputs
12308 (list python-azure-common
12309 python-azure-core
12310 python-azure-storage-blob
12311 python-boto3
12312 ;; python-google-cloud-storage ;see guix/guix#1436
12313 python-paramiko
12314 python-requests
12315 python-wrapt
12316 python-zstandard))
12317 (native-inputs
12318 (list python-numpy
12319 python-moto
12320 python-pytest
12321 python-pytest-rerunfailures
12322 python-responses
12323 python-setuptools
12324 python-setuptools-scm
12325 python-wheel))
12326 (home-page "https://github.com/piskvorky/smart_open")
12327 (synopsis "Utilities for streaming large files")
12328 (description
12329 "This package provides utilities for streaming large files (S3, HDFS,
12330GCS, Azure Blob Storage, gzip, bz2, etc.)")
12331 (license license:expat)))
12332
12333(define-public python-smart-open-6
12334 (package
12335 (inherit python-smart-open)
12336 (name "python-smart-open")
12337 (version "6.4.0")
12338 (source
12339 (origin
12340 (method git-fetch)
12341 (uri (git-reference
12342 (url "https://github.com/piskvorky/smart_open")
12343 (commit (string-append "v" version))))
12344 (file-name (git-file-name name version))
12345 (sha256
12346 (base32 "1vpx37b6lsb6iwi59776ywjrqk1czv8arlhaf9073lrsbilqvj3x"))))
12347 (arguments
12348 (list
12349 ;; XXX: Tests need some older native inputs, disable for now.
12350 #:tests? #f))))
12351
12352(define-public python-w3lib
12353 (package
12354 (name "python-w3lib")
12355 (version "2.3.1")
12356 (source
12357 (origin
12358 (method url-fetch)
12359 (uri (pypi-uri "w3lib" version))
12360 (sha256
12361 (base32
12362 "1929layzxwdnf43hhrz7rabv388b2yibj7mnq9s62mr760mc12jw"))))
12363 (build-system pyproject-build-system)
12364 (native-inputs
12365 (list python-pytest python-setuptools python-wheel))
12366 (home-page "https://github.com/scrapy/w3lib")
12367 (synopsis "Python library of web-related functions")
12368 (description
12369 "This is a Python library of web-related functions, such as: remove
12370comments, or tags from HTML snippets, extract base url from HTML snippets,
12371translate entities on HTML strings, among other things.")
12372 (license license:bsd-3)))
12373
12374(define-public python-webcolors
12375 (package
12376 (name "python-webcolors")
12377 (version "24.11.1")
12378 (source
12379 (origin
12380 (method url-fetch)
12381 (uri (pypi-uri "webcolors" version))
12382 (sha256
12383 (base32 "1xl0vn4xa03vjwx6fj19q9kgb94g65gvdf3p0ivsy0i2ydldgczc"))))
12384 (build-system pyproject-build-system)
12385 (arguments
12386 (list
12387 #:phases
12388 '(modify-phases %standard-phases
12389 (add-after 'unpack 'patch-pyproject
12390 (lambda _
12391 ;; XXX Our version of python-pdm-backend does not recognize
12392 ;; "dependency-groups", but is fine with the bogus
12393 ;; "tool.whatever".
12394 (substitute* "pyproject.toml"
12395 (("\\[dependency-groups\\]") "[tool.whatever]")))))))
12396 (native-inputs
12397 (list python-pdm-backend python-pytest))
12398 (home-page "https://github.com/ubernostrum/webcolors")
12399 (synopsis "HTML/CSS color definitions library")
12400 (description "@code{python-webcolors} is a module for working with
12401HTML/CSS color definitions. Normalizing and converting between the following
12402formats is supported.
12403@itemize
12404@item Specification-defined color names
12405@item Six-digit hexadecimal
12406@item Three-digit hexadecimal
12407@item Integer rgb() triplet
12408@item Percentage rgb() triplet
12409@end itemize
12410Only the RGB colorspace is supported. Conversion to/from the HSL colorspace
12411can be handled by the @code{colorsys} module in the Python standard library.")
12412 (license license:bsd-3)))
12413
12414(define-public python-woob
12415 ;; TODO: woob requires backends which are currently installed on the fly in
12416 ;; ~/.local/share/woob/modules/3.7/woob_modules/ , perhaps we should install
12417 ;; them in the store instead. Many modules are included in the modules
12418 ;; directory in the source tree, but it is unclear how to install them.
12419 ;; Many modules require extra dependencies though, so maybe they should be
12420 ;; packaged independently of woob itself.
12421 (package
12422 (name "python-woob")
12423 (version "3.7")
12424 (source
12425 (origin
12426 (method git-fetch)
12427 (uri (git-reference
12428 (url "https://gitlab.com/woob/woob.git")
12429 (commit version)))
12430 (file-name (git-file-name name version))
12431 (sha256
12432 (base32 "1sy0aykff56xs4dnc7ak6m8is2zgz9fprf3i1pk8n861xz1z748i"))))
12433 (build-system pyproject-build-system)
12434 (arguments
12435 (list
12436 #:test-flags
12437 ;; Deselect tests that require DNS lookup.
12438 #~(list
12439 "--deselect=tests/browser/adapters.py::TestAdapter::test_ciphers"
12440 "--deselect=tests/browser/browsers.py::TestBrowser::test_verify")
12441 #:phases
12442 #~(modify-phases %standard-phases
12443 (add-before 'build 'relax-requirements
12444 (lambda _
12445 (substitute* "pyproject.toml"
12446 ;; packaging ~= 23.0
12447 (("\"packaging .*\",")
12448 "")
12449 ;; rich~=13.0
12450 (("\"rich .*\",")
12451 "\"rich\",")))))))
12452 (native-inputs
12453 (list nss-certs-for-test
12454 python-pytest
12455 python-setuptools))
12456 (propagated-inputs
12457 (list python-babel
12458 python-colorama
12459 python-cssselect
12460 python-dateutil
12461 python-feedparser
12462 python-html2text
12463 python-lxml
12464 python-packaging
12465 python-pillow
12466 python-prettytable
12467 python-pycountry
12468 python-pyyaml
12469 python-requests
12470 python-responses
12471 python-rich
12472 python-termcolor
12473 python-unidecode))
12474 (home-page "https://woob.tech/")
12475 (synopsis "Woob, Web Outside Of Browsers")
12476 (description
12477 "Woob is a collection of applications able to interact with
12478websites, without requiring the user to open them in a browser. It also
12479provides well-defined APIs to talk to websites lacking one.")
12480 (license license:lgpl3+)))
12481
12482(define-public python-flask-combo-jsonapi
12483 (let ((commit "3cfff98ecdbadc45d25a3fd443ad67d3743be6f5")
12484 (revision "0"))
12485 (package
12486 (name "python-flask-combo-jsonapi")
12487 (version (git-version "1.1.0" revision commit))
12488 (source
12489 (origin
12490 (method git-fetch)
12491 (uri (git-reference
12492 (url "https://github.com/AdCombo/flask-combo-jsonapi")
12493 (commit commit)))
12494 (file-name (git-file-name name version))
12495 (sha256
12496 (base32 "1lp81v96qh9hdj3c95kvfaq0vy5vd8cm55j03aszc93bs8z5jg7h"))))
12497 (build-system pyproject-build-system)
12498 (arguments
12499 (list
12500 #:test-flags
12501 #~(list
12502 "-k"
12503 (string-join
12504 (list
12505 ;; XXX: This tests a feature that doesn't make sense when dropping
12506 ;; marshmallow < 3 support.
12507 "not test_compute_schema_propagate_context"
12508 ;; The following tests fail for unknown reasons (see:
12509 ;; https://github.com/AdCombo/flask-combo-jsonapi/issues/66).
12510 "test_get_list_with_simple_filter_relationship_custom_qs_api"
12511 "test_get_list_with_simple_filter_relationship_error")
12512 " and not "))
12513 #:phases
12514 #~(modify-phases %standard-phases
12515 (add-after 'unpack 'loosen-requirements
12516 (lambda _
12517 ;; Don't pin specific versions of dependencies.
12518 (substitute* "requirements.txt"
12519 (("^(sqlalchemy|marshmallow|Flask)[=<>].*" _ dep)
12520 (string-append dep "\n"))
12521 (("^marshmallow_jsonapi[=<>].*")
12522 "marshmallow_jsonapi_minfork\n"))
12523 ;; Drop support for marshmallow < 3.
12524 (substitute* (list "flask_combo_jsonapi/data_layers/alchemy.py"
12525 "flask_combo_jsonapi/schema.py")
12526 (("from marshmallow\\.base import SchemaABC")
12527 "from marshmallow import Schema")
12528 (("if isinstance\\(related_schema_cls, SchemaABC\\):")
12529 "if isinstance(related_schema_cls, Schema):"))
12530 (substitute* "tests/test_sqlalchemy_data_layer.py"
12531 (("default=None")
12532 "dump_default=None")
12533 (("missing=")
12534 "load_default=")))))))
12535 (propagated-inputs
12536 (list python-flask
12537 python-marshmallow
12538 python-marshmallow-jsonapi
12539 python-simplejson
12540 python-sqlalchemy
12541 python-apispec
12542 python-simplejson
12543 python-six))
12544 (native-inputs
12545 (list python-pytest python-setuptools))
12546 (home-page "https://github.com/AdCombo/flask-combo-jsonapi")
12547 (synopsis "Flask extension to quickly create JSON:API 1.0 REST Web APIs")
12548 (description
12549 "Flask-COMBO-JSONAPI is a Python Flask extension for building REST Web
12550APIs compliant with the @uref{https://jsonapi.org, JSON:API 1.0}
12551specification.
12552
12553It tries to combine the power of Flask-Restless with the flexibility of
12554Flask-RESTful to quickly build APIs that fit the complexity of existing
12555real-life projects with legacy data and diverse storage providers.")
12556 (license license:expat))))
12557
12558(define-public python-mwparserfromhell
12559 (package
12560 (name "python-mwparserfromhell")
12561 (version "0.7.2")
12562 (source
12563 (origin
12564 (method git-fetch)
12565 (uri (git-reference
12566 (url "https://github.com/earwig/mwparserfromhell")
12567 (commit (string-append "v" version))))
12568 (file-name (git-file-name name version))
12569 (sha256
12570 (base32 "083ir0nccm14431mmn243862gq731ww98fwpd95zm1yccvpzdy68"))))
12571 (build-system pyproject-build-system)
12572 (native-inputs (list python-pytest python-setuptools))
12573 (home-page "https://github.com/earwig/mwparserfromhell")
12574 (synopsis "Python parser for MediaWiki wikicode")
12575 (description
12576 "The MediaWiki Parser From Hell is a python library package that provides
12577a parser for MediaWiki.
12578
12579It exposes parses as normal string objects with additional methods giving
12580access to the special Wikicode features it contains (hyperlinks, tags,
12581templates…). The parser doesn't interpolate strings at all, it remains at a
12582purely formal level.
12583
12584Full documentation may be found at
12585@uref{https://mwparserfromhell.readthedocs.io, ReadTheDocs}")
12586 (license license:expat)))
12587
12588(define-public python-tweepy
12589 (package
12590 (name "python-tweepy")
12591 (version "4.16.0")
12592 (source
12593 (origin
12594 (method git-fetch)
12595 (uri
12596 (git-reference
12597 (url "https://github.com/tweepy/tweepy")
12598 (commit (string-append "v" version))))
12599 (file-name (git-file-name name version))
12600 (sha256
12601 (base32 "1k99qf0h1ykz0c56wdnlsyvd6zrcsrc4rl7rnlaxrpjppxjnpcpn"))))
12602 (build-system pyproject-build-system)
12603 (arguments
12604 ;; tests: 149 passed, 3 skipped, 1 warning
12605 (list #:test-backend #~'unittest
12606 #:test-flags #~(list "discover" "tests")))
12607 (native-inputs
12608 (list nss-certs-for-test
12609 python-flit-core
12610 python-urllib3-1.26
12611 python-vcrpy))
12612 (propagated-inputs
12613 (list python-aiohttp
12614 python-async-lru
12615 python-oauthlib
12616 python-requests
12617 python-requests-oauthlib))
12618 (home-page "https://www.tweepy.org/")
12619 (synopsis "Twitter library for Python")
12620 (description
12621 "This package provides @code{Tweepy}, an easy-to-use Python library for
12622accessing the Twitter API.")
12623 (license license:expat)))
12624
12625(define-public python-quart
12626 (package
12627 (name "python-quart")
12628 (version "0.19.9")
12629 (source
12630 (origin
12631 (method git-fetch) ; no tests in PyPI release
12632 (uri (git-reference
12633 (url "https://github.com/pallets/quart")
12634 (commit version)))
12635 (file-name (git-file-name name version))
12636 (sha256
12637 (base32 "1h5ifv8g9dc9m07vj4v7dfalam83v38545d845vvgys1gan1pscd"))))
12638 (build-system pyproject-build-system)
12639 (arguments
12640 (list
12641 #:phases
12642 #~(modify-phases %standard-phases
12643 (add-after 'unpack 'remove-coverage-pytest-options
12644 (lambda _
12645 (substitute* "pyproject.toml"
12646 (("--no-cov-on-fail") "")))))))
12647 (native-inputs
12648 (list python-poetry-core
12649 python-pytest
12650 python-pytest-asyncio))
12651 (propagated-inputs
12652 (list hypercorn
12653 python-aiofiles
12654 python-blinker
12655 python-click
12656 python-dotenv
12657 python-flask
12658 python-itsdangerous
12659 python-jinja2
12660 python-markupsafe
12661 python-toml
12662 python-werkzeug))
12663 (home-page "https://gitlab.com/pgjones/quart/")
12664 (synopsis "Python ASGI web microframework with the same API as Flask")
12665 (description
12666 "This package provides a Python ASGI web microframework with the same API
12667as Flask.")
12668 (license license:expat)))
12669
12670(define-public python-quart-trio
12671 (package
12672 (name "python-quart-trio")
12673 (version "0.12.0")
12674 (source
12675 (origin
12676 (method url-fetch)
12677 (uri (pypi-uri "quart_trio" version))
12678 (sha256
12679 (base32 "130r8hdk7xxjp380z1r3m28lw86q2a6g9rf0mgp9gs6hk04q9v02"))))
12680 (build-system pyproject-build-system)
12681 (arguments
12682 (list
12683 #:phases
12684 #~(modify-phases %standard-phases
12685 (add-after 'unpack 'remove-coverage-pytest-options
12686 (lambda _
12687 (substitute* "pyproject.toml"
12688 (("--no-cov-on-fail") "")))))))
12689 (native-inputs
12690 (list python-pdm-backend
12691 python-pytest
12692 python-pytest-sugar
12693 python-pytest-trio))
12694 (propagated-inputs
12695 (list hypercorn
12696 python-quart
12697 python-trio))
12698 (home-page "https://github.com/pgjones/quart-trio")
12699 (synopsis "Extension for Quart to support the Trio event loop")
12700 (description
12701 "This package provides a Quart extension to provide Trio support. This
12702is an alternative to using the asyncio event loop present in the Python
12703standard library and supported by default in Quart.")
12704 (license license:expat)))
12705
12706(define-public python-ajsonrpc
12707 (package
12708 (name "python-ajsonrpc")
12709 (version "1.2.0")
12710 (source
12711 (origin
12712 (method git-fetch)
12713 (uri (git-reference
12714 (url "https://github.com/pavlov99/ajsonrpc")
12715 (commit version)))
12716 (file-name (git-file-name name version))
12717 (sha256
12718 (base32 "0c7jxfkv5q2m95j54dn650gcvdbpag2qcki7phvmrwsgb36w09kd"))))
12719 (build-system pyproject-build-system)
12720 (arguments
12721 (list
12722 #:phases
12723 #~(modify-phases %standard-phases
12724 (add-after 'unpack 'set-version
12725 (lambda _
12726 (substitute* "ajsonrpc/__init__.py"
12727 (("^__version__ = .*")
12728 (string-append "__version__ = \"" #$version "\"\n"))))))))
12729 (native-inputs
12730 (list python-pytest
12731 python-setuptools))
12732 (propagated-inputs
12733 (list python-quart
12734 python-sanic
12735 python-tornado))
12736 (home-page "https://github.com/pavlov99/ajsonrpc")
12737 (synopsis "Async JSON-RPC 2.0 protocol and server")
12738 (description
12739 "This package provides a Python JSON-RPC 2.0 protocol and server powered
12740by asyncio.")
12741 (license license:expat)))
12742
12743(define-public python-protego
12744 (package
12745 (name "python-protego")
12746 (version "0.4.0")
12747 (source
12748 (origin
12749 (method url-fetch)
12750 (uri (pypi-uri "protego" version))
12751 (sha256
12752 (base32 "1xn2aska8v94jqnbyv4ywczb55gaqvr298q8ybhs168knrifd9ck"))))
12753 (build-system pyproject-build-system)
12754 (native-inputs (list python-pytest python-setuptools python-wheel))
12755 (home-page "https://github.com/scrapy/protego")
12756 (synopsis "Python robots.txt parser with support for modern conventions")
12757 (description "Protego is a pure-Python @file{robots.txt} parser with support
12758for modern conventions.")
12759 (license license:bsd-3)))
12760
12761(define-public python-parsel
12762 (package
12763 (name "python-parsel")
12764 (version "1.10.0")
12765 (source
12766 (origin
12767 (method url-fetch)
12768 (uri (pypi-uri "parsel" version))
12769 (sha256
12770 (base32 "1050v20gzijfcaxpm1d4bvxqw2l7xhyf9pxrawrv8lczanwpvw8l"))))
12771 (build-system pyproject-build-system)
12772 (propagated-inputs
12773 (list python-cssselect
12774 python-jmespath
12775 python-lxml
12776 python-typing-extensions
12777 python-w3lib))
12778 (native-inputs
12779 (list python-psutil python-pytest python-setuptools python-wheel))
12780 (home-page "https://github.com/scrapy/parsel")
12781 (synopsis "Extract data from HTML and XML using XPath and CSS selectors")
12782 (description "Parsel is a library to extract and remove data from
12783HTML and XML using XPath and CSS selectors, optionally combined with
12784regular expressions.")
12785 (license license:bsd-3)))
12786
12787(define-public python-scrapy
12788 (package
12789 (name "python-scrapy")
12790 (version "2.13.3")
12791 (source
12792 (origin
12793 (method url-fetch)
12794 (uri (pypi-uri "scrapy" version))
12795 (sha256
12796 (base32 "0k90pni6vkj7axx3cji0b2x7yg4yfh5kh1csqiq9ssp42265h5xz"))))
12797 (build-system pyproject-build-system)
12798 (arguments
12799 (list #:test-flags
12800 #~(list "--numprocesses" (number->string (parallel-job-count))
12801 "-k" (string-join
12802 ;; ConnectionRefusedError: [Errno 111] Connection
12803 ;; refused
12804 (list "not test_append"
12805 "test_append_active_mode"
12806 "test_overwrite"
12807 "test_overwrite_active_mode"
12808 "test_persist"
12809 ;; AssertionError
12810 "test_start_deprecated_super")
12811 " and not ")
12812 ;; Skip documentation testing.
12813 "--ignore=docs")
12814 #:phases
12815 #~(modify-phases %standard-phases
12816 (add-before 'check 'prepare-test-environment
12817 (lambda _
12818 (setenv "HOME" "/tmp"))))))
12819 (propagated-inputs
12820 (list python-cryptography
12821 python-cssselect
12822 python-defusedxml
12823 python-itemadapter
12824 python-itemloaders
12825 python-lxml
12826 python-packaging
12827 python-parsel
12828 python-protego
12829 python-pydispatcher
12830 python-pyopenssl
12831 python-pypydispatcher
12832 python-queuelib
12833 python-service-identity
12834 python-tldextract
12835 python-twisted
12836 python-w3lib
12837 python-zope-interface))
12838 (native-inputs
12839 (list nss-certs-for-test
12840 python-hatchling
12841 python-pexpect
12842 python-pytest
12843 python-pytest-xdist
12844 python-setuptools
12845 python-sybil
12846 python-testfixtures))
12847 (home-page "https://scrapy.org")
12848 (synopsis "High-level Web crawling and Web scraping framework")
12849 (description "Scrapy is a fast high-level web crawling and web
12850scraping framework, used to crawl websites and extract structured data
12851from their pages. It can be used for a wide range of purposes, from data
12852mining to monitoring and automated testing.")
12853 (license license:bsd-3)))
12854
12855(define-public python-jstyleson
12856 (let ((commit "8c47cc9e665b3b1744cccfaa7a650de5f3c575dd")
12857 (revision "0"))
12858 (package
12859 (name "python-jstyleson")
12860 (version (git-version "0.0.2" revision commit))
12861 (source
12862 (origin
12863 (method git-fetch)
12864 (uri (git-reference
12865 (url "https://github.com/linjackson78/jstyleson")
12866 (commit commit)))
12867 (file-name (git-file-name name version))
12868 (sha256
12869 (base32 "0r72mq7h294w5icpdbjd202w25kwr1dz7nh79f6m74xisc9cixia"))))
12870 (build-system pyproject-build-system)
12871 (native-inputs (list python-pytest python-setuptools))
12872 (home-page "https://github.com/linjackson78/jstyleson")
12873 (synopsis "JSON parser supporting js-style comments")
12874 (description
12875 "@code{jstyleson} is a Python library to parse JSON. Contrary to the
12876standard Python @code{json} library, it understands js-style comments.
12877Trailing comma is also supported.")
12878 (license license:expat))))
12879
12880(define-public python-html-text
12881 (package
12882 (name "python-html-text")
12883 (version "0.7.0")
12884 (source
12885 (origin
12886 (method url-fetch)
12887 (uri (pypi-uri "html_text" version))
12888 (sha256
12889 (base32 "10lixghras86av966ha9piqfl1iscf7nffg69dmz13sxjh371jrx"))))
12890 (build-system pyproject-build-system)
12891 (native-inputs
12892 (list python-pytest
12893 python-setuptools
12894 python-wheel))
12895 (propagated-inputs
12896 (list python-lxml
12897 python-lxml-html-clean))
12898 (home-page "https://github.com/TeamHG-Memex/html-text")
12899 (synopsis "Extract text from HTML")
12900 (description "HTML to Text is a Python library for extract text from HTML.
12901Contrary to other solution such as LXML or Beautiful Soup, the text extracted
12902with @code{html_text} does not contain elements such as JavaScript or inline
12903styles not normally visible to users. It also normalizes white space
12904characters in a smarter, more visually pleasing style.")
12905 (license license:expat)))
12906
12907(define-public python-mf2py
12908 (package
12909 (name "python-mf2py")
12910 (version "2.0.1")
12911 (source
12912 (origin
12913 (method git-fetch)
12914 (uri (git-reference
12915 (url "https://github.com/microformats/mf2py")
12916 (commit (string-append "v" version))))
12917 (file-name (git-file-name name version))
12918 (sha256
12919 (base32 "0ajnf0zrh1l48fvix9fbs1qvgbqhiljqnrm51rx44p7dbarpw4ls"))))
12920 (build-system pyproject-build-system)
12921 (native-inputs (list python-mock python-poetry-core python-pytest))
12922 (propagated-inputs
12923 (list python-beautifulsoup4 python-html5lib python-requests))
12924 (home-page "https://github.com/microformats/mf2py")
12925 (synopsis "Python Microformats2 parser")
12926 (description
12927 "This Python library provides a Microformats2 parser implementing the
12928full Microformats2 (mf2) specification, including backward compatibility with
12929Microformats1 (mf1).")
12930 (license license:expat)))
12931
12932(define-public python-extruct
12933 (package
12934 (name "python-extruct")
12935 (version "0.18.0")
12936 (source (origin
12937 (method git-fetch) ;for tests
12938 (uri (git-reference
12939 (url "https://github.com/scrapinghub/extruct")
12940 (commit (string-append "v" version))))
12941 (file-name (git-file-name name version))
12942 (sha256
12943 (base32
12944 "03qdldqrvmbsk6klq4nkxvvp3b2a0qqgqg115i3crbmialiaai45"))))
12945 (build-system pyproject-build-system)
12946 (arguments
12947 (list
12948 #:test-flags
12949 ;; 67 passed, 3 deselected
12950 ;; XXX: 3 tests fail with errors in assertion.
12951 #~(list "-k" (string-append
12952 "not test_microformat"
12953 " and not test_microformat"
12954 " and not test_umicroformat"))))
12955 (native-inputs
12956 (list python-pytest
12957 python-setuptools
12958 python-wheel))
12959 (propagated-inputs
12960 (list python-html-text
12961 python-jstyleson
12962 python-lxml
12963 python-mf2py
12964 python-pyrdfa3
12965 python-rdflib
12966 python-w3lib))
12967 (home-page "https://github.com/scrapinghub/extruct")
12968 (synopsis "Extract embedded metadata from HTML markup")
12969 (description "@code{extruct} is a Python library for extracting embedded
12970metadata from HTML markup. Currently, extruct supports:
12971@itemize
12972@item W3C's HTML Microdata
12973@item embedded JSON-LD
12974@item Microformat via mf2py
12975@item Facebook's Open Graph
12976@item (experimental) RDFa via rdflib
12977@item Dublin Core Metadata (DC-HTML-2003)
12978@end itemize")
12979 (license license:bsd-3)))
12980
12981(define-public python-wadllib
12982 (package
12983 (name "python-wadllib")
12984 (version "2.0.0")
12985 (source
12986 (origin
12987 (method url-fetch)
12988 (uri (pypi-uri "wadllib" version))
12989 (sha256
12990 (base32 "09vlfg4mzdmkqk6br7j8ms3116qk5am0nf4v1jkzwd7swhisznqy"))))
12991 (build-system pyproject-build-system)
12992 (arguments
12993 (list
12994 ;; XXX: Doctests are currently failing.
12995 #:tests? #f
12996 #:phases
12997 #~(modify-phases %standard-phases
12998 (replace 'check
12999 (lambda* (#:key tests? #:allow-other-keys)
13000 (if tests?
13001 (invoke "zope-testrunner" "--test-path=src")
13002 (format #t "test suite not run~%")))))))
13003 (native-inputs
13004 (list python-multipart python-setuptools python-zope-testrunner))
13005 (propagated-inputs (list python-lazr-uri))
13006 (home-page "https://launchpad.net/wadllib")
13007 (synopsis "Web Application Description Language (WADL) navigation library")
13008 (description "The @code{wadllib} Python library allows navigating HTTP
13009resources using Web Application Description Language (WADL) files as guides.")
13010 (license license:lgpl3)))
13011
13012(define-public python-zeep
13013 (package
13014 (name "python-zeep")
13015 (version "4.3.1")
13016 (source
13017 (origin
13018 (method url-fetch)
13019 (uri (pypi-uri "zeep" version))
13020 (sha256
13021 (base32 "0vm0asfak0pxfa9i753imcy72hk8gkxbj6pmw185b7dhw7lqalzl"))))
13022 (build-system pyproject-build-system)
13023 (arguments
13024 (list
13025 #:phases
13026 '(modify-phases %standard-phases
13027 (add-after 'unpack 'compatibility
13028 (lambda _
13029 ;; Relax requests-file requirement.
13030 (substitute* "pyproject.toml"
13031 (("\"requests-file.*\",")
13032 "\"requests-file\","))
13033 ;; httpx removed the "proxies" keyword. It's now either "mounts"
13034 ;; or "proxy". See https://github.com/encode/httpx/pull/2879.
13035 (substitute* "src/zeep/transports.py"
13036 (("proxies=") "proxy="))))
13037 ;; One test requires write access
13038 (add-before 'check 'set-HOME
13039 (lambda _ (setenv "HOME" (getcwd)))))))
13040 (propagated-inputs
13041 (list python-attrs
13042 python-isodate
13043 python-lxml
13044 python-platformdirs
13045 python-pytz
13046 python-requests
13047 python-requests-file
13048 python-requests-toolbelt))
13049 (native-inputs
13050 (list nss-certs-for-test
13051 python-freezegun
13052 python-pretend
13053 python-pytest
13054 python-pytest-asyncio
13055 python-pytest-cov
13056 python-pytest-httpx
13057 python-requests-mock
13058 python-setuptools
13059 python-wheel))
13060 (home-page "https://docs.python-zeep.org/en/stable/")
13061 (synopsis "Python SOAP client based on lxml / requests")
13062 (description "Zeep is a Python SOAP client. Highlights:
13063
13064@itemize
13065@item Build on top of @code{lxml} and @code{requests}.
13066@item Support for Soap 1.1, Soap 1.2 and HTTP bindings.
13067@item Support for WS-Addressing headers.
13068@item Support for WSSE (UserNameToken / x.509 signing).
13069@item Support for @code{asyncio} via @code{httpx}.
13070@item Experimental support for XOP messages.
13071@end itemize")
13072 (license license:expat)))
13073
13074(define-public python-http-client
13075 (package
13076 (name "python-http-client")
13077 (version "3.3.7")
13078 (source
13079 (origin
13080 (method git-fetch)
13081 (uri (git-reference
13082 (url "https://github.com/sendgrid/python-http-client")
13083 (commit version)))
13084 (file-name (git-file-name name version))
13085 (sha256
13086 (base32 "0z0ziw3f4zw5fj4spiwhhs2x8qs3i5999ry2p6a5sc8b1lkkj2zi"))))
13087 (build-system pyproject-build-system)
13088 (arguments
13089 (list
13090 #:test-backend #~'unittest
13091 #:phases
13092 #~(modify-phases %standard-phases
13093 (add-after 'unpack 'fix-tests
13094 (lambda _
13095 ;; The test expects the copyright to be updated each year.
13096 (substitute* "tests/test_daterange.py"
13097 (("time\\.strftime\\(\"%Y\"\\)") "2022")))))))
13098 (native-inputs
13099 (list python-setuptools))
13100 (home-page "https://github.com/sendgrid/python-http-client")
13101 (synopsis "HTTP REST client for Python")
13102 (description
13103 "This package provides access to any RESTful or RESTful-like API.")
13104 (license license:expat)))
13105
13106(define-public python-sendgrid
13107 (package
13108 (name "python-sendgrid")
13109 (version "6.9.7")
13110 (source
13111 (origin
13112 (method git-fetch)
13113 (uri (git-reference
13114 (url "https://github.com/sendgrid/sendgrid-python")
13115 (commit version)))
13116 (file-name (git-file-name name version))
13117 (sha256
13118 (base32 "0kvp4gm3bpcsj2mkv05pgvlcv1jlsfhcljcv61wz5kq9d273h7rg"))))
13119 (build-system pyproject-build-system)
13120 (arguments
13121 (list
13122 #:test-flags
13123 #~(list "--ignore=test/integ"
13124 ;; Network access is required.
13125 "--ignore=live_test.py")))
13126 (native-inputs
13127 (list python-pytest
13128 python-setuptools))
13129 (propagated-inputs
13130 (list python-cryptography
13131 python-http-client
13132 python-flask
13133 python-pyyaml
13134 python-six ;hard dependency
13135 python-starkbank-ecdsa
13136 python-werkzeug))
13137 (home-page "https://github.com/sendgrid/sendgrid-python/")
13138 (synopsis "SendGrid API library for Python")
13139 (description
13140 "The @code{sendgrid} Python library allows access to the
13141SendGrid Web API v3. Version 3+ of the library provides full support for all
13142SendGrid Web API v3 endpoints, including the new v3 /mail/send.")
13143 (license license:expat)))
13144
13145(define-public python-sse-starlette
13146 (package
13147 (name "python-sse-starlette")
13148 (version "3.1.2")
13149 (source
13150 (origin
13151 (method git-fetch)
13152 (uri (git-reference
13153 (url "https://github.com/sysid/sse-starlette")
13154 (commit (string-append "v" version))))
13155 (file-name (git-file-name name version))
13156 (sha256
13157 (base32 "0cs4218jc8fa9x362vdigdpz2nn1l4qav9yizj3psklvwiq2z1as"))))
13158 (build-system pyproject-build-system)
13159 (arguments
13160 (list
13161 #:test-flags
13162 #~(list
13163 ;; XXX: Server fails to start.
13164 "--ignore=tests/experimentation/test_multiple_consumers_asyncio.py"
13165 "--ignore=tests/experimentation/test_multiple_consumers_threads.py"
13166 ;; XXX: Missing test dependency.
13167 "--ignore=tests/integration/test_multiple_consumers.py")
13168 #:phases
13169 #~(modify-phases %standard-phases
13170 (add-after 'unpack 'relax-requirements
13171 (lambda _
13172 (substitute* "pyproject.toml"
13173 (("\"anyio>=.*\"")
13174 "\"anyio\"")))))))
13175 (propagated-inputs (list python-anyio python-starlette))
13176 (native-inputs
13177 (list python-asgi-lifespan
13178 python-async-timeout
13179 python-httpx
13180 python-portend
13181 python-pytest
13182 python-pytest-asyncio
13183 python-psutil
13184 python-setuptools
13185 python-tenacity
13186 python-uvicorn))
13187 (home-page "https://github.com/sysid/sse-starlette")
13188 (synopsis "SSE plugin for Starlette")
13189 (description
13190 "This package provides SSE plugin for Starlette.")
13191 (license license:bsd-3)))
13192
13193(define-public python-sseclient-py
13194 (package
13195 (name "python-sseclient-py")
13196 (version "1.9.0")
13197 (source
13198 (origin
13199 (method git-fetch)
13200 (uri (git-reference
13201 (url "https://github.com/mpetazzoni/sseclient")
13202 (commit (string-append "sseclient-py-" version))))
13203 (file-name (git-file-name name version))
13204 (sha256
13205 (base32 "1yi2v8z89mygsr1vzyc4r3j7flr3jrh6a6kzqfdh86i5a5j5v280"))))
13206 (build-system pyproject-build-system)
13207 (native-inputs (list python-hatchling python-pytest))
13208 (arguments
13209 (list
13210 #:test-backend #~'unittest
13211 #:test-flags #~'("discover" "--verbose" "tests")))
13212 (home-page "https://github.com/mpetazzoni/sseclient")
13213 (synopsis "Pure-Python Server Side Events (SSE) client")
13214 (description
13215 "This package provides a Python client for SSE event sources that
13216seamlessly integrates with @code{urllib3} and @code{requests}.")
13217 (license license:asl2.0)))
13218
13219(define-public python-starlette
13220 (package
13221 (name "python-starlette")
13222 (version "0.49.1")
13223 (source (origin
13224 (method git-fetch)
13225 (uri (git-reference
13226 (url "https://github.com/encode/starlette")
13227 (commit version)))
13228 (file-name (git-file-name name version))
13229 (sha256
13230 (base32
13231 "0w9cyaxpc2p99hqrfw164iypacx3i1gsmn2z0xywgd21alva82ji"))))
13232 (build-system pyproject-build-system)
13233 (propagated-inputs (list python-anyio
13234 python-typing-extensions
13235 ;; [all] extra dependencies:
13236 python-itsdangerous
13237 python-jinja2
13238 python-multipart
13239 python-pyyaml
13240 python-requests))
13241 (native-inputs (list python-hatchling
13242 python-httpx
13243 python-pytest
13244 python-typing-extensions))
13245 (home-page "https://github.com/encode/starlette")
13246 (synopsis "Little ASGI library")
13247 (description
13248 "Starlette is a lightweight ASGI (Asynchronous Server Gateway
13249Interface) framework/toolkit for building async web services in Python.")
13250 (license license:bsd-3)))
13251
13252(define-public python-starsessions
13253 (package
13254 (name "python-starsessions")
13255 (version "1.3.0")
13256 (source (origin
13257 (method git-fetch)
13258 (uri (git-reference
13259 (url "https://github.com/alex-oleshkevich/starsessions")
13260 (commit (string-append "v" version))))
13261 (file-name (git-file-name name version))
13262 (sha256
13263 (base32
13264 "00dkdhp22vfmcn0w4y7f2ii8m1xj5i7409x58g3l8lvk6v5ng2nf"))))
13265 (build-system pyproject-build-system)
13266 (arguments
13267 (list
13268 #:test-flags
13269 ;; These tests require a running redis server
13270 '(list "--ignore=tests/backends/test_redis.py"
13271 ;; XXX: this failure indicates a real compatibility problem, but
13272 ;; it seems restricted to the tests only.
13273 ;; AttributeError: 'Cookies' object has no attribute
13274 ;; 'clear_session_cookies'
13275 "-k"
13276 (string-append "not test_session_clears_on_tab_close"
13277 ;; This fails because an error is not raised.
13278 " and not test_session_wants_secret_key"))
13279 #:phases
13280 '(modify-phases %standard-phases
13281 (add-after 'unpack 'compatibilitiy
13282 (lambda _
13283 ;; aioredis has been renamed
13284 (substitute* "starsessions/backends/redis.py"
13285 (("aioredis") "redis")))))))
13286 (propagated-inputs
13287 (list python-redis
13288 python-itsdangerous
13289 python-starlette))
13290 (native-inputs
13291 (list python-httpx
13292 python-poetry-core
13293 python-pytest
13294 python-pytest-asyncio
13295 python-requests))
13296 (home-page "https://github.com/alex-oleshkevich/starsessions")
13297 (synopsis "Pluggable session support for Starlette and FastAPI")
13298 (description
13299 "This package adds pluggable session backends and ships default
13300@code{InMemoryBackend} and @code{CookieBackend} implementations for Starlette
13301and FastAPI.")
13302 (license license:expat)))
13303
13304(define-public python-whereismyip
13305 (package
13306 (name "python-whereismyip")
13307 (version "0.1.0")
13308 (source
13309 (origin
13310 (method url-fetch)
13311 (uri (pypi-uri "whereismyip" version))
13312 (sha256
13313 (base32 "0psrlvax8249ccs2rvgdygpckzz22vxjcyzr2pql06d48k61gk54"))))
13314 (build-system pyproject-build-system)
13315 (arguments (list #:tests? #false)) ; There are no tests.
13316 (native-inputs (list python-setuptools))
13317 (home-page "https://pypi.org/project/whereismyip/")
13318 (synopsis "Queries multiple geolocation services until one succeeds")
13319 (description
13320 "This package provides a simple Python library that queries multiple geolocation
13321services until one succeeds.")
13322 (license license:gpl3)))
13323
13324(define-public python-whitenoise
13325 (package
13326 (name "python-whitenoise")
13327 (version "6.9.0")
13328 (source (origin
13329 (method git-fetch) ; PyPI missing test failes
13330 (uri (git-reference
13331 (url "https://github.com/evansd/whitenoise")
13332 (commit version)))
13333 (file-name (git-file-name name version))
13334 (sha256
13335 (base32
13336 "0y00a59ww9f631m51d5db5xcnbckzcwfm64wabp5vamn7l1kqqsj"))))
13337 (build-system pyproject-build-system)
13338 (arguments
13339 (list
13340 #:test-flags #~(list "-k" "not test_modified"))) ; HTTP 304 error
13341 (native-inputs (list python-brotli
13342 python-django
13343 python-requests
13344 python-pytest
13345 python-setuptools
13346 python-wheel))
13347 (home-page "https://github.com/evansd/whitenoise")
13348 (synopsis "Static file serving for WSGI applications")
13349 (description
13350 "WhiteNoise allows your web app to serve its own static files, making it
13351a self-contained unit that can be deployed anywhere without relying on nginx,
13352Amazon S3 or any other external service.")
13353 (license license:expat)))
13354
13355(define-public python-suds
13356 (package
13357 (name "python-suds")
13358 (version "1.2.0")
13359 (source
13360 (origin
13361 (method url-fetch)
13362 (uri (pypi-uri "suds" version))
13363 (sha256
13364 (base32 "1byyg7b2ixpr8hc849a6dd0qn5daxqawz6lb3php8lrmsb1n5cc3"))))
13365 (build-system pyproject-build-system)
13366 (arguments
13367 (list #:phases
13368 #~(modify-phases %standard-phases
13369 ;; XXX: chirp expects suds instead of suds_community
13370 (add-after 'install 'add-custom-dist-info
13371 (lambda _
13372 (for-each
13373 (lambda (dir)
13374 (with-directory-excursion (dirname dir)
13375 (symlink
13376 (basename dir)
13377 (string-append "suds-" #$version ".dist-info"))))
13378 (find-files #$output
13379 (lambda (file stat)
13380 (string-suffix? ".dist-info" file))
13381 #:directories? #t)))))))
13382 (native-inputs
13383 (list python-pytest
13384 python-setuptools
13385 python-wheel))
13386 (home-page "https://github.com/suds-community/suds")
13387 (synopsis "Lightweight SOAP python client for consuming Web Services")
13388 (description
13389 "Suds is a lightweight SOAP-based web service client for Python.")
13390 (license license:lgpl3+)))
13391
13392(define-public python-fastapi
13393 (package
13394 (name "python-fastapi")
13395 (version "0.128.0")
13396 (source
13397 (origin
13398 (method url-fetch)
13399 (uri (pypi-uri "fastapi" version))
13400 (sha256
13401 (base32 "0nk4ybvzv3bcgv5plbg3infykp19p1wryhpy1zk6n2pirvhpkh8w"))))
13402 (build-system pyproject-build-system)
13403 (arguments
13404 (list
13405 ;; tests: 1126 passed, 12 skipped, 2 deselected
13406 #:test-flags
13407 #~(list
13408 ;; cannot import name 'StaticPool' from 'sqlalchemy'
13409 "--ignore=tests/test_tutorial/"
13410 ;; Some snapshots have incorrect values.
13411 "--deselect=tests/test_schema_compat_pydantic_v2.py::test_openapi_schema"
13412 ;; Argument() missing 1 required positional argument: 'default'
13413 "--ignore=tests/test_fastapi_cli.py")))
13414 (native-inputs
13415 (list python-anyio
13416 python-dirty-equals
13417 python-flask
13418 python-inline-snapshot
13419 python-pdm-backend
13420 ;; python-pwdlib
13421 python-pyjwt
13422 python-pytest
13423 python-sqlalchemy
13424 ;; python-sqlmodel
13425 python-types-orjson
13426 python-types-ujson))
13427 (propagated-inputs
13428 (list python-starlette
13429 python-pydantic
13430 python-typing-extensions
13431 python-annotated-doc
13432 ;; [optional]
13433 python-email-validator
13434 python-fastapi-cli
13435 python-httpx
13436 python-itsdangerous
13437 python-jinja2
13438 python-multipart
13439 python-orjson
13440 python-pydantic-extra-types
13441 python-pydantic-settings
13442 python-pyyaml
13443 python-ujson
13444 python-uvicorn))
13445 (home-page "https://github.com/tiangolo/fastapi")
13446 (synopsis "Web framework based on type hints")
13447 (description "FastAPI provides a web API framework based on pydantic and
13448starlette.")
13449 (license license:expat)))
13450
13451(define-public python-fastapi-csrf-protect
13452 (package
13453 (name "python-fastapi-csrf-protect")
13454 (version "0.3.3")
13455 (source (origin
13456 (method git-fetch)
13457 (uri (git-reference
13458 (url "https://github.com/aekasitt/fastapi-csrf-protect")
13459 (commit (string-append "v" version))))
13460 (file-name (git-file-name name version))
13461 (sha256
13462 (base32
13463 "181yawlbpd4709mamsradr9zj0jrbp4qvwfvmggs80pd36iiwyy8"))))
13464 (build-system pyproject-build-system)
13465 (propagated-inputs
13466 (list python-fastapi python-itsdangerous
13467 python-pydantic))
13468 (native-inputs
13469 (list python-poetry-core
13470 python-pytest))
13471 (home-page "https://github.com/aekasitt/fastapi-csrf-protect")
13472 (synopsis "Cross-Site Request Forgery (XSRF) protection")
13473 (description
13474 "This package provides a stateless implementation of @dfn{Cross-Site
13475Request Forgery} (XSRF) Protection by using the Double Submit Cookie mitigation
13476pattern.")
13477 (license license:expat)))
13478
13479(define-public python-fastapi-pagination-minimal
13480 (package
13481 (name "python-fastapi-pagination-minimal")
13482 (version "0.15.6")
13483 (source (origin
13484 (method git-fetch)
13485 (uri (git-reference
13486 (url "https://github.com/uriyyo/fastapi-pagination")
13487 (commit version)))
13488 (file-name (git-file-name name version))
13489 (sha256
13490 (base32
13491 "1ndazaqi1na0lj6fi42d7mi9lmpxdak0wq0pd97fb3b23ml8rlg6"))))
13492 (build-system pyproject-build-system)
13493 ;; We run the tests in python-fastapi-pagination only.
13494 (arguments (list #:tests? #false))
13495 ;; These are the only required dependencies,
13496 ;; please add all optional dependencies to the
13497 ;; full python-fastapi-pagination below.
13498 (propagated-inputs (list python-fastapi python-pydantic))
13499 (native-inputs (list python-hatchling))
13500 (home-page "https://github.com/uriyyo/fastapi-pagination")
13501 (synopsis "FastAPI pagination library")
13502 (description "@code{fastapi-pagination} is a Python library designed to
13503simplify pagination in FastAPI applications. It provides a set of utility
13504functions and data models to help you paginate your database queries and
13505return paginated responses to your clients.")
13506 (license license:expat)))
13507
13508(define-public python-fastapi-pagination
13509 (package
13510 (inherit python-fastapi-pagination-minimal)
13511 (name "python-fastapi-pagination")
13512 (arguments
13513 (list
13514 #:test-flags
13515 #~(list "--asyncio-mode=auto"
13516 "--ignore=tests/ext"
13517 ;; Netwok access is required.
13518 "-k" (string-join
13519 (list "not test_optional_params[postgres-default]"
13520 "test_optional_params[postgres-limit-offset]"
13521 "test_optional_params[sqlite-default]"
13522 "test_optional_params[sqlite-limit-offset]")
13523 " and not "))
13524 #:phases
13525 '(modify-phases %standard-phases
13526 (add-after 'unpack 'patch-tests
13527 (lambda _
13528 ;; We don't have a package for python-cassandra or motor, but we
13529 ;; also don't need them as we only run the unit tests anyway.
13530 (substitute* "tests/conftest.py"
13531 (("from cassandra.*") "")
13532 (("from motor.*") "")))))))
13533 (propagated-inputs
13534 (modify-inputs (package-propagated-inputs
13535 python-fastapi-pagination-minimal)
13536 (prepend python-asyncpg
13537 python-databases
13538 python-django
13539 python-fastapi
13540 python-pydantic
13541 python-sqlalchemy
13542 (package
13543 (inherit python-tortoise-orm)
13544 (arguments
13545 (substitute-keyword-arguments (package-arguments
13546 python-tortoise-orm)
13547 ((#:phases phases '%standard-phases)
13548 `(modify-phases ,phases
13549 (delete 'sanity-check)))))
13550 (propagated-inputs
13551 (modify-inputs (package-propagated-inputs python-tortoise-orm)
13552 (replace "python-aiosqlite" python-aiosqlite)))))))
13553 (native-inputs
13554 (list python-aiosqlite
13555 python-asgi-lifespan
13556 python-asyncpg
13557 python-dirty-equals
13558 python-faker
13559 python-hatchling
13560 python-httpx
13561 python-pytest
13562 python-pytest-asyncio
13563 python-sqlalchemy
13564 python-typing-extensions))
13565 (description
13566 (string-append (package-description python-fastapi-pagination-minimal)
13567 "
13568
13569This package, as opposed to @code{python-fastapi-pagination-minimal}, depends on
13570all available optional dependencies supported by mainline
13571@code{fastapi-pagination}."))))
13572
13573(define-public python-fastapi-cli
13574 (package
13575 (name "python-fastapi-cli")
13576 (version "0.0.7")
13577 (source
13578 (origin
13579 (method url-fetch)
13580 (uri (pypi-uri "fastapi_cli" version))
13581 (sha256
13582 (base32 "0pk0ldmymc25ys4v6mslzd5vsjh9r69hfylh2ljl29pmarcvdcq2"))))
13583 (build-system pyproject-build-system)
13584 ;; Tests require fastapi, which depends on this package.
13585 (arguments (list #:tests? #false))
13586 (propagated-inputs (list python-rich-toolkit python-typer python-uvicorn))
13587 (native-inputs
13588 (list python-inline-snapshot python-pdm-backend python-pytest))
13589 (home-page "https://pypi.org/project/fastapi-cli/")
13590 (synopsis
13591 "Run and manage FastAPI apps from the command line with FastAPI CLI")
13592 (description
13593 "FastAPI CLI is a command line program fastapi that you can use to serve
13594your FastAPI app, manage your FastAPI project, and more.")
13595 (license license:expat)))
13596
13597(define-public python-pyactiveresource
13598 (package
13599 (name "python-pyactiveresource")
13600 (version "2.2.2")
13601 (source
13602 (origin
13603 (method git-fetch)
13604 (uri (git-reference
13605 (url "https://github.com/Shopify/pyactiveresource")
13606 (commit (string-append "v" version))))
13607 (file-name (git-file-name name version))
13608 (sha256
13609 (base32 "03pw6fwqjn09fbd6xmng0arlz75pp6ykw25c8d1snp4bxlzkrwqf"))))
13610 (build-system pyproject-build-system)
13611 (native-inputs (list python-dateutil python-pytest python-pyyaml
13612 python-setuptools))
13613 (propagated-inputs (list python-six))
13614 (home-page "https://github.com/Shopify/pyactiveresource/")
13615 (synopsis "ActiveResource for Python")
13616 (description
13617 "This package provides a Python port of the ActiveResource project.
13618
13619Active Resource attempts to provide a coherent wrapper object-relational
13620mapping for REST web services. It follows the same philosophy as Active
13621Record, in that one of its prime aims is to reduce the amount of code needed
13622to map to these resources. This is made possible by relying on a number of
13623code- and protocol-based conventions that make it easy for Active Resource to
13624infer complex relations and structures.")
13625 (license license:expat)))
13626
13627(define-public python-shopifyapi
13628 (package
13629 (name "python-shopifyapi")
13630 (version "12.7.0")
13631 (source
13632 (origin
13633 (method git-fetch)
13634 (uri (git-reference
13635 (url "https://github.com/Shopify/shopify_python_api")
13636 (commit (string-append "v" version))))
13637 (file-name (git-file-name name version))
13638 (sha256
13639 (base32 "11zjm3aspb247wwlmfmq6wwk6lv3xyv3lqnd78sczjg9anba3779"))))
13640 (build-system pyproject-build-system)
13641 (arguments
13642 (list
13643 #:test-flags
13644 #~'("-k"
13645 ;; Disable a failing test.
13646 "not test_raises_if_aud_doesnt_match_api_key")))
13647 (native-inputs (list python-mock python-pytest python-setuptools))
13648 (propagated-inputs (list python-pyactiveresource python-pyjwt
13649 python-pyyaml python-six))
13650 (home-page "https://github.com/Shopify/shopify_python_api")
13651 (synopsis "Shopify API for Python")
13652 (description
13653 "This package provides the Shopify API for Python.
13654
13655The ShopifyAPI library allows Python developers to programmatically access the
13656admin section of stores using an ActiveResource-like interface similar the
13657ruby Shopify API gem. The library makes HTTP requests to Shopify in order to
13658list, create, update, or delete resources (e.g. Order, Product, Collection).")
13659 (license license:expat)))
13660
13661(define-public python-pybadges
13662 (package
13663 (name "python-pybadges")
13664 (version "3.0.1")
13665 (source (origin
13666 (method git-fetch)
13667 (uri (git-reference
13668 (url "https://github.com/google/pybadges")
13669 (commit version)))
13670 (file-name (git-file-name name version))
13671 (sha256
13672 "1zgb9idz7m3mzf8wvik0gwmyrxp753axqjv2pab326cr5myj1s4b")))
13673 (build-system pyproject-build-system)
13674 (arguments
13675 (list
13676 #:test-flags
13677 #~'("-k"
13678 ;; Disable network dependent tests.
13679 "not test_changes and not test_not_image_url and not test_http_url")))
13680 (propagated-inputs (list python-jinja2 python-requests))
13681 (native-inputs (list python-flask
13682 python-fonttools
13683 python-pillow
13684 python-pytest
13685 python-setuptools
13686 python-wheel
13687 python-xmldiff))
13688 (home-page "https://github.com/google/pybadges")
13689 (synopsis "Generate Github-style badges on the command-line")
13690 (description
13691 "This package provides @code{python-pybadges}: a library and command-line
13692tool for generating Github-style badges as SVG images.")
13693 (license license:asl2.0)))
13694
13695(define-public python-grid5000
13696 (package
13697 (name "python-grid5000")
13698 (version "1.2.4")
13699 (source (origin
13700 (method git-fetch)
13701 (uri (git-reference
13702 (url "https://gitlab.inria.fr/msimonin/python-grid5000")
13703 (commit (string-append "v" version))))
13704 (file-name (git-file-name name version))
13705 (sha256
13706 "0px5dr6kn7i5dyy4g42vqap1zpkc4hdvg7prrxdkkl57lfhz5w61")))
13707 (build-system pyproject-build-system)
13708 (arguments
13709 (list #:tests? #f)) ; No tests.
13710 (native-inputs (list python-setuptools))
13711 (propagated-inputs (list python-requests python-ipython python-pyyaml))
13712 (home-page "https://pypi.org/project/python-grid5000/")
13713 (synopsis "Grid5000 python client")
13714 (description
13715 "python-grid5000 is a python package wrapping the Grid5000 REST API.
13716You can use it as a library in your python project or you can explore the
13717Grid5000 resources interactively using the embedded shell.")
13718 (license license:gpl3+)))
13719
13720(define-public python-enoslib
13721 (package
13722 (name "python-enoslib")
13723 (version "8.0.1")
13724 (source
13725 (origin
13726 (method git-fetch)
13727 (uri (git-reference
13728 (url "https://gitlab.inria.fr/discovery/enoslib")
13729 (commit (string-append "v" version))))
13730 (file-name (git-file-name name version))
13731 (sha256 "0vs6b0bnlv95mzv0rjbxqwrhzkgjkn91gqipgwdf7y4ffpz8nybg")))
13732 (arguments
13733 (list
13734 #:test-flags
13735 #~(list "enoslib/tests/unit"
13736 "--ignore" "enoslib/tests/unit/infra/test_utils.py"
13737 "--ignore-glob" "enoslib/tests/unit/infra/enos_iotlab/*")
13738 #:phases
13739 #~(modify-phases %standard-phases
13740 (add-before 'check 'pre-check
13741 (lambda* (#:key tests? #:allow-other-keys)
13742 (when tests?
13743 ;; Otherwise Ansible fails to create its config directory.
13744 (setenv "HOME" "/tmp"))))
13745 ;; Disable the sanity check, which fails with the following error:
13746 ;;
13747 ;; ContextualVersionConflict(rich 12.4.1
13748 ;; (/gnu/store/...-python-rich-12.4.1/lib/python3.9/site-packages),
13749 ;; Requirement.parse('rich[jupyter]~=12.0.0'), {'enoslib'})
13750 ;;
13751 ;; The optional jupyter dependency of rich isn't critical for
13752 ;; EnOSlib to work
13753 (delete 'sanity-check))))
13754 (build-system pyproject-build-system)
13755 (native-inputs
13756 (list python-ddt
13757 python-freezegun
13758 python-pytest
13759 python-setuptools
13760 python-wheel))
13761 (propagated-inputs
13762 (list ansible
13763 python-cryptography
13764 python-grid5000
13765 python-jsonschema
13766 python-netaddr
13767 python-packaging
13768 python-requests
13769 python-rich
13770 python-sshtunnel
13771 python-pytz))
13772 (home-page "https://discovery.gitlabpages.inria.fr/enoslib/index.html")
13773 (synopsis "Deploy distributed testbeds on a variety of platforms")
13774 (description
13775 "EnOSlib is a library to build experimental frameworks on various
13776scientific testbeds. It lets you deploy networks of machines on actual
13777hardware on Grid'5000 or via OpenStack, to Vagrant, Chameleon, and more.")
13778 (license license:gpl3+)))
13779
13780(define-public python-pynetbox
13781 (package
13782 (name "python-pynetbox")
13783 (version "7.4.1")
13784 (source (origin
13785 (method url-fetch)
13786 (uri (pypi-uri "pynetbox" version))
13787 (sha256
13788 (base32
13789 "1hq0mqykwdsmcrj61fxxzdkpc7wnld4grhkcxy560ym79jbbb0iz"))))
13790 (build-system pyproject-build-system)
13791 (arguments
13792 (list
13793 #:test-flags
13794 ;; Integration tests depend on docker.
13795 '(list "--ignore=tests/integration")))
13796 (propagated-inputs (list python-packaging python-requests))
13797 (native-inputs
13798 (list python-pytest
13799 python-setuptools
13800 python-setuptools-scm
13801 python-wheel))
13802 (home-page "https://github.com/netbox-community/pynetbox")
13803 (synopsis "NetBox API client library")
13804 (description "Python module to query and edit data stored in a
13805@url{https://netbox.dev,NetBox} instance.")
13806 (license license:asl2.0)))
13807
13808(define-public python-waybackpack
13809 (package
13810 (name "python-waybackpack")
13811 (version "0.6.4")
13812 (source
13813 (origin
13814 (method url-fetch)
13815 (uri (pypi-uri "waybackpack" version))
13816 (sha256
13817 (base32 "16lcr2hv7gmp199fh3psrnv68j20pfxria8v6gchrpl1jqx9f923"))))
13818 (build-system pyproject-build-system)
13819 (arguments
13820 (list #:tests? #f)) ; would require network (and SSL certificates)
13821 (propagated-inputs (list python-requests))
13822 (native-inputs (list python-pytest python-setuptools python-wheel))
13823 (home-page "https://github.com/jsvine/waybackpack")
13824 (synopsis
13825 "Download the entire Wayback Machine archive for a given URL")
13826 (description
13827 "This package provides a library and a command-line tool that lets
13828you download the entire Wayback Machine archive for a given URL.")
13829 (license license:expat)))
13830
13831(define-public python-xyzservices
13832 (package
13833 (name "python-xyzservices")
13834 (version "2025.4.0")
13835 (source
13836 (origin
13837 (method url-fetch)
13838 (uri (pypi-uri "xyzservices" version))
13839 (sha256
13840 (base32 "1n096zg9bd4n6w6axcm16m9sxdkc6qy1mipva0scbyj86rqn9rvg"))))
13841 (build-system pyproject-build-system)
13842 (arguments
13843 (list
13844 #:test-flags #~(list "-m" "not request")))
13845 (native-inputs
13846 (list python-pytest
13847 python-mercantile
13848 python-requests
13849 python-setuptools
13850 python-setuptools-scm))
13851 (home-page "https://github.com/geopandas/xyzservices")
13852 (synopsis "Source of XYZ tiles providers")
13853 (description "@code{xyzservices} is a lightweight library providing a
13854repository of available XYZ services offering raster basemap tiles. The
13855repository is provided via Python API and as a compressed JSON file.")
13856 (license license:bsd-3)))
13857
13858(define-public s3cmd
13859 (package
13860 (name "s3cmd")
13861 (version "2.4.0")
13862 (source
13863 (origin
13864 (method git-fetch)
13865 (uri (git-reference
13866 (url "https://github.com/s3tools/s3cmd")
13867 (commit (string-append "v" version))))
13868 (file-name (git-file-name name version))
13869 (sha256
13870 (base32 "168c49d1v8r7azv66zz0w07jalf434c2jpg2xzads5jnxzmiy73k"))))
13871 (build-system pyproject-build-system)
13872 (arguments
13873 (list
13874 #:tests? #f ; XXX: Tests require network access.
13875 #:phases
13876 #~(modify-phases %standard-phases
13877 (add-after 'unpack 'hide-wrapping
13878 (lambda _
13879 (substitute* "S3/MultiPart.py"
13880 (("sys\\.argv\\[0\\]")
13881 "\"s3cmd\""))
13882 (substitute* "s3cmd"
13883 (("optparser\\.get_prog_name\\(\\)")
13884 "\"s3cmd\"")))))))
13885 (native-inputs (list python-setuptools))
13886 (inputs (list python-dateutil python-magic))
13887 (home-page "https://s3tools.org/s3cmd")
13888 (synopsis "Command line tool for S3-compatible storage services")
13889 (description
13890 "S3cmd is a command line tool for uploading, retrieving and managing data
13891in storage services that are compatible with the Amazon Simple Storage
13892Service (S3) protocol, including S3 itself. It supports rsync-like backup,
13893GnuPG encryption, and more. It also supports management of Amazon's
13894CloudFront content delivery network.")
13895 (license license:gpl2+)))