1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2013, 2014, 2015, 2016, 2019 Andreas Enge <andreas@enge.fr>
5 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
6 ;;; Copyright © 2014, 2017 Eric Bavier <bavier@member.fsf.org>
7 ;;; Copyright © 2014, 2015 Federico Beffa <beffa@fbengineering.ch>
8 ;;; Copyright © 2015 Omar Radwan <toxemicsquire4@gmail.com>
9 ;;; Copyright © 2015 Pierre-Antoine Rault <par@rigelk.eu>
10 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
11 ;;; Copyright © 2015, 2016 Christopher Allan Webber <cwebber@dustycloud.org>
12 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
13 ;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org>
14 ;;; Copyright © 2015, 2016, 2017, 2019 Leo Famulari <leo@famulari.name>
15 ;;; Copyright © 2015, 2017 Ben Woodcroft <donttrustben@gmail.com>
16 ;;; Copyright © 2015, 2016 Erik Edrosa <erik.edrosa@gmail.com>
17 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
18 ;;; Copyright © 2015, 2017 Kyle Meyer <kyle@kyleam.com>
19 ;;; Copyright © 2015, 2016 Chris Marusich <cmmarusich@gmail.com>
20 ;;; Copyright © 2016 Danny Milosavljevic <dannym+a@scratchpost.org>
21 ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
22 ;;; Copyright © 2016, 2018-2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
23 ;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org>
24 ;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com>
25 ;;; Copyright © 2016, 2017 Troy Sankey <sankeytms@gmail.com>
26 ;;; Copyright © 2016, 2017 ng0 <ng0@n0.is>
27 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
28 ;;; Copyright © 2016 David Craven <david@craven.ch>
29 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
30 ;;; Copyright © 2016, 2017 Stefan Reichör <stefan@xsteve.at>
31 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
32 ;;; Copyright © 2016, 2017, 2019 Alex Vong <alexvong1995@gmail.com>
33 ;;; Copyright © 2016, 2017, 2018 Arun Isaac <arunisaac@systemreboot.net>
34 ;;; Copyright © 2016, 2017, 2018 Julien Lepiller <julien@lepiller.eu>
35 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
36 ;;; Copyright © 2016, 2017 Thomas Danckaert <post@thomasdanckaert.be>
37 ;;; Copyright © 2017 Carlo Zancanaro <carlo@zancanaro.id.au>
38 ;;; Copyright © 2017 Frederick M. Muriithi <fredmanglis@gmail.com>
39 ;;; Copyright © 2017, 2018 Adriano Peluso <catonano@gmail.com>
40 ;;; Copyright © 2017 Ben Sturmfels <ben@sturm.com.au>
41 ;;; Copyright © 2017, 2018, 2019 Mathieu Othacehe <m.othacehe@gmail.com>
42 ;;; Copyright © 2017 José Miguel Sánchez García <jmi2k@openmailbox.org>
43 ;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
44 ;;; Copyright © 2017, 2018, 2019 Kei Kebreau <kkebreau@posteo.net>
45 ;;; Copyright © 2017 Rutger Helling <rhelling@mykolab.com>
46 ;;; Copyright © 2017 Muriithi Frederick Muriuki <fredmanglis@gmail.com>
47 ;;; Copyright © 2017, 2019 Brendan Tildesley <mail@brendan.scot>
48 ;;; Copyright © 2018 Ethan R. Jones <ethanrjones97@gmail.com
49 ;;; Copyright © 2018 Fis Trivial <ybbs.daans@hotmail.com>
50 ;;; Copyright © 2018 Vijayalakshmi Vedantham <vijimay12@gmail.com>
51 ;;; Copyright © 2018 Mathieu Lirzin <mthl@gnu.org>
52 ;;; Copyright © 2018 Adam Massmann <massmannak@gmail.com>
53 ;;; Copyright © 2016, 2018 Tomáš Čech <sleep_walker@gnu.org>
54 ;;; Copyright © 2018, 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
55 ;;; Copyright © 2018 Oleg Pykhalov <go.wigust@gmail.com>
56 ;;; Copyright © 2018, 2019 Clément Lassieur <clement@lassieur.org>
57 ;;; Copyright © 2018, 2019 Maxim Cournoyer <maxim.cournoyer@gmail.com>
58 ;;; Copyright © 2018 Luther Thompson <lutheroto@gmail.com>
59 ;;; Copyright © 2018 Vagrant Cascadian <vagrant@debian.org>
60 ;;; Copyright © 2019, 2020 Brett Gilio <brettg@gnu.org>
61 ;;; Copyright © 2019 Sam <smbaines8@gmail.com>
62 ;;; Copyright © 2019 Jack Hill <jackhill@jackhill.us>
63 ;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
64 ;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
65 ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
66 ;;; Copyright © 2019 Jacob MacDonald <jaccarmac@gmail.com>
67 ;;; Copyright © 2019 Giacomo Leidi <goodoldpaul@autistici.org>
68 ;;; Copyright © 2019 Wiktor Żelazny <wzelazny@vurv.cz>
69 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
70 ;;; Copyright © 2019 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
71 ;;; Copyright © 2020 Riku Viitanen <riku.viitanen@protonmail.com>
73 ;;; This file is part of GNU Guix.
75 ;;; GNU Guix is free software; you can redistribute it and/or modify it
76 ;;; under the terms of the GNU General Public License as published by
77 ;;; the Free Software Foundation; either version 3 of the License, or (at
78 ;;; your option) any later version.
80 ;;; GNU Guix is distributed in the hope that it will be useful, but
81 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
82 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
83 ;;; GNU General Public License for more details.
85 ;;; You should have received a copy of the GNU General Public License
86 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
88 (define-module (gnu packages python-xyz)
89 #:use-module ((guix licenses) #:prefix license:)
90 #:use-module (gnu packages)
91 #:use-module (gnu packages algebra)
92 #:use-module (gnu packages adns)
93 #:use-module (gnu packages attr)
94 #:use-module (gnu packages backup)
95 #:use-module (gnu packages bash)
96 #:use-module (gnu packages check)
97 #:use-module (gnu packages compression)
98 #:use-module (gnu packages crypto)
99 #:use-module (gnu packages databases)
100 #:use-module (gnu packages dbm)
101 #:use-module (gnu packages file)
102 #:use-module (gnu packages fontutils)
103 #:use-module (gnu packages gcc)
104 #:use-module (gnu packages geo)
105 #:use-module (gnu packages ghostscript)
106 #:use-module (gnu packages gl)
107 #:use-module (gnu packages glib)
108 #:use-module (gnu packages gnome)
109 #:use-module (gnu packages graphviz)
110 #:use-module (gnu packages graphics)
111 #:use-module (gnu packages gstreamer)
112 #:use-module (gnu packages gtk)
113 #:use-module (gnu packages icu4c)
114 #:use-module (gnu packages image)
115 #:use-module (gnu packages imagemagick)
116 #:use-module (gnu packages kerberos)
117 #:use-module (gnu packages libevent)
118 #:use-module (gnu packages libffi)
119 #:use-module (gnu packages linux)
120 #:use-module (gnu packages llvm)
121 #:use-module (gnu packages man)
122 #:use-module (gnu packages maths)
123 #:use-module (gnu packages monitoring)
124 #:use-module (gnu packages multiprecision)
125 #:use-module (gnu packages networking)
126 #:use-module (gnu packages ncurses)
127 #:use-module (gnu packages openstack)
128 #:use-module (gnu packages pcre)
129 #:use-module (gnu packages perl)
130 #:use-module (gnu packages pkg-config)
131 #:use-module (gnu packages python)
132 #:use-module (gnu packages python-check)
133 #:use-module (gnu packages python-compression)
134 #:use-module (gnu packages python-crypto)
135 #:use-module (gnu packages python-science)
136 #:use-module (gnu packages python-web)
137 #:use-module (gnu packages qt)
138 #:use-module (gnu packages readline)
139 #:use-module (gnu packages sdl)
140 #:use-module (gnu packages search)
141 #:use-module (gnu packages shells)
142 #:use-module (gnu packages sphinx)
143 #:use-module (gnu packages ssh)
144 #:use-module (gnu packages terminals)
145 #:use-module (gnu packages tex)
146 #:use-module (gnu packages texinfo)
147 #:use-module (gnu packages time)
148 #:use-module (gnu packages tls)
149 #:use-module (gnu packages version-control)
150 #:use-module (gnu packages video)
151 #:use-module (gnu packages web)
152 #:use-module (gnu packages base)
153 #:use-module (gnu packages xml)
154 #:use-module (gnu packages xorg)
155 #:use-module (gnu packages xdisorg)
156 #:use-module (gnu packages tcl)
157 #:use-module (gnu packages bdw-gc)
158 #:use-module (gnu packages serialization)
159 #:use-module (guix packages)
160 #:use-module (guix download)
161 #:use-module (guix git-download)
162 #:use-module (guix hg-download)
163 #:use-module (guix utils)
164 #:use-module (guix build-system gnu)
165 #:use-module (guix build-system cmake)
166 #:use-module (guix build-system python)
167 #:use-module (guix build-system trivial)
168 #:use-module (srfi srfi-1)
169 #:use-module (srfi srfi-26))
171 (define-public python-psutil
173 (name "python-psutil")
178 (uri (pypi-uri "psutil" version))
180 (base32 "0isil5jxwwd8awz54qk28rpgjg43i5l6yl70g40vxwa4r4m56lfh"))))
181 (build-system python-build-system)
183 ;; FIXME: some tests does not return and times out.
185 (home-page "https://www.github.com/giampaolo/psutil")
186 (synopsis "Library for retrieving information on running processes")
188 "psutil (Python system and process utilities) is a library for retrieving
189 information on running processes and system utilization (CPU, memory, disks,
190 network) in Python. It is useful mainly for system monitoring, profiling and
191 limiting process resources and management of running processes. It implements
192 many functionalities offered by command line tools such as: ps, top, lsof,
193 netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
194 pidof, tty, taskset, pmap.")
195 (properties `((python2-variant . ,(delay python2-psutil))))
196 (license license:bsd-3)))
198 (define-public python2-psutil
199 (let ((base (package-with-python2 (strip-python2-variant python-psutil))))
203 `(("python2-enum34" ,python2-enum34) ;optional
204 ,@(package-propagated-inputs base))))))
206 (define-public python-shapely
208 (name "python-shapely")
209 (version "1.6.4.post2")
213 (uri (pypi-uri "Shapely" version))
216 "03r42fmd9alp6r3q95ad6rldq2f7n1wimrw53zy5kpn33yv7pf64"))))
217 (build-system python-build-system)
219 `(("python-cython" ,python-cython)
220 ("python-matplotlib" ,python-matplotlib)
221 ("python-pytest" ,python-pytest)
222 ("python-pytest-cov" ,python-pytest-cov)))
226 `(("python-numpy" ,python-numpy)))
229 (modify-phases %standard-phases
230 (add-after 'unpack 'patch-geos-path
231 (lambda* (#:key inputs #:allow-other-keys)
232 (let ((geos (assoc-ref inputs "geos"))
233 (glibc (assoc-ref inputs ,(if (%current-target-system)
234 "cross-libc" "libc"))))
235 (substitute* "shapely/geos.py"
236 (("_lgeos = load_dll\\('geos_c', fallbacks=.*\\)")
237 (string-append "_lgeos = load_dll('geos_c', fallbacks=['"
238 geos "/lib/libgeos_c.so'])"))
239 (("free = load_dll\\('c'\\)\\.free")
240 (string-append "free = load_dll('c', fallbacks=['"
241 glibc "/lib/libc.so.6']).free"))))
243 (home-page "https://github.com/Toblerity/Shapely")
244 (synopsis "Library for the manipulation and analysis of geometric objects")
245 (description "Shapely is a Python package for manipulation and analysis of
246 planar geometric objects. It is based on the @code{GEOS} library.")
247 (license license:bsd-3)))
249 (define-public python-shortuuid
251 (name "python-shortuuid")
256 (uri (pypi-uri "shortuuid" version))
259 "1f8i4zwj5vmpzbz6b17bljy4399gx5aq7vsyw63sz2qgyjcd73yh"))))
260 (build-system python-build-system)
262 `(("python-pep8" ,python-pep8)))
263 (home-page "https://github.com/skorokithakis/shortuuid")
264 (synopsis "Generator library for concise, unambiguous and URL-safe UUIDs")
266 "@code{shortuuid} is a Python library for generating concise, unambiguous
267 and URL-safe UUIDs. UUIDs are generated using the built-in Python @code{uuid}
268 module and then similar looking characters are removed.")
269 (license license:bsd-3)))
271 (define-public python-logwrap
273 (name "python-logwrap")
278 (uri (pypi-uri "logwrap" version ".zip"))
281 "1d2k0hvpbi51vl410y8fbs5m0nxnlh2k7gr2nrh3k81ibhzscsra"))))
282 (build-system python-build-system)
284 `(("python-six" ,python-six)
285 ("python-typing" ,python-typing)))
288 ("python-cython" ,python-cython)
289 ("python-pytest" ,python-pytest)
290 ("python-pytest-cov" ,python-pytest-cov)
291 ("python-pytest-runner" ,python-pytest-runner)))
292 (home-page "https://github.com/penguinolog/logwrap")
293 (synopsis "Decorator for logging function arguments")
294 (description "This package provides a decorator to log function arguments
295 and function call return values in a human-readable way.")
296 (license license:asl2.0)))
298 (define-public python2-shapely
299 (package-with-python2 python-shapely))
301 (define-public python-clyent
303 (name "python-clyent")
308 (uri (pypi-uri "clyent" version))
311 "1r9987qmy1pz3hq54160bapqsywpq14waw4w9x3ly8hmq7kpgfbj"))))
312 (build-system python-build-system)
314 `(("python-mock" ,python-mock)))
315 (home-page "https://github.com/binstar/clyent")
316 (synopsis "Command line client library")
317 (description "Clyent is a Python command line utiliy library. It is used
318 by @code{binstar}, @code{binstar-build} and @code{chalmers}.")
319 (license license:bsd-3)))
321 (define-public python2-clyent
322 (package-with-python2 python-clyent))
324 (define-public python-babel
326 (name "python-babel")
331 (uri (pypi-uri "Babel" version))
334 "0a7wawx8vsg7igvz6p3x909fskhg4b2y1910xk4f4c8y22p3aqg8"))))
335 (build-system python-build-system)
337 `(("python-freezegun" ,python-freezegun)
338 ("python-pytest" ,python-pytest)))
340 `(("python-pytz" ,python-pytz)))
342 `(#:phases (modify-phases %standard-phases
345 (invoke "pytest" "-vv" "-k"
347 ;; XXX: These tests fail when using Pytest 4.x and
348 ;; Babel 2.6.0. Try removing this for later versions.
349 "not test_no_inherit_metazone_marker_never_in_output"
350 " and not test_smoke_dates"
351 " and not test_smoke_numbers")))))))
352 (home-page "http://babel.pocoo.org/")
354 "Tools for internationalizing Python applications")
356 "Babel is composed of two major parts:
357 - tools to build and work with gettext message catalogs
358 - a Python interface to the CLDR (Common Locale Data Repository), providing
359 access to various locale display names, localized number and date formatting,
361 (license license:bsd-3)))
363 (define-public python2-babel
364 (package-with-python2 python-babel))
366 ;; Sphinx < 2.0 requires this version. Remove once no longer needed.
367 (define-public python2-babel-2.6
369 (inherit python2-babel)
373 (uri (pypi-uri "Babel" version))
376 "08rxmbx2s4irp0w0gmn498vns5xy0fagm0fg33xa772jiks51flc"))))))
378 (define-public python2-backport-ssl-match-hostname
380 (name "python2-backport-ssl-match-hostname")
385 (uri (pypi-uri "backports.ssl_match_hostname" version))
388 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
389 (build-system python-build-system)
392 #:tests? #f)) ; no test target
393 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
394 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
396 "This backport brings the ssl.match_hostname() function to users of
397 earlier versions of Python. The function checks the hostname in the
398 certificate returned by the server to which a connection has been established,
399 and verifies that it matches the intended target hostname.")
400 (license license:psfl)))
402 (define-public python-boolean.py
404 (name "python-boolean.py")
408 ;; There's no source tarball on PyPI.
411 (url "https://github.com/bastikr/boolean.py")
412 (commit (string-append "v" version))))
413 (file-name (git-file-name name version))
415 (base32 "1wc89y73va58cj7dsx6c199zpxsy9q53dsffsdj6zmc90inqz6qs"))))
416 (build-system python-build-system)
417 (home-page "https://github.com/bastikr/boolean.py")
418 (synopsis "Boolean algebra in one Python module")
420 "This is a small Python library that implements boolean algebra.
421 It defines two base elements, @code{TRUE} and @code{FALSE}, and a
422 @code{Symbol} class that can take on one of these two values. Calculations
423 are done only in terms of @code{AND}, @code{OR}, and @code{NOT}---other
424 compositions like @code{XOR} and @code{NAND} are emulated on top of them.
425 Expressions are constructed from parsed strings or directly in Python.")
426 (license license:bsd-2)))
428 (define-public python-hdf4
435 (uri (pypi-uri name version))
438 "1hjiyrxvxk9817qyqky3nar4y3fs4z8wxz0n884zzb5wi6skrjks"))))
439 (build-system python-build-system)
440 (native-inputs `(("nose" ,python-nose)))
441 (propagated-inputs `(("numpy" ,python-numpy)))
444 ("libjpeg" ,libjpeg-turbo)
448 (modify-phases %standard-phases
451 ;; The 'runexamples' script sets PYTHONPATH to CWD, then goes
452 ;; on to import numpy. Somehow this works on their CI system.
453 ;; Let's just manage PYTHONPATH here instead.
454 (substitute* "runexamples.sh"
455 (("export PYTHONPATH=.*") ""))
457 (string-append (getcwd) ":"
458 (getenv "PYTHONPATH")))
459 (invoke "./runexamples.sh")
460 (invoke "nosetests" "-v"))))))
461 (home-page "https://github.com/fhs/python-hdf4")
462 (synopsis "Python interface to the NCSA HDF4 library")
464 "Python-HDF4 is a python wrapper around the NCSA HDF version 4 library,
465 which implements the SD (Scientific Dataset), VS (Vdata) and V (Vgroup) API’s.
466 NetCDF files can also be read and modified. Python-HDF4 is a fork of
467 @url{http://hdfeos.org/software/pyhdf.php,pyhdf}.")
468 (license license:expat)))
470 (define-public python2-hdf4
471 (package-with-python2 python-hdf4))
473 (define-public python-h5py
480 (uri (pypi-uri "h5py" version))
483 "0mdr6wrq02ac93m1aqx9kad0ppfzmm4imlxqgyy1x4l7hmdcc9p6"))))
484 (build-system python-build-system)
486 `(#:tests? #f ; no test target
488 (modify-phases %standard-phases
489 (add-after 'unpack 'fix-hdf5-paths
490 (lambda* (#:key inputs #:allow-other-keys)
491 (let ((prefix (assoc-ref inputs "hdf5")))
492 (substitute* "setup_build.py"
493 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
494 (string-append "['" prefix "/lib" "']"))
495 (("'/opt/local/include', '/usr/local/include'")
496 (string-append "'" prefix "/include" "'")))
497 (substitute* "setup_configure.py"
498 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
499 (string-append "['" prefix "/lib" "']")))
502 `(("python-six" ,python-six)
503 ("python-numpy" ,python-numpy)))
507 `(("python-cython" ,python-cython)
508 ("python-pkgconfig" ,python-pkgconfig)))
509 (home-page "http://www.h5py.org/")
510 (synopsis "Read and write HDF5 files from Python")
512 "The h5py package provides both a high- and low-level interface to the
513 HDF5 library from Python. The low-level interface is intended to be a
514 complete wrapping of the HDF5 API, while the high-level component supports
515 access to HDF5 files, datasets and groups using established Python and NumPy
517 (license license:bsd-3)))
519 (define-public python2-h5py
520 (package-with-python2 python-h5py))
522 (define-public python-sh
529 (uri (pypi-uri "sh" version))
532 "1z2hx357xp3v4cv44xmqp7lli3frndqpyfmpbxf7n76h7s1zaaxm"))))
533 (build-system python-build-system)
536 (modify-phases %standard-phases
539 ;; XXX: A Python 2 test fails when HOME=/homeless-shelter.
540 (setenv "HOME" "/tmp")
541 (invoke "python" "sh.py" "test"))))))
543 `(("python-coverage" ,python-coverage)))
544 (home-page "https://github.com/amoffat/sh")
545 (synopsis "Python subprocess replacement")
546 (description "This package provides a replacement for Python's
547 @code{subprocess} feature.")
548 (license license:expat)))
550 (define-public python2-sh
551 (package-with-python2 python-sh))
553 (define-public python-cftime
555 (name "python-cftime")
560 (uri (pypi-uri "cftime" version))
562 (base32 "0w0gi6jnch38hiygl62j4xkcirv4y3dcwrvxl9p7bsk6j27lzihs"))))
563 (build-system python-build-system)
565 `(("python-numpy" ,python-numpy)))
567 `(("python-coveralls" ,python-coveralls)
568 ("python-cython" ,python-cython)
569 ("python-pytest-cov" ,python-pytest-cov)))
570 (home-page "https://github.com/Unidata/cftime")
571 (synopsis "Library for time handling")
573 "This package provides time-handling functionality that used to be part
574 of the netcdf4 package before.")
575 ;; This package claims to include code under the GPLv3 but is released
577 (license (list license:isc license:gpl3+))))
579 (define-public python-netcdf4
581 (name "python-netcdf4")
586 (uri (pypi-uri "netCDF4" version))
589 "0c0sklgrmv15ygliin8qq0hp7vanmbi74m6zpi0r1ksr0hssyd5r"))))
590 (build-system python-build-system)
593 (modify-phases %standard-phases
594 (add-after 'unpack 'configure-locations
595 (lambda* (#:key inputs #:allow-other-keys)
596 (setenv "HDF5_DIR" (assoc-ref inputs "hdf5"))
599 `(("python-cython" ,python-cython)))
601 `(("python-numpy" ,python-numpy)
602 ("python-cftime" ,python-cftime)))
607 (home-page "https://github.com/Unidata/netcdf4-python")
608 (synopsis "Python/numpy interface to the netCDF library")
609 (description "Netcdf4-python is a Python interface to the netCDF C
610 library. netCDF version 4 has many features not found in earlier
611 versions of the library and is implemented on top of HDF5. This module
612 can read and write files in both the new netCDF 4 and the old netCDF 3
613 format, and can create files that are readable by HDF5 clients. The
614 API is modelled after @code{Scientific.IO.NetCDF}, and should be familiar
615 to users of that module.")
616 ;; The software is mainly ISC, but includes some files covered
617 ;; by the Expat license.
618 (license (list license:isc license:expat))))
620 (define-public python2-netcdf4
621 (package-with-python2 python-netcdf4))
623 (define-public python-license-expression
625 (name "python-license-expression")
630 (uri (pypi-uri "license-expression" version))
632 (base32 "08ppb0bxbrsxazy88sgpl9yffvdsabw6dkk1nc332wcz2mphwwyf"))))
633 (build-system python-build-system)
635 `(("python-boolean.py" ,python-boolean.py)))
636 (home-page "https://github.com/nexB/license-expression")
637 (synopsis "Apply boolean logic to license expressions")
639 "This Python module defines a tiny language to evaluate and compare
640 license expressions using boolean logic. Logical combinations of licenses can
641 be tested for equality, containment, and equivalence. They can be normalised
642 and simplified. It supports SPDX license expressions as well as other naming
643 conventions and aliases in the same expression.")
644 (license license:gpl2+)))
646 (define-public python-lockfile
648 (name "python-lockfile")
653 (uri (pypi-uri "lockfile" version))
656 "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba"))))
657 (build-system python-build-system)
658 (arguments '(#:test-target "check"))
660 `(("python-pbr" ,python-pbr)))
661 (home-page "https://launchpad.net/pylockfile")
662 (synopsis "Platform-independent file locking module")
664 "The lockfile package exports a LockFile class which provides a simple
665 API for locking files.")
666 (license license:expat)))
668 (define-public python2-lockfile
669 (package-with-python2 python-lockfile))
671 (define-public python-semantic-version
673 (name "python-semantic-version")
678 (uri (pypi-uri "semantic_version" version))
681 "1h2l9xyg1zzsda6kjcmfcgycbvrafwci283vcr1v5sbk01l2hhra"))))
682 (build-system python-build-system)
684 `(#:tests? #f)) ; PyPI tarball lacks tests
685 (home-page "https://github.com/rbarrois/python-semanticversion")
686 (synopsis "Semantic versioning module for Python")
688 "The @code{semantic_version} class is a small library for handling
689 @uref{https://semver.org/, semantic versioning} (@dfn{SemVer}) in Python.
691 It can compare versions, generate a new version that represents a bump in one of
692 the version levels, and check whether any given string is a proper semantic
693 version identifier.")
694 (license license:bsd-3)))
696 (define-public python2-semantic-version
697 (package-with-python2 python-semantic-version))
699 (define-public python-serpent
701 (name "python-serpent")
706 (uri (pypi-uri "serpent" version))
708 (base32 "1arnckykpkvv2qrp49l1k7q5mr5pisswl0rvdx98x8wsl1n361pk"))))
709 (build-system python-build-system)
711 `(("python-attrs" ,python-attrs)
712 ("python-pytz" ,python-pytz)))
713 (home-page "https://github.com/irmen/Serpent")
714 (synopsis "Serializer for literal Python expressions")
716 "Serpent provides @code{ast.literal_eval()}-compatible object tree
717 serialization. It serializes an object tree into bytes (an utf-8 encoded
718 string) that can be decoded and then passed as-is to @code{ast.literal_eval()}
719 to rebuild the original object tree.
721 Because only safe literals are encoded, it is safe to send serpent data to
722 other machines, such as over the network.")
723 (license license:expat)))
725 (define-public python-setuptools
727 (name "python-setuptools")
732 (uri (pypi-uri "setuptools" version ".zip"))
735 "04sns22y2hhsrwfy1mha2lgslvpjsjsz8xws7h2rh5a7ylkd28m2"))
736 (modules '((guix build utils)))
739 ;; Remove included binaries which are used to build self-extracting
740 ;; installers for Windows.
741 ;; TODO: Find some way to build them ourself so we can include them.
742 (for-each delete-file (find-files "setuptools" "^(cli|gui).*\\.exe$"))
744 (build-system python-build-system)
745 ;; FIXME: Tests require pytest, which itself relies on setuptools.
746 ;; One could bootstrap with an internal untested setuptools.
749 (home-page "https://pypi.python.org/pypi/setuptools")
751 "Library designed to facilitate packaging Python projects")
753 "Setuptools is a fully-featured, stable library designed to facilitate
754 packaging Python projects, where packaging includes:
755 Python package and module definitions,
756 distribution package metadata,
758 project installation,
759 platform-specific details,
761 ;; TODO: setuptools now bundles the following libraries:
762 ;; packaging, pyparsing, six and appdirs. How to unbundle?
763 (license (list license:psfl ; setuptools itself
764 license:expat ; six, appdirs, pyparsing
765 license:asl2.0 ; packaging is dual ASL2/BSD-2
768 (define-public python2-setuptools
769 (package-with-python2 python-setuptools))
771 ;; The setuptools provided by Python 3.7.4 is too new for Tensorflow.
772 (define-public python-setuptools-for-tensorflow
775 (inherit python-setuptools)
778 (inherit (package-source python-setuptools))
779 (uri (pypi-uri "setuptools" version ".zip"))
782 "1mzdhvfhnv4lggxa8rjl0dzqxvfx377gg5sqs57v89wrp09lwj65")))))))
784 (define-public python-uniseg
786 (name "python-uniseg")
791 (uri (pypi-uri "uniseg" version ".zip"))
794 "05jsazvz6nbmh6l3v1rph5ydkqn1hzx1pyggdyvgp2qgmgrnmiz2"))))
795 (build-system python-build-system)
797 '(#:tests? #f)) ; The test suite requires network access.
801 "https://bitbucket.org/emptypage/uniseg-python")
803 "Python library to determine Unicode text segmentations")
805 "Uniseg is a Python package used to determine Unicode text segmentations.
806 Supported segmentations include:
808 @item @dfn{Code point} (any value in the Unicode codespace)
809 @item @dfn{Grapheme cluster} (user-perceived character made of a single or
810 multiple Unicode code points, e.g. \"G\" + acute-accent)
815 (license license:expat)))
817 (define-public python2-uniseg
818 (package-with-python2 python-uniseg))
820 (define-public python-humanfriendly
822 (name "python-humanfriendly")
827 (uri (pypi-uri "humanfriendly" version))
830 "0pisgizjql86785jchfjv217g0lsgk114g2lja5j4y3lsc3b9szi"))))
831 (build-system python-build-system)
833 `(;; XXX: Tests depend on coloredlogs, which in turn depends on humanfriendly.
836 `(("python-monotonic" ,python-monotonic)))
837 (home-page "https://humanfriendly.readthedocs.io")
838 (synopsis "Human-friendly input and output in Python")
840 "The functions and classes in @code{humanfriendly} can be used to make
841 text interfaces more user-friendly. It includes tools to parse and format
842 numbers, file sizes, and timespans, timers for long-running operations, menus
843 to allow the user to choose from a list of options, and terminal interaction
845 (license license:expat)))
847 (define-public python2-humanfriendly
848 (package-with-python2 python-humanfriendly))
850 (define-public python-capturer
852 (name "python-capturer")
857 (uri (pypi-uri "capturer" version))
860 "05d6ji4j8ipiq0br7bwam38qc6hd9l1djmfxlzrxx19ziyjl4089"))))
861 (build-system python-build-system)
865 `(("python-humanfriendly" ,python-humanfriendly)))
866 (home-page "https://capturer.readthedocs.io")
867 (synopsis "Capture stdout and stderr streams of the current process")
869 "The capturer package makes it easy to capture the stdout and stderr
870 streams of the current process and subprocesses. Output can be relayed
871 to the terminal in real time but is also available to the Python program
872 for additional processing.")
873 (license license:expat)))
875 (define-public python2-capturer
876 (package-with-python2 python-capturer))
878 (define-public python-case
885 (uri (pypi-uri "case" version))
888 "1cagg06vfph864s6l5jb0zqliwxh647bki8j6lf4a4qrv40jnhs8"))))
889 (build-system python-build-system)
891 `(("python-mock" ,python-mock)
892 ("python-nose" ,python-nose)
893 ("python-six" ,python-six)
894 ("python-unittest2" ,python-unittest2)))
896 `(("python-coverage" ,python-coverage)))
897 (home-page "https://github.com/celery/case")
898 (synopsis "Unittest utilities and convenience methods")
900 "The @code{case} package provides utilities on top of unittest, including
901 some helpful Python 2 compatibility convenience methods.")
902 (license license:bsd-3)))
904 (define-public python-verboselogs
906 (name "python-verboselogs")
911 (uri (pypi-uri "verboselogs" version))
914 "09z4d1jiasn7k1hs5af2ckmnrd0i1d1m04bhfjhv7z6svzfdwgg3"))))
915 (build-system python-build-system)
918 (modify-phases %standard-phases
921 ;; Do not run pylint plugin test, as astroid is an old
922 ;; unsupported version.
923 (invoke "pytest" "-v" "-k" "not test_pylint_plugin"
924 "verboselogs/tests.py"))))))
926 `(("python-mock" ,python-mock)
927 ("python-pytest" ,python-pytest)))
928 (home-page "https://verboselogs.readthedocs.io")
929 (synopsis "Verbose logging level for Python's logging module")
931 "The @code{verboselogs} package extends Python's @code{logging} module to
932 add the log levels NOTICE, SPAM, SUCCESS and VERBOSE.")
933 (license license:expat)))
935 (define-public python2-verboselogs
936 (package-with-python2 python-verboselogs))
938 (define-public python-coloredlogs
940 (name "python-coloredlogs")
945 (uri (pypi-uri "coloredlogs" version))
948 "0dkw6xp0r1dwgz4s2f58npx5nxfq51wf4l6qkm5ib27slgfs4sdq"))))
949 (build-system python-build-system)
951 `(;Tests require some updated modules
954 `(("python-capturer" ,python-capturer)))
955 (home-page "https://coloredlogs.readthedocs.io")
956 (synopsis "Colored stream handler for Python's logging module")
958 "The @code{coloredlogs} package enables colored terminal output for
959 Python's logging module. The @code{ColoredFormatter} class inherits from
960 @code{logging.Formatter} and uses ANSI escape sequences to render your logging
962 (license license:expat)))
964 (define-public python2-coloredlogs
965 (package-with-python2 python-coloredlogs))
967 (define-public python-editorconfig
969 (name "python-editorconfig")
974 (uri (pypi-uri "EditorConfig" version))
977 "0v55z351p9qkyp3bbspwywwn28sbcknhirngjbj779n3z52z63hv"))))
978 (build-system python-build-system)
979 (home-page "https://editorconfig.org/")
980 (synopsis "EditorConfig bindings for python")
981 (description "The EditorConfig project consists of a file format for
982 defining coding styles and a collection of text editor plugins that enable
983 editors to read the file format and adhere to defined styles. EditorConfig
984 files are easily readable and they work nicely with version control systems.")
985 ;; "fnmatch.py" and "ini.py" are licensed under psfl, the rest is bsd-2.
986 (license (list license:bsd-2 license:psfl))))
988 (define-public python-et-xmlfile
990 (name "python-et-xmlfile")
995 (uri (pypi-uri "et_xmlfile" version))
998 "0nrkhcb6jdrlb6pwkvd4rycw34y3s931hjf409ij9xkjsli9fkb1"))))
999 (build-system python-build-system)
1001 `(#:phases (modify-phases %standard-phases
1004 (invoke "pytest"))))))
1006 `(("python-pytest" ,python-pytest)
1007 ("python-lxml" ,python-lxml))) ;used for the tests
1008 (home-page "https://bitbucket.org/openpyxl/et_xmlfile")
1009 (synopsis "Low memory implementation of @code{lxml.xmlfile}")
1010 (description "This Python library is based upon the @code{xmlfile} module
1011 from @code{lxml}. It aims to provide a low memory, compatible implementation
1012 of @code{xmlfile}.")
1013 (license license:expat)))
1015 (define-public python2-et-xmlfile
1016 (package-with-python2 python-et-xmlfile))
1018 (define-public python-openpyxl
1020 (name "python-openpyxl")
1024 ;; We use the upstream repository, as the tests are not included in the
1028 (url "https://bitbucket.org/openpyxl/openpyxl")
1029 (changeset version)))
1030 (file-name (string-append name "-" version "-checkout"))
1032 (base32 "1qhij6kcvdxqjy4g6193nsv4q7fy8n4fwyd3c2z047idlm6s3j4w"))))
1033 (build-system python-build-system)
1035 `(#:phases (modify-phases %standard-phases
1038 (invoke "pytest"))))))
1040 ;; For the test suite.
1041 `(("python-lxml" ,python-lxml)
1042 ("python-pillow" ,python-pillow)
1043 ("python-pytest" ,python-pytest)))
1045 `(("python-et-xmlfile" ,python-et-xmlfile)
1046 ("python-jdcal" ,python-jdcal)))
1047 (home-page "https://openpyxl.readthedocs.io")
1048 (synopsis "Python library to read/write Excel 2010 XLSX/XLSM files")
1049 (description "This Python library allows reading and writing to the Excel XLSX, XLSM,
1050 XLTX and XLTM file formats that are defined by the Office Open XML (OOXML)
1052 (license license:expat)))
1054 (define-public python-eventlet
1056 (name "python-eventlet")
1061 (uri (pypi-uri "eventlet" version))
1064 "1hgz8jq19wlz8vwqj900ry8cjv578nz4scc91mlc8944yid6573c"))))
1065 (build-system python-build-system)
1067 `(("python-greenlet" ,python-greenlet)))
1069 ;; TODO: Requires unpackaged 'enum-compat'.
1071 (home-page "https://eventlet.net")
1072 (synopsis "Concurrent networking library for Python")
1074 "Eventlet is a concurrent networking library for Python that
1075 allows you to change how you run your code, not how you write it.
1076 It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O.
1077 Coroutines ensure that the developer uses a blocking style of programming
1078 that is similar to threading, but provide the benefits of non-blocking I/O.
1079 The event dispatch is implicit, which means you can easily use @code{Eventlet}
1080 from the Python interpreter, or as a small part of a larger application.")
1081 (license license:expat)))
1083 (define-public python2-eventlet
1084 (let ((base (package-with-python2
1085 (strip-python2-variant python-eventlet))))
1086 (package (inherit base)
1088 `(("python2-enum34" ,python2-enum34)
1089 ,@(package-propagated-inputs base))))))
1091 (define-public python-six
1098 (uri (pypi-uri "six" version))
1101 "0wxs1q74v07ssjywbbm7x6h5v9qx209ld2yfsif4060sxi0h2sni"))))
1102 (build-system python-build-system)
1105 (modify-phases %standard-phases
1108 (invoke "py.test" "-v"))))))
1110 `(("python-py" ,python-py)
1111 ("python-pytest" ,python-pytest-bootstrap)))
1112 (home-page "https://pypi.python.org/pypi/six/")
1113 (synopsis "Python 2 and 3 compatibility utilities")
1115 "Six is a Python 2 and 3 compatibility library. It provides utility
1116 functions for smoothing over the differences between the Python versions with
1117 the goal of writing Python code that is compatible on both Python versions.
1118 Six supports every Python version since 2.5. It is contained in only one
1119 Python file, so it can be easily copied into your project.")
1120 (license license:x11)))
1122 (define-public python2-six
1123 (package-with-python2 python-six))
1125 (define-public python-six-bootstrap
1127 (inherit python-six)
1128 (name "python-six-bootstrap")
1130 (arguments `(#:tests? #f))))
1132 (define-public python2-six-bootstrap
1133 (package-with-python2 python-six-bootstrap))
1135 (define-public python-schedule
1137 (name "python-schedule")
1142 (uri (pypi-uri "schedule" version))
1145 "0vplyjcbfrq50sphlwya749z8p2pcyi2nycw3518i0qpd9a6189i"))))
1146 (build-system python-build-system)
1148 `(("python-pytest" ,python-pytest)
1149 ("python-mock" ,python-mock)))
1150 (home-page "https://github.com/dbader/schedule")
1151 (synopsis "Schedule periodic function calls in Python")
1153 "Schedule is an in-process scheduler for periodic jobs that uses the
1154 builder pattern for configuration. Schedule lets you run Python functions (or
1155 any other callable) periodically at pre-determined intervals using a simple,
1156 human-friendly syntax.")
1157 (license license:expat)))
1159 (define-public python2-schedule
1160 (package-with-python2 python-schedule))
1162 (define-public python2-mechanize
1164 (name "python2-mechanize")
1169 (uri (pypi-uri "mechanize" version))
1172 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1173 (build-system python-build-system)
1175 `(#:python ,python-2 ; apparently incompatible with Python 3
1177 ;; test fails with message
1178 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1179 ;; (python-3.3.2) or
1180 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1182 ;; The source code is from March 2011 and probably not up-to-date
1183 ;; with respect to python unit tests.
1184 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1186 "Stateful programmatic web browsing in Python")
1188 "Mechanize implements stateful programmatic web browsing in Python,
1189 after Andy Lester’s Perl module WWW::Mechanize.")
1190 (license (license:non-copyleft
1192 "See COPYING in the distribution."))))
1195 (define-public python-simplejson
1197 (name "python-simplejson")
1202 (uri (pypi-uri "simplejson" version))
1205 "1lkv3xlf7ryzi69zqfdbkvpxdfy1rg1rq2yzcnxgf4km5m6difqy"))))
1206 (build-system python-build-system)
1207 (home-page "http://simplejson.readthedocs.org/en/latest/")
1209 "Json library for Python")
1211 "JSON (JavaScript Object Notation) is a subset of JavaScript
1212 syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1215 Simplejson exposes an API familiar to users of the standard library marshal
1216 and pickle modules. It is the externally maintained version of the json
1217 library contained in Python 2.6, but maintains compatibility with Python 2.5
1218 and (currently) has significant performance advantages, even without using
1219 the optional C extension for speedups. Simplejson is also supported on
1221 (license license:x11)))
1223 (define-public python2-simplejson
1224 (package-with-python2 python-simplejson))
1227 (define-public python-pyicu
1229 (name "python-pyicu")
1234 (uri (pypi-uri "PyICU" version))
1237 "1x4w8m7ifki9z2a187pgjr33z6z0rp2fii9b73djak1vhm9v9cnx"))))
1238 (build-system python-build-system)
1240 `(("icu4c" ,icu4c)))
1242 `(("python-pytest" ,python-pytest)
1243 ("python-six" ,python-six)))
1244 (home-page "https://github.com/ovalhub/pyicu")
1245 (synopsis "Python extension wrapping the ICU C++ API")
1247 "PyICU is a python extension wrapping the ICU C++ API.")
1248 (properties `((python2-variant . ,(delay python2-pyicu))))
1249 (license license:x11)))
1251 (define-public python2-pyicu
1252 (let ((base (package-with-python2
1253 (strip-python2-variant python-pyicu))))
1257 `(,@(package-arguments base)
1259 (modify-phases %standard-phases
1260 (add-before 'check 'delete-failing-test
1262 ;; XXX: This fails due to Unicode issues unique to Python 2,
1263 ;; it seems: <https://github.com/ovalhub/pyicu/issues/61>.
1264 (delete-file "test/test_Script.py")
1267 (define-public python2-dogtail
1268 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1269 ;; spaces in indentation" with Python 3.
1271 (name "python2-dogtail")
1275 (uri (pypi-uri "dogtail" version))
1278 "0p5wfssvzr9w0bvhllzbbd8fnp4cca2qxcpcsc33dchrmh5n552x"))))
1279 (build-system python-build-system)
1280 (arguments `(#:python ,python-2
1281 #:tests? #f)) ; invalid command "test"
1282 ;; Currently no offical homepage.
1283 (home-page "https://pypi.python.org/pypi/dogtail/")
1284 (synopsis "GUI test tool and automation framework written in Python")
1286 "Dogtail is a GUI test tool and automation framework written in Python.
1287 It uses Accessibility (a11y) technologies to communicate with desktop
1288 applications. dogtail scripts are written in Python and executed like any
1289 other Python program.")
1290 (license license:gpl2+)))
1292 (define-public python-empy
1294 (name "python-empy")
1298 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1302 "1mxfy5mgp473ga1pgz2nvm8ds6z4g3hdky8523z6jzvcs9ny6hcq"))))
1303 (build-system python-build-system)
1305 `(#:tests? #f)) ; python2 only
1306 (home-page "http://www.alcyone.com/software/empy/")
1307 (synopsis "Templating system for Python")
1309 "EmPy is a system for embedding Python expressions and statements in
1310 template text; it takes an EmPy source file, processes it, and produces
1311 output. This is accomplished via expansions, which are special signals to the
1312 EmPy system and are set off by a special prefix (by default the at sign, @@).
1313 EmPy can expand arbitrary Python expressions and statements in this way, as
1314 well as a variety of special forms. Textual data not explicitly delimited in
1315 this way is sent unaffected to the output, allowing Python to be used in
1316 effect as a markup language. Also supported are callbacks via hooks,
1317 recording and playback via diversions, and dynamic, chainable filters. The
1318 system is highly configurable via command line options and embedded
1320 (license license:lgpl2.1+)))
1322 (define-public python2-empy
1323 (let ((base (package-with-python2 (strip-python2-variant python-empy))))
1326 (arguments `(,@(package-arguments base)
1329 (define-public python2-element-tree
1331 (name "python2-element-tree")
1336 "http://effbot.org/media/downloads/elementtree-"
1337 version "-20050316.tar.gz"))
1340 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1341 (build-system python-build-system)
1343 `(#:python ,python-2 ; seems to be part of Python 3
1344 #:tests? #f)) ; no 'test' sub-command
1345 (synopsis "Toolkit for XML processing in Python")
1347 "ElementTree is a Python library supporting lightweight XML processing.")
1348 (home-page "http://effbot.org/zone/element-index.htm")
1349 (license (license:x11-style
1350 "http://docs.python.org/2/license.html"
1351 "Like \"CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2\"."))))
1353 (define-public python2-pybugz
1355 (name "python2-pybugz")
1360 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1364 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
1365 (patches (search-patches "pybugz-stty.patch"
1366 "pybugz-encode-error.patch"))))
1367 (build-system python-build-system)
1369 `(#:python ,python-2 ; SyntaxError with Python 3
1370 #:tests? #f)) ; no 'test' sub-command
1372 `(("element-tree" ,python2-element-tree)))
1373 (synopsis "Python and command-line interface to Bugzilla")
1375 "PyBugz is a Python library and command-line tool to query the Bugzilla
1376 bug tracking system. It is meant as an aid to speed up interaction with the
1378 (home-page "http://www.liquidx.net/pybugz/")
1379 (license license:gpl2)))
1381 (define-public python2-enum
1383 (name "python2-enum")
1387 (uri (pypi-uri "enum" version))
1390 "13lk3yrwj42vl30kw3c194f739nrfrdg64s6i0v2p636n4k8brsl"))))
1391 (build-system python-build-system)
1393 `(#:python ,python-2))
1394 (home-page "http://pypi.python.org/pypi/enum/")
1395 (synopsis "Robust enumerated type support in Python")
1397 "This provides a module for robust enumerations in Python. It has
1398 been superseded by the Python standard library and is provided only for
1400 ;; Choice of either license.
1401 (license (list license:gpl3+ license:psfl))))
1403 (define-public python-enum34
1405 (name "python-enum34")
1410 (uri (pypi-uri "enum34" version))
1413 "1cgm5ng2gcfrkrm3hc22brl6chdmv67b9zvva9sfs7gn7dwc9n4a"))))
1414 (build-system python-build-system)
1415 (home-page "https://pypi.python.org/pypi/enum34")
1416 (synopsis "Backported Python 3.4 Enum")
1418 "Enum34 is the new Python stdlib enum module available in Python 3.4
1419 backported for previous versions of Python from 2.4 to 3.3.")
1420 (license license:bsd-3)))
1422 (define-public python2-enum34
1423 (package-with-python2 python-enum34))
1425 (define-public python-parse-type
1427 (name "python-parse-type")
1432 (uri (pypi-uri "parse_type" version))
1435 "0g3b6gsdwnm8dpkh2vn34q6dzxm9gl908ggyzcv31n9xbp3vv5pm"))))
1436 (build-system python-build-system)
1438 `(("python-six" ,python-six)
1439 ("python-parse" ,python-parse)))
1441 `(("python-pytest" ,python-pytest)
1442 ("python-pytest-runner" ,python-pytest-runner)))
1443 (home-page "https://github.com/jenisys/parse_type")
1444 (synopsis "Extended parse module")
1446 "Parse_type extends the python parse module.")
1448 `((python2-variant . ,(delay python2-parse-type))))
1449 (license license:bsd-3)))
1451 (define-public python2-parse-type
1452 (let ((base (package-with-python2
1453 (strip-python2-variant python-parse-type))))
1454 (package (inherit base)
1456 `(("python2-enum34" ,python2-enum34)
1457 ,@(package-propagated-inputs base))))))
1459 (define-public python-parse
1461 (name "python-parse")
1466 (uri (pypi-uri "parse" version))
1469 "0f8997xr8nq2nq35iiviq8ningd1zvy59fg503xfpbi2dwhgdkf3"))))
1470 (build-system python-build-system)
1473 (modify-phases %standard-phases
1475 (lambda _ (invoke "python" "test_parse.py"))))))
1476 (home-page "https://github.com/r1chardj0n3s/parse")
1477 (synopsis "Parse strings")
1479 "Parse strings using a specification based on the Python @code{format()}
1481 (license license:x11)))
1483 (define-public python-polib
1485 (name "python-polib")
1489 (uri (pypi-uri "polib" version))
1492 "1pq2hbm3m2q0cjdszk8mc4qa1vl3wcblh5nfyirlfnzb2pcy7zss"))))
1493 (build-system python-build-system)
1494 (home-page "https://bitbucket.org/izi/polib/wiki/Home")
1495 (synopsis "Manipulate, create and modify gettext files")
1496 (description "Polib can manipulate any gettext format (po, pot and mo)
1497 files. It can be used to create po files from scratch or to modify
1499 (license license:expat)))
1501 (define-public python2-polib
1502 (let ((base (package-with-python2 (strip-python2-variant python-polib))))
1505 (arguments `(,@(package-arguments base)
1506 ;; Tests don't work with python2.
1509 (define-public python-poyo
1511 (name "python-poyo")
1516 (uri (pypi-uri "poyo" version))
1519 "1pflivs6j22frz0v3dqxnvc8yb8fb52g11lqr88z0i8cg2m5csg2"))))
1520 (build-system python-build-system)
1521 (home-page "https://github.com/hackebrot/poyo")
1522 (synopsis "Lightweight YAML Parser for Python")
1524 "This package provides a lightweight YAML Parser for Python. It supports
1525 only a chosen subset of the YAML format that is required to parse cookiecutter
1526 user configuration files. It does not have support for serializing into YAML
1527 and is not compatible with JSON.")
1528 (license license:expat)))
1530 (define-public scons
1537 (url "https://github.com/SCons/scons.git")
1539 (file-name (git-file-name name version))
1542 "1xy8jrwz87y589ihcld4hv7wn122sjbz914xn8h50ww77wbhk8hn"))))
1543 (build-system python-build-system)
1545 `(#:use-setuptools? #f ; still relies on distutils
1546 #:tests? #f ; no 'python setup.py test' command
1548 (modify-phases %standard-phases
1549 (add-before 'build 'bootstrap
1551 (substitute* "src/engine/SCons/compat/__init__.py"
1552 (("sys.modules\\[new\\] = imp.load_module\\(old, \\*imp.find_module\\(old\\)\\)")
1553 "sys.modules[new] = __import__(old)"))
1554 (substitute* "src/engine/SCons/Platform/__init__.py"
1555 (("mod = imp.load_module\\(full_name, file, path, desc\\)")
1556 "mod = __import__(full_name)"))
1557 (invoke "python" "bootstrap.py" "build/scons" "DEVELOPER=guix")
1558 (chdir "build/scons")
1560 (home-page "http://scons.org/")
1561 (synopsis "Software construction tool written in Python")
1563 "SCons is a software construction tool. Think of SCons as an improved,
1564 cross-platform substitute for the classic Make utility with integrated
1565 functionality similar to autoconf/automake and compiler caches such as ccache.
1566 In short, SCons is an easier, more reliable and faster way to build
1568 (license license:x11)))
1570 (define-public scons-python2
1572 (inherit (package-with-python2 scons))
1573 (name "scons-python2")))
1575 (define-public python-extras
1577 (name "python-extras")
1582 (uri (pypi-uri "extras" version))
1585 "0khvm08rcwm62wc47j8niyl6h13f8w51c8669ifivjdr23g3cbhk"))))
1586 (build-system python-build-system)
1588 ;; FIXME: Circular dependency on testtools.
1590 (home-page "https://github.com/testing-cabal/extras")
1591 (synopsis "Useful extensions to the Python standard library")
1593 "Extras is a set of extensions to the Python standard library.")
1594 (license license:expat)))
1596 (define-public python2-extras
1597 (package-with-python2 python-extras))
1599 (define-public python-mimeparse
1601 (name "python-mimeparse")
1606 (uri (pypi-uri "python-mimeparse" version))
1609 "0y2g6cl660bpz11srgqyvvm8gmywpgyx8g0xfvbiyr0af0yv1r3n"))))
1610 (build-system python-build-system)
1613 (modify-phases %standard-phases
1616 (invoke "./mimeparse_test.py"))))))
1618 "https://github.com/dbtsai/python-mimeparse")
1619 (synopsis "Python library for parsing MIME types")
1621 "Mimeparse provides basic functions for parsing MIME type names and
1622 matching them against a list of media-ranges.")
1623 (license license:expat)))
1625 (define-public python2-mimeparse
1626 (package-with-python2 python-mimeparse))
1628 (define-public python-miniboa
1630 (name "python-miniboa")
1635 (uri (pypi-uri "miniboa" version))
1638 "09jh3pn4rh7kh7jayanf8jzy6gp03791b5a193w6148cf3i6k9m3"))))
1639 (build-system python-build-system)
1640 (home-page "https://github.com/shmup/miniboa")
1641 (synopsis "Simple, single-threaded Telnet server")
1643 "Miniboa is a simple, asynchronous, single-threaded, poll-based Telnet
1645 (license license:asl2.0)))
1647 (define-public python2-miniboa
1648 (package-with-python2 python-miniboa))
1650 (define-public python-pafy
1652 (name "python-pafy")
1657 (uri (pypi-uri "pafy" version))
1660 "1a7dxi95m1043rxx1r5x3ngb66nwlq6aqcasyqqjzmmmjps4zrim"))))
1661 (build-system python-build-system)
1663 `(#:tests? #f)) ; Currently pafy can not find itself in the tests
1665 ;; Youtube-dl is a python package which is imported in the file
1666 ;; "backend_youtube_dl.py", therefore it needs to be propagated.
1667 `(("youtube-dl" ,youtube-dl)))
1668 (home-page "https://np1.github.io/pafy/")
1669 (synopsis "Retrieve YouTube content and metadata")
1671 "@code{pafy} is a python library to retrieve YouTube content and metadata.")
1672 (license license:lgpl3+)))
1674 (define-public python2-funcsigs
1676 (name "python2-funcsigs")
1680 (uri (pypi-uri "funcsigs" version))
1683 "0l4g5818ffyfmfs1a924811azhjj8ax9xd1cffr1mzd3ycn0zfx7"))))
1684 (build-system python-build-system)
1686 `(#:python ,python-2))
1688 `(("python2-unittest2" ,python2-unittest2)))
1689 (home-page "http://funcsigs.readthedocs.org")
1690 (synopsis "Python function signatures from PEP362")
1692 "Backport of @code{funcsigs} which was introduced in Python 3.3.")
1693 (license license:asl2.0)))
1695 (define-public python2-funcsigs-bootstrap
1697 (inherit python2-funcsigs)
1698 (name "python2-funcsigs-bootstrap")
1702 ,@(package-arguments python2-funcsigs)))))
1704 (define-public python-py
1711 (uri (pypi-uri "py" version))
1714 "0lsy1gajva083pzc7csj1cvbmminb7b4l6a0prdzyb3fd829nqyw"))))
1715 (build-system python-build-system)
1717 ;; FIXME: "ImportError: 'test' module incorrectly imported from
1718 ;; '/gnu/store/...-python-pytest-mimimal-3.0.5/lib/python3.5/site-packages'.
1719 ;; Expected '/tmp/guix-build-python-py-1.4.31.drv-0/py-1.4.31/py'.
1720 ;; Is this module globally installed?"
1723 `(("python-setuptools-scm" ,python-setuptools-scm)))
1724 (home-page "https://github.com/pytest-dev/py")
1725 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1727 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1728 code introspection, and logging.")
1729 (license license:expat)))
1731 (define-public python2-py
1732 (package-with-python2 python-py))
1734 ;; Recent versions of python-fixtures and python-testrepository need
1735 ;; python-pbr for packaging, which itself needs these two packages for
1737 ;; To fix this circular dependency, we use a build of python-pbr, based on the
1738 ;; same source, just without any test dependencies and with tests disabled.
1739 ;; python-pbr-minmal is then used to package python-fixtures and
1740 ;; python-testrepository.
1741 ;; Strictly speaking we currently could remove the test-requirements from the
1742 ;; normal python-pbr package (and save this package) since test are disabled
1743 ;; there anyway. But this may change in future.
1744 (define-public python-pbr-minimal
1746 (name "python-pbr-minimal")
1751 (uri (pypi-uri "pbr" version))
1754 "14fs5acnalnb3h62s7q7av239j541fk0n0z0lawh4h09b1s93s6p"))))
1755 (build-system python-build-system)
1758 (home-page "http://docs.openstack.org/developer/pbr/")
1759 (synopsis "Minimal build of python-pbr used for bootstrapping")
1761 "Used only for bootstrapping python2-pbr, you should not need this.")
1762 (license license:asl2.0)))
1764 (define-public python2-pbr-minimal
1765 (package-with-python2 python-pbr-minimal))
1767 (define-public python-pbr
1769 (inherit python-pbr-minimal)
1772 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1774 `(("git" ,git))) ;; pbr actually uses the "git" binary.
1776 `(("python-fixtures" ,python-fixtures-bootstrap)
1777 ;; discover, coverage, hacking, subunit
1778 ("python-mock" ,python-mock)
1779 ("python-six" ,python-six)
1780 ("python-sphinx" ,python-sphinx)
1781 ("python-testrepository" ,python-testrepository-bootstrap)
1782 ("python-testresources" ,python-testresources-bootstrap)
1783 ("python-testscenarios" ,python-testscenarios-bootstrap)
1784 ("python-testtools" ,python-testtools-bootstrap)
1785 ("python-virtualenv" ,python-virtualenv)))
1786 (synopsis "Enhance the default behavior of Python’s setuptools")
1788 "Python Build Reasonableness (PBR) is a library that injects some useful
1789 and sensible default behaviors into your setuptools run. It will set
1790 versions, process requirements files and generate AUTHORS and ChangeLog file
1791 from git information.
1794 (define-public python2-pbr
1795 (package-with-python2 python-pbr))
1797 (define-public python-pyrsistent
1799 (name "python-pyrsistent")
1801 (home-page "https://github.com/tobgu/pyrsistent")
1804 (uri (pypi-uri "pyrsistent" version))
1807 "1qkh74bm296mp5g3r11lgsksr6bh4w1bf8pji4nmxdlfj542ga1w"))))
1808 (build-system python-build-system)
1810 `(("python-hypothesis" ,python-hypothesis)
1811 ("python-pytest" ,python-pytest)
1812 ("python-pytest-runner" ,python-pytest-runner)))
1814 `(("python-six" ,python-six)))
1815 (synopsis "Persistent data structures for Python")
1817 "Pyrsistent is a number of persistent collections (by some referred to as
1818 functional data structures). Persistent in the sense that they are immutable.
1820 All methods on a data structure that would normally mutate it instead return a
1821 new copy of the structure containing the requested updates. The original
1822 structure is left untouched.")
1823 (license license:expat)))
1825 (define-public python2-pyrsistent
1826 (package-with-python2 python-pyrsistent))
1828 (define-public python-exif-read
1830 (name "python-exif-read")
1834 (uri (pypi-uri "ExifRead" version))
1837 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
1838 (build-system python-build-system)
1839 (arguments `(#:tests? #f)) ; no tests
1840 (home-page "https://github.com/ianare/exif-py")
1841 (synopsis "Python library to extract EXIF data from image files")
1843 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
1845 (license license:bsd-3)))
1847 (define-public python2-exif-read
1848 (package-with-python2 python-exif-read))
1850 (define-public python-pyld
1852 (name "python-pyld")
1856 (uri (pypi-uri "PyLD" version))
1859 "1ywbdbsrkg533qh8xn9ifjh2mvam6v5msrjyqq73jfpvcp89qvff"))))
1860 (build-system python-build-system)
1861 (home-page "https://github.com/digitalbazaar/pyld")
1862 (synopsis "Python implementation of the JSON-LD specification")
1864 "PyLD is an implementation of the JSON-LD specification.")
1865 (license license:bsd-3)))
1867 (define-public python2-pyld
1868 (package-with-python2 python-pyld))
1870 (define-public python-click
1872 (name "python-click")
1877 (uri (pypi-uri "click" version))
1880 "1mzjixd4vjbjvzb6vylki9w1556a9qmdh35kzmq6cign46av952v"))))
1881 (build-system python-build-system)
1884 (modify-phases %standard-phases
1885 (add-after 'unpack 'fix-paths
1886 (lambda* (#:key inputs #:allow-other-keys)
1887 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
1888 "cross-libc" "libc"))))
1889 (substitute* "click/_unicodefun.py"
1891 (string-append "'" glibc "/bin/locale'"))))
1895 (invoke "python" "-m" "pytest"))))))
1897 `(("python-pytest" ,python-pytest)))
1898 (home-page "https://palletsprojects.com/p/click/")
1899 (synopsis "Command line library for Python")
1901 "Click is a Python package for creating command line interfaces in a
1902 composable way with as little code as necessary. Its name stands for
1903 \"Command Line Interface Creation Kit\". It's highly configurable but comes
1904 with sensible defaults out of the box.")
1905 (license license:bsd-3)))
1907 (define-public python2-click
1908 (package-with-python2 python-click))
1910 (define-public python-wheel
1912 (name "python-wheel")
1917 (uri (pypi-uri "wheel" version))
1920 "0ii6f34rvpjg3nmw4bc2h7fhdsy38y1h93hghncfs5akfrldmj8h"))))
1921 (build-system python-build-system)
1923 ;; FIXME: The test suite runs "python setup.py bdist_wheel", which in turn
1924 ;; fails to find the newly-built bdist_wheel library, even though it is
1925 ;; available on PYTHONPATH. What search path is consulted by setup.py?
1927 (home-page "https://bitbucket.org/pypa/wheel/")
1928 (synopsis "Format for built Python packages")
1930 "A wheel is a ZIP-format archive with a specially formatted filename and
1931 the @code{.whl} extension. It is designed to contain all the files for a PEP
1932 376 compatible install in a way that is very close to the on-disk format. Many
1933 packages will be properly installed with only the @code{Unpack} step and the
1934 unpacked archive preserves enough information to @code{Spread} (copy data and
1935 scripts to their final locations) at any later time. Wheel files can be
1936 installed with a newer @code{pip} or with wheel's own command line utility.")
1937 (license license:expat)))
1939 (define-public python2-wheel
1940 (package-with-python2 python-wheel))
1942 (define-public python-vcversioner
1944 (name "python-vcversioner")
1945 (version "2.16.0.0")
1949 (uri (pypi-uri "vcversioner" version))
1952 "16z10sm78jd7ca3jbkgc3q5i8a8q7y1h21q1li21yy3rlhbhrrns"))))
1953 (build-system python-build-system)
1954 (synopsis "Python library for version number discovery")
1955 (description "Vcversioner is a Python library that inspects tagging
1956 information in a variety of version control systems in order to discover
1958 (home-page "https://github.com/habnabit/vcversioner")
1959 (license license:isc)))
1961 (define-public python2-vcversioner
1962 (package-with-python2 python-vcversioner))
1964 (define-public python-jdcal
1966 (name "python-jdcal")
1971 (uri (pypi-uri "jdcal" version))
1974 "1ja6j2xq97bsl6rv09mhdx7n0xnrsfx0mj5xqza0mxghqmkm02pa"))))
1975 (build-system python-build-system)
1977 `(#:phases (modify-phases %standard-phases
1980 (invoke "pytest"))))))
1982 `(("python-pytest" ,python-pytest)))
1983 (home-page "https://github.com/phn/jdcal")
1984 (synopsis "Functions to convert between Julian dates Gregorian dates")
1985 (description "This Python library provides functions for converting
1986 between Julian dates and Gregorian dates.")
1987 (license license:bsd-2)))
1989 (define-public python2-jdcal
1990 (package-with-python2 python-jdcal))
1992 (define-public python-jsonschema
1994 (name "python-jsonschema")
1998 (uri (pypi-uri "jsonschema" version))
2001 "03g20i1xfg4qdlk4475pl4pp7y0h37g1fbgs5qhy678q9xb822hc"))))
2002 (build-system python-build-system)
2005 (modify-phases %standard-phases
2008 (setenv "PYTHONPATH" (string-append ".:" (getenv "PYTHONPATH")))
2009 (invoke "trial" "jsonschema"))))))
2011 `(("python-setuptools_scm" ,python-setuptools-scm)
2012 ("python-twisted" ,python-twisted)))
2014 `(("python-attrs" ,python-attrs)
2015 ("python-pyrsistent" ,python-pyrsistent)
2016 ("python-six" ,python-six)))
2017 (home-page "https://github.com/Julian/jsonschema")
2018 (synopsis "Implementation of JSON Schema for Python")
2020 "Jsonschema is an implementation of JSON Schema for Python.")
2021 (license license:expat)
2022 (properties `((python2-variant . ,(delay python2-jsonschema))))))
2024 (define-public python2-jsonschema
2025 (let ((jsonschema (package-with-python2
2026 (strip-python2-variant python-jsonschema))))
2027 (package (inherit jsonschema)
2029 `(("python2-functools32" ,python2-functools32)
2030 ,@(package-propagated-inputs jsonschema))))))
2032 ;; This old version is still required by docker-compose as of 1.24.0.
2033 (define-public python-jsonschema-2.6
2035 (name "python-jsonschema")
2039 (uri (pypi-uri "jsonschema" version))
2042 "00kf3zmpp9ya4sydffpifn0j0mzm342a2vzh82p6r0vh10cg7xbg"))))
2043 (build-system python-build-system)
2046 (modify-phases %standard-phases
2047 (replace 'check (lambda _ (invoke "nosetests"))))))
2049 `(("python-nose" ,python-nose)
2050 ("python-vcversioner" ,python-vcversioner)))
2051 (home-page "https://github.com/Julian/jsonschema")
2052 (synopsis "Implementation of JSON Schema for Python")
2054 "Jsonschema is an implementation of JSON Schema for Python.")
2055 (license license:expat)
2056 (properties `((python2-variant . ,(delay python2-jsonschema))))))
2058 (define-public python-schema
2060 (name "python-schema")
2065 (uri (pypi-uri "schema" version))
2068 "1lw28j9w9vxyigg7vkfkvi6ic9lgjkdnfvnxdr7pklslqvzmk2vm"))))
2069 (build-system python-build-system)
2071 `(("python-pytest" ,python-pytest)))
2072 (home-page "https://github.com/keleshev/schema")
2073 (synopsis "Simple data validation library")
2075 "@code{python-schema} is a library for validating Python data
2076 structures, such as those obtained from config-files, forms, external
2077 services or command-line parsing, converted from JSON/YAML (or
2078 something else) to Python data-types.")
2079 (license license:psfl)))
2081 (define-public python2-schema
2082 (package-with-python2 python-schema))
2084 (define-public python-schema-0.5
2085 (package (inherit python-schema)
2090 (uri (pypi-uri "schema" version))
2093 "10zqvpaky51kgb8nd42bk7jwl8cn2zvayxjpdc1wwmpybj92x67s"))))))
2095 (define-public python2-schema-0.5
2096 (package-with-python2 python-schema-0.5))
2098 (define-public python-kitchen
2100 (name "python-kitchen")
2105 (uri (pypi-uri "kitchen" version))
2108 "1zakh6l0yjvwic9p0nkvmbidpnkygkxbigh2skmb5gccyrhbp7xg"))))
2109 (build-system python-build-system)
2111 `(("python-chardet" ,python-chardet)))
2112 (home-page "https://github.com/fedora-infra/kitchen")
2113 (synopsis "Python API for snippets")
2114 (description "@code{kitchen} module provides a python API for all sorts of
2115 little useful snippets of code that everybody ends up writing for their projects
2116 but never seem big enough to build an independent release. Use kitchen and stop
2117 cutting and pasting that code over and over.")
2118 (license (list license:lgpl2.1+
2119 ;; subprocess.py, test_subprocess.py,
2120 ;; kitchen/pycompat25/defaultdict.py:
2123 (define-public python2-kitchen
2124 (package-with-python2 python-kitchen))
2126 (define-public python-unidecode
2128 (name "python-unidecode")
2132 (uri (pypi-uri "Unidecode" version))
2135 "1s6cp2lv4m0f00hjckjz8p6m7d3n3v16jvg353llf5ia1iqsnsib"))))
2136 (build-system python-build-system)
2137 (home-page "https://pypi.python.org/pypi/Unidecode")
2138 (synopsis "ASCII transliterations of Unicode text")
2140 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2141 useful when integrating with legacy code that doesn't support Unicode, or for
2142 ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2143 machine identifiers from human-readable Unicode strings that should still be
2144 somewhat intelligible.")
2145 (license license:gpl2+)))
2147 (define-public python2-unidecode
2148 (package-with-python2 python-unidecode))
2150 (define-public python-pyjwt
2152 (name "python-pyjwt")
2157 (uri (pypi-uri "PyJWT" version))
2160 "15hflax5qkw1v6nssk1r0wkj83jgghskcmn875m3wgvpzdvajncd"))
2161 (modules '((guix build utils)))
2164 (for-each delete-file-recursively
2165 (find-files "." "\\.pyc$"))
2167 (build-system python-build-system)
2169 `(("python-pytest" ,python-pytest)
2170 ("python-pytest-cov" ,python-pytest-cov)
2171 ("python-pytest-runner" ,python-pytest-runner)))
2172 (home-page "https://github.com/progrium/pyjwt")
2173 (synopsis "JSON Web Token implementation in Python")
2175 "PyJWT is a JSON Web Token implementation written in Python.")
2176 (license license:expat)))
2178 (define-public python2-pyjwt
2179 (package-with-python2 python-pyjwt))
2181 (define-public python-pykka
2183 (name "python-pykka")
2188 (uri (pypi-uri "Pykka" version))
2191 "049w3r0mdnnw7xv19jiq7rvls9k7xs73x05b4qs5d6z4vvmgyiz8"))))
2192 (build-system python-build-system)
2194 `(("python-mock" ,python-mock)
2195 ("python-nose" ,python-nose)
2196 ("python-gevent" ,python-gevent)
2197 ("python-eventlet" ,python-eventlet)))
2198 (home-page "https://www.pykka.org/")
2199 (synopsis "Pykka is a Python implementation of the actor model")
2201 "Pykka is a Python implementation of the actor model.
2202 The actor model introduces some simple rules to control the sharing
2203 of state and cooperation between execution units, which makes it
2204 easier to build concurrent applications.")
2205 (license license:asl2.0)))
2207 (define-public python2-pykka
2208 (package-with-python2 python-pykka))
2210 (define-public python-pymsgbox
2212 (name "python-pymsgbox")
2218 ;; LICENSE.txt is not present on pypi
2219 (url "https://github.com/asweigart/PyMsgBox")
2220 (commit "55926b55f46caa969c5ddb87990ebea2737bd66f")))
2221 (file-name (git-file-name name version))
2224 "0zy7rjfpwlrd8b64j7jk2lb8m2npc21rnpwakpfvwgl4nxdy80rg"))))
2226 ;; Circular dependency to run tests:
2227 ;; Tests need pyautogui, which depends on pymsgbox.
2229 (build-system python-build-system)
2230 (home-page "https://github.com/asweigart/PyMsgBox")
2231 (synopsis "Python module for JavaScript-like message boxes")
2233 "PyMsgBox is a simple, cross-platform, pure Python module for
2234 JavaScript-like message boxes. Types of dialog boxes include:
2242 (license license:bsd-3)))
2244 (define-public python-pympler
2246 (name "python-pympler")
2247 (home-page "https://pythonhosted.org/Pympler/")
2251 (uri (pypi-uri "Pympler" version))
2254 "0ki7bqp1h9l1xc2k1h4vjyzsgs20i8ingvcdhszyi72s28wyf4bs"))))
2255 (build-system python-build-system)
2257 `(#:phases (modify-phases %standard-phases
2259 (add-after 'install 'check
2260 (lambda* (#:key inputs outputs #:allow-other-keys)
2261 (add-installed-pythonpath inputs outputs)
2262 (invoke "python" "setup.py" "test"))))))
2263 (synopsis "Measure, monitor and analyze memory behavior")
2265 "Pympler is a development tool to measure, monitor and analyze
2266 the memory behavior of Python objects in a running Python application.
2268 By pympling a Python application, detailed insight in the size and the
2269 lifetime of Python objects can be obtained. Undesirable or unexpected
2270 runtime behavior like memory bloat and other @samp{pymples} can easily
2273 A web profiling frontend exposes process statistics, garbage
2274 visualisation and class tracker statistics.")
2275 (license license:asl2.0)))
2277 (define-public python2-pympler
2278 (package-with-python2 python-pympler))
2280 (define-public python-itsdangerous
2282 (name "python-itsdangerous")
2287 (uri (pypi-uri "itsdangerous" version))
2290 "068zpbksq5q2z4dckh2k1zbcq43ay74ylqn77rni797j0wyh66rj"))))
2291 (build-system python-build-system)
2292 (home-page "https://palletsprojects.com/p/itsdangerous/")
2293 (synopsis "Python library for passing data to/from untrusted environments")
2295 "Itsdangerous provides various helpers to pass trusted data to untrusted
2296 environments and back.")
2297 (license license:bsd-3)))
2299 (define-public python2-itsdangerous
2300 (package-with-python2 python-itsdangerous))
2302 (define-public python-pyyaml
2304 (name "python-pyyaml")
2309 (uri (pypi-uri "PyYAML" version))
2312 "1gx603g484z46cb74j9rzr6sjlh2vndxayicvlyhxdz98lhhkwry"))))
2313 (build-system python-build-system)
2315 `(("libyaml" ,libyaml)))
2316 (home-page "http://pyyaml.org/wiki/PyYAML")
2317 (synopsis "YAML parser and emitter for Python")
2319 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2320 complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2321 API, and sensible error messages. PyYAML supports standard YAML tags and
2322 provides Python-specific tags that allow to represent an arbitrary Python
2324 (license license:expat)))
2326 (define-public python2-pyyaml
2327 (package-with-python2 python-pyyaml))
2329 (define-public python-vine
2331 (name "python-vine")
2336 (uri (pypi-uri "vine" version))
2339 "0wkskb2hb494v9gixqnf4bl972p4ibcmxdykzpwjlfa5picns4aj"))))
2340 (build-system python-build-system)
2342 `(("python-pytest" ,python-pytest)
2343 ("python-case" ,python-case)))
2344 (home-page "https://github.com/celery/vine")
2345 (synopsis "Promises for Python")
2347 "@code{vine} provides a special implementation of promises in that it can
2348 be used both for \"promise of a value\" and lazy evaluation. The biggest
2349 upside for this is that everything in a promise can also be a promise,
2350 e.g. filters, callbacks and errbacks can all be promises.")
2351 (license license:bsd-3)))
2353 (define-public python-virtualenv
2355 (name "python-virtualenv")
2360 (uri (pypi-uri "virtualenv" version))
2363 "0242cg3hdq3qdvx5flyrki8lpwlgwf5k45c21ks5049fv7ygm6gq"))))
2364 (build-system python-build-system)
2367 (modify-phases %standard-phases
2368 (add-before 'check 'disable-failing-test
2370 ;; Disable failing test. See upstream bug report
2371 ;; https://github.com/pypa/virtualenv/issues/957
2372 (substitute* "tests/test_virtualenv.py"
2373 (("skipif.*") "skipif(True, reason=\"Guix\")\n"))
2376 `(("python-mock" ,python-mock)
2377 ("python-pytest" ,python-pytest)))
2378 (home-page "https://virtualenv.pypa.io/")
2379 (synopsis "Virtual Python environment builder")
2381 "Virtualenv is a tool to create isolated Python environments.")
2382 (license license:expat)))
2384 (define-public python2-virtualenv
2385 (package-with-python2 python-virtualenv))
2387 (define-public python-markupsafe
2389 (name "python-markupsafe")
2394 (uri (pypi-uri "MarkupSafe" version))
2397 "0sqipg4fk7xbixqd8kq6rlkxj664d157bdwbh93farcphf92x1r9"))))
2398 (build-system python-build-system)
2400 `(#:modules ((ice-9 ftw)
2404 (guix build python-build-system))
2405 #:phases (modify-phases %standard-phases
2408 (let ((cwd (getcwd))
2409 (libdir (find (cut string-prefix? "lib." <>)
2410 (scandir "build"))))
2411 (setenv "PYTHONPATH"
2412 (string-append cwd "/build/" libdir ":"
2413 (getenv "PYTHONPATH")))
2414 (invoke "pytest" "-vv")))))))
2416 `(("python-pytest" ,python-pytest)))
2417 (home-page "https://github.com/mitsuhiko/markupsafe")
2418 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2420 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2422 (license license:bsd-3)))
2424 (define-public python2-markupsafe
2425 (package-with-python2 python-markupsafe))
2427 (define-public python-jinja2
2429 (name "python-jinja2")
2434 (uri (pypi-uri "Jinja2" version))
2437 "04shqrs56aj04ipyqykj512rw2l0zfammvj9krawzxz7xc14yp06"))))
2438 (build-system python-build-system)
2440 `(("python-markupsafe" ,python-markupsafe)))
2441 (home-page "http://jinja.pocoo.org/")
2442 (synopsis "Python template engine")
2444 "Jinja2 is a small but fast and easy to use stand-alone template engine
2445 written in pure Python.")
2446 (license license:bsd-3)))
2448 (define-public python2-jinja2
2449 (package-with-python2 python-jinja2))
2451 (define-public python-jinja2-time
2453 (name "python-jinja2-time")
2458 (uri (pypi-uri "jinja2-time" version))
2461 "0h0dr7cfpjnjj8bgl2vk9063a53649pn37wnlkd8hxjy656slkni"))))
2462 (build-system python-build-system)
2464 `(("python-arrow" ,python-arrow)
2465 ("python-jinja2" ,python-jinja2)))
2467 "https://github.com/hackebrot/jinja2-time")
2468 (synopsis "Jinja2 Extension for Dates and Times")
2470 "This package provides an extension for the template engine Jinja2. It
2471 adds a 'now' tag providing a convenient access to the arrow.now() API from
2472 templates. A format string can be provided to control the output.")
2473 (license license:expat)))
2475 (define-public python-pystache
2477 (name "python-pystache")
2481 (uri (pypi-uri "pystache" version))
2484 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2485 (build-system python-build-system)
2487 '(#:tests? #f)) ; FIXME: Python 3 tests are failing.
2488 (home-page "http://defunkt.io/pystache/")
2489 (synopsis "Python logic-less template engine")
2491 "Pystache is a Python implementation of the framework agnostic,
2492 logic-free templating system Mustache.")
2493 (license license:expat)
2494 (properties `((python2-variant . ,(delay python2-pystache))))))
2496 (define-public python2-pystache
2497 (package (inherit (package-with-python2
2498 (strip-python2-variant python-pystache)))
2500 `(#:python ,python-2
2502 (modify-phases %standard-phases
2505 (invoke "python" "test_pystache.py"))))))))
2507 (define-public python-joblib
2509 (name "python-joblib")
2513 (uri (pypi-uri "joblib" version))
2516 "0612nazad8dxmn3xghfrmjax6456l4xy6hn9cngs7vydi14ds7v5"))))
2517 (build-system python-build-system)
2520 (modify-phases %standard-phases
2522 (lambda _ (invoke "pytest" "-v" "joblib"))))))
2524 `(("python-pytest" ,python-pytest)))
2525 (home-page "https://joblib.readthedocs.io/")
2526 (synopsis "Using Python functions as pipeline jobs")
2528 "Joblib is a set of tools to provide lightweight pipelining in Python.
2529 In particular, joblib offers: transparent disk-caching of the output values
2530 and lazy re-evaluation (memoize pattern), easy simple parallel computing
2531 logging and tracing of the execution.")
2532 (license license:bsd-3)))
2534 (define-public python2-joblib
2535 (package-with-python2 python-joblib))
2537 (define-public python-daemon
2539 (name "python-daemon")
2544 (uri (pypi-uri "python-daemon" version))
2547 "09fcjdjzk9ywmpnrj62iyxqgcygzdafsz41qlrk2dknzbagcmzmg"))))
2548 (build-system python-build-system)
2551 (modify-phases %standard-phases
2552 (add-before 'check 'disable-tests
2554 ;; FIXME: Determine why test fails
2555 (substitute* "test/test_daemon.py"
2556 (("test_detaches_process_context")
2557 "skip_test_detaches_process_context"))
2560 `(("python-lockfile" ,python-lockfile)))
2562 `(("python-unittest2" ,python-unittest2)
2563 ("python-testtools" ,python-testtools)
2564 ("python-testscenarios" ,python-testscenarios)
2565 ("python-mock" ,python-mock)
2566 ("python-docutils" ,python-docutils)))
2567 (home-page "https://pagure.io/python-daemon/")
2568 (synopsis "Python library for making a Unix daemon process")
2569 (description "Python-daemon is a library that assists a Python program to
2570 turn itself into a well-behaved Unix daemon process, as specified in PEP 3143.
2572 This library provides a @code{DaemonContext} class that manages the following
2573 important tasks for becoming a daemon process:
2575 @item Detach the process into its own process group.
2576 @item Set process environment appropriate for running inside a chroot.
2577 @item Renounce suid and sgid privileges.
2578 @item Close all open file descriptors.
2579 @item Change the working directory, uid, gid, and umask.
2580 @item Set appropriate signal handlers.
2581 @item Open new file descriptors for stdin, stdout, and stderr.
2582 @item Manage a specified PID lock file.
2583 @item Register cleanup functions for at-exit processing.
2585 ;; Only setup.py is gpl3+, everything else is apache 2.0 licensed.
2586 (license (list license:asl2.0 license:gpl3+))))
2588 (define-public python-anytree
2590 (name "python-anytree")
2594 (uri (pypi-uri "anytree" version))
2597 "1aycpc387wqz7h9w2p53qxn43qsh3m6by6ak4kkc66x9aprr63rz"))))
2598 (build-system python-build-system)
2600 `(("python-six" ,python-six)))
2603 ("graphviz" ,graphviz) ;for 'dot'
2604 ("python-nose" ,python-nose)))
2605 (home-page "https://github.com/c0fec0de/anytree")
2606 (synopsis "Lightweight tree data library")
2608 "@code{anytree} is a simple, lightweight, and extensible tree data
2609 structure for Python.")
2610 (license license:asl2.0)))
2612 (define-public python-docutils
2614 (name "python-docutils")
2619 (uri (pypi-uri "docutils" version))
2622 "0x22fs3pdmr42kvz6c654756wja305qv6cx1zbhwlagvxgr4xrji"))))
2623 (build-system python-build-system)
2625 '(#:tests? #f)) ; no setup.py test command
2626 (home-page "http://docutils.sourceforge.net/")
2627 (synopsis "Python Documentation Utilities")
2629 "Docutils is a modular system for processing documentation into useful
2630 formats, such as HTML, XML, and LaTeX. For input Docutils supports
2632 ;; Most of the source code is public domain, but some source files are
2633 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2634 (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+))))
2636 (define-public python2-docutils
2637 (package-with-python2 python-docutils))
2639 (define-public python-pygments
2641 (name "python-pygments")
2646 (uri (pypi-uri "Pygments" version))
2649 "1zmhnswy0wxfn0xprs9aqsvx2c3kmzfn2wx14q8cv3vpkxdamj4q"))))
2650 (build-system python-build-system)
2652 ;; FIXME: Tests require sphinx, which depends on this.
2654 (home-page "http://pygments.org/")
2655 (synopsis "Syntax highlighting")
2657 "Pygments is a syntax highlighting package written in Python.")
2658 (license license:bsd-2)))
2660 (define-public python2-pygments
2661 (package-with-python2 python-pygments))
2663 (define-public python-bumpversion
2665 (name "python-bumpversion")
2670 (uri (pypi-uri "bumpversion" version))
2673 "0zn7694yfipxg35ikkfh7kvgl2fissha3dnqad2c5bvsvmrwhi37"))))
2674 (build-system python-build-system)
2675 (home-page "https://github.com/peritus/bumpversion")
2676 (synopsis "Tool to bump software version")
2677 (description "This tool provides a command-line interface (CLI) to bump a
2678 software version simply.")
2679 (license license:expat)))
2681 (define-public python-deprecated
2683 (name "python-deprecated")
2689 (url "https://github.com/tantale/deprecated.git")
2690 (commit (string-append "v" version))))
2691 (file-name (git-file-name name version))
2694 "14909glxxwwc4b9qpz2b9jdriwzi5n65ichw85xqppap5f79wcwz"))))
2695 (build-system python-build-system)
2697 `(#:phases (modify-phases %standard-phases
2700 (invoke "pytest"))))))
2702 `(("python-wrapt" ,python-wrapt)))
2704 `(("python-bumpversion" ,python-bumpversion)
2705 ("python-pytest" ,python-pytest)
2706 ("python-pytest-cov" ,python-pytest-cov)
2707 ("python-sphinx" ,python-sphinx)
2708 ("python-tox" ,python-tox)))
2709 (home-page "https://github.com/tantale/deprecated")
2710 (synopsis "Python decorator to deprecate classes, functions or methods")
2711 (description "The @code{deprecated} decorator provides a convenient way to deprecate
2712 to deprecate classes, functions or methods.")
2713 (license license:expat)))
2715 (define-public python-pygithub
2717 (name "python-pygithub")
2720 ;; We fetch from the Git repo because there are no tests in the PyPI
2725 (url "https://github.com/PyGithub/PyGithub.git")
2726 (commit (string-append "v" version))))
2727 (file-name (git-file-name name version))
2729 (base32 "1625v558xga5mwhl9jqmibywy5qafmg1vqrirqz6zfq1la1d22mw"))))
2730 (build-system python-build-system)
2732 `(#:phases (modify-phases %standard-phases
2733 ;; Some tests rely on the network.
2734 (add-after 'unpack 'disable-failing-tests
2736 (substitute* "tests/Issue142.py"
2737 (("testDecodeJson") "disabled_testDecodeJson"))
2739 (add-before 'check 'prepare-for-tests
2741 (for-each (lambda (f)
2743 (find-files "./tests"))
2744 (system* "python" "-m" "lib2to3" "-w" "-n" "tests")
2745 (setenv "PYTHONPATH"
2746 (string-append "./tests:" (getenv "PYTHONPATH")))
2749 `(("python-deprecated" ,python-deprecated)
2750 ("python-pyjwt" ,python-pyjwt)
2751 ("python-requests" ,python-requests)))
2752 (native-inputs `(("python-httpretty" ,python-httpretty)))
2753 (home-page "https://pygithub.readthedocs.io/en/latest/")
2754 (synopsis "Python library for the GitHub API")
2755 (description "This library allows managing GitHub resources such as
2756 repositories, user profiles, and organizations in your Python applications,
2757 using version 3 of the GitHub application programming interface (API).")
2758 (license license:lgpl3+)))
2760 (define-public python-rellu
2762 (name "python-rellu")
2767 (uri (pypi-uri "rellu" version))
2770 "1w0arpj1sm7vh29nrbnca4pnp8sx42l07r17inwqcjjf9bhng66x"))))
2771 (build-system python-build-system)
2773 `(("python-invoke" ,python-invoke)
2774 ("python-pygithub" ,python-pygithub)))
2775 (home-page "https://github.com/robotframework/rellu")
2776 (synopsis "Utilities to create PyPI releases")
2777 (description "This collection of utilities contains tooling and templates
2778 to assist in creating releases on GitHub and publishing them on PyPI. It is
2779 designed to be used by Robot Framework and tools and libraries in its
2780 ecosystem, but can naturally be used also by other projects.")
2781 (license license:asl2.0)))
2783 (define-public python-robotframework
2785 (name "python-robotframework")
2787 ;; There are no tests in the PyPI archive.
2792 (url "https://github.com/robotframework/robotframework.git")
2793 (commit (string-append "v" version))))
2794 (file-name (git-file-name name version))
2796 (base32 "16gnxy0qinh8fhs0qvhff5z2xh49c3cqgm0d7bfjw120df6x7fym"))
2797 (patches (search-patches
2798 "python-robotframework-honor-source-date-epoch.patch"))))
2799 (build-system python-build-system)
2801 `(#:phases (modify-phases %standard-phases
2802 (add-before 'build 'build-and-install-doc
2803 (lambda* (#:key outputs #:allow-other-keys)
2804 (let* ((doc-output (assoc-ref outputs "doc"))
2805 (doc (string-append doc-output "/share/"
2806 ,name "-" ,version "/")))
2807 (invoke "invoke" "library-docs" "all")
2809 (copy-recursively "doc/libraries"
2810 (string-append doc "/libraries"))
2814 (invoke "python" "utest/run.py"))))))
2816 `(("python-invoke" ,python-invoke)
2817 ("python-rellu" ,python-rellu)
2818 ("python:tk" ,python "tk"))) ;used when building the HTML doc
2819 (outputs '("out" "doc"))
2820 (home-page "https://robotframework.org")
2821 (synopsis "Generic automation framework")
2822 (description "Robot Framework is a generic automation framework for
2823 acceptance testing, acceptance test driven development (ATDD), and robotic
2824 process automation (RPA).")
2825 (license license:asl2.0)))
2827 (define-public python-robotframework-lint
2828 ;; There is no properly tagged release; the commit below seems to correspond
2829 ;; to the 0.9 stable release available from PyPI. The tests are not
2830 ;; included in the PyPI archive, so we fetch the sources from the upstream
2832 (let ((commit "e851879bab1f63e4e53b34a4dc8a67ed95102830")
2835 (name "python-robotframework-lint")
2836 (version (git-version "0.9.0" revision commit))
2841 (url "https://github.com/boakley/robotframework-lint.git")
2843 (file-name (git-file-name name version))
2846 "1p6fknqg5sb9qz5857ji4a877657vgfjm5v3zn45994parx6ml1m"))))
2847 (build-system python-build-system)
2850 (modify-phases %standard-phases
2853 (invoke "python" "-m" "robot" "-A"
2854 "tests/conf/default.args" "tests"))))))
2856 `(("python-robotframework" ,python-robotframework)))
2857 (home-page "https://github.com/boakley/robotframework-lint/")
2858 (synopsis "Static analysis tool (linter) for Robot Framework")
2859 (description "This package provides the @code{rflint} command-line
2860 utility, a static analysis tool (linter) for Robot Framework source files.")
2861 (license license:asl2.0))))
2863 (define-public python-robotframework-sshlibrary
2865 (name "python-robotframework-sshlibrary")
2867 ;; There are no tests in the PyPI archive.
2872 (url "https://github.com/robotframework/SSHLibrary.git")
2873 (commit (string-append "v" version))))
2874 (file-name (git-file-name name version))
2877 "1mk6dz2jqqndbx4yji09012q6rmadnqdywi7czvj62b0s07dr3r2"))))
2878 (build-system python-build-system)
2881 (modify-phases %standard-phases
2882 (add-before 'build 'build-and-install-doc
2883 (lambda* (#:key outputs #:allow-other-keys)
2884 (let* ((doc-output (assoc-ref outputs "doc"))
2885 (doc (string-append doc-output "/share/"
2886 ,name "-" ,version "/")))
2887 (invoke "chmod" "-R" "+w" "docs")
2888 (invoke "invoke" "kw-docs" "project-docs")
2890 (for-each delete-file (find-files "docs" "\\.rst"))
2891 (copy-recursively "docs" doc)
2895 ;; Some tests require an SSH server; we remove them.
2896 (delete-file "utest/test_client_api.py")
2897 (delete-file "utest/test_scp.py")
2898 (invoke "python" "utest/run.py"))))))
2900 `(("python-robotframework" ,python-robotframework)
2901 ("python-paramiko" ,python-paramiko)
2902 ("python-scp" ,python-scp)))
2904 `(("openssh" ,openssh)
2906 ;; To generate the documentation
2907 ("python-docutils" ,python-docutils)
2908 ("python-invoke" ,python-invoke)
2909 ("python-pygments" ,python-pygments)
2910 ("python-rellu" ,python-rellu)))
2911 (outputs '("out" "doc"))
2912 (home-page "https://github.com/robotframework/SSHLibrary")
2913 (synopsis "Robot Framework library for SSH and SFTP")
2914 (description "SSHLibrary is a Robot Framework library providing support
2915 for SSH and SFTP. It has the following main usages:
2917 @item Executing commands on the remote machine, either blocking or non-blocking.
2918 @item Writing and reading in an interactive shell.
2919 @item Transferring files and directories over SFTP.
2920 @item Ensuring that files and directories exist on the remote machine.
2922 (license license:asl2.0)))
2924 (define-public python-scp
2931 (uri (pypi-uri "scp" version))
2934 "1crlpw9lnn58fs1c1rmh7s7s9y5gkgpgjsqlvg9qa51kq1knx7gg"))))
2935 (build-system python-build-system)
2937 '(#:tests? #f)) ;tests require an SSH server
2939 `(("python-paramiko" ,python-paramiko)))
2940 (home-page "https://github.com/jbardin/scp.py")
2941 (synopsis "SCP protocol module for Python and Paramiko")
2942 (description "The scp module extends the Paramiko library to send and
2943 receive files via the SCP1 protocol, as implemented by the OpenSSH
2944 @command{scp} program.")
2945 (license license:gpl2+)))
2947 (define-public python-rst.linker
2949 (name "python-rst.linker")
2954 (uri (pypi-uri "rst.linker" version))
2956 (base32 "0pqsfqqx8h0pq21k8l3k62kznrgaj2ala93c64s4d9rpbr4mgkd2"))))
2957 (build-system python-build-system)
2959 `(("python-dateutil" ,python-dateutil)
2960 ("python-six" ,python-six)))
2962 `(("python-setuptools-scm" ,python-setuptools-scm)))
2963 ;; Test would require path.py, which would introduce a cyclic dependence.
2964 (arguments `(#:tests? #f))
2965 ;; Note: As of version 1.7 the documentation is not worth building.
2966 (home-page "https://github.com/jaraco/rst.linker")
2967 (synopsis "Sphinx plugin to add links and timestamps")
2968 (description "rst.linker allows to automatically replace text by a
2969 reStructuredText external reference or timestamps. It's primary purpose is to
2970 augment the changelog, but it can be used for other documents, too.")
2971 (license license:expat)))
2973 (define-public python2-rst.linker
2974 (package-with-python2 python-rst.linker))
2976 (define-public python-feedgenerator
2978 (name "python-feedgenerator")
2983 (uri (pypi-uri "feedgenerator" version))
2986 "01mirwkm7xfx539hmvj7g9da1j51gw5lsx74dr0glizskjm5vq2s"))
2987 (modules '((guix build utils)))
2990 ;; Remove pre-compiled .pyc files from source.
2991 (for-each delete-file-recursively
2992 (find-files "." "__pycache__" #:directories? #t))
2993 (for-each delete-file (find-files "." "\\.pyc$"))
2995 (build-system python-build-system)
2997 `(("python-pytz" ,python-pytz)
2998 ("python-six" ,python-six)))
2999 (home-page "https://github.com/getpelican/feedgenerator")
3001 "Standalone version of Django's Atom/RSS feed generator")
3003 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
3004 which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
3005 (license license:bsd-3)))
3007 (define-public python2-feedgenerator
3008 (package-with-python2 python-feedgenerator))
3010 (define-public python-toml
3012 (name "python-toml")
3017 (uri (pypi-uri "toml" version))
3020 "0bdbpbip67wdm6c7xwc6mmbmskyradj4cdxn1iibj4fcx1nbv1lf"))))
3021 (build-system python-build-system)
3023 `(#:tests? #f)) ;no tests suite in release
3024 (home-page "https://github.com/uiri/toml")
3025 (synopsis "Library for TOML")
3027 "@code{toml} is a library for parsing and creating Tom's Obvious, Minimal
3028 Language (TOML) configuration files.")
3029 (license license:expat)))
3031 (define-public python-jsonrpc-server
3033 (name "python-jsonrpc-server")
3038 (uri (pypi-uri "python-jsonrpc-server" version))
3041 "0ddgdp26dfxaz6isjbb12974b3rxavgsqrn2zrmck62cmipg5g05"))))
3042 (build-system python-build-system)
3044 `(("python-future" ,python-future)
3045 ("python-mock" ,python-mock)
3046 ("python-pytest" ,python-pytest)
3047 ("python-ujson" ,python-ujson)))
3049 "https://github.com/palantir/python-jsonrpc-server")
3050 (synopsis "JSON RPC 2.0 server library")
3052 "This package provides a JSON RPC 2.0 server library for Python.")
3053 (license license:expat)))
3055 (define-public python-pydocstyle
3057 (name "python-pydocstyle")
3062 (uri (pypi-uri "pydocstyle" version))
3065 "1m1xv9clkg9lgzyza6dnj359z04vh5g0h49nhzghv7lg81gchhap"))))
3066 (build-system python-build-system)
3068 `(("python-six" ,python-six)
3069 ("python-snowballstemmer" ,python-snowballstemmer)))
3071 "https://github.com/PyCQA/pydocstyle/")
3072 (synopsis "Python docstring style checker")
3074 "This package provides a style checker for the Python Language
3076 (license license:expat)))
3078 (define-public python-language-server
3080 (name "python-language-server")
3085 (uri (pypi-uri "python-language-server" version))
3088 "0cqrffd5272p2hifa35rf1h1g6dss741jmjkwa43jninifmbz0df"))))
3089 (build-system python-build-system)
3091 `(("python-pluggy" ,python-pluggy)
3092 ("python-jsonrpc-server" ,python-jsonrpc-server)
3093 ("python-jedi" ,python-jedi)
3094 ("python-yapf" ,python-yapf)
3095 ("python-pyflakes" ,python-pyflakes)
3096 ("python-pydocstyle" ,python-pydocstyle)
3097 ("python-pycodestyle" ,python-pycodestyle)
3098 ("python-mccabe" ,python-mccabe)
3099 ("python-rope" ,python-rope)
3100 ("python-autopep8" ,python-autopep8)
3101 ("python-flake8" ,python-flake8)
3102 ("python-pylint" ,python-pylint)))
3103 (home-page "https://github.com/palantir/python-language-server")
3104 (synopsis "Python implementation of the Language Server Protocol")
3106 "The Python Language Server (pyls) is an implementation of the Python 3
3107 language specification for the Language Server Protocol (LSP). This tool is
3108 used in text editing environments to provide a complete and integrated
3109 feature-set for programming Python effectively.")
3110 (license license:expat)))
3112 (define-public python-black
3114 (name "python-black")
3119 (uri (pypi-uri "black" version))
3122 "0i4sfqgz6w15vd50kbhi7g7rifgqlf8yfr8y78rypd56q64qn592"))))
3123 (build-system python-build-system)
3126 (modify-phases %standard-phases
3127 (add-after 'patch-source-shebangs 'patch-extra-shebangs
3129 (let ((python3 (which "python3")))
3130 (substitute* '("tests/data/fmtonoff.py"
3131 "tests/data/string_prefixes.py"
3132 "tests/data/function.py")
3133 (("#!/usr/bin/env python3(\\.[0-9]+)?" _ minor-version)
3134 (string-append "#!" python3 (if (string? minor-version)
3138 `(("python-click" ,python-click)
3139 ("python-attrs" ,python-attrs)
3140 ("python-appdirs" ,python-appdirs)
3141 ("python-toml" ,python-toml)))
3142 (home-page "https://github.com/ambv/black")
3143 (synopsis "The uncompromising code formatter")
3144 (description "Black is the uncompromising Python code formatter.")
3145 (license license:expat)))
3147 (define-public python-blinker
3149 (name "python-blinker")
3154 (uri (pypi-uri "blinker" version))
3157 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
3158 (build-system python-build-system)
3159 (home-page "http://pythonhosted.org/blinker/")
3160 (synopsis "Fast, simple object-to-object and broadcast signaling")
3162 "Blinker provides a fast dispatching system that allows any number of
3163 interested parties to subscribe to events, or \"signals\".")
3164 (license license:expat)))
3166 (define-public python2-blinker
3167 (package-with-python2 python-blinker))
3169 (define-public pelican
3176 (uri (pypi-uri "pelican" version))
3179 "0mp7hjyhs38ag1hyfcy882g400z0babqi72pnli46dqijfhajzmy"))))
3180 (build-system python-build-system)
3182 `(("python-blinker" ,python-blinker)
3183 ("python-dateutil" ,python-dateutil)
3184 ("python-docutils" ,python-docutils)
3185 ("python-feedgenerator" ,python-feedgenerator)
3186 ("python-jinja2" ,python-jinja2)
3187 ("python-markdown" ,python-markdown)
3188 ("python-pygments" ,python-pygments)
3189 ("python-pytz" ,python-pytz)
3190 ("python-six" ,python-six)
3191 ("python-unidecode" ,python-unidecode)))
3192 (home-page "https://getpelican.com/")
3194 `(;; XXX Requires a lot more packages to do unit tests :P
3196 (synopsis "Python-based static site publishing system")
3198 "Pelican is a tool to generate a static blog from reStructuredText,
3199 Markdown input files, and more. Pelican uses Jinja2 for templating
3200 and is very extensible.")
3201 (license license:agpl3+)))
3203 (define-public mallard-ducktype
3205 (name "mallard-ducktype")
3210 ;; git-reference because tests are not included in pypi source tarball
3211 ;; https://issues.guix.gnu.org/issue/36755#2
3213 (url "https://github.com/projectmallard/mallard-ducktype.git")
3215 (file-name (git-file-name name version))
3218 "1jk9bfz7g04ip78s03b0xak6d54rj4h9zpgadkziy1ji216g6y4c"))))
3219 (build-system python-build-system)
3222 (modify-phases %standard-phases
3225 (with-directory-excursion "tests"
3226 (invoke "sh" "runtests")))))))
3227 (home-page "http://projectmallard.org")
3228 (synopsis "Convert Ducktype to Mallard documentation markup")
3230 "Ducktype is a lightweight syntax that can represent all the semantics
3231 of the Mallard XML documentation system. Ducktype files can be converted to
3232 Mallard using the @command{ducktype} tool. The yelp-tools package
3233 provides additional functionality on the produced Mallard documents.")
3234 (license license:expat)))
3236 (define-public python-cython
3238 (name "python-cython")
3243 (uri (pypi-uri "Cython" version))
3246 "13k37lrcgagwwnzr5bzririsscb793vndj234d475x1h9ad0d7f2"))))
3247 (build-system python-build-system)
3248 ;; we need the full python package and not just the python-wrapper
3249 ;; because we need libpython3.3m.so
3251 `(("python" ,python)))
3254 (modify-phases %standard-phases
3255 (add-before 'check 'set-HOME
3256 ;; some tests require access to "$HOME/.cython"
3257 (lambda _ (setenv "HOME" "/tmp") #t))
3259 ;; FIXME: These tests started failing on armhf after the 0.28 update
3260 ;; (commit c69d11c5930), both with an error such as this:
3261 ;; compiling (cpp) and running dictcomp ...
3262 ;; === C/C++ compiler error output: ===
3264 ;; dictcomp.cpp:5221: confused by earlier errors, bailing out
3265 ;; See <https://hydra.gnu.org/build/2948724> for logs.
3266 ,@(if (target-arm32?)
3267 `((add-before 'check 'disable-failing-tests
3269 (let ((disabled-tests (open-file "tests/bugs.txt" "a")))
3270 (for-each (lambda (test)
3271 (format disabled-tests "~a\n" test))
3272 '("memslice" "dictcomp"))
3273 (close-port disabled-tests)))))
3278 ;; Disable compiler optimizations to greatly reduce the running
3279 ;; time of the test suite.
3280 (setenv "CFLAGS" "-O0")
3282 (invoke "python" "runtests.py" "-vv"
3283 "-j" (number->string (parallel-job-count))))))))
3284 (home-page "https://cython.org/")
3285 (synopsis "C extensions for Python")
3286 (description "Cython is an optimising static compiler for both the Python
3287 programming language and the extended Cython programming language. It makes
3288 writing C extensions for Python as easy as Python itself.")
3289 (license license:asl2.0)
3290 (properties `((python2-variant . ,(delay python2-cython))))))
3292 (define-public python2-cython
3293 (let ((base (package-with-python2 (strip-python2-variant python-cython))))
3296 (name "python2-cython")
3298 `(("python-2" ,python-2))) ;this is not automatically changed
3300 (substitute-keyword-arguments (package-arguments base)
3302 `(modify-phases ,phases
3303 (add-before 'check 'adjust-test_embed
3305 (substitute* "runtests.py"
3306 ;; test_embed goes great lengths to find the static libpythonX.Y.a
3307 ;; so it can give the right -L flag to GCC when embedding static
3308 ;; builds of Python. It is unaware that the Python "config"
3309 ;; directory (where the static library lives) was renamed in
3310 ;; Python 3, and falls back to sysconfig.get_config_var('LIBDIR'),
3311 ;; which works fine, because that is where the shared library is.
3313 ;; It also appears to be unaware that the Makefile in Demos/embed
3314 ;; already unconditionally pass the static library location to GCC,
3315 ;; after checking sysconfig.get_config_var('LIBPL).
3317 ;; The effect is that the linker is unable to resolve libexpat
3318 ;; symbols when building for Python 2, because neither the Python 2
3319 ;; shared library nor Expat is available. To fix it, we can either
3320 ;; add Expat as an input and make it visible to the linker, or just
3321 ;; prevent it from overriding the Python shared library location.
3322 ;; The end result is identical, so we take the easy route.
3323 ((" or libname not in os\\.listdir\\(libdir\\)")
3327 ;; The RPython toolchain currently does not support Python 3.
3328 (define-public python2-rpython
3330 (name "python2-rpython")
3335 (uri (pypi-uri "rpython" version))
3338 "02z9cvxf0y41dcvwnvf2zn0albhhw1drvjjbq27m6i1piw1k6fc0"))))
3339 (build-system python-build-system)
3340 (arguments `(#:python ,python-2))
3342 `(("python2-pytest" ,python2-pytest))) ; needed for running tests
3343 (home-page "https://rpython.readthedocs.org")
3344 (synopsis "Framework for implementing interpreters and virtual machines")
3345 (description "RPython is a translation and support framework for
3346 producing implementations of dynamic languages, emphasizing a clean separation
3347 between language specification and implementation aspects.")
3348 (license license:expat)))
3350 ;; NOTE: when upgrading numpy please make sure that python-pandas and
3351 ;; python-scipy still build, as these three packages are often used together.
3352 (define-public python-numpy
3354 (name "python-numpy")
3360 "https://github.com/numpy/numpy/releases/download/v"
3361 version "/numpy-" version ".tar.gz"))
3364 "1ak9dmjja0q90a7fsxli51ypcwssh8c4pb6f8wkrsnf2xgdk6dy9"))))
3365 (build-system python-build-system)
3367 `(("openblas" ,openblas)
3368 ("lapack" ,lapack)))
3370 `(("python-cython" ,python-cython)
3371 ("python-pytest" ,python-pytest)
3372 ("gfortran" ,gfortran)))
3375 (modify-phases %standard-phases
3376 (add-before 'build 'configure-blas-lapack
3377 (lambda* (#:key inputs #:allow-other-keys)
3378 (call-with-output-file "site.cfg"
3382 libraries = openblas
3383 library_dirs = ~a/lib
3384 include_dirs = ~a/include
3386 # backslash-n to make emacs happy
3388 lapack_libs = lapack
3389 library_dirs = ~a/lib
3390 include_dirs = ~a/include
3392 (assoc-ref inputs "openblas")
3393 (assoc-ref inputs "openblas")
3394 (assoc-ref inputs "lapack")
3395 (assoc-ref inputs "lapack"))))
3397 (add-before 'build 'fix-executable-paths
3398 (lambda* (#:key inputs #:allow-other-keys)
3399 ;; Make /gnu/store/...-bash-.../bin/sh the default shell,
3400 ;; instead of /bin/sh.
3401 (substitute* "numpy/distutils/exec_command.py"
3402 (("(os.environ.get\\('SHELL', ')(/bin/sh'\\))" match match-start match-end)
3403 (string-append match-start (assoc-ref inputs "bash") match-end)))
3404 ;; Use "gcc" executable, not "cc".
3405 (substitute* "numpy/distutils/system_info.py"
3406 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
3407 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3409 ;; Tests can only be run after the library has been installed and not
3410 ;; within the source directory.
3412 (add-after 'install 'check
3413 (lambda* (#:key outputs inputs #:allow-other-keys)
3414 ;; Make installed package available for running the tests
3415 (add-installed-pythonpath inputs outputs)
3416 ;; Make sure "f2py" etc is found.
3417 (setenv "PATH" (string-append (assoc-ref outputs "out") "/bin"
3418 ":" (getenv "PATH")))
3419 (with-directory-excursion "/tmp"
3420 (invoke "python" "-c"
3421 "import numpy; numpy.test(verbose=2)")))))))
3422 (home-page "http://www.numpy.org/")
3423 (synopsis "Fundamental package for scientific computing with Python")
3424 (description "NumPy is the fundamental package for scientific computing
3425 with Python. It contains among other things: a powerful N-dimensional array
3426 object, sophisticated (broadcasting) functions, tools for integrating C/C++
3427 and Fortran code, useful linear algebra, Fourier transform, and random number
3429 (properties `((python2-variant . ,(delay python2-numpy))))
3430 (license license:bsd-3)))
3432 ;; Numpy 1.16.x are the last versions that support Python 2.
3433 (define-public python2-numpy
3434 (let ((numpy (package-with-python2
3435 (strip-python2-variant python-numpy))))
3442 "https://github.com/numpy/numpy/releases/download/v"
3443 version "/numpy-" version ".tar.gz"))
3446 "0lg1cycxzi4rvvrd5zxinpdz0ni792fpx6xjd75z1923zcac8qrb")))))))
3448 ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of
3449 ;; interest only for legacy code going back to NumPy's predecessor
3451 (define-public python2-numpy-1.8
3452 (package (inherit python2-numpy)
3458 (url "https://github.com/numpy/numpy")
3459 (commit (string-append "v" version))))
3460 (file-name (git-file-name "numpy" version))
3463 "0ikgi15rsqwbkfsjjxrwh40lqyal2wvyp3923y6w6ch3dcr82sfk"))))
3465 (substitute-keyword-arguments (package-arguments python2-numpy)
3467 `(modify-phases ,phases
3468 (replace 'configure-blas-lapack
3469 (lambda* (#:key inputs #:allow-other-keys)
3470 (call-with-output-file "site.cfg"
3474 libraries = openblas,lapack
3475 library_dirs = ~a/lib:~a/lib
3476 include_dirs = ~a/include:~a/include
3478 (assoc-ref inputs "openblas")
3479 (assoc-ref inputs "lapack")
3480 (assoc-ref inputs "openblas")
3481 (assoc-ref inputs "lapack"))))
3484 `(("python2-nose" ,python2-nose)))
3485 (description "NumPy is the fundamental package for scientific computing
3486 with Python. It contains among other things: a powerful N-dimensional array
3487 object, sophisticated (broadcasting) functions, tools for integrating C/C++
3488 and Fortran code, useful linear algebra, Fourier transform, and random number
3489 capabilities. Version 1.8 is the last one to contain the numpy.oldnumeric API
3490 that includes the compatibility layer numpy.oldnumeric with NumPy's predecessor
3492 (license license:bsd-3)))
3494 (define-public python-munch
3496 (name "python-munch")
3501 (uri (pypi-uri "munch" version))
3504 "1cmqg91xnqx8gvnh4pmp0bfl1dfcm65d5p9mg73zz8pkjhx6h80l"))))
3505 (build-system python-build-system)
3506 (home-page "https://github.com/Infinidat/munch")
3507 (synopsis "Dot-accessible dictionary")
3508 (description "Munch is a dot-accessible dictionary similar to JavaScript
3510 (license license:expat)))
3512 (define-public python2-munch
3513 (package-with-python2 python-munch))
3515 (define-public python-colormath
3517 (name "python-colormath")
3522 (uri (pypi-uri "colormath" version))
3525 "05qjycgxp3p2f9n6lmic68sxmsyvgnnlyl4z9w7dl9s56jphaiix"))))
3526 (build-system python-build-system)
3528 `(("python-networkx" ,python-networkx)
3529 ("python-numpy" ,python-numpy)))
3530 (home-page "https://github.com/gtaylor/python-colormath")
3531 (synopsis "Color math and conversion library")
3533 "This is a Python library for color math and conversions.")
3534 (license license:bsd-3)))
3536 (define-public python2-colormath
3537 (package-with-python2 python-colormath))
3539 (define-public python-spectra
3541 (name "python-spectra")
3546 (uri (pypi-uri "spectra" version))
3549 "1f322x914bhkg6r5gv1vmnir3iy0k5kih0fd2gp3rdkw32jn5cwf"))))
3550 (build-system python-build-system)
3553 (modify-phases %standard-phases
3555 (lambda _ (invoke "nosetests" "-v"))))))
3557 `(("python-colormath" ,python-colormath)))
3559 `(("python-nose" ,python-nose)))
3560 (home-page "https://github.com/jsvine/spectra")
3561 (synopsis "Color scales and color conversion")
3563 "This package provides a Python library intended to make color math,
3564 color scales, and color space conversion easy. It has support for:
3569 @item Color blending
3570 @item Brightening/darkening colors
3571 @item Saturating/desaturating colors
3572 @item Conversion to/from multiple color spaces.
3574 (license license:expat)))
3576 (define-public python2-spectra
3577 (package-with-python2 python-spectra))
3579 (define-public python-numpy-documentation
3581 (name "python-numpy-documentation")
3582 (version (package-version python-numpy))
3583 (source (package-source python-numpy))
3584 (build-system python-build-system)
3586 `(("python-matplotlib" ,python-matplotlib)
3587 ("python-numpy" ,python-numpy)
3588 ("pkg-config" ,pkg-config)
3589 ("python-sphinx" ,python-sphinx)
3590 ("python-numpydoc" ,python-numpydoc)
3591 ("texlive" ,(texlive-union (list texlive-fonts-cm-super
3593 texlive-generic-ifxetex
3594 texlive-generic-pdftex
3596 texlive-latex-capt-of
3598 texlive-latex-environ
3599 texlive-latex-eqparbox
3600 texlive-latex-etoolbox
3601 texlive-latex-expdlist
3602 texlive-latex-fancyhdr
3603 texlive-latex-fancyvrb
3604 texlive-latex-fncychap
3606 texlive-latex-framed
3607 texlive-latex-geometry
3608 texlive-latex-graphics
3609 texlive-latex-hyperref
3610 texlive-latex-mdwtools
3611 texlive-latex-multirow
3612 texlive-latex-needspace
3613 texlive-latex-oberdiek
3614 texlive-latex-parskip
3615 texlive-latex-preview
3616 texlive-latex-tabulary
3617 texlive-latex-threeparttable
3618 texlive-latex-titlesec
3619 texlive-latex-trimspaces
3621 texlive-latex-upquote
3623 texlive-latex-varwidth
3624 texlive-latex-wrapfig)))
3625 ("texinfo" ,texinfo)
3627 ("scipy-sphinx-theme"
3628 ,(origin ; The build script expects scipy-sphinx-theme as a git submodule
3631 (url "https://github.com/scipy/scipy-sphinx-theme.git")
3632 (commit "c466764e2231ba132c09826b5b138fffa1cfcec3")))
3635 "0q2y87clwlsgc7wvlsn9pzyssybcq10plwhq2w1ydykfsyyqbmkl"))))
3636 ,@(package-native-inputs python-numpy)))
3638 `(#:tests? #f ; we're only generating the documentation
3640 (modify-phases %standard-phases
3643 (lambda* (#:key inputs outputs #:allow-other-keys)
3644 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
3646 data "/doc/" ,name "-"
3647 ,(package-version python-numpy)))
3648 (info-reader (string-append data "/info"))
3649 (html (string-append doc "/html"))
3650 (scipy-sphinx-theme "scipy-sphinx-theme")
3651 (sphinx-theme-checkout (assoc-ref inputs scipy-sphinx-theme))
3652 (pyver ,(string-append "PYVER=")))
3654 ;; FIXME: this is needed to for texlive-union to generate
3655 ;; fonts, which are not found.
3656 (setenv "HOME" "/tmp")
3658 (with-directory-excursion "doc"
3659 (copy-recursively sphinx-theme-checkout scipy-sphinx-theme)
3661 (invoke "make" "html" pyver)
3662 (invoke "make" "latex" "PAPER=a4" pyver)
3663 (invoke "make" "-C" "build/latex"
3664 "all-pdf" "PAPER=a4" pyver)
3665 ;; FIXME: Generation of the info file fails.
3666 ;; (invoke "make" "info" pyver)
3668 ;; (copy-file "build/texinfo/numpy.info"
3669 ;; (string-append info "/numpy.info"))
3670 (for-each (lambda (file)
3671 (copy-file (string-append "build/latex" file)
3672 (string-append doc file)))
3673 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3674 (with-directory-excursion "build/html"
3675 (for-each (lambda (file)
3676 (let* ((dir (dirname file))
3677 (tgt-dir (string-append html "/" dir)))
3678 (unless (equal? "." dir)
3680 (install-file file html)))
3681 (find-files "." ".*")))))
3683 (home-page (package-home-page python-numpy))
3684 (synopsis "Documentation for the python-numpy package")
3685 (description (package-description python-numpy))
3686 (license (package-license python-numpy))))
3688 (define-public python2-numpy-documentation
3689 (let ((numpy-documentation (package-with-python2 python-numpy-documentation)))
3691 (inherit numpy-documentation)
3692 (native-inputs `(("python2-functools32" ,python2-functools32)
3693 ,@(package-native-inputs numpy-documentation))))))
3695 (define-public python-pygit2
3697 (name "python-pygit2")
3702 (uri (pypi-uri "pygit2" version))
3704 (base32 "11kzj5mjkspvplnpdb6bj8dcj6rgmkk986k8hjcklyg5yaxkz32d"))))
3705 (build-system python-build-system)
3707 '(#:tests? #f)) ; tests don't run correctly in our environment
3709 `(("python-six" ,python-six)
3710 ("python-cffi" ,python-cffi)
3711 ("libgit2" ,libgit2)
3712 ("python-tox" ,python-tox)))
3714 `(("python-pytest" ,python-pytest)))
3715 (home-page "https://github.com/libgit2/pygit2")
3716 (synopsis "Python bindings for libgit2")
3717 (description "Pygit2 is a set of Python bindings to the libgit2 shared
3718 library, libgit2 implements Git plumbing.")
3719 ;; GPL2.0 only, with linking exception.
3720 (license license:gpl2)))
3722 (define-public python2-pygit2
3723 (package-with-python2 python-pygit2))
3725 (define-public python-pyparsing
3727 (name "python-pyparsing")
3732 (uri (pypi-uri "pyparsing" version))
3734 (base32 "0yk6xl885b91dmlhlsap7x78hk2rdr879fln9anbq6k4ca42djb6"))))
3735 (build-system python-build-system)
3736 (outputs '("out" "doc"))
3738 `(#:tests? #f ; no test target
3740 (modify-phases %standard-phases
3741 (add-after 'install 'install-doc
3742 (lambda* (#:key outputs #:allow-other-keys)
3743 (let* ((doc (string-append (assoc-ref outputs "doc")
3744 "/share/doc/" ,name "-" ,version))
3745 (html-doc (string-append doc "/html"))
3746 (examples (string-append doc "/examples")))
3752 (install-file file tgt))
3753 (find-files dir ".*")))
3754 (list "docs" "htmldoc" "examples")
3755 (list doc html-doc examples))
3757 (home-page "https://github.com/pyparsing/pyparsing")
3758 (synopsis "Python parsing class library")
3760 "The pyparsing module is an alternative approach to creating and
3761 executing simple grammars, vs. the traditional lex/yacc approach, or the use
3762 of regular expressions. The pyparsing module provides a library of classes
3763 that client code uses to construct the grammar directly in Python code.")
3764 (license license:expat)))
3766 (define-public python2-pyparsing
3767 (package-with-python2 python-pyparsing))
3769 (define-public python-numpydoc
3771 (name "python-numpydoc")
3776 (uri (pypi-uri "numpydoc" version))
3779 "1zazxg3m8j4fksv3f7v7vpf4bj9qb1vj3r326am0vdip141vzx31"))))
3780 (build-system python-build-system)
3782 `(("python-sphinx" ,python-sphinx)))
3784 `(("python-nose" ,python-nose)))
3785 (home-page "https://pypi.python.org/pypi/numpydoc")
3787 "Numpy's Sphinx extensions")
3789 "Sphinx extension to support docstrings in Numpy format.")
3790 (license license:bsd-2)))
3792 (define-public python2-numpydoc
3793 (package-with-python2 python-numpydoc))
3795 (define-public python-numexpr
3797 (name "python-numexpr")
3802 (uri (pypi-uri "numexpr" version))
3805 "1frnbcwmsi312154x274xl28xazr1k8vjby83fwyla2n10a81bgq"))))
3806 (build-system python-build-system)
3807 (arguments `(#:tests? #f)) ; no tests included
3809 `(("python-numpy" ,python-numpy)))
3810 (home-page "https://github.com/pydata/numexpr")
3811 (synopsis "Fast numerical expression evaluator for NumPy")
3813 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3814 expressions that operate on arrays are accelerated and use less memory than
3815 doing the same calculation in Python. In addition, its multi-threaded
3816 capabilities can make use of all your cores, which may accelerate
3817 computations, most specially if they are not memory-bounded (e.g. those using
3818 transcendental functions).")
3819 (license license:expat)))
3821 (define-public python2-numexpr
3822 (package-with-python2 python-numexpr))
3824 (define-public python-cycler
3826 (name "python-cycler")
3830 (uri (pypi-uri "cycler" version))
3833 "1n69n23fak1gjxlrbhqisi2b9pv3ckrfj98llx3p53953082syyd"))))
3834 (build-system python-build-system)
3836 ;; XXX: The current version requires 'coveralls' which we don't have.
3837 ;; Enable this for the next release which uses 'python-pytest'.
3840 `(("python-six" ,python-six)))
3841 (home-page "http://matplotlib.org/cycler/")
3842 (synopsis "Composable keyword argument iterator")
3844 "When using @code{matplotlib} and plotting more than one line, it is
3845 common to want to be able to want to be able to cycle over one or more artist
3846 styles; but the plotting logic can quickly become involved.
3847 To address this and enable easy cycling over arbitrary @code{kwargs}, the
3848 @code{Cycler} class was developed.")
3849 (license license:bsd-3)))
3851 (define-public python2-cycler
3852 (package-with-python2 python-cycler))
3854 (define-public python-colorspacious
3856 (name "python-colorspacious")
3862 (url "https://github.com/njsmith/colorspacious.git")
3863 (commit (string-append "v" version))))
3864 (file-name (git-file-name name version))
3866 (base32 "0x7nkphr6g5ql5fvgss8l56rgiyjgh6fm8zzs73i94ci9wzlm63w"))))
3867 (build-system python-build-system)
3869 `(("python-numpy" ,python-numpy)))
3871 `(("python-nose" ,python-nose)))
3874 (modify-phases %standard-phases
3877 (invoke "nosetests" "--all-modules" "-v" "colorspacious"))))))
3878 (home-page "https://github.com/njsmith/colorspacious")
3879 (synopsis "Python library for colorspace conversions")
3880 (description "@code{colorspacious} is a Python library that lets you
3881 convert between colorspaces like sRGB, XYZ, CIEL*a*b*, CIECAM02, CAM02-UCS, etc.")
3882 (license license:expat)))
3884 (define-public python2-colorspacious
3885 (package-with-python2 python-colorspacious))
3887 (define-public python-matplotlib
3889 (name "python-matplotlib")
3894 (uri (pypi-uri "matplotlib" version))
3897 "1nmshfqh7wyg15i16hx1yiylcvzkws29ivn66n3i0wyqwcpjr3lf"))))
3898 (build-system python-build-system)
3899 (propagated-inputs ; the following packages are all needed at run time
3900 `(("python-cycler" ,python-cycler)
3901 ("python-kiwisolver" ,python-kiwisolver)
3902 ("python-pyparsing" ,python-pyparsing)
3903 ("python-pygobject" ,python-pygobject)
3904 ("gobject-introspection" ,gobject-introspection)
3905 ("python-tkinter" ,python "tk")
3906 ("python-dateutil" ,python-dateutil)
3907 ("python-numpy" ,python-numpy)
3908 ("python-pillow" ,python-pillow)
3909 ("python-pytz" ,python-pytz)
3910 ("python-six" ,python-six)
3911 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3912 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3913 ;; object. For this reason we need to import both libraries.
3914 ;; https://cairocffi.readthedocs.io/en/stable/cffi_api.html#converting-pycairo-wrappers-to-cairocffi
3915 ("python-pycairo" ,python-pycairo)
3916 ("python-cairocffi" ,python-cairocffi)))
3918 `(("libpng" ,libpng)
3919 ("imagemagick" ,imagemagick)
3920 ("freetype" ,freetype)
3923 ;; FIXME: Add backends when available.
3924 ;("python-wxpython" ,python-wxpython)
3928 `(("pkg-config" ,pkg-config)
3929 ("python-pytest" ,python-pytest)
3930 ("python-mock" ,python-mock)
3935 (uri "https://jqueryui.com/resources/download/jquery-ui-1.12.1.zip")
3938 "0kb21xf38diqgxcdi1z3s9ssq36pldvyqxy56hn6pcva6rs3c8zq"))))))
3941 (modify-phases %standard-phases
3942 ;; XXX We disable all image comparison tests because we're using a
3943 ;; newer version of FreeType than matplotlib expects. This leads to
3944 ;; minor differences throughout the tests.
3945 (add-after 'unpack 'fix-and-disable-failing-tests
3947 (substitute* (append (find-files "lib/matplotlib/tests/"
3949 (find-files "lib/mpl_toolkits/tests"
3951 (("^from matplotlib" match)
3952 (string-append "import pytest\n" match))
3953 (("( *)@image_comparison" match indent)
3954 (string-append indent
3955 "@pytest.mark.skip(reason=\"unknown minor image differences\")\n"
3957 (substitute* "lib/matplotlib/tests/test_animation.py"
3958 (("/bin/sh") (which "sh")))
3959 (for-each delete-file
3960 ;; test_normal_axes, test_get_tightbbox_polar
3961 '("lib/matplotlib/tests/test_axes.py"
3962 ;; We don't use the webagg backend and this test forces it.
3963 "lib/matplotlib/tests/test_backend_webagg.py"
3964 ;; test_outward_ticks
3965 "lib/matplotlib/tests/test_tightlayout.py"
3966 ;; test_hidden_axes fails with minor extent
3967 ;; differences, possibly due to the use of a
3968 ;; different version of FreeType.
3969 "lib/matplotlib/tests/test_constrainedlayout.py"
3970 ;; Fontconfig returns no fonts.
3971 "lib/matplotlib/tests/test_font_manager.py"))
3973 (add-before 'install 'install-jquery-ui
3974 (lambda* (#:key outputs inputs #:allow-other-keys)
3975 (let ((dir (string-append (assoc-ref outputs "out")
3976 "/lib/python3.7/site-packages/matplotlib/backends/web_backend/")))
3979 (assoc-ref inputs "jquery-ui")
3983 (lambda* (#:key outputs inputs #:allow-other-keys)
3984 (add-installed-pythonpath inputs outputs)
3985 (invoke "python" "tests.py" "-v"
3986 "-m" "not network and not webagg")))
3987 (add-before 'build 'configure-environment
3988 (lambda* (#:key outputs inputs #:allow-other-keys)
3989 (let ((cairo (assoc-ref inputs "cairo")))
3990 ;; Setting this directory in the 'basedirlist' of 'setup.cfg'
3992 (setenv "LD_LIBRARY_PATH" (string-append cairo "/lib"))
3993 (setenv "HOME" (getcwd))
3994 (call-with-output-file "setup.cfg"
3996 (format port "[directories]~%
3997 basedirlist = ~a,~a~%
4000 (assoc-ref inputs "tcl")
4001 (assoc-ref inputs "tk")))))
4003 (home-page "https://matplotlib.org/")
4004 (synopsis "2D plotting library for Python")
4006 "Matplotlib is a Python 2D plotting library which produces publication
4007 quality figures in a variety of hardcopy formats and interactive environments
4008 across platforms. Matplotlib can be used in Python scripts, the python and
4009 ipython shell, web application servers, and six graphical user interface
4011 (license license:psfl)
4012 (properties `((python2-variant . ,(delay python2-matplotlib))))))
4014 (define-public python2-matplotlib
4015 (let ((matplotlib (package-with-python2
4016 (strip-python2-variant python-matplotlib))))
4017 (package (inherit matplotlib)
4022 (uri (pypi-uri "matplotlib" version))
4025 "09i1gnrra1590brc1f8d5rh2zvnknmfgzp613ab0462qkrwj15h2"))))
4027 (substitute-keyword-arguments (package-arguments matplotlib)
4029 `(modify-phases ,phases
4030 (replace 'install-jquery-ui
4031 (lambda* (#:key outputs inputs #:allow-other-keys)
4032 (let ((dir (string-append (assoc-ref outputs "out")
4033 "/lib/python2.7/site-packages/"
4034 "matplotlib/backends/web_backend/")))
4037 (assoc-ref inputs "jquery-ui")
4040 (delete 'fix-and-disable-failing-tests)
4041 (delete 'check))))) ; These tests weren't run the the past.
4042 ;; Make sure to use special packages for Python 2 instead
4043 ;; of those automatically rewritten by package-with-python2.
4045 `(("python2-pycairo" ,python2-pycairo)
4046 ("python2-backports-functools-lru-cache"
4047 ,python2-backports-functools-lru-cache)
4048 ("python2-functools32" ,python2-functools32)
4049 ("python2-pygobject-2" ,python2-pygobject-2)
4050 ("python2-subprocess32" ,python2-subprocess32)
4051 ("python2-tkinter" ,python-2 "tk")
4052 ,@(fold alist-delete (package-propagated-inputs matplotlib)
4053 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
4055 (define-public python-matplotlib-documentation
4057 (name "python-matplotlib-documentation")
4058 (version (package-version python-matplotlib))
4059 (source (package-source python-matplotlib))
4060 (build-system python-build-system)
4062 `(("python-matplotlib" ,python-matplotlib)
4063 ("python-colorspacious" ,python-colorspacious)
4064 ("python-sphinx" ,python-sphinx)
4065 ("python-sphinx-copybutton" ,python-sphinx-copybutton)
4066 ("python-sphinx-gallery" ,python-sphinx-gallery)
4067 ("python-numpydoc" ,python-numpydoc)
4068 ("python-ipython" ,python-ipython)
4069 ("python-ipykernel" ,python-ipykernel)
4070 ("python-mock" ,python-mock)
4071 ("graphviz" ,graphviz)
4072 ("texlive" ,(texlive-union (list texlive-amsfonts
4073 texlive-latex-amsmath
4074 texlive-latex-enumitem
4075 texlive-latex-expdlist
4076 texlive-latex-geometry
4077 texlive-latex-preview
4078 texlive-latex-type1cm
4081 texlive-generic-pdftex
4084 texlive-fonts-adobe-times
4085 texlive-fonts-txfonts)))
4086 ("texinfo" ,texinfo)
4087 ,@(package-native-inputs python-matplotlib)))
4089 `(#:tests? #f ; we're only generating documentation
4091 (modify-phases %standard-phases
4092 ;; The tests in python-matplotlib are run after the install phase, so
4093 ;; we need to delete the extra phase here.
4098 (setenv "PYTHONPATH"
4099 (string-append (getenv "PYTHONPATH")
4100 ":" (getcwd) "/../examples/units"))
4101 (substitute* "conf.py"
4103 (("^SHA = check_output.*")
4104 (string-append "SHA = \"" ,version "\"\n"))
4105 ;; Don't fetch intersphinx files from the Internet
4106 (("^explicit_order_folders" m)
4107 (string-append "intersphinx_mapping = {}\n" m))
4108 (("'sphinx.ext.intersphinx',") "")
4109 ;; Disable URL embedding which requires internet access.
4110 (("'https://docs.scipy.org/doc/numpy'") "None")
4111 (("'https://docs.scipy.org/doc/scipy/reference'") "None"))
4113 "SPHINXBUILD=sphinx-build"
4114 "SPHINXOPTS=" ; don't abort on warnings
4117 (lambda* (#:key inputs outputs #:allow-other-keys)
4118 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
4119 (doc (string-append data "/doc/python-matplotlib-" ,version))
4120 (info (string-append data "/info"))
4121 (html (string-append doc "/html")))
4124 (copy-recursively "build/html" html)
4125 (symlink (string-append html "/_images")
4126 (string-append info "/matplotlib-figures"))
4127 (with-directory-excursion "build/texinfo"
4128 (substitute* "matplotlib.texi"
4129 (("@image\\{([^,]*)" all file)
4130 (string-append "@image{matplotlib-figures/" file)))
4131 (symlink (string-append html "/_images")
4132 "./matplotlib-figures")
4133 (invoke "makeinfo" "--no-split"
4134 "-o" "matplotlib.info" "matplotlib.texi"))
4135 (install-file "build/texinfo/matplotlib.info" info))
4137 (home-page (package-home-page python-matplotlib))
4138 (synopsis "Documentation for the python-matplotlib package")
4139 (description (package-description python-matplotlib))
4140 (license (package-license python-matplotlib))))
4142 (define-public python2-matplotlib-documentation
4143 (let ((parent (package-with-python2 python-matplotlib-documentation)))
4147 (alist-delete "python-sphinx-copybutton"
4148 (package-native-inputs parent))))))
4150 (define-public python-matplotlib-venn
4152 (name "python-matplotlib-venn")
4157 (uri (pypi-uri "matplotlib-venn" version ".zip"))
4160 "13w3i1wih0mij08hrgppzg0g9z50y54rc28l6gdi1r5w45l7l0dy"))))
4161 (build-system python-build-system)
4162 (arguments '(#:tests? #f)) ; tests are not included
4164 `(("python-matplotlib" ,python-matplotlib)
4165 ("python-numpy" ,python-numpy)
4166 ("python-scipy" ,python-scipy)))
4168 `(("unzip" ,unzip)))
4169 (home-page "https://github.com/konstantint/matplotlib-venn")
4170 (synopsis "Plot area-proportional Venn diagrams")
4172 "This package provides tools for plotting area-proportional two- and
4173 three-way Venn diagrams in @code{matplotlib}.")
4174 (license license:expat)))
4176 (define-public python2-pysnptools
4178 (name "python2-pysnptools")
4183 (uri (pypi-uri "pysnptools" version))
4186 "0lnis5xsl7bi0hz4f7gbicahzi5zlxkc21nk3g374xv8fb5hb3qm"))))
4187 (build-system python-build-system)
4189 `(#:python ,python-2 ; only Python 2.7 is supported
4190 #:tests? #f)) ; test files (e.g. examples/toydata.bim) not included
4192 `(("python2-numpy" ,python2-numpy)
4193 ("python2-scipy" ,python2-scipy)
4194 ("python2-pandas" ,python2-pandas)))
4196 `(("python2-cython" ,python2-cython)))
4197 (home-page "http://microsoftgenomics.github.io/PySnpTools/")
4198 (synopsis "Library for reading and manipulating genetic data")
4200 "PySnpTools is a library for reading and manipulating genetic data. It
4201 can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
4202 those files. It can also efficiently manipulate ranges of integers using set
4203 operators such as union, intersection, and difference.")
4204 (license license:asl2.0)))
4206 (define-public python-socksipy-branch
4208 (name "python-socksipy-branch")
4213 (uri (pypi-uri "SocksiPy-branch" version))
4216 "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p"))))
4217 (build-system python-build-system)
4219 `(#:tests? #f)) ; There are no tests
4220 (home-page "https://code.google.com/archive/p/socksipy-branch/")
4221 (synopsis "Python SOCKS module")
4223 "SocksiPy - A Python SOCKS client module. It provides a
4224 socket-like interface that supports connections to any TCP
4225 service through the use of a SOCKS4, SOCKS5 or HTTP proxy.
4226 The original version was developed by Dan Haim, this is a
4227 branch created by Mario Vilas to address some open issues,
4228 as the original project seems to have been abandoned circa 2007.")
4229 (license license:bsd-3)))
4231 (define-public python2-socksipy-branch
4232 (package-with-python2 python-socksipy-branch))
4234 (define-public python-socksipychain
4236 (name "python-socksipychain")
4242 (url "https://github.com/pagekite/PySocksipyChain.git")
4243 (commit (string-append "v" version))))
4244 (file-name (git-file-name name version))
4247 "0idm9a050rd2kbgbz2sk9ib9589kj4xh1xdnggs6xbq2v2y8f6zn"))))
4248 (build-system python-build-system)
4250 `(#:tests? #f)) ; Tests try to access the network.
4251 (home-page "http://pagekite.net/wiki/Floss/PySocksipyChain/")
4252 (synopsis "Python SOCKS module with chained proxies support")
4254 "SocksiPyChain is a modified version of the SocksiPy SOCKS module, which
4255 adds support for arbitrary chaining of proxy servers and various modes of
4256 TLS/SSL encryption. It was developed for use in PageKite, and also includes
4257 a simple netcat replacement with chaining support.")
4258 (license license:bsd-3)))
4260 (define-public python-pycodestyle
4262 (name "python-pycodestyle")
4267 (uri (pypi-uri "pycodestyle" version))
4270 "0v4prb05n21bm8650v0a01k1nyqjdmkrsm3zycfxh2j5k9n962p4"))))
4271 (build-system python-build-system)
4272 (home-page "https://pycodestyle.readthedocs.io/")
4273 (synopsis "Python style guide checker")
4274 (description "@code{pycodestyle} (formerly pep8) is a tool to check
4275 Python code against some of the style conventions in
4276 @url{http://www.python.org/dev/peps/pep-0008/,PEP 8}.")
4277 (license license:expat)))
4279 (define-public python2-pycodestyle
4280 (package-with-python2 python-pycodestyle))
4282 (define-public python-multidict
4284 (name "python-multidict")
4289 (uri (pypi-uri "multidict" version))
4292 "1vf5bq8hn5a9rvhr5v4fwbmarfsp35hhr8gs74kqfijy34j2f194"))))
4293 (build-system python-build-system)
4295 `(("python-pytest" ,python-pytest)
4296 ("python-pytest-runner" ,python-pytest-runner)))
4297 (home-page "https://github.com/aio-libs/multidict/")
4298 (synopsis "Multidict implementation")
4299 (description "Multidict is dict-like collection of key-value pairs
4300 where key might be occurred more than once in the container.")
4301 (license license:asl2.0)))
4303 (define-public python-orderedmultidict
4305 (name "python-orderedmultidict")
4310 (uri (pypi-uri "orderedmultidict" version))
4313 "0dls862ibm7qbq4fnvwx0xn1v9hwyzywbff8xjjdr42dd75208yw"))))
4314 (build-system python-build-system)
4317 (modify-phases %standard-phases
4318 (add-after 'unpack 'fix-tests
4320 ;; The package uses nosetest for running the tests.
4321 ;; Adding this initfile allows to run the test suite
4322 ;; without requiring nosetest.
4323 (with-output-to-file "tests/__init__.py" newline)
4326 `(("python-six" ,python-six)))
4328 `(("python-pycodestyle" ,python-pycodestyle)))
4329 (home-page "https://github.com/gruns/orderedmultidict")
4330 (synopsis "Python Ordered Multivalue Dictionary - omdict")
4331 (description "This package contains a library for ordered multivalue
4332 dictionaries. A multivalue dictionary is a dictionary that can store
4333 multiple values for the same key. An ordered multivalue dictionary is a
4334 multivalue dictionary that retains the order of insertions and deletions.")
4335 (license license:unlicense)))
4337 (define-public python2-orderedmultidict
4338 (package-with-python2 python-orderedmultidict))
4340 (define-public python-autopep8
4342 (name "python-autopep8")
4347 (uri (pypi-uri "autopep8" version))
4350 "192bvhzi4d0claqxgzymvv7k3qnj627742bc8sgxpzjj42pd9112"))))
4351 (build-system python-build-system)
4353 `(("python-pycodestyle" ,python-pycodestyle)))
4354 (home-page "https://github.com/hhatto/autopep8")
4355 (synopsis "Format Python code according to the PEP 8 style guide")
4357 "@code{autopep8} automatically formats Python code to conform to
4358 the PEP 8 style guide. It uses the pycodestyle utility to determine
4359 what parts of the code needs to be formatted. @code{autopep8} is
4360 capable of fixing most of the formatting issues that can be reported
4362 (license (license:non-copyleft
4363 "https://github.com/hhatto/autopep8/blob/master/LICENSE"))))
4365 (define-public python2-autopep8
4366 (package-with-python2 python-autopep8))
4368 (define-public python-distutils-extra
4370 (name "python-distutils-extra")
4375 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
4376 version "/+download/python-distutils-extra-"
4380 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
4381 (build-system python-build-system)
4382 (home-page "https://launchpad.net/python-distutils-extra/")
4383 (synopsis "Enhancements to Python's distutils")
4385 "The python-distutils-extra module enables you to easily integrate
4386 gettext support, themed icons, and scrollkeeper-based documentation into
4387 Python's distutils.")
4388 (license license:gpl2)))
4390 (define-public python2-distutils-extra
4391 (package-with-python2 python-distutils-extra))
4393 (define-public python2-elib.intl
4395 (name "python2-elib.intl")
4399 ;; This project doesn't tag releases or publish tarballs, so we take
4400 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
4403 (url "https://github.com/dieterv/elib.intl.git")
4404 (commit "d09997cfef")))
4405 (file-name (string-append name "-" version "-checkout"))
4408 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
4409 (build-system python-build-system)
4411 ;; incompatible with Python 3 (exception syntax)
4412 `(#:python ,python-2
4414 (home-page "https://github.com/dieterv/elib.intl")
4415 (synopsis "Enhanced internationalization for Python")
4417 "The elib.intl module provides enhanced internationalization (I18N)
4418 services for your Python modules and applications.")
4419 (license license:lgpl3+)))
4421 (define-public python-olefile
4423 (name "python-olefile")
4428 (uri (string-append "https://github.com/decalage2/olefile/releases/"
4429 "download/v" version "/olefile-" version ".tar.gz"))
4430 (file-name (string-append name "-" version ".tar.gz"))
4433 "1kjxh4gr651hpqkjfv89cfzr40hyvf3vjlda7mifiail83j7j07m"))))
4434 (build-system python-build-system)
4435 (home-page "https://www.decalage.info/python/olefileio")
4436 (synopsis "Read and write Microsoft OLE2 files.")
4438 "@code{olefile} can parse, read and write Microsoft OLE2 files (Structured
4439 Storage or Compound Document, Microsoft Office). It is an improved version of
4440 the OleFileIO module from PIL, the Python Image Library.")
4441 (license license:bsd-3)))
4443 (define-public python2-olefile
4444 (package-with-python2 python-olefile))
4446 (define-public python-pillow
4448 (name "python-pillow")
4453 (uri (pypi-uri "Pillow" version))
4456 "1c8wkzc58f5wdh006jvmwdk3wxld1xgagcbdvj7iv17qi0m9fkmz"))))
4457 (build-system python-build-system)
4459 `(("python-pytest" ,python-pytest)))
4461 `(("freetype" ,freetype)
4463 ("libjpeg" ,libjpeg-turbo)
4464 ("libtiff" ,libtiff)
4465 ("libwebp" ,libwebp)
4466 ("openjpeg" ,openjpeg)
4469 `(("python-olefile" ,python-olefile)))
4472 (modify-phases %standard-phases
4473 (add-after 'unpack 'patch-ldconfig
4475 (substitute* "setup.py"
4476 (("\\['/sbin/ldconfig', '-p'\\]") "['true']"))))
4478 (lambda* (#:key outputs inputs tests? #:allow-other-keys)
4481 (setenv "HOME" (getcwd))
4482 ;; Make installed package available for running the tests.
4483 (add-installed-pythonpath inputs outputs)
4484 (invoke "python" "selftest.py" "--installed")
4485 (invoke "python" "-m" "pytest" "-vv"))
4487 (home-page "https://python-pillow.org")
4488 (synopsis "Fork of the Python Imaging Library")
4490 "The Python Imaging Library adds image processing capabilities to your
4491 Python interpreter. This library provides extensive file format support, an
4492 efficient internal representation, and fairly powerful image processing
4493 capabilities. The core image library is designed for fast access to data
4494 stored in a few basic pixel formats. It should provide a solid foundation for
4495 a general image processing tool.")
4496 (license (license:x11-style
4497 "http://www.pythonware.com/products/pil/license.htm"
4498 "The PIL Software License"))))
4500 (define-public python2-pillow
4501 (package-with-python2 python-pillow))
4503 (define-public python-pycparser
4505 (name "python-pycparser")
4510 (uri (pypi-uri "pycparser" version))
4513 "1cr5dcj9628lkz1qlwq3fv97c25363qppkmcayqvd05dpy573259"))))
4514 (outputs '("out" "doc"))
4515 (build-system python-build-system)
4517 `(("pkg-config" ,pkg-config)))
4520 (modify-phases %standard-phases
4523 (with-directory-excursion "tests"
4524 (invoke "python" "all_tests.py"))
4526 (add-after 'install 'install-doc
4527 (lambda* (#:key outputs #:allow-other-keys)
4528 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4529 (doc (string-append data "/doc/" ,name "-" ,version))
4530 (examples (string-append doc "/examples")))
4532 (for-each (lambda (file)
4533 (copy-file (string-append "." file)
4534 (string-append doc file)))
4535 '("/README.rst" "/CHANGES" "/LICENSE"))
4536 (copy-recursively "examples" examples)
4538 (home-page "https://github.com/eliben/pycparser")
4539 (synopsis "C parser in Python")
4541 "Pycparser is a complete parser of the C language, written in pure Python
4542 using the PLY parsing library. It parses C code into an AST and can serve as
4543 a front-end for C compilers or analysis tools.")
4544 (license license:bsd-3)))
4546 (define-public python2-pycparser
4547 (package-with-python2 python-pycparser))
4549 (define-public python-pywavelets
4551 (name "python-pywavelets")
4553 (home-page "https://github.com/PyWavelets/pywt")
4556 (uri (pypi-uri "PyWavelets" version))
4559 "1p3qv2v66ghnqrb1f98wyyhp9dz71jwcd6kfpsax65sfdpiyqp1w"))))
4560 (build-system python-build-system)
4562 '(#:modules ((ice-9 ftw)
4566 (guix build python-build-system))
4567 #:phases (modify-phases %standard-phases
4570 (let ((cwd (getcwd))
4571 (libdir (find (cut string-prefix? "lib." <>)
4572 (scandir "build"))))
4573 (with-directory-excursion (string-append cwd "/build/" libdir)
4574 (invoke "nosetests" "-v" "."))))))))
4576 `(("python-matplotlib" ,python-matplotlib) ;for tests
4577 ("python-nose" ,python-nose)))
4579 `(("python-numpy" ,python-numpy)))
4580 (synopsis "Wavelet transforms in Python")
4582 "PyWavelets is a library for wavelet transforms in Python. Wavelets are
4583 mathematical basis functions that are localized in both time and frequency.
4584 Wavelet transforms are time-frequency transforms employing wavelets. They are
4585 similar to Fourier transforms, the difference being that Fourier transforms are
4586 localized only in frequency instead of in time and frequency.")
4587 (license license:expat)))
4589 (define-public python2-pywavelets
4590 (package-with-python2 python-pywavelets))
4592 (define-public python-xcffib
4594 (name "python-xcffib")
4599 (uri (pypi-uri "xcffib" version))
4602 "04k91yxyb3pgc5lvxmivh8w71yjrap2g57yk3s73x4rm4nvjq51n"))))
4603 (build-system python-build-system)
4605 `(("libxcb" ,libxcb)))
4607 `(("python-cffi" ,python-cffi) ; used at run time
4608 ("python-six" ,python-six)))
4610 `(;; FIXME: Tests need more work. See ".travis.yml" in the repository.
4613 (modify-phases %standard-phases
4614 (add-after 'unpack 'fix-libxcb-path
4615 (lambda* (#:key inputs #:allow-other-keys)
4616 (let ((libxcb (assoc-ref inputs "libxcb")))
4617 (substitute* '("xcffib/__init__.py")
4618 (("^soname = \"") (string-append "soname = \"" libxcb "/lib/")))
4620 (add-after 'install 'install-doc
4621 (lambda* (#:key outputs #:allow-other-keys)
4622 (let ((doc (string-append (assoc-ref outputs "out") "/share"
4623 "/doc/" ,name "-" ,version)))
4625 (copy-file "README.md"
4626 (string-append doc "/README.md"))
4628 (home-page "https://github.com/tych0/xcffib")
4629 (synopsis "XCB Python bindings")
4631 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
4632 support for Python 3 and PyPy. It is based on cffi.")
4633 (license license:expat)))
4635 (define-public python2-xcffib
4636 (package-with-python2 python-xcffib))
4638 (define-public python-cairocffi
4640 (name "python-cairocffi")
4645 (uri (pypi-uri "cairocffi" version))
4648 "0dq3k4zhqd8cwsf3nyjqvjqm8wkvrjn1wjf44rl3v0h8kqx6qf0m"))
4649 (patches (search-patches "python-cairocffi-dlopen-path.patch"))))
4650 (build-system python-build-system)
4651 (outputs '("out" "doc"))
4655 ("gdk-pixbuf" ,gdk-pixbuf)
4659 `(("pkg-config" ,pkg-config)
4660 ("python-pytest" ,python-pytest)
4661 ("python-pytest-cov" ,python-pytest-cov)
4662 ("python-pytest-runner" ,python-pytest-runner)
4663 ("python-sphinx" ,python-sphinx)
4664 ("python-docutils" ,python-docutils)))
4666 `(("python-xcffib" ,python-xcffib))) ; used at run time
4669 (modify-phases %standard-phases
4670 (add-after 'unpack 'patch-paths
4671 (lambda* (#:key inputs outputs #:allow-other-keys)
4672 (substitute* (find-files "." "\\.py$")
4673 (("dlopen\\(ffi, 'cairo'")
4674 (string-append "dlopen(ffi, '" (assoc-ref inputs "cairo")
4675 "/lib/libcairo.so.2'"))
4676 (("dlopen\\(ffi, 'gdk-3'")
4677 (string-append "dlopen(ffi, '" (assoc-ref inputs "gtk+")
4678 "/lib/libgtk-3.so.0'"))
4679 (("dlopen\\(ffi, 'gdk_pixbuf-2.0'")
4680 (string-append "dlopen(ffi, '" (assoc-ref inputs "gdk-pixbuf")
4681 "/lib/libgdk_pixbuf-2.0.so.0'"))
4682 (("dlopen\\(ffi, 'glib-2.0'")
4683 (string-append "dlopen(ffi, '" (assoc-ref inputs "glib")
4684 "/lib/libglib-2.0.so.0'"))
4685 (("dlopen\\(ffi, 'gobject-2.0'")
4686 (string-append "dlopen(ffi, '" (assoc-ref inputs "glib")
4687 "/lib/libgobject-2.0.so.0'"))
4688 (("dlopen\\(ffi, 'pangocairo-1.0'")
4689 (string-append "dlopen(ffi, '" (assoc-ref inputs "pango")
4690 "/lib/libpangocairo-1.0.so.0'"))
4691 (("dlopen\\(ffi, 'pango-1.0'")
4692 (string-append "dlopen(ffi, '" (assoc-ref inputs "pango")
4693 "/lib/libpango-1.0.so.0'")))
4695 (add-after 'install 'install-doc
4696 (lambda* (#:key inputs outputs #:allow-other-keys)
4697 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4698 (doc (string-append data "/doc/" ,name "-" ,version))
4699 (html (string-append doc "/html")))
4700 (setenv "LD_LIBRARY_PATH"
4701 (string-append (assoc-ref inputs "cairo") "/lib" ":"
4702 (assoc-ref inputs "gdk-pixbuf") "/lib"))
4703 (setenv "LANG" "en_US.UTF-8")
4705 (for-each (lambda (file)
4706 (copy-file (string-append "." file)
4707 (string-append doc file)))
4708 '("/README.rst" "/CHANGES" "/LICENSE"))
4709 (system* "python" "setup.py" "build_sphinx")
4710 (copy-recursively "docs/_build/html" html)
4712 (home-page "https://github.com/Kozea/cairocffi")
4713 (synopsis "Python bindings and object-oriented API for Cairo")
4715 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
4716 Python bindings and object-oriented API for cairo. Cairo is a 2D vector
4717 graphics library with support for multiple backends including image buffers,
4718 PNG, PostScript, PDF, and SVG file output.")
4719 (license license:bsd-3)))
4721 (define-public python2-cairocffi
4722 (package-with-python2 python-cairocffi))
4724 (define-public python-decorator
4726 (name "python-decorator")
4731 (uri (pypi-uri "decorator" version))
4733 (base32 "0308djallnh00v112y5b7nadl657ysmkp6vc8xn51d6yzc9zm7n3"))))
4734 (build-system python-build-system)
4735 (home-page "https://pypi.python.org/pypi/decorator/")
4736 (synopsis "Python module to simplify usage of decorators")
4738 "The aim of the decorator module is to simplify the usage of decorators
4739 for the average programmer, and to popularize decorators usage giving examples
4740 of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
4741 etc. The core of this module is a decorator factory.")
4742 (license license:expat)))
4744 (define-public python2-decorator
4745 (package-with-python2 python-decorator))
4747 (define-public python-drmaa
4749 (name "python-drmaa")
4754 (uri (pypi-uri "drmaa" version))
4756 (base32 "0xzqriqyvk5b8hszbavsyxd29wm3sxirm8zvvdm73rs2iq7w4hkx"))))
4757 (build-system python-build-system)
4758 ;; The test suite requires libdrmaa which is provided by the cluster
4759 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
4760 ;; should be set to the path of the libdrmaa library.
4761 (arguments '(#:tests? #f))
4763 `(("python-nose" ,python-nose)))
4764 (home-page "https://pypi.python.org/pypi/drmaa")
4765 (synopsis "Python bindings for the DRMAA library")
4767 "A Python package for Distributed Resource Management (DRM) job
4768 submission and control. This package is an implementation of the DRMAA 1.0
4769 Python language binding specification.")
4770 (license license:bsd-3)))
4772 (define-public python2-drmaa
4773 (package-with-python2 python-drmaa))
4775 (define-public python-grako
4777 (name "python-grako")
4783 (pypi-uri "grako" version ".zip"))
4786 "0r63i68wcnv63rfjkasq1ah81frz61a6mzbcnaxhrkdpx84p7hzw"))))
4787 (build-system python-build-system)
4788 (arguments '(#:tests? #f)) ; Test file 'grako.ebnf' is missing from archive.
4791 ("python-pytest" ,python-pytest)
4792 ("python-pytest-runner" ,python-pytest-runner)))
4793 (home-page "https://bitbucket.org/neogeny/grako")
4794 (synopsis "EBNF parser generator")
4796 "Grako takes a grammar in a variation of EBNF as input, and outputs a
4797 memoizing PEG/Packrat parser in Python.")
4798 (license license:bsd-3)))
4800 (define-public python2-grako
4801 (package-with-python2 python-grako))
4803 (define-public python-gridmap
4805 (name "python-gridmap")
4811 (url "https://github.com/pygridtools/gridmap.git")
4812 (commit (string-append "v" version))))
4813 (file-name (git-file-name name version))
4815 (base32 "1478lbwsr1w24cii2x01m2910fvh8r43ghnb78nc972a96hqiknm"))))
4816 (build-system python-build-system)
4818 '(#:tests? #f)) ; FIXME: Requires python-cherrypy.
4820 `(("python-psutil" ,python-psutil)
4821 ("python-drmaa" ,python-drmaa)
4822 ("python-pyzmq" ,python-pyzmq)))
4823 (home-page "https://github.com/pygridtools/gridmap")
4824 (synopsis "Create jobs on a cluster directly from Python")
4826 "Gridmap is a Python package to allow you to easily create jobs on the
4827 cluster directly from Python. You can directly map Python functions onto the
4828 cluster without needing to write any wrapper code yourself.")
4829 (license license:gpl3+)))
4831 (define-public python2-gridmap
4832 (package-with-python2 python-gridmap))
4834 (define-public python-honcho
4836 (name "python-honcho")
4842 (url "https://github.com/nickstenning/honcho.git")
4843 (commit (string-append "v" version))))
4844 (file-name (git-file-name name version))
4846 (base32 "11bd87474qpif20xdcn0ra1idj5k16ka51i658wfpxwc6nzsn92b"))))
4847 (build-system python-build-system)
4849 `(("python-pytest" ,python-pytest)
4850 ("python-mock" ,python-mock)
4851 ("python-tox" ,python-tox)
4852 ("which" ,which))) ;for tests
4854 `(("python-jinja2" ,python-jinja2)))
4857 (modify-phases %standard-phases
4859 (add-after 'install 'check
4860 (lambda* (#:key outputs inputs #:allow-other-keys)
4861 ;; fix honcho path in testsuite
4862 (substitute* "tests/conftest.py"
4863 (("'honcho'") (string-append "'" (assoc-ref outputs "out")
4864 "/bin/honcho" "'")))
4865 ;; It's easier to run tests after install.
4866 ;; Make installed package available for running the tests
4867 (add-installed-pythonpath inputs outputs)
4868 (invoke "py.test" "-v"))))))
4869 (home-page "https://github.com/nickstenning/honcho")
4870 (synopsis "Manage Procfile-based applications")
4872 "A Procfile is a file which describes how to run an application
4873 consisting of several processes. honcho starts all listed processes.
4874 The output of all running processes is collected by honcho and
4876 (license license:expat)))
4878 (define-public python2-honcho
4879 (package-with-python2 python-honcho))
4881 (define-public python-pexpect
4883 (name "python-pexpect")
4888 (uri (pypi-uri "pexpect" version))
4890 (base32 "1fla85g47iaxxpjhp9vkxdnv4pgc7rplfy6ja491smrrk0jqi3ia"))))
4891 (build-system python-build-system)
4894 (modify-phases %standard-phases
4895 (add-before 'check 'prepare-tests
4897 (substitute* (find-files "tests")
4898 (("/bin/ls") (which "ls"))
4899 (("/bin/echo") (which "echo"))
4900 (("/bin/which") (which "which"))
4901 ;; Many tests try to use the /bin directory which
4902 ;; is not present in the build environment.
4903 ;; Use one that's non-empty and unlikely to change.
4904 (("/bin'") "/dev'"))
4905 ;; XXX: Socket connection test gets "Connection reset by peer".
4906 ;; Why does it not work? Delete for now.
4907 (delete-file "tests/test_socket.py")
4909 (replace 'check (lambda _ (invoke "nosetests" "-v"))))))
4911 `(("python-nose" ,python-nose)
4912 ("python-pytest" ,python-pytest)
4915 ("bash-full" ,bash))) ;full Bash for 'test_replwrap.py'
4917 `(("python-ptyprocess" ,python-ptyprocess)))
4918 (home-page "http://pexpect.readthedocs.org/")
4919 (synopsis "Controlling interactive console applications")
4921 "Pexpect is a pure Python module for spawning child applications;
4922 controlling them; and responding to expected patterns in their output.
4923 Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4924 child application and control it as if a human were typing commands.")
4925 (license license:isc)))
4927 (define-public python2-pexpect
4928 (package-with-python2 python-pexpect))
4930 (define-public python-setuptools-scm
4932 (name "python-setuptools-scm")
4936 (uri (pypi-uri "setuptools_scm" version))
4939 "0n3knn3p1sqlx31k2lahn7z9bacvlv8nhlfidj77vz50bxqlgasj"))))
4940 (build-system python-build-system)
4941 (home-page "https://github.com/pypa/setuptools_scm/")
4942 (synopsis "Manage Python package versions in SCM metadata")
4944 "Setuptools_scm handles managing your Python package versions in
4945 @dfn{software configuration management} (SCM) metadata instead of declaring
4946 them as the version argument or in a SCM managed file.")
4947 (license license:expat)))
4949 ;; Needed by python-lazy-object-proxy, remove on next update cycle.
4950 (define-public python-setuptools-scm-3.3
4952 (inherit python-setuptools-scm)
4956 (uri (pypi-uri "setuptools_scm" version))
4959 "19cyndx23xmpbhz4qrwmfwsmnnaczd0dw7qg977ksq2dbvxy29dx"))))))
4961 (define-public python2-setuptools-scm
4962 (package-with-python2 python-setuptools-scm))
4964 (define-public python-pathlib2
4966 (name "python-pathlib2")
4971 (uri (pypi-uri "pathlib2" version))
4974 "0hpp92vqqgcd8h92msm9slv161b1q160igjwnkf2ag6cx0c96695"))))
4975 (build-system python-build-system)
4977 `(("python-scandir" ,python-scandir)
4978 ("python-six" ,python-six)))
4979 (home-page "https://pypi.python.org/pypi/pathlib2/")
4980 (synopsis "Object-oriented file system paths")
4981 (description "The goal of pathlib2 is to provide a backport of the
4982 standard @code{pathlib} module which tracks the standard library module, so
4983 all the newest features of the standard @code{pathlib} can be used also on
4984 older Python versions.")
4985 (license license:expat)))
4987 (define-public python2-importlib-resources
4989 (name "python2-importlib-resources")
4993 (uri (pypi-uri "importlib_resources" version))
4996 "0y3hg12iby1qyaspnbisz4s4vxax7syikk3skznwqizqyv89y9yk"))))
4997 (build-system python-build-system)
4999 `(#:python ,python-2))
5001 `(("python-wheel" ,python2-wheel)))
5003 `(("python-pathlib2" ,python2-pathlib2)
5004 ("python-typing" ,python2-typing)))
5005 (home-page "https://gitlab.com/python-devs/importlib_resources")
5006 (synopsis "Backport of @code{importlib.resources} from Python 3.7")
5008 "This package provides an implementation of @code{importlib.resources}
5009 for older versions of Python.")
5010 (license license:asl2.0)))
5012 (define-public python-importlib-metadata
5014 (name "python-importlib-metadata")
5019 (uri (pypi-uri "importlib_metadata" version))
5021 (base32 "1n76444v7zn910xrhh8954jdn4byxbn9f1jck6b85a716mbh2z7i"))))
5022 (build-system python-build-system)
5024 `(("python-zipp" ,python-zipp)))
5026 `(("python-setuptools-scm" ,python-setuptools-scm)
5027 ("python-packaging" ,python-packaging)))
5028 (home-page "https://importlib-metadata.readthedocs.io/")
5029 (synopsis "Read metadata from Python packages")
5031 "@code{importlib_metadata} is a library which provides an API for
5032 accessing an installed Python package's metadata, such as its entry points or
5033 its top-level name. This functionality intends to replace most uses of
5034 @code{pkg_resources} entry point API and metadata API. Along with
5035 @code{importlib.resources} in Python 3.7 and newer, this can eliminate the
5036 need to use the older and less efficient @code{pkg_resources} package.")
5037 (properties `((python2-variant . ,(delay python2-importlib-metadata))))
5038 (license license:asl2.0)))
5040 (define-public python2-importlib-metadata
5041 (let ((base (package-with-python2 (strip-python2-variant
5042 python-importlib-metadata))))
5045 (name "python2-importlib-metadata")
5047 `(("python-configparser" ,python2-configparser)
5048 ("python-contextlib2" ,python2-contextlib2)
5049 ("python-importlib-resources" ,python2-importlib-resources)
5050 ("python-pathlib2" ,python2-pathlib2)
5051 ,@(package-propagated-inputs base))))))
5053 (define-public python-jaraco-packaging
5055 (name "python-jaraco-packaging")
5060 (uri (pypi-uri "jaraco.packaging" version))
5063 "0zimrnkh33b9g8ffw11mjh6kvs54cy5gcjw1h5cl1r7dc833dmkm"))))
5064 (build-system python-build-system)
5066 `(("python-pytest" ,python-pytest)
5067 ("python-pytest-checkdocs" ,python-pytest-checkdocs)
5068 ("python-pytest-flake8" ,python-pytest-flake8)
5069 ("python-rst.linker" ,python-rst.linker)
5070 ("python-setuptools" ,python-setuptools)
5071 ("python-setuptools-scm" ,python-setuptools-scm)
5072 ("python-six" ,python-six)
5073 ("python-sphinx" ,python-sphinx)))
5074 (home-page "https://github.com/jaraco/jaraco.packaging")
5075 (synopsis "Tools to supplement packaging Python releases")
5077 "This package provides various tools to supplement packaging Python
5079 (license license:expat)))
5081 (define-public python-pathpy
5083 (name "python-pathpy")
5088 (uri (pypi-uri "path.py" version))
5090 (base32 "0ir9j1haq2jbi7aip6k2fa9l7q1l03k4hp1awxhjhcwzsnwp3ll8"))))
5091 (outputs '("out" "doc"))
5092 (build-system python-build-system)
5094 `(("python-appdirs" ,python-appdirs)
5095 ("python-importlib-metadata" ,python-importlib-metadata)))
5097 `(("python-setuptools-scm" ,python-setuptools-scm)
5098 ("python-sphinx" ,python-sphinx)
5099 ("python-rst.linker" ,python-rst.linker)
5100 ("python-pytest" ,python-pytest)
5101 ("python-pytest-runner" ,python-pytest-runner)
5102 ("python-jaraco-packaging" ,python-jaraco-packaging)))
5105 (modify-phases %standard-phases
5106 (add-after 'build 'build-doc
5108 (setenv "LANG" "en_US.UTF-8")
5109 (invoke "python" "setup.py" "build_sphinx")))
5110 (add-after 'install 'install-doc
5111 (lambda* (#:key outputs #:allow-other-keys)
5112 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
5113 (doc (string-append data "/doc/" ,name "-" ,version))
5114 (html (string-append doc "/html")))
5116 (for-each (lambda (file)
5117 (copy-file file (string-append doc "/" file)))
5118 '("README.rst" "CHANGES.rst"))
5119 (copy-recursively "build/sphinx/html" html)
5123 ;; The import time test aborts if an import takes longer than
5124 ;; 100ms. It may very well take a little longer than that.
5125 (invoke "pytest" "-v" "-k" "not test_import_time"))))))
5126 (home-page "https://github.com/jaraco/path.py")
5127 (synopsis "Python module wrapper for built-in os.path")
5129 "@code{path.py} implements path objects as first-class entities, allowing
5130 common operations on files to be invoked on those path objects directly.")
5131 (license license:expat)))
5133 (define-public python2-pathpy
5134 (package-with-python2 python-pathpy))
5136 (define-public python-simplegeneric
5138 (name "python-simplegeneric")
5143 (uri (pypi-uri "simplegeneric" version ".zip"))
5145 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
5146 (build-system python-build-system)
5148 `(("unzip" ,unzip)))
5149 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
5150 (synopsis "Python module for simple generic functions")
5152 "The simplegeneric module lets you define simple single-dispatch generic
5153 functions, akin to Python’s built-in generic functions like @code{len()},
5154 @code{iter()} and so on. However, instead of using specially-named methods,
5155 these generic functions use simple lookup tables, akin to those used by
5156 e.g. @code{pickle.dump()} and other generic functions found in the Python
5158 (license license:zpl2.1)))
5160 (define-public python2-simplegeneric
5161 (package-with-python2 python-simplegeneric))
5163 (define-public python-ipython-genutils
5164 ;; TODO: This package is retired, check if can be removed, see description.
5166 (name "python-ipython-genutils")
5171 (uri (pypi-uri "ipython_genutils" version))
5173 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
5174 (build-system python-build-system)
5175 (arguments `(#:tests? #f)) ; no tests
5176 (home-page "https://ipython.org")
5177 (synopsis "Vestigial utilities from IPython")
5179 "This package provides retired utilities from IPython. No packages
5180 outside IPython/Jupyter should depend on it.
5182 This package shouldn't exist. It contains some common utilities shared by
5183 Jupyter and IPython projects during The Big Split. As soon as possible, those
5184 packages will remove their dependency on this, and this package will go
5186 (license license:bsd-3)))
5188 (define-public python2-ipython-genutils
5189 (package-with-python2 python-ipython-genutils))
5191 (define-public python-traitlets
5193 (name "python-traitlets")
5198 (uri (pypi-uri "traitlets" version))
5201 "1xsrwgivpkxlbr4dfndfsi098s29yqgswgjc1qqn69yxklvfw8yh"))))
5202 (build-system python-build-system)
5205 (modify-phases %standard-phases
5206 (replace 'check (lambda _ (invoke "pytest" "-vv" "traitlets"))))))
5208 `(("python-ipython-genutils" ,python-ipython-genutils)
5209 ("python-decorator" ,python-decorator)))
5211 `(("python-pytest" ,python-pytest)))
5212 (properties `((python2-variant . ,(delay python2-traitlets))))
5213 (home-page "https://ipython.org")
5214 (synopsis "Configuration system for Python applications")
5216 "Traitlets is a framework that lets Python classes have attributes with
5217 type checking, dynamically calculated default values, and ‘on change’
5218 callbacks. The package also includes a mechanism to use traitlets for
5219 configuration, loading values from files or from command line arguments. This
5220 is a distinct layer on top of traitlets, so you can use traitlets in your code
5221 without using the configuration machinery.")
5222 (license license:bsd-3)))
5224 (define-public python2-traitlets
5225 (let ((traitlets (package-with-python2 (strip-python2-variant python-traitlets))))
5229 `(("python2-enum34" ,python2-enum34)
5230 ,@(package-propagated-inputs traitlets))))))
5232 (define-public python-jupyter-core
5234 (name "python-jupyter-core")
5239 (uri (string-append (pypi-uri "jupyter_core" version)))
5242 "1dy083rarba8prn9f9srxq3c7n7vyql02ycrqq306c40lr57aw5s"))))
5243 (build-system python-build-system)
5244 ;; FIXME: not sure how to run the tests
5245 (arguments `(#:tests? #f))
5247 `(("python-traitlets" ,python-traitlets)))
5248 (home-page "http://jupyter.org/")
5249 (synopsis "Jupyter base package")
5251 "Jupyter core is the base package on which Jupyter projects rely.")
5252 (license license:bsd-3)))
5254 (define-public python2-jupyter-core
5255 (package-with-python2 python-jupyter-core))
5257 (define-public python-jupyter-client
5259 (name "python-jupyter-client")
5264 (uri (pypi-uri "jupyter_client" version))
5267 "0l9mh7ccrpl3lppym3dnky8n1nk7xarzzdcxf4q2s7aw203cpydm"))))
5268 (build-system python-build-system)
5269 ;; Tests fail because of missing native python kernel which I assume is
5270 ;; provided by the ipython package, which we cannot use because it would
5271 ;; cause a dependency cycle.
5275 #:phases (modify-phases %standard-phases
5276 (add-after 'unpack 'set-tool-file-names
5277 (lambda* (#:key inputs #:allow-other-keys)
5278 (let ((iproute (assoc-ref inputs "iproute")))
5279 (substitute* "jupyter_client/localinterfaces.py"
5281 (string-append "'" iproute "/sbin/ip'")))
5284 `(("iproute" ,iproute)))
5286 `(("python-pyzmq" ,python-pyzmq)
5287 ("python-traitlets" ,python-traitlets)
5288 ("python-jupyter-core" ,python-jupyter-core)))
5289 (home-page "http://jupyter.org/")
5290 (synopsis "Jupyter protocol implementation and client libraries")
5292 "The @code{jupyter_client} package contains the reference implementation
5293 of the Jupyter protocol. It also provides client and kernel management APIs
5294 for working with kernels, and the @code{jupyter kernelspec} entrypoint for
5295 installing @code{kernelspec}s for use with Jupyter frontends.")
5296 (license license:bsd-3)))
5298 (define-public python2-jupyter-client
5299 (package-with-python2 python-jupyter-client))
5301 (define-public python-ipykernel
5303 (name "python-ipykernel")
5308 (uri (pypi-uri "ipykernel" version))
5310 (base32 "1a08y677lpn80qzvv7z0smgggmr5m5ayf0bs6vds47xpxl9sss5k"))))
5311 (build-system python-build-system)
5314 (modify-phases %standard-phases
5317 (setenv "HOME" "/tmp")
5318 (invoke "pytest" "-v")
5320 (add-after 'install 'set-python-file-name
5321 (lambda* (#:key outputs #:allow-other-keys)
5322 ;; Record the absolute file name of the 'python' executable in
5324 (let ((out (assoc-ref outputs "out")))
5325 (substitute* (string-append out "/share/jupyter"
5326 "/kernels/python3/kernel.json")
5328 (string-append "\"" (which "python") "\"")))
5331 `(("python-ipython" ,python-ipython)
5332 ;; imported at runtime during connect
5333 ("python-jupyter-client" ,python-jupyter-client)))
5335 `(("python-flaky" ,python-flaky)
5336 ("python-nose" ,python-nose)
5337 ("python-pytest" ,python-pytest)))
5338 (home-page "https://ipython.org")
5339 (synopsis "IPython Kernel for Jupyter")
5341 "This package provides the IPython kernel for Jupyter.")
5342 (license license:bsd-3)))
5344 ;; Version 5.1.1 and above no longer support Python 2.
5345 (define-public python2-ipykernel
5347 (name "python2-ipykernel")
5352 (uri (pypi-uri "ipykernel" version))
5354 (base32 "0br95qhrd5k65g10djngiy27hs0642301hlf2q142i8djabvzh0g"))))
5355 (build-system python-build-system)
5357 `(#:python ,python-2
5359 (modify-phases %standard-phases
5362 (setenv "HOME" "/tmp")
5363 (invoke "pytest" "-v")
5366 `(("python2-ipython" ,python2-ipython)
5367 ;; imported at runtime during connect
5368 ("python2-jupyter-client" ,python2-jupyter-client)))
5370 `(("python2-pytest" ,python2-pytest)
5371 ("python2-nose" ,python2-nose)))
5372 (home-page "https://ipython.org")
5373 (synopsis "IPython Kernel for Jupyter")
5375 "This package provides the IPython kernel for Jupyter.")
5376 (license license:bsd-3)))
5378 (define-public python-pari-jupyter
5380 (name "python-pari-jupyter")
5385 (uri (pypi-uri "pari_jupyter" version))
5388 "1yash0p422nnin7z58b99d0p23nx79f5m0mainc9hsjg72jhdhr6"))))
5389 (build-system python-build-system)
5391 `(("python-ipykernel" ,python-ipykernel)))
5393 `(("pari-gp" ,pari-gp)
5394 ("readline" ,readline)))
5396 `(#:tests? #f)) ; no test suite
5398 "https://github.com/jdemeyer/pari_jupyter")
5399 (synopsis "A Jupyter kernel for PARI/GP")
5400 (description "The package provides a PARI/GP kernel for Jupyter.")
5401 (license license:gpl3+)))
5403 (define-public python-backcall
5405 (name "python-backcall")
5410 (uri (pypi-uri "backcall" version))
5413 "1r01dqch3f8fdj3n6fviw8hxqrs6w5v0qw4izmvqzry1w9dxiv1q"))))
5414 (build-system python-build-system)
5415 (home-page "https://github.com/takluyver/backcall/")
5416 (synopsis "Specifications for callback functions passed in to an API")
5418 "If your code lets other people supply callback functions, it's important
5419 to specify the function signature you expect, and check that functions support
5420 that. Adding extra parameters later would break other peoples code unless
5421 you're careful. The @code{backcall} package provides a way of specifying the
5422 callback signature using a prototype function.")
5423 (license license:bsd-3)))
5425 ;; This is the latest release of the LTS version of ipython with support for
5426 ;; Python 2.7 and Python 3.x. Later non-LTS versions starting from 6.0 have
5427 ;; dropped support for Python 2.7.
5428 (define-public python2-ipython
5430 (name "python2-ipython")
5435 (uri (pypi-uri "ipython" version ".tar.gz"))
5437 (base32 "01l93i4hspf0lvhmycvc8j378bslm9rw30mwfspsl6v1ayc69b2b"))))
5438 (build-system python-build-system)
5440 `(("python2-backports-shutil-get-terminal-size"
5441 ,python2-backports-shutil-get-terminal-size)
5442 ("python2-pathlib2" ,python2-pathlib2)
5443 ("python2-pyzmq" ,python2-pyzmq)
5444 ("python2-prompt-toolkit" ,python2-prompt-toolkit-1)
5445 ("python2-terminado" ,python2-terminado)
5446 ("python2-matplotlib" ,python2-matplotlib)
5447 ("python2-numpy" ,python2-numpy)
5448 ("python2-numpydoc" ,python2-numpydoc)
5449 ("python2-jinja2" ,python2-jinja2)
5450 ("python2-mistune" ,python2-mistune)
5451 ("python2-pexpect" ,python2-pexpect)
5452 ("python2-pickleshare" ,python2-pickleshare)
5453 ("python2-simplegeneric" ,python2-simplegeneric)
5454 ("python2-jsonschema" ,python2-jsonschema)
5455 ("python2-traitlets" ,python2-traitlets)
5456 ("python2-nbformat" ,python2-nbformat)
5457 ("python2-pygments" ,python2-pygments)))
5459 `(("readline" ,readline)
5462 `(("graphviz" ,graphviz)
5463 ("pkg-config" ,pkg-config)
5464 ("python2-requests" ,python2-requests) ;; for tests
5465 ("python2-testpath" ,python2-testpath)
5466 ("python2-mock" ,python2-mock)
5467 ("python2-nose" ,python2-nose)))
5469 `(#:python ,python-2
5471 (modify-phases %standard-phases
5472 (add-before 'check 'delete-broken-tests
5473 (lambda* (#:key inputs #:allow-other-keys)
5474 ;; These tests throw errors for unknown reasons.
5475 (delete-file "IPython/core/tests/test_profile.py")
5476 (delete-file "IPython/core/tests/test_interactiveshell.py")
5477 (delete-file "IPython/core/tests/test_magic.py")
5479 (home-page "https://ipython.org")
5480 (synopsis "IPython is a tool for interactive computing in Python")
5482 "IPython provides a rich architecture for interactive computing with:
5483 Powerful interactive shells, a browser-based notebook, support for interactive
5484 data visualization, embeddable interpreters and tools for parallel
5486 (license license:bsd-3)))
5488 (define-public python-ipython
5490 (name "python-ipython")
5495 (uri (pypi-uri "ipython" version ".tar.gz"))
5497 (base32 "103jkw18z7fnwdal1mdbijjxi1fndzn31g887lmj7ddpf2r07lyz"))))
5498 (build-system python-build-system)
5500 `(("python-backcall" ,python-backcall)
5501 ("python-pyzmq" ,python-pyzmq)
5502 ("python-prompt-toolkit" ,python-prompt-toolkit)
5503 ("python-terminado" ,python-terminado)
5504 ("python-matplotlib" ,python-matplotlib)
5505 ("python-numpy" ,python-numpy)
5506 ("python-numpydoc" ,python-numpydoc)
5507 ("python-jedi" ,python-jedi)
5508 ("python-jinja2" ,python-jinja2)
5509 ("python-mistune" ,python-mistune)
5510 ("python-pexpect" ,python-pexpect)
5511 ("python-pickleshare" ,python-pickleshare)
5512 ("python-simplegeneric" ,python-simplegeneric)
5513 ("python-jsonschema" ,python-jsonschema)
5514 ("python-traitlets" ,python-traitlets)
5515 ("python-nbformat" ,python-nbformat)
5516 ("python-pygments" ,python-pygments)))
5518 `(("readline" ,readline)
5521 `(("graphviz" ,graphviz)
5522 ("pkg-config" ,pkg-config)
5523 ("python-requests" ,python-requests) ;; for tests
5524 ("python-testpath" ,python-testpath)
5525 ("python-nose" ,python-nose)))
5528 (modify-phases %standard-phases
5529 (add-after 'unpack 'make-docs-reproducible
5531 (substitute* "IPython/sphinxext/ipython_directive.py"
5532 ((".*import datetime") "")
5533 ((".*datetime.datetime.now\\(\\)") "")
5534 (("%timeit") "# %timeit"))
5536 ;; Tests can only be run after the library has been installed and not
5537 ;; within the source directory.
5539 (add-after 'install 'check
5540 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
5543 ;; Make installed package available for running the tests
5544 (add-installed-pythonpath inputs outputs)
5545 (setenv "HOME" "/tmp/") ;; required by a test
5546 ;; We only test the core because one of the other tests
5547 ;; tries to import ipykernel.
5548 (invoke "python" "IPython/testing/iptest.py"
5549 "-v" "IPython/core/tests"))
5551 (add-before 'check 'fix-tests
5552 (lambda* (#:key inputs #:allow-other-keys)
5553 (substitute* "./IPython/utils/_process_posix.py"
5554 (("/usr/bin/env', 'which") (which "which")))
5555 (substitute* "./IPython/core/tests/test_inputtransformer.py"
5556 (("#!/usr/bin/env python")
5557 (string-append "#!" (which "python"))))
5558 ;; This test introduces a circular dependency on ipykernel
5559 ;; (which depends on ipython).
5560 (delete-file "IPython/core/tests/test_display.py")
5561 ;; AttributeError: module 'IPython.core' has no attribute 'formatters'
5562 (delete-file "IPython/core/tests/test_interactiveshell.py")
5564 (home-page "https://ipython.org")
5565 (synopsis "IPython is a tool for interactive computing in Python")
5567 "IPython provides a rich architecture for interactive computing with:
5568 Powerful interactive shells, a browser-based notebook, support for interactive
5569 data visualization, embeddable interpreters and tools for parallel
5571 (license license:bsd-3)))
5573 (define-public python-ipython-documentation
5575 (inherit python-ipython)
5576 (name "python-ipython-documentation")
5577 (version (package-version python-ipython))
5580 (modify-phases %standard-phases
5584 (lambda* (#:key outputs #:allow-other-keys)
5585 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
5586 (doc (string-append data "/doc/" ,name "-" ,version))
5587 (html (string-append doc "/html"))
5588 (man1 (string-append data "/man/man1"))
5589 (info (string-append data "/info"))
5590 (examples (string-append doc "/examples"))
5591 (python-arg (string-append "PYTHON=" (which "python"))))
5592 (setenv "LANG" "en_US.utf8")
5593 (with-directory-excursion "docs"
5594 ;; FIXME: pdf fails to build
5595 ;;(system* "make" "pdf" "PAPER=a4")
5596 (system* "make" python-arg "html")
5597 ;; FIXME: the generated texi file contains ^@^@, which trips
5599 ;; (system* "make" python-arg "info")
5601 (copy-recursively "docs/man" man1)
5602 (copy-recursively "examples" examples)
5603 (copy-recursively "docs/build/html" html)
5604 ;; (copy-file "docs/build/latex/ipython.pdf"
5605 ;; (string-append doc "/ipython.pdf"))
5607 ;; (copy-file "docs/build/texinfo/ipython.info"
5608 ;; (string-append info "/ipython.info"))
5609 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))
5612 `(("python-ipython" ,python-ipython)
5613 ("python-ipykernel" ,python-ipykernel)))
5615 `(("python-sphinx" ,python-sphinx)
5616 ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)
5617 ;; FIXME: It's possible that a smaller union would work just as well.
5618 ("texlive" ,(texlive-union (list texlive-amsfonts
5620 texlive-generic-ifxetex
5621 texlive-generic-pdftex
5622 texlive-latex-capt-of
5624 texlive-latex-environ
5625 texlive-latex-eqparbox
5626 texlive-latex-etoolbox
5627 texlive-latex-expdlist
5628 texlive-latex-fancyhdr
5629 texlive-latex-fancyvrb
5630 texlive-latex-fncychap
5632 texlive-latex-framed
5633 texlive-latex-geometry
5634 texlive-latex-graphics
5635 texlive-latex-hyperref
5636 texlive-latex-mdwtools
5637 texlive-latex-multirow
5638 texlive-latex-needspace
5639 texlive-latex-oberdiek
5640 texlive-latex-parskip
5641 texlive-latex-preview
5642 texlive-latex-tabulary
5643 texlive-latex-threeparttable
5644 texlive-latex-titlesec
5645 texlive-latex-trimspaces
5647 texlive-latex-upquote
5649 texlive-latex-varwidth
5650 texlive-latex-wrapfig)))
5651 ("texinfo" ,texinfo)))))
5653 (define-public python-urwid
5655 (name "python-urwid")
5660 (uri (pypi-uri "urwid" version))
5663 "1g6cpicybvbananpjikmjk8npmjk4xvak1wjzji62wc600wkwkb4"))))
5664 (build-system python-build-system)
5665 (home-page "http://urwid.org")
5666 (synopsis "Console user interface library for Python")
5668 "Urwid is a curses-based UI/widget library for Python. It includes many
5669 features useful for text console applications.")
5670 (license license:lgpl2.1+)))
5672 (define-public python2-urwid
5673 (package-with-python2 python-urwid))
5675 (define-public python-urwidtrees
5677 (name "python-urwidtrees")
5682 ;; package author intends on distributing via github rather than pypi:
5683 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
5685 (url "https://github.com/pazz/urwidtrees")
5687 (file-name (git-file-name name version))
5690 "1n1kpidvkdnsqyb82vlvk78gmly96kh8351lqxn2pzgwwns6fml2"))))
5691 (build-system python-build-system)
5693 '(#:use-setuptools? #f
5694 #:tests? #f)) ; no tests
5695 (propagated-inputs `(("python-urwid" ,python-urwid)))
5696 (home-page "https://github.com/pazz/urwidtrees")
5697 (synopsis "Tree widgets for urwid")
5698 (description "Urwidtrees is a Widget Container API for the @code{urwid}
5699 toolkit. Use it to build trees of widgets.")
5700 (license license:gpl3+)))
5702 (define-public python2-urwidtrees
5703 (package-with-python2 python-urwidtrees))
5705 (define-public python-ua-parser
5707 (name "python-ua-parser")
5712 (uri (pypi-uri "ua-parser" version))
5715 "1jwdf58rhchjzzrad405pviv0iq24xa2xmmmdgcm2c8s6b4wzfwp"))))
5716 (build-system python-build-system)
5718 `(#:tests? #f)) ;no test suite in release
5720 `(("python-pyyaml" ,python-pyyaml)))
5721 (home-page "https://github.com/ua-parser/uap-python")
5722 (synopsis "User agent parser")
5724 "@code{ua-parser} is a Python port of Browserscope's user agent parser.")
5725 (license license:asl2.0)))
5727 (define-public python2-ua-parser
5728 (package-with-python2 python-ua-parser))
5730 (define-public python-user-agents
5732 (name "python-user-agents")
5737 (uri (pypi-uri "user-agents" version))
5740 "0fc00cd3j8dahq1zzn8pkgfgd7lq37bp2scmdma2n1c049vicgb4"))))
5741 (build-system python-build-system)
5743 `(#:tests? #f)) ;missing devices.json test file in release
5745 `(("python-ua-parser" ,python-ua-parser)))
5746 (home-page "https://github.com/selwin/python-user-agents")
5747 (synopsis "User Agent strings parsing library")
5749 "A library to identify devices (phones, tablets) and their capabilities by
5750 parsing (browser/HTTP) user agent strings.")
5751 (license license:expat)))
5753 (define-public python2-user-agents
5754 (package-with-python2 python-user-agents))
5756 (define-public python-dbus
5758 (name "python-dbus")
5763 (uri (string-append "https://dbus.freedesktop.org/releases/dbus-python/"
5764 "dbus-python-" version ".tar.gz"))
5766 (base32 "0cdchkgnivlka4lf8q4qfk0yxq483i3r3aqickjf8hfn7nx0c0mi"))))
5767 (build-system gnu-build-system)
5769 `(("pkg-config" ,pkg-config)))
5771 `(("python" ,python-wrapper)
5772 ("dbus-glib" ,dbus-glib)))
5773 (synopsis "Python bindings for D-bus")
5774 (description "python-dbus provides bindings for libdbus, the reference
5775 implementation of D-Bus.")
5776 (home-page "https://www.freedesktop.org/wiki/Software/DBusBindings/")
5777 (license license:expat)))
5779 (define-public python2-dbus
5780 (package (inherit python-dbus)
5781 (name "python2-dbus")
5782 (inputs `(("python" ,python-2)
5783 ,@(alist-delete "python"
5784 (package-inputs python-dbus)
5787 (define-public python-notify2
5789 (name "python-notify2")
5794 (uri (pypi-uri "notify2" version))
5797 "0z8rrv9rsg1r2qgh2dxj3dfj5xnki98kgi3w839kqby4a26i1yik"))))
5798 (build-system python-build-system)
5799 (arguments `(#:tests? #f)) ; tests depend on system state
5801 `(("python-dbus" ,python-dbus)))
5802 (home-page "https://bitbucket.org/takluyver/pynotify2")
5803 (synopsis "Python interface to D-Bus notifications")
5805 "Pynotify2 provides a Python interface for sending D-Bus notifications.
5806 It is a reimplementation of pynotify in pure Python, and an alternative to
5807 the GObject Introspection bindings to libnotify for non-GTK applications.")
5808 (license (list license:bsd-2
5809 license:lgpl2.1+))))
5811 (define-public python2-notify2
5812 (package-with-python2 python-notify2))
5814 ;; beautifulsoup4 has a totally different namespace than 3.x,
5815 ;; and pypi seems to put it under its own name, so I guess we should too
5816 (define-public python-beautifulsoup4
5818 (name "python-beautifulsoup4")
5823 (uri (pypi-uri "beautifulsoup4" version))
5826 "0j2kycz2dxgx68xzjm7rxg5xn6v61gq5ifvxyg99slmqkybnal4l"))))
5827 (build-system python-build-system)
5830 (modify-phases %standard-phases
5831 ;; The Python 2 source is the definitive source of beautifulsoup4. We
5832 ;; must use this conversion script when building with Python 3. The
5833 ;; conversion script also runs the tests.
5834 ;; For more information, see the file 'convert-py3k' in the source
5837 (lambda _ (invoke "./convert-py3k"))))))
5839 `(("python-soupsieve" ,python-soupsieve)))
5841 "https://www.crummy.com/software/BeautifulSoup/bs4/")
5843 "Python screen-scraping library")
5845 "Beautiful Soup is a Python library designed for rapidly setting up
5846 screen-scraping projects. It offers Pythonic idioms for navigating,
5847 searching, and modifying a parse tree, providing a toolkit for
5848 dissecting a document and extracting what you need. It automatically
5849 converts incoming documents to Unicode and outgoing documents to UTF-8.")
5850 (license license:expat)
5851 (properties `((python2-variant . ,(delay python2-beautifulsoup4))))))
5853 (define-public python2-beautifulsoup4
5855 (inherit (package-with-python2
5856 (strip-python2-variant python-beautifulsoup4)))
5857 (arguments `(#:python ,python-2))))
5859 (define-public python-soupsieve
5861 (name "python-soupsieve")
5866 (uri (pypi-uri "soupsieve" version))
5869 "1nhd0q0ifwva9wn645s6pn74p1rd97asn3qfg75nphx1wkgcbhg2"))))
5870 (build-system python-build-system)
5871 (arguments `(#:tests? #f))
5872 ;;XXX: 2 tests fail currently despite claming they were to be
5873 ;;skipped. Also, beautifulsoup4 may depend on this in the future, so we
5874 ;;don't want to create a circular dependency.
5875 (home-page "https://github.com/facelessuser/soupsieve")
5876 (synopsis "CSS selector library")
5878 "Soup Sieve is a CSS selector library designed to be used with Beautiful
5879 Soup 4. It aims to provide selecting, matching, and filtering using modern
5880 CSS selectors. Soup Sieve currently provides selectors from the CSS level 1
5881 specifications up through the latest CSS level 4 drafts and beyond (though
5882 some are not yet implemented).")
5883 (properties `((python2-variant . ,(delay python2-soupsieve))))
5884 (license license:expat)))
5886 (define-public python2-soupsieve
5887 (let ((base (package-with-python2 (strip-python2-variant python-soupsieve))))
5891 `(("python2-backports-functools-lru-cache"
5892 ,python2-backports-functools-lru-cache)
5893 ,@(package-propagated-inputs base))))))
5895 (define-public python-netifaces
5897 (name "python-netifaces")
5902 (uri (pypi-uri "netifaces" version))
5905 "1gccklrcplbbqh81g1mdgpa5y8na7kkf29cq2ka3f5a2fp5hyndx"))))
5906 (build-system python-build-system)
5907 (home-page "https://github.com/al45tair/netifaces")
5909 "Python module for portable network interface information")
5911 "Netifaces is a Python module providing information on network
5912 interfaces in an easy and portable manner.")
5913 (license license:expat)))
5915 (define-public python2-netifaces
5916 (package-with-python2 python-netifaces))
5918 (define-public python-networkx
5920 (name "python-networkx")
5925 (uri (pypi-uri "networkx" version ".zip"))
5927 (base32 "12swxb15299v9vqjsq4z8rgh5sdhvpx497xwnhpnb0gynrx6zra5"))))
5928 (build-system python-build-system)
5929 ;; python-decorator is needed at runtime.
5931 `(("python-decorator" ,python-decorator)))
5933 `(("python-nose" ,python-nose)
5935 (home-page "https://networkx.github.io/")
5936 (synopsis "Python module for creating and manipulating graphs and networks")
5938 "NetworkX is a Python package for the creation, manipulation, and study
5939 of the structure, dynamics, and functions of complex networks.")
5940 (license license:bsd-3)))
5942 (define-public python2-networkx
5943 (package-with-python2 python-networkx))
5945 (define-public python-datrie
5947 (name "python-datrie")
5952 (uri (pypi-uri "datrie" version))
5955 "0338r8xgmpy78556jhms0h6qkvyjr10p8bpgdvcpqzm9lrmxmmdx"))))
5956 (build-system python-build-system)
5958 `(("python-cython" ,python-cython)
5959 ("python-hypothesis" ,python-hypothesis)
5960 ("python-pytest" ,python-pytest)
5961 ("python-pytest-runner" ,python-pytest-runner)))
5962 (home-page "https://github.com/kmike/datrie")
5963 (synopsis "Fast, efficiently stored trie for Python")
5965 "This package provides a fast, efficiently stored trie implementation for
5967 (license license:lgpl2.1+)))
5969 (define-public snakemake
5976 (uri (pypi-uri "snakemake" version))
5978 (base32 "1pnpvvn8n2a78cg360wz3ldmpqrsm2wzi0c0dmvki9fnsw6fxdas"))))
5979 (build-system python-build-system)
5981 ;; TODO: Package missing test dependencies.
5984 (modify-phases %standard-phases
5985 ;; For cluster execution Snakemake will call Python. Since there is
5986 ;; no suitable PYTHONPATH set, cluster execution will fail. We fix
5987 ;; this by calling the snakemake wrapper instead.
5988 (add-after 'unpack 'call-wrapper-not-wrapped-snakemake
5989 (lambda* (#:key outputs #:allow-other-keys)
5990 (substitute* "snakemake/executors.py"
5991 (("\\{sys.executable\\} -m snakemake")
5992 (string-append (assoc-ref outputs "out")
5996 `(("python-appdirs" ,python-appdirs)
5997 ("python-configargparse" ,python-configargparse)
5998 ("python-datrie" ,python-datrie)
5999 ("python-docutils" ,python-docutils)
6000 ("python-gitpython" ,python-gitpython)
6001 ("python-jinja2" ,python-jinja2)
6002 ("python-jsonschema" ,python-jsonschema)
6003 ("python-networkx" ,python-networkx)
6004 ("python-psutil" ,python-psutil)
6005 ("python-pyyaml" ,python-pyyaml)
6006 ("python-ratelimiter" ,python-ratelimiter)
6007 ("python-requests" ,python-requests)
6008 ("python-wrapt" ,python-wrapt)))
6009 (home-page "https://snakemake.readthedocs.io")
6010 (synopsis "Python-based execution environment for make-like workflows")
6012 "Snakemake aims to reduce the complexity of creating workflows by
6013 providing a clean and modern domain specific specification language (DSL) in
6014 Python style, together with a fast and comfortable execution environment.")
6015 (license license:expat)))
6017 (define-public python-pyqrcode
6019 (name "python-pyqrcode")
6024 (uri (pypi-uri "PyQRCode" version))
6027 "1m9ln8k9v7dfbh1i81225hx5mdsh8mpf9g7r4wpbfmiyfcs7dgzx"))))
6028 (build-system python-build-system)
6030 "https://github.com/mnooner256/pyqrcode")
6031 (synopsis "QR code generator")
6033 "Pyqrcode is a QR code generator written purely in Python with
6034 SVG, EPS, PNG and terminal output.")
6035 (license license:bsd-3)))
6037 (define-public python-seaborn
6039 (name "python-seaborn")
6044 (uri (pypi-uri "seaborn" version))
6046 (base32 "0bqysi3fxfjl1866m5jq8z7mynhqbqnikim74dmzn8539iwkzj3n"))
6050 ;; This has already been merged, but there is no new
6051 ;; release including this patch. It fixes problems
6052 ;; with axis rotation that would lead to test
6054 (uri "https://patch-diff.githubusercontent.com/raw/mwaskom/seaborn/pull/1716.diff")
6057 "1lm870z316n9ivsyr86hpk1gxaraw0mrjvq42lqsm0znhjdp9q9w"))
6058 (file-name "seaborn-0.9.0-axis-rotation.patch"))))))
6059 (build-system python-build-system)
6062 (modify-phases %standard-phases
6063 (add-before 'check 'start-xserver
6064 (lambda* (#:key inputs #:allow-other-keys)
6065 (let ((xorg-server (assoc-ref inputs "xorg-server")))
6066 ;; There must be a running X server and make check doesn't
6067 ;; start one. Therefore we must do it.
6068 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
6069 (setenv "DISPLAY" ":1")
6071 (add-after 'unpack 'fix-tests
6073 ;; test_cbar_ticks fails probably because of matplotlib's
6074 ;; expectation of using an older version of FreeType.
6075 (delete-file "seaborn/tests/test_matrix.py")
6077 (replace 'check (lambda _ (invoke "pytest" "seaborn") #t)))))
6079 `(("python-pandas" ,python-pandas)
6080 ("python-matplotlib" ,python-matplotlib)
6081 ("python-numpy" ,python-numpy)
6082 ("python-scipy" ,python-scipy)))
6084 `(("python-pytest" ,python-pytest)
6085 ("xorg-server" ,xorg-server-for-tests)))
6086 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
6087 (synopsis "Statistical data visualization")
6089 "Seaborn is a library for making attractive and informative statistical
6090 graphics in Python. It is built on top of matplotlib and tightly integrated
6091 with the PyData stack, including support for numpy and pandas data structures
6092 and statistical routines from scipy and statsmodels.")
6093 (license license:bsd-3)))
6095 (define-public python2-seaborn
6096 (package-with-python2 python-seaborn))
6098 (define-public python-mpmath
6100 (name "python-mpmath")
6104 (uri (string-append "http://mpmath.org/files/mpmath-"
6108 "08ijsr4ifrqv3cjc26mkw0dbvyygsa99in376hr4b96ddm1gdpb8"))))
6109 (build-system python-build-system)
6112 (modify-phases %standard-phases
6115 (invoke "python" "mpmath/tests/runtests.py" "-local"))))))
6116 (home-page "http://mpmath.org")
6117 (synopsis "Arbitrary-precision floating-point arithmetic in python")
6119 "@code{mpmath} can be used as an arbitrary-precision substitute for
6120 Python's float/complex types and math/cmath modules, but also does much
6121 more advanced mathematics.")
6122 (license license:bsd-3)))
6124 (define-public python2-mpmath
6125 (package-with-python2 python-mpmath))
6127 (define-public python-bigfloat
6129 (name "python-bigfloat")
6134 (uri (pypi-uri "bigfloat" version))
6136 (base32 "0xd7q4l7v0f463diznjv4k9wlaks80pn9drdqmfifi7zx8qvybi6"))))
6137 (build-system python-build-system)
6140 (home-page "https://github.com/mdickinson/bigfloat")
6141 (synopsis "Arbitrary precision floating-point arithmetic for Python")
6143 "This package provides a Python interface to the MPFR library for
6144 multiprecision arithmetic.")
6145 (license license:lgpl3+)))
6147 (define-public python2-bigfloat
6148 (package-with-python2 python-bigfloat))
6150 (define-public python-sympy
6152 (name "python-sympy")
6158 "https://github.com/sympy/sympy/releases/download/sympy-"
6159 version "/sympy-" version ".tar.gz"))
6161 (base32 "190n29sppw7g8ihilc5451y7jlfcaw56crqiqbf1jff43dlmfnxc"))))
6162 (build-system python-build-system)
6165 (modify-phases %standard-phases
6166 ;; Run the core tests after installation. By default it would run
6167 ;; *all* tests, which take a very long time to complete and are known
6170 (add-after 'install 'check
6171 (lambda* (#:key outputs #:allow-other-keys)
6172 (invoke "python3" "-c" "import sympy; sympy.test(\"/core\")")
6175 `(("python-mpmath" ,python-mpmath)))
6176 (home-page "http://www.sympy.org/")
6177 (synopsis "Python library for symbolic mathematics")
6179 "SymPy is a Python library for symbolic mathematics. It aims to become a
6180 full-featured computer algebra system (CAS) while keeping the code as simple
6181 as possible in order to be comprehensible and easily extensible.")
6182 (license license:bsd-3)))
6184 (define-public python2-sympy
6186 (inherit (package-with-python2 python-sympy))
6189 (modify-phases %standard-phases
6190 ;; Run the core tests after installation. By default it would run
6191 ;; *all* tests, which take a very long time to complete and are known
6194 (add-after 'install 'check
6195 (lambda* (#:key outputs #:allow-other-keys)
6196 (invoke "python" "-c" "import sympy; sympy.test(\"/core\")")
6199 (define-public python-q
6206 (uri (pypi-uri "q" version))
6209 "1mgfazh8fkizh6walra2zv885f3lcgr3nb02v1frfm4p8ddcy3yy"))))
6210 (build-system python-build-system)
6211 (home-page "https://github.com/zestyping/q")
6212 (synopsis "Quick-and-dirty debugging output for tired programmers")
6214 "q is a Python module for \"print\" style of debugging Python code. It
6215 provides convenient short API for print out of values, tracebacks, and
6216 falling into the Python interpreter.")
6217 (license license:asl2.0)))
6219 (define-public python2-q
6220 (package-with-python2 python-q))
6222 (define-public python2-xlib
6224 (name "python2-xlib")
6228 (uri (string-append "mirror://sourceforge/python-xlib/python-xlib"
6230 "python-xlib-" version ".tar.gz"))
6233 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
6234 (build-system python-build-system)
6236 `(#:python ,python-2 ;Python 2 only
6237 #:tests? #f)) ;no tests
6238 (home-page "http://python-xlib.sourceforge.net/")
6239 (synopsis "Python X11 client library")
6241 "The Python X Library is intended to be a fully functional X client
6242 library for Python programs. It is useful to implement low-level X clients.
6243 It is written entirely in Python.")
6244 (license license:gpl2+)))
6246 (define-public python-singledispatch
6248 (name "python-singledispatch")
6253 (uri (pypi-uri "singledispatch" version))
6256 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
6257 (build-system python-build-system)
6259 `(("python-six" ,python-six))) ; required for conversion, not at run-time
6261 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
6262 (synopsis "Backport of singledispatch feature from Python 3.4")
6264 "This library brings functools.singledispatch from Python 3.4 to Python
6266 (license license:expat)))
6268 (define-public python2-singledispatch
6269 (package-with-python2 python-singledispatch))
6271 ;; the python- version can be removed with python-3.5
6272 (define-public python-backports-abc
6274 (name "python-backports-abc")
6279 (uri (pypi-uri "backports_abc" version))
6282 "1pkv8d1zxj5f9i227dxbjczncbv7ks7ywnjwyxfjagm02i2yafq3"))))
6283 (build-system python-build-system)
6284 (home-page "https://github.com/cython/backports_abc")
6285 (synopsis "Backport of additions to the 'collections.abc' module")
6287 "Python-backports-abc provides a backport of additions to the
6288 @code{collections.abc} module in Python-3.5.")
6289 (license license:psfl)))
6291 (define-public python2-backports-abc
6292 (package-with-python2 python-backports-abc))
6294 (define-public python-backports-csv
6296 (name "python-backports-csv")
6301 (uri (pypi-uri "backports.csv" version))
6304 "1imzbrradkfn8s2m1qcimyn74dn1mz2p3j381jljn166rf2i6hlc"))))
6305 (build-system python-build-system)
6306 (home-page "https://github.com/ryanhiebert/backports.csv")
6307 (synopsis "Backport of Python 3's csv module for Python 2")
6309 "Provides a backport of Python 3's @code{csv} module for parsing
6310 comma separated values. The API of the @code{csv} module in Python 2
6311 is drastically different from the @code{csv} module in Python 3.
6312 This is due, for the most part, to the difference between str in
6313 Python 2 and Python 3.")
6314 (license license:psfl)))
6316 (define-public python2-backports-csv
6317 (package-with-python2 python-backports-csv))
6319 (define-public python2-backports-shutil-get-terminal-size
6321 (name "python2-backports-shutil-get-terminal-size")
6326 (uri (pypi-uri "backports.shutil_get_terminal_size" version))
6329 "107cmn7g3jnbkp826zlj8rrj19fam301qvaqf0f3905f5217lgki"))))
6330 (build-system python-build-system)
6332 `(#:python ,python-2
6334 (modify-phases %standard-phases
6337 (invoke "py.test" "-v"))))))
6339 `(("python2-pytest" ,python2-pytest)))
6340 (home-page "https://github.com/chrippa/backports.shutil_get_terminal_size")
6341 (synopsis "Backport of Python 3.3's @code{shutil.get_terminal_size}")
6343 "This package provides a backport of the @code{get_terminal_size
6344 function} from Python 3.3's @code{shutil}.
6345 Unlike the original version it is written in pure Python rather than C,
6346 so it might be a tiny bit slower.")
6347 (license license:expat)))
6349 (define-public python-waf
6355 (uri (string-append "https://waf.io/"
6356 "waf-" version ".tar.bz2"))
6359 "19dvqbsvxz7ch03dh1v0znklrwxlz6yzddc3k9smzrrgny4jch6q"))))
6360 (build-system python-build-system)
6363 (modify-phases %standard-phases
6366 ;; XXX: Find a way to add all extra tools.
6367 (let ((tools '("gccdeps"
6368 "clang_compilation_database")))
6369 (invoke "python" "waf-light" "configure" "build"
6370 (string-append "--tools="
6371 (string-join tools ","))))))
6374 (invoke "python" "waf" "--version")))
6376 (lambda* (#:key outputs #:allow-other-keys)
6377 (let ((out (assoc-ref outputs "out")))
6378 (install-file "waf" (string-append out "/bin")))
6380 ;; waf breaks when it is wrapped.
6382 (home-page "https://waf.io/")
6383 (synopsis "Python-based build system")
6385 "Waf is a Python-based framework for configuring, compiling and installing
6387 (license license:bsd-3)))
6389 (define-public python2-waf
6390 (package-with-python2 python-waf))
6392 (define-public python-pyzmq
6394 (name "python-pyzmq")
6399 (uri (pypi-uri "pyzmq" version))
6401 (base32 "1pyxxrz60f88ffm0y6vpbx3q8jcr9ybz8fcilihwzwhh36n84ax7"))))
6402 (build-system python-build-system)
6405 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
6406 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
6407 ;; --inplace' for 'python setup.py test' to work.
6410 `(("zeromq" ,zeromq)))
6412 `(("pkg-config" ,pkg-config)
6413 ("python-nose" ,python-nose)))
6414 (home-page "https://github.com/zeromq/pyzmq")
6415 (synopsis "Python bindings for 0MQ")
6417 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
6418 (license license:bsd-4)))
6420 (define-public python2-pyzmq
6421 (package-with-python2 python-pyzmq))
6423 (define-public python-pep8
6424 ;; This package has been renamed to ‘pycodestyle’ and is no longer updated.
6425 ;; Its last release (1.7.1) adds only a scary warning to this effect, breaking
6426 ;; some dependents' test suites, and nothing more.
6428 (name "python-pep8")
6433 (uri (pypi-uri "pep8" version))
6436 "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1"))
6437 (patches (search-patches "python-pep8-stdlib-tokenize-compat.patch"))))
6438 (build-system python-build-system)
6439 (home-page "https://pep8.readthedocs.org/")
6440 (synopsis "Python style guide checker")
6442 "This tools checks Python code against some of the style conventions in
6444 (license license:expat)))
6446 (define-public python2-pep8
6447 (package-with-python2 python-pep8))
6449 (define-public python-pyflakes
6451 (name "python-pyflakes")
6456 (uri (pypi-uri "pyflakes" version))
6459 "18pq95a1xj2dgdd0m85gyfsn40jajj4xc3lp8wfv7igqhrc86xnr"))))
6460 (build-system python-build-system)
6462 "https://github.com/pyflakes/pyflakes")
6463 (synopsis "Passive checker of Python programs")
6465 "Pyflakes statically checks Python source code for common errors.")
6466 (license license:expat)))
6468 (define-public python2-pyflakes
6469 (package-with-python2 python-pyflakes))
6471 (define-public python-mccabe
6473 (name "python-mccabe")
6478 (uri (pypi-uri "mccabe" version))
6481 "07w3p1qm44hgxf3vvwz84kswpsx6s7kvaibzrsx5dzm0hli1i3fx"))))
6482 (build-system python-build-system)
6484 `(("python-pytest" ,python-pytest-bootstrap)
6485 ("python-pytest-runner" ,python-pytest-runner)))
6486 (home-page "https://github.com/flintwork/mccabe")
6487 (synopsis "McCabe checker, plugin for flake8")
6489 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
6490 complexity of Python source code.")
6491 (license license:expat)))
6493 (define-public python2-mccabe
6494 (package-with-python2 python-mccabe))
6496 (define-public python-mccabe-0.2.1
6497 (package (inherit python-mccabe)
6502 (uri (pypi-uri "mccabe" version))
6505 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))))
6507 (define-public python2-mccabe-0.2.1
6508 (package-with-python2 python-mccabe-0.2.1))
6510 ;; Flake8 2.4.1 requires an older version of pep8.
6511 ;; This should be removed ASAP.
6512 (define-public python-pep8-1.5.7
6513 (package (inherit python-pep8)
6518 (uri (pypi-uri "pep8" version))
6521 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))
6523 ;; XXX Tests not compatible with Python 3.5.
6526 (define-public python2-pep8-1.5.7
6527 (package-with-python2 python-pep8-1.5.7))
6529 ;; Flake8 2.4.1 requires an older version of pyflakes.
6530 ;; This should be removed ASAP.
6531 (define-public python-pyflakes-0.8.1
6532 (package (inherit python-pyflakes)
6537 (uri (pypi-uri "pyflakes" version))
6540 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))
6542 ;; XXX Tests not compatible with Python 3.5.
6545 (define-public python2-pyflakes-0.8.1
6546 (package-with-python2 python-pyflakes-0.8.1))
6548 (define-public python-flake8
6550 (name "python-flake8")
6554 (uri (pypi-uri "flake8" version))
6557 "0qg6zggqigrd4k3gv88shd1a27d0cwgfql8vfiq2c7rl7w3rd6c5"))))
6558 (build-system python-build-system)
6561 (modify-phases %standard-phases
6563 (add-after 'install 'check
6564 (lambda* (#:key inputs outputs #:allow-other-keys)
6565 (add-installed-pythonpath inputs outputs)
6566 (invoke "pytest" "-v")
6569 `(("python-pycodestyle" ,python-pycodestyle)
6570 ("python-entrypoints" ,python-entrypoints)
6571 ("python-pyflakes" ,python-pyflakes)
6572 ("python-mccabe" ,python-mccabe)))
6574 `(("python-mock" ,python-mock)
6575 ("python-pytest" ,python-pytest-bootstrap)
6576 ("python-pytest-runner" ,python-pytest-runner)))
6577 (home-page "https://gitlab.com/pycqa/flake8")
6579 "The modular source code checker: pep8, pyflakes and co")
6581 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
6582 (properties `((python2-variant . ,(delay python2-flake8))))
6583 (license license:expat)))
6585 (define-public python2-flake8
6586 (let ((base (package-with-python2 (strip-python2-variant python-flake8))))
6587 (package (inherit base)
6589 `(("python2-configparser" ,python2-configparser)
6590 ("python2-enum34" ,python2-enum34)
6591 ("python2-typing" ,python2-typing)
6592 ,@(package-propagated-inputs base))))))
6594 ;; python-hacking requires flake8 <2.6.0.
6595 (define-public python-flake8-2.5
6597 (inherit python-flake8)
6601 (uri (pypi-uri "flake8" version))
6604 "1snylqwbmrylbx3r1wpz8ggk98f6bcag4441ag8mm2l7wyn58sij"))))
6606 `(("python-pep8" ,python-pep8)
6607 ,@(package-propagated-inputs python-flake8)))
6608 (properties `((python2-variant . ,(delay python2-flake8-2.5))))))
6610 (define-public python2-flake8-2.5
6612 (inherit python2-flake8)
6613 (version (package-version python-flake8-2.5))
6615 (inherit (package-source python-flake8-2.5))))
6617 `(("python2-pep8" ,python2-pep8)
6618 ,@(package-propagated-inputs python2-flake8)))))
6620 (define-public python-flake8-polyfill
6622 (name "python-flake8-polyfill")
6627 (uri (pypi-uri "flake8-polyfill" version))
6630 "1nlf1mkqw856vi6782qcglqhaacb23khk9wkcgn55npnjxshhjz4"))))
6631 (build-system python-build-system)
6634 (modify-phases %standard-phases
6637 ;; Be compatible with Pytest 4:
6638 ;; https://gitlab.com/pycqa/flake8-polyfill/merge_requests/7
6639 (substitute* "setup.cfg"
6643 (setenv "PYTHONPATH"
6644 (string-append (getcwd) "/build/lib:"
6645 (getenv "PYTHONPATH")))
6646 (invoke "py.test" "-v"))))))
6648 `(("python-flake8" ,python-flake8)
6649 ("python-mock" ,python-mock)
6650 ("python-pep8" ,python-pep8)
6651 ("python-pycodestyle" ,python-pycodestyle)
6652 ("python-pytest" ,python-pytest)))
6653 (home-page "https://gitlab.com/pycqa/flake8-polyfill")
6654 (synopsis "Polyfill package for Flake8 plugins")
6656 "This package that provides some compatibility helpers for Flake8
6657 plugins that intend to support Flake8 2.x and 3.x simultaneously.")
6658 (license license:expat)))
6660 (define-public python2-flake8-polyfill
6661 (package-with-python2 python-flake8-polyfill))
6663 (define-public python-mistune
6665 (name "python-mistune")
6670 (uri (pypi-uri "mistune" version))
6673 "0vkmsh0x480rni51lhyvigfdf06b9247z868pk3bal1wnnfl58sr"))))
6674 (build-system python-build-system)
6676 `(("python-nose" ,python-nose)
6677 ("python-cython" ,python-cython)))
6678 (home-page "https://github.com/lepture/mistune")
6679 (synopsis "Markdown parser in pure Python")
6680 (description "This package provides a fast markdown parser in pure
6682 (license license:bsd-3)))
6684 (define-public python2-mistune
6685 (package-with-python2 python-mistune))
6687 (define-public python-markdown
6689 (name "python-markdown")
6694 (uri (pypi-uri "Markdown" version))
6697 "0yhylk4ffqqs7x086fav4pnfsl1021v7lghznzkififprmmqfl1f"))))
6698 (build-system python-build-system)
6700 `(("python-nose" ,python-nose)
6701 ("python-pyyaml" ,python-pyyaml)))
6702 (home-page "https://python-markdown.github.io/")
6703 (synopsis "Python implementation of Markdown")
6705 "This package provides a Python implementation of John Gruber's
6706 Markdown. The library features international input, various Markdown
6707 extensions, and several HTML output formats. A command line wrapper
6708 markdown_py is also provided to convert Markdown files to HTML.")
6709 (license license:bsd-3)))
6711 (define-public python2-markdown
6712 (package-with-python2 python-markdown))
6714 (define-public python-ptyprocess
6716 (name "python-ptyprocess")
6721 (uri (pypi-uri "ptyprocess" version))
6724 "0ra31k10v3629xq0kdn8lwmfbi97anmk48r03yvh7mks0kq96hg6"))))
6725 (build-system python-build-system)
6727 `(("python-nose" ,python-nose)))
6730 (modify-phases %standard-phases
6732 (lambda _ (invoke "nosetests"))))))
6733 (home-page "https://github.com/pexpect/ptyprocess")
6734 (synopsis "Run a subprocess in a pseudo terminal")
6736 "This package provides a Python library used to launch a subprocess in a
6737 pseudo terminal (pty), and interact with both the process and its pty.")
6738 (license license:isc)))
6740 (define-public python2-ptyprocess
6741 (package-with-python2 python-ptyprocess))
6743 (define-public python-cram
6745 (name "python-cram")
6747 (home-page "https://bitheap.org/cram/")
6750 (uri (list (string-append home-page "cram-"
6752 (pypi-uri "cram" version)))
6755 "0bvz6fwdi55rkrz3f50zsy35gvvwhlppki2yml5bj5ffy9d499vx"))))
6758 (modify-phases %standard-phases
6759 (add-after 'unpack 'patch-source
6761 (substitute* (find-files "cram" ".*\\.py$")
6762 ;; Replace default shell path.
6763 (("/bin/sh") (which "sh")))
6764 (substitute* (find-files "tests" ".*\\.t$")
6766 (("/bin/bash") (which "bash"))
6767 (("/bin/sh") (which "sh")))
6768 (substitute* "cram/_test.py"
6769 ;; This hack works around a bug triggered by substituting
6770 ;; the /bin/sh paths. "tests/usage.t" compares the output of
6771 ;; "cram -h", which breaks the output at 80 characters. This
6772 ;; causes the line showing the default shell to break into two
6773 ;; lines, but the test expects a single line...
6774 (("env\\['COLUMNS'\\] = '80'")
6775 "env['COLUMNS'] = '160'"))
6777 (substitute* "Makefile"
6778 ;; Recent versions of python-coverage have caused the test
6779 ;; coverage to decrease (as of version 0.7). Allow that.
6780 (("--fail-under=100")
6785 ;; The test phase uses the built library and executable.
6786 (lambda* (#:key inputs outputs #:allow-other-keys)
6787 (add-installed-pythonpath inputs outputs)
6788 (setenv "PATH" (string-append (getenv "PATH") ":"
6789 (assoc-ref outputs "out") "/bin"))
6790 (invoke "make" "test"))))))
6791 (build-system python-build-system)
6793 `(("python-coverage" ,python-coverage)
6795 (synopsis "Simple testing framework for command line applications")
6797 "Cram is a functional testing framework for command line applications.
6798 Cram tests look like snippets of interactive shell sessions. Cram runs each
6799 command and compares the command output in the test with the command’s actual
6801 (license license:gpl2+)))
6803 (define-public python2-cram
6804 (package-with-python2 python-cram))
6806 (define-public python-straight-plugin
6808 (name "python-straight-plugin")
6813 (uri (pypi-uri "straight.plugin" version))
6816 "069pjll4383p4kkgvcc40hgyvf79j2wdbpgwz77yigzxksh1gj62"))))
6817 (build-system python-build-system)
6818 (home-page "https://github.com/ironfroggy/straight.plugin")
6819 (synopsis "Simple namespaced plugin facility")
6820 (description "Straight Plugin provides a type of plugin you can create from
6821 almost any existing Python modules, and an easy way for outside developers to
6822 add functionality and customization to your projects with their own plugins.")
6823 (license license:expat)))
6825 (define-public python2-straight-plugin
6826 (package-with-python2 python-straight-plugin))
6828 (define-public python-fonttools
6830 (name "python-fonttools")
6834 (uri (pypi-uri "fonttools" version ".zip"))
6837 "012qqspnwdl4vy8qgzzpfglkk5dgzxiw0fak2jq74ngygvz3vfv6"))))
6838 (build-system python-build-system)
6841 ("python-pytest" ,python-pytest)
6842 ("python-pytest-runner" ,python-pytest-runner)))
6843 (home-page "https://github.com/fonttools/fonttools")
6844 (synopsis "Tools to manipulate font files")
6846 "FontTools/TTX is a library to manipulate font files from Python. It
6847 supports reading and writing of TrueType/OpenType fonts, reading and writing
6848 of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
6849 also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
6850 from an XML-based format.")
6851 (license license:expat)))
6853 ;; Fonttools 4.x dropped support for Python 2, so stick with 3.x here.
6854 (define-public python2-fonttools
6855 (let ((base (package-with-python2 (strip-python2-variant python-fonttools))))
6861 (uri (pypi-uri "fonttools" version ".zip"))
6864 "0v6399g755f2hn1ry62i5b6gdinf2fpx2966v3bxh6bjw1accb5p")))))))
6866 (define-public python-ly
6873 (uri (pypi-uri name version))
6876 "0x98dv7p8mg26p4816yy8hz4f34zf6hpnnfmr56msgh9jnsm2qfl"))))
6877 (build-system python-build-system)
6879 ;; FIXME: Some tests need network access.
6881 (synopsis "Tool and library for manipulating LilyPond files")
6882 (description "This package provides a Python library to parse, manipulate
6883 or create documents in LilyPond format. A command line program ly is also
6884 provided that can be used to do various manipulations with LilyPond files.")
6885 (home-page "https://pypi.python.org/pypi/python-ly")
6886 (license license:gpl2+)))
6888 (define-public python-appdirs
6890 (name "python-appdirs")
6895 (uri (pypi-uri "appdirs" version))
6898 "14id6wxi12lgyw0mg3bcfnf888ad07jz9yj46gfzhn186z8rcn4y"))))
6899 (build-system python-build-system)
6900 (home-page "https://github.com/ActiveState/appdirs")
6902 "Determine platform-specific dirs, e.g. a \"user data dir\"")
6904 "This module provides a portable way of finding out where user data
6905 should be stored on various operating systems.")
6906 (license license:expat)))
6908 (define-public python2-appdirs
6909 (package-with-python2 python-appdirs))
6911 (define-public python-llfuse
6913 (name "python-llfuse")
6917 (uri (pypi-uri "llfuse" version ".tar.bz2"))
6920 "1n7a90jww3ly49fm7x27m3xw3la3qfrnykcakga654g6kcyjlhbf"))))
6921 (build-system python-build-system)
6926 `(("pkg-config" ,pkg-config)))
6927 (synopsis "Python bindings for FUSE")
6929 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
6930 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
6931 (license license:lgpl2.0+)
6932 (properties `((python2-variant . ,(delay python2-llfuse))))))
6934 (define-public python2-llfuse
6935 (package (inherit (package-with-python2
6936 (strip-python2-variant python-llfuse)))
6937 (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2)))))
6940 (define-public python-llfuse-0.41
6941 (package (inherit python-llfuse)
6946 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
6947 "llfuse-" version ".tar.bz2"))
6950 "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa"))))
6951 ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat)
6952 ;; licensed. The rest of the package is licensed under LGPL2.0 or later.
6953 (license (list license:expat license:lgpl2.0+))))
6955 (define-public python-msgpack
6957 (name "python-msgpack")
6961 (uri (pypi-uri "msgpack" version))
6964 "1hz2dba1nvvn52afg34liijsm7kn65cmn06dl0xbwld6bb4cis0f"))))
6965 (build-system python-build-system)
6967 `(#:modules ((guix build utils)
6968 (guix build python-build-system)
6973 (modify-phases %standard-phases
6976 (let ((cwd (getcwd)))
6977 (setenv "PYTHONPATH"
6978 (string-append cwd "/build/"
6979 (find (cut string-prefix? "lib" <>)
6980 (scandir (string-append cwd "/build")))
6982 (getenv "PYTHONPATH")))
6983 (invoke "pytest" "-v" "test")))))))
6985 `(("python-pytest" ,python-pytest)))
6986 (synopsis "MessagePack (de)serializer")
6987 (description "MessagePack is a fast, compact binary serialization format,
6988 suitable for similar data to JSON. This package provides CPython bindings for
6989 reading and writing MessagePack data.")
6990 (home-page "https://pypi.python.org/pypi/msgpack/")
6991 (license license:asl2.0)))
6993 ;; This msgpack library's name changed from "python-msgpack" to "msgpack" with
6994 ;; release 0.5. Some packages like borg still call it by the old name for now.
6995 ;; <https://bugs.gnu.org/30662>
6996 (define-public python-msgpack-transitional
6998 (inherit python-msgpack)
6999 (name "python-msgpack-transitional")
7001 (substitute-keyword-arguments (package-arguments python-msgpack)
7003 `(modify-phases ,phases
7004 (add-after 'unpack 'configure-transitional
7006 ;; Keep using the old name.
7007 (substitute* "setup.py"
7008 (("TRANSITIONAL = False")
7009 "TRANSITIONAL = 1"))
7012 (define-public python2-msgpack
7013 (package-with-python2 python-msgpack))
7015 (define-public python-netaddr
7017 (name "python-netaddr")
7022 (uri (pypi-uri "netaddr" version))
7025 "1zdfadvpq4lmcqzr383gywxn4xyn355kj1n3lk9q2l03vmyfrbiq"))))
7026 (build-system python-build-system)
7027 (arguments `(#:tests? #f)) ;; No tests.
7028 (home-page "https://github.com/drkjam/netaddr/")
7029 (synopsis "Pythonic manipulation of network addresses")
7031 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
7032 and MAC network addresses.")
7033 (license license:bsd-3)))
7035 (define-public python2-netaddr
7036 (package-with-python2 python-netaddr))
7038 (define-public python2-pyroute2
7040 (name "python2-pyroute2")
7045 (uri (pypi-uri "pyroute2" version))
7048 "1gmz4r1w0yzj6fjjypnalmfyy0lnfznydyn62gi3wk50j5hhxbny"))))
7049 (build-system python-build-system)
7051 `(#:python ,python-2)) ;Python 3.x is not supported
7052 (home-page "https://github.com/svinota/pyroute2")
7053 (synopsis "Python netlink library")
7055 "Pyroute2 is a pure Python netlink library with minimal dependencies.
7056 Supported netlink families and protocols include:
7058 @item rtnl, network settings - addresses, routes, traffic controls
7059 @item nfnetlink - netfilter API: ipset, nftables, ...
7060 @item ipq - simplest userspace packet filtering, iptables QUEUE target
7061 @item devlink - manage and monitor devlink-enabled hardware
7062 @item generic - generic netlink families
7064 @item nl80211 - wireless functions API (basic support)
7065 @item taskstats - extended process statistics
7066 @item acpi_events - ACPI events monitoring
7067 @item thermal_events - thermal events monitoring
7068 @item VFS_DQUOT - disk quota events monitoring
7071 (license license:gpl2+)))
7073 (define-public python-wrapt
7075 (name "python-wrapt")
7080 (uri (pypi-uri "wrapt" version))
7083 "1q81762dgsgrd12f8qc39zk8s5wll3m5xc32jdmlf6cls4gh4njn"))))
7084 (build-system python-build-system)
7086 ;; Tests are not included in the tarball, they are only available in the
7089 (home-page "https://github.com/GrahamDumpleton/wrapt")
7090 (synopsis "Module for decorators, wrappers and monkey patching")
7092 "The aim of the wrapt module is to provide a transparent object proxy for
7093 Python, which can be used as the basis for the construction of function
7094 wrappers and decorator functions.")
7095 (license license:bsd-2)))
7097 (define-public python2-wrapt
7098 (package-with-python2 python-wrapt))
7100 (define-public python-xlrd
7102 (name "python-xlrd")
7106 (uri (pypi-uri "xlrd" version))
7109 "1ci93fda4n67qhdvfl16zasyxrpygzk53hs6m8z0rd4dxrnb6vjl"))))
7110 (build-system python-build-system)
7113 (modify-phases %standard-phases
7114 ;; Some tests depend on writing a temporary file to the user's home
7116 (add-after 'unpack 'fix-tests
7118 (delete-file "tests/test_open_workbook.py")
7120 (home-page "http://www.python-excel.org/")
7121 (synopsis "Library for extracting data from Excel files")
7122 (description "This package provides a library to extract data from
7123 spreadsheets using Microsoft Excel proprietary file formats @samp{.xls} and
7124 @samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
7125 Unicode-aware. It is not intended as an end-user tool.")
7126 (license license:bsd-3)))
7128 (define-public python2-xlrd
7129 (package-with-python2 python-xlrd))
7131 (define-public python-prettytable
7133 (name "python-prettytable")
7138 (uri (pypi-uri "prettytable" version ".tar.bz2"))
7141 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
7142 (build-system python-build-system)
7143 (home-page "http://code.google.com/p/prettytable/")
7144 (synopsis "Display tabular data in an ASCII table format")
7146 "A library designed to represent tabular data in visually appealing ASCII
7147 tables. PrettyTable allows for selection of which columns are to be printed,
7148 independent alignment of columns (left or right justified or centred) and
7149 printing of sub-tables by specifying a row range.")
7150 (license license:bsd-3)))
7152 (define-public python2-prettytable
7153 (package-with-python2 python-prettytable))
7155 (define-public python-tables
7157 (name "python-tables")
7162 (uri (pypi-uri "tables" version))
7165 "0affz7k8babh8wdmsgrz5jxrd569by2w8ffimcxs9wiaf5rw1idx"))
7166 (modules '((guix build utils)))
7169 ;; Remove pre-compiled .pyc files from source.
7170 (for-each delete-file-recursively
7171 (find-files "." "__pycache__" #:directories? #t))
7172 (for-each delete-file (find-files "." "\\.pyc$"))
7174 (build-system python-build-system)
7176 `(;; FIXME: python-build-system does not pass configure-flags to "build"
7177 ;; or "check", so we must override the build and check phases.
7179 (modify-phases %standard-phases
7180 (add-after 'unpack 'use-gcc
7182 (substitute* "setup.py"
7183 (("compiler = new_compiler\\(\\)" line)
7185 "\ncompiler.set_executables(compiler='gcc',"
7186 "compiler_so='gcc',"
7188 "linker_so='gcc -shared')")))
7191 (lambda* (#:key inputs #:allow-other-keys)
7192 (invoke "python" "setup.py" "build"
7193 (string-append "--hdf5="
7194 (assoc-ref inputs "hdf5")))))
7196 (lambda* (#:key inputs #:allow-other-keys)
7197 (invoke "python" "setup.py" "check"
7198 (string-append "--hdf5="
7199 (assoc-ref inputs "hdf5"))))))))
7201 `(("python-numexpr" ,python-numexpr)
7202 ("python-numpy" ,python-numpy)))
7204 `(("python-cython" ,python-cython)
7205 ("pkg-config" ,pkg-config)))
7210 (home-page "http://www.pytables.org/")
7211 (synopsis "Hierarchical datasets for Python")
7212 (description "PyTables is a package for managing hierarchical datasets and
7213 designed to efficiently cope with extremely large amounts of data.")
7214 (license license:bsd-3)))
7216 (define-public python2-tables
7217 (package-with-python2 python-tables))
7219 (define-public python-pyasn1
7221 (name "python-pyasn1")
7226 (uri (pypi-uri "pyasn1" version))
7229 "1z5h38anjzzrxpraa9iq9llffyx2zs8gx0q6dc1g029miwnn50gv"))))
7230 (build-system python-build-system)
7231 (home-page "http://pyasn1.sourceforge.net/")
7232 (synopsis "ASN.1 types and codecs")
7234 "This is an implementation of ASN.1 types and codecs in Python. It is
7235 suitable for a wide range of protocols based on the ASN.1 specification.")
7236 (license license:bsd-2)))
7238 (define-public python2-pyasn1
7239 (package-with-python2 python-pyasn1))
7241 (define-public python-pyasn1-modules
7243 (name "python-pyasn1-modules")
7248 (uri (pypi-uri "pyasn1-modules" version))
7251 "0ivm850yi7ajjbi8j115qpsj95bgxdsx48nbjzg0zip788c3xkx0"))))
7252 (build-system python-build-system)
7254 `(("python-pyasn1" ,python-pyasn1)))
7255 (home-page "https://sourceforge.net/projects/pyasn1/")
7256 (synopsis "ASN.1 codec implementations")
7258 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
7259 implementations of ASN.1-based codecs and protocols.")
7260 (license license:bsd-3)))
7262 (define-public python2-pyasn1-modules
7263 (package-with-python2 python-pyasn1-modules))
7265 (define-public python-ipaddress
7267 (name "python-ipaddress")
7271 (uri (pypi-uri "ipaddress" version))
7274 "0b570bm6xqpjwqis15pvdy6lyvvzfndjvkynilcddjj5x98wfimi"))))
7275 (build-system python-build-system)
7276 (home-page "https://github.com/phihag/ipaddress")
7277 (synopsis "IP address manipulation library")
7279 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
7280 in Python. This library is used to create, poke at, and manipulate IPv4 and
7281 IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
7282 module to older versions of Python.")
7283 (license license:psfl)))
7285 (define-public python2-ipaddress
7286 (package-with-python2 python-ipaddress))
7288 (define-public python2-ipaddr
7290 (name "python2-ipaddr")
7295 (uri (pypi-uri "ipaddr" version))
7297 (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v"))))
7298 (build-system python-build-system)
7300 `(#:python ,python-2 ;version 2 only
7302 (modify-phases %standard-phases
7304 (lambda _ (invoke "python" "ipaddr_test.py"))))))
7305 (home-page "https://github.com/google/ipaddr-py")
7306 (synopsis "IP address manipulation library")
7308 "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and
7309 IPv6 addresses and networks.
7311 For new implementations you may prefer to use the standard module
7312 @code{ipaddress}, which was introduced in Python 3.3 and backported to older
7313 versions of Python.")
7314 (license license:asl2.0)))
7316 (define-public python-idna
7318 (name "python-idna")
7323 (uri (pypi-uri "idna" version))
7326 "01rlkigdxg17sf9yar1jl8n18ls59367wqh59hnawlyg53vb6my3"))))
7327 (build-system python-build-system)
7328 (home-page "https://github.com/kjd/idna")
7329 (synopsis "Internationalized domain names in applications")
7331 "This is a library to support the Internationalised Domain Names in
7332 Applications (IDNA) protocol as specified in RFC 5891. This version of the
7333 protocol is often referred to as “IDNA2008” and can produce different results
7334 from the earlier standard from 2003. The library is also intended to act as a
7335 suitable drop-in replacement for the “encodings.idna” module that comes with
7336 the Python standard library but currently only supports the older 2003
7338 (license license:bsd-4)))
7340 (define-public python-idna-2.7
7341 (package (inherit python-idna)
7345 (uri (pypi-uri "idna" version))
7348 "05jam7d31767dr12x0rbvvs8lxnpb1mhdb2zdlfxgh83z6k3hjk8"))))))
7351 (define-public python2-idna
7352 (package-with-python2 python-idna))
7354 (define-public python-idna-ssl
7356 (name "python-idna-ssl")
7361 (uri (pypi-uri "idna-ssl" version))
7364 "0ydrc8hpg9mdr5hqq1lqfsfbn6sjq69slwpfrnlrm3k0phqg14qj"))))
7365 (build-system python-build-system)
7367 `(#:tests? #f)) ;circular dependency with python-aiohttp
7368 (home-page "https://github.com/aio-libs/idna-ssl")
7369 (synopsis "Patch @code{ssl.match_hostname} for Unicode(idna) domains support")
7370 (description "Patch @code{ssl.match_hostname} for Unicode(idna)
7372 (license license:expat)))
7374 (define-public python-pretend
7376 (name "python-pretend")
7381 (uri (pypi-uri "pretend" version))
7384 "040vm94lcbscg5p81g1icmwwwa2jm7wrd1ybmxnv1sz8rl8bh3n9"))))
7385 (build-system python-build-system)
7386 (home-page "https://github.com/alex/pretend")
7387 (synopsis "Library for stubbing in Python")
7389 "Pretend is a library to make stubbing with Python easier. Stubbing is a
7390 technique for writing tests. You may hear the term mixed up with mocks,
7391 fakes, or doubles. Basically, a stub is an object that returns pre-canned
7392 responses, rather than doing any computation.")
7393 (license license:bsd-3)))
7395 (define-public python2-pretend
7396 (package-with-python2 python-pretend))
7398 (define-public python-pip
7405 (uri (pypi-uri "pip" version))
7408 "100sd12ss4mbdj5lf3wawad29cm573b27765mq098x6xhcj71395"))))
7409 (build-system python-build-system)
7411 '(#:tests? #f)) ; there are no tests in the pypi archive.
7412 (home-page "https://pip.pypa.io/")
7413 (synopsis "Package manager for Python software")
7415 "Pip is a package manager for Python software, that finds packages on the
7416 Python Package Index (PyPI).")
7417 (license license:expat)))
7419 (define-public python2-pip
7420 (package-with-python2 python-pip))
7422 (define-public python-tlsh
7424 (name "python-tlsh")
7426 (home-page "https://github.com/trendmicro/tlsh")
7431 (url "https://github.com/trendmicro/tlsh.git")
7432 (commit (string-append "v" version))))
7433 (file-name (git-file-name name version))
7435 (base32 "1ydliir308xn4ywy705mmsh7863ldlixdvpqwdhbipzq9vfpmvll"))))
7436 (build-system cmake-build-system)
7438 '(#:out-of-source? #f
7439 #:phases (modify-phases %standard-phases
7442 (lambda* (#:key outputs #:allow-other-keys)
7443 ;; Build and install the Python bindings. The underlying
7444 ;; C++ library is apparently not meant to be installed.
7445 (let ((out (assoc-ref outputs "out")))
7446 (with-directory-excursion "py_ext"
7447 (and (system* "python" "setup.py" "build")
7448 (system* "python" "setup.py" "install"
7449 (string-append "--prefix=" out))))))))))
7450 (inputs `(("python" ,python-wrapper))) ;for the bindings
7451 (synopsis "Fuzzy matching library for Python")
7453 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
7454 Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
7455 value which can be used for similarity comparisons. Similar objects have
7456 similar hash values, which allows for the detection of similar objects by
7457 comparing their hash values. The byte stream should have a sufficient amount
7458 of complexity; for example, a byte stream of identical bytes will not generate
7460 (license license:asl2.0)))
7462 (define-public python2-tlsh
7464 (inherit python-tlsh)
7465 (name "python2-tlsh")
7466 (inputs `(("python" ,python-2)))))
7468 (define-public python-termcolor
7470 (name "python-termcolor")
7475 (uri (pypi-uri "termcolor" version))
7478 "0fv1vq14rpqwgazxg4981904lfyp84mnammw7y046491cv76jv8x"))))
7479 (build-system python-build-system)
7481 ;; There are no tests.
7483 (home-page "https://pypi.python.org/pypi/termcolor")
7484 (synopsis "ANSII Color formatting for terminal output")
7486 "This package provides ANSII Color formatting for output in terminals.")
7487 (license license:expat)))
7489 (define-public python2-termcolor
7490 (package-with-python2 python-termcolor))
7492 (define-public python-libarchive-c
7494 (name "python-libarchive-c")
7498 (uri (pypi-uri "libarchive-c" version))
7501 "0qg0v1s9c1xdk9philhnv8k6c6nicvnvfwlc0j9srg90jmdlvm06"))))
7502 (build-system python-build-system)
7504 '(#:phases (modify-phases %standard-phases
7506 'build 'reference-libarchive
7507 (lambda* (#:key inputs #:allow-other-keys)
7508 ;; Retain the absolute file name of libarchive.so.
7509 (let ((libarchive (assoc-ref inputs "libarchive")))
7510 (substitute* "libarchive/ffi.py"
7511 (("find_library\\('archive'\\)")
7512 (string-append "'" libarchive
7513 "/lib/libarchive.so'"))))))
7515 (lambda _ (invoke "pytest" "-vv"))))))
7517 `(("python-mock" ,python-mock)
7518 ("python-pytest" ,python-pytest)))
7520 `(("libarchive" ,libarchive)))
7521 (home-page "https://github.com/Changaco/python-libarchive-c")
7522 (synopsis "Python interface to libarchive")
7524 "This package provides Python bindings to libarchive, a C library to
7525 access possibly compressed archives in many different formats. It uses
7526 Python's @code{ctypes} foreign function interface (FFI).")
7527 (license license:lgpl2.0+)))
7529 (define-public python2-libarchive-c
7530 (package-with-python2 python-libarchive-c))
7532 (define-public python-file
7535 (name "python-file")
7536 (build-system python-build-system)
7538 '(#:tests? #f ;no tests
7539 #:configure-flags '("--single-version-externally-managed" "--root=/")
7540 #:phases (modify-phases %standard-phases
7541 (add-before 'build 'change-directory
7545 (add-before 'build 'set-library-file-name
7546 (lambda* (#:key inputs #:allow-other-keys)
7547 (let ((file (assoc-ref inputs "file")))
7548 (substitute* "magic.py"
7549 (("find_library\\('magic'\\)")
7550 (string-append "'" file "/lib/libmagic.so'")))
7552 (inputs `(("file" ,file)))
7553 (native-inputs (if (%current-target-system)
7554 `(("self" ,this-package))
7556 (synopsis "Python bindings to the libmagic file type guesser. Note that
7557 this module and the python-magic module both provide a \"magic.py\" file;
7558 these two modules, which are different and were developed separately, both
7559 serve the same purpose: provide Python bindings for libmagic.")))
7561 (define-public python2-file
7562 (package-with-python2 python-file))
7564 (define-public python-debian
7566 (name "python-debian")
7567 (home-page "https://salsa.debian.org/python-debian-team/python-debian")
7571 ;; Use git-fetch, as pypi doesn't include test suite.
7576 (file-name (git-file-name name version))
7579 "0qy6x28bj6yfikhjww932v5xq4mf5bm1iczl7acy4c7zm6mwhqfa"))))
7580 (build-system python-build-system)
7582 `(#:phases (modify-phases %standard-phases
7583 (add-after 'unpack 'remove-debian-specific-tests
7584 ;; python-apt, apt and dpkg are not yet available in guix,
7585 ;; and these tests heavily depend on them.
7587 (delete-file "lib/debian/tests/test_deb822.py")
7588 (delete-file "lib/debian/tests/test_debfile.py")
7591 `(("python-six" ,python-six)
7592 ("python-chardet" ,python-chardet)))
7593 (synopsis "Debian package related modules")
7595 ;; XXX: Use @enumerate instead of @itemize to work around
7596 ;; <http://bugs.gnu.org/21772>.
7597 "This package provides Python modules that abstract many formats of
7598 Debian-related files, such as:
7601 @item Debtags information;
7602 @item @file{debian/changelog} files;
7603 @item packages files, pdiffs;
7604 @item control files of single or multiple RFC822-style paragraphs---e.g.
7605 @file{debian/control}, @file{.changes}, @file{.dsc};
7606 @item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
7607 contained files and meta-information.
7610 ;; Modules are either GPLv2+ or GPLv3+.
7611 (license license:gpl3+)))
7613 (define-public python2-debian
7614 (package-with-python2 python-debian))
7616 (define-public python-nbformat
7618 (name "python-nbformat")
7623 (uri (pypi-uri "nbformat" version))
7626 "00nlf08h8yc4q73nphfvfhxrcnilaqanb8z0mdy6nxk0vzq4wjgp"))))
7627 (build-system python-build-system)
7628 (arguments `(#:tests? #f)) ; no test target
7630 `(("python-ipython-genutils" ,python-ipython-genutils)
7631 ("python-jsonschema" ,python-jsonschema)
7632 ("python-jupyter-core" ,python-jupyter-core)
7633 ("python-traitlets" ,python-traitlets)))
7634 (home-page "http://jupyter.org")
7635 (synopsis "Jupyter Notebook format")
7636 (description "This package provides the reference implementation of the
7637 Jupyter Notebook format and Python APIs for working with notebooks.")
7638 (license license:bsd-3)))
7640 (define-public python2-nbformat
7641 (package-with-python2 python-nbformat))
7643 (define-public python-bleach
7645 (name "python-bleach")
7650 (uri (pypi-uri "bleach" version))
7653 "1yhrgrhkln8bd6gn3imj69g1h4xqah9gaz9q26crqr6gmmvpzprz"))))
7654 (build-system python-build-system)
7656 `(("python-webencodings" ,python-webencodings)
7657 ("python-six" ,python-six)))
7659 `(("python-pytest" ,python-pytest)
7660 ("python-pytest-runner" ,python-pytest-runner-2)))
7661 (home-page "https://github.com/jsocol/bleach")
7662 (synopsis "Whitelist-based HTML-sanitizing tool")
7663 (description "Bleach is an easy whitelist-based HTML-sanitizing tool.")
7664 (license license:asl2.0)))
7666 (define-public python2-bleach
7667 (package-with-python2 python-bleach))
7669 (define-public python-entrypoints
7671 (name "python-entrypoints")
7676 (uri (pypi-uri "entrypoints" version))
7679 "0lc4si3xb7hza424414rdqdc3vng3kcrph8jbvjqb32spqddf3f7"))))
7680 (build-system python-build-system)
7681 ;; The package does not come with a setup.py file, so we have to generate
7686 (modify-phases %standard-phases
7687 (add-after 'unpack 'create-setup.py
7689 (call-with-output-file "setup.py"
7692 from setuptools import setup
7693 setup(name='entrypoints', version='~a', py_modules=['entrypoints'])
7695 (home-page "https://github.com/takluyver/entrypoints")
7696 (synopsis "Discover and load entry points from installed Python packages")
7697 (description "Entry points are a way for Python packages to advertise
7698 objects with some common interface. The most common examples are
7699 @code{console_scripts} entry points, which define shell commands by
7700 identifying a Python function to run. The @code{entrypoints} module contains
7701 functions to find and load entry points.")
7702 (license license:expat)))
7704 (define-public python2-entrypoints
7705 (package-with-python2 python-entrypoints))
7707 (define-public python-nbconvert
7709 (name "python-nbconvert")
7714 (uri (pypi-uri "nbconvert" version))
7717 "0brclbb18l4nmd5qy3dl9wn05rjdh1fz4rmzdlfqacj12rcdvdgp"))))
7718 (build-system python-build-system)
7720 `(;; The "bdist_egg" target is disabled by default, causing the installation
7722 #:configure-flags (list "bdist_egg")
7723 ;; FIXME: 5 failures, 40 errors.
7726 ;; (modify-phases %standard-phases
7729 ;; (zero? (system* "py.test" "-v")))))
7731 `(("python-pytest" ,python-pytest)))
7733 `(("python-bleach" ,python-bleach)
7734 ("python-entrypoints" ,python-entrypoints)
7735 ("python-jinja2" ,python-jinja2)
7736 ("python-jupyter-core" ,python-jupyter-core)
7737 ("python-mistune" ,python-mistune)
7738 ("python-nbformat" ,python-nbformat)
7739 ("python-pygments" ,python-pygments)
7740 ("python-traitlets" ,python-traitlets)))
7741 (home-page "http://jupyter.org")
7742 (synopsis "Converting Jupyter Notebooks")
7743 (description "The @code{nbconvert} tool, @{jupyter nbconvert}, converts
7744 notebooks to various other formats via Jinja templates. It allows you to
7745 convert an @code{.ipynb} notebook file into various static formats including:
7753 @item ReStructured Text (rst)
7754 @item executable script
7756 (license license:bsd-3)))
7758 (define-public python2-nbconvert
7759 (package-with-python2 python-nbconvert))
7761 (define-public python-notebook
7763 (name "python-notebook")
7767 (uri (pypi-uri "notebook" version))
7770 "0jm7324mbxljmn9hgapj66q7swyz5ai92blmr0jpcy0h80x6f26r"))))
7771 (build-system python-build-system)
7774 (modify-phases %standard-phases
7777 ;; These tests require a browser
7778 (delete-file-recursively "notebook/tests/selenium")
7779 ;; Some tests need HOME
7780 (setenv "HOME" "/tmp")
7781 ;; This file contains "warningfilters", which are not supported
7782 ;; by this version of nose.
7783 (delete-file "setup.cfg")
7784 (with-directory-excursion "/tmp"
7785 (invoke "nosetests" "-v"))
7788 `(("python-jupyter-core" ,python-jupyter-core)
7789 ("python-nbformat" ,python-nbformat)
7790 ("python-nbconvert" ,python-nbconvert)
7791 ("python-prometheus-client" ,python-prometheus-client)
7792 ("python-send2trash" ,python-send2trash)
7793 ("python-terminado" ,python-terminado)))
7795 `(("python-nose" ,python-nose)
7796 ("python-sphinx" ,python-sphinx)
7797 ("python-requests" ,python-requests)))
7798 (home-page "http://jupyter.org/")
7799 (synopsis "Web-based notebook environment for interactive computing")
7801 "The Jupyter HTML notebook is a web-based notebook environment for
7802 interactive computing.")
7803 (properties `((python2-variant . ,(delay python2-notebook))))
7804 (license license:bsd-3)))
7806 (define-public python2-notebook
7807 (let ((base (package-with-python2
7808 (strip-python2-variant python-notebook))))
7809 (package (inherit base)
7811 `(("python2-mock" ,python2-mock)
7812 ,@(package-native-inputs base)))
7814 (substitute-keyword-arguments (package-arguments base)
7816 `(modify-phases ,phases
7817 (add-before 'check 'disable-test-case
7818 ;; The test requires network access to localhost. Curiously it
7819 ;; fails with Python 2 only. Simply make the test-case return
7823 "notebook/services/nbconvert/tests/test_nbconvert_api.py"
7824 (("formats = self.nbconvert_api") "return #")))))))))))
7826 (define-public python-widgetsnbextension
7828 (name "python-widgetsnbextension")
7833 (uri (pypi-uri "widgetsnbextension" version))
7836 "0rc2nivdy7k4m3vljx7wdh2jh11djapcgwhvzlbs0isl8gl8nqgs"))))
7837 (build-system python-build-system)
7839 `(("python-ipykernel" ,python-ipykernel)
7840 ("python-notebook" ,python-notebook)))
7842 `(("python-certifi" ,python-certifi)
7843 ("python-nose" ,python-nose)))
7844 (home-page "https://ipython.org")
7845 (synopsis "IPython HTML widgets for Jupyter")
7846 (description "This package provides interactive HTML widgets for Jupyter
7848 (license license:bsd-3)))
7850 (define-public python2-widgetsnbextension
7851 (package-with-python2 python-widgetsnbextension))
7853 (define-public python-ipywidgets
7855 (name "python-ipywidgets")
7860 (uri (pypi-uri "ipywidgets" version))
7863 "1lk0qrr5l9a0z7qkkn30hv5832whxwxymf1l576fmmad0n7hkxms"))))
7864 (build-system python-build-system)
7866 `(("python-ipython" ,python-ipython)
7867 ("python-traitlets" ,python-traitlets)
7868 ("python-widgetsnbextension" ,python-widgetsnbextension)))
7870 `(("python-nose" ,python-nose)
7871 ("python-pytest" ,python-pytest)))
7872 (home-page "https://ipython.org")
7873 (synopsis "IPython HTML widgets for Jupyter")
7874 (description "Ipywidgets are interactive HTML widgets for Jupyter
7875 notebooks and the IPython kernel. Notebooks come alive when interactive
7876 widgets are used. Users gain control of their data and can visualize changes
7878 (license license:bsd-3)))
7880 (define-public python2-ipywidgets
7881 (package-with-python2 python-ipywidgets))
7883 (define-public python-jupyter-console
7885 (name "python-jupyter-console")
7890 (uri (pypi-uri "jupyter_console" version))
7893 "1xdjw11cppf1fxvwkw2bk13ckkwas3bdah8baingn9296mvfi31h"))))
7894 (build-system python-build-system)
7896 `(("python-ipykernel" ,python-ipykernel)
7897 ("python-jupyter-client" ,python-jupyter-client)
7898 ("python-prompt-toolkit" ,python-prompt-toolkit)
7899 ("python-pygments" ,python-pygments)))
7901 `(("python-nose" ,python-nose)))
7902 (home-page "https://jupyter.org")
7903 (synopsis "Jupyter terminal console")
7904 (description "This package provides a terminal-based console frontend for
7905 Jupyter kernels. It also allows for console-based interaction with non-Python
7906 Jupyter kernels such as IJulia and IRKernel.")
7907 (license license:bsd-3)))
7909 (define-public python2-jupyter-console
7911 (name "python2-jupyter-console")
7916 (uri (pypi-uri "jupyter_console" version))
7919 "1kam1qzgwr7srhm5r6aj90di5sws4bq0jmiw15452ddamb9yspal"))))
7920 (build-system python-build-system)
7921 ;; Tests only run in an TTY.
7922 (arguments `(#:tests? #f))
7924 `(("python2-ipykernel" ,python2-ipykernel)
7925 ("python2-jupyter-client" ,python2-jupyter-client)
7926 ("python2-prompt-toolkit" ,python2-prompt-toolkit-1)
7927 ("python2-pygments" ,python2-pygments)))
7929 `(("python2-nose" ,python2-nose)))
7930 (home-page "https://jupyter.org")
7931 (synopsis "Jupyter terminal console")
7932 (description "This package provides a terminal-based console frontend for
7933 Jupyter kernels. It also allows for console-based interaction with non-Python
7934 Jupyter kernels such as IJulia and IRKernel.")
7935 (license license:bsd-3)))
7937 ;; The python-ipython and python-jupyter-console require each other. To get
7938 ;; the functionality in both packages working, strip down the
7939 ;; python-jupyter-console package when using it as an input to python-ipython.
7940 (define python-jupyter-console-minimal
7942 (inherit python-jupyter-console)
7943 (name "python-jupyter-console-minimal")
7945 (substitute-keyword-arguments
7946 (package-arguments python-jupyter-console)
7948 `(modify-phases ,phases
7949 (add-after 'install 'delete-bin
7950 (lambda* (#:key outputs #:allow-other-keys)
7951 ;; Delete the bin files, to avoid conflicts in profiles
7952 ;; where python-ipython and python-jupyter-console are
7954 (delete-file-recursively
7956 (assoc-ref outputs "out") "/bin"))))))))
7957 ;; Remove the python-ipython propagated input, to avoid the cycle
7961 (package-propagated-inputs python-jupyter-console)))))
7963 (define-public python-qtconsole
7965 (name "python-qtconsole")
7970 (uri (pypi-uri "qtconsole" version))
7973 "1b03n1ixzscm0jw97l4dq5iy4fslnqxq5bb8287xb7n2a1gs26xw"))))
7974 (build-system python-build-system)
7976 ;; XXX: Tests are disabled, because this package needs python-ipython 7,
7977 ;; but we only have the LTS version 5.x. This means that there might be
7978 ;; runtime errors, but since this is a dependency of the Jupyter package,
7979 ;; and Jupyter can be used without the qtconsole we can overlook this for
7983 (modify-phases %standard-phases
7984 (add-before 'check 'pre-check
7986 (setenv "QT_QPA_PLATFORM" "offscreen")
7989 `(("python-ipykernel" ,python-ipykernel)
7990 ("python-ipython" ,python-ipython)))
7992 `(("python-pytest" ,python-pytest)))
7993 (home-page "http://jupyter.org")
7994 (synopsis "Jupyter Qt console")
7995 (description "This package provides a Qt-based console for Jupyter with
7996 support for rich media output.")
7997 (license license:bsd-3)))
7999 (define-public python-jsbeautifier
8001 (name "python-jsbeautifier")
8003 (home-page "https://github.com/beautify-web/js-beautify")
8008 (commit (string-append "v" version))))
8009 (file-name (git-file-name name version))
8012 "0wawb070ki1axb3jc9xvsrgpji52vcfif3zmjzc3z4g98m5xw4kg"))))
8013 (build-system python-build-system)
8015 `(#:phases (modify-phases %standard-phases
8016 (add-after 'unpack 'chdir
8018 ;; The upstream Git repository contains all the code,
8019 ;; but this package only builds the python code.
8022 (add-after 'unpack 'patch-python-six-requirements
8024 (substitute* "python/setup.py"
8029 `(("python-editorconfig" ,python-editorconfig)
8030 ("python-six" ,python-six)))
8032 `(("python-pytest" ,python-pytest)))
8033 (synopsis "JavaScript unobfuscator and beautifier")
8034 (description "Beautify, unpack or deobfuscate JavaScript, leveraging
8035 popular online obfuscators.")
8036 (license license:expat)))
8038 (define-public jupyter
8045 (uri (pypi-uri "jupyter" version))
8048 "0pwf3pminkzyzgx5kcplvvbvwrrzd3baa7lmh96f647k30rlpp6r"))))
8049 (build-system python-build-system)
8050 (arguments '(#:tests? #f)) ; there are none.
8052 `(("python-ipykernel" ,python-ipykernel)
8053 ("python-ipywidgets" ,python-ipywidgets)
8054 ("python-jupyter-console" ,python-jupyter-console)
8055 ("python-nbconvert" ,python-nbconvert)
8056 ("python-notebook" ,python-notebook)
8057 ("python-qtconsole" ,python-qtconsole)))
8058 (native-search-paths
8059 (list (search-path-specification
8060 (variable "JUPYTER_PATH")
8061 (files '("share/jupyter")))))
8062 (home-page "https://jupyter.org")
8063 (synopsis "Web application for interactive documents")
8065 "The Jupyter Notebook is a web application that allows you to create and
8066 share documents that contain live code, equations, visualizations and
8067 explanatory text. Uses include: data cleaning and transformation, numerical
8068 simulation, statistical modeling, machine learning and much more.")
8069 (license license:bsd-3)))
8071 (define-public python-chardet
8073 (name "python-chardet")
8078 (uri (pypi-uri "chardet" version))
8081 "1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4"))))
8083 `(("python-hypothesis" ,python-hypothesis)
8084 ("python-pytest" ,python-pytest)
8085 ("python-pytest-runner" ,python-pytest-runner)))
8086 (build-system python-build-system)
8087 ;; XXX: Incompatible with Pytest 4: <https://github.com/chardet/chardet/issues/173>.
8088 (arguments `(#:tests? #f))
8089 (home-page "https://github.com/chardet/chardet")
8090 (synopsis "Universal encoding detector for Python 2 and 3")
8092 "This package provides @code{chardet}, a Python module that can
8093 automatically detect a wide range of file encodings.")
8094 (license license:lgpl2.1+)))
8096 (define-public python2-chardet
8097 (package-with-python2 python-chardet))
8099 (define-public python-docopt
8101 (name "python-docopt")
8106 ;; The release on PyPI does not include tests.
8108 (url "https://github.com/docopt/docopt")
8110 (file-name (git-file-name name version))
8113 "0aad9gbswnnhssin2q0m5lmpm0ahyf80ahs2zjigbn5y7fvljnd0"))))
8114 (build-system python-build-system)
8116 `(("python-pytest" ,python-pytest)))
8119 (modify-phases %standard-phases
8121 (lambda _ (invoke "py.test"))))))
8122 (home-page "http://docopt.org")
8123 (synopsis "Command-line interface description language for Python")
8124 (description "This library allows the user to define a command-line
8125 interface from a program's help message rather than specifying it
8126 programmatically with command-line parsers like @code{getopt} and
8128 (license license:expat)))
8130 (define-public python2-docopt
8131 (package-with-python2 python-docopt))
8133 (define-public python-pythondialog
8135 (name "python-pythondialog")
8140 (uri (pypi-uri "pythondialog" version))
8143 "1728ghsran47jczn9bhlnkvk5bvqmmbihabgif5h705b84r1272c"))))
8144 (build-system python-build-system)
8147 (modify-phases %standard-phases
8148 (add-after 'unpack 'patch-path
8149 (lambda* (#:key inputs #:allow-other-keys)
8150 (let* ((dialog (assoc-ref inputs "dialog")))
8151 ;; Since this library really wants to grovel the search path, we
8152 ;; must hardcode dialog's store path into it.
8153 (substitute* "dialog.py"
8154 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
8155 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
8157 #:tests? #f)) ; no test suite
8159 `(("dialog" ,dialog)))
8160 (home-page "http://pythondialog.sourceforge.net/")
8161 (synopsis "Python interface to the UNIX dialog utility")
8162 (description "A Python wrapper for the dialog utility. Its purpose is to
8163 provide an easy to use, pythonic and comprehensive Python interface to dialog.
8164 This allows one to make simple text-mode user interfaces on Unix-like systems")
8165 (license license:lgpl2.1)
8166 (properties `((python2-variant . ,(delay python2-pythondialog))))))
8168 (define-public python2-pythondialog
8169 (let ((base (package-with-python2 (strip-python2-variant python-pythondialog))))
8172 (version (package-version python-pythondialog))
8175 (uri (pypi-uri "python2-pythondialog" version))
8178 "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9")))))))
8180 (define-public python-configobj
8182 (name "python-configobj")
8186 (uri (pypi-uri "configobj" version))
8189 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
8190 ;; Patch setup.py so it looks for python-setuptools, which is
8191 ;; required to parse the keyword 'install_requires' in setup.py.
8192 (patches (search-patches "python-configobj-setuptools.patch"))))
8193 (build-system python-build-system)
8195 `(("python-six" ,python-six)))
8196 (synopsis "Config file reading, writing and validation")
8197 (description "ConfigObj is a simple but powerful config file reader and
8198 writer: an ini file round tripper. Its main feature is that it is very easy to
8199 use, with a straightforward programmer’s interface and a simple syntax for
8201 (home-page "https://github.com/DiffSK/configobj")
8202 (license license:bsd-3)))
8204 (define-public python2-configobj
8205 (package-with-python2 python-configobj))
8207 (define-public python-configargparse
8209 (name "python-configargparse")
8213 (uri (pypi-uri "ConfigArgParse" version))
8216 "149fy4zya0rsnlkvxbbq43cyr8lscb5k4pj1m6n7f1grwcmzwbif"))))
8217 (build-system python-build-system)
8219 `(("python-pyyaml" ,python-pyyaml)))
8222 (modify-phases %standard-phases
8225 ;; Bypass setuptools-shim because one test relies on "setup.py"
8226 ;; being the first argument passed to the python call.
8228 ;; NOTE: Many tests do not run because they rely on Python's
8229 ;; built-in test.test_argparse, but we remove the unit tests from
8230 ;; our Python installation.
8231 (invoke "python" "setup.py" "test"))))))
8232 (synopsis "Replacement for argparse")
8233 (description "A drop-in replacement for argparse that allows options to also
8234 be set via config files and/or environment variables.")
8235 (home-page "https://github.com/bw2/ConfigArgParse")
8236 (license license:expat)))
8238 (define-public python2-configargparse
8239 (package-with-python2 python-configargparse))
8241 (define-public python-argparse-manpage
8243 (name "python-argparse-manpage")
8248 (uri (pypi-uri "argparse-manpage" version))
8251 "0blh31zns68anina9lba5wh81d1414s97p60zw5l0d0shhh0wj5p"))))
8252 (build-system python-build-system)
8253 (home-page "https://github.com/praiskup/argparse-manpage")
8254 (synopsis "Build manual page from Python's ArgumentParser object")
8256 "This package provides tools to build manual pages from Python's
8257 @code{ArgumentParser} object.")
8258 (license license:asl2.0)))
8260 (define-public python-contextlib2
8262 (name "python-contextlib2")
8267 (uri (pypi-uri "contextlib2" version))
8270 "0j6ad6lwwyc9kv71skj098v5l7x5biyj2hs4lc5x1kcixqcr97sh"))))
8271 (build-system python-build-system)
8272 (home-page "http://contextlib2.readthedocs.org/")
8273 (synopsis "Tools for decorators and context managers")
8274 (description "This module is primarily a backport of the Python
8275 3.2 contextlib to earlier Python versions. Like contextlib, it
8276 provides utilities for common tasks involving decorators and context
8277 managers. It also contains additional features that are not part of
8278 the standard library.")
8279 (properties `((python2-variant . ,(delay python2-contextlib2))))
8280 (license license:psfl)))
8282 (define-public python2-contextlib2
8283 (let ((base (package-with-python2
8284 (strip-python2-variant python-contextlib2))))
8288 (substitute-keyword-arguments (package-arguments base)
8290 `(modify-phases ,phases
8292 (lambda _ (invoke "python" "test_contextlib2.py" "-v")))))))
8294 `(("python2-unittest2" ,python2-unittest2))))))
8296 (define-public python-texttable
8298 (name "python-texttable")
8303 (uri (pypi-uri "texttable" version))
8306 "0yawv64c0zbawwv6zz84whb32fnb2n9jylwjcfsrcdgh7xvl340i"))))
8307 (build-system python-build-system)
8308 (arguments '(#:tests? #f)) ; no tests
8309 (home-page "https://github.com/foutaise/texttable/")
8310 (synopsis "Python module for creating simple ASCII tables")
8311 (description "Texttable is a Python module for creating simple ASCII
8313 (license license:lgpl2.1+)))
8315 (define-public python2-texttable
8316 (package-with-python2 python-texttable))
8318 (define-public python-atomicwrites
8320 (name "python-atomicwrites")
8324 (uri (pypi-uri "atomicwrites" version))
8327 "19ngcscdf3jsqmpcxn6zl5b6anmsajb6izp1smcd1n02midl9abm"))))
8328 (build-system python-build-system)
8329 (synopsis "Atomic file writes in Python")
8330 (description "Library for atomic file writes using platform dependent tools
8331 for atomic file system operations.")
8332 (home-page "https://github.com/untitaker/python-atomicwrites")
8333 (license license:expat)))
8335 (define-public python2-atomicwrites
8336 (package-with-python2 python-atomicwrites))
8338 (define-public python-click-threading
8340 (name "python-click-threading")
8344 (uri (pypi-uri "click-threading" version))
8347 "1rsxc2fbkxlhwhlmxsdjzq3spn284l6rvjfcz9mbb17ibgdgmc5j"))))
8348 (build-system python-build-system)
8350 `(("python-click" ,python-click)))
8351 (synopsis "Utilities for multithreading in Click")
8352 (description "This package provides utilities for multithreading in Click
8354 (home-page "https://github.com/click-contrib/click-threading")
8355 (license license:expat)))
8357 (define-public python-click-log
8359 (name "python-click-log")
8363 (uri (pypi-uri "click-log" version))
8366 "091i03bhxyzsdbc6kilxhivfda2f8ymz3b33xa6cj5kbzjiirz8n"))))
8367 (build-system python-build-system)
8369 `(("python-click" ,python-click)))
8370 (synopsis "Logging for click applications")
8371 (description "This package provides a Python library for logging Click
8373 (home-page "https://github.com/click-contrib/click-log")
8374 (license license:expat)))
8376 (define-public python-apipkg
8378 (name "python-apipkg")
8382 (uri (pypi-uri "apipkg" version))
8385 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
8386 (build-system python-build-system)
8388 `(("python-pytest" ,python-pytest)))
8389 (synopsis "Namespace control and lazy-import mechanism")
8390 (description "With apipkg you can control the exported namespace of a Python
8391 package and greatly reduce the number of imports for your users. It is a small
8392 pure Python module that works on virtually all Python versions.")
8393 (home-page "https://github.com/pytest-dev/apipkg")
8394 (license license:expat)))
8396 (define-public python2-apipkg
8397 (package-with-python2 python-apipkg))
8399 (define-public python-execnet
8401 (name "python-execnet")
8405 (uri (pypi-uri "execnet" version))
8408 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
8409 (build-system python-build-system)
8411 `(;; 2 failed, 275 passed, 670 skipped, 4 xfailed
8412 ;; The two test failures are caused by the lack of an `ssh` executable.
8413 ;; The test suite can be run with pytest after the 'install' phase.
8416 `(("python-pytest" ,python-pytest)
8417 ("python-setuptools-scm" ,python-setuptools-scm)))
8419 `(("python-apipkg" ,python-apipkg)))
8420 (synopsis "Rapid multi-Python deployment")
8421 (description "Execnet provides a share-nothing model with
8422 channel-send/receive communication for distributing execution across many
8423 Python interpreters across version, platform and network barriers. It has a
8424 minimal and fast API targeting the following uses:
8426 @item distribute tasks to (many) local or remote CPUs
8427 @item write and deploy hybrid multi-process applications
8428 @item write scripts to administer multiple environments
8430 (home-page "http://codespeak.net/execnet/")
8431 (license license:expat)))
8433 (define-public python2-execnet
8434 (package-with-python2 python-execnet))
8436 (define-public python-icalendar
8438 (name "python-icalendar")
8442 (uri (pypi-uri "icalendar" version))
8445 "16gjvqv0n05jrb9g228pdjgzd3amz2pdhvcgsn1jypszjg5m2w9l"))))
8446 (build-system python-build-system)
8448 `(("python-dateutil" ,python-dateutil)
8449 ("python-pytz" ,python-pytz)))
8450 (synopsis "Python library for parsing iCalendar files")
8451 (description "The icalendar package is a parser/generator of iCalendar
8452 files for use with Python.")
8453 (home-page "https://github.com/collective/icalendar")
8454 (license license:bsd-2)))
8456 (define-public python-args
8458 (name "python-args")
8462 (uri (pypi-uri "args" version))
8465 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
8466 (build-system python-build-system)
8467 (home-page "https://github.com/kennethreitz/args")
8468 (synopsis "Command-line argument parser")
8470 "This library provides a Python module to parse command-line arguments.")
8471 (license license:bsd-3)))
8473 (define-public python2-args
8474 (package-with-python2 python-args))
8476 (define-public python-clint
8478 (name "python-clint")
8482 (uri (pypi-uri "clint" version))
8485 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
8486 (build-system python-build-system)
8489 (modify-phases %standard-phases
8491 (lambda _ (invoke "py.test" "-v"))))))
8493 `(("python-pytest" ,python-pytest)))
8495 `(("python-args" ,python-args)))
8496 (home-page "https://github.com/kennethreitz/clint")
8497 (synopsis "Command-line interface tools")
8499 "Clint is a Python module filled with a set of tools for developing
8500 command-line applications, including tools for colored and indented
8501 output, progress bar display, and pipes.")
8502 (license license:isc)))
8504 (define-public python2-clint
8505 (package-with-python2 python-clint))
8507 (define-public python-rply
8509 (name "python-rply")
8513 (uri (pypi-uri "rply" version))
8516 "0lv428895zxsz43968qx0q9bimwqnfykndz4dpjbq515w2gvzhjh"))))
8517 (build-system python-build-system)
8519 `(("python-appdirs" ,python-appdirs)))
8520 (home-page "https://github.com/alex/rply")
8521 (synopsis "Parser generator for Python")
8523 "This package provides a pure Python based parser generator, that also
8524 works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
8525 with a new public API, and RPython support.")
8526 (license license:bsd-3)))
8528 (define-public python2-rply
8529 (package-with-python2 python-rply))
8531 (define-public python-hy
8537 (uri (pypi-uri "hy" version))
8540 "1gdbqsirsdxj320wnp7my5awzs1kfs6m4fqmkzbd1zd47qzj0zfi"))))
8541 (build-system python-build-system)
8544 (modify-phases %standard-phases
8545 (add-before 'install 'set-HOME
8547 (setenv "HOME" "/tmp")))
8550 ;; Tests require write access to HOME.
8551 (setenv "HOME" "/tmp")
8552 (invoke "nosetests"))))))
8554 `(("python-coverage" ,python-coverage)
8555 ("python-nose" ,python-nose)))
8557 `(("python-astor" ,python-astor)
8558 ("python-clint" ,python-clint)
8559 ("python-rply" ,python-rply)
8560 ("python-fastentrypoints"
8561 ,python-fastentrypoints)
8562 ("python-funcparserlib"
8563 ,python-funcparserlib)))
8564 (home-page "http://hylang.org/")
8565 (synopsis "Lisp frontend to Python")
8567 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
8568 its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
8569 Python at your fingertips, in Lisp form.")
8570 (license license:expat)))
8572 (define-public python2-hy
8573 (package-with-python2 python-hy))
8575 (define-public python2-functools32
8577 (name "python2-functools32")
8582 (uri (pypi-uri "functools32" version))
8585 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
8586 (build-system python-build-system)
8588 `(#:python ,python-2
8589 #:tests? #f)) ; no test target
8590 (home-page "https://github.com/MiCHiLU/python-functools32")
8592 "Backport of the functools module from Python 3.2.3")
8594 "This package is a backport of the @code{functools} module from Python
8595 3.2.3 for use with older versions of Python and PyPy.")
8596 (license license:expat)))
8598 (define-public python2-subprocess32
8600 (name "python2-subprocess32")
8604 (uri (pypi-uri "subprocess32" version))
8607 "14350dhhlhyz5gqzi3lihn9m6lvskx5mcb20srx1kgsk9i50li8y"))
8609 (search-patches "python2-subprocess32-disable-input-test.patch"))))
8610 (build-system python-build-system)
8612 `(#:python ,python-2
8613 ;; The test suite fails with Python > 2.7.13:
8614 ;; import test.support
8615 ;; ImportError: No module named support
8618 (modify-phases %standard-phases
8619 (add-after 'unpack 'patch-/bin/sh
8621 (substitute* '("subprocess32.py"
8622 "test_subprocess32.py")
8623 (("/bin/sh") (which "sh")))
8625 (home-page "https://github.com/google/python-subprocess32")
8626 (synopsis "Backport of the subprocess module from Python 3.2")
8628 "This is a backport of the @code{subprocess} standard library module
8629 from Python 3.2 and 3.3 for use on Python 2. It includes bugfixes and some
8630 new features. On POSIX systems it is guaranteed to be reliable when used
8631 in threaded applications. It includes timeout support from Python 3.3 but
8632 otherwise matches 3.2’s API.")
8633 (license license:psfl)))
8635 (define-public python2-futures
8637 (name "python2-futures")
8642 (uri (pypi-uri "futures" version))
8645 "0rdjmmsab550kxsssdq49jcniz77zlkpw4pvi9hvib3lsskjmh4y"))))
8646 (build-system python-build-system)
8648 `(#:python ,python-2
8650 (modify-phases %standard-phases
8653 (invoke "python" "test_futures.py")
8655 (home-page "https://github.com/agronholm/pythonfutures")
8657 "Backport of the concurrent.futures package from Python 3.2")
8659 "The concurrent.futures module provides a high-level interface for
8660 asynchronously executing callables. This package backports the
8661 concurrent.futures package from Python 3.2")
8662 (license license:bsd-3)))
8664 (define-public python-promise
8666 (name "python-promise")
8671 (uri (pypi-uri "promise" version))
8674 "1k19ms8l3d5jzjh557rgkxb5sg4mqgfc315rn4hx1z3n8qq6lr3h"))))
8675 (build-system python-build-system)
8676 ;; Tests wants python-futures, which is a python2 only program, and
8677 ;; can't be found by python-promise at test time.
8678 (arguments `(#:tests? #f))
8679 (home-page "https://github.com/syrusakbary/promise")
8680 (synopsis "Promises/A+ implementation for Python")
8682 "Promises/A+ implementation for Python")
8683 (properties `((python2-variant . ,(delay python2-promise))))
8684 (license license:expat)))
8686 (define-public python2-promise
8687 (let ((promise (package-with-python2
8688 (strip-python2-variant python-promise))))
8689 (package (inherit promise)
8690 (arguments (substitute-keyword-arguments (package-arguments promise)
8693 `(("python2-futures" ,python2-futures)
8694 ("python2-pytest" ,python2-pytest)
8695 ,@(package-native-inputs promise))))))
8697 (define-public python-progressbar33
8699 (name "python-progressbar33")
8704 (uri (pypi-uri "progressbar33" version))
8707 "1zvf6zs5hzrc03p9nfs4p16vhilqikycvv1yk0pxn8s07fdhvzji"))))
8708 (build-system python-build-system)
8709 (home-page "http://github.com/germangh/python-progressbar")
8710 (synopsis "Text progress bar library for Python")
8712 "This package provides a text progress bar library for Python. This
8713 version only differs from the original @code{progressbar} package in that it
8714 uses relative package imports instead of absolute imports, which is necessary
8715 for the module to work under Python 3.3.")
8716 ;; Either or both of these licenses may be selected.
8717 (license (list license:lgpl2.1+ license:bsd-3))))
8719 (define-public python-colorama
8721 (name "python-colorama")
8726 (uri (pypi-uri "colorama" version))
8729 "1wd1szk0z3073ghx26ynw43gnc140ibln1safgsis6s6z3s25ss8"))))
8730 (build-system python-build-system)
8731 (synopsis "Colored terminal text rendering for Python")
8732 (description "Colorama is a Python library for rendering colored terminal
8734 (home-page "https://pypi.python.org/pypi/colorama")
8735 (license license:bsd-3)))
8737 (define-public python2-colorama
8738 (package-with-python2 python-colorama))
8740 (define-public python-rsa
8747 (uri (pypi-uri "rsa" version))
8750 "1dcxvszbikgzh99ybdc7jq0zb9wspy2ds8z9mjsqiyv3q884xpr5"))))
8751 (build-system python-build-system)
8753 `(("python-pyasn1" ,python-pyasn1)))
8754 (synopsis "Pure-Python RSA implementation")
8755 (description "Python-RSA is a pure-Python RSA implementation. It supports
8756 encryption and decryption, signing and verifying signatures, and key
8757 generation according to PKCS#1 version 1.5. It can be used as a Python
8758 library as well as on the command line.")
8759 (home-page "https://stuvel.eu/rsa")
8760 (license license:asl2.0)))
8762 (define-public python2-rsa
8763 (package-with-python2 python-rsa))
8765 (define-public python-pluggy
8767 (name "python-pluggy")
8772 (uri (pypi-uri "pluggy" version))
8775 "10511a54dvafw1jrk75mrhml53c7b7w4yaw7241696lc2hfvr895"))))
8776 (build-system python-build-system)
8778 `(("python-setuptools-scm" ,python-setuptools-scm)))
8779 (synopsis "Plugin and hook calling mechanism for Python")
8780 (description "Pluggy is an extraction of the plugin manager as used by
8781 Pytest but stripped of Pytest specific details.")
8782 (home-page "https://pypi.python.org/pypi/pluggy")
8783 (license license:expat)))
8785 (define-public python2-pluggy
8786 (package-with-python2 python-pluggy))
8788 (define-public python-tox
8795 (uri (pypi-uri "tox" version))
8798 "1drp6mwm8wdypjym15ia8lwjxbhcksb9vzxg4ay5dh4ji57by2ny"))))
8799 (build-system python-build-system)
8801 ;; FIXME: Tests require pytest-timeout, which itself requires
8802 ;; pytest>=2.8.0 for installation.
8805 `(("python-pluggy" ,python-pluggy) ; >=0.3.0,<0.4.0
8806 ("python-py" ,python-py)
8807 ("python-virtualenv" ,python-virtualenv)))
8809 `(; FIXME: Missing: ("python-pytest-timeout" ,python-pytest-timeout)
8810 ("python-pytest" ,python-pytest) ; >= 2.3.5
8811 ("python-setuptools-scm" ,python-setuptools-scm)))
8812 (home-page "http://tox.testrun.org/")
8813 (synopsis "Virtualenv-based automation of test activities")
8814 (description "Tox is a generic virtualenv management and test command line
8815 tool. It can be used to check that a package installs correctly with
8816 different Python versions and interpreters, or run tests in each type of
8817 supported environment, or act as a frontend to continuous integration
8819 (license license:expat)))
8821 (define-public python2-tox
8822 (package-with-python2 python-tox))
8824 (define-public python-jmespath
8826 (name "python-jmespath")
8831 (uri (pypi-uri "jmespath" version))
8834 "0k0765x1mybcrzajh3hiqkl8sy9hs0bmn4900frxy0j3ykvaxqmx"))))
8835 (build-system python-build-system)
8837 `(("python-nose" ,python-nose)))
8838 (synopsis "JSON Matching Expressions")
8839 (description "JMESPath (pronounced “james path”) is a Python library that
8840 allows one to declaratively specify how to extract elements from a JSON
8842 (home-page "https://github.com/jmespath/jmespath.py")
8843 (license license:expat)))
8845 (define-public python2-jmespath
8846 (package-with-python2 python-jmespath))
8848 (define-public python-botocore
8850 (name "python-botocore")
8851 (version "1.12.149")
8855 (uri (pypi-uri "botocore" version))
8858 "12597f74khp3ngwr282cb949w0gcqj20rkfc3x275dijavyy5cmf"))))
8859 (build-system python-build-system)
8861 ;; FIXME: Many tests are failing.
8864 `(("python-dateutil" ,python-dateutil)
8865 ("python-docutils" ,python-docutils)
8866 ("python-jmespath" ,python-jmespath)))
8868 `(("python-mock" ,python-mock)
8869 ("python-nose" ,python-nose)
8871 ("python-tox" ,python-tox)
8872 ("python-urllib3" ,python-urllib3)
8873 ("python-wheel" ,python-wheel)))
8874 (home-page "https://github.com/boto/botocore")
8875 (synopsis "Low-level interface to AWS")
8876 (description "Botocore is a Python library that provides a low-level
8877 interface to the Amazon Web Services (AWS) API.")
8878 (license license:asl2.0)))
8880 (define-public python2-botocore
8881 (package-with-python2 python-botocore))
8883 (define-public python-xdo
8890 "http://http.debian.net/debian/pool/main/p/python-xdo/"
8891 "python-xdo_" version ".orig.tar.gz"))
8894 "1vqh1n5yy5dhnq312kwrl90fnck4v26is3lq3lxdvcn60vv19da0"))))
8895 (build-system python-build-system)
8898 (modify-phases %standard-phases
8899 (add-before 'install 'patch-libxdo-path
8900 ;; Hardcode the path of dynamically loaded libxdo library.
8901 (lambda* (#:key inputs #:allow-other-keys)
8902 (let ((libxdo (string-append
8903 (assoc-ref inputs "xdotool")
8905 (substitute* "xdo/_xdo.py"
8906 (("find_library\\(\"xdo\"\\)")
8907 (simple-format #f "\"~a\"" libxdo)))
8909 #:tests? #f)) ; no tests provided
8911 `(("python-six" ,python-six)))
8913 `(("xdotool" ,xdotool)
8914 ("libX11" ,libx11)))
8915 (home-page "https://tracker.debian.org/pkg/python-xdo")
8916 (synopsis "Python library for simulating X11 keyboard/mouse input")
8917 (description "Provides bindings to libxdo for manipulating X11 via simulated
8918 input. (Note that this is mostly a legacy library; you may wish to look at
8919 python-xdo for newer bindings.)")
8920 (license license:bsd-3)))
8922 (define-public python2-xdo
8923 (package-with-python2 python-xdo))
8925 (define-public python-mako
8927 (name "python-mako")
8932 (uri (pypi-uri "Mako" version))
8935 "0jqa3qfpykyn4fmkn0kh6043sfls7br8i2bsdbccazcvk9cijsd3"))))
8936 (build-system python-build-system)
8938 `(#:phases (modify-phases %standard-phases
8941 (invoke "pytest" "-vv"))))))
8943 `(("python-markupsafe" ,python-markupsafe)))
8945 `(("python-mock" ,python-mock)
8946 ("python-pytest" ,python-pytest)))
8947 (home-page "https://www.makotemplates.org/")
8948 (synopsis "Templating language for Python")
8949 (description "Mako is a templating language for Python that compiles
8950 templates into Python modules.")
8951 (license license:expat)))
8953 (define-public python2-mako
8954 (package-with-python2 python-mako))
8956 (define-public python-waitress
8958 (name "python-waitress")
8963 (uri (pypi-uri "waitress" version))
8964 (patches (search-patches "python-waitress-fix-tests.patch"))
8967 "1a85gyji0kajc3p0s1pwwfm06w4wfxjkvvl4rnrz3h164kbd6g6k"))))
8968 (build-system python-build-system)
8969 (home-page "https://github.com/Pylons/waitress")
8970 (synopsis "Waitress WSGI server")
8971 (description "Waitress is meant to be a production-quality pure-Python WSGI
8972 server with very acceptable performance.")
8973 (license license:zpl2.1)))
8975 (define-public python2-waitress
8976 (package-with-python2 python-waitress))
8978 (define-public python-whichcraft
8980 (name "python-whichcraft")
8985 (uri (pypi-uri "whichcraft" version))
8988 "11yfkzyplizdgndy34vyd5qlmr1n5mxis3a3svxmx8fnccdvknxc"))))
8989 (build-system python-build-system)
8991 `(("python-pytest" ,python-pytest)))
8992 (home-page "https://github.com/pydanny/whichcraft")
8993 (synopsis "Cross-platform cross-python shutil.which functionality")
8995 "This package provides a shim of the shutil.which function that's
8996 designed to work across multiple versions of Python.")
8997 (license license:bsd-3)))
8999 (define-public python-cookiecutter
9001 (name "python-cookiecutter")
9006 (uri (pypi-uri "cookiecutter" version))
9009 "0glsvaz8igi2wy1hsnhm9fkn6560vdvdixzvkq6dn20z3hpaa5hk"))))
9010 (build-system python-build-system)
9012 `(("python-freezegun" ,python-freezegun)
9013 ("python-pytest" ,python-pytest)
9014 ("python-pytest-catchlog" ,python-pytest-catchlog)
9015 ("python-pytest-cov" ,python-pytest-cov)
9016 ("python-pytest-mock" ,python-pytest-mock)))
9018 `(("python-binaryornot" ,python-binaryornot)
9019 ("python-click" ,python-click)
9020 ("python-future" ,python-future)
9021 ("python-jinja2" ,python-jinja2)
9022 ("python-jinja2-time" ,python-jinja2-time)
9023 ("python-poyo" ,python-poyo)
9024 ("python-requests" ,python-requests)
9025 ("python-whichcraft" ,python-whichcraft)))
9026 (home-page "https://github.com/audreyr/cookiecutter")
9028 "Command-line utility that creates projects from project templates")
9030 "This package provides a command-line utility that creates projects from
9031 project templates, e.g. creating a Python package project from a Python package
9033 (license license:bsd-3)))
9035 (define-public python-pyquery
9037 (name "python-pyquery")
9042 (uri (pypi-uri "pyquery" version))
9045 "1xia20wm0vx5dk85kcwgh13bylz8qh47ffjxssd2586r60xi783a"))))
9046 (build-system python-build-system)
9048 `(("python-webob" ,python-webob)
9049 ("python-webtest" ,python-webtest)))
9051 `(("python-lxml" ,python-lxml)
9052 ("python-cssselect" ,python-cssselect)))
9053 (home-page "https://github.com/gawel/pyquery")
9054 (synopsis "Make jQuery-like queries on xml documents")
9055 (description "pyquery allows you to make jQuery queries on xml documents.
9056 The API is as much as possible the similar to jQuery. pyquery uses lxml for
9057 fast xml and html manipulation.")
9058 (license license:bsd-3)))
9060 (define-public python-anyjson
9062 (name "python-anyjson")
9067 (uri (pypi-uri "anyjson" version))
9070 "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
9071 (build-system python-build-system)
9073 `(;; We could possibly get tests working, but on Python 3 it's not so easy.
9074 ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
9075 ;; whatever) so this transformation needs to be done before the tests
9076 ;; can be run. Maybe we could add a build step to transform beforehand
9077 ;; but it could be annoying/difficult.
9078 ;; We can enable tests for the Python 2 version, though, and do below.
9080 (home-page "https://bitbucket.org/runeh/anyjson/")
9082 "Wraps best available JSON implementation in a common interface")
9084 "Anyjson loads whichever is the fastest JSON module installed
9085 and provides a uniform API regardless of which JSON implementation is used.")
9086 (license license:bsd-3)
9087 (properties `((python2-variant . ,(delay python2-anyjson))))))
9089 (define-public python2-anyjson
9090 (let ((anyjson (package-with-python2
9091 (strip-python2-variant python-anyjson))))
9094 (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
9096 ,@(package-arguments anyjson)))
9097 (native-inputs `(("python2-nose" ,python2-nose))))))
9099 (define-public python-amqp
9101 (name "python-amqp")
9106 (uri (pypi-uri "amqp" version))
9109 "1sv600dgqwpimr6i1g59y9hpn50mc236gdqkr7zin13kvlpx0g87"))))
9110 (build-system python-build-system)
9112 `(("python-case" ,python-case)
9113 ("python-pytest-sugar" ,python-pytest-sugar)
9114 ("python-mock" ,python-mock)))
9116 `(("python-vine" ,python-vine)))
9117 (home-page "https://github.com/celery/py-amqp")
9119 "Low-level AMQP client for Python (fork of amqplib)")
9121 "This is a fork of amqplib which was originally written by Barry Pederson.
9122 It is maintained by the Celery project, and used by kombu as a pure python
9123 alternative when librabbitmq is not available.")
9124 (license license:lgpl2.1+)
9125 (properties `((python2-variant . ,(delay python2-amqp))))))
9127 (define-public python2-amqp
9128 (let ((amqp (package-with-python2
9129 (strip-python2-variant python-amqp))))
9132 (arguments `(;; Tries to run coverage tests with nose-cover3, which seems
9133 ;; unmaintained. Weirdly, does not do this on the python 3
9136 ,@(package-arguments amqp))))))
9138 (define-public python-txamqp
9140 (name "python-txamqp")
9145 (uri (pypi-uri "txAMQP" version))
9148 "0jd9864k3csc06kipiwzjlk9mq4054s8kzk5q1cfnxj8572s4iv4"))))
9149 (build-system python-build-system)
9151 `(("python-six" ,python-six)
9152 ("python-twisted" ,python-twisted)))
9153 (home-page "https://github.com/txamqp/txamqp")
9154 (synopsis "Communicate with AMQP peers and brokers using Twisted")
9156 "This package provides a Python library for communicating with AMQP peers
9157 and brokers using the asynchronous networking framework Twisted. It contains
9158 all the necessary code to connect, send and receive messages to/from an
9159 AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It
9160 also includes support for using Thrift RPC over AMQP in Twisted
9162 (license license:asl2.0)))
9164 (define-public python2-txamqp
9165 (package-with-python2 python-txamqp))
9167 (define-public python-kombu
9169 (name "python-kombu")
9174 (uri (pypi-uri "kombu" version))
9177 "15k8f7mzqr049sg9vi48m19vjykviafk3f0p5xzgw9by0x0kyxjj"))))
9178 (build-system python-build-system)
9180 `(("python-mock" ,python-mock)
9181 ("python-case" ,python-case)
9182 ("python-pyro4" ,python-pyro4)
9183 ("python-pytest-sugar" ,python-pytest-sugar)
9184 ("python-pytz" ,python-pytz)))
9186 `(("python-anyjson" ,python-anyjson)
9187 ("python-amqp" ,python-amqp)
9188 ("python-redis" ,python-redis)))
9189 (home-page "https://kombu.readthedocs.io")
9190 (synopsis "Message passing library for Python")
9191 (description "The aim of Kombu is to make messaging in Python as easy as
9192 possible by providing an idiomatic high-level interface for the AMQ protocol,
9193 and also provide proven and tested solutions to common messaging problems.
9194 AMQP is the Advanced Message Queuing Protocol, an open standard protocol for
9195 message orientation, queuing, routing, reliability and security, for which the
9196 RabbitMQ messaging server is the most popular implementation.")
9197 (license license:bsd-3)
9198 (properties `((python2-variant . ,(delay python2-kombu))))))
9200 (define-public python2-kombu
9201 (let ((kombu (package-with-python2
9202 (strip-python2-variant python-kombu))))
9205 (arguments `(;; FIXME: 'TestTransport.test_del_sync' fails on python2.
9206 ;; It works fine on the python3 variant.
9208 ,@(package-arguments kombu)))
9209 (native-inputs `(("python2-unittest2" ,python2-unittest2)
9210 ,@(package-native-inputs kombu))))))
9212 (define-public python-billiard
9214 (name "python-billiard")
9219 (uri (pypi-uri "billiard" version))
9222 "03msmapj3s5zgqk87d646mafz7a01h5bm2wijalgpi0s80ks5na2"))))
9223 (build-system python-build-system)
9225 `(("python-case" ,python-case)
9226 ("python-pytest" ,python-pytest)))
9227 (home-page "https://github.com/celery/billiard")
9229 "Python multiprocessing fork with improvements and bugfixes")
9231 "Billiard is a fork of the Python 2.7 multiprocessing package. The
9232 multiprocessing package itself is a renamed and updated version of R Oudkerk's
9233 pyprocessing package. This standalone variant is intended to be compatible with
9234 Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.")
9235 (license license:bsd-3)
9236 (properties `((python2-variant . ,(delay python2-billiard))))))
9238 (define-public python2-billiard
9239 (let ((billiard (package-with-python2
9240 (strip-python2-variant python-billiard))))
9243 (native-inputs `(("python2-unittest2" ,python2-unittest2)
9244 ("python2-mock" ,python2-mock)
9245 ,@(package-native-inputs billiard))))))
9247 (define-public python-celery
9249 (name "python-celery")
9254 (uri (pypi-uri "celery" version))
9257 "0y66rz7z8dfcgs3s0qxmdddlaq57bzbgxgfz896nbp14grkv9nkp"))))
9258 (build-system python-build-system)
9260 '(;; TODO The tests fail with Python 3.7
9261 ;; https://github.com/celery/celery/issues/4849
9264 (modify-phases %standard-phases
9265 (add-after 'unpack 'patch-requirements
9267 (substitute* "requirements/test.txt"
9268 (("pytest>=3\\.0,<3\\.3")
9272 `(("python-case" ,python-case)
9273 ("python-pytest" ,python-pytest)))
9275 `(("python-pytz" ,python-pytz)
9276 ("python-billiard" ,python-billiard)
9277 ("python-kombu" ,python-kombu)))
9278 (home-page "https://celeryproject.org")
9279 (synopsis "Distributed Task Queue")
9280 (description "Celery is an asynchronous task queue/job queue based on
9281 distributed message passing. It is focused on real-time operation, but
9282 supports scheduling as well. The execution units, called tasks, are executed
9283 concurrently on a single or more worker servers using multiprocessing,
9284 Eventlet, or gevent. Tasks can execute asynchronously (in the background) or
9285 synchronously (wait until ready).")
9286 (license license:bsd-3)
9287 (properties `((python2-variant . ,(delay python2-celery))))))
9289 (define-public python2-celery
9290 (let ((celery (package-with-python2
9291 (strip-python2-variant python-celery))))
9294 (native-inputs `(("python2-unittest2" ,python2-unittest2)
9295 ("python2-mock" ,python2-mock)
9296 ,@(package-native-inputs celery))))))
9298 (define-public python-translitcodec
9300 (name "python-translitcodec")
9305 (uri (pypi-uri "translitcodec" version))
9308 "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki"))))
9309 (build-system python-build-system)
9311 `(#:tests? #f)) ; no tests provided
9313 "https://github.com/claudep/translitcodec")
9315 "Unicode to 8-bit charset transliteration codec")
9317 "This package contains codecs for transliterating ISO 10646 texts into
9318 best-effort representations using smaller coded character sets (ASCII,
9320 (license license:expat)))
9322 (define-public python2-translitcodec
9323 (package-with-python2 python-translitcodec))
9325 (define-public python-editor
9327 (name "python-editor")
9332 (uri (pypi-uri "python-editor" version))
9335 "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n"))))
9336 (build-system python-build-system)
9338 "https://github.com/fmoo/python-editor")
9340 "Programmatically open an editor, capture the result")
9342 "python-editor is a library that provides the editor module for
9343 programmatically interfacing with your system's $EDITOR.")
9344 (license license:asl2.0)))
9346 (define-public python2-editor
9347 (package-with-python2 python-editor))
9349 (define-public python-vobject
9351 (name "python-vobject")
9355 (uri (pypi-uri "vobject" version))
9358 "0hqjgf3ay1m5w1c0k00g5yfpdz1zni5qnr5rh9b8fg9hjvhwlmhg"))))
9359 (build-system python-build-system)
9361 '(;; The test suite relies on some non-portable Windows interfaces.
9364 `(("python-dateutil" ,python-dateutil)
9365 ("python-pyicu" ,python-pyicu)))
9366 (synopsis "Parse and generate vCard and vCalendar files")
9367 (description "Vobject is intended to be a full featured Python package for
9368 parsing and generating vCard and vCalendar files. Currently, iCalendar files
9369 are supported and well tested. vCard 3.0 files are supported, and all data
9370 should be imported, but only a few components are understood in a sophisticated
9372 (home-page "http://eventable.github.io/vobject/")
9373 (license license:asl2.0)))
9375 (define-public python2-vobject
9376 (package-with-python2 python-vobject))
9378 (define-public python-munkres
9380 (name "python-munkres")
9384 (uri (pypi-uri "munkres" version))
9387 "0mbspx4zv8id4x6pim6ybsa1xh96qwpbqj7skbqz4c9c9nf1lpqq"))))
9388 (build-system python-build-system)
9390 '(#:tests? #f)) ; no test suite
9391 (home-page "http://software.clapper.org/munkres/")
9392 (synopsis "Implementation of the Munkres algorithm")
9393 (description "The Munkres module provides an implementation of the Munkres
9394 algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm),
9395 useful for solving the Assignment Problem.")
9396 (license license:bsd-3)))
9398 (define-public python2-munkres
9399 (package-with-python2 python-munkres))
9401 (define-public python-whoosh
9403 (name "python-whoosh")
9408 (uri (pypi-uri "Whoosh" version))
9411 "10qsqdjpbc85fykc1vgcs8xwbgn4l2l52c8d83xf1q59pwyn79bw"))))
9412 (build-system python-build-system)
9413 (arguments '(#:tests? #f)) ; Test invocation is no longer supported by Python.
9415 `(("python-pytest" ,python-pytest)))
9416 (home-page "https://bitbucket.org/mchaput/whoosh")
9417 (synopsis "Full text indexing, search, and spell checking library")
9419 "Whoosh is a fast, pure-Python full text indexing, search, and spell
9421 (license license:bsd-2)))
9423 (define-public python2-whoosh
9424 (let ((whoosh (package-with-python2 (strip-python2-variant python-whoosh))))
9425 (package (inherit whoosh)
9427 `(("python2-backport-ssl-match-hostname"
9428 ,python2-backport-ssl-match-hostname)
9429 ,@(package-propagated-inputs whoosh))))))
9431 (define-public python-pathlib
9433 (name "python-pathlib")
9437 (uri (pypi-uri "pathlib" version))
9440 "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39"))))
9441 (build-system python-build-system)
9442 ;; The tests depend on the internal "test" module, which does not provide
9443 ;; a stable interface.
9444 (arguments `(#:tests? #f))
9445 (home-page "https://pathlib.readthedocs.org/")
9446 (synopsis "Object-oriented file system paths")
9447 (description "Pathlib offers a set of classes to handle file system paths.
9448 It offers the following advantages over using string objects:
9451 @item No more cumbersome use of os and os.path functions. Everything can
9452 be done easily through operators, attribute accesses, and method calls.
9453 @item Embodies the semantics of different path types. For example,
9454 comparing Windows paths ignores casing.
9455 @item Well-defined semantics, eliminating any inconsistencies or
9456 ambiguities (forward vs. backward slashes, etc.).
9459 Note: In Python 3.4, pathlib is now part of the standard library. For other
9460 Python versions please consider python-pathlib2 instead, which tracks the
9461 standard library module. This module (python-pathlib) isn't maintained
9463 (license license:expat)))
9465 (define-public python2-pathlib
9466 (package-with-python2 python-pathlib))
9468 (define-public python2-pathlib2
9470 (name "python2-pathlib2")
9474 (uri (pypi-uri "pathlib2" version))
9477 "0hpp92vqqgcd8h92msm9slv161b1q160igjwnkf2ag6cx0c96695"))))
9478 (build-system python-build-system)
9479 ;; We only need the the Python 2 variant, since for Python 3 our minimum
9480 ;; version is 3.4 which already includes this package as part of the
9481 ;; standard library.
9483 `(#:python ,python-2))
9485 `(("python2-scandir" ,python2-scandir)
9486 ("python2-six" ,python2-six)))
9487 (home-page "https://pypi.python.org/pypi/pathlib2/")
9488 (synopsis "Object-oriented file system paths - backport of standard
9490 (description "The goal of pathlib2 is to provide a backport of standard
9491 pathlib module which tracks the standard library module, so all the newest
9492 features of the standard pathlib can be used also on older Python versions.
9494 Pathlib offers a set of classes to handle file system paths. It offers the
9495 following advantages over using string objects:
9498 @item No more cumbersome use of os and os.path functions. Everything can
9499 be done easily through operators, attribute accesses, and method calls.
9500 @item Embodies the semantics of different path types. For example,
9501 comparing Windows paths ignores casing.
9502 @item Well-defined semantics, eliminating any inconsistencies or
9503 ambiguities (forward vs. backward slashes, etc.).
9505 (license license:expat)))
9507 (define-public python2-pathlib2-bootstrap
9510 (inherit python2-pathlib2)
9511 (name "python2-pathlib2-bootstrap")
9513 `(("python2-scandir" ,python2-scandir)
9514 ("python2-six" ,python2-six-bootstrap))))))
9516 (define-public python-jellyfish
9518 (name "python-jellyfish")
9522 (uri (pypi-uri "jellyfish" version))
9525 "1j9rplb16ba2prjj6mip46z0w9pnhnqpwgiwi0x93vnas14rlyl8"))))
9526 (build-system python-build-system)
9528 `(("python-pytest" ,python-pytest)))
9529 (home-page "https://github.com/jamesturk/jellyfish")
9530 (synopsis "Approximate and phonetic matching of strings")
9531 (description "Jellyfish uses a variety of string comparison and phonetic
9532 encoding algorithms to do fuzzy string matching.")
9533 (license license:bsd-2)
9534 (properties `((python2-variant . ,(delay python2-jellyfish))))))
9536 (define-public python2-jellyfish
9537 (let ((jellyfish (package-with-python2
9538 (strip-python2-variant python-jellyfish))))
9539 (package (inherit jellyfish)
9540 (native-inputs `(("python2-unicodecsv" ,python2-unicodecsv)
9541 ,@(package-native-inputs jellyfish))))))
9543 (define-public python2-unicodecsv
9545 (name "python2-unicodecsv")
9549 ;; The test suite is not included in the PyPi release.
9550 ;; https://github.com/jdunck/python-unicodecsv/issues/19
9552 (url "https://github.com/jdunck/python-unicodecsv")
9554 (file-name (git-file-name name version))
9557 "15hx2k41a2lpv4hcml9zp4cvlx1171mnb5s4s13xc1pxkq3vgdjy"))))
9558 (build-system python-build-system)
9560 `(;; It supports Python 3, but Python 3 can already do Unicode CSV.
9561 #:python ,python-2))
9563 `(("python2-unittest2" ,python2-unittest2)))
9564 (home-page "https://github.com/jdunck/python-unicodecsv")
9565 (synopsis "Unicode CSV module for Python 2")
9566 (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV
9567 module, adding support for Unicode strings.")
9568 (license license:bsd-2)))
9570 (define-public python-rarfile
9572 (name "python-rarfile")
9576 (uri (pypi-uri "rarfile" version))
9579 "0qfad483kcbga0bn4qmcz953xjk16r52fahiy46zzn56v80y89ra"))))
9580 (build-system python-build-system)
9583 (modify-phases %standard-phases
9585 ;; Many tests fail, but the installation proceeds.
9586 (lambda _ (invoke "make" "-C" "test" "test"))))))
9588 `(("which" ,which))) ; required for tests
9590 `(("libarchive" ,libarchive)))
9591 (home-page "https://github.com/markokr/rarfile")
9592 (synopsis "RAR archive reader for Python")
9593 (description "This is Python module for RAR archive reading. The interface
9594 is made as zipfile like as possible.")
9595 (license license:isc)))
9597 (define-public python2-rarfile
9598 (package-with-python2 python-rarfile))
9600 (define-public python-magic
9602 (name "python-magic")
9607 (uri (pypi-uri "python-magic" version))
9610 "1mgwig9pnzgkf86q9ji9pnc99bngms15lfszq5rgqb9db07mqxpk"))
9611 (file-name (string-append name "-" version "-checkout"))))
9612 (build-system python-build-system)
9614 ;; The tests are unreliable, so don't run them. The tests fail
9615 ;; under Python3 because they were written for Python2 and
9616 ;; contain import statements that do not work in Python3. One of
9617 ;; the tests fails under Python2 because its assertions are
9618 ;; overly stringent; it relies on comparing output strings which
9619 ;; are brittle and can change depending on the version of
9620 ;; libmagic being used and the system on which the test is
9621 ;; running. In my case, under GuixSD 0.10.0, only one test
9622 ;; failed, and it seems to have failed only because the version
9623 ;; of libmagic that is packaged in Guix outputs a slightly
9624 ;; different (but not wrong) string than the one that the test
9627 #:phases (modify-phases %standard-phases
9628 ;; Replace a specific method call with a hard-coded
9629 ;; path to the necessary libmagic.so file in the
9630 ;; store. If we don't do this, then the method call
9631 ;; will fail to find the libmagic.so file, which in
9632 ;; turn will cause any application using
9633 ;; python-magic to fail.
9634 (add-before 'build 'hard-code-path-to-libmagic
9635 (lambda* (#:key inputs #:allow-other-keys)
9636 (let ((file (assoc-ref inputs "file")))
9637 (substitute* "magic.py"
9638 (("ctypes.util.find_library\\('magic'\\)")
9639 (string-append "'" file "/lib/libmagic.so'")))
9641 (add-before 'install 'disable-egg-compression
9643 (let ((port (open-file "setup.cfg" "a")))
9644 (display "\n[easy_install]\nzip_ok = 0\n"
9649 ;; python-magic needs to be able to find libmagic.so.
9652 "https://github.com/ahupp/python-magic")
9654 "File type identification using libmagic")
9656 "This module uses ctypes to access the libmagic file type
9657 identification library. It makes use of the local magic database and
9658 supports both textual and MIME-type output. Note that this module and
9659 the python-file module both provide a \"magic.py\" file; these two
9660 modules, which are different and were developed separately, both serve
9661 the same purpose: to provide Python bindings for libmagic.")
9662 (license license:expat)))
9664 (define-public python2-magic
9665 (package-with-python2 python-magic))
9667 (define-public python2-s3cmd
9669 (name "python2-s3cmd")
9674 (uri (string-append "mirror://sourceforge/s3tools/s3cmd/" version "/"
9675 "s3cmd-" version ".tar.gz"))
9678 "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6"))))
9679 (build-system python-build-system)
9681 ;; s3cmd is written for python2 only and contains no tests.
9682 `(#:python ,python-2
9685 `(("python2-dateutil" ,python2-dateutil)
9686 ;; The python-file package also provides a magic.py module.
9687 ;; This is an unfortunate state of affairs; however, s3cmd
9688 ;; fails to install if it cannot find specifically the
9689 ;; python-magic package. Thus we include it, instead of using
9690 ;; python-file. Ironically, s3cmd sometimes works better
9691 ;; without libmagic bindings at all:
9692 ;; https://github.com/s3tools/s3cmd/issues/198
9693 ("python2-magic" ,python2-magic)))
9694 (home-page "http://s3tools.org/s3cmd")
9695 (synopsis "Command line tool for S3-compatible storage services")
9697 "S3cmd is a command line tool for uploading, retrieving and managing data
9698 in storage services that are compatible with the Amazon Simple Storage
9699 Service (S3) protocol, including S3 itself. It supports rsync-like backup,
9700 GnuPG encryption, and more. It also supports management of Amazon's
9701 CloudFront content delivery network.")
9702 (license license:gpl2+)))
9704 (define-public python-pkgconfig
9706 (name "python-pkgconfig")
9711 (uri (pypi-uri "pkgconfig" version))
9714 "107x2wmchlch8saixb488cgjz9n6inl38wi7nxkb942rbaapxiqb"))))
9715 (build-system python-build-system)
9717 `(("python-nose" ,python-nose)))
9719 `(("pkg-config" ,pkg-config)))
9722 (modify-phases %standard-phases
9723 (add-before 'build 'patch
9724 ;; Hard-code the path to pkg-config.
9726 (substitute* "pkgconfig/pkgconfig.py"
9727 (("cmd = 'pkg-config")
9728 (string-append "cmd = '" (which "pkg-config"))))
9732 (invoke "nosetests" "test.py"))))))
9733 (home-page "https://github.com/matze/pkgconfig")
9734 (synopsis "Python interface for pkg-config")
9735 (description "This module provides a Python interface to pkg-config. It
9736 can be used to find all pkg-config packages, check if a package exists,
9737 check if a package meets certain version requirements, query CFLAGS and
9738 LDFLAGS and parse the output to build extensions with setup.py.")
9739 (license license:expat)))
9741 (define-public python2-pkgconfig
9742 (package-with-python2 python-pkgconfig))
9744 (define-public python-bz2file
9746 (name "python-bz2file")
9751 (uri (pypi-uri "bz2file" version))
9754 "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4"))))
9755 (build-system python-build-system)
9757 `(#:tests? #f)) ; Tests use deprecated python modules.
9758 (home-page "https://github.com/nvawda/bz2file")
9759 (synopsis "Read and write bzip2-compressed files")
9761 "Bz2file is a Python library for reading and writing bzip2-compressed
9762 files. It contains a drop-in replacement for the I/O interface in the
9763 standard library's @code{bz2} module, including features from the latest
9764 development version of CPython that are not available in older releases.")
9765 (license license:asl2.0)))
9767 (define-public python2-bz2file
9768 (package-with-python2 python-bz2file))
9770 (define-public python-future
9772 (name "python-future")
9777 (uri (pypi-uri "future" version))
9780 "1f2rlqn9rh7adgir52dlbqz69gsab44x0mlm8gf1cs7xvhv54137"))))
9781 (build-system python-build-system)
9782 ;; Many tests connect to the network or are otherwise flawed.
9783 ;; https://github.com/PythonCharmers/python-future/issues/210
9786 (home-page "http://python-future.org")
9787 (synopsis "Single-source support for Python 3 and 2")
9789 "@code{python-future} is the missing compatibility layer between Python 2 and
9790 Python 3. It allows you to use a single, clean Python 3.x-compatible codebase
9791 to support both Python 2 and Python 3 with minimal overhead.")
9792 (license license:expat)))
9794 (define-public python2-future
9795 (package-with-python2 python-future))
9797 (define-public python-cysignals
9799 (name "python-cysignals")
9804 (uri (pypi-uri "cysignals" version))
9807 "15ix8crpad26cfl1skyg7qajqqfdrm8q5ahhmlfmqi1aw0jqj2g2"))))
9808 (build-system python-build-system)
9810 `(("python-cython" ,python-cython)
9811 ("python-sphinx" ,python-sphinx)))
9813 `(("pari-gp" ,pari-gp)))
9815 `(#:modules ((guix build python-build-system)
9816 ((guix build gnu-build-system) #:prefix gnu:)
9818 ;; FIXME: Tests are executed after installation and currently fail
9819 ;; when not installing into standard locations; the author is working
9823 (modify-phases %standard-phases
9826 (assoc-ref gnu:%standard-phases 'configure)))))
9828 "https://github.com/sagemath/cysignals")
9830 "Handling of interrupts and signals for Cython")
9832 "The cysignals package provides mechanisms to handle interrupts (and
9833 other signals and errors) in Cython code, using two related approaches,
9834 for mixed Cython/Python code or external C libraries and pure Cython code,
9836 (license license:lgpl3+)))
9838 (define-public python2-cysignals
9839 (package-with-python2 python-cysignals))
9841 (define-public python2-shedskin
9843 (name "python2-shedskin")
9848 (uri (string-append "https://github.com/shedskin/shedskin/"
9849 "releases/download/v" version
9850 "/shedskin-" version ".tgz"))
9853 "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41"))))
9854 (build-system python-build-system)
9856 `(#:python ,python-2
9857 #:phases (modify-phases %standard-phases
9858 (add-after 'unpack 'fix-resulting-include-libs
9859 (lambda* (#:key inputs #:allow-other-keys)
9860 (let ((libgc (assoc-ref inputs "libgc"))
9861 (pcre (assoc-ref inputs "pcre")))
9862 (substitute* "shedskin/makefile.py"
9863 (("variable == 'CCFLAGS':[ ]*")
9864 (string-append "variable == 'CCFLAGS':\n"
9865 " line += ' -I " pcre "/include"
9866 " -I " libgc "/include'"))
9867 (("variable == 'LFLAGS':[ ]*")
9868 (string-append "variable == 'LFLAGS':\n"
9869 " line += ' -L" pcre "/lib"
9870 " -L " libgc "/lib'")))
9872 (inputs `(("pcre" ,pcre)
9874 (home-page "https://shedskin.github.io/")
9875 (synopsis "Experimental Python-2 to C++ Compiler")
9876 (description (string-append "This is an experimental compiler for a subset of
9877 Python. It generates C++ code and a Makefile."))
9878 (license (list license:gpl3 license:bsd-3 license:expat))))
9880 (define-public python2-rope
9882 (name "python2-rope")
9887 (uri (pypi-uri "rope" version))
9890 "1cppm0pa9aqgsbkq130lskrzmrvjs5vpiavjjbhpz2fdw52w8251"))))
9892 ;; Rope has only partial python3 support, see `python-rope'
9893 `(#:python ,python-2))
9894 (build-system python-build-system)
9896 `(("python2-unittest2" ,python2-unittest2)))
9897 (home-page "https://github.com/python-rope/rope")
9898 (synopsis "Refactoring library for Python")
9899 (description "Rope is a refactoring library for Python. It facilitates
9900 the renaming, moving and extracting of attributes, functions, modules, fields
9901 and parameters in Python 2 source code. These refactorings can also be applied
9902 to occurrences in strings and comments.")
9903 (license license:gpl2)))
9905 (define-public python-rope
9907 (inherit python2-rope)
9908 (name "python-rope")
9909 (arguments `(#:python ,python-wrapper
9910 ;; XXX: Only partial python3 support, results in some failing
9911 ;; tests: <https://github.com/python-rope/rope/issues/247>.
9913 (properties `((python2-variant . ,(delay python2-rope))))))
9915 (define-public python-py3status
9917 (name "python-py3status")
9922 (uri (pypi-uri "py3status" version))
9924 (base32 "16z8zq83hxy48g6hh4xczbdz50qvxv9k1aahr4fqq7jis60cc262"))))
9925 (build-system python-build-system)
9930 (modify-phases %standard-phases
9931 ;; 'file' is used for detection of configuration file encoding
9932 ;; let's make link the dependency to particular input
9933 (add-before 'build 'patch-file-path
9934 (lambda* (#:key inputs #:allow-other-keys)
9935 (let ((file-path (assoc-ref inputs "file")))
9936 (substitute* "py3status/parse_config.py"
9937 (("\\[\"file\", \"-b\"")
9938 (string-append "['" file-path "/bin/file', '-b'")))
9940 #:tests? #f)) ; TODO: Requires many libraries not in Guix.
9941 (home-page "https://github.com/ultrabug/py3status")
9942 (synopsis "Extensible i3status wrapper written in Python")
9943 (description "py3status is an i3status wrapper which extends i3status
9944 functionality in a modular way, allowing you to extend your panel with your
9945 own code, responding to click events and updating clock every second.")
9946 (license license:bsd-3)))
9948 (define-public python-tblib
9950 (name "python-tblib")
9954 (uri (pypi-uri "tblib" version))
9956 "1rsg8h069kqgncyv8fgzyj6qflk6j10cb78pa5jk34ixwq044vj3"))))
9957 (build-system python-build-system)
9960 (modify-phases %standard-phases
9961 (add-before 'check 'adjust-tests
9963 (when (which "python3")
9964 ;; Adjust the example output to match that of Python 3.7:
9965 ;; <https://github.com/ionelmc/python-tblib/issues/36>.
9966 (substitute* "README.rst"
9967 (("Exception\\('fail',") "Exception('fail'"))
9971 ;; Upstream runs tests after installation and the package itself
9972 ;; resides in a subdirectory. Extend PYTHONPATH so it will be
9974 (setenv "PYTHONPATH"
9975 (string-append (getcwd) "/build/lib:"
9976 (getenv "PYTHONPATH")))
9977 (invoke "py.test" "-vv" "tests" "README.rst"))))))
9979 `(("python-pytest" ,python-pytest)
9980 ("python-six" ,python-six)))
9981 (home-page "https://github.com/ionelmc/python-tblib")
9982 (synopsis "Traceback serialization library")
9984 "Traceback serialization allows you to:
9987 @item Pickle tracebacks and raise exceptions with pickled tracebacks in
9988 different processes. This allows better error handling when running code over
9989 multiple processes (imagine multiprocessing, billiard, futures, celery etc).
9991 @item Parse traceback strings and raise with the parsed tracebacks.
9993 (license license:bsd-3)))
9995 (define-public python2-tblib
9996 (package-with-python2 python-tblib))
9998 (define-public python-greenlet
10000 (name "python-greenlet")
10004 (uri (pypi-uri "greenlet" version))
10007 "1g4g1wwc472ds89zmqlpyan3fbnzpa8qm48z3z1y6mlk44z485ll"))))
10008 (build-system python-build-system)
10009 (home-page "https://greenlet.readthedocs.io/")
10010 (synopsis "Lightweight in-process concurrent programming")
10012 "Greenlet package is a spin-off of Stackless, a version of CPython
10013 that supports micro-threads called \"tasklets\". Tasklets run
10014 pseudo-concurrently (typically in a single or a few OS-level threads) and
10015 are synchronized with data exchanges on \"channels\".")
10016 (license (list license:psfl license:expat))))
10018 (define-public python2-greenlet
10019 (package-with-python2 python-greenlet))
10021 (define-public python-objgraph
10023 (name "python-objgraph")
10028 (uri (pypi-uri "objgraph" version))
10031 "19qmqsh984zq1rzzjy4vqnmviaqnymcyl8h7z99pnicbgwnm2adz"))))
10032 (build-system python-build-system)
10034 `(("python-graphviz" ,python-graphviz)))
10036 `(("python-mock" ,python-mock)
10037 ("graphviz" ,graphviz)))
10038 (home-page "https://mg.pov.lt/objgraph/")
10039 (synopsis "Draw Python object reference graphs with graphviz")
10041 "This package provides tools to draw Python object reference graphs with
10043 (license license:expat)))
10045 (define-public python2-objgraph
10046 (package-with-python2 python-objgraph))
10048 (define-public python-gevent
10050 (name "python-gevent")
10054 (uri (pypi-uri "gevent" version))
10057 "0b0fr04qdk1p4sniv87fh8z5psac60x01pv054kpgi94520g81iz"))
10058 (modules '((guix build utils)))
10061 ;; unbunding libev and c-ares
10062 (delete-file-recursively "deps")
10064 (build-system python-build-system)
10066 `(#:modules ((ice-9 ftw)
10070 (guix build python-build-system))
10071 #:phases (modify-phases %standard-phases
10072 (add-before 'patch-source-shebangs 'patch-hard-coded-paths
10074 (substitute* "src/gevent/subprocess.py"
10075 (("/bin/sh") (which "sh")))
10076 (for-each (lambda (file)
10078 (("/bin/sh") (which "sh"))
10079 (("/bin/true") (which "true"))))
10080 (find-files "src/greentest" "\\.py$"))
10082 (add-before 'build 'do-not-use-bundled-sources
10083 (lambda* (#:key inputs #:allow-other-keys)
10084 (setenv "CONFIG_SHELL" (which "bash"))
10085 (setenv "LIBEV_EMBED" "false")
10086 (setenv "CARES_EMBED" "false")
10087 (setenv "EMBED" "false")
10089 ;; Prevent building bundled libev.
10090 (substitute* "setup.py"
10091 (("run_make=_BUILDING")
10094 (let ((greenlet (string-append
10095 (assoc-ref inputs "python-greenlet")
10097 (match (scandir greenlet
10099 (string-prefix? "python" item)))
10101 (setenv "C_INCLUDE_PATH"
10102 (string-append greenlet "/" python)))))
10104 (add-before 'check 'skip-timer-test
10106 ;; XXX: Skip 'TestTimerResolution', which appears to be
10108 (substitute* "src/greentest/test__core_timer.py"
10109 (("not greentest.RUNNING_ON_CI") "False"))
10113 ;; Make sure the build directory is on PYTHONPATH.
10114 (setenv "PYTHONPATH"
10116 (getenv "PYTHONPATH") ":"
10118 (car (scandir "build" (cut string-prefix? "lib." <>)))))
10119 (with-directory-excursion "src/greentest"
10120 ;; XXX: Many tests require network access. Instead we only
10121 ;; run known-good tests. Unfortunately we cannot use
10122 ;; recursion here since this directory also contains
10123 ;; Python-version-specific subfolders.
10124 (apply invoke "python" "testrunner.py" "--config"
10125 "known_failures.py"
10126 (scandir "." (cut regexp-exec
10127 (make-regexp "test_+(subprocess|core)")
10130 `(("python-greenlet" ,python-greenlet)
10131 ("python-objgraph" ,python-objgraph)))
10133 `(("python-six" ,python-six)))
10135 `(("c-ares" ,c-ares)
10137 (home-page "http://www.gevent.org/")
10138 (synopsis "Coroutine-based network library")
10140 "gevent is a coroutine-based Python networking library that uses greenlet
10141 to provide a high-level synchronous API on top of the libev event loop.")
10142 (license license:expat)
10143 (properties `((python2-variant . ,(delay python2-gevent))))))
10145 (define-public python2-gevent
10146 (let ((base (package-with-python2
10147 (strip-python2-variant python-gevent))))
10150 (native-inputs `(,@(package-native-inputs python-gevent)
10151 ("python-mock" ,python2-mock))))))
10153 (define-public python-fastimport
10155 (name "python-fastimport")
10160 (uri (pypi-uri "fastimport" version))
10162 (base32 "1aqjsin4rmqm7ln4j0p73fzxifws6c6ikgyhav7r137m2ixsxl43"))))
10163 (build-system python-build-system)
10164 (home-page "https://github.com/jelmer/python-fastimport")
10165 (synopsis "VCS fastimport parser and generator in Python")
10166 (description "This package provides a parser for and generator of the Git
10167 @url{https://www.kernel.org/pub/software/scm/git/docs/git-fast-import.html,fastimport}
10169 (license license:gpl2+)))
10171 (define-public python2-fastimport
10172 (package-with-python2 python-fastimport))
10174 (define-public python-twisted
10176 (name "python-twisted")
10180 (uri (pypi-uri "Twisted" version ".tar.bz2"))
10183 "17d3hnxv9qndagzz63mdpyk99xj63p9gq586vjn0rxk8cl197nym"))))
10184 (build-system python-build-system)
10186 '(#:tests? #f)) ; FIXME: some tests fail
10188 `(("python-zope-interface" ,python-zope-interface)
10189 ("python-pyhamcrest" ,python-pyhamcrest)
10190 ("python-incremental" ,python-incremental)
10191 ("python-hyperlink" ,python-hyperlink)
10192 ("python-constantly" ,python-constantly)
10193 ("python-automat" ,python-automat)))
10194 (home-page "https://twistedmatrix.com/")
10195 (synopsis "Asynchronous networking framework written in Python")
10197 "Twisted is an extensible framework for Python programming, with special
10198 focus on event-based network programming and multiprotocol integration.")
10199 (license license:expat)))
10201 (define-public python2-twisted
10202 (package-with-python2 python-twisted))
10204 (define-public python-pika
10206 (name "python-pika")
10211 (uri (pypi-uri "pika" version))
10214 "0ld7akgm93s8pfa4dsx9qlzlhj76zspbr5m9ms0ns09yd2w4aq9h"))))
10215 (build-system python-build-system)
10217 `(("python-pyev" ,python-pyev)
10218 ("python-tornado" ,python-tornado)
10219 ("python-twisted" ,python-twisted)))
10220 (home-page "https://pika.readthedocs.org")
10221 (synopsis "Pure Python AMQP Client Library")
10223 "Pika is a pure-Python implementation of the AMQP (Advanced Message Queuing
10224 Protocol) 0-9-1 protocol that tries to stay fairly independent of the underlying
10225 network support library.")
10226 (license license:bsd-3)))
10228 (define-public python2-pika
10229 (package-with-python2 python-pika))
10231 (define-public python-ply
10233 (name "python-ply")
10238 (uri (pypi-uri "ply" version))
10241 "1jxsr1d2f732r6ljhvm827113dckwl6qwakfvpbdhcbhvpvlmscn"))))
10242 (build-system python-build-system)
10243 (home-page "http://www.dabeaz.com/ply/")
10244 (synopsis "Python Lex & Yacc")
10245 (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python.
10246 It uses LR parsing and does extensive error checking.")
10247 (license license:bsd-3)))
10249 (define-public python2-ply
10250 (package-with-python2 python-ply))
10252 (define-public python-tabulate
10254 (name "python-tabulate")
10258 (uri (pypi-uri "tabulate" version))
10261 "1inqhspd4frxnp08c32yndr0lc4px1xfkqah184i5w09gkhvi843"))))
10262 (build-system python-build-system)
10264 ;; FIXME: The pypi release tarball is missing a 'test/common.py'
10265 ;; and the latest release is not tagged in the upstream repository.
10267 (home-page "https://bitbucket.org/astanin/python-tabulate")
10268 (synopsis "Pretty-print tabular data")
10270 "Tabulate is a library and command-line utility to pretty-print tabular
10272 (license license:expat)))
10274 (define-public python2-tabulate
10275 (package-with-python2 python-tabulate))
10277 (define-public python-kazoo
10279 (name "python-kazoo")
10284 (uri (pypi-uri "kazoo" version))
10287 "16y213k7r8shyn2zw1k6lkzjgcrvm441pqv8scvcjixhvpbx3hm7"))))
10288 (build-system python-build-system)
10289 (arguments '(#:tests? #f)) ; XXX: needs zookeeper
10291 `(("python-six" ,python-six)))
10292 (home-page "https://kazoo.readthedocs.org")
10293 (synopsis "High-level Zookeeper client library")
10295 "Kazoo is a Python client library for the Apache Zookeeper distributed
10296 application service. It is designed to be easy to use and to avoid common
10297 programming errors.")
10298 (license license:asl2.0)))
10300 (define-public python2-kazoo
10301 (package-with-python2 python-kazoo))
10303 (define-public python-pykafka
10305 (name "python-pykafka")
10309 (uri (pypi-uri "pykafka" version))
10312 "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv"))))
10313 (build-system python-build-system)
10314 (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc.
10316 `(("python-gevent" ,python-gevent)
10317 ("python-kazoo" ,python-kazoo)
10318 ("python-tabulate" ,python-tabulate)))
10320 `(("librdkafka" ,librdkafka)))
10321 (home-page "https://pykafka.readthedocs.io/")
10322 (synopsis "Apache Kafka client for Python")
10324 "PyKafka is a client for the Apache Kafka distributed messaging system.
10325 It includes Python implementations of Kafka producers and consumers, which
10326 are optionally backed by a C extension built on librdkafka.")
10327 (license license:asl2.0)))
10329 (define-public python2-pykafka
10330 (package-with-python2 python-pykafka))
10332 (define-public python-wcwidth
10334 (name "python-wcwidth")
10338 (uri (pypi-uri "wcwidth" version))
10341 "1a1pzds3xzfylm5mnc5f6c1p8kiig0daqjc9gygd9rc3cj53x2zj"))))
10342 (build-system python-build-system)
10343 (home-page "https://github.com/jquast/wcwidth")
10344 (synopsis "Measure number of terminal column cells of wide-character codes")
10345 (description "Wcwidth measures the number of terminal column cells of
10346 wide-character codes. It is useful for those implementing a terminal emulator,
10347 or programs that carefully produce output to be interpreted by one. It is a
10348 Python implementation of the @code{wcwidth} and @code{wcswidth} C functions
10349 specified in POSIX.1-2001 and POSIX.1-2008.")
10350 (license license:expat)))
10352 (define-public python2-wcwidth
10353 (package-with-python2 python-wcwidth))
10355 (define-public python2-jsonrpclib
10357 (name "python2-jsonrpclib")
10361 (uri (pypi-uri "jsonrpclib" version))
10364 "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z"))))
10365 (build-system python-build-system)
10368 #:python ,python-2))
10369 (home-page "https://github.com/joshmarshall/jsonrpclib/")
10370 (synopsis "Implementation of JSON-RPC specification for Python")
10372 "This library is an implementation of the JSON-RPC specification.
10373 It supports both the original 1.0 specification, as well as the
10374 new (proposed) 2.0 spec, which includes batch submission, keyword arguments,
10376 (license license:asl2.0)))
10378 (define-public python-chai
10380 (name "python-chai")
10384 (uri (pypi-uri "chai" version))
10387 "1k6n6zbgrrs83crp6mr3yqj9zlv40b8rpisyrliwsq7naml2p3gz"))))
10388 (build-system python-build-system)
10389 (home-page "https://github.com/agoragames/chai")
10390 (synopsis "Mocking framework for Python")
10392 "Chai provides an api for mocking, stubbing and spying your python
10393 objects, patterned after the Mocha library for Ruby.")
10394 (license license:bsd-3)))
10396 (define-public python2-chai
10397 (package-with-python2 python-chai))
10399 (define-public python-inflection
10401 (name "python-inflection")
10404 (origin (method url-fetch)
10405 (uri (pypi-uri "inflection" version))
10408 "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq"))))
10409 (build-system python-build-system)
10411 `(("python-pytest" ,python-pytest)))
10412 (home-page "https://github.com/jpvanhal/inflection")
10413 (synopsis "Python string transformation library")
10415 "Inflection is a string transformation library. It singularizes
10416 and pluralizes English words, and transforms strings from CamelCase to
10417 underscored string.")
10418 (license license:expat)))
10420 (define-public python2-inflection
10421 (package-with-python2 python-inflection))
10423 (define-public python-pylev
10425 (name "python-pylev")
10429 (uri (pypi-uri "pylev" version))
10432 "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86"))))
10433 (build-system python-build-system)
10434 (home-page "https://github.com/toastdriven/pylev")
10435 (synopsis "Levenshtein distance implementation in Python")
10436 (description "Pure Python Levenshtein implementation, based off the
10437 Wikipedia code samples at
10438 @url{http://en.wikipedia.org/wiki/Levenshtein_distance}.")
10439 (license license:bsd-3)))
10441 (define-public python2-pylev
10442 (package-with-python2 python-pylev))
10444 (define-public python-cleo
10446 (name "python-cleo")
10450 (uri (pypi-uri "cleo" version))
10453 "06zp695hq835rkaq6irr1ds1dp2qfzyf32v60vxpd8rcnxv319l5"))))
10454 (build-system python-build-system)
10457 ("python-mock" ,python-mock)
10458 ("python-pytest-mock" ,python-pytest-mock)
10459 ("python-pytest" ,python-pytest)))
10461 `(("python-backpack" ,python-backpack)
10462 ("python-pastel" ,python-pastel)
10463 ("python-pylev" ,python-pylev)))
10464 (home-page "https://github.com/sdispater/cleo")
10465 (synopsis "Command-line arguments library for Python")
10467 "Cleo allows you to create command-line commands with signature in
10468 docstring and colored output.")
10469 (license license:expat)))
10471 (define-public python2-cleo
10472 (package-with-python2 python-cleo))
10474 (define-public python-tomlkit
10476 (name "python-tomlkit")
10481 (uri (pypi-uri "tomlkit" version))
10484 "18820ga5z3if1w8dvykxrfm000akracq01ic402xrbljgbn5grn4"))))
10485 (build-system python-build-system)
10487 `(("python-pytest" ,python-pytest)))
10489 "https://github.com/sdispater/tomlkit")
10490 (synopsis "Style preserving TOML library")
10492 "TOML Kit is a 0.5.0-compliant TOML library. It includes a parser that
10493 preserves all comments, indentations, whitespace and internal element ordering,
10494 and makes them accessible and editable via an intuitive API. It can also
10495 create new TOML documents from scratch using the provided helpers. Part of the
10496 implementation as been adapted, improved and fixed from Molten.")
10497 (license license:expat)))
10499 (define-public python-shellingham
10501 (name "python-shellingham")
10506 (uri (pypi-uri "shellingham" version))
10509 "1q7kws7w4x2hji3g7y0ni9ddk4sd676ylrb3db54gbpys6xj6nwq"))))
10510 (build-system python-build-system)
10512 "https://github.com/sarugaku/shellingham")
10513 (synopsis "Tool to detect surrounding shell")
10515 "Shellingham detects what shell the current Python executable is
10517 (license license:isc)))
10519 (define-public python-memcached
10521 (name "python-memcached")
10526 (uri (pypi-uri "python-memcached" version))
10529 "0kvyapavbirk2x3n1jx4yb9nyigrj1s3x15nm3qhpvhkpqvqdqm2"))))
10530 (build-system python-build-system)
10531 (propagated-inputs `(("python-six" ,python-six)))
10533 "https://github.com/linsomniac/python-memcached")
10534 (synopsis "Pure python memcached client")
10536 "This software is a pure Python interface to the memcached memory cache
10537 daemon. It is the client side software which allows storing values in one or
10538 more, possibly remote, memcached servers.")
10539 (license license:psfl)))
10541 (define-public python-clikit
10543 (name "python-clikit")
10548 (uri (pypi-uri "clikit" version))
10551 "0dc8czib5f4j9px1ivcpqnmivnx2zjpc0xb00ldrhsqylks7r06n"))))
10552 (build-system python-build-system)
10554 `(("python-pastel" ,python-pastel)
10555 ("python-pylev" ,python-pylev)))
10556 (home-page "https://github.com/sdispater/clikit")
10557 (synopsis "Group of utilities to build command line interfaces")
10559 "CliKit is a group of utilities to build testable command line
10561 (license license:expat)))
10563 (define-public python-msgpack-python
10565 (name "python-msgpack-python")
10570 (uri (pypi-uri "msgpack-python" version))
10573 "16wh8qgybmfh4pjp8vfv78mdlkxfmcasg78lzlnm6nslsfkci31p"))))
10574 (build-system python-build-system)
10575 (home-page "http://msgpack.org/")
10576 (synopsis "Package to deserialize messages in MessagePack binary format")
10578 "MessagePack is an efficient binary serialization format. It lets you
10579 exchange data among multiple languages like JSON. But it's faster and
10580 smaller. Small integers are encoded into a single byte, and typical short
10581 strings require only one extra byte in addition to the strings themselves.")
10582 (license license:asl2.0)))
10584 (define-public python-cachy
10586 (name "python-cachy")
10591 (uri (pypi-uri "cachy" version))
10594 "0v6mjyhgx6j7ya20bk69cr3gdzdkdf6psay0h090rscclgji65dp"))))
10595 (build-system python-build-system)
10597 `(("python-fakeredis" ,python-fakeredis)
10598 ("python-flexmock" ,python-flexmock)
10599 ("python-pytest" ,python-pytest)))
10601 `(("python-memcached" ,python-memcached)
10602 ("python-msgpack-python" ,python-msgpack-python)
10603 ("python-redis" ,python-redis)))
10604 (home-page "https://github.com/sdispater/cachy")
10605 (synopsis "Simple yet effective caching library")
10607 "Cachy provides a simple yet effective caching library. A simple but
10608 powerful API: thread-safety; decorator syntax; support for memcached, redis,
10609 database, file, dict stores. Cachy supports python versions 2.7+ and 3.2+.")
10610 (license license:expat)))
10612 (define-public poetry
10615 (version "0.12.17")
10616 ;; Poetry can only be built from source with poetry.
10620 (uri (pypi-uri "poetry" version))
10623 "0gxwcd65qjmzqzppf53x51sic1rbcd9py6cdzx3aprppipimslvf"))))
10624 (build-system python-build-system)
10626 `(#:tests? #f ;; Pypi does not have tests.
10628 (modify-phases %standard-phases
10631 ;; Bug in poetry https://github.com/sdispater/poetry/issues/866.
10632 (invoke "sed" "-i" "-e" "s/from distutils.core/from setuptools/"
10636 `(("python-cachecontrol" ,python-cachecontrol)
10637 ("python-cachy" ,python-cachy)
10638 ("python-cleo" ,python-cleo)
10639 ("python-glob2" ,python-glob2)
10640 ("python-html5lib" ,python-html5lib)
10641 ("python-jsonschema" ,python-jsonschema)
10642 ("python-msgpack" ,python-msgpack)
10643 ("python-pkginfo" ,python-pkginfo)
10644 ("python-pyparsing" ,python-pyparsing)
10645 ("python-pyrsistent" ,python-pyrsistent)
10646 ("python-requests" ,python-requests)
10647 ("python-requests-toolbelt" ,python-requests-toolbelt)
10648 ("python-shellingham" ,python-shellingham)
10649 ("python-tomlkit" ,python-tomlkit)
10650 ("python-virtualenv" ,python-virtualenv)))
10651 (home-page "https://poetry.eustace.io/")
10652 (synopsis "Python dependency management and packaging made easy")
10653 (description "Poetry is a tool for dependency management and packaging
10654 in Python. It allows you to declare the libraries your project depends on and
10655 it will manage (install/update) them for you.")
10656 (license license:expat)))
10658 (define-public python-lazy-object-proxy
10660 (name "python-lazy-object-proxy")
10664 (uri (pypi-uri "lazy-object-proxy" version))
10667 "1w1aaay424ciz8fz3fkzxb0pxzfxn184f2whpyn4fx72bn50x47k"))))
10669 `(("python-setuptools-scm" ,python-setuptools-scm-3.3)))
10670 (build-system python-build-system)
10671 (home-page "https://github.com/ionelmc/python-lazy-object-proxy")
10672 (synopsis "Lazy object proxy for python")
10674 "Lazy object proxy is an object that wraps a callable but defers the call
10675 until the object is actually required, and caches the result of said call.")
10676 (license license:bsd-2)))
10678 (define-public python2-lazy-object-proxy
10679 (package-with-python2 python-lazy-object-proxy))
10681 (define-public python-dnspython
10683 (name "python-dnspython")
10687 (uri (string-append "http://www.dnspython.org/kits/"
10688 version "/dnspython-" version ".tar.gz"))
10691 "0jr4v2pd90i6l1xxbss2m05psbjaxvyvvvpq44wycijpfgjqln8i"))))
10692 (build-system python-build-system)
10693 (arguments '(#:tests? #f)) ; XXX: requires internet access
10694 (home-page "http://www.dnspython.org")
10695 (synopsis "DNS toolkit for Python")
10697 "dnspython is a DNS toolkit for Python. It supports almost all record
10698 types. It can be used for queries, zone transfers, and dynamic updates.
10699 It supports TSIG authenticated messages and EDNS0.")
10700 (license license:expat)))
10702 (define-public python2-dnspython
10703 (package-with-python2 python-dnspython))
10705 (define-public python-email-validator
10707 (name "python-email-validator")
10710 (origin (method url-fetch)
10711 (uri (pypi-uri "email_validator" version))
10714 "1ja9149l9ck5n45a72h3is7v476hjny5ybxbcamx1nw6iplsm7k6"))))
10715 (build-system python-build-system)
10718 (modify-phases %standard-phases
10719 (add-before 'build 'use-dnspython
10721 (substitute* "setup.py"
10722 (("dnspython3") "dnspython"))
10725 `(("python-dnspython" ,python-dnspython)
10726 ("python-idna" ,python-idna)))
10727 (home-page "https://github.com/JoshData/python-email-validator")
10728 (synopsis "Email address validation library for Python")
10730 "This library validates email address syntax and deliverability.")
10731 (license license:cc0)))
10733 (define-public python2-email-validator
10734 (package-with-python2 python-email-validator))
10736 (define-public python-ukpostcodeparser
10738 (name "python-ukpostcodeparser")
10742 (uri (pypi-uri "UkPostcodeParser" version))
10745 "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd"))))
10746 (build-system python-build-system)
10747 (home-page "https://github.com/hamstah/ukpostcodeparser")
10748 (synopsis "UK Postcode parser for Python")
10750 "This library provides the @code{parse_uk_postcode} function for
10751 parsing UK postcodes.")
10752 (license license:expat)))
10754 (define-public python2-ukpostcodeparser
10755 (package-with-python2 python-ukpostcodeparser))
10757 (define-public python-faker
10759 (name "python-faker")
10763 (uri (pypi-uri "Faker" version))
10766 "1fh2p2yz0fsdr4fqwxgddwbvfb6qn6vp8yx0qwqzra27yq5d1wsm"))
10768 (search-patches "python-faker-fix-build-32bit.patch"))
10769 (modules '((guix build utils)))
10772 (for-each delete-file (find-files "." "\\.pyc$"))
10774 (build-system python-build-system)
10777 (modify-phases %standard-phases
10779 (lambda _ (invoke "python" "-m" "unittest" "-v" "tests"))))))
10782 ("python-email-validator" ,python-email-validator)
10783 ("python-mock" ,python-mock)
10784 ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
10786 `(("python-dateutil" ,python-dateutil)
10787 ("python-six" ,python-six)))
10788 (home-page "https://github.com/joke2k/faker")
10789 (synopsis "Python package that generates fake data")
10791 "Faker is a Python package that generates fake data such as names,
10792 addresses, and phone numbers.")
10793 (license license:expat)
10794 (properties `((python2-variant . ,(delay python2-faker))))))
10796 (define-public python2-faker
10797 (let ((base (package-with-python2 (strip-python2-variant
10802 `(("python2-ipaddress" ,python2-ipaddress)
10803 ,@(package-propagated-inputs base))))))
10805 (define-public python-pyaml
10807 (name "python-pyaml")
10808 (version "18.11.0")
10811 (uri (pypi-uri "pyaml" version))
10814 "0fi604ix8lbpj1266q7js6szm771saprdzzcdwmj43wy83694qmr"))))
10815 (build-system python-build-system)
10817 `(("python-unidecode" ,python-unidecode)))
10819 `(("python-pyyaml" ,python-pyyaml)))
10820 (home-page "https://github.com/mk-fg/pretty-yaml")
10821 (synopsis "YAML pretty-print library for Python")
10823 "pyaml is a PyYAML based python module to produce pretty and readable
10824 YAML-serialized data.")
10825 (license license:wtfpl2)))
10827 (define-public python2-pyaml
10828 (package-with-python2 python-pyaml))
10830 (define-public python-backpack
10832 (name "python-backpack")
10837 (uri (pypi-uri "backpack" version))
10840 "14rq1mvm0jda90lcx9gyyby9dvq4x3js2cmxvd6vl4686ixwyqh1"))))
10841 (build-system python-build-system)
10843 `(("python-pytest" ,python-pytest)
10844 ("python-nose" ,python-nose)))
10846 `(("python-simplejson" ,python-simplejson)))
10847 (home-page "https://github.com/sdispater/backpack")
10848 (synopsis "Utilities for working with Python collections")
10849 (description "Backpack provides some useful utilities for working with
10850 collections of data.")
10851 (license license:expat)))
10853 (define-public python2-backpack
10854 (package-with-python2 python-backpack))
10856 (define-public python-prompt-toolkit
10858 (name "python-prompt-toolkit")
10863 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
10866 "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
10867 (build-system python-build-system)
10870 (modify-phases %standard-phases
10872 (add-after 'install 'post-install-check
10873 (lambda* (#:key inputs outputs #:allow-other-keys)
10874 ;; HOME is needed for the test
10875 ;; "test_pathcompleter_can_expanduser".
10876 (setenv "HOME" "/tmp")
10877 (add-installed-pythonpath inputs outputs)
10878 (invoke "py.test"))))))
10880 `(("python-wcwidth" ,python-wcwidth)
10881 ("python-six" ,python-six)
10882 ("python-pygments" ,python-pygments)))
10884 `(("python-pytest" ,python-pytest)))
10885 (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
10886 (synopsis "Library for building command line interfaces in Python")
10888 "Prompt-Toolkit is a library for building interactive command line
10889 interfaces in Python. It's like GNU Readline but it also features syntax
10890 highlighting while typing, out-of-the-box multi-line input editing, advanced
10891 code completion, incremental search, support for Chinese double-width
10892 characters, mouse support, and auto suggestions.")
10893 (license license:bsd-3)))
10895 (define-public python2-prompt-toolkit
10896 (package-with-python2 python-prompt-toolkit))
10898 (define-public python-prompt-toolkit-1
10899 (package (inherit python-prompt-toolkit)
10904 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
10907 "05v9h5nydljwpj5nm8n804ms0glajwfy1zagrzqrg91wk3qqi1c5"))))))
10909 (define-public python2-prompt-toolkit-1
10910 (package-with-python2 python-prompt-toolkit-1))
10912 (define-public python-jedi
10914 (name "python-jedi")
10919 (uri (pypi-uri "jedi" version))
10922 "0bp4pxhsynaarbvzblsn5x32lzp29svy3sxfy8i6m5iwz9s9r1ds"))))
10923 (build-system python-build-system)
10926 (modify-phases %standard-phases
10927 (add-after 'unpack 'disable-file-completion-test
10928 ;; A single parameterized test currently fail (see:
10929 ;; https://github.com/davidhalter/jedi/issues/1395). Remove it.
10931 (substitute* "test/test_api/test_completion.py"
10932 ((".*'example.py', 'rb\"' \\+ join\\('\\.\\.'.*") ""))
10936 (setenv "HOME" "/tmp")
10937 (invoke "python" "-m" "pytest"))))))
10939 `(("python-pytest" ,python-pytest)
10940 ("python-docopt" ,python-docopt)))
10942 `(("python-parso" ,python-parso)))
10943 (home-page "https://github.com/davidhalter/jedi")
10944 (synopsis "Autocompletion and static analysis library for Python")
10946 "Jedi is a static analysis tool for Python that can be used in Integrated
10947 Development Environments (@dfn{IDE}s) and text editors. It understands Python
10948 on a deeper level than many other static analysis frameworks for Python.
10950 Jedi understands docstrings and you can use Jedi autocompletion in your REPL as
10952 (license license:expat)))
10954 (define-public python2-jedi
10955 (package-with-python2 python-jedi))
10957 (define-public ptpython
10963 (uri (pypi-uri "ptpython" version))
10966 "1mmbiyzf0n8hm7z2a562x7w5cbl6jc0zsk6vp40q1z4cyblv1k13"))))
10967 (build-system python-build-system)
10969 '(#:tests? #f)) ; FIXME: No tests in pypi tarball.
10971 `(("python-docopt" ,python-docopt)
10972 ("python-jedi" ,python-jedi)
10973 ("python-prompt-toolkit" ,python-prompt-toolkit)
10974 ("python-pygments" ,python-pygments)))
10975 (home-page "https://github.com/jonathanslenders/ptpython")
10976 (synopsis "Python Read-Eval-Print-Loop with nice IDE-like features")
10978 "ptpython is a Python read-eval-print loop with IDE-like features.
10979 It supports syntax highlighting, multiline editing, autocompletion, mouse,
10980 color schemes, bracketed paste, Vi and Emacs keybindings, Chinese characters
10982 (license license:bsd-3)
10983 (properties `((python2-variant . ,(delay ptpython-2))))))
10985 (define-public ptpython-2
10986 (let ((base (package-with-python2 (strip-python2-variant ptpython))))
10989 (name "ptpython2"))))
10991 (define-public python-stem
10993 (name "python-stem")
10998 (uri (pypi-uri "stem" version))
11001 "18lc95pmc7i089nlsb06dsxyjl5wbhxfqgdxbjcia35ndh8z7sn9"))))
11002 (build-system python-build-system)
11005 (modify-phases %standard-phases
11008 (invoke "./run_tests.py" "--unit")
11011 `(("python-mock" ,python-mock)
11012 ("python-pycodestyle" ,python-pycodestyle)
11013 ("python-pyflakes" ,python-pyflakes)))
11014 (home-page "https://stem.torproject.org/")
11016 "Python controller library that allows applications to interact with Tor")
11018 "Stem is a Python controller library for Tor. With it you can use Tor's
11019 control protocol to script against the Tor process and read descriptor data
11020 relays publish about themselves.")
11021 (license license:lgpl3)))
11023 (define-public python2-stem
11024 (package-with-python2 python-stem))
11026 (define-public python-pyserial
11028 (name "python-pyserial")
11033 (uri (pypi-uri "pyserial" version))
11036 "09y68bczw324a4jb9a1cfwrbjhq179vnfkkkrybbksp0vqgl0bbf"))))
11037 (build-system python-build-system)
11039 '(#:tests? #f)) ; FIXME: 3/49 tests are failing.
11041 ;; (modify-phases %standard-phases
11044 ;; (zero? (system* "python" "test/run_all_tests.py" "loop://")))))))
11046 "https://github.com/pyserial/pyserial")
11047 (synopsis "Python Serial Port Bindings")
11048 (description "@code{pyserial} provide serial port bindings for Python. It
11049 supports different byte sizes, stop bits, parity and flow control with RTS/CTS
11050 and/or Xon/Xoff. The port is accessed in RAW mode.")
11051 (license license:bsd-3)))
11053 (define-public python2-pyserial
11054 (package-with-python2 python-pyserial))
11056 (define-public python-kivy
11058 (name "python-kivy")
11063 (uri (pypi-uri "Kivy" version))
11064 (file-name (string-append name "-" version ".tar.gz"))
11067 "1zzxjdp78hfjjiklzr82l4zwibwcq4j6kgicspqs6iyyfn5yisbw"))))
11068 (build-system python-build-system)
11070 `(#:tests? #f ; Tests require many optional packages
11072 (modify-phases %standard-phases
11073 (add-after 'patch-generated-file-shebangs 'set-sdl-paths
11074 (lambda* (#:key inputs #:allow-other-keys)
11075 (setenv "KIVY_SDL2_PATH"
11076 (string-append (assoc-ref inputs "sdl-union")
11081 ("pkg-config" ,pkg-config)
11082 ("python-cython" ,python-cython)))
11084 `(("gstreamer" ,gstreamer)
11087 ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))))
11088 (home-page "http://kivy.org")
11090 "Multitouch application framework")
11092 "A software library for rapid development of
11093 hardware-accelerated multitouch applications.")
11094 (license license:expat)))
11096 (define-public python2-kivy
11097 (package-with-python2 python-kivy))
11099 (define-public python-kivy-next
11100 (deprecated-package "python-kivy-next" python-kivy))
11102 (define-public python2-kivy-next
11103 (deprecated-package "python2-kivy-next" python2-kivy))
11105 (define-public python-binaryornot
11107 (name "python-binaryornot")
11111 (uri (pypi-uri "binaryornot" version))
11114 "0qc006986rb6bcbmiymwgcl1mns2jphr1j7sr7nk41nlr7gh359m"))))
11115 (build-system python-build-system)
11118 (modify-phases %standard-phases
11119 (add-after 'unpack 'patch-tests
11121 ;; TypeError: binary() got an unexpected keyword argument
11123 (substitute* "tests/test_check.py"
11124 (("average_size=512") ""))
11127 `(("python-chardet" ,python-chardet)
11128 ("python-hypothesis" ,python-hypothesis)))
11129 (home-page "https://github.com/audreyr/binaryornot")
11130 (synopsis "Package to check if a file is binary or text")
11131 (description "Ultra-lightweight pure Python package to check if a file is
11133 (license license:bsd-3)
11134 (properties `((python2-variant . ,(delay python2-binaryornot))))))
11136 (define-public python2-binaryornot
11137 (let ((base (package-with-python2 (strip-python2-variant python-binaryornot))))
11138 (package (inherit base)
11140 `(("python2-enum34" ,python2-enum34)
11141 ,@(package-propagated-inputs base))))))
11143 (define-public python-binwalk
11144 (let ((commit "64201acfb5b0a9cdd9faa58c40a36dcff8612e29")
11147 (name "python-binwalk")
11148 (version (git-version "2.1.1" revision commit))
11152 (uri (git-reference
11153 (url "https://github.com/ReFirmLabs/binwalk")
11155 (file-name (git-file-name name version))
11158 "1z7ca6rfp887hw5jc3sb45mm4fa0xid4lsp2z8g4r590dr7k7w15"))))
11159 (build-system python-build-system)
11162 (modify-phases %standard-phases
11163 (add-before 'check 'set-pythonpath
11165 (setenv "PYTHONPATH"
11168 ":" (getenv "PYTHONPATH")))
11172 `(("python-coverage" ,python-coverage)
11173 ("python-nose" ,python-nose)))
11174 (home-page "https://github.com/ReFirmLabs/binwalk")
11175 (synopsis "Firmware analysis tool")
11176 (description "Binwalk is a tool for analyzing, reverse engineering, and extracting firmware images")
11177 (license license:expat))))
11179 (define-public python-nltk
11181 (name "python-nltk")
11185 (uri (pypi-uri "nltk" version))
11188 "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"))))
11189 (build-system python-build-system)
11191 '(;; The tests require some extra resources to be downloaded.
11192 ;; TODO Try packaging these resources.
11194 (home-page "http://nltk.org/")
11195 (synopsis "Natural Language Toolkit")
11196 (description "It provides interfaces to over 50 corpora and lexical
11197 resources such as WordNet, along with a suite of text processing libraries
11198 for classification, tokenization, stemming, tagging, parsing, and semantic
11199 reasoning, wrappers for natural language processing libraries.")
11200 (license license:asl2.0)))
11202 (define-public python2-nltk
11203 (package-with-python2 python-nltk))
11205 (define-public python-pymongo
11207 (name "python-pymongo")
11211 (uri (pypi-uri "pymongo" version))
11214 "0zis4707r9hdg5qgkhp3wss9camr9h56ixyfc8n9dxwlnnly4x4c"))))
11215 (build-system python-build-system)
11217 `(("python-certifi" ,python-certifi)))
11218 (home-page "https://github.com/mongodb/mongo-python-driver")
11219 (synopsis "Python driver for MongoDB")
11220 (description "Python driver for MongoDB.")
11221 (license license:asl2.0)))
11223 (define-public python2-pymongo
11224 (package-with-python2 python-pymongo))
11226 (define-public python-consul
11228 (name "python-consul")
11233 (uri (pypi-uri "python-consul" version))
11236 "0rfyxcy4cr3x848vhx876ifalxd5ghq6l5x813m49h4vq2d4jiq8"))))
11237 (build-system python-build-system)
11239 '(#:tests? #f)) ; The tests are not distributed
11241 `(("python-requests" ,python-requests)
11242 ("python-six" ,python-six)))
11243 (home-page "https://github.com/cablehead/python-consul")
11244 (synopsis "Python client for Consul")
11246 "Python client for @url{http://www.consul.io/,Consul}, a tool for service
11247 discovery, monitoring and configuration.")
11248 (license license:expat)))
11250 (define-public python2-consul
11251 (package-with-python2 python-consul))
11253 (define-public python-schematics
11255 (name "python-schematics")
11260 (uri (git-reference
11261 (url "https://github.com/schematics/schematics.git")
11262 (commit (string-append "v" version))))
11263 (file-name (git-file-name name version))
11265 (base32 "0xdqskycznqc7mfp60bhw1zq8wx7yx1dvmbq3brnm1dx3xnqa0zd"))))
11266 (build-system python-build-system)
11268 `(("python-six" ,python-six)))
11270 ;; The tests require a bunch of not very nice packages with fixed
11271 ;; version requirements (e.g. python-coveralls).
11273 (home-page "https://github.com/schematics/schematics")
11274 (synopsis "Python Data Structures for Humans")
11275 (description "Python Data Structures for Humans.")
11276 (license license:bsd-3)))
11278 (define-public python2-schematics
11279 (package-with-python2 python-schematics))
11281 (define-public python-odfpy
11283 (name "python-odfpy")
11287 (uri (pypi-uri "odfpy" version))
11290 "1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"))))
11292 `(#:modules ((srfi srfi-1)
11293 (guix build python-build-system)
11294 (guix build utils))
11296 (modify-phases %standard-phases
11298 ;; The test runner invokes python2 and python3 for test*.py.
11299 ;; To avoid having both in inputs, we replicate it here.
11301 (for-each (lambda (test-file) (invoke "python" test-file))
11302 (find-files "tests" "^test.*\\.py$"))
11304 (build-system python-build-system)
11305 (home-page "https://github.com/eea/odfpy")
11306 (synopsis "Python API and tools to manipulate OpenDocument files")
11307 (description "Collection of libraries and utility programs written in
11308 Python to manipulate OpenDocument 1.2 files.")
11310 ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
11311 ;; number of files with other licenses.
11312 (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0))))
11314 (define-public python2-odfpy
11315 (package-with-python2 python-odfpy))
11317 (define-public python-natsort
11319 (name "python-natsort")
11323 (uri (pypi-uri "natsort" version))
11326 "0i732amg6yzkx4g4c9j09jmqq39q377x9cl2nbkm5hax2c2v0wxf"))))
11327 (build-system python-build-system)
11329 `(#:modules ((guix build utils)
11330 (guix build python-build-system)
11335 (modify-phases %standard-phases
11336 (add-before 'check 'set-cachedir
11337 ;; Tests require write access to $HOME by default
11338 (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t))
11341 (let ((cwd (getcwd)))
11342 (setenv "PYTHONPATH"
11345 (find (cut string-prefix? "lib" <>)
11346 (scandir (string-append cwd "/build")))
11348 (getenv "PYTHONPATH")))
11349 (invoke "pytest" "-v")))))))
11351 `(("python-hypothesis" ,python-hypothesis)
11352 ("python-pytest-cov" ,python-pytest-cov)
11353 ("python-pytest-mock" ,python-pytest-mock)
11354 ("python-pytest" ,python-pytest)))
11355 (propagated-inputs ; TODO: Add python-fastnumbers.
11356 `(("python-pyicu" ,python-pyicu)))
11357 (home-page "https://github.com/SethMMorton/natsort")
11358 (synopsis "Natural sorting for python and shell")
11360 "Natsort lets you apply natural sorting on lists instead of
11361 lexicographical. If you use the built-in @code{sorted} method in python
11362 on a list such as @code{[@code{a20}, @code{a9}, @code{a1}, @code{a4},
11363 @code{a10}]}, it would be returned as @code{[@code{a1}, @code{a10}, @code{a20},
11364 @code{a4}, @code{a9}]}. Natsort provides a function @code{natsorted} that
11365 identifies numbers and sorts them separately from strings. It can also sort
11366 version numbers, real numbers, mixed types and more, and comes with a shell
11367 command @command{natsort} that exposes this functionality in the command line.")
11368 (license license:expat)
11369 (properties `((python2-variant . ,(delay python2-natsort))))))
11371 (define-public python2-natsort
11372 (let ((base (package-with-python2 (strip-python2-variant python-natsort))))
11373 (package (inherit base)
11375 `(("python2-pathlib" ,python2-pathlib)
11376 ,@(package-native-inputs base))))))
11378 (define-public python-glances
11380 (name "python-glances")
11385 (uri (pypi-uri "Glances" version))
11387 (base32 "15384pbvw9wj4sb8zgvd9v1812vrypbyjg0acicjf1hdb3p30fkk"))
11388 (modules '((guix build utils)))
11391 ;; Glances phones PyPI for weekly update checks by default.
11392 ;; Disable these. The user can re-enable them if desired.
11393 (substitute* "glances/outdated.py"
11394 (("^(.*)self\\.load_config\\(config\\)\n" line indentation)
11395 (string-append indentation
11396 "self.args.disable_check_update = True\n"
11399 (build-system python-build-system)
11401 `(("python-future" ,python-future)
11402 ("python-psutil" ,python-psutil)))
11403 (home-page "https://github.com/nicolargo/glances")
11404 (synopsis "Cross-platform curses-based monitoring tool")
11406 "Glances is a curses-based monitoring tool for a wide variety of platforms.
11407 Glances uses the PsUtil library to get information from your system. It
11408 monitors CPU, load, memory, network bandwidth, disk I/O, disk use, and more.")
11409 (license license:lgpl3+)))
11411 (define-public python2-glances
11412 (package-with-python2 python-glances))
11414 (define-public python-graphql-core
11416 (name "python-graphql-core")
11421 (uri (pypi-uri "graphql-core" version))
11424 "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0"))))
11425 (build-system python-build-system)
11427 `(#:tests? #f ; Tests require the unpackaged pytest-benchmark.
11429 (modify-phases %standard-phases
11430 (add-after 'unpack 'patch-hardcoded-version
11431 (lambda _ (substitute*
11433 (("'gevent==1.1rc1'") "'gevent'"))
11436 `(("python-gevent" ,python-gevent)
11437 ("python-mock" ,python-mock)
11438 ("python-pytest-mock" ,python-pytest-mock)))
11440 `(("python-promise" ,python-promise)
11441 ("python-six" ,python-six)))
11442 (home-page "https://github.com/graphql-python/graphql-core")
11443 (synopsis "GraphQL implementation for Python")
11445 "GraphQL implementation for Python. GraphQL is a data query language and
11446 runtime designed and used to request and deliver data to mobile and web apps.
11447 This library is a port of @url{https://github.com/graphql/graphql-js,graphql-js}
11449 (license license:expat)))
11451 (define-public python2-graphql-core
11452 (package-with-python2 python-graphql-core))
11454 (define-public python-graphql-relay
11456 (name "python-graphql-relay")
11461 (uri (pypi-uri "graphql-relay" version))
11464 "1nv5dxcj59zv31qvl8bd142njmxcmymny2dz3br1l2cpbljbf5i7"))))
11465 (build-system python-build-system)
11467 '(#:tests? #f)) ; The tests are not distributed
11469 `(("python-graphql-core" ,python-graphql-core)
11470 ("python-promise" ,python-promise)
11471 ("python-six" ,python-six)))
11472 (home-page "https://github.com/graphql-python/graphql-relay-py")
11473 (synopsis "Relay implementation for Python")
11475 "This is a library to allow the easy creation of Relay-compliant servers
11476 using the GraphQL Python reference implementation of a GraphQL server. It
11477 should be noted that the code is a exact port of the original
11478 @url{https://github.com/graphql/graphql-relay-js,graphql-relay js implementation}
11480 (license license:expat)))
11482 (define-public python2-graphql-relay
11483 (package-with-python2 python-graphql-relay))
11485 (define-public python-graphene
11487 (name "python-graphene")
11492 (uri (pypi-uri "graphene" version))
11495 "09zhac7igh9ixdz0ay6csy35b40l1jwbf2wrbxmgxwfhy51iy06q"))))
11496 (build-system python-build-system)
11498 `(("python-graphql-core" ,python-graphql-core)
11499 ("python-graphql-relay" ,python-graphql-relay)
11500 ("python-iso8601" ,python-iso8601)
11501 ("python-promise" ,python-promise)
11502 ("python-six" ,python-six)))
11504 `(#:tests? #f)) ; no tests/ in the PyPI tarball
11505 (home-page "http://graphene-python.org/")
11506 (synopsis "GraphQL Framework for Python")
11508 "Graphene is a Python library for building GraphQL schemas/types.
11509 A GraphQL schema describes your data model, and provides a GraphQL server
11510 with an associated set of resolve methods that know how to fetch data.")
11511 (properties `((python2-variant . ,(delay python2-graphene))))
11512 (license license:expat)))
11514 (define-public python2-graphene
11515 (let ((base (package-with-python2
11516 (strip-python2-variant python-graphene))))
11517 (package (inherit base)
11519 `(("python2-sqlalchemy" ,python2-sqlalchemy)
11520 ,@(package-native-inputs base))))))
11522 (define-public python-nautilus
11524 (name "python-nautilus")
11529 (uri (pypi-uri "nautilus" version))
11532 "01hwzjc1zshk4vvxrcghm398fpy4jls66dyz06g07mrwqif8878p"))))
11533 (build-system python-build-system)
11534 (arguments `(#:tests? #f)) ; fails to import test modules
11536 `(("python-bcrypt" ,python-bcrypt)
11537 ("python-click" ,python-click)
11538 ("python-consul" ,python-consul)
11539 ("python-graphene" ,python-graphene)
11540 ("python-jinja2" ,python-jinja2)
11541 ("python-peewee" ,python-peewee)
11542 ("python-pika" ,python-pika)
11543 ("python-tornado" ,python-tornado)
11544 ("python-wtforms" ,python-wtforms)))
11546 `(("python-nose2" ,python-nose2)))
11547 (home-page "https://github.com/AlecAivazis/nautilus")
11548 (synopsis "Library for creating microservice applications")
11550 "Nautilus is a framework for flux based microservices that looks to
11551 provide extendible implementations of common aspects of a cloud so that you can
11552 focus on building massively scalable web applications.")
11553 (license license:expat)))
11555 (define-public python-snowballstemmer
11557 (name "python-snowballstemmer")
11561 (uri (pypi-uri "snowballstemmer" version))
11564 "0a0idq4y5frv7qsg2x62jd7rd272749xk4x99misf5rcifk2d7wi"))))
11565 (build-system python-build-system)
11567 `(;; No tests exist
11569 (home-page "https://github.com/shibukawa/snowball_py")
11570 (synopsis "Snowball stemming library collection for Python")
11571 (description "This package provides 16 word stemmer algorithms generated
11572 from Snowball algorithms. It includes the 15 original ones plus the Poerter
11574 (license license:bsd-3)))
11576 (define-public python2-snowballstemmer
11577 (package-with-python2 python-snowballstemmer))
11579 (define-public python-setproctitle
11581 (name "python-setproctitle")
11586 (uri (pypi-uri "setproctitle" version))
11589 "163kplw9dcrw0lffq1bvli5yws3rngpnvrxrzdw89pbphjjvg0v2"))))
11590 (build-system python-build-system)
11593 (modify-phases %standard-phases
11594 (add-before 'check 'patch-Makefile
11595 ;; Stricly this is only required for the python2 variant.
11596 ;; But adding a phase in an inherited package seems to be
11597 ;; cumbersum. So we patch even for python3.
11599 (let ((nose (assoc-ref %build-inputs "python2-nose")))
11601 (substitute* "Makefile"
11602 (("\\$\\(PYTHON\\) [^ ]which nosetests[^ ] ")
11603 (string-append nose "/bin/nosetests "))))
11607 (setenv "PYTHON" (or (which "python3") (which "python")))
11608 (setenv "PYCONFIG" (or (which "python3-config")
11609 (which "python-config")))
11610 (setenv "CC" "gcc")
11611 ;; No need to extend PYTHONPATH to find the built package, since
11612 ;; the Makefile will build anyway
11613 (invoke "make" "check"))))))
11615 `(("procps" ,procps))) ; required for tests
11617 "https://github.com/dvarrazzo/py-setproctitle")
11619 "Setproctitle implementation for Python to customize the process title")
11620 (description "The library allows a process to change its title (as displayed
11621 by system tools such as ps and top).
11623 Changing the title is mostly useful in multi-process systems, for
11624 example when a master process is forked: changing the children's title
11625 allows to identify the task each process is busy with. The technique
11626 is used by PostgreSQL and the OpenSSH Server for example.")
11627 (license license:bsd-3)
11628 (properties `((python2-variant . ,(delay python2-setproctitle))))))
11630 (define-public python2-setproctitle
11631 (let ((base (package-with-python2
11632 (strip-python2-variant python-setproctitle))))
11635 (native-inputs `(("python2-nose" ,python2-nose)
11636 ,@(package-native-inputs base))))))
11638 (define-public python-validictory
11640 (name "python-validictory")
11645 (uri (pypi-uri "validictory" version))
11648 "1zf1g9sw47xzp5f80bd94pb42j9yqv82lcrgcvdwr6nkaphfi37q"))))
11649 (build-system python-build-system)
11652 (modify-phases %standard-phases
11653 (add-after 'unpack 'bootstrap
11654 ;; Move the tests out of the package directory to avoid
11657 (rename-file "validictory/tests" "tests")
11658 (delete-file "tests/__init__.py")))
11661 ;; Extend PYTHONPATH so the built package will be found.
11662 (setenv "PYTHONPATH"
11663 (string-append (getcwd) "/build/lib:"
11664 (getenv "PYTHONPATH")))
11665 (invoke "py.test" "-vv" ))))))
11667 `(("python-pytest" ,python-pytest)))
11669 "https://github.com/jamesturk/validictory")
11670 (synopsis "General purpose Python data validator")
11671 (description "It allows validation of arbitrary Python data structures.
11673 The schema format is based on the JSON Schema
11674 proposal (http://json-schema.org), so combined with json the library is also
11675 useful as a validator for JSON data.")
11676 (license license:expat)))
11678 (define-public python2-validictory
11679 (package-with-python2 python-validictory))
11681 (define-public python-pyelftools
11683 (name "python-pyelftools")
11688 (uri (pypi-uri "pyelftools" version))
11691 "090vdksbz341f7ljvr0zswblw4lspa8qaiikzyjkf318arpxmil9"))))
11692 (build-system python-build-system)
11695 (modify-phases %standard-phases
11696 (add-before 'check 'set-pythonpath
11698 (setenv "PYTHONPATH"
11701 ":" (getenv "PYTHONPATH")))
11704 "https://github.com/eliben/pyelftools")
11706 "Analyze binary and library file information")
11707 (description "This Python library provides interfaces for parsing and
11708 analyzing two binary and library file formats; the Executable and Linking
11709 Format (ELF), and debugging information in the Debugging With Attributed
11710 Record Format (DWARF).")
11711 (license license:public-domain)))
11713 (define-public python-pyev
11715 (name "python-pyev")
11720 (uri (pypi-uri "pyev" version))
11723 "0rf603lc0s6zpa1nb25vhd8g4y337wg2wyz56i0agsdh7jchl0sx"))))
11724 (build-system python-build-system)
11726 `(#:tests? #f ; no test suite
11728 (modify-phases %standard-phases
11729 (add-after 'unpack 'patch
11730 (lambda* (#:key inputs #:allow-other-keys)
11731 (let ((libev (string-append (assoc-ref inputs "libev")
11732 "/lib/libev.so.4")))
11733 (substitute* "setup.py"
11734 (("libev_dll_name = find_library\\(\\\"ev\\\"\\)")
11735 (string-append "libev_dll_name = \"" libev "\"")))))))))
11737 `(("libev" ,libev)))
11738 (home-page "http://pythonhosted.org/pyev/")
11739 (synopsis "Python libev interface")
11740 (description "Pyev provides a Python interface to libev.")
11741 (license license:gpl3)))
11743 (define-public python2-pyev
11744 (package-with-python2 python-pyev))
11746 (define-public python-imagesize
11748 (name "python-imagesize")
11753 (uri (pypi-uri "imagesize" version))
11756 "1dg3wn7qpwmhgqc0r9na2ding1wif9q5spz3j9zn2riwphc2k0zk"))))
11757 (build-system python-build-system)
11758 (home-page "https://github.com/shibukawa/imagesize_py")
11759 (synopsis "Gets image size of files in various formats in Python")
11761 "This package allows determination of image size from
11762 PNG, JPEG, JPEG2000 and GIF files in pure Python.")
11763 (license license:expat)))
11765 (define-public python2-imagesize
11766 (package-with-python2 python-imagesize))
11768 (define-public python-termstyle
11770 (name "python-termstyle")
11775 (uri (pypi-uri "termstyle" version))
11778 "17wzkkcqy5zc0g68xlad3kcv66iw14d2pwqc0h9420gak0vbhx7g"))))
11779 (build-system python-build-system)
11782 (modify-phases %standard-phases
11785 (invoke "python" "test3.py"))))))
11786 (home-page "https://github.com/gfxmonk/termstyle")
11787 (synopsis "Console text coloring for Python")
11788 (description "This package provides console text coloring for Python.")
11789 (license license:bsd-3)))
11791 (define-public python-argcomplete
11793 (name "python-argcomplete")
11798 (uri (pypi-uri "argcomplete" version))
11801 "02jkc44drb0yjz6x28lvg6rj607n8r2irdpdvyylm8xnycn54zx3"))))
11802 (build-system python-build-system)
11805 (modify-phases %standard-phases
11806 (add-after 'unpack 'embed-tool-references
11808 (substitute* "argcomplete/bash_completion.d/python-argcomplete.sh"
11810 (string-append " " (which "grep")))
11812 (string-append " " (which "egrep")))
11814 (string-append "elif " (which "which")))
11816 (string-append "$(" (which "which"))))
11822 `(("python-coverage" ,python-coverage)
11823 ("python-flake8" ,python-flake8)
11824 ("python-pexpect" ,python-pexpect)
11825 ("python-wheel" ,python-wheel)
11828 ("bash-full" ,bash))) ;full Bash for 'test_file_completion'
11829 (home-page "https://github.com/kislyuk/argcomplete")
11830 (synopsis "Shell tab completion for Python argparse")
11831 (description "argcomplete provides extensible command line tab completion
11832 of arguments and options for Python scripts using @code{argparse}. It's
11833 particularly useful for programs with many options or sub-parsers that can
11834 dynamically suggest completions; for example, when browsing resources over the
11836 (license license:asl2.0)))
11838 (define-public python2-argcomplete
11839 (package-with-python2 python-argcomplete))
11841 (define-public python-xopen
11843 (name "python-xopen")
11848 (uri (pypi-uri "xopen" version))
11851 "17xbrgi23l87yg6h0qcknssp2q812miiy33qw6v45v5gx0jwv5xh"))))
11852 (build-system python-build-system)
11854 `(("python-setuptools-scm" ,python-setuptools-scm)))
11855 (home-page "https://github.com/marcelm/xopen/")
11856 (synopsis "Open compressed files transparently")
11857 (description "This module provides an @code{xopen} function that works like
11858 Python's built-in @code{open} function, but can also deal with compressed files.
11859 Supported compression formats are gzip, bzip2 and, xz, and are automatically
11860 recognized by their file extensions. The focus is on being as efficient as
11861 possible on all supported Python versions.")
11862 (license license:expat)))
11864 (define-public python2-xopen
11865 (let ((base (package-with-python2
11866 (strip-python2-variant python-xopen))))
11869 (propagated-inputs `(("python2-bz2file" ,python2-bz2file)
11870 ,@(package-propagated-inputs base))))))
11872 (define-public python-cheetah
11874 (name "python-cheetah")
11879 (uri (pypi-uri "Cheetah3" version))
11882 "1ihag9cxll6b86fc8v5lkhmr3brdbi4yiz16zpgw79yylmv8fgr9"))))
11883 (build-system python-build-system)
11885 `(#:modules ((guix build utils)
11886 (guix build python-build-system)
11890 #:phases (modify-phases %standard-phases
11891 (add-after 'unpack 'use-absolute-python
11893 (substitute* "Cheetah/CheetahWrapper.py"
11894 (("#!/usr/bin/env python")
11895 (string-append "#!" (which "python"))))
11899 (let ((cwd (getcwd)))
11900 (setenv "PYTHONPATH"
11903 (find (cut string-prefix? "lib" <>)
11904 (scandir (string-append cwd "/build")))
11905 ":" (getenv "PYTHONPATH")))
11907 (string-append (getenv "PATH")
11909 (setenv "TMPDIR" "/tmp")
11911 (substitute* "Cheetah/Tests/Test.py"
11912 (("unittest.TextTestRunner\\(\\)")
11913 "unittest.TextTestRunner(verbosity=2)"))
11915 (invoke "python" "Cheetah/Tests/Test.py")))))))
11917 `(("python-markdown" ,python-markdown))) ;optional
11918 (home-page "http://cheetahtemplate.org/")
11919 (synopsis "Template engine")
11920 (description "Cheetah is a text-based template engine and Python code
11923 Cheetah can be used as a standalone templating utility or referenced as
11924 a library from other Python applications. It has many potential uses,
11925 but web developers looking for a viable alternative to ASP, JSP, PHP and
11926 PSP are expected to be its principle user group.
11930 @item Generates HTML, SGML, XML, SQL, Postscript, form email, LaTeX, or any other
11932 @item Cleanly separates content, graphic design, and program code.
11933 @item Blends the power and flexibility of Python with a simple template language
11934 that non-programmers can understand.
11935 @item Gives template writers full access to any Python data structure, module,
11936 function, object, or method in their templates.
11937 @item Makes code reuse easy by providing an object-orientated interface to
11938 templates that is accessible from Python code or other Cheetah templates.
11939 One template can subclass another and selectively reimplement sections of it.
11940 @item Provides a simple, yet powerful, caching mechanism that can dramatically
11941 improve the performance of a dynamic website.
11942 @item Compiles templates into optimized, yet readable, Python code.
11944 (license (license:x11-style "file://LICENSE"))))
11946 (define-public python2-cheetah
11947 (package-with-python2 python-cheetah))
11949 (define-public python-dulwich
11951 (name "python-dulwich")
11956 (uri (list (string-append "https://www.dulwich.io/releases/"
11957 "dulwich-" version ".tar.gz")
11958 (pypi-uri "dulwich" version)))
11961 "1aa1xfrxkc3j9s4xi0llhf5gndyi9ryprcxsqfa5fcb8ph34981q"))))
11962 (build-system python-build-system)
11965 (modify-phases %standard-phases
11966 (add-before 'check 'fix-tests
11967 (lambda* (#:key inputs #:allow-other-keys)
11968 ;; The tests use Popen with a custom environment which doesn't
11970 (substitute* "dulwich/tests/compat/utils.py"
11971 (("'git'") (string-append "'"
11974 (substitute* '("dulwich/tests/test_repository.py"
11975 "dulwich/tests/test_hooks.py")
11976 (("#!/bin/sh") (string-append "#!" (which "sh"))))
11977 (setenv "TEST_RUNNER" "unittest")
11978 (setenv "PYTHONHASHSEED" "random")
11981 `(("python-fastimport" ,python-fastimport)))
11983 `(("python-mock" ,python-mock)
11984 ("python-geventhttpclient" ,python-geventhttpclient)
11986 (home-page "https://www.dulwich.io/")
11987 (synopsis "Git implementation in Python")
11988 (description "Dulwich is an implementation of the Git file formats and
11989 protocols written in pure Python.")
11990 ;; Can be used with either license.
11991 (license (list license:asl2.0 license:gpl2+))))
11993 (define-public python2-dulwich
11994 (package-with-python2 python-dulwich))
11996 (define-public python-pbkdf2
11998 (name "python-pbkdf2")
12003 (uri (pypi-uri "pbkdf2" version))
12006 "0yb99rl2mbsaamj571s1mf6vgniqh23v98k4632150hjkwv9fqxc"))))
12007 (build-system python-build-system)
12010 (modify-phases %standard-phases
12013 (setenv "PYTHONPATH"
12014 (string-append (getcwd) "/build/lib:"
12015 (getenv "PYTHONPATH")))
12016 (invoke "python" "test/test_pbkdf2.py"))))))
12018 `(("python-pycrypto" ,python-pycrypto))) ; optional
12019 (home-page "https://www.dlitz.net/software/python-pbkdf2/")
12020 (synopsis "Password-based key derivation")
12021 (description "This module implements the password-based key derivation
12022 function, PBKDF2, specified in RSA PKCS#5 v2.0.
12024 PKCS#5 v2.0 Password-Based Key Derivation is a key derivation function which
12025 is part of the RSA Public Key Cryptography Standards series. The provided
12026 implementation takes a password or a passphrase and a salt value (and
12027 optionally a iteration count, a digest module, and a MAC module) and provides
12028 a file-like object from which an arbitrarly-sized key can be read.")
12029 (license license:expat)))
12031 (define-public python2-pbkdf2
12032 (package-with-python2 python-pbkdf2))
12034 (define-public python-qrcode
12036 (name "python-qrcode")
12041 (uri (pypi-uri "qrcode" version))
12043 (base32 "0sa3n298b9jpz6zn0birnjii3mg9sihjq28n9nzjlzv09y2m6ljh"))))
12044 (build-system python-build-system)
12046 ;; FIXME: Tests require packaging 'pymaging'.
12049 `(("python-lxml" ,python-lxml) ; for SVG output
12050 ("python-pillow" ,python-pillow) ; for PNG output
12051 ("python-six" ,python-six)))
12052 (home-page "https://github.com/lincolnloop/python-qrcode")
12053 (synopsis "QR Code image generator")
12054 (description "This package provides a pure Python QR Code generator
12055 module. It uses the Python Imaging Library (PIL) to allow for the generation
12058 In addition this package provides a command line tool to generate QR codes and
12059 either write these QR codes to a file or do the output as ascii art at the
12061 (license license:bsd-3)))
12063 (define-public python2-qrcode
12064 (package-with-python2 python-qrcode))
12066 (define-public python-rst2ansi
12068 (name "python-rst2ansi")
12073 (uri (pypi-uri "rst2ansi" version))
12076 "0vzy6gd60l79ff750scl0sz48r1laalkl6md6dwzah4dcadgn5qv"))))
12077 (build-system python-build-system)
12079 `(("python-docutils" ,python-docutils)))
12080 (home-page "https://github.com/Snaipe/python-rst-to-ansi")
12081 (synopsis "Convert RST to ANSI-decorated console output")
12083 "Python module dedicated to rendering RST (reStructuredText) documents
12084 to ansi-escaped strings suitable for display in a terminal.")
12085 (license license:expat)))
12087 (define-public python-ansi2html
12089 (name "python-ansi2html")
12094 (uri (pypi-uri "ansi2html" version))
12097 "1wa00zffprb78w1mqq90dk47czz1knanys2a40zbw2vyapd5lp9y"))))
12098 (build-system python-build-system)
12100 `(("python-mock" ,python-mock)
12101 ("python-nose" ,python-nose)))
12103 `(("python-six" ,python-six)))
12104 (home-page "https://github.com/ralphbean/ansi2html")
12105 (synopsis "Convert ANSI-decorated console output to HTML")
12107 "@command{ansi2html} is a Python library and command line utility for
12108 convering text with ANSI color codes to HTML or LaTeX.")
12109 (license license:gpl3+)))
12111 (define-public python2-ansi2html
12112 (package-with-python2 python-ansi2html))
12114 (define-public python-ddt
12116 (name "python-ddt")
12121 (uri (pypi-uri "ddt" version))
12124 "1lw17420iimhghkgzgax85nn8d1an2d6k2cfvb7j5kwn2dqlr1vk"))))
12125 (build-system python-build-system)
12127 `(("python-mock" ,python-mock)
12128 ("python-nose" ,python-nose)))
12130 `(("python-six" ,python-six)
12131 ("python-pyyaml" ,python-pyyaml)))
12132 (home-page "https://github.com/txels/ddt")
12133 (synopsis "Data-Driven Tests")
12135 "Data-Driven Tests (@dfn{DDT}) allow you to multiply one test case by
12136 running it with different test data, and make it appear as multiple test
12138 (license license:expat)))
12140 (define-public python2-ddt
12141 (package-with-python2 python-ddt))
12143 (define-public python-pycountry
12145 (name "python-pycountry")
12146 (version "18.5.26")
12150 (uri (pypi-uri "pycountry" version))
12153 "15q9j047s3yc9cfcxq1ch8b71f81na44cr6dydd5gxk0ki9a4akz"))))
12154 (build-system python-build-system)
12155 (home-page "https://bitbucket.org/flyingcircus/pycountry")
12156 (synopsis "ISO databases for languages, countries, currencies, etc.")
12158 "@code{pycountry} provides the ISO databases for the standards:
12160 @item 639-3 (Languages)
12161 @item 3166 (Countries)
12162 @item 3166-3 (Deleted Countries)
12163 @item 3166-2 (Subdivisions of countries)
12164 @item 4217 (Currencies)
12165 @item 15924 (Scripts)
12167 It includes a copy from Debian’s pkg-isocodes and makes the data accessible
12168 through a Python API.")
12169 (license license:lgpl2.1+)))
12171 (define-public python2-pycountry
12172 (package-with-python2 python-pycountry))
12174 (define-public python-pycosat
12176 (name "python-pycosat")
12181 (uri (pypi-uri "pycosat" version))
12184 "1kl3wh1f47rc712n4bmwplbx3fqz3x9i1b587jrbpmvdva4c8f6l"))))
12185 ;; TODO: Unundle picosat. http://fmv.jku.at/picosat/
12186 (build-system python-build-system)
12187 (home-page "https://github.com/ContinuumIO/pycosat")
12188 (synopsis "Bindings to picosat (a SAT solver)")
12190 "This package provides efficient Python bindings to @code{picosat} on
12191 the C level. When importing pycosat, the @code{picosat} solver becomes part
12192 of the Python process itself. @code{picosat} is a @dfn{Boolean Satisfiability
12193 Problem} (SAT) solver.")
12194 (license license:expat)))
12196 (define-public python2-pycosat
12197 (package-with-python2 python-pycosat))
12199 (define-public python2-ruamel.ordereddict
12201 (name "python2-ruamel.ordereddict")
12206 (uri (pypi-uri "ruamel.ordereddict" version))
12209 "1xmkl8v9l9inm2pyxgc1fm5005yxm7fkd5gv74q7lj1iy5qc8n3h"))))
12210 (build-system python-build-system)
12212 `(#:python ,python-2
12214 (modify-phases %standard-phases
12216 (add-after 'install 'check
12217 (lambda* (#:key inputs outputs #:allow-other-keys)
12218 (add-installed-pythonpath inputs outputs)
12219 (invoke "python" "test/testordereddict.py"))))))
12220 (home-page "https://bitbucket.org/ruamel/ordereddict")
12221 (synopsis "Version of dict that keeps keys in insertion order")
12223 "This is an implementation of an ordered dictionary with @dfn{Key
12224 Insertion Order} (KIO: updates of values do not affect the position of the
12225 key), @dfn{Key Value Insertion Order} (KVIO, an existing key's position is
12226 removed and put at the back). The standard library module @code{OrderedDict},
12227 implemented later, implements a subset of @code{ordereddict} functionality.
12228 Sorted dictionaries are also provided. Currently only with @dfn{Key Sorted
12229 Order} (KSO, no sorting function can be specified, but a transform can be
12230 specified to apply on the key before comparison (e.g. @code{string.lower})).")
12231 (license license:expat)))
12233 (define-public python-pypeg2
12235 (name "python-pypeg2")
12240 (uri (pypi-uri "pyPEG2" version))
12243 "0v8ziaam2r637v94ra4dbjw6jzxz99gs5x4i585kgag1v204yb9b"))))
12244 (build-system python-build-system)
12245 (propagated-inputs `(("python-lxml" ,python-lxml)))
12247 ;;https://bitbucket.org/fdik/pypeg/issues/36/test-failures-on-py35
12249 (home-page "https://fdik.org/pyPEG/")
12250 (synopsis "Parsering Expression Grammars in Python")
12251 (description "PyPEG is an intrinsic parser interpreter framework for
12252 Python. It is based on Parsing Expression Grammars, PEG. With pyPEG you can
12253 parse many formal languages.")
12254 (license license:gpl2)))
12256 (define-public python-incremental
12258 (name "python-incremental")
12263 (uri (pypi-uri "incremental" version))
12266 "1cylxdz1cnkm5g3pklna3h2n0i0rks95ir1pnpxfnvpkmab1cxbv"))))
12267 (build-system python-build-system)
12268 (home-page "https://github.com/hawkowl/incremental")
12269 (synopsis "Library for versioning Python projects")
12270 (description "Incremental is a small library that versions your Python
12272 (license license:expat)))
12274 (define-public python2-incremental
12275 (package-with-python2 python-incremental))
12277 (define-public python-invoke
12279 (name "python-invoke")
12280 (home-page "http://www.pyinvoke.org/")
12284 (uri (pypi-uri "invoke" version))
12287 "1nn7gad0rvy492acpyhkrp01zsk86acf34qhsvq4xmm6x39788n5"))))
12288 (build-system python-build-system)
12290 ;; XXX: Requires many dependencies that are not yet in Guix.
12292 (synopsis "Pythonic task execution")
12294 "Invoke is a Python task execution tool and library, drawing inspiration
12295 from various sources to arrive at a powerful and clean feature set. It is
12296 evolved from the Fabric project, but focuses on local and abstract concerns
12297 instead of servers and network commands.")
12298 (license license:bsd-3)))
12300 (define-public python2-invoke
12301 (package-with-python2 python-invoke))
12303 (define-public python-automat
12305 (name "python-automat")
12309 (uri (pypi-uri "Automat" version))
12312 "03ivg70n3b1cbcd2zvjhk8y4kmqxcvhmili39lmgx09dza1qpmyb"))))
12313 (build-system python-build-system)
12314 ;; We disable the tests because they require python-twisted, while
12315 ;; python-twisted depends on python-automat. Twisted is optional, but the
12316 ;; tests fail if it is not available. Also see
12317 ;; <https://github.com/glyph/automat/issues/71>.
12318 (arguments '(#:tests? #f))
12320 `(("python-m2r" ,python-m2r)
12321 ("python-setuptools-scm" ,python-setuptools-scm)
12322 ("python-graphviz" ,python-graphviz)))
12324 `(("python-six" ,python-six)
12325 ("python-attrs" ,python-attrs)))
12326 (home-page "https://github.com/glyph/Automat")
12327 (synopsis "Self-service finite-state machines")
12328 (description "Automat is a library for concise, idiomatic Python
12329 expression of finite-state automata (particularly deterministic finite-state
12331 (license license:expat)))
12333 (define-public python2-automat
12334 (package-with-python2 python-automat))
12336 (define-public python-m2r
12338 (name "python-m2r")
12342 (uri (pypi-uri "m2r" version))
12345 "16gdm8i06jjmlpvckpfmlkr4693dh0vs192vgsqn84fsdkbbm45z"))))
12346 (build-system python-build-system)
12348 `(("python-docutils" ,python-docutils)
12349 ("python-mistune" ,python-mistune)))
12351 `(("python-pygments" ,python-pygments)
12352 ("python-mock" ,python-mock)))
12353 (home-page "https://github.com/miyakogi/m2r")
12354 (synopsis "Markdown to reStructuredText converter")
12355 (description "M2R converts a markdown file including reST markups to valid
12357 (license license:expat)))
12359 (define-public python2-m2r
12360 (package-with-python2 python-m2r))
12362 (define-public python-constantly
12364 (name "python-constantly")
12368 (uri (pypi-uri "constantly" version))
12371 "0dgwdla5kfpqz83hfril716inm41hgn9skxskvi77605jbmp4qsq"))))
12372 (build-system python-build-system)
12373 (home-page "https://github.com/twisted/constantly")
12374 (synopsis "Symbolic constants in Python")
12375 (description "Constantly is a Python library that provides symbolic
12376 constant support. It includes collections and constants with text, numeric,
12377 and bit flag values.")
12378 (license license:expat)))
12380 (define-public python2-constantly
12381 (package-with-python2 python-constantly))
12383 (define-public python-attrs
12385 (name "python-attrs")
12389 (uri (pypi-uri "attrs" version))
12392 "16g33zr5f449lqc5wgvzpknxryfzrfsxcr6kpgxwn7l5fkv71f7h"))))
12393 (build-system python-build-system)
12395 `(#:modules ((guix build utils)
12396 (guix build python-build-system)
12400 #:phases (modify-phases %standard-phases
12403 (let ((cwd (getcwd)))
12404 (setenv "PYTHONPATH"
12407 (find (cut string-prefix? "lib" <>)
12408 (scandir (string-append cwd "/build")))
12410 (getenv "PYTHONPATH")))
12411 (invoke "python" "-m" "pytest")))))))
12413 `(("python-coverage" ,python-coverage)
12414 ("python-hypothesis" ,python-hypothesis)
12415 ("python-pympler" ,python-pympler)
12416 ("python-pytest" ,python-pytest)
12417 ("python-six" ,python-six)
12418 ("python-sphinx" ,python-sphinx)
12419 ("python-zope-interface" ,python-zope-interface)))
12420 (home-page "https://github.com/python-attrs/attrs/")
12421 (synopsis "Attributes without boilerplate")
12422 (description "@code{attrs} is a Python package with class decorators that
12423 ease the chores of implementing the most common attribute-related object
12425 (license license:expat)))
12427 (define-public python2-attrs
12428 (package-with-python2 python-attrs))
12430 (define-public python-attrs-bootstrap
12432 (inherit python-attrs)
12433 (name "python-attrs-bootstrap")
12434 (native-inputs `())
12435 (arguments `(#:tests? #f))))
12437 (define-public python2-attrs-bootstrap
12438 (package-with-python2 python-attrs-bootstrap))
12440 (define-public python2-cliapp
12442 (name "python2-cliapp")
12443 (version "1.20180812.1")
12447 (uri (string-append
12448 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/cliapp/snapshot/cliapp-"
12449 version ".tar.gz"))
12452 "1c1jlblbns8qhiaqjpg4xi6lip8xwfc5w643p43rg543havaj45x"))))
12453 (build-system python-build-system)
12455 `(#:python ,python-2
12457 (modify-phases %standard-phases
12458 ;; check phase needs to be run before the build phase. If not,
12459 ;; coverage-test-runner looks for tests for the built source files,
12462 (add-before 'build 'check
12464 ;; Disable python3 tests
12465 (substitute* "check"
12466 (("python3") "# python3"))
12467 (invoke "./check"))))))
12469 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)
12470 ("python2-pep8" ,python2-pep8)))
12472 `(("python2-pyaml" ,python2-pyaml)))
12473 (home-page "https://liw.fi/cliapp/")
12474 (synopsis "Python framework for command line programs")
12475 (description "@code{python2-cliapp} is a python framework for
12476 command line programs. It contains the typical stuff such programs
12477 need to do, such as parsing the command line for options, and
12478 iterating over input files.")
12479 (license license:gpl2+)))
12481 (define-public python2-ttystatus
12483 (name "python2-ttystatus")
12488 (uri (string-append
12489 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/ttystatus/snapshot/ttystatus-"
12490 version ".tar.gz"))
12493 "06mdk4d19zw2j3is54gndhzl396g3xc8k52m7i86z69s9hcz71by"))))
12494 (build-system python-build-system)
12496 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)
12497 ("python2-pep8" ,python2-pep8)))
12499 `(#:python ,python-2
12501 (modify-phases %standard-phases
12502 ;; check phase needs to be run before the build phase. If not,
12503 ;; coverage-test-runner looks for tests for the built source files,
12506 (add-before 'build 'check
12507 (lambda _ (invoke "make" "check"))))))
12508 (home-page "https://liw.fi/ttystatus/")
12509 (synopsis "Python library for showing progress reporting and
12510 status updates on terminals")
12511 (description "@code{python2-ttystatus} is a python library for
12512 showing progress reporting and status updates on terminals, for
12513 command line programs. Output is automatically adapted to the width
12514 of the terminal: truncated if it does not fit, and resized if the
12515 terminal size changes.")
12516 (license license:gpl3+)))
12518 (define-public python2-tracing
12520 (name "python2-tracing")
12525 (uri (string-append
12526 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/python-tracing/snapshot/tracing-"
12527 version ".tar.gz"))
12530 "06cw4zg42fsvqy372vi2whj26w56vzg5axhzwdjc2bgwf03garbw"))))
12531 (build-system python-build-system)
12533 `(#:python ,python-2))
12534 (home-page "https://liw.fi/tracing/")
12535 (synopsis "Python debug logging helper")
12536 (description "@code{python2-tracing} is a python library for
12537 logging debug messages. It provides a way to turn debugging messages
12538 on and off, based on the filename they occur in. It is much faster
12539 than using @code{logging.Filter} to accomplish the same thing, which
12540 matters when code is run in production mode. The actual logging still
12541 happens using the @code{logging} library.")
12542 (license license:gpl3+)))
12544 (define-public python2-larch
12546 (name "python2-larch")
12547 (version "1.20151025")
12551 (uri (string-append
12552 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/larch/snapshot/larch-"
12553 version ".tar.gz"))
12554 (patches (search-patches
12555 "python2-larch-coverage-4.0a6-compatibility.patch"))
12558 "1p4knkkavlqymgciz2wbcnfrdgdbafhg14maplnk4vbw0q8xs663"))))
12559 (build-system python-build-system)
12561 `(#:python ,python-2
12563 (modify-phases %standard-phases
12564 ;; check phase needs to be run before the build phase. If not,
12565 ;; coverage-test-runner looks for tests for the built source files,
12568 (add-before 'build 'check
12569 (lambda _ (invoke "make" "check"))))))
12571 `(("cmdtest" ,cmdtest)
12572 ("python2-coverage-test-runner" ,python2-coverage-test-runner)))
12574 `(("python2-tracing" ,python2-tracing)))
12575 (home-page "https://liw.fi/larch/")
12576 (synopsis "Python copy-on-write B-tree library")
12577 (description "@code{python2-larch} is an implementation of
12578 particular kind of B-tree, based on research by Ohad Rodeh. See
12579 @url{http://liw.fi/larch/ohad-btrees-shadowing-clones.pdf} for details
12580 on the data structure.
12582 The distinctive feature of this B-tree is that a node is never
12583 (conceptually) modified. Instead, all updates are done by
12584 copy-on-write. This makes it easy to clone a tree, and modify only the
12585 clone, while other processes access the original tree.")
12586 (license license:gpl3+)))
12588 (define-public python-astroid
12590 (name "python-astroid")
12595 (uri (pypi-uri "astroid" version))
12597 (base32 "0fnibsl2cb5mvzbfm7sycj85smx48f8w8m7ks1sqlmpr9ps0gski"))))
12598 (build-system python-build-system)
12600 `(("python-lazy-object-proxy" ,python-lazy-object-proxy)
12601 ("python-six" ,python-six)
12602 ("python-typed-ast" ,python-typed-ast)
12603 ("python-wrapt" ,python-wrapt)))
12605 `(("python-dateutil" ,python-dateutil)
12606 ("python-nose" ,python-nose)
12607 ("python-pytest" ,python-pytest)
12608 ("python-pytest-runner" ,python-pytest-runner)))
12611 (modify-phases %standard-phases
12612 (add-after 'unpack 'remove-spurious-test
12614 ;; This can be removed after upgrading from python-3.7
12615 ;; https://github.com/PyCQA/astroid/issues/593
12616 ;; https://bugs.python.org/issue34056
12617 (delete-file "astroid/tests/unittest_modutils.py")
12621 (invoke "pytest" "astroid"))))))
12622 (home-page "https://github.com/PyCQA/astroid")
12623 (synopsis "Common base representation of python source code for pylint and
12625 (description "@code{python-astroid} provides a common base representation
12626 of python source code for projects such as pychecker, pyreverse, pylint, etc.
12628 It provides a compatible representation which comes from the _ast module. It
12629 rebuilds the tree generated by the builtin _ast module by recursively walking
12630 down the AST and building an extended ast. The new node classes have
12631 additional methods and attributes for different usages. They include some
12632 support for static inference and local name scopes. Furthermore, astroid
12633 builds partial trees by inspecting living objects.")
12634 (license license:lgpl2.1+)
12635 (properties `((python2-variant . ,(delay python2-astroid))))))
12637 (define-public python2-astroid
12638 (let ((base (package-with-python2
12639 (strip-python2-variant python-astroid))))
12640 (package (inherit base)
12641 ;; Version 2.x removes python2 support.
12646 (uri (pypi-uri "astroid" version))
12649 "0fir4b67sm7shcacah9n61pvq313m523jb4q80sycrh3p8nmi6zw"))))
12651 (substitute-keyword-arguments (package-arguments base)
12653 `(modify-phases ,phases
12654 (add-after 'unpack 'remove-spurious-test
12656 ;; https://github.com/PyCQA/astroid/issues/276
12657 (delete-file "astroid/tests/unittest_brain.py")
12661 (invoke"python" "-m" "unittest" "discover"
12662 "-p" "unittest*.py")))))))
12663 (native-inputs `())
12665 `(("python2-backports-functools-lru-cache"
12666 ,python2-backports-functools-lru-cache)
12667 ("python2-enum34" ,python2-enum34)
12668 ("python2-singledispatch" ,python2-singledispatch)
12669 ,@(alist-delete "python-typed-ast"
12670 (package-propagated-inputs base)))))))
12672 (define-public python-isort
12674 (name "python-isort")
12679 (uri (git-reference
12680 ;; Tests pass only from the Github sources
12681 (url "https://github.com/timothycrosley/isort")
12683 (file-name (git-file-name name version))
12686 "1q0mlrpki5vjbgwxag5rghljjcfg7mvb0pbkwid80p0sqrxlm2p6"))))
12687 (build-system python-build-system)
12689 `(("python-mock" ,python-mock)
12690 ("python-pytest" ,python-pytest)))
12691 (home-page "https://github.com/timothycrosley/isort")
12692 (synopsis "Python utility/library to sort python imports")
12693 (description "@code{python-isort} is a python utility/library to sort
12694 imports alphabetically, and automatically separated into sections. It
12695 provides a command line utility, a python library and plugins for various
12697 (license license:expat)
12698 (properties `((python2-variant . ,(delay python2-isort))))))
12700 (define-public python2-isort
12701 (let ((base (package-with-python2
12702 (strip-python2-variant python-isort))))
12703 (package (inherit base)
12705 `(("python2-futures" ,python2-futures)
12706 ,@(package-native-inputs base))))))
12708 (define-public python2-backports-functools-lru-cache
12710 (name "python2-backports-functools-lru-cache")
12715 ;; only the pypi tarballs contain the necessary metadata
12716 (uri (pypi-uri "backports.functools_lru_cache" version))
12719 "06jgv8gib4fhky0p5cmxdghvsgjyzcdgk48k8pxb1ccf11znk64x"))))
12720 (build-system python-build-system)
12722 `(("python2-setuptools-scm" ,python2-setuptools-scm)))
12724 `(#:python ,python-2))
12725 (home-page "https://github.com/jaraco/backports.functools_lru_cache")
12726 (synopsis "Backport of functools.lru_cache from Python 3.3")
12727 (description "@code{python2-backports-functools-lru-cache} is a backport
12728 of @code{functools.lru_cache} from python 3.3.")
12729 (license license:expat)))
12731 (define-public python-configparser
12733 (name "python-configparser")
12738 (uri (pypi-uri "configparser" version))
12741 "0cnz213il9lhgda6x70fw7mfqr8da43s3wm343lwzhqx94mgmmav"))))
12742 (build-system python-build-system)
12743 (home-page "https://github.com/jaraco/configparser/")
12744 (synopsis "Backport of configparser from python 3.5")
12745 (description "@code{python-configparser} is a backport of
12746 @code{configparser} from Python 3.5 so that it can be used directly
12747 in other versions.")
12748 (license license:expat)))
12750 (define-public python2-configparser
12751 (package-with-python2 python-configparser))
12753 (define-public python-mando
12755 (name "python-mando")
12759 (uri (pypi-uri "mando" version))
12762 "0q6rl085q1hw1wic52pqfndr0x3nirbxnhqj9akdm5zhq2fv3zkr"))))
12763 (build-system python-build-system)
12765 `(("python-rst2ansi" ,python-rst2ansi)
12766 ("python-six" ,python-six)))
12768 `(("python-pytest" ,python-pytest)))
12769 (home-page "https://mando.readthedocs.org/")
12771 "Wrapper around argparse, allowing creation of complete CLI applications")
12773 "This package is a wrapper around argparse, allowing you to write complete CLI
12774 applications in seconds while maintaining all the flexibility.")
12775 (license license:expat)))
12777 (define-public python2-mando
12778 (package-with-python2 python-mando))
12780 (define-public python2-argparse
12782 (name "python2-argparse")
12787 (uri (pypi-uri "argparse" version))
12790 "1r6nznp64j68ih1k537wms7h57nvppq0szmwsaf99n71bfjqkc32"))))
12791 (build-system python-build-system)
12793 `(#:python ,python-2))
12794 (home-page "https://github.com/ThomasWaldmann/argparse/")
12795 (synopsis "Python command-line parsing library")
12797 "This package is mostly for people who want to have @code{argparse} on
12798 older Pythons because it was not part of the standard library back then.")
12799 (license license:psfl)))
12801 (define-public python-fudge
12803 (name "python-fudge")
12804 ;; 0.9.6 is the latest version suitable for testing the "fabric" Python 2
12805 ;; package, which is currently the only use of this package.
12810 (uri (pypi-uri "fudge" version))
12813 "185ia3vr3qk4f2s1a9hdxb8ci4qc0x0xidrad96pywg8j930qs9l"))))
12814 (build-system python-build-system)
12816 `(#:tests? #f)) ;XXX: Tests require the NoseJS Python package.
12817 (home-page "https://github.com/fudge-py/fudge")
12818 (synopsis "Replace real objects with fakes/mocks/stubs while testing")
12820 "Fudge is a Python module for using fake objects (mocks and stubs) to
12823 In readable Python code, you declare the methods available on your fake object
12824 and how they should be called. Then you inject that into your application and
12825 start testing. This declarative approach means you don’t have to record and
12826 playback actions and you don’t have to inspect your fakes after running code.
12827 If the fake object was used incorrectly then you’ll see an informative
12828 exception message with a traceback that points to the culprit.")
12829 (license license:expat)))
12831 (define-public python2-fudge
12832 (package-with-python2 python-fudge))
12834 (define-public python-mwclient
12836 (name "python-mwclient")
12841 ;; The PyPI version wouldn't contain tests.
12842 (uri (git-reference
12843 (url "https://github.com/mwclient/mwclient")
12844 (commit (string-append "v" version))))
12845 (file-name (git-file-name name version))
12848 "1c3q6lwmb05yqywc4ya98ca7hsl15niili8rccl4n1yqp77c103v"))))
12849 (build-system python-build-system)
12851 `(("python-requests-oauthlib" ,python-requests-oauthlib)
12852 ("python-six" ,python-six)))
12854 `(("python-mock" ,python-mock)
12855 ("python-pytest" ,python-pytest)
12856 ("python-pytest-cov" ,python-pytest-cov)
12857 ("python-pytest-runner" ,python-pytest-runner)
12858 ("python-responses" ,python-responses)))
12859 (home-page "https://github.com/btongminh/mwclient")
12860 (synopsis "MediaWiki API client")
12861 (description "This package provides a MediaWiki API client.")
12862 (license license:expat)))
12864 (define-public python2-mwclient
12865 (package-with-python2 python-mwclient))
12867 (define-public python-utils
12869 (name "python-utils")
12873 (uri (pypi-uri "python-utils" version))
12876 "1mcsy6q5am4ya72rgkpb6kax6vv7c93cfkkas89xnpa4sj9zf28p"))))
12877 (build-system python-build-system)
12879 `(("pytest-runner" ,python-pytest-runner)
12880 ("pytest" ,python-pytest)
12881 ("six" ,python-six)))
12882 (home-page "https://github.com/WoLpH/python-utils")
12883 (synopsis "Convenient utilities not included with the standard Python install")
12885 "Python Utils is a collection of small Python functions and classes which
12886 make common patterns shorter and easier.")
12887 (license license:bsd-2)))
12889 (define-public python2-utils
12890 (package-with-python2 python-utils))
12892 (define-public python-diff-match-patch
12894 (name "python-diff-match-patch")
12895 (version "20121119")
12899 (uri (pypi-uri "diff-match-patch" version))
12902 "0k1f3v8nbidcmmrk65m7h8v41jqi37653za9fcs96y7jzc8mdflx"))))
12903 (build-system python-build-system)
12904 (home-page "https://code.google.com/p/google-diff-match-patch")
12905 (synopsis "Synchronize plain text")
12906 (description "Diff Match and Patch libraries offer robust algorithms to
12907 perform the operations required for synchronizing plain text.")
12908 (license license:asl2.0)))
12910 (define-public python2-diff-match-patch
12911 (package-with-python2 python-diff-match-patch))
12913 (define-public python-dirsync
12915 (name "python-dirsync")
12920 (uri (pypi-uri "dirsync" version))
12923 "1r40fkanksagcszf1ag85mdr8w7rgc7196n6s1qlsk2abw6i7v0z"))))
12924 (build-system python-build-system)
12926 `(("six" ,python-six)))
12927 (home-page "https://bitbucket.org/tkhyn/dirsync")
12928 (synopsis "Advanced directory tree synchronisation tool")
12929 (description "Advanced directory tree synchronisation tool.")
12930 (license license:expat)))
12932 (define-public python2-dirsync
12933 (package-with-python2 python-dirsync))
12935 (define-public python-levenshtein
12937 (name "python-levenshtein")
12942 (uri (pypi-uri "python-Levenshtein" version))
12945 "1c9ybqcja31nghfcc8xxbbz9h60s9qi12b9hr4jyl69xbvg12fh3"))))
12946 (build-system python-build-system)
12947 (home-page "https://github.com/ztane/python-Levenshtein")
12948 (synopsis "Fast computation of Levenshtein distance and string similarity")
12950 "The Levenshtein Python C extension module contains functions for fast computation of
12952 @item Levenshtein (edit) distance, and edit operations
12953 @item string similarity
12954 @item approximate median strings, and generally string averaging
12955 @item string sequence and set similarity
12957 It supports both normal and Unicode strings.")
12958 (license license:gpl2+)))
12960 (define-public python2-levenshtein
12961 (package-with-python2 python-levenshtein))
12963 (define-public python-scandir
12965 (name "python-scandir")
12970 (uri (pypi-uri "scandir" version))
12972 (base32 "0r3hvf1a9jm1rkqgx40gxkmccknkaiqjavs8lccgq9s8khh5x5s4"))))
12973 (build-system python-build-system)
12975 `(#:phases (modify-phases %standard-phases
12978 (invoke "python" "test/run_tests.py"))))))
12979 (home-page "https://github.com/benhoyt/scandir")
12980 (synopsis "Directory iteration function")
12982 "Directory iteration function like os.listdir(), except that instead of
12983 returning a list of bare filenames, it yields DirEntry objects that include
12984 file type and stat information along with the name. Using scandir() increases
12985 the speed of os.walk() by 2-20 times (depending on the platform and file
12986 system) by avoiding unnecessary calls to os.stat() in most cases.
12988 This package is part of the Python standard library since version 3.5.")
12989 (license license:bsd-3)))
12991 (define-public python2-scandir
12992 (package-with-python2 python-scandir))
12994 (define-public python2-stemming
12996 (name "python2-stemming")
13001 (uri (pypi-uri "stemming" version))
13003 (base32 "0ldwa24gnnxhniv0fhygkpc2mwgd93q10ag8rvzayv6hw418frsr"))))
13004 (build-system python-build-system)
13006 `(#:python ,python-2))
13007 (home-page "https://bitbucket.org/mchaput/stemming/overview")
13008 (synopsis "Python implementations of various stemming algorithms")
13010 "Python implementations of the Porter, Porter2, Paice-Husk, and Lovins
13011 stemming algorithms for English. These implementations are straightforward and
13012 efficient, unlike some Python versions of the same algorithms available on the
13013 Web. This package is an extraction of the stemming code included in the Whoosh
13015 (license license:public-domain)))
13017 (define-public python-factory-boy
13019 (name "python-factory-boy")
13024 (uri (pypi-uri "factory_boy" version))
13026 (base32 "1fvin6san5xsjh2c4y18caj2lnmwxlylyqm8mh1yc6rp38wlwr56"))))
13027 (build-system python-build-system)
13029 ;; Tests are not included in the tarball.
13032 `(("faker" ,python-faker)))
13033 (home-page "https://github.com/benhoyt/scandir")
13034 (synopsis "Versatile test fixtures replacement")
13036 "Factory_boy is a fixtures replacement based on thoughtbot’s factory_girl.
13038 As a fixtures replacement tool, it aims to replace static, hard to maintain
13039 fixtures with easy-to-use factories for complex object.
13041 Instead of building an exhaustive test setup with every possible combination
13042 of corner cases, factory_boy allows you to use objects customized for the
13043 current test, while only declaring the test-specific fields")
13044 (license license:expat)))
13046 (define-public python2-factory-boy
13047 (package-with-python2 python-factory-boy))
13049 (define-public python-translate-toolkit
13051 (name "python-translate-toolkit")
13056 (uri (pypi-uri "translate-toolkit" version ".tar.bz2"))
13058 (base32 "1vlkwrg83vb17jc36pmwh2b7jphwf390lz0jw8hakcg16qhwypvq"))))
13059 (build-system python-build-system)
13061 `(("python-pytest" ,python-pytest)
13062 ("python-sphinx" ,python-sphinx)))
13064 `(("python-babel" ,python-babel)
13065 ("python-beautifulsoup4" ,python-beautifulsoup4)
13066 ("python-chardet" ,python-chardet)
13067 ("python-diff-match-patch" ,python-diff-match-patch)
13068 ("python-levenshtein" ,python-levenshtein)
13069 ("python-lxml" ,python-lxml)
13070 ("python-six" ,python-six)
13071 ("python-vobject" ,python-vobject)
13072 ("python-pyyaml" ,python-pyyaml)))
13074 ;; TODO: tests are not run, because they end with
13075 ;; TypeError: parse() missing 2 required positional arguments: 'tree' and
13077 ;; during test setup.
13079 (home-page "https://toolkit.translatehouse.org")
13080 (synopsis "Tools and API for translation and localization engineering")
13082 "Tools and API for translation and localization engineering. It contains
13083 several utilities, as well as an API for building localization tools.")
13084 (license license:gpl2+)))
13086 (define-public python2-translate-toolkit
13087 (package-with-python2 python-translate-toolkit))
13089 (define-public python-packaging
13091 (name "python-packaging")
13096 (uri (pypi-uri "packaging" version))
13097 ;; XXX: The URL in the patch file is wrong, it should be
13098 ;; <https://github.com/pypa/packaging/pull/256>.
13099 (patches (search-patches "python-packaging-test-arch.patch"))
13102 "1y2ip3a4ykkpgnwgn85j6hkspcl0cg3mzms97f40mk57vwqq67gy"))))
13103 (build-system python-build-system)
13105 `(#:phases (modify-phases %standard-phases
13107 (lambda _ (invoke "py.test" "-vv"))))))
13109 `(("python-pretend" ,python-pretend)
13110 ("python-pytest" ,python-pytest)))
13112 `(("python-pyparsing" ,python-pyparsing)
13113 ("python-six" ,python-six)))
13114 (home-page "https://github.com/pypa/packaging")
13115 (synopsis "Core utilities for Python packages")
13116 (description "Packaging is a Python module for dealing with Python packages.
13117 It offers an interface for working with package versions, names, and dependency
13119 ;; From 'LICENSE': This software is made available under the terms of
13120 ;; *either* of the licenses found in LICENSE.APACHE or LICENSE.BSD.
13121 ;; Contributions to this software is made under the terms of *both* these
13123 (license (list license:asl2.0 license:bsd-2))))
13125 (define-public python2-packaging
13126 (package-with-python2 python-packaging))
13128 (define-public python-relatorio
13130 (name "python-relatorio")
13135 (uri (pypi-uri "relatorio" version))
13138 "1na6hlhz1awi1hbjg1gyclq0khz42iz90wvdjw7mmj655788bpxx"))))
13139 (build-system python-build-system)
13141 `(("python-lxml" ,python-lxml)
13142 ("python-genshi" ,python-genshi)))
13144 `(("python-magic" ,python-magic)))
13145 (home-page "https://relatorio.tryton.org/")
13146 (synopsis "Templating library able to output ODT and PDF files")
13147 (description "Relatorio is a templating library which provides a way to
13148 easily output ODT, ODS, PNG, SVG and several other kinds of files. Support
13149 for more filetypes can be easily added by creating plugins for them.")
13150 (license license:gpl3+)))
13152 (define-public python2-relatorio
13153 (package-with-python2 python-relatorio))
13155 (define-public python-radon
13157 (name "python-radon")
13162 (uri (pypi-uri "radon" version))
13165 "07gq5hq4nrffxnlnksws9hrx7fd001gam63j62i82gyfr23gvdym"))))
13166 (build-system python-build-system)
13168 `(#:phases (modify-phases %standard-phases
13171 (invoke "python" "radon/tests/run.py"))))))
13173 `(("python-colorama" ,python-colorama)
13174 ("python-flake8-polyfill" ,python-flake8-polyfill)
13175 ("python-mando" ,python-mando)))
13177 `(("python-pytest" ,python-pytest)
13178 ("python-pytest-mock" ,python-pytest-mock)))
13179 (home-page "https://radon.readthedocs.org/")
13180 (synopsis "Code Metrics in Python")
13181 (description "Radon is a Python tool which computes various code metrics.
13182 Supported metrics are:
13184 @item raw metrics: SLOC, comment lines, blank lines, &c.
13185 @item Cyclomatic Complexity (i.e. McCabe’s Complexity)
13186 @item Halstead metrics (all of them)
13187 @item the Maintainability Index (a Visual Studio metric)
13189 (license license:expat)))
13191 (define-public python2-radon
13192 (package-with-python2 python-radon))
13194 (define-public python-sure
13196 (name "python-sure")
13201 (uri (pypi-uri "sure" version))
13204 "1and0drq8w9iplsic22n2h7hkpyq03a1mbqk4sgcdqhqzdqm539w"))))
13205 (build-system python-build-system)
13207 `(("python-mock" ,python-mock)
13208 ("python-six" ,python-six)))
13210 `(("python-nose" ,python-nose)))
13211 (home-page "https://github.com/gabrielfalcao/sure")
13212 (synopsis "Automated testing library in python for python")
13214 "Sure is a python library that leverages a DSL for writing assertions.
13215 Sure is heavily inspired by @code{RSpec Expectations} and @code{should.js}.")
13216 (license license:gpl3+)))
13218 (define-public python2-sure
13219 (package-with-python2 python-sure))
13221 (define-public python2-couleur
13222 ;; This package does not seem to support python3 at all, hence,
13223 ;; only the python2 variant definition is provided.
13225 (name "python2-couleur")
13230 (uri (pypi-uri "couleur" version))
13233 "1qqaxyqz74wvid0cr119dhcwz0h0if5b5by44zl49pd5z65v58k1"))))
13234 (build-system python-build-system)
13236 `(#:python ,python-2))
13237 (home-page "https://github.com/gabrielfalcao/couleur")
13239 "ANSI terminal tool for python, colored shell and other handy fancy features")
13241 "@code{Couleur} provides python programs a way to use the ANSI features in a unix
13242 terminal such as coloured output in the shell, overwriting output, indentation, etc.")
13243 ;; README.md says ASL2.0, but all source code headers are LGPL3+.
13244 ;; https://github.com/gabrielfalcao/couleur/issues/11
13245 (license license:lgpl3+)))
13247 (define-public python-misaka
13249 (name "python-misaka")
13254 (uri (pypi-uri "misaka" version))
13257 "1mzc29wwyhyardclj1vg2xsfdibg2lzb7f1azjcxi580ama55wv2"))))
13258 (build-system python-build-system)
13260 `(;; Line 37 of setup.py calls self.run_command('develop')
13261 ;; in the 'check' phase. This command seems to be trying
13263 ;; /gnu/store/...-python-<version>/lib/python<version>/site-packages/
13264 ;; for which it does not have the permission to write.
13267 `(("python-cffi" ,python-cffi)))
13268 (home-page "https://github.com/FSX/misaka")
13269 (synopsis "Python binding for Hoedown")
13271 "@code{Misaka} is a CFFI-based binding for @code{Hoedown}, a fast markdown processing
13272 library written in C. It features a fast HTML renderer and functionality to make custom
13273 renderers (e.g. man pages or LaTeX).")
13274 (license license:expat)))
13276 (define-public python2-misaka
13277 (package-with-python2 python-misaka))
13279 (define-public python2-steadymark
13280 ;; This is forced into being a python2 only variant
13281 ;; due to its dependence on couleur that has no support
13284 (name "python2-steadymark")
13289 (uri (pypi-uri "steadymark" version))
13292 "1640i9g8dycql3cc8j0bky0jkzj0q39blfbp4lsgpkprkfgcdk8v"))))
13293 (build-system python-build-system)
13295 `(("python-couleur" ,python2-couleur)
13296 ("python-sure" ,python2-sure)
13297 ("python-misaka" ,python2-misaka)))
13299 `(#:python ,python-2
13301 (modify-phases %standard-phases
13302 (add-before 'build 'patch-setup-py
13304 ;; Update requirements from dependency==version
13305 ;; to dependency>=version
13306 (substitute* "setup.py"
13309 (home-page "https://github.com/gabrielfalcao/steadymark")
13310 (synopsis "Markdown-based test runner for python")
13312 "@code{Steadymark} allows documentation to be written in github-flavoured
13313 markdown. The documentation may contain snippets of code surrounded by python
13314 code blocks and @code{Steadymark} will find these snippets and run them, making
13315 sure that there are no old malfunctional examples in the documentation examples.")
13316 (license license:expat)))
13318 (define-public python-jsonpointer
13320 (name "python-jsonpointer")
13325 (uri (pypi-uri "jsonpointer" version))
13328 "1cg0gvgqjysydv6p45v4jywg1jb3v48c7m3cbpi57zgf6nndr9cz"))))
13329 (build-system python-build-system)
13330 (home-page "https://github.com/stefankoegl/python-json-pointer")
13331 (synopsis "Identify specific nodes in a JSON document")
13332 (description "@code{jsonpointer} allows you to access specific nodes
13333 by path in a JSON document (see RFC 6901).")
13334 (license license:bsd-3)))
13336 (define-public python2-jsonpointer
13337 (package-with-python2 python-jsonpointer))
13339 (define-public python-jsonpatch
13341 (name "python-jsonpatch")
13346 ;; pypi version lacks tests.js
13347 (uri (git-reference
13348 (url "https://github.com/stefankoegl/python-json-patch")
13349 (commit (string-append "v" version))))
13350 (file-name (git-file-name name version))
13353 "0k9pff06lxama3nhsc7cdxbp83422bdy8ifs52i6xkas8hpyzfzr"))))
13354 (build-system python-build-system)
13356 `(("python-jsonpointer" ,python-jsonpointer)))
13357 (home-page "https://github.com/stefankoegl/python-json-patch")
13358 (synopsis "Applying JSON Patches in Python 2.6+ and 3.x")
13359 (description "@code{jsonpatch} is a library and program that allows
13360 applying JSON Patches according to RFC 6902.")
13361 (license license:bsd-3)))
13363 (define-public python2-jsonpatch
13364 (package-with-python2 python-jsonpatch))
13366 (define-public python-jsonpatch-0.4
13367 (package (inherit python-jsonpatch)
13368 (name "python-jsonpatch")
13373 (uri (git-reference
13374 (url "https://github.com/stefankoegl/python-json-patch")
13375 (commit (string-append "v" version))))
13376 (file-name (git-file-name name version))
13379 "1fq02y57kinyknxjcav0slcb0k9mwdffqw2hnlhdkpj7palh2mwk"))))))
13381 (define-public python2-jsonpatch-0.4
13382 (package-with-python2 python-jsonpatch-0.4))
13384 (define-public python-rfc3986
13386 (name "python-rfc3986")
13390 (uri (pypi-uri "rfc3986" version))
13393 "06wlmysw83f75ff84zr1yr6n0shvc2xn1n1sb4iwzqap9hf5fn44"))))
13394 (build-system python-build-system)
13396 `(#:modules ((guix build utils)
13397 (guix build python-build-system)
13402 (modify-phases %standard-phases
13405 (let ((cwd (getcwd)))
13406 (setenv "PYTHONPATH"
13407 (string-append cwd "/build/"
13408 (find (cut string-prefix? "lib" <>)
13409 (scandir (string-append cwd "/build")))
13411 (getenv "PYTHONPATH")))
13412 (invoke "pytest" "-v")))))))
13414 `(("python-pytest" ,python-pytest)))
13415 (home-page "https://rfc3986.readthedocs.io/")
13416 (synopsis "Parse and validate URI references")
13418 "@code{rfc3986} is a Python implementation of RFC@tie{}3986 including
13419 validation and authority parsing. This module also supports RFC@tie{}6874
13420 which adds support for zone identifiers to IPv6 addresses.")
13421 (license license:asl2.0)))
13423 (define-public python2-rfc3986
13424 (package-with-python2 python-rfc3986))
13426 (define-public python-rfc3987
13428 (name "python-rfc3987")
13433 (uri (pypi-uri "rfc3987" version))
13436 "192pclzs2y0yaywqkrlvd0x73740q310kvqvm6jldhi619mq59wi"))))
13437 (build-system python-build-system)
13438 (home-page "https://pypi.python.org/pypi/rfc3987")
13439 (synopsis "Parsing and validation of URIs (RFC 3986) and IRIs (RFC 3987)")
13440 (description "@code{rfc3987} provides routines for parsing and
13441 validation of URIs (see RFC 3986) and IRIs (see RFC 3987).")
13442 (license license:gpl3+)))
13444 (define-public python2-rfc3987
13445 (package-with-python2 python-rfc3987))
13447 (define-public python-validate-email
13449 (name "python-validate-email")
13454 (uri (pypi-uri "validate_email" version))
13457 "1bxffaf5yz2cph8ki55vdvdypbwkvn2xr1firlcy62vqbzf1jivq"))))
13458 (build-system python-build-system)
13459 (home-page "https://github.com/syrusakbary/validate_email")
13460 (synopsis "Verifies if an email address is valid and really exists")
13461 (description "@code{validate_email} can be used to verify if an email
13462 address is valid and really exists.")
13463 (license license:lgpl3+)))
13465 (define-public python2-validate-email
13466 (package-with-python2 python-validate-email))
13468 (define-public python-flex
13470 (name "python-flex")
13475 (uri (pypi-uri "flex" version))
13478 "00pamnwla3khk8nyla7y28dq9jnh69swd7f4jfsl7sn1izs8n8zk"))))
13479 (build-system python-build-system)
13481 `(("python-click" ,python-click)
13482 ("python-iso8601" ,python-iso8601)
13483 ("python-jsonpointer" ,python-jsonpointer)
13484 ("python-pyyaml" ,python-pyyaml)
13485 ("python-requests" ,python-requests)
13486 ("python-rfc3987" ,python-rfc3987)
13487 ("python-six" ,python-six)
13488 ("python-validate-email" ,python-validate-email)))
13489 (home-page "https://github.com/pipermerriam/flex")
13490 (synopsis "Validates Swagger schemata")
13491 (description "@code{flex} can be used to validate Swagger schemata.")
13492 (license license:bsd-3)))
13494 (define-public python2-flex
13495 (package-with-python2 python-flex))
13497 (define-public python-marshmallow
13499 (name "python-marshmallow")
13500 (version "3.0.0b14")
13504 (uri (pypi-uri "marshmallow" version))
13507 "1digk3f5cfk7wmlka65mc7bzsd96pbsgcsvp6pimd5b4ff9zb5p3"))))
13508 (build-system python-build-system)
13510 `(("python-dateutil" ,python-dateutil)
13511 ("python-simplejson" ,python-simplejson)))
13513 `(("python-pytest" ,python-pytest)
13514 ("python-pytz" ,python-pytz)))
13515 (home-page "https://github.com/marshmallow-code/marshmallow")
13516 (synopsis "Convert complex datatypes to and from native
13517 Python datatypes.")
13518 (description "@code{marshmallow} provides a library for converting
13519 complex datatypes to and from native Python datatypes.")
13520 (license license:expat)))
13522 (define-public python2-marshmallow
13523 (package-with-python2 python-marshmallow))
13525 (define-public python-apispec
13527 (name "python-apispec")
13532 (uri (pypi-uri "apispec" version))
13535 "0kxa8723zbisx10363yh4mmmn4higxrspymbjfz5zq8f644zagm9"))))
13536 (build-system python-build-system)
13538 `(("python-pyyaml" ,python-pyyaml)))
13540 `(("python-pytest" ,python-pytest)
13541 ("python-flask" ,python-flask)
13542 ("python-marshmallow" ,python-marshmallow)
13543 ("python-tornado" ,python-tornado)
13544 ("python-bottle" ,python-bottle)
13545 ("python-mock" ,python-mock)))
13546 (home-page "https://github.com/marshmallow-code/apispec")
13547 (synopsis "Swagger 2.0 API specification generator")
13548 (description "@code{python-apispec} is a pluggable API specification
13549 generator. Currently supports the OpenAPI specification (f.k.a.
13551 (license license:expat)))
13553 (define-public python2-apispec
13554 (package-with-python2 python-apispec))
13556 (define-public python-flasgger
13558 (name "python-flasgger")
13563 (uri (git-reference
13564 (url "https://github.com/rochacbruno/flasgger.git")
13566 (file-name (git-file-name name version))
13568 (base32 "0yydxsyjnc0clbrjqb1n7587l6cdqvwdagwxk5hkx01qwdfbkvpn"))))
13569 (build-system python-build-system)
13572 (modify-phases %standard-phases
13574 (lambda* (#:key inputs outputs #:allow-other-keys)
13575 (substitute* "Makefile"
13576 (("flake8 flasgger --ignore=F403")
13577 "flake8 flasgger --ignore=E731,F403"))
13578 (setenv "PYTHONPATH" (string-append (getcwd)
13580 (getenv "PYTHONPATH")))
13581 (invoke "py.test"))))))
13583 `(("python-flask" ,python-flask)
13584 ("python-pyyaml" ,python-pyyaml)
13585 ("python-jsonschema" ,python-jsonschema)
13586 ("python-mistune" ,python-mistune)
13587 ("python-six" ,python-six)))
13589 `(("python-decorator" ,python-decorator)
13590 ("python-flake8" ,python-flake8)
13591 ("python-flask-restful" ,python-flask-restful)
13592 ("python-flex" ,python-flex)
13593 ("python-pytest" ,python-pytest)
13594 ("python-pytest-cov" ,python-pytest-cov)
13595 ("python-marshmallow" ,python-marshmallow)
13596 ("python-apispec" ,python-apispec)))
13597 (home-page "https://github.com/rochacbruno/flasgger/")
13598 (synopsis "Extract Swagger specs from your Flask project")
13599 (description "@code{python-flasgger} allows extracting Swagger specs
13600 from your Flask project. It is a fork of Flask-Swagger.")
13601 (license license:expat)))
13603 (define-public python2-flasgger
13604 (package-with-python2 python-flasgger))
13606 (define-public python-swagger-spec-validator
13608 (name "python-swagger-spec-validator")
13613 (uri (pypi-uri "swagger-spec-validator" version))
13616 "11g627icrsqwazsncwi0sdvprcj6hwaayw5xk3xsj8d97bmrzqjp"))))
13617 (build-system python-build-system)
13619 `(("python-jsonschema" ,python-jsonschema)
13620 ("python-pyyaml" ,python-pyyaml)
13621 ("python-six" ,python-six)))
13623 "https://github.com/Yelp/swagger_spec_validator")
13624 (synopsis "Validation of Swagger specifications")
13625 (description "@code{swagger_spec_validator} provides a library for
13626 validating Swagger API specifications.")
13627 (license license:asl2.0)))
13629 (define-public python2-swagger-spec-validator
13630 (package-with-python2 python-swagger-spec-validator))
13632 (define-public python-apache-libcloud
13634 (name "python-apache-libcloud")
13639 (uri (pypi-uri "apache-libcloud" version))
13642 "0daj3mkzw79v5zin2r1s2wkrz1hplfc16bwj4ss68i5qjq4l2p0j"))))
13643 (build-system python-build-system)
13646 (modify-phases %standard-phases
13647 (add-after 'unpack 'patch-ssh
13648 (lambda* (#:key inputs #:allow-other-keys)
13649 (substitute* "libcloud/compute/ssh.py"
13650 (("'ssh'") (string-append "'" (assoc-ref inputs "openssh")
13653 (add-after 'unpack 'patch-tests
13655 (substitute* "./libcloud/test/test_file_fixtures.py"
13656 ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-923>.
13657 (("def _ascii") "def _raw_data(self, method, url, body, headers):
13658 return (httplib.OK,
13660 {\"test\": \"value\"},
13661 httplib.responses[httplib.OK])
13663 (substitute* "libcloud/test/compute/test_ssh_client.py"
13664 (("class ShellOutSSHClientTests")
13665 "@unittest.skip(\"Guix container doesn't have ssh service\")
13666 class ShellOutSSHClientTests")
13667 ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-924>.
13668 (("'.xf0.x90.x8d.x88'") "b'\\xF0\\x90\\x8D\\x88'")
13669 (("'.xF0', '.x90', '.x8D', '.x88'")
13670 "b'\\xF0', b'\\x90', b'\\x8D', b'\\x88'"))
13672 (add-before 'check 'copy-secret
13674 (copy-file "libcloud/test/secrets.py-dist"
13675 "libcloud/test/secrets.py")
13678 `(("openssh" ,openssh)))
13680 `(("python-paramiko" ,python-paramiko)
13681 ("python-requests" ,python-requests)))
13683 `(("python-lockfile" ,python-lockfile)
13684 ("python-mock" ,python-mock)
13685 ("python-pytest" ,python-pytest)
13686 ("python-pytest-runner" ,python-pytest-runner)
13687 ("python-requests-mock" ,python-requests-mock)))
13688 (home-page "https://libcloud.apache.org/")
13689 (synopsis "Unified Cloud API")
13690 (description "@code{libcloud} is a Python library for interacting with
13691 many of the popular cloud service providers using a unified API.")
13692 (license license:asl2.0)))
13694 (define-public python2-apache-libcloud
13695 (package-with-python2 python-apache-libcloud))
13697 (define-public python-smmap2
13699 (name "python-smmap2")
13704 (uri (pypi-uri "smmap2" version))
13706 (base32 "16k03pcnxd3lgzwgbd7nl4jwzm1wmahirvd09kljnzvy96hgza99"))))
13707 (build-system python-build-system)
13709 `(("python-nosexcover" ,python-nosexcover)))
13710 (home-page "https://github.com/Byron/smmap")
13711 (synopsis "Python sliding window memory map manager")
13712 (description "@code{smmap2} is a pure Python implementation of a sliding
13713 window memory map manager.")
13714 (license license:bsd-3)))
13716 (define-public python2-smmap2
13717 (package-with-python2 python-smmap2))
13719 (define-public python-regex
13721 (name "python-regex")
13722 (version "2019.04.14")
13725 (uri (pypi-uri "regex" version))
13728 "1a6hhfs6l6snr1z654ay6wzbmwdkmv282fzfkd5hk2d1n73y8v6m"))))
13729 ;; TODO: Fix and enable regex_test.py tests that complain about the
13730 ;; test.support module not existing.
13731 (build-system python-build-system)
13732 (home-page "https://bitbucket.org/mrabarnett/mrab-regex")
13733 (synopsis "Alternative regular expression module")
13734 (description "This regular expression implementation is backwards-
13735 compatible with the standard @code{re} module, but offers additional
13736 functionality like full case-folding for case-insensitive matches in Unicode.")
13737 (license license:psfl)))
13739 (define-public python2-regex
13740 (package-with-python2 python-regex))
13742 (define-public python2-pyopengl
13744 (name "python2-pyopengl")
13749 (uri (pypi-uri "PyOpenGL" version))
13752 "1byxjj6a8rwzhxhjqlc588zdad2qwxdd7vlam2653ylll31waiwv"))))
13754 `(#:python ,python-2))
13755 (build-system python-build-system)
13756 (home-page "http://pyopengl.sourceforge.net")
13757 (synopsis "Standard OpenGL bindings for Python")
13759 "PyOpenGL is the most common cross platform Python binding to OpenGL and
13760 related APIs. The binding is created using the standard @code{ctypes}
13762 (license license:bsd-3)))
13764 (define-public python2-pyopengl-accelerate
13766 (inherit python2-pyopengl)
13767 (name "python2-pyopengl-accelerate")
13772 (uri (pypi-uri "PyOpenGL-accelerate" version))
13775 "0464c1ifzk0k92lyndikmvzjgnx1y25r7bkkc8pnxm4kp1q4czwj"))))
13776 (synopsis "Acceleration code for PyOpenGL")
13778 "This is the Cython-coded accelerator module for PyOpenGL.")))
13780 (define-public python-rencode
13782 (name "python-rencode")
13787 (uri (pypi-uri "rencode" version))
13790 "0mzwdq1is7kyyr32i5k4iz6g5xxdvmiyc132jnc60p9m6lnwjrpv"))))
13791 (build-system python-build-system)
13794 (modify-phases %standard-phases
13795 (add-before 'check 'delete-bogus-test
13796 ;; This test requires /home/aresch/Downloads, which is not provided by
13797 ;; the build environment.
13799 (delete-file "rencode/t.py")
13801 (native-inputs `(("pkg-config" ,pkg-config)
13802 ("python-cython" ,python-cython)))
13803 (home-page "https://github.com/aresch/rencode")
13804 (synopsis "Serialization of heterogeneous data structures")
13806 "The @code{rencode} module is a data structure serialization library,
13807 similar to @code{bencode} from the BitTorrent project. For complex,
13808 heterogeneous data structures with many small elements, r-encoding stake up
13809 significantly less space than b-encodings. This version of rencode is a
13810 complete rewrite in Cython to attempt to increase the performance over the
13811 pure Python module.")
13812 (license license:bsd-3)))
13814 (define-public python2-rencode
13815 (package-with-python2 python-rencode))
13817 (define-public python-xenon
13819 (name "python-xenon")
13824 (uri (pypi-uri "xenon" version))
13827 "029cbhysg2vr5n4jz8gpg2793f8wkwnqpr1qgv6c1dn685vy31mc"))))
13828 (build-system python-build-system)
13830 `(("python-pyyaml" ,python-pyyaml)
13831 ("python-radon" ,python-radon)
13832 ("python-requests" ,python-requests)
13833 ("python-flake8" ,python-flake8)
13834 ("python-tox" ,python-tox)))
13837 (modify-phases %standard-phases
13838 (add-before 'build 'patch-test-requirements
13840 ;; Remove httpretty dependency for tests.
13841 (substitute* "setup.py"
13842 (("httpretty") ""))
13844 (home-page "https://xenon.readthedocs.org/")
13845 (synopsis "Monitor code metrics for Python on your CI server")
13847 "Xenon is a monitoring tool based on Radon. It monitors code complexity.
13848 Ideally, @code{xenon} is run every time code is committed. Through command
13849 line options, various thresholds can be set for the complexity of code. It
13850 will fail (i.e. it will exit with a non-zero exit code) when any of these
13851 requirements is not met.")
13852 (license license:expat)))
13854 (define-public python2-xenon
13855 (package-with-python2 python-xenon))
13857 (define-public python-pysocks
13859 (name "python-pysocks")
13864 (uri (pypi-uri "PySocks" version))
13867 "0z4p31bpqm893cf87qqgb30k7nwd8kqfjwwjm5cvxb6zbyj1w0yr"))))
13868 (build-system python-build-system)
13869 (arguments `(#:tests? #f))
13870 (home-page "https://github.com/Anorov/PySocks")
13871 (synopsis "SOCKS client module")
13872 (description "@code{pysocks} is an updated and semi-actively maintained
13873 version of @code{SocksiPy} with bug fixes and extra features.")
13874 (license license:bsd-3)))
13876 (define-public python2-pysocks
13877 (package-with-python2 python-pysocks))
13879 (define-public python-pydiff
13881 (name "python-pydiff")
13886 (uri (pypi-uri "pydiff" version))
13889 "1als83h9w0gab24ipyna6khm390qmpnpkc5jksmdbs2xc8hp2z44"))))
13890 (build-system python-build-system)
13891 (home-page "https://github.com/myint/pydiff")
13892 (synopsis "Library to diff two Python files at the bytecode level")
13894 "@code{pydiff} makes it easy to look for actual code changes while
13895 ignoring formatting changes.")
13896 (license license:expat)))
13898 (define-public python2-pydiff
13899 (package-with-python2 python-pydiff))
13901 (define-public python-tqdm
13903 (name "python-tqdm")
13908 (uri (pypi-uri "tqdm" version))
13911 "1pw0ngm0zn9papdmkwipi3yih5c3di6d0w849bdmrraq4d2d9h2y"))))
13912 (build-system python-build-system)
13914 `(("python-flake8" ,python-flake8)
13915 ("python-nose" ,python-nose)
13916 ("python-coverage" ,python-coverage)))
13917 (home-page "https://github.com/tqdm/tqdm")
13918 (synopsis "Fast, extensible progress meter")
13920 "Make loops show a progress bar on the console by just wrapping any
13921 iterable with @code{|tqdm(iterable)|}. Offers many options to define
13922 design and layout.")
13923 (license (list license:mpl2.0 license:expat))
13924 (properties `((python2-variant . ,(delay python2-tqdm))))))
13926 (define-public python2-tqdm
13927 (let ((tqdm (package-with-python2
13928 (strip-python2-variant python-tqdm))))
13929 (package (inherit tqdm)
13930 (native-inputs `(("python2-functools32" ,python2-functools32)
13931 ,@(package-native-inputs tqdm))))))
13933 (define-public python-pkginfo
13935 (name "python-pkginfo")
13940 (uri (pypi-uri "pkginfo" version))
13943 "0x6lm17p1ks031mj6pajyp4rkq74vpqq8qwjb7ikgwmkli1day2q"))))
13944 (build-system python-build-system)
13946 ;; The tests are broken upstream.
13949 "https://code.launchpad.net/~tseaver/pkginfo/trunk")
13951 "Query metadatdata from sdists, bdists, and installed packages")
13953 "API to query the distutils metadata written in @file{PKG-INFO} inside a
13954 source distriubtion (an sdist) or a binary distribution (e.g., created by
13955 running bdist_egg). It can also query the EGG-INFO directory of an installed
13956 distribution, and the *.egg-info stored in a \"development checkout\" (e.g,
13957 created by running @code{python setup.py develop}).")
13958 (license license:expat)))
13960 (define-public python2-pkginfo
13961 (package-with-python2 python-pkginfo))
13963 (define-public python-twine
13965 (name "python-twine")
13970 (uri (pypi-uri "twine" version))
13973 "1ay1b6kdq6k4bfbjsvf6ymj41wrgpvinhxndb09355pwhxwmp96a"))))
13974 (build-system python-build-system)
13976 `(("python-tqdm" ,python-tqdm)
13977 ("python-pkginfo" ,python-pkginfo)
13978 ("python-requests" ,python-requests)
13979 ("python-requests-toolbelt" ,python-requests-toolbelt)))
13980 (home-page "https://github.com/pypa/twine")
13981 (synopsis "Collection of utilities for interacting with PyPI")
13983 "@code{twine} currently supports registering projects and uploading
13984 distributions. It authenticates the user over HTTPS, allows them to pre-sign
13985 their files and supports any packaging format (including wheels).")
13986 (license license:asl2.0)))
13988 (define-public python2-twine
13989 (package-with-python2 python-twine))
13991 (define-public python-linecache2
13993 (name "python-linecache2")
13998 (uri (pypi-uri "linecache2" version))
14001 "0z79g3ds5wk2lvnqw0y2jpakjf32h95bd9zmnvp7dnqhf57gy9jb"))))
14002 (build-system python-build-system)
14004 `(;; The tests depend on unittest2, and our version is a bit too old.
14007 `(("python-pbr" ,python-pbr-minimal)))
14009 "https://github.com/testing-cabal/linecache2")
14010 (synopsis "Backports of the linecache module")
14012 "The linecache module allows one to get any line from any file, while
14013 attempting to optimize internally, using a cache, the common case where many
14014 lines are read from a single file.")
14015 (license license:psfl)))
14017 (define-public python2-linecache2
14018 (package-with-python2 python-linecache2))
14020 (define-public python-traceback2
14022 (name "python-traceback2")
14027 (uri (pypi-uri "traceback2" version))
14030 "0c1h3jas1jp1fdbn9z2mrgn3jj0hw1x3yhnkxp7jw34q15xcdb05"))))
14031 (build-system python-build-system)
14033 `(;; python-traceback2 and python-unittest2 depend on one another.
14036 `(("python-pbr" ,python-pbr-minimal)))
14038 `(("python-linecache2" ,python-linecache2)))
14040 "https://github.com/testing-cabal/traceback2")
14041 (synopsis "Backports of the traceback module")
14043 "This module provides a standard interface to extract, format and print
14044 stack traces of Python programs. It exactly mimics the behavior of the Python
14045 interpreter when it prints a stack trace.")
14046 (license license:psfl)))
14048 (define-public python2-traceback2
14049 (package-with-python2 python-traceback2))
14051 (define-public python-ratelimiter
14053 (name "python-ratelimiter")
14058 (uri (pypi-uri "ratelimiter" version))
14061 "1dhz85mj5bqd2mij84ncs6pz32hgidr79hay4aqfmzaa4rbb497p"))))
14062 (build-system python-build-system)
14064 '(#:tests? #f)) ; There are no tests in the pypi archive.
14065 (home-page "https://github.com/RazerM/ratelimiter")
14066 (synopsis "Simple rate limiting object")
14068 "The @code{ratelimiter} module ensures that an operation will not be
14069 executed more than a given number of times during a given period.")
14070 (license license:asl2.0)))
14072 (define-public python2-ratelimiter
14073 (package-with-python2 python-ratelimiter))
14075 (define-public python-dukpy
14077 (name "python-dukpy")
14082 (uri (git-reference
14083 (url "https://github.com/kovidgoyal/dukpy.git")
14084 (commit (string-append "v" version))))
14085 (file-name (git-file-name name version))
14087 (base32 "13h21nqzasv4zj32xs61brmc106pr2cx243672crcmwxxnjgaxls"))))
14088 (build-system python-build-system)
14089 (home-page "https://github.com/kovidgoyal/dukpy")
14090 (synopsis "Run JavaScript in python")
14092 "dukpy is a JavaScript runtime environment for Python using the duktape
14093 embeddable JavaScript engine.")
14094 ;; Dukpy is licensed under MIT like the embedded duktape library,
14095 ;; with 'errors.c' as GPL3.
14096 (license (list license:expat license:gpl3))))
14098 (define-public python2-dukpy
14099 (package-with-python2 python-dukpy))
14101 (define-public python-jsonrpclib-pelix
14103 (name "python-jsonrpclib-pelix")
14108 (uri (pypi-uri "jsonrpclib-pelix" version))
14111 "0f83z5zi7w32vprhk1dyc94ir1bh4hdd57bjdbwkq9ykng8qilhl"))))
14112 (build-system python-build-system)
14114 `(#:tests? #f)) ; no tests in PyPI tarball
14115 (home-page "https://github.com/tcalmant/jsonrpclib/")
14116 (synopsis "JSON-RPC 2.0 client library for Python")
14118 "This library implements the JSON-RPC v2.0
14119 specification (backwards-compatible) as a client library for Python. This
14120 version is a fork of jsonrpclib by Josh Marshall, usable with Pelix remote
14122 (license license:asl2.0)))
14124 (define-public python2-jsonrpclib-pelix
14125 (package-with-python2 python-jsonrpclib-pelix))
14127 (define-public python-setuptools-scm-git-archive
14129 (name "python-setuptools-scm-git-archive")
14134 (uri (pypi-uri "setuptools_scm_git_archive" version))
14137 "1nii1sz5jq75ilf18bjnr11l9rz1lvdmyk66bxl7q90qan85yhjj"))))
14138 (build-system python-build-system)
14140 `(("python-pytest" ,python-pytest)))
14142 `(("python-setuptools-scm" ,python-setuptools-scm)))
14143 (home-page "https://github.com/Changaco/setuptools_scm_git_archive/")
14144 (synopsis "Setuptools_scm plugin for git archives")
14146 "The setuptools_scm_git_archive package is a plugin to
14147 setuptools_scm, which supports obtaining versions from git archives that
14148 belong to tagged versions.")
14149 (license license:expat)))
14151 (define-public python2-setuptools-scm-git-archive
14152 (package-with-python2 python-setuptools-scm-git-archive))
14154 (define-public python-setuptools-git
14156 (name "python-setuptools-git")
14161 (uri (pypi-uri "setuptools-git" version))
14164 "0i84qjwp5m0l9qagdjww2frdh63r37km1c48mrvbmaqsl1ni6r7z"))))
14165 (build-system python-build-system)
14168 (modify-phases %standard-phases
14169 ;; This is needed for tests.
14170 (add-after 'unpack 'configure-git
14172 (setenv "HOME" "/tmp")
14173 (invoke "git" "config" "--global" "user.email" "guix")
14174 (invoke "git" "config" "--global" "user.name" "guix")
14177 `(("git" ,git-minimal)))
14178 (home-page "https://github.com/msabramo/setuptools-git")
14179 (synopsis "Setuptools revision control system plugin for Git")
14181 "This package provides a plugin for Setuptools for revision control with
14183 (license license:bsd-3)))
14185 (define-public python-pyclipper
14187 (name "python-pyclipper")
14188 (version "1.1.0.post3")
14192 (uri (pypi-uri "pyclipper" version ".zip"))
14194 (base32 "164yksvqwqvwzh8f8lq92asg87hd8rvcy2xb5vm4y4ccvd5xgb7i"))
14195 (modules '((guix build utils)))
14198 ;; This file is generated by Cython.
14199 (delete-file "pyclipper/pyclipper.cpp") #t))))
14200 (build-system python-build-system)
14203 (modify-phases %standard-phases
14204 (add-before 'build 'cythonize-sources
14206 (with-directory-excursion "pyclipper"
14207 (invoke "cython" "--cplus" "pyclipper.pyx")))))))
14209 `(("python-setuptools-scm-git-archive" ,python-setuptools-scm-git-archive)))
14211 `(("python-cython" ,python-cython)
14212 ("python-pytest" ,python-pytest)
14213 ("python-pytest-runner" ,python-pytest-runner)
14214 ("python-unittest2" ,python-unittest2)
14216 (home-page "https://github.com/greginvm/pyclipper")
14217 (synopsis "Wrapper for Angus Johnson's Clipper library")
14219 "Pyclipper is a Cython wrapper for the C++ translation of the
14220 Angus Johnson's polygon clipping Clipper library (ver. 6.4.2).")
14221 (license license:expat)))
14223 (define-public python2-pyclipper
14224 (package-with-python2 python-pyclipper))
14226 (define-public python2-booleanoperations
14228 (name "python2-booleanoperations")
14233 (uri (pypi-uri "booleanOperations" version ".zip"))
14236 "1hw42fazdpvsn77glx96hwsj9l17mvx37sc5707s08y5w6fx16mn"))))
14237 (build-system python-build-system)
14239 `(#:python ,python-2))
14242 ("python2-pytest" ,python2-pytest)
14243 ("python2-pytest-runner" ,python2-pytest-runner)))
14245 `(("python-fonttools" ,python2-fonttools)
14246 ("python-pyclipper" ,python2-pyclipper)
14247 ("python-ufolib" ,python2-ufolib)))
14248 (home-page "https://github.com/typemytype/booleanOperations")
14249 (synopsis "Boolean operations on paths")
14251 "BooleanOperations provides a Python library that enables
14252 boolean operations on paths.")
14253 (license license:expat)))
14255 (define-public python-tempdir
14257 (name "python-tempdir")
14262 (uri (pypi-uri "tempdir" version))
14265 "13msyyxqbicr111a294x7fsqbkl6a31fyrqflx3q7k547gnq15k8"))))
14266 (build-system python-build-system)
14267 (home-page "https://pypi.org/project/tempdir/")
14269 ;; the package has no tests
14271 (synopsis "Python library for managing temporary directories")
14273 "This library manages temporary directories that are automatically
14274 deleted with all their contents when they are no longer needed. It is
14275 particularly convenient for use in tests.")
14276 (license license:expat)))
14278 (define-public python2-tempdir
14279 (package-with-python2 python-tempdir))
14281 (define-public python-activepapers
14283 (name "python-activepapers")
14288 (uri (pypi-uri "ActivePapers.Py" version))
14291 "12wkhjh90ffipjzv10swndp2xv9hd7xrxvg6v0n4n3i411pj4xb8"))))
14292 (build-system python-build-system)
14294 `(#:modules ((ice-9 ftw)
14297 (guix build python-build-system))
14300 (modify-phases %standard-phases
14301 (add-after 'unpack 'delete-python2-code
14303 (for-each delete-file
14304 '("lib/activepapers/builtins2.py"
14305 "lib/activepapers/standardlib2.py"
14306 "lib/activepapers/utility2.py"))))
14309 ;; Deactivate the test cases that download files
14310 (setenv "NO_NETWORK_ACCESS" "1")
14311 ;; For some strange reason, some tests fail if nosetests runs all
14312 ;; test modules in a single execution. They pass if each test
14313 ;; module is run individually.
14314 (for-each (lambda (filename)
14315 (invoke "nosetests"
14316 (string-append "tests/" filename)))
14319 (string-suffix? ".py" filename)))))))))
14321 `(("python-tempdir" ,python-tempdir)
14322 ("python-nose" ,python-nose)))
14324 `(("python-h5py" ,python-h5py)))
14325 (home-page "http://www.activepapers.org/")
14326 (synopsis "Executable papers for scientific computing")
14328 "ActivePapers is a tool for working with executable papers, which
14329 combine data, code, and documentation in single-file packages,
14330 suitable for publication as supplementary material or on repositories
14331 such as figshare or Zenodo.")
14332 (properties `((python2-variant . ,(delay python2-activepapers))))
14333 (license license:bsd-3)))
14335 (define-public python2-activepapers
14336 (let ((base (package-with-python2
14337 (strip-python2-variant python-activepapers))))
14341 (substitute-keyword-arguments (package-arguments base)
14343 `(modify-phases ,phases
14344 (delete 'delete-python2-code)
14345 (add-after 'unpack 'delete-python3-code
14347 (for-each delete-file
14348 '("lib/activepapers/builtins3.py"
14349 "lib/activepapers/standardlib3.py"
14350 "lib/activepapers/utility3.py")))))))))))
14352 (define-public python-semver
14354 (name "python-semver")
14359 (uri (pypi-uri "semver" version))
14362 "183kg1rhzz3hqizvphkd8hlbf1zxfx8737zhfkmqzxi71jmdw7pd"))))
14363 (build-system python-build-system)
14365 `(("python-tox" ,python-tox)
14366 ("python-virtualenv" ,python-virtualenv)))
14367 (home-page "https://github.com/k-bx/python-semver")
14368 (synopsis "Python helper for Semantic Versioning")
14369 (description "This package provides a Python library for
14370 @url{Semantic Versioning, http://semver.org/}.")
14371 (license license:bsd-3)))
14373 (define-public python2-semver
14374 (package-with-python2 python-semver))
14376 (define-public python-pyro4
14378 (name "python-pyro4")
14383 (uri (pypi-uri "Pyro4" version))
14385 (base32 "0gsjg869y4gpy265s1gj1f2qy6jn5iz8r2bwwnq78r1r5yi15zib"))))
14386 (build-system python-build-system)
14388 '(#:tests? #f)) ;FIXME: Some tests require network access.
14390 `(("python-cloudpickle" ,python-cloudpickle)
14391 ("python-dill" ,python-dill)
14392 ("python-msgpack" ,python-msgpack)))
14394 `(("python-serpent" ,python-serpent)))
14395 (home-page "https://pyro4.readthedocs.io")
14396 (synopsis "Distributed object middleware for Python")
14398 "Pyro enables you to build applications in which objects can talk to each
14399 other over the network. You can just use normal Python method calls to call
14400 objects on other machines, also known as remote procedure calls (RPC).")
14401 (license license:expat)))
14403 (define-public python2-pyro
14405 (name "python2-pyro")
14410 (uri (pypi-uri "Pyro" version))
14411 (file-name (string-append "Pyro-" version ".tar.gz"))
14414 "0y75wzdqbjy565rpxaxscav4j8xg060sa90lnmb7aypgaf251v8v"))))
14415 (build-system python-build-system)
14417 ;; Pyro is not compatible with Python 3
14418 `(#:python ,python-2
14419 ;; Pyro has no test cases for automatic execution
14421 (home-page "http://pythonhosted.org/Pyro/")
14422 (synopsis "Distributed object manager for Python")
14423 (description "Pyro is a Distributed Object Technology system
14424 written in Python that is designed to be easy to use. It resembles
14425 Java's Remote Method Invocation (RMI). It has less similarity to CORBA,
14426 which is a system and language independent Distributed Object Technology
14427 and has much more to offer than Pyro or RMI. Pyro 3.x is no
14428 longer maintained. New projects should use Pyro4 instead, which
14429 is the new Pyro version that is actively developed.")
14430 (license license:expat)))
14432 (define-public python2-scientific
14434 (name "python2-scientific")
14439 (uri (git-reference
14440 (url "https://github.com/khinsen/ScientificPython")
14441 (commit (string-append "rel" version))))
14442 (file-name (git-file-name name version))
14445 "16l48aj9fps9r7jyk8gpxppwrv0fqvlc13sayxskz28r5s6sjwbl"))))
14446 (build-system python-build-system)
14448 `(("netcdf" ,netcdf)))
14450 `(("python-numpy" ,python2-numpy-1.8)
14451 ("python-pyro" ,python2-pyro)))
14453 ;; ScientificPython is not compatible with Python 3
14454 `(#:python ,python-2
14455 #:tests? #f ; No test suite
14457 (modify-phases %standard-phases
14459 (lambda* (#:key inputs #:allow-other-keys)
14460 (invoke "python" "setup.py" "build"
14461 (string-append "--netcdf_prefix="
14462 (assoc-ref inputs "netcdf"))))))))
14463 (home-page "http://dirac.cnrs-orleans.fr/ScientificPython")
14464 (synopsis "Python modules for scientific computing")
14465 (description "ScientificPython is a collection of Python modules that are
14466 useful for scientific computing. Most modules are rather general (Geometry,
14467 physical units, automatic derivatives, ...) whereas others are more
14468 domain-specific (e.g. netCDF and PDB support). The library is currently
14469 not actively maintained and works only with Python 2 and NumPy < 1.9.")
14470 (license license:cecill-c)))
14472 (define-public python2-mmtk
14474 (name "python2-mmtk")
14479 (uri (git-reference
14480 (url "https://github.com/khinsen/MMTK")
14481 (commit (string-append "rel" version))))
14482 (file-name (git-file-name name version))
14485 "1fqwh3ba9jd42nigvn5shndgwb1zy7kh9520ncvqci7n8ffjr6p1"))))
14486 (build-system python-build-system)
14488 `(("netcdf" ,netcdf)))
14490 `(("python-scientific" ,python2-scientific)
14491 ("python-tkinter" ,python-2 "tk")))
14493 `(#:python ,python-2
14496 (modify-phases %standard-phases
14497 (add-before 'build 'includes-from-scientific
14498 (lambda* (#:key inputs #:allow-other-keys)
14499 (mkdir-p "Include/Scientific")
14502 (assoc-ref inputs "python-scientific")
14503 "/include/python2.7/Scientific")
14504 "Include/Scientific"))))))
14505 (home-page "http://dirac.cnrs-orleans.fr/MMTK")
14506 (synopsis "Python library for molecular simulation")
14507 (description "MMTK is a library for molecular simulations with an emphasis
14508 on biomolecules. It provides widely used methods such as Molecular Dynamics
14509 and normal mode analysis, but also basic routines for implementing new methods
14510 for simulation and analysis. The library is currently not actively maintained
14511 and works only with Python 2 and NumPy < 1.9.")
14512 (license license:cecill-c)))
14514 (define-public python-phonenumbers
14516 (name "python-phonenumbers")
14521 (uri (pypi-uri "phonenumbers" version))
14524 "03fmrgb4r8x3ykmddjs9i3zhs703in8smikj3a6447blqpimwyh1"))))
14525 (build-system python-build-system)
14527 "https://github.com/daviddrysdale/python-phonenumbers")
14529 "Python library for dealing with international phone numbers")
14531 "This package provides a Python port of Google's libphonenumber library.")
14532 (license license:asl2.0)))
14534 (define-public python2-phonenumbers
14535 (package-with-python2 python-phonenumbers))
14537 (define-public python-send2trash
14539 (name "python-send2trash")
14542 (origin (method git-fetch)
14543 ;; Source tarball on PyPI doesn't include tests.
14544 (uri (git-reference
14545 (url "https://github.com/hsoft/send2trash.git")
14547 (file-name (git-file-name name version))
14550 "1c76zldhw2ay7q7r00nnzcampjz9lkqfcbzqpm0iqp5i6bmmv30v"))))
14551 (build-system python-build-system)
14554 (modify-phases %standard-phases
14555 (add-before 'check 'pre-check
14557 (mkdir-p "/tmp/foo")
14558 (setenv "HOME" "/tmp/foo")
14560 (home-page "https://github.com/hsoft/send2trash")
14561 (synopsis "Send files to the user's @file{~/Trash} directory")
14562 (description "This package provides a Python library to send files to the
14563 user's @file{~/Trash} directory.")
14564 (properties `((python2-variant . ,(delay python2-send2trash))))
14565 (license license:bsd-3)))
14567 (define-public python2-send2trash
14569 (inherit (package-with-python2 (strip-python2-variant python-send2trash)))
14571 (substitute-keyword-arguments (package-arguments python-send2trash)
14573 `(modify-phases ,phases
14574 (add-before 'check 'setenv
14576 (setenv "PYTHONPATH"
14577 (string-append (getcwd) ":" (getenv "PYTHONPATH")))
14580 (define-public python-yapf
14582 (name "python-yapf")
14587 (uri (pypi-uri "yapf" version))
14590 "1pj3xzblmbssshi889b6n9hwqbjpabw6j0fimlng2sshd3226bki"))))
14591 (build-system python-build-system)
14592 (home-page "https://github.com/google/yapf")
14593 (synopsis "Formatter for Python code")
14594 (description "YAPF is a formatter for Python code. It's based off of
14595 @dfn{clang-format}, developed by Daniel Jasper. In essence, the algorithm
14596 takes the code and reformats it to the best formatting that conforms to the
14597 style guide, even if the original code didn't violate the style guide.")
14598 (license license:asl2.0)))
14600 (define-public python2-yapf
14601 (package-with-python2 python-yapf))
14603 (define-public python-gyp
14604 (let ((commit "5e2b3ddde7cda5eb6bc09a5546a76b00e49d888f")
14607 (name "python-gyp")
14608 ;; Google does not release versions,
14609 ;; based on second most recent commit date.
14610 (version (git-version "0.0.0" revision commit))
14613 ;; Google does not release tarballs,
14614 ;; git checkout is needed.
14616 (uri (git-reference
14617 (url "https://chromium.googlesource.com/external/gyp")
14619 (file-name (git-file-name name version))
14622 "0fr7nxcrk292djmxzpcjaphnsd123k31gp8jnd91vwknhq6snmv9"))))
14623 (build-system python-build-system)
14624 (home-page "https://gyp.gsrc.io/")
14625 (synopsis "GYP is a Meta-Build system")
14627 "GYP builds build systems for large, cross platform applications.
14628 It can be used to generate XCode projects, Visual Studio projects, Ninja build
14629 files, and Makefiles.")
14630 (license license:bsd-3))))
14632 (define-public python2-gyp
14633 (package-with-python2 python-gyp))
14635 (define-public python-whatever
14637 (name "python-whatever")
14642 (uri (git-reference
14643 (url "https://github.com/Suor/whatever")
14645 (file-name (git-file-name name version))
14647 (base32 "1q7ajgqjfivxqsqgnhp4lc4p6jxyh4zprcsdbpd6dw54inaf0av5"))))
14648 (build-system python-build-system)
14651 (modify-phases %standard-phases
14654 (invoke "py.test"))))))
14656 `(("python-pytest" ,python-pytest)))
14657 (home-page "http://github.com/Suor/whatever")
14658 (synopsis "Make anonymous functions by partial application of operators")
14659 (description "@code{whatever} provides an easy way to make anonymous
14660 functions by partial application of operators.")
14661 (license license:bsd-3)))
14663 (define-public python2-whatever
14664 (package-with-python2 python-whatever))
14666 (define-public python-funcy
14668 (name "python-funcy")
14673 (uri (git-reference
14674 (url "https://github.com/Suor/funcy.git")
14677 (base32 "1s98vkjnq3zq71737hn8xa15kssvmy1sfzsll3vrlv53902418mw"))
14678 (file-name (git-file-name name version))))
14679 (build-system python-build-system)
14682 (modify-phases %standard-phases
14685 (invoke "py.test"))))))
14687 `(("python-pytest" ,python-pytest)
14688 ("python-whatever" ,python-whatever)))
14689 (home-page "http://github.com/Suor/funcy")
14690 (synopsis "Functional tools")
14691 (description "@code{funcy} is a library that provides functional tools.
14694 @item merge - Merges collections of the same type
14695 @item walk - Type-preserving map
14696 @item select - Selects a part of a collection
14697 @item take - Takes the first n items of a collection
14698 @item first - Takes the first item of a collection
14699 @item remove - Predicated-removes items of a collection
14700 @item concat - Concatenates two collections
14701 @item flatten - Flattens a collection with subcollections
14702 @item distinct - Returns only distinct items
14703 @item split - Predicated-splits a collection
14704 @item split_at - Splits a collection at a given item
14705 @item group_by - Groups items by group
14706 @item pairwise - Pairs off adjacent items
14707 @item partial - Partially-applies a function
14708 @item curry - Curries a function
14709 @item compose - Composes functions
14710 @item complement - Complements a predicate
14711 @item all_fn - \"all\" with predicate
14713 (license license:bsd-3)))
14715 (define-public python2-funcy
14716 (package-with-python2 python-funcy))
14718 (define-public python-isoweek
14720 (name "python-isoweek")
14725 (uri (pypi-uri "isoweek" version))
14728 "1s7zsf0pab0l9gn6456qadnz5i5h90hafcjwnhx5mq23qjxggwvk"))))
14729 (build-system python-build-system)
14730 (home-page "https://github.com/gisle/isoweek")
14731 (synopsis "Objects representing a week")
14732 (description "The @code{isoweek} module provide the class Week that
14733 implements the week definition of ISO 8601. This standard also defines
14734 a notation for identifying weeks; yyyyWww (where the W is a literal).
14735 Week instances stringify to this form.")
14736 (license license:bsd-3)))
14738 (define-public python2-isoweek
14739 (package-with-python2 python-isoweek))
14741 (define-public python-tokenize-rt
14743 (name "python-tokenize-rt")
14748 (uri (pypi-uri "tokenize-rt" version))
14751 "1yjvbz7rvrz31zjyax1cgy3xhf4wb3j18jwnj4bnl77ca4gliyiw"))))
14752 (build-system python-build-system)
14753 (home-page "https://github.com/asottile/tokenize-rt")
14754 (synopsis "Wrapper around the stdlib tokenize which roundtrips.")
14756 "This Python library is a wrapper around @code{tokenize} from the Python
14757 standard library. It provides two additional tokens @code{ESCAPED_NL} and
14758 @code{UNIMPORTANT_WS}, and a @code{Token} data type. Use @code{src_to_tokens}
14759 and @code{tokens_to_src} to roundtrip.")
14760 (license license:expat)))
14762 (define-public python-future-fstrings
14764 (name "python-future-fstrings")
14769 (uri (pypi-uri "future_fstrings" version))
14772 "0ydxqz2dvns44g55p8ix2x18qkfk3aaz0m0dc70f3g6n8js35h47"))))
14773 (build-system python-build-system)
14775 `(("python-tokenize-rt" ,python-tokenize-rt)))
14776 (home-page "https://github.com/asottile/future-fstrings")
14777 (synopsis "Backport of fstrings to Python < 3.6")
14779 "This package provides a UTF-8 compatible encoding
14780 @code{future_fstrings}, which performs source manipulation. It decodes the
14781 source bytes using the UTF-8 encoding and then rewrites Python 3.6 style
14782 @code{f} strings.")
14783 (license license:expat)))
14785 (define-public python-typed-ast
14787 (name "python-typed-ast")
14792 (uri (git-reference
14793 (url "https://github.com/python/typed_ast.git")
14796 (base32 "0l0hz809f7i356kmqkvfsaswiidb98j9hs9rrjnfawzqcbffzgyb"))
14797 (file-name (git-file-name name version))))
14798 (build-system python-build-system)
14800 `(#:modules ((guix build utils)
14801 (guix build python-build-system)
14806 (modify-phases %standard-phases
14809 (let ((cwd (getcwd)))
14810 (setenv "PYTHONPATH"
14811 (string-append cwd "/build/"
14812 (find (cut string-prefix? "lib" <>)
14813 (scandir (string-append cwd "/build")))
14815 (getenv "PYTHONPATH"))))
14818 (native-inputs `(("python-pytest" ,python-pytest)))
14819 (home-page "https://github.com/python/typed_ast")
14820 (synopsis "Fork of Python @code{ast} modules with type comment support")
14821 (description "This package provides a parser similar to the standard
14822 @code{ast} library. Unlike @code{ast}, the parsers in @code{typed_ast}
14823 include PEP 484 type comments and are independent of the version of Python
14824 under which they are run. The @code{typed_ast} parsers produce the standard
14825 Python AST (plus type comments), and are both fast and correct, as they are
14826 based on the CPython 2.7 and 3.7 parsers.")
14827 ;; See the file "LICENSE" for the details.
14828 (license (list license:psfl
14830 license:expat)))) ;ast27/Parser/spark.py
14832 (define-public python-typing
14834 (name "python-typing")
14839 (uri (pypi-uri "typing" version))
14842 "0ba9acs4awx15bf9v3nrs781msbd2nx826906nj6fqks2bvca9s0"))))
14843 (build-system python-build-system)
14844 (home-page "https://docs.python.org/3/library/typing.html")
14845 (synopsis "Type hints for Python")
14846 (description "This is a backport of the standard library @code{typing}
14847 module to Python versions older than 3.5. Typing defines a standard notation
14848 for Python function and variable type annotations. The notation can be used
14849 for documenting code in a concise, standard format, and it has been designed
14850 to also be used by static and runtime type checkers, static analyzers, IDEs
14852 (license license:psfl)))
14854 (define-public python2-typing
14855 (package-with-python2 python-typing))
14857 (define-public python-typing-extensions
14859 (name "python-typing-extensions")
14864 (uri (pypi-uri "typing_extensions" version))
14867 "0wfsv71pvkyf2na938l579jh0v3kzl6g744ijgnahcwd4d9x0b7v"))))
14868 (build-system python-build-system)
14870 "https://github.com/python/typing/blob/master/typing_extensions/README.rst")
14871 (synopsis "Experimental type hints for Python")
14873 "The typing_extensions module contains additional @code{typing} hints not
14874 yet present in the of the @code{typing} standard library.
14875 Included are implementations of:
14878 @item ContextManager
14889 @item TYPE_CHECKING
14890 @item AsyncGenerator
14892 (license license:psfl)))
14894 (define-public bpython
14901 (uri (pypi-uri "bpython" version))
14903 (base32 "1hl6frgvr2lqaxqczl8amg9xih32b3gzv429vs0qrjb8wpdj1k2n"))))
14904 (build-system python-build-system)
14907 (modify-phases %standard-phases
14908 (add-after 'unpack 'remove-failing-test
14910 ;; Remove failing test. FIXME: make it pass
14911 (delete-file "bpython/test/test_args.py")
14913 (add-after 'wrap 'add-aliases
14914 ;; for symmetry to bpython2, add symlinks bypthon3, bpdb3, etc.
14915 (lambda* (#:key outputs #:allow-other-keys)
14916 (let ((out (assoc-ref outputs "out")))
14919 (symlink old (string-append out "/bin/" new)))
14920 '("bpython" "bpython-curses" "bpython-urwid" "bpdb")
14921 '("bpython3" "bpython3-curses" "bpython3-urwid" "bpdb3")))
14924 `(("python-pygments" ,python-pygments)
14925 ("python-requests" ,python-requests)
14926 ("python-babel" ,python-babel) ; optional, for internationalization
14927 ("python-curtsies" ,python-curtsies) ; >= 0.1.18
14928 ("python-greenlet" ,python-greenlet)
14929 ("python-urwid" ,python-urwid) ; for bpython-urwid only
14930 ("python-six" ,python-six)))
14932 `(("python-sphinx" ,python-sphinx)
14933 ("python-mock" ,python-mock)))
14934 (home-page "https://bpython-interpreter.org/")
14935 (synopsis "Fancy interface to the Python interpreter")
14936 (description "Bpython is a fancy interface to the Python
14937 interpreter. bpython's main features are
14940 @item in-line syntax highlighting,
14941 @item readline-like autocomplete with suggestions displayed as you type,
14942 @item expected parameter list for any Python function,
14943 @item \"rewind\" function to pop the last line of code from memory and
14945 @item send the code you've entered off to a pastebin,
14946 @item save the code you've entered to a file, and
14947 @item auto-indentation.
14949 (license license:expat)))
14951 (define-public bpython2
14952 (let ((base (package-with-python2
14953 (strip-python2-variant bpython))))
14954 (package (inherit base)
14957 `(#:python ,python-2
14959 (modify-phases %standard-phases
14960 (add-after 'unpack 'remove-failing-test
14962 ;; Remove failing test. FIXME: make it pass
14963 (delete-file "bpython/test/test_args.py")
14964 ;; Disable failing test-cases (renaming inhibits they are
14966 (substitute* "bpython/test/test_curtsies_repl.py"
14967 (("^(\\s*def )(test_get_last_word_with_prev_line\\W)" _ a b)
14968 (string-append a "xxx_off_" b))
14969 (("^(\\s*def )(test_complex\\W)" _ a b)
14970 (string-append a "xxx_off_" b)))
14972 (add-before 'build 'rename-scripts
14973 ;; rename the scripts to bypthon2, bpdb2, etc.
14975 (substitute* "setup.py"
14976 (("^(\\s+'bpdb)(\\s+=.*',?)\\s*?$" _ name rest)
14977 (string-append name "2" rest "\n"))
14978 (("^(\\s+'bpython)(-\\S+)?(\\s+=.*',?)\\s*?$" _ name sub rest)
14979 (string-append name "2" (or sub "") rest "\n")))
14982 (define-public python-pyinotify
14984 (name "python-pyinotify")
14988 (uri (pypi-uri "pyinotify" version))
14991 "1x3i9wmzw33fpkis203alygfnrkcmq9w1aydcm887jh6frfqm6cw"))))
14992 (build-system python-build-system)
14993 (arguments `(#:tests? #f)) ;no tests
14994 (home-page "https://github.com/seb-m/pyinotify")
14995 (synopsis "Python library for monitoring inotify events")
14997 "@code{pyinotify} provides a Python interface for monitoring
14998 file system events on Linux.")
14999 (license license:expat)))
15001 (define-public python2-pyinotify
15002 (package-with-python2 python-pyinotify))
15004 ;; Ada parser uses this version.
15005 (define-public python2-quex-0.67.3
15007 (name "python2-quex")
15012 (uri (string-append "mirror://sourceforge/quex/HISTORY/"
15013 (version-major+minor version)
15014 "/quex-" version ".zip"))
15017 "14gv8ll3ipqv4kyc2xiy891nrmjl4ic823zfyx8hassagyclyppw"))))
15018 (build-system python-build-system)
15020 `(("unzip" ,unzip)))
15022 `(#:python ,python-2
15025 (modify-phases %standard-phases
15026 (delete 'configure)
15029 (lambda* (#:key outputs #:allow-other-keys)
15030 (let* ((out (assoc-ref outputs "out"))
15031 (share/quex (string-append out "/share/quex"))
15032 (bin (string-append out "/bin")))
15033 (copy-recursively "." share/quex)
15035 (symlink (string-append share/quex "/quex-exe.py")
15036 (string-append bin "/quex"))
15038 (native-search-paths
15039 (list (search-path-specification
15040 (variable "QUEX_PATH")
15041 (files '("share/quex")))))
15042 (home-page "http://quex.sourceforge.net/")
15043 (synopsis "Lexical analyzer generator in Python")
15044 (description "@code{quex} is a lexical analyzer generator in Python.")
15045 (license license:lgpl2.1+))) ; Non-military
15047 (define-public python2-quex
15048 (package (inherit python2-quex-0.67.3)
15049 (name "python2-quex")
15054 (uri (string-append "mirror://sourceforge/quex/DOWNLOAD/quex-" version ".tar.gz"))
15057 "0svc9nla3b9145d6b7fb9dizx412l3difzqw0ilh9lz52nsixw8j"))
15058 (file-name (string-append name "-" version ".tar.gz"))))))
15060 (define-public python-more-itertools
15062 (name "python-more-itertools")
15067 (uri (pypi-uri "more-itertools" version))
15070 "16phg2f2dvm6ci5wr49ncha5lmc0m2in3bsl33c61vzca4gkvd4b"))))
15071 (build-system python-build-system)
15072 (home-page "https://github.com/erikrose/more-itertools")
15073 (synopsis "More routines for operating on iterables, beyond itertools")
15074 (description "Python's built-in @code{itertools} module implements a
15075 number of iterator building blocks inspired by constructs from APL, Haskell,
15076 and SML. @code{more-itertools} includes additional building blocks for
15077 working with iterables.")
15078 (properties `((python2-variant . ,(delay python2-more-itertools))))
15079 (license license:expat)))
15081 ;; The 5.x series are the last versions supporting Python 2.7.
15082 (define-public python2-more-itertools
15084 (inherit python-more-itertools)
15085 (name "python2-more-itertools")
15089 (uri (pypi-uri "more-itertools" version))
15092 "1r12cm6mcdwdzz7d47a6g4l437xsvapdlgyhqay3i2nrlv03da9q"))))
15094 `(#:python ,python2-minimal))
15096 `(("python2-six" ,python2-six-bootstrap)))))
15098 (define-public python-latexcodec
15100 (name "python-latexcodec")
15105 (uri (pypi-uri "latexcodec" version))
15107 (base32 "0wnp3yqcgx0rpy8dz51vh75lbp2qif67da19zi7m3ca98n887hgb"))))
15108 (build-system python-build-system)
15110 `(("python-six" ,python-six)))
15111 (home-page "https://readthedocs.org/projects/latexcodec/")
15112 (synopsis "Work with LaTeX code in Python")
15113 (description "Lexer and codec to work with LaTeX code in Python.")
15114 (license license:expat)))
15116 (define-public python-pybtex
15118 (name "python-pybtex")
15123 (uri (pypi-uri "pybtex" version))
15125 (base32 "070wfcmxrd7xg1si421mi9150gmx2qwx431nwf69sq3hhmgnx080"))))
15126 (build-system python-build-system)
15128 `(("python-nose" ,python-nose)))
15130 `(("python-latexcodec" ,python-latexcodec)
15131 ("python-pyyaml" ,python-pyyaml)
15132 ("python-six" ,python-six)))
15134 `(#:test-target "nosetests"))
15135 (home-page "https://pybtex.org/")
15136 (synopsis "BibTeX-compatible bibliography processor")
15137 (description "Pybtex is a BibTeX-compatible bibliography processor written
15138 in Python. You can simply type pybtex instead of bibtex.")
15139 (license license:expat)))
15141 (define-public python-onetimepass
15143 (name "python-onetimepass")
15148 (uri (pypi-uri "onetimepass" version))
15150 (base32 "09vagxgbq78wvq4xbikmn2hpqqsa2i96kqsmphf7dqynfv0dlsd5"))))
15151 (build-system python-build-system)
15152 (propagated-inputs `(("python-six" ,python-six)))
15153 (home-page "https://github.com/tadeck/onetimepass/")
15154 (synopsis "One-time password library")
15155 (description "Python one-time password library for HMAC-based (HOTP) and
15156 time-based (TOTP) passwords.")
15157 (license license:expat)))
15159 (define-public python-parso
15161 (name "python-parso")
15166 (uri (pypi-uri "parso" version))
15169 "171a9ivhxwsd52h1cgsz40zgzpgzscn7yqb7sdjhy8m1lzj0wsv6"))))
15171 `(("python-pytest" ,python-pytest)))
15172 (build-system python-build-system)
15174 `(#:phases (modify-phases %standard-phases
15176 (lambda _ (invoke "pytest" "-vv"))))))
15177 (home-page "https://github.com/davidhalter/parso")
15178 (synopsis "Python Parser")
15179 (description "Parso is a Python parser that supports error recovery and
15180 round-trip parsing for different Python versions (in multiple Python versions).
15181 Parso is also able to list multiple syntax errors in your Python file.")
15182 (license license:expat)))
15184 (define-public python2-parso
15185 (package-with-python2 python-parso))
15187 (define-public python-async-generator
15189 (name "python-async-generator")
15194 (uri (pypi-uri "async_generator" version))
15197 "0i11f6z6lix8ixi3vsk6s76zvvpmgrw6zjrcwjm0m4hjdh83vfvf"))))
15198 (build-system python-build-system)
15200 `(("python-pytest" ,python-pytest)))
15201 (home-page "https://github.com/python-trio/async_generator")
15202 (synopsis "Async generators and context managers for Python 3.5+")
15203 (description "@code{async_generator} back-ports Python 3.6's native async
15204 generators and Python 3.7's context managers into Python 3.5.")
15206 (license (list license:expat license:asl2.0))))
15208 (define-public python-async-timeout
15210 (name "python-async-timeout")
15215 (uri (pypi-uri "async-timeout" version))
15218 "0pscbyr840m7fyfc3r8zv9kgkwdcn9f78p7zsrczciwd09m82g0c"))))
15219 (build-system python-build-system)
15220 (home-page "https://github.com/aio-libs/async_timeout/")
15221 (synopsis "Timeout context manager for asyncio programs")
15222 (description "@code{async-timeout} provides a timeout timeout context
15223 manager compatible with @code{asyncio}.")
15224 (license license:asl2.0)))
15226 (define-public python-glob2
15228 (name "python-glob2")
15233 (uri (git-reference
15234 (url "https://github.com/miracle2k/python-glob2.git")
15235 (commit (string-append "v" version))))
15236 (file-name (git-file-name name version))
15238 (base32 "160nh2ay9lw2hi0rixpzb2k87r6ql56k0j2cm87lqz8xc8zbw919"))))
15239 (build-system python-build-system)
15240 (home-page "https://github.com/miracle2k/python-glob2/")
15241 (synopsis "Extended Version of the python buildin glob module")
15242 (description "This is an extended version of the Python
15243 @url{http://docs.python.org/library/glob.html, built-in glob module} which
15247 @item The ability to capture the text matched by glob patterns, and return
15248 those matches alongside the file names.
15249 @item A recursive @code{**} globbing syntax, akin for example to the
15250 @code{globstar} option of Bash.
15251 @item The ability to replace the file system functions used, in order to glob
15252 on virtual file systems.
15253 @item Compatible with Python 2 and Python 3 (tested with 3.3).
15256 Glob2 currently based on the glob code from Python 3.3.1.")
15257 (license license:bsd-2)))
15259 (define-public python2-glob2
15260 (package-with-python2 python-glob2))
15262 (define-public python-gipc
15264 (name "python-gipc")
15269 (uri (pypi-uri "gipc" version ".zip"))
15272 "0pd9by719qh882hqs6xpby61sn1x5h98hms5p2p8yqnycrf1s0h2"))))
15273 (build-system python-build-system)
15275 `(("unzip" ,unzip)))
15277 `(("python-gevent" ,python-gevent)))
15278 (home-page "http://gehrcke.de/gipc")
15279 (synopsis "Child process management in the context of gevent")
15280 (description "Usage of Python's multiprocessing package in a
15281 gevent-powered application may raise problems. With @code{gipc},
15282 process-based child processes can safely be created anywhere within a
15283 gevent-powered application.")
15284 (license license:expat)))
15286 (define-public python2-gipc
15287 (package-with-python2 python-gipc))
15289 (define-public python-fusepy
15291 (name "python-fusepy")
15296 (uri (pypi-uri "fusepy" version))
15299 "0v5grm4zyf58hsplwsxfbihddw95lz9w8cy3rpzbyha287swgx8h"))))
15300 (build-system python-build-system)
15303 (modify-phases %standard-phases
15304 (add-before 'build 'set-library-file-name
15305 (lambda* (#:key inputs #:allow-other-keys)
15306 (let ((fuse (assoc-ref inputs "fuse")))
15307 (substitute* "fuse.py"
15308 (("find_library\\('fuse'\\)")
15309 (string-append "'" fuse "/lib/libfuse.so'")))
15313 (home-page "https://github.com/fusepy/fusepy")
15314 (synopsis "Simple ctypes bindings for FUSE")
15315 (description "Python module that provides a simple interface to FUSE and
15316 MacFUSE. The binding is created using the standard @code{ctypes} library.")
15317 (license license:isc)))
15319 (define-public python2-fusepy
15320 (package-with-python2 python-fusepy))
15322 (define-public python2-gdrivefs
15324 (name "python2-gdrivefs")
15329 (uri (pypi-uri "gdrivefs" version))
15332 "0v9sp2cfg4ki3wagkwf3rnfpjhvgf845anz3757il9z95yvvcvb7"))))
15333 (build-system python-build-system)
15335 `(#:python ,python-2
15337 (modify-phases %standard-phases
15338 (add-before 'build 'patch-setup-py
15340 ;; Update requirements from dependency==version
15341 ;; to dependency>=version
15342 (substitute* "gdrivefs/resources/requirements.txt"
15346 `(("python2-gipc" ,python2-gipc)
15347 ("python2-gevent" ,python2-gevent)
15348 ("python2-greenlet" ,python2-greenlet)
15349 ("python2-httplib2" ,python2-httplib2)
15350 ("python2-uritemplate" ,python2-uritemplate)
15351 ("python2-oauth2client" ,python2-oauth2client)
15352 ("python2-six" ,python2-six)))
15354 `(("python2-dateutil" ,python2-dateutil)
15355 ("python2-fusepy" ,python2-fusepy)
15356 ("python2-google-api-client" ,python2-google-api-client)))
15357 (home-page "https://github.com/dsoprea/GDriveFS")
15358 (synopsis "Mount Google Drive as a local file system")
15359 (description "@code{gdrivefs} provides a FUSE wrapper for Google Drive
15360 under Python 2.7.")
15361 (license license:gpl2)))
15363 (define-public pybind11
15369 (uri (git-reference
15370 (url "https://github.com/pybind/pybind11.git")
15371 (commit (string-append "v" version))))
15374 "11b6dniri8m05spfd2a19irz82shf4sdca73566bniggrf3zclnf"))
15375 (file-name (git-file-name name version))))
15376 (build-system cmake-build-system)
15378 `(("python" ,python)
15379 ("python-pytest" ,python-pytest)))
15381 `(#:test-target "check"))
15382 (home-page "https://github.com/pybind/pybind11/")
15383 (synopsis "Seamless operability between C++11 and Python")
15384 (description "pybind11 is a lightweight header-only library that exposes
15385 C++ types in Python and vice versa, mainly to create Python bindings of
15386 existing C++ code. Its goals and syntax are similar to the excellent
15387 Boost.Python library by David Abrahams: to minimize boilerplate code in
15388 traditional extension modules by inferring type information using compile-time
15390 (license license:expat)))
15392 (define-public python-fasteners
15394 (name "python-fasteners")
15399 (uri (pypi-uri "fasteners" version))
15402 "063y20kx01ihbz2mziapmjxi2cd0dq48jzg587xdsdp07xvpcz22"))))
15403 (build-system python-build-system)
15405 `(("python-monotonic" ,python-monotonic)
15406 ("python-six" ,python-six)
15407 ("python-testtools" ,python-testtools)))
15408 (home-page "https://github.com/harlowja/fasteners")
15409 (synopsis "Python package that provides useful locks")
15411 "This package provides a Python program that provides following locks:
15414 @item Locking decorator
15415 @item Reader-writer locks
15416 @item Inter-process locks
15417 @item Generic helpers
15419 (properties `((python2-variant . ,(delay python2-fasteners))))
15420 (license license:asl2.0)))
15422 (define-public python2-fasteners
15423 (let ((base (package-with-python2 (strip-python2-variant python-fasteners))))
15427 `(("python2-futures" ,python2-futures)
15428 ,@(package-propagated-inputs base))))))
15430 (define-public python-requests-file
15432 (name "python-requests-file")
15437 (uri (pypi-uri "requests-file" version))
15440 "1yp2jaxg3v86pia0q512dg3hz6s9y5vzdivsgrba1kds05ial14g"))))
15441 (build-system python-build-system)
15443 `(("python-requests" ,python-requests)
15444 ("python-six" ,python-six)))
15446 "https://github.com/dashea/requests-file")
15447 (synopsis "File transport adapter for Requests")
15449 "Requests-File is a transport adapter for use with the Requests Python
15450 library to allow local file system access via @code{file://} URLs.")
15451 (license license:asl2.0)))
15453 (define-public python2-requests-file
15454 (package-with-python2 python-requests-file))
15456 (define-public python-tldextract
15458 (name "python-tldextract")
15463 (uri (pypi-uri "tldextract" version))
15466 "1d5s8v6kpsgazyahflhji1cfdcf89rv7l7z55v774bhzvcjp2y99"))))
15467 (build-system python-build-system)
15469 `(("python-pytest" ,python-pytest)
15470 ("python-responses" ,python-responses)))
15472 `(("python-idna" ,python-idna)
15473 ("python-requests" ,python-requests)
15474 ("python-requests-file" ,python-requests-file)))
15476 "https://github.com/john-kurkowski/tldextract")
15478 "Separate the TLD from the registered domain and subdomains of a URL")
15480 "TLDExtract accurately separates the TLD from the registered domain and
15481 subdomains of a URL, using the Public Suffix List. By default, this includes
15482 the public ICANN TLDs and their exceptions. It can optionally support the
15483 Public Suffix List's private domains as well.")
15484 (license license:bsd-3)))
15486 (define-public python2-tldextract
15487 (package-with-python2 python-tldextract))
15489 (define-public python-pynamecheap
15491 (name "python-pynamecheap")
15496 (uri (pypi-uri "PyNamecheap" version))
15499 "0wkbwz208j8nfrsmzmclvxg22ymknn0mlz76wbdza9k2bx2zja6l"))))
15500 (build-system python-build-system)
15502 `(("python-requests" ,python-requests)))
15504 "https://github.com/Bemmu/PyNamecheap")
15506 "Namecheap API client in Python")
15508 "PyNamecheap is a Namecheap API client in Python.")
15509 (license license:expat)))
15511 (define-public python2-pynamecheap
15512 (package-with-python2 python-pynamecheap))
15514 (define-public python-dns-lexicon
15516 (name "python-dns-lexicon")
15521 (uri (pypi-uri "dns-lexicon" version))
15524 "0jdn3ns71bsybr7njgsqr9xlxsqh7zh6phn4ld0liazqdn2l5f6m"))))
15525 (build-system python-build-system)
15527 `(#:tests? #f)) ;requires internet access
15529 `(("python-future" ,python-future)
15530 ("python-pynamecheap" ,python-pynamecheap)
15531 ("python-requests" ,python-requests)
15532 ("python-tldextract" ,python-tldextract)
15533 ("python-urllib3" ,python-urllib3)))
15534 (home-page "https://github.com/AnalogJ/lexicon")
15536 "Manipulate DNS records on various DNS providers")
15538 "Lexicon provides a way to manipulate DNS records on multiple DNS
15539 providers in a standardized way. It has a CLI but it can also be used as a
15540 Python library. It was designed to be used in automation, specifically with
15542 (license license:expat)))
15544 (define-public python2-dns-lexicon
15545 (package-with-python2 python-dns-lexicon))
15547 (define-public python-commandlines
15549 (name "python-commandlines")
15554 (uri (pypi-uri "commandlines" version))
15557 "0r7xcr0knv02p4mswa2bng61nn8nbhhrs6kvdnb9bb3hhjvm1dl6"))))
15558 (build-system python-build-system)
15559 (home-page "https://github.com/chrissimpkins/commandlines")
15560 (synopsis "Command line argument to object parsing library")
15562 "@code{Commandlines} is a Python library for command line application
15563 development that supports command line argument parsing, command string
15564 validation testing and application logic.")
15565 (license license:expat)))
15567 ;; Make sure to upgrade python-llvmlite in (gnu packages llvm) together with
15568 ;; python-numba. They have a very unflexible relationship.
15569 (define-public python-numba
15571 (name "python-numba")
15576 (uri (pypi-uri "numba" version))
15579 "1vnfzcq6fcnkmdms6114d49awvvj5181fl7z1wlha27qc2paxjy2"))))
15580 (build-system python-build-system)
15582 `(#:modules ((guix build utils)
15583 (guix build python-build-system)
15588 (modify-phases %standard-phases
15589 (add-after 'unpack 'disable-proprietary-features
15591 (setenv "NUMBA_DISABLE_HSA" "1")
15592 (setenv "NUMBA_DISABLE_CUDA" "1")
15594 (add-after 'unpack 'remove-failing-tests
15596 ;; FIXME: These tests fail for unknown reasons:
15597 ;; test_non_writable_pycache, test_non_creatable_pycache, and
15598 ;; test_frozen (all in numba.tests.test_dispatcher.TestCache).
15599 (substitute* "numba/tests/test_dispatcher.py"
15600 (("def test(_non_writable_pycache)" _ m)
15601 (string-append "def guix_skip" m))
15602 (("def test(_non_creatable_pycache)" _ m)
15603 (string-append "def guix_skip" m))
15604 (("def test(_frozen)" _ m)
15605 (string-append "def guix_skip" m)))
15607 ;; These tests fail because we don't run the tests from the build
15608 ;; directory: test_setup_py_distutils, test_setup_py_setuptools
15609 ;; They are in numba.tests.test_pycc.TestDistutilsSupport.
15610 (substitute* "numba/tests/test_pycc.py"
15611 (("def test(_setup_py_distutils|_setup_py_setuptools)" _ m)
15612 (string-append "def guix_skip" m)))
15614 ;; These tests fail because our version of Python does not have
15615 ;; a recognizable front-end for the Numba distribution to use
15616 ;; to check against.
15617 (substitute* "numba/tests/test_entrypoints.py"
15618 (("def test(_init_entrypoint)" _ m)
15619 (string-append "def guix_skip" m)))
15620 (substitute* "numba/tests/test_jitclasses.py"
15621 (("def test(_jitclass_longlabel_not_truncated)" _ m)
15622 (string-append "def guix_skip" m)))
15626 (let ((cwd (getcwd)))
15627 (setenv "PYTHONPATH"
15628 (string-append cwd "/build/"
15629 (find (cut string-prefix? "lib" <>)
15630 (scandir (string-append cwd "/build")))
15632 (getenv "PYTHONPATH")))
15633 ;; Something is wrong with the PYTHONPATH when running the
15634 ;; tests from the build directory, as it complains about not being
15635 ;; able to import certain modules.
15636 (with-directory-excursion "/tmp"
15637 (invoke "python3" "-m" "numba.runtests" "-v" "-m")))
15640 `(("python-llvmlite" ,python-llvmlite)
15641 ("python-numpy" ,python-numpy)
15642 ("python-singledispatch" ,python-singledispatch)))
15643 ;; Needed for tests.
15645 `(("python-jinja2" ,python-jinja2)
15646 ("python-pygments" ,python-pygments)))
15647 (home-page "https://numba.pydata.org")
15648 (synopsis "Compile Python code using LLVM")
15649 (description "Numba gives you the power to speed up your applications with
15650 high performance functions written directly in Python. With a few
15651 annotations, array-oriented and math-heavy Python code can be just-in-time
15652 compiled to native machine instructions, similar in performance to C, C++ and
15653 Fortran, without having to switch languages or Python interpreters.
15655 Numba works by generating optimized machine code using the LLVM compiler
15656 infrastructure at import time, runtime, or statically (using the included pycc
15658 (license license:bsd-3)))
15660 (define-public python-anndata
15662 (name "python-anndata")
15667 (uri (pypi-uri "anndata" version))
15670 "03x83yjaccbqszj7x4fwwmpil0ai59yx64d1zmf2691za3j03w73"))))
15671 (build-system python-build-system)
15673 `(("python-h5py" ,python-h5py)
15674 ("python-natsort" ,python-natsort)
15675 ("python-pandas" ,python-pandas)
15676 ("python-scipy" ,python-scipy)))
15677 (home-page "https://github.com/theislab/anndata")
15678 (synopsis "Annotated data for data analysis pipelines")
15679 (description "Anndata is a package for simple (functional) high-level APIs
15680 for data analysis pipelines. In this context, it provides an efficient,
15681 scalable way of keeping track of data together with learned annotations and
15682 reduces the code overhead typically encountered when using a mostly
15683 object-oriented library such as @code{scikit-learn}.")
15684 (license license:bsd-3)))
15686 (define-public python-dill
15688 (name "python-dill")
15689 (version "0.3.1.1")
15693 (uri (pypi-uri "dill" version))
15695 (base32 "1704g8z70d210ksgbccs2v545v9w0wc6lx15m296alb7jf0yzn22"))))
15696 (build-system python-build-system)
15699 (modify-phases %standard-phases
15702 (with-directory-excursion "/tmp"
15703 (invoke "nosetests" "-v"))
15706 `(("python-nose" ,python-nose)))
15707 (home-page "https://pypi.org/project/dill/")
15708 (synopsis "Serialize all of Python")
15709 (description "Dill extends Python's @code{pickle} module for serializing
15710 and de-serializing Python objects to the majority of the built-in Python
15711 types. Dill provides the user the same interface as the @code{pickle} module,
15712 and also includes some additional features. In addition to pickling Python
15713 objects, @code{dill} provides the ability to save the state of an interpreter
15714 session in a single command. Hence, it would be feasible to save a
15715 interpreter session, close the interpreter, ship the pickled file to another
15716 computer, open a new interpreter, unpickle the session and thus continue from
15717 the saved state of the original interpreter session.")
15718 (license license:bsd-3)))
15720 (define-public python-multiprocess
15722 (name "python-multiprocess")
15727 (uri (pypi-uri "multiprocess" version))
15730 "1r882nvd44xqwbrclwqx5rhs80l6809rcvpc7pkpgnij06cvvmcz"))))
15731 (build-system python-build-system)
15734 (modify-phases %standard-phases
15735 (add-after 'unpack 'disable-broken-tests
15737 ;; This test is broken as there is no keyboard interrupt.
15738 (substitute* "py3.7/multiprocess/tests/__init__.py"
15739 (("^(.*)def test_wait_result"
15741 (string-append indent
15742 "@unittest.skip(\"Disabled by Guix\")\n"
15745 ;; Tests must be run after installation.
15747 (add-after 'install 'check
15748 (lambda* (#:key inputs outputs #:allow-other-keys)
15749 (add-installed-pythonpath inputs outputs)
15750 (invoke "python" "-m" "multiprocess.tests")
15753 `(("python-dill" ,python-dill)))
15754 (home-page "https://pypi.org/project/multiprocess/")
15755 (synopsis "Multiprocessing and multithreading in Python")
15757 "This package is a fork of the multiprocessing Python package, a package
15758 which supports the spawning of processes using the API of the standard
15759 library's @code{threading} module.")
15760 (license license:bsd-3)))
15762 (define-public python-toolz
15764 (name "python-toolz")
15769 (uri (pypi-uri "toolz" version))
15772 "1j9i7fdjnx9dz35fdj5gvgxx6585ja9sxgaiv65if77nlxz0m7wj"))))
15773 (build-system python-build-system)
15774 ;; FIXME: tests cannot be computed: "Can't perform this operation for
15775 ;; unregistered loader type"
15776 (arguments '(#:tests? #f))
15777 (home-page "https://github.com/pytoolz/toolz/")
15778 (synopsis "List processing tools and functional utilities")
15780 "This package provides a set of utility functions for iterators,
15781 functions, and dictionaries.")
15782 (license license:bsd-3)))
15784 (define-public python2-toolz
15785 (package-with-python2 python-toolz))
15787 (define-public python-cytoolz
15789 (name "python-cytoolz")
15790 (version "0.9.0.1")
15794 (uri (pypi-uri "cytoolz" version))
15797 "1r80p88hm3f3r4zpixzr047y5hw4bzy41m4xywnhycda83x0dk44"))))
15798 (build-system python-build-system)
15799 ;; FIXME: tests fail with "module 'cytoolz.curried' has no attribute
15801 (arguments '(#:tests? #f))
15803 `(("python-toolz" ,python-toolz)))
15805 `(("python-cython" ,python-cython)))
15806 (home-page "https://github.com/pytoolz/cytoolz")
15807 (synopsis "High performance functional utilities")
15809 "The cytoolz package implements the same API as provided by toolz. The
15810 main differences are that @code{cytoolz} is faster and cytoolz offers a C API
15811 that is accessible to other projects developed in Cython.")
15812 (license license:bsd-3)))
15814 (define-public python-sortedcontainers
15816 (name "python-sortedcontainers")
15821 (uri (pypi-uri "sortedcontainers" version))
15824 "0fm0w5id2yhqld95hg2m636vjgkz377rvgdfqaxc25vbylr9lklp"))))
15825 (build-system python-build-system)
15827 `(("python-tox" ,python-tox)))
15828 (home-page "http://www.grantjenks.com/docs/sortedcontainers/")
15829 (synopsis "Sorted List, Sorted Dict, Sorted Set")
15831 "This package provides a sorted collections library, written in
15833 (license license:asl2.0)))
15835 (define-public python-cloudpickle
15837 (name "python-cloudpickle")
15842 (uri (pypi-uri "cloudpickle" version))
15845 "1wdw89mlm7fqa3fm3ymskx05jrys66n8m1z1a8s0mss0799ahsgi"))))
15846 (build-system python-build-system)
15847 ;; FIXME: there are 5 errors in 122 tests:
15848 ;; ERROR: test_function_pickle_compat_0_4_0 (tests.cloudpickle_test.CloudPickleTest)
15849 ;; ERROR: test_function_pickle_compat_0_4_1 (tests.cloudpickle_test.CloudPickleTest)
15850 ;; ERROR: test_function_pickle_compat_0_4_0 (tests.cloudpickle_test.Protocol2CloudPickleTest)
15851 ;; ERROR: test_function_pickle_compat_0_4_1 (tests.cloudpickle_test.Protocol2CloudPickleTest)
15852 ;; ERROR: test_temp_file (tests.cloudpickle_file_test.CloudPickleFileTests)
15853 ;; TypeError: cannot serialize '_io.BufferedRandom' object
15854 (arguments '(#:tests? #f))
15856 `(("python-pytest" ,python-pytest)
15857 ("python-mock" ,python-mock)
15858 ("python-tornado" ,python-tornado)))
15859 (home-page "https://github.com/cloudpipe/cloudpickle")
15860 (synopsis "Extended pickling support for Python objects")
15862 "Cloudpickle makes it possible to serialize Python constructs not
15863 supported by the default pickle module from the Python standard library. It
15864 is especially useful for cluster computing where Python expressions are
15865 shipped over the network to execute on remote hosts, possibly close to the
15867 (license license:bsd-3)))
15869 (define-public python2-cloudpickle
15870 (package-with-python2 python-cloudpickle))
15872 (define-public python-locket
15874 (name "python-locket")
15879 (uri (pypi-uri "locket" version))
15882 "1d4z2zngrpqkrfhnd4yhysh66kjn4mblys2l06sh5dix2p0n7vhz"))))
15883 (build-system python-build-system)
15884 (home-page "https://github.com/mwilliamson/locket.py")
15885 (synopsis "File-based locks for Python")
15887 "Locket implements a lock that can be used by multiple processes provided
15888 they use the same path.")
15889 (license license:bsd-2)))
15891 (define-public python2-locket
15892 (package-with-python2 python-locket))
15894 (define-public python-blosc
15896 (name "python-blosc")
15901 (uri (pypi-uri "blosc" version))
15904 "1cm91c6r431yla2mbs4895bgiianjf30dfz14vvv99dslygd65jw"))))
15905 (build-system python-build-system)
15906 ;; FIXME: all tests pass, but then this error is printed:
15907 ;; TypeError: calling <function run at 0x7ffff2568d90> returned None, not a test
15908 (arguments '(#:tests? #f))
15910 `(("python-numpy" ,python-numpy)))
15911 (home-page "https://github.com/blosc/python-blosc")
15912 (synopsis "Python wrapper for the Blosc data compressor library")
15913 (description "Blosc is a high performance compressor optimized for binary
15914 data. It has been designed to transmit data to the processor cache faster
15915 than the traditional, non-compressed, direct memory fetch approach via a
15916 @code{memcpy()} system call.
15918 Blosc works well for compressing numerical arrays that contains data with
15919 relatively low entropy, like sparse data, time series, grids with
15920 regular-spaced values, etc.
15922 This Python package wraps the Blosc library.")
15923 (license license:bsd-3)))
15925 (define-public python2-blosc
15926 (package-with-python2 python-blosc))
15928 (define-public python-partd
15930 (name "python-partd")
15935 (uri (pypi-uri "partd" version))
15938 "0sz6rwlnl4fqq220pyz863cnv0gjdxl4m7lscl71ishl5z0xkmhz"))))
15939 (build-system python-build-system)
15941 `(("python-blosc" ,python-blosc)
15942 ("python-locket" ,python-locket)
15943 ("python-numpy" ,python-numpy)
15944 ("python-pandas" ,python-pandas)
15945 ("python-pyzmq" ,python-pyzmq)
15946 ("python-toolz" ,python-toolz)))
15947 (home-page "https://github.com/dask/partd/")
15948 (synopsis "Appendable key-value storage")
15949 (description "Partd stores key-value pairs. Values are raw bytes. We
15950 append on old values. Partd excels at shuffling operations.")
15951 (license license:bsd-3)))
15953 (define-public python2-partd
15954 (package-with-python2 python-partd))
15956 (define-public python-fsspec
15958 (name "python-fsspec")
15963 (uri (pypi-uri "fsspec" version))
15966 "1g9ba8v04s1nrh7pvzfm2md7ivl2mrz3hcq3y9d1a44gd62h17zj"))))
15967 (build-system python-build-system)
15968 (arguments '(#:tests? #f)) ; there are none
15969 (home-page "https://github.com/intake/filesystem_spec")
15970 (synopsis "File-system specification")
15971 (description "The purpose of this package is to produce a template or
15972 specification for a file-system interface, that specific implementations
15973 should follow, so that applications making use of them can rely on a common
15974 behavior and not have to worry about the specific internal implementation
15975 decisions with any given backend.")
15976 (license license:bsd-3)))
15978 (define-public python-dask
15980 (name "python-dask")
15985 (uri (pypi-uri "dask" version))
15987 (base32 "1w1hqr8vyx6ygwflj2737dcy0mmgvrc0s602gnny8pzlcbs9m76b"))))
15988 (build-system python-build-system)
15991 (modify-phases %standard-phases
15992 (add-after 'unpack 'disable-broken-tests
15994 ;; This test is marked as xfail when pytest-xdist is used.
15995 (substitute* "dask/tests/test_threaded.py"
15996 (("def test_interrupt\\(\\)" m)
15997 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
15999 ;; This one fails with a type error:
16000 ;; TypeError: Already tz-aware, use tz_convert to convert.
16001 (substitute* "dask/dataframe/tests/test_shuffle.py"
16002 (("def test_set_index_timestamp\\(\\)" m)
16003 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
16007 (lambda _ (invoke "pytest" "-vv"))))))
16009 `(("python-cloudpickle" ,python-cloudpickle)
16010 ("python-fsspec" ,python-fsspec)
16011 ("python-numpy" ,python-numpy)
16012 ("python-packaging" ,python-packaging)
16013 ("python-pandas" ,python-pandas)
16014 ("python-partd" ,python-partd)
16015 ("python-toolz" ,python-toolz)
16016 ("python-pyyaml" ,python-pyyaml)))
16018 `(("python-pytest" ,python-pytest)
16019 ("python-pytest-runner" ,python-pytest-runner)))
16020 (home-page "https://github.com/dask/dask/")
16021 (synopsis "Parallel computing with task scheduling")
16023 "Dask is a flexible parallel computing library for analytics. It
16024 consists of two components: dynamic task scheduling optimized for computation,
16025 and large data collections like parallel arrays, dataframes, and lists that
16026 extend common interfaces like NumPy, Pandas, or Python iterators to
16027 larger-than-memory or distributed environments. These parallel collections
16028 run on top of the dynamic task schedulers. ")
16029 (license license:bsd-3)))
16031 (define-public python-ilinkedlist
16033 (name "python-ilinkedlist")
16038 (uri (pypi-uri "ilinkedlist" version))
16041 "0nrw4sr3afldrp7073hvc0rgdz282s0l819jdmj1i6nn05v33h0l"))))
16042 (build-system python-build-system)
16043 (native-inputs `(("python-pytest" ,python-pytest)))
16044 (inputs `(("python" ,python)))
16045 (home-page "https://github.com/luther9/ilinkedlist-py")
16046 (synopsis "Immutable linked list library")
16048 "This is a implementation of immutable linked lists for Python. It
16049 contains @code{nil} (the empty linked list) and a @code{Pair} class for nodes.
16050 Since a linked list is treated as immutable, it is hashable, and its length
16051 can be retrieved in constant time. Some of the terminology is inspired by
16052 LISP. It is possible to create an improper list by creating a @code{Pair}
16053 with a non-list @code{cdr}.")
16054 (license license:gpl3+)))
16056 (define-public python-readlike
16058 (name "python-readlike")
16063 (uri (pypi-uri "readlike" version))
16065 (base32 "027w8fvi50ksl57q0a7kb5zvmq8jxaawnviib1jdqw0p3igvm1j4"))))
16066 (build-system python-build-system)
16067 (home-page "https://github.com/jangler/readlike")
16068 (synopsis "GNU Readline-like line editing module")
16070 "This Python module provides line editing functions similar to the default
16071 Emacs-style ones of GNU Readline. Unlike the Python standard library's
16072 @code{readline} package, this one allows access to those capabilties in settings
16073 outside of a standard command-line interface. It is especially well-suited to
16074 interfacing with Urwid, due to a shared syntax for describing key inputs.
16076 Currently, all stateless Readline commands are implemented. Yanking and history
16077 are not supported.")
16078 (license license:expat)))
16080 (define-public python2-readlike
16081 (package-with-python2 python-readlike))
16083 (define-public python-reparser
16085 (name "python-reparser")
16090 (uri (pypi-uri "ReParser" version))
16092 (base32 "0nniqb69xr0fv7ydlmrr877wyyjb61nlayka7xr08vlxl9caz776"))))
16093 (build-system python-build-system)
16094 (home-page "https://github.com/xmikos/reparser")
16095 (synopsis "Simple lexer/parser for inline markup based on regular expressions")
16097 "This Python library provides a simple lexer/parser for inline markup based
16098 on regular expressions.")
16099 (license license:expat)))
16101 (define-public python2-reparser
16102 (let ((reparser (package-with-python2
16103 (strip-python2-variant python-reparser))))
16104 (package (inherit reparser)
16106 `(("python2-enum34" ,python2-enum34)
16107 ,@(package-propagated-inputs reparser))))))
16109 (define-public python-precis-i18n
16111 (name "python-precis-i18n")
16116 (uri (pypi-uri "precis_i18n" version))
16119 "0gjhvwd8aifx94rl1ag08vlmndyx2q3fkyqb0c4i46x3p2bc2yi2"))))
16120 (build-system python-build-system)
16121 (home-page "https://github.com/byllyfish/precis_i18n")
16122 (synopsis "Implementation of the PRECIS framework")
16124 "This module implements the PRECIS Framework as described in RFC 8264,
16125 RFC 8265 and RFC 8266.")
16126 (license license:expat)))
16128 (define-public python-absl-py
16130 (name "python-absl-py")
16135 (uri (pypi-uri "absl-py" version))
16138 "1mp9lk0b2qa37b7y6ak4lvf6ifw2ylyy6bkf9ik77md3j4xrwlc7"))))
16139 (build-system python-build-system)
16141 `(("python-six" ,python-six)))
16142 (home-page "https://github.com/abseil/abseil-py")
16143 (synopsis "Abseil Python common libraries")
16145 "This package provides the Abseil Python Common Libraries, a collection
16146 of Python libraries for building Python applications.")
16147 (license license:asl2.0)))
16149 (define-public python-astor
16151 (name "python-astor")
16156 (uri (pypi-uri "astor" version))
16159 "13gv6f2xz9i564byp21gcpc0l3w4cs23k1wbcam8kky2ls3hvhwm"))))
16160 (build-system python-build-system)
16161 ;; FIXME: There are two errors and two test failures.
16162 (arguments `(#:tests? #f))
16163 (home-page "https://github.com/berkerpeksag/astor")
16164 (synopsis "Read and write Python ASTs")
16165 (description "Astor is designed to allow easy manipulation of Python
16166 source via the Abstract Syntax Tree.")
16167 (license license:bsd-3)))
16169 (define-public python2-astor
16170 (package-with-python2 python-astor))
16172 (define-public python-grpcio
16174 (name "python-grpcio")
16179 (uri (pypi-uri "grpcio" version))
16182 "0qb9y6j83nxa6d4kc60i8yfgdm7a8ms7b54kncjzf5y7nsxp8rzx"))))
16183 (build-system python-build-system)
16185 `(("python-six" ,python-six)))
16186 (home-page "https://grpc.io")
16187 (synopsis "HTTP/2-based RPC framework")
16188 (description "This package provides a Python library for communicating
16189 with the HTTP/2-based RPC framework gRPC.")
16190 (license license:asl2.0)))
16192 (define-public python-astunparse
16194 (name "python-astunparse")
16199 (uri (pypi-uri "astunparse" version))
16201 (base32 "0rzbc44xcvzjhhiy7wac96mgal5mcjz1mfq8rmvgswskf4kf9cys"))))
16202 (build-system python-build-system)
16203 (arguments '(#:tests? #f)) ; there are none
16205 `(("python-six" ,python-six)
16206 ("python-wheel" ,python-wheel)))
16207 (home-page "https://github.com/simonpercivall/astunparse")
16208 (synopsis "AST unparser for Python")
16209 (description "This package provides an AST unparser for Python. It is a
16210 factored out version of @code{unparse} found in the Python source
16212 (license license:bsd-3)))
16214 (define-public python-gast
16216 (name "python-gast")
16221 (uri (pypi-uri "gast" version))
16223 (base32 "1w5dzdb3gpcfmd2s0b93d8gff40a1s41rv31458z14inb3s9v4zy"))))
16224 (build-system python-build-system)
16226 `(("python-astunparse" ,python-astunparse)))
16227 (home-page "https://pypi.org/project/gast/")
16228 (synopsis "Generic Python AST that abstracts the underlying Python version")
16230 "GAST provides a compatibility layer between the AST of various Python
16231 versions, as produced by @code{ast.parse} from the standard @code{ast}
16233 (license license:bsd-3)))
16235 (define-public python-wikidata
16237 (name "python-wikidata")
16242 (uri (pypi-uri "Wikidata" version))
16245 "08nlnydddfp1jj0cdmshvld1irzngbp3dij928wqsg9ziklm6mw9"))))
16246 (build-system python-build-system)
16248 `(("python-babel" ,python-babel)))
16249 (home-page "https://github.com/dahlia/wikidata")
16250 (synopsis "Wikidata client library")
16252 "This package provides a Python interface to
16253 @url{https://www.wikidata.org/, Wikidata}.")
16254 (properties '((upstream-name . "Wikidata")))
16255 (license license:gpl3+)))
16257 (define-public python-doctest-ignore-unicode
16259 (name "python-doctest-ignore-unicode")
16264 (uri (pypi-uri "doctest-ignore-unicode" version))
16267 "1m9aa4qnyj21lbq4sbvmv1vcz7zksss4rz37ddf2hxv4hk8b547w"))))
16268 (build-system python-build-system)
16270 `(("python-nose" ,python-nose)))
16271 (home-page "https://github.com/gnublade/doctest-ignore-unicode")
16272 (synopsis "Ignore Unicode literal prefixes in doctests")
16274 "This package adds support for a flag to ignore Unicode literal prefixes
16276 (license license:asl2.0)))
16278 (define-public python-attr
16280 (name "python-attr")
16285 (uri (pypi-uri "attr" version))
16288 "0pbpskvxp5hzdvcaf766ljwpckshir8sf7z6jqji6zyib20594ch"))))
16289 (build-system python-build-system)
16290 (home-page "https://github.com/denis-ryzhkov/attr")
16291 (synopsis "Decorator for attributes of target function or class")
16292 (description "Simple decorator to set attributes of target function or
16293 class in a @acronym{DRY, Don't Repeat Yourself} way.")
16294 (license license:expat)))
16296 (define-public python-construct
16298 (name "python-construct")
16303 (uri (pypi-uri "construct" version))
16306 "130iy05awzigm2xah2yvlmb08mac5bi4gzr5m3g7k1krs3ps0w92"))))
16307 (build-system python-build-system)
16309 `(#:tests? #f)) ; No tests exist.
16311 `(("python-extras" ,python-extras)
16312 ("python-arrow" ,python-arrow)
16313 ("python-numpy" ,python-numpy)
16314 ("python-ruamel.yaml" ,python-ruamel.yaml)))
16315 (home-page "http://construct.readthedocs.io")
16316 (synopsis "Declarative and symmetrical parser and builder for binary data")
16318 "This package provides both simple, atomic constructs (such as
16319 integers of various sizes), as well as composite ones which allow you
16320 form hierarchical and sequential structures of increasing complexity.
16321 It features bit and byte granularity, easy debugging and testing, an
16322 easy-to-extend subclass system, and lots of primitive constructs to
16323 make your work easier.")
16324 (license license:expat)))
16326 (define-public python-humanize
16328 (name "python-humanize")
16333 (uri (pypi-uri "humanize" version))
16336 "06dvhm3k8lf2rayn1gxbd46y0fy1db26m3h9vrq7rb1ib08mfgx4"))))
16338 '(#:tests? #f)) ; tests not in pypi archive
16339 (build-system python-build-system)
16340 (home-page "https://github.com/jmoiron/humanize")
16341 (synopsis "Print numerical information in a human-readable form")
16342 (description "This package provides a Python module that displays numbers
16343 and dates in \"human readable\" forms. For example, it would display
16344 \"12345591313\" as \"12.3 billion\".")
16345 (license license:expat)))
16347 (define-public python-txaio
16349 (name "python-txaio")
16354 (uri (pypi-uri "txaio" version))
16357 "1zmpdph6zddgrnkkcykh6qk5s46l7s5mzfqrh82m4b5iffn61qv7"))))
16358 (build-system python-build-system)
16360 `(("python-twisted" ,python-twisted)
16361 ("python-six" ,python-six)))
16362 (home-page "https://github.com/crossbario/txaio")
16363 (synopsis "Compatibility layer between Python asyncio and Twisted")
16364 (description "Txaio provides a compatibility layer between the Python
16365 @code{asyncio} module and @code{Twisted}.")
16366 (license license:expat)))
16368 (define-public python-toolshed
16370 (name "python-toolshed")
16375 (uri (pypi-uri "toolshed" version))
16378 "14zvz51gzf9i1i3d1sj363ba4rksl6lcf4lz1arl8hpqgcbir8r3"))))
16379 (build-system python-build-system)
16381 `(("python-nose" ,python-nose)))
16382 (home-page "https://github.com/brentp/toolshed/")
16383 (synopsis "Collection of modules and functions for working with data")
16384 (description "This is a collection of well-tested, simple modules and
16385 functions that aim to reduce boilerplate when working with data.")
16386 (license license:bsd-2)))
16388 (define-public python-annoy
16390 (name "python-annoy")
16395 (uri (pypi-uri "annoy" version))
16398 "1rxn6snn0r32r07g45hdjhh8aa1xzx6fjrm8g62d8vzp46z7rzrp"))))
16399 (build-system python-build-system)
16401 `(("python-nose" ,python-nose)))
16402 (home-page "https://github.com/spotify/annoy/")
16403 (synopsis "Approximate nearest neighbors library")
16405 "Annoy is a C++ library with Python bindings to search for points in
16406 space that are close to a given query point. It also creates large read-only
16407 file-based data structures that are @code{mmap}ped into memory so that many
16408 processes may share the same data.")
16409 (license license:asl2.0)))
16411 (define-public python-pylzma
16413 (name "python-pylzma")
16418 (uri (pypi-uri "pylzma" version))
16421 "074anvhyjgsv2iby2ql1ixfvjgmhnvcwjbdz8gk70xzkzcm1fx5q"))))
16422 (build-system python-build-system)
16423 (home-page "http://www.joachim-bauch.de/projects/pylzma/")
16424 (synopsis "Python bindings for the LZMA library by Igor Pavlov.")
16425 (description "This package provides Python bindings for the LZMA library
16427 (license license:lgpl2.1+)))
16429 (define-public python2-pylzma
16430 (package-with-python2 python-pylzma))
16432 (define-public python2-zeroconf
16434 (name "python2-zeroconf")
16436 ;; This is the last version that supports Python 2.x.
16441 (uri (pypi-uri "zeroconf" version))
16444 "0ykzg730n915qbrq9bn5pn06bv6rb5zawal4sqjyfnjjm66snkj3"))))
16445 (build-system python-build-system)
16447 `(#:python ,python-2
16449 (modify-phases %standard-phases
16450 (add-after 'unpack 'patch-requires
16451 (lambda* (#:key inputs #:allow-other-keys)
16452 (substitute* "setup.py"
16457 `(("python2-six" ,python2-six)
16458 ("python2-enum32" ,python2-enum34)
16459 ("python2-netifaces" ,python2-netifaces)
16460 ("python2-typing" ,python2-typing)))
16461 (home-page "https://github.com/jstasiak/python-zeroconf")
16462 (synopsis "Pure Python mDNS service discovery")
16464 "Pure Python multicast DNS (mDNS) service discovery library (Bonjour/Avahi
16466 (license license:lgpl2.1+)))
16468 (define-public python-bsddb3
16470 (name "python-bsddb3")
16475 (uri (pypi-uri "bsddb3" version))
16478 "019db2y6bfmiqbrgg9x9f6h72qjmqh05czdn2v5sy9bl0gs23mj2"))))
16479 (build-system python-build-system)
16484 (modify-phases %standard-phases
16485 (add-after 'unpack 'configure-locations
16486 (lambda* (#:key inputs #:allow-other-keys)
16487 (setenv "BERKELEYDB_DIR" (assoc-ref inputs "bdb"))
16488 (setenv "YES_I_HAVE_THE_RIGHT_TO_USE_THIS_BERKELEY_DB_VERSION" "1")
16492 (invoke "python3" "test3.py" "-v"))))))
16493 (home-page "https://www.jcea.es/programacion/pybsddb.htm")
16494 (synopsis "Python bindings for Oracle Berkeley DB")
16496 "This module provides a nearly complete wrapping of the Oracle/Sleepycat
16497 C API for the Database Environment, Database, Cursor, Log Cursor, Sequence and
16498 Transaction objects, and each of these is exposed as a Python type in the
16499 bsddb3.db module. The database objects can use various access methods: btree,
16500 hash, recno, and queue. Complete support of Berkeley DB distributed
16501 transactions. Complete support for Berkeley DB Replication Manager.
16502 Complete support for Berkeley DB Base Replication. Support for RPC.")
16503 (license license:bsd-3)))
16505 (define-public python-dbfread
16507 (name "python-dbfread")
16511 (uri (pypi-uri "dbfread" version))
16514 "0gdpwdzf1fngsi6jrdyj4qdf6cr7gnnr3zp80dpkzbgz0spskj07"))))
16515 (build-system python-build-system)
16517 `(("python-pytest" ,python-pytest)))
16518 (home-page "https://dbfread.readthedocs.io")
16519 (synopsis "Read DBF Files with Python")
16521 "This library reads DBF files and returns the data as native Python data
16522 types for further processing. It is primarily intended for batch jobs and
16524 (license license:expat)))
16526 (define-public python-cached-property
16528 (name "python-cached-property")
16533 (uri (pypi-uri "cached-property" version))
16536 "010m1bl380l2r3vwq24r5v14l6gwvgm9v0mqqjkjss552jgsa5wj"))))
16537 (build-system python-build-system)
16540 (modify-phases %standard-phases
16541 ;; https://github.com/pydanny/cached-property/issues/131
16542 ;; recent versions of freezegun break one test
16543 (add-after 'unpack 'disable-broken-test
16545 (substitute* "tests/test_cached_property.py"
16546 (("def test_threads_ttl_expiry\\(self\\)" m)
16547 (string-append "@unittest.skip(\"Disabled by Guix\")\n"
16551 `(("python-freezegun" ,python-freezegun)))
16553 "https://github.com/pydanny/cached-property")
16555 "Decorator for caching properties in classes")
16557 "This package provides a decorator which makes caching
16558 time-or-computationally-expensive properties quick and easy and works in Python
16560 (license license:bsd-3)))
16562 (define-public python-folium
16564 (name "python-folium")
16569 (uri (pypi-uri "folium" version))
16572 "0gcc267wxwxr57ry86pqpbiyfvl0g48hfvgy0f2mz9s58g87kgzd"))))
16573 (build-system python-build-system)
16575 `(("python-branca" ,python-branca)
16576 ("python-jinja2" ,python-jinja2)
16577 ("python-numpy" ,python-numpy)
16578 ("python-requests" ,python-requests)))
16580 `(("python-pytest" ,python-pytest)))
16581 (home-page "https://github.com/python-visualization/folium")
16582 (synopsis "Make beautiful maps with Leaflet.js & Python")
16583 (description "@code{folium} makes it easy to visualize data that’s been
16584 manipulated in Python on an interactive leaflet map. It enables both the
16585 binding of data to a map for @code{choropleth} visualizations as well as
16586 passing rich vector/raster/HTML visualizations as markers on the map.
16588 The library has a number of built-in tilesets from OpenStreetMap, Mapbox, and
16589 Stamen, and supports custom tilesets with Mapbox or Cloudmade API keys. It
16590 supports Image, Video, GeoJSON and TopoJSON overlays.")
16591 (license license:expat)))
16593 (define-public jube
16595 ;; This is a command-line tool, so no "python-" prefix.
16600 (uri (string-append
16601 "http://apps.fz-juelich.de/jsc/jube/jube2/download.php?version="
16605 "0xq4k1q63s1p6swgyp61vahlrd1fqmgbm0gm5kpj8ikwy0yc0nqk"))
16606 (file-name (string-append "jube-" version ".tar.gz"))))
16607 (build-system python-build-system)
16608 (home-page "https://apps.fz-juelich.de/jsc/jube/jube2/docu/index.html")
16609 (synopsis "Benchmarking environment")
16611 "JUBE helps perform and analyze benchmarks in a systematic way. For each
16612 benchmarked application, benchmark data is stored in a format that allows JUBE
16613 to deduct the desired information. This data can be parsed by automatic pre-
16614 and post-processing scripts that draw information and store it more densely
16615 for manual interpretation.")
16616 (license license:gpl3+)))
16618 (define-public python-pyroutelib3
16620 (name "python-pyroutelib3")
16621 (version "1.3.post1")
16625 (uri (pypi-uri "pyroutelib3" version))
16628 "1hpbydpn2alyswiajfbvhzq4c7f36vdmvxy91hgv8l1lb2g2vfrj"))))
16629 (build-system python-build-system)
16631 `(("python-dateutil" ,python-dateutil)))
16632 (home-page "https://github.com/MKuranowski/pyroutelib3")
16633 (synopsis "Library for simple routing on OSM data")
16634 (description "Library for simple routing on OSM data")
16635 (license license:gpl3+)))
16637 (define-public python-bibtexparser
16639 (name "python-bibtexparser")
16644 (uri (pypi-uri "bibtexparser" version))
16647 "0zwhfkrzf3n5847dbnfng92k7ak199l9v6x6ax3dgdidfpm6d2fz"))))
16648 (build-system python-build-system)
16650 `(("python-pyparsing" ,python-pyparsing)))
16652 `(("python-future" ,python-future)))
16653 (home-page "https://github.com/sciunto-org/python-bibtexparser")
16654 (synopsis "Python library to parse BibTeX files")
16655 (description "BibtexParser is a Python library to parse BibTeX files.")
16656 (license (list license:bsd-3 license:lgpl3))))
16658 (define-public python-distro
16660 (name "python-distro")
16665 (uri (pypi-uri "distro" version))
16668 "0mrg75w4ap7mdzyga75yaid9n8bgb345ih5mwjp3plj6v1jxwb9n"))))
16669 (build-system python-build-system)
16671 `(("python-pytest" ,python-pytest)))
16672 (home-page "https://github.com/nir0s/distro")
16674 "OS platform information API")
16676 "@code{distro} provides information about the OS distribution it runs on,
16677 such as a reliable machine-readable ID, or version information.
16679 It is the recommended replacement for Python's original
16680 `platform.linux_distribution` function (which will be removed in Python 3.8).
16681 @code{distro} also provides a command-line interface to output the platform
16682 information in various formats.")
16683 (license license:asl2.0)))
16685 (define-public python-cairosvg
16687 (name "python-cairosvg")
16692 (uri (pypi-uri "CairoSVG" version))
16694 (base32 "1bb7irxbaxxb9ahm3z5wsx1q96mm5gzskc7b6q07h9ikcnb8yrjf"))))
16695 (build-system python-build-system)
16698 (modify-phases %standard-phases
16700 (lambda _ (invoke "pytest"))))))
16702 `(("python-cairocffi" ,python-cairocffi)
16703 ("python-cssselect2" ,python-cssselect2)
16704 ("python-defusedxml" ,python-defusedxml)
16705 ("python-pillow" ,python-pillow)
16706 ("python-tinycss2" ,python-tinycss2)))
16708 `(("python-pytest-flake8" ,python-pytest-flake8)
16709 ("python-pytest-isort" ,python-pytest-isort)
16710 ("python-pytest-runner" ,python-pytest-runner)))
16711 (home-page "https://cairosvg.org/")
16712 (synopsis "SVG to PDF/PS/PNG converter based on Cairo")
16713 (description "CairoSVG is a SVG converter based on Cairo. It can export
16714 SVG files to PDF, PostScript and PNG files. The main part of CairoSVG is a
16715 SVG parser, trying to follow the SVG 1.1 recommendation from the W3C. Once
16716 parsed, the result is drawn to a Cairo surface that can be exported to
16717 qvarious formats: PDF, PostScript, PNG and even SVG.")
16718 (license license:lgpl3+)))
16720 (define-public python-pyphen
16722 (name "python-pyphen")
16727 (uri (pypi-uri "Pyphen" version))
16729 (base32 "08c9y69ry9d6m4zalhnalg86lsp9v2j5n1ziw5vxfmiihx83lqrv"))))
16730 (build-system python-build-system)
16731 ;; TODO: Use the Guix system hyphenation packages hyphen-* rather than the
16732 ;; embedded set provided by upstream - like Debian does.
16733 (home-page "https://github.com/Kozea/Pyphen")
16734 (synopsis "Pure Python module to hyphenate text")
16735 (description "Pyphen is a pure Python module to hyphenate text using
16736 existing Hunspell hyphenation dictionaries.")
16737 (license (list license:gpl2 license:lgpl2.1 license:mpl1.1))))
16739 (define-public python-intelhex
16741 (name "python-intelhex")
16746 (uri (pypi-uri "intelhex" version))
16749 "0ckqjbxd8gwcg98gfzpn4vq1qxzfvq3rdbrr1hikj1nmw08qb780"))))
16750 (build-system python-build-system)
16751 (arguments '(#:tests? #f)) ;issue with version
16752 (home-page "https://pypi.org/project/IntelHex/")
16753 (synopsis "Python library for Intel HEX files manipulations")
16754 (description "The Intel HEX file format is widely used in microprocessors
16755 and microcontrollers area (embedded systems etc.) as the de facto standard for
16756 representation of code to be programmed into microelectronic devices. This
16757 package provides an intelhex Python library to read, write, create from
16758 scratch and manipulate data from Intel HEX file format. It also includes
16759 several convenience Python scripts, including \"classic\" hex2bin and bin2hex
16760 converters and more, those based on the library itself.")
16761 (license license:bsd-3)))
16763 (define-public python-pykwalify
16765 (name "python-pykwalify")
16770 (uri (pypi-uri "pykwalify" version))
16773 "1cnfzkg1b01f825ikpw2fhjclf9c8akxjfrbd1vc22x1lg2kk2vy"))))
16774 (build-system python-build-system)
16775 (arguments '(#:tests? #f)) ;missing dependencies
16777 `(("python-dateutil" ,python-dateutil)
16778 ("python-docopt" ,python-docopt)
16779 ("python-pyyaml" ,python-pyyaml)))
16780 (home-page "https://github.com/grokzen/pykwalify")
16782 "Python lib/cli for JSON/YAML schema validation")
16784 "This package provides a parser, schema validator, and data binding tool
16785 for YAML and JSON.")
16786 (license license:expat)))
16788 (define-public python-dbusmock
16790 (name "python-dbusmock")
16795 (uri (pypi-uri "python-dbusmock" version))
16798 "0hp2kyac88nh9iv6l8hlmv7s1sa1s5f1a3wc2pmlmmxnd211fjlr"))))
16799 (build-system python-build-system)
16802 (modify-phases %standard-phases
16803 (add-after 'unpack 'patch-shell-path
16805 (substitute* "tests/test_code.py"
16806 (("/bin/bash") (which "bash")))
16810 ("dbus" ,dbus) ; for dbus-daemon
16811 ("python-nose" ,python-nose)
16814 `(("python-dbus" ,python-dbus)
16815 ("python-pygobject" ,python-pygobject)))
16816 (home-page "https://github.com/martinpitt/python-dbusmock")
16817 (synopsis "Python library for mock D-Bus objects")
16818 (description "python-dbusmock allows for the easy creation of mock objects on
16819 D-Bus. This is useful for writing tests for software which talks to D-Bus
16820 services such as upower, systemd, logind, gnome-session or others, and it is
16821 hard (or impossible without root privileges) to set the state of the real
16822 services to what you expect in your tests.")
16823 (license license:lgpl3+)))
16825 (define-public python-ujson
16827 (name "python-ujson")
16832 (uri (pypi-uri "ujson" version))
16835 "11jz5wi7mbgqcsz52iqhpyykiaasila4lq8cmc2d54bfa3jp6q7n"))))
16836 (build-system python-build-system)
16837 (home-page "http://www.esn.me")
16839 "Ultra fast JSON encoder and decoder for Python")
16841 "UltraJSON is an ultra fast JSON encoder and decoder written in pure C with
16842 bindings for Python 2.5+ and 3.")
16843 (license license:bsd-3)))
16845 (define-public python2-ujson
16846 (package-with-python2 python-ujson))
16848 (define-public python-iocapture
16849 ;; The latest release is more than a year older than this commit.
16850 (let ((commit "fdc021c431d0840303908dfc3ca8769db383595c")
16853 (name "python-iocapture")
16858 (uri (git-reference
16859 (url "https://github.com/oinume/iocapture.git")
16861 (file-name (git-file-name name version))
16864 "1mkbhqibxvgwg0p7slr8dfraa3g2s6bsayladhax2jccwj4kcndz"))))
16865 (build-system python-build-system)
16868 (modify-phases %standard-phases
16870 (add-after 'install 'check
16871 (lambda* (#:key inputs outputs #:allow-other-keys)
16872 (add-installed-pythonpath inputs outputs)
16873 (invoke "py.test" "-v" "tests")
16876 `(("python-flexmock" ,python-flexmock)
16877 ("python-pytest" ,python-pytest)
16878 ("python-pytest-cov" ,python-pytest-cov)
16879 ("python-six" ,python-six)))
16880 (home-page "https://github.com/oinume/iocapture")
16881 (synopsis "Python capturing tool for stdout and stderr")
16883 "This package helps you to capture the standard out (stdout) and the
16884 standard error channel (stderr) in your program.")
16885 (license license:expat))))
16887 (define-public python-argh
16888 ;; There are 21 commits since the latest release containing important
16890 (let ((commit "dcd3253f2994400a6a58a700c118c53765bc50a4")
16893 (name "python-argh")
16894 (version (git-version "0.26.2" revision commit))
16898 (uri (git-reference
16899 (url "https://github.com/neithere/argh.git")
16901 (file-name (git-file-name name version))
16904 "1p5h3dnpbsjmqrvil96s71asc6i3gpinmbrabqmwnrsxprz7r3ns"))))
16905 (build-system python-build-system)
16907 `(("python-iocapture" ,python-iocapture)
16908 ("python-mock" ,python-mock)
16909 ("python-pytest" ,python-pytest)
16910 ("python-pytest-cov" ,python-pytest-cov)
16911 ("python-pytest-xdist" ,python-pytest-xdist)
16912 ("python-tox" ,python-tox)))
16913 (home-page "https://github.com/neithere/argh/")
16914 (synopsis "Argparse wrapper with natural syntax")
16916 "python-argh is a small library that provides several layers of
16917 abstraction on top of @code{python-argparse}. The layers can be mixed. It is
16918 always possible to declare a command with the highest possible (and least
16919 flexible) layer and then tune the behaviour with any of the lower layers
16920 including the native API of @code{python-argparse}.")
16921 (license license:lgpl3+))))
16923 (define-public python-ppft
16925 (name "python-ppft")
16926 (version "1.6.6.1")
16930 (uri (pypi-uri "ppft" version))
16933 "1z1invkhszc5d2mvgr221v7cszzifcc77mz0pv3wjp6x5q2768cy"))))
16934 (build-system python-build-system)
16935 (arguments '(#:tests? #f)) ; there are none
16937 `(("python-six" ,python-six)))
16938 (home-page "https://pypi.org/project/ppft/")
16939 (synopsis "Fork of Parallel Python")
16941 "This package is a fork of Parallel Python. The Parallel Python
16942 module (@code{pp}) provides an easy and efficient way to create
16943 parallel-enabled applications for @dfn{symmetric multiprocessing} (SMP)
16944 computers and clusters. It features cross-platform portability and dynamic
16946 (license license:bsd-3)))
16948 (define-public python-pox
16950 (name "python-pox")
16955 (uri (pypi-uri "pox" version))
16958 "0y17ckc2p6i6709s279sjdj4q459mpcc38ymg9zv9y6vl6jf3bq6"))))
16959 (build-system python-build-system)
16962 (modify-phases %standard-phases
16965 (mkdir-p "/tmp/guix")
16966 (setenv "SHELL" "bash")
16967 (setenv "USERNAME" "guix")
16968 (setenv "HOME" "/tmp/guix") ; must end on USERNAME...
16969 (invoke "py.test" "-vv")
16972 `(("python-pytest" ,python-pytest)
16974 (home-page "https://pypi.org/project/pox/")
16975 (synopsis "Python utilities for filesystem exploration and automated builds")
16977 "Pox provides a collection of utilities for navigating and manipulating
16978 filesystems. This module is designed to facilitate some of the low level
16979 operating system interactions that are useful when exploring a filesystem on a
16980 remote host. Pox provides Python equivalents of several shell commands such
16981 as @command{which} and @command{find}. These commands allow automated
16982 discovery of what has been installed on an operating system, and where the
16983 essential tools are located.")
16984 (license license:bsd-3)))
16986 (define-public python-pathos
16988 (name "python-pathos")
16993 (uri (pypi-uri "pathos" version))
16996 "0in8hxdz7k081ijn6q94gr39ycy7363sx4zysmbwyvd7snqjrbi1"))))
16997 (build-system python-build-system)
17000 (modify-phases %standard-phases
17003 (setenv "PYTHONPATH"
17004 (string-append (getcwd) ":" (getenv "PYTHONPATH")))
17005 (invoke "python" "./tests/__main__.py"))))))
17007 `(("python-dill" ,python-dill)
17008 ("python-multiprocess" ,python-multiprocess)
17009 ("python-pox" ,python-pox)
17010 ("python-ppft" ,python-ppft)))
17012 `(("python-pytest" ,python-pytest)))
17013 (home-page "https://pypi.org/project/pathos/")
17015 "Parallel graph management and execution in heterogeneous computing")
17017 "Python-pathos is a framework for heterogenous computing. It provides a
17018 consistent high-level interface for configuring and launching parallel
17019 computations across heterogenous resources. Python-pathos provides configurable
17020 launchers for parallel and distributed computing, where each launcher contains
17021 the syntactic logic to configure and launch jobs in an execution environment.")
17022 (license license:bsd-3)))
17024 (define-public python-flit
17026 (name "python-flit")
17031 (uri (pypi-uri "flit" version))
17034 "0h5vvmqinqzn97mr3ix7zx53af9ad4fimjjwqpx88yp8qhz4r5bc"))))
17035 (build-system python-build-system)
17037 `(#:tests? #f)) ; XXX: Check requires network access.
17038 (home-page "https://flit.readthedocs.io/")
17040 "Simple packaging tool for simple packages")
17042 "Flit is a simple way to put Python packages and modules on PyPI. Flit
17043 packages a single importable module or package at a time, using the import
17044 name as the name on PyPI. All subpackages and data files within a package
17045 are included automatically.")
17046 (license license:bsd-3)))
17048 (define-public python-pathtools
17050 (name "python-pathtools")
17055 (uri (pypi-uri "pathtools" version))
17058 "1h7iam33vwxk8bvslfj4qlsdprdnwf8bvzhqh3jq5frr391cadbw"))))
17059 (build-system python-build-system)
17061 "https://github.com/gorakhargosh/pathtools")
17062 (synopsis "Path utilities for Python")
17063 (description "Pattern matching and various utilities for file systems
17065 (license license:expat)))
17067 (define-public python-fastentrypoints
17069 (name "python-fastentrypoints")
17074 (uri (pypi-uri "fastentrypoints" version))
17077 "02s1j8i2dzbpbwgq2a3fiqwm3cnmhii2qzc0k42l0rdxd4a4ya7z"))))
17078 (build-system python-build-system)
17080 "https://github.com/ninjaaron/fast-entry_points")
17082 "Makes entry_points specified in setup.py load more quickly")
17084 "Using entry_points in your setup.py makes scripts that start really
17085 slowly because it imports pkg_resources. This package allows such setup
17086 scripts to load entry points more quickly.")
17087 (license license:bsd-3)))
17089 (define-public python-funcparserlib
17091 (name "python-funcparserlib")
17096 (uri (pypi-uri "funcparserlib" version))
17099 "07f9cgjr3h4j2m67fhwapn8fja87vazl58zsj4yppf9y3an2x6dp"))))
17101 `(("python-tox" ,python-tox)))
17104 (modify-phases %standard-phases
17107 (invoke "tox"))))))
17108 (build-system python-build-system)
17110 "https://github.com/vlasovskikh/funcparserlib")
17112 "Recursive descent parsing library based on functional combinators")
17114 "This package is a recursive descent parsing library for Python based on
17115 functional combinators. Parser combinators are just higher-order functions
17116 that take parsers as their arguments and return them as result values.")
17117 (license license:expat)))
17119 (define-public python-speg
17121 (name "python-speg")
17126 (uri (pypi-uri "speg" version ".zip"))
17128 (base32 "0w9y4jf4787dzhy6rvhwi0mpl0r8qkqmqmyv2hpwdpv8w53yzjqh"))))
17130 `(#:tests? #f)) ;FIXME: tests fail, not sure why
17132 `(("unzip" ,unzip)))
17133 (build-system python-build-system)
17134 (home-page "https://github.com/avakar/speg")
17135 (synopsis "PEG-based parser interpreter with memoization")
17136 (description "This package is a PEG-based parser and interpreter with
17138 (license license:expat)))
17140 (define-public python-cson
17142 (name "python-cson")
17147 (uri (pypi-uri "cson" version))
17149 (base32 "00cyvigg4npbph39ghkg77xbxisa6plf75vii24igxfizik0337f"))))
17150 (build-system python-build-system)
17152 `(("python-speg" ,python-speg)))
17153 (home-page "https://github.com/avakar/pycson")
17154 (synopsis "Parser for Coffeescript Object Notation (CSON)")
17155 (description "This package is a parser for Coffeescript Object
17157 (license license:expat)))
17159 (define-public python-asynctest
17161 (name "python-asynctest")
17166 (uri (pypi-uri "asynctest" version))
17169 "1b3zsy7p84gag6q8ai2ylyrhx213qdk2h2zb6im3xn0m5n264y62"))))
17170 (build-system python-build-system)
17173 (modify-phases %standard-phases
17176 (invoke "python" "-X" "dev" "-m" "unittest" "-v" "test")))
17177 (add-after 'unpack 'disable-tests
17179 (substitute* "test/test_selector.py"
17180 ;; XXX: This test fails for unknown reason inside the build
17182 (("def test_events_watched_outside_test_are_ignored")
17183 "@unittest.skip('disabled by guix')
17184 def test_events_watched_outside_test_are_ignored")))))))
17185 (home-page "https://github.com/Martiusweb/asynctest")
17186 (synopsis "Extension of unittest for testing asyncio libraries")
17188 "The package asynctest is built on top of the standard unittest module
17189 and cuts down boilerplate code when testing libraries for asyncio.")
17190 (license license:asl2.0)))
17192 (define-public python-aionotify
17194 (name "python-aionotify")
17198 ;; Source tarball on PyPi lacks tests
17200 (uri (git-reference
17201 (url "https://github.com/rbarrois/aionotify")
17202 (commit (string-append "v" version))))
17203 (file-name (git-file-name name version))
17205 (base32 "1sk9i8czxgsbrswsf1nlb4c82vgnlzi8zrvrxdip92w2z8hqh43y"))))
17206 (build-system python-build-system)
17207 (native-inputs `(("python-asynctest" ,python-asynctest)))
17208 (home-page "https://github.com/rbarrois/aionotify")
17209 (synopsis "Asyncio-powered inotify library")
17211 "@code{aionotify} is a simple, asyncio-based inotify library.")
17212 (license license:bsd-3)))
17214 (define-public python-forbiddenfruit
17216 (name "python-forbiddenfruit")
17220 ;; Source tarball on PyPi lacks Makefile that builds and runs tests
17222 (uri (git-reference
17223 (url "https://github.com/clarete/forbiddenfruit")
17225 (file-name (git-file-name name version))
17227 (base32 "1fp2xvdqpi910j9r3q68x38phpxbm700gjdi2m2j5gs91xdnyyh2"))))
17228 (build-system python-build-system)
17231 (modify-phases %standard-phases
17234 (invoke "make" "SKIP_DEPS=1"))))))
17236 `(("python-nose" ,python-nose)
17237 ("python-coverage" ,python-coverage)))
17238 (home-page "https://github.com/clarete/forbiddenfruit")
17239 (synopsis "Patch python built-in objects")
17240 (description "This project allows Python code to extend built-in types.")
17241 (license (list license:gpl3+ license:expat))))
17243 (define-public python-shouldbe
17245 (name "python-shouldbe")
17250 (uri (pypi-uri "shouldbe" version))
17253 "16zbvjxf71dl4yfbgcr6idyim3mdrfvix1dv8b95p0s9z07372pj"))))
17254 (build-system python-build-system)
17256 `(("python-forbiddenfruit" ,python-forbiddenfruit)))
17258 `(("python-nose" ,python-nose)))
17259 (home-page "https://github.com/directxman12/should_be")
17260 (synopsis "Python Assertion Helpers inspired by Shouldly")
17262 "Python Assertion Helpers inspired by Shouldly.")
17263 (license license:isc)))
17265 (define-public python-k5test
17267 (name "python-k5test")
17272 (uri (pypi-uri "k5test" version))
17275 "1lqp3jgfngyhaxjgj3n230hn90wsylwilh120yjf62h7b1s02mh8"))))
17276 (build-system python-build-system)
17278 `(("python-six" ,python-six)
17279 ;; `which`, `kadmin.local` binaries called inside library
17281 ("mit-krb5" ,mit-krb5)))
17282 (native-inputs `(("mit-krb5" ,mit-krb5)))
17285 (modify-phases %standard-phases
17286 (add-after 'unpack 'patch-paths
17288 (substitute* "k5test/realm.py"
17289 (("'kadmin_local'") "'kadmin.local'")))))))
17290 (home-page "https://github.com/pythongssapi/k5test")
17291 (synopsis "Library for setting up self-contained Kerberos 5 environments")
17293 "@code{k5test} is a library for setting up self-contained Kerberos 5
17294 environments, and running Python unit tests inside those environments. It is
17295 based on the file of the same name found alongside the MIT Kerberos 5 unit
17297 (license license:isc)))
17299 (define-public python-gssapi
17301 (name "python-gssapi")
17306 (uri (pypi-uri "gssapi" version))
17309 "1gymg4asvwrz7y13qpwp2s5g8qwq179d72gkj09q6bfcgs82l5wr"))))
17310 (build-system python-build-system)
17312 `(("python-decorator" ,python-decorator)
17313 ("python-six" ,python-six)))
17315 `(("mit-krb5" ,mit-krb5)))
17318 `(("python-shouldbe" ,python-shouldbe)
17319 ("python-parameterized" ,python-parameterized)
17320 ("python-k5test" ,python-k5test)
17321 ("python-nose" ,python-nose)))
17322 (home-page "https://github.com/pythongssapi/python-gssapi")
17323 (synopsis "Python GSSAPI Wrapper")
17325 "Python-GSSAPI provides both low-level and high level wrappers around the
17326 GSSAPI C libraries. While it focuses on the Kerberos mechanism, it should
17327 also be useable with other GSSAPI mechanisms.")
17328 (license license:isc)))