gnu: python-aiohttp: Update to 3.7.4 [fixes CVE-2021-21330].
[jackhill/guix/guix.git] / gnu / packages / python-web.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
3 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
4 ;;; Copyright © 2017 Christopher Baines <mail@cbaines.net>
5 ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
6 ;;; Copyright © 2013, 2014, 2015, 2016, 2020 Andreas Enge <andreas@enge.fr>
7 ;;; Copyright © 2016, 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
8 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
10 ;;; Copyright © 2016, 2017, 2020 Julien Lepiller <julien@lepiller.eu>
11 ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
12 ;;; Copyright © 2014, 2017 Eric Bavier <bavier@member.fsf.org>
13 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
14 ;;; Copyright © 2015 Cyril Roelandt <tipecaml@gmail.com>
15 ;;; Copyright © 2015, 2016, 2017, 2019 Leo Famulari <leo@famulari.name>
16 ;;; Copyright © 2016, 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
17 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
18 ;;; Copyright © 2015, 2017 Ben Woodcroft <donttrustben@gmail.com>
19 ;;; Copyright © 2015, 2016 Christopher Allan Webber <cwebber@dustycloud.org>
20 ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com>
21 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
22 ;;; Copyright © 2016 David Craven <david@craven.ch>
23 ;;; Copyright © 2017 Oleg Pykhalov <go.wigust@gmail.com>
24 ;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org>
25 ;;; Copyright © 2017 Mark Meyer <mark@ofosos.org>
26 ;;; Copyright © 2018 Tomáš Čech <sleep_walker@gnu.org>
27 ;;; Copyright © 2018, 2019 Nicolas Goaziou <mail@nicolasgoaziou.fr>
28 ;;; Copyright © 2018 Mathieu Othacehe <m.othacehe@gmail.com>
29 ;;; Copyright © 2018, 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
30 ;;; Copyright © 2019 Vagrant Cascadian <vagrant@debian.org>
31 ;;; Copyright © 2019 Brendan Tildesley <mail@brendan.scot>
32 ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
33 ;;; Copyright © 2019, 2020 Tanguy Le Carrour <tanguy@bioneland.org>
34 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
35 ;;; Copyright © 2020 Evan Straw <evan.straw99@gmail.com>
36 ;;; Copyright © 2020 Alexandros Theodotou <alex@zrythm.org>
37 ;;; Copyright © 2020 Holger Peters <holger.peters@posteo.de>
38 ;;; Copyright © 2020 Noisytoot <noisytoot@gmail.com>
39 ;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
40 ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
41 ;;; Copyright © 2020 Konrad Hinsen <konrad.hinsen@fastmail.net>
42 ;;; Copyright © 2020 Giacomo Leidi <goodoldpaul@autistici.org>
43 ;;;
44 ;;; This file is part of GNU Guix.
45 ;;;
46 ;;; GNU Guix is free software; you can redistribute it and/or modify it
47 ;;; under the terms of the GNU General Public License as published by
48 ;;; the Free Software Foundation; either version 3 of the License, or (at
49 ;;; your option) any later version.
50 ;;;
51 ;;; GNU Guix is distributed in the hope that it will be useful, but
52 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
53 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
54 ;;; GNU General Public License for more details.
55 ;;;
56 ;;; You should have received a copy of the GNU General Public License
57 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
58
59 (define-module (gnu packages python-web)
60 #:use-module (guix packages)
61 #:use-module (guix download)
62 #:use-module (guix git-download)
63 #:use-module (guix build-system python)
64 #:use-module (guix utils)
65 #:use-module (gnu packages)
66 #:use-module (gnu packages base)
67 #:use-module (gnu packages check)
68 #:use-module (gnu packages compression)
69 #:use-module (gnu packages curl)
70 #:use-module (gnu packages databases)
71 #:use-module (gnu packages django)
72 #:use-module (gnu packages graphviz)
73 #:use-module (gnu packages groff)
74 #:use-module (gnu packages libevent)
75 #:use-module (gnu packages libffi)
76 #:use-module (gnu packages pkg-config)
77 #:use-module (gnu packages python)
78 #:use-module (gnu packages python-build)
79 #:use-module (gnu packages python-check)
80 #:use-module (gnu packages python-compression)
81 #:use-module (gnu packages python-crypto)
82 #:use-module (gnu packages python-science)
83 #:use-module (gnu packages python-xyz)
84 #:use-module (gnu packages serialization)
85 #:use-module (gnu packages sphinx)
86 #:use-module (gnu packages texinfo)
87 #:use-module (gnu packages tls)
88 #:use-module (gnu packages time)
89 #:use-module (gnu packages web)
90 #:use-module (gnu packages xml)
91 #:use-module ((guix licenses) #:prefix license:)
92 #:use-module (srfi srfi-1))
93
94 (define-public python-aiohttp
95 (package
96 (name "python-aiohttp")
97 (version "3.7.4")
98 (source
99 (origin
100 (method url-fetch)
101 (uri (pypi-uri "aiohttp" version))
102 (sha256
103 (base32 "1pn79h8fng4xi5gl1f6saw31nxgmgyxl41yf3vba1l21673yr12x"))))
104 (build-system python-build-system)
105 (arguments
106 '(#:phases
107 (modify-phases %standard-phases
108 (add-after 'unpack 'fix-tests
109 (lambda _
110 ;; disable brotli tests, because we’re not providing that optional library
111 (substitute* "tests/test_http_parser.py"
112 ((" async def test_feed_eof_no_err_brotli")
113 " @pytest.mark.xfail\n async def test_feed_eof_no_err_brotli"))
114 ;; make sure the timestamp of this file is > 1990, because a few
115 ;; tests like test_static_file_if_modified_since_past_date depend on it
116 (let ((late-90s (* 60 60 24 365 30)))
117 (utime "tests/data.unknown_mime_type" late-90s late-90s))
118
119 ;; Disable test that attempts to access httpbin.org.
120 (substitute* "tests/test_formdata.py"
121 (("async def test_mark_formdata_as_processed.*" all)
122 (string-append "@pytest.mark.xfail\n" all)))
123
124 ;; Don't test the aiohttp pytest plugin to avoid a dependency loop.
125 (delete-file "tests/test_pytest_plugin.py")
126 #t))
127 (replace 'check
128 (lambda* (#:key tests? #:allow-other-keys)
129 (setenv "PYTHONPATH"
130 (string-append ".:" (getenv "PYTHONPATH")))
131 (if tests?
132 (invoke "pytest" "-vv"
133 ;; Disable loading the aiohttp coverage plugin
134 ;; to avoid a circular dependency (code coverage
135 ;; is not very interesting to us anyway).
136 "-o" "addopts=''")
137 (format #t "test suite not run~%")))))))
138 (propagated-inputs
139 `(("python-aiodns" ,python-aiodns)
140 ("python-async-timeout" ,python-async-timeout)
141 ("python-attrs" ,python-attrs) ;note: remove for > 3.7
142 ("python-chardet" ,python-chardet)
143 ("python-idna-ssl" ,python-idna-ssl)
144 ("python-multidict" ,python-multidict)
145 ("python-typing-extensions" ,python-typing-extensions)
146 ("python-yarl" ,python-yarl)))
147 (native-inputs
148 `(("python-pytest" ,python-pytest)
149 ("python-pytest-mock" ,python-pytest-mock)
150 ("python-re-assert" ,python-re-assert)
151 ("gunicorn" ,gunicorn-bootstrap)
152 ("python-freezegun" ,python-freezegun)
153 ("python-async-generator" ,python-async-generator)))
154 (home-page "https://github.com/aio-libs/aiohttp/")
155 (synopsis "Async HTTP client/server framework (asyncio)")
156 (description "@code{aiohttp} is an asynchronous HTTP client/server
157 framework.
158
159 Its main features are:
160 @itemize
161 @item Supports both client and server side of HTTP protocol.
162 @item Supports both client and server Web-Sockets out-of-the-box without the
163 Callback Hell.
164 @item Web-server has middlewares and pluggable routing.
165 @end itemize")
166 (license license:asl2.0)))
167
168 (define-public python-aiohttp-socks
169 (package
170 (name "python-aiohttp-socks")
171 (version "0.5.5")
172 (source
173 (origin
174 (method url-fetch)
175 (uri (pypi-uri "aiohttp_socks" version))
176 (sha256
177 (base32
178 "0jmhb0l1w8k1nishij3awd9zv8zbyb5l35a2pdalrqxxasbhbcif"))))
179 (build-system python-build-system)
180 (propagated-inputs
181 `(("python-aiohttp" ,python-aiohttp)
182 ("python-attrs" ,python-attrs)
183 ("python-socks" ,python-socks)))
184 (home-page "https://github.com/romis2012/aiohttp-socks")
185 (synopsis "SOCKS proxy connector for aiohttp")
186 (description "This package provides a SOCKS proxy connector for
187 aiohttp. It supports SOCKS4(a) and SOCKS5.")
188 (license license:asl2.0)))
189
190 (define-public python-aiodns
191 (package
192 (name "python-aiodns")
193 (version "1.1.1")
194 (source
195 (origin
196 (method url-fetch)
197 (uri (pypi-uri "aiodns" version))
198 (sha256
199 (base32
200 "1snr5paql8dgvc676n8xq460wypjsb1xj53cf3px1s4wczf7lryq"))))
201 (build-system python-build-system)
202 (propagated-inputs
203 `(("python-pycares" ,python-pycares)))
204 (arguments
205 `(#:tests? #f)) ;tests require internet access
206 (home-page "https://github.com/saghul/aiodns")
207 (synopsis "Simple DNS resolver for asyncio")
208 (description "@code{aiodns} provides a simple way for doing
209 asynchronous DNS resolutions with a synchronous looking interface by
210 using @url{https://github.com/saghul/pycares,pycares}.")
211 (license license:expat)))
212
213 (define-public python-aiorpcx
214 (package
215 (name "python-aiorpcx")
216 (version "0.18.3")
217 (source
218 (origin
219 (method url-fetch)
220 (uri (pypi-uri "aiorpcX" version))
221 (sha256
222 (base32
223 "0k545hc7wl6sh1svydzbv6x7sx5pig2pqkl3yxs9riwmvzawx9xp"))))
224 (build-system python-build-system)
225 (propagated-inputs
226 `(("python-attrs" ,python-attrs)))
227 (home-page "https://github.com/kyuupichan/aiorpcX")
228 (synopsis "Generic asyncio RPC implementation")
229 (description
230 "The aiorpcX library is a generic asyncio implementation of RPC suitable
231 for an application that is a client, server or both.
232
233 The package includes a module with full coverage of JSON RPC versions 1.0 and
234 2.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
235 comes with a SOCKS proxy client.")
236 (license (list license:expat license:bsd-2))))
237
238 (define-public python-asgiref
239 (package
240 (name "python-asgiref")
241 (version "3.2.10")
242 (source (origin
243 (method url-fetch)
244 (uri (pypi-uri "asgiref" version))
245 (sha256
246 (base32
247 "06kg3hnnvh7qg0w9amkvk1hd6n6bs055r04b7if6ipa7w4g92lby"))))
248 (build-system python-build-system)
249 (arguments
250 '(#:phases (modify-phases %standard-phases
251 (replace 'check
252 (lambda _
253 (setenv "PYTHONPATH"
254 (string-append "./build/lib:"
255 (getenv "PYTHONPATH")))
256 (invoke "pytest" "-vv"))))))
257 (native-inputs
258 `(("python-pytest" ,python-pytest)
259 ("python-pytest-asyncio" ,python-pytest-asyncio)))
260 (home-page "https://github.com/django/asgiref/")
261 (synopsis "ASGI specs, helper code, and adapters")
262 (description
263 "ASGI is a standard for Python asynchronous web apps and servers to
264 communicate with each other, and positioned as an asynchronous successor to
265 WSGI. This package includes libraries for implementing ASGI servers.")
266 (license license:bsd-3)))
267
268 (define-public python-css-html-js-minify
269 (package
270 (name "python-css-html-js-minify")
271 (version "2.5.5")
272 (source (origin
273 (method url-fetch)
274 (uri (pypi-uri "css-html-js-minify" version ".zip"))
275 (sha256
276 (base32
277 "0v3l2dqdk2y4r6ax259gs4ij1zzm9yxg6491s6254vs9w3vi37sa"))))
278 (build-system python-build-system)
279 ;; XXX: The git repository has no tags, and the PyPI releases do not
280 ;; contain tests.
281 (arguments '(#:tests? #f))
282 (native-inputs `(("unzip" ,unzip)))
283 (home-page "https://github.com/juancarlospaco/css-html-js-minify")
284 (synopsis "CSS/HTML/JS minifier")
285 (description
286 "This package provides a single-file minifier for CSS, HTML, and JavaScript.")
287 ;; XXX: The README just says "GNU GPL and GNU LGPL and MIT". From
288 ;; <https://github.com/juancarlospaco/css-html-js-minify/issues/9> it
289 ;; looks like the user can choose a license.
290 (license (list license:gpl3+ license:lgpl3+ license:expat))))
291
292 (define-public python-aws-sam-translator
293 (package
294 (name "python-aws-sam-translator")
295 (version "1.30.1")
296 (source (origin
297 (method url-fetch)
298 (uri (pypi-uri "aws-sam-translator" version))
299 (sha256
300 (base32
301 "0d9ppd94x2kw404m49ajswmmxgdngbs4p5ajyrdvnlivfzqbv7dx"))))
302 (build-system python-build-system)
303 (arguments
304 `(;; XXX: Tests are not distributed with the PyPI archive, and would
305 ;; introduce a circular dependency on python-cfn-lint.
306 #:tests? #f
307 #:phases (modify-phases %standard-phases
308 (add-after 'unpack 'loosen-requirements
309 (lambda _
310 ;; The package needlessly specifies exact versions
311 ;; of dependencies, when it works fine with others.
312 (substitute* "requirements/base.txt"
313 (("(.*)(~=[0-9\\.]+)" all package version)
314 package))
315 #t)))))
316 (propagated-inputs
317 `(("python-boto3" ,python-boto3)
318 ("python-jsonschema" ,python-jsonschema)
319 ("python-six" ,python-six)))
320 (home-page "https://github.com/awslabs/serverless-application-model")
321 (synopsis "Transform AWS SAM templates into AWS CloudFormation templates")
322 (description
323 "AWS SAM Translator is a library that transform @dfn{Serverless Application
324 Model} (SAM) templates into AWS CloudFormation templates.")
325 (license license:asl2.0)))
326
327 (define-public python-aws-xray-sdk
328 (package
329 (name "python-aws-xray-sdk")
330 (version "2.6.0")
331 (home-page "https://github.com/aws/aws-xray-sdk-python")
332 (source (origin
333 (method git-fetch)
334 (uri (git-reference (url home-page) (commit version)))
335 (file-name (git-file-name name version))
336 (sha256
337 (base32
338 "12fzr0ylpa1lx3xr1x2f1jx8iiyzcr6g57fb9jign0j0lxdlbzpv"))))
339 (build-system python-build-system)
340 (arguments
341 `(#:phases (modify-phases %standard-phases
342 (add-after 'unpack 'disable-tests
343 (lambda _
344 (for-each delete-file
345 '(;; These tests require packages not yet in Guix.
346 "tests/ext/aiobotocore/test_aiobotocore.py"
347 "tests/ext/aiohttp/test_middleware.py"
348 "tests/ext/pg8000/test_pg8000.py"
349 "tests/ext/psycopg2/test_psycopg2.py"
350 "tests/ext/pymysql/test_pymysql.py"
351 "tests/ext/pynamodb/test_pynamodb.py"
352 "tests/test_async_recorder.py"
353
354 ;; FIXME: Why is this failing?
355 "tests/test_patcher.py"
356
357 ;; TODO: How to configure Django for these tests.
358 "tests/ext/django/test_db.py"
359 "tests/ext/django/test_middleware.py"
360
361 ;; These tests want to access httpbin.org.
362 "tests/ext/requests/test_requests.py"
363 "tests/ext/httplib/test_httplib.py"
364 "tests/ext/aiohttp/test_client.py"))))
365 (replace 'check
366 (lambda _
367 (setenv "PYTHONPATH"
368 (string-append "./build/lib:.:"
369 (getenv "PYTHONPATH")))
370 (invoke "pytest" "-vv" "tests"))))))
371 (native-inputs
372 `(;; These are required for the test suite.
373 ("python-bottle" ,python-bottle)
374 ("python-flask" ,python-flask)
375 ("python-flask-sqlalchemy" ,python-flask-sqlalchemy)
376 ("python-pymysql" ,python-pymysql)
377 ("python-pytest" ,python-pytest)
378 ("python-pytest-aiohttp" ,python-pytest-aiohttp)
379 ("python-requests" ,python-requests)
380 ("python-sqlalchemy" ,python-sqlalchemy)
381 ("python-webtest" ,python-webtest)))
382 (propagated-inputs
383 `(("python-aiohttp" ,python-aiohttp)
384 ("python-botocore" ,python-botocore)
385 ("python-future" ,python-future)
386 ("python-jsonpickle" ,python-jsonpickle)
387 ("python-urllib3" ,python-urllib3)
388 ("python-wrapt" ,python-wrapt)))
389 (synopsis "Profile applications on AWS X-Ray")
390 (description
391 "The AWS X-Ray SDK for Python enables Python developers to record and
392 emit information from within their applications to the AWS X-Ray service.")
393 (license license:asl2.0)))
394
395 (define-public python-cfn-lint
396 (package
397 (name "python-cfn-lint")
398 (version "0.41.0")
399 (home-page "https://github.com/aws-cloudformation/cfn-python-lint")
400 (source (origin
401 (method git-fetch)
402 (uri (git-reference
403 (url home-page)
404 (commit (string-append "v" version))))
405 (file-name (git-file-name name version))
406 (sha256
407 (base32
408 "0nqs0fmj3hd7pnd9hkb4z57jvi2iv82hh6n3xxba6i6p8zgx75q4"))))
409 (build-system python-build-system)
410 (arguments
411 `(#:phases (modify-phases %standard-phases
412 (replace 'check
413 (lambda* (#:key outputs #:allow-other-keys)
414 (let ((out (assoc-ref outputs "out")))
415 ;; Remove test for the documentation update scripts
416 ;; to avoid a dependency on 'git'.
417 (delete-file
418 "test/unit/module/maintenance/test_update_documentation.py")
419 (setenv "PYTHONPATH"
420 (string-append "./build/lib:"
421 (getenv "PYTHONPATH")))
422 (setenv "PATH" (string-append out "/bin:"
423 (getenv "PATH")))
424 (invoke "python" "-m" "unittest" "discover"
425 "-s" "test")))))))
426 (native-inputs
427 `(("python-pydot" ,python-pydot)
428 ("python-mock" ,python-mock)))
429 (propagated-inputs
430 `(("python-aws-sam-translator" ,python-aws-sam-translator)
431 ("python-jsonpatch" ,python-jsonpatch)
432 ("python-jsonschema" ,python-jsonschema)
433 ("python-junit-xml" ,python-junit-xml)
434 ("python-networkx" ,python-networkx)
435 ("python-pyyaml" ,python-pyyaml)
436 ("python-six" ,python-six)))
437 (synopsis "Validate CloudFormation templates")
438 (description
439 "This package lets you validate CloudFormation YAML/JSON templates against
440 the CloudFormation spec and additional checks. Includes checking valid values
441 for resource properties and best practices.")
442 (license license:expat)))
443
444 (define-public python-falcon
445 (package
446 (name "python-falcon")
447 (version "2.0.0")
448 (source
449 (origin
450 (method url-fetch)
451 (uri (pypi-uri "falcon" version))
452 (sha256
453 (base32
454 "1z6mqfv574x6jiawf67ib52g4kk20c2x7xk7wrn1573b8v7r79gf"))
455 (modules '((guix build utils)))
456 (snippet
457 '(begin
458 (delete-file-recursively "falcon/vendor")
459 (substitute* "setup.py"
460 ((".*falcon\\.vendor\\.mimeparse.*") ""))
461 (substitute* '("falcon/media/handlers.py"
462 "falcon/request.py")
463 (("from falcon\\.vendor ") ""))
464 (substitute* "falcon.egg-info/SOURCES.txt"
465 (("falcon/vendor.*") ""))
466 #t))))
467 (build-system python-build-system)
468 (arguments
469 `(#:phases
470 (modify-phases %standard-phases
471 (replace 'check
472 (lambda* (#:key inputs outputs #:allow-other-keys)
473 ;; Skip orjson, which requires rust to build.
474 (substitute* "tests/test_media_handlers.py"
475 (("== 'CPython") "!= 'CPython"))
476 (add-installed-pythonpath inputs outputs)
477 (invoke "pytest" "--ignore" "falcon"))))))
478 (propagated-inputs
479 `(("python-mimeparse" ,python-mimeparse)))
480 (native-inputs
481 `(("python-cython" ,python-cython) ;for faster binaries
482 ("python-mujson" ,python-mujson)
483 ("python-msgpack" ,python-msgpack)
484 ("python-pytest" ,python-pytest)
485 ("python-pytest-runner" ,python-pytest-runner)
486 ("python-pyyaml" ,python-pyyaml)
487 ("python-rapidjson" ,python-rapidjson)
488 ("python-requests" ,python-requests)
489 ("python-testtools" ,python-testtools)
490 ("python-ujson" ,python-ujson)))
491 (home-page "https://falconframework.org")
492 (synopsis
493 "Web framework for building APIs and application backends")
494 (description
495 "Falcon is a web API framework for building microservices, application
496 backends and higher-level frameworks. Among its features are:
497 @itemize
498 @item Optimized and extensible code base
499 @item Routing via URI templates and REST-inspired resource
500 classes
501 @item Access to headers and bodies through request and response
502 classes
503 @item Request processing via middleware components and hooks
504 @item Idiomatic HTTP error responses
505 @item Straightforward exception handling
506 @item Unit testing support through WSGI helpers and mocks
507 @item Compatible with both CPython and PyPy
508 @item Cython support for better performance when used with CPython
509 @end itemize")
510 (license license:asl2.0)))
511
512 (define-public python-falcon-cors
513 (package
514 (name "python-falcon-cors")
515 (version "1.1.7")
516 (source
517 (origin
518 (method url-fetch)
519 (uri (pypi-uri "falcon-cors" version))
520 (sha256
521 (base32
522 "12pym7hwsbd8b0c1azn95nas8gm3f1qpr6lpyx0958xm65ffr20p"))))
523 (build-system python-build-system)
524 (native-inputs
525 `(("python-falcon" ,python-falcon)))
526 (home-page
527 "https://github.com/lwcolton/falcon-cors")
528 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
529 (description "This middleware provides @dfn{cross-origin resource
530 sharing} (CORS) support for Falcon. It allows applying a specially crafted
531 CORS object to the incoming requests, enabling the ability to serve resources
532 over a different origin than that of the web application.")
533 (license license:asl2.0)))
534
535 (define-public python-furl
536 (package
537 (name "python-furl")
538 (version "2.0.0")
539 (source
540 (origin
541 (method url-fetch)
542 (uri (pypi-uri "furl" version))
543 (sha256
544 (base32
545 "1v2lakx03d5w8954a39ki44xv5mllnq0a0avhxykv9hrzg0yvjpx"))))
546 (build-system python-build-system)
547 (propagated-inputs
548 `(("python-six" ,python-six)
549 ("python-orderedmultidict" ,python-orderedmultidict)))
550 (native-inputs
551 `(("python-flake8" ,python-flake8)))
552 (home-page "https://github.com/gruns/furl")
553 (synopsis "URL manipulation in Python")
554 (description "Furl provides an easy-to-use alternative to the
555 @code{urllib} and @code{urlparse} modules for manipulating URLs.")
556 (license license:unlicense)))
557
558 (define-public python2-furl
559 (package-with-python2 python-furl))
560
561 (define-public python-httplib2
562 (package
563 (name "python-httplib2")
564 (version "0.9.2")
565 (source
566 (origin
567 (method url-fetch)
568 (uri (pypi-uri "httplib2" version))
569 (sha256
570 (base32
571 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
572 (build-system python-build-system)
573 (home-page "https://github.com/jcgregorio/httplib2")
574 (synopsis "Comprehensive HTTP client library")
575 (description
576 "A comprehensive HTTP client library supporting many features left out of
577 other HTTP libraries.")
578 (license license:expat)))
579
580 (define-public python2-httplib2
581 (package-with-python2 python-httplib2))
582
583 (define-public httpie
584 (package
585 (name "httpie")
586 (version "2.3.0")
587 (source
588 (origin
589 (method url-fetch)
590 (uri (pypi-uri "httpie" version))
591 (sha256
592 (base32
593 "15ngl3yc186gkgqdx8iav9bpj8gxjpzz26y32z92jwyhj4cmfh6m"))))
594 (build-system python-build-system)
595 (arguments
596 ;; The tests attempt to access external web servers, so we cannot run them.
597 '(#:tests? #f))
598 (propagated-inputs
599 `(("python-colorama" ,python-colorama)
600 ("python-pygments" ,python-pygments)
601 ("python-requests" ,python-requests)
602 ("python-requests-toolbelt" ,python-requests-toolbelt-0.9.1)))
603 (home-page "https://httpie.io")
604 (synopsis "cURL-like tool for humans")
605 (description
606 "A command line HTTP client with an intuitive UI, JSON support,
607 syntax highlighting, wget-like downloads, plugins, and more. It consists of
608 a single http command designed for painless debugging and interaction with
609 HTTP servers, RESTful APIs, and web services.")
610 ;; This was fixed in 1.0.3.
611 (properties `((lint-hidden-cve . ("CVE-2019-10751"))))
612 (license license:bsd-3)))
613
614 (define-public python-html2text
615 (package
616 (name "python-html2text")
617 (version "2020.1.16")
618 (source
619 (origin
620 (method url-fetch)
621 (uri (pypi-uri "html2text" version))
622 (sha256
623 (base32
624 "1fvv4z6dblii2wk1x82981ag8yhxbim1v2ksgywxsndh2s7335p2"))))
625 (build-system python-build-system)
626 (arguments
627 '(#:phases
628 (modify-phases %standard-phases
629 (replace 'check
630 (lambda _
631 (invoke "pytest" "test/"))))))
632 (native-inputs
633 `(("python-pytest" ,python-pytest)))
634 (home-page "https://github.com/Alir3z4/html2text")
635 (synopsis "Convert HTML into plain text")
636 (description "html2text takes HTML and converts it into plain ASCII text
637 which is also valid markdown. html2text was originally written by Aaron
638 Swartz.")
639 (license license:gpl3+)))
640
641 (define-public python2-html2text
642 (let ((base (package-with-python2 python-html2text)))
643 (package
644 (inherit base)
645 ;; This is the last version with support for Python 2.
646 (version "2019.8.11")
647 (source (origin
648 (method url-fetch)
649 (uri (pypi-uri "html2text" version))
650 (sha256
651 (base32
652 "0ppgjplg06kmv9sj0x8p7acczcq2mcfgk1jdjwm4w5w40b0vj5pm")))))))
653
654 (define-public python-jose
655 (package
656 (name "python-jose")
657 (version "3.2.0")
658 (home-page "http://github.com/mpdavis/python-jose")
659 (source (origin
660 (method git-fetch)
661 (uri (git-reference (url home-page) (commit version)))
662 (file-name (git-file-name name version))
663 (sha256
664 (base32
665 "1xmnf8whzv2gnkkdv0fqcn9qwmcc7y647p4kw9fi3lvcp9kch8vi"))))
666 (build-system python-build-system)
667 (arguments
668 `(#:phases
669 (modify-phases %standard-phases
670 (replace 'check
671 (lambda* (#:key tests? #:allow-other-keys)
672 (if tests?
673 (invoke "pytest" "-vv")
674 (format #t "test suite not run~%"))
675 #t)))))
676 (native-inputs
677 `(;; All native inputs are for tests.
678 ("python-pyasn1" ,python-pyasn1)
679 ("python-pytest" ,python-pytest)
680 ("python-pytest-cov" ,python-pytest-cov)
681 ("python-pytest-runner" ,python-pytest-runner)))
682 (propagated-inputs
683 `(("python-cryptography" ,python-cryptography)
684 ("python-rsa" ,python-rsa)
685 ("python-six" ,python-six)))
686 (synopsis "JOSE implementation in Python")
687 (description
688 "The @dfn{JavaScript Object Signing and Encryption} (JOSE) technologies
689 - JSON Web Signature (JWS), JSON Web Encryption (JWE), JSON Web Key (JWK), and
690 JSON Web Algorithms (JWA) - collectively can be used to encrypt and/or sign
691 content using a variety of algorithms.")
692 (license license:expat)))
693
694 (define-public python-jsonpickle
695 (package
696 (name "python-jsonpickle")
697 (version "1.4.1")
698 (source (origin
699 (method url-fetch)
700 (uri (pypi-uri "jsonpickle" version))
701 (sha256
702 (base32
703 "1fn86z468hamw8njh2grw2xdhsm7g48dyxs3lw0n10nn1g6vgm78"))))
704 (build-system python-build-system)
705 (arguments
706 `(#:phases (modify-phases %standard-phases
707 (replace 'check
708 (lambda _
709 (setenv "PYTHONPATH"
710 (string-append "./build/lib:"
711 (getenv "PYTHONPATH")))
712 (invoke "pytest" "-vv"
713 ;; Prevent running the flake8 and black
714 ;; pytest plugins, which only tests style
715 ;; and frequently causes harmless failures.
716 "-o" "addopts=''"))))))
717 (native-inputs
718 `(("python-setuptools-scm" ,python-setuptools-scm)
719 ("python-toml" ,python-toml) ;XXX: for setuptools_scm[toml]
720 ;; For tests.
721 ("python-numpy" ,python-numpy)
722 ("python-pandas" ,python-pandas)
723 ("python-pytest" ,python-pytest)))
724 (home-page "https://jsonpickle.github.io/")
725 (synopsis "Serialize object graphs into JSON")
726 (description
727 "This package provides a Python library for serializing any arbitrary
728 object graph to and from JSON.")
729 (license license:bsd-3)))
730
731 (define-public python-mechanicalsoup
732 (package
733 (name "python-mechanicalsoup")
734 (version "0.11.0")
735 (source
736 (origin
737 (method url-fetch)
738 (uri (pypi-uri "MechanicalSoup" version))
739 (sha256
740 (base32 "0k59wwk75q7nz6i6gynvzhagy02ql0bv7py3qqcwgjw7607yq4i7"))))
741 (build-system python-build-system)
742 (arguments
743 ;; TODO: Enable tests when python-flake8@3.5 hits master.
744 `(#:tests? #f))
745 (propagated-inputs
746 `(("python-beautifulsoup4" ,python-beautifulsoup4)
747 ("python-lxml" ,python-lxml)
748 ("python-requests" ,python-requests)
749 ("python-six" ,python-six)))
750 ;; (native-inputs
751 ;; ;; For tests.
752 ;; `(("python-pytest-flake8" ,python-pytest-flake8)
753 ;; ("python-pytest-httpbin" ,python-pytest-httpbin)
754 ;; ("python-pytest-mock" ,python-pytest-mock)
755 ;; ("python-pytest-runner" ,python-pytest-runner)
756 ;; ("python-requests-mock" ,python-requests-mock)))
757 (home-page "https://mechanicalsoup.readthedocs.io/")
758 (synopsis "Python library for automating website interaction")
759 (description
760 "MechanicalSoup is a Python library for automating interaction with
761 websites. It automatically stores and sends cookies, follows redirects, and can
762 follow links and submit forms. It doesn’t do JavaScript.")
763 (license license:expat)))
764
765 (define-public python2-mechanicalsoup
766 (package-with-python2 python-mechanicalsoup))
767
768 (define-public python-hyperframe
769 (package
770 (name "python-hyperframe")
771 (version "5.2.0")
772 (source
773 (origin
774 (method url-fetch)
775 (uri (pypi-uri "hyperframe" version))
776 (sha256
777 (base32 "07xlf44l1cw0ghxx46sbmkgzil8vqv8kxwy42ywikiy35izw3xd9"))))
778 (build-system python-build-system)
779 (arguments
780 `(#:phases
781 (modify-phases %standard-phases
782 (replace 'check
783 (lambda* (#:key inputs outputs #:allow-other-keys)
784 (add-installed-pythonpath inputs outputs)
785 (invoke "pytest" "-vv" "test"))))))
786 (native-inputs
787 `(("python-pytest" ,python-pytest)))
788 (home-page "https://github.com/python-hyper/hyperframe")
789 (synopsis "HTTP/2 framing layer for Python")
790 (description
791 "This library contains the HTTP/2 framing code used in the hyper project.
792 It provides a pure-Python codebase that is capable of decoding a binary stream
793 into HTTP/2 frames.")
794 (license license:expat)))
795
796 (define-public python-hpack
797 (package
798 (name "python-hpack")
799 (version "3.0.0")
800 (source
801 (origin
802 ;; PyPI tarball is missing some files necessary for the tests.
803 (method git-fetch)
804 (uri (git-reference
805 (url "https://github.com/python-hyper/hpack")
806 (commit (string-append "v" version))))
807 (file-name (git-file-name name version))
808 (sha256
809 (base32 "0w8hkz50a6lzkmgi41ryicm0mh9ca9cx29pm3s0xlpn0vs29xrmd"))))
810 (build-system python-build-system)
811 (arguments
812 `(#:phases
813 (modify-phases %standard-phases
814 (replace 'check
815 (lambda* (#:key inputs outputs #:allow-other-keys)
816 (add-installed-pythonpath inputs outputs)
817 (invoke "pytest" "-vv" "test" "-k"
818 ;; This test will be fixed in the next version. See:
819 ;; https://github.com/python-hyper/hpack/issues/168.
820 "not test_get_by_index_out_of_range"))))))
821 (native-inputs
822 `(("python-pytest" ,python-pytest)))
823 (home-page "https://hyper.rtfd.org")
824 (synopsis "Pure-Python HPACK header compression")
825 (description
826 "This module contains a pure-Python HTTP/2 header encoding (HPACK) logic
827 for use in Python programs that implement HTTP/2.")
828 (license license:expat)))
829
830 (define-public python-h11
831 (package
832 (name "python-h11")
833 (version "0.9.0")
834 (source
835 (origin
836 (method url-fetch)
837 (uri (pypi-uri "h11" version))
838 (sha256
839 (base32 "1qfad70h59hya21vrzz8dqyyaiqhac0anl2dx3s3k80gpskvrm1k"))))
840 (build-system python-build-system)
841 (arguments
842 `(#:phases
843 (modify-phases %standard-phases
844 (replace 'check
845 (lambda _
846 (invoke "pytest" "-vv"))))))
847 (native-inputs
848 `(("python-pytest" ,python-pytest)))
849 (home-page "https://github.com/python-hyper/h11")
850 (synopsis "Pure-Python, bring-your-own-I/O implementation of HTTP/1.1")
851 (description
852 "This is a little HTTP/1.1 library written from scratch in Python, heavily
853 inspired by hyper-h2. It's a bring-your-own-I/O library; h11 contains no IO
854 code whatsoever. This means you can hook h11 up to your favorite network API,
855 and that could be anything you want.")
856 (license license:expat)))
857
858 (define-public python-h2
859 (package
860 (name "python-h2")
861 (version "3.2.0")
862 (source
863 (origin
864 (method url-fetch)
865 (uri (pypi-uri "h2" version))
866 (sha256
867 (base32 "051gg30aca26rdxsmr9svwqm06pdz9bv21ch4n0lgi7jsvml2pw7"))))
868 (build-system python-build-system)
869 (arguments
870 `(#:phases
871 (modify-phases %standard-phases
872 (replace 'check
873 (lambda* (#:key inputs outputs #:allow-other-keys)
874 (add-installed-pythonpath inputs outputs)
875 (invoke "pytest" "-vv" "test"))))))
876 (native-inputs
877 `(("python-pytest" ,python-pytest)))
878 (propagated-inputs
879 `(("python-hpack" ,python-hpack)
880 ("python-hyperframe" ,python-hyperframe)))
881 (home-page "https://github.com/python-hyper/hyper-h2")
882 (synopsis "HTTP/2 State-Machine based protocol implementation")
883 (description
884 "This module contains a pure-Python implementation of a HTTP/2 protocol
885 stack. It does not provide a parsing layer, a network layer, or any rules
886 about concurrency. Instead, it's a purely in-memory solution, defined in
887 terms of data actions and HTTP/2 frames. This is one building block of a full
888 Python HTTP implementation.")
889 (license license:expat)))
890
891 (define-public python-sockjs-tornado
892 (package
893 (name "python-sockjs-tornado")
894 (version "1.0.6")
895 (source
896 (origin
897 (method url-fetch)
898 (uri (pypi-uri "sockjs-tornado" version))
899 (sha256
900 (base32
901 "15dgv6hw6c7h3m310alw1h6p5443lrm9pyqhcv2smc13fz1v04pc"))))
902 (build-system python-build-system)
903 (arguments
904 `(;; There are no tests, and running the test phase requires missing
905 ;; dependencies
906 #:tests? #f))
907 (propagated-inputs
908 `(("python-tornado" ,python-tornado)))
909 (home-page "https://github.com/mrjoes/sockjs-tornado/")
910 (synopsis
911 "SockJS Python server implementation on top of the Tornado framework")
912 (description
913 "SockJS-tornado provides the server-side counterpart to a SockJS client
914 library, through the Tornado framework.
915
916 SockJS provides a low-latency, full-duplex, cross-domain communication channel
917 between a web browser and web server.")
918 (license license:expat)))
919
920 (define-public python2-sockjs-tornado
921 (package-with-python2 python-sockjs-tornado))
922
923 (define-public python-flask-babel
924 (package
925 (name "python-flask-babel")
926 (version "1.0.0")
927 (source
928 (origin
929 (method url-fetch)
930 (uri (pypi-uri "Flask-Babel" version))
931 (sha256
932 (base32
933 "0gmb165vkwv5v7dxsxa2i3zhafns0fh938m2zdcrv4d8z5l099yn"))))
934 (build-system python-build-system)
935 (arguments
936 '(#:phases (modify-phases %standard-phases
937 (replace 'check
938 (lambda _
939 (with-directory-excursion "tests"
940 (invoke "python" "tests.py")))))))
941 (propagated-inputs
942 `(("python-flask" ,python-flask)
943 ("python-babel" ,python-babel)
944 ("python-jinja2" ,python-jinja2)
945 ("python-pytz" ,python-pytz)))
946 (home-page "https://github.com/python-babel/flask-babel")
947 (synopsis "Add i18n/l10n support to Flask applications")
948 (description "This package implements internationalization and localization
949 support for Flask. This is based on the Python babel module as well as pytz -
950 both of which are installed automatically if you install this library.")
951 (license license:bsd-3)))
952
953 (define-public python2-flask-babel
954 (package-with-python2 python-flask-babel))
955
956 (define-public python-flask-cors
957 (package
958 (name "python-flask-cors")
959 (version "3.0.9")
960 (source (origin
961 (method url-fetch)
962 (uri (pypi-uri "Flask-Cors" version))
963 (sha256
964 (base32
965 "1f36hkaxc92zn12f88fkzwifdvlvsnmlp1dv3p5inpcc500c3kvb"))))
966 (build-system python-build-system)
967 (native-inputs
968 `(("python-flask" ,python-flask)
969 ("python-nose" ,python-nose)
970 ("python-packaging" ,python-packaging)))
971 (propagated-inputs
972 `(("python-six" ,python-six)))
973 (home-page "https://flask-cors.readthedocs.io/en/latest/")
974 (synopsis "Handle Cross-Origin Resource Sharing with Flask")
975 (description
976 "This package provides a Flask extension for handling @acronym{CORS,Cross
977 Origin Resource Sharing}, making cross-origin AJAX possible.")
978 (license license:expat)))
979
980 (define-public python-flask-markdown
981 (package
982 (name "python-flask-markdown")
983 (version "0.3")
984 (source
985 (origin
986 (method url-fetch)
987 (uri (pypi-uri "Flask-Markdown" version))
988 (sha256
989 (base32
990 "0l32ikv4f7va926jlq4f7gx0xid247bhlxl6bd9av5dk8ljz1hyq"))))
991 (build-system python-build-system)
992 (arguments
993 '(#:tests? #f)) ; Tests seem to be incompatible with latest python
994 (propagated-inputs
995 `(("python-markdown" ,python-markdown)
996 ("python-flask" ,python-flask)))
997 (native-inputs
998 `(("python-nose" ,python-nose)))
999 (home-page "https://github.com/dcolish/flask-markdown")
1000 (synopsis "Small extension to help with using Markdown in Flask")
1001 (description
1002 "Flask-Markdown supports several extensions for Markdown and integrates
1003 into Jinja2 by default.")
1004 (license license:bsd-3)))
1005
1006 (define-public python-flask-session
1007 (package
1008 (name "python-flask-session")
1009 (version "0.3.2")
1010 (source
1011 (origin
1012 (method url-fetch)
1013 (uri (pypi-uri "Flask-Session" version))
1014 (sha256
1015 (base32
1016 "08s4msg8jzb8vgb9bd491zvrzhrdldxdw6vimb0kx5kgy2xy4s07"))))
1017 (build-system python-build-system)
1018 (arguments
1019 '(#:tests? #f)) ; Tests require the various storage backends to be present
1020 (propagated-inputs
1021 `(("python-flask" ,python-flask)))
1022 (home-page "https://github.com/fengsp/flask-session")
1023 (synopsis "Adds server-side session support to your Flask application")
1024 (description
1025 "Flask-Session is an extension for Flask that adds support for
1026 Server-side sessions, with a variety of different backends for session
1027 storage.")
1028 (license license:bsd-3)))
1029
1030 (define-public python-html5lib
1031 (package
1032 (name "python-html5lib")
1033 (version "1.1")
1034 (source
1035 (origin
1036 (method url-fetch)
1037 (uri (pypi-uri "html5lib" version))
1038 (sha256
1039 (base32
1040 "0vqlhk0hgbsfkh7ybmby93xhlx8dq6pr5blf356ka3z2c41b9rdj"))))
1041 (build-system python-build-system)
1042 (propagated-inputs
1043 `(("python-six" ,python-six)
1044 ("python-webencodings" ,python-webencodings)))
1045 (arguments
1046 `(#:test-target "check"))
1047 (home-page
1048 "https://github.com/html5lib/html5lib-python")
1049 (synopsis
1050 "Python HTML parser based on the WHATWG HTML specification")
1051 (description
1052 "Html5lib is an HTML parser based on the WHATWG HTML specification
1053 and written in Python.")
1054 (license license:expat)))
1055
1056 (define-public python2-html5lib
1057 (package-with-python2 python-html5lib))
1058
1059 ;; Needed for python-bleach, a dependency of python-notebook
1060 (define-public python-html5lib-0.9
1061 (package
1062 (inherit python-html5lib)
1063 (version "0.999")
1064 (source
1065 (origin
1066 (method url-fetch)
1067 (uri (pypi-uri "html5lib" version))
1068 (sha256
1069 (base32
1070 "17n4zfsj6ynmbwdwviywmj8r6nzr3xvfx2zs0xhndmvm51z7z263"))))))
1071
1072 (define-public python2-html5lib-0.9
1073 (package-with-python2 python-html5lib-0.9))
1074
1075 (define-public python-html5-parser
1076 (package
1077 (name "python-html5-parser")
1078 (version "0.4.9")
1079 (source (origin
1080 (method url-fetch)
1081 (uri (pypi-uri "html5-parser" version))
1082 (sha256
1083 (base32
1084 "13yl3vnf3sxl05m0nhpngnrz3g1jvyahd33lys3m3hfb91l8zzi5"))))
1085 (build-system python-build-system)
1086 (native-inputs
1087 `(("pkg-config" ,pkg-config)))
1088 (inputs
1089 `(("libxml2" ,libxml2)))
1090 (propagated-inputs
1091 `(("python-lxml" ,python-lxml)
1092 ("python-beautifulsoup4" ,python-beautifulsoup4)))
1093 (home-page "https://html5-parser.readthedocs.io")
1094 (synopsis "Fast C-based HTML5 parsing for Python")
1095 (description "This package provides a fast implementation of the HTML5
1096 parsing spec for Python. Parsing is done in C using a variant of the gumbo
1097 parser. The gumbo parse tree is then transformed into an lxml tree, also in
1098 C, yielding parse times that can be a thirtieth of the html5lib parse times.")
1099 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
1100 ;; indicate ASL2.0, including the LICENSE file for the whole project.
1101 (license (list license:asl2.0 license:gpl3))))
1102
1103 (define-public python2-html5-parser
1104 (package-with-python2 python-html5-parser))
1105
1106 (define-public python-minio
1107 (package
1108 (name "python-minio")
1109 (version "6.0.0")
1110 (source (origin
1111 (method url-fetch)
1112 (uri (pypi-uri "minio" version))
1113 (sha256
1114 (base32
1115 "1cxpa0m7mdvpdbc1g6wlihq6ja4g4paxkl6f3q84bbnx07zpbllp"))))
1116 (build-system python-build-system)
1117 (arguments
1118 '(#:phases (modify-phases %standard-phases
1119 (add-before 'check 'disable-failing-tests
1120 (lambda _
1121 ;; This test requires network access.
1122 (delete-file "tests/unit/credentials_test.py")
1123 #t)))))
1124 (native-inputs
1125 `(("python-faker" ,python-faker)
1126 ("python-mock" ,python-mock)
1127 ("python-nose" ,python-nose)))
1128 (propagated-inputs
1129 `(("python-certifi" ,python-certifi)
1130 ("python-configparser" ,python-configparser)
1131 ("python-dateutil" ,python-dateutil)
1132 ("python-pytz" ,python-pytz)
1133 ("python-urllib3" ,python-urllib3)))
1134 (home-page "https://github.com/minio/minio-py")
1135 (synopsis "Programmatically access Amazon S3 from Python")
1136 (description
1137 "This package provides a Python library for interacting with any
1138 Amazon S3 compatible object storage server.")
1139 (license license:asl2.0)))
1140
1141 (define-public python-pycurl
1142 (package
1143 (name "python-pycurl")
1144 (version "7.43.0.5")
1145 (source
1146 (origin
1147 (method url-fetch)
1148 (uri (string-append "https://dl.bintray.com/pycurl/pycurl/pycurl-"
1149 version ".tar.gz"))
1150 (sha256
1151 (base32 "1cwlb76vddqp2mxqvjbhf367caddzy82rhangddjjhjqaj8x4zgc"))))
1152 (build-system python-build-system)
1153 (arguments
1154 ;; The tests attempt to access external web servers, so we cannot run
1155 ;; them. Furthermore, they are skipped altogether when using Python 2.
1156 '(#:tests? #f
1157 #:phases (modify-phases %standard-phases
1158 (add-before 'build 'configure-tls-backend
1159 (lambda _
1160 ;; XXX: PycURL fails to automatically determine which TLS
1161 ;; backend to use when cURL is built with --disable-static.
1162 ;; See setup.py and <https://github.com/pycurl/pycurl/pull/147>.
1163 (setenv "PYCURL_SSL_LIBRARY" "gnutls")
1164 #t)))))
1165 (native-inputs
1166 `(("python-nose" ,python-nose)
1167 ("python-bottle" ,python-bottle)))
1168 (inputs
1169 `(("curl" ,curl)
1170 ("gnutls" ,gnutls)))
1171 (home-page "http://pycurl.io/")
1172 (synopsis "Lightweight Python wrapper around libcurl")
1173 (description "Pycurl is a lightweight wrapper around libcurl. It provides
1174 high-speed transfers via libcurl and frequently outperforms alternatives.")
1175
1176 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
1177 ;; under the terms of LGPLv2.1+ or Expat.
1178 (license (list license:lgpl2.1+ license:expat))))
1179
1180 (define-public python2-pycurl
1181 (package-with-python2 python-pycurl))
1182
1183 (define-public python-webencodings
1184 (package
1185 (name "python-webencodings")
1186 (version "0.5.1")
1187 (source (origin
1188 (method url-fetch)
1189 (uri (pypi-uri "webencodings" version))
1190 (sha256
1191 (base32
1192 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
1193 (build-system python-build-system)
1194 (arguments
1195 '(#:phases
1196 (modify-phases %standard-phases
1197 (replace 'check
1198 (lambda _
1199 (invoke "py.test" "-v" "webencodings/tests.py")
1200 #t)))))
1201 (native-inputs
1202 `(("python-pytest" ,python-pytest)))
1203 (home-page "https://github.com/SimonSapin/python-webencodings")
1204 (synopsis "Character encoding aliases for legacy web content")
1205 (description
1206 "In order to be compatible with legacy web content when interpreting
1207 something like @code{Content-Type: text/html; charset=latin1}, tools need
1208 to use a particular set of aliases for encoding labels as well as some
1209 overriding rules. For example, @code{US-ASCII} and @code{iso-8859-1} on
1210 the web are actually aliases for @code{windows-1252}, and a @code{UTF-8}
1211 or @code{UTF-16} BOM takes precedence over any other encoding declaration.
1212 The WHATWG @url{https://encoding.spec.whatwg.org/,Encoding} standard
1213 defines all such details so that implementations do not have to
1214 reverse-engineer each other.
1215
1216 This module implements the Encoding standard and has encoding labels and
1217 BOM detection, but the actual implementation for encoders and decoders
1218 is Python’s.")
1219 (license license:bsd-3)))
1220
1221 (define-public python2-webencodings
1222 (package-with-python2 python-webencodings))
1223
1224 (define-public python-openid
1225 (package
1226 (name "python-openid")
1227 (version "3.2.0")
1228 (source
1229 (origin
1230 (method url-fetch)
1231 (uri (pypi-uri "python3-openid" version))
1232 (sha256
1233 (base32
1234 "1bxf9a3ny1js422j962zfzl4a9dhj192pvai05whn7j0iy9gdyrk"))))
1235 (build-system python-build-system)
1236 (arguments
1237 `(#:phases
1238 (modify-phases %standard-phases
1239 (replace 'check
1240 (lambda _
1241 (invoke "coverage" "run" "-m"
1242 "unittest" "openid.test.test_suite"))))))
1243 (properties `((python2-variant . ,(delay python2-openid))))
1244 (propagated-inputs
1245 `(("python-defusedxml" ,python-defusedxml)))
1246 (native-inputs
1247 `(("python-coverage" ,python-coverage)
1248 ("python-psycopg2" ,python-psycopg2)
1249 ("python-django" ,python-django)))
1250 (home-page "https://github.com/necaris/python3-openid")
1251 (synopsis "OpenID support for servers and consumers")
1252 (description "This library provides OpenID authentication for Python, both
1253 for clients and servers.")
1254 (license license:asl2.0)))
1255
1256 (define-public python2-openid
1257 (package
1258 (name "python2-openid")
1259 (version "2.2.5")
1260 (source
1261 (origin
1262 (method url-fetch)
1263 (uri (pypi-uri "python-openid" version))
1264 (sha256
1265 (base32
1266 "1vvhxlghjan01snfdc4k7ykd80vkyjgizwgg9bncnin8rqz1ricj"))))
1267 (build-system python-build-system)
1268 (arguments
1269 ;; Python 3 support is in `python3-openid`, a separate package.
1270 `(#:python ,python-2
1271 ;; Tests aren't initialized correctly.
1272 #:tests? #f))
1273 (home-page "https://github.com/openid/python-openid")
1274 (synopsis "OpenID support for servers and consumers")
1275 (description "This library provides OpenID authentication for Python, both
1276 for clients and servers.")
1277 (license license:asl2.0)))
1278
1279 (define-public python-cssutils
1280 (package
1281 (name "python-cssutils")
1282 (version "1.0.2")
1283 (source
1284 (origin
1285 (method url-fetch)
1286 (uri (pypi-uri "cssutils" version))
1287 (sha256
1288 (base32
1289 "1bxchrbqzapwijap0yhlxdil1w9bmwvgx77aizlkhc2mcxjg1z52"))))
1290 (build-system python-build-system)
1291 (native-inputs
1292 `(("unzip" ,unzip))) ; for unpacking the source
1293 (arguments
1294 `(#:tests? #f)) ; tests require python-pbr < 1.7.0
1295 (home-page "http://cthedot.de/cssutils/")
1296 (synopsis
1297 "CSS Cascading Style Sheets library for Python")
1298 (description
1299 "Cssutils is a Python package for parsing and building CSS
1300 Cascading Style Sheets. Currently it provides a DOM only and no rendering
1301 options.")
1302 (license license:lgpl3+)))
1303
1304 (define-public python2-cssutils
1305 (package-with-python2 python-cssutils))
1306
1307 (define-public python-css-parser
1308 (package
1309 (inherit python-cssutils)
1310 (name "python-css-parser")
1311 (version "1.0.6")
1312 (source
1313 (origin
1314 (method url-fetch)
1315 (uri (pypi-uri "css-parser" version ".tar.gz"))
1316 (sha256
1317 (base32 "0bmg4kiiir6pj9x3sd12x4dz2c1xpp2bn5nn60fxnbk2lnl4im2f"))))
1318 (home-page "https://github.com/ebook-utils/css-parser")
1319 (synopsis "Fork of cssutils modified for parsing ebooks")
1320 (description
1321 "Css-parser is a Python package for parsing and building CSS
1322 Cascading Style Sheets. Currently it provides a DOM only and no rendering
1323 options.
1324
1325 It's a fork of cssutils 1.0.2, updated and modified for parsing ebooks, due to
1326 cssutils not receiving updates as of 1.0.2.")
1327 (license license:lgpl3+)))
1328
1329 (define-public python2-css-parser
1330 (package-with-python2 python-css-parser))
1331
1332 (define-public python-cssselect
1333 (package
1334 (name "python-cssselect")
1335 (version "1.1.0")
1336 (source (origin
1337 ;; The PyPI release does not contain tests.
1338 (method git-fetch)
1339 (uri (git-reference
1340 (url "https://github.com/scrapy/cssselect")
1341 (commit (string-append "v" version))))
1342 (file-name (git-file-name name version))
1343 (sha256
1344 (base32
1345 "0xslrnhbrmgakp4xg6k26qffay3kqffp3a2z2sk27c65rwxa79kc"))))
1346 (build-system python-build-system)
1347 (arguments
1348 `(#:phases (modify-phases %standard-phases
1349 (replace 'check
1350 (lambda _
1351 (invoke "pytest" "-vv"))))))
1352 (native-inputs
1353 `(("python-lxml" ,python-lxml)
1354 ("python-pytest" ,python-pytest)))
1355 (home-page "https://github.com/scrapy/cssselect")
1356 (synopsis "CSS3 selector parser and translator to XPath 1.0")
1357 (description
1358 "Cssselect ia a Python module that parses CSS3 Selectors and translates
1359 them to XPath 1.0 expressions. Such expressions can be used in lxml or
1360 another XPath engine to find the matching elements in an XML or HTML document.")
1361 (license license:bsd-3)))
1362
1363 (define-public python2-cssselect
1364 (package-with-python2 python-cssselect))
1365
1366 (define-public python-databricks-cli
1367 (package
1368 (name "python-databricks-cli")
1369 (version "0.14.1")
1370 (home-page "https://github.com/databricks/databricks-cli")
1371 (source (origin
1372 (method git-fetch)
1373 (uri (git-reference (url home-page) (commit version)))
1374 (file-name (git-file-name name version))
1375 (sha256
1376 (base32
1377 "03w19rzh72jll9phai23wp0c2mlv39qsrv50mhckziy39z60yxh8"))))
1378 (build-system python-build-system)
1379 (arguments
1380 `(#:phases (modify-phases %standard-phases
1381 (replace 'check
1382 (lambda _
1383 (setenv "PYTHONPATH"
1384 (string-append "./build/lib:"
1385 (getenv "PYTHONPATH")))
1386 (invoke "pytest" "tests" "-vv"
1387 ;; XXX: This fails with newer Pytest
1388 ;; (upstream uses Pytest 3..).
1389 "-k" "not test_get_request_with_list"))))))
1390 (native-inputs
1391 `(;; For tests.
1392 ("python-decorator" ,python-decorator)
1393 ("python-mock" ,python-mock)
1394 ("python-pytest" ,python-pytest)
1395 ("python-requests-mock" ,python-requests-mock)))
1396 (propagated-inputs
1397 `(("python-click" ,python-click)
1398 ("python-configparser" ,python-configparser)
1399 ("python-requests" ,python-requests)
1400 ("python-six" ,python-six)
1401 ("python-tabulate" ,python-tabulate)))
1402 (synopsis "Command line interface for Databricks")
1403 (description
1404 "The Databricks Command Line Interface is a tool which provides an easy
1405 to use interface to the Databricks platform. The CLI is built on top of the
1406 Databricks REST APIs.")
1407 (license license:asl2.0)))
1408
1409 (define-public python-openid-cla
1410 (package
1411 (name "python-openid-cla")
1412 (version "1.2")
1413 (source
1414 (origin
1415 (method url-fetch)
1416 (uri (pypi-uri "python-openid-cla" version))
1417 (sha256
1418 (base32
1419 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
1420 (build-system python-build-system)
1421 (arguments '(#:tests? #f)) ; No tests.
1422 (home-page "https://github.com/puiterwijk/python-openid-cla/")
1423 (synopsis "Implementation of the OpenID CLA extension for python-openid")
1424 (description "@code{openid-cla} is an implementation of the OpenID
1425 contributor license agreement extension for python-openid.")
1426 (license license:bsd-3)))
1427
1428 (define-public python2-openid-cla
1429 (package-with-python2 python-openid-cla))
1430
1431 (define-public python-openid-teams
1432 (package
1433 (name "python-openid-teams")
1434 (version "1.1")
1435 (source
1436 (origin
1437 (method url-fetch)
1438 (uri (pypi-uri "python-openid-teams" version))
1439 (sha256
1440 (base32
1441 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
1442 (build-system python-build-system)
1443 (arguments '(#:tests? #f)) ; No tests.
1444 (home-page "https://github.com/puiterwijk/python-openid-teams/")
1445 (synopsis "Implementation of the OpenID teams extension for python-openid")
1446 (description
1447 "@code{openid-teams} is an implementation of the OpenID
1448 teams extension for python-openid.")
1449 (license license:bsd-3)))
1450
1451 (define-public python2-openid-teams
1452 (package-with-python2 python-openid-teams))
1453
1454 (define-public python-priority
1455 (package
1456 (name "python-priority")
1457 (version "1.3.0")
1458 (source
1459 (origin
1460 (method url-fetch)
1461 (uri (pypi-uri "priority" version))
1462 (sha256
1463 (base32 "1gpzn9k9zgks0iw5wdmad9b4dry8haiz2sbp6gycpjkzdld9dhbb"))))
1464 (build-system python-build-system)
1465 (arguments
1466 `(#:phases
1467 (modify-phases %standard-phases
1468 (replace 'check
1469 (lambda* (#:key inputs outputs #:allow-other-keys)
1470 (add-installed-pythonpath inputs outputs)
1471 (invoke "pytest" "-vv" "test" "-k"
1472 ;; This test exceeded the Hypothesis deadline.
1473 "not test_period_of_repetition"))))))
1474 (native-inputs
1475 `(("python-hypothesis" ,python-hypothesis)
1476 ("python-pytest" ,python-pytest)
1477 ("python-pytest-cov" ,python-pytest-cov)
1478 ("python-pytest-xdist" ,python-pytest-xdist)))
1479 (home-page "https://python-hyper.org/projects/priority/en/latest/")
1480 (synopsis "Pure-Python implementation of the HTTP/2 priority tree")
1481 (description
1482 "Priority is a pure-Python implementation of the priority logic for HTTP/2,
1483 set out in RFC 7540 Section 5.3 (Stream Priority).")
1484 (license license:expat)))
1485
1486 (define-public python-wsproto
1487 (package
1488 (name "python-wsproto")
1489 (version "0.15.0")
1490 (source
1491 (origin
1492 (method url-fetch)
1493 (uri (pypi-uri "wsproto" version))
1494 (sha256
1495 (base32 "17gsxlli4w8am1wwwl3k90hpdfa213ax40ycbbvb7hjx1v1rhiv1"))))
1496 (build-system python-build-system)
1497 (arguments
1498 `(#:phases
1499 (modify-phases %standard-phases
1500 (replace 'check
1501 (lambda* (#:key inputs outputs #:allow-other-keys)
1502 (add-installed-pythonpath inputs outputs)
1503 (invoke "pytest" "-vv" "test"))))))
1504 (native-inputs
1505 `(("python-pytest" ,python-pytest)))
1506 (propagated-inputs
1507 `(("python-h11" ,python-h11)))
1508 (home-page "https://github.com/python-hyper/wsproto/")
1509 (synopsis "WebSockets state-machine based protocol implementation")
1510 (description
1511 "@code{wsproto} is a pure-Python implementation of a WebSocket protocol
1512 stack. It's written from the ground up to be embeddable in whatever program you
1513 choose to use, ensuring that you can communicate via WebSockets, as defined in
1514 RFC6455, regardless of your programming paradigm.")
1515 (license license:expat)))
1516
1517 (define-public python-hypercorn
1518 (package
1519 (name "python-hypercorn")
1520 (version "0.10.2")
1521 (source
1522 (origin
1523 (method url-fetch)
1524 (uri (pypi-uri "Hypercorn" version))
1525 (sha256
1526 (base32 "15dgy47a18w2ls3hwykra1cyf7yzxmfjqnsqml482p12cxr2xwqr"))))
1527 (build-system python-build-system)
1528 (arguments
1529 `(#:phases
1530 (modify-phases %standard-phases
1531 (replace 'check
1532 (lambda* (#:key inputs outputs #:allow-other-keys)
1533 (add-installed-pythonpath inputs outputs)
1534 (invoke "pytest" "-vv"))))))
1535 (propagated-inputs
1536 `(("python-h11" ,python-h11)
1537 ("python-h2" ,python-h2)
1538 ("python-priority" ,python-priority)
1539 ("python-toml" ,python-toml)
1540 ("python-typing-extensions" ,python-typing-extensions)
1541 ("python-wsproto" ,python-wsproto)))
1542 (native-inputs
1543 `(("python-hypothesis" ,python-hypothesis)
1544 ("python-mock" ,python-mock)
1545 ("python-pytest" ,python-pytest)
1546 ("python-pytest-asyncio" ,python-pytest-asyncio)
1547 ("python-pytest-cov" ,python-pytest-cov)
1548 ("python-pytest-trio" ,python-pytest-trio)
1549 ("python-trio" ,python-trio)))
1550 (home-page "https://gitlab.com/pgjones/hypercorn/")
1551 (synopsis "ASGI Server based on Hyper libraries")
1552 (description
1553 "Hypercorn is an ASGI web server based on the sans-io hyper, h11, h2, and
1554 wsproto libraries and inspired by Gunicorn. It supports HTTP/1, HTTP/2,
1555 WebSockets (over HTTP/1 and HTTP/2), ASGI/2, and ASGI/3 specifications. It can
1556 utilise asyncio, uvloop, or trio worker types.")
1557 (license license:expat)))
1558
1559 (define-public python-querystring-parser
1560 (package
1561 (name "python-querystring-parser")
1562 (version "1.2.4")
1563 (source (origin
1564 (method url-fetch)
1565 (uri (pypi-uri "querystring_parser" version))
1566 (sha256
1567 (base32
1568 "0qlar8a0wa003hm2z6wcpb625r6vjj0a70rsni9h8lz0zwfcwkv4"))))
1569 (build-system python-build-system)
1570 (arguments
1571 `(#:phases (modify-phases %standard-phases
1572 (replace 'check
1573 (lambda _
1574 ;; XXX FIXME: This test is broken with Python 3.7:
1575 ;; https://github.com/bernii/querystring-parser/issues/35
1576 (substitute* "querystring_parser/tests.py"
1577 (("self\\.assertEqual\\(self\\.knownValuesNormalized, result\\)")
1578 "True"))
1579 (invoke "python" "querystring_parser/tests.py"))))))
1580 (propagated-inputs
1581 `(("python-six" ,python-six)))
1582 (home-page "https://github.com/bernii/querystring-parser")
1583 (synopsis "QueryString parser that correctly handles nested dictionaries")
1584 (description
1585 "This package provides a query string parser for Python and Django
1586 projects that correctly creates nested dictionaries from sent form/querystring
1587 data.")
1588 (license license:expat)))
1589
1590 (define-public python-tornado
1591 (package
1592 (name "python-tornado")
1593 (version "5.1.1")
1594 (source
1595 (origin
1596 (method url-fetch)
1597 (uri (pypi-uri "tornado" version))
1598 (sha256
1599 (base32
1600 "02clqk2116jbnq8lnaqmdw3p52nqrd9ib59r4xz2ll43fpcmhlaf"))))
1601 (build-system python-build-system)
1602 (arguments
1603 '(;; FIXME: Two tests error out with:
1604 ;; AssertionError: b'Error in atexit._run_exitfuncs:\nFileNotF[44 chars]ry\n' != b''
1605 ;; #:phases
1606 ;; (modify-phases %standard-phases
1607 ;; (replace 'check
1608 ;; (lambda _
1609 ;; ;; 'setup.py test' hits an AssertionError on BSD-specific
1610 ;; ;; "tornado/platform/kqueue.py". This is the supported method:
1611 ;; (invoke "python" "-m" "tornado.test.runtests")
1612 ;; #t)))
1613 #:tests? #f))
1614 (native-inputs
1615 `(("python-certifi" ,python-certifi)))
1616 (home-page "https://www.tornadoweb.org/")
1617 (synopsis "Python web framework and asynchronous networking library")
1618 (description
1619 "Tornado is a Python web framework and asynchronous networking library,
1620 originally developed at FriendFeed. By using non-blocking network I/O,
1621 Tornado can scale to tens of thousands of open connections, making it ideal
1622 for long polling, WebSockets, and other applications that require a long-lived
1623 connection to each user.")
1624 (license license:asl2.0)
1625 (properties `((python2-variant . ,(delay python2-tornado))))))
1626
1627 (define-public python-tornado-6
1628 (package
1629 (name "python-tornado")
1630 (version "6.0.4")
1631 (source
1632 (origin
1633 (method url-fetch)
1634 (uri (pypi-uri "tornado" version))
1635 (sha256
1636 (base32
1637 "1p5n7sw4580pkybywg93p8ddqdj9lhhy72rzswfa801vlidx9qhg"))))
1638 (build-system python-build-system)
1639 (arguments
1640 '(#:phases
1641 (modify-phases %standard-phases
1642 (replace 'check
1643 (lambda _
1644 (invoke "python" "-m" "tornado.test.runtests")
1645 #t)))))
1646 (native-inputs
1647 `(("python-certifi" ,python-certifi)))
1648 (home-page "https://www.tornadoweb.org/")
1649 (synopsis "Python web framework and asynchronous networking library")
1650 (description
1651 "Tornado is a Python web framework and asynchronous networking library,
1652 originally developed at FriendFeed. By using non-blocking network I/O,
1653 Tornado can scale to tens of thousands of open connections, making it ideal
1654 for long polling, WebSockets, and other applications that require a long-lived
1655 connection to each user.")
1656 (license license:asl2.0)))
1657
1658 (define-public python2-tornado
1659 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
1660 (package (inherit tornado)
1661 (propagated-inputs
1662 `(("python2-backport-ssl-match-hostname"
1663 ,python2-backport-ssl-match-hostname)
1664 ("python2-backports-abc" ,python2-backports-abc)
1665 ("python2-singledispatch" ,python2-singledispatch)
1666 ,@(package-propagated-inputs tornado))))))
1667
1668 (define-public python-tornado-http-auth
1669 (package
1670 (name "python-tornado-http-auth")
1671 (version "1.1.1")
1672 (source
1673 (origin
1674 (method url-fetch)
1675 (uri (pypi-uri "tornado-http-auth" version))
1676 (sha256
1677 (base32 "0hyc5f0a09i5yb99pk4bxpg6w9ichbrb5cv7hc9hff7rxd8w0v0x"))))
1678 (build-system python-build-system)
1679 (propagated-inputs
1680 `(("python-tornado" ,python-tornado)))
1681 (home-page "https://github.com/gvalkov/tornado-http-auth")
1682 (synopsis "Digest and basic authentication module for Tornado")
1683 (description
1684 "Provides support for adding authentication to services using the Tornado
1685 web framework, either via the basic or digest authentication schemes.")
1686 (license license:asl2.0)))
1687
1688 (define-public python-terminado
1689 (package
1690 (name "python-terminado")
1691 (version "0.8.1")
1692 (source
1693 (origin
1694 (method url-fetch)
1695 (uri (pypi-uri "terminado" version))
1696 (sha256
1697 (base32
1698 "0yh69k6579g848rmjyllb5h75pkvgcy27r1l3yzgkf33wnnzkasm"))))
1699 (build-system python-build-system)
1700 (propagated-inputs
1701 `(("python-tornado" ,python-tornado)
1702 ("python-ptyprocess" ,python-ptyprocess)))
1703 (native-inputs
1704 `(("python-nose" ,python-nose)))
1705 (arguments
1706 `(#:phases
1707 (modify-phases %standard-phases
1708 (replace 'check
1709 (lambda _ (invoke "nosetests") #t)))))
1710 (home-page "https://github.com/takluyver/terminado")
1711 (synopsis "Terminals served to term.js using Tornado websockets")
1712 (description "This package provides a Tornado websocket backend for the
1713 term.js Javascript terminal emulator library.")
1714 (license license:bsd-2)
1715 (properties `((python2-variant . ,(delay python2-terminado))))))
1716
1717 (define-public python2-terminado
1718 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
1719 (package (inherit terminado)
1720 (propagated-inputs
1721 `(("python2-backport-ssl-match-hostname"
1722 ,python2-backport-ssl-match-hostname)
1723 ("python2-futures" ,python2-futures)
1724 ,@(package-propagated-inputs terminado))))))
1725
1726 (define-public python-wsgi-intercept
1727 (package
1728 (name "python-wsgi-intercept")
1729 (version "1.2.2")
1730 (source (origin
1731 (method url-fetch)
1732 (uri (pypi-uri "wsgi_intercept" version))
1733 (sha256
1734 (base32
1735 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
1736 (build-system python-build-system)
1737 (propagated-inputs
1738 `(("python-six" ,python-six)))
1739 (native-inputs
1740 `(("python-pytest" ,python-pytest)
1741 ("python-httplib2" ,python-httplib2)
1742 ("python-requests" ,python-requests)
1743 ("python-urllib3" ,python-urllib3)))
1744 (synopsis "Puts a WSGI application in place of a real URI for testing")
1745 (description "Wsgi_intercept installs a WSGI application in place of a real
1746 URI for testing. Testing a WSGI application normally involves starting a
1747 server at a local host and port, then pointing your test code to that address.
1748 Instead, this library lets you intercept calls to any specific host/port
1749 combination and redirect them into a WSGI application importable by your test
1750 program. Thus, you can avoid spawning multiple processes or threads to test
1751 your Web app.")
1752 (home-page "https://github.com/cdent/wsgi-intercept")
1753 (license license:expat)))
1754
1755 (define-public python-webob
1756 (package
1757 (name "python-webob")
1758 (version "1.8.6")
1759 (source
1760 (origin
1761 (method url-fetch)
1762 (uri (pypi-uri "WebOb" version))
1763 (sha256
1764 (base32
1765 "026i3z99nr3px75isa9mbnky5i7rffiv4d124h5kxfjjsxz92fma"))))
1766 (build-system python-build-system)
1767 (native-inputs
1768 `(("python-nose" ,python-nose)))
1769 (home-page "https://webob.org/")
1770 (synopsis "WSGI request and response object")
1771 (description
1772 "WebOb provides wrappers around the WSGI request environment, and an
1773 object to help create WSGI responses.")
1774 (license license:expat)))
1775
1776 (define-public python2-webob
1777 (package-with-python2 python-webob))
1778
1779 (define-public python-zope-event
1780 (package
1781 (name "python-zope-event")
1782 (version "4.4")
1783 (source
1784 (origin
1785 (method url-fetch)
1786 (uri (pypi-uri "zope.event" version))
1787 (sha256
1788 (base32
1789 "1ksbc726av9xacml6jhcfyn828hlhb9xlddpx6fcvnlvmpmpvhk9"))))
1790 (build-system python-build-system)
1791 (home-page "https://pypi.org/project/zope.event/")
1792 (synopsis "Event publishing system for Python")
1793 (description "Zope.event provides an event publishing API, intended for
1794 use by applications which are unaware of any subscribers to their events. It
1795 is a simple event-dispatching system on which more sophisticated event
1796 dispatching systems can be built.")
1797 (license license:zpl2.1)))
1798
1799 (define-public python2-zope-event
1800 (package-with-python2 python-zope-event))
1801
1802 (define-public python-zope-interface
1803 (package
1804 (name "python-zope-interface")
1805 (version "5.1.0")
1806 (source
1807 (origin
1808 (method url-fetch)
1809 (uri (pypi-uri "zope.interface" version))
1810 (sha256
1811 (base32
1812 "03nrl6b8cb600dnnh46y149awvrm0gxyqgwq5hdw3lvys8mw9r20"))))
1813 (build-system python-build-system)
1814 (arguments '(#:tests? #f)) ; test suite can't find python-zope-testing
1815 (native-inputs
1816 `(("python-coverage" ,python-coverage)
1817 ("python-nose" ,python-nose)
1818 ("python-zope-event" ,python-zope-event)
1819 ("python-zope-testing" ,python-zope-testing)))
1820 (home-page "https://github.com/zopefoundation/zope.interface")
1821 (synopsis "Python implementation of the \"design by contract\"
1822 methodology")
1823 (description "Zope.interface provides an implementation of \"object
1824 interfaces\" for Python. Interfaces are a mechanism for labeling objects as
1825 conforming to a given API or contract.")
1826 (license license:zpl2.1)))
1827
1828 (define-public python2-zope-interface
1829 (package-with-python2 python-zope-interface))
1830
1831 (define-public python-zope-exceptions
1832 (package
1833 (name "python-zope-exceptions")
1834 (version "4.4")
1835 (source
1836 (origin
1837 (method url-fetch)
1838 (uri (pypi-uri "zope.exceptions" version))
1839 (sha256
1840 (base32
1841 "1nkgfwawswmyc6i0b8g3ymvja4mb507m8yhid8s4rbxq3dmqhwhd"))))
1842 (build-system python-build-system)
1843 (arguments
1844 '(#:phases
1845 (modify-phases %standard-phases
1846 (replace 'check
1847 (lambda _
1848 (invoke "zope-testrunner" "--test-path=src"))))))
1849 (native-inputs
1850 `(("python-zope-testrunner" ,python-zope-testrunner-bootstrap)))
1851 (propagated-inputs
1852 `(("python-zope-interface" ,python-zope-interface)))
1853 (home-page "https://pypi.org/project/zope.exceptions/")
1854 (synopsis "Zope exceptions")
1855 (description "Zope.exceptions provides general-purpose exception types
1856 that have uses outside of the Zope framework.")
1857 (license license:zpl2.1)))
1858
1859 (define-public python-zope-exceptions-bootstrap
1860 (package
1861 (inherit python-zope-exceptions)
1862 (arguments `(#:tests? #f))
1863 (propagated-inputs `())
1864 (native-inputs `())
1865 (properties `((hidden? . #t)))))
1866
1867 (define-public python2-zope-exceptions
1868 (package-with-python2 python-zope-exceptions))
1869
1870 (define-public python-zope-testing
1871 (package
1872 (name "python-zope-testing")
1873 (version "4.7")
1874 (source
1875 (origin
1876 (method url-fetch)
1877 (uri (pypi-uri "zope.testing" version))
1878 (sha256
1879 (base32
1880 "1sh3c3i0m8n8fnhqiry0bk3rr356i56ry7calmn57s1pvv8yhsyn"))))
1881 (build-system python-build-system)
1882 (home-page "https://pypi.org/project/zope.testing/")
1883 (synopsis "Zope testing helpers")
1884 (description "Zope.testing provides a number of testing utilities for HTML
1885 forms, HTTP servers, regular expressions, and more.")
1886 (license license:zpl2.1)))
1887
1888 (define-public python2-zope-testing
1889 (package-with-python2 python-zope-testing))
1890
1891 (define-public python-zope-testrunner
1892 (package
1893 (name "python-zope-testrunner")
1894 (version "5.2")
1895 (source
1896 (origin
1897 (method url-fetch)
1898 (uri (pypi-uri "zope.testrunner" version))
1899 (sha256
1900 (base32
1901 "0jyyf1dcz156q95x2y7yw2v420q2xn3cff0c5aci7hmdmcbn0gc7"))))
1902 (build-system python-build-system)
1903 (arguments
1904 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1905 (native-inputs
1906 `(("python-zope-testing" ,python-zope-testing)))
1907 (propagated-inputs
1908 `(("python-six" ,python-six)
1909 ("python-zope-exceptions" ,python-zope-exceptions)
1910 ("python-zope-interface" ,python-zope-interface)))
1911 (home-page "https://pypi.org/project/zope.testrunner/")
1912 (synopsis "Zope testrunner script")
1913 (description "Zope.testrunner provides a script for running Python
1914 tests.")
1915 (license license:zpl2.1)))
1916
1917 (define-public python-zope-testrunner-bootstrap
1918 (package
1919 (inherit python-zope-testrunner)
1920 (arguments `(#:tests? #f))
1921 (propagated-inputs
1922 `(("python-six" ,python-six)
1923 ("python-zope-exceptions" ,python-zope-exceptions-bootstrap)))
1924 (properties `((hidden? . #t)))))
1925
1926 (define-public python2-zope-testrunner
1927 (package-with-python2 python-zope-testrunner))
1928
1929 (define-public python-zope-i18nmessageid
1930 (package
1931 (name "python-zope-i18nmessageid")
1932 (version "5.0.1")
1933 (source
1934 (origin
1935 (method url-fetch)
1936 (uri (pypi-uri "zope.i18nmessageid" version))
1937 (sha256
1938 (base32
1939 "0ndhn4w1qgwkfbwf9vm2bgq418z5g0wmfsgl0d9nz62cd0mi8d4m"))))
1940 (build-system python-build-system)
1941 (native-inputs
1942 `(("python-coverage" ,python-coverage)
1943 ("python-zope-testrunner" ,python-zope-testrunner)))
1944 (propagated-inputs
1945 `(("python-six" ,python-six)))
1946 (home-page "https://pypi.org/project/zope.i18nmessageid/")
1947 (synopsis "Message identifiers for internationalization")
1948 (description "Zope.i18nmessageid provides facilities for declaring
1949 internationalized messages within program source text.")
1950 (license license:zpl2.1)))
1951
1952 (define-public python2-zope-i18nmessageid
1953 (package-with-python2 python-zope-i18nmessageid))
1954
1955 (define-public python-zope-schema
1956 (package
1957 (name "python-zope-schema")
1958 (version "6.0.0")
1959 (source
1960 (origin
1961 (method url-fetch)
1962 (uri (pypi-uri "zope.schema" version))
1963 (sha256
1964 (base32
1965 "09jg47bxhfg1ahr1jxb5y0cbiszyk1j6fn1r1r7s6svjl3lbryr0"))))
1966 (build-system python-build-system)
1967 (arguments
1968 `(#:phases
1969 (modify-phases %standard-phases
1970 (replace 'check
1971 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
1972 (add-installed-pythonpath inputs outputs)
1973 (if tests?
1974 (invoke "zope-testrunner" "--test-path=src")
1975 #t))))))
1976 (propagated-inputs
1977 `(("python-zope-event" ,python-zope-event)
1978 ("python-zope-interface" ,python-zope-interface)))
1979 (native-inputs
1980 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1981 ("python-zope-testing" ,python-zope-testing)
1982 ("python-zope-testrunner" ,python-zope-testrunner)))
1983 (home-page "https://pypi.org/project/zope.schema/")
1984 (synopsis "Zope data schemas")
1985 (description "Zope.scheme provides extensions to zope.interface for
1986 defining data schemas.")
1987 (license license:zpl2.1)))
1988
1989 (define-public python2-zope-schema
1990 (package-with-python2 python-zope-schema))
1991
1992 (define-public python-zope-configuration
1993 (package
1994 (name "python-zope-configuration")
1995 (version "4.4.0")
1996 (source (origin
1997 (method url-fetch)
1998 (uri (pypi-uri "zope.configuration" version))
1999 (sha256
2000 (base32
2001 "0g6vrl7y27z9cj5xyrww9xlzk4npj55mgmlrcd9d2nj08jn2pw79"))))
2002 (build-system python-build-system)
2003 (native-inputs
2004 `(("python-manuel" ,python-manuel)
2005 ("python-zope-testing" ,python-zope-testing)
2006 ("python-zope-testrunner" ,python-zope-testrunner)))
2007 (propagated-inputs
2008 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
2009 ("python-zope-interface" ,python-zope-interface)
2010 ("python-zope-schema" ,python-zope-schema)))
2011 (home-page "https://pypi.org/project/zope.configuration/")
2012 (synopsis "Zope Configuration Markup Language")
2013 (description "Zope.configuration implements ZCML, the Zope Configuration
2014 Markup Language.")
2015 (license license:zpl2.1)))
2016
2017 (define-public python-zope-configuration-bootstrap
2018 (package
2019 (inherit python-zope-configuration)
2020 (arguments `(#:tests? #f))
2021 (native-inputs `())
2022 (properties `((hidden? . #t)))))
2023
2024 (define-public python2-zope-configuration
2025 (package-with-python2 python-zope-configuration))
2026
2027 (define-public python-zope-copy
2028 (package
2029 (name "python-zope-copy")
2030 (version "4.2")
2031 (source
2032 (origin
2033 (method url-fetch)
2034 (uri (pypi-uri "zope.copy" version))
2035 (sha256
2036 (base32
2037 "06m75434krl57n6p73c2qj55k5i3fixg887j8ss01ih6zw4rvfs7"))))
2038 (build-system python-build-system)
2039 (arguments
2040 '(#:phases
2041 (modify-phases %standard-phases
2042 (replace 'check
2043 (lambda _
2044 (invoke "zope-testrunner" "--test-path=src" "\\[]"))))))
2045 (propagated-inputs
2046 `(("python-zope-interface" ,python-zope-interface)))
2047 (native-inputs
2048 `(("python-zope-component" ,python-zope-component-bootstrap)
2049 ("python-zope-location" ,python-zope-location-bootstrap)
2050 ("python-zope-testing" ,python-zope-testing)
2051 ("python-zope-testrunner" ,python-zope-testrunner)))
2052 (home-page "https://github.com/zopefoundation/zope.copy")
2053 (synopsis "Pluggable object copying mechanism")
2054 (description
2055 "This package provides a pluggable mechanism for copying persistent objects.")
2056 (license license:zpl2.1)))
2057
2058 (define-public python-zope-proxy
2059 (package
2060 (name "python-zope-proxy")
2061 (version "4.3.5")
2062 (source
2063 (origin
2064 (method url-fetch)
2065 (uri (pypi-uri "zope.proxy" version))
2066 (sha256
2067 (base32
2068 "14h7nyfbl5vpfk0rbviy4ygdfx0yx5kncvg6jpbdb0dhwna0ssm6"))))
2069 (build-system python-build-system)
2070 (native-inputs
2071 `(("python-zope-security" ,python-zope-security-bootstrap)
2072 ("python-zope-testrunner" ,python-zope-testrunner)))
2073 (propagated-inputs
2074 `(("python-zope-interface" ,python-zope-interface)))
2075 (home-page "https://pypi.org/project/zope.proxy/")
2076 (synopsis "Generic, transparent proxies")
2077 (description "Zope.proxy provides generic, transparent proxies for Python.
2078 Proxies are special objects which serve as mostly-transparent wrappers around
2079 another object, intervening in the apparent behavior of the wrapped object
2080 only when necessary to apply the policy (e.g., access checking, location
2081 brokering, etc.) for which the proxy is responsible.")
2082 (license license:zpl2.1)))
2083
2084 (define-public python-zope-proxy-bootstrap
2085 (package
2086 (inherit python-zope-proxy)
2087 (arguments `(#:tests? #f))
2088 (native-inputs `())
2089 (properties `((hidden? . #t)))))
2090
2091 (define-public python2-zope-proxy
2092 (package-with-python2 python-zope-proxy))
2093
2094 (define-public python-zope-hookable
2095 (package
2096 (name "python-zope-hookable")
2097 (version "5.0.1")
2098 (source
2099 (origin
2100 (method url-fetch)
2101 (uri (pypi-uri "zope.hookable" version))
2102 (sha256
2103 (base32
2104 "0hc82lfr7bk53nvbxvjkibkarngyrzgfk2i6bg8wshl0ly0pdl19"))))
2105 (build-system python-build-system)
2106 (native-inputs
2107 `(("python-coverage" ,python-coverage)
2108 ("python-zope-testing" ,python-zope-testing)))
2109 (home-page "https://github.com/zopefoundation/zope.hookable")
2110 (synopsis "Zope hookable")
2111 (description "This package supports the efficient creation of hookable
2112 objects, which are callable objects that are meant to be optionally replaced.
2113 The idea is that you create a function that does some default thing and make i
2114 hookable. Later, someone can modify what it does by calling its sethook method
2115 and changing its implementation. All users of the function, including those
2116 that imported it, will see the change.")
2117 (license license:zpl2.1)))
2118
2119 (define-public python-zope-location
2120 (package
2121 (name "python-zope-location")
2122 (version "4.2")
2123 (source
2124 (origin
2125 (method url-fetch)
2126 (uri (pypi-uri "zope.location" version))
2127 (sha256
2128 (base32
2129 "1b40pzl8v00d583d3gsxv1qjdw2dhghlgkbgxl3m07d5r3izj857"))))
2130 (build-system python-build-system)
2131 (arguments
2132 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
2133 (native-inputs
2134 `(("python-zope-testrunner" ,python-zope-testrunner)))
2135 (propagated-inputs
2136 `(("python-zope-interface" ,python-zope-interface)
2137 ("python-zope-proxy" ,python-zope-proxy)
2138 ("python-zope-schema" ,python-zope-schema)))
2139 (home-page "https://pypi.org/project/zope.location/")
2140 (synopsis "Zope location library")
2141 (description "Zope.location implements the concept of \"locations\" in
2142 Zope3, which are are special objects that have a structural location.")
2143 (license license:zpl2.1)))
2144
2145 (define-public python-zope-location-bootstrap
2146 (package
2147 (inherit python-zope-location)
2148 (arguments `(#:tests? #f))
2149 (native-inputs `())
2150 (properties `((hidden? . #t)))))
2151
2152 (define-public python2-zope-location
2153 (package-with-python2 python-zope-location))
2154
2155 (define-public python-zope-security
2156 (package
2157 (name "python-zope-security")
2158 (version "5.1.1")
2159 (source
2160 (origin
2161 (method url-fetch)
2162 (uri (pypi-uri "zope.security" version))
2163 (sha256
2164 (base32
2165 "11lfw67cigscfax9c5j63xcvz2qcj724zx5fcdqyc94am2glim0h"))))
2166 (build-system python-build-system)
2167 (propagated-inputs
2168 `(("python-zope-component" ,python-zope-component)
2169 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
2170 ("python-zope-interface" ,python-zope-interface)
2171 ("python-zope-location" ,python-zope-location)
2172 ("python-zope-proxy" ,python-zope-proxy)
2173 ("python-zope-schema" ,python-zope-schema)))
2174 (native-inputs
2175 `(("python-btrees" ,python-btrees)
2176 ("python-zope-component" ,python-zope-component-bootstrap)
2177 ("python-zope-configuration" ,python-zope-configuration-bootstrap)
2178 ("python-zope-location" ,python-zope-location-bootstrap)
2179 ("python-zope-testing" ,python-zope-testing)
2180 ("python-zope-testrunner" ,python-zope-testrunner)))
2181 (home-page "https://pypi.org/project/zope.security/")
2182 (synopsis "Zope security framework")
2183 (description "Zope.security provides a generic mechanism to implement
2184 security policies on Python objects.")
2185 (license license:zpl2.1)))
2186
2187 (define-public python-zope-security-bootstrap
2188 (package
2189 (inherit python-zope-security)
2190 (arguments `(#:tests? #f))
2191 (propagated-inputs
2192 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
2193 ("python-zope-interface" ,python-zope-interface)
2194 ("python-zope-proxy" ,python-zope-proxy-bootstrap)
2195 ("python-zope-schema" ,python-zope-schema)))
2196 (native-inputs `())
2197 (properties `((hidden? . #t)))))
2198
2199 (define-public python2-zope-security
2200 (package-with-python2 python-zope-security))
2201
2202 (define-public python-zope-component
2203 (package
2204 (name "python-zope-component")
2205 (version "4.6.2")
2206 (source
2207 (origin
2208 (method url-fetch)
2209 (uri (pypi-uri "zope.component" version))
2210 (sha256
2211 (base32
2212 "14iwp95hh6q5dj4k9h1iw75cbp89bs27nany4dinyglb44c8jqli"))))
2213 (build-system python-build-system)
2214 (arguments
2215 '(#:phases
2216 (modify-phases %standard-phases
2217 (replace 'check
2218 (lambda* (#:key inputs outputs #:allow-other-keys)
2219 (add-installed-pythonpath inputs outputs)
2220 (invoke "python" "setup.py" "test"))))))
2221 (native-inputs
2222 `(("python-persistent" ,python-persistent)
2223 ("python-zope-configuration" ,python-zope-configuration-bootstrap)
2224 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
2225 ("python-zope-location" ,python-zope-location-bootstrap)
2226 ("python-zope-proxy" ,python-zope-proxy-bootstrap)
2227 ("python-zope-security" ,python-zope-security-bootstrap)
2228 ("python-zope-testing" ,python-zope-testing)
2229 ("python-zope-testrunner" ,python-zope-testrunner)))
2230 (propagated-inputs
2231 `(("python-zope-deferredimport" ,python-zope-deferredimport)
2232 ("python-zope-deprecation" ,python-zope-deprecation)
2233 ("python-zope-event" ,python-zope-event)
2234 ("python-zope-hookable" ,python-zope-hookable)
2235 ("python-zope-interface" ,python-zope-interface)))
2236 (home-page "https://github.com/zopefoundation/zope.component")
2237 (synopsis "Zope Component Architecture")
2238 (description "Zope.component represents the core of the Zope Component
2239 Architecture. Together with the zope.interface package, it provides
2240 facilities for defining, registering and looking up components.")
2241 (license license:zpl2.1)))
2242
2243 (define-public python-zope-component-bootstrap
2244 (package
2245 (inherit python-zope-component)
2246 (arguments `(#:tests? #f))
2247 (native-inputs `())
2248 (properties `((hidden? . #t)))))
2249
2250 (define-public python2-zope-component
2251 (package-with-python2 python-zope-component))
2252
2253 (define-public python-zope-deferredimport
2254 (package
2255 (name "python-zope-deferredimport")
2256 (version "4.3.1")
2257 (source
2258 (origin
2259 (method url-fetch)
2260 (uri (pypi-uri "zope.deferredimport" version))
2261 (sha256
2262 (base32
2263 "1q89v54dwniiqypjbwywwdfjdr4kdkqlyqsgrpplgvsygdg39cjp"))))
2264 (build-system python-build-system)
2265 (propagated-inputs
2266 `(("python-zope-proxy" ,python-zope-proxy)))
2267 (native-inputs
2268 `(("python-zope-testrunner" ,python-zope-testrunner)))
2269 (home-page "https://github.com/zopefoundation/zope.deferredimport")
2270 (synopsis "Defer imports until used by code")
2271 (description
2272 "Often, especially for package modules, you want to import names for
2273 convenience, but not actually perform the imports until necessary. The
2274 @code{zope.deferredimport} package provided facilities for defining names in
2275 modules that will be imported from somewhere else when used. You can also cause
2276 deprecation warnings to be issued when a variable is used.")
2277 (license license:zpl2.1)))
2278
2279 (define-public python-ndg-httpsclient
2280 (package
2281 (name "python-ndg-httpsclient")
2282 (version "0.5.1")
2283 (source (origin
2284 (method url-fetch)
2285 (uri (pypi-uri "ndg_httpsclient" version))
2286 (sha256
2287 (base32
2288 "0412b7i1s4vj7lz9r72nmb28h9syd4q2x89bdirkkc3a6z8awbyp"))))
2289 (build-system python-build-system)
2290 (arguments
2291 '(;; The tests appear to require networking.
2292 #:tests? #f))
2293 (propagated-inputs
2294 `(("python-pyopenssl" ,python-pyopenssl)))
2295 (synopsis "HTTPS support for Python's httplib and urllib2")
2296 (description "This is a HTTPS client implementation for httplib and urllib2
2297 based on PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation
2298 over the default provided with Python and, importantly, enables full
2299 verification of the SSL peer.")
2300 (home-page "https://github.com/cedadev/ndg_httpsclient/")
2301 (license license:bsd-3)))
2302
2303 ;; python2-openssl requires special care, so package-with-python2 is
2304 ;; insufficient.
2305 (define-public python2-ndg-httpsclient
2306 (package (inherit python-ndg-httpsclient)
2307 (name "python2-ndg-httpsclient")
2308 (arguments
2309 (substitute-keyword-arguments (package-arguments python-ndg-httpsclient)
2310 ((#:python _) python-2)))
2311 (propagated-inputs
2312 `(("python2-pyopenssl" ,python2-pyopenssl)))))
2313
2314 (define-public python-websocket-client
2315 (package
2316 (name "python-websocket-client")
2317 (version "0.54.0")
2318 (source
2319 (origin
2320 (method url-fetch)
2321 (uri (pypi-uri "websocket_client" version))
2322 (sha256
2323 (base32
2324 "0j88zmikaypf38lvpkf4aaxrjp9j07dmy5ghj7kli0fv3p4n45g5"))))
2325 (build-system python-build-system)
2326 (propagated-inputs
2327 `(("python-six" ,python-six)))
2328 (home-page "https://github.com/liris/websocket-client")
2329 (synopsis "WebSocket client for Python")
2330 (description "The Websocket-client module provides the low level APIs for
2331 WebSocket usage in Python programs.")
2332 (properties `((python2-variant . ,(delay python2-websocket-client))))
2333 (license license:lgpl2.1+)))
2334
2335 (define-public python2-websocket-client
2336 (let ((base (package-with-python2
2337 (strip-python2-variant python-websocket-client))))
2338 (package
2339 (inherit base)
2340 (native-inputs
2341 `(("python2-backport-ssl-match-hostname"
2342 ,python2-backport-ssl-match-hostname)
2343 ,@(package-native-inputs base))))))
2344
2345 (define-public python-purl
2346 (package
2347 (name "python-purl")
2348 (version "1.5")
2349 (source
2350 (origin
2351 (method url-fetch)
2352 (uri (pypi-uri "purl" version))
2353 (sha256
2354 (base32
2355 "15ibnz1xrh5msmn04j0nr00sz4n7jwx6cwd6zlx99kkz3vpin53m"))))
2356 (build-system python-build-system)
2357 (propagated-inputs `(("python-six" ,python-six)))
2358 (home-page
2359 "https://github.com/codeinthehole/purl")
2360 (synopsis
2361 "Python package for URL manipulation")
2362 (description
2363 "Purl is a Python package for handling URLs.")
2364 (license license:expat)))
2365
2366 (define-public python-apiron
2367 (package
2368 (name "python-apiron")
2369 (version "5.1.0")
2370 (source
2371 (origin
2372 (method url-fetch)
2373 (uri (pypi-uri "apiron" version))
2374 (sha256
2375 (base32 "1qwbqn47sf0aqznj1snbv37v8ijx476qqkjf5l9pac7xjkxsr8qk"))))
2376 (build-system python-build-system)
2377 (arguments
2378 `(#:phases
2379 (modify-phases %standard-phases
2380 (replace 'check
2381 (lambda* (#:key inputs outputs #:allow-other-keys)
2382 (add-installed-pythonpath inputs outputs)
2383 (invoke "pytest" "-vv" "--cov" "-k"
2384 ;; This test tries to connect to the internet.
2385 "not test_call"))))))
2386 (propagated-inputs
2387 `(("python-requests" ,python-requests)))
2388 (native-inputs
2389 `(("python-pytest" ,python-pytest)
2390 ("python-pytest-cov" ,python-pytest-cov)))
2391 (home-page "https://github.com/ithaka/apiron")
2392 (synopsis "Python wrapper for interacting with RESTful APIs")
2393 (description
2394 "@code{apiron} provides a declarative, structured configuration of
2395 services and endpoints with a unified interface for interacting with RESTful
2396 APIs.")
2397 (license license:expat)))
2398
2399 (define-public python-beren
2400 (package
2401 (name "python-beren")
2402 (version "0.7.0")
2403 (source
2404 (origin
2405 (method url-fetch)
2406 (uri (pypi-uri "beren" version))
2407 (sha256
2408 (base32 "1v3mdwfqsyza892zvs124ym9w1bkng1j56b7l4dwfjir3723xcgf"))))
2409 (build-system python-build-system)
2410 (arguments
2411 ;; The test tries to open a connection to a remote server.
2412 `(#:tests? #f))
2413 (propagated-inputs
2414 `(("python-apiron" ,python-apiron)))
2415 (home-page "https://github.com/teffalump/beren")
2416 (synopsis "REST client for Orthanc DICOM servers")
2417 (description
2418 "@code{beren} provides a REST client for Orthanc, a DICOM server.")
2419 (license license:gpl3+)))
2420
2421 (define-public python-requests
2422 (package
2423 (name "python-requests")
2424 (version "2.25.0")
2425 (source (origin
2426 (method url-fetch)
2427 (uri (pypi-uri "requests" version))
2428 (sha256
2429 (base32
2430 "1y6mb8c0ipd64d5axq2p368yxndp3f966hmabjka2q2a5y9hn6kz"))))
2431 (build-system python-build-system)
2432 (propagated-inputs
2433 `(("python-certifi" ,python-certifi)
2434 ("python-chardet" ,python-chardet)
2435 ("python-idna" ,python-idna)
2436 ("python-urllib3" ,python-urllib3)))
2437 (arguments
2438 ;; FIXME: Some tests require network access.
2439 '(#:tests? #f))
2440 (home-page "http://python-requests.org/")
2441 (synopsis "Python HTTP library")
2442 (description
2443 "Requests is a Python HTTP client library. It aims to be easier to use
2444 than Python’s urllib2 library.")
2445 (license license:asl2.0)))
2446
2447 ;; Some software requires an older version of Requests, notably Docker/Docker
2448 ;; Compose.
2449 (define-public python-requests-2.20
2450 (package (inherit python-requests)
2451 (version "2.20.1")
2452 (source (origin
2453 (method url-fetch)
2454 (uri (pypi-uri "requests" version))
2455 (sha256
2456 (base32
2457 "0qzj6cgv3k9wyj7wlxgz7xq0cfg4jbbkfm24pp8dnhczwl31527a"))))
2458 (propagated-inputs
2459 `(("python-urllib3" ,python-urllib3-1.24)
2460 ("python-idna" ,python-idna-2.7)
2461 ,@(package-propagated-inputs python-requests)))))
2462
2463 (define-public python2-requests
2464 (package-with-python2 python-requests))
2465
2466 (define-public python-requests_ntlm
2467 (package
2468 (name "python-requests_ntlm")
2469 (version "1.1.0")
2470 (source
2471 (origin
2472 (method url-fetch)
2473 (uri (pypi-uri "requests_ntlm" version))
2474 (sha256
2475 (base32
2476 "0wgbqzaq9w7bas16b7brdb75f91bh3275fb459093bk1ihpck2ci"))))
2477 (build-system python-build-system)
2478 (propagated-inputs
2479 `(("python-cryptography" ,python-cryptography)
2480 ("python-ntlm-auth" ,python-ntlm-auth)
2481 ("python-requests" ,python-requests)))
2482 (home-page "https://github.com/requests/requests-ntlm")
2483 (synopsis
2484 "NTLM authentication support for Requests")
2485 (description
2486 "This package allows for HTTP NTLM authentication using the requests
2487 library.")
2488 (license license:isc)))
2489
2490 (define-public python-requests-mock
2491 (package
2492 (name "python-requests-mock")
2493 (version "1.8.0")
2494 (source
2495 (origin
2496 (method url-fetch)
2497 (uri (pypi-uri "requests-mock" version))
2498 (sha256
2499 (base32
2500 "09nj8fmyj7xz2mgwyvbw0fl9zybmx2d3qd2hf529vvjc9s24d3z6"))))
2501 (build-system python-build-system)
2502 (propagated-inputs
2503 `(("python-requests" ,python-requests)
2504 ("python-six" ,python-six)))
2505 (native-inputs
2506 `(("python-pbr" ,python-pbr)
2507 ("python-discover" ,python-discover)
2508 ("python-docutils" ,python-docutils)
2509 ("python-fixtures" ,python-fixtures)
2510 ("python-mock" ,python-mock)
2511 ("python-purl" ,python-purl)
2512 ("python-pytest" ,python-pytest)
2513 ("python-sphinx" ,python-sphinx)
2514 ("python-testrepository" ,python-testrepository)))
2515 (home-page "https://requests-mock.readthedocs.org/")
2516 (synopsis "Mock out responses from the requests package")
2517 (description
2518 "This module provides a building block to stub out the HTTP requests
2519 portions of your testing code.")
2520 (license license:asl2.0)))
2521
2522 (define-public python-requests-toolbelt
2523 (package
2524 (name "python-requests-toolbelt")
2525 (version "0.8.0")
2526 (source (origin
2527 (method url-fetch)
2528 (uri (pypi-uri "requests-toolbelt" version))
2529 (sha256
2530 (base32
2531 "1dc7l42i4080r8i4m9fj51jx367lqkai170vrv7wd93gdj9k39gn"))))
2532 (build-system python-build-system)
2533 (native-inputs
2534 `(("python-betamax" ,python-betamax)
2535 ("python-mock" ,python-mock)
2536 ("python-pytest" ,python-pytest)))
2537 (propagated-inputs
2538 `(("python-requests" ,python-requests)))
2539 (synopsis "Extensions to python-requests")
2540 (description "This is a toolbelt of useful classes and functions to be used
2541 with python-requests.")
2542 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
2543 (license license:asl2.0)))
2544
2545 (define-public python2-requests-toolbelt
2546 (package-with-python2 python-requests-toolbelt))
2547
2548 (define-public python-requests-toolbelt-0.9.1
2549 (package
2550 (inherit python-requests-toolbelt)
2551 (version "0.9.1")
2552 (source (origin
2553 (method url-fetch)
2554 (uri (pypi-uri "requests-toolbelt" version))
2555 (sha256
2556 (base32
2557 "1h3gm88dcjbd7gm229a7x5qkkhnsqsjz0m0l2xyavm2ab3a8k04n"))))
2558 (arguments
2559 `(;; FIXME: Some tests require network access.
2560 #:tests? #f))))
2561
2562 (define-public python-requests-ftp
2563 (package
2564 (name "python-requests-ftp")
2565 (version "0.3.1")
2566 (source
2567 (origin
2568 (method url-fetch)
2569 (uri (pypi-uri "requests-ftp" version))
2570 (sha256
2571 (base32
2572 "0yh5v21v36dsjsgv4y9dx4mmz35741l5jf6pbq9w19d8rfsww13m"))))
2573 (build-system python-build-system)
2574 (propagated-inputs
2575 `(("python-requests" ,python-requests)))
2576 (home-page
2577 "https://github.com/Lukasa/requests-ftp")
2578 (synopsis "FTP Transport Adapter for Requests")
2579 (description
2580 "Requests-FTP is an implementation of a simple FTP transport
2581 adapter for use with the Requests library.")
2582 (license license:asl2.0)))
2583
2584 (define-public python-oauthlib
2585 (package
2586 (name "python-oauthlib")
2587 (version "3.1.0")
2588 (source (origin
2589 (method url-fetch)
2590 (uri (pypi-uri "oauthlib" version))
2591 (sha256
2592 (base32
2593 "12gqnabwck30gdlpwm6af3s28qm9p2yc7b1w8s4fk9ncbz1irr5y"))))
2594 (build-system python-build-system)
2595 (arguments
2596 `(#:phases (modify-phases %standard-phases
2597 (replace 'check
2598 (lambda _
2599 (invoke "pytest" "-vv"))))))
2600 (native-inputs
2601 `(("python-pytest" ,python-pytest)
2602 ("python-pytest-cov" ,python-pytest-cov)
2603 ("python-mock" ,python-mock)))
2604 (propagated-inputs
2605 `(("python-cryptography" ,python-cryptography)
2606 ("python-pyjwt" ,python-pyjwt)
2607 ("python-blinker" ,python-blinker)))
2608 (home-page "https://github.com/oauthlib/oauthlib")
2609 (synopsis "OAuth implementation for Python")
2610 (description
2611 "Oauthlib is a generic, spec-compliant, thorough implementation of the
2612 OAuth request-signing logic.")
2613 (license license:bsd-3)))
2614
2615 (define-public python2-oauthlib
2616 (package-with-python2 python-oauthlib))
2617
2618 (define-public python-rauth
2619 (package
2620 (name "python-rauth")
2621 (version "0.7.3")
2622 (source
2623 (origin
2624 (method url-fetch)
2625 (uri (pypi-uri "rauth" version))
2626 (sha256
2627 (base32
2628 "02kv8w8l98ky223avyq7vw7x1f2ya9chrm59r77ylq45qb0xnk2j"))))
2629 (build-system python-build-system)
2630 (arguments
2631 `(#:test-target "check"))
2632 (propagated-inputs
2633 `(("python-requests" ,python-requests)))
2634 (home-page "https://github.com/litl/rauth")
2635 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
2636 (description
2637 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
2638 provides service wrappers for convenient connection initialization and
2639 authenticated session objects providing things like keep-alive.")
2640 (license license:expat)
2641 (properties `((python2-variant . ,(delay python2-rauth))))))
2642
2643 (define-public python2-rauth
2644 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
2645 (package
2646 (inherit base)
2647 (native-inputs `(("python2-unittest2" ,python2-unittest2)
2648 ,@(package-native-inputs base))))))
2649
2650 (define-public python-urllib3
2651 (package
2652 (name "python-urllib3")
2653 (version "1.26.2")
2654 (source
2655 (origin
2656 (method url-fetch)
2657 (uri (pypi-uri "urllib3" version))
2658 (sha256
2659 (base32
2660 "024yldjwjavps39yb77sc422z8fa9bn20wcqrcncjwrqjab8y60r"))))
2661 (build-system python-build-system)
2662 (arguments `(#:tests? #f))
2663 (propagated-inputs
2664 `(;; These 5 inputs are used to build urrlib3[secure]
2665 ("python-certifi" ,python-certifi)
2666 ("python-cryptography" ,python-cryptography)
2667 ("python-idna" ,python-idna)
2668 ("python-pyopenssl" ,python-pyopenssl)
2669 ("python-pysocks" ,python-pysocks)))
2670 (home-page "https://urllib3.readthedocs.io/")
2671 (synopsis "HTTP library with thread-safe connection pooling")
2672 (description
2673 "Urllib3 supports features left out of urllib and urllib2 libraries. It
2674 can reuse the same socket connection for multiple requests, it can POST files,
2675 supports url redirection and retries, and also gzip and deflate decoding.")
2676 (properties `((python2-variant . ,(delay python2-urllib3))))
2677 (license license:expat)))
2678
2679 ;; Some software requires an older version of urllib3, notably Docker.
2680 (define-public python-urllib3-1.24
2681 (package (inherit python-urllib3)
2682 (version "1.24.3")
2683 (source (origin
2684 (method url-fetch)
2685 (uri (pypi-uri "urllib3" version))
2686 (sha256
2687 (base32
2688 "1x0slqrv6kixkbcdnxbglvjliwhc1payavxjvk8fvbqjrnasd4r3"))))))
2689
2690
2691 (define-public python2-urllib3
2692 (let ((base (package-with-python2 (strip-python2-variant python-urllib3))))
2693 (package/inherit
2694 base
2695 (propagated-inputs
2696 `(("python-ipaddress" ,python2-ipaddress)
2697 ,@(package-propagated-inputs base))))))
2698
2699 (define-public awscli
2700 (package
2701 ;; Note: updating awscli typically requires updating botocore as well.
2702 (name "awscli")
2703 (version "1.18.203")
2704 (source
2705 (origin
2706 (method url-fetch)
2707 (uri (pypi-uri name version))
2708 (sha256
2709 (base32
2710 "128zg24961j8nmnq2dxqg6a7zwh3qgv87cmvclsdqwwih9nigxv9"))))
2711 (build-system python-build-system)
2712 (arguments
2713 ;; FIXME: The 'pypi' release does not contain tests.
2714 '(#:tests? #f
2715 #:phases
2716 (modify-phases %standard-phases
2717 (add-after 'unpack 'fix-reference-to-groff
2718 (lambda _
2719 (substitute* "awscli/help.py"
2720 (("if not self._exists_on_path\\('groff'\\):") "")
2721 (("raise ExecutableNotFoundError\\('groff'\\)") "")
2722 (("cmdline = \\['groff'")
2723 (string-append "cmdline = ['" (which "groff") "'")))
2724 #t)))))
2725 (propagated-inputs
2726 `(("python-colorama" ,python-colorama)
2727 ("python-botocore" ,python-botocore)
2728 ("python-s3transfer" ,python-s3transfer)
2729 ("python-docutils" ,python-docutils)
2730 ("python-pyyaml" ,python-pyyaml)
2731 ("python-rsa" ,python-rsa)))
2732 (native-inputs
2733 `(("groff" ,groff)))
2734 (home-page "https://aws.amazon.com/cli/")
2735 (synopsis "Command line client for AWS")
2736 (description "AWS CLI provides a unified command line interface to the
2737 Amazon Web Services (AWS) API.")
2738 (license license:asl2.0)))
2739
2740 (define-public python-wsgiproxy2
2741 (package
2742 (name "python-wsgiproxy2")
2743 (version "0.4.6")
2744 (source
2745 (origin
2746 (method url-fetch)
2747 (uri (pypi-uri "WSGIProxy2" version ".tar.gz"))
2748 (sha256
2749 (base32 "16jch5nic0hia28lps3c678s9s9mjdq8n87igxncjg0rpi5adqnf"))))
2750 (build-system python-build-system)
2751 (native-inputs
2752 `(("python-webtest" ,python-webtest)))
2753 (propagated-inputs
2754 `(("python-requests" ,python-requests)
2755 ("python-six" ,python-six)
2756 ("python-urllib3" ,python-urllib3)
2757 ("python-webob" ,python-webob)))
2758 (home-page "https://github.com/gawel/WSGIProxy2/")
2759 (synopsis "WSGI Proxy with various http client backends")
2760 (description "WSGI turns HTTP requests into WSGI function calls.
2761 WSGIProxy turns WSGI function calls into HTTP requests.
2762 It also includes code to sign requests and pass private data,
2763 and to spawn subprocesses to handle requests.")
2764 (license license:expat)))
2765
2766 (define-public python2-wsgiproxy2
2767 (package-with-python2 python-wsgiproxy2))
2768
2769 (define-public python-pastedeploy
2770 (package
2771 (name "python-pastedeploy")
2772 (version "2.1.1")
2773 (source
2774 (origin
2775 (method url-fetch)
2776 (uri (pypi-uri "PasteDeploy" version))
2777 (sha256
2778 (base32 "05s88qdjdwd9d9qs13fap7nqgxs7qs5qfzzjbrc5va13k2mxdskd"))))
2779 (build-system python-build-system)
2780 (arguments
2781 '(#:test-target "pytest"))
2782 (native-inputs
2783 `(("python-pytest" ,python-pytest)
2784 ("python-pytest-runner" ,python-pytest-runner)))
2785 (home-page "https://pylonsproject.org/")
2786 (synopsis
2787 "Load, configure, and compose WSGI applications and servers")
2788 (description
2789 "This tool provides code to load WSGI applications and servers from URIs;
2790 these URIs can refer to Python Eggs for INI-style configuration files. Paste
2791 Script provides commands to serve applications based on this configuration
2792 file.")
2793 (license license:expat)))
2794
2795 (define-public python2-pastedeploy
2796 (package-with-python2 python-pastedeploy))
2797
2798 (define-public python-webtest
2799 (package
2800 (name "python-webtest")
2801 (version "2.0.33")
2802 (source
2803 (origin
2804 (method url-fetch)
2805 (uri (pypi-uri "WebTest" version))
2806 (sha256
2807 (base32
2808 "1l3z0cwqslsf4rcrhi2gr8kdfh74wn2dw76376i4g9i38gz8wd21"))))
2809 (build-system python-build-system)
2810 (arguments
2811 ;; Tests require python-pyquery, which creates a circular dependency.
2812 `(#:tests? #f))
2813 (propagated-inputs
2814 `(("python-waitress" ,python-waitress)
2815 ("python-webob" ,python-webob)
2816 ("python-six" ,python-six)
2817 ("python-beautifulsoup4" ,python-beautifulsoup4)))
2818 (home-page "https://docs.pylonsproject.org/projects/webtest/")
2819 (synopsis "Helper to test WSGI applications")
2820 (description "Webtest allows you to test your Python web applications
2821 without starting an HTTP server. It supports anything that supports the
2822 minimum of WSGI.")
2823 (license license:expat)))
2824
2825 (define-public python2-webtest
2826 (package-with-python2 python-webtest))
2827
2828 (define-public python-flask
2829 (package
2830 (name "python-flask")
2831 (version "1.1.2")
2832 (source (origin
2833 (method url-fetch)
2834 (uri (pypi-uri "Flask" version))
2835 (sha256
2836 (base32
2837 "0q3h295izcil7lswkzfnyg3k5gq4hpmqmpl6i7s5m1n9szi1myjf"))))
2838 (build-system python-build-system)
2839 (arguments
2840 '(#:phases
2841 (modify-phases %standard-phases
2842 (replace 'check
2843 (lambda _
2844 (setenv "PYTHONPATH" (string-append "./build/lib:"
2845 (getenv "PYTHONPATH")))
2846 (invoke "pytest" "-vv" "tests"))))))
2847 (native-inputs
2848 `(("python-pytest" ,python-pytest)))
2849 (propagated-inputs
2850 `(("python-itsdangerous" ,python-itsdangerous)
2851 ("python-jinja2" ,python-jinja2)
2852 ("python-click" ,python-click)
2853 ("python-werkzeug" ,python-werkzeug)))
2854 (home-page "https://www.palletsprojects.com/p/flask/")
2855 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
2856 (description "Flask is a micro web framework based on the Werkzeug toolkit
2857 and Jinja2 template engine. It is called a micro framework because it does not
2858 presume or force a developer to use a particular tool or library.")
2859 (license license:bsd-3)))
2860
2861 (define-public python2-flask
2862 (package-with-python2 python-flask))
2863
2864 (define-public python-flask-wtf
2865 (package
2866 (name "python-flask-wtf")
2867 (version "0.14.3")
2868 (source
2869 (origin
2870 (method url-fetch)
2871 (uri (pypi-uri "Flask-WTF" version))
2872 (sha256
2873 (base32
2874 "086pvg2x69n0nczcq7frknfjd8am1zdy8qqpva1sanwb02hf65yl"))))
2875 (build-system python-build-system)
2876 (arguments
2877 '(#:phases
2878 (modify-phases %standard-phases
2879 (replace 'check
2880 (lambda _
2881 (setenv "PYTHONPATH" (string-append "./build/lib:"
2882 (getenv "PYTHONPATH")))
2883 (invoke "pytest" "-vv"))))))
2884 (propagated-inputs
2885 `(("python-flask-babel" ,python-flask-babel)
2886 ("python-babel" ,python-babel)
2887 ("python-wtforms" ,python-wtforms)))
2888 (native-inputs
2889 `(("python-pytest" ,python-pytest)))
2890 (home-page "https://github.com/lepture/flask-wtf")
2891 (synopsis "Simple integration of Flask and WTForms")
2892 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
2893 upload, and reCAPTCHA.")
2894 (license license:bsd-3)))
2895
2896 (define-public python2-flask-wtf
2897 (package-with-python2 python-flask-wtf))
2898
2899 (define-public python-flask-multistatic
2900 (package
2901 (name "python-flask-multistatic")
2902 (version "1.0")
2903 (source
2904 (origin
2905 (method url-fetch)
2906 (uri (pypi-uri "flask-multistatic" version))
2907 (sha256
2908 (base32
2909 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
2910 (build-system python-build-system)
2911 (propagated-inputs
2912 `(("python-flask" ,python-flask)))
2913 (home-page "https://pagure.io/flask-multistatic")
2914 (synopsis "Flask plugin to allow overriding static files")
2915 (description "@code{flask-multistatic} is a flask plugin that adds support
2916 for overriding static files.")
2917 (license license:gpl3+)))
2918
2919 (define-public python2-flask-multistatic
2920 (package-with-python2 python-flask-multistatic))
2921
2922 (define-public python-cookies
2923 (package
2924 (name "python-cookies")
2925 (version "2.2.1")
2926 (source (origin
2927 (method url-fetch)
2928 (uri (pypi-uri "cookies" version))
2929 (sha256
2930 (base32
2931 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
2932 (build-system python-build-system)
2933 (arguments
2934 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
2935 #:tests? #f))
2936 (native-inputs
2937 `(("python-pytest" ,python-pytest)))
2938 (synopsis "HTTP cookie parser and renderer")
2939 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
2940 Python.")
2941 (home-page "https://gitlab.com/sashahart/cookies")
2942 (license license:expat)))
2943
2944 (define-public python2-cookies
2945 (package-with-python2 python-cookies))
2946
2947 (define-public python-responses
2948 (package
2949 (name "python-responses")
2950 (version "0.10.6")
2951 (source (origin
2952 (method url-fetch)
2953 (uri (pypi-uri "responses" version))
2954 (sha256
2955 (base32
2956 "147pacwkkqy3qf3hr33fnl1xbzgw0zsm3qppvvy9qhq8h069qbah"))))
2957 (build-system python-build-system)
2958 (arguments
2959 `(;; Test suite is not distributed:
2960 ;; https://github.com/getsentry/responses/issues/38
2961 #:tests? #f))
2962 (native-inputs
2963 `(("python-mock" ,python-mock)))
2964 (propagated-inputs
2965 `(("python-requests" ,python-requests)
2966 ("python-cookies" ,python-cookies)
2967 ("python-six" ,python-six)))
2968 (home-page "https://github.com/getsentry/responses")
2969 (synopsis "Utility for mocking out the `requests` Python library")
2970 (description "A utility library for mocking out the `requests` Python
2971 library.")
2972 (license license:asl2.0)))
2973
2974 (define-public python2-responses
2975 (package-with-python2 python-responses))
2976
2977 (define-public python-grequests
2978 (package
2979 (name "python-grequests")
2980 (version "0.3.0")
2981 (source
2982 (origin
2983 (method url-fetch)
2984 (uri (pypi-uri "grequests" version))
2985 (sha256
2986 (base32
2987 "1j9icncllbkv7x5719b20mx670c6q1jrdx1sakskkarvx3pc8h8g"))))
2988 (build-system python-build-system)
2989 (propagated-inputs
2990 `(("python-gevent" ,python-gevent)
2991 ("python-requests" ,python-requests)))
2992 (native-inputs
2993 `(("python-nose" ,python-nose)
2994 ("python-zope.interface" ,python-zope-interface)
2995 ("python-zope.event" ,python-zope-event)))
2996 (home-page "https://github.com/kennethreitz/grequests")
2997 (synopsis "Python library for asynchronous HTTP requests")
2998 (description "GRequests is a Python library that allows you to use
2999 @code{Requests} with @code{Gevent} to make asynchronous HTTP Requests easily")
3000 (license license:bsd-2)))
3001
3002 (define-public python-dpkt
3003 (package
3004 (name "python-dpkt")
3005 (version "1.9.4")
3006 (source
3007 (origin
3008 (method url-fetch)
3009 (uri (pypi-uri "dpkt" version))
3010 (sha256
3011 (base32
3012 "1d28r8pmhzjjd6hrn1xcddinfhwv8lcl1s59ygmqa8kfmz5pkrgl"))))
3013 (build-system python-build-system)
3014 (home-page "https://github.com/kbandla/dpkt")
3015 (synopsis "Packet generator and parser for TCP/IP protocols")
3016 (description "The dpkt module is a fast, simple packet generator and parser
3017 for the basic TCP/IP protocols.")
3018 (license license:bsd-3)))
3019
3020 (define-public python-geventhttpclient
3021 (package
3022 (name "python-geventhttpclient")
3023 (version "1.4.4")
3024 (source (origin
3025 (method url-fetch)
3026 (uri (pypi-uri "geventhttpclient" version))
3027 (sha256
3028 (base32
3029 "1hy4qm9d3r69n5199i7qjji1v7718n7cxbj8ggi0njify99m37pm"))
3030 (modules '((guix build utils)))
3031 (snippet
3032 '(begin
3033 ;; Delete pre-compiled files.
3034 (for-each delete-file (find-files "src/geventhttpclient"
3035 ".*\\.pyc"))))))
3036 (build-system python-build-system)
3037 (arguments
3038 '(#:phases
3039 (modify-phases %standard-phases
3040 (add-after 'unpack 'delete-network-tests
3041 (lambda _
3042 (delete-file "src/geventhttpclient/tests/test_client.py")))
3043 (add-after 'unpack 'fix-compatibility-issue
3044 ;; See: https://github.com/gwik/geventhttpclient/issues/137.
3045 (lambda _
3046 (substitute* "src/geventhttpclient/tests/test_ssl.py"
3047 ((".*sock.last_seen_sni = None.*")
3048 ""))))
3049 (replace 'check
3050 (lambda* (#:key inputs outputs #:allow-other-keys)
3051 (add-installed-pythonpath inputs outputs)
3052 (invoke "py.test" "src/geventhttpclient/tests" "-v"
3053 ;; Append the test modules to sys.path to avoid
3054 ;; namespace conflict which breaks SSL tests.
3055 "--import-mode=append"
3056 ;; XXX: This test fails with Python 3.8:
3057 ;; https://github.com/gwik/geventhttpclient/issues/119
3058 "-k" "not test_cookielib_compatibility"))))))
3059 (native-inputs
3060 `(("python-dpkt" ,python-dpkt)
3061 ("python-pytest" ,python-pytest)))
3062 (propagated-inputs
3063 `(("python-certifi" ,python-certifi)
3064 ("python-gevent" ,python-gevent)
3065 ("python-six" ,python-six)))
3066 (home-page "https://github.com/gwik/geventhttpclient")
3067 (synopsis "HTTP client library for gevent")
3068 (description "@code{python-geventhttpclient} is a high performance,
3069 concurrent HTTP client library for python using @code{gevent}.")
3070 (license license:expat)))
3071
3072 (define-public python-requests-oauthlib
3073 (package
3074 (name "python-requests-oauthlib")
3075 (version "1.2.0")
3076 (source
3077 (origin
3078 (method url-fetch)
3079 (uri (pypi-uri "requests-oauthlib" version))
3080 (sha256
3081 (base32
3082 "0mrglgcvq7k48pf27s4gifdk0za8xmgpf55jy15yjj471qrk6rdx"))))
3083 (build-system python-build-system)
3084 (arguments
3085 `(#:phases
3086 (modify-phases %standard-phases
3087 ;; removes tests that require network access
3088 (add-before 'check 'pre-check
3089 (lambda _
3090 (delete-file "tests/test_core.py")
3091 #t)))))
3092 (native-inputs
3093 `(("python-pyjwt" ,python-pyjwt)
3094 ("python-requests-mock" ,python-requests-mock)
3095 ("python-mock" ,python-mock)))
3096 (propagated-inputs
3097 `(("python-oauthlib" ,python-oauthlib)
3098 ("python-requests" ,python-requests)))
3099 (home-page
3100 "https://github.com/requests/requests-oauthlib")
3101 (synopsis
3102 "OAuthlib authentication support for Requests")
3103 (description
3104 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
3105 provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
3106 (license license:isc)))
3107
3108 (define-public python-url
3109 (package
3110 (name "python-url")
3111 (version "0.2.0")
3112 (source (origin
3113 (method url-fetch)
3114 (uri (pypi-uri "url" version))
3115 (sha256
3116 (base32
3117 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
3118 (build-system python-build-system)
3119 (propagated-inputs
3120 `(("python-publicsuffix" ,python-publicsuffix)))
3121 (native-inputs
3122 `(("python-coverage" ,python-coverage)
3123 ("python-nose" ,python-nose)))
3124 (arguments
3125 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
3126 (home-page "https://github.com/seomoz/url-py")
3127 (synopsis "URL Parsing")
3128 (description "Library for parsing urls.")
3129 (license license:expat)
3130 (properties `((python2-variant . ,(delay python2-url))))))
3131
3132 (define-public python2-url
3133 (let ((base (package-with-python2 (strip-python2-variant python-url))))
3134 (package (inherit base)
3135 (propagated-inputs
3136 `(("python2-publicsuffix" ,python2-publicsuffix))))))
3137
3138 (define-public python-cachecontrol
3139 (package
3140 (name "python-cachecontrol")
3141 (version "0.12.5")
3142 (source
3143 (origin
3144 (method git-fetch)
3145 ;; Pypi does not have tests.
3146 (uri (git-reference
3147 (url "https://github.com/ionrock/cachecontrol")
3148 (commit (string-append "v" version))))
3149 (file-name (git-file-name name version))
3150 (sha256
3151 (base32
3152 "03lgc65sl04n0cgzmmgg99bk83f9i6k8yrmcd4hpl46q1pymn0kz"))))
3153 (build-system python-build-system)
3154 (arguments
3155 ;; Versions > 0.11.6 depend on CherryPy for testing.
3156 ;; It's too much work to package CherryPy for now.
3157 `(#:tests? #f))
3158 (propagated-inputs
3159 `(("python-requests" ,python-requests)
3160 ("python-msgpack" ,python-msgpack)
3161 ("python-lockfile" ,python-lockfile)))
3162 (home-page "https://github.com/ionrock/cachecontrol")
3163 (synopsis "The httplib2 caching algorithms for use with requests")
3164 (description "CacheControl is a port of the caching algorithms in
3165 @code{httplib2} for use with @code{requests} session objects.")
3166 (license license:asl2.0)))
3167
3168 (define-public python-cachecontrol-0.11
3169 (package
3170 (inherit python-cachecontrol)
3171 (name "python-cachecontrol")
3172 (version "0.11.7")
3173 (source
3174 (origin
3175 (method url-fetch)
3176 (uri (pypi-uri "CacheControl" version))
3177 (sha256
3178 (base32
3179 "07jsfhlbcwgqg6ayz8nznzaqg5rmxqblbzxz1qvg5wc44pcjjy4g"))))))
3180
3181 (define-public python-betamax
3182 (package
3183 (name "python-betamax")
3184 (version "0.8.1")
3185 (source
3186 (origin
3187 (method url-fetch)
3188 (uri (pypi-uri "betamax" version))
3189 (sha256
3190 (base32
3191 "1hki1c2vs7adq7zr56wi6i5bhrkia4s2ywpv2c98ibnczz709w2v"))))
3192 (build-system python-build-system)
3193 (arguments
3194 '(;; Many tests fail because they require networking.
3195 #:tests? #f))
3196 (propagated-inputs
3197 `(("python-requests" ,python-requests)))
3198 (home-page "https://github.com/sigmavirus24/betamax")
3199 (synopsis "Record HTTP interactions with python-requests")
3200 (description "Betamax will record your test suite's HTTP interactions and
3201 replay them during future tests. It is designed to work with python-requests.")
3202 (license license:expat)))
3203
3204 (define-public python2-betamax
3205 (package-with-python2 python-betamax))
3206
3207 (define-public python-betamax-matchers
3208 (package
3209 (name "python-betamax-matchers")
3210 (version "0.4.0")
3211 (source
3212 (origin
3213 (method url-fetch)
3214 (uri (pypi-uri "betamax-matchers" version))
3215 (sha256
3216 (base32
3217 "07qpwjyq2i2aqhz5iwghnj4pqr2ys5n45v1vmpcfx9r5mhwrsq43"))))
3218 (build-system python-build-system)
3219 (propagated-inputs
3220 `(("python-betamax" ,python-betamax)
3221 ("python-requests-toolbelt" ,python-requests-toolbelt)))
3222 (home-page "https://github.com/sigmavirus24/betamax_matchers")
3223 (synopsis "VCR imitation for python-requests")
3224 (description "@code{betamax-matchers} provides a set of Matchers for
3225 Betamax.")
3226 (license license:asl2.0)))
3227
3228 (define-public python2-betamax-matchers
3229 (package-with-python2 python-betamax-matchers))
3230
3231 (define-public python-s3transfer
3232 (package
3233 (name "python-s3transfer")
3234 (version "0.3.3")
3235 (source (origin
3236 (method url-fetch)
3237 (uri (pypi-uri "s3transfer" version))
3238 (sha256
3239 (base32
3240 "1nzp5kwmy9669334shcz9ipg89jgpdqhrmbkgdg18r7wmvi3f6lj"))))
3241 (build-system python-build-system)
3242 (arguments
3243 `(#:phases
3244 (modify-phases %standard-phases
3245 (add-after 'unpack 'patch
3246 (lambda _
3247 ;; There's a small issue with one test with Python 3.8, this
3248 ;; change has been suggested upstream:
3249 ;; https://github.com/boto/s3transfer/pull/164
3250 (substitute* "tests/unit/test_s3transfer.py"
3251 (("super\\(FailedDownloadParts, self\\)\\.submit\\(function\\)")
3252 "futures.Future()"))
3253 #t))
3254 (replace 'check
3255 (lambda _
3256 ;; Some of the 'integration' tests require network access or
3257 ;; login credentials.
3258 (invoke "nosetests" "--exclude=integration")
3259 #t)))))
3260 (native-inputs
3261 `(("python-docutils" ,python-docutils)
3262 ("python-mock" ,python-mock)
3263 ("python-nose" ,python-nose)))
3264 (propagated-inputs
3265 `(("python-botocore" ,python-botocore)
3266 ("python-urllib3" ,python-urllib3)))
3267 (synopsis "Amazon S3 Transfer Manager")
3268 (description "S3transfer is a Python library for managing Amazon S3
3269 transfers.")
3270 (home-page "https://github.com/boto/s3transfer")
3271 (license license:asl2.0)
3272 (properties `((python2-variant . ,(delay python2-s3transfer))))))
3273
3274 (define-public python2-s3transfer
3275 (let ((base (package-with-python2 (strip-python2-variant python-s3transfer))))
3276 (package
3277 (inherit base)
3278 (native-inputs
3279 `(("python2-futures" ,python2-futures)
3280 ,@(package-native-inputs base))))))
3281
3282 (define-public python-slimit
3283 (package
3284 (name "python-slimit")
3285 (version "0.8.1")
3286 (source
3287 (origin
3288 (method url-fetch)
3289 (uri (pypi-uri "slimit" version ".zip"))
3290 (sha256
3291 (base32
3292 "02vj2x728rs1127q2nc27frrqra4fczivnb7gch6n5lzi7pxqczl"))))
3293 (build-system python-build-system)
3294 (native-inputs
3295 `(("unzip" ,unzip)))
3296 (propagated-inputs
3297 `(("python-ply" ,python-ply)))
3298 (home-page "https://slimit.readthedocs.io/")
3299 (synopsis "JavaScript minifier, parser and lexer written in Python")
3300 (description
3301 "SlimIt is a JavaScript minifier written in Python. It compiles
3302 JavaScript into more compact code so that it downloads and runs faster.
3303 SlimIt also provides a library that includes a JavaScript parser, lexer,
3304 pretty printer and a tree visitor.")
3305 (license license:expat)))
3306
3307 (define-public python-flask-restful
3308 (package
3309 (name "python-flask-restful")
3310 (version "0.3.8")
3311 (source
3312 (origin
3313 (method url-fetch)
3314 (uri (pypi-uri "Flask-RESTful" version))
3315 (patches (search-patches "python-flask-restful-werkzeug-compat.patch"))
3316 (sha256
3317 (base32
3318 "05b9lzx5yc3wgml2bcq50lq35h66m8zpj6dc9advcb5z3acsbaay"))))
3319 (build-system python-build-system)
3320 (propagated-inputs
3321 `(("python-aniso8601" ,python-aniso8601)
3322 ("python-flask" ,python-flask)
3323 ("python-pycrypto" ,python-pycrypto)
3324 ("python-pytz" ,python-pytz)))
3325 (native-inputs
3326 `(;; Optional dependency of Flask. Tests need it.
3327 ("python-blinker" ,python-blinker)
3328 ("python-mock" ,python-mock) ; For tests
3329 ("python-nose" ,python-nose))) ;for tests
3330 (home-page
3331 "https://www.github.com/flask-restful/flask-restful/")
3332 (synopsis
3333 "Flask module for creating REST APIs")
3334 (description
3335 "This package contains a Flask module for creating REST APIs.")
3336 (license license:bsd-3)))
3337
3338 (define-public python-flask-basicauth
3339 (package
3340 (name "python-flask-basicauth")
3341 (version "0.2.0")
3342 (source
3343 (origin
3344 (method url-fetch)
3345 (uri (pypi-uri "Flask-BasicAuth" version))
3346 (sha256
3347 (base32
3348 "1zq1spkjr4sjdnalpp8wl242kdqyk6fhbnhr8hi4r4f0km4bspnz"))))
3349 (build-system python-build-system)
3350 (arguments
3351 `(#:phases (modify-phases %standard-phases
3352 (add-after 'unpack 'fix-imports
3353 (lambda _
3354 (substitute* '("docs/index.rst"
3355 "docs/conf.py"
3356 "flask_basicauth.py"
3357 "test_basicauth.py")
3358 (("flask\\.ext\\.basicauth")
3359 "flask_basicauth"))
3360 #t)))))
3361 (propagated-inputs
3362 `(("python-flask" ,python-flask)))
3363 (home-page "https://github.com/jpvanhal/flask-basicauth")
3364 (synopsis "HTTP basic access authentication for Flask")
3365 (description
3366 "This package provides HTTP basic access authentication for Flask.")
3367 (license license:bsd-3)))
3368
3369 (define-public python-flask-htpasswd
3370 (package
3371 (name "python-flask-htpasswd")
3372 (version "0.3.1")
3373 (source
3374 (origin
3375 (method url-fetch)
3376 (uri (pypi-uri "flask-htpasswd" version))
3377 (sha256
3378 (base32
3379 "14q1y1y9i9bhabdnwd25jqzc4ljli23smxfyyh8abxz1vq93pxra"))))
3380 (build-system python-build-system)
3381 (propagated-inputs
3382 `(("python-flask" ,python-flask)
3383 ("python-itsdangerous" ,python-itsdangerous)
3384 ("python-passlib" ,python-passlib)
3385 ("python-tox" ,python-tox)))
3386 (home-page "https://github.com/carsongee/flask-htpasswd")
3387 (synopsis "Basic authentication via htpasswd files in Flask applications")
3388 (description "This package provides Basic authentication via
3389 @file{htpasswd} files and access_token authentication in Flask
3390 applications.")
3391 (license license:bsd-3)))
3392
3393 (define-public python-flask-sqlalchemy
3394 (package
3395 (name "python-flask-sqlalchemy")
3396 (version "2.4.4")
3397 (source (origin
3398 (method url-fetch)
3399 (uri (pypi-uri "Flask-SQLAlchemy" version))
3400 (sha256
3401 (base32
3402 "1rgsj49gnx361hnb3vn6c1h17497qh22yc3r70l1r6w0mw71bixz"))))
3403 (build-system python-build-system)
3404 (propagated-inputs
3405 `(("python-flask" ,python-flask)
3406 ("python-sqlalchemy" ,python-sqlalchemy)))
3407 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
3408 (synopsis "Module adding SQLAlchemy support to your Flask application")
3409 (description
3410 "This package adds SQLAlchemy support to your Flask application.")
3411 (license license:bsd-3)))
3412
3413 (define-public python-flask-restplus
3414 (package
3415 (name "python-flask-restplus")
3416 (version "0.9.2")
3417 (source
3418 (origin
3419 (method url-fetch)
3420 (uri (pypi-uri "flask-restplus" version))
3421 (sha256
3422 (base32
3423 "11his6ii5brpkhld0d5bwzjjw4q3vmplpd6fmgzjrvvklsbk0cf4"))))
3424 (build-system python-build-system)
3425 (arguments
3426 '(#:tests? #f)) ; FIXME: 35/882 tests failing.
3427 ;; #:phases
3428 ;; (modify-phases %standard-phases
3429 ;; (replace 'check
3430 ;; (lambda _
3431 ;; (invoke "nosetests")
3432 ;; #t)))))
3433 (propagated-inputs
3434 `(("python-aniso8601" ,python-aniso8601)
3435 ("python-flask" ,python-flask)
3436 ("python-jsonschema" ,python-jsonschema)
3437 ("python-pytz" ,python-pytz)
3438 ("python-six" ,python-six)))
3439 (native-inputs
3440 `(("python-tzlocal" ,python-tzlocal)
3441 ("python-blinker" ,python-blinker)
3442 ("python-nose" ,python-nose)
3443 ("python-rednose" ,python-rednose)))
3444 (home-page "https://github.com/noirbizarre/flask-restplus")
3445 (synopsis "Framework for documented API development with Flask")
3446 (description "This package provides a framework for API development with
3447 the Flask web framework in Python. It is similar to package
3448 @code{python-flask-restful} but supports the @code{python-swagger}
3449 documentation builder.")
3450 (license license:expat)))
3451
3452 (define-public python-flask-restful-swagger
3453 (package
3454 (name "python-flask-restful-swagger")
3455 (version "0.20.1")
3456 (source
3457 (origin
3458 (method url-fetch)
3459 (uri (pypi-uri "flask-restful-swagger" version))
3460 (sha256
3461 (base32
3462 "1p66f98b5zpypnnz56pxpbirchqj6aniw6qyrp8h572l0dn9xlvq"))))
3463 (build-system python-build-system)
3464 (arguments '(#:tests? #f)) ;no tests
3465 (propagated-inputs
3466 `(("python-flask-restful" ,python-flask-restful)))
3467 (home-page "https://github.com/rantav/flask-restful-swagger")
3468 (synopsis "Extract Swagger specs from Flask-Restful projects")
3469 (description "This package lets you extract Swagger API documentation
3470 specs from your Flask-Restful projects.")
3471 (license license:expat)))
3472
3473 (define-public python-htmlmin
3474 (package
3475 (name "python-htmlmin")
3476 (version "0.1.12")
3477 (source
3478 (origin
3479 (method url-fetch)
3480 (uri (pypi-uri "htmlmin" version))
3481 (sha256
3482 (base32
3483 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
3484 (arguments
3485 `(#:tests? #f)) ; no tests
3486 (build-system python-build-system)
3487 (home-page "https://htmlmin.readthedocs.org/en/latest/")
3488 (synopsis "HTML minifier")
3489 (description "@code{htmlmin} is an HTML minifier that just works.
3490 It comes with safe defaults and easily configurable options.")
3491 (license license:bsd-3)))
3492
3493 (define-public python2-htmlmin
3494 (package-with-python2 python-htmlmin))
3495
3496 (define-public python-flask-htmlmin
3497 (package
3498 (name "python-flask-htmlmin")
3499 (version "1.2")
3500 (source
3501 (origin
3502 (method url-fetch)
3503 (uri (pypi-uri "Flask-HTMLmin" version))
3504 (sha256
3505 (base32
3506 "1n6zlq72kakkw0z2jpq6nh74lfsmxybm4g053pwhc14fbr809348"))))
3507 (propagated-inputs
3508 `(("python-flask" ,python-flask)
3509 ("python-htmlmin" ,python-htmlmin)))
3510 (build-system python-build-system)
3511 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
3512 (synopsis "HTML response minifier for Flask")
3513 (description
3514 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
3515 (license license:bsd-3)))
3516
3517 (define-public python2-flask-htmlmin
3518 (package-with-python2 python-flask-htmlmin))
3519
3520 (define-public python-jsmin
3521 (package
3522 (name "python-jsmin")
3523 (version "2.2.2")
3524 (source
3525 (origin
3526 (method url-fetch)
3527 (uri (pypi-uri "jsmin" version))
3528 (sha256
3529 (base32
3530 "0fsmqbjvpxvff0984x7c0y8xmf49ax9mncz48b9xjx8wrnr9kpxn"))))
3531 (build-system python-build-system)
3532 (home-page "https://github.com/tikitu/jsmin/")
3533 (synopsis "Python JavaScript minifier")
3534 (description
3535 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
3536 on the command line.")
3537 (license license:expat)))
3538
3539 (define-public python-flask-login
3540 (package
3541 (name "python-flask-login")
3542 (version "0.5.0")
3543 (source
3544 (origin
3545 (method git-fetch)
3546 (uri (git-reference
3547 (url "https://github.com/maxcountryman/flask-login")
3548 (commit version)))
3549 (file-name (git-file-name name version))
3550 (sha256
3551 (base32 "11ac924w0y4m0kf3mxnxdlidy88jfa7njw5yyrq16dvnx4iwd8gg"))))
3552 (build-system python-build-system)
3553 (propagated-inputs
3554 `(("python-flask" ,python-flask)))
3555 (native-inputs
3556 ;; For tests.
3557 `(("python-blinker" ,python-blinker)
3558 ("python-coverage" ,python-coverage)
3559 ("python-mock" ,python-mock)
3560 ("python-pycodestyle" ,python-pycodestyle)
3561 ("python-pyflakes" ,python-pyflakes)
3562 ("python-pytest" ,python-pytest)
3563 ("python-semantic-version" ,python-semantic-version)
3564 ("python-werkzeug" ,python-werkzeug)))
3565 (home-page "https://github.com/maxcountryman/flask-login")
3566 (synopsis "User session management for Flask")
3567 (description
3568 "@code{Flask-Login} provides user session management for Flask. It
3569 handles the common tasks of logging in, logging out, and remembering your
3570 users' sessions over extended periods of time.")
3571 (license license:expat)))
3572
3573 (define-public python2-flask-login
3574 (package-with-python2 python-flask-login))
3575
3576 (define-public python-oauth2client
3577 (package
3578 (name "python-oauth2client")
3579 (version "4.0.0")
3580 (source
3581 (origin
3582 (method url-fetch)
3583 (uri (pypi-uri "oauth2client" version))
3584 (sha256
3585 (base32
3586 "1irqqap2zibysf8dba8sklfqikia579srd0phm5n754ni0h59gl0"))))
3587 (build-system python-build-system)
3588 (arguments
3589 `(#:tests? #f))
3590 (propagated-inputs
3591 `(("python-httplib2" ,python-httplib2)
3592 ("python-pyasn1" ,python-pyasn1)
3593 ("python-pyasn1-modules" ,python-pyasn1-modules)
3594 ("python-rsa" ,python-rsa)
3595 ("python-six" ,python-six)))
3596 (home-page "https://github.com/google/oauth2client/")
3597 (synopsis "OAuth 2.0 client library")
3598 (description "@code{python-oauth2client} provides an OAuth 2.0 client
3599 library for Python")
3600 (license license:asl2.0)))
3601
3602 (define-public python2-oauth2client
3603 (package-with-python2 python-oauth2client))
3604
3605 (define-public python-flask-oidc
3606 (package
3607 (name "python-flask-oidc")
3608 (version "1.1.1")
3609 (source
3610 (origin
3611 (method url-fetch)
3612 (uri (pypi-uri "flask-oidc" version))
3613 (sha256
3614 (base32
3615 "1ay5j0mf174bix7i67hclr95gv16z81fpx0dijvi0gydvdj3ddy2"))))
3616 (build-system python-build-system)
3617 (propagated-inputs
3618 `(("python-flask" ,python-flask)
3619 ("python-itsdangerous" ,python-itsdangerous)
3620 ("python-oauth2client" ,python-oauth2client)
3621 ("python-six" ,python-six)))
3622 (native-inputs
3623 `(("python-nose" ,python-nose)
3624 ("python-mock" ,python-mock)))
3625 (home-page "https://github.com/puiterwijk/flask-oidc")
3626 (synopsis "OpenID Connect extension for Flask")
3627 (description "@code{python-flask-oidc} provides an OpenID Connect extension
3628 for Flask.")
3629 (license license:bsd-2)))
3630
3631 (define-public python-webassets
3632 (package
3633 (name "python-webassets")
3634 (version "2.0")
3635 (source
3636 (origin
3637 (method url-fetch)
3638 (uri (pypi-uri "webassets" version))
3639 (sha256
3640 (base32
3641 "1kc1042jydgk54xpgcp0r1ib4gys91nhy285jzfcxj3pfqrk4w8n"))))
3642 (build-system python-build-system)
3643 (arguments
3644 '(#:phases (modify-phases %standard-phases
3645 (add-before 'check 'disable-some-tests
3646 (lambda _
3647 ;; This test requires 'postcss' and 'babel' which are
3648 ;; not yet available in Guix.
3649 (delete-file "tests/test_filters.py")
3650 #t))
3651 (replace 'check
3652 (lambda _
3653 (setenv "PYTHONPATH"
3654 (string-append "./build/lib:"
3655 (getenv "PYTHONPATH")))
3656 (invoke "pytest" "-vv"))))))
3657 (native-inputs
3658 `(("python-jinja2" ,python-jinja2)
3659 ("python-mock" ,python-mock)
3660 ("python-nose" ,python-nose)
3661 ("python-pytest" ,python-pytest)))
3662 (home-page "https://github.com/miracle2k/webassets")
3663 (synopsis "Media asset management")
3664 (description "Merges, minifies and compresses Javascript and CSS files,
3665 supporting a variety of different filters, including YUI, jsmin, jspacker or
3666 CSS tidy. Also supports URL rewriting in CSS files.")
3667 (license license:bsd-2)))
3668
3669 (define-public python-cssmin
3670 (package
3671 (name "python-cssmin")
3672 (version "0.2.0")
3673 (source
3674 (origin
3675 (method url-fetch)
3676 (uri (pypi-uri "cssmin" version))
3677 (sha256
3678 (base32
3679 "1dk723nfm2yf8cp4pj785giqlwv42l0kj8rk40kczvq1hk6g04p0"))))
3680 (build-system python-build-system)
3681 (home-page "https://github.com/zacharyvoase/cssmin")
3682 (synopsis "Python port of the YUI CSS Compressor")
3683 (description "Python port of the YUI CSS Compressor.")
3684 (license (list license:expat license:bsd-3))))
3685
3686 (define-public python2-cssmin
3687 (package-with-python2 python-cssmin))
3688
3689 (define-public python-elasticsearch
3690 (package
3691 (name "python-elasticsearch")
3692 (version "7.1.0")
3693 (source
3694 (origin
3695 (method url-fetch)
3696 (uri (pypi-uri "elasticsearch" version))
3697 (sha256
3698 (base32
3699 "0rnjvlhw4v3vg14l519qliy1s1zpmx3827q0xfviwvk42rr7hh01"))))
3700 (build-system python-build-system)
3701 (native-inputs
3702 `(("python-mock" ,python-mock)
3703 ("python-nosexcover" ,python-nosexcover)
3704 ("python-pyaml" ,python-pyaml)
3705 ("python-requests" ,python-requests)))
3706 (propagated-inputs
3707 `(("urllib3" ,python-urllib3)))
3708 (arguments
3709 ;; tests require the test_elasticsearch module but it is not distributed.
3710 `(#:tests? #f))
3711 (home-page "https://github.com/elastic/elasticsearch-py")
3712 (synopsis "Low-level client for Elasticsearch")
3713 (description "Official low-level client for Elasticsearch. Its goal is to
3714 provide common ground for all Elasticsearch-related code in Python; because of
3715 this it tries to be opinion-free and very extendable.")
3716 (license license:expat)))
3717
3718 (define-public python2-elasticsearch
3719 (package-with-python2 python-elasticsearch))
3720
3721 (define-public python-flask-script
3722 (package
3723 (name "python-flask-script")
3724 (version "2.0.6")
3725 (source
3726 (origin
3727 (method url-fetch)
3728 (uri (pypi-uri "Flask-Script" version))
3729 (sha256
3730 (base32
3731 "0r8w2v89nj6b9p91p495cga5m72a673l2wc0hp0zqk05j4yrc9b4"))))
3732 (build-system python-build-system)
3733 (arguments
3734 `(#:phases
3735 (modify-phases %standard-phases
3736 (add-after 'unpack 'patch-tests
3737 (lambda _
3738 (substitute* "tests.py"
3739 (("flask\\.ext\\.script") "flask_script"))
3740 #t)))))
3741 (propagated-inputs
3742 `(("python-flask" ,python-flask)
3743 ("python-argcomplete" ,python-argcomplete)
3744 ("python-werkzeug" ,python-werkzeug)))
3745 (native-inputs
3746 `(("python-pytest" ,python-pytest)))
3747 (home-page
3748 "https://github.com/smurfix/flask-script")
3749 (synopsis "Scripting support for Flask")
3750 (description "The Flask-Script extension provides support for writing
3751 external scripts in Flask. This includes running a development server,
3752 a customised Python shell, scripts to set up your database, cronjobs,
3753 and other command-line tasks that belong outside the web application
3754 itself.")
3755 (license license:bsd-3)))
3756
3757 (define-public python-flask-migrate
3758 (package
3759 (name "python-flask-migrate")
3760 (version "2.5.3")
3761 (source
3762 (origin
3763 (method url-fetch)
3764 (uri (pypi-uri "Flask-Migrate" version))
3765 (sha256
3766 (base32
3767 "1vip9ww6l18dxffjsggm83k71zkvihxpnhaswpv8klh95s6517d6"))))
3768 (build-system python-build-system)
3769 (propagated-inputs
3770 `(("python-flask" ,python-flask)
3771 ("python-alembic" ,python-alembic)
3772 ("python-sqlalchemy" ,python-sqlalchemy)
3773 ("python-flask-script" ,python-flask-script)
3774 ("python-flask-sqlalchemy" ,python-flask-sqlalchemy)))
3775 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
3776 (synopsis "SQLAlchemy database migrations for Flask programs using
3777 Alembic")
3778 (description "This package contains SQLAlchemy database migration tools
3779 for Flask programs that are using @code{python-alembic}.")
3780 (license license:expat)))
3781
3782 (define-public python-genshi
3783 (package
3784 (name "python-genshi")
3785 (version "0.7.3")
3786 (source
3787 (origin
3788 (method git-fetch)
3789 (uri (git-reference
3790 (url "https://github.com/edgewall/genshi")
3791 (commit version)))
3792 (file-name (git-file-name name version))
3793 (sha256
3794 (base32 "04bw7nd4wyn8ixnhik57hny2xpjjpn80k5hp6691inix5gc6rxaf"))))
3795 (build-system python-build-system)
3796 (home-page "https://genshi.edgewall.org/")
3797 (synopsis "Toolkit for generation of output for the web")
3798 (description "Genshi is a Python library that provides an integrated set
3799 of components for parsing, generating, and processing HTML, XML or other
3800 textual content for output generation on the web.")
3801 (license license:bsd-3)))
3802
3803 (define-public python2-genshi
3804 (package-with-python2 python-genshi))
3805
3806 (define-public python-flask-principal
3807 (package
3808 (name "python-flask-principal")
3809 (version "0.4.0")
3810 (source
3811 (origin
3812 (method url-fetch)
3813 (uri (pypi-uri "Flask-Principal" version))
3814 (sha256
3815 (base32
3816 "0lwlr5smz8vfm5h9a9i7da3q1c24xqc6vm9jdywdpgxfbi5i7mpm"))))
3817 (build-system python-build-system)
3818 (propagated-inputs
3819 `(("python-blinker" ,python-blinker)))
3820 (native-inputs
3821 `(("python-flask" ,python-flask)
3822 ("python-nose" ,python-nose)))
3823 (home-page "https://pythonhosted.org/Flask-Principal/")
3824 (synopsis "Identity management for Flask")
3825 (description "@code{flask_principal} is a identity management library for
3826 Flask. It supports managing both authentication and authorization data in a
3827 thread-local variable.")
3828 (license license:expat)))
3829
3830 (define-public python-flask-httpauth
3831 (package
3832 (name "python-flask-httpauth")
3833 (version "3.2.3")
3834 (source
3835 (origin
3836 (method url-fetch)
3837 (uri (pypi-uri "Flask-HTTPAuth" version))
3838 (sha256
3839 (base32
3840 "13gff5w1mqpzm5nccyg02v3ifb9ifqh5k866cssjhghhg6msfjsz"))))
3841 (build-system python-build-system)
3842 (native-inputs
3843 `(("python-flask" ,python-flask)))
3844 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
3845 (synopsis "Basic and Digest HTTP authentication for Flask routes")
3846 (description "@code{flask_httpauth} provides Basic and Digest HTTP
3847 authentication for Flask routes.")
3848 (license license:expat)))
3849
3850 (define-public python-uritemplate
3851 (package
3852 (name "python-uritemplate")
3853 (version "3.0.1")
3854 (source
3855 (origin
3856 (method url-fetch)
3857 (uri (pypi-uri "uritemplate" version))
3858 (sha256
3859 (base32
3860 "1bkwmgr0ia9gcn4bszs2xlvml79f0bi2s4a87xg22ky9rq8avy2s"))))
3861 (build-system python-build-system)
3862 (home-page "https://uritemplate.readthedocs.org")
3863 (synopsis "Library to deal with URI Templates")
3864 (description "@code{uritemplate} provides Python library to deal with URI
3865 Templates.")
3866 (license license:bsd-2)))
3867
3868 (define-public python2-uritemplate
3869 (package-with-python2 python-uritemplate))
3870
3871 (define-public python-publicsuffix
3872 (package
3873 (name "python-publicsuffix")
3874 (version "1.1.0")
3875 (source (origin
3876 (method url-fetch)
3877 (uri (pypi-uri "publicsuffix" version))
3878 (sha256
3879 (base32
3880 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
3881 (build-system python-build-system)
3882 (arguments
3883 `(#:tests? #f)) ; tests use the internet
3884 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
3885 (synopsis "Get suffix for a domain name")
3886 (description "Get a public suffix for a domain name using the Public Suffix
3887 List.")
3888 (license license:expat)))
3889
3890 (define-public python2-publicsuffix
3891 (package-with-python2 python-publicsuffix))
3892
3893 (define-public python-publicsuffix2
3894 (package
3895 (name "python-publicsuffix2")
3896 (version "2.20191221")
3897 (source
3898 (origin
3899 (method url-fetch)
3900 (uri (pypi-uri "publicsuffix2" version))
3901 (sha256
3902 (base32 "0yzysvfj1najr1mb4pcqrbmjir3xpb69rlffln95a3cdm8qwry00"))))
3903 (build-system python-build-system)
3904 (arguments
3905 '(#:phases
3906 (modify-phases %standard-phases
3907 (add-after 'unpack 'ignore-maintainer-inputs
3908 (lambda _
3909 ;; Comment out a demand for python-requests, which is used only by
3910 ;; the unused ‘update_psl’ helper command.
3911 (substitute* "setup.py"
3912 (("'requests " match)
3913 (format #f "# ~a" match)))
3914 #t)))
3915 #:tests? #f)) ; the test suite requires network access
3916 (home-page "https://github.com/pombredanne/python-publicsuffix2")
3917 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
3918 (description "Get a public suffix for a domain name using the Public Suffix
3919 List. Forked from and using the same API as the publicsuffix package.")
3920 (license (list license:expat license:mpl2.0))))
3921
3922 (define-public python2-publicsuffix2
3923 (package-with-python2 python-publicsuffix2))
3924
3925 (define-public python-werkzeug
3926 (package
3927 (name "python-werkzeug")
3928 (version "1.0.1")
3929 (source
3930 (origin
3931 (method url-fetch)
3932 (uri (pypi-uri "Werkzeug" version))
3933 (sha256
3934 (base32
3935 "0z74sa1xw5h20yin9faj0vvdbq713cgbj84klc72jr9nmpjv303c"))))
3936 (build-system python-build-system)
3937 (arguments
3938 '(#:phases
3939 (modify-phases %standard-phases
3940 (delete 'check)
3941 (add-after 'install 'check
3942 (lambda* (#:key inputs outputs #:allow-other-keys)
3943 (add-installed-pythonpath inputs outputs)
3944 (invoke "python" "-m" "pytest"))))))
3945 (propagated-inputs
3946 `(("python-requests" ,python-requests)))
3947 (native-inputs
3948 `(("python-pytest" ,python-pytest)
3949 ("python-pytest-timeout" ,python-pytest-timeout)))
3950 (home-page "https://palletsprojects.com/p/werkzeug/")
3951 (synopsis "Utilities for WSGI applications")
3952 (description "One of the most advanced WSGI utility modules. It includes a
3953 powerful debugger, full-featured request and response objects, HTTP utilities to
3954 handle entity tags, cache control headers, HTTP dates, cookie handling, file
3955 uploads, a powerful URL routing system and a bunch of community-contributed
3956 addon modules.")
3957 (license license:x11)))
3958
3959 (define-public python-bottle
3960 (package
3961 (name "python-bottle")
3962 (version "0.12.19")
3963 (source
3964 (origin
3965 (method url-fetch)
3966 (uri (pypi-uri "bottle" version))
3967 (sha256
3968 (base32 "0b6s50vc4iad97b6bb3xnyrgajb3nj6n6jbr5p54a4vapky3zmx9"))))
3969 (build-system python-build-system)
3970 (home-page "https://bottlepy.org/")
3971 (synopsis "WSGI framework for small web-applications.")
3972 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
3973 (license license:expat)))
3974
3975 (define-public python2-bottle
3976 (package-with-python2 python-bottle))
3977
3978 (define-public python-wtforms
3979 (package
3980 (name "python-wtforms")
3981 (version "2.1")
3982 (source
3983 (origin
3984 (method url-fetch)
3985 (uri (pypi-uri "WTForms" version ".zip"))
3986 (sha256
3987 (base32
3988 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
3989 (build-system python-build-system)
3990 (arguments
3991 '(#:phases
3992 (modify-phases %standard-phases
3993 (add-after 'unpack 'remove-django-test
3994 ;; Don't fail the tests when the inputs for the optional tests cannot be found.
3995 (lambda _
3996 (substitute*
3997 "tests/runtests.py"
3998 (("'ext_django.tests', 'ext_sqlalchemy', 'ext_dateutil', 'locale_babel'") "")
3999 (("sys.stderr.write(\"### Disabled test '%s', dependency not found\n\" % name)") ""))
4000 #t)))))
4001 (native-inputs
4002 `(("unzip" ,unzip)))
4003 (home-page "http://wtforms.simplecodes.com/")
4004 (synopsis
4005 "Form validation and rendering library for Python web development")
4006 (description
4007 "WTForms is a flexible forms validation and rendering library
4008 for Python web development. It is very similar to the web form API
4009 available in Django, but is a standalone package.")
4010 (license license:bsd-3)))
4011
4012 (define-public python2-wtforms
4013 (package-with-python2 python-wtforms))
4014
4015 (define-public python-paste
4016 (package
4017 (name "python-paste")
4018 (version "3.0.6")
4019 (source
4020 (origin
4021 (method url-fetch)
4022 (uri (pypi-uri "Paste" version))
4023 (sha256
4024 (base32
4025 "14lbi9asn5agsdf7r97prkjpz7amgmp529lbvfhf0nv881xczah6"))
4026 (patches (search-patches "python-paste-remove-timing-test.patch"))
4027 (modules '((guix build utils)))
4028 (snippet
4029 '(begin
4030 ;; This test calls out to the internet.
4031 (delete-file "tests/test_proxy.py") #t))))
4032 (build-system python-build-system)
4033 (native-inputs
4034 `(("python-pytest" ,python-pytest)
4035 ("python-pytest-runner" ,python-pytest-runner)
4036 ("python-nose" ,python-nose)))
4037 (propagated-inputs
4038 `(("python-six" ,python-six)))
4039 (home-page "https://pythonpaste.readthedocs.io/")
4040 (synopsis
4041 "Python web development tools, focusing on WSGI")
4042 (description
4043 "Paste provides a variety of web development tools and middleware which
4044 can be nested together to build web applications. Paste's design closely
4045 follows ideas flowing from WSGI (Web Standard Gateway Interface).")
4046 (license license:expat)))
4047
4048 (define-public python2-paste
4049 (package-with-python2 python-paste))
4050
4051 (define-public python-pastescript
4052 (package
4053 (name "python-pastescript")
4054 (version "2.0.2")
4055 (source
4056 (origin
4057 (method url-fetch)
4058 (uri (pypi-uri "PasteScript" version))
4059 (sha256
4060 (base32
4061 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
4062 (build-system python-build-system)
4063 (native-inputs
4064 `(("python-nose" ,python-nose)))
4065 (propagated-inputs
4066 `(("python-paste" ,python-paste)
4067 ("python-pastedeploy" ,python-pastedeploy)))
4068 (home-page (string-append "https://web.archive.org/web/20161025192515/"
4069 "http://pythonpaste.org/script/"))
4070 (arguments
4071 '(;; Unfortunately, this requires the latest unittest2,
4072 ;; but that requires traceback2 which requires linecache2 which requires
4073 ;; unittest2. So we're skipping tests for now.
4074 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
4075 ;; so in theory we could get around this situation somehow.)
4076 #:tests? #f))
4077 (synopsis
4078 "Pluggable command line tool for serving web applications and more")
4079 (description
4080 "PasteScript is a plugin-friendly command line tool which provides a
4081 variety of features, from launching web applications to bootstrapping project
4082 layouts.")
4083 (license license:expat)))
4084
4085 (define-public python2-pastescript
4086 (package-with-python2 python-pastescript))
4087
4088 (define-public python2-urlgrabber
4089 (package
4090 (name "python2-urlgrabber")
4091 (version "3.10.2")
4092 (source
4093 (origin
4094 (method url-fetch)
4095 (uri (pypi-uri "urlgrabber" version))
4096 (sha256
4097 (base32 "0w1h7hlsq406bxfy2pn4i9bd003bwl0q9b7p03z3g6yl0d21ddq5"))))
4098 (build-system python-build-system)
4099 (arguments `(#:python ,python-2)) ; urlgrabber supports python2 only
4100 (home-page "http://urlgrabber.baseurl.org")
4101 (synopsis "High-level cross protocol url-grabber")
4102 (description "@code{urlgrabber} is Python2 library that unifies access to
4103 files available on web, FTP or locally. It supports HTTP, FTP and file://
4104 protocols, it supports features like HTTP keep-alive, reget, throttling and
4105 more.")
4106 (license license:lgpl2.1+)))
4107
4108 (define-public python-pycares
4109 (package
4110 (name "python-pycares")
4111 (version "2.3.0")
4112 (source
4113 (origin
4114 (method url-fetch)
4115 (uri (pypi-uri "pycares" version))
4116 (sha256
4117 (base32
4118 "0h4fxw5drrhfyslzmfpljk0qnnpbhhb20hnnndzahhbwylyw1x1n"))))
4119 (build-system python-build-system)
4120 (arguments
4121 `(#:tests? #f)) ;tests require internet access
4122 (home-page "https://github.com/saghul/pycares")
4123 (synopsis "Python interface for @code{c-ares}")
4124 (description "@code{pycares} is a Python module which provides an
4125 interface to @code{c-ares}, a C library that performs DNS requests and
4126 name resolutions asynchronously.")
4127 (license license:expat)))
4128
4129 (define-public python-yarl
4130 (package
4131 (name "python-yarl")
4132 (version "1.1.1")
4133 (source
4134 (origin
4135 (method url-fetch)
4136 (uri (pypi-uri "yarl" version))
4137 (sha256
4138 (base32
4139 "1s6z13g8vgxfkkqwhn6imnm7pl7ky9arv4jygnn6bcndcbidg7d6"))))
4140 (build-system python-build-system)
4141 (native-inputs
4142 `(("python-pytest" ,python-pytest)
4143 ("python-pytest-runner" ,python-pytest-runner)))
4144 (propagated-inputs
4145 `(("python-idna" ,python-idna)
4146 ("python-multidict" ,python-multidict)))
4147 (home-page "https://github.com/aio-libs/yarl/")
4148 (synopsis "Yet another URL library")
4149 (description "@code{yarl} module provides handy @code{URL} class
4150 for URL parsing and changing.")
4151 (license license:asl2.0)))
4152
4153 (define-public python-google-api-client
4154 (package
4155 (name "python-google-api-client")
4156 (version "1.6.7")
4157 (source
4158 (origin
4159 (method url-fetch)
4160 (uri (pypi-uri "google-api-python-client" version))
4161 (sha256
4162 (base32
4163 "1wpbbbxfpy9mwxdy3kn352cb590ladv574j1aa2l4grjdqw3ln05"))))
4164 (build-system python-build-system)
4165 (arguments
4166 '(#:tests? #f)) ; tests require internet access
4167 (native-inputs
4168 `(("python-httplib2" ,python-httplib2)
4169 ("python-six" ,python-six)
4170 ("python-oauth2client" ,python-oauth2client)
4171 ("python-uritemplate" ,python-uritemplate)))
4172 (home-page "https://github.com/google/google-api-python-client")
4173 (synopsis "Core Python library for accessing Google APIs")
4174 (description "Python client library for Google's discovery based APIs")
4175 (license license:asl2.0)))
4176
4177 (define-public python2-google-api-client
4178 (package-with-python2 python-google-api-client))
4179
4180 (define-public python-hawkauthlib
4181 (package
4182 (name "python-hawkauthlib")
4183 (version "2.0.0")
4184 (source
4185 (origin
4186 (method url-fetch)
4187 (uri (pypi-uri "hawkauthlib" version))
4188 (sha256
4189 (base32
4190 "03ai47s4h8nfnrf25shbfvkm1b9n1ccd4nmmj280sg1fayi69zgg"))))
4191 (build-system python-build-system)
4192 (propagated-inputs
4193 `(("python-requests" ,python-requests)
4194 ("python-webob" ,python-webob)))
4195 (home-page "https://github.com/mozilla-services/hawkauthlib")
4196 (synopsis "Hawk Access Authentication protocol")
4197 (description
4198 "This is a low-level Python library for implementing Hawk Access Authentication,
4199 a simple HTTP request-signing scheme.")
4200 (license license:mpl2.0)))
4201
4202 (define-public python-pybrowserid
4203 (package
4204 (name "python-pybrowserid")
4205 (version "0.14.0")
4206 (source
4207 (origin
4208 (method url-fetch)
4209 (uri (pypi-uri "PyBrowserID" version))
4210 (sha256
4211 (base32
4212 "1qvi79kfb8x9kxkm5lw2mp42hm82cpps1xknmsb5ghkwx1lpc8kc"))))
4213 (build-system python-build-system)
4214 (propagated-inputs
4215 `(("python-requests" ,python-requests)))
4216 (native-inputs
4217 `(("python-mock" ,python-mock)))
4218 (home-page "https://github.com/mozilla/PyBrowserID")
4219 (synopsis "Python library for the BrowserID protocol")
4220 (description
4221 "This is a Python client library for the BrowserID protocol that
4222 underlies Mozilla Persona.")
4223 (license license:mpl2.0)))
4224
4225 (define-public python-pyfxa
4226 (package
4227 (name "python-pyfxa")
4228 (version "0.6.0")
4229 (source
4230 (origin
4231 (method url-fetch)
4232 (uri (pypi-uri "PyFxA" version))
4233 (sha256
4234 (base32
4235 "0axl16fyrz2r88gnw4b12mk7dpkqscv8c4wsc1y5hicl7bsbc4fm"))))
4236 (build-system python-build-system)
4237 (arguments '(#:tests? #f)) ; 17 tests require network access
4238 (propagated-inputs
4239 `(("python-cryptography" ,python-cryptography)
4240 ("python-hawkauthlib" ,python-hawkauthlib)
4241 ("python-pybrowserid" ,python-pybrowserid)
4242 ("python-requests" ,python-requests)
4243 ("python-six" ,python-six)))
4244 (native-inputs
4245 `(("python-grequests" ,python-grequests)
4246 ("python-mock" ,python-mock)
4247 ("python-responses" ,python-responses)
4248 ("python-unittest2" ,python-unittest2)))
4249 (home-page "https://github.com/mozilla/PyFxA")
4250 (synopsis "Firefox Accounts client library for Python")
4251 (description
4252 "This is a Python library for interacting with the Firefox Accounts
4253 ecosystem.")
4254 (license license:mpl2.0)))
4255
4256 (define-public python-hyperlink
4257 (package
4258 (name "python-hyperlink")
4259 (version "19.0.0")
4260 (source
4261 (origin
4262 (method url-fetch)
4263 (uri (pypi-uri "hyperlink" version))
4264 (sha256
4265 (base32
4266 "0m2nhi0j8wmgfscf974wd5v1xfq8mah286hil6npy1ys0m3y7222"))))
4267 (build-system python-build-system)
4268 (propagated-inputs
4269 `(("python-idna" ,python-idna)))
4270 (home-page "https://github.com/python-hyper/hyperlink")
4271 (synopsis "Python module to create immutable URLs according to spec")
4272 (description "This package provides a Python module to create immutable, and
4273 correct URLs for Python according to RFCs 3986 and 3987.")
4274 (license license:expat)))
4275
4276 (define-public python-treq
4277 (package
4278 (name "python-treq")
4279 (version "18.6.0")
4280 (source
4281 (origin
4282 (method url-fetch)
4283 (uri (pypi-uri "treq" version))
4284 (sha256
4285 (base32
4286 "0j4zwq9p1c9piv1vc66nxcv9s6hdinf90jwkbsm91k14npv9zq4i"))))
4287 (build-system python-build-system)
4288 (propagated-inputs
4289 `(("python-attrs" ,python-attrs)
4290 ("python-idna" ,python-idna)
4291 ("python-incremental" ,python-incremental)
4292 ("python-requests" ,python-requests)
4293 ("python-service-identity" ,python-service-identity)
4294 ("python-twisted" ,python-twisted)))
4295 (home-page "https://github.com/twisted/treq")
4296 (synopsis "Requests-like API built on top of twisted.web's Agent")
4297 (description "This package provides an HTTP library inspired by
4298 @code{requests}} but written on top of Twisted's @code{Agents}. It offers a
4299 high level API for making HTTP requests when using Twisted.")
4300 (license license:expat)))
4301
4302 (define-public python-autobahn
4303 (package
4304 (name "python-autobahn")
4305 (version "19.2.1")
4306 (source
4307 (origin
4308 (method url-fetch)
4309 (uri (pypi-uri "autobahn" version))
4310 (sha256
4311 (base32
4312 "1mm7j24ls01c7jb1ad5p5cpyxvzgydiyf8b04ihykh2v8g98j0x7"))))
4313 (build-system python-build-system)
4314 (arguments
4315 ;; The tests fail to run:
4316 ;; https://github.com/crossbario/autobahn-python/issues/1117
4317 `(#:tests? #f))
4318 (propagated-inputs
4319 `(("python-cffi" ,python-cffi)
4320 ("python-twisted" ,python-twisted)
4321 ("python-txaio" ,python-txaio)))
4322 (home-page "https://crossbar.io/autobahn/")
4323 (synopsis "Web Application Messaging Protocol implementation")
4324 (description "This package provides an implementation of the @dfn{Web Application
4325 Messaging Protocol} (WAMP). WAMP connects components in distributed
4326 applications using Publish and Subscribe (PubSub) and routed Remote Procedure
4327 Calls (rRPC). It is ideal for distributed, multi-client and server applications
4328 such as IoT applications or multi-user database-driven business applications.")
4329 (license license:expat)))
4330
4331 (define-public python-ws4py
4332 (package
4333 (name "python-ws4py")
4334 (version "0.5.1")
4335 (source
4336 (origin
4337 (method url-fetch)
4338 (uri (pypi-uri "ws4py" version))
4339 (sha256
4340 (base32
4341 "10slbbf2jm4hpr92jx7kh7mhf48sjl01v2w4d8z3f1p0ybbp7l19"))))
4342 (build-system python-build-system)
4343 (arguments
4344 `(#:phases
4345 (modify-phases %standard-phases
4346 (add-after 'unpack 'python3.7-compatibility
4347 (lambda _
4348 (substitute* '("ws4py/server/tulipserver.py"
4349 "ws4py/async_websocket.py")
4350 (("asyncio.async")
4351 "asyncio.ensure_future"))
4352 #t))
4353 ;; We don't have a package for cherrypy.
4354 (add-after 'unpack 'remove-cherrypy-support
4355 (lambda _
4356 (delete-file "ws4py/server/cherrypyserver.py")
4357 #t)))))
4358 (propagated-inputs
4359 `(("python-gevent" ,python-gevent)
4360 ("python-tornado" ,python-tornado)))
4361 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
4362 (synopsis "WebSocket client and server library")
4363 (description
4364 "This package provides a WebSocket client and server library for
4365 Python.")
4366 (license license:bsd-3)))
4367
4368 (define-public python-slugify
4369 (package
4370 (name "python-slugify")
4371 (version "4.0.1")
4372 (source
4373 (origin
4374 (method url-fetch)
4375 (uri (pypi-uri "python-slugify" version))
4376 (sha256
4377 (base32 "0w22fapghmzk3xdasc4dn7h8sl58l08d1h5zbf72dh80drv1g9b9"))))
4378 (propagated-inputs
4379 `(("python-unidecode" ,python-unidecode)))
4380 (arguments
4381 `(#:phases
4382 (modify-phases %standard-phases
4383 (replace 'check
4384 (lambda _
4385 (invoke "python" "test.py"))))))
4386 (build-system python-build-system)
4387 (home-page "https://github.com/un33k/python-slugify")
4388 (synopsis "Python Slugify application that handles Unicode")
4389 (description "This package provides a @command{slufigy} command and
4390 library to create slugs from unicode strings while keeping it DRY.")
4391 (license license:expat)))
4392
4393 (define-public python-branca
4394 (package
4395 (name "python-branca")
4396 (version "0.3.1")
4397 (source
4398 (origin
4399 (method url-fetch)
4400 (uri (pypi-uri "branca" version))
4401 (sha256
4402 (base32
4403 "0pmigd521j2228xf8x34vbx0niwvms7xl7za0lymywj0vydjqxiy"))))
4404 (build-system python-build-system)
4405 (propagated-inputs
4406 `(("python-jinja2" ,python-jinja2)
4407 ("python-six" ,python-six)))
4408 (native-inputs
4409 `(("python-pytest" ,python-pytest)))
4410 (home-page "https://github.com/python-visualization/branca")
4411 (synopsis "Generate complex HTML+JS pages with Python")
4412 (description "Generate complex HTML+JS pages with Python")
4413 (license license:expat)))
4414
4415 (define-public python-tinycss2
4416 (package
4417 (name "python-tinycss2")
4418 (version "1.1.0")
4419 (source
4420 (origin
4421 (method url-fetch)
4422 (uri (pypi-uri "tinycss2" version))
4423 (sha256
4424 (base32 "12p16k8x8ig51gpfcwz3k3kxpxrwwkn41a1avdgvh3nn8hqarp7v"))))
4425 (build-system python-build-system)
4426 (arguments
4427 ;; Test data is missing from the PyPI archive, and the build system is
4428 ;; based on Flit, which wants an unmaintained and unpackaged
4429 ;; python-pytoml dependency.
4430 `(#:tests? #f))
4431 (propagated-inputs
4432 `(("python-webencodings" ,python-webencodings)))
4433 (home-page "https://tinycss2.readthedocs.io/")
4434 (synopsis "Low-level CSS parser for Python")
4435 (description "@code{tinycss2} can parse strings, return Python objects
4436 representing tokens and blocks, and generate CSS strings corresponding to
4437 these objects.
4438
4439 Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
4440 grammar of CSS but doesn’t know specific rules, properties or values supported
4441 in various CSS modules.")
4442 (license license:bsd-3)))
4443
4444 (define-public python-cssselect2
4445 (package
4446 (name "python-cssselect2")
4447 (version "0.4.1")
4448 (source
4449 (origin
4450 (method url-fetch)
4451 (uri (pypi-uri "cssselect2" version))
4452 (sha256
4453 (base32 "1j2fcr217rsvkipsg6zjq03rl64rxnvb5hqqpx0dv58fhspvkywk"))))
4454 (build-system python-build-system)
4455 (arguments
4456 `(#:phases
4457 (modify-phases %standard-phases
4458 (replace 'check
4459 (lambda _ (invoke "pytest"))))))
4460 (propagated-inputs
4461 `(("python-tinycss2" ,python-tinycss2)))
4462 (native-inputs
4463 `(("python-pytest-cov" ,python-pytest-cov)
4464 ("python-pytest-flake8" ,python-pytest-flake8)
4465 ("python-pytest-isort" ,python-pytest-isort)
4466 ("python-pytest-runner" ,python-pytest-runner)))
4467 (home-page "https://cssselect2.readthedocs.io/")
4468 (synopsis "CSS selectors for Python ElementTree")
4469 (description "@code{cssselect2} is a straightforward implementation of
4470 CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
4471 ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
4472
4473 Unlike the Python package @code{cssselect}, it does not translate selectors to
4474 XPath and therefore does not have all the correctness corner cases that are
4475 hard or impossible to fix in cssselect.")
4476 (license license:bsd-3)))
4477
4478 (define-public python-uvloop
4479 (package
4480 (name "python-uvloop")
4481 (version "0.14.0")
4482 (source
4483 (origin
4484 (method url-fetch)
4485 (uri (pypi-uri "uvloop" version))
4486 (sha256
4487 (base32 "07j678z9gf41j98w72ysrnb5sa41pl5yxd7ib17lcwfxqz0cjfhj"))))
4488 (build-system python-build-system)
4489 (arguments
4490 '(#:tests? #f ;FIXME: tests hang and with some errors in the way
4491 #:phases
4492 (modify-phases %standard-phases
4493 (add-after 'unpack 'preparations
4494 (lambda _
4495 ;; Use packaged libuv.
4496 (substitute* "setup.py" (("self.use_system_libuv = False")
4497 "self.use_system_libuv = True"))
4498 #t)))))
4499 (native-inputs
4500 `(("python-aiohttp" ,python-aiohttp)
4501 ("python-cython" ,python-cython)
4502 ("python-flake8" ,python-flake8)
4503 ("python-psutil" ,python-psutil)
4504 ("python-pyopenssl" ,python-pyopenssl)
4505 ("python-twine" ,python-twine)))
4506 (inputs
4507 `(("libuv" ,libuv)))
4508 (home-page "https://github.com/MagicStack/uvloop")
4509 (synopsis "Fast implementation of asyncio event loop on top of libuv")
4510 (description
4511 "@code{uvloop} is a fast, drop-in replacement of the built-in asyncio
4512 event loop. It is implemented in Cython and uses libuv under the hood.")
4513 (license license:expat)))
4514
4515 (define-public gunicorn
4516 (package
4517 (name "gunicorn")
4518 (version "20.0.4")
4519 (source
4520 (origin
4521 (method url-fetch)
4522 (uri (pypi-uri "gunicorn" version))
4523 (sha256
4524 (base32
4525 "09n6fc019bgrvph1s5h1lwhn2avcsprw6ncd203qhra3i8mvn10r"))))
4526 (outputs '("out" "doc"))
4527 (build-system python-build-system)
4528 (arguments
4529 `(#:phases
4530 (modify-phases %standard-phases
4531 (add-after 'build 'build-doc
4532 (lambda _
4533 (invoke "make" "-C" "docs" "PAPER=a4" "html" "info")
4534 (delete-file "docs/build/texinfo/Makefile")
4535 (delete-file "docs/build/texinfo/Gunicorn.texi")
4536 #t))
4537 (replace 'check
4538 (lambda _
4539 (setenv "PYTHONPATH"
4540 (string-append ".:" (getenv "PYTHONPATH")))
4541 (invoke "pytest")))
4542 (add-after 'install 'install-doc
4543 (lambda* (#:key outputs #:allow-other-keys)
4544 (let* ((doc (string-append (assoc-ref outputs "doc")
4545 "/share/doc/" ,name "-" ,version))
4546 (html (string-append doc "/html"))
4547 (info (string-append doc "/info"))
4548 (examples (string-append doc "/examples")))
4549 (mkdir-p html)
4550 (mkdir-p info)
4551 (mkdir-p examples)
4552 (copy-recursively "docs/build/html" html)
4553 (copy-recursively "docs/build/texinfo" info)
4554 (copy-recursively "examples" examples)
4555 (for-each (lambda (file)
4556 (copy-file file (string-append doc "/" file)))
4557 '("README.rst" "NOTICE" "LICENSE" "THANKS")))
4558 #t)))))
4559 (native-inputs
4560 `(("binutils" ,binutils) ;; for ctypes.util.find_library()
4561 ("python-aiohttp" ,python-aiohttp)
4562 ("python-pytest" ,python-pytest)
4563 ("python-pytest-cov" ,python-pytest-cov)
4564 ("python-sphinx" ,python-sphinx)
4565 ("texinfo" ,texinfo)))
4566 (home-page "https://gunicorn.org/")
4567 (synopsis "Python WSGI HTTP Server for UNIX")
4568 (description "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
4569 Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
4570 Unicorn project. The Gunicorn server is broadly compatible with
4571 various web frameworks, simply implemented, light on server resources,
4572 and fairly speedy.")
4573 (license license:expat)))
4574
4575 ;; break cyclic dependency for python-aiohttp, which depends on gunicorn for
4576 ;; its tests
4577 (define-public gunicorn-bootstrap
4578 (package
4579 (inherit gunicorn)
4580 (name "gunicorn")
4581 (arguments `(#:tests? #f))
4582 (properties '((hidden? . #t)))
4583 (native-inputs `())))
4584
4585 (define-public python-httptools
4586 (package
4587 (name "python-httptools")
4588 (version "0.1.1")
4589 (source
4590 (origin
4591 ;; PyPI tarball comes with a vendored http-parser and no tests.
4592 (method git-fetch)
4593 (uri (git-reference
4594 (url "https://github.com/MagicStack/httptools")
4595 (commit (string-append "v" version))))
4596 (file-name (git-file-name name version))
4597 (sha256
4598 (base32 "0g08128x2ixsiwrzskxc6c8ymgzs39wbzr5mhy0mjk30q9pqqv77"))))
4599 (build-system python-build-system)
4600 (arguments
4601 '(#:phases
4602 (modify-phases %standard-phases
4603 (add-after 'unpack 'preparations
4604 (lambda _
4605 ;; Skip a failing test (AssertionError). Bug report:
4606 ;; https://github.com/MagicStack/httptools/issues/10.
4607 (substitute* "tests/test_parser.py"
4608 ((" def test_parser_response_1")
4609 (string-append
4610 " @unittest.skip(\"Disabled.\")\n"
4611 " def test_parser_response_1")))
4612 ;; Use packaged http-parser.
4613 (substitute* "setup.py" (("self.use_system_http_parser = False")
4614 "self.use_system_http_parser = True"))
4615 ;; This path is hardcoded. Hardcode our own.
4616 (substitute* "httptools/parser/cparser.pxd"
4617 (("../../vendor/http-parser")
4618 (string-append (assoc-ref %build-inputs "http-parser")
4619 "/include")))
4620 ;; Don't force Cython version.
4621 (substitute* "setup.py" (("Cython==") "Cython>="))
4622 #t)))))
4623 (native-inputs
4624 `(("python-cython" ,python-cython)
4625 ("python-pytest" ,python-pytest)))
4626 (inputs
4627 `(("http-parser" ,http-parser)))
4628 (home-page "https://github.com/MagicStack/httptools")
4629 (synopsis "Collection of framework independent HTTP protocol utils")
4630 (description
4631 "@code{httptools} is a Python binding for the nodejs HTTP parser.")
4632 (license license:expat)))
4633
4634 (define-public python-uvicorn
4635 (package
4636 (name "python-uvicorn")
4637 (version "0.11.8")
4638 (source
4639 (origin
4640 ;; PyPI tarball has no tests.
4641 (method git-fetch)
4642 (uri (git-reference
4643 (url "https://github.com/encode/uvicorn")
4644 (commit version)))
4645 (file-name (git-file-name name version))
4646 (sha256
4647 (base32 "00iidg5ysp7k00bw3kmkvr8mghnh4jdi0p2ryiarhryf8wz2r3fy"))))
4648 (build-system python-build-system)
4649 (arguments
4650 `(#:phases
4651 (modify-phases %standard-phases
4652 (replace 'check
4653 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
4654 (add-installed-pythonpath inputs outputs)
4655 (invoke "pytest" "-vv"))))))
4656 (native-inputs
4657 `(("python-black" ,python-black)
4658 ("python-codecov" ,python-codecov)
4659 ("python-flake8" ,python-flake8)
4660 ("python-isort" ,python-isort)
4661 ("python-mypy" ,python-mypy)
4662 ("python-pytest" ,python-pytest)
4663 ("python-pytest-cov" ,python-pytest-cov)
4664 ("python-pytest-mock" ,python-pytest-mock)
4665 ("python-requests" ,python-requests)))
4666 (propagated-inputs
4667 `(("python-click" ,python-click)
4668 ("python-h11" ,python-h11)
4669 ("python-httptools" ,python-httptools)
4670 ("python-pyyaml" ,python-pyyaml)
4671 ("python-uvloop" ,python-uvloop)
4672 ("python-watchgod" ,python-watchgod)
4673 ("python-websockets" ,python-websockets)
4674 ("python-wsproto" ,python-wsproto)))
4675 (home-page "https://github.com/encode/uvicorn")
4676 (synopsis "Fast ASGI server implementation")
4677 (description
4678 "@code{uvicorn} is a fast ASGI server implementation, using @code{uvloop}
4679 and @code{httptools}. It currently supports HTTP/1.1 and WebSockets. Support
4680 for HTTP/2 is planned.")
4681 (license license:bsd-3)))
4682
4683 (define-public python-translation-finder
4684 (package
4685 (name "python-translation-finder")
4686 (version "1.7")
4687 (source
4688 (origin
4689 (method url-fetch)
4690 (uri (pypi-uri "translation-finder" version))
4691 (sha256
4692 (base32
4693 "1pcy9z8gmb8x41gjhw9x0lkr0d2mv5mdxcs2hwg6q8mxs857j589"))))
4694 (build-system python-build-system)
4695 (arguments
4696 `(#:phases
4697 (modify-phases %standard-phases
4698 (add-before 'build 'remove-failing-test
4699 (lambda _
4700 (delete-file "translation_finder/test_api.py")
4701 #t)))))
4702 (propagated-inputs
4703 `(("python-chardet" ,python-chardet)
4704 ("python-pathlib2" ,python-pathlib2)
4705 ("python-ruamel.yaml" ,python-ruamel.yaml)
4706 ("python-six" ,python-six)))
4707 (native-inputs
4708 `(("python-codecov" ,python-codecov)
4709 ("python-codacy-coverage" ,python-codacy-coverage)
4710 ("python-pytest-cov" ,python-pytest-cov)
4711 ("python-pytest-runner" ,python-pytest-runner)
4712 ("python-twine" ,python-twine)))
4713 (home-page "https://weblate.org/")
4714 (synopsis "Translation file finder for Weblate")
4715 (description "This package provides a function to find translation file in
4716 the source code of a project. It supports many translation file formats and
4717 is part of the Weblate translation platform.")
4718 (license license:gpl3+)))
4719
4720 (define-public python-gitlab
4721 (package
4722 (name "python-gitlab")
4723 (version "1.15.0")
4724 (source
4725 (origin
4726 (method url-fetch)
4727 (uri (pypi-uri "python-gitlab" version))
4728 (sha256
4729 (base32
4730 "0zl6kz8v8cg1bcy2r78b2snb0lpw0b573gdx2x1ps0nhsh75l4j5"))))
4731 (build-system python-build-system)
4732 (propagated-inputs
4733 `(("python-requests" ,python-requests)
4734 ("python-six" ,python-six)))
4735 (native-inputs
4736 `(("python-httmock" ,python-httmock)
4737 ("python-mock" ,python-mock)))
4738 (home-page
4739 "https://github.com/python-gitlab/python-gitlab")
4740 (synopsis "Interact with GitLab API")
4741 (description "This package provides an extended library for interacting
4742 with GitLab instances through their API.")
4743 (license license:lgpl3+)))
4744
4745 (define-public python-path-and-address
4746 (package
4747 (name "python-path-and-address")
4748 (version "2.0.1")
4749 (source
4750 (origin
4751 ;; The source distributed on PyPI doesn't include tests.
4752 (method git-fetch)
4753 (uri (git-reference
4754 (url "https://github.com/joeyespo/path-and-address")
4755 (commit (string-append "v" version))))
4756 (file-name (git-file-name name version))
4757 (sha256
4758 (base32
4759 "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6"))))
4760 (build-system python-build-system)
4761 (arguments
4762 `(#:phases
4763 (modify-phases %standard-phases
4764 (replace 'check
4765 (lambda* (#:key inputs outputs #:allow-other-keys)
4766 (add-installed-pythonpath inputs outputs)
4767 (invoke "py.test"))))))
4768 (native-inputs
4769 `(("python-pytest" ,python-pytest)))
4770 (home-page "https://github.com/joeyespo/path-and-address")
4771 (synopsis "Functions for command-line server tools used by humans")
4772 (description "Path-and-address resolves ambiguities of command-line
4773 interfaces, inferring which argument is the path, and which is the address.")
4774 (license license:expat)))
4775
4776 (define-public grip
4777 ;; No release by upstream for quite some time, some bugs fixed since. See:
4778 ;; https://github.com/joeyespo/grip/issues/304
4779 (let ((commit "27a4d6d87ea1d0ea7f7f120de55baabee3de73e3"))
4780 (package
4781 (name "grip")
4782 (version (git-version "4.5.2" "1" commit))
4783 (source
4784 (origin
4785 (method git-fetch)
4786 (uri (git-reference
4787 (url "https://github.com/joeyespo/grip")
4788 (commit commit)))
4789 (file-name (git-file-name name version))
4790 (sha256
4791 (base32
4792 "0kx5hgb3q19i4l18a4vqdq9af390xgpk88lp2ay75qi96k0dc68w"))))
4793 (build-system python-build-system)
4794 (propagated-inputs
4795 `(("python-docopt" ,python-docopt)
4796 ("python-flask" ,python-flask)
4797 ("python-markdown" ,python-markdown)
4798 ("python-path-and-address" ,python-path-and-address)
4799 ("python-pygments" ,python-pygments)
4800 ("python-requests" ,python-requests)))
4801 (native-inputs
4802 `(("python-pytest" ,python-pytest)
4803 ("python-responses" ,python-responses)))
4804 (arguments
4805 `(#:phases
4806 (modify-phases %standard-phases
4807 (replace 'check
4808 (lambda* (#:key inputs outputs #:allow-other-keys)
4809 (add-installed-pythonpath inputs outputs)
4810 (setenv "PATH" (string-append
4811 (getenv "PATH") ":"
4812 (assoc-ref %outputs "out") "/bin"))
4813 (invoke "py.test" "-m" "not assumption"))))))
4814 (home-page "https://github.com/joeyespo/grip")
4815 (synopsis "Preview Markdown files using the GitHub API")
4816 (description "Grip is a command-line server application written in Python
4817 that uses the GitHub Markdown API to render a local Markdown file. The styles
4818 and rendering come directly from GitHub, so you'll know exactly how it will
4819 appear. Changes you make to the file will be instantly reflected in the browser
4820 without requiring a page refresh.")
4821 (license license:expat))))
4822
4823 (define-public python-port-for
4824 (package
4825 (name "python-port-for")
4826 (version "0.4")
4827 (source
4828 (origin
4829 (method url-fetch)
4830 (uri (pypi-uri "port-for" version))
4831 (sha256
4832 (base32
4833 "1pncxlj25ggw99r0ijfbkq70gd7cbhqdx5ivsxy4jdp0z14cpda7"))))
4834 (build-system python-build-system)
4835 (arguments
4836 `(#:phases
4837 (modify-phases %standard-phases
4838 (add-after 'unpack 'use-urllib3
4839 (lambda _
4840 (substitute* "port_for/_download_ranges.py"
4841 (("urllib2") "urllib3"))
4842 #t)))))
4843 (propagated-inputs
4844 `(("python-urllib3" ,python-urllib3)))
4845 (native-inputs
4846 `(("python-mock" ,python-mock)))
4847 (home-page "https://github.com/kmike/port-for/")
4848 (synopsis "TCP localhost port finder and association manager")
4849 (description
4850 "This package provides a utility that helps with local TCP ports
4851 management. It can find an unused TCP localhost port and remember the
4852 association.")
4853 (license license:expat)))
4854
4855 (define-public python-livereload
4856 (package
4857 (name "python-livereload")
4858 (version "2.6.1")
4859 (source
4860 (origin
4861 (method url-fetch)
4862 (uri (pypi-uri "livereload" version))
4863 (sha256
4864 (base32
4865 "0rhggz185bxc3zjnfpmhcvibyzi86i624za1lfh7x7ajsxw4y9c9"))))
4866 (build-system python-build-system)
4867 (propagated-inputs
4868 `(("python-six" ,python-six)
4869 ("python-tornado" ,python-tornado)))
4870 (home-page "https://github.com/lepture/python-livereload")
4871 (synopsis "Python LiveReload")
4872 (description
4873 "Python LiveReload provides a command line utility, @command{livereload},
4874 for starting a web server in a directory. It can trigger arbitrary commands
4875 and serve updated contents upon changes to the directory.")
4876 (license license:bsd-3)))
4877
4878 (define-public python-vf-1
4879 (package
4880 (name "python-vf-1")
4881 (version "0.0.11")
4882 (source
4883 (origin
4884 (method url-fetch)
4885 (uri (pypi-uri "VF-1" version))
4886 (sha256
4887 (base32
4888 "0xlqsaxsiayk1sd07kpz8abbcnab582y29a1y4882fq6j4gma5xi"))))
4889 (build-system python-build-system)
4890 (home-page "https://github.com/solderpunk/VF-1")
4891 (synopsis "Command line gopher client")
4892 (description "@code{VF-1} is a command line gopher client with
4893 @acronym{TLS, Transport Layer Security} support.")
4894 (license license:bsd-2)))
4895
4896 (define-public python-httpcore
4897 (package
4898 (name "python-httpcore")
4899 (version "0.12.2")
4900 (source
4901 (origin
4902 ;; PyPI tarball does not contain tests.
4903 (method git-fetch)
4904 (uri (git-reference
4905 (url "https://github.com/encode/httpcore")
4906 (commit version)))
4907 (file-name (git-file-name name version))
4908 (sha256
4909 (base32 "1nrwwfdqjfc2a1k3j41cdwkprwvplf95fwmypdl2aq2qgp3209q0"))))
4910 (build-system python-build-system)
4911 (arguments
4912 `(#:tests? #f ; Tests hang at 98%
4913 #:phases
4914 (modify-phases %standard-phases
4915 (replace 'check
4916 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
4917 (when tests?
4918 (add-installed-pythonpath inputs outputs)
4919 (invoke "pytest" "-vv" "--cov=httpcore"
4920 "--cov=tests" "tests"))
4921 #t)))))
4922 (native-inputs
4923 `(("python-autoflake" ,python-autoflake)
4924 ("python-flake8" ,python-flake8)
4925 ("python-flake8-bugbear" ,python-flake8-bugbear)
4926 ("python-flake8-pie" ,python-flake8-pie)
4927 ("python-isort" ,python-isort)
4928 ("python-mypy" ,python-mypy)
4929 ("python-pytest" ,python-pytest)
4930 ("python-pytest-asyncio" ,python-pytest-asyncio)
4931 ("python-pytest-cov" ,python-pytest-cov)
4932 ("python-pytest-trio" ,python-pytest-trio)
4933 ("python-uvicorn" ,python-uvicorn)
4934 ("python-trustme" ,python-trustme)))
4935 (propagated-inputs
4936 `(("python-h11" ,python-h11)
4937 ("python-h2" ,python-h2)
4938 ("python-sniffio" ,python-sniffio)
4939 ("python-trio" ,python-trio)
4940 ("python-trio-typing" ,python-trio-typing)))
4941 (home-page "https://github.com/encode/httpcore")
4942 (synopsis "Minimal, low-level HTTP client")
4943 (description
4944 "HTTP Core provides a minimal and low-level HTTP client, which does one
4945 thing only: send HTTP requests.
4946
4947 Some things HTTP Core does do:
4948
4949 @itemize
4950 @item Sending HTTP requests.
4951 @item Provides both sync and async interfaces.
4952 @item Supports HTTP/1.1 and HTTP/2.
4953 @item Async backend support for asyncio and trio.
4954 @item Automatic connection pooling.
4955 @item HTTP(S) proxy support.
4956 @end itemize")
4957 (license license:bsd-3)))
4958
4959 (define-public python-httpx
4960 (package
4961 (name "python-httpx")
4962 (version "0.16.1")
4963 (source
4964 (origin
4965 ;; PyPI tarball does not contain tests.
4966 (method git-fetch)
4967 (uri (git-reference
4968 (url "https://github.com/encode/httpx")
4969 (commit version)))
4970 (file-name (git-file-name name version))
4971 (sha256
4972 (base32 "00gmq45fckcqkj910bvd7pyqz1mvgsdvz4s0k7dzbnc5czzq1f4a"))))
4973 (build-system python-build-system)
4974 (arguments
4975 `(#:phases
4976 (modify-phases %standard-phases
4977 (replace 'check
4978 (lambda _
4979 (invoke "pytest" "-vv" "-k"
4980 ;; These tests try to open an outgoing connection.
4981 (string-append
4982 "not test_connect_timeout"
4983 " and not test_that_send_cause_async_client_to_be_not_"
4984 "closed"
4985 " and not test_that_async_client_caused_warning_when_"
4986 "being_deleted"
4987 " and not test_that_send_cause_client_to_be_not_closed"
4988 " and not test_async_proxy_close"
4989 " and not test_sync_proxy_close")))))))
4990 (native-inputs
4991 `(("python-autoflake" ,python-autoflake)
4992 ("python-black" ,python-black)
4993 ("python-cryptography" ,python-cryptography)
4994 ("python-flake8" ,python-flake8)
4995 ("python-flake8-bugbear" ,python-flake8-bugbear)
4996 ("python-flake8-pie" ,python-flake8-pie)
4997 ("python-isort" ,python-isort)
4998 ("python-mypy" ,python-mypy)
4999 ("python-pytest" ,python-pytest)
5000 ("python-pytest-asyncio" ,python-pytest-asyncio)
5001 ("python-pytest-trio" ,python-pytest-trio)
5002 ("python-pytest-cov" ,python-pytest-cov)
5003 ("python-trio" ,python-trio)
5004 ("python-trio-typing" ,python-trio-typing)
5005 ("python-trustme" ,python-trustme)
5006 ("python-uvicorn" ,python-uvicorn)))
5007 (propagated-inputs
5008 `(("python-brotli" ,python-brotli)
5009 ("python-certifi" ,python-certifi)
5010 ("python-chardet" ,python-chardet)
5011 ("python-httpcore" ,python-httpcore)
5012 ("python-idna" ,python-idna)
5013 ("python-rfc3986" ,python-rfc3986)
5014 ("python-sniffio" ,python-sniffio)))
5015 (home-page "https://www.python-httpx.org/")
5016 (synopsis "HTTP client for Python")
5017 (description
5018 "HTTPX is a fully featured HTTP client for Python 3, which provides sync
5019 and async APIs, and support for both HTTP/1.1 and HTTP/2.
5020
5021 HTTPX builds on the well-established usability of requests, and gives you:
5022
5023 @itemize
5024 @item A broadly requests-compatible API.
5025 @item Standard synchronous interface, but with async support if you need it.
5026 @item HTTP/1.1 and HTTP/2 support.
5027 @item Ability to make requests directly to WSGI applications or ASGI applications.
5028 @item Strict timeouts everywhere.
5029 @item Fully type annotated.
5030 @item 99% test coverage.
5031 @end itemize
5032
5033 Plus all the standard features of requests:
5034
5035 @itemize
5036 @item International Domains and URLs
5037 @item Keep-Alive & Connection Pooling
5038 @item Sessions with Cookie Persistence
5039 @item Browser-style SSL Verification
5040 @item Basic/Digest Authentication
5041 @item Elegant Key/Value Cookies
5042 @item Automatic Decompression
5043 @item Automatic Content Decoding
5044 @item Unicode Response Bodies
5045 @item Multipart File Uploads
5046 @item HTTP(S) Proxy Support
5047 @item Connection Timeouts
5048 @item Streaming Downloads
5049 @item .netrc Support
5050 @item Chunked Requests
5051 @end itemize")
5052 (license license:bsd-3)))
5053
5054 (define-public python-websockets
5055 (package
5056 (name "python-websockets")
5057 (version "8.1")
5058 (source
5059 (origin
5060 (method url-fetch)
5061 (uri (pypi-uri "websockets" version))
5062 (sha256
5063 (base32
5064 "03s3ml6sbki24aajllf8aily0xzrn929zxi84p50zkkbikdd4raw"))))
5065 (build-system python-build-system)
5066 (arguments '(#:tests? #f)) ; Tests not included in release tarball.
5067 (home-page "https://github.com/aaugustin/websockets")
5068 (synopsis
5069 "Python implementation of the WebSocket Protocol (RFC 6455 & 7692)")
5070 (description
5071 "@code{websockets} is a library for building WebSocket servers and clients
5072 in Python with a focus on correctness and simplicity.
5073
5074 Built on top of @code{asyncio}, Python's standard asynchronous I/O framework,
5075 it provides an elegant coroutine-based API.")
5076 (license license:bsd-3)))
5077
5078 (define-public python-selenium
5079 (package
5080 (name "python-selenium")
5081 (version "3.141.0")
5082 (source
5083 (origin
5084 (method url-fetch)
5085 (uri (pypi-uri "selenium" version))
5086 (sha256
5087 (base32
5088 "039hf9knvl4s3hp21bzwsp1g5ri9gxsh504dp48lc6nr1av35byy"))))
5089 (build-system python-build-system)
5090 (propagated-inputs
5091 `(("python-urllib3" ,python-urllib3)))
5092 (home-page
5093 "https://github.com/SeleniumHQ/selenium/")
5094 (synopsis "Python bindings for Selenium")
5095 (description "Selenium enables web browser automation.
5096 Selenium specifically provides infrastructure for the W3C WebDriver specification
5097 — a platform and language-neutral coding interface compatible with all
5098 major web browsers.")
5099 (license license:asl2.0)))
5100
5101 (define-public python-rapidjson
5102 (package
5103 (name "python-rapidjson")
5104 (version "0.9.1")
5105 (source
5106 (origin
5107 (method url-fetch)
5108 (uri (pypi-uri "python-rapidjson" version))
5109 (sha256
5110 (base32
5111 "18cl2dhx3gds5vg52jxmh9wjlbiy8dx06c3n482rfpdi9dzbv05d"))
5112 (modules '((guix build utils)))
5113 (snippet
5114 '(begin (delete-file-recursively "rapidjson") #t))))
5115 (build-system python-build-system)
5116 (arguments
5117 `(#:configure-flags
5118 (list (string-append "--rj-include-dir="
5119 (assoc-ref %build-inputs "rapidjson")
5120 "/include/rapidjson"))
5121 #:phases
5122 (modify-phases %standard-phases
5123 (replace 'build
5124 (lambda* (#:key inputs #:allow-other-keys)
5125 (invoke "python" "setup.py" "build"
5126 (string-append "--rj-include-dir="
5127 (assoc-ref %build-inputs "rapidjson")
5128 "/include/rapidjson"))))
5129 (replace 'check
5130 (lambda* (#:key inputs outputs #:allow-other-keys)
5131 (add-installed-pythonpath inputs outputs)
5132 ;; Some tests are broken.
5133 (delete-file "tests/test_base_types.py")
5134 (delete-file "tests/test_validator.py")
5135 (invoke "python" "-m" "pytest" "tests"))))))
5136 (native-inputs
5137 `(("rapidjson" ,rapidjson)
5138 ("python-pytest" ,python-pytest)
5139 ("python-pytz" ,python-pytz)))
5140 (home-page "https://github.com/python-rapidjson/python-rapidjson")
5141 (synopsis "Python wrapper around rapidjson")
5142 (description "This package provides a python wrapper around rapidjson.")
5143 (license license:expat)))
5144
5145 (define-public python-venusian
5146 (package
5147 (name "python-venusian")
5148 (version "3.0.0")
5149 (source
5150 (origin
5151 (method url-fetch)
5152 (uri (pypi-uri "venusian" version))
5153 (sha256
5154 (base32 "0f7f67dkgxxcjfhpdd5frb9pszkf04lyzzpn5069q0xi89r2p17n"))))
5155 (build-system python-build-system)
5156 (native-inputs
5157 `(("python-pytest" ,python-pytest)
5158 ("python-runner" ,python-pytest-runner)
5159 ("python-pytest-cov" ,python-pytest-cov)))
5160 (arguments '(#:test-target "pytest"))
5161 (home-page "https://docs.pylonsproject.org/projects/venusian")
5162 (synopsis "Library for deferring decorator actions")
5163 (description
5164 "Venusian is a library which allows framework authors to defer decorator
5165 actions. Instead of taking actions when a function (or class) decorator is
5166 executed at import time, you can defer the action usually taken by the
5167 decorator until a separate scan phase.")
5168 (license license:repoze)))
5169
5170 (define-public python-zope-deprecation
5171 (package
5172 (name "python-zope-deprecation")
5173 (version "4.4.0")
5174 (source (origin
5175 (method url-fetch)
5176 (uri (pypi-uri "zope.deprecation" version))
5177 (sha256
5178 (base32
5179 "1pz2cv7gv9y1r3m0bdv7ks1alagmrn5msm5spwdzkb2by0w36i8d"))))
5180 (build-system python-build-system)
5181 (native-inputs `())
5182 (propagated-inputs `())
5183 (home-page "https://zopedeprecation.readthedocs.io/")
5184 (synopsis "Function for marking deprecations")
5185 (description "The @code{zope.deprecation} module provides a function for
5186 marking modules, classes, functions, methods and properties as deprecated,
5187 displaying warnings when usaged in application code.")
5188 (license license:zpl2.1)))
5189
5190 (define-public python-translationstring
5191 (package
5192 (name "python-translationstring")
5193 (version "1.3")
5194 (source (origin
5195 (method url-fetch)
5196 (uri (pypi-uri "translationstring" version))
5197 (sha256
5198 (base32
5199 "0bdpcnd9pv0131dl08h4zbcwmgc45lyvq3pa224xwan5b3x4rr2f"))))
5200 (build-system python-build-system)
5201 (home-page "http://docs.pylonsproject.org/projects/translationstring")
5202 (synopsis "Internationalization tooling for the Pylons project")
5203 (description "This package provides a library used by various Pylons
5204 project packages for internationalization (i18n) duties related to
5205 translation.")
5206 (license license:repoze)))
5207
5208 (define-public python-plaster
5209 (package
5210 (name "python-plaster")
5211 (version "1.0")
5212 (source (origin
5213 (method url-fetch)
5214 (uri (pypi-uri "plaster" version))
5215 (sha256
5216 (base32
5217 "1hy8k0nv2mxq94y5aysk6hjk9ryb4bsd13g83m60hcyzxz3wflc3"))))
5218 (build-system python-build-system)
5219 (native-inputs
5220 `(("python-pytest" ,python-pytest)))
5221 (home-page "https://docs.pylonsproject.org/projects/plaster/en/latest/")
5222 (synopsis "Configuration loader for multiple config file formats")
5223 (description
5224 "Plaster is a loader interface around multiple config file formats. It
5225 exists to define a common API for applications to use when they wish to load
5226 configuration. The library itself does not aim to handle anything except a
5227 basic API that applications may use to find and load configuration settings.
5228 Any specific constraints should be implemented in a pluggable loader which can
5229 be registered via an entrypoint.")
5230 (license license:repoze)))
5231
5232 (define-public python-plaster-pastedeploy
5233 (package
5234 (name "python-plaster-pastedeploy")
5235 (version "0.7")
5236 (source (origin
5237 (method url-fetch)
5238 (uri (pypi-uri "plaster_pastedeploy" version))
5239 (sha256
5240 (base32
5241 "1zg7gcsvc1kzay1ry5p699rg2qavfsxqwl17mqxzr0gzw6j9679r"))))
5242 (build-system python-build-system)
5243 (native-inputs
5244 `(("python-pytest" ,python-pytest)))
5245 (propagated-inputs
5246 `(("python-plaster" ,python-plaster)
5247 ("python-pastedeploy" ,python-pastedeploy)))
5248 (home-page "https://github.com/Pylons/plaster_pastedeploy")
5249 (synopsis "Plugin for python-plaster adding PasteDeploy syntax")
5250 (description
5251 "This plugin for @code{python-plaster} adds support for PasteDeploy
5252 syntax, it provides a plaster @code{Loader} object that can parse ini files
5253 according to the standard set by PasteDeploy ")
5254 (license license:expat)))
5255
5256 (define-public python-hupper
5257 (package
5258 (name "python-hupper")
5259 (version "1.10.2")
5260 (source (origin
5261 (method url-fetch)
5262 (uri (pypi-uri "hupper" version))
5263 (sha256
5264 (base32
5265 "0am0p6g5cz6xmcaf04xq8q6dzdd9qz0phj6gcmpsckf2mcyza61q"))))
5266 (build-system python-build-system)
5267 (arguments '(#:test-target "pytest"))
5268 (native-inputs
5269 `(("python-pytest" ,python-pytest)
5270 ("python-pytest-runner" ,python-pytest-runner)
5271 ("python-watchdog" ,python-watchdog)
5272 ("python-mock" ,python-mock)
5273 ("python-pytest-cov" ,python-pytest-cov)))
5274 (propagated-inputs
5275 `(("python-pytz" ,python-pytz)))
5276 (home-page "https://readthedocs.org/projects/hupper")
5277 (synopsis "Integrated process monitor tracking changes to imported Python files")
5278 (description
5279 "Hupper is an integrated process monitor that will track changes to any
5280 imported Python files in sys.modules as well as custom paths. When files are
5281 changed the process is restarted.")
5282 (license license:expat)))
5283
5284 (define-public python-pyramid
5285 (package
5286 (name "python-pyramid")
5287 (version "1.10.4")
5288 (source (origin
5289 (method url-fetch)
5290 (uri (pypi-uri "pyramid" version))
5291 (sha256
5292 (base32
5293 "0rkxs1ajycg2zh1c94xlmls56mx5m161sn8112skj0amza6cn36q"))))
5294 (build-system python-build-system)
5295 (propagated-inputs
5296 `(("python-hupper" ,python-hupper)
5297 ("python-plaster-pastedeploy" ,python-plaster-pastedeploy)
5298 ("python-translationstring" ,python-translationstring)
5299 ("python-venusian" ,python-venusian)
5300 ("python-webob" ,python-webob)
5301 ("python-zope-deprecation" ,python-zope-deprecation)
5302 ("python-zope-interface" ,python-zope-interface)
5303 ("python-webtest" ,python-webtest)
5304 ("python-zope-component" ,python-zope-component)
5305 ("python-plaster" ,python-plaster)))
5306 (home-page "https://trypyramid.com/")
5307 (synopsis "Python web-framework suitable for small and large sites")
5308 (description
5309 "Pyramid makes it easy to write web applications. From minimal
5310 request/response web apps to larger, grown applications.")
5311 (license license:repoze)))
5312
5313 (define-public python-random-user-agent
5314 (package
5315 (name "python-random-user-agent")
5316 (version "1.0.1")
5317 (source
5318 (origin
5319 (method url-fetch)
5320 (uri (pypi-uri "random_user_agent" version))
5321 (sha256
5322 (base32
5323 "04nhzdh2ki7ybhjrmghxci6hcm6i03vvin2q2ynj87fbr1pa534g"))))
5324 (build-system python-build-system)
5325 (home-page "https://github.com/Luqman-Ud-Din/random_user_agent")
5326 (synopsis "List of user agents")
5327 (description
5328 "This package provides a list of user agents, from a collection of more
5329 than 326,000 known user-agents. Users can pick a random one, or select one
5330 based on filters.")
5331 (license license:expat)))
5332
5333 (define-public python-flask-restx
5334 (package
5335 (name "python-flask-restx")
5336 (version "0.2.0")
5337 (source
5338 ;; We fetch from the Git repo because there are no tests in the PyPI
5339 ;; archive.
5340 (origin
5341 (method git-fetch)
5342 (uri (git-reference
5343 (url "https://github.com/python-restx/flask-restx")
5344 (commit version)))
5345 (file-name (git-file-name name version))
5346 (sha256
5347 (base32 "0xf2vkmdngp9cv9klznizai4byxjcf0iqh1pr4b83nann0jxqwy7"))))
5348 (build-system python-build-system)
5349 (propagated-inputs
5350 `(("python-aniso8601" ,python-aniso8601)
5351 ("python-flask" ,python-flask)
5352 ("python-jsonschema" ,python-jsonschema)
5353 ("python-pytz" ,python-pytz)))
5354 (native-inputs
5355 `(("python-blinker" ,python-blinker)
5356 ("python-faker" ,python-faker)
5357 ("python-pytest" ,python-pytest)
5358 ("python-pytest-benchmark"
5359 ,python-pytest-benchmark)
5360 ("python-pytest-flask" ,python-pytest-flask)
5361 ("python-pytest-mock" ,python-pytest-mock)))
5362 (arguments
5363 `(#:phases
5364 (modify-phases %standard-phases
5365 (replace 'check
5366 (lambda _
5367 (invoke "pytest" "--benchmark-skip" "-k"
5368 ;; Those tests need internet access
5369 "not test_check and not test_valid_value_check"))))))
5370 (home-page "https://github.com/python-restx/flask-restx")
5371 (synopsis
5372 "Framework for fast, easy and documented API development with Flask")
5373 (description
5374 "Flask-RESTX is an extension for Flask that adds support for quickly building
5375 REST APIs. Flask-RESTX encourages best practices with minimal setup. If you are familiar
5376 with Flask, Flask-RESTX should be easy to pick up. It provides a coherent collection of
5377 decorators and tools to describe your API and expose its documentation properly using
5378 Swagger.")
5379 (license license:bsd-3)))
5380
5381 (define-public python-manuel
5382 (package
5383 (name "python-manuel")
5384 (version "1.10.1")
5385 (source
5386 (origin
5387 (method url-fetch)
5388 (uri (pypi-uri "manuel" version))
5389 (sha256
5390 (base32
5391 "1bdzay7j70fly5fy6wbdi8fbrxjrrlxnxnw226rwry1c8a351rpy"))))
5392 (build-system python-build-system)
5393 (propagated-inputs
5394 `(("python-six" ,python-six)))
5395 (native-inputs
5396 `(("python-zope-testing" ,python-zope-testing)))
5397 (home-page "https://pypi.org/project/manuel/")
5398 (synopsis "Build tested documentation")
5399 (description
5400 "Manuel lets you mix and match traditional doctests with custom test syntax.")
5401 (license license:asl2.0)))
5402
5403 (define-public python-persistent
5404 (package
5405 (name "python-persistent")
5406 (version "4.6.4")
5407 (source
5408 (origin
5409 (method url-fetch)
5410 (uri (pypi-uri "persistent" version))
5411 (sha256
5412 (base32
5413 "0imm9ji03lhkpcfmhid7x5209ix8g2rlgki9ik1qxks4b8sm8gzq"))))
5414 (build-system python-build-system)
5415 (propagated-inputs
5416 `(("python-cffi" ,python-cffi)
5417 ("python-zope-interface" ,python-zope-interface)))
5418 (native-inputs
5419 `(("python-manuel" ,python-manuel)
5420 ("python-zope-testrunner" ,python-zope-testrunner)))
5421 (home-page "https://github.com/zopefoundation/persistent/")
5422 (synopsis "Translucent persistent objects")
5423 (description "This package contains a generic persistence implementation for
5424 Python. It forms the core protocol for making objects interact
5425 \"transparently\" with a database such as the ZODB.")
5426 (license license:zpl2.1)))
5427
5428 (define-public python-btrees
5429 (package
5430 (name "python-btrees")
5431 (version "4.7.2")
5432 (source
5433 (origin
5434 (method url-fetch)
5435 (uri (pypi-uri "BTrees" version))
5436 (sha256
5437 (base32
5438 "0iiq0g9k1g6qgqq84q9h6639vlvzznk1rgdm0rfcnnqkbkmsbr3w"))))
5439 (build-system python-build-system)
5440 (propagated-inputs
5441 `(("python-persistent" ,python-persistent)
5442 ("python-zope-interface" ,python-zope-interface)))
5443 (native-inputs
5444 `(("python-persistent" ,python-persistent)
5445 ("python-transaction" ,python-transaction)
5446 ("python-zope-testrunner" ,python-zope-testrunner)))
5447 (home-page "https://github.com/zopefoundation/BTrees")
5448 (synopsis "Scalable persistent object containers")
5449 (description
5450 "This package contains a set of persistent object containers built around a
5451 modified BTree data structure. The trees are optimized for use inside ZODB's
5452 \"optimistic concurrency\" paradigm, and include explicit resolution of
5453 conflicts detected by that mechanism.")
5454 (license license:zpl2.1)))
5455
5456 (define-public python-transaction
5457 (package
5458 (name "python-transaction")
5459 (version "3.0.0")
5460 (source
5461 (origin
5462 (method url-fetch)
5463 (uri (pypi-uri "transaction" version))
5464 (sha256
5465 (base32
5466 "0bdaks31bgfh78wnj3sij24bfysmqk25crsis6amz8kzrc0d82iv"))))
5467 (build-system python-build-system)
5468 (propagated-inputs
5469 `(("python-zope-interface" ,python-zope-interface)))
5470 (native-inputs
5471 `(("python-coverage" ,python-coverage)
5472 ("python-mock" ,python-mock)
5473 ("python-nose" ,python-nose)))
5474 (home-page "https://github.com/zopefoundation/transaction")
5475 (synopsis "Transaction management for Python")
5476 (description "This package contains a generic transaction implementation
5477 for Python. It is mainly used by the ZODB.")
5478 (license license:zpl2.1)))
5479
5480 (define-public python-robot-detection
5481 (package
5482 (name "python-robot-detection")
5483 (version "0.4")
5484 (source
5485 (origin
5486 (method url-fetch)
5487 (uri (pypi-uri "robot-detection" version))
5488 (sha256
5489 (base32
5490 "1xd2jm3yn31bnk1kqzggils2rxj26ylxsfz3ap7bhr3ilhnbg3rx"))))
5491 (build-system python-build-system)
5492 (arguments '(#:tests? #f)) ; Tests not shipped in pypi release.
5493 (propagated-inputs `(("python-six" ,python-six)))
5494 (home-page "https://github.com/rory/robot-detection")
5495 (synopsis "Detect web crawlers")
5496 (description
5497 "@code{robot_detection} is a python module to detect if a given HTTP User
5498 Agent is a web crawler. It uses the list of registered robots from
5499 @url{http://www.robotstxt.org}.")
5500 (license license:gpl3+)))
5501
5502 (define-public python-pysolr
5503 (package
5504 (name "python-pysolr")
5505 (version "3.9.0")
5506 (source
5507 (origin
5508 (method url-fetch)
5509 (uri (pypi-uri "pysolr" version))
5510 (sha256
5511 (base32
5512 "1rj5jmscvxjwcmlfi6hmkj44l4x6n3ln5p7d8d18j566hzmmzw3f"))))
5513 (build-system python-build-system)
5514 (arguments
5515 '(#:tests? #f)) ; Tests require network access.
5516 (propagated-inputs
5517 `(("python-requests" ,python-requests)))
5518 (native-inputs
5519 `(("python-setuptools-scm" ,python-setuptools-scm)))
5520 (home-page "https://github.com/django-haystack/pysolr/")
5521 (synopsis "Lightweight python wrapper for Apache Solr")
5522 (description
5523 "This module provides an interface that queries the Apache Solr server
5524 using a pure Python implementation.")
5525 (license license:bsd-3)))
5526
5527 (define-public python-http-ece
5528 (package
5529 (name "python-http-ece")
5530 (version "1.1.0")
5531 (source
5532 (origin
5533 (method git-fetch)
5534 (uri (git-reference
5535 (url "https://github.com/web-push-libs/encrypted-content-encoding")
5536 (commit (string-append "v" version))))
5537 (file-name (git-file-name name version))
5538 (sha256
5539 (base32
5540 "0bp4cc0xc123i72h80ax3qz3ixfwx3j7pw343kc7i6kdvfi8klx7"))))
5541 (build-system python-build-system)
5542 (arguments
5543 `(#:phases
5544 (modify-phases %standard-phases
5545 (add-after 'unpack 'change-directory
5546 (lambda _ (chdir "python") #t)))))
5547 (propagated-inputs
5548 `(("python-cryptography" ,python-cryptography)))
5549 (native-inputs
5550 `(("python-coverage" ,python-coverage)
5551 ("python-flake8" ,python-flake8)
5552 ("python-mock" ,python-mock)
5553 ("python-nose" ,python-nose)))
5554 (home-page "https://github.com/web-push-libs/encrypted-content-encoding")
5555 (synopsis "Encrypted Content Encoding for HTTP")
5556 (description
5557 "This package provices a simple implementation of Encrypted Content
5558 Encoding for HTTP.")
5559 (license license:expat)))
5560
5561 (define-public python-cloudscraper
5562 (package
5563 (name "python-cloudscraper")
5564 (version "1.2.48")
5565 (source
5566 (origin
5567 (method url-fetch)
5568 (uri (pypi-uri "cloudscraper" version))
5569 (sha256
5570 (base32 "0qjxzb0z5bprvmdhx42ayqhlhi2h49d9dwc0vvycj817s71f2sxv"))
5571 (modules '((guix build utils)))
5572 (snippet
5573 '(with-directory-excursion "cloudscraper"
5574 (for-each delete-file
5575 '("captcha/2captcha.py"
5576 "captcha/9kw.py"
5577 "captcha/anticaptcha.py"
5578 "captcha/deathbycaptcha.py"))
5579 (substitute* "__init__.py"
5580 ;; Perhaps it's a joke, but don't promote proprietary software.
5581 (("([Th]is feature is not available) in the .*'" _ prefix)
5582 (string-append prefix ".'")))
5583 #t))))
5584 (build-system python-build-system)
5585 (arguments
5586 `(#:phases
5587 (modify-phases %standard-phases
5588 ;; XXX: Dependencies, that have not yet been packaged
5589 ;; and cause an import error when included.
5590 (add-after 'unpack 'drop-unsupported-sources
5591 (lambda _
5592 (with-directory-excursion "cloudscraper"
5593 (for-each delete-file
5594 '("interpreters/js2py.py"
5595 "interpreters/v8.py")))
5596 #t)))))
5597 (propagated-inputs
5598 `(("python-requests" ,python-requests)
5599 ("python-requests-toolbelt" ,python-requests-toolbelt-0.9.1)
5600 ("python-pyparsing" ,python-pyparsing-2.4.7)))
5601 (native-inputs
5602 `(("python-pytest" ,python-pytest)))
5603 (home-page "https://github.com/venomous/cloudscraper")
5604 (synopsis "Cloudflare anti-bot bypass")
5605 (description
5606 "This module acts as a webbrowser solving Cloudflare's Javascript
5607 challenges.")
5608 (license license:expat)))
5609
5610 (define-public python-imap-tools
5611 (package
5612 (name "python-imap-tools")
5613 (version "0.29.0")
5614 (source
5615 (origin
5616 (method url-fetch)
5617 (uri (pypi-uri "imap_tools" version))
5618 (sha256
5619 (base32
5620 "0x122jwpc74wwyw2rsv2fvh6p12y31019ndfr9717jzjkj2d3lhb"))))
5621 (build-system python-build-system)
5622 (arguments '(#:tests? #f)) ; tests require internet access
5623 (home-page "https://github.com/ikvk/imap_tools")
5624 (synopsis "Work with email and mailbox by IMAP")
5625 (description
5626 "This Python library provides tools to deal with email and mailboxes
5627 over IMAP:
5628
5629 @itemize
5630 @item Parsed email message attributes
5631 @item Query builder for searching emails
5632 @item Work with emails in folders (copy, delete, flag, move, seen)
5633 @item Work with mailbox folders (list, set, get, create, exists, rename, delete, status)
5634 @end itemize")
5635 (license license:asl2.0)))
5636
5637 (define-public python-hstspreload
5638 (package
5639 (name "python-hstspreload")
5640 (version "2020.10.20")
5641 (source
5642 (origin
5643 (method url-fetch)
5644 (uri (pypi-uri "hstspreload" version))
5645 (sha256
5646 (base32
5647 "1qah80p2xlib1rhivvdj9v5y3girxrj7dwp1mnh8mwaj5wy32y8a"))))
5648 (build-system python-build-system)
5649 (home-page
5650 "https://github.com/sethmlarson/hstspreload")
5651 (synopsis
5652 "Chromium HSTS Preload list as a Python package")
5653 (description
5654 "@code{python-hstspreload} contains Chromium HSTS Preload list
5655 as a Python package.")
5656 (license license:bsd-3)))
5657
5658 (define-public python-sanic
5659 (package
5660 (name "python-sanic")
5661 (version "20.9.1")
5662 (source
5663 (origin
5664 (method url-fetch)
5665 (uri (pypi-uri "sanic" version))
5666 (sha256
5667 (base32
5668 "06p0lsxqbfbka2yaqlpp0bg5pf7ma44zi6kq7qbb6hhry48dp1w6"))))
5669 (build-system python-build-system)
5670 (arguments
5671 '(#:phases
5672 (modify-phases %standard-phases
5673 (add-after 'unpack 'use-recent-pytest
5674 ;; Allow using recent dependencies.
5675 (lambda* (#:key inputs #:allow-other-keys)
5676 (substitute* "setup.py"
5677 (("httpcore==0.3.0") "httpcore")
5678 (("pytest==5.2.1") "pytest")
5679 (("multidict==5.0.0") "multidict")
5680 (("httpx==0\\.15\\.4") "httpx"))
5681 #t))
5682 (replace 'check
5683 (lambda* (#:key inputs outputs #:allow-other-keys)
5684 (add-installed-pythonpath inputs outputs)
5685 (invoke "pytest" "-vv" "./tests" "-k"
5686 "not test_zero_downtime and not test_gunicorn_worker"))))))
5687 (propagated-inputs
5688 `(("python-aiofiles" ,python-aiofiles)
5689 ("python-httptools" ,python-httptools)
5690 ("python-httpx" ,python-httpx)
5691 ("python-multidict" ,python-multidict)
5692 ("python-ujson" ,python-ujson)
5693 ("python-uvloop" ,python-uvloop)
5694 ("python-websockets" ,python-websockets)))
5695 (native-inputs
5696 `(("gunicorn" ,gunicorn)
5697 ("python-beautifulsoup4" ,python-beautifulsoup4)
5698 ("python-hstspreload" ,python-hstspreload)
5699 ("python-httpcore" ,python-httpcore)
5700 ("python-pytest" ,python-pytest)
5701 ("python-pytest-cov" ,python-pytest-cov)
5702 ("python-pytest-benchmark" ,python-pytest-benchmark)
5703 ("python-pytest-sanic" ,python-pytest-sanic)
5704 ("python-pytest-sugar" ,python-pytest-sugar)
5705 ("python-urllib3" ,python-urllib3)
5706 ("python-uvicorn" ,python-uvicorn)))
5707 (home-page
5708 "https://github.com/huge-success/sanic/")
5709 (synopsis
5710 "Async Python 3.6+ web server/framework")
5711 (description
5712 "Sanic is a Python 3.6+ web server and web framework
5713 that's written to go fast. It allows the usage of the
5714 @code{async/await} syntax added in Python 3.5, which makes
5715 your code non-blocking and speedy.")
5716 (license license:expat)))
5717
5718 (define-public python-socks
5719 (package
5720 (name "python-socks")
5721 (version "1.1.2")
5722 (source
5723 (origin
5724 (method url-fetch)
5725 (uri (pypi-uri "python-socks" version))
5726 (sha256
5727 (base32
5728 "06mgv3icsyglv50w3sb71x6cpbskza20pqd93l5xk59x574i6xgs"))))
5729 (build-system python-build-system)
5730 (arguments
5731 `(#:tests? #f ; tests not included
5732 #:phases
5733 (modify-phases %standard-phases
5734 (replace 'check
5735 (lambda* (#:key tests? #:allow-other-keys)
5736 (when tests?
5737 (invoke "pytest" "tests/" "-s"))
5738 #t)))))
5739 (propagated-inputs
5740 `(("python-async-timeout" ,python-async-timeout)
5741 ("python-curio" ,python-curio)
5742 ("python-trio" ,python-trio)))
5743 (native-inputs
5744 `(("python-pytest" ,python-pytest)))
5745 (home-page "https://github.com/romis2012/python-socks")
5746 (synopsis
5747 "Core proxy (SOCKS4, SOCKS5, HTTP tunneling) functionality for Python")
5748 (description
5749 "Socks is a library providing core proxy (SOCKS4, SOCKS5, HTTP tunneling)
5750 functionality.")
5751 (license license:asl2.0)))