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>
72 ;;; This file is part of GNU Guix.
74 ;;; GNU Guix is free software; you can redistribute it and/or modify it
75 ;;; under the terms of the GNU General Public License as published by
76 ;;; the Free Software Foundation; either version 3 of the License, or (at
77 ;;; your option) any later version.
79 ;;; GNU Guix is distributed in the hope that it will be useful, but
80 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
81 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
82 ;;; GNU General Public License for more details.
84 ;;; You should have received a copy of the GNU General Public License
85 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
87 (define-module (gnu packages python-xyz)
88 #:use-module ((guix licenses) #:prefix license:)
89 #:use-module (gnu packages)
90 #:use-module (gnu packages algebra)
91 #:use-module (gnu packages adns)
92 #:use-module (gnu packages attr)
93 #:use-module (gnu packages backup)
94 #:use-module (gnu packages bash)
95 #:use-module (gnu packages check)
96 #:use-module (gnu packages compression)
97 #:use-module (gnu packages crypto)
98 #:use-module (gnu packages databases)
99 #:use-module (gnu packages dbm)
100 #:use-module (gnu packages file)
101 #:use-module (gnu packages fontutils)
102 #:use-module (gnu packages gcc)
103 #:use-module (gnu packages geo)
104 #:use-module (gnu packages ghostscript)
105 #:use-module (gnu packages gl)
106 #:use-module (gnu packages glib)
107 #:use-module (gnu packages gnome)
108 #:use-module (gnu packages graphviz)
109 #:use-module (gnu packages graphics)
110 #:use-module (gnu packages gstreamer)
111 #:use-module (gnu packages gtk)
112 #:use-module (gnu packages icu4c)
113 #:use-module (gnu packages image)
114 #:use-module (gnu packages imagemagick)
115 #:use-module (gnu packages libevent)
116 #:use-module (gnu packages libffi)
117 #:use-module (gnu packages linux)
118 #:use-module (gnu packages llvm)
119 #:use-module (gnu packages man)
120 #:use-module (gnu packages maths)
121 #:use-module (gnu packages monitoring)
122 #:use-module (gnu packages multiprecision)
123 #:use-module (gnu packages networking)
124 #:use-module (gnu packages ncurses)
125 #:use-module (gnu packages openstack)
126 #:use-module (gnu packages pcre)
127 #:use-module (gnu packages perl)
128 #:use-module (gnu packages pkg-config)
129 #:use-module (gnu packages python)
130 #:use-module (gnu packages python-check)
131 #:use-module (gnu packages python-compression)
132 #:use-module (gnu packages python-crypto)
133 #:use-module (gnu packages python-science)
134 #:use-module (gnu packages python-web)
135 #:use-module (gnu packages qt)
136 #:use-module (gnu packages readline)
137 #:use-module (gnu packages sdl)
138 #:use-module (gnu packages search)
139 #:use-module (gnu packages shells)
140 #:use-module (gnu packages sphinx)
141 #:use-module (gnu packages ssh)
142 #:use-module (gnu packages terminals)
143 #:use-module (gnu packages tex)
144 #:use-module (gnu packages texinfo)
145 #:use-module (gnu packages time)
146 #:use-module (gnu packages tls)
147 #:use-module (gnu packages version-control)
148 #:use-module (gnu packages video)
149 #:use-module (gnu packages web)
150 #:use-module (gnu packages base)
151 #:use-module (gnu packages xml)
152 #:use-module (gnu packages xorg)
153 #:use-module (gnu packages xdisorg)
154 #:use-module (gnu packages tcl)
155 #:use-module (gnu packages bdw-gc)
156 #:use-module (gnu packages serialization)
157 #:use-module (guix packages)
158 #:use-module (guix download)
159 #:use-module (guix git-download)
160 #:use-module (guix hg-download)
161 #:use-module (guix utils)
162 #:use-module (guix build-system gnu)
163 #:use-module (guix build-system cmake)
164 #:use-module (guix build-system python)
165 #:use-module (guix build-system trivial)
166 #:use-module (srfi srfi-1)
167 #:use-module (srfi srfi-26))
169 (define-public python-psutil
171 (name "python-psutil")
176 (uri (pypi-uri "psutil" version))
178 (base32 "0isil5jxwwd8awz54qk28rpgjg43i5l6yl70g40vxwa4r4m56lfh"))))
179 (build-system python-build-system)
181 ;; FIXME: some tests does not return and times out.
183 (home-page "https://www.github.com/giampaolo/psutil")
184 (synopsis "Library for retrieving information on running processes")
186 "psutil (Python system and process utilities) is a library for retrieving
187 information on running processes and system utilization (CPU, memory, disks,
188 network) in Python. It is useful mainly for system monitoring, profiling and
189 limiting process resources and management of running processes. It implements
190 many functionalities offered by command line tools such as: ps, top, lsof,
191 netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
192 pidof, tty, taskset, pmap.")
193 (properties `((python2-variant . ,(delay python2-psutil))))
194 (license license:bsd-3)))
196 (define-public python2-psutil
197 (let ((base (package-with-python2 (strip-python2-variant python-psutil))))
201 `(("python2-enum34" ,python2-enum34) ;optional
202 ,@(package-propagated-inputs base))))))
204 (define-public python-shapely
206 (name "python-shapely")
207 (version "1.6.4.post2")
211 (uri (pypi-uri "Shapely" version))
214 "03r42fmd9alp6r3q95ad6rldq2f7n1wimrw53zy5kpn33yv7pf64"))))
215 (build-system python-build-system)
217 `(("python-cython" ,python-cython)
218 ("python-matplotlib" ,python-matplotlib)
219 ("python-pytest" ,python-pytest)
220 ("python-pytest-cov" ,python-pytest-cov)))
224 `(("python-numpy" ,python-numpy)))
227 (modify-phases %standard-phases
228 (add-after 'unpack 'patch-geos-path
229 (lambda* (#:key inputs #:allow-other-keys)
230 (let ((geos (assoc-ref inputs "geos"))
231 (glibc (assoc-ref inputs ,(if (%current-target-system)
232 "cross-libc" "libc"))))
233 (substitute* "shapely/geos.py"
234 (("_lgeos = load_dll\\('geos_c', fallbacks=.*\\)")
235 (string-append "_lgeos = load_dll('geos_c', fallbacks=['"
236 geos "/lib/libgeos_c.so'])"))
237 (("free = load_dll\\('c'\\)\\.free")
238 (string-append "free = load_dll('c', fallbacks=['"
239 glibc "/lib/libc.so.6']).free"))))
241 (home-page "https://github.com/Toblerity/Shapely")
242 (synopsis "Library for the manipulation and analysis of geometric objects")
243 (description "Shapely is a Python package for manipulation and analysis of
244 planar geometric objects. It is based on the @code{GEOS} library.")
245 (license license:bsd-3)))
247 (define-public python-shortuuid
249 (name "python-shortuuid")
254 (uri (pypi-uri "shortuuid" version))
257 "1f8i4zwj5vmpzbz6b17bljy4399gx5aq7vsyw63sz2qgyjcd73yh"))))
258 (build-system python-build-system)
260 `(("python-pep8" ,python-pep8)))
261 (home-page "https://github.com/skorokithakis/shortuuid")
262 (synopsis "Generator library for concise, unambiguous and URL-safe UUIDs")
264 "@code{shortuuid} is a Python library for generating concise, unambiguous
265 and URL-safe UUIDs. UUIDs are generated using the built-in Python @code{uuid}
266 module and then similar looking characters are removed.")
267 (license license:bsd-3)))
269 (define-public python-logwrap
271 (name "python-logwrap")
276 (uri (pypi-uri "logwrap" version ".zip"))
279 "1d2k0hvpbi51vl410y8fbs5m0nxnlh2k7gr2nrh3k81ibhzscsra"))))
280 (build-system python-build-system)
282 `(("python-six" ,python-six)
283 ("python-typing" ,python-typing)))
286 ("python-cython" ,python-cython)
287 ("python-pytest" ,python-pytest)
288 ("python-pytest-cov" ,python-pytest-cov)
289 ("python-pytest-runner" ,python-pytest-runner)))
290 (home-page "https://github.com/penguinolog/logwrap")
291 (synopsis "Decorator for logging function arguments")
292 (description "This package provides a decorator to log function arguments
293 and function call return values in a human-readable way.")
294 (license license:asl2.0)))
296 (define-public python2-shapely
297 (package-with-python2 python-shapely))
299 (define-public python-clyent
301 (name "python-clyent")
306 (uri (pypi-uri "clyent" version))
309 "1r9987qmy1pz3hq54160bapqsywpq14waw4w9x3ly8hmq7kpgfbj"))))
310 (build-system python-build-system)
312 `(("python-mock" ,python-mock)))
313 (home-page "https://github.com/binstar/clyent")
314 (synopsis "Command line client library")
315 (description "Clyent is a Python command line utiliy library. It is used
316 by @code{binstar}, @code{binstar-build} and @code{chalmers}.")
317 (license license:bsd-3)))
319 (define-public python2-clyent
320 (package-with-python2 python-clyent))
322 (define-public python-babel
324 (name "python-babel")
329 (uri (pypi-uri "Babel" version))
332 "0a7wawx8vsg7igvz6p3x909fskhg4b2y1910xk4f4c8y22p3aqg8"))))
333 (build-system python-build-system)
335 `(("python-freezegun" ,python-freezegun)
336 ("python-pytest" ,python-pytest)))
338 `(("python-pytz" ,python-pytz)))
340 `(#:phases (modify-phases %standard-phases
343 (invoke "pytest" "-vv" "-k"
345 ;; XXX: These tests fail when using Pytest 4.x and
346 ;; Babel 2.6.0. Try removing this for later versions.
347 "not test_no_inherit_metazone_marker_never_in_output"
348 " and not test_smoke_dates"
349 " and not test_smoke_numbers")))))))
350 (home-page "http://babel.pocoo.org/")
352 "Tools for internationalizing Python applications")
354 "Babel is composed of two major parts:
355 - tools to build and work with gettext message catalogs
356 - a Python interface to the CLDR (Common Locale Data Repository), providing
357 access to various locale display names, localized number and date formatting,
359 (license license:bsd-3)))
361 (define-public python2-babel
362 (package-with-python2 python-babel))
364 ;; Sphinx < 2.0 requires this version. Remove once no longer needed.
365 (define-public python2-babel-2.6
367 (inherit python2-babel)
371 (uri (pypi-uri "Babel" version))
374 "08rxmbx2s4irp0w0gmn498vns5xy0fagm0fg33xa772jiks51flc"))))))
376 (define-public python2-backport-ssl-match-hostname
378 (name "python2-backport-ssl-match-hostname")
383 (uri (pypi-uri "backports.ssl_match_hostname" version))
386 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
387 (build-system python-build-system)
390 #:tests? #f)) ; no test target
391 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
392 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
394 "This backport brings the ssl.match_hostname() function to users of
395 earlier versions of Python. The function checks the hostname in the
396 certificate returned by the server to which a connection has been established,
397 and verifies that it matches the intended target hostname.")
398 (license license:psfl)))
400 (define-public python-boolean.py
402 (name "python-boolean.py")
406 ;; There's no source tarball on PyPI.
409 (url "https://github.com/bastikr/boolean.py")
410 (commit (string-append "v" version))))
411 (file-name (git-file-name name version))
413 (base32 "1wc89y73va58cj7dsx6c199zpxsy9q53dsffsdj6zmc90inqz6qs"))))
414 (build-system python-build-system)
415 (home-page "https://github.com/bastikr/boolean.py")
416 (synopsis "Boolean algebra in one Python module")
418 "This is a small Python library that implements boolean algebra.
419 It defines two base elements, @code{TRUE} and @code{FALSE}, and a
420 @code{Symbol} class that can take on one of these two values. Calculations
421 are done only in terms of @code{AND}, @code{OR}, and @code{NOT}---other
422 compositions like @code{XOR} and @code{NAND} are emulated on top of them.
423 Expressions are constructed from parsed strings or directly in Python.")
424 (license license:bsd-2)))
426 (define-public python-hdf4
433 (uri (pypi-uri name version))
436 "1hjiyrxvxk9817qyqky3nar4y3fs4z8wxz0n884zzb5wi6skrjks"))))
437 (build-system python-build-system)
438 (native-inputs `(("nose" ,python-nose)))
439 (propagated-inputs `(("numpy" ,python-numpy)))
446 (modify-phases %standard-phases
449 ;; The 'runexamples' script sets PYTHONPATH to CWD, then goes
450 ;; on to import numpy. Somehow this works on their CI system.
451 ;; Let's just manage PYTHONPATH here instead.
452 (substitute* "runexamples.sh"
453 (("export PYTHONPATH=.*") ""))
455 (string-append (getcwd) ":"
456 (getenv "PYTHONPATH")))
457 (invoke "./runexamples.sh")
458 (invoke "nosetests" "-v"))))))
459 (home-page "https://github.com/fhs/python-hdf4")
460 (synopsis "Python interface to the NCSA HDF4 library")
462 "Python-HDF4 is a python wrapper around the NCSA HDF version 4 library,
463 which implements the SD (Scientific Dataset), VS (Vdata) and V (Vgroup) API’s.
464 NetCDF files can also be read and modified. Python-HDF4 is a fork of
465 @url{http://hdfeos.org/software/pyhdf.php,pyhdf}.")
466 (license license:expat)))
468 (define-public python2-hdf4
469 (package-with-python2 python-hdf4))
471 (define-public python-h5py
478 (uri (pypi-uri "h5py" version))
481 "0mdr6wrq02ac93m1aqx9kad0ppfzmm4imlxqgyy1x4l7hmdcc9p6"))))
482 (build-system python-build-system)
484 `(#:tests? #f ; no test target
486 (modify-phases %standard-phases
487 (add-after 'unpack 'fix-hdf5-paths
488 (lambda* (#:key inputs #:allow-other-keys)
489 (let ((prefix (assoc-ref inputs "hdf5")))
490 (substitute* "setup_build.py"
491 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
492 (string-append "['" prefix "/lib" "']"))
493 (("'/opt/local/include', '/usr/local/include'")
494 (string-append "'" prefix "/include" "'")))
495 (substitute* "setup_configure.py"
496 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
497 (string-append "['" prefix "/lib" "']")))
500 `(("python-six" ,python-six)
501 ("python-numpy" ,python-numpy)))
505 `(("python-cython" ,python-cython)
506 ("python-pkgconfig" ,python-pkgconfig)))
507 (home-page "http://www.h5py.org/")
508 (synopsis "Read and write HDF5 files from Python")
510 "The h5py package provides both a high- and low-level interface to the
511 HDF5 library from Python. The low-level interface is intended to be a
512 complete wrapping of the HDF5 API, while the high-level component supports
513 access to HDF5 files, datasets and groups using established Python and NumPy
515 (license license:bsd-3)))
517 (define-public python2-h5py
518 (package-with-python2 python-h5py))
520 (define-public python-sh
527 (uri (pypi-uri "sh" version))
530 "1z2hx357xp3v4cv44xmqp7lli3frndqpyfmpbxf7n76h7s1zaaxm"))))
531 (build-system python-build-system)
534 (modify-phases %standard-phases
537 ;; XXX: A Python 2 test fails when HOME=/homeless-shelter.
538 (setenv "HOME" "/tmp")
539 (invoke "python" "sh.py" "test"))))))
541 `(("python-coverage" ,python-coverage)))
542 (home-page "https://github.com/amoffat/sh")
543 (synopsis "Python subprocess replacement")
544 (description "This package provides a replacement for Python's
545 @code{subprocess} feature.")
546 (license license:expat)))
548 (define-public python2-sh
549 (package-with-python2 python-sh))
551 (define-public python-cftime
553 (name "python-cftime")
558 (uri (pypi-uri "cftime" version))
560 (base32 "0w0gi6jnch38hiygl62j4xkcirv4y3dcwrvxl9p7bsk6j27lzihs"))))
561 (build-system python-build-system)
563 `(("python-numpy" ,python-numpy)))
565 `(("python-coveralls" ,python-coveralls)
566 ("python-cython" ,python-cython)
567 ("python-pytest-cov" ,python-pytest-cov)))
568 (home-page "https://github.com/Unidata/cftime")
569 (synopsis "Library for time handling")
571 "This package provides time-handling functionality that used to be part
572 of the netcdf4 package before.")
573 ;; This package claims to include code under the GPLv3 but is released
575 (license (list license:isc license:gpl3+))))
577 (define-public python-netcdf4
579 (name "python-netcdf4")
584 (uri (pypi-uri "netCDF4" version))
587 "0c0sklgrmv15ygliin8qq0hp7vanmbi74m6zpi0r1ksr0hssyd5r"))))
588 (build-system python-build-system)
591 (modify-phases %standard-phases
592 (add-after 'unpack 'configure-locations
593 (lambda* (#:key inputs #:allow-other-keys)
594 (setenv "HDF5_DIR" (assoc-ref inputs "hdf5"))
597 `(("python-cython" ,python-cython)))
599 `(("python-numpy" ,python-numpy)
600 ("python-cftime" ,python-cftime)))
605 (home-page "https://github.com/Unidata/netcdf4-python")
606 (synopsis "Python/numpy interface to the netCDF library")
607 (description "Netcdf4-python is a Python interface to the netCDF C
608 library. netCDF version 4 has many features not found in earlier
609 versions of the library and is implemented on top of HDF5. This module
610 can read and write files in both the new netCDF 4 and the old netCDF 3
611 format, and can create files that are readable by HDF5 clients. The
612 API is modelled after @code{Scientific.IO.NetCDF}, and should be familiar
613 to users of that module.")
614 ;; The software is mainly ISC, but includes some files covered
615 ;; by the Expat license.
616 (license (list license:isc license:expat))))
618 (define-public python2-netcdf4
619 (package-with-python2 python-netcdf4))
621 (define-public python-license-expression
623 (name "python-license-expression")
628 (uri (pypi-uri "license-expression" version))
630 (base32 "08ppb0bxbrsxazy88sgpl9yffvdsabw6dkk1nc332wcz2mphwwyf"))))
631 (build-system python-build-system)
633 `(("python-boolean.py" ,python-boolean.py)))
634 (home-page "https://github.com/nexB/license-expression")
635 (synopsis "Apply boolean logic to license expressions")
637 "This Python module defines a tiny language to evaluate and compare
638 license expressions using boolean logic. Logical combinations of licenses can
639 be tested for equality, containment, and equivalence. They can be normalised
640 and simplified. It supports SPDX license expressions as well as other naming
641 conventions and aliases in the same expression.")
642 (license license:gpl2+)))
644 (define-public python-lockfile
646 (name "python-lockfile")
651 (uri (pypi-uri "lockfile" version))
654 "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba"))))
655 (build-system python-build-system)
656 (arguments '(#:test-target "check"))
658 `(("python-pbr" ,python-pbr)))
659 (home-page "https://launchpad.net/pylockfile")
660 (synopsis "Platform-independent file locking module")
662 "The lockfile package exports a LockFile class which provides a simple
663 API for locking files.")
664 (license license:expat)))
666 (define-public python2-lockfile
667 (package-with-python2 python-lockfile))
669 (define-public python-semantic-version
671 (name "python-semantic-version")
676 (uri (pypi-uri "semantic_version" version))
679 "1h2l9xyg1zzsda6kjcmfcgycbvrafwci283vcr1v5sbk01l2hhra"))))
680 (build-system python-build-system)
682 `(#:tests? #f)) ; PyPI tarball lacks tests
683 (home-page "https://github.com/rbarrois/python-semanticversion")
684 (synopsis "Semantic versioning module for Python")
686 "The @code{semantic_version} class is a small library for handling
687 @uref{https://semver.org/, semantic versioning} (@dfn{SemVer}) in Python.
689 It can compare versions, generate a new version that represents a bump in one of
690 the version levels, and check whether any given string is a proper semantic
691 version identifier.")
692 (license license:bsd-3)))
694 (define-public python2-semantic-version
695 (package-with-python2 python-semantic-version))
697 (define-public python-serpent
699 (name "python-serpent")
704 (uri (pypi-uri "serpent" version))
706 (base32 "1arnckykpkvv2qrp49l1k7q5mr5pisswl0rvdx98x8wsl1n361pk"))))
707 (build-system python-build-system)
709 `(("python-attrs" ,python-attrs)
710 ("python-pytz" ,python-pytz)))
711 (home-page "https://github.com/irmen/Serpent")
712 (synopsis "Serializer for literal Python expressions")
714 "Serpent provides @code{ast.literal_eval()}-compatible object tree
715 serialization. It serializes an object tree into bytes (an utf-8 encoded
716 string) that can be decoded and then passed as-is to @code{ast.literal_eval()}
717 to rebuild the original object tree.
719 Because only safe literals are encoded, it is safe to send serpent data to
720 other machines, such as over the network.")
721 (license license:expat)))
723 (define-public python-setuptools
725 (name "python-setuptools")
730 (uri (pypi-uri "setuptools" version ".zip"))
733 "04sns22y2hhsrwfy1mha2lgslvpjsjsz8xws7h2rh5a7ylkd28m2"))
734 (modules '((guix build utils)))
737 ;; Remove included binaries which are used to build self-extracting
738 ;; installers for Windows.
739 ;; TODO: Find some way to build them ourself so we can include them.
740 (for-each delete-file (find-files "setuptools" "^(cli|gui).*\\.exe$"))
742 (build-system python-build-system)
743 ;; FIXME: Tests require pytest, which itself relies on setuptools.
744 ;; One could bootstrap with an internal untested setuptools.
747 (home-page "https://pypi.python.org/pypi/setuptools")
749 "Library designed to facilitate packaging Python projects")
751 "Setuptools is a fully-featured, stable library designed to facilitate
752 packaging Python projects, where packaging includes:
753 Python package and module definitions,
754 distribution package metadata,
756 project installation,
757 platform-specific details,
759 ;; TODO: setuptools now bundles the following libraries:
760 ;; packaging, pyparsing, six and appdirs. How to unbundle?
761 (license (list license:psfl ; setuptools itself
762 license:expat ; six, appdirs, pyparsing
763 license:asl2.0 ; packaging is dual ASL2/BSD-2
766 (define-public python2-setuptools
767 (package-with-python2 python-setuptools))
769 ;; The setuptools provided by Python 3.7.4 is too new for Tensorflow.
770 (define-public python-setuptools-for-tensorflow
773 (inherit python-setuptools)
776 (inherit (package-source python-setuptools))
777 (uri (pypi-uri "setuptools" version ".zip"))
780 "1mzdhvfhnv4lggxa8rjl0dzqxvfx377gg5sqs57v89wrp09lwj65")))))))
782 (define-public python-uniseg
784 (name "python-uniseg")
789 (uri (pypi-uri "uniseg" version ".zip"))
792 "05jsazvz6nbmh6l3v1rph5ydkqn1hzx1pyggdyvgp2qgmgrnmiz2"))))
793 (build-system python-build-system)
795 '(#:tests? #f)) ; The test suite requires network access.
799 "https://bitbucket.org/emptypage/uniseg-python")
801 "Python library to determine Unicode text segmentations")
803 "Uniseg is a Python package used to determine Unicode text segmentations.
804 Supported segmentations include:
806 @item @dfn{Code point} (any value in the Unicode codespace)
807 @item @dfn{Grapheme cluster} (user-perceived character made of a single or
808 multiple Unicode code points, e.g. \"G\" + acute-accent)
813 (license license:expat)))
815 (define-public python2-uniseg
816 (package-with-python2 python-uniseg))
818 (define-public python-humanfriendly
820 (name "python-humanfriendly")
825 (uri (pypi-uri "humanfriendly" version))
828 "0pisgizjql86785jchfjv217g0lsgk114g2lja5j4y3lsc3b9szi"))))
829 (build-system python-build-system)
831 `(;; XXX: Tests depend on coloredlogs, which in turn depends on humanfriendly.
834 `(("python-monotonic" ,python-monotonic)))
835 (home-page "https://humanfriendly.readthedocs.io")
836 (synopsis "Human-friendly input and output in Python")
838 "The functions and classes in @code{humanfriendly} can be used to make
839 text interfaces more user-friendly. It includes tools to parse and format
840 numbers, file sizes, and timespans, timers for long-running operations, menus
841 to allow the user to choose from a list of options, and terminal interaction
843 (license license:expat)))
845 (define-public python2-humanfriendly
846 (package-with-python2 python-humanfriendly))
848 (define-public python-capturer
850 (name "python-capturer")
855 (uri (pypi-uri "capturer" version))
858 "05d6ji4j8ipiq0br7bwam38qc6hd9l1djmfxlzrxx19ziyjl4089"))))
859 (build-system python-build-system)
863 `(("python-humanfriendly" ,python-humanfriendly)))
864 (home-page "https://capturer.readthedocs.io")
865 (synopsis "Capture stdout and stderr streams of the current process")
867 "The capturer package makes it easy to capture the stdout and stderr
868 streams of the current process and subprocesses. Output can be relayed
869 to the terminal in real time but is also available to the Python program
870 for additional processing.")
871 (license license:expat)))
873 (define-public python2-capturer
874 (package-with-python2 python-capturer))
876 (define-public python-case
883 (uri (pypi-uri "case" version))
886 "1cagg06vfph864s6l5jb0zqliwxh647bki8j6lf4a4qrv40jnhs8"))))
887 (build-system python-build-system)
889 `(("python-mock" ,python-mock)
890 ("python-nose" ,python-nose)
891 ("python-six" ,python-six)
892 ("python-unittest2" ,python-unittest2)))
894 `(("python-coverage" ,python-coverage)))
895 (home-page "https://github.com/celery/case")
896 (synopsis "Unittest utilities and convenience methods")
898 "The @code{case} package provides utilities on top of unittest, including
899 some helpful Python 2 compatibility convenience methods.")
900 (license license:bsd-3)))
902 (define-public python-verboselogs
904 (name "python-verboselogs")
909 (uri (pypi-uri "verboselogs" version))
912 "09z4d1jiasn7k1hs5af2ckmnrd0i1d1m04bhfjhv7z6svzfdwgg3"))))
913 (build-system python-build-system)
916 (modify-phases %standard-phases
919 ;; Do not run pylint plugin test, as astroid is an old
920 ;; unsupported version.
921 (invoke "pytest" "-v" "-k" "not test_pylint_plugin"
922 "verboselogs/tests.py"))))))
924 `(("python-mock" ,python-mock)
925 ("python-pytest" ,python-pytest)))
926 (home-page "https://verboselogs.readthedocs.io")
927 (synopsis "Verbose logging level for Python's logging module")
929 "The @code{verboselogs} package extends Python's @code{logging} module to
930 add the log levels NOTICE, SPAM, SUCCESS and VERBOSE.")
931 (license license:expat)))
933 (define-public python2-verboselogs
934 (package-with-python2 python-verboselogs))
936 (define-public python-coloredlogs
938 (name "python-coloredlogs")
943 (uri (pypi-uri "coloredlogs" version))
946 "0dkw6xp0r1dwgz4s2f58npx5nxfq51wf4l6qkm5ib27slgfs4sdq"))))
947 (build-system python-build-system)
949 `(;Tests require some updated modules
952 `(("python-capturer" ,python-capturer)))
953 (home-page "https://coloredlogs.readthedocs.io")
954 (synopsis "Colored stream handler for Python's logging module")
956 "The @code{coloredlogs} package enables colored terminal output for
957 Python's logging module. The @code{ColoredFormatter} class inherits from
958 @code{logging.Formatter} and uses ANSI escape sequences to render your logging
960 (license license:expat)))
962 (define-public python2-coloredlogs
963 (package-with-python2 python-coloredlogs))
965 (define-public python-editorconfig
967 (name "python-editorconfig")
972 (uri (pypi-uri "EditorConfig" version))
975 "0v55z351p9qkyp3bbspwywwn28sbcknhirngjbj779n3z52z63hv"))))
976 (build-system python-build-system)
977 (home-page "https://editorconfig.org/")
978 (synopsis "EditorConfig bindings for python")
979 (description "The EditorConfig project consists of a file format for
980 defining coding styles and a collection of text editor plugins that enable
981 editors to read the file format and adhere to defined styles. EditorConfig
982 files are easily readable and they work nicely with version control systems.")
983 ;; "fnmatch.py" and "ini.py" are licensed under psfl, the rest is bsd-2.
984 (license (list license:bsd-2 license:psfl))))
986 (define-public python-et-xmlfile
988 (name "python-et-xmlfile")
993 (uri (pypi-uri "et_xmlfile" version))
996 "0nrkhcb6jdrlb6pwkvd4rycw34y3s931hjf409ij9xkjsli9fkb1"))))
997 (build-system python-build-system)
999 `(#:phases (modify-phases %standard-phases
1002 (invoke "pytest"))))))
1004 `(("python-pytest" ,python-pytest)
1005 ("python-lxml" ,python-lxml))) ;used for the tests
1006 (home-page "https://bitbucket.org/openpyxl/et_xmlfile")
1007 (synopsis "Low memory implementation of @code{lxml.xmlfile}")
1008 (description "This Python library is based upon the @code{xmlfile} module
1009 from @code{lxml}. It aims to provide a low memory, compatible implementation
1010 of @code{xmlfile}.")
1011 (license license:expat)))
1013 (define-public python2-et-xmlfile
1014 (package-with-python2 python-et-xmlfile))
1016 (define-public python-openpyxl
1018 (name "python-openpyxl")
1022 ;; We use the upstream repository, as the tests are not included in the
1026 (url "https://bitbucket.org/openpyxl/openpyxl")
1027 (changeset version)))
1028 (file-name (string-append name "-" version "-checkout"))
1030 (base32 "1qhij6kcvdxqjy4g6193nsv4q7fy8n4fwyd3c2z047idlm6s3j4w"))))
1031 (build-system python-build-system)
1033 `(#:phases (modify-phases %standard-phases
1036 (invoke "pytest"))))))
1038 ;; For the test suite.
1039 `(("python-lxml" ,python-lxml)
1040 ("python-pillow" ,python-pillow)
1041 ("python-pytest" ,python-pytest)))
1043 `(("python-et-xmlfile" ,python-et-xmlfile)
1044 ("python-jdcal" ,python-jdcal)))
1045 (home-page "https://openpyxl.readthedocs.io")
1046 (synopsis "Python library to read/write Excel 2010 XLSX/XLSM files")
1047 (description "This Python library allows reading and writing to the Excel XLSX, XLSM,
1048 XLTX and XLTM file formats that are defined by the Office Open XML (OOXML)
1050 (license license:expat)))
1052 (define-public python-eventlet
1054 (name "python-eventlet")
1059 (uri (pypi-uri "eventlet" version))
1062 "1hgz8jq19wlz8vwqj900ry8cjv578nz4scc91mlc8944yid6573c"))))
1063 (build-system python-build-system)
1065 `(("python-greenlet" ,python-greenlet)))
1067 ;; TODO: Requires unpackaged 'enum-compat'.
1069 (home-page "https://eventlet.net")
1070 (synopsis "Concurrent networking library for Python")
1072 "Eventlet is a concurrent networking library for Python that
1073 allows you to change how you run your code, not how you write it.
1074 It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O.
1075 Coroutines ensure that the developer uses a blocking style of programming
1076 that is similar to threading, but provide the benefits of non-blocking I/O.
1077 The event dispatch is implicit, which means you can easily use @code{Eventlet}
1078 from the Python interpreter, or as a small part of a larger application.")
1079 (license license:expat)))
1081 (define-public python2-eventlet
1082 (let ((base (package-with-python2
1083 (strip-python2-variant python-eventlet))))
1084 (package (inherit base)
1086 `(("python2-enum34" ,python2-enum34)
1087 ,@(package-propagated-inputs base))))))
1089 (define-public python-six
1096 (uri (pypi-uri "six" version))
1099 "0wxs1q74v07ssjywbbm7x6h5v9qx209ld2yfsif4060sxi0h2sni"))))
1100 (build-system python-build-system)
1103 (modify-phases %standard-phases
1106 (invoke "py.test" "-v"))))))
1108 `(("python-py" ,python-py)
1109 ("python-pytest" ,python-pytest-bootstrap)))
1110 (home-page "https://pypi.python.org/pypi/six/")
1111 (synopsis "Python 2 and 3 compatibility utilities")
1113 "Six is a Python 2 and 3 compatibility library. It provides utility
1114 functions for smoothing over the differences between the Python versions with
1115 the goal of writing Python code that is compatible on both Python versions.
1116 Six supports every Python version since 2.5. It is contained in only one
1117 Python file, so it can be easily copied into your project.")
1118 (license license:x11)))
1120 (define-public python2-six
1121 (package-with-python2 python-six))
1123 (define-public python-six-bootstrap
1125 (inherit python-six)
1126 (name "python-six-bootstrap")
1128 (arguments `(#:tests? #f))))
1130 (define-public python2-six-bootstrap
1131 (package-with-python2 python-six-bootstrap))
1133 (define-public python-schedule
1135 (name "python-schedule")
1140 (uri (pypi-uri "schedule" version))
1143 "0vplyjcbfrq50sphlwya749z8p2pcyi2nycw3518i0qpd9a6189i"))))
1144 (build-system python-build-system)
1146 `(("python-pytest" ,python-pytest)
1147 ("python-mock" ,python-mock)))
1148 (home-page "https://github.com/dbader/schedule")
1149 (synopsis "Schedule periodic function calls in Python")
1151 "Schedule is an in-process scheduler for periodic jobs that uses the
1152 builder pattern for configuration. Schedule lets you run Python functions (or
1153 any other callable) periodically at pre-determined intervals using a simple,
1154 human-friendly syntax.")
1155 (license license:expat)))
1157 (define-public python2-schedule
1158 (package-with-python2 python-schedule))
1160 (define-public python2-mechanize
1162 (name "python2-mechanize")
1167 (uri (pypi-uri "mechanize" version))
1170 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1171 (build-system python-build-system)
1173 `(#:python ,python-2 ; apparently incompatible with Python 3
1175 ;; test fails with message
1176 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1177 ;; (python-3.3.2) or
1178 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1180 ;; The source code is from March 2011 and probably not up-to-date
1181 ;; with respect to python unit tests.
1182 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1184 "Stateful programmatic web browsing in Python")
1186 "Mechanize implements stateful programmatic web browsing in Python,
1187 after Andy Lester’s Perl module WWW::Mechanize.")
1188 (license (license:non-copyleft
1190 "See COPYING in the distribution."))))
1193 (define-public python-simplejson
1195 (name "python-simplejson")
1200 (uri (pypi-uri "simplejson" version))
1203 "1lkv3xlf7ryzi69zqfdbkvpxdfy1rg1rq2yzcnxgf4km5m6difqy"))))
1204 (build-system python-build-system)
1205 (home-page "http://simplejson.readthedocs.org/en/latest/")
1207 "Json library for Python")
1209 "JSON (JavaScript Object Notation) is a subset of JavaScript
1210 syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1213 Simplejson exposes an API familiar to users of the standard library marshal
1214 and pickle modules. It is the externally maintained version of the json
1215 library contained in Python 2.6, but maintains compatibility with Python 2.5
1216 and (currently) has significant performance advantages, even without using
1217 the optional C extension for speedups. Simplejson is also supported on
1219 (license license:x11)))
1221 (define-public python2-simplejson
1222 (package-with-python2 python-simplejson))
1225 (define-public python-pyicu
1227 (name "python-pyicu")
1232 (uri (pypi-uri "PyICU" version))
1235 "1x4w8m7ifki9z2a187pgjr33z6z0rp2fii9b73djak1vhm9v9cnx"))))
1236 (build-system python-build-system)
1238 `(("icu4c" ,icu4c)))
1240 `(("python-pytest" ,python-pytest)
1241 ("python-six" ,python-six)))
1242 (home-page "https://github.com/ovalhub/pyicu")
1243 (synopsis "Python extension wrapping the ICU C++ API")
1245 "PyICU is a python extension wrapping the ICU C++ API.")
1246 (properties `((python2-variant . ,(delay python2-pyicu))))
1247 (license license:x11)))
1249 (define-public python2-pyicu
1250 (let ((base (package-with-python2
1251 (strip-python2-variant python-pyicu))))
1255 `(,@(package-arguments base)
1257 (modify-phases %standard-phases
1258 (add-before 'check 'delete-failing-test
1260 ;; XXX: This fails due to Unicode issues unique to Python 2,
1261 ;; it seems: <https://github.com/ovalhub/pyicu/issues/61>.
1262 (delete-file "test/test_Script.py")
1265 (define-public python2-dogtail
1266 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1267 ;; spaces in indentation" with Python 3.
1269 (name "python2-dogtail")
1273 (uri (pypi-uri "dogtail" version))
1276 "0p5wfssvzr9w0bvhllzbbd8fnp4cca2qxcpcsc33dchrmh5n552x"))))
1277 (build-system python-build-system)
1278 (arguments `(#:python ,python-2
1279 #:tests? #f)) ; invalid command "test"
1280 ;; Currently no offical homepage.
1281 (home-page "https://pypi.python.org/pypi/dogtail/")
1282 (synopsis "GUI test tool and automation framework written in Python")
1284 "Dogtail is a GUI test tool and automation framework written in Python.
1285 It uses Accessibility (a11y) technologies to communicate with desktop
1286 applications. dogtail scripts are written in Python and executed like any
1287 other Python program.")
1288 (license license:gpl2+)))
1290 (define-public python-empy
1292 (name "python-empy")
1296 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1300 "1mxfy5mgp473ga1pgz2nvm8ds6z4g3hdky8523z6jzvcs9ny6hcq"))))
1301 (build-system python-build-system)
1303 `(#:tests? #f)) ; python2 only
1304 (home-page "http://www.alcyone.com/software/empy/")
1305 (synopsis "Templating system for Python")
1307 "EmPy is a system for embedding Python expressions and statements in
1308 template text; it takes an EmPy source file, processes it, and produces
1309 output. This is accomplished via expansions, which are special signals to the
1310 EmPy system and are set off by a special prefix (by default the at sign, @@).
1311 EmPy can expand arbitrary Python expressions and statements in this way, as
1312 well as a variety of special forms. Textual data not explicitly delimited in
1313 this way is sent unaffected to the output, allowing Python to be used in
1314 effect as a markup language. Also supported are callbacks via hooks,
1315 recording and playback via diversions, and dynamic, chainable filters. The
1316 system is highly configurable via command line options and embedded
1318 (license license:lgpl2.1+)))
1320 (define-public python2-empy
1321 (let ((base (package-with-python2 (strip-python2-variant python-empy))))
1324 (arguments `(,@(package-arguments base)
1327 (define-public python2-element-tree
1329 (name "python2-element-tree")
1334 "http://effbot.org/media/downloads/elementtree-"
1335 version "-20050316.tar.gz"))
1338 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1339 (build-system python-build-system)
1341 `(#:python ,python-2 ; seems to be part of Python 3
1342 #:tests? #f)) ; no 'test' sub-command
1343 (synopsis "Toolkit for XML processing in Python")
1345 "ElementTree is a Python library supporting lightweight XML processing.")
1346 (home-page "http://effbot.org/zone/element-index.htm")
1347 (license (license:x11-style
1348 "http://docs.python.org/2/license.html"
1349 "Like \"CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2\"."))))
1351 (define-public python2-pybugz
1353 (name "python2-pybugz")
1358 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1362 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
1363 (patches (search-patches "pybugz-stty.patch"
1364 "pybugz-encode-error.patch"))))
1365 (build-system python-build-system)
1367 `(#:python ,python-2 ; SyntaxError with Python 3
1368 #:tests? #f)) ; no 'test' sub-command
1370 `(("element-tree" ,python2-element-tree)))
1371 (synopsis "Python and command-line interface to Bugzilla")
1373 "PyBugz is a Python library and command-line tool to query the Bugzilla
1374 bug tracking system. It is meant as an aid to speed up interaction with the
1376 (home-page "http://www.liquidx.net/pybugz/")
1377 (license license:gpl2)))
1379 (define-public python2-enum
1381 (name "python2-enum")
1385 (uri (pypi-uri "enum" version))
1388 "13lk3yrwj42vl30kw3c194f739nrfrdg64s6i0v2p636n4k8brsl"))))
1389 (build-system python-build-system)
1391 `(#:python ,python-2))
1392 (home-page "http://pypi.python.org/pypi/enum/")
1393 (synopsis "Robust enumerated type support in Python")
1395 "This provides a module for robust enumerations in Python. It has
1396 been superseded by the Python standard library and is provided only for
1398 ;; Choice of either license.
1399 (license (list license:gpl3+ license:psfl))))
1401 (define-public python-enum34
1403 (name "python-enum34")
1408 (uri (pypi-uri "enum34" version))
1411 "1cgm5ng2gcfrkrm3hc22brl6chdmv67b9zvva9sfs7gn7dwc9n4a"))))
1412 (build-system python-build-system)
1413 (home-page "https://pypi.python.org/pypi/enum34")
1414 (synopsis "Backported Python 3.4 Enum")
1416 "Enum34 is the new Python stdlib enum module available in Python 3.4
1417 backported for previous versions of Python from 2.4 to 3.3.")
1418 (license license:bsd-3)))
1420 (define-public python2-enum34
1421 (package-with-python2 python-enum34))
1423 (define-public python-parse-type
1425 (name "python-parse-type")
1430 (uri (pypi-uri "parse_type" version))
1433 "0g3b6gsdwnm8dpkh2vn34q6dzxm9gl908ggyzcv31n9xbp3vv5pm"))))
1434 (build-system python-build-system)
1436 `(("python-six" ,python-six)
1437 ("python-parse" ,python-parse)))
1439 `(("python-pytest" ,python-pytest)
1440 ("python-pytest-runner" ,python-pytest-runner)))
1441 (home-page "https://github.com/jenisys/parse_type")
1442 (synopsis "Extended parse module")
1444 "Parse_type extends the python parse module.")
1446 `((python2-variant . ,(delay python2-parse-type))))
1447 (license license:bsd-3)))
1449 (define-public python2-parse-type
1450 (let ((base (package-with-python2
1451 (strip-python2-variant python-parse-type))))
1452 (package (inherit base)
1454 `(("python2-enum34" ,python2-enum34)
1455 ,@(package-propagated-inputs base))))))
1457 (define-public python-parse
1459 (name "python-parse")
1464 (uri (pypi-uri "parse" version))
1467 "0f8997xr8nq2nq35iiviq8ningd1zvy59fg503xfpbi2dwhgdkf3"))))
1468 (build-system python-build-system)
1471 (modify-phases %standard-phases
1473 (lambda _ (invoke "python" "test_parse.py"))))))
1474 (home-page "https://github.com/r1chardj0n3s/parse")
1475 (synopsis "Parse strings")
1477 "Parse strings using a specification based on the Python @code{format()}
1479 (license license:x11)))
1481 (define-public python-polib
1483 (name "python-polib")
1487 (uri (pypi-uri "polib" version))
1490 "1pq2hbm3m2q0cjdszk8mc4qa1vl3wcblh5nfyirlfnzb2pcy7zss"))))
1491 (build-system python-build-system)
1492 (home-page "https://bitbucket.org/izi/polib/wiki/Home")
1493 (synopsis "Manipulate, create and modify gettext files")
1494 (description "Polib can manipulate any gettext format (po, pot and mo)
1495 files. It can be used to create po files from scratch or to modify
1497 (license license:expat)))
1499 (define-public python2-polib
1500 (let ((base (package-with-python2 (strip-python2-variant python-polib))))
1503 (arguments `(,@(package-arguments base)
1504 ;; Tests don't work with python2.
1507 (define-public python-poyo
1509 (name "python-poyo")
1514 (uri (pypi-uri "poyo" version))
1517 "1pflivs6j22frz0v3dqxnvc8yb8fb52g11lqr88z0i8cg2m5csg2"))))
1518 (build-system python-build-system)
1519 (home-page "https://github.com/hackebrot/poyo")
1520 (synopsis "Lightweight YAML Parser for Python")
1522 "This package provides a lightweight YAML Parser for Python. It supports
1523 only a chosen subset of the YAML format that is required to parse cookiecutter
1524 user configuration files. It does not have support for serializing into YAML
1525 and is not compatible with JSON.")
1526 (license license:expat)))
1528 (define-public scons
1535 (url "https://github.com/SCons/scons.git")
1537 (file-name (git-file-name name version))
1540 "1xy8jrwz87y589ihcld4hv7wn122sjbz914xn8h50ww77wbhk8hn"))))
1541 (build-system python-build-system)
1543 `(#:use-setuptools? #f ; still relies on distutils
1544 #:tests? #f ; no 'python setup.py test' command
1546 (modify-phases %standard-phases
1547 (add-before 'build 'bootstrap
1549 (substitute* "src/engine/SCons/compat/__init__.py"
1550 (("sys.modules\\[new\\] = imp.load_module\\(old, \\*imp.find_module\\(old\\)\\)")
1551 "sys.modules[new] = __import__(old)"))
1552 (substitute* "src/engine/SCons/Platform/__init__.py"
1553 (("mod = imp.load_module\\(full_name, file, path, desc\\)")
1554 "mod = __import__(full_name)"))
1555 (invoke "python" "bootstrap.py" "build/scons" "DEVELOPER=guix")
1556 (chdir "build/scons")
1558 (home-page "http://scons.org/")
1559 (synopsis "Software construction tool written in Python")
1561 "SCons is a software construction tool. Think of SCons as an improved,
1562 cross-platform substitute for the classic Make utility with integrated
1563 functionality similar to autoconf/automake and compiler caches such as ccache.
1564 In short, SCons is an easier, more reliable and faster way to build
1566 (license license:x11)))
1568 (define-public scons-python2
1570 (inherit (package-with-python2 scons))
1571 (name "scons-python2")))
1573 (define-public python-extras
1575 (name "python-extras")
1580 (uri (pypi-uri "extras" version))
1583 "0khvm08rcwm62wc47j8niyl6h13f8w51c8669ifivjdr23g3cbhk"))))
1584 (build-system python-build-system)
1586 ;; FIXME: Circular dependency on testtools.
1588 (home-page "https://github.com/testing-cabal/extras")
1589 (synopsis "Useful extensions to the Python standard library")
1591 "Extras is a set of extensions to the Python standard library.")
1592 (license license:expat)))
1594 (define-public python2-extras
1595 (package-with-python2 python-extras))
1597 (define-public python-mimeparse
1599 (name "python-mimeparse")
1604 (uri (pypi-uri "python-mimeparse" version))
1607 "0y2g6cl660bpz11srgqyvvm8gmywpgyx8g0xfvbiyr0af0yv1r3n"))))
1608 (build-system python-build-system)
1611 (modify-phases %standard-phases
1614 (invoke "./mimeparse_test.py"))))))
1616 "https://github.com/dbtsai/python-mimeparse")
1617 (synopsis "Python library for parsing MIME types")
1619 "Mimeparse provides basic functions for parsing MIME type names and
1620 matching them against a list of media-ranges.")
1621 (license license:expat)))
1623 (define-public python2-mimeparse
1624 (package-with-python2 python-mimeparse))
1626 (define-public python-miniboa
1628 (name "python-miniboa")
1633 (uri (pypi-uri "miniboa" version))
1636 "09jh3pn4rh7kh7jayanf8jzy6gp03791b5a193w6148cf3i6k9m3"))))
1637 (build-system python-build-system)
1638 (home-page "https://github.com/shmup/miniboa")
1639 (synopsis "Simple, single-threaded Telnet server")
1641 "Miniboa is a simple, asynchronous, single-threaded, poll-based Telnet
1643 (license license:asl2.0)))
1645 (define-public python2-miniboa
1646 (package-with-python2 python-miniboa))
1648 (define-public python-pafy
1650 (name "python-pafy")
1655 (uri (pypi-uri "pafy" version))
1658 "1a7dxi95m1043rxx1r5x3ngb66nwlq6aqcasyqqjzmmmjps4zrim"))))
1659 (build-system python-build-system)
1661 `(#:tests? #f)) ; Currently pafy can not find itself in the tests
1663 ;; Youtube-dl is a python package which is imported in the file
1664 ;; "backend_youtube_dl.py", therefore it needs to be propagated.
1665 `(("youtube-dl" ,youtube-dl)))
1666 (home-page "https://np1.github.io/pafy/")
1667 (synopsis "Retrieve YouTube content and metadata")
1669 "@code{pafy} is a python library to retrieve YouTube content and metadata.")
1670 (license license:lgpl3+)))
1672 (define-public python2-funcsigs
1674 (name "python2-funcsigs")
1678 (uri (pypi-uri "funcsigs" version))
1681 "0l4g5818ffyfmfs1a924811azhjj8ax9xd1cffr1mzd3ycn0zfx7"))))
1682 (build-system python-build-system)
1684 `(#:python ,python-2))
1686 `(("python2-unittest2" ,python2-unittest2)))
1687 (home-page "http://funcsigs.readthedocs.org")
1688 (synopsis "Python function signatures from PEP362")
1690 "Backport of @code{funcsigs} which was introduced in Python 3.3.")
1691 (license license:asl2.0)))
1693 (define-public python2-funcsigs-bootstrap
1695 (inherit python2-funcsigs)
1696 (name "python2-funcsigs-bootstrap")
1700 ,@(package-arguments python2-funcsigs)))))
1702 (define-public python-py
1709 (uri (pypi-uri "py" version))
1712 "0lsy1gajva083pzc7csj1cvbmminb7b4l6a0prdzyb3fd829nqyw"))))
1713 (build-system python-build-system)
1715 ;; FIXME: "ImportError: 'test' module incorrectly imported from
1716 ;; '/gnu/store/...-python-pytest-mimimal-3.0.5/lib/python3.5/site-packages'.
1717 ;; Expected '/tmp/guix-build-python-py-1.4.31.drv-0/py-1.4.31/py'.
1718 ;; Is this module globally installed?"
1721 `(("python-setuptools-scm" ,python-setuptools-scm)))
1722 (home-page "https://github.com/pytest-dev/py")
1723 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1725 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1726 code introspection, and logging.")
1727 (license license:expat)))
1729 (define-public python2-py
1730 (package-with-python2 python-py))
1732 ;; Recent versions of python-fixtures and python-testrepository need
1733 ;; python-pbr for packaging, which itself needs these two packages for
1735 ;; To fix this circular dependency, we use a build of python-pbr, based on the
1736 ;; same source, just without any test dependencies and with tests disabled.
1737 ;; python-pbr-minmal is then used to package python-fixtures and
1738 ;; python-testrepository.
1739 ;; Strictly speaking we currently could remove the test-requirements from the
1740 ;; normal python-pbr package (and save this package) since test are disabled
1741 ;; there anyway. But this may change in future.
1742 (define-public python-pbr-minimal
1744 (name "python-pbr-minimal")
1749 (uri (pypi-uri "pbr" version))
1752 "14fs5acnalnb3h62s7q7av239j541fk0n0z0lawh4h09b1s93s6p"))))
1753 (build-system python-build-system)
1756 (home-page "http://docs.openstack.org/developer/pbr/")
1757 (synopsis "Minimal build of python-pbr used for bootstrapping")
1759 "Used only for bootstrapping python2-pbr, you should not need this.")
1760 (license license:asl2.0)))
1762 (define-public python2-pbr-minimal
1763 (package-with-python2 python-pbr-minimal))
1765 (define-public python-pbr
1767 (inherit python-pbr-minimal)
1770 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1772 `(("git" ,git))) ;; pbr actually uses the "git" binary.
1774 `(("python-fixtures" ,python-fixtures-bootstrap)
1775 ;; discover, coverage, hacking, subunit
1776 ("python-mock" ,python-mock)
1777 ("python-six" ,python-six)
1778 ("python-sphinx" ,python-sphinx)
1779 ("python-testrepository" ,python-testrepository-bootstrap)
1780 ("python-testresources" ,python-testresources-bootstrap)
1781 ("python-testscenarios" ,python-testscenarios-bootstrap)
1782 ("python-testtools" ,python-testtools-bootstrap)
1783 ("python-virtualenv" ,python-virtualenv)))
1784 (synopsis "Enhance the default behavior of Python’s setuptools")
1786 "Python Build Reasonableness (PBR) is a library that injects some useful
1787 and sensible default behaviors into your setuptools run. It will set
1788 versions, process requirements files and generate AUTHORS and ChangeLog file
1789 from git information.
1792 (define-public python2-pbr
1793 (package-with-python2 python-pbr))
1795 (define-public python-pyrsistent
1797 (name "python-pyrsistent")
1799 (home-page "https://github.com/tobgu/pyrsistent")
1802 (uri (pypi-uri "pyrsistent" version))
1805 "1qkh74bm296mp5g3r11lgsksr6bh4w1bf8pji4nmxdlfj542ga1w"))))
1806 (build-system python-build-system)
1808 `(("python-hypothesis" ,python-hypothesis)
1809 ("python-pytest" ,python-pytest)
1810 ("python-pytest-runner" ,python-pytest-runner)))
1812 `(("python-six" ,python-six)))
1813 (synopsis "Persistent data structures for Python")
1815 "Pyrsistent is a number of persistent collections (by some referred to as
1816 functional data structures). Persistent in the sense that they are immutable.
1818 All methods on a data structure that would normally mutate it instead return a
1819 new copy of the structure containing the requested updates. The original
1820 structure is left untouched.")
1821 (license license:expat)))
1823 (define-public python2-pyrsistent
1824 (package-with-python2 python-pyrsistent))
1826 (define-public python-exif-read
1828 (name "python-exif-read")
1832 (uri (pypi-uri "ExifRead" version))
1835 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
1836 (build-system python-build-system)
1837 (arguments `(#:tests? #f)) ; no tests
1838 (home-page "https://github.com/ianare/exif-py")
1839 (synopsis "Python library to extract EXIF data from image files")
1841 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
1843 (license license:bsd-3)))
1845 (define-public python2-exif-read
1846 (package-with-python2 python-exif-read))
1848 (define-public python-pyld
1850 (name "python-pyld")
1854 (uri (pypi-uri "PyLD" version))
1857 "1ywbdbsrkg533qh8xn9ifjh2mvam6v5msrjyqq73jfpvcp89qvff"))))
1858 (build-system python-build-system)
1859 (home-page "https://github.com/digitalbazaar/pyld")
1860 (synopsis "Python implementation of the JSON-LD specification")
1862 "PyLD is an implementation of the JSON-LD specification.")
1863 (license license:bsd-3)))
1865 (define-public python2-pyld
1866 (package-with-python2 python-pyld))
1868 (define-public python-click
1870 (name "python-click")
1875 (uri (pypi-uri "click" version))
1878 "1mzjixd4vjbjvzb6vylki9w1556a9qmdh35kzmq6cign46av952v"))))
1879 (build-system python-build-system)
1882 (modify-phases %standard-phases
1883 (add-after 'unpack 'fix-paths
1884 (lambda* (#:key inputs #:allow-other-keys)
1885 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
1886 "cross-libc" "libc"))))
1887 (substitute* "click/_unicodefun.py"
1889 (string-append "'" glibc "/bin/locale'"))))
1893 (invoke "python" "-m" "pytest"))))))
1895 `(("python-pytest" ,python-pytest)))
1896 (home-page "https://palletsprojects.com/p/click/")
1897 (synopsis "Command line library for Python")
1899 "Click is a Python package for creating command line interfaces in a
1900 composable way with as little code as necessary. Its name stands for
1901 \"Command Line Interface Creation Kit\". It's highly configurable but comes
1902 with sensible defaults out of the box.")
1903 (license license:bsd-3)))
1905 (define-public python2-click
1906 (package-with-python2 python-click))
1908 (define-public python-wheel
1910 (name "python-wheel")
1915 (uri (pypi-uri "wheel" version))
1918 "0ii6f34rvpjg3nmw4bc2h7fhdsy38y1h93hghncfs5akfrldmj8h"))))
1919 (build-system python-build-system)
1921 ;; FIXME: The test suite runs "python setup.py bdist_wheel", which in turn
1922 ;; fails to find the newly-built bdist_wheel library, even though it is
1923 ;; available on PYTHONPATH. What search path is consulted by setup.py?
1925 (home-page "https://bitbucket.org/pypa/wheel/")
1926 (synopsis "Format for built Python packages")
1928 "A wheel is a ZIP-format archive with a specially formatted filename and
1929 the @code{.whl} extension. It is designed to contain all the files for a PEP
1930 376 compatible install in a way that is very close to the on-disk format. Many
1931 packages will be properly installed with only the @code{Unpack} step and the
1932 unpacked archive preserves enough information to @code{Spread} (copy data and
1933 scripts to their final locations) at any later time. Wheel files can be
1934 installed with a newer @code{pip} or with wheel's own command line utility.")
1935 (license license:expat)))
1937 (define-public python2-wheel
1938 (package-with-python2 python-wheel))
1940 (define-public python-vcversioner
1942 (name "python-vcversioner")
1943 (version "2.16.0.0")
1947 (uri (pypi-uri "vcversioner" version))
1950 "16z10sm78jd7ca3jbkgc3q5i8a8q7y1h21q1li21yy3rlhbhrrns"))))
1951 (build-system python-build-system)
1952 (synopsis "Python library for version number discovery")
1953 (description "Vcversioner is a Python library that inspects tagging
1954 information in a variety of version control systems in order to discover
1956 (home-page "https://github.com/habnabit/vcversioner")
1957 (license license:isc)))
1959 (define-public python2-vcversioner
1960 (package-with-python2 python-vcversioner))
1962 (define-public python-jdcal
1964 (name "python-jdcal")
1969 (uri (pypi-uri "jdcal" version))
1972 "1ja6j2xq97bsl6rv09mhdx7n0xnrsfx0mj5xqza0mxghqmkm02pa"))))
1973 (build-system python-build-system)
1975 `(#:phases (modify-phases %standard-phases
1978 (invoke "pytest"))))))
1980 `(("python-pytest" ,python-pytest)))
1981 (home-page "https://github.com/phn/jdcal")
1982 (synopsis "Functions to convert between Julian dates Gregorian dates")
1983 (description "This Python library provides functions for converting
1984 between Julian dates and Gregorian dates.")
1985 (license license:bsd-2)))
1987 (define-public python2-jdcal
1988 (package-with-python2 python-jdcal))
1990 (define-public python-jsonschema
1992 (name "python-jsonschema")
1996 (uri (pypi-uri "jsonschema" version))
1999 "03g20i1xfg4qdlk4475pl4pp7y0h37g1fbgs5qhy678q9xb822hc"))))
2000 (build-system python-build-system)
2003 (modify-phases %standard-phases
2006 (setenv "PYTHONPATH" (string-append ".:" (getenv "PYTHONPATH")))
2007 (invoke "trial" "jsonschema"))))))
2009 `(("python-setuptools_scm" ,python-setuptools-scm)
2010 ("python-twisted" ,python-twisted)))
2012 `(("python-attrs" ,python-attrs)
2013 ("python-pyrsistent" ,python-pyrsistent)
2014 ("python-six" ,python-six)))
2015 (home-page "https://github.com/Julian/jsonschema")
2016 (synopsis "Implementation of JSON Schema for Python")
2018 "Jsonschema is an implementation of JSON Schema for Python.")
2019 (license license:expat)
2020 (properties `((python2-variant . ,(delay python2-jsonschema))))))
2022 (define-public python2-jsonschema
2023 (let ((jsonschema (package-with-python2
2024 (strip-python2-variant python-jsonschema))))
2025 (package (inherit jsonschema)
2027 `(("python2-functools32" ,python2-functools32)
2028 ,@(package-propagated-inputs jsonschema))))))
2030 ;; This old version is still required by docker-compose as of 1.24.0.
2031 (define-public python-jsonschema-2.6
2033 (name "python-jsonschema")
2037 (uri (pypi-uri "jsonschema" version))
2040 "00kf3zmpp9ya4sydffpifn0j0mzm342a2vzh82p6r0vh10cg7xbg"))))
2041 (build-system python-build-system)
2044 (modify-phases %standard-phases
2045 (replace 'check (lambda _ (invoke "nosetests"))))))
2047 `(("python-nose" ,python-nose)
2048 ("python-vcversioner" ,python-vcversioner)))
2049 (home-page "https://github.com/Julian/jsonschema")
2050 (synopsis "Implementation of JSON Schema for Python")
2052 "Jsonschema is an implementation of JSON Schema for Python.")
2053 (license license:expat)
2054 (properties `((python2-variant . ,(delay python2-jsonschema))))))
2056 (define-public python-schema
2058 (name "python-schema")
2063 (uri (pypi-uri "schema" version))
2066 "1lw28j9w9vxyigg7vkfkvi6ic9lgjkdnfvnxdr7pklslqvzmk2vm"))))
2067 (build-system python-build-system)
2069 `(("python-pytest" ,python-pytest)))
2070 (home-page "https://github.com/keleshev/schema")
2071 (synopsis "Simple data validation library")
2073 "@code{python-schema} is a library for validating Python data
2074 structures, such as those obtained from config-files, forms, external
2075 services or command-line parsing, converted from JSON/YAML (or
2076 something else) to Python data-types.")
2077 (license license:psfl)))
2079 (define-public python2-schema
2080 (package-with-python2 python-schema))
2082 (define-public python-schema-0.5
2083 (package (inherit python-schema)
2088 (uri (pypi-uri "schema" version))
2091 "10zqvpaky51kgb8nd42bk7jwl8cn2zvayxjpdc1wwmpybj92x67s"))))))
2093 (define-public python2-schema-0.5
2094 (package-with-python2 python-schema-0.5))
2096 (define-public python-kitchen
2098 (name "python-kitchen")
2103 (uri (pypi-uri "kitchen" version))
2106 "1zakh6l0yjvwic9p0nkvmbidpnkygkxbigh2skmb5gccyrhbp7xg"))))
2107 (build-system python-build-system)
2109 `(("python-chardet" ,python-chardet)))
2110 (home-page "https://github.com/fedora-infra/kitchen")
2111 (synopsis "Python API for snippets")
2112 (description "@code{kitchen} module provides a python API for all sorts of
2113 little useful snippets of code that everybody ends up writing for their projects
2114 but never seem big enough to build an independent release. Use kitchen and stop
2115 cutting and pasting that code over and over.")
2116 (license (list license:lgpl2.1+
2117 ;; subprocess.py, test_subprocess.py,
2118 ;; kitchen/pycompat25/defaultdict.py:
2121 (define-public python2-kitchen
2122 (package-with-python2 python-kitchen))
2124 (define-public python-unidecode
2126 (name "python-unidecode")
2130 (uri (pypi-uri "Unidecode" version))
2133 "1s6cp2lv4m0f00hjckjz8p6m7d3n3v16jvg353llf5ia1iqsnsib"))))
2134 (build-system python-build-system)
2135 (home-page "https://pypi.python.org/pypi/Unidecode")
2136 (synopsis "ASCII transliterations of Unicode text")
2138 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2139 useful when integrating with legacy code that doesn't support Unicode, or for
2140 ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2141 machine identifiers from human-readable Unicode strings that should still be
2142 somewhat intelligible.")
2143 (license license:gpl2+)))
2145 (define-public python2-unidecode
2146 (package-with-python2 python-unidecode))
2148 (define-public python-pyjwt
2150 (name "python-pyjwt")
2155 (uri (pypi-uri "PyJWT" version))
2158 "15hflax5qkw1v6nssk1r0wkj83jgghskcmn875m3wgvpzdvajncd"))
2159 (modules '((guix build utils)))
2162 (for-each delete-file-recursively
2163 (find-files "." "\\.pyc$"))
2165 (build-system python-build-system)
2167 `(("python-pytest" ,python-pytest)
2168 ("python-pytest-cov" ,python-pytest-cov)
2169 ("python-pytest-runner" ,python-pytest-runner)))
2170 (home-page "https://github.com/progrium/pyjwt")
2171 (synopsis "JSON Web Token implementation in Python")
2173 "PyJWT is a JSON Web Token implementation written in Python.")
2174 (license license:expat)))
2176 (define-public python2-pyjwt
2177 (package-with-python2 python-pyjwt))
2179 (define-public python-pykka
2181 (name "python-pykka")
2186 (uri (pypi-uri "Pykka" version))
2189 "049w3r0mdnnw7xv19jiq7rvls9k7xs73x05b4qs5d6z4vvmgyiz8"))))
2190 (build-system python-build-system)
2192 `(("python-mock" ,python-mock)
2193 ("python-nose" ,python-nose)
2194 ("python-gevent" ,python-gevent)
2195 ("python-eventlet" ,python-eventlet)))
2196 (home-page "https://www.pykka.org/")
2197 (synopsis "Pykka is a Python implementation of the actor model")
2199 "Pykka is a Python implementation of the actor model.
2200 The actor model introduces some simple rules to control the sharing
2201 of state and cooperation between execution units, which makes it
2202 easier to build concurrent applications.")
2203 (license license:asl2.0)))
2205 (define-public python2-pykka
2206 (package-with-python2 python-pykka))
2208 (define-public python-pymsgbox
2210 (name "python-pymsgbox")
2216 ;; LICENSE.txt is not present on pypi
2217 (url "https://github.com/asweigart/PyMsgBox")
2218 (commit "55926b55f46caa969c5ddb87990ebea2737bd66f")))
2219 (file-name (git-file-name name version))
2222 "0zy7rjfpwlrd8b64j7jk2lb8m2npc21rnpwakpfvwgl4nxdy80rg"))))
2224 ;; Circular dependency to run tests:
2225 ;; Tests need pyautogui, which depends on pymsgbox.
2227 (build-system python-build-system)
2228 (home-page "https://github.com/asweigart/PyMsgBox")
2229 (synopsis "Python module for JavaScript-like message boxes")
2231 "PyMsgBox is a simple, cross-platform, pure Python module for
2232 JavaScript-like message boxes. Types of dialog boxes include:
2240 (license license:bsd-3)))
2242 (define-public python-pympler
2244 (name "python-pympler")
2245 (home-page "https://pythonhosted.org/Pympler/")
2249 (uri (pypi-uri "Pympler" version))
2252 "0ki7bqp1h9l1xc2k1h4vjyzsgs20i8ingvcdhszyi72s28wyf4bs"))))
2253 (build-system python-build-system)
2255 `(#:phases (modify-phases %standard-phases
2257 (add-after 'install 'check
2258 (lambda* (#:key inputs outputs #:allow-other-keys)
2259 (add-installed-pythonpath inputs outputs)
2260 (invoke "python" "setup.py" "test"))))))
2261 (synopsis "Measure, monitor and analyze memory behavior")
2263 "Pympler is a development tool to measure, monitor and analyze
2264 the memory behavior of Python objects in a running Python application.
2266 By pympling a Python application, detailed insight in the size and the
2267 lifetime of Python objects can be obtained. Undesirable or unexpected
2268 runtime behavior like memory bloat and other @samp{pymples} can easily
2271 A web profiling frontend exposes process statistics, garbage
2272 visualisation and class tracker statistics.")
2273 (license license:asl2.0)))
2275 (define-public python2-pympler
2276 (package-with-python2 python-pympler))
2278 (define-public python-itsdangerous
2280 (name "python-itsdangerous")
2285 (uri (pypi-uri "itsdangerous" version))
2288 "068zpbksq5q2z4dckh2k1zbcq43ay74ylqn77rni797j0wyh66rj"))))
2289 (build-system python-build-system)
2290 (home-page "https://palletsprojects.com/p/itsdangerous/")
2291 (synopsis "Python library for passing data to/from untrusted environments")
2293 "Itsdangerous provides various helpers to pass trusted data to untrusted
2294 environments and back.")
2295 (license license:bsd-3)))
2297 (define-public python2-itsdangerous
2298 (package-with-python2 python-itsdangerous))
2300 (define-public python-pyyaml
2302 (name "python-pyyaml")
2307 (uri (pypi-uri "PyYAML" version))
2310 "1gx603g484z46cb74j9rzr6sjlh2vndxayicvlyhxdz98lhhkwry"))))
2311 (build-system python-build-system)
2313 `(("libyaml" ,libyaml)))
2314 (home-page "http://pyyaml.org/wiki/PyYAML")
2315 (synopsis "YAML parser and emitter for Python")
2317 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2318 complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2319 API, and sensible error messages. PyYAML supports standard YAML tags and
2320 provides Python-specific tags that allow to represent an arbitrary Python
2322 (license license:expat)))
2324 (define-public python2-pyyaml
2325 (package-with-python2 python-pyyaml))
2327 (define-public python-vine
2329 (name "python-vine")
2334 (uri (pypi-uri "vine" version))
2337 "0wkskb2hb494v9gixqnf4bl972p4ibcmxdykzpwjlfa5picns4aj"))))
2338 (build-system python-build-system)
2340 `(("python-pytest" ,python-pytest)
2341 ("python-case" ,python-case)))
2342 (home-page "https://github.com/celery/vine")
2343 (synopsis "Promises for Python")
2345 "@code{vine} provides a special implementation of promises in that it can
2346 be used both for \"promise of a value\" and lazy evaluation. The biggest
2347 upside for this is that everything in a promise can also be a promise,
2348 e.g. filters, callbacks and errbacks can all be promises.")
2349 (license license:bsd-3)))
2351 (define-public python-virtualenv
2353 (name "python-virtualenv")
2358 (uri (pypi-uri "virtualenv" version))
2361 "0242cg3hdq3qdvx5flyrki8lpwlgwf5k45c21ks5049fv7ygm6gq"))))
2362 (build-system python-build-system)
2365 (modify-phases %standard-phases
2366 (add-before 'check 'disable-failing-test
2368 ;; Disable failing test. See upstream bug report
2369 ;; https://github.com/pypa/virtualenv/issues/957
2370 (substitute* "tests/test_virtualenv.py"
2371 (("skipif.*") "skipif(True, reason=\"Guix\")\n"))
2374 `(("python-mock" ,python-mock)
2375 ("python-pytest" ,python-pytest)))
2376 (home-page "https://virtualenv.pypa.io/")
2377 (synopsis "Virtual Python environment builder")
2379 "Virtualenv is a tool to create isolated Python environments.")
2380 (license license:expat)))
2382 (define-public python2-virtualenv
2383 (package-with-python2 python-virtualenv))
2385 (define-public python-markupsafe
2387 (name "python-markupsafe")
2392 (uri (pypi-uri "MarkupSafe" version))
2395 "0sqipg4fk7xbixqd8kq6rlkxj664d157bdwbh93farcphf92x1r9"))))
2396 (build-system python-build-system)
2398 `(#:modules ((ice-9 ftw)
2402 (guix build python-build-system))
2403 #:phases (modify-phases %standard-phases
2406 (let ((cwd (getcwd))
2407 (libdir (find (cut string-prefix? "lib." <>)
2408 (scandir "build"))))
2409 (setenv "PYTHONPATH"
2410 (string-append cwd "/build/" libdir ":"
2411 (getenv "PYTHONPATH")))
2412 (invoke "pytest" "-vv")))))))
2414 `(("python-pytest" ,python-pytest)))
2415 (home-page "https://github.com/mitsuhiko/markupsafe")
2416 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2418 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2420 (license license:bsd-3)))
2422 (define-public python2-markupsafe
2423 (package-with-python2 python-markupsafe))
2425 (define-public python-jinja2
2427 (name "python-jinja2")
2432 (uri (pypi-uri "Jinja2" version))
2435 "04shqrs56aj04ipyqykj512rw2l0zfammvj9krawzxz7xc14yp06"))))
2436 (build-system python-build-system)
2438 `(("python-markupsafe" ,python-markupsafe)))
2439 (home-page "http://jinja.pocoo.org/")
2440 (synopsis "Python template engine")
2442 "Jinja2 is a small but fast and easy to use stand-alone template engine
2443 written in pure Python.")
2444 (license license:bsd-3)))
2446 (define-public python2-jinja2
2447 (package-with-python2 python-jinja2))
2449 (define-public python-jinja2-time
2451 (name "python-jinja2-time")
2456 (uri (pypi-uri "jinja2-time" version))
2459 "0h0dr7cfpjnjj8bgl2vk9063a53649pn37wnlkd8hxjy656slkni"))))
2460 (build-system python-build-system)
2462 `(("python-arrow" ,python-arrow)
2463 ("python-jinja2" ,python-jinja2)))
2465 "https://github.com/hackebrot/jinja2-time")
2466 (synopsis "Jinja2 Extension for Dates and Times")
2468 "This package provides an extension for the template engine Jinja2. It
2469 adds a 'now' tag providing a convenient access to the arrow.now() API from
2470 templates. A format string can be provided to control the output.")
2471 (license license:expat)))
2473 (define-public python-pystache
2475 (name "python-pystache")
2479 (uri (pypi-uri "pystache" version))
2482 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2483 (build-system python-build-system)
2485 '(#:tests? #f)) ; FIXME: Python 3 tests are failing.
2486 (home-page "http://defunkt.io/pystache/")
2487 (synopsis "Python logic-less template engine")
2489 "Pystache is a Python implementation of the framework agnostic,
2490 logic-free templating system Mustache.")
2491 (license license:expat)
2492 (properties `((python2-variant . ,(delay python2-pystache))))))
2494 (define-public python2-pystache
2495 (package (inherit (package-with-python2
2496 (strip-python2-variant python-pystache)))
2498 `(#:python ,python-2
2500 (modify-phases %standard-phases
2503 (invoke "python" "test_pystache.py"))))))))
2505 (define-public python-joblib
2507 (name "python-joblib")
2511 (uri (pypi-uri "joblib" version))
2514 "0612nazad8dxmn3xghfrmjax6456l4xy6hn9cngs7vydi14ds7v5"))))
2515 (build-system python-build-system)
2518 (modify-phases %standard-phases
2520 (lambda _ (invoke "pytest" "-v" "joblib"))))))
2522 `(("python-pytest" ,python-pytest)))
2523 (home-page "https://joblib.readthedocs.io/")
2524 (synopsis "Using Python functions as pipeline jobs")
2526 "Joblib is a set of tools to provide lightweight pipelining in Python.
2527 In particular, joblib offers: transparent disk-caching of the output values
2528 and lazy re-evaluation (memoize pattern), easy simple parallel computing
2529 logging and tracing of the execution.")
2530 (license license:bsd-3)))
2532 (define-public python2-joblib
2533 (package-with-python2 python-joblib))
2535 (define-public python-daemon
2537 (name "python-daemon")
2542 (uri (pypi-uri "python-daemon" version))
2545 "09fcjdjzk9ywmpnrj62iyxqgcygzdafsz41qlrk2dknzbagcmzmg"))))
2546 (build-system python-build-system)
2549 (modify-phases %standard-phases
2550 (add-before 'check 'disable-tests
2552 ;; FIXME: Determine why test fails
2553 (substitute* "test/test_daemon.py"
2554 (("test_detaches_process_context")
2555 "skip_test_detaches_process_context"))
2558 `(("python-lockfile" ,python-lockfile)))
2560 `(("python-unittest2" ,python-unittest2)
2561 ("python-testtools" ,python-testtools)
2562 ("python-testscenarios" ,python-testscenarios)
2563 ("python-mock" ,python-mock)
2564 ("python-docutils" ,python-docutils)))
2565 (home-page "https://pagure.io/python-daemon/")
2566 (synopsis "Python library for making a Unix daemon process")
2567 (description "Python-daemon is a library that assists a Python program to
2568 turn itself into a well-behaved Unix daemon process, as specified in PEP 3143.
2570 This library provides a @code{DaemonContext} class that manages the following
2571 important tasks for becoming a daemon process:
2573 @item Detach the process into its own process group.
2574 @item Set process environment appropriate for running inside a chroot.
2575 @item Renounce suid and sgid privileges.
2576 @item Close all open file descriptors.
2577 @item Change the working directory, uid, gid, and umask.
2578 @item Set appropriate signal handlers.
2579 @item Open new file descriptors for stdin, stdout, and stderr.
2580 @item Manage a specified PID lock file.
2581 @item Register cleanup functions for at-exit processing.
2583 ;; Only setup.py is gpl3+, everything else is apache 2.0 licensed.
2584 (license (list license:asl2.0 license:gpl3+))))
2586 (define-public python-docutils
2588 (name "python-docutils")
2593 (uri (pypi-uri "docutils" version))
2596 "0x22fs3pdmr42kvz6c654756wja305qv6cx1zbhwlagvxgr4xrji"))))
2597 (build-system python-build-system)
2599 '(#:tests? #f)) ; no setup.py test command
2600 (home-page "http://docutils.sourceforge.net/")
2601 (synopsis "Python Documentation Utilities")
2603 "Docutils is a modular system for processing documentation into useful
2604 formats, such as HTML, XML, and LaTeX. For input Docutils supports
2606 ;; Most of the source code is public domain, but some source files are
2607 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2608 (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+))))
2610 (define-public python2-docutils
2611 (package-with-python2 python-docutils))
2613 (define-public python-pygments
2615 (name "python-pygments")
2620 (uri (pypi-uri "Pygments" version))
2623 "15v2sqm5g12bqa0c7wikfh9ck2nl97ayizy1hpqhmws5gqalq748"))))
2624 (build-system python-build-system)
2626 ;; FIXME: Tests require sphinx, which depends on this.
2628 (home-page "http://pygments.org/")
2629 (synopsis "Syntax highlighting")
2631 "Pygments is a syntax highlighting package written in Python.")
2632 (license license:bsd-2)))
2634 (define-public python2-pygments
2635 (package-with-python2 python-pygments))
2637 (define-public python-bumpversion
2639 (name "python-bumpversion")
2644 (uri (pypi-uri "bumpversion" version))
2647 "0zn7694yfipxg35ikkfh7kvgl2fissha3dnqad2c5bvsvmrwhi37"))))
2648 (build-system python-build-system)
2649 (home-page "https://github.com/peritus/bumpversion")
2650 (synopsis "Tool to bump software version")
2651 (description "This tool provides a command-line interface (CLI) to bump a
2652 software version simply.")
2653 (license license:expat)))
2655 (define-public python-deprecated
2657 (name "python-deprecated")
2663 (url "https://github.com/tantale/deprecated.git")
2664 (commit (string-append "v" version))))
2665 (file-name (git-file-name name version))
2668 "14909glxxwwc4b9qpz2b9jdriwzi5n65ichw85xqppap5f79wcwz"))))
2669 (build-system python-build-system)
2671 `(#:phases (modify-phases %standard-phases
2674 (invoke "pytest"))))))
2676 `(("python-wrapt" ,python-wrapt)))
2678 `(("python-bumpversion" ,python-bumpversion)
2679 ("python-pytest" ,python-pytest)
2680 ("python-pytest-cov" ,python-pytest-cov)
2681 ("python-sphinx" ,python-sphinx)
2682 ("python-tox" ,python-tox)))
2683 (home-page "https://github.com/tantale/deprecated")
2684 (synopsis "Python decorator to deprecate classes, functions or methods")
2685 (description "The @code{deprecated} decorator provides a convenient way to deprecate
2686 to deprecate classes, functions or methods.")
2687 (license license:expat)))
2689 (define-public python-pygithub
2691 (name "python-pygithub")
2694 ;; We fetch from the Git repo because there are no tests in the PyPI
2699 (url "https://github.com/PyGithub/PyGithub.git")
2700 (commit (string-append "v" version))))
2701 (file-name (git-file-name name version))
2703 (base32 "1625v558xga5mwhl9jqmibywy5qafmg1vqrirqz6zfq1la1d22mw"))))
2704 (build-system python-build-system)
2706 `(#:phases (modify-phases %standard-phases
2707 ;; Some tests rely on the network.
2708 (add-after 'unpack 'disable-failing-tests
2710 (substitute* "tests/Issue142.py"
2711 (("testDecodeJson") "disabled_testDecodeJson"))
2713 (add-before 'check 'prepare-for-tests
2715 (for-each (lambda (f)
2717 (find-files "./tests"))
2718 (system* "python" "-m" "lib2to3" "-w" "-n" "tests")
2719 (setenv "PYTHONPATH"
2720 (string-append "./tests:" (getenv "PYTHONPATH")))
2723 `(("python-deprecated" ,python-deprecated)
2724 ("python-pyjwt" ,python-pyjwt)
2725 ("python-requests" ,python-requests)))
2726 (native-inputs `(("python-httpretty" ,python-httpretty)))
2727 (home-page "https://pygithub.readthedocs.io/en/latest/")
2728 (synopsis "Python library for the GitHub API")
2729 (description "This library allows managing GitHub resources such as
2730 repositories, user profiles, and organizations in your Python applications,
2731 using version 3 of the GitHub application programming interface (API).")
2732 (license license:lgpl3+)))
2734 (define-public python-rellu
2736 (name "python-rellu")
2741 (uri (pypi-uri "rellu" version))
2744 "1w0arpj1sm7vh29nrbnca4pnp8sx42l07r17inwqcjjf9bhng66x"))))
2745 (build-system python-build-system)
2747 `(("python-invoke" ,python-invoke)
2748 ("python-pygithub" ,python-pygithub)))
2749 (home-page "https://github.com/robotframework/rellu")
2750 (synopsis "Utilities to create PyPI releases")
2751 (description "This collection of utilities contains tooling and templates
2752 to assist in creating releases on GitHub and publishing them on PyPI. It is
2753 designed to be used by Robot Framework and tools and libraries in its
2754 ecosystem, but can naturally be used also by other projects.")
2755 (license license:asl2.0)))
2757 (define-public python-robotframework
2759 (name "python-robotframework")
2761 ;; There are no tests in the PyPI archive.
2766 (url "https://github.com/robotframework/robotframework.git")
2767 (commit (string-append "v" version))))
2768 (file-name (git-file-name name version))
2770 (base32 "16gnxy0qinh8fhs0qvhff5z2xh49c3cqgm0d7bfjw120df6x7fym"))
2771 (patches (search-patches
2772 "python-robotframework-honor-source-date-epoch.patch"))))
2773 (build-system python-build-system)
2775 `(#:phases (modify-phases %standard-phases
2776 (add-before 'build 'build-and-install-doc
2777 (lambda* (#:key outputs #:allow-other-keys)
2778 (let* ((doc-output (assoc-ref outputs "doc"))
2779 (doc (string-append doc-output "/share/"
2780 ,name "-" ,version "/")))
2781 (invoke "invoke" "library-docs" "all")
2783 (copy-recursively "doc/libraries"
2784 (string-append doc "/libraries"))
2788 (invoke "python" "utest/run.py"))))))
2790 `(("python-invoke" ,python-invoke)
2791 ("python-rellu" ,python-rellu)
2792 ("python:tk" ,python "tk"))) ;used when building the HTML doc
2793 (outputs '("out" "doc"))
2794 (home-page "https://robotframework.org")
2795 (synopsis "Generic automation framework")
2796 (description "Robot Framework is a generic automation framework for
2797 acceptance testing, acceptance test driven development (ATDD), and robotic
2798 process automation (RPA).")
2799 (license license:asl2.0)))
2801 (define-public python-robotframework-lint
2802 ;; There is no properly tagged release; the commit below seems to correspond
2803 ;; to the 0.9 stable release available from PyPI. The tests are not
2804 ;; included in the PyPI archive, so we fetch the sources from the upstream
2806 (let ((commit "e851879bab1f63e4e53b34a4dc8a67ed95102830")
2809 (name "python-robotframework-lint")
2810 (version (git-version "0.9.0" revision commit))
2815 (url "https://github.com/boakley/robotframework-lint.git")
2817 (file-name (git-file-name name version))
2820 "1p6fknqg5sb9qz5857ji4a877657vgfjm5v3zn45994parx6ml1m"))))
2821 (build-system python-build-system)
2824 (modify-phases %standard-phases
2827 (invoke "python" "-m" "robot" "-A"
2828 "tests/conf/default.args" "tests"))))))
2830 `(("python-robotframework" ,python-robotframework)))
2831 (home-page "https://github.com/boakley/robotframework-lint/")
2832 (synopsis "Static analysis tool (linter) for Robot Framework")
2833 (description "This package provides the @code{rflint} command-line
2834 utility, a static analysis tool (linter) for Robot Framework source files.")
2835 (license license:asl2.0))))
2837 (define-public python-robotframework-sshlibrary
2839 (name "python-robotframework-sshlibrary")
2841 ;; There are no tests in the PyPI archive.
2846 (url "https://github.com/robotframework/SSHLibrary.git")
2847 (commit (string-append "v" version))))
2848 (file-name (git-file-name name version))
2851 "1mk6dz2jqqndbx4yji09012q6rmadnqdywi7czvj62b0s07dr3r2"))))
2852 (build-system python-build-system)
2855 (modify-phases %standard-phases
2856 (add-before 'build 'build-and-install-doc
2857 (lambda* (#:key outputs #:allow-other-keys)
2858 (let* ((doc-output (assoc-ref outputs "doc"))
2859 (doc (string-append doc-output "/share/"
2860 ,name "-" ,version "/")))
2861 (invoke "chmod" "-R" "+w" "docs")
2862 (invoke "invoke" "kw-docs" "project-docs")
2864 (for-each delete-file (find-files "docs" "\\.rst"))
2865 (copy-recursively "docs" doc)
2869 ;; Some tests require an SSH server; we remove them.
2870 (delete-file "utest/test_client_api.py")
2871 (delete-file "utest/test_scp.py")
2872 (invoke "python" "utest/run.py"))))))
2874 `(("python-robotframework" ,python-robotframework)
2875 ("python-paramiko" ,python-paramiko)
2876 ("python-scp" ,python-scp)))
2878 `(("openssh" ,openssh)
2880 ;; To generate the documentation
2881 ("python-docutils" ,python-docutils)
2882 ("python-invoke" ,python-invoke)
2883 ("python-pygments" ,python-pygments)
2884 ("python-rellu" ,python-rellu)))
2885 (outputs '("out" "doc"))
2886 (home-page "https://github.com/robotframework/SSHLibrary")
2887 (synopsis "Robot Framework library for SSH and SFTP")
2888 (description "SSHLibrary is a Robot Framework library providing support
2889 for SSH and SFTP. It has the following main usages:
2891 @item Executing commands on the remote machine, either blocking or non-blocking.
2892 @item Writing and reading in an interactive shell.
2893 @item Transferring files and directories over SFTP.
2894 @item Ensuring that files and directories exist on the remote machine.
2896 (license license:asl2.0)))
2898 (define-public python-scp
2905 (uri (pypi-uri "scp" version))
2908 "1crlpw9lnn58fs1c1rmh7s7s9y5gkgpgjsqlvg9qa51kq1knx7gg"))))
2909 (build-system python-build-system)
2911 '(#:tests? #f)) ;tests require an SSH server
2913 `(("python-paramiko" ,python-paramiko)))
2914 (home-page "https://github.com/jbardin/scp.py")
2915 (synopsis "SCP protocol module for Python and Paramiko")
2916 (description "The scp module extends the Paramiko library to send and
2917 receive files via the SCP1 protocol, as implemented by the OpenSSH
2918 @command{scp} program.")
2919 (license license:gpl2+)))
2921 (define-public python-rst.linker
2923 (name "python-rst.linker")
2928 (uri (pypi-uri "rst.linker" version))
2930 (base32 "0pqsfqqx8h0pq21k8l3k62kznrgaj2ala93c64s4d9rpbr4mgkd2"))))
2931 (build-system python-build-system)
2933 `(("python-dateutil" ,python-dateutil)
2934 ("python-six" ,python-six)))
2936 `(("python-setuptools-scm" ,python-setuptools-scm)))
2937 ;; Test would require path.py, which would introduce a cyclic dependence.
2938 (arguments `(#:tests? #f))
2939 ;; Note: As of version 1.7 the documentation is not worth building.
2940 (home-page "https://github.com/jaraco/rst.linker")
2941 (synopsis "Sphinx plugin to add links and timestamps")
2942 (description "rst.linker allows to automatically replace text by a
2943 reStructuredText external reference or timestamps. It's primary purpose is to
2944 augment the changelog, but it can be used for other documents, too.")
2945 (license license:expat)))
2947 (define-public python2-rst.linker
2948 (package-with-python2 python-rst.linker))
2950 (define-public python-feedgenerator
2952 (name "python-feedgenerator")
2957 (uri (pypi-uri "feedgenerator" version))
2960 "01mirwkm7xfx539hmvj7g9da1j51gw5lsx74dr0glizskjm5vq2s"))
2961 (modules '((guix build utils)))
2964 ;; Remove pre-compiled .pyc files from source.
2965 (for-each delete-file-recursively
2966 (find-files "." "__pycache__" #:directories? #t))
2967 (for-each delete-file (find-files "." "\\.pyc$"))
2969 (build-system python-build-system)
2971 `(("python-pytz" ,python-pytz)
2972 ("python-six" ,python-six)))
2973 (home-page "https://github.com/getpelican/feedgenerator")
2975 "Standalone version of Django's Atom/RSS feed generator")
2977 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2978 which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
2979 (license license:bsd-3)))
2981 (define-public python2-feedgenerator
2982 (package-with-python2 python-feedgenerator))
2984 (define-public python-toml
2986 (name "python-toml")
2991 (uri (pypi-uri "toml" version))
2994 "0bdbpbip67wdm6c7xwc6mmbmskyradj4cdxn1iibj4fcx1nbv1lf"))))
2995 (build-system python-build-system)
2997 `(#:tests? #f)) ;no tests suite in release
2998 (home-page "https://github.com/uiri/toml")
2999 (synopsis "Library for TOML")
3001 "@code{toml} is a library for parsing and creating Tom's Obvious, Minimal
3002 Language (TOML) configuration files.")
3003 (license license:expat)))
3005 (define-public python-jsonrpc-server
3007 (name "python-jsonrpc-server")
3012 (uri (pypi-uri "python-jsonrpc-server" version))
3015 "0ddgdp26dfxaz6isjbb12974b3rxavgsqrn2zrmck62cmipg5g05"))))
3016 (build-system python-build-system)
3018 `(("python-future" ,python-future)
3019 ("python-mock" ,python-mock)
3020 ("python-pytest" ,python-pytest)
3021 ("python-ujson" ,python-ujson)))
3023 "https://github.com/palantir/python-jsonrpc-server")
3024 (synopsis "JSON RPC 2.0 server library")
3026 "This package provides a JSON RPC 2.0 server library for Python.")
3027 (license license:expat)))
3029 (define-public python-pydocstyle
3031 (name "python-pydocstyle")
3036 (uri (pypi-uri "pydocstyle" version))
3039 "1m1xv9clkg9lgzyza6dnj359z04vh5g0h49nhzghv7lg81gchhap"))))
3040 (build-system python-build-system)
3042 `(("python-six" ,python-six)
3043 ("python-snowballstemmer" ,python-snowballstemmer)))
3045 "https://github.com/PyCQA/pydocstyle/")
3046 (synopsis "Python docstring style checker")
3048 "This package provides a style checker for the Python Language
3050 (license license:expat)))
3052 (define-public python-language-server
3054 (name "python-language-server")
3059 (uri (pypi-uri "python-language-server" version))
3062 "1nrs56jpx7dvghaas0kc5k9lxas5vr3awj3k87p4akki43nsblb8"))))
3063 (build-system python-build-system)
3065 `(("python-pluggy" ,python-pluggy)
3066 ("python-jsonrpc-server" ,python-jsonrpc-server)
3067 ("python-jedi" ,python-jedi)
3068 ("python-yapf" ,python-yapf)
3069 ("python-pyflakes" ,python-pyflakes)
3070 ("python-pydocstyle" ,python-pydocstyle)
3071 ("python-pycodestyle" ,python-pycodestyle)
3072 ("python-mccabe" ,python-mccabe)
3073 ("python-rope" ,python-rope)
3074 ("python-autopep8" ,python-autopep8)
3075 ("python-flake8" ,python-flake8)
3076 ("python-pylint" ,python-pylint)))
3077 (home-page "https://github.com/palantir/python-language-server")
3078 (synopsis "Python implementation of the Language Server Protocol")
3080 "The Python Language Server (pyls) is an implementation of the Python 3
3081 language specification for the Language Server Protocol (LSP). This tool is
3082 used in text editing environments to provide a complete and integrated
3083 feature-set for programming Python effectively.")
3084 (license license:expat)))
3086 (define-public python-black
3088 (name "python-black")
3093 (uri (pypi-uri "black" version))
3096 "0i4sfqgz6w15vd50kbhi7g7rifgqlf8yfr8y78rypd56q64qn592"))))
3097 (build-system python-build-system)
3100 (modify-phases %standard-phases
3101 (add-after 'patch-source-shebangs 'patch-extra-shebangs
3103 (let ((python3 (which "python3")))
3104 (substitute* '("tests/data/fmtonoff.py"
3105 "tests/data/string_prefixes.py"
3106 "tests/data/function.py")
3107 (("#!/usr/bin/env python3(\\.[0-9]+)?" _ minor-version)
3108 (string-append "#!" python3 (if (string? minor-version)
3112 `(("python-click" ,python-click)
3113 ("python-attrs" ,python-attrs)
3114 ("python-appdirs" ,python-appdirs)
3115 ("python-toml" ,python-toml)))
3116 (home-page "https://github.com/ambv/black")
3117 (synopsis "The uncompromising code formatter")
3118 (description "Black is the uncompromising Python code formatter.")
3119 (license license:expat)))
3121 (define-public python-blinker
3123 (name "python-blinker")
3128 (uri (pypi-uri "blinker" version))
3131 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
3132 (build-system python-build-system)
3133 (home-page "http://pythonhosted.org/blinker/")
3134 (synopsis "Fast, simple object-to-object and broadcast signaling")
3136 "Blinker provides a fast dispatching system that allows any number of
3137 interested parties to subscribe to events, or \"signals\".")
3138 (license license:expat)))
3140 (define-public python2-blinker
3141 (package-with-python2 python-blinker))
3143 (define-public pelican
3150 (uri (pypi-uri "pelican" version))
3153 "0mp7hjyhs38ag1hyfcy882g400z0babqi72pnli46dqijfhajzmy"))))
3154 (build-system python-build-system)
3156 `(("python-blinker" ,python-blinker)
3157 ("python-dateutil" ,python-dateutil)
3158 ("python-docutils" ,python-docutils)
3159 ("python-feedgenerator" ,python-feedgenerator)
3160 ("python-jinja2" ,python-jinja2)
3161 ("python-markdown" ,python-markdown)
3162 ("python-pygments" ,python-pygments)
3163 ("python-pytz" ,python-pytz)
3164 ("python-six" ,python-six)
3165 ("python-unidecode" ,python-unidecode)))
3166 (home-page "https://getpelican.com/")
3168 `(;; XXX Requires a lot more packages to do unit tests :P
3170 (synopsis "Python-based static site publishing system")
3172 "Pelican is a tool to generate a static blog from reStructuredText,
3173 Markdown input files, and more. Pelican uses Jinja2 for templating
3174 and is very extensible.")
3175 (license license:agpl3+)))
3177 (define-public mallard-ducktype
3179 (name "mallard-ducktype")
3184 ;; git-reference because tests are not included in pypi source tarball
3185 ;; https://issues.guix.gnu.org/issue/36755#2
3187 (url "https://github.com/projectmallard/mallard-ducktype.git")
3189 (file-name (git-file-name name version))
3192 "1jk9bfz7g04ip78s03b0xak6d54rj4h9zpgadkziy1ji216g6y4c"))))
3193 (build-system python-build-system)
3196 (modify-phases %standard-phases
3199 (with-directory-excursion "tests"
3200 (invoke "sh" "runtests")))))))
3201 (home-page "http://projectmallard.org")
3202 (synopsis "Convert Ducktype to Mallard documentation markup")
3204 "Ducktype is a lightweight syntax that can represent all the semantics
3205 of the Mallard XML documentation system. Ducktype files can be converted to
3206 Mallard using the @command{ducktype} tool. The yelp-tools package
3207 provides additional functionality on the produced Mallard documents.")
3208 (license license:expat)))
3210 (define-public python-cython
3212 (name "python-cython")
3217 (uri (pypi-uri "Cython" version))
3220 "13k37lrcgagwwnzr5bzririsscb793vndj234d475x1h9ad0d7f2"))))
3221 (build-system python-build-system)
3222 ;; we need the full python package and not just the python-wrapper
3223 ;; because we need libpython3.3m.so
3225 `(("python" ,python)))
3228 (modify-phases %standard-phases
3229 (add-before 'check 'set-HOME
3230 ;; some tests require access to "$HOME/.cython"
3231 (lambda _ (setenv "HOME" "/tmp") #t))
3233 ;; FIXME: These tests started failing on armhf after the 0.28 update
3234 ;; (commit c69d11c5930), both with an error such as this:
3235 ;; compiling (cpp) and running dictcomp ...
3236 ;; === C/C++ compiler error output: ===
3238 ;; dictcomp.cpp:5221: confused by earlier errors, bailing out
3239 ;; See <https://hydra.gnu.org/build/2948724> for logs.
3240 ,@(if (target-arm32?)
3241 `((add-before 'check 'disable-failing-tests
3243 (let ((disabled-tests (open-file "tests/bugs.txt" "a")))
3244 (for-each (lambda (test)
3245 (format disabled-tests "~a\n" test))
3246 '("memslice" "dictcomp"))
3247 (close-port disabled-tests)))))
3252 ;; Disable compiler optimizations to greatly reduce the running
3253 ;; time of the test suite.
3254 (setenv "CFLAGS" "-O0")
3256 (invoke "python" "runtests.py" "-vv"
3257 "-j" (number->string (parallel-job-count))))))))
3258 (home-page "https://cython.org/")
3259 (synopsis "C extensions for Python")
3260 (description "Cython is an optimising static compiler for both the Python
3261 programming language and the extended Cython programming language. It makes
3262 writing C extensions for Python as easy as Python itself.")
3263 (license license:asl2.0)
3264 (properties `((python2-variant . ,(delay python2-cython))))))
3266 (define-public python2-cython
3267 (let ((base (package-with-python2 (strip-python2-variant python-cython))))
3270 (name "python2-cython")
3272 `(("python-2" ,python-2))) ;this is not automatically changed
3274 (substitute-keyword-arguments (package-arguments base)
3276 `(modify-phases ,phases
3277 (add-before 'check 'adjust-test_embed
3279 (substitute* "runtests.py"
3280 ;; test_embed goes great lengths to find the static libpythonX.Y.a
3281 ;; so it can give the right -L flag to GCC when embedding static
3282 ;; builds of Python. It is unaware that the Python "config"
3283 ;; directory (where the static library lives) was renamed in
3284 ;; Python 3, and falls back to sysconfig.get_config_var('LIBDIR'),
3285 ;; which works fine, because that is where the shared library is.
3287 ;; It also appears to be unaware that the Makefile in Demos/embed
3288 ;; already unconditionally pass the static library location to GCC,
3289 ;; after checking sysconfig.get_config_var('LIBPL).
3291 ;; The effect is that the linker is unable to resolve libexpat
3292 ;; symbols when building for Python 2, because neither the Python 2
3293 ;; shared library nor Expat is available. To fix it, we can either
3294 ;; add Expat as an input and make it visible to the linker, or just
3295 ;; prevent it from overriding the Python shared library location.
3296 ;; The end result is identical, so we take the easy route.
3297 ((" or libname not in os\\.listdir\\(libdir\\)")
3301 ;; The RPython toolchain currently does not support Python 3.
3302 (define-public python2-rpython
3304 (name "python2-rpython")
3309 (uri (pypi-uri "rpython" version))
3312 "02z9cvxf0y41dcvwnvf2zn0albhhw1drvjjbq27m6i1piw1k6fc0"))))
3313 (build-system python-build-system)
3314 (arguments `(#:python ,python-2))
3316 `(("python2-pytest" ,python2-pytest))) ; needed for running tests
3317 (home-page "https://rpython.readthedocs.org")
3318 (synopsis "Framework for implementing interpreters and virtual machines")
3319 (description "RPython is a translation and support framework for
3320 producing implementations of dynamic languages, emphasizing a clean separation
3321 between language specification and implementation aspects.")
3322 (license license:expat)))
3324 ;; NOTE: when upgrading numpy please make sure that python-pandas and
3325 ;; python-scipy still build, as these three packages are often used together.
3326 (define-public python-numpy
3328 (name "python-numpy")
3334 "https://github.com/numpy/numpy/releases/download/v"
3335 version "/numpy-" version ".tar.gz"))
3338 "1ak9dmjja0q90a7fsxli51ypcwssh8c4pb6f8wkrsnf2xgdk6dy9"))))
3339 (build-system python-build-system)
3341 `(("openblas" ,openblas)
3342 ("lapack" ,lapack)))
3344 `(("python-cython" ,python-cython)
3345 ("python-pytest" ,python-pytest)
3346 ("gfortran" ,gfortran)))
3349 (modify-phases %standard-phases
3350 (add-before 'build 'configure-blas-lapack
3351 (lambda* (#:key inputs #:allow-other-keys)
3352 (call-with-output-file "site.cfg"
3356 libraries = openblas
3357 library_dirs = ~a/lib
3358 include_dirs = ~a/include
3360 # backslash-n to make emacs happy
3362 lapack_libs = lapack
3363 library_dirs = ~a/lib
3364 include_dirs = ~a/include
3366 (assoc-ref inputs "openblas")
3367 (assoc-ref inputs "openblas")
3368 (assoc-ref inputs "lapack")
3369 (assoc-ref inputs "lapack"))))
3371 (add-before 'build 'fix-executable-paths
3372 (lambda* (#:key inputs #:allow-other-keys)
3373 ;; Make /gnu/store/...-bash-.../bin/sh the default shell,
3374 ;; instead of /bin/sh.
3375 (substitute* "numpy/distutils/exec_command.py"
3376 (("(os.environ.get\\('SHELL', ')(/bin/sh'\\))" match match-start match-end)
3377 (string-append match-start (assoc-ref inputs "bash") match-end)))
3378 ;; Use "gcc" executable, not "cc".
3379 (substitute* "numpy/distutils/system_info.py"
3380 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
3381 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3383 ;; Tests can only be run after the library has been installed and not
3384 ;; within the source directory.
3386 (add-after 'install 'check
3387 (lambda* (#:key outputs inputs #:allow-other-keys)
3388 ;; Make installed package available for running the tests
3389 (add-installed-pythonpath inputs outputs)
3390 ;; Make sure "f2py" etc is found.
3391 (setenv "PATH" (string-append (assoc-ref outputs "out") "/bin"
3392 ":" (getenv "PATH")))
3393 (with-directory-excursion "/tmp"
3394 (invoke "python" "-c"
3395 "import numpy; numpy.test(verbose=2)")))))))
3396 (home-page "http://www.numpy.org/")
3397 (synopsis "Fundamental package for scientific computing with Python")
3398 (description "NumPy is the fundamental package for scientific computing
3399 with Python. It contains among other things: a powerful N-dimensional array
3400 object, sophisticated (broadcasting) functions, tools for integrating C/C++
3401 and Fortran code, useful linear algebra, Fourier transform, and random number
3403 (properties `((python2-variant . ,(delay python2-numpy))))
3404 (license license:bsd-3)))
3406 ;; Numpy 1.16.x are the last versions that support Python 2.
3407 (define-public python2-numpy
3408 (let ((numpy (package-with-python2
3409 (strip-python2-variant python-numpy))))
3416 "https://github.com/numpy/numpy/releases/download/v"
3417 version "/numpy-" version ".tar.gz"))
3420 "0lg1cycxzi4rvvrd5zxinpdz0ni792fpx6xjd75z1923zcac8qrb")))))))
3422 ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of
3423 ;; interest only for legacy code going back to NumPy's predecessor
3425 (define-public python2-numpy-1.8
3426 (package (inherit python2-numpy)
3432 (url "https://github.com/numpy/numpy")
3433 (commit (string-append "v" version))))
3434 (file-name (git-file-name "numpy" version))
3437 "0ikgi15rsqwbkfsjjxrwh40lqyal2wvyp3923y6w6ch3dcr82sfk"))))
3439 (substitute-keyword-arguments (package-arguments python2-numpy)
3441 `(modify-phases ,phases
3442 (replace 'configure-blas-lapack
3443 (lambda* (#:key inputs #:allow-other-keys)
3444 (call-with-output-file "site.cfg"
3448 libraries = openblas,lapack
3449 library_dirs = ~a/lib:~a/lib
3450 include_dirs = ~a/include:~a/include
3452 (assoc-ref inputs "openblas")
3453 (assoc-ref inputs "lapack")
3454 (assoc-ref inputs "openblas")
3455 (assoc-ref inputs "lapack"))))
3458 `(("python2-nose" ,python2-nose)))
3459 (description "NumPy is the fundamental package for scientific computing
3460 with Python. It contains among other things: a powerful N-dimensional array
3461 object, sophisticated (broadcasting) functions, tools for integrating C/C++
3462 and Fortran code, useful linear algebra, Fourier transform, and random number
3463 capabilities. Version 1.8 is the last one to contain the numpy.oldnumeric API
3464 that includes the compatibility layer numpy.oldnumeric with NumPy's predecessor
3466 (license license:bsd-3)))
3468 (define-public python-munch
3470 (name "python-munch")
3475 (uri (pypi-uri "munch" version))
3478 "1cmqg91xnqx8gvnh4pmp0bfl1dfcm65d5p9mg73zz8pkjhx6h80l"))))
3479 (build-system python-build-system)
3480 (home-page "https://github.com/Infinidat/munch")
3481 (synopsis "Dot-accessible dictionary")
3482 (description "Munch is a dot-accessible dictionary similar to JavaScript
3484 (license license:expat)))
3486 (define-public python2-munch
3487 (package-with-python2 python-munch))
3489 (define-public python-colormath
3491 (name "python-colormath")
3496 (uri (pypi-uri "colormath" version))
3499 "05qjycgxp3p2f9n6lmic68sxmsyvgnnlyl4z9w7dl9s56jphaiix"))))
3500 (build-system python-build-system)
3502 `(("python-networkx" ,python-networkx)
3503 ("python-numpy" ,python-numpy)))
3504 (home-page "https://github.com/gtaylor/python-colormath")
3505 (synopsis "Color math and conversion library")
3507 "This is a Python library for color math and conversions.")
3508 (license license:bsd-3)))
3510 (define-public python2-colormath
3511 (package-with-python2 python-colormath))
3513 (define-public python-spectra
3515 (name "python-spectra")
3520 (uri (pypi-uri "spectra" version))
3523 "1f322x914bhkg6r5gv1vmnir3iy0k5kih0fd2gp3rdkw32jn5cwf"))))
3524 (build-system python-build-system)
3527 (modify-phases %standard-phases
3529 (lambda _ (invoke "nosetests" "-v"))))))
3531 `(("python-colormath" ,python-colormath)))
3533 `(("python-nose" ,python-nose)))
3534 (home-page "https://github.com/jsvine/spectra")
3535 (synopsis "Color scales and color conversion")
3537 "This package provides a Python library intended to make color math,
3538 color scales, and color space conversion easy. It has support for:
3543 @item Color blending
3544 @item Brightening/darkening colors
3545 @item Saturating/desaturating colors
3546 @item Conversion to/from multiple color spaces.
3548 (license license:expat)))
3550 (define-public python2-spectra
3551 (package-with-python2 python-spectra))
3553 (define-public python-numpy-documentation
3555 (name "python-numpy-documentation")
3556 (version (package-version python-numpy))
3557 (source (package-source python-numpy))
3558 (build-system python-build-system)
3560 `(("python-matplotlib" ,python-matplotlib)
3561 ("python-numpy" ,python-numpy)
3562 ("pkg-config" ,pkg-config)
3563 ("python-sphinx" ,python-sphinx)
3564 ("python-numpydoc" ,python-numpydoc)
3565 ("texlive" ,(texlive-union (list texlive-fonts-cm-super
3567 texlive-generic-ifxetex
3568 texlive-generic-pdftex
3570 texlive-latex-capt-of
3572 texlive-latex-environ
3573 texlive-latex-eqparbox
3574 texlive-latex-etoolbox
3575 texlive-latex-expdlist
3576 texlive-latex-fancyhdr
3577 texlive-latex-fancyvrb
3578 texlive-latex-fncychap
3580 texlive-latex-framed
3581 texlive-latex-geometry
3582 texlive-latex-graphics
3583 texlive-latex-hyperref
3584 texlive-latex-mdwtools
3585 texlive-latex-multirow
3586 texlive-latex-needspace
3587 texlive-latex-oberdiek
3588 texlive-latex-parskip
3589 texlive-latex-preview
3590 texlive-latex-tabulary
3591 texlive-latex-threeparttable
3592 texlive-latex-titlesec
3593 texlive-latex-trimspaces
3595 texlive-latex-upquote
3597 texlive-latex-varwidth
3598 texlive-latex-wrapfig)))
3599 ("texinfo" ,texinfo)
3601 ("scipy-sphinx-theme"
3602 ,(origin ; The build script expects scipy-sphinx-theme as a git submodule
3605 (url "https://github.com/scipy/scipy-sphinx-theme.git")
3606 (commit "c466764e2231ba132c09826b5b138fffa1cfcec3")))
3609 "0q2y87clwlsgc7wvlsn9pzyssybcq10plwhq2w1ydykfsyyqbmkl"))))
3610 ,@(package-native-inputs python-numpy)))
3612 `(#:tests? #f ; we're only generating the documentation
3614 (modify-phases %standard-phases
3617 (lambda* (#:key inputs outputs #:allow-other-keys)
3618 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
3620 data "/doc/" ,name "-"
3621 ,(package-version python-numpy)))
3622 (info-reader (string-append data "/info"))
3623 (html (string-append doc "/html"))
3624 (scipy-sphinx-theme "scipy-sphinx-theme")
3625 (sphinx-theme-checkout (assoc-ref inputs scipy-sphinx-theme))
3626 (pyver ,(string-append "PYVER=")))
3628 ;; FIXME: this is needed to for texlive-union to generate
3629 ;; fonts, which are not found.
3630 (setenv "HOME" "/tmp")
3632 (with-directory-excursion "doc"
3633 (copy-recursively sphinx-theme-checkout scipy-sphinx-theme)
3635 (invoke "make" "html" pyver)
3636 (invoke "make" "latex" "PAPER=a4" pyver)
3637 (invoke "make" "-C" "build/latex"
3638 "all-pdf" "PAPER=a4" pyver)
3639 ;; FIXME: Generation of the info file fails.
3640 ;; (invoke "make" "info" pyver)
3642 ;; (copy-file "build/texinfo/numpy.info"
3643 ;; (string-append info "/numpy.info"))
3644 (for-each (lambda (file)
3645 (copy-file (string-append "build/latex" file)
3646 (string-append doc file)))
3647 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3648 (with-directory-excursion "build/html"
3649 (for-each (lambda (file)
3650 (let* ((dir (dirname file))
3651 (tgt-dir (string-append html "/" dir)))
3652 (unless (equal? "." dir)
3654 (install-file file html)))
3655 (find-files "." ".*")))))
3657 (home-page (package-home-page python-numpy))
3658 (synopsis "Documentation for the python-numpy package")
3659 (description (package-description python-numpy))
3660 (license (package-license python-numpy))))
3662 (define-public python2-numpy-documentation
3663 (let ((numpy-documentation (package-with-python2 python-numpy-documentation)))
3665 (inherit numpy-documentation)
3666 (native-inputs `(("python2-functools32" ,python2-functools32)
3667 ,@(package-native-inputs numpy-documentation))))))
3669 (define-public python-pygit2
3671 (name "python-pygit2")
3676 (uri (pypi-uri "pygit2" version))
3678 (base32 "11kzj5mjkspvplnpdb6bj8dcj6rgmkk986k8hjcklyg5yaxkz32d"))))
3679 (build-system python-build-system)
3681 '(#:tests? #f)) ; tests don't run correctly in our environment
3683 `(("python-six" ,python-six)
3684 ("python-cffi" ,python-cffi)
3685 ("libgit2" ,libgit2)
3686 ("python-tox" ,python-tox)))
3688 `(("python-pytest" ,python-pytest)))
3689 (home-page "https://github.com/libgit2/pygit2")
3690 (synopsis "Python bindings for libgit2")
3691 (description "Pygit2 is a set of Python bindings to the libgit2 shared
3692 library, libgit2 implements Git plumbing.")
3693 ;; GPL2.0 only, with linking exception.
3694 (license license:gpl2)))
3696 (define-public python2-pygit2
3697 (package-with-python2 python-pygit2))
3699 (define-public python-pyparsing
3701 (name "python-pyparsing")
3706 (uri (pypi-uri "pyparsing" version))
3708 (base32 "0yk6xl885b91dmlhlsap7x78hk2rdr879fln9anbq6k4ca42djb6"))))
3709 (build-system python-build-system)
3710 (outputs '("out" "doc"))
3712 `(#:tests? #f ; no test target
3714 (modify-phases %standard-phases
3715 (add-after 'install 'install-doc
3716 (lambda* (#:key outputs #:allow-other-keys)
3717 (let* ((doc (string-append (assoc-ref outputs "doc")
3718 "/share/doc/" ,name "-" ,version))
3719 (html-doc (string-append doc "/html"))
3720 (examples (string-append doc "/examples")))
3726 (install-file file tgt))
3727 (find-files dir ".*")))
3728 (list "docs" "htmldoc" "examples")
3729 (list doc html-doc examples))
3731 (home-page "https://github.com/pyparsing/pyparsing")
3732 (synopsis "Python parsing class library")
3734 "The pyparsing module is an alternative approach to creating and
3735 executing simple grammars, vs. the traditional lex/yacc approach, or the use
3736 of regular expressions. The pyparsing module provides a library of classes
3737 that client code uses to construct the grammar directly in Python code.")
3738 (license license:expat)))
3740 (define-public python2-pyparsing
3741 (package-with-python2 python-pyparsing))
3743 (define-public python-numpydoc
3745 (name "python-numpydoc")
3750 (uri (pypi-uri "numpydoc" version))
3753 "1zazxg3m8j4fksv3f7v7vpf4bj9qb1vj3r326am0vdip141vzx31"))))
3754 (build-system python-build-system)
3756 `(("python-sphinx" ,python-sphinx)))
3758 `(("python-nose" ,python-nose)))
3759 (home-page "https://pypi.python.org/pypi/numpydoc")
3761 "Numpy's Sphinx extensions")
3763 "Sphinx extension to support docstrings in Numpy format.")
3764 (license license:bsd-2)))
3766 (define-public python2-numpydoc
3767 (package-with-python2 python-numpydoc))
3769 (define-public python-numexpr
3771 (name "python-numexpr")
3776 (uri (pypi-uri "numexpr" version))
3779 "1frnbcwmsi312154x274xl28xazr1k8vjby83fwyla2n10a81bgq"))))
3780 (build-system python-build-system)
3781 (arguments `(#:tests? #f)) ; no tests included
3783 `(("python-numpy" ,python-numpy)))
3784 (home-page "https://github.com/pydata/numexpr")
3785 (synopsis "Fast numerical expression evaluator for NumPy")
3787 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3788 expressions that operate on arrays are accelerated and use less memory than
3789 doing the same calculation in Python. In addition, its multi-threaded
3790 capabilities can make use of all your cores, which may accelerate
3791 computations, most specially if they are not memory-bounded (e.g. those using
3792 transcendental functions).")
3793 (license license:expat)))
3795 (define-public python2-numexpr
3796 (package-with-python2 python-numexpr))
3798 (define-public python-cycler
3800 (name "python-cycler")
3804 (uri (pypi-uri "cycler" version))
3807 "1n69n23fak1gjxlrbhqisi2b9pv3ckrfj98llx3p53953082syyd"))))
3808 (build-system python-build-system)
3810 ;; XXX: The current version requires 'coveralls' which we don't have.
3811 ;; Enable this for the next release which uses 'python-pytest'.
3814 `(("python-six" ,python-six)))
3815 (home-page "http://matplotlib.org/cycler/")
3816 (synopsis "Composable keyword argument iterator")
3818 "When using @code{matplotlib} and plotting more than one line, it is
3819 common to want to be able to want to be able to cycle over one or more artist
3820 styles; but the plotting logic can quickly become involved.
3821 To address this and enable easy cycling over arbitrary @code{kwargs}, the
3822 @code{Cycler} class was developed.")
3823 (license license:bsd-3)))
3825 (define-public python2-cycler
3826 (package-with-python2 python-cycler))
3828 (define-public python-colorspacious
3830 (name "python-colorspacious")
3836 (url "https://github.com/njsmith/colorspacious.git")
3837 (commit (string-append "v" version))))
3838 (file-name (git-file-name name version))
3840 (base32 "0x7nkphr6g5ql5fvgss8l56rgiyjgh6fm8zzs73i94ci9wzlm63w"))))
3841 (build-system python-build-system)
3843 `(("python-numpy" ,python-numpy)))
3845 `(("python-nose" ,python-nose)))
3848 (modify-phases %standard-phases
3851 (invoke "nosetests" "--all-modules" "-v" "colorspacious"))))))
3852 (home-page "https://github.com/njsmith/colorspacious")
3853 (synopsis "Python library for colorspace conversions")
3854 (description "@code{colorspacious} is a Python library that lets you
3855 convert between colorspaces like sRGB, XYZ, CIEL*a*b*, CIECAM02, CAM02-UCS, etc.")
3856 (license license:expat)))
3858 (define-public python2-colorspacious
3859 (package-with-python2 python-colorspacious))
3861 (define-public python-matplotlib
3863 (name "python-matplotlib")
3868 (uri (pypi-uri "matplotlib" version))
3871 "1nmshfqh7wyg15i16hx1yiylcvzkws29ivn66n3i0wyqwcpjr3lf"))))
3872 (build-system python-build-system)
3873 (propagated-inputs ; the following packages are all needed at run time
3874 `(("python-cycler" ,python-cycler)
3875 ("python-kiwisolver" ,python-kiwisolver)
3876 ("python-pyparsing" ,python-pyparsing)
3877 ("python-pygobject" ,python-pygobject)
3878 ("gobject-introspection" ,gobject-introspection)
3879 ("python-tkinter" ,python "tk")
3880 ("python-dateutil" ,python-dateutil)
3881 ("python-numpy" ,python-numpy)
3882 ("python-pillow" ,python-pillow)
3883 ("python-pytz" ,python-pytz)
3884 ("python-six" ,python-six)
3885 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3886 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3887 ;; object. For this reason we need to import both libraries.
3888 ;; https://cairocffi.readthedocs.io/en/stable/cffi_api.html#converting-pycairo-wrappers-to-cairocffi
3889 ("python-pycairo" ,python-pycairo)
3890 ("python-cairocffi" ,python-cairocffi)))
3892 `(("libpng" ,libpng)
3893 ("imagemagick" ,imagemagick)
3894 ("freetype" ,freetype)
3897 ;; FIXME: Add backends when available.
3898 ;("python-wxpython" ,python-wxpython)
3902 `(("pkg-config" ,pkg-config)
3903 ("python-pytest" ,python-pytest)
3904 ("python-mock" ,python-mock)
3909 (uri "https://jqueryui.com/resources/download/jquery-ui-1.12.1.zip")
3912 "0kb21xf38diqgxcdi1z3s9ssq36pldvyqxy56hn6pcva6rs3c8zq"))))))
3915 (modify-phases %standard-phases
3916 ;; XXX We disable all image comparison tests because we're using a
3917 ;; newer version of FreeType than matplotlib expects. This leads to
3918 ;; minor differences throughout the tests.
3919 (add-after 'unpack 'fix-and-disable-failing-tests
3921 (substitute* (append (find-files "lib/matplotlib/tests/"
3923 (find-files "lib/mpl_toolkits/tests"
3925 (("^from matplotlib" match)
3926 (string-append "import pytest\n" match))
3927 (("( *)@image_comparison" match indent)
3928 (string-append indent
3929 "@pytest.mark.skip(reason=\"unknown minor image differences\")\n"
3931 (substitute* "lib/matplotlib/tests/test_animation.py"
3932 (("/bin/sh") (which "sh")))
3933 (for-each delete-file
3934 ;; test_normal_axes, test_get_tightbbox_polar
3935 '("lib/matplotlib/tests/test_axes.py"
3936 ;; We don't use the webagg backend and this test forces it.
3937 "lib/matplotlib/tests/test_backend_webagg.py"
3938 ;; test_outward_ticks
3939 "lib/matplotlib/tests/test_tightlayout.py"
3940 ;; test_hidden_axes fails with minor extent
3941 ;; differences, possibly due to the use of a
3942 ;; different version of FreeType.
3943 "lib/matplotlib/tests/test_constrainedlayout.py"
3944 ;; Fontconfig returns no fonts.
3945 "lib/matplotlib/tests/test_font_manager.py"))
3947 (add-before 'install 'install-jquery-ui
3948 (lambda* (#:key outputs inputs #:allow-other-keys)
3949 (let ((dir (string-append (assoc-ref outputs "out")
3950 "/lib/python3.7/site-packages/matplotlib/backends/web_backend/")))
3953 (assoc-ref inputs "jquery-ui")
3957 (lambda* (#:key outputs inputs #:allow-other-keys)
3958 (add-installed-pythonpath inputs outputs)
3959 (invoke "python" "tests.py" "-v"
3960 "-m" "not network and not webagg")))
3961 (add-before 'build 'configure-environment
3962 (lambda* (#:key outputs inputs #:allow-other-keys)
3963 (let ((cairo (assoc-ref inputs "cairo")))
3964 ;; Setting this directory in the 'basedirlist' of 'setup.cfg'
3966 (setenv "LD_LIBRARY_PATH" (string-append cairo "/lib"))
3967 (setenv "HOME" (getcwd))
3968 (call-with-output-file "setup.cfg"
3970 (format port "[directories]~%
3971 basedirlist = ~a,~a~%
3974 (assoc-ref inputs "tcl")
3975 (assoc-ref inputs "tk")))))
3977 (home-page "https://matplotlib.org/")
3978 (synopsis "2D plotting library for Python")
3980 "Matplotlib is a Python 2D plotting library which produces publication
3981 quality figures in a variety of hardcopy formats and interactive environments
3982 across platforms. Matplotlib can be used in Python scripts, the python and
3983 ipython shell, web application servers, and six graphical user interface
3985 (license license:psfl)
3986 (properties `((python2-variant . ,(delay python2-matplotlib))))))
3988 (define-public python2-matplotlib
3989 (let ((matplotlib (package-with-python2
3990 (strip-python2-variant python-matplotlib))))
3991 (package (inherit matplotlib)
3996 (uri (pypi-uri "matplotlib" version))
3999 "09i1gnrra1590brc1f8d5rh2zvnknmfgzp613ab0462qkrwj15h2"))))
4001 (substitute-keyword-arguments (package-arguments matplotlib)
4003 `(modify-phases ,phases
4004 (replace 'install-jquery-ui
4005 (lambda* (#:key outputs inputs #:allow-other-keys)
4006 (let ((dir (string-append (assoc-ref outputs "out")
4007 "/lib/python2.7/site-packages/"
4008 "matplotlib/backends/web_backend/")))
4011 (assoc-ref inputs "jquery-ui")
4014 (delete 'fix-and-disable-failing-tests)
4015 (delete 'check))))) ; These tests weren't run the the past.
4016 ;; Make sure to use special packages for Python 2 instead
4017 ;; of those automatically rewritten by package-with-python2.
4019 `(("python2-pycairo" ,python2-pycairo)
4020 ("python2-backports-functools-lru-cache"
4021 ,python2-backports-functools-lru-cache)
4022 ("python2-functools32" ,python2-functools32)
4023 ("python2-pygobject-2" ,python2-pygobject-2)
4024 ("python2-subprocess32" ,python2-subprocess32)
4025 ("python2-tkinter" ,python-2 "tk")
4026 ,@(fold alist-delete (package-propagated-inputs matplotlib)
4027 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
4029 (define-public python-matplotlib-documentation
4031 (name "python-matplotlib-documentation")
4032 (version (package-version python-matplotlib))
4033 (source (package-source python-matplotlib))
4034 (build-system python-build-system)
4036 `(("python-matplotlib" ,python-matplotlib)
4037 ("python-colorspacious" ,python-colorspacious)
4038 ("python-sphinx" ,python-sphinx)
4039 ("python-sphinx-copybutton" ,python-sphinx-copybutton)
4040 ("python-sphinx-gallery" ,python-sphinx-gallery)
4041 ("python-numpydoc" ,python-numpydoc)
4042 ("python-ipython" ,python-ipython)
4043 ("python-ipykernel" ,python-ipykernel)
4044 ("python-mock" ,python-mock)
4045 ("graphviz" ,graphviz)
4046 ("texlive" ,(texlive-union (list texlive-amsfonts
4047 texlive-latex-amsmath
4048 texlive-latex-enumitem
4049 texlive-latex-expdlist
4050 texlive-latex-geometry
4051 texlive-latex-preview
4052 texlive-latex-type1cm
4055 texlive-generic-pdftex
4058 texlive-fonts-adobe-times
4059 texlive-fonts-txfonts)))
4060 ("texinfo" ,texinfo)
4061 ,@(package-native-inputs python-matplotlib)))
4063 `(#:tests? #f ; we're only generating documentation
4065 (modify-phases %standard-phases
4066 ;; The tests in python-matplotlib are run after the install phase, so
4067 ;; we need to delete the extra phase here.
4072 (setenv "PYTHONPATH"
4073 (string-append (getenv "PYTHONPATH")
4074 ":" (getcwd) "/../examples/units"))
4075 (substitute* "conf.py"
4077 (("^SHA = check_output.*")
4078 (string-append "SHA = \"" ,version "\"\n"))
4079 ;; Don't fetch intersphinx files from the Internet
4080 (("^explicit_order_folders" m)
4081 (string-append "intersphinx_mapping = {}\n" m))
4082 (("'sphinx.ext.intersphinx',") "")
4083 ;; Disable URL embedding which requires internet access.
4084 (("'https://docs.scipy.org/doc/numpy'") "None")
4085 (("'https://docs.scipy.org/doc/scipy/reference'") "None"))
4087 "SPHINXBUILD=sphinx-build"
4088 "SPHINXOPTS=" ; don't abort on warnings
4091 (lambda* (#:key inputs outputs #:allow-other-keys)
4092 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
4093 (doc (string-append data "/doc/python-matplotlib-" ,version))
4094 (info (string-append data "/info"))
4095 (html (string-append doc "/html")))
4098 (copy-recursively "build/html" html)
4099 (symlink (string-append html "/_images")
4100 (string-append info "/matplotlib-figures"))
4101 (with-directory-excursion "build/texinfo"
4102 (substitute* "matplotlib.texi"
4103 (("@image\\{([^,]*)" all file)
4104 (string-append "@image{matplotlib-figures/" file)))
4105 (symlink (string-append html "/_images")
4106 "./matplotlib-figures")
4107 (invoke "makeinfo" "--no-split"
4108 "-o" "matplotlib.info" "matplotlib.texi"))
4109 (install-file "build/texinfo/matplotlib.info" info))
4111 (home-page (package-home-page python-matplotlib))
4112 (synopsis "Documentation for the python-matplotlib package")
4113 (description (package-description python-matplotlib))
4114 (license (package-license python-matplotlib))))
4116 (define-public python2-matplotlib-documentation
4117 (let ((parent (package-with-python2 python-matplotlib-documentation)))
4121 (alist-delete "python-sphinx-copybutton"
4122 (package-native-inputs parent))))))
4124 (define-public python-matplotlib-venn
4126 (name "python-matplotlib-venn")
4131 (uri (pypi-uri "matplotlib-venn" version ".zip"))
4134 "13w3i1wih0mij08hrgppzg0g9z50y54rc28l6gdi1r5w45l7l0dy"))))
4135 (build-system python-build-system)
4136 (arguments '(#:tests? #f)) ; tests are not included
4138 `(("python-matplotlib" ,python-matplotlib)
4139 ("python-numpy" ,python-numpy)
4140 ("python-scipy" ,python-scipy)))
4142 `(("unzip" ,unzip)))
4143 (home-page "https://github.com/konstantint/matplotlib-venn")
4144 (synopsis "Plot area-proportional Venn diagrams")
4146 "This package provides tools for plotting area-proportional two- and
4147 three-way Venn diagrams in @code{matplotlib}.")
4148 (license license:expat)))
4150 (define-public python2-pysnptools
4152 (name "python2-pysnptools")
4157 (uri (pypi-uri "pysnptools" version))
4160 "0lnis5xsl7bi0hz4f7gbicahzi5zlxkc21nk3g374xv8fb5hb3qm"))))
4161 (build-system python-build-system)
4163 `(#:python ,python-2 ; only Python 2.7 is supported
4164 #:tests? #f)) ; test files (e.g. examples/toydata.bim) not included
4166 `(("python2-numpy" ,python2-numpy)
4167 ("python2-scipy" ,python2-scipy)
4168 ("python2-pandas" ,python2-pandas)))
4170 `(("python2-cython" ,python2-cython)))
4171 (home-page "http://microsoftgenomics.github.io/PySnpTools/")
4172 (synopsis "Library for reading and manipulating genetic data")
4174 "PySnpTools is a library for reading and manipulating genetic data. It
4175 can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
4176 those files. It can also efficiently manipulate ranges of integers using set
4177 operators such as union, intersection, and difference.")
4178 (license license:asl2.0)))
4180 (define-public python-socksipy-branch
4182 (name "python-socksipy-branch")
4187 (uri (pypi-uri "SocksiPy-branch" version))
4190 "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p"))))
4191 (build-system python-build-system)
4193 `(#:tests? #f)) ; There are no tests
4194 (home-page "https://code.google.com/archive/p/socksipy-branch/")
4195 (synopsis "Python SOCKS module")
4197 "SocksiPy - A Python SOCKS client module. It provides a
4198 socket-like interface that supports connections to any TCP
4199 service through the use of a SOCKS4, SOCKS5 or HTTP proxy.
4200 The original version was developed by Dan Haim, this is a
4201 branch created by Mario Vilas to address some open issues,
4202 as the original project seems to have been abandoned circa 2007.")
4203 (license license:bsd-3)))
4205 (define-public python2-socksipy-branch
4206 (package-with-python2 python-socksipy-branch))
4208 (define-public python-socksipychain
4210 (name "python-socksipychain")
4216 (url "https://github.com/pagekite/PySocksipyChain.git")
4217 (commit (string-append "v" version))))
4218 (file-name (git-file-name name version))
4221 "0idm9a050rd2kbgbz2sk9ib9589kj4xh1xdnggs6xbq2v2y8f6zn"))))
4222 (build-system python-build-system)
4224 `(#:tests? #f)) ; Tests try to access the network.
4225 (home-page "http://pagekite.net/wiki/Floss/PySocksipyChain/")
4226 (synopsis "Python SOCKS module with chained proxies support")
4228 "SocksiPyChain is a modified version of the SocksiPy SOCKS module, which
4229 adds support for arbitrary chaining of proxy servers and various modes of
4230 TLS/SSL encryption. It was developed for use in PageKite, and also includes
4231 a simple netcat replacement with chaining support.")
4232 (license license:bsd-3)))
4234 (define-public python-pycodestyle
4236 (name "python-pycodestyle")
4241 (uri (pypi-uri "pycodestyle" version))
4244 "0v4prb05n21bm8650v0a01k1nyqjdmkrsm3zycfxh2j5k9n962p4"))))
4245 (build-system python-build-system)
4246 (home-page "https://pycodestyle.readthedocs.io/")
4247 (synopsis "Python style guide checker")
4248 (description "@code{pycodestyle} (formerly pep8) is a tool to check
4249 Python code against some of the style conventions in
4250 @url{http://www.python.org/dev/peps/pep-0008/,PEP 8}.")
4251 (license license:expat)))
4253 (define-public python2-pycodestyle
4254 (package-with-python2 python-pycodestyle))
4256 (define-public python-multidict
4258 (name "python-multidict")
4263 (uri (pypi-uri "multidict" version))
4266 "1vf5bq8hn5a9rvhr5v4fwbmarfsp35hhr8gs74kqfijy34j2f194"))))
4267 (build-system python-build-system)
4269 `(("python-pytest" ,python-pytest)
4270 ("python-pytest-runner" ,python-pytest-runner)))
4271 (home-page "https://github.com/aio-libs/multidict/")
4272 (synopsis "Multidict implementation")
4273 (description "Multidict is dict-like collection of key-value pairs
4274 where key might be occurred more than once in the container.")
4275 (license license:asl2.0)))
4277 (define-public python-orderedmultidict
4279 (name "python-orderedmultidict")
4284 (uri (pypi-uri "orderedmultidict" version))
4287 "0dls862ibm7qbq4fnvwx0xn1v9hwyzywbff8xjjdr42dd75208yw"))))
4288 (build-system python-build-system)
4291 (modify-phases %standard-phases
4292 (add-after 'unpack 'fix-tests
4294 ;; The package uses nosetest for running the tests.
4295 ;; Adding this initfile allows to run the test suite
4296 ;; without requiring nosetest.
4297 (with-output-to-file "tests/__init__.py" newline)
4300 `(("python-six" ,python-six)))
4302 `(("python-pycodestyle" ,python-pycodestyle)))
4303 (home-page "https://github.com/gruns/orderedmultidict")
4304 (synopsis "Python Ordered Multivalue Dictionary - omdict")
4305 (description "This package contains a library for ordered multivalue
4306 dictionaries. A multivalue dictionary is a dictionary that can store
4307 multiple values for the same key. An ordered multivalue dictionary is a
4308 multivalue dictionary that retains the order of insertions and deletions.")
4309 (license license:unlicense)))
4311 (define-public python2-orderedmultidict
4312 (package-with-python2 python-orderedmultidict))
4314 (define-public python-autopep8
4316 (name "python-autopep8")
4321 (uri (pypi-uri "autopep8" version))
4324 "192bvhzi4d0claqxgzymvv7k3qnj627742bc8sgxpzjj42pd9112"))))
4325 (build-system python-build-system)
4327 `(("python-pycodestyle" ,python-pycodestyle)))
4328 (home-page "https://github.com/hhatto/autopep8")
4329 (synopsis "Format Python code according to the PEP 8 style guide")
4331 "@code{autopep8} automatically formats Python code to conform to
4332 the PEP 8 style guide. It uses the pycodestyle utility to determine
4333 what parts of the code needs to be formatted. @code{autopep8} is
4334 capable of fixing most of the formatting issues that can be reported
4336 (license (license:non-copyleft
4337 "https://github.com/hhatto/autopep8/blob/master/LICENSE"))))
4339 (define-public python2-autopep8
4340 (package-with-python2 python-autopep8))
4342 (define-public python-distutils-extra
4344 (name "python-distutils-extra")
4349 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
4350 version "/+download/python-distutils-extra-"
4354 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
4355 (build-system python-build-system)
4356 (home-page "https://launchpad.net/python-distutils-extra/")
4357 (synopsis "Enhancements to Python's distutils")
4359 "The python-distutils-extra module enables you to easily integrate
4360 gettext support, themed icons, and scrollkeeper-based documentation into
4361 Python's distutils.")
4362 (license license:gpl2)))
4364 (define-public python2-distutils-extra
4365 (package-with-python2 python-distutils-extra))
4367 (define-public python2-elib.intl
4369 (name "python2-elib.intl")
4373 ;; This project doesn't tag releases or publish tarballs, so we take
4374 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
4377 (url "https://github.com/dieterv/elib.intl.git")
4378 (commit "d09997cfef")))
4379 (file-name (string-append name "-" version "-checkout"))
4382 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
4383 (build-system python-build-system)
4385 ;; incompatible with Python 3 (exception syntax)
4386 `(#:python ,python-2
4388 (home-page "https://github.com/dieterv/elib.intl")
4389 (synopsis "Enhanced internationalization for Python")
4391 "The elib.intl module provides enhanced internationalization (I18N)
4392 services for your Python modules and applications.")
4393 (license license:lgpl3+)))
4395 (define-public python-olefile
4397 (name "python-olefile")
4402 (uri (string-append "https://github.com/decalage2/olefile/releases/"
4403 "download/v" version "/olefile-" version ".tar.gz"))
4404 (file-name (string-append name "-" version ".tar.gz"))
4407 "1kjxh4gr651hpqkjfv89cfzr40hyvf3vjlda7mifiail83j7j07m"))))
4408 (build-system python-build-system)
4409 (home-page "https://www.decalage.info/python/olefileio")
4410 (synopsis "Read and write Microsoft OLE2 files.")
4412 "@code{olefile} can parse, read and write Microsoft OLE2 files (Structured
4413 Storage or Compound Document, Microsoft Office). It is an improved version of
4414 the OleFileIO module from PIL, the Python Image Library.")
4415 (license license:bsd-3)))
4417 (define-public python2-olefile
4418 (package-with-python2 python-olefile))
4420 (define-public python-pillow
4422 (name "python-pillow")
4427 (uri (pypi-uri "Pillow" version))
4430 "1c8wkzc58f5wdh006jvmwdk3wxld1xgagcbdvj7iv17qi0m9fkmz"))))
4431 (build-system python-build-system)
4433 `(("python-pytest" ,python-pytest)))
4435 `(("freetype" ,freetype)
4437 ("libjpeg" ,libjpeg)
4438 ("libtiff" ,libtiff)
4439 ("libwebp" ,libwebp)
4440 ("openjpeg" ,openjpeg)
4443 `(("python-olefile" ,python-olefile)))
4446 (modify-phases %standard-phases
4447 (add-after 'unpack 'patch-ldconfig
4449 (substitute* "setup.py"
4450 (("\\['/sbin/ldconfig', '-p'\\]") "['true']"))))
4452 (lambda* (#:key outputs inputs tests? #:allow-other-keys)
4455 (setenv "HOME" (getcwd))
4456 ;; Make installed package available for running the tests.
4457 (add-installed-pythonpath inputs outputs)
4458 (invoke "python" "selftest.py" "--installed")
4459 (invoke "python" "-m" "pytest" "-vv"))
4461 (home-page "https://python-pillow.org")
4462 (synopsis "Fork of the Python Imaging Library")
4464 "The Python Imaging Library adds image processing capabilities to your
4465 Python interpreter. This library provides extensive file format support, an
4466 efficient internal representation, and fairly powerful image processing
4467 capabilities. The core image library is designed for fast access to data
4468 stored in a few basic pixel formats. It should provide a solid foundation for
4469 a general image processing tool.")
4470 (license (license:x11-style
4471 "http://www.pythonware.com/products/pil/license.htm"
4472 "The PIL Software License"))))
4474 (define-public python2-pillow
4475 (package-with-python2 python-pillow))
4477 (define-public python-pycparser
4479 (name "python-pycparser")
4484 (uri (pypi-uri "pycparser" version))
4487 "1cr5dcj9628lkz1qlwq3fv97c25363qppkmcayqvd05dpy573259"))))
4488 (outputs '("out" "doc"))
4489 (build-system python-build-system)
4491 `(("pkg-config" ,pkg-config)))
4494 (modify-phases %standard-phases
4497 (with-directory-excursion "tests"
4498 (invoke "python" "all_tests.py"))
4500 (add-after 'install 'install-doc
4501 (lambda* (#:key outputs #:allow-other-keys)
4502 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4503 (doc (string-append data "/doc/" ,name "-" ,version))
4504 (examples (string-append doc "/examples")))
4506 (for-each (lambda (file)
4507 (copy-file (string-append "." file)
4508 (string-append doc file)))
4509 '("/README.rst" "/CHANGES" "/LICENSE"))
4510 (copy-recursively "examples" examples)
4512 (home-page "https://github.com/eliben/pycparser")
4513 (synopsis "C parser in Python")
4515 "Pycparser is a complete parser of the C language, written in pure Python
4516 using the PLY parsing library. It parses C code into an AST and can serve as
4517 a front-end for C compilers or analysis tools.")
4518 (license license:bsd-3)))
4520 (define-public python2-pycparser
4521 (package-with-python2 python-pycparser))
4523 (define-public python-pywavelets
4525 (name "python-pywavelets")
4527 (home-page "https://github.com/PyWavelets/pywt")
4530 (uri (pypi-uri "PyWavelets" version))
4533 "1p3qv2v66ghnqrb1f98wyyhp9dz71jwcd6kfpsax65sfdpiyqp1w"))))
4534 (build-system python-build-system)
4536 '(#:modules ((ice-9 ftw)
4540 (guix build python-build-system))
4541 #:phases (modify-phases %standard-phases
4544 (let ((cwd (getcwd))
4545 (libdir (find (cut string-prefix? "lib." <>)
4546 (scandir "build"))))
4547 (with-directory-excursion (string-append cwd "/build/" libdir)
4548 (invoke "nosetests" "-v" "."))))))))
4550 `(("python-matplotlib" ,python-matplotlib) ;for tests
4551 ("python-nose" ,python-nose)))
4553 `(("python-numpy" ,python-numpy)))
4554 (synopsis "Wavelet transforms in Python")
4556 "PyWavelets is a library for wavelet transforms in Python. Wavelets are
4557 mathematical basis functions that are localized in both time and frequency.
4558 Wavelet transforms are time-frequency transforms employing wavelets. They are
4559 similar to Fourier transforms, the difference being that Fourier transforms are
4560 localized only in frequency instead of in time and frequency.")
4561 (license license:expat)))
4563 (define-public python2-pywavelets
4564 (package-with-python2 python-pywavelets))
4566 (define-public python-xcffib
4568 (name "python-xcffib")
4573 (uri (pypi-uri "xcffib" version))
4576 "04k91yxyb3pgc5lvxmivh8w71yjrap2g57yk3s73x4rm4nvjq51n"))))
4577 (build-system python-build-system)
4579 `(("libxcb" ,libxcb)))
4581 `(("python-cffi" ,python-cffi) ; used at run time
4582 ("python-six" ,python-six)))
4584 `(;; FIXME: Tests need more work. See ".travis.yml" in the repository.
4587 (modify-phases %standard-phases
4588 (add-after 'unpack 'fix-libxcb-path
4589 (lambda* (#:key inputs #:allow-other-keys)
4590 (let ((libxcb (assoc-ref inputs "libxcb")))
4591 (substitute* '("xcffib/__init__.py")
4592 (("^soname = \"") (string-append "soname = \"" libxcb "/lib/")))
4594 (add-after 'install 'install-doc
4595 (lambda* (#:key outputs #:allow-other-keys)
4596 (let ((doc (string-append (assoc-ref outputs "out") "/share"
4597 "/doc/" ,name "-" ,version)))
4599 (copy-file "README.md"
4600 (string-append doc "/README.md"))
4602 (home-page "https://github.com/tych0/xcffib")
4603 (synopsis "XCB Python bindings")
4605 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
4606 support for Python 3 and PyPy. It is based on cffi.")
4607 (license license:expat)))
4609 (define-public python2-xcffib
4610 (package-with-python2 python-xcffib))
4612 (define-public python-cairocffi
4614 (name "python-cairocffi")
4619 (uri (pypi-uri "cairocffi" version))
4622 "0dq3k4zhqd8cwsf3nyjqvjqm8wkvrjn1wjf44rl3v0h8kqx6qf0m"))
4623 (patches (search-patches "python-cairocffi-dlopen-path.patch"))))
4624 (build-system python-build-system)
4625 (outputs '("out" "doc"))
4629 ("gdk-pixbuf" ,gdk-pixbuf)
4633 `(("pkg-config" ,pkg-config)
4634 ("python-pytest" ,python-pytest)
4635 ("python-pytest-cov" ,python-pytest-cov)
4636 ("python-pytest-runner" ,python-pytest-runner)
4637 ("python-sphinx" ,python-sphinx)
4638 ("python-docutils" ,python-docutils)))
4640 `(("python-xcffib" ,python-xcffib))) ; used at run time
4643 (modify-phases %standard-phases
4644 (add-after 'unpack 'patch-paths
4645 (lambda* (#:key inputs outputs #:allow-other-keys)
4646 (substitute* (find-files "." "\\.py$")
4647 (("dlopen\\(ffi, 'cairo'")
4648 (string-append "dlopen(ffi, '" (assoc-ref inputs "cairo")
4649 "/lib/libcairo.so.2'"))
4650 (("dlopen\\(ffi, 'gdk-3'")
4651 (string-append "dlopen(ffi, '" (assoc-ref inputs "gtk+")
4652 "/lib/libgtk-3.so.0'"))
4653 (("dlopen\\(ffi, 'gdk_pixbuf-2.0'")
4654 (string-append "dlopen(ffi, '" (assoc-ref inputs "gdk-pixbuf")
4655 "/lib/libgdk_pixbuf-2.0.so.0'"))
4656 (("dlopen\\(ffi, 'glib-2.0'")
4657 (string-append "dlopen(ffi, '" (assoc-ref inputs "glib")
4658 "/lib/libglib-2.0.so.0'"))
4659 (("dlopen\\(ffi, 'gobject-2.0'")
4660 (string-append "dlopen(ffi, '" (assoc-ref inputs "glib")
4661 "/lib/libgobject-2.0.so.0'"))
4662 (("dlopen\\(ffi, 'pangocairo-1.0'")
4663 (string-append "dlopen(ffi, '" (assoc-ref inputs "pango")
4664 "/lib/libpangocairo-1.0.so.0'"))
4665 (("dlopen\\(ffi, 'pango-1.0'")
4666 (string-append "dlopen(ffi, '" (assoc-ref inputs "pango")
4667 "/lib/libpango-1.0.so.0'")))
4669 (add-after 'install 'install-doc
4670 (lambda* (#:key inputs outputs #:allow-other-keys)
4671 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4672 (doc (string-append data "/doc/" ,name "-" ,version))
4673 (html (string-append doc "/html")))
4674 (setenv "LD_LIBRARY_PATH"
4675 (string-append (assoc-ref inputs "cairo") "/lib" ":"
4676 (assoc-ref inputs "gdk-pixbuf") "/lib"))
4677 (setenv "LANG" "en_US.UTF-8")
4679 (for-each (lambda (file)
4680 (copy-file (string-append "." file)
4681 (string-append doc file)))
4682 '("/README.rst" "/CHANGES" "/LICENSE"))
4683 (system* "python" "setup.py" "build_sphinx")
4684 (copy-recursively "docs/_build/html" html)
4686 (home-page "https://github.com/Kozea/cairocffi")
4687 (synopsis "Python bindings and object-oriented API for Cairo")
4689 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
4690 Python bindings and object-oriented API for cairo. Cairo is a 2D vector
4691 graphics library with support for multiple backends including image buffers,
4692 PNG, PostScript, PDF, and SVG file output.")
4693 (license license:bsd-3)))
4695 (define-public python2-cairocffi
4696 (package-with-python2 python-cairocffi))
4698 (define-public python-decorator
4700 (name "python-decorator")
4705 (uri (pypi-uri "decorator" version))
4707 (base32 "0308djallnh00v112y5b7nadl657ysmkp6vc8xn51d6yzc9zm7n3"))))
4708 (build-system python-build-system)
4709 (home-page "https://pypi.python.org/pypi/decorator/")
4710 (synopsis "Python module to simplify usage of decorators")
4712 "The aim of the decorator module is to simplify the usage of decorators
4713 for the average programmer, and to popularize decorators usage giving examples
4714 of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
4715 etc. The core of this module is a decorator factory.")
4716 (license license:expat)))
4718 (define-public python2-decorator
4719 (package-with-python2 python-decorator))
4721 (define-public python-drmaa
4723 (name "python-drmaa")
4728 (uri (pypi-uri "drmaa" version))
4730 (base32 "0xzqriqyvk5b8hszbavsyxd29wm3sxirm8zvvdm73rs2iq7w4hkx"))))
4731 (build-system python-build-system)
4732 ;; The test suite requires libdrmaa which is provided by the cluster
4733 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
4734 ;; should be set to the path of the libdrmaa library.
4735 (arguments '(#:tests? #f))
4737 `(("python-nose" ,python-nose)))
4738 (home-page "https://pypi.python.org/pypi/drmaa")
4739 (synopsis "Python bindings for the DRMAA library")
4741 "A Python package for Distributed Resource Management (DRM) job
4742 submission and control. This package is an implementation of the DRMAA 1.0
4743 Python language binding specification.")
4744 (license license:bsd-3)))
4746 (define-public python2-drmaa
4747 (package-with-python2 python-drmaa))
4749 (define-public python-grako
4751 (name "python-grako")
4757 (pypi-uri "grako" version ".zip"))
4760 "0r63i68wcnv63rfjkasq1ah81frz61a6mzbcnaxhrkdpx84p7hzw"))))
4761 (build-system python-build-system)
4762 (arguments '(#:tests? #f)) ; Test file 'grako.ebnf' is missing from archive.
4765 ("python-pytest" ,python-pytest)
4766 ("python-pytest-runner" ,python-pytest-runner)))
4767 (home-page "https://bitbucket.org/neogeny/grako")
4768 (synopsis "EBNF parser generator")
4770 "Grako takes a grammar in a variation of EBNF as input, and outputs a
4771 memoizing PEG/Packrat parser in Python.")
4772 (license license:bsd-3)))
4774 (define-public python2-grako
4775 (package-with-python2 python-grako))
4777 (define-public python-gridmap
4779 (name "python-gridmap")
4785 (url "https://github.com/pygridtools/gridmap.git")
4786 (commit (string-append "v" version))))
4787 (file-name (git-file-name name version))
4789 (base32 "1478lbwsr1w24cii2x01m2910fvh8r43ghnb78nc972a96hqiknm"))))
4790 (build-system python-build-system)
4792 '(#:tests? #f)) ; FIXME: Requires python-cherrypy.
4794 `(("python-psutil" ,python-psutil)
4795 ("python-drmaa" ,python-drmaa)
4796 ("python-pyzmq" ,python-pyzmq)))
4797 (home-page "https://github.com/pygridtools/gridmap")
4798 (synopsis "Create jobs on a cluster directly from Python")
4800 "Gridmap is a Python package to allow you to easily create jobs on the
4801 cluster directly from Python. You can directly map Python functions onto the
4802 cluster without needing to write any wrapper code yourself.")
4803 (license license:gpl3+)))
4805 (define-public python2-gridmap
4806 (package-with-python2 python-gridmap))
4808 (define-public python-honcho
4810 (name "python-honcho")
4816 (url "https://github.com/nickstenning/honcho.git")
4817 (commit (string-append "v" version))))
4818 (file-name (git-file-name name version))
4820 (base32 "11bd87474qpif20xdcn0ra1idj5k16ka51i658wfpxwc6nzsn92b"))))
4821 (build-system python-build-system)
4823 `(("python-pytest" ,python-pytest)
4824 ("python-mock" ,python-mock)
4825 ("python-tox" ,python-tox)
4826 ("which" ,which))) ;for tests
4828 `(("python-jinja2" ,python-jinja2)))
4831 (modify-phases %standard-phases
4833 (add-after 'install 'check
4834 (lambda* (#:key outputs inputs #:allow-other-keys)
4835 ;; fix honcho path in testsuite
4836 (substitute* "tests/conftest.py"
4837 (("'honcho'") (string-append "'" (assoc-ref outputs "out")
4838 "/bin/honcho" "'")))
4839 ;; It's easier to run tests after install.
4840 ;; Make installed package available for running the tests
4841 (add-installed-pythonpath inputs outputs)
4842 (invoke "py.test" "-v"))))))
4843 (home-page "https://github.com/nickstenning/honcho")
4844 (synopsis "Manage Procfile-based applications")
4846 "A Procfile is a file which describes how to run an application
4847 consisting of several processes. honcho starts all listed processes.
4848 The output of all running processes is collected by honcho and
4850 (license license:expat)))
4852 (define-public python2-honcho
4853 (package-with-python2 python-honcho))
4855 (define-public python-pexpect
4857 (name "python-pexpect")
4862 (uri (pypi-uri "pexpect" version))
4864 (base32 "1fla85g47iaxxpjhp9vkxdnv4pgc7rplfy6ja491smrrk0jqi3ia"))))
4865 (build-system python-build-system)
4868 (modify-phases %standard-phases
4869 (add-before 'check 'prepare-tests
4871 (substitute* (find-files "tests")
4872 (("/bin/ls") (which "ls"))
4873 (("/bin/echo") (which "echo"))
4874 (("/bin/which") (which "which"))
4875 ;; Many tests try to use the /bin directory which
4876 ;; is not present in the build environment.
4877 ;; Use one that's non-empty and unlikely to change.
4878 (("/bin'") "/dev'"))
4879 ;; XXX: Socket connection test gets "Connection reset by peer".
4880 ;; Why does it not work? Delete for now.
4881 (delete-file "tests/test_socket.py")
4883 (replace 'check (lambda _ (invoke "nosetests" "-v"))))))
4885 `(("python-nose" ,python-nose)
4886 ("python-pytest" ,python-pytest)
4889 ("bash-full" ,bash))) ;full Bash for 'test_replwrap.py'
4891 `(("python-ptyprocess" ,python-ptyprocess)))
4892 (home-page "http://pexpect.readthedocs.org/")
4893 (synopsis "Controlling interactive console applications")
4895 "Pexpect is a pure Python module for spawning child applications;
4896 controlling them; and responding to expected patterns in their output.
4897 Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4898 child application and control it as if a human were typing commands.")
4899 (license license:isc)))
4901 (define-public python2-pexpect
4902 (package-with-python2 python-pexpect))
4904 (define-public python-setuptools-scm
4906 (name "python-setuptools-scm")
4910 (uri (pypi-uri "setuptools_scm" version))
4913 "0n3knn3p1sqlx31k2lahn7z9bacvlv8nhlfidj77vz50bxqlgasj"))))
4914 (build-system python-build-system)
4915 (home-page "https://github.com/pypa/setuptools_scm/")
4916 (synopsis "Manage Python package versions in SCM metadata")
4918 "Setuptools_scm handles managing your Python package versions in
4919 @dfn{software configuration management} (SCM) metadata instead of declaring
4920 them as the version argument or in a SCM managed file.")
4921 (license license:expat)))
4923 ;; Needed by python-lazy-object-proxy, remove on next update cycle.
4924 (define-public python-setuptools-scm-3.3
4926 (inherit python-setuptools-scm)
4930 (uri (pypi-uri "setuptools_scm" version))
4933 "19cyndx23xmpbhz4qrwmfwsmnnaczd0dw7qg977ksq2dbvxy29dx"))))))
4935 (define-public python2-setuptools-scm
4936 (package-with-python2 python-setuptools-scm))
4938 (define-public python-pathlib2
4940 (name "python-pathlib2")
4945 (uri (pypi-uri "pathlib2" version))
4948 "0hpp92vqqgcd8h92msm9slv161b1q160igjwnkf2ag6cx0c96695"))))
4949 (build-system python-build-system)
4951 `(("python-scandir" ,python-scandir)
4952 ("python-six" ,python-six)))
4953 (home-page "https://pypi.python.org/pypi/pathlib2/")
4954 (synopsis "Object-oriented file system paths")
4955 (description "The goal of pathlib2 is to provide a backport of the
4956 standard @code{pathlib} module which tracks the standard library module, so
4957 all the newest features of the standard @code{pathlib} can be used also on
4958 older Python versions.")
4959 (license license:expat)))
4961 (define-public python2-importlib-resources
4963 (name "python2-importlib-resources")
4967 (uri (pypi-uri "importlib_resources" version))
4970 "0y3hg12iby1qyaspnbisz4s4vxax7syikk3skznwqizqyv89y9yk"))))
4971 (build-system python-build-system)
4973 `(#:python ,python-2))
4975 `(("python-wheel" ,python2-wheel)))
4977 `(("python-pathlib2" ,python2-pathlib2)
4978 ("python-typing" ,python2-typing)))
4979 (home-page "https://gitlab.com/python-devs/importlib_resources")
4980 (synopsis "Backport of @code{importlib.resources} from Python 3.7")
4982 "This package provides an implementation of @code{importlib.resources}
4983 for older versions of Python.")
4984 (license license:asl2.0)))
4986 (define-public python-importlib-metadata
4988 (name "python-importlib-metadata")
4993 (uri (pypi-uri "importlib_metadata" version))
4995 (base32 "1n76444v7zn910xrhh8954jdn4byxbn9f1jck6b85a716mbh2z7i"))))
4996 (build-system python-build-system)
4998 `(("python-zipp" ,python-zipp)))
5000 `(("python-setuptools-scm" ,python-setuptools-scm)
5001 ("python-packaging" ,python-packaging)))
5002 (home-page "https://importlib-metadata.readthedocs.io/")
5003 (synopsis "Read metadata from Python packages")
5005 "@code{importlib_metadata} is a library which provides an API for
5006 accessing an installed Python package's metadata, such as its entry points or
5007 its top-level name. This functionality intends to replace most uses of
5008 @code{pkg_resources} entry point API and metadata API. Along with
5009 @code{importlib.resources} in Python 3.7 and newer, this can eliminate the
5010 need to use the older and less efficient @code{pkg_resources} package.")
5011 (license license:asl2.0)))
5013 (define-public python2-importlib-metadata
5014 (let ((base (package-with-python2 (strip-python2-variant
5015 python-importlib-metadata))))
5018 (name "python2-importlib-metadata")
5020 `(("python-configparser" ,python2-configparser)
5021 ("python-contextlib2" ,python2-contextlib2)
5022 ("python-importlib-resources" ,python2-importlib-resources)
5023 ("python-pathlib2" ,python2-pathlib2)
5024 ,@(package-propagated-inputs base))))))
5026 (define-public python-jaraco-packaging
5028 (name "python-jaraco-packaging")
5033 (uri (pypi-uri "jaraco.packaging" version))
5036 "0zimrnkh33b9g8ffw11mjh6kvs54cy5gcjw1h5cl1r7dc833dmkm"))))
5037 (build-system python-build-system)
5039 `(("python-pytest" ,python-pytest)
5040 ("python-pytest-checkdocs" ,python-pytest-checkdocs)
5041 ("python-pytest-flake8" ,python-pytest-flake8)
5042 ("python-rst.linker" ,python-rst.linker)
5043 ("python-setuptools" ,python-setuptools)
5044 ("python-setuptools-scm" ,python-setuptools-scm)
5045 ("python-six" ,python-six)
5046 ("python-sphinx" ,python-sphinx)))
5047 (home-page "https://github.com/jaraco/jaraco.packaging")
5048 (synopsis "Tools to supplement packaging Python releases")
5050 "This package provides various tools to supplement packaging Python
5052 (license license:expat)))
5054 (define-public python-pathpy
5056 (name "python-pathpy")
5061 (uri (pypi-uri "path.py" version))
5063 (base32 "0ir9j1haq2jbi7aip6k2fa9l7q1l03k4hp1awxhjhcwzsnwp3ll8"))))
5064 (outputs '("out" "doc"))
5065 (build-system python-build-system)
5067 `(("python-appdirs" ,python-appdirs)
5068 ("python-importlib-metadata" ,python-importlib-metadata)))
5070 `(("python-setuptools-scm" ,python-setuptools-scm)
5071 ("python-sphinx" ,python-sphinx)
5072 ("python-rst.linker" ,python-rst.linker)
5073 ("python-pytest" ,python-pytest)
5074 ("python-pytest-runner" ,python-pytest-runner)
5075 ("python-jaraco-packaging" ,python-jaraco-packaging)))
5078 (modify-phases %standard-phases
5079 (add-after 'build 'build-doc
5081 (setenv "LANG" "en_US.UTF-8")
5082 (invoke "python" "setup.py" "build_sphinx")))
5083 (add-after 'install 'install-doc
5084 (lambda* (#:key outputs #:allow-other-keys)
5085 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
5086 (doc (string-append data "/doc/" ,name "-" ,version))
5087 (html (string-append doc "/html")))
5089 (for-each (lambda (file)
5090 (copy-file file (string-append doc "/" file)))
5091 '("README.rst" "CHANGES.rst"))
5092 (copy-recursively "build/sphinx/html" html)
5096 ;; The import time test aborts if an import takes longer than
5097 ;; 100ms. It may very well take a little longer than that.
5098 (invoke "pytest" "-v" "-k" "not test_import_time"))))))
5099 (home-page "https://github.com/jaraco/path.py")
5100 (synopsis "Python module wrapper for built-in os.path")
5102 "@code{path.py} implements path objects as first-class entities, allowing
5103 common operations on files to be invoked on those path objects directly.")
5104 (license license:expat)))
5106 (define-public python2-pathpy
5107 (package-with-python2 python-pathpy))
5109 (define-public python-simplegeneric
5111 (name "python-simplegeneric")
5116 (uri (pypi-uri "simplegeneric" version ".zip"))
5118 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
5119 (build-system python-build-system)
5121 `(("unzip" ,unzip)))
5122 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
5123 (synopsis "Python module for simple generic functions")
5125 "The simplegeneric module lets you define simple single-dispatch generic
5126 functions, akin to Python’s built-in generic functions like @code{len()},
5127 @code{iter()} and so on. However, instead of using specially-named methods,
5128 these generic functions use simple lookup tables, akin to those used by
5129 e.g. @code{pickle.dump()} and other generic functions found in the Python
5131 (license license:zpl2.1)))
5133 (define-public python2-simplegeneric
5134 (package-with-python2 python-simplegeneric))
5136 (define-public python-ipython-genutils
5137 ;; TODO: This package is retired, check if can be removed, see description.
5139 (name "python-ipython-genutils")
5144 (uri (pypi-uri "ipython_genutils" version))
5146 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
5147 (build-system python-build-system)
5148 (arguments `(#:tests? #f)) ; no tests
5149 (home-page "https://ipython.org")
5150 (synopsis "Vestigial utilities from IPython")
5152 "This package provides retired utilities from IPython. No packages
5153 outside IPython/Jupyter should depend on it.
5155 This package shouldn't exist. It contains some common utilities shared by
5156 Jupyter and IPython projects during The Big Split. As soon as possible, those
5157 packages will remove their dependency on this, and this package will go
5159 (license license:bsd-3)))
5161 (define-public python2-ipython-genutils
5162 (package-with-python2 python-ipython-genutils))
5164 (define-public python-traitlets
5166 (name "python-traitlets")
5171 (uri (pypi-uri "traitlets" version))
5174 "1xsrwgivpkxlbr4dfndfsi098s29yqgswgjc1qqn69yxklvfw8yh"))))
5175 (build-system python-build-system)
5178 (modify-phases %standard-phases
5179 (replace 'check (lambda _ (invoke "pytest" "-vv" "traitlets"))))))
5181 `(("python-ipython-genutils" ,python-ipython-genutils)
5182 ("python-decorator" ,python-decorator)))
5184 `(("python-pytest" ,python-pytest)))
5185 (properties `((python2-variant . ,(delay python2-traitlets))))
5186 (home-page "https://ipython.org")
5187 (synopsis "Configuration system for Python applications")
5189 "Traitlets is a framework that lets Python classes have attributes with
5190 type checking, dynamically calculated default values, and ‘on change’
5191 callbacks. The package also includes a mechanism to use traitlets for
5192 configuration, loading values from files or from command line arguments. This
5193 is a distinct layer on top of traitlets, so you can use traitlets in your code
5194 without using the configuration machinery.")
5195 (license license:bsd-3)))
5197 (define-public python2-traitlets
5198 (let ((traitlets (package-with-python2 (strip-python2-variant python-traitlets))))
5202 `(("python2-enum34" ,python2-enum34)
5203 ,@(package-propagated-inputs traitlets))))))
5205 (define-public python-jupyter-core
5207 (name "python-jupyter-core")
5212 (uri (string-append (pypi-uri "jupyter_core" version)))
5215 "1dy083rarba8prn9f9srxq3c7n7vyql02ycrqq306c40lr57aw5s"))))
5216 (build-system python-build-system)
5217 ;; FIXME: not sure how to run the tests
5218 (arguments `(#:tests? #f))
5220 `(("python-traitlets" ,python-traitlets)))
5221 (home-page "http://jupyter.org/")
5222 (synopsis "Jupyter base package")
5224 "Jupyter core is the base package on which Jupyter projects rely.")
5225 (license license:bsd-3)))
5227 (define-public python2-jupyter-core
5228 (package-with-python2 python-jupyter-core))
5230 (define-public python-jupyter-client
5232 (name "python-jupyter-client")
5237 (uri (pypi-uri "jupyter_client" version))
5240 "0l9mh7ccrpl3lppym3dnky8n1nk7xarzzdcxf4q2s7aw203cpydm"))))
5241 (build-system python-build-system)
5242 ;; Tests fail because of missing native python kernel which I assume is
5243 ;; provided by the ipython package, which we cannot use because it would
5244 ;; cause a dependency cycle.
5248 #:phases (modify-phases %standard-phases
5249 (add-after 'unpack 'set-tool-file-names
5250 (lambda* (#:key inputs #:allow-other-keys)
5251 (let ((iproute (assoc-ref inputs "iproute")))
5252 (substitute* "jupyter_client/localinterfaces.py"
5254 (string-append "'" iproute "/sbin/ip'")))
5257 `(("iproute" ,iproute)))
5259 `(("python-pyzmq" ,python-pyzmq)
5260 ("python-traitlets" ,python-traitlets)
5261 ("python-jupyter-core" ,python-jupyter-core)))
5262 (home-page "http://jupyter.org/")
5263 (synopsis "Jupyter protocol implementation and client libraries")
5265 "The @code{jupyter_client} package contains the reference implementation
5266 of the Jupyter protocol. It also provides client and kernel management APIs
5267 for working with kernels, and the @code{jupyter kernelspec} entrypoint for
5268 installing @code{kernelspec}s for use with Jupyter frontends.")
5269 (license license:bsd-3)))
5271 (define-public python2-jupyter-client
5272 (package-with-python2 python-jupyter-client))
5274 (define-public python-ipykernel
5276 (name "python-ipykernel")
5281 (uri (pypi-uri "ipykernel" version))
5283 (base32 "1a08y677lpn80qzvv7z0smgggmr5m5ayf0bs6vds47xpxl9sss5k"))))
5284 (build-system python-build-system)
5287 (modify-phases %standard-phases
5290 (setenv "HOME" "/tmp")
5291 (invoke "pytest" "-v")
5293 (add-after 'install 'set-python-file-name
5294 (lambda* (#:key outputs #:allow-other-keys)
5295 ;; Record the absolute file name of the 'python' executable in
5297 (let ((out (assoc-ref outputs "out")))
5298 (substitute* (string-append out "/share/jupyter"
5299 "/kernels/python3/kernel.json")
5301 (string-append "\"" (which "python") "\"")))
5304 `(("python-ipython" ,python-ipython)
5305 ;; imported at runtime during connect
5306 ("python-jupyter-client" ,python-jupyter-client)))
5308 `(("python-flaky" ,python-flaky)
5309 ("python-nose" ,python-nose)
5310 ("python-pytest" ,python-pytest)))
5311 (home-page "https://ipython.org")
5312 (synopsis "IPython Kernel for Jupyter")
5314 "This package provides the IPython kernel for Jupyter.")
5315 (license license:bsd-3)))
5317 ;; Version 5.1.1 and above no longer support Python 2.
5318 (define-public python2-ipykernel
5320 (name "python2-ipykernel")
5325 (uri (pypi-uri "ipykernel" version))
5327 (base32 "0br95qhrd5k65g10djngiy27hs0642301hlf2q142i8djabvzh0g"))))
5328 (build-system python-build-system)
5330 `(#:python ,python-2
5332 (modify-phases %standard-phases
5335 (setenv "HOME" "/tmp")
5336 (invoke "pytest" "-v")
5339 `(("python2-ipython" ,python2-ipython)
5340 ;; imported at runtime during connect
5341 ("python2-jupyter-client" ,python2-jupyter-client)))
5343 `(("python2-pytest" ,python2-pytest)
5344 ("python2-nose" ,python2-nose)))
5345 (home-page "https://ipython.org")
5346 (synopsis "IPython Kernel for Jupyter")
5348 "This package provides the IPython kernel for Jupyter.")
5349 (license license:bsd-3)))
5351 (define-public python-pari-jupyter
5353 (name "python-pari-jupyter")
5358 (uri (pypi-uri "pari_jupyter" version))
5361 "1yash0p422nnin7z58b99d0p23nx79f5m0mainc9hsjg72jhdhr6"))))
5362 (build-system python-build-system)
5364 `(("python-ipykernel" ,python-ipykernel)))
5366 `(("pari-gp" ,pari-gp)
5367 ("readline" ,readline)))
5369 `(#:tests? #f)) ; no test suite
5371 "https://github.com/jdemeyer/pari_jupyter")
5372 (synopsis "A Jupyter kernel for PARI/GP")
5373 (description "The package provides a PARI/GP kernel for Jupyter.")
5374 (license license:gpl3+)))
5376 (define-public python-backcall
5378 (name "python-backcall")
5383 (uri (pypi-uri "backcall" version))
5386 "1r01dqch3f8fdj3n6fviw8hxqrs6w5v0qw4izmvqzry1w9dxiv1q"))))
5387 (build-system python-build-system)
5388 (home-page "https://github.com/takluyver/backcall/")
5389 (synopsis "Specifications for callback functions passed in to an API")
5391 "If your code lets other people supply callback functions, it's important
5392 to specify the function signature you expect, and check that functions support
5393 that. Adding extra parameters later would break other peoples code unless
5394 you're careful. The @code{backcall} package provides a way of specifying the
5395 callback signature using a prototype function.")
5396 (license license:bsd-3)))
5398 ;; This is the latest release of the LTS version of ipython with support for
5399 ;; Python 2.7 and Python 3.x. Later non-LTS versions starting from 6.0 have
5400 ;; dropped support for Python 2.7.
5401 (define-public python2-ipython
5403 (name "python2-ipython")
5408 (uri (pypi-uri "ipython" version ".tar.gz"))
5410 (base32 "01l93i4hspf0lvhmycvc8j378bslm9rw30mwfspsl6v1ayc69b2b"))))
5411 (build-system python-build-system)
5413 `(("python2-backports-shutil-get-terminal-size"
5414 ,python2-backports-shutil-get-terminal-size)
5415 ("python2-pathlib2" ,python2-pathlib2)
5416 ("python2-pyzmq" ,python2-pyzmq)
5417 ("python2-prompt-toolkit" ,python2-prompt-toolkit-1)
5418 ("python2-terminado" ,python2-terminado)
5419 ("python2-matplotlib" ,python2-matplotlib)
5420 ("python2-numpy" ,python2-numpy)
5421 ("python2-numpydoc" ,python2-numpydoc)
5422 ("python2-jinja2" ,python2-jinja2)
5423 ("python2-mistune" ,python2-mistune)
5424 ("python2-pexpect" ,python2-pexpect)
5425 ("python2-pickleshare" ,python2-pickleshare)
5426 ("python2-simplegeneric" ,python2-simplegeneric)
5427 ("python2-jsonschema" ,python2-jsonschema)
5428 ("python2-traitlets" ,python2-traitlets)
5429 ("python2-nbformat" ,python2-nbformat)
5430 ("python2-pygments" ,python2-pygments)))
5432 `(("readline" ,readline)
5435 `(("graphviz" ,graphviz)
5436 ("pkg-config" ,pkg-config)
5437 ("python2-requests" ,python2-requests) ;; for tests
5438 ("python2-testpath" ,python2-testpath)
5439 ("python2-mock" ,python2-mock)
5440 ("python2-nose" ,python2-nose)))
5442 `(#:python ,python-2
5444 (modify-phases %standard-phases
5445 (add-before 'check 'delete-broken-tests
5446 (lambda* (#:key inputs #:allow-other-keys)
5447 ;; These tests throw errors for unknown reasons.
5448 (delete-file "IPython/core/tests/test_profile.py")
5449 (delete-file "IPython/core/tests/test_interactiveshell.py")
5450 (delete-file "IPython/core/tests/test_magic.py")
5452 (home-page "https://ipython.org")
5453 (synopsis "IPython is a tool for interactive computing in Python")
5455 "IPython provides a rich architecture for interactive computing with:
5456 Powerful interactive shells, a browser-based notebook, support for interactive
5457 data visualization, embeddable interpreters and tools for parallel
5459 (license license:bsd-3)))
5461 (define-public python-ipython
5463 (name "python-ipython")
5468 (uri (pypi-uri "ipython" version ".tar.gz"))
5470 (base32 "103jkw18z7fnwdal1mdbijjxi1fndzn31g887lmj7ddpf2r07lyz"))))
5471 (build-system python-build-system)
5473 `(("python-backcall" ,python-backcall)
5474 ("python-pyzmq" ,python-pyzmq)
5475 ("python-prompt-toolkit" ,python-prompt-toolkit)
5476 ("python-terminado" ,python-terminado)
5477 ("python-matplotlib" ,python-matplotlib)
5478 ("python-numpy" ,python-numpy)
5479 ("python-numpydoc" ,python-numpydoc)
5480 ("python-jedi" ,python-jedi)
5481 ("python-jinja2" ,python-jinja2)
5482 ("python-mistune" ,python-mistune)
5483 ("python-pexpect" ,python-pexpect)
5484 ("python-pickleshare" ,python-pickleshare)
5485 ("python-simplegeneric" ,python-simplegeneric)
5486 ("python-jsonschema" ,python-jsonschema)
5487 ("python-traitlets" ,python-traitlets)
5488 ("python-nbformat" ,python-nbformat)
5489 ("python-pygments" ,python-pygments)))
5491 `(("readline" ,readline)
5494 `(("graphviz" ,graphviz)
5495 ("pkg-config" ,pkg-config)
5496 ("python-requests" ,python-requests) ;; for tests
5497 ("python-testpath" ,python-testpath)
5498 ("python-nose" ,python-nose)))
5501 (modify-phases %standard-phases
5502 (add-after 'unpack 'make-docs-reproducible
5504 (substitute* "IPython/sphinxext/ipython_directive.py"
5505 ((".*import datetime") "")
5506 ((".*datetime.datetime.now\\(\\)") "")
5507 (("%timeit") "# %timeit"))
5509 ;; Tests can only be run after the library has been installed and not
5510 ;; within the source directory.
5512 (add-after 'install 'check
5513 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
5516 ;; Make installed package available for running the tests
5517 (add-installed-pythonpath inputs outputs)
5518 (setenv "HOME" "/tmp/") ;; required by a test
5519 ;; We only test the core because one of the other tests
5520 ;; tries to import ipykernel.
5521 (invoke "python" "IPython/testing/iptest.py"
5522 "-v" "IPython/core/tests"))
5524 (add-before 'check 'fix-tests
5525 (lambda* (#:key inputs #:allow-other-keys)
5526 (substitute* "./IPython/utils/_process_posix.py"
5527 (("/usr/bin/env', 'which") (which "which")))
5528 (substitute* "./IPython/core/tests/test_inputtransformer.py"
5529 (("#!/usr/bin/env python")
5530 (string-append "#!" (which "python"))))
5531 ;; This test introduces a circular dependency on ipykernel
5532 ;; (which depends on ipython).
5533 (delete-file "IPython/core/tests/test_display.py")
5534 ;; AttributeError: module 'IPython.core' has no attribute 'formatters'
5535 (delete-file "IPython/core/tests/test_interactiveshell.py")
5537 (home-page "https://ipython.org")
5538 (synopsis "IPython is a tool for interactive computing in Python")
5540 "IPython provides a rich architecture for interactive computing with:
5541 Powerful interactive shells, a browser-based notebook, support for interactive
5542 data visualization, embeddable interpreters and tools for parallel
5544 (license license:bsd-3)))
5546 (define-public python-ipython-documentation
5548 (inherit python-ipython)
5549 (name "python-ipython-documentation")
5550 (version (package-version python-ipython))
5553 (modify-phases %standard-phases
5557 (lambda* (#:key outputs #:allow-other-keys)
5558 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
5559 (doc (string-append data "/doc/" ,name "-" ,version))
5560 (html (string-append doc "/html"))
5561 (man1 (string-append data "/man/man1"))
5562 (info (string-append data "/info"))
5563 (examples (string-append doc "/examples"))
5564 (python-arg (string-append "PYTHON=" (which "python"))))
5565 (setenv "LANG" "en_US.utf8")
5566 (with-directory-excursion "docs"
5567 ;; FIXME: pdf fails to build
5568 ;;(system* "make" "pdf" "PAPER=a4")
5569 (system* "make" python-arg "html")
5570 ;; FIXME: the generated texi file contains ^@^@, which trips
5572 ;; (system* "make" python-arg "info")
5574 (copy-recursively "docs/man" man1)
5575 (copy-recursively "examples" examples)
5576 (copy-recursively "docs/build/html" html)
5577 ;; (copy-file "docs/build/latex/ipython.pdf"
5578 ;; (string-append doc "/ipython.pdf"))
5580 ;; (copy-file "docs/build/texinfo/ipython.info"
5581 ;; (string-append info "/ipython.info"))
5582 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))
5585 `(("python-ipython" ,python-ipython)
5586 ("python-ipykernel" ,python-ipykernel)))
5588 `(("python-sphinx" ,python-sphinx)
5589 ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)
5590 ;; FIXME: It's possible that a smaller union would work just as well.
5591 ("texlive" ,(texlive-union (list texlive-amsfonts
5593 texlive-generic-ifxetex
5594 texlive-generic-pdftex
5595 texlive-latex-capt-of
5597 texlive-latex-environ
5598 texlive-latex-eqparbox
5599 texlive-latex-etoolbox
5600 texlive-latex-expdlist
5601 texlive-latex-fancyhdr
5602 texlive-latex-fancyvrb
5603 texlive-latex-fncychap
5605 texlive-latex-framed
5606 texlive-latex-geometry
5607 texlive-latex-graphics
5608 texlive-latex-hyperref
5609 texlive-latex-mdwtools
5610 texlive-latex-multirow
5611 texlive-latex-needspace
5612 texlive-latex-oberdiek
5613 texlive-latex-parskip
5614 texlive-latex-preview
5615 texlive-latex-tabulary
5616 texlive-latex-threeparttable
5617 texlive-latex-titlesec
5618 texlive-latex-trimspaces
5620 texlive-latex-upquote
5622 texlive-latex-varwidth
5623 texlive-latex-wrapfig)))
5624 ("texinfo" ,texinfo)))))
5626 (define-public python-urwid
5628 (name "python-urwid")
5633 (uri (pypi-uri "urwid" version))
5636 "1g6cpicybvbananpjikmjk8npmjk4xvak1wjzji62wc600wkwkb4"))))
5637 (build-system python-build-system)
5638 (home-page "http://urwid.org")
5639 (synopsis "Console user interface library for Python")
5641 "Urwid is a curses-based UI/widget library for Python. It includes many
5642 features useful for text console applications.")
5643 (license license:lgpl2.1+)))
5645 (define-public python2-urwid
5646 (package-with-python2 python-urwid))
5648 (define-public python-urwidtrees
5650 (name "python-urwidtrees")
5655 ;; package author intends on distributing via github rather than pypi:
5656 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
5658 (url "https://github.com/pazz/urwidtrees")
5660 (file-name (git-file-name name version))
5663 "1n1kpidvkdnsqyb82vlvk78gmly96kh8351lqxn2pzgwwns6fml2"))))
5664 (build-system python-build-system)
5666 '(#:use-setuptools? #f
5667 #:tests? #f)) ; no tests
5668 (propagated-inputs `(("python-urwid" ,python-urwid)))
5669 (home-page "https://github.com/pazz/urwidtrees")
5670 (synopsis "Tree widgets for urwid")
5671 (description "Urwidtrees is a Widget Container API for the @code{urwid}
5672 toolkit. Use it to build trees of widgets.")
5673 (license license:gpl3+)))
5675 (define-public python2-urwidtrees
5676 (package-with-python2 python-urwidtrees))
5678 (define-public python-ua-parser
5680 (name "python-ua-parser")
5685 (uri (pypi-uri "ua-parser" version))
5688 "1jwdf58rhchjzzrad405pviv0iq24xa2xmmmdgcm2c8s6b4wzfwp"))))
5689 (build-system python-build-system)
5691 `(#:tests? #f)) ;no test suite in release
5693 `(("python-pyyaml" ,python-pyyaml)))
5694 (home-page "https://github.com/ua-parser/uap-python")
5695 (synopsis "User agent parser")
5697 "@code{ua-parser} is a Python port of Browserscope's user agent parser.")
5698 (license license:asl2.0)))
5700 (define-public python2-ua-parser
5701 (package-with-python2 python-ua-parser))
5703 (define-public python-user-agents
5705 (name "python-user-agents")
5710 (uri (pypi-uri "user-agents" version))
5713 "0fc00cd3j8dahq1zzn8pkgfgd7lq37bp2scmdma2n1c049vicgb4"))))
5714 (build-system python-build-system)
5716 `(#:tests? #f)) ;missing devices.json test file in release
5718 `(("python-ua-parser" ,python-ua-parser)))
5719 (home-page "https://github.com/selwin/python-user-agents")
5720 (synopsis "User Agent strings parsing library")
5722 "A library to identify devices (phones, tablets) and their capabilities by
5723 parsing (browser/HTTP) user agent strings.")
5724 (license license:expat)))
5726 (define-public python2-user-agents
5727 (package-with-python2 python-user-agents))
5729 (define-public python-dbus
5731 (name "python-dbus")
5736 (uri (string-append "https://dbus.freedesktop.org/releases/dbus-python/"
5737 "dbus-python-" version ".tar.gz"))
5739 (base32 "0cdchkgnivlka4lf8q4qfk0yxq483i3r3aqickjf8hfn7nx0c0mi"))))
5740 (build-system gnu-build-system)
5742 `(("pkg-config" ,pkg-config)))
5744 `(("python" ,python-wrapper)
5745 ("dbus-glib" ,dbus-glib)))
5746 (synopsis "Python bindings for D-bus")
5747 (description "python-dbus provides bindings for libdbus, the reference
5748 implementation of D-Bus.")
5749 (home-page "https://www.freedesktop.org/wiki/Software/DBusBindings/")
5750 (license license:expat)))
5752 (define-public python2-dbus
5753 (package (inherit python-dbus)
5754 (name "python2-dbus")
5755 (inputs `(("python" ,python-2)
5756 ,@(alist-delete "python"
5757 (package-inputs python-dbus)
5760 (define-public python-notify2
5762 (name "python-notify2")
5767 (uri (pypi-uri "notify2" version))
5770 "0z8rrv9rsg1r2qgh2dxj3dfj5xnki98kgi3w839kqby4a26i1yik"))))
5771 (build-system python-build-system)
5772 (arguments `(#:tests? #f)) ; tests depend on system state
5774 `(("python-dbus" ,python-dbus)))
5775 (home-page "https://bitbucket.org/takluyver/pynotify2")
5776 (synopsis "Python interface to D-Bus notifications")
5778 "Pynotify2 provides a Python interface for sending D-Bus notifications.
5779 It is a reimplementation of pynotify in pure Python, and an alternative to
5780 the GObject Introspection bindings to libnotify for non-GTK applications.")
5781 (license (list license:bsd-2
5782 license:lgpl2.1+))))
5784 (define-public python2-notify2
5785 (package-with-python2 python-notify2))
5787 ;; beautifulsoup4 has a totally different namespace than 3.x,
5788 ;; and pypi seems to put it under its own name, so I guess we should too
5789 (define-public python-beautifulsoup4
5791 (name "python-beautifulsoup4")
5796 (uri (pypi-uri "beautifulsoup4" version))
5799 "0j2kycz2dxgx68xzjm7rxg5xn6v61gq5ifvxyg99slmqkybnal4l"))))
5800 (build-system python-build-system)
5803 (modify-phases %standard-phases
5804 ;; The Python 2 source is the definitive source of beautifulsoup4. We
5805 ;; must use this conversion script when building with Python 3. The
5806 ;; conversion script also runs the tests.
5807 ;; For more information, see the file 'convert-py3k' in the source
5810 (lambda _ (invoke "./convert-py3k"))))))
5812 `(("python-soupsieve" ,python-soupsieve)))
5814 "https://www.crummy.com/software/BeautifulSoup/bs4/")
5816 "Python screen-scraping library")
5818 "Beautiful Soup is a Python library designed for rapidly setting up
5819 screen-scraping projects. It offers Pythonic idioms for navigating,
5820 searching, and modifying a parse tree, providing a toolkit for
5821 dissecting a document and extracting what you need. It automatically
5822 converts incoming documents to Unicode and outgoing documents to UTF-8.")
5823 (license license:expat)
5824 (properties `((python2-variant . ,(delay python2-beautifulsoup4))))))
5826 (define-public python2-beautifulsoup4
5828 (inherit (package-with-python2
5829 (strip-python2-variant python-beautifulsoup4)))
5830 (arguments `(#:python ,python-2))))
5832 (define-public python-soupsieve
5834 (name "python-soupsieve")
5839 (uri (pypi-uri "soupsieve" version))
5842 "1nhd0q0ifwva9wn645s6pn74p1rd97asn3qfg75nphx1wkgcbhg2"))))
5843 (build-system python-build-system)
5844 (arguments `(#:tests? #f))
5845 ;;XXX: 2 tests fail currently despite claming they were to be
5846 ;;skipped. Also, beautifulsoup4 may depend on this in the future, so we
5847 ;;don't want to create a circular dependency.
5848 (home-page "https://github.com/facelessuser/soupsieve")
5849 (synopsis "CSS selector library")
5851 "Soup Sieve is a CSS selector library designed to be used with Beautiful
5852 Soup 4. It aims to provide selecting, matching, and filtering using modern
5853 CSS selectors. Soup Sieve currently provides selectors from the CSS level 1
5854 specifications up through the latest CSS level 4 drafts and beyond (though
5855 some are not yet implemented).")
5856 (properties `((python2-variant . ,(delay python2-soupsieve))))
5857 (license license:expat)))
5859 (define-public python2-soupsieve
5860 (let ((base (package-with-python2 (strip-python2-variant python-soupsieve))))
5864 `(("python2-backports-functools-lru-cache"
5865 ,python2-backports-functools-lru-cache)
5866 ,@(package-propagated-inputs base))))))
5868 (define-public python-netifaces
5870 (name "python-netifaces")
5875 (uri (pypi-uri "netifaces" version))
5878 "1gccklrcplbbqh81g1mdgpa5y8na7kkf29cq2ka3f5a2fp5hyndx"))))
5879 (build-system python-build-system)
5880 (home-page "https://github.com/al45tair/netifaces")
5882 "Python module for portable network interface information")
5884 "Netifaces is a Python module providing information on network
5885 interfaces in an easy and portable manner.")
5886 (license license:expat)))
5888 (define-public python2-netifaces
5889 (package-with-python2 python-netifaces))
5891 (define-public python-networkx
5893 (name "python-networkx")
5898 (uri (pypi-uri "networkx" version ".zip"))
5900 (base32 "12swxb15299v9vqjsq4z8rgh5sdhvpx497xwnhpnb0gynrx6zra5"))))
5901 (build-system python-build-system)
5902 ;; python-decorator is needed at runtime.
5904 `(("python-decorator" ,python-decorator)))
5906 `(("python-nose" ,python-nose)
5908 (home-page "https://networkx.github.io/")
5909 (synopsis "Python module for creating and manipulating graphs and networks")
5911 "NetworkX is a Python package for the creation, manipulation, and study
5912 of the structure, dynamics, and functions of complex networks.")
5913 (license license:bsd-3)))
5915 (define-public python2-networkx
5916 (package-with-python2 python-networkx))
5918 (define-public python-datrie
5920 (name "python-datrie")
5925 (uri (pypi-uri "datrie" version))
5928 "0338r8xgmpy78556jhms0h6qkvyjr10p8bpgdvcpqzm9lrmxmmdx"))))
5929 (build-system python-build-system)
5931 `(("python-cython" ,python-cython)
5932 ("python-hypothesis" ,python-hypothesis)
5933 ("python-pytest" ,python-pytest)
5934 ("python-pytest-runner" ,python-pytest-runner)))
5935 (home-page "https://github.com/kmike/datrie")
5936 (synopsis "Fast, efficiently stored trie for Python")
5938 "This package provides a fast, efficiently stored trie implementation for
5940 (license license:lgpl2.1+)))
5942 (define-public snakemake
5949 (uri (pypi-uri "snakemake" version))
5951 (base32 "1pnpvvn8n2a78cg360wz3ldmpqrsm2wzi0c0dmvki9fnsw6fxdas"))))
5952 (build-system python-build-system)
5954 ;; TODO: Package missing test dependencies.
5957 (modify-phases %standard-phases
5958 ;; For cluster execution Snakemake will call Python. Since there is
5959 ;; no suitable PYTHONPATH set, cluster execution will fail. We fix
5960 ;; this by calling the snakemake wrapper instead.
5961 (add-after 'unpack 'call-wrapper-not-wrapped-snakemake
5962 (lambda* (#:key outputs #:allow-other-keys)
5963 (substitute* "snakemake/executors.py"
5964 (("\\{sys.executable\\} -m snakemake")
5965 (string-append (assoc-ref outputs "out")
5969 `(("python-appdirs" ,python-appdirs)
5970 ("python-configargparse" ,python-configargparse)
5971 ("python-datrie" ,python-datrie)
5972 ("python-docutils" ,python-docutils)
5973 ("python-gitpython" ,python-gitpython)
5974 ("python-jinja2" ,python-jinja2)
5975 ("python-jsonschema" ,python-jsonschema)
5976 ("python-networkx" ,python-networkx)
5977 ("python-psutil" ,python-psutil)
5978 ("python-pyyaml" ,python-pyyaml)
5979 ("python-ratelimiter" ,python-ratelimiter)
5980 ("python-requests" ,python-requests)
5981 ("python-wrapt" ,python-wrapt)))
5982 (home-page "https://snakemake.readthedocs.io")
5983 (synopsis "Python-based execution environment for make-like workflows")
5985 "Snakemake aims to reduce the complexity of creating workflows by
5986 providing a clean and modern domain specific specification language (DSL) in
5987 Python style, together with a fast and comfortable execution environment.")
5988 (license license:expat)))
5990 (define-public python-pyqrcode
5992 (name "python-pyqrcode")
5997 (uri (pypi-uri "PyQRCode" version))
6000 "1m9ln8k9v7dfbh1i81225hx5mdsh8mpf9g7r4wpbfmiyfcs7dgzx"))))
6001 (build-system python-build-system)
6003 "https://github.com/mnooner256/pyqrcode")
6004 (synopsis "QR code generator")
6006 "Pyqrcode is a QR code generator written purely in Python with
6007 SVG, EPS, PNG and terminal output.")
6008 (license license:bsd-3)))
6010 (define-public python-seaborn
6012 (name "python-seaborn")
6017 (uri (pypi-uri "seaborn" version))
6019 (base32 "0bqysi3fxfjl1866m5jq8z7mynhqbqnikim74dmzn8539iwkzj3n"))
6023 ;; This has already been merged, but there is no new
6024 ;; release including this patch. It fixes problems
6025 ;; with axis rotation that would lead to test
6027 (uri "https://patch-diff.githubusercontent.com/raw/mwaskom/seaborn/pull/1716.diff")
6030 "1lm870z316n9ivsyr86hpk1gxaraw0mrjvq42lqsm0znhjdp9q9w"))
6031 (file-name "seaborn-0.9.0-axis-rotation.patch"))))))
6032 (build-system python-build-system)
6035 (modify-phases %standard-phases
6036 (add-before 'check 'start-xserver
6037 (lambda* (#:key inputs #:allow-other-keys)
6038 (let ((xorg-server (assoc-ref inputs "xorg-server")))
6039 ;; There must be a running X server and make check doesn't
6040 ;; start one. Therefore we must do it.
6041 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
6042 (setenv "DISPLAY" ":1")
6044 (add-after 'unpack 'fix-tests
6046 ;; test_cbar_ticks fails probably because of matplotlib's
6047 ;; expectation of using an older version of FreeType.
6048 (delete-file "seaborn/tests/test_matrix.py")
6050 (replace 'check (lambda _ (invoke "pytest" "seaborn") #t)))))
6052 `(("python-pandas" ,python-pandas)
6053 ("python-matplotlib" ,python-matplotlib)
6054 ("python-numpy" ,python-numpy)
6055 ("python-scipy" ,python-scipy)))
6057 `(("python-pytest" ,python-pytest)
6058 ("xorg-server" ,xorg-server-for-tests)))
6059 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
6060 (synopsis "Statistical data visualization")
6062 "Seaborn is a library for making attractive and informative statistical
6063 graphics in Python. It is built on top of matplotlib and tightly integrated
6064 with the PyData stack, including support for numpy and pandas data structures
6065 and statistical routines from scipy and statsmodels.")
6066 (license license:bsd-3)))
6068 (define-public python2-seaborn
6069 (package-with-python2 python-seaborn))
6071 (define-public python-mpmath
6073 (name "python-mpmath")
6077 (uri (string-append "http://mpmath.org/files/mpmath-"
6081 "08ijsr4ifrqv3cjc26mkw0dbvyygsa99in376hr4b96ddm1gdpb8"))))
6082 (build-system python-build-system)
6085 (modify-phases %standard-phases
6088 (invoke "python" "mpmath/tests/runtests.py" "-local"))))))
6089 (home-page "http://mpmath.org")
6090 (synopsis "Arbitrary-precision floating-point arithmetic in python")
6092 "@code{mpmath} can be used as an arbitrary-precision substitute for
6093 Python's float/complex types and math/cmath modules, but also does much
6094 more advanced mathematics.")
6095 (license license:bsd-3)))
6097 (define-public python2-mpmath
6098 (package-with-python2 python-mpmath))
6100 (define-public python-bigfloat
6102 (name "python-bigfloat")
6107 (uri (pypi-uri "bigfloat" version))
6109 (base32 "0xd7q4l7v0f463diznjv4k9wlaks80pn9drdqmfifi7zx8qvybi6"))))
6110 (build-system python-build-system)
6113 (home-page "https://github.com/mdickinson/bigfloat")
6114 (synopsis "Arbitrary precision floating-point arithmetic for Python")
6116 "This package provides a Python interface to the MPFR library for
6117 multiprecision arithmetic.")
6118 (license license:lgpl3+)))
6120 (define-public python2-bigfloat
6121 (package-with-python2 python-bigfloat))
6123 (define-public python-sympy
6125 (name "python-sympy")
6131 "https://github.com/sympy/sympy/releases/download/sympy-"
6132 version "/sympy-" version ".tar.gz"))
6134 (base32 "190n29sppw7g8ihilc5451y7jlfcaw56crqiqbf1jff43dlmfnxc"))))
6135 (build-system python-build-system)
6138 (modify-phases %standard-phases
6139 ;; Run the core tests after installation. By default it would run
6140 ;; *all* tests, which take a very long time to complete and are known
6143 (add-after 'install 'check
6144 (lambda* (#:key outputs #:allow-other-keys)
6145 (invoke "python3" "-c" "import sympy; sympy.test(\"/core\")")
6148 `(("python-mpmath" ,python-mpmath)))
6149 (home-page "http://www.sympy.org/")
6150 (synopsis "Python library for symbolic mathematics")
6152 "SymPy is a Python library for symbolic mathematics. It aims to become a
6153 full-featured computer algebra system (CAS) while keeping the code as simple
6154 as possible in order to be comprehensible and easily extensible.")
6155 (license license:bsd-3)))
6157 (define-public python2-sympy
6159 (inherit (package-with-python2 python-sympy))
6162 (modify-phases %standard-phases
6163 ;; Run the core tests after installation. By default it would run
6164 ;; *all* tests, which take a very long time to complete and are known
6167 (add-after 'install 'check
6168 (lambda* (#:key outputs #:allow-other-keys)
6169 (invoke "python" "-c" "import sympy; sympy.test(\"/core\")")
6172 (define-public python-q
6179 (uri (pypi-uri "q" version))
6182 "1mgfazh8fkizh6walra2zv885f3lcgr3nb02v1frfm4p8ddcy3yy"))))
6183 (build-system python-build-system)
6184 (home-page "https://github.com/zestyping/q")
6185 (synopsis "Quick-and-dirty debugging output for tired programmers")
6187 "q is a Python module for \"print\" style of debugging Python code. It
6188 provides convenient short API for print out of values, tracebacks, and
6189 falling into the Python interpreter.")
6190 (license license:asl2.0)))
6192 (define-public python2-q
6193 (package-with-python2 python-q))
6195 (define-public python2-xlib
6197 (name "python2-xlib")
6201 (uri (string-append "mirror://sourceforge/python-xlib/python-xlib"
6203 "python-xlib-" version ".tar.gz"))
6206 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
6207 (build-system python-build-system)
6209 `(#:python ,python-2 ;Python 2 only
6210 #:tests? #f)) ;no tests
6211 (home-page "http://python-xlib.sourceforge.net/")
6212 (synopsis "Python X11 client library")
6214 "The Python X Library is intended to be a fully functional X client
6215 library for Python programs. It is useful to implement low-level X clients.
6216 It is written entirely in Python.")
6217 (license license:gpl2+)))
6219 (define-public python-singledispatch
6221 (name "python-singledispatch")
6226 (uri (pypi-uri "singledispatch" version))
6229 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
6230 (build-system python-build-system)
6232 `(("python-six" ,python-six))) ; required for conversion, not at run-time
6234 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
6235 (synopsis "Backport of singledispatch feature from Python 3.4")
6237 "This library brings functools.singledispatch from Python 3.4 to Python
6239 (license license:expat)))
6241 (define-public python2-singledispatch
6242 (package-with-python2 python-singledispatch))
6244 ;; the python- version can be removed with python-3.5
6245 (define-public python-backports-abc
6247 (name "python-backports-abc")
6252 (uri (pypi-uri "backports_abc" version))
6255 "1pkv8d1zxj5f9i227dxbjczncbv7ks7ywnjwyxfjagm02i2yafq3"))))
6256 (build-system python-build-system)
6257 (home-page "https://github.com/cython/backports_abc")
6258 (synopsis "Backport of additions to the 'collections.abc' module")
6260 "Python-backports-abc provides a backport of additions to the
6261 @code{collections.abc} module in Python-3.5.")
6262 (license license:psfl)))
6264 (define-public python2-backports-abc
6265 (package-with-python2 python-backports-abc))
6267 (define-public python-backports-csv
6269 (name "python-backports-csv")
6274 (uri (pypi-uri "backports.csv" version))
6277 "1imzbrradkfn8s2m1qcimyn74dn1mz2p3j381jljn166rf2i6hlc"))))
6278 (build-system python-build-system)
6279 (home-page "https://github.com/ryanhiebert/backports.csv")
6280 (synopsis "Backport of Python 3's csv module for Python 2")
6282 "Provides a backport of Python 3's @code{csv} module for parsing
6283 comma separated values. The API of the @code{csv} module in Python 2
6284 is drastically different from the @code{csv} module in Python 3.
6285 This is due, for the most part, to the difference between str in
6286 Python 2 and Python 3.")
6287 (license license:psfl)))
6289 (define-public python2-backports-csv
6290 (package-with-python2 python-backports-csv))
6292 (define-public python2-backports-shutil-get-terminal-size
6294 (name "python2-backports-shutil-get-terminal-size")
6299 (uri (pypi-uri "backports.shutil_get_terminal_size" version))
6302 "107cmn7g3jnbkp826zlj8rrj19fam301qvaqf0f3905f5217lgki"))))
6303 (build-system python-build-system)
6305 `(#:python ,python-2
6307 (modify-phases %standard-phases
6310 (invoke "py.test" "-v"))))))
6312 `(("python2-pytest" ,python2-pytest)))
6313 (home-page "https://github.com/chrippa/backports.shutil_get_terminal_size")
6314 (synopsis "Backport of Python 3.3's @code{shutil.get_terminal_size}")
6316 "This package provides a backport of the @code{get_terminal_size
6317 function} from Python 3.3's @code{shutil}.
6318 Unlike the original version it is written in pure Python rather than C,
6319 so it might be a tiny bit slower.")
6320 (license license:expat)))
6322 (define-public python-waf
6328 (uri (string-append "https://waf.io/"
6329 "waf-" version ".tar.bz2"))
6332 "19dvqbsvxz7ch03dh1v0znklrwxlz6yzddc3k9smzrrgny4jch6q"))))
6333 (build-system python-build-system)
6336 (modify-phases %standard-phases
6339 ;; XXX: Find a way to add all extra tools.
6340 (let ((tools '("gccdeps"
6341 "clang_compilation_database")))
6342 (invoke "python" "waf-light" "configure" "build"
6343 (string-append "--tools="
6344 (string-join tools ","))))))
6347 (invoke "python" "waf" "--version")))
6349 (lambda* (#:key outputs #:allow-other-keys)
6350 (let ((out (assoc-ref outputs "out")))
6351 (install-file "waf" (string-append out "/bin")))
6353 ;; waf breaks when it is wrapped.
6355 (home-page "https://waf.io/")
6356 (synopsis "Python-based build system")
6358 "Waf is a Python-based framework for configuring, compiling and installing
6360 (license license:bsd-3)))
6362 (define-public python2-waf
6363 (package-with-python2 python-waf))
6365 (define-public python-pyzmq
6367 (name "python-pyzmq")
6372 (uri (pypi-uri "pyzmq" version))
6374 (base32 "1pyxxrz60f88ffm0y6vpbx3q8jcr9ybz8fcilihwzwhh36n84ax7"))))
6375 (build-system python-build-system)
6378 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
6379 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
6380 ;; --inplace' for 'python setup.py test' to work.
6383 `(("zeromq" ,zeromq)))
6385 `(("pkg-config" ,pkg-config)
6386 ("python-nose" ,python-nose)))
6387 (home-page "https://github.com/zeromq/pyzmq")
6388 (synopsis "Python bindings for 0MQ")
6390 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
6391 (license license:bsd-4)))
6393 (define-public python2-pyzmq
6394 (package-with-python2 python-pyzmq))
6396 (define-public python-pep8
6397 ;; This package has been renamed to ‘pycodestyle’ and is no longer updated.
6398 ;; Its last release (1.7.1) adds only a scary warning to this effect, breaking
6399 ;; some dependents' test suites, and nothing more.
6401 (name "python-pep8")
6406 (uri (pypi-uri "pep8" version))
6409 "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1"))
6410 (patches (search-patches "python-pep8-stdlib-tokenize-compat.patch"))))
6411 (build-system python-build-system)
6412 (home-page "https://pep8.readthedocs.org/")
6413 (synopsis "Python style guide checker")
6415 "This tools checks Python code against some of the style conventions in
6417 (license license:expat)))
6419 (define-public python2-pep8
6420 (package-with-python2 python-pep8))
6422 (define-public python-pyflakes
6424 (name "python-pyflakes")
6429 (uri (pypi-uri "pyflakes" version))
6432 "18pq95a1xj2dgdd0m85gyfsn40jajj4xc3lp8wfv7igqhrc86xnr"))))
6433 (build-system python-build-system)
6435 "https://github.com/pyflakes/pyflakes")
6436 (synopsis "Passive checker of Python programs")
6438 "Pyflakes statically checks Python source code for common errors.")
6439 (license license:expat)))
6441 (define-public python2-pyflakes
6442 (package-with-python2 python-pyflakes))
6444 (define-public python-mccabe
6446 (name "python-mccabe")
6451 (uri (pypi-uri "mccabe" version))
6454 "07w3p1qm44hgxf3vvwz84kswpsx6s7kvaibzrsx5dzm0hli1i3fx"))))
6455 (build-system python-build-system)
6457 `(("python-pytest" ,python-pytest-bootstrap)
6458 ("python-pytest-runner" ,python-pytest-runner)))
6459 (home-page "https://github.com/flintwork/mccabe")
6460 (synopsis "McCabe checker, plugin for flake8")
6462 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
6463 complexity of Python source code.")
6464 (license license:expat)))
6466 (define-public python2-mccabe
6467 (package-with-python2 python-mccabe))
6469 (define-public python-mccabe-0.2.1
6470 (package (inherit python-mccabe)
6475 (uri (pypi-uri "mccabe" version))
6478 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))))
6480 (define-public python2-mccabe-0.2.1
6481 (package-with-python2 python-mccabe-0.2.1))
6483 ;; Flake8 2.4.1 requires an older version of pep8.
6484 ;; This should be removed ASAP.
6485 (define-public python-pep8-1.5.7
6486 (package (inherit python-pep8)
6491 (uri (pypi-uri "pep8" version))
6494 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))
6496 ;; XXX Tests not compatible with Python 3.5.
6499 (define-public python2-pep8-1.5.7
6500 (package-with-python2 python-pep8-1.5.7))
6502 ;; Flake8 2.4.1 requires an older version of pyflakes.
6503 ;; This should be removed ASAP.
6504 (define-public python-pyflakes-0.8.1
6505 (package (inherit python-pyflakes)
6510 (uri (pypi-uri "pyflakes" version))
6513 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))
6515 ;; XXX Tests not compatible with Python 3.5.
6518 (define-public python2-pyflakes-0.8.1
6519 (package-with-python2 python-pyflakes-0.8.1))
6521 (define-public python-flake8
6523 (name "python-flake8")
6527 (uri (pypi-uri "flake8" version))
6530 "0qg6zggqigrd4k3gv88shd1a27d0cwgfql8vfiq2c7rl7w3rd6c5"))))
6531 (build-system python-build-system)
6534 (modify-phases %standard-phases
6536 (add-after 'install 'check
6537 (lambda* (#:key inputs outputs #:allow-other-keys)
6538 (add-installed-pythonpath inputs outputs)
6539 (invoke "pytest" "-v")
6542 `(("python-pycodestyle" ,python-pycodestyle)
6543 ("python-entrypoints" ,python-entrypoints)
6544 ("python-pyflakes" ,python-pyflakes)
6545 ("python-mccabe" ,python-mccabe)))
6547 `(("python-mock" ,python-mock)
6548 ("python-pytest" ,python-pytest-bootstrap)
6549 ("python-pytest-runner" ,python-pytest-runner)))
6550 (home-page "https://gitlab.com/pycqa/flake8")
6552 "The modular source code checker: pep8, pyflakes and co")
6554 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
6555 (properties `((python2-variant . ,(delay python2-flake8))))
6556 (license license:expat)))
6558 (define-public python2-flake8
6559 (let ((base (package-with-python2 (strip-python2-variant python-flake8))))
6560 (package (inherit base)
6562 `(("python2-configparser" ,python2-configparser)
6563 ("python2-enum34" ,python2-enum34)
6564 ("python2-typing" ,python2-typing)
6565 ,@(package-propagated-inputs base))))))
6567 ;; python-hacking requires flake8 <2.6.0.
6568 (define-public python-flake8-2.5
6570 (inherit python-flake8)
6574 (uri (pypi-uri "flake8" version))
6577 "1snylqwbmrylbx3r1wpz8ggk98f6bcag4441ag8mm2l7wyn58sij"))))
6579 `(("python-pep8" ,python-pep8)
6580 ,@(package-propagated-inputs python-flake8)))
6581 (properties `((python2-variant . ,(delay python2-flake8-2.5))))))
6583 (define-public python2-flake8-2.5
6585 (inherit python2-flake8)
6586 (version (package-version python-flake8-2.5))
6588 (inherit (package-source python-flake8-2.5))))
6590 `(("python2-pep8" ,python2-pep8)
6591 ,@(package-propagated-inputs python2-flake8)))))
6593 (define-public python-flake8-polyfill
6595 (name "python-flake8-polyfill")
6600 (uri (pypi-uri "flake8-polyfill" version))
6603 "1nlf1mkqw856vi6782qcglqhaacb23khk9wkcgn55npnjxshhjz4"))))
6604 (build-system python-build-system)
6607 (modify-phases %standard-phases
6610 ;; Be compatible with Pytest 4:
6611 ;; https://gitlab.com/pycqa/flake8-polyfill/merge_requests/7
6612 (substitute* "setup.cfg"
6616 (setenv "PYTHONPATH"
6617 (string-append (getcwd) "/build/lib:"
6618 (getenv "PYTHONPATH")))
6619 (invoke "py.test" "-v"))))))
6621 `(("python-flake8" ,python-flake8)
6622 ("python-mock" ,python-mock)
6623 ("python-pep8" ,python-pep8)
6624 ("python-pycodestyle" ,python-pycodestyle)
6625 ("python-pytest" ,python-pytest)))
6626 (home-page "https://gitlab.com/pycqa/flake8-polyfill")
6627 (synopsis "Polyfill package for Flake8 plugins")
6629 "This package that provides some compatibility helpers for Flake8
6630 plugins that intend to support Flake8 2.x and 3.x simultaneously.")
6631 (license license:expat)))
6633 (define-public python2-flake8-polyfill
6634 (package-with-python2 python-flake8-polyfill))
6636 (define-public python-mistune
6638 (name "python-mistune")
6643 (uri (pypi-uri "mistune" version))
6646 "0vkmsh0x480rni51lhyvigfdf06b9247z868pk3bal1wnnfl58sr"))))
6647 (build-system python-build-system)
6649 `(("python-nose" ,python-nose)
6650 ("python-cython" ,python-cython)))
6651 (home-page "https://github.com/lepture/mistune")
6652 (synopsis "Markdown parser in pure Python")
6653 (description "This package provides a fast markdown parser in pure
6655 (license license:bsd-3)))
6657 (define-public python2-mistune
6658 (package-with-python2 python-mistune))
6660 (define-public python-markdown
6662 (name "python-markdown")
6667 (uri (pypi-uri "Markdown" version))
6670 "0yhylk4ffqqs7x086fav4pnfsl1021v7lghznzkififprmmqfl1f"))))
6671 (build-system python-build-system)
6673 `(("python-nose" ,python-nose)
6674 ("python-pyyaml" ,python-pyyaml)))
6675 (home-page "https://python-markdown.github.io/")
6676 (synopsis "Python implementation of Markdown")
6678 "This package provides a Python implementation of John Gruber's
6679 Markdown. The library features international input, various Markdown
6680 extensions, and several HTML output formats. A command line wrapper
6681 markdown_py is also provided to convert Markdown files to HTML.")
6682 (license license:bsd-3)))
6684 (define-public python2-markdown
6685 (package-with-python2 python-markdown))
6687 (define-public python-ptyprocess
6689 (name "python-ptyprocess")
6694 (uri (pypi-uri "ptyprocess" version))
6697 "0ra31k10v3629xq0kdn8lwmfbi97anmk48r03yvh7mks0kq96hg6"))))
6698 (build-system python-build-system)
6700 `(("python-nose" ,python-nose)))
6703 (modify-phases %standard-phases
6705 (lambda _ (invoke "nosetests"))))))
6706 (home-page "https://github.com/pexpect/ptyprocess")
6707 (synopsis "Run a subprocess in a pseudo terminal")
6709 "This package provides a Python library used to launch a subprocess in a
6710 pseudo terminal (pty), and interact with both the process and its pty.")
6711 (license license:isc)))
6713 (define-public python2-ptyprocess
6714 (package-with-python2 python-ptyprocess))
6716 (define-public python-cram
6718 (name "python-cram")
6720 (home-page "https://bitheap.org/cram/")
6723 (uri (list (string-append home-page "cram-"
6725 (pypi-uri "cram" version)))
6728 "0bvz6fwdi55rkrz3f50zsy35gvvwhlppki2yml5bj5ffy9d499vx"))))
6731 (modify-phases %standard-phases
6732 (add-after 'unpack 'patch-source
6734 (substitute* (find-files "cram" ".*\\.py$")
6735 ;; Replace default shell path.
6736 (("/bin/sh") (which "sh")))
6737 (substitute* (find-files "tests" ".*\\.t$")
6739 (("/bin/bash") (which "bash"))
6740 (("/bin/sh") (which "sh")))
6741 (substitute* "cram/_test.py"
6742 ;; This hack works around a bug triggered by substituting
6743 ;; the /bin/sh paths. "tests/usage.t" compares the output of
6744 ;; "cram -h", which breaks the output at 80 characters. This
6745 ;; causes the line showing the default shell to break into two
6746 ;; lines, but the test expects a single line...
6747 (("env\\['COLUMNS'\\] = '80'")
6748 "env['COLUMNS'] = '160'"))
6750 (substitute* "Makefile"
6751 ;; Recent versions of python-coverage have caused the test
6752 ;; coverage to decrease (as of version 0.7). Allow that.
6753 (("--fail-under=100")
6758 ;; The test phase uses the built library and executable.
6759 (lambda* (#:key inputs outputs #:allow-other-keys)
6760 (add-installed-pythonpath inputs outputs)
6761 (setenv "PATH" (string-append (getenv "PATH") ":"
6762 (assoc-ref outputs "out") "/bin"))
6763 (invoke "make" "test"))))))
6764 (build-system python-build-system)
6766 `(("python-coverage" ,python-coverage)
6768 (synopsis "Simple testing framework for command line applications")
6770 "Cram is a functional testing framework for command line applications.
6771 Cram tests look like snippets of interactive shell sessions. Cram runs each
6772 command and compares the command output in the test with the command’s actual
6774 (license license:gpl2+)))
6776 (define-public python2-cram
6777 (package-with-python2 python-cram))
6779 (define-public python-straight-plugin
6781 (name "python-straight-plugin")
6786 (uri (pypi-uri "straight.plugin" version))
6789 "069pjll4383p4kkgvcc40hgyvf79j2wdbpgwz77yigzxksh1gj62"))))
6790 (build-system python-build-system)
6791 (home-page "https://github.com/ironfroggy/straight.plugin")
6792 (synopsis "Simple namespaced plugin facility")
6793 (description "Straight Plugin provides a type of plugin you can create from
6794 almost any existing Python modules, and an easy way for outside developers to
6795 add functionality and customization to your projects with their own plugins.")
6796 (license license:expat)))
6798 (define-public python2-straight-plugin
6799 (package-with-python2 python-straight-plugin))
6801 (define-public python-fonttools
6803 (name "python-fonttools")
6807 (uri (pypi-uri "fonttools" version ".zip"))
6810 "12ripk3s7skgxr1bs9r8n13r94ym3s8iir7ivfixls9fa4dabmlh"))))
6811 (build-system python-build-system)
6814 ("python-pytest" ,python-pytest)
6815 ("python-pytest-runner" ,python-pytest-runner)))
6816 (home-page "https://github.com/fonttools/fonttools")
6817 (synopsis "Tools to manipulate font files")
6819 "FontTools/TTX is a library to manipulate font files from Python. It
6820 supports reading and writing of TrueType/OpenType fonts, reading and writing
6821 of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
6822 also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
6823 from an XML-based format.")
6824 (license license:expat)))
6826 (define-public python2-fonttools
6827 (package-with-python2 python-fonttools))
6829 (define-public python-ly
6836 (uri (pypi-uri name version))
6839 "0x98dv7p8mg26p4816yy8hz4f34zf6hpnnfmr56msgh9jnsm2qfl"))))
6840 (build-system python-build-system)
6842 ;; FIXME: Some tests need network access.
6844 (synopsis "Tool and library for manipulating LilyPond files")
6845 (description "This package provides a Python library to parse, manipulate
6846 or create documents in LilyPond format. A command line program ly is also
6847 provided that can be used to do various manipulations with LilyPond files.")
6848 (home-page "https://pypi.python.org/pypi/python-ly")
6849 (license license:gpl2+)))
6851 (define-public python-appdirs
6853 (name "python-appdirs")
6858 (uri (pypi-uri "appdirs" version))
6861 "14id6wxi12lgyw0mg3bcfnf888ad07jz9yj46gfzhn186z8rcn4y"))))
6862 (build-system python-build-system)
6863 (home-page "https://github.com/ActiveState/appdirs")
6865 "Determine platform-specific dirs, e.g. a \"user data dir\"")
6867 "This module provides a portable way of finding out where user data
6868 should be stored on various operating systems.")
6869 (license license:expat)))
6871 (define-public python2-appdirs
6872 (package-with-python2 python-appdirs))
6874 (define-public python-llfuse
6876 (name "python-llfuse")
6880 (uri (pypi-uri "llfuse" version ".tar.bz2"))
6883 "1n7a90jww3ly49fm7x27m3xw3la3qfrnykcakga654g6kcyjlhbf"))))
6884 (build-system python-build-system)
6889 `(("pkg-config" ,pkg-config)))
6890 (synopsis "Python bindings for FUSE")
6892 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
6893 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
6894 (license license:lgpl2.0+)
6895 (properties `((python2-variant . ,(delay python2-llfuse))))))
6897 (define-public python2-llfuse
6898 (package (inherit (package-with-python2
6899 (strip-python2-variant python-llfuse)))
6900 (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2)))))
6903 (define-public python-llfuse-0.41
6904 (package (inherit python-llfuse)
6909 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
6910 "llfuse-" version ".tar.bz2"))
6913 "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa"))))
6914 ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat)
6915 ;; licensed. The rest of the package is licensed under LGPL2.0 or later.
6916 (license (list license:expat license:lgpl2.0+))))
6918 (define-public python-msgpack
6920 (name "python-msgpack")
6924 (uri (pypi-uri "msgpack" version))
6927 "1hz2dba1nvvn52afg34liijsm7kn65cmn06dl0xbwld6bb4cis0f"))))
6928 (build-system python-build-system)
6930 `(#:modules ((guix build utils)
6931 (guix build python-build-system)
6936 (modify-phases %standard-phases
6939 (let ((cwd (getcwd)))
6940 (setenv "PYTHONPATH"
6941 (string-append cwd "/build/"
6942 (find (cut string-prefix? "lib" <>)
6943 (scandir (string-append cwd "/build")))
6945 (getenv "PYTHONPATH")))
6946 (invoke "pytest" "-v" "test")))))))
6948 `(("python-pytest" ,python-pytest)))
6949 (synopsis "MessagePack (de)serializer")
6950 (description "MessagePack is a fast, compact binary serialization format,
6951 suitable for similar data to JSON. This package provides CPython bindings for
6952 reading and writing MessagePack data.")
6953 (home-page "https://pypi.python.org/pypi/msgpack/")
6954 (license license:asl2.0)))
6956 ;; This msgpack library's name changed from "python-msgpack" to "msgpack" with
6957 ;; release 0.5. Some packages like borg still call it by the old name for now.
6958 ;; <https://bugs.gnu.org/30662>
6959 (define-public python-msgpack-transitional
6961 (inherit python-msgpack)
6962 (name "python-msgpack-transitional")
6964 (substitute-keyword-arguments (package-arguments python-msgpack)
6966 `(modify-phases ,phases
6967 (add-after 'unpack 'configure-transitional
6969 ;; Keep using the old name.
6970 (substitute* "setup.py"
6971 (("TRANSITIONAL = False")
6972 "TRANSITIONAL = 1"))
6975 (define-public python2-msgpack
6976 (package-with-python2 python-msgpack))
6978 (define-public python-netaddr
6980 (name "python-netaddr")
6985 (uri (pypi-uri "netaddr" version))
6988 "1zdfadvpq4lmcqzr383gywxn4xyn355kj1n3lk9q2l03vmyfrbiq"))))
6989 (build-system python-build-system)
6990 (arguments `(#:tests? #f)) ;; No tests.
6991 (home-page "https://github.com/drkjam/netaddr/")
6992 (synopsis "Pythonic manipulation of network addresses")
6994 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
6995 and MAC network addresses.")
6996 (license license:bsd-3)))
6998 (define-public python2-netaddr
6999 (package-with-python2 python-netaddr))
7001 (define-public python2-pyroute2
7003 (name "python2-pyroute2")
7008 (uri (pypi-uri "pyroute2" version))
7011 "1gmz4r1w0yzj6fjjypnalmfyy0lnfznydyn62gi3wk50j5hhxbny"))))
7012 (build-system python-build-system)
7014 `(#:python ,python-2)) ;Python 3.x is not supported
7015 (home-page "https://github.com/svinota/pyroute2")
7016 (synopsis "Python netlink library")
7018 "Pyroute2 is a pure Python netlink library with minimal dependencies.
7019 Supported netlink families and protocols include:
7021 @item rtnl, network settings - addresses, routes, traffic controls
7022 @item nfnetlink - netfilter API: ipset, nftables, ...
7023 @item ipq - simplest userspace packet filtering, iptables QUEUE target
7024 @item devlink - manage and monitor devlink-enabled hardware
7025 @item generic - generic netlink families
7027 @item nl80211 - wireless functions API (basic support)
7028 @item taskstats - extended process statistics
7029 @item acpi_events - ACPI events monitoring
7030 @item thermal_events - thermal events monitoring
7031 @item VFS_DQUOT - disk quota events monitoring
7034 (license license:gpl2+)))
7036 (define-public python-wrapt
7038 (name "python-wrapt")
7043 (uri (pypi-uri "wrapt" version))
7046 "1q81762dgsgrd12f8qc39zk8s5wll3m5xc32jdmlf6cls4gh4njn"))))
7047 (build-system python-build-system)
7049 ;; Tests are not included in the tarball, they are only available in the
7052 (home-page "https://github.com/GrahamDumpleton/wrapt")
7053 (synopsis "Module for decorators, wrappers and monkey patching")
7055 "The aim of the wrapt module is to provide a transparent object proxy for
7056 Python, which can be used as the basis for the construction of function
7057 wrappers and decorator functions.")
7058 (license license:bsd-2)))
7060 (define-public python2-wrapt
7061 (package-with-python2 python-wrapt))
7063 (define-public python-xlrd
7065 (name "python-xlrd")
7069 (uri (pypi-uri "xlrd" version))
7072 "1ci93fda4n67qhdvfl16zasyxrpygzk53hs6m8z0rd4dxrnb6vjl"))))
7073 (build-system python-build-system)
7076 (modify-phases %standard-phases
7077 ;; Some tests depend on writing a temporary file to the user's home
7079 (add-after 'unpack 'fix-tests
7081 (delete-file "tests/test_open_workbook.py")
7083 (home-page "http://www.python-excel.org/")
7084 (synopsis "Library for extracting data from Excel files")
7085 (description "This package provides a library to extract data from
7086 spreadsheets using Microsoft Excel proprietary file formats @samp{.xls} and
7087 @samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
7088 Unicode-aware. It is not intended as an end-user tool.")
7089 (license license:bsd-3)))
7091 (define-public python2-xlrd
7092 (package-with-python2 python-xlrd))
7094 (define-public python-prettytable
7096 (name "python-prettytable")
7101 (uri (pypi-uri "prettytable" version ".tar.bz2"))
7104 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
7105 (build-system python-build-system)
7106 (home-page "http://code.google.com/p/prettytable/")
7107 (synopsis "Display tabular data in an ASCII table format")
7109 "A library designed to represent tabular data in visually appealing ASCII
7110 tables. PrettyTable allows for selection of which columns are to be printed,
7111 independent alignment of columns (left or right justified or centred) and
7112 printing of sub-tables by specifying a row range.")
7113 (license license:bsd-3)))
7115 (define-public python2-prettytable
7116 (package-with-python2 python-prettytable))
7118 (define-public python-tables
7120 (name "python-tables")
7125 (uri (pypi-uri "tables" version))
7128 "0affz7k8babh8wdmsgrz5jxrd569by2w8ffimcxs9wiaf5rw1idx"))
7129 (modules '((guix build utils)))
7132 ;; Remove pre-compiled .pyc files from source.
7133 (for-each delete-file-recursively
7134 (find-files "." "__pycache__" #:directories? #t))
7135 (for-each delete-file (find-files "." "\\.pyc$"))
7137 (build-system python-build-system)
7139 `(;; FIXME: python-build-system does not pass configure-flags to "build"
7140 ;; or "check", so we must override the build and check phases.
7142 (modify-phases %standard-phases
7143 (add-after 'unpack 'use-gcc
7145 (substitute* "setup.py"
7146 (("compiler = new_compiler\\(\\)" line)
7148 "\ncompiler.set_executables(compiler='gcc',"
7149 "compiler_so='gcc',"
7151 "linker_so='gcc -shared')")))
7154 (lambda* (#:key inputs #:allow-other-keys)
7155 (invoke "python" "setup.py" "build"
7156 (string-append "--hdf5="
7157 (assoc-ref inputs "hdf5")))))
7159 (lambda* (#:key inputs #:allow-other-keys)
7160 (invoke "python" "setup.py" "check"
7161 (string-append "--hdf5="
7162 (assoc-ref inputs "hdf5"))))))))
7164 `(("python-numexpr" ,python-numexpr)
7165 ("python-numpy" ,python-numpy)))
7167 `(("python-cython" ,python-cython)
7168 ("pkg-config" ,pkg-config)))
7173 (home-page "http://www.pytables.org/")
7174 (synopsis "Hierarchical datasets for Python")
7175 (description "PyTables is a package for managing hierarchical datasets and
7176 designed to efficiently cope with extremely large amounts of data.")
7177 (license license:bsd-3)))
7179 (define-public python2-tables
7180 (package-with-python2 python-tables))
7182 (define-public python-pyasn1
7184 (name "python-pyasn1")
7189 (uri (pypi-uri "pyasn1" version))
7192 "1z5h38anjzzrxpraa9iq9llffyx2zs8gx0q6dc1g029miwnn50gv"))))
7193 (build-system python-build-system)
7194 (home-page "http://pyasn1.sourceforge.net/")
7195 (synopsis "ASN.1 types and codecs")
7197 "This is an implementation of ASN.1 types and codecs in Python. It is
7198 suitable for a wide range of protocols based on the ASN.1 specification.")
7199 (license license:bsd-2)))
7201 (define-public python2-pyasn1
7202 (package-with-python2 python-pyasn1))
7204 (define-public python-pyasn1-modules
7206 (name "python-pyasn1-modules")
7211 (uri (pypi-uri "pyasn1-modules" version))
7214 "0ivm850yi7ajjbi8j115qpsj95bgxdsx48nbjzg0zip788c3xkx0"))))
7215 (build-system python-build-system)
7217 `(("python-pyasn1" ,python-pyasn1)))
7218 (home-page "https://sourceforge.net/projects/pyasn1/")
7219 (synopsis "ASN.1 codec implementations")
7221 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
7222 implementations of ASN.1-based codecs and protocols.")
7223 (license license:bsd-3)))
7225 (define-public python2-pyasn1-modules
7226 (package-with-python2 python-pyasn1-modules))
7228 (define-public python-ipaddress
7230 (name "python-ipaddress")
7234 (uri (pypi-uri "ipaddress" version))
7237 "0b570bm6xqpjwqis15pvdy6lyvvzfndjvkynilcddjj5x98wfimi"))))
7238 (build-system python-build-system)
7239 (home-page "https://github.com/phihag/ipaddress")
7240 (synopsis "IP address manipulation library")
7242 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
7243 in Python. This library is used to create, poke at, and manipulate IPv4 and
7244 IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
7245 module to older versions of Python.")
7246 (license license:psfl)))
7248 (define-public python2-ipaddress
7249 (package-with-python2 python-ipaddress))
7251 (define-public python2-ipaddr
7253 (name "python2-ipaddr")
7258 (uri (pypi-uri "ipaddr" version))
7260 (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v"))))
7261 (build-system python-build-system)
7263 `(#:python ,python-2 ;version 2 only
7265 (modify-phases %standard-phases
7267 (lambda _ (invoke "python" "ipaddr_test.py"))))))
7268 (home-page "https://github.com/google/ipaddr-py")
7269 (synopsis "IP address manipulation library")
7271 "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and
7272 IPv6 addresses and networks.
7274 For new implementations you may prefer to use the standard module
7275 @code{ipaddress}, which was introduced in Python 3.3 and backported to older
7276 versions of Python.")
7277 (license license:asl2.0)))
7279 (define-public python-idna
7281 (name "python-idna")
7286 (uri (pypi-uri "idna" version))
7289 "01rlkigdxg17sf9yar1jl8n18ls59367wqh59hnawlyg53vb6my3"))))
7290 (build-system python-build-system)
7291 (home-page "https://github.com/kjd/idna")
7292 (synopsis "Internationalized domain names in applications")
7294 "This is a library to support the Internationalised Domain Names in
7295 Applications (IDNA) protocol as specified in RFC 5891. This version of the
7296 protocol is often referred to as “IDNA2008” and can produce different results
7297 from the earlier standard from 2003. The library is also intended to act as a
7298 suitable drop-in replacement for the “encodings.idna” module that comes with
7299 the Python standard library but currently only supports the older 2003
7301 (license license:bsd-4)))
7303 (define-public python-idna-2.7
7304 (package (inherit python-idna)
7308 (uri (pypi-uri "idna" version))
7311 "05jam7d31767dr12x0rbvvs8lxnpb1mhdb2zdlfxgh83z6k3hjk8"))))))
7314 (define-public python2-idna
7315 (package-with-python2 python-idna))
7317 (define-public python-idna-ssl
7319 (name "python-idna-ssl")
7324 (uri (pypi-uri "idna-ssl" version))
7327 "0ydrc8hpg9mdr5hqq1lqfsfbn6sjq69slwpfrnlrm3k0phqg14qj"))))
7328 (build-system python-build-system)
7330 `(#:tests? #f)) ;circular dependency with python-aiohttp
7331 (home-page "https://github.com/aio-libs/idna-ssl")
7332 (synopsis "Patch @code{ssl.match_hostname} for Unicode(idna) domains support")
7333 (description "Patch @code{ssl.match_hostname} for Unicode(idna)
7335 (license license:expat)))
7337 (define-public python-pretend
7339 (name "python-pretend")
7344 (uri (pypi-uri "pretend" version))
7347 "040vm94lcbscg5p81g1icmwwwa2jm7wrd1ybmxnv1sz8rl8bh3n9"))))
7348 (build-system python-build-system)
7349 (home-page "https://github.com/alex/pretend")
7350 (synopsis "Library for stubbing in Python")
7352 "Pretend is a library to make stubbing with Python easier. Stubbing is a
7353 technique for writing tests. You may hear the term mixed up with mocks,
7354 fakes, or doubles. Basically, a stub is an object that returns pre-canned
7355 responses, rather than doing any computation.")
7356 (license license:bsd-3)))
7358 (define-public python2-pretend
7359 (package-with-python2 python-pretend))
7361 (define-public python-pip
7368 (uri (pypi-uri "pip" version))
7371 "100sd12ss4mbdj5lf3wawad29cm573b27765mq098x6xhcj71395"))))
7372 (build-system python-build-system)
7374 '(#:tests? #f)) ; there are no tests in the pypi archive.
7375 (home-page "https://pip.pypa.io/")
7376 (synopsis "Package manager for Python software")
7378 "Pip is a package manager for Python software, that finds packages on the
7379 Python Package Index (PyPI).")
7380 (license license:expat)))
7382 (define-public python2-pip
7383 (package-with-python2 python-pip))
7385 (define-public python-tlsh
7387 (name "python-tlsh")
7389 (home-page "https://github.com/trendmicro/tlsh")
7394 (url "https://github.com/trendmicro/tlsh.git")
7395 (commit (string-append "v" version))))
7396 (file-name (git-file-name name version))
7398 (base32 "1ydliir308xn4ywy705mmsh7863ldlixdvpqwdhbipzq9vfpmvll"))))
7399 (build-system cmake-build-system)
7401 '(#:out-of-source? #f
7402 #:phases (modify-phases %standard-phases
7405 (lambda* (#:key outputs #:allow-other-keys)
7406 ;; Build and install the Python bindings. The underlying
7407 ;; C++ library is apparently not meant to be installed.
7408 (let ((out (assoc-ref outputs "out")))
7409 (with-directory-excursion "py_ext"
7410 (and (system* "python" "setup.py" "build")
7411 (system* "python" "setup.py" "install"
7412 (string-append "--prefix=" out))))))))))
7413 (inputs `(("python" ,python-wrapper))) ;for the bindings
7414 (synopsis "Fuzzy matching library for Python")
7416 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
7417 Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
7418 value which can be used for similarity comparisons. Similar objects have
7419 similar hash values, which allows for the detection of similar objects by
7420 comparing their hash values. The byte stream should have a sufficient amount
7421 of complexity; for example, a byte stream of identical bytes will not generate
7423 (license license:asl2.0)))
7425 (define-public python2-tlsh
7427 (inherit python-tlsh)
7428 (name "python2-tlsh")
7429 (inputs `(("python" ,python-2)))))
7431 (define-public python-termcolor
7433 (name "python-termcolor")
7438 (uri (pypi-uri "termcolor" version))
7441 "0fv1vq14rpqwgazxg4981904lfyp84mnammw7y046491cv76jv8x"))))
7442 (build-system python-build-system)
7444 ;; There are no tests.
7446 (home-page "https://pypi.python.org/pypi/termcolor")
7447 (synopsis "ANSII Color formatting for terminal output")
7449 "This package provides ANSII Color formatting for output in terminals.")
7450 (license license:expat)))
7452 (define-public python2-termcolor
7453 (package-with-python2 python-termcolor))
7455 (define-public python-libarchive-c
7457 (name "python-libarchive-c")
7461 (uri (pypi-uri "libarchive-c" version))
7464 "0qg0v1s9c1xdk9philhnv8k6c6nicvnvfwlc0j9srg90jmdlvm06"))))
7465 (build-system python-build-system)
7467 '(#:phases (modify-phases %standard-phases
7469 'build 'reference-libarchive
7470 (lambda* (#:key inputs #:allow-other-keys)
7471 ;; Retain the absolute file name of libarchive.so.
7472 (let ((libarchive (assoc-ref inputs "libarchive")))
7473 (substitute* "libarchive/ffi.py"
7474 (("find_library\\('archive'\\)")
7475 (string-append "'" libarchive
7476 "/lib/libarchive.so'"))))))
7478 (lambda _ (invoke "pytest" "-vv"))))))
7480 `(("python-mock" ,python-mock)
7481 ("python-pytest" ,python-pytest)))
7483 `(("libarchive" ,libarchive)))
7484 (home-page "https://github.com/Changaco/python-libarchive-c")
7485 (synopsis "Python interface to libarchive")
7487 "This package provides Python bindings to libarchive, a C library to
7488 access possibly compressed archives in many different formats. It uses
7489 Python's @code{ctypes} foreign function interface (FFI).")
7490 (license license:lgpl2.0+)))
7492 (define-public python2-libarchive-c
7493 (package-with-python2 python-libarchive-c))
7495 (define-public python-file
7498 (name "python-file")
7499 (build-system python-build-system)
7501 '(#:tests? #f ;no tests
7502 #:configure-flags '("--single-version-externally-managed" "--root=/")
7503 #:phases (modify-phases %standard-phases
7504 (add-before 'build 'change-directory
7508 (add-before 'build 'set-library-file-name
7509 (lambda* (#:key inputs #:allow-other-keys)
7510 (let ((file (assoc-ref inputs "file")))
7511 (substitute* "magic.py"
7512 (("find_library\\('magic'\\)")
7513 (string-append "'" file "/lib/libmagic.so'")))
7515 (inputs `(("file" ,file)))
7516 (native-inputs (if (%current-target-system)
7517 `(("self" ,this-package))
7519 (synopsis "Python bindings to the libmagic file type guesser. Note that
7520 this module and the python-magic module both provide a \"magic.py\" file;
7521 these two modules, which are different and were developed separately, both
7522 serve the same purpose: provide Python bindings for libmagic.")))
7524 (define-public python2-file
7525 (package-with-python2 python-file))
7527 (define-public python-debian
7529 (name "python-debian")
7530 (home-page "https://salsa.debian.org/python-debian-team/python-debian")
7534 ;; Use git-fetch, as pypi doesn't include test suite.
7539 (file-name (git-file-name name version))
7542 "0qy6x28bj6yfikhjww932v5xq4mf5bm1iczl7acy4c7zm6mwhqfa"))))
7543 (build-system python-build-system)
7545 `(#:phases (modify-phases %standard-phases
7546 (add-after 'unpack 'remove-debian-specific-tests
7547 ;; python-apt, apt and dpkg are not yet available in guix,
7548 ;; and these tests heavily depend on them.
7550 (delete-file "lib/debian/tests/test_deb822.py")
7551 (delete-file "lib/debian/tests/test_debfile.py")
7554 `(("python-six" ,python-six)
7555 ("python-chardet" ,python-chardet)))
7556 (synopsis "Debian package related modules")
7558 ;; XXX: Use @enumerate instead of @itemize to work around
7559 ;; <http://bugs.gnu.org/21772>.
7560 "This package provides Python modules that abstract many formats of
7561 Debian-related files, such as:
7564 @item Debtags information;
7565 @item @file{debian/changelog} files;
7566 @item packages files, pdiffs;
7567 @item control files of single or multiple RFC822-style paragraphs---e.g.
7568 @file{debian/control}, @file{.changes}, @file{.dsc};
7569 @item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
7570 contained files and meta-information.
7573 ;; Modules are either GPLv2+ or GPLv3+.
7574 (license license:gpl3+)))
7576 (define-public python2-debian
7577 (package-with-python2 python-debian))
7579 (define-public python-nbformat
7581 (name "python-nbformat")
7586 (uri (pypi-uri "nbformat" version))
7589 "00nlf08h8yc4q73nphfvfhxrcnilaqanb8z0mdy6nxk0vzq4wjgp"))))
7590 (build-system python-build-system)
7591 (arguments `(#:tests? #f)) ; no test target
7593 `(("python-ipython-genutils" ,python-ipython-genutils)
7594 ("python-jsonschema" ,python-jsonschema)
7595 ("python-jupyter-core" ,python-jupyter-core)
7596 ("python-traitlets" ,python-traitlets)))
7597 (home-page "http://jupyter.org")
7598 (synopsis "Jupyter Notebook format")
7599 (description "This package provides the reference implementation of the
7600 Jupyter Notebook format and Python APIs for working with notebooks.")
7601 (license license:bsd-3)))
7603 (define-public python2-nbformat
7604 (package-with-python2 python-nbformat))
7606 (define-public python-bleach
7608 (name "python-bleach")
7613 (uri (pypi-uri "bleach" version))
7616 "1yhrgrhkln8bd6gn3imj69g1h4xqah9gaz9q26crqr6gmmvpzprz"))))
7617 (build-system python-build-system)
7619 `(("python-webencodings" ,python-webencodings)
7620 ("python-six" ,python-six)))
7622 `(("python-pytest" ,python-pytest)
7623 ("python-pytest-runner" ,python-pytest-runner-2)))
7624 (home-page "https://github.com/jsocol/bleach")
7625 (synopsis "Whitelist-based HTML-sanitizing tool")
7626 (description "Bleach is an easy whitelist-based HTML-sanitizing tool.")
7627 (license license:asl2.0)))
7629 (define-public python2-bleach
7630 (package-with-python2 python-bleach))
7632 (define-public python-entrypoints
7634 (name "python-entrypoints")
7639 (uri (pypi-uri "entrypoints" version))
7642 "0lc4si3xb7hza424414rdqdc3vng3kcrph8jbvjqb32spqddf3f7"))))
7643 (build-system python-build-system)
7644 ;; The package does not come with a setup.py file, so we have to generate
7649 (modify-phases %standard-phases
7650 (add-after 'unpack 'create-setup.py
7652 (call-with-output-file "setup.py"
7655 from setuptools import setup
7656 setup(name='entrypoints', version='~a', py_modules=['entrypoints'])
7658 (home-page "https://github.com/takluyver/entrypoints")
7659 (synopsis "Discover and load entry points from installed Python packages")
7660 (description "Entry points are a way for Python packages to advertise
7661 objects with some common interface. The most common examples are
7662 @code{console_scripts} entry points, which define shell commands by
7663 identifying a Python function to run. The @code{entrypoints} module contains
7664 functions to find and load entry points.")
7665 (license license:expat)))
7667 (define-public python2-entrypoints
7668 (package-with-python2 python-entrypoints))
7670 (define-public python-nbconvert
7672 (name "python-nbconvert")
7677 (uri (pypi-uri "nbconvert" version))
7680 "0brclbb18l4nmd5qy3dl9wn05rjdh1fz4rmzdlfqacj12rcdvdgp"))))
7681 (build-system python-build-system)
7683 `(;; The "bdist_egg" target is disabled by default, causing the installation
7685 #:configure-flags (list "bdist_egg")
7686 ;; FIXME: 5 failures, 40 errors.
7689 ;; (modify-phases %standard-phases
7692 ;; (zero? (system* "py.test" "-v")))))
7694 `(("python-pytest" ,python-pytest)))
7696 `(("python-bleach" ,python-bleach)
7697 ("python-entrypoints" ,python-entrypoints)
7698 ("python-jinja2" ,python-jinja2)
7699 ("python-jupyter-core" ,python-jupyter-core)
7700 ("python-mistune" ,python-mistune)
7701 ("python-nbformat" ,python-nbformat)
7702 ("python-pygments" ,python-pygments)
7703 ("python-traitlets" ,python-traitlets)))
7704 (home-page "http://jupyter.org")
7705 (synopsis "Converting Jupyter Notebooks")
7706 (description "The @code{nbconvert} tool, @{jupyter nbconvert}, converts
7707 notebooks to various other formats via Jinja templates. It allows you to
7708 convert an @code{.ipynb} notebook file into various static formats including:
7716 @item ReStructured Text (rst)
7717 @item executable script
7719 (license license:bsd-3)))
7721 (define-public python2-nbconvert
7722 (package-with-python2 python-nbconvert))
7724 (define-public python-notebook
7726 (name "python-notebook")
7730 (uri (pypi-uri "notebook" version))
7733 "0jm7324mbxljmn9hgapj66q7swyz5ai92blmr0jpcy0h80x6f26r"))))
7734 (build-system python-build-system)
7737 (modify-phases %standard-phases
7740 ;; These tests require a browser
7741 (delete-file-recursively "notebook/tests/selenium")
7742 ;; Some tests need HOME
7743 (setenv "HOME" "/tmp")
7744 ;; This file contains "warningfilters", which are not supported
7745 ;; by this version of nose.
7746 (delete-file "setup.cfg")
7747 (with-directory-excursion "/tmp"
7748 (invoke "nosetests" "-v"))
7751 `(("python-jupyter-core" ,python-jupyter-core)
7752 ("python-nbformat" ,python-nbformat)
7753 ("python-nbconvert" ,python-nbconvert)
7754 ("python-prometheus-client" ,python-prometheus-client)
7755 ("python-send2trash" ,python-send2trash)
7756 ("python-terminado" ,python-terminado)))
7758 `(("python-nose" ,python-nose)
7759 ("python-sphinx" ,python-sphinx)
7760 ("python-requests" ,python-requests)))
7761 (home-page "http://jupyter.org/")
7762 (synopsis "Web-based notebook environment for interactive computing")
7764 "The Jupyter HTML notebook is a web-based notebook environment for
7765 interactive computing.")
7766 (properties `((python2-variant . ,(delay python2-notebook))))
7767 (license license:bsd-3)))
7769 (define-public python2-notebook
7770 (let ((base (package-with-python2
7771 (strip-python2-variant python-notebook))))
7772 (package (inherit base)
7774 `(("python2-mock" ,python2-mock)
7775 ,@(package-native-inputs base)))
7777 (substitute-keyword-arguments (package-arguments base)
7779 `(modify-phases ,phases
7780 (add-before 'check 'disable-test-case
7781 ;; The test requires network access to localhost. Curiously it
7782 ;; fails with Python 2 only. Simply make the test-case return
7786 "notebook/services/nbconvert/tests/test_nbconvert_api.py"
7787 (("formats = self.nbconvert_api") "return #")))))))))))
7789 (define-public python-widgetsnbextension
7791 (name "python-widgetsnbextension")
7796 (uri (pypi-uri "widgetsnbextension" version))
7799 "0rc2nivdy7k4m3vljx7wdh2jh11djapcgwhvzlbs0isl8gl8nqgs"))))
7800 (build-system python-build-system)
7802 `(("python-ipykernel" ,python-ipykernel)
7803 ("python-notebook" ,python-notebook)))
7805 `(("python-certifi" ,python-certifi)
7806 ("python-nose" ,python-nose)))
7807 (home-page "https://ipython.org")
7808 (synopsis "IPython HTML widgets for Jupyter")
7809 (description "This package provides interactive HTML widgets for Jupyter
7811 (license license:bsd-3)))
7813 (define-public python2-widgetsnbextension
7814 (package-with-python2 python-widgetsnbextension))
7816 (define-public python-ipywidgets
7818 (name "python-ipywidgets")
7823 (uri (pypi-uri "ipywidgets" version))
7826 "1lk0qrr5l9a0z7qkkn30hv5832whxwxymf1l576fmmad0n7hkxms"))))
7827 (build-system python-build-system)
7829 `(("python-ipython" ,python-ipython)
7830 ("python-traitlets" ,python-traitlets)
7831 ("python-widgetsnbextension" ,python-widgetsnbextension)))
7833 `(("python-nose" ,python-nose)
7834 ("python-pytest" ,python-pytest)))
7835 (home-page "https://ipython.org")
7836 (synopsis "IPython HTML widgets for Jupyter")
7837 (description "Ipywidgets are interactive HTML widgets for Jupyter
7838 notebooks and the IPython kernel. Notebooks come alive when interactive
7839 widgets are used. Users gain control of their data and can visualize changes
7841 (license license:bsd-3)))
7843 (define-public python2-ipywidgets
7844 (package-with-python2 python-ipywidgets))
7846 (define-public python-jupyter-console
7848 (name "python-jupyter-console")
7853 (uri (pypi-uri "jupyter_console" version))
7856 "1xdjw11cppf1fxvwkw2bk13ckkwas3bdah8baingn9296mvfi31h"))))
7857 (build-system python-build-system)
7859 `(("python-ipykernel" ,python-ipykernel)
7860 ("python-jupyter-client" ,python-jupyter-client)
7861 ("python-prompt-toolkit" ,python-prompt-toolkit)
7862 ("python-pygments" ,python-pygments)))
7864 `(("python-nose" ,python-nose)))
7865 (home-page "https://jupyter.org")
7866 (synopsis "Jupyter terminal console")
7867 (description "This package provides a terminal-based console frontend for
7868 Jupyter kernels. It also allows for console-based interaction with non-Python
7869 Jupyter kernels such as IJulia and IRKernel.")
7870 (license license:bsd-3)))
7872 (define-public python2-jupyter-console
7874 (name "python2-jupyter-console")
7879 (uri (pypi-uri "jupyter_console" version))
7882 "1kam1qzgwr7srhm5r6aj90di5sws4bq0jmiw15452ddamb9yspal"))))
7883 (build-system python-build-system)
7884 ;; Tests only run in an TTY.
7885 (arguments `(#:tests? #f))
7887 `(("python2-ipykernel" ,python2-ipykernel)
7888 ("python2-jupyter-client" ,python2-jupyter-client)
7889 ("python2-prompt-toolkit" ,python2-prompt-toolkit-1)
7890 ("python2-pygments" ,python2-pygments)))
7892 `(("python2-nose" ,python2-nose)))
7893 (home-page "https://jupyter.org")
7894 (synopsis "Jupyter terminal console")
7895 (description "This package provides a terminal-based console frontend for
7896 Jupyter kernels. It also allows for console-based interaction with non-Python
7897 Jupyter kernels such as IJulia and IRKernel.")
7898 (license license:bsd-3)))
7900 ;; The python-ipython and python-jupyter-console require each other. To get
7901 ;; the functionality in both packages working, strip down the
7902 ;; python-jupyter-console package when using it as an input to python-ipython.
7903 (define python-jupyter-console-minimal
7905 (inherit python-jupyter-console)
7906 (name "python-jupyter-console-minimal")
7908 (substitute-keyword-arguments
7909 (package-arguments python-jupyter-console)
7911 `(modify-phases ,phases
7912 (add-after 'install 'delete-bin
7913 (lambda* (#:key outputs #:allow-other-keys)
7914 ;; Delete the bin files, to avoid conflicts in profiles
7915 ;; where python-ipython and python-jupyter-console are
7917 (delete-file-recursively
7919 (assoc-ref outputs "out") "/bin"))))))))
7920 ;; Remove the python-ipython propagated input, to avoid the cycle
7924 (package-propagated-inputs python-jupyter-console)))))
7926 (define-public python-qtconsole
7928 (name "python-qtconsole")
7933 (uri (pypi-uri "qtconsole" version))
7936 "1b03n1ixzscm0jw97l4dq5iy4fslnqxq5bb8287xb7n2a1gs26xw"))))
7937 (build-system python-build-system)
7939 ;; XXX: Tests are disabled, because this package needs python-ipython 7,
7940 ;; but we only have the LTS version 5.x. This means that there might be
7941 ;; runtime errors, but since this is a dependency of the Jupyter package,
7942 ;; and Jupyter can be used without the qtconsole we can overlook this for
7946 (modify-phases %standard-phases
7947 (add-before 'check 'pre-check
7949 (setenv "QT_QPA_PLATFORM" "offscreen")
7952 `(("python-ipykernel" ,python-ipykernel)
7953 ("python-ipython" ,python-ipython)))
7955 `(("python-pytest" ,python-pytest)))
7956 (home-page "http://jupyter.org")
7957 (synopsis "Jupyter Qt console")
7958 (description "This package provides a Qt-based console for Jupyter with
7959 support for rich media output.")
7960 (license license:bsd-3)))
7962 (define-public python-jsbeautifier
7964 (name "python-jsbeautifier")
7966 (home-page "https://github.com/beautify-web/js-beautify")
7971 (commit (string-append "v" version))))
7972 (file-name (git-file-name name version))
7975 "0wawb070ki1axb3jc9xvsrgpji52vcfif3zmjzc3z4g98m5xw4kg"))))
7976 (build-system python-build-system)
7978 `(#:phases (modify-phases %standard-phases
7979 (add-after 'unpack 'chdir
7981 ;; The upstream Git repository contains all the code,
7982 ;; but this package only builds the python code.
7985 (add-after 'unpack 'patch-python-six-requirements
7987 (substitute* "python/setup.py"
7992 `(("python-editorconfig" ,python-editorconfig)
7993 ("python-six" ,python-six)))
7995 `(("python-pytest" ,python-pytest)))
7996 (synopsis "JavaScript unobfuscator and beautifier")
7997 (description "Beautify, unpack or deobfuscate JavaScript, leveraging
7998 popular online obfuscators.")
7999 (license license:expat)))
8001 (define-public jupyter
8008 (uri (pypi-uri "jupyter" version))
8011 "0pwf3pminkzyzgx5kcplvvbvwrrzd3baa7lmh96f647k30rlpp6r"))))
8012 (build-system python-build-system)
8013 (arguments '(#:tests? #f)) ; there are none.
8015 `(("python-ipykernel" ,python-ipykernel)
8016 ("python-ipywidgets" ,python-ipywidgets)
8017 ("python-jupyter-console" ,python-jupyter-console)
8018 ("python-nbconvert" ,python-nbconvert)
8019 ("python-notebook" ,python-notebook)
8020 ("python-qtconsole" ,python-qtconsole)))
8021 (native-search-paths
8022 (list (search-path-specification
8023 (variable "JUPYTER_PATH")
8024 (files '("share/jupyter")))))
8025 (home-page "https://jupyter.org")
8026 (synopsis "Web application for interactive documents")
8028 "The Jupyter Notebook is a web application that allows you to create and
8029 share documents that contain live code, equations, visualizations and
8030 explanatory text. Uses include: data cleaning and transformation, numerical
8031 simulation, statistical modeling, machine learning and much more.")
8032 (license license:bsd-3)))
8034 (define-public python-chardet
8036 (name "python-chardet")
8041 (uri (pypi-uri "chardet" version))
8044 "1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4"))))
8046 `(("python-hypothesis" ,python-hypothesis)
8047 ("python-pytest" ,python-pytest)
8048 ("python-pytest-runner" ,python-pytest-runner)))
8049 (build-system python-build-system)
8050 ;; XXX: Incompatible with Pytest 4: <https://github.com/chardet/chardet/issues/173>.
8051 (arguments `(#:tests? #f))
8052 (home-page "https://github.com/chardet/chardet")
8053 (synopsis "Universal encoding detector for Python 2 and 3")
8055 "This package provides @code{chardet}, a Python module that can
8056 automatically detect a wide range of file encodings.")
8057 (license license:lgpl2.1+)))
8059 (define-public python2-chardet
8060 (package-with-python2 python-chardet))
8062 (define-public python-docopt
8064 (name "python-docopt")
8069 ;; The release on PyPI does not include tests.
8071 (url "https://github.com/docopt/docopt")
8073 (file-name (git-file-name name version))
8076 "0aad9gbswnnhssin2q0m5lmpm0ahyf80ahs2zjigbn5y7fvljnd0"))))
8077 (build-system python-build-system)
8079 `(("python-pytest" ,python-pytest)))
8082 (modify-phases %standard-phases
8084 (lambda _ (invoke "py.test"))))))
8085 (home-page "http://docopt.org")
8086 (synopsis "Command-line interface description language for Python")
8087 (description "This library allows the user to define a command-line
8088 interface from a program's help message rather than specifying it
8089 programmatically with command-line parsers like @code{getopt} and
8091 (license license:expat)))
8093 (define-public python2-docopt
8094 (package-with-python2 python-docopt))
8096 (define-public python-pythondialog
8098 (name "python-pythondialog")
8103 (uri (pypi-uri "pythondialog" version))
8106 "1728ghsran47jczn9bhlnkvk5bvqmmbihabgif5h705b84r1272c"))))
8107 (build-system python-build-system)
8110 (modify-phases %standard-phases
8111 (add-after 'unpack 'patch-path
8112 (lambda* (#:key inputs #:allow-other-keys)
8113 (let* ((dialog (assoc-ref inputs "dialog")))
8114 ;; Since this library really wants to grovel the search path, we
8115 ;; must hardcode dialog's store path into it.
8116 (substitute* "dialog.py"
8117 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
8118 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
8120 #:tests? #f)) ; no test suite
8122 `(("dialog" ,dialog)))
8123 (home-page "http://pythondialog.sourceforge.net/")
8124 (synopsis "Python interface to the UNIX dialog utility")
8125 (description "A Python wrapper for the dialog utility. Its purpose is to
8126 provide an easy to use, pythonic and comprehensive Python interface to dialog.
8127 This allows one to make simple text-mode user interfaces on Unix-like systems")
8128 (license license:lgpl2.1)
8129 (properties `((python2-variant . ,(delay python2-pythondialog))))))
8131 (define-public python2-pythondialog
8132 (let ((base (package-with-python2 (strip-python2-variant python-pythondialog))))
8135 (version (package-version python-pythondialog))
8138 (uri (pypi-uri "python2-pythondialog" version))
8141 "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9")))))))
8143 (define-public python-configobj
8145 (name "python-configobj")
8149 (uri (pypi-uri "configobj" version))
8152 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
8153 ;; Patch setup.py so it looks for python-setuptools, which is
8154 ;; required to parse the keyword 'install_requires' in setup.py.
8155 (patches (search-patches "python-configobj-setuptools.patch"))))
8156 (build-system python-build-system)
8158 `(("python-six" ,python-six)))
8159 (synopsis "Config file reading, writing and validation")
8160 (description "ConfigObj is a simple but powerful config file reader and
8161 writer: an ini file round tripper. Its main feature is that it is very easy to
8162 use, with a straightforward programmer’s interface and a simple syntax for
8164 (home-page "https://github.com/DiffSK/configobj")
8165 (license license:bsd-3)))
8167 (define-public python2-configobj
8168 (package-with-python2 python-configobj))
8170 (define-public python-configargparse
8172 (name "python-configargparse")
8176 (uri (pypi-uri "ConfigArgParse" version))
8179 "149fy4zya0rsnlkvxbbq43cyr8lscb5k4pj1m6n7f1grwcmzwbif"))))
8180 (build-system python-build-system)
8182 `(("python-pyyaml" ,python-pyyaml)))
8185 (modify-phases %standard-phases
8188 ;; Bypass setuptools-shim because one test relies on "setup.py"
8189 ;; being the first argument passed to the python call.
8191 ;; NOTE: Many tests do not run because they rely on Python's
8192 ;; built-in test.test_argparse, but we remove the unit tests from
8193 ;; our Python installation.
8194 (invoke "python" "setup.py" "test"))))))
8195 (synopsis "Replacement for argparse")
8196 (description "A drop-in replacement for argparse that allows options to also
8197 be set via config files and/or environment variables.")
8198 (home-page "https://github.com/bw2/ConfigArgParse")
8199 (license license:expat)))
8201 (define-public python2-configargparse
8202 (package-with-python2 python-configargparse))
8204 (define-public python-argparse-manpage
8206 (name "python-argparse-manpage")
8211 (uri (pypi-uri "argparse-manpage" version))
8214 "0blh31zns68anina9lba5wh81d1414s97p60zw5l0d0shhh0wj5p"))))
8215 (build-system python-build-system)
8216 (home-page "https://github.com/praiskup/argparse-manpage")
8217 (synopsis "Build manual page from Python's ArgumentParser object")
8219 "This package provides tools to build manual pages from Python's
8220 @code{ArgumentParser} object.")
8221 (license license:asl2.0)))
8223 (define-public python-contextlib2
8225 (name "python-contextlib2")
8230 (uri (pypi-uri "contextlib2" version))
8233 "0j6ad6lwwyc9kv71skj098v5l7x5biyj2hs4lc5x1kcixqcr97sh"))))
8234 (build-system python-build-system)
8235 (home-page "http://contextlib2.readthedocs.org/")
8236 (synopsis "Tools for decorators and context managers")
8237 (description "This module is primarily a backport of the Python
8238 3.2 contextlib to earlier Python versions. Like contextlib, it
8239 provides utilities for common tasks involving decorators and context
8240 managers. It also contains additional features that are not part of
8241 the standard library.")
8242 (properties `((python2-variant . ,(delay python2-contextlib2))))
8243 (license license:psfl)))
8245 (define-public python2-contextlib2
8246 (let ((base (package-with-python2
8247 (strip-python2-variant python-contextlib2))))
8251 (substitute-keyword-arguments (package-arguments base)
8253 `(modify-phases ,phases
8255 (lambda _ (invoke "python" "test_contextlib2.py" "-v")))))))
8257 `(("python2-unittest2" ,python2-unittest2))))))
8259 (define-public python-texttable
8261 (name "python-texttable")
8266 (uri (pypi-uri "texttable" version))
8269 "0yawv64c0zbawwv6zz84whb32fnb2n9jylwjcfsrcdgh7xvl340i"))))
8270 (build-system python-build-system)
8271 (arguments '(#:tests? #f)) ; no tests
8272 (home-page "https://github.com/foutaise/texttable/")
8273 (synopsis "Python module for creating simple ASCII tables")
8274 (description "Texttable is a Python module for creating simple ASCII
8276 (license license:lgpl2.1+)))
8278 (define-public python2-texttable
8279 (package-with-python2 python-texttable))
8281 (define-public python-atomicwrites
8283 (name "python-atomicwrites")
8287 (uri (pypi-uri "atomicwrites" version))
8290 "19ngcscdf3jsqmpcxn6zl5b6anmsajb6izp1smcd1n02midl9abm"))))
8291 (build-system python-build-system)
8292 (synopsis "Atomic file writes in Python")
8293 (description "Library for atomic file writes using platform dependent tools
8294 for atomic file system operations.")
8295 (home-page "https://github.com/untitaker/python-atomicwrites")
8296 (license license:expat)))
8298 (define-public python2-atomicwrites
8299 (package-with-python2 python-atomicwrites))
8301 (define-public python-click-threading
8303 (name "python-click-threading")
8307 (uri (pypi-uri "click-threading" version))
8310 "1rsxc2fbkxlhwhlmxsdjzq3spn284l6rvjfcz9mbb17ibgdgmc5j"))))
8311 (build-system python-build-system)
8313 `(("python-click" ,python-click)))
8314 (synopsis "Utilities for multithreading in Click")
8315 (description "This package provides utilities for multithreading in Click
8317 (home-page "https://github.com/click-contrib/click-threading")
8318 (license license:expat)))
8320 (define-public python-click-log
8322 (name "python-click-log")
8326 (uri (pypi-uri "click-log" version))
8329 "091i03bhxyzsdbc6kilxhivfda2f8ymz3b33xa6cj5kbzjiirz8n"))))
8330 (build-system python-build-system)
8332 `(("python-click" ,python-click)))
8333 (synopsis "Logging for click applications")
8334 (description "This package provides a Python library for logging Click
8336 (home-page "https://github.com/click-contrib/click-log")
8337 (license license:expat)))
8339 (define-public python-apipkg
8341 (name "python-apipkg")
8345 (uri (pypi-uri "apipkg" version))
8348 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
8349 (build-system python-build-system)
8351 `(("python-pytest" ,python-pytest)))
8352 (synopsis "Namespace control and lazy-import mechanism")
8353 (description "With apipkg you can control the exported namespace of a Python
8354 package and greatly reduce the number of imports for your users. It is a small
8355 pure Python module that works on virtually all Python versions.")
8356 (home-page "https://github.com/pytest-dev/apipkg")
8357 (license license:expat)))
8359 (define-public python2-apipkg
8360 (package-with-python2 python-apipkg))
8362 (define-public python-execnet
8364 (name "python-execnet")
8368 (uri (pypi-uri "execnet" version))
8371 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
8372 (build-system python-build-system)
8374 `(;; 2 failed, 275 passed, 670 skipped, 4 xfailed
8375 ;; The two test failures are caused by the lack of an `ssh` executable.
8376 ;; The test suite can be run with pytest after the 'install' phase.
8379 `(("python-pytest" ,python-pytest)
8380 ("python-setuptools-scm" ,python-setuptools-scm)))
8382 `(("python-apipkg" ,python-apipkg)))
8383 (synopsis "Rapid multi-Python deployment")
8384 (description "Execnet provides a share-nothing model with
8385 channel-send/receive communication for distributing execution across many
8386 Python interpreters across version, platform and network barriers. It has a
8387 minimal and fast API targeting the following uses:
8389 @item distribute tasks to (many) local or remote CPUs
8390 @item write and deploy hybrid multi-process applications
8391 @item write scripts to administer multiple environments
8393 (home-page "http://codespeak.net/execnet/")
8394 (license license:expat)))
8396 (define-public python2-execnet
8397 (package-with-python2 python-execnet))
8399 (define-public python-icalendar
8401 (name "python-icalendar")
8405 (uri (pypi-uri "icalendar" version))
8408 "16gjvqv0n05jrb9g228pdjgzd3amz2pdhvcgsn1jypszjg5m2w9l"))))
8409 (build-system python-build-system)
8411 `(("python-dateutil" ,python-dateutil)
8412 ("python-pytz" ,python-pytz)))
8413 (synopsis "Python library for parsing iCalendar files")
8414 (description "The icalendar package is a parser/generator of iCalendar
8415 files for use with Python.")
8416 (home-page "https://github.com/collective/icalendar")
8417 (license license:bsd-2)))
8419 (define-public python-args
8421 (name "python-args")
8425 (uri (pypi-uri "args" version))
8428 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
8429 (build-system python-build-system)
8430 (home-page "https://github.com/kennethreitz/args")
8431 (synopsis "Command-line argument parser")
8433 "This library provides a Python module to parse command-line arguments.")
8434 (license license:bsd-3)))
8436 (define-public python2-args
8437 (package-with-python2 python-args))
8439 (define-public python-clint
8441 (name "python-clint")
8445 (uri (pypi-uri "clint" version))
8448 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
8449 (build-system python-build-system)
8452 (modify-phases %standard-phases
8454 (lambda _ (invoke "py.test" "-v"))))))
8456 `(("python-pytest" ,python-pytest)))
8458 `(("python-args" ,python-args)))
8459 (home-page "https://github.com/kennethreitz/clint")
8460 (synopsis "Command-line interface tools")
8462 "Clint is a Python module filled with a set of tools for developing
8463 command-line applications, including tools for colored and indented
8464 output, progress bar display, and pipes.")
8465 (license license:isc)))
8467 (define-public python2-clint
8468 (package-with-python2 python-clint))
8470 (define-public python-rply
8472 (name "python-rply")
8476 (uri (pypi-uri "rply" version))
8479 "0lv428895zxsz43968qx0q9bimwqnfykndz4dpjbq515w2gvzhjh"))))
8480 (build-system python-build-system)
8482 `(("python-appdirs" ,python-appdirs)))
8483 (home-page "https://github.com/alex/rply")
8484 (synopsis "Parser generator for Python")
8486 "This package provides a pure Python based parser generator, that also
8487 works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
8488 with a new public API, and RPython support.")
8489 (license license:bsd-3)))
8491 (define-public python2-rply
8492 (package-with-python2 python-rply))
8494 (define-public python-hy
8500 (uri (pypi-uri "hy" version))
8503 "1gdbqsirsdxj320wnp7my5awzs1kfs6m4fqmkzbd1zd47qzj0zfi"))))
8504 (build-system python-build-system)
8507 (modify-phases %standard-phases
8508 (add-before 'install 'set-HOME
8510 (setenv "HOME" "/tmp")))
8513 ;; Tests require write access to HOME.
8514 (setenv "HOME" "/tmp")
8515 (invoke "nosetests"))))))
8517 `(("python-coverage" ,python-coverage)
8518 ("python-nose" ,python-nose)))
8520 `(("python-astor" ,python-astor)
8521 ("python-clint" ,python-clint)
8522 ("python-rply" ,python-rply)
8523 ("python-fastentrypoints"
8524 ,python-fastentrypoints)
8525 ("python-funcparserlib"
8526 ,python-funcparserlib)))
8527 (home-page "http://hylang.org/")
8528 (synopsis "Lisp frontend to Python")
8530 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
8531 its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
8532 Python at your fingertips, in Lisp form.")
8533 (license license:expat)))
8535 (define-public python2-hy
8536 (package-with-python2 python-hy))
8538 (define-public python2-functools32
8540 (name "python2-functools32")
8545 (uri (pypi-uri "functools32" version))
8548 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
8549 (build-system python-build-system)
8551 `(#:python ,python-2
8552 #:tests? #f)) ; no test target
8553 (home-page "https://github.com/MiCHiLU/python-functools32")
8555 "Backport of the functools module from Python 3.2.3")
8557 "This package is a backport of the @code{functools} module from Python
8558 3.2.3 for use with older versions of Python and PyPy.")
8559 (license license:expat)))
8561 (define-public python2-subprocess32
8563 (name "python2-subprocess32")
8567 (uri (pypi-uri "subprocess32" version))
8570 "14350dhhlhyz5gqzi3lihn9m6lvskx5mcb20srx1kgsk9i50li8y"))
8572 (search-patches "python2-subprocess32-disable-input-test.patch"))))
8573 (build-system python-build-system)
8575 `(#:python ,python-2
8576 ;; The test suite fails with Python > 2.7.13:
8577 ;; import test.support
8578 ;; ImportError: No module named support
8581 (modify-phases %standard-phases
8582 (add-after 'unpack 'patch-/bin/sh
8584 (substitute* '("subprocess32.py"
8585 "test_subprocess32.py")
8586 (("/bin/sh") (which "sh")))
8588 (home-page "https://github.com/google/python-subprocess32")
8589 (synopsis "Backport of the subprocess module from Python 3.2")
8591 "This is a backport of the @code{subprocess} standard library module
8592 from Python 3.2 and 3.3 for use on Python 2. It includes bugfixes and some
8593 new features. On POSIX systems it is guaranteed to be reliable when used
8594 in threaded applications. It includes timeout support from Python 3.3 but
8595 otherwise matches 3.2’s API.")
8596 (license license:psfl)))
8598 (define-public python2-futures
8600 (name "python2-futures")
8605 (uri (pypi-uri "futures" version))
8608 "0rdjmmsab550kxsssdq49jcniz77zlkpw4pvi9hvib3lsskjmh4y"))))
8609 (build-system python-build-system)
8611 `(#:python ,python-2
8613 (modify-phases %standard-phases
8616 (invoke "python" "test_futures.py")
8618 (home-page "https://github.com/agronholm/pythonfutures")
8620 "Backport of the concurrent.futures package from Python 3.2")
8622 "The concurrent.futures module provides a high-level interface for
8623 asynchronously executing callables. This package backports the
8624 concurrent.futures package from Python 3.2")
8625 (license license:bsd-3)))
8627 (define-public python-promise
8629 (name "python-promise")
8634 (uri (pypi-uri "promise" version))
8637 "1k19ms8l3d5jzjh557rgkxb5sg4mqgfc315rn4hx1z3n8qq6lr3h"))))
8638 (build-system python-build-system)
8639 ;; Tests wants python-futures, which is a python2 only program, and
8640 ;; can't be found by python-promise at test time.
8641 (arguments `(#:tests? #f))
8642 (home-page "https://github.com/syrusakbary/promise")
8643 (synopsis "Promises/A+ implementation for Python")
8645 "Promises/A+ implementation for Python")
8646 (properties `((python2-variant . ,(delay python2-promise))))
8647 (license license:expat)))
8649 (define-public python2-promise
8650 (let ((promise (package-with-python2
8651 (strip-python2-variant python-promise))))
8652 (package (inherit promise)
8653 (arguments (substitute-keyword-arguments (package-arguments promise)
8656 `(("python2-futures" ,python2-futures)
8657 ("python2-pytest" ,python2-pytest)
8658 ,@(package-native-inputs promise))))))
8660 (define-public python-progressbar33
8662 (name "python-progressbar33")
8667 (uri (pypi-uri "progressbar33" version))
8670 "1zvf6zs5hzrc03p9nfs4p16vhilqikycvv1yk0pxn8s07fdhvzji"))))
8671 (build-system python-build-system)
8672 (home-page "http://github.com/germangh/python-progressbar")
8673 (synopsis "Text progress bar library for Python")
8675 "This package provides a text progress bar library for Python. This
8676 version only differs from the original @code{progressbar} package in that it
8677 uses relative package imports instead of absolute imports, which is necessary
8678 for the module to work under Python 3.3.")
8679 ;; Either or both of these licenses may be selected.
8680 (license (list license:lgpl2.1+ license:bsd-3))))
8682 (define-public python-colorama
8684 (name "python-colorama")
8689 (uri (pypi-uri "colorama" version))
8692 "1wd1szk0z3073ghx26ynw43gnc140ibln1safgsis6s6z3s25ss8"))))
8693 (build-system python-build-system)
8694 (synopsis "Colored terminal text rendering for Python")
8695 (description "Colorama is a Python library for rendering colored terminal
8697 (home-page "https://pypi.python.org/pypi/colorama")
8698 (license license:bsd-3)))
8700 (define-public python2-colorama
8701 (package-with-python2 python-colorama))
8703 (define-public python-rsa
8710 (uri (pypi-uri "rsa" version))
8713 "1dcxvszbikgzh99ybdc7jq0zb9wspy2ds8z9mjsqiyv3q884xpr5"))))
8714 (build-system python-build-system)
8716 `(("python-pyasn1" ,python-pyasn1)))
8717 (synopsis "Pure-Python RSA implementation")
8718 (description "Python-RSA is a pure-Python RSA implementation. It supports
8719 encryption and decryption, signing and verifying signatures, and key
8720 generation according to PKCS#1 version 1.5. It can be used as a Python
8721 library as well as on the command line.")
8722 (home-page "https://stuvel.eu/rsa")
8723 (license license:asl2.0)))
8725 (define-public python2-rsa
8726 (package-with-python2 python-rsa))
8728 (define-public python-pluggy
8730 (name "python-pluggy")
8735 (uri (pypi-uri "pluggy" version))
8738 "10511a54dvafw1jrk75mrhml53c7b7w4yaw7241696lc2hfvr895"))))
8739 (build-system python-build-system)
8741 `(("python-setuptools-scm" ,python-setuptools-scm)))
8742 (synopsis "Plugin and hook calling mechanism for Python")
8743 (description "Pluggy is an extraction of the plugin manager as used by
8744 Pytest but stripped of Pytest specific details.")
8745 (home-page "https://pypi.python.org/pypi/pluggy")
8746 (license license:expat)))
8748 (define-public python2-pluggy
8749 (package-with-python2 python-pluggy))
8751 (define-public python-tox
8758 (uri (pypi-uri "tox" version))
8761 "1drp6mwm8wdypjym15ia8lwjxbhcksb9vzxg4ay5dh4ji57by2ny"))))
8762 (build-system python-build-system)
8764 ;; FIXME: Tests require pytest-timeout, which itself requires
8765 ;; pytest>=2.8.0 for installation.
8768 `(("python-pluggy" ,python-pluggy) ; >=0.3.0,<0.4.0
8769 ("python-py" ,python-py)
8770 ("python-virtualenv" ,python-virtualenv)))
8772 `(; FIXME: Missing: ("python-pytest-timeout" ,python-pytest-timeout)
8773 ("python-pytest" ,python-pytest) ; >= 2.3.5
8774 ("python-setuptools-scm" ,python-setuptools-scm)))
8775 (home-page "http://tox.testrun.org/")
8776 (synopsis "Virtualenv-based automation of test activities")
8777 (description "Tox is a generic virtualenv management and test command line
8778 tool. It can be used to check that a package installs correctly with
8779 different Python versions and interpreters, or run tests in each type of
8780 supported environment, or act as a frontend to continuous integration
8782 (license license:expat)))
8784 (define-public python2-tox
8785 (package-with-python2 python-tox))
8787 (define-public python-jmespath
8789 (name "python-jmespath")
8794 (uri (pypi-uri "jmespath" version))
8797 "0k0765x1mybcrzajh3hiqkl8sy9hs0bmn4900frxy0j3ykvaxqmx"))))
8798 (build-system python-build-system)
8800 `(("python-nose" ,python-nose)))
8801 (synopsis "JSON Matching Expressions")
8802 (description "JMESPath (pronounced “james path”) is a Python library that
8803 allows one to declaratively specify how to extract elements from a JSON
8805 (home-page "https://github.com/jmespath/jmespath.py")
8806 (license license:expat)))
8808 (define-public python2-jmespath
8809 (package-with-python2 python-jmespath))
8811 (define-public python-botocore
8813 (name "python-botocore")
8814 (version "1.12.149")
8818 (uri (pypi-uri "botocore" version))
8821 "12597f74khp3ngwr282cb949w0gcqj20rkfc3x275dijavyy5cmf"))))
8822 (build-system python-build-system)
8824 ;; FIXME: Many tests are failing.
8827 `(("python-dateutil" ,python-dateutil)
8828 ("python-docutils" ,python-docutils)
8829 ("python-jmespath" ,python-jmespath)))
8831 `(("python-mock" ,python-mock)
8832 ("python-nose" ,python-nose)
8834 ("python-tox" ,python-tox)
8835 ("python-urllib3" ,python-urllib3)
8836 ("python-wheel" ,python-wheel)))
8837 (home-page "https://github.com/boto/botocore")
8838 (synopsis "Low-level interface to AWS")
8839 (description "Botocore is a Python library that provides a low-level
8840 interface to the Amazon Web Services (AWS) API.")
8841 (license license:asl2.0)))
8843 (define-public python2-botocore
8844 (package-with-python2 python-botocore))
8846 (define-public python-xdo
8853 "http://http.debian.net/debian/pool/main/p/python-xdo/"
8854 "python-xdo_" version ".orig.tar.gz"))
8857 "1vqh1n5yy5dhnq312kwrl90fnck4v26is3lq3lxdvcn60vv19da0"))))
8858 (build-system python-build-system)
8861 (modify-phases %standard-phases
8862 (add-before 'install 'patch-libxdo-path
8863 ;; Hardcode the path of dynamically loaded libxdo library.
8864 (lambda* (#:key inputs #:allow-other-keys)
8865 (let ((libxdo (string-append
8866 (assoc-ref inputs "xdotool")
8868 (substitute* "xdo/_xdo.py"
8869 (("find_library\\(\"xdo\"\\)")
8870 (simple-format #f "\"~a\"" libxdo)))
8872 #:tests? #f)) ; no tests provided
8874 `(("python-six" ,python-six)))
8876 `(("xdotool" ,xdotool)
8877 ("libX11" ,libx11)))
8878 (home-page "https://tracker.debian.org/pkg/python-xdo")
8879 (synopsis "Python library for simulating X11 keyboard/mouse input")
8880 (description "Provides bindings to libxdo for manipulating X11 via simulated
8881 input. (Note that this is mostly a legacy library; you may wish to look at
8882 python-xdo for newer bindings.)")
8883 (license license:bsd-3)))
8885 (define-public python2-xdo
8886 (package-with-python2 python-xdo))
8888 (define-public python-mako
8890 (name "python-mako")
8895 (uri (pypi-uri "Mako" version))
8898 "0jqa3qfpykyn4fmkn0kh6043sfls7br8i2bsdbccazcvk9cijsd3"))))
8899 (build-system python-build-system)
8901 `(#:phases (modify-phases %standard-phases
8904 (invoke "pytest" "-vv"))))))
8906 `(("python-markupsafe" ,python-markupsafe)))
8908 `(("python-mock" ,python-mock)
8909 ("python-pytest" ,python-pytest)))
8910 (home-page "https://www.makotemplates.org/")
8911 (synopsis "Templating language for Python")
8912 (description "Mako is a templating language for Python that compiles
8913 templates into Python modules.")
8914 (license license:expat)))
8916 (define-public python2-mako
8917 (package-with-python2 python-mako))
8919 (define-public python-waitress
8921 (name "python-waitress")
8926 (uri (pypi-uri "waitress" version))
8927 (patches (search-patches "python-waitress-fix-tests.patch"))
8930 "1a85gyji0kajc3p0s1pwwfm06w4wfxjkvvl4rnrz3h164kbd6g6k"))))
8931 (build-system python-build-system)
8932 (home-page "https://github.com/Pylons/waitress")
8933 (synopsis "Waitress WSGI server")
8934 (description "Waitress is meant to be a production-quality pure-Python WSGI
8935 server with very acceptable performance.")
8936 (license license:zpl2.1)))
8938 (define-public python2-waitress
8939 (package-with-python2 python-waitress))
8941 (define-public python-whichcraft
8943 (name "python-whichcraft")
8948 (uri (pypi-uri "whichcraft" version))
8951 "11yfkzyplizdgndy34vyd5qlmr1n5mxis3a3svxmx8fnccdvknxc"))))
8952 (build-system python-build-system)
8954 `(("python-pytest" ,python-pytest)))
8955 (home-page "https://github.com/pydanny/whichcraft")
8956 (synopsis "Cross-platform cross-python shutil.which functionality")
8958 "This package provides a shim of the shutil.which function that's
8959 designed to work across multiple versions of Python.")
8960 (license license:bsd-3)))
8962 (define-public python-cookiecutter
8964 (name "python-cookiecutter")
8969 (uri (pypi-uri "cookiecutter" version))
8972 "0glsvaz8igi2wy1hsnhm9fkn6560vdvdixzvkq6dn20z3hpaa5hk"))))
8973 (build-system python-build-system)
8975 `(("python-freezegun" ,python-freezegun)
8976 ("python-pytest" ,python-pytest)
8977 ("python-pytest-catchlog" ,python-pytest-catchlog)
8978 ("python-pytest-cov" ,python-pytest-cov)
8979 ("python-pytest-mock" ,python-pytest-mock)))
8981 `(("python-binaryornot" ,python-binaryornot)
8982 ("python-click" ,python-click)
8983 ("python-future" ,python-future)
8984 ("python-jinja2" ,python-jinja2)
8985 ("python-jinja2-time" ,python-jinja2-time)
8986 ("python-poyo" ,python-poyo)
8987 ("python-requests" ,python-requests)
8988 ("python-whichcraft" ,python-whichcraft)))
8989 (home-page "https://github.com/audreyr/cookiecutter")
8991 "Command-line utility that creates projects from project templates")
8993 "This package provides a command-line utility that creates projects from
8994 project templates, e.g. creating a Python package project from a Python package
8996 (license license:bsd-3)))
8998 (define-public python-pyquery
9000 (name "python-pyquery")
9005 (uri (pypi-uri "pyquery" version))
9008 "1xia20wm0vx5dk85kcwgh13bylz8qh47ffjxssd2586r60xi783a"))))
9009 (build-system python-build-system)
9011 `(("python-webob" ,python-webob)
9012 ("python-webtest" ,python-webtest)))
9014 `(("python-lxml" ,python-lxml)
9015 ("python-cssselect" ,python-cssselect)))
9016 (home-page "https://github.com/gawel/pyquery")
9017 (synopsis "Make jQuery-like queries on xml documents")
9018 (description "pyquery allows you to make jQuery queries on xml documents.
9019 The API is as much as possible the similar to jQuery. pyquery uses lxml for
9020 fast xml and html manipulation.")
9021 (license license:bsd-3)))
9023 (define-public python-anyjson
9025 (name "python-anyjson")
9030 (uri (pypi-uri "anyjson" version))
9033 "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
9034 (build-system python-build-system)
9036 `(;; We could possibly get tests working, but on Python 3 it's not so easy.
9037 ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
9038 ;; whatever) so this transformation needs to be done before the tests
9039 ;; can be run. Maybe we could add a build step to transform beforehand
9040 ;; but it could be annoying/difficult.
9041 ;; We can enable tests for the Python 2 version, though, and do below.
9043 (home-page "https://bitbucket.org/runeh/anyjson/")
9045 "Wraps best available JSON implementation in a common interface")
9047 "Anyjson loads whichever is the fastest JSON module installed
9048 and provides a uniform API regardless of which JSON implementation is used.")
9049 (license license:bsd-3)
9050 (properties `((python2-variant . ,(delay python2-anyjson))))))
9052 (define-public python2-anyjson
9053 (let ((anyjson (package-with-python2
9054 (strip-python2-variant python-anyjson))))
9057 (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
9059 ,@(package-arguments anyjson)))
9060 (native-inputs `(("python2-nose" ,python2-nose))))))
9062 (define-public python-amqp
9064 (name "python-amqp")
9069 (uri (pypi-uri "amqp" version))
9072 "1sv600dgqwpimr6i1g59y9hpn50mc236gdqkr7zin13kvlpx0g87"))))
9073 (build-system python-build-system)
9075 `(("python-case" ,python-case)
9076 ("python-pytest-sugar" ,python-pytest-sugar)
9077 ("python-mock" ,python-mock)))
9079 `(("python-vine" ,python-vine)))
9080 (home-page "https://github.com/celery/py-amqp")
9082 "Low-level AMQP client for Python (fork of amqplib)")
9084 "This is a fork of amqplib which was originally written by Barry Pederson.
9085 It is maintained by the Celery project, and used by kombu as a pure python
9086 alternative when librabbitmq is not available.")
9087 (license license:lgpl2.1+)
9088 (properties `((python2-variant . ,(delay python2-amqp))))))
9090 (define-public python2-amqp
9091 (let ((amqp (package-with-python2
9092 (strip-python2-variant python-amqp))))
9095 (arguments `(;; Tries to run coverage tests with nose-cover3, which seems
9096 ;; unmaintained. Weirdly, does not do this on the python 3
9099 ,@(package-arguments amqp))))))
9101 (define-public python-txamqp
9103 (name "python-txamqp")
9108 (uri (pypi-uri "txAMQP" version))
9111 "0jd9864k3csc06kipiwzjlk9mq4054s8kzk5q1cfnxj8572s4iv4"))))
9112 (build-system python-build-system)
9114 `(("python-six" ,python-six)
9115 ("python-twisted" ,python-twisted)))
9116 (home-page "https://github.com/txamqp/txamqp")
9117 (synopsis "Communicate with AMQP peers and brokers using Twisted")
9119 "This package provides a Python library for communicating with AMQP peers
9120 and brokers using the asynchronous networking framework Twisted. It contains
9121 all the necessary code to connect, send and receive messages to/from an
9122 AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It
9123 also includes support for using Thrift RPC over AMQP in Twisted
9125 (license license:asl2.0)))
9127 (define-public python2-txamqp
9128 (package-with-python2 python-txamqp))
9130 (define-public python-kombu
9132 (name "python-kombu")
9137 (uri (pypi-uri "kombu" version))
9140 "15k8f7mzqr049sg9vi48m19vjykviafk3f0p5xzgw9by0x0kyxjj"))))
9141 (build-system python-build-system)
9143 `(("python-mock" ,python-mock)
9144 ("python-case" ,python-case)
9145 ("python-pyro4" ,python-pyro4)
9146 ("python-pytest-sugar" ,python-pytest-sugar)
9147 ("python-pytz" ,python-pytz)))
9149 `(("python-anyjson" ,python-anyjson)
9150 ("python-amqp" ,python-amqp)
9151 ("python-redis" ,python-redis)))
9152 (home-page "https://kombu.readthedocs.io")
9153 (synopsis "Message passing library for Python")
9154 (description "The aim of Kombu is to make messaging in Python as easy as
9155 possible by providing an idiomatic high-level interface for the AMQ protocol,
9156 and also provide proven and tested solutions to common messaging problems.
9157 AMQP is the Advanced Message Queuing Protocol, an open standard protocol for
9158 message orientation, queuing, routing, reliability and security, for which the
9159 RabbitMQ messaging server is the most popular implementation.")
9160 (license license:bsd-3)
9161 (properties `((python2-variant . ,(delay python2-kombu))))))
9163 (define-public python2-kombu
9164 (let ((kombu (package-with-python2
9165 (strip-python2-variant python-kombu))))
9168 (arguments `(;; FIXME: 'TestTransport.test_del_sync' fails on python2.
9169 ;; It works fine on the python3 variant.
9171 ,@(package-arguments kombu)))
9172 (native-inputs `(("python2-unittest2" ,python2-unittest2)
9173 ,@(package-native-inputs kombu))))))
9175 (define-public python-billiard
9177 (name "python-billiard")
9182 (uri (pypi-uri "billiard" version))
9185 "03msmapj3s5zgqk87d646mafz7a01h5bm2wijalgpi0s80ks5na2"))))
9186 (build-system python-build-system)
9188 `(("python-case" ,python-case)
9189 ("python-pytest" ,python-pytest)))
9190 (home-page "https://github.com/celery/billiard")
9192 "Python multiprocessing fork with improvements and bugfixes")
9194 "Billiard is a fork of the Python 2.7 multiprocessing package. The
9195 multiprocessing package itself is a renamed and updated version of R Oudkerk's
9196 pyprocessing package. This standalone variant is intended to be compatible with
9197 Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.")
9198 (license license:bsd-3)
9199 (properties `((python2-variant . ,(delay python2-billiard))))))
9201 (define-public python2-billiard
9202 (let ((billiard (package-with-python2
9203 (strip-python2-variant python-billiard))))
9206 (native-inputs `(("python2-unittest2" ,python2-unittest2)
9207 ("python2-mock" ,python2-mock)
9208 ,@(package-native-inputs billiard))))))
9210 (define-public python-celery
9212 (name "python-celery")
9217 (uri (pypi-uri "celery" version))
9220 "0y66rz7z8dfcgs3s0qxmdddlaq57bzbgxgfz896nbp14grkv9nkp"))))
9221 (build-system python-build-system)
9223 '(;; TODO The tests fail with Python 3.7
9224 ;; https://github.com/celery/celery/issues/4849
9227 (modify-phases %standard-phases
9228 (add-after 'unpack 'patch-requirements
9230 (substitute* "requirements/test.txt"
9231 (("pytest>=3\\.0,<3\\.3")
9235 `(("python-case" ,python-case)
9236 ("python-pytest" ,python-pytest)))
9238 `(("python-pytz" ,python-pytz)
9239 ("python-billiard" ,python-billiard)
9240 ("python-kombu" ,python-kombu)))
9241 (home-page "https://celeryproject.org")
9242 (synopsis "Distributed Task Queue")
9243 (description "Celery is an asynchronous task queue/job queue based on
9244 distributed message passing. It is focused on real-time operation, but
9245 supports scheduling as well. The execution units, called tasks, are executed
9246 concurrently on a single or more worker servers using multiprocessing,
9247 Eventlet, or gevent. Tasks can execute asynchronously (in the background) or
9248 synchronously (wait until ready).")
9249 (license license:bsd-3)
9250 (properties `((python2-variant . ,(delay python2-celery))))))
9252 (define-public python2-celery
9253 (let ((celery (package-with-python2
9254 (strip-python2-variant python-celery))))
9257 (native-inputs `(("python2-unittest2" ,python2-unittest2)
9258 ("python2-mock" ,python2-mock)
9259 ,@(package-native-inputs celery))))))
9261 (define-public python-translitcodec
9263 (name "python-translitcodec")
9268 (uri (pypi-uri "translitcodec" version))
9271 "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki"))))
9272 (build-system python-build-system)
9274 `(#:tests? #f)) ; no tests provided
9276 "https://github.com/claudep/translitcodec")
9278 "Unicode to 8-bit charset transliteration codec")
9280 "This package contains codecs for transliterating ISO 10646 texts into
9281 best-effort representations using smaller coded character sets (ASCII,
9283 (license license:expat)))
9285 (define-public python2-translitcodec
9286 (package-with-python2 python-translitcodec))
9288 (define-public python-editor
9290 (name "python-editor")
9295 (uri (pypi-uri "python-editor" version))
9298 "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n"))))
9299 (build-system python-build-system)
9301 "https://github.com/fmoo/python-editor")
9303 "Programmatically open an editor, capture the result")
9305 "python-editor is a library that provides the editor module for
9306 programmatically interfacing with your system's $EDITOR.")
9307 (license license:asl2.0)))
9309 (define-public python2-editor
9310 (package-with-python2 python-editor))
9312 (define-public python-vobject
9314 (name "python-vobject")
9318 (uri (pypi-uri "vobject" version))
9321 "0hqjgf3ay1m5w1c0k00g5yfpdz1zni5qnr5rh9b8fg9hjvhwlmhg"))))
9322 (build-system python-build-system)
9324 '(;; The test suite relies on some non-portable Windows interfaces.
9327 `(("python-dateutil" ,python-dateutil)
9328 ("python-pyicu" ,python-pyicu)))
9329 (synopsis "Parse and generate vCard and vCalendar files")
9330 (description "Vobject is intended to be a full featured Python package for
9331 parsing and generating vCard and vCalendar files. Currently, iCalendar files
9332 are supported and well tested. vCard 3.0 files are supported, and all data
9333 should be imported, but only a few components are understood in a sophisticated
9335 (home-page "http://eventable.github.io/vobject/")
9336 (license license:asl2.0)))
9338 (define-public python2-vobject
9339 (package-with-python2 python-vobject))
9341 (define-public python-munkres
9343 (name "python-munkres")
9347 (uri (pypi-uri "munkres" version))
9350 "0mbspx4zv8id4x6pim6ybsa1xh96qwpbqj7skbqz4c9c9nf1lpqq"))))
9351 (build-system python-build-system)
9353 '(#:tests? #f)) ; no test suite
9354 (home-page "http://software.clapper.org/munkres/")
9355 (synopsis "Implementation of the Munkres algorithm")
9356 (description "The Munkres module provides an implementation of the Munkres
9357 algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm),
9358 useful for solving the Assignment Problem.")
9359 (license license:bsd-3)))
9361 (define-public python2-munkres
9362 (package-with-python2 python-munkres))
9364 (define-public python-whoosh
9366 (name "python-whoosh")
9371 (uri (pypi-uri "Whoosh" version))
9374 "10qsqdjpbc85fykc1vgcs8xwbgn4l2l52c8d83xf1q59pwyn79bw"))))
9375 (build-system python-build-system)
9376 (arguments '(#:tests? #f)) ; Test invocation is no longer supported by Python.
9378 `(("python-pytest" ,python-pytest)))
9379 (home-page "https://bitbucket.org/mchaput/whoosh")
9380 (synopsis "Full text indexing, search, and spell checking library")
9382 "Whoosh is a fast, pure-Python full text indexing, search, and spell
9384 (license license:bsd-2)))
9386 (define-public python2-whoosh
9387 (let ((whoosh (package-with-python2 (strip-python2-variant python-whoosh))))
9388 (package (inherit whoosh)
9390 `(("python2-backport-ssl-match-hostname"
9391 ,python2-backport-ssl-match-hostname)
9392 ,@(package-propagated-inputs whoosh))))))
9394 (define-public python-pathlib
9396 (name "python-pathlib")
9400 (uri (pypi-uri "pathlib" version))
9403 "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39"))))
9404 (build-system python-build-system)
9405 ;; The tests depend on the internal "test" module, which does not provide
9406 ;; a stable interface.
9407 (arguments `(#:tests? #f))
9408 (home-page "https://pathlib.readthedocs.org/")
9409 (synopsis "Object-oriented file system paths")
9410 (description "Pathlib offers a set of classes to handle file system paths.
9411 It offers the following advantages over using string objects:
9414 @item No more cumbersome use of os and os.path functions. Everything can
9415 be done easily through operators, attribute accesses, and method calls.
9416 @item Embodies the semantics of different path types. For example,
9417 comparing Windows paths ignores casing.
9418 @item Well-defined semantics, eliminating any inconsistencies or
9419 ambiguities (forward vs. backward slashes, etc.).
9422 Note: In Python 3.4, pathlib is now part of the standard library. For other
9423 Python versions please consider python-pathlib2 instead, which tracks the
9424 standard library module. This module (python-pathlib) isn't maintained
9426 (license license:expat)))
9428 (define-public python2-pathlib
9429 (package-with-python2 python-pathlib))
9431 (define-public python2-pathlib2
9433 (name "python2-pathlib2")
9437 (uri (pypi-uri "pathlib2" version))
9440 "0hpp92vqqgcd8h92msm9slv161b1q160igjwnkf2ag6cx0c96695"))))
9441 (build-system python-build-system)
9442 ;; We only need the the Python 2 variant, since for Python 3 our minimum
9443 ;; version is 3.4 which already includes this package as part of the
9444 ;; standard library.
9446 `(#:python ,python-2))
9448 `(("python2-scandir" ,python2-scandir)
9449 ("python2-six" ,python2-six)))
9450 (home-page "https://pypi.python.org/pypi/pathlib2/")
9451 (synopsis "Object-oriented file system paths - backport of standard
9453 (description "The goal of pathlib2 is to provide a backport of standard
9454 pathlib module which tracks the standard library module, so all the newest
9455 features of the standard pathlib can be used also on older Python versions.
9457 Pathlib offers a set of classes to handle file system paths. It offers the
9458 following advantages over using string objects:
9461 @item No more cumbersome use of os and os.path functions. Everything can
9462 be done easily through operators, attribute accesses, and method calls.
9463 @item Embodies the semantics of different path types. For example,
9464 comparing Windows paths ignores casing.
9465 @item Well-defined semantics, eliminating any inconsistencies or
9466 ambiguities (forward vs. backward slashes, etc.).
9468 (license license:expat)))
9470 (define-public python2-pathlib2-bootstrap
9473 (inherit python2-pathlib2)
9474 (name "python2-pathlib2-bootstrap")
9476 `(("python2-scandir" ,python2-scandir)
9477 ("python2-six" ,python2-six-bootstrap))))))
9479 (define-public python-jellyfish
9481 (name "python-jellyfish")
9485 (uri (pypi-uri "jellyfish" version))
9488 "1j9rplb16ba2prjj6mip46z0w9pnhnqpwgiwi0x93vnas14rlyl8"))))
9489 (build-system python-build-system)
9491 `(("python-pytest" ,python-pytest)))
9492 (home-page "https://github.com/jamesturk/jellyfish")
9493 (synopsis "Approximate and phonetic matching of strings")
9494 (description "Jellyfish uses a variety of string comparison and phonetic
9495 encoding algorithms to do fuzzy string matching.")
9496 (license license:bsd-2)
9497 (properties `((python2-variant . ,(delay python2-jellyfish))))))
9499 (define-public python2-jellyfish
9500 (let ((jellyfish (package-with-python2
9501 (strip-python2-variant python-jellyfish))))
9502 (package (inherit jellyfish)
9503 (native-inputs `(("python2-unicodecsv" ,python2-unicodecsv)
9504 ,@(package-native-inputs jellyfish))))))
9506 (define-public python2-unicodecsv
9508 (name "python2-unicodecsv")
9512 ;; The test suite is not included in the PyPi release.
9513 ;; https://github.com/jdunck/python-unicodecsv/issues/19
9515 (url "https://github.com/jdunck/python-unicodecsv")
9517 (file-name (git-file-name name version))
9520 "15hx2k41a2lpv4hcml9zp4cvlx1171mnb5s4s13xc1pxkq3vgdjy"))))
9521 (build-system python-build-system)
9523 `(;; It supports Python 3, but Python 3 can already do Unicode CSV.
9524 #:python ,python-2))
9526 `(("python2-unittest2" ,python2-unittest2)))
9527 (home-page "https://github.com/jdunck/python-unicodecsv")
9528 (synopsis "Unicode CSV module for Python 2")
9529 (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV
9530 module, adding support for Unicode strings.")
9531 (license license:bsd-2)))
9533 (define-public python-rarfile
9535 (name "python-rarfile")
9539 (uri (pypi-uri "rarfile" version))
9542 "0qfad483kcbga0bn4qmcz953xjk16r52fahiy46zzn56v80y89ra"))))
9543 (build-system python-build-system)
9546 (modify-phases %standard-phases
9548 ;; Many tests fail, but the installation proceeds.
9549 (lambda _ (invoke "make" "-C" "test" "test"))))))
9551 `(("which" ,which))) ; required for tests
9553 `(("libarchive" ,libarchive)))
9554 (home-page "https://github.com/markokr/rarfile")
9555 (synopsis "RAR archive reader for Python")
9556 (description "This is Python module for RAR archive reading. The interface
9557 is made as zipfile like as possible.")
9558 (license license:isc)))
9560 (define-public python2-rarfile
9561 (package-with-python2 python-rarfile))
9563 (define-public python-magic
9565 (name "python-magic")
9570 (uri (pypi-uri "python-magic" version))
9573 "1mgwig9pnzgkf86q9ji9pnc99bngms15lfszq5rgqb9db07mqxpk"))
9574 (file-name (string-append name "-" version "-checkout"))))
9575 (build-system python-build-system)
9577 ;; The tests are unreliable, so don't run them. The tests fail
9578 ;; under Python3 because they were written for Python2 and
9579 ;; contain import statements that do not work in Python3. One of
9580 ;; the tests fails under Python2 because its assertions are
9581 ;; overly stringent; it relies on comparing output strings which
9582 ;; are brittle and can change depending on the version of
9583 ;; libmagic being used and the system on which the test is
9584 ;; running. In my case, under GuixSD 0.10.0, only one test
9585 ;; failed, and it seems to have failed only because the version
9586 ;; of libmagic that is packaged in Guix outputs a slightly
9587 ;; different (but not wrong) string than the one that the test
9590 #:phases (modify-phases %standard-phases
9591 ;; Replace a specific method call with a hard-coded
9592 ;; path to the necessary libmagic.so file in the
9593 ;; store. If we don't do this, then the method call
9594 ;; will fail to find the libmagic.so file, which in
9595 ;; turn will cause any application using
9596 ;; python-magic to fail.
9597 (add-before 'build 'hard-code-path-to-libmagic
9598 (lambda* (#:key inputs #:allow-other-keys)
9599 (let ((file (assoc-ref inputs "file")))
9600 (substitute* "magic.py"
9601 (("ctypes.util.find_library\\('magic'\\)")
9602 (string-append "'" file "/lib/libmagic.so'")))
9604 (add-before 'install 'disable-egg-compression
9606 (let ((port (open-file "setup.cfg" "a")))
9607 (display "\n[easy_install]\nzip_ok = 0\n"
9612 ;; python-magic needs to be able to find libmagic.so.
9615 "https://github.com/ahupp/python-magic")
9617 "File type identification using libmagic")
9619 "This module uses ctypes to access the libmagic file type
9620 identification library. It makes use of the local magic database and
9621 supports both textual and MIME-type output. Note that this module and
9622 the python-file module both provide a \"magic.py\" file; these two
9623 modules, which are different and were developed separately, both serve
9624 the same purpose: to provide Python bindings for libmagic.")
9625 (license license:expat)))
9627 (define-public python2-magic
9628 (package-with-python2 python-magic))
9630 (define-public python2-s3cmd
9632 (name "python2-s3cmd")
9637 (uri (string-append "mirror://sourceforge/s3tools/s3cmd/" version "/"
9638 "s3cmd-" version ".tar.gz"))
9641 "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6"))))
9642 (build-system python-build-system)
9644 ;; s3cmd is written for python2 only and contains no tests.
9645 `(#:python ,python-2
9648 `(("python2-dateutil" ,python2-dateutil)
9649 ;; The python-file package also provides a magic.py module.
9650 ;; This is an unfortunate state of affairs; however, s3cmd
9651 ;; fails to install if it cannot find specifically the
9652 ;; python-magic package. Thus we include it, instead of using
9653 ;; python-file. Ironically, s3cmd sometimes works better
9654 ;; without libmagic bindings at all:
9655 ;; https://github.com/s3tools/s3cmd/issues/198
9656 ("python2-magic" ,python2-magic)))
9657 (home-page "http://s3tools.org/s3cmd")
9658 (synopsis "Command line tool for S3-compatible storage services")
9660 "S3cmd is a command line tool for uploading, retrieving and managing data
9661 in storage services that are compatible with the Amazon Simple Storage
9662 Service (S3) protocol, including S3 itself. It supports rsync-like backup,
9663 GnuPG encryption, and more. It also supports management of Amazon's
9664 CloudFront content delivery network.")
9665 (license license:gpl2+)))
9667 (define-public python-pkgconfig
9669 (name "python-pkgconfig")
9674 (uri (pypi-uri "pkgconfig" version))
9677 "107x2wmchlch8saixb488cgjz9n6inl38wi7nxkb942rbaapxiqb"))))
9678 (build-system python-build-system)
9680 `(("python-nose" ,python-nose)))
9682 `(("pkg-config" ,pkg-config)))
9685 (modify-phases %standard-phases
9686 (add-before 'build 'patch
9687 ;; Hard-code the path to pkg-config.
9689 (substitute* "pkgconfig/pkgconfig.py"
9690 (("cmd = 'pkg-config")
9691 (string-append "cmd = '" (which "pkg-config"))))
9695 (invoke "nosetests" "test.py"))))))
9696 (home-page "https://github.com/matze/pkgconfig")
9697 (synopsis "Python interface for pkg-config")
9698 (description "This module provides a Python interface to pkg-config. It
9699 can be used to find all pkg-config packages, check if a package exists,
9700 check if a package meets certain version requirements, query CFLAGS and
9701 LDFLAGS and parse the output to build extensions with setup.py.")
9702 (license license:expat)))
9704 (define-public python2-pkgconfig
9705 (package-with-python2 python-pkgconfig))
9707 (define-public python-bz2file
9709 (name "python-bz2file")
9714 (uri (pypi-uri "bz2file" version))
9717 "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4"))))
9718 (build-system python-build-system)
9720 `(#:tests? #f)) ; Tests use deprecated python modules.
9721 (home-page "https://github.com/nvawda/bz2file")
9722 (synopsis "Read and write bzip2-compressed files")
9724 "Bz2file is a Python library for reading and writing bzip2-compressed
9725 files. It contains a drop-in replacement for the I/O interface in the
9726 standard library's @code{bz2} module, including features from the latest
9727 development version of CPython that are not available in older releases.")
9728 (license license:asl2.0)))
9730 (define-public python2-bz2file
9731 (package-with-python2 python-bz2file))
9733 (define-public python-future
9735 (name "python-future")
9740 (uri (pypi-uri "future" version))
9743 "1f2rlqn9rh7adgir52dlbqz69gsab44x0mlm8gf1cs7xvhv54137"))))
9744 (build-system python-build-system)
9745 ;; Many tests connect to the network or are otherwise flawed.
9746 ;; https://github.com/PythonCharmers/python-future/issues/210
9749 (home-page "http://python-future.org")
9750 (synopsis "Single-source support for Python 3 and 2")
9752 "@code{python-future} is the missing compatibility layer between Python 2 and
9753 Python 3. It allows you to use a single, clean Python 3.x-compatible codebase
9754 to support both Python 2 and Python 3 with minimal overhead.")
9755 (license license:expat)))
9757 (define-public python2-future
9758 (package-with-python2 python-future))
9760 (define-public python-cysignals
9762 (name "python-cysignals")
9767 (uri (pypi-uri "cysignals" version))
9770 "15ix8crpad26cfl1skyg7qajqqfdrm8q5ahhmlfmqi1aw0jqj2g2"))))
9771 (build-system python-build-system)
9773 `(("python-cython" ,python-cython)
9774 ("python-sphinx" ,python-sphinx)))
9776 `(("pari-gp" ,pari-gp)))
9778 `(#:modules ((guix build python-build-system)
9779 ((guix build gnu-build-system) #:prefix gnu:)
9781 ;; FIXME: Tests are executed after installation and currently fail
9782 ;; when not installing into standard locations; the author is working
9786 (modify-phases %standard-phases
9789 (assoc-ref gnu:%standard-phases 'configure)))))
9791 "https://github.com/sagemath/cysignals")
9793 "Handling of interrupts and signals for Cython")
9795 "The cysignals package provides mechanisms to handle interrupts (and
9796 other signals and errors) in Cython code, using two related approaches,
9797 for mixed Cython/Python code or external C libraries and pure Cython code,
9799 (license license:lgpl3+)))
9801 (define-public python2-cysignals
9802 (package-with-python2 python-cysignals))
9804 (define-public python2-shedskin
9806 (name "python2-shedskin")
9811 (uri (string-append "https://github.com/shedskin/shedskin/"
9812 "releases/download/v" version
9813 "/shedskin-" version ".tgz"))
9816 "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41"))))
9817 (build-system python-build-system)
9819 `(#:python ,python-2
9820 #:phases (modify-phases %standard-phases
9821 (add-after 'unpack 'fix-resulting-include-libs
9822 (lambda* (#:key inputs #:allow-other-keys)
9823 (let ((libgc (assoc-ref inputs "libgc"))
9824 (pcre (assoc-ref inputs "pcre")))
9825 (substitute* "shedskin/makefile.py"
9826 (("variable == 'CCFLAGS':[ ]*")
9827 (string-append "variable == 'CCFLAGS':\n"
9828 " line += ' -I " pcre "/include"
9829 " -I " libgc "/include'"))
9830 (("variable == 'LFLAGS':[ ]*")
9831 (string-append "variable == 'LFLAGS':\n"
9832 " line += ' -L" pcre "/lib"
9833 " -L " libgc "/lib'")))
9835 (inputs `(("pcre" ,pcre)
9837 (home-page "https://shedskin.github.io/")
9838 (synopsis "Experimental Python-2 to C++ Compiler")
9839 (description (string-append "This is an experimental compiler for a subset of
9840 Python. It generates C++ code and a Makefile."))
9841 (license (list license:gpl3 license:bsd-3 license:expat))))
9843 (define-public python2-rope
9845 (name "python2-rope")
9850 (uri (pypi-uri "rope" version))
9853 "1cppm0pa9aqgsbkq130lskrzmrvjs5vpiavjjbhpz2fdw52w8251"))))
9855 ;; Rope has only partial python3 support, see `python-rope'
9856 `(#:python ,python-2))
9857 (build-system python-build-system)
9859 `(("python2-unittest2" ,python2-unittest2)))
9860 (home-page "https://github.com/python-rope/rope")
9861 (synopsis "Refactoring library for Python")
9862 (description "Rope is a refactoring library for Python. It facilitates
9863 the renaming, moving and extracting of attributes, functions, modules, fields
9864 and parameters in Python 2 source code. These refactorings can also be applied
9865 to occurrences in strings and comments.")
9866 (license license:gpl2)))
9868 (define-public python-rope
9870 (inherit python2-rope)
9871 (name "python-rope")
9872 (arguments `(#:python ,python-wrapper
9873 ;; XXX: Only partial python3 support, results in some failing
9874 ;; tests: <https://github.com/python-rope/rope/issues/247>.
9876 (properties `((python2-variant . ,(delay python2-rope))))))
9878 (define-public python-py3status
9880 (name "python-py3status")
9885 (uri (pypi-uri "py3status" version))
9887 (base32 "16z8zq83hxy48g6hh4xczbdz50qvxv9k1aahr4fqq7jis60cc262"))))
9888 (build-system python-build-system)
9893 (modify-phases %standard-phases
9894 ;; 'file' is used for detection of configuration file encoding
9895 ;; let's make link the dependency to particular input
9896 (add-before 'build 'patch-file-path
9897 (lambda* (#:key inputs #:allow-other-keys)
9898 (let ((file-path (assoc-ref inputs "file")))
9899 (substitute* "py3status/parse_config.py"
9900 (("\\[\"file\", \"-b\"")
9901 (string-append "['" file-path "/bin/file', '-b'")))
9903 #:tests? #f)) ; TODO: Requires many libraries not in Guix.
9904 (home-page "https://github.com/ultrabug/py3status")
9905 (synopsis "Extensible i3status wrapper written in Python")
9906 (description "py3status is an i3status wrapper which extends i3status
9907 functionality in a modular way, allowing you to extend your panel with your
9908 own code, responding to click events and updating clock every second.")
9909 (license license:bsd-3)))
9911 (define-public python-tblib
9913 (name "python-tblib")
9917 (uri (pypi-uri "tblib" version))
9919 "1rsg8h069kqgncyv8fgzyj6qflk6j10cb78pa5jk34ixwq044vj3"))))
9920 (build-system python-build-system)
9923 (modify-phases %standard-phases
9924 (add-before 'check 'adjust-tests
9926 (when (which "python3")
9927 ;; Adjust the example output to match that of Python 3.7:
9928 ;; <https://github.com/ionelmc/python-tblib/issues/36>.
9929 (substitute* "README.rst"
9930 (("Exception\\('fail',") "Exception('fail'"))
9934 ;; Upstream runs tests after installation and the package itself
9935 ;; resides in a subdirectory. Extend PYTHONPATH so it will be
9937 (setenv "PYTHONPATH"
9938 (string-append (getcwd) "/build/lib:"
9939 (getenv "PYTHONPATH")))
9940 (invoke "py.test" "-vv" "tests" "README.rst"))))))
9942 `(("python-pytest" ,python-pytest)
9943 ("python-six" ,python-six)))
9944 (home-page "https://github.com/ionelmc/python-tblib")
9945 (synopsis "Traceback serialization library")
9947 "Traceback serialization allows you to:
9950 @item Pickle tracebacks and raise exceptions with pickled tracebacks in
9951 different processes. This allows better error handling when running code over
9952 multiple processes (imagine multiprocessing, billiard, futures, celery etc).
9954 @item Parse traceback strings and raise with the parsed tracebacks.
9956 (license license:bsd-3)))
9958 (define-public python2-tblib
9959 (package-with-python2 python-tblib))
9961 (define-public python-greenlet
9963 (name "python-greenlet")
9967 (uri (pypi-uri "greenlet" version))
9970 "1g4g1wwc472ds89zmqlpyan3fbnzpa8qm48z3z1y6mlk44z485ll"))))
9971 (build-system python-build-system)
9972 (home-page "https://greenlet.readthedocs.io/")
9973 (synopsis "Lightweight in-process concurrent programming")
9975 "Greenlet package is a spin-off of Stackless, a version of CPython
9976 that supports micro-threads called \"tasklets\". Tasklets run
9977 pseudo-concurrently (typically in a single or a few OS-level threads) and
9978 are synchronized with data exchanges on \"channels\".")
9979 (license (list license:psfl license:expat))))
9981 (define-public python2-greenlet
9982 (package-with-python2 python-greenlet))
9984 (define-public python-objgraph
9986 (name "python-objgraph")
9991 (uri (pypi-uri "objgraph" version))
9994 "184m09am5gpbqfaiy7l0hwh476mczbrly1dffs0rw2p1d1i2q32a"))))
9995 (build-system python-build-system)
9997 `(("python-graphviz" ,python-graphviz)))
9999 `(("python-mock" ,python-mock)
10000 ("graphviz" ,graphviz)))
10001 (home-page "https://mg.pov.lt/objgraph/")
10002 (synopsis "Draw Python object reference graphs with graphviz")
10004 "This package provides tools to draw Python object reference graphs with
10006 (license license:expat)))
10008 (define-public python-gevent
10010 (name "python-gevent")
10014 (uri (pypi-uri "gevent" version))
10017 "0b0fr04qdk1p4sniv87fh8z5psac60x01pv054kpgi94520g81iz"))
10018 (modules '((guix build utils)))
10021 ;; unbunding libev and c-ares
10022 (delete-file-recursively "deps")
10024 (build-system python-build-system)
10026 `(#:modules ((ice-9 ftw)
10030 (guix build python-build-system))
10031 #:phases (modify-phases %standard-phases
10032 (add-before 'patch-source-shebangs 'patch-hard-coded-paths
10034 (substitute* "src/gevent/subprocess.py"
10035 (("/bin/sh") (which "sh")))
10036 (for-each (lambda (file)
10038 (("/bin/sh") (which "sh"))
10039 (("/bin/true") (which "true"))))
10040 (find-files "src/greentest" "\\.py$"))
10042 (add-before 'build 'do-not-use-bundled-sources
10043 (lambda* (#:key inputs #:allow-other-keys)
10044 (setenv "CONFIG_SHELL" (which "bash"))
10045 (setenv "LIBEV_EMBED" "false")
10046 (setenv "CARES_EMBED" "false")
10047 (setenv "EMBED" "false")
10049 ;; Prevent building bundled libev.
10050 (substitute* "setup.py"
10051 (("run_make=_BUILDING")
10054 (let ((greenlet (string-append
10055 (assoc-ref inputs "python-greenlet")
10057 (match (scandir greenlet
10059 (string-prefix? "python" item)))
10061 (setenv "C_INCLUDE_PATH"
10062 (string-append greenlet "/" python)))))
10064 (add-before 'check 'skip-timer-test
10066 ;; XXX: Skip 'TestTimerResolution', which appears to be
10068 (substitute* "src/greentest/test__core_timer.py"
10069 (("not greentest.RUNNING_ON_CI") "False"))
10073 ;; Make sure the build directory is on PYTHONPATH.
10074 (setenv "PYTHONPATH"
10076 (getenv "PYTHONPATH") ":"
10078 (car (scandir "build" (cut string-prefix? "lib." <>)))))
10079 (with-directory-excursion "src/greentest"
10080 ;; XXX: Many tests require network access. Instead we only
10081 ;; run known-good tests. Unfortunately we cannot use
10082 ;; recursion here since this directory also contains
10083 ;; Python-version-specific subfolders.
10084 (apply invoke "python" "testrunner.py" "--config"
10085 "known_failures.py"
10086 (scandir "." (cut regexp-exec
10087 (make-regexp "test_+(subprocess|core)")
10090 `(("python-greenlet" ,python-greenlet)
10091 ("python-objgraph" ,python-objgraph)))
10093 `(("python-six" ,python-six)))
10095 `(("c-ares" ,c-ares)
10097 (home-page "http://www.gevent.org/")
10098 (synopsis "Coroutine-based network library")
10100 "gevent is a coroutine-based Python networking library that uses greenlet
10101 to provide a high-level synchronous API on top of the libev event loop.")
10102 (license license:expat)
10103 (properties `((python2-variant . ,(delay python2-gevent))))))
10105 (define-public python2-gevent
10106 (let ((base (package-with-python2
10107 (strip-python2-variant python-gevent))))
10110 (native-inputs `(,@(package-native-inputs python-gevent)
10111 ("python-mock" ,python2-mock))))))
10113 (define-public python-fastimport
10115 (name "python-fastimport")
10120 (uri (pypi-uri "fastimport" version))
10122 (base32 "1aqjsin4rmqm7ln4j0p73fzxifws6c6ikgyhav7r137m2ixsxl43"))))
10123 (build-system python-build-system)
10124 (home-page "https://github.com/jelmer/python-fastimport")
10125 (synopsis "VCS fastimport parser and generator in Python")
10126 (description "This package provides a parser for and generator of the Git
10127 @url{https://www.kernel.org/pub/software/scm/git/docs/git-fast-import.html,fastimport}
10129 (license license:gpl2+)))
10131 (define-public python2-fastimport
10132 (package-with-python2 python-fastimport))
10134 (define-public python-twisted
10136 (name "python-twisted")
10140 (uri (pypi-uri "Twisted" version ".tar.bz2"))
10143 "17d3hnxv9qndagzz63mdpyk99xj63p9gq586vjn0rxk8cl197nym"))))
10144 (build-system python-build-system)
10146 '(#:tests? #f)) ; FIXME: some tests fail
10148 `(("python-zope-interface" ,python-zope-interface)
10149 ("python-pyhamcrest" ,python-pyhamcrest)
10150 ("python-incremental" ,python-incremental)
10151 ("python-hyperlink" ,python-hyperlink)
10152 ("python-constantly" ,python-constantly)
10153 ("python-automat" ,python-automat)))
10154 (home-page "https://twistedmatrix.com/")
10155 (synopsis "Asynchronous networking framework written in Python")
10157 "Twisted is an extensible framework for Python programming, with special
10158 focus on event-based network programming and multiprotocol integration.")
10159 (license license:expat)))
10161 (define-public python2-twisted
10162 (package-with-python2 python-twisted))
10164 (define-public python-pika
10166 (name "python-pika")
10171 (uri (pypi-uri "pika" version))
10174 "0ld7akgm93s8pfa4dsx9qlzlhj76zspbr5m9ms0ns09yd2w4aq9h"))))
10175 (build-system python-build-system)
10177 `(("python-pyev" ,python-pyev)
10178 ("python-tornado" ,python-tornado)
10179 ("python-twisted" ,python-twisted)))
10180 (home-page "https://pika.readthedocs.org")
10181 (synopsis "Pure Python AMQP Client Library")
10183 "Pika is a pure-Python implementation of the AMQP (Advanced Message Queuing
10184 Protocol) 0-9-1 protocol that tries to stay fairly independent of the underlying
10185 network support library.")
10186 (license license:bsd-3)))
10188 (define-public python2-pika
10189 (package-with-python2 python-pika))
10191 (define-public python-ply
10193 (name "python-ply")
10198 (uri (pypi-uri "ply" version))
10201 "1jxsr1d2f732r6ljhvm827113dckwl6qwakfvpbdhcbhvpvlmscn"))))
10202 (build-system python-build-system)
10203 (home-page "http://www.dabeaz.com/ply/")
10204 (synopsis "Python Lex & Yacc")
10205 (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python.
10206 It uses LR parsing and does extensive error checking.")
10207 (license license:bsd-3)))
10209 (define-public python2-ply
10210 (package-with-python2 python-ply))
10212 (define-public python-tabulate
10214 (name "python-tabulate")
10218 (uri (pypi-uri "tabulate" version))
10221 "1inqhspd4frxnp08c32yndr0lc4px1xfkqah184i5w09gkhvi843"))))
10222 (build-system python-build-system)
10224 ;; FIXME: The pypi release tarball is missing a 'test/common.py'
10225 ;; and the latest release is not tagged in the upstream repository.
10227 (home-page "https://bitbucket.org/astanin/python-tabulate")
10228 (synopsis "Pretty-print tabular data")
10230 "Tabulate is a library and command-line utility to pretty-print tabular
10232 (license license:expat)))
10234 (define-public python2-tabulate
10235 (package-with-python2 python-tabulate))
10237 (define-public python-kazoo
10239 (name "python-kazoo")
10244 (uri (pypi-uri "kazoo" version))
10247 "16y213k7r8shyn2zw1k6lkzjgcrvm441pqv8scvcjixhvpbx3hm7"))))
10248 (build-system python-build-system)
10249 (arguments '(#:tests? #f)) ; XXX: needs zookeeper
10251 `(("python-six" ,python-six)))
10252 (home-page "https://kazoo.readthedocs.org")
10253 (synopsis "High-level Zookeeper client library")
10255 "Kazoo is a Python client library for the Apache Zookeeper distributed
10256 application service. It is designed to be easy to use and to avoid common
10257 programming errors.")
10258 (license license:asl2.0)))
10260 (define-public python2-kazoo
10261 (package-with-python2 python-kazoo))
10263 (define-public python-pykafka
10265 (name "python-pykafka")
10269 (uri (pypi-uri "pykafka" version))
10272 "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv"))))
10273 (build-system python-build-system)
10274 (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc.
10276 `(("python-gevent" ,python-gevent)
10277 ("python-kazoo" ,python-kazoo)
10278 ("python-tabulate" ,python-tabulate)))
10280 `(("librdkafka" ,librdkafka)))
10281 (home-page "https://pykafka.readthedocs.io/")
10282 (synopsis "Apache Kafka client for Python")
10284 "PyKafka is a client for the Apache Kafka distributed messaging system.
10285 It includes Python implementations of Kafka producers and consumers, which
10286 are optionally backed by a C extension built on librdkafka.")
10287 (license license:asl2.0)))
10289 (define-public python2-pykafka
10290 (package-with-python2 python-pykafka))
10292 (define-public python-wcwidth
10294 (name "python-wcwidth")
10298 (uri (pypi-uri "wcwidth" version))
10301 "1a1pzds3xzfylm5mnc5f6c1p8kiig0daqjc9gygd9rc3cj53x2zj"))))
10302 (build-system python-build-system)
10303 (home-page "https://github.com/jquast/wcwidth")
10304 (synopsis "Measure number of terminal column cells of wide-character codes")
10305 (description "Wcwidth measures the number of terminal column cells of
10306 wide-character codes. It is useful for those implementing a terminal emulator,
10307 or programs that carefully produce output to be interpreted by one. It is a
10308 Python implementation of the @code{wcwidth} and @code{wcswidth} C functions
10309 specified in POSIX.1-2001 and POSIX.1-2008.")
10310 (license license:expat)))
10312 (define-public python2-wcwidth
10313 (package-with-python2 python-wcwidth))
10315 (define-public python2-jsonrpclib
10317 (name "python2-jsonrpclib")
10321 (uri (pypi-uri "jsonrpclib" version))
10324 "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z"))))
10325 (build-system python-build-system)
10328 #:python ,python-2))
10329 (home-page "https://github.com/joshmarshall/jsonrpclib/")
10330 (synopsis "Implementation of JSON-RPC specification for Python")
10332 "This library is an implementation of the JSON-RPC specification.
10333 It supports both the original 1.0 specification, as well as the
10334 new (proposed) 2.0 spec, which includes batch submission, keyword arguments,
10336 (license license:asl2.0)))
10338 (define-public python-chai
10340 (name "python-chai")
10344 (uri (pypi-uri "chai" version))
10347 "1k6n6zbgrrs83crp6mr3yqj9zlv40b8rpisyrliwsq7naml2p3gz"))))
10348 (build-system python-build-system)
10349 (home-page "https://github.com/agoragames/chai")
10350 (synopsis "Mocking framework for Python")
10352 "Chai provides an api for mocking, stubbing and spying your python
10353 objects, patterned after the Mocha library for Ruby.")
10354 (license license:bsd-3)))
10356 (define-public python2-chai
10357 (package-with-python2 python-chai))
10359 (define-public python-inflection
10361 (name "python-inflection")
10364 (origin (method url-fetch)
10365 (uri (pypi-uri "inflection" version))
10368 "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq"))))
10369 (build-system python-build-system)
10371 `(("python-pytest" ,python-pytest)))
10372 (home-page "https://github.com/jpvanhal/inflection")
10373 (synopsis "Python string transformation library")
10375 "Inflection is a string transformation library. It singularizes
10376 and pluralizes English words, and transforms strings from CamelCase to
10377 underscored string.")
10378 (license license:expat)))
10380 (define-public python2-inflection
10381 (package-with-python2 python-inflection))
10383 (define-public python-pylev
10385 (name "python-pylev")
10389 (uri (pypi-uri "pylev" version))
10392 "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86"))))
10393 (build-system python-build-system)
10394 (home-page "https://github.com/toastdriven/pylev")
10395 (synopsis "Levenshtein distance implementation in Python")
10396 (description "Pure Python Levenshtein implementation, based off the
10397 Wikipedia code samples at
10398 @url{http://en.wikipedia.org/wiki/Levenshtein_distance}.")
10399 (license license:bsd-3)))
10401 (define-public python2-pylev
10402 (package-with-python2 python-pylev))
10404 (define-public python-cleo
10406 (name "python-cleo")
10410 (uri (pypi-uri "cleo" version))
10413 "06zp695hq835rkaq6irr1ds1dp2qfzyf32v60vxpd8rcnxv319l5"))))
10414 (build-system python-build-system)
10417 ("python-mock" ,python-mock)
10418 ("python-pytest-mock" ,python-pytest-mock)
10419 ("python-pytest" ,python-pytest)))
10421 `(("python-backpack" ,python-backpack)
10422 ("python-pastel" ,python-pastel)
10423 ("python-pylev" ,python-pylev)))
10424 (home-page "https://github.com/sdispater/cleo")
10425 (synopsis "Command-line arguments library for Python")
10427 "Cleo allows you to create command-line commands with signature in
10428 docstring and colored output.")
10429 (license license:expat)))
10431 (define-public python2-cleo
10432 (package-with-python2 python-cleo))
10434 (define-public python-tomlkit
10436 (name "python-tomlkit")
10441 (uri (pypi-uri "tomlkit" version))
10444 "18820ga5z3if1w8dvykxrfm000akracq01ic402xrbljgbn5grn4"))))
10445 (build-system python-build-system)
10447 `(("python-pytest" ,python-pytest)))
10449 "https://github.com/sdispater/tomlkit")
10450 (synopsis "Style preserving TOML library")
10452 "TOML Kit is a 0.5.0-compliant TOML library. It includes a parser that
10453 preserves all comments, indentations, whitespace and internal element ordering,
10454 and makes them accessible and editable via an intuitive API. It can also
10455 create new TOML documents from scratch using the provided helpers. Part of the
10456 implementation as been adapted, improved and fixed from Molten.")
10457 (license license:expat)))
10459 (define-public python-shellingham
10461 (name "python-shellingham")
10466 (uri (pypi-uri "shellingham" version))
10469 "1q7kws7w4x2hji3g7y0ni9ddk4sd676ylrb3db54gbpys6xj6nwq"))))
10470 (build-system python-build-system)
10472 "https://github.com/sarugaku/shellingham")
10473 (synopsis "Tool to detect surrounding shell")
10475 "Shellingham detects what shell the current Python executable is
10477 (license license:isc)))
10479 (define-public python-memcached
10481 (name "python-memcached")
10486 (uri (pypi-uri "python-memcached" version))
10489 "0kvyapavbirk2x3n1jx4yb9nyigrj1s3x15nm3qhpvhkpqvqdqm2"))))
10490 (build-system python-build-system)
10491 (propagated-inputs `(("python-six" ,python-six)))
10493 "https://github.com/linsomniac/python-memcached")
10494 (synopsis "Pure python memcached client")
10496 "This software is a pure Python interface to the memcached memory cache
10497 daemon. It is the client side software which allows storing values in one or
10498 more, possibly remote, memcached servers.")
10499 (license license:psfl)))
10501 (define-public python-clikit
10503 (name "python-clikit")
10508 (uri (pypi-uri "clikit" version))
10511 "0dc8czib5f4j9px1ivcpqnmivnx2zjpc0xb00ldrhsqylks7r06n"))))
10512 (build-system python-build-system)
10514 `(("python-pastel" ,python-pastel)
10515 ("python-pylev" ,python-pylev)))
10516 (home-page "https://github.com/sdispater/clikit")
10517 (synopsis "Group of utilities to build command line interfaces")
10519 "CliKit is a group of utilities to build testable command line
10521 (license license:expat)))
10523 (define-public python-msgpack-python
10525 (name "python-msgpack-python")
10530 (uri (pypi-uri "msgpack-python" version))
10533 "16wh8qgybmfh4pjp8vfv78mdlkxfmcasg78lzlnm6nslsfkci31p"))))
10534 (build-system python-build-system)
10535 (home-page "http://msgpack.org/")
10536 (synopsis "Package to deserialize messages in MessagePack binary format")
10538 "MessagePack is an efficient binary serialization format. It lets you
10539 exchange data among multiple languages like JSON. But it's faster and
10540 smaller. Small integers are encoded into a single byte, and typical short
10541 strings require only one extra byte in addition to the strings themselves.")
10542 (license license:asl2.0)))
10544 (define-public python-cachy
10546 (name "python-cachy")
10551 (uri (pypi-uri "cachy" version))
10554 "0v6mjyhgx6j7ya20bk69cr3gdzdkdf6psay0h090rscclgji65dp"))))
10555 (build-system python-build-system)
10557 `(("python-fakeredis" ,python-fakeredis)
10558 ("python-flexmock" ,python-flexmock)
10559 ("python-pytest" ,python-pytest)))
10561 `(("python-memcached" ,python-memcached)
10562 ("python-msgpack-python" ,python-msgpack-python)
10563 ("python-redis" ,python-redis)))
10564 (home-page "https://github.com/sdispater/cachy")
10565 (synopsis "Simple yet effective caching library")
10567 "Cachy provides a simple yet effective caching library. A simple but
10568 powerful API: thread-safety; decorator syntax; support for memcached, redis,
10569 database, file, dict stores. Cachy supports python versions 2.7+ and 3.2+.")
10570 (license license:expat)))
10572 (define-public poetry
10575 (version "0.12.17")
10576 ;; Poetry can only be built from source with poetry.
10580 (uri (pypi-uri "poetry" version))
10583 "0gxwcd65qjmzqzppf53x51sic1rbcd9py6cdzx3aprppipimslvf"))))
10584 (build-system python-build-system)
10586 `(#:tests? #f ;; Pypi does not have tests.
10588 (modify-phases %standard-phases
10591 ;; Bug in poetry https://github.com/sdispater/poetry/issues/866.
10592 (invoke "sed" "-i" "-e" "s/from distutils.core/from setuptools/"
10596 `(("python-cachecontrol" ,python-cachecontrol)
10597 ("python-cachy" ,python-cachy)
10598 ("python-cleo" ,python-cleo)
10599 ("python-glob2" ,python-glob2)
10600 ("python-html5lib" ,python-html5lib)
10601 ("python-jsonschema" ,python-jsonschema)
10602 ("python-msgpack" ,python-msgpack)
10603 ("python-pkginfo" ,python-pkginfo)
10604 ("python-pyparsing" ,python-pyparsing)
10605 ("python-pyrsistent" ,python-pyrsistent)
10606 ("python-requests" ,python-requests)
10607 ("python-requests-toolbelt" ,python-requests-toolbelt)
10608 ("python-shellingham" ,python-shellingham)
10609 ("python-tomlkit" ,python-tomlkit)
10610 ("python-virtualenv" ,python-virtualenv)))
10611 (home-page "https://poetry.eustace.io/")
10612 (synopsis "Python dependency management and packaging made easy")
10613 (description "Poetry is a tool for dependency management and packaging
10614 in Python. It allows you to declare the libraries your project depends on and
10615 it will manage (install/update) them for you.")
10616 (license license:expat)))
10618 (define-public python-lazy-object-proxy
10620 (name "python-lazy-object-proxy")
10624 (uri (pypi-uri "lazy-object-proxy" version))
10627 "1w1aaay424ciz8fz3fkzxb0pxzfxn184f2whpyn4fx72bn50x47k"))))
10629 `(("python-setuptools-scm" ,python-setuptools-scm-3.3)))
10630 (build-system python-build-system)
10631 (home-page "https://github.com/ionelmc/python-lazy-object-proxy")
10632 (synopsis "Lazy object proxy for python")
10634 "Lazy object proxy is an object that wraps a callable but defers the call
10635 until the object is actually required, and caches the result of said call.")
10636 (license license:bsd-2)))
10638 (define-public python2-lazy-object-proxy
10639 (package-with-python2 python-lazy-object-proxy))
10641 (define-public python-dnspython
10643 (name "python-dnspython")
10647 (uri (string-append "http://www.dnspython.org/kits/"
10648 version "/dnspython-" version ".tar.gz"))
10651 "0jr4v2pd90i6l1xxbss2m05psbjaxvyvvvpq44wycijpfgjqln8i"))))
10652 (build-system python-build-system)
10653 (arguments '(#:tests? #f)) ; XXX: requires internet access
10654 (home-page "http://www.dnspython.org")
10655 (synopsis "DNS toolkit for Python")
10657 "dnspython is a DNS toolkit for Python. It supports almost all record
10658 types. It can be used for queries, zone transfers, and dynamic updates.
10659 It supports TSIG authenticated messages and EDNS0.")
10660 (license license:expat)))
10662 (define-public python2-dnspython
10663 (package-with-python2 python-dnspython))
10665 (define-public python-email-validator
10667 (name "python-email-validator")
10670 (origin (method url-fetch)
10671 (uri (pypi-uri "email_validator" version))
10674 "1ja9149l9ck5n45a72h3is7v476hjny5ybxbcamx1nw6iplsm7k6"))))
10675 (build-system python-build-system)
10678 (modify-phases %standard-phases
10679 (add-before 'build 'use-dnspython
10681 (substitute* "setup.py"
10682 (("dnspython3") "dnspython"))
10685 `(("python-dnspython" ,python-dnspython)
10686 ("python-idna" ,python-idna)))
10687 (home-page "https://github.com/JoshData/python-email-validator")
10688 (synopsis "Email address validation library for Python")
10690 "This library validates email address syntax and deliverability.")
10691 (license license:cc0)))
10693 (define-public python2-email-validator
10694 (package-with-python2 python-email-validator))
10696 (define-public python-ukpostcodeparser
10698 (name "python-ukpostcodeparser")
10702 (uri (pypi-uri "UkPostcodeParser" version))
10705 "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd"))))
10706 (build-system python-build-system)
10707 (home-page "https://github.com/hamstah/ukpostcodeparser")
10708 (synopsis "UK Postcode parser for Python")
10710 "This library provides the @code{parse_uk_postcode} function for
10711 parsing UK postcodes.")
10712 (license license:expat)))
10714 (define-public python2-ukpostcodeparser
10715 (package-with-python2 python-ukpostcodeparser))
10717 (define-public python-faker
10719 (name "python-faker")
10723 (uri (pypi-uri "Faker" version))
10726 "1fh2p2yz0fsdr4fqwxgddwbvfb6qn6vp8yx0qwqzra27yq5d1wsm"))
10728 (search-patches "python-faker-fix-build-32bit.patch"))
10729 (modules '((guix build utils)))
10732 (for-each delete-file (find-files "." "\\.pyc$"))
10734 (build-system python-build-system)
10737 (modify-phases %standard-phases
10739 (lambda _ (invoke "python" "-m" "unittest" "-v" "tests"))))))
10742 ("python-email-validator" ,python-email-validator)
10743 ("python-mock" ,python-mock)
10744 ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
10746 `(("python-dateutil" ,python-dateutil)
10747 ("python-six" ,python-six)))
10748 (home-page "https://github.com/joke2k/faker")
10749 (synopsis "Python package that generates fake data")
10751 "Faker is a Python package that generates fake data such as names,
10752 addresses, and phone numbers.")
10753 (license license:expat)
10754 (properties `((python2-variant . ,(delay python2-faker))))))
10756 (define-public python2-faker
10757 (let ((base (package-with-python2 (strip-python2-variant
10762 `(("python2-ipaddress" ,python2-ipaddress)
10763 ,@(package-propagated-inputs base))))))
10765 (define-public python-pyaml
10767 (name "python-pyaml")
10768 (version "18.11.0")
10771 (uri (pypi-uri "pyaml" version))
10774 "0fi604ix8lbpj1266q7js6szm771saprdzzcdwmj43wy83694qmr"))))
10775 (build-system python-build-system)
10777 `(("python-unidecode" ,python-unidecode)))
10779 `(("python-pyyaml" ,python-pyyaml)))
10780 (home-page "https://github.com/mk-fg/pretty-yaml")
10781 (synopsis "YAML pretty-print library for Python")
10783 "pyaml is a PyYAML based python module to produce pretty and readable
10784 YAML-serialized data.")
10785 (license license:wtfpl2)))
10787 (define-public python2-pyaml
10788 (package-with-python2 python-pyaml))
10790 (define-public python-backpack
10792 (name "python-backpack")
10797 (uri (pypi-uri "backpack" version))
10800 "14rq1mvm0jda90lcx9gyyby9dvq4x3js2cmxvd6vl4686ixwyqh1"))))
10801 (build-system python-build-system)
10803 `(("python-pytest" ,python-pytest)
10804 ("python-nose" ,python-nose)))
10806 `(("python-simplejson" ,python-simplejson)))
10807 (home-page "https://github.com/sdispater/backpack")
10808 (synopsis "Utilities for working with Python collections")
10809 (description "Backpack provides some useful utilities for working with
10810 collections of data.")
10811 (license license:expat)))
10813 (define-public python2-backpack
10814 (package-with-python2 python-backpack))
10816 (define-public python-prompt-toolkit
10818 (name "python-prompt-toolkit")
10823 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
10826 "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
10827 (build-system python-build-system)
10830 (modify-phases %standard-phases
10832 (add-after 'install 'post-install-check
10833 (lambda* (#:key inputs outputs #:allow-other-keys)
10834 ;; HOME is needed for the test
10835 ;; "test_pathcompleter_can_expanduser".
10836 (setenv "HOME" "/tmp")
10837 (add-installed-pythonpath inputs outputs)
10838 (invoke "py.test"))))))
10840 `(("python-wcwidth" ,python-wcwidth)
10841 ("python-six" ,python-six)
10842 ("python-pygments" ,python-pygments)))
10844 `(("python-pytest" ,python-pytest)))
10845 (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
10846 (synopsis "Library for building command line interfaces in Python")
10848 "Prompt-Toolkit is a library for building interactive command line
10849 interfaces in Python. It's like GNU Readline but it also features syntax
10850 highlighting while typing, out-of-the-box multi-line input editing, advanced
10851 code completion, incremental search, support for Chinese double-width
10852 characters, mouse support, and auto suggestions.")
10853 (license license:bsd-3)))
10855 (define-public python2-prompt-toolkit
10856 (package-with-python2 python-prompt-toolkit))
10858 (define-public python-prompt-toolkit-1
10859 (package (inherit python-prompt-toolkit)
10864 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
10867 "05v9h5nydljwpj5nm8n804ms0glajwfy1zagrzqrg91wk3qqi1c5"))))))
10869 (define-public python2-prompt-toolkit-1
10870 (package-with-python2 python-prompt-toolkit-1))
10872 (define-public python-jedi
10874 (name "python-jedi")
10879 (uri (pypi-uri "jedi" version))
10882 "0bp4pxhsynaarbvzblsn5x32lzp29svy3sxfy8i6m5iwz9s9r1ds"))))
10883 (build-system python-build-system)
10886 (modify-phases %standard-phases
10887 (add-after 'unpack 'disable-file-completion-test
10888 ;; A single parameterized test currently fail (see:
10889 ;; https://github.com/davidhalter/jedi/issues/1395). Remove it.
10891 (substitute* "test/test_api/test_completion.py"
10892 ((".*'example.py', 'rb\"' \\+ join\\('\\.\\.'.*") ""))
10896 (setenv "HOME" "/tmp")
10897 (invoke "python" "-m" "pytest"))))))
10899 `(("python-pytest" ,python-pytest)
10900 ("python-docopt" ,python-docopt)))
10902 `(("python-parso" ,python-parso)))
10903 (home-page "https://github.com/davidhalter/jedi")
10904 (synopsis "Autocompletion and static analysis library for Python")
10906 "Jedi is a static analysis tool for Python that can be used in Integrated
10907 Development Environments (@dfn{IDE}s) and text editors. It understands Python
10908 on a deeper level than many other static analysis frameworks for Python.
10910 Jedi understands docstrings and you can use Jedi autocompletion in your REPL as
10912 (license license:expat)))
10914 (define-public python2-jedi
10915 (package-with-python2 python-jedi))
10917 (define-public ptpython
10923 (uri (pypi-uri "ptpython" version))
10926 "1mmbiyzf0n8hm7z2a562x7w5cbl6jc0zsk6vp40q1z4cyblv1k13"))))
10927 (build-system python-build-system)
10929 '(#:tests? #f)) ; FIXME: No tests in pypi tarball.
10931 `(("python-docopt" ,python-docopt)
10932 ("python-jedi" ,python-jedi)
10933 ("python-prompt-toolkit" ,python-prompt-toolkit)
10934 ("python-pygments" ,python-pygments)))
10935 (home-page "https://github.com/jonathanslenders/ptpython")
10936 (synopsis "Python Read-Eval-Print-Loop with nice IDE-like features")
10938 "ptpython is a Python read-eval-print loop with IDE-like features.
10939 It supports syntax highlighting, multiline editing, autocompletion, mouse,
10940 color schemes, bracketed paste, Vi and Emacs keybindings, Chinese characters
10942 (license license:bsd-3)
10943 (properties `((python2-variant . ,(delay ptpython-2))))))
10945 (define-public ptpython-2
10946 (let ((base (package-with-python2 (strip-python2-variant ptpython))))
10949 (name "ptpython2"))))
10951 (define-public python-stem
10953 (name "python-stem")
10958 (uri (pypi-uri "stem" version))
10961 "18lc95pmc7i089nlsb06dsxyjl5wbhxfqgdxbjcia35ndh8z7sn9"))))
10962 (build-system python-build-system)
10965 (modify-phases %standard-phases
10968 (invoke "./run_tests.py" "--unit")
10971 `(("python-mock" ,python-mock)
10972 ("python-pycodestyle" ,python-pycodestyle)
10973 ("python-pyflakes" ,python-pyflakes)))
10974 (home-page "https://stem.torproject.org/")
10976 "Python controller library that allows applications to interact with Tor")
10978 "Stem is a Python controller library for Tor. With it you can use Tor's
10979 control protocol to script against the Tor process and read descriptor data
10980 relays publish about themselves.")
10981 (license license:lgpl3)))
10983 (define-public python2-stem
10984 (package-with-python2 python-stem))
10986 (define-public python-pyserial
10988 (name "python-pyserial")
10993 (uri (pypi-uri "pyserial" version))
10996 "09y68bczw324a4jb9a1cfwrbjhq179vnfkkkrybbksp0vqgl0bbf"))))
10997 (build-system python-build-system)
10999 '(#:tests? #f)) ; FIXME: 3/49 tests are failing.
11001 ;; (modify-phases %standard-phases
11004 ;; (zero? (system* "python" "test/run_all_tests.py" "loop://")))))))
11006 "https://github.com/pyserial/pyserial")
11007 (synopsis "Python Serial Port Bindings")
11008 (description "@code{pyserial} provide serial port bindings for Python. It
11009 supports different byte sizes, stop bits, parity and flow control with RTS/CTS
11010 and/or Xon/Xoff. The port is accessed in RAW mode.")
11011 (license license:bsd-3)))
11013 (define-public python2-pyserial
11014 (package-with-python2 python-pyserial))
11016 (define-public python-kivy
11018 (name "python-kivy")
11023 (uri (pypi-uri "Kivy" version))
11024 (file-name (string-append name "-" version ".tar.gz"))
11027 "1zzxjdp78hfjjiklzr82l4zwibwcq4j6kgicspqs6iyyfn5yisbw"))))
11028 (build-system python-build-system)
11030 `(#:tests? #f ; Tests require many optional packages
11032 (modify-phases %standard-phases
11033 (add-after 'patch-generated-file-shebangs 'set-sdl-paths
11034 (lambda* (#:key inputs #:allow-other-keys)
11035 (setenv "KIVY_SDL2_PATH"
11036 (string-append (assoc-ref inputs "sdl-union")
11041 ("pkg-config" ,pkg-config)
11042 ("python-cython" ,python-cython)))
11044 `(("gstreamer" ,gstreamer)
11047 ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))))
11048 (home-page "http://kivy.org")
11050 "Multitouch application framework")
11052 "A software library for rapid development of
11053 hardware-accelerated multitouch applications.")
11054 (license license:expat)))
11056 (define-public python2-kivy
11057 (package-with-python2 python-kivy))
11059 (define-public python-kivy-next
11060 (deprecated-package "python-kivy-next" python-kivy))
11062 (define-public python2-kivy-next
11063 (deprecated-package "python2-kivy-next" python2-kivy))
11065 (define-public python-binaryornot
11067 (name "python-binaryornot")
11071 (uri (pypi-uri "binaryornot" version))
11074 "0qc006986rb6bcbmiymwgcl1mns2jphr1j7sr7nk41nlr7gh359m"))))
11075 (build-system python-build-system)
11078 (modify-phases %standard-phases
11079 (add-after 'unpack 'patch-tests
11081 ;; TypeError: binary() got an unexpected keyword argument
11083 (substitute* "tests/test_check.py"
11084 (("average_size=512") ""))
11087 `(("python-chardet" ,python-chardet)
11088 ("python-hypothesis" ,python-hypothesis)))
11089 (home-page "https://github.com/audreyr/binaryornot")
11090 (synopsis "Package to check if a file is binary or text")
11091 (description "Ultra-lightweight pure Python package to check if a file is
11093 (license license:bsd-3)
11094 (properties `((python2-variant . ,(delay python2-binaryornot))))))
11096 (define-public python2-binaryornot
11097 (let ((base (package-with-python2 (strip-python2-variant python-binaryornot))))
11098 (package (inherit base)
11100 `(("python2-enum34" ,python2-enum34)
11101 ,@(package-propagated-inputs base))))))
11103 (define-public python-binwalk
11104 (let ((commit "64201acfb5b0a9cdd9faa58c40a36dcff8612e29")
11107 (name "python-binwalk")
11108 (version (git-version "2.1.1" revision commit))
11112 (uri (git-reference
11113 (url "https://github.com/ReFirmLabs/binwalk")
11115 (file-name (git-file-name name version))
11118 "1z7ca6rfp887hw5jc3sb45mm4fa0xid4lsp2z8g4r590dr7k7w15"))))
11119 (build-system python-build-system)
11122 (modify-phases %standard-phases
11123 (add-before 'check 'set-pythonpath
11125 (setenv "PYTHONPATH"
11128 ":" (getenv "PYTHONPATH")))
11132 `(("python-coverage" ,python-coverage)
11133 ("python-nose" ,python-nose)))
11134 (home-page "https://github.com/ReFirmLabs/binwalk")
11135 (synopsis "Firmware analysis tool")
11136 (description "Binwalk is a tool for analyzing, reverse engineering, and extracting firmware images")
11137 (license license:expat))))
11139 (define-public python-nltk
11141 (name "python-nltk")
11145 (uri (pypi-uri "nltk" version))
11148 "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"))))
11149 (build-system python-build-system)
11151 '(;; The tests require some extra resources to be downloaded.
11152 ;; TODO Try packaging these resources.
11154 (home-page "http://nltk.org/")
11155 (synopsis "Natural Language Toolkit")
11156 (description "It provides interfaces to over 50 corpora and lexical
11157 resources such as WordNet, along with a suite of text processing libraries
11158 for classification, tokenization, stemming, tagging, parsing, and semantic
11159 reasoning, wrappers for natural language processing libraries.")
11160 (license license:asl2.0)))
11162 (define-public python2-nltk
11163 (package-with-python2 python-nltk))
11165 (define-public python-pymongo
11167 (name "python-pymongo")
11171 (uri (pypi-uri "pymongo" version))
11174 "0zis4707r9hdg5qgkhp3wss9camr9h56ixyfc8n9dxwlnnly4x4c"))))
11175 (build-system python-build-system)
11177 `(("python-certifi" ,python-certifi)))
11178 (home-page "https://github.com/mongodb/mongo-python-driver")
11179 (synopsis "Python driver for MongoDB")
11180 (description "Python driver for MongoDB.")
11181 (license license:asl2.0)))
11183 (define-public python2-pymongo
11184 (package-with-python2 python-pymongo))
11186 (define-public python-consul
11188 (name "python-consul")
11193 (uri (pypi-uri "python-consul" version))
11196 "0rfyxcy4cr3x848vhx876ifalxd5ghq6l5x813m49h4vq2d4jiq8"))))
11197 (build-system python-build-system)
11199 '(#:tests? #f)) ; The tests are not distributed
11201 `(("python-requests" ,python-requests)
11202 ("python-six" ,python-six)))
11203 (home-page "https://github.com/cablehead/python-consul")
11204 (synopsis "Python client for Consul")
11206 "Python client for @url{http://www.consul.io/,Consul}, a tool for service
11207 discovery, monitoring and configuration.")
11208 (license license:expat)))
11210 (define-public python2-consul
11211 (package-with-python2 python-consul))
11213 (define-public python-schematics
11215 (name "python-schematics")
11220 (uri (git-reference
11221 (url "https://github.com/schematics/schematics.git")
11222 (commit (string-append "v" version))))
11223 (file-name (git-file-name name version))
11225 (base32 "0xdqskycznqc7mfp60bhw1zq8wx7yx1dvmbq3brnm1dx3xnqa0zd"))))
11226 (build-system python-build-system)
11228 `(("python-six" ,python-six)))
11230 ;; The tests require a bunch of not very nice packages with fixed
11231 ;; version requirements (e.g. python-coveralls).
11233 (home-page "https://github.com/schematics/schematics")
11234 (synopsis "Python Data Structures for Humans")
11235 (description "Python Data Structures for Humans.")
11236 (license license:bsd-3)))
11238 (define-public python2-schematics
11239 (package-with-python2 python-schematics))
11241 (define-public python-odfpy
11243 (name "python-odfpy")
11247 (uri (pypi-uri "odfpy" version))
11250 "1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"))))
11252 `(#:modules ((srfi srfi-1)
11253 (guix build python-build-system)
11254 (guix build utils))
11256 (modify-phases %standard-phases
11258 ;; The test runner invokes python2 and python3 for test*.py.
11259 ;; To avoid having both in inputs, we replicate it here.
11261 (for-each (lambda (test-file) (invoke "python" test-file))
11262 (find-files "tests" "^test.*\\.py$"))
11264 (build-system python-build-system)
11265 (home-page "https://github.com/eea/odfpy")
11266 (synopsis "Python API and tools to manipulate OpenDocument files")
11267 (description "Collection of libraries and utility programs written in
11268 Python to manipulate OpenDocument 1.2 files.")
11270 ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
11271 ;; number of files with other licenses.
11272 (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0))))
11274 (define-public python2-odfpy
11275 (package-with-python2 python-odfpy))
11277 (define-public python-natsort
11279 (name "python-natsort")
11283 (uri (pypi-uri "natsort" version))
11286 "0i732amg6yzkx4g4c9j09jmqq39q377x9cl2nbkm5hax2c2v0wxf"))))
11287 (build-system python-build-system)
11289 `(#:modules ((guix build utils)
11290 (guix build python-build-system)
11295 (modify-phases %standard-phases
11296 (add-before 'check 'set-cachedir
11297 ;; Tests require write access to $HOME by default
11298 (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t))
11301 (let ((cwd (getcwd)))
11302 (setenv "PYTHONPATH"
11305 (find (cut string-prefix? "lib" <>)
11306 (scandir (string-append cwd "/build")))
11308 (getenv "PYTHONPATH")))
11309 (invoke "pytest" "-v")))))))
11311 `(("python-hypothesis" ,python-hypothesis)
11312 ("python-pytest-cov" ,python-pytest-cov)
11313 ("python-pytest-mock" ,python-pytest-mock)
11314 ("python-pytest" ,python-pytest)))
11315 (propagated-inputs ; TODO: Add python-fastnumbers.
11316 `(("python-pyicu" ,python-pyicu)))
11317 (home-page "https://github.com/SethMMorton/natsort")
11318 (synopsis "Natural sorting for python and shell")
11320 "Natsort lets you apply natural sorting on lists instead of
11321 lexicographical. If you use the built-in @code{sorted} method in python
11322 on a list such as @code{[@code{a20}, @code{a9}, @code{a1}, @code{a4},
11323 @code{a10}]}, it would be returned as @code{[@code{a1}, @code{a10}, @code{a20},
11324 @code{a4}, @code{a9}]}. Natsort provides a function @code{natsorted} that
11325 identifies numbers and sorts them separately from strings. It can also sort
11326 version numbers, real numbers, mixed types and more, and comes with a shell
11327 command @command{natsort} that exposes this functionality in the command line.")
11328 (license license:expat)
11329 (properties `((python2-variant . ,(delay python2-natsort))))))
11331 (define-public python2-natsort
11332 (let ((base (package-with-python2 (strip-python2-variant python-natsort))))
11333 (package (inherit base)
11335 `(("python2-pathlib" ,python2-pathlib)
11336 ,@(package-native-inputs base))))))
11338 (define-public python-glances
11340 (name "python-glances")
11345 (uri (pypi-uri "Glances" version))
11347 (base32 "15384pbvw9wj4sb8zgvd9v1812vrypbyjg0acicjf1hdb3p30fkk"))
11348 (modules '((guix build utils)))
11351 ;; Glances phones PyPI for weekly update checks by default.
11352 ;; Disable these. The user can re-enable them if desired.
11353 (substitute* "glances/outdated.py"
11354 (("^(.*)self\\.load_config\\(config\\)\n" line indentation)
11355 (string-append indentation
11356 "self.args.disable_check_update = True\n"
11359 (build-system python-build-system)
11361 `(("python-future" ,python-future)
11362 ("python-psutil" ,python-psutil)))
11363 (home-page "https://github.com/nicolargo/glances")
11364 (synopsis "Cross-platform curses-based monitoring tool")
11366 "Glances is a curses-based monitoring tool for a wide variety of platforms.
11367 Glances uses the PsUtil library to get information from your system. It
11368 monitors CPU, load, memory, network bandwidth, disk I/O, disk use, and more.")
11369 (license license:lgpl3+)))
11371 (define-public python2-glances
11372 (package-with-python2 python-glances))
11374 (define-public python-graphql-core
11376 (name "python-graphql-core")
11381 (uri (pypi-uri "graphql-core" version))
11384 "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0"))))
11385 (build-system python-build-system)
11387 `(#:tests? #f ; Tests require the unpackaged pytest-benchmark.
11389 (modify-phases %standard-phases
11390 (add-after 'unpack 'patch-hardcoded-version
11391 (lambda _ (substitute*
11393 (("'gevent==1.1rc1'") "'gevent'"))
11396 `(("python-gevent" ,python-gevent)
11397 ("python-mock" ,python-mock)
11398 ("python-pytest-mock" ,python-pytest-mock)))
11400 `(("python-promise" ,python-promise)
11401 ("python-six" ,python-six)))
11402 (home-page "https://github.com/graphql-python/graphql-core")
11403 (synopsis "GraphQL implementation for Python")
11405 "GraphQL implementation for Python. GraphQL is a data query language and
11406 runtime designed and used to request and deliver data to mobile and web apps.
11407 This library is a port of @url{https://github.com/graphql/graphql-js,graphql-js}
11409 (license license:expat)))
11411 (define-public python2-graphql-core
11412 (package-with-python2 python-graphql-core))
11414 (define-public python-graphql-relay
11416 (name "python-graphql-relay")
11421 (uri (pypi-uri "graphql-relay" version))
11424 "1nv5dxcj59zv31qvl8bd142njmxcmymny2dz3br1l2cpbljbf5i7"))))
11425 (build-system python-build-system)
11427 '(#:tests? #f)) ; The tests are not distributed
11429 `(("python-graphql-core" ,python-graphql-core)
11430 ("python-promise" ,python-promise)
11431 ("python-six" ,python-six)))
11432 (home-page "https://github.com/graphql-python/graphql-relay-py")
11433 (synopsis "Relay implementation for Python")
11435 "This is a library to allow the easy creation of Relay-compliant servers
11436 using the GraphQL Python reference implementation of a GraphQL server. It
11437 should be noted that the code is a exact port of the original
11438 @url{https://github.com/graphql/graphql-relay-js,graphql-relay js implementation}
11440 (license license:expat)))
11442 (define-public python2-graphql-relay
11443 (package-with-python2 python-graphql-relay))
11445 (define-public python-graphene
11447 (name "python-graphene")
11452 (uri (pypi-uri "graphene" version))
11455 "09zhac7igh9ixdz0ay6csy35b40l1jwbf2wrbxmgxwfhy51iy06q"))))
11456 (build-system python-build-system)
11458 `(("python-graphql-core" ,python-graphql-core)
11459 ("python-graphql-relay" ,python-graphql-relay)
11460 ("python-iso8601" ,python-iso8601)
11461 ("python-promise" ,python-promise)
11462 ("python-six" ,python-six)))
11464 `(#:tests? #f)) ; no tests/ in the PyPI tarball
11465 (home-page "http://graphene-python.org/")
11466 (synopsis "GraphQL Framework for Python")
11468 "Graphene is a Python library for building GraphQL schemas/types.
11469 A GraphQL schema describes your data model, and provides a GraphQL server
11470 with an associated set of resolve methods that know how to fetch data.")
11471 (properties `((python2-variant . ,(delay python2-graphene))))
11472 (license license:expat)))
11474 (define-public python2-graphene
11475 (let ((base (package-with-python2
11476 (strip-python2-variant python-graphene))))
11477 (package (inherit base)
11479 `(("python2-sqlalchemy" ,python2-sqlalchemy)
11480 ,@(package-native-inputs base))))))
11482 (define-public python-nautilus
11484 (name "python-nautilus")
11489 (uri (pypi-uri "nautilus" version))
11492 "01hwzjc1zshk4vvxrcghm398fpy4jls66dyz06g07mrwqif8878p"))))
11493 (build-system python-build-system)
11494 (arguments `(#:tests? #f)) ; fails to import test modules
11496 `(("python-bcrypt" ,python-bcrypt)
11497 ("python-click" ,python-click)
11498 ("python-consul" ,python-consul)
11499 ("python-graphene" ,python-graphene)
11500 ("python-jinja2" ,python-jinja2)
11501 ("python-peewee" ,python-peewee)
11502 ("python-pika" ,python-pika)
11503 ("python-tornado" ,python-tornado)
11504 ("python-wtforms" ,python-wtforms)))
11506 `(("python-nose2" ,python-nose2)))
11507 (home-page "https://github.com/AlecAivazis/nautilus")
11508 (synopsis "Library for creating microservice applications")
11510 "Nautilus is a framework for flux based microservices that looks to
11511 provide extendible implementations of common aspects of a cloud so that you can
11512 focus on building massively scalable web applications.")
11513 (license license:expat)))
11515 (define-public python-snowballstemmer
11517 (name "python-snowballstemmer")
11521 (uri (pypi-uri "snowballstemmer" version))
11524 "0a0idq4y5frv7qsg2x62jd7rd272749xk4x99misf5rcifk2d7wi"))))
11525 (build-system python-build-system)
11527 `(;; No tests exist
11529 (home-page "https://github.com/shibukawa/snowball_py")
11530 (synopsis "Snowball stemming library collection for Python")
11531 (description "This package provides 16 word stemmer algorithms generated
11532 from Snowball algorithms. It includes the 15 original ones plus the Poerter
11534 (license license:bsd-3)))
11536 (define-public python2-snowballstemmer
11537 (package-with-python2 python-snowballstemmer))
11539 (define-public python-setproctitle
11541 (name "python-setproctitle")
11546 (uri (pypi-uri "setproctitle" version))
11549 "163kplw9dcrw0lffq1bvli5yws3rngpnvrxrzdw89pbphjjvg0v2"))))
11550 (build-system python-build-system)
11553 (modify-phases %standard-phases
11554 (add-before 'check 'patch-Makefile
11555 ;; Stricly this is only required for the python2 variant.
11556 ;; But adding a phase in an inherited package seems to be
11557 ;; cumbersum. So we patch even for python3.
11559 (let ((nose (assoc-ref %build-inputs "python2-nose")))
11561 (substitute* "Makefile"
11562 (("\\$\\(PYTHON\\) [^ ]which nosetests[^ ] ")
11563 (string-append nose "/bin/nosetests "))))
11567 (setenv "PYTHON" (or (which "python3") (which "python")))
11568 (setenv "PYCONFIG" (or (which "python3-config")
11569 (which "python-config")))
11570 (setenv "CC" "gcc")
11571 ;; No need to extend PYTHONPATH to find the built package, since
11572 ;; the Makefile will build anyway
11573 (invoke "make" "check"))))))
11575 `(("procps" ,procps))) ; required for tests
11577 "https://github.com/dvarrazzo/py-setproctitle")
11579 "Setproctitle implementation for Python to customize the process title")
11580 (description "The library allows a process to change its title (as displayed
11581 by system tools such as ps and top).
11583 Changing the title is mostly useful in multi-process systems, for
11584 example when a master process is forked: changing the children's title
11585 allows to identify the task each process is busy with. The technique
11586 is used by PostgreSQL and the OpenSSH Server for example.")
11587 (license license:bsd-3)
11588 (properties `((python2-variant . ,(delay python2-setproctitle))))))
11590 (define-public python2-setproctitle
11591 (let ((base (package-with-python2
11592 (strip-python2-variant python-setproctitle))))
11595 (native-inputs `(("python2-nose" ,python2-nose)
11596 ,@(package-native-inputs base))))))
11598 (define-public python-validictory
11600 (name "python-validictory")
11605 (uri (pypi-uri "validictory" version))
11608 "1zf1g9sw47xzp5f80bd94pb42j9yqv82lcrgcvdwr6nkaphfi37q"))))
11609 (build-system python-build-system)
11612 (modify-phases %standard-phases
11613 (add-after 'unpack 'bootstrap
11614 ;; Move the tests out of the package directory to avoid
11617 (rename-file "validictory/tests" "tests")
11618 (delete-file "tests/__init__.py")))
11621 ;; Extend PYTHONPATH so the built package will be found.
11622 (setenv "PYTHONPATH"
11623 (string-append (getcwd) "/build/lib:"
11624 (getenv "PYTHONPATH")))
11625 (invoke "py.test" "-vv" ))))))
11627 `(("python-pytest" ,python-pytest)))
11629 "https://github.com/jamesturk/validictory")
11630 (synopsis "General purpose Python data validator")
11631 (description "It allows validation of arbitrary Python data structures.
11633 The schema format is based on the JSON Schema
11634 proposal (http://json-schema.org), so combined with json the library is also
11635 useful as a validator for JSON data.")
11636 (license license:expat)))
11638 (define-public python2-validictory
11639 (package-with-python2 python-validictory))
11641 (define-public python-pyelftools
11643 (name "python-pyelftools")
11648 (uri (pypi-uri "pyelftools" version))
11651 "090vdksbz341f7ljvr0zswblw4lspa8qaiikzyjkf318arpxmil9"))))
11652 (build-system python-build-system)
11655 (modify-phases %standard-phases
11656 (add-before 'check 'set-pythonpath
11658 (setenv "PYTHONPATH"
11661 ":" (getenv "PYTHONPATH")))
11664 "https://github.com/eliben/pyelftools")
11666 "Analyze binary and library file information")
11667 (description "This Python library provides interfaces for parsing and
11668 analyzing two binary and library file formats; the Executable and Linking
11669 Format (ELF), and debugging information in the Debugging With Attributed
11670 Record Format (DWARF).")
11671 (license license:public-domain)))
11673 (define-public python-pyev
11675 (name "python-pyev")
11680 (uri (pypi-uri "pyev" version))
11683 "0rf603lc0s6zpa1nb25vhd8g4y337wg2wyz56i0agsdh7jchl0sx"))))
11684 (build-system python-build-system)
11686 `(#:tests? #f ; no test suite
11688 (modify-phases %standard-phases
11689 (add-after 'unpack 'patch
11690 (lambda* (#:key inputs #:allow-other-keys)
11691 (let ((libev (string-append (assoc-ref inputs "libev")
11692 "/lib/libev.so.4")))
11693 (substitute* "setup.py"
11694 (("libev_dll_name = find_library\\(\\\"ev\\\"\\)")
11695 (string-append "libev_dll_name = \"" libev "\"")))))))))
11697 `(("libev" ,libev)))
11698 (home-page "http://pythonhosted.org/pyev/")
11699 (synopsis "Python libev interface")
11700 (description "Pyev provides a Python interface to libev.")
11701 (license license:gpl3)))
11703 (define-public python2-pyev
11704 (package-with-python2 python-pyev))
11706 (define-public python-imagesize
11708 (name "python-imagesize")
11713 (uri (pypi-uri "imagesize" version))
11716 "1dg3wn7qpwmhgqc0r9na2ding1wif9q5spz3j9zn2riwphc2k0zk"))))
11717 (build-system python-build-system)
11718 (home-page "https://github.com/shibukawa/imagesize_py")
11719 (synopsis "Gets image size of files in various formats in Python")
11721 "This package allows determination of image size from
11722 PNG, JPEG, JPEG2000 and GIF files in pure Python.")
11723 (license license:expat)))
11725 (define-public python2-imagesize
11726 (package-with-python2 python-imagesize))
11728 (define-public python-termstyle
11730 (name "python-termstyle")
11735 (uri (pypi-uri "termstyle" version))
11738 "17wzkkcqy5zc0g68xlad3kcv66iw14d2pwqc0h9420gak0vbhx7g"))))
11739 (build-system python-build-system)
11742 (modify-phases %standard-phases
11745 (invoke "python" "test3.py"))))))
11746 (home-page "https://github.com/gfxmonk/termstyle")
11747 (synopsis "Console text coloring for Python")
11748 (description "This package provides console text coloring for Python.")
11749 (license license:bsd-3)))
11751 (define-public python-argcomplete
11753 (name "python-argcomplete")
11758 (uri (pypi-uri "argcomplete" version))
11761 "02jkc44drb0yjz6x28lvg6rj607n8r2irdpdvyylm8xnycn54zx3"))))
11762 (build-system python-build-system)
11765 (modify-phases %standard-phases
11766 (add-after 'unpack 'embed-tool-references
11768 (substitute* "argcomplete/bash_completion.d/python-argcomplete.sh"
11770 (string-append " " (which "grep")))
11772 (string-append " " (which "egrep")))
11774 (string-append "elif " (which "which")))
11776 (string-append "$(" (which "which"))))
11782 `(("python-coverage" ,python-coverage)
11783 ("python-flake8" ,python-flake8)
11784 ("python-pexpect" ,python-pexpect)
11785 ("python-wheel" ,python-wheel)
11788 ("bash-full" ,bash))) ;full Bash for 'test_file_completion'
11789 (home-page "https://github.com/kislyuk/argcomplete")
11790 (synopsis "Shell tab completion for Python argparse")
11791 (description "argcomplete provides extensible command line tab completion
11792 of arguments and options for Python scripts using @code{argparse}. It's
11793 particularly useful for programs with many options or sub-parsers that can
11794 dynamically suggest completions; for example, when browsing resources over the
11796 (license license:asl2.0)))
11798 (define-public python2-argcomplete
11799 (package-with-python2 python-argcomplete))
11801 (define-public python-xopen
11803 (name "python-xopen")
11808 (uri (pypi-uri "xopen" version))
11811 "17xbrgi23l87yg6h0qcknssp2q812miiy33qw6v45v5gx0jwv5xh"))))
11812 (build-system python-build-system)
11814 `(("python-setuptools-scm" ,python-setuptools-scm)))
11815 (home-page "https://github.com/marcelm/xopen/")
11816 (synopsis "Open compressed files transparently")
11817 (description "This module provides an @code{xopen} function that works like
11818 Python's built-in @code{open} function, but can also deal with compressed files.
11819 Supported compression formats are gzip, bzip2 and, xz, and are automatically
11820 recognized by their file extensions. The focus is on being as efficient as
11821 possible on all supported Python versions.")
11822 (license license:expat)))
11824 (define-public python2-xopen
11825 (let ((base (package-with-python2
11826 (strip-python2-variant python-xopen))))
11829 (propagated-inputs `(("python2-bz2file" ,python2-bz2file)
11830 ,@(package-propagated-inputs base))))))
11832 (define-public python-cheetah
11834 (name "python-cheetah")
11839 (uri (pypi-uri "Cheetah3" version))
11842 "1ihag9cxll6b86fc8v5lkhmr3brdbi4yiz16zpgw79yylmv8fgr9"))))
11843 (build-system python-build-system)
11845 `(#:modules ((guix build utils)
11846 (guix build python-build-system)
11850 #:phases (modify-phases %standard-phases
11851 (add-after 'unpack 'use-absolute-python
11853 (substitute* "Cheetah/CheetahWrapper.py"
11854 (("#!/usr/bin/env python")
11855 (string-append "#!" (which "python"))))
11859 (let ((cwd (getcwd)))
11860 (setenv "PYTHONPATH"
11863 (find (cut string-prefix? "lib" <>)
11864 (scandir (string-append cwd "/build")))
11865 ":" (getenv "PYTHONPATH")))
11867 (string-append (getenv "PATH")
11869 (setenv "TMPDIR" "/tmp")
11871 (substitute* "Cheetah/Tests/Test.py"
11872 (("unittest.TextTestRunner\\(\\)")
11873 "unittest.TextTestRunner(verbosity=2)"))
11875 (invoke "python" "Cheetah/Tests/Test.py")))))))
11877 `(("python-markdown" ,python-markdown))) ;optional
11878 (home-page "http://cheetahtemplate.org/")
11879 (synopsis "Template engine")
11880 (description "Cheetah is a text-based template engine and Python code
11883 Cheetah can be used as a standalone templating utility or referenced as
11884 a library from other Python applications. It has many potential uses,
11885 but web developers looking for a viable alternative to ASP, JSP, PHP and
11886 PSP are expected to be its principle user group.
11890 @item Generates HTML, SGML, XML, SQL, Postscript, form email, LaTeX, or any other
11892 @item Cleanly separates content, graphic design, and program code.
11893 @item Blends the power and flexibility of Python with a simple template language
11894 that non-programmers can understand.
11895 @item Gives template writers full access to any Python data structure, module,
11896 function, object, or method in their templates.
11897 @item Makes code reuse easy by providing an object-orientated interface to
11898 templates that is accessible from Python code or other Cheetah templates.
11899 One template can subclass another and selectively reimplement sections of it.
11900 @item Provides a simple, yet powerful, caching mechanism that can dramatically
11901 improve the performance of a dynamic website.
11902 @item Compiles templates into optimized, yet readable, Python code.
11904 (license (license:x11-style "file://LICENSE"))))
11906 (define-public python2-cheetah
11907 (package-with-python2 python-cheetah))
11909 (define-public python-dulwich
11911 (name "python-dulwich")
11916 (uri (list (string-append "https://www.dulwich.io/releases/"
11917 "dulwich-" version ".tar.gz")
11918 (pypi-uri "dulwich" version)))
11921 "1aa1xfrxkc3j9s4xi0llhf5gndyi9ryprcxsqfa5fcb8ph34981q"))))
11922 (build-system python-build-system)
11925 (modify-phases %standard-phases
11926 (add-before 'check 'fix-tests
11927 (lambda* (#:key inputs #:allow-other-keys)
11928 ;; The tests use Popen with a custom environment which doesn't
11930 (substitute* "dulwich/tests/compat/utils.py"
11931 (("'git'") (string-append "'"
11934 (substitute* '("dulwich/tests/test_repository.py"
11935 "dulwich/tests/test_hooks.py")
11936 (("#!/bin/sh") (string-append "#!" (which "sh"))))
11937 (setenv "TEST_RUNNER" "unittest")
11938 (setenv "PYTHONHASHSEED" "random")
11941 `(("python-fastimport" ,python-fastimport)))
11943 `(("python-mock" ,python-mock)
11944 ("python-geventhttpclient" ,python-geventhttpclient)
11946 (home-page "https://www.dulwich.io/")
11947 (synopsis "Git implementation in Python")
11948 (description "Dulwich is an implementation of the Git file formats and
11949 protocols written in pure Python.")
11950 ;; Can be used with either license.
11951 (license (list license:asl2.0 license:gpl2+))))
11953 (define-public python2-dulwich
11954 (package-with-python2 python-dulwich))
11956 (define-public python-pbkdf2
11958 (name "python-pbkdf2")
11963 (uri (pypi-uri "pbkdf2" version))
11966 "0yb99rl2mbsaamj571s1mf6vgniqh23v98k4632150hjkwv9fqxc"))))
11967 (build-system python-build-system)
11970 (modify-phases %standard-phases
11973 (setenv "PYTHONPATH"
11974 (string-append (getcwd) "/build/lib:"
11975 (getenv "PYTHONPATH")))
11976 (invoke "python" "test/test_pbkdf2.py"))))))
11978 `(("python-pycrypto" ,python-pycrypto))) ; optional
11979 (home-page "https://www.dlitz.net/software/python-pbkdf2/")
11980 (synopsis "Password-based key derivation")
11981 (description "This module implements the password-based key derivation
11982 function, PBKDF2, specified in RSA PKCS#5 v2.0.
11984 PKCS#5 v2.0 Password-Based Key Derivation is a key derivation function which
11985 is part of the RSA Public Key Cryptography Standards series. The provided
11986 implementation takes a password or a passphrase and a salt value (and
11987 optionally a iteration count, a digest module, and a MAC module) and provides
11988 a file-like object from which an arbitrarly-sized key can be read.")
11989 (license license:expat)))
11991 (define-public python2-pbkdf2
11992 (package-with-python2 python-pbkdf2))
11994 (define-public python-qrcode
11996 (name "python-qrcode")
12001 (uri (pypi-uri "qrcode" version))
12003 (base32 "0sa3n298b9jpz6zn0birnjii3mg9sihjq28n9nzjlzv09y2m6ljh"))))
12004 (build-system python-build-system)
12006 ;; FIXME: Tests require packaging 'pymaging'.
12009 `(("python-lxml" ,python-lxml) ; for SVG output
12010 ("python-pillow" ,python-pillow) ; for PNG output
12011 ("python-six" ,python-six)))
12012 (home-page "https://github.com/lincolnloop/python-qrcode")
12013 (synopsis "QR Code image generator")
12014 (description "This package provides a pure Python QR Code generator
12015 module. It uses the Python Imaging Library (PIL) to allow for the generation
12018 In addition this package provides a command line tool to generate QR codes and
12019 either write these QR codes to a file or do the output as ascii art at the
12021 (license license:bsd-3)))
12023 (define-public python2-qrcode
12024 (package-with-python2 python-qrcode))
12026 (define-public python-rst2ansi
12028 (name "python-rst2ansi")
12033 (uri (pypi-uri "rst2ansi" version))
12036 "0vzy6gd60l79ff750scl0sz48r1laalkl6md6dwzah4dcadgn5qv"))))
12037 (build-system python-build-system)
12039 `(("python-docutils" ,python-docutils)))
12040 (home-page "https://github.com/Snaipe/python-rst-to-ansi")
12041 (synopsis "Convert RST to ANSI-decorated console output")
12043 "Python module dedicated to rendering RST (reStructuredText) documents
12044 to ansi-escaped strings suitable for display in a terminal.")
12045 (license license:expat)))
12047 (define-public python-ansi2html
12049 (name "python-ansi2html")
12054 (uri (pypi-uri "ansi2html" version))
12057 "1wa00zffprb78w1mqq90dk47czz1knanys2a40zbw2vyapd5lp9y"))))
12058 (build-system python-build-system)
12060 `(("python-mock" ,python-mock)
12061 ("python-nose" ,python-nose)))
12063 `(("python-six" ,python-six)))
12064 (home-page "https://github.com/ralphbean/ansi2html")
12065 (synopsis "Convert ANSI-decorated console output to HTML")
12067 "@command{ansi2html} is a Python library and command line utility for
12068 convering text with ANSI color codes to HTML or LaTeX.")
12069 (license license:gpl3+)))
12071 (define-public python2-ansi2html
12072 (package-with-python2 python-ansi2html))
12074 (define-public python-ddt
12076 (name "python-ddt")
12081 (uri (pypi-uri "ddt" version))
12084 "1lw17420iimhghkgzgax85nn8d1an2d6k2cfvb7j5kwn2dqlr1vk"))))
12085 (build-system python-build-system)
12087 `(("python-mock" ,python-mock)
12088 ("python-nose" ,python-nose)))
12090 `(("python-six" ,python-six)
12091 ("python-pyyaml" ,python-pyyaml)))
12092 (home-page "https://github.com/txels/ddt")
12093 (synopsis "Data-Driven Tests")
12095 "Data-Driven Tests (@dfn{DDT}) allow you to multiply one test case by
12096 running it with different test data, and make it appear as multiple test
12098 (license license:expat)))
12100 (define-public python2-ddt
12101 (package-with-python2 python-ddt))
12103 (define-public python-pycountry
12105 (name "python-pycountry")
12106 (version "18.5.26")
12110 (uri (pypi-uri "pycountry" version))
12113 "15q9j047s3yc9cfcxq1ch8b71f81na44cr6dydd5gxk0ki9a4akz"))))
12114 (build-system python-build-system)
12115 (home-page "https://bitbucket.org/flyingcircus/pycountry")
12116 (synopsis "ISO databases for languages, countries, currencies, etc.")
12118 "@code{pycountry} provides the ISO databases for the standards:
12120 @item 639-3 (Languages)
12121 @item 3166 (Countries)
12122 @item 3166-3 (Deleted Countries)
12123 @item 3166-2 (Subdivisions of countries)
12124 @item 4217 (Currencies)
12125 @item 15924 (Scripts)
12127 It includes a copy from Debian’s pkg-isocodes and makes the data accessible
12128 through a Python API.")
12129 (license license:lgpl2.1+)))
12131 (define-public python2-pycountry
12132 (package-with-python2 python-pycountry))
12134 (define-public python-pycosat
12136 (name "python-pycosat")
12141 (uri (pypi-uri "pycosat" version))
12144 "1kl3wh1f47rc712n4bmwplbx3fqz3x9i1b587jrbpmvdva4c8f6l"))))
12145 ;; TODO: Unundle picosat. http://fmv.jku.at/picosat/
12146 (build-system python-build-system)
12147 (home-page "https://github.com/ContinuumIO/pycosat")
12148 (synopsis "Bindings to picosat (a SAT solver)")
12150 "This package provides efficient Python bindings to @code{picosat} on
12151 the C level. When importing pycosat, the @code{picosat} solver becomes part
12152 of the Python process itself. @code{picosat} is a @dfn{Boolean Satisfiability
12153 Problem} (SAT) solver.")
12154 (license license:expat)))
12156 (define-public python2-pycosat
12157 (package-with-python2 python-pycosat))
12159 (define-public python2-ruamel.ordereddict
12161 (name "python2-ruamel.ordereddict")
12166 (uri (pypi-uri "ruamel.ordereddict" version))
12169 "1xmkl8v9l9inm2pyxgc1fm5005yxm7fkd5gv74q7lj1iy5qc8n3h"))))
12170 (build-system python-build-system)
12172 `(#:python ,python-2
12174 (modify-phases %standard-phases
12176 (add-after 'install 'check
12177 (lambda* (#:key inputs outputs #:allow-other-keys)
12178 (add-installed-pythonpath inputs outputs)
12179 (invoke "python" "test/testordereddict.py"))))))
12180 (home-page "https://bitbucket.org/ruamel/ordereddict")
12181 (synopsis "Version of dict that keeps keys in insertion order")
12183 "This is an implementation of an ordered dictionary with @dfn{Key
12184 Insertion Order} (KIO: updates of values do not affect the position of the
12185 key), @dfn{Key Value Insertion Order} (KVIO, an existing key's position is
12186 removed and put at the back). The standard library module @code{OrderedDict},
12187 implemented later, implements a subset of @code{ordereddict} functionality.
12188 Sorted dictionaries are also provided. Currently only with @dfn{Key Sorted
12189 Order} (KSO, no sorting function can be specified, but a transform can be
12190 specified to apply on the key before comparison (e.g. @code{string.lower})).")
12191 (license license:expat)))
12193 (define-public python-pypeg2
12195 (name "python-pypeg2")
12200 (uri (pypi-uri "pyPEG2" version))
12203 "0v8ziaam2r637v94ra4dbjw6jzxz99gs5x4i585kgag1v204yb9b"))))
12204 (build-system python-build-system)
12205 (propagated-inputs `(("python-lxml" ,python-lxml)))
12207 ;;https://bitbucket.org/fdik/pypeg/issues/36/test-failures-on-py35
12209 (home-page "https://fdik.org/pyPEG/")
12210 (synopsis "Parsering Expression Grammars in Python")
12211 (description "PyPEG is an intrinsic parser interpreter framework for
12212 Python. It is based on Parsing Expression Grammars, PEG. With pyPEG you can
12213 parse many formal languages.")
12214 (license license:gpl2)))
12216 (define-public python-incremental
12218 (name "python-incremental")
12223 (uri (pypi-uri "incremental" version))
12226 "1cylxdz1cnkm5g3pklna3h2n0i0rks95ir1pnpxfnvpkmab1cxbv"))))
12227 (build-system python-build-system)
12228 (home-page "https://github.com/hawkowl/incremental")
12229 (synopsis "Library for versioning Python projects")
12230 (description "Incremental is a small library that versions your Python
12232 (license license:expat)))
12234 (define-public python2-incremental
12235 (package-with-python2 python-incremental))
12237 (define-public python-invoke
12239 (name "python-invoke")
12240 (home-page "http://www.pyinvoke.org/")
12244 (uri (pypi-uri "invoke" version))
12247 "1nn7gad0rvy492acpyhkrp01zsk86acf34qhsvq4xmm6x39788n5"))))
12248 (build-system python-build-system)
12250 ;; XXX: Requires many dependencies that are not yet in Guix.
12252 (synopsis "Pythonic task execution")
12254 "Invoke is a Python task execution tool and library, drawing inspiration
12255 from various sources to arrive at a powerful and clean feature set. It is
12256 evolved from the Fabric project, but focuses on local and abstract concerns
12257 instead of servers and network commands.")
12258 (license license:bsd-3)))
12260 (define-public python2-invoke
12261 (package-with-python2 python-invoke))
12263 (define-public python-automat
12265 (name "python-automat")
12269 (uri (pypi-uri "Automat" version))
12272 "03ivg70n3b1cbcd2zvjhk8y4kmqxcvhmili39lmgx09dza1qpmyb"))))
12273 (build-system python-build-system)
12274 ;; We disable the tests because they require python-twisted, while
12275 ;; python-twisted depends on python-automat. Twisted is optional, but the
12276 ;; tests fail if it is not available. Also see
12277 ;; <https://github.com/glyph/automat/issues/71>.
12278 (arguments '(#:tests? #f))
12280 `(("python-m2r" ,python-m2r)
12281 ("python-setuptools-scm" ,python-setuptools-scm)
12282 ("python-graphviz" ,python-graphviz)))
12284 `(("python-six" ,python-six)
12285 ("python-attrs" ,python-attrs)))
12286 (home-page "https://github.com/glyph/Automat")
12287 (synopsis "Self-service finite-state machines")
12288 (description "Automat is a library for concise, idiomatic Python
12289 expression of finite-state automata (particularly deterministic finite-state
12291 (license license:expat)))
12293 (define-public python2-automat
12294 (package-with-python2 python-automat))
12296 (define-public python-m2r
12298 (name "python-m2r")
12302 (uri (pypi-uri "m2r" version))
12305 "16gdm8i06jjmlpvckpfmlkr4693dh0vs192vgsqn84fsdkbbm45z"))))
12306 (build-system python-build-system)
12308 `(("python-docutils" ,python-docutils)
12309 ("python-mistune" ,python-mistune)))
12311 `(("python-pygments" ,python-pygments)
12312 ("python-mock" ,python-mock)))
12313 (home-page "https://github.com/miyakogi/m2r")
12314 (synopsis "Markdown to reStructuredText converter")
12315 (description "M2R converts a markdown file including reST markups to valid
12317 (license license:expat)))
12319 (define-public python2-m2r
12320 (package-with-python2 python-m2r))
12322 (define-public python-constantly
12324 (name "python-constantly")
12328 (uri (pypi-uri "constantly" version))
12331 "0dgwdla5kfpqz83hfril716inm41hgn9skxskvi77605jbmp4qsq"))))
12332 (build-system python-build-system)
12333 (home-page "https://github.com/twisted/constantly")
12334 (synopsis "Symbolic constants in Python")
12335 (description "Constantly is a Python library that provides symbolic
12336 constant support. It includes collections and constants with text, numeric,
12337 and bit flag values.")
12338 (license license:expat)))
12340 (define-public python2-constantly
12341 (package-with-python2 python-constantly))
12343 (define-public python-attrs
12345 (name "python-attrs")
12349 (uri (pypi-uri "attrs" version))
12352 "16g33zr5f449lqc5wgvzpknxryfzrfsxcr6kpgxwn7l5fkv71f7h"))))
12353 (build-system python-build-system)
12355 `(#:modules ((guix build utils)
12356 (guix build python-build-system)
12360 #:phases (modify-phases %standard-phases
12363 (let ((cwd (getcwd)))
12364 (setenv "PYTHONPATH"
12367 (find (cut string-prefix? "lib" <>)
12368 (scandir (string-append cwd "/build")))
12370 (getenv "PYTHONPATH")))
12371 (invoke "python" "-m" "pytest")))))))
12373 `(("python-coverage" ,python-coverage)
12374 ("python-hypothesis" ,python-hypothesis)
12375 ("python-pympler" ,python-pympler)
12376 ("python-pytest" ,python-pytest)
12377 ("python-six" ,python-six)
12378 ("python-sphinx" ,python-sphinx)
12379 ("python-zope-interface" ,python-zope-interface)))
12380 (home-page "https://github.com/python-attrs/attrs/")
12381 (synopsis "Attributes without boilerplate")
12382 (description "@code{attrs} is a Python package with class decorators that
12383 ease the chores of implementing the most common attribute-related object
12385 (license license:expat)))
12387 (define-public python2-attrs
12388 (package-with-python2 python-attrs))
12390 (define-public python-attrs-bootstrap
12392 (inherit python-attrs)
12393 (name "python-attrs-bootstrap")
12394 (native-inputs `())
12395 (arguments `(#:tests? #f))))
12397 (define-public python2-attrs-bootstrap
12398 (package-with-python2 python-attrs-bootstrap))
12400 (define-public python2-cliapp
12402 (name "python2-cliapp")
12403 (version "1.20180812.1")
12407 (uri (string-append
12408 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/cliapp/snapshot/cliapp-"
12409 version ".tar.gz"))
12412 "1c1jlblbns8qhiaqjpg4xi6lip8xwfc5w643p43rg543havaj45x"))))
12413 (build-system python-build-system)
12415 `(#:python ,python-2
12417 (modify-phases %standard-phases
12418 ;; check phase needs to be run before the build phase. If not,
12419 ;; coverage-test-runner looks for tests for the built source files,
12422 (add-before 'build 'check
12424 ;; Disable python3 tests
12425 (substitute* "check"
12426 (("python3") "# python3"))
12427 (invoke "./check"))))))
12429 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)
12430 ("python2-pep8" ,python2-pep8)))
12432 `(("python2-pyaml" ,python2-pyaml)))
12433 (home-page "https://liw.fi/cliapp/")
12434 (synopsis "Python framework for command line programs")
12435 (description "@code{python2-cliapp} is a python framework for
12436 command line programs. It contains the typical stuff such programs
12437 need to do, such as parsing the command line for options, and
12438 iterating over input files.")
12439 (license license:gpl2+)))
12441 (define-public python2-ttystatus
12443 (name "python2-ttystatus")
12448 (uri (string-append
12449 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/ttystatus/snapshot/ttystatus-"
12450 version ".tar.gz"))
12453 "06mdk4d19zw2j3is54gndhzl396g3xc8k52m7i86z69s9hcz71by"))))
12454 (build-system python-build-system)
12456 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)
12457 ("python2-pep8" ,python2-pep8)))
12459 `(#:python ,python-2
12461 (modify-phases %standard-phases
12462 ;; check phase needs to be run before the build phase. If not,
12463 ;; coverage-test-runner looks for tests for the built source files,
12466 (add-before 'build 'check
12467 (lambda _ (invoke "make" "check"))))))
12468 (home-page "https://liw.fi/ttystatus/")
12469 (synopsis "Python library for showing progress reporting and
12470 status updates on terminals")
12471 (description "@code{python2-ttystatus} is a python library for
12472 showing progress reporting and status updates on terminals, for
12473 command line programs. Output is automatically adapted to the width
12474 of the terminal: truncated if it does not fit, and resized if the
12475 terminal size changes.")
12476 (license license:gpl3+)))
12478 (define-public python2-tracing
12480 (name "python2-tracing")
12485 (uri (string-append
12486 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/python-tracing/snapshot/tracing-"
12487 version ".tar.gz"))
12490 "06cw4zg42fsvqy372vi2whj26w56vzg5axhzwdjc2bgwf03garbw"))))
12491 (build-system python-build-system)
12493 `(#:python ,python-2))
12494 (home-page "https://liw.fi/tracing/")
12495 (synopsis "Python debug logging helper")
12496 (description "@code{python2-tracing} is a python library for
12497 logging debug messages. It provides a way to turn debugging messages
12498 on and off, based on the filename they occur in. It is much faster
12499 than using @code{logging.Filter} to accomplish the same thing, which
12500 matters when code is run in production mode. The actual logging still
12501 happens using the @code{logging} library.")
12502 (license license:gpl3+)))
12504 (define-public python2-larch
12506 (name "python2-larch")
12507 (version "1.20151025")
12511 (uri (string-append
12512 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/larch/snapshot/larch-"
12513 version ".tar.gz"))
12514 (patches (search-patches
12515 "python2-larch-coverage-4.0a6-compatibility.patch"))
12518 "1p4knkkavlqymgciz2wbcnfrdgdbafhg14maplnk4vbw0q8xs663"))))
12519 (build-system python-build-system)
12521 `(#:python ,python-2
12523 (modify-phases %standard-phases
12524 ;; check phase needs to be run before the build phase. If not,
12525 ;; coverage-test-runner looks for tests for the built source files,
12528 (add-before 'build 'check
12529 (lambda _ (invoke "make" "check"))))))
12531 `(("cmdtest" ,cmdtest)
12532 ("python2-coverage-test-runner" ,python2-coverage-test-runner)))
12534 `(("python2-tracing" ,python2-tracing)))
12535 (home-page "https://liw.fi/larch/")
12536 (synopsis "Python copy-on-write B-tree library")
12537 (description "@code{python2-larch} is an implementation of
12538 particular kind of B-tree, based on research by Ohad Rodeh. See
12539 @url{http://liw.fi/larch/ohad-btrees-shadowing-clones.pdf} for details
12540 on the data structure.
12542 The distinctive feature of this B-tree is that a node is never
12543 (conceptually) modified. Instead, all updates are done by
12544 copy-on-write. This makes it easy to clone a tree, and modify only the
12545 clone, while other processes access the original tree.")
12546 (license license:gpl3+)))
12548 (define-public python-astroid
12550 (name "python-astroid")
12555 (uri (pypi-uri "astroid" version))
12557 (base32 "0fnibsl2cb5mvzbfm7sycj85smx48f8w8m7ks1sqlmpr9ps0gski"))))
12558 (build-system python-build-system)
12560 `(("python-lazy-object-proxy" ,python-lazy-object-proxy)
12561 ("python-six" ,python-six)
12562 ("python-typed-ast" ,python-typed-ast)
12563 ("python-wrapt" ,python-wrapt)))
12565 `(("python-dateutil" ,python-dateutil)
12566 ("python-nose" ,python-nose)
12567 ("python-pytest" ,python-pytest)
12568 ("python-pytest-runner" ,python-pytest-runner)))
12571 (modify-phases %standard-phases
12572 (add-after 'unpack 'remove-spurious-test
12574 ;; This can be removed after upgrading from python-3.7
12575 ;; https://github.com/PyCQA/astroid/issues/593
12576 ;; https://bugs.python.org/issue34056
12577 (delete-file "astroid/tests/unittest_modutils.py")
12581 (invoke "pytest" "astroid"))))))
12582 (home-page "https://github.com/PyCQA/astroid")
12583 (synopsis "Common base representation of python source code for pylint and
12585 (description "@code{python-astroid} provides a common base representation
12586 of python source code for projects such as pychecker, pyreverse, pylint, etc.
12588 It provides a compatible representation which comes from the _ast module. It
12589 rebuilds the tree generated by the builtin _ast module by recursively walking
12590 down the AST and building an extended ast. The new node classes have
12591 additional methods and attributes for different usages. They include some
12592 support for static inference and local name scopes. Furthermore, astroid
12593 builds partial trees by inspecting living objects.")
12594 (license license:lgpl2.1+)
12595 (properties `((python2-variant . ,(delay python2-astroid))))))
12597 (define-public python2-astroid
12598 (let ((base (package-with-python2
12599 (strip-python2-variant python-astroid))))
12600 (package (inherit base)
12601 ;; Version 2.x removes python2 support.
12606 (uri (pypi-uri "astroid" version))
12609 "0fir4b67sm7shcacah9n61pvq313m523jb4q80sycrh3p8nmi6zw"))))
12611 (substitute-keyword-arguments (package-arguments base)
12613 `(modify-phases ,phases
12614 (add-after 'unpack 'remove-spurious-test
12616 ;; https://github.com/PyCQA/astroid/issues/276
12617 (delete-file "astroid/tests/unittest_brain.py")
12621 (invoke"python" "-m" "unittest" "discover"
12622 "-p" "unittest*.py")))))))
12623 (native-inputs `())
12625 `(("python2-backports-functools-lru-cache"
12626 ,python2-backports-functools-lru-cache)
12627 ("python2-enum34" ,python2-enum34)
12628 ("python2-singledispatch" ,python2-singledispatch)
12629 ,@(alist-delete "python-typed-ast"
12630 (package-propagated-inputs base)))))))
12632 (define-public python-isort
12634 (name "python-isort")
12639 (uri (git-reference
12640 ;; Tests pass only from the Github sources
12641 (url "https://github.com/timothycrosley/isort")
12643 (file-name (git-file-name name version))
12646 "1q0mlrpki5vjbgwxag5rghljjcfg7mvb0pbkwid80p0sqrxlm2p6"))))
12647 (build-system python-build-system)
12649 `(("python-mock" ,python-mock)
12650 ("python-pytest" ,python-pytest)))
12651 (home-page "https://github.com/timothycrosley/isort")
12652 (synopsis "Python utility/library to sort python imports")
12653 (description "@code{python-isort} is a python utility/library to sort
12654 imports alphabetically, and automatically separated into sections. It
12655 provides a command line utility, a python library and plugins for various
12657 (license license:expat)
12658 (properties `((python2-variant . ,(delay python2-isort))))))
12660 (define-public python2-isort
12661 (let ((base (package-with-python2
12662 (strip-python2-variant python-isort))))
12663 (package (inherit base)
12665 `(("python2-futures" ,python2-futures)
12666 ,@(package-native-inputs base))))))
12668 (define-public python2-backports-functools-lru-cache
12670 (name "python2-backports-functools-lru-cache")
12675 ;; only the pypi tarballs contain the necessary metadata
12676 (uri (pypi-uri "backports.functools_lru_cache" version))
12679 "06jgv8gib4fhky0p5cmxdghvsgjyzcdgk48k8pxb1ccf11znk64x"))))
12680 (build-system python-build-system)
12682 `(("python2-setuptools-scm" ,python2-setuptools-scm)))
12684 `(#:python ,python-2))
12685 (home-page "https://github.com/jaraco/backports.functools_lru_cache")
12686 (synopsis "Backport of functools.lru_cache from Python 3.3")
12687 (description "@code{python2-backports-functools-lru-cache} is a backport
12688 of @code{functools.lru_cache} from python 3.3.")
12689 (license license:expat)))
12691 (define-public python-configparser
12693 (name "python-configparser")
12698 (uri (pypi-uri "configparser" version))
12701 "0cnz213il9lhgda6x70fw7mfqr8da43s3wm343lwzhqx94mgmmav"))))
12702 (build-system python-build-system)
12703 (home-page "https://github.com/jaraco/configparser/")
12704 (synopsis "Backport of configparser from python 3.5")
12705 (description "@code{python-configparser} is a backport of
12706 @code{configparser} from Python 3.5 so that it can be used directly
12707 in other versions.")
12708 (license license:expat)))
12710 (define-public python2-configparser
12711 (package-with-python2 python-configparser))
12713 (define-public python-mando
12715 (name "python-mando")
12719 (uri (pypi-uri "mando" version))
12722 "0q6rl085q1hw1wic52pqfndr0x3nirbxnhqj9akdm5zhq2fv3zkr"))))
12723 (build-system python-build-system)
12725 `(("python-rst2ansi" ,python-rst2ansi)
12726 ("python-six" ,python-six)))
12728 `(("python-pytest" ,python-pytest)))
12729 (home-page "https://mando.readthedocs.org/")
12731 "Wrapper around argparse, allowing creation of complete CLI applications")
12733 "This package is a wrapper around argparse, allowing you to write complete CLI
12734 applications in seconds while maintaining all the flexibility.")
12735 (license license:expat)))
12737 (define-public python2-mando
12738 (package-with-python2 python-mando))
12740 (define-public python2-argparse
12742 (name "python2-argparse")
12747 (uri (pypi-uri "argparse" version))
12750 "1r6nznp64j68ih1k537wms7h57nvppq0szmwsaf99n71bfjqkc32"))))
12751 (build-system python-build-system)
12753 `(#:python ,python-2))
12754 (home-page "https://github.com/ThomasWaldmann/argparse/")
12755 (synopsis "Python command-line parsing library")
12757 "This package is mostly for people who want to have @code{argparse} on
12758 older Pythons because it was not part of the standard library back then.")
12759 (license license:psfl)))
12761 (define-public python-fudge
12763 (name "python-fudge")
12764 ;; 0.9.6 is the latest version suitable for testing the "fabric" Python 2
12765 ;; package, which is currently the only use of this package.
12770 (uri (pypi-uri "fudge" version))
12773 "185ia3vr3qk4f2s1a9hdxb8ci4qc0x0xidrad96pywg8j930qs9l"))))
12774 (build-system python-build-system)
12776 `(#:tests? #f)) ;XXX: Tests require the NoseJS Python package.
12777 (home-page "https://github.com/fudge-py/fudge")
12778 (synopsis "Replace real objects with fakes/mocks/stubs while testing")
12780 "Fudge is a Python module for using fake objects (mocks and stubs) to
12783 In readable Python code, you declare the methods available on your fake object
12784 and how they should be called. Then you inject that into your application and
12785 start testing. This declarative approach means you don’t have to record and
12786 playback actions and you don’t have to inspect your fakes after running code.
12787 If the fake object was used incorrectly then you’ll see an informative
12788 exception message with a traceback that points to the culprit.")
12789 (license license:expat)))
12791 (define-public python2-fudge
12792 (package-with-python2 python-fudge))
12794 (define-public python-mwclient
12796 (name "python-mwclient")
12801 ;; The PyPI version wouldn't contain tests.
12802 (uri (git-reference
12803 (url "https://github.com/mwclient/mwclient")
12804 (commit (string-append "v" version))))
12805 (file-name (git-file-name name version))
12808 "1c3q6lwmb05yqywc4ya98ca7hsl15niili8rccl4n1yqp77c103v"))))
12809 (build-system python-build-system)
12811 `(("python-requests-oauthlib" ,python-requests-oauthlib)
12812 ("python-six" ,python-six)))
12814 `(("python-mock" ,python-mock)
12815 ("python-pytest" ,python-pytest)
12816 ("python-pytest-cov" ,python-pytest-cov)
12817 ("python-pytest-runner" ,python-pytest-runner)
12818 ("python-responses" ,python-responses)))
12819 (home-page "https://github.com/btongminh/mwclient")
12820 (synopsis "MediaWiki API client")
12821 (description "This package provides a MediaWiki API client.")
12822 (license license:expat)))
12824 (define-public python2-mwclient
12825 (package-with-python2 python-mwclient))
12827 (define-public python-utils
12829 (name "python-utils")
12833 (uri (pypi-uri "python-utils" version))
12836 "1mcsy6q5am4ya72rgkpb6kax6vv7c93cfkkas89xnpa4sj9zf28p"))))
12837 (build-system python-build-system)
12839 `(("pytest-runner" ,python-pytest-runner)
12840 ("pytest" ,python-pytest)
12841 ("six" ,python-six)))
12842 (home-page "https://github.com/WoLpH/python-utils")
12843 (synopsis "Convenient utilities not included with the standard Python install")
12845 "Python Utils is a collection of small Python functions and classes which
12846 make common patterns shorter and easier.")
12847 (license license:bsd-2)))
12849 (define-public python2-utils
12850 (package-with-python2 python-utils))
12852 (define-public python-diff-match-patch
12854 (name "python-diff-match-patch")
12855 (version "20121119")
12859 (uri (pypi-uri "diff-match-patch" version))
12862 "0k1f3v8nbidcmmrk65m7h8v41jqi37653za9fcs96y7jzc8mdflx"))))
12863 (build-system python-build-system)
12864 (home-page "https://code.google.com/p/google-diff-match-patch")
12865 (synopsis "Synchronize plain text")
12866 (description "Diff Match and Patch libraries offer robust algorithms to
12867 perform the operations required for synchronizing plain text.")
12868 (license license:asl2.0)))
12870 (define-public python2-diff-match-patch
12871 (package-with-python2 python-diff-match-patch))
12873 (define-public python-dirsync
12875 (name "python-dirsync")
12880 (uri (pypi-uri "dirsync" version))
12883 "1r40fkanksagcszf1ag85mdr8w7rgc7196n6s1qlsk2abw6i7v0z"))))
12884 (build-system python-build-system)
12886 `(("six" ,python-six)))
12887 (home-page "https://bitbucket.org/tkhyn/dirsync")
12888 (synopsis "Advanced directory tree synchronisation tool")
12889 (description "Advanced directory tree synchronisation tool.")
12890 (license license:expat)))
12892 (define-public python2-dirsync
12893 (package-with-python2 python-dirsync))
12895 (define-public python-levenshtein
12897 (name "python-levenshtein")
12902 (uri (pypi-uri "python-Levenshtein" version))
12905 "1c9ybqcja31nghfcc8xxbbz9h60s9qi12b9hr4jyl69xbvg12fh3"))))
12906 (build-system python-build-system)
12907 (home-page "https://github.com/ztane/python-Levenshtein")
12908 (synopsis "Fast computation of Levenshtein distance and string similarity")
12910 "The Levenshtein Python C extension module contains functions for fast computation of
12912 @item Levenshtein (edit) distance, and edit operations
12913 @item string similarity
12914 @item approximate median strings, and generally string averaging
12915 @item string sequence and set similarity
12917 It supports both normal and Unicode strings.")
12918 (license license:gpl2+)))
12920 (define-public python2-levenshtein
12921 (package-with-python2 python-levenshtein))
12923 (define-public python-scandir
12925 (name "python-scandir")
12930 (uri (pypi-uri "scandir" version))
12932 (base32 "0r3hvf1a9jm1rkqgx40gxkmccknkaiqjavs8lccgq9s8khh5x5s4"))))
12933 (build-system python-build-system)
12935 `(#:phases (modify-phases %standard-phases
12938 (invoke "python" "test/run_tests.py"))))))
12939 (home-page "https://github.com/benhoyt/scandir")
12940 (synopsis "Directory iteration function")
12942 "Directory iteration function like os.listdir(), except that instead of
12943 returning a list of bare filenames, it yields DirEntry objects that include
12944 file type and stat information along with the name. Using scandir() increases
12945 the speed of os.walk() by 2-20 times (depending on the platform and file
12946 system) by avoiding unnecessary calls to os.stat() in most cases.
12948 This package is part of the Python standard library since version 3.5.")
12949 (license license:bsd-3)))
12951 (define-public python2-scandir
12952 (package-with-python2 python-scandir))
12954 (define-public python2-stemming
12956 (name "python2-stemming")
12961 (uri (pypi-uri "stemming" version))
12963 (base32 "0ldwa24gnnxhniv0fhygkpc2mwgd93q10ag8rvzayv6hw418frsr"))))
12964 (build-system python-build-system)
12966 `(#:python ,python-2))
12967 (home-page "https://bitbucket.org/mchaput/stemming/overview")
12968 (synopsis "Python implementations of various stemming algorithms")
12970 "Python implementations of the Porter, Porter2, Paice-Husk, and Lovins
12971 stemming algorithms for English. These implementations are straightforward and
12972 efficient, unlike some Python versions of the same algorithms available on the
12973 Web. This package is an extraction of the stemming code included in the Whoosh
12975 (license license:public-domain)))
12977 (define-public python-factory-boy
12979 (name "python-factory-boy")
12984 (uri (pypi-uri "factory_boy" version))
12986 (base32 "1fvin6san5xsjh2c4y18caj2lnmwxlylyqm8mh1yc6rp38wlwr56"))))
12987 (build-system python-build-system)
12989 ;; Tests are not included in the tarball.
12992 `(("faker" ,python-faker)))
12993 (home-page "https://github.com/benhoyt/scandir")
12994 (synopsis "Versatile test fixtures replacement")
12996 "Factory_boy is a fixtures replacement based on thoughtbot’s factory_girl.
12998 As a fixtures replacement tool, it aims to replace static, hard to maintain
12999 fixtures with easy-to-use factories for complex object.
13001 Instead of building an exhaustive test setup with every possible combination
13002 of corner cases, factory_boy allows you to use objects customized for the
13003 current test, while only declaring the test-specific fields")
13004 (license license:expat)))
13006 (define-public python2-factory-boy
13007 (package-with-python2 python-factory-boy))
13009 (define-public python-translate-toolkit
13011 (name "python-translate-toolkit")
13016 (uri (pypi-uri "translate-toolkit" version ".tar.bz2"))
13018 (base32 "1vlkwrg83vb17jc36pmwh2b7jphwf390lz0jw8hakcg16qhwypvq"))))
13019 (build-system python-build-system)
13021 `(("python-pytest" ,python-pytest)
13022 ("python-sphinx" ,python-sphinx)))
13024 `(("python-babel" ,python-babel)
13025 ("python-beautifulsoup4" ,python-beautifulsoup4)
13026 ("python-chardet" ,python-chardet)
13027 ("python-diff-match-patch" ,python-diff-match-patch)
13028 ("python-levenshtein" ,python-levenshtein)
13029 ("python-lxml" ,python-lxml)
13030 ("python-six" ,python-six)
13031 ("python-vobject" ,python-vobject)
13032 ("python-pyyaml" ,python-pyyaml)))
13034 ;; TODO: tests are not run, because they end with
13035 ;; TypeError: parse() missing 2 required positional arguments: 'tree' and
13037 ;; during test setup.
13039 (home-page "https://toolkit.translatehouse.org")
13040 (synopsis "Tools and API for translation and localization engineering")
13042 "Tools and API for translation and localization engineering. It contains
13043 several utilities, as well as an API for building localization tools.")
13044 (license license:gpl2+)))
13046 (define-public python2-translate-toolkit
13047 (package-with-python2 python-translate-toolkit))
13049 (define-public python-packaging
13051 (name "python-packaging")
13056 (uri (pypi-uri "packaging" version))
13059 "1y2ip3a4ykkpgnwgn85j6hkspcl0cg3mzms97f40mk57vwqq67gy"))))
13060 (build-system python-build-system)
13062 `(#:phases (modify-phases %standard-phases
13064 (lambda _ (invoke "py.test" "-vv"))))))
13066 `(("python-pretend" ,python-pretend)
13067 ("python-pytest" ,python-pytest)))
13069 `(("python-pyparsing" ,python-pyparsing)
13070 ("python-six" ,python-six)))
13071 (home-page "https://github.com/pypa/packaging")
13072 (synopsis "Core utilities for Python packages")
13073 (description "Packaging is a Python module for dealing with Python packages.
13074 It offers an interface for working with package versions, names, and dependency
13076 ;; From 'LICENSE': This software is made available under the terms of
13077 ;; *either* of the licenses found in LICENSE.APACHE or LICENSE.BSD.
13078 ;; Contributions to this software is made under the terms of *both* these
13080 (license (list license:asl2.0 license:bsd-2))))
13082 (define-public python2-packaging
13083 (package-with-python2 python-packaging))
13085 (define-public python-relatorio
13087 (name "python-relatorio")
13092 (uri (pypi-uri "relatorio" version))
13095 "1na6hlhz1awi1hbjg1gyclq0khz42iz90wvdjw7mmj655788bpxx"))))
13096 (build-system python-build-system)
13098 `(("python-lxml" ,python-lxml)
13099 ("python-genshi" ,python-genshi)))
13101 `(("python-magic" ,python-magic)))
13102 (home-page "https://relatorio.tryton.org/")
13103 (synopsis "Templating library able to output ODT and PDF files")
13104 (description "Relatorio is a templating library which provides a way to
13105 easily output ODT, ODS, PNG, SVG and several other kinds of files. Support
13106 for more filetypes can be easily added by creating plugins for them.")
13107 (license license:gpl3+)))
13109 (define-public python2-relatorio
13110 (package-with-python2 python-relatorio))
13112 (define-public python-radon
13114 (name "python-radon")
13119 (uri (pypi-uri "radon" version))
13122 "07gq5hq4nrffxnlnksws9hrx7fd001gam63j62i82gyfr23gvdym"))))
13123 (build-system python-build-system)
13125 `(#:phases (modify-phases %standard-phases
13128 (invoke "python" "radon/tests/run.py"))))))
13130 `(("python-colorama" ,python-colorama)
13131 ("python-flake8-polyfill" ,python-flake8-polyfill)
13132 ("python-mando" ,python-mando)))
13134 `(("python-pytest" ,python-pytest)
13135 ("python-pytest-mock" ,python-pytest-mock)))
13136 (home-page "https://radon.readthedocs.org/")
13137 (synopsis "Code Metrics in Python")
13138 (description "Radon is a Python tool which computes various code metrics.
13139 Supported metrics are:
13141 @item raw metrics: SLOC, comment lines, blank lines, &c.
13142 @item Cyclomatic Complexity (i.e. McCabe’s Complexity)
13143 @item Halstead metrics (all of them)
13144 @item the Maintainability Index (a Visual Studio metric)
13146 (license license:expat)))
13148 (define-public python2-radon
13149 (package-with-python2 python-radon))
13151 (define-public python-sure
13153 (name "python-sure")
13158 (uri (pypi-uri "sure" version))
13161 "1and0drq8w9iplsic22n2h7hkpyq03a1mbqk4sgcdqhqzdqm539w"))))
13162 (build-system python-build-system)
13164 `(("python-mock" ,python-mock)
13165 ("python-six" ,python-six)))
13167 `(("python-nose" ,python-nose)))
13168 (home-page "https://github.com/gabrielfalcao/sure")
13169 (synopsis "Automated testing library in python for python")
13171 "Sure is a python library that leverages a DSL for writing assertions.
13172 Sure is heavily inspired by @code{RSpec Expectations} and @code{should.js}.")
13173 (license license:gpl3+)))
13175 (define-public python2-sure
13176 (package-with-python2 python-sure))
13178 (define-public python2-couleur
13179 ;; This package does not seem to support python3 at all, hence,
13180 ;; only the python2 variant definition is provided.
13182 (name "python2-couleur")
13187 (uri (pypi-uri "couleur" version))
13190 "1qqaxyqz74wvid0cr119dhcwz0h0if5b5by44zl49pd5z65v58k1"))))
13191 (build-system python-build-system)
13193 `(#:python ,python-2))
13194 (home-page "https://github.com/gabrielfalcao/couleur")
13196 "ANSI terminal tool for python, colored shell and other handy fancy features")
13198 "@code{Couleur} provides python programs a way to use the ANSI features in a unix
13199 terminal such as coloured output in the shell, overwriting output, indentation, etc.")
13200 ;; README.md says ASL2.0, but all source code headers are LGPL3+.
13201 ;; https://github.com/gabrielfalcao/couleur/issues/11
13202 (license license:lgpl3+)))
13204 (define-public python-misaka
13206 (name "python-misaka")
13211 (uri (pypi-uri "misaka" version))
13214 "1mzc29wwyhyardclj1vg2xsfdibg2lzb7f1azjcxi580ama55wv2"))))
13215 (build-system python-build-system)
13217 `(;; Line 37 of setup.py calls self.run_command('develop')
13218 ;; in the 'check' phase. This command seems to be trying
13220 ;; /gnu/store/...-python-<version>/lib/python<version>/site-packages/
13221 ;; for which it does not have the permission to write.
13224 `(("python-cffi" ,python-cffi)))
13225 (home-page "https://github.com/FSX/misaka")
13226 (synopsis "Python binding for Hoedown")
13228 "@code{Misaka} is a CFFI-based binding for @code{Hoedown}, a fast markdown processing
13229 library written in C. It features a fast HTML renderer and functionality to make custom
13230 renderers (e.g. man pages or LaTeX).")
13231 (license license:expat)))
13233 (define-public python2-misaka
13234 (package-with-python2 python-misaka))
13236 (define-public python2-steadymark
13237 ;; This is forced into being a python2 only variant
13238 ;; due to its dependence on couleur that has no support
13241 (name "python2-steadymark")
13246 (uri (pypi-uri "steadymark" version))
13249 "1640i9g8dycql3cc8j0bky0jkzj0q39blfbp4lsgpkprkfgcdk8v"))))
13250 (build-system python-build-system)
13252 `(("python-couleur" ,python2-couleur)
13253 ("python-sure" ,python2-sure)
13254 ("python-misaka" ,python2-misaka)))
13256 `(#:python ,python-2
13258 (modify-phases %standard-phases
13259 (add-before 'build 'patch-setup-py
13261 ;; Update requirements from dependency==version
13262 ;; to dependency>=version
13263 (substitute* "setup.py"
13266 (home-page "https://github.com/gabrielfalcao/steadymark")
13267 (synopsis "Markdown-based test runner for python")
13269 "@code{Steadymark} allows documentation to be written in github-flavoured
13270 markdown. The documentation may contain snippets of code surrounded by python
13271 code blocks and @code{Steadymark} will find these snippets and run them, making
13272 sure that there are no old malfunctional examples in the documentation examples.")
13273 (license license:expat)))
13275 (define-public python-jsonpointer
13277 (name "python-jsonpointer")
13282 (uri (pypi-uri "jsonpointer" version))
13285 "1cg0gvgqjysydv6p45v4jywg1jb3v48c7m3cbpi57zgf6nndr9cz"))))
13286 (build-system python-build-system)
13287 (home-page "https://github.com/stefankoegl/python-json-pointer")
13288 (synopsis "Identify specific nodes in a JSON document")
13289 (description "@code{jsonpointer} allows you to access specific nodes
13290 by path in a JSON document (see RFC 6901).")
13291 (license license:bsd-3)))
13293 (define-public python2-jsonpointer
13294 (package-with-python2 python-jsonpointer))
13296 (define-public python-jsonpatch
13298 (name "python-jsonpatch")
13303 ;; pypi version lacks tests.js
13304 (uri (git-reference
13305 (url "https://github.com/stefankoegl/python-json-patch")
13306 (commit (string-append "v" version))))
13307 (file-name (git-file-name name version))
13310 "0k9pff06lxama3nhsc7cdxbp83422bdy8ifs52i6xkas8hpyzfzr"))))
13311 (build-system python-build-system)
13313 `(("python-jsonpointer" ,python-jsonpointer)))
13314 (home-page "https://github.com/stefankoegl/python-json-patch")
13315 (synopsis "Applying JSON Patches in Python 2.6+ and 3.x")
13316 (description "@code{jsonpatch} is a library and program that allows
13317 applying JSON Patches according to RFC 6902.")
13318 (license license:bsd-3)))
13320 (define-public python2-jsonpatch
13321 (package-with-python2 python-jsonpatch))
13323 (define-public python-jsonpatch-0.4
13324 (package (inherit python-jsonpatch)
13325 (name "python-jsonpatch")
13330 (uri (git-reference
13331 (url "https://github.com/stefankoegl/python-json-patch")
13332 (commit (string-append "v" version))))
13333 (file-name (git-file-name name version))
13336 "1fq02y57kinyknxjcav0slcb0k9mwdffqw2hnlhdkpj7palh2mwk"))))))
13338 (define-public python2-jsonpatch-0.4
13339 (package-with-python2 python-jsonpatch-0.4))
13341 (define-public python-rfc3986
13343 (name "python-rfc3986")
13347 (uri (pypi-uri "rfc3986" version))
13350 "06wlmysw83f75ff84zr1yr6n0shvc2xn1n1sb4iwzqap9hf5fn44"))))
13351 (build-system python-build-system)
13353 `(#:modules ((guix build utils)
13354 (guix build python-build-system)
13359 (modify-phases %standard-phases
13362 (let ((cwd (getcwd)))
13363 (setenv "PYTHONPATH"
13364 (string-append cwd "/build/"
13365 (find (cut string-prefix? "lib" <>)
13366 (scandir (string-append cwd "/build")))
13368 (getenv "PYTHONPATH")))
13369 (invoke "pytest" "-v")))))))
13371 `(("python-pytest" ,python-pytest)))
13372 (home-page "https://rfc3986.readthedocs.io/")
13373 (synopsis "Parse and validate URI references")
13375 "@code{rfc3986} is a Python implementation of RFC@tie{}3986 including
13376 validation and authority parsing. This module also supports RFC@tie{}6874
13377 which adds support for zone identifiers to IPv6 addresses.")
13378 (license license:asl2.0)))
13380 (define-public python2-rfc3986
13381 (package-with-python2 python-rfc3986))
13383 (define-public python-rfc3987
13385 (name "python-rfc3987")
13390 (uri (pypi-uri "rfc3987" version))
13393 "192pclzs2y0yaywqkrlvd0x73740q310kvqvm6jldhi619mq59wi"))))
13394 (build-system python-build-system)
13395 (home-page "https://pypi.python.org/pypi/rfc3987")
13396 (synopsis "Parsing and validation of URIs (RFC 3986) and IRIs (RFC 3987)")
13397 (description "@code{rfc3987} provides routines for parsing and
13398 validation of URIs (see RFC 3986) and IRIs (see RFC 3987).")
13399 (license license:gpl3+)))
13401 (define-public python2-rfc3987
13402 (package-with-python2 python-rfc3987))
13404 (define-public python-validate-email
13406 (name "python-validate-email")
13411 (uri (pypi-uri "validate_email" version))
13414 "1bxffaf5yz2cph8ki55vdvdypbwkvn2xr1firlcy62vqbzf1jivq"))))
13415 (build-system python-build-system)
13416 (home-page "https://github.com/syrusakbary/validate_email")
13417 (synopsis "Verifies if an email address is valid and really exists")
13418 (description "@code{validate_email} can be used to verify if an email
13419 address is valid and really exists.")
13420 (license license:lgpl3+)))
13422 (define-public python2-validate-email
13423 (package-with-python2 python-validate-email))
13425 (define-public python-flex
13427 (name "python-flex")
13432 (uri (pypi-uri "flex" version))
13435 "00pamnwla3khk8nyla7y28dq9jnh69swd7f4jfsl7sn1izs8n8zk"))))
13436 (build-system python-build-system)
13438 `(("python-click" ,python-click)
13439 ("python-iso8601" ,python-iso8601)
13440 ("python-jsonpointer" ,python-jsonpointer)
13441 ("python-pyyaml" ,python-pyyaml)
13442 ("python-requests" ,python-requests)
13443 ("python-rfc3987" ,python-rfc3987)
13444 ("python-six" ,python-six)
13445 ("python-validate-email" ,python-validate-email)))
13446 (home-page "https://github.com/pipermerriam/flex")
13447 (synopsis "Validates Swagger schemata")
13448 (description "@code{flex} can be used to validate Swagger schemata.")
13449 (license license:bsd-3)))
13451 (define-public python2-flex
13452 (package-with-python2 python-flex))
13454 (define-public python-marshmallow
13456 (name "python-marshmallow")
13457 (version "3.0.0b14")
13461 (uri (pypi-uri "marshmallow" version))
13464 "1digk3f5cfk7wmlka65mc7bzsd96pbsgcsvp6pimd5b4ff9zb5p3"))))
13465 (build-system python-build-system)
13467 `(("python-dateutil" ,python-dateutil)
13468 ("python-simplejson" ,python-simplejson)))
13470 `(("python-pytest" ,python-pytest)
13471 ("python-pytz" ,python-pytz)))
13472 (home-page "https://github.com/marshmallow-code/marshmallow")
13473 (synopsis "Convert complex datatypes to and from native
13474 Python datatypes.")
13475 (description "@code{marshmallow} provides a library for converting
13476 complex datatypes to and from native Python datatypes.")
13477 (license license:expat)))
13479 (define-public python2-marshmallow
13480 (package-with-python2 python-marshmallow))
13482 (define-public python-apispec
13484 (name "python-apispec")
13489 (uri (pypi-uri "apispec" version))
13492 "0kxa8723zbisx10363yh4mmmn4higxrspymbjfz5zq8f644zagm9"))))
13493 (build-system python-build-system)
13495 `(("python-pyyaml" ,python-pyyaml)))
13497 `(("python-pytest" ,python-pytest)
13498 ("python-flask" ,python-flask)
13499 ("python-marshmallow" ,python-marshmallow)
13500 ("python-tornado" ,python-tornado)
13501 ("python-bottle" ,python-bottle)
13502 ("python-mock" ,python-mock)))
13503 (home-page "https://github.com/marshmallow-code/apispec")
13504 (synopsis "Swagger 2.0 API specification generator")
13505 (description "@code{python-apispec} is a pluggable API specification
13506 generator. Currently supports the OpenAPI specification (f.k.a.
13508 (license license:expat)))
13510 (define-public python2-apispec
13511 (package-with-python2 python-apispec))
13513 (define-public python-flasgger
13515 (name "python-flasgger")
13520 (uri (git-reference
13521 (url "https://github.com/rochacbruno/flasgger.git")
13523 (file-name (git-file-name name version))
13525 (base32 "0yydxsyjnc0clbrjqb1n7587l6cdqvwdagwxk5hkx01qwdfbkvpn"))))
13526 (build-system python-build-system)
13529 (modify-phases %standard-phases
13531 (lambda* (#:key inputs outputs #:allow-other-keys)
13532 (substitute* "Makefile"
13533 (("flake8 flasgger --ignore=F403")
13534 "flake8 flasgger --ignore=E731,F403"))
13535 (setenv "PYTHONPATH" (string-append (getcwd)
13537 (getenv "PYTHONPATH")))
13538 (invoke "py.test"))))))
13540 `(("python-flask" ,python-flask)
13541 ("python-pyyaml" ,python-pyyaml)
13542 ("python-jsonschema" ,python-jsonschema)
13543 ("python-mistune" ,python-mistune)
13544 ("python-six" ,python-six)))
13546 `(("python-decorator" ,python-decorator)
13547 ("python-flake8" ,python-flake8)
13548 ("python-flask-restful" ,python-flask-restful)
13549 ("python-flex" ,python-flex)
13550 ("python-pytest" ,python-pytest)
13551 ("python-pytest-cov" ,python-pytest-cov)
13552 ("python-marshmallow" ,python-marshmallow)
13553 ("python-apispec" ,python-apispec)))
13554 (home-page "https://github.com/rochacbruno/flasgger/")
13555 (synopsis "Extract Swagger specs from your Flask project")
13556 (description "@code{python-flasgger} allows extracting Swagger specs
13557 from your Flask project. It is a fork of Flask-Swagger.")
13558 (license license:expat)))
13560 (define-public python2-flasgger
13561 (package-with-python2 python-flasgger))
13563 (define-public python-swagger-spec-validator
13565 (name "python-swagger-spec-validator")
13570 (uri (pypi-uri "swagger-spec-validator" version))
13573 "11g627icrsqwazsncwi0sdvprcj6hwaayw5xk3xsj8d97bmrzqjp"))))
13574 (build-system python-build-system)
13576 `(("python-jsonschema" ,python-jsonschema)
13577 ("python-pyyaml" ,python-pyyaml)
13578 ("python-six" ,python-six)))
13580 "https://github.com/Yelp/swagger_spec_validator")
13581 (synopsis "Validation of Swagger specifications")
13582 (description "@code{swagger_spec_validator} provides a library for
13583 validating Swagger API specifications.")
13584 (license license:asl2.0)))
13586 (define-public python2-swagger-spec-validator
13587 (package-with-python2 python-swagger-spec-validator))
13589 (define-public python-apache-libcloud
13591 (name "python-apache-libcloud")
13596 (uri (pypi-uri "apache-libcloud" version))
13599 "0daj3mkzw79v5zin2r1s2wkrz1hplfc16bwj4ss68i5qjq4l2p0j"))))
13600 (build-system python-build-system)
13603 (modify-phases %standard-phases
13604 (add-after 'unpack 'patch-ssh
13605 (lambda* (#:key inputs #:allow-other-keys)
13606 (substitute* "libcloud/compute/ssh.py"
13607 (("'ssh'") (string-append "'" (assoc-ref inputs "openssh")
13610 (add-after 'unpack 'patch-tests
13612 (substitute* "./libcloud/test/test_file_fixtures.py"
13613 ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-923>.
13614 (("def _ascii") "def _raw_data(self, method, url, body, headers):
13615 return (httplib.OK,
13617 {\"test\": \"value\"},
13618 httplib.responses[httplib.OK])
13620 (substitute* "libcloud/test/compute/test_ssh_client.py"
13621 (("class ShellOutSSHClientTests")
13622 "@unittest.skip(\"Guix container doesn't have ssh service\")
13623 class ShellOutSSHClientTests")
13624 ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-924>.
13625 (("'.xf0.x90.x8d.x88'") "b'\\xF0\\x90\\x8D\\x88'")
13626 (("'.xF0', '.x90', '.x8D', '.x88'")
13627 "b'\\xF0', b'\\x90', b'\\x8D', b'\\x88'"))
13629 (add-before 'check 'copy-secret
13631 (copy-file "libcloud/test/secrets.py-dist"
13632 "libcloud/test/secrets.py")
13635 `(("openssh" ,openssh)))
13637 `(("python-paramiko" ,python-paramiko)
13638 ("python-requests" ,python-requests)))
13640 `(("python-lockfile" ,python-lockfile)
13641 ("python-mock" ,python-mock)
13642 ("python-pytest" ,python-pytest)
13643 ("python-pytest-runner" ,python-pytest-runner)
13644 ("python-requests-mock" ,python-requests-mock)))
13645 (home-page "https://libcloud.apache.org/")
13646 (synopsis "Unified Cloud API")
13647 (description "@code{libcloud} is a Python library for interacting with
13648 many of the popular cloud service providers using a unified API.")
13649 (license license:asl2.0)))
13651 (define-public python2-apache-libcloud
13652 (package-with-python2 python-apache-libcloud))
13654 (define-public python-smmap2
13656 (name "python-smmap2")
13661 (uri (pypi-uri "smmap2" version))
13663 (base32 "16k03pcnxd3lgzwgbd7nl4jwzm1wmahirvd09kljnzvy96hgza99"))))
13664 (build-system python-build-system)
13666 `(("python-nosexcover" ,python-nosexcover)))
13667 (home-page "https://github.com/Byron/smmap")
13668 (synopsis "Python sliding window memory map manager")
13669 (description "@code{smmap2} is a pure Python implementation of a sliding
13670 window memory map manager.")
13671 (license license:bsd-3)))
13673 (define-public python2-smmap2
13674 (package-with-python2 python-smmap2))
13676 (define-public python-regex
13678 (name "python-regex")
13679 (version "2019.04.14")
13682 (uri (pypi-uri "regex" version))
13685 "1a6hhfs6l6snr1z654ay6wzbmwdkmv282fzfkd5hk2d1n73y8v6m"))))
13686 ;; TODO: Fix and enable regex_test.py tests that complain about the
13687 ;; test.support module not existing.
13688 (build-system python-build-system)
13689 (home-page "https://bitbucket.org/mrabarnett/mrab-regex")
13690 (synopsis "Alternative regular expression module")
13691 (description "This regular expression implementation is backwards-
13692 compatible with the standard @code{re} module, but offers additional
13693 functionality like full case-folding for case-insensitive matches in Unicode.")
13694 (license license:psfl)))
13696 (define-public python2-regex
13697 (package-with-python2 python-regex))
13699 (define-public python2-pyopengl
13701 (name "python2-pyopengl")
13706 (uri (pypi-uri "PyOpenGL" version))
13709 "1byxjj6a8rwzhxhjqlc588zdad2qwxdd7vlam2653ylll31waiwv"))))
13711 `(#:python ,python-2))
13712 (build-system python-build-system)
13713 (home-page "http://pyopengl.sourceforge.net")
13714 (synopsis "Standard OpenGL bindings for Python")
13716 "PyOpenGL is the most common cross platform Python binding to OpenGL and
13717 related APIs. The binding is created using the standard @code{ctypes}
13719 (license license:bsd-3)))
13721 (define-public python2-pyopengl-accelerate
13723 (inherit python2-pyopengl)
13724 (name "python2-pyopengl-accelerate")
13729 (uri (pypi-uri "PyOpenGL-accelerate" version))
13732 "0464c1ifzk0k92lyndikmvzjgnx1y25r7bkkc8pnxm4kp1q4czwj"))))
13733 (synopsis "Acceleration code for PyOpenGL")
13735 "This is the Cython-coded accelerator module for PyOpenGL.")))
13737 (define-public python-rencode
13739 (name "python-rencode")
13744 (uri (pypi-uri "rencode" version))
13747 "0mzwdq1is7kyyr32i5k4iz6g5xxdvmiyc132jnc60p9m6lnwjrpv"))))
13748 (build-system python-build-system)
13751 (modify-phases %standard-phases
13752 (add-before 'check 'delete-bogus-test
13753 ;; This test requires /home/aresch/Downloads, which is not provided by
13754 ;; the build environment.
13756 (delete-file "rencode/t.py")
13758 (native-inputs `(("pkg-config" ,pkg-config)
13759 ("python-cython" ,python-cython)))
13760 (home-page "https://github.com/aresch/rencode")
13761 (synopsis "Serialization of heterogeneous data structures")
13763 "The @code{rencode} module is a data structure serialization library,
13764 similar to @code{bencode} from the BitTorrent project. For complex,
13765 heterogeneous data structures with many small elements, r-encoding stake up
13766 significantly less space than b-encodings. This version of rencode is a
13767 complete rewrite in Cython to attempt to increase the performance over the
13768 pure Python module.")
13769 (license license:bsd-3)))
13771 (define-public python2-rencode
13772 (package-with-python2 python-rencode))
13774 (define-public python-xenon
13776 (name "python-xenon")
13781 (uri (pypi-uri "xenon" version))
13784 "029cbhysg2vr5n4jz8gpg2793f8wkwnqpr1qgv6c1dn685vy31mc"))))
13785 (build-system python-build-system)
13787 `(("python-pyyaml" ,python-pyyaml)
13788 ("python-radon" ,python-radon)
13789 ("python-requests" ,python-requests)
13790 ("python-flake8" ,python-flake8)
13791 ("python-tox" ,python-tox)))
13794 (modify-phases %standard-phases
13795 (add-before 'build 'patch-test-requirements
13797 ;; Remove httpretty dependency for tests.
13798 (substitute* "setup.py"
13799 (("httpretty") ""))
13801 (home-page "https://xenon.readthedocs.org/")
13802 (synopsis "Monitor code metrics for Python on your CI server")
13804 "Xenon is a monitoring tool based on Radon. It monitors code complexity.
13805 Ideally, @code{xenon} is run every time code is committed. Through command
13806 line options, various thresholds can be set for the complexity of code. It
13807 will fail (i.e. it will exit with a non-zero exit code) when any of these
13808 requirements is not met.")
13809 (license license:expat)))
13811 (define-public python2-xenon
13812 (package-with-python2 python-xenon))
13814 (define-public python-pysocks
13816 (name "python-pysocks")
13821 (uri (pypi-uri "PySocks" version))
13824 "0z4p31bpqm893cf87qqgb30k7nwd8kqfjwwjm5cvxb6zbyj1w0yr"))))
13825 (build-system python-build-system)
13826 (arguments `(#:tests? #f))
13827 (home-page "https://github.com/Anorov/PySocks")
13828 (synopsis "SOCKS client module")
13829 (description "@code{pysocks} is an updated and semi-actively maintained
13830 version of @code{SocksiPy} with bug fixes and extra features.")
13831 (license license:bsd-3)))
13833 (define-public python2-pysocks
13834 (package-with-python2 python-pysocks))
13836 (define-public python-pydiff
13838 (name "python-pydiff")
13843 (uri (pypi-uri "pydiff" version))
13846 "1als83h9w0gab24ipyna6khm390qmpnpkc5jksmdbs2xc8hp2z44"))))
13847 (build-system python-build-system)
13848 (home-page "https://github.com/myint/pydiff")
13849 (synopsis "Library to diff two Python files at the bytecode level")
13851 "@code{pydiff} makes it easy to look for actual code changes while
13852 ignoring formatting changes.")
13853 (license license:expat)))
13855 (define-public python2-pydiff
13856 (package-with-python2 python-pydiff))
13858 (define-public python-tqdm
13860 (name "python-tqdm")
13865 (uri (pypi-uri "tqdm" version))
13868 "1pw0ngm0zn9papdmkwipi3yih5c3di6d0w849bdmrraq4d2d9h2y"))))
13869 (build-system python-build-system)
13871 `(("python-flake8" ,python-flake8)
13872 ("python-nose" ,python-nose)
13873 ("python-coverage" ,python-coverage)))
13874 (home-page "https://github.com/tqdm/tqdm")
13875 (synopsis "Fast, extensible progress meter")
13877 "Make loops show a progress bar on the console by just wrapping any
13878 iterable with @code{|tqdm(iterable)|}. Offers many options to define
13879 design and layout.")
13880 (license (list license:mpl2.0 license:expat))
13881 (properties `((python2-variant . ,(delay python2-tqdm))))))
13883 (define-public python2-tqdm
13884 (let ((tqdm (package-with-python2
13885 (strip-python2-variant python-tqdm))))
13886 (package (inherit tqdm)
13887 (native-inputs `(("python2-functools32" ,python2-functools32)
13888 ,@(package-native-inputs tqdm))))))
13890 (define-public python-pkginfo
13892 (name "python-pkginfo")
13897 (uri (pypi-uri "pkginfo" version))
13900 "0x6lm17p1ks031mj6pajyp4rkq74vpqq8qwjb7ikgwmkli1day2q"))))
13901 (build-system python-build-system)
13903 ;; The tests are broken upstream.
13906 "https://code.launchpad.net/~tseaver/pkginfo/trunk")
13908 "Query metadatdata from sdists, bdists, and installed packages")
13910 "API to query the distutils metadata written in @file{PKG-INFO} inside a
13911 source distriubtion (an sdist) or a binary distribution (e.g., created by
13912 running bdist_egg). It can also query the EGG-INFO directory of an installed
13913 distribution, and the *.egg-info stored in a \"development checkout\" (e.g,
13914 created by running @code{python setup.py develop}).")
13915 (license license:expat)))
13917 (define-public python2-pkginfo
13918 (package-with-python2 python-pkginfo))
13920 (define-public python-twine
13922 (name "python-twine")
13927 (uri (pypi-uri "twine" version))
13930 "1ay1b6kdq6k4bfbjsvf6ymj41wrgpvinhxndb09355pwhxwmp96a"))))
13931 (build-system python-build-system)
13933 `(("python-tqdm" ,python-tqdm)
13934 ("python-pkginfo" ,python-pkginfo)
13935 ("python-requests" ,python-requests)
13936 ("python-requests-toolbelt" ,python-requests-toolbelt)))
13937 (home-page "https://github.com/pypa/twine")
13938 (synopsis "Collection of utilities for interacting with PyPI")
13940 "@code{twine} currently supports registering projects and uploading
13941 distributions. It authenticates the user over HTTPS, allows them to pre-sign
13942 their files and supports any packaging format (including wheels).")
13943 (license license:asl2.0)))
13945 (define-public python2-twine
13946 (package-with-python2 python-twine))
13948 (define-public python-linecache2
13950 (name "python-linecache2")
13955 (uri (pypi-uri "linecache2" version))
13958 "0z79g3ds5wk2lvnqw0y2jpakjf32h95bd9zmnvp7dnqhf57gy9jb"))))
13959 (build-system python-build-system)
13961 `(;; The tests depend on unittest2, and our version is a bit too old.
13964 `(("python-pbr" ,python-pbr-minimal)))
13966 "https://github.com/testing-cabal/linecache2")
13967 (synopsis "Backports of the linecache module")
13969 "The linecache module allows one to get any line from any file, while
13970 attempting to optimize internally, using a cache, the common case where many
13971 lines are read from a single file.")
13972 (license license:psfl)))
13974 (define-public python2-linecache2
13975 (package-with-python2 python-linecache2))
13977 (define-public python-traceback2
13979 (name "python-traceback2")
13984 (uri (pypi-uri "traceback2" version))
13987 "0c1h3jas1jp1fdbn9z2mrgn3jj0hw1x3yhnkxp7jw34q15xcdb05"))))
13988 (build-system python-build-system)
13990 `(;; python-traceback2 and python-unittest2 depend on one another.
13993 `(("python-pbr" ,python-pbr-minimal)))
13995 `(("python-linecache2" ,python-linecache2)))
13997 "https://github.com/testing-cabal/traceback2")
13998 (synopsis "Backports of the traceback module")
14000 "This module provides a standard interface to extract, format and print
14001 stack traces of Python programs. It exactly mimics the behavior of the Python
14002 interpreter when it prints a stack trace.")
14003 (license license:psfl)))
14005 (define-public python2-traceback2
14006 (package-with-python2 python-traceback2))
14008 (define-public python-ratelimiter
14010 (name "python-ratelimiter")
14015 (uri (pypi-uri "ratelimiter" version))
14018 "1dhz85mj5bqd2mij84ncs6pz32hgidr79hay4aqfmzaa4rbb497p"))))
14019 (build-system python-build-system)
14021 '(#:tests? #f)) ; There are no tests in the pypi archive.
14022 (home-page "https://github.com/RazerM/ratelimiter")
14023 (synopsis "Simple rate limiting object")
14025 "The @code{ratelimiter} module ensures that an operation will not be
14026 executed more than a given number of times during a given period.")
14027 (license license:asl2.0)))
14029 (define-public python2-ratelimiter
14030 (package-with-python2 python-ratelimiter))
14032 (define-public python-dukpy
14034 (name "python-dukpy")
14039 (uri (git-reference
14040 (url "https://github.com/kovidgoyal/dukpy.git")
14041 (commit (string-append "v" version))))
14042 (file-name (git-file-name name version))
14044 (base32 "13h21nqzasv4zj32xs61brmc106pr2cx243672crcmwxxnjgaxls"))))
14045 (build-system python-build-system)
14046 (home-page "https://github.com/kovidgoyal/dukpy")
14047 (synopsis "Run JavaScript in python")
14049 "dukpy is a JavaScript runtime environment for Python using the duktape
14050 embeddable JavaScript engine.")
14051 ;; Dukpy is licensed under MIT like the embedded duktape library,
14052 ;; with 'errors.c' as GPL3.
14053 (license (list license:expat license:gpl3))))
14055 (define-public python2-dukpy
14056 (package-with-python2 python-dukpy))
14058 (define-public python-jsonrpclib-pelix
14060 (name "python-jsonrpclib-pelix")
14065 (uri (pypi-uri "jsonrpclib-pelix" version))
14068 "0f83z5zi7w32vprhk1dyc94ir1bh4hdd57bjdbwkq9ykng8qilhl"))))
14069 (build-system python-build-system)
14071 `(#:tests? #f)) ; no tests in PyPI tarball
14072 (home-page "https://github.com/tcalmant/jsonrpclib/")
14073 (synopsis "JSON-RPC 2.0 client library for Python")
14075 "This library implements the JSON-RPC v2.0
14076 specification (backwards-compatible) as a client library for Python. This
14077 version is a fork of jsonrpclib by Josh Marshall, usable with Pelix remote
14079 (license license:asl2.0)))
14081 (define-public python2-jsonrpclib-pelix
14082 (package-with-python2 python-jsonrpclib-pelix))
14084 (define-public python-setuptools-scm-git-archive
14086 (name "python-setuptools-scm-git-archive")
14091 (uri (pypi-uri "setuptools_scm_git_archive" version))
14094 "1nii1sz5jq75ilf18bjnr11l9rz1lvdmyk66bxl7q90qan85yhjj"))))
14095 (build-system python-build-system)
14097 `(("python-pytest" ,python-pytest)))
14099 `(("python-setuptools-scm" ,python-setuptools-scm)))
14100 (home-page "https://github.com/Changaco/setuptools_scm_git_archive/")
14101 (synopsis "Setuptools_scm plugin for git archives")
14103 "The setuptools_scm_git_archive package is a plugin to
14104 setuptools_scm, which supports obtaining versions from git archives that
14105 belong to tagged versions.")
14106 (license license:expat)))
14108 (define-public python2-setuptools-scm-git-archive
14109 (package-with-python2 python-setuptools-scm-git-archive))
14111 (define-public python-setuptools-git
14113 (name "python-setuptools-git")
14118 (uri (pypi-uri "setuptools-git" version))
14121 "0i84qjwp5m0l9qagdjww2frdh63r37km1c48mrvbmaqsl1ni6r7z"))))
14122 (build-system python-build-system)
14125 (modify-phases %standard-phases
14126 ;; This is needed for tests.
14127 (add-after 'unpack 'configure-git
14129 (setenv "HOME" "/tmp")
14130 (invoke "git" "config" "--global" "user.email" "guix")
14131 (invoke "git" "config" "--global" "user.name" "guix")
14134 `(("git" ,git-minimal)))
14135 (home-page "https://github.com/msabramo/setuptools-git")
14136 (synopsis "Setuptools revision control system plugin for Git")
14138 "This package provides a plugin for Setuptools for revision control with
14140 (license license:bsd-3)))
14142 (define-public python-pyclipper
14144 (name "python-pyclipper")
14145 (version "1.1.0.post3")
14149 (uri (pypi-uri "pyclipper" version ".zip"))
14151 (base32 "164yksvqwqvwzh8f8lq92asg87hd8rvcy2xb5vm4y4ccvd5xgb7i"))
14152 (modules '((guix build utils)))
14155 ;; This file is generated by Cython.
14156 (delete-file "pyclipper/pyclipper.cpp") #t))))
14157 (build-system python-build-system)
14160 (modify-phases %standard-phases
14161 (add-before 'build 'cythonize-sources
14163 (with-directory-excursion "pyclipper"
14164 (invoke "cython" "--cplus" "pyclipper.pyx")))))))
14166 `(("python-setuptools-scm-git-archive" ,python-setuptools-scm-git-archive)))
14168 `(("python-cython" ,python-cython)
14169 ("python-pytest" ,python-pytest)
14170 ("python-pytest-runner" ,python-pytest-runner)
14171 ("python-unittest2" ,python-unittest2)
14173 (home-page "https://github.com/greginvm/pyclipper")
14174 (synopsis "Wrapper for Angus Johnson's Clipper library")
14176 "Pyclipper is a Cython wrapper for the C++ translation of the
14177 Angus Johnson's polygon clipping Clipper library (ver. 6.4.2).")
14178 (license license:expat)))
14180 (define-public python2-pyclipper
14181 (package-with-python2 python-pyclipper))
14183 (define-public python2-booleanoperations
14185 (name "python2-booleanoperations")
14190 (uri (pypi-uri "booleanOperations" version ".zip"))
14193 "1hw42fazdpvsn77glx96hwsj9l17mvx37sc5707s08y5w6fx16mn"))))
14194 (build-system python-build-system)
14196 `(#:python ,python-2))
14199 ("python2-pytest" ,python2-pytest)
14200 ("python2-pytest-runner" ,python2-pytest-runner)))
14202 `(("python-fonttools" ,python2-fonttools)
14203 ("python-pyclipper" ,python2-pyclipper)
14204 ("python-ufolib" ,python2-ufolib)))
14205 (home-page "https://github.com/typemytype/booleanOperations")
14206 (synopsis "Boolean operations on paths")
14208 "BooleanOperations provides a Python library that enables
14209 boolean operations on paths.")
14210 (license license:expat)))
14212 (define-public python-tempdir
14214 (name "python-tempdir")
14219 (uri (pypi-uri "tempdir" version))
14222 "13msyyxqbicr111a294x7fsqbkl6a31fyrqflx3q7k547gnq15k8"))))
14223 (build-system python-build-system)
14224 (home-page "https://pypi.org/project/tempdir/")
14226 ;; the package has no tests
14228 (synopsis "Python library for managing temporary directories")
14230 "This library manages temporary directories that are automatically
14231 deleted with all their contents when they are no longer needed. It is
14232 particularly convenient for use in tests.")
14233 (license license:expat)))
14235 (define-public python2-tempdir
14236 (package-with-python2 python-tempdir))
14238 (define-public python-activepapers
14240 (name "python-activepapers")
14245 (uri (pypi-uri "ActivePapers.Py" version))
14248 "12wkhjh90ffipjzv10swndp2xv9hd7xrxvg6v0n4n3i411pj4xb8"))))
14249 (build-system python-build-system)
14251 `(#:modules ((ice-9 ftw)
14254 (guix build python-build-system))
14257 (modify-phases %standard-phases
14258 (add-after 'unpack 'delete-python2-code
14260 (for-each delete-file
14261 '("lib/activepapers/builtins2.py"
14262 "lib/activepapers/standardlib2.py"
14263 "lib/activepapers/utility2.py"))))
14266 ;; Deactivate the test cases that download files
14267 (setenv "NO_NETWORK_ACCESS" "1")
14268 ;; For some strange reason, some tests fail if nosetests runs all
14269 ;; test modules in a single execution. They pass if each test
14270 ;; module is run individually.
14271 (for-each (lambda (filename)
14272 (invoke "nosetests"
14273 (string-append "tests/" filename)))
14276 (string-suffix? ".py" filename)))))))))
14278 `(("python-tempdir" ,python-tempdir)
14279 ("python-nose" ,python-nose)))
14281 `(("python-h5py" ,python-h5py)))
14282 (home-page "http://www.activepapers.org/")
14283 (synopsis "Executable papers for scientific computing")
14285 "ActivePapers is a tool for working with executable papers, which
14286 combine data, code, and documentation in single-file packages,
14287 suitable for publication as supplementary material or on repositories
14288 such as figshare or Zenodo.")
14289 (properties `((python2-variant . ,(delay python2-activepapers))))
14290 (license license:bsd-3)))
14292 (define-public python2-activepapers
14293 (let ((base (package-with-python2
14294 (strip-python2-variant python-activepapers))))
14298 (substitute-keyword-arguments (package-arguments base)
14300 `(modify-phases ,phases
14301 (delete 'delete-python2-code)
14302 (add-after 'unpack 'delete-python3-code
14304 (for-each delete-file
14305 '("lib/activepapers/builtins3.py"
14306 "lib/activepapers/standardlib3.py"
14307 "lib/activepapers/utility3.py")))))))))))
14309 (define-public python-semver
14311 (name "python-semver")
14316 (uri (pypi-uri "semver" version))
14319 "183kg1rhzz3hqizvphkd8hlbf1zxfx8737zhfkmqzxi71jmdw7pd"))))
14320 (build-system python-build-system)
14322 `(("python-tox" ,python-tox)
14323 ("python-virtualenv" ,python-virtualenv)))
14324 (home-page "https://github.com/k-bx/python-semver")
14325 (synopsis "Python helper for Semantic Versioning")
14326 (description "This package provides a Python library for
14327 @url{Semantic Versioning, http://semver.org/}.")
14328 (license license:bsd-3)))
14330 (define-public python2-semver
14331 (package-with-python2 python-semver))
14333 (define-public python-pyro4
14335 (name "python-pyro4")
14340 (uri (pypi-uri "Pyro4" version))
14342 (base32 "0gsjg869y4gpy265s1gj1f2qy6jn5iz8r2bwwnq78r1r5yi15zib"))))
14343 (build-system python-build-system)
14345 '(#:tests? #f)) ;FIXME: Some tests require network access.
14347 `(("python-cloudpickle" ,python-cloudpickle)
14348 ("python-dill" ,python-dill)
14349 ("python-msgpack" ,python-msgpack)))
14351 `(("python-serpent" ,python-serpent)))
14352 (home-page "https://pyro4.readthedocs.io")
14353 (synopsis "Distributed object middleware for Python")
14355 "Pyro enables you to build applications in which objects can talk to each
14356 other over the network. You can just use normal Python method calls to call
14357 objects on other machines, also known as remote procedure calls (RPC).")
14358 (license license:expat)))
14360 (define-public python2-pyro
14362 (name "python2-pyro")
14367 (uri (pypi-uri "Pyro" version))
14368 (file-name (string-append "Pyro-" version ".tar.gz"))
14371 "0y75wzdqbjy565rpxaxscav4j8xg060sa90lnmb7aypgaf251v8v"))))
14372 (build-system python-build-system)
14374 ;; Pyro is not compatible with Python 3
14375 `(#:python ,python-2
14376 ;; Pyro has no test cases for automatic execution
14378 (home-page "http://pythonhosted.org/Pyro/")
14379 (synopsis "Distributed object manager for Python")
14380 (description "Pyro is a Distributed Object Technology system
14381 written in Python that is designed to be easy to use. It resembles
14382 Java's Remote Method Invocation (RMI). It has less similarity to CORBA,
14383 which is a system and language independent Distributed Object Technology
14384 and has much more to offer than Pyro or RMI. Pyro 3.x is no
14385 longer maintained. New projects should use Pyro4 instead, which
14386 is the new Pyro version that is actively developed.")
14387 (license license:expat)))
14389 (define-public python2-scientific
14391 (name "python2-scientific")
14396 (uri (git-reference
14397 (url "https://github.com/khinsen/ScientificPython")
14398 (commit (string-append "rel" version))))
14399 (file-name (git-file-name name version))
14402 "16l48aj9fps9r7jyk8gpxppwrv0fqvlc13sayxskz28r5s6sjwbl"))))
14403 (build-system python-build-system)
14405 `(("netcdf" ,netcdf)))
14407 `(("python-numpy" ,python2-numpy-1.8)
14408 ("python-pyro" ,python2-pyro)))
14410 ;; ScientificPython is not compatible with Python 3
14411 `(#:python ,python-2
14412 #:tests? #f ; No test suite
14414 (modify-phases %standard-phases
14416 (lambda* (#:key inputs #:allow-other-keys)
14417 (invoke "python" "setup.py" "build"
14418 (string-append "--netcdf_prefix="
14419 (assoc-ref inputs "netcdf"))))))))
14420 (home-page "http://dirac.cnrs-orleans.fr/ScientificPython")
14421 (synopsis "Python modules for scientific computing")
14422 (description "ScientificPython is a collection of Python modules that are
14423 useful for scientific computing. Most modules are rather general (Geometry,
14424 physical units, automatic derivatives, ...) whereas others are more
14425 domain-specific (e.g. netCDF and PDB support). The library is currently
14426 not actively maintained and works only with Python 2 and NumPy < 1.9.")
14427 (license license:cecill-c)))
14429 (define-public python2-mmtk
14431 (name "python2-mmtk")
14436 (uri (git-reference
14437 (url "https://github.com/khinsen/MMTK")
14438 (commit (string-append "rel" version))))
14439 (file-name (git-file-name name version))
14442 "1fqwh3ba9jd42nigvn5shndgwb1zy7kh9520ncvqci7n8ffjr6p1"))))
14443 (build-system python-build-system)
14445 `(("netcdf" ,netcdf)))
14447 `(("python-scientific" ,python2-scientific)
14448 ("python-tkinter" ,python-2 "tk")))
14450 `(#:python ,python-2
14453 (modify-phases %standard-phases
14454 (add-before 'build 'includes-from-scientific
14455 (lambda* (#:key inputs #:allow-other-keys)
14456 (mkdir-p "Include/Scientific")
14459 (assoc-ref inputs "python-scientific")
14460 "/include/python2.7/Scientific")
14461 "Include/Scientific"))))))
14462 (home-page "http://dirac.cnrs-orleans.fr/MMTK")
14463 (synopsis "Python library for molecular simulation")
14464 (description "MMTK is a library for molecular simulations with an emphasis
14465 on biomolecules. It provides widely used methods such as Molecular Dynamics
14466 and normal mode analysis, but also basic routines for implementing new methods
14467 for simulation and analysis. The library is currently not actively maintained
14468 and works only with Python 2 and NumPy < 1.9.")
14469 (license license:cecill-c)))
14471 (define-public python-phonenumbers
14473 (name "python-phonenumbers")
14478 (uri (pypi-uri "phonenumbers" version))
14481 "03fmrgb4r8x3ykmddjs9i3zhs703in8smikj3a6447blqpimwyh1"))))
14482 (build-system python-build-system)
14484 "https://github.com/daviddrysdale/python-phonenumbers")
14486 "Python library for dealing with international phone numbers")
14488 "This package provides a Python port of Google's libphonenumber library.")
14489 (license license:asl2.0)))
14491 (define-public python2-phonenumbers
14492 (package-with-python2 python-phonenumbers))
14494 (define-public python-send2trash
14496 (name "python-send2trash")
14499 (origin (method git-fetch)
14500 ;; Source tarball on PyPI doesn't include tests.
14501 (uri (git-reference
14502 (url "https://github.com/hsoft/send2trash.git")
14504 (file-name (git-file-name name version))
14507 "1c76zldhw2ay7q7r00nnzcampjz9lkqfcbzqpm0iqp5i6bmmv30v"))))
14508 (build-system python-build-system)
14511 (modify-phases %standard-phases
14512 (add-before 'check 'pre-check
14514 (mkdir-p "/tmp/foo")
14515 (setenv "HOME" "/tmp/foo")
14517 (home-page "https://github.com/hsoft/send2trash")
14518 (synopsis "Send files to the user's @file{~/Trash} directory")
14519 (description "This package provides a Python library to send files to the
14520 user's @file{~/Trash} directory.")
14521 (properties `((python2-variant . ,(delay python2-send2trash))))
14522 (license license:bsd-3)))
14524 (define-public python2-send2trash
14526 (inherit (package-with-python2 (strip-python2-variant python-send2trash)))
14528 (substitute-keyword-arguments (package-arguments python-send2trash)
14530 `(modify-phases ,phases
14531 (add-before 'check 'setenv
14533 (setenv "PYTHONPATH"
14534 (string-append (getcwd) ":" (getenv "PYTHONPATH")))
14537 (define-public python-yapf
14539 (name "python-yapf")
14544 (uri (pypi-uri "yapf" version))
14547 "1pj3xzblmbssshi889b6n9hwqbjpabw6j0fimlng2sshd3226bki"))))
14548 (build-system python-build-system)
14549 (home-page "https://github.com/google/yapf")
14550 (synopsis "Formatter for Python code")
14551 (description "YAPF is a formatter for Python code. It's based off of
14552 @dfn{clang-format}, developed by Daniel Jasper. In essence, the algorithm
14553 takes the code and reformats it to the best formatting that conforms to the
14554 style guide, even if the original code didn't violate the style guide.")
14555 (license license:asl2.0)))
14557 (define-public python2-yapf
14558 (package-with-python2 python-yapf))
14560 (define-public python-gyp
14561 (let ((commit "5e2b3ddde7cda5eb6bc09a5546a76b00e49d888f")
14564 (name "python-gyp")
14565 ;; Google does not release versions,
14566 ;; based on second most recent commit date.
14567 (version (git-version "0.0.0" revision commit))
14570 ;; Google does not release tarballs,
14571 ;; git checkout is needed.
14573 (uri (git-reference
14574 (url "https://chromium.googlesource.com/external/gyp")
14576 (file-name (git-file-name name version))
14579 "0fr7nxcrk292djmxzpcjaphnsd123k31gp8jnd91vwknhq6snmv9"))))
14580 (build-system python-build-system)
14581 (home-page "https://gyp.gsrc.io/")
14582 (synopsis "GYP is a Meta-Build system")
14584 "GYP builds build systems for large, cross platform applications.
14585 It can be used to generate XCode projects, Visual Studio projects, Ninja build
14586 files, and Makefiles.")
14587 (license license:bsd-3))))
14589 (define-public python2-gyp
14590 (package-with-python2 python-gyp))
14592 (define-public python-whatever
14594 (name "python-whatever")
14599 (uri (git-reference
14600 (url "https://github.com/Suor/whatever")
14602 (file-name (git-file-name name version))
14604 (base32 "1q7ajgqjfivxqsqgnhp4lc4p6jxyh4zprcsdbpd6dw54inaf0av5"))))
14605 (build-system python-build-system)
14608 (modify-phases %standard-phases
14611 (invoke "py.test"))))))
14613 `(("python-pytest" ,python-pytest)))
14614 (home-page "http://github.com/Suor/whatever")
14615 (synopsis "Make anonymous functions by partial application of operators")
14616 (description "@code{whatever} provides an easy way to make anonymous
14617 functions by partial application of operators.")
14618 (license license:bsd-3)))
14620 (define-public python2-whatever
14621 (package-with-python2 python-whatever))
14623 (define-public python-funcy
14625 (name "python-funcy")
14630 (uri (git-reference
14631 (url "https://github.com/Suor/funcy.git")
14634 (base32 "1s98vkjnq3zq71737hn8xa15kssvmy1sfzsll3vrlv53902418mw"))
14635 (file-name (git-file-name name version))))
14636 (build-system python-build-system)
14639 (modify-phases %standard-phases
14642 (invoke "py.test"))))))
14644 `(("python-pytest" ,python-pytest)
14645 ("python-whatever" ,python-whatever)))
14646 (home-page "http://github.com/Suor/funcy")
14647 (synopsis "Functional tools")
14648 (description "@code{funcy} is a library that provides functional tools.
14651 @item merge - Merges collections of the same type
14652 @item walk - Type-preserving map
14653 @item select - Selects a part of a collection
14654 @item take - Takes the first n items of a collection
14655 @item first - Takes the first item of a collection
14656 @item remove - Predicated-removes items of a collection
14657 @item concat - Concatenates two collections
14658 @item flatten - Flattens a collection with subcollections
14659 @item distinct - Returns only distinct items
14660 @item split - Predicated-splits a collection
14661 @item split_at - Splits a collection at a given item
14662 @item group_by - Groups items by group
14663 @item pairwise - Pairs off adjacent items
14664 @item partial - Partially-applies a function
14665 @item curry - Curries a function
14666 @item compose - Composes functions
14667 @item complement - Complements a predicate
14668 @item all_fn - \"all\" with predicate
14670 (license license:bsd-3)))
14672 (define-public python2-funcy
14673 (package-with-python2 python-funcy))
14675 (define-public python-isoweek
14677 (name "python-isoweek")
14682 (uri (pypi-uri "isoweek" version))
14685 "1s7zsf0pab0l9gn6456qadnz5i5h90hafcjwnhx5mq23qjxggwvk"))))
14686 (build-system python-build-system)
14687 (home-page "https://github.com/gisle/isoweek")
14688 (synopsis "Objects representing a week")
14689 (description "The @code{isoweek} module provide the class Week that
14690 implements the week definition of ISO 8601. This standard also defines
14691 a notation for identifying weeks; yyyyWww (where the W is a literal).
14692 Week instances stringify to this form.")
14693 (license license:bsd-3)))
14695 (define-public python2-isoweek
14696 (package-with-python2 python-isoweek))
14698 (define-public python-tokenize-rt
14700 (name "python-tokenize-rt")
14705 (uri (pypi-uri "tokenize-rt" version))
14708 "1yjvbz7rvrz31zjyax1cgy3xhf4wb3j18jwnj4bnl77ca4gliyiw"))))
14709 (build-system python-build-system)
14710 (home-page "https://github.com/asottile/tokenize-rt")
14711 (synopsis "Wrapper around the stdlib tokenize which roundtrips.")
14713 "This Python library is a wrapper around @code{tokenize} from the Python
14714 standard library. It provides two additional tokens @code{ESCAPED_NL} and
14715 @code{UNIMPORTANT_WS}, and a @code{Token} data type. Use @code{src_to_tokens}
14716 and @code{tokens_to_src} to roundtrip.")
14717 (license license:expat)))
14719 (define-public python-future-fstrings
14721 (name "python-future-fstrings")
14726 (uri (pypi-uri "future_fstrings" version))
14729 "0ydxqz2dvns44g55p8ix2x18qkfk3aaz0m0dc70f3g6n8js35h47"))))
14730 (build-system python-build-system)
14732 `(("python-tokenize-rt" ,python-tokenize-rt)))
14733 (home-page "https://github.com/asottile/future-fstrings")
14734 (synopsis "Backport of fstrings to Python < 3.6")
14736 "This package provides a UTF-8 compatible encoding
14737 @code{future_fstrings}, which performs source manipulation. It decodes the
14738 source bytes using the UTF-8 encoding and then rewrites Python 3.6 style
14739 @code{f} strings.")
14740 (license license:expat)))
14742 (define-public python-typed-ast
14744 (name "python-typed-ast")
14749 (uri (git-reference
14750 (url "https://github.com/python/typed_ast.git")
14753 (base32 "0l0hz809f7i356kmqkvfsaswiidb98j9hs9rrjnfawzqcbffzgyb"))
14754 (file-name (git-file-name name version))))
14755 (build-system python-build-system)
14757 `(#:modules ((guix build utils)
14758 (guix build python-build-system)
14763 (modify-phases %standard-phases
14766 (let ((cwd (getcwd)))
14767 (setenv "PYTHONPATH"
14768 (string-append cwd "/build/"
14769 (find (cut string-prefix? "lib" <>)
14770 (scandir (string-append cwd "/build")))
14772 (getenv "PYTHONPATH"))))
14775 (native-inputs `(("python-pytest" ,python-pytest)))
14776 (home-page "https://github.com/python/typed_ast")
14777 (synopsis "Fork of Python @code{ast} modules with type comment support")
14778 (description "This package provides a parser similar to the standard
14779 @code{ast} library. Unlike @code{ast}, the parsers in @code{typed_ast}
14780 include PEP 484 type comments and are independent of the version of Python
14781 under which they are run. The @code{typed_ast} parsers produce the standard
14782 Python AST (plus type comments), and are both fast and correct, as they are
14783 based on the CPython 2.7 and 3.7 parsers.")
14784 ;; See the file "LICENSE" for the details.
14785 (license (list license:psfl
14787 license:expat)))) ;ast27/Parser/spark.py
14789 (define-public python-typing
14791 (name "python-typing")
14796 (uri (pypi-uri "typing" version))
14799 "0ba9acs4awx15bf9v3nrs781msbd2nx826906nj6fqks2bvca9s0"))))
14800 (build-system python-build-system)
14801 (home-page "https://docs.python.org/3/library/typing.html")
14802 (synopsis "Type hints for Python")
14803 (description "This is a backport of the standard library @code{typing}
14804 module to Python versions older than 3.5. Typing defines a standard notation
14805 for Python function and variable type annotations. The notation can be used
14806 for documenting code in a concise, standard format, and it has been designed
14807 to also be used by static and runtime type checkers, static analyzers, IDEs
14809 (license license:psfl)))
14811 (define-public python2-typing
14812 (package-with-python2 python-typing))
14814 (define-public python-typing-extensions
14816 (name "python-typing-extensions")
14821 (uri (pypi-uri "typing_extensions" version))
14824 "0wfsv71pvkyf2na938l579jh0v3kzl6g744ijgnahcwd4d9x0b7v"))))
14825 (build-system python-build-system)
14827 "https://github.com/python/typing/blob/master/typing_extensions/README.rst")
14828 (synopsis "Experimental type hints for Python")
14830 "The typing_extensions module contains additional @code{typing} hints not
14831 yet present in the of the @code{typing} standard library.
14832 Included are implementations of:
14835 @item ContextManager
14846 @item TYPE_CHECKING
14847 @item AsyncGenerator
14849 (license license:psfl)))
14851 (define-public bpython
14858 (uri (pypi-uri "bpython" version))
14860 (base32 "1hl6frgvr2lqaxqczl8amg9xih32b3gzv429vs0qrjb8wpdj1k2n"))))
14861 (build-system python-build-system)
14864 (modify-phases %standard-phases
14865 (add-after 'unpack 'remove-failing-test
14867 ;; Remove failing test. FIXME: make it pass
14868 (delete-file "bpython/test/test_args.py")
14870 (add-after 'wrap 'add-aliases
14871 ;; for symmetry to bpython2, add symlinks bypthon3, bpdb3, etc.
14872 (lambda* (#:key outputs #:allow-other-keys)
14873 (let ((out (assoc-ref outputs "out")))
14876 (symlink old (string-append out "/bin/" new)))
14877 '("bpython" "bpython-curses" "bpython-urwid" "bpdb")
14878 '("bpython3" "bpython3-curses" "bpython3-urwid" "bpdb3")))
14881 `(("python-pygments" ,python-pygments)
14882 ("python-requests" ,python-requests)
14883 ("python-babel" ,python-babel) ; optional, for internationalization
14884 ("python-curtsies" ,python-curtsies) ; >= 0.1.18
14885 ("python-greenlet" ,python-greenlet)
14886 ("python-urwid" ,python-urwid) ; for bpython-urwid only
14887 ("python-six" ,python-six)))
14889 `(("python-sphinx" ,python-sphinx)
14890 ("python-mock" ,python-mock)))
14891 (home-page "https://bpython-interpreter.org/")
14892 (synopsis "Fancy interface to the Python interpreter")
14893 (description "Bpython is a fancy interface to the Python
14894 interpreter. bpython's main features are
14897 @item in-line syntax highlighting,
14898 @item readline-like autocomplete with suggestions displayed as you type,
14899 @item expected parameter list for any Python function,
14900 @item \"rewind\" function to pop the last line of code from memory and
14902 @item send the code you've entered off to a pastebin,
14903 @item save the code you've entered to a file, and
14904 @item auto-indentation.
14906 (license license:expat)))
14908 (define-public bpython2
14909 (let ((base (package-with-python2
14910 (strip-python2-variant bpython))))
14911 (package (inherit base)
14914 `(#:python ,python-2
14916 (modify-phases %standard-phases
14917 (add-after 'unpack 'remove-failing-test
14919 ;; Remove failing test. FIXME: make it pass
14920 (delete-file "bpython/test/test_args.py")
14921 ;; Disable failing test-cases (renaming inhibits they are
14923 (substitute* "bpython/test/test_curtsies_repl.py"
14924 (("^(\\s*def )(test_get_last_word_with_prev_line\\W)" _ a b)
14925 (string-append a "xxx_off_" b))
14926 (("^(\\s*def )(test_complex\\W)" _ a b)
14927 (string-append a "xxx_off_" b)))
14929 (add-before 'build 'rename-scripts
14930 ;; rename the scripts to bypthon2, bpdb2, etc.
14932 (substitute* "setup.py"
14933 (("^(\\s+'bpdb)(\\s+=.*',?)\\s*?$" _ name rest)
14934 (string-append name "2" rest "\n"))
14935 (("^(\\s+'bpython)(-\\S+)?(\\s+=.*',?)\\s*?$" _ name sub rest)
14936 (string-append name "2" (or sub "") rest "\n")))
14939 (define-public python-pyinotify
14941 (name "python-pyinotify")
14945 (uri (pypi-uri "pyinotify" version))
14948 "1x3i9wmzw33fpkis203alygfnrkcmq9w1aydcm887jh6frfqm6cw"))))
14949 (build-system python-build-system)
14950 (arguments `(#:tests? #f)) ;no tests
14951 (home-page "https://github.com/seb-m/pyinotify")
14952 (synopsis "Python library for monitoring inotify events")
14954 "@code{pyinotify} provides a Python interface for monitoring
14955 file system events on Linux.")
14956 (license license:expat)))
14958 (define-public python2-pyinotify
14959 (package-with-python2 python-pyinotify))
14961 ;; Ada parser uses this version.
14962 (define-public python2-quex-0.67.3
14964 (name "python2-quex")
14969 (uri (string-append "mirror://sourceforge/quex/HISTORY/"
14970 (version-major+minor version)
14971 "/quex-" version ".zip"))
14974 "14gv8ll3ipqv4kyc2xiy891nrmjl4ic823zfyx8hassagyclyppw"))))
14975 (build-system python-build-system)
14977 `(("unzip" ,unzip)))
14979 `(#:python ,python-2
14982 (modify-phases %standard-phases
14983 (delete 'configure)
14986 (lambda* (#:key outputs #:allow-other-keys)
14987 (let* ((out (assoc-ref outputs "out"))
14988 (share/quex (string-append out "/share/quex"))
14989 (bin (string-append out "/bin")))
14990 (copy-recursively "." share/quex)
14992 (symlink (string-append share/quex "/quex-exe.py")
14993 (string-append bin "/quex"))
14995 (native-search-paths
14996 (list (search-path-specification
14997 (variable "QUEX_PATH")
14998 (files '("share/quex")))))
14999 (home-page "http://quex.sourceforge.net/")
15000 (synopsis "Lexical analyzer generator in Python")
15001 (description "@code{quex} is a lexical analyzer generator in Python.")
15002 (license license:lgpl2.1+))) ; Non-military
15004 (define-public python2-quex
15005 (package (inherit python2-quex-0.67.3)
15006 (name "python2-quex")
15011 (uri (string-append "mirror://sourceforge/quex/DOWNLOAD/quex-" version ".tar.gz"))
15014 "0svc9nla3b9145d6b7fb9dizx412l3difzqw0ilh9lz52nsixw8j"))
15015 (file-name (string-append name "-" version ".tar.gz"))))))
15017 (define-public python-more-itertools
15019 (name "python-more-itertools")
15024 (uri (pypi-uri "more-itertools" version))
15027 "16phg2f2dvm6ci5wr49ncha5lmc0m2in3bsl33c61vzca4gkvd4b"))))
15028 (build-system python-build-system)
15029 (home-page "https://github.com/erikrose/more-itertools")
15030 (synopsis "More routines for operating on iterables, beyond itertools")
15031 (description "Python's built-in @code{itertools} module implements a
15032 number of iterator building blocks inspired by constructs from APL, Haskell,
15033 and SML. @code{more-itertools} includes additional building blocks for
15034 working with iterables.")
15035 (properties `((python2-variant . ,(delay python2-more-itertools))))
15036 (license license:expat)))
15038 ;; The 5.x series are the last versions supporting Python 2.7.
15039 (define-public python2-more-itertools
15041 (inherit python-more-itertools)
15042 (name "python2-more-itertools")
15046 (uri (pypi-uri "more-itertools" version))
15049 "1r12cm6mcdwdzz7d47a6g4l437xsvapdlgyhqay3i2nrlv03da9q"))))
15051 `(#:python ,python2-minimal))
15053 `(("python2-six" ,python2-six-bootstrap)))))
15055 (define-public python-latexcodec
15057 (name "python-latexcodec")
15062 (uri (pypi-uri "latexcodec" version))
15064 (base32 "0wnp3yqcgx0rpy8dz51vh75lbp2qif67da19zi7m3ca98n887hgb"))))
15065 (build-system python-build-system)
15067 `(("python-six" ,python-six)))
15068 (home-page "https://readthedocs.org/projects/latexcodec/")
15069 (synopsis "Work with LaTeX code in Python")
15070 (description "Lexer and codec to work with LaTeX code in Python.")
15071 (license license:expat)))
15073 (define-public python-pybtex
15075 (name "python-pybtex")
15080 (uri (pypi-uri "pybtex" version))
15082 (base32 "070wfcmxrd7xg1si421mi9150gmx2qwx431nwf69sq3hhmgnx080"))))
15083 (build-system python-build-system)
15085 `(("python-nose" ,python-nose)))
15087 `(("python-latexcodec" ,python-latexcodec)
15088 ("python-pyyaml" ,python-pyyaml)
15089 ("python-six" ,python-six)))
15091 `(#:test-target "nosetests"))
15092 (home-page "https://pybtex.org/")
15093 (synopsis "BibTeX-compatible bibliography processor")
15094 (description "Pybtex is a BibTeX-compatible bibliography processor written
15095 in Python. You can simply type pybtex instead of bibtex.")
15096 (license license:expat)))
15098 (define-public python-onetimepass
15100 (name "python-onetimepass")
15105 (uri (pypi-uri "onetimepass" version))
15107 (base32 "09vagxgbq78wvq4xbikmn2hpqqsa2i96kqsmphf7dqynfv0dlsd5"))))
15108 (build-system python-build-system)
15109 (propagated-inputs `(("python-six" ,python-six)))
15110 (home-page "https://github.com/tadeck/onetimepass/")
15111 (synopsis "One-time password library")
15112 (description "Python one-time password library for HMAC-based (HOTP) and
15113 time-based (TOTP) passwords.")
15114 (license license:expat)))
15116 (define-public python-parso
15118 (name "python-parso")
15123 (uri (pypi-uri "parso" version))
15126 "171a9ivhxwsd52h1cgsz40zgzpgzscn7yqb7sdjhy8m1lzj0wsv6"))))
15128 `(("python-pytest" ,python-pytest)))
15129 (build-system python-build-system)
15131 `(#:phases (modify-phases %standard-phases
15133 (lambda _ (invoke "pytest" "-vv"))))))
15134 (home-page "https://github.com/davidhalter/parso")
15135 (synopsis "Python Parser")
15136 (description "Parso is a Python parser that supports error recovery and
15137 round-trip parsing for different Python versions (in multiple Python versions).
15138 Parso is also able to list multiple syntax errors in your Python file.")
15139 (license license:expat)))
15141 (define-public python2-parso
15142 (package-with-python2 python-parso))
15144 (define-public python-async-generator
15146 (name "python-async-generator")
15151 (uri (pypi-uri "async_generator" version))
15154 "0i11f6z6lix8ixi3vsk6s76zvvpmgrw6zjrcwjm0m4hjdh83vfvf"))))
15155 (build-system python-build-system)
15157 `(("python-pytest" ,python-pytest)))
15158 (home-page "https://github.com/python-trio/async_generator")
15159 (synopsis "Async generators and context managers for Python 3.5+")
15160 (description "@code{async_generator} back-ports Python 3.6's native async
15161 generators and Python 3.7's context managers into Python 3.5.")
15163 (license (list license:expat license:asl2.0))))
15165 (define-public python-async-timeout
15167 (name "python-async-timeout")
15172 (uri (pypi-uri "async-timeout" version))
15175 "0pscbyr840m7fyfc3r8zv9kgkwdcn9f78p7zsrczciwd09m82g0c"))))
15176 (build-system python-build-system)
15177 (home-page "https://github.com/aio-libs/async_timeout/")
15178 (synopsis "Timeout context manager for asyncio programs")
15179 (description "@code{async-timeout} provides a timeout timeout context
15180 manager compatible with @code{asyncio}.")
15181 (license license:asl2.0)))
15183 (define-public python-glob2
15185 (name "python-glob2")
15190 (uri (git-reference
15191 (url "https://github.com/miracle2k/python-glob2.git")
15192 (commit (string-append "v" version))))
15193 (file-name (git-file-name name version))
15195 (base32 "160nh2ay9lw2hi0rixpzb2k87r6ql56k0j2cm87lqz8xc8zbw919"))))
15196 (build-system python-build-system)
15197 (home-page "https://github.com/miracle2k/python-glob2/")
15198 (synopsis "Extended Version of the python buildin glob module")
15199 (description "This is an extended version of the Python
15200 @url{http://docs.python.org/library/glob.html, built-in glob module} which
15204 @item The ability to capture the text matched by glob patterns, and return
15205 those matches alongside the file names.
15206 @item A recursive @code{**} globbing syntax, akin for example to the
15207 @code{globstar} option of Bash.
15208 @item The ability to replace the file system functions used, in order to glob
15209 on virtual file systems.
15210 @item Compatible with Python 2 and Python 3 (tested with 3.3).
15213 Glob2 currently based on the glob code from Python 3.3.1.")
15214 (license license:bsd-2)))
15216 (define-public python2-glob2
15217 (package-with-python2 python-glob2))
15219 (define-public python-gipc
15221 (name "python-gipc")
15226 (uri (pypi-uri "gipc" version ".zip"))
15229 "0pd9by719qh882hqs6xpby61sn1x5h98hms5p2p8yqnycrf1s0h2"))))
15230 (build-system python-build-system)
15232 `(("unzip" ,unzip)))
15234 `(("python-gevent" ,python-gevent)))
15235 (home-page "http://gehrcke.de/gipc")
15236 (synopsis "Child process management in the context of gevent")
15237 (description "Usage of Python's multiprocessing package in a
15238 gevent-powered application may raise problems. With @code{gipc},
15239 process-based child processes can safely be created anywhere within a
15240 gevent-powered application.")
15241 (license license:expat)))
15243 (define-public python2-gipc
15244 (package-with-python2 python-gipc))
15246 (define-public python-fusepy
15248 (name "python-fusepy")
15253 (uri (pypi-uri "fusepy" version))
15256 "0v5grm4zyf58hsplwsxfbihddw95lz9w8cy3rpzbyha287swgx8h"))))
15257 (build-system python-build-system)
15260 (modify-phases %standard-phases
15261 (add-before 'build 'set-library-file-name
15262 (lambda* (#:key inputs #:allow-other-keys)
15263 (let ((fuse (assoc-ref inputs "fuse")))
15264 (substitute* "fuse.py"
15265 (("find_library\\('fuse'\\)")
15266 (string-append "'" fuse "/lib/libfuse.so'")))
15270 (home-page "https://github.com/fusepy/fusepy")
15271 (synopsis "Simple ctypes bindings for FUSE")
15272 (description "Python module that provides a simple interface to FUSE and
15273 MacFUSE. The binding is created using the standard @code{ctypes} library.")
15274 (license license:isc)))
15276 (define-public python2-fusepy
15277 (package-with-python2 python-fusepy))
15279 (define-public python2-gdrivefs
15281 (name "python2-gdrivefs")
15286 (uri (pypi-uri "gdrivefs" version))
15289 "0v9sp2cfg4ki3wagkwf3rnfpjhvgf845anz3757il9z95yvvcvb7"))))
15290 (build-system python-build-system)
15292 `(#:python ,python-2
15294 (modify-phases %standard-phases
15295 (add-before 'build 'patch-setup-py
15297 ;; Update requirements from dependency==version
15298 ;; to dependency>=version
15299 (substitute* "gdrivefs/resources/requirements.txt"
15303 `(("python2-gipc" ,python2-gipc)
15304 ("python2-gevent" ,python2-gevent)
15305 ("python2-greenlet" ,python2-greenlet)
15306 ("python2-httplib2" ,python2-httplib2)
15307 ("python2-uritemplate" ,python2-uritemplate)
15308 ("python2-oauth2client" ,python2-oauth2client)
15309 ("python2-six" ,python2-six)))
15311 `(("python2-dateutil" ,python2-dateutil)
15312 ("python2-fusepy" ,python2-fusepy)
15313 ("python2-google-api-client" ,python2-google-api-client)))
15314 (home-page "https://github.com/dsoprea/GDriveFS")
15315 (synopsis "Mount Google Drive as a local file system")
15316 (description "@code{gdrivefs} provides a FUSE wrapper for Google Drive
15317 under Python 2.7.")
15318 (license license:gpl2)))
15320 (define-public pybind11
15326 (uri (git-reference
15327 (url "https://github.com/pybind/pybind11.git")
15328 (commit (string-append "v" version))))
15331 "11b6dniri8m05spfd2a19irz82shf4sdca73566bniggrf3zclnf"))
15332 (file-name (git-file-name name version))))
15333 (build-system cmake-build-system)
15335 `(("python" ,python)
15336 ("python-pytest" ,python-pytest)))
15338 `(#:test-target "check"))
15339 (home-page "https://github.com/pybind/pybind11/")
15340 (synopsis "Seamless operability between C++11 and Python")
15341 (description "pybind11 is a lightweight header-only library that exposes
15342 C++ types in Python and vice versa, mainly to create Python bindings of
15343 existing C++ code. Its goals and syntax are similar to the excellent
15344 Boost.Python library by David Abrahams: to minimize boilerplate code in
15345 traditional extension modules by inferring type information using compile-time
15347 (license license:expat)))
15349 (define-public python-fasteners
15351 (name "python-fasteners")
15356 (uri (pypi-uri "fasteners" version))
15359 "063y20kx01ihbz2mziapmjxi2cd0dq48jzg587xdsdp07xvpcz22"))))
15360 (build-system python-build-system)
15362 `(("python-monotonic" ,python-monotonic)
15363 ("python-six" ,python-six)
15364 ("python-testtools" ,python-testtools)))
15365 (home-page "https://github.com/harlowja/fasteners")
15366 (synopsis "Python package that provides useful locks")
15368 "This package provides a Python program that provides following locks:
15371 @item Locking decorator
15372 @item Reader-writer locks
15373 @item Inter-process locks
15374 @item Generic helpers
15376 (properties `((python2-variant . ,(delay python2-fasteners))))
15377 (license license:asl2.0)))
15379 (define-public python2-fasteners
15380 (let ((base (package-with-python2 (strip-python2-variant python-fasteners))))
15384 `(("python2-futures" ,python2-futures)
15385 ,@(package-propagated-inputs base))))))
15387 (define-public python-requests-file
15389 (name "python-requests-file")
15394 (uri (pypi-uri "requests-file" version))
15397 "1yp2jaxg3v86pia0q512dg3hz6s9y5vzdivsgrba1kds05ial14g"))))
15398 (build-system python-build-system)
15400 `(("python-requests" ,python-requests)
15401 ("python-six" ,python-six)))
15403 "https://github.com/dashea/requests-file")
15404 (synopsis "File transport adapter for Requests")
15406 "Requests-File is a transport adapter for use with the Requests Python
15407 library to allow local file system access via @code{file://} URLs.")
15408 (license license:asl2.0)))
15410 (define-public python2-requests-file
15411 (package-with-python2 python-requests-file))
15413 (define-public python-tldextract
15415 (name "python-tldextract")
15420 (uri (pypi-uri "tldextract" version))
15423 "1d5s8v6kpsgazyahflhji1cfdcf89rv7l7z55v774bhzvcjp2y99"))))
15424 (build-system python-build-system)
15426 `(("python-pytest" ,python-pytest)
15427 ("python-responses" ,python-responses)))
15429 `(("python-idna" ,python-idna)
15430 ("python-requests" ,python-requests)
15431 ("python-requests-file" ,python-requests-file)))
15433 "https://github.com/john-kurkowski/tldextract")
15435 "Separate the TLD from the registered domain and subdomains of a URL")
15437 "TLDExtract accurately separates the TLD from the registered domain and
15438 subdomains of a URL, using the Public Suffix List. By default, this includes
15439 the public ICANN TLDs and their exceptions. It can optionally support the
15440 Public Suffix List's private domains as well.")
15441 (license license:bsd-3)))
15443 (define-public python2-tldextract
15444 (package-with-python2 python-tldextract))
15446 (define-public python-pynamecheap
15448 (name "python-pynamecheap")
15453 (uri (pypi-uri "PyNamecheap" version))
15456 "0wkbwz208j8nfrsmzmclvxg22ymknn0mlz76wbdza9k2bx2zja6l"))))
15457 (build-system python-build-system)
15459 `(("python-requests" ,python-requests)))
15461 "https://github.com/Bemmu/PyNamecheap")
15463 "Namecheap API client in Python")
15465 "PyNamecheap is a Namecheap API client in Python.")
15466 (license license:expat)))
15468 (define-public python2-pynamecheap
15469 (package-with-python2 python-pynamecheap))
15471 (define-public python-dns-lexicon
15473 (name "python-dns-lexicon")
15478 (uri (pypi-uri "dns-lexicon" version))
15481 "0jdn3ns71bsybr7njgsqr9xlxsqh7zh6phn4ld0liazqdn2l5f6m"))))
15482 (build-system python-build-system)
15484 `(#:tests? #f)) ;requires internet access
15486 `(("python-future" ,python-future)
15487 ("python-pynamecheap" ,python-pynamecheap)
15488 ("python-requests" ,python-requests)
15489 ("python-tldextract" ,python-tldextract)
15490 ("python-urllib3" ,python-urllib3)))
15491 (home-page "https://github.com/AnalogJ/lexicon")
15493 "Manipulate DNS records on various DNS providers")
15495 "Lexicon provides a way to manipulate DNS records on multiple DNS
15496 providers in a standardized way. It has a CLI but it can also be used as a
15497 Python library. It was designed to be used in automation, specifically with
15499 (license license:expat)))
15501 (define-public python2-dns-lexicon
15502 (package-with-python2 python-dns-lexicon))
15504 (define-public python-commandlines
15506 (name "python-commandlines")
15511 (uri (pypi-uri "commandlines" version))
15514 "0r7xcr0knv02p4mswa2bng61nn8nbhhrs6kvdnb9bb3hhjvm1dl6"))))
15515 (build-system python-build-system)
15516 (home-page "https://github.com/chrissimpkins/commandlines")
15517 (synopsis "Command line argument to object parsing library")
15519 "@code{Commandlines} is a Python library for command line application
15520 development that supports command line argument parsing, command string
15521 validation testing and application logic.")
15522 (license license:expat)))
15524 ;; Make sure to upgrade python-llvmlite in (gnu packages llvm) together with
15525 ;; python-numba. They have a very unflexible relationship.
15526 (define-public python-numba
15528 (name "python-numba")
15533 (uri (pypi-uri "numba" version))
15536 "1vnfzcq6fcnkmdms6114d49awvvj5181fl7z1wlha27qc2paxjy2"))))
15537 (build-system python-build-system)
15539 `(#:modules ((guix build utils)
15540 (guix build python-build-system)
15545 (modify-phases %standard-phases
15546 (add-after 'unpack 'disable-proprietary-features
15548 (setenv "NUMBA_DISABLE_HSA" "1")
15549 (setenv "NUMBA_DISABLE_CUDA" "1")
15551 (add-after 'unpack 'remove-failing-tests
15553 ;; FIXME: These tests fail for unknown reasons:
15554 ;; test_non_writable_pycache, test_non_creatable_pycache, and
15555 ;; test_frozen (all in numba.tests.test_dispatcher.TestCache).
15556 (substitute* "numba/tests/test_dispatcher.py"
15557 (("def test(_non_writable_pycache)" _ m)
15558 (string-append "def guix_skip" m))
15559 (("def test(_non_creatable_pycache)" _ m)
15560 (string-append "def guix_skip" m))
15561 (("def test(_frozen)" _ m)
15562 (string-append "def guix_skip" m)))
15564 ;; These tests fail because we don't run the tests from the build
15565 ;; directory: test_setup_py_distutils, test_setup_py_setuptools
15566 ;; They are in numba.tests.test_pycc.TestDistutilsSupport.
15567 (substitute* "numba/tests/test_pycc.py"
15568 (("def test(_setup_py_distutils|_setup_py_setuptools)" _ m)
15569 (string-append "def guix_skip" m)))
15571 ;; These tests fail because our version of Python does not have
15572 ;; a recognizable front-end for the Numba distribution to use
15573 ;; to check against.
15574 (substitute* "numba/tests/test_entrypoints.py"
15575 (("def test(_init_entrypoint)" _ m)
15576 (string-append "def guix_skip" m)))
15577 (substitute* "numba/tests/test_jitclasses.py"
15578 (("def test(_jitclass_longlabel_not_truncated)" _ m)
15579 (string-append "def guix_skip" m)))
15583 (let ((cwd (getcwd)))
15584 (setenv "PYTHONPATH"
15585 (string-append cwd "/build/"
15586 (find (cut string-prefix? "lib" <>)
15587 (scandir (string-append cwd "/build")))
15589 (getenv "PYTHONPATH")))
15590 ;; Something is wrong with the PYTHONPATH when running the
15591 ;; tests from the build directory, as it complains about not being
15592 ;; able to import certain modules.
15593 (with-directory-excursion "/tmp"
15594 (invoke "python3" "-m" "numba.runtests" "-v" "-m")))
15597 `(("python-llvmlite" ,python-llvmlite)
15598 ("python-numpy" ,python-numpy)
15599 ("python-singledispatch" ,python-singledispatch)))
15600 ;; Needed for tests.
15602 `(("python-jinja2" ,python-jinja2)
15603 ("python-pygments" ,python-pygments)))
15604 (home-page "https://numba.pydata.org")
15605 (synopsis "Compile Python code using LLVM")
15606 (description "Numba gives you the power to speed up your applications with
15607 high performance functions written directly in Python. With a few
15608 annotations, array-oriented and math-heavy Python code can be just-in-time
15609 compiled to native machine instructions, similar in performance to C, C++ and
15610 Fortran, without having to switch languages or Python interpreters.
15612 Numba works by generating optimized machine code using the LLVM compiler
15613 infrastructure at import time, runtime, or statically (using the included pycc
15615 (license license:bsd-3)))
15617 (define-public python-anndata
15619 (name "python-anndata")
15624 (uri (pypi-uri "anndata" version))
15627 "03x83yjaccbqszj7x4fwwmpil0ai59yx64d1zmf2691za3j03w73"))))
15628 (build-system python-build-system)
15630 `(("python-h5py" ,python-h5py)
15631 ("python-natsort" ,python-natsort)
15632 ("python-pandas" ,python-pandas)
15633 ("python-scipy" ,python-scipy)))
15634 (home-page "https://github.com/theislab/anndata")
15635 (synopsis "Annotated data for data analysis pipelines")
15636 (description "Anndata is a package for simple (functional) high-level APIs
15637 for data analysis pipelines. In this context, it provides an efficient,
15638 scalable way of keeping track of data together with learned annotations and
15639 reduces the code overhead typically encountered when using a mostly
15640 object-oriented library such as @code{scikit-learn}.")
15641 (license license:bsd-3)))
15643 (define-public python-dill
15645 (name "python-dill")
15646 (version "0.3.1.1")
15650 (uri (pypi-uri "dill" version))
15652 (base32 "1704g8z70d210ksgbccs2v545v9w0wc6lx15m296alb7jf0yzn22"))))
15653 (build-system python-build-system)
15656 (modify-phases %standard-phases
15659 (with-directory-excursion "/tmp"
15660 (invoke "nosetests" "-v"))
15663 `(("python-nose" ,python-nose)))
15664 (home-page "https://pypi.org/project/dill/")
15665 (synopsis "Serialize all of Python")
15666 (description "Dill extends Python's @code{pickle} module for serializing
15667 and de-serializing Python objects to the majority of the built-in Python
15668 types. Dill provides the user the same interface as the @code{pickle} module,
15669 and also includes some additional features. In addition to pickling Python
15670 objects, @code{dill} provides the ability to save the state of an interpreter
15671 session in a single command. Hence, it would be feasible to save a
15672 interpreter session, close the interpreter, ship the pickled file to another
15673 computer, open a new interpreter, unpickle the session and thus continue from
15674 the saved state of the original interpreter session.")
15675 (license license:bsd-3)))
15677 (define-public python-multiprocess
15679 (name "python-multiprocess")
15684 (uri (pypi-uri "multiprocess" version))
15687 "1r882nvd44xqwbrclwqx5rhs80l6809rcvpc7pkpgnij06cvvmcz"))))
15688 (build-system python-build-system)
15691 (modify-phases %standard-phases
15692 (add-after 'unpack 'disable-broken-tests
15694 ;; This test is broken as there is no keyboard interrupt.
15695 (substitute* "py3.7/multiprocess/tests/__init__.py"
15696 (("^(.*)def test_wait_result"
15698 (string-append indent
15699 "@unittest.skip(\"Disabled by Guix\")\n"
15702 ;; Tests must be run after installation.
15704 (add-after 'install 'check
15705 (lambda* (#:key inputs outputs #:allow-other-keys)
15706 (add-installed-pythonpath inputs outputs)
15707 (invoke "python" "-m" "multiprocess.tests")
15710 `(("python-dill" ,python-dill)))
15711 (home-page "https://pypi.org/project/multiprocess/")
15712 (synopsis "Multiprocessing and multithreading in Python")
15714 "This package is a fork of the multiprocessing Python package, a package
15715 which supports the spawning of processes using the API of the standard
15716 library's @code{threading} module.")
15717 (license license:bsd-3)))
15719 (define-public python-toolz
15721 (name "python-toolz")
15726 (uri (pypi-uri "toolz" version))
15729 "1j9i7fdjnx9dz35fdj5gvgxx6585ja9sxgaiv65if77nlxz0m7wj"))))
15730 (build-system python-build-system)
15731 ;; FIXME: tests cannot be computed: "Can't perform this operation for
15732 ;; unregistered loader type"
15733 (arguments '(#:tests? #f))
15734 (home-page "https://github.com/pytoolz/toolz/")
15735 (synopsis "List processing tools and functional utilities")
15737 "This package provides a set of utility functions for iterators,
15738 functions, and dictionaries.")
15739 (license license:bsd-3)))
15741 (define-public python2-toolz
15742 (package-with-python2 python-toolz))
15744 (define-public python-cytoolz
15746 (name "python-cytoolz")
15747 (version "0.9.0.1")
15751 (uri (pypi-uri "cytoolz" version))
15754 "1r80p88hm3f3r4zpixzr047y5hw4bzy41m4xywnhycda83x0dk44"))))
15755 (build-system python-build-system)
15756 ;; FIXME: tests fail with "module 'cytoolz.curried' has no attribute
15758 (arguments '(#:tests? #f))
15760 `(("python-toolz" ,python-toolz)))
15762 `(("python-cython" ,python-cython)))
15763 (home-page "https://github.com/pytoolz/cytoolz")
15764 (synopsis "High performance functional utilities")
15766 "The cytoolz package implements the same API as provided by toolz. The
15767 main differences are that @code{cytoolz} is faster and cytoolz offers a C API
15768 that is accessible to other projects developed in Cython.")
15769 (license license:bsd-3)))
15771 (define-public python-sortedcontainers
15773 (name "python-sortedcontainers")
15778 (uri (pypi-uri "sortedcontainers" version))
15781 "0fm0w5id2yhqld95hg2m636vjgkz377rvgdfqaxc25vbylr9lklp"))))
15782 (build-system python-build-system)
15784 `(("python-tox" ,python-tox)))
15785 (home-page "http://www.grantjenks.com/docs/sortedcontainers/")
15786 (synopsis "Sorted List, Sorted Dict, Sorted Set")
15788 "This package provides a sorted collections library, written in
15790 (license license:asl2.0)))
15792 (define-public python-cloudpickle
15794 (name "python-cloudpickle")
15799 (uri (pypi-uri "cloudpickle" version))
15802 "1wdw89mlm7fqa3fm3ymskx05jrys66n8m1z1a8s0mss0799ahsgi"))))
15803 (build-system python-build-system)
15804 ;; FIXME: there are 5 errors in 122 tests:
15805 ;; ERROR: test_function_pickle_compat_0_4_0 (tests.cloudpickle_test.CloudPickleTest)
15806 ;; ERROR: test_function_pickle_compat_0_4_1 (tests.cloudpickle_test.CloudPickleTest)
15807 ;; ERROR: test_function_pickle_compat_0_4_0 (tests.cloudpickle_test.Protocol2CloudPickleTest)
15808 ;; ERROR: test_function_pickle_compat_0_4_1 (tests.cloudpickle_test.Protocol2CloudPickleTest)
15809 ;; ERROR: test_temp_file (tests.cloudpickle_file_test.CloudPickleFileTests)
15810 ;; TypeError: cannot serialize '_io.BufferedRandom' object
15811 (arguments '(#:tests? #f))
15813 `(("python-pytest" ,python-pytest)
15814 ("python-mock" ,python-mock)
15815 ("python-tornado" ,python-tornado)))
15816 (home-page "https://github.com/cloudpipe/cloudpickle")
15817 (synopsis "Extended pickling support for Python objects")
15819 "Cloudpickle makes it possible to serialize Python constructs not
15820 supported by the default pickle module from the Python standard library. It
15821 is especially useful for cluster computing where Python expressions are
15822 shipped over the network to execute on remote hosts, possibly close to the
15824 (license license:bsd-3)))
15826 (define-public python2-cloudpickle
15827 (package-with-python2 python-cloudpickle))
15829 (define-public python-locket
15831 (name "python-locket")
15836 (uri (pypi-uri "locket" version))
15839 "1d4z2zngrpqkrfhnd4yhysh66kjn4mblys2l06sh5dix2p0n7vhz"))))
15840 (build-system python-build-system)
15841 (home-page "https://github.com/mwilliamson/locket.py")
15842 (synopsis "File-based locks for Python")
15844 "Locket implements a lock that can be used by multiple processes provided
15845 they use the same path.")
15846 (license license:bsd-2)))
15848 (define-public python2-locket
15849 (package-with-python2 python-locket))
15851 (define-public python-blosc
15853 (name "python-blosc")
15858 (uri (pypi-uri "blosc" version))
15861 "1cm91c6r431yla2mbs4895bgiianjf30dfz14vvv99dslygd65jw"))))
15862 (build-system python-build-system)
15863 ;; FIXME: all tests pass, but then this error is printed:
15864 ;; TypeError: calling <function run at 0x7ffff2568d90> returned None, not a test
15865 (arguments '(#:tests? #f))
15867 `(("python-numpy" ,python-numpy)))
15868 (home-page "https://github.com/blosc/python-blosc")
15869 (synopsis "Python wrapper for the Blosc data compressor library")
15870 (description "Blosc is a high performance compressor optimized for binary
15871 data. It has been designed to transmit data to the processor cache faster
15872 than the traditional, non-compressed, direct memory fetch approach via a
15873 @code{memcpy()} system call.
15875 Blosc works well for compressing numerical arrays that contains data with
15876 relatively low entropy, like sparse data, time series, grids with
15877 regular-spaced values, etc.
15879 This Python package wraps the Blosc library.")
15880 (license license:bsd-3)))
15882 (define-public python2-blosc
15883 (package-with-python2 python-blosc))
15885 (define-public python-partd
15887 (name "python-partd")
15892 (uri (pypi-uri "partd" version))
15895 "0sz6rwlnl4fqq220pyz863cnv0gjdxl4m7lscl71ishl5z0xkmhz"))))
15896 (build-system python-build-system)
15898 `(("python-blosc" ,python-blosc)
15899 ("python-locket" ,python-locket)
15900 ("python-numpy" ,python-numpy)
15901 ("python-pandas" ,python-pandas)
15902 ("python-pyzmq" ,python-pyzmq)
15903 ("python-toolz" ,python-toolz)))
15904 (home-page "https://github.com/dask/partd/")
15905 (synopsis "Appendable key-value storage")
15906 (description "Partd stores key-value pairs. Values are raw bytes. We
15907 append on old values. Partd excels at shuffling operations.")
15908 (license license:bsd-3)))
15910 (define-public python2-partd
15911 (package-with-python2 python-partd))
15913 (define-public python-fsspec
15915 (name "python-fsspec")
15920 (uri (pypi-uri "fsspec" version))
15923 "1g9ba8v04s1nrh7pvzfm2md7ivl2mrz3hcq3y9d1a44gd62h17zj"))))
15924 (build-system python-build-system)
15925 (arguments '(#:tests? #f)) ; there are none
15926 (home-page "https://github.com/intake/filesystem_spec")
15927 (synopsis "File-system specification")
15928 (description "The purpose of this package is to produce a template or
15929 specification for a file-system interface, that specific implementations
15930 should follow, so that applications making use of them can rely on a common
15931 behavior and not have to worry about the specific internal implementation
15932 decisions with any given backend.")
15933 (license license:bsd-3)))
15935 (define-public python-dask
15937 (name "python-dask")
15942 (uri (pypi-uri "dask" version))
15944 (base32 "1w1hqr8vyx6ygwflj2737dcy0mmgvrc0s602gnny8pzlcbs9m76b"))))
15945 (build-system python-build-system)
15948 (modify-phases %standard-phases
15949 (add-after 'unpack 'disable-broken-tests
15951 ;; This test is marked as xfail when pytest-xdist is used.
15952 (substitute* "dask/tests/test_threaded.py"
15953 (("def test_interrupt\\(\\)" m)
15954 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
15956 ;; This one fails with a type error:
15957 ;; TypeError: Already tz-aware, use tz_convert to convert.
15958 (substitute* "dask/dataframe/tests/test_shuffle.py"
15959 (("def test_set_index_timestamp\\(\\)" m)
15960 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
15964 (lambda _ (invoke "pytest" "-vv"))))))
15966 `(("python-cloudpickle" ,python-cloudpickle)
15967 ("python-fsspec" ,python-fsspec)
15968 ("python-numpy" ,python-numpy)
15969 ("python-packaging" ,python-packaging)
15970 ("python-pandas" ,python-pandas)
15971 ("python-partd" ,python-partd)
15972 ("python-toolz" ,python-toolz)
15973 ("python-pyyaml" ,python-pyyaml)))
15975 `(("python-pytest" ,python-pytest)
15976 ("python-pytest-runner" ,python-pytest-runner)))
15977 (home-page "https://github.com/dask/dask/")
15978 (synopsis "Parallel computing with task scheduling")
15980 "Dask is a flexible parallel computing library for analytics. It
15981 consists of two components: dynamic task scheduling optimized for computation,
15982 and large data collections like parallel arrays, dataframes, and lists that
15983 extend common interfaces like NumPy, Pandas, or Python iterators to
15984 larger-than-memory or distributed environments. These parallel collections
15985 run on top of the dynamic task schedulers. ")
15986 (license license:bsd-3)))
15988 (define-public python-ilinkedlist
15990 (name "python-ilinkedlist")
15995 (uri (pypi-uri "ilinkedlist" version))
15998 "0nrw4sr3afldrp7073hvc0rgdz282s0l819jdmj1i6nn05v33h0l"))))
15999 (build-system python-build-system)
16000 (native-inputs `(("python-pytest" ,python-pytest)))
16001 (inputs `(("python" ,python)))
16002 (home-page "https://github.com/luther9/ilinkedlist-py")
16003 (synopsis "Immutable linked list library")
16005 "This is a implementation of immutable linked lists for Python. It
16006 contains @code{nil} (the empty linked list) and a @code{Pair} class for nodes.
16007 Since a linked list is treated as immutable, it is hashable, and its length
16008 can be retrieved in constant time. Some of the terminology is inspired by
16009 LISP. It is possible to create an improper list by creating a @code{Pair}
16010 with a non-list @code{cdr}.")
16011 (license license:gpl3+)))
16013 (define-public python-readlike
16015 (name "python-readlike")
16020 (uri (pypi-uri "readlike" version))
16022 (base32 "027w8fvi50ksl57q0a7kb5zvmq8jxaawnviib1jdqw0p3igvm1j4"))))
16023 (build-system python-build-system)
16024 (home-page "https://github.com/jangler/readlike")
16025 (synopsis "GNU Readline-like line editing module")
16027 "This Python module provides line editing functions similar to the default
16028 Emacs-style ones of GNU Readline. Unlike the Python standard library's
16029 @code{readline} package, this one allows access to those capabilties in settings
16030 outside of a standard command-line interface. It is especially well-suited to
16031 interfacing with Urwid, due to a shared syntax for describing key inputs.
16033 Currently, all stateless Readline commands are implemented. Yanking and history
16034 are not supported.")
16035 (license license:expat)))
16037 (define-public python2-readlike
16038 (package-with-python2 python-readlike))
16040 (define-public python-reparser
16042 (name "python-reparser")
16047 (uri (pypi-uri "ReParser" version))
16049 (base32 "0nniqb69xr0fv7ydlmrr877wyyjb61nlayka7xr08vlxl9caz776"))))
16050 (build-system python-build-system)
16051 (home-page "https://github.com/xmikos/reparser")
16052 (synopsis "Simple lexer/parser for inline markup based on regular expressions")
16054 "This Python library provides a simple lexer/parser for inline markup based
16055 on regular expressions.")
16056 (license license:expat)))
16058 (define-public python2-reparser
16059 (let ((reparser (package-with-python2
16060 (strip-python2-variant python-reparser))))
16061 (package (inherit reparser)
16063 `(("python2-enum34" ,python2-enum34)
16064 ,@(package-propagated-inputs reparser))))))
16066 (define-public python-precis-i18n
16068 (name "python-precis-i18n")
16073 (uri (pypi-uri "precis_i18n" version))
16076 "0gjhvwd8aifx94rl1ag08vlmndyx2q3fkyqb0c4i46x3p2bc2yi2"))))
16077 (build-system python-build-system)
16078 (home-page "https://github.com/byllyfish/precis_i18n")
16079 (synopsis "Implementation of the PRECIS framework")
16081 "This module implements the PRECIS Framework as described in RFC 8264,
16082 RFC 8265 and RFC 8266.")
16083 (license license:expat)))
16085 (define-public python-absl-py
16087 (name "python-absl-py")
16092 (uri (pypi-uri "absl-py" version))
16095 "1mp9lk0b2qa37b7y6ak4lvf6ifw2ylyy6bkf9ik77md3j4xrwlc7"))))
16096 (build-system python-build-system)
16098 `(("python-six" ,python-six)))
16099 (home-page "https://github.com/abseil/abseil-py")
16100 (synopsis "Abseil Python common libraries")
16102 "This package provides the Abseil Python Common Libraries, a collection
16103 of Python libraries for building Python applications.")
16104 (license license:asl2.0)))
16106 (define-public python-astor
16108 (name "python-astor")
16113 (uri (pypi-uri "astor" version))
16116 "13gv6f2xz9i564byp21gcpc0l3w4cs23k1wbcam8kky2ls3hvhwm"))))
16117 (build-system python-build-system)
16118 ;; FIXME: There are two errors and two test failures.
16119 (arguments `(#:tests? #f))
16120 (home-page "https://github.com/berkerpeksag/astor")
16121 (synopsis "Read and write Python ASTs")
16122 (description "Astor is designed to allow easy manipulation of Python
16123 source via the Abstract Syntax Tree.")
16124 (license license:bsd-3)))
16126 (define-public python2-astor
16127 (package-with-python2 python-astor))
16129 (define-public python-grpcio
16131 (name "python-grpcio")
16136 (uri (pypi-uri "grpcio" version))
16139 "0qb9y6j83nxa6d4kc60i8yfgdm7a8ms7b54kncjzf5y7nsxp8rzx"))))
16140 (build-system python-build-system)
16142 `(("python-six" ,python-six)))
16143 (home-page "https://grpc.io")
16144 (synopsis "HTTP/2-based RPC framework")
16145 (description "This package provides a Python library for communicating
16146 with the HTTP/2-based RPC framework gRPC.")
16147 (license license:asl2.0)))
16149 (define-public python-astunparse
16151 (name "python-astunparse")
16156 (uri (pypi-uri "astunparse" version))
16158 (base32 "0rzbc44xcvzjhhiy7wac96mgal5mcjz1mfq8rmvgswskf4kf9cys"))))
16159 (build-system python-build-system)
16160 (arguments '(#:tests? #f)) ; there are none
16162 `(("python-six" ,python-six)
16163 ("python-wheel" ,python-wheel)))
16164 (home-page "https://github.com/simonpercivall/astunparse")
16165 (synopsis "AST unparser for Python")
16166 (description "This package provides an AST unparser for Python. It is a
16167 factored out version of @code{unparse} found in the Python source
16169 (license license:bsd-3)))
16171 (define-public python-gast
16173 (name "python-gast")
16178 (uri (pypi-uri "gast" version))
16180 (base32 "1w5dzdb3gpcfmd2s0b93d8gff40a1s41rv31458z14inb3s9v4zy"))))
16181 (build-system python-build-system)
16183 `(("python-astunparse" ,python-astunparse)))
16184 (home-page "https://pypi.org/project/gast/")
16185 (synopsis "Generic Python AST that abstracts the underlying Python version")
16187 "GAST provides a compatibility layer between the AST of various Python
16188 versions, as produced by @code{ast.parse} from the standard @code{ast}
16190 (license license:bsd-3)))
16192 (define-public python-wikidata
16194 (name "python-wikidata")
16199 (uri (pypi-uri "Wikidata" version))
16202 "08nlnydddfp1jj0cdmshvld1irzngbp3dij928wqsg9ziklm6mw9"))))
16203 (build-system python-build-system)
16205 `(("python-babel" ,python-babel)))
16206 (home-page "https://github.com/dahlia/wikidata")
16207 (synopsis "Wikidata client library")
16209 "This package provides a Python interface to
16210 @url{https://www.wikidata.org/, Wikidata}.")
16211 (properties '((upstream-name . "Wikidata")))
16212 (license license:gpl3+)))
16214 (define-public python-doctest-ignore-unicode
16216 (name "python-doctest-ignore-unicode")
16221 (uri (pypi-uri "doctest-ignore-unicode" version))
16224 "1m9aa4qnyj21lbq4sbvmv1vcz7zksss4rz37ddf2hxv4hk8b547w"))))
16225 (build-system python-build-system)
16227 `(("python-nose" ,python-nose)))
16228 (home-page "https://github.com/gnublade/doctest-ignore-unicode")
16229 (synopsis "Ignore Unicode literal prefixes in doctests")
16231 "This package adds support for a flag to ignore Unicode literal prefixes
16233 (license license:asl2.0)))
16235 (define-public python-attr
16237 (name "python-attr")
16242 (uri (pypi-uri "attr" version))
16245 "0pbpskvxp5hzdvcaf766ljwpckshir8sf7z6jqji6zyib20594ch"))))
16246 (build-system python-build-system)
16247 (home-page "https://github.com/denis-ryzhkov/attr")
16248 (synopsis "Decorator for attributes of target function or class")
16249 (description "Simple decorator to set attributes of target function or
16250 class in a @acronym{DRY, Don't Repeat Yourself} way.")
16251 (license license:expat)))
16253 (define-public python-construct
16255 (name "python-construct")
16260 (uri (pypi-uri "construct" version))
16263 "130iy05awzigm2xah2yvlmb08mac5bi4gzr5m3g7k1krs3ps0w92"))))
16264 (build-system python-build-system)
16266 `(#:tests? #f)) ; No tests exist.
16268 `(("python-extras" ,python-extras)
16269 ("python-arrow" ,python-arrow)
16270 ("python-numpy" ,python-numpy)
16271 ("python-ruamel.yaml" ,python-ruamel.yaml)))
16272 (home-page "http://construct.readthedocs.io")
16273 (synopsis "Declarative and symmetrical parser and builder for binary data")
16275 "This package provides both simple, atomic constructs (such as
16276 integers of various sizes), as well as composite ones which allow you
16277 form hierarchical and sequential structures of increasing complexity.
16278 It features bit and byte granularity, easy debugging and testing, an
16279 easy-to-extend subclass system, and lots of primitive constructs to
16280 make your work easier.")
16281 (license license:expat)))
16283 (define-public python-humanize
16285 (name "python-humanize")
16290 (uri (pypi-uri "humanize" version))
16293 "06dvhm3k8lf2rayn1gxbd46y0fy1db26m3h9vrq7rb1ib08mfgx4"))))
16295 '(#:tests? #f)) ; tests not in pypi archive
16296 (build-system python-build-system)
16297 (home-page "https://github.com/jmoiron/humanize")
16298 (synopsis "Print numerical information in a human-readable form")
16299 (description "This package provides a Python module that displays numbers
16300 and dates in \"human readable\" forms. For example, it would display
16301 \"12345591313\" as \"12.3 billion\".")
16302 (license license:expat)))
16304 (define-public python-txaio
16306 (name "python-txaio")
16311 (uri (pypi-uri "txaio" version))
16314 "1zmpdph6zddgrnkkcykh6qk5s46l7s5mzfqrh82m4b5iffn61qv7"))))
16315 (build-system python-build-system)
16317 `(("python-twisted" ,python-twisted)
16318 ("python-six" ,python-six)))
16319 (home-page "https://github.com/crossbario/txaio")
16320 (synopsis "Compatibility layer between Python asyncio and Twisted")
16321 (description "Txaio provides a compatibility layer between the Python
16322 @code{asyncio} module and @code{Twisted}.")
16323 (license license:expat)))
16325 (define-public python-toolshed
16327 (name "python-toolshed")
16332 (uri (pypi-uri "toolshed" version))
16335 "14zvz51gzf9i1i3d1sj363ba4rksl6lcf4lz1arl8hpqgcbir8r3"))))
16336 (build-system python-build-system)
16338 `(("python-nose" ,python-nose)))
16339 (home-page "https://github.com/brentp/toolshed/")
16340 (synopsis "Collection of modules and functions for working with data")
16341 (description "This is a collection of well-tested, simple modules and
16342 functions that aim to reduce boilerplate when working with data.")
16343 (license license:bsd-2)))
16345 (define-public python-annoy
16347 (name "python-annoy")
16352 (uri (pypi-uri "annoy" version))
16355 "1rxn6snn0r32r07g45hdjhh8aa1xzx6fjrm8g62d8vzp46z7rzrp"))))
16356 (build-system python-build-system)
16358 `(("python-nose" ,python-nose)))
16359 (home-page "https://github.com/spotify/annoy/")
16360 (synopsis "Approximate nearest neighbors library")
16362 "Annoy is a C++ library with Python bindings to search for points in
16363 space that are close to a given query point. It also creates large read-only
16364 file-based data structures that are @code{mmap}ped into memory so that many
16365 processes may share the same data.")
16366 (license license:asl2.0)))
16368 (define-public python-pylzma
16370 (name "python-pylzma")
16375 (uri (pypi-uri "pylzma" version))
16378 "074anvhyjgsv2iby2ql1ixfvjgmhnvcwjbdz8gk70xzkzcm1fx5q"))))
16379 (build-system python-build-system)
16380 (home-page "http://www.joachim-bauch.de/projects/pylzma/")
16381 (synopsis "Python bindings for the LZMA library by Igor Pavlov.")
16382 (description "This package provides Python bindings for the LZMA library
16384 (license license:lgpl2.1+)))
16386 (define-public python2-pylzma
16387 (package-with-python2 python-pylzma))
16389 (define-public python2-zeroconf
16391 (name "python2-zeroconf")
16393 ;; This is the last version that supports Python 2.x.
16398 (uri (pypi-uri "zeroconf" version))
16401 "0ykzg730n915qbrq9bn5pn06bv6rb5zawal4sqjyfnjjm66snkj3"))))
16402 (build-system python-build-system)
16404 `(#:python ,python-2
16406 (modify-phases %standard-phases
16407 (add-after 'unpack 'patch-requires
16408 (lambda* (#:key inputs #:allow-other-keys)
16409 (substitute* "setup.py"
16414 `(("python2-six" ,python2-six)
16415 ("python2-enum32" ,python2-enum34)
16416 ("python2-netifaces" ,python2-netifaces)
16417 ("python2-typing" ,python2-typing)))
16418 (home-page "https://github.com/jstasiak/python-zeroconf")
16419 (synopsis "Pure Python mDNS service discovery")
16421 "Pure Python multicast DNS (mDNS) service discovery library (Bonjour/Avahi
16423 (license license:lgpl2.1+)))
16425 (define-public python-bsddb3
16427 (name "python-bsddb3")
16432 (uri (pypi-uri "bsddb3" version))
16435 "019db2y6bfmiqbrgg9x9f6h72qjmqh05czdn2v5sy9bl0gs23mj2"))))
16436 (build-system python-build-system)
16441 (modify-phases %standard-phases
16442 (add-after 'unpack 'configure-locations
16443 (lambda* (#:key inputs #:allow-other-keys)
16444 (setenv "BERKELEYDB_DIR" (assoc-ref inputs "bdb"))
16445 (setenv "YES_I_HAVE_THE_RIGHT_TO_USE_THIS_BERKELEY_DB_VERSION" "1")
16449 (invoke "python3" "test3.py" "-v"))))))
16450 (home-page "https://www.jcea.es/programacion/pybsddb.htm")
16451 (synopsis "Python bindings for Oracle Berkeley DB")
16453 "This module provides a nearly complete wrapping of the Oracle/Sleepycat
16454 C API for the Database Environment, Database, Cursor, Log Cursor, Sequence and
16455 Transaction objects, and each of these is exposed as a Python type in the
16456 bsddb3.db module. The database objects can use various access methods: btree,
16457 hash, recno, and queue. Complete support of Berkeley DB distributed
16458 transactions. Complete support for Berkeley DB Replication Manager.
16459 Complete support for Berkeley DB Base Replication. Support for RPC.")
16460 (license license:bsd-3)))
16462 (define-public python-dbfread
16464 (name "python-dbfread")
16468 (uri (pypi-uri "dbfread" version))
16471 "0gdpwdzf1fngsi6jrdyj4qdf6cr7gnnr3zp80dpkzbgz0spskj07"))))
16472 (build-system python-build-system)
16474 `(("python-pytest" ,python-pytest)))
16475 (home-page "https://dbfread.readthedocs.io")
16476 (synopsis "Read DBF Files with Python")
16478 "This library reads DBF files and returns the data as native Python data
16479 types for further processing. It is primarily intended for batch jobs and
16481 (license license:expat)))
16483 (define-public python-cached-property
16485 (name "python-cached-property")
16490 (uri (pypi-uri "cached-property" version))
16493 "010m1bl380l2r3vwq24r5v14l6gwvgm9v0mqqjkjss552jgsa5wj"))))
16494 (build-system python-build-system)
16497 (modify-phases %standard-phases
16498 ;; https://github.com/pydanny/cached-property/issues/131
16499 ;; recent versions of freezegun break one test
16500 (add-after 'unpack 'disable-broken-test
16502 (substitute* "tests/test_cached_property.py"
16503 (("def test_threads_ttl_expiry\\(self\\)" m)
16504 (string-append "@unittest.skip(\"Disabled by Guix\")\n"
16508 `(("python-freezegun" ,python-freezegun)))
16510 "https://github.com/pydanny/cached-property")
16512 "Decorator for caching properties in classes")
16514 "This package provides a decorator which makes caching
16515 time-or-computationally-expensive properties quick and easy and works in Python
16517 (license license:bsd-3)))
16519 (define-public python-folium
16521 (name "python-folium")
16526 (uri (pypi-uri "folium" version))
16529 "0gcc267wxwxr57ry86pqpbiyfvl0g48hfvgy0f2mz9s58g87kgzd"))))
16530 (build-system python-build-system)
16532 `(("python-branca" ,python-branca)
16533 ("python-jinja2" ,python-jinja2)
16534 ("python-numpy" ,python-numpy)
16535 ("python-requests" ,python-requests)))
16537 `(("python-pytest" ,python-pytest)))
16538 (home-page "https://github.com/python-visualization/folium")
16539 (synopsis "Make beautiful maps with Leaflet.js & Python")
16540 (description "@code{folium} makes it easy to visualize data that’s been
16541 manipulated in Python on an interactive leaflet map. It enables both the
16542 binding of data to a map for @code{choropleth} visualizations as well as
16543 passing rich vector/raster/HTML visualizations as markers on the map.
16545 The library has a number of built-in tilesets from OpenStreetMap, Mapbox, and
16546 Stamen, and supports custom tilesets with Mapbox or Cloudmade API keys. It
16547 supports Image, Video, GeoJSON and TopoJSON overlays.")
16548 (license license:expat)))
16550 (define-public jube
16552 ;; This is a command-line tool, so no "python-" prefix.
16557 (uri (string-append
16558 "http://apps.fz-juelich.de/jsc/jube/jube2/download.php?version="
16562 "0xq4k1q63s1p6swgyp61vahlrd1fqmgbm0gm5kpj8ikwy0yc0nqk"))
16563 (file-name (string-append "jube-" version ".tar.gz"))))
16564 (build-system python-build-system)
16565 (home-page "https://apps.fz-juelich.de/jsc/jube/jube2/docu/index.html")
16566 (synopsis "Benchmarking environment")
16568 "JUBE helps perform and analyze benchmarks in a systematic way. For each
16569 benchmarked application, benchmark data is stored in a format that allows JUBE
16570 to deduct the desired information. This data can be parsed by automatic pre-
16571 and post-processing scripts that draw information and store it more densely
16572 for manual interpretation.")
16573 (license license:gpl3+)))
16575 (define-public python-pyroutelib3
16577 (name "python-pyroutelib3")
16578 (version "1.3.post1")
16582 (uri (pypi-uri "pyroutelib3" version))
16585 "1hpbydpn2alyswiajfbvhzq4c7f36vdmvxy91hgv8l1lb2g2vfrj"))))
16586 (build-system python-build-system)
16588 `(("python-dateutil" ,python-dateutil)))
16589 (home-page "https://github.com/MKuranowski/pyroutelib3")
16590 (synopsis "Library for simple routing on OSM data")
16591 (description "Library for simple routing on OSM data")
16592 (license license:gpl3+)))
16594 (define-public python-bibtexparser
16596 (name "python-bibtexparser")
16601 (uri (pypi-uri "bibtexparser" version))
16604 "0zwhfkrzf3n5847dbnfng92k7ak199l9v6x6ax3dgdidfpm6d2fz"))))
16605 (build-system python-build-system)
16607 `(("python-pyparsing" ,python-pyparsing)))
16609 `(("python-future" ,python-future)))
16610 (home-page "https://github.com/sciunto-org/python-bibtexparser")
16611 (synopsis "Python library to parse BibTeX files")
16612 (description "BibtexParser is a Python library to parse BibTeX files.")
16613 (license (list license:bsd-3 license:lgpl3))))
16615 (define-public python-distro
16617 (name "python-distro")
16622 (uri (pypi-uri "distro" version))
16625 "0mrg75w4ap7mdzyga75yaid9n8bgb345ih5mwjp3plj6v1jxwb9n"))))
16626 (build-system python-build-system)
16628 `(("python-pytest" ,python-pytest)))
16629 (home-page "https://github.com/nir0s/distro")
16631 "OS platform information API")
16633 "@code{distro} provides information about the OS distribution it runs on,
16634 such as a reliable machine-readable ID, or version information.
16636 It is the recommended replacement for Python's original
16637 `platform.linux_distribution` function (which will be removed in Python 3.8).
16638 @code{distro} also provides a command-line interface to output the platform
16639 information in various formats.")
16640 (license license:asl2.0)))
16642 (define-public python-cairosvg
16644 (name "python-cairosvg")
16649 (uri (pypi-uri "CairoSVG" version))
16651 (base32 "1bb7irxbaxxb9ahm3z5wsx1q96mm5gzskc7b6q07h9ikcnb8yrjf"))))
16652 (build-system python-build-system)
16655 (modify-phases %standard-phases
16657 (lambda _ (invoke "pytest"))))))
16659 `(("python-cairocffi" ,python-cairocffi)
16660 ("python-cssselect2" ,python-cssselect2)
16661 ("python-defusedxml" ,python-defusedxml)
16662 ("python-pillow" ,python-pillow)
16663 ("python-tinycss2" ,python-tinycss2)))
16665 `(("python-pytest-flake8" ,python-pytest-flake8)
16666 ("python-pytest-isort" ,python-pytest-isort)
16667 ("python-pytest-runner" ,python-pytest-runner)))
16668 (home-page "https://cairosvg.org/")
16669 (synopsis "SVG to PDF/PS/PNG converter based on Cairo")
16670 (description "CairoSVG is a SVG converter based on Cairo. It can export
16671 SVG files to PDF, PostScript and PNG files. The main part of CairoSVG is a
16672 SVG parser, trying to follow the SVG 1.1 recommendation from the W3C. Once
16673 parsed, the result is drawn to a Cairo surface that can be exported to
16674 qvarious formats: PDF, PostScript, PNG and even SVG.")
16675 (license license:lgpl3+)))
16677 (define-public python-pyphen
16679 (name "python-pyphen")
16684 (uri (pypi-uri "Pyphen" version))
16686 (base32 "08c9y69ry9d6m4zalhnalg86lsp9v2j5n1ziw5vxfmiihx83lqrv"))))
16687 (build-system python-build-system)
16688 ;; TODO: Use the Guix system hyphenation packages hyphen-* rather than the
16689 ;; embedded set provided by upstream - like Debian does.
16690 (home-page "https://github.com/Kozea/Pyphen")
16691 (synopsis "Pure Python module to hyphenate text")
16692 (description "Pyphen is a pure Python module to hyphenate text using
16693 existing Hunspell hyphenation dictionaries.")
16694 (license (list license:gpl2 license:lgpl2.1 license:mpl1.1))))
16696 (define-public python-intelhex
16698 (name "python-intelhex")
16703 (uri (pypi-uri "intelhex" version))
16706 "0ckqjbxd8gwcg98gfzpn4vq1qxzfvq3rdbrr1hikj1nmw08qb780"))))
16707 (build-system python-build-system)
16708 (arguments '(#:tests? #f)) ;issue with version
16709 (home-page "https://pypi.org/project/IntelHex/")
16710 (synopsis "Python library for Intel HEX files manipulations")
16711 (description "The Intel HEX file format is widely used in microprocessors
16712 and microcontrollers area (embedded systems etc.) as the de facto standard for
16713 representation of code to be programmed into microelectronic devices. This
16714 package provides an intelhex Python library to read, write, create from
16715 scratch and manipulate data from Intel HEX file format. It also includes
16716 several convenience Python scripts, including \"classic\" hex2bin and bin2hex
16717 converters and more, those based on the library itself.")
16718 (license license:bsd-3)))
16720 (define-public python-pykwalify
16722 (name "python-pykwalify")
16727 (uri (pypi-uri "pykwalify" version))
16730 "1cnfzkg1b01f825ikpw2fhjclf9c8akxjfrbd1vc22x1lg2kk2vy"))))
16731 (build-system python-build-system)
16732 (arguments '(#:tests? #f)) ;missing dependencies
16734 `(("python-dateutil" ,python-dateutil)
16735 ("python-docopt" ,python-docopt)
16736 ("python-pyyaml" ,python-pyyaml)))
16737 (home-page "https://github.com/grokzen/pykwalify")
16739 "Python lib/cli for JSON/YAML schema validation")
16741 "This package provides a parser, schema validator, and data binding tool
16742 for YAML and JSON.")
16743 (license license:expat)))
16745 (define-public python-dbusmock
16747 (name "python-dbusmock")
16752 (uri (pypi-uri "python-dbusmock" version))
16755 "0hp2kyac88nh9iv6l8hlmv7s1sa1s5f1a3wc2pmlmmxnd211fjlr"))))
16756 (build-system python-build-system)
16759 (modify-phases %standard-phases
16760 (add-after 'unpack 'patch-shell-path
16762 (substitute* "tests/test_code.py"
16763 (("/bin/bash") (which "bash")))
16767 ("dbus" ,dbus) ; for dbus-daemon
16768 ("python-nose" ,python-nose)
16771 `(("python-dbus" ,python-dbus)
16772 ("python-pygobject" ,python-pygobject)))
16773 (home-page "https://github.com/martinpitt/python-dbusmock")
16774 (synopsis "Python library for mock D-Bus objects")
16775 (description "python-dbusmock allows for the easy creation of mock objects on
16776 D-Bus. This is useful for writing tests for software which talks to D-Bus
16777 services such as upower, systemd, logind, gnome-session or others, and it is
16778 hard (or impossible without root privileges) to set the state of the real
16779 services to what you expect in your tests.")
16780 (license license:lgpl3+)))
16782 (define-public python-ujson
16784 (name "python-ujson")
16789 (uri (pypi-uri "ujson" version))
16792 "11jz5wi7mbgqcsz52iqhpyykiaasila4lq8cmc2d54bfa3jp6q7n"))))
16793 (build-system python-build-system)
16794 (home-page "http://www.esn.me")
16796 "Ultra fast JSON encoder and decoder for Python")
16798 "UltraJSON is an ultra fast JSON encoder and decoder written in pure C with
16799 bindings for Python 2.5+ and 3.")
16800 (license license:bsd-3)))
16802 (define-public python2-ujson
16803 (package-with-python2 python-ujson))
16805 (define-public python-iocapture
16806 ;; The latest release is more than a year older than this commit.
16807 (let ((commit "fdc021c431d0840303908dfc3ca8769db383595c")
16810 (name "python-iocapture")
16815 (uri (git-reference
16816 (url "https://github.com/oinume/iocapture.git")
16818 (file-name (git-file-name name version))
16821 "1mkbhqibxvgwg0p7slr8dfraa3g2s6bsayladhax2jccwj4kcndz"))))
16822 (build-system python-build-system)
16825 (modify-phases %standard-phases
16827 (add-after 'install 'check
16828 (lambda* (#:key inputs outputs #:allow-other-keys)
16829 (add-installed-pythonpath inputs outputs)
16830 (invoke "py.test" "-v" "tests")
16833 `(("python-flexmock" ,python-flexmock)
16834 ("python-pytest" ,python-pytest)
16835 ("python-pytest-cov" ,python-pytest-cov)
16836 ("python-six" ,python-six)))
16837 (home-page "https://github.com/oinume/iocapture")
16838 (synopsis "Python capturing tool for stdout and stderr")
16840 "This package helps you to capture the standard out (stdout) and the
16841 standard error channel (stderr) in your program.")
16842 (license license:expat))))
16844 (define-public python-argh
16845 ;; There are 21 commits since the latest release containing important
16847 (let ((commit "dcd3253f2994400a6a58a700c118c53765bc50a4")
16850 (name "python-argh")
16851 (version (git-version "0.26.2" revision commit))
16855 (uri (git-reference
16856 (url "https://github.com/neithere/argh.git")
16858 (file-name (git-file-name name version))
16861 "1p5h3dnpbsjmqrvil96s71asc6i3gpinmbrabqmwnrsxprz7r3ns"))))
16862 (build-system python-build-system)
16864 `(("python-iocapture" ,python-iocapture)
16865 ("python-mock" ,python-mock)
16866 ("python-pytest" ,python-pytest)
16867 ("python-pytest-cov" ,python-pytest-cov)
16868 ("python-pytest-xdist" ,python-pytest-xdist)
16869 ("python-tox" ,python-tox)))
16870 (home-page "https://github.com/neithere/argh/")
16871 (synopsis "Argparse wrapper with natural syntax")
16873 "python-argh is a small library that provides several layers of
16874 abstraction on top of @code{python-argparse}. The layers can be mixed. It is
16875 always possible to declare a command with the highest possible (and least
16876 flexible) layer and then tune the behaviour with any of the lower layers
16877 including the native API of @code{python-argparse}.")
16878 (license license:lgpl3+))))
16880 (define-public python-ppft
16882 (name "python-ppft")
16883 (version "1.6.6.1")
16887 (uri (pypi-uri "ppft" version))
16890 "1z1invkhszc5d2mvgr221v7cszzifcc77mz0pv3wjp6x5q2768cy"))))
16891 (build-system python-build-system)
16892 (arguments '(#:tests? #f)) ; there are none
16894 `(("python-six" ,python-six)))
16895 (home-page "https://pypi.org/project/ppft/")
16896 (synopsis "Fork of Parallel Python")
16898 "This package is a fork of Parallel Python. The Parallel Python
16899 module (@code{pp}) provides an easy and efficient way to create
16900 parallel-enabled applications for @dfn{symmetric multiprocessing} (SMP)
16901 computers and clusters. It features cross-platform portability and dynamic
16903 (license license:bsd-3)))
16905 (define-public python-pox
16907 (name "python-pox")
16912 (uri (pypi-uri "pox" version))
16915 "0y17ckc2p6i6709s279sjdj4q459mpcc38ymg9zv9y6vl6jf3bq6"))))
16916 (build-system python-build-system)
16919 (modify-phases %standard-phases
16922 (mkdir-p "/tmp/guix")
16923 (setenv "SHELL" "bash")
16924 (setenv "USERNAME" "guix")
16925 (setenv "HOME" "/tmp/guix") ; must end on USERNAME...
16926 (invoke "py.test" "-vv")
16929 `(("python-pytest" ,python-pytest)
16931 (home-page "https://pypi.org/project/pox/")
16932 (synopsis "Python utilities for filesystem exploration and automated builds")
16934 "Pox provides a collection of utilities for navigating and manipulating
16935 filesystems. This module is designed to facilitate some of the low level
16936 operating system interactions that are useful when exploring a filesystem on a
16937 remote host. Pox provides Python equivalents of several shell commands such
16938 as @command{which} and @command{find}. These commands allow automated
16939 discovery of what has been installed on an operating system, and where the
16940 essential tools are located.")
16941 (license license:bsd-3)))
16943 (define-public python-pathos
16945 (name "python-pathos")
16950 (uri (pypi-uri "pathos" version))
16953 "0in8hxdz7k081ijn6q94gr39ycy7363sx4zysmbwyvd7snqjrbi1"))))
16954 (build-system python-build-system)
16957 (modify-phases %standard-phases
16960 (setenv "PYTHONPATH"
16961 (string-append (getcwd) ":" (getenv "PYTHONPATH")))
16962 (invoke "python" "./tests/__main__.py"))))))
16964 `(("python-dill" ,python-dill)
16965 ("python-multiprocess" ,python-multiprocess)
16966 ("python-pox" ,python-pox)
16967 ("python-ppft" ,python-ppft)))
16969 `(("python-pytest" ,python-pytest)))
16970 (home-page "https://pypi.org/project/pathos/")
16972 "Parallel graph management and execution in heterogeneous computing")
16974 "Python-pathos is a framework for heterogenous computing. It provides a
16975 consistent high-level interface for configuring and launching parallel
16976 computations across heterogenous resources. Python-pathos provides configurable
16977 launchers for parallel and distributed computing, where each launcher contains
16978 the syntactic logic to configure and launch jobs in an execution environment.")
16979 (license license:bsd-3)))
16981 (define-public python-flit
16983 (name "python-flit")
16988 (uri (pypi-uri "flit" version))
16991 "0h5vvmqinqzn97mr3ix7zx53af9ad4fimjjwqpx88yp8qhz4r5bc"))))
16992 (build-system python-build-system)
16994 `(#:tests? #f)) ; XXX: Check requires network access.
16995 (home-page "https://flit.readthedocs.io/")
16997 "Simple packaging tool for simple packages")
16999 "Flit is a simple way to put Python packages and modules on PyPI. Flit
17000 packages a single importable module or package at a time, using the import
17001 name as the name on PyPI. All subpackages and data files within a package
17002 are included automatically.")
17003 (license license:bsd-3)))
17005 (define-public python-pathtools
17007 (name "python-pathtools")
17012 (uri (pypi-uri "pathtools" version))
17015 "1h7iam33vwxk8bvslfj4qlsdprdnwf8bvzhqh3jq5frr391cadbw"))))
17016 (build-system python-build-system)
17018 "https://github.com/gorakhargosh/pathtools")
17019 (synopsis "Path utilities for Python")
17020 (description "Pattern matching and various utilities for file systems
17022 (license license:expat)))
17024 (define-public python-fastentrypoints
17026 (name "python-fastentrypoints")
17031 (uri (pypi-uri "fastentrypoints" version))
17034 "02s1j8i2dzbpbwgq2a3fiqwm3cnmhii2qzc0k42l0rdxd4a4ya7z"))))
17035 (build-system python-build-system)
17037 "https://github.com/ninjaaron/fast-entry_points")
17039 "Makes entry_points specified in setup.py load more quickly")
17041 "Using entry_points in your setup.py makes scripts that start really
17042 slowly because it imports pkg_resources. This package allows such setup
17043 scripts to load entry points more quickly.")
17044 (license license:bsd-3)))
17046 (define-public python-funcparserlib
17048 (name "python-funcparserlib")
17053 (uri (pypi-uri "funcparserlib" version))
17056 "07f9cgjr3h4j2m67fhwapn8fja87vazl58zsj4yppf9y3an2x6dp"))))
17058 `(("python-tox" ,python-tox)))
17061 (modify-phases %standard-phases
17064 (invoke "tox"))))))
17065 (build-system python-build-system)
17067 "https://github.com/vlasovskikh/funcparserlib")
17069 "Recursive descent parsing library based on functional combinators")
17071 "This package is a recursive descent parsing library for Python based on
17072 functional combinators. Parser combinators are just higher-order functions
17073 that take parsers as their arguments and return them as result values.")
17074 (license license:expat)))
17076 (define-public python-speg
17078 (name "python-speg")
17083 (uri (pypi-uri "speg" version ".zip"))
17085 (base32 "0w9y4jf4787dzhy6rvhwi0mpl0r8qkqmqmyv2hpwdpv8w53yzjqh"))))
17087 `(#:tests? #f)) ;FIXME: tests fail, not sure why
17089 `(("unzip" ,unzip)))
17090 (build-system python-build-system)
17091 (home-page "https://github.com/avakar/speg")
17092 (synopsis "PEG-based parser interpreter with memoization")
17093 (description "This package is a PEG-based parser and interpreter with
17095 (license license:expat)))
17097 (define-public python-cson
17099 (name "python-cson")
17104 (uri (pypi-uri "cson" version))
17106 (base32 "00cyvigg4npbph39ghkg77xbxisa6plf75vii24igxfizik0337f"))))
17107 (build-system python-build-system)
17109 `(("python-speg" ,python-speg)))
17110 (home-page "https://github.com/avakar/pycson")
17111 (synopsis "Parser for Coffeescript Object Notation (CSON)")
17112 (description "This package is a parser for Coffeescript Object
17114 (license license:expat)))