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 Ricardo Wurmus <rekado@elephly.net>
9 ;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
10 ;;; Copyright © 2016, 2017 Julien Lepiller <julien@lepiller.eu>
11 ;;; Copyright © 2016, 2017 ng0 <ng0@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>
35 ;;; This file is part of GNU Guix.
37 ;;; GNU Guix is free software; you can redistribute it and/or modify it
38 ;;; under the terms of the GNU General Public License as published by
39 ;;; the Free Software Foundation; either version 3 of the License, or (at
40 ;;; your option) any later version.
42 ;;; GNU Guix is distributed in the hope that it will be useful, but
43 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
44 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
45 ;;; GNU General Public License for more details.
47 ;;; You should have received a copy of the GNU General Public License
48 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
50 (define-module (gnu packages python-web)
51 #:use-module (guix packages)
52 #:use-module (guix download)
53 #:use-module (guix git-download)
54 #:use-module (guix build-system python)
55 #:use-module (guix utils)
56 #:use-module (gnu packages)
57 #:use-module (gnu packages base)
58 #:use-module (gnu packages check)
59 #:use-module (gnu packages compression)
60 #:use-module (gnu packages curl)
61 #:use-module (gnu packages databases)
62 #:use-module (gnu packages django)
63 #:use-module (gnu packages groff)
64 #:use-module (gnu packages libffi)
65 #:use-module (gnu packages pkg-config)
66 #:use-module (gnu packages python)
67 #:use-module (gnu packages python-check)
68 #:use-module (gnu packages python-crypto)
69 #:use-module (gnu packages python-xyz)
70 #:use-module (gnu packages sphinx)
71 #:use-module (gnu packages texinfo)
72 #:use-module (gnu packages tls)
73 #:use-module (gnu packages time)
74 #:use-module (gnu packages web)
75 #:use-module (gnu packages xml)
76 #:use-module ((guix licenses) #:prefix license:)
77 #:use-module (srfi srfi-1))
79 (define-public python-aiohttp
81 (name "python-aiohttp")
86 (uri (pypi-uri "aiohttp" version))
89 "1gy95ni8rkdwzir9zf14ivpfwp02g69xbhibldykff0rzbs86k4w"))))
90 (build-system python-build-system)
92 `(#:tests? #f)) ;missing pytest-timeout
94 `(("python-aiodns" ,python-aiodns)
95 ("python-async-timeout" ,python-async-timeout)
96 ("python-attrs" ,python-attrs)
97 ("python-chardet" ,python-chardet)
98 ("python-idna-ssl" ,python-idna-ssl)
99 ("python-multidict" ,python-multidict)
100 ("python-yarl" ,python-yarl)))
101 (home-page "https://github.com/aio-libs/aiohttp/")
102 (synopsis "Async HTTP client/server framework (asyncio)")
103 (description "@code{aiohttp} is an asynchronous HTTP client/server
106 Its main features are:
108 @item Supports both client and server side of HTTP protocol.
109 @item Supports both client and server Web-Sockets out-of-the-box without the
111 @item Web-server has middlewares and pluggable routing.
113 (license license:asl2.0)))
115 (define-public python-aiohttp-socks
117 (name "python-aiohttp-socks")
122 (uri (pypi-uri "aiohttp_socks" version))
125 "0473702jk66xrgpm28wbdgpnak4v0dh2qmdjw7ky7hf3lwwqkggf"))))
126 (build-system python-build-system)
128 `(("python-aiohttp" ,python-aiohttp)))
129 (home-page "https://github.com/romis2012/aiohttp-socks")
130 (synopsis "SOCKS proxy connector for aiohttp")
131 (description "This package provides a SOCKS proxy connector for
132 aiohttp. It supports SOCKS4(a) and SOCKS5.")
133 (license license:asl2.0)))
135 (define-public python-aiodns
137 (name "python-aiodns")
142 (uri (pypi-uri "aiodns" version))
145 "1snr5paql8dgvc676n8xq460wypjsb1xj53cf3px1s4wczf7lryq"))))
146 (build-system python-build-system)
148 `(("python-pycares" ,python-pycares)))
150 `(#:tests? #f)) ;tests require internet access
151 (home-page "http://github.com/saghul/aiodns")
152 (synopsis "Simple DNS resolver for asyncio")
153 (description "@code{aiodns} provides a simple way for doing
154 asynchronous DNS resolutions with a synchronous looking interface by
155 using @url{https://github.com/saghul/pycares,pycares}.")
156 (license license:expat)))
158 (define-public python-aiorpcx
160 (name "python-aiorpcx")
165 (uri (pypi-uri "aiorpcX" version))
168 "0k545hc7wl6sh1svydzbv6x7sx5pig2pqkl3yxs9riwmvzawx9xp"))))
169 (build-system python-build-system)
171 `(("python-attrs" ,python-attrs)))
172 (home-page "https://github.com/kyuupichan/aiorpcX")
173 (synopsis "Generic asyncio RPC implementation")
175 "The aiorpcX library is a generic asyncio implementation of RPC suitable
176 for an application that is a client, server or both.
178 The package includes a module with full coverage of JSON RPC versions 1.0 and
179 2.0, JSON RPC protocol auto-detection, and arbitrary message framing. It also
180 comes with a SOCKS proxy client.")
181 (license (list license:expat license:bsd-2))))
183 (define-public python-falcon
185 (name "python-falcon")
190 (uri (pypi-uri "falcon" version))
193 "1i0vmqsk24z4biirqhpvas9h28wy7nmpy3jvnb6rz2imq04zd09r"))))
194 (build-system python-build-system)
197 (modify-phases %standard-phases
200 (invoke "pytest"))))))
202 `(("python-mimeparse" ,python-mimeparse)
203 ("python-six" ,python-six)))
205 `(("python-cython" ,python-cython) ;for faster binaries
206 ("python-pytest" ,python-pytest)
207 ("python-pyyaml" ,python-pyyaml)
208 ("python-requests" ,python-requests)
209 ("python-testtools" ,python-testtools)
210 ("python-jsonschema" ,python-jsonschema)
211 ("python-msgpack" ,python-msgpack)))
212 (home-page "https://falconframework.org")
214 "Web framework for building APIs and application backends")
216 "Falcon is a web API framework for building microservices, application
217 backends and higher-level frameworks. Among its features are:
219 @item Optimized and extensible code base
220 @item Routing via URI templates and REST-inspired resource
222 @item Access to headers and bodies through request and response
224 @item Request processing via middleware components and hooks
225 @item Idiomatic HTTP error responses
226 @item Straightforward exception handling
227 @item Unit testing support through WSGI helpers and mocks
228 @item Compatible with both CPython and PyPy
229 @item Cython support for better performance when used with CPython
231 (license license:asl2.0)))
233 (define-public python2-falcon
234 (package-with-python2 python-falcon))
236 (define-public python-falcon-cors
238 (name "python-falcon-cors")
243 (uri (pypi-uri "falcon-cors" version))
246 "12pym7hwsbd8b0c1azn95nas8gm3f1qpr6lpyx0958xm65ffr20p"))))
247 (build-system python-build-system)
249 `(("python-falcon" ,python-falcon)))
251 "https://github.com/lwcolton/falcon-cors")
252 (synopsis "Falcon @dfn{cross-origin resource sharing} (CORS) library")
253 (description "This middleware provides @dfn{cross-origin resource
254 sharing} (CORS) support for Falcon. It allows applying a specially crafted
255 CORS object to the incoming requests, enabling the ability to serve resources
256 over a different origin than that of the web application.")
257 (license license:asl2.0)))
259 (define-public python2-falcon-cors
260 (package-with-python2 python-falcon-cors))
262 (define-public python-furl
269 (uri (pypi-uri "furl" version))
272 "0lzpfpm686hvz3sr1mcrnd1b3lgmnw8v59gb43wfi98r3b671pqc"))))
273 (build-system python-build-system)
275 `(("python-six" ,python-six)
276 ("python-orderedmultidict" ,python-orderedmultidict)))
278 `(("python-pycodestyle" ,python-pycodestyle)))
279 (home-page "https://github.com/gruns/furl")
280 (synopsis "URL manipulation in Python")
281 (description "Furl provides an easy-to-use alternative to the
282 @code{urllib} and @code{urlparse} modules for manipulating URLs.")
283 (license license:unlicense)))
285 (define-public python2-furl
286 (package-with-python2 python-furl))
288 (define-public python-httplib2
290 (name "python-httplib2")
295 (uri (pypi-uri "httplib2" version))
298 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
299 (build-system python-build-system)
300 (home-page "https://github.com/jcgregorio/httplib2")
301 (synopsis "Comprehensive HTTP client library")
303 "A comprehensive HTTP client library supporting many features left out of
304 other HTTP libraries.")
305 (license license:expat)))
307 (define-public python2-httplib2
308 (package-with-python2 python-httplib2))
310 (define-public httpie
317 (uri (pypi-uri "httpie" version))
320 "103fcigpxf4nqmrdqjnyz7d9n4n16906slwmmqqc0gkxv8hnw6vd"))))
321 (build-system python-build-system)
323 ;; The tests attempt to access external web servers, so we cannot run them.
326 `(("python-colorama" ,python-colorama)
327 ("python-pygments" ,python-pygments)
328 ("python-requests" ,python-requests)))
329 (home-page "https://httpie.org/")
330 (synopsis "cURL-like tool for humans")
332 "A command line HTTP client with an intuitive UI, JSON support,
333 syntax highlighting, wget-like downloads, plugins, and more. It consists of
334 a single http command designed for painless debugging and interaction with
335 HTTP servers, RESTful APIs, and web services.")
336 (license license:bsd-3)))
338 (define-public python-html2text
340 (name "python-html2text")
341 (version "2019.8.11")
345 (uri (pypi-uri "html2text" version))
348 "0ppgjplg06kmv9sj0x8p7acczcq2mcfgk1jdjwm4w5w40b0vj5pm"))))
349 (build-system python-build-system)
352 (modify-phases %standard-phases
355 (invoke "pytest" "test/"))))))
357 `(("python-pytest" ,python-pytest)))
358 (home-page "https://github.com/Alir3z4/html2text")
359 (synopsis "Convert HTML into plain text")
360 (description "html2text takes HTML and converts it into plain ASCII text
361 which is also valid markdown. html2text was originally written by Aaron
363 (license license:gpl3+)))
365 (define-public python2-html2text
366 (package-with-python2 python-html2text))
368 (define-public python-mechanicalsoup
370 (name "python-mechanicalsoup")
375 (uri (pypi-uri "MechanicalSoup" version))
377 (base32 "0k59wwk75q7nz6i6gynvzhagy02ql0bv7py3qqcwgjw7607yq4i7"))))
378 (build-system python-build-system)
380 ;; TODO: Enable tests when python-flake8@3.5 hits master.
383 `(("python-beautifulsoup4" ,python-beautifulsoup4)
384 ("python-lxml" ,python-lxml)
385 ("python-requests" ,python-requests)
386 ("python-six" ,python-six)))
389 ;; `(("python-pytest-flake8" ,python-pytest-flake8)
390 ;; ("python-pytest-httpbin" ,python-pytest-httpbin)
391 ;; ("python-pytest-mock" ,python-pytest-mock)
392 ;; ("python-pytest-runner" ,python-pytest-runner)
393 ;; ("python-requests-mock" ,python-requests-mock)))
394 (home-page "https://mechanicalsoup.readthedocs.io/")
395 (synopsis "Python library for automating website interaction")
397 "MechanicalSoup is a Python library for automating interaction with
398 websites. It automatically stores and sends cookies, follows redirects, and can
399 follow links and submit forms. It doesn’t do JavaScript.")
400 (license license:expat)))
402 (define-public python2-mechanicalsoup
403 (package-with-python2 python-mechanicalsoup))
405 (define-public python-sockjs-tornado
407 (name "python-sockjs-tornado")
412 (uri (pypi-uri "sockjs-tornado" version))
415 "15dgv6hw6c7h3m310alw1h6p5443lrm9pyqhcv2smc13fz1v04pc"))))
416 (build-system python-build-system)
418 `(;; There are no tests, and running the test phase requires missing
422 `(("python-tornado" ,python-tornado)))
423 (home-page "https://github.com/mrjoes/sockjs-tornado/")
425 "SockJS Python server implementation on top of the Tornado framework")
427 "SockJS-tornado provides the server-side counterpart to a SockJS client
428 library, through the Tornado framework.
430 SockJS provides a low-latency, full-duplex, cross-domain communication channel
431 between a web browser and web server.")
432 (license license:expat)))
434 (define-public python2-sockjs-tornado
435 (package-with-python2 python-sockjs-tornado))
437 (define-public python-flask-babel
439 (name "python-flask-babel")
444 (uri (pypi-uri "Flask-Babel" version))
447 "0ff9n165vhf1nhv6807ckhpp224jw7k7sd7jz5kfh3sbpl85gmy0"))))
448 (build-system python-build-system)
450 `(("python-flask" ,python-flask)
451 ("python-babel" ,python-babel)
452 ("python-jinja2" ,python-jinja2)
453 ("python-pytz" ,python-pytz)))
454 (home-page "https://github.com/python-babel/flask-babel")
455 (synopsis "Add i18n/l10n support to Flask applications")
456 (description "This package implements internationalization and localization
457 support for Flask. This is based on the Python babel module as well as pytz -
458 both of which are installed automatically if you install this library.")
459 (license license:bsd-3)))
461 (define-public python2-flask-babel
462 (package-with-python2 python-flask-babel))
464 (define-public python-html5lib
466 (name "python-html5lib")
471 (uri (pypi-uri "html5lib" version))
474 "0dipzfrycv6j1jw82v9b7d8lzggx3x8xngx6l4xrqkxwvg7hvjv6"))))
475 (build-system python-build-system)
477 `(("python-six" ,python-six)
478 ("python-webencodings" ,python-webencodings)))
480 `(#:test-target "check"))
482 "https://github.com/html5lib/html5lib-python")
484 "Python HTML parser based on the WHATWG HTML specifcation")
486 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
487 and written in Python.")
488 (license license:expat)))
490 (define-public python2-html5lib
491 (package-with-python2 python-html5lib))
493 ;; Needed for python-bleach, a dependency of python-notebook
494 (define-public python-html5lib-0.9
496 (inherit python-html5lib)
501 (uri (pypi-uri "html5lib" version))
504 "17n4zfsj6ynmbwdwviywmj8r6nzr3xvfx2zs0xhndmvm51z7z263"))))))
506 (define-public python2-html5lib-0.9
507 (package-with-python2 python-html5lib-0.9))
509 (define-public python-html5-parser
511 (name "python-html5-parser")
515 (uri (pypi-uri "html5-parser" version))
518 "01mx33sx4dhl4kj6wc48nj6jz7ry60rkhjv0s6k8h5xmjf5yy0x9"))))
519 (build-system python-build-system)
521 `(("pkg-config" ,pkg-config)))
523 `(("libxml2" ,libxml2)))
525 `(("python-lxml" ,python-lxml)
526 ("python-beautifulsoup4" ,python-beautifulsoup4)))
527 (home-page "https://html5-parser.readthedocs.io")
528 (synopsis "Fast C-based HTML5 parsing for Python")
529 (description "This package provides a fast implementation of the HTML5
530 parsing spec for Python. Parsing is done in C using a variant of the gumbo
531 parser. The gumbo parse tree is then transformed into an lxml tree, also in
532 C, yielding parse times that can be a thirtieth of the html5lib parse times.")
533 ;; src/as-python-tree.[c|h] are licensed GPL3. The other files
534 ;; indicate ASL2.0, including the LICENSE file for the whole project.
535 (license (list license:asl2.0 license:gpl3))))
537 (define-public python2-html5-parser
538 (package-with-python2 python-html5-parser))
540 (define-public python-pycurl
542 (name "python-pycurl")
547 (uri (string-append "https://dl.bintray.com/pycurl/pycurl/pycurl-"
550 (base32 "1915kb04k1j4y6k1dx1sgnbddxrl9r1n4q928if2lkrdm73xy30g"))))
551 (build-system python-build-system)
553 ;; The tests attempt to access external web servers, so we cannot run
554 ;; them. Furthermore, they are skipped altogether when using Python 2.
556 #:phases (modify-phases %standard-phases
557 (add-before 'build 'configure-tls-backend
559 ;; XXX: PycURL fails to automatically determine which TLS
560 ;; backend to use when cURL is built with --disable-static.
561 ;; See setup.py and <https://github.com/pycurl/pycurl/pull/147>.
562 (setenv "PYCURL_SSL_LIBRARY" "gnutls")
565 `(("python-nose" ,python-nose)
566 ("python-bottle" ,python-bottle)))
570 (home-page "http://pycurl.io/")
571 (synopsis "Lightweight Python wrapper around libcurl")
572 (description "Pycurl is a lightweight wrapper around libcurl. It provides
573 high-speed transfers via libcurl and frequently outperforms alternatives.")
575 ;; Per 'README.rst', this is dual-licensed: users can redistribute pycurl
576 ;; under the terms of LGPLv2.1+ or Expat.
577 (license (list license:lgpl2.1+ license:expat))))
579 (define-public python2-pycurl
580 (package-with-python2 python-pycurl))
582 (define-public python-webencodings
584 (name "python-webencodings")
588 (uri (pypi-uri "webencodings" version))
591 "08qrgrc4hrximb2gqnl69g01s93rhf2842jfxdjljc1dbwj1qsmk"))))
592 (build-system python-build-system)
595 (modify-phases %standard-phases
598 (invoke "py.test" "-v" "webencodings/tests.py")
601 `(("python-pytest" ,python-pytest)))
602 (home-page "https://github.com/SimonSapin/python-webencodings")
603 (synopsis "Character encoding aliases for legacy web content")
605 "In order to be compatible with legacy web content when interpreting
606 something like @code{Content-Type: text/html; charset=latin1}, tools need
607 to use a particular set of aliases for encoding labels as well as some
608 overriding rules. For example, @code{US-ASCII} and @code{iso-8859-1} on
609 the web are actually aliases for @code{windows-1252}, and a @code{UTF-8}
610 or @code{UTF-16} BOM takes precedence over any other encoding declaration.
611 The WHATWG @url{https://encoding.spec.whatwg.org/,Encoding} standard
612 defines all such details so that implementations do not have to
613 reverse-engineer each other.
615 This module implements the Encoding standard and has encoding labels and
616 BOM detection, but the actual implementation for encoders and decoders
618 (license license:bsd-3)))
620 (define-public python2-webencodings
621 (package-with-python2 python-webencodings))
623 (define-public python-openid
625 (name "python-openid")
630 (uri (pypi-uri "python3-openid" version))
633 "00l5hrjh19740w00b3fnsqldnla41wbr2rics09dl4kyd1fkd3b2"))))
634 (build-system python-build-system)
637 (modify-phases %standard-phases
640 (invoke "coverage" "run" "-m"
641 "unittest" "openid.test.test_suite"))))))
642 (properties `((python2-variant . ,(delay python2-openid))))
644 `(("python-defusedxml" ,python-defusedxml)))
646 `(("python-coverage" ,python-coverage)
647 ("python-psycopg2" ,python-psycopg2)
648 ("python-django" ,python-django)))
649 (home-page "https://github.com/necaris/python3-openid")
650 (synopsis "OpenID support for servers and consumers")
651 (description "This library provides OpenID authentication for Python, both
652 for clients and servers.")
653 (license license:asl2.0)))
655 (define-public python2-openid
657 (name "python2-openid")
662 (uri (pypi-uri "python-openid" version))
665 "1vvhxlghjan01snfdc4k7ykd80vkyjgizwgg9bncnin8rqz1ricj"))))
666 (build-system python-build-system)
668 ;; Python 3 support is in `python3-openid`, a separate package.
670 ;; Tests aren't initialized correctly.
672 (home-page "https://github.com/openid/python-openid")
673 (synopsis "OpenID support for servers and consumers")
674 (description "This library provides OpenID authentication for Python, both
675 for clients and servers.")
676 (license license:asl2.0)))
678 (define-public python-cssutils
680 (name "python-cssutils")
685 (uri (pypi-uri "cssutils" version))
688 "1bxchrbqzapwijap0yhlxdil1w9bmwvgx77aizlkhc2mcxjg1z52"))))
689 (build-system python-build-system)
691 `(("unzip" ,unzip))) ; for unpacking the source
693 `(#:tests? #f)) ; tests require python-pbr < 1.7.0
694 (home-page "http://cthedot.de/cssutils/")
696 "CSS Cascading Style Sheets library for Python")
698 "Cssutils is a Python package for parsing and building CSS
699 Cascading Style Sheets. Currently it provides a DOM only and no rendering
701 (license license:lgpl3+)))
703 (define-public python2-cssutils
704 (package-with-python2 python-cssutils))
706 (define-public python-css-parser
708 (inherit python-cssutils)
709 (name "python-css-parser")
714 (uri (pypi-uri "css-parser" version ".tar.gz"))
717 "0i4xfykiffxzr4f6y0m2ggqvx1rzam6pw6krlr5k6ldf29akbay7"))))
718 (home-page "https://github.com/ebook-utils/css-parser")
719 (synopsis "Fork of cssutils modified for parsing ebooks")
721 "Css-parser is a fork of cssutils 1.0.2, updated and modified for parsing
722 ebooks, due to cssutils not receiving updates as of 1.0.2.")
723 (license license:lgpl3+)))
725 (define-public python2-css-parser
726 (package-with-python2 python-css-parser))
728 (define-public python-cssselect
730 (name "python-cssselect")
735 (uri (pypi-uri "cssselect" version))
738 "1xg6gbva1yswghiycmgincv6ab4bn7hpm720ndbj40h8xycmnfvi"))))
739 (build-system python-build-system)
741 ;; tests fail with message
742 ;; AttributeError: 'module' object has no attribute 'tests'
745 "https://pythonhosted.org/cssselect/")
747 "CSS3 selector parser and translator to XPath 1.0")
749 "Cssselect ia a Python module that parses CSS3 Selectors and translates
750 them to XPath 1.0 expressions. Such expressions can be used in lxml or
751 another XPath engine to find the matching elements in an XML or HTML document.")
752 (license license:bsd-3)))
754 (define-public python2-cssselect
755 (package-with-python2 python-cssselect))
757 (define-public python-openid-cla
759 (name "python-openid-cla")
764 (uri (pypi-uri "python-openid-cla" version))
767 "102hy2qisvjxp5s0v9lvwqi4f2dk0dhns40vjgn008yxc7k0h3cr"))))
768 (build-system python-build-system)
769 (arguments '(#:tests? #f)) ; No tests.
770 (home-page "https://github.com/puiterwijk/python-openid-cla/")
771 (synopsis "Implementation of the OpenID CLA extension for python-openid")
772 (description "@code{openid-cla} is an implementation of the OpenID
773 contributor license agreement extension for python-openid.")
774 (license license:bsd-3)))
776 (define-public python2-openid-cla
777 (package-with-python2 python-openid-cla))
779 (define-public python-openid-teams
781 (name "python-openid-teams")
786 (uri (pypi-uri "python-openid-teams" version))
789 "05zrh78alav24rxkbqlpbad6d3x2nljk6z6j7kflxf3vdqa7w969"))))
790 (build-system python-build-system)
791 (arguments '(#:tests? #f)) ; No tests.
792 (home-page "https://github.com/puiterwijk/python-openid-teams/")
793 (synopsis "Implementation of the OpenID teams extension for python-openid")
795 "@code{openid-teams} is an implementation of the OpenID
796 teams extension for python-openid.")
797 (license license:bsd-3)))
799 (define-public python2-openid-teams
800 (package-with-python2 python-openid-teams))
802 (define-public python-tornado
804 (name "python-tornado")
809 (uri (pypi-uri "tornado" version))
812 "02clqk2116jbnq8lnaqmdw3p52nqrd9ib59r4xz2ll43fpcmhlaf"))))
813 (build-system python-build-system)
815 '(;; FIXME: Two tests error out with:
816 ;; AssertionError: b'Error in atexit._run_exitfuncs:\nFileNotF[44 chars]ry\n' != b''
818 ;; (modify-phases %standard-phases
821 ;; ;; 'setup.py test' hits an AssertionError on BSD-specific
822 ;; ;; "tornado/platform/kqueue.py". This is the supported method:
823 ;; (invoke "python" "-m" "tornado.test.runtests")
827 `(("python-certifi" ,python-certifi)))
828 (home-page "https://www.tornadoweb.org/")
829 (synopsis "Python web framework and asynchronous networking library")
831 "Tornado is a Python web framework and asynchronous networking library,
832 originally developed at FriendFeed. By using non-blocking network I/O,
833 Tornado can scale to tens of thousands of open connections, making it ideal
834 for long polling, WebSockets, and other applications that require a long-lived
835 connection to each user.")
836 (license license:asl2.0)
837 (properties `((python2-variant . ,(delay python2-tornado))))))
839 (define-public python2-tornado
840 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
841 (package (inherit tornado)
843 `(("python2-backport-ssl-match-hostname"
844 ,python2-backport-ssl-match-hostname)
845 ("python2-backports-abc" ,python2-backports-abc)
846 ("python2-singledispatch" ,python2-singledispatch)
847 ,@(package-propagated-inputs tornado))))))
849 (define-public python-tornado-http-auth
851 (name "python-tornado-http-auth")
856 (uri (pypi-uri "tornado-http-auth" version))
858 (base32 "0hyc5f0a09i5yb99pk4bxpg6w9ichbrb5cv7hc9hff7rxd8w0v0x"))))
859 (build-system python-build-system)
861 `(("python-tornado" ,python-tornado)))
862 (home-page "https://github.com/gvalkov/tornado-http-auth")
863 (synopsis "Digest and basic authentication module for Tornado")
865 "Provides support for adding authentication to services using the Tornado
866 web framework, either via the basic or digest authentication schemes.")
867 (license license:asl2.0)))
869 (define-public python-terminado
871 (name "python-terminado")
876 (uri (pypi-uri "terminado" version))
879 "0yh69k6579g848rmjyllb5h75pkvgcy27r1l3yzgkf33wnnzkasm"))))
880 (build-system python-build-system)
882 `(("python-tornado" ,python-tornado)
883 ("python-ptyprocess" ,python-ptyprocess)))
885 `(("python-nose" ,python-nose)))
888 (modify-phases %standard-phases
890 (lambda _ (invoke "nosetests") #t)))))
891 (home-page "https://github.com/takluyver/terminado")
892 (synopsis "Terminals served to term.js using Tornado websockets")
893 (description "This package provides a Tornado websocket backend for the
894 term.js Javascript terminal emulator library.")
895 (license license:bsd-2)
896 (properties `((python2-variant . ,(delay python2-terminado))))))
898 (define-public python2-terminado
899 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
900 (package (inherit terminado)
902 `(("python2-backport-ssl-match-hostname"
903 ,python2-backport-ssl-match-hostname)
904 ("python2-futures" ,python2-futures)
905 ,@(package-propagated-inputs terminado))))))
907 (define-public python-wsgi-intercept
909 (name "python-wsgi-intercept")
913 (uri (pypi-uri "wsgi_intercept" version))
916 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
917 (build-system python-build-system)
919 `(("python-six" ,python-six)))
921 `(("python-pytest" ,python-pytest)
922 ("python-httplib2" ,python-httplib2)
923 ("python-requests" ,python-requests)
924 ("python-urllib3" ,python-urllib3)))
925 (synopsis "Puts a WSGI application in place of a real URI for testing")
926 (description "Wsgi_intercept installs a WSGI application in place of a real
927 URI for testing. Testing a WSGI application normally involves starting a
928 server at a local host and port, then pointing your test code to that address.
929 Instead, this library lets you intercept calls to any specific host/port
930 combination and redirect them into a WSGI application importable by your test
931 program. Thus, you can avoid spawning multiple processes or threads to test
933 (home-page "https://github.com/cdent/wsgi-intercept")
934 (license license:expat)))
936 (define-public python-webob
938 (name "python-webob")
943 (uri (pypi-uri "WebOb" version))
946 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
947 (build-system python-build-system)
949 `(("python-nose" ,python-nose)))
950 (home-page "https://webob.org/")
951 (synopsis "WSGI request and response object")
953 "WebOb provides wrappers around the WSGI request environment, and an
954 object to help create WSGI responses.")
955 (license license:expat)))
957 (define-public python2-webob
958 (package-with-python2 python-webob))
960 (define-public python-zope-event
962 (name "python-zope-event")
967 (uri (pypi-uri "zope.event" version))
970 "1ksbc726av9xacml6jhcfyn828hlhb9xlddpx6fcvnlvmpmpvhk9"))))
971 (build-system python-build-system)
972 (home-page "https://pypi.python.org/pypi/zope.event")
973 (synopsis "Event publishing system for Python")
974 (description "Zope.event provides an event publishing API, intended for
975 use by applications which are unaware of any subscribers to their events. It
976 is a simple event-dispatching system on which more sophisticated event
977 dispatching systems can be built.")
978 (license license:zpl2.1)))
980 (define-public python2-zope-event
981 (package-with-python2 python-zope-event))
983 (define-public python-zope-interface
985 (name "python-zope-interface")
990 (uri (pypi-uri "zope.interface" version))
993 "1rgh2x3rcl9r0v0499kf78xy86rnmanajf4ywmqb943wpk50sg8v"))))
994 (build-system python-build-system)
996 `(("python-zope-event" ,python-zope-event)))
997 (home-page "https://github.com/zopefoundation/zope.interface")
998 (synopsis "Python implementation of the \"design by contract\"
1000 (description "Zope.interface provides an implementation of \"object
1001 interfaces\" for Python. Interfaces are a mechanism for labeling objects as
1002 conforming to a given API or contract.")
1003 (license license:zpl2.1)))
1005 (define-public python2-zope-interface
1006 (package-with-python2 python-zope-interface))
1008 (define-public python-zope-exceptions
1010 (name "python-zope-exceptions")
1015 (uri (pypi-uri "zope.exceptions" version))
1018 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
1019 (build-system python-build-system)
1021 '(#:tests? #f)) ; circular dependency with zope.testrunner
1023 `(("python-zope-interface" ,python-zope-interface)))
1024 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
1025 (synopsis "Zope exceptions")
1026 (description "Zope.exceptions provides general-purpose exception types
1027 that have uses outside of the Zope framework.")
1028 (license license:zpl2.1)))
1030 (define-public python2-zope-exceptions
1031 (package-with-python2 python-zope-exceptions))
1033 (define-public python-zope-testing
1035 (name "python-zope-testing")
1040 (uri (pypi-uri "zope.testing" version))
1043 "0iiq54hjhkk2gpvzfjac70vyn4r0kw0ngvicshxbdwrkgf2gjq3g"))
1044 (modules '((guix build utils)))
1047 ;; Remove pre-compiled .pyc files backup files from source.
1048 (for-each delete-file (find-files "." "(\\.pyc|~)$"))
1050 (build-system python-build-system)
1051 (home-page "https://pypi.python.org/pypi/zope.testing")
1052 (synopsis "Zope testing helpers")
1053 (description "Zope.testing provides a number of testing utilities for HTML
1054 forms, HTTP servers, regular expressions, and more.")
1055 (license license:zpl2.1)))
1057 (define-public python2-zope-testing
1058 (package-with-python2 python-zope-testing))
1060 (define-public python-zope-testrunner
1062 (name "python-zope-testrunner")
1067 (uri (pypi-uri "zope.testrunner" version ".zip"))
1070 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
1071 (build-system python-build-system)
1073 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1075 `(("python-six" ,python-six)
1076 ;("python-zope-interface" ,python-zope-interface)
1077 ("python-zope-exceptions" ,python-zope-exceptions)
1078 ("python-zope-testing" ,python-zope-testing)
1081 `(("python-zope-interface" ,python-zope-interface)))
1082 (home-page "https://pypi.python.org/pypi/zope.testrunner")
1083 (synopsis "Zope testrunner script")
1084 (description "Zope.testrunner provides a script for running Python
1086 (license license:zpl2.1)))
1088 (define-public python2-zope-testrunner
1089 (let ((base (package-with-python2 python-zope-testrunner)))
1093 (append (package-native-inputs base)
1094 `(("python2-subunit" ,python2-subunit)
1095 ("python2-mimeparse" ,python2-mimeparse)))))))
1097 (define-public python-zope-i18nmessageid
1099 (name "python-zope-i18nmessageid")
1104 (uri (pypi-uri "zope.i18nmessageid" version))
1107 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
1108 (build-system python-build-system)
1109 (home-page "https://pypi.python.org/pypi/zope.i18nmessageid")
1110 (synopsis "Message identifiers for internationalization")
1111 (description "Zope.i18nmessageid provides facilities for declaring
1112 internationalized messages within program source text.")
1113 (license license:zpl2.1)))
1115 (define-public python2-zope-i18nmessageid
1116 (package-with-python2 python-zope-i18nmessageid))
1118 (define-public python-zope-schema
1120 (name "python-zope-schema")
1125 (uri (pypi-uri "zope.schema" version))
1128 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
1129 (build-system python-build-system)
1131 '(#:tests? #f)) ; FIXME: Tests can't find zope.event.
1133 `(("python-zope-event" ,python-zope-event)
1134 ("python-zope-exceptions" ,python-zope-exceptions)
1135 ("python-zope-interface" ,python-zope-interface)))
1137 `(("python-zope-testing" ,python-zope-testing)
1138 ("python-coverage" ,python-coverage)
1139 ("python-nose" ,python-nose)))
1140 (home-page "https://pypi.python.org/pypi/zope.schema")
1141 (synopsis "Zope data schemas")
1142 (description "Zope.scheme provides extensions to zope.interface for
1143 defining data schemas.")
1144 (license license:zpl2.1)))
1146 (define-public python2-zope-schema
1147 (package-with-python2 python-zope-schema))
1149 (define-public python-zope-configuration
1151 (name "python-zope-configuration")
1155 (uri (pypi-uri "zope.configuration" version))
1158 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
1159 (build-system python-build-system)
1161 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1163 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1164 ("python-zope-schema" ,python-zope-schema)))
1165 (home-page "https://pypi.python.org/pypi/zope.configuration")
1166 (synopsis "Zope Configuration Markup Language")
1167 (description "Zope.configuration implements ZCML, the Zope Configuration
1169 (license license:zpl2.1)))
1171 (define-public python2-zope-configuration
1172 (package-with-python2 python-zope-configuration))
1174 (define-public python-zope-proxy
1176 (name "python-zope-proxy")
1181 (uri (pypi-uri "zope.proxy" version))
1184 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
1185 (build-system python-build-system)
1187 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1189 `(("python-zope-interface" ,python-zope-interface)))
1190 (home-page "https://pypi.python.org/pypi/zope.proxy")
1191 (synopsis "Generic, transparent proxies")
1192 (description "Zope.proxy provides generic, transparent proxies for Python.
1193 Proxies are special objects which serve as mostly-transparent wrappers around
1194 another object, intervening in the apparent behavior of the wrapped object
1195 only when necessary to apply the policy (e.g., access checking, location
1196 brokering, etc.) for which the proxy is responsible.")
1197 (license license:zpl2.1)))
1199 (define-public python2-zope-proxy
1200 (package-with-python2 python-zope-proxy))
1202 (define-public python-zope-location
1204 (name "python-zope-location")
1209 (uri (pypi-uri "zope.location" version))
1212 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
1213 (build-system python-build-system)
1215 '(#:tests? #f)) ; FIXME: Tests can't find zope.interface.
1217 `(("python-zope-proxy" ,python-zope-proxy)
1218 ("python-zope-schema" ,python-zope-schema)))
1219 (home-page "https://pypi.python.org/pypi/zope.location/")
1220 (synopsis "Zope location library")
1221 (description "Zope.location implements the concept of \"locations\" in
1222 Zope3, which are are special objects that have a structural location.")
1223 (license license:zpl2.1)))
1225 (define-public python2-zope-location
1226 (package-with-python2 python-zope-location))
1228 (define-public python-zope-security
1230 (name "python-zope-security")
1235 (uri (pypi-uri "zope.security" version))
1238 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
1239 (build-system python-build-system)
1241 '(#:tests? #f)) ; FIXME: Tests can't find zope.testrunner.
1243 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1244 ("python-zope-proxy" ,python-zope-proxy)
1245 ("python-zope-schema" ,python-zope-schema)))
1247 `(("python-six" ,python-six)
1248 ("python-zope-component" ,python-zope-component)
1249 ("python-zope-configuration" ,python-zope-configuration)
1250 ("python-zope-location" ,python-zope-location)
1251 ("python-zope-testrunner" ,python-zope-testrunner)
1252 ("python-zope-testing" ,python-zope-testing)))
1253 (home-page "https://pypi.python.org/pypi/zope.security")
1254 (synopsis "Zope security framework")
1255 (description "Zope.security provides a generic mechanism to implement
1256 security policies on Python objects.")
1257 (license license:zpl2.1)))
1259 (define-public python2-zope-security
1260 (let ((zope-security (package-with-python2 python-zope-security)))
1261 (package (inherit zope-security)
1263 `(("python2-zope-testrunner" ,python2-zope-testrunner)
1265 "python-zope-testrunner"
1266 (package-propagated-inputs zope-security)))))))
1268 (define-public python-zope-component
1270 (name "python-zope-component")
1275 (uri (pypi-uri "zope.component" version))
1278 "1hlvzwj1kcfz1qms1dzhwsshpsf38z9clmyksb1gh41n8k3kchdv"))))
1279 (build-system python-build-system)
1281 ;; Skip tests due to circular dependency with python-zope-security.
1284 `(("python-zope-testing" ,python-zope-testing)))
1286 `(("python-zope-event" ,python-zope-event)
1287 ("python-zope-interface" ,python-zope-interface)
1288 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
1289 ("python-zope-configuration" ,python-zope-configuration)))
1290 (home-page "https://github.com/zopefoundation/zope.component")
1291 (synopsis "Zope Component Architecture")
1292 (description "Zope.component represents the core of the Zope Component
1293 Architecture. Together with the zope.interface package, it provides
1294 facilities for defining, registering and looking up components.")
1295 (license license:zpl2.1)))
1297 (define-public python2-zope-component
1298 (package-with-python2 python-zope-component))
1300 (define-public python-ndg-httpsclient
1302 (name "python-ndg-httpsclient")
1306 (uri (pypi-uri "ndg_httpsclient" version))
1309 "0412b7i1s4vj7lz9r72nmb28h9syd4q2x89bdirkkc3a6z8awbyp"))))
1310 (build-system python-build-system)
1312 '(;; The tests appear to require networking.
1315 `(("python-pyopenssl" ,python-pyopenssl)))
1316 (synopsis "HTTPS support for Python's httplib and urllib2")
1317 (description "This is a HTTPS client implementation for httplib and urllib2
1318 based on PyOpenSSL. PyOpenSSL provides a more fully-featured SSL implementation
1319 over the default provided with Python and, importantly, enables full
1320 verification of the SSL peer.")
1321 (home-page "https://github.com/cedadev/ndg_httpsclient/")
1322 (license license:bsd-3)))
1324 ;; python2-openssl requires special care, so package-with-python2 is
1326 (define-public python2-ndg-httpsclient
1327 (package (inherit python-ndg-httpsclient)
1328 (name "python2-ndg-httpsclient")
1330 (substitute-keyword-arguments (package-arguments python-ndg-httpsclient)
1331 ((#:python _) python-2)))
1333 `(("python2-pyopenssl" ,python2-pyopenssl)))))
1335 (define-public python-websocket-client
1337 (name "python-websocket-client")
1342 (uri (pypi-uri "websocket_client" version))
1345 "0j88zmikaypf38lvpkf4aaxrjp9j07dmy5ghj7kli0fv3p4n45g5"))))
1346 (build-system python-build-system)
1348 `(("python-six" ,python-six)))
1349 (home-page "https://github.com/liris/websocket-client")
1350 (synopsis "WebSocket client for Python")
1351 (description "The Websocket-client module provides the low level APIs for
1352 WebSocket usage in Python programs.")
1353 (properties `((python2-variant . ,(delay python2-websocket-client))))
1354 (license license:lgpl2.1+)))
1356 (define-public python2-websocket-client
1357 (let ((base (package-with-python2
1358 (strip-python2-variant python-websocket-client))))
1362 `(("python2-backport-ssl-match-hostname"
1363 ,python2-backport-ssl-match-hostname)
1364 ,@(package-native-inputs base))))))
1366 (define-public python-requests
1368 (name "python-requests")
1372 (uri (pypi-uri "requests" version))
1375 "1d5ybh11jr5sm7xp6mz8fyc7vrp4syifds91m7sj60xalal0gq0i"))))
1376 (build-system python-build-system)
1378 `(("python-certifi" ,python-certifi)
1379 ("python-chardet" ,python-chardet)
1380 ("python-idna" ,python-idna)
1381 ("python-urllib3" ,python-urllib3)))
1383 ;; FIXME: Some tests require network access.
1385 (home-page "http://python-requests.org/")
1386 (synopsis "Python HTTP library")
1388 "Requests is a Python HTTP client library. It aims to be easier to use
1389 than Python’s urllib2 library.")
1390 (license license:asl2.0)))
1392 ;; Some software requires an older version of Requests, notably Docker/Docker
1394 (define-public python-requests-2.20
1395 (package (inherit python-requests)
1399 (uri (pypi-uri "requests" version))
1402 "0qzj6cgv3k9wyj7wlxgz7xq0cfg4jbbkfm24pp8dnhczwl31527a"))))
1404 `(("python-urllib3" ,python-urllib3-1.24)
1405 ("python-idna" ,python-idna-2.7)
1406 ,@(package-propagated-inputs python-requests)))))
1408 ;; Some software requires an older version of Requests, notably Docker
1410 (define-public python-requests-2.7
1411 (package (inherit python-requests)
1415 (uri (pypi-uri "requests" version))
1418 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
1420 (define-public python2-requests
1421 (package-with-python2 python-requests))
1423 (define-public python-requests-mock
1425 (name "python-requests-mock")
1430 (uri (pypi-uri "requests-mock" version))
1433 "0jr997dvk6zbmhvbpcv3rajrgag69mcsm1ai3w3rgk2jdh6rg1mx"))))
1434 (build-system python-build-system)
1436 `(("python-requests" ,python-requests)
1437 ("python-six" ,python-six)))
1439 `(("python-pbr" ,python-pbr)
1440 ("python-discover" ,python-discover)
1441 ("python-docutils" ,python-docutils)
1442 ("python-fixtures" ,python-fixtures)
1443 ("python-mock" ,python-mock)
1444 ("python-sphinx" ,python-sphinx)
1445 ("python-testrepository" ,python-testrepository)
1446 ("python-testtools" ,python-testtools)))
1447 (home-page "https://requests-mock.readthedocs.org/")
1448 (synopsis "Mock out responses from the requests package")
1450 "This module provides a building block to stub out the HTTP requests
1451 portions of your testing code.")
1452 (properties `((python2-variant . ,(delay python2-requests-mock))))
1453 (license license:asl2.0)))
1455 (define-public python2-requests-mock
1456 (package (inherit (package-with-python2
1457 (strip-python2-variant python-requests-mock)))
1459 `(#:python ,python-2
1460 ;; FIXME: 'subunit.run discover: error: no such option: --list'
1463 (define-public python-requests-toolbelt
1465 (name "python-requests-toolbelt")
1469 (uri (pypi-uri "requests-toolbelt" version))
1472 "1dc7l42i4080r8i4m9fj51jx367lqkai170vrv7wd93gdj9k39gn"))))
1473 (build-system python-build-system)
1475 `(("python-betamax" ,python-betamax)
1476 ("python-mock" ,python-mock)
1477 ("python-pytest" ,python-pytest)))
1479 `(("python-requests" ,python-requests)))
1480 (synopsis "Extensions to python-requests")
1481 (description "This is a toolbelt of useful classes and functions to be used
1482 with python-requests.")
1483 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
1484 (license license:asl2.0)))
1486 (define-public python2-requests-toolbelt
1487 (package-with-python2 python-requests-toolbelt))
1489 (define-public python-oauthlib
1491 (name "python-oauthlib")
1495 (uri (pypi-uri "oauthlib" version))
1498 "163jg4a8f7c5ki655grrr47kgljy12wri3qly7ijf64sk1fjrqqc"))))
1499 (build-system python-build-system)
1501 `(#:phases (modify-phases %standard-phases
1504 (invoke "pytest" "-vv"))))))
1506 `(("python-pytest" ,python-pytest)
1507 ("python-pytest-cov" ,python-pytest-cov)
1508 ("python-mock" ,python-mock)))
1510 `(("python-cryptography" ,python-cryptography)
1511 ("python-pyjwt" ,python-pyjwt)
1512 ("python-blinker" ,python-blinker)))
1513 (home-page "https://github.com/oauthlib/oauthlib")
1514 (synopsis "OAuth implementation for Python")
1516 "Oauthlib is a generic, spec-compliant, thorough implementation of the
1517 OAuth request-signing logic.")
1518 (license license:bsd-3)))
1520 (define-public python2-oauthlib
1521 (package-with-python2 python-oauthlib))
1523 (define-public python-rauth
1525 (name "python-rauth")
1530 (uri (pypi-uri "rauth" version))
1533 "02kv8w8l98ky223avyq7vw7x1f2ya9chrm59r77ylq45qb0xnk2j"))))
1534 (build-system python-build-system)
1536 `(#:test-target "check"))
1538 `(("python-requests" ,python-requests)))
1539 (home-page "https://github.com/litl/rauth")
1540 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
1542 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
1543 provides service wrappers for convenient connection initialization and
1544 authenticated session objects providing things like keep-alive.")
1545 (license license:expat)
1546 (properties `((python2-variant . ,(delay python2-rauth))))))
1548 (define-public python2-rauth
1549 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
1552 (native-inputs `(("python2-unittest2" ,python2-unittest2)
1553 ,@(package-native-inputs base))))))
1555 (define-public python-urllib3
1557 (name "python-urllib3")
1562 (uri (pypi-uri "urllib3" version))
1565 "0cij8qcvvpj62g1q8n785qjkdymfh4b7vf45si4sw64l41rr3rfv"))))
1566 (build-system python-build-system)
1567 (arguments `(#:tests? #f))
1569 `(;; These 5 inputs are used to build urrlib3[secure]
1570 ("python-certifi" ,python-certifi)
1571 ("python-cryptography" ,python-cryptography)
1572 ("python-idna" ,python-idna)
1573 ("python-ipaddress" ,python-ipaddress)
1574 ("python-pyopenssl" ,python-pyopenssl)
1575 ("python-pysocks" ,python-pysocks)))
1576 (home-page "https://urllib3.readthedocs.io/")
1577 (synopsis "HTTP library with thread-safe connection pooling")
1579 "Urllib3 supports features left out of urllib and urllib2 libraries. It
1580 can reuse the same socket connection for multiple requests, it can POST files,
1581 supports url redirection and retries, and also gzip and deflate decoding.")
1582 (license license:expat)))
1584 ;; Some software requires an older version of urllib3, notably Docker.
1585 (define-public python-urllib3-1.24
1586 (package (inherit python-urllib3)
1590 (uri (pypi-uri "urllib3" version))
1593 "1x0slqrv6kixkbcdnxbglvjliwhc1payavxjvk8fvbqjrnasd4r3"))))))
1596 (define-public python2-urllib3
1597 (package-with-python2 python-urllib3))
1599 (define-public awscli
1606 (uri (pypi-uri name version))
1609 "0sispclx263lybbk19zp1n9yhg8xxx4jddypzgi24vpjaqnsbwlc"))))
1610 (build-system python-build-system)
1612 ;; FIXME: The 'pypi' release does not contain tests.
1615 (modify-phases %standard-phases
1616 (add-after 'unpack 'fix-reference-to-groff
1618 (substitute* "awscli/help.py"
1619 (("if not self._exists_on_path\\('groff'\\):") "")
1620 (("raise ExecutableNotFoundError\\('groff'\\)") "")
1621 (("cmdline = \\['groff'")
1622 (string-append "cmdline = ['" (which "groff") "'")))
1625 `(("python-colorama" ,python-colorama)
1626 ("python-botocore" ,python-botocore)
1627 ("python-s3transfer" ,python-s3transfer)
1628 ("python-docutils" ,python-docutils)
1629 ("python-pyyaml" ,python-pyyaml)
1630 ("python-rsa" ,python-rsa)))
1632 `(("groff" ,groff)))
1633 (home-page "https://aws.amazon.com/cli/")
1634 (synopsis "Command line client for AWS")
1635 (description "AWS CLI provides a unified command line interface to the
1636 Amazon Web Services (AWS) API.")
1637 (license license:asl2.0)))
1639 (define-public python-wsgiproxy2
1641 (name "python-wsgiproxy2")
1646 (uri (pypi-uri "WSGIProxy2" version ".tar.gz"))
1648 (base32 "16jch5nic0hia28lps3c678s9s9mjdq8n87igxncjg0rpi5adqnf"))))
1649 (build-system python-build-system)
1651 `(("python-webtest" ,python-webtest)))
1653 `(("python-requests" ,python-requests)
1654 ("python-six" ,python-six)
1655 ("python-urllib3" ,python-urllib3)
1656 ("python-webob" ,python-webob)))
1657 (home-page "https://github.com/gawel/WSGIProxy2/")
1658 (synopsis "WSGI Proxy with various http client backends")
1659 (description "WSGI turns HTTP requests into WSGI function calls.
1660 WSGIProxy turns WSGI function calls into HTTP requests.
1661 It also includes code to sign requests and pass private data,
1662 and to spawn subprocesses to handle requests.")
1663 (license license:expat)))
1665 (define-public python2-wsgiproxy2
1666 (package-with-python2 python-wsgiproxy2))
1668 (define-public python-pastedeploy
1670 (name "python-pastedeploy")
1675 (uri (pypi-uri "PasteDeploy" version))
1678 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
1679 (build-system python-build-system)
1681 `(("python-nose" ,python-nose)))
1682 (home-page "https://pylonsproject.org/")
1684 "Load, configure, and compose WSGI applications and servers")
1686 "This tool provides code to load WSGI applications and servers from URIs;
1687 these URIs can refer to Python Eggs for INI-style configuration files. Paste
1688 Script provides commands to serve applications based on this configuration
1690 (license license:expat)))
1692 (define-public python2-pastedeploy
1693 (package-with-python2 python-pastedeploy))
1695 (define-public python-webtest
1697 (name "python-webtest")
1702 (uri (pypi-uri "WebTest" version))
1705 "1l3z0cwqslsf4rcrhi2gr8kdfh74wn2dw76376i4g9i38gz8wd21"))))
1706 (build-system python-build-system)
1708 ;; Tests require python-pyquery, which creates a circular dependency.
1711 `(("python-waitress" ,python-waitress)
1712 ("python-webob" ,python-webob)
1713 ("python-six" ,python-six)
1714 ("python-beautifulsoup4" ,python-beautifulsoup4)))
1715 (home-page "https://docs.pylonsproject.org/projects/webtest/")
1716 (synopsis "Helper to test WSGI applications")
1717 (description "Webtest allows you to test your Python web applications
1718 without starting an HTTP server. It supports anything that supports the
1720 (license license:expat)))
1722 (define-public python2-webtest
1723 (package-with-python2 python-webtest))
1725 (define-public python-flask
1727 (name "python-flask")
1731 (uri (pypi-uri "Flask" version))
1734 "1wxnhjlxwwjhjxmghykjhllpahv5pkdc5hln4ab6nab43s26sz5d"))))
1735 (build-system python-build-system)
1738 (modify-phases %standard-phases
1741 (invoke "python" "-m" "pytest"))))))
1743 `(("python-pytest" ,python-pytest)))
1745 `(("python-itsdangerous" ,python-itsdangerous)
1746 ("python-jinja2" ,python-jinja2)
1747 ("python-click" ,python-click)
1748 ("python-werkzeug" ,python-werkzeug)))
1749 (home-page "https://www.palletsprojects.com/p/flask/")
1750 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
1751 (description "Flask is a micro web framework based on the Werkzeug toolkit
1752 and Jinja2 template engine. It is called a micro framework because it does not
1753 presume or force a developer to use a particular tool or library.")
1754 (license license:bsd-3)))
1756 (define-public python2-flask
1757 (package-with-python2 python-flask))
1759 (define-public python-flask-wtf
1761 (name "python-flask-wtf")
1766 (uri (pypi-uri "Flask-WTF" version))
1769 "04l5743j2dici46038sqlzvf0xzpg8rf7s9ld2x24xv7f4idg990"))))
1770 (build-system python-build-system)
1773 (modify-phases %standard-phases
1774 (add-before 'check 'drop-failing-test
1776 ;; FIXME: This file tries resolving an external server, which
1777 ;; fails. Try to patch out the offending section instead of
1778 ;; deleting the whole thing.
1779 (delete-file "tests/test_recaptcha.py")
1782 `(("python-flask-babel" ,python-flask-babel)
1783 ("python-babel" ,python-babel)
1784 ("python-wtforms" ,python-wtforms)))
1786 `(("python-nose" ,python-nose)))
1787 (home-page "https://github.com/lepture/flask-wtf")
1788 (synopsis "Simple integration of Flask and WTForms")
1789 (description "Flask-WTF integrates Flask and WTForms, including CSRF, file
1790 upload, and reCAPTCHA.")
1791 (license license:bsd-3)))
1793 (define-public python2-flask-wtf
1794 (package-with-python2 python-flask-wtf))
1796 (define-public python-flask-multistatic
1798 (name "python-flask-multistatic")
1803 (uri (pypi-uri "flask-multistatic" version))
1806 "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm"))))
1807 (build-system python-build-system)
1809 `(("python-flask" ,python-flask)))
1810 (home-page "https://pagure.io/flask-multistatic")
1811 (synopsis "Flask plugin to allow overriding static files")
1812 (description "@code{flask-multistatic} is a flask plugin that adds support
1813 for overriding static files.")
1814 (license license:gpl3+)))
1816 (define-public python2-flask-multistatic
1817 (package-with-python2 python-flask-multistatic))
1819 (define-public python-cookies
1821 (name "python-cookies")
1825 (uri (pypi-uri "cookies" version))
1828 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
1829 (build-system python-build-system)
1831 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
1834 `(("python-pytest" ,python2-pytest)))
1835 (synopsis "HTTP cookie parser and renderer")
1836 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
1838 (home-page "https://gitlab.com/sashahart/cookies")
1839 (license license:expat)))
1841 (define-public python2-cookies
1842 (package-with-python2 python-cookies))
1844 (define-public python-responses
1846 (name "python-responses")
1850 (uri (pypi-uri "responses" version))
1853 "147pacwkkqy3qf3hr33fnl1xbzgw0zsm3qppvvy9qhq8h069qbah"))))
1854 (build-system python-build-system)
1856 `(;; Test suite is not distributed:
1857 ;; https://github.com/getsentry/responses/issues/38
1860 `(("python-mock" ,python-mock)))
1862 `(("python-requests" ,python-requests)
1863 ("python-cookies" ,python-cookies)
1864 ("python-six" ,python-six)))
1865 (home-page "https://github.com/getsentry/responses")
1866 (synopsis "Utility for mocking out the `requests` Python library")
1867 (description "A utility library for mocking out the `requests` Python
1869 (license license:asl2.0)))
1871 (define-public python2-responses
1872 (package-with-python2 python-responses))
1874 (define-public python-grequests
1876 (name "python-grequests")
1881 (uri (pypi-uri "grequests" version))
1884 "1j9icncllbkv7x5719b20mx670c6q1jrdx1sakskkarvx3pc8h8g"))))
1885 (build-system python-build-system)
1887 `(("python-gevent" ,python-gevent)
1888 ("python-requests" ,python-requests)))
1890 `(("python-nose" ,python-nose)))
1891 (home-page "https://github.com/kennethreitz/grequests")
1892 (synopsis "Python library for asynchronous HTTP requests")
1893 (description "GRequests is a Python library that allows you to use
1894 @code{Requests} with @code{Gevent} to make asynchronous HTTP Requests easily")
1895 (license license:bsd-2)))
1897 (define-public python-geventhttpclient
1899 (name "python-geventhttpclient")
1903 (uri (pypi-uri "geventhttpclient" version))
1906 "07d0q3wzmml75227r6y6mrl5a0zpf4v9gj0ni5rhbyzmaj4az1xx"))
1907 (modules '((guix build utils)))
1910 ;; Delete pre-compiled files.
1911 (for-each delete-file (find-files "src/geventhttpclient"
1914 (build-system python-build-system)
1917 (modify-phases %standard-phases
1918 (add-after 'unpack 'delete-network-tests
1920 (delete-file "src/geventhttpclient/tests/test_client.py")
1923 (add-after 'install 'check
1924 (lambda* (#:key inputs outputs #:allow-other-keys)
1925 (add-installed-pythonpath inputs outputs)
1926 (invoke "py.test" "src/geventhttpclient/tests" "-v"
1927 ;; Append the test modules to sys.path to avoid
1928 ;; namespace conflict which breaks SSL tests.
1929 "--import-mode=append")
1932 `(("python-pytest" ,python-pytest)))
1934 `(("python-certifi" ,python-certifi)
1935 ("python-gevent" ,python-gevent)
1936 ("python-six" ,python-six)))
1937 (home-page "https://github.com/gwik/geventhttpclient")
1938 (synopsis "HTTP client library for gevent")
1939 (description "@code{python-geventhttpclient} is a high performance,
1940 concurrent HTTP client library for python using @code{gevent}.")
1941 (license license:expat)))
1943 (define-public python2-geventhttpclient
1944 (package-with-python2 python-geventhttpclient))
1946 (define-public python-requests-oauthlib
1948 (name "python-requests-oauthlib")
1953 (uri (pypi-uri "requests-oauthlib" version))
1956 "0mrglgcvq7k48pf27s4gifdk0za8xmgpf55jy15yjj471qrk6rdx"))))
1957 (build-system python-build-system)
1960 (modify-phases %standard-phases
1961 ;; removes tests that require network access
1962 (add-before 'check 'pre-check
1964 (delete-file "tests/test_core.py")
1967 `(("python-pyjwt" ,python-pyjwt)
1968 ("python-requests-mock" ,python-requests-mock)
1969 ("python-mock" ,python-mock)))
1971 `(("python-oauthlib" ,python-oauthlib)
1972 ("python-requests" ,python-requests)))
1974 "https://github.com/requests/requests-oauthlib")
1976 "OAuthlib authentication support for Requests")
1978 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
1979 provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
1980 (license license:isc)))
1982 (define-public python2-requests-oauthlib
1983 (package-with-python2 python-requests-oauthlib))
1985 (define-public python-url
1991 (uri (pypi-uri "url" version))
1994 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
1995 (build-system python-build-system)
1997 `(("python-publicsuffix" ,python-publicsuffix)))
1999 `(("python-coverage" ,python-coverage)
2000 ("python-nose" ,python-nose)))
2002 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
2003 (home-page "https://github.com/seomoz/url-py")
2004 (synopsis "URL Parsing")
2005 (description "Library for parsing urls.")
2006 (license license:expat)
2007 (properties `((python2-variant . ,(delay python2-url))))))
2009 (define-public python2-url
2010 (let ((base (package-with-python2 (strip-python2-variant python-url))))
2011 (package (inherit base)
2013 `(("python2-publicsuffix" ,python2-publicsuffix))))))
2015 (define-public python-cachecontrol
2017 (name "python-cachecontrol")
2022 ;; Pypi does not have tests.
2024 (url "https://github.com/ionrock/cachecontrol")
2025 (commit (string-append "v" version))))
2026 (file-name (git-file-name name version))
2029 "03lgc65sl04n0cgzmmgg99bk83f9i6k8yrmcd4hpl46q1pymn0kz"))))
2030 (build-system python-build-system)
2032 ;; Versions > 0.11.6 depend on CherryPy for testing.
2033 ;; It's too much work to package CherryPy for now.
2036 `(("python-requests" ,python-requests)
2037 ("python-lockfile" ,python-lockfile)))
2038 (home-page "https://github.com/ionrock/cachecontrol")
2039 (synopsis "The httplib2 caching algorithms for use with requests")
2040 (description "CacheControl is a port of the caching algorithms in
2041 @code{httplib2} for use with @code{requests} session objects.")
2042 (license license:asl2.0)))
2044 (define-public python2-cachecontrol
2045 (package-with-python2 python-cachecontrol))
2047 (define-public python-betamax
2049 (name "python-betamax")
2054 (uri (pypi-uri "betamax" version))
2057 "1hki1c2vs7adq7zr56wi6i5bhrkia4s2ywpv2c98ibnczz709w2v"))))
2058 (build-system python-build-system)
2060 '(;; Many tests fail because they require networking.
2063 `(("python-requests" ,python-requests)))
2064 (home-page "https://github.com/sigmavirus24/betamax")
2065 (synopsis "Record HTTP interactions with python-requests")
2066 (description "Betamax will record your test suite's HTTP interactions and
2067 replay them during future tests. It is designed to work with python-requests.")
2068 (license license:expat)))
2070 (define-public python2-betamax
2071 (package-with-python2 python-betamax))
2073 (define-public python-betamax-matchers
2075 (name "python-betamax-matchers")
2080 (uri (pypi-uri "betamax-matchers" version))
2083 "07qpwjyq2i2aqhz5iwghnj4pqr2ys5n45v1vmpcfx9r5mhwrsq43"))))
2084 (build-system python-build-system)
2086 `(("python-betamax" ,python-betamax)
2087 ("python-requests-toolbelt" ,python-requests-toolbelt)))
2088 (home-page "https://github.com/sigmavirus24/betamax_matchers")
2089 (synopsis "VCR imitation for python-requests")
2090 (description "@code{betamax-matchers} provides a set of Matchers for
2092 (license license:asl2.0)))
2094 (define-public python2-betamax-matchers
2095 (package-with-python2 python-betamax-matchers))
2097 (define-public python-s3transfer
2099 (name "python-s3transfer")
2103 (uri (pypi-uri "s3transfer" version))
2106 "08fhj73b1ai52hrs2q3nggshq3pswn1gq8ch3m009cb2v2vmqggj"))))
2107 (build-system python-build-system)
2110 (modify-phases %standard-phases
2113 ;; Some of the 'integration' tests require network access or
2114 ;; login credentials.
2115 (invoke "nosetests" "--exclude=integration")
2118 `(("python-docutils" ,python-docutils)
2119 ("python-mock" ,python-mock)
2120 ("python-nose" ,python-nose)))
2122 `(("python-botocore" ,python-botocore)
2123 ("python-urllib3" ,python-urllib3)))
2124 (synopsis "Amazon S3 Transfer Manager")
2125 (description "S3transfer is a Python library for managing Amazon S3
2127 (home-page "https://github.com/boto/s3transfer")
2128 (license license:asl2.0)
2129 (properties `((python2-variant . ,(delay python2-s3transfer))))))
2131 (define-public python2-s3transfer
2132 (let ((base (package-with-python2 (strip-python2-variant python-s3transfer))))
2136 `(("python2-futures" ,python2-futures)
2137 ,@(package-native-inputs base))))))
2139 (define-public python-slimit
2141 (name "python-slimit")
2146 (uri (pypi-uri "slimit" version ".zip"))
2149 "02vj2x728rs1127q2nc27frrqra4fczivnb7gch6n5lzi7pxqczl"))))
2150 (build-system python-build-system)
2152 `(("unzip" ,unzip)))
2154 `(("python-ply" ,python-ply)))
2155 (home-page "https://slimit.readthedocs.io/")
2156 (synopsis "JavaScript minifier, parser and lexer written in Python")
2158 "SlimIt is a JavaScript minifier written in Python. It compiles
2159 JavaScript into more compact code so that it downloads and runs faster.
2160 SlimIt also provides a library that includes a JavaScript parser, lexer,
2161 pretty printer and a tree visitor.")
2162 (license license:expat)))
2164 (define-public python-flask-restful
2166 (name "python-flask-restful")
2171 (uri (pypi-uri "Flask-RESTful" version))
2174 "1a9cbwkr6krryyzq4sd3f415nkkc6dyfls5i3pgyibs94g0hw97q"))))
2175 (build-system python-build-system)
2177 `(("python-aniso8601" ,python-aniso8601)
2178 ("python-flask" ,python-flask)
2179 ("python-pycrypto" ,python-pycrypto)
2180 ("python-pytz" ,python-pytz)))
2182 `(;; Optional dependency of Flask. Tests need it.
2183 ("python-blinker" ,python-blinker)
2184 ("python-mock" ,python-mock) ; For tests
2185 ("python-nose" ,python-nose) ; For tests
2186 ("python-sphinx" ,python-sphinx)))
2188 "https://www.github.com/flask-restful/flask-restful/")
2190 "Flask module for creating REST APIs")
2192 "This package contains a Flask module for creating REST APIs.")
2193 (license license:bsd-3)))
2195 (define-public python-flask-basicauth
2197 (name "python-flask-basicauth")
2202 (uri (pypi-uri "Flask-BasicAuth" version))
2205 "1zq1spkjr4sjdnalpp8wl242kdqyk6fhbnhr8hi4r4f0km4bspnz"))))
2206 (build-system python-build-system)
2208 `(("python-flask" ,python-flask)))
2210 "https://github.com/jpvanhal/flask-basicauth")
2212 "HTTP basic access authentication for Flask")
2214 "This package provides HTTP basic access authentication for Flask.")
2215 (license license:bsd-3)))
2217 (define-public python-flask-htpasswd
2219 (name "python-flask-htpasswd")
2224 (uri (pypi-uri "flask-htpasswd" version))
2227 "14q1y1y9i9bhabdnwd25jqzc4ljli23smxfyyh8abxz1vq93pxra"))))
2228 (build-system python-build-system)
2230 `(("python-flask" ,python-flask)
2231 ("python-itsdangerous" ,python-itsdangerous)
2232 ("python-passlib" ,python-passlib)
2233 ("python-tox" ,python-tox)))
2234 (home-page "http://github.com/carsongee/flask-htpasswd")
2235 (synopsis "Basic authentication via htpasswd files in Flask applications")
2236 (description "This package provides Basic authentication via
2237 @file{htpasswd} files and access_token authentication in Flask
2239 (license license:bsd-3)))
2241 (define-public python-flask-sqlalchemy
2243 (name "python-flask-sqlalchemy")
2247 (uri (pypi-uri "Flask-SQLAlchemy" version))
2250 "0nnllf0ddbh9jlhngnyjj98lbxgxr1csaplllx0caw98syq0k5hc"))))
2251 (build-system python-build-system)
2253 `(("python-flask" ,python-flask)
2254 ("python-sqlalchemy" ,python-sqlalchemy)))
2255 (home-page "https://github.com/mitsuhiko/flask-sqlalchemy")
2256 (synopsis "Module adding SQLAlchemy support to your Flask application")
2258 "This package adds SQLAlchemy support to your Flask application.")
2259 (license license:bsd-3)))
2261 (define-public python-flask-restplus
2263 (name "python-flask-restplus")
2268 (uri (pypi-uri "flask-restplus" version))
2271 "11his6ii5brpkhld0d5bwzjjw4q3vmplpd6fmgzjrvvklsbk0cf4"))))
2272 (build-system python-build-system)
2274 '(#:tests? #f)) ; FIXME: 35/882 tests failing.
2276 ;; (modify-phases %standard-phases
2279 ;; (invoke "nosetests")
2282 `(("python-aniso8601" ,python-aniso8601)
2283 ("python-flask" ,python-flask)
2284 ("python-jsonschema" ,python-jsonschema)
2285 ("python-pytz" ,python-pytz)
2286 ("python-six" ,python-six)))
2288 `(("python-tzlocal" ,python-tzlocal)
2289 ("python-blinker" ,python-blinker)
2290 ("python-nose" ,python-nose)
2291 ("python-rednose" ,python-rednose)))
2292 (home-page "https://github.com/noirbizarre/flask-restplus")
2293 (synopsis "Framework for documented API development with Flask")
2294 (description "This package provides a framework for API development with
2295 the Flask web framework in Python. It is similar to package
2296 @code{python-flask-restful} but supports the @code{python-swagger}
2297 documentation builder.")
2298 (license license:expat)))
2300 (define-public python-flask-restful-swagger
2302 (name "python-flask-restful-swagger")
2307 (uri (pypi-uri "flask-restful-swagger" version))
2310 "16msl8hd5xjmj833bpy264v98cpl5hkw5bgl5gf5vgndxbv3rm6v"))))
2311 (build-system python-build-system)
2313 `(("python-flask-restful" ,python-flask-restful)))
2314 (home-page "https://github.com/rantav/flask-restful-swagger")
2315 (synopsis "Extract Swagger specs from Flask-Restful projects")
2316 (description "This package lets you extract Swagger API documentation
2317 specs from your Flask-Restful projects.")
2318 (license license:expat)))
2320 (define-public python2-flask-restful-swagger
2321 (package-with-python2 python-flask-restful-swagger))
2323 (define-public python-htmlmin
2325 (name "python-htmlmin")
2330 (uri (pypi-uri "htmlmin" version))
2333 "0y51xhabw6x8jk8k93xl8vznshpz3jb6l28075r5sjip613fzhah"))))
2335 `(#:tests? #f)) ; no tests
2336 (build-system python-build-system)
2337 (home-page "https://htmlmin.readthedocs.org/en/latest/")
2338 (synopsis "HTML minifier")
2339 (description "@code{htmlmin} is an HTML minifier that just works.
2340 It comes with safe defaults and easily configurable options.")
2341 (license license:bsd-3)))
2343 (define-public python2-htmlmin
2344 (package-with-python2 python-htmlmin))
2346 (define-public python-flask-htmlmin
2348 (name "python-flask-htmlmin")
2353 (uri (pypi-uri "Flask-HTMLmin" version))
2356 "1n6zlq72kakkw0z2jpq6nh74lfsmxybm4g053pwhc14fbr809348"))))
2358 `(("python-flask" ,python-flask)
2359 ("python-htmlmin" ,python-htmlmin)))
2360 (build-system python-build-system)
2361 (home-page "https://github.com/hamidfzm/Flask-HTMLmin")
2362 (synopsis "HTML response minifier for Flask")
2364 "Minify @code{text/html} MIME type responses when using @code{Flask}.")
2365 (license license:bsd-3)))
2367 (define-public python2-flask-htmlmin
2368 (package-with-python2 python-flask-htmlmin))
2370 (define-public python-jsmin
2372 (name "python-jsmin")
2377 (uri (pypi-uri "jsmin" version))
2380 "0fsmqbjvpxvff0984x7c0y8xmf49ax9mncz48b9xjx8wrnr9kpxn"))))
2381 (build-system python-build-system)
2382 (home-page "https://github.com/tikitu/jsmin/")
2383 (synopsis "Python JavaScript minifier")
2385 "@code{jsmin} is a JavaScript minifier, usable from both Python code and
2386 on the command line.")
2387 (license license:expat)))
2389 (define-public python-flask-login
2391 (name "python-flask-login")
2397 (url "https://github.com/maxcountryman/flask-login.git")
2399 (file-name (git-file-name name version))
2401 (base32 "1rj0qwyxapxnp84fi4lhmvh3d91fdiwz7hibw77x3d5i72knqaa9"))))
2404 (modify-phases %standard-phases
2405 (add-before 'check 'avoid-yanc
2406 ;; Work around '.nosetests-real: error: no such option: --with-yanc'.
2408 (setenv "NOCOLOR" "set")
2410 (build-system python-build-system)
2412 `(("python-flask" ,python-flask)))
2415 `(("python-blinker" ,python-blinker)
2416 ("python-mock" ,python-mock)
2417 ("python-nose" ,python-nose)
2418 ("python-pep8" ,python-pep8)
2419 ("python-pyflakes" ,python-pyflakes)
2420 ("python-semantic-version" ,python-semantic-version)
2421 ("python-werkzeug" ,python-werkzeug)))
2422 (home-page "https://github.com/maxcountryman/flask-login")
2423 (synopsis "User session management for Flask")
2425 "@code{Flask-Login} provides user session management for Flask. It
2426 handles the common tasks of logging in, logging out, and remembering your
2427 users' sessions over extended periods of time.")
2428 (license license:expat)))
2430 (define-public python2-flask-login
2431 (package-with-python2 python-flask-login))
2433 (define-public python-oauth2client
2435 (name "python-oauth2client")
2440 (uri (pypi-uri "oauth2client" version))
2443 "1irqqap2zibysf8dba8sklfqikia579srd0phm5n754ni0h59gl0"))))
2444 (build-system python-build-system)
2448 `(("python-httplib2" ,python-httplib2)
2449 ("python-pyasn1" ,python-pyasn1)
2450 ("python-pyasn1-modules" ,python-pyasn1-modules)
2451 ("python-rsa" ,python-rsa)
2452 ("python-six" ,python-six)))
2453 (home-page "https://github.com/google/oauth2client/")
2454 (synopsis "OAuth 2.0 client library")
2455 (description "@code{python-oauth2client} provides an OAuth 2.0 client
2456 library for Python")
2457 (license license:asl2.0)))
2459 (define-public python2-oauth2client
2460 (package-with-python2 python-oauth2client))
2462 (define-public python-flask-oidc
2464 (name "python-flask-oidc")
2469 (uri (pypi-uri "flask-oidc" version))
2472 "1ay5j0mf174bix7i67hclr95gv16z81fpx0dijvi0gydvdj3ddy2"))))
2473 (build-system python-build-system)
2475 `(("python-flask" ,python-flask)
2476 ("python-itsdangerous" ,python-itsdangerous)
2477 ("python-oauth2client" ,python-oauth2client)
2478 ("python-six" ,python-six)))
2480 `(("python-nose" ,python-nose)
2481 ("python-mock" ,python-mock)))
2482 (home-page "https://github.com/puiterwijk/flask-oidc")
2483 (synopsis "OpenID Connect extension for Flask")
2484 (description "@code{python-flask-oidc} provides an OpenID Connect extension
2486 (license license:bsd-2)))
2488 (define-public python-webassets
2490 (name "python-webassets")
2495 (uri (pypi-uri "webassets" version))
2498 "1nrqkpb7z46h2b77xafxihqv3322cwqv6293ngaky4j3ff4cing7"))))
2499 (build-system python-build-system)
2501 `(("python-jinja2" ,python-jinja2)
2502 ("python-mock" ,python-mock)
2503 ("python-nose" ,python-nose)
2504 ("python-pytest" ,python-pytest)))
2505 (home-page "https://github.com/miracle2k/webassets")
2506 (synopsis "Media asset management")
2507 (description "Merges, minifies and compresses Javascript and CSS files,
2508 supporting a variety of different filters, including YUI, jsmin, jspacker or
2509 CSS tidy. Also supports URL rewriting in CSS files.")
2510 (license license:bsd-2)))
2512 (define-public python-cssmin
2514 (name "python-cssmin")
2519 (uri (pypi-uri "cssmin" version))
2522 "1dk723nfm2yf8cp4pj785giqlwv42l0kj8rk40kczvq1hk6g04p0"))))
2523 (build-system python-build-system)
2524 (home-page "https://github.com/zacharyvoase/cssmin")
2525 (synopsis "Python port of the YUI CSS Compressor")
2526 (description "Python port of the YUI CSS Compressor.")
2527 (license (list license:expat license:bsd-3))))
2529 (define-public python2-cssmin
2530 (package-with-python2 python-cssmin))
2532 (define-public python-elasticsearch
2534 (name "python-elasticsearch")
2539 (uri (pypi-uri "elasticsearch" version))
2542 "0rnjvlhw4v3vg14l519qliy1s1zpmx3827q0xfviwvk42rr7hh01"))))
2543 (build-system python-build-system)
2545 `(("python-mock" ,python-mock)
2546 ("python-nosexcover" ,python-nosexcover)
2547 ("python-pyaml" ,python-pyaml)
2548 ("python-requests" ,python-requests)))
2550 `(("urllib3" ,python-urllib3)))
2552 ;; tests require the test_elasticsearch module but it is not distributed.
2554 (home-page "https://github.com/elastic/elasticsearch-py")
2555 (synopsis "Low-level client for Elasticsearch")
2556 (description "Official low-level client for Elasticsearch. Its goal is to
2557 provide common ground for all Elasticsearch-related code in Python; because of
2558 this it tries to be opinion-free and very extendable.")
2559 (license license:expat)))
2561 (define-public python2-elasticsearch
2562 (package-with-python2 python-elasticsearch))
2564 (define-public python-flask-script
2566 (name "python-flask-script")
2571 (uri (pypi-uri "Flask-Script" version))
2574 "0r8w2v89nj6b9p91p495cga5m72a673l2wc0hp0zqk05j4yrc9b4"))))
2575 (build-system python-build-system)
2578 (modify-phases %standard-phases
2579 (add-after 'unpack 'patch-tests
2581 (substitute* "tests.py"
2582 (("flask\\.ext\\.script") "flask_script"))
2585 `(("python-flask" ,python-flask)
2586 ("python-argcomplete" ,python-argcomplete)
2587 ("python-werkzeug" ,python-werkzeug)))
2589 `(("python-pytest" ,python-pytest)))
2591 "https://github.com/smurfix/flask-script")
2592 (synopsis "Scripting support for Flask")
2593 (description "The Flask-Script extension provides support for writing
2594 external scripts in Flask. This includes running a development server,
2595 a customised Python shell, scripts to set up your database, cronjobs,
2596 and other command-line tasks that belong outside the web application
2598 (license license:bsd-3)))
2600 (define-public python2-flask-script
2601 (package-with-python2 python-flask-script))
2603 (define-public python-flask-migrate
2605 (name "python-flask-migrate")
2610 (uri (pypi-uri "Flask-Migrate" version))
2613 "107x78lkqsnbg92dld3dkagg07jvchp3ib3y0sivc4ipz6n1y7rk"))))
2614 (build-system python-build-system)
2616 `(("python-flask" ,python-flask)
2617 ("python-alembic" ,python-alembic)
2618 ("python-sqlalchemy" ,python-sqlalchemy)
2619 ("python-flask-script" ,python-flask-script)
2620 ("python-flask-sqlalchemy" ,python-flask-sqlalchemy)))
2621 (home-page "https://github.com/miguelgrinberg/flask-migrate/")
2622 (synopsis "SQLAlchemy database migrations for Flask programs using
2624 (description "This package contains SQLAlchemy database migration tools
2625 for Flask programs that are using @code{python-alembic}.")
2626 (license license:expat)))
2628 (define-public python2-flask-migrate
2629 (package-with-python2 python-flask-migrate))
2631 (define-public python-genshi
2633 (name "python-genshi")
2639 (url "https://github.com/edgewall/genshi.git")
2641 (file-name (git-file-name name version))
2643 (base32 "06rch30x10l105k5b6rahd839lkhmgrzn6691wbci0cb2fzps32w"))))
2644 (build-system python-build-system)
2645 (home-page "https://genshi.edgewall.org/")
2646 (synopsis "Toolkit for generation of output for the web")
2647 (description "Genshi is a Python library that provides an integrated set
2648 of components for parsing, generating, and processing HTML, XML or other
2649 textual content for output generation on the web.")
2650 (license license:bsd-3)))
2652 (define-public python2-genshi
2653 (package-with-python2 python-genshi))
2655 (define-public python-flask-principal
2657 (name "python-flask-principal")
2662 (uri (pypi-uri "Flask-Principal" version))
2665 "0lwlr5smz8vfm5h9a9i7da3q1c24xqc6vm9jdywdpgxfbi5i7mpm"))))
2666 (build-system python-build-system)
2668 `(("python-blinker" ,python-blinker)))
2670 `(("python-flask" ,python-flask)
2671 ("python-nose" ,python-nose)))
2672 (home-page "http://packages.python.org/Flask-Principal/")
2673 (synopsis "Identity management for Flask")
2674 (description "@code{flask_principal} is a identity management library for
2675 Flask. It supports managing both authentication and authorization data in a
2676 thread-local variable.")
2677 (license license:expat)))
2679 (define-public python2-flask-principal
2680 (package-with-python2 python-flask-principal))
2682 (define-public python-flask-httpauth
2684 (name "python-flask-httpauth")
2689 (uri (pypi-uri "Flask-HTTPAuth" version))
2692 "13gff5w1mqpzm5nccyg02v3ifb9ifqh5k866cssjhghhg6msfjsz"))))
2693 (build-system python-build-system)
2695 `(("python-flask" ,python-flask)))
2696 (home-page "https://github.com/miguelgrinberg/flask-httpauth/")
2697 (synopsis "Basic and Digest HTTP authentication for Flask routes")
2698 (description "@code{flask_httpauth} provides Basic and Digest HTTP
2699 authentication for Flask routes.")
2700 (license license:expat)))
2702 (define-public python2-flask-httpauth
2703 (package-with-python2 python-flask-httpauth))
2705 (define-public python-uritemplate
2707 (name "python-uritemplate")
2712 (uri (pypi-uri "uritemplate" version))
2715 "0781gm9g34wa0asc19dx81ng0nqq07igzv3bbvdqmz13pv7469n0"))))
2716 (build-system python-build-system)
2717 (home-page "https://uritemplate.readthedocs.org")
2718 (synopsis "Library to deal with URI Templates")
2719 (description "@code{uritemplate} provides Python library to deal with URI
2721 (license license:bsd-2)))
2723 (define-public python2-uritemplate
2724 (package-with-python2 python-uritemplate))
2726 (define-public python-publicsuffix
2728 (name "python-publicsuffix")
2732 (uri (pypi-uri "publicsuffix" version))
2735 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
2736 (build-system python-build-system)
2738 `(#:tests? #f)) ; tests use the internet
2739 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
2740 (synopsis "Get suffix for a domain name")
2741 (description "Get a public suffix for a domain name using the Public Suffix
2743 (license license:expat)))
2745 (define-public python2-publicsuffix
2746 (package-with-python2 python-publicsuffix))
2748 (define-public python-publicsuffix2
2750 (name "python-publicsuffix2")
2751 (version "2.20191221")
2755 (uri (pypi-uri "publicsuffix2" version))
2757 (base32 "0yzysvfj1najr1mb4pcqrbmjir3xpb69rlffln95a3cdm8qwry00"))))
2758 (build-system python-build-system)
2761 (modify-phases %standard-phases
2762 (add-after 'unpack 'ignore-maintainer-inputs
2764 ;; Comment out a demand for python-requests, which is used only by
2765 ;; the unused ‘update_psl’ helper command.
2766 (substitute* "setup.py"
2767 (("'requests " match)
2768 (format "# ~a" match)))
2770 #:tests? #f)) ; the test suite requires network access
2771 (home-page "https://github.com/pombredanne/python-publicsuffix2")
2772 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
2773 (description "Get a public suffix for a domain name using the Public Suffix
2774 List. Forked from and using the same API as the publicsuffix package.")
2775 (license (list license:expat license:mpl2.0))))
2777 (define-public python2-publicsuffix2
2778 (package-with-python2 python-publicsuffix2))
2780 (define-public python-werkzeug
2782 (name "python-werkzeug")
2787 (uri (pypi-uri "werkzeug" version))
2790 "0z2m4snn1vc9518r2vzgdj1nc90kcgi60wijvd29yvcp85ypmzf3"))))
2791 (build-system python-build-system)
2794 (modify-phases %standard-phases
2796 (add-after 'install 'check
2797 (lambda* (#:key inputs outputs #:allow-other-keys)
2798 (add-installed-pythonpath inputs outputs)
2799 (invoke "python" "-m" "pytest"))))))
2801 `(("python-requests" ,python-requests)))
2803 `(("python-pytest" ,python-pytest)))
2804 (home-page "https://www.palletsprojects.org/p/werkzeug/")
2805 (synopsis "Utilities for WSGI applications")
2806 (description "One of the most advanced WSGI utility modules. It includes a
2807 powerful debugger, full-featured request and response objects, HTTP utilities to
2808 handle entity tags, cache control headers, HTTP dates, cookie handling, file
2809 uploads, a powerful URL routing system and a bunch of community-contributed
2811 (license license:x11)))
2813 (define-public python2-werkzeug
2814 (package-with-python2 python-werkzeug))
2816 (define-public python-bottle
2818 (name "python-bottle")
2823 (uri (pypi-uri "bottle" version))
2826 "0m9k2a7yxvggc4kw8fsvj381vgsvfcdshg5nzy6vwrxiw2p53drr"))))
2827 (build-system python-build-system)
2828 (home-page "http://bottlepy.org/")
2829 (synopsis "WSGI framework for small web-applications.")
2830 (description "@code{python-bottle} is a WSGI framework for small web-applications.")
2831 (license license:expat)))
2833 (define-public python2-bottle
2834 (package-with-python2 python-bottle))
2836 (define-public python-wtforms
2838 (name "python-wtforms")
2843 (uri (pypi-uri "WTForms" version ".zip"))
2846 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
2847 (build-system python-build-system)
2850 (modify-phases %standard-phases
2851 (add-after 'unpack 'remove-django-test
2852 ;; Don't fail the tests when the inputs for the optional tests cannot be found.
2856 (("'ext_django.tests', 'ext_sqlalchemy', 'ext_dateutil', 'locale_babel'") "")
2857 (("sys.stderr.write(\"### Disabled test '%s', dependency not found\n\" % name)") ""))
2860 `(("unzip" ,unzip)))
2861 (home-page "http://wtforms.simplecodes.com/")
2863 "Form validation and rendering library for Python web development")
2865 "WTForms is a flexible forms validation and rendering library
2866 for Python web development. It is very similar to the web form API
2867 available in Django, but is a standalone package.")
2868 (license license:bsd-3)))
2870 (define-public python2-wtforms
2871 (package-with-python2 python-wtforms))
2873 (define-public python-paste
2875 (name "python-paste")
2880 (uri (pypi-uri "Paste" version))
2883 "14lbi9asn5agsdf7r97prkjpz7amgmp529lbvfhf0nv881xczah6"))
2884 (patches (search-patches "python-paste-remove-timing-test.patch"))
2885 (modules '((guix build utils)))
2888 ;; This test calls out to the internet.
2889 (delete-file "tests/test_proxy.py") #t))))
2890 (build-system python-build-system)
2892 `(("python-pytest" ,python-pytest)
2893 ("python-pytest-runner" ,python-pytest-runner)
2894 ("python-nose" ,python-nose)))
2896 `(("python-six" ,python-six)))
2897 (home-page "https://pythonpaste.readthedocs.io/")
2899 "Python web development tools, focusing on WSGI")
2901 "Paste provides a variety of web development tools and middleware which
2902 can be nested together to build web applications. Paste's design closely
2903 follows ideas flowing from WSGI (Web Standard Gateway Interface).")
2904 (license license:expat)))
2906 (define-public python2-paste
2907 (package-with-python2 python-paste))
2909 (define-public python-pastescript
2911 (name "python-pastescript")
2916 (uri (pypi-uri "PasteScript" version))
2919 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
2920 (build-system python-build-system)
2922 `(("python-nose" ,python-nose)))
2924 `(("python-paste" ,python-paste)
2925 ("python-pastedeploy" ,python-pastedeploy)))
2926 (home-page (string-append "https://web.archive.org/web/20161025192515/"
2927 "http://pythonpaste.org/script/"))
2929 '(;; Unfortunately, this requires the latest unittest2,
2930 ;; but that requires traceback2 which requires linecache2 which requires
2931 ;; unittest2. So we're skipping tests for now.
2932 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
2933 ;; so in theory we could get around this situation somehow.)
2936 "Pluggable command line tool for serving web applications and more")
2938 "PasteScript is a plugin-friendly command line tool which provides a
2939 variety of features, from launching web applications to bootstrapping project
2941 (license license:expat)))
2943 (define-public python2-pastescript
2944 (package-with-python2 python-pastescript))
2946 (define-public python2-urlgrabber
2948 (name "python2-urlgrabber")
2953 (uri (pypi-uri "urlgrabber" version))
2955 (base32 "0w1h7hlsq406bxfy2pn4i9bd003bwl0q9b7p03z3g6yl0d21ddq5"))))
2956 (build-system python-build-system)
2957 (arguments `(#:python ,python-2)) ; urlgrabber supports python2 only
2958 (home-page "http://urlgrabber.baseurl.org")
2959 (synopsis "High-level cross protocol url-grabber")
2960 (description "@code{urlgrabber} is Python2 library that unifies access to
2961 files available on web, FTP or locally. It supports HTTP, FTP and file://
2962 protocols, it supports features like HTTP keep-alive, reget, throttling and
2964 (license license:lgpl2.1+)))
2966 (define-public python-pycares
2968 (name "python-pycares")
2973 (uri (pypi-uri "pycares" version))
2976 "0h4fxw5drrhfyslzmfpljk0qnnpbhhb20hnnndzahhbwylyw1x1n"))))
2977 (build-system python-build-system)
2979 `(#:tests? #f)) ;tests require internet access
2980 (home-page "http://github.com/saghul/pycares")
2981 (synopsis "Python interface for @code{c-ares}")
2982 (description "@code{pycares} is a Python module which provides an
2983 interface to @code{c-ares}, a C library that performs DNS requests and
2984 name resolutions asynchronously.")
2985 (license license:expat)))
2987 (define-public python-yarl
2989 (name "python-yarl")
2994 (uri (pypi-uri "yarl" version))
2997 "1s6z13g8vgxfkkqwhn6imnm7pl7ky9arv4jygnn6bcndcbidg7d6"))))
2998 (build-system python-build-system)
3000 `(("python-pytest" ,python-pytest)
3001 ("python-pytest-runner" ,python-pytest-runner)))
3003 `(("python-idna" ,python-idna)
3004 ("python-multidict" ,python-multidict)))
3005 (home-page "https://github.com/aio-libs/yarl/")
3006 (synopsis "Yet another URL library")
3007 (description "@code{yarl} module provides handy @code{URL} class
3008 for URL parsing and changing.")
3009 (license license:asl2.0)))
3011 (define-public python-google-api-client
3013 (name "python-google-api-client")
3018 (uri (pypi-uri "google-api-python-client" version))
3021 "1wpbbbxfpy9mwxdy3kn352cb590ladv574j1aa2l4grjdqw3ln05"))))
3022 (build-system python-build-system)
3024 '(#:tests? #f)) ; tests require internet access
3026 `(("python-httplib2" ,python-httplib2)
3027 ("python-six" ,python-six)
3028 ("python-oauth2client" ,python-oauth2client)
3029 ("python-uritemplate" ,python-uritemplate)))
3030 (home-page "https://github.com/google/google-api-python-client")
3031 (synopsis "Core Python library for accessing Google APIs")
3032 (description "Python client library for Google's discovery based APIs")
3033 (license license:asl2.0)))
3035 (define-public python2-google-api-client
3036 (package-with-python2 python-google-api-client))
3038 (define-public python-hawkauthlib
3040 (name "python-hawkauthlib")
3045 (uri (pypi-uri "hawkauthlib" version))
3048 "03ai47s4h8nfnrf25shbfvkm1b9n1ccd4nmmj280sg1fayi69zgg"))))
3049 (build-system python-build-system)
3051 `(("python-requests" ,python-requests)
3052 ("python-webob" ,python-webob)))
3053 (home-page "https://github.com/mozilla-services/hawkauthlib")
3054 (synopsis "Hawk Access Authentication protocol")
3056 "This is a low-level Python library for implementing Hawk Access Authentication,
3057 a simple HTTP request-signing scheme.")
3058 (license license:mpl2.0)))
3060 (define-public python-pybrowserid
3062 (name "python-pybrowserid")
3067 (uri (pypi-uri "PyBrowserID" version))
3070 "1qvi79kfb8x9kxkm5lw2mp42hm82cpps1xknmsb5ghkwx1lpc8kc"))))
3071 (build-system python-build-system)
3073 `(("python-requests" ,python-requests)))
3075 `(("python-mock" ,python-mock)))
3076 (home-page "https://github.com/mozilla/PyBrowserID")
3077 (synopsis "Python library for the BrowserID protocol")
3079 "This is a Python client library for the BrowserID protocol that
3080 underlies Mozilla Persona.")
3081 (license license:mpl2.0)))
3083 (define-public python-pyfxa
3085 (name "python-pyfxa")
3090 (uri (pypi-uri "PyFxA" version))
3093 "0axl16fyrz2r88gnw4b12mk7dpkqscv8c4wsc1y5hicl7bsbc4fm"))))
3094 (build-system python-build-system)
3095 (arguments '(#:tests? #f)) ; 17 tests require network access
3097 `(("python-cryptography" ,python-cryptography)
3098 ("python-hawkauthlib" ,python-hawkauthlib)
3099 ("python-pybrowserid" ,python-pybrowserid)
3100 ("python-requests" ,python-requests)
3101 ("python-six" ,python-six)))
3103 `(("python-grequests" ,python-grequests)
3104 ("python-mock" ,python-mock)
3105 ("python-responses" ,python-responses)
3106 ("python-unittest2" ,python-unittest2)))
3107 (home-page "https://github.com/mozilla/PyFxA")
3108 (synopsis "Firefox Accounts client library for Python")
3110 "This is a Python library for interacting with the Firefox Accounts
3112 (license license:mpl2.0)))
3114 (define-public python-hyperlink
3116 (name "python-hyperlink")
3121 (uri (pypi-uri "hyperlink" version))
3124 "0m2nhi0j8wmgfscf974wd5v1xfq8mah286hil6npy1ys0m3y7222"))))
3125 (build-system python-build-system)
3127 `(("python-idna" ,python-idna)))
3128 (home-page "https://github.com/python-hyper/hyperlink")
3129 (synopsis "Python module to create immutable URLs according to spec")
3130 (description "This package provides a Python module to create immutable, and
3131 correct URLs for Python according to RFCs 3986 and 3987.")
3132 (license license:expat)))
3134 (define-public python-treq
3136 (name "python-treq")
3141 (uri (pypi-uri "treq" version))
3144 "0j4zwq9p1c9piv1vc66nxcv9s6hdinf90jwkbsm91k14npv9zq4i"))))
3145 (build-system python-build-system)
3147 `(("python-attrs" ,python-attrs)
3148 ("python-idna" ,python-idna)
3149 ("python-incremental" ,python-incremental)
3150 ("python-requests" ,python-requests)
3151 ("python-service-identity" ,python-service-identity)
3152 ("python-twisted" ,python-twisted)))
3153 (home-page "https://github.com/twisted/treq")
3154 (synopsis "Requests-like API built on top of twisted.web's Agent")
3155 (description "This package provides an HTTP library inspired by
3156 @code{requests}} but written on top of Twisted's @code{Agents}. It offers a
3157 high level API for making HTTP requests when using Twisted.")
3158 (license license:expat)))
3160 (define-public python-autobahn
3162 (name "python-autobahn")
3167 (uri (pypi-uri "autobahn" version))
3170 "1mm7j24ls01c7jb1ad5p5cpyxvzgydiyf8b04ihykh2v8g98j0x7"))))
3171 (build-system python-build-system)
3173 ;; The tests fail to run:
3174 ;; https://github.com/crossbario/autobahn-python/issues/1117
3177 `(("python-cffi" ,python-cffi)
3178 ("python-twisted" ,python-twisted)
3179 ("python-txaio" ,python-txaio)))
3180 (home-page "https://crossbar.io/autobahn/")
3181 (synopsis "Web Application Messaging Protocol implementation")
3182 (description "This package provides an implementation of the @dfn{Web Application
3183 Messaging Protocol} (WAMP). WAMP connects components in distributed
3184 applications using Publish and Subscribe (PubSub) and routed Remote Procedure
3185 Calls (rRPC). It is ideal for distributed, multi-client and server applications
3186 such as IoT applications or multi-user database-driven business applications.")
3187 (license license:expat)))
3189 (define-public python-ws4py
3191 (name "python-ws4py")
3196 (uri (pypi-uri "ws4py" version))
3199 "10slbbf2jm4hpr92jx7kh7mhf48sjl01v2w4d8z3f1p0ybbp7l19"))))
3200 (build-system python-build-system)
3203 (modify-phases %standard-phases
3204 (add-after 'unpack 'python3.7-compatibility
3206 (substitute* '("ws4py/server/tulipserver.py"
3207 "ws4py/async_websocket.py")
3209 "asyncio.ensure_future"))
3211 ;; We don't have a package for cherrypy.
3212 (add-after 'unpack 'remove-cherrypy-support
3214 (delete-file "ws4py/server/cherrypyserver.py")
3217 `(("python-gevent" ,python-gevent)
3218 ("python-tornado" ,python-tornado)))
3219 (home-page "https://github.com/Lawouach/WebSocket-for-Python")
3220 (synopsis "WebSocket client and server library")
3222 "This package provides a WebSocket client and server library for
3224 (license license:bsd-3)))
3226 ;; kaldi-gstreamer-server does not yet work with python-ws4py > 0.3.2
3227 (define-public python2-ws4py-for-kaldi-gstreamer-server
3228 (package (inherit python-ws4py)
3229 (name "python2-ws4py")
3234 (uri (pypi-uri "ws4py" version))
3237 "12ys3dv98awhrxd570vla3hqgzq3avjhq4yafhghhq3a942y1928"))))
3238 (build-system python-build-system)
3240 `(#:python ,python-2
3242 (modify-phases %standard-phases
3243 ;; We don't have a package for cherrypy.
3244 (add-after 'unpack 'remove-cherrypy-support
3246 (delete-file "ws4py/server/cherrypyserver.py")
3249 `(("python-gevent" ,python2-gevent)
3250 ("python-tornado" ,python2-tornado)))))
3252 (define-public python-slugify
3254 (name "python-slugify")
3259 (uri (pypi-uri "python-slugify" version))
3261 (base32 "0dv97yi5fq074q5qyqbin09pmi8ixg36caf5nkpw2bqkd8jh6pap"))
3263 (search-patches "python-slugify-depend-on-unidecode.patch"))))
3265 `(("python-wheel" ,python-wheel)))
3267 `(("python-unidecode" ,python-unidecode)))
3270 (modify-phases %standard-phases
3273 (invoke "python" "test.py"))))))
3274 (build-system python-build-system)
3275 (home-page "https://github.com/un33k/python-slugify")
3276 (synopsis "Python Slugify application that handles Unicode")
3277 (description "This package provides a @command{slufigy} command and
3278 library to create slugs from unicode strings while keeping it DRY.")
3279 (license license:expat)))
3281 (define-public python-branca
3283 (name "python-branca")
3288 (uri (pypi-uri "branca" version))
3291 "0pmigd521j2228xf8x34vbx0niwvms7xl7za0lymywj0vydjqxiy"))))
3292 (build-system python-build-system)
3294 `(("python-jinja2" ,python-jinja2)
3295 ("python-six" ,python-six)))
3297 `(("python-pytest" ,python-pytest)))
3298 (home-page "https://github.com/python-visualization/branca")
3299 (synopsis "Generate complex HTML+JS pages with Python")
3300 (description "Generate complex HTML+JS pages with Python")
3301 (license license:expat)))
3303 (define-public python-tinycss2
3305 (name "python-tinycss2")
3310 (uri (pypi-uri "tinycss2" version))
3312 (base32 "1kw84y09lggji4krkc58jyhsfj31w8npwhznr7lf19d0zbix09v4"))))
3313 (build-system python-build-system)
3316 (modify-phases %standard-phases
3318 (lambda _ (invoke "pytest"))))))
3320 `(("python-webencodings" ,python-webencodings)))
3322 `(("python-pytest-flake8" ,python-pytest-flake8)
3323 ("python-pytest-isort" ,python-pytest-isort)
3324 ("python-pytest-runner" ,python-pytest-runner)))
3325 (home-page "https://tinycss2.readthedocs.io/")
3326 (synopsis "Low-level CSS parser for Python")
3327 (description "@code{tinycss2} can parse strings, return Python objects
3328 representing tokens and blocks, and generate CSS strings corresponding to
3331 Based on the CSS Syntax Level 3 specification, @code{tinycss2} knows the
3332 grammar of CSS but doesn’t know specific rules, properties or values supported
3333 in various CSS modules.")
3334 (license license:bsd-3)))
3336 (define-public python-cssselect2
3338 (name "python-cssselect2")
3343 (uri (pypi-uri "cssselect2" version))
3345 (base32 "0skymzb4ncrm2zdsy80f53vi0arf776lvbp51hzh4ayp1il5lj3h"))))
3346 (build-system python-build-system)
3349 (modify-phases %standard-phases
3351 (lambda _ (invoke "pytest"))))))
3353 `(("python-tinycss2" ,python-tinycss2)))
3355 `(("python-pytest-cov" ,python-pytest-cov)
3356 ("python-pytest-flake8" ,python-pytest-flake8)
3357 ("python-pytest-isort" ,python-pytest-isort)
3358 ("python-pytest-runner" ,python-pytest-runner)))
3359 (home-page "https://cssselect2.readthedocs.io/")
3360 (synopsis "CSS selectors for Python ElementTree")
3361 (description "@code{cssselect2} is a straightforward implementation of
3362 CSS3 Selectors for markup documents (HTML, XML, etc.) that can be read by
3363 ElementTree-like parsers (including cElementTree, lxml, html5lib, etc.).
3365 Unlike the Python package @code{cssselect}, it does not translate selectors to
3366 XPath and therefore does not have all the correctness corner cases that are
3367 hard or impossible to fix in cssselect.")
3368 (license license:bsd-3)))
3370 (define-public gunicorn
3377 (uri (pypi-uri "gunicorn" version))
3380 "0l1zm8a0vz8ws3lkn8q9a0f93ipdzyvlf2zlwdj5xyadh6jdwsgg"))))
3381 (outputs '("out" "doc"))
3382 (build-system python-build-system)
3385 (modify-phases %standard-phases
3386 (add-after 'build 'build-doc
3388 (invoke "make" "-C" "docs" "PAPER=a4" "html" "info")
3389 (delete-file "docs/build/texinfo/Makefile")
3390 (delete-file "docs/build/texinfo/Gunicorn.texi")
3394 (setenv "PYTHONPATH"
3395 (string-append ".:" (getenv "PYTHONPATH")))
3396 ;; Remove test modules failing due to libc not found due to
3397 ;; section '.dynamic' not found in libc.so
3398 (delete-file "tests/test_arbiter.py")
3399 (delete-file "tests/test_config.py")
3400 (delete-file "tests/test_sock.py")
3402 (add-after 'install 'install-doc
3403 (lambda* (#:key outputs #:allow-other-keys)
3404 (let* ((doc (string-append (assoc-ref outputs "doc")
3405 "/share/doc/" ,name "-" ,version))
3406 (html (string-append doc "/html"))
3407 (info (string-append doc "/info"))
3408 (examples (string-append doc "/examples")))
3412 (copy-recursively "docs/build/html" html)
3413 (copy-recursively "docs/build/texinfo" info)
3414 (copy-recursively "examples" examples)
3415 (for-each (lambda (file)
3416 (copy-file file (string-append doc "/" file)))
3417 '("README.rst" "NOTICE" "LICENSE" "THANKS")))
3420 `(("binutils" ,binutils) ;; for ctypes.util.find_library()
3421 ("python-aiohttp", python-aiohttp)
3422 ("python-pytest" ,python-pytest)
3423 ("python-pytest-cov" ,python-pytest-cov)
3424 ("python-sphinx" ,python-sphinx)
3425 ("texinfo" ,texinfo)))
3426 (home-page "https://gunicorn.org/")
3427 (synopsis "Python WSGI HTTP Server for UNIX")
3428 (description "Gunicorn ‘Green Unicorn’ is a Python WSGI HTTP
3429 Server for UNIX. It’s a pre-fork worker model ported from Ruby’s
3430 Unicorn project. The Gunicorn server is broadly compatible with
3431 various web frameworks, simply implemented, light on server resources,
3432 and fairly speedy.")
3433 (license license:expat)))