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