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