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 ;;; Copyright © 2020 Alexandros Theodotou <alex@zrythm.org>
38 ;;; This file is part of GNU Guix.
40 ;;; GNU Guix is free software; you can redistribute it and/or modify it
41 ;;; under the terms of the GNU General Public License as published by
42 ;;; the Free Software Foundation; either version 3 of the License, or (at
43 ;;; your option) any later version.
45 ;;; GNU Guix is distributed in the hope that it will be useful, but
46 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
47 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
48 ;;; GNU General Public License for more details.
50 ;;; You should have received a copy of the GNU General Public License
51 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
53 (define-module (gnu packages python-web)
54 #:use-module (guix packages)
55 #:use-module (guix download)
56 #:use-module (guix git-download)
57 #:use-module (guix build-system python)
58 #:use-module (guix utils)
59 #:use-module (gnu packages)
60 #:use-module (gnu packages base)
61 #:use-module (gnu packages check)
62 #:use-module (gnu packages compression)
63 #:use-module (gnu packages curl)
64 #:use-module (gnu packages databases)
65 #:use-module (gnu packages django)
66 #:use-module (gnu packages groff)
67 #:use-module (gnu packages libffi)
68 #:use-module (gnu packages pkg-config)
69 #:use-module (gnu packages python)
70 #:use-module (gnu packages python-check)
71 #:use-module (gnu packages python-crypto)
72 #:use-module (gnu packages python-xyz)
73 #:use-module (gnu packages serialization)
74 #:use-module (gnu packages sphinx)
75 #:use-module (gnu packages texinfo)
76 #:use-module (gnu packages tls)
77 #:use-module (gnu packages time)
78 #:use-module (gnu packages web)
79 #:use-module (gnu packages xml)
80 #:use-module ((guix licenses) #:prefix license:)
81 #:use-module (srfi srfi-1))
83 (define-public python-aiohttp
85 (name "python-aiohttp")
90 (uri (pypi-uri "aiohttp" version))
93 "09pkw6f1790prnrq0k8cqgnf1qy57ll8lpmc6kld09q7zw4vi6i5"))
94 (patches (search-patches "python-aiohttp-3.6.2-no-warning-fail.patch"))))
96 (build-system python-build-system)
99 (modify-phases %standard-phases
100 (add-after 'unpack 'fix-tests
102 ;; disable brotli tests, because we’re not providing that optional library
103 (substitute* "tests/test_http_parser.py"
104 ((" async def test_feed_eof_no_err_brotli")
105 " @pytest.mark.xfail\n async def test_feed_eof_no_err_brotli"))
106 ;; make sure the timestamp of this file is > 1990, because a few
107 ;; tests like test_static_file_if_modified_since_past_date depend on it
108 (invoke "touch" "-d" "2020-01-01" "tests/data.unknown_mime_type")
111 `(("python-aiodns" ,python-aiodns)
112 ("python-async-timeout" ,python-async-timeout)
113 ("python-attrs" ,python-attrs)
114 ("python-chardet" ,python-chardet)
115 ("python-idna-ssl" ,python-idna-ssl)
116 ("python-multidict" ,python-multidict)
117 ("python-yarl" ,python-yarl)))
119 `(("python-pytest-runner" ,python-pytest-runner)
120 ("python-pytest-xdit" ,python-pytest-xdist)
121 ("python-pytest-timeout" ,python-pytest-timeout)
122 ("python-pytest-forked" ,python-pytest-forked)
123 ("python-pytest-mock" ,python-pytest-mock)
124 ("gunicorn" ,gunicorn-bootstrap)
125 ("python-freezegun" ,python-freezegun)
126 ("python-async-generator" ,python-async-generator)))
127 (home-page "https://github.com/aio-libs/aiohttp/")
128 (synopsis "Async HTTP client/server framework (asyncio)")
129 (description "@code{aiohttp} is an asynchronous HTTP client/server
132 Its main features are:
134 @item Supports both client and server side of HTTP protocol.
135 @item Supports both client and server Web-Sockets out-of-the-box without the
137 @item Web-server has middlewares and pluggable routing.
139 (license license:asl2.0)))
141 (define-public python-aiohttp-socks
143 (name "python-aiohttp-socks")
148 (uri (pypi-uri "aiohttp_socks" version))
151 "0473702jk66xrgpm28wbdgpnak4v0dh2qmdjw7ky7hf3lwwqkggf"))))
152 (build-system python-build-system)
154 `(("python-aiohttp" ,python-aiohttp)))
155 (home-page "https://github.com/romis2012/aiohttp-socks")
156 (synopsis "SOCKS proxy connector for aiohttp")
157 (description "This package provides a SOCKS proxy connector for
158 aiohttp. It supports SOCKS4(a) and SOCKS5.")
159 (license license:asl2.0)))
161 (define-public python-aiodns
163 (name "python-aiodns")
168 (uri (pypi-uri "aiodns" version))
171 "1snr5paql8dgvc676n8xq460wypjsb1xj53cf3px1s4wczf7lryq"))))
172 (build-system python-build-system)
174 `(("python-pycares" ,python-pycares)))
176 `(#:tests? #f)) ;tests require internet access
177 (home-page "http://github.com/saghul/aiodns")
178 (synopsis "Simple DNS resolver for asyncio")
179 (description "@code{aiodns} provides a simple way for doing
180 asynchronous DNS resolutions with a synchronous looking interface by
181 using @url{https://github.com/saghul/pycares,pycares}.")
182 (license license:expat)))
184 (define-public python-aiorpcx
186 (name "python-aiorpcx")
191 (uri (pypi-uri "aiorpcX" version))
194 "0k545hc7wl6sh1svydzbv6x7sx5pig2pqkl3yxs9riwmvzawx9xp"))))
195 (build-system python-build-system)
197 `(("python-attrs" ,python-attrs)))
198 (home-page "https://github.com/kyuupichan/aiorpcX")
199 (synopsis "Generic asyncio RPC implementation")
201 "The aiorpcX library is a generic asyncio implementation of RPC suitable
202 for an application that is a client, server or both.
204 The package includes a module with full coverage of JSON RPC versions 1.0 and
205 2.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
206 comes with a SOCKS proxy client.")
207 (license (list license:expat license:bsd-2))))
209 (define-public python-falcon
211 (name "python-falcon")
216 (uri (pypi-uri "falcon" version))
219 "1i0vmqsk24z4biirqhpvas9h28wy7nmpy3jvnb6rz2imq04zd09r"))))
220 (build-system python-build-system)
223 (modify-phases %standard-phases
226 (invoke "pytest"))))))
228 `(("python-mimeparse" ,python-mimeparse)
229 ("python-six" ,python-six)))
231 `(("python-cython" ,python-cython) ;for faster binaries
232 ("python-pytest" ,python-pytest)
233 ("python-pyyaml" ,python-pyyaml)
234 ("python-requests" ,python-requests)
235 ("python-testtools" ,python-testtools)
236 ("python-jsonschema" ,python-jsonschema)
237 ("python-msgpack" ,python-msgpack)))
238 (home-page "https://falconframework.org")
240 "Web framework for building APIs and application backends")
242 "Falcon is a web API framework for building microservices, application
243 backends and higher-level frameworks. Among its features are:
245 @item Optimized and extensible code base
246 @item Routing via URI templates and REST-inspired resource
248 @item Access to headers and bodies through request and response
250 @item Request processing via middleware components and hooks
251 @item Idiomatic HTTP error responses
252 @item Straightforward exception handling
253 @item Unit testing support through WSGI helpers and mocks
254 @item Compatible with both CPython and PyPy
255 @item Cython support for better performance when used with CPython
257 (license license:asl2.0)))
259 (define-public python2-falcon
260 (package-with-python2 python-falcon))
262 (define-public python-falcon-cors
264 (name "python-falcon-cors")
269 (uri (pypi-uri "falcon-cors" version))
272 "12pym7hwsbd8b0c1azn95nas8gm3f1qpr6lpyx0958xm65ffr20p"))))
273 (build-system python-build-system)
275 `(("python-falcon" ,python-falcon)))
277 "https://github.com/lwcolton/falcon-cors")
278 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
279 (description "This middleware provides @dfn{cross-origin resource
280 sharing} (CORS) support for Falcon. It allows applying a specially crafted
281 CORS object to the incoming requests, enabling the ability to serve resources
282 over a different origin than that of the web application.")
283 (license license:asl2.0)))
285 (define-public python2-falcon-cors
286 (package-with-python2 python-falcon-cors))
288 (define-public python-furl
295 (uri (pypi-uri "furl" version))
298 "0lzpfpm686hvz3sr1mcrnd1b3lgmnw8v59gb43wfi98r3b671pqc"))))
299 (build-system python-build-system)
301 `(("python-six" ,python-six)
302 ("python-orderedmultidict" ,python-orderedmultidict)))
304 `(("python-pycodestyle" ,python-pycodestyle)))
305 (home-page "https://github.com/gruns/furl")
306 (synopsis "URL manipulation in Python")
307 (description "Furl provides an easy-to-use alternative to the
308 @code{urllib} and @code{urlparse} modules for manipulating URLs.")
309 (license license:unlicense)))
311 (define-public python2-furl
312 (package-with-python2 python-furl))
314 (define-public python-httplib2
316 (name "python-httplib2")
321 (uri (pypi-uri "httplib2" version))
324 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
325 (build-system python-build-system)
326 (home-page "https://github.com/jcgregorio/httplib2")
327 (synopsis "Comprehensive HTTP client library")
329 "A comprehensive HTTP client library supporting many features left out of
330 other HTTP libraries.")
331 (license license:expat)))
333 (define-public python2-httplib2
334 (package-with-python2 python-httplib2))
336 (define-public httpie
343 (uri (pypi-uri "httpie" version))
346 "02bw20cwv3a1lzrn919dk25dq4v81x6q786zlrqsqzhsdxszj14c"))))
347 (build-system python-build-system)
349 ;; The tests attempt to access external web servers, so we cannot run them.
352 `(("python-colorama" ,python-colorama)
353 ("python-pygments" ,python-pygments)
354 ("python-requests" ,python-requests)))
355 (home-page "https://httpie.org/")
356 (synopsis "cURL-like tool for humans")
358 "A command line HTTP client with an intuitive UI, JSON support,
359 syntax highlighting, wget-like downloads, plugins, and more. It consists of
360 a single http command designed for painless debugging and interaction with
361 HTTP servers, RESTful APIs, and web services.")
362 (license license:bsd-3)))
364 (define-public python-html2text
366 (name "python-html2text")
367 (version "2019.8.11")
371 (uri (pypi-uri "html2text" version))
374 "0ppgjplg06kmv9sj0x8p7acczcq2mcfgk1jdjwm4w5w40b0vj5pm"))))
375 (build-system python-build-system)
378 (modify-phases %standard-phases
381 (invoke "pytest" "test/"))))))
383 `(("python-pytest" ,python-pytest)))
384 (home-page "https://github.com/Alir3z4/html2text")
385 (synopsis "Convert HTML into plain text")
386 (description "html2text takes HTML and converts it into plain ASCII text
387 which is also valid markdown. html2text was originally written by Aaron
389 (license license:gpl3+)))
391 (define-public python2-html2text
392 (package-with-python2 python-html2text))
394 (define-public python-mechanicalsoup
396 (name "python-mechanicalsoup")
401 (uri (pypi-uri "MechanicalSoup" version))
403 (base32 "0k59wwk75q7nz6i6gynvzhagy02ql0bv7py3qqcwgjw7607yq4i7"))))
404 (build-system python-build-system)
406 ;; TODO: Enable tests when python-flake8@3.5 hits master.
409 `(("python-beautifulsoup4" ,python-beautifulsoup4)
410 ("python-lxml" ,python-lxml)
411 ("python-requests" ,python-requests)
412 ("python-six" ,python-six)))
415 ;; `(("python-pytest-flake8" ,python-pytest-flake8)
416 ;; ("python-pytest-httpbin" ,python-pytest-httpbin)
417 ;; ("python-pytest-mock" ,python-pytest-mock)
418 ;; ("python-pytest-runner" ,python-pytest-runner)
419 ;; ("python-requests-mock" ,python-requests-mock)))
420 (home-page "https://mechanicalsoup.readthedocs.io/")
421 (synopsis "Python library for automating website interaction")
423 "MechanicalSoup is a Python library for automating interaction with
424 websites. It automatically stores and sends cookies, follows redirects, and can
425 follow links and submit forms. It doesn’t do JavaScript.")
426 (license license:expat)))
428 (define-public python2-mechanicalsoup
429 (package-with-python2 python-mechanicalsoup))
431 (define-public python-sockjs-tornado
433 (name "python-sockjs-tornado")
438 (uri (pypi-uri "sockjs-tornado" version))
441 "15dgv6hw6c7h3m310alw1h6p5443lrm9pyqhcv2smc13fz1v04pc"))))
442 (build-system python-build-system)
444 `(;; There are no tests, and running the test phase requires missing
448 `(("python-tornado" ,python-tornado)))
449 (home-page "https://github.com/mrjoes/sockjs-tornado/")
451 "SockJS Python server implementation on top of the Tornado framework")
453 "SockJS-tornado provides the server-side counterpart to a SockJS client
454 library, through the Tornado framework.
456 SockJS provides a low-latency, full-duplex, cross-domain communication channel
457 between a web browser and web server.")
458 (license license:expat)))
460 (define-public python2-sockjs-tornado
461 (package-with-python2 python-sockjs-tornado))
463 (define-public python-flask-babel
465 (name "python-flask-babel")
470 (uri (pypi-uri "Flask-Babel" version))
473 "0gmb165vkwv5v7dxsxa2i3zhafns0fh938m2zdcrv4d8z5l099yn"))))
474 (build-system python-build-system)
476 '(#:phases (modify-phases %standard-phases
479 (with-directory-excursion "tests"
480 (invoke "python" "tests.py")))))))
482 `(("python-flask" ,python-flask)
483 ("python-babel" ,python-babel)
484 ("python-jinja2" ,python-jinja2)
485 ("python-pytz" ,python-pytz)))
486 (home-page "https://github.com/python-babel/flask-babel")
487 (synopsis "Add i18n/l10n support to Flask applications")
488 (description "This package implements internationalization and localization
489 support for Flask. This is based on the Python babel module as well as pytz -
490 both of which are installed automatically if you install this library.")
491 (license license:bsd-3)))
493 (define-public python2-flask-babel
494 (package-with-python2 python-flask-babel))
496 (define-public python-html5lib
498 (name "python-html5lib")
503 (uri (pypi-uri "html5lib" version))
506 "0dipzfrycv6j1jw82v9b7d8lzggx3x8xngx6l4xrqkxwvg7hvjv6"))))
507 (build-system python-build-system)
509 `(("python-six" ,python-six)
510 ("python-webencodings" ,python-webencodings)))
512 `(#:test-target "check"))
514 "https://github.com/html5lib/html5lib-python")
516 "Python HTML parser based on the WHATWG HTML specifcation")
518 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
519 and written in Python.")
520 (license license:expat)))
522 (define-public python2-html5lib
523 (package-with-python2 python-html5lib))
525 ;; Needed for python-bleach, a dependency of python-notebook
526 (define-public python-html5lib-0.9
528 (inherit python-html5lib)
533 (uri (pypi-uri "html5lib" version))
536 "17n4zfsj6ynmbwdwviywmj8r6nzr3xvfx2zs0xhndmvm51z7z263"))))))
538 (define-public python2-html5lib-0.9
539 (package-with-python2 python-html5lib-0.9))
541 (define-public python-html5-parser
543 (name "python-html5-parser")
547 (uri (pypi-uri "html5-parser" version))
550 "01mx33sx4dhl4kj6wc48nj6jz7ry60rkhjv0s6k8h5xmjf5yy0x9"))))
551 (build-system python-build-system)
553 `(("pkg-config" ,pkg-config)))
555 `(("libxml2" ,libxml2)))
557 `(("python-lxml" ,python-lxml)
558 ("python-beautifulsoup4" ,python-beautifulsoup4)))
559 (home-page "https://html5-parser.readthedocs.io")
560 (synopsis "Fast C-based HTML5 parsing for Python")
561 (description "This package provides a fast implementation of the HTML5
562 parsing spec for Python. Parsing is done in C using a variant of the gumbo
563 parser. The gumbo parse tree is then transformed into an lxml tree, also in
564 C, yielding parse times that can be a thirtieth of the html5lib parse times.")
565 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
566 ;; indicate ASL2.0, including the LICENSE file for the whole project.
567 (license (list license:asl2.0 license:gpl3))))
569 (define-public python2-html5-parser
570 (package-with-python2 python-html5-parser))
572 (define-public python-pycurl
574 (name "python-pycurl")
579 (uri (string-append "https://dl.bintray.com/pycurl/pycurl/pycurl-"
582 (base32 "1915kb04k1j4y6k1dx1sgnbddxrl9r1n4q928if2lkrdm73xy30g"))))
583 (build-system python-build-system)
585 ;; The tests attempt to access external web servers, so we cannot run
586 ;; them. Furthermore, they are skipped altogether when using Python 2.
588 #:phases (modify-phases %standard-phases
589 (add-before 'build 'configure-tls-backend
591 ;; XXX: PycURL fails to automatically determine which TLS
592 ;; backend to use when cURL is built with --disable-static.
593 ;; See setup.py and <https://github.com/pycurl/pycurl/pull/147>.
594 (setenv "PYCURL_SSL_LIBRARY" "gnutls")
597 `(("python-nose" ,python-nose)
598 ("python-bottle" ,python-bottle)))
602 (home-page "http://pycurl.io/")
603 (synopsis "Lightweight Python wrapper around libcurl")
604 (description "Pycurl is a lightweight wrapper around libcurl. It provides
605 high-speed transfers via libcurl and frequently outperforms alternatives.")
607 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
608 ;; under the terms of LGPLv2.1+ or Expat.
609 (license (list license:lgpl2.1+ license:expat))))
611 (define-public python2-pycurl
612 (package-with-python2 python-pycurl))
614 (define-public python-webencodings
616 (name "python-webencodings")
620 (uri (pypi-uri "webencodings" version))
623 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
624 (build-system python-build-system)
627 (modify-phases %standard-phases
630 (invoke "py.test" "-v" "webencodings/tests.py")
633 `(("python-pytest" ,python-pytest)))
634 (home-page "https://github.com/SimonSapin/python-webencodings")
635 (synopsis "Character encoding aliases for legacy web content")
637 "In order to be compatible with legacy web content when interpreting
638 something like @code{Content-Type: text/html; charset=latin1}, tools need
639 to use a particular set of aliases for encoding labels as well as some
640 overriding rules. For example, @code{US-ASCII} and @code{iso-8859-1} on
641 the web are actually aliases for @code{windows-1252}, and a @code{UTF-8}
642 or @code{UTF-16} BOM takes precedence over any other encoding declaration.
643 The WHATWG @url{https://encoding.spec.whatwg.org/,Encoding} standard
644 defines all such details so that implementations do not have to
645 reverse-engineer each other.
647 This module implements the Encoding standard and has encoding labels and
648 BOM detection, but the actual implementation for encoders and decoders
650 (license license:bsd-3)))
652 (define-public python2-webencodings
653 (package-with-python2 python-webencodings))
655 (define-public python-openid
657 (name "python-openid")
662 (uri (pypi-uri "python3-openid" version))
665 "00l5hrjh19740w00b3fnsqldnla41wbr2rics09dl4kyd1fkd3b2"))))
666 (build-system python-build-system)
669 (modify-phases %standard-phases
672 (invoke "coverage" "run" "-m"
673 "unittest" "openid.test.test_suite"))))))
674 (properties `((python2-variant . ,(delay python2-openid))))
676 `(("python-defusedxml" ,python-defusedxml)))
678 `(("python-coverage" ,python-coverage)
679 ("python-psycopg2" ,python-psycopg2)
680 ("python-django" ,python-django)))
681 (home-page "https://github.com/necaris/python3-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)))
687 (define-public python2-openid
689 (name "python2-openid")
694 (uri (pypi-uri "python-openid" version))
697 "1vvhxlghjan01snfdc4k7ykd80vkyjgizwgg9bncnin8rqz1ricj"))))
698 (build-system python-build-system)
700 ;; Python 3 support is in `python3-openid`, a separate package.
702 ;; Tests aren't initialized correctly.
704 (home-page "https://github.com/openid/python-openid")
705 (synopsis "OpenID support for servers and consumers")
706 (description "This library provides OpenID authentication for Python, both
707 for clients and servers.")
708 (license license:asl2.0)))
710 (define-public python-cssutils
712 (name "python-cssutils")
717 (uri (pypi-uri "cssutils" version))
720 "1bxchrbqzapwijap0yhlxdil1w9bmwvgx77aizlkhc2mcxjg1z52"))))
721 (build-system python-build-system)
723 `(("unzip" ,unzip))) ; for unpacking the source
725 `(#:tests? #f)) ; tests require python-pbr < 1.7.0
726 (home-page "http://cthedot.de/cssutils/")
728 "CSS Cascading Style Sheets library for Python")
730 "Cssutils is a Python package for parsing and building CSS
731 Cascading Style Sheets. Currently it provides a DOM only and no rendering
733 (license license:lgpl3+)))
735 (define-public python2-cssutils
736 (package-with-python2 python-cssutils))
738 (define-public python-css-parser
740 (inherit python-cssutils)
741 (name "python-css-parser")
746 (uri (pypi-uri "css-parser" version ".tar.gz"))
749 "0i4xfykiffxzr4f6y0m2ggqvx1rzam6pw6krlr5k6ldf29akbay7"))))
750 (home-page "https://github.com/ebook-utils/css-parser")
751 (synopsis "Fork of cssutils modified for parsing ebooks")
753 "Css-parser is a fork of cssutils 1.0.2, updated and modified for parsing
754 ebooks, due to cssutils not receiving updates as of 1.0.2.")
755 (license license:lgpl3+)))
757 (define-public python2-css-parser
758 (package-with-python2 python-css-parser))
760 (define-public python-cssselect
762 (name "python-cssselect")
767 (uri (pypi-uri "cssselect" version))
770 "1xg6gbva1yswghiycmgincv6ab4bn7hpm720ndbj40h8xycmnfvi"))))
771 (build-system python-build-system)
773 ;; tests fail with message
774 ;; AttributeError: 'module' object has no attribute 'tests'
777 "https://pythonhosted.org/cssselect/")
779 "CSS3 selector parser and translator to XPath 1.0")
781 "Cssselect ia a Python module that parses CSS3 Selectors and translates
782 them to XPath 1.0 expressions. Such expressions can be used in lxml or
783 another XPath engine to find the matching elements in an XML or HTML document.")
784 (license license:bsd-3)))
786 (define-public python2-cssselect
787 (package-with-python2 python-cssselect))
789 (define-public python-openid-cla
791 (name "python-openid-cla")
796 (uri (pypi-uri "python-openid-cla" version))
799 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
800 (build-system python-build-system)
801 (arguments '(#:tests? #f)) ; No tests.
802 (home-page "https://github.com/puiterwijk/python-openid-cla/")
803 (synopsis "Implementation of the OpenID CLA extension for python-openid")
804 (description "@code{openid-cla} is an implementation of the OpenID
805 contributor license agreement extension for python-openid.")
806 (license license:bsd-3)))
808 (define-public python2-openid-cla
809 (package-with-python2 python-openid-cla))
811 (define-public python-openid-teams
813 (name "python-openid-teams")
818 (uri (pypi-uri "python-openid-teams" version))
821 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
822 (build-system python-build-system)
823 (arguments '(#:tests? #f)) ; No tests.
824 (home-page "https://github.com/puiterwijk/python-openid-teams/")
825 (synopsis "Implementation of the OpenID teams extension for python-openid")
827 "@code{openid-teams} is an implementation of the OpenID
828 teams extension for python-openid.")
829 (license license:bsd-3)))
831 (define-public python2-openid-teams
832 (package-with-python2 python-openid-teams))
834 (define-public python-tornado
836 (name "python-tornado")
841 (uri (pypi-uri "tornado" version))
844 "02clqk2116jbnq8lnaqmdw3p52nqrd9ib59r4xz2ll43fpcmhlaf"))))
845 (build-system python-build-system)
847 '(;; FIXME: Two tests error out with:
848 ;; AssertionError: b'Error in atexit._run_exitfuncs:\nFileNotF[44 chars]ry\n' != b''
850 ;; (modify-phases %standard-phases
853 ;; ;; 'setup.py test' hits an AssertionError on BSD-specific
854 ;; ;; "tornado/platform/kqueue.py". This is the supported method:
855 ;; (invoke "python" "-m" "tornado.test.runtests")
859 `(("python-certifi" ,python-certifi)))
860 (home-page "https://www.tornadoweb.org/")
861 (synopsis "Python web framework and asynchronous networking library")
863 "Tornado is a Python web framework and asynchronous networking library,
864 originally developed at FriendFeed. By using non-blocking network I/O,
865 Tornado can scale to tens of thousands of open connections, making it ideal
866 for long polling, WebSockets, and other applications that require a long-lived
867 connection to each user.")
868 (license license:asl2.0)
869 (properties `((python2-variant . ,(delay python2-tornado))))))
871 (define-public python2-tornado
872 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
873 (package (inherit tornado)
875 `(("python2-backport-ssl-match-hostname"
876 ,python2-backport-ssl-match-hostname)
877 ("python2-backports-abc" ,python2-backports-abc)
878 ("python2-singledispatch" ,python2-singledispatch)
879 ,@(package-propagated-inputs tornado))))))
881 (define-public python-tornado-http-auth
883 (name "python-tornado-http-auth")
888 (uri (pypi-uri "tornado-http-auth" version))
890 (base32 "0hyc5f0a09i5yb99pk4bxpg6w9ichbrb5cv7hc9hff7rxd8w0v0x"))))
891 (build-system python-build-system)
893 `(("python-tornado" ,python-tornado)))
894 (home-page "https://github.com/gvalkov/tornado-http-auth")
895 (synopsis "Digest and basic authentication module for Tornado")
897 "Provides support for adding authentication to services using the Tornado
898 web framework, either via the basic or digest authentication schemes.")
899 (license license:asl2.0)))
901 (define-public python-terminado
903 (name "python-terminado")
908 (uri (pypi-uri "terminado" version))
911 "0yh69k6579g848rmjyllb5h75pkvgcy27r1l3yzgkf33wnnzkasm"))))
912 (build-system python-build-system)
914 `(("python-tornado" ,python-tornado)
915 ("python-ptyprocess" ,python-ptyprocess)))
917 `(("python-nose" ,python-nose)))
920 (modify-phases %standard-phases
922 (lambda _ (invoke "nosetests") #t)))))
923 (home-page "https://github.com/takluyver/terminado")
924 (synopsis "Terminals served to term.js using Tornado websockets")
925 (description "This package provides a Tornado websocket backend for the
926 term.js Javascript terminal emulator library.")
927 (license license:bsd-2)
928 (properties `((python2-variant . ,(delay python2-terminado))))))
930 (define-public python2-terminado
931 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
932 (package (inherit terminado)
934 `(("python2-backport-ssl-match-hostname"
935 ,python2-backport-ssl-match-hostname)
936 ("python2-futures" ,python2-futures)
937 ,@(package-propagated-inputs terminado))))))
939 (define-public python-wsgi-intercept
941 (name "python-wsgi-intercept")
945 (uri (pypi-uri "wsgi_intercept" version))
948 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
949 (build-system python-build-system)
951 `(("python-six" ,python-six)))
953 `(("python-pytest" ,python-pytest)
954 ("python-httplib2" ,python-httplib2)
955 ("python-requests" ,python-requests)
956 ("python-urllib3" ,python-urllib3)))
957 (synopsis "Puts a WSGI application in place of a real URI for testing")
958 (description "Wsgi_intercept installs a WSGI application in place of a real
959 URI for testing. Testing a WSGI application normally involves starting a
960 server at a local host and port, then pointing your test code to that address.
961 Instead, this library lets you intercept calls to any specific host/port
962 combination and redirect them into a WSGI application importable by your test
963 program. Thus, you can avoid spawning multiple processes or threads to test
965 (home-page "https://github.com/cdent/wsgi-intercept")
966 (license license:expat)))
968 (define-public python-webob
970 (name "python-webob")
975 (uri (pypi-uri "WebOb" version))
978 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
979 (build-system python-build-system)
981 `(("python-nose" ,python-nose)))
982 (home-page "https://webob.org/")
983 (synopsis "WSGI request and response object")
985 "WebOb provides wrappers around the WSGI request environment, and an
986 object to help create WSGI responses.")
987 (license license:expat)))
989 (define-public python2-webob
990 (package-with-python2 python-webob))
992 (define-public python-zope-event
994 (name "python-zope-event")
999 (uri (pypi-uri "zope.event" version))
1002 "1ksbc726av9xacml6jhcfyn828hlhb9xlddpx6fcvnlvmpmpvhk9"))))
1003 (build-system python-build-system)
1004 (home-page "https://pypi.org/project/zope.event/")
1005 (synopsis "Event publishing system for Python")
1006 (description "Zope.event provides an event publishing API, intended for
1007 use by applications which are unaware of any subscribers to their events. It
1008 is a simple event-dispatching system on which more sophisticated event
1009 dispatching systems can be built.")
1010 (license license:zpl2.1)))
1012 (define-public python2-zope-event
1013 (package-with-python2 python-zope-event))
1015 (define-public python-zope-interface
1017 (name "python-zope-interface")
1022 (uri (pypi-uri "zope.interface" version))
1025 "0r9kvb1q3lxrdhxabliv9nwhjsdmn1n0vcjv93rlqkyb7yyh24gx"))))
1026 (build-system python-build-system)
1028 `(("python-zope-event" ,python-zope-event)))
1029 (home-page "https://github.com/zopefoundation/zope.interface")
1030 (synopsis "Python implementation of the \"design by contract\"
1032 (description "Zope.interface provides an implementation of \"object
1033 interfaces\" for Python. Interfaces are a mechanism for labeling objects as
1034 conforming to a given API or contract.")
1035 (license license:zpl2.1)))
1037 (define-public python2-zope-interface
1038 (package-with-python2 python-zope-interface))
1040 (define-public python-zope-exceptions
1042 (name "python-zope-exceptions")
1047 (uri (pypi-uri "zope.exceptions" version))
1050 "04bjskwas17yscl8bs3l44maxspw1gdji0zcmr499fs420y9r9az"))))
1051 (build-system python-build-system)
1053 '(#:tests? #f)) ; circular dependency with zope.testrunner
1055 `(("python-zope-interface" ,python-zope-interface)))
1056 (home-page "https://pypi.org/project/zope.exceptions/")
1057 (synopsis "Zope exceptions")
1058 (description "Zope.exceptions provides general-purpose exception types
1059 that have uses outside of the Zope framework.")
1060 (license license:zpl2.1)))
1062 (define-public python2-zope-exceptions
1063 (package-with-python2 python-zope-exceptions))
1065 (define-public python-zope-testing
1067 (name "python-zope-testing")
1072 (uri (pypi-uri "zope.testing" version))
1075 "1sh3c3i0m8n8fnhqiry0bk3rr356i56ry7calmn57s1pvv8yhsyn"))))
1076 (build-system python-build-system)
1077 (home-page "https://pypi.org/project/zope.testing/")
1078 (synopsis "Zope testing helpers")
1079 (description "Zope.testing provides a number of testing utilities for HTML
1080 forms, HTTP servers, regular expressions, and more.")
1081 (license license:zpl2.1)))
1083 (define-public python2-zope-testing
1084 (package-with-python2 python-zope-testing))
1086 (define-public python-zope-testrunner
1088 (name "python-zope-testrunner")
1093 (uri (pypi-uri "zope.testrunner" version))
1096 "0w3q66cy4crpj7c0hw0vvvvwf3g931rnvw7wwa20av7yqvv6ajim"))))
1097 (build-system python-build-system)
1099 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1101 `(("python-zope-testing" ,python-zope-testing)))
1103 `(("python-six" ,python-six)
1104 ("python-zope-exceptions" ,python-zope-exceptions)
1105 ("python-zope-interface" ,python-zope-interface)))
1106 (home-page "https://pypi.org/project/zope.testrunner/")
1107 (synopsis "Zope testrunner script")
1108 (description "Zope.testrunner provides a script for running Python
1110 (license license:zpl2.1)))
1112 (define-public python2-zope-testrunner
1113 (package-with-python2 python-zope-testrunner))
1115 (define-public python-zope-i18nmessageid
1117 (name "python-zope-i18nmessageid")
1122 (uri (pypi-uri "zope.i18nmessageid" version))
1125 "0ndhn4w1qgwkfbwf9vm2bgq418z5g0wmfsgl0d9nz62cd0mi8d4m"))))
1126 (build-system python-build-system)
1128 `(("python-coverage" ,python-coverage)
1129 ("python-zope-testrunner" ,python-zope-testrunner)))
1131 `(("python-six" ,python-six)))
1132 (home-page "https://pypi.org/project/zope.i18nmessageid/")
1133 (synopsis "Message identifiers for internationalization")
1134 (description "Zope.i18nmessageid provides facilities for declaring
1135 internationalized messages within program source text.")
1136 (license license:zpl2.1)))
1138 (define-public python2-zope-i18nmessageid
1139 (package-with-python2 python-zope-i18nmessageid))
1141 (define-public python-zope-schema
1143 (name "python-zope-schema")
1148 (uri (pypi-uri "zope.schema" version))
1151 "0q93j0x52a42khw12al90jw2bk0wly3jwghql3a25zpwwxvn24ya"))))
1152 (build-system python-build-system)
1154 '(#:tests? #f)) ; FIXME: Tests can't find zope.event.
1156 `(("python-zope-event" ,python-zope-event)
1157 ("python-zope-interface" ,python-zope-interface)))
1159 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1160 ("python-zope-testing" ,python-zope-testing)
1161 ("python-zope-testrunner" ,python-zope-testrunner)))
1162 (home-page "https://pypi.org/project/zope.schema/")
1163 (synopsis "Zope data schemas")
1164 (description "Zope.scheme provides extensions to zope.interface for
1165 defining data schemas.")
1166 (license license:zpl2.1)))
1168 (define-public python2-zope-schema
1169 (package-with-python2 python-zope-schema))
1171 (define-public python-zope-configuration
1173 (name "python-zope-configuration")
1177 (uri (pypi-uri "zope.configuration" version))
1180 "1qb88764fd7nkkmqv7fl9bxd1jirynkg5vbqkpqdiffnkxzp85kf"))))
1181 (build-system python-build-system)
1183 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1185 `(("python-zope-testing" ,python-zope-testing)
1186 ("python-zope-testrunner" ,python-zope-testrunner)))
1188 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1189 ("python-zope-interface" ,python-zope-interface)
1190 ("python-zope-schema" ,python-zope-schema)))
1191 (home-page "https://pypi.org/project/zope.configuration/")
1192 (synopsis "Zope Configuration Markup Language")
1193 (description "Zope.configuration implements ZCML, the Zope Configuration
1195 (license license:zpl2.1)))
1197 (define-public python2-zope-configuration
1198 (package-with-python2 python-zope-configuration))
1200 (define-public python-zope-proxy
1202 (name "python-zope-proxy")
1207 (uri (pypi-uri "zope.proxy" version))
1210 "1g0rcfnbchpvqhm76aixqlz544dawrgmy8gw9zwmijhk6wfl9f26"))))
1211 (build-system python-build-system)
1213 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1215 `(("python-zope-testrunner" ,python-zope-testrunner)))
1217 `(("python-zope-interface" ,python-zope-interface)))
1218 (home-page "https://pypi.org/project/zope.proxy/")
1219 (synopsis "Generic, transparent proxies")
1220 (description "Zope.proxy provides generic, transparent proxies for Python.
1221 Proxies are special objects which serve as mostly-transparent wrappers around
1222 another object, intervening in the apparent behavior of the wrapped object
1223 only when necessary to apply the policy (e.g., access checking, location
1224 brokering, etc.) for which the proxy is responsible.")
1225 (license license:zpl2.1)))
1227 (define-public python2-zope-proxy
1228 (package-with-python2 python-zope-proxy))
1230 (define-public python-zope-location
1232 (name "python-zope-location")
1237 (uri (pypi-uri "zope.location" version))
1240 "1b40pzl8v00d583d3gsxv1qjdw2dhghlgkbgxl3m07d5r3izj857"))))
1241 (build-system python-build-system)
1243 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1245 `(("python-zope-testrunner" ,python-zope-testrunner)))
1247 `(("python-zope-interface" ,python-zope-interface)
1248 ("python-zope-proxy" ,python-zope-proxy)
1249 ("python-zope-schema" ,python-zope-schema)))
1250 (home-page "https://pypi.org/project/zope.location/")
1251 (synopsis "Zope location library")
1252 (description "Zope.location implements the concept of \"locations\" in
1253 Zope3, which are are special objects that have a structural location.")
1254 (license license:zpl2.1)))
1256 (define-public python2-zope-location
1257 (package-with-python2 python-zope-location))
1259 (define-public python-zope-security
1261 (name "python-zope-security")
1266 (uri (pypi-uri "zope.security" version))
1269 "1npfrgnm202v48wavpwn3450dsn7az12lfww95vbhxyjl11f14yb"))))
1270 (build-system python-build-system)
1272 '(#:tests? #f)) ; FIXME: Tests can't find zope.testrunner.
1274 `(("python-zope-component" ,python-zope-component)
1275 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1276 ("python-zope-interface" ,python-zope-interface)
1277 ("python-zope-location" ,python-zope-location)
1278 ("python-zope-proxy" ,python-zope-proxy)
1279 ("python-zope-schema" ,python-zope-schema)))
1281 `(("python-zope-configuration" ,python-zope-configuration)
1282 ("python-zope-testrunner" ,python-zope-testrunner)
1283 ("python-zope-testing" ,python-zope-testing)))
1284 (home-page "https://pypi.org/project/zope.security/")
1285 (synopsis "Zope security framework")
1286 (description "Zope.security provides a generic mechanism to implement
1287 security policies on Python objects.")
1288 (license license:zpl2.1)))
1290 (define-public python2-zope-security
1291 (package-with-python2 python-zope-security))
1293 (define-public python-zope-component
1295 (name "python-zope-component")
1300 (uri (pypi-uri "zope.component" version))
1303 "1hlvzwj1kcfz1qms1dzhwsshpsf38z9clmyksb1gh41n8k3kchdv"))))
1304 (build-system python-build-system)
1306 ;; Skip tests due to circular dependency with python-zope-security.
1309 `(("python-zope-testing" ,python-zope-testing)))
1311 `(("python-zope-event" ,python-zope-event)
1312 ("python-zope-interface" ,python-zope-interface)
1313 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1314 ("python-zope-configuration" ,python-zope-configuration)))
1315 (home-page "https://github.com/zopefoundation/zope.component")
1316 (synopsis "Zope Component Architecture")
1317 (description "Zope.component represents the core of the Zope Component
1318 Architecture. Together with the zope.interface package, it provides
1319 facilities for defining, registering and looking up components.")
1320 (license license:zpl2.1)))
1322 (define-public python2-zope-component
1323 (package-with-python2 python-zope-component))
1325 (define-public python-ndg-httpsclient
1327 (name "python-ndg-httpsclient")
1331 (uri (pypi-uri "ndg_httpsclient" version))
1334 "0412b7i1s4vj7lz9r72nmb28h9syd4q2x89bdirkkc3a6z8awbyp"))))
1335 (build-system python-build-system)
1337 '(;; The tests appear to require networking.
1340 `(("python-pyopenssl" ,python-pyopenssl)))
1341 (synopsis "HTTPS support for Python's httplib and urllib2")
1342 (description "This is a HTTPS client implementation for httplib and urllib2
1343 based on PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation
1344 over the default provided with Python and, importantly, enables full
1345 verification of the SSL peer.")
1346 (home-page "https://github.com/cedadev/ndg_httpsclient/")
1347 (license license:bsd-3)))
1349 ;; python2-openssl requires special care, so package-with-python2 is
1351 (define-public python2-ndg-httpsclient
1352 (package (inherit python-ndg-httpsclient)
1353 (name "python2-ndg-httpsclient")
1355 (substitute-keyword-arguments (package-arguments python-ndg-httpsclient)
1356 ((#:python _) python-2)))
1358 `(("python2-pyopenssl" ,python2-pyopenssl)))))
1360 (define-public python-websocket-client
1362 (name "python-websocket-client")
1367 (uri (pypi-uri "websocket_client" version))
1370 "0j88zmikaypf38lvpkf4aaxrjp9j07dmy5ghj7kli0fv3p4n45g5"))))
1371 (build-system python-build-system)
1373 `(("python-six" ,python-six)))
1374 (home-page "https://github.com/liris/websocket-client")
1375 (synopsis "WebSocket client for Python")
1376 (description "The Websocket-client module provides the low level APIs for
1377 WebSocket usage in Python programs.")
1378 (properties `((python2-variant . ,(delay python2-websocket-client))))
1379 (license license:lgpl2.1+)))
1381 (define-public python2-websocket-client
1382 (let ((base (package-with-python2
1383 (strip-python2-variant python-websocket-client))))
1387 `(("python2-backport-ssl-match-hostname"
1388 ,python2-backport-ssl-match-hostname)
1389 ,@(package-native-inputs base))))))
1391 (define-public python-requests
1393 (name "python-requests")
1397 (uri (pypi-uri "requests" version))
1400 "1d5ybh11jr5sm7xp6mz8fyc7vrp4syifds91m7sj60xalal0gq0i"))))
1401 (build-system python-build-system)
1403 `(("python-certifi" ,python-certifi)
1404 ("python-chardet" ,python-chardet)
1405 ("python-idna" ,python-idna)
1406 ("python-urllib3" ,python-urllib3)))
1408 ;; FIXME: Some tests require network access.
1410 (home-page "http://python-requests.org/")
1411 (synopsis "Python HTTP library")
1413 "Requests is a Python HTTP client library. It aims to be easier to use
1414 than Python’s urllib2 library.")
1415 (license license:asl2.0)))
1417 ;; Some software requires an older version of Requests, notably Docker/Docker
1419 (define-public python-requests-2.20
1420 (package (inherit python-requests)
1424 (uri (pypi-uri "requests" version))
1427 "0qzj6cgv3k9wyj7wlxgz7xq0cfg4jbbkfm24pp8dnhczwl31527a"))))
1429 `(("python-urllib3" ,python-urllib3-1.24)
1430 ("python-idna" ,python-idna-2.7)
1431 ,@(package-propagated-inputs python-requests)))))
1433 ;; Some software requires an older version of Requests, notably Docker
1435 (define-public python-requests-2.7
1436 (package (inherit python-requests)
1440 (uri (pypi-uri "requests" version))
1443 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
1445 (define-public python2-requests
1446 (package-with-python2 python-requests))
1448 (define-public python-requests_ntlm
1450 (name "python-requests_ntlm")
1455 (uri (pypi-uri "requests_ntlm" version))
1458 "0wgbqzaq9w7bas16b7brdb75f91bh3275fb459093bk1ihpck2ci"))))
1459 (build-system python-build-system)
1461 `(("python-cryptography" ,python-cryptography)
1462 ("python-ntlm-auth" ,python-ntlm-auth)
1463 ("python-requests" ,python-requests)))
1464 (home-page "https://github.com/requests/requests-ntlm")
1466 "NTLM authentication support for Requests")
1468 "This package allows for HTTP NTLM authentication using the requests
1470 (license license:isc)))
1472 (define-public python-requests-mock
1474 (name "python-requests-mock")
1479 (uri (pypi-uri "requests-mock" version))
1482 "0jr997dvk6zbmhvbpcv3rajrgag69mcsm1ai3w3rgk2jdh6rg1mx"))))
1483 (build-system python-build-system)
1485 `(("python-requests" ,python-requests)
1486 ("python-six" ,python-six)))
1488 `(("python-pbr" ,python-pbr)
1489 ("python-discover" ,python-discover)
1490 ("python-docutils" ,python-docutils)
1491 ("python-fixtures" ,python-fixtures)
1492 ("python-mock" ,python-mock)
1493 ("python-sphinx" ,python-sphinx)
1494 ("python-testrepository" ,python-testrepository)
1495 ("python-testtools" ,python-testtools)))
1496 (home-page "https://requests-mock.readthedocs.org/")
1497 (synopsis "Mock out responses from the requests package")
1499 "This module provides a building block to stub out the HTTP requests
1500 portions of your testing code.")
1501 (properties `((python2-variant . ,(delay python2-requests-mock))))
1502 (license license:asl2.0)))
1504 (define-public python2-requests-mock
1505 (package (inherit (package-with-python2
1506 (strip-python2-variant python-requests-mock)))
1508 `(#:python ,python-2
1509 ;; FIXME: 'subunit.run discover: error: no such option: --list'
1512 (define-public python-requests-toolbelt
1514 (name "python-requests-toolbelt")
1518 (uri (pypi-uri "requests-toolbelt" version))
1521 "1dc7l42i4080r8i4m9fj51jx367lqkai170vrv7wd93gdj9k39gn"))))
1522 (build-system python-build-system)
1524 `(("python-betamax" ,python-betamax)
1525 ("python-mock" ,python-mock)
1526 ("python-pytest" ,python-pytest)))
1528 `(("python-requests" ,python-requests)))
1529 (synopsis "Extensions to python-requests")
1530 (description "This is a toolbelt of useful classes and functions to be used
1531 with python-requests.")
1532 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
1533 (license license:asl2.0)))
1535 (define-public python2-requests-toolbelt
1536 (package-with-python2 python-requests-toolbelt))
1538 (define-public python-oauthlib
1540 (name "python-oauthlib")
1544 (uri (pypi-uri "oauthlib" version))
1547 "163jg4a8f7c5ki655grrr47kgljy12wri3qly7ijf64sk1fjrqqc"))))
1548 (build-system python-build-system)
1550 `(#:phases (modify-phases %standard-phases
1553 (invoke "pytest" "-vv"))))))
1555 `(("python-pytest" ,python-pytest)
1556 ("python-pytest-cov" ,python-pytest-cov)
1557 ("python-mock" ,python-mock)))
1559 `(("python-cryptography" ,python-cryptography)
1560 ("python-pyjwt" ,python-pyjwt)
1561 ("python-blinker" ,python-blinker)))
1562 (home-page "https://github.com/oauthlib/oauthlib")
1563 (synopsis "OAuth implementation for Python")
1565 "Oauthlib is a generic, spec-compliant, thorough implementation of the
1566 OAuth request-signing logic.")
1567 (license license:bsd-3)))
1569 (define-public python2-oauthlib
1570 (package-with-python2 python-oauthlib))
1572 (define-public python-rauth
1574 (name "python-rauth")
1579 (uri (pypi-uri "rauth" version))
1582 "02kv8w8l98ky223avyq7vw7x1f2ya9chrm59r77ylq45qb0xnk2j"))))
1583 (build-system python-build-system)
1585 `(#:test-target "check"))
1587 `(("python-requests" ,python-requests)))
1588 (home-page "https://github.com/litl/rauth")
1589 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
1591 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
1592 provides service wrappers for convenient connection initialization and
1593 authenticated session objects providing things like keep-alive.")
1594 (license license:expat)
1595 (properties `((python2-variant . ,(delay python2-rauth))))))
1597 (define-public python2-rauth
1598 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
1601 (native-inputs `(("python2-unittest2" ,python2-unittest2)
1602 ,@(package-native-inputs base))))))
1604 (define-public python-urllib3
1606 (name "python-urllib3")
1611 (uri (pypi-uri "urllib3" version))
1614 "0cij8qcvvpj62g1q8n785qjkdymfh4b7vf45si4sw64l41rr3rfv"))))
1615 (build-system python-build-system)
1616 (arguments `(#:tests? #f))
1618 `(;; These 5 inputs are used to build urrlib3[secure]
1619 ("python-certifi" ,python-certifi)
1620 ("python-cryptography" ,python-cryptography)
1621 ("python-idna" ,python-idna)
1622 ("python-ipaddress" ,python-ipaddress)
1623 ("python-pyopenssl" ,python-pyopenssl)
1624 ("python-pysocks" ,python-pysocks)))
1625 (home-page "https://urllib3.readthedocs.io/")
1626 (synopsis "HTTP library with thread-safe connection pooling")
1628 "Urllib3 supports features left out of urllib and urllib2 libraries. It
1629 can reuse the same socket connection for multiple requests, it can POST files,
1630 supports url redirection and retries, and also gzip and deflate decoding.")
1631 (license license:expat)))
1633 ;; Some software requires an older version of urllib3, notably Docker.
1634 (define-public python-urllib3-1.24
1635 (package (inherit python-urllib3)
1639 (uri (pypi-uri "urllib3" version))
1642 "1x0slqrv6kixkbcdnxbglvjliwhc1payavxjvk8fvbqjrnasd4r3"))))))
1645 (define-public python2-urllib3
1646 (package-with-python2 python-urllib3))
1648 (define-public awscli
1655 (uri (pypi-uri name version))
1658 "0p479mfs9r0m82a217pap8156ijwvhv6r3kqa4k267gd05wgvygm"))))
1659 (build-system python-build-system)
1661 ;; FIXME: The 'pypi' release does not contain tests.
1664 (modify-phases %standard-phases
1665 (add-after 'unpack 'fix-reference-to-groff
1667 (substitute* "awscli/help.py"
1668 (("if not self._exists_on_path\\('groff'\\):") "")
1669 (("raise ExecutableNotFoundError\\('groff'\\)") "")
1670 (("cmdline = \\['groff'")
1671 (string-append "cmdline = ['" (which "groff") "'")))
1674 `(("python-colorama" ,python-colorama)
1675 ("python-botocore" ,python-botocore)
1676 ("python-s3transfer" ,python-s3transfer)
1677 ("python-docutils" ,python-docutils)
1678 ("python-pyyaml" ,python-pyyaml)
1679 ("python-rsa" ,python-rsa)))
1681 `(("groff" ,groff)))
1682 (home-page "https://aws.amazon.com/cli/")
1683 (synopsis "Command line client for AWS")
1684 (description "AWS CLI provides a unified command line interface to the
1685 Amazon Web Services (AWS) API.")
1686 (license license:asl2.0)))
1688 (define-public python-wsgiproxy2
1690 (name "python-wsgiproxy2")
1695 (uri (pypi-uri "WSGIProxy2" version ".tar.gz"))
1697 (base32 "16jch5nic0hia28lps3c678s9s9mjdq8n87igxncjg0rpi5adqnf"))))
1698 (build-system python-build-system)
1700 `(("python-webtest" ,python-webtest)))
1702 `(("python-requests" ,python-requests)
1703 ("python-six" ,python-six)
1704 ("python-urllib3" ,python-urllib3)
1705 ("python-webob" ,python-webob)))
1706 (home-page "https://github.com/gawel/WSGIProxy2/")
1707 (synopsis "WSGI Proxy with various http client backends")
1708 (description "WSGI turns HTTP requests into WSGI function calls.
1709 WSGIProxy turns WSGI function calls into HTTP requests.
1710 It also includes code to sign requests and pass private data,
1711 and to spawn subprocesses to handle requests.")
1712 (license license:expat)))
1714 (define-public python2-wsgiproxy2
1715 (package-with-python2 python-wsgiproxy2))
1717 (define-public python-pastedeploy
1719 (name "python-pastedeploy")
1724 (uri (pypi-uri "PasteDeploy" version))
1727 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
1728 (build-system python-build-system)
1730 `(("python-nose" ,python-nose)))
1731 (home-page "https://pylonsproject.org/")
1733 "Load, configure, and compose WSGI applications and servers")
1735 "This tool provides code to load WSGI applications and servers from URIs;
1736 these URIs can refer to Python Eggs for INI-style configuration files. Paste
1737 Script provides commands to serve applications based on this configuration
1739 (license license:expat)))
1741 (define-public python2-pastedeploy
1742 (package-with-python2 python-pastedeploy))
1744 (define-public python-webtest
1746 (name "python-webtest")
1751 (uri (pypi-uri "WebTest" version))
1754 "1l3z0cwqslsf4rcrhi2gr8kdfh74wn2dw76376i4g9i38gz8wd21"))))
1755 (build-system python-build-system)
1757 ;; Tests require python-pyquery, which creates a circular dependency.
1760 `(("python-waitress" ,python-waitress)
1761 ("python-webob" ,python-webob)
1762 ("python-six" ,python-six)
1763 ("python-beautifulsoup4" ,python-beautifulsoup4)))
1764 (home-page "https://docs.pylonsproject.org/projects/webtest/")
1765 (synopsis "Helper to test WSGI applications")
1766 (description "Webtest allows you to test your Python web applications
1767 without starting an HTTP server. It supports anything that supports the
1769 (license license:expat)))
1771 (define-public python2-webtest
1772 (package-with-python2 python-webtest))
1774 (define-public python-flask
1776 (name "python-flask")
1780 (uri (pypi-uri "Flask" version))
1783 "0q3h295izcil7lswkzfnyg3k5gq4hpmqmpl6i7s5m1n9szi1myjf"))))
1784 (build-system python-build-system)
1787 (modify-phases %standard-phases
1790 (setenv "PYTHONPATH" (string-append "./build/lib:"
1791 (getenv "PYTHONPATH")))
1792 (invoke "pytest" "-vv" "tests"))))))
1794 `(("python-pytest" ,python-pytest)))
1796 `(("python-itsdangerous" ,python-itsdangerous)
1797 ("python-jinja2" ,python-jinja2)
1798 ("python-click" ,python-click)
1799 ("python-werkzeug" ,python-werkzeug)))
1800 (home-page "https://www.palletsprojects.com/p/flask/")
1801 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
1802 (description "Flask is a micro web framework based on the Werkzeug toolkit
1803 and Jinja2 template engine. It is called a micro framework because it does not
1804 presume or force a developer to use a particular tool or library.")
1805 (license license:bsd-3)))
1807 (define-public python2-flask
1808 (package-with-python2 python-flask))
1810 (define-public python-flask-wtf
1812 (name "python-flask-wtf")
1817 (uri (pypi-uri "Flask-WTF" version))
1820 "086pvg2x69n0nczcq7frknfjd8am1zdy8qqpva1sanwb02hf65yl"))))
1821 (build-system python-build-system)
1824 (modify-phases %standard-phases
1827 (setenv "PYTHONPATH" (string-append "./build/lib:"
1828 (getenv "PYTHONPATH")))
1829 (invoke "pytest" "-vv"))))))
1831 `(("python-flask-babel" ,python-flask-babel)
1832 ("python-babel" ,python-babel)
1833 ("python-wtforms" ,python-wtforms)))
1835 `(("python-pytest" ,python-pytest)))
1836 (home-page "https://github.com/lepture/flask-wtf")
1837 (synopsis "Simple integration of Flask and WTForms")
1838 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
1839 upload, and reCAPTCHA.")
1840 (license license:bsd-3)))
1842 (define-public python2-flask-wtf
1843 (package-with-python2 python-flask-wtf))
1845 (define-public python-flask-multistatic
1847 (name "python-flask-multistatic")
1852 (uri (pypi-uri "flask-multistatic" version))
1855 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
1856 (build-system python-build-system)
1858 `(("python-flask" ,python-flask)))
1859 (home-page "https://pagure.io/flask-multistatic")
1860 (synopsis "Flask plugin to allow overriding static files")
1861 (description "@code{flask-multistatic} is a flask plugin that adds support
1862 for overriding static files.")
1863 (license license:gpl3+)))
1865 (define-public python2-flask-multistatic
1866 (package-with-python2 python-flask-multistatic))
1868 (define-public python-cookies
1870 (name "python-cookies")
1874 (uri (pypi-uri "cookies" version))
1877 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
1878 (build-system python-build-system)
1880 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
1883 `(("python-pytest" ,python-pytest)))
1884 (synopsis "HTTP cookie parser and renderer")
1885 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
1887 (home-page "https://gitlab.com/sashahart/cookies")
1888 (license license:expat)))
1890 (define-public python2-cookies
1891 (package-with-python2 python-cookies))
1893 (define-public python-responses
1895 (name "python-responses")
1899 (uri (pypi-uri "responses" version))
1902 "147pacwkkqy3qf3hr33fnl1xbzgw0zsm3qppvvy9qhq8h069qbah"))))
1903 (build-system python-build-system)
1905 `(;; Test suite is not distributed:
1906 ;; https://github.com/getsentry/responses/issues/38
1909 `(("python-mock" ,python-mock)))
1911 `(("python-requests" ,python-requests)
1912 ("python-cookies" ,python-cookies)
1913 ("python-six" ,python-six)))
1914 (home-page "https://github.com/getsentry/responses")
1915 (synopsis "Utility for mocking out the `requests` Python library")
1916 (description "A utility library for mocking out the `requests` Python
1918 (license license:asl2.0)))
1920 (define-public python2-responses
1921 (package-with-python2 python-responses))
1923 (define-public python-grequests
1925 (name "python-grequests")
1930 (uri (pypi-uri "grequests" version))
1933 "1j9icncllbkv7x5719b20mx670c6q1jrdx1sakskkarvx3pc8h8g"))))
1934 (build-system python-build-system)
1936 `(("python-gevent" ,python-gevent)
1937 ("python-requests" ,python-requests)))
1939 `(("python-nose" ,python-nose)))
1940 (home-page "https://github.com/kennethreitz/grequests")
1941 (synopsis "Python library for asynchronous HTTP requests")
1942 (description "GRequests is a Python library that allows you to use
1943 @code{Requests} with @code{Gevent} to make asynchronous HTTP Requests easily")
1944 (license license:bsd-2)))
1946 (define-public python-geventhttpclient
1948 (name "python-geventhttpclient")
1952 (uri (pypi-uri "geventhttpclient" version))
1955 "07d0q3wzmml75227r6y6mrl5a0zpf4v9gj0ni5rhbyzmaj4az1xx"))
1956 (modules '((guix build utils)))
1959 ;; Delete pre-compiled files.
1960 (for-each delete-file (find-files "src/geventhttpclient"
1963 (build-system python-build-system)
1966 (modify-phases %standard-phases
1967 (add-after 'unpack 'delete-network-tests
1969 (delete-file "src/geventhttpclient/tests/test_client.py")
1972 (add-after 'install 'check
1973 (lambda* (#:key inputs outputs #:allow-other-keys)
1974 (add-installed-pythonpath inputs outputs)
1975 (invoke "py.test" "src/geventhttpclient/tests" "-v"
1976 ;; Append the test modules to sys.path to avoid
1977 ;; namespace conflict which breaks SSL tests.
1978 "--import-mode=append")
1981 `(("python-pytest" ,python-pytest)))
1983 `(("python-certifi" ,python-certifi)
1984 ("python-gevent" ,python-gevent)
1985 ("python-six" ,python-six)))
1986 (home-page "https://github.com/gwik/geventhttpclient")
1987 (synopsis "HTTP client library for gevent")
1988 (description "@code{python-geventhttpclient} is a high performance,
1989 concurrent HTTP client library for python using @code{gevent}.")
1990 (license license:expat)))
1992 (define-public python2-geventhttpclient
1993 (package-with-python2 python-geventhttpclient))
1995 (define-public python-requests-oauthlib
1997 (name "python-requests-oauthlib")
2002 (uri (pypi-uri "requests-oauthlib" version))
2005 "0mrglgcvq7k48pf27s4gifdk0za8xmgpf55jy15yjj471qrk6rdx"))))
2006 (build-system python-build-system)
2009 (modify-phases %standard-phases
2010 ;; removes tests that require network access
2011 (add-before 'check 'pre-check
2013 (delete-file "tests/test_core.py")
2016 `(("python-pyjwt" ,python-pyjwt)
2017 ("python-requests-mock" ,python-requests-mock)
2018 ("python-mock" ,python-mock)))
2020 `(("python-oauthlib" ,python-oauthlib)
2021 ("python-requests" ,python-requests)))
2023 "https://github.com/requests/requests-oauthlib")
2025 "OAuthlib authentication support for Requests")
2027 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
2028 provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
2029 (license license:isc)))
2031 (define-public python2-requests-oauthlib
2032 (package-with-python2 python-requests-oauthlib))
2034 (define-public python-url
2040 (uri (pypi-uri "url" version))
2043 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
2044 (build-system python-build-system)
2046 `(("python-publicsuffix" ,python-publicsuffix)))
2048 `(("python-coverage" ,python-coverage)
2049 ("python-nose" ,python-nose)))
2051 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
2052 (home-page "https://github.com/seomoz/url-py")
2053 (synopsis "URL Parsing")
2054 (description "Library for parsing urls.")
2055 (license license:expat)
2056 (properties `((python2-variant . ,(delay python2-url))))))
2058 (define-public python2-url
2059 (let ((base (package-with-python2 (strip-python2-variant python-url))))
2060 (package (inherit base)
2062 `(("python2-publicsuffix" ,python2-publicsuffix))))))
2064 (define-public python-cachecontrol
2066 (name "python-cachecontrol")
2071 ;; Pypi does not have tests.
2073 (url "https://github.com/ionrock/cachecontrol")
2074 (commit (string-append "v" version))))
2075 (file-name (git-file-name name version))
2078 "03lgc65sl04n0cgzmmgg99bk83f9i6k8yrmcd4hpl46q1pymn0kz"))))
2079 (build-system python-build-system)
2081 ;; Versions > 0.11.6 depend on CherryPy for testing.
2082 ;; It's too much work to package CherryPy for now.
2085 `(("python-requests" ,python-requests)
2086 ("python-msgpack" ,python-msgpack)
2087 ("python-lockfile" ,python-lockfile)))
2088 (home-page "https://github.com/ionrock/cachecontrol")
2089 (synopsis "The httplib2 caching algorithms for use with requests")
2090 (description "CacheControl is a port of the caching algorithms in
2091 @code{httplib2} for use with @code{requests} session objects.")
2092 (license license:asl2.0)))
2094 (define-public python2-cachecontrol
2095 (package-with-python2 python-cachecontrol))
2097 (define-public python-betamax
2099 (name "python-betamax")
2104 (uri (pypi-uri "betamax" version))
2107 "1hki1c2vs7adq7zr56wi6i5bhrkia4s2ywpv2c98ibnczz709w2v"))))
2108 (build-system python-build-system)
2110 '(;; Many tests fail because they require networking.
2113 `(("python-requests" ,python-requests)))
2114 (home-page "https://github.com/sigmavirus24/betamax")
2115 (synopsis "Record HTTP interactions with python-requests")
2116 (description "Betamax will record your test suite's HTTP interactions and
2117 replay them during future tests. It is designed to work with python-requests.")
2118 (license license:expat)))
2120 (define-public python2-betamax
2121 (package-with-python2 python-betamax))
2123 (define-public python-betamax-matchers
2125 (name "python-betamax-matchers")
2130 (uri (pypi-uri "betamax-matchers" version))
2133 "07qpwjyq2i2aqhz5iwghnj4pqr2ys5n45v1vmpcfx9r5mhwrsq43"))))
2134 (build-system python-build-system)
2136 `(("python-betamax" ,python-betamax)
2137 ("python-requests-toolbelt" ,python-requests-toolbelt)))
2138 (home-page "https://github.com/sigmavirus24/betamax_matchers")
2139 (synopsis "VCR imitation for python-requests")
2140 (description "@code{betamax-matchers} provides a set of Matchers for
2142 (license license:asl2.0)))
2144 (define-public python2-betamax-matchers
2145 (package-with-python2 python-betamax-matchers))
2147 (define-public python-s3transfer
2149 (name "python-s3transfer")
2153 (uri (pypi-uri "s3transfer" version))
2156 "08fhj73b1ai52hrs2q3nggshq3pswn1gq8ch3m009cb2v2vmqggj"))))
2157 (build-system python-build-system)
2160 (modify-phases %standard-phases
2163 ;; Some of the 'integration' tests require network access or
2164 ;; login credentials.
2165 (invoke "nosetests" "--exclude=integration")
2168 `(("python-docutils" ,python-docutils)
2169 ("python-mock" ,python-mock)
2170 ("python-nose" ,python-nose)))
2172 `(("python-botocore" ,python-botocore)
2173 ("python-urllib3" ,python-urllib3)))
2174 (synopsis "Amazon S3 Transfer Manager")
2175 (description "S3transfer is a Python library for managing Amazon S3
2177 (home-page "https://github.com/boto/s3transfer")
2178 (license license:asl2.0)
2179 (properties `((python2-variant . ,(delay python2-s3transfer))))))
2181 (define-public python2-s3transfer
2182 (let ((base (package-with-python2 (strip-python2-variant python-s3transfer))))
2186 `(("python2-futures" ,python2-futures)
2187 ,@(package-native-inputs base))))))
2189 (define-public python-slimit
2191 (name "python-slimit")
2196 (uri (pypi-uri "slimit" version ".zip"))
2199 "02vj2x728rs1127q2nc27frrqra4fczivnb7gch6n5lzi7pxqczl"))))
2200 (build-system python-build-system)
2202 `(("unzip" ,unzip)))
2204 `(("python-ply" ,python-ply)))
2205 (home-page "https://slimit.readthedocs.io/")
2206 (synopsis "JavaScript minifier, parser and lexer written in Python")
2208 "SlimIt is a JavaScript minifier written in Python. It compiles
2209 JavaScript into more compact code so that it downloads and runs faster.
2210 SlimIt also provides a library that includes a JavaScript parser, lexer,
2211 pretty printer and a tree visitor.")
2212 (license license:expat)))
2214 (define-public python-flask-restful
2216 (name "python-flask-restful")
2221 (uri (pypi-uri "Flask-RESTful" version))
2222 (patches (search-patches "python-flask-restful-werkzeug-compat.patch"))
2225 "05b9lzx5yc3wgml2bcq50lq35h66m8zpj6dc9advcb5z3acsbaay"))))
2226 (build-system python-build-system)
2228 `(("python-aniso8601" ,python-aniso8601)
2229 ("python-flask" ,python-flask)
2230 ("python-pycrypto" ,python-pycrypto)
2231 ("python-pytz" ,python-pytz)))
2233 `(;; Optional dependency of Flask. Tests need it.
2234 ("python-blinker" ,python-blinker)
2235 ("python-mock" ,python-mock) ; For tests
2236 ("python-nose" ,python-nose))) ;for tests
2238 "https://www.github.com/flask-restful/flask-restful/")
2240 "Flask module for creating REST APIs")
2242 "This package contains a Flask module for creating REST APIs.")
2243 (license license:bsd-3)))
2245 (define-public python-flask-basicauth
2247 (name "python-flask-basicauth")
2252 (uri (pypi-uri "Flask-BasicAuth" version))
2255 "1zq1spkjr4sjdnalpp8wl242kdqyk6fhbnhr8hi4r4f0km4bspnz"))))
2256 (build-system python-build-system)
2258 `(("python-flask" ,python-flask)))
2260 "https://github.com/jpvanhal/flask-basicauth")
2262 "HTTP basic access authentication for Flask")
2264 "This package provides HTTP basic access authentication for Flask.")
2265 (license license:bsd-3)))
2267 (define-public python-flask-htpasswd
2269 (name "python-flask-htpasswd")
2274 (uri (pypi-uri "flask-htpasswd" version))
2277 "14q1y1y9i9bhabdnwd25jqzc4ljli23smxfyyh8abxz1vq93pxra"))))
2278 (build-system python-build-system)
2280 `(("python-flask" ,python-flask)
2281 ("python-itsdangerous" ,python-itsdangerous)
2282 ("python-passlib" ,python-passlib)
2283 ("python-tox" ,python-tox)))
2284 (home-page "http://github.com/carsongee/flask-htpasswd")
2285 (synopsis "Basic authentication via htpasswd files in Flask applications")
2286 (description "This package provides Basic authentication via
2287 @file{htpasswd} files and access_token authentication in Flask
2289 (license license:bsd-3)))
2291 (define-public python-flask-sqlalchemy
2293 (name "python-flask-sqlalchemy")
2297 (uri (pypi-uri "Flask-SQLAlchemy" version))
2300 "0nnllf0ddbh9jlhngnyjj98lbxgxr1csaplllx0caw98syq0k5hc"))))
2301 (build-system python-build-system)
2303 `(("python-flask" ,python-flask)
2304 ("python-sqlalchemy" ,python-sqlalchemy)))
2305 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
2306 (synopsis "Module adding SQLAlchemy support to your Flask application")
2308 "This package adds SQLAlchemy support to your Flask application.")
2309 (license license:bsd-3)))
2311 (define-public python-flask-restplus
2313 (name "python-flask-restplus")
2318 (uri (pypi-uri "flask-restplus" version))
2321 "11his6ii5brpkhld0d5bwzjjw4q3vmplpd6fmgzjrvvklsbk0cf4"))))
2322 (build-system python-build-system)
2324 '(#:tests? #f)) ; FIXME: 35/882 tests failing.
2326 ;; (modify-phases %standard-phases
2329 ;; (invoke "nosetests")
2332 `(("python-aniso8601" ,python-aniso8601)
2333 ("python-flask" ,python-flask)
2334 ("python-jsonschema" ,python-jsonschema)
2335 ("python-pytz" ,python-pytz)
2336 ("python-six" ,python-six)))
2338 `(("python-tzlocal" ,python-tzlocal)
2339 ("python-blinker" ,python-blinker)
2340 ("python-nose" ,python-nose)
2341 ("python-rednose" ,python-rednose)))
2342 (home-page "https://github.com/noirbizarre/flask-restplus")
2343 (synopsis "Framework for documented API development with Flask")
2344 (description "This package provides a framework for API development with
2345 the Flask web framework in Python. It is similar to package
2346 @code{python-flask-restful} but supports the @code{python-swagger}
2347 documentation builder.")
2348 (license license:expat)))
2350 (define-public python-flask-restful-swagger
2352 (name "python-flask-restful-swagger")
2357 (uri (pypi-uri "flask-restful-swagger" version))
2360 "1p66f98b5zpypnnz56pxpbirchqj6aniw6qyrp8h572l0dn9xlvq"))))
2361 (build-system python-build-system)
2362 (arguments '(#:tests? #f)) ;no tests
2364 `(("python-flask-restful" ,python-flask-restful)))
2365 (home-page "https://github.com/rantav/flask-restful-swagger")
2366 (synopsis "Extract Swagger specs from Flask-Restful projects")
2367 (description "This package lets you extract Swagger API documentation
2368 specs from your Flask-Restful projects.")
2369 (license license:expat)))
2371 (define-public python2-flask-restful-swagger
2372 (package-with-python2 python-flask-restful-swagger))
2374 (define-public python-htmlmin
2376 (name "python-htmlmin")
2381 (uri (pypi-uri "htmlmin" version))
2384 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
2386 `(#:tests? #f)) ; no tests
2387 (build-system python-build-system)
2388 (home-page "https://htmlmin.readthedocs.org/en/latest/")
2389 (synopsis "HTML minifier")
2390 (description "@code{htmlmin} is an HTML minifier that just works.
2391 It comes with safe defaults and easily configurable options.")
2392 (license license:bsd-3)))
2394 (define-public python2-htmlmin
2395 (package-with-python2 python-htmlmin))
2397 (define-public python-flask-htmlmin
2399 (name "python-flask-htmlmin")
2404 (uri (pypi-uri "Flask-HTMLmin" version))
2407 "1n6zlq72kakkw0z2jpq6nh74lfsmxybm4g053pwhc14fbr809348"))))
2409 `(("python-flask" ,python-flask)
2410 ("python-htmlmin" ,python-htmlmin)))
2411 (build-system python-build-system)
2412 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
2413 (synopsis "HTML response minifier for Flask")
2415 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
2416 (license license:bsd-3)))
2418 (define-public python2-flask-htmlmin
2419 (package-with-python2 python-flask-htmlmin))
2421 (define-public python-jsmin
2423 (name "python-jsmin")
2428 (uri (pypi-uri "jsmin" version))
2431 "0fsmqbjvpxvff0984x7c0y8xmf49ax9mncz48b9xjx8wrnr9kpxn"))))
2432 (build-system python-build-system)
2433 (home-page "https://github.com/tikitu/jsmin/")
2434 (synopsis "Python JavaScript minifier")
2436 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
2437 on the command line.")
2438 (license license:expat)))
2440 (define-public python-flask-login
2442 (name "python-flask-login")
2448 (url "https://github.com/maxcountryman/flask-login.git")
2450 (file-name (git-file-name name version))
2452 (base32 "11ac924w0y4m0kf3mxnxdlidy88jfa7njw5yyrq16dvnx4iwd8gg"))))
2453 (build-system python-build-system)
2455 `(("python-flask" ,python-flask)))
2458 `(("python-blinker" ,python-blinker)
2459 ("python-coverage" ,python-coverage)
2460 ("python-mock" ,python-mock)
2461 ("python-pycodestyle" ,python-pycodestyle)
2462 ("python-pyflakes" ,python-pyflakes)
2463 ("python-pytest" ,python-pytest)
2464 ("python-semantic-version" ,python-semantic-version)
2465 ("python-werkzeug" ,python-werkzeug)))
2466 (home-page "https://github.com/maxcountryman/flask-login")
2467 (synopsis "User session management for Flask")
2469 "@code{Flask-Login} provides user session management for Flask. It
2470 handles the common tasks of logging in, logging out, and remembering your
2471 users' sessions over extended periods of time.")
2472 (license license:expat)))
2474 (define-public python2-flask-login
2475 (package-with-python2 python-flask-login))
2477 (define-public python-oauth2client
2479 (name "python-oauth2client")
2484 (uri (pypi-uri "oauth2client" version))
2487 "1irqqap2zibysf8dba8sklfqikia579srd0phm5n754ni0h59gl0"))))
2488 (build-system python-build-system)
2492 `(("python-httplib2" ,python-httplib2)
2493 ("python-pyasn1" ,python-pyasn1)
2494 ("python-pyasn1-modules" ,python-pyasn1-modules)
2495 ("python-rsa" ,python-rsa)
2496 ("python-six" ,python-six)))
2497 (home-page "https://github.com/google/oauth2client/")
2498 (synopsis "OAuth 2.0 client library")
2499 (description "@code{python-oauth2client} provides an OAuth 2.0 client
2500 library for Python")
2501 (license license:asl2.0)))
2503 (define-public python2-oauth2client
2504 (package-with-python2 python-oauth2client))
2506 (define-public python-flask-oidc
2508 (name "python-flask-oidc")
2513 (uri (pypi-uri "flask-oidc" version))
2516 "1ay5j0mf174bix7i67hclr95gv16z81fpx0dijvi0gydvdj3ddy2"))))
2517 (build-system python-build-system)
2519 `(("python-flask" ,python-flask)
2520 ("python-itsdangerous" ,python-itsdangerous)
2521 ("python-oauth2client" ,python-oauth2client)
2522 ("python-six" ,python-six)))
2524 `(("python-nose" ,python-nose)
2525 ("python-mock" ,python-mock)))
2526 (home-page "https://github.com/puiterwijk/flask-oidc")
2527 (synopsis "OpenID Connect extension for Flask")
2528 (description "@code{python-flask-oidc} provides an OpenID Connect extension
2530 (license license:bsd-2)))
2532 (define-public python-webassets
2534 (name "python-webassets")
2539 (uri (pypi-uri "webassets" version))
2542 "1nrqkpb7z46h2b77xafxihqv3322cwqv6293ngaky4j3ff4cing7"))))
2543 (build-system python-build-system)
2545 `(("python-jinja2" ,python-jinja2)
2546 ("python-mock" ,python-mock)
2547 ("python-nose" ,python-nose)
2548 ("python-pytest" ,python-pytest)))
2549 (home-page "https://github.com/miracle2k/webassets")
2550 (synopsis "Media asset management")
2551 (description "Merges, minifies and compresses Javascript and CSS files,
2552 supporting a variety of different filters, including YUI, jsmin, jspacker or
2553 CSS tidy. Also supports URL rewriting in CSS files.")
2554 (license license:bsd-2)))
2556 (define-public python-cssmin
2558 (name "python-cssmin")
2563 (uri (pypi-uri "cssmin" version))
2566 "1dk723nfm2yf8cp4pj785giqlwv42l0kj8rk40kczvq1hk6g04p0"))))
2567 (build-system python-build-system)
2568 (home-page "https://github.com/zacharyvoase/cssmin")
2569 (synopsis "Python port of the YUI CSS Compressor")
2570 (description "Python port of the YUI CSS Compressor.")
2571 (license (list license:expat license:bsd-3))))
2573 (define-public python2-cssmin
2574 (package-with-python2 python-cssmin))
2576 (define-public python-elasticsearch
2578 (name "python-elasticsearch")
2583 (uri (pypi-uri "elasticsearch" version))
2586 "0rnjvlhw4v3vg14l519qliy1s1zpmx3827q0xfviwvk42rr7hh01"))))
2587 (build-system python-build-system)
2589 `(("python-mock" ,python-mock)
2590 ("python-nosexcover" ,python-nosexcover)
2591 ("python-pyaml" ,python-pyaml)
2592 ("python-requests" ,python-requests)))
2594 `(("urllib3" ,python-urllib3)))
2596 ;; tests require the test_elasticsearch module but it is not distributed.
2598 (home-page "https://github.com/elastic/elasticsearch-py")
2599 (synopsis "Low-level client for Elasticsearch")
2600 (description "Official low-level client for Elasticsearch. Its goal is to
2601 provide common ground for all Elasticsearch-related code in Python; because of
2602 this it tries to be opinion-free and very extendable.")
2603 (license license:expat)))
2605 (define-public python2-elasticsearch
2606 (package-with-python2 python-elasticsearch))
2608 (define-public python-flask-script
2610 (name "python-flask-script")
2615 (uri (pypi-uri "Flask-Script" version))
2618 "0r8w2v89nj6b9p91p495cga5m72a673l2wc0hp0zqk05j4yrc9b4"))))
2619 (build-system python-build-system)
2622 (modify-phases %standard-phases
2623 (add-after 'unpack 'patch-tests
2625 (substitute* "tests.py"
2626 (("flask\\.ext\\.script") "flask_script"))
2629 `(("python-flask" ,python-flask)
2630 ("python-argcomplete" ,python-argcomplete)
2631 ("python-werkzeug" ,python-werkzeug)))
2633 `(("python-pytest" ,python-pytest)))
2635 "https://github.com/smurfix/flask-script")
2636 (synopsis "Scripting support for Flask")
2637 (description "The Flask-Script extension provides support for writing
2638 external scripts in Flask. This includes running a development server,
2639 a customised Python shell, scripts to set up your database, cronjobs,
2640 and other command-line tasks that belong outside the web application
2642 (license license:bsd-3)))
2644 (define-public python2-flask-script
2645 (package-with-python2 python-flask-script))
2647 (define-public python-flask-migrate
2649 (name "python-flask-migrate")
2654 (uri (pypi-uri "Flask-Migrate" version))
2657 "1vip9ww6l18dxffjsggm83k71zkvihxpnhaswpv8klh95s6517d6"))))
2658 (build-system python-build-system)
2660 `(("python-flask" ,python-flask)
2661 ("python-alembic" ,python-alembic)
2662 ("python-sqlalchemy" ,python-sqlalchemy)
2663 ("python-flask-script" ,python-flask-script)
2664 ("python-flask-sqlalchemy" ,python-flask-sqlalchemy)))
2665 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
2666 (synopsis "SQLAlchemy database migrations for Flask programs using
2668 (description "This package contains SQLAlchemy database migration tools
2669 for Flask programs that are using @code{python-alembic}.")
2670 (license license:expat)))
2672 (define-public python-genshi
2674 (name "python-genshi")
2680 (url "https://github.com/edgewall/genshi.git")
2682 (file-name (git-file-name name version))
2684 (base32 "06rch30x10l105k5b6rahd839lkhmgrzn6691wbci0cb2fzps32w"))))
2685 (build-system python-build-system)
2686 (home-page "https://genshi.edgewall.org/")
2687 (synopsis "Toolkit for generation of output for the web")
2688 (description "Genshi is a Python library that provides an integrated set
2689 of components for parsing, generating, and processing HTML, XML or other
2690 textual content for output generation on the web.")
2691 (license license:bsd-3)))
2693 (define-public python2-genshi
2694 (package-with-python2 python-genshi))
2696 (define-public python-flask-principal
2698 (name "python-flask-principal")
2703 (uri (pypi-uri "Flask-Principal" version))
2706 "0lwlr5smz8vfm5h9a9i7da3q1c24xqc6vm9jdywdpgxfbi5i7mpm"))))
2707 (build-system python-build-system)
2709 `(("python-blinker" ,python-blinker)))
2711 `(("python-flask" ,python-flask)
2712 ("python-nose" ,python-nose)))
2713 (home-page "https://pythonhosted.org/Flask-Principal/")
2714 (synopsis "Identity management for Flask")
2715 (description "@code{flask_principal} is a identity management library for
2716 Flask. It supports managing both authentication and authorization data in a
2717 thread-local variable.")
2718 (license license:expat)))
2720 (define-public python2-flask-principal
2721 (package-with-python2 python-flask-principal))
2723 (define-public python-flask-httpauth
2725 (name "python-flask-httpauth")
2730 (uri (pypi-uri "Flask-HTTPAuth" version))
2733 "13gff5w1mqpzm5nccyg02v3ifb9ifqh5k866cssjhghhg6msfjsz"))))
2734 (build-system python-build-system)
2736 `(("python-flask" ,python-flask)))
2737 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
2738 (synopsis "Basic and Digest HTTP authentication for Flask routes")
2739 (description "@code{flask_httpauth} provides Basic and Digest HTTP
2740 authentication for Flask routes.")
2741 (license license:expat)))
2743 (define-public python2-flask-httpauth
2744 (package-with-python2 python-flask-httpauth))
2746 (define-public python-uritemplate
2748 (name "python-uritemplate")
2753 (uri (pypi-uri "uritemplate" version))
2756 "0781gm9g34wa0asc19dx81ng0nqq07igzv3bbvdqmz13pv7469n0"))))
2757 (build-system python-build-system)
2758 (home-page "https://uritemplate.readthedocs.org")
2759 (synopsis "Library to deal with URI Templates")
2760 (description "@code{uritemplate} provides Python library to deal with URI
2762 (license license:bsd-2)))
2764 (define-public python2-uritemplate
2765 (package-with-python2 python-uritemplate))
2767 (define-public python-publicsuffix
2769 (name "python-publicsuffix")
2773 (uri (pypi-uri "publicsuffix" version))
2776 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
2777 (build-system python-build-system)
2779 `(#:tests? #f)) ; tests use the internet
2780 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
2781 (synopsis "Get suffix for a domain name")
2782 (description "Get a public suffix for a domain name using the Public Suffix
2784 (license license:expat)))
2786 (define-public python2-publicsuffix
2787 (package-with-python2 python-publicsuffix))
2789 (define-public python-publicsuffix2
2791 (name "python-publicsuffix2")
2792 (version "2.20191221")
2796 (uri (pypi-uri "publicsuffix2" version))
2798 (base32 "0yzysvfj1najr1mb4pcqrbmjir3xpb69rlffln95a3cdm8qwry00"))))
2799 (build-system python-build-system)
2802 (modify-phases %standard-phases
2803 (add-after 'unpack 'ignore-maintainer-inputs
2805 ;; Comment out a demand for python-requests, which is used only by
2806 ;; the unused ‘update_psl’ helper command.
2807 (substitute* "setup.py"
2808 (("'requests " match)
2809 (format "# ~a" match)))
2811 #:tests? #f)) ; the test suite requires network access
2812 (home-page "https://github.com/pombredanne/python-publicsuffix2")
2813 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
2814 (description "Get a public suffix for a domain name using the Public Suffix
2815 List. Forked from and using the same API as the publicsuffix package.")
2816 (license (list license:expat license:mpl2.0))))
2818 (define-public python2-publicsuffix2
2819 (package-with-python2 python-publicsuffix2))
2821 (define-public python-werkzeug
2823 (name "python-werkzeug")
2828 (uri (pypi-uri "Werkzeug" version))
2831 "15kh0z61klp62mrc1prka13xsshxn0rsp1j1s2964iw86yisi6qn"))))
2832 (build-system python-build-system)
2835 (modify-phases %standard-phases
2837 (add-after 'install 'check
2838 (lambda* (#:key inputs outputs #:allow-other-keys)
2839 (add-installed-pythonpath inputs outputs)
2840 (invoke "python" "-m" "pytest"))))))
2842 `(("python-requests" ,python-requests)))
2844 `(("python-pytest" ,python-pytest)
2845 ("python-pytest-timeout" ,python-pytest-timeout)))
2846 (home-page "https://www.palletsprojects.org/p/werkzeug/")
2847 (synopsis "Utilities for WSGI applications")
2848 (description "One of the most advanced WSGI utility modules. It includes a
2849 powerful debugger, full-featured request and response objects, HTTP utilities to
2850 handle entity tags, cache control headers, HTTP dates, cookie handling, file
2851 uploads, a powerful URL routing system and a bunch of community-contributed
2853 (license license:x11)))
2855 (define-public python2-werkzeug
2856 (package-with-python2 python-werkzeug))
2858 (define-public python-bottle
2860 (name "python-bottle")
2865 (uri (pypi-uri "bottle" version))
2868 "0m9k2a7yxvggc4kw8fsvj381vgsvfcdshg5nzy6vwrxiw2p53drr"))))
2869 (build-system python-build-system)
2870 (home-page "http://bottlepy.org/")
2871 (synopsis "WSGI framework for small web-applications.")
2872 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
2873 (license license:expat)))
2875 (define-public python2-bottle
2876 (package-with-python2 python-bottle))
2878 (define-public python-wtforms
2880 (name "python-wtforms")
2885 (uri (pypi-uri "WTForms" version ".zip"))
2888 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
2889 (build-system python-build-system)
2892 (modify-phases %standard-phases
2893 (add-after 'unpack 'remove-django-test
2894 ;; Don't fail the tests when the inputs for the optional tests cannot be found.
2898 (("'ext_django.tests', 'ext_sqlalchemy', 'ext_dateutil', 'locale_babel'") "")
2899 (("sys.stderr.write(\"### Disabled test '%s', dependency not found\n\" % name)") ""))
2902 `(("unzip" ,unzip)))
2903 (home-page "http://wtforms.simplecodes.com/")
2905 "Form validation and rendering library for Python web development")
2907 "WTForms is a flexible forms validation and rendering library
2908 for Python web development. It is very similar to the web form API
2909 available in Django, but is a standalone package.")
2910 (license license:bsd-3)))
2912 (define-public python2-wtforms
2913 (package-with-python2 python-wtforms))
2915 (define-public python-paste
2917 (name "python-paste")
2922 (uri (pypi-uri "Paste" version))
2925 "14lbi9asn5agsdf7r97prkjpz7amgmp529lbvfhf0nv881xczah6"))
2926 (patches (search-patches "python-paste-remove-timing-test.patch"))
2927 (modules '((guix build utils)))
2930 ;; This test calls out to the internet.
2931 (delete-file "tests/test_proxy.py") #t))))
2932 (build-system python-build-system)
2934 `(("python-pytest" ,python-pytest)
2935 ("python-pytest-runner" ,python-pytest-runner)
2936 ("python-nose" ,python-nose)))
2938 `(("python-six" ,python-six)))
2939 (home-page "https://pythonpaste.readthedocs.io/")
2941 "Python web development tools, focusing on WSGI")
2943 "Paste provides a variety of web development tools and middleware which
2944 can be nested together to build web applications. Paste's design closely
2945 follows ideas flowing from WSGI (Web Standard Gateway Interface).")
2946 (license license:expat)))
2948 (define-public python2-paste
2949 (package-with-python2 python-paste))
2951 (define-public python-pastescript
2953 (name "python-pastescript")
2958 (uri (pypi-uri "PasteScript" version))
2961 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
2962 (build-system python-build-system)
2964 `(("python-nose" ,python-nose)))
2966 `(("python-paste" ,python-paste)
2967 ("python-pastedeploy" ,python-pastedeploy)))
2968 (home-page (string-append "https://web.archive.org/web/20161025192515/"
2969 "http://pythonpaste.org/script/"))
2971 '(;; Unfortunately, this requires the latest unittest2,
2972 ;; but that requires traceback2 which requires linecache2 which requires
2973 ;; unittest2. So we're skipping tests for now.
2974 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
2975 ;; so in theory we could get around this situation somehow.)
2978 "Pluggable command line tool for serving web applications and more")
2980 "PasteScript is a plugin-friendly command line tool which provides a
2981 variety of features, from launching web applications to bootstrapping project
2983 (license license:expat)))
2985 (define-public python2-pastescript
2986 (package-with-python2 python-pastescript))
2988 (define-public python2-urlgrabber
2990 (name "python2-urlgrabber")
2995 (uri (pypi-uri "urlgrabber" version))
2997 (base32 "0w1h7hlsq406bxfy2pn4i9bd003bwl0q9b7p03z3g6yl0d21ddq5"))))
2998 (build-system python-build-system)
2999 (arguments `(#:python ,python-2)) ; urlgrabber supports python2 only
3000 (home-page "http://urlgrabber.baseurl.org")
3001 (synopsis "High-level cross protocol url-grabber")
3002 (description "@code{urlgrabber} is Python2 library that unifies access to
3003 files available on web, FTP or locally. It supports HTTP, FTP and file://
3004 protocols, it supports features like HTTP keep-alive, reget, throttling and
3006 (license license:lgpl2.1+)))
3008 (define-public python-pycares
3010 (name "python-pycares")
3015 (uri (pypi-uri "pycares" version))
3018 "0h4fxw5drrhfyslzmfpljk0qnnpbhhb20hnnndzahhbwylyw1x1n"))))
3019 (build-system python-build-system)
3021 `(#:tests? #f)) ;tests require internet access
3022 (home-page "http://github.com/saghul/pycares")
3023 (synopsis "Python interface for @code{c-ares}")
3024 (description "@code{pycares} is a Python module which provides an
3025 interface to @code{c-ares}, a C library that performs DNS requests and
3026 name resolutions asynchronously.")
3027 (license license:expat)))
3029 (define-public python-yarl
3031 (name "python-yarl")
3036 (uri (pypi-uri "yarl" version))
3039 "1s6z13g8vgxfkkqwhn6imnm7pl7ky9arv4jygnn6bcndcbidg7d6"))))
3040 (build-system python-build-system)
3042 `(("python-pytest" ,python-pytest)
3043 ("python-pytest-runner" ,python-pytest-runner)))
3045 `(("python-idna" ,python-idna)
3046 ("python-multidict" ,python-multidict)))
3047 (home-page "https://github.com/aio-libs/yarl/")
3048 (synopsis "Yet another URL library")
3049 (description "@code{yarl} module provides handy @code{URL} class
3050 for URL parsing and changing.")
3051 (license license:asl2.0)))
3053 (define-public python-google-api-client
3055 (name "python-google-api-client")
3060 (uri (pypi-uri "google-api-python-client" version))
3063 "1wpbbbxfpy9mwxdy3kn352cb590ladv574j1aa2l4grjdqw3ln05"))))
3064 (build-system python-build-system)
3066 '(#:tests? #f)) ; tests require internet access
3068 `(("python-httplib2" ,python-httplib2)
3069 ("python-six" ,python-six)
3070 ("python-oauth2client" ,python-oauth2client)
3071 ("python-uritemplate" ,python-uritemplate)))
3072 (home-page "https://github.com/google/google-api-python-client")
3073 (synopsis "Core Python library for accessing Google APIs")
3074 (description "Python client library for Google's discovery based APIs")
3075 (license license:asl2.0)))
3077 (define-public python2-google-api-client
3078 (package-with-python2 python-google-api-client))
3080 (define-public python-hawkauthlib
3082 (name "python-hawkauthlib")
3087 (uri (pypi-uri "hawkauthlib" version))
3090 "03ai47s4h8nfnrf25shbfvkm1b9n1ccd4nmmj280sg1fayi69zgg"))))
3091 (build-system python-build-system)
3093 `(("python-requests" ,python-requests)
3094 ("python-webob" ,python-webob)))
3095 (home-page "https://github.com/mozilla-services/hawkauthlib")
3096 (synopsis "Hawk Access Authentication protocol")
3098 "This is a low-level Python library for implementing Hawk Access Authentication,
3099 a simple HTTP request-signing scheme.")
3100 (license license:mpl2.0)))
3102 (define-public python-pybrowserid
3104 (name "python-pybrowserid")
3109 (uri (pypi-uri "PyBrowserID" version))
3112 "1qvi79kfb8x9kxkm5lw2mp42hm82cpps1xknmsb5ghkwx1lpc8kc"))))
3113 (build-system python-build-system)
3115 `(("python-requests" ,python-requests)))
3117 `(("python-mock" ,python-mock)))
3118 (home-page "https://github.com/mozilla/PyBrowserID")
3119 (synopsis "Python library for the BrowserID protocol")
3121 "This is a Python client library for the BrowserID protocol that
3122 underlies Mozilla Persona.")
3123 (license license:mpl2.0)))
3125 (define-public python-pyfxa
3127 (name "python-pyfxa")
3132 (uri (pypi-uri "PyFxA" version))
3135 "0axl16fyrz2r88gnw4b12mk7dpkqscv8c4wsc1y5hicl7bsbc4fm"))))
3136 (build-system python-build-system)
3137 (arguments '(#:tests? #f)) ; 17 tests require network access
3139 `(("python-cryptography" ,python-cryptography)
3140 ("python-hawkauthlib" ,python-hawkauthlib)
3141 ("python-pybrowserid" ,python-pybrowserid)
3142 ("python-requests" ,python-requests)
3143 ("python-six" ,python-six)))
3145 `(("python-grequests" ,python-grequests)
3146 ("python-mock" ,python-mock)
3147 ("python-responses" ,python-responses)
3148 ("python-unittest2" ,python-unittest2)))
3149 (home-page "https://github.com/mozilla/PyFxA")
3150 (synopsis "Firefox Accounts client library for Python")
3152 "This is a Python library for interacting with the Firefox Accounts
3154 (license license:mpl2.0)))
3156 (define-public python-hyperlink
3158 (name "python-hyperlink")
3163 (uri (pypi-uri "hyperlink" version))
3166 "0m2nhi0j8wmgfscf974wd5v1xfq8mah286hil6npy1ys0m3y7222"))))
3167 (build-system python-build-system)
3169 `(("python-idna" ,python-idna)))
3170 (home-page "https://github.com/python-hyper/hyperlink")
3171 (synopsis "Python module to create immutable URLs according to spec")
3172 (description "This package provides a Python module to create immutable, and
3173 correct URLs for Python according to RFCs 3986 and 3987.")
3174 (license license:expat)))
3176 (define-public python-treq
3178 (name "python-treq")
3183 (uri (pypi-uri "treq" version))
3186 "0j4zwq9p1c9piv1vc66nxcv9s6hdinf90jwkbsm91k14npv9zq4i"))))
3187 (build-system python-build-system)
3189 `(("python-attrs" ,python-attrs)
3190 ("python-idna" ,python-idna)
3191 ("python-incremental" ,python-incremental)
3192 ("python-requests" ,python-requests)
3193 ("python-service-identity" ,python-service-identity)
3194 ("python-twisted" ,python-twisted)))
3195 (home-page "https://github.com/twisted/treq")
3196 (synopsis "Requests-like API built on top of twisted.web's Agent")
3197 (description "This package provides an HTTP library inspired by
3198 @code{requests}} but written on top of Twisted's @code{Agents}. It offers a
3199 high level API for making HTTP requests when using Twisted.")
3200 (license license:expat)))
3202 (define-public python-autobahn
3204 (name "python-autobahn")
3209 (uri (pypi-uri "autobahn" version))
3212 "1mm7j24ls01c7jb1ad5p5cpyxvzgydiyf8b04ihykh2v8g98j0x7"))))
3213 (build-system python-build-system)
3215 ;; The tests fail to run:
3216 ;; https://github.com/crossbario/autobahn-python/issues/1117
3219 `(("python-cffi" ,python-cffi)
3220 ("python-twisted" ,python-twisted)
3221 ("python-txaio" ,python-txaio)))
3222 (home-page "https://crossbar.io/autobahn/")
3223 (synopsis "Web Application Messaging Protocol implementation")
3224 (description "This package provides an implementation of the @dfn{Web Application
3225 Messaging Protocol} (WAMP). WAMP connects components in distributed
3226 applications using Publish and Subscribe (PubSub) and routed Remote Procedure
3227 Calls (rRPC). It is ideal for distributed, multi-client and server applications
3228 such as IoT applications or multi-user database-driven business applications.")
3229 (license license:expat)))
3231 (define-public python-ws4py
3233 (name "python-ws4py")
3238 (uri (pypi-uri "ws4py" version))
3241 "10slbbf2jm4hpr92jx7kh7mhf48sjl01v2w4d8z3f1p0ybbp7l19"))))
3242 (build-system python-build-system)
3245 (modify-phases %standard-phases
3246 (add-after 'unpack 'python3.7-compatibility
3248 (substitute* '("ws4py/server/tulipserver.py"
3249 "ws4py/async_websocket.py")
3251 "asyncio.ensure_future"))
3253 ;; We don't have a package for cherrypy.
3254 (add-after 'unpack 'remove-cherrypy-support
3256 (delete-file "ws4py/server/cherrypyserver.py")
3259 `(("python-gevent" ,python-gevent)
3260 ("python-tornado" ,python-tornado)))
3261 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
3262 (synopsis "WebSocket client and server library")
3264 "This package provides a WebSocket client and server library for
3266 (license license:bsd-3)))
3268 ;; kaldi-gstreamer-server does not yet work with python-ws4py > 0.3.2
3269 (define-public python2-ws4py-for-kaldi-gstreamer-server
3270 (package (inherit python-ws4py)
3271 (name "python2-ws4py")
3276 (uri (pypi-uri "ws4py" version))
3279 "12ys3dv98awhrxd570vla3hqgzq3avjhq4yafhghhq3a942y1928"))))
3280 (build-system python-build-system)
3282 `(#:python ,python-2
3284 (modify-phases %standard-phases
3285 ;; We don't have a package for cherrypy.
3286 (add-after 'unpack 'remove-cherrypy-support
3288 (delete-file "ws4py/server/cherrypyserver.py")
3291 `(("python-gevent" ,python2-gevent)
3292 ("python-tornado" ,python2-tornado)))))
3294 (define-public python-slugify
3296 (name "python-slugify")
3301 (uri (pypi-uri "python-slugify" version))
3303 (base32 "0dv97yi5fq074q5qyqbin09pmi8ixg36caf5nkpw2bqkd8jh6pap"))
3305 (search-patches "python-slugify-depend-on-unidecode.patch"))))
3307 `(("python-wheel" ,python-wheel)))
3309 `(("python-unidecode" ,python-unidecode)))
3312 (modify-phases %standard-phases
3315 (invoke "python" "test.py"))))))
3316 (build-system python-build-system)
3317 (home-page "https://github.com/un33k/python-slugify")
3318 (synopsis "Python Slugify application that handles Unicode")
3319 (description "This package provides a @command{slufigy} command and
3320 library to create slugs from unicode strings while keeping it DRY.")
3321 (license license:expat)))
3323 (define-public python-branca
3325 (name "python-branca")
3330 (uri (pypi-uri "branca" version))
3333 "0pmigd521j2228xf8x34vbx0niwvms7xl7za0lymywj0vydjqxiy"))))
3334 (build-system python-build-system)
3336 `(("python-jinja2" ,python-jinja2)
3337 ("python-six" ,python-six)))
3339 `(("python-pytest" ,python-pytest)))
3340 (home-page "https://github.com/python-visualization/branca")
3341 (synopsis "Generate complex HTML+JS pages with Python")
3342 (description "Generate complex HTML+JS pages with Python")
3343 (license license:expat)))
3345 (define-public python-tinycss2
3347 (name "python-tinycss2")
3352 (uri (pypi-uri "tinycss2" version))
3354 (base32 "1kw84y09lggji4krkc58jyhsfj31w8npwhznr7lf19d0zbix09v4"))))
3355 (build-system python-build-system)
3358 (modify-phases %standard-phases
3360 (lambda _ (invoke "pytest"))))))
3362 `(("python-webencodings" ,python-webencodings)))
3364 `(("python-pytest-flake8" ,python-pytest-flake8)
3365 ("python-pytest-isort" ,python-pytest-isort)
3366 ("python-pytest-runner" ,python-pytest-runner)))
3367 (home-page "https://tinycss2.readthedocs.io/")
3368 (synopsis "Low-level CSS parser for Python")
3369 (description "@code{tinycss2} can parse strings, return Python objects
3370 representing tokens and blocks, and generate CSS strings corresponding to
3373 Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
3374 grammar of CSS but doesn’t know specific rules, properties or values supported
3375 in various CSS modules.")
3376 (license license:bsd-3)))
3378 (define-public python-cssselect2
3380 (name "python-cssselect2")
3385 (uri (pypi-uri "cssselect2" version))
3387 (base32 "0skymzb4ncrm2zdsy80f53vi0arf776lvbp51hzh4ayp1il5lj3h"))))
3388 (build-system python-build-system)
3391 (modify-phases %standard-phases
3393 (lambda _ (invoke "pytest"))))))
3395 `(("python-tinycss2" ,python-tinycss2)))
3397 `(("python-pytest-cov" ,python-pytest-cov)
3398 ("python-pytest-flake8" ,python-pytest-flake8)
3399 ("python-pytest-isort" ,python-pytest-isort)
3400 ("python-pytest-runner" ,python-pytest-runner)))
3401 (home-page "https://cssselect2.readthedocs.io/")
3402 (synopsis "CSS selectors for Python ElementTree")
3403 (description "@code{cssselect2} is a straightforward implementation of
3404 CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
3405 ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
3407 Unlike the Python package @code{cssselect}, it does not translate selectors to
3408 XPath and therefore does not have all the correctness corner cases that are
3409 hard or impossible to fix in cssselect.")
3410 (license license:bsd-3)))
3412 (define-public gunicorn
3419 (uri (pypi-uri "gunicorn" version))
3422 "09n6fc019bgrvph1s5h1lwhn2avcsprw6ncd203qhra3i8mvn10r"))))
3423 (outputs '("out" "doc"))
3424 (build-system python-build-system)
3427 (modify-phases %standard-phases
3428 (add-after 'build 'build-doc
3430 (invoke "make" "-C" "docs" "PAPER=a4" "html" "info")
3431 (delete-file "docs/build/texinfo/Makefile")
3432 (delete-file "docs/build/texinfo/Gunicorn.texi")
3436 (setenv "PYTHONPATH"
3437 (string-append ".:" (getenv "PYTHONPATH")))
3439 (add-after 'install 'install-doc
3440 (lambda* (#:key outputs #:allow-other-keys)
3441 (let* ((doc (string-append (assoc-ref outputs "doc")
3442 "/share/doc/" ,name "-" ,version))
3443 (html (string-append doc "/html"))
3444 (info (string-append doc "/info"))
3445 (examples (string-append doc "/examples")))
3449 (copy-recursively "docs/build/html" html)
3450 (copy-recursively "docs/build/texinfo" info)
3451 (copy-recursively "examples" examples)
3452 (for-each (lambda (file)
3453 (copy-file file (string-append doc "/" file)))
3454 '("README.rst" "NOTICE" "LICENSE" "THANKS")))
3457 `(("binutils" ,binutils) ;; for ctypes.util.find_library()
3458 ("python-aiohttp", python-aiohttp)
3459 ("python-pytest" ,python-pytest)
3460 ("python-pytest-cov" ,python-pytest-cov)
3461 ("python-sphinx" ,python-sphinx)
3462 ("texinfo" ,texinfo)))
3463 (home-page "https://gunicorn.org/")
3464 (synopsis "Python WSGI HTTP Server for UNIX")
3465 (description "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
3466 Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
3467 Unicorn project. The Gunicorn server is broadly compatible with
3468 various web frameworks, simply implemented, light on server resources,
3469 and fairly speedy.")
3470 (license license:expat)))
3472 ;; break cyclic dependency for python-aiohttp, which depends on gunicorn for
3474 (define-public gunicorn-bootstrap
3478 (arguments `(#:tests? #f))
3479 (properties '((hidden? . #t)))
3480 (native-inputs `())))
3482 (define-public python-translation-finder
3484 (name "python-translation-finder")
3489 (uri (pypi-uri "translation-finder" version))
3492 "1pcy9z8gmb8x41gjhw9x0lkr0d2mv5mdxcs2hwg6q8mxs857j589"))))
3493 (build-system python-build-system)
3496 (modify-phases %standard-phases
3497 (add-before 'build 'remove-failing-test
3499 (delete-file "translation_finder/test_api.py")
3502 `(("python-chardet" ,python-chardet)
3503 ("python-pathlib2" ,python-pathlib2)
3504 ("python-ruamel.yaml" ,python-ruamel.yaml)
3505 ("python-six" ,python-six)))
3507 `(("python-codecov" ,python-codecov)
3508 ("python-codacy-coverage" ,python-codacy-coverage)
3509 ("python-pytest-cov" ,python-pytest-cov)
3510 ("python-pytest-runner" ,python-pytest-runner)
3511 ("python-twine" ,python-twine)))
3512 (home-page "https://weblate.org/")
3513 (synopsis "Translation file finder for Weblate")
3514 (description "This package provides a function to find translation file in
3515 the source code of a project. It supports many translation file formats and
3516 is part of the Weblate translation platform.")
3517 (license license:gpl3+)))
3519 (define-public python-gitlab
3521 (name "python-gitlab")
3526 (uri (pypi-uri "python-gitlab" version))
3529 "0zl6kz8v8cg1bcy2r78b2snb0lpw0b573gdx2x1ps0nhsh75l4j5"))))
3530 (build-system python-build-system)
3532 `(("python-requests" ,python-requests)
3533 ("python-six" ,python-six)))
3535 `(("python-httmock" ,python-httmock)
3536 ("python-mock" ,python-mock)))
3538 "https://github.com/python-gitlab/python-gitlab")
3539 (synopsis "Interact with GitLab API")
3540 (description "This package provides an extended library for interacting
3541 with GitLab instances through their API.")
3542 (license license:lgpl3+)))
3544 (define-public python-path-and-address
3546 (name "python-path-and-address")
3550 ;; The source distributed on PyPI doesn't include tests.
3553 (url "https://github.com/joeyespo/path-and-address")
3554 (commit (string-append "v" version))))
3555 (file-name (git-file-name name version))
3558 "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6"))))
3559 (build-system python-build-system)
3562 (modify-phases %standard-phases
3564 (lambda* (#:key inputs outputs #:allow-other-keys)
3565 (add-installed-pythonpath inputs outputs)
3566 (invoke "py.test"))))))
3568 `(("python-pytest" ,python-pytest)))
3569 (home-page "https://github.com/joeyespo/path-and-address")
3570 (synopsis "Functions for command-line server tools used by humans")
3571 (description "Path-and-address resolves ambiguities of command-line
3572 interfaces, inferring which argument is the path, and which is the address.")
3573 (license license:expat)))
3576 ;; No release by upstream for quite some time, some bugs fixed since. See:
3577 ;; https://github.com/joeyespo/grip/issues/304
3578 (let ((commit "27a4d6d87ea1d0ea7f7f120de55baabee3de73e3"))
3581 (version (git-version "4.5.2" "1" commit))
3586 (url "https://github.com/joeyespo/grip")
3588 (file-name (git-file-name name version))
3591 "0kx5hgb3q19i4l18a4vqdq9af390xgpk88lp2ay75qi96k0dc68w"))))
3592 (build-system python-build-system)
3594 `(("python-docopt" ,python-docopt)
3595 ("python-flask" ,python-flask)
3596 ("python-markdown" ,python-markdown)
3597 ("python-path-and-address" ,python-path-and-address)
3598 ("python-pygments" ,python-pygments)
3599 ("python-requests" ,python-requests)))
3601 `(("python-pytest" ,python-pytest)
3602 ("python-responses" ,python-responses)))
3605 (modify-phases %standard-phases
3607 (lambda* (#:key inputs outputs #:allow-other-keys)
3608 (add-installed-pythonpath inputs outputs)
3609 (setenv "PATH" (string-append
3611 (assoc-ref %outputs "out") "/bin"))
3612 (invoke "py.test" "-m" "not assumption"))))))
3613 (home-page "https://github.com/joeyespo/grip")
3614 (synopsis "Preview Markdown files using the GitHub API")
3615 (description "Grip is a command-line server application written in Python
3616 that uses the GitHub Markdown API to render a local Markdown file. The styles
3617 and rendering come directly from GitHub, so you'll know exactly how it will
3618 appear. Changes you make to the file will be instantly reflected in the browser
3619 without requiring a page refresh.")
3620 (license license:expat))))