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 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 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 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 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 Nils Gillmann <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 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 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 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 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 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 Brendan Tildesley <brendan.tildesley@openmailbox.org>
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 Nicolas Goaziou <mail@nicolasgoaziou.fr>
55 ;;; Copyright © 2018 Oleg Pykhalov <go.wigust@gmail.com>
56 ;;; Copyright © 2018 Clément Lassieur <clement@lassieur.org>
57 ;;; Copyright © 2018 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 Brett Gilio <brettg@posteo.net>
62 ;;; This file is part of GNU Guix.
64 ;;; GNU Guix is free software; you can redistribute it and/or modify it
65 ;;; under the terms of the GNU General Public License as published by
66 ;;; the Free Software Foundation; either version 3 of the License, or (at
67 ;;; your option) any later version.
69 ;;; GNU Guix is distributed in the hope that it will be useful, but
70 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
71 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
72 ;;; GNU General Public License for more details.
74 ;;; You should have received a copy of the GNU General Public License
75 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
77 (define-module (gnu packages python-xyz)
78 #:use-module ((guix licenses) #:prefix license:)
79 #:use-module (gnu packages)
80 #:use-module (gnu packages algebra)
81 #:use-module (gnu packages adns)
82 #:use-module (gnu packages attr)
83 #:use-module (gnu packages backup)
84 #:use-module (gnu packages bash)
85 #:use-module (gnu packages check)
86 #:use-module (gnu packages compression)
87 #:use-module (gnu packages crypto)
88 #:use-module (gnu packages databases)
89 #:use-module (gnu packages file)
90 #:use-module (gnu packages fontutils)
91 #:use-module (gnu packages gcc)
92 #:use-module (gnu packages geo)
93 #:use-module (gnu packages ghostscript)
94 #:use-module (gnu packages gl)
95 #:use-module (gnu packages glib)
96 #:use-module (gnu packages graphviz)
97 #:use-module (gnu packages graphics)
98 #:use-module (gnu packages gstreamer)
99 #:use-module (gnu packages gtk)
100 #:use-module (gnu packages icu4c)
101 #:use-module (gnu packages image)
102 #:use-module (gnu packages imagemagick)
103 #:use-module (gnu packages libevent)
104 #:use-module (gnu packages libffi)
105 #:use-module (gnu packages linux)
106 #:use-module (gnu packages llvm)
107 #:use-module (gnu packages man)
108 #:use-module (gnu packages maths)
109 #:use-module (gnu packages monitoring)
110 #:use-module (gnu packages multiprecision)
111 #:use-module (gnu packages networking)
112 #:use-module (gnu packages ncurses)
113 #:use-module (gnu packages openstack)
114 #:use-module (gnu packages pcre)
115 #:use-module (gnu packages perl)
116 #:use-module (gnu packages pkg-config)
117 #:use-module (gnu packages python)
118 #:use-module (gnu packages python-check)
119 #:use-module (gnu packages python-crypto)
120 #:use-module (gnu packages python-web)
121 #:use-module (gnu packages qt)
122 #:use-module (gnu packages readline)
123 #:use-module (gnu packages sdl)
124 #:use-module (gnu packages search)
125 #:use-module (gnu packages shells)
126 #:use-module (gnu packages ssh)
127 #:use-module (gnu packages terminals)
128 #:use-module (gnu packages tex)
129 #:use-module (gnu packages texinfo)
130 #:use-module (gnu packages time)
131 #:use-module (gnu packages tls)
132 #:use-module (gnu packages version-control)
133 #:use-module (gnu packages video)
134 #:use-module (gnu packages web)
135 #:use-module (gnu packages base)
136 #:use-module (gnu packages xml)
137 #:use-module (gnu packages xorg)
138 #:use-module (gnu packages xdisorg)
139 #:use-module (gnu packages tcl)
140 #:use-module (gnu packages bdw-gc)
141 #:use-module (guix packages)
142 #:use-module (guix download)
143 #:use-module (guix git-download)
144 #:use-module (guix utils)
145 #:use-module (guix build-system gnu)
146 #:use-module (guix build-system cmake)
147 #:use-module (guix build-system python)
148 #:use-module (guix build-system trivial)
149 #:use-module (srfi srfi-1)
150 #:use-module (srfi srfi-26))
152 (define-public python-psutil
154 (name "python-psutil")
159 (uri (pypi-uri "psutil" version))
162 "063v69x7spyclyaxrd3gmzj3p16q5ayg97xqhwb1kyn22a9pwip2"))))
163 (build-system python-build-system)
165 ;; FIXME: some tests does not return and times out.
167 (home-page "https://www.github.com/giampaolo/psutil")
168 (synopsis "Library for retrieving information on running processes")
170 "psutil (Python system and process utilities) is a library for retrieving
171 information on running processes and system utilization (CPU, memory, disks,
172 network) in Python. It is useful mainly for system monitoring, profiling and
173 limiting process resources and management of running processes. It implements
174 many functionalities offered by command line tools such as: ps, top, lsof,
175 netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
176 pidof, tty, taskset, pmap.")
177 (properties `((python2-variant . ,(delay python2-psutil))))
178 (license license:bsd-3)))
180 (define-public python2-psutil
181 (let ((base (package-with-python2 (strip-python2-variant python-psutil))))
185 `(("python2-enum34" ,python2-enum34) ;optional
186 ,@(package-propagated-inputs base))))))
188 (define-public python-shapely
190 (name "python-shapely")
195 (uri (pypi-uri "Shapely" version))
198 "0svc58dzcw9gj92b4sgq35sdxkf85z0qwlzxarkzq4bp3h8jy58l"))))
199 (build-system python-build-system)
201 `(("python-cython" ,python-cython)
202 ("python-matplotlib" ,python-matplotlib)
203 ("python-pytest" ,python-pytest)
204 ("python-pytest-cov" ,python-pytest-cov)))
208 `(("python-numpy" ,python-numpy)))
211 (modify-phases %standard-phases
212 (add-after 'unpack 'patch-geos-path
213 (lambda* (#:key inputs #:allow-other-keys)
214 (let ((geos (assoc-ref inputs "geos"))
215 (glibc (assoc-ref inputs ,(if (%current-target-system)
216 "cross-libc" "libc"))))
217 (substitute* "shapely/geos.py"
218 (("_lgeos = load_dll\\('geos_c', fallbacks=.*\\)")
219 (string-append "_lgeos = load_dll('geos_c', fallbacks=['"
220 geos "/lib/libgeos_c.so'])"))
221 (("free = load_dll\\('c'\\)\\.free")
222 (string-append "free = load_dll('c', fallbacks=['"
223 glibc "/lib/libc.so.6']).free"))))
225 (home-page "https://github.com/Toblerity/Shapely")
226 (synopsis "Library for the manipulation and analysis of geometric objects")
227 (description "Shapely is a Python package for manipulation and analysis of
228 planar geometric objects. It is based on the @code{GEOS} library.")
229 (license license:bsd-3)))
231 (define-public python-logwrap
233 (name "python-logwrap")
238 (uri (pypi-uri "logwrap" version ".zip"))
241 "1d2k0hvpbi51vl410y8fbs5m0nxnlh2k7gr2nrh3k81ibhzscsra"))))
242 (build-system python-build-system)
244 `(("python-six" ,python-six)
245 ("python-typing" ,python-typing)))
248 ("python-cython" ,python-cython)
249 ("python-pytest" ,python-pytest)
250 ("python-pytest-cov" ,python-pytest-cov)
251 ("python-pytest-runner" ,python-pytest-runner)))
252 (home-page "https://github.com/penguinolog/logwrap")
253 (synopsis "Decorator for logging function arguments")
254 (description "This package provides a decorator to log function arguments
255 and function call return values in a human-readable way.")
256 (license license:asl2.0)))
258 (define-public python2-shapely
259 (package-with-python2 python-shapely))
261 (define-public python-clyent
263 (name "python-clyent")
268 (uri (pypi-uri "clyent" version))
271 "1r9987qmy1pz3hq54160bapqsywpq14waw4w9x3ly8hmq7kpgfbj"))))
272 (build-system python-build-system)
274 `(("python-mock" ,python-mock)))
275 (home-page "https://github.com/binstar/clyent")
276 (synopsis "Command line client library")
277 (description "Clyent is a Python command line utiliy library. It is used
278 by @code{binstar}, @code{binstar-build} and @code{chalmers}.")
279 (license license:bsd-3)))
281 (define-public python2-clyent
282 (package-with-python2 python-clyent))
284 (define-public python-babel
286 (name "python-babel")
291 (uri (pypi-uri "Babel" version))
294 "08rxmbx2s4irp0w0gmn498vns5xy0fagm0fg33xa772jiks51flc"))))
295 (build-system python-build-system)
297 `(("python-freezegun" ,python-freezegun)
298 ("python-pytest" ,python-pytest)))
300 `(("python-pytz" ,python-pytz)))
302 `(#:phases (modify-phases %standard-phases
304 (lambda _ (invoke "pytest" "-vv"))))))
305 (home-page "http://babel.pocoo.org/")
307 "Tools for internationalizing Python applications")
309 "Babel is composed of two major parts:
310 - tools to build and work with gettext message catalogs
311 - a Python interface to the CLDR (Common Locale Data Repository), providing
312 access to various locale display names, localized number and date formatting,
314 (license license:bsd-3)))
316 (define-public python2-babel
317 (package-with-python2 python-babel))
319 (define-public python2-backport-ssl-match-hostname
321 (name "python2-backport-ssl-match-hostname")
326 (uri (pypi-uri "backports.ssl_match_hostname" version))
329 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
330 (build-system python-build-system)
333 #:tests? #f)) ; no test target
334 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
335 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
337 "This backport brings the ssl.match_hostname() function to users of
338 earlier versions of Python. The function checks the hostname in the
339 certificate returned by the server to which a connection has been established,
340 and verifies that it matches the intended target hostname.")
341 (license license:psfl)))
343 (define-public python-hdf4
350 (uri (pypi-uri name version))
353 "1hjiyrxvxk9817qyqky3nar4y3fs4z8wxz0n884zzb5wi6skrjks"))))
354 (build-system python-build-system)
355 (native-inputs `(("nose" ,python-nose)))
356 (propagated-inputs `(("numpy" ,python-numpy)))
363 (modify-phases %standard-phases
366 ;; The 'runexamples' script sets PYTHONPATH to CWD, then goes
367 ;; on to import numpy. Somehow this works on their CI system.
368 ;; Let's just manage PYTHONPATH here instead.
369 (substitute* "runexamples.sh"
370 (("export PYTHONPATH=.*") ""))
372 (string-append (getcwd) ":"
373 (getenv "PYTHONPATH")))
374 (invoke "./runexamples.sh")
375 (invoke "nosetests" "-v"))))))
376 (home-page "https://github.com/fhs/python-hdf4")
377 (synopsis "Python interface to the NCSA HDF4 library")
379 "Python-HDF4 is a python wrapper around the NCSA HDF version 4 library,
380 which implements the SD (Scientific Dataset), VS (Vdata) and V (Vgroup) API’s.
381 NetCDF files can also be read and modified. Python-HDF4 is a fork of
382 @url{http://hdfeos.org/software/pyhdf.php,pyhdf}.")
383 (license license:expat)))
385 (define-public python2-hdf4
386 (package-with-python2 python-hdf4))
388 (define-public python-h5py
395 (uri (pypi-uri "h5py" version))
398 "0mdr6wrq02ac93m1aqx9kad0ppfzmm4imlxqgyy1x4l7hmdcc9p6"))))
399 (build-system python-build-system)
401 `(#:tests? #f ; no test target
403 (modify-phases %standard-phases
404 (add-after 'unpack 'fix-hdf5-paths
405 (lambda* (#:key inputs #:allow-other-keys)
406 (let ((prefix (assoc-ref inputs "hdf5")))
407 (substitute* "setup_build.py"
408 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
409 (string-append "['" prefix "/lib" "']"))
410 (("'/opt/local/include', '/usr/local/include'")
411 (string-append "'" prefix "/include" "'")))
412 (substitute* "setup_configure.py"
413 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
414 (string-append "['" prefix "/lib" "']")))
417 `(("python-six" ,python-six)
418 ("python-numpy" ,python-numpy)))
422 `(("python-cython" ,python-cython)
423 ("python-pkgconfig" ,python-pkgconfig)))
424 (home-page "http://www.h5py.org/")
425 (synopsis "Read and write HDF5 files from Python")
427 "The h5py package provides both a high- and low-level interface to the
428 HDF5 library from Python. The low-level interface is intended to be a
429 complete wrapping of the HDF5 API, while the high-level component supports
430 access to HDF5 files, datasets and groups using established Python and NumPy
432 (license license:bsd-3)))
434 (define-public python2-h5py
435 (package-with-python2 python-h5py))
437 (define-public python-sh
444 (uri (pypi-uri "sh" version))
447 "1z2hx357xp3v4cv44xmqp7lli3frndqpyfmpbxf7n76h7s1zaaxm"))))
448 (build-system python-build-system)
451 (modify-phases %standard-phases
454 (invoke "python" "sh.py" "test"))))))
456 `(("python-coverage" ,python-coverage)))
457 (home-page "https://github.com/amoffat/sh")
458 (synopsis "Python subprocess replacement")
459 (description "This package provides a replacement for Python's
460 @code{subprocess} feature.")
461 (license license:expat)))
463 (define-public python2-sh
464 (package-with-python2 python-sh))
466 (define-public python-cftime
468 (name "python-cftime")
473 (uri (pypi-uri "cftime" version))
476 "0362dhxbzk593walyjz30dll6y2y79wialik647cbwdsf3ad0x6x"))))
477 (build-system python-build-system)
479 `(("python-numpy" ,python-numpy)))
481 `(("python-coveralls" ,python-coveralls)
482 ("python-cython" ,python-cython)
483 ("python-pytest-cov" ,python-pytest-cov)))
484 (home-page "https://github.com/Unidata/cftime")
485 (synopsis "Library for time handling")
487 "This package provides time-handling functionality that used to be part
488 of the netcdf4 package before.")
489 ;; This package claims to include code under the GPLv3 but is released
491 (license (list license:isc license:gpl3+))))
493 (define-public python-netcdf4
495 (name "python-netcdf4")
500 (uri (pypi-uri "netCDF4" version))
503 "0c0sklgrmv15ygliin8qq0hp7vanmbi74m6zpi0r1ksr0hssyd5r"))))
504 (build-system python-build-system)
507 (modify-phases %standard-phases
508 (add-after 'unpack 'configure-locations
509 (lambda* (#:key inputs #:allow-other-keys)
510 (setenv "HDF5_DIR" (assoc-ref inputs "hdf5"))
513 `(("python-cython" ,python-cython)))
515 `(("python-numpy" ,python-numpy)
516 ("python-cftime" ,python-cftime)))
521 (home-page "https://github.com/Unidata/netcdf4-python")
522 (synopsis "Python/numpy interface to the netCDF library")
523 (description "Netcdf4-python is a Python interface to the netCDF C
524 library. netCDF version 4 has many features not found in earlier
525 versions of the library and is implemented on top of HDF5. This module
526 can read and write files in both the new netCDF 4 and the old netCDF 3
527 format, and can create files that are readable by HDF5 clients. The
528 API is modelled after @code{Scientific.IO.NetCDF}, and should be familiar
529 to users of that module.")
530 ;; The software is mainly ISC, but includes some files covered
531 ;; by the Expat license.
532 (license (list license:isc license:expat))))
534 (define-public python2-netcdf4
535 (package-with-python2 python-netcdf4))
537 (define-public python-lockfile
539 (name "python-lockfile")
544 (uri (pypi-uri "lockfile" version))
547 "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba"))))
548 (build-system python-build-system)
549 (arguments '(#:test-target "check"))
551 `(("python-pbr" ,python-pbr)))
552 (home-page "https://launchpad.net/pylockfile")
553 (synopsis "Platform-independent file locking module")
555 "The lockfile package exports a LockFile class which provides a simple
556 API for locking files.")
557 (license license:expat)))
559 (define-public python2-lockfile
560 (package-with-python2 python-lockfile))
562 (define-public python-semantic-version
564 (name "python-semantic-version")
569 (uri (pypi-uri "semantic_version" version))
572 "1h2l9xyg1zzsda6kjcmfcgycbvrafwci283vcr1v5sbk01l2hhra"))))
573 (build-system python-build-system)
575 `(#:tests? #f)) ; PyPI tarball lacks tests
576 (home-page "https://github.com/rbarrois/python-semanticversion")
577 (synopsis "Semantic versioning module for Python")
579 "The @code{semantic_version} class is a small library for handling
580 @uref{https://semver.org/, semantic versioning} (@dfn{SemVer}) in Python.
582 It can compare versions, generate a new version that represents a bump in one of
583 the version levels, and check whether any given string is a proper semantic
584 version identifier.")
585 (license license:bsd-3)))
587 (define-public python2-semantic-version
588 (package-with-python2 python-semantic-version))
590 (define-public python-serpent
592 (name "python-serpent")
597 (uri (pypi-uri "serpent" version))
600 "04p9dsrm5pv8vhk3flvih55kgvlzpi38hlaykdiakddmgwqw93bg"))))
601 (build-system python-build-system)
602 (home-page "https://github.com/irmen/Serpent")
603 (synopsis "Serializer for literal Python expressions")
605 "Serpent provides ast.literal_eval() compatible object tree
606 serialization. It serializes an object tree into bytes (utf-8 encoded string)
607 that can be decoded and then passed as-is to ast.literal_eval() to rebuild it
608 as the original object tree. As such it is safe to send serpent data to other
609 machines over the network for instance (because only safe literals are
611 (license license:expat)))
613 (define-public python-setuptools
615 (name "python-setuptools")
620 (uri (pypi-uri "setuptools" version ".zip"))
623 "0pq116lr14gnc62v76nk0npkm6krb2mpp7p9ab369zgv4n7dnah1"))
624 (modules '((guix build utils)))
627 ;; Remove included binaries which are used to build self-extracting
628 ;; installers for Windows.
629 ;; TODO: Find some way to build them ourself so we can include them.
630 (for-each delete-file (find-files "setuptools" "^(cli|gui).*\\.exe$"))
632 (build-system python-build-system)
633 ;; FIXME: Tests require pytest, which itself relies on setuptools.
634 ;; One could bootstrap with an internal untested setuptools.
637 (home-page "https://pypi.python.org/pypi/setuptools")
639 "Library designed to facilitate packaging Python projects")
641 "Setuptools is a fully-featured, stable library designed to facilitate
642 packaging Python projects, where packaging includes:
643 Python package and module definitions,
644 distribution package metadata,
646 project installation,
647 platform-specific details,
649 ;; TODO: setuptools now bundles the following libraries:
650 ;; packaging, pyparsing, six and appdirs. How to unbundle?
651 (license (list license:psfl ; setuptools itself
652 license:expat ; six, appdirs, pyparsing
653 license:asl2.0 ; packaging is dual ASL2/BSD-2
656 (define-public python2-setuptools
657 (package-with-python2 python-setuptools))
659 (define-public python-uniseg
661 (name "python-uniseg")
666 (uri (pypi-uri "uniseg" version ".zip"))
669 "05jsazvz6nbmh6l3v1rph5ydkqn1hzx1pyggdyvgp2qgmgrnmiz2"))))
670 (build-system python-build-system)
672 '(#:tests? #f)) ; The test suite requires network access.
676 "https://bitbucket.org/emptypage/uniseg-python")
678 "Python library to determine Unicode text segmentations")
680 "Uniseg is a Python package used to determine Unicode text segmentations.
681 Supported segmentations include:
683 @item @dfn{Code point} (any value in the Unicode codespace)
684 @item @dfn{Grapheme cluster} (user-perceived character made of a single or
685 multiple Unicode code points, e.g. \"G\" + acute-accent)
690 (license license:expat)))
692 (define-public python2-uniseg
693 (package-with-python2 python-uniseg))
695 (define-public python-humanfriendly
697 (name "python-humanfriendly")
702 (uri (pypi-uri "humanfriendly" version))
705 "0pisgizjql86785jchfjv217g0lsgk114g2lja5j4y3lsc3b9szi"))))
706 (build-system python-build-system)
708 `(;; XXX: Tests depend on coloredlogs, which in turn depends on humanfriendly.
711 `(("python-monotonic" ,python-monotonic)))
712 (home-page "https://humanfriendly.readthedocs.io")
713 (synopsis "Human-friendly input and output in Python")
715 "The functions and classes in @code{humanfriendly} can be used to make
716 text interfaces more user-friendly. It includes tools to parse and format
717 numbers, file sizes, and timespans, timers for long-running operations, menus
718 to allow the user to choose from a list of options, and terminal interaction
720 (license license:expat)))
722 (define-public python2-humanfriendly
723 (package-with-python2 python-humanfriendly))
725 (define-public python-capturer
727 (name "python-capturer")
732 (uri (pypi-uri "capturer" version))
735 "05d6ji4j8ipiq0br7bwam38qc6hd9l1djmfxlzrxx19ziyjl4089"))))
736 (build-system python-build-system)
740 `(("python-humanfriendly" ,python-humanfriendly)))
741 (home-page "https://capturer.readthedocs.io")
742 (synopsis "Capture stdout and stderr streams of the current process")
744 "The capturer package makes it easy to capture the stdout and stderr
745 streams of the current process and subprocesses. Output can be relayed
746 to the terminal in real time but is also available to the Python program
747 for additional processing.")
748 (license license:expat)))
750 (define-public python2-capturer
751 (package-with-python2 python-capturer))
753 (define-public python-case
760 (uri (pypi-uri "case" version))
763 "1cagg06vfph864s6l5jb0zqliwxh647bki8j6lf4a4qrv40jnhs8"))))
764 (build-system python-build-system)
766 `(("python-mock" ,python-mock)
767 ("python-nose" ,python-nose)
768 ("python-six" ,python-six)
769 ("python-unittest2" ,python-unittest2)))
771 `(("python-coverage" ,python-coverage)))
772 (home-page "https://github.com/celery/case")
773 (synopsis "Unittest utilities and convenience methods")
775 "The @code{case} package provides utilities on top of unittest, including
776 some helpful Python 2 compatibility convenience methods.")
777 (license license:bsd-3)))
779 (define-public python-verboselogs
781 (name "python-verboselogs")
786 (uri (pypi-uri "verboselogs" version))
789 "09z4d1jiasn7k1hs5af2ckmnrd0i1d1m04bhfjhv7z6svzfdwgg3"))))
790 (build-system python-build-system)
792 `(("python-mock" ,python-mock)
793 ("python-astroid" ,python-astroid)
794 ("python-pylint" ,python-pylint)))
795 (home-page "https://verboselogs.readthedocs.io")
796 (synopsis "Verbose logging level for Python's logging module")
798 "The @code{verboselogs} package extends Python's @code{logging} module to
799 add the log levels NOTICE, SPAM, SUCCESS and VERBOSE.")
800 (license license:expat)))
802 (define-public python2-verboselogs
803 (package-with-python2 python-verboselogs))
805 (define-public python-coloredlogs
807 (name "python-coloredlogs")
812 (uri (pypi-uri "coloredlogs" version))
815 "1blcann6dyg5dhps9pg12rn0q0rjrlajpmmil0gy0j4cbvnl2il9"))))
816 (build-system python-build-system)
818 `(;Tests require some updated modules
821 `(("python-capturer" ,python-capturer)))
822 (home-page "https://coloredlogs.readthedocs.io")
823 (synopsis "Colored stream handler for Python's logging module")
825 "The @code{coloredlogs} package enables colored terminal output for
826 Python's logging module. The @code{ColoredFormatter} class inherits from
827 @code{logging.Formatter} and uses ANSI escape sequences to render your logging
829 (license license:expat)))
831 (define-public python2-coloredlogs
832 (package-with-python2 python-coloredlogs))
834 (define-public python-eventlet
836 (name "python-eventlet")
841 (uri (pypi-uri "eventlet" version))
844 "0f3q55mq4n021wb7qa53pz3ix6i2py64sap66vsaqm2scjw83m9s"))))
845 (build-system python-build-system)
847 `(("python-greenlet" ,python-greenlet)))
849 ;; TODO: Requires unpackaged 'enum-compat'.
851 (home-page "http://eventlet.net")
852 (synopsis "Concurrent networking library for Python")
854 "Eventlet is a concurrent networking library for Python that
855 allows you to change how you run your code, not how you write it.
856 It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O.
857 Coroutines ensure that the developer uses a blocking style of programming
858 that is similar to threading, but provide the benefits of non-blocking I/O.
859 The event dispatch is implicit, which means you can easily use @code{Eventlet}
860 from the Python interpreter, or as a small part of a larger application.")
861 (license license:expat)))
863 (define-public python2-eventlet
864 (let ((base (package-with-python2
865 (strip-python2-variant python-eventlet))))
866 (package (inherit base)
868 `(("python2-enum34" ,python2-enum34)
869 ,@(package-propagated-inputs base))))))
871 (define-public python-six
878 (uri (pypi-uri "six" version))
881 "1scqzwc51c875z23phj48gircqjgnn3af8zy2izjwmnlxrxsgs3h"))))
882 (build-system python-build-system)
885 (modify-phases %standard-phases
888 (invoke "py.test" "-v"))))))
890 `(("python-py" ,python-py)
891 ("python-pytest" ,python-pytest-bootstrap)))
892 (home-page "https://pypi.python.org/pypi/six/")
893 (synopsis "Python 2 and 3 compatibility utilities")
895 "Six is a Python 2 and 3 compatibility library. It provides utility
896 functions for smoothing over the differences between the Python versions with
897 the goal of writing Python code that is compatible on both Python versions.
898 Six supports every Python version since 2.5. It is contained in only one
899 Python file, so it can be easily copied into your project.")
900 (license license:x11)))
902 (define-public python2-six
903 (package-with-python2 python-six))
905 (define-public python-six-bootstrap
908 (name "python-six-bootstrap")
910 (arguments `(#:tests? #f))))
912 (define-public python2-six-bootstrap
913 (package-with-python2 python-six-bootstrap))
915 (define-public python-schedule
917 (name "python-schedule")
922 (uri (pypi-uri "schedule" version))
925 "0vplyjcbfrq50sphlwya749z8p2pcyi2nycw3518i0qpd9a6189i"))))
926 (build-system python-build-system)
928 `(("python-pytest" ,python-pytest)
929 ("python-mock" ,python-mock)))
930 (home-page "https://github.com/dbader/schedule")
931 (synopsis "Schedule periodic function calls in Python")
933 "Schedule is an in-process scheduler for periodic jobs that uses the
934 builder pattern for configuration. Schedule lets you run Python functions (or
935 any other callable) periodically at pre-determined intervals using a simple,
936 human-friendly syntax.")
937 (license license:expat)))
939 (define-public python2-schedule
940 (package-with-python2 python-schedule))
942 (define-public python-pandas
944 (name "python-pandas")
949 (uri (pypi-uri "pandas" version))
951 (base32 "1x54pd7hr3y7qahx6b5bf2wzj54xvl8r3s1h4pl254pnmi3wl92v"))))
952 (build-system python-build-system)
954 `(#:modules ((guix build utils)
955 (guix build python-build-system)
958 #:phases (modify-phases %standard-phases
961 (let ((build-directory
964 (car (scandir "build"
965 (cut string-prefix? "lib." <>))))))
966 ;; Disable the "strict data files" option which causes
967 ;; the build to error out if required data files are not
968 ;; available (as is the case with PyPI archives).
969 (substitute* "setup.cfg"
970 (("addopts = --strict-data-files") "addopts = "))
971 (with-directory-excursion build-directory
972 ;; Delete tests that require "moto" which is not yet in Guix.
973 (for-each delete-file
974 '("pandas/tests/io/conftest.py"
975 "pandas/tests/io/json/test_compression.py"
976 "pandas/tests/io/parser/test_network.py"
977 "pandas/tests/io/test_excel.py"
978 "pandas/tests/io/test_parquet.py"))
979 (invoke "pytest" "-vv" "pandas" "--skip-slow"
980 "--skip-network" "-k"
981 ;; XXX: Due to the deleted tests above.
982 "not test_read_s3_jsonl"))))))))
984 `(("python-numpy" ,python-numpy)
985 ("python-pytz" ,python-pytz)
986 ("python-dateutil" ,python-dateutil)))
988 `(("python-cython" ,python-cython)
989 ("python-beautifulsoup4" ,python-beautifulsoup4)
990 ("python-lxml" ,python-lxml)
991 ("python-html5lib" ,python-html5lib)
992 ("python-nose" ,python-nose)
993 ("python-pytest" ,python-pytest)))
994 (home-page "https://pandas.pydata.org")
995 (synopsis "Data structures for data analysis, time series, and statistics")
997 "Pandas is a Python package providing fast, flexible, and expressive data
998 structures designed to make working with structured (tabular,
999 multidimensional, potentially heterogeneous) and time series data both easy
1000 and intuitive. It aims to be the fundamental high-level building block for
1001 doing practical, real world data analysis in Python.")
1002 (license license:bsd-3)))
1004 (define-public python2-pandas
1005 (package-with-python2 python-pandas))
1007 (define-public python2-mechanize
1009 (name "python2-mechanize")
1014 (uri (pypi-uri "mechanize" version))
1017 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1018 (build-system python-build-system)
1020 `(#:python ,python-2 ; apparently incompatible with Python 3
1022 ;; test fails with message
1023 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1024 ;; (python-3.3.2) or
1025 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1027 ;; The source code is from March 2011 and probably not up-to-date
1028 ;; with respect to python unit tests.
1029 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1031 "Stateful programmatic web browsing in Python")
1033 "Mechanize implements stateful programmatic web browsing in Python,
1034 after Andy Lester’s Perl module WWW::Mechanize.")
1035 (license (license:non-copyleft
1037 "See COPYING in the distribution."))))
1040 (define-public python-simplejson
1042 (name "python-simplejson")
1047 (uri (pypi-uri "simplejson" version))
1050 "1lkv3xlf7ryzi69zqfdbkvpxdfy1rg1rq2yzcnxgf4km5m6difqy"))))
1051 (build-system python-build-system)
1052 (home-page "http://simplejson.readthedocs.org/en/latest/")
1054 "Json library for Python")
1056 "JSON (JavaScript Object Notation) is a subset of JavaScript
1057 syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1060 Simplejson exposes an API familiar to users of the standard library marshal
1061 and pickle modules. It is the externally maintained version of the json
1062 library contained in Python 2.6, but maintains compatibility with Python 2.5
1063 and (currently) has significant performance advantages, even without using
1064 the optional C extension for speedups. Simplejson is also supported on
1066 (license license:x11)))
1068 (define-public python2-simplejson
1069 (package-with-python2 python-simplejson))
1072 (define-public python-pyicu
1074 (name "python-pyicu")
1079 (uri (pypi-uri "PyICU" version))
1082 "0wq9y5fi1ighgf5aws9nr87vi1w44p7q1k83rx2y3qj5d2xyhspa"))))
1083 (build-system python-build-system)
1085 `(("icu4c" ,icu4c)))
1087 `(("python-pytest" ,python-pytest)
1088 ("python-six" ,python-six)))
1089 (home-page "https://github.com/ovalhub/pyicu")
1090 (synopsis "Python extension wrapping the ICU C++ API")
1092 "PyICU is a python extension wrapping the ICU C++ API.")
1093 (properties `((python2-variant . ,(delay python2-pyicu))))
1094 (license license:x11)))
1096 (define-public python2-pyicu
1097 (let ((base (package-with-python2
1098 (strip-python2-variant python-pyicu))))
1102 `(,@(package-arguments base)
1104 (modify-phases %standard-phases
1105 (add-before 'check 'delete-failing-test
1107 ;; XXX: This fails due to Unicode issues unique to Python 2,
1108 ;; it seems: <https://github.com/ovalhub/pyicu/issues/61>.
1109 (delete-file "test/test_Script.py")
1112 (define-public python2-dogtail
1113 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1114 ;; spaces in indentation" with Python 3.
1116 (name "python2-dogtail")
1120 (uri (pypi-uri "dogtail" version))
1123 "0p5wfssvzr9w0bvhllzbbd8fnp4cca2qxcpcsc33dchrmh5n552x"))))
1124 (build-system python-build-system)
1125 (arguments `(#:python ,python-2
1126 #:tests? #f)) ; invalid command "test"
1127 ;; Currently no offical homepage.
1128 (home-page "https://pypi.python.org/pypi/dogtail/")
1129 (synopsis "GUI test tool and automation framework written in Python")
1131 "Dogtail is a GUI test tool and automation framework written in Python.
1132 It uses Accessibility (a11y) technologies to communicate with desktop
1133 applications. dogtail scripts are written in Python and executed like any
1134 other Python program.")
1135 (license license:gpl2+)))
1137 (define-public python-empy
1139 (name "python-empy")
1143 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1147 "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6"))))
1148 (build-system python-build-system)
1150 `(#:tests? #f)) ;python2 only
1151 (home-page "http://www.alcyone.com/software/empy/")
1152 (synopsis "Templating system for Python")
1154 "EmPy is a system for embedding Python expressions and statements in
1155 template text; it takes an EmPy source file, processes it, and produces
1156 output. This is accomplished via expansions, which are special signals to the
1157 EmPy system and are set off by a special prefix (by default the at sign, @@).
1158 EmPy can expand arbitrary Python expressions and statements in this way, as
1159 well as a variety of special forms. Textual data not explicitly delimited in
1160 this way is sent unaffected to the output, allowing Python to be used in
1161 effect as a markup language. Also supported are callbacks via hooks,
1162 recording and playback via diversions, and dynamic, chainable filters. The
1163 system is highly configurable via command line options and embedded
1165 (license license:lgpl2.1+)))
1167 (define-public python2-empy
1168 (package-with-python2 python-empy))
1170 (define-public python2-element-tree
1172 (name "python2-element-tree")
1177 "http://effbot.org/media/downloads/elementtree-"
1178 version "-20050316.tar.gz"))
1181 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1182 (build-system python-build-system)
1184 `(#:python ,python-2 ; seems to be part of Python 3
1185 #:tests? #f)) ; no 'test' sub-command
1186 (synopsis "Toolkit for XML processing in Python")
1188 "ElementTree is a Python library supporting lightweight XML processing.")
1189 (home-page "http://effbot.org/zone/element-index.htm")
1190 (license (license:x11-style
1191 "http://docs.python.org/2/license.html"
1192 "Like \"CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2\"."))))
1194 (define-public python2-pybugz
1196 (name "python2-pybugz")
1201 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1205 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
1206 (patches (search-patches "pybugz-stty.patch"
1207 "pybugz-encode-error.patch"))))
1208 (build-system python-build-system)
1210 `(#:python ,python-2 ; SyntaxError with Python 3
1211 #:tests? #f)) ; no 'test' sub-command
1213 `(("element-tree" ,python2-element-tree)))
1214 (synopsis "Python and command-line interface to Bugzilla")
1216 "PyBugz is a Python library and command-line tool to query the Bugzilla
1217 bug tracking system. It is meant as an aid to speed up interaction with the
1219 (home-page "http://www.liquidx.net/pybugz/")
1220 (license license:gpl2)))
1222 (define-public python2-enum
1224 (name "python2-enum")
1228 (uri (pypi-uri "enum" version))
1231 "13lk3yrwj42vl30kw3c194f739nrfrdg64s6i0v2p636n4k8brsl"))))
1232 (build-system python-build-system)
1234 `(#:python ,python-2))
1235 (home-page "http://pypi.python.org/pypi/enum/")
1236 (synopsis "Robust enumerated type support in Python")
1238 "This provides a module for robust enumerations in Python. It has
1239 been superseded by the Python standard library and is provided only for
1241 ;; Choice of either license.
1242 (license (list license:gpl3+ license:psfl))))
1244 (define-public python-enum34
1246 (name "python-enum34")
1251 (uri (pypi-uri "enum34" version))
1254 "1cgm5ng2gcfrkrm3hc22brl6chdmv67b9zvva9sfs7gn7dwc9n4a"))))
1255 (build-system python-build-system)
1256 (home-page "https://pypi.python.org/pypi/enum34")
1257 (synopsis "Backported Python 3.4 Enum")
1259 "Enum34 is the new Python stdlib enum module available in Python 3.4
1260 backported for previous versions of Python from 2.4 to 3.3.")
1261 (license license:bsd-3)))
1263 (define-public python2-enum34
1264 (package-with-python2 python-enum34))
1266 (define-public python-parse-type
1268 (name "python-parse-type")
1273 (uri (pypi-uri "parse_type" version))
1276 "0g3b6gsdwnm8dpkh2vn34q6dzxm9gl908ggyzcv31n9xbp3vv5pm"))))
1277 (build-system python-build-system)
1279 `(("python-six" ,python-six)
1280 ("python-parse" ,python-parse)))
1282 `(("python-pytest" ,python-pytest)
1283 ("python-pytest-runner" ,python-pytest-runner)))
1284 (home-page "https://github.com/jenisys/parse_type")
1285 (synopsis "Extended parse module")
1287 "Parse_type extends the python parse module.")
1289 `((python2-variant . ,(delay python2-parse-type))))
1290 (license license:bsd-3)))
1292 (define-public python2-parse-type
1293 (let ((base (package-with-python2
1294 (strip-python2-variant python-parse-type))))
1295 (package (inherit base)
1297 `(("python2-enum34" ,python2-enum34)
1298 ,@(package-propagated-inputs base))))))
1300 (define-public python-parse
1302 (name "python-parse")
1307 (uri (pypi-uri "parse" version))
1310 "0f8997xr8nq2nq35iiviq8ningd1zvy59fg503xfpbi2dwhgdkf3"))))
1311 (build-system python-build-system)
1314 (modify-phases %standard-phases
1316 (lambda _ (invoke "python" "test_parse.py"))))))
1317 (home-page "https://github.com/r1chardj0n3s/parse")
1318 (synopsis "Parse strings")
1320 "Parse strings using a specification based on the Python @code{format()}
1322 (license license:x11)))
1324 (define-public python-polib
1326 (name "python-polib")
1330 (uri (pypi-uri "polib" version))
1333 "1pq2hbm3m2q0cjdszk8mc4qa1vl3wcblh5nfyirlfnzb2pcy7zss"))))
1334 (build-system python-build-system)
1335 (home-page "https://bitbucket.org/izi/polib/wiki/Home")
1336 (synopsis "Manipulate, create and modify gettext files")
1337 (description "Polib can manipulate any gettext format (po, pot and mo)
1338 files. It can be used to create po files from scratch or to modify
1340 (license license:expat)))
1342 (define-public python2-polib
1343 (let ((base (package-with-python2 (strip-python2-variant python-polib))))
1346 (arguments `(,@(package-arguments base)
1347 ;; Tests don't work with python2.
1350 (define-public scons
1357 (url "https://github.com/SCons/scons.git")
1359 (file-name (git-file-name name version))
1362 "1xizkjgrvydkjhpv7i5rx0mdkp3618sis7jsckjh57nxcynlk5dc"))))
1363 (build-system python-build-system)
1365 `(#:use-setuptools? #f ; still relies on distutils
1366 #:tests? #f ; no 'python setup.py test' command
1368 (modify-phases %standard-phases
1369 (add-before 'build 'bootstrap
1371 (substitute* "src/engine/SCons/compat/__init__.py"
1372 (("sys.modules\\[new\\] = imp.load_module\\(old, \\*imp.find_module\\(old\\)\\)")
1373 "sys.modules[new] = __import__(old)"))
1374 (invoke "python" "bootstrap.py" "build/scons" "DEVELOPER=guix")
1375 (chdir "build/scons")
1377 (home-page "http://scons.org/")
1378 (synopsis "Software construction tool written in Python")
1380 "SCons is a software construction tool. Think of SCons as an improved,
1381 cross-platform substitute for the classic Make utility with integrated
1382 functionality similar to autoconf/automake and compiler caches such as ccache.
1383 In short, SCons is an easier, more reliable and faster way to build
1385 (license license:x11)))
1387 (define-public scons-python2
1389 (inherit (package-with-python2 scons))
1390 (name "scons-python2")))
1392 (define-public python-extras
1394 (name "python-extras")
1399 (uri (pypi-uri "extras" version))
1402 "0khvm08rcwm62wc47j8niyl6h13f8w51c8669ifivjdr23g3cbhk"))))
1403 (build-system python-build-system)
1405 ;; FIXME: Circular dependency on testtools.
1407 (home-page "https://github.com/testing-cabal/extras")
1408 (synopsis "Useful extensions to the Python standard library")
1410 "Extras is a set of extensions to the Python standard library.")
1411 (license license:expat)))
1413 (define-public python2-extras
1414 (package-with-python2 python-extras))
1416 (define-public python-mimeparse
1418 (name "python-mimeparse")
1423 (uri (pypi-uri "python-mimeparse" version))
1426 "0y2g6cl660bpz11srgqyvvm8gmywpgyx8g0xfvbiyr0af0yv1r3n"))))
1427 (build-system python-build-system)
1430 (modify-phases %standard-phases
1433 (invoke "./mimeparse_test.py"))))))
1435 "https://github.com/dbtsai/python-mimeparse")
1436 (synopsis "Python library for parsing MIME types")
1438 "Mimeparse provides basic functions for parsing MIME type names and
1439 matching them against a list of media-ranges.")
1440 (license license:expat)))
1442 (define-public python2-mimeparse
1443 (package-with-python2 python-mimeparse))
1445 (define-public python-miniboa
1447 (name "python-miniboa")
1452 (uri (pypi-uri "miniboa" version))
1455 "09jh3pn4rh7kh7jayanf8jzy6gp03791b5a193w6148cf3i6k9m3"))))
1456 (build-system python-build-system)
1457 (home-page "https://github.com/shmup/miniboa")
1458 (synopsis "Simple, single-threaded Telnet server")
1460 "Miniboa is a simple, asynchronous, single-threaded, poll-based Telnet
1462 (license license:asl2.0)))
1464 (define-public python2-miniboa
1465 (package-with-python2 python-miniboa))
1467 (define-public python-pafy
1469 (name "python-pafy")
1474 (uri (pypi-uri "pafy" version))
1477 "1a7dxi95m1043rxx1r5x3ngb66nwlq6aqcasyqqjzmmmjps4zrim"))))
1478 (build-system python-build-system)
1480 `(#:tests? #f)) ; Currently pafy can not find itself in the tests
1482 ;; Youtube-dl is a python package which is imported in the file
1483 ;; "backend_youtube_dl.py", therefore it needs to be propagated.
1484 `(("youtube-dl" ,youtube-dl)))
1485 (home-page "https://np1.github.io/pafy/")
1486 (synopsis "Retrieve YouTube content and metadata")
1488 "@code{pafy} is a python library to retrieve YouTube content and metadata.")
1489 (license license:lgpl3+)))
1491 (define-public python2-funcsigs
1493 (name "python2-funcsigs")
1497 (uri (pypi-uri "funcsigs" version))
1500 "0l4g5818ffyfmfs1a924811azhjj8ax9xd1cffr1mzd3ycn0zfx7"))))
1501 (build-system python-build-system)
1503 `(#:python ,python-2))
1505 `(("python2-unittest2" ,python2-unittest2)))
1506 (home-page "http://funcsigs.readthedocs.org")
1507 (synopsis "Python function signatures from PEP362")
1509 "Backport of @code{funcsigs} which was introduced in Python 3.3.")
1510 (license license:asl2.0)))
1512 (define-public python2-funcsigs-bootstrap
1514 (inherit python2-funcsigs)
1515 (name "python2-funcsigs-bootstrap")
1519 ,@(package-arguments python2-funcsigs)))))
1521 (define-public python-py
1528 (uri (pypi-uri "py" version))
1531 "1xxvwfn82457djf55f5n2c94699rfqnk43br8fif2r2q8gvrmm9z"))))
1532 (build-system python-build-system)
1534 ;; FIXME: "ImportError: 'test' module incorrectly imported from
1535 ;; '/gnu/store/...-python-pytest-mimimal-3.0.5/lib/python3.5/site-packages'.
1536 ;; Expected '/tmp/guix-build-python-py-1.4.31.drv-0/py-1.4.31/py'.
1537 ;; Is this module globally installed?"
1540 `(("python-setuptools-scm" ,python-setuptools-scm)))
1541 (home-page "https://github.com/pytest-dev/py")
1542 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1544 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1545 code introspection, and logging.")
1546 (license license:expat)))
1548 (define-public python2-py
1549 (package-with-python2 python-py))
1551 ;; Recent versions of python-fixtures and python-testrepository need
1552 ;; python-pbr for packaging, which itself needs these two packages for
1554 ;; To fix this circular dependency, we use a build of python-pbr, based on the
1555 ;; same source, just without any test dependencies and with tests disabled.
1556 ;; python-pbr-minmal is then used to package python-fixtures and
1557 ;; python-testrepository.
1558 ;; Strictly speaking we currently could remove the test-requirements from the
1559 ;; normal python-pbr package (and save this package) since test are disabled
1560 ;; there anyway. But this may change in future.
1561 (define-public python-pbr-minimal
1563 (name "python-pbr-minimal")
1568 (uri (pypi-uri "pbr" version))
1571 "14fs5acnalnb3h62s7q7av239j541fk0n0z0lawh4h09b1s93s6p"))))
1572 (build-system python-build-system)
1575 (home-page "http://docs.openstack.org/developer/pbr/")
1576 (synopsis "Minimal build of python-pbr used for bootstrapping")
1578 "Used only for bootstrapping python2-pbr, you should not need this.")
1579 (license license:asl2.0)))
1581 (define-public python2-pbr-minimal
1582 (package-with-python2 python-pbr-minimal))
1584 (define-public python-pbr
1586 (inherit python-pbr-minimal)
1589 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1591 `(("git" ,git))) ;; pbr actually uses the "git" binary.
1593 `(("python-fixtures" ,python-fixtures-bootstrap)
1594 ;; discover, coverage, hacking, subunit
1595 ("python-mock" ,python-mock)
1596 ("python-six" ,python-six)
1597 ("python-sphinx" ,python-sphinx)
1598 ("python-testrepository" ,python-testrepository-bootstrap)
1599 ("python-testresources" ,python-testresources-bootstrap)
1600 ("python-testscenarios" ,python-testscenarios-bootstrap)
1601 ("python-testtools" ,python-testtools-bootstrap)
1602 ("python-virtualenv" ,python-virtualenv)))
1603 (synopsis "Enhance the default behavior of Python’s setuptools")
1605 "Python Build Reasonableness (PBR) is a library that injects some useful
1606 and sensible default behaviors into your setuptools run. It will set
1607 versions, process requirements files and generate AUTHORS and ChangeLog file
1608 from git information.
1611 (define-public python2-pbr
1612 (package-with-python2 python-pbr))
1614 (define-public python-exif-read
1616 (name "python-exif-read")
1620 (uri (pypi-uri "ExifRead" version))
1623 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
1624 (build-system python-build-system)
1625 (arguments `(#:tests? #f)) ; no tests
1626 (home-page "https://github.com/ianare/exif-py")
1627 (synopsis "Python library to extract EXIF data from image files")
1629 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
1631 (license license:bsd-3)))
1633 (define-public python2-exif-read
1634 (package-with-python2 python-exif-read))
1636 (define-public python-pyld
1638 (name "python-pyld")
1642 (uri (pypi-uri "PyLD" version))
1645 "12i2g6xdj30k7xxcibg3sc5y76snwq8l6n8fy9lyi577kgy0h2pm"))))
1646 (build-system python-build-system)
1647 (home-page "https://github.com/digitalbazaar/pyld")
1648 (synopsis "Python implementation of the JSON-LD specification")
1650 "PyLD is an implementation of the JSON-LD specification.")
1651 (license license:bsd-3)))
1653 (define-public python2-pyld
1654 (package-with-python2 python-pyld))
1656 (define-public python-click
1658 (name "python-click")
1663 (uri (pypi-uri "click" version))
1666 "1mzjixd4vjbjvzb6vylki9w1556a9qmdh35kzmq6cign46av952v"))))
1667 (build-system python-build-system)
1670 (modify-phases %standard-phases
1671 (add-after 'unpack 'fix-paths
1672 (lambda* (#:key inputs #:allow-other-keys)
1673 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
1674 "cross-libc" "libc"))))
1675 (substitute* "click/_unicodefun.py"
1677 (string-append "'" glibc "/bin/locale'"))))
1681 (invoke "python" "-m" "pytest"))))))
1683 `(("python-pytest" ,python-pytest)))
1684 (home-page "https://palletsprojects.com/p/click/")
1685 (synopsis "Command line library for Python")
1687 "Click is a Python package for creating command line interfaces in a
1688 composable way with as little code as necessary. Its name stands for
1689 \"Command Line Interface Creation Kit\". It's highly configurable but comes
1690 with sensible defaults out of the box.")
1691 (license license:bsd-3)))
1693 (define-public python2-click
1694 (package-with-python2 python-click))
1696 (define-public python-wheel
1698 (name "python-wheel")
1703 (uri (pypi-uri "wheel" version))
1706 "1dhxl1bf18bx9szmqcnxbg6204hp3im8089q3hkwh5jfa6zh75q2"))))
1707 (build-system python-build-system)
1709 `(("python-jsonschema" ,python-jsonschema)
1710 ("python-pytest-cov" ,python-pytest-cov)))
1711 (home-page "https://bitbucket.org/pypa/wheel/")
1712 (synopsis "Format for built Python packages")
1714 "A wheel is a ZIP-format archive with a specially formatted filename and
1715 the @code{.whl} extension. It is designed to contain all the files for a PEP
1716 376 compatible install in a way that is very close to the on-disk format. Many
1717 packages will be properly installed with only the @code{Unpack} step and the
1718 unpacked archive preserves enough information to @code{Spread} (copy data and
1719 scripts to their final locations) at any later time. Wheel files can be
1720 installed with a newer @code{pip} or with wheel's own command line utility.")
1721 (license license:expat)
1722 (properties `((python2-variant . ,(delay python2-wheel))))))
1724 (define-public python2-wheel
1725 (let ((wheel (package-with-python2
1726 (strip-python2-variant python-wheel))))
1727 (package (inherit wheel)
1728 (native-inputs `(("python2-functools32" ,python2-functools32)
1729 ,@(package-native-inputs wheel))))))
1731 (define-public python-vcversioner
1733 (name "python-vcversioner")
1734 (version "2.16.0.0")
1738 (uri (pypi-uri "vcversioner" version))
1741 "16z10sm78jd7ca3jbkgc3q5i8a8q7y1h21q1li21yy3rlhbhrrns"))))
1742 (build-system python-build-system)
1743 (synopsis "Python library for version number discovery")
1744 (description "Vcversioner is a Python library that inspects tagging
1745 information in a variety of version control systems in order to discover
1747 (home-page "https://github.com/habnabit/vcversioner")
1748 (license license:isc)))
1750 (define-public python2-vcversioner
1751 (package-with-python2 python-vcversioner))
1753 (define-public python-jsonschema
1755 (name "python-jsonschema")
1759 (uri (pypi-uri "jsonschema" version))
1762 "00kf3zmpp9ya4sydffpifn0j0mzm342a2vzh82p6r0vh10cg7xbg"))))
1763 (build-system python-build-system)
1766 (modify-phases %standard-phases
1767 (replace 'check (lambda _ (invoke "nosetests"))))))
1769 `(("python-nose" ,python-nose)
1770 ("python-vcversioner" ,python-vcversioner)))
1771 (home-page "https://github.com/Julian/jsonschema")
1772 (synopsis "Implementation of JSON Schema for Python")
1774 "Jsonschema is an implementation of JSON Schema for Python.")
1775 (license license:expat)
1776 (properties `((python2-variant . ,(delay python2-jsonschema))))))
1778 (define-public python2-jsonschema
1779 (let ((jsonschema (package-with-python2
1780 (strip-python2-variant python-jsonschema))))
1781 (package (inherit jsonschema)
1783 `(("python2-mock" ,python2-mock)
1784 ,@(package-native-inputs jsonschema)))
1786 `(("python2-functools32" ,python2-functools32))))))
1788 (define-public python-schema
1790 (name "python-schema")
1795 (uri (pypi-uri "schema" version))
1798 "1lw28j9w9vxyigg7vkfkvi6ic9lgjkdnfvnxdr7pklslqvzmk2vm"))))
1799 (build-system python-build-system)
1801 `(("python-pytest" ,python-pytest)))
1802 (home-page "https://github.com/keleshev/schema")
1803 (synopsis "Simple data validation library")
1805 "@code{python-schema} is a library for validating Python data
1806 structures, such as those obtained from config-files, forms, external
1807 services or command-line parsing, converted from JSON/YAML (or
1808 something else) to Python data-types.")
1809 (license license:psfl)))
1811 (define-public python2-schema
1812 (package-with-python2 python-schema))
1814 (define-public python-schema-0.5
1815 (package (inherit python-schema)
1820 (uri (pypi-uri "schema" version))
1823 "10zqvpaky51kgb8nd42bk7jwl8cn2zvayxjpdc1wwmpybj92x67s"))))))
1825 (define-public python2-schema-0.5
1826 (package-with-python2 python-schema-0.5))
1828 (define-public python-kitchen
1830 (name "python-kitchen")
1835 (uri (pypi-uri "kitchen" version))
1838 "1zakh6l0yjvwic9p0nkvmbidpnkygkxbigh2skmb5gccyrhbp7xg"))))
1839 (build-system python-build-system)
1841 `(("python-chardet" ,python-chardet)))
1842 (home-page "https://github.com/fedora-infra/kitchen")
1843 (synopsis "Python API for snippets")
1844 (description "@code{kitchen} module provides a python API for all sorts of
1845 little useful snippets of code that everybody ends up writing for their projects
1846 but never seem big enough to build an independent release. Use kitchen and stop
1847 cutting and pasting that code over and over.")
1848 (license (list license:lgpl2.1+
1849 ;; subprocess.py, test_subprocess.py,
1850 ;; kitchen/pycompat25/defaultdict.py:
1853 (define-public python2-kitchen
1854 (package-with-python2 python-kitchen))
1856 (define-public python-unidecode
1858 (name "python-unidecode")
1862 (uri (pypi-uri "Unidecode" version))
1865 "1ysjbr3nqfqj97h8zyj3v9pya413vkv7a1mzml80w37xx15kb1cb"))))
1866 (build-system python-build-system)
1867 (home-page "https://pypi.python.org/pypi/Unidecode")
1868 (synopsis "ASCII transliterations of Unicode text")
1870 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
1871 useful when integrating with legacy code that doesn't support Unicode, or for
1872 ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
1873 machine identifiers from human-readable Unicode strings that should still be
1874 somewhat intelligible.")
1875 (license license:gpl2+)))
1877 (define-public python2-unidecode
1878 (package-with-python2 python-unidecode))
1880 (define-public python-pyjwt
1882 (name "python-pyjwt")
1887 (uri (pypi-uri "PyJWT" version))
1890 "1rxsg14i33vm2i6lz0my628108c81k43v10n4h3p0gx62xdyf2sh"))
1891 (modules '((guix build utils)))
1894 (for-each delete-file-recursively
1895 (find-files "." "\\.pyc$"))
1897 (build-system python-build-system)
1899 `(("python-pytest" ,python-pytest)
1900 ("python-pytest-cov" ,python-pytest-cov)
1901 ("python-pytest-runner" ,python-pytest-runner)))
1902 (home-page "https://github.com/progrium/pyjwt")
1903 (synopsis "JSON Web Token implementation in Python")
1905 "PyJWT is a JSON Web Token implementation written in Python.")
1906 (license license:expat)))
1908 (define-public python2-pyjwt
1909 (package-with-python2 python-pyjwt))
1911 (define-public python-pykka
1913 (name "python-pykka")
1918 (uri (pypi-uri "Pykka" version))
1921 "049w3r0mdnnw7xv19jiq7rvls9k7xs73x05b4qs5d6z4vvmgyiz8"))))
1922 (build-system python-build-system)
1924 `(("python-mock" ,python-mock)
1925 ("python-nose" ,python-nose)
1926 ("python-gevent" ,python-gevent)
1927 ("python-eventlet" ,python-eventlet)))
1928 (home-page "https://www.pykka.org/")
1929 (synopsis "Pykka is a Python implementation of the actor model")
1931 "Pykka is a Python implementation of the actor model.
1932 The actor model introduces some simple rules to control the sharing
1933 of state and cooperation between execution units, which makes it
1934 easier to build concurrent applications.")
1935 (license license:asl2.0)))
1937 (define-public python2-pykka
1938 (package-with-python2 python-pykka))
1940 (define-public python-pympler
1942 (name "python-pympler")
1943 (home-page "https://pythonhosted.org/Pympler/")
1947 (uri (pypi-uri "Pympler" version))
1950 "03qwsbilqgvnbl3a1jmpgixbr2kq6m3fvdlzyr3wdp01bwlc85kx"))))
1951 (build-system python-build-system)
1953 `(#:phases (modify-phases %standard-phases
1955 (add-after 'install 'check
1956 (lambda* (#:key inputs outputs #:allow-other-keys)
1957 (add-installed-pythonpath inputs outputs)
1958 (invoke "python" "setup.py" "test"))))))
1959 (synopsis "Measure, monitor and analyze memory behavior")
1961 "Pympler is a development tool to measure, monitor and analyze
1962 the memory behavior of Python objects in a running Python application.
1964 By pympling a Python application, detailed insight in the size and the
1965 lifetime of Python objects can be obtained. Undesirable or unexpected
1966 runtime behavior like memory bloat and other @samp{pymples} can easily
1969 A web profiling frontend exposes process statistics, garbage
1970 visualisation and class tracker statistics.")
1971 (license license:asl2.0)))
1973 (define-public python2-pympler
1974 (package-with-python2 python-pympler))
1976 (define-public python-itsdangerous
1978 (name "python-itsdangerous")
1983 (uri (pypi-uri "itsdangerous" version))
1986 "068zpbksq5q2z4dckh2k1zbcq43ay74ylqn77rni797j0wyh66rj"))))
1987 (build-system python-build-system)
1988 (home-page "https://palletsprojects.com/p/itsdangerous/")
1989 (synopsis "Python library for passing data to/from untrusted environments")
1991 "Itsdangerous provides various helpers to pass trusted data to untrusted
1992 environments and back.")
1993 (license license:bsd-3)))
1995 (define-public python2-itsdangerous
1996 (package-with-python2 python-itsdangerous))
1998 (define-public python-pyyaml
2000 (name "python-pyyaml")
2005 (uri (pypi-uri "PyYAML" version))
2008 "1gx603g484z46cb74j9rzr6sjlh2vndxayicvlyhxdz98lhhkwry"))))
2009 (build-system python-build-system)
2011 `(("libyaml" ,libyaml)))
2012 (home-page "http://pyyaml.org/wiki/PyYAML")
2013 (synopsis "YAML parser and emitter for Python")
2015 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2016 complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2017 API, and sensible error messages. PyYAML supports standard YAML tags and
2018 provides Python-specific tags that allow to represent an arbitrary Python
2020 (license license:expat)))
2022 (define-public python2-pyyaml
2023 (package-with-python2 python-pyyaml))
2025 (define-public python-vine
2027 (name "python-vine")
2032 (uri (pypi-uri "vine" version))
2035 "0wkskb2hb494v9gixqnf4bl972p4ibcmxdykzpwjlfa5picns4aj"))))
2036 (build-system python-build-system)
2038 `(("python-pytest" ,python-pytest)
2039 ("python-case" ,python-case)))
2040 (home-page "https://github.com/celery/vine")
2041 (synopsis "Promises for Python")
2043 "@code{vine} provides a special implementation of promises in that it can
2044 be used both for \"promise of a value\" and lazy evaluation. The biggest
2045 upside for this is that everything in a promise can also be a promise,
2046 e.g. filters, callbacks and errbacks can all be promises.")
2047 (license license:bsd-3)))
2049 (define-public python-virtualenv
2051 (name "python-virtualenv")
2056 (uri (pypi-uri "virtualenv" version))
2059 "0242cg3hdq3qdvx5flyrki8lpwlgwf5k45c21ks5049fv7ygm6gq"))))
2060 (build-system python-build-system)
2063 (modify-phases %standard-phases
2064 (add-before 'check 'disable-failing-test
2066 ;; Disable failing test. See upstream bug report
2067 ;; https://github.com/pypa/virtualenv/issues/957
2068 (substitute* "tests/test_virtualenv.py"
2069 (("skipif.*") "skipif(True, reason=\"Guix\")\n"))
2072 `(("python-mock" ,python-mock)
2073 ("python-pytest" ,python-pytest)))
2074 (home-page "https://virtualenv.pypa.io/")
2075 (synopsis "Virtual Python environment builder")
2077 "Virtualenv is a tool to create isolated Python environments.")
2078 (license license:expat)))
2080 (define-public python2-virtualenv
2081 (package-with-python2 python-virtualenv))
2083 (define-public python-markupsafe
2085 (name "python-markupsafe")
2090 (uri (pypi-uri "MarkupSafe" version))
2093 "0rdn1s8x9ni7ss8rfiacj7x1085lx8mh2zdwqslnw8xc3l4nkgm6"))))
2094 (build-system python-build-system)
2095 (home-page "https://github.com/mitsuhiko/markupsafe")
2096 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2098 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2100 (license license:bsd-3)))
2102 (define-public python2-markupsafe
2103 (package-with-python2 python-markupsafe))
2105 (define-public python-jinja2
2107 (name "python-jinja2")
2112 (uri (pypi-uri "Jinja2" version))
2115 "190l36hfw3wb2n3n68yacjabxyb1pnxwn7vjx96cmjj002xy2jzq"))))
2116 (build-system python-build-system)
2118 `(("python-markupsafe" ,python-markupsafe)))
2119 (home-page "http://jinja.pocoo.org/")
2120 (synopsis "Python template engine")
2122 "Jinja2 is a small but fast and easy to use stand-alone template engine
2123 written in pure Python.")
2124 (license license:bsd-3)))
2126 (define-public python2-jinja2
2127 (package-with-python2 python-jinja2))
2129 (define-public python-pystache
2131 (name "python-pystache")
2135 (uri (pypi-uri "pystache" version))
2138 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2139 (build-system python-build-system)
2141 '(#:tests? #f)) ; FIXME: Python 3 tests are failing.
2142 (home-page "http://defunkt.io/pystache/")
2143 (synopsis "Python logic-less template engine")
2145 "Pystache is a Python implementation of the framework agnostic,
2146 logic-free templating system Mustache.")
2147 (license license:expat)
2148 (properties `((python2-variant . ,(delay python2-pystache))))))
2150 (define-public python2-pystache
2151 (package (inherit (package-with-python2
2152 (strip-python2-variant python-pystache)))
2154 `(#:python ,python-2
2156 (modify-phases %standard-phases
2159 (invoke "python" "test_pystache.py"))))))))
2161 (define-public python-joblib
2163 (name "python-joblib")
2167 (uri (pypi-uri "joblib" version))
2170 "0612nazad8dxmn3xghfrmjax6456l4xy6hn9cngs7vydi14ds7v5"))))
2171 (build-system python-build-system)
2174 (modify-phases %standard-phases
2176 (lambda _ (invoke "pytest" "-v" "joblib"))))))
2178 `(("python-pytest" ,python-pytest)))
2179 (home-page "https://joblib.readthedocs.io/")
2180 (synopsis "Using Python functions as pipeline jobs")
2182 "Joblib is a set of tools to provide lightweight pipelining in Python.
2183 In particular, joblib offers: transparent disk-caching of the output values
2184 and lazy re-evaluation (memoize pattern), easy simple parallel computing
2185 logging and tracing of the execution.")
2186 (license license:bsd-3)))
2188 (define-public python2-joblib
2189 (package-with-python2 python-joblib))
2191 (define-public python-docutils
2193 (name "python-docutils")
2198 (uri (pypi-uri "docutils" version))
2201 "0x22fs3pdmr42kvz6c654756wja305qv6cx1zbhwlagvxgr4xrji"))))
2202 (build-system python-build-system)
2204 '(#:tests? #f)) ; no setup.py test command
2205 (home-page "http://docutils.sourceforge.net/")
2206 (synopsis "Python Documentation Utilities")
2208 "Docutils is a modular system for processing documentation into useful
2209 formats, such as HTML, XML, and LaTeX. For input Docutils supports
2211 ;; Most of the source code is public domain, but some source files are
2212 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2213 (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+))))
2215 (define-public python2-docutils
2216 (package-with-python2 python-docutils))
2218 (define-public python-pygments
2220 (name "python-pygments")
2225 (uri (pypi-uri "Pygments" version))
2228 "1k78qdvir1yb1c634nkv6rbga8wv4289xarghmsbbvzhvr311bnv"))))
2229 (build-system python-build-system)
2231 ;; FIXME: Tests require sphinx, which depends on this.
2233 (home-page "http://pygments.org/")
2234 (synopsis "Syntax highlighting")
2236 "Pygments is a syntax highlighting package written in Python.")
2237 (license license:bsd-2)))
2239 (define-public python2-pygments
2240 (package-with-python2 python-pygments))
2242 (define-public python-sphinxcontrib-websupport
2244 (name "python-sphinxcontrib-websupport")
2248 (uri (pypi-uri "sphinxcontrib-websupport" version))
2251 "1ff3ix76xi1y6m99qxhaq5161ix9swwzydilvdya07mgbcvpzr4x"))))
2252 (build-system python-build-system)
2254 ;; FIXME: Tests depend on Sphinx, which depends on this.
2256 (home-page "http://sphinx-doc.org/")
2257 (synopsis "Sphinx API for web applications")
2258 (description "This package provides a Python API to easily integrate
2259 Sphinx documentation into your web application. It provides tools to
2260 integrate Sphinx documents in web templates and to handle searches.")
2261 (license license:bsd-3)))
2263 (define-public python2-sphinxcontrib-websupport
2264 (package-with-python2 python-sphinxcontrib-websupport))
2266 (define-public python-sphinx
2268 (name "python-sphinx")
2273 (uri (pypi-uri "Sphinx" version))
2276 "0pkkbfj7cl157q550gcs45am5y78ps0h7q6455d64s1zmw01jlvi"))))
2277 (build-system python-build-system)
2280 (modify-phases %standard-phases
2283 ;; Requires Internet access.
2284 (delete-file "tests/test_build_linkcheck.py")
2285 (substitute* "tests/test_build_latex.py"
2286 (("@pytest.mark.sphinx\\('latex', testroot='images'\\)")
2287 "@pytest.mark.skip()"))
2288 (when (which "python")
2289 ;; XXX: These tests are broken when using Python2:
2290 ;; <https://github.com/sphinx-doc/sphinx/issues/4710>.
2291 (delete-file "tests/test_api_translator.py")
2292 (delete-file "tests/test_setup_command.py"))
2293 (invoke "make" "test"))))))
2295 `(("python-imagesize" ,python-imagesize)
2296 ("python-sphinx-alabaster-theme"
2297 ,python-sphinx-alabaster-theme)
2298 ("python-babel" ,python-babel)
2299 ("python-snowballstemmer" ,python-snowballstemmer)
2300 ("python-docutils" ,python-docutils)
2301 ("python-jinja2" ,python-jinja2)
2302 ("python-packaging" ,python-packaging)
2303 ("python-pygments" ,python-pygments)
2304 ("python-requests" ,python-requests)
2305 ("python-six" ,python-six)
2306 ("python-sphinxcontrib-websupport" ,python-sphinxcontrib-websupport)))
2308 `(("graphviz" ,graphviz)
2309 ("imagemagick" ,imagemagick) ;for "convert"
2310 ("python-html5lib" ,python-html5lib)
2311 ("python-mock" ,python-mock)
2312 ("python-nose" ,python-nose)
2313 ("python-pytest" ,python-pytest)))
2314 (home-page "http://sphinx-doc.org/")
2315 (synopsis "Python documentation generator")
2316 (description "Sphinx is a tool that makes it easy to create documentation
2317 for Python projects or other documents consisting of multiple reStructuredText
2319 (license license:bsd-3)
2320 (properties `((python2-variant . ,(delay python2-sphinx))))))
2322 (define-public python2-sphinx
2323 (let ((base (package-with-python2 (strip-python2-variant python-sphinx))))
2326 (native-inputs `(("python2-mock" ,python2-mock)
2327 ("python2-enum34" ,python2-enum34)
2328 ,@(package-native-inputs base)))
2329 (propagated-inputs `(("python2-pytz" ,python2-pytz)
2330 ("python2-typing" ,python2-typing)
2331 ,@(package-propagated-inputs base))))))
2333 (define-public python-sphinx-gallery
2335 (name "python-sphinx-gallery")
2339 (uri (string-append "https://github.com/sphinx-gallery/sphinx-gallery"
2340 "/archive/v" version ".tar.gz"))
2341 (file-name (string-append name "-" version ".tar.gz"))
2344 "03fs99mcb1r7qp0xixqv07vcz98sk21yq19ffdysi0infdcpzfkd"))))
2345 (build-system python-build-system)
2347 ;; FIXME: Tests attempt to download <https://docs.python.org/3/objects.inv>,
2348 ;; <https://docs.scipy.org/doc/numpy/objects.inv>, and
2349 ;; <https://matplotlib.org/objects.inv>.
2352 `(("python-pytest-runner" ,python-pytest-runner)))
2353 (home-page "https://sphinx-gallery.github.io/")
2354 (synopsis "Generate an examples gallery automatically")
2356 "@code{sphinx_gallery} is a Sphinx extension that builds an HTML version
2357 from any set of Python scripts and puts it into an examples gallery.")
2358 (license license:bsd-3)))
2360 (define-public python2-sphinx-gallery
2361 (package-with-python2 python-sphinx-gallery))
2363 (define-public python-sphinx-rtd-theme
2365 (name "python-sphinx-rtd-theme")
2370 (uri (pypi-uri "sphinx_rtd_theme" version))
2373 "05rlhjzdyapr2w74jjs7mrm8hi69qskcr5vya9f9drpsys7lpxrd"))))
2374 (build-system python-build-system)
2375 (arguments '(#:tests? #f)) ; No tests.
2377 `(("python-sphinx" ,python-sphinx)))
2378 (home-page "https://github.com/snide/sphinx_rtd_theme/")
2379 (synopsis "ReadTheDocs.org theme for Sphinx")
2380 (description "A theme for Sphinx used by ReadTheDocs.org.")
2381 (license license:expat)))
2383 (define-public python2-sphinx-rtd-theme
2384 (package-with-python2 python-sphinx-rtd-theme))
2386 (define-public python-guzzle-sphinx-theme
2388 (name "python-guzzle-sphinx-theme")
2393 (uri (pypi-uri "guzzle_sphinx_theme" version))
2396 "1rnkzrrsbnifn3vsb4pfaia3nlvgvw6ndpxp7lzjrh23qcwid34v"))))
2397 (build-system python-build-system)
2399 `(("python-sphinx" ,python-sphinx)))
2400 (home-page "https://github.com/guzzle/guzzle_sphinx_theme")
2401 (synopsis "Sphinx theme used by Guzzle")
2402 (description "This package provides guzzle_sphinx_theme, a theme for the
2403 Sphinx documentation system, used by @uref{http://docs.guzzlephp.org, Guzzle}
2404 and several other projects.")
2405 (license license:expat)))
2407 (define-public python2-guzzle-sphinx-theme
2408 (package-with-python2 python-guzzle-sphinx-theme))
2410 (define-public python-rst.linker
2412 (name "python-rst.linker")
2417 (uri (pypi-uri "rst.linker" version))
2420 "0iqaacp7pj1s8avs4kc0qg0r7dscywaq37y6l9j14glqdikk0wdj"))))
2421 (build-system python-build-system)
2423 `(("python-dateutil" ,python-dateutil)
2424 ("python-six" ,python-six)))
2426 `(("python-setuptools-scm" ,python-setuptools-scm)))
2427 ;; Test would require path.py, which would introduce a cyclic dependence.
2428 (arguments `(#:tests? #f))
2429 ;; Note: As of version 1.7 the documentation is not worth building.
2430 (home-page "https://github.com/jaraco/rst.linker")
2431 (synopsis "Sphinx plugin to add links and timestamps")
2432 (description "rst.linker allows to automatically replace text by a
2433 reStructuredText external reference or timestamps. It's primary purpose is to
2434 augment the changelog, but it can be used for other documents, too.")
2435 (license license:expat)))
2437 (define-public python2-rst.linker
2438 (package-with-python2 python-rst.linker))
2440 (define-public python-feedgenerator
2442 (name "python-feedgenerator")
2447 (uri (pypi-uri "feedgenerator" version))
2450 "01mirwkm7xfx539hmvj7g9da1j51gw5lsx74dr0glizskjm5vq2s"))
2451 (modules '((guix build utils)))
2454 ;; Remove pre-compiled .pyc files from source.
2455 (for-each delete-file-recursively
2456 (find-files "." "__pycache__" #:directories? #t))
2457 (for-each delete-file (find-files "." "\\.pyc$"))
2459 (build-system python-build-system)
2461 `(("python-pytz" ,python-pytz)
2462 ("python-six" ,python-six)))
2463 (home-page "https://github.com/getpelican/feedgenerator")
2465 "Standalone version of Django's Atom/RSS feed generator")
2467 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2468 which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
2469 (license license:bsd-3)))
2471 (define-public python2-feedgenerator
2472 (package-with-python2 python-feedgenerator))
2474 (define-public python-toml
2476 (name "python-toml")
2481 (uri (pypi-uri "toml" version))
2484 "0bdbpbip67wdm6c7xwc6mmbmskyradj4cdxn1iibj4fcx1nbv1lf"))))
2485 (build-system python-build-system)
2487 `(#:tests? #f)) ;no tests suite in release
2488 (home-page "https://github.com/uiri/toml")
2489 (synopsis "Library for TOML")
2491 "@code{toml} is a library for parsing and creating Tom's Obvious, Minimal
2492 Language (TOML) configuration files.")
2493 (license license:expat)))
2495 (define-public python-black
2497 (name "python-black")
2502 (uri (pypi-uri "black" version))
2505 "0i4sfqgz6w15vd50kbhi7g7rifgqlf8yfr8y78rypd56q64qn592"))))
2506 (build-system python-build-system)
2509 (modify-phases %standard-phases
2510 (add-after 'patch-source-shebangs 'patch-extra-shebangs
2512 (let ((python3 (which "python3")))
2513 (substitute* '("tests/data/fmtonoff.py"
2514 "tests/data/string_prefixes.py"
2515 "tests/data/function.py")
2516 (("#!/usr/bin/env python3(\\.[0-9]+)?" _ minor-version)
2517 (string-append "#!" python3 (if (string? minor-version)
2521 `(("python-click" ,python-click)
2522 ("python-attrs" ,python-attrs)
2523 ("python-appdirs" ,python-appdirs)
2524 ("python-toml" ,python-toml)))
2525 (home-page "https://github.com/ambv/black")
2526 (synopsis "The uncompromising code formatter")
2527 (description "Black is the uncompromising Python code formatter.")
2528 (license license:expat)))
2530 (define-public python-blinker
2532 (name "python-blinker")
2537 (uri (pypi-uri "blinker" version))
2540 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
2541 (build-system python-build-system)
2542 (home-page "http://pythonhosted.org/blinker/")
2543 (synopsis "Fast, simple object-to-object and broadcast signaling")
2545 "Blinker provides a fast dispatching system that allows any number of
2546 interested parties to subscribe to events, or \"signals\".")
2547 (license license:expat)))
2549 (define-public python2-blinker
2550 (package-with-python2 python-blinker))
2552 (define-public pelican
2559 (uri (pypi-uri "pelican" version))
2562 "12spygavv9b6xpb5pgp7f0p3z0mms60nx6zrpx1yfkj68zz4flra"))))
2563 (build-system python-build-system)
2565 `(("python-feedgenerator" ,python-feedgenerator)
2566 ("python-jinja2" ,python-jinja2)
2567 ("python-pygments" ,python-pygments)
2568 ("python-docutils" ,python-docutils)
2569 ("python-pytz" ,python-pytz)
2570 ("python-blinker" ,python-blinker)
2571 ("python-unidecode" ,python-unidecode)
2572 ("python-six" ,python-six)
2573 ("python-dateutil" ,python-dateutil)
2574 ("python-markdown" ,python-markdown)))
2575 (home-page "https://getpelican.com/")
2577 `(;; XXX Requires a lot more packages to do unit tests :P
2579 #:phases (modify-phases %standard-phases
2581 'install 'adjust-requires
2582 ;; Since feedgenerator is installed from git, it doesn't
2583 ;; conform to the version requirements.
2585 ;; We *do have* "feedgenerator >= 1.6", but strip off the
2586 ;; version requirement so setuptools doesn't get confused.
2588 (substitute* "setup.py"
2589 (("['\"]feedgenerator.*?['\"]")
2590 "'feedgenerator'")))))))
2591 (synopsis "Python-based static site publishing system")
2593 "Pelican is a tool to generate a static blog from reStructuredText,
2594 Markdown input files, and more. Pelican uses Jinja2 for templating
2595 and is very extensible.")
2596 (license license:agpl3+)))
2598 (define-public python-scikit-image
2600 (name "python-scikit-image")
2605 (uri (pypi-uri "scikit-image" version))
2607 (base32 "0l1c3rl4s1jyv80i5hns4pgih09zrxfj7lygdc51w8sgyysb7ac6"))))
2608 (build-system python-build-system)
2610 ;; TODO: Some tests require running X11 server. Disable them?
2612 ;; See DEPENDS.txt for the list of build and run time requiremnts
2614 `(("python-cloudpickle" ,python-cloudpickle)
2615 ("python-dask" ,python-dask)
2616 ("python-matplotlib" ,python-matplotlib)
2617 ("python-networkx" ,python-networkx)
2618 ("python-numpy" ,python-numpy)
2619 ("python-pillow" ,python-pillow)
2620 ("python-pywavelets" ,python-pywavelets)
2621 ("python-scipy" ,python-scipy)
2622 ("python-six" ,python-six)))
2624 `(("python-cython" ,python-cython)))
2625 (home-page "http://scikit-image.org/")
2626 (synopsis "Image processing in Python")
2628 "Scikit-image is a collection of algorithms for image processing.")
2629 (license license:bsd-3)))
2631 (define-public python2-scikit-image
2632 (package-with-python2 python-scikit-image))
2634 (define-public python-cython
2636 (name "python-cython")
2641 (uri (pypi-uri "Cython" version))
2644 "0imw9s2rbrh32clbl10csnwmig9p3nzkrd2baxxxfmnrsc42pb3n"))))
2645 (build-system python-build-system)
2646 ;; we need the full python package and not just the python-wrapper
2647 ;; because we need libpython3.3m.so
2649 `(("python" ,python)))
2652 (modify-phases %standard-phases
2653 (add-before 'check 'set-HOME
2654 ;; some tests require access to "$HOME/.cython"
2655 (lambda _ (setenv "HOME" "/tmp") #t))
2657 ;; FIXME: These tests started failing on armhf after the 0.28 update
2658 ;; (commit c69d11c5930), both with an error such as this:
2659 ;; compiling (cpp) and running dictcomp ...
2660 ;; === C/C++ compiler error output: ===
2662 ;; dictcomp.cpp:5221: confused by earlier errors, bailing out
2663 ;; See <https://hydra.gnu.org/build/2948724> for logs.
2664 ,@(if (target-arm32?)
2665 `((add-before 'check 'disable-failing-tests
2667 (let ((disabled-tests (open-file "tests/bugs.txt" "a")))
2668 (for-each (lambda (test)
2669 (format disabled-tests "~a\n" test))
2670 '("memslice" "dictcomp"))
2671 (close-port disabled-tests)))))
2676 ;; The "with_outer_raising" test fails with Python 3.7. See
2677 ;; https://github.com/cython/cython/issues/2454
2678 (delete-file "tests/run/generators_py.py")
2679 (invoke "python" "runtests.py" "-vv"))))))
2680 (home-page "http://cython.org/")
2681 (synopsis "C extensions for Python")
2682 (description "Cython is an optimising static compiler for both the Python
2683 programming language and the extended Cython programming language. It makes
2684 writing C extensions for Python as easy as Python itself.")
2685 (license license:asl2.0)
2686 (properties `((python2-variant . ,(delay python2-cython))))))
2688 (define-public python2-cython
2689 (package (inherit (package-with-python2
2690 (strip-python2-variant python-cython)))
2691 (name "python2-cython")
2693 `(("python-2" ,python-2))))) ; this is not automatically changed
2695 ;; The RPython toolchain currently does not support Python 3.
2696 (define-public python2-rpython
2698 (name "python2-rpython")
2703 (uri (pypi-uri "rpython" version))
2706 "02z9cvxf0y41dcvwnvf2zn0albhhw1drvjjbq27m6i1piw1k6fc0"))))
2707 (build-system python-build-system)
2708 (arguments `(#:python ,python-2))
2710 `(("python2-pytest" ,python2-pytest))) ; needed for running tests
2711 (home-page "https://rpython.readthedocs.org")
2712 (synopsis "Framework for implementing interpreters and virtual machines")
2713 (description "RPython is a translation and support framework for
2714 producing implementations of dynamic languages, emphasizing a clean separation
2715 between language specification and implementation aspects.")
2716 (license license:expat)))
2718 ;; NOTE: when upgrading numpy please make sure that python-pandas and
2719 ;; python-scipy still build, as these three packages are often used together.
2720 (define-public python-numpy
2722 (name "python-numpy")
2728 "https://github.com/numpy/numpy/releases/download/v"
2729 version "/numpy-" version ".tar.gz"))
2732 "102vcl2qq4pjbm7a3d67vkkvn4466ngia1d8wi5avqwqh8j0jvkn"))))
2733 (build-system python-build-system)
2735 `(("openblas" ,openblas)
2736 ("lapack" ,lapack)))
2738 `(("python-cython" ,python-cython)
2739 ("python-pytest" ,python-pytest)
2740 ("gfortran" ,gfortran)))
2743 (modify-phases %standard-phases
2744 (add-before 'build 'configure-blas-lapack
2745 (lambda* (#:key inputs #:allow-other-keys)
2746 (call-with-output-file "site.cfg"
2750 libraries = openblas
2751 library_dirs = ~a/lib
2752 include_dirs = ~a/include
2754 # backslash-n to make emacs happy
2756 lapack_libs = lapack
2757 library_dirs = ~a/lib
2758 include_dirs = ~a/include
2760 (assoc-ref inputs "openblas")
2761 (assoc-ref inputs "openblas")
2762 (assoc-ref inputs "lapack")
2763 (assoc-ref inputs "lapack"))))
2765 (add-before 'build 'fix-executable-paths
2766 (lambda* (#:key inputs #:allow-other-keys)
2767 ;; Make /gnu/store/...-bash-.../bin/sh the default shell,
2768 ;; instead of /bin/sh.
2769 (substitute* "numpy/distutils/exec_command.py"
2770 (("(os.environ.get\\('SHELL', ')(/bin/sh'\\))" match match-start match-end)
2771 (string-append match-start (assoc-ref inputs "bash") match-end)))
2772 ;; Use "gcc" executable, not "cc".
2773 (substitute* "numpy/distutils/system_info.py"
2774 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
2775 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
2777 ;; Tests can only be run after the library has been installed and not
2778 ;; within the source directory.
2780 (add-after 'install 'check
2781 (lambda* (#:key outputs inputs #:allow-other-keys)
2782 ;; Make installed package available for running the tests
2783 (add-installed-pythonpath inputs outputs)
2784 ;; Make sure "f2py" etc is found.
2785 (setenv "PATH" (string-append (assoc-ref outputs "out") "/bin"
2786 ":" (getenv "PATH")))
2787 (with-directory-excursion "/tmp"
2788 (invoke "python" "-c"
2789 "import numpy; numpy.test(verbose=2)")))))))
2790 (home-page "http://www.numpy.org/")
2791 (synopsis "Fundamental package for scientific computing with Python")
2792 (description "NumPy is the fundamental package for scientific computing
2793 with Python. It contains among other things: a powerful N-dimensional array
2794 object, sophisticated (broadcasting) functions, tools for integrating C/C++
2795 and Fortran code, useful linear algebra, Fourier transform, and random number
2797 (license license:bsd-3)))
2799 (define-public python2-numpy
2800 (package-with-python2 python-numpy))
2802 ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of
2803 ;; interest only for legacy code going back to NumPy's predecessor
2805 (define-public python2-numpy-1.8
2806 (package (inherit python2-numpy)
2812 "https://github.com/numpy/numpy/archive/v" version ".tar.gz"))
2813 (file-name (string-append "python2-numpy-" version ".tar.gz"))
2816 "0sc20gz1b17xnyrkp5frca3ql5qfalpv916hfg2kqxpwr6jg0f1g"))))
2818 (substitute-keyword-arguments (package-arguments python2-numpy)
2820 `(modify-phases ,phases
2821 (replace 'configure-blas-lapack
2822 (lambda* (#:key inputs #:allow-other-keys)
2823 (call-with-output-file "site.cfg"
2827 libraries = openblas,lapack
2828 library_dirs = ~a/lib:~a/lib
2829 include_dirs = ~a/include:~a/include
2831 (assoc-ref inputs "openblas")
2832 (assoc-ref inputs "lapack")
2833 (assoc-ref inputs "openblas")
2834 (assoc-ref inputs "lapack"))))
2837 `(("python2-nose" ,python2-nose)))
2838 (description "NumPy is the fundamental package for scientific computing
2839 with Python. It contains among other things: a powerful N-dimensional array
2840 object, sophisticated (broadcasting) functions, tools for integrating C/C++
2841 and Fortran code, useful linear algebra, Fourier transform, and random number
2842 capabilities. Version 1.8 is the last one to contain the numpy.oldnumeric API
2843 that includes the compatibility layer numpy.oldnumeric with NumPy's predecessor
2845 (license license:bsd-3)))
2847 (define-public python-munch
2849 (name "python-munch")
2854 (uri (pypi-uri "munch" version))
2857 "1cmqg91xnqx8gvnh4pmp0bfl1dfcm65d5p9mg73zz8pkjhx6h80l"))))
2858 (build-system python-build-system)
2859 (home-page "https://github.com/Infinidat/munch")
2860 (synopsis "Dot-accessible dictionary")
2861 (description "Munch is a dot-accessible dictionary similar to JavaScript
2863 (license license:expat)))
2865 (define-public python2-munch
2866 (package-with-python2 python-munch))
2868 (define-public python-colormath
2870 (name "python-colormath")
2875 (uri (pypi-uri "colormath" version))
2878 "05qjycgxp3p2f9n6lmic68sxmsyvgnnlyl4z9w7dl9s56jphaiix"))))
2879 (build-system python-build-system)
2881 `(("python-networkx" ,python-networkx)
2882 ("python-numpy" ,python-numpy)))
2883 (home-page "https://github.com/gtaylor/python-colormath")
2884 (synopsis "Color math and conversion library")
2886 "This is a Python library for color math and conversions.")
2887 (license license:bsd-3)))
2889 (define-public python2-colormath
2890 (package-with-python2 python-colormath))
2892 (define-public python-spectra
2894 (name "python-spectra")
2899 (uri (pypi-uri "spectra" version))
2902 "1f322x914bhkg6r5gv1vmnir3iy0k5kih0fd2gp3rdkw32jn5cwf"))))
2903 (build-system python-build-system)
2906 (modify-phases %standard-phases
2908 (lambda _ (invoke "nosetests" "-v"))))))
2910 `(("python-colormath" ,python-colormath)))
2912 `(("python-nose" ,python-nose)))
2913 (home-page "https://github.com/jsvine/spectra")
2914 (synopsis "Color scales and color conversion")
2916 "This package provides a Python library intended to make color math,
2917 color scales, and color space conversion easy. It has support for:
2922 @item Color blending
2923 @item Brightening/darkening colors
2924 @item Saturating/desaturating colors
2925 @item Conversion to/from multiple color spaces.
2927 (license license:expat)))
2929 (define-public python2-spectra
2930 (package-with-python2 python-spectra))
2932 (define-public python-numpy-documentation
2934 (name "python-numpy-documentation")
2935 (version (package-version python-numpy))
2936 (source (package-source python-numpy))
2937 (build-system python-build-system)
2939 `(("python-matplotlib" ,python-matplotlib)
2940 ("python-numpy" ,python-numpy)
2941 ("pkg-config" ,pkg-config)
2942 ("python-sphinx" ,python-sphinx)
2943 ("python-numpydoc" ,python-numpydoc)
2944 ("texlive" ,(texlive-union (list texlive-fonts-amsfonts
2945 texlive-fonts-cm-super
2947 texlive-generic-ifxetex
2948 texlive-generic-pdftex
2949 texlive-latex-amsfonts
2950 texlive-latex-capt-of
2952 texlive-latex-environ
2953 texlive-latex-eqparbox
2954 texlive-latex-etoolbox
2955 texlive-latex-expdlist
2956 texlive-latex-fancyhdr
2957 texlive-latex-fancyvrb
2958 texlive-latex-fncychap
2960 texlive-latex-framed
2961 texlive-latex-geometry
2962 texlive-latex-graphics
2963 texlive-latex-hyperref
2964 texlive-latex-mdwtools
2965 texlive-latex-multirow
2966 texlive-latex-needspace
2967 texlive-latex-oberdiek
2968 texlive-latex-parskip
2969 texlive-latex-preview
2970 texlive-latex-tabulary
2971 texlive-latex-threeparttable
2972 texlive-latex-titlesec
2973 texlive-latex-trimspaces
2975 texlive-latex-upquote
2977 texlive-latex-varwidth
2978 texlive-latex-wrapfig)))
2979 ("texinfo" ,texinfo)
2981 ("scipy-sphinx-theme"
2982 ,(origin ; The build script expects scipy-sphinx-theme as a git submodule
2985 (url "https://github.com/scipy/scipy-sphinx-theme.git")
2986 (commit "c466764e2231ba132c09826b5b138fffa1cfcec3")))
2989 "0q2y87clwlsgc7wvlsn9pzyssybcq10plwhq2w1ydykfsyyqbmkl"))))
2990 ,@(package-native-inputs python-numpy)))
2992 `(#:tests? #f ; we're only generating the documentation
2994 (modify-phases %standard-phases
2997 (lambda* (#:key inputs outputs #:allow-other-keys)
2998 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
3000 data "/doc/" ,name "-"
3001 ,(package-version python-numpy)))
3002 (info-reader (string-append data "/info"))
3003 (html (string-append doc "/html"))
3004 (scipy-sphinx-theme "scipy-sphinx-theme")
3005 (sphinx-theme-checkout (assoc-ref inputs scipy-sphinx-theme))
3006 (pyver ,(string-append "PYVER=")))
3008 ;; FIXME: this is needed to for texlive-union to generate
3009 ;; fonts, which are not found.
3010 (setenv "HOME" "/tmp")
3012 (with-directory-excursion "doc"
3013 (copy-recursively sphinx-theme-checkout scipy-sphinx-theme)
3015 (invoke "make" "html" pyver)
3016 (invoke "make" "latex" "PAPER=a4" pyver)
3017 (invoke "make" "-C" "build/latex"
3018 "all-pdf" "PAPER=a4" pyver)
3019 ;; FIXME: Generation of the info file fails.
3020 ;; (invoke "make" "info" pyver)
3022 ;; (copy-file "build/texinfo/numpy.info"
3023 ;; (string-append info "/numpy.info"))
3024 (for-each (lambda (file)
3025 (copy-file (string-append "build/latex" file)
3026 (string-append doc file)))
3027 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3028 (with-directory-excursion "build/html"
3029 (for-each (lambda (file)
3030 (let* ((dir (dirname file))
3031 (tgt-dir (string-append html "/" dir)))
3032 (unless (equal? "." dir)
3034 (install-file file html)))
3035 (find-files "." ".*")))))
3037 (home-page (package-home-page python-numpy))
3038 (synopsis "Documentation for the python-numpy package")
3039 (description (package-description python-numpy))
3040 (license (package-license python-numpy))))
3042 (define-public python2-numpy-documentation
3043 (let ((numpy-documentation (package-with-python2 python-numpy-documentation)))
3045 (inherit numpy-documentation)
3046 (native-inputs `(("python2-functools32" ,python2-functools32)
3047 ,@(package-native-inputs numpy-documentation))))))
3049 (define-public python-pygit2
3051 (name "python-pygit2")
3056 (uri (pypi-uri "pygit2" version))
3059 "046ahvsb7a20sgvscqfm3cb32sp3sii4gim9vz7zzrkf7yz16xlv"))))
3060 (build-system python-build-system)
3063 (modify-phases %standard-phases
3064 ;; Remove after the next update. See:
3065 ;; https://github.com/libgit2/pygit2/pull/851
3066 (add-after 'unpack 'compile-with-cffi
3068 (substitute* "setup.py"
3069 (("install_requires")
3070 "setup_requires=['cffi'],\n install_requires"))
3072 (add-after 'unpack 'fix-dependency-versioning
3074 (substitute* "setup.py"
3078 `(("python-six" ,python-six)
3079 ("python-cffi" ,python-cffi)
3080 ("libgit2" ,libgit2)
3081 ("python-tox" ,python-tox)))
3083 `(("python-pytest" ,python-pytest)))
3084 (home-page "https://github.com/libgit2/pygit2")
3085 (synopsis "Python bindings for libgit2")
3086 (description "Pygit2 is a set of Python bindings to the libgit2 shared
3087 library, libgit2 implements Git plumbing.")
3088 ;; GPL2.0 only, with linking exception.
3089 (license license:gpl2)))
3091 (define-public python2-pygit2
3092 (package-with-python2 python-pygit2))
3094 (define-public python-pyparsing
3096 (name "python-pyparsing")
3101 (uri (pypi-uri "pyparsing" version))
3103 (base32 "06dgd0iilvf8m0ssmfpcbh8l6jf0zkp8adbb84llksg17crfx4zl"))))
3104 (build-system python-build-system)
3105 (outputs '("out" "doc"))
3107 `(#:tests? #f ; no test target
3109 (modify-phases %standard-phases
3110 (add-after 'install 'install-doc
3111 (lambda* (#:key outputs #:allow-other-keys)
3112 (let* ((doc (string-append (assoc-ref outputs "doc")
3113 "/share/doc/" ,name "-" ,version))
3114 (html-doc (string-append doc "/html"))
3115 (examples (string-append doc "/examples")))
3121 (install-file file tgt))
3122 (find-files dir ".*")))
3123 (list "docs" "htmldoc" "examples")
3124 (list doc html-doc examples))
3126 (home-page "https://github.com/pyparsing/pyparsing")
3127 (synopsis "Python parsing class library")
3129 "The pyparsing module is an alternative approach to creating and
3130 executing simple grammars, vs. the traditional lex/yacc approach, or the use
3131 of regular expressions. The pyparsing module provides a library of classes
3132 that client code uses to construct the grammar directly in Python code.")
3133 (license license:expat)))
3135 (define-public python2-pyparsing
3136 (package-with-python2 python-pyparsing))
3138 (define-public python-numpydoc
3140 (name "python-numpydoc")
3145 (uri (pypi-uri "numpydoc" version))
3148 "1zazxg3m8j4fksv3f7v7vpf4bj9qb1vj3r326am0vdip141vzx31"))))
3149 (build-system python-build-system)
3151 `(("python-sphinx" ,python-sphinx)))
3153 `(("python-nose" ,python-nose)))
3154 (home-page "https://pypi.python.org/pypi/numpydoc")
3156 "Numpy's Sphinx extensions")
3158 "Sphinx extension to support docstrings in Numpy format.")
3159 (license license:bsd-2)))
3161 (define-public python2-numpydoc
3162 (package-with-python2 python-numpydoc))
3164 (define-public python-numexpr
3166 (name "python-numexpr")
3171 (uri (pypi-uri "numexpr" version))
3174 "1frnbcwmsi312154x274xl28xazr1k8vjby83fwyla2n10a81bgq"))))
3175 (build-system python-build-system)
3176 (arguments `(#:tests? #f)) ; no tests included
3178 `(("python-numpy" ,python-numpy)))
3179 (home-page "https://github.com/pydata/numexpr")
3180 (synopsis "Fast numerical expression evaluator for NumPy")
3182 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3183 expressions that operate on arrays are accelerated and use less memory than
3184 doing the same calculation in Python. In addition, its multi-threaded
3185 capabilities can make use of all your cores, which may accelerate
3186 computations, most specially if they are not memory-bounded (e.g. those using
3187 transcendental functions).")
3188 (license license:expat)))
3190 (define-public python2-numexpr
3191 (package-with-python2 python-numexpr))
3193 (define-public python-cycler
3195 (name "python-cycler")
3199 (uri (pypi-uri "cycler" version))
3202 "1n69n23fak1gjxlrbhqisi2b9pv3ckrfj98llx3p53953082syyd"))))
3203 (build-system python-build-system)
3205 ;; XXX: The current version requires 'coveralls' which we don't have.
3206 ;; Enable this for the next release which uses 'python-pytest'.
3209 `(("python-six" ,python-six)))
3210 (home-page "http://matplotlib.org/cycler/")
3211 (synopsis "Composable keyword argument iterator")
3213 "When using @code{matplotlib} and plotting more than one line, it is
3214 common to want to be able to want to be able to cycle over one or more artist
3215 styles; but the plotting logic can quickly become involved.
3216 To address this and enable easy cycling over arbitrary @code{kwargs}, the
3217 @code{Cycler} class was developed.")
3218 (license license:bsd-3)))
3220 (define-public python2-cycler
3221 (package-with-python2 python-cycler))
3223 (define-public python-colorspacious
3225 (name "python-colorspacious")
3230 (uri (string-append "https://github.com/njsmith/colorspacious/archive/v"
3232 (file-name (string-append name "-" version))
3234 (base32 "1vflh5jm32qb0skza2i8pjacv09w6gq84fqpp2nj77s0rbmzgr4k"))))
3235 (build-system python-build-system)
3237 `(("python-numpy" ,python-numpy)))
3239 `(("python-nose" ,python-nose)))
3242 (modify-phases %standard-phases
3245 (invoke "nosetests" "--all-modules" "-v" "colorspacious"))))))
3246 (home-page "https://github.com/njsmith/colorspacious")
3247 (synopsis "Python library for colorspace conversions")
3248 (description "@code{colorspacious} is a Python library that lets you
3249 convert between colorspaces like sRGB, XYZ, CIEL*a*b*, CIECAM02, CAM02-UCS, etc.")
3250 (license license:expat)))
3252 (define-public python2-colorspacious
3253 (package-with-python2 python-colorspacious))
3255 (define-public python-matplotlib
3257 (name "python-matplotlib")
3262 (uri (pypi-uri "matplotlib" version))
3265 "1rcc7x9ig3hpchkc4cwdvym3y451w74275fxr455zkfagrsvymbk"))))
3266 (build-system python-build-system)
3267 (propagated-inputs ; the following packages are all needed at run time
3268 `(("python-cycler" ,python-cycler)
3269 ("python-kiwisolver" ,python-kiwisolver)
3270 ("python-pyparsing" ,python-pyparsing)
3271 ("python-pygobject" ,python-pygobject)
3272 ("gobject-introspection" ,gobject-introspection)
3273 ("python-tkinter" ,python "tk")
3274 ("python-dateutil" ,python-dateutil)
3275 ("python-numpy" ,python-numpy)
3276 ("python-pillow" ,python-pillow)
3277 ("python-pytz" ,python-pytz)
3278 ("python-six" ,python-six)
3279 ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated
3280 ;; from 'gtk+') provides the required 'typelib' files used by
3281 ;; 'gobject-introspection'. The location of these files is set with the
3282 ;; help of the environment variable GI_TYPELIB_PATH. At build time this
3283 ;; is done automatically by a 'native-search-path' procedure. However,
3284 ;; at run-time the user must set this variable as follows:
3286 ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0
3288 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3289 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3290 ;; object. For this reason we need to import both libraries.
3291 ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo
3292 ("python-pycairo" ,python-pycairo)
3293 ;; XXX: qtwebkit cannot be built reliably.
3294 ("python-pyqt" ,python-pyqt-without-qtwebkit)
3295 ("python-cairocffi" ,python-cairocffi)))
3297 `(("libpng" ,libpng)
3298 ("imagemagick" ,imagemagick)
3299 ("freetype" ,freetype)
3302 ;; FIXME: Add backends when available.
3303 ;("python-wxpython" ,python-wxpython)
3307 `(("pkg-config" ,pkg-config)
3308 ("python-nose" ,python-nose)
3309 ("python-mock" ,python-mock)))
3312 (modify-phases %standard-phases
3313 (add-before 'build 'configure-environment
3314 (lambda* (#:key outputs inputs #:allow-other-keys)
3315 (let ((cairo (assoc-ref inputs "cairo"))
3316 (gtk+ (assoc-ref inputs "gtk+")))
3317 ;; Setting these directories in the 'basedirlist' of 'setup.cfg'
3319 (setenv "LD_LIBRARY_PATH"
3320 (string-append cairo "/lib:" gtk+ "/lib"))
3321 (setenv "HOME" (getcwd))
3322 (call-with-output-file "setup.cfg"
3324 (format port "[directories]~%
3325 basedirlist = ~a,~a~%
3328 (assoc-ref inputs "tcl")
3329 (assoc-ref inputs "tk")))))
3331 (home-page "http://matplotlib.org")
3332 (synopsis "2D plotting library for Python")
3334 "Matplotlib is a Python 2D plotting library which produces publication
3335 quality figures in a variety of hardcopy formats and interactive environments
3336 across platforms. Matplotlib can be used in Python scripts, the python and
3337 ipython shell, web application servers, and six graphical user interface
3339 (license license:psfl)
3340 (properties `((python2-variant . ,(delay python2-matplotlib))))))
3342 (define-public python2-matplotlib
3343 (let ((matplotlib (package-with-python2
3344 (strip-python2-variant python-matplotlib))))
3345 (package (inherit matplotlib)
3346 ;; Make sure to use special packages for Python 2 instead
3347 ;; of those automatically rewritten by package-with-python2.
3349 `(("python2-pycairo" ,python2-pycairo)
3350 ("python2-backports-functools-lru-cache"
3351 ,python2-backports-functools-lru-cache)
3352 ("python2-functools32" ,python2-functools32)
3353 ("python2-pygobject-2" ,python2-pygobject-2)
3354 ("python2-subprocess32" ,python2-subprocess32)
3355 ("python2-tkinter" ,python-2 "tk")
3356 ,@(fold alist-delete (package-propagated-inputs matplotlib)
3357 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
3359 (define-public python-matplotlib-documentation
3361 (name "python-matplotlib-documentation")
3362 (version (package-version python-matplotlib))
3363 (source (package-source python-matplotlib))
3364 (build-system python-build-system)
3366 `(("python-matplotlib" ,python-matplotlib)
3367 ("python-colorspacious" ,python-colorspacious)
3368 ("python-sphinx" ,python-sphinx)
3369 ("python-sphinx-gallery" ,python-sphinx-gallery)
3370 ("python-numpydoc" ,python-numpydoc)
3371 ("python-ipython" ,python-ipython)
3372 ("python-mock" ,python-mock)
3373 ("graphviz" ,graphviz)
3374 ("texlive" ,texlive)
3375 ("texinfo" ,texinfo)
3376 ,@(package-native-inputs python-matplotlib)))
3378 `(#:tests? #f ; we're only generating documentation
3380 (modify-phases %standard-phases
3384 ;; Produce pdf in 'A4' format.
3385 (substitute* "conf.py"
3386 (("latex_paper_size = 'letter'") "")
3387 ;; latex_paper_size is deprecated -> set paper size using
3389 (("latex_elements\\['pointsize'\\] = '11pt'" match)
3390 ;; insert at a point where latex_elements{} is defined:
3391 (string-append match "\nlatex_elements['papersize'] = 'a4paper'")))
3392 (invoke "make" "SPHINXBUILD=sphinx-build" "html" "latex" "texinfo")))
3394 (lambda* (#:key inputs outputs #:allow-other-keys)
3395 (let* ((data (string-append (assoc-ref outputs "out") "/share"))
3396 (doc (string-append data "/doc/python-matplotlib-" ,version))
3397 (info (string-append data "/info"))
3398 (html (string-append doc "/html")))
3401 (copy-recursively "build/html" html)
3402 (symlink (string-append html "/_images")
3403 (string-append info "/matplotlib-figures"))
3404 (with-directory-excursion "build/texinfo"
3405 (substitute* "matplotlib.texi"
3406 (("@image\\{([^,]*)" all file)
3407 (string-append "@image{matplotlib-figures/" file)))
3408 (symlink (string-append html "/_images")
3409 "./matplotlib-figures")
3410 (system* "makeinfo" "--no-split"
3411 "-o" "matplotlib.info" "matplotlib.texi"))
3412 (copy-file "build/texinfo/matplotlib.info"
3413 (string-append info "/matplotlib.info"))
3414 (copy-file "build/latex/Matplotlib.pdf"
3415 (string-append doc "/Matplotlib.pdf")))
3417 (home-page (package-home-page python-matplotlib))
3418 (synopsis "Documentation for the python-matplotlib package")
3419 (description (package-description python-matplotlib))
3420 (license (package-license python-matplotlib))))
3422 (define-public python2-matplotlib-documentation
3423 (package-with-python2 python-matplotlib-documentation))
3425 (define-public python2-pysnptools
3427 (name "python2-pysnptools")
3432 (uri (pypi-uri "pysnptools" version))
3435 "0lnis5xsl7bi0hz4f7gbicahzi5zlxkc21nk3g374xv8fb5hb3qm"))))
3436 (build-system python-build-system)
3438 `(#:python ,python-2 ; only Python 2.7 is supported
3439 #:tests? #f)) ; test files (e.g. examples/toydata.bim) not included
3441 `(("python2-numpy" ,python2-numpy)
3442 ("python2-scipy" ,python2-scipy)
3443 ("python2-pandas" ,python2-pandas)))
3445 `(("python2-cython" ,python2-cython)))
3446 (home-page "http://microsoftgenomics.github.io/PySnpTools/")
3447 (synopsis "Library for reading and manipulating genetic data")
3449 "PySnpTools is a library for reading and manipulating genetic data. It
3450 can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
3451 those files. It can also efficiently manipulate ranges of integers using set
3452 operators such as union, intersection, and difference.")
3453 (license license:asl2.0)))
3455 (define-public python-scipy
3457 (name "python-scipy")
3462 (uri (pypi-uri "scipy" version))
3465 "1lfg686w6vv2m2dfs8v9d0bf2i18z7wz5vgzjnkgmpr4hi0550w7"))))
3466 (build-system python-build-system)
3468 `(("python-numpy" ,python-numpy)
3469 ("python-matplotlib" ,python-matplotlib)
3470 ("python-pyparsing" ,python-pyparsing)))
3472 `(("lapack" ,lapack)
3473 ("openblas" ,openblas)))
3475 `(("python-cython" ,python-cython)
3476 ("python-pytest" ,python-pytest)
3477 ("python-sphinx" ,python-sphinx)
3478 ("python-numpydoc" ,python-numpydoc)
3479 ("gfortran" ,gfortran)
3482 (outputs '("out" "doc"))
3485 (modify-phases %standard-phases
3486 (add-after 'unpack 'disable-broken-tests
3488 (substitute* "scipy/sparse/linalg/dsolve/tests/test_linsolve.py"
3489 (("^( +)def test_threads_parallel\\(self\\):" m indent)
3490 (string-append indent
3491 "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
3493 (substitute* "scipy/sparse/linalg/eigen/arpack/tests/test_arpack.py"
3494 (("^def test_parallel_threads\\(\\):" m)
3495 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
3498 (add-before 'build 'configure-openblas
3499 (lambda* (#:key inputs #:allow-other-keys)
3500 (call-with-output-file "site.cfg"
3504 libraries = openblas
3505 library_dirs = ~a/lib
3506 include_dirs = ~a/include
3508 # backslash-n to make emacs happy
3510 library_dirs = ~a/lib
3511 atlas_libs = openblas
3513 (assoc-ref inputs "openblas")
3514 (assoc-ref inputs "openblas")
3515 (assoc-ref inputs "openblas"))))
3517 (add-after 'install 'install-doc
3518 (lambda* (#:key inputs outputs #:allow-other-keys)
3519 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3520 (doc (string-append data "/doc/" ,name "-" ,version))
3521 (html (string-append doc "/html"))
3522 (pyver ,(string-append "PYVER=" (version-major+minor
3523 (package-version python))))
3524 ;; By default it tries to run sphinx-build through the Python
3525 ;; interpreter which won't work with our shell wrapper.
3526 (sphinxbuild "SPHINXBUILD=LANG=C sphinx-build"))
3527 ;; Make installed package available for building the
3529 (add-installed-pythonpath inputs outputs)
3530 (with-directory-excursion "doc"
3531 ;; Fix generation of images for mathematical expressions.
3532 (substitute* (find-files "source" "conf\\.py")
3533 (("pngmath_use_preview = True")
3534 "pngmath_use_preview = False"))
3536 (invoke "make" "html" pyver sphinxbuild)
3537 (with-directory-excursion "build/html"
3538 (for-each (lambda (file)
3539 (let* ((dir (dirname file))
3540 (tgt-dir (string-append html "/" dir)))
3541 (install-file file html)))
3542 (find-files "." ".*")))))
3544 ;; Tests can only be run after the library has been installed and not
3545 ;; within the source directory.
3547 (add-after 'install 'check
3548 (lambda* (#:key inputs outputs #:allow-other-keys)
3549 (add-installed-pythonpath inputs outputs)
3550 (with-directory-excursion "/tmp"
3551 (invoke "python" "-c"
3552 "import scipy; scipy.test(verbose=2)")))))))
3553 (home-page "https://www.scipy.org/")
3554 (synopsis "The Scipy library provides efficient numerical routines")
3555 (description "The SciPy library is one of the core packages that make up
3556 the SciPy stack. It provides many user-friendly and efficient numerical
3557 routines such as routines for numerical integration and optimization.")
3558 (properties `((python2-variant . ,(delay python2-scipy))))
3559 (license license:bsd-3)))
3561 (define-public python2-scipy
3562 (package-with-python2
3563 (strip-python2-variant python-scipy)))
3565 (define-public python-socksipy-branch
3567 (name "python-socksipy-branch")
3572 (uri (pypi-uri "SocksiPy-branch" version))
3575 "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p"))))
3576 (build-system python-build-system)
3578 `(#:tests? #f)) ; There are no tests
3579 (home-page "https://code.google.com/archive/p/socksipy-branch/")
3580 (synopsis "Python SOCKS module")
3582 "SocksiPy - A Python SOCKS client module. It provides a
3583 socket-like interface that supports connections to any TCP
3584 service through the use of a SOCKS4, SOCKS5 or HTTP proxy.
3585 The original version was developed by Dan Haim, this is a
3586 branch created by Mario Vilas to address some open issues,
3587 as the original project seems to have been abandoned circa 2007.")
3588 (license license:bsd-3)))
3590 (define-public python2-socksipy-branch
3591 (package-with-python2 python-socksipy-branch))
3593 (define-public python-pycodestyle
3595 (name "python-pycodestyle")
3600 (uri (pypi-uri "pycodestyle" version))
3603 "0fhy4vnlgpjq4qd1wdnl6pvdw7rah0ypmn8c9mkhz8clsndskz6b"))))
3604 (build-system python-build-system)
3605 (home-page "https://pycodestyle.readthedocs.io/")
3606 (synopsis "Python style guide checker")
3607 (description "@code{pycodestyle} (formerly pep8) is a tool to check
3608 Python code against some of the style conventions in
3609 @url{http://www.python.org/dev/peps/pep-0008/,PEP 8}.")
3610 (license license:expat)))
3612 (define-public python2-pycodestyle
3613 (package-with-python2 python-pycodestyle))
3615 (define-public python-multidict
3617 (name "python-multidict")
3622 (uri (pypi-uri "multidict" version))
3625 "1vf5bq8hn5a9rvhr5v4fwbmarfsp35hhr8gs74kqfijy34j2f194"))))
3626 (build-system python-build-system)
3628 `(("python-pytest" ,python-pytest)
3629 ("python-pytest-runner" ,python-pytest-runner)))
3630 (home-page "https://github.com/aio-libs/multidict/")
3631 (synopsis "Multidict implementation")
3632 (description "Multidict is dict-like collection of key-value pairs
3633 where key might be occurred more than once in the container.")
3634 (license license:asl2.0)))
3636 (define-public python-orderedmultidict
3638 (name "python-orderedmultidict")
3643 (uri (pypi-uri "orderedmultidict" version))
3646 "0dls862ibm7qbq4fnvwx0xn1v9hwyzywbff8xjjdr42dd75208yw"))))
3647 (build-system python-build-system)
3650 (modify-phases %standard-phases
3651 (add-after 'unpack 'fix-tests
3653 ;; The package uses nosetest for running the tests.
3654 ;; Adding this initfile allows to run the test suite
3655 ;; without requiring nosetest.
3656 (with-output-to-file "tests/__init__.py" newline)
3659 `(("python-six" ,python-six)))
3661 `(("python-pycodestyle" ,python-pycodestyle)))
3662 (home-page "https://github.com/gruns/orderedmultidict")
3663 (synopsis "Python Ordered Multivalue Dictionary - omdict")
3664 (description "This package contains a library for ordered multivalue
3665 dictionaries. A multivalue dictionary is a dictionary that can store
3666 multiple values for the same key. An ordered multivalue dictionary is a
3667 multivalue dictionary that retains the order of insertions and deletions.")
3668 (license license:unlicense)))
3670 (define-public python2-orderedmultidict
3671 (package-with-python2 python-orderedmultidict))
3673 (define-public python-autopep8
3675 (name "python-autopep8")
3680 (uri (pypi-uri "autopep8" version))
3683 "192bvhzi4d0claqxgzymvv7k3qnj627742bc8sgxpzjj42pd9112"))))
3684 (build-system python-build-system)
3686 `(("python-pycodestyle" ,python-pycodestyle)))
3687 (home-page "https://github.com/hhatto/autopep8")
3688 (synopsis "Format Python code according to the PEP 8 style guide")
3690 "@code{autopep8} automatically formats Python code to conform to
3691 the PEP 8 style guide. It uses the pycodestyle utility to determine
3692 what parts of the code needs to be formatted. @code{autopep8} is
3693 capable of fixing most of the formatting issues that can be reported
3695 (license (license:non-copyleft
3696 "https://github.com/hhatto/autopep8/blob/master/LICENSE"))))
3698 (define-public python2-autopep8
3699 (package-with-python2 python-autopep8))
3701 (define-public python-distutils-extra
3703 (name "python-distutils-extra")
3708 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
3709 version "/+download/python-distutils-extra-"
3713 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
3714 (build-system python-build-system)
3715 (home-page "https://launchpad.net/python-distutils-extra/")
3716 (synopsis "Enhancements to Python's distutils")
3718 "The python-distutils-extra module enables you to easily integrate
3719 gettext support, themed icons, and scrollkeeper-based documentation into
3720 Python's distutils.")
3721 (license license:gpl2)))
3723 (define-public python2-distutils-extra
3724 (package-with-python2 python-distutils-extra))
3726 (define-public python2-elib.intl
3728 (name "python2-elib.intl")
3732 ;; This project doesn't tag releases or publish tarballs, so we take
3733 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
3736 (url "https://github.com/dieterv/elib.intl.git")
3737 (commit "d09997cfef")))
3738 (file-name (string-append name "-" version "-checkout"))
3741 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
3742 (build-system python-build-system)
3744 ;; incompatible with Python 3 (exception syntax)
3745 `(#:python ,python-2
3747 (home-page "https://github.com/dieterv/elib.intl")
3748 (synopsis "Enhanced internationalization for Python")
3750 "The elib.intl module provides enhanced internationalization (I18N)
3751 services for your Python modules and applications.")
3752 (license license:lgpl3+)))
3754 (define-public python-olefile
3756 (name "python-olefile")
3761 (uri (string-append "https://github.com/decalage2/olefile/archive/v"
3763 (file-name (string-append name "-" version ".tar.gz"))
3766 "18ai19zwagm6nli14k8bii31ipbab2rp7plrvsm6gmfql551a8ai"))))
3767 (build-system python-build-system)
3769 "https://www.decalage.info/python/olefileio")
3770 (synopsis "Read and write Microsoft OLE2 files.")
3772 "@code{olefile} can parse, read and write Microsoft OLE2 files (Structured
3773 Storage or Compound Document, Microsoft Office). It is an improved version of
3774 the OleFileIO module from PIL, the Python Image Library.")
3775 (license license:bsd-3)))
3777 (define-public python2-olefile
3778 (package-with-python2 python-olefile))
3780 (define-public python-pillow
3782 (name "python-pillow")
3787 (uri (pypi-uri "Pillow" version))
3790 "17waygkhhzjd75kajlfw9v57mbb41lcpg6cvkdijqd7smm76ccsj"))))
3791 (build-system python-build-system)
3793 `(("python-pytest" ,python-pytest)))
3795 `(("freetype" ,freetype)
3798 ("libjpeg" ,libjpeg)
3799 ("openjpeg" ,openjpeg)
3800 ("libtiff" ,libtiff)
3801 ("libwebp" ,libwebp)))
3803 `(("python-olefile" ,python-olefile)))
3806 (modify-phases %standard-phases
3807 (add-after 'unpack 'patch-ldconfig
3809 (substitute* "setup.py"
3810 (("\\['/sbin/ldconfig', '-p'\\]") "['true']"))))
3811 (delete 'check) ; We must run checks after python-pillow is installed.
3812 (add-after 'install 'check-installed
3813 (lambda* (#:key outputs inputs #:allow-other-keys)
3815 (setenv "HOME" (getcwd))
3816 ;; Make installed package available for running the tests.
3817 (add-installed-pythonpath inputs outputs)
3818 (invoke "python" "selftest.py" "--installed")
3819 (invoke "python" "-m" "pytest" "-vv")))))))
3820 (home-page "https://python-pillow.org")
3821 (synopsis "Fork of the Python Imaging Library")
3823 "The Python Imaging Library adds image processing capabilities to your
3824 Python interpreter. This library provides extensive file format support, an
3825 efficient internal representation, and fairly powerful image processing
3826 capabilities. The core image library is designed for fast access to data
3827 stored in a few basic pixel formats. It should provide a solid foundation for
3828 a general image processing tool.")
3829 (license (license:x11-style
3830 "http://www.pythonware.com/products/pil/license.htm"
3831 "The PIL Software License"))))
3833 (define-public python2-pillow
3834 (package-with-python2 python-pillow))
3836 (define-public python-pycparser
3838 (name "python-pycparser")
3843 (uri (pypi-uri "pycparser" version))
3846 "09mjyw82ibqzl449g7swy8bfxnfpmas0815d2rkdjlcqw81wma4r"))))
3847 (outputs '("out" "doc"))
3848 (build-system python-build-system)
3850 `(("pkg-config" ,pkg-config)))
3853 (modify-phases %standard-phases
3856 (with-directory-excursion "tests"
3857 (invoke "python" "all_tests.py"))
3859 (add-after 'install 'install-doc
3860 (lambda* (#:key outputs #:allow-other-keys)
3861 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3862 (doc (string-append data "/doc/" ,name "-" ,version))
3863 (examples (string-append doc "/examples")))
3865 (for-each (lambda (file)
3866 (copy-file (string-append "." file)
3867 (string-append doc file)))
3868 '("/README.rst" "/CHANGES" "/LICENSE"))
3869 (copy-recursively "examples" examples)))))))
3870 (home-page "https://github.com/eliben/pycparser")
3871 (synopsis "C parser in Python")
3873 "Pycparser is a complete parser of the C language, written in pure Python
3874 using the PLY parsing library. It parses C code into an AST and can serve as
3875 a front-end for C compilers or analysis tools.")
3876 (license license:bsd-3)))
3878 (define-public python2-pycparser
3879 (package-with-python2 python-pycparser))
3881 (define-public python-pywavelets
3883 (name "python-pywavelets")
3885 (home-page "https://github.com/PyWavelets/pywt")
3888 (uri (pypi-uri "PyWavelets" version))
3891 "1p3qv2v66ghnqrb1f98wyyhp9dz71jwcd6kfpsax65sfdpiyqp1w"))))
3892 (build-system python-build-system)
3894 '(#:modules ((ice-9 ftw)
3898 (guix build python-build-system))
3899 #:phases (modify-phases %standard-phases
3902 (let ((cwd (getcwd))
3903 (libdir (find (cut string-prefix? "lib." <>)
3904 (scandir "build"))))
3905 (with-directory-excursion (string-append cwd "/build/" libdir)
3906 (invoke "nosetests" "-v" "."))))))))
3908 `(("python-matplotlib" ,python-matplotlib) ;for tests
3909 ("python-nose" ,python-nose)))
3911 `(("python-numpy" ,python-numpy)))
3912 (synopsis "Wavelet transforms in Python")
3914 "PyWavelets is a library for wavelet transforms in Python. Wavelets are
3915 mathematical basis functions that are localized in both time and frequency.
3916 Wavelet transforms are time-frequency transforms employing wavelets. They are
3917 similar to Fourier transforms, the difference being that Fourier transforms are
3918 localized only in frequency instead of in time and frequency.")
3919 (license license:expat)))
3921 (define-public python2-pywavelets
3922 (package-with-python2 python-pywavelets))
3924 (define-public python-xcffib
3926 (name "python-xcffib")
3931 (uri (pypi-uri "xcffib" version))
3934 "04k91yxyb3pgc5lvxmivh8w71yjrap2g57yk3s73x4rm4nvjq51n"))))
3935 (build-system python-build-system)
3937 `(("libxcb" ,libxcb)))
3939 `(("python-cffi" ,python-cffi) ; used at run time
3940 ("python-six" ,python-six)))
3942 `(;; FIXME: Tests need more work. See ".travis.yml" in the repository.
3945 (modify-phases %standard-phases
3946 (add-after 'unpack 'fix-libxcb-path
3947 (lambda* (#:key inputs #:allow-other-keys)
3948 (let ((libxcb (assoc-ref inputs "libxcb")))
3949 (substitute* '("xcffib/__init__.py")
3950 (("^soname = \"") (string-append "soname = \"" libxcb "/lib/")))
3952 (add-after 'install 'install-doc
3953 (lambda* (#:key outputs #:allow-other-keys)
3954 (let ((doc (string-append (assoc-ref outputs "out") "/share"
3955 "/doc/" ,name "-" ,version)))
3957 (copy-file "README.md"
3958 (string-append doc "/README.md"))
3960 (home-page "https://github.com/tych0/xcffib")
3961 (synopsis "XCB Python bindings")
3963 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
3964 support for Python 3 and PyPy. It is based on cffi.")
3965 (license license:expat)))
3967 (define-public python2-xcffib
3968 (package-with-python2 python-xcffib))
3970 (define-public python-cairocffi
3972 (name "python-cairocffi")
3977 (uri (pypi-uri "cairocffi" version))
3980 "0dq3k4zhqd8cwsf3nyjqvjqm8wkvrjn1wjf44rl3v0h8kqx6qf0m"))
3981 (patches (search-patches "python-cairocffi-dlopen-path.patch"))))
3982 (build-system python-build-system)
3983 (outputs '("out" "doc"))
3987 ("gdk-pixbuf" ,gdk-pixbuf)
3991 `(("pkg-config" ,pkg-config)
3992 ("python-pytest" ,python-pytest)
3993 ("python-pytest-cov" ,python-pytest-cov)
3994 ("python-pytest-runner" ,python-pytest-runner)
3995 ("python-sphinx" ,python-sphinx)
3996 ("python-docutils" ,python-docutils)))
3998 `(("python-xcffib" ,python-xcffib))) ; used at run time
4001 (modify-phases %standard-phases
4002 (add-after 'unpack 'patch-paths
4003 (lambda* (#:key inputs outputs #:allow-other-keys)
4004 (substitute* (find-files "." "\\.py$")
4005 (("dlopen\\(ffi, 'cairo'")
4006 (string-append "dlopen(ffi, '" (assoc-ref inputs "cairo")
4007 "/lib/libcairo.so.2'"))
4008 (("dlopen\\(ffi, 'gdk-3'")
4009 (string-append "dlopen(ffi, '" (assoc-ref inputs "gtk+")
4010 "/lib/libgtk-3.so.0'"))
4011 (("dlopen\\(ffi, 'gdk_pixbuf-2.0'")
4012 (string-append "dlopen(ffi, '" (assoc-ref inputs "gdk-pixbuf")
4013 "/lib/libgdk_pixbuf-2.0.so.0'"))
4014 (("dlopen\\(ffi, 'glib-2.0'")
4015 (string-append "dlopen(ffi, '" (assoc-ref inputs "glib")
4016 "/lib/libglib-2.0.so.0'"))
4017 (("dlopen\\(ffi, 'gobject-2.0'")
4018 (string-append "dlopen(ffi, '" (assoc-ref inputs "glib")
4019 "/lib/libgobject-2.0.so.0'"))
4020 (("dlopen\\(ffi, 'pangocairo-1.0'")
4021 (string-append "dlopen(ffi, '" (assoc-ref inputs "pango")
4022 "/lib/libpangocairo-1.0.so.0'"))
4023 (("dlopen\\(ffi, 'pango-1.0'")
4024 (string-append "dlopen(ffi, '" (assoc-ref inputs "pango")
4025 "/lib/libpango-1.0.so.0'")))
4027 (add-after 'install 'install-doc
4028 (lambda* (#:key inputs outputs #:allow-other-keys)
4029 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4030 (doc (string-append data "/doc/" ,name "-" ,version))
4031 (html (string-append doc "/html")))
4032 (setenv "LD_LIBRARY_PATH"
4033 (string-append (assoc-ref inputs "cairo") "/lib" ":"
4034 (assoc-ref inputs "gdk-pixbuf") "/lib"))
4035 (setenv "LANG" "en_US.UTF-8")
4037 (for-each (lambda (file)
4038 (copy-file (string-append "." file)
4039 (string-append doc file)))
4040 '("/README.rst" "/CHANGES" "/LICENSE"))
4041 (system* "python" "setup.py" "build_sphinx")
4042 (copy-recursively "docs/_build/html" html)
4044 (home-page "https://github.com/Kozea/cairocffi")
4045 (synopsis "Python bindings and object-oriented API for Cairo")
4047 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
4048 Python bindings and object-oriented API for cairo. Cairo is a 2D vector
4049 graphics library with support for multiple backends including image buffers,
4050 PNG, PostScript, PDF, and SVG file output.")
4051 (license license:bsd-3)))
4053 (define-public python2-cairocffi
4054 (package-with-python2 python-cairocffi))
4056 (define-public python-decorator
4058 (name "python-decorator")
4063 (uri (pypi-uri "decorator" version))
4065 (base32 "0308djallnh00v112y5b7nadl657ysmkp6vc8xn51d6yzc9zm7n3"))))
4066 (build-system python-build-system)
4067 (home-page "https://pypi.python.org/pypi/decorator/")
4068 (synopsis "Python module to simplify usage of decorators")
4070 "The aim of the decorator module is to simplify the usage of decorators
4071 for the average programmer, and to popularize decorators usage giving examples
4072 of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
4073 etc. The core of this module is a decorator factory.")
4074 (license license:expat)))
4076 (define-public python2-decorator
4077 (package-with-python2 python-decorator))
4079 (define-public python-drmaa
4081 (name "python-drmaa")
4086 (uri (pypi-uri "drmaa" version))
4088 (base32 "0xzqriqyvk5b8hszbavsyxd29wm3sxirm8zvvdm73rs2iq7w4hkx"))))
4089 (build-system python-build-system)
4090 ;; The test suite requires libdrmaa which is provided by the cluster
4091 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
4092 ;; should be set to the path of the libdrmaa library.
4093 (arguments '(#:tests? #f))
4095 `(("python-nose" ,python-nose)))
4096 (home-page "https://pypi.python.org/pypi/drmaa")
4097 (synopsis "Python bindings for the DRMAA library")
4099 "A Python package for Distributed Resource Management (DRM) job
4100 submission and control. This package is an implementation of the DRMAA 1.0
4101 Python language binding specification.")
4102 (license license:bsd-3)))
4104 (define-public python2-drmaa
4105 (package-with-python2 python-drmaa))
4107 (define-public python-grako
4109 (name "python-grako")
4115 (pypi-uri "grako" version ".zip"))
4118 "0r63i68wcnv63rfjkasq1ah81frz61a6mzbcnaxhrkdpx84p7hzw"))))
4119 (build-system python-build-system)
4120 (arguments '(#:tests? #f)) ; Test file 'grako.ebnf' is missing from archive.
4123 ("python-pytest" ,python-pytest)
4124 ("python-pytest-runner" ,python-pytest-runner)))
4125 (home-page "https://bitbucket.org/neogeny/grako")
4126 (synopsis "EBNF parser generator")
4128 "Grako takes a grammar in a variation of EBNF as input, and outputs a
4129 memoizing PEG/Packrat parser in Python.")
4130 (license license:bsd-3)))
4132 (define-public python2-grako
4133 (package-with-python2 python-grako))
4135 (define-public python-gridmap
4137 (name "python-gridmap")
4143 "https://github.com/pygridtools/gridmap/archive/v"
4145 (file-name (string-append name "-" version ".tar.gz"))
4147 (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x"))))
4148 (build-system python-build-system)
4150 '(#:tests? #f)) ; FIXME: Requires python-cherrypy.
4152 `(("python-psutil" ,python-psutil)
4153 ("python-drmaa" ,python-drmaa)
4154 ("python-pyzmq" ,python-pyzmq)))
4155 (home-page "https://github.com/pygridtools/gridmap")
4156 (synopsis "Create jobs on a cluster directly from Python")
4158 "Gridmap is a Python package to allow you to easily create jobs on the
4159 cluster directly from Python. You can directly map Python functions onto the
4160 cluster without needing to write any wrapper code yourself.")
4161 (license license:gpl3+)))
4163 (define-public python2-gridmap
4164 (package-with-python2 python-gridmap))
4166 (define-public python-honcho
4168 (name "python-honcho")
4174 "https://github.com/nickstenning/honcho/archive/v"
4176 (file-name (string-append name "-" version ".tar.gz"))
4178 (base32 "0zizn61n5z5hq421hkypk9pw8s6fpxw30f4hsg7k4ivwzy3gjw9j"))))
4179 (build-system python-build-system)
4181 `(("python-pytest" ,python-pytest)
4182 ("python-mock" ,python-mock)
4183 ("python-tox" ,python-tox)
4184 ("which" ,which))) ;for tests
4186 `(("python-jinja2" ,python-jinja2)))
4189 (modify-phases %standard-phases
4191 (add-after 'install 'check
4192 (lambda* (#:key outputs inputs #:allow-other-keys)
4193 ;; fix honcho path in testsuite
4194 (substitute* "tests/conftest.py"
4195 (("'honcho'") (string-append "'" (assoc-ref outputs "out")
4196 "/bin/honcho" "'")))
4197 ;; It's easier to run tests after install.
4198 ;; Make installed package available for running the tests
4199 (add-installed-pythonpath inputs outputs)
4200 (invoke "py.test" "-v"))))))
4201 (home-page "https://github.com/nickstenning/honcho")
4202 (synopsis "Manage Procfile-based applications")
4204 "A Procfile is a file which describes how to run an application
4205 consisting of serveral processes. honcho starts all listed processes.
4206 The output of all running processes is collected by honcho and
4208 (license license:expat)))
4210 (define-public python2-honcho
4211 (package-with-python2 python-honcho))
4213 (define-public python-pexpect
4215 (name "python-pexpect")
4220 (uri (pypi-uri "pexpect" version))
4222 (base32 "1fla85g47iaxxpjhp9vkxdnv4pgc7rplfy6ja491smrrk0jqi3ia"))))
4223 (build-system python-build-system)
4226 (modify-phases %standard-phases
4227 (add-before 'check 'prepare-tests
4229 (substitute* (find-files "tests")
4230 (("/bin/ls") (which "ls"))
4231 (("/bin/echo") (which "echo"))
4232 (("/bin/which") (which "which"))
4233 ;; Many tests try to use the /bin directory which
4234 ;; is not present in the build environment.
4235 ;; Use one that's non-empty and unlikely to change.
4236 (("/bin'") "/dev'"))
4237 ;; XXX: Socket connection test gets "Connection reset by peer".
4238 ;; Why does it not work? Delete for now.
4239 (delete-file "tests/test_socket.py")
4241 (replace 'check (lambda _ (invoke "nosetests" "-v"))))))
4243 `(("python-nose" ,python-nose)
4244 ("python-pytest" ,python-pytest)
4247 ("bash-full" ,bash))) ;full Bash for 'test_replwrap.py'
4249 `(("python-ptyprocess" ,python-ptyprocess)))
4250 (home-page "http://pexpect.readthedocs.org/")
4251 (synopsis "Controlling interactive console applications")
4253 "Pexpect is a pure Python module for spawning child applications;
4254 controlling them; and responding to expected patterns in their output.
4255 Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4256 child application and control it as if a human were typing commands.")
4257 (license license:isc)))
4259 (define-public python2-pexpect
4260 (package-with-python2 python-pexpect))
4262 (define-public python-setuptools-scm
4264 (name "python-setuptools-scm")
4268 (uri (pypi-uri "setuptools_scm" version))
4271 "0h4bglwfz8b9prqljv8z3w9rgydfyxzaj05bm1y6zs5m6shz548i"))))
4272 (build-system python-build-system)
4273 (home-page "https://github.com/pypa/setuptools_scm/")
4274 (synopsis "Manage Python package versions in SCM metadata")
4276 "Setuptools_scm handles managing your Python package versions in
4277 @dfn{software configuration management} (SCM) metadata instead of declaring
4278 them as the version argument or in a SCM managed file.")
4279 (license license:expat)))
4281 (define-public python2-setuptools-scm
4282 (package-with-python2 python-setuptools-scm))
4284 (define-public python-pathpy
4286 (name "python-pathpy")
4291 (uri (pypi-uri "path.py" version))
4293 (base32 "07x15v8c7ry9bvycw294c9yq6ky9v2b0dalvgi6rn38ilh69vsz7"))))
4294 ;; (outputs '("out" "doc"))
4295 (build-system python-build-system)
4297 `(("python-appdirs" ,python-appdirs)))
4299 `(("python-setuptools-scm" ,python-setuptools-scm)
4300 ("python-sphinx" ,python-sphinx)
4301 ("python-rst.linker" ,python-rst.linker)
4302 ("python-pytest" ,python-pytest)
4303 ("python-pytest-runner" ,python-pytest-runner)))
4305 ;; FIXME: Documentation and tests require "jaraco.packaging".
4308 ;; (modify-phases %standard-phases
4309 ;; (add-after 'build 'build-doc
4311 ;; (setenv "LANG" "en_US.UTF-8")
4312 ;; (zero? (system* "python" "setup.py" "build_sphinx"))))
4313 ;; (add-after 'install 'install-doc
4314 ;; (lambda* (#:key outputs #:allow-other-keys)
4315 ;; (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4316 ;; (doc (string-append data "/doc/" ,name "-" ,version))
4317 ;; (html (string-append doc "/html")))
4319 ;; (for-each (lambda (file)
4320 ;; (copy-file file (string-append doc "/" file)))
4321 ;; '("README.rst" "CHANGES.rst"))
4322 ;; (copy-recursively "build/sphinx/html" html)))))))
4323 (home-page "https://github.com/jaraco/path.py")
4324 (synopsis "Python module wrapper for built-in os.path")
4326 "@code{path.py} implements path objects as first-class entities, allowing
4327 common operations on files to be invoked on those path objects directly.")
4328 (license license:expat)))
4330 (define-public python2-pathpy
4331 (package-with-python2 python-pathpy))
4333 (define-public python-simplegeneric
4335 (name "python-simplegeneric")
4340 (uri (pypi-uri "simplegeneric" version ".zip"))
4342 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
4343 (build-system python-build-system)
4345 `(("unzip" ,unzip)))
4346 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
4347 (synopsis "Python module for simple generic functions")
4349 "The simplegeneric module lets you define simple single-dispatch generic
4350 functions, akin to Python’s built-in generic functions like @code{len()},
4351 @code{iter()} and so on. However, instead of using specially-named methods,
4352 these generic functions use simple lookup tables, akin to those used by
4353 e.g. @code{pickle.dump()} and other generic functions found in the Python
4355 (license license:zpl2.1)))
4357 (define-public python2-simplegeneric
4358 (package-with-python2 python-simplegeneric))
4360 (define-public python-ipython-genutils
4361 ;; TODO: This package is retired, check if can be removed, see description.
4363 (name "python-ipython-genutils")
4368 (uri (pypi-uri "ipython_genutils" version))
4370 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
4371 (build-system python-build-system)
4372 (arguments `(#:tests? #f)) ; no tests
4373 (home-page "https://ipython.org")
4374 (synopsis "Vestigial utilities from IPython")
4376 "This package provides retired utilities from IPython. No packages
4377 outside IPython/Jupyter should depend on it.
4379 This package shouldn't exist. It contains some common utilities shared by
4380 Jupyter and IPython projects during The Big Split. As soon as possible, those
4381 packages will remove their dependency on this, and this package will go
4383 (license license:bsd-3)))
4385 (define-public python2-ipython-genutils
4386 (package-with-python2 python-ipython-genutils))
4388 (define-public python-traitlets
4390 (name "python-traitlets")
4395 (uri (pypi-uri "traitlets" version))
4398 "0dbq7sx26xqz5ixs711k5nc88p8a0nqyz6162pwks5dpcz9d4jww"))))
4399 (build-system python-build-system)
4402 (modify-phases %standard-phases
4403 (replace 'check (lambda _ (invoke "pytest" "-vv" "traitlets"))))))
4405 `(("python-ipython-genutils" ,python-ipython-genutils)
4406 ("python-decorator" ,python-decorator))) ;not needed for >4.3.2
4408 `(("python-pytest" ,python-pytest)))
4409 (properties `((python2-variant . ,(delay python2-traitlets))))
4410 (home-page "https://ipython.org")
4411 (synopsis "Configuration system for Python applications")
4413 "Traitlets is a framework that lets Python classes have attributes with
4414 type checking, dynamically calculated default values, and ‘on change’
4415 callbacks. The package also includes a mechanism to use traitlets for
4416 configuration, loading values from files or from command line arguments. This
4417 is a distinct layer on top of traitlets, so you can use traitlets in your code
4418 without using the configuration machinery.")
4419 (license license:bsd-3)))
4421 (define-public python2-traitlets
4422 (let ((traitlets (package-with-python2 (strip-python2-variant python-traitlets))))
4426 `(("python2-enum34" ,python2-enum34)
4427 ,@(package-propagated-inputs traitlets))))))
4429 (define-public python-jupyter-core
4431 (name "python-jupyter-core")
4436 (uri (string-append (pypi-uri "jupyter_core" version)))
4439 "1dy083rarba8prn9f9srxq3c7n7vyql02ycrqq306c40lr57aw5s"))))
4440 (build-system python-build-system)
4441 ;; FIXME: not sure how to run the tests
4442 (arguments `(#:tests? #f))
4444 `(("python-traitlets" ,python-traitlets)))
4445 (home-page "http://jupyter.org/")
4446 (synopsis "Jupyter base package")
4448 "Jupyter core is the base package on which Jupyter projects rely.")
4449 (license license:bsd-3)))
4451 (define-public python2-jupyter-core
4452 (package-with-python2 python-jupyter-core))
4454 (define-public python-jupyter-client
4456 (name "python-jupyter-client")
4461 (uri (pypi-uri "jupyter_client" version))
4464 "0l9mh7ccrpl3lppym3dnky8n1nk7xarzzdcxf4q2s7aw203cpydm"))))
4465 (build-system python-build-system)
4466 ;; Tests fail because of missing native python kernel which I assume is
4467 ;; provided by the ipython package, which we cannot use because it would
4468 ;; cause a dependency cycle.
4469 (arguments `(#:tests? #f))
4471 `(("python-pyzmq" ,python-pyzmq)
4472 ("python-traitlets" ,python-traitlets)
4473 ("python-jupyter-core" ,python-jupyter-core)))
4474 (home-page "http://jupyter.org/")
4475 (synopsis "Jupyter protocol implementation and client libraries")
4477 "The @code{jupyter_client} package contains the reference implementation
4478 of the Jupyter protocol. It also provides client and kernel management APIs
4479 for working with kernels, and the @code{jupyter kernelspec} entrypoint for
4480 installing @code{kernelspec}s for use with Jupyter frontends.")
4481 (license license:bsd-3)))
4483 (define-public python2-jupyter-client
4484 (package-with-python2 python-jupyter-client))
4486 (define-public python-ipykernel
4488 (name "python-ipykernel")
4493 (uri (pypi-uri "ipykernel" version))
4495 (base32 "0br95qhrd5k65g10djngiy27hs0642301hlf2q142i8djabvzh0g"))))
4496 (build-system python-build-system)
4499 (modify-phases %standard-phases
4502 (setenv "HOME" "/tmp")
4503 (invoke "pytest" "-v")
4506 `(("python-ipython" ,python-ipython)
4507 ;; imported at runtime during connect
4508 ("python-jupyter-client" ,python-jupyter-client)))
4510 `(("python-pytest" ,python-pytest)
4511 ("python-nose" ,python-nose)))
4512 (home-page "https://ipython.org")
4513 (synopsis "IPython Kernel for Jupyter")
4515 "This package provides the IPython kernel for Jupyter.")
4516 (license license:bsd-3)))
4518 (define-public python2-ipykernel
4519 (package-with-python2 python-ipykernel))
4521 ;; This is the latest release of the LTS version of ipython with support for
4522 ;; Python 2.7 and Python 3.x. Later non-LTS versions starting from 6.0 have
4523 ;; dropped support for Python 2.7. We may want to rename this package.
4524 (define-public python-ipython
4526 (name "python-ipython")
4531 (uri (pypi-uri "ipython" version ".tar.gz"))
4533 (base32 "01l93i4hspf0lvhmycvc8j378bslm9rw30mwfspsl6v1ayc69b2b"))))
4534 (build-system python-build-system)
4535 (outputs '("out" "doc"))
4537 `(("python-pyzmq" ,python-pyzmq)
4538 ("python-prompt-toolkit" ,python-prompt-toolkit-1)
4539 ("python-terminado" ,python-terminado)
4540 ("python-matplotlib" ,python-matplotlib)
4541 ("python-numpy" ,python-numpy)
4542 ("python-numpydoc" ,python-numpydoc)
4543 ("python-jinja2" ,python-jinja2)
4544 ("python-mistune" ,python-mistune)
4545 ("python-pexpect" ,python-pexpect)
4546 ("python-pickleshare" ,python-pickleshare)
4547 ("python-simplegeneric" ,python-simplegeneric)
4548 ("python-jsonschema" ,python-jsonschema)
4549 ("python-traitlets" ,python-traitlets)
4550 ("python-nbformat" ,python-nbformat)
4551 ("python-pygments" ,python-pygments)))
4553 `(("readline" ,readline)
4556 `(("graphviz" ,graphviz)
4557 ("pkg-config" ,pkg-config)
4558 ("python-requests" ,python-requests) ;; for tests
4559 ("python-testpath" ,python-testpath)
4560 ("python-nose" ,python-nose)
4561 ("python-sphinx" ,python-sphinx)
4562 ("python-shpinx-rtd-theme" ,python-sphinx-rtd-theme)
4563 ;; FIXME: It's possible that a smaller union would work just as well.
4564 ("texlive" ,(texlive-union (list texlive-fonts-amsfonts
4566 texlive-generic-ifxetex
4567 texlive-generic-pdftex
4568 texlive-latex-amsfonts
4569 texlive-latex-capt-of
4571 texlive-latex-environ
4572 texlive-latex-eqparbox
4573 texlive-latex-etoolbox
4574 texlive-latex-expdlist
4575 texlive-latex-fancyhdr
4576 texlive-latex-fancyvrb
4577 texlive-latex-fncychap
4579 texlive-latex-framed
4580 texlive-latex-geometry
4581 texlive-latex-graphics
4582 texlive-latex-hyperref
4583 texlive-latex-mdwtools
4584 texlive-latex-multirow
4585 texlive-latex-oberdiek
4586 texlive-latex-parskip
4587 texlive-latex-preview
4588 texlive-latex-tabulary
4589 texlive-latex-threeparttable
4590 texlive-latex-titlesec
4591 texlive-latex-trimspaces
4593 texlive-latex-upquote
4595 texlive-latex-varwidth
4596 texlive-latex-wrapfig)))
4597 ("texinfo" ,texinfo)))
4600 (modify-phases %standard-phases
4601 (add-after 'install 'install-doc
4602 (lambda* (#:key inputs outputs #:allow-other-keys)
4603 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4604 (doc (string-append data "/doc/" ,name "-" ,version))
4605 (html (string-append doc "/html"))
4606 (man1 (string-append data "/man/man1"))
4607 (info (string-append data "/info"))
4608 (examples (string-append doc "/examples"))
4609 (python-arg (string-append "PYTHON=" (which "python"))))
4610 (setenv "LANG" "en_US.utf8")
4611 ;; Make installed package available for running the tests
4612 (add-installed-pythonpath inputs outputs)
4613 (with-directory-excursion "docs"
4614 ;; FIXME: pdf fails to build
4615 ;;(system* "make" "pdf" "PAPER=a4")
4616 (system* "make" python-arg "html")
4617 (system* "make" python-arg "info"))
4618 (copy-recursively "docs/man" man1)
4619 (copy-recursively "examples" examples)
4620 (copy-recursively "docs/build/html" html)
4621 ;; (copy-file "docs/build/latex/ipython.pdf"
4622 ;; (string-append doc "/ipython.pdf"))
4624 (copy-file "docs/build/texinfo/ipython.info"
4625 (string-append info "/ipython.info"))
4626 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))
4628 ;; Tests can only be run after the library has been installed and not
4629 ;; within the source directory.
4631 (add-after 'install 'check
4632 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
4635 ;; Make installed package available for running the tests
4636 (add-installed-pythonpath inputs outputs)
4637 (setenv "HOME" "/tmp/") ;; required by a test
4638 ;; We only test the core because one of the other tests
4639 ;; tries to import ipykernel.
4640 (invoke "python" "IPython/testing/iptest.py"
4641 "-v" "IPython/core/tests"))
4643 (add-before 'check 'fix-tests
4644 (lambda* (#:key inputs #:allow-other-keys)
4645 (substitute* "./IPython/utils/_process_posix.py"
4646 (("/usr/bin/env', 'which") (which "which")))
4647 (substitute* "./IPython/core/tests/test_inputtransformer.py"
4648 (("#!/usr/bin/env python")
4649 (string-append "#!" (which "python"))))
4650 ;; Disable 1 failing test
4651 (substitute* "./IPython/core/tests/test_magic.py"
4652 (("def test_dirops\\(\\):" all)
4653 (string-append "@dec.skipif(True)\n" all)))
4654 ;; This test introduces a circular dependency on ipykernel
4655 ;; (which depends on ipython).
4656 (delete-file "IPython/core/tests/test_display.py")
4657 ;; These tests throw errors for unknown reasons.
4658 (delete-file "IPython/extensions/tests/test_storemagic.py")
4659 (delete-file "IPython/core/tests/test_displayhook.py")
4660 (delete-file "IPython/core/tests/test_interactiveshell.py")
4661 (delete-file "IPython/core/tests/test_pylabtools.py")
4662 (delete-file "IPython/core/tests/test_paths.py")
4664 (home-page "https://ipython.org")
4665 (synopsis "IPython is a tool for interactive computing in Python")
4667 "IPython provides a rich architecture for interactive computing with:
4668 Powerful interactive shells, a browser-based notebook, support for interactive
4669 data visualization, embeddable interpreters and tools for parallel
4671 (license license:bsd-3)
4672 (properties `((python2-variant . ,(delay python2-ipython))))))
4674 (define-public python2-ipython
4675 (let ((ipython (package-with-python2 (strip-python2-variant python-ipython))))
4678 ;; FIXME: add pyreadline once available.
4680 `(("python2-backports-shutil-get-terminal-size"
4681 ,python2-backports-shutil-get-terminal-size)
4682 ("python2-pathlib2" ,python2-pathlib2)
4683 ,@(package-propagated-inputs ipython)))
4685 `(("python2-mock" ,python2-mock)
4686 ,@(package-native-inputs ipython))))))
4688 (define-public python-urwid
4690 (name "python-urwid")
4695 (uri (pypi-uri "urwid" version))
4698 "1g6cpicybvbananpjikmjk8npmjk4xvak1wjzji62wc600wkwkb4"))))
4699 (build-system python-build-system)
4700 (home-page "http://urwid.org")
4701 (synopsis "Console user interface library for Python")
4703 "Urwid is a curses-based UI/widget library for Python. It includes many
4704 features useful for text console applications.")
4705 (license license:lgpl2.1+)))
4707 (define-public python2-urwid
4708 (package-with-python2 python-urwid))
4710 (define-public python-urwidtrees
4712 (name "python-urwidtrees")
4717 ;; package author intends on distributing via github rather than pypi:
4718 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
4719 (uri (string-append "https://github.com/pazz/urwidtrees/archive/"
4721 (file-name (string-append name "-" version ".tar.gz"))
4724 "0d30lyd3s2a97rhqfax5w9ssqds2z6aydqx3c6j2c2lk3cb4ngvh"))))
4725 (build-system python-build-system)
4727 '(#:tests? #f)) ; no tests
4728 (propagated-inputs `(("python-urwid" ,python-urwid)))
4729 (home-page "https://github.com/pazz/urwidtrees")
4730 (synopsis "Tree widgets for urwid")
4731 (description "Urwidtrees is a Widget Container API for the @code{urwid}
4732 toolkit. Use it to build trees of widgets.")
4733 (license license:gpl3+)))
4735 (define-public python2-urwidtrees
4736 (package-with-python2 python-urwidtrees))
4738 (define-public python-ua-parser
4740 (name "python-ua-parser")
4745 (uri (pypi-uri "ua-parser" version))
4748 "1jwdf58rhchjzzrad405pviv0iq24xa2xmmmdgcm2c8s6b4wzfwp"))))
4749 (build-system python-build-system)
4751 `(#:tests? #f)) ;no test suite in release
4753 `(("python-pyyaml" ,python-pyyaml)))
4754 (home-page "https://github.com/ua-parser/uap-python")
4755 (synopsis "User agent parser")
4757 "@code{ua-parser} is a Python port of Browserscope's user agent parser.")
4758 (license license:asl2.0)))
4760 (define-public python2-ua-parser
4761 (package-with-python2 python-ua-parser))
4763 (define-public python-user-agents
4765 (name "python-user-agents")
4770 (uri (pypi-uri "user-agents" version))
4773 "0fc00cd3j8dahq1zzn8pkgfgd7lq37bp2scmdma2n1c049vicgb4"))))
4774 (build-system python-build-system)
4776 `(#:tests? #f)) ;missing devices.json test file in release
4778 `(("python-ua-parser" ,python-ua-parser)))
4779 (home-page "https://github.com/selwin/python-user-agents")
4780 (synopsis "User Agent strings parsing library")
4782 "A library to identify devices (phones, tablets) and their capabilities by
4783 parsing (browser/HTTP) user agent strings.")
4784 (license license:expat)))
4786 (define-public python2-user-agents
4787 (package-with-python2 python-user-agents))
4789 (define-public python-dbus
4791 (name "python-dbus")
4796 (uri (string-append "https://dbus.freedesktop.org/releases/dbus-python/"
4797 "dbus-python-" version ".tar.gz"))
4800 "0vvvjmiwnc9cjlks3gcdk43ap7llhlpz7cm1wbw0nc2yfsxjpwdb"))))
4801 (build-system gnu-build-system)
4804 (modify-phases %standard-phases
4808 ;; XXX: For the missing '/etc/machine-id'.
4809 (substitute* "test/run-test.sh"
4810 (("DBUS_FATAL_WARNINGS=1")
4811 "DBUS_FATAL_WARNINGS=0"))
4814 `(("pkg-config" ,pkg-config)))
4816 `(("python" ,python-wrapper)
4817 ("dbus-glib" ,dbus-glib)))
4818 (synopsis "Python bindings for D-bus")
4819 (description "python-dbus provides bindings for libdbus, the reference
4820 implementation of D-Bus.")
4821 (home-page "https://www.freedesktop.org/wiki/Software/DBusBindings/")
4822 (license license:expat)))
4824 (define-public python2-dbus
4825 (package (inherit python-dbus)
4826 (name "python2-dbus")
4827 (inputs `(("python" ,python-2)
4828 ,@(alist-delete "python"
4829 (package-inputs python-dbus)
4831 ;; FIXME: on Python 2, the test_utf8 fails with:
4832 ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)"
4833 (arguments `(#:tests? #f))))
4835 (define-public python-lxml
4837 (name "python-lxml")
4842 (uri (pypi-uri "lxml" version))
4845 "0zw0y9hs0nflxhl9cs6ipwwh53szi3w2x06wl0k9cylyqac0cwin"))))
4846 (build-system python-build-system)
4848 `(("libxml2" ,libxml2)
4849 ("libxslt" ,libxslt)))
4850 (home-page "http://lxml.de/")
4852 "Python XML processing library")
4854 "The lxml XML toolkit is a Pythonic binding for the C libraries
4855 libxml2 and libxslt.")
4856 (license license:bsd-3))) ; and a few more, see LICENSES.txt
4858 (define-public python2-lxml
4859 (package-with-python2 python-lxml))
4861 ;; beautifulsoup4 has a totally different namespace than 3.x,
4862 ;; and pypi seems to put it under its own name, so I guess we should too
4863 (define-public python-beautifulsoup4
4865 (name "python-beautifulsoup4")
4870 (uri (pypi-uri "beautifulsoup4" version))
4873 "041dhalzjciw6qyzzq7a2k4h1yvyk76xigp35hv5ibnn448ydy4h"))))
4874 (build-system python-build-system)
4877 (modify-phases %standard-phases
4878 ;; The Python 2 source is the definitive source of beautifulsoup4. We
4879 ;; must use this conversion script when building with Python 3. The
4880 ;; conversion script also runs the tests.
4881 ;; For more information, see the file 'convert-py3k' in the source
4884 (lambda _ (invoke "./convert-py3k"))))))
4886 "https://www.crummy.com/software/BeautifulSoup/bs4/")
4888 "Python screen-scraping library")
4890 "Beautiful Soup is a Python library designed for rapidly setting up
4891 screen-scraping projects. It offers Pythonic idioms for navigating,
4892 searching, and modifying a parse tree, providing a toolkit for
4893 dissecting a document and extracting what you need. It automatically
4894 converts incoming documents to Unicode and outgoing documents to UTF-8.")
4895 (license license:expat)
4896 (properties `((python2-variant . ,(delay python2-beautifulsoup4))))))
4898 (define-public python2-beautifulsoup4
4900 (inherit (package-with-python2
4901 (strip-python2-variant python-beautifulsoup4)))
4902 (arguments `(#:python ,python-2))))
4904 (define-public python-netifaces
4906 (name "python-netifaces")
4911 (uri (pypi-uri "netifaces" version))
4914 "1gccklrcplbbqh81g1mdgpa5y8na7kkf29cq2ka3f5a2fp5hyndx"))))
4915 (build-system python-build-system)
4916 (home-page "https://github.com/al45tair/netifaces")
4918 "Python module for portable network interface information")
4920 "Netifaces is a Python module providing information on network
4921 interfaces in an easy and portable manner.")
4922 (license license:expat)))
4924 (define-public python2-netifaces
4925 (package-with-python2 python-netifaces))
4927 (define-public python-networkx
4929 (name "python-networkx")
4934 (uri (pypi-uri "networkx" version ".zip"))
4936 (base32 "12swxb15299v9vqjsq4z8rgh5sdhvpx497xwnhpnb0gynrx6zra5"))))
4937 (build-system python-build-system)
4938 ;; python-decorator is needed at runtime.
4940 `(("python-decorator" ,python-decorator)))
4942 `(("python-nose" ,python-nose)
4944 (home-page "https://networkx.github.io/")
4945 (synopsis "Python module for creating and manipulating graphs and networks")
4947 "NetworkX is a Python package for the creation, manipulation, and study
4948 of the structure, dynamics, and functions of complex networks.")
4949 (license license:bsd-3)))
4951 (define-public python2-networkx
4952 (package-with-python2 python-networkx))
4954 (define-public python-datrie
4956 (name "python-datrie")
4961 (uri (pypi-uri "datrie" version))
4964 "08r0if7dry2q7p34gf7ffyrlnf4bdvnprxgydlfxgfnvq8f3f4bs"))))
4965 (build-system python-build-system)
4967 `(#:phases (modify-phases %standard-phases
4968 (add-before 'build 'cythonize
4970 ;; Regenerate Cython classes to solve ABI issues with Python
4971 ;; 3.7.0. See <https://github.com/pytries/datrie/issues/52>.
4972 (invoke "cython" "src/datrie.pyx" "src/cdatrie.pxd"
4973 "src/stdio_ext.pxd" "-a"))))))
4975 `(("python-cython" ,python-cython)
4976 ("python-hypothesis" ,python-hypothesis)
4977 ("python-pytest" ,python-pytest)
4978 ("python-pytest-runner" ,python-pytest-runner)))
4979 (home-page "https://github.com/kmike/datrie")
4980 (synopsis "Fast, efficiently stored trie for Python")
4982 "This package provides a fast, efficiently stored trie implementation for
4984 (license license:lgpl2.1+)))
4986 (define-public snakemake
4993 (uri (pypi-uri "snakemake" version))
4995 (base32 "0gj0xxgiq3mp9qyyrbfzldiaq1giliqw0in64nqiz7vx49myqj7z"))))
4996 (build-system python-build-system)
4998 ;; TODO: Package missing test dependencies.
5001 (modify-phases %standard-phases
5002 ;; For cluster execution Snakemake will call Python. Since there is
5003 ;; no suitable PYTHONPATH set, cluster execution will fail. We fix
5004 ;; this by calling the snakemake wrapper instead.
5005 (add-after 'unpack 'call-wrapper-not-wrapped-snakemake
5006 (lambda* (#:key outputs #:allow-other-keys)
5007 (substitute* "snakemake/executors.py"
5008 (("\\{sys.executable\\} -m snakemake")
5009 (string-append (assoc-ref outputs "out")
5013 `(("python-gitpython" ,python-gitpython)
5014 ("python-wrapt" ,python-wrapt)
5015 ("python-requests" ,python-requests)
5016 ("python-appdirs" ,python-appdirs)
5017 ("python-configargparse" ,python-configargparse)
5018 ("python-datrie" ,python-datrie)
5019 ("python-docutils" ,python-docutils)
5020 ("python-jinja2" ,python-jinja2)
5021 ("python-jsonschema" ,python-jsonschema)
5022 ("python-networkx" ,python-networkx)
5023 ("python-pyyaml" ,python-pyyaml)
5024 ("python-ratelimiter" ,python-ratelimiter)))
5025 (home-page "https://snakemake.readthedocs.io")
5026 (synopsis "Python-based execution environment for make-like workflows")
5028 "Snakemake aims to reduce the complexity of creating workflows by
5029 providing a clean and modern domain specific specification language (DSL) in
5030 Python style, together with a fast and comfortable execution environment.")
5031 (license license:expat)))
5033 ;; This is currently needed for the pigx-* packages.
5034 (define-public snakemake-4
5035 (package (inherit snakemake)
5040 (uri (pypi-uri "snakemake" version))
5042 (base32 "0g0paia4z7w3srnqdmavq3hrb2x7qnpf81jx50njl0p7y4y0j8jv"))))
5044 `(("python-wrapt" ,python-wrapt)
5045 ("python-requests" ,python-requests)
5046 ("python-appdirs" ,python-appdirs)
5047 ("python-configargparse" ,python-configargparse)
5048 ("python-pyyaml" ,python-pyyaml)
5049 ("python-ratelimiter" ,python-ratelimiter)))))
5051 (define-public python-pyqrcode
5053 (name "python-pyqrcode")
5058 (uri (pypi-uri "PyQRCode" version))
5061 "1m9ln8k9v7dfbh1i81225hx5mdsh8mpf9g7r4wpbfmiyfcs7dgzx"))))
5062 (build-system python-build-system)
5064 "https://github.com/mnooner256/pyqrcode")
5065 (synopsis "QR code generator")
5067 "Pyqrcode is a QR code generator written purely in Python with
5068 SVG, EPS, PNG and terminal output.")
5069 (license license:bsd-3)))
5071 (define-public python-seaborn
5073 (name "python-seaborn")
5078 (uri (pypi-uri "seaborn" version))
5080 (base32 "0bqysi3fxfjl1866m5jq8z7mynhqbqnikim74dmzn8539iwkzj3n"))))
5081 (build-system python-build-system)
5084 (modify-phases %standard-phases
5085 (add-before 'check 'start-xserver
5086 (lambda* (#:key inputs #:allow-other-keys)
5087 (let ((xorg-server (assoc-ref inputs "xorg-server")))
5088 ;; There must be a running X server and make check doesn't
5089 ;; start one. Therefore we must do it.
5090 (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
5091 (setenv "DISPLAY" ":1")
5093 (replace 'check (lambda _ (invoke "pytest" "seaborn") #t)))))
5095 `(("python-pandas" ,python-pandas)
5096 ("python-matplotlib" ,python-matplotlib)
5097 ("python-numpy" ,python-numpy)
5098 ("python-scipy" ,python-scipy)))
5100 `(("python-pytest" ,python-pytest)
5101 ("xorg-server" ,xorg-server)))
5102 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
5103 (synopsis "Statistical data visualization")
5105 "Seaborn is a library for making attractive and informative statistical
5106 graphics in Python. It is built on top of matplotlib and tightly integrated
5107 with the PyData stack, including support for numpy and pandas data structures
5108 and statistical routines from scipy and statsmodels.")
5109 (license license:bsd-3)))
5111 (define-public python2-seaborn
5112 (package-with-python2 python-seaborn))
5114 (define-public python-mpmath
5116 (name "python-mpmath")
5120 (uri (string-append "http://mpmath.org/files/mpmath-"
5124 "08ijsr4ifrqv3cjc26mkw0dbvyygsa99in376hr4b96ddm1gdpb8"))))
5125 (build-system python-build-system)
5128 (modify-phases %standard-phases
5131 (invoke "python" "mpmath/tests/runtests.py" "-local"))))))
5132 (home-page "http://mpmath.org")
5133 (synopsis "Arbitrary-precision floating-point arithmetic in python")
5135 "@code{mpmath} can be used as an arbitrary-precision substitute for
5136 Python's float/complex types and math/cmath modules, but also does much
5137 more advanced mathematics.")
5138 (license license:bsd-3)))
5140 (define-public python2-mpmath
5141 (package-with-python2 python-mpmath))
5143 (define-public python-bigfloat
5145 (name "python-bigfloat")
5150 (uri (pypi-uri "bigfloat" version))
5152 (base32 "0xd7q4l7v0f463diznjv4k9wlaks80pn9drdqmfifi7zx8qvybi6"))))
5153 (build-system python-build-system)
5156 (home-page "https://github.com/mdickinson/bigfloat")
5157 (synopsis "Arbitrary precision floating-point arithmetic for Python")
5159 "This packages provides a Python interface to the MPFR library for
5160 multiprecision arithmetic.")
5161 (license license:lgpl3+)))
5163 (define-public python2-bigfloat
5164 (package-with-python2 python-bigfloat))
5166 (define-public python-sympy
5168 (name "python-sympy")
5174 "https://github.com/sympy/sympy/releases/download/sympy-"
5175 version "/sympy-" version ".tar.gz"))
5177 (base32 "190n29sppw7g8ihilc5451y7jlfcaw56crqiqbf1jff43dlmfnxc"))))
5178 (build-system python-build-system)
5181 (modify-phases %standard-phases
5182 ;; Run the core tests after installation. By default it would run
5183 ;; *all* tests, which take a very long time to complete and are known
5186 (add-after 'install 'check
5187 (lambda* (#:key outputs #:allow-other-keys)
5188 (invoke "python3" "-c" "import sympy; sympy.test(\"/core\")")
5191 `(("python-mpmath" ,python-mpmath)))
5192 (home-page "http://www.sympy.org/")
5193 (synopsis "Python library for symbolic mathematics")
5195 "SymPy is a Python library for symbolic mathematics. It aims to become a
5196 full-featured computer algebra system (CAS) while keeping the code as simple
5197 as possible in order to be comprehensible and easily extensible.")
5198 (license license:bsd-3)))
5200 (define-public python2-sympy
5202 (inherit (package-with-python2 python-sympy))
5205 (modify-phases %standard-phases
5206 ;; Run the core tests after installation. By default it would run
5207 ;; *all* tests, which take a very long time to complete and are known
5210 (add-after 'install 'check
5211 (lambda* (#:key outputs #:allow-other-keys)
5212 (invoke "python" "-c" "import sympy; sympy.test(\"/core\")")
5215 (define-public python-q
5222 (uri (pypi-uri "q" version))
5225 "1mgfazh8fkizh6walra2zv885f3lcgr3nb02v1frfm4p8ddcy3yy"))))
5226 (build-system python-build-system)
5227 (home-page "https://github.com/zestyping/q")
5228 (synopsis "Quick-and-dirty debugging output for tired programmers")
5230 "q is a Python module for \"print\" style of debugging Python code. It
5231 provides convenient short API for print out of values, tracebacks, and
5232 falling into the Python interpreter.")
5233 (license license:asl2.0)))
5235 (define-public python2-q
5236 (package-with-python2 python-q))
5238 (define-public python2-xlib
5240 (name "python2-xlib")
5244 (uri (string-append "mirror://sourceforge/python-xlib/python-xlib"
5246 "python-xlib-" version ".tar.gz"))
5249 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
5250 (build-system python-build-system)
5252 `(#:python ,python-2 ;Python 2 only
5253 #:tests? #f)) ;no tests
5254 (home-page "http://python-xlib.sourceforge.net/")
5255 (synopsis "Python X11 client library")
5257 "The Python X Library is intended to be a fully functional X client
5258 library for Python programs. It is useful to implement low-level X clients.
5259 It is written entirely in Python.")
5260 (license license:gpl2+)))
5262 (define-public python-singledispatch
5264 (name "python-singledispatch")
5269 (uri (pypi-uri "singledispatch" version))
5272 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
5273 (build-system python-build-system)
5275 `(("python-six" ,python-six))) ; required for conversion, not at run-time
5277 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
5278 (synopsis "Backport of singledispatch feature from Python 3.4")
5280 "This library brings functools.singledispatch from Python 3.4 to Python
5282 (license license:expat)))
5284 (define-public python2-singledispatch
5285 (package-with-python2 python-singledispatch))
5287 ;; the python- version can be removed with python-3.5
5288 (define-public python-backports-abc
5290 (name "python-backports-abc")
5295 (uri (pypi-uri "backports_abc" version))
5298 "1pkv8d1zxj5f9i227dxbjczncbv7ks7ywnjwyxfjagm02i2yafq3"))))
5299 (build-system python-build-system)
5300 (home-page "https://github.com/cython/backports_abc")
5301 (synopsis "Backport of additions to the 'collections.abc' module")
5303 "Python-backports-abc provides a backport of additions to the
5304 'collections.abc' module in Python-3.5.")
5305 (license license:psfl)))
5307 (define-public python2-backports-abc
5308 (package-with-python2 python-backports-abc))
5310 (define-public python-backports-csv
5312 (name "python-backports-csv")
5317 (uri (pypi-uri "backports.csv" version))
5320 "1imzbrradkfn8s2m1qcimyn74dn1mz2p3j381jljn166rf2i6hlc"))))
5321 (build-system python-build-system)
5322 (home-page "https://github.com/ryanhiebert/backports.csv")
5323 (synopsis "Backport of Python 3's csv module for Python 2")
5325 "Provides a backport of Python 3's @code{csv} module for parsing
5326 comma separated values. The API of the @code{csv} module in Python 2
5327 is drastically different from the @code{csv} module in Python 3.
5328 This is due, for the most part, to the difference between str in
5329 Python 2 and Python 3.")
5330 (license license:psfl)))
5332 (define-public python2-backports-csv
5333 (package-with-python2 python-backports-csv))
5335 (define-public python2-backports-shutil-get-terminal-size
5337 (name "python2-backports-shutil-get-terminal-size")
5342 (uri (pypi-uri "backports.shutil_get_terminal_size" version))
5345 "107cmn7g3jnbkp826zlj8rrj19fam301qvaqf0f3905f5217lgki"))))
5346 (build-system python-build-system)
5348 `(#:python ,python-2
5350 (modify-phases %standard-phases
5353 (invoke "py.test" "-v"))))))
5355 `(("python2-pytest" ,python2-pytest)))
5356 (home-page "https://github.com/chrippa/backports.shutil_get_terminal_size")
5357 (synopsis "Backport of Python 3.3's @code{shutil.get_terminal_size}")
5359 "This package provides a backport of the @code{get_terminal_size
5360 function} from Python 3.3's @code{shutil}.
5361 Unlike the original version it is written in pure Python rather than C,
5362 so it might be a tiny bit slower.")
5363 (license license:expat)))
5365 (define-public python-waf
5371 (uri (string-append "https://waf.io/"
5372 "waf-" version ".tar.bz2"))
5375 "13zrniwkmfqgsgzi9v5m1367fppp9yzrz6z2ny6hy8dmpb8mj4z4"))))
5376 (build-system python-build-system)
5379 (modify-phases %standard-phases
5382 (invoke "python" "waf-light" "configure" "build")))
5385 (invoke "python" "waf" "--version")))
5387 (lambda* (#:key outputs #:allow-other-keys)
5388 (let ((out (assoc-ref outputs "out")))
5389 (install-file "waf" (string-append out "/bin")))
5391 ;; waf breaks when it is wrapped.
5393 (home-page "https://waf.io/")
5394 (synopsis "Python-based build system")
5396 "Waf is a Python-based framework for configuring, compiling and installing
5398 (license license:bsd-3)))
5400 (define-public python2-waf
5401 (package-with-python2 python-waf))
5403 (define-public python-pyzmq
5405 (name "python-pyzmq")
5410 (uri (pypi-uri "pyzmq" version))
5412 (base32 "1pyxxrz60f88ffm0y6vpbx3q8jcr9ybz8fcilihwzwhh36n84ax7"))))
5413 (build-system python-build-system)
5416 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
5417 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
5418 ;; --inplace' for 'python setup.py test' to work.
5421 `(("zeromq" ,zeromq)))
5423 `(("pkg-config" ,pkg-config)
5424 ("python-nose" ,python-nose)))
5425 (home-page "https://github.com/zeromq/pyzmq")
5426 (synopsis "Python bindings for 0MQ")
5428 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
5429 (license license:bsd-4)))
5431 (define-public python2-pyzmq
5432 (package-with-python2 python-pyzmq))
5434 (define-public python-pep8
5435 ;; This package has been renamed to ‘pycodestyle’ and is no longer updated.
5436 ;; Its last release (1.7.1) adds only a scary warning to this effect, breaking
5437 ;; some dependents' test suites, and nothing more.
5439 (name "python-pep8")
5444 (uri (pypi-uri "pep8" version))
5447 "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1"))))
5448 (build-system python-build-system)
5449 (home-page "https://pep8.readthedocs.org/")
5450 (synopsis "Python style guide checker")
5452 "This tools checks Python code against some of the style conventions in
5454 (license license:expat)))
5456 (define-public python2-pep8
5457 (package-with-python2 python-pep8))
5459 (define-public python-pyflakes
5461 (name "python-pyflakes")
5466 (uri (pypi-uri "pyflakes" version))
5469 "0jba28czyvimdc72llms3f17swp3i8jdcabf5w0j00adfbn64xls"))))
5470 (build-system python-build-system)
5472 "https://github.com/pyflakes/pyflakes")
5473 (synopsis "Passive checker of Python programs")
5475 "Pyflakes statically checks Python source code for common errors.")
5476 (license license:expat)))
5478 (define-public python2-pyflakes
5479 (package-with-python2 python-pyflakes))
5481 (define-public python-mccabe
5483 (name "python-mccabe")
5488 (uri (pypi-uri "mccabe" version))
5491 "07w3p1qm44hgxf3vvwz84kswpsx6s7kvaibzrsx5dzm0hli1i3fx"))))
5492 (build-system python-build-system)
5494 `(("python-pytest" ,python-pytest-bootstrap)
5495 ("python-pytest-runner" ,python-pytest-runner)))
5496 (home-page "https://github.com/flintwork/mccabe")
5497 (synopsis "McCabe checker, plugin for flake8")
5499 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
5500 complexity of Python source code.")
5501 (license license:expat)))
5503 (define-public python2-mccabe
5504 (package-with-python2 python-mccabe))
5506 (define-public python-mccabe-0.2.1
5507 (package (inherit python-mccabe)
5512 (uri (pypi-uri "mccabe" version))
5515 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))))
5517 (define-public python2-mccabe-0.2.1
5518 (package-with-python2 python-mccabe-0.2.1))
5520 ;; Flake8 2.4.1 requires an older version of pep8.
5521 ;; This should be removed ASAP.
5522 (define-public python-pep8-1.5.7
5523 (package (inherit python-pep8)
5528 (uri (pypi-uri "pep8" version))
5531 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))
5533 ;; XXX Tests not compatible with Python 3.5.
5536 (define-public python2-pep8-1.5.7
5537 (package-with-python2 python-pep8-1.5.7))
5539 ;; Flake8 2.4.1 requires an older version of pyflakes.
5540 ;; This should be removed ASAP.
5541 (define-public python-pyflakes-0.8.1
5542 (package (inherit python-pyflakes)
5547 (uri (pypi-uri "pyflakes" version))
5550 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))
5552 ;; XXX Tests not compatible with Python 3.5.
5555 (define-public python2-pyflakes-0.8.1
5556 (package-with-python2 python-pyflakes-0.8.1))
5558 ;; This package is used by hypothesis which has thousands of dependent packages.
5559 ;; FIXME: Consolidate this with "python-flake8" below in the next rebuild cycle.
5560 (define-public python-flake8-3.5
5562 (name "python-flake8")
5567 (uri (pypi-uri "flake8" version))
5570 "184b33grvvjmiwlv9kyd7yng9qv5ld24154j70z332xxg9gjclvj"))))
5571 (build-system python-build-system)
5574 (modify-phases %standard-phases
5575 ;; Two errors don't seem to have assigned codes.
5576 (add-after 'unpack 'delete-broken-test
5577 (lambda _ (delete-file "tests/unit/test_pyflakes_codes.py") #t))
5578 (add-after 'unpack 'fix-problem-with-pycodestyle
5580 ;; See https://gitlab.com/pycqa/flake8/merge_requests/230
5581 ;; This should no longer be needed with the next release.
5582 (substitute* "setup.py"
5583 (("PEP8_PLUGIN\\('break_around_binary_operator'\\),")
5584 "PEP8_PLUGIN('break_after_binary_operator'),\
5585 PEP8_PLUGIN('break_before_binary_operator'),"))
5588 (add-after 'install 'check
5589 (lambda* (#:key inputs outputs #:allow-other-keys)
5590 (add-installed-pythonpath inputs outputs)
5591 (invoke "pytest" "-v")
5594 `(("python-pycodestyle" ,python-pycodestyle)
5595 ("python-pyflakes" ,python-pyflakes)
5596 ("python-mccabe" ,python-mccabe)))
5598 `(("python-mock" ,python-mock)
5599 ("python-pytest" ,python-pytest-bootstrap)
5600 ("python-pytest-runner" ,python-pytest-runner)))
5601 (home-page "https://gitlab.com/pycqa/flake8")
5603 "The modular source code checker: pep8, pyflakes and co")
5605 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
5606 (properties `((python2-variant . ,(delay python2-flake8-3.5))))
5607 (license license:expat)))
5609 (define-public python2-flake8-3.5
5610 (let ((base (package-with-python2 (strip-python2-variant python-flake8-3.5))))
5611 (package (inherit base)
5613 `(("python2-configparser" ,python2-configparser)
5614 ("python2-enum34" ,python2-enum34)
5615 ,@(package-propagated-inputs base))))))
5617 ;; Version 3.5.0 has compatibility issues with Pyflakes 2.0, so we need
5618 ;; this newer version. Keep it as a separate variable for now to avoid
5619 ;; rebuilding "python-hypothesis"; this should be removed in the next
5621 (define-public python-flake8
5623 (inherit python-flake8-3.5)
5627 (uri (pypi-uri "flake8" version))
5630 "0w0nprx22rbvrrkbfx9v5jc5gskbm08g219l7r8wai8zfswgadba"))))
5632 (substitute-keyword-arguments (package-arguments python-flake8-3.5)
5634 `(modify-phases ,phases
5635 (delete 'delete-broken-test)
5636 (delete 'fix-problem-with-pycodestyle)))))
5637 (properties `((python2-variant . ,(delay python2-flake8))))))
5639 (define-public python2-flake8
5640 (let ((base (package-with-python2 (strip-python2-variant python-flake8))))
5641 (package (inherit base)
5643 (package-propagated-inputs python2-flake8-3.5)))))
5645 ;; python-hacking requires flake8 <2.6.0.
5646 (define-public python-flake8-2.5
5648 (inherit python-flake8)
5652 (uri (pypi-uri "flake8" version))
5655 "1snylqwbmrylbx3r1wpz8ggk98f6bcag4441ag8mm2l7wyn58sij"))))
5657 `(("python-pep8" ,python-pep8)
5658 ,@(package-propagated-inputs python-flake8)))
5659 (properties `((python2-variant . ,(delay python2-flake8-2.5))))))
5661 (define-public python2-flake8-2.5
5663 (inherit python2-flake8)
5664 (version (package-version python-flake8-2.5))
5666 (inherit (package-source python-flake8-2.5))))
5668 `(("python2-pep8" ,python2-pep8)
5669 ,@(package-propagated-inputs python2-flake8)))))
5671 (define-public python-flake8-polyfill
5673 (name "python-flake8-polyfill")
5678 (uri (pypi-uri "flake8-polyfill" version))
5681 "1nlf1mkqw856vi6782qcglqhaacb23khk9wkcgn55npnjxshhjz4"))))
5682 (build-system python-build-system)
5685 (modify-phases %standard-phases
5688 (setenv "PYTHONPATH"
5689 (string-append (getcwd) "/build/lib:"
5690 (getenv "PYTHONPATH")))
5691 (invoke "py.test" "-v"))))))
5693 `(("python-flake8" ,python-flake8)
5694 ("python-mock" ,python-mock)
5695 ("python-pep8" ,python-pep8)
5696 ("python-pycodestyle" ,python-pycodestyle)
5697 ("python-pytest" ,python-pytest)))
5698 (home-page "https://gitlab.com/pycqa/flake8-polyfill")
5699 (synopsis "Polyfill package for Flake8 plugins")
5701 "This package that provides some compatibility helpers for Flake8
5702 plugins that intend to support Flake8 2.x and 3.x simultaneously.")
5703 (license license:expat)))
5705 (define-public python2-flake8-polyfill
5706 (package-with-python2 python-flake8-polyfill))
5708 (define-public python-mistune
5710 (name "python-mistune")
5715 (uri (pypi-uri "mistune" version))
5718 "0vkmsh0x480rni51lhyvigfdf06b9247z868pk3bal1wnnfl58sr"))))
5719 (build-system python-build-system)
5721 `(("python-nose" ,python-nose)
5722 ("python-cython" ,python-cython)))
5723 (home-page "https://github.com/lepture/mistune")
5724 (synopsis "Markdown parser in pure Python")
5725 (description "This package provides a fast markdown parser in pure
5727 (license license:bsd-3)))
5729 (define-public python2-mistune
5730 (package-with-python2 python-mistune))
5732 (define-public python-markdown
5734 (name "python-markdown")
5739 (uri (pypi-uri "Markdown" version))
5742 "0z6v8649sr434d5r5zmrhydka7v7f9yas4bwcgkcs0650jdhybnh"))))
5743 (build-system python-build-system)
5745 `(("python-nose" ,python-nose)
5746 ("python-pyyaml" ,python-pyyaml)))
5747 (home-page "https://python-markdown.github.io/")
5748 (synopsis "Python implementation of Markdown")
5750 "This package provides a Python implementation of John Gruber's
5751 Markdown. The library features international input, various Markdown
5752 extensions, and several HTML output formats. A command line wrapper
5753 markdown_py is also provided to convert Markdown files to HTML.")
5754 (license license:bsd-3)))
5756 (define-public python2-markdown
5757 (package-with-python2 python-markdown))
5759 (define-public python-ptyprocess
5761 (name "python-ptyprocess")
5766 (uri (pypi-uri "ptyprocess" version))
5769 "0ra31k10v3629xq0kdn8lwmfbi97anmk48r03yvh7mks0kq96hg6"))))
5770 (build-system python-build-system)
5772 `(("python-nose" ,python-nose)))
5775 (modify-phases %standard-phases
5777 (lambda _ (invoke "nosetests"))))))
5778 (home-page "https://github.com/pexpect/ptyprocess")
5779 (synopsis "Run a subprocess in a pseudo terminal")
5781 "This package provides a Python library used to launch a subprocess in a
5782 pseudo terminal (pty), and interact with both the process and its pty.")
5783 (license license:isc)))
5785 (define-public python2-ptyprocess
5786 (package-with-python2 python-ptyprocess))
5788 (define-public python-cram
5790 (name "python-cram")
5792 (home-page "https://bitheap.org/cram/")
5795 (uri (list (string-append home-page "cram-"
5797 (pypi-uri "cram" version)))
5800 "0bvz6fwdi55rkrz3f50zsy35gvvwhlppki2yml5bj5ffy9d499vx"))))
5803 (modify-phases %standard-phases
5804 (add-after 'unpack 'patch-source
5806 (substitute* (find-files "cram" ".*\\.py$")
5807 ;; Replace default shell path.
5808 (("/bin/sh") (which "sh")))
5809 (substitute* (find-files "tests" ".*\\.t$")
5811 (("/bin/bash") (which "bash"))
5812 (("/bin/sh") (which "sh")))
5813 (substitute* "cram/_test.py"
5814 ;; This hack works around a bug triggered by substituting
5815 ;; the /bin/sh paths. "tests/usage.t" compares the output of
5816 ;; "cram -h", which breaks the output at 80 characters. This
5817 ;; causes the line showing the default shell to break into two
5818 ;; lines, but the test expects a single line...
5819 (("env\\['COLUMNS'\\] = '80'")
5820 "env['COLUMNS'] = '160'"))
5823 (add-after 'install 'check
5824 ;; The test phase uses the built library and executable.
5825 ;; It's easier to run it after install since the build
5826 ;; directory contains version-specific PATH.
5827 (lambda* (#:key inputs outputs #:allow-other-keys)
5828 (add-installed-pythonpath inputs outputs)
5829 (setenv "PATH" (string-append (getenv "PATH") ":"
5830 (assoc-ref outputs "out") "/bin"))
5831 (invoke "make" "test"))))))
5832 (build-system python-build-system)
5834 `(("python-coverage" ,python-coverage)
5836 (synopsis "Simple testing framework for command line applications")
5838 "Cram is a functional testing framework for command line applications.
5839 Cram tests look like snippets of interactive shell sessions. Cram runs each
5840 command and compares the command output in the test with the command’s actual
5842 (license license:gpl2+)))
5844 (define-public python2-cram
5845 (package-with-python2 python-cram))
5847 (define-public python-straight-plugin
5849 (name "python-straight-plugin")
5854 (uri (pypi-uri "straight.plugin" version))
5857 "069pjll4383p4kkgvcc40hgyvf79j2wdbpgwz77yigzxksh1gj62"))))
5858 (build-system python-build-system)
5859 (home-page "https://github.com/ironfroggy/straight.plugin")
5860 (synopsis "Simple namespaced plugin facility")
5861 (description "Straight Plugin provides a type of plugin you can create from
5862 almost any existing Python modules, and an easy way for outside developers to
5863 add functionality and customization to your projects with their own plugins.")
5864 (license license:expat)))
5866 (define-public python2-straight-plugin
5867 (package-with-python2 python-straight-plugin))
5869 (define-public python-fonttools
5871 (name "python-fonttools")
5875 (uri (pypi-uri "fonttools" version ".zip"))
5878 "0vsvjhidpb5kywpjgz1j3fywzkddxkb0afqai18qa3h6lqjyxwpb"))))
5879 (build-system python-build-system)
5882 ("python-pytest" ,python-pytest)
5883 ("python-pytest-runner" ,python-pytest-runner)))
5884 (home-page "https://github.com/behdad/fonttools")
5885 (synopsis "Tools to manipulate font files")
5887 "FontTools/TTX is a library to manipulate font files from Python. It
5888 supports reading and writing of TrueType/OpenType fonts, reading and writing
5889 of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
5890 also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
5891 from an XML-based format.")
5892 (license license:expat)))
5894 (define-public python2-fonttools
5895 (package-with-python2 python-fonttools))
5897 (define-public python-ly
5904 (uri (pypi-uri name version))
5907 "0x98dv7p8mg26p4816yy8hz4f34zf6hpnnfmr56msgh9jnsm2qfl"))))
5908 (build-system python-build-system)
5910 ;; FIXME: Some tests need network access.
5912 (synopsis "Tool and library for manipulating LilyPond files")
5913 (description "This package provides a Python library to parse, manipulate
5914 or create documents in LilyPond format. A command line program ly is also
5915 provided that can be used to do various manipulations with LilyPond files.")
5916 (home-page "https://pypi.python.org/pypi/python-ly")
5917 (license license:gpl2+)))
5919 (define-public python-appdirs
5921 (name "python-appdirs")
5926 (uri (pypi-uri "appdirs" version))
5929 "14id6wxi12lgyw0mg3bcfnf888ad07jz9yj46gfzhn186z8rcn4y"))))
5930 (build-system python-build-system)
5931 (home-page "https://github.com/ActiveState/appdirs")
5933 "Determine platform-specific dirs, e.g. a \"user data dir\"")
5935 "This module provides a portable way of finding out where user data
5936 should be stored on various operating systems.")
5937 (license license:expat)))
5939 (define-public python2-appdirs
5940 (package-with-python2 python-appdirs))
5942 (define-public python-llfuse
5944 (name "python-llfuse")
5948 (uri (pypi-uri "llfuse" version ".tar.bz2"))
5951 "1n7a90jww3ly49fm7x27m3xw3la3qfrnykcakga654g6kcyjlhbf"))))
5952 (build-system python-build-system)
5957 `(("pkg-config" ,pkg-config)))
5958 (synopsis "Python bindings for FUSE")
5960 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
5961 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
5962 (license license:lgpl2.0+)
5963 (properties `((python2-variant . ,(delay python2-llfuse))))))
5965 (define-public python2-llfuse
5966 (package (inherit (package-with-python2
5967 (strip-python2-variant python-llfuse)))
5968 (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2)))))
5971 (define-public python-llfuse-0.41
5972 (package (inherit python-llfuse)
5977 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5978 "llfuse-" version ".tar.bz2"))
5981 "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa"))))
5982 ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat)
5983 ;; licensed. The rest of the package is licensed under LGPL2.0 or later.
5984 (license (list license:expat license:lgpl2.0+))))
5986 (define-public python-msgpack
5988 (name "python-msgpack")
5992 (uri (pypi-uri "msgpack" version))
5995 "1hz2dba1nvvn52afg34liijsm7kn65cmn06dl0xbwld6bb4cis0f"))))
5996 (build-system python-build-system)
5998 `(#:modules ((guix build utils)
5999 (guix build python-build-system)
6004 (modify-phases %standard-phases
6007 (let ((cwd (getcwd)))
6008 (setenv "PYTHONPATH"
6009 (string-append cwd "/build/"
6010 (find (cut string-prefix? "lib" <>)
6011 (scandir (string-append cwd "/build")))
6013 (getenv "PYTHONPATH")))
6014 (invoke "pytest" "-v" "test")))))))
6016 `(("python-pytest" ,python-pytest)))
6017 (synopsis "MessagePack (de)serializer")
6018 (description "MessagePack is a fast, compact binary serialization format,
6019 suitable for similar data to JSON. This package provides CPython bindings for
6020 reading and writing MessagePack data.")
6021 (home-page "https://pypi.python.org/pypi/msgpack/")
6022 (license license:asl2.0)))
6024 ;; This msgpack library's name changed from "python-msgpack" to "msgpack" with
6025 ;; release 0.5. Some packages like borg still call it by the old name for now.
6026 ;; <https://bugs.gnu.org/30662>
6027 (define-public python-msgpack-transitional
6029 (inherit python-msgpack)
6030 (name "python-msgpack-transitional")
6032 (substitute-keyword-arguments (package-arguments python-msgpack)
6034 `(modify-phases ,phases
6035 (add-after 'unpack 'configure-transitional
6037 ;; Keep using the old name.
6038 (substitute* "setup.py"
6039 (("TRANSITIONAL = False")
6040 "TRANSITIONAL = 1"))
6043 (define-public python2-msgpack
6044 (package-with-python2 python-msgpack))
6046 (define-public python-netaddr
6048 (name "python-netaddr")
6053 (uri (pypi-uri "netaddr" version))
6056 "1zdfadvpq4lmcqzr383gywxn4xyn355kj1n3lk9q2l03vmyfrbiq"))))
6057 (build-system python-build-system)
6058 (arguments `(#:tests? #f)) ;; No tests.
6059 (home-page "https://github.com/drkjam/netaddr/")
6060 (synopsis "Pythonic manipulation of network addresses")
6062 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
6063 and MAC network addresses.")
6064 (license license:bsd-3)))
6066 (define-public python2-netaddr
6067 (package-with-python2 python-netaddr))
6069 (define-public python-wrapt
6071 (name "python-wrapt")
6076 (uri (pypi-uri "wrapt" version))
6079 "0cqmysny1pz01jw26q48q5zasvns6507rwhgm6wcw743f0r01sja"))))
6080 (build-system python-build-system)
6082 ;; Tests are not included in the tarball, they are only available in the
6085 (home-page "https://github.com/GrahamDumpleton/wrapt")
6086 (synopsis "Module for decorators, wrappers and monkey patching")
6088 "The aim of the wrapt module is to provide a transparent object proxy for
6089 Python, which can be used as the basis for the construction of function
6090 wrappers and decorator functions.")
6091 (license license:bsd-2)))
6093 (define-public python2-wrapt
6094 (package-with-python2 python-wrapt))
6096 (define-public python-xlrd
6098 (name "python-xlrd")
6102 (uri (pypi-uri "xlrd" version))
6105 "0s8hjiz01vbhy85xalrz0qlsmd9ypf36zjqrf97hh984spapvy0g"))))
6106 (build-system python-build-system)
6109 (modify-phases %standard-phases
6110 ;; Current test in setup.py does not work as of 1.0.0, so use nose to
6111 ;; run tests instead for now.
6112 (replace 'check (lambda _ (invoke "nosetests"))))))
6113 (native-inputs `(("python-nose" ,python-nose)))
6114 (home-page "http://www.python-excel.org/")
6115 (synopsis "Library for extracting data from Excel files")
6116 (description "This packages provides a library to extract data from
6117 spreadsheets using Microsoft Excel proprietary file formats @samp{.xls} and
6118 @samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
6119 Unicode-aware. It is not intended as an end-user tool.")
6120 (license license:bsd-3)))
6122 (define-public python2-xlrd
6123 (package-with-python2 python-xlrd))
6125 (define-public python-prettytable
6127 (name "python-prettytable")
6132 (uri (pypi-uri "prettytable" version ".tar.bz2"))
6135 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
6136 (build-system python-build-system)
6137 (home-page "http://code.google.com/p/prettytable/")
6138 (synopsis "Display tabular data in an ASCII table format")
6140 "A library designed to represent tabular data in visually appealing ASCII
6141 tables. PrettyTable allows for selection of which columns are to be printed,
6142 independent alignment of columns (left or right justified or centred) and
6143 printing of sub-tables by specifying a row range.")
6144 (license license:bsd-3)))
6146 (define-public python2-prettytable
6147 (package-with-python2 python-prettytable))
6149 (define-public python-tables
6151 (name "python-tables")
6156 (uri (pypi-uri "tables" version))
6159 "0affz7k8babh8wdmsgrz5jxrd569by2w8ffimcxs9wiaf5rw1idx"))
6160 (modules '((guix build utils)))
6163 ;; Remove pre-compiled .pyc files from source.
6164 (for-each delete-file-recursively
6165 (find-files "." "__pycache__" #:directories? #t))
6166 (for-each delete-file (find-files "." "\\.pyc$"))
6168 (build-system python-build-system)
6170 `(;; FIXME: python-build-system does not pass configure-flags to "build"
6171 ;; or "check", so we must override the build and check phases.
6173 (modify-phases %standard-phases
6174 (add-after 'unpack 'use-gcc
6176 (substitute* "setup.py"
6177 (("compiler = new_compiler\\(\\)" line)
6179 "\ncompiler.set_executables(compiler='gcc',"
6180 "compiler_so='gcc',"
6182 "linker_so='gcc -shared')")))
6185 (lambda* (#:key inputs #:allow-other-keys)
6186 (invoke "python" "setup.py" "build"
6187 (string-append "--hdf5="
6188 (assoc-ref inputs "hdf5")))))
6190 (lambda* (#:key inputs #:allow-other-keys)
6191 (invoke "python" "setup.py" "check"
6192 (string-append "--hdf5="
6193 (assoc-ref inputs "hdf5"))))))))
6195 `(("python-numexpr" ,python-numexpr)
6196 ("python-numpy" ,python-numpy)))
6198 `(("python-cython" ,python-cython)
6199 ("pkg-config" ,pkg-config)))
6204 (home-page "http://www.pytables.org/")
6205 (synopsis "Hierarchical datasets for Python")
6206 (description "PyTables is a package for managing hierarchical datasets and
6207 designed to efficiently cope with extremely large amounts of data.")
6208 (license license:bsd-3)))
6210 (define-public python2-tables
6211 (package-with-python2 python-tables))
6213 (define-public python-pyasn1
6215 (name "python-pyasn1")
6220 (uri (pypi-uri "pyasn1" version))
6223 "1z5h38anjzzrxpraa9iq9llffyx2zs8gx0q6dc1g029miwnn50gv"))))
6224 (build-system python-build-system)
6225 (home-page "http://pyasn1.sourceforge.net/")
6226 (synopsis "ASN.1 types and codecs")
6228 "This is an implementation of ASN.1 types and codecs in Python. It is
6229 suitable for a wide range of protocols based on the ASN.1 specification.")
6230 (license license:bsd-2)))
6232 (define-public python2-pyasn1
6233 (package-with-python2 python-pyasn1))
6235 (define-public python-pyasn1-modules
6237 (name "python-pyasn1-modules")
6242 (uri (pypi-uri "pyasn1-modules" version))
6245 "0ivm850yi7ajjbi8j115qpsj95bgxdsx48nbjzg0zip788c3xkx0"))))
6246 (build-system python-build-system)
6248 `(("python-pyasn1" ,python-pyasn1)))
6249 (home-page "https://sourceforge.net/projects/pyasn1/")
6250 (synopsis "ASN.1 codec implementations")
6252 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
6253 implementations of ASN.1-based codecs and protocols.")
6254 (license license:bsd-3)))
6256 (define-public python2-pyasn1-modules
6257 (package-with-python2 python-pyasn1-modules))
6259 (define-public python-ipaddress
6261 (name "python-ipaddress")
6265 (uri (pypi-uri "ipaddress" version))
6268 "0b570bm6xqpjwqis15pvdy6lyvvzfndjvkynilcddjj5x98wfimi"))))
6269 (build-system python-build-system)
6270 (home-page "https://github.com/phihag/ipaddress")
6271 (synopsis "IP address manipulation library")
6273 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
6274 in Python. This library is used to create, poke at, and manipulate IPv4 and
6275 IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
6276 module to older versions of Python.")
6277 (license license:psfl)))
6279 (define-public python2-ipaddress
6280 (package-with-python2 python-ipaddress))
6282 (define-public python2-ipaddr
6284 (name "python2-ipaddr")
6289 (uri (pypi-uri "ipaddr" version))
6291 (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v"))))
6292 (build-system python-build-system)
6294 `(#:python ,python-2 ;version 2 only
6296 (modify-phases %standard-phases
6298 (lambda _ (invoke "python" "ipaddr_test.py"))))))
6299 (home-page "https://github.com/google/ipaddr-py")
6300 (synopsis "IP address manipulation library")
6302 "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and
6303 IPv6 addresses and networks.
6305 For new implementations you may prefer to use the standard module
6306 @code{ipaddress}, which was introduced in Python 3.3 and backported to older
6307 versions of Python.")
6308 (license license:asl2.0)))
6310 (define-public python-idna
6312 (name "python-idna")
6317 (uri (pypi-uri "idna" version))
6320 "05jam7d31767dr12x0rbvvs8lxnpb1mhdb2zdlfxgh83z6k3hjk8"))))
6321 (build-system python-build-system)
6322 (home-page "https://github.com/kjd/idna")
6323 (synopsis "Internationalized domain names in applications")
6325 "This is a library to support the Internationalised Domain Names in
6326 Applications (IDNA) protocol as specified in RFC 5891. This version of the
6327 protocol is often referred to as “IDNA2008” and can produce different results
6328 from the earlier standard from 2003. The library is also intended to act as a
6329 suitable drop-in replacement for the “encodings.idna” module that comes with
6330 the Python standard library but currently only supports the older 2003
6332 (license license:bsd-4)))
6334 (define-public python2-idna
6335 (package-with-python2 python-idna))
6337 (define-public python-idna-ssl
6339 (name "python-idna-ssl")
6344 (uri (pypi-uri "idna-ssl" version))
6347 "0ydrc8hpg9mdr5hqq1lqfsfbn6sjq69slwpfrnlrm3k0phqg14qj"))))
6348 (build-system python-build-system)
6350 `(#:tests? #f)) ;circular dependency with python-aiohttp
6351 (home-page "https://github.com/aio-libs/idna-ssl")
6352 (synopsis "Patch @code{ssl.match_hostname} for Unicode(idna) domains support")
6353 (description "Patch @code{ssl.match_hostname} for Unicode(idna)
6355 (license license:expat)))
6357 (define-public python-pretend
6359 (name "python-pretend")
6364 (uri (pypi-uri "pretend" version))
6367 "040vm94lcbscg5p81g1icmwwwa2jm7wrd1ybmxnv1sz8rl8bh3n9"))))
6368 (build-system python-build-system)
6369 (home-page "https://github.com/alex/pretend")
6370 (synopsis "Library for stubbing in Python")
6372 "Pretend is a library to make stubbing with Python easier. Stubbing is a
6373 technique for writing tests. You may hear the term mixed up with mocks,
6374 fakes, or doubles. Basically, a stub is an object that returns pre-canned
6375 responses, rather than doing any computation.")
6376 (license license:bsd-3)))
6378 (define-public python2-pretend
6379 (package-with-python2 python-pretend))
6381 (define-public python-pip
6388 (uri (pypi-uri "pip" version))
6391 "188fclay154s520n43s7cxxlhdaiysvxf19zk8vr1xbyjyyr58n0"))))
6392 (build-system python-build-system)
6394 '(#:tests? #f)) ; there are no tests in the pypi archive.
6395 (home-page "https://pip.pypa.io/")
6396 (synopsis "Package manager for Python software")
6398 "Pip is a package manager for Python software, that finds packages on the
6399 Python Package Index (PyPI).")
6400 (license license:expat)))
6402 (define-public python2-pip
6403 (package-with-python2 python-pip))
6405 (define-public python-tlsh
6407 (name "python-tlsh")
6409 (home-page "https://github.com/trendmicro/tlsh")
6412 (uri (string-append "https://github.com/trendmicro/tlsh/archive/v"
6416 "1x1vahd4zg5kpyr9h9hs3fvh460p25rjy4cclwdnbbw8x3vc30q3"))
6417 (file-name (string-append name "-" version ".tar.gz"))))
6418 (build-system cmake-build-system)
6420 '(#:out-of-source? #f
6421 #:phases (modify-phases %standard-phases
6424 (lambda* (#:key outputs #:allow-other-keys)
6425 ;; Build and install the Python bindings. The underlying
6426 ;; C++ library is apparently not meant to be installed.
6427 (let ((out (assoc-ref outputs "out")))
6428 (with-directory-excursion "py_ext"
6429 (and (system* "python" "setup.py" "build")
6430 (system* "python" "setup.py" "install"
6431 (string-append "--prefix=" out))))))))))
6432 (inputs `(("python" ,python-wrapper))) ;for the bindings
6433 (synopsis "Fuzzy matching library for Python")
6435 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
6436 Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
6437 value which can be used for similarity comparisons. Similar objects have
6438 similar hash values, which allows for the detection of similar objects by
6439 comparing their hash values. The byte stream should have a sufficient amount
6440 of complexity; for example, a byte stream of identical bytes will not generate
6442 (license license:asl2.0)))
6444 (define-public python2-tlsh
6446 (inherit python-tlsh)
6447 (name "python2-tlsh")
6448 (inputs `(("python" ,python-2)))))
6450 (define-public python-termcolor
6452 (name "python-termcolor")
6457 (uri (pypi-uri "termcolor" version))
6460 "0fv1vq14rpqwgazxg4981904lfyp84mnammw7y046491cv76jv8x"))))
6461 (build-system python-build-system)
6463 ;; There are no tests.
6465 (home-page "https://pypi.python.org/pypi/termcolor")
6466 (synopsis "ANSII Color formatting for terminal output")
6468 "This package provides ANSII Color formatting for output in terminals.")
6469 (license license:expat)))
6471 (define-public python2-termcolor
6472 (package-with-python2 python-termcolor))
6474 (define-public python-libarchive-c
6476 (name "python-libarchive-c")
6480 (uri (pypi-uri "libarchive-c" version))
6483 "0qg0v1s9c1xdk9philhnv8k6c6nicvnvfwlc0j9srg90jmdlvm06"))))
6484 (build-system python-build-system)
6486 '(#:phases (modify-phases %standard-phases
6488 'build 'reference-libarchive
6489 (lambda* (#:key inputs #:allow-other-keys)
6490 ;; Retain the absolute file name of libarchive.so.
6491 (let ((libarchive (assoc-ref inputs "libarchive")))
6492 (substitute* "libarchive/ffi.py"
6493 (("find_library\\('archive'\\)")
6494 (string-append "'" libarchive
6495 "/lib/libarchive.so'"))))))
6497 (lambda _ (invoke "pytest" "-vv"))))))
6499 `(("python-mock" ,python-mock)
6500 ("python-pytest" ,python-pytest)))
6502 `(("libarchive" ,libarchive)))
6503 (home-page "https://github.com/Changaco/python-libarchive-c")
6504 (synopsis "Python interface to libarchive")
6506 "This package provides Python bindings to libarchive, a C library to
6507 access possibly compressed archives in many different formats. It uses
6508 Python's @code{ctypes} foreign function interface (FFI).")
6509 (license license:lgpl2.0+)))
6511 (define-public python2-libarchive-c
6512 (package-with-python2 python-libarchive-c))
6514 (define-public python-file
6517 (name "python-file")
6518 (build-system python-build-system)
6520 '(#:tests? #f ;no tests
6521 #:configure-flags '("--single-version-externally-managed" "--root=/")
6522 #:phases (modify-phases %standard-phases
6523 (add-before 'build 'change-directory
6527 (add-before 'build 'set-library-file-name
6528 (lambda* (#:key inputs #:allow-other-keys)
6529 (let ((file (assoc-ref inputs "file")))
6530 (substitute* "magic.py"
6531 (("find_library\\('magic'\\)")
6532 (string-append "'" file "/lib/libmagic.so'")))
6534 (inputs `(("file" ,file)))
6535 (self-native-input? #f)
6536 (synopsis "Python bindings to the libmagic file type guesser. Note that
6537 this module and the python-magic module both provide a \"magic.py\" file;
6538 these two modules, which are different and were developed separately, both
6539 serve the same purpose: provide Python bindings for libmagic.")))
6541 (define-public python2-file
6542 (package-with-python2 python-file))
6544 (define-public python-debian
6546 (name "python-debian")
6547 (home-page "https://salsa.debian.org/python-debian-team/python-debian")
6552 (uri (pypi-uri name version))
6555 "0i15f0xzx679sd0ldq2sls9pnnps9fv6vhqvnv9dzf4qhma42i0y"))))
6556 (build-system python-build-system)
6558 `(("python-six" ,python-six)))
6559 (synopsis "Debian package related modules")
6561 ;; XXX: Use @enumerate instead of @itemize to work around
6562 ;; <http://bugs.gnu.org/21772>.
6563 "This package provides Python modules that abstract many formats of
6564 Debian-related files, such as:
6567 @item Debtags information;
6568 @item @file{debian/changelog} files;
6569 @item packages files, pdiffs;
6570 @item control files of single or multiple RFC822-style paragraphs---e.g.
6571 @file{debian/control}, @file{.changes}, @file{.dsc};
6572 @item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
6573 contained files and meta-information.
6576 ;; Modules are either GPLv2+ or GPLv3+.
6577 (license license:gpl3+)))
6579 (define-public python2-debian
6580 (package-with-python2 python-debian))
6582 (define-public python-nbformat
6584 (name "python-nbformat")
6589 (uri (pypi-uri "nbformat" version))
6592 "00nlf08h8yc4q73nphfvfhxrcnilaqanb8z0mdy6nxk0vzq4wjgp"))))
6593 (build-system python-build-system)
6594 (arguments `(#:tests? #f)) ; no test target
6596 `(("python-ipython-genutils" ,python-ipython-genutils)
6597 ("python-jsonschema" ,python-jsonschema)
6598 ("python-jupyter-core" ,python-jupyter-core)
6599 ("python-traitlets" ,python-traitlets)))
6600 (home-page "http://jupyter.org")
6601 (synopsis "Jupyter Notebook format")
6602 (description "This package provides the reference implementation of the
6603 Jupyter Notebook format and Python APIs for working with notebooks.")
6604 (license license:bsd-3)))
6606 (define-public python2-nbformat
6607 (package-with-python2 python-nbformat))
6609 (define-public python-bleach
6611 (name "python-bleach")
6616 (uri (pypi-uri "bleach" version))
6619 "0jvg3jxrvnx7xmm9gj262v60ib452xlnwlb0navyp7jsvcd0d4qj"))))
6620 (build-system python-build-system)
6622 `(("python-html5lib" ,python-html5lib-0.9)
6623 ("python-six" ,python-six)))
6625 `(("python-nose" ,python-nose)))
6626 (home-page "https://github.com/jsocol/bleach")
6627 (synopsis "Whitelist-based HTML-sanitizing tool")
6628 (description "Bleach is an easy whitelist-based HTML-sanitizing tool.")
6629 (license license:asl2.0)))
6631 (define-public python2-bleach
6632 (package-with-python2 python-bleach))
6634 (define-public python-entrypoints
6636 (name "python-entrypoints")
6641 (uri (pypi-uri "entrypoints" version))
6644 "0lc4si3xb7hza424414rdqdc3vng3kcrph8jbvjqb32spqddf3f7"))))
6645 (build-system python-build-system)
6646 ;; The package does not come with a setup.py file, so we have to generate
6651 (modify-phases %standard-phases
6652 (add-after 'unpack 'create-setup.py
6654 (call-with-output-file "setup.py"
6657 from setuptools import setup
6658 setup(name='entrypoints', version='~a', py_modules=['entrypoints'])
6660 (home-page "https://github.com/takluyver/entrypoints")
6661 (synopsis "Discover and load entry points from installed Python packages")
6662 (description "Entry points are a way for Python packages to advertise
6663 objects with some common interface. The most common examples are
6664 @code{console_scripts} entry points, which define shell commands by
6665 identifying a Python function to run. The @code{entrypoints} module contains
6666 functions to find and load entry points.")
6667 (license license:expat)))
6669 (define-public python2-entrypoints
6670 (package-with-python2 python-entrypoints))
6672 (define-public python-nbconvert
6674 (name "python-nbconvert")
6679 (uri (pypi-uri "nbconvert" version))
6682 "0brclbb18l4nmd5qy3dl9wn05rjdh1fz4rmzdlfqacj12rcdvdgp"))))
6683 (build-system python-build-system)
6685 `(;; The "bdist_egg" target is disabled by default, causing the installation
6687 #:configure-flags (list "bdist_egg")
6688 ;; FIXME: 5 failures, 40 errors.
6691 ;; (modify-phases %standard-phases
6694 ;; (zero? (system* "py.test" "-v")))))
6696 `(("python-pytest" ,python-pytest)))
6698 `(("python-bleach" ,python-bleach)
6699 ("python-entrypoints" ,python-entrypoints)
6700 ("python-jinja2" ,python-jinja2)
6701 ("python-jupyter-core" ,python-jupyter-core)
6702 ("python-mistune" ,python-mistune)
6703 ("python-nbformat" ,python-nbformat)
6704 ("python-pygments" ,python-pygments)
6705 ("python-traitlets" ,python-traitlets)))
6706 (home-page "http://jupyter.org")
6707 (synopsis "Converting Jupyter Notebooks")
6708 (description "The @code{nbconvert} tool, @{jupyter nbconvert}, converts
6709 notebooks to various other formats via Jinja templates. It allows you to
6710 convert an @code{.ipynb} notebook file into various static formats including:
6718 @item ReStructured Text (rst)
6719 @item executable script
6721 (license license:bsd-3)))
6723 (define-public python2-nbconvert
6724 (package-with-python2 python-nbconvert))
6726 (define-public python-notebook
6728 (name "python-notebook")
6732 (uri (pypi-uri "notebook" version))
6735 "0jm7324mbxljmn9hgapj66q7swyz5ai92blmr0jpcy0h80x6f26r"))))
6736 (build-system python-build-system)
6739 (modify-phases %standard-phases
6742 ;; These tests require a browser
6743 (delete-file-recursively "notebook/tests/selenium")
6744 ;; Some tests need HOME
6745 (setenv "HOME" "/tmp")
6746 ;; This file contains "warningfilters", which are not supported
6747 ;; by this version of nose.
6748 (delete-file "setup.cfg")
6749 (with-directory-excursion "/tmp"
6750 (invoke "nosetests" "-v"))
6753 `(("python-jupyter-core" ,python-jupyter-core)
6754 ("python-nbformat" ,python-nbformat)
6755 ("python-nbconvert" ,python-nbconvert)
6756 ("python-prometheus-client" ,python-prometheus-client)
6757 ("python-send2trash" ,python-send2trash)
6758 ("python-terminado" ,python-terminado)))
6760 `(("python-nose" ,python-nose)
6761 ("python-sphinx" ,python-sphinx)
6762 ("python-requests" ,python-requests)))
6763 (home-page "http://jupyter.org/")
6764 (synopsis "Web-based notebook environment for interactive computing")
6766 "The Jupyter HTML notebook is a web-based notebook environment for
6767 interactive computing.")
6768 (properties `((python2-variant . ,(delay python2-notebook))))
6769 (license license:bsd-3)))
6771 (define-public python2-notebook
6772 (let ((base (package-with-python2
6773 (strip-python2-variant python-notebook))))
6774 (package (inherit base)
6776 `(("python2-mock" ,python2-mock)
6777 ,@(package-native-inputs base)))
6779 (substitute-keyword-arguments (package-arguments base)
6781 `(modify-phases ,phases
6782 (add-before 'check 'disable-test-case
6783 ;; The test requires network access to localhost. Curiously it
6784 ;; fails with Python 2 only. Simply make the test-case return
6788 "notebook/services/nbconvert/tests/test_nbconvert_api.py"
6789 (("formats = self.nbconvert_api") "return #")))))))))))
6791 (define-public python-widgetsnbextension
6793 (name "python-widgetsnbextension")
6798 (uri (pypi-uri "widgetsnbextension" version))
6801 "0rc2nivdy7k4m3vljx7wdh2jh11djapcgwhvzlbs0isl8gl8nqgs"))))
6802 (build-system python-build-system)
6804 `(("python-ipykernel" ,python-ipykernel)
6805 ("python-notebook" ,python-notebook)))
6807 `(("python-certifi" ,python-certifi)
6808 ("python-nose" ,python-nose)))
6809 (home-page "https://ipython.org")
6810 (synopsis "IPython HTML widgets for Jupyter")
6811 (description "This package provides interactive HTML widgets for Jupyter
6813 (license license:bsd-3)))
6815 (define-public python2-widgetsnbextension
6816 (package-with-python2 python-widgetsnbextension))
6818 (define-public python-ipywidgets
6820 (name "python-ipywidgets")
6825 (uri (pypi-uri "ipywidgets" version))
6828 "1lk0qrr5l9a0z7qkkn30hv5832whxwxymf1l576fmmad0n7hkxms"))))
6829 (build-system python-build-system)
6831 `(("python-ipython" ,python-ipython)
6832 ("python-traitlets" ,python-traitlets)
6833 ("python-widgetsnbextension" ,python-widgetsnbextension)))
6835 `(("python-nose" ,python-nose)
6836 ("python-pytest" ,python-pytest)))
6837 (home-page "https://ipython.org")
6838 (synopsis "IPython HTML widgets for Jupyter")
6839 (description "Ipywidgets are interactive HTML widgets for Jupyter
6840 notebooks and the IPython kernel. Notebooks come alive when interactive
6841 widgets are used. Users gain control of their data and can visualize changes
6843 (license license:bsd-3)))
6845 (define-public python2-ipywidgets
6846 (package-with-python2 python-ipywidgets))
6848 (define-public python-jupyter-console
6850 (name "python-jupyter-console")
6855 (uri (pypi-uri "jupyter_console" version))
6858 "1kam1qzgwr7srhm5r6aj90di5sws4bq0jmiw15452ddamb9yspal"))))
6859 (build-system python-build-system)
6860 ;; Tests only run in an TTY.
6861 (arguments `(#:tests? #f))
6863 `(("python-ipykernel" ,python-ipykernel)
6864 ("python-jupyter-client" ,python-jupyter-client)
6865 ("python-prompt-toolkit" ,python-prompt-toolkit-1)
6866 ("python-pygments" ,python-pygments)))
6868 `(("python-nose" ,python-nose)))
6869 (home-page "https://jupyter.org")
6870 (synopsis "Jupyter terminal console")
6871 (description "This package provides a terminal-based console frontend for
6872 Jupyter kernels. It also allows for console-based interaction with non-Python
6873 Jupyter kernels such as IJulia and IRKernel.")
6874 (license license:bsd-3)))
6876 (define-public python2-jupyter-console
6877 (package-with-python2 python-jupyter-console))
6879 ;; The python-ipython and python-jupyter-console require each other. To get
6880 ;; the functionality in both packages working, strip down the
6881 ;; python-jupyter-console package when using it as an input to python-ipython.
6882 (define python-jupyter-console-minimal
6884 (inherit python-jupyter-console)
6885 (name "python-jupyter-console-minimal")
6887 (substitute-keyword-arguments
6888 (package-arguments python-jupyter-console)
6890 `(modify-phases ,phases
6891 (add-after 'install 'delete-bin
6892 (lambda* (#:key outputs #:allow-other-keys)
6893 ;; Delete the bin files, to avoid conflicts in profiles
6894 ;; where python-ipython and python-jupyter-console are
6896 (delete-file-recursively
6898 (assoc-ref outputs "out") "/bin"))))))))
6899 ;; Remove the python-ipython propagated input, to avoid the cycle
6903 (package-propagated-inputs python-jupyter-console)))))
6905 (define-public python-qtconsole
6907 (name "python-qtconsole")
6912 (uri (pypi-uri "qtconsole" version))
6915 "1b03n1ixzscm0jw97l4dq5iy4fslnqxq5bb8287xb7n2a1gs26xw"))))
6916 (build-system python-build-system)
6918 ;; XXX: Tests are disabled, because this package needs python-ipython 7,
6919 ;; but we only have the LTS version 5.x. This means that there might be
6920 ;; runtime errors, but since this is a dependency of the Jupyter package,
6921 ;; and Jupyter can be used without the qtconsole we can overlook this for
6925 (modify-phases %standard-phases
6926 (add-before 'check 'pre-check
6928 (setenv "QT_QPA_PLATFORM" "offscreen")
6931 `(("python-ipykernel" ,python-ipykernel)
6932 ("python-ipython" ,python-ipython)))
6934 `(("python-pytest" ,python-pytest)))
6935 (home-page "http://jupyter.org")
6936 (synopsis "Jupyter Qt console")
6937 (description "This package provides a Qt-based console for Jupyter with
6938 support for rich media output.")
6939 (license license:bsd-3)))
6941 (define-public jupyter
6948 (uri (pypi-uri "jupyter" version))
6951 "0pwf3pminkzyzgx5kcplvvbvwrrzd3baa7lmh96f647k30rlpp6r"))))
6952 (build-system python-build-system)
6953 (arguments '(#:tests? #f)) ; there are none.
6955 `(("python-ipykernel" ,python-ipykernel)
6956 ("python-ipywidgets" ,python-ipywidgets)
6957 ("python-jupyter-console" ,python-jupyter-console)
6958 ("python-nbconvert" ,python-nbconvert)
6959 ("python-notebook" ,python-notebook)
6960 ("python-qtconsole" ,python-qtconsole)))
6961 (native-search-paths
6962 (list (search-path-specification
6963 (variable "JUPYTER_PATH")
6964 (files '("share/jupyter")))))
6965 (home-page "https://jupyter.org")
6966 (synopsis "Web application for interactive documents")
6968 "The Jupyter Notebook is a web application that allows you to create and
6969 share documents that contain live code, equations, visualizations and
6970 explanatory text. Uses include: data cleaning and transformation, numerical
6971 simulation, statistical modeling, machine learning and much more.")
6972 (license license:bsd-3)))
6974 (define-public python-chardet
6976 (name "python-chardet")
6981 (uri (pypi-uri "chardet" version))
6984 "1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4"))))
6986 `(("python-hypothesis" ,python-hypothesis)
6987 ("python-pytest" ,python-pytest)
6988 ("python-pytest-runner" ,python-pytest-runner)))
6989 (build-system python-build-system)
6990 (home-page "https://github.com/chardet/chardet")
6991 (synopsis "Universal encoding detector for Python 2 and 3")
6993 "This package provides @code{chardet}, a Python module that can
6994 automatically detect a wide range of file encodings.")
6995 (license license:lgpl2.1+)))
6997 (define-public python2-chardet
6998 (package-with-python2 python-chardet))
7000 (define-public python-docopt
7002 (name "python-docopt")
7007 ;; The release on PyPI does not include tests.
7009 "https://github.com/docopt/docopt/archive/"
7011 (file-name (string-append name "-" version ".tar.gz"))
7014 "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1"))))
7015 (build-system python-build-system)
7017 `(("python-pytest" ,python-pytest)))
7020 (modify-phases %standard-phases
7022 (lambda _ (invoke "py.test"))))))
7023 (home-page "http://docopt.org")
7024 (synopsis "Command-line interface description language for Python")
7025 (description "This library allows the user to define a command-line
7026 interface from a program's help message rather than specifying it
7027 programatically with command-line parsers like @code{getopt} and
7029 (license license:expat)))
7031 (define-public python2-docopt
7032 (package-with-python2 python-docopt))
7034 (define-public python-pythondialog
7036 (name "python-pythondialog")
7041 (uri (pypi-uri "pythondialog" version))
7044 "1728ghsran47jczn9bhlnkvk5bvqmmbihabgif5h705b84r1272c"))))
7045 (build-system python-build-system)
7048 (modify-phases %standard-phases
7049 (add-after 'unpack 'patch-path
7050 (lambda* (#:key inputs #:allow-other-keys)
7051 (let* ((dialog (assoc-ref inputs "dialog")))
7052 ;; Since this library really wants to grovel the search path, we
7053 ;; must hardcode dialog's store path into it.
7054 (substitute* "dialog.py"
7055 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
7056 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
7058 #:tests? #f)) ; no test suite
7060 `(("dialog" ,dialog)))
7061 (home-page "http://pythondialog.sourceforge.net/")
7062 (synopsis "Python interface to the UNIX dialog utility")
7063 (description "A Python wrapper for the dialog utility. Its purpose is to
7064 provide an easy to use, pythonic and comprehensive Python interface to dialog.
7065 This allows one to make simple text-mode user interfaces on Unix-like systems")
7066 (license license:lgpl2.1)
7067 (properties `((python2-variant . ,(delay python2-pythondialog))))))
7069 (define-public python2-pythondialog
7070 (let ((base (package-with-python2 (strip-python2-variant python-pythondialog))))
7073 (version (package-version python-pythondialog))
7076 (uri (pypi-uri "python2-pythondialog" version))
7079 "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9")))))))
7081 (define-public python-configobj
7083 (name "python-configobj")
7087 (uri (pypi-uri "configobj" version))
7090 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
7091 ;; Patch setup.py so it looks for python-setuptools, which is
7092 ;; required to parse the keyword 'install_requires' in setup.py.
7093 (patches (search-patches "python-configobj-setuptools.patch"))))
7094 (build-system python-build-system)
7096 `(("python-six" ,python-six)))
7097 (synopsis "Config file reading, writing and validation")
7098 (description "ConfigObj is a simple but powerful config file reader and
7099 writer: an ini file round tripper. Its main feature is that it is very easy to
7100 use, with a straightforward programmer’s interface and a simple syntax for
7102 (home-page "https://github.com/DiffSK/configobj")
7103 (license license:bsd-3)))
7105 (define-public python2-configobj
7106 (package-with-python2 python-configobj))
7108 (define-public python-configargparse
7110 (name "python-configargparse")
7114 (uri (pypi-uri "ConfigArgParse" version))
7117 "149fy4zya0rsnlkvxbbq43cyr8lscb5k4pj1m6n7f1grwcmzwbif"))))
7118 (build-system python-build-system)
7120 `(("python-pyyaml" ,python-pyyaml)))
7123 (modify-phases %standard-phases
7126 ;; Bypass setuptools-shim because one test relies on "setup.py"
7127 ;; being the first argument passed to the python call.
7129 ;; NOTE: Many tests do not run because they rely on Python's
7130 ;; built-in test.test_argparse, but we remove the unit tests from
7131 ;; our Python installation.
7132 (invoke "python" "setup.py" "test"))))))
7133 (synopsis "Replacement for argparse")
7134 (description "A drop-in replacement for argparse that allows options to also
7135 be set via config files and/or environment variables.")
7136 (home-page "https://github.com/bw2/ConfigArgParse")
7137 (license license:expat)))
7139 (define-public python2-configargparse
7140 (package-with-python2 python-configargparse))
7142 (define-public python-argparse-manpage
7144 (name "python-argparse-manpage")
7149 (uri (pypi-uri "argparse-manpage" version))
7152 "0blh31zns68anina9lba5wh81d1414s97p60zw5l0d0shhh0wj5p"))))
7153 (build-system python-build-system)
7154 (home-page "https://github.com/praiskup/argparse-manpage")
7155 (synopsis "Build manual page from Python's ArgumentParser object")
7157 "This package provides tools to build manual pages from Python's
7158 @code{ArgumentParser} object.")
7159 (license license:asl2.0)))
7161 (define-public python2-contextlib2
7163 (name "python2-contextlib2")
7168 (uri (pypi-uri "contextlib2" version))
7171 "0j6ad6lwwyc9kv71skj098v5l7x5biyj2hs4lc5x1kcixqcr97sh"))))
7172 (build-system python-build-system)
7174 `(#:python ,python-2
7176 (modify-phases %standard-phases
7178 (lambda _ (invoke "python" "test_contextlib2.py" "-v"))))))
7180 `(("python2-unittest2" ,python2-unittest2)))
7181 (home-page "http://contextlib2.readthedocs.org/")
7182 (synopsis "Tools for decorators and context managers")
7183 (description "This module is primarily a backport of the Python
7184 3.2 contextlib to earlier Python versions. Like contextlib, it
7185 provides utilities for common tasks involving decorators and context
7186 managers. It also contains additional features that are not part of
7187 the standard library.")
7188 (license license:psfl)))
7190 (define-public python-texttable
7192 (name "python-texttable")
7197 (uri (pypi-uri "texttable" version))
7200 "1liiiydgkg37i46a418aw19fyf6z3ds51wdwwpyjbs12x0phhf4a"))))
7201 (build-system python-build-system)
7202 (arguments '(#:tests? #f)) ; no tests
7203 (home-page "https://github.com/foutaise/texttable/")
7204 (synopsis "Python module for creating simple ASCII tables")
7205 (description "Texttable is a Python module for creating simple ASCII
7207 (license license:lgpl2.1+)))
7209 (define-public python2-texttable
7210 (package-with-python2 python-texttable))
7212 (define-public python-atomicwrites
7214 (name "python-atomicwrites")
7218 (uri (pypi-uri "atomicwrites" version))
7221 "11bm90fwm2avvf4f3ib8g925w7jr4m11vcsinn1bi6ns4bm32214"))))
7222 (build-system python-build-system)
7223 (synopsis "Atomic file writes in Python")
7224 (description "Library for atomic file writes using platform dependent tools
7225 for atomic file system operations.")
7226 (home-page "https://github.com/untitaker/python-atomicwrites")
7227 (license license:expat)))
7229 (define-public python2-atomicwrites
7230 (package-with-python2 python-atomicwrites))
7232 (define-public python-click-threading
7234 (name "python-click-threading")
7238 (uri (pypi-uri "click-threading" version))
7241 "1rsxc2fbkxlhwhlmxsdjzq3spn284l6rvjfcz9mbb17ibgdgmc5j"))))
7242 (build-system python-build-system)
7244 `(("python-click" ,python-click)))
7245 (synopsis "Utilities for multithreading in Click")
7246 (description "This package provides utilities for multithreading in Click
7248 (home-page "https://github.com/click-contrib/click-threading")
7249 (license license:expat)))
7251 (define-public python-click-log
7253 (name "python-click-log")
7257 (uri (pypi-uri "click-log" version))
7260 "091i03bhxyzsdbc6kilxhivfda2f8ymz3b33xa6cj5kbzjiirz8n"))))
7261 (build-system python-build-system)
7263 `(("python-click" ,python-click)))
7264 (synopsis "Logging for click applications")
7265 (description "This package provides a Python library for logging Click
7267 (home-page "https://github.com/click-contrib/click-log")
7268 (license license:expat)))
7270 (define-public python-apipkg
7272 (name "python-apipkg")
7276 (uri (pypi-uri "apipkg" version))
7279 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
7280 (build-system python-build-system)
7282 `(("python-pytest" ,python-pytest)))
7283 (synopsis "Namespace control and lazy-import mechanism")
7284 (description "With apipkg you can control the exported namespace of a Python
7285 package and greatly reduce the number of imports for your users. It is a small
7286 pure Python module that works on virtually all Python versions.")
7287 (home-page "https://github.com/pytest-dev/apipkg")
7288 (license license:expat)))
7290 (define-public python2-apipkg
7291 (package-with-python2 python-apipkg))
7293 (define-public python-execnet
7295 (name "python-execnet")
7299 (uri (pypi-uri "execnet" version))
7302 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
7303 (build-system python-build-system)
7305 `(;; 2 failed, 275 passed, 670 skipped, 4 xfailed
7306 ;; The two test failures are caused by the lack of an `ssh` executable.
7307 ;; The test suite can be run with pytest after the 'install' phase.
7310 `(("python-pytest" ,python-pytest)
7311 ("python-setuptools-scm" ,python-setuptools-scm)))
7313 `(("python-apipkg" ,python-apipkg)))
7314 (synopsis "Rapid multi-Python deployment")
7315 (description "Execnet provides a share-nothing model with
7316 channel-send/receive communication for distributing execution across many
7317 Python interpreters across version, platform and network barriers. It has a
7318 minimal and fast API targeting the following uses:
7320 @item distribute tasks to (many) local or remote CPUs
7321 @item write and deploy hybrid multi-process applications
7322 @item write scripts to administer multiple environments
7324 (home-page "http://codespeak.net/execnet/")
7325 (license license:expat)))
7327 (define-public python2-execnet
7328 (package-with-python2 python-execnet))
7330 (define-public python-icalendar
7332 (name "python-icalendar")
7336 (uri (pypi-uri "icalendar" version))
7339 "0mk3dk1dxkcm46jy48v27j2w2349iv4sbimqj1yb5js43mx49hh7"))))
7340 (build-system python-build-system)
7342 `(("python-dateutil" ,python-dateutil)
7343 ("python-pytz" ,python-pytz)))
7344 (synopsis "Python library for parsing iCalendar files")
7345 (description "The icalendar package is a parser/generator of iCalendar
7346 files for use with Python.")
7347 (home-page "https://github.com/collective/icalendar")
7348 (license license:bsd-2)))
7350 (define-public python-sphinxcontrib-newsfeed
7352 (name "python-sphinxcontrib-newsfeed")
7356 (uri (pypi-uri "sphinxcontrib-newsfeed" version))
7359 "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p"))))
7360 (arguments '(#:tests? #f)) ; No tests.
7361 (build-system python-build-system)
7363 `(("python-sphinx" ,python-sphinx)))
7364 (synopsis "News Feed extension for Sphinx")
7365 (description "Sphinxcontrib-newsfeed is an extension for adding a simple
7366 Blog, News or Announcements section to a Sphinx website.")
7367 (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed")
7368 (license license:bsd-2)))
7370 (define-public python-args
7372 (name "python-args")
7376 (uri (pypi-uri "args" version))
7379 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
7380 (build-system python-build-system)
7381 (home-page "https://github.com/kennethreitz/args")
7382 (synopsis "Command-line argument parser")
7384 "This library provides a Python module to parse command-line arguments.")
7385 (license license:bsd-3)))
7387 (define-public python2-args
7388 (package-with-python2 python-args))
7390 (define-public python-clint
7392 (name "python-clint")
7396 (uri (pypi-uri "clint" version))
7399 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
7400 (build-system python-build-system)
7403 (modify-phases %standard-phases
7405 (lambda _ (invoke "py.test" "-v"))))))
7407 `(("python-pytest" ,python-pytest)))
7409 `(("python-args" ,python-args)))
7410 (home-page "https://github.com/kennethreitz/clint")
7411 (synopsis "Command-line interface tools")
7413 "Clint is a Python module filled with a set of tools for developing
7414 command-line applications, including tools for colored and indented
7415 output, progress bar display, and pipes.")
7416 (license license:isc)))
7418 (define-public python2-clint
7419 (package-with-python2 python-clint))
7421 (define-public python-rply
7423 (name "python-rply")
7427 (uri (pypi-uri "rply" version))
7430 "0lv428895zxsz43968qx0q9bimwqnfykndz4dpjbq515w2gvzhjh"))))
7431 (build-system python-build-system)
7433 `(("python-appdirs" ,python-appdirs)))
7434 (home-page "https://github.com/alex/rply")
7435 (synopsis "Parser generator for Python")
7437 "This package provides a pure Python based parser generator, that also
7438 works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
7439 with a new public API, and RPython support.")
7440 (license license:bsd-3)))
7442 (define-public python2-rply
7443 (package-with-python2 python-rply))
7445 (define-public python-hy
7451 (uri (pypi-uri "hy" version))
7454 "19sfymaksx9jhksfnb15ahid46mzrhdfzz6yy2craz2qnzvpmky8"))))
7455 (build-system python-build-system)
7458 (modify-phases %standard-phases
7461 ;; Tests require write access to HOME.
7462 (setenv "HOME" "/tmp")
7463 (invoke "nosetests"))))))
7465 `(("python-coverage" ,python-coverage)
7466 ("python-nose" ,python-nose)))
7468 `(("python-astor" ,python-astor)
7469 ("python-clint" ,python-clint)
7470 ("python-rply" ,python-rply)))
7471 (home-page "http://hylang.org/")
7472 (synopsis "Lisp frontend to Python")
7474 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
7475 its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
7476 Python at your fingertips, in Lisp form.")
7477 (license license:expat)))
7479 (define-public python2-hy
7480 (package-with-python2 python-hy))
7482 (define-public python2-functools32
7484 (name "python2-functools32")
7489 (uri (pypi-uri "functools32" version))
7492 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
7493 (build-system python-build-system)
7495 `(#:python ,python-2
7496 #:tests? #f)) ; no test target
7497 (home-page "https://github.com/MiCHiLU/python-functools32")
7499 "Backport of the functools module from Python 3.2.3")
7501 "This package is a backport of the @code{functools} module from Python
7502 3.2.3 for use with older versions of Python and PyPy.")
7503 (license license:expat)))
7505 (define-public python2-subprocess32
7507 (name "python2-subprocess32")
7511 (uri (pypi-uri "subprocess32" version))
7514 "14350dhhlhyz5gqzi3lihn9m6lvskx5mcb20srx1kgsk9i50li8y"))
7516 (search-patches "python2-subprocess32-disable-input-test.patch"))))
7517 (build-system python-build-system)
7519 `(#:python ,python-2
7520 ;; The test suite fails with Python > 2.7.13:
7521 ;; import test.support
7522 ;; ImportError: No module named support
7525 (modify-phases %standard-phases
7526 (add-after 'unpack 'patch-/bin/sh
7528 (substitute* '("subprocess32.py"
7529 "test_subprocess32.py")
7530 (("/bin/sh") (which "sh")))
7532 (home-page "https://github.com/google/python-subprocess32")
7533 (synopsis "Backport of the subprocess module from Python 3.2")
7535 "This is a backport of the @code{subprocess} standard library module
7536 from Python 3.2 and 3.3 for use on Python 2. It includes bugfixes and some
7537 new features. On POSIX systems it is guaranteed to be reliable when used
7538 in threaded applications. It includes timeout support from Python 3.3 but
7539 otherwise matches 3.2’s API.")
7540 (license license:psfl)))
7542 (define-public python2-futures
7544 (name "python2-futures")
7549 (uri (pypi-uri "futures" version))
7552 "0rdjmmsab550kxsssdq49jcniz77zlkpw4pvi9hvib3lsskjmh4y"))))
7553 (build-system python-build-system)
7554 (arguments `(#:python ,python-2
7555 ;; FIXME: Python 2.7.14 moved the test.support library,
7556 ;; but our package has not yet been adjusted. Enable
7557 ;; tests when the python2 package has been fixed.
7559 (home-page "https://github.com/agronholm/pythonfutures")
7561 "Backport of the concurrent.futures package from Python 3.2")
7563 "The concurrent.futures module provides a high-level interface for
7564 asynchronously executing callables. This package backports the
7565 concurrent.futures package from Python 3.2")
7566 (license license:bsd-3)))
7568 (define-public python-promise
7570 (name "python-promise")
7575 (uri (pypi-uri "promise" version))
7578 "1k19ms8l3d5jzjh557rgkxb5sg4mqgfc315rn4hx1z3n8qq6lr3h"))))
7579 (build-system python-build-system)
7580 ;; Tests wants python-futures, which is a python2 only program, and
7581 ;; can't be found by python-promise at test time.
7582 (arguments `(#:tests? #f))
7583 (home-page "https://github.com/syrusakbary/promise")
7584 (synopsis "Promises/A+ implementation for Python")
7586 "Promises/A+ implementation for Python")
7587 (properties `((python2-variant . ,(delay python2-promise))))
7588 (license license:expat)))
7590 (define-public python2-promise
7591 (let ((promise (package-with-python2
7592 (strip-python2-variant python-promise))))
7593 (package (inherit promise)
7594 (arguments (substitute-keyword-arguments (package-arguments promise)
7597 `(("python2-futures" ,python2-futures)
7598 ("python2-pytest" ,python2-pytest)
7599 ,@(package-native-inputs promise))))))
7601 (define-public python-colorama
7603 (name "python-colorama")
7608 (uri (pypi-uri "colorama" version))
7611 "1wd1szk0z3073ghx26ynw43gnc140ibln1safgsis6s6z3s25ss8"))))
7612 (build-system python-build-system)
7613 (synopsis "Colored terminal text rendering for Python")
7614 (description "Colorama is a Python library for rendering colored terminal
7616 (home-page "https://pypi.python.org/pypi/colorama")
7617 (license license:bsd-3)))
7619 (define-public python2-colorama
7620 (package-with-python2 python-colorama))
7622 (define-public python-rsa
7629 (uri (pypi-uri "rsa" version))
7632 "1dcxvszbikgzh99ybdc7jq0zb9wspy2ds8z9mjsqiyv3q884xpr5"))))
7633 (build-system python-build-system)
7635 `(("python-pyasn1" ,python-pyasn1)))
7636 (synopsis "Pure-Python RSA implementation")
7637 (description "Python-RSA is a pure-Python RSA implementation. It supports
7638 encryption and decryption, signing and verifying signatures, and key
7639 generation according to PKCS#1 version 1.5. It can be used as a Python
7640 library as well as on the command line.")
7641 (home-page "https://stuvel.eu/rsa")
7642 (license license:asl2.0)))
7644 (define-public python2-rsa
7645 (package-with-python2 python-rsa))
7647 (define-public python-pluggy
7649 (name "python-pluggy")
7654 (uri (pypi-uri "pluggy" version))
7657 "1qbn70mksmr03hac6jgp6fiqc4l7859z8dchx2x950vhlij87swm"))))
7658 (build-system python-build-system)
7660 `(("python-setuptools-scm" ,python-setuptools-scm)))
7661 (synopsis "Plugin and hook calling mechanism for Python")
7662 (description "Pluggy is an extraction of the plugin manager as used by
7663 Pytest but stripped of Pytest specific details.")
7664 (home-page "https://pypi.python.org/pypi/pluggy")
7665 (license license:expat)))
7667 (define-public python2-pluggy
7668 (package-with-python2 python-pluggy))
7670 (define-public python-tox
7677 (uri (pypi-uri "tox" version))
7680 "1drp6mwm8wdypjym15ia8lwjxbhcksb9vzxg4ay5dh4ji57by2ny"))))
7681 (build-system python-build-system)
7683 ;; FIXME: Tests require pytest-timeout, which itself requires
7684 ;; pytest>=2.8.0 for installation.
7687 `(("python-pluggy" ,python-pluggy) ; >=0.3.0,<0.4.0
7688 ("python-py" ,python-py)
7689 ("python-virtualenv" ,python-virtualenv)))
7691 `(; FIXME: Missing: ("python-pytest-timeout" ,python-pytest-timeout)
7692 ("python-pytest" ,python-pytest) ; >= 2.3.5
7693 ("python-setuptools-scm" ,python-setuptools-scm)))
7694 (home-page "http://tox.testrun.org/")
7695 (synopsis "Virtualenv-based automation of test activities")
7696 (description "Tox is a generic virtualenv management and test command line
7697 tool. It can be used to check that a package installs correctly with
7698 different Python versions and interpreters, or run tests in each type of
7699 supported environment, or act as a frontend to continuous integration
7701 (license license:expat)))
7703 (define-public python2-tox
7704 (package-with-python2 python-tox))
7706 (define-public python-jmespath
7708 (name "python-jmespath")
7713 (uri (pypi-uri "jmespath" version))
7716 "0r7wc7fsxmlwzxx9j1j7rms06c6xs6d4sysirdhz1jk2mb4x90ba"))))
7717 (build-system python-build-system)
7719 `(("python-nose" ,python-nose)))
7720 (synopsis "JSON Matching Expressions")
7721 (description "JMESPath (pronounced “james path”) is a Python library that
7722 allows one to declaratively specify how to extract elements from a JSON
7724 (home-page "https://github.com/jmespath/jmespath.py")
7725 (license license:expat)))
7727 (define-public python2-jmespath
7728 (package-with-python2 python-jmespath))
7730 (define-public python-botocore
7732 (name "python-botocore")
7737 (uri (pypi-uri "botocore" version))
7740 "12cqpbnz3vfv41mp9admvciw7bc7hz57sjpqs2bxaw9wnfmbw5lg"))))
7741 (build-system python-build-system)
7743 ;; FIXME: Many tests are failing.
7746 `(("python-dateutil" ,python-dateutil)
7747 ("python-docutils" ,python-docutils)
7748 ("python-jmespath" ,python-jmespath)))
7750 `(("python-mock" ,python-mock)
7751 ("python-nose" ,python-nose)
7753 ("python-tox" ,python-tox)
7754 ("python-wheel" ,python-wheel)))
7755 (home-page "https://github.com/boto/botocore")
7756 (synopsis "Low-level interface to AWS")
7757 (description "Botocore is a Python library that provides a low-level
7758 interface to the Amazon Web Services (AWS) API.")
7759 (license license:asl2.0)))
7761 (define-public python2-botocore
7762 (package-with-python2 python-botocore))
7764 (define-public python-xdo
7771 "http://http.debian.net/debian/pool/main/p/python-xdo/"
7772 "python-xdo_" version ".orig.tar.gz"))
7775 "1vqh1n5yy5dhnq312kwrl90fnck4v26is3lq3lxdvcn60vv19da0"))))
7776 (build-system python-build-system)
7779 (modify-phases %standard-phases
7780 (add-before 'install 'patch-libxdo-path
7781 ;; Hardcode the path of dynamically loaded libxdo library.
7782 (lambda* (#:key inputs #:allow-other-keys)
7783 (let ((libxdo (string-append
7784 (assoc-ref inputs "xdotool")
7786 (substitute* "xdo/_xdo.py"
7787 (("find_library\\(\"xdo\"\\)")
7788 (simple-format #f "\"~a\"" libxdo)))
7790 #:tests? #f)) ; no tests provided
7792 `(("python-six" ,python-six)))
7794 `(("xdotool" ,xdotool)
7795 ("libX11" ,libx11)))
7796 (home-page "https://tracker.debian.org/pkg/python-xdo")
7797 (synopsis "Python library for simulating X11 keyboard/mouse input")
7798 (description "Provides bindings to libxdo for manipulating X11 via simulated
7799 input. (Note that this is mostly a legacy library; you may wish to look at
7800 python-xdo for newer bindings.)")
7801 (license license:bsd-3)))
7803 (define-public python2-xdo
7804 (package-with-python2 python-xdo))
7806 (define-public python-mako
7808 (name "python-mako")
7813 (uri (pypi-uri "Mako" version))
7816 "1bi5gnr8r8dva06qpyx4kgjc6spm2k1y908183nbbaylggjzs0jf"))))
7817 (build-system python-build-system)
7819 `(("python-markupsafe" ,python-markupsafe)))
7821 `(("python-mock" ,python-mock)
7822 ("python-nose" ,python-nose)
7823 ("python-pytest" ,python-pytest)))
7824 (home-page "http://www.makotemplates.org/")
7825 (synopsis "Templating language for Python")
7826 (description "Mako is a templating language for Python that compiles
7827 templates into Python modules.")
7828 (license license:expat)))
7830 (define-public python2-mako
7831 (package-with-python2 python-mako))
7833 (define-public python-waitress
7835 (name "python-waitress")
7840 (uri (pypi-uri "waitress" version))
7841 (patches (search-patches "python-waitress-fix-tests.patch"))
7844 "1a85gyji0kajc3p0s1pwwfm06w4wfxjkvvl4rnrz3h164kbd6g6k"))))
7845 (build-system python-build-system)
7846 (home-page "https://github.com/Pylons/waitress")
7847 (synopsis "Waitress WSGI server")
7848 (description "Waitress is meant to be a production-quality pure-Python WSGI
7849 server with very acceptable performance.")
7850 (license license:zpl2.1)))
7852 (define-public python2-waitress
7853 (package-with-python2 python-waitress))
7855 (define-public python-pyquery
7857 (name "python-pyquery")
7862 (uri (pypi-uri "pyquery" version))
7865 "1xia20wm0vx5dk85kcwgh13bylz8qh47ffjxssd2586r60xi783a"))))
7866 (build-system python-build-system)
7868 `(("python-webob" ,python-webob)
7869 ("python-webtest" ,python-webtest)))
7871 `(("python-lxml" ,python-lxml)
7872 ("python-cssselect" ,python-cssselect)))
7873 (home-page "https://github.com/gawel/pyquery")
7874 (synopsis "Make jQuery-like queries on xml documents")
7875 (description "pyquery allows you to make jQuery queries on xml documents.
7876 The API is as much as possible the similar to jQuery. pyquery uses lxml for
7877 fast xml and html manipulation.")
7878 (license license:bsd-3)))
7880 (define-public python2-pyquery
7881 (package-with-python2 python-pyquery))
7883 (define-public python-anyjson
7885 (name "python-anyjson")
7890 (uri (pypi-uri "anyjson" version))
7893 "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
7894 (build-system python-build-system)
7896 `(;; We could possibly get tests working, but on Python 3 it's not so easy.
7897 ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
7898 ;; whatever) so this transformation needs to be done before the tests
7899 ;; can be run. Maybe we could add a build step to transform beforehand
7900 ;; but it could be annoying/difficult.
7901 ;; We can enable tests for the Python 2 version, though, and do below.
7903 (home-page "https://bitbucket.org/runeh/anyjson/")
7905 "Wraps best available JSON implementation in a common interface")
7907 "Anyjson loads whichever is the fastest JSON module installed
7908 and provides a uniform API regardless of which JSON implementation is used.")
7909 (license license:bsd-3)
7910 (properties `((python2-variant . ,(delay python2-anyjson))))))
7912 (define-public python2-anyjson
7913 (let ((anyjson (package-with-python2
7914 (strip-python2-variant python-anyjson))))
7917 (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
7919 ,@(package-arguments anyjson)))
7920 (native-inputs `(("python2-nose" ,python2-nose))))))
7922 (define-public python-amqp
7924 (name "python-amqp")
7929 (uri (pypi-uri "amqp" version))
7932 "1sv600dgqwpimr6i1g59y9hpn50mc236gdqkr7zin13kvlpx0g87"))))
7933 (build-system python-build-system)
7935 `(("python-case" ,python-case)
7936 ("python-pytest-sugar" ,python-pytest-sugar)
7937 ("python-mock" ,python-mock)))
7939 `(("python-vine" ,python-vine)))
7940 (home-page "https://github.com/celery/py-amqp")
7942 "Low-level AMQP client for Python (fork of amqplib)")
7944 "This is a fork of amqplib which was originally written by Barry Pederson.
7945 It is maintained by the Celery project, and used by kombu as a pure python
7946 alternative when librabbitmq is not available.")
7947 (license license:lgpl2.1+)
7948 (properties `((python2-variant . ,(delay python2-amqp))))))
7950 (define-public python2-amqp
7951 (let ((amqp (package-with-python2
7952 (strip-python2-variant python-amqp))))
7955 (arguments `(;; Tries to run coverage tests with nose-cover3, which seems
7956 ;; unmaintained. Weirdly, does not do this on the python 3
7959 ,@(package-arguments amqp))))))
7961 (define-public python-txamqp
7963 (name "python-txamqp")
7968 (uri (pypi-uri "txAMQP" version))
7971 "0jd9864k3csc06kipiwzjlk9mq4054s8kzk5q1cfnxj8572s4iv4"))))
7972 (build-system python-build-system)
7974 `(("python-six" ,python-six)
7975 ("python-twisted" ,python-twisted)))
7976 (home-page "https://github.com/txamqp/txamqp")
7977 (synopsis "Communicate with AMQP peers and brokers using Twisted")
7979 "This package provides a Python library for communicating with AMQP peers
7980 and brokers using the asynchronous networking framework Twisted. It contains
7981 all the necessary code to connect, send and receive messages to/from an
7982 AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It
7983 also includes support for using Thrift RPC over AMQP in Twisted
7985 (license license:asl2.0)))
7987 (define-public python2-txamqp
7988 (package-with-python2 python-txamqp))
7990 (define-public python-kombu
7992 (name "python-kombu")
7997 (uri (pypi-uri "kombu" version))
8000 "15k8f7mzqr049sg9vi48m19vjykviafk3f0p5xzgw9by0x0kyxjj"))))
8001 (build-system python-build-system)
8003 `(("python-mock" ,python-mock)
8004 ("python-case" ,python-case)
8005 ("python-pyro4" ,python-pyro4)
8006 ("python-pytest-sugar" ,python-pytest-sugar)
8007 ("python-pytz" ,python-pytz)))
8009 `(("python-anyjson" ,python-anyjson)
8010 ("python-amqp" ,python-amqp)
8011 ("python-redis" ,python-redis)))
8012 (home-page "https://kombu.readthedocs.io")
8013 (synopsis "Message passing library for Python")
8014 (description "The aim of Kombu is to make messaging in Python as easy as
8015 possible by providing an idiomatic high-level interface for the AMQ protocol,
8016 and also provide proven and tested solutions to common messaging problems.
8017 AMQP is the Advanced Message Queuing Protocol, an open standard protocol for
8018 message orientation, queuing, routing, reliability and security, for which the
8019 RabbitMQ messaging server is the most popular implementation.")
8020 (license license:bsd-3)
8021 (properties `((python2-variant . ,(delay python2-kombu))))))
8023 (define-public python2-kombu
8024 (let ((kombu (package-with-python2
8025 (strip-python2-variant python-kombu))))
8028 (arguments `(;; FIXME: 'TestTransport.test_del_sync' fails on python2.
8029 ;; It works fine on the python3 variant.
8031 ,@(package-arguments kombu)))
8032 (native-inputs `(("python2-unittest2" ,python2-unittest2)
8033 ,@(package-native-inputs kombu))))))
8035 (define-public python-billiard
8037 (name "python-billiard")
8042 (uri (pypi-uri "billiard" version))
8045 "03msmapj3s5zgqk87d646mafz7a01h5bm2wijalgpi0s80ks5na2"))))
8046 (build-system python-build-system)
8048 `(("python-case" ,python-case)
8049 ("python-pytest" ,python-pytest)))
8050 (home-page "https://github.com/celery/billiard")
8052 "Python multiprocessing fork with improvements and bugfixes")
8054 "Billiard is a fork of the Python 2.7 multiprocessing package. The
8055 multiprocessing package itself is a renamed and updated version of R Oudkerk's
8056 pyprocessing package. This standalone variant is intended to be compatible with
8057 Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.")
8058 (license license:bsd-3)
8059 (properties `((python2-variant . ,(delay python2-billiard))))))
8061 (define-public python2-billiard
8062 (let ((billiard (package-with-python2
8063 (strip-python2-variant python-billiard))))
8066 (native-inputs `(("python2-unittest2" ,python2-unittest2)
8067 ("python2-mock" ,python2-mock)
8068 ,@(package-native-inputs billiard))))))
8070 (define-public python-celery
8072 (name "python-celery")
8077 (uri (pypi-uri "celery" version))
8080 "0y66rz7z8dfcgs3s0qxmdddlaq57bzbgxgfz896nbp14grkv9nkp"))))
8081 (build-system python-build-system)
8083 '(;; TODO The tests fail with Python 3.7
8084 ;; https://github.com/celery/celery/issues/4849
8087 (modify-phases %standard-phases
8088 (add-after 'unpack 'patch-requirements
8090 (substitute* "requirements/test.txt"
8091 (("pytest>=3\\.0,<3\\.3")
8095 `(("python-case" ,python-case)
8096 ("python-pytest" ,python-pytest)))
8098 `(("python-pytz" ,python-pytz)
8099 ("python-billiard" ,python-billiard)
8100 ("python-kombu" ,python-kombu)))
8101 (home-page "https://celeryproject.org")
8102 (synopsis "Distributed Task Queue")
8103 (description "Celery is an asynchronous task queue/job queue based on
8104 distributed message passing. It is focused on real-time operation, but
8105 supports scheduling as well. The execution units, called tasks, are executed
8106 concurrently on a single or more worker servers using multiprocessing,
8107 Eventlet, or gevent. Tasks can execute asynchronously (in the background) or
8108 synchronously (wait until ready).")
8109 (license license:bsd-3)
8110 (properties `((python2-variant . ,(delay python2-celery))))))
8112 (define-public python2-celery
8113 (let ((celery (package-with-python2
8114 (strip-python2-variant python-celery))))
8117 (native-inputs `(("python2-unittest2" ,python2-unittest2)
8118 ("python2-mock" ,python2-mock)
8119 ,@(package-native-inputs celery))))))
8121 (define-public python-translitcodec
8123 (name "python-translitcodec")
8128 (uri (pypi-uri "translitcodec" version))
8131 "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki"))))
8132 (build-system python-build-system)
8134 `(#:tests? #f)) ; no tests provided
8136 "https://github.com/claudep/translitcodec")
8138 "Unicode to 8-bit charset transliteration codec")
8140 "This package contains codecs for transliterating ISO 10646 texts into
8141 best-effort representations using smaller coded character sets (ASCII,
8143 (license license:expat)))
8145 (define-public python2-translitcodec
8146 (package-with-python2 python-translitcodec))
8148 (define-public python-editor
8150 (name "python-editor")
8155 (uri (pypi-uri "python-editor" version))
8158 "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n"))))
8159 (build-system python-build-system)
8161 "https://github.com/fmoo/python-editor")
8163 "Programmatically open an editor, capture the result")
8165 "python-editor is a library that provides the editor module for
8166 programmatically interfacing with your system's $EDITOR.")
8167 (license license:asl2.0)))
8169 (define-public python2-editor
8170 (package-with-python2 python-editor))
8172 (define-public python-sphinxcontrib-programoutput
8174 (name "python-sphinxcontrib-programoutput")
8178 (uri (pypi-uri "sphinxcontrib-programoutput" version))
8181 "153hhnlbx4688zj9wd64819ps5znc2jlyp5crkgzvn5hxgy99vpx"))))
8182 (build-system python-build-system)
8184 ;; FIXME: Many tests are failing and the upstream is gone.
8187 `(("python-sphinx" ,python-sphinx)))
8188 (synopsis "Sphinx extension to include program output")
8189 (description "A Sphinx extension to literally insert the output of arbitrary
8190 commands into documents, helping you to keep your command examples up to date.")
8191 (home-page "https://github.com/lunaryorn/sphinxcontrib-programoutput")
8192 (license license:bsd-2)))
8194 (define-public python2-sphinxcontrib-programoutput
8195 (package-with-python2 python-sphinxcontrib-programoutput))
8197 (define-public python-sphinx-repoze-autointerface
8199 (name "python-sphinx-repoze-autointerface")
8203 (uri (pypi-uri "repoze.sphinx.autointerface" version))
8206 "08ycivzf7bh4a1zcyp31hbyqs1b2c9r26raa3vxjwwmbfqr3iw4f"))))
8207 (build-system python-build-system)
8208 (arguments '(#:tests? #f)) ; No tests.
8210 `(("python-sphinx" ,python-sphinx)
8211 ("python-zope-interface" ,python-zope-interface)))
8212 (synopsis "Auto-generate Sphinx API docs from Zope interfaces")
8213 (description "This package defines an extension for the Sphinx documentation
8214 system. The extension allows generation of API documentation by
8215 introspection of @code{zope.interface} instances in code.")
8216 (home-page "https://github.com/repoze/repoze.sphinx.autointerface")
8217 (license license:repoze)))
8219 (define-public python2-sphinx-repoze-autointerface
8220 (package-with-python2 python-sphinx-repoze-autointerface))
8222 (define-public python-vobject
8224 (name "python-vobject")
8228 (uri (pypi-uri "vobject" version))
8231 "0hqjgf3ay1m5w1c0k00g5yfpdz1zni5qnr5rh9b8fg9hjvhwlmhg"))))
8232 (build-system python-build-system)
8234 '(;; The test suite relies on some non-portable Windows interfaces.
8237 `(("python-dateutil" ,python-dateutil)
8238 ("python-pyicu" ,python-pyicu)))
8239 (synopsis "Parse and generate vCard and vCalendar files")
8240 (description "Vobject is intended to be a full featured Python package for
8241 parsing and generating vCard and vCalendar files. Currently, iCalendar files
8242 are supported and well tested. vCard 3.0 files are supported, and all data
8243 should be imported, but only a few components are understood in a sophisticated
8245 (home-page "http://eventable.github.io/vobject/")
8246 (license license:asl2.0)))
8248 (define-public python2-vobject
8249 (package-with-python2 python-vobject))
8251 (define-public python-munkres
8253 (name "python-munkres")
8257 (uri (pypi-uri "munkres" version))
8260 "0mbspx4zv8id4x6pim6ybsa1xh96qwpbqj7skbqz4c9c9nf1lpqq"))))
8261 (build-system python-build-system)
8263 '(#:tests? #f)) ; no test suite
8264 (home-page "http://software.clapper.org/munkres/")
8265 (synopsis "Implementation of the Munkres algorithm")
8266 (description "The Munkres module provides an implementation of the Munkres
8267 algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm),
8268 useful for solving the Assignment Problem.")
8269 (license license:bsd-3)))
8271 (define-public python2-munkres
8272 (package-with-python2 python-munkres))
8274 (define-public python-whoosh
8276 (name "python-whoosh")
8281 (uri (pypi-uri "Whoosh" version))
8284 "10qsqdjpbc85fykc1vgcs8xwbgn4l2l52c8d83xf1q59pwyn79bw"))))
8285 (build-system python-build-system)
8287 `(("python-pytest" ,python-pytest)))
8288 (home-page "https://bitbucket.org/mchaput/whoosh")
8289 (synopsis "Full text indexing, search, and spell checking library")
8291 "Whoosh is a fast, pure-Python full text indexing, search, and spell
8293 (license license:bsd-2)))
8295 (define-public python2-whoosh
8296 (let ((whoosh (package-with-python2 (strip-python2-variant python-whoosh))))
8297 (package (inherit whoosh)
8299 `(("python2-backport-ssl-match-hostname"
8300 ,python2-backport-ssl-match-hostname)
8301 ,@(package-propagated-inputs whoosh))))))
8303 (define-public python-pathlib
8305 (name "python-pathlib")
8309 (uri (pypi-uri "pathlib" version))
8312 "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39"))))
8313 (build-system python-build-system)
8314 ;; The tests depend on the internal "test" module, which does not provide
8315 ;; a stable interface.
8316 (arguments `(#:tests? #f))
8317 (home-page "https://pathlib.readthedocs.org/")
8318 (synopsis "Object-oriented file system paths")
8319 (description "Pathlib offers a set of classes to handle file system paths.
8320 It offers the following advantages over using string objects:
8323 @item No more cumbersome use of os and os.path functions. Everything can
8324 be done easily through operators, attribute accesses, and method calls.
8325 @item Embodies the semantics of different path types. For example,
8326 comparing Windows paths ignores casing.
8327 @item Well-defined semantics, eliminating any inconsistencies or
8328 ambiguities (forward vs. backward slashes, etc.).
8331 Note: In Python 3.4, pathlib is now part of the standard library. For other
8332 Python versions please consider python-pathlib2 instead, which tracks the
8333 standard library module. This module (python-pathlib) isn't maintained
8335 (license license:expat)))
8337 (define-public python2-pathlib
8338 (package-with-python2 python-pathlib))
8340 (define-public python2-pathlib2
8342 (name "python2-pathlib2")
8346 (uri (pypi-uri "pathlib2" version))
8349 "10yb0iv5x2hs631rcppkhbddx799d3h8pcwmkbh2a66ns3w71ccf"))))
8350 (build-system python-build-system)
8351 ;; We only need the the Python 2 variant, since for Python 3 our minimum
8352 ;; version is 3.4 which already includes this package as part of the
8353 ;; standard library.
8355 `(#:python ,python-2))
8357 `(("python2-scandir" ,python2-scandir)
8358 ("python2-six" ,python2-six)))
8359 (home-page "https://pypi.python.org/pypi/pathlib2/")
8360 (synopsis "Object-oriented file system paths - backport of standard
8362 (description "The goal of pathlib2 is to provide a backport of standard
8363 pathlib module which tracks the standard library module, so all the newest
8364 features of the standard pathlib can be used also on older Python versions.
8366 Pathlib offers a set of classes to handle file system paths. It offers the
8367 following advantages over using string objects:
8370 @item No more cumbersome use of os and os.path functions. Everything can
8371 be done easily through operators, attribute accesses, and method calls.
8372 @item Embodies the semantics of different path types. For example,
8373 comparing Windows paths ignores casing.
8374 @item Well-defined semantics, eliminating any inconsistencies or
8375 ambiguities (forward vs. backward slashes, etc.).
8377 (license license:expat)))
8379 (define-public python2-pathlib2-bootstrap
8382 (inherit python2-pathlib2)
8383 (name "python2-pathlib2-bootstrap")
8385 `(("python2-scandir" ,python2-scandir)
8386 ("python2-six" ,python2-six-bootstrap))))))
8388 (define-public python-jellyfish
8390 (name "python-jellyfish")
8394 (uri (pypi-uri "jellyfish" version))
8397 "1j9rplb16ba2prjj6mip46z0w9pnhnqpwgiwi0x93vnas14rlyl8"))))
8398 (build-system python-build-system)
8400 `(("python-pytest" ,python-pytest)))
8401 (home-page "https://github.com/jamesturk/jellyfish")
8402 (synopsis "Approximate and phonetic matching of strings")
8403 (description "Jellyfish uses a variety of string comparison and phonetic
8404 encoding algorithms to do fuzzy string matching.")
8405 (license license:bsd-2)
8406 (properties `((python2-variant . ,(delay python2-jellyfish))))))
8408 (define-public python2-jellyfish
8409 (let ((jellyfish (package-with-python2
8410 (strip-python2-variant python-jellyfish))))
8411 (package (inherit jellyfish)
8412 (native-inputs `(("python2-unicodecsv" ,python2-unicodecsv)
8413 ,@(package-native-inputs jellyfish))))))
8415 (define-public python2-unicodecsv
8417 (name "python2-unicodecsv")
8421 ;; The test suite is not included in the PyPi release.
8422 ;; https://github.com/jdunck/python-unicodecsv/issues/19
8423 (uri (string-append "https://github.com/jdunck/python-unicodecsv/"
8424 "archive/" version ".tar.gz"))
8425 (file-name (string-append name "-" version ".tar.gz"))
8428 "087nqanfcyp6mlfbbr5lva5f3w6iz1bybls9xlrb8icmc474wh4w"))))
8429 (build-system python-build-system)
8431 `(;; It supports Python 3, but Python 3 can already do Unicode CSV.
8432 #:python ,python-2))
8434 `(("python2-unittest2" ,python2-unittest2)))
8435 (home-page "https://github.com/jdunck/python-unicodecsv")
8436 (synopsis "Unicode CSV module for Python 2")
8437 (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV
8438 module, adding support for Unicode strings.")
8439 (license license:bsd-2)))
8441 (define-public python-rarfile
8443 (name "python-rarfile")
8447 (uri (pypi-uri "rarfile" version))
8450 "0qfad483kcbga0bn4qmcz953xjk16r52fahiy46zzn56v80y89ra"))))
8451 (build-system python-build-system)
8454 (modify-phases %standard-phases
8456 ;; Many tests fail, but the installation proceeds.
8457 (lambda _ (invoke "make" "-C" "test" "test"))))))
8459 `(("which" ,which))) ; required for tests
8461 `(("libarchive" ,libarchive)))
8462 (home-page "https://github.com/markokr/rarfile")
8463 (synopsis "RAR archive reader for Python")
8464 (description "This is Python module for RAR archive reading. The interface
8465 is made as zipfile like as possible.")
8466 (license license:isc)))
8468 (define-public python2-rarfile
8469 (package-with-python2 python-rarfile))
8471 (define-public python-magic
8473 (name "python-magic")
8478 (uri (pypi-uri "python-magic" version))
8481 "1mgwig9pnzgkf86q9ji9pnc99bngms15lfszq5rgqb9db07mqxpk"))
8482 (file-name (string-append name "-" version "-checkout"))))
8483 (build-system python-build-system)
8485 ;; The tests are unreliable, so don't run them. The tests fail
8486 ;; under Python3 because they were written for Python2 and
8487 ;; contain import statements that do not work in Python3. One of
8488 ;; the tests fails under Python2 because its assertions are
8489 ;; overly stringent; it relies on comparing output strings which
8490 ;; are brittle and can change depending on the version of
8491 ;; libmagic being used and the system on which the test is
8492 ;; running. In my case, under GuixSD 0.10.0, only one test
8493 ;; failed, and it seems to have failed only because the version
8494 ;; of libmagic that is packaged in Guix outputs a slightly
8495 ;; different (but not wrong) string than the one that the test
8498 #:phases (modify-phases %standard-phases
8499 ;; Replace a specific method call with a hard-coded
8500 ;; path to the necessary libmagic.so file in the
8501 ;; store. If we don't do this, then the method call
8502 ;; will fail to find the libmagic.so file, which in
8503 ;; turn will cause any application using
8504 ;; python-magic to fail.
8505 (add-before 'build 'hard-code-path-to-libmagic
8506 (lambda* (#:key inputs #:allow-other-keys)
8507 (let ((file (assoc-ref inputs "file")))
8508 (substitute* "magic.py"
8509 (("ctypes.util.find_library\\('magic'\\)")
8510 (string-append "'" file "/lib/libmagic.so'")))
8512 (add-before 'install 'disable-egg-compression
8514 (let ((port (open-file "setup.cfg" "a")))
8515 (display "\n[easy_install]\nzip_ok = 0\n"
8520 ;; python-magic needs to be able to find libmagic.so.
8523 "https://github.com/ahupp/python-magic")
8525 "File type identification using libmagic")
8527 "This module uses ctypes to access the libmagic file type
8528 identification library. It makes use of the local magic database and
8529 supports both textual and MIME-type output. Note that this module and
8530 the python-file module both provide a \"magic.py\" file; these two
8531 modules, which are different and were developed separately, both serve
8532 the same purpose: to provide Python bindings for libmagic.")
8533 (license license:expat)))
8535 (define-public python2-magic
8536 (package-with-python2 python-magic))
8538 (define-public python2-s3cmd
8540 (name "python2-s3cmd")
8545 (uri (string-append "mirror://sourceforge/s3tools/s3cmd/" version "/"
8546 "s3cmd-" version ".tar.gz"))
8549 "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6"))))
8550 (build-system python-build-system)
8552 ;; s3cmd is written for python2 only and contains no tests.
8553 `(#:python ,python-2
8556 `(("python2-dateutil" ,python2-dateutil)
8557 ;; The python-file package also provides a magic.py module.
8558 ;; This is an unfortunate state of affairs; however, s3cmd
8559 ;; fails to install if it cannot find specifically the
8560 ;; python-magic package. Thus we include it, instead of using
8561 ;; python-file. Ironically, s3cmd sometimes works better
8562 ;; without libmagic bindings at all:
8563 ;; https://github.com/s3tools/s3cmd/issues/198
8564 ("python2-magic" ,python2-magic)))
8565 (home-page "http://s3tools.org/s3cmd")
8566 (synopsis "Command line tool for S3-compatible storage services")
8568 "S3cmd is a command line tool for uploading, retrieving and managing data
8569 in storage services that are compatible with the Amazon Simple Storage
8570 Service (S3) protocol, including S3 itself. It supports rsync-like backup,
8571 GnuPG encryption, and more. It also supports management of Amazon's
8572 CloudFront content delivery network.")
8573 (license license:gpl2+)))
8575 (define-public python-pkgconfig
8577 (name "python-pkgconfig")
8582 (uri (pypi-uri "pkgconfig" version))
8585 "107x2wmchlch8saixb488cgjz9n6inl38wi7nxkb942rbaapxiqb"))))
8586 (build-system python-build-system)
8588 `(("python-nose" ,python-nose)))
8590 `(("pkg-config" ,pkg-config)))
8593 (modify-phases %standard-phases
8594 (add-before 'build 'patch
8595 ;; Hard-code the path to pkg-config.
8597 (substitute* "pkgconfig/pkgconfig.py"
8598 (("cmd = 'pkg-config")
8599 (string-append "cmd = '" (which "pkg-config"))))
8603 (invoke "nosetests" "test.py"))))))
8604 (home-page "https://github.com/matze/pkgconfig")
8605 (synopsis "Python interface for pkg-config")
8606 (description "This module provides a Python interface to pkg-config. It
8607 can be used to find all pkg-config packages, check if a package exists,
8608 check if a package meets certain version requirements, query CFLAGS and
8609 LDFLAGS and parse the output to build extensions with setup.py.")
8610 (license license:expat)))
8612 (define-public python2-pkgconfig
8613 (package-with-python2 python-pkgconfig))
8615 (define-public python-bz2file
8617 (name "python-bz2file")
8622 (uri (pypi-uri "bz2file" version))
8625 "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4"))))
8626 (build-system python-build-system)
8628 `(#:tests? #f)) ; Tests use deprecated python modules.
8629 (home-page "https://github.com/nvawda/bz2file")
8630 (synopsis "Read and write bzip2-compressed files")
8632 "Bz2file is a Python library for reading and writing bzip2-compressed
8633 files. It contains a drop-in replacement for the I/O interface in the
8634 standard library's @code{bz2} module, including features from the latest
8635 development version of CPython that are not available in older releases.")
8636 (license license:asl2.0)))
8638 (define-public python2-bz2file
8639 (package-with-python2 python-bz2file))
8641 (define-public python-future
8643 (name "python-future")
8648 (uri (pypi-uri "future" version))
8651 "1nzy1k4m9966sikp0qka7lirh8sqrsyainyf8rk97db7nwdfv773"))))
8652 (build-system python-build-system)
8653 ;; Many tests connect to the network or are otherwise flawed.
8654 ;; https://github.com/PythonCharmers/python-future/issues/210
8657 (home-page "http://python-future.org")
8658 (synopsis "Single-source support for Python 3 and 2")
8660 "@code{python-future} is the missing compatibility layer between Python 2 and
8661 Python 3. It allows you to use a single, clean Python 3.x-compatible codebase
8662 to support both Python 2 and Python 3 with minimal overhead.")
8663 (license license:expat)))
8665 (define-public python2-future
8666 (package-with-python2 python-future))
8668 (define-public python-cysignals
8670 (name "python-cysignals")
8675 (uri (pypi-uri "cysignals" version))
8678 "15ix8crpad26cfl1skyg7qajqqfdrm8q5ahhmlfmqi1aw0jqj2g2"))))
8679 (build-system python-build-system)
8681 `(("python-cython" ,python-cython)
8682 ("python-sphinx" ,python-sphinx)))
8684 `(("pari-gp" ,pari-gp)))
8686 `(#:modules ((guix build python-build-system)
8687 ((guix build gnu-build-system) #:prefix gnu:)
8689 ;; FIXME: Tests are executed after installation and currently fail
8690 ;; when not installing into standard locations; the author is working
8694 (modify-phases %standard-phases
8697 (assoc-ref gnu:%standard-phases 'configure)))))
8699 "https://github.com/sagemath/cysignals")
8701 "Handling of interrupts and signals for Cython")
8703 "The cysignals package provides mechanisms to handle interrupts (and
8704 other signals and errors) in Cython code, using two related approaches,
8705 for mixed Cython/Python code or external C libraries and pure Cython code,
8707 (license license:lgpl3+)))
8709 (define-public python2-cysignals
8710 (package-with-python2 python-cysignals))
8712 (define-public python2-shedskin
8714 (name "python2-shedskin")
8719 (uri (string-append "https://github.com/shedskin/shedskin/"
8720 "releases/download/v" version
8721 "/shedskin-" version ".tgz"))
8724 "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41"))))
8725 (build-system python-build-system)
8727 `(#:python ,python-2
8728 #:phases (modify-phases %standard-phases
8729 (add-after 'unpack 'fix-resulting-include-libs
8730 (lambda* (#:key inputs #:allow-other-keys)
8731 (let ((libgc (assoc-ref inputs "libgc"))
8732 (pcre (assoc-ref inputs "pcre")))
8733 (substitute* "shedskin/makefile.py"
8734 (("variable == 'CCFLAGS':[ ]*")
8735 (string-append "variable == 'CCFLAGS':\n"
8736 " line += ' -I " pcre "/include"
8737 " -I " libgc "/include'"))
8738 (("variable == 'LFLAGS':[ ]*")
8739 (string-append "variable == 'LFLAGS':\n"
8740 " line += ' -L" pcre "/lib"
8741 " -L " libgc "/lib'")))
8743 (inputs `(("pcre" ,pcre)
8745 (home-page "https://shedskin.github.io/")
8746 (synopsis "Experimental Python-2 to C++ Compiler")
8747 (description (string-append "This is an experimental compiler for a subset of
8748 Python. It generates C++ code and a Makefile."))
8749 (license (list license:gpl3 license:bsd-3 license:expat))))
8751 (define-public python2-rope
8753 (name "python2-rope")
8758 (uri (pypi-uri "rope" version))
8761 "1cppm0pa9aqgsbkq130lskrzmrvjs5vpiavjjbhpz2fdw52w8251"))))
8763 ;; Rope is currently python-2 only.
8764 ;; https://github.com/python-rope/rope/issues/57
8765 `(#:python ,python-2))
8766 (build-system python-build-system)
8768 `(("python2-unittest2" ,python2-unittest2)))
8769 (home-page "https://github.com/python-rope/rope")
8770 (synopsis "Refactoring library for Python")
8771 (description "Rope is a refactoring library for Python. It facilitates
8772 the renaming, moving and extracting of attributes, functions, modules, fields
8773 and parameters in Python 2 source code. These refactorings can also be applied
8774 to occurrences in strings and comments.")
8775 (license license:gpl2)))
8777 (define-public python-py3status
8779 (name "python-py3status")
8784 (uri (pypi-uri "py3status" version))
8787 "0shxcfz4wcczj0mhwp4w0dvwd2fdd9bgprq8slim1519iiqzgwhq"))))
8788 (build-system python-build-system)
8793 (modify-phases %standard-phases
8794 ;; 'file' is used for detection of configuration file encoding
8795 ;; let's make link the dependency to particular input
8796 (add-before 'build 'patch-file-path
8797 (lambda* (#:key inputs #:allow-other-keys)
8798 (let ((file-path (assoc-ref inputs "file")))
8799 (substitute* "py3status/parse_config.py"
8800 (("\\['file', '-b'")
8801 (string-append "['" file-path "/bin/file', '-b'")))
8803 #:tests? #f)) ; TODO: Requires many libraries not in Guix.
8804 (home-page "https://github.com/ultrabug/py3status")
8805 (synopsis "Extensible i3status wrapper written in Python")
8806 (description "py3status is an i3status wrapper which extends i3status
8807 functionality in a modular way, allowing you to extend your panel with your
8808 own code, responding to click events and updating clock every second.")
8809 (license license:bsd-3)))
8811 (define-public python-tblib
8813 (name "python-tblib")
8817 (uri (pypi-uri "tblib" version))
8819 "1rsg8h069kqgncyv8fgzyj6qflk6j10cb78pa5jk34ixwq044vj3"))))
8820 (build-system python-build-system)
8823 (modify-phases %standard-phases
8824 (add-before 'check 'adjust-tests
8826 (when (which "python3")
8827 ;; Adjust the example output to match that of Python 3.7:
8828 ;; <https://github.com/ionelmc/python-tblib/issues/36>.
8829 (substitute* "README.rst"
8830 (("Exception\\('fail',") "Exception('fail'"))
8834 ;; Upstream runs tests after installation and the package itself
8835 ;; resides in a subdirectory. Extend PYTHONPATH so it will be
8837 (setenv "PYTHONPATH"
8838 (string-append (getcwd) "/build/lib:"
8839 (getenv "PYTHONPATH")))
8840 (invoke "py.test" "-vv" "tests" "README.rst"))))))
8842 `(("python-pytest" ,python-pytest)
8843 ("python-six" ,python-six)))
8844 (home-page "https://github.com/ionelmc/python-tblib")
8845 (synopsis "Traceback serialization library")
8847 "Traceback serialization allows you to:
8850 @item Pickle tracebacks and raise exceptions with pickled tracebacks in
8851 different processes. This allows better error handling when running code over
8852 multiple processes (imagine multiprocessing, billiard, futures, celery etc).
8854 @item Parse traceback strings and raise with the parsed tracebacks.
8856 (license license:bsd-3)))
8858 (define-public python2-tblib
8859 (package-with-python2 python-tblib))
8861 (define-public python-greenlet
8863 (name "python-greenlet")
8867 (uri (pypi-uri "greenlet" version))
8870 "1g4g1wwc472ds89zmqlpyan3fbnzpa8qm48z3z1y6mlk44z485ll"))))
8871 (build-system python-build-system)
8872 (home-page "https://greenlet.readthedocs.io/")
8873 (synopsis "Lightweight in-process concurrent programming")
8875 "Greenlet package is a spin-off of Stackless, a version of CPython
8876 that supports micro-threads called \"tasklets\". Tasklets run
8877 pseudo-concurrently (typically in a single or a few OS-level threads) and
8878 are synchronized with data exchanges on \"channels\".")
8879 (license (list license:psfl license:expat))))
8881 (define-public python2-greenlet
8882 (package-with-python2 python-greenlet))
8884 (define-public python-objgraph
8886 (name "python-objgraph")
8891 (uri (pypi-uri "objgraph" version))
8894 "184m09am5gpbqfaiy7l0hwh476mczbrly1dffs0rw2p1d1i2q32a"))))
8895 (build-system python-build-system)
8897 `(("python-graphviz" ,python-graphviz)))
8899 `(("python-mock" ,python-mock)
8900 ("graphviz" ,graphviz)))
8901 (home-page "https://mg.pov.lt/objgraph/")
8902 (synopsis "Draw Python object reference graphs with graphviz")
8904 "This package provides tools to draw Python object reference graphs with
8906 (license license:expat)))
8908 (define-public python-gevent
8910 (name "python-gevent")
8914 (uri (pypi-uri "gevent" version))
8917 "0b0fr04qdk1p4sniv87fh8z5psac60x01pv054kpgi94520g81iz"))
8918 (modules '((guix build utils)))
8921 ;; unbunding libev and c-ares
8922 (delete-file-recursively "deps")
8924 (build-system python-build-system)
8926 `(#:modules ((ice-9 ftw)
8930 (guix build python-build-system))
8931 #:phases (modify-phases %standard-phases
8932 (add-after 'unpack 'unpack-libev
8933 (lambda* (#:key inputs #:allow-other-keys)
8934 (mkdir-p "deps/libev")
8935 ;; FIXME: gevent requires building libev, even though
8936 ;; it only links against the proper one.
8937 (invoke "tar" "-xf" (assoc-ref inputs "libev-source")
8938 "--strip-components=1" "-C" "deps/libev")))
8939 (add-before 'patch-source-shebangs 'patch-hard-coded-paths
8941 (substitute* "src/gevent/subprocess.py"
8942 (("/bin/sh") (which "sh")))
8943 (for-each (lambda (file)
8945 (("/bin/sh") (which "sh"))
8946 (("/bin/true") (which "true"))))
8947 (find-files "src/greentest" "\\.py$"))
8949 (add-before 'build 'do-not-use-bundled-sources
8950 (lambda* (#:key inputs #:allow-other-keys)
8951 (setenv "CONFIG_SHELL" (which "bash"))
8952 (setenv "LIBEV_EMBED" "false")
8953 (setenv "CARES_EMBED" "false")
8954 (setenv "EMBED" "false")
8956 (let ((greenlet (string-append
8957 (assoc-ref inputs "python-greenlet")
8959 (match (scandir greenlet
8961 (string-prefix? "python" item)))
8964 (string-append greenlet "/" python)))))
8966 (add-before 'check 'skip-timer-test
8968 ;; XXX: Skip 'TestTimerResolution', which appears to be
8970 (substitute* "src/greentest/test__core_timer.py"
8971 (("not greentest.RUNNING_ON_CI") "False"))
8975 ;; Make sure the build directory is on PYTHONPATH.
8976 (setenv "PYTHONPATH"
8978 (getenv "PYTHONPATH") ":"
8980 (car (scandir "build" (cut string-prefix? "lib." <>)))))
8981 (with-directory-excursion "src/greentest"
8982 ;; XXX: Many tests require network access. Instead we only
8983 ;; run known-good tests. Unfortunately we cannot use
8984 ;; recursion here since this directory also contains
8985 ;; Python-version-specific subfolders.
8986 (apply invoke "python" "testrunner.py" "--config"
8988 (scandir "." (cut regexp-exec
8989 (make-regexp "test_+(subprocess|core)")
8992 `(("python-greenlet" ,python-greenlet)
8993 ("python-objgraph" ,python-objgraph)))
8995 `(("libev-source" ,(package-source libev))
8996 ("python-six" ,python-six)))
8998 `(("c-ares" ,c-ares)
9000 (home-page "http://www.gevent.org/")
9001 (synopsis "Coroutine-based network library")
9003 "gevent is a coroutine-based Python networking library that uses greenlet
9004 to provide a high-level synchronous API on top of the libev event loop.")
9005 (license license:expat)
9006 (properties `((python2-variant . ,(delay python2-gevent))))))
9008 (define-public python2-gevent
9009 (let ((base (package-with-python2
9010 (strip-python2-variant python-gevent))))
9013 (native-inputs `(,@(package-native-inputs python-gevent)
9014 ("python-mock" ,python2-mock))))))
9016 (define-public python-fastimport
9018 (name "python-fastimport")
9023 (uri (pypi-uri "fastimport" version))
9025 (base32 "1aqjsin4rmqm7ln4j0p73fzxifws6c6ikgyhav7r137m2ixsxl43"))))
9026 (build-system python-build-system)
9027 (home-page "https://github.com/jelmer/python-fastimport")
9028 (synopsis "VCS fastimport parser and generator in Python")
9029 (description "This package provides a parser for and generator of the Git
9030 @url{https://www.kernel.org/pub/software/scm/git/docs/git-fast-import.html,fastimport}
9032 (license license:gpl2+)))
9034 (define-public python2-fastimport
9035 (package-with-python2 python-fastimport))
9037 (define-public python-twisted
9039 (name "python-twisted")
9043 (uri (pypi-uri "Twisted" version ".tar.bz2"))
9046 "1p245mg15hkxp7hy5cyq2fgvlgjkb4cg0gwkwd148nzy1bbi3wnv"))))
9047 (build-system python-build-system)
9049 '(#:tests? #f)) ; FIXME: Some tests are failing.
9051 ;; (modify-phases %standard-phases
9054 ;; (zero? (system* "./bin/trial" "twisted")))))
9056 `(("python-zope-interface" ,python-zope-interface)
9057 ("python-incremental" ,python-incremental)
9058 ("python-constantly" ,python-constantly)
9059 ("python-automat" ,python-automat)))
9060 (home-page "https://twistedmatrix.com/")
9061 (synopsis "Asynchronous networking framework written in Python")
9063 "Twisted is an extensible framework for Python programming, with special
9064 focus on event-based network programming and multiprotocol integration.")
9065 (license license:expat)))
9067 (define-public python2-twisted
9068 (package-with-python2 python-twisted))
9070 (define-public python-pika
9072 (name "python-pika")
9077 (uri (pypi-uri "pika" version))
9080 "0ld7akgm93s8pfa4dsx9qlzlhj76zspbr5m9ms0ns09yd2w4aq9h"))))
9081 (build-system python-build-system)
9083 `(("python-pyev" ,python-pyev)
9084 ("python-tornado" ,python-tornado)
9085 ("python-twisted" ,python-twisted)))
9086 (home-page "https://pika.readthedocs.org")
9087 (synopsis "Pure Python AMQP Client Library")
9089 "Pika is a pure-Python implementation of the AMQP (Advanced Message Queuing
9090 Protocol) 0-9-1 protocol that tries to stay fairly independent of the underlying
9091 network support library.")
9092 (license license:bsd-3)))
9094 (define-public python2-pika
9095 (package-with-python2 python-pika))
9097 (define-public python-ply
9104 (uri (pypi-uri "ply" version))
9107 "1jxsr1d2f732r6ljhvm827113dckwl6qwakfvpbdhcbhvpvlmscn"))))
9108 (build-system python-build-system)
9109 (home-page "http://www.dabeaz.com/ply/")
9110 (synopsis "Python Lex & Yacc")
9111 (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python.
9112 It uses LR parsing and does extensive error checking.")
9113 (license license:bsd-3)))
9115 (define-public python2-ply
9116 (package-with-python2 python-ply))
9118 (define-public python-tabulate
9120 (name "python-tabulate")
9124 (uri (pypi-uri "tabulate" version))
9127 "1inqhspd4frxnp08c32yndr0lc4px1xfkqah184i5w09gkhvi843"))))
9128 (build-system python-build-system)
9130 ;; FIXME: The pypi release tarball is missing a 'test/common.py'
9131 ;; and the latest release is not tagged in the upstream repository.
9133 (home-page "https://bitbucket.org/astanin/python-tabulate")
9134 (synopsis "Pretty-print tabular data")
9136 "Tabulate is a library and command-line utility to pretty-print tabular
9138 (license license:expat)))
9140 (define-public python2-tabulate
9141 (package-with-python2 python-tabulate))
9143 (define-public python-kazoo
9145 (name "python-kazoo")
9150 (uri (pypi-uri "kazoo" version))
9153 "16y213k7r8shyn2zw1k6lkzjgcrvm441pqv8scvcjixhvpbx3hm7"))))
9154 (build-system python-build-system)
9155 (arguments '(#:tests? #f)) ; XXX: needs zookeeper
9157 `(("python-six" ,python-six)))
9158 (home-page "https://kazoo.readthedocs.org")
9159 (synopsis "High-level Zookeeper client library")
9161 "Kazoo is a Python client library for the Apache Zookeeper distributed
9162 application service. It is designed to be easy to use and to avoid common
9163 programming errors.")
9164 (license license:asl2.0)))
9166 (define-public python2-kazoo
9167 (package-with-python2 python-kazoo))
9169 (define-public python-pykafka
9171 (name "python-pykafka")
9175 (uri (pypi-uri "pykafka" version))
9178 "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv"))))
9179 (build-system python-build-system)
9180 (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc.
9182 `(("python-gevent" ,python-gevent)
9183 ("python-kazoo" ,python-kazoo)
9184 ("python-tabulate" ,python-tabulate)))
9186 `(("librdkafka" ,librdkafka)))
9187 (home-page "https://pykafka.readthedocs.io/")
9188 (synopsis "Apache Kafka client for Python")
9190 "PyKafka is a client for the Apache Kafka distributed messaging system.
9191 It includes Python implementations of Kafka producers and consumers, which
9192 are optionally backed by a C extension built on librdkafka.")
9193 (license license:asl2.0)))
9195 (define-public python2-pykafka
9196 (package-with-python2 python-pykafka))
9198 (define-public python-wcwidth
9200 (name "python-wcwidth")
9205 (uri (pypi-uri "wcwidth" version))
9208 "0pn6dflzm609m4r3i8ik5ni9ijjbb5fa3vg1n7hn6vkd49r77wrx"))))
9209 (build-system python-build-system)
9210 (home-page "https://github.com/jquast/wcwidth")
9211 (synopsis "Measure number of terminal column cells of wide-character codes")
9212 (description "Wcwidth measures the number of terminal column cells of
9213 wide-character codes. It is useful for those implementing a terminal emulator,
9214 or programs that carefully produce output to be interpreted by one. It is a
9215 Python implementation of the @code{wcwidth} and @code{wcswidth} C functions
9216 specified in POSIX.1-2001 and POSIX.1-2008.")
9217 (license license:expat)))
9219 (define-public python2-wcwidth
9220 (package-with-python2 python-wcwidth))
9222 (define-public python2-jsonrpclib
9224 (name "python2-jsonrpclib")
9228 (uri (pypi-uri "jsonrpclib" version))
9231 "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z"))))
9232 (build-system python-build-system)
9235 #:python ,python-2))
9236 (home-page "https://github.com/joshmarshall/jsonrpclib/")
9237 (synopsis "Implementation of JSON-RPC specification for Python")
9239 "This library is an implementation of the JSON-RPC specification.
9240 It supports both the original 1.0 specification, as well as the
9241 new (proposed) 2.0 spec, which includes batch submission, keyword arguments,
9243 (license license:asl2.0)))
9245 (define-public python-chai
9247 (name "python-chai")
9251 (uri (pypi-uri "chai" version))
9254 "1k6n6zbgrrs83crp6mr3yqj9zlv40b8rpisyrliwsq7naml2p3gz"))))
9255 (build-system python-build-system)
9256 (home-page "https://github.com/agoragames/chai")
9257 (synopsis "Mocking framework for Python")
9259 "Chai provides an api for mocking, stubbing and spying your python
9260 objects, patterned after the Mocha library for Ruby.")
9261 (license license:bsd-3)))
9263 (define-public python2-chai
9264 (package-with-python2 python-chai))
9266 (define-public python-inflection
9268 (name "python-inflection")
9271 (origin (method url-fetch)
9272 (uri (pypi-uri "inflection" version))
9275 "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq"))))
9276 (build-system python-build-system)
9278 `(("python-pytest" ,python-pytest)))
9279 (home-page "https://github.com/jpvanhal/inflection")
9280 (synopsis "Python string transformation library")
9282 "Inflection is a string transformation library. It singularizes
9283 and pluralizes English words, and transforms strings from CamelCase to
9284 underscored string.")
9285 (license license:expat)))
9287 (define-public python2-inflection
9288 (package-with-python2 python-inflection))
9290 (define-public python-pylev
9292 (name "python-pylev")
9296 (uri (pypi-uri "pylev" version))
9299 "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86"))))
9300 (build-system python-build-system)
9301 (home-page "https://github.com/toastdriven/pylev")
9302 (synopsis "Levenshtein distance implementation in Python")
9303 (description "Pure Python Levenshtein implementation, based off the
9304 Wikipedia code samples at
9305 @url{http://en.wikipedia.org/wiki/Levenshtein_distance}.")
9306 (license license:bsd-3)))
9308 (define-public python2-pylev
9309 (package-with-python2 python-pylev))
9311 (define-public python-cleo
9313 (name "python-cleo")
9317 (uri (pypi-uri "cleo" version))
9320 "0q1cf0szr0d54am4pypzwdnm74zpladdsinad94c2fz5i06fdpf7"))))
9321 (build-system python-build-system)
9324 ("python-mock" ,python-mock)
9325 ("python-pytest-mock" ,python-pytest-mock)
9326 ("python-pytest" ,python-pytest)))
9328 `(("python-backpack" ,python-backpack)
9329 ("python-pastel" ,python-pastel)
9330 ("python-pylev" ,python-pylev)))
9331 (home-page "https://github.com/sdispater/cleo")
9332 (synopsis "Command-line arguments library for Python")
9334 "Cleo allows you to create command-line commands with signature in
9335 docstring and colored output.")
9336 (license license:expat)))
9338 (define-public python2-cleo
9339 (package-with-python2 python-cleo))
9341 (define-public python-lazy-object-proxy
9343 (name "python-lazy-object-proxy")
9347 (uri (pypi-uri "lazy-object-proxy" version))
9350 "0yha7q9bhw857fwaby785d63mffhngl9npwzlk9i0pwlkwvbx4gb"))))
9351 (build-system python-build-system)
9352 (home-page "https://github.com/ionelmc/python-lazy-object-proxy")
9353 (synopsis "Lazy object proxy for python")
9355 "Lazy object proxy is an object that wraps a callable but defers the call
9356 until the object is actually required, and caches the result of said call.")
9357 (license license:bsd-2)))
9359 (define-public python2-lazy-object-proxy
9360 (package-with-python2 python-lazy-object-proxy))
9362 (define-public python-dnspython
9364 (name "python-dnspython")
9368 (uri (string-append "http://www.dnspython.org/kits/"
9369 version "/dnspython-" version ".tar.gz"))
9372 "0jr4v2pd90i6l1xxbss2m05psbjaxvyvvvpq44wycijpfgjqln8i"))))
9373 (build-system python-build-system)
9374 (arguments '(#:tests? #f)) ; XXX: requires internet access
9375 (home-page "http://www.dnspython.org")
9376 (synopsis "DNS toolkit for Python")
9378 "dnspython is a DNS toolkit for Python. It supports almost all record
9379 types. It can be used for queries, zone transfers, and dynamic updates.
9380 It supports TSIG authenticated messages and EDNS0.")
9381 (license license:expat)))
9383 (define-public python2-dnspython
9384 (package-with-python2 python-dnspython))
9386 (define-public python-email-validator
9388 (name "python-email-validator")
9391 (origin (method url-fetch)
9392 (uri (pypi-uri "email_validator" version))
9395 "1ja9149l9ck5n45a72h3is7v476hjny5ybxbcamx1nw6iplsm7k6"))))
9396 (build-system python-build-system)
9399 (modify-phases %standard-phases
9400 (add-before 'build 'use-dnspython
9402 (substitute* "setup.py"
9403 (("dnspython3") "dnspython"))
9406 `(("python-dnspython" ,python-dnspython)
9407 ("python-idna" ,python-idna)))
9408 (home-page "https://github.com/JoshData/python-email-validator")
9409 (synopsis "Email address validation library for Python")
9411 "This library validates email address syntax and deliverability.")
9412 (license license:cc0)))
9414 (define-public python2-email-validator
9415 (package-with-python2 python-email-validator))
9417 (define-public python-ukpostcodeparser
9419 (name "python-ukpostcodeparser")
9423 (uri (pypi-uri "UkPostcodeParser" version))
9426 "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd"))))
9427 (build-system python-build-system)
9428 (home-page "https://github.com/hamstah/ukpostcodeparser")
9429 (synopsis "UK Postcode parser for Python")
9431 "This library provides the @code{parse_uk_postcode} function for
9432 parsing UK postcodes.")
9433 (license license:expat)))
9435 (define-public python2-ukpostcodeparser
9436 (package-with-python2 python-ukpostcodeparser))
9438 (define-public python-faker
9440 (name "python-faker")
9444 (uri (pypi-uri "Faker" version))
9447 "1fh2p2yz0fsdr4fqwxgddwbvfb6qn6vp8yx0qwqzra27yq5d1wsm"))
9449 (search-patches "python-faker-fix-build-32bit.patch"))
9450 (modules '((guix build utils)))
9453 (for-each delete-file (find-files "." "\\.pyc$"))
9455 (build-system python-build-system)
9458 (modify-phases %standard-phases
9460 (lambda _ (invoke "python" "-m" "unittest" "-v" "tests"))))))
9463 ("python-email-validator" ,python-email-validator)
9464 ("python-mock" ,python-mock)
9465 ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
9467 `(("python-dateutil" ,python-dateutil)
9468 ("python-six" ,python-six)))
9469 (home-page "https://github.com/joke2k/faker")
9470 (synopsis "Python package that generates fake data")
9472 "Faker is a Python package that generates fake data such as names,
9473 addresses, and phone numbers.")
9474 (license license:expat)
9475 (properties `((python2-variant . ,(delay python2-faker))))))
9477 (define-public python2-faker
9478 (let ((base (package-with-python2 (strip-python2-variant
9483 `(("python2-ipaddress" ,python2-ipaddress)
9484 ,@(package-propagated-inputs base))))))
9486 (define-public python-pyaml
9488 (name "python-pyaml")
9492 (uri (pypi-uri "pyaml" version))
9495 "0fi604ix8lbpj1266q7js6szm771saprdzzcdwmj43wy83694qmr"))))
9496 (build-system python-build-system)
9498 `(("python-unidecode" ,python-unidecode)))
9500 `(("python-pyyaml" ,python-pyyaml)))
9501 (home-page "https://github.com/mk-fg/pretty-yaml")
9502 (synopsis "YAML pretty-print library for Python")
9504 "pyaml is a PyYAML based python module to produce pretty and readable
9505 YAML-serialized data.")
9506 (license (license:non-copyleft "http://www.wtfpl.net/txt/copying/"))))
9508 (define-public python2-pyaml
9509 (package-with-python2 python-pyaml))
9511 (define-public python-backpack
9513 (name "python-backpack")
9518 (uri (pypi-uri "backpack" version))
9521 "14rq1mvm0jda90lcx9gyyby9dvq4x3js2cmxvd6vl4686ixwyqh1"))))
9522 (build-system python-build-system)
9524 `(("python-pytest" ,python-pytest)
9525 ("python-nose" ,python-nose)))
9527 `(("python-simplejson" ,python-simplejson)))
9528 (home-page "https://github.com/sdispater/backpack")
9529 (synopsis "Utilities for working with Python collections")
9530 (description "Backpack provides some useful utilities for working with
9531 collections of data.")
9532 (license license:expat)))
9534 (define-public python2-backpack
9535 (package-with-python2 python-backpack))
9537 (define-public python-prompt-toolkit
9539 (name "python-prompt-toolkit")
9544 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
9547 "0fgacqk73w7s932vy46pan2yp8rvjmlkag20xvaydh9mhf6h85zx"))))
9548 (build-system python-build-system)
9551 (modify-phases %standard-phases
9553 (add-after 'install 'post-install-check
9554 (lambda* (#:key inputs outputs #:allow-other-keys)
9555 ;; HOME is needed for the test
9556 ;; "test_pathcompleter_can_expanduser".
9557 (setenv "HOME" "/tmp")
9558 (add-installed-pythonpath inputs outputs)
9559 (invoke "py.test"))))))
9561 `(("python-wcwidth" ,python-wcwidth)
9562 ("python-six" ,python-six)
9563 ("python-pygments" ,python-pygments)))
9565 `(("python-pytest" ,python-pytest)))
9566 (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
9567 (synopsis "Library for building command line interfaces in Python")
9569 "Prompt-Toolkit is a library for building interactive command line
9570 interfaces in Python. It's like GNU Readline but it also features syntax
9571 highlighting while typing, out-of-the-box multi-line input editing, advanced
9572 code completion, incremental search, support for Chinese double-width
9573 characters, mouse support, and auto suggestions.")
9574 (license license:bsd-3)))
9576 (define-public python2-prompt-toolkit
9577 (package-with-python2 python-prompt-toolkit))
9579 (define-public python-prompt-toolkit-1
9580 (package (inherit python-prompt-toolkit)
9585 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
9588 "05v9h5nydljwpj5nm8n804ms0glajwfy1zagrzqrg91wk3qqi1c5"))))))
9590 (define-public python2-prompt-toolkit-1
9591 (package-with-python2 python-prompt-toolkit-1))
9593 (define-public python-jedi
9595 (name "python-jedi")
9600 (uri (pypi-uri "jedi" version))
9603 "1za944msp0f8x36qa8l309jhv0kzlsdh7r9nj3z12y8npnsh45sp"))))
9604 (build-system python-build-system)
9606 `( ;; Many tests are failing with Python 3.7.x as of version 0.13.2 (see:
9607 ;; https://github.com/davidhalter/jedi/issues/1263)
9610 (modify-phases %standard-phases
9612 (lambda* (#:key tests? #:allow-other-keys)
9614 (invoke "py.test" "-vv")))))))
9616 `(("python-pytest" ,python-pytest)
9617 ("python-docopt" ,python-docopt)))
9619 `(("python-parso" ,python-parso)))
9620 (home-page "https://github.com/davidhalter/jedi")
9621 (synopsis "Autocompletion and static analysis library for Python")
9623 "Jedi is a static analysis tool for Python that can be used in Integrated
9624 Development Environments (@dfn{IDE}s) and text editors. It understands Python
9625 on a deeper level than many other static analysis frameworks for Python.
9627 Jedi understands docstrings and you can use Jedi autocompletion in your REPL as
9629 (license license:expat)))
9631 (define-public python2-jedi
9632 (package-with-python2 python-jedi))
9634 (define-public ptpython
9640 (uri (pypi-uri "ptpython" version))
9643 "1mmbiyzf0n8hm7z2a562x7w5cbl6jc0zsk6vp40q1z4cyblv1k13"))))
9644 (build-system python-build-system)
9646 '(#:tests? #f)) ; FIXME: No tests in pypi tarball.
9648 `(("python-docopt" ,python-docopt)
9649 ("python-jedi" ,python-jedi)
9650 ("python-prompt-toolkit" ,python-prompt-toolkit)
9651 ("python-pygments" ,python-pygments)))
9652 (home-page "https://github.com/jonathanslenders/ptpython")
9653 (synopsis "Python Read-Eval-Print-Loop with nice IDE-like features")
9655 "ptpython is a Python read-eval-print loop with IDE-like features.
9656 It supports syntax highlighting, multiline editing, autocompletion, mouse,
9657 color schemes, bracketed paste, Vi and Emacs keybindings, Chinese characters
9659 (license license:bsd-3)
9660 (properties `((python2-variant . ,(delay ptpython-2))))))
9662 (define-public ptpython-2
9663 (let ((base (package-with-python2 (strip-python2-variant ptpython))))
9666 (name "ptpython2"))))
9668 (define-public python-stem
9670 (name "python-stem")
9675 (uri (pypi-uri "stem" version))
9678 "1awiglfiajnx2hva9aqpj3fmdvdb4qg7cwnlfyih827m68y3cq8v"))))
9679 (build-system python-build-system)
9682 (modify-phases %standard-phases
9685 (invoke "./run_tests.py" "--unit")
9688 `(("python-mock" ,python-mock)
9689 ("python-pycodestyle" ,python-pycodestyle)
9690 ("python-pyflakes" ,python-pyflakes)))
9691 (home-page "https://stem.torproject.org/")
9693 "Python controller library that allows applications to interact with Tor")
9695 "Stem is a Python controller library for Tor. With it you can use Tor's
9696 control protocol to script against the Tor process and read descriptor data
9697 relays publish about themselves.")
9698 (license license:lgpl3)))
9700 (define-public python2-stem
9701 (package-with-python2 python-stem))
9703 (define-public python-pyserial
9705 (name "python-pyserial")
9710 (uri (pypi-uri "pyserial" version))
9713 "0k1nfdrxxkdlv4zgaqsdv8li0pj3gbh2pyxw8q2bsg6f9490amyn"))))
9714 (build-system python-build-system)
9716 '(#:tests? #f)) ; FIXME: 3/49 tests are failing.
9718 ;; (modify-phases %standard-phases
9721 ;; (zero? (system* "python" "test/run_all_tests.py" "loop://")))))))
9723 "https://github.com/pyserial/pyserial")
9724 (synopsis "Python Serial Port Bindings")
9725 (description "@code{pyserial} provide serial port bindings for Python. It
9726 supports different byte sizes, stop bits, parity and flow control with RTS/CTS
9727 and/or Xon/Xoff. The port is accessed in RAW mode.")
9728 (license license:bsd-3)))
9730 (define-public python2-pyserial
9731 (package-with-python2 python-pyserial))
9733 (define-public python-kivy
9735 (name "python-kivy")
9740 (uri (pypi-uri "Kivy" version))
9741 (file-name (string-append name "-" version ".tar.gz"))
9744 "1zzxjdp78hfjjiklzr82l4zwibwcq4j6kgicspqs6iyyfn5yisbw"))))
9745 (build-system python-build-system)
9747 `(#:tests? #f ; Tests require many optional packages
9749 (modify-phases %standard-phases
9750 (add-after 'patch-generated-file-shebangs 'set-sdl-paths
9751 (lambda* (#:key inputs #:allow-other-keys)
9752 (setenv "KIVY_SDL2_PATH"
9753 (string-append (assoc-ref inputs "sdl-union")
9758 ("pkg-config" ,pkg-config)
9759 ("python-cython" ,python-cython)))
9761 `(("gstreamer" ,gstreamer)
9764 ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))))
9765 (home-page "http://kivy.org")
9767 "Multitouch application framework")
9769 "A software library for rapid development of
9770 hardware-accelerated multitouch applications.")
9771 (license license:expat)))
9773 (define-public python2-kivy
9774 (package-with-python2 python-kivy))
9776 (define-public python-kivy-next
9777 (deprecated-package "python-kivy-next" python-kivy))
9779 (define-public python2-kivy-next
9780 (deprecated-package "python2-kivy-next" python2-kivy))
9782 (define-public python-binaryornot
9784 (name "python-binaryornot")
9788 (uri (pypi-uri "binaryornot" version))
9791 "0qc006986rb6bcbmiymwgcl1mns2jphr1j7sr7nk41nlr7gh359m"))))
9792 (build-system python-build-system)
9794 `(("python-chardet" ,python-chardet)
9795 ("python-hypothesis" ,python-hypothesis)))
9796 (home-page "https://github.com/audreyr/binaryornot")
9797 (synopsis "Package to check if a file is binary or text")
9798 (description "Ultra-lightweight pure Python package to check if a file is
9800 (license license:bsd-3)
9801 (properties `((python2-variant . ,(delay python2-binaryornot))))))
9803 (define-public python2-binaryornot
9804 (let ((base (package-with-python2 (strip-python2-variant python-binaryornot))))
9805 (package (inherit base)
9807 `(("python2-enum34" ,python2-enum34)
9808 ,@(package-propagated-inputs base))))))
9810 (define-public python-nltk
9812 (name "python-nltk")
9816 (uri (pypi-uri "nltk" version))
9819 "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"))))
9820 (build-system python-build-system)
9822 '(;; The tests require some extra resources to be downloaded.
9823 ;; TODO Try packaging these resources.
9825 (home-page "http://nltk.org/")
9826 (synopsis "Natural Language Toolkit")
9827 (description "It provides interfaces to over 50 corpora and lexical
9828 resources such as WordNet, along with a suite of text processing libraries
9829 for classification, tokenization, stemming, tagging, parsing, and semantic
9830 reasoning, wrappers for natural language processing libraries.")
9831 (license license:asl2.0)))
9833 (define-public python2-nltk
9834 (package-with-python2 python-nltk))
9836 (define-public python-pymongo
9838 (name "python-pymongo")
9842 (uri (pypi-uri "pymongo" version))
9845 "0zis4707r9hdg5qgkhp3wss9camr9h56ixyfc8n9dxwlnnly4x4c"))))
9846 (build-system python-build-system)
9848 `(("python-certifi" ,python-certifi)))
9849 (home-page "https://github.com/mongodb/mongo-python-driver")
9850 (synopsis "Python driver for MongoDB")
9851 (description "Python driver for MongoDB.")
9852 (license license:asl2.0)))
9854 (define-public python2-pymongo
9855 (package-with-python2 python-pymongo))
9857 (define-public python-consul
9859 (name "python-consul")
9864 (uri (pypi-uri "python-consul" version))
9867 "0rfyxcy4cr3x848vhx876ifalxd5ghq6l5x813m49h4vq2d4jiq8"))))
9868 (build-system python-build-system)
9870 '(#:tests? #f)) ; The tests are not distributed
9872 `(("python-requests" ,python-requests)
9873 ("python-six" ,python-six)))
9874 (home-page "https://github.com/cablehead/python-consul")
9875 (synopsis "Python client for Consul")
9877 "Python client for @url{http://www.consul.io/,Consul}, a tool for service
9878 discovery, monitoring and configuration.")
9879 (license license:expat)))
9881 (define-public python2-consul
9882 (package-with-python2 python-consul))
9884 (define-public python-schematics
9886 (name "python-schematics")
9892 "https://github.com/schematics/schematics/archive/v" version ".tar.gz"))
9893 (file-name (string-append name "-" version ".tar.gz"))
9896 "19v1i69bf3bzarfxmbv0v6ivpcn758x3shvbiy9l2hy0lvqwnp6l"))))
9897 (build-system python-build-system)
9899 `(("python-six" ,python-six)))
9901 `(#:tests? #f)) ; requires a bunch of not very nice packages with fixed
9902 ; version requirements (eg python-coveralls)
9903 (home-page "https://github.com/schematics/schematics")
9904 (synopsis "Python Data Structures for Humans")
9905 (description "Python Data Structures for Humans.")
9906 (license license:bsd-3)))
9908 (define-public python2-schematics
9909 (package-with-python2 python-schematics))
9911 (define-public python-odfpy
9913 (name "python-odfpy")
9917 (uri (pypi-uri "odfpy" version))
9920 "1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"))))
9922 `(#:modules ((srfi srfi-1)
9923 (guix build python-build-system)
9926 (modify-phases %standard-phases
9928 ;; The test runner invokes python2 and python3 for test*.py.
9929 ;; To avoid having both in inputs, we replicate it here.
9931 (for-each (lambda (test-file) (invoke "python" test-file))
9932 (find-files "tests" "^test.*\\.py$"))
9934 (build-system python-build-system)
9935 (home-page "https://github.com/eea/odfpy")
9936 (synopsis "Python API and tools to manipulate OpenDocument files")
9937 (description "Collection of libraries and utility programs written in
9938 Python to manipulate OpenDocument 1.2 files.")
9940 ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
9941 ;; number of files with other licenses.
9942 (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0))))
9944 (define-public python2-odfpy
9945 (package-with-python2 python-odfpy))
9947 (define-public python-natsort
9949 (name "python-natsort")
9953 (uri (pypi-uri "natsort" version))
9956 "0i732amg6yzkx4g4c9j09jmqq39q377x9cl2nbkm5hax2c2v0wxf"))))
9957 (build-system python-build-system)
9959 `(#:modules ((guix build utils)
9960 (guix build python-build-system)
9965 (modify-phases %standard-phases
9966 (add-before 'check 'set-cachedir
9967 ;; Tests require write access to $HOME by default
9968 (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t))
9971 (let ((cwd (getcwd)))
9972 (setenv "PYTHONPATH"
9975 (find (cut string-prefix? "lib" <>)
9976 (scandir (string-append cwd "/build")))
9978 (getenv "PYTHONPATH")))
9979 (invoke "pytest" "-v")))))))
9981 `(("python-hypothesis" ,python-hypothesis)
9982 ("python-pytest-cov" ,python-pytest-cov)
9983 ("python-pytest-mock" ,python-pytest-mock)
9984 ("python-pytest" ,python-pytest)))
9985 (propagated-inputs ; TODO: Add python-fastnumbers.
9986 `(("python-pyicu" ,python-pyicu)))
9987 (home-page "https://github.com/SethMMorton/natsort")
9988 (synopsis "Natural sorting for python and shell")
9990 "Natsort lets you apply natural sorting on lists instead of
9991 lexicographical. If you use the built-in @code{sorted} method in python
9992 on a list such as @code{['a20', 'a9', 'a1', 'a4', 'a10']}, it would be
9993 returned as @code{['a1', 'a10', 'a20', 'a4', 'a9']}. Natsort provides a
9994 function @code{natsorted} that identifies numbers and sorts them separately
9995 from strings. It can also sort version numbers, real numbers, mixed types
9996 and more, and comes with a shell command @command{natsort} that exposes this
9997 functionality in the command line.")
9998 (license license:expat)
9999 (properties `((python2-variant . ,(delay python2-natsort))))))
10001 (define-public python2-natsort
10002 (let ((base (package-with-python2 (strip-python2-variant python-natsort))))
10003 (package (inherit base)
10005 `(("python2-pathlib" ,python2-pathlib)
10006 ,@(package-native-inputs base))))))
10008 (define-public python-glances
10010 (name "python-glances")
10015 (uri (pypi-uri "Glances" version))
10018 "09fxysfp1n16csqvzvawy74qm6a94nvwjf3vcf5gkqp4i6k4vjjy"))))
10019 (build-system python-build-system)
10021 `(("python-psutil" ,python-psutil)))
10023 "https://github.com/nicolargo/glances")
10025 "A cross-platform curses-based monitoring tool")
10027 "Glances is a curses-based monitoring tool for a wide variety of platforms.
10028 Glances uses the PsUtil library to get information from your system. It monitors
10029 CPU, load, memory, network bandwidth, disk I/O, disk use, and more.")
10030 (license license:lgpl3+)))
10032 (define-public python2-glances
10033 (package-with-python2 python-glances))
10035 (define-public python-graphql-core
10037 (name "python-graphql-core")
10042 (uri (pypi-uri "graphql-core" version))
10045 "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0"))))
10046 (build-system python-build-system)
10048 `(#:tests? #f ; Tests require the unpackaged pytest-benchmark.
10050 (modify-phases %standard-phases
10051 (add-after 'unpack 'patch-hardcoded-version
10052 (lambda _ (substitute*
10054 (("'gevent==1.1rc1'") "'gevent'"))
10057 `(("python-gevent" ,python-gevent)
10058 ("python-mock" ,python-mock)
10059 ("python-pytest-mock" ,python-pytest-mock)))
10061 `(("python-promise" ,python-promise)
10062 ("python-six" ,python-six)))
10063 (home-page "https://github.com/graphql-python/graphql-core")
10064 (synopsis "GraphQL implementation for Python")
10066 "GraphQL implementation for Python. GraphQL is a data query language and
10067 runtime designed and used to request and deliver data to mobile and web apps.
10068 This library is a port of @url{https://github.com/graphql/graphql-js,graphql-js}
10070 (license license:expat)))
10072 (define-public python2-graphql-core
10073 (package-with-python2 python-graphql-core))
10075 (define-public python-graphql-relay
10077 (name "python-graphql-relay")
10082 (uri (pypi-uri "graphql-relay" version))
10085 "1nv5dxcj59zv31qvl8bd142njmxcmymny2dz3br1l2cpbljbf5i7"))))
10086 (build-system python-build-system)
10088 '(#:tests? #f)) ; The tests are not distributed
10090 `(("python-graphql-core" ,python-graphql-core)
10091 ("python-promise" ,python-promise)
10092 ("python-six" ,python-six)))
10093 (home-page "https://github.com/graphql-python/graphql-relay-py")
10094 (synopsis "Relay implementation for Python")
10096 "This is a library to allow the easy creation of Relay-compliant servers
10097 using the GraphQL Python reference implementation of a GraphQL server. It
10098 should be noted that the code is a exact port of the original
10099 @url{https://github.com/graphql/graphql-relay-js,graphql-relay js implementation}
10101 (license license:expat)))
10103 (define-public python2-graphql-relay
10104 (package-with-python2 python-graphql-relay))
10106 (define-public python-graphene
10108 (name "python-graphene")
10113 (uri (pypi-uri "graphene" version))
10116 "09zhac7igh9ixdz0ay6csy35b40l1jwbf2wrbxmgxwfhy51iy06q"))))
10117 (build-system python-build-system)
10119 `(("python-graphql-core" ,python-graphql-core)
10120 ("python-graphql-relay" ,python-graphql-relay)
10121 ("python-iso8601" ,python-iso8601)
10122 ("python-promise" ,python-promise)
10123 ("python-six" ,python-six)))
10125 `(#:tests? #f)) ; no tests/ in the PyPI tarball
10126 (home-page "http://graphene-python.org/")
10127 (synopsis "GraphQL Framework for Python")
10129 "Graphene is a Python library for building GraphQL schemas/types.
10130 A GraphQL schema describes your data model, and provides a GraphQL server
10131 with an associated set of resolve methods that know how to fetch data.")
10132 (properties `((python2-variant . ,(delay python2-graphene))))
10133 (license license:expat)))
10135 (define-public python2-graphene
10136 (let ((base (package-with-python2
10137 (strip-python2-variant python-graphene))))
10138 (package (inherit base)
10140 `(("python2-sqlalchemy" ,python2-sqlalchemy)
10141 ,@(package-native-inputs base))))))
10143 (define-public python-nautilus
10145 (name "python-nautilus")
10150 (uri (pypi-uri "nautilus" version))
10153 "01hwzjc1zshk4vvxrcghm398fpy4jls66dyz06g07mrwqif8878p"))))
10154 (build-system python-build-system)
10155 (arguments `(#:tests? #f)) ; fails to import test modules
10157 `(("python-bcrypt" ,python-bcrypt)
10158 ("python-click" ,python-click)
10159 ("python-consul" ,python-consul)
10160 ("python-graphene" ,python-graphene)
10161 ("python-jinja2" ,python-jinja2)
10162 ("python-peewee" ,python-peewee)
10163 ("python-pika" ,python-pika)
10164 ("python-tornado" ,python-tornado)
10165 ("python-wtforms" ,python-wtforms)))
10167 `(("python-nose2" ,python-nose2)))
10168 (home-page "https://github.com/AlecAivazis/nautilus")
10169 (synopsis "Library for creating microservice applications")
10171 "Nautilus is a framework for flux based microservices that looks to
10172 provide extendible implementations of common aspects of a cloud so that you can
10173 focus on building massively scalable web applications.")
10174 (license license:expat)))
10176 (define-public python-snowballstemmer
10178 (name "python-snowballstemmer")
10182 (uri (pypi-uri "snowballstemmer" version))
10185 "0a0idq4y5frv7qsg2x62jd7rd272749xk4x99misf5rcifk2d7wi"))))
10186 (build-system python-build-system)
10188 `(;; No tests exist
10190 (home-page "https://github.com/shibukawa/snowball_py")
10191 (synopsis "Snowball stemming library collection for Python")
10192 (description "This package provides 16 word stemmer algorithms generated
10193 from Snowball algorithms. It includes the 15 original ones plus the Poerter
10195 (license license:bsd-3)))
10197 (define-public python2-snowballstemmer
10198 (package-with-python2 python-snowballstemmer))
10200 (define-public python-sphinx-cloud-sptheme
10202 (name "python-sphinx-cloud-sptheme")
10206 (uri (pypi-uri "cloud_sptheme" version))
10209 "1dniqb6a39yh786f86c4jn666rwnyi1jvzn4616zhcchb7sfdshd"))))
10210 (build-system python-build-system)
10211 ;; FIXME: The 'pypi' release archive does not contain tests.
10212 (arguments '(#:tests? #f))
10214 `(("python-sphinx" ,python-sphinx)))
10215 (home-page "https://bitbucket.org/ecollins/cloud_sptheme")
10216 (synopsis "'Cloud' theme for Sphinx documenter")
10217 (description "This package contains the \"Cloud\" theme for Sphinx and some
10218 related extensions.")
10219 (license license:bsd-3)))
10221 (define-public python2-sphinx-cloud-sptheme
10222 (package-with-python2 python-sphinx-cloud-sptheme))
10224 (define-public python-sphinx-alabaster-theme
10226 (name "python-sphinx-alabaster-theme")
10230 (uri (pypi-uri "alabaster" version))
10233 "00nwwjj2d2ym4s2kk217x7jkx1hnczc3fvm8yxbqmsp6b0nxfqd6"))))
10234 (build-system python-build-system)
10236 `(("python-pygments" ,python-pygments)))
10237 (home-page "https://alabaster.readthedocs.io/")
10238 (synopsis "Configurable sidebar-enabled Sphinx theme")
10239 (description "Alabaster is a visually (c)lean, responsive, configurable
10240 theme for the Sphinx documentation system. It's the default theme of Sphinx.")
10241 (license license:bsd-3)))
10243 (define-public python2-sphinx-alabaster-theme
10244 (package-with-python2 python-sphinx-alabaster-theme))
10246 (define-public python-setproctitle
10248 (name "python-setproctitle")
10253 (uri (pypi-uri "setproctitle" version))
10256 "163kplw9dcrw0lffq1bvli5yws3rngpnvrxrzdw89pbphjjvg0v2"))))
10257 (build-system python-build-system)
10260 (modify-phases %standard-phases
10261 (add-before 'check 'patch-Makefile
10262 ;; Stricly this is only required for the python2 variant.
10263 ;; But adding a phase in an inherited package seems to be
10264 ;; cumbersum. So we patch even for python3.
10266 (let ((nose (assoc-ref %build-inputs "python2-nose")))
10268 (substitute* "Makefile"
10269 (("\\$\\(PYTHON\\) [^ ]which nosetests[^ ] ")
10270 (string-append nose "/bin/nosetests "))))
10274 (setenv "PYTHON" (or (which "python3") (which "python")))
10275 (setenv "PYCONFIG" (or (which "python3-config")
10276 (which "python-config")))
10277 (setenv "CC" "gcc")
10278 ;; No need to extend PYTHONPATH to find the built package, since
10279 ;; the Makefile will build anyway
10280 (invoke "make" "check"))))))
10282 `(("procps" ,procps))) ; required for tests
10284 "https://github.com/dvarrazzo/py-setproctitle")
10286 "Setproctitle implementation for Python to customize the process title")
10287 (description "The library allows a process to change its title (as displayed
10288 by system tools such as ps and top).
10290 Changing the title is mostly useful in multi-process systems, for
10291 example when a master process is forked: changing the children's title
10292 allows to identify the task each process is busy with. The technique
10293 is used by PostgreSQL and the OpenSSH Server for example.")
10294 (license license:bsd-3)
10295 (properties `((python2-variant . ,(delay python2-setproctitle))))))
10297 (define-public python2-setproctitle
10298 (let ((base (package-with-python2
10299 (strip-python2-variant python-setproctitle))))
10302 (native-inputs `(("python2-nose" ,python2-nose)
10303 ,@(package-native-inputs base))))))
10305 (define-public python-validictory
10307 (name "python-validictory")
10312 (uri (pypi-uri "validictory" version))
10315 "1zf1g9sw47xzp5f80bd94pb42j9yqv82lcrgcvdwr6nkaphfi37q"))))
10316 (build-system python-build-system)
10319 (modify-phases %standard-phases
10320 (add-after 'unpack 'bootstrap
10321 ;; Move the tests out of the package directory to avoid
10324 (rename-file "validictory/tests" "tests")
10325 (delete-file "tests/__init__.py")))
10328 ;; Extend PYTHONPATH so the built package will be found.
10329 (setenv "PYTHONPATH"
10330 (string-append (getcwd) "/build/lib:"
10331 (getenv "PYTHONPATH")))
10332 (invoke "py.test" "-vv" ))))))
10334 `(("python-pytest" ,python-pytest)))
10336 "https://github.com/jamesturk/validictory")
10337 (synopsis "General purpose Python data validator")
10338 (description "It allows validation of arbitrary Python data structures.
10340 The schema format is based on the JSON Schema
10341 proposal (http://json-schema.org), so combined with json the library is also
10342 useful as a validator for JSON data.")
10343 (license license:expat)))
10345 (define-public python2-validictory
10346 (package-with-python2 python-validictory))
10348 (define-public python-pyelftools
10350 (name "python-pyelftools")
10355 (uri (pypi-uri "pyelftools" version))
10358 "090vdksbz341f7ljvr0zswblw4lspa8qaiikzyjkf318arpxmil9"))))
10359 (build-system python-build-system)
10362 (modify-phases %standard-phases
10363 (add-before 'check 'set-pythonpath
10365 (setenv "PYTHONPATH"
10368 ":" (getenv "PYTHONPATH")))
10371 "https://github.com/eliben/pyelftools")
10373 "Analyze binary and library file information")
10374 (description "This Python library provides interfaces for parsing and
10375 analyzing two binary and library file formats; the Executable and Linking
10376 Format (ELF), and debugging information in the Debugging With Attributed
10377 Record Format (DWARF).")
10378 (license license:public-domain)))
10380 (define-public python-pyev
10382 (name "python-pyev")
10387 (uri (pypi-uri "pyev" version))
10390 "0rf603lc0s6zpa1nb25vhd8g4y337wg2wyz56i0agsdh7jchl0sx"))))
10391 (build-system python-build-system)
10393 `(#:tests? #f ; no test suite
10395 (modify-phases %standard-phases
10396 (add-after 'unpack 'patch
10397 (lambda* (#:key inputs #:allow-other-keys)
10398 (let ((libev (string-append (assoc-ref inputs "libev")
10399 "/lib/libev.so.4")))
10400 (substitute* "setup.py"
10401 (("libev_dll_name = find_library\\(\\\"ev\\\"\\)")
10402 (string-append "libev_dll_name = \"" libev "\"")))))))))
10404 `(("libev" ,libev)))
10405 (home-page "http://pythonhosted.org/pyev/")
10406 (synopsis "Python libev interface")
10407 (description "Pyev provides a Python interface to libev.")
10408 (license license:gpl3)))
10410 (define-public python2-pyev
10411 (package-with-python2 python-pyev))
10413 (define-public python-imagesize
10415 (name "python-imagesize")
10420 (uri (pypi-uri "imagesize" version))
10423 "1dg3wn7qpwmhgqc0r9na2ding1wif9q5spz3j9zn2riwphc2k0zk"))))
10424 (build-system python-build-system)
10425 (home-page "https://github.com/shibukawa/imagesize_py")
10426 (synopsis "Gets image size of files in various formats in Python")
10428 "This package allows determination of image size from
10429 PNG, JPEG, JPEG2000 and GIF files in pure Python.")
10430 (license license:expat)))
10432 (define-public python2-imagesize
10433 (package-with-python2 python-imagesize))
10435 (define-public python-termstyle
10437 (name "python-termstyle")
10442 (uri (pypi-uri "termstyle" version))
10445 "17wzkkcqy5zc0g68xlad3kcv66iw14d2pwqc0h9420gak0vbhx7g"))))
10446 (build-system python-build-system)
10449 (modify-phases %standard-phases
10452 (invoke "python" "test3.py"))))))
10453 (home-page "https://github.com/gfxmonk/termstyle")
10454 (synopsis "Console text coloring for Python")
10455 (description "This package provides console text coloring for Python.")
10456 (license license:bsd-3)))
10458 (define-public python-argcomplete
10460 (name "python-argcomplete")
10465 (uri (pypi-uri "argcomplete" version))
10468 "11bwiw6j0nilgz81xnw6f1npyga3prp8asjqrm87cdr3ria5l03x"))))
10469 (build-system python-build-system)
10471 `(("python-pexpect" ,python-pexpect)
10473 ("bash-full" ,bash))) ;full Bash for 'test_file_completion'
10474 (home-page "https://github.com/kislyuk/argcomplete")
10475 (synopsis "Shell tab completion for Python argparse")
10476 (description "argcomplete provides extensible command line tab completion
10477 of arguments and options for Python scripts using @code{argparse}. It's
10478 particularly useful for programs with many options or sub-parsers that can
10479 dynamically suggest completions; for example, when browsing resources over the
10481 (license license:asl2.0)))
10483 (define-public python2-argcomplete
10484 (package-with-python2 python-argcomplete))
10486 (define-public python-xopen
10488 (name "python-xopen")
10493 (uri (pypi-uri "xopen" version))
10496 "1a0wbil552wsmklwd89ssmgz3pjd86qa9i7jh8wqb9wslc8a2qjr"))
10497 (file-name (string-append name "-" version ".tar.gz"))))
10498 (build-system python-build-system)
10499 (home-page "https://github.com/marcelm/xopen/")
10500 (synopsis "Open compressed files transparently")
10501 (description "This module provides an @code{xopen} function that works like
10502 Python's built-in @code{open} function, but can also deal with compressed files.
10503 Supported compression formats are gzip, bzip2 and, xz, and are automatically
10504 recognized by their file extensions. The focus is on being as efficient as
10505 possible on all supported Python versions.")
10506 (license license:expat)))
10508 (define-public python2-xopen
10509 (let ((base (package-with-python2
10510 (strip-python2-variant python-xopen))))
10513 (propagated-inputs `(("python2-bz2file" ,python2-bz2file)
10514 ,@(package-propagated-inputs base))))))
10516 (define-public python-cheetah
10518 (name "python-cheetah")
10523 (uri (pypi-uri "Cheetah3" version))
10526 "1ihag9cxll6b86fc8v5lkhmr3brdbi4yiz16zpgw79yylmv8fgr9"))))
10527 (build-system python-build-system)
10529 `(#:modules ((guix build utils)
10530 (guix build python-build-system)
10534 #:phases (modify-phases %standard-phases
10535 (add-after 'unpack 'use-absolute-python
10537 (substitute* "Cheetah/CheetahWrapper.py"
10538 (("#!/usr/bin/env python")
10539 (string-append "#!" (which "python"))))
10543 (let ((cwd (getcwd)))
10544 (setenv "PYTHONPATH"
10547 (find (cut string-prefix? "lib" <>)
10548 (scandir (string-append cwd "/build")))
10549 ":" (getenv "PYTHONPATH")))
10551 (string-append (getenv "PATH")
10553 (setenv "TMPDIR" "/tmp")
10555 (substitute* "Cheetah/Tests/Test.py"
10556 (("unittest.TextTestRunner\\(\\)")
10557 "unittest.TextTestRunner(verbosity=2)"))
10559 (invoke "python" "Cheetah/Tests/Test.py")))))))
10561 `(("python-markdown" ,python-markdown))) ;optional
10562 (home-page "http://cheetahtemplate.org/")
10563 (synopsis "Template engine")
10564 (description "Cheetah is a text-based template engine and Python code
10567 Cheetah can be used as a standalone templating utility or referenced as
10568 a library from other Python applications. It has many potential uses,
10569 but web developers looking for a viable alternative to ASP, JSP, PHP and
10570 PSP are expected to be its principle user group.
10574 @item Generates HTML, SGML, XML, SQL, Postscript, form email, LaTeX, or any other
10576 @item Cleanly separates content, graphic design, and program code.
10577 @item Blends the power and flexibility of Python with a simple template language
10578 that non-programmers can understand.
10579 @item Gives template writers full access to any Python data structure, module,
10580 function, object, or method in their templates.
10581 @item Makes code reuse easy by providing an object-orientated interface to
10582 templates that is accessible from Python code or other Cheetah templates.
10583 One template can subclass another and selectively reimplement sections of it.
10584 @item Provides a simple, yet powerful, caching mechanism that can dramatically
10585 improve the performance of a dynamic website.
10586 @item Compiles templates into optimized, yet readable, Python code.
10588 (license (license:x11-style "file://LICENSE"))))
10590 (define-public python2-cheetah
10591 (package-with-python2 python-cheetah))
10593 (define-public python-dulwich
10595 (name "python-dulwich")
10600 (uri (list (string-append "https://www.dulwich.io/releases/"
10601 "dulwich-" version ".tar.gz")
10602 (pypi-uri "dulwich" version)))
10605 "1aa1xfrxkc3j9s4xi0llhf5gndyi9ryprcxsqfa5fcb8ph34981q"))))
10606 (build-system python-build-system)
10609 (modify-phases %standard-phases
10610 (add-before 'check 'fix-tests
10611 (lambda* (#:key inputs #:allow-other-keys)
10612 ;; The tests use Popen with a custom environment which doesn't
10614 (substitute* "dulwich/tests/compat/utils.py"
10615 (("'git'") (string-append "'"
10618 (substitute* '("dulwich/tests/test_repository.py"
10619 "dulwich/tests/test_hooks.py")
10620 (("#!/bin/sh") (string-append "#!" (which "sh"))))
10621 (setenv "TEST_RUNNER" "unittest")
10622 (setenv "PYTHONHASHSEED" "random")
10625 `(("python-fastimport" ,python-fastimport)))
10627 `(("python-mock" ,python-mock)
10628 ("python-geventhttpclient" ,python-geventhttpclient)
10630 (home-page "https://www.dulwich.io/")
10631 (synopsis "Git implementation in Python")
10632 (description "Dulwich is an implementation of the Git file formats and
10633 protocols written in pure Python.")
10634 ;; Can be used with either license.
10635 (license (list license:asl2.0 license:gpl2+))))
10637 (define-public python2-dulwich
10638 (package-with-python2 python-dulwich))
10640 (define-public python-pbkdf2
10642 (name "python-pbkdf2")
10647 (uri (pypi-uri "pbkdf2" version))
10650 "0yb99rl2mbsaamj571s1mf6vgniqh23v98k4632150hjkwv9fqxc"))))
10651 (build-system python-build-system)
10654 (modify-phases %standard-phases
10657 (setenv "PYTHONPATH"
10658 (string-append (getcwd) "/build/lib:"
10659 (getenv "PYTHONPATH")))
10660 (invoke "python" "test/test_pbkdf2.py"))))))
10662 `(("python-pycrypto" ,python-pycrypto))) ; optional
10663 (home-page "https://www.dlitz.net/software/python-pbkdf2/")
10664 (synopsis "Password-based key derivation")
10665 (description "This module implements the password-based key derivation
10666 function, PBKDF2, specified in RSA PKCS#5 v2.0.
10668 PKCS#5 v2.0 Password-Based Key Derivation is a key derivation function which
10669 is part of the RSA Public Key Cryptography Standards series. The provided
10670 implementation takes a password or a passphrase and a salt value (and
10671 optionally a iteration count, a digest module, and a MAC module) and provides
10672 a file-like object from which an arbitrarly-sized key can be read.")
10673 (license license:expat)))
10675 (define-public python2-pbkdf2
10676 (package-with-python2 python-pbkdf2))
10678 (define-public python-qrcode
10680 (name "python-qrcode")
10685 (uri (pypi-uri "qrcode" version))
10688 "1gz1g2n9kqwqkak78aavr354z1v3yyiksk7q6xp5hi1zr6s0syq3"))))
10689 (build-system python-build-system)
10691 ;; FIXME: Tests require packaging 'pymaging'.
10694 `(("python-lxml" ,python-lxml) ; for SVG output
10695 ("python-pillow" ,python-pillow) ; for PNG output
10696 ("python-six" ,python-six)))
10698 `(;; The setup.cfg file needs to be used, and support for this requires
10699 ;; at least version 30.3.0 of setuptools
10700 ("python-setuptools" ,python-setuptools)))
10701 (home-page "https://github.com/lincolnloop/python-qrcode")
10702 (synopsis "QR Code image generator")
10703 (description "This package provides a pure Python QR Code generator
10704 module. It uses the Python Imaging Library (PIL) to allow for the generation
10707 In addition this package provides a command line tool to generate QR codes and
10708 either write these QR codes to a file or do the output as ascii art at the
10710 (license license:bsd-3)))
10712 (define-public python2-qrcode
10713 (package-with-python2 python-qrcode))
10715 (define-public python-rst2ansi
10717 (name "python-rst2ansi")
10722 (uri (pypi-uri "rst2ansi" version))
10725 "0vzy6gd60l79ff750scl0sz48r1laalkl6md6dwzah4dcadgn5qv"))))
10726 (build-system python-build-system)
10728 `(("python-docutils" ,python-docutils)))
10729 (home-page "https://github.com/Snaipe/python-rst-to-ansi")
10730 (synopsis "Convert RST to ANSI-decorated console output")
10732 "Python module dedicated to rendering RST (reStructuredText) documents
10733 to ansi-escaped strings suitable for display in a terminal.")
10734 (license license:expat)))
10736 (define-public python-ansi2html
10738 (name "python-ansi2html")
10743 (uri (pypi-uri "ansi2html" version))
10746 "1wa00zffprb78w1mqq90dk47czz1knanys2a40zbw2vyapd5lp9y"))))
10747 (build-system python-build-system)
10749 `(("python-mock" ,python-mock)
10750 ("python-nose" ,python-nose)))
10752 `(("python-six" ,python-six)))
10753 (home-page "https://github.com/ralphbean/ansi2html")
10754 (synopsis "Convert ANSI-decorated console output to HTML")
10756 "@command{ansi2html} is a Python library and command line utility for
10757 convering text with ANSI color codes to HTML or LaTeX.")
10758 (license license:gpl3+)))
10760 (define-public python2-ansi2html
10761 (package-with-python2 python-ansi2html))
10763 (define-public python-ddt
10765 (name "python-ddt")
10770 (uri (pypi-uri "ddt" version))
10773 "1lw17420iimhghkgzgax85nn8d1an2d6k2cfvb7j5kwn2dqlr1vk"))))
10774 (build-system python-build-system)
10776 `(("python-mock" ,python-mock)
10777 ("python-nose" ,python-nose)))
10779 `(("python-six" ,python-six)
10780 ("python-pyyaml" ,python-pyyaml)))
10781 (home-page "https://github.com/txels/ddt")
10782 (synopsis "Data-Driven Tests")
10784 "Data-Driven Tests (@dfn{DDT}) allow you to multiply one test case by
10785 running it with different test data, and make it appear as multiple test
10787 (license license:expat)))
10789 (define-public python2-ddt
10790 (package-with-python2 python-ddt))
10792 (define-public python-pycountry
10794 (name "python-pycountry")
10795 (version "18.5.26")
10799 (uri (pypi-uri "pycountry" version))
10802 "15q9j047s3yc9cfcxq1ch8b71f81na44cr6dydd5gxk0ki9a4akz"))))
10803 (build-system python-build-system)
10804 (home-page "https://bitbucket.org/flyingcircus/pycountry")
10805 (synopsis "ISO databases for languages, countries, currencies, etc.")
10807 "@code{pycountry} provides the ISO databases for the standards:
10809 @item 639-3 (Languages)
10810 @item 3166 (Countries)
10811 @item 3166-3 (Deleted Countries)
10812 @item 3166-2 (Subdivisions of countries)
10813 @item 4217 (Currencies)
10814 @item 15924 (Scripts)
10816 It includes a copy from Debian’s pkg-isocodes and makes the data accessible
10817 through a Python API.")
10818 (license license:lgpl2.1+)))
10820 (define-public python2-pycountry
10821 (package-with-python2 python-pycountry))
10823 (define-public python-pycosat
10825 (name "python-pycosat")
10830 (uri (pypi-uri "pycosat" version))
10833 "1kl3wh1f47rc712n4bmwplbx3fqz3x9i1b587jrbpmvdva4c8f6l"))))
10834 ;; TODO: Unundle picosat. http://fmv.jku.at/picosat/
10835 (build-system python-build-system)
10836 (home-page "https://github.com/ContinuumIO/pycosat")
10837 (synopsis "Bindings to picosat (a SAT solver)")
10839 "This package provides efficient Python bindings to @code{picosat} on
10840 the C level. When importing pycosat, the @code{picosat} solver becomes part
10841 of the Python process itself. @code{picosat} is a @dfn{Boolean Satisfiability
10842 Problem} (SAT) solver.")
10843 (license license:expat)))
10845 (define-public python2-pycosat
10846 (package-with-python2 python-pycosat))
10848 (define-public python2-ruamel.ordereddict
10850 (name "python2-ruamel.ordereddict")
10855 (uri (pypi-uri "ruamel.ordereddict" version))
10858 "1xmkl8v9l9inm2pyxgc1fm5005yxm7fkd5gv74q7lj1iy5qc8n3h"))))
10859 (build-system python-build-system)
10861 `(#:python ,python-2
10863 (modify-phases %standard-phases
10865 (add-after 'install 'check
10866 (lambda* (#:key inputs outputs #:allow-other-keys)
10867 (add-installed-pythonpath inputs outputs)
10868 (invoke "python" "test/testordereddict.py"))))))
10869 (home-page "https://bitbucket.org/ruamel/ordereddict")
10870 (synopsis "Version of dict that keeps keys in insertion order")
10872 "This is an implementation of an ordered dictionary with @dfn{Key
10873 Insertion Order} (KIO: updates of values do not affect the position of the
10874 key), @dfn{Key Value Insertion Order} (KVIO, an existing key's position is
10875 removed and put at the back). The standard library module @code{OrderedDict},
10876 implemented later, implements a subset of @code{ordereddict} functionality.
10877 Sorted dictionaries are also provided. Currently only with @dfn{Key Sorted
10878 Order} (KSO, no sorting function can be specified, but a transform can be
10879 specified to apply on the key before comparison (e.g. @code{string.lower})).")
10880 (license license:expat)))
10882 (define-public python-pypeg2
10884 (name "python-pypeg2")
10889 (uri (pypi-uri "pyPEG2" version))
10892 "0v8ziaam2r637v94ra4dbjw6jzxz99gs5x4i585kgag1v204yb9b"))))
10893 (build-system python-build-system)
10894 (propagated-inputs `(("python-lxml" ,python-lxml)))
10896 ;;https://bitbucket.org/fdik/pypeg/issues/36/test-failures-on-py35
10898 (home-page "https://fdik.org/pyPEG/")
10899 (synopsis "Parsering Expression Grammars in Python")
10900 (description "PyPEG is an intrinsic parser interpreter framework for
10901 Python. It is based on Parsing Expression Grammars, PEG. With pyPEG you can
10902 parse many formal languages.")
10903 (license license:gpl2)))
10905 (define-public python-incremental
10907 (name "python-incremental")
10912 (uri (pypi-uri "incremental" version))
10915 "1cylxdz1cnkm5g3pklna3h2n0i0rks95ir1pnpxfnvpkmab1cxbv"))))
10916 (build-system python-build-system)
10917 (home-page "https://github.com/hawkowl/incremental")
10918 (synopsis "Library for versioning Python projects")
10919 (description "Incremental is a small library that versions your Python
10921 (license license:expat)))
10923 (define-public python2-incremental
10924 (package-with-python2 python-incremental))
10926 (define-public python-invoke
10928 (name "python-invoke")
10929 (home-page "http://www.pyinvoke.org/")
10933 (uri (pypi-uri "invoke" version))
10936 "0aiy1xvk1f91246zxd1zqrm679vdvd10h843a2na41cqr3cflpi6"))))
10937 (build-system python-build-system)
10939 ;; XXX: Requires many dependencies that are not yet in Guix.
10941 (synopsis "Pythonic task execution")
10943 "Invoke is a Python task execution tool and library, drawing inspiration
10944 from various sources to arrive at a powerful and clean feature set. It is
10945 evolved from the Fabric project, but focuses on local and abstract concerns
10946 instead of servers and network commands.")
10947 (license license:bsd-3)))
10949 (define-public python2-invoke
10950 (package-with-python2 python-invoke))
10952 (define-public python-automat
10954 (name "python-automat")
10958 (uri (pypi-uri "Automat" version))
10961 "1a7nsrljysfmdqmpn2apfa1gg6rfah4y9sizvns8gb08rx7d07rw"))))
10962 (build-system python-build-system)
10963 ;; We disable the tests because they require python-twisted, while
10964 ;; python-twisted depends on python-automat. Twisted is optional, but the
10965 ;; tests fail if it is not available. Also see
10966 ;; <https://github.com/glyph/automat/issues/71>.
10967 (arguments '(#:tests? #f))
10969 `(("python-m2r" ,python-m2r)
10970 ("python-setuptools-scm" ,python-setuptools-scm)
10971 ("python-graphviz" ,python-graphviz)))
10973 `(("python-six" ,python-six)
10974 ("python-attrs" ,python-attrs)))
10975 (home-page "https://github.com/glyph/Automat")
10976 (synopsis "Self-service finite-state machines")
10977 (description "Automat is a library for concise, idiomatic Python
10978 expression of finite-state automata (particularly deterministic finite-state
10980 (license license:expat)))
10982 (define-public python2-automat
10983 (package-with-python2 python-automat))
10985 (define-public python-m2r
10987 (name "python-m2r")
10991 (uri (pypi-uri "m2r" version))
10994 "1axrwnf425sz4qz3c0qc7yhhki4myzb8rki7pczcsgzznzmqdyxd"))))
10995 (build-system python-build-system)
10997 `(("python-docutils" ,python-docutils)
10998 ("python-mistune" ,python-mistune)))
11000 `(("python-pygments" ,python-pygments)
11001 ("python-mock" ,python-mock)))
11002 (home-page "https://github.com/miyakogi/m2r")
11003 (synopsis "Markdown to reStructuredText converter")
11004 (description "M2R converts a markdown file including reST markups to valid
11006 (license license:expat)))
11008 (define-public python2-m2r
11009 (package-with-python2 python-m2r))
11011 (define-public python-constantly
11013 (name "python-constantly")
11017 (uri (pypi-uri "constantly" version))
11020 "0dgwdla5kfpqz83hfril716inm41hgn9skxskvi77605jbmp4qsq"))))
11021 (build-system python-build-system)
11022 (home-page "https://github.com/twisted/constantly")
11023 (synopsis "Symbolic constants in Python")
11024 (description "Constantly is a Python library that provides symbolic
11025 constant support. It includes collections and constants with text, numeric,
11026 and bit flag values.")
11027 (license license:expat)))
11029 (define-public python2-constantly
11030 (package-with-python2 python-constantly))
11032 (define-public python-attrs
11034 (name "python-attrs")
11038 (uri (pypi-uri "attrs" version))
11041 "0s9ydh058wmmf5v391pym877x4ahxg45dw6a0w4c7s5wgpigdjqh"))))
11042 (build-system python-build-system)
11044 `(#:modules ((guix build utils)
11045 (guix build python-build-system)
11049 #:phases (modify-phases %standard-phases
11052 (let ((cwd (getcwd)))
11053 (setenv "PYTHONPATH"
11056 (find (cut string-prefix? "lib" <>)
11057 (scandir (string-append cwd "/build")))
11059 (getenv "PYTHONPATH")))
11060 (invoke "python" "-m" "pytest")))))))
11062 `(("python-coverage" ,python-coverage)
11063 ("python-hypothesis" ,python-hypothesis)
11064 ("python-pympler" ,python-pympler)
11065 ("python-pytest" ,python-pytest)
11066 ("python-six" ,python-six)
11067 ("python-sphinx" ,python-sphinx)
11068 ("python-zope-interface" ,python-zope-interface)))
11069 (home-page "https://github.com/python-attrs/attrs/")
11070 (synopsis "Attributes without boilerplate")
11071 (description "@code{attrs} is a Python package with class decorators that
11072 ease the chores of implementing the most common attribute-related object
11074 (license license:expat)))
11076 (define-public python2-attrs
11077 (package-with-python2 python-attrs))
11079 (define-public python-attrs-bootstrap
11081 (inherit python-attrs)
11082 (name "python-attrs-bootstrap")
11083 ;; Keep this on a fixed version so python-attrs can be updated without
11084 ;; triggering a mass-rebuild. FIXME: Update this in the next rebuild cycle.
11088 (uri (pypi-uri "attrs" version))
11091 "1jafnn1kzd6qhxgprhx6y6ik1r5m2rilx25syzcmq03azp660y8w"))))
11092 (native-inputs `())
11093 (arguments `(#:tests? #f))))
11095 (define-public python2-attrs-bootstrap
11096 (package-with-python2 python-attrs-bootstrap))
11098 (define-public python2-cliapp
11100 (name "python2-cliapp")
11101 (version "1.20170823")
11105 (uri (string-append
11106 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/cliapp/snapshot/cliapp-"
11107 version ".tar.gz"))
11110 "1i9gik0xrj6jmi95s5w988jl1y265baz5xm5pbqdyvsh8h9ln6yq"))))
11111 (build-system python-build-system)
11113 `(#:python ,python-2
11115 (modify-phases %standard-phases
11116 ;; check phase needs to be run before the build phase. If not,
11117 ;; coverage-test-runner looks for tests for the built source files,
11120 (add-before 'build 'check
11122 ;; Disable python3 tests
11123 (substitute* "check"
11124 (("python3") "# python3"))
11125 (invoke "./check"))))))
11127 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)
11128 ("python2-pep8" ,python2-pep8)))
11130 `(("python2-pyaml" ,python2-pyaml)))
11131 (home-page "https://liw.fi/cliapp/")
11132 (synopsis "Python framework for command line programs")
11133 (description "@code{python2-cliapp} is a python framework for
11134 command line programs. It contains the typical stuff such programs
11135 need to do, such as parsing the command line for options, and
11136 iterating over input files.")
11137 (license license:gpl2+)))
11139 (define-public python2-ttystatus
11141 (name "python2-ttystatus")
11146 (uri (string-append
11147 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/ttystatus/snapshot/ttystatus-"
11148 version ".tar.gz"))
11151 "0vivqbw7ddhsq1zj3g9cvvv4f0phl0pis2smsnwcr2szz2fk3hl6"))))
11152 (build-system python-build-system)
11154 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)
11155 ("python2-pep8" ,python2-pep8)))
11157 `(#:python ,python-2
11159 (modify-phases %standard-phases
11160 ;; check phase needs to be run before the build phase. If not,
11161 ;; coverage-test-runner looks for tests for the built source files,
11164 (add-before 'build 'check
11165 (lambda _ (invoke "make" "check"))))))
11166 (home-page "https://liw.fi/ttystatus/")
11167 (synopsis "Python library for showing progress reporting and
11168 status updates on terminals")
11169 (description "@code{python2-ttystatus} is a python library for
11170 showing progress reporting and status updates on terminals, for
11171 command line programs. Output is automatically adapted to the width
11172 of the terminal: truncated if it does not fit, and resized if the
11173 terminal size changes.")
11174 (license license:gpl3+)))
11176 (define-public python2-tracing
11178 (name "python2-tracing")
11183 (uri (string-append
11184 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/python-tracing/snapshot/tracing-"
11185 version ".tar.gz"))
11188 "06cw4zg42fsvqy372vi2whj26w56vzg5axhzwdjc2bgwf03garbw"))))
11189 (build-system python-build-system)
11191 `(#:python ,python-2))
11192 (home-page "https://liw.fi/tracing/")
11193 (synopsis "Python debug logging helper")
11194 (description "@code{python2-tracing} is a python library for
11195 logging debug messages. It provides a way to turn debugging messages
11196 on and off, based on the filename they occur in. It is much faster
11197 than using @code{logging.Filter} to accomplish the same thing, which
11198 matters when code is run in production mode. The actual logging still
11199 happens using the @code{logging} library.")
11200 (license license:gpl3+)))
11202 (define-public python2-larch
11204 (name "python2-larch")
11205 (version "1.20151025")
11209 (uri (string-append
11210 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/larch/snapshot/larch-"
11211 version ".tar.gz"))
11212 (patches (search-patches
11213 "python2-larch-coverage-4.0a6-compatibility.patch"))
11216 "1p4knkkavlqymgciz2wbcnfrdgdbafhg14maplnk4vbw0q8xs663"))))
11217 (build-system python-build-system)
11219 `(#:python ,python-2
11221 (modify-phases %standard-phases
11222 ;; check phase needs to be run before the build phase. If not,
11223 ;; coverage-test-runner looks for tests for the built source files,
11226 (add-before 'build 'check
11227 (lambda _ (invoke "make" "check"))))))
11229 `(("cmdtest" ,cmdtest)
11230 ("python2-coverage-test-runner" ,python2-coverage-test-runner)))
11232 `(("python2-tracing" ,python2-tracing)))
11233 (home-page "https://liw.fi/larch/")
11234 (synopsis "Python copy-on-write B-tree library")
11235 (description "@code{python2-larch} is an implementation of
11236 particular kind of B-tree, based on research by Ohad Rodeh. See
11237 @url{http://liw.fi/larch/ohad-btrees-shadowing-clones.pdf} for details
11238 on the data structure.
11240 The distinctive feature of this B-tree is that a node is never
11241 (conceptually) modified. Instead, all updates are done by
11242 copy-on-write. This makes it easy to clone a tree, and modify only the
11243 clone, while other processes access the original tree.")
11244 (license license:gpl3+)))
11246 (define-public python-astroid
11248 (name "python-astroid")
11253 (uri (pypi-uri "astroid" version))
11256 "08hz675knh4294bancdapql392fmbjyimhbyrmfkz1ka7l035c1m"))))
11257 (build-system python-build-system)
11259 `(("python-lazy-object-proxy" ,python-lazy-object-proxy)
11260 ("python-six" ,python-six)
11261 ("python-wrapt" ,python-wrapt)))
11263 `(("python-dateutil" ,python-dateutil)
11264 ("python-nose" ,python-nose)
11265 ("python-pytest" ,python-pytest)
11266 ("python-pytest-runner" ,python-pytest-runner)))
11269 (modify-phases %standard-phases
11270 (add-after 'unpack 'remove-spurious-test
11272 ;; This can be removed after upgrading from python-3.7
11273 ;; https://github.com/PyCQA/astroid/issues/593
11274 ;; https://bugs.python.org/issue34056
11275 (delete-file "astroid/tests/unittest_modutils.py")
11279 (invoke "pytest" "astroid"))))))
11280 (home-page "https://github.com/PyCQA/astroid")
11281 (synopsis "Common base representation of python source code for pylint and
11283 (description "@code{python-astroid} provides a common base representation
11284 of python source code for projects such as pychecker, pyreverse, pylint, etc.
11286 It provides a compatible representation which comes from the _ast module. It
11287 rebuilds the tree generated by the builtin _ast module by recursively walking
11288 down the AST and building an extended ast. The new node classes have
11289 additional methods and attributes for different usages. They include some
11290 support for static inference and local name scopes. Furthermore, astroid
11291 builds partial trees by inspecting living objects.")
11292 (license license:lgpl2.1+)
11293 (properties `((python2-variant . ,(delay python2-astroid))))))
11295 (define-public python2-astroid
11296 (let ((base (package-with-python2
11297 (strip-python2-variant python-astroid))))
11298 (package (inherit base)
11299 ;; Version 2.x removes python2 support.
11304 (uri (pypi-uri "astroid" version))
11307 "0fir4b67sm7shcacah9n61pvq313m523jb4q80sycrh3p8nmi6zw"))))
11309 (substitute-keyword-arguments (package-arguments base)
11311 `(modify-phases ,phases
11312 (add-after 'unpack 'remove-spurious-test
11314 ;; https://github.com/PyCQA/astroid/issues/276
11315 (delete-file "astroid/tests/unittest_brain.py")
11319 (invoke"python" "-m" "unittest" "discover"
11320 "-p" "unittest*.py")))))))
11321 (native-inputs `())
11323 `(("python2-backports-functools-lru-cache"
11324 ,python2-backports-functools-lru-cache)
11325 ("python2-enum34" ,python2-enum34)
11326 ("python2-singledispatch" ,python2-singledispatch)
11327 ,@(package-propagated-inputs base))))))
11329 (define-public python-isort
11331 (name "python-isort")
11336 (uri (git-reference
11337 ;; Tests pass only from the Github sources
11338 (url "https://github.com/timothycrosley/isort")
11340 (file-name (git-file-name name version))
11343 "1q0mlrpki5vjbgwxag5rghljjcfg7mvb0pbkwid80p0sqrxlm2p6"))))
11344 (build-system python-build-system)
11346 `(("python-mock" ,python-mock)
11347 ("python-pytest" ,python-pytest)))
11348 (home-page "https://github.com/timothycrosley/isort")
11349 (synopsis "Python utility/library to sort python imports")
11350 (description "@code{python-isort} is a python utility/library to sort
11351 imports alphabetically, and automatically separated into sections. It
11352 provides a command line utility, a python library and plugins for various
11354 (license license:expat)
11355 (properties `((python2-variant . ,(delay python2-isort))))))
11357 (define-public python2-isort
11358 (let ((base (package-with-python2
11359 (strip-python2-variant python-isort))))
11360 (package (inherit base)
11362 `(("python2-futures" ,python2-futures)
11363 ,@(package-native-inputs base))))))
11365 (define-public python2-backports-functools-lru-cache
11367 (name "python2-backports-functools-lru-cache")
11372 ;; only the pypi tarballs contain the necessary metadata
11373 (uri (pypi-uri "backports.functools_lru_cache" version))
11376 "06jgv8gib4fhky0p5cmxdghvsgjyzcdgk48k8pxb1ccf11znk64x"))))
11377 (build-system python-build-system)
11379 `(("python2-setuptools-scm" ,python2-setuptools-scm)))
11381 `(#:python ,python-2))
11382 (home-page "https://github.com/jaraco/backports.functools_lru_cache")
11383 (synopsis "Backport of functools.lru_cache from Python 3.3")
11384 (description "@code{python2-backports-functools-lru-cache} is a backport
11385 of @code{functools.lru_cache} from python 3.3.")
11386 (license license:expat)))
11388 (define-public python-configparser
11390 (name "python-configparser")
11395 (uri (string-append
11396 "https://bitbucket.org/ambv/configparser/get/"
11397 version ".tar.bz2"))
11398 (file-name (string-append name "-" version ".tar.gz"))
11401 "0waq40as14abwzbb321hfz4vr1fi363nscy32ga14qvfygrg96wa"))))
11402 (build-system python-build-system)
11403 (home-page "http://docs.python.org/py3k/library/configparser.html")
11404 (synopsis "Backport of configparser from python 3.5")
11405 (description "@code{python-configparser} is a backport of
11406 @code{configparser} from Python 3.5 so that it can be used directly
11407 in other versions.")
11408 (license license:expat)))
11410 (define-public python2-configparser
11411 (package-with-python2 python-configparser))
11413 (define-public python-mando
11415 (name "python-mando")
11419 (uri (pypi-uri "mando" version))
11422 "0q6rl085q1hw1wic52pqfndr0x3nirbxnhqj9akdm5zhq2fv3zkr"))))
11423 (build-system python-build-system)
11425 `(("python-rst2ansi" ,python-rst2ansi)
11426 ("python-six" ,python-six)))
11428 `(("python-pytest" ,python-pytest)))
11429 (home-page "https://mando.readthedocs.org/")
11431 "Wrapper around argparse, allowing creation of complete CLI applications")
11433 "This package is a wrapper around argparse, allowing you to write complete CLI
11434 applications in seconds while maintaining all the flexibility.")
11435 (license license:expat)))
11437 (define-public python2-mando
11438 (package-with-python2 python-mando))
11440 (define-public python-fudge
11442 (name "python-fudge")
11443 ;; 0.9.6 is the latest version suitable for testing the "fabric" Python 2
11444 ;; package, which is currently the only use of this package.
11449 (uri (pypi-uri "fudge" version))
11452 "185ia3vr3qk4f2s1a9hdxb8ci4qc0x0xidrad96pywg8j930qs9l"))))
11453 (build-system python-build-system)
11455 `(#:tests? #f)) ;XXX: Tests require the NoseJS Python package.
11456 (home-page "https://github.com/fudge-py/fudge")
11457 (synopsis "Replace real objects with fakes/mocks/stubs while testing")
11459 "Fudge is a Python module for using fake objects (mocks and stubs) to
11462 In readable Python code, you declare the methods available on your fake object
11463 and how they should be called. Then you inject that into your application and
11464 start testing. This declarative approach means you don’t have to record and
11465 playback actions and you don’t have to inspect your fakes after running code.
11466 If the fake object was used incorrectly then you’ll see an informative
11467 exception message with a traceback that points to the culprit.")
11468 (license license:expat)))
11470 (define-public python2-fudge
11471 (package-with-python2 python-fudge))
11473 (define-public python-mwclient
11475 (name "python-mwclient")
11480 ;; The PyPI version wouldn't contain tests.
11481 (uri (string-append "https://github.com/mwclient/mwclient/archive/"
11482 "v" version ".tar.gz"))
11483 (file-name (string-append name "-" version ".tar.gz"))
11486 "1jj0yhilkjir00719fc7w133x7hdyhkxhk6xblla4asig45klsfv"))))
11487 (build-system python-build-system)
11489 `(("python-requests" ,python-requests)
11490 ("python-requests-oauthlib"
11491 ,python-requests-oauthlib)
11492 ("python-six" ,python-six)))
11494 `(("python-mock" ,python-mock)
11495 ("python-pytest" ,python-pytest)
11496 ("python-pytest-pep8" ,python-pytest-pep8)
11497 ("python-pytest-cache" ,python-pytest-cache)
11498 ("python-pytest-cov" ,python-pytest-cov)
11499 ("python-responses" ,python-responses)))
11500 (home-page "https://github.com/btongminh/mwclient")
11501 (synopsis "MediaWiki API client")
11502 (description "This package provides a MediaWiki API client.")
11503 (license license:expat)))
11505 (define-public python2-mwclient
11506 (package-with-python2 python-mwclient))
11508 (define-public python-utils
11510 (name "python-utils")
11514 (uri (pypi-uri "python-utils" version))
11517 "1mcsy6q5am4ya72rgkpb6kax6vv7c93cfkkas89xnpa4sj9zf28p"))))
11518 (build-system python-build-system)
11520 `(("pytest-runner" ,python-pytest-runner)
11521 ("pytest" ,python-pytest)
11522 ("six" ,python-six)))
11523 (home-page "https://github.com/WoLpH/python-utils")
11524 (synopsis "Convenient utilities not included with the standard Python install")
11526 "Python Utils is a collection of small Python functions and classes which
11527 make common patterns shorter and easier.")
11528 (license license:bsd-2)))
11530 (define-public python2-utils
11531 (package-with-python2 python-utils))
11533 (define-public python-sphinx-me
11535 (name "python-sphinx-me")
11540 (uri (pypi-uri "sphinx-me" version))
11543 "06jzgp213zihnvpcy2y5jy3ykid3apc2ncp2pg6a2g05lhiziglq"))))
11544 (build-system python-build-system)
11545 (home-page "https://github.com/stephenmcd/sphinx-me")
11546 (synopsis "Create a Sphinx documentation shell")
11548 "Create a Sphinx documentation shell for your project and include the
11549 README file as the documentation index. It handles extracting the required
11550 meta data such as the project name, author and version from your project for
11551 use in your Sphinx docs.")
11552 (license license:bsd-2)))
11554 (define-public python2-sphinx-me
11555 (package-with-python2 python-sphinx-me))
11557 (define-public python-diff-match-patch
11559 (name "python-diff-match-patch")
11560 (version "20121119")
11564 (uri (pypi-uri "diff-match-patch" version))
11567 "0k1f3v8nbidcmmrk65m7h8v41jqi37653za9fcs96y7jzc8mdflx"))))
11568 (build-system python-build-system)
11569 (home-page "https://code.google.com/p/google-diff-match-patch")
11570 (synopsis "Synchronize plain text")
11571 (description "Diff Match and Patch libraries offer robust algorithms to
11572 perform the operations required for synchronizing plain text.")
11573 (license license:asl2.0)))
11575 (define-public python2-diff-match-patch
11576 (package-with-python2 python-diff-match-patch))
11578 (define-public python-dirsync
11580 (name "python-dirsync")
11585 (uri (pypi-uri "dirsync" version))
11588 "1r40fkanksagcszf1ag85mdr8w7rgc7196n6s1qlsk2abw6i7v0z"))))
11589 (build-system python-build-system)
11591 `(("six" ,python-six)))
11592 (home-page "https://bitbucket.org/tkhyn/dirsync")
11593 (synopsis "Advanced directory tree synchronisation tool")
11594 (description "Advanced directory tree synchronisation tool.")
11595 (license license:expat)))
11597 (define-public python2-dirsync
11598 (package-with-python2 python-dirsync))
11600 (define-public python-levenshtein
11602 (name "python-levenshtein")
11607 (uri (pypi-uri "python-Levenshtein" version))
11610 "1c9ybqcja31nghfcc8xxbbz9h60s9qi12b9hr4jyl69xbvg12fh3"))))
11611 (build-system python-build-system)
11612 (home-page "https://github.com/ztane/python-Levenshtein")
11613 (synopsis "Fast computation of Levenshtein distance and string similarity")
11615 "The Levenshtein Python C extension module contains functions for fast computation of
11617 @item Levenshtein (edit) distance, and edit operations
11618 @item string similarity
11619 @item approximate median strings, and generally string averaging
11620 @item string sequence and set similarity
11622 It supports both normal and Unicode strings.")
11623 (license license:gpl2+)))
11625 (define-public python2-levenshtein
11626 (package-with-python2 python-levenshtein))
11628 (define-public python-scandir
11630 (name "python-scandir")
11635 (uri (pypi-uri "scandir" version))
11637 (base32 "0r3hvf1a9jm1rkqgx40gxkmccknkaiqjavs8lccgq9s8khh5x5s4"))))
11638 (build-system python-build-system)
11640 `(#:phases (modify-phases %standard-phases
11643 (invoke "python" "test/run_tests.py"))))))
11644 (home-page "https://github.com/benhoyt/scandir")
11645 (synopsis "Directory iteration function")
11647 "Directory iteration function like os.listdir(), except that instead of
11648 returning a list of bare filenames, it yields DirEntry objects that include
11649 file type and stat information along with the name. Using scandir() increases
11650 the speed of os.walk() by 2-20 times (depending on the platform and file
11651 system) by avoiding unnecessary calls to os.stat() in most cases.
11653 This package is part of the Python standard library since version 3.5.")
11654 (license license:bsd-3)))
11656 (define-public python2-scandir
11657 (package-with-python2 python-scandir))
11659 (define-public python2-stemming
11661 (name "python2-stemming")
11666 (uri (pypi-uri "stemming" version))
11668 (base32 "0ldwa24gnnxhniv0fhygkpc2mwgd93q10ag8rvzayv6hw418frsr"))))
11669 (build-system python-build-system)
11671 `(#:python ,python-2))
11672 (home-page "https://bitbucket.org/mchaput/stemming/overview")
11673 (synopsis "Python implementations of various stemming algorithms")
11675 "Python implementations of the Porter, Porter2, Paice-Husk, and Lovins
11676 stemming algorithms for English. These implementations are straightforward and
11677 efficient, unlike some Python versions of the same algorithms available on the
11678 Web. This package is an extraction of the stemming code included in the Whoosh
11680 (license license:public-domain)))
11682 (define-public python-factory-boy
11684 (name "python-factory-boy")
11689 (uri (pypi-uri "factory_boy" version))
11691 (base32 "1fvin6san5xsjh2c4y18caj2lnmwxlylyqm8mh1yc6rp38wlwr56"))))
11692 (build-system python-build-system)
11694 ;; Tests are not included in the tarball.
11697 `(("faker" ,python-faker)))
11698 (home-page "https://github.com/benhoyt/scandir")
11699 (synopsis "Versatile test fixtures replacement")
11701 "Factory_boy is a fixtures replacement based on thoughtbot’s factory_girl.
11703 As a fixtures replacement tool, it aims to replace static, hard to maintain
11704 fixtures with easy-to-use factories for complex object.
11706 Instead of building an exhaustive test setup with every possible combination
11707 of corner cases, factory_boy allows you to use objects customized for the
11708 current test, while only declaring the test-specific fields")
11709 (license license:expat)))
11711 (define-public python2-factory-boy
11712 (package-with-python2 python-factory-boy))
11714 (define-public python-translate-toolkit
11716 (name "python-translate-toolkit")
11721 (uri (pypi-uri "translate-toolkit" version ".tar.bz2"))
11723 (base32 "1vlkwrg83vb17jc36pmwh2b7jphwf390lz0jw8hakcg16qhwypvq"))))
11724 (build-system python-build-system)
11726 `(("python-pytest" ,python-pytest)
11727 ("python-sphinx" ,python-sphinx)))
11729 `(("python-babel" ,python-babel)
11730 ("python-beautifulsoup4" ,python-beautifulsoup4)
11731 ("python-chardet" ,python-chardet)
11732 ("python-diff-match-patch" ,python-diff-match-patch)
11733 ("python-levenshtein" ,python-levenshtein)
11734 ("python-lxml" ,python-lxml)
11735 ("python-six" ,python-six)
11736 ("python-vobject" ,python-vobject)
11737 ("python-pyyaml" ,python-pyyaml)))
11739 ;; TODO: tests are not run, because they end with
11740 ;; TypeError: parse() missing 2 required positional arguments: 'tree' and
11742 ;; during test setup.
11744 (home-page "http://toolkit.translatehouse.org")
11745 (synopsis "Tools and API for translation and localization engineering")
11747 "Tools and API for translation and localization engineering. It contains
11748 several utilities, as well as an API for building localization tools.")
11749 (license license:gpl2+)))
11751 (define-public python2-translate-toolkit
11752 (package-with-python2 python-translate-toolkit))
11754 (define-public python-packaging
11756 (name "python-packaging")
11761 (uri (pypi-uri "packaging" version))
11764 "01wq9c53ix5rz6qg2c98gy8n4ff768rmanifm8m5jpjiaizj51h8"))))
11765 (build-system python-build-system)
11767 `(#:phases (modify-phases %standard-phases
11769 (lambda _ (invoke "py.test" "-vv"))))))
11771 `(("python-pretend" ,python-pretend)
11772 ("python-pytest" ,python-pytest)))
11774 `(("python-pyparsing" ,python-pyparsing)
11775 ("python-six" ,python-six)))
11776 (home-page "https://github.com/pypa/packaging")
11777 (synopsis "Core utilities for Python packages")
11778 (description "Packaging is a Python module for dealing with Python packages.
11779 It offers an interface for working with package versions, names, and dependency
11781 ;; From 'LICENSE': This software is made available under the terms of
11782 ;; *either* of the licenses found in LICENSE.APACHE or LICENSE.BSD.
11783 ;; Contributions to this software is made under the terms of *both* these
11785 (license (list license:asl2.0 license:bsd-2))))
11787 (define-public python2-packaging
11788 (package-with-python2 python-packaging))
11790 (define-public python-relatorio
11792 (name "python-relatorio")
11797 (uri (pypi-uri "relatorio" version))
11800 "1na6hlhz1awi1hbjg1gyclq0khz42iz90wvdjw7mmj655788bpxx"))))
11801 (build-system python-build-system)
11803 `(("python-lxml" ,python-lxml)
11804 ("python-genshi" ,python-genshi)))
11806 `(("python-magic" ,python-magic)))
11807 (home-page "https://relatorio.tryton.org/")
11808 (synopsis "Templating library able to output ODT and PDF files")
11809 (description "Relatorio is a templating library which provides a way to
11810 easily output ODT, ODS, PNG, SVG and several other kinds of files. Support
11811 for more filetypes can be easily added by creating plugins for them.")
11812 (license license:gpl3+)))
11814 (define-public python2-relatorio
11815 (package-with-python2 python-relatorio))
11817 (define-public python-radon
11819 (name "python-radon")
11824 (uri (pypi-uri "radon" version))
11827 "07gq5hq4nrffxnlnksws9hrx7fd001gam63j62i82gyfr23gvdym"))))
11828 (build-system python-build-system)
11830 `(#:phases (modify-phases %standard-phases
11833 (invoke "python" "radon/tests/run.py"))))))
11835 `(("python-colorama" ,python-colorama)
11836 ("python-flake8-polyfill" ,python-flake8-polyfill)
11837 ("python-mando" ,python-mando)))
11839 `(("python-pytest" ,python-pytest)
11840 ("python-pytest-mock" ,python-pytest-mock)))
11841 (home-page "https://radon.readthedocs.org/")
11842 (synopsis "Code Metrics in Python")
11843 (description "Radon is a Python tool which computes various code metrics.
11844 Supported metrics are:
11846 @item raw metrics: SLOC, comment lines, blank lines, &c.
11847 @item Cyclomatic Complexity (i.e. McCabe’s Complexity)
11848 @item Halstead metrics (all of them)
11849 @item the Maintainability Index (a Visual Studio metric)
11851 (license license:expat)))
11853 (define-public python2-radon
11854 (package-with-python2 python-radon))
11856 (define-public python-sure
11858 (name "python-sure")
11863 (uri (pypi-uri "sure" version))
11866 "1and0drq8w9iplsic22n2h7hkpyq03a1mbqk4sgcdqhqzdqm539w"))))
11867 (build-system python-build-system)
11869 `(("python-mock" ,python-mock)
11870 ("python-six" ,python-six)))
11872 `(("python-nose" ,python-nose)))
11873 (home-page "https://github.com/gabrielfalcao/sure")
11874 (synopsis "Automated testing library in python for python")
11876 "Sure is a python library that leverages a DSL for writing assertions.
11877 Sure is heavily inspired by @code{RSpec Expectations} and @code{should.js}.")
11878 (license license:gpl3+)))
11880 (define-public python2-sure
11881 (package-with-python2 python-sure))
11883 (define-public python2-couleur
11884 ;; This package does not seem to support python3 at all, hence,
11885 ;; only the python2 variant definition is provided.
11887 (name "python2-couleur")
11892 (uri (pypi-uri "couleur" version))
11895 "1qqaxyqz74wvid0cr119dhcwz0h0if5b5by44zl49pd5z65v58k1"))))
11896 (build-system python-build-system)
11898 `(#:python ,python-2))
11899 (home-page "https://github.com/gabrielfalcao/couleur")
11901 "ANSI terminal tool for python, colored shell and other handy fancy features")
11903 "@code{Couleur} provides python programs a way to use the ANSI features in a unix
11904 terminal such as coloured output in the shell, overwriting output, indentation, etc.")
11905 ;; README.md says ASL2.0, but all source code headers are LGPL3+.
11906 ;; https://github.com/gabrielfalcao/couleur/issues/11
11907 (license license:lgpl3+)))
11909 (define-public python-misaka
11911 (name "python-misaka")
11916 (uri (pypi-uri "misaka" version))
11919 "1yqrq3a5rracirmvk52n28nn6ckdaz897gnigv89a9gmyn87sqw7"))))
11920 (build-system python-build-system)
11922 `(;; Line 37 of setup.py calls self.run_command('develop')
11923 ;; in the 'check' phase. This command seems to be trying
11925 ;; /gnu/store/...-python-<version>/lib/python<version>/site-packages/
11926 ;; for which it does not have the permission to write.
11929 `(("python-cffi" ,python-cffi)))
11930 (home-page "https://github.com/FSX/misaka")
11931 (synopsis "Python binding for Hoedown")
11933 "@code{Misaka} is a CFFI-based binding for @code{Hoedown}, a fast markdown processing
11934 library written in C. It features a fast HTML renderer and functionality to make custom
11935 renderers (e.g. man pages or LaTeX).")
11936 (license license:expat)))
11938 (define-public python2-misaka
11939 (package-with-python2 python-misaka))
11941 (define-public python2-steadymark
11942 ;; This is forced into being a python2 only variant
11943 ;; due to its dependence on couleur that has no support
11946 (name "python2-steadymark")
11951 (uri (pypi-uri "steadymark" version))
11954 "1640i9g8dycql3cc8j0bky0jkzj0q39blfbp4lsgpkprkfgcdk8v"))))
11955 (build-system python-build-system)
11957 `(("python-couleur" ,python2-couleur)
11958 ("python-sure" ,python2-sure)
11959 ("python-misaka" ,python2-misaka)))
11961 `(#:python ,python-2
11963 (modify-phases %standard-phases
11964 (add-before 'build 'patch-setup-py
11966 ;; Update requirements from dependency==version
11967 ;; to dependency>=version
11968 (substitute* "setup.py"
11971 (home-page "https://github.com/gabrielfalcao/steadymark")
11972 (synopsis "Markdown-based test runner for python")
11974 "@code{Steadymark} allows documentation to be written in github-flavoured
11975 markdown. The documentation may contain snippets of code surrounded by python
11976 code blocks and @code{Steadymark} will find these snippets and run them, making
11977 sure that there are no old malfunctional examples in the documentation examples.")
11978 (license license:expat)))
11980 (define-public python-jsonpointer
11982 (name "python-jsonpointer")
11987 (uri (pypi-uri "jsonpointer" version))
11990 "1cg0gvgqjysydv6p45v4jywg1jb3v48c7m3cbpi57zgf6nndr9cz"))))
11991 (build-system python-build-system)
11992 (home-page "https://github.com/stefankoegl/python-json-pointer")
11993 (synopsis "Identify specific nodes in a JSON document")
11994 (description "@code{jsonpointer} allows you to access specific nodes
11995 by path in a JSON document (see RFC 6901).")
11996 (license license:bsd-3)))
11998 (define-public python2-jsonpointer
11999 (package-with-python2 python-jsonpointer))
12001 (define-public python-jsonpatch
12003 (name "python-jsonpatch")
12008 ;; pypi version lacks tests.js
12009 (uri (string-append "https://github.com/stefankoegl/python-json-patch/"
12010 "archive/v" version ".tar.gz"))
12011 (file-name (string-append name "-" version ".tar.gz"))
12014 "085ykisl8v7mv9h7hvhdy3l2fjzs4214gx32r5k6nx4f76hbv6y5"))))
12015 (build-system python-build-system)
12017 `(("python-jsonpointer" ,python-jsonpointer)))
12018 (home-page "https://github.com/stefankoegl/python-json-patch")
12019 (synopsis "Applying JSON Patches in Python 2.6+ and 3.x")
12020 (description "@code{jsonpatch} is a library and program that allows
12021 applying JSON Patches according to RFC 6902.")
12022 (license license:bsd-3)))
12024 (define-public python2-jsonpatch
12025 (package-with-python2 python-jsonpatch))
12027 (define-public python-jsonpatch-0.4
12028 (package (inherit python-jsonpatch)
12029 (name "python-jsonpatch")
12034 (uri (string-append "https://github.com/stefankoegl/python-json-patch/"
12035 "archive/v" version ".tar.gz"))
12036 (file-name (string-append name "-" version ".tar.gz"))
12039 "0j0cd9z9zyp8kppp464jxrfgrnbgkzl1yi10i5gsv8yz6d95929d"))))))
12041 (define-public python2-jsonpatch-0.4
12042 (package-with-python2 python-jsonpatch-0.4))
12044 (define-public python-rfc3986
12046 (name "python-rfc3986")
12050 (uri (pypi-uri "rfc3986" version))
12053 "06wlmysw83f75ff84zr1yr6n0shvc2xn1n1sb4iwzqap9hf5fn44"))))
12054 (build-system python-build-system)
12056 `(#:modules ((guix build utils)
12057 (guix build python-build-system)
12062 (modify-phases %standard-phases
12065 (let ((cwd (getcwd)))
12066 (setenv "PYTHONPATH"
12067 (string-append cwd "/build/"
12068 (find (cut string-prefix? "lib" <>)
12069 (scandir (string-append cwd "/build")))
12071 (getenv "PYTHONPATH")))
12072 (invoke "pytest" "-v")))))))
12074 `(("python-pytest" ,python-pytest)))
12075 (home-page "https://rfc3986.readthedocs.io/")
12076 (synopsis "Parse and validate URI references")
12078 "@code{rfc3986} is a Python implementation of RFC@tie{}3986 including
12079 validation and authority parsing. This module also supports RFC@tie{}6874
12080 which adds support for zone identifiers to IPv6 addresses.")
12081 (license license:asl2.0)))
12083 (define-public python2-rfc3986
12084 (package-with-python2 python-rfc3986))
12086 (define-public python-rfc3987
12088 (name "python-rfc3987")
12093 (uri (pypi-uri "rfc3987" version))
12096 "192pclzs2y0yaywqkrlvd0x73740q310kvqvm6jldhi619mq59wi"))))
12097 (build-system python-build-system)
12098 (home-page "https://pypi.python.org/pypi/rfc3987")
12099 (synopsis "Parsing and validation of URIs (RFC 3986) and IRIs (RFC 3987)")
12100 (description "@code{rfc3987} provides routines for parsing and
12101 validation of URIs (see RFC 3986) and IRIs (see RFC 3987).")
12102 (license license:gpl3+)))
12104 (define-public python2-rfc3987
12105 (package-with-python2 python-rfc3987))
12107 (define-public python-validate-email
12109 (name "python-validate-email")
12114 (uri (pypi-uri "validate_email" version))
12117 "1bxffaf5yz2cph8ki55vdvdypbwkvn2xr1firlcy62vqbzf1jivq"))))
12118 (build-system python-build-system)
12119 (home-page "https://github.com/syrusakbary/validate_email")
12120 (synopsis "Verifies if an email address is valid and really exists")
12121 (description "@code{validate_email} can be used to verify if an email
12122 address is valid and really exists.")
12123 (license license:lgpl3+)))
12125 (define-public python2-validate-email
12126 (package-with-python2 python-validate-email))
12128 (define-public python-flex
12130 (name "python-flex")
12135 (uri (pypi-uri "flex" version))
12138 "00pamnwla3khk8nyla7y28dq9jnh69swd7f4jfsl7sn1izs8n8zk"))))
12139 (build-system python-build-system)
12141 `(("python-click" ,python-click)
12142 ("python-iso8601" ,python-iso8601)
12143 ("python-jsonpointer" ,python-jsonpointer)
12144 ("python-pyyaml" ,python-pyyaml)
12145 ("python-requests" ,python-requests)
12146 ("python-rfc3987" ,python-rfc3987)
12147 ("python-six" ,python-six)
12148 ("python-validate-email" ,python-validate-email)))
12149 (home-page "https://github.com/pipermerriam/flex")
12150 (synopsis "Validates Swagger schemata")
12151 (description "@code{flex} can be used to validate Swagger schemata.")
12152 (license license:bsd-3)))
12154 (define-public python2-flex
12155 (package-with-python2 python-flex))
12157 (define-public python-marshmallow
12159 (name "python-marshmallow")
12160 (version "3.0.0b14")
12164 (uri (pypi-uri "marshmallow" version))
12167 "1digk3f5cfk7wmlka65mc7bzsd96pbsgcsvp6pimd5b4ff9zb5p3"))))
12168 (build-system python-build-system)
12170 `(("python-dateutil" ,python-dateutil)
12171 ("python-simplejson" ,python-simplejson)))
12173 `(("python-pytest" ,python-pytest)
12174 ("python-pytz" ,python-pytz)))
12175 (home-page "https://github.com/marshmallow-code/marshmallow")
12176 (synopsis "Convert complex datatypes to and from native
12177 Python datatypes.")
12178 (description "@code{marshmallow} provides a library for converting
12179 complex datatypes to and from native Python datatypes.")
12180 (license license:expat)))
12182 (define-public python2-marshmallow
12183 (package-with-python2 python-marshmallow))
12185 (define-public python-apispec
12187 (name "python-apispec")
12192 (uri (pypi-uri "apispec" version))
12195 "0kxa8723zbisx10363yh4mmmn4higxrspymbjfz5zq8f644zagm9"))))
12196 (build-system python-build-system)
12198 `(("python-pyyaml" ,python-pyyaml)))
12200 `(("python-pytest" ,python-pytest)
12201 ("python-flask" ,python-flask)
12202 ("python-marshmallow" ,python-marshmallow)
12203 ("python-tornado" ,python-tornado)
12204 ("python-bottle" ,python-bottle)
12205 ("python-mock" ,python-mock)))
12206 (home-page "https://github.com/marshmallow-code/apispec")
12207 (synopsis "Swagger 2.0 API specification generator")
12208 (description "@code{python-apispec} is a pluggable API specification
12209 generator. Currently supports the OpenAPI specification (f.k.a.
12211 (license license:expat)))
12213 (define-public python2-apispec
12214 (package-with-python2 python-apispec))
12216 (define-public python-flasgger
12218 (name "python-flasgger")
12223 (uri (string-append "https://github.com/rochacbruno/flasgger/archive/"
12224 version ".tar.gz"))
12225 (file-name (string-append name "-" version ".tar.gz"))
12228 "1gqzlm0rb55fdpsy5ipkganlx9cnpi454fqyycr03jm22zql14ay"))))
12229 (build-system python-build-system)
12232 (modify-phases %standard-phases
12234 (lambda* (#:key inputs outputs #:allow-other-keys)
12235 (substitute* "Makefile"
12236 (("flake8 flasgger --ignore=F403")
12237 "flake8 flasgger --ignore=E731,F403"))
12238 (setenv "PYTHONPATH" (string-append (getcwd)
12240 (getenv "PYTHONPATH")))
12241 (invoke "py.test"))))))
12243 `(("python-flask" ,python-flask)
12244 ("python-pyyaml" ,python-pyyaml)
12245 ("python-jsonschema" ,python-jsonschema)
12246 ("python-mistune" ,python-mistune)
12247 ("python-six" ,python-six)))
12249 `(("python-decorator" ,python-decorator)
12250 ("python-flake8" ,python-flake8)
12251 ("python-flask-restful" ,python-flask-restful)
12252 ("python-flex" ,python-flex)
12253 ("python-pytest" ,python-pytest)
12254 ("python-pytest-cov" ,python-pytest-cov)
12255 ("python-marshmallow" ,python-marshmallow)
12256 ("python-apispec" ,python-apispec)))
12257 (home-page "https://github.com/rochacbruno/flasgger/")
12258 (synopsis "Extract Swagger specs from your Flask project")
12259 (description "@code{python-flasgger} allows extracting Swagger specs
12260 from your Flask project. It is a fork of Flask-Swagger.")
12261 (license license:expat)))
12263 (define-public python2-flasgger
12264 (package-with-python2 python-flasgger))
12266 (define-public python-swagger-spec-validator
12268 (name "python-swagger-spec-validator")
12273 (uri (pypi-uri "swagger-spec-validator" version))
12276 "13hkpn2lycwr0468yqhjb3kwszqf7hjwlq61w7vdxq1caz31k4nw"))))
12277 (build-system python-build-system)
12279 `(("python-jsonschema" ,python-jsonschema)
12280 ("python-six" ,python-six)))
12282 "https://github.com/Yelp/swagger_spec_validator")
12283 (synopsis "Validation of Swagger specifications")
12284 (description "@code{swagger_spec_validator} provides a library for
12285 validating Swagger API specifications.")
12286 (license license:asl2.0)))
12288 (define-public python2-swagger-spec-validator
12289 (package-with-python2 python-swagger-spec-validator))
12291 (define-public python-apache-libcloud
12293 (name "python-apache-libcloud")
12298 (uri (pypi-uri "apache-libcloud" version))
12301 "0daj3mkzw79v5zin2r1s2wkrz1hplfc16bwj4ss68i5qjq4l2p0j"))))
12302 (build-system python-build-system)
12305 (modify-phases %standard-phases
12306 (add-after 'unpack 'patch-ssh
12307 (lambda* (#:key inputs #:allow-other-keys)
12308 (substitute* "libcloud/compute/ssh.py"
12309 (("'ssh'") (string-append "'" (assoc-ref inputs "openssh")
12312 (add-after 'unpack 'patch-tests
12314 (substitute* "./libcloud/test/test_file_fixtures.py"
12315 ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-923>.
12316 (("def _ascii") "def _raw_data(self, method, url, body, headers):
12317 return (httplib.OK,
12319 {\"test\": \"value\"},
12320 httplib.responses[httplib.OK])
12322 (substitute* "libcloud/test/compute/test_ssh_client.py"
12323 (("class ShellOutSSHClientTests")
12324 "@unittest.skip(\"Guix container doesn't have ssh service\")
12325 class ShellOutSSHClientTests")
12326 ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-924>.
12327 (("'.xf0.x90.x8d.x88'") "b'\\xF0\\x90\\x8D\\x88'")
12328 (("'.xF0', '.x90', '.x8D', '.x88'")
12329 "b'\\xF0', b'\\x90', b'\\x8D', b'\\x88'"))
12331 (add-before 'check 'copy-secret
12333 (copy-file "libcloud/test/secrets.py-dist"
12334 "libcloud/test/secrets.py")
12337 `(("openssh" ,openssh)))
12339 `(("python-paramiko" ,python-paramiko)
12340 ("python-requests" ,python-requests)))
12342 `(("python-lockfile" ,python-lockfile)
12343 ("python-mock" ,python-mock)
12344 ("python-pytest" ,python-pytest)
12345 ("python-pytest-runner" ,python-pytest-runner)
12346 ("python-requests-mock" ,python-requests-mock)))
12347 (home-page "https://libcloud.apache.org/")
12348 (synopsis "Unified Cloud API")
12349 (description "@code{libcloud} is a Python library for interacting with
12350 many of the popular cloud service providers using a unified API.")
12351 (license license:asl2.0)))
12353 (define-public python2-apache-libcloud
12354 (package-with-python2 python-apache-libcloud))
12356 (define-public python-smmap2
12358 (name "python-smmap2")
12363 (uri (pypi-uri "smmap2" version))
12366 "1hvn28p3zvxa98sbi9lrqvv2ps4q284j4jq9a619zw0m7yv0sly7"))))
12367 (build-system python-build-system)
12369 `(("python-nosexcover" ,python-nosexcover)))
12370 (home-page "https://github.com/Byron/smmap")
12371 (synopsis "Python sliding window memory map manager")
12372 (description "@code{smmap2} is a pure Python implementation of a sliding
12373 window memory map manager.")
12374 (license license:bsd-3)))
12376 (define-public python2-smmap2
12377 (package-with-python2 python-smmap2))
12379 (define-public python-regex
12381 (name "python-regex")
12382 (version "2017.06.07")
12385 (uri (pypi-uri "regex" version))
12388 "06r6b7yigikbj3a72whl85r2b64pj1r0ypmw9yalmkm0wnxq8mz4"))))
12389 (build-system python-build-system)
12390 (home-page "https://bitbucket.org/mrabarnett/mrab-regex")
12391 (synopsis "Alternative regular expression module")
12392 (description "This regular expression implementation is backwards-
12393 compatible with the standard @code{re} module, but offers additional
12394 functionality like full case-folding for case-insensitive matches in Unicode.")
12395 (license license:psfl)))
12397 (define-public python2-regex
12398 (package-with-python2 python-regex))
12400 (define-public python2-pyopengl
12402 (name "python2-pyopengl")
12407 (uri (pypi-uri "PyOpenGL" version))
12410 "1byxjj6a8rwzhxhjqlc588zdad2qwxdd7vlam2653ylll31waiwv"))))
12412 `(#:python ,python-2))
12413 (build-system python-build-system)
12414 (home-page "http://pyopengl.sourceforge.net")
12415 (synopsis "Standard OpenGL bindings for Python")
12417 "PyOpenGL is the most common cross platform Python binding to OpenGL and
12418 related APIs. The binding is created using the standard @code{ctypes}
12420 (license license:bsd-3)))
12422 (define-public python2-pyopengl-accelerate
12424 (inherit python2-pyopengl)
12425 (name "python2-pyopengl-accelerate")
12430 (uri (pypi-uri "PyOpenGL-accelerate" version))
12433 "0464c1ifzk0k92lyndikmvzjgnx1y25r7bkkc8pnxm4kp1q4czwj"))))
12434 (synopsis "Acceleration code for PyOpenGL")
12436 "This is the Cython-coded accelerator module for PyOpenGL.")))
12438 (define-public python-rencode
12440 (name "python-rencode")
12445 (uri (pypi-uri "rencode" version))
12448 "0mzwdq1is7kyyr32i5k4iz6g5xxdvmiyc132jnc60p9m6lnwjrpv"))))
12449 (build-system python-build-system)
12452 (modify-phases %standard-phases
12453 (add-before 'check 'delete-bogus-test
12454 ;; This test requires /home/aresch/Downloads, which is not provided by
12455 ;; the build environment.
12457 (delete-file "rencode/t.py")
12459 (native-inputs `(("pkg-config" ,pkg-config)
12460 ("python-cython" ,python-cython)))
12461 (home-page "https://github.com/aresch/rencode")
12462 (synopsis "Serialization of heterogeneous data structures")
12464 "The @code{rencode} module is a data structure serialization library,
12465 similar to @code{bencode} from the BitTorrent project. For complex,
12466 heterogeneous data structures with many small elements, r-encoding stake up
12467 significantly less space than b-encodings. This version of rencode is a
12468 complete rewrite in Cython to attempt to increase the performance over the
12469 pure Python module.")
12470 (license license:bsd-3)))
12472 (define-public python2-rencode
12473 (package-with-python2 python-rencode))
12475 (define-public python-xenon
12477 (name "python-xenon")
12482 (uri (pypi-uri "xenon" version))
12485 "029cbhysg2vr5n4jz8gpg2793f8wkwnqpr1qgv6c1dn685vy31mc"))))
12486 (build-system python-build-system)
12488 `(("python-pyyaml" ,python-pyyaml)
12489 ("python-radon" ,python-radon)
12490 ("python-requests" ,python-requests)
12491 ("python-flake8" ,python-flake8)
12492 ("python-tox" ,python-tox)))
12495 (modify-phases %standard-phases
12496 (add-before 'build 'patch-test-requirements
12498 ;; Remove httpretty dependency for tests.
12499 (substitute* "setup.py"
12500 (("httpretty") ""))
12502 (home-page "https://xenon.readthedocs.org/")
12503 (synopsis "Monitor code metrics for Python on your CI server")
12505 "Xenon is a monitoring tool based on Radon. It monitors code complexity.
12506 Ideally, @code{xenon} is run every time code is committed. Through command
12507 line options, various thresholds can be set for the complexity of code. It
12508 will fail (i.e. it will exit with a non-zero exit code) when any of these
12509 requirements is not met.")
12510 (license license:expat)))
12512 (define-public python2-xenon
12513 (package-with-python2 python-xenon))
12515 (define-public python-pysocks
12517 (name "python-pysocks")
12522 (uri (pypi-uri "PySocks" version))
12525 "0wn6xafwy9c1gamwljw3fyvih5w19qy9xp39zmv8c90ai5ajrr9z"))))
12526 (build-system python-build-system)
12527 (arguments `(#:tests? #f))
12528 (home-page "https://github.com/Anorov/PySocks")
12529 (synopsis "SOCKS client module")
12530 (description "@code{pysocks} is an updated and semi-actively maintained
12531 version of @code{SocksiPy} with bug fixes and extra features.")
12532 (license license:bsd-3)))
12534 (define-public python2-pysocks
12535 (package-with-python2 python-pysocks))
12537 (define-public python-pydiff
12539 (name "python-pydiff")
12544 (uri (pypi-uri "pydiff" version))
12547 "1als83h9w0gab24ipyna6khm390qmpnpkc5jksmdbs2xc8hp2z44"))))
12548 (build-system python-build-system)
12549 (home-page "https://github.com/myint/pydiff")
12550 (synopsis "Library to diff two Python files at the bytecode level")
12552 "@code{pydiff} makes it easy to look for actual code changes while
12553 ignoring formatting changes.")
12554 (license license:expat)))
12556 (define-public python2-pydiff
12557 (package-with-python2 python-pydiff))
12559 (define-public python-tqdm
12561 (name "python-tqdm")
12566 (uri (pypi-uri "tqdm" version))
12569 "1pw0ngm0zn9papdmkwipi3yih5c3di6d0w849bdmrraq4d2d9h2y"))))
12570 (build-system python-build-system)
12572 `(("python-flake8" ,python-flake8)
12573 ("python-nose" ,python-nose)
12574 ("python-coverage" ,python-coverage)))
12575 (home-page "https://github.com/tqdm/tqdm")
12576 (synopsis "Fast, extensible progress meter")
12578 "Make loops show a progress bar on the console by just wrapping any
12579 iterable with @code{|tqdm(iterable)|}. Offers many options to define
12580 design and layout.")
12581 (license (list license:mpl2.0 license:expat))))
12583 (define-public python2-tqdm
12584 (package-with-python2 python-tqdm))
12586 (define-public python-pkginfo
12588 (name "python-pkginfo")
12593 (uri (pypi-uri "pkginfo" version))
12596 "0x6lm17p1ks031mj6pajyp4rkq74vpqq8qwjb7ikgwmkli1day2q"))))
12597 (build-system python-build-system)
12599 ;; The tests are broken upstream.
12602 "https://code.launchpad.net/~tseaver/pkginfo/trunk")
12604 "Query metadatdata from sdists, bdists, and installed packages")
12606 "API to query the distutils metadata written in @file{PKG-INFO} inside a
12607 source distriubtion (an sdist) or a binary distribution (e.g., created by
12608 running bdist_egg). It can also query the EGG-INFO directory of an installed
12609 distribution, and the *.egg-info stored in a \"development checkout\" (e.g,
12610 created by running @code{python setup.py develop}).")
12611 (license license:expat)))
12613 (define-public python2-pkginfo
12614 (package-with-python2 python-pkginfo))
12616 (define-public python-twine
12618 (name "python-twine")
12623 (uri (pypi-uri "twine" version))
12626 "1ay1b6kdq6k4bfbjsvf6ymj41wrgpvinhxndb09355pwhxwmp96a"))))
12627 (build-system python-build-system)
12629 `(("python-tqdm" ,python-tqdm)
12630 ("python-pkginfo" ,python-pkginfo)
12631 ("python-requests" ,python-requests)
12632 ("python-requests-toolbelt" ,python-requests-toolbelt)))
12633 (home-page "https://github.com/pypa/twine")
12634 (synopsis "Collection of utilities for interacting with PyPI")
12636 "@code{twine} currently supports registering projects and uploading
12637 distributions. It authenticates the user over HTTPS, allows them to pre-sign
12638 their files and supports any packaging format (including wheels).")
12639 (license license:asl2.0)))
12641 (define-public python2-twine
12642 (package-with-python2 python-twine))
12644 (define-public python-linecache2
12646 (name "python-linecache2")
12651 (uri (pypi-uri "linecache2" version))
12654 "0z79g3ds5wk2lvnqw0y2jpakjf32h95bd9zmnvp7dnqhf57gy9jb"))))
12655 (build-system python-build-system)
12657 `(;; The tests depend on unittest2, and our version is a bit too old.
12660 `(("python-pbr" ,python-pbr-minimal)))
12662 "https://github.com/testing-cabal/linecache2")
12663 (synopsis "Backports of the linecache module")
12665 "The linecache module allows one to get any line from any file, while
12666 attempting to optimize internally, using a cache, the common case where many
12667 lines are read from a single file.")
12668 (license license:psfl)))
12670 (define-public python2-linecache2
12671 (package-with-python2 python-linecache2))
12673 (define-public python-traceback2
12675 (name "python-traceback2")
12680 (uri (pypi-uri "traceback2" version))
12683 "0c1h3jas1jp1fdbn9z2mrgn3jj0hw1x3yhnkxp7jw34q15xcdb05"))))
12684 (build-system python-build-system)
12686 `(;; python-traceback2 and python-unittest2 depend on one another.
12689 `(("python-pbr" ,python-pbr-minimal)))
12691 `(("python-linecache2" ,python-linecache2)))
12693 "https://github.com/testing-cabal/traceback2")
12694 (synopsis "Backports of the traceback module")
12696 "This module provides a standard interface to extract, format and print
12697 stack traces of Python programs. It exactly mimics the behavior of the Python
12698 interpreter when it prints a stack trace.")
12699 (license license:psfl)))
12701 (define-public python2-traceback2
12702 (package-with-python2 python-traceback2))
12704 (define-public python-ratelimiter
12706 (name "python-ratelimiter")
12711 (uri (pypi-uri "ratelimiter" version))
12714 "1dhz85mj5bqd2mij84ncs6pz32hgidr79hay4aqfmzaa4rbb497p"))))
12715 (build-system python-build-system)
12717 '(#:tests? #f)) ; There are no tests in the pypi archive.
12718 (home-page "https://github.com/RazerM/ratelimiter")
12719 (synopsis "Simple rate limiting object")
12721 "The @code{ratelimiter} module ensures that an operation will not be
12722 executed more than a given number of times during a given period.")
12723 (license license:asl2.0)))
12725 (define-public python2-ratelimiter
12726 (package-with-python2 python-ratelimiter))
12728 (define-public python-dukpy
12730 (name "python-dukpy")
12735 (uri (string-append "https://github.com/kovidgoyal/dukpy/archive/v"
12736 version ".tar.gz"))
12737 (file-name (string-append name "-" version ".tar.gz"))
12740 "0pj39rfwlzivqm5hkrsza7gssg6ggpxlq5ivc8f3h7x5pfgc6y6c"))))
12741 (build-system python-build-system)
12742 (home-page "https://github.com/kovidgoyal/dukpy")
12743 (synopsis "Run JavaScript in python")
12745 "dukpy is a JavaScript runtime environment for Python using the duktape
12746 embeddable JavaScript engine.")
12747 ;; Dukpy is licensed under MIT like the embedded duktape library,
12748 ;; with 'errors.c' as GPL3.
12749 (license (list license:expat license:gpl3))))
12751 (define-public python2-dukpy
12752 (package-with-python2 python-dukpy))
12754 (define-public python-jsonrpclib-pelix
12756 (name "python-jsonrpclib-pelix")
12761 (uri (pypi-uri "jsonrpclib-pelix" version))
12764 "0f83z5zi7w32vprhk1dyc94ir1bh4hdd57bjdbwkq9ykng8qilhl"))))
12765 (build-system python-build-system)
12767 `(#:tests? #f)) ; no tests in PyPI tarball
12768 (home-page "https://github.com/tcalmant/jsonrpclib/")
12769 (synopsis "JSON-RPC 2.0 client library for Python")
12771 "This library implements the JSON-RPC v2.0
12772 specification (backwards-compatible) as a client library for Python. This
12773 version is a fork of jsonrpclib by Josh Marshall, usable with Pelix remote
12775 (license license:asl2.0)))
12777 (define-public python2-jsonrpclib-pelix
12778 (package-with-python2 python-jsonrpclib-pelix))
12780 (define-public python-setuptools-scm-git-archive
12782 (name "python-setuptools-scm-git-archive")
12787 (uri (pypi-uri "setuptools_scm_git_archive" version))
12790 "1nii1sz5jq75ilf18bjnr11l9rz1lvdmyk66bxl7q90qan85yhjj"))))
12791 (build-system python-build-system)
12793 `(("python-pytest" ,python-pytest)))
12795 `(("python-setuptools-scm" ,python-setuptools-scm)))
12796 (home-page "https://github.com/Changaco/setuptools_scm_git_archive/")
12797 (synopsis "Setuptools_scm plugin for git archives")
12799 "The setuptools_scm_git_archive package is a plugin to
12800 setuptools_scm, which supports obtaining versions from git archives that
12801 belong to tagged versions.")
12802 (license license:expat)))
12804 (define-public python2-setuptools-scm-git-archive
12805 (package-with-python2 python-setuptools-scm-git-archive))
12807 (define-public python-pyclipper
12809 (name "python-pyclipper")
12810 (version "1.1.0.post1")
12814 (uri (pypi-uri "pyclipper" version ".zip"))
12817 "0ldbkbnx94an4zzrwb1sxmg6k0jgk4cwmvcdyy8y5k1zslc612wa"))
12818 (modules '((guix build utils)))
12821 ;; This file is generated by Cython.
12822 (delete-file "pyclipper/pyclipper.cpp") #t))))
12823 (build-system python-build-system)
12826 (modify-phases %standard-phases
12827 (add-before 'build 'cythonize-sources
12829 (with-directory-excursion "pyclipper"
12830 (invoke "cython" "--cplus" "pyclipper.pyx")))))))
12832 `(("python-setuptools-scm-git-archive" ,python-setuptools-scm-git-archive)))
12834 `(("python-cython" ,python-cython)
12835 ("python-pytest" ,python-pytest)
12836 ("python-pytest-runner" ,python-pytest-runner)
12837 ("python-unittest2" ,python-unittest2)
12839 (home-page "https://github.com/greginvm/pyclipper")
12840 (synopsis "Wrapper for Angus Johnson's Clipper library")
12842 "Pyclipper is a Cython wrapper for the C++ translation of the
12843 Angus Johnson's polygon clipping Clipper library (ver. 6.4.2).")
12844 (license license:expat)))
12846 (define-public python2-pyclipper
12847 (package-with-python2 python-pyclipper))
12849 (define-public python2-booleanoperations
12851 (name "python2-booleanoperations")
12856 (uri (pypi-uri "booleanOperations" version ".zip"))
12859 "1hw42fazdpvsn77glx96hwsj9l17mvx37sc5707s08y5w6fx16mn"))))
12860 (build-system python-build-system)
12862 `(#:python ,python-2))
12865 ("python2-pytest" ,python2-pytest)
12866 ("python2-pytest-runner" ,python2-pytest-runner)))
12868 `(("python-fonttools" ,python2-fonttools)
12869 ("python-pyclipper" ,python2-pyclipper)
12870 ("python-ufolib" ,python2-ufolib)))
12871 (home-page "https://github.com/typemytype/booleanOperations")
12872 (synopsis "Boolean operations on paths")
12874 "BooleanOperations provides a Python library that enables
12875 boolean operations on paths.")
12876 (license license:expat)))
12878 (define-public python-tempdir
12880 (name "python-tempdir")
12885 (uri (pypi-uri "tempdir" version))
12888 "13msyyxqbicr111a294x7fsqbkl6a31fyrqflx3q7k547gnq15k8"))))
12889 (build-system python-build-system)
12890 (home-page "https://pypi.org/project/tempdir/")
12892 ;; the package has no tests
12894 (synopsis "Python library for managing temporary directories")
12896 "This library manages temporary directories that are automatically
12897 deleted with all their contents when they are no longer needed. It is
12898 particularly convenient for use in tests.")
12899 (license license:expat)))
12901 (define-public python2-tempdir
12902 (package-with-python2 python-tempdir))
12904 (define-public python-activepapers
12906 (name "python-activepapers")
12911 (uri (pypi-uri "ActivePapers.Py" version))
12914 "12wkhjh90ffipjzv10swndp2xv9hd7xrxvg6v0n4n3i411pj4xb8"))))
12915 (build-system python-build-system)
12917 `(#:modules ((ice-9 ftw)
12920 (guix build python-build-system))
12923 (modify-phases %standard-phases
12924 (add-after 'unpack 'delete-python2-code
12926 (for-each delete-file
12927 '("lib/activepapers/builtins2.py"
12928 "lib/activepapers/standardlib2.py"
12929 "lib/activepapers/utility2.py"))))
12932 ;; Deactivate the test cases that download files
12933 (setenv "NO_NETWORK_ACCESS" "1")
12934 ;; For some strange reason, some tests fail if nosetests runs all
12935 ;; test modules in a single execution. They pass if each test
12936 ;; module is run individually.
12937 (for-each (lambda (filename)
12938 (invoke "nosetests"
12939 (string-append "tests/" filename)))
12942 (string-suffix? ".py" filename)))))))))
12944 `(("python-tempdir" ,python-tempdir)
12945 ("python-nose" ,python-nose)))
12947 `(("python-h5py" ,python-h5py)))
12948 (home-page "http://www.activepapers.org/")
12949 (synopsis "Executable papers for scientific computing")
12951 "ActivePapers is a tool for working with executable papers, which
12952 combine data, code, and documentation in single-file packages,
12953 suitable for publication as supplementary material or on repositories
12954 such as figshare or Zenodo.")
12955 (properties `((python2-variant . ,(delay python2-activepapers))))
12956 (license license:bsd-3)))
12958 (define-public python2-activepapers
12959 (let ((base (package-with-python2
12960 (strip-python2-variant python-activepapers))))
12964 (substitute-keyword-arguments (package-arguments base)
12966 `(modify-phases ,phases
12967 (delete 'delete-python2-code)
12968 (add-after 'unpack 'delete-python3-code
12970 (for-each delete-file
12971 '("lib/activepapers/builtins3.py"
12972 "lib/activepapers/standardlib3.py"
12973 "lib/activepapers/utility3.py")))))))))))
12975 (define-public python-semver
12977 (name "python-semver")
12982 (uri (pypi-uri "semver" version))
12985 "0hhgqppchv59rqj0yzi1prdg2nfsywqmjsqy2rycyxm0hvxmbyqz"))))
12986 (build-system python-build-system)
12989 (modify-phases %standard-phases
12990 (add-after 'unpack 'patch-test-requirements
12992 (substitute* "setup.py"
12993 ;; Our Python is new enough.
12994 (("'virtualenv<14\\.0\\.0'") "'virtualenv'"))
12997 `(("python-tox" ,python-tox)
12998 ("python-virtualenv" ,python-virtualenv)))
12999 (home-page "https://github.com/k-bx/python-semver")
13000 (synopsis "Python helper for Semantic Versioning")
13001 (description "This package provides a Python library for
13002 @url{Semantic Versioning, http://semver.org/}.")
13003 (license license:bsd-3)))
13005 (define-public python2-semver
13006 (package-with-python2 python-semver))
13008 (define-public python-pyro4
13010 (name "python-pyro4")
13015 (uri (pypi-uri "Pyro4" version))
13018 "0pzp7c6q3vvkxq0wy9lr6wd5wky40sajz69g697i5rb2q497pvc9"))))
13019 (build-system python-build-system)
13021 `(("python-serpent" ,python-serpent)))
13022 (home-page "https://pyro4.readthedocs.io")
13023 (synopsis "Distributed object middleware for Python")
13025 "Pyro enables you to build applications in which objects can talk to each
13026 other over the network. You can just use normal Python method calls to call
13027 objects on other machines, also known as remote procedure calls (RPC).")
13028 (license license:expat)))
13030 (define-public python2-pyro
13032 (name "python2-pyro")
13037 (uri (pypi-uri "Pyro" version))
13038 (file-name (string-append "Pyro-" version ".tar.gz"))
13041 "0y75wzdqbjy565rpxaxscav4j8xg060sa90lnmb7aypgaf251v8v"))))
13042 (build-system python-build-system)
13044 ;; Pyro is not compatible with Python 3
13045 `(#:python ,python-2
13046 ;; Pyro has no test cases for automatic execution
13048 (home-page "http://pythonhosted.org/Pyro/")
13049 (synopsis "Distributed object manager for Python")
13050 (description "Pyro is a Distributed Object Technology system
13051 written in Python that is designed to be easy to use. It resembles
13052 Java's Remote Method Invocation (RMI). It has less similarity to CORBA,
13053 which is a system and language independent Distributed Object Technology
13054 and has much more to offer than Pyro or RMI. Pyro 3.x is no
13055 longer maintained. New projects should use Pyro4 instead, which
13056 is the new Pyro version that is actively developed.")
13057 (license license:expat)))
13059 (define-public python2-scientific
13061 (name "python2-scientific")
13066 (uri (string-append "https://bitbucket.org/khinsen/"
13067 "scientificpython/downloads/ScientificPython-"
13068 version ".tar.gz"))
13069 (file-name (string-append "ScientificPython-" version ".tar.gz"))
13072 "0fc69zhlsn9d2jvbzyjl9ah53vj598h84nkq230c83ahfvgzx5y3"))))
13073 (build-system python-build-system)
13075 `(("netcdf" ,netcdf)))
13077 `(("python-numpy" ,python2-numpy-1.8)
13078 ("python-pyro" ,python2-pyro)))
13080 ;; ScientificPython is not compatible with Python 3
13081 `(#:python ,python-2
13082 #:tests? #f ; No test suite
13084 (modify-phases %standard-phases
13086 (lambda* (#:key inputs #:allow-other-keys)
13087 (invoke "python" "setup.py" "build"
13088 (string-append "--netcdf_prefix="
13089 (assoc-ref inputs "netcdf"))))))))
13090 (home-page "https://bitbucket.org/khinsen/scientificpython")
13091 (synopsis "Python modules for scientific computing")
13092 (description "ScientificPython is a collection of Python modules that are
13093 useful for scientific computing. Most modules are rather general (Geometry,
13094 physical units, automatic derivatives, ...) whereas others are more
13095 domain-specific (e.g. netCDF and PDB support). The library is currently
13096 not actively maintained and works only with Python 2 and NumPy < 1.9.")
13097 (license license:cecill-c)))
13099 (define-public python2-mmtk
13101 (name "python2-mmtk")
13106 (uri (string-append "https://bitbucket.org/khinsen/"
13107 "mmtk/downloads/MMTK-" version ".tar.gz"))
13108 (file-name (string-append "MMTK-" version ".tar.gz"))
13111 "1d0nnjx4lwsvh8f99vv1r6gi50d93yba0adkz8b4zgv4za4c5862"))))
13112 (build-system python-build-system)
13114 `(("netcdf" ,netcdf)))
13116 `(("python-scientific" ,python2-scientific)
13117 ("python-tkinter" ,python-2 "tk")))
13119 `(#:python ,python-2
13122 (modify-phases %standard-phases
13123 (add-before 'build 'includes-from-scientific
13124 (lambda* (#:key inputs #:allow-other-keys)
13125 (mkdir-p "Include/Scientific")
13128 (assoc-ref inputs "python-scientific")
13129 "/include/python2.7/Scientific")
13130 "Include/Scientific"))))))
13131 (home-page "http://dirac.cnrs-orleans.fr/MMTK")
13132 (synopsis "Python library for molecular simulation")
13133 (description "MMTK is a library for molecular simulations with an emphasis
13134 on biomolecules. It provides widely used methods such as Molecular Dynamics
13135 and normal mode analysis, but also basic routines for implementing new methods
13136 for simulation and analysis. The library is currently not actively maintained
13137 and works only with Python 2 and NumPy < 1.9.")
13138 (license license:cecill-c)))
13140 (define-public python-phonenumbers
13142 (name "python-phonenumbers")
13147 (uri (pypi-uri "phonenumbers" version))
13150 "03fmrgb4r8x3ykmddjs9i3zhs703in8smikj3a6447blqpimwyh1"))))
13151 (build-system python-build-system)
13153 "https://github.com/daviddrysdale/python-phonenumbers")
13155 "Python library for dealing with international phone numbers")
13157 "This package provides a Python port of Google's libphonenumber library.")
13158 (license license:asl2.0)))
13160 (define-public python2-phonenumbers
13161 (package-with-python2 python-phonenumbers))
13163 (define-public python-send2trash
13165 (name "python-send2trash")
13168 (origin (method git-fetch)
13169 ;; Source tarball on PyPI doesn't include tests.
13170 (uri (git-reference
13171 (url "https://github.com/hsoft/send2trash.git")
13173 (file-name (git-file-name name version))
13176 "1c76zldhw2ay7q7r00nnzcampjz9lkqfcbzqpm0iqp5i6bmmv30v"))))
13177 (build-system python-build-system)
13180 (modify-phases %standard-phases
13181 (add-before 'check 'pre-check
13183 (mkdir-p "/tmp/foo")
13184 (setenv "HOME" "/tmp/foo")
13186 (home-page "https://github.com/hsoft/send2trash")
13187 (synopsis "Send files to the user's @file{~/Trash} directory")
13188 (description "This package provides a Python library to send files to the
13189 user's @file{~/Trash} directory.")
13190 (license license:bsd-3)))
13192 (define-public python2-send2trash
13194 (inherit (package-with-python2 python-send2trash))
13196 (substitute-keyword-arguments (package-arguments python-send2trash)
13198 `(modify-phases ,phases
13199 (add-before 'check 'setenv
13201 (setenv "PYTHONPATH"
13202 (string-append (getcwd) ":" (getenv "PYTHONPATH")))
13204 (properties `((python2-variant . ,(delay python-send2trash))))))
13206 (define-public python-yapf
13208 (name "python-yapf")
13213 (uri (pypi-uri "yapf" version))
13216 "0anwby0ydmyzcsgjc5dn1ryddwvii4dq61vck447q0n96npnzfyf"))))
13217 (build-system python-build-system)
13218 (home-page "https://github.com/google/yapf")
13219 (synopsis "Formatter for Python code")
13220 (description "YAPF is a formatter for Python code. It's based off of
13221 @dfn{clang-format}, developed by Daniel Jasper. In essence, the algorithm
13222 takes the code and reformats it to the best formatting that conforms to the
13223 style guide, even if the original code didn't violate the style guide.")
13224 (license license:asl2.0)))
13226 (define-public python2-yapf
13227 (package-with-python2 python-yapf))
13229 (define-public python-gyp
13230 (let ((commit "5e2b3ddde7cda5eb6bc09a5546a76b00e49d888f")
13233 (name "python-gyp")
13234 ;; Google does not release versions,
13235 ;; based on second most recent commit date.
13236 (version (git-version "0.0.0" revision commit))
13239 ;; Google does not release tarballs,
13240 ;; git checkout is needed.
13242 (uri (git-reference
13243 (url "https://chromium.googlesource.com/external/gyp")
13245 (file-name (git-file-name name version))
13248 "0fr7nxcrk292djmxzpcjaphnsd123k31gp8jnd91vwknhq6snmv9"))))
13249 (build-system python-build-system)
13250 (home-page "https://gyp.gsrc.io/")
13251 (synopsis "GYP is a Meta-Build system")
13253 "GYP builds build systems for large, cross platform applications.
13254 It can be used to generate XCode projects, Visual Studio projects, Ninja build
13255 files, and Makefiles.")
13256 (license license:bsd-3))))
13258 (define-public python2-gyp
13259 (package-with-python2 python-gyp))
13261 (define-public python-whatever
13263 (name "python-whatever")
13268 (uri (string-append "https://github.com/Suor/whatever/archive/" version
13272 "1iqvnaf0zpc6b4rvbqq4xy45mszcscyzpzknv8wg6j84pbp22sap"))
13273 (file-name (string-append name "-" version ".tar.gz"))))
13274 (build-system python-build-system)
13277 (modify-phases %standard-phases
13280 (invoke "py.test"))))))
13282 `(("python-pytest" ,python-pytest)))
13283 (home-page "http://github.com/Suor/whatever")
13284 (synopsis "Make anonymous functions by partial application of operators")
13285 (description "@code{whatever} provides an easy way to make anonymous
13286 functions by partial application of operators.")
13287 (license license:bsd-3)))
13289 (define-public python2-whatever
13290 (package-with-python2 python-whatever))
13292 (define-public python-funcy
13294 (name "python-funcy")
13299 (uri (string-append "https://github.com/Suor/funcy/archive/" version
13303 "1fanxivsip29vgarw6dn39xym3q4pbxcpa11plpp548lvxajpahz"))
13304 (file-name (string-append name "-" version ".tar.gz"))))
13305 (build-system python-build-system)
13308 (modify-phases %standard-phases
13311 (invoke "py.test"))))))
13313 `(("python-pytest" ,python-pytest)
13314 ("python-whatever" ,python-whatever)))
13315 (home-page "http://github.com/Suor/funcy")
13316 (synopsis "Functional tools")
13317 (description "@code{funcy} is a library that provides functional tools.
13320 @item merge - Merges collections of the same type
13321 @item walk - Type-preserving map
13322 @item select - Selects a part of a collection
13323 @item take - Takes the first n items of a collection
13324 @item first - Takes the first item of a collection
13325 @item remove - Predicated-removes items of a collection
13326 @item concat - Concatenates two collections
13327 @item flatten - Flattens a collection with subcollections
13328 @item distinct - Returns only distinct items
13329 @item split - Predicated-splits a collection
13330 @item split_at - Splits a collection at a given item
13331 @item group_by - Groups items by group
13332 @item pairwise - Pairs off adjacent items
13333 @item partial - Partially-applies a function
13334 @item curry - Curries a function
13335 @item compose - Composes functions
13336 @item complement - Complements a predicate
13337 @item all_fn - \"all\" with predicate
13339 (license license:bsd-3)))
13341 (define-public python2-funcy
13342 (package-with-python2 python-funcy))
13344 (define-public python-isoweek
13346 (name "python-isoweek")
13351 (uri (pypi-uri "isoweek" version))
13354 "1s7zsf0pab0l9gn6456qadnz5i5h90hafcjwnhx5mq23qjxggwvk"))))
13355 (build-system python-build-system)
13356 (home-page "https://github.com/gisle/isoweek")
13357 (synopsis "Objects representing a week")
13358 (description "The @code{isoweek} module provide the class Week that
13359 implements the week definition of ISO 8601. This standard also defines
13360 a notation for identifying weeks; yyyyWww (where the W is a literal).
13361 Week instances stringify to this form.")
13362 (license license:bsd-3)))
13364 (define-public python2-isoweek
13365 (package-with-python2 python-isoweek))
13367 (define-public python-tokenize-rt
13369 (name "python-tokenize-rt")
13374 (uri (pypi-uri "tokenize-rt" version))
13377 "1yjvbz7rvrz31zjyax1cgy3xhf4wb3j18jwnj4bnl77ca4gliyiw"))))
13378 (build-system python-build-system)
13379 (home-page "https://github.com/asottile/tokenize-rt")
13380 (synopsis "Wrapper around the stdlib tokenize which roundtrips.")
13382 "This Python library is a wrapper around @code{tokenize} from the Python
13383 standard library. It provides two additional tokens @code{ESCAPED_NL} and
13384 @code{UNIMPORTANT_WS}, and a @code{Token} data type. Use @code{src_to_tokens}
13385 and @code{tokens_to_src} to roundtrip.")
13386 (license license:expat)))
13388 (define-public python-future-fstrings
13390 (name "python-future-fstrings")
13395 (uri (pypi-uri "future_fstrings" version))
13398 "0ydxqz2dvns44g55p8ix2x18qkfk3aaz0m0dc70f3g6n8js35h47"))))
13399 (build-system python-build-system)
13401 `(("python-tokenize-rt" ,python-tokenize-rt)))
13402 (home-page "https://github.com/asottile/future-fstrings")
13403 (synopsis "Backport of fstrings to Python < 3.6")
13405 "This package provides a UTF-8 compatible encoding
13406 @code{future_fstrings}, which performs source manipulation. It decodes the
13407 source bytes using the UTF-8 encoding and then rewrites Python 3.6 style
13408 @code{f} strings.")
13409 (license license:expat)))
13411 (define-public python-typing
13413 (name "python-typing")
13418 (uri (pypi-uri "typing" version))
13421 "0ba9acs4awx15bf9v3nrs781msbd2nx826906nj6fqks2bvca9s0"))))
13422 (build-system python-build-system)
13423 (home-page "https://docs.python.org/3/library/typing.html")
13424 (synopsis "Type hints for Python")
13425 (description "This is a backport of the standard library @code{typing}
13426 module to Python versions older than 3.5. Typing defines a standard notation
13427 for Python function and variable type annotations. The notation can be used
13428 for documenting code in a concise, standard format, and it has been designed
13429 to also be used by static and runtime type checkers, static analyzers, IDEs
13431 (license license:psfl)))
13433 (define-public python2-typing
13434 (package-with-python2 python-typing))
13436 (define-public bpython
13443 (uri (pypi-uri "bpython" version))
13446 "0bxhxi5zxdkrf8b4gwn0d363kdz3qnypjwhm1aydki53ph8ca1w9"))))
13447 (build-system python-build-system)
13450 (modify-phases %standard-phases
13451 (add-after 'unpack 'remove-failing-test
13453 ;; Remove failing test. FIXME: make it pass
13454 (delete-file "bpython/test/test_args.py")
13456 (add-after 'wrap 'add-aliases
13457 ;; for symmetry to bpython2, add symlinks bypthon3, bpdb3, etc.
13458 (lambda* (#:key outputs #:allow-other-keys)
13459 (let ((out (assoc-ref outputs "out")))
13462 (symlink old (string-append out "/bin/" new)))
13463 '("bpython" "bpython-curses" "bpython-urwid" "bpdb")
13464 '("bpython3" "bpython3-curses" "bpython3-urwid" "bpdb3")))
13467 `(("python-pygments" ,python-pygments)
13468 ("python-requests" ,python-requests)
13469 ("python-babel" ,python-babel) ; optional, for internationalization
13470 ("python-curtsies" ,python-curtsies) ; >= 0.1.18
13471 ("python-greenlet" ,python-greenlet)
13472 ("python-urwid" ,python-urwid) ; for bpython-urwid only
13473 ("python-six" ,python-six)))
13475 `(("python-sphinx" ,python-sphinx)
13476 ("python-mock" ,python-mock)))
13477 (home-page "https://bpython-interpreter.org/")
13478 (synopsis "Fancy interface to the Python interpreter")
13479 (description "Bpython is a fancy interface to the Python
13480 interpreter. bpython's main features are
13483 @item in-line syntax highlighting,
13484 @item readline-like autocomplete with suggestions displayed as you type,
13485 @item expected parameter list for any Python function,
13486 @item \"rewind\" function to pop the last line of code from memory and
13488 @item send the code you've entered off to a pastebin,
13489 @item save the code you've entered to a file, and
13490 @item auto-indentation.
13492 (license license:expat)))
13494 (define-public bpython2
13495 (let ((base (package-with-python2
13496 (strip-python2-variant bpython))))
13497 (package (inherit base)
13500 `(#:python ,python-2
13502 (modify-phases %standard-phases
13503 (add-after 'unpack 'remove-failing-test
13505 ;; Remove failing test. FIXME: make it pass
13506 (delete-file "bpython/test/test_args.py")
13507 ;; Disable failing test-cases (renaming inhibits they are
13509 (substitute* "bpython/test/test_curtsies_repl.py"
13510 (("^(\\s*def )(test_get_last_word_with_prev_line\\W)" _ a b)
13511 (string-append a "xxx_off_" b))
13512 (("^(\\s*def )(test_complex\\W)" _ a b)
13513 (string-append a "xxx_off_" b)))
13515 (add-before 'build 'rename-scripts
13516 ;; rename the scripts to bypthon2, bpdb2, etc.
13518 (substitute* "setup.py"
13519 (("^(\\s+'bpdb)(\\s+=.*',?)\\s*?$" _ name rest)
13520 (string-append name "2" rest "\n"))
13521 (("^(\\s+'bpython)(-\\S+)?(\\s+=.*',?)\\s*?$" _ name sub rest)
13522 (string-append name "2" (or sub "") rest "\n")))
13525 (define-public python-pyinotify
13527 (name "python-pyinotify")
13531 (uri (pypi-uri "pyinotify" version))
13534 "1x3i9wmzw33fpkis203alygfnrkcmq9w1aydcm887jh6frfqm6cw"))))
13535 (build-system python-build-system)
13536 (arguments `(#:tests? #f)) ;no tests
13537 (home-page "https://github.com/seb-m/pyinotify")
13538 (synopsis "Python library for monitoring inotify events")
13540 "@code{pyinotify} provides a Python interface for monitoring
13541 file system events on Linux.")
13542 (license license:expat)))
13544 (define-public python2-pyinotify
13545 (package-with-python2 python-pyinotify))
13547 ;; Ada parser uses this version.
13548 (define-public python2-quex-0.67.3
13550 (name "python2-quex")
13555 (uri (string-append "mirror://sourceforge/quex/HISTORY/"
13556 (version-major+minor version)
13557 "/quex-" version ".zip"))
13560 "14gv8ll3ipqv4kyc2xiy891nrmjl4ic823zfyx8hassagyclyppw"))))
13561 (build-system python-build-system)
13563 `(("unzip" ,unzip)))
13565 `(#:python ,python-2
13568 (modify-phases %standard-phases
13569 (delete 'configure)
13572 (lambda* (#:key outputs #:allow-other-keys)
13573 (let* ((out (assoc-ref outputs "out"))
13574 (share/quex (string-append out "/share/quex"))
13575 (bin (string-append out "/bin")))
13576 (copy-recursively "." share/quex)
13578 (symlink (string-append share/quex "/quex-exe.py")
13579 (string-append bin "/quex"))
13581 (native-search-paths
13582 (list (search-path-specification
13583 (variable "QUEX_PATH")
13584 (files '("share/quex")))))
13585 (home-page "http://quex.sourceforge.net/")
13586 (synopsis "Lexical analyzer generator in Python")
13587 (description "@code{quex} is a lexical analyzer generator in Python.")
13588 (license license:lgpl2.1+))) ; Non-military
13590 (define-public python2-quex
13591 (package (inherit python2-quex-0.67.3)
13592 (name "python2-quex")
13597 (uri (string-append "mirror://sourceforge/quex/DOWNLOAD/quex-" version ".tar.gz"))
13600 "0svc9nla3b9145d6b7fb9dizx412l3difzqw0ilh9lz52nsixw8j"))
13601 (file-name (string-append name "-" version ".tar.gz"))))))
13603 (define-public python-more-itertools
13605 (name "python-more-itertools")
13610 (uri (pypi-uri "more-itertools" version))
13613 "17h3na0rdh8xq30w4b9pizgkdxmm51896bxw600x84jflg9vaxn4"))))
13614 (build-system python-build-system)
13616 `(,@(if (any (cute string-prefix? <> (or (%current-system)
13617 (%current-target-system)))
13620 (modify-phases %standard-phases
13621 ;; This is required for 32-bit hardware.
13622 ;; TODO: Try to remove this when upgrading.
13623 (add-after 'unpack 'patch-test
13625 (substitute* "more_itertools/tests/test_more.py"
13626 (("10 \\*\\* 10") "9 ** 9"))
13630 `(("python-six" ,python-six-bootstrap)))
13631 (home-page "https://github.com/erikrose/more-itertools")
13632 (synopsis "More routines for operating on iterables, beyond itertools")
13633 (description "Python's built-in @code{itertools} module implements a
13634 number of iterator building blocks inspired by constructs from APL, Haskell,
13635 and SML. @code{more-itertools} includes additional building blocks for
13636 working with iterables.")
13637 (license license:expat)))
13639 (define-public python2-more-itertools
13640 (package-with-python2 python-more-itertools))
13642 (define-public python-latexcodec
13644 (name "python-latexcodec")
13649 (uri (pypi-uri "latexcodec" version))
13652 "0zdd1gf24i83ykadx0y30n3001j43scqr2saql3vckk5c39dj1wn"))))
13653 (build-system python-build-system)
13655 `(("python-six" ,python-six)))
13656 (home-page "https://readthedocs.org/projects/latexcodec/")
13657 (synopsis "Work with LaTeX code in Python")
13658 (description "Lexer and codec to work with LaTeX code in Python.")
13659 (license license:expat)))
13661 (define-public python-pybtex
13663 (name "python-pybtex")
13668 (uri (pypi-uri "pybtex" version))
13671 "00300j8dn5pxq4ndxmfmbmycg2znawkqs49val2x6jlmfiy6r2mg"))))
13672 (build-system python-build-system)
13674 `(("python-nose" ,python-nose)))
13676 `(("python-latexcodec" ,python-latexcodec)
13677 ("python-pyyaml" ,python-pyyaml)
13678 ("python-six" ,python-six)))
13680 `(#:test-target "nosetests"))
13681 (home-page "https://pybtex.org/")
13682 (synopsis "BibTeX-compatible bibliography processor")
13683 (description "Pybtex is a BibTeX-compatible bibliography processor written
13684 in Python. You can simply type pybtex instead of bibtex.")
13685 (license license:expat)))
13687 (define-public python-onetimepass
13689 (name "python-onetimepass")
13694 (uri (pypi-uri "onetimepass" version))
13696 (base32 "09vagxgbq78wvq4xbikmn2hpqqsa2i96kqsmphf7dqynfv0dlsd5"))))
13697 (build-system python-build-system)
13698 (propagated-inputs `(("python-six" ,python-six)))
13699 (home-page "https://github.com/tadeck/onetimepass/")
13700 (synopsis "One-time password library")
13701 (description "Python one-time password library for HMAC-based (HOTP) and
13702 time-based (TOTP) passwords.")
13703 (license license:expat)))
13705 (define-public python-parso
13707 (name "python-parso")
13712 (uri (pypi-uri "parso" version))
13715 "18p89iwcm8mnf380f92g9w0bhx5km8wxp392vvjcq4y1ld1llw1m"))))
13717 `(("python-pytest" ,python-pytest)))
13718 (build-system python-build-system)
13719 (home-page "https://github.com/davidhalter/parso")
13720 (synopsis "Python Parser")
13721 (description "Parso is a Python parser that supports error recovery and
13722 round-trip parsing for different Python versions (in multiple Python versions).
13723 Parso is also able to list multiple syntax errors in your Python file.")
13724 (license license:expat)))
13726 (define-public python2-parso
13727 (package-with-python2 python-parso))
13729 (define-public python-async-generator
13731 (name "python-async-generator")
13736 (uri (pypi-uri "async_generator" version))
13739 "0wc3hidz1q85cja93k5pzybn0fprfnqyrv4qlkdqdzklc5f4dmdp"))))
13740 (build-system python-build-system)
13742 `(("python-pytest" ,python-pytest)))
13743 (home-page "https://github.com/python-trio/async_generator")
13744 (synopsis "Async generators and context managers for Python 3.5+")
13745 (description "@code{async_generator} back-ports Python 3.6's native async
13746 generators and Python 3.7's context managers into Python 3.5.")
13748 (license (list license:expat license:asl2.0))))
13750 (define-public python-async-timeout
13752 (name "python-async-timeout")
13757 (uri (pypi-uri "async-timeout" version))
13760 "0pscbyr840m7fyfc3r8zv9kgkwdcn9f78p7zsrczciwd09m82g0c"))))
13761 (build-system python-build-system)
13762 (home-page "https://github.com/aio-libs/async_timeout/")
13763 (synopsis "Timeout context manager for asyncio programs")
13764 (description "@code{async-timeout} provides a timeout timeout context
13765 manager compatible with @code{asyncio}.")
13766 (license license:asl2.0)))
13768 (define-public python-glob2
13770 (name "python-glob2")
13774 (uri (string-append
13775 "https://github.com/miracle2k/python-glob2/archive/"
13780 "0ja168f0dz4kbz4m06dm0rd3acaypk6hjx2km541pw22y9s40mag"))
13781 (file-name (string-append name "-" version ".tar.gz"))))
13782 (build-system python-build-system)
13783 (home-page "https://github.com/miracle2k/python-glob2/")
13784 (synopsis "Extended Version of the python buildin glob module")
13785 (description "This is an extended version of the Python
13786 @url{http://docs.python.org/library/glob.html, built-in glob module} which
13790 @item The ability to capture the text matched by glob patterns, and return
13791 those matches alongside the file names.
13792 @item A recursive @code{**} globbing syntax, akin for example to the
13793 @code{globstar} option of Bash.
13794 @item The ability to replace the file system functions used, in order to glob
13795 on virtual file systems.
13796 @item Compatible with Python 2 and Python 3 (tested with 3.3).
13799 Glob2 currently based on the glob code from Python 3.3.1.")
13800 (license license:bsd-2)))
13802 (define-public python2-glob2
13803 (package-with-python2 python-glob2))
13805 (define-public python-gipc
13807 (name "python-gipc")
13812 (uri (pypi-uri "gipc" version ".zip"))
13815 "0pd9by719qh882hqs6xpby61sn1x5h98hms5p2p8yqnycrf1s0h2"))))
13816 (build-system python-build-system)
13818 `(("unzip" ,unzip)))
13820 `(("python-gevent" ,python-gevent)))
13821 (home-page "http://gehrcke.de/gipc")
13822 (synopsis "Child process management in the context of gevent")
13823 (description "Usage of Python's multiprocessing package in a
13824 gevent-powered application may raise problems. With @code{gipc},
13825 process-based child processes can safely be created anywhere within a
13826 gevent-powered application.")
13827 (license license:expat)))
13829 (define-public python2-gipc
13830 (package-with-python2 python-gipc))
13832 (define-public python-fusepy
13834 (name "python-fusepy")
13839 (uri (pypi-uri "fusepy" version))
13842 "0v5grm4zyf58hsplwsxfbihddw95lz9w8cy3rpzbyha287swgx8h"))))
13843 (build-system python-build-system)
13846 (modify-phases %standard-phases
13847 (add-before 'build 'set-library-file-name
13848 (lambda* (#:key inputs #:allow-other-keys)
13849 (let ((fuse (assoc-ref inputs "fuse")))
13850 (substitute* "fuse.py"
13851 (("find_library\\('fuse'\\)")
13852 (string-append "'" fuse "/lib/libfuse.so'")))
13856 (home-page "https://github.com/fusepy/fusepy")
13857 (synopsis "Simple ctypes bindings for FUSE")
13858 (description "Python module that provides a simple interface to FUSE and
13859 MacFUSE. The binding is created using the standard @code{ctypes} library.")
13860 (license license:isc)))
13862 (define-public python2-fusepy
13863 (package-with-python2 python-fusepy))
13865 (define-public python2-gdrivefs
13867 (name "python2-gdrivefs")
13872 (uri (pypi-uri "gdrivefs" version))
13875 "0v9sp2cfg4ki3wagkwf3rnfpjhvgf845anz3757il9z95yvvcvb7"))))
13876 (build-system python-build-system)
13878 `(#:python ,python-2
13880 (modify-phases %standard-phases
13881 (add-before 'build 'patch-setup-py
13883 ;; Update requirements from dependency==version
13884 ;; to dependency>=version
13885 (substitute* "gdrivefs/resources/requirements.txt"
13889 `(("python2-gipc" ,python2-gipc)
13890 ("python2-gevent" ,python2-gevent)
13891 ("python2-greenlet" ,python2-greenlet)
13892 ("python2-httplib2" ,python2-httplib2)
13893 ("python2-uritemplate" ,python2-uritemplate)
13894 ("python2-oauth2client" ,python2-oauth2client)
13895 ("python2-six" ,python2-six)))
13897 `(("python2-dateutil" ,python2-dateutil)
13898 ("python2-fusepy" ,python2-fusepy)
13899 ("python2-google-api-client" ,python2-google-api-client)))
13900 (home-page "https://github.com/dsoprea/GDriveFS")
13901 (synopsis "Mount Google Drive as a local file system")
13902 (description "@code{gdrivefs} provides a FUSE wrapper for Google Drive
13903 under Python 2.7.")
13904 (license license:gpl2)))
13906 (define-public pybind11
13912 (uri (git-reference
13913 (url "https://github.com/pybind/pybind11.git")
13914 (commit (string-append "v" version))))
13917 "0pa79ymcasv8br5ifbx7878id5py2jpjac3i20cqxr6gs9l6ivlv"))
13918 (file-name (git-file-name name version))))
13919 (build-system cmake-build-system)
13921 `(("python" ,python)
13922 ("python-pytest" ,python-pytest)))
13924 `(#:test-target "check"))
13925 (home-page "https://github.com/pybind/pybind11/")
13926 (synopsis "Seamless operability between C++11 and Python")
13927 (description "pybind11 is a lightweight header-only library that exposes
13928 C++ types in Python and vice versa, mainly to create Python bindings of
13929 existing C++ code. Its goals and syntax are similar to the excellent
13930 Boost.Python library by David Abrahams: to minimize boilerplate code in
13931 traditional extension modules by inferring type information using compile-time
13933 (license license:expat)))
13935 (define-public python-fasteners
13937 (name "python-fasteners")
13942 (uri (pypi-uri "fasteners" version))
13945 "063y20kx01ihbz2mziapmjxi2cd0dq48jzg587xdsdp07xvpcz22"))))
13946 (build-system python-build-system)
13948 `(("python-monotonic" ,python-monotonic)
13949 ("python-six" ,python-six)
13950 ("python-testtools" ,python-testtools)))
13951 (home-page "https://github.com/harlowja/fasteners")
13952 (synopsis "Python package that provides useful locks")
13954 "This package provides a Python program that provides following locks:
13957 @item Locking decorator
13958 @item Reader-writer locks
13959 @item Inter-process locks
13960 @item Generic helpers
13962 (properties `((python2-variant . ,(delay python2-fasteners))))
13963 (license license:asl2.0)))
13965 (define-public python2-fasteners
13966 (let ((base (package-with-python2 (strip-python2-variant python-fasteners))))
13970 `(("python2-futures" ,python2-futures)
13971 ,@(package-propagated-inputs base))))))
13973 (define-public python-requests-file
13975 (name "python-requests-file")
13980 (uri (pypi-uri "requests-file" version))
13983 "1yp2jaxg3v86pia0q512dg3hz6s9y5vzdivsgrba1kds05ial14g"))))
13984 (build-system python-build-system)
13986 `(("python-requests" ,python-requests)
13987 ("python-six" ,python-six)))
13989 "https://github.com/dashea/requests-file")
13990 (synopsis "File transport adapter for Requests")
13992 "Requests-File is a transport adapter for use with the Requests Python
13993 library to allow local filesystem access via file:// URLs.")
13994 (license license:asl2.0)))
13996 (define-public python2-requests-file
13997 (package-with-python2 python-requests-file))
13999 (define-public python-tldextract
14001 (name "python-tldextract")
14006 (uri (pypi-uri "tldextract" version))
14009 "1d5s8v6kpsgazyahflhji1cfdcf89rv7l7z55v774bhzvcjp2y99"))))
14010 (build-system python-build-system)
14012 `(("python-pytest" ,python-pytest)
14013 ("python-responses" ,python-responses)))
14015 `(("python-idna" ,python-idna)
14016 ("python-requests" ,python-requests)
14017 ("python-requests-file" ,python-requests-file)))
14019 "https://github.com/john-kurkowski/tldextract")
14021 "Separate the TLD from the registered domain and subdomains of a URL")
14023 "TLDExtract accurately separates the TLD from the registered domain and
14024 subdomains of a URL, using the Public Suffix List. By default, this includes
14025 the public ICANN TLDs and their exceptions. It can optionally support the
14026 Public Suffix List's private domains as well.")
14027 (license license:bsd-3)))
14029 (define-public python2-tldextract
14030 (package-with-python2 python-tldextract))
14032 (define-public python-pynamecheap
14034 (name "python-pynamecheap")
14039 (uri (pypi-uri "PyNamecheap" version))
14042 "0wkbwz208j8nfrsmzmclvxg22ymknn0mlz76wbdza9k2bx2zja6l"))))
14043 (build-system python-build-system)
14045 `(("python-requests" ,python-requests)))
14047 "https://github.com/Bemmu/PyNamecheap")
14049 "Namecheap API client in Python")
14051 "PyNamecheap is a Namecheap API client in Python.")
14052 (license license:expat)))
14054 (define-public python2-pynamecheap
14055 (package-with-python2 python-pynamecheap))
14057 (define-public python-dns-lexicon
14059 (name "python-dns-lexicon")
14064 (uri (pypi-uri "dns-lexicon" version))
14067 "0jdn3ns71bsybr7njgsqr9xlxsqh7zh6phn4ld0liazqdn2l5f6m"))))
14068 (build-system python-build-system)
14070 `(#:tests? #f)) ;requires internet access
14072 `(("python-future" ,python-future)
14073 ("python-pynamecheap" ,python-pynamecheap)
14074 ("python-requests" ,python-requests)
14075 ("python-tldextract" ,python-tldextract)
14076 ("python-urllib3" ,python-urllib3)))
14077 (home-page "https://github.com/AnalogJ/lexicon")
14079 "Manipulate DNS records on various DNS providers")
14081 "Lexicon provides a way to manipulate DNS records on multiple DNS
14082 providers in a standardized way. It has a CLI but it can also be used as a
14083 Python library. It was designed to be used in automation, specifically with
14085 (license license:expat)))
14087 (define-public python2-dns-lexicon
14088 (package-with-python2 python-dns-lexicon))
14090 (define-public python-commandlines
14092 (name "python-commandlines")
14097 (uri (pypi-uri "commandlines" version))
14100 "0r7xcr0knv02p4mswa2bng61nn8nbhhrs6kvdnb9bb3hhjvm1dl6"))))
14101 (build-system python-build-system)
14102 (home-page "https://github.com/chrissimpkins/commandlines")
14103 (synopsis "Command line argument to object parsing library")
14105 "@code{Commandlines} is a Python library for command line application
14106 development that supports command line argument parsing, command string
14107 validation testing and application logic.")
14108 (license license:expat)))
14110 ;; Make sure to upgrade python-llvmlite in (gnu packages llvm) together with
14111 ;; python-numba. They have a very unflexible relationship.
14112 (define-public python-numba
14114 (name "python-numba")
14119 (uri (pypi-uri "numba" version))
14122 "1bibvkwga1v8293i9ivl469d8bzgabn3vgr2ig7c1i68v8frsx07"))))
14123 (build-system python-build-system)
14125 `(#:modules ((guix build utils)
14126 (guix build python-build-system)
14131 (modify-phases %standard-phases
14132 (add-after 'unpack 'disable-proprietary-features
14134 (setenv "NUMBA_DISABLE_HSA" "1")
14135 (setenv "NUMBA_DISABLE_CUDA" "1")
14137 (add-after 'unpack 'remove-failing-tests
14139 ;; FIXME: these tests fail for unknown reasons:
14140 ;; test_non_writable_pycache, test_non_creatable_pycache, and
14141 ;; test_frozen (all in numba.tests.test_dispatcher.TestCache).
14142 (substitute* "numba/tests/test_dispatcher.py"
14143 (("def test(_non_writable_pycache)" _ m)
14144 (string-append "def guix_skip" m))
14145 (("def test(_non_creatable_pycache)" _ m)
14146 (string-append "def guix_skip" m))
14147 (("def test(_frozen)" _ m)
14148 (string-append "def guix_skip" m)))
14150 ;; These tests fail because we don't run the tests from the build
14151 ;; directory: test_setup_py_distutils, test_setup_py_setuptools
14152 ;; They ar in numba.tests.test_pycc.TestDistutilsSupport.
14153 (substitute* "numba/tests/test_pycc.py"
14154 (("def test(_setup_py_distutils|_setup_py_setuptools)" _ m)
14155 (string-append "def guix_skip" m)))
14159 (let ((cwd (getcwd)))
14160 (setenv "PYTHONPATH"
14161 (string-append cwd "/build/"
14162 (find (cut string-prefix? "lib" <>)
14163 (scandir (string-append cwd "/build")))
14165 (getenv "PYTHONPATH")))
14166 ;; Something is wrong with the PYTHONPATH when running the
14167 ;; tests from the build directory, as it complains about not being
14168 ;; able to import certain modules.
14169 (with-directory-excursion "/tmp"
14170 (invoke "python3" "-m" "numba.runtests" "-v" "-m")))
14173 `(("python-llvmlite" ,python-llvmlite)
14174 ("python-numpy" ,python-numpy)
14175 ("python-singledispatch" ,python-singledispatch)))
14176 ;; Needed for tests.
14178 `(("python-jinja2" ,python-jinja2)
14179 ("python-pygments" ,python-pygments)))
14180 (home-page "https://numba.pydata.org")
14181 (synopsis "Compile Python code using LLVM")
14182 (description "Numba gives you the power to speed up your applications with
14183 high performance functions written directly in Python. With a few
14184 annotations, array-oriented and math-heavy Python code can be just-in-time
14185 compiled to native machine instructions, similar in performance to C, C++ and
14186 Fortran, without having to switch languages or Python interpreters.
14188 Numba works by generating optimized machine code using the LLVM compiler
14189 infrastructure at import time, runtime, or statically (using the included pycc
14191 (license license:bsd-3)))
14193 (define-public python-anndata
14195 (name "python-anndata")
14200 (uri (pypi-uri "anndata" version))
14203 "1fh461xyyc7pcrjfgd013bdc2alf53r46ss3gfw3431mbb1gappi"))))
14204 (build-system python-build-system)
14206 `(("python-h5py" ,python-h5py)
14207 ("python-natsort" ,python-natsort)
14208 ("python-pandas" ,python-pandas)
14209 ("python-scipy" ,python-scipy)))
14210 (home-page "https://github.com/theislab/anndata")
14211 (synopsis "Annotated data for data analysis pipelines")
14212 (description "Anndata is a package for simple (functional) high-level APIs
14213 for data analysis pipelines. In this context, it provides an efficient,
14214 scalable way of keeping track of data together with learned annotations and
14215 reduces the code overhead typically encountered when using a mostly
14216 object-oriented library such as @code{scikit-learn}.")
14217 (license license:bsd-3)))
14219 (define-public python-dill
14221 (name "python-dill")
14222 (version "0.2.8.2")
14226 (uri (pypi-uri "dill" version))
14229 "1cymzn9fxwdy33h21zkk4gqgzvd25110hh3zdqnvnwa3p52c4kb2"))))
14230 (build-system python-build-system)
14231 ;; FIXME: The check phase fails with "don't know how to make test".
14232 (arguments '(#:tests? #f))
14233 (home-page "https://pypi.org/project/dill")
14234 (synopsis "Serialize all of Python")
14235 (description "Dill extends Python's @code{pickle} module for serializing
14236 and de-serializing Python objects to the majority of the built-in Python
14237 types. Dill provides the user the same interface as the @code{pickle} module,
14238 and also includes some additional features. In addition to pickling Python
14239 objects, @code{dill} provides the ability to save the state of an interpreter
14240 session in a single command. Hence, it would be feasable to save a
14241 interpreter session, close the interpreter, ship the pickled file to another
14242 computer, open a new interpreter, unpickle the session and thus continue from
14243 the saved state of the original interpreter session.")
14244 (license license:bsd-3)))
14246 (define-public python-multiprocess
14248 (name "python-multiprocess")
14249 (version "0.70.6.1")
14253 (uri (pypi-uri "multiprocess" version))
14256 "1ip5caz67b3q0553mr8gm8xwsb8x500jn8ml0gihgyfy52m2ypcq"))))
14257 (build-system python-build-system)
14259 `(("python-dill" ,python-dill)))
14260 (home-page "https://pypi.org/project/multiprocess")
14261 (synopsis "Multiprocessing and multithreading in Python")
14263 "This package is a fork of the multiprocessing Python package, a package
14264 which supports the spawning of processes using the API of the standard
14265 library's @code{threading} module.")
14266 (license license:bsd-3)))
14268 (define-public python-toolz
14270 (name "python-toolz")
14275 (uri (pypi-uri "toolz" version))
14278 "1j9i7fdjnx9dz35fdj5gvgxx6585ja9sxgaiv65if77nlxz0m7wj"))))
14279 (build-system python-build-system)
14280 ;; FIXME: tests cannot be computed: "Can't perform this operation for
14281 ;; unregistered loader type"
14282 (arguments '(#:tests? #f))
14283 (home-page "https://github.com/pytoolz/toolz/")
14284 (synopsis "List processing tools and functional utilities")
14286 "This package provides a set of utility functions for iterators,
14287 functions, and dictionaries.")
14288 (license license:bsd-3)))
14290 (define-public python2-toolz
14291 (package-with-python2 python-toolz))
14293 (define-public python-cytoolz
14295 (name "python-cytoolz")
14296 (version "0.9.0.1")
14300 (uri (pypi-uri "cytoolz" version))
14303 "1r80p88hm3f3r4zpixzr047y5hw4bzy41m4xywnhycda83x0dk44"))))
14304 (build-system python-build-system)
14305 ;; FIXME: tests fail with "module 'cytoolz.curried' has no attribute
14307 (arguments '(#:tests? #f))
14309 `(("python-toolz" ,python-toolz)))
14311 `(("python-cython" ,python-cython)))
14312 (home-page "https://github.com/pytoolz/cytoolz")
14313 (synopsis "High performance functional utilities")
14315 "The cytoolz package implements the same API as provided by toolz. The
14316 main differences are that @code{cytoolz} is faster and cytoolz offers a C API
14317 that is accessible to other projects developed in Cython.")
14318 (license license:bsd-3)))
14320 (define-public python-sortedcontainers
14322 (name "python-sortedcontainers")
14327 (uri (pypi-uri "sortedcontainers" version))
14330 "10hrk2k0hbf9x78vd3f0lj277m1yzfhzzxr0hja718liwb398wk0"))))
14331 (build-system python-build-system)
14333 `(("python-tox" ,python-tox)))
14334 (home-page "http://www.grantjenks.com/docs/sortedcontainers/")
14335 (synopsis "Sorted List, Sorted Dict, Sorted Set")
14337 "This package provides a sorted collections library, written in
14339 (license license:asl2.0)))
14341 (define-public python-cloudpickle
14343 (name "python-cloudpickle")
14348 (uri (pypi-uri "cloudpickle" version))
14351 "1wdw89mlm7fqa3fm3ymskx05jrys66n8m1z1a8s0mss0799ahsgi"))))
14352 (build-system python-build-system)
14353 ;; FIXME: there are 5 errors in 122 tests:
14354 ;; ERROR: test_function_pickle_compat_0_4_0 (tests.cloudpickle_test.CloudPickleTest)
14355 ;; ERROR: test_function_pickle_compat_0_4_1 (tests.cloudpickle_test.CloudPickleTest)
14356 ;; ERROR: test_function_pickle_compat_0_4_0 (tests.cloudpickle_test.Protocol2CloudPickleTest)
14357 ;; ERROR: test_function_pickle_compat_0_4_1 (tests.cloudpickle_test.Protocol2CloudPickleTest)
14358 ;; ERROR: test_temp_file (tests.cloudpickle_file_test.CloudPickleFileTests)
14359 ;; TypeError: cannot serialize '_io.BufferedRandom' object
14360 (arguments '(#:tests? #f))
14362 `(("python-pytest" ,python-pytest)
14363 ("python-mock" ,python-mock)
14364 ("python-tornado" ,python-tornado)))
14365 (home-page "https://github.com/cloudpipe/cloudpickle")
14366 (synopsis "Extended pickling support for Python objects")
14368 "Cloudpickle makes it possible to serialize Python constructs not
14369 supported by the default pickle module from the Python standard library. It
14370 is especially useful for cluster computing where Python expressions are
14371 shipped over the network to execute on remote hosts, possibly close to the
14373 (license license:bsd-3)))
14375 (define-public python2-cloudpickle
14376 (package-with-python2 python-cloudpickle))
14378 (define-public python-locket
14380 (name "python-locket")
14385 (uri (pypi-uri "locket" version))
14388 "1d4z2zngrpqkrfhnd4yhysh66kjn4mblys2l06sh5dix2p0n7vhz"))))
14389 (build-system python-build-system)
14390 (home-page "https://github.com/mwilliamson/locket.py")
14391 (synopsis "File-based locks for Python")
14393 "Locket implements a lock that can be used by multiple processes provided
14394 they use the same path.")
14395 (license license:bsd-2)))
14397 (define-public python2-locket
14398 (package-with-python2 python-locket))
14400 (define-public python-blosc
14402 (name "python-blosc")
14407 (uri (pypi-uri "blosc" version))
14410 "1cm91c6r431yla2mbs4895bgiianjf30dfz14vvv99dslygd65jw"))))
14411 (build-system python-build-system)
14412 ;; FIXME: all tests pass, but then this error is printed:
14413 ;; TypeError: calling <function run at 0x7ffff2568d90> returned None, not a test
14414 (arguments '(#:tests? #f))
14416 `(("python-numpy" ,python-numpy)))
14417 (home-page "https://github.com/blosc/python-blosc")
14418 (synopsis "Python wrapper for the Blosc data compressor library")
14419 (description "Blosc is a high performance compressor optimized for binary
14420 data. It has been designed to transmit data to the processor cache faster
14421 than the traditional, non-compressed, direct memory fetch approach via a
14422 @code{memcpy()} system call.
14424 Blosc works well for compressing numerical arrays that contains data with
14425 relatively low entropy, like sparse data, time series, grids with
14426 regular-spaced values, etc.
14428 This Python package wraps the Blosc library.")
14429 (license license:bsd-3)))
14431 (define-public python2-blosc
14432 (package-with-python2 python-blosc))
14434 (define-public python-partd
14436 (name "python-partd")
14441 (uri (pypi-uri "partd" version))
14444 "0sz6rwlnl4fqq220pyz863cnv0gjdxl4m7lscl71ishl5z0xkmhz"))))
14445 (build-system python-build-system)
14447 `(("python-blosc" ,python-blosc)
14448 ("python-locket" ,python-locket)
14449 ("python-numpy" ,python-numpy)
14450 ("python-pandas" ,python-pandas)
14451 ("python-pyzmq" ,python-pyzmq)
14452 ("python-toolz" ,python-toolz)))
14453 (home-page "https://github.com/dask/partd/")
14454 (synopsis "Appendable key-value storage")
14455 (description "Partd stores key-value pairs. Values are raw bytes. We
14456 append on old values. Partd excels at shuffling operations.")
14457 (license license:bsd-3)))
14459 (define-public python2-partd
14460 (package-with-python2 python-partd))
14462 (define-public python-dask
14464 (name "python-dask")
14469 (uri (pypi-uri "dask" version))
14472 "1xwz8h020ipwav2p5gcq9pskya1cvzd6hjyvd06dvr3w5lxlmym1"))))
14473 (build-system python-build-system)
14474 ;; A single test out of 5000+ fails. This test is marked as xfail when
14475 ;; pytest-xdist is used.
14478 (modify-phases %standard-phases
14479 (add-after 'unpack 'disable-broken-test
14481 (substitute* "dask/tests/test_threaded.py"
14482 (("def test_interrupt\\(\\)" m)
14483 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
14485 (when (which "python2")
14486 ;; This test fails with recent Pandas:
14487 ;; <https://github.com/dask/dask/issues/3794>.
14488 (substitute* "dask/dataframe/tests/test_dataframe.py"
14489 (("def test_info\\(\\)" m)
14490 (string-append "@pytest.mark.skip(reason=\"Disabled by Guix\")\n"
14494 (lambda _ (invoke "pytest" "-vv"))))))
14496 `(("python-cloudpickle" ,python-cloudpickle)
14497 ("python-numpy" ,python-numpy)
14498 ("python-pandas" ,python-pandas)
14499 ("python-partd" ,python-partd)
14500 ("python-toolz" ,python-toolz)
14501 ("python-pyyaml" ,python-pyyaml)))
14503 `(("python-pytest" ,python-pytest)
14504 ("python-pytest-runner" ,python-pytest-runner)))
14505 (home-page "https://github.com/dask/dask/")
14506 (synopsis "Parallel computing with task scheduling")
14508 "Dask is a flexible parallel computing library for analytics. It
14509 consists of two components: dynamic task scheduling optimized for computation,
14510 and large data collections like parallel arrays, dataframes, and lists that
14511 extend common interfaces like NumPy, Pandas, or Python iterators to
14512 larger-than-memory or distributed environments. These parallel collections
14513 run on top of the dynamic task schedulers. ")
14514 (license license:bsd-3)))
14516 (define-public python2-dask
14517 (package-with-python2 python-dask))
14519 (define-public python-ilinkedlist
14521 (name "python-ilinkedlist")
14526 (uri (pypi-uri "ilinkedlist" version))
14529 "0nrw4sr3afldrp7073hvc0rgdz282s0l819jdmj1i6nn05v33h0l"))))
14530 (build-system python-build-system)
14531 (native-inputs `(("python-pytest" ,python-pytest)))
14532 (inputs `(("python" ,python)))
14533 (home-page "https://github.com/luther9/ilinkedlist-py")
14534 (synopsis "Immutable linked list library")
14536 "This is a implementation of immutable linked lists for Python. It
14537 contains @code{nil} (the empty linked list) and a @code{Pair} class for nodes.
14538 Since a linked list is treated as immutable, it is hashable, and its length
14539 can be retrieved in constant time. Some of the terminology is inspired by
14540 LISP. It is possible to create an improper list by creating a @code{Pair}
14541 with a non-list @code{cdr}.")
14542 (license license:gpl3+)))
14544 (define-public python-readlike
14546 (name "python-readlike")
14551 (uri (pypi-uri "readlike" version))
14553 (base32 "027w8fvi50ksl57q0a7kb5zvmq8jxaawnviib1jdqw0p3igvm1j4"))))
14554 (build-system python-build-system)
14555 (home-page "https://github.com/jangler/readlike")
14556 (synopsis "GNU Readline-like line editing module")
14558 "This Python module provides line editing functions similar to the default
14559 Emacs-style ones of GNU Readline. Unlike the Python standard library's
14560 @code{readline} package, this one allows access to those capabilties in settings
14561 outside of a standard command-line interface. It is especially well-suited to
14562 interfacing with Urwid, due to a shared syntax for describing key inputs.
14564 Currently, all stateless Readline commands are implemented. Yanking and history
14565 are not supported.")
14566 (license license:expat)))
14568 (define-public python2-readlike
14569 (package-with-python2 python-readlike))
14571 (define-public python-reparser
14573 (name "python-reparser")
14578 (uri (pypi-uri "ReParser" version))
14580 (base32 "0nniqb69xr0fv7ydlmrr877wyyjb61nlayka7xr08vlxl9caz776"))))
14581 (build-system python-build-system)
14582 (home-page "https://github.com/xmikos/reparser")
14583 (synopsis "Simple lexer/parser for inline markup based on regular expressions")
14585 "This Python library provides a simple lexer/parser for inline markup based
14586 on regular expressions.")
14587 (license license:expat)))
14589 (define-public python2-reparser
14590 (let ((reparser (package-with-python2
14591 (strip-python2-variant python-reparser))))
14592 (package (inherit reparser)
14594 `(("python2-enum34" ,python2-enum34)
14595 ,@(package-propagated-inputs reparser))))))
14597 (define-public python-precis-i18n
14599 (name "python-precis-i18n")
14604 (uri (pypi-uri "precis_i18n" version))
14607 "0gjhvwd8aifx94rl1ag08vlmndyx2q3fkyqb0c4i46x3p2bc2yi2"))))
14608 (build-system python-build-system)
14609 (home-page "https://github.com/byllyfish/precis_i18n")
14610 (synopsis "Implementation of the PRECIS framework")
14612 "This module implements the PRECIS Framework as described in RFC 8264,
14613 RFC 8265 and RFC 8266.")
14614 (license license:expat)))
14616 (define-public python-absl-py
14618 (name "python-absl-py")
14623 (uri (pypi-uri "absl-py" version))
14626 "1mp9lk0b2qa37b7y6ak4lvf6ifw2ylyy6bkf9ik77md3j4xrwlc7"))))
14627 (build-system python-build-system)
14629 `(("python-six" ,python-six)))
14630 (home-page "https://github.com/abseil/abseil-py")
14631 (synopsis "Abseil Python common libraries")
14633 "This package provides the Abseil Python Common Libraries, a collection
14634 of Python libraries for building Python applications.")
14635 (license license:asl2.0)))
14637 (define-public python-astor
14639 (name "python-astor")
14644 (uri (pypi-uri "astor" version))
14647 "13gv6f2xz9i564byp21gcpc0l3w4cs23k1wbcam8kky2ls3hvhwm"))))
14648 (build-system python-build-system)
14649 ;; FIXME: There are two errors and two test failures.
14650 (arguments `(#:tests? #f))
14651 (home-page "https://github.com/berkerpeksag/astor")
14652 (synopsis "Read and write Python ASTs")
14653 (description "Astor is designed to allow easy manipulation of Python
14654 source via the Abstract Syntax Tree.")
14655 (license license:bsd-3)))
14657 (define-public python2-astor
14658 (package-with-python2 python-astor))
14660 (define-public python-grpcio
14662 (name "python-grpcio")
14667 (uri (pypi-uri "grpcio" version))
14670 "0qb9y6j83nxa6d4kc60i8yfgdm7a8ms7b54kncjzf5y7nsxp8rzx"))))
14671 (build-system python-build-system)
14673 `(("python-six" ,python-six)))
14674 (home-page "https://grpc.io")
14675 (synopsis "HTTP/2-based RPC framework")
14676 (description "This package provides a Python library for communicating
14677 with the HTTP/2-based RPC framework gRPC.")
14678 (license license:asl2.0)))
14680 (define-public python-astunparse
14682 (name "python-astunparse")
14687 (uri (pypi-uri "astunparse" version))
14690 "1jhidwyrqn17avqh9xnnm3wd7q7aahaq009cba67g86y6gxicyyj"))))
14691 (build-system python-build-system)
14692 (arguments '(#:tests? #f)) ; there are none
14694 `(("python-six" ,python-six)
14695 ("python-wheel" ,python-wheel)))
14696 (home-page "https://github.com/simonpercivall/astunparse")
14697 (synopsis "AST unparser for Python")
14698 (description "This package provides an AST unparser for Python. It is a
14699 factored out version of @code{unparse} found in the Python source
14701 (license license:bsd-3)))
14703 (define-public python-gast
14705 (name "python-gast")
14710 (uri (pypi-uri "gast" version))
14713 "0c296xm1vz9x4w4inmdl0k8mnc0i9arw94si2i7pglpc461r0s3h"))))
14714 (build-system python-build-system)
14716 `(("python-astunparse" ,python-astunparse)))
14717 (home-page "https://pypi.org/project/gast/")
14718 (synopsis "Generic Python AST that abstracts the underlying Python version")
14720 "GAST provides a compatibility layer between the AST of various Python
14721 versions, as produced by @code{ast.parse} from the standard @code{ast}
14723 (license license:bsd-3)))
14725 (define-public python-wikidata
14727 (name "python-wikidata")
14732 (uri (pypi-uri "Wikidata" version))
14735 "08nlnydddfp1jj0cdmshvld1irzngbp3dij928wqsg9ziklm6mw9"))))
14736 (build-system python-build-system)
14738 `(("python-babel" ,python-babel)))
14739 (home-page "https://github.com/dahlia/wikidata")
14740 (synopsis "Wikidata client library")
14742 "This package provides a Python interface to
14743 @url{https://www.wikidata.org/, Wikidata}.")
14744 (properties '((upstream-name . "Wikidata")))
14745 (license license:gpl3+)))
14747 (define-public python-doctest-ignore-unicode
14749 (name "python-doctest-ignore-unicode")
14754 (uri (pypi-uri "doctest-ignore-unicode" version))
14757 "1m9aa4qnyj21lbq4sbvmv1vcz7zksss4rz37ddf2hxv4hk8b547w"))))
14758 (build-system python-build-system)
14760 `(("python-nose" ,python-nose)))
14761 (home-page "https://github.com/gnublade/doctest-ignore-unicode")
14762 (synopsis "Ignore Unicode literal prefixes in doctests")
14764 "This package adds support for a flag to ignore Unicode literal prefixes
14766 (license license:asl2.0)))
14768 (define-public python-attr
14770 (name "python-attr")
14775 (uri (pypi-uri "attr" version))
14778 "0pbpskvxp5hzdvcaf766ljwpckshir8sf7z6jqji6zyib20594ch"))))
14779 (build-system python-build-system)
14780 (home-page "https://github.com/denis-ryzhkov/attr")
14781 (synopsis "Decorator for attributes of target function or class")
14782 (description "Simple decorator to set attributes of target function or
14783 class in a @acronym{DRY, Don't Repeat Yourself} way.")
14784 (license license:expat)))