gnu: python-webtest: Update to 2.0.29.
[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>
3;;; Copyright © 2015, 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
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>
8;;; Copyright © 2015, 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
9;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
10;;; Copyright © 2016, 2017 Julien Lepiller <julien@lepiller.eu>
11;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
12;;; Copyright © 2014, 2017 Eric Bavier <bavier@member.fsf.org>
13;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
14;;; Copyright © 2015 Cyril Roelandt <tipecaml@gmail.com>
15;;; Copyright © 2015, 2016, 2017 Leo Famulari <leo@famulari.name>
16;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
331ebb7f 17;;; Copyright © 2016, 2017, 2018 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>
1b2f753d
LC
25;;;
26;;; This file is part of GNU Guix.
27;;;
28;;; GNU Guix is free software; you can redistribute it and/or modify it
29;;; under the terms of the GNU General Public License as published by
30;;; the Free Software Foundation; either version 3 of the License, or (at
31;;; your option) any later version.
32;;;
33;;; GNU Guix is distributed in the hope that it will be useful, but
34;;; WITHOUT ANY WARRANTY; without even the implied warranty of
35;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
36;;; GNU General Public License for more details.
37;;;
38;;; You should have received a copy of the GNU General Public License
39;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
40
41(define-module (gnu packages python-web)
42 #:use-module (guix packages)
43 #:use-module (guix download)
44 #:use-module (guix build-system python)
45 #:use-module (gnu packages)
ac257f12 46 #:use-module (gnu packages check)
1b2f753d 47 #:use-module (gnu packages compression)
a8714bf6 48 #:use-module (gnu packages databases)
1b2f753d
LC
49 #:use-module (gnu packages django)
50 #:use-module (gnu packages pkg-config)
51 #:use-module (gnu packages python)
cc6f4912 52 #:use-module (gnu packages python-crypto)
33dc54b0 53 #:use-module (gnu packages time)
1b2f753d
LC
54 #:use-module (gnu packages xml)
55 #:use-module ((guix licenses) #:prefix license:)
56 #:use-module (srfi srfi-1))
57
589e3f4e
LC
58(define-public python-furl
59 (package
60 (name "python-furl")
61 (version "0.5.6")
62 (source
63 (origin
64 (method url-fetch)
65 (uri (pypi-uri "furl" version))
66 (sha256
67 (base32
68 "0lzpfpm686hvz3sr1mcrnd1b3lgmnw8v59gb43wfi98r3b671pqc"))))
69 (build-system python-build-system)
70 (propagated-inputs
71 `(("python-six" ,python-six)
72 ("python-orderedmultidict" ,python-orderedmultidict)))
73 (native-inputs
74 `(("python-pycodestyle" ,python-pycodestyle)))
75 (home-page "https://github.com/gruns/furl")
76 (synopsis "URL manipulation in Python")
77 (description "Furl provides an easy-to-use alternative to the
78@code{urllib} and @code{urlparse} modules for manipulating URLs.")
79 (license license:unlicense)))
80
81(define-public python2-furl
82 (package-with-python2 python-furl))
83
1b2f753d
LC
84(define-public python-httplib2
85 (package
86 (name "python-httplib2")
87 (version "0.9.2")
88 (source
89 (origin
90 (method url-fetch)
91 (uri (pypi-uri "httplib2" version))
92 (sha256
93 (base32
94 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
95 (build-system python-build-system)
96 (home-page "https://github.com/jcgregorio/httplib2")
97 (synopsis "Comprehensive HTTP client library")
98 (description
99 "A comprehensive HTTP client library supporting many features left out of
100other HTTP libraries.")
101 (license license:expat)))
102
103(define-public python2-httplib2
104 (package-with-python2 python-httplib2))
105
106(define-public python-sockjs-tornado
107 (package
108 (name "python-sockjs-tornado")
109 (version "1.0.3")
110 (source
111 (origin
112 (method url-fetch)
113 (uri (pypi-uri "sockjs-tornado" version))
114 (sha256
115 (base32
116 "16cff40nniqsyvda1pb2j3b4zwmrw7y2g1vqq78lp20xpmhnwwkd"))))
117 (build-system python-build-system)
118 (arguments
119 `(;; There are no tests, and running the test phase requires missing
120 ;; dependencies
121 #:tests? #f))
122 (propagated-inputs
123 `(("python-tornado" ,python-tornado)))
9be5ecdf 124 (home-page "https://github.com/mrjoes/sockjs-tornado/")
1b2f753d
LC
125 (synopsis
126 "SockJS python server implementation on top of Tornado framework")
127 (description
128 "SockJS-tornado provides the server side counterpart to a SockJS client
129library, through the Tornado framework.
130
131SockJS provides a low latency, full duplex, cross-domain communication channel
132between a web browser and web server.")
133 (license license:expat)))
134
135(define-public python2-sockjs-tornado
136 (package-with-python2 python-sockjs-tornado))
137
138(define-public python-flask-babel
139 (package
140 (name "python-flask-babel")
1a6fb8da 141 (version "0.11.2")
1b2f753d
LC
142 (source
143 (origin
144 (method url-fetch)
145 (uri (pypi-uri "Flask-Babel" version))
146 (sha256
147 (base32
1a6fb8da 148 "0ff9n165vhf1nhv6807ckhpp224jw7k7sd7jz5kfh3sbpl85gmy0"))))
1b2f753d
LC
149 (build-system python-build-system)
150 (propagated-inputs
151 `(("python-flask" ,python-flask)
152 ("python-babel" ,python-babel)
153 ("python-jinja2" ,python-jinja2)
154 ("python-pytz" ,python-pytz)))
155 (home-page "https://github.com/python-babel/flask-babel")
156 (synopsis "Add i18n/l10n support to Flask applications")
157 (description "This package implements internationalization and localization
158support for Flask. This is based on the Python babel module as well as pytz -
159both of which are installed automatically if you install this library.")
160 (license license:bsd-3)))
161
162(define-public python2-flask-babel
163 (package-with-python2 python-flask-babel))
164
165(define-public python-html5lib
166 (package
167 (name "python-html5lib")
4ef80b2f 168 (version "1.0.1")
1b2f753d
LC
169 (source
170 (origin
171 (method url-fetch)
172 (uri (pypi-uri "html5lib" version))
173 (sha256
174 (base32
4ef80b2f 175 "0dipzfrycv6j1jw82v9b7d8lzggx3x8xngx6l4xrqkxwvg7hvjv6"))))
1b2f753d
LC
176 (build-system python-build-system)
177 (propagated-inputs
178 `(("python-six" ,python-six)
179 ("python-webencodings" ,python-webencodings)))
180 (arguments
181 `(#:test-target "check"))
182 (home-page
183 "https://github.com/html5lib/html5lib-python")
184 (synopsis
185 "Python HTML parser based on the WHATWG HTML specifcation")
186 (description
187 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
188and written in Python.")
189 (license license:expat)))
190
191(define-public python2-html5lib
192 (package-with-python2 python-html5lib))
193
194;; Needed for python-bleach, a dependency of python-notebook
195(define-public python-html5lib-0.9
196 (package
197 (inherit python-html5lib)
198 (version "0.999")
199 (source
200 (origin
201 (method url-fetch)
202 (uri (pypi-uri "html5lib" version))
203 (sha256
204 (base32
205 "17n4zfsj6ynmbwdwviywmj8r6nzr3xvfx2zs0xhndmvm51z7z263"))))))
206
207(define-public python2-html5lib-0.9
208 (package-with-python2 python-html5lib-0.9))
209
210(define-public python-html5-parser
211 (package
212 (name "python-html5-parser")
213 (version "0.4.4")
214 (source (origin
215 (method url-fetch)
216 (uri (pypi-uri "html5-parser" version))
217 (sha256
218 (base32
219 "1d8sxhl41ffh7qlk7wlsy17xw6slzx5v1yna9s72wx5qrpaa3wxr"))))
220 (build-system python-build-system)
221 (native-inputs
222 `(("pkg-config" ,pkg-config)))
223 (inputs
224 `(("libxml2" ,libxml2)))
225 (propagated-inputs
226 `(("python-lxml" ,python-lxml)
227 ("python-beautifulsoup4" ,python-beautifulsoup4)))
228 (home-page "https://html5-parser.readthedocs.io")
229 (synopsis "Fast C-based HTML5 parsing for Python")
230 (description "This package provides a fast implementation of the HTML5
231parsing spec for Python. Parsing is done in C using a variant of the gumbo
232parser. The gumbo parse tree is then transformed into an lxml tree, also in
233C, yielding parse times that can be a thirtieth of the html5lib parse times.")
234 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
235 ;; indicate ASL2.0, including the LICENSE file for the whole project.
236 (license (list license:asl2.0 license:gpl3))))
237
238(define-public python2-html5-parser
239 (package-with-python2 python-html5-parser))
240
241(define-public python-webencodings
242 (package
243 (name "python-webencodings")
b0a2c9cb 244 (version "0.5.1")
1b2f753d
LC
245 (source (origin
246 (method url-fetch)
247 (uri (pypi-uri "webencodings" version))
248 (sha256
249 (base32
b0a2c9cb 250 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
1b2f753d
LC
251 (build-system python-build-system)
252 (arguments
253 '(#:phases
254 (modify-phases %standard-phases
255 (replace 'check
256 (lambda _
257 (zero? (system* "py.test" "-v" "webencodings/tests.py")))))))
258 (native-inputs
259 `(("python-pytest" ,python-pytest)))
260 (home-page "https://github.com/SimonSapin/python-webencodings")
261 (synopsis "Character encoding aliases for legacy web content")
262 (description
263 "In order to be compatible with legacy web content when interpreting
264something like @code{Content-Type: text/html; charset=latin1}, tools need
265to use a particular set of aliases for encoding labels as well as some
266overriding rules. For example, @code{US-ASCII} and @code{iso-8859-1} on
267the web are actually aliases for @code{windows-1252}, and an @code{UTF-8}
268or @code{UTF-16} BOM takes precedence over any other encoding declaration.
269The WHATWG @url{https://encoding.spec.whatwg.org/,Encoding} standard
270defines all such details so that implementations do not have to
271reverse-engineer each other.
272
273This module implements the Encoding standard and has encoding labels and
274BOM detection, but the actual implementation for encoders and decoders
275is Python’s.")
276 (license license:bsd-3)))
277
278(define-public python2-webencodings
279 (package-with-python2 python-webencodings))
280
281(define-public python-openid
282 (package
283 (name "python-openid")
284 (version "3.0.10")
285 (source
286 (origin
287 (method url-fetch)
288 (uri (pypi-uri "python3-openid" version))
289 (sha256
290 (base32
291 "1x3nh3fycqfn43jp5j5pb4q4y2jxp4mdka4absaa3bc0078qd758"))))
292 (build-system python-build-system)
293 (arguments
294 `(#:phases
295 (modify-phases %standard-phases
296 (replace 'check
297 (lambda _
298 (zero? (system* "./admin/runtests")))))))
299 (properties `((python2-variant . ,(delay python2-openid))))
300 (propagated-inputs
301 `(("python-defusedxml" ,python-defusedxml)))
302 (native-inputs
303 `(("python-psycopg2" ,python-psycopg2)
304 ("python-django" ,python-django)))
305 (home-page "https://github.com/necaris/python3-openid")
306 (synopsis "OpenID support for servers and consumers")
307 (description "This library provides OpenID authentication for Python, both
308for clients and servers.")
309 (license license:asl2.0)))
310
311(define-public python2-openid
312 (package
313 (name "python2-openid")
314 (version "2.2.5")
315 (source
316 (origin
317 (method url-fetch)
318 (uri (pypi-uri "python-openid" version))
319 (sha256
320 (base32
321 "1vvhxlghjan01snfdc4k7ykd80vkyjgizwgg9bncnin8rqz1ricj"))))
322 (build-system python-build-system)
323 (arguments
324 ;; Python 3 support is in `python3-openid`, a separate package.
325 `(#:python ,python-2))
326 (home-page "https://github.com/openid/python-openid")
327 (synopsis "OpenID support for servers and consumers")
328 (description "This library provides OpenID authentication for Python, both
329for clients and servers.")
330 (license license:asl2.0)))
331
332(define-public python-cssutils
333 (package
334 (name "python-cssutils")
3c5658c5 335 (version "1.0.2")
1b2f753d
LC
336 (source
337 (origin
338 (method url-fetch)
339 (uri (pypi-uri "cssutils" version))
340 (sha256
341 (base32
3c5658c5 342 "1bxchrbqzapwijap0yhlxdil1w9bmwvgx77aizlkhc2mcxjg1z52"))))
1b2f753d
LC
343 (build-system python-build-system)
344 (native-inputs
3c5658c5 345 `(("unzip" ,unzip))) ; for unpacking the source
1b2f753d 346 (arguments
3c5658c5 347 `(#:tests? #f)) ; tests require python-pbr < 1.7.0
1b2f753d
LC
348 (home-page "http://cthedot.de/cssutils/")
349 (synopsis
350 "CSS Cascading Style Sheets library for Python")
351 (description
352 "Cssutils is a Python package for parsing and building CSS
353Cascading Style Sheets. Currently it provides a DOM only and no rendering
354options.")
355 (license license:lgpl3+)))
356
357(define-public python2-cssutils
358 (package-with-python2 python-cssutils))
359
360(define-public python-cssselect
361 (package
362 (name "python-cssselect")
363 (version "0.9.2")
364 (source
365 (origin
366 (method url-fetch)
367 (uri (pypi-uri "cssselect" version))
368 (sha256
369 (base32
370 "1xg6gbva1yswghiycmgincv6ab4bn7hpm720ndbj40h8xycmnfvi"))))
371 (build-system python-build-system)
372 (arguments
373 ;; tests fail with message
374 ;; AttributeError: 'module' object has no attribute 'tests'
375 `(#:tests? #f))
376 (home-page
377 "https://pythonhosted.org/cssselect/")
378 (synopsis
379 "CSS3 selector parser and translator to XPath 1.0")
380 (description
381 "Cssselect ia a Python module that parses CSS3 Selectors and translates
382them to XPath 1.0 expressions. Such expressions can be used in lxml or
383another XPath engine to find the matching elements in an XML or HTML document.")
384 (license license:bsd-3)))
385
386(define-public python2-cssselect
387 (package-with-python2 python-cssselect))
388
389(define-public python-openid-cla
390 (package
391 (name "python-openid-cla")
392 (version "1.2")
393 (source
394 (origin
395 (method url-fetch)
396 (uri (pypi-uri "python-openid-cla" version))
397 (sha256
398 (base32
399 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
400 (build-system python-build-system)
401 (arguments '(#:tests? #f)) ; No tests.
402 (home-page "https://github.com/puiterwijk/python-openid-cla/")
403 (synopsis "Implementation of the OpenID CLA extension for python-openid")
404 (description "@code{openid-cla} is an implementation of the OpenID
405contributor license agreement extension for python-openid.")
406 (license license:bsd-3)))
407
408(define-public python2-openid-cla
409 (package-with-python2 python-openid-cla))
410
411(define-public python-openid-teams
412 (package
413 (name "python-openid-teams")
414 (version "1.1")
415 (source
416 (origin
417 (method url-fetch)
418 (uri (pypi-uri "python-openid-teams" version))
419 (sha256
420 (base32
421 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
422 (build-system python-build-system)
423 (arguments '(#:tests? #f)) ; No tests.
424 (home-page "https://github.com/puiterwijk/python-openid-teams/")
425 (synopsis "Implementation of the OpenID teams extension for python-openid")
426 (description
427 "@code{openid-teams} is an implementation of the OpenID
428teams extension for python-openid.")
429 (license license:bsd-3)))
430
431(define-public python2-openid-teams
432 (package-with-python2 python-openid-teams))
433
434(define-public python-tornado
435 (package
436 (name "python-tornado")
437 (version "4.5.1")
438 (source
439 (origin
440 (method url-fetch)
441 (uri (pypi-uri "tornado" version))
442 (sha256
443 (base32 "1zbkgcdfq81k298awrm8p0xwbwwn2p3nbizdglzfbkskhai082fv"))))
444 (build-system python-build-system)
445 (arguments
446 '(;; FIXME: Two tests error out with:
447 ;; AssertionError: b'Error in atexit._run_exitfuncs:\nFileNotF[44 chars]ry\n' != b''
448 ;; #:phases
449 ;; (modify-phases %standard-phases
450 ;; (replace 'check
451 ;; (lambda _
452 ;; ;; 'setup.py test' hits an AssertionError on BSD-specific
453 ;; ;; "tornado/platform/kqueue.py". This is the supported method:
454 ;; (zero? (system* "python" "-m" "tornado.test")))))
455 #:tests? #f))
456 (native-inputs
457 `(("python-certifi" ,python-certifi)))
458 (propagated-inputs
459 `(("python-backports-abc" ,python-backports-abc)))
460 (home-page "http://www.tornadoweb.org/")
461 (synopsis "Python web framework and asynchronous networking library")
462 (description
463 "Tornado is a Python web framework and asynchronous networking library,
464originally developed at FriendFeed. By using non-blocking network I/O,
465Tornado can scale to tens of thousands of open connections, making it ideal
466for long polling, WebSockets, and other applications that require a long-lived
467connection to each user.")
468 (license license:asl2.0)
469 (properties `((python2-variant . ,(delay python2-tornado))))))
470
471(define-public python2-tornado
472 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
473 (package (inherit tornado)
474 (propagated-inputs
475 `(("python2-backport-ssl-match-hostname"
476 ,python2-backport-ssl-match-hostname)
477 ("python2-singledispatch" ,python2-singledispatch)
478 ,@(package-propagated-inputs tornado))))))
479
480(define-public python-tornado-http-auth
481 (package
482 (name "python-tornado-http-auth")
483 (version "1.1.0")
484 (source
485 (origin
486 (method url-fetch)
487 (uri (pypi-uri "tornado-http-auth" version))
488 (sha256
489 (base32
490 "0znrgqd7k2s4ia474xizi6h3061zj4sn5n6cq76bkwl3wwshifn5"))))
491 (build-system python-build-system)
492 (propagated-inputs
493 `(("python-tornado" ,python-tornado)))
494 (home-page
495 "https://github.com/gvalkov/tornado-http-auth")
496 (synopsis
497 "Digest and basic authentication module for Tornado")
498 (description
499 "Provides support for adding authentication to services using the Tornado
500web framework, either via the basic or digest authentication schemes.")
501 (license license:asl2.0)))
502
503(define-public python-terminado
504 (package
505 (name "python-terminado")
506 (version "0.6")
507 (source
508 (origin
509 (method url-fetch)
510 (uri (pypi-uri "terminado" version))
511 (sha256
512 (base32
513 "09h1kwi86g5mrk14s4pgbhshd602zry29lnpxamcqz864kva22rc"))))
514 (build-system python-build-system)
515 (propagated-inputs
516 `(("python-tornado" ,python-tornado)
517 ("python-ptyprocess" ,python-ptyprocess)))
518 (native-inputs
519 `(("python-nose" ,python-nose)))
520 (arguments
521 `(#:phases
522 (modify-phases %standard-phases
523 (replace 'check
524 (lambda _
525 (zero? (system* "nosetests")))))))
526 (home-page "https://github.com/takluyver/terminado")
527 (synopsis "Terminals served to term.js using Tornado websockets")
528 (description "This package provides a Tornado websocket backend for the
529term.js Javascript terminal emulator library.")
530 (license license:bsd-2)
531 (properties `((python2-variant . ,(delay python2-terminado))))))
532
533(define-public python2-terminado
534 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
535 (package (inherit terminado)
536 (propagated-inputs
537 `(("python2-backport-ssl-match-hostname"
538 ,python2-backport-ssl-match-hostname)
539 ,@(package-propagated-inputs terminado))))))
540
589e3f4e
LC
541(define-public python-wsgi-intercept
542 (package
543 (name "python-wsgi-intercept")
544 (version "1.2.2")
545 (source (origin
546 (method url-fetch)
547 (uri (string-append
548 "https://pypi.python.org/packages/"
549 "38/76/ebcbc24d0cb77db34520a3ca6ed1bd43ace17d182bbd8dd7d976f1c176fb/"
550 "wsgi_intercept-" version ".tar.gz"))
551 (sha256
552 (base32
553 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
554 (build-system python-build-system)
555 (propagated-inputs
556 `(("python-six" ,python-six)))
557 (native-inputs
558 `(("python-pytest" ,python-pytest)
559 ("python-httplib2" ,python-httplib2)
560 ("python-requests" ,python-requests)
561 ("python-urllib3" ,python-urllib3)))
562 (synopsis "Puts a WSGI application in place of a real URI for testing")
563 (description "Wsgi_intercept installs a WSGI application in place of a real
564URI for testing. Testing a WSGI application normally involves starting a
565server at a local host and port, then pointing your test code to that address.
566Instead, this library lets you intercept calls to any specific host/port
567combination and redirect them into a WSGI application importable by your test
568program. Thus, you can avoid spawning multiple processes or threads to test
569your Web app.")
570 (home-page "https://github.com/cdent/wsgi-intercept")
571 (license license:expat)))
572
1b2f753d
LC
573(define-public python-webob
574 (package
575 (name "python-webob")
576 (version "1.5.1")
577 (source
578 (origin
579 (method url-fetch)
580 (uri (pypi-uri "WebOb" version))
581 (sha256
582 (base32
583 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
584 (build-system python-build-system)
585 (native-inputs
586 `(("python-nose" ,python-nose)))
9be5ecdf 587 (home-page "https://webob.org/")
1b2f753d
LC
588 (synopsis "WSGI request and response object")
589 (description
590 "WebOb provides wrappers around the WSGI request environment, and an
591object to help create WSGI responses.")
592 (license license:expat)))
593
594(define-public python2-webob
595 (package-with-python2 python-webob))
596
597(define-public python-zope-event
598 (package
599 (name "python-zope-event")
600 (version "4.1.0")
601 (source
602 (origin
603 (method url-fetch)
604 (uri (string-append "https://pypi.python.org/packages/source/z"
605 "/zope.event/zope.event-" version ".tar.gz"))
606 (sha256
607 (base32
608 "11p75zpfz3ffhz21nzx9wb23xs993ck5s6hkjcvhswwizni5jynw"))))
609 (build-system python-build-system)
9be5ecdf 610 (home-page "https://pypi.python.org/pypi/zope.event")
1b2f753d
LC
611 (synopsis "Event publishing system for Python")
612 (description "Zope.event provides an event publishing API, intended for
613use by applications which are unaware of any subscribers to their events. It
614is a simple event-dispatching system on which more sophisticated event
615dispatching systems can be built.")
616 (license license:zpl2.1)))
617
618(define-public python2-zope-event
619 (package-with-python2 python-zope-event))
620
621(define-public python-zope-interface
622 (package
623 (name "python-zope-interface")
624 (version "4.1.3")
625 (source
626 (origin
627 (method url-fetch)
628 (uri (string-append "https://pypi.python.org/packages/source/z"
629 "/zope.interface/zope.interface-" version ".tar.gz"))
630 (sha256
631 (base32
632 "0ks8h73b2g4bkad821qbv0wzjppdrwys33i7ka45ik3wxjg1l8if"))))
633 (build-system python-build-system)
634 (native-inputs
635 `(("python-zope-event" ,python-zope-event)))
636 (home-page "https://github.com/zopefoundation/zope.interface")
637 (synopsis "Python implementation of the \"design by contract\"
638methodology")
639 (description "Zope.interface provides an implementation of \"object
640interfaces\" for Python. Interfaces are a mechanism for labeling objects as
641conforming to a given API or contract.")
642 (license license:zpl2.1)))
643
644(define-public python2-zope-interface
645 (package-with-python2 python-zope-interface))
646
647(define-public python-zope-exceptions
648 (package
649 (name "python-zope-exceptions")
650 (version "4.0.8")
651 (source
652 (origin
653 (method url-fetch)
654 (uri (string-append "https://pypi.python.org/packages/source/z"
655 "/zope.exceptions/zope.exceptions-"
656 version ".tar.gz"))
657 (sha256
658 (base32
659 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
660 (build-system python-build-system)
661 (arguments
662 '(#:tests? #f)) ; circular dependency with zope.testrunner
663 (propagated-inputs
664 `(("python-zope-interface" ,python-zope-interface)))
665 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
666 (synopsis "Zope exceptions")
667 (description "Zope.exceptions provides general-purpose exception types
668that have uses outside of the Zope framework.")
669 (license license:zpl2.1)))
670
671(define-public python2-zope-exceptions
672 (package-with-python2 python-zope-exceptions))
673
674(define-public python-zope-testing
675 (package
676 (name "python-zope-testing")
f9a6457d 677 (version "4.6.1")
1b2f753d
LC
678 (source
679 (origin
680 (method url-fetch)
f9a6457d 681 (uri (pypi-uri "zope.testing" version))
1b2f753d
LC
682 (sha256
683 (base32
f9a6457d 684 "1vvxhjmzl7vw2i1akfj1xbggwn36270ym7f2ic9xwbaswfw1ap56"))
1b2f753d
LC
685 (modules '((guix build utils)))
686 (snippet
687 '(begin
688 ;; Remove pre-compiled .pyc files backup files from source.
689 (for-each delete-file (find-files "." "(\\.pyc|~)$"))
690 #t))))
691 (build-system python-build-system)
692 (native-inputs
693 `(("python-zope-exceptions" ,python-zope-exceptions)))
694 (propagated-inputs
695 `(("python-zope-interface" ,python-zope-interface)))
9be5ecdf 696 (home-page "https://pypi.python.org/pypi/zope.testing")
1b2f753d
LC
697 (synopsis "Zope testing helpers")
698 (description "Zope.testing provides a number of testing utilities for HTML
699forms, HTTP servers, regular expressions, and more.")
700 (license license:zpl2.1)))
701
702(define-public python2-zope-testing
703 (package-with-python2 python-zope-testing))
704
705(define-public python-zope-testrunner
706 (package
707 (name "python-zope-testrunner")
708 (version "4.4.9")
709 (source
710 (origin
711 (method url-fetch)
712 (uri (string-append "https://pypi.python.org/packages/source/z"
713 "/zope.testrunner/zope.testrunner-"
714 version ".zip"))
715 (sha256
716 (base32
717 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
718 (build-system python-build-system)
719 (arguments
720 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
721 (native-inputs
722 `(("python-six" ,python-six)
723 ;("python-zope-interface" ,python-zope-interface)
724 ("python-zope-exceptions" ,python-zope-exceptions)
725 ("python-zope-testing" ,python-zope-testing)
726 ("unzip" ,unzip)))
727 (propagated-inputs
728 `(("python-zope-interface" ,python-zope-interface)))
9be5ecdf 729 (home-page "https://pypi.python.org/pypi/zope.testrunner")
1b2f753d
LC
730 (synopsis "Zope testrunner script")
731 (description "Zope.testrunner provides a script for running Python
732tests.")
733 (license license:zpl2.1)))
734
735(define-public python2-zope-testrunner
736 (let ((base (package-with-python2 python-zope-testrunner)))
737 (package
738 (inherit base)
739 (native-inputs
740 (append (package-native-inputs base)
741 `(("python2-subunit" ,python2-subunit)
742 ("python2-mimeparse" ,python2-mimeparse)))))))
743
744(define-public python-zope-i18nmessageid
745 (package
746 (name "python-zope-i18nmessageid")
747 (version "4.0.3")
748 (source
749 (origin
750 (method url-fetch)
751 (uri (string-append
752 "https://pypi.python.org/packages/source/z"
753 "/zope.i18nmessageid/zope.i18nmessageid-"
754 version ".tar.gz"))
755 (sha256
756 (base32
757 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
758 (build-system python-build-system)
9be5ecdf 759 (home-page "https://pypi.python.org/pypi/zope.i18nmessageid")
1b2f753d
LC
760 (synopsis "Message identifiers for internationalization")
761 (description "Zope.i18nmessageid provides facilities for declaring
762internationalized messages within program source text.")
763 (license license:zpl2.1)))
764
765(define-public python2-zope-i18nmessageid
766 (package-with-python2 python-zope-i18nmessageid))
767
768(define-public python-zope-schema
769 (package
770 (name "python-zope-schema")
771 (version "4.4.2")
772 (source
773 (origin
774 (method url-fetch)
775 (uri (string-append "https://pypi.python.org/packages/source/z"
776 "/zope.schema/zope.schema-" version ".tar.gz"))
777 (sha256
778 (base32
779 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
780 (build-system python-build-system)
781 (arguments
782 '(#:tests? #f)) ; FIXME: Tests can't find zope.event.
783 (propagated-inputs
784 `(("python-zope-event" ,python-zope-event)
785 ("python-zope-exceptions", python-zope-exceptions)
786 ("python-zope-interface" ,python-zope-interface)))
787 (native-inputs
788 `(("python-zope-testing" ,python-zope-testing)
789 ("python-coverage" ,python-coverage)
790 ("python-nose" ,python-nose)))
9be5ecdf 791 (home-page "https://pypi.python.org/pypi/zope.schema")
1b2f753d
LC
792 (synopsis "Zope data schemas")
793 (description "Zope.scheme provides extensions to zope.interface for
794defining data schemas.")
795 (license license:zpl2.1)))
796
797(define-public python2-zope-schema
798 (package-with-python2 python-zope-schema))
799
800(define-public python-zope-configuration
801 (package
802 (name "python-zope-configuration")
803 (version "4.0.3")
804 (source (origin
805 (method url-fetch)
806 (uri (string-append "https://pypi.python.org/packages/source/z"
807 "/zope.configuration/zope.configuration-"
808 version ".tar.gz"))
809 (sha256
810 (base32
811 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
812 (build-system python-build-system)
813 (arguments
814 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
815 (propagated-inputs
816 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
817 ("python-zope-schema" ,python-zope-schema)))
9be5ecdf 818 (home-page "https://pypi.python.org/pypi/zope.configuration")
1b2f753d
LC
819 (synopsis "Zope Configuration Markup Language")
820 (description "Zope.configuration implements ZCML, the Zope Configuration
821Markup Language.")
822 (license license:zpl2.1)))
823
824(define-public python2-zope-configuration
825 (package-with-python2 python-zope-configuration))
826
827(define-public python-zope-proxy
828 (package
829 (name "python-zope-proxy")
830 (version "4.1.6")
831 (source
832 (origin
833 (method url-fetch)
834 (uri (string-append "https://pypi.python.org/packages/source/z"
835 "/zope.proxy/zope.proxy-" version ".tar.gz"))
836 (sha256
837 (base32
838 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
839 (build-system python-build-system)
840 (arguments
841 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
842 (propagated-inputs
843 `(("python-zope-interface" ,python-zope-interface)))
9be5ecdf 844 (home-page "https://pypi.python.org/pypi/zope.proxy")
1b2f753d
LC
845 (synopsis "Generic, transparent proxies")
846 (description "Zope.proxy provides generic, transparent proxies for Python.
847Proxies are special objects which serve as mostly-transparent wrappers around
848another object, intervening in the apparent behavior of the wrapped object
849only when necessary to apply the policy (e.g., access checking, location
850brokering, etc.) for which the proxy is responsible.")
851 (license license:zpl2.1)))
852
853(define-public python2-zope-proxy
854 (package-with-python2 python-zope-proxy))
855
856(define-public python-zope-location
857 (package
858 (name "python-zope-location")
859 (version "4.0.3")
860 (source
861 (origin
862 (method url-fetch)
863 (uri (string-append "https://pypi.python.org/packages/source/z"
864 "/zope.location/zope.location-" version ".tar.gz"))
865 (sha256
866 (base32
867 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
868 (build-system python-build-system)
869 (arguments
870 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
871 (propagated-inputs
872 `(("python-zope-proxy" ,python-zope-proxy)
873 ("python-zope-schema" ,python-zope-schema)))
9be5ecdf 874 (home-page "https://pypi.python.org/pypi/zope.location/")
1b2f753d
LC
875 (synopsis "Zope location library")
876 (description "Zope.location implements the concept of \"locations\" in
877Zope3, which are are special objects that have a structural location.")
878 (license license:zpl2.1)))
879
880(define-public python2-zope-location
881 (package-with-python2 python-zope-location))
882
883(define-public python-zope-security
884 (package
885 (name "python-zope-security")
886 (version "4.0.3")
887 (source
888 (origin
889 (method url-fetch)
890 (uri (string-append "https://pypi.python.org/packages/source/z"
891 "/zope.security/zope.security-" version ".tar.gz"))
892 (sha256
893 (base32
894 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
895 (build-system python-build-system)
896 (arguments
897 '(#:tests? #f)) ; FIXME: Tests can't find zope.testrunner.
898 (propagated-inputs
899 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
900 ("python-zope-proxy" ,python-zope-proxy)
901 ("python-zope-schema" ,python-zope-schema)))
902 (native-inputs
903 `(("python-six" ,python-six)
904 ("python-zope-component" ,python-zope-component)
905 ("python-zope-configuration" ,python-zope-configuration)
906 ("python-zope-location" ,python-zope-location)
907 ("python-zope-testrunner" ,python-zope-testrunner)
908 ("python-zope-testing" ,python-zope-testing)))
9be5ecdf 909 (home-page "https://pypi.python.org/pypi/zope.security")
1b2f753d
LC
910 (synopsis "Zope security framework")
911 (description "Zope.security provides a generic mechanism to implement
912security policies on Python objects.")
913 (license license:zpl2.1)))
914
915(define-public python2-zope-security
916 (let ((zope-security (package-with-python2 python-zope-security)))
917 (package (inherit zope-security)
918 (propagated-inputs
919 `(("python2-zope-testrunner" ,python2-zope-testrunner)
920 ,@(alist-delete
921 "python-zope-testrunner"
922 (package-propagated-inputs zope-security)))))))
923
924(define-public python-zope-component
925 (package
926 (name "python-zope-component")
927 (version "4.3.0")
928 (source
929 (origin
930 (method url-fetch)
931 (uri (pypi-uri "zope.component" version))
932 (sha256
933 (base32
934 "1hlvzwj1kcfz1qms1dzhwsshpsf38z9clmyksb1gh41n8k3kchdv"))))
935 (build-system python-build-system)
936 (arguments
937 ;; Skip tests due to circular dependency with python-zope-security.
938 '(#:tests? #f))
939 (native-inputs
940 `(("python-zope-testing" ,python-zope-testing)))
941 (propagated-inputs
942 `(("python-zope-event" ,python-zope-event)
943 ("python-zope-interface" ,python-zope-interface)
944 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
945 ("python-zope-configuration" ,python-zope-configuration)))
946 (home-page "https://github.com/zopefoundation/zope.component")
947 (synopsis "Zope Component Architecture")
948 (description "Zope.component represents the core of the Zope Component
949Architecture. Together with the zope.interface package, it provides
950facilities for defining, registering and looking up components.")
951 (license license:zpl2.1)))
952
953(define-public python2-zope-component
954 (package-with-python2 python-zope-component))
955
956(define-public python-ndg-httpsclient
957 (package
958 (name "python-ndg-httpsclient")
6f21aca7 959 (version "0.4.4")
1b2f753d
LC
960 (source (origin
961 (method url-fetch)
962 (uri (pypi-uri "ndg_httpsclient" version))
963 (sha256
964 (base32
6f21aca7 965 "0sl5ak1r1xil9ms0a9fh9fm6ncml65kgnjpjfic9dhnaimwx997v"))))
1b2f753d
LC
966 (build-system python-build-system)
967 (arguments
968 '(;; The tests appear to require networking.
969 #:tests? #f))
970 (propagated-inputs
971 `(("python-pyopenssl" ,python-pyopenssl)))
972 (synopsis "HTTPS support for Python's httplib and urllib2")
973 (description "This is a HTTPS client implementation for httplib and urllib2
974based on PyOpenSSL. PyOpenSSL provides a more fully featured SSL implementation
975over the default provided with Python and importantly enables full verification
976of the SSL peer.")
977 (home-page "https://github.com/cedadev/ndg_httpsclient/")
978 (license license:bsd-3)))
979
980;; python2-openssl requires special care, so package-with-python2 is
981;; insufficient.
982(define-public python2-ndg-httpsclient
983 (package (inherit python-ndg-httpsclient)
984 (name "python2-ndg-httpsclient")
985 (arguments `(#:python ,python-2))
986 (propagated-inputs
987 `(("python2-pyopenssl" ,python2-pyopenssl)))))
988
989(define-public python-websocket-client
990 (package
991 (name "python-websocket-client")
992 (version "0.37.0")
993 (source
994 (origin
995 (method url-fetch)
996 (uri (pypi-uri "websocket_client" version))
997 (sha256
998 (base32
999 "0h9glp1jll3z76ly3kg08aqgxqk0a68p4zi9yn50353bh5nj92v7"))))
1000 (build-system python-build-system)
1001 (propagated-inputs
1002 `(("python-six" ,python-six)))
1003 (home-page "https://github.com/liris/websocket-client")
1004 (synopsis "WebSocket client for Python")
1005 (description "The Websocket-client module provides the low level APIs for
1006WebSocket usage in Python programs.")
1007 (license license:lgpl2.1+)))
1008
1009(define-public python2-websocket-client
1010 (package-with-python2 python-websocket-client))
1011
589e3f4e
LC
1012(define-public python-requests
1013 (package
1014 (name "python-requests")
1015 (version "2.13.0")
1016 (source (origin
1017 (method url-fetch)
1018 (uri (pypi-uri "requests" version))
1019 (sha256
1020 (base32
1021 "1s0wg4any4dsv5l3hqjxqk2zgb7pdbqhy9rhc8kh3aigfq4ws8jp"))))
1022 ;; TODO: unbundle urllib3 and chardet.
1023 (build-system python-build-system)
1024 (arguments
1025 ;; FIXME: Some tests require network access.
1026 '(#:tests? #f))
1027 (home-page "http://python-requests.org/")
1028 (synopsis "Python HTTP library")
1029 (description
1030 "Requests is a Python HTTP client library. It aims to be easier to use
1031than Python’s urllib2 library.")
1032 (license license:asl2.0)))
1033
1034;; Some software requires an older version of Requests, notably Docker
1035;; Compose.
1036(define-public python-requests-2.7
1037 (package (inherit python-requests)
1038 (version "2.7.0")
1039 (source (origin
1040 (method url-fetch)
1041 (uri (pypi-uri "requests" version))
1042 (sha256
1043 (base32
1044 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
1045
1046(define-public python2-requests
1047 (package-with-python2 python-requests))
1048
1b2f753d
LC
1049(define-public python-requests-mock
1050 (package
1051 (name "python-requests-mock")
1052 (version "1.3.0")
1053 (source
1054 (origin
1055 (method url-fetch)
1056 (uri (pypi-uri "requests-mock" version))
1057 (sha256
1058 (base32
1059 "0jr997dvk6zbmhvbpcv3rajrgag69mcsm1ai3w3rgk2jdh6rg1mx"))))
1060 (build-system python-build-system)
1061 (propagated-inputs
1062 `(("python-requests" ,python-requests)
1063 ("python-six" ,python-six)))
1064 (native-inputs
1065 `(("python-pbr" ,python-pbr)
1066 ("python-discover" ,python-discover)
1067 ("python-docutils" ,python-docutils)
1068 ("python-fixtures" ,python-fixtures)
1069 ("python-mock" ,python-mock)
1070 ("python-sphinx" ,python-sphinx)
1071 ("python-testrepository" ,python-testrepository)
1072 ("python-testtools" ,python-testtools)))
1073 (home-page "https://requests-mock.readthedocs.org/")
1074 (synopsis "Mock out responses from the requests package")
1075 (description
1076 "This module provides a building block to stub out the HTTP requests
1077portions of your testing code.")
1078 (properties `((python2-variant . ,(delay python2-requests-mock))))
1079 (license license:asl2.0)))
1080
1081(define-public python2-requests-mock
1082 (package (inherit (package-with-python2
1083 (strip-python2-variant python-requests-mock)))
1084 (arguments
1085 `(#:python ,python-2
1086 ;; FIXME: 'subunit.run discover: error: no such option: --list'
1087 #:tests? #f))))
1088
1089(define-public python-requests-toolbelt
1090 (package
1091 (name "python-requests-toolbelt")
1092 (version "0.8.0")
1093 (source (origin
1094 (method url-fetch)
1095 (uri (pypi-uri "requests-toolbelt" version))
1096 (sha256
1097 (base32
1098 "1dc7l42i4080r8i4m9fj51jx367lqkai170vrv7wd93gdj9k39gn"))))
1099 (build-system python-build-system)
1100 (native-inputs
1101 `(("python-betamax" ,python-betamax)
1102 ("python-mock" ,python-mock)
1103 ("python-pytest" ,python-pytest)))
1104 (propagated-inputs
1105 `(("python-requests" ,python-requests)))
1106 (synopsis "Extensions to python-requests")
1107 (description "This is a toolbelt of useful classes and functions to be used
1108with python-requests.")
1109 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
1110 (license license:asl2.0)))
1111
1112(define-public python2-requests-toolbelt
1113 (package-with-python2 python-requests-toolbelt))
1114
589e3f4e
LC
1115(define-public python-oauthlib
1116 (package
1117 (name "python-oauthlib")
1118 (version "1.0.3")
1119 (source (origin
1120 (method url-fetch)
1121 (uri (pypi-uri "oauthlib" version))
1122 (sha256
1123 (base32
1124 "1bfrj70vdjxjw74khbyh6f0dksv7p5rh2346jnlrffyacd3gwjzg"))))
1125 (build-system python-build-system)
1126 (native-inputs
1127 `(("python-nose" ,python-nose)
1128 ("python-mock" ,python-mock)
1129 ("python-cryptography" ,python-cryptography)
1130 ("python-pyjwt" ,python-pyjwt)
1131 ("python-blinker" ,python-blinker)))
1132 (home-page "https://github.com/idan/oauthlib")
1133 (synopsis "OAuth implementation for Python")
1134 (description
1135 "Oauthlib is a generic, spec-compliant, thorough implementation of the
1136OAuth request-signing logic.")
1137 (license license:bsd-3)
1138 (properties `((python2-variant . ,(delay python2-oauthlib))))))
1139
1140(define-public python2-oauthlib
1141 (let ((base (package-with-python2 (strip-python2-variant python-oauthlib))))
1142 (package
1143 (inherit base)
1144 (native-inputs `(("python2-unittest2" ,python2-unittest2)
1145 ,@(package-native-inputs base))))))
1146
1b2f753d
LC
1147(define-public python-rauth
1148 (package
1149 (name "python-rauth")
1150 (version "0.7.3")
1151 (source
1152 (origin
1153 (method url-fetch)
1154 (uri (pypi-uri "rauth" version))
1155 (sha256
1156 (base32
1157 "02kv8w8l98ky223avyq7vw7x1f2ya9chrm59r77ylq45qb0xnk2j"))))
1158 (build-system python-build-system)
1159 (arguments
1160 `(#:test-target "check"))
1161 (propagated-inputs
1162 `(("python-requests" ,python-requests)))
1163 (home-page "https://github.com/litl/rauth")
1164 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
1165 (description
1166 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
1167provides service wrappers for convenient connection initialization and
1168authenticated session objects providing things like keep-alive.")
1169 (license license:expat)
1170 (properties `((python2-variant . ,(delay python2-rauth))))))
1171
1172(define-public python2-rauth
1173 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
1174 (package
1175 (inherit base)
1176 (native-inputs `(("python2-unittest2" ,python2-unittest2)
1177 ,@(package-native-inputs base))))))
1178
1179(define-public python-urllib3
1180 (package
1181 (name "python-urllib3")
1182 (version "1.18.1")
1183 (source
1184 (origin
1185 (method url-fetch)
1186 (uri (pypi-uri "urllib3" version))
1187 (sha256
1188 (base32
1189 "1wb8aqnq53vzh2amrv8kc66f3h6fx217y0q62y6n30a64p2yqmam"))))
1190 (build-system python-build-system)
1191 (arguments `(#:tests? #f))
1192 (native-inputs
1193 `(;; some packages for tests
1194 ("python-nose" ,python-nose)
1195 ("python-mock" ,python-mock)
1196 ("python-tornado" ,python-tornado)))
1197 (propagated-inputs
1198 `(;; These 5 inputs are used to build urrlib3[secure]
1199 ("python-certifi" ,python-certifi)
1200 ("python-cryptography" ,python-cryptography) ;
1201 ("python-idna" ,python-idna)
1202 ("python-ipaddress" ,python-ipaddress)
1203 ("python-pyopenssl" ,python-pyopenssl)))
1204 (home-page "https://urllib3.readthedocs.org/")
1205 (synopsis "HTTP library with thread-safe connection pooling")
1206 (description
1207 "Urllib3 supports features left out of urllib and urllib2 libraries. It
1208can reuse the same socket connection for multiple requests, it can POST files,
1209supports url redirection and retries, and also gzip and deflate decoding.")
1210 (license license:expat)))
1211
1212(define-public python2-urllib3
1213 (package-with-python2 python-urllib3))
1214
1215(define-public awscli
1216 (package
1217 (name "awscli")
331ebb7f 1218 (version "1.14.41")
1b2f753d
LC
1219 (source
1220 (origin
1221 (method url-fetch)
1222 (uri (pypi-uri name version))
1223 (sha256
1224 (base32
331ebb7f 1225 "0sispclx263lybbk19zp1n9yhg8xxx4jddypzgi24vpjaqnsbwlc"))))
1b2f753d
LC
1226 (build-system python-build-system)
1227 (propagated-inputs
1228 `(("python-colorama" ,python-colorama)
1229 ("python-botocore" ,python-botocore)
1230 ("python-s3transfer" ,python-s3transfer)
1231 ("python-docutils" ,python-docutils)
1232 ("python-pyyaml" ,python-pyyaml)
1233 ("python-rsa" ,python-rsa)))
1234 (arguments
1235 ;; FIXME: The 'pypi' release does not contain tests.
1236 '(#:tests? #f))
1237 (home-page "https://aws.amazon.com/cli/")
1238 (synopsis "Command line client for AWS")
1239 (description "AWS CLI provides a unified command line interface to the
1240Amazon Web Services (AWS) API.")
1241 (license license:asl2.0)))
1242
1243(define-public python-wsgiproxy2
1244 (package
1245 (name "python-wsgiproxy2")
1246 (version "0.4.2")
1247 (source
1248 (origin
1249 (method url-fetch)
1250 (uri (pypi-uri "WSGIProxy2" version ".zip"))
1251 (sha256
1252 (base32
1253 "13kf9bdxrc95y9vriaz0viry3ah11nz4rlrykcfvb8nlqpx3dcm4"))))
1254 (build-system python-build-system)
1255 (arguments
1256 '(;; Wsgiproxy2's test suite requires Restkit, which does not yet fully
1257 ;; support Python 3:
1258 ;; https://github.com/benoitc/restkit/issues/140
1259 #:tests? #f))
1260 (native-inputs
1261 `(("unzip" ,unzip)
1262 ("python-nose" ,python-nose)
1263 ("python-coverage" ,python-coverage)))
1264 (propagated-inputs
1265 `(("python-six" ,python-six)
1266 ("python-webob" ,python-webob)))
1267 (home-page
1268 "https://github.com/gawel/WSGIProxy2/")
1269 (synopsis "WSGI Proxy with various http client backends")
1270 (description "WSGI turns HTTP requests into WSGI function calls.
1271WSGIProxy turns WSGI function calls into HTTP requests.
1272It also includes code to sign requests and pass private data,
1273and to spawn subprocesses to handle requests.")
1274 (license license:expat)))
1275
1276(define-public python2-wsgiproxy2
1277 (package-with-python2 python-wsgiproxy2))
1278
1279(define-public python-pastedeploy
1280 (package
1281 (name "python-pastedeploy")
1282 (version "1.5.2")
1283 (source
1284 (origin
1285 (method url-fetch)
1286 (uri (pypi-uri "PasteDeploy" version))
1287 (sha256
1288 (base32
1289 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
1290 (build-system python-build-system)
1291 (native-inputs
1292 `(("python-nose" ,python-nose)))
1293 (home-page "http://pythonpaste.org/deploy/")
1294 (synopsis
1295 "Load, configure, and compose WSGI applications and servers")
1296 (description
1297 "This tool provides code to load WSGI applications and servers from URIs;
1298these URIs can refer to Python Eggs for INI-style configuration files. Paste
1299Script provides commands to serve applications based on this configuration
1300file.")
1301 (license license:expat)))
1302
1303(define-public python2-pastedeploy
1304 (package-with-python2 python-pastedeploy))
1305
1306(define-public python-webtest
1307 (package
1308 (name "python-webtest")
e46dd02d 1309 (version "2.0.29")
1b2f753d
LC
1310 (source
1311 (origin
1312 (method url-fetch)
1313 (uri (pypi-uri "WebTest" version))
1314 (sha256
1315 (base32
e46dd02d 1316 "0bcj1ica5lnmj5zbvk46x28kgphcsgh7sfnwjmn0cr94mhawrg6v"))))
1b2f753d
LC
1317 (build-system python-build-system)
1318 (arguments
1319 `(;; Unfortunately we have to disable tests!
1320 ;; This release of WebTest is pinned to python-nose < 1.3,
1321 ;; but older versions of python-nose are plagued with the following
1322 ;; bug(s), which rears its ugly head during test execution:
1323 ;; https://github.com/nose-devs/nose/issues/759
1324 ;; https://github.com/nose-devs/nose/pull/811
1325 #:tests? #f))
1326 ;; Commented out code is no good, but in this case, once tests
1327 ;; are ready to be enabled again, we should put the following
1328 ;; in place:
1329 ;; (native-inputs
1330 ;; `(("python-nose" ,python-nose) ; technially < 1.3,
1331 ;; ; but see above comment
1332 ;; ("python-coverage" ,python-coverage)
1333 ;; ("python-mock" ,python-mock)
1334 ;; ("python-pastedeploy" ,python-pastedeploy)
1335 ;; ("python-wsgiproxy2" ,python-wsgiproxy2)
1336 ;; ("python-pyquery" ,python-pyquery)))
1337 (propagated-inputs
1338 `(("python-waitress" ,python-waitress)
1339 ("python-webob" ,python-webob)
1340 ("python-six" ,python-six)
1341 ("python-beautifulsoup4" ,python-beautifulsoup4)))
1342 (home-page "http://webtest.pythonpaste.org/")
1343 (synopsis "Helper to test WSGI applications")
1344 (description "Webtest allows you to test your Python web applications
1345without starting an HTTP server. It supports anything that supports the
1346minimum of WSGI.")
1347 (license license:expat)))
1348
1349(define-public python2-webtest
1350 (package-with-python2 python-webtest))
1351
1352(define-public python-flask
1353 (package
1354 (name "python-flask")
1355 (version "0.11.1")
1356 (source (origin
1357 (method url-fetch)
1358 (uri (pypi-uri "Flask" version))
1359 (sha256
1360 (base32
1361 "03kbfll4sj3v5z7r31c7bhfpi11r1np076d4p1k2kg4yzcmkywdl"))))
1362 (build-system python-build-system)
1363 (propagated-inputs
1364 `(("python-itsdangerous" ,python-itsdangerous)
1365 ("python-jinja2" ,python-jinja2)
1366 ("python-click" ,python-click)
1367 ("python-werkzeug" ,python-werkzeug)))
1368 (home-page "https://github.com/mitsuhiko/flask/")
1369 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
1370 (description "Flask is a micro web framework based on the Werkzeug toolkit
1371and Jinja2 template engine. It is called a micro framework because it does not
1372presume or force a developer to use a particular tool or library.")
1373 (license license:bsd-3)))
1374
1375(define-public python2-flask
1376 (package-with-python2 python-flask))
1377
1378(define-public python-flask-wtf
1379 (package
1380 (name "python-flask-wtf")
1381 (version "0.13.1")
1382 (source
1383 (origin
1384 (method url-fetch)
1385 (uri (pypi-uri "Flask-WTF" version))
1386 (sha256
1387 (base32
1388 "04l5743j2dici46038sqlzvf0xzpg8rf7s9ld2x24xv7f4idg990"))))
1389 (build-system python-build-system)
1390 (arguments
1391 '(#:phases
1392 (modify-phases %standard-phases
1393 (add-before 'check 'drop-failing-test
1394 (lambda _
1395 ;; FIXME: This file tries resolving an external server, which
1396 ;; fails. Try to patch out the offending section instead of
1397 ;; deleting the whole thing.
1398 (delete-file "tests/test_recaptcha.py")
1399 #t)))))
1400 (propagated-inputs
1401 `(("python-flask-babel" ,python-flask-babel)
1402 ("python-babel" ,python-babel)
1403 ("python-wtforms" ,python-wtforms)))
1404 (native-inputs
1405 `(("python-nose" ,python-nose)))
1406 (home-page "https://github.com/lepture/flask-wtf")
1407 (synopsis "Simple integration of Flask and WTForms")
1408 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
1409upload, and reCAPTCHA.")
1410 (license license:bsd-3)))
1411
1412(define-public python2-flask-wtf
1413 (package-with-python2 python-flask-wtf))
1414
1415(define-public python-flask-multistatic
1416 (package
1417 (name "python-flask-multistatic")
1418 (version "1.0")
1419 (source
1420 (origin
1421 (method url-fetch)
1422 (uri (pypi-uri "flask-multistatic" version))
1423 (sha256
1424 (base32
1425 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
1426 (build-system python-build-system)
1427 (propagated-inputs
1428 `(("python-flask" ,python-flask)))
1429 (home-page "https://pagure.io/flask-multistatic")
1430 (synopsis "Flask plugin to allow overriding static files")
1431 (description "@code{flask-multistatic} is a flask plugin that adds support
1432for overriding static files.")
1433 (license license:gpl3+)))
1434
1435(define-public python2-flask-multistatic
1436 (package-with-python2 python-flask-multistatic))
1437
1438(define-public python-cookies
1439 (package
1440 (name "python-cookies")
1441 (version "2.2.1")
1442 (source (origin
1443 (method url-fetch)
1444 (uri (pypi-uri "cookies" version))
1445 (sha256
1446 (base32
1447 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
1448 (build-system python-build-system)
1449 (arguments
1450 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
1451 #:tests? #f))
1452 (native-inputs
1453 `(("python-pytest" ,python2-pytest)))
1454 (synopsis "HTTP cookie parser and renderer")
1455 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
1456Python.")
1457 (home-page "https://gitlab.com/sashahart/cookies")
1458 (license license:expat)))
1459
1460(define-public python2-cookies
1461 (package-with-python2 python-cookies))
1462
1463(define-public python-responses
1464 (package
1465 (name "python-responses")
1466 (version "0.5.1")
1467 (source (origin
1468 (method url-fetch)
1469 (uri (pypi-uri "responses" version))
1470 (sha256
1471 (base32
1472 "1spcfxixyk9k7pk82jm6zqkwk031s95lh8q0mz7539jrb7269bcc"))))
1473 (build-system python-build-system)
1474 (arguments
1475 `(;; Test suite is not distributed:
1476 ;; https://github.com/getsentry/responses/issues/38
1477 #:tests? #f))
1478 (native-inputs
1479 `(("python-mock" ,python-mock)))
1480 (propagated-inputs
1481 `(("python-requests" ,python-requests)
1482 ("python-cookies" ,python-cookies)
1483 ("python-six" ,python-six)))
1484 (home-page "https://github.com/getsentry/responses")
1485 (synopsis "Utility for mocking out the `requests` Python library")
1486 (description "A utility library for mocking out the `requests` Python
1487library.")
1488 (license license:asl2.0)))
1489
1490(define-public python2-responses
1491 (package-with-python2 python-responses))
1492
1493(define-public python-geventhttpclient
1494 (package
1495 (name "python-geventhttpclient")
1496 (version "1.3.1")
1497 (source (origin
1498 (method url-fetch)
1499 (uri (pypi-uri "geventhttpclient" version))
1500 (sha256
1501 (base32
1502 "07d0q3wzmml75227r6y6mrl5a0zpf4v9gj0ni5rhbyzmaj4az1xx"))
1503 (modules '((guix build utils)))
1504 (snippet
1505 '(begin
1506 ;; Delete pre-compiled files.
1507 (for-each delete-file (find-files "src/geventhttpclient"
1508 ".*\\.pyc"))
1509 #t))))
1510 (build-system python-build-system)
1511 (arguments
1512 '(#:phases
1513 (modify-phases %standard-phases
1514 (add-after 'unpack 'delete-network-tests
1515 (lambda _
1516 (delete-file "src/geventhttpclient/tests/test_client.py")
1517 #t))
1518 (delete 'check)
1519 (add-after 'install 'check
1520 (lambda* (#:key inputs outputs #:allow-other-keys)
1521 (add-installed-pythonpath inputs outputs)
1522 (zero? (system* "py.test" "src/geventhttpclient/tests" "-v")))))))
1523 (native-inputs
1524 `(("python-pytest" ,python-pytest)))
1525 (propagated-inputs
1526 `(("python-certifi" ,python-certifi)
1527 ("python-gevent" ,python-gevent)
1528 ("python-six" ,python-six)))
1529 (home-page "https://github.com/gwik/geventhttpclient")
1530 (synopsis "HTTP client library for gevent")
1531 (description "@code{python-geventhttpclient} is a high performance,
1532concurrent HTTP client library for python using @code{gevent}.")
1533 (license license:expat)))
1534
1535(define-public python2-geventhttpclient
1536 (package-with-python2 python-geventhttpclient))
1537
1538(define-public python-requests-oauthlib
1539 (package
1540 (name "python-requests-oauthlib")
1541 (version "0.6.2")
1542 (source
1543 (origin
1544 (method url-fetch)
1545 (uri (pypi-uri "requests-oauthlib" version))
1546 (sha256
1547 (base32
1548 "0ykff67sjcl227c23g0rxzfx34rr5bf21kwv0z3zmgk0lfmch7hn"))))
1549 (build-system python-build-system)
1550 (arguments
1551 `(#:phases
1552 (modify-phases %standard-phases
1553 ;; removes tests that require network access
1554 (add-before 'check 'pre-check
1555 (lambda _
1556 (delete-file "tests/test_core.py")
1557 #t)))))
1558 (native-inputs
1559 `(("python-requests-mock" ,python-requests-mock)
1560 ("python-mock" ,python-mock)))
1561 (propagated-inputs
1562 `(("python-oauthlib" ,python-oauthlib)
1563 ("python-requests" ,python-requests)))
1564 (home-page
1565 "https://github.com/requests/requests-oauthlib")
1566 (synopsis
1567 "OAuthlib authentication support for Requests")
1568 (description
1569 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
1570provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
1571 (license license:isc)))
1572
1573(define-public python2-requests-oauthlib
1574 (package-with-python2 python-requests-oauthlib))
1575
1576(define-public python-url
1577 (package
1578 (name "python-url")
1579 (version "0.2.0")
1580 (source (origin
1581 (method url-fetch)
1582 (uri (pypi-uri "url" version))
1583 (sha256
1584 (base32
1585 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
1586 (build-system python-build-system)
1587 (propagated-inputs
1588 `(("python-publicsuffix" ,python-publicsuffix)))
1589 (native-inputs
1590 `(("python-coverage" ,python-coverage)
1591 ("python-nose" ,python-nose)))
1592 (arguments
1593 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
1594 (home-page "https://github.com/seomoz/url-py")
1595 (synopsis "URL Parsing")
1596 (description "Library for parsing urls.")
1597 (license license:expat)
1598 (properties `((python2-variant . ,(delay python2-url))))))
1599
1600(define-public python2-url
1601 (let ((base (package-with-python2 (strip-python2-variant python-url))))
1602 (package (inherit base)
1603 (propagated-inputs
1604 `(("python2-publicsuffix" ,python2-publicsuffix))))))
1605
1606(define-public python-cachecontrol
1607 (package
1608 (name "python-cachecontrol")
1609 (version "0.11.6")
1610 (source
1611 (origin
1612 (method url-fetch)
1613 ;; Pypi does not have tests.
1614 (uri (string-append
1615 "https://github.com/ionrock/cachecontrol/archive/v"
1616 version ".tar.gz"))
1617 (file-name (string-append name "-" version ".tar.gz"))
1618 (sha256
1619 (base32
1620 "0yj60d0f69a2l8p7y86k4zhzzm6rnxpq74sfl240pry9l0lfw2vw"))))
1621 (build-system python-build-system)
1622 (arguments
1623 `(#:phases
1624 (modify-phases %standard-phases
1625 (replace 'check
1626 (lambda _
1627 ;; Drop test that requires internet access.
1628 (delete-file "tests/test_regressions.py")
1629 (setenv "PYTHONPATH"
1630 (string-append (getcwd) "/build/lib:"
1631 (getenv "PYTHONPATH")))
1632 (zero? (system* "py.test" "-vv")))))))
1633 (native-inputs
1634 `(("python-pytest" ,python-pytest)
1635 ("python-redis" ,python-redis)
1636 ("python-webtest" ,python-webtest)
1637 ("python-mock" ,python-mock)))
1638 (propagated-inputs
1639 `(("python-requests" ,python-requests)
1640 ("python-lockfile" ,python-lockfile)))
1641 (home-page "https://github.com/ionrock/cachecontrol")
1642 (synopsis "The httplib2 caching algorithms for use with requests")
1643 (description "CacheControl is a port of the caching algorithms in
1644@code{httplib2} for use with @code{requests} session objects.")
1645 (license license:asl2.0)))
1646
1647(define-public python2-cachecontrol
1648 (package-with-python2 python-cachecontrol))
1649
1650(define-public python-betamax
1651 (package
1652 (name "python-betamax")
1653 (version "0.8.0")
1654 (source
1655 (origin
1656 (method url-fetch)
1657 (uri (pypi-uri "betamax" version))
1658 (sha256
1659 (base32
1660 "18f8v5gng3j773jlbbzx4rg1i4y2zw3m2l1zpmbvp8bh5a2q1i42"))))
1661 (build-system python-build-system)
1662 (arguments
1663 '(;; Many tests fail because they require networking.
1664 #:tests? #f))
1665 (propagated-inputs
1666 `(("python-requests" ,python-requests)))
1667 (home-page "https://github.com/sigmavirus24/betamax")
1668 (synopsis "Record HTTP interactions with python-requests")
1669 (description "Betamax will record your test suite's HTTP interactions and
1670replay them during future tests. It is designed to work with python-requests.")
1671 (license license:expat)))
1672
1673(define-public python2-betamax
1674 (package-with-python2 python-betamax))
1675
1676(define-public python-betamax-matchers
1677 (package
1678 (name "python-betamax-matchers")
1679 (version "0.4.0")
1680 (source
1681 (origin
1682 (method url-fetch)
1683 (uri (pypi-uri "betamax-matchers" version))
1684 (sha256
1685 (base32
1686 "07qpwjyq2i2aqhz5iwghnj4pqr2ys5n45v1vmpcfx9r5mhwrsq43"))))
1687 (build-system python-build-system)
1688 (propagated-inputs
1689 `(("python-betamax" ,python-betamax)
1690 ("python-requests-toolbelt" ,python-requests-toolbelt)))
1691 (home-page "https://github.com/sigmavirus24/betamax_matchers")
1692 (synopsis "VCR imitation for python-requests")
1693 (description "@code{betamax-matchers} provides a set of Matchers for
1694Betamax.")
1695 (license license:asl2.0)))
1696
1697(define-public python2-betamax-matchers
1698 (package-with-python2 python-betamax-matchers))
1699
1700(define-public python-s3transfer
1701 (package
1702 (name "python-s3transfer")
1703 (version "0.1.11")
1704 (source (origin
1705 (method url-fetch)
1706 (uri (pypi-uri "s3transfer" version))
1707 (sha256
1708 (base32
1709 "0yfrfnf404cxzn3iswibqjxklsl0b1lwgqiml6pwiqj79a7zbwbn"))))
1710 (build-system python-build-system)
1711 (arguments
1712 `(#:phases
1713 (modify-phases %standard-phases
1714 (replace 'check
1715 (lambda _
1716 ;; 7 of the 'integration' tests require network access or login
1717 ;; credentials.
1718 (zero? (system* "nosetests" "--exclude=integration")))))))
1719 (native-inputs
1720 `(("python-docutils" ,python-docutils)
1721 ("python-mock" ,python-mock)
1722 ("python-nose" ,python-nose)))
1723 (propagated-inputs
1724 `(("python-botocore" ,python-botocore)))
1725 (synopsis "Amazon S3 Transfer Manager")
1726 (description "S3transfer is a Python library for managing Amazon S3
1727transfers.")
1728 (home-page "https://github.com/boto/s3transfer")
1729 (license license:asl2.0)
1730 (properties `((python2-variant . ,(delay python2-s3transfer))))))
1731
1732(define-public python2-s3transfer
1733 (let ((base (package-with-python2 (strip-python2-variant python-s3transfer))))
1734 (package
1735 (inherit base)
1736 (native-inputs
1737 `(("python2-futures" ,python2-futures)
1738 ,@(package-native-inputs base))))))
1739
1740(define-public python-flask-restful
1741 (package
1742 (name "python-flask-restful")
1743 (version "0.3.5")
1744 (source
1745 (origin
1746 (method url-fetch)
1747 (uri (pypi-uri "Flask-RESTful" version))
1748 (sha256
1749 (base32
1750 "0hjcmdb56b7z4bkw848lxfkyrpnkwzmqn2dgnlv12mwvjpzsxr6c"))))
1751 (build-system python-build-system)
1752 (propagated-inputs
1753 `(("python-aniso8601" ,python-aniso8601)
1754 ("python-flask" ,python-flask)
1755 ("python-pycrypto" ,python-pycrypto)
1756 ("python-pytz" ,python-pytz)))
1757 (native-inputs
1758 `(;; Optional dependency of Flask. Tests need it.
1759 ("python-blinker" ,python-blinker)
1760 ("python-mock" ,python-mock) ; For tests
1761 ("python-nose" ,python-nose) ; For tests
1762 ("python-sphinx" ,python-sphinx)))
1763 (home-page
1764 "https://www.github.com/flask-restful/flask-restful/")
1765 (synopsis
1766 "Flask module for creating REST APIs")
1767 (description
1768 "This package contains a Flask module for creating REST APIs.")
1769 (license license:bsd-3)))
1770
1771(define-public python-flask-basicauth
1772 (package
1773 (name "python-flask-basicauth")
1774 (version "0.2.0")
1775 (source
1776 (origin
1777 (method url-fetch)
1778 (uri (pypi-uri "Flask-BasicAuth" version))
1779 (sha256
1780 (base32
1781 "1zq1spkjr4sjdnalpp8wl242kdqyk6fhbnhr8hi4r4f0km4bspnz"))))
1782 (build-system python-build-system)
1783 (propagated-inputs
1784 `(("python-flask" ,python-flask)))
1785 (home-page
1786 "https://github.com/jpvanhal/flask-basicauth")
1787 (synopsis
1788 "HTTP basic access authentication for Flask")
1789 (description
1790 "This package provides HTTP basic access authentication for Flask.")
1791 (license license:bsd-3)))
1792
1793(define-public python-flask-sqlalchemy
1794 (package
1795 (name "python-flask-sqlalchemy")
1796 (version "2.1")
1797 (source
1798 (origin
1799 (method url-fetch)
1800 (uri (pypi-uri "Flask-SQLAlchemy" version))
1801 (sha256
1802 (base32
1803 "1i9ps5d5snih9xlqhrvmi3qfiygkmqzxh92n25kj4pf89kj4s965"))))
1804 (build-system python-build-system)
1805 (propagated-inputs
1806 `(("python-flask" ,python-flask)
1807 ("python-sqlalchemy" ,python-sqlalchemy)))
1808 (home-page
1809 "https://github.com/mitsuhiko/flask-sqlalchemy")
1810 (synopsis
1811 "Module adding SQLAlchemy support to your Flask application")
1812 (description
1813 "This package adds SQLAlchemy support to your Flask application.")
1814 (license license:bsd-3)))
1815
1816(define-public python-flask-restplus
1817 (package
1818 (name "python-flask-restplus")
1819 (version "0.9.2")
1820 (source
1821 (origin
1822 (method url-fetch)
1823 (uri (pypi-uri "flask-restplus" version))
1824 (sha256
1825 (base32
1826 "11his6ii5brpkhld0d5bwzjjw4q3vmplpd6fmgzjrvvklsbk0cf4"))))
1827 (build-system python-build-system)
1828 (arguments
1829 '(#:tests? #f)) ; FIXME: 35/882 tests failing.
1830 ;; #:phases
1831 ;; (modify-phases %standard-phases
1832 ;; (replace 'check
1833 ;; (lambda _
1834 ;; (zero? (system* "nosetests")))))))
1835 (propagated-inputs
1836 `(("python-aniso8601" ,python-aniso8601)
1837 ("python-flask" ,python-flask)
1838 ("python-jsonschema" ,python-jsonschema)
1839 ("python-pytz" ,python-pytz)
1840 ("python-six" ,python-six)))
1841 (native-inputs
1842 `(("python-tzlocal" ,python-tzlocal)
1843 ("python-blinker" ,python-blinker)
1844 ("python-nose" ,python-nose)
1845 ("python-rednose" ,python-rednose)))
1846 (home-page "https://github.com/noirbizarre/flask-restplus")
1847 (synopsis "Framework for documented API development with Flask")
1848 (description "This package provides a framework for API development with
1849the Flask web framework in Python. It is similar to package
1850@code{python-flask-restful} but supports the @code{python-swagger}
1851documentation builder.")
1852 (license license:expat)))
1853
1854(define-public python-flask-restful-swagger
1855 (package
1856 (name "python-flask-restful-swagger")
1857 (version "0.19")
1858 (source
1859 (origin
1860 (method url-fetch)
1861 (uri (pypi-uri "flask-restful-swagger" version))
1862 (sha256
1863 (base32
1864 "16msl8hd5xjmj833bpy264v98cpl5hkw5bgl5gf5vgndxbv3rm6v"))))
1865 (build-system python-build-system)
1866 (propagated-inputs
1867 `(("python-flask-restful" ,python-flask-restful)))
1868 (home-page "https://github.com/rantav/flask-restful-swagger")
1869 (synopsis "Extract Swagger specs from Flask-Restful projects")
1870 (description "This package lets you extract Swagger API documentation
1871specs from your Flask-Restful projects.")
1872 (license license:expat)))
1873
1874(define-public python2-flask-restful-swagger
1875 (package-with-python2 python-flask-restful-swagger))
1876
1877(define-public python-htmlmin
1878 (package
1879 (name "python-htmlmin")
1880 (version "0.1.10")
1881 (source
1882 (origin
1883 (method url-fetch)
1884 (uri (pypi-uri "htmlmin" version))
1885 (sha256
1886 (base32
1887 "0qxa93j3p1ak32qh8d9kshqv8v3z0hkc13dwbhp5cn7sn3xmsp6a"))))
1888 (arguments
1889 `(#:tests? #f)) ;htmlmin has no tests
1890 (build-system python-build-system)
1891 (home-page "https://htmlmin.readthedocs.org/en/latest/")
1892 (synopsis "HTML minifier")
1893 (description "@code{htmlmin} is an HTML minifier that just works.
1894It comes with safe defaults and easily configurable options.")
1895 (license license:bsd-3)))
1896
1897(define-public python2-htmlmin
1898 (package-with-python2 python-htmlmin))
1899
1900(define-public python-flask-htmlmin
1901 (package
1902 (name "python-flask-htmlmin")
1903 (version "1.2")
1904 (source
1905 (origin
1906 (method url-fetch)
1907 (uri (pypi-uri "Flask-HTMLmin" version))
1908 (sha256
1909 (base32
1910 "1n6zlq72kakkw0z2jpq6nh74lfsmxybm4g053pwhc14fbr809348"))))
1911 (propagated-inputs
1912 `(("python-flask" ,python-flask)
1913 ("python-htmlmin" ,python-htmlmin)))
1914 (build-system python-build-system)
1915 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
1916 (synopsis "HTML response minifier for Flask")
1917 (description
1918 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
1919 (license license:bsd-3)))
1920
1921(define-public python2-flask-htmlmin
1922 (package-with-python2 python-flask-htmlmin))
1923
1924(define-public python-flask-login
1925 (package
1926 (name "python-flask-login")
1927 (version "0.4.0")
1928 (source
1929 (origin
1930 (method url-fetch)
1931 (uri (string-append "https://github.com/maxcountryman/flask-login/archive/"
1932 version ".tar.gz"))
1933 (file-name (string-append name "-" version ".tar.gz"))
1934 (sha256
1935 (base32
1936 "1pdqp7a2gyb7k06xda004x0fi2w66s6kn2i0ndkqndmg12d83f9w"))))
1937 (arguments
1938 ;; Tests fail PEP8 compliance. See:
1939 ;; https://github.com/maxcountryman/flask-login/issues/340
1940 `(#:tests? #f))
1941 (build-system python-build-system)
1942 (home-page "https://github.com/maxcountryman/flask-login")
1943 (synopsis "User session management for Flask")
1944 (description
1945 "@code{Flask-Login} provides user session management for Flask. It
1946handles the common tasks of logging in, logging out, and remembering your
1947users' sessions over extended periods of time.")
1948 (license license:expat)))
1949
1950(define-public python2-flask-login
1951 (package-with-python2 python-flask-login))
1952
1953(define-public python-oauth2client
1954 (package
1955 (name "python-oauth2client")
1956 (version "4.0.0")
1957 (source
1958 (origin
1959 (method url-fetch)
1960 (uri (pypi-uri "oauth2client" version))
1961 (sha256
1962 (base32
1963 "1irqqap2zibysf8dba8sklfqikia579srd0phm5n754ni0h59gl0"))))
1964 (build-system python-build-system)
1965 (arguments
1966 `(#:tests? #f))
1967 (propagated-inputs
1968 `(("python-httplib2" ,python-httplib2)
1969 ("python-pyasn1" ,python-pyasn1)
1970 ("python-pyasn1-modules" ,python-pyasn1-modules)
1971 ("python-rsa" ,python-rsa)
1972 ("python-six" ,python-six)))
9be5ecdf 1973 (home-page "https://github.com/google/oauth2client/")
1b2f753d
LC
1974 (synopsis "OAuth 2.0 client library")
1975 (description "@code{python-oauth2client} provides an OAuth 2.0 client
1976library for Python")
1977 (license license:asl2.0)))
1978
1979(define-public python-flask-oidc
1980 (package
1981 (name "python-flask-oidc")
1982 (version "1.1.1")
1983 (source
1984 (origin
1985 (method url-fetch)
1986 (uri (pypi-uri "flask-oidc" version))
1987 (sha256
1988 (base32
1989 "1ay5j0mf174bix7i67hclr95gv16z81fpx0dijvi0gydvdj3ddy2"))))
1990 (build-system python-build-system)
1991 (propagated-inputs
1992 `(("python-flask" ,python-flask)
1993 ("python-itsdangerous" ,python-itsdangerous)
1994 ("python-oauth2client" ,python-oauth2client)
1995 ("python-six" ,python-six)))
1996 (native-inputs
1997 `(("python-nose" ,python-nose)
1998 ("python-mock" ,python-mock)))
1999 (home-page "https://github.com/puiterwijk/flask-oidc")
2000 (synopsis "OpenID Connect extension for Flask")
2001 (description "@code{python-flask-oidc} provides an OpenID Connect extension
2002for Flask.")
2003 (license license:bsd-2)))
2004
2005(define-public python-webassets
2006 (package
2007 (name "python-webassets")
2008 (version "0.12.1")
2009 (source
2010 (origin
2011 (method url-fetch)
2012 (uri (pypi-uri "webassets" version))
2013 (sha256
2014 (base32
2015 "1nrqkpb7z46h2b77xafxihqv3322cwqv6293ngaky4j3ff4cing7"))))
2016 (build-system python-build-system)
2017 (native-inputs
2018 `(("python-jinja2" ,python-jinja2)
2019 ("python-mock" ,python-mock)
2020 ("python-nose" ,python-nose)
2021 ("python-pytest" ,python-pytest)))
2022 (home-page "https://github.com/miracle2k/webassets")
2023 (synopsis "Media asset management")
2024 (description "Merges, minifies and compresses Javascript and CSS files,
2025supporting a variety of different filters, including YUI, jsmin, jspacker or
2026CSS tidy. Also supports URL rewriting in CSS files.")
2027 (license license:bsd-2)))
2028
2029(define-public python-cssmin
2030 (package
2031 (name "python-cssmin")
2032 (version "0.2.0")
2033 (source
2034 (origin
2035 (method url-fetch)
2036 (uri (pypi-uri "cssmin" version))
2037 (sha256
2038 (base32
2039 "1dk723nfm2yf8cp4pj785giqlwv42l0kj8rk40kczvq1hk6g04p0"))))
2040 (build-system python-build-system)
2041 (home-page "https://github.com/zacharyvoase/cssmin")
2042 (synopsis "Python port of the YUI CSS Compressor")
2043 (description "Python port of the YUI CSS Compressor.")
2044 (license (list license:expat license:bsd-3))))
2045
2046(define-public python2-cssmin
2047 (package-with-python2 python-cssmin))
2048
2049(define-public python-elasticsearch
2050 (package
2051 (name "python-elasticsearch")
aabcb6e5 2052 (version "6.1.1")
1b2f753d
LC
2053 (source
2054 (origin
2055 (method url-fetch)
2056 (uri (pypi-uri "elasticsearch" version))
2057 (sha256
2058 (base32
aabcb6e5 2059 "1kjxl45yvvgfb5fmamx0kfsfg9pzphiqrwbkns3s28r1w7ya74cd"))))
1b2f753d
LC
2060 (build-system python-build-system)
2061 (native-inputs
2062 `(("python-mock" ,python-mock)
2063 ("python-nosexcover" ,python-nosexcover)
2064 ("python-pyaml" ,python-pyaml)
2065 ("python-requests" ,python-requests)))
2066 (propagated-inputs
2067 `(("urllib3" ,python-urllib3)))
2068 (arguments
2069 ;; tests require the test_elasticsearch module but it is not distributed.
2070 `(#:tests? #f))
2071 (home-page "https://github.com/elastic/elasticsearch-py")
2072 (synopsis "Low-level client for Elasticsearch")
2073 (description "Official low-level client for Elasticsearch. Its goal is to
2074provide common ground for all Elasticsearch-related code in Python; because of
2075this it tries to be opinion-free and very extendable.")
2076 (license license:expat)))
2077
2078(define-public python2-elasticsearch
2079 (package-with-python2 python-elasticsearch))
2080
2081(define-public python-flask-script
2082 (package
2083 (name "python-flask-script")
2084 (version "2.0.5")
2085 (source
2086 (origin
2087 (method url-fetch)
2088 (uri (pypi-uri "Flask-Script" version))
2089 (sha256
2090 (base32
2091 "0zqh2yq8zk7m9b4xw1ryqmrljkdigfb3hk5155a3b5hkfnn6xxyf"))))
2092 (build-system python-build-system)
2093 (propagated-inputs
2094 `(("python-flask" ,python-flask)
2095 ("python-argcomplete" ,python-argcomplete)
2096 ("python-werkzeug" ,python-werkzeug)))
2097 (native-inputs
2098 `(("python-pytest" ,python-pytest)))
2099 (home-page
9be5ecdf 2100 "https://github.com/smurfix/flask-script")
1b2f753d
LC
2101 (synopsis "Scripting support for Flask")
2102 (description "The Flask-Script extension provides support for writing
2103external scripts in Flask. This includes running a development server,
2104a customised Python shell, scripts to set up your database, cronjobs,
2105and other command-line tasks that belong outside the web application
2106itself.")
2107 (license license:bsd-3)))
2108
2109(define-public python2-flask-script
2110 (package-with-python2 python-flask-script))
2111
2112(define-public python-flask-migrate
2113 (package
2114 (name "python-flask-migrate")
2115 (version "2.0.3")
2116 (source
2117 (origin
2118 (method url-fetch)
2119 (uri (pypi-uri "Flask-Migrate" version))
2120 (sha256
2121 (base32
2122 "107x78lkqsnbg92dld3dkagg07jvchp3ib3y0sivc4ipz6n1y7rk"))))
2123 (build-system python-build-system)
2124 (propagated-inputs
2125 `(("python-flask" ,python-flask)
2126 ("python-alembic" ,python-alembic)
2127 ("python-sqlalchemy" ,python-sqlalchemy)
2128 ("python-flask-script" ,python-flask-script)
2129 ("python-flask-sqlalchemy" ,python-flask-sqlalchemy)))
9be5ecdf 2130 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
1b2f753d
LC
2131 (synopsis "SQLAlchemy database migrations for Flask programs using
2132Alembic")
2133 (description "This package contains SQLAlchemy database migration tools
2134for Flask programs that are using @code{python-alembic}.")
2135 (license license:expat)))
2136
2137(define-public python2-flask-migrate
2138 (package-with-python2 python-flask-migrate))
2139
2140(define-public python-genshi
2141 (package
2142 (name "python-genshi")
2143 (version "0.7")
2144 (source
2145 (origin
2146 (method url-fetch)
2147 (uri (string-append
2148 "https://ftp.edgewall.org/pub/genshi/Genshi-"
2149 version ".tar.gz"))
2150 (patches
2151 (search-patches
2152 ;; The first 4 patches are in the master branch upstream.
2153 ;; See this as a reference https://genshi.edgewall.org/ticket/582
2154 ;; The last 2 are NOT in any branch.
2155 ;; They were sent as attachments to a ticket opened at
2156 ;; https://genshi.edgewall.org/ticket/602#no1
2157 "python-genshi-stripping-of-unsafe-script-tags.patch"
2158 "python-genshi-disable-speedups-on-python-3.3.patch"
2159 "python-genshi-isstring-helper.patch"
2160 "python-genshi-add-support-for-python-3.4-AST.patch"
2161 "python-genshi-fix-tests-on-python-3.5.patch"
2162 "python-genshi-buildable-on-python-2.7.patch"))
2163 (sha256
2164 (base32
2165 "0lkkbp6fbwzv0zda5iqc21rr7rdldkwh3hfabfjl9i4bwq14858x"))))
2166 (build-system python-build-system)
2167 (home-page "https://genshi.edgewall.org/")
2168 (synopsis "Toolkit for generation of output for the web")
2169 (description "Genshi is a Python library that provides an integrated set
2170of components for parsing, generating, and processing HTML, XML or other
2171textual content for output generation on the web.")
2172 (license license:bsd-3)))
2173
2174;; The linter here claims that patch file names should start with the package
2175;; name. But, in this case the patches are inherited from python-genshi with
2176;; the "python-genshi-" prefix instead of "python2-genshi-".
2177(define-public python2-genshi
2178 (package-with-python2 python-genshi))
2179
2180(define-public python-flask-principal
2181 (package
2182 (name "python-flask-principal")
2183 (version "0.4.0")
2184 (source
2185 (origin
2186 (method url-fetch)
2187 (uri (pypi-uri "Flask-Principal" version))
2188 (sha256
2189 (base32
2190 "0lwlr5smz8vfm5h9a9i7da3q1c24xqc6vm9jdywdpgxfbi5i7mpm"))))
2191 (build-system python-build-system)
2192 (propagated-inputs
2193 `(("python-blinker" ,python-blinker)))
2194 (native-inputs
2195 `(("python-flask" ,python-flask)
2196 ("python-nose" ,python-nose)))
2197 (home-page "http://packages.python.org/Flask-Principal/")
2198 (synopsis "Identity management for Flask")
2199 (description "@code{flask_principal} is a identity management library for
2200Flask. It supports managing both authentication and authorization data in a
2201thread-local variable.")
2202 (license license:expat)))
2203
2204(define-public python2-flask-principal
2205 (package-with-python2 python-flask-principal))
2206
2207(define-public python-flask-httpauth
2208 (package
2209 (name "python-flask-httpauth")
2210 (version "3.2.3")
2211 (source
2212 (origin
2213 (method url-fetch)
2214 (uri (pypi-uri "Flask-HTTPAuth" version))
2215 (sha256
2216 (base32
2217 "13gff5w1mqpzm5nccyg02v3ifb9ifqh5k866cssjhghhg6msfjsz"))))
2218 (build-system python-build-system)
2219 (native-inputs
2220 `(("python-flask" ,python-flask)))
9be5ecdf 2221 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
1b2f753d
LC
2222 (synopsis "Basic and Digest HTTP authentication for Flask routes")
2223 (description "@code{flask_httpauth} provides Basic and Digest HTTP
2224authentication for Flask routes.")
2225 (license license:expat)))
2226
2227(define-public python2-flask-httpauth
2228 (package-with-python2 python-flask-httpauth))
2229
2230(define-public python-uritemplate
2231 (package
2232 (name "python-uritemplate")
2233 (version "3.0.0")
2234 (source
2235 (origin
2236 (method url-fetch)
2237 (uri (pypi-uri "uritemplate" version))
2238 (sha256
2239 (base32
2240 "0781gm9g34wa0asc19dx81ng0nqq07igzv3bbvdqmz13pv7469n0"))))
2241 (build-system python-build-system)
2242 (home-page "https://uritemplate.readthedocs.org")
2243 (synopsis "Library to deal with URI Templates")
2244 (description "@code{uritemplate} provides Python library to deal with URI
2245Templates.")
2246 (license license:bsd-2)))
2247
2248(define-public python2-uritemplate
2249 (package-with-python2 python-uritemplate))
2250
589e3f4e
LC
2251(define-public python-publicsuffix
2252 (package
2253 (name "python-publicsuffix")
2254 (version "1.1.0")
2255 (source (origin
2256 (method url-fetch)
2257 (uri (pypi-uri "publicsuffix" version))
2258 (sha256
2259 (base32
2260 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
2261 (build-system python-build-system)
2262 (arguments
2263 `(#:tests? #f)) ; tests use the internet
2264 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
2265 (synopsis "Get suffix for a domain name")
2266 (description "Get a public suffix for a domain name using the Public Suffix
2267List.")
2268 (license license:expat)))
2269
2270(define-public python2-publicsuffix
2271 (package-with-python2 python-publicsuffix))
2272
2273(define-public python-publicsuffix2
2274 (package
2275 (name "python-publicsuffix2")
2276 (version "2.20160818")
2277 (source
2278 (origin
2279 (method url-fetch)
2280 (uri (pypi-uri "publicsuffix2" version ".tar.bz2"))
2281 (sha256
2282 (base32
2283 "1bb55yka9vkn7i6y1kjzxa516kh6v4gsrxa90w5wdz5p5n968r68"))))
2284 (build-system python-build-system)
2285 (arguments
2286 '(#:tests? #f)) ; The test suite requires network access.
2287 (home-page "https://github.com/pombredanne/python-publicsuffix2")
2288 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
2289 (description "Get a public suffix for a domain name using the Public Suffix
2290List. Forked from and using the same API as the publicsuffix package.")
2291 (license (list license:expat license:mpl2.0))))
2292
2293(define-public python2-publicsuffix2
2294 (package-with-python2 python-publicsuffix2))
98c6a025
RW
2295
2296(define-public python-werkzeug
2297 (package
2298 (name "python-werkzeug")
2299 (version "0.11.15")
2300 (source
2301 (origin
2302 (method url-fetch)
2303 (uri (pypi-uri "Werkzeug" version))
2304 (sha256
2305 (base32
2306 "1h5wycw8yj7q0grqsjnsqflmrlsdagvl2j4dsgdncci6mjc7fpa5"))))
2307 (build-system python-build-system)
2308 (native-inputs
2309 `(("python-pytest" ,python-pytest)))
2310 (home-page "http://werkzeug.pocoo.org/")
2311 (synopsis "Utilities for WSGI applications")
2312 (description "One of the most advanced WSGI utility modules. It includes a
2313powerful debugger, full-featured request and response objects, HTTP utilities to
2314handle entity tags, cache control headers, HTTP dates, cookie handling, file
2315uploads, a powerful URL routing system and a bunch of community-contributed
2316addon modules.")
2317 (license license:x11)))
2318
2319(define-public python2-werkzeug
2320 (package-with-python2 python-werkzeug))
2321
2322(define-public python-bottle
2323 (package
2324 (name "python-bottle")
2325 (version "0.12.13")
2326 (source
2327 (origin
2328 (method url-fetch)
2329 (uri (pypi-uri "bottle" version))
2330 (sha256
2331 (base32
2332 "0m9k2a7yxvggc4kw8fsvj381vgsvfcdshg5nzy6vwrxiw2p53drr"))))
2333 (build-system python-build-system)
2334 (home-page "http://bottlepy.org/")
2335 (synopsis "WSGI framework for small web-applications.")
2336 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
2337 (license license:expat)))
2338
2339(define-public python2-bottle
2340 (package-with-python2 python-bottle))
2341
2342(define-public python-wtforms
2343 (package
2344 (name "python-wtforms")
2345 (version "2.1")
2346 (source
2347 (origin
2348 (method url-fetch)
2349 (uri (pypi-uri "WTForms" version ".zip"))
2350 (sha256
2351 (base32
2352 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
2353 (build-system python-build-system)
2354 (arguments
2355 '(#:phases
2356 (modify-phases %standard-phases
2357 (add-after 'unpack 'remove-django-test
2358 ;; Don't fail the tests when the inputs for the optional tests cannot be found.
2359 (lambda _
2360 (substitute*
2361 "tests/runtests.py"
2362 (("'ext_django.tests', 'ext_sqlalchemy', 'ext_dateutil', 'locale_babel'") "")
2363 (("sys.stderr.write(\"### Disabled test '%s', dependency not found\n\" % name)") ""))
2364 #t)))))
2365 (native-inputs
2366 `(("unzip" ,unzip)))
2367 (home-page "http://wtforms.simplecodes.com/")
2368 (synopsis
2369 "Form validation and rendering library for Python web development")
2370 (description
2371 "WTForms is a flexible forms validation and rendering library
2372for Python web development. It is very similar to the web form API
2373available in Django, but is a standalone package.")
2374 (license license:bsd-3)))
2375
2376(define-public python2-wtforms
2377 (package-with-python2 python-wtforms))
2378
2379(define-public python-paste
2380 (package
2381 (name "python-paste")
2382 (version "2.0.3")
2383 (source
2384 (origin
2385 (method url-fetch)
2386 (uri (pypi-uri "Paste" version))
2387 (sha256
2388 (base32
2389 "062jk0nlxf6lb2wwj6zc20rlvrwsnikpkh90y0dn8cjch93s6ii3"))
2390 (patches (search-patches "python-paste-remove-website-test.patch"
2391 "python-paste-remove-timing-test.patch"))))
2392 (build-system python-build-system)
2393 (native-inputs
2394 `(("python-nose" ,python-nose)))
2395 (propagated-inputs
2396 `(("python-six" ,python-six)))
2397 (home-page "http://pythonpaste.org")
2398 (synopsis
2399 "Python web development tools, focusing on WSGI")
2400 (description
2401 "Paste provides a variety of web development tools and middleware which
2402can be nested together to build web applications. Paste's design closely
2403follows ideas flowing from WSGI (Web Standard Gateway Interface).")
2404 (license license:expat)))
2405
2406(define-public python2-paste
2407 (package-with-python2 python-paste))
2408
2409(define-public python-pastescript
2410 (package
2411 (name "python-pastescript")
2412 (version "2.0.2")
2413 (source
2414 (origin
2415 (method url-fetch)
2416 (uri (pypi-uri "PasteScript" version))
2417 (sha256
2418 (base32
2419 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
2420 (build-system python-build-system)
2421 (native-inputs
2422 `(("python-nose" ,python-nose)))
2423 (propagated-inputs
2424 `(("python-paste" ,python-paste)
2425 ("python-pastedeploy" ,python-pastedeploy)))
2426 (home-page "http://pythonpaste.org/script/")
2427 (arguments
2428 '(;; Unfortunately, this requires the latest unittest2,
2429 ;; but that requires traceback2 which requires linecache2 which requires
2430 ;; unittest2. So we're skipping tests for now.
2431 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
2432 ;; so in theory we could get around this situation somehow.)
2433 #:tests? #f))
2434 (synopsis
2435 "Pluggable command line tool for serving web applications and more")
2436 (description
2437 "PasteScript is a plugin-friendly command line tool which provides a
2438variety of features, from launching web applications to bootstrapping project
2439layouts.")
2440 (license license:expat)))
2441
2442(define-public python2-pastescript
2443 (package-with-python2 python-pastescript))