gnu: python-zope-i18nmessageid: Update to 5.0.1.
[jackhill/guix/guix.git] / gnu / packages / python-web.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
3 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
4 ;;; Copyright © 2017 Christopher Baines <mail@cbaines.net>
5 ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
6 ;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
7 ;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com>
8 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
10 ;;; Copyright © 2016, 2017, 2020 Julien Lepiller <julien@lepiller.eu>
11 ;;; Copyright © 2016, 2017 ng0 <ng0@n0.is>
12 ;;; Copyright © 2014, 2017 Eric Bavier <bavier@member.fsf.org>
13 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
14 ;;; Copyright © 2015 Cyril Roelandt <tipecaml@gmail.com>
15 ;;; Copyright © 2015, 2016, 2017, 2019 Leo Famulari <leo@famulari.name>
16 ;;; Copyright © 2016, 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
17 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
18 ;;; Copyright © 2015, 2017 Ben Woodcroft <donttrustben@gmail.com>
19 ;;; Copyright © 2015, 2016 Christopher Allan Webber <cwebber@dustycloud.org>
20 ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com>
21 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
22 ;;; Copyright © 2016 David Craven <david@craven.ch>
23 ;;; Copyright © 2017 Oleg Pykhalov <go.wigust@gmail.com>
24 ;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org>
25 ;;; Copyright © 2017 Mark Meyer <mark@ofosos.org>
26 ;;; Copyright © 2018 Tomáš Čech <sleep_walker@gnu.org>
27 ;;; Copyright © 2018, 2019 Nicolas Goaziou <mail@nicolasgoaziou.fr>
28 ;;; Copyright © 2018 Mathieu Othacehe <m.othacehe@gmail.com>
29 ;;; Copyright © 2018 Maxim Cournoyer <maxim.cournoyer@gmail.com>
30 ;;; Copyright © 2019 Vagrant Cascadian <vagrant@debian.org>
31 ;;; Copyright © 2019 Brendan Tildesley <mail@brendan.scot>
32 ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
33 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
34 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
35 ;;; Copyright © 2020 Evan Straw <evan.straw99@gmail.com>
36 ;;;
37 ;;; This file is part of GNU Guix.
38 ;;;
39 ;;; GNU Guix is free software; you can redistribute it and/or modify it
40 ;;; under the terms of the GNU General Public License as published by
41 ;;; the Free Software Foundation; either version 3 of the License, or (at
42 ;;; your option) any later version.
43 ;;;
44 ;;; GNU Guix is distributed in the hope that it will be useful, but
45 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
46 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
47 ;;; GNU General Public License for more details.
48 ;;;
49 ;;; You should have received a copy of the GNU General Public License
50 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
51
52 (define-module (gnu packages python-web)
53 #:use-module (guix packages)
54 #:use-module (guix download)
55 #:use-module (guix git-download)
56 #:use-module (guix build-system python)
57 #:use-module (guix utils)
58 #:use-module (gnu packages)
59 #:use-module (gnu packages base)
60 #:use-module (gnu packages check)
61 #:use-module (gnu packages compression)
62 #:use-module (gnu packages curl)
63 #:use-module (gnu packages databases)
64 #:use-module (gnu packages django)
65 #:use-module (gnu packages groff)
66 #:use-module (gnu packages libffi)
67 #:use-module (gnu packages pkg-config)
68 #:use-module (gnu packages python)
69 #:use-module (gnu packages python-check)
70 #:use-module (gnu packages python-crypto)
71 #:use-module (gnu packages python-xyz)
72 #:use-module (gnu packages serialization)
73 #:use-module (gnu packages sphinx)
74 #:use-module (gnu packages texinfo)
75 #:use-module (gnu packages tls)
76 #:use-module (gnu packages time)
77 #:use-module (gnu packages web)
78 #:use-module (gnu packages xml)
79 #:use-module ((guix licenses) #:prefix license:)
80 #:use-module (srfi srfi-1))
81
82 (define-public python-aiohttp
83 (package
84 (name "python-aiohttp")
85 (version "3.6.2")
86 (source
87 (origin
88 (method url-fetch)
89 (uri (pypi-uri "aiohttp" version))
90 (sha256
91 (base32
92 "09pkw6f1790prnrq0k8cqgnf1qy57ll8lpmc6kld09q7zw4vi6i5"))))
93 (build-system python-build-system)
94 (arguments
95 `(#:tests? #f)) ;missing pytest-timeout
96 (propagated-inputs
97 `(("python-aiodns" ,python-aiodns)
98 ("python-async-timeout" ,python-async-timeout)
99 ("python-attrs" ,python-attrs)
100 ("python-chardet" ,python-chardet)
101 ("python-idna-ssl" ,python-idna-ssl)
102 ("python-multidict" ,python-multidict)
103 ("python-yarl" ,python-yarl)))
104 (home-page "https://github.com/aio-libs/aiohttp/")
105 (synopsis "Async HTTP client/server framework (asyncio)")
106 (description "@code{aiohttp} is an asynchronous HTTP client/server
107 framework.
108
109 Its main features are:
110 @itemize
111 @item Supports both client and server side of HTTP protocol.
112 @item Supports both client and server Web-Sockets out-of-the-box without the
113 Callback Hell.
114 @item Web-server has middlewares and pluggable routing.
115 @end itemize")
116 (license license:asl2.0)))
117
118 (define-public python-aiohttp-socks
119 (package
120 (name "python-aiohttp-socks")
121 (version "0.2.2")
122 (source
123 (origin
124 (method url-fetch)
125 (uri (pypi-uri "aiohttp_socks" version))
126 (sha256
127 (base32
128 "0473702jk66xrgpm28wbdgpnak4v0dh2qmdjw7ky7hf3lwwqkggf"))))
129 (build-system python-build-system)
130 (propagated-inputs
131 `(("python-aiohttp" ,python-aiohttp)))
132 (home-page "https://github.com/romis2012/aiohttp-socks")
133 (synopsis "SOCKS proxy connector for aiohttp")
134 (description "This package provides a SOCKS proxy connector for
135 aiohttp. It supports SOCKS4(a) and SOCKS5.")
136 (license license:asl2.0)))
137
138 (define-public python-aiodns
139 (package
140 (name "python-aiodns")
141 (version "1.1.1")
142 (source
143 (origin
144 (method url-fetch)
145 (uri (pypi-uri "aiodns" version))
146 (sha256
147 (base32
148 "1snr5paql8dgvc676n8xq460wypjsb1xj53cf3px1s4wczf7lryq"))))
149 (build-system python-build-system)
150 (inputs
151 `(("python-pycares" ,python-pycares)))
152 (arguments
153 `(#:tests? #f)) ;tests require internet access
154 (home-page "http://github.com/saghul/aiodns")
155 (synopsis "Simple DNS resolver for asyncio")
156 (description "@code{aiodns} provides a simple way for doing
157 asynchronous DNS resolutions with a synchronous looking interface by
158 using @url{https://github.com/saghul/pycares,pycares}.")
159 (license license:expat)))
160
161 (define-public python-aiorpcx
162 (package
163 (name "python-aiorpcx")
164 (version "0.18.3")
165 (source
166 (origin
167 (method url-fetch)
168 (uri (pypi-uri "aiorpcX" version))
169 (sha256
170 (base32
171 "0k545hc7wl6sh1svydzbv6x7sx5pig2pqkl3yxs9riwmvzawx9xp"))))
172 (build-system python-build-system)
173 (propagated-inputs
174 `(("python-attrs" ,python-attrs)))
175 (home-page "https://github.com/kyuupichan/aiorpcX")
176 (synopsis "Generic asyncio RPC implementation")
177 (description
178 "The aiorpcX library is a generic asyncio implementation of RPC suitable
179 for an application that is a client, server or both.
180
181 The package includes a module with full coverage of JSON RPC versions 1.0 and
182 2.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
183 comes with a SOCKS proxy client.")
184 (license (list license:expat license:bsd-2))))
185
186 (define-public python-falcon
187 (package
188 (name "python-falcon")
189 (version "1.4.1")
190 (source
191 (origin
192 (method url-fetch)
193 (uri (pypi-uri "falcon" version))
194 (sha256
195 (base32
196 "1i0vmqsk24z4biirqhpvas9h28wy7nmpy3jvnb6rz2imq04zd09r"))))
197 (build-system python-build-system)
198 (arguments
199 `(#:phases
200 (modify-phases %standard-phases
201 (replace 'check
202 (lambda _
203 (invoke "pytest"))))))
204 (propagated-inputs
205 `(("python-mimeparse" ,python-mimeparse)
206 ("python-six" ,python-six)))
207 (native-inputs
208 `(("python-cython" ,python-cython) ;for faster binaries
209 ("python-pytest" ,python-pytest)
210 ("python-pyyaml" ,python-pyyaml)
211 ("python-requests" ,python-requests)
212 ("python-testtools" ,python-testtools)
213 ("python-jsonschema" ,python-jsonschema)
214 ("python-msgpack" ,python-msgpack)))
215 (home-page "https://falconframework.org")
216 (synopsis
217 "Web framework for building APIs and application backends")
218 (description
219 "Falcon is a web API framework for building microservices, application
220 backends and higher-level frameworks. Among its features are:
221 @itemize
222 @item Optimized and extensible code base
223 @item Routing via URI templates and REST-inspired resource
224 classes
225 @item Access to headers and bodies through request and response
226 classes
227 @item Request processing via middleware components and hooks
228 @item Idiomatic HTTP error responses
229 @item Straightforward exception handling
230 @item Unit testing support through WSGI helpers and mocks
231 @item Compatible with both CPython and PyPy
232 @item Cython support for better performance when used with CPython
233 @end itemize")
234 (license license:asl2.0)))
235
236 (define-public python2-falcon
237 (package-with-python2 python-falcon))
238
239 (define-public python-falcon-cors
240 (package
241 (name "python-falcon-cors")
242 (version "1.1.7")
243 (source
244 (origin
245 (method url-fetch)
246 (uri (pypi-uri "falcon-cors" version))
247 (sha256
248 (base32
249 "12pym7hwsbd8b0c1azn95nas8gm3f1qpr6lpyx0958xm65ffr20p"))))
250 (build-system python-build-system)
251 (native-inputs
252 `(("python-falcon" ,python-falcon)))
253 (home-page
254 "https://github.com/lwcolton/falcon-cors")
255 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
256 (description "This middleware provides @dfn{cross-origin resource
257 sharing} (CORS) support for Falcon. It allows applying a specially crafted
258 CORS object to the incoming requests, enabling the ability to serve resources
259 over a different origin than that of the web application.")
260 (license license:asl2.0)))
261
262 (define-public python2-falcon-cors
263 (package-with-python2 python-falcon-cors))
264
265 (define-public python-furl
266 (package
267 (name "python-furl")
268 (version "0.5.6")
269 (source
270 (origin
271 (method url-fetch)
272 (uri (pypi-uri "furl" version))
273 (sha256
274 (base32
275 "0lzpfpm686hvz3sr1mcrnd1b3lgmnw8v59gb43wfi98r3b671pqc"))))
276 (build-system python-build-system)
277 (propagated-inputs
278 `(("python-six" ,python-six)
279 ("python-orderedmultidict" ,python-orderedmultidict)))
280 (native-inputs
281 `(("python-pycodestyle" ,python-pycodestyle)))
282 (home-page "https://github.com/gruns/furl")
283 (synopsis "URL manipulation in Python")
284 (description "Furl provides an easy-to-use alternative to the
285 @code{urllib} and @code{urlparse} modules for manipulating URLs.")
286 (license license:unlicense)))
287
288 (define-public python2-furl
289 (package-with-python2 python-furl))
290
291 (define-public python-httplib2
292 (package
293 (name "python-httplib2")
294 (version "0.9.2")
295 (source
296 (origin
297 (method url-fetch)
298 (uri (pypi-uri "httplib2" version))
299 (sha256
300 (base32
301 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
302 (build-system python-build-system)
303 (home-page "https://github.com/jcgregorio/httplib2")
304 (synopsis "Comprehensive HTTP client library")
305 (description
306 "A comprehensive HTTP client library supporting many features left out of
307 other HTTP libraries.")
308 (license license:expat)))
309
310 (define-public python2-httplib2
311 (package-with-python2 python-httplib2))
312
313 (define-public httpie
314 (package
315 (name "httpie")
316 (version "2.0.0")
317 (source
318 (origin
319 (method url-fetch)
320 (uri (pypi-uri "httpie" version))
321 (sha256
322 (base32
323 "02bw20cwv3a1lzrn919dk25dq4v81x6q786zlrqsqzhsdxszj14c"))))
324 (build-system python-build-system)
325 (arguments
326 ;; The tests attempt to access external web servers, so we cannot run them.
327 '(#:tests? #f))
328 (propagated-inputs
329 `(("python-colorama" ,python-colorama)
330 ("python-pygments" ,python-pygments)
331 ("python-requests" ,python-requests)))
332 (home-page "https://httpie.org/")
333 (synopsis "cURL-like tool for humans")
334 (description
335 "A command line HTTP client with an intuitive UI, JSON support,
336 syntax highlighting, wget-like downloads, plugins, and more. It consists of
337 a single http command designed for painless debugging and interaction with
338 HTTP servers, RESTful APIs, and web services.")
339 (license license:bsd-3)))
340
341 (define-public python-html2text
342 (package
343 (name "python-html2text")
344 (version "2019.8.11")
345 (source
346 (origin
347 (method url-fetch)
348 (uri (pypi-uri "html2text" version))
349 (sha256
350 (base32
351 "0ppgjplg06kmv9sj0x8p7acczcq2mcfgk1jdjwm4w5w40b0vj5pm"))))
352 (build-system python-build-system)
353 (arguments
354 '(#:phases
355 (modify-phases %standard-phases
356 (replace 'check
357 (lambda _
358 (invoke "pytest" "test/"))))))
359 (native-inputs
360 `(("python-pytest" ,python-pytest)))
361 (home-page "https://github.com/Alir3z4/html2text")
362 (synopsis "Convert HTML into plain text")
363 (description "html2text takes HTML and converts it into plain ASCII text
364 which is also valid markdown. html2text was originally written by Aaron
365 Swartz.")
366 (license license:gpl3+)))
367
368 (define-public python2-html2text
369 (package-with-python2 python-html2text))
370
371 (define-public python-mechanicalsoup
372 (package
373 (name "python-mechanicalsoup")
374 (version "0.11.0")
375 (source
376 (origin
377 (method url-fetch)
378 (uri (pypi-uri "MechanicalSoup" version))
379 (sha256
380 (base32 "0k59wwk75q7nz6i6gynvzhagy02ql0bv7py3qqcwgjw7607yq4i7"))))
381 (build-system python-build-system)
382 (arguments
383 ;; TODO: Enable tests when python-flake8@3.5 hits master.
384 `(#:tests? #f))
385 (propagated-inputs
386 `(("python-beautifulsoup4" ,python-beautifulsoup4)
387 ("python-lxml" ,python-lxml)
388 ("python-requests" ,python-requests)
389 ("python-six" ,python-six)))
390 ;; (native-inputs
391 ;; ;; For tests.
392 ;; `(("python-pytest-flake8" ,python-pytest-flake8)
393 ;; ("python-pytest-httpbin" ,python-pytest-httpbin)
394 ;; ("python-pytest-mock" ,python-pytest-mock)
395 ;; ("python-pytest-runner" ,python-pytest-runner)
396 ;; ("python-requests-mock" ,python-requests-mock)))
397 (home-page "https://mechanicalsoup.readthedocs.io/")
398 (synopsis "Python library for automating website interaction")
399 (description
400 "MechanicalSoup is a Python library for automating interaction with
401 websites. It automatically stores and sends cookies, follows redirects, and can
402 follow links and submit forms. It doesn’t do JavaScript.")
403 (license license:expat)))
404
405 (define-public python2-mechanicalsoup
406 (package-with-python2 python-mechanicalsoup))
407
408 (define-public python-sockjs-tornado
409 (package
410 (name "python-sockjs-tornado")
411 (version "1.0.6")
412 (source
413 (origin
414 (method url-fetch)
415 (uri (pypi-uri "sockjs-tornado" version))
416 (sha256
417 (base32
418 "15dgv6hw6c7h3m310alw1h6p5443lrm9pyqhcv2smc13fz1v04pc"))))
419 (build-system python-build-system)
420 (arguments
421 `(;; There are no tests, and running the test phase requires missing
422 ;; dependencies
423 #:tests? #f))
424 (propagated-inputs
425 `(("python-tornado" ,python-tornado)))
426 (home-page "https://github.com/mrjoes/sockjs-tornado/")
427 (synopsis
428 "SockJS Python server implementation on top of the Tornado framework")
429 (description
430 "SockJS-tornado provides the server-side counterpart to a SockJS client
431 library, through the Tornado framework.
432
433 SockJS provides a low-latency, full-duplex, cross-domain communication channel
434 between a web browser and web server.")
435 (license license:expat)))
436
437 (define-public python2-sockjs-tornado
438 (package-with-python2 python-sockjs-tornado))
439
440 (define-public python-flask-babel
441 (package
442 (name "python-flask-babel")
443 (version "1.0.0")
444 (source
445 (origin
446 (method url-fetch)
447 (uri (pypi-uri "Flask-Babel" version))
448 (sha256
449 (base32
450 "0gmb165vkwv5v7dxsxa2i3zhafns0fh938m2zdcrv4d8z5l099yn"))))
451 (build-system python-build-system)
452 (arguments
453 '(#:phases (modify-phases %standard-phases
454 (replace 'check
455 (lambda _
456 (with-directory-excursion "tests"
457 (invoke "python" "tests.py")))))))
458 (propagated-inputs
459 `(("python-flask" ,python-flask)
460 ("python-babel" ,python-babel)
461 ("python-jinja2" ,python-jinja2)
462 ("python-pytz" ,python-pytz)))
463 (home-page "https://github.com/python-babel/flask-babel")
464 (synopsis "Add i18n/l10n support to Flask applications")
465 (description "This package implements internationalization and localization
466 support for Flask. This is based on the Python babel module as well as pytz -
467 both of which are installed automatically if you install this library.")
468 (license license:bsd-3)))
469
470 (define-public python2-flask-babel
471 (package-with-python2 python-flask-babel))
472
473 (define-public python-html5lib
474 (package
475 (name "python-html5lib")
476 (version "1.0.1")
477 (source
478 (origin
479 (method url-fetch)
480 (uri (pypi-uri "html5lib" version))
481 (sha256
482 (base32
483 "0dipzfrycv6j1jw82v9b7d8lzggx3x8xngx6l4xrqkxwvg7hvjv6"))))
484 (build-system python-build-system)
485 (propagated-inputs
486 `(("python-six" ,python-six)
487 ("python-webencodings" ,python-webencodings)))
488 (arguments
489 `(#:test-target "check"))
490 (home-page
491 "https://github.com/html5lib/html5lib-python")
492 (synopsis
493 "Python HTML parser based on the WHATWG HTML specifcation")
494 (description
495 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
496 and written in Python.")
497 (license license:expat)))
498
499 (define-public python2-html5lib
500 (package-with-python2 python-html5lib))
501
502 ;; Needed for python-bleach, a dependency of python-notebook
503 (define-public python-html5lib-0.9
504 (package
505 (inherit python-html5lib)
506 (version "0.999")
507 (source
508 (origin
509 (method url-fetch)
510 (uri (pypi-uri "html5lib" version))
511 (sha256
512 (base32
513 "17n4zfsj6ynmbwdwviywmj8r6nzr3xvfx2zs0xhndmvm51z7z263"))))))
514
515 (define-public python2-html5lib-0.9
516 (package-with-python2 python-html5lib-0.9))
517
518 (define-public python-html5-parser
519 (package
520 (name "python-html5-parser")
521 (version "0.4.5")
522 (source (origin
523 (method url-fetch)
524 (uri (pypi-uri "html5-parser" version))
525 (sha256
526 (base32
527 "01mx33sx4dhl4kj6wc48nj6jz7ry60rkhjv0s6k8h5xmjf5yy0x9"))))
528 (build-system python-build-system)
529 (native-inputs
530 `(("pkg-config" ,pkg-config)))
531 (inputs
532 `(("libxml2" ,libxml2)))
533 (propagated-inputs
534 `(("python-lxml" ,python-lxml)
535 ("python-beautifulsoup4" ,python-beautifulsoup4)))
536 (home-page "https://html5-parser.readthedocs.io")
537 (synopsis "Fast C-based HTML5 parsing for Python")
538 (description "This package provides a fast implementation of the HTML5
539 parsing spec for Python. Parsing is done in C using a variant of the gumbo
540 parser. The gumbo parse tree is then transformed into an lxml tree, also in
541 C, yielding parse times that can be a thirtieth of the html5lib parse times.")
542 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
543 ;; indicate ASL2.0, including the LICENSE file for the whole project.
544 (license (list license:asl2.0 license:gpl3))))
545
546 (define-public python2-html5-parser
547 (package-with-python2 python-html5-parser))
548
549 (define-public python-pycurl
550 (package
551 (name "python-pycurl")
552 (version "7.43.0.2")
553 (source
554 (origin
555 (method url-fetch)
556 (uri (string-append "https://dl.bintray.com/pycurl/pycurl/pycurl-"
557 version ".tar.gz"))
558 (sha256
559 (base32 "1915kb04k1j4y6k1dx1sgnbddxrl9r1n4q928if2lkrdm73xy30g"))))
560 (build-system python-build-system)
561 (arguments
562 ;; The tests attempt to access external web servers, so we cannot run
563 ;; them. Furthermore, they are skipped altogether when using Python 2.
564 '(#:tests? #f
565 #:phases (modify-phases %standard-phases
566 (add-before 'build 'configure-tls-backend
567 (lambda _
568 ;; XXX: PycURL fails to automatically determine which TLS
569 ;; backend to use when cURL is built with --disable-static.
570 ;; See setup.py and <https://github.com/pycurl/pycurl/pull/147>.
571 (setenv "PYCURL_SSL_LIBRARY" "gnutls")
572 #t)))))
573 (native-inputs
574 `(("python-nose" ,python-nose)
575 ("python-bottle" ,python-bottle)))
576 (inputs
577 `(("curl" ,curl)
578 ("gnutls" ,gnutls)))
579 (home-page "http://pycurl.io/")
580 (synopsis "Lightweight Python wrapper around libcurl")
581 (description "Pycurl is a lightweight wrapper around libcurl. It provides
582 high-speed transfers via libcurl and frequently outperforms alternatives.")
583
584 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
585 ;; under the terms of LGPLv2.1+ or Expat.
586 (license (list license:lgpl2.1+ license:expat))))
587
588 (define-public python2-pycurl
589 (package-with-python2 python-pycurl))
590
591 (define-public python-webencodings
592 (package
593 (name "python-webencodings")
594 (version "0.5.1")
595 (source (origin
596 (method url-fetch)
597 (uri (pypi-uri "webencodings" version))
598 (sha256
599 (base32
600 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
601 (build-system python-build-system)
602 (arguments
603 '(#:phases
604 (modify-phases %standard-phases
605 (replace 'check
606 (lambda _
607 (invoke "py.test" "-v" "webencodings/tests.py")
608 #t)))))
609 (native-inputs
610 `(("python-pytest" ,python-pytest)))
611 (home-page "https://github.com/SimonSapin/python-webencodings")
612 (synopsis "Character encoding aliases for legacy web content")
613 (description
614 "In order to be compatible with legacy web content when interpreting
615 something like @code{Content-Type: text/html; charset=latin1}, tools need
616 to use a particular set of aliases for encoding labels as well as some
617 overriding rules. For example, @code{US-ASCII} and @code{iso-8859-1} on
618 the web are actually aliases for @code{windows-1252}, and a @code{UTF-8}
619 or @code{UTF-16} BOM takes precedence over any other encoding declaration.
620 The WHATWG @url{https://encoding.spec.whatwg.org/,Encoding} standard
621 defines all such details so that implementations do not have to
622 reverse-engineer each other.
623
624 This module implements the Encoding standard and has encoding labels and
625 BOM detection, but the actual implementation for encoders and decoders
626 is Python’s.")
627 (license license:bsd-3)))
628
629 (define-public python2-webencodings
630 (package-with-python2 python-webencodings))
631
632 (define-public python-openid
633 (package
634 (name "python-openid")
635 (version "3.1.0")
636 (source
637 (origin
638 (method url-fetch)
639 (uri (pypi-uri "python3-openid" version))
640 (sha256
641 (base32
642 "00l5hrjh19740w00b3fnsqldnla41wbr2rics09dl4kyd1fkd3b2"))))
643 (build-system python-build-system)
644 (arguments
645 `(#:phases
646 (modify-phases %standard-phases
647 (replace 'check
648 (lambda _
649 (invoke "coverage" "run" "-m"
650 "unittest" "openid.test.test_suite"))))))
651 (properties `((python2-variant . ,(delay python2-openid))))
652 (propagated-inputs
653 `(("python-defusedxml" ,python-defusedxml)))
654 (native-inputs
655 `(("python-coverage" ,python-coverage)
656 ("python-psycopg2" ,python-psycopg2)
657 ("python-django" ,python-django)))
658 (home-page "https://github.com/necaris/python3-openid")
659 (synopsis "OpenID support for servers and consumers")
660 (description "This library provides OpenID authentication for Python, both
661 for clients and servers.")
662 (license license:asl2.0)))
663
664 (define-public python2-openid
665 (package
666 (name "python2-openid")
667 (version "2.2.5")
668 (source
669 (origin
670 (method url-fetch)
671 (uri (pypi-uri "python-openid" version))
672 (sha256
673 (base32
674 "1vvhxlghjan01snfdc4k7ykd80vkyjgizwgg9bncnin8rqz1ricj"))))
675 (build-system python-build-system)
676 (arguments
677 ;; Python 3 support is in `python3-openid`, a separate package.
678 `(#:python ,python-2
679 ;; Tests aren't initialized correctly.
680 #:tests? #f))
681 (home-page "https://github.com/openid/python-openid")
682 (synopsis "OpenID support for servers and consumers")
683 (description "This library provides OpenID authentication for Python, both
684 for clients and servers.")
685 (license license:asl2.0)))
686
687 (define-public python-cssutils
688 (package
689 (name "python-cssutils")
690 (version "1.0.2")
691 (source
692 (origin
693 (method url-fetch)
694 (uri (pypi-uri "cssutils" version))
695 (sha256
696 (base32
697 "1bxchrbqzapwijap0yhlxdil1w9bmwvgx77aizlkhc2mcxjg1z52"))))
698 (build-system python-build-system)
699 (native-inputs
700 `(("unzip" ,unzip))) ; for unpacking the source
701 (arguments
702 `(#:tests? #f)) ; tests require python-pbr < 1.7.0
703 (home-page "http://cthedot.de/cssutils/")
704 (synopsis
705 "CSS Cascading Style Sheets library for Python")
706 (description
707 "Cssutils is a Python package for parsing and building CSS
708 Cascading Style Sheets. Currently it provides a DOM only and no rendering
709 options.")
710 (license license:lgpl3+)))
711
712 (define-public python2-cssutils
713 (package-with-python2 python-cssutils))
714
715 (define-public python-css-parser
716 (package
717 (inherit python-cssutils)
718 (name "python-css-parser")
719 (version "1.0.4")
720 (source
721 (origin
722 (method url-fetch)
723 (uri (pypi-uri "css-parser" version ".tar.gz"))
724 (sha256
725 (base32
726 "0i4xfykiffxzr4f6y0m2ggqvx1rzam6pw6krlr5k6ldf29akbay7"))))
727 (home-page "https://github.com/ebook-utils/css-parser")
728 (synopsis "Fork of cssutils modified for parsing ebooks")
729 (description
730 "Css-parser is a fork of cssutils 1.0.2, updated and modified for parsing
731 ebooks, due to cssutils not receiving updates as of 1.0.2.")
732 (license license:lgpl3+)))
733
734 (define-public python2-css-parser
735 (package-with-python2 python-css-parser))
736
737 (define-public python-cssselect
738 (package
739 (name "python-cssselect")
740 (version "0.9.2")
741 (source
742 (origin
743 (method url-fetch)
744 (uri (pypi-uri "cssselect" version))
745 (sha256
746 (base32
747 "1xg6gbva1yswghiycmgincv6ab4bn7hpm720ndbj40h8xycmnfvi"))))
748 (build-system python-build-system)
749 (arguments
750 ;; tests fail with message
751 ;; AttributeError: 'module' object has no attribute 'tests'
752 `(#:tests? #f))
753 (home-page
754 "https://pythonhosted.org/cssselect/")
755 (synopsis
756 "CSS3 selector parser and translator to XPath 1.0")
757 (description
758 "Cssselect ia a Python module that parses CSS3 Selectors and translates
759 them to XPath 1.0 expressions. Such expressions can be used in lxml or
760 another XPath engine to find the matching elements in an XML or HTML document.")
761 (license license:bsd-3)))
762
763 (define-public python2-cssselect
764 (package-with-python2 python-cssselect))
765
766 (define-public python-openid-cla
767 (package
768 (name "python-openid-cla")
769 (version "1.2")
770 (source
771 (origin
772 (method url-fetch)
773 (uri (pypi-uri "python-openid-cla" version))
774 (sha256
775 (base32
776 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
777 (build-system python-build-system)
778 (arguments '(#:tests? #f)) ; No tests.
779 (home-page "https://github.com/puiterwijk/python-openid-cla/")
780 (synopsis "Implementation of the OpenID CLA extension for python-openid")
781 (description "@code{openid-cla} is an implementation of the OpenID
782 contributor license agreement extension for python-openid.")
783 (license license:bsd-3)))
784
785 (define-public python2-openid-cla
786 (package-with-python2 python-openid-cla))
787
788 (define-public python-openid-teams
789 (package
790 (name "python-openid-teams")
791 (version "1.1")
792 (source
793 (origin
794 (method url-fetch)
795 (uri (pypi-uri "python-openid-teams" version))
796 (sha256
797 (base32
798 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
799 (build-system python-build-system)
800 (arguments '(#:tests? #f)) ; No tests.
801 (home-page "https://github.com/puiterwijk/python-openid-teams/")
802 (synopsis "Implementation of the OpenID teams extension for python-openid")
803 (description
804 "@code{openid-teams} is an implementation of the OpenID
805 teams extension for python-openid.")
806 (license license:bsd-3)))
807
808 (define-public python2-openid-teams
809 (package-with-python2 python-openid-teams))
810
811 (define-public python-tornado
812 (package
813 (name "python-tornado")
814 (version "5.1.1")
815 (source
816 (origin
817 (method url-fetch)
818 (uri (pypi-uri "tornado" version))
819 (sha256
820 (base32
821 "02clqk2116jbnq8lnaqmdw3p52nqrd9ib59r4xz2ll43fpcmhlaf"))))
822 (build-system python-build-system)
823 (arguments
824 '(;; FIXME: Two tests error out with:
825 ;; AssertionError: b'Error in atexit._run_exitfuncs:\nFileNotF[44 chars]ry\n' != b''
826 ;; #:phases
827 ;; (modify-phases %standard-phases
828 ;; (replace 'check
829 ;; (lambda _
830 ;; ;; 'setup.py test' hits an AssertionError on BSD-specific
831 ;; ;; "tornado/platform/kqueue.py". This is the supported method:
832 ;; (invoke "python" "-m" "tornado.test.runtests")
833 ;; #t)))
834 #:tests? #f))
835 (native-inputs
836 `(("python-certifi" ,python-certifi)))
837 (home-page "https://www.tornadoweb.org/")
838 (synopsis "Python web framework and asynchronous networking library")
839 (description
840 "Tornado is a Python web framework and asynchronous networking library,
841 originally developed at FriendFeed. By using non-blocking network I/O,
842 Tornado can scale to tens of thousands of open connections, making it ideal
843 for long polling, WebSockets, and other applications that require a long-lived
844 connection to each user.")
845 (license license:asl2.0)
846 (properties `((python2-variant . ,(delay python2-tornado))))))
847
848 (define-public python2-tornado
849 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
850 (package (inherit tornado)
851 (propagated-inputs
852 `(("python2-backport-ssl-match-hostname"
853 ,python2-backport-ssl-match-hostname)
854 ("python2-backports-abc" ,python2-backports-abc)
855 ("python2-singledispatch" ,python2-singledispatch)
856 ,@(package-propagated-inputs tornado))))))
857
858 (define-public python-tornado-http-auth
859 (package
860 (name "python-tornado-http-auth")
861 (version "1.1.1")
862 (source
863 (origin
864 (method url-fetch)
865 (uri (pypi-uri "tornado-http-auth" version))
866 (sha256
867 (base32 "0hyc5f0a09i5yb99pk4bxpg6w9ichbrb5cv7hc9hff7rxd8w0v0x"))))
868 (build-system python-build-system)
869 (propagated-inputs
870 `(("python-tornado" ,python-tornado)))
871 (home-page "https://github.com/gvalkov/tornado-http-auth")
872 (synopsis "Digest and basic authentication module for Tornado")
873 (description
874 "Provides support for adding authentication to services using the Tornado
875 web framework, either via the basic or digest authentication schemes.")
876 (license license:asl2.0)))
877
878 (define-public python-terminado
879 (package
880 (name "python-terminado")
881 (version "0.8.1")
882 (source
883 (origin
884 (method url-fetch)
885 (uri (pypi-uri "terminado" version))
886 (sha256
887 (base32
888 "0yh69k6579g848rmjyllb5h75pkvgcy27r1l3yzgkf33wnnzkasm"))))
889 (build-system python-build-system)
890 (propagated-inputs
891 `(("python-tornado" ,python-tornado)
892 ("python-ptyprocess" ,python-ptyprocess)))
893 (native-inputs
894 `(("python-nose" ,python-nose)))
895 (arguments
896 `(#:phases
897 (modify-phases %standard-phases
898 (replace 'check
899 (lambda _ (invoke "nosetests") #t)))))
900 (home-page "https://github.com/takluyver/terminado")
901 (synopsis "Terminals served to term.js using Tornado websockets")
902 (description "This package provides a Tornado websocket backend for the
903 term.js Javascript terminal emulator library.")
904 (license license:bsd-2)
905 (properties `((python2-variant . ,(delay python2-terminado))))))
906
907 (define-public python2-terminado
908 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
909 (package (inherit terminado)
910 (propagated-inputs
911 `(("python2-backport-ssl-match-hostname"
912 ,python2-backport-ssl-match-hostname)
913 ("python2-futures" ,python2-futures)
914 ,@(package-propagated-inputs terminado))))))
915
916 (define-public python-wsgi-intercept
917 (package
918 (name "python-wsgi-intercept")
919 (version "1.2.2")
920 (source (origin
921 (method url-fetch)
922 (uri (pypi-uri "wsgi_intercept" version))
923 (sha256
924 (base32
925 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
926 (build-system python-build-system)
927 (propagated-inputs
928 `(("python-six" ,python-six)))
929 (native-inputs
930 `(("python-pytest" ,python-pytest)
931 ("python-httplib2" ,python-httplib2)
932 ("python-requests" ,python-requests)
933 ("python-urllib3" ,python-urllib3)))
934 (synopsis "Puts a WSGI application in place of a real URI for testing")
935 (description "Wsgi_intercept installs a WSGI application in place of a real
936 URI for testing. Testing a WSGI application normally involves starting a
937 server at a local host and port, then pointing your test code to that address.
938 Instead, this library lets you intercept calls to any specific host/port
939 combination and redirect them into a WSGI application importable by your test
940 program. Thus, you can avoid spawning multiple processes or threads to test
941 your Web app.")
942 (home-page "https://github.com/cdent/wsgi-intercept")
943 (license license:expat)))
944
945 (define-public python-webob
946 (package
947 (name "python-webob")
948 (version "1.5.1")
949 (source
950 (origin
951 (method url-fetch)
952 (uri (pypi-uri "WebOb" version))
953 (sha256
954 (base32
955 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
956 (build-system python-build-system)
957 (native-inputs
958 `(("python-nose" ,python-nose)))
959 (home-page "https://webob.org/")
960 (synopsis "WSGI request and response object")
961 (description
962 "WebOb provides wrappers around the WSGI request environment, and an
963 object to help create WSGI responses.")
964 (license license:expat)))
965
966 (define-public python2-webob
967 (package-with-python2 python-webob))
968
969 (define-public python-zope-event
970 (package
971 (name "python-zope-event")
972 (version "4.4")
973 (source
974 (origin
975 (method url-fetch)
976 (uri (pypi-uri "zope.event" version))
977 (sha256
978 (base32
979 "1ksbc726av9xacml6jhcfyn828hlhb9xlddpx6fcvnlvmpmpvhk9"))))
980 (build-system python-build-system)
981 (home-page "https://pypi.org/project/zope.event/")
982 (synopsis "Event publishing system for Python")
983 (description "Zope.event provides an event publishing API, intended for
984 use by applications which are unaware of any subscribers to their events. It
985 is a simple event-dispatching system on which more sophisticated event
986 dispatching systems can be built.")
987 (license license:zpl2.1)))
988
989 (define-public python2-zope-event
990 (package-with-python2 python-zope-event))
991
992 (define-public python-zope-interface
993 (package
994 (name "python-zope-interface")
995 (version "4.7.2")
996 (source
997 (origin
998 (method url-fetch)
999 (uri (pypi-uri "zope.interface" version))
1000 (sha256
1001 (base32
1002 "0r9kvb1q3lxrdhxabliv9nwhjsdmn1n0vcjv93rlqkyb7yyh24gx"))))
1003 (build-system python-build-system)
1004 (native-inputs
1005 `(("python-zope-event" ,python-zope-event)))
1006 (home-page "https://github.com/zopefoundation/zope.interface")
1007 (synopsis "Python implementation of the \"design by contract\"
1008 methodology")
1009 (description "Zope.interface provides an implementation of \"object
1010 interfaces\" for Python. Interfaces are a mechanism for labeling objects as
1011 conforming to a given API or contract.")
1012 (license license:zpl2.1)))
1013
1014 (define-public python2-zope-interface
1015 (package-with-python2 python-zope-interface))
1016
1017 (define-public python-zope-exceptions
1018 (package
1019 (name "python-zope-exceptions")
1020 (version "4.3")
1021 (source
1022 (origin
1023 (method url-fetch)
1024 (uri (pypi-uri "zope.exceptions" version))
1025 (sha256
1026 (base32
1027 "04bjskwas17yscl8bs3l44maxspw1gdji0zcmr499fs420y9r9az"))))
1028 (build-system python-build-system)
1029 (arguments
1030 '(#:tests? #f)) ; circular dependency with zope.testrunner
1031 (propagated-inputs
1032 `(("python-zope-interface" ,python-zope-interface)))
1033 (home-page "https://pypi.org/project/zope.exceptions/")
1034 (synopsis "Zope exceptions")
1035 (description "Zope.exceptions provides general-purpose exception types
1036 that have uses outside of the Zope framework.")
1037 (license license:zpl2.1)))
1038
1039 (define-public python2-zope-exceptions
1040 (package-with-python2 python-zope-exceptions))
1041
1042 (define-public python-zope-testing
1043 (package
1044 (name "python-zope-testing")
1045 (version "4.7")
1046 (source
1047 (origin
1048 (method url-fetch)
1049 (uri (pypi-uri "zope.testing" version))
1050 (sha256
1051 (base32
1052 "1sh3c3i0m8n8fnhqiry0bk3rr356i56ry7calmn57s1pvv8yhsyn"))))
1053 (build-system python-build-system)
1054 (home-page "https://pypi.org/project/zope.testing/")
1055 (synopsis "Zope testing helpers")
1056 (description "Zope.testing provides a number of testing utilities for HTML
1057 forms, HTTP servers, regular expressions, and more.")
1058 (license license:zpl2.1)))
1059
1060 (define-public python2-zope-testing
1061 (package-with-python2 python-zope-testing))
1062
1063 (define-public python-zope-testrunner
1064 (package
1065 (name "python-zope-testrunner")
1066 (version "5.1")
1067 (source
1068 (origin
1069 (method url-fetch)
1070 (uri (pypi-uri "zope.testrunner" version))
1071 (sha256
1072 (base32
1073 "0w3q66cy4crpj7c0hw0vvvvwf3g931rnvw7wwa20av7yqvv6ajim"))))
1074 (build-system python-build-system)
1075 (arguments
1076 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1077 (native-inputs
1078 `(("python-zope-testing" ,python-zope-testing)))
1079 (propagated-inputs
1080 `(("python-six" ,python-six)
1081 ("python-zope-exceptions" ,python-zope-exceptions)
1082 ("python-zope-interface" ,python-zope-interface)))
1083 (home-page "https://pypi.org/project/zope.testrunner/")
1084 (synopsis "Zope testrunner script")
1085 (description "Zope.testrunner provides a script for running Python
1086 tests.")
1087 (license license:zpl2.1)))
1088
1089 (define-public python2-zope-testrunner
1090 (package-with-python2 python-zope-testrunner))
1091
1092 (define-public python-zope-i18nmessageid
1093 (package
1094 (name "python-zope-i18nmessageid")
1095 (version "5.0.1")
1096 (source
1097 (origin
1098 (method url-fetch)
1099 (uri (pypi-uri "zope.i18nmessageid" version))
1100 (sha256
1101 (base32
1102 "0ndhn4w1qgwkfbwf9vm2bgq418z5g0wmfsgl0d9nz62cd0mi8d4m"))))
1103 (build-system python-build-system)
1104 (native-inputs
1105 `(("python-coverage" ,python-coverage)
1106 ("python-zope-testrunner" ,python-zope-testrunner)))
1107 (propagated-inputs
1108 `(("python-six" ,python-six)))
1109 (home-page "https://pypi.org/project/zope.i18nmessageid/")
1110 (synopsis "Message identifiers for internationalization")
1111 (description "Zope.i18nmessageid provides facilities for declaring
1112 internationalized messages within program source text.")
1113 (license license:zpl2.1)))
1114
1115 (define-public python2-zope-i18nmessageid
1116 (package-with-python2 python-zope-i18nmessageid))
1117
1118 (define-public python-zope-schema
1119 (package
1120 (name "python-zope-schema")
1121 (version "4.4.2")
1122 (source
1123 (origin
1124 (method url-fetch)
1125 (uri (pypi-uri "zope.schema" version))
1126 (sha256
1127 (base32
1128 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
1129 (build-system python-build-system)
1130 (arguments
1131 '(#:tests? #f)) ; FIXME: Tests can't find zope.event.
1132 (propagated-inputs
1133 `(("python-zope-event" ,python-zope-event)
1134 ("python-zope-exceptions" ,python-zope-exceptions)
1135 ("python-zope-interface" ,python-zope-interface)))
1136 (native-inputs
1137 `(("python-zope-testing" ,python-zope-testing)
1138 ("python-coverage" ,python-coverage)
1139 ("python-nose" ,python-nose)))
1140 (home-page "https://pypi.org/project/zope.schema/")
1141 (synopsis "Zope data schemas")
1142 (description "Zope.scheme provides extensions to zope.interface for
1143 defining data schemas.")
1144 (license license:zpl2.1)))
1145
1146 (define-public python2-zope-schema
1147 (package-with-python2 python-zope-schema))
1148
1149 (define-public python-zope-configuration
1150 (package
1151 (name "python-zope-configuration")
1152 (version "4.0.3")
1153 (source (origin
1154 (method url-fetch)
1155 (uri (pypi-uri "zope.configuration" version))
1156 (sha256
1157 (base32
1158 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
1159 (build-system python-build-system)
1160 (arguments
1161 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1162 (propagated-inputs
1163 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1164 ("python-zope-schema" ,python-zope-schema)))
1165 (home-page "https://pypi.org/project/zope.configuration/")
1166 (synopsis "Zope Configuration Markup Language")
1167 (description "Zope.configuration implements ZCML, the Zope Configuration
1168 Markup Language.")
1169 (license license:zpl2.1)))
1170
1171 (define-public python2-zope-configuration
1172 (package-with-python2 python-zope-configuration))
1173
1174 (define-public python-zope-proxy
1175 (package
1176 (name "python-zope-proxy")
1177 (version "4.1.6")
1178 (source
1179 (origin
1180 (method url-fetch)
1181 (uri (pypi-uri "zope.proxy" version))
1182 (sha256
1183 (base32
1184 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
1185 (build-system python-build-system)
1186 (arguments
1187 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1188 (propagated-inputs
1189 `(("python-zope-interface" ,python-zope-interface)))
1190 (home-page "https://pypi.org/project/zope.proxy/")
1191 (synopsis "Generic, transparent proxies")
1192 (description "Zope.proxy provides generic, transparent proxies for Python.
1193 Proxies are special objects which serve as mostly-transparent wrappers around
1194 another object, intervening in the apparent behavior of the wrapped object
1195 only when necessary to apply the policy (e.g., access checking, location
1196 brokering, etc.) for which the proxy is responsible.")
1197 (license license:zpl2.1)))
1198
1199 (define-public python2-zope-proxy
1200 (package-with-python2 python-zope-proxy))
1201
1202 (define-public python-zope-location
1203 (package
1204 (name "python-zope-location")
1205 (version "4.0.3")
1206 (source
1207 (origin
1208 (method url-fetch)
1209 (uri (pypi-uri "zope.location" version))
1210 (sha256
1211 (base32
1212 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
1213 (build-system python-build-system)
1214 (arguments
1215 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1216 (propagated-inputs
1217 `(("python-zope-proxy" ,python-zope-proxy)
1218 ("python-zope-schema" ,python-zope-schema)))
1219 (home-page "https://pypi.org/project/zope.location/")
1220 (synopsis "Zope location library")
1221 (description "Zope.location implements the concept of \"locations\" in
1222 Zope3, which are are special objects that have a structural location.")
1223 (license license:zpl2.1)))
1224
1225 (define-public python2-zope-location
1226 (package-with-python2 python-zope-location))
1227
1228 (define-public python-zope-security
1229 (package
1230 (name "python-zope-security")
1231 (version "4.0.3")
1232 (source
1233 (origin
1234 (method url-fetch)
1235 (uri (pypi-uri "zope.security" version))
1236 (sha256
1237 (base32
1238 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
1239 (build-system python-build-system)
1240 (arguments
1241 '(#:tests? #f)) ; FIXME: Tests can't find zope.testrunner.
1242 (propagated-inputs
1243 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1244 ("python-zope-proxy" ,python-zope-proxy)
1245 ("python-zope-schema" ,python-zope-schema)))
1246 (native-inputs
1247 `(("python-six" ,python-six)
1248 ("python-zope-component" ,python-zope-component)
1249 ("python-zope-configuration" ,python-zope-configuration)
1250 ("python-zope-location" ,python-zope-location)
1251 ("python-zope-testrunner" ,python-zope-testrunner)
1252 ("python-zope-testing" ,python-zope-testing)))
1253 (home-page "https://pypi.org/project/zope.security/")
1254 (synopsis "Zope security framework")
1255 (description "Zope.security provides a generic mechanism to implement
1256 security policies on Python objects.")
1257 (license license:zpl2.1)))
1258
1259 (define-public python2-zope-security
1260 (let ((zope-security (package-with-python2 python-zope-security)))
1261 (package (inherit zope-security)
1262 (propagated-inputs
1263 `(("python2-zope-testrunner" ,python2-zope-testrunner)
1264 ,@(alist-delete
1265 "python-zope-testrunner"
1266 (package-propagated-inputs zope-security)))))))
1267
1268 (define-public python-zope-component
1269 (package
1270 (name "python-zope-component")
1271 (version "4.3.0")
1272 (source
1273 (origin
1274 (method url-fetch)
1275 (uri (pypi-uri "zope.component" version))
1276 (sha256
1277 (base32
1278 "1hlvzwj1kcfz1qms1dzhwsshpsf38z9clmyksb1gh41n8k3kchdv"))))
1279 (build-system python-build-system)
1280 (arguments
1281 ;; Skip tests due to circular dependency with python-zope-security.
1282 '(#:tests? #f))
1283 (native-inputs
1284 `(("python-zope-testing" ,python-zope-testing)))
1285 (propagated-inputs
1286 `(("python-zope-event" ,python-zope-event)
1287 ("python-zope-interface" ,python-zope-interface)
1288 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1289 ("python-zope-configuration" ,python-zope-configuration)))
1290 (home-page "https://github.com/zopefoundation/zope.component")
1291 (synopsis "Zope Component Architecture")
1292 (description "Zope.component represents the core of the Zope Component
1293 Architecture. Together with the zope.interface package, it provides
1294 facilities for defining, registering and looking up components.")
1295 (license license:zpl2.1)))
1296
1297 (define-public python2-zope-component
1298 (package-with-python2 python-zope-component))
1299
1300 (define-public python-ndg-httpsclient
1301 (package
1302 (name "python-ndg-httpsclient")
1303 (version "0.5.1")
1304 (source (origin
1305 (method url-fetch)
1306 (uri (pypi-uri "ndg_httpsclient" version))
1307 (sha256
1308 (base32
1309 "0412b7i1s4vj7lz9r72nmb28h9syd4q2x89bdirkkc3a6z8awbyp"))))
1310 (build-system python-build-system)
1311 (arguments
1312 '(;; The tests appear to require networking.
1313 #:tests? #f))
1314 (propagated-inputs
1315 `(("python-pyopenssl" ,python-pyopenssl)))
1316 (synopsis "HTTPS support for Python's httplib and urllib2")
1317 (description "This is a HTTPS client implementation for httplib and urllib2
1318 based on PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation
1319 over the default provided with Python and, importantly, enables full
1320 verification of the SSL peer.")
1321 (home-page "https://github.com/cedadev/ndg_httpsclient/")
1322 (license license:bsd-3)))
1323
1324 ;; python2-openssl requires special care, so package-with-python2 is
1325 ;; insufficient.
1326 (define-public python2-ndg-httpsclient
1327 (package (inherit python-ndg-httpsclient)
1328 (name "python2-ndg-httpsclient")
1329 (arguments
1330 (substitute-keyword-arguments (package-arguments python-ndg-httpsclient)
1331 ((#:python _) python-2)))
1332 (propagated-inputs
1333 `(("python2-pyopenssl" ,python2-pyopenssl)))))
1334
1335 (define-public python-websocket-client
1336 (package
1337 (name "python-websocket-client")
1338 (version "0.54.0")
1339 (source
1340 (origin
1341 (method url-fetch)
1342 (uri (pypi-uri "websocket_client" version))
1343 (sha256
1344 (base32
1345 "0j88zmikaypf38lvpkf4aaxrjp9j07dmy5ghj7kli0fv3p4n45g5"))))
1346 (build-system python-build-system)
1347 (propagated-inputs
1348 `(("python-six" ,python-six)))
1349 (home-page "https://github.com/liris/websocket-client")
1350 (synopsis "WebSocket client for Python")
1351 (description "The Websocket-client module provides the low level APIs for
1352 WebSocket usage in Python programs.")
1353 (properties `((python2-variant . ,(delay python2-websocket-client))))
1354 (license license:lgpl2.1+)))
1355
1356 (define-public python2-websocket-client
1357 (let ((base (package-with-python2
1358 (strip-python2-variant python-websocket-client))))
1359 (package
1360 (inherit base)
1361 (native-inputs
1362 `(("python2-backport-ssl-match-hostname"
1363 ,python2-backport-ssl-match-hostname)
1364 ,@(package-native-inputs base))))))
1365
1366 (define-public python-requests
1367 (package
1368 (name "python-requests")
1369 (version "2.22.0")
1370 (source (origin
1371 (method url-fetch)
1372 (uri (pypi-uri "requests" version))
1373 (sha256
1374 (base32
1375 "1d5ybh11jr5sm7xp6mz8fyc7vrp4syifds91m7sj60xalal0gq0i"))))
1376 (build-system python-build-system)
1377 (propagated-inputs
1378 `(("python-certifi" ,python-certifi)
1379 ("python-chardet" ,python-chardet)
1380 ("python-idna" ,python-idna)
1381 ("python-urllib3" ,python-urllib3)))
1382 (arguments
1383 ;; FIXME: Some tests require network access.
1384 '(#:tests? #f))
1385 (home-page "http://python-requests.org/")
1386 (synopsis "Python HTTP library")
1387 (description
1388 "Requests is a Python HTTP client library. It aims to be easier to use
1389 than Python’s urllib2 library.")
1390 (license license:asl2.0)))
1391
1392 ;; Some software requires an older version of Requests, notably Docker/Docker
1393 ;; Compose.
1394 (define-public python-requests-2.20
1395 (package (inherit python-requests)
1396 (version "2.20.1")
1397 (source (origin
1398 (method url-fetch)
1399 (uri (pypi-uri "requests" version))
1400 (sha256
1401 (base32
1402 "0qzj6cgv3k9wyj7wlxgz7xq0cfg4jbbkfm24pp8dnhczwl31527a"))))
1403 (propagated-inputs
1404 `(("python-urllib3" ,python-urllib3-1.24)
1405 ("python-idna" ,python-idna-2.7)
1406 ,@(package-propagated-inputs python-requests)))))
1407
1408 ;; Some software requires an older version of Requests, notably Docker
1409 ;; Compose.
1410 (define-public python-requests-2.7
1411 (package (inherit python-requests)
1412 (version "2.7.0")
1413 (source (origin
1414 (method url-fetch)
1415 (uri (pypi-uri "requests" version))
1416 (sha256
1417 (base32
1418 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
1419
1420 (define-public python2-requests
1421 (package-with-python2 python-requests))
1422
1423 (define-public python-requests-mock
1424 (package
1425 (name "python-requests-mock")
1426 (version "1.3.0")
1427 (source
1428 (origin
1429 (method url-fetch)
1430 (uri (pypi-uri "requests-mock" version))
1431 (sha256
1432 (base32
1433 "0jr997dvk6zbmhvbpcv3rajrgag69mcsm1ai3w3rgk2jdh6rg1mx"))))
1434 (build-system python-build-system)
1435 (propagated-inputs
1436 `(("python-requests" ,python-requests)
1437 ("python-six" ,python-six)))
1438 (native-inputs
1439 `(("python-pbr" ,python-pbr)
1440 ("python-discover" ,python-discover)
1441 ("python-docutils" ,python-docutils)
1442 ("python-fixtures" ,python-fixtures)
1443 ("python-mock" ,python-mock)
1444 ("python-sphinx" ,python-sphinx)
1445 ("python-testrepository" ,python-testrepository)
1446 ("python-testtools" ,python-testtools)))
1447 (home-page "https://requests-mock.readthedocs.org/")
1448 (synopsis "Mock out responses from the requests package")
1449 (description
1450 "This module provides a building block to stub out the HTTP requests
1451 portions of your testing code.")
1452 (properties `((python2-variant . ,(delay python2-requests-mock))))
1453 (license license:asl2.0)))
1454
1455 (define-public python2-requests-mock
1456 (package (inherit (package-with-python2
1457 (strip-python2-variant python-requests-mock)))
1458 (arguments
1459 `(#:python ,python-2
1460 ;; FIXME: 'subunit.run discover: error: no such option: --list'
1461 #:tests? #f))))
1462
1463 (define-public python-requests-toolbelt
1464 (package
1465 (name "python-requests-toolbelt")
1466 (version "0.8.0")
1467 (source (origin
1468 (method url-fetch)
1469 (uri (pypi-uri "requests-toolbelt" version))
1470 (sha256
1471 (base32
1472 "1dc7l42i4080r8i4m9fj51jx367lqkai170vrv7wd93gdj9k39gn"))))
1473 (build-system python-build-system)
1474 (native-inputs
1475 `(("python-betamax" ,python-betamax)
1476 ("python-mock" ,python-mock)
1477 ("python-pytest" ,python-pytest)))
1478 (propagated-inputs
1479 `(("python-requests" ,python-requests)))
1480 (synopsis "Extensions to python-requests")
1481 (description "This is a toolbelt of useful classes and functions to be used
1482 with python-requests.")
1483 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
1484 (license license:asl2.0)))
1485
1486 (define-public python2-requests-toolbelt
1487 (package-with-python2 python-requests-toolbelt))
1488
1489 (define-public python-oauthlib
1490 (package
1491 (name "python-oauthlib")
1492 (version "3.0.1")
1493 (source (origin
1494 (method url-fetch)
1495 (uri (pypi-uri "oauthlib" version))
1496 (sha256
1497 (base32
1498 "163jg4a8f7c5ki655grrr47kgljy12wri3qly7ijf64sk1fjrqqc"))))
1499 (build-system python-build-system)
1500 (arguments
1501 `(#:phases (modify-phases %standard-phases
1502 (replace 'check
1503 (lambda _
1504 (invoke "pytest" "-vv"))))))
1505 (native-inputs
1506 `(("python-pytest" ,python-pytest)
1507 ("python-pytest-cov" ,python-pytest-cov)
1508 ("python-mock" ,python-mock)))
1509 (propagated-inputs
1510 `(("python-cryptography" ,python-cryptography)
1511 ("python-pyjwt" ,python-pyjwt)
1512 ("python-blinker" ,python-blinker)))
1513 (home-page "https://github.com/oauthlib/oauthlib")
1514 (synopsis "OAuth implementation for Python")
1515 (description
1516 "Oauthlib is a generic, spec-compliant, thorough implementation of the
1517 OAuth request-signing logic.")
1518 (license license:bsd-3)))
1519
1520 (define-public python2-oauthlib
1521 (package-with-python2 python-oauthlib))
1522
1523 (define-public python-rauth
1524 (package
1525 (name "python-rauth")
1526 (version "0.7.3")
1527 (source
1528 (origin
1529 (method url-fetch)
1530 (uri (pypi-uri "rauth" version))
1531 (sha256
1532 (base32
1533 "02kv8w8l98ky223avyq7vw7x1f2ya9chrm59r77ylq45qb0xnk2j"))))
1534 (build-system python-build-system)
1535 (arguments
1536 `(#:test-target "check"))
1537 (propagated-inputs
1538 `(("python-requests" ,python-requests)))
1539 (home-page "https://github.com/litl/rauth")
1540 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
1541 (description
1542 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
1543 provides service wrappers for convenient connection initialization and
1544 authenticated session objects providing things like keep-alive.")
1545 (license license:expat)
1546 (properties `((python2-variant . ,(delay python2-rauth))))))
1547
1548 (define-public python2-rauth
1549 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
1550 (package
1551 (inherit base)
1552 (native-inputs `(("python2-unittest2" ,python2-unittest2)
1553 ,@(package-native-inputs base))))))
1554
1555 (define-public python-urllib3
1556 (package
1557 (name "python-urllib3")
1558 (version "1.25.3")
1559 (source
1560 (origin
1561 (method url-fetch)
1562 (uri (pypi-uri "urllib3" version))
1563 (sha256
1564 (base32
1565 "0cij8qcvvpj62g1q8n785qjkdymfh4b7vf45si4sw64l41rr3rfv"))))
1566 (build-system python-build-system)
1567 (arguments `(#:tests? #f))
1568 (propagated-inputs
1569 `(;; These 5 inputs are used to build urrlib3[secure]
1570 ("python-certifi" ,python-certifi)
1571 ("python-cryptography" ,python-cryptography)
1572 ("python-idna" ,python-idna)
1573 ("python-ipaddress" ,python-ipaddress)
1574 ("python-pyopenssl" ,python-pyopenssl)
1575 ("python-pysocks" ,python-pysocks)))
1576 (home-page "https://urllib3.readthedocs.io/")
1577 (synopsis "HTTP library with thread-safe connection pooling")
1578 (description
1579 "Urllib3 supports features left out of urllib and urllib2 libraries. It
1580 can reuse the same socket connection for multiple requests, it can POST files,
1581 supports url redirection and retries, and also gzip and deflate decoding.")
1582 (license license:expat)))
1583
1584 ;; Some software requires an older version of urllib3, notably Docker.
1585 (define-public python-urllib3-1.24
1586 (package (inherit python-urllib3)
1587 (version "1.24.3")
1588 (source (origin
1589 (method url-fetch)
1590 (uri (pypi-uri "urllib3" version))
1591 (sha256
1592 (base32
1593 "1x0slqrv6kixkbcdnxbglvjliwhc1payavxjvk8fvbqjrnasd4r3"))))))
1594
1595
1596 (define-public python2-urllib3
1597 (package-with-python2 python-urllib3))
1598
1599 (define-public awscli
1600 (package
1601 (name "awscli")
1602 (version "1.18.6")
1603 (source
1604 (origin
1605 (method url-fetch)
1606 (uri (pypi-uri name version))
1607 (sha256
1608 (base32
1609 "0p479mfs9r0m82a217pap8156ijwvhv6r3kqa4k267gd05wgvygm"))))
1610 (build-system python-build-system)
1611 (arguments
1612 ;; FIXME: The 'pypi' release does not contain tests.
1613 '(#:tests? #f
1614 #:phases
1615 (modify-phases %standard-phases
1616 (add-after 'unpack 'fix-reference-to-groff
1617 (lambda _
1618 (substitute* "awscli/help.py"
1619 (("if not self._exists_on_path\\('groff'\\):") "")
1620 (("raise ExecutableNotFoundError\\('groff'\\)") "")
1621 (("cmdline = \\['groff'")
1622 (string-append "cmdline = ['" (which "groff") "'")))
1623 #t)))))
1624 (propagated-inputs
1625 `(("python-colorama" ,python-colorama)
1626 ("python-botocore" ,python-botocore)
1627 ("python-s3transfer" ,python-s3transfer)
1628 ("python-docutils" ,python-docutils)
1629 ("python-pyyaml" ,python-pyyaml)
1630 ("python-rsa" ,python-rsa)))
1631 (native-inputs
1632 `(("groff" ,groff)))
1633 (home-page "https://aws.amazon.com/cli/")
1634 (synopsis "Command line client for AWS")
1635 (description "AWS CLI provides a unified command line interface to the
1636 Amazon Web Services (AWS) API.")
1637 (license license:asl2.0)))
1638
1639 (define-public python-wsgiproxy2
1640 (package
1641 (name "python-wsgiproxy2")
1642 (version "0.4.6")
1643 (source
1644 (origin
1645 (method url-fetch)
1646 (uri (pypi-uri "WSGIProxy2" version ".tar.gz"))
1647 (sha256
1648 (base32 "16jch5nic0hia28lps3c678s9s9mjdq8n87igxncjg0rpi5adqnf"))))
1649 (build-system python-build-system)
1650 (native-inputs
1651 `(("python-webtest" ,python-webtest)))
1652 (propagated-inputs
1653 `(("python-requests" ,python-requests)
1654 ("python-six" ,python-six)
1655 ("python-urllib3" ,python-urllib3)
1656 ("python-webob" ,python-webob)))
1657 (home-page "https://github.com/gawel/WSGIProxy2/")
1658 (synopsis "WSGI Proxy with various http client backends")
1659 (description "WSGI turns HTTP requests into WSGI function calls.
1660 WSGIProxy turns WSGI function calls into HTTP requests.
1661 It also includes code to sign requests and pass private data,
1662 and to spawn subprocesses to handle requests.")
1663 (license license:expat)))
1664
1665 (define-public python2-wsgiproxy2
1666 (package-with-python2 python-wsgiproxy2))
1667
1668 (define-public python-pastedeploy
1669 (package
1670 (name "python-pastedeploy")
1671 (version "1.5.2")
1672 (source
1673 (origin
1674 (method url-fetch)
1675 (uri (pypi-uri "PasteDeploy" version))
1676 (sha256
1677 (base32
1678 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
1679 (build-system python-build-system)
1680 (native-inputs
1681 `(("python-nose" ,python-nose)))
1682 (home-page "https://pylonsproject.org/")
1683 (synopsis
1684 "Load, configure, and compose WSGI applications and servers")
1685 (description
1686 "This tool provides code to load WSGI applications and servers from URIs;
1687 these URIs can refer to Python Eggs for INI-style configuration files. Paste
1688 Script provides commands to serve applications based on this configuration
1689 file.")
1690 (license license:expat)))
1691
1692 (define-public python2-pastedeploy
1693 (package-with-python2 python-pastedeploy))
1694
1695 (define-public python-webtest
1696 (package
1697 (name "python-webtest")
1698 (version "2.0.33")
1699 (source
1700 (origin
1701 (method url-fetch)
1702 (uri (pypi-uri "WebTest" version))
1703 (sha256
1704 (base32
1705 "1l3z0cwqslsf4rcrhi2gr8kdfh74wn2dw76376i4g9i38gz8wd21"))))
1706 (build-system python-build-system)
1707 (arguments
1708 ;; Tests require python-pyquery, which creates a circular dependency.
1709 `(#:tests? #f))
1710 (propagated-inputs
1711 `(("python-waitress" ,python-waitress)
1712 ("python-webob" ,python-webob)
1713 ("python-six" ,python-six)
1714 ("python-beautifulsoup4" ,python-beautifulsoup4)))
1715 (home-page "https://docs.pylonsproject.org/projects/webtest/")
1716 (synopsis "Helper to test WSGI applications")
1717 (description "Webtest allows you to test your Python web applications
1718 without starting an HTTP server. It supports anything that supports the
1719 minimum of WSGI.")
1720 (license license:expat)))
1721
1722 (define-public python2-webtest
1723 (package-with-python2 python-webtest))
1724
1725 (define-public python-flask
1726 (package
1727 (name "python-flask")
1728 (version "1.1.1")
1729 (source (origin
1730 (method url-fetch)
1731 (uri (pypi-uri "Flask" version))
1732 (sha256
1733 (base32
1734 "0ljdjgyjn7vh8ic1n1dc2l1cl421i6pr3kx5sz2w5irhyfbg3y8k"))))
1735 (build-system python-build-system)
1736 (arguments
1737 '(#:phases
1738 (modify-phases %standard-phases
1739 (replace 'check
1740 (lambda _
1741 (setenv "PYTHONPATH" (string-append "./build/lib:"
1742 (getenv "PYTHONPATH")))
1743 (invoke "pytest" "-vv" "tests"))))))
1744 (native-inputs
1745 `(("python-pytest" ,python-pytest)))
1746 (propagated-inputs
1747 `(("python-itsdangerous" ,python-itsdangerous)
1748 ("python-jinja2" ,python-jinja2)
1749 ("python-click" ,python-click)
1750 ("python-werkzeug" ,python-werkzeug)))
1751 (home-page "https://www.palletsprojects.com/p/flask/")
1752 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
1753 (description "Flask is a micro web framework based on the Werkzeug toolkit
1754 and Jinja2 template engine. It is called a micro framework because it does not
1755 presume or force a developer to use a particular tool or library.")
1756 (license license:bsd-3)))
1757
1758 (define-public python2-flask
1759 (package-with-python2 python-flask))
1760
1761 (define-public python-flask-wtf
1762 (package
1763 (name "python-flask-wtf")
1764 (version "0.14.3")
1765 (source
1766 (origin
1767 (method url-fetch)
1768 (uri (pypi-uri "Flask-WTF" version))
1769 (sha256
1770 (base32
1771 "086pvg2x69n0nczcq7frknfjd8am1zdy8qqpva1sanwb02hf65yl"))))
1772 (build-system python-build-system)
1773 (arguments
1774 '(#:phases
1775 (modify-phases %standard-phases
1776 (replace 'check
1777 (lambda _
1778 (setenv "PYTHONPATH" (string-append "./build/lib:"
1779 (getenv "PYTHONPATH")))
1780 (invoke "pytest" "-vv"))))))
1781 (propagated-inputs
1782 `(("python-flask-babel" ,python-flask-babel)
1783 ("python-babel" ,python-babel)
1784 ("python-wtforms" ,python-wtforms)))
1785 (native-inputs
1786 `(("python-pytest" ,python-pytest)))
1787 (home-page "https://github.com/lepture/flask-wtf")
1788 (synopsis "Simple integration of Flask and WTForms")
1789 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
1790 upload, and reCAPTCHA.")
1791 (license license:bsd-3)))
1792
1793 (define-public python2-flask-wtf
1794 (package-with-python2 python-flask-wtf))
1795
1796 (define-public python-flask-multistatic
1797 (package
1798 (name "python-flask-multistatic")
1799 (version "1.0")
1800 (source
1801 (origin
1802 (method url-fetch)
1803 (uri (pypi-uri "flask-multistatic" version))
1804 (sha256
1805 (base32
1806 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
1807 (build-system python-build-system)
1808 (propagated-inputs
1809 `(("python-flask" ,python-flask)))
1810 (home-page "https://pagure.io/flask-multistatic")
1811 (synopsis "Flask plugin to allow overriding static files")
1812 (description "@code{flask-multistatic} is a flask plugin that adds support
1813 for overriding static files.")
1814 (license license:gpl3+)))
1815
1816 (define-public python2-flask-multistatic
1817 (package-with-python2 python-flask-multistatic))
1818
1819 (define-public python-cookies
1820 (package
1821 (name "python-cookies")
1822 (version "2.2.1")
1823 (source (origin
1824 (method url-fetch)
1825 (uri (pypi-uri "cookies" version))
1826 (sha256
1827 (base32
1828 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
1829 (build-system python-build-system)
1830 (arguments
1831 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
1832 #:tests? #f))
1833 (native-inputs
1834 `(("python-pytest" ,python-pytest)))
1835 (synopsis "HTTP cookie parser and renderer")
1836 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
1837 Python.")
1838 (home-page "https://gitlab.com/sashahart/cookies")
1839 (license license:expat)))
1840
1841 (define-public python2-cookies
1842 (package-with-python2 python-cookies))
1843
1844 (define-public python-responses
1845 (package
1846 (name "python-responses")
1847 (version "0.10.6")
1848 (source (origin
1849 (method url-fetch)
1850 (uri (pypi-uri "responses" version))
1851 (sha256
1852 (base32
1853 "147pacwkkqy3qf3hr33fnl1xbzgw0zsm3qppvvy9qhq8h069qbah"))))
1854 (build-system python-build-system)
1855 (arguments
1856 `(;; Test suite is not distributed:
1857 ;; https://github.com/getsentry/responses/issues/38
1858 #:tests? #f))
1859 (native-inputs
1860 `(("python-mock" ,python-mock)))
1861 (propagated-inputs
1862 `(("python-requests" ,python-requests)
1863 ("python-cookies" ,python-cookies)
1864 ("python-six" ,python-six)))
1865 (home-page "https://github.com/getsentry/responses")
1866 (synopsis "Utility for mocking out the `requests` Python library")
1867 (description "A utility library for mocking out the `requests` Python
1868 library.")
1869 (license license:asl2.0)))
1870
1871 (define-public python2-responses
1872 (package-with-python2 python-responses))
1873
1874 (define-public python-grequests
1875 (package
1876 (name "python-grequests")
1877 (version "0.3.0")
1878 (source
1879 (origin
1880 (method url-fetch)
1881 (uri (pypi-uri "grequests" version))
1882 (sha256
1883 (base32
1884 "1j9icncllbkv7x5719b20mx670c6q1jrdx1sakskkarvx3pc8h8g"))))
1885 (build-system python-build-system)
1886 (propagated-inputs
1887 `(("python-gevent" ,python-gevent)
1888 ("python-requests" ,python-requests)))
1889 (native-inputs
1890 `(("python-nose" ,python-nose)))
1891 (home-page "https://github.com/kennethreitz/grequests")
1892 (synopsis "Python library for asynchronous HTTP requests")
1893 (description "GRequests is a Python library that allows you to use
1894 @code{Requests} with @code{Gevent} to make asynchronous HTTP Requests easily")
1895 (license license:bsd-2)))
1896
1897 (define-public python-geventhttpclient
1898 (package
1899 (name "python-geventhttpclient")
1900 (version "1.3.1")
1901 (source (origin
1902 (method url-fetch)
1903 (uri (pypi-uri "geventhttpclient" version))
1904 (sha256
1905 (base32
1906 "07d0q3wzmml75227r6y6mrl5a0zpf4v9gj0ni5rhbyzmaj4az1xx"))
1907 (modules '((guix build utils)))
1908 (snippet
1909 '(begin
1910 ;; Delete pre-compiled files.
1911 (for-each delete-file (find-files "src/geventhttpclient"
1912 ".*\\.pyc"))
1913 #t))))
1914 (build-system python-build-system)
1915 (arguments
1916 '(#:phases
1917 (modify-phases %standard-phases
1918 (add-after 'unpack 'delete-network-tests
1919 (lambda _
1920 (delete-file "src/geventhttpclient/tests/test_client.py")
1921 #t))
1922 (delete 'check)
1923 (add-after 'install 'check
1924 (lambda* (#:key inputs outputs #:allow-other-keys)
1925 (add-installed-pythonpath inputs outputs)
1926 (invoke "py.test" "src/geventhttpclient/tests" "-v"
1927 ;; Append the test modules to sys.path to avoid
1928 ;; namespace conflict which breaks SSL tests.
1929 "--import-mode=append")
1930 #t)))))
1931 (native-inputs
1932 `(("python-pytest" ,python-pytest)))
1933 (propagated-inputs
1934 `(("python-certifi" ,python-certifi)
1935 ("python-gevent" ,python-gevent)
1936 ("python-six" ,python-six)))
1937 (home-page "https://github.com/gwik/geventhttpclient")
1938 (synopsis "HTTP client library for gevent")
1939 (description "@code{python-geventhttpclient} is a high performance,
1940 concurrent HTTP client library for python using @code{gevent}.")
1941 (license license:expat)))
1942
1943 (define-public python2-geventhttpclient
1944 (package-with-python2 python-geventhttpclient))
1945
1946 (define-public python-requests-oauthlib
1947 (package
1948 (name "python-requests-oauthlib")
1949 (version "1.2.0")
1950 (source
1951 (origin
1952 (method url-fetch)
1953 (uri (pypi-uri "requests-oauthlib" version))
1954 (sha256
1955 (base32
1956 "0mrglgcvq7k48pf27s4gifdk0za8xmgpf55jy15yjj471qrk6rdx"))))
1957 (build-system python-build-system)
1958 (arguments
1959 `(#:phases
1960 (modify-phases %standard-phases
1961 ;; removes tests that require network access
1962 (add-before 'check 'pre-check
1963 (lambda _
1964 (delete-file "tests/test_core.py")
1965 #t)))))
1966 (native-inputs
1967 `(("python-pyjwt" ,python-pyjwt)
1968 ("python-requests-mock" ,python-requests-mock)
1969 ("python-mock" ,python-mock)))
1970 (propagated-inputs
1971 `(("python-oauthlib" ,python-oauthlib)
1972 ("python-requests" ,python-requests)))
1973 (home-page
1974 "https://github.com/requests/requests-oauthlib")
1975 (synopsis
1976 "OAuthlib authentication support for Requests")
1977 (description
1978 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
1979 provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
1980 (license license:isc)))
1981
1982 (define-public python2-requests-oauthlib
1983 (package-with-python2 python-requests-oauthlib))
1984
1985 (define-public python-url
1986 (package
1987 (name "python-url")
1988 (version "0.2.0")
1989 (source (origin
1990 (method url-fetch)
1991 (uri (pypi-uri "url" version))
1992 (sha256
1993 (base32
1994 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
1995 (build-system python-build-system)
1996 (propagated-inputs
1997 `(("python-publicsuffix" ,python-publicsuffix)))
1998 (native-inputs
1999 `(("python-coverage" ,python-coverage)
2000 ("python-nose" ,python-nose)))
2001 (arguments
2002 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
2003 (home-page "https://github.com/seomoz/url-py")
2004 (synopsis "URL Parsing")
2005 (description "Library for parsing urls.")
2006 (license license:expat)
2007 (properties `((python2-variant . ,(delay python2-url))))))
2008
2009 (define-public python2-url
2010 (let ((base (package-with-python2 (strip-python2-variant python-url))))
2011 (package (inherit base)
2012 (propagated-inputs
2013 `(("python2-publicsuffix" ,python2-publicsuffix))))))
2014
2015 (define-public python-cachecontrol
2016 (package
2017 (name "python-cachecontrol")
2018 (version "0.12.5")
2019 (source
2020 (origin
2021 (method git-fetch)
2022 ;; Pypi does not have tests.
2023 (uri (git-reference
2024 (url "https://github.com/ionrock/cachecontrol")
2025 (commit (string-append "v" version))))
2026 (file-name (git-file-name name version))
2027 (sha256
2028 (base32
2029 "03lgc65sl04n0cgzmmgg99bk83f9i6k8yrmcd4hpl46q1pymn0kz"))))
2030 (build-system python-build-system)
2031 (arguments
2032 ;; Versions > 0.11.6 depend on CherryPy for testing.
2033 ;; It's too much work to package CherryPy for now.
2034 `(#:tests? #f))
2035 (propagated-inputs
2036 `(("python-requests" ,python-requests)
2037 ("python-lockfile" ,python-lockfile)))
2038 (home-page "https://github.com/ionrock/cachecontrol")
2039 (synopsis "The httplib2 caching algorithms for use with requests")
2040 (description "CacheControl is a port of the caching algorithms in
2041 @code{httplib2} for use with @code{requests} session objects.")
2042 (license license:asl2.0)))
2043
2044 (define-public python2-cachecontrol
2045 (package-with-python2 python-cachecontrol))
2046
2047 (define-public python-betamax
2048 (package
2049 (name "python-betamax")
2050 (version "0.8.1")
2051 (source
2052 (origin
2053 (method url-fetch)
2054 (uri (pypi-uri "betamax" version))
2055 (sha256
2056 (base32
2057 "1hki1c2vs7adq7zr56wi6i5bhrkia4s2ywpv2c98ibnczz709w2v"))))
2058 (build-system python-build-system)
2059 (arguments
2060 '(;; Many tests fail because they require networking.
2061 #:tests? #f))
2062 (propagated-inputs
2063 `(("python-requests" ,python-requests)))
2064 (home-page "https://github.com/sigmavirus24/betamax")
2065 (synopsis "Record HTTP interactions with python-requests")
2066 (description "Betamax will record your test suite's HTTP interactions and
2067 replay them during future tests. It is designed to work with python-requests.")
2068 (license license:expat)))
2069
2070 (define-public python2-betamax
2071 (package-with-python2 python-betamax))
2072
2073 (define-public python-betamax-matchers
2074 (package
2075 (name "python-betamax-matchers")
2076 (version "0.4.0")
2077 (source
2078 (origin
2079 (method url-fetch)
2080 (uri (pypi-uri "betamax-matchers" version))
2081 (sha256
2082 (base32
2083 "07qpwjyq2i2aqhz5iwghnj4pqr2ys5n45v1vmpcfx9r5mhwrsq43"))))
2084 (build-system python-build-system)
2085 (propagated-inputs
2086 `(("python-betamax" ,python-betamax)
2087 ("python-requests-toolbelt" ,python-requests-toolbelt)))
2088 (home-page "https://github.com/sigmavirus24/betamax_matchers")
2089 (synopsis "VCR imitation for python-requests")
2090 (description "@code{betamax-matchers} provides a set of Matchers for
2091 Betamax.")
2092 (license license:asl2.0)))
2093
2094 (define-public python2-betamax-matchers
2095 (package-with-python2 python-betamax-matchers))
2096
2097 (define-public python-s3transfer
2098 (package
2099 (name "python-s3transfer")
2100 (version "0.2.0")
2101 (source (origin
2102 (method url-fetch)
2103 (uri (pypi-uri "s3transfer" version))
2104 (sha256
2105 (base32
2106 "08fhj73b1ai52hrs2q3nggshq3pswn1gq8ch3m009cb2v2vmqggj"))))
2107 (build-system python-build-system)
2108 (arguments
2109 `(#:phases
2110 (modify-phases %standard-phases
2111 (replace 'check
2112 (lambda _
2113 ;; Some of the 'integration' tests require network access or
2114 ;; login credentials.
2115 (invoke "nosetests" "--exclude=integration")
2116 #t)))))
2117 (native-inputs
2118 `(("python-docutils" ,python-docutils)
2119 ("python-mock" ,python-mock)
2120 ("python-nose" ,python-nose)))
2121 (propagated-inputs
2122 `(("python-botocore" ,python-botocore)
2123 ("python-urllib3" ,python-urllib3)))
2124 (synopsis "Amazon S3 Transfer Manager")
2125 (description "S3transfer is a Python library for managing Amazon S3
2126 transfers.")
2127 (home-page "https://github.com/boto/s3transfer")
2128 (license license:asl2.0)
2129 (properties `((python2-variant . ,(delay python2-s3transfer))))))
2130
2131 (define-public python2-s3transfer
2132 (let ((base (package-with-python2 (strip-python2-variant python-s3transfer))))
2133 (package
2134 (inherit base)
2135 (native-inputs
2136 `(("python2-futures" ,python2-futures)
2137 ,@(package-native-inputs base))))))
2138
2139 (define-public python-slimit
2140 (package
2141 (name "python-slimit")
2142 (version "0.8.1")
2143 (source
2144 (origin
2145 (method url-fetch)
2146 (uri (pypi-uri "slimit" version ".zip"))
2147 (sha256
2148 (base32
2149 "02vj2x728rs1127q2nc27frrqra4fczivnb7gch6n5lzi7pxqczl"))))
2150 (build-system python-build-system)
2151 (native-inputs
2152 `(("unzip" ,unzip)))
2153 (propagated-inputs
2154 `(("python-ply" ,python-ply)))
2155 (home-page "https://slimit.readthedocs.io/")
2156 (synopsis "JavaScript minifier, parser and lexer written in Python")
2157 (description
2158 "SlimIt is a JavaScript minifier written in Python. It compiles
2159 JavaScript into more compact code so that it downloads and runs faster.
2160 SlimIt also provides a library that includes a JavaScript parser, lexer,
2161 pretty printer and a tree visitor.")
2162 (license license:expat)))
2163
2164 (define-public python-flask-restful
2165 (package
2166 (name "python-flask-restful")
2167 (version "0.3.8")
2168 (source
2169 (origin
2170 (method url-fetch)
2171 (uri (pypi-uri "Flask-RESTful" version))
2172 (patches (search-patches "python-flask-restful-werkzeug-compat.patch"))
2173 (sha256
2174 (base32
2175 "05b9lzx5yc3wgml2bcq50lq35h66m8zpj6dc9advcb5z3acsbaay"))))
2176 (build-system python-build-system)
2177 (propagated-inputs
2178 `(("python-aniso8601" ,python-aniso8601)
2179 ("python-flask" ,python-flask)
2180 ("python-pycrypto" ,python-pycrypto)
2181 ("python-pytz" ,python-pytz)))
2182 (native-inputs
2183 `(;; Optional dependency of Flask. Tests need it.
2184 ("python-blinker" ,python-blinker)
2185 ("python-mock" ,python-mock) ; For tests
2186 ("python-nose" ,python-nose))) ;for tests
2187 (home-page
2188 "https://www.github.com/flask-restful/flask-restful/")
2189 (synopsis
2190 "Flask module for creating REST APIs")
2191 (description
2192 "This package contains a Flask module for creating REST APIs.")
2193 (license license:bsd-3)))
2194
2195 (define-public python-flask-basicauth
2196 (package
2197 (name "python-flask-basicauth")
2198 (version "0.2.0")
2199 (source
2200 (origin
2201 (method url-fetch)
2202 (uri (pypi-uri "Flask-BasicAuth" version))
2203 (sha256
2204 (base32
2205 "1zq1spkjr4sjdnalpp8wl242kdqyk6fhbnhr8hi4r4f0km4bspnz"))))
2206 (build-system python-build-system)
2207 (propagated-inputs
2208 `(("python-flask" ,python-flask)))
2209 (home-page
2210 "https://github.com/jpvanhal/flask-basicauth")
2211 (synopsis
2212 "HTTP basic access authentication for Flask")
2213 (description
2214 "This package provides HTTP basic access authentication for Flask.")
2215 (license license:bsd-3)))
2216
2217 (define-public python-flask-htpasswd
2218 (package
2219 (name "python-flask-htpasswd")
2220 (version "0.3.1")
2221 (source
2222 (origin
2223 (method url-fetch)
2224 (uri (pypi-uri "flask-htpasswd" version))
2225 (sha256
2226 (base32
2227 "14q1y1y9i9bhabdnwd25jqzc4ljli23smxfyyh8abxz1vq93pxra"))))
2228 (build-system python-build-system)
2229 (propagated-inputs
2230 `(("python-flask" ,python-flask)
2231 ("python-itsdangerous" ,python-itsdangerous)
2232 ("python-passlib" ,python-passlib)
2233 ("python-tox" ,python-tox)))
2234 (home-page "http://github.com/carsongee/flask-htpasswd")
2235 (synopsis "Basic authentication via htpasswd files in Flask applications")
2236 (description "This package provides Basic authentication via
2237 @file{htpasswd} files and access_token authentication in Flask
2238 applications.")
2239 (license license:bsd-3)))
2240
2241 (define-public python-flask-sqlalchemy
2242 (package
2243 (name "python-flask-sqlalchemy")
2244 (version "2.4.0")
2245 (source (origin
2246 (method url-fetch)
2247 (uri (pypi-uri "Flask-SQLAlchemy" version))
2248 (sha256
2249 (base32
2250 "0nnllf0ddbh9jlhngnyjj98lbxgxr1csaplllx0caw98syq0k5hc"))))
2251 (build-system python-build-system)
2252 (propagated-inputs
2253 `(("python-flask" ,python-flask)
2254 ("python-sqlalchemy" ,python-sqlalchemy)))
2255 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
2256 (synopsis "Module adding SQLAlchemy support to your Flask application")
2257 (description
2258 "This package adds SQLAlchemy support to your Flask application.")
2259 (license license:bsd-3)))
2260
2261 (define-public python-flask-restplus
2262 (package
2263 (name "python-flask-restplus")
2264 (version "0.9.2")
2265 (source
2266 (origin
2267 (method url-fetch)
2268 (uri (pypi-uri "flask-restplus" version))
2269 (sha256
2270 (base32
2271 "11his6ii5brpkhld0d5bwzjjw4q3vmplpd6fmgzjrvvklsbk0cf4"))))
2272 (build-system python-build-system)
2273 (arguments
2274 '(#:tests? #f)) ; FIXME: 35/882 tests failing.
2275 ;; #:phases
2276 ;; (modify-phases %standard-phases
2277 ;; (replace 'check
2278 ;; (lambda _
2279 ;; (invoke "nosetests")
2280 ;; #t)))))
2281 (propagated-inputs
2282 `(("python-aniso8601" ,python-aniso8601)
2283 ("python-flask" ,python-flask)
2284 ("python-jsonschema" ,python-jsonschema)
2285 ("python-pytz" ,python-pytz)
2286 ("python-six" ,python-six)))
2287 (native-inputs
2288 `(("python-tzlocal" ,python-tzlocal)
2289 ("python-blinker" ,python-blinker)
2290 ("python-nose" ,python-nose)
2291 ("python-rednose" ,python-rednose)))
2292 (home-page "https://github.com/noirbizarre/flask-restplus")
2293 (synopsis "Framework for documented API development with Flask")
2294 (description "This package provides a framework for API development with
2295 the Flask web framework in Python. It is similar to package
2296 @code{python-flask-restful} but supports the @code{python-swagger}
2297 documentation builder.")
2298 (license license:expat)))
2299
2300 (define-public python-flask-restful-swagger
2301 (package
2302 (name "python-flask-restful-swagger")
2303 (version "0.20.1")
2304 (source
2305 (origin
2306 (method url-fetch)
2307 (uri (pypi-uri "flask-restful-swagger" version))
2308 (sha256
2309 (base32
2310 "1p66f98b5zpypnnz56pxpbirchqj6aniw6qyrp8h572l0dn9xlvq"))))
2311 (build-system python-build-system)
2312 (arguments '(#:tests? #f)) ;no tests
2313 (propagated-inputs
2314 `(("python-flask-restful" ,python-flask-restful)))
2315 (home-page "https://github.com/rantav/flask-restful-swagger")
2316 (synopsis "Extract Swagger specs from Flask-Restful projects")
2317 (description "This package lets you extract Swagger API documentation
2318 specs from your Flask-Restful projects.")
2319 (license license:expat)))
2320
2321 (define-public python2-flask-restful-swagger
2322 (package-with-python2 python-flask-restful-swagger))
2323
2324 (define-public python-htmlmin
2325 (package
2326 (name "python-htmlmin")
2327 (version "0.1.12")
2328 (source
2329 (origin
2330 (method url-fetch)
2331 (uri (pypi-uri "htmlmin" version))
2332 (sha256
2333 (base32
2334 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
2335 (arguments
2336 `(#:tests? #f)) ; no tests
2337 (build-system python-build-system)
2338 (home-page "https://htmlmin.readthedocs.org/en/latest/")
2339 (synopsis "HTML minifier")
2340 (description "@code{htmlmin} is an HTML minifier that just works.
2341 It comes with safe defaults and easily configurable options.")
2342 (license license:bsd-3)))
2343
2344 (define-public python2-htmlmin
2345 (package-with-python2 python-htmlmin))
2346
2347 (define-public python-flask-htmlmin
2348 (package
2349 (name "python-flask-htmlmin")
2350 (version "1.2")
2351 (source
2352 (origin
2353 (method url-fetch)
2354 (uri (pypi-uri "Flask-HTMLmin" version))
2355 (sha256
2356 (base32
2357 "1n6zlq72kakkw0z2jpq6nh74lfsmxybm4g053pwhc14fbr809348"))))
2358 (propagated-inputs
2359 `(("python-flask" ,python-flask)
2360 ("python-htmlmin" ,python-htmlmin)))
2361 (build-system python-build-system)
2362 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
2363 (synopsis "HTML response minifier for Flask")
2364 (description
2365 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
2366 (license license:bsd-3)))
2367
2368 (define-public python2-flask-htmlmin
2369 (package-with-python2 python-flask-htmlmin))
2370
2371 (define-public python-jsmin
2372 (package
2373 (name "python-jsmin")
2374 (version "2.2.2")
2375 (source
2376 (origin
2377 (method url-fetch)
2378 (uri (pypi-uri "jsmin" version))
2379 (sha256
2380 (base32
2381 "0fsmqbjvpxvff0984x7c0y8xmf49ax9mncz48b9xjx8wrnr9kpxn"))))
2382 (build-system python-build-system)
2383 (home-page "https://github.com/tikitu/jsmin/")
2384 (synopsis "Python JavaScript minifier")
2385 (description
2386 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
2387 on the command line.")
2388 (license license:expat)))
2389
2390 (define-public python-flask-login
2391 (package
2392 (name "python-flask-login")
2393 (version "0.5.0")
2394 (source
2395 (origin
2396 (method git-fetch)
2397 (uri (git-reference
2398 (url "https://github.com/maxcountryman/flask-login.git")
2399 (commit version)))
2400 (file-name (git-file-name name version))
2401 (sha256
2402 (base32 "11ac924w0y4m0kf3mxnxdlidy88jfa7njw5yyrq16dvnx4iwd8gg"))))
2403 (build-system python-build-system)
2404 (propagated-inputs
2405 `(("python-flask" ,python-flask)))
2406 (native-inputs
2407 ;; For tests.
2408 `(("python-blinker" ,python-blinker)
2409 ("python-coverage" ,python-coverage)
2410 ("python-mock" ,python-mock)
2411 ("python-pycodestyle" ,python-pycodestyle)
2412 ("python-pyflakes" ,python-pyflakes)
2413 ("python-pytest" ,python-pytest)
2414 ("python-semantic-version" ,python-semantic-version)
2415 ("python-werkzeug" ,python-werkzeug)))
2416 (home-page "https://github.com/maxcountryman/flask-login")
2417 (synopsis "User session management for Flask")
2418 (description
2419 "@code{Flask-Login} provides user session management for Flask. It
2420 handles the common tasks of logging in, logging out, and remembering your
2421 users' sessions over extended periods of time.")
2422 (license license:expat)))
2423
2424 (define-public python2-flask-login
2425 (package-with-python2 python-flask-login))
2426
2427 (define-public python-oauth2client
2428 (package
2429 (name "python-oauth2client")
2430 (version "4.0.0")
2431 (source
2432 (origin
2433 (method url-fetch)
2434 (uri (pypi-uri "oauth2client" version))
2435 (sha256
2436 (base32
2437 "1irqqap2zibysf8dba8sklfqikia579srd0phm5n754ni0h59gl0"))))
2438 (build-system python-build-system)
2439 (arguments
2440 `(#:tests? #f))
2441 (propagated-inputs
2442 `(("python-httplib2" ,python-httplib2)
2443 ("python-pyasn1" ,python-pyasn1)
2444 ("python-pyasn1-modules" ,python-pyasn1-modules)
2445 ("python-rsa" ,python-rsa)
2446 ("python-six" ,python-six)))
2447 (home-page "https://github.com/google/oauth2client/")
2448 (synopsis "OAuth 2.0 client library")
2449 (description "@code{python-oauth2client} provides an OAuth 2.0 client
2450 library for Python")
2451 (license license:asl2.0)))
2452
2453 (define-public python2-oauth2client
2454 (package-with-python2 python-oauth2client))
2455
2456 (define-public python-flask-oidc
2457 (package
2458 (name "python-flask-oidc")
2459 (version "1.1.1")
2460 (source
2461 (origin
2462 (method url-fetch)
2463 (uri (pypi-uri "flask-oidc" version))
2464 (sha256
2465 (base32
2466 "1ay5j0mf174bix7i67hclr95gv16z81fpx0dijvi0gydvdj3ddy2"))))
2467 (build-system python-build-system)
2468 (propagated-inputs
2469 `(("python-flask" ,python-flask)
2470 ("python-itsdangerous" ,python-itsdangerous)
2471 ("python-oauth2client" ,python-oauth2client)
2472 ("python-six" ,python-six)))
2473 (native-inputs
2474 `(("python-nose" ,python-nose)
2475 ("python-mock" ,python-mock)))
2476 (home-page "https://github.com/puiterwijk/flask-oidc")
2477 (synopsis "OpenID Connect extension for Flask")
2478 (description "@code{python-flask-oidc} provides an OpenID Connect extension
2479 for Flask.")
2480 (license license:bsd-2)))
2481
2482 (define-public python-webassets
2483 (package
2484 (name "python-webassets")
2485 (version "0.12.1")
2486 (source
2487 (origin
2488 (method url-fetch)
2489 (uri (pypi-uri "webassets" version))
2490 (sha256
2491 (base32
2492 "1nrqkpb7z46h2b77xafxihqv3322cwqv6293ngaky4j3ff4cing7"))))
2493 (build-system python-build-system)
2494 (native-inputs
2495 `(("python-jinja2" ,python-jinja2)
2496 ("python-mock" ,python-mock)
2497 ("python-nose" ,python-nose)
2498 ("python-pytest" ,python-pytest)))
2499 (home-page "https://github.com/miracle2k/webassets")
2500 (synopsis "Media asset management")
2501 (description "Merges, minifies and compresses Javascript and CSS files,
2502 supporting a variety of different filters, including YUI, jsmin, jspacker or
2503 CSS tidy. Also supports URL rewriting in CSS files.")
2504 (license license:bsd-2)))
2505
2506 (define-public python-cssmin
2507 (package
2508 (name "python-cssmin")
2509 (version "0.2.0")
2510 (source
2511 (origin
2512 (method url-fetch)
2513 (uri (pypi-uri "cssmin" version))
2514 (sha256
2515 (base32
2516 "1dk723nfm2yf8cp4pj785giqlwv42l0kj8rk40kczvq1hk6g04p0"))))
2517 (build-system python-build-system)
2518 (home-page "https://github.com/zacharyvoase/cssmin")
2519 (synopsis "Python port of the YUI CSS Compressor")
2520 (description "Python port of the YUI CSS Compressor.")
2521 (license (list license:expat license:bsd-3))))
2522
2523 (define-public python2-cssmin
2524 (package-with-python2 python-cssmin))
2525
2526 (define-public python-elasticsearch
2527 (package
2528 (name "python-elasticsearch")
2529 (version "7.1.0")
2530 (source
2531 (origin
2532 (method url-fetch)
2533 (uri (pypi-uri "elasticsearch" version))
2534 (sha256
2535 (base32
2536 "0rnjvlhw4v3vg14l519qliy1s1zpmx3827q0xfviwvk42rr7hh01"))))
2537 (build-system python-build-system)
2538 (native-inputs
2539 `(("python-mock" ,python-mock)
2540 ("python-nosexcover" ,python-nosexcover)
2541 ("python-pyaml" ,python-pyaml)
2542 ("python-requests" ,python-requests)))
2543 (propagated-inputs
2544 `(("urllib3" ,python-urllib3)))
2545 (arguments
2546 ;; tests require the test_elasticsearch module but it is not distributed.
2547 `(#:tests? #f))
2548 (home-page "https://github.com/elastic/elasticsearch-py")
2549 (synopsis "Low-level client for Elasticsearch")
2550 (description "Official low-level client for Elasticsearch. Its goal is to
2551 provide common ground for all Elasticsearch-related code in Python; because of
2552 this it tries to be opinion-free and very extendable.")
2553 (license license:expat)))
2554
2555 (define-public python2-elasticsearch
2556 (package-with-python2 python-elasticsearch))
2557
2558 (define-public python-flask-script
2559 (package
2560 (name "python-flask-script")
2561 (version "2.0.6")
2562 (source
2563 (origin
2564 (method url-fetch)
2565 (uri (pypi-uri "Flask-Script" version))
2566 (sha256
2567 (base32
2568 "0r8w2v89nj6b9p91p495cga5m72a673l2wc0hp0zqk05j4yrc9b4"))))
2569 (build-system python-build-system)
2570 (arguments
2571 `(#:phases
2572 (modify-phases %standard-phases
2573 (add-after 'unpack 'patch-tests
2574 (lambda _
2575 (substitute* "tests.py"
2576 (("flask\\.ext\\.script") "flask_script"))
2577 #t)))))
2578 (propagated-inputs
2579 `(("python-flask" ,python-flask)
2580 ("python-argcomplete" ,python-argcomplete)
2581 ("python-werkzeug" ,python-werkzeug)))
2582 (native-inputs
2583 `(("python-pytest" ,python-pytest)))
2584 (home-page
2585 "https://github.com/smurfix/flask-script")
2586 (synopsis "Scripting support for Flask")
2587 (description "The Flask-Script extension provides support for writing
2588 external scripts in Flask. This includes running a development server,
2589 a customised Python shell, scripts to set up your database, cronjobs,
2590 and other command-line tasks that belong outside the web application
2591 itself.")
2592 (license license:bsd-3)))
2593
2594 (define-public python2-flask-script
2595 (package-with-python2 python-flask-script))
2596
2597 (define-public python-flask-migrate
2598 (package
2599 (name "python-flask-migrate")
2600 (version "2.5.3")
2601 (source
2602 (origin
2603 (method url-fetch)
2604 (uri (pypi-uri "Flask-Migrate" version))
2605 (sha256
2606 (base32
2607 "1vip9ww6l18dxffjsggm83k71zkvihxpnhaswpv8klh95s6517d6"))))
2608 (build-system python-build-system)
2609 (propagated-inputs
2610 `(("python-flask" ,python-flask)
2611 ("python-alembic" ,python-alembic)
2612 ("python-sqlalchemy" ,python-sqlalchemy)
2613 ("python-flask-script" ,python-flask-script)
2614 ("python-flask-sqlalchemy" ,python-flask-sqlalchemy)))
2615 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
2616 (synopsis "SQLAlchemy database migrations for Flask programs using
2617 Alembic")
2618 (description "This package contains SQLAlchemy database migration tools
2619 for Flask programs that are using @code{python-alembic}.")
2620 (license license:expat)))
2621
2622 (define-public python-genshi
2623 (package
2624 (name "python-genshi")
2625 (version "0.7.2")
2626 (source
2627 (origin
2628 (method git-fetch)
2629 (uri (git-reference
2630 (url "https://github.com/edgewall/genshi.git")
2631 (commit version)))
2632 (file-name (git-file-name name version))
2633 (sha256
2634 (base32 "06rch30x10l105k5b6rahd839lkhmgrzn6691wbci0cb2fzps32w"))))
2635 (build-system python-build-system)
2636 (home-page "https://genshi.edgewall.org/")
2637 (synopsis "Toolkit for generation of output for the web")
2638 (description "Genshi is a Python library that provides an integrated set
2639 of components for parsing, generating, and processing HTML, XML or other
2640 textual content for output generation on the web.")
2641 (license license:bsd-3)))
2642
2643 (define-public python2-genshi
2644 (package-with-python2 python-genshi))
2645
2646 (define-public python-flask-principal
2647 (package
2648 (name "python-flask-principal")
2649 (version "0.4.0")
2650 (source
2651 (origin
2652 (method url-fetch)
2653 (uri (pypi-uri "Flask-Principal" version))
2654 (sha256
2655 (base32
2656 "0lwlr5smz8vfm5h9a9i7da3q1c24xqc6vm9jdywdpgxfbi5i7mpm"))))
2657 (build-system python-build-system)
2658 (propagated-inputs
2659 `(("python-blinker" ,python-blinker)))
2660 (native-inputs
2661 `(("python-flask" ,python-flask)
2662 ("python-nose" ,python-nose)))
2663 (home-page "https://pythonhosted.org/Flask-Principal/")
2664 (synopsis "Identity management for Flask")
2665 (description "@code{flask_principal} is a identity management library for
2666 Flask. It supports managing both authentication and authorization data in a
2667 thread-local variable.")
2668 (license license:expat)))
2669
2670 (define-public python2-flask-principal
2671 (package-with-python2 python-flask-principal))
2672
2673 (define-public python-flask-httpauth
2674 (package
2675 (name "python-flask-httpauth")
2676 (version "3.2.3")
2677 (source
2678 (origin
2679 (method url-fetch)
2680 (uri (pypi-uri "Flask-HTTPAuth" version))
2681 (sha256
2682 (base32
2683 "13gff5w1mqpzm5nccyg02v3ifb9ifqh5k866cssjhghhg6msfjsz"))))
2684 (build-system python-build-system)
2685 (native-inputs
2686 `(("python-flask" ,python-flask)))
2687 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
2688 (synopsis "Basic and Digest HTTP authentication for Flask routes")
2689 (description "@code{flask_httpauth} provides Basic and Digest HTTP
2690 authentication for Flask routes.")
2691 (license license:expat)))
2692
2693 (define-public python2-flask-httpauth
2694 (package-with-python2 python-flask-httpauth))
2695
2696 (define-public python-uritemplate
2697 (package
2698 (name "python-uritemplate")
2699 (version "3.0.0")
2700 (source
2701 (origin
2702 (method url-fetch)
2703 (uri (pypi-uri "uritemplate" version))
2704 (sha256
2705 (base32
2706 "0781gm9g34wa0asc19dx81ng0nqq07igzv3bbvdqmz13pv7469n0"))))
2707 (build-system python-build-system)
2708 (home-page "https://uritemplate.readthedocs.org")
2709 (synopsis "Library to deal with URI Templates")
2710 (description "@code{uritemplate} provides Python library to deal with URI
2711 Templates.")
2712 (license license:bsd-2)))
2713
2714 (define-public python2-uritemplate
2715 (package-with-python2 python-uritemplate))
2716
2717 (define-public python-publicsuffix
2718 (package
2719 (name "python-publicsuffix")
2720 (version "1.1.0")
2721 (source (origin
2722 (method url-fetch)
2723 (uri (pypi-uri "publicsuffix" version))
2724 (sha256
2725 (base32
2726 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
2727 (build-system python-build-system)
2728 (arguments
2729 `(#:tests? #f)) ; tests use the internet
2730 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
2731 (synopsis "Get suffix for a domain name")
2732 (description "Get a public suffix for a domain name using the Public Suffix
2733 List.")
2734 (license license:expat)))
2735
2736 (define-public python2-publicsuffix
2737 (package-with-python2 python-publicsuffix))
2738
2739 (define-public python-publicsuffix2
2740 (package
2741 (name "python-publicsuffix2")
2742 (version "2.20191221")
2743 (source
2744 (origin
2745 (method url-fetch)
2746 (uri (pypi-uri "publicsuffix2" version))
2747 (sha256
2748 (base32 "0yzysvfj1najr1mb4pcqrbmjir3xpb69rlffln95a3cdm8qwry00"))))
2749 (build-system python-build-system)
2750 (arguments
2751 '(#:phases
2752 (modify-phases %standard-phases
2753 (add-after 'unpack 'ignore-maintainer-inputs
2754 (lambda _
2755 ;; Comment out a demand for python-requests, which is used only by
2756 ;; the unused ‘update_psl’ helper command.
2757 (substitute* "setup.py"
2758 (("'requests " match)
2759 (format "# ~a" match)))
2760 #t)))
2761 #:tests? #f)) ; the test suite requires network access
2762 (home-page "https://github.com/pombredanne/python-publicsuffix2")
2763 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
2764 (description "Get a public suffix for a domain name using the Public Suffix
2765 List. Forked from and using the same API as the publicsuffix package.")
2766 (license (list license:expat license:mpl2.0))))
2767
2768 (define-public python2-publicsuffix2
2769 (package-with-python2 python-publicsuffix2))
2770
2771 (define-public python-werkzeug
2772 (package
2773 (name "python-werkzeug")
2774 (version "1.0.0")
2775 (source
2776 (origin
2777 (method url-fetch)
2778 (uri (pypi-uri "Werkzeug" version))
2779 (sha256
2780 (base32
2781 "15kh0z61klp62mrc1prka13xsshxn0rsp1j1s2964iw86yisi6qn"))))
2782 (build-system python-build-system)
2783 (arguments
2784 '(#:phases
2785 (modify-phases %standard-phases
2786 (delete 'check)
2787 (add-after 'install 'check
2788 (lambda* (#:key inputs outputs #:allow-other-keys)
2789 (add-installed-pythonpath inputs outputs)
2790 (invoke "python" "-m" "pytest"))))))
2791 (propagated-inputs
2792 `(("python-requests" ,python-requests)))
2793 (native-inputs
2794 `(("python-pytest" ,python-pytest)
2795 ("python-pytest-timeout" ,python-pytest-timeout)))
2796 (home-page "https://www.palletsprojects.org/p/werkzeug/")
2797 (synopsis "Utilities for WSGI applications")
2798 (description "One of the most advanced WSGI utility modules. It includes a
2799 powerful debugger, full-featured request and response objects, HTTP utilities to
2800 handle entity tags, cache control headers, HTTP dates, cookie handling, file
2801 uploads, a powerful URL routing system and a bunch of community-contributed
2802 addon modules.")
2803 (license license:x11)))
2804
2805 (define-public python2-werkzeug
2806 (package-with-python2 python-werkzeug))
2807
2808 (define-public python-bottle
2809 (package
2810 (name "python-bottle")
2811 (version "0.12.13")
2812 (source
2813 (origin
2814 (method url-fetch)
2815 (uri (pypi-uri "bottle" version))
2816 (sha256
2817 (base32
2818 "0m9k2a7yxvggc4kw8fsvj381vgsvfcdshg5nzy6vwrxiw2p53drr"))))
2819 (build-system python-build-system)
2820 (home-page "http://bottlepy.org/")
2821 (synopsis "WSGI framework for small web-applications.")
2822 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
2823 (license license:expat)))
2824
2825 (define-public python2-bottle
2826 (package-with-python2 python-bottle))
2827
2828 (define-public python-wtforms
2829 (package
2830 (name "python-wtforms")
2831 (version "2.1")
2832 (source
2833 (origin
2834 (method url-fetch)
2835 (uri (pypi-uri "WTForms" version ".zip"))
2836 (sha256
2837 (base32
2838 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
2839 (build-system python-build-system)
2840 (arguments
2841 '(#:phases
2842 (modify-phases %standard-phases
2843 (add-after 'unpack 'remove-django-test
2844 ;; Don't fail the tests when the inputs for the optional tests cannot be found.
2845 (lambda _
2846 (substitute*
2847 "tests/runtests.py"
2848 (("'ext_django.tests', 'ext_sqlalchemy', 'ext_dateutil', 'locale_babel'") "")
2849 (("sys.stderr.write(\"### Disabled test '%s', dependency not found\n\" % name)") ""))
2850 #t)))))
2851 (native-inputs
2852 `(("unzip" ,unzip)))
2853 (home-page "http://wtforms.simplecodes.com/")
2854 (synopsis
2855 "Form validation and rendering library for Python web development")
2856 (description
2857 "WTForms is a flexible forms validation and rendering library
2858 for Python web development. It is very similar to the web form API
2859 available in Django, but is a standalone package.")
2860 (license license:bsd-3)))
2861
2862 (define-public python2-wtforms
2863 (package-with-python2 python-wtforms))
2864
2865 (define-public python-paste
2866 (package
2867 (name "python-paste")
2868 (version "3.0.6")
2869 (source
2870 (origin
2871 (method url-fetch)
2872 (uri (pypi-uri "Paste" version))
2873 (sha256
2874 (base32
2875 "14lbi9asn5agsdf7r97prkjpz7amgmp529lbvfhf0nv881xczah6"))
2876 (patches (search-patches "python-paste-remove-timing-test.patch"))
2877 (modules '((guix build utils)))
2878 (snippet
2879 '(begin
2880 ;; This test calls out to the internet.
2881 (delete-file "tests/test_proxy.py") #t))))
2882 (build-system python-build-system)
2883 (native-inputs
2884 `(("python-pytest" ,python-pytest)
2885 ("python-pytest-runner" ,python-pytest-runner)
2886 ("python-nose" ,python-nose)))
2887 (propagated-inputs
2888 `(("python-six" ,python-six)))
2889 (home-page "https://pythonpaste.readthedocs.io/")
2890 (synopsis
2891 "Python web development tools, focusing on WSGI")
2892 (description
2893 "Paste provides a variety of web development tools and middleware which
2894 can be nested together to build web applications. Paste's design closely
2895 follows ideas flowing from WSGI (Web Standard Gateway Interface).")
2896 (license license:expat)))
2897
2898 (define-public python2-paste
2899 (package-with-python2 python-paste))
2900
2901 (define-public python-pastescript
2902 (package
2903 (name "python-pastescript")
2904 (version "2.0.2")
2905 (source
2906 (origin
2907 (method url-fetch)
2908 (uri (pypi-uri "PasteScript" version))
2909 (sha256
2910 (base32
2911 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
2912 (build-system python-build-system)
2913 (native-inputs
2914 `(("python-nose" ,python-nose)))
2915 (propagated-inputs
2916 `(("python-paste" ,python-paste)
2917 ("python-pastedeploy" ,python-pastedeploy)))
2918 (home-page (string-append "https://web.archive.org/web/20161025192515/"
2919 "http://pythonpaste.org/script/"))
2920 (arguments
2921 '(;; Unfortunately, this requires the latest unittest2,
2922 ;; but that requires traceback2 which requires linecache2 which requires
2923 ;; unittest2. So we're skipping tests for now.
2924 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
2925 ;; so in theory we could get around this situation somehow.)
2926 #:tests? #f))
2927 (synopsis
2928 "Pluggable command line tool for serving web applications and more")
2929 (description
2930 "PasteScript is a plugin-friendly command line tool which provides a
2931 variety of features, from launching web applications to bootstrapping project
2932 layouts.")
2933 (license license:expat)))
2934
2935 (define-public python2-pastescript
2936 (package-with-python2 python-pastescript))
2937
2938 (define-public python2-urlgrabber
2939 (package
2940 (name "python2-urlgrabber")
2941 (version "3.10.2")
2942 (source
2943 (origin
2944 (method url-fetch)
2945 (uri (pypi-uri "urlgrabber" version))
2946 (sha256
2947 (base32 "0w1h7hlsq406bxfy2pn4i9bd003bwl0q9b7p03z3g6yl0d21ddq5"))))
2948 (build-system python-build-system)
2949 (arguments `(#:python ,python-2)) ; urlgrabber supports python2 only
2950 (home-page "http://urlgrabber.baseurl.org")
2951 (synopsis "High-level cross protocol url-grabber")
2952 (description "@code{urlgrabber} is Python2 library that unifies access to
2953 files available on web, FTP or locally. It supports HTTP, FTP and file://
2954 protocols, it supports features like HTTP keep-alive, reget, throttling and
2955 more.")
2956 (license license:lgpl2.1+)))
2957
2958 (define-public python-pycares
2959 (package
2960 (name "python-pycares")
2961 (version "2.3.0")
2962 (source
2963 (origin
2964 (method url-fetch)
2965 (uri (pypi-uri "pycares" version))
2966 (sha256
2967 (base32
2968 "0h4fxw5drrhfyslzmfpljk0qnnpbhhb20hnnndzahhbwylyw1x1n"))))
2969 (build-system python-build-system)
2970 (arguments
2971 `(#:tests? #f)) ;tests require internet access
2972 (home-page "http://github.com/saghul/pycares")
2973 (synopsis "Python interface for @code{c-ares}")
2974 (description "@code{pycares} is a Python module which provides an
2975 interface to @code{c-ares}, a C library that performs DNS requests and
2976 name resolutions asynchronously.")
2977 (license license:expat)))
2978
2979 (define-public python-yarl
2980 (package
2981 (name "python-yarl")
2982 (version "1.1.1")
2983 (source
2984 (origin
2985 (method url-fetch)
2986 (uri (pypi-uri "yarl" version))
2987 (sha256
2988 (base32
2989 "1s6z13g8vgxfkkqwhn6imnm7pl7ky9arv4jygnn6bcndcbidg7d6"))))
2990 (build-system python-build-system)
2991 (native-inputs
2992 `(("python-pytest" ,python-pytest)
2993 ("python-pytest-runner" ,python-pytest-runner)))
2994 (propagated-inputs
2995 `(("python-idna" ,python-idna)
2996 ("python-multidict" ,python-multidict)))
2997 (home-page "https://github.com/aio-libs/yarl/")
2998 (synopsis "Yet another URL library")
2999 (description "@code{yarl} module provides handy @code{URL} class
3000 for URL parsing and changing.")
3001 (license license:asl2.0)))
3002
3003 (define-public python-google-api-client
3004 (package
3005 (name "python-google-api-client")
3006 (version "1.6.7")
3007 (source
3008 (origin
3009 (method url-fetch)
3010 (uri (pypi-uri "google-api-python-client" version))
3011 (sha256
3012 (base32
3013 "1wpbbbxfpy9mwxdy3kn352cb590ladv574j1aa2l4grjdqw3ln05"))))
3014 (build-system python-build-system)
3015 (arguments
3016 '(#:tests? #f)) ; tests require internet access
3017 (native-inputs
3018 `(("python-httplib2" ,python-httplib2)
3019 ("python-six" ,python-six)
3020 ("python-oauth2client" ,python-oauth2client)
3021 ("python-uritemplate" ,python-uritemplate)))
3022 (home-page "https://github.com/google/google-api-python-client")
3023 (synopsis "Core Python library for accessing Google APIs")
3024 (description "Python client library for Google's discovery based APIs")
3025 (license license:asl2.0)))
3026
3027 (define-public python2-google-api-client
3028 (package-with-python2 python-google-api-client))
3029
3030 (define-public python-hawkauthlib
3031 (package
3032 (name "python-hawkauthlib")
3033 (version "2.0.0")
3034 (source
3035 (origin
3036 (method url-fetch)
3037 (uri (pypi-uri "hawkauthlib" version))
3038 (sha256
3039 (base32
3040 "03ai47s4h8nfnrf25shbfvkm1b9n1ccd4nmmj280sg1fayi69zgg"))))
3041 (build-system python-build-system)
3042 (propagated-inputs
3043 `(("python-requests" ,python-requests)
3044 ("python-webob" ,python-webob)))
3045 (home-page "https://github.com/mozilla-services/hawkauthlib")
3046 (synopsis "Hawk Access Authentication protocol")
3047 (description
3048 "This is a low-level Python library for implementing Hawk Access Authentication,
3049 a simple HTTP request-signing scheme.")
3050 (license license:mpl2.0)))
3051
3052 (define-public python-pybrowserid
3053 (package
3054 (name "python-pybrowserid")
3055 (version "0.14.0")
3056 (source
3057 (origin
3058 (method url-fetch)
3059 (uri (pypi-uri "PyBrowserID" version))
3060 (sha256
3061 (base32
3062 "1qvi79kfb8x9kxkm5lw2mp42hm82cpps1xknmsb5ghkwx1lpc8kc"))))
3063 (build-system python-build-system)
3064 (propagated-inputs
3065 `(("python-requests" ,python-requests)))
3066 (native-inputs
3067 `(("python-mock" ,python-mock)))
3068 (home-page "https://github.com/mozilla/PyBrowserID")
3069 (synopsis "Python library for the BrowserID protocol")
3070 (description
3071 "This is a Python client library for the BrowserID protocol that
3072 underlies Mozilla Persona.")
3073 (license license:mpl2.0)))
3074
3075 (define-public python-pyfxa
3076 (package
3077 (name "python-pyfxa")
3078 (version "0.6.0")
3079 (source
3080 (origin
3081 (method url-fetch)
3082 (uri (pypi-uri "PyFxA" version))
3083 (sha256
3084 (base32
3085 "0axl16fyrz2r88gnw4b12mk7dpkqscv8c4wsc1y5hicl7bsbc4fm"))))
3086 (build-system python-build-system)
3087 (arguments '(#:tests? #f)) ; 17 tests require network access
3088 (propagated-inputs
3089 `(("python-cryptography" ,python-cryptography)
3090 ("python-hawkauthlib" ,python-hawkauthlib)
3091 ("python-pybrowserid" ,python-pybrowserid)
3092 ("python-requests" ,python-requests)
3093 ("python-six" ,python-six)))
3094 (native-inputs
3095 `(("python-grequests" ,python-grequests)
3096 ("python-mock" ,python-mock)
3097 ("python-responses" ,python-responses)
3098 ("python-unittest2" ,python-unittest2)))
3099 (home-page "https://github.com/mozilla/PyFxA")
3100 (synopsis "Firefox Accounts client library for Python")
3101 (description
3102 "This is a Python library for interacting with the Firefox Accounts
3103 ecosystem.")
3104 (license license:mpl2.0)))
3105
3106 (define-public python-hyperlink
3107 (package
3108 (name "python-hyperlink")
3109 (version "19.0.0")
3110 (source
3111 (origin
3112 (method url-fetch)
3113 (uri (pypi-uri "hyperlink" version))
3114 (sha256
3115 (base32
3116 "0m2nhi0j8wmgfscf974wd5v1xfq8mah286hil6npy1ys0m3y7222"))))
3117 (build-system python-build-system)
3118 (propagated-inputs
3119 `(("python-idna" ,python-idna)))
3120 (home-page "https://github.com/python-hyper/hyperlink")
3121 (synopsis "Python module to create immutable URLs according to spec")
3122 (description "This package provides a Python module to create immutable, and
3123 correct URLs for Python according to RFCs 3986 and 3987.")
3124 (license license:expat)))
3125
3126 (define-public python-treq
3127 (package
3128 (name "python-treq")
3129 (version "18.6.0")
3130 (source
3131 (origin
3132 (method url-fetch)
3133 (uri (pypi-uri "treq" version))
3134 (sha256
3135 (base32
3136 "0j4zwq9p1c9piv1vc66nxcv9s6hdinf90jwkbsm91k14npv9zq4i"))))
3137 (build-system python-build-system)
3138 (propagated-inputs
3139 `(("python-attrs" ,python-attrs)
3140 ("python-idna" ,python-idna)
3141 ("python-incremental" ,python-incremental)
3142 ("python-requests" ,python-requests)
3143 ("python-service-identity" ,python-service-identity)
3144 ("python-twisted" ,python-twisted)))
3145 (home-page "https://github.com/twisted/treq")
3146 (synopsis "Requests-like API built on top of twisted.web's Agent")
3147 (description "This package provides an HTTP library inspired by
3148 @code{requests}} but written on top of Twisted's @code{Agents}. It offers a
3149 high level API for making HTTP requests when using Twisted.")
3150 (license license:expat)))
3151
3152 (define-public python-autobahn
3153 (package
3154 (name "python-autobahn")
3155 (version "19.2.1")
3156 (source
3157 (origin
3158 (method url-fetch)
3159 (uri (pypi-uri "autobahn" version))
3160 (sha256
3161 (base32
3162 "1mm7j24ls01c7jb1ad5p5cpyxvzgydiyf8b04ihykh2v8g98j0x7"))))
3163 (build-system python-build-system)
3164 (arguments
3165 ;; The tests fail to run:
3166 ;; https://github.com/crossbario/autobahn-python/issues/1117
3167 `(#:tests? #f))
3168 (propagated-inputs
3169 `(("python-cffi" ,python-cffi)
3170 ("python-twisted" ,python-twisted)
3171 ("python-txaio" ,python-txaio)))
3172 (home-page "https://crossbar.io/autobahn/")
3173 (synopsis "Web Application Messaging Protocol implementation")
3174 (description "This package provides an implementation of the @dfn{Web Application
3175 Messaging Protocol} (WAMP). WAMP connects components in distributed
3176 applications using Publish and Subscribe (PubSub) and routed Remote Procedure
3177 Calls (rRPC). It is ideal for distributed, multi-client and server applications
3178 such as IoT applications or multi-user database-driven business applications.")
3179 (license license:expat)))
3180
3181 (define-public python-ws4py
3182 (package
3183 (name "python-ws4py")
3184 (version "0.5.1")
3185 (source
3186 (origin
3187 (method url-fetch)
3188 (uri (pypi-uri "ws4py" version))
3189 (sha256
3190 (base32
3191 "10slbbf2jm4hpr92jx7kh7mhf48sjl01v2w4d8z3f1p0ybbp7l19"))))
3192 (build-system python-build-system)
3193 (arguments
3194 `(#:phases
3195 (modify-phases %standard-phases
3196 (add-after 'unpack 'python3.7-compatibility
3197 (lambda _
3198 (substitute* '("ws4py/server/tulipserver.py"
3199 "ws4py/async_websocket.py")
3200 (("asyncio.async")
3201 "asyncio.ensure_future"))
3202 #t))
3203 ;; We don't have a package for cherrypy.
3204 (add-after 'unpack 'remove-cherrypy-support
3205 (lambda _
3206 (delete-file "ws4py/server/cherrypyserver.py")
3207 #t)))))
3208 (propagated-inputs
3209 `(("python-gevent" ,python-gevent)
3210 ("python-tornado" ,python-tornado)))
3211 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
3212 (synopsis "WebSocket client and server library")
3213 (description
3214 "This package provides a WebSocket client and server library for
3215 Python.")
3216 (license license:bsd-3)))
3217
3218 ;; kaldi-gstreamer-server does not yet work with python-ws4py > 0.3.2
3219 (define-public python2-ws4py-for-kaldi-gstreamer-server
3220 (package (inherit python-ws4py)
3221 (name "python2-ws4py")
3222 (version "0.3.2")
3223 (source
3224 (origin
3225 (method url-fetch)
3226 (uri (pypi-uri "ws4py" version))
3227 (sha256
3228 (base32
3229 "12ys3dv98awhrxd570vla3hqgzq3avjhq4yafhghhq3a942y1928"))))
3230 (build-system python-build-system)
3231 (arguments
3232 `(#:python ,python-2
3233 #:phases
3234 (modify-phases %standard-phases
3235 ;; We don't have a package for cherrypy.
3236 (add-after 'unpack 'remove-cherrypy-support
3237 (lambda _
3238 (delete-file "ws4py/server/cherrypyserver.py")
3239 #t)))))
3240 (propagated-inputs
3241 `(("python-gevent" ,python2-gevent)
3242 ("python-tornado" ,python2-tornado)))))
3243
3244 (define-public python-slugify
3245 (package
3246 (name "python-slugify")
3247 (version "3.0.4")
3248 (source
3249 (origin
3250 (method url-fetch)
3251 (uri (pypi-uri "python-slugify" version))
3252 (sha256
3253 (base32 "0dv97yi5fq074q5qyqbin09pmi8ixg36caf5nkpw2bqkd8jh6pap"))
3254 (patches
3255 (search-patches "python-slugify-depend-on-unidecode.patch"))))
3256 (native-inputs
3257 `(("python-wheel" ,python-wheel)))
3258 (propagated-inputs
3259 `(("python-unidecode" ,python-unidecode)))
3260 (arguments
3261 `(#:phases
3262 (modify-phases %standard-phases
3263 (replace 'check
3264 (lambda _
3265 (invoke "python" "test.py"))))))
3266 (build-system python-build-system)
3267 (home-page "https://github.com/un33k/python-slugify")
3268 (synopsis "Python Slugify application that handles Unicode")
3269 (description "This package provides a @command{slufigy} command and
3270 library to create slugs from unicode strings while keeping it DRY.")
3271 (license license:expat)))
3272
3273 (define-public python-branca
3274 (package
3275 (name "python-branca")
3276 (version "0.3.1")
3277 (source
3278 (origin
3279 (method url-fetch)
3280 (uri (pypi-uri "branca" version))
3281 (sha256
3282 (base32
3283 "0pmigd521j2228xf8x34vbx0niwvms7xl7za0lymywj0vydjqxiy"))))
3284 (build-system python-build-system)
3285 (propagated-inputs
3286 `(("python-jinja2" ,python-jinja2)
3287 ("python-six" ,python-six)))
3288 (native-inputs
3289 `(("python-pytest" ,python-pytest)))
3290 (home-page "https://github.com/python-visualization/branca")
3291 (synopsis "Generate complex HTML+JS pages with Python")
3292 (description "Generate complex HTML+JS pages with Python")
3293 (license license:expat)))
3294
3295 (define-public python-tinycss2
3296 (package
3297 (name "python-tinycss2")
3298 (version "1.0.2")
3299 (source
3300 (origin
3301 (method url-fetch)
3302 (uri (pypi-uri "tinycss2" version))
3303 (sha256
3304 (base32 "1kw84y09lggji4krkc58jyhsfj31w8npwhznr7lf19d0zbix09v4"))))
3305 (build-system python-build-system)
3306 (arguments
3307 `(#:phases
3308 (modify-phases %standard-phases
3309 (replace 'check
3310 (lambda _ (invoke "pytest"))))))
3311 (propagated-inputs
3312 `(("python-webencodings" ,python-webencodings)))
3313 (native-inputs
3314 `(("python-pytest-flake8" ,python-pytest-flake8)
3315 ("python-pytest-isort" ,python-pytest-isort)
3316 ("python-pytest-runner" ,python-pytest-runner)))
3317 (home-page "https://tinycss2.readthedocs.io/")
3318 (synopsis "Low-level CSS parser for Python")
3319 (description "@code{tinycss2} can parse strings, return Python objects
3320 representing tokens and blocks, and generate CSS strings corresponding to
3321 these objects.
3322
3323 Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
3324 grammar of CSS but doesn’t know specific rules, properties or values supported
3325 in various CSS modules.")
3326 (license license:bsd-3)))
3327
3328 (define-public python-cssselect2
3329 (package
3330 (name "python-cssselect2")
3331 (version "0.2.2")
3332 (source
3333 (origin
3334 (method url-fetch)
3335 (uri (pypi-uri "cssselect2" version))
3336 (sha256
3337 (base32 "0skymzb4ncrm2zdsy80f53vi0arf776lvbp51hzh4ayp1il5lj3h"))))
3338 (build-system python-build-system)
3339 (arguments
3340 `(#:phases
3341 (modify-phases %standard-phases
3342 (replace 'check
3343 (lambda _ (invoke "pytest"))))))
3344 (propagated-inputs
3345 `(("python-tinycss2" ,python-tinycss2)))
3346 (native-inputs
3347 `(("python-pytest-cov" ,python-pytest-cov)
3348 ("python-pytest-flake8" ,python-pytest-flake8)
3349 ("python-pytest-isort" ,python-pytest-isort)
3350 ("python-pytest-runner" ,python-pytest-runner)))
3351 (home-page "https://cssselect2.readthedocs.io/")
3352 (synopsis "CSS selectors for Python ElementTree")
3353 (description "@code{cssselect2} is a straightforward implementation of
3354 CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
3355 ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
3356
3357 Unlike the Python package @code{cssselect}, it does not translate selectors to
3358 XPath and therefore does not have all the correctness corner cases that are
3359 hard or impossible to fix in cssselect.")
3360 (license license:bsd-3)))
3361
3362 (define-public gunicorn
3363 (package
3364 (name "gunicorn")
3365 (version "20.0.0")
3366 (source
3367 (origin
3368 (method url-fetch)
3369 (uri (pypi-uri "gunicorn" version))
3370 (sha256
3371 (base32
3372 "0l1zm8a0vz8ws3lkn8q9a0f93ipdzyvlf2zlwdj5xyadh6jdwsgg"))))
3373 (outputs '("out" "doc"))
3374 (build-system python-build-system)
3375 (arguments
3376 `(#:phases
3377 (modify-phases %standard-phases
3378 (add-after 'build 'build-doc
3379 (lambda _
3380 (invoke "make" "-C" "docs" "PAPER=a4" "html" "info")
3381 (delete-file "docs/build/texinfo/Makefile")
3382 (delete-file "docs/build/texinfo/Gunicorn.texi")
3383 #t))
3384 (replace 'check
3385 (lambda _
3386 (setenv "PYTHONPATH"
3387 (string-append ".:" (getenv "PYTHONPATH")))
3388 ;; Remove test modules failing due to libc not found due to
3389 ;; section '.dynamic' not found in libc.so
3390 (delete-file "tests/test_arbiter.py")
3391 (delete-file "tests/test_config.py")
3392 (delete-file "tests/test_sock.py")
3393 (invoke "pytest")))
3394 (add-after 'install 'install-doc
3395 (lambda* (#:key outputs #:allow-other-keys)
3396 (let* ((doc (string-append (assoc-ref outputs "doc")
3397 "/share/doc/" ,name "-" ,version))
3398 (html (string-append doc "/html"))
3399 (info (string-append doc "/info"))
3400 (examples (string-append doc "/examples")))
3401 (mkdir-p html)
3402 (mkdir-p info)
3403 (mkdir-p examples)
3404 (copy-recursively "docs/build/html" html)
3405 (copy-recursively "docs/build/texinfo" info)
3406 (copy-recursively "examples" examples)
3407 (for-each (lambda (file)
3408 (copy-file file (string-append doc "/" file)))
3409 '("README.rst" "NOTICE" "LICENSE" "THANKS")))
3410 #t)))))
3411 (native-inputs
3412 `(("binutils" ,binutils) ;; for ctypes.util.find_library()
3413 ("python-aiohttp", python-aiohttp)
3414 ("python-pytest" ,python-pytest)
3415 ("python-pytest-cov" ,python-pytest-cov)
3416 ("python-sphinx" ,python-sphinx)
3417 ("texinfo" ,texinfo)))
3418 (home-page "https://gunicorn.org/")
3419 (synopsis "Python WSGI HTTP Server for UNIX")
3420 (description "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
3421 Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
3422 Unicorn project. The Gunicorn server is broadly compatible with
3423 various web frameworks, simply implemented, light on server resources,
3424 and fairly speedy.")
3425 (license license:expat)))
3426
3427 (define-public python-translation-finder
3428 (package
3429 (name "python-translation-finder")
3430 (version "1.7")
3431 (source
3432 (origin
3433 (method url-fetch)
3434 (uri (pypi-uri "translation-finder" version))
3435 (sha256
3436 (base32
3437 "1pcy9z8gmb8x41gjhw9x0lkr0d2mv5mdxcs2hwg6q8mxs857j589"))))
3438 (build-system python-build-system)
3439 (arguments
3440 `(#:phases
3441 (modify-phases %standard-phases
3442 (add-before 'build 'remove-failing-test
3443 (lambda _
3444 (delete-file "translation_finder/test_api.py")
3445 #t)))))
3446 (propagated-inputs
3447 `(("python-chardet" ,python-chardet)
3448 ("python-pathlib2" ,python-pathlib2)
3449 ("python-ruamel.yaml" ,python-ruamel.yaml)
3450 ("python-six" ,python-six)))
3451 (native-inputs
3452 `(("python-codecov" ,python-codecov)
3453 ("python-codacy-coverage" ,python-codacy-coverage)
3454 ("python-pytest-cov" ,python-pytest-cov)
3455 ("python-pytest-runner" ,python-pytest-runner)
3456 ("python-twine" ,python-twine)))
3457 (home-page "https://weblate.org/")
3458 (synopsis "Translation file finder for Weblate")
3459 (description "This package provides a function to find translation file in
3460 the source code of a project. It supports many translation file formats and
3461 is part of the Weblate translation platform.")
3462 (license license:gpl3+)))
3463
3464 (define-public python-gitlab
3465 (package
3466 (name "python-gitlab")
3467 (version "1.15.0")
3468 (source
3469 (origin
3470 (method url-fetch)
3471 (uri (pypi-uri "python-gitlab" version))
3472 (sha256
3473 (base32
3474 "0zl6kz8v8cg1bcy2r78b2snb0lpw0b573gdx2x1ps0nhsh75l4j5"))))
3475 (build-system python-build-system)
3476 (propagated-inputs
3477 `(("python-requests" ,python-requests)
3478 ("python-six" ,python-six)))
3479 (native-inputs
3480 `(("python-httmock" ,python-httmock)
3481 ("python-mock" ,python-mock)))
3482 (home-page
3483 "https://github.com/python-gitlab/python-gitlab")
3484 (synopsis "Interact with GitLab API")
3485 (description "This package provides an extended library for interacting
3486 with GitLab instances through their API.")
3487 (license license:lgpl3+)))
3488
3489 (define-public python-path-and-address
3490 (package
3491 (name "python-path-and-address")
3492 (version "2.0.1")
3493 (source
3494 (origin
3495 ;; The source distributed on PyPI doesn't include tests.
3496 (method git-fetch)
3497 (uri (git-reference
3498 (url "https://github.com/joeyespo/path-and-address")
3499 (commit (string-append "v" version))))
3500 (file-name (git-file-name name version))
3501 (sha256
3502 (base32
3503 "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6"))))
3504 (build-system python-build-system)
3505 (arguments
3506 `(#:phases
3507 (modify-phases %standard-phases
3508 (replace 'check
3509 (lambda* (#:key inputs outputs #:allow-other-keys)
3510 (add-installed-pythonpath inputs outputs)
3511 (invoke "py.test"))))))
3512 (native-inputs
3513 `(("python-pytest" ,python-pytest)))
3514 (home-page "https://github.com/joeyespo/path-and-address")
3515 (synopsis "Functions for command-line server tools used by humans")
3516 (description "Path-and-address resolves ambiguities of command-line
3517 interfaces, inferring which argument is the path, and which is the address.")
3518 (license license:expat)))
3519
3520 (define-public grip
3521 ;; No release by upstream for quite some time, some bugs fixed since. See:
3522 ;; https://github.com/joeyespo/grip/issues/304
3523 (let ((commit "27a4d6d87ea1d0ea7f7f120de55baabee3de73e3"))
3524 (package
3525 (name "grip")
3526 (version (git-version "4.5.2" "1" commit))
3527 (source
3528 (origin
3529 (method git-fetch)
3530 (uri (git-reference
3531 (url "https://github.com/joeyespo/grip")
3532 (commit commit)))
3533 (file-name (git-file-name name version))
3534 (sha256
3535 (base32
3536 "0kx5hgb3q19i4l18a4vqdq9af390xgpk88lp2ay75qi96k0dc68w"))))
3537 (build-system python-build-system)
3538 (propagated-inputs
3539 `(("python-docopt" ,python-docopt)
3540 ("python-flask" ,python-flask)
3541 ("python-markdown" ,python-markdown)
3542 ("python-path-and-address" ,python-path-and-address)
3543 ("python-pygments" ,python-pygments)
3544 ("python-requests" ,python-requests)))
3545 (native-inputs
3546 `(("python-pytest" ,python-pytest)
3547 ("python-responses" ,python-responses)))
3548 (arguments
3549 `(#:phases
3550 (modify-phases %standard-phases
3551 (replace 'check
3552 (lambda* (#:key inputs outputs #:allow-other-keys)
3553 (add-installed-pythonpath inputs outputs)
3554 (setenv "PATH" (string-append
3555 (getenv "PATH") ":"
3556 (assoc-ref %outputs "out") "/bin"))
3557 (invoke "py.test" "-m" "not assumption"))))))
3558 (home-page "https://github.com/joeyespo/grip")
3559 (synopsis "Preview Markdown files using the GitHub API")
3560 (description "Grip is a command-line server application written in Python
3561 that uses the GitHub Markdown API to render a local Markdown file. The styles
3562 and rendering come directly from GitHub, so you'll know exactly how it will
3563 appear. Changes you make to the file will be instantly reflected in the browser
3564 without requiring a page refresh.")
3565 (license license:expat))))