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