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