1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2013, 2014, 2015, 2016 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 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 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 Leo Famulari <leo@famulari.name>
15 ;;; Copyright © 2015 Ben Woodcroft <donttrustben@gmail.com>
16 ;;; Copyright © 2015, 2016 Erik Edrosa <erik.edrosa@gmail.com>
17 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
18 ;;; Copyright © 2015 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 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 Troy Sankey <sankeytms@gmail.com>
26 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
27 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
28 ;;; Copyright © 2016 David Craven <david@craven.ch>
29 ;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
30 ;;; Copyright © 2016 Stefan Reichoer <stefan@xsteve.at>
31 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
32 ;;; Copyright © 2016 Alex Vong <alexvong1995@gmail.com>
34 ;;; This file is part of GNU Guix.
36 ;;; GNU Guix is free software; you can redistribute it and/or modify it
37 ;;; under the terms of the GNU General Public License as published by
38 ;;; the Free Software Foundation; either version 3 of the License, or (at
39 ;;; your option) any later version.
41 ;;; GNU Guix is distributed in the hope that it will be useful, but
42 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
43 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
44 ;;; GNU General Public License for more details.
46 ;;; You should have received a copy of the GNU General Public License
47 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
49 (define-module (gnu packages python)
50 #:use-module ((guix licenses) #:prefix license:)
51 #:use-module (gnu packages)
52 #:use-module (gnu packages algebra)
53 #:use-module (gnu packages adns)
54 #:use-module (gnu packages attr)
55 #:use-module (gnu packages backup)
56 #:use-module (gnu packages compression)
57 #:use-module (gnu packages databases)
58 #:use-module (gnu packages django)
59 #:use-module (gnu packages file)
60 #:use-module (gnu packages fontutils)
61 #:use-module (gnu packages gcc)
62 #:use-module (gnu packages ghostscript)
63 #:use-module (gnu packages gl)
64 #:use-module (gnu packages glib)
65 #:use-module (gnu packages gstreamer)
66 #:use-module (gnu packages gtk)
67 #:use-module (gnu packages icu4c)
68 #:use-module (gnu packages image)
69 #:use-module (gnu packages imagemagick)
70 #:use-module (gnu packages libevent)
71 #:use-module (gnu packages libffi)
72 #:use-module (gnu packages linux)
73 #:use-module (gnu packages maths)
74 #:use-module (gnu packages multiprecision)
75 #:use-module (gnu packages networking)
76 #:use-module (gnu packages ncurses)
77 #:use-module (gnu packages openstack)
78 #:use-module (gnu packages password-utils)
79 #:use-module (gnu packages pcre)
80 #:use-module (gnu packages perl)
81 #:use-module (gnu packages pkg-config)
82 #:use-module (gnu packages readline)
83 #:use-module (gnu packages sdl)
84 #:use-module (gnu packages statistics)
85 #:use-module (gnu packages tex)
86 #:use-module (gnu packages texinfo)
87 #:use-module (gnu packages tls)
88 #:use-module (gnu packages version-control)
89 #:use-module (gnu packages web)
90 #:use-module (gnu packages base)
91 #:use-module (gnu packages xml)
92 #:use-module (gnu packages xorg)
93 #:use-module (gnu packages xdisorg)
94 #:use-module (gnu packages zip)
95 #:use-module (gnu packages tcl)
96 #:use-module (gnu packages bdw-gc)
97 #:use-module (guix packages)
98 #:use-module (guix download)
99 #:use-module (guix git-download)
100 #:use-module (guix utils)
101 #:use-module (guix build-system gnu)
102 #:use-module (guix build-system cmake)
103 #:use-module (guix build-system python)
104 #:use-module (guix build-system trivial)
105 #:use-module (srfi srfi-1))
107 (define-public python-2.7
114 (uri (string-append "https://www.python.org/ftp/python/"
115 version "/Python-" version ".tar.xz"))
118 "0iiz844riiznsyhhyy962710pz228gmhv8qi3yk4w4jhmx2lqawn"))
119 (patches (search-patches "python-2.7-search-paths.patch"
120 "python-2-deterministic-build-info.patch"
121 "python-2.7-source-date-epoch.patch"))
122 (modules '((guix build utils)))
123 ;; suboptimal to delete failing tests here, but if we delete them in the
124 ;; arguments then we need to make sure to strip out that phase when it
125 ;; gets inherited by python and python-minimal.
128 (for-each delete-file
129 '("Lib/test/test_compileall.py"
130 "Lib/test/test_distutils.py"
131 "Lib/test/test_import.py"
132 "Lib/test/test_shutil.py"
133 "Lib/test/test_socket.py"
134 "Lib/test/test_subprocess.py"))
137 "tk")) ;tkinter; adds 50 MiB to the closure
138 (build-system gnu-build-system)
142 ;; test_compileall test_distutils test_import test_shutil test_socket
145 ;; test_aepack test_al test_applesingle test_bsddb test_bsddb185
146 ;; test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk
147 ;; test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses
148 ;; test_dl test_gdb test_gl test_imageop test_imgfile test_ioctl
149 ;; test_kqueue test_linuxaudiodev test_macos test_macostools
150 ;; test_msilib test_ossaudiodev test_scriptpackages test_smtpnet
151 ;; test_socketserver test_startfile test_sunaudiodev test_timeout
152 ;; test_tk test_ttk_guionly test_urllib2net test_urllibnet
153 ;; test_winreg test_winsound test_zipfile64
154 ;; 4 skips unexpected on linux2:
155 ;; test_bsddb test_bsddb3 test_gdb test_ioctl
158 (list "--enable-shared" ;allow embedding
159 "--with-system-ffi" ;build ctypes
160 (string-append "LDFLAGS=-Wl,-rpath="
161 (assoc-ref %outputs "out") "/lib"))
163 #:modules ((ice-9 ftw) (ice-9 match)
164 (guix build utils) (guix build gnu-build-system))
166 (modify-phases %standard-phases
168 'configure 'patch-lib-shells
170 ;; Filter for existing files, since some may not exist in all
171 ;; versions of python that are built with this recipe.
172 (substitute* (filter file-exists?
173 '("Lib/subprocess.py"
175 "Lib/distutils/tests/test_spawn.py"
176 "Lib/test/test_subprocess.py"))
177 (("/bin/sh") (which "sh")))
179 ;; Use zero as the timestamp in .pyc files so that builds are
180 ;; deterministic. TODO: Remove it when this variable is set in
181 ;; gnu-build-system.scm.
182 (setenv "SOURCE_DATE_EPOCH" "1")
184 (add-before 'configure 'do-not-record-configure-flags
185 (lambda* (#:key configure-flags #:allow-other-keys)
186 ;; Remove configure flags from the installed '_sysconfigdata.py'
187 ;; and 'Makefile' so we don't end up keeping references to the
190 ;; Preserve at least '--with-system-ffi' since otherwise the
191 ;; thing tries to build libffi, fails, and we end up with a
192 ;; Python that lacks ctypes.
193 (substitute* "configure"
194 (("^CONFIG_ARGS=.*$")
195 (format #f "CONFIG_ARGS='~a'\n"
196 (if (member "--with-system-ffi" configure-flags)
203 ;; 'Lib/test/test_site.py' needs a valid $HOME
204 (setenv "HOME" (getcwd))
205 ,@(if (string-prefix? "mips64el" (%current-system))
207 ;; XXX: The following test fails on mips64el.
208 '((false-if-exception
209 (delete-file "Lib/test/test_ctypes.py")))
214 'unpack 'set-source-file-times-to-1980
215 ;; XXX One of the tests uses a ZIP library to pack up some of the
216 ;; source tree, and fails with "ZIP does not support timestamps
217 ;; before 1980". Work around this by setting the file times in the
218 ;; source tree to sometime in early 1980.
220 (let ((circa-1980 (* 10 366 24 60 60)))
221 (ftw "." (lambda (file stat flag)
222 (utime file circa-1980 circa-1980)
225 (add-after 'install 'remove-tests
226 ;; Remove 25 MiB of unneeded unit tests. Keep test_support.*
227 ;; because these files are used by some libraries out there.
228 (lambda* (#:key outputs #:allow-other-keys)
229 (let ((out (assoc-ref outputs "out")))
230 (match (scandir (string-append out "/lib")
232 (string-prefix? "python" name)))
234 (let ((testdir (string-append out "/lib/" pythonX.Y
236 (with-directory-excursion testdir
237 (for-each delete-file-recursively
243 (string-prefix? "test_support."
245 (call-with-output-file "__init__.py" (const #t))
247 (add-before 'strip 'make-libraries-writable
248 (lambda* (#:key outputs #:allow-other-keys)
249 ;; Make .so files writable so they can be stripped.
250 (let ((out (assoc-ref outputs "out")))
251 (for-each (lambda (file)
253 (find-files (string-append out "/lib")
256 (add-after 'install 'move-tk-inter
257 (lambda* (#:key outputs #:allow-other-keys)
258 ;; When Tkinter support is built move it to a separate output so
259 ;; that the main output doesn't contain a reference to Tcl/Tk.
260 (let ((out (assoc-ref outputs "out"))
261 (tk (assoc-ref outputs "tk")))
263 (match (find-files out "tkinter.*\\.so")
265 ;; The .so is in OUT/lib/pythonX.Y/lib-dynload, but we
266 ;; want it under TK/lib/pythonX.Y/site-packages.
267 (let* ((len (string-length out))
268 (target (string-append
271 (dirname (dirname tkinter.so))
274 (install-file tkinter.so target)
275 (delete-file tkinter.so)))))
280 ("libffi" ,libffi) ; for ctypes
281 ("sqlite" ,sqlite) ; for sqlite extension
283 ("readline" ,readline)
286 ("tk" ,tk))) ; for tkinter
288 `(("pkg-config" ,pkg-config)))
290 (list (search-path-specification
291 (variable "PYTHONPATH")
292 (files '("lib/python2.7/site-packages")))))
293 (home-page "http://python.org")
294 (synopsis "High-level, dynamically-typed programming language")
296 "Python is a remarkably powerful dynamic programming language that
297 is used in a wide variety of application domains. Some of its key
298 distinguishing features include: clear, readable syntax; strong
299 introspection capabilities; intuitive object orientation; natural
300 expression of procedural code; full modularity, supporting hierarchical
301 packages; exception-based error handling; and very high level dynamic
303 (license license:psfl)))
305 ;; Current 2.x version.
306 (define-public python-2 python-2.7)
308 (define-public python-3.4
309 (package (inherit python-2)
313 (uri (string-append "https://www.python.org/ftp/python/"
314 version "/Python-" version ".tar.xz"))
315 (patches (search-patches
316 "python-fix-tests.patch"
317 ;; XXX Try removing this patch for python > 3.4.3
318 "python-disable-ssl-test.patch"
319 "python-3-deterministic-build-info.patch"
320 "python-3-search-paths.patch"))
321 (patch-flags '("-p0"))
324 "1f4nm4z08sy0kqwisvv95l02crv6dyysdmx44p1mz3bn6csrdcxm"))))
325 (arguments (substitute-keyword-arguments (package-arguments python-2)
328 (list (search-path-specification
329 (variable "PYTHONPATH")
330 (files (list (string-append "lib/python"
331 (version-major+minor version)
332 "/site-packages"))))))))
334 ;; Current 3.x version.
335 (define-public python-3 python-3.4)
337 ;; Current major version.
338 (define-public python python-3)
340 ;; Minimal variants of Python, mostly used to break the cycle between Tk and
341 ;; Python (Tk -> libxcb -> Python.)
343 (define-public python2-minimal
344 (package (inherit python-2)
345 (name "python-minimal")
348 (substitute-keyword-arguments (package-arguments python-2)
349 ((#:configure-flags cf)
350 `(append ,cf '("--without-system-ffi")))))
351 (inputs '()))) ;none of the optional dependencies
353 (define-public python-minimal
354 (package (inherit python)
355 (name "python-minimal")
358 (substitute-keyword-arguments (package-arguments python)
359 ((#:configure-flags cf)
360 `(append ,cf '("--without-system-ffi")))))
362 ;; OpenSSL is a mandatory dependency of Python 3.x, for urllib;
363 ;; zlib is required by 'zipimport', used by pip.
364 (inputs `(("openssl" ,openssl)
367 (define* (wrap-python3 python
369 (name (string-append (package-name python) "-wrapper")))
370 (package (inherit python)
373 (build-system trivial-build-system)
375 (propagated-inputs `(("python" ,python)))
377 `(#:modules ((guix build utils))
380 (use-modules (guix build utils))
381 (let ((bin (string-append (assoc-ref %outputs "out") "/bin"))
382 (python (string-append (assoc-ref %build-inputs "python") "/bin/")))
386 (symlink (string-append python old)
387 (string-append bin "/" new)))
388 '("python3" "pydoc3" "idle3")
389 '("python" "pydoc" "idle"))))))
390 (synopsis "Wrapper for the Python 3 commands")
392 "This package provides wrappers for the commands of Python@tie{}3.x such
393 that they can be invoked under their usual name---e.g., @command{python}
394 instead of @command{python3}.")))
396 (define-public python-wrapper (wrap-python3 python))
397 (define-public python-minimal-wrapper (wrap-python3 python-minimal))
399 (define-public python-psutil
401 (name "python-psutil")
406 (uri (pypi-uri "psutil" version))
409 "1w4r09fvn6kd80m5mx4ws1wz100brkaq6hzzpwrns8cgjzjpl6c6"))))
410 (build-system python-build-system)
412 `(("python-setuptools" ,python-setuptools)))
413 (home-page "https://www.github.com/giampaolo/psutil")
414 (synopsis "Library for retrieving information on running processes")
416 "psutil (Python system and process utilities) is a library for retrieving
417 information on running processes and system utilization (CPU, memory, disks,
418 network) in Python. It is useful mainly for system monitoring, profiling and
419 limiting process resources and management of running processes. It implements
420 many functionalities offered by command line tools such as: ps, top, lsof,
421 netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
422 pidof, tty, taskset, pmap.")
423 (license license:bsd-3)))
425 (define-public python2-psutil
426 (package-with-python2 python-psutil))
428 (define-public python-passlib
430 (name "python-passlib")
435 (uri (pypi-uri "passlib" version))
438 "1z27wdxs5rj5xhhqfzvzn3yg682irkxw6dcs5jj7mcf97psk8gd8"))))
439 (build-system python-build-system)
441 `(("python-nose" ,python-nose)
442 ("python-setuptools" ,python-setuptools)))
444 `(("python-py-bcrypt" ,python-py-bcrypt)))
448 'check 'set-PYTHON_EGG_CACHE
449 ;; some tests require access to "$HOME/.cython"
450 (lambda* _ (setenv "PYTHON_EGG_CACHE" "/tmp"))
452 (home-page "https://bitbucket.org/ecollins/passlib")
454 "Comprehensive password hashing framework")
456 "Passlib is a password hashing library for Python 2 & 3, which provides
457 cross-platform implementations of over 30 password hashing algorithms, as well
458 as a framework for managing existing password hashes. It's designed to be
459 useful for a wide range of tasks, from verifying a hash found in /etc/shadow,
460 to providing full-strength password hashing for multi-user application.")
461 (license license:bsd-3)))
463 (define-public python2-passlib
464 (package-with-python2 python-passlib))
466 (define-public python-py-bcrypt
468 (name "python-py-bcrypt")
474 "https://pypi.python.org/packages/source/p/py-bcrypt/py-bcrypt-"
479 "0y6smdggwi5s72v6p1nn53dg6w05hna3d264cq6kas0lap73p8az"))))
480 (build-system python-build-system)
482 `(("python-setuptools" ,python-setuptools)))
483 (home-page "https://code.google.com/p/py-bcrypt")
485 "Bcrypt password hashing and key derivation")
487 "A python wrapper of OpenBSD's Blowfish password hashing code. This
488 system hashes passwords using a version of Bruce Schneier's Blowfish block
489 cipher with modifications designed to raise the cost of off-line password
490 cracking and frustrate fast hardware implementation. The computation cost of
491 the algorithm is parametised, so it can be increased as computers get faster.
492 The intent is to make a compromise of a password database less likely to
493 result in an attacker gaining knowledge of the plaintext passwords (e.g. using
495 ;; "sha2.c" is under BSD-3;
496 ;; "blowfish.c" and "bcrypt.c" are under BSD-4;
497 ;; the rest is under ISC.
498 (license (list license:isc license:bsd-3 license:bsd-4))))
500 (define-public python2-py-bcrypt
501 (package-with-python2 python-py-bcrypt))
504 (define-public python-paramiko
506 (name "python-paramiko")
511 (uri (pypi-uri "paramiko" version))
514 "14k8z7ndc3zk5xivnm4d8lncchx475ll5izpf8vmfbq7rp9yp5rj"))))
515 (build-system python-build-system)
517 `(("python-setuptools" ,python-setuptools)))
519 `(("python-pycrypto" ,python-pycrypto)))
521 `(("python-ecdsa" ,python-ecdsa)))
522 (home-page "http://www.paramiko.org/")
523 (synopsis "SSHv2 protocol library")
524 (description "Paramiko is a python implementation of the SSHv2 protocol,
525 providing both client and server functionality. While it leverages a Python C
526 extension for low level cryptography (PyCrypto), Paramiko itself is a pure
527 Python interface around SSH networking concepts.")
528 (license license:lgpl2.1+)))
530 (define-public python2-paramiko
531 (package-with-python2 python-paramiko))
534 (define-public python-httplib2
536 (name "python-httplib2")
541 (uri (pypi-uri "httplib2" version))
544 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
545 (build-system python-build-system)
547 `(("python-setuptools" ,python-setuptools)))
548 (home-page "https://github.com/jcgregorio/httplib2")
549 (synopsis "Comprehensive HTTP client library")
551 "A comprehensive HTTP client library supporting many features left out of
552 other HTTP libraries.")
553 (license license:expat)))
555 (define-public python2-httplib2
556 (package-with-python2 python-httplib2))
558 (define-public python-ecdsa
560 (name "python-ecdsa")
566 "https://pypi.python.org/packages/source/e/ecdsa/ecdsa-"
571 "1yj31j0asmrx4an9xvsaj2icdmzy6pw0glfpqrrkrphwdpi1xkv4"))))
572 (build-system python-build-system)
574 `(("python-setuptools" ,python-setuptools)))
576 `(("openssl" ,openssl)))
578 "http://github.com/warner/python-ecdsa")
580 "ECDSA cryptographic signature library (pure python)")
582 "This is an easy-to-use implementation of ECDSA cryptography (Elliptic
583 Curve Digital Signature Algorithm), implemented purely in Python. With this
584 library, you can quickly create keypairs (signing key and verifying key), sign
585 messages, and verify the signatures. The keys and signatures are very short,
586 making them easy to handle and incorporate into other protocols.")
587 (license license:expat)))
589 (define-public python2-ecdsa
590 (package-with-python2 python-ecdsa))
592 (define-public python-ccm
599 (uri (pypi-uri "ccm" version))
602 "177dfxsmk3k4cih6fh6v8d91bh4nqx7ns6pc07w7m7i3cvdx3c8n"))))
603 (build-system python-build-system)
605 `(("python-setuptools" ,python-setuptools)))
607 `(("python-pyyaml" ,python-pyyaml)
608 ("python-six" ,python-six)))
609 (home-page "https://github.com/pcmanus/ccm")
610 (synopsis "Cassandra Cluster Manager")
611 (description "A script/library to create, launch and remove an Apache
612 Cassandra cluster on localhost.")
613 (license license:asl2.0)))
615 (define-public python2-ccm
616 (package-with-python2 python-ccm))
618 (define-public python-pytz
625 (uri (pypi-uri "pytz" version ".tar.bz2"))
628 "1mjmrkk4vc5xzppw7fm0pli1nnbj57cvqv7jjv5whcmccyhxz4y1"))))
629 (build-system python-build-system)
630 (arguments `(#:tests? #f)) ; no test target
631 (home-page "http://pythonhosted.org/pytz")
632 (synopsis "Python timezone library")
634 "This library allows accurate and cross platform timezone calculations
635 using Python 2.4 or higher and provides access to the Olson timezone database.")
636 (license license:expat)))
638 (define-public python2-pytz
639 (package-with-python2 python-pytz))
642 (define-public python-babel
644 (name "python-babel")
649 (uri (pypi-uri "Babel" version))
652 "0k43pi0p1dwpds2w0km3fw92wixzxv2vw7p09capxmjz5cfh23lw"))))
653 (build-system python-build-system)
655 `(("python-pytz" ,python-pytz)
656 ("python-setuptools" ,python-setuptools)))
657 (arguments `(#:tests? #f)) ; no test target
658 (home-page "http://babel.pocoo.org/")
660 "Tools for internationalizing Python applications")
662 "Babel is composed of two major parts:
663 - tools to build and work with gettext message catalogs
664 - a Python interface to the CLDR (Common Locale Data Repository), providing
665 access to various locale display names, localized number and date formatting,
667 (license license:bsd-3)))
669 (define-public python2-babel
670 (package-with-python2 python-babel))
672 (define-public python2-backport-ssl-match-hostname
674 (name "python2-backport-ssl-match-hostname")
680 "https://pypi.python.org/packages/source/b/"
681 "backports.ssl_match_hostname/backports.ssl_match_hostname-"
685 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
686 (build-system python-build-system)
689 #:tests? #f)) ; no test target
691 `(("python2-setuptools" ,python2-setuptools)))
692 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
693 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
695 "This backport brings the ssl.match_hostname() function to users of
696 earlier versions of Python. The function checks the hostname in the
697 certificate returned by the server to which a connection has been established,
698 and verifies that it matches the intended target hostname.")
699 (license license:psfl)))
701 (define-public python-h5py
708 (uri (pypi-uri "h5py" version))
711 "0df46dg7i7xfking9lp221bfm8dbl974yvlrbi1w7r6m61ac7bxj"))))
712 (build-system python-build-system)
714 `(#:tests? #f ; no test target
716 (modify-phases %standard-phases
717 (add-after 'unpack 'fix-hdf5-paths
718 (lambda* (#:key inputs #:allow-other-keys)
719 (let ((prefix (assoc-ref inputs "hdf5")))
720 (substitute* "setup_build.py"
721 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
722 (string-append "['" prefix "/lib" "']"))
723 (("'/opt/local/include', '/usr/local/include'")
724 (string-append "'" prefix "/include" "'")))
725 (substitute* "setup_configure.py"
726 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
727 (string-append "['" prefix "/lib" "']")))
730 `(("python-numpy" ,python-numpy)))
733 ("python-six" ,python-six)))
735 `(("python-cython" ,python-cython)
736 ("python-pkgconfig" ,python-pkgconfig)))
737 (home-page "http://www.h5py.org/")
738 (synopsis "Read and write HDF5 files from Python")
740 "The h5py package provides both a high- and low-level interface to the
741 HDF5 library from Python. The low-level interface is intended to be a
742 complete wrapping of the HDF5 API, while the high-level component supports
743 access to HDF5 files, datasets and groups using established Python and NumPy
745 (license license:bsd-3)
746 (properties `((python2-variant . ,(delay python2-h5py))))))
748 (define-public python2-h5py
749 (package-with-python2 (strip-python2-variant python-h5py)))
751 (define-public python-lockfile
753 (name "python-lockfile")
758 (uri (string-append "https://pypi.python.org/packages/source/l/lockfile/"
759 "lockfile-" version ".tar.gz"))
762 "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba"))))
763 (build-system python-build-system)
764 (arguments '(#:test-target "check"))
766 `(("python-pbr" ,python-pbr)))
767 (home-page "https://launchpad.net/pylockfile")
768 (synopsis "Platform-independent file locking module")
770 "The lockfile package exports a LockFile class which provides a simple
771 API for locking files.")
772 (license license:expat)
773 (properties `((python2-variant . ,(delay python2-lockfile))))))
775 (define-public python2-lockfile
776 (let ((base (package-with-python2 (strip-python2-variant python-lockfile))))
779 (native-inputs `(("python2-setuptools" ,python2-setuptools)
780 ,@(package-native-inputs base))))))
782 (define-public python-mock
789 (uri (string-append "https://pypi.python.org/packages/source/m/mock/"
790 "mock-" version ".tar.gz"))
793 "0kzlsbki6q0awf89rc287f3aj8x431lrajf160a70z0ikhnxsfdq"))))
794 (build-system python-build-system)
795 (arguments '(#:test-target "check"))
796 (home-page "http://code.google.com/p/mock/")
797 (synopsis "Python mocking and patching library for testing")
799 "Mock is a library for testing in Python. It allows you to replace parts
800 of your system under test with mock objects and make assertions about how they
802 (license license:expat)))
804 (define-public python2-mock
805 (package-with-python2 python-mock))
808 (define-public python-setuptools
810 (name "python-setuptools")
815 (uri (string-append "https://pypi.python.org/packages/source/s/setuptools/setuptools-"
819 "0kc7rbav00ks6iaw14p38y81q12fx0lpkhgf5m97xc04f5r318ig"))))
820 (build-system python-build-system)
821 ;; FIXME: Tests require pytest, which itself relies on setuptools.
822 ;; One could bootstrap with an internal untested setuptools.
825 (home-page "https://pypi.python.org/pypi/setuptools")
827 "Library designed to facilitate packaging Python projects")
829 "Setuptools is a fully-featured, stable library designed to facilitate
830 packaging Python projects, where packaging includes:
831 Python package and module definitions,
832 distribution package metadata,
834 project installation,
835 platform-specific details,
837 (license license:psfl)))
839 (define-public python2-setuptools
840 (package-with-python2 python-setuptools))
843 (define-public python-pycrypto
845 (name "python-pycrypto")
850 (uri (string-append "https://pypi.python.org/packages/source/p/"
851 "pycrypto/pycrypto-" version ".tar.gz"))
854 "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj"))))
855 (build-system python-build-system)
857 `(("python-setuptools" ,python-setuptools)))
864 'build 'set-build-env
865 ;; pycrypto runs an autoconf configure script behind the scenes
867 (setenv "CONFIG_SHELL" (which "bash")))
869 (home-page "http://www.pycrypto.org/")
870 (synopsis "Cryptographic modules for Python")
872 "Pycrypto is a collection of both secure hash functions (such as SHA256
873 and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal,
874 etc.). The package is structured to make adding new modules easy.")
875 (license license:public-domain)))
877 (define-public python2-pycrypto
878 (let ((pycrypto (package-with-python2 python-pycrypto)))
879 (package (inherit pycrypto)
881 `(("python" ,python-2)
884 (package-inputs pycrypto)))))))
886 (define-public python-keyring
888 (name "python-keyring")
893 (uri (pypi-uri "keyring" version))
896 "0482rmi2x6p78wl2kz8qzyq21xz1sbbfwnv5x7dggar4vkwxhzfx"))))
897 (build-system python-build-system)
899 `(("python-setuptools-scm" ,python-setuptools-scm)))
901 `(("python-pycrypto" ,python-pycrypto)))
903 `(#:tests? #f)) ;TODO: tests require pytest
904 (home-page "https://github.com/jaraco/keyring")
905 (synopsis "Store and access your passwords safely")
907 "The Python keyring lib provides a easy way to access the system keyring
908 service from python. It can be used in any application that needs safe
910 ;; "MIT" and PSF dual license
911 (license license:x11)
912 (properties `((python2-variant . ,(delay python2-keyring))))))
914 (define-public python2-keyring
915 (let ((base (package-with-python2 (strip-python2-variant python-keyring))))
918 (native-inputs `(("python2-setuptools" ,python2-setuptools)
919 ,@(package-native-inputs base))))))
921 (define-public python-six
928 (uri (pypi-uri "six" version))
931 "0snmb8xffb3vsma0z67i0h0w2g2dy0p3gsgh9gi4i0kgc5l8spqh"))))
932 (build-system python-build-system)
934 `(("python-setuptools" ,python-setuptools)))
935 (home-page "http://pypi.python.org/pypi/six/")
936 (synopsis "Python 2 and 3 compatibility utilities")
938 "Six is a Python 2 and 3 compatibility library. It provides utility
939 functions for smoothing over the differences between the Python versions with
940 the goal of writing Python code that is compatible on both Python versions.
941 Six supports every Python version since 2.5. It is contained in only one
942 Python file, so it can be easily copied into your project.")
943 (license license:x11)))
945 (define-public python2-six
946 (package-with-python2 python-six))
948 (define-public python-dateutil-2
950 (name "python-dateutil")
955 (uri (pypi-uri "python-dateutil" version))
958 "0jrfpcgvgya6hs45dhrd9yiqgdgz9qp9aa07zsw8gqgn8zphff86"))))
959 (build-system python-build-system)
961 `(("python-six" ,python-six)))
962 (home-page "https://dateutil.readthedocs.io/en/stable/")
963 (synopsis "Extensions to the standard datetime module")
965 "The dateutil module provides powerful extensions to the standard
966 datetime module, available in Python 2.3+.")
967 (license license:bsd-3)
968 (properties `((python2-variant . ,(delay python2-dateutil-2))))))
970 (define-public python2-dateutil-2
971 (let ((base (package-with-python2 (strip-python2-variant python-dateutil-2))))
974 (inputs `(("python2-setuptools" ,python2-setuptools)
975 ,@(package-inputs base))))))
977 (define-public python-dateutil
979 (name "python-dateutil")
980 (version "1.5") ; last version for python < 3
984 (uri (string-append "http://labix.org/download/python-dateutil/"
985 "python-dateutil-" version ".tar.gz"))
988 "0fqfglhy5khbvsipr3x7m6bcaqljh8xl5cw33vbfxy7qhmywm2n0"))))
989 (build-system python-build-system)
991 `(("python-setuptools" ,python-setuptools)))
992 (home-page "https://dateutil.readthedocs.io/en/stable/")
993 (synopsis "Extensions to the standard datetime module")
995 "The dateutil module provides powerful extensions to the standard
996 datetime module, available in Python 2.3+.")
997 (license license:psfl)))
999 (define-public python2-dateutil
1000 (package-with-python2 python-dateutil))
1002 (define-public python-parsedatetime
1004 (name "python-parsedatetime")
1009 (uri (pypi-uri "parsedatetime" version))
1012 "0bdgyw6y3v7bcxlx0p50s8drxsh5bb5cy2afccqr3j90amvpii8p"))))
1013 (build-system python-build-system)
1015 `(("python-nose" ,python-nose)
1016 ("python-pyicu" ,python-pyicu)))
1017 (home-page "http://github.com/bear/parsedatetime/")
1019 "Parse human-readable date/time text")
1021 "Parse human-readable date/time text.")
1022 (license license:asl2.0)
1023 (properties `((python2-variant . ,(delay python2-parsedatetime))))))
1025 (define-public python2-parsedatetime
1026 (let ((base (package-with-python2 (strip-python2-variant python-parsedatetime))))
1029 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1030 ,@(package-native-inputs base))))))
1032 (define-public python-pandas
1034 (name "python-pandas")
1040 "https://pypi.python.org/packages/11/09/"
1041 "e66eb844daba8680ddff26335d5b4fead77f60f957678243549a8dd4830d/"
1042 "pandas-" version ".tar.gz"))
1044 (base32 "1ckpxrvvjj6zxmn68icd9hib8qcpx9b35f6izxnr25br5ilq7r6j"))))
1045 (build-system python-build-system)
1047 `(("python-numpy" ,python-numpy)))
1049 `(("python-pytz" ,python-pytz)
1050 ("python-dateutil" ,python-dateutil-2)))
1052 `(("python-nose" ,python-nose)))
1053 (home-page "http://pandas.pydata.org")
1054 (synopsis "Data structures for data analysis, time series, and statistics")
1056 "Pandas is a Python package providing fast, flexible, and expressive data
1057 structures designed to make working with structured (tabular,
1058 multidimensional, potentially heterogeneous) and time series data both easy
1059 and intuitive. It aims to be the fundamental high-level building block for
1060 doing practical, real world data analysis in Python.")
1061 (license license:bsd-3)
1062 (properties `((python2-variant . ,(delay python2-pandas))))))
1064 (define-public python2-pandas
1065 (let ((base (package-with-python2 (strip-python2-variant python-pandas))))
1068 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1069 ,@(package-native-inputs base))))))
1071 (define-public python-tzlocal
1073 (name "python-tzlocal")
1078 (uri (pypi-uri "tzlocal" version))
1081 "0paj7vlsb0np8b5sp4bv64wxv7qk2piyp7xg29pkhdjwsbls9fnb"))))
1082 (build-system python-build-system)
1083 (inputs `(("python-pytz" ,python-pytz)))
1084 (home-page "https://github.com/regebro/tzlocal")
1086 "Local timezone information for Python")
1088 "Tzlocal returns a tzinfo object with the local timezone information.
1089 This module attempts to fix a glaring hole in pytz, that there is no way to
1090 get the local timezone information, unless you know the zoneinfo name, and
1091 under several distributions that's hard or impossible to figure out.")
1092 (license license:cc0)))
1094 (define-public python2-pysqlite
1096 (name "python2-pysqlite")
1101 (uri (pypi-uri "pysqlite" version))
1104 "0rm0zqyb363y6wljhfmbxs16jjv7p8nk1d8zgq9sdwj6js7y3jkm"))))
1105 (build-system python-build-system)
1107 `(("sqlite" ,sqlite)))
1109 `(#:python ,python-2 ; incompatible with Python 3
1110 #:tests? #f)) ; no test target
1111 (home-page "http://github.com/ghaering/pysqlite")
1112 (synopsis "SQLite bindings for Python")
1114 "Pysqlite provides SQLite bindings for Python that comply to the
1115 Database API 2.0T.")
1116 (license license:zlib)))
1119 (define-public python2-mechanize
1121 (name "python2-mechanize")
1126 (uri (string-append "https://pypi.python.org/packages/source/m/mechanize/mechanize-"
1130 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1131 (build-system python-build-system)
1133 `(("python2-setuptools" ,python2-setuptools)))
1135 `(#:python ,python-2 ; apparently incompatible with Python 3
1137 ;; test fails with message
1138 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1139 ;; (python-3.3.2) or
1140 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1142 ;; The source code is from March 2011 and probably not up-to-date
1143 ;; with respect to python unit tests.
1144 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1146 "Stateful programmatic web browsing in Python")
1148 "Mechanize implements stateful programmatic web browsing in Python,
1149 after Andy Lester’s Perl module WWW::Mechanize.")
1150 (license (license:non-copyleft
1152 "See COPYING in the distribution."))))
1155 (define-public python-simplejson
1157 (name "python-simplejson")
1162 (uri (pypi-uri "simplejson" version))
1165 "0zylrnax8b6r0ndgni4w9c599fi6wm9vx5g6k3ddqfj3932kk16m"))))
1166 (build-system python-build-system)
1167 (home-page "http://simplejson.readthedocs.org/en/latest/")
1169 "Json library for Python")
1171 "JSON (JavaScript Object Notation) is a subset of JavaScript
1172 syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1175 Simplejson exposes an API familiar to users of the standard library marshal
1176 and pickle modules. It is the externally maintained version of the json
1177 library contained in Python 2.6, but maintains compatibility with Python 2.5
1178 and (currently) has significant performance advantages, even without using
1179 the optional C extension for speedups. Simplejson is also supported on
1181 (license license:x11)))
1183 (define-public python2-simplejson
1184 (package-with-python2 python-simplejson))
1187 (define-public python-pyicu
1189 (name "python-pyicu")
1194 (uri (string-append "https://pypi.python.org/packages/source/P/PyICU/PyICU-"
1198 "1diba0g8md614fvm9yf50paiwdkhj6rd7xwf1rg9mc0pxc0hhn4v"))))
1199 (build-system python-build-system)
1201 `(("icu4c" ,icu4c)))
1202 (home-page "http://pyicu.osafoundation.org/")
1203 (synopsis "Python extension wrapping the ICU C++ API")
1205 "PyICU is a python extension wrapping the ICU C++ API.")
1206 (license license:x11)
1207 (properties `((python2-variant . ,(delay python2-pyicu))))))
1209 (define-public python2-pyicu
1211 (inherit (package-with-python2
1212 (strip-python2-variant python-pyicu)))
1213 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
1215 (define-public python2-dogtail
1216 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1217 ;; spaces in indentation" with Python 3.
1219 (name "python2-dogtail")
1224 "https://fedorahosted.org/released/dogtail/dogtail-"
1228 "1yc4cg7ip87z15gyd4wy2vzbywrjc52a3m8r8gqy2b50d65llcg1"))))
1229 (build-system python-build-system)
1230 (arguments `(#:python ,python-2
1231 #:tests? #f)) ; invalid command "test"
1232 (home-page "https://fedorahosted.org/dogtail/")
1233 (synopsis "GUI test tool and automation framework written in Python")
1235 "Dogtail is a GUI test tool and automation framework written in Python.
1236 It uses Accessibility (a11y) technologies to communicate with desktop
1237 applications. dogtail scripts are written in Python and executed like any
1238 other Python program.")
1239 (license license:gpl2+)))
1241 (define-public python2-empy
1243 (name "python2-empy")
1247 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1251 "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6"))))
1252 (build-system python-build-system)
1254 `(#:python ,python-2
1255 #:phases (alist-replace
1258 (zero? (system* "./test.sh")))
1260 (home-page "http://www.alcyone.com/software/empy/")
1261 (synopsis "Templating system for Python")
1263 "EmPy is a system for embedding Python expressions and statements in
1264 template text; it takes an EmPy source file, processes it, and produces
1265 output. This is accomplished via expansions, which are special signals to the
1266 EmPy system and are set off by a special prefix (by default the at sign, @@).
1267 EmPy can expand arbitrary Python expressions and statements in this way, as
1268 well as a variety of special forms. Textual data not explicitly delimited in
1269 this way is sent unaffected to the output, allowing Python to be used in
1270 effect as a markup language. Also supported are callbacks via hooks,
1271 recording and playback via diversions, and dynamic, chainable filters. The
1272 system is highly configurable via command line options and embedded
1274 (license license:lgpl2.1+)))
1276 (define-public python2-element-tree
1278 (name "python2-element-tree")
1283 "http://effbot.org/media/downloads/elementtree-"
1284 version "-20050316.tar.gz"))
1287 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1288 (build-system python-build-system)
1290 `(#:python ,python-2 ; seems to be part of Python 3
1291 #:tests? #f)) ; no 'test' sub-command
1292 (synopsis "Toolkit for XML processing in Python")
1294 "ElementTree is a Python library supporting lightweight XML processing.")
1295 (home-page "http://effbot.org/zone/element-index.htm")
1296 (license (license:x11-style
1297 "http://docs.python.org/2/license.html"
1298 "Like \"CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2\"."))))
1300 (define-public python2-pybugz
1302 (name "python2-pybugz")
1307 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1311 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
1312 (patches (search-patches "pybugz-stty.patch"
1313 "pybugz-encode-error.patch"))))
1314 (build-system python-build-system)
1316 `(#:python ,python-2 ; SyntaxError with Python 3
1317 #:tests? #f)) ; no 'test' sub-command
1318 (inputs `(("element-tree" ,python2-element-tree)))
1319 (synopsis "Python and command-line interface to Bugzilla")
1321 "PyBugz is a Python library and command-line tool to query the Bugzilla
1322 bug tracking system. It is meant as an aid to speed up interaction with the
1324 (home-page "http://www.liquidx.net/pybugz/")
1325 (license license:gpl2)))
1327 (define-public python-enum34
1329 (name "python-enum34")
1334 (uri (pypi-uri "enum34" version))
1337 "0yx1m4564wxgbm4glb3457hi16xihd9w63rv13y2przkdir9dfgp"))))
1338 (build-system python-build-system)
1343 (lambda _ (zero? (system* "python" "enum/test_enum.py")))
1345 (home-page "https://pypi.python.org/pypi/enum34")
1346 (synopsis "Backported Python 3.4 Enum")
1348 "Enum34 is the new Python stdlib enum module available in Python 3.4
1349 backported for previous versions of Python from 2.4 to 3.3.")
1350 (license license:bsd-3)))
1352 (define-public python2-enum34
1353 (package-with-python2 python-enum34))
1355 (define-public python-parse-type
1357 (name "python-parse-type")
1362 (uri (string-append "https://pypi.python.org/packages/source/p/"
1363 "parse_type/parse_type-" version ".tar.gz"))
1366 "0iv1c34npr4iynwpgv1vkjx9rjd18a85ir8c01gc5f7wp8iv7l1x"))))
1367 (build-system python-build-system)
1369 `(("python-setuptools" ,python-setuptools)
1370 ("python-six" ,python-six)
1371 ("python-parse" ,python-parse)))
1372 (arguments '(#:tests? #f)) ;TODO: tests require pytest
1373 (home-page "https://github.com/jenisys/parse_type")
1374 (synopsis "Extended parse module")
1376 "Parse_type extends the python parse module.")
1377 (license license:bsd-3)))
1379 (define-public python-parse
1381 (name "python-parse")
1386 (uri (pypi-uri "parse" version))
1389 "0y31i3mwgv35qn0kzzjn9q8jqfdqmbi6sr6yfvn8rq4lqjm5lhvi"))))
1390 (build-system python-build-system)
1395 (lambda _ (zero? (system* "python" "test_parse.py")))
1397 (home-page "https://github.com/r1chardj0n3s/parse")
1398 (synopsis "Parse strings")
1400 "Parse strings using a specification based on the Python format()
1402 (license license:x11)))
1405 (define-public scons
1411 (uri (string-append "mirror://sourceforge/scons/scons/" version
1412 "/scons-" version ".tar.gz"))
1415 "0hdlci43wjz8maryj83mz04ir6rwcdrrzpd7cpzvdlzycqhdfmsb"))))
1416 (build-system python-build-system)
1418 ;; With Python 3.x, fails to build with a syntax error.
1419 `(#:python ,python-2
1420 #:tests? #f)) ; no 'python setup.py test' command
1421 (home-page "http://scons.org/")
1422 (synopsis "Software construction tool written in Python")
1424 "SCons is a software construction tool. Think of SCons as an improved,
1425 cross-platform substitute for the classic Make utility with integrated
1426 functionality similar to autoconf/automake and compiler caches such as ccache.
1427 In short, SCons is an easier, more reliable and faster way to build
1429 (license license:x11)))
1431 (define-public python-extras
1433 (name "python-extras")
1439 "https://pypi.python.org/packages/source/e/extras/extras-"
1443 "1h7zx4dfyclalg0fqnfjijpn0f793a9mx8sy3b27gd31nr6dhq3s"))))
1444 (build-system python-build-system)
1446 `(("python-setuptools" ,python-setuptools)))
1448 ;; error in setup.cfg: command 'test' has no such option 'buffer'
1450 (home-page "https://github.com/testing-cabal/extras")
1451 (synopsis "Useful extensions to the Python standard library")
1453 "Extras is a set of extensions to the Python standard library.")
1454 (license license:expat)))
1456 (define-public python2-extras
1457 (package-with-python2 python-extras))
1459 (define-public python-mimeparse
1461 (name "python-mimeparse")
1467 "https://pypi.python.org/packages/source/p/python-mimeparse/python-mimeparse-"
1471 "1hyxg09kaj02ri0rmwjqi86wk4nd1akvv7n0dx77azz76wga4s9w"))))
1472 (build-system python-build-system)
1474 `(("python-setuptools" ,python-setuptools)))
1476 '(#:tests? #f)) ; no setup.py test command
1478 "https://github.com/dbtsai/python-mimeparse")
1479 (synopsis "Python library for parsing MIME types")
1481 "Mimeparse provides basic functions for parsing MIME type names and
1482 matching them against a list of media-ranges.")
1483 (license license:expat)))
1485 (define-public python2-mimeparse
1486 (package-with-python2 python-mimeparse))
1488 (define-public python-nose
1490 (name "python-nose")
1495 (uri (pypi-uri "nose" version))
1498 "164a43k7k2wsqqk1s6vavcdamvss4mz0vd6pwzv2h9n8rgwzxgzi"))))
1499 (build-system python-build-system)
1501 `(("python-setuptools" ,python-setuptools)))
1503 '(#:tests? #f)) ; FIXME: test suite fails
1504 (home-page "http://readthedocs.org/docs/nose/")
1505 (synopsis "Python testing library")
1507 "Nose extends the unittest library to make testing easier.")
1508 (license license:lgpl2.0+)))
1510 (define-public python2-nose
1511 (package-with-python2 python-nose))
1513 (define-public python-nose2
1515 (name "python-nose2")
1520 (uri (pypi-uri "nose2" version))
1523 "1x4zjq1zlyrh8b9ba0cmafd3w94pxhid408kibyjd3s6h1lap6s7"))))
1524 (build-system python-build-system)
1525 (arguments `(#:tests? #f)) ; 'module' object has no attribute 'collector'
1527 `(("python-setuptools" ,python-setuptools)))
1529 `(("python-cov-core" ,python-cov-core)
1530 ("python-pytest-cov" ,python-pytest-cov)
1531 ("python-six" ,python-six)))
1532 (home-page "https://github.com/nose-devs/nose2")
1533 (synopsis "Next generation of nicer testing for Python")
1535 "Nose2 is the next generation of nicer testing for Python, based on the
1536 plugins branch of unittest2. Nose2 aims to improve on nose by providing a
1537 better plugin api, being easier for users to configure, and simplifying internal
1538 interfaces and processes.")
1539 (license license:bsd-2)))
1541 (define-public python2-nose2
1542 (package-with-python2 python-nose2))
1544 (define-public python-unittest2
1546 (name "python-unittest2")
1552 "https://pypi.python.org/packages/source/u/unittest2py3k/unittest2py3k-"
1556 "00yl6lskygcrddx5zspkhr0ibgvpknl4678kkm6s626539grq93q"))))
1557 (build-system python-build-system)
1559 `(("python-setuptools" ,python-setuptools)))
1560 (home-page "http://pypi.python.org/pypi/unittest2")
1561 (synopsis "Python unit testing library")
1563 "Unittest2 is a replacement for the unittest module in the Python
1565 (license license:psfl)))
1567 (define-public python2-unittest2
1568 (package (inherit python-unittest2)
1569 (name "python2-unittest2")
1575 "https://pypi.python.org/packages/source/u/unittest2/unittest2-"
1579 "0wbs4i4x3x7klr3v35ss6p9mcqz883i1xgcpkhvl7n2lyv6yhpda"))))
1581 `(("python2-setuptools" ,python2-setuptools)))
1583 `(#:python ,python-2
1584 #:tests? #f)))) ; no setup.py test command
1586 (define-public python-py
1593 (uri (pypi-uri "py" version))
1596 "0561gz2w3i825gyl42mcq14y3dcgkapfiv5zv9a2bz15qxiijl56"))))
1597 (build-system python-build-system)
1599 `(("python-setuptools" ,python-setuptools)))
1600 (home-page "http://pylib.readthedocs.org/")
1601 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1603 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1604 code introspection, and logging.")
1605 (license license:expat)))
1607 (define-public python2-py
1608 (package-with-python2 python-py))
1610 (define-public python-pytest
1612 (name "python-pytest")
1618 "https://pypi.python.org/packages/source/p/pytest/pytest-"
1622 "1z4yi986f9n0p8qmzmn21m21m8j1x78hk3505f89baqm6pdw7afm"))
1623 (modules '((guix build utils)))
1625 ;; One of the tests involves the /usr directory, so it fails.
1626 '(substitute* "testing/test_argcomplete.py"
1627 (("def test_remove_dir_prefix\\(self\\):")
1628 "@pytest.mark.xfail\n def test_remove_dir_prefix(self):")))))
1629 (build-system python-build-system)
1631 `(("python-setuptools" ,python-setuptools)
1632 ("python-py" ,python-py)
1633 ("python-nose" ,python-nose)
1634 ("python-mock" ,python-mock)))
1635 (home-page "http://pytest.org")
1636 (synopsis "Python testing library")
1638 "Pytest is a testing tool that provides auto-discovery of test modules
1639 and functions, detailed info on failing assert statements, modular fixtures,
1640 and many external plugins.")
1641 (license license:expat)))
1643 (define-public python2-pytest
1644 (package-with-python2 python-pytest))
1646 (define-public python-pytest-cov
1648 (name "python-pytest-cov")
1653 (uri (pypi-uri "pytest-cov" version))
1656 "1yl4nbhzfgsxqlsyk4clafgp9x11zvgrkprm9i2p3fgkwx9jxcm8"))))
1657 (build-system python-build-system)
1659 `(("python-coverage" ,python-coverage)
1660 ("python-pytest" ,python-pytest)))
1661 (home-page "https://github.com/pytest-dev/pytest-cov")
1662 (synopsis "Pytest plugin for measuring coverage")
1664 "Pytest-cov produces coverage reports. It supports centralised testing and
1665 distributed testing in both @code{load} and @code{each} modes. It also
1666 supports coverage of subprocesses.")
1667 (license license:expat)
1668 (properties `((python2-variant . ,(delay python2-pytest-cov))))))
1670 (define-public python2-pytest-cov
1671 (let ((base (package-with-python2 (strip-python2-variant python-pytest-cov))))
1674 (inputs `(("python2-setuptools" ,python2-setuptools)
1675 ,@(package-inputs base))))))
1677 (define-public python-pytest-runner
1679 (name "python-pytest-runner")
1684 (uri (pypi-uri "pytest-runner" version))
1687 "1nwcqx0l3fv52kv8526wy8ypzghbq96c96di318d98d3wh7a8xg7"))))
1688 (build-system python-build-system)
1691 (modify-phases %standard-phases
1692 ;; The fancy way of setting the version with setuptools_scm does not
1693 ;; seem to work here.
1694 (add-after 'unpack 'set-version
1696 (substitute* "docs/conf.py"
1697 (("version = setuptools_scm\\.get_version\\(root='\\.\\.')")
1698 (string-append "version = \"" ,version "\"")))
1701 `(("python-pytest" ,python-pytest)
1702 ("python-setuptools-scm" ,python-setuptools-scm)))
1703 (home-page "https://github.com/pytest-dev/pytest-runner")
1704 (synopsis "Invoke py.test as a distutils command")
1706 "This package provides a @command{pytest-runner} command that
1707 @file{setup.py} files can use to run tests.")
1708 (license license:expat)
1709 (properties `((python2-variant . ,(delay python2-pytest-runner))))))
1711 (define-public python2-pytest-runner
1712 (let ((base (package-with-python2
1713 (strip-python2-variant python-pytest-runner))))
1716 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1717 ,@(package-native-inputs base))))))
1719 (define-public python-pytest-mock
1721 (name "python-pytest-mock")
1726 (uri (pypi-uri "pytest-mock" version ".zip"))
1729 "03zxar5drzm7ksqyrwypjaza3cri6wqvpr6iam92djvg6znp32gp"))))
1730 (build-system python-build-system)
1732 `(("unzip" ,unzip)))
1734 `(("python-py" ,python-py)
1735 ("python-pytest" ,python-pytest)))
1736 (home-page "https://github.com/pytest-dev/pytest-mock/")
1737 (synopsis "Thin-wrapper around the mock package for easier use with py.test")
1739 "This plugin installs a @code{mocker} fixture which is a thin-wrapper
1740 around the patching API provided by the @code{mock} package, but with the
1741 benefit of not having to worry about undoing patches at the end of a test.
1742 The mocker fixture has the same API as @code{mock.patch}, supporting the
1744 (properties `((python2-variant . ,(delay python2-pytest-mock))))
1745 (license license:expat)))
1747 (define-public python2-pytest-mock
1748 (let ((base (package-with-python2
1749 (strip-python2-variant python-pytest-mock))))
1750 (package (inherit base)
1752 `(("python2-setuptools" ,python2-setuptools)
1753 ,@(package-native-inputs base)))
1755 `(("python2-mock" ,python2-mock)
1756 ,@(package-inputs base))))))
1758 (define-public python-pytest-xdist
1760 (name "python-pytest-xdist")
1765 (uri (pypi-uri "pytest-xdist" version ".zip"))
1768 "08rn2l39ds60xshs4js787l84pfckksqklfq2wq9x8ig2aci2pja"))
1769 (modules '((guix build utils)))
1772 ;; Remove pre-compiled .pyc files from source.
1773 (for-each delete-file-recursively
1774 (find-files "." "__pycache__" #:directories? #t))
1775 (for-each delete-file (find-files "." "\\.pyc$"))
1777 (build-system python-build-system)
1780 ("python-setuptools-scm" ,python-setuptools-scm)))
1782 `(("python-apipkg" ,python-apipkg)
1783 ("python-execnet" ,python-execnet)
1784 ("python-pytest" ,python-pytest)
1785 ("python-py" ,python-py)))
1787 "https://github.com/pytest-dev/pytest-xdist")
1789 "Plugin for py.test with distributed testing and loop-on-failing modes")
1791 "The pytest-xdist plugin extends py.test with some unique test execution
1792 modes: parallelization, running tests in boxed subprocesses, the ability
1793 to run tests repeatedly when failed, and the ability to run tests on multiple
1794 Python interpreters or platforms. It uses rsync to copy the existing
1795 program code to a remote location, executes there, and then syncs the
1797 (license license:expat)
1798 (properties `((python2-variant . ,(delay python2-pytest-xdist))))))
1800 (define-public python2-pytest-xdist
1801 (let ((base (package-with-python2
1802 (strip-python2-variant python-pytest-xdist))))
1805 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1806 ,@(package-native-inputs base))))))
1808 (define-public python-scripttest
1810 (name "python-scripttest")
1816 "https://pypi.python.org/packages/source/s/scripttest/scripttest-"
1820 "0f4w84k8ck82syys7yg9maz93mqzc8p5ymis941x034v44jzq74m"))))
1821 (build-system python-build-system)
1823 `(("python-setuptools" ,python-setuptools)
1824 ("python-pytest" ,python-pytest)))
1825 (home-page "http://pythonpaste.org/scripttest/")
1826 (synopsis "Python library to test command-line scripts")
1827 (description "Scripttest is a Python helper library for testing
1828 interactive command-line applications. With it you can run a script in a
1829 subprocess and see the output as well as any file modifications.")
1830 (license license:expat)))
1832 (define-public python2-scripttest
1833 (package-with-python2 python-scripttest))
1835 (define-public python-testtools
1837 (name "python-testtools")
1843 "https://pypi.python.org/packages/source/t/testtools/testtools-"
1847 "1dyml28ykpl5jb9khdmcdvhy1cxqingys6qvj2k04fzlaj6z3bbx"))))
1848 (build-system python-build-system)
1850 `(("python-mimeparse" ,python-mimeparse)))
1852 `(("python-setuptools" ,python-setuptools)
1853 ("python-extras" ,python-extras)))
1854 (home-page "https://github.com/testing-cabal/testtools")
1856 "Extensions to the Python standard library unit testing framework")
1858 "Testtools extends the Python standard library unit testing framework to
1859 provide matchers, more debugging information, and cross-Python
1861 (license license:psfl)))
1863 (define-public python2-testtools
1864 (package-with-python2 python-testtools))
1866 (define-public python-testscenarios
1868 (name "python-testscenarios")
1874 "https://pypi.python.org/packages/source/t/testscenarios/testscenarios-"
1878 "1671jvrvqlmbnc42j7pc5y6vc37q44aiwrq0zic652pxyy2fxvjg"))))
1879 (build-system python-build-system)
1881 `(("python-setuptools" ,python-setuptools)
1882 ("python-testtools" ,python-testtools)
1883 ("python-mimeparse" ,python-mimeparse)))
1884 (home-page "https://launchpad.net/testscenarios")
1885 (synopsis "Pyunit extension for dependency injection")
1887 "Testscenarios provides clean dependency injection for Python unittest
1889 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
1891 (define-public python2-testscenarios
1892 (package-with-python2 python-testscenarios))
1894 (define-public python-testresources
1896 (name "python-testresources")
1902 "https://pypi.python.org/packages/source/t/testresources/testresources-"
1906 "0cbj3plbllyz42c4b5xxgwaa7mml54lakslrn4kkhinxhdri22md"))))
1907 (build-system python-build-system)
1909 `(("python-setuptools" ,python-setuptools)))
1910 (home-page "https://launchpad.net/testresources")
1912 "Pyunit extension for managing test resources")
1914 "Testresources is an extension to Python's unittest to allow declarative
1915 use of resources by test cases.")
1916 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
1918 (define-public python2-testresources
1919 (package-with-python2 python-testresources))
1921 (define-public python-subunit
1923 (name "python-subunit")
1929 "https://pypi.python.org/packages/source/p/python-subunit/python-subunit-"
1933 "1nkw9wfbvizmpajbj3in8ns07g7lwkiv8hip14jjlwk3cacls6jv"))))
1934 (build-system python-build-system)
1936 `(("python-setuptools" ,python-setuptools)
1937 ("python-testtools" ,python-testtools)
1938 ("python-mimeparse" ,python-mimeparse)
1939 ("python-testscenarios" ,python-testscenarios)))
1940 (home-page "http://launchpad.net/subunit")
1941 (synopsis "Python implementation of the subunit protocol")
1943 "Python-subunit is a Python implementation of the subunit test streaming
1945 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
1947 (define-public python2-subunit
1948 (package-with-python2 python-subunit))
1950 ;; Recent versions of python-fixtures need a recent version of python-pbr,
1951 ;; which needs a recent version of python-fixtures. To fix this circular
1952 ;; dependency, we keep old versions of python-fixtures and python-pbr to
1953 ;; bootstrap the whole thing:
1954 ;; - python-fixtures-0.3.16 is used to build python-pbr-0.11
1955 ;; - python-pbr-0.11 is used to build python-fixtures
1956 ;; - python-fixtures is used to build python-pbr
1957 (define-public python-fixtures-0.3.16
1959 (name "python-fixtures")
1965 "https://pypi.python.org/packages/source/f/fixtures/fixtures-"
1969 "0x9r2gwilcig5g54k60bxzg96zabizq1855lrprlb4zckalp9asc"))))
1970 (build-system python-build-system)
1972 `(("python-setuptools" ,python-setuptools)))
1974 '(#:tests? #f)) ; no setup.py test command
1975 (home-page "https://launchpad.net/python-fixtures")
1976 (synopsis "Python test fixture library")
1978 "Fixtures provides a way to create reusable state, useful when writing
1980 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
1982 (define-public python2-fixtures-0.3.16
1983 (package-with-python2 python-fixtures-0.3.16))
1985 (define-public python-pbr-0.11
1993 "https://pypi.python.org/packages/source/p/pbr/pbr-"
1997 "0v9gb7gyqf7q9s99l0nnjj9ww9b0jvyqlwm4d56pcyinxydddw6p"))))
1998 (build-system python-build-system)
2000 `(#:tests? #f)) ;; Most tests seem to use the Internet.
2002 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
2003 ("python-pip" ,python-pip)
2004 ("python-setuptools" ,python-setuptools)))
2005 (home-page "https://launchpad.net/pbr")
2006 (synopsis "Change the default behavior of Python’s setuptools")
2008 "Python Build Reasonableness (PBR) is a library that injects some useful
2009 and sensible default behaviors into your setuptools run.")
2010 (license license:asl2.0)))
2012 (define-public python2-pbr-0.11
2013 (package-with-python2 python-pbr-0.11))
2015 (define-public python-pbr
2023 "https://pypi.python.org/packages/source/p/pbr/pbr-"
2028 "0jcny36cf3s8ar5r4a575npz080hndnrfs4np1fqhv0ym4k7c4p2"))))
2029 (build-system python-build-system)
2031 `(#:tests? #f)) ;; Most tests seem to use the Internet.
2033 `(("python-testrepository" ,python-testrepository)
2034 ("git" ,git))) ;; pbr actually uses the "git" binary.
2036 `(("python-fixtures" ,python-fixtures)
2037 ("python-mimeparse" ,python-mimeparse)
2038 ("python-mock" ,python-mock)
2039 ("python-setuptools" ,python-setuptools)
2040 ("python-six" ,python-six)
2041 ("python-sphinx" ,python-sphinx)
2042 ("python-testrepository" ,python-testrepository)
2043 ("python-testresources" ,python-testresources)
2044 ("python-testscenarios" ,python-testscenarios)
2045 ("python-testtools" ,python-testtools)
2046 ("python-virtualenv" ,python-virtualenv)))
2047 (home-page "https://launchpad.net/pbr")
2048 (synopsis "Change the default behavior of Python’s setuptools")
2050 "Python Build Reasonableness (PBR) is a library that injects some useful
2051 and sensible default behaviors into your setuptools run.")
2052 (license license:asl2.0)))
2054 (define-public python2-pbr
2055 (package-with-python2 python-pbr))
2057 (define-public python-fixtures
2059 (name "python-fixtures")
2064 (uri (pypi-uri "fixtures" version))
2067 "0djxvdwm8s60dbfn7bhf40x6g818p3b3mlwijm1c3bqg7msn271y"))))
2068 (build-system python-build-system)
2070 `(("python-six" ,python-six)
2071 ("python-pbr-0.11" ,python-pbr-0.11)))
2073 `(("python-pip" ,python-pip)
2074 ("python-setuptools" ,python-setuptools)
2076 ("python-testtools" ,python-testtools)))
2078 '(#:tests? #f)) ; no setup.py test command
2079 (home-page "https://launchpad.net/python-fixtures")
2080 (synopsis "Python test fixture library")
2082 "Fixtures provides a way to create reusable state, useful when writing
2084 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
2086 (define-public python2-fixtures
2087 (package-with-python2 python-fixtures))
2089 (define-public python-testrepository
2091 (name "python-testrepository")
2097 "https://pypi.python.org/packages/source/t/testrepository/testrepository-"
2101 "1ssqb07c277010i6gzzkbdd46gd9mrj0bi0i8vn560n2k2y4j93m"))))
2102 (build-system python-build-system)
2104 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
2105 ("python-testtools" ,python-testtools)))
2107 `(("python-setuptools" ,python-setuptools)
2108 ("python-subunit" ,python-subunit)
2109 ("python-mimeparse" ,python-mimeparse)))
2110 (home-page "https://launchpad.net/testrepository")
2111 (synopsis "Database for Python test results")
2112 (description "Testrepository provides a database of test results which can
2113 be used as part of a developer's workflow to check things such as what tests
2114 have failed since the last commit or what tests are currently failing.")
2115 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
2117 (define-public python2-testrepository
2118 (package-with-python2 python-testrepository))
2120 (define-public python-coverage
2122 (name "python-coverage")
2127 (uri (pypi-uri "coverage" version))
2130 "01rbr4br4lsk0lwn8fb96zwd2xr4f0mg1w7iq3j11i8f5ig2nqs1"))))
2131 (build-system python-build-system)
2133 `(("python-setuptools" ,python-setuptools)))
2134 (home-page "http://nedbatchelder.com/code/coverage")
2135 (synopsis "Code coverage measurement for Python")
2137 "Coverage measures code coverage, typically during test execution. It
2138 uses the code analysis tools and tracing hooks provided in the Python standard
2139 library to determine which lines are executable, and which have been
2141 (license license:bsd-3)))
2143 (define-public python2-coverage
2144 (package-with-python2 python-coverage))
2146 (define-public python-cov-core
2148 (name "python-cov-core")
2153 (uri (pypi-uri "cov-core" version))
2156 "0k3np9ymh06yv1ib96sb6wfsxjkqhmik8qfsn119vnhga9ywc52a"))))
2157 (build-system python-build-system)
2159 `(("python-coverage" ,python-coverage)))
2160 (home-page "https://github.com/schlamar/cov-core")
2161 (synopsis "plugin core for use by pytest-cov, nose-cov and nose2-cov")
2163 "This is a library package for use by pytest-cov, nose-cov and nose2-cov.
2164 It is useful for developing coverage plugins for these testing frameworks.")
2165 (license license:expat)
2166 (properties `((python2-variant . ,(delay python2-cov-core))))))
2168 (define-public python2-cov-core
2169 (let ((cov-core (package-with-python2 (strip-python2-variant python-cov-core))))
2170 (package (inherit cov-core)
2172 `(("python2-setuptools" ,python2-setuptools)
2173 ,@(package-native-inputs cov-core))))))
2175 (define-public python-discover
2177 (name "python-discover")
2183 "https://pypi.python.org/packages/source/d/discover/discover-"
2187 "0y8d0zwiqar51kxj8lzmkvwc3b8kazb04gk5zcb4nzg5k68zmhq5"))))
2188 (build-system python-build-system)
2190 `(("python-setuptools" ,python-setuptools)))
2191 (home-page "http://pypi.python.org/pypi/discover/")
2193 "Python test discovery for unittest")
2195 "Discover provides test discovery for unittest, a feature that has been
2196 backported from Python 2.7 for Python 2.4+.")
2197 (license license:bsd-3)))
2199 (define-public python2-discover
2200 (package-with-python2 python-discover))
2202 (define-public behave
2208 (uri (pypi-uri "behave" version ".tar.bz2"))
2211 "1iypp6z46r19n4xmgx6m1lwmlpfjh8vapq8izigrqlaarvp2y64c"))))
2212 (build-system python-build-system)
2214 `(("python-setuptools" ,python-setuptools)
2215 ("python-six" ,python-six)
2216 ("python-parse" ,python-parse)
2217 ("python-parse-type" ,python-parse-type)))
2218 (arguments `(#:tests? #f)) ;TODO: tests require nose>=1.3 and
2220 (home-page "http://github.com/behave/behave")
2221 (synopsis "Python behavior-driven development")
2223 "Behave is a tool for behavior-driven development in python.
2224 Behavior-driven development (or BDD) is an agile software development
2225 technique that encourages collaboration between developers, QA and
2226 non-technical or business participants in a software project. Behave uses
2227 tests written in a natural language style, backed up by Python code.")
2228 (license license:x11)))
2230 (define-public python-exif-read
2232 (name "python-exif-read")
2236 (uri (pypi-uri "ExifRead" version))
2239 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
2240 (build-system python-build-system)
2242 `(("python-setuptools" ,python-setuptools)))
2243 (arguments `(#:tests? #f)) ; no tests
2244 (home-page "https://github.com/ianare/exif-py")
2245 (synopsis "Python library to extract EXIF data from image files")
2247 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
2249 (license license:bsd-3)))
2251 (define-public python2-exif-read
2252 (package-with-python2 python-exif-read))
2254 (define-public python-pyld
2256 (name "python-pyld")
2260 (uri (pypi-uri "PyLD" version))
2263 "0k881ffazpf8q1z8862g4bb3pzwpnz9whrci2mf311mvn1qbyqad"))))
2264 (build-system python-build-system)
2266 `(("python-setuptools" ,python-setuptools)))
2267 (arguments `(#:tests? #f)) ; no tests
2268 (home-page "http://github.com/digitalbazaar/pyld")
2269 (synopsis "Python implementation of the JSON-LD specification")
2271 "PyLD is an implementation of the JSON-LD specification.")
2272 (license license:bsd-3)))
2274 (define-public python2-pyld
2275 (package-with-python2 python-pyld))
2277 (define-public python-certifi
2279 (name "python-certifi")
2280 (version "2016.8.31")
2283 (uri (pypi-uri "certifi" version))
2286 "06c9dcyv8ss050gkv5xjivbxhm6qm0s9vzy4r33wqabgv118lw7p"))))
2287 (build-system python-build-system)
2289 `(("python-setuptools" ,python-setuptools)))
2290 (arguments `(#:tests? #f)) ; no tests
2291 (home-page "http://python-requests.org/")
2292 (synopsis "Python CA certificate bundle")
2294 "Certifi is a Python library that contains a CA certificate bundle, which
2295 is used by the Requests library to verify HTTPS requests.")
2296 (license license:asl2.0)))
2298 (define-public python2-certifi
2299 (package-with-python2 python-certifi))
2301 (define-public python-click
2303 (name "python-click")
2308 (uri (pypi-uri "click" version))
2311 "1sggipyz52crrybwbr9xvwxd4aqigvplf53k9w3ygxmzivd1jsnc"))))
2312 (build-system python-build-system)
2315 (modify-phases %standard-phases
2316 (add-after 'unpack 'fix-paths
2317 (lambda* (#:key inputs #:allow-other-keys)
2318 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
2319 "cross-libc" "libc"))))
2320 (substitute* "click/_unicodefun.py"
2322 (string-append "'" glibc "/bin/locale'"))))
2325 `(("python-setuptools" ,python-setuptools)))
2326 (home-page "http://click.pocoo.org")
2327 (synopsis "Command line library for Python")
2329 "Click is a Python package for creating command line interfaces in a
2330 composable way with as little code as necessary. Its name stands for
2331 \"Command Line Interface Creation Kit\". It's highly configurable but comes
2332 with sensible defaults out of the box.")
2333 (license license:bsd-3)))
2335 (define-public python2-click
2336 (package-with-python2 python-click))
2338 (define-public python-wheel
2340 (name "python-wheel")
2345 (uri (pypi-uri "wheel" version))
2348 "0j0n38hg1jvrmyy68f9ikvzq1gs9g0sx4ws7maf8wi3bwbbqmfqy"))))
2349 (build-system python-build-system)
2351 `(("python-setuptools" ,python-setuptools)
2352 ("python-jsonschema" ,python-jsonschema)
2353 ("python-pytest-cov" ,python-pytest-cov)))
2354 (home-page "https://bitbucket.org/pypa/wheel/")
2355 (synopsis "Format for built Python packages")
2357 "A wheel is a ZIP-format archive with a specially formatted filename and
2358 the @code{.whl} extension. It is designed to contain all the files for a PEP
2359 376 compatible install in a way that is very close to the on-disk format. Many
2360 packages will be properly installed with only the @code{Unpack} step and the
2361 unpacked archive preserves enough information to @code{Spread} (copy data and
2362 scripts to their final locations) at any later time. Wheel files can be
2363 installed with a newer @code{pip} or with wheel's own command line utility.")
2364 (license license:expat)
2365 (properties `((python2-variant . ,(delay python2-wheel))))))
2367 (define-public python2-wheel
2368 (let ((wheel (package-with-python2
2369 (strip-python2-variant python-wheel))))
2370 (package (inherit wheel)
2371 (native-inputs `(("python2-functools32" ,python2-functools32)
2372 ,@(package-native-inputs wheel))))))
2375 (define-public python-requests
2377 (name "python-requests")
2381 (uri (pypi-uri "requests" version))
2384 "0zsqrzlybf25xscgi7ja4s48y2abf9wvjkn47wh984qgs1fq2xy5"))))
2385 (build-system python-build-system)
2387 `(("python-setuptools" ,python-setuptools)
2388 ("python-py" ,python-py)
2389 ("python-pytest" ,python-pytest)
2390 ("python-pytest-cov" ,python-pytest-cov)
2391 ("python-wheel" ,python-wheel)))
2392 (home-page "http://python-requests.org/")
2393 (synopsis "Python HTTP library")
2395 "Requests is a Python HTTP client library. It aims to be easier to use
2396 than Python’s urllib2 library.")
2397 (license license:asl2.0)))
2399 ;; Some software requires an older version of Requests, notably Docker
2401 (define-public python-requests-2.7
2402 (package (inherit python-requests)
2406 (uri (pypi-uri "requests" version))
2409 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
2411 (define-public python2-requests
2412 (package-with-python2 python-requests))
2414 (define-public python-vcversioner
2416 (name "python-vcversioner")
2417 (version "2.14.0.0")
2421 (uri (pypi-uri "vcversioner" version))
2424 "11ivq1bm7v0yb4nsfbv9m7g7lyjn112gbvpjnjz8nv1fx633dm5c"))))
2425 (build-system python-build-system)
2427 `(("python-setuptools" ,python-setuptools)))
2428 (synopsis "Python library for version number discovery")
2429 (description "Vcversioner is a Python library that inspects tagging
2430 information in a variety of version control systems in order to discover
2432 (home-page "https://github.com/habnabit/vcversioner")
2433 (license license:isc)))
2435 (define-public python2-vcversioner
2436 (package-with-python2 python-vcversioner))
2438 (define-public python-jsonschema
2440 (name "python-jsonschema")
2446 "https://pypi.python.org/packages/source/j/jsonschema/jsonschema-"
2450 "0hddbqjm4jq63y8jf44nswina1crjs16l9snb6m3vvgyg31klrrn"))))
2451 (build-system python-build-system)
2453 `(("python-setuptools" ,python-setuptools)
2454 ("python-vcversioner" ,python-vcversioner)))
2455 (home-page "http://github.com/Julian/jsonschema")
2456 (synopsis "Implementation of JSON Schema for Python")
2458 "Jsonschema is an implementation of JSON Schema for Python.")
2459 (license license:expat)
2460 (properties `((python2-variant . ,(delay python2-jsonschema))))))
2462 (define-public python2-jsonschema
2463 (let ((jsonschema (package-with-python2
2464 (strip-python2-variant python-jsonschema))))
2465 (package (inherit jsonschema)
2467 `(("python2-functools32" ,python2-functools32)
2468 ,@(package-inputs jsonschema))))))
2470 (define-public python-unidecode
2472 (name "python-unidecode")
2476 (uri (pypi-uri "Unidecode" version))
2479 "12hhblqy1ajvidm38im4171x4arg83pfmziyn53nizp29p3m14gi"))))
2480 (build-system python-build-system)
2482 `(("python-setuptools" ,python-setuptools)))
2483 (home-page "https://pypi.python.org/pypi/Unidecode")
2484 (synopsis "ASCII transliterations of Unicode text")
2486 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2487 useful when integrating with legacy code that doesn't support Unicode, or for
2488 ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2489 machine identifiers from human-readable Unicode strings that should still be
2490 somewhat intelligeble.")
2491 (license license:gpl2+)))
2493 (define-public python2-unidecode
2494 (package-with-python2 python-unidecode))
2496 (define-public python-pyjwt
2498 (name "python-pyjwt")
2503 (uri (pypi-uri "PyJWT" version))
2506 "1556v2jppd8mjkkj66pxb5rcazm35jq81r233mdl8hfmz9n3icp1"))))
2507 (build-system python-build-system)
2509 `(("python-setuptools" ,python-setuptools)
2510 ("python-pytest-runner" ,python-pytest-runner)))
2512 '(#:tests? #f)) ; test suite doesn't work
2513 (home-page "http://github.com/progrium/pyjwt")
2514 (synopsis "JSON Web Token implementation in Python")
2516 "PyJWT is a JSON Web Token implementation written in Python.")
2517 (license license:expat)))
2519 (define-public python2-pyjwt
2520 (package-with-python2 python-pyjwt))
2522 (define-public python-oauthlib
2524 (name "python-oauthlib")
2528 (uri (pypi-uri "oauthlib" version))
2531 "1bfrj70vdjxjw74khbyh6f0dksv7p5rh2346jnlrffyacd3gwjzg"))))
2532 (build-system python-build-system)
2534 `(("python-coverage" ,python-coverage)
2535 ("python-nose" ,python-nose)
2536 ("python-mock" ,python-mock)))
2538 `(("python-blinker" ,python-blinker)
2539 ("python-cryptography" ,python-cryptography)
2540 ("python-pyjwt" ,python-pyjwt)))
2541 (home-page "https://github.com/idan/oauthlib")
2542 (synopsis "OAuth implementation for Python")
2544 "Oauthlib is a generic, spec-compliant, thorough implementation of the
2545 OAuth request-signing logic.")
2546 (license license:bsd-3)
2547 (properties `((python2-variant . ,(delay python2-oauthlib))))))
2549 (define-public python2-oauthlib
2550 (let ((base (package-with-python2 (strip-python2-variant python-oauthlib))))
2553 (native-inputs `(("python2-setuptools" ,python2-setuptools)
2554 ("python2-unittest2" ,python2-unittest2)
2555 ,@(package-native-inputs base))))))
2557 (define-public python-itsdangerous
2559 (name "python-itsdangerous")
2565 "https://pypi.python.org/packages/source/i/itsdangerous/itsdangerous-"
2569 "06856q6x675ly542ig0plbqcyab6ksfzijlyf1hzhgg3sgwgrcyb"))))
2570 (build-system python-build-system)
2571 (home-page "http://github.com/mitsuhiko/itsdangerous")
2572 (synopsis "Python library for passing data to/from untrusted environments")
2574 "Itsdangerous provides various helpers to pass trusted data to untrusted
2575 environments and back.")
2576 (license license:bsd-3)
2577 (properties `((python2-variant . ,(delay python2-itsdangerous))))))
2579 (define-public python2-itsdangerous
2580 (let ((base (package-with-python2
2581 (strip-python2-variant python-itsdangerous))))
2584 (native-inputs `(("python2-setuptools" ,python2-setuptools)
2585 ,@(package-native-inputs base))))))
2587 (define-public python-pyyaml
2589 (name "python-pyyaml")
2595 "https://pypi.python.org/packages/source/P/PyYAML/PyYAML-"
2599 "1s26125vfnskng58ym37xhwv8v0mm95b2cwbjfag8prfhy596v63"))))
2600 (build-system python-build-system)
2602 `(("libyaml" ,libyaml)))
2604 `(("python-setuptools" ,python-setuptools)))
2605 (home-page "http://pyyaml.org/wiki/PyYAML")
2606 (synopsis "YAML parser and emitter for Python")
2608 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2609 complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2610 API, and sensible error messages. PyYAML supports standard YAML tags and
2611 provides Python-specific tags that allow to represent an arbitrary Python
2613 (license license:expat)))
2615 (define-public python2-pyyaml
2616 (package-with-python2 python-pyyaml))
2618 (define-public python-virtualenv
2620 (name "python-virtualenv")
2625 (uri (pypi-uri "virtualenv" version))
2628 "07cbajzk8l05k5zhlw0b9wbf2is65bl9v6zrn2a0iyn57w6pd73d"))))
2629 (build-system python-build-system)
2632 (modify-phases %standard-phases
2635 ;; Disable failing test. See upstream bug report
2636 ;; https://github.com/pypa/virtualenv/issues/957
2637 (substitute* "tests/test_virtualenv.py"
2638 (("skipif.*") "skipif(True, reason=\"Guix\")\n"))
2639 (zero? (system* "py.test")))))))
2641 `(("python-setuptools" ,python-setuptools)
2642 ("python-mock" ,python-mock)
2643 ("python-pytest" ,python-pytest)))
2644 (home-page "https://virtualenv.pypa.io/")
2645 (synopsis "Virtual Python environment builder")
2647 "Virtualenv is a tool to create isolated Python environments.")
2648 (license license:expat)))
2650 (define-public python2-virtualenv
2651 (package-with-python2 python-virtualenv))
2653 (define-public python-markupsafe
2655 (name "python-markupsafe")
2661 "https://pypi.python.org/packages/source/M/MarkupSafe/MarkupSafe-"
2665 "1hvip33wva3fnmvfp9x5klqri7hpl1hkgqmjbss18nmrb7zimv54"))))
2666 (build-system python-build-system)
2668 `(("python-setuptools" ,python-setuptools)))
2669 (home-page "http://github.com/mitsuhiko/markupsafe")
2670 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2672 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2674 (license license:bsd-3)))
2676 (define-public python2-markupsafe
2677 (package-with-python2 python-markupsafe))
2679 (define-public python-jinja2
2681 (name "python-jinja2")
2686 (uri (pypi-uri "Jinja2" version))
2689 "1x0v41lp5m1pjix3l46zx02b7lqp2hflgpnxwkywxynvi3zz47xw"))))
2690 (build-system python-build-system)
2692 `(("python-setuptools" ,python-setuptools)
2693 ("python-markupsafe" ,python-markupsafe)))
2694 (home-page "http://jinja.pocoo.org/")
2695 (synopsis "Python template engine")
2697 "Jinja2 is a small but fast and easy to use stand-alone template engine
2698 written in pure Python.")
2699 (license license:bsd-3)))
2701 (define-public python2-jinja2
2702 (package-with-python2 python-jinja2))
2704 (define-public python-pystache
2706 (name "python-pystache")
2710 (uri (pypi-uri "pystache" version))
2713 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2714 (build-system python-build-system)
2716 `(("python-setuptools" ,python-setuptools)))
2717 (home-page "http://defunkt.io/pystache/")
2718 (synopsis "Python logic-less template engine")
2720 "Pystache is a Python implementation of the framework agnostic,
2721 logic-free templating system Mustache.")
2722 (license license:expat)))
2724 (define-public python2-pystache
2725 (package-with-python2 python-pystache))
2727 (define-public python-joblib
2729 (name "python-joblib")
2733 (uri (string-append "https://pypi.python.org/packages/source/"
2734 "j/joblib/joblib-" version ".tar.gz"))
2737 "1dvw3f8jgj6h0fxkghbgyclvdzc7l0ig7n0vis70awb5kczb9bs3"))))
2738 (build-system python-build-system)
2740 `(("python-setuptools" ,python-setuptools)
2741 ("python-nose" ,python-nose)))
2742 (home-page "http://pythonhosted.org/joblib/")
2743 (synopsis "Using Python functions as pipeline jobs")
2745 "Joblib is a set of tools to provide lightweight pipelining in Python.
2746 In particular, joblib offers: transparent disk-caching of the output values
2747 and lazy re-evaluation (memoize pattern), easy simple parallel computing
2748 logging and tracing of the execution.")
2749 (license license:bsd-3)))
2751 (define-public python2-joblib
2752 (package-with-python2 python-joblib))
2754 (define-public python-docutils
2756 (name "python-docutils")
2762 "https://pypi.python.org/packages/source/d/docutils/docutils-"
2766 "1ylnjnw1x4b2y7blr6x35ncdzn69k253kw4cdkv6asdb21w73ny7"))))
2767 (build-system python-build-system)
2769 `(("python-setuptools" ,python-setuptools)))
2771 '(#:tests? #f)) ; no setup.py test command
2772 (home-page "http://docutils.sourceforge.net/")
2773 (synopsis "Python Documentation Utilities")
2775 "Docutils is a modular system for processing documentation into useful
2776 formats, such as HTML, XML, and LaTeX. For input Docutils supports
2778 ;; Most of the source code is public domain, but some source files are
2779 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2780 (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+))))
2782 (define-public python2-docutils
2783 (package-with-python2 python-docutils))
2785 (define-public python-pygments
2787 (name "python-pygments")
2792 (uri (pypi-uri "Pygments" version))
2795 "0lagrwifsgn0s8bzqahpr87p7gd38xja8f06akscinp6hj89283k"))))
2796 (build-system python-build-system)
2798 `(("python-setuptools" ,python-setuptools)))
2799 (home-page "http://pygments.org/")
2800 (synopsis "Syntax highlighting")
2802 "Pygments is a syntax highlighting package written in Python.")
2803 (license license:bsd-2)))
2805 (define-public python2-pygments
2806 (package-with-python2 python-pygments))
2808 (define-public python-sphinx
2810 (name "python-sphinx")
2816 "https://pypi.python.org/packages/source/S/Sphinx/Sphinx-"
2820 "011xizm3jnmf4cvs5i6kgf6c5nn046h79i8j0vd0f27yw9j3p4wl"))))
2821 (build-system python-build-system)
2823 `(("python-setuptools" ,python-setuptools)
2824 ("python-jinja2" ,python-jinja2)
2825 ("python-docutils" ,python-docutils)
2826 ("python-pygments" ,python-pygments)))
2827 (home-page "http://sphinx-doc.org/")
2828 (synopsis "Python documentation generator")
2829 (description "Sphinx is a tool that makes it easy to create documentation
2830 for Python projects or other documents consisting of multiple reStructuredText
2832 (license license:bsd-3)))
2834 (define-public python2-sphinx
2835 (package-with-python2 python-sphinx))
2837 (define-public python-sphinx-rtd-theme
2839 (name "python-sphinx-rtd-theme")
2844 (uri (string-append "https://pypi.python.org/packages/source/s/"
2845 "sphinx_rtd_theme/sphinx_rtd_theme-"
2849 "19nw3rn7awplcdrz63kg1njqwkbymfg9lwn7l2grhdyhyr2gaa8g"))))
2850 (build-system python-build-system)
2852 `(;; With standard flags, the install phase attempts to create a zip'd
2853 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2855 #:configure-flags '("--single-version-externally-managed"
2856 "--record=sphinx-rtd-theme.txt")))
2858 `(("python-setuptools" ,python-setuptools)))
2860 `(("python-docutils" ,python-docutils)
2861 ("python-sphinx" ,python-sphinx)))
2862 (home-page "https://github.com/snide/sphinx_rtd_theme/")
2863 (synopsis "ReadTheDocs.org theme for Sphinx")
2864 (description "A theme for Sphinx used by ReadTheDocs.org.")
2865 (license license:expat)))
2867 (define-public python2-sphinx-rtd-theme
2868 (package-with-python2 python-sphinx-rtd-theme))
2870 (define-public python-feedgenerator
2872 (name "python-feedgenerator")
2877 (uri (pypi-uri "feedgenerator" version))
2880 "0mkimp1fpdan4p3882vzcws4l594k71ich4g0wq97jbra7p602n0"))))
2881 (build-system python-build-system)
2883 `(("python-setuptools" ,python-setuptools)
2884 ("python-pytz" ,python-pytz)
2885 ("python-six" ,python-six)))
2886 (home-page "https://github.com/getpelican/feedgenerator")
2888 "Standalone version of Django's Atom/RSS feed generator")
2890 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2891 which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
2892 (license license:bsd-3)))
2894 (define-public python2-feedgenerator
2895 (package-with-python2 python-feedgenerator))
2897 (define-public python-blinker
2899 (name "python-blinker")
2904 (uri (pypi-uri "blinker" version))
2907 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
2908 (build-system python-build-system)
2910 `(("python-setuptools" ,python-setuptools)))
2911 ;; No "test" command supplied to setuptools, so unless there's another way
2912 ;; to run tests, we're skipping them!
2913 (arguments '(#:tests? #f))
2914 (home-page "http://pythonhosted.org/blinker/")
2915 (synopsis "Fast, simple object-to-object and broadcast signaling")
2917 "Blinker provides a fast dispatching system that allows any number of
2918 interested parties to subscribe to events, or \"signals\".")
2919 (license license:expat)))
2921 (define-public python2-blinker
2922 (package-with-python2 python-blinker))
2924 (define-public pelican
2931 (uri (pypi-uri "pelican" version))
2934 "1hn94rb4q3zmcq16in055xikal4dba5hfx3zznq7warllcgc9f8k"))))
2935 (build-system python-build-system)
2937 `(("python-feedgenerator" ,python-feedgenerator)
2938 ("python-jinja2" ,python-jinja2)
2939 ("python-pygments" ,python-pygments)
2940 ("python-docutils" ,python-docutils)
2941 ("python-pytz" ,python-pytz)
2942 ("python-blinker" ,python-blinker)
2943 ("python-unidecode" ,python-unidecode)
2944 ("python-six" ,python-six)
2945 ("python-dateutil-2" ,python-dateutil-2)))
2946 (home-page "http://getpelican.com/")
2948 `(;; XXX Requires a lot more packages to do unit tests :P
2950 #:phases (modify-phases %standard-phases
2952 'install 'adjust-requires
2953 ;; Since feedgenerator is installed from git, it doesn't
2954 ;; conform to the version requirements.
2956 ;; We *do have* "feedgenerator >= 1.6", but strip off the
2957 ;; version requirement so setuptools doesn't get confused.
2959 (substitute* "setup.py"
2960 (("['\"]feedgenerator.*?['\"]")
2961 "'feedgenerator'")))))))
2962 (synopsis "Python-based static site publishing system")
2964 "Pelican is a tool to generate a static blog from reStructuredText,
2965 Markdown input files, and more. Pelican uses Jinja2 for templating
2966 and is very extensible.")
2967 (license license:agpl3+)))
2969 (define-public python-scikit-learn
2971 (name "python-scikit-learn")
2977 "https://github.com/scikit-learn/scikit-learn/archive/"
2979 (file-name (string-append name "-" version ".tar.gz"))
2982 "140skabifgc7lvvj873pnzlwx0ni6q8qkrsyad2ccjb3h8rxzkih"))))
2983 (build-system python-build-system)
2988 ;; some tests require access to "$HOME"
2989 (lambda _ (setenv "HOME" "/tmp"))
2990 ;; Tests can only be run after the library has been installed and not
2991 ;; within the source directory.
2995 (with-directory-excursion "/tmp"
2996 ;; With Python 3 one test of 3334 fails
2997 ;; (sklearn.tests.test_common.test_transformers); see
2998 ;; https://github.com/scikit-learn/scikit-learn/issues/3693
2999 (system* "nosetests" "-v" "sklearn")))
3000 (alist-delete 'check %standard-phases)))))
3002 `(("openblas" ,openblas)
3003 ("python-nose" ,python-nose)))
3005 `(("python-numpy" ,python-numpy)
3006 ("python-scipy" ,python-scipy)))
3007 (home-page "http://scikit-learn.org/")
3008 (synopsis "Machine Learning in Python")
3010 "Scikit-learn provides simple and efficient tools for data
3011 mining and data analysis.")
3012 (license license:bsd-3)
3013 (properties `((python2-variant . ,(delay python2-scikit-learn))))))
3015 (define-public python2-scikit-learn
3016 (package-with-python2 (strip-python2-variant python-scikit-learn)))
3018 (define-public python-scikit-image
3020 (name "python-scikit-image")
3026 "https://pypi.python.org/packages/source/s/scikit-image/scikit-image-"
3029 (base32 "0jz416fqvpahqyffw8plmszzfj669w8wvf3y9clnr5lr6a7md3kn"))))
3030 (build-system python-build-system)
3032 `(("python-matplotlib" ,python-matplotlib)
3033 ("python-networkx" ,python-networkx)
3034 ("python-numpy" ,python-numpy)
3035 ("python-scipy" ,python-scipy)
3036 ("python-six" ,python-six)
3037 ("python-pillow" ,python-pillow)))
3039 `(("python-cython" ,python-cython)
3040 ("python-setuptools" ,python-setuptools)))
3041 (home-page "http://scikit-image.org/")
3042 (synopsis "Image processing in Python")
3044 "Scikit-image is a collection of algorithms for image processing.")
3045 (license license:bsd-3)
3046 (properties `((python2-variant . ,(delay python2-scikit-image))))))
3048 (define-public python2-scikit-image
3049 (let ((scikit-image (package-with-python2
3050 (strip-python2-variant python-scikit-image))))
3051 (package (inherit scikit-image)
3053 `(("python2-mock" ,python2-mock)
3054 ,@(package-native-inputs scikit-image)))
3056 `(("python2-pytz" ,python2-pytz)
3057 ,@(package-propagated-inputs scikit-image))))))
3059 (define-public python-redis
3061 (name "python-redis")
3067 "https://pypi.python.org/packages/source/r/redis/redis-"
3070 (base32 "1701qjwn4n05q90fdg4bsg96s27xf5s4hsb4gxhv3xk052q3gyx4"))))
3071 (build-system python-build-system)
3072 ;; Tests require a running Redis server
3073 (arguments '(#:tests? #f))
3075 `(("python-setuptools" ,python-setuptools)
3076 ("python-pytest" ,python-pytest)))
3077 (home-page "https://github.com/andymccurdy/redis-py")
3078 (synopsis "Redis Python client")
3080 "This package provides a Python interface to the Redis key-value store.")
3081 (license license:expat)))
3083 (define-public python2-redis
3084 (package-with-python2 python-redis))
3086 (define-public python-rq
3094 "https://pypi.python.org/packages/source/r/rq/rq-"
3097 (base32 "0b0z5hn8wkfg300hx7816csgv3bcfamlr29fi3yzgqmpqxwj3fix"))))
3098 (build-system python-build-system)
3100 `(("python-click" ,python-click)
3101 ("python-redis" ,python-redis)))
3103 `(("python-setuptools" ,python-setuptools)))
3104 (home-page "http://python-rq.org/")
3105 (synopsis "Simple job queues for Python")
3107 "RQ (Redis Queue) is a simple Python library for queueing jobs and
3108 processing them in the background with workers. It is backed by Redis and it
3109 is designed to have a low barrier to entry.")
3110 (license license:bsd-2)))
3112 (define-public python2-rq
3113 (package-with-python2 python-rq))
3115 (define-public python-cython
3117 (name "python-cython")
3122 (uri (pypi-uri "Cython" version))
3125 "1fg7fmpvfcq9md4ncyqnnylyjy4z3ksdrshzis95g1sh03d8z044"))))
3126 (build-system python-build-system)
3127 ;; we need the full python package and not just the python-wrapper
3128 ;; because we need libpython3.3m.so
3130 `(("python" ,python)))
3133 (modify-phases %standard-phases
3134 (add-before 'check 'set-HOME
3135 ;; some tests require access to "$HOME/.cython"
3136 (lambda _ (setenv "HOME" "/tmp")))
3138 (lambda _ (zero? (system* "python" "runtests.py" "-vv")))))))
3139 (home-page "http://cython.org/")
3140 (synopsis "C extensions for Python")
3141 (description "Cython is an optimising static compiler for both the Python
3142 programming language and the extended Cython programming language. It makes
3143 writing C extensions for Python as easy as Python itself.")
3144 (license license:asl2.0)
3145 (properties `((python2-variant . ,(delay python2-cython))))))
3147 (define-public python2-cython
3148 (package (inherit (package-with-python2
3149 (strip-python2-variant python-cython)))
3150 (name "python2-cython")
3152 `(("python-2" ,python-2))))) ; this is not automatically changed
3154 ;; The RPython toolchain currently does not support Python 3.
3155 (define-public python2-rpython
3157 (name "python2-rpython")
3162 (uri (pypi-uri "rpython" version))
3165 "07pps06fq4c4wmi5ii0sgh9zgwniz5y7frqhm28g3a154l163fxc"))))
3166 (build-system python-build-system)
3167 (arguments `(#:python ,python-2))
3169 `(("python2-pytest" ,python2-pytest) ; needed for running tests
3170 ("python2-setuptools" ,python2-setuptools)))
3171 (home-page "https://rpython.readthedocs.org")
3172 (synopsis "Framework for implementing interpreters and virtual machines")
3173 (description "RPython is a translation and support framework for
3174 producing implementations of dynamic languages, emphasizing a clean separation
3175 between language specification and implementation aspects.")
3176 (license license:expat)))
3178 ;; This version of numpy is missing the documentation and is only used to
3179 ;; build matplotlib which is required to build numpy's documentation.
3180 (define python-numpy-bootstrap
3182 (name "python-numpy-bootstrap")
3187 (uri (string-append "mirror://sourceforge/numpy/NumPy/" version
3188 "/numpy-" version ".tar.gz"))
3191 "1bjjhvncraka5s6i4lg644jrxij6bvycxy7an20gcz3a0m11iygp"))))
3192 (build-system python-build-system)
3194 `(("python-nose" ,python-nose)
3195 ("openblas" ,openblas)
3196 ("lapack" ,lapack)))
3198 `(("gfortran" ,gfortran)))
3202 'build 'set-environment-variables
3203 (lambda* (#:key inputs #:allow-other-keys)
3204 (call-with-output-file "site.cfg"
3208 libraries = openblas
3209 library_dirs = ~a/lib
3210 include_dirs = ~a/include
3213 lapack_libs = lapack
3214 library_dirs = ~a/lib
3215 include_dirs = ~a/include
3217 (assoc-ref inputs "openblas")
3218 (assoc-ref inputs "openblas")
3219 (assoc-ref inputs "lapack")
3220 (assoc-ref inputs "lapack"))))
3221 ;; Use "gcc" executable, not "cc".
3222 (substitute* "numpy/distutils/system_info.py"
3223 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
3224 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3226 ;; Tests can only be run after the library has been installed and not
3227 ;; within the source directory.
3231 (with-directory-excursion "/tmp"
3232 (zero? (system* "python" "-c"
3233 "import numpy; numpy.test(verbose=2)"))))
3236 %standard-phases)))))
3237 (home-page "http://www.numpy.org/")
3238 (synopsis "Fundamental package for scientific computing with Python")
3239 (description "NumPy is the fundamental package for scientific computing
3240 with Python. It contains among other things: a powerful N-dimensional array
3241 object, sophisticated (broadcasting) functions, tools for integrating C/C++
3242 and Fortran code, useful linear algebra, Fourier transform, and random number
3244 (license license:bsd-3)))
3246 (define python2-numpy-bootstrap
3247 (package-with-python2 python-numpy-bootstrap))
3249 (define-public python2-fastlmm
3251 (name "python2-fastlmm")
3256 (uri (pypi-uri "fastlmm" version ".zip"))
3259 "1q8c34rpmwkfy3r4d5172pzdkpfryj561897z9r3x22gq7813x1m"))))
3260 (build-system python-build-system)
3262 `(#:python ,python-2)) ; only Python 2.7 is supported
3264 `(("python2-numpy" ,python2-numpy)
3265 ("python2-scipy" ,python2-scipy)
3266 ("python2-matplotlib" ,python2-matplotlib)
3267 ("python2-pandas" ,python2-pandas)
3268 ("python2-scikit-learn" ,python2-scikit-learn)
3269 ("python2-cython" ,python2-cython)
3270 ("python2-pysnptools" ,python2-pysnptools)))
3273 ("python2-mock" ,python2-mock)
3274 ("python2-setuptools" ,python2-setuptools)))
3275 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/fastlmm/")
3276 (synopsis "Perform genome-wide association studies on large data sets")
3278 "FaST-LMM, which stands for Factored Spectrally Transformed Linear Mixed
3279 Models, is a program for performing both single-SNP and SNP-set genome-wide
3280 association studies (GWAS) on extremely large data sets.")
3281 (license license:asl2.0)))
3283 (define-public python-numpy
3284 (package (inherit python-numpy-bootstrap)
3285 (name "python-numpy")
3286 (outputs '("out" "doc"))
3289 ("python-setuptools" ,python-setuptools)
3290 ("python-matplotlib" ,python-matplotlib)
3291 ("python-sphinx" ,python-sphinx)
3292 ("python-pyparsing" ,python-pyparsing)
3293 ("python-numpydoc" ,python-numpydoc)
3294 ,@(package-inputs python-numpy-bootstrap)))
3296 `(("pkg-config" ,pkg-config)
3297 ("texlive" ,texlive)
3298 ("texinfo" ,texinfo)
3300 ,@(package-native-inputs python-numpy-bootstrap)))
3302 `(,@(substitute-keyword-arguments
3303 (package-arguments python-numpy-bootstrap)
3306 'install 'install-doc
3307 (lambda* (#:key outputs #:allow-other-keys)
3308 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3310 data "/doc/" ,name "-"
3311 ,(package-version python-numpy-bootstrap)))
3312 (info (string-append data "/info"))
3313 (html (string-append doc "/html"))
3314 (pyver ,(string-append "PYVER=")))
3315 (with-directory-excursion "doc"
3317 (system* "make" "html" pyver)
3318 (system* "make" "latex" "PAPER=a4" pyver)
3319 (system* "make" "-C" "build/latex"
3320 "all-pdf" "PAPER=a4" pyver)
3321 ;; FIXME: Generation of the info file fails.
3322 ;; (system* "make" "info" pyver)
3324 ;; (copy-file "build/texinfo/numpy.info"
3325 ;; (string-append info "/numpy.info"))
3326 (for-each (lambda (file)
3327 (copy-file (string-append "build/latex" file)
3328 (string-append doc file)))
3329 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3330 (with-directory-excursion "build/html"
3331 (for-each (lambda (file)
3332 (let* ((dir (dirname file))
3333 (tgt-dir (string-append html "/" dir)))
3334 (unless (equal? "." dir)
3336 (install-file file html)))
3337 (find-files "." ".*"))))))
3340 (define-public python2-numpy
3341 (package-with-python2 python-numpy))
3343 (define-public python-pyparsing
3345 (name "python-pyparsing")
3350 (uri (string-append "mirror://sourceforge/pyparsing/pyparsing"
3351 "/pyparsing-" version
3352 "/pyparsing-" version ".tar.gz"))
3355 "0kw4py7gn45j93q8r7bzajfrjdc3xlsn2yzln41lf9zmrghjkrq6"))))
3356 (build-system python-build-system)
3357 (outputs '("out" "doc"))
3359 `(#:tests? #f ; no test target
3360 #:modules ((guix build python-build-system)
3364 'install 'install-doc
3365 (lambda* (#:key outputs #:allow-other-keys)
3366 (let* ((doc (string-append (assoc-ref outputs "doc")
3367 "/share/doc/" ,name "-" ,version))
3368 (html-doc (string-append doc "/html"))
3369 (examples (string-append doc "/examples")))
3375 (install-file file tgt))
3376 (find-files dir ".*")))
3377 (list "docs" "htmldoc" "examples")
3378 (list doc html-doc examples))))
3380 (home-page "http://pyparsing.wikispaces.com")
3381 (synopsis "Python parsing class library")
3383 "The pyparsing module is an alternative approach to creating and
3384 executing simple grammars, vs. the traditional lex/yacc approach, or the use
3385 of regular expressions. The pyparsing module provides a library of classes
3386 that client code uses to construct the grammar directly in Python code.")
3387 (license license:expat)))
3389 (define-public python2-pyparsing
3390 (package-with-python2 python-pyparsing))
3392 (define-public python-numpydoc
3394 (name "python-numpydoc")
3400 "https://pypi.python.org/packages/source/n/numpydoc/numpydoc-"
3404 "0d4dnifaxkll50jx6czj05y8cb4ny60njd2wz299sj2jxfy51w4k"))
3405 (modules '((guix build utils)))
3408 ;; Drop a test requiring matplotlib, which we cannot add as an
3409 ;; input since it would create a circular dependency: Extend the
3410 ;; test for Python 3, where it is already dropped, to Python 2.
3411 (substitute* "numpydoc/tests/test_plot_directive.py"
3413 (build-system python-build-system)
3415 `(("python-setuptools" ,python-setuptools)
3416 ("python-docutils" ,python-docutils)
3417 ("python-sphinx" ,python-sphinx)
3418 ("python-nose" ,python-nose)))
3419 (home-page "https://pypi.python.org/pypi/numpydoc")
3421 "Numpy's Sphinx extensions")
3423 "Sphinx extension to support docstrings in Numpy format.")
3424 (license license:bsd-2)))
3426 (define-public python2-numpydoc
3427 (package-with-python2 python-numpydoc))
3429 (define-public python-numexpr
3431 (name "python-numexpr")
3436 (uri (pypi-uri "numexpr" version))
3439 "0i6iagl2hhbr8q4qzbbjd859v5806vqylq87fq7pi914ps6d6cag"))))
3440 (build-system python-build-system)
3441 (arguments `(#:tests? #f)) ; no tests included
3443 `(("python-numpy" ,python-numpy)))
3444 (home-page "https://github.com/pydata/numexpr")
3445 (synopsis "Fast numerical expression evaluator for NumPy")
3447 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3448 expressions that operate on arrays are accelerated and use less memory than
3449 doing the same calculation in Python. In addition, its multi-threaded
3450 capabilities can make use of all your cores, which may accelerate
3451 computations, most specially if they are not memory-bounded (e.g. those using
3452 transcendental functions).")
3453 (license license:expat)
3454 (properties `((python2-variant . ,(delay python2-numexpr))))))
3456 (define-public python2-numexpr
3457 (package-with-python2 (strip-python2-variant python-numexpr)))
3459 (define-public python-matplotlib
3461 (name "python-matplotlib")
3466 (uri (string-append "mirror://sourceforge/matplotlib/matplotlib"
3467 "/matplotlib-" version
3468 "/matplotlib-" version ".tar.gz"))
3471 "1dn05cvd0g984lzhh72wa0z93psgwshbbg93fkab6slx5m3l95av"))
3472 (patches (search-patches "matplotlib-setupext-tk.patch"))))
3473 (build-system python-build-system)
3474 (outputs '("out" "doc"))
3475 (propagated-inputs ; the following packages are all needed at run time
3476 `(("python-pyparsing" ,python-pyparsing)
3477 ("python-pygobject" ,python-pygobject)
3478 ("gobject-introspection" ,gobject-introspection)
3479 ("python-tkinter" ,python "tk")
3480 ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated
3481 ;; from 'gtk+') provides the required 'typelib' files used by
3482 ;; 'gobject-introspection'. The location of these files is set with the
3483 ;; help of the environment variable GI_TYPELIB_PATH. At build time this
3484 ;; is done automatically by a 'native-search-path' procedure. However,
3485 ;; at run-time the user must set this variable as follows:
3487 ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0
3489 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3490 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3491 ;; object. For this reason we need to import both libraries.
3492 ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo
3493 ("python-pycairo" ,python-pycairo)
3494 ("python-cairocffi" ,python-cairocffi)))
3496 `(("python-setuptools" ,python-setuptools)
3497 ("python-dateutil" ,python-dateutil-2)
3498 ("python-six" ,python-six)
3499 ("python-pytz" ,python-pytz)
3500 ("python-numpy" ,python-numpy-bootstrap)
3501 ("python-sphinx" ,python-sphinx)
3502 ("python-numpydoc" ,python-numpydoc)
3503 ("python-nose" ,python-nose)
3504 ("python-mock" ,python-mock)
3506 ("imagemagick" ,imagemagick)
3507 ("freetype" ,freetype)
3510 ("python-pillow" ,python-pillow)
3511 ;; FIXME: Add backends when available.
3512 ;("python-wxpython" ,python-wxpython)
3513 ;("python-pyqt" ,python-pyqt)
3517 `(("pkg-config" ,pkg-config)
3518 ("texlive" ,texlive)
3519 ("texinfo" ,texinfo)))
3523 'build 'configure-environment
3524 (lambda* (#:key outputs inputs #:allow-other-keys)
3525 (let ((cairo (assoc-ref inputs "cairo"))
3526 (gtk+ (assoc-ref inputs "gtk+")))
3527 ;; Setting these directories in the 'basedirlist' of 'setup.cfg'
3529 (setenv "LD_LIBRARY_PATH"
3530 (string-append cairo "/lib:" gtk+ "/lib"))
3531 (setenv "HOME" (getcwd))
3532 (call-with-output-file "setup.cfg"
3534 (format port "[directories]~%
3535 basedirlist = ~a,~a~%
3538 (assoc-ref inputs "tcl")
3539 (assoc-ref inputs "tk"))))))
3541 'install 'install-doc
3542 (lambda* (#:key outputs #:allow-other-keys)
3543 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3544 (doc (string-append data "/doc/" ,name "-" ,version))
3545 (info (string-append data "/info"))
3546 (html (string-append doc "/html")))
3547 (with-directory-excursion "doc"
3548 ;; Produce pdf in 'A4' format.
3549 (substitute* (find-files "." "conf\\.py")
3550 (("latex_paper_size = 'letter'")
3551 "latex_paper_size = 'a4'"))
3554 ;; The doc recommends to run the 'html' target twice.
3555 (system* "python" "make.py" "html")
3556 (system* "python" "make.py" "html")
3557 (copy-recursively "build/html" html)
3558 (system* "python" "make.py" "latex")
3559 (system* "python" "make.py" "texinfo")
3560 (symlink (string-append html "/_images")
3561 (string-append info "/matplotlib-figures"))
3562 (with-directory-excursion "build/texinfo"
3563 (substitute* "matplotlib.texi"
3564 (("@image\\{([^,]*)" all file)
3565 (string-append "@image{matplotlib-figures/" file)))
3566 (symlink (string-append html "/_images")
3567 "./matplotlib-figures")
3568 (system* "makeinfo" "--no-split"
3569 "-o" "matplotlib.info" "matplotlib.texi"))
3570 (copy-file "build/texinfo/matplotlib.info"
3571 (string-append info "/matplotlib.info"))
3572 (copy-file "build/latex/Matplotlib.pdf"
3573 (string-append doc "/Matplotlib.pdf")))))
3574 %standard-phases))))
3575 (home-page "http://matplotlib.org")
3576 (synopsis "2D plotting library for Python")
3578 "Matplotlib is a Python 2D plotting library which produces publication
3579 quality figures in a variety of hardcopy formats and interactive environments
3580 across platforms. Matplotlib can be used in Python scripts, the python and
3581 ipython shell, web application servers, and six graphical user interface
3583 (license license:psfl)
3584 (properties `((python2-variant . ,(delay python2-matplotlib))))))
3586 (define-public python2-matplotlib
3587 (let ((matplotlib (package-with-python2
3588 (strip-python2-variant python-matplotlib))))
3589 (package (inherit matplotlib)
3590 ;; Make sure to use special packages for Python 2 instead
3591 ;; of those automatically rewritten by package-with-python2.
3593 `(("python2-pycairo" ,python2-pycairo)
3594 ("python2-pygobject-2" ,python2-pygobject-2)
3595 ("python2-tkinter" ,python-2 "tk")
3596 ,@(fold alist-delete (package-propagated-inputs matplotlib)
3597 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
3599 (define-public python2-pysnptools
3601 (name "python2-pysnptools")
3606 (uri (pypi-uri "pysnptools" version ".zip"))
3609 "1wybggjzz8zw7aav4pjsg2h22xp17a1lghrprza1pxwlm7wf96y2"))))
3610 (build-system python-build-system)
3612 `(#:python ,python-2)) ; only Python 2.7 is supported
3614 `(("python2-numpy" ,python2-numpy)
3615 ("python2-scipy" ,python2-scipy)
3616 ("python2-pytz" ,python2-pytz)
3617 ("python2-cython" ,python2-cython)))
3619 `(("python2-dateutil-2" ,python2-dateutil-2)
3620 ("python2-pandas" ,python2-pandas)
3621 ("python2-six" ,python2-six)))
3624 ("python2-setuptools" ,python2-setuptools)))
3625 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/")
3626 (synopsis "Library for reading and manipulating genetic data")
3628 "PySnpTools is a library for reading and manipulating genetic data. It
3629 can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
3630 those files. It can also efficiently manipulate ranges of integers using set
3631 operators such as union, intersection, and difference.")
3632 (license license:asl2.0)))
3634 (define-public python-rpy2
3636 (name "python-rpy2")
3641 (uri (pypi-uri "rpy2" version))
3644 "0nhan2qvrw7b7gg5zddwa22kybdv3x1g26vkd7q8lvnkgzrs4dga"))))
3645 (build-system python-build-system)
3647 `(("python-six" ,python-six)
3648 ("readline" ,readline)
3653 `(("python-setuptools" ,python-setuptools)
3655 (home-page "http://rpy.sourceforge.net/")
3656 (synopsis "Python interface to the R language")
3657 (description "rpy2 is a redesign and rewrite of rpy. It is providing a
3658 low-level interface to R from Python, a proposed high-level interface,
3659 including wrappers to graphical libraries, as well as R-like structures and
3661 (license license:gpl3+)))
3663 (define-public python2-rpy2
3664 (let ((rpy2 (package-with-python2 python-rpy2)))
3665 (package (inherit rpy2)
3667 `(("python2-singledispatch" ,python2-singledispatch)
3668 ,@(package-native-inputs rpy2))))))
3670 (define-public python-scipy
3672 (name "python-scipy")
3677 ; http://downloads.sourceforge.net/project/scipy/scipy/0.16.1/scipy-0.16.1.tar.gz
3678 (uri (string-append "mirror://sourceforge/scipy/scipy/" version
3679 "/scipy-" version ".tar.xz"))
3682 "0wa0a4skpda3gx7lb12yn19nhbairlyxrvda2lz2bcawk3x5qzz2"))))
3683 (build-system python-build-system)
3685 `(("python-numpy" ,python-numpy)
3686 ("python-matplotlib" ,python-matplotlib)
3687 ("python-pyparsing" ,python-pyparsing)))
3689 `(("lapack" ,lapack)
3690 ("openblas" ,openblas)))
3692 `(("python-nose" ,python-nose)
3693 ("python-sphinx" ,python-sphinx)
3694 ("python-numpydoc" ,python-numpydoc)
3695 ("gfortran" ,gfortran)
3696 ("texlive" ,texlive)
3698 (outputs '("out" "doc"))
3702 'build 'configure-openblas
3703 (lambda* (#:key inputs #:allow-other-keys)
3704 (call-with-output-file "site.cfg"
3708 libraries = openblas
3709 library_dirs = ~a/lib
3710 include_dirs = ~a/include
3712 library_dirs = ~a/lib
3713 atlas_libs = openblas
3715 (assoc-ref inputs "openblas")
3716 (assoc-ref inputs "openblas")
3717 (assoc-ref inputs "openblas"))))
3720 'install 'install-doc
3721 (lambda* (#:key outputs #:allow-other-keys)
3722 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3723 (doc (string-append data "/doc/" ,name "-" ,version))
3724 (html (string-append doc "/html"))
3725 (pyver ,(string-append "PYVER=")))
3726 (with-directory-excursion "doc"
3727 ;; Fix generation of images for mathematical expressions.
3728 (substitute* (find-files "source" "conf\\.py")
3729 (("pngmath_use_preview = True")
3730 "pngmath_use_preview = False"))
3732 (system* "make" "html" pyver)
3733 (system* "make" "latex" "PAPER=a4" pyver)
3734 (system* "make" "-C" "build/latex" "all-pdf" "PAPER=a4" pyver)
3735 (copy-file "build/latex/scipy-ref.pdf"
3736 (string-append doc "/scipy-ref.pdf"))
3737 (with-directory-excursion "build/html"
3738 (for-each (lambda (file)
3739 (let* ((dir (dirname file))
3740 (tgt-dir (string-append html "/" dir)))
3741 (install-file file html)))
3742 (find-files "." ".*"))))))
3743 ;; Tests can only be run after the library has been installed and not
3744 ;; within the source directory.
3748 (with-directory-excursion "/tmp"
3749 (zero? (system* "python" "-c" "import scipy; scipy.test()"))))
3755 (substitute* "scipy/integrate/tests/test_quadpack.py"
3756 (("libm.so") "libm.so.6"))
3758 %standard-phases)))))))
3759 (home-page "http://www.scipy.org/")
3760 (synopsis "The Scipy library provides efficient numerical routines")
3761 (description "The SciPy library is one of the core packages that make up
3762 the SciPy stack. It provides many user-friendly and efficient numerical
3763 routines such as routines for numerical integration and optimization.")
3764 (license license:bsd-3)))
3766 (define-public python2-scipy
3767 (package-with-python2 python-scipy))
3769 (define-public python-socksipy-branch
3771 (name "python-socksipy-branch")
3776 (uri (pypi-uri "SocksiPy-branch" version))
3779 "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p"))))
3780 (build-system python-build-system)
3782 `(#:tests? #f)) ; There are no tests
3783 (home-page "https://code.google.com/archive/p/socksipy-branch/")
3784 (synopsis "Python SOCKS module")
3786 "SocksiPy - A Python SOCKS client module. It provides a
3787 socket-like interface that supports connections to any TCP
3788 service through the use of a SOCKS4, SOCKS5 or HTTP proxy.
3789 The original version was developed by Dan Haim, this is a
3790 branch created by Mario Vilas to address some open issues,
3791 as the original project seems to have been abandoned circa 2007.")
3792 (license license:bsd-3)))
3794 (define-public python2-socksipy-branch
3795 (package-with-python2 python-socksipy-branch))
3797 (define-public python-sqlalchemy
3799 (name "python-sqlalchemy")
3804 (uri (string-append "https://pypi.python.org/packages/source/S/"
3805 "SQLAlchemy/SQLAlchemy-" version ".tar.gz"))
3808 "1l8qclhd0s90w3pvwhi5mjxdwr5j7gw7cjka2fx6f2vqmq7f4yb6"))))
3809 (build-system python-build-system)
3811 `(("python-cython" ,python-cython) ;for c extensions
3812 ("python-pytest" ,python-pytest)
3813 ("python-mock" ,python-mock))) ;for tests
3815 `(#:phases (alist-replace
3817 (lambda _ (zero? (system* "py.test")))
3819 (home-page "http://www.sqlalchemy.org")
3820 (synopsis "Database abstraction library")
3822 "SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that
3823 gives application developers the full power and flexibility of SQL. It
3824 provides a full suite of well known enterprise-level persistence patterns,
3825 designed for efficient and high-performing database access, adapted into a
3826 simple and Pythonic domain language.")
3827 (license license:x11)))
3829 (define-public python2-sqlalchemy
3830 (package-with-python2 python-sqlalchemy))
3832 (define-public python-sqlalchemy-utils
3834 (name "python-sqlalchemy-utils")
3839 (uri (pypi-uri "SQLAlchemy-Utils" version))
3842 "1zbmmh7n8m01ikizn2mj1mfwch26nsr1awv9mvskqry7av0mpy98"))))
3843 (build-system python-build-system)
3845 `(("python-six" ,python-six)
3846 ("python-sqlalchemy" ,python-sqlalchemy)))
3847 (home-page "https://github.com/kvesteri/sqlalchemy-utils")
3848 (synopsis "Various utility functions for SQLAlchemy")
3850 "SQLAlchemy-utils provides various utility functions and custom data types
3851 for SQLAlchemy. SQLAlchemy is an SQL database abstraction library for Python.")
3852 (properties `((python2-variant . ,(delay python2-sqlalchemy-utils))))
3853 (license license:bsd-3)))
3855 (define-public python2-sqlalchemy-utils
3856 (let ((base (package-with-python2
3857 (strip-python2-variant python-sqlalchemy-utils))))
3858 (package (inherit base)
3860 `(("python2-setuptools" ,python2-setuptools)
3861 ,@(package-native-inputs base))))))
3863 (define-public python-alembic
3865 (name "python-alembic")
3870 (uri (pypi-uri "alembic" version))
3873 "0ias6fdzwr2s220fnjspkdgm9510bd0cnap0hx5y4zy4srba9f3z"))))
3874 (build-system python-build-system)
3876 `(("python-mock" ,python-mock)
3877 ("python-pytest-cov" ,python-pytest-cov)))
3879 `(("python-sqlalchemy" ,python-sqlalchemy)
3880 ("python-mako" ,python-mako)
3881 ("python-editor" ,python-editor)))
3882 (home-page "http://bitbucket.org/zzzeek/alembic")
3884 "Database migration tool for SQLAlchemy")
3886 "Alembic is a lightweight database migration tool for usage with the
3887 SQLAlchemy Database Toolkit for Python.")
3888 (license license:expat)
3889 (properties `((python2-variant . ,(delay python2-alembic))))))
3891 (define-public python2-alembic
3892 (let ((alembic (package-with-python2
3893 (strip-python2-variant python-alembic))))
3896 (native-inputs `(("python2-setuptools" ,python2-setuptools)
3897 ,@(package-native-inputs alembic))))))
3899 (define-public python-distutils-extra
3901 (name "python-distutils-extra")
3906 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
3907 version "/+download/python-distutils-extra-"
3911 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
3912 (build-system python-build-system)
3914 `(("python-setuptools" ,python-setuptools)))
3915 (home-page "https://launchpad.net/python-distutils-extra/")
3916 (synopsis "Enhancements to Python's distutils")
3918 "The python-distutils-extra module enables you to easily integrate
3919 gettext support, themed icons, and scrollkeeper-based documentation into
3920 Python's distutils.")
3921 (license license:gpl2)))
3923 (define-public python2-distutils-extra
3924 (package-with-python2 python-distutils-extra))
3926 (define-public python2-elib.intl
3928 (name "python2-elib.intl")
3932 ;; This project doesn't tag releases or publish tarballs, so we take
3933 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
3936 (url "https://github.com/dieterv/elib.intl.git")
3937 (commit "d09997cfef")))
3940 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
3941 (build-system python-build-system)
3943 `(("python2-setuptools" ,python2-setuptools)))
3945 ;; incompatible with Python 3 (exception syntax)
3946 `(#:python ,python-2
3948 ;; With standard flags, the install phase attempts to create a zip'd
3949 ;; egg file, and fails with an error: 'ZIP does not support timestamps
3951 #:configure-flags '("--single-version-externally-managed"
3952 "--record=elib.txt")))
3953 (home-page "https://github.com/dieterv/elib.intl")
3954 (synopsis "Enhanced internationalization for Python")
3956 "The elib.intl module provides enhanced internationalization (I18N)
3957 services for your Python modules and applications.")
3958 (license license:lgpl3+)))
3960 (define-public python-pillow
3962 (name "python-pillow")
3967 (uri (pypi-uri "Pillow" version))
3970 "1w9x3dfrg8b5lqhpjl0fczfyf9842wbqwgxbjjq4vfpxv5jwm49l"))))
3971 (build-system python-build-system)
3973 `(("python-setuptools" ,python-setuptools)
3974 ("python-nose" ,python-nose)))
3976 `(("freetype" ,freetype)
3979 ("libjpeg" ,libjpeg)
3980 ("openjpeg" ,openjpeg)
3981 ("libtiff" ,libtiff)
3982 ("libwebp" ,libwebp)))
3984 `(;; Used at runtime for pkg_resources
3985 ("python-setuptools" ,python-setuptools)))
3987 `(#:phases (modify-phases %standard-phases
3989 'install 'disable-egg-compression
3991 ;; Leave the .egg uncompressed since compressing it would
3992 ;; prevent the GC from identifying run-time dependencies.
3993 ;; See <http://bugs.gnu.org/20765>.
3994 (let ((port (open-file "setup.cfg" "a")))
3995 (display "\n[easy_install]\nzip_ok = 0\n"
4000 'install 'check-installed
4003 (setenv "HOME" (getcwd))
4004 (and (zero? (system* "python" "selftest.py"
4006 (zero? (system* "python" "test-installed.py"))))))
4008 (home-page "https://pypi.python.org/pypi/Pillow")
4009 (synopsis "Fork of the Python Imaging Library")
4011 "The Python Imaging Library adds image processing capabilities to your
4012 Python interpreter. This library provides extensive file format support, an
4013 efficient internal representation, and fairly powerful image processing
4014 capabilities. The core image library is designed for fast access to data
4015 stored in a few basic pixel formats. It should provide a solid foundation for
4016 a general image processing tool.")
4017 (license (license:x11-style
4018 "http://www.pythonware.com/products/pil/license.htm"
4019 "The PIL Software License"))))
4021 (define-public python2-pillow
4022 (package-with-python2 python-pillow))
4024 (define-public python-pycparser
4026 (name "python-pycparser")
4031 (uri (pypi-uri "pycparser" version))
4034 "0wvzyb6rxsfj3xcnpa4ynbh9qc7rrbk2277d5wqpphmx9akv8nbr"))))
4035 (outputs '("out" "doc"))
4036 (build-system python-build-system)
4038 `(("pkg-config" ,pkg-config)
4039 ("python-setuptools" ,python-setuptools)))
4045 (with-directory-excursion "tests"
4046 (zero? (system* "python" "all_tests.py"))))
4048 'install 'install-doc
4049 (lambda* (#:key outputs #:allow-other-keys)
4050 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4051 (doc (string-append data "/doc/" ,name "-" ,version))
4052 (examples (string-append doc "/examples")))
4054 (for-each (lambda (file)
4055 (copy-file (string-append "." file)
4056 (string-append doc file)))
4057 '("/README.rst" "/CHANGES" "/LICENSE"))
4058 (copy-recursively "examples" examples)))
4059 %standard-phases))))
4060 (home-page "https://github.com/eliben/pycparser")
4061 (synopsis "C parser in Python")
4063 "Pycparser is a complete parser of the C language, written in pure Python
4064 using the PLY parsing library. It parses C code into an AST and can serve as
4065 a front-end for C compilers or analysis tools.")
4066 (license license:bsd-3)))
4068 (define-public python2-pycparser
4069 (package-with-python2 python-pycparser))
4071 (define-public python-cffi
4073 (name "python-cffi")
4078 (uri (pypi-uri "cffi" version))
4080 (base32 "161rj52rzi3880lij17d6i9kvgkiwjilrqjs8405k8sf6ryif7cg"))))
4081 (build-system python-build-system)
4082 (outputs '("out" "doc"))
4084 `(("libffi" ,libffi)))
4085 (propagated-inputs ; required at run-time
4086 `(("python-pycparser" ,python-pycparser)))
4088 `(("pkg-config" ,pkg-config)
4089 ("python-sphinx" ,python-sphinx)
4090 ("python-pytest" ,python-pytest)
4091 ("python-setuptools" ,python-setuptools)))
4095 'install 'install-doc
4096 (lambda* (#:key outputs #:allow-other-keys)
4097 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4098 (doc (string-append data "/doc/" ,name "-" ,version))
4099 (html (string-append doc "/html")))
4100 (with-directory-excursion "doc"
4101 (system* "make" "html")
4103 (copy-recursively "build/html" html))
4104 (copy-file "LICENSE" (string-append doc "/LICENSE"))))
4106 (home-page "http://cffi.readthedocs.org")
4107 (synopsis "Foreign function interface for Python")
4109 "Foreign Function Interface for Python calling C code.")
4110 (license license:expat)))
4112 (define-public python2-cffi
4113 (package-with-python2 python-cffi))
4115 (define-public python-xcffib
4117 (name "python-xcffib")
4122 (uri (string-append "https://pypi.python.org/packages/source/x/"
4123 "xcffib/xcffib-" version ".tar.gz"))
4126 "0655hzxv57h1a9ja9kwp0ichbkhf3djw32k33d66xp0q37dq2y81"))))
4127 (build-system python-build-system)
4129 `(("libxcb" ,libxcb)
4130 ("python-six" ,python-six)))
4132 `(("python-setuptools" ,python-setuptools)))
4134 `(("python-cffi" ,python-cffi))) ; used at run time
4138 'install 'install-doc
4139 (lambda* (#:key outputs #:allow-other-keys)
4140 (let ((doc (string-append (assoc-ref outputs "out") "/share"
4141 "/doc/" ,name "-" ,version)))
4143 (copy-file "README.md"
4144 (string-append doc "/README.md"))))
4146 (home-page "https://github.com/tych0/xcffib")
4147 (synopsis "XCB Python bindings")
4149 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
4150 support for Python 3 and PyPy. It is based on cffi.")
4151 (license license:expat)))
4153 (define-public python2-xcffib
4154 (package-with-python2 python-xcffib))
4156 (define-public python-cairocffi
4158 (name "python-cairocffi")
4163 ;; The archive on pypi is missing the 'utils' directory!
4164 (uri (string-append "https://github.com/SimonSapin/cairocffi/archive/v"
4166 (file-name (string-append name "-" version ".tar.gz"))
4169 "03w5p62sp3nqiccx864sbq0jvh7946277jqx3rcc3dch5xwfvv51"))))
4170 (build-system python-build-system)
4171 (outputs '("out" "doc"))
4173 `(("gdk-pixbuf" ,gdk-pixbuf)
4176 `(("pkg-config" ,pkg-config)
4177 ("python-sphinx" ,python-sphinx)
4178 ("python-docutils" ,python-docutils)
4179 ("python-setuptools" ,python-setuptools)))
4181 `(("python-xcffib" ,python-xcffib))) ; used at run time
4185 'install 'install-doc
4186 (lambda* (#:key inputs outputs #:allow-other-keys)
4187 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4188 (doc (string-append data "/doc/" ,name "-" ,version))
4189 (html (string-append doc "/html")))
4190 (setenv "LD_LIBRARY_PATH"
4191 (string-append (assoc-ref inputs "cairo") "/lib" ":"
4192 (assoc-ref inputs "gdk-pixbuf") "/lib"))
4193 (setenv "LANG" "en_US.UTF-8")
4195 (for-each (lambda (file)
4196 (copy-file (string-append "." file)
4197 (string-append doc file)))
4198 '("/README.rst" "/CHANGES" "/LICENSE"))
4199 (system* "python" "setup.py" "build_sphinx")
4200 (copy-recursively "docs/_build/html" html)))
4202 (home-page "https://github.com/SimonSapin/cairocffi")
4203 (synopsis "Python bindings and object-oriented API for Cairo")
4205 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
4206 Python bindings and object-oriented API for cairo. Cairo is a 2D vector
4207 graphics library with support for multiple backends including image buffers,
4208 PNG, PostScript, PDF, and SVG file output.")
4209 (license license:bsd-3)))
4211 (define-public python2-cairocffi
4212 (package-with-python2 python-cairocffi))
4214 (define-public python-decorator
4216 (name "python-decorator")
4221 (uri (pypi-uri "decorator" version))
4223 (base32 "1a5vwhflfd9sh3rfb40xlyipldgdzfff6brman57hqv3661jw0lh"))))
4224 (build-system python-build-system)
4225 (arguments '(#:tests? #f)) ; no test target
4227 `(("python-setuptools" ,python-setuptools)))
4228 (home-page "https://pypi.python.org/pypi/decorator/")
4229 (synopsis "Python module to simplify usage of decorators")
4231 "The aim of the decorator module is to simplify the usage of decorators
4232 for the average programmer, and to popularize decorators usage giving examples
4233 of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
4234 etc. The core of this module is a decorator factory.")
4235 (license license:expat)))
4237 (define-public python2-decorator
4238 (package-with-python2 python-decorator))
4240 (define-public python-drmaa
4242 (name "python-drmaa")
4248 "https://pypi.python.org/packages/source/d/drmaa/drmaa-"
4251 (base32 "0bzl9f9g34dlhwf09i3fdv7dqqzf2iq0w7d6c2bafx1nlap8qfbh"))))
4252 (build-system python-build-system)
4253 ;; The test suite requires libdrmaa which is provided by the cluster
4254 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
4255 ;; should be set to the path of the libdrmaa library.
4256 (arguments '(#:tests? #f))
4258 `(("python-nose" ,python-nose)
4259 ("python-setuptools" ,python-setuptools)))
4260 (home-page "https://pypi.python.org/pypi/drmaa")
4261 (synopsis "Python bindings for the DRMAA library")
4263 "A Python package for Distributed Resource Management (DRM) job
4264 submission and control. This package is an implementation of the DRMAA 1.0
4265 Python language binding specification.")
4266 (license license:bsd-3)))
4268 (define-public python2-drmaa
4269 (package-with-python2 python-drmaa))
4271 (define-public python-gridmap
4273 (name "python-gridmap")
4279 "https://github.com/pygridtools/gridmap/archive/v"
4281 (file-name (string-append name "-" version ".tar.gz"))
4283 (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x"))))
4284 (build-system python-build-system)
4286 `(("python-psutil" ,python-psutil)
4287 ("python-drmaa" ,python-drmaa)
4288 ("python-pyzmq" ,python-pyzmq)))
4290 `(("python-setuptools" ,python-setuptools)))
4291 (home-page "https://github.com/pygridtools/gridmap")
4292 (synopsis "Create jobs on a cluster directly from Python")
4294 "Gridmap is a Python package to allow you to easily create jobs on the
4295 cluster directly from Python. You can directly map Python functions onto the
4296 cluster without needing to write any wrapper code yourself.")
4297 (license license:gpl3+)))
4299 (define-public python2-gridmap
4300 (package-with-python2 python-gridmap))
4302 (define-public python-pexpect
4304 (name "python-pexpect")
4309 (uri (string-append "https://pypi.python.org/packages/source/p/"
4310 "pexpect/pexpect-" version ".tar.gz"))
4312 (base32 "1fp5gm976z7ghm8jw57463rj19cv06c8zw842prgyg788f6n3snz"))))
4313 (build-system python-build-system)
4316 (modify-phases %standard-phases
4317 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4319 `(("python-nose" ,python-nose)))
4320 (home-page "http://pexpect.readthedocs.org/")
4321 (synopsis "Controlling interactive console applications")
4323 "Pexpect is a pure Python module for spawning child applications;
4324 controlling them; and responding to expected patterns in their output.
4325 Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4326 child application and control it as if a human were typing commands.")
4327 (license license:isc)))
4329 (define-public python2-pexpect
4330 (package-with-python2 python-pexpect))
4332 (define-public python-setuptools-scm
4334 (name "python-setuptools-scm")
4338 (uri (pypi-uri "setuptools_scm" version))
4341 "1gqr73i150yzj3mz32854vj93x07yr52kn8fdckwa41ll8wgficc"))))
4342 (build-system python-build-system)
4343 (native-inputs `(("python-setuptools" ,python-setuptools)))
4344 (home-page "https://github.com/pypa/setuptools_scm/")
4345 (synopsis "Manage Python package versions in SCM metadata")
4347 "Setuptools_scm handles managing your Python package versions in
4348 @dfn{software configuration management} (SCM) metadata instead of declaring
4349 them as the version argument or in a SCM managed file.")
4350 (license license:expat)))
4352 (define-public python2-setuptools-scm
4353 (package-with-python2 python-setuptools-scm))
4355 (define-public python-pathpy
4357 (name "python-pathpy")
4362 (uri (string-append "https://pypi.python.org/packages/source/p/"
4363 "path.py/path.py-" version ".tar.gz"))
4365 (base32 "1p8s1l2vfkqhqxdhqlj0g1jjw4f1as2frr35sjcpjjpd5a89y41f"))))
4366 (build-system python-build-system)
4368 `(("python-appdirs" ,python-appdirs)))
4370 `(("python-setuptools" ,python-setuptools)
4371 ("python-setuptools-scm" ,python-setuptools-scm)
4372 ("python-pytest" ,python-pytest)
4373 ("python-pytest-runner" ,python-pytest-runner)))
4374 (home-page "http://github.com/jaraco/path.py")
4375 (synopsis "Python module wrapper for built-in os.path")
4377 "@code{path.py} implements path objects as first-class entities, allowing
4378 common operations on files to be invoked on those path objects directly.")
4379 (license license:expat)))
4381 (define-public python2-pathpy
4382 (package-with-python2 python-pathpy))
4384 (define-public python-pickleshare
4386 (name "python-pickleshare")
4391 (uri (string-append "https://pypi.python.org/packages/source/p/"
4392 "pickleshare/pickleshare-" version ".tar.gz"))
4394 (base32 "11ljr90j3p6qswdrbl7p4cjb2i93f6vn0vx9anzpshsx0d2mggn0"))))
4395 (build-system python-build-system)
4397 `(("python-pathpy" ,python-pathpy)))
4399 `(("python-setuptools" ,python-setuptools)))
4400 (home-page "https://github.com/vivainio/pickleshare")
4401 (synopsis "Tiny key value database with concurrency support")
4403 "PickleShare is a small ‘shelve’-like datastore with concurrency support.
4404 Like shelve, a PickleShareDB object acts like a normal dictionary. Unlike
4405 shelve, many processes can access the database simultaneously. Changing a
4406 value in database is immediately visible to other processes accessing the same
4407 database. Concurrency is possible because the values are stored in separate
4408 files. Hence the “database” is a directory where all files are governed by
4410 (license license:expat)))
4412 (define-public python2-pickleshare
4413 (package-with-python2 python-pickleshare))
4415 (define-public python-simplegeneric
4417 (name "python-simplegeneric")
4422 (uri (string-append "https://pypi.python.org/packages/source/s/"
4423 "simplegeneric/simplegeneric-" version ".zip"))
4425 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
4426 (build-system python-build-system)
4428 `(("python-setuptools" ,python-setuptools)
4430 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
4431 (synopsis "Python module for simple generic functions")
4433 "The simplegeneric module lets you define simple single-dispatch generic
4434 functions, akin to Python’s built-in generic functions like @code{len()},
4435 @code{iter()} and so on. However, instead of using specially-named methods,
4436 these generic functions use simple lookup tables, akin to those used by
4437 e.g. @code{pickle.dump()} and other generic functions found in the Python
4439 (license license:zpl2.1)))
4441 (define-public python2-simplegeneric
4442 (package-with-python2 python-simplegeneric))
4444 (define-public python-ipython-genutils
4446 (name "python-ipython-genutils")
4451 (uri (string-append "https://pypi.python.org/packages/source/i/"
4452 "ipython_genutils/ipython_genutils-"
4455 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
4456 (build-system python-build-system)
4457 (arguments `(#:tests? #f)) ; no tests
4458 (home-page "http://ipython.org")
4459 (synopsis "Vestigial utilities from IPython")
4461 "This package provides retired utilities from IPython.")
4462 (license license:bsd-3)))
4464 (define-public python2-ipython-genutils
4465 (package-with-python2 python-ipython-genutils))
4467 (define-public python-traitlets
4469 (name "python-traitlets")
4474 (uri (pypi-uri "traitlets" version))
4477 "1afy08sa5n9gnkvh3da49c16zkyv598vchv0p1hp7zzjy8895hz4"))))
4478 (build-system python-build-system)
4481 (modify-phases %standard-phases
4482 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4484 `(("python-ipython-genutils" ,python-ipython-genutils)
4485 ("python-decorator" ,python-decorator)))
4487 `(("python-mock" ,python-mock)
4488 ("python-nose" ,python-nose)))
4489 (home-page "http://ipython.org")
4490 (synopsis "Configuration system for Python applications")
4492 "Traitlets is a framework that lets Python classes have attributes with
4493 type checking, dynamically calculated default values, and ‘on change’
4494 callbacks. The package also includes a mechanism to use traitlets for
4495 configuration, loading values from files or from command line arguments. This
4496 is a distinct layer on top of traitlets, so you can use traitlets in your code
4497 without using the configuration machinery.")
4498 (license license:bsd-3)))
4500 (define-public python2-traitlets
4501 (package-with-python2 python-traitlets))
4503 (define-public python-jupyter-core
4505 (name "python-jupyter-core")
4510 (uri (string-append (pypi-uri "jupyter_core" version)))
4513 "177d9csqldzhsh6xs1p4nf6lzvhzyg6gklqjf69lxgxyadx87v24"))))
4514 (build-system python-build-system)
4515 ;; FIXME: not sure how to run the tests
4516 (arguments `(#:tests? #f))
4518 `(("python-traitlets" ,python-traitlets)))
4519 (home-page "http://jupyter.org/")
4520 (synopsis "Jupyter base package")
4522 "Jupyter core is the base package on which Jupyter projects rely.")
4523 (license license:bsd-3)))
4525 (define-public python2-jupyter-core
4526 (package-with-python2 python-jupyter-core))
4528 (define-public python-jupyter-client
4530 (name "python-jupyter-client")
4535 (uri (pypi-uri "jupyter_client" version))
4538 "1vjjrpjw7k5sh982pbjnslv7byfbfazjw9g92jvs7dz5qbx556n9"))))
4539 (build-system python-build-system)
4540 ;; Tests fail because of missing native python kernel which I assume is
4541 ;; provided by the ipython package, which we cannot use because it would
4542 ;; cause a dependency cycle.
4543 (arguments `(#:tests? #f))
4545 `(("python-pyzmq" ,python-pyzmq)
4546 ("python-traitlets" ,python-traitlets)
4547 ("python-jupyter-core" ,python-jupyter-core)))
4548 (home-page "http://jupyter.org/")
4549 (synopsis "Jupyter protocol implementation and client libraries")
4551 "The @code{jupyter_client} package contains the reference implementation
4552 of the Jupyter protocol. It also provides client and kernel management APIs
4553 for working with kernels, and the @code{jupyter kernelspec} entrypoint for
4554 installing @code{kernelspec}s for use with Jupyter frontends.")
4555 (license license:bsd-3)))
4557 (define-public python2-jupyter-client
4558 (package-with-python2 python-jupyter-client))
4560 (define-public python-ipython
4562 (name "python-ipython")
4567 (patches (search-patches "python-ipython-inputhook-ctype.patch"))
4568 (uri (string-append "https://pypi.python.org/packages/source/i/"
4569 "ipython/ipython-" version ".tar.gz"))
4571 (base32 "0xwin0sa9n0cabx4cq1ibf5ldsiw5dyimibla82kicz5gbpas4y9"))))
4572 (build-system python-build-system)
4573 (outputs '("out" "doc"))
4575 `(("python-pyzmq" ,python-pyzmq)
4576 ("python-terminado" ,python-terminado)))
4578 `(("readline" ,readline)
4580 ("python-matplotlib" ,python-matplotlib)
4581 ("python-numpy" ,python-numpy)
4582 ("python-numpydoc" ,python-numpydoc)
4583 ("python-jinja2" ,python-jinja2)
4584 ("python-mistune" ,python-mistune)
4585 ("python-jsonschema" ,python-jsonschema)
4586 ("python-pygments" ,python-pygments)
4587 ("python-requests" ,python-requests) ;; for tests
4588 ("python-nose" ,python-nose)))
4590 `(("pkg-config" ,pkg-config)
4591 ("python-sphinx" ,python-sphinx)
4592 ("texlive" ,texlive)
4593 ("texinfo" ,texinfo)
4594 ("python-setuptools" ,python-setuptools)))
4597 (modify-phases %standard-phases
4599 'install 'install-doc
4600 (lambda* (#:key inputs outputs #:allow-other-keys)
4601 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4602 (doc (string-append data "/doc/" ,name "-" ,version))
4603 (html (string-append doc "/html"))
4604 (man1 (string-append data "/man/man1"))
4605 (info (string-append data "/info"))
4606 (examples (string-append doc "/examples")))
4607 (setenv "LANG" "en_US.utf8")
4608 (with-directory-excursion "docs"
4609 ;; FIXME: html and pdf fail to build
4610 ;; (system* "make" "html")
4611 ;; (system* "make" "pdf" "PAPER=a4")
4612 (system* "make" "info"))
4613 (copy-recursively "docs/man" man1)
4614 (copy-recursively "examples" examples)
4615 ;; (copy-recursively "docs/build/html" html)
4616 ;; (copy-file "docs/build/latex/ipython.pdf"
4617 ;; (string-append doc "/ipython.pdf"))
4619 (copy-file "docs/build/texinfo/ipython.info"
4620 (string-append info "/ipython.info"))
4621 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))
4622 ;; Tests can only be run after the library has been installed and not
4623 ;; within the source directory.
4627 (lambda* (#:key outputs tests? #:allow-other-keys)
4629 (with-directory-excursion "/tmp"
4630 (setenv "HOME" "/tmp/") ;; required by a test
4631 (zero? (system* (string-append (assoc-ref outputs "out")
4636 (lambda* (#:key inputs #:allow-other-keys)
4637 (substitute* "./IPython/utils/_process_posix.py"
4638 (("/usr/bin/env', 'which") (which "which")))
4639 (substitute* "./IPython/core/tests/test_inputtransformer.py"
4640 (("#!/usr/bin/env python")
4641 (string-append "#!" (which "python"))))
4642 ;; Disable 1 failing test
4643 (substitute* "./IPython/core/tests/test_magic.py"
4644 (("def test_dirops\\(\\):" all)
4645 (string-append "@dec.skipif(True)\n" all))))))))
4646 (home-page "http://ipython.org")
4647 (synopsis "IPython is a tool for interactive computing in Python")
4649 "IPython provides a rich architecture for interactive computing with:
4650 Powerful interactive shells, a browser-based notebook, support for interactive
4651 data visualization, embeddable interpreters and tools for parallel
4653 (license license:bsd-3)
4654 (properties `((python2-variant . ,(delay python2-ipython))))))
4656 (define-public python2-ipython
4657 (let ((ipython (package-with-python2 (strip-python2-variant python-ipython))))
4660 ;; FIXME: some tests are failing
4662 `(#:tests? #f ,@(package-arguments ipython)))
4663 ;; FIXME: add pyreadline once available.
4665 `(("python2-mock" ,python2-mock)
4666 ,@(package-inputs ipython))))))
4668 (define-public python-isodate
4670 (name "python-isodate")
4675 (uri (pypi-uri "isodate" version))
4678 "0cafaiwixgpxwh9dsd28qb0dbzsj6xpxjdkyk30ns91ps10mq422"))))
4679 (build-system python-build-system)
4681 `(("python-setuptools" ,python-setuptools)))
4683 "http://cheeseshop.python.org/pypi/isodate")
4685 "Python date parser and formatter")
4687 "Python-isodate is a python module for parsing and formatting
4688 ISO 8601 dates, time and duration.")
4689 (license license:bsd-3)))
4691 (define-public python2-isodate
4692 (package-with-python2 python-isodate))
4694 (define-public python-html5lib
4696 (name "python-html5lib")
4701 (uri (pypi-uri "html5lib" version))
4704 "1lknq5j3nh11xrl268ks76zaj0gyzh34v94n5vbf6dk8llzxdx0q"))))
4705 (build-system python-build-system)
4707 `(("python-six" ,python-six))) ; required to "import html5lib"
4709 `(("python-setuptools" ,python-setuptools)))
4711 `(#:test-target "check"))
4713 "https://github.com/html5lib/html5lib-python")
4715 "Python HTML parser based on the WHATWG HTML specifcation")
4717 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
4718 and written in Python.")
4719 (license license:expat)))
4721 (define-public python2-html5lib
4722 (package-with-python2 python-html5lib))
4724 (define-public python-urwid
4726 (name "python-urwid")
4731 (uri (pypi-uri "urwid" version))
4734 "18cnd1wdjcas08x5qwa5ayw6jsfcn33w4d9f7q3s29fy6qzc1kng"))))
4735 (build-system python-build-system)
4738 (modify-phases %standard-phases
4739 ;; Disable failing test. Bug filed upstream:
4740 ;; https://github.com/wardi/urwid/issues/164
4741 ;; TODO: check again for python-urwid > 1.3.1 or python > 3.4.3.
4742 (add-after 'unpack 'disable-failing-test
4744 (substitute* "urwid/tests/test_event_loops.py"
4745 (("test_remove_watch_file")
4746 "disable_remove_watch_file")))))))
4747 (native-inputs `(("python-setuptools" ,python-setuptools)))
4748 (home-page "http://urwid.org")
4749 (synopsis "Console user interface library for Python")
4751 "Urwid is a curses-based UI/widget library for Python. It includes many
4752 features useful for text console applications.")
4753 (license license:lgpl2.1+)))
4755 (define-public python2-urwid
4756 (package-with-python2 python-urwid))
4758 (define-public python-urwidtrees
4760 (name "python-urwidtrees")
4765 ;; package author intends on distributing via github rather than pypi:
4766 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
4767 (uri (string-append "https://github.com/pazz/urwidtrees/archive/"
4769 (file-name (string-append name "-" version ".tar.gz"))
4772 "0d30lyd3s2a97rhqfax5w9ssqds2z6aydqx3c6j2c2lk3cb4ngvh"))))
4773 (build-system python-build-system)
4775 '(#:tests? #f)) ; no tests
4776 (inputs `(("python-urwid" ,python-urwid)))
4777 (home-page "https://github.com/pazz/urwidtrees")
4778 (synopsis "Tree widgets for urwid")
4779 (description "Urwidtrees is a Widget Container API for the @code{urwid}
4780 toolkit. Use it to build trees of widgets.")
4781 (license license:gpl3+)))
4783 (define-public python2-urwidtrees
4784 (package-with-python2 python-urwidtrees))
4786 (define-public python-dbus
4788 (name "python-dbus")
4794 "https://dbus.freedesktop.org/releases/dbus-python/dbus-python-"
4797 (base32 "1py62qir966lvdkngg0v8k1khsqxwk5m4s8nflpk1agk5f5nqb71"))))
4798 (build-system gnu-build-system)
4801 (modify-phases %standard-phases
4805 ;; XXX: For the missing '/etc/machine-id'.
4806 (substitute* "test/run-test.sh"
4807 (("DBUS_FATAL_WARNINGS=1")
4808 "DBUS_FATAL_WARNINGS=0"))
4811 `(("pkg-config" ,pkg-config)))
4813 `(("python" ,python)
4814 ("dbus-glib" ,dbus-glib)))
4815 (synopsis "Python bindings for D-bus")
4816 (description "python-dbus provides bindings for libdbus, the reference
4817 implementation of D-Bus.")
4818 (home-page "http://www.freedesktop.org/wiki/Software/DBusBindings/")
4819 (license license:expat)))
4821 (define-public python2-dbus
4822 (package (inherit python-dbus)
4823 (name "python2-dbus")
4824 (inputs `(("python" ,python-2)
4825 ,@(alist-delete "python"
4826 (package-inputs python-dbus)
4828 ;; FIXME: on Python 2, the test_utf8 fails with:
4829 ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)"
4830 (arguments `(#:tests? #f))))
4832 (define-public python-apsw
4834 (name "python-apsw")
4835 (version "3.9.2-r1")
4839 (uri (pypi-uri "apsw" version))
4842 "0w4jb0wpx785qw42r3h4fh7gl5w2968q48i7gygybsfxck8nzffs"))))
4843 (build-system python-build-system)
4845 `(("python-setuptools" ,python-setuptools)
4846 ("sqlite" ,sqlite)))
4849 ;; swap check and install phases
4852 (assoc-ref %standard-phases 'check)
4855 %standard-phases))))
4856 (home-page "https://github.com/rogerbinns/apsw/")
4857 (synopsis "Another Python SQLite Wrapper")
4858 (description "APSW is a Python wrapper for the SQLite
4859 embedded relational database engine. In contrast to other wrappers such as
4860 pysqlite it focuses on being a minimal layer over SQLite attempting just to
4861 translate the complete SQLite API into Python.")
4862 (license license:zlib)))
4864 (define-public python2-apsw
4865 (package-with-python2 python-apsw))
4867 (define-public python-lxml
4869 (name "python-lxml")
4874 (uri (pypi-uri "lxml" version))
4877 "1pvbmiy2m7jwv493kilbghhj2pkh8wy1na3ji350vhzhlwlclx4w"))))
4878 (build-system python-build-system)
4880 `(("libxml2" ,libxml2)
4881 ("libxslt" ,libxslt)
4882 ("python-setuptools" ,python-setuptools)))
4883 (home-page "http://lxml.de/")
4885 "Python XML processing library")
4887 "The lxml XML toolkit is a Pythonic binding for the C libraries
4888 libxml2 and libxslt.")
4889 (license license:bsd-3))) ; and a few more, see LICENSES.txt
4891 (define-public python2-lxml
4892 (package-with-python2 python-lxml))
4894 ;; beautifulsoup4 has a totally different namespace than 3.x,
4895 ;; and pypi seems to put it under its own name, so I guess we should too
4896 (define-public python-beautifulsoup4
4898 (name "python-beautifulsoup4")
4903 (uri (pypi-uri "beautifulsoup4" version))
4906 "1qgmhw65ncsgccjhslgkkszif47q6gvxwqv4mim17agxd81p951w"))))
4907 (build-system python-build-system)
4910 (modify-phases %standard-phases
4911 ;; The Python 2 source is the definitive source of beautifulsoup4. We
4912 ;; must use this conversion script when building with Python 3. The
4913 ;; conversion script also runs the tests.
4914 ;; For more information, see the file 'convert-py3k' in the source
4917 (lambda _ (zero? (system* "./convert-py3k")))))))
4919 "http://www.crummy.com/software/BeautifulSoup/bs4/")
4921 "Python screen-scraping library")
4923 "Beautiful Soup is a Python library designed for rapidly setting up
4924 screen-scraping projects. It offers Pythonic idioms for navigating,
4925 searching, and modifying a parse tree, providing a toolkit for
4926 dissecting a document and extracting what you need. It automatically
4927 converts incoming documents to Unicode and outgoing documents to UTF-8.")
4928 (license license:expat)
4929 (properties `((python2-variant . ,(delay python2-beautifulsoup4))))))
4931 (define-public python2-beautifulsoup4
4933 (inherit (package-with-python2
4934 (strip-python2-variant python-beautifulsoup4)))
4935 (native-inputs `(("python2-setuptools" ,python2-setuptools)))
4936 (arguments `(#:python ,python-2))))
4938 (define-public python2-cssutils
4940 (name "python2-cssutils")
4945 (uri (pypi-uri "cssutils" version))
4948 "0qwha9x1wml2qmipbcz03gndnlwhzrjdvw9i09si247a90l8p8fq"))))
4949 (build-system python-build-system)
4951 `(("python2-mock" ,python2-mock) ; for the tests
4952 ("unzip" ,unzip))) ; for unpacking the source
4954 `(("python2-setuptools" ,python2-setuptools)))
4956 `(#:python ,python-2 ; Otherwise tests fail with a syntax error.
4957 #:tests? #f ; The tests apparently download an external URL.
4959 (home-page "http://cthedot.de/cssutils/")
4961 "CSS Cascading Style Sheets library for Python")
4963 "Cssutils is a Python package for parsing and building CSS
4964 Cascading Style Sheets. Currently it provides a DOM only and no rendering
4966 (license license:lgpl3+)))
4968 (define-public python-cssselect
4970 (name "python-cssselect")
4975 (uri (pypi-uri "cssselect" version))
4978 "1xg6gbva1yswghiycmgincv6ab4bn7hpm720ndbj40h8xycmnfvi"))))
4979 (build-system python-build-system)
4981 `(("python-setuptools" ,python-setuptools)))
4983 ;; tests fail with message
4984 ;; AttributeError: 'module' object has no attribute 'tests'
4987 "https://pythonhosted.org/cssselect/")
4989 "CSS3 selector parser and translator to XPath 1.0")
4991 "Cssselect ia a Python module that parses CSS3 Selectors and translates
4992 them to XPath 1.0 expressions. Such expressions can be used in lxml or
4993 another XPath engine to find the matching elements in an XML or HTML document.")
4994 (license license:bsd-3)))
4996 (define-public python2-cssselect
4997 (package-with-python2 python-cssselect))
4999 (define-public python-netifaces
5001 (name "python-netifaces")
5007 "https://pypi.python.org/packages/source/n/netifaces/netifaces-"
5012 "1plw237a4zib4z8s62g0mrs8gm3kjfrp5sxh6bbk9nl3rdls2mln"))))
5013 (build-system python-build-system)
5015 `(("python-setuptools" ,python-setuptools)))
5017 "https://bitbucket.org/al45tair/netifaces")
5019 "Python module for portable network interface information")
5021 "Netifaces is a Python module providing information on network
5022 interfaces in an easy and portable manner.")
5023 (license license:expat)))
5025 (define-public python2-netifaces
5026 (package-with-python2 python-netifaces))
5028 (define-public python-networkx
5030 (name "python-networkx")
5035 (uri (pypi-uri "networkx" version))
5037 (base32 "1f74s56xb4ggixiq0vxyfxsfk8p20c7a099lpcf60izv1php03hd"))))
5038 (build-system python-build-system)
5039 ;; python-decorator is needed at runtime
5041 `(("python-decorator" ,python-decorator)))
5043 `(("python-setuptools" ,python-setuptools)
5044 ("python-nose" ,python-nose)))
5045 (home-page "http://networkx.github.io/")
5046 (synopsis "Python module for creating and manipulating graphs and networks")
5048 "NetworkX is a Python package for the creation, manipulation, and study
5049 of the structure, dynamics, and functions of complex networks.")
5050 (license license:bsd-3)))
5052 (define-public python2-networkx
5053 (package-with-python2 python-networkx))
5055 (define-public snakemake
5063 "https://pypi.python.org/packages/source/s/snakemake/snakemake-"
5066 (base32 "0fi4b63sj60hvi7rfydvmz2icl4wj74djw5sn2gl8hxd02qw4b91"))))
5067 (build-system python-build-system)
5068 (inputs `(("python-setuptools" ,python-setuptools)))
5069 (home-page "https://bitbucket.org/johanneskoester/snakemake")
5070 (synopsis "Python-based execution environment for make-like workflows")
5072 "Snakemake aims to reduce the complexity of creating workflows by
5073 providing a clean and modern domain specific specification language (DSL) in
5074 Python style, together with a fast and comfortable execution environment.")
5075 (license license:expat)))
5077 (define-public python-seaborn
5079 (name "python-seaborn")
5084 (uri (pypi-uri "seaborn" version))
5086 (base32 "0ibi3xsfm2kysph61mnfy0pf8d5rkgxgrdb0z9nbizgcgdsb5a0m"))))
5087 (build-system python-build-system)
5089 `(("python-pandas" ,python-pandas)
5090 ("python-matplotlib" ,python-matplotlib)
5091 ("python-scipy" ,python-scipy)))
5092 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
5093 (synopsis "Statistical data visualization")
5095 "Seaborn is a library for making attractive and informative statistical
5096 graphics in Python. It is built on top of matplotlib and tightly integrated
5097 with the PyData stack, including support for numpy and pandas data structures
5098 and statistical routines from scipy and statsmodels.")
5099 (license license:bsd-3)
5100 (properties `((python2-variant . ,(delay python2-seaborn))))))
5102 (define-public python2-seaborn
5103 (let ((base (package-with-python2 (strip-python2-variant python-seaborn))))
5106 (propagated-inputs `(("python2-pytz" ,python2-pytz)
5107 ,@(package-propagated-inputs base)))
5108 (native-inputs `(("python2-setuptools" ,python2-setuptools)
5109 ,@(package-native-inputs base))))))
5111 (define-public python-sympy
5113 (name "python-sympy")
5119 "https://github.com/sympy/sympy/releases/download/sympy-"
5120 version "/sympy-" version ".tar.gz"))
5122 (base32 "19yp0gy4i7p4g6l3b8vaqkj9qj7yqb5kqy0qgbdagpzgkdz958yz"))))
5123 (build-system python-build-system)
5125 `(("python-setuptools" ,python-setuptools)))
5126 (home-page "http://www.sympy.org/")
5127 (synopsis "Python library for symbolic mathematics")
5129 "SymPy is a Python library for symbolic mathematics. It aims to become a
5130 full-featured computer algebra system (CAS) while keeping the code as simple
5131 as possible in order to be comprehensible and easily extensible.")
5132 (license license:bsd-3)))
5134 (define-public python2-sympy
5135 (package-with-python2 python-sympy))
5137 (define-public python-q
5144 (uri (pypi-uri "q" version))
5147 "1mgfazh8fkizh6walra2zv885f3lcgr3nb02v1frfm4p8ddcy3yy"))))
5148 (build-system python-build-system)
5149 (home-page "https://github.com/zestyping/q")
5150 (synopsis "Quick-and-dirty debugging output for tired programmers")
5152 "q is a Python module for \"print\" style of debugging Python code. It
5153 provides convenient short API for print out of values, tracebacks, and
5154 falling into the Python interpreter.")
5155 (license license:asl2.0)
5156 (properties `((python2-variant . ,(delay python2-q))))))
5158 (define-public python2-q
5159 (let ((base (package-with-python2 (strip-python2-variant python-q))))
5163 `(("python2-setuptools" ,python2-setuptools)
5164 ,@(package-native-inputs base))))))
5166 (define-public python-testlib
5168 (name "python-testlib")
5174 "https://pypi.python.org/packages/source/t/testlib/testlib-"
5177 (base32 "1mz26cxn4x8bbgv0rn0mvj2z05y31rkc8009nvdlb3lam5b4mj3y"))))
5178 (build-system python-build-system)
5180 `(("python-setuptools" ,python-setuptools)))
5182 `(("unzip" ,unzip)))
5187 (lambda* (#:key inputs outputs #:allow-other-keys)
5188 (let ((unzip (string-append (assoc-ref inputs "unzip")
5190 (source (assoc-ref inputs "source")))
5191 (and (zero? (system* unzip source))
5192 (chdir (string-append "testlib-" ,version)))))
5194 (synopsis "Python micro test suite harness")
5195 (description "A micro unittest suite harness for Python.")
5196 (home-page "https://github.com/trentm/testlib")
5197 (license license:expat)))
5199 (define-public python2-testlib
5200 (package-with-python2 python-testlib))
5202 (define-public python2-xlib
5204 (name "python2-xlib")
5208 (uri (string-append "mirror://sourceforge/python-xlib/python-xlib"
5210 "python-xlib-" version ".tar.gz"))
5213 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
5214 (build-system python-build-system)
5216 `(#:python ,python-2 ;Python 2 only
5217 #:tests? #f)) ;no tests
5219 `(("python-setuptools" ,python-setuptools)))
5220 (home-page "http://python-xlib.sourceforge.net/")
5221 (synopsis "Python X11 client library")
5223 "The Python X Library is intended to be a fully functional X client
5224 library for Python programs. It is useful to implement low-level X clients.
5225 It is written entirely in Python.")
5226 (license license:gpl2+)))
5228 (define-public python-singledispatch
5230 (name "python-singledispatch")
5235 (uri (pypi-uri "singledispatch" version))
5238 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
5239 (build-system python-build-system)
5241 `(("python-setuptools" ,python-setuptools)))
5243 `(("python-six" ,python-six)))
5245 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
5246 (synopsis "Backport of singledispatch feature from Python 3.4")
5248 "This library brings functools.singledispatch from Python 3.4 to Python
5250 (license license:expat)))
5252 (define-public python2-singledispatch
5253 (package-with-python2 python-singledispatch))
5255 (define-public python-tornado
5257 (name "python-tornado")
5262 (uri (pypi-uri "tornado" version))
5264 (base32 "1gzgwayl6hmc9jfcl88bni4jcsk2jcca9dn1rvrfsvnijcjx7hn9"))))
5265 (build-system python-build-system)
5267 `(("python-certifi" ,python-certifi)))
5269 `(("python-backports-abc" ,python-backports-abc)))
5270 (home-page "http://www.tornadoweb.org/")
5271 (synopsis "Python web framework and asynchronous networking library")
5273 "Tornado is a Python web framework and asynchronous networking library,
5274 originally developed at FriendFeed. By using non-blocking network I/O,
5275 Tornado can scale to tens of thousands of open connections, making it ideal
5276 for long polling, WebSockets, and other applications that require a long-lived
5277 connection to each user.")
5278 (license license:asl2.0)
5279 (properties `((python2-variant . ,(delay python2-tornado))))))
5281 (define-public python2-tornado
5282 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
5283 (package (inherit tornado)
5285 `(("python2-backport-ssl-match-hostname"
5286 ,python2-backport-ssl-match-hostname)
5287 ("python2-singledispatch" ,python2-singledispatch)
5288 ,@(package-inputs tornado)))
5290 `(("python2-setuptools" ,python2-setuptools)
5291 ,@(package-native-inputs tornado))))))
5293 ;; the python- version can be removed with python-3.5
5294 (define-public python-backports-abc
5296 (name "python-backports-abc")
5301 (uri (pypi-uri "backports_abc" version))
5304 "19fh75lni9pb673n2fn505m1rckm0af0szcv5xx1qm1xpa940glb"))))
5305 (build-system python-build-system)
5307 `(("python-setuptools" ,python-setuptools)))
5308 (home-page "https://github.com/cython/backports_abc")
5309 (synopsis "Backport of additions to the 'collections.abc' module")
5311 "Python-backports-abc provides a backport of additions to the
5312 'collections.abc' module in Python-3.5.")
5313 (license license:psfl)))
5315 (define-public python2-backports-abc
5316 (package-with-python2 python-backports-abc))
5318 (define-public python-waf
5324 (uri (string-append "https://waf.io/"
5325 "waf-" version ".tar.bz2"))
5328 "1sl3ipi2czds57rlzjnpdzqa0skx8asfvmh3qmibpvdwf15rpppg"))))
5329 (build-system python-build-system)
5332 (modify-phases %standard-phases
5335 (zero? (system* "python" "waf-light" "configure" "build"))))
5338 (zero? (system* "python" "waf" "--version"))))
5341 (copy-file "waf" %output))))))
5342 (home-page "http://waf.io/")
5343 (synopsis "Python-based build system")
5345 "Waf is a Python-based framework for configuring, compiling and installing
5347 (license license:bsd-3)))
5349 (define-public python2-waf
5350 (package-with-python2 python-waf))
5352 (define-public python-pyzmq
5354 (name "python-pyzmq")
5359 (uri (pypi-uri "pyzmq" version))
5361 (base32 "13fhwnlvsvxv72kfhqbpn6qi7msh8mc8377mpabv32skk2cjfnxx"))))
5362 (build-system python-build-system)
5365 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
5366 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
5367 ;; --inplace' for 'python setup.py test' to work.
5370 `(("zeromq" ,zeromq)))
5372 `(("pkg-config" ,pkg-config)
5373 ("python-nose" ,python-nose)
5374 ("python-setuptools" ,python-setuptools)))
5375 (home-page "http://github.com/zeromq/pyzmq")
5376 (synopsis "Python bindings for 0MQ")
5378 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
5379 (license license:bsd-4)))
5381 (define-public python2-pyzmq
5382 (package-with-python2 python-pyzmq))
5384 (define-public python-pep8
5386 (name "python-pep8")
5391 (uri (pypi-uri "pep8" version))
5394 "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1"))))
5395 (build-system python-build-system)
5397 `(("python-setuptools" ,python-setuptools)))
5398 (home-page "http://pep8.readthedocs.org/")
5399 (synopsis "Python style guide checker")
5401 "This tools checks Python code against some of the style conventions in
5403 (license license:expat)))
5405 (define-public python2-pep8
5406 (package-with-python2 python-pep8))
5408 (define-public python-pyflakes
5410 (name "python-pyflakes")
5415 (uri (pypi-uri "pyflakes" version))
5418 "0qs2sgqszq7wcplis8509wk2ygqcrwzbs1ghfj3svvivq2j377pk"))))
5419 (build-system python-build-system)
5421 `(("python-setuptools" ,python-setuptools)))
5423 "https://github.com/pyflakes/pyflakes")
5424 (synopsis "Passive checker of Python programs")
5426 "Pyflakes statically checks Python source code for common errors.")
5427 (license license:expat)))
5429 (define-public python2-pyflakes
5430 (package-with-python2 python-pyflakes))
5432 (define-public python-mccabe
5434 (name "python-mccabe")
5439 (uri (pypi-uri "mccabe" version))
5442 "0yr08a36h8lqlif10l4xcikbbig7q8f41gqywir7rrvnv3mi4aws"))))
5443 (build-system python-build-system)
5445 `(("python-pytest" ,python-pytest)
5446 ("python-pytest-runner" ,python-pytest-runner)
5447 ("python-setuptools" ,python-setuptools)))
5448 (home-page "https://github.com/flintwork/mccabe")
5449 (synopsis "McCabe checker, plugin for flake8")
5451 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
5452 complexity of Python source code.")
5453 (license license:expat)))
5455 (define-public python2-mccabe
5456 (package-with-python2 python-mccabe))
5458 (define-public python-mccabe-0.2.1
5459 (package (inherit python-mccabe)
5464 (uri (pypi-uri "mccabe" version))
5467 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))
5468 (inputs `(("python-setuptools" ,python-setuptools)))))
5470 (define-public python2-mccabe-0.2.1
5471 (package-with-python2 python-mccabe-0.2.1))
5473 ;; Flake8 2.4.1 requires an older version of pep8.
5474 ;; This should be removed ASAP.
5475 (define-public python-pep8-1.5.7
5476 (package (inherit python-pep8)
5482 "https://pypi.python.org/packages/source/p/pep8/pep8-"
5487 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))))
5489 (define-public python2-pep8-1.5.7
5490 (package-with-python2 python-pep8-1.5.7))
5492 ;; Flake8 2.4.1 requires an older version of pyflakes.
5493 ;; This should be removed ASAP.
5494 (define-public python-pyflakes-0.8.1
5495 (package (inherit python-pyflakes)
5501 "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-"
5506 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))))
5508 (define-public python2-pyflakes-0.8.1
5509 (package-with-python2 python-pyflakes-0.8.1))
5511 (define-public python-flake8
5513 (name "python-flake8")
5518 (uri (pypi-uri "flake8" version))
5521 "0bs9cz4fr99r2rwig1b8jwaadl1nan7kgpdzqwj0bwbckwbmh7nc"))))
5522 (build-system python-build-system)
5524 `(("python-setuptools" ,python-setuptools)
5525 ("python-pep8" ,python-pep8)
5526 ("python-pyflakes" ,python-pyflakes)
5527 ("python-mccabe" ,python-mccabe)
5528 ("python-mock" ,python-mock)
5529 ("python-nose" ,python-nose)))
5530 (home-page "https://gitlab.com/pycqa/flake8")
5532 "The modular source code checker: pep8, pyflakes and co")
5534 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
5535 (license license:expat)))
5537 (define-public python2-flake8
5538 (package-with-python2 python-flake8))
5540 ;; This will only be needed by the python-hacking package and will not be
5541 ;; necessary once python-hacking > 0.10.2 is released.
5542 (define-public python-flake8-2.2.4
5543 (package (inherit python-flake8)
5545 `(("python-setuptools" ,python-setuptools)
5546 ("python-pep8" ,python-pep8-1.5.7)
5547 ("python-pyflakes" ,python-pyflakes-0.8.1)
5548 ("python-mccabe" ,python-mccabe-0.2.1)
5549 ("python-mock" ,python-mock)
5550 ("python-nose" ,python-nose)))
5555 (uri (pypi-uri "flake8" version))
5558 "1r9wsry4va45h1rck5hxd3vzsg2q3y6lnl6pym1bxvz8ry19jwx8"))))))
5560 (define-public python2-flake8-2.2.4
5561 (package-with-python2 python-flake8-2.2.4))
5563 (define-public python-mistune
5565 (name "python-mistune")
5571 "https://pypi.python.org/packages/source/m/mistune/mistune-"
5576 "17zqjp9m4d1w3jf2rbbq5xshcw24q1vlcv24gkgfqqyyymajxahx"))))
5577 (build-system python-build-system)
5579 `(("python-setuptools" ,python-setuptools)
5580 ("python-nose" ,python-nose)
5581 ("python-cython" ,python-cython)))
5582 (home-page "https://github.com/lepture/mistune")
5583 (synopsis "Markdown parser in pure Python")
5584 (description "This package provides a fast markdown parser in pure
5586 (license license:bsd-3)))
5588 (define-public python2-mistune
5589 (package-with-python2 python-mistune))
5591 (define-public python-markdown
5593 (name "python-markdown")
5598 (uri (pypi-uri "Markdown" version))
5601 "0q758a3fiiawr20b3hhjfs677cwj6xi284yb7xspcvv0fdicz54d"))))
5602 (build-system python-build-system)
5605 (modify-phases %standard-phases
5608 (zero? (system* "python" "run-tests.py")))))))
5610 `(("python-nose" ,python-nose)
5611 ("python-pyyaml" ,python-pyyaml)))
5612 (home-page "https://pythonhosted.org/Markdown/")
5613 (synopsis "Python implementation of Markdown")
5615 "This package provides a Python implementation of John Gruber's
5616 Markdown. The library features international input, various Markdown
5617 extensions, and several HTML output formats. A command line wrapper
5618 markdown_py is also provided to convert Markdown files to HTML.")
5619 (license license:bsd-3)))
5621 (define-public python2-markdown
5622 (package-with-python2 python-markdown))
5624 (define-public python-ptyprocess
5626 (name "python-ptyprocess")
5632 "https://pypi.python.org/packages/source/p/ptyprocess/ptyprocess-"
5636 "0nggns5kikn32yyda2zrj1xdmh49pi3v0drggcdwljbv36r8zdyw"))))
5637 (build-system python-build-system)
5639 `(("python-setuptools" ,python-setuptools)
5640 ("python-nose" ,python-nose)))
5643 (modify-phases %standard-phases
5646 (zero? (system* "nosetests")))))))
5647 (home-page "https://github.com/pexpect/ptyprocess")
5648 (synopsis "Run a subprocess in a pseudo terminal")
5650 "This package provides a Python library used to launch a subprocess in a
5651 pseudo terminal (pty), and interact with both the process and its pty.")
5652 (license license:isc)))
5654 (define-public python2-ptyprocess
5655 (package-with-python2 python-ptyprocess))
5657 (define-public python-terminado
5659 (name "python-terminado")
5664 (uri (pypi-uri "terminado" version))
5667 "09h1kwi86g5mrk14s4pgbhshd602zry29lnpxamcqz864kva22rc"))))
5668 (build-system python-build-system)
5670 `(("python-tornado" ,python-tornado)
5671 ("python-ptyprocess" ,python-ptyprocess)))
5673 `(("python-nose" ,python-nose)))
5676 (modify-phases %standard-phases
5679 (zero? (system* "nosetests")))))))
5680 (home-page "https://github.com/takluyver/terminado")
5681 (synopsis "Terminals served to term.js using Tornado websockets")
5682 (description "This package provides a Tornado websocket backend for the
5683 term.js Javascript terminal emulator library.")
5684 (license license:bsd-2)
5685 (properties `((python2-variant . ,(delay python2-terminado))))))
5687 (define-public python2-terminado
5688 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
5689 (package (inherit terminado)
5691 `(("python2-backport-ssl-match-hostname"
5692 ,python2-backport-ssl-match-hostname)
5693 ,@(package-propagated-inputs terminado)))
5695 `(("python2-setuptools" ,python2-setuptools)
5696 ,@(package-native-inputs terminado))))))
5698 (define-public python-fonttools
5700 (name "python-fonttools")
5705 "https://pypi.python.org/packages/source/F/FontTools/"
5706 "fonttools-" version ".tar.gz"))
5709 "08ay3x4ijarwhl60gqx2i9jzq6pxs20p4snc2d1q5jagh4rn39lb"))))
5710 (build-system python-build-system)
5711 (arguments '(#:test-target "check"))
5713 ;; XXX: module not found if setuptools is not available.
5714 `(("python-setuptools" ,python-setuptools)))
5715 (home-page "http://github.com/behdad/fonttools")
5716 (synopsis "Tools to manipulate font files")
5718 "FontTools/TTX is a library to manipulate font files from Python. It
5719 supports reading and writinfg of TrueType/OpenType fonts, reading and writing
5720 of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
5721 also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
5722 from an XML-based format.")
5723 (license (license:non-copyleft
5724 "file://LICENSE.txt"
5725 "See LICENSE.txt in the distribution."))))
5727 (define-public python2-fonttools
5728 (package-with-python2 python-fonttools))
5730 (define-public python-ly
5737 (uri (string-append "https://pypi.python.org/packages/57/4f/"
5738 "889579244947368f28eda66b782331b1e75f83fd72e63f9ece93cd7a18f9"
5739 "/python-ly-" version ".tar.gz"))
5742 "0g6n288l83sfwavxh1aryi0aqvsr3sp7v6f903mckwqa4scpky62"))))
5743 (build-system python-build-system)
5745 `(("python-setuptools" ,python-setuptools)))
5746 (synopsis "Tool and library for manipulating LilyPond files")
5747 (description "This package provides a Python library to parse, manipulate
5748 or create documents in LilyPond format. A command line program ly is also
5749 provided that can be used to do various manipulations with LilyPond files.")
5750 (home-page "https://pypi.python.org/pypi/python-ly")
5751 (license license:gpl2+)))
5753 (define-public python-appdirs
5755 (name "python-appdirs")
5761 "https://pypi.python.org/packages/source/a/appdirs/appdirs-"
5766 "1iddva7v3fq0aqzsahkazxr7vpw28mqcrsy818z4wyiqnkplbhlg"))))
5767 (build-system python-build-system)
5769 `(("python-setuptools" ,python-setuptools)))
5770 (home-page "http://github.com/ActiveState/appdirs")
5772 "Determine platform-specific dirs, e.g. a \"user data dir\"")
5774 "This module provides a portable way of finding out where user data
5775 should be stored on various operating systems.")
5776 (license license:expat)))
5778 (define-public python2-appdirs
5779 (package-with-python2 python-appdirs))
5781 (define-public python-llfuse
5783 (name "python-llfuse")
5788 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5789 "llfuse-" version ".tar.bz2"))
5792 "0v6vj9mb286njgd1szg9hz2qdh5f3vkhsvajripfcqg458av310v"))))
5793 (build-system python-build-system)
5798 `(("pkg-config" ,pkg-config)
5799 ("python-setuptools" ,python-setuptools)))
5800 (synopsis "Python bindings for FUSE")
5802 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
5803 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
5804 (license license:lgpl2.0+)
5805 (properties `((python2-variant . ,(delay python2-llfuse))))))
5807 (define-public python2-llfuse
5808 (package (inherit (package-with-python2
5809 (strip-python2-variant python-llfuse)))
5810 (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2)))))
5813 (define-public python-llfuse-0.41
5814 (package (inherit python-llfuse)
5819 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5820 "llfuse-" version ".tar.bz2"))
5823 "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa"))))
5824 ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat)
5825 ;; licensed. The rest of the package is licensed under LGPL2.0 or later.
5826 (license (list license:expat license:lgpl2.0+))))
5828 (define-public python-msgpack
5830 (name "python-msgpack")
5834 (uri (pypi-uri "msgpack-python" version))
5837 "11pqk5braa6wndpnr1dhg64js82vjgxnm0lzy73rwl831zgijaqs"))))
5838 (build-system python-build-system)
5839 (synopsis "MessagePack (de)serializer")
5840 (description "MessagePack is a fast, compact binary serialization format,
5841 suitable for similar data to JSON. This package provides CPython bindings for
5842 reading and writing MessagePack data.")
5843 (home-page "https://pypi.python.org/pypi/msgpack-python/")
5844 (license license:asl2.0)
5845 (properties `((python2-variant . ,(delay python2-msgpack))))))
5847 (define-public python2-msgpack
5848 (package (inherit (package-with-python2
5849 (strip-python2-variant python-msgpack)))
5851 `(("python2-setuptools" ,python2-setuptools)))))
5853 (define-public python-netaddr
5855 (name "python-netaddr")
5861 "https://pypi.python.org/packages/source/n/netaddr/netaddr-"
5866 "06dxjlbcicq7q3vqy8agq11ra01kvvd47j4mk6dmghjsyzyckxd1"))))
5867 (build-system python-build-system)
5868 (arguments `(#:tests? #f)) ;; No tests.
5870 `(("python-setuptools" ,python-setuptools)))
5871 (home-page "https://github.com/drkjam/netaddr/")
5872 (synopsis "Pythonic manipulation of network addresses")
5874 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
5875 and MAC network addresses.")
5876 (license license:bsd-3)))
5878 (define-public python2-netaddr
5879 (package-with-python2 python-netaddr))
5881 (define-public python-wrapt
5883 (name "python-wrapt")
5889 "https://pypi.python.org/packages/source/w/wrapt/wrapt-"
5894 "0cq8rlpzkxzk48b50yrfhzn1d1hrq4gjcdqlrgq4v5palgiv9jwr"))))
5895 (build-system python-build-system)
5897 ;; Tests are not included in the tarball, they are only available in the
5901 `(("python-setuptools" ,python-setuptools)))
5902 (home-page "https://github.com/GrahamDumpleton/wrapt")
5903 (synopsis "Module for decorators, wrappers and monkey patching")
5905 "The aim of the wrapt module is to provide a transparent object proxy for
5906 Python, which can be used as the basis for the construction of function
5907 wrappers and decorator functions.")
5908 (license license:bsd-2)))
5910 (define-public python2-wrapt
5911 (package-with-python2 python-wrapt))
5913 (define-public python-iso8601
5915 (name "python-iso8601")
5920 (uri (pypi-uri "iso8601" version))
5923 "0c7gh3lsdjds262h0v1sqc66l7hqgfwbakn96qrhdbl0i3vm5yz8"))))
5924 (build-system python-build-system)
5926 `(("python-setuptools" ,python-setuptools)))
5927 (home-page "https://bitbucket.org/micktwomey/pyiso8601")
5928 (synopsis "Module to parse ISO 8601 dates")
5930 "This module parses the most common forms of ISO 8601 date strings (e.g.
5931 @code{2007-01-14T20:34:22+00:00}) into @code{datetime} objects.")
5932 (license license:expat)))
5934 (define-public python2-iso8601
5935 (package-with-python2 python-iso8601))
5937 (define-public python-monotonic
5939 (name "python-monotonic")
5945 "https://pypi.python.org/packages/source/m/monotonic/monotonic-"
5950 "0yz0bcbwx8r2c01czzfpbrxddynxyk9k95jj8h6sgcb7xmfvl998"))))
5951 (build-system python-build-system)
5953 `(("python-setuptools" ,python-setuptools)))
5954 (home-page "https://github.com/atdt/monotonic")
5955 (synopsis "Implementation of time.monotonic() for Python 2 & < 3.3")
5957 "This module provides a monotonic() function which returns the value (in
5958 fractional seconds) of a clock which never goes backwards.")
5959 (license license:asl2.0)))
5961 (define-public python2-monotonic
5962 (package-with-python2 python-monotonic))
5964 (define-public python-webob
5966 (name "python-webob")
5971 (uri (pypi-uri "WebOb" version))
5974 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
5975 (build-system python-build-system)
5977 `(("python-nose" ,python-nose)
5978 ("python-setuptools" ,python-setuptools)))
5979 (home-page "http://webob.org/")
5980 (synopsis "WSGI request and response object")
5982 "WebOb provides wrappers around the WSGI request environment, and an
5983 object to help create WSGI responses.")
5984 (license license:expat)))
5986 (define-public python2-webob
5987 (package-with-python2 python-webob))
5989 (define-public python-xlrd
5991 (name "python-xlrd")
5995 (uri (pypi-uri "xlrd" version))
5998 "0s8hjiz01vbhy85xalrz0qlsmd9ypf36zjqrf97hh984spapvy0g"))))
5999 (build-system python-build-system)
6002 (modify-phases %standard-phases
6003 ;; Current test in setup.py does not work as of 1.0.0, so use nose to
6004 ;; run tests instead for now.
6005 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
6006 (native-inputs `(("python-nose" ,python-nose)
6007 ("python-setuptools" ,python-setuptools)))
6008 (home-page "http://www.python-excel.org/")
6009 (synopsis "Library for extracting data from Excel files")
6010 (description "This packages provides a library to extract data from
6011 spreadsheets using Microsoft Excel proprietary file formats @samp{.xls} and
6012 @samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
6013 Unicode-aware. It is not intended as an end-user tool.")
6014 (license license:bsd-3)))
6016 (define-public python2-xlrd
6017 (package-with-python2 python-xlrd))
6019 (define-public python-prettytable
6021 (name "python-prettytable")
6027 "https://pypi.python.org/packages/source/P/PrettyTable/"
6028 "prettytable-" version ".tar.bz2"))
6031 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
6032 (build-system python-build-system)
6034 `(("python-setuptools" ,python-setuptools)))
6035 (home-page "http://code.google.com/p/prettytable/")
6036 (synopsis "Display tabular data in an ASCII table format")
6038 "A library designed to represent tabular data in visually appealing ASCII
6039 tables. PrettyTable allows for selection of which columns are to be printed,
6040 independent alignment of columns (left or right justified or centred) and
6041 printing of sub-tables by specifying a row range.")
6042 (license license:bsd-3)))
6044 (define-public python2-prettytable
6045 (package-with-python2 python-prettytable))
6047 (define-public python-tables
6049 (name "python-tables")
6054 (uri (pypi-uri "tables" version))
6057 "117s6w7s3yxafpmf3zz3svana7xfrsviw01va1xp7h8ylx8v6r1m"))))
6058 (build-system python-build-system)
6060 `(;; FIXME: python-build-system does not pass configure-flags to "build"
6061 ;; or "check", so we must override the build and check phases.
6063 (modify-phases %standard-phases
6064 (add-after 'unpack 'use-gcc
6066 (substitute* "setup.py"
6067 (("compiler = new_compiler\\(\\)" line)
6069 "\ncompiler.set_executables(compiler='gcc',"
6070 "compiler_so='gcc',"
6072 "linker_so='gcc -shared')")))
6075 (lambda* (#:key inputs #:allow-other-keys)
6076 (zero? (system* "python" "setup.py" "build"
6077 (string-append "--hdf5="
6078 (assoc-ref inputs "hdf5"))))))
6080 (lambda* (#:key inputs #:allow-other-keys)
6081 (zero? (system* "python" "setup.py" "check"
6082 (string-append "--hdf5="
6083 (assoc-ref inputs "hdf5")))))))))
6085 `(("python-numexpr" ,python-numexpr)
6086 ("python-numpy" ,python-numpy)))
6088 `(("python-setuptools" ,python-setuptools)
6089 ("python-cython" ,python-cython)
6090 ("pkg-config" ,pkg-config)))
6095 (home-page "http://www.pytables.org/")
6096 (synopsis "Hierarchical datasets for Python")
6097 (description "PyTables is a package for managing hierarchical datasets and
6098 designed to efficently cope with extremely large amounts of data.")
6099 (license license:bsd-3)))
6101 (define-public python2-tables
6102 (package-with-python2 python-tables))
6104 (define-public python-pyasn1
6106 (name "python-pyasn1")
6111 (uri (pypi-uri "pyasn1" version))
6114 "0zraxni14bqi20kr4bi6nwsh32aibz0fq0xaczfisw0zdpcsqg45"))))
6115 (build-system python-build-system)
6116 (home-page "http://pyasn1.sourceforge.net/")
6117 (synopsis "ASN.1 types and codecs")
6119 "This is an implementation of ASN.1 types and codecs in Python. It is
6120 suitable for a wide range of protocols based on the ASN.1 specification.")
6121 (license license:bsd-2)))
6123 (define-public python2-pyasn1
6124 (package-with-python2 python-pyasn1))
6126 (define-public python-pyasn1-modules
6128 (name "python-pyasn1-modules")
6133 (uri (pypi-uri "pyasn1-modules" version))
6136 "0drqgw81xd3fxdlg89kgd79zzrabvfncvkbybi2wr6w2y4s1jmhh"))))
6137 (build-system python-build-system)
6139 `(("python-setuptools" ,python-setuptools)))
6141 `(("python-pyasn1" ,python-pyasn1)))
6142 (home-page "http://sourceforge.net/projects/pyasn1/")
6143 (synopsis "ASN.1 codec implementations")
6145 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
6146 implementations of ASN.1-based codecs and protocols.")
6147 (license license:bsd-3)))
6149 (define-public python2-pyasn1-modules
6150 (package-with-python2 python-pyasn1-modules))
6152 (define-public python-ipaddress
6154 (name "python-ipaddress")
6158 (uri (pypi-uri "ipaddress" version))
6161 "1c3imabdrw8nfksgjjflzg7h4ynjckqacb188rf541m74arq4cas"))))
6162 (build-system python-build-system)
6163 (home-page "https://github.com/phihag/ipaddress")
6164 (synopsis "IP address manipulation library")
6166 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
6167 in Python. This library is used to create, poke at, and manipulate IPv4 and
6168 IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
6169 module to older versions of Python.")
6170 (license license:psfl)
6171 (properties `((python2-variant . ,(delay python2-ipaddress))))))
6173 (define-public python2-ipaddress
6174 (let ((base (package-with-python2 (strip-python2-variant python-ipaddress))))
6175 (package (inherit base)
6177 `(("python2-setuptools" ,python2-setuptools)
6178 ,@(package-native-inputs base))))))
6180 (define-public python2-ipaddr
6182 (name "python2-ipaddr")
6187 (uri (pypi-uri "ipaddr" version))
6189 (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v"))))
6190 (build-system python-build-system)
6192 `(#:python ,python-2 ;version 2 only
6194 (modify-phases %standard-phases
6197 (zero? (system* "python" "ipaddr_test.py")))))))
6198 (home-page "https://github.com/google/ipaddr-py")
6199 (synopsis "IP address manipulation library")
6201 "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and
6202 IPv6 addresses and networks.
6204 For new implementations you may prefer to use the standard module
6205 @code{ipaddress}, which was introduced in Python 3.3 and backported to older
6206 versions of Python.")
6207 (license license:asl2.0)))
6209 (define-public python-idna
6211 (name "python-idna")
6216 (uri (string-append "https://pypi.python.org/packages/source/i/"
6217 "idna/idna-" version ".tar.gz"))
6220 "0frxgmgi234lr9hylg62j69j4ik5zhg0wz05w5dhyacbjfnrl68n"))))
6221 (build-system python-build-system)
6223 `(("python-setuptools" ,python-setuptools)))
6224 (home-page "https://github.com/kjd/idna")
6225 (synopsis "Internationalized domain names in applications")
6227 "This is a library to support the Internationalised Domain Names in
6228 Applications (IDNA) protocol as specified in RFC 5891. This version of the
6229 protocol is often referred to as “IDNA2008” and can produce different results
6230 from the earlier standard from 2003. The library is also intended to act as a
6231 suitable drop-in replacement for the “encodings.idna” module that comes with
6232 the Python standard library but currently only supports the older 2003
6234 (license license:bsd-4)))
6236 (define-public python2-idna
6237 (package-with-python2 python-idna))
6239 (define-public python-pretend
6241 (name "python-pretend")
6246 (uri (string-append "https://pypi.python.org/packages/source/p/"
6247 "pretend/pretend-" version ".tar.gz"))
6250 "0r5r7ygz9m6d2bklflbl84cqhjkc2q12xgis8268ygjh30g2q3wk"))))
6251 (build-system python-build-system)
6253 `(("python-setuptools" ,python-setuptools)))
6254 (home-page "https://github.com/alex/pretend")
6255 (synopsis "Library for stubbing in Python")
6257 "Pretend is a library to make stubbing with Python easier. Stubbing is a
6258 technique for writing tests. You may hear the term mixed up with mocks,
6259 fakes, or doubles. Basically, a stub is an object that returns pre-canned
6260 responses, rather than doing any computation.")
6261 (license license:bsd-3)))
6263 (define-public python2-pretend
6264 (package-with-python2 python-pretend))
6266 (define-public python-cryptography-vectors
6268 (name "python-cryptography-vectors")
6273 (uri (pypi-uri "cryptography_vectors" version))
6276 "15h1iz2klnpb4f8djxy7cpbnyn3wbjp7bnj4pz6s7w6plghbq524"))))
6277 (build-system python-build-system)
6279 `(("python-setuptools" ,python-setuptools)))
6280 (home-page "https://github.com/pyca/cryptography")
6281 (synopsis "Test vectors for the cryptography package")
6283 "This package contains test vectors for the cryptography package.")
6284 ;; Distributed under either BSD-3 or ASL2.0
6285 (license (list license:bsd-3 license:asl2.0))))
6287 (define-public python2-cryptography-vectors
6288 (package-with-python2 python-cryptography-vectors))
6290 (define-public python-cryptography
6292 (name "python-cryptography")
6297 (uri (pypi-uri "cryptography" version))
6300 "1a85l548w5vvq3yhz0az7ajg2ijixzp6gagapw6wgrqvq28ghgs2"))))
6301 (build-system python-build-system)
6303 `(("openssl" ,openssl)))
6305 `(("python-cffi" ,python-cffi)
6306 ("python-six" ,python-six)
6307 ("python-pyasn1" ,python-pyasn1)
6308 ("python-idna" ,python-idna)
6309 ("python-iso8601" ,python-iso8601)))
6311 `(("python-cryptography-vectors" ,python-cryptography-vectors)
6312 ("python-hypothesis" ,python-hypothesis)
6313 ("python-setuptools" ,python-setuptools)
6314 ("python-pretend" ,python-pretend)
6315 ("python-pyasn1" ,python-pyasn1)
6316 ("python-pyasn1-modules" ,python-pyasn1-modules)
6317 ("python-pytest" ,python-pytest)))
6318 (home-page "https://github.com/pyca/cryptography")
6319 (synopsis "Cryptographic recipes and primitives for Python")
6321 "cryptography is a package which provides cryptographic recipes and
6322 primitives to Python developers. It aims to be the “cryptographic standard
6323 library” for Python. The package includes both high level recipes, and low
6324 level interfaces to common cryptographic algorithms such as symmetric ciphers,
6325 message digests and key derivation functions.")
6326 ;; Distributed under either BSD-3 or ASL2.0
6327 (license (list license:bsd-3 license:asl2.0))
6328 (properties `((python2-variant . ,(delay python2-cryptography))))))
6330 (define-public python2-cryptography
6331 (let ((crypto (package-with-python2
6332 (strip-python2-variant python-cryptography))))
6333 (package (inherit crypto)
6335 `(("python2-ipaddress" ,python2-ipaddress)
6336 ("python2-backport-ssl-match-hostname"
6337 ,python2-backport-ssl-match-hostname)
6338 ("python2-enum34" ,python2-enum34)
6339 ,@(package-propagated-inputs crypto))))))
6341 (define-public python-pyopenssl
6343 (name "python-pyopenssl")
6348 (uri (pypi-uri "pyOpenSSL" version))
6351 "0prm06zz7hl6bk5s2lqzw25lq6smayfv2fgiliw2rbqxlyiavxw8"))))
6352 (build-system python-build-system)
6354 `(("python-cryptography" ,python-cryptography)
6355 ("python-six" ,python-six)))
6357 `(("openssl" ,openssl)))
6359 `(("python-setuptools" ,python-setuptools)))
6360 (home-page "https://github.com/pyca/pyopenssl")
6361 (synopsis "Python wrapper module around the OpenSSL library")
6363 "PyOpenSSL is a high-level wrapper around a subset of the OpenSSL
6365 (license license:asl2.0)))
6367 (define-public python2-pyopenssl
6368 (package-with-python2 python-pyopenssl))
6370 (define-public python-pip
6377 (uri (pypi-uri "pip" version))
6380 "08cm8d4228fj0qnrysy3qv1a6022zr3dcs25amd14lgxil6vvx26"))))
6381 (build-system python-build-system)
6383 `(("python-setuptools" ,python-setuptools)
6384 ("python-virtualenv" ,python-virtualenv)
6386 ("python-mock" ,python-mock)
6387 ("python-pytest" ,python-pytest)
6388 ("python-scripttest" ,python-scripttest)))
6389 (home-page "https://pip.pypa.io/")
6391 "Package manager for Python software")
6393 "Pip is a package manager for Python software, that finds packages on the
6394 Python Package Index (PyPI).")
6395 (license license:expat)))
6397 (define-public python2-pip
6398 (package-with-python2 python-pip))
6400 (define-public python-tlsh
6402 (name "python-tlsh")
6404 (home-page "https://github.com/trendmicro/tlsh")
6407 (uri (string-append "https://github.com/trendmicro/tlsh/archive/v"
6411 "00bhzjqrlh7v538kbkbn8lgx976j1138al3sdhklaizqjvpwyk4r"))
6412 (file-name (string-append name "-" version ".tar.gz"))))
6413 (build-system cmake-build-system)
6415 '(#:out-of-source? #f
6416 #:phases (modify-phases %standard-phases
6419 (lambda* (#:key outputs #:allow-other-keys)
6420 ;; Build and install the Python bindings. The underlying
6421 ;; C++ library is apparently not meant to be installed.
6422 (let ((out (assoc-ref outputs "out")))
6423 (with-directory-excursion "py_ext"
6424 (and (system* "python" "setup.py" "build")
6425 (system* "python" "setup.py" "install"
6426 (string-append "--prefix=" out))))))))))
6427 (inputs `(("python" ,python-wrapper))) ;for the bindings
6428 (synopsis "Fuzzy matching library for Python")
6430 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
6431 Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
6432 value which can be used for similarity comparisons. Similar objects have
6433 similar hash values, which allows for the detection of similar objects by
6434 comparing their hash values. The byte stream should have a sufficient amount
6435 of complexity; for example, a byte stream of identical bytes will not generate
6437 (license license:asl2.0)))
6439 (define-public python2-tlsh
6441 (inherit python-tlsh)
6442 (name "python2-tlsh")
6443 (inputs `(("python" ,python-2)))))
6445 (define-public python-termcolor
6447 (name "python-termcolor")
6452 (uri (pypi-uri "python-termcolor" version))
6455 "0fv1vq14rpqwgazxg4981904lfyp84mnammw7y046491cv76jv8x"))))
6456 (build-system python-build-system)
6458 ;; There are no tests.
6460 (home-page "http://pypi.python.org/pypi/termcolor")
6461 (synopsis "ANSII Color formatting for terminal output")
6463 "This package provides ANSII Color formatting for output in terminals.")
6464 (license license:expat)))
6466 (define-public python2-termcolor
6467 (package-with-python2 python-termcolor))
6469 (define-public python-libarchive-c
6471 (name "python-libarchive-c")
6475 (uri (pypi-uri "libarchive-c" version))
6478 "0z4r7v3dhd6b3120mav05ff08srih176r2rg5k8kn7mjd9pslm2x"))))
6479 (build-system python-build-system)
6481 '(#:phases (modify-phases %standard-phases
6483 'build 'reference-libarchive
6484 (lambda* (#:key inputs #:allow-other-keys)
6485 ;; Retain the absolute file name of libarchive.so.
6486 (let ((libarchive (assoc-ref inputs "libarchive")))
6487 (substitute* "libarchive/ffi.py"
6488 (("find_library\\('archive'\\)")
6489 (string-append "'" libarchive
6490 "/lib/libarchive.so'"))))
6492 ;; Do not make a compressed egg (see
6493 ;; <http://bugs.gnu.org/20765>).
6494 (let ((port (open-file "setup.cfg" "a")))
6495 (display "\n[easy_install]\nzip_ok = 0\n"
6500 `(("python-setuptools" ,python-setuptools)
6501 ("libarchive" ,libarchive)))
6502 (home-page "https://github.com/Changaco/python-libarchive-c")
6503 (synopsis "Python interface to libarchive")
6505 "This package provides Python bindings to libarchive, a C library to
6506 access possibly compressed archives in many different formats. It uses
6507 Python's @code{ctypes} foreign function interface (FFI).")
6508 (license license:lgpl2.0+)))
6510 (define-public python2-libarchive-c
6511 (package-with-python2 python-libarchive-c))
6513 (define-public python-file
6516 (name "python-file")
6517 (build-system python-build-system)
6519 '(#:tests? #f ;no tests
6520 #:phases (modify-phases %standard-phases
6521 (add-before 'build 'change-directory
6525 (add-before 'build 'set-library-file-name
6526 (lambda* (#:key inputs #:allow-other-keys)
6527 (let ((file (assoc-ref inputs "file")))
6528 (substitute* "magic.py"
6529 (("find_library\\('magic'\\)")
6530 (string-append "'" file "/lib/libmagic.so'")))
6532 (inputs `(("file" ,file)))
6533 (self-native-input? #f)
6534 (synopsis "Python bindings to the libmagic file type guesser. Note that
6535 this module and the python-magic module both provide a \"magic.py\" file;
6536 these two modules, which are different and were developed separately, both
6537 serve the same purpose: provide Python bindings for libmagic.")))
6539 (define-public python2-file
6540 (package-with-python2 python-file))
6542 (define-public python-debian
6544 (name "python-debian")
6550 "https://pypi.python.org/packages/source/p/python-debian/python-debian-"
6554 "193faznwnjc3n5991wyzim6h9gyq1zxifmfrnpm3avgkh7ahyynh"))))
6555 (build-system python-build-system)
6557 `(("python-six" ,python-six)))
6559 `(("python-setuptools" ,python-setuptools)))
6560 (home-page "http://packages.debian.org/sid/python-debian")
6561 (synopsis "Debian package related modules")
6563 ;; XXX: Use @enumerate instead of @itemize to work around
6564 ;; <http://bugs.gnu.org/21772>.
6565 "This package provides Python modules that abstract many formats of
6566 Debian-related files, such as:
6569 @item Debtags information;
6570 @item @file{debian/changelog} files;
6571 @item packages files, pdiffs;
6572 @item control files of single or multiple RFC822-style paragraphs---e.g.
6573 @file{debian/control}, @file{.changes}, @file{.dsc};
6574 @item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
6575 contained files and meta-information.
6578 ;; Modules are either GPLv2+ or GPLv3+.
6579 (license license:gpl3+)))
6581 (define-public python2-debian
6582 (package-with-python2 python-debian))
6584 (define-public python-chardet
6586 (name "python-chardet")
6592 "https://pypi.python.org/packages/source/c/chardet/chardet-"
6597 "1ak87ikcw34fivcgiz2xvi938dmclh078az65l9x3rmgljrkhgp5"))))
6598 (build-system python-build-system)
6600 `(("python-setuptools" ,python-setuptools)))
6601 (home-page "https://github.com/chardet/chardet")
6602 (synopsis "Universal encoding detector for Python 2 and 3")
6604 "This package provides @code{chardet}, a Python module that can
6605 automatically detect a wide range of file encodings.")
6606 (license license:lgpl2.1+)))
6608 (define-public python2-chardet
6609 (package-with-python2 python-chardet))
6611 (define-public python-docopt
6613 (name "python-docopt")
6618 ;; The release on PyPI does not include tests.
6620 "https://github.com/docopt/docopt/archive/"
6622 (file-name (string-append name "-" version ".tar.gz"))
6625 "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1"))))
6626 (build-system python-build-system)
6628 `(("python-pytest" ,python-pytest)
6629 ("python-setuptools" ,python-setuptools)))
6631 `(#:phases (alist-replace
6633 (lambda _ (zero? (system* "py.test")))
6635 (home-page "http://docopt.org")
6636 (synopsis "Command-line interface description language for Python")
6637 (description "This library allows the user to define a command-line
6638 interface from a program's help message rather than specifying it
6639 programatically with command-line parsers like @code{getopt} and
6641 (license license:expat)))
6643 (define-public python2-docopt
6644 (package-with-python2 python-docopt))
6646 (define-public python-zope-event
6648 (name "python-zope-event")
6653 (uri (string-append "https://pypi.python.org/packages/source/z"
6654 "/zope.event/zope.event-" version ".tar.gz"))
6657 "11p75zpfz3ffhz21nzx9wb23xs993ck5s6hkjcvhswwizni5jynw"))))
6658 (build-system python-build-system)
6660 `(("python-setuptools" ,python-setuptools)))
6661 (home-page "http://pypi.python.org/pypi/zope.event")
6662 (synopsis "Event publishing system for Python")
6663 (description "Zope.event provides an event publishing API, intended for
6664 use by applications which are unaware of any subscribers to their events. It
6665 is a simple event-dispatching system on which more sophisticated event
6666 dispatching systems can be built.")
6667 (license license:zpl2.1)))
6669 (define-public python2-zope-event
6670 (package-with-python2 python-zope-event))
6672 (define-public python-zope-interface
6674 (name "python-zope-interface")
6679 (uri (string-append "https://pypi.python.org/packages/source/z"
6680 "/zope.interface/zope.interface-" version ".tar.gz"))
6683 "0ks8h73b2g4bkad821qbv0wzjppdrwys33i7ka45ik3wxjg1l8if"))))
6684 (build-system python-build-system)
6686 `(("python-zope-event" ,python-zope-event)))
6687 (home-page "https://github.com/zopefoundation/zope.interface")
6688 (synopsis "Python implementation of the \"design by contract\"
6690 (description "Zope.interface provides an implementation of \"object
6691 interfaces\" for Python. Interfaces are a mechanism for labeling objects as
6692 conforming to a given API or contract.")
6693 (license license:zpl2.1)))
6695 (define-public python2-zope-interface
6696 (package-with-python2 python-zope-interface))
6698 (define-public python-zope-exceptions
6700 (name "python-zope-exceptions")
6705 (uri (string-append "https://pypi.python.org/packages/source/z"
6706 "/zope.exceptions/zope.exceptions-"
6710 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
6711 (build-system python-build-system)
6713 '(#:tests? #f)) ; circular dependency with zope.testrunner
6715 `(("python-zope-interface" ,python-zope-interface)))
6716 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
6717 (synopsis "Zope exceptions")
6718 (description "Zope.exceptions provides general-purpose exception types
6719 that have uses outside of the Zope framework.")
6720 (license license:zpl2.1)))
6722 (define-public python2-zope-exceptions
6723 (package-with-python2 python-zope-exceptions))
6725 (define-public python-zope-testing
6727 (name "python-zope-testing")
6732 (uri (string-append "https://pypi.python.org/packages/source/z"
6733 "/zope.testing/zope.testing-" version ".tar.gz"))
6736 "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))
6737 (modules '((guix build utils)))
6740 ;; Remove pre-compiled .pyc files backup files from source.
6741 (for-each delete-file (find-files "." "(\\.pyc|~)$"))
6743 (build-system python-build-system)
6745 `(("python-zope-exceptions" ,python-zope-exceptions)))
6747 `(("python-zope-interface" ,python-zope-interface)))
6748 (home-page "http://pypi.python.org/pypi/zope.testing")
6749 (synopsis "Zope testing helpers")
6750 (description "Zope.testing provides a number of testing utilities for HTML
6751 forms, HTTP servers, regular expressions, and more.")
6752 (license license:zpl2.1)))
6754 (define-public python2-zope-testing
6755 (package-with-python2 python-zope-testing))
6757 (define-public python-zope-testrunner
6759 (name "python-zope-testrunner")
6764 (uri (string-append "https://pypi.python.org/packages/source/z"
6765 "/zope.testrunner/zope.testrunner-"
6769 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
6770 (build-system python-build-system)
6772 `(("python-six" ,python-six)
6773 ("python-zope-exceptions" ,python-zope-exceptions)
6774 ("python-zope-testing" ,python-zope-testing)
6777 `(("python-zope-interface" ,python-zope-interface)))
6778 (home-page "http://pypi.python.org/pypi/zope.testrunner")
6779 (synopsis "Zope testrunner script")
6780 (description "Zope.testrunner provides a script for running Python
6782 (license license:zpl2.1)))
6784 (define-public python2-zope-testrunner
6785 (let ((base (package-with-python2 python-zope-testrunner)))
6789 (append (package-native-inputs base)
6790 `(("python2-subunit" ,python2-subunit)
6791 ("python2-mimeparse" ,python2-mimeparse)))))))
6793 (define-public python-zope-i18nmessageid
6795 (name "python-zope-i18nmessageid")
6801 "https://pypi.python.org/packages/source/z"
6802 "/zope.i18nmessageid/zope.i18nmessageid-"
6806 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
6807 (build-system python-build-system)
6809 `(("python-setuptools" ,python-setuptools)))
6810 (home-page "http://pypi.python.org/pypi/zope.i18nmessageid")
6811 (synopsis "Message identifiers for internationalization")
6812 (description "Zope.i18nmessageid provides facilities for declaring
6813 internationalized messages within program source text.")
6814 (license license:zpl2.1)))
6816 (define-public python2-zope-i18nmessageid
6817 (package-with-python2 python-zope-i18nmessageid))
6819 (define-public python-zope-schema
6821 (name "python-zope-schema")
6826 (uri (string-append "https://pypi.python.org/packages/source/z"
6827 "/zope.schema/zope.schema-" version ".tar.gz"))
6830 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
6831 (build-system python-build-system)
6833 `(("python-zope-event" ,python-zope-event)
6834 ("python-zope-interface" ,python-zope-interface)))
6836 `(("python-zope-testing" ,python-zope-testing)))
6837 (home-page "http://pypi.python.org/pypi/zope.schema")
6838 (synopsis "Zope data schemas")
6839 (description "Zope.scheme provides extensions to zope.interface for
6840 defining data schemas.")
6841 (license license:zpl2.1)))
6843 (define-public python2-zope-schema
6844 (package-with-python2 python-zope-schema))
6846 (define-public python-zope-configuration
6848 (name "python-zope-configuration")
6852 (uri (string-append "https://pypi.python.org/packages/source/z"
6853 "/zope.configuration/zope.configuration-"
6857 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
6858 (build-system python-build-system)
6860 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6861 ("python-zope-schema" ,python-zope-schema)))
6862 (home-page "http://pypi.python.org/pypi/zope.configuration")
6863 (synopsis "Zope Configuration Markup Language")
6864 (description "Zope.configuration implements ZCML, the Zope Configuration
6866 (license license:zpl2.1)))
6868 (define-public python2-zope-configuration
6869 (package-with-python2 python-zope-configuration))
6871 (define-public python-zope-proxy
6873 (name "python-zope-proxy")
6878 (uri (string-append "https://pypi.python.org/packages/source/z"
6879 "/zope.proxy/zope.proxy-" version ".tar.gz"))
6882 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
6883 (build-system python-build-system)
6885 `(("python-zope-interface" ,python-zope-interface)))
6886 (home-page "http://pypi.python.org/pypi/zope.proxy")
6887 (synopsis "Generic, transparent proxies")
6888 (description "Zope.proxy provides generic, transparent proxies for Python.
6889 Proxies are special objects which serve as mostly-transparent wrappers around
6890 another object, intervening in the apparent behavior of the wrapped object
6891 only when necessary to apply the policy (e.g., access checking, location
6892 brokering, etc.) for which the proxy is responsible.")
6893 (license license:zpl2.1)))
6895 (define-public python2-zope-proxy
6896 (package-with-python2 python-zope-proxy))
6898 (define-public python-zope-location
6900 (name "python-zope-location")
6905 (uri (string-append "https://pypi.python.org/packages/source/z"
6906 "/zope.location/zope.location-" version ".tar.gz"))
6909 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
6910 (build-system python-build-system)
6912 `(("python-zope-proxy" ,python-zope-proxy)
6913 ("python-zope-schema" ,python-zope-schema)))
6914 (home-page "http://pypi.python.org/pypi/zope.location/")
6915 (synopsis "Zope location library")
6916 (description "Zope.location implements the concept of \"locations\" in
6917 Zope3, which are are special objects that have a structural location.")
6918 (license license:zpl2.1)))
6920 (define-public python2-zope-location
6921 (package-with-python2 python-zope-location))
6923 (define-public python-zope-security
6925 (name "python-zope-security")
6930 (uri (string-append "https://pypi.python.org/packages/source/z"
6931 "/zope.security/zope.security-" version ".tar.gz"))
6934 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
6935 (build-system python-build-system)
6937 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6938 ("python-zope-component" ,python-zope-component)
6939 ("python-zope-location" ,python-zope-location)
6940 ("python-zope-proxy" ,python-zope-proxy)
6941 ("python-zope-schema" ,python-zope-schema)
6942 ("python-zope-testrunner" ,python-zope-testrunner)
6943 ("python-zope-testing" ,python-zope-testing)))
6944 (home-page "http://pypi.python.org/pypi/zope.security")
6945 (synopsis "Zope security framework")
6946 (description "Zope.security provides a generic mechanism to implement
6947 security policies on Python objects.")
6948 (license license:zpl2.1)))
6950 (define-public python2-zope-security
6951 (let ((zope-security (package-with-python2 python-zope-security)))
6952 (package (inherit zope-security)
6954 `(("python2-zope-testrunner" ,python2-zope-testrunner)
6956 "python-zope-testrunner"
6957 (package-propagated-inputs zope-security)))))))
6959 (define-public python-zope-component
6961 (name "python-zope-component")
6966 (uri (string-append "https://pypi.python.org/packages/source/z"
6967 "/zope.component/zope.component-" version ".tar.gz"))
6970 "06pqr8m5jv12xjyy5b59hh9anl61cxkzhw9mka33r3nxalmi2b18"))))
6971 (build-system python-build-system)
6973 ;; Skip tests due to circular dependency with python-zope-security.
6976 `(("python-zope-testing" ,python-zope-testing)))
6978 `(("python-zope-event" ,python-zope-event)
6979 ("python-zope-interface" ,python-zope-interface)
6980 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6981 ("python-zope-configuration" ,python-zope-configuration)))
6982 (home-page "https://github.com/zopefoundation/zope.component")
6983 (synopsis "Zope Component Architecture")
6984 (description "Zope.component represents the core of the Zope Component
6985 Architecture. Together with the zope.interface package, it provides
6986 facilities for defining, registering and looking up components.")
6987 (license license:zpl2.1)))
6989 (define-public python2-zope-component
6990 (package-with-python2 python-zope-component))
6992 (define-public python-pythondialog
6994 (name "python-pythondialog")
6999 (uri (pypi-uri "pythondialog" version))
7002 "1728ghsran47jczn9bhlnkvk5bvqmmbihabgif5h705b84r1272c"))))
7003 (build-system python-build-system)
7006 (modify-phases %standard-phases
7007 (add-after 'unpack 'patch-path
7008 (lambda* (#:key inputs #:allow-other-keys)
7009 (let* ((dialog (assoc-ref inputs "dialog")))
7010 ;; Since this library really wants to grovel the search path, we
7011 ;; must hardcode dialog's store path into it.
7012 (substitute* "dialog.py"
7013 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
7014 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
7016 #:tests? #f)) ; no test suite
7018 `(("dialog" ,dialog)))
7019 (home-page "http://pythondialog.sourceforge.net/")
7020 (synopsis "Python interface to the UNIX dialog utility")
7021 (description "A Python wrapper for the dialog utility. Its purpose is to
7022 provide an easy to use, pythonic and comprehensive Python interface to dialog.
7023 This allows one to make simple text-mode user interfaces on Unix-like systems")
7024 (license license:lgpl2.1)
7025 (properties `((python2-variant . ,(delay python2-pythondialog))))))
7027 (define-public python2-pythondialog
7028 (let ((base (package-with-python2 (strip-python2-variant python-pythondialog))))
7031 (version (package-version python-pythondialog))
7034 (uri (pypi-uri "python2-pythondialog" version))
7037 "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9")))))))
7039 (define-public python-pyrfc3339
7041 (name "python-pyrfc3339")
7046 (uri (pypi-uri "pyRFC3339" version))
7049 "0dgm4l9y8jiax5cp6yxjd2i27cq8h33sh81n1wfbmnmqb32cdywd"))))
7050 (build-system python-build-system)
7052 `(("python-pytz" ,python-pytz)))
7054 `(("python-nose" ,python-nose)
7055 ("python-setuptools" ,python-setuptools)))
7056 (home-page "https://github.com/kurtraschke/pyRFC3339")
7057 (synopsis "Python timestamp library")
7058 (description "Python library for generating and parsing RFC 3339-compliant
7060 (license license:expat)))
7062 (define-public python2-pyrfc3339
7063 (package-with-python2 python-pyrfc3339))
7065 (define-public python-werkzeug
7067 (name "python-werkzeug")
7072 (uri (pypi-uri "Werkzeug" version))
7075 "1rgpq8a2qv26d75v9j3b074inirlyy6y4b5x4rxblp202jy4cb77"))))
7076 (build-system python-build-system)
7078 `(("python-pytest" ,python-pytest)))
7079 (home-page "http://werkzeug.pocoo.org/")
7080 (synopsis "Utilities for WSGI applications")
7081 (description "One of the most advanced WSGI utility modules. It includes a
7082 powerful debugger, full-featured request and response objects, HTTP utilities to
7083 handle entity tags, cache control headers, HTTP dates, cookie handling, file
7084 uploads, a powerful URL routing system and a bunch of community-contributed
7086 (license license:x11)))
7088 (define-public python2-werkzeug
7089 (package-with-python2 python-werkzeug))
7091 (define-public python-configobj
7093 (name "python-configobj")
7098 "https://pypi.python.org/packages/source/c/configobj/"
7099 "configobj-" version ".tar.gz"))
7102 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
7103 ;; Patch setup.py so it looks for python-setuptools, which is
7104 ;; required to parse the keyword 'install_requires' in setup.py.
7105 (patches (search-patches "python-configobj-setuptools.patch"))))
7106 (build-system python-build-system)
7108 `(("python-setuptools" ,python-setuptools)
7109 ("python-six" ,python-six)))
7110 (synopsis "Config file reading, writing and validation")
7111 (description "ConfigObj is a simple but powerful config file reader and
7112 writer: an ini file round tripper. Its main feature is that it is very easy to
7113 use, with a straightforward programmer’s interface and a simple syntax for
7115 (home-page "https://github.com/DiffSK/configobj")
7116 (license license:bsd-3)))
7118 (define-public python2-configobj
7119 (package-with-python2 python-configobj))
7121 (define-public python-configargparse
7123 (name "python-configargparse")
7128 "https://pypi.python.org/packages/source/C/ConfigArgParse/"
7129 "ConfigArgParse-" version ".tar.gz"))
7132 "19wh919gbdbzxzpagg52q3lm62yicm95ddlcx77dyjc1slyshl1v"))))
7133 (build-system python-build-system)
7135 ;; FIXME: Bug in test suite filed upstream:
7136 ;; https://github.com/bw2/ConfigArgParse/issues/32
7138 (synopsis "Replacement for argparse")
7139 (description "A drop-in replacement for argparse that allows options to also
7140 be set via config files and/or environment variables.")
7141 (home-page "https://github.com/bw2/ConfigArgParse")
7142 (license license:expat)))
7144 (define-public python2-configargparse
7145 (package-with-python2 python-configargparse))
7147 (define-public python-ndg-httpsclient
7149 (name "python-ndg-httpsclient")
7154 "https://pypi.python.org/packages/source/n/ndg-httpsclient/"
7155 "ndg_httpsclient-" version ".tar.gz"))
7158 "0x32ibixm3vv5m9xfk83xsqm8xcqw4dd0khbh6qbri6rxgymbhg8"))))
7159 (build-system python-build-system)
7161 `(("python-pyopenssl" ,python-pyopenssl)))
7162 (synopsis "HTTPS support for Python's httplib and urllib2")
7163 (description "This is a HTTPS client implementation for httplib and urllib2
7164 based on PyOpenSSL. PyOpenSSL provides a more fully featured SSL implementation
7165 over the default provided with Python and importantly enables full verification
7167 (home-page "https://github.com/cedadev/ndg_httpsclient/")
7168 (license license:bsd-3)))
7170 ;; python2-openssl requires special care, so package-with-python2 is
7172 (define-public python2-ndg-httpsclient
7173 (package (inherit python-ndg-httpsclient)
7174 (name "python2-ndg-httpsclient")
7175 (arguments `(#:python ,python-2))
7177 `(("python2-pyopenssl" ,python2-pyopenssl)))))
7179 (define-public python-contextlib2
7181 (name "python-contextlib2")
7186 (uri (pypi-uri "contextlib2" version))
7189 "0cmp131dlh0d0zvw0aza1zd13glvngzk8lb4avks0hm7yxwdr9am"))))
7190 (build-system python-build-system)
7193 (modify-phases %standard-phases
7197 "python" "test_contextlib2.py" "-v")))))))
7198 (home-page "http://contextlib2.readthedocs.org/")
7199 (synopsis "Tools for decorators and context managers")
7200 (description "This module is primarily a backport of the Python
7201 3.2 contextlib to earlier Python versions. Like contextlib, it
7202 provides utilities for common tasks involving decorators and context
7203 managers. It also contains additional features that are not part of
7204 the standard library.")
7205 (license license:psfl)))
7207 (define-public python2-contextlib2
7208 (package-with-python2 python-contextlib2))
7210 (define-public python-texttable
7212 (name "python-texttable")
7217 (uri (pypi-uri "texttable" version))
7220 "0bkhs4dx9s6g7fpb969hygq56hyz4ncfamlynw72s0n6nqfbd1w5"))))
7221 (build-system python-build-system)
7222 (arguments '(#:tests? #f)) ; no tests
7223 (home-page "https://github.com/foutaise/texttable/")
7224 (synopsis "Python module for creating simple ASCII tables")
7225 (description "Texttable is a Python module for creating simple ASCII
7227 (license license:lgpl2.1+)))
7229 (define-public python2-texttable
7230 (package-with-python2 python-texttable))
7232 (define-public python-websocket-client
7234 (name "python-websocket-client")
7239 (uri (pypi-uri "websocket_client" version))
7242 "0h9glp1jll3z76ly3kg08aqgxqk0a68p4zi9yn50353bh5nj92v7"))))
7243 (build-system python-build-system)
7245 `(("python-six" ,python-six))) ; for tests
7247 `(("python-setuptools" ,python-setuptools)))
7248 (home-page "https://github.com/liris/websocket-client")
7249 (synopsis "WebSocket client for Python")
7250 (description "The Websocket-client module provides the low level APIs for
7251 WebSocket usage in Python programs.")
7252 (license license:lgpl2.1+)))
7254 (define-public python2-websocket-client
7255 (package-with-python2 python-websocket-client))
7257 (define-public python-atomicwrites
7259 (name "python-atomicwrites")
7263 (uri (pypi-uri "atomicwrites" version))
7266 "1s01dci8arsl9d9vr5nz1fk9znldp1z3l4yl43f0c27z12b8yxl0"))))
7267 (build-system python-build-system)
7268 (synopsis "Atomic file writes in Python")
7269 (description "Library for atomic file writes using platform dependent tools
7270 for atomic file system operations.")
7271 (home-page "https://github.com/untitaker/python-atomicwrites")
7272 (license license:expat)
7273 (properties `((python2-variant . ,(delay python2-atomicwrites))))))
7275 (define-public python2-atomicwrites
7276 (package (inherit (package-with-python2
7277 (strip-python2-variant python-atomicwrites)))
7279 `(("python2-setuptools" ,python2-setuptools)))))
7281 (define-public python-requests-toolbelt
7283 (name "python-requests-toolbelt")
7288 "https://pypi.python.org/packages/"
7289 "e1/a4/a94c037bc72ad70441aff1403d3243510d2542ddca7759faaeffeb11aefe/"
7290 "requests-toolbelt-" version ".tar.gz"))
7293 "15q9nrgp85nqlr4kdz1zvj8z2npafi2sr12y7fqgxbkq28j1aci6"))))
7294 (build-system python-build-system)
7296 `(("python-requests" ,python-requests)))
7297 (synopsis "Extensions to python-requests")
7298 (description "This is a toolbelt of useful classes and functions to be used
7299 with python-requests.")
7300 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
7301 (license license:asl2.0)))
7303 (define-public python-click-threading
7305 (name "python-click-threading")
7310 "https://pypi.python.org/packages/"
7311 "fe/b7/e7f609d18a2a351cb71616adcf54df1acd82f83cb9b5936935a4d20e2c23/"
7312 "click-threading-" version ".tar.gz"))
7315 "18bcqikxwb3drb8rf60cclxkxw52521b38ax3byah6j8cn8y9p4j"))))
7316 (build-system python-build-system)
7318 `(("python-click" ,python-click)))
7319 (synopsis "Utilities for multithreading in Click")
7320 (description "This package provides utilities for multithreading in Click
7322 (home-page "https://github.com/click-contrib/click-threading")
7323 (license license:expat)))
7325 (define-public python-click-log
7327 (name "python-click-log")
7331 (uri (pypi-uri "click-log" version))
7334 "0kdd1vminxpcfczxl2kkf285n0dr1gxh2cdbx1p6vkj7b7bci3gx"))))
7335 (build-system python-build-system)
7337 `(("python-click" ,python-click)))
7338 (synopsis "Logging for click applications")
7339 (description "This package provides a Python library for logging Click
7341 (home-page "https://github.com/click-contrib/click-log")
7342 (license license:expat)))
7344 (define-public python-apipkg
7346 (name "python-apipkg")
7350 (uri (pypi-uri "apipkg" version))
7353 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
7354 (build-system python-build-system)
7356 `(("python-pytest" ,python-pytest)))
7357 (synopsis "Namespace control and lazy-import mechanism")
7358 (description "With apipkg you can control the exported namespace of a Python
7359 package and greatly reduce the number of imports for your users. It is a small
7360 pure Python module that works on virtually all Python versions.")
7361 (home-page "https://bitbucket.org/hpk42/apipkg")
7362 (license license:expat)
7363 (properties `((python2-variant . ,(delay python2-apipkg))))))
7365 (define-public python2-apipkg
7367 (inherit (package-with-python2
7368 (strip-python2-variant python-apipkg)))
7370 `(("python2-setuptools" ,python2-setuptools)))))
7372 (define-public python-execnet
7374 (name "python-execnet")
7378 (uri (pypi-uri "execnet" version))
7381 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
7382 (build-system python-build-system)
7384 `(("python-setuptools-scm" ,python-setuptools-scm)))
7386 `(("python-apipkg" ,python-apipkg)))
7387 (synopsis "Rapid multi-Python deployment")
7388 (description "Execnet provides a share-nothing model with
7389 channel-send/receive communication for distributing execution across many
7390 Python interpreters across version, platform and network barriers. It has a
7391 minimal and fast API targetting the following uses:
7393 @item distribute tasks to (many) local or remote CPUs
7394 @item write and deploy hybrid multi-process applications
7395 @item write scripts to administer multiple environments
7397 (home-page "http://codespeak.net/execnet/")
7398 (license license:expat)
7399 (properties `((python2-variant . ,(delay python2-execnet))))))
7401 (define-public python2-execnet
7402 (let ((execnet (package-with-python2
7403 (strip-python2-variant python-execnet))))
7407 `(("python2-setuptools" ,python2-setuptools)
7408 ,@(package-native-inputs execnet))))))
7410 ;;; The software provided by this package was integrated into pytest 2.8.
7411 (define-public python-pytest-cache
7413 (name "python-pytest-cache")
7417 (uri (pypi-uri "pytest-cache" version))
7420 "1a873fihw4rhshc722j4h6j7g3nj7xpgsna9hhg3zn6ksknnhx5y"))))
7421 (build-system python-build-system)
7423 `(("python-apipkg" ,python-apipkg)
7424 ("python-execnet" ,python-execnet)
7425 ("python-py" ,python-py)
7426 ("python-pytest" ,python-pytest)))
7427 (synopsis "Py.test plugin with mechanisms for caching across test runs")
7428 (description "The pytest-cache plugin provides tools to rerun failures from
7429 the last py.test invocation.")
7430 (home-page "https://bitbucket.org/hpk42/pytest-cache/")
7431 (license license:expat)
7432 (properties `((python2-variant . ,(delay python2-pytest-cache))))))
7434 (define-public python2-pytest-cache
7435 (let ((pytest-cache (package-with-python2
7436 (strip-python2-variant python-pytest-cache))))
7438 (inherit pytest-cache)
7440 `(("python2-setuptools" ,python2-setuptools)
7441 ,@(package-native-inputs pytest-cache))))))
7443 (define-public python-pytest-localserver
7445 (name "python-pytest-localserver")
7449 (uri (pypi-uri "pytest-localserver" version))
7452 "0dvqspjr6va55zwmnnc2mmpqc7mm65kxig9ya44x1z8aadzxpa4p"))))
7453 (build-system python-build-system)
7455 `(#:phases (modify-phases %standard-phases
7458 (zero? (system* "py.test" "--genscript=runtests.py"))
7459 (zero? (system* "py.test")))))))
7461 `(("python-pytest" ,python-pytest)
7462 ("python-requests" ,python-requests)
7463 ("python-six" ,python-six)))
7465 `(("python-werkzeug" ,python-werkzeug)))
7466 (synopsis "Py.test plugin to test server connections locally")
7467 (description "Pytest-localserver is a plugin for the pytest testing
7468 framework which enables you to test server connections locally.")
7469 (home-page "https://pypi.python.org/pypi/pytest-localserver")
7470 (license license:expat)))
7472 (define-public python-wsgi-intercept
7474 (name "python-wsgi-intercept")
7479 "https://pypi.python.org/packages/"
7480 "38/76/ebcbc24d0cb77db34520a3ca6ed1bd43ace17d182bbd8dd7d976f1c176fb/"
7481 "wsgi_intercept-" version ".tar.gz"))
7484 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
7485 (build-system python-build-system)
7487 `(("python-pytest" ,python-pytest)
7488 ("python-six" ,python-six)))
7490 `(("python-httplib2" ,python-httplib2)
7491 ("python-requests" ,python-requests)))
7492 (synopsis "Puts a WSGI application in place of a real URI for testing")
7493 (description "Wsgi_intercept installs a WSGI application in place of a real
7494 URI for testing. Testing a WSGI application normally involves starting a
7495 server at a local host and port, then pointing your test code to that address.
7496 Instead, this library lets you intercept calls to any specific host/port
7497 combination and redirect them into a WSGI application importable by your test
7498 program. Thus, you can avoid spawning multiple processes or threads to test
7500 (home-page "https://github.com/cdent/wsgi-intercept")
7501 (license license:expat)))
7503 (define-public python-pytest-xprocess
7505 (name "python-pytest-xprocess")
7509 (uri (pypi-uri "pytest-xprocess" version))
7512 "17zlql1xqw3ywcgwwbqmw633aly99lab12hm02asr8awvg5603pp"))))
7513 (build-system python-build-system)
7515 `(("python-pytest" ,python-pytest)
7516 ("python-pytest-cache" ,python-pytest-cache)
7517 ("python-psutil" ,python-psutil)))
7518 (synopsis "Pytest plugin to manage external processes across test runs")
7519 (description "Pytest-xprocess is an experimental py.test plugin for managing
7520 processes across test runs.")
7521 (home-page "https://bitbucket.org/pytest-dev/pytest-xprocess")
7522 (license license:expat)))
7524 (define-public python-icalendar
7526 (name "python-icalendar")
7530 (uri (pypi-uri "icalendar" version))
7533 "01amnk3621s7fagfla86npd25knbqirchg7h1jpqxqp103d02bs7"))))
7534 (build-system python-build-system)
7536 `(("python-dateutil-2" ,python-dateutil-2)
7537 ("python-pytz" ,python-pytz)))
7538 (synopsis "Python library for parsing iCalendar files")
7539 (description "The icalendar package is a parser/generator of iCalendar
7540 files for use with Python.")
7541 (home-page "https://github.com/collective/icalendar")
7542 (license license:bsd-2)))
7544 (define-public python-sphinxcontrib-newsfeed
7546 (name "python-sphinxcontrib-newsfeed")
7550 (uri (pypi-uri "sphinxcontrib-newsfeed" version))
7553 "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p"))))
7554 (build-system python-build-system)
7556 `(("python-docutils" ,python-docutils)
7557 ("python-sphinx" ,python-sphinx)))
7558 (synopsis "News Feed extension for Sphinx")
7559 (description "Sphinxcontrib-newsfeed is an extension for adding a simple
7560 Blog, News or Announcements section to a Sphinx website.")
7561 (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed")
7562 (license license:bsd-2)))
7564 (define-public python-args
7566 (name "python-args")
7570 (uri (pypi-uri "args" version))
7573 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
7574 (build-system python-build-system)
7576 `(("python-setuptools" ,python-setuptools)))
7577 (home-page "https://github.com/kennethreitz/args")
7578 (synopsis "Command-line argument parser")
7580 "This library provides a Python module to parse command-line arguments.")
7581 (license license:bsd-3)))
7583 (define-public python2-args
7584 (package-with-python2 python-args))
7586 (define-public python-clint
7588 (name "python-clint")
7592 (uri (pypi-uri "clint" version))
7595 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
7596 (build-system python-build-system)
7598 `(("python-args" ,python-args)
7599 ("python-setuptools" ,python-setuptools)))
7600 (home-page "https://github.com/kennethreitz/clint")
7601 (synopsis "Command-line interface tools")
7603 "Clint is a Python module filled with a set of tools for developing
7604 command-line applications, including tools for colored and indented
7605 output, progress bar display, and pipes.")
7606 (license license:isc)))
7608 (define-public python2-clint
7609 (package-with-python2 python-clint))
7611 (define-public python-astor
7613 (name "python-astor")
7617 (uri (pypi-uri "astor" version))
7620 "1fdafq5hkis1fxqlmhw0sn44zp2ar46nxhbc22cvwg7hsd8z5gsa"))))
7621 (build-system python-build-system)
7623 `(("python-setuptools" ,python-setuptools)))
7624 (home-page "https://github.com/berkerpeksag/astor")
7625 (synopsis "Read and write Python ASTs")
7627 "Astor is designed to allow easy manipulation of Python source via the
7628 Abstract Syntax Tree.")
7629 (license license:bsd-3)))
7631 (define-public python2-astor
7632 (package-with-python2 python-astor))
7634 (define-public python-rply
7636 (name "python-rply")
7640 (uri (pypi-uri "rply" version))
7643 "12rp1d9ba7nvd5rhaxi6xzx1rm67r1k1ylsrkzhpwnphqpb06cvj"))))
7644 (build-system python-build-system)
7646 `(("python-appdirs" ,python-appdirs)
7647 ("python-setuptools" ,python-setuptools)))
7648 (home-page "https://github.com/alex/rply")
7649 (synopsis "Parser generator for Python")
7651 "This package provides a pure Python based parser generator, that also
7652 works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
7653 with a new public API, and RPython support.")
7654 (license license:bsd-3)))
7656 (define-public python2-rply
7657 (package-with-python2 python-rply))
7659 (define-public python-hy
7665 (uri (pypi-uri "hy" version))
7668 "1msqv747iz12r73mz4qvsmlwkddwjvrahlrk7ysrcz07h7dsscxs"))))
7669 (build-system python-build-system)
7671 `(("python-astor" ,python-astor)
7672 ("python-clint" ,python-clint)
7673 ("python-rply" ,python-rply)
7674 ("python-setuptools" ,python-setuptools)))
7675 (home-page "http://hylang.org/")
7676 (synopsis "Lisp frontend to Python")
7678 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
7679 its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
7680 Python at your fingertips, in Lisp form.")
7681 (license license:expat)))
7683 (define-public python2-hy
7684 (package-with-python2 python-hy))
7686 (define-public python-rauth
7688 (name "python-rauth")
7693 (uri (pypi-uri "rauth" version))
7696 "00pq7zw429hhza9c0qzxiqp77m653jv09z92nralnmzwdf6pzicf"))))
7697 (build-system python-build-system)
7699 `(#:test-target "check"))
7701 `(("python-requests" ,python-requests)))
7702 (home-page "https://github.com/litl/rauth")
7703 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
7705 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
7706 provides service wrappers for convenient connection initialization and
7707 authenticated session objects providing things like keep-alive.")
7708 (license license:expat)
7709 (properties `((python2-variant . ,(delay python2-rauth))))))
7711 (define-public python2-rauth
7712 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
7715 (native-inputs `(("python2-setuptools" ,python2-setuptools)
7716 ("python2-unittest2" ,python2-unittest2)
7717 ,@(package-native-inputs base))))))
7719 (define-public python2-functools32
7721 (name "python2-functools32")
7726 (uri (pypi-uri "functools32" version))
7729 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
7730 (build-system python-build-system)
7732 `(#:python ,python-2
7733 #:tests? #f)) ; no test target
7735 `(("python2-setuptools" ,python2-setuptools)))
7736 (home-page "https://github.com/MiCHiLU/python-functools32")
7738 "Backport of the functools module from Python 3.2.3")
7740 "This package is a backport of the @code{functools} module from Python
7741 3.2.3 for use with older versions of Python and PyPy.")
7742 (license license:expat)))
7744 (define-public python2-futures
7746 (name "python2-futures")
7751 (uri (pypi-uri "futures" version))
7754 "1vcb34dqhzkhbq1957vdjszhhm5y3j9ba88dgwhqx2zynhmk9qig"))))
7755 (build-system python-build-system)
7756 (arguments `(#:python ,python-2))
7758 `(("python2-setuptools" ,python2-setuptools)))
7759 (home-page "https://github.com/agronholm/pythonfutures")
7761 "Backport of the concurrent.futures package from Python 3.2")
7763 "The concurrent.futures module provides a high-level interface for
7764 asynchronously executing callables. This package backports the
7765 concurrent.futures package from Python 3.2")
7766 (license license:bsd-3)))
7768 (define-public python-promise
7770 (name "python-promise")
7775 (uri (pypi-uri "promise" version))
7778 "1k19ms8l3d5jzjh557rgkxb5sg4mqgfc315rn4hx1z3n8qq6lr3h"))))
7779 (build-system python-build-system)
7780 ;; Tests wants python-futures, which is a python2 only program, and
7781 ;; can't be found by python-promise at test time.
7782 (arguments `(#:tests? #f))
7783 (home-page "https://github.com/syrusakbary/promise")
7784 (synopsis "Promises/A+ implementation for Python")
7786 "Promises/A+ implementation for Python")
7787 (properties `((python2-variant . ,(delay python2-promise))))
7788 (license license:expat)))
7790 (define-public python2-promise
7791 (let ((promise (package-with-python2
7792 (strip-python2-variant python-promise))))
7793 (package (inherit promise)
7794 (arguments (substitute-keyword-arguments (package-arguments promise)
7797 `(("python2-futures" ,python2-futures)
7798 ("python2-pytest" ,python2-pytest)
7799 ("python2-setuptools" ,python2-setuptools)
7800 ,@(package-native-inputs promise))))))
7802 (define-public python-urllib3
7804 (name "python-urllib3")
7809 (uri (pypi-uri "urllib3" version))
7812 "1wb8aqnq53vzh2amrv8kc66f3h6fx217y0q62y6n30a64p2yqmam"))))
7813 (build-system python-build-system)
7814 (arguments `(#:tests? #f))
7816 `(("python-setuptools" ,python-setuptools)
7817 ;; some packages for tests
7818 ("python-nose" ,python-nose)
7819 ("python-mock" ,python-mock)
7820 ("python-tornado" ,python-tornado)))
7822 `(;; packages for https security
7823 ("python-certifi" ,python-certifi)
7824 ("python-ndg-httpsclient" ,python-ndg-httpsclient)
7825 ("python-pyasn1" ,python-pyasn1)
7826 ("python-pyopenssl" ,python-pyopenssl)))
7827 (home-page "https://urllib3.readthedocs.org/")
7828 (synopsis "HTTP library with thread-safe connection pooling")
7830 "Urllib3 supports features left out of urllib and urllib2 libraries. It
7831 can reuse the same socket connection for multiple requests, it can POST files,
7832 supports url redirection and retries, and also gzip and deflate decoding.")
7833 (license license:expat)))
7835 (define-public python2-urllib3
7836 (package-with-python2 python-urllib3))
7838 (define-public python-colorama
7840 (name "python-colorama")
7845 (uri (pypi-uri "colorama" version))
7848 "1716z9pq1r5ys3nkg7wdrb3h2f9rmd0zdxpxzmx3bgwgf6xg48gb"))))
7849 (build-system python-build-system)
7851 `(("python-setuptools" ,python-setuptools)))
7852 (synopsis "colored terminal text rendering for Python")
7853 (description "Colorama is a Python library for rendering colored terminal
7855 (home-page "https://pypi.python.org/pypi/colorama")
7856 (license license:bsd-3)))
7858 (define-public python2-colorama
7859 (package-with-python2 python-colorama))
7861 (define-public python-rsa
7868 (uri (pypi-uri "rsa" version))
7871 "1dcxvszbikgzh99ybdc7jq0zb9wspy2ds8z9mjsqiyv3q884xpr5"))))
7872 (build-system python-build-system)
7874 `(("python-pyasn1" ,python-pyasn1)
7875 ("python-setuptools" ,python-setuptools)))
7876 (synopsis "Pure-Python RSA implementation")
7877 (description "Python-RSA is a pure-Python RSA implementation. It supports
7878 encryption and decryption, signing and verifying signatures, and key
7879 generation according to PKCS#1 version 1.5. It can be used as a Python
7880 library as well as on the command line.")
7881 (home-page "http://stuvel.eu/rsa")
7882 (license license:asl2.0)))
7884 (define-public python2-rsa
7885 (package-with-python2 python-rsa))
7887 (define-public python-pluggy
7889 (name "python-pluggy")
7894 (uri (pypi-uri "pluggy" version))
7897 "18qfzfm40bgx672lkg8q9x5hdh76n7vax99aank7vh2nw21wg70m"))))
7898 (build-system python-build-system)
7900 `(("python-setuptools" ,python-setuptools)))
7901 (synopsis "Plugin and hook calling mechanism for Python")
7902 (description "Pluggy is an extraction of the plugin manager as used by
7903 Pytest but stripped of Pytest specific details.")
7904 (home-page "https://pypi.python.org/pypi/pluggy")
7905 (license license:expat)))
7907 (define-public python2-pluggy
7908 (package-with-python2 python-pluggy))
7910 (define-public python-tox
7917 (uri (pypi-uri "tox" version))
7920 "1vj73ar4rimq3fwy5r2z3jv4g9qbh8rmpmncsc00g0k310acqzxz"))))
7921 (build-system python-build-system)
7923 ;; FIXME: Tests require a newer version of pytest, but upgrading our
7924 ;; pytest breaks other packages.
7927 `(("python-setuptools" ,python-setuptools)
7928 ("python-pluggy" ,python-pluggy)
7929 ("python-py" ,python-py)
7930 ("python-virtualenv" ,python-virtualenv)
7931 ("python-pytest" ,python-pytest)))
7932 (home-page "http://tox.testrun.org/")
7933 (synopsis "Virtualenv-based automation of test activities")
7934 (description "Tox is a generic virtualenv management and test command line
7935 tool. It can be used to check that a package installs correctly with
7936 different Python versions and interpreters, or run tests in each type of
7937 supported environment, or act as a frontend to continuous integration
7939 (license license:expat)))
7941 (define-public python2-tox
7942 (package-with-python2 python-tox))
7944 (define-public python-jmespath
7946 (name "python-jmespath")
7951 (uri (pypi-uri "jmespath" version))
7954 "0g9xvl69y7nr3w7ag4fsp6sm4fqf6vrqjw7504x2hzrrsh3ampq8"))))
7955 (build-system python-build-system)
7957 `(("python-setuptools" ,python-setuptools)))
7958 (synopsis "JSON Matching Expressions")
7959 (description "JMESPath (pronounced “james path”) is a Python library that
7960 allows one to declaratively specify how to extract elements from a JSON
7962 (home-page "https://github.com/jmespath/jmespath.py")
7963 (license license:expat)))
7965 (define-public python2-jmespath
7966 (package-with-python2 python-jmespath))
7968 (define-public python-botocore
7970 (name "python-botocore")
7975 (uri (pypi-uri "botocore" version))
7978 "1zxczlwqy9bl27d9bc5x99mb5mcsxm350240lp5nx7014xb311lj"))))
7979 (build-system python-build-system)
7981 `(("python-dateutil" ,python-dateutil-2)
7982 ("python-docutils" ,python-docutils)
7983 ("python-mock" ,python-mock)
7984 ("python-nose" ,python-nose)
7985 ("python-setuptools" ,python-setuptools)
7986 ("python-tox" ,python-tox)
7987 ("python-wheel" ,python-wheel)
7988 ("python-jmespath" ,python-jmespath)))
7989 (home-page "https://github.com/boto/botocore")
7990 (synopsis "Low-level interface to AWS")
7991 (description "Botocore is a Python library that provides a low-level
7992 interface to the Amazon Web Services (AWS) API.")
7993 (license license:asl2.0)))
7995 (define-public python2-botocore
7996 (package-with-python2 python-botocore))
7998 (define-public awscli
8005 (uri (pypi-uri name version))
8008 "0lclasm0wnayd3b8zl9l91i32nbgrhh0ncf9lksss4cv0myfwmfg"))))
8009 (build-system python-build-system)
8011 `(("python-colorama" ,python-colorama)
8012 ("python-docutils" ,python-docutils)
8013 ("python-mock" ,python-mock)
8014 ("python-nose" ,python-nose)
8015 ("python-rsa" ,python-rsa)
8016 ("python-setuptools" ,python-setuptools)
8017 ("python-sphinx" ,python-sphinx)
8018 ("python-tox" ,python-tox)
8019 ("python-wheel" ,python-wheel)
8020 ("python-botocore" ,python-botocore)
8021 ("python-s3transfer" ,python-s3transfer)))
8022 (home-page "http://aws.amazon.com/cli/")
8023 (synopsis "Command line client for AWS")
8024 (description "AWS CLI provides a unified command line interface to the
8025 Amazon Web Services (AWS) API.")
8026 (license license:asl2.0)))
8028 (define-public python-hypothesis
8030 (name "python-hypothesis")
8034 (uri (pypi-uri "hypothesis" version))
8037 "0qyqq9akm4vshhn8cngjc1qykcvsn7cz6dlm6njfsgpbraqrmbbw"))))
8038 (build-system python-build-system)
8040 `(("python-flake8" ,python-flake8)
8041 ("python-pytest" ,python-pytest)))
8042 (synopsis "Library for property based testing")
8043 (description "Hypothesis is a library for testing your Python code against a
8044 much larger range of examples than you would ever want to write by hand. It’s
8045 based on the Haskell library, Quickcheck, and is designed to integrate
8046 seamlessly into your existing Python unit testing work flow.")
8047 (home-page "https://github.com/DRMacIver/hypothesis")
8048 (license license:mpl2.0)
8049 (properties `((python2-variant . ,(delay python2-hypothesis))))))
8051 (define-public python2-hypothesis
8052 (let ((hypothesis (package-with-python2
8053 (strip-python2-variant python-hypothesis))))
8054 (package (inherit hypothesis)
8056 `(("python2-enum34" ,python2-enum34)
8057 ("python2-setuptools" ,python2-setuptools))))))
8059 (define-public python-pytest-subtesthack
8061 (name "python-pytest-subtesthack")
8065 (uri (pypi-uri "pytest-subtesthack" version))
8068 "15kzcr5pchf3id4ikdvlv752rc0j4d912n589l4rifp8qsj19l1x"))))
8069 (build-system python-build-system)
8071 `(;; setuptools required for python-2 variant
8072 ("python-setuptools" ,python-setuptools)))
8074 `(("python-pytest" ,python-pytest)))
8075 (synopsis "Set-up and tear-down fixtures for unit tests")
8076 (description "This plugin allows you to set up and tear down fixtures within
8077 unit test functions that use @code{py.test}. This is useful for using
8078 @command{hypothesis} inside py.test, as @command{hypothesis} will call the test
8079 function multiple times, without setting up or tearing down fixture state as is
8080 normally the case.")
8081 (home-page "https://github.com/untitaker/pytest-subtesthack/")
8082 (license license:unlicense)))
8084 (define-public python2-pytest-subtesthack
8085 (package-with-python2 python-pytest-subtesthack))
8087 (define-public python2-xdo
8089 (name "python2-xdo")
8094 "http://http.debian.net/debian/pool/main/p/python-xdo/"
8095 "python-xdo_" version ".orig.tar.gz"))
8098 "1kl5c1p0dyxf62plnk6fl77ycfb4whwjms16r14dxx8kn90hlqz4"))))
8099 (build-system python-build-system)
8101 `(#:python ,python-2
8102 #:tests? #f)) ; no tests provided
8104 `(("xdotool" ,xdotool)
8105 ("libX11" ,libx11)))
8106 (home-page "https://tracker.debian.org/pkg/python-xdo")
8107 (synopsis "Python library for simulating X11 keyboard/mouse input")
8108 (description "Provides bindings to libxdo for manipulating X11 via simulated
8109 input. (Note that this is mostly a legacy library; you may wish to look at
8110 python-xdo for newer bindings.)")
8111 (license license:bsd-3)))
8113 (define-public python-wtforms
8115 (name "python-wtforms")
8120 (uri (pypi-uri "WTForms" version ".zip"))
8123 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
8124 (build-system python-build-system)
8126 `(("unzip" ,unzip)))
8127 (home-page "http://wtforms.simplecodes.com/")
8129 "Form validation and rendering library for Python web development")
8131 "WTForms is a flexible forms validation and rendering library
8132 for Python web development. It is very similar to the web form API
8133 available in Django, but is a standalone package.")
8134 (license license:bsd-3)
8135 (properties `((python2-variant . ,(delay python2-wtforms))))))
8137 (define-public python2-wtforms
8139 (inherit (package-with-python2
8140 (strip-python2-variant python-wtforms)))
8141 (inputs `(("python2-setuptools" ,python2-setuptools)))))
8143 (define-public python-mako
8145 (name "python-mako")
8150 (uri (pypi-uri "Mako" version))
8153 "136kcjbs0s98qkx8a418b05dfblqp0kiiqyx8vhx4rarwc7bqi3n"))))
8154 (build-system python-build-system)
8156 `(("python-markupsafe" ,python-markupsafe)
8157 ("python-mock" ,python-mock)
8158 ("python-nose" ,python-nose)))
8159 (home-page "http://www.makotemplates.org/")
8160 (synopsis "Templating language for Python")
8161 (description "Mako is a templating language for Python that compiles
8162 templates into Python modules.")
8163 (license license:expat)
8164 (properties `((python2-variant . ,(delay python2-mako))))))
8166 (define-public python2-mako
8167 (let ((base (package-with-python2
8168 (strip-python2-variant python-mako))))
8172 (cons `("python2-setuptools" ,python2-setuptools)
8173 (package-native-inputs base))))))
8175 (define-public python-waitress
8177 (name "python-waitress")
8182 (uri (pypi-uri "waitress" version))
8185 "017n9ra6vvmq9d5sfhdzyzr1mg15x2hj2dhm4pdlw98c1ypw2h3w"))))
8186 (build-system python-build-system)
8187 (home-page "https://github.com/Pylons/waitress")
8188 (synopsis "Waitress WSGI server")
8189 (description "Waitress is meant to be a production-quality pure-Python WSGI
8190 server with very acceptable performance.")
8191 (license license:zpl2.1)
8192 (properties `((python2-variant . ,(delay python2-waitress))))))
8194 (define-public python2-waitress
8196 (inherit (package-with-python2
8197 (strip-python2-variant python-waitress)))
8198 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
8200 (define-public python-wsgiproxy2
8202 (name "python-wsgiproxy2")
8207 (uri (pypi-uri "WSGIProxy2" version ".zip"))
8210 "13kf9bdxrc95y9vriaz0viry3ah11nz4rlrykcfvb8nlqpx3dcm4"))))
8211 (build-system python-build-system)
8213 '(;; Wsgiproxy2's test suite requires Restkit, which does not yet fully
8214 ;; support Python 3:
8215 ;; https://github.com/benoitc/restkit/issues/140
8219 ("python-nose" ,python-nose)
8220 ("python-coverage" ,python-coverage)))
8222 `(("python-six" ,python-six)
8223 ("python-webob" ,python-webob)))
8225 "https://github.com/gawel/WSGIProxy2/")
8226 (synopsis "WSGI Proxy with various http client backends")
8227 (description "WSGI turns HTTP requests into WSGI function calls.
8228 WSGIProxy turns WSGI function calls into HTTP requests.
8229 It also includes code to sign requests and pass private data,
8230 and to spawn subprocesses to handle requests.")
8231 (license license:expat)
8232 (properties `((python2-variant . ,(delay python2-wsgiproxy2))))))
8234 (define-public python2-wsgiproxy2
8235 (let ((wsgiproxy2 (package-with-python2
8236 (strip-python2-variant python-wsgiproxy2))))
8238 (inherit wsgiproxy2)
8239 (inputs `(("python2-setuptools" ,python2-setuptools)
8240 ,@(package-inputs wsgiproxy2))))))
8242 (define-public python-pastedeploy
8244 (name "python-pastedeploy")
8249 (uri (pypi-uri "PasteDeploy" version))
8252 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
8253 (build-system python-build-system)
8255 `(("python-nose" ,python-nose)))
8257 ;; This package uses pkg_resources, part of setuptools, during runtime,
8258 ;; hence why not a native-input.
8259 `(("python-setuptools" ,python-setuptools)))
8260 (home-page "http://pythonpaste.org/deploy/")
8262 "Load, configure, and compose WSGI applications and servers")
8264 "This tool provides code to load WSGI applications and servers from URIs;
8265 these URIs can refer to Python Eggs for INI-style configuration files. Paste
8266 Script provides commands to serve applications based on this configuration
8268 (license license:expat)))
8270 (define-public python2-pastedeploy
8271 (package-with-python2 python-pastedeploy))
8273 (define-public python-paste
8275 (name "python-paste")
8280 (uri (pypi-uri "Paste" version))
8283 "16dsv9qi0r4qsrsb6dilpq2rx0fnglvh36flzywcdnm2jg43mb5d"))
8284 (patches (search-patches "python-paste-remove-website-test.patch"
8285 "python-paste-remove-timing-test.patch"))))
8286 (build-system python-build-system)
8288 `(("python-nose" ,python-nose)))
8290 `(;; Uses pkg_resources provided by setuptools internally.
8291 ("python-setuptools" ,python-setuptools)
8292 ("python-six" ,python-six)))
8294 '(;; Tests don't pass on Python 3, but work fine on Python 2.
8295 ;; (As of 2.0.2, Python 3 support in Paste is presently a bit broken,
8296 ;; but is usable enough for the minimal amount it's used in MediaGoblin
8297 ;; still... things should be better by the next Paste release.)
8299 (home-page "http://pythonpaste.org")
8301 "Python web development tools, focusing on WSGI")
8303 "Paste provides a variety of web development tools and middleware which
8304 can be nested together to build web applications. Paste's design closely
8305 follows ideas flowing from WSGI (Web Standard Gateway Interface).")
8306 (license license:expat)
8307 (properties `((python2-variant . ,(delay python2-paste))))))
8309 (define-public python2-paste
8310 (let ((paste (package-with-python2
8311 (strip-python2-variant python-paste))))
8315 ;; Tests are back for Python 2!
8317 ,@(package-arguments paste))))))
8319 (define-public python-pastescript
8321 (name "python-pastescript")
8326 (uri (pypi-uri "PasteScript" version))
8329 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
8330 (build-system python-build-system)
8332 `(("python-nose" ,python-nose)))
8334 `(;; Uses pkg_resources provided by setuptools internally.
8335 ("python-setuptools" ,python-setuptools)
8336 ("python-paste" ,python-paste)
8337 ("python-pastedeploy" ,python-pastedeploy)))
8338 (home-page "http://pythonpaste.org/script/")
8340 '(;; Unfortunately, this requires the latest unittest2,
8341 ;; but that requires traceback2 which requires linecache2 which requires
8342 ;; unittest2. So we're skipping tests for now.
8343 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
8344 ;; so in theory we could get around this situation somehow.)
8347 "Pluggable command line tool for serving web applications and more")
8349 "PasteScript is a plugin-friendly command line tool which provides a
8350 variety of features, from launching web applications to bootstrapping project
8352 (license license:expat)))
8354 (define-public python2-pastescript
8355 (package-with-python2 python-pastescript))
8357 (define-public python-pyquery
8359 (name "python-pyquery")
8364 (uri (pypi-uri "pyquery" version))
8367 "0j9fsisip21qv4xljsg5dmni1pgpvwrjyyhhql0glydc4bs5rjgv"))))
8368 (build-system python-build-system)
8370 `(("python-webob" ,python-webob)
8371 ("python-webtest" ,python-webtest)))
8373 `(("python-lxml" ,python-lxml)
8374 ("python-cssselect" ,python-cssselect)))
8375 (home-page "https://github.com/gawel/pyquery")
8376 (synopsis "Make jQuery-like queries on xml documents")
8377 (description "pyquery allows you to make jQuery queries on xml documents.
8378 The API is as much as possible the similar to jQuery. pyquery uses lxml for
8379 fast xml and html manipulation.")
8380 (license license:bsd-3)
8381 (properties `((python2-variant . ,(delay python2-pyquery))))))
8383 (define-public python2-pyquery
8384 (let ((pyquery (package-with-python2
8385 (strip-python2-variant python-pyquery))))
8388 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8389 ,@(package-native-inputs pyquery))))))
8391 (define-public python-webtest
8393 (name "python-webtest")
8398 (uri (pypi-uri "WebTest" version))
8401 "0bv0qhdjakdsdgj4sk21gnpp8xp8bga4x03p6gjb83ihrsb7n4xv"))))
8402 (build-system python-build-system)
8404 `(;; Unfortunately we have to disable tests!
8405 ;; This release of WebTest is pinned to python-nose < 1.3,
8406 ;; but older versions of python-nose are plagued with the following
8407 ;; bug(s), which rears its ugly head during test execution:
8408 ;; https://github.com/nose-devs/nose/issues/759
8409 ;; https://github.com/nose-devs/nose/pull/811
8411 ;; Commented out code is no good, but in this case, once tests
8412 ;; are ready to be enabled again, we should put the following
8415 ;; `(("python-nose" ,python-nose) ; technially < 1.3,
8416 ;; ; but see above comment
8417 ;; ("python-coverage" ,python-coverage)
8418 ;; ("python-mock" ,python-mock)
8419 ;; ("python-pastedeploy" ,python-pastedeploy)
8420 ;; ("python-wsgiproxy2" ,python-wsgiproxy2)
8421 ;; ("python-pyquery" ,python-pyquery)))
8423 `(("python-waitress" ,python-waitress)
8424 ("python-webob" ,python-webob)
8425 ("python-six" ,python-six)
8426 ("python-beautifulsoup4" ,python-beautifulsoup4)))
8427 (home-page "http://webtest.pythonpaste.org/")
8428 (synopsis "Helper to test WSGI applications")
8429 (description "Webtest allows you to test your Python web applications
8430 without starting an HTTP server. It supports anything that supports the
8432 (license license:expat)
8433 (properties `((python2-variant . ,(delay python2-webtest))))))
8435 (define-public python2-webtest
8436 (let ((webtest (package-with-python2
8437 (strip-python2-variant python-webtest))))
8440 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8441 ,@(package-native-inputs webtest))))))
8443 (define-public python-anyjson
8445 (name "python-anyjson")
8450 (uri (pypi-uri "anyjson" version))
8453 "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
8454 (build-system python-build-system)
8456 `(;; We could possibly get tests working, but on Python 3 it's not so easy.
8457 ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
8458 ;; whatever) so this transformation needs to be done before the tests
8459 ;; can be run. Maybe we could add a build step to transform beforehand
8460 ;; but it could be annoying/difficult.
8461 ;; We can enable tests for the Python 2 version, though, and do below.
8463 (home-page "http://bitbucket.org/runeh/anyjson/")
8465 "Wraps best available JSON implementation in a common interface")
8467 "Anyjson loads whichever is the fastest JSON module installed
8468 and provides a uniform API regardless of which JSON implementation is used.")
8469 (license license:bsd-3)
8470 (properties `((python2-variant . ,(delay python2-anyjson))))))
8472 (define-public python2-anyjson
8473 (let ((anyjson (package-with-python2
8474 (strip-python2-variant python-anyjson))))
8477 (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
8479 ,@(package-arguments anyjson)))
8480 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8481 ("python2-nose" ,python2-nose))))))
8483 (define-public python-amqp
8485 (name "python-amqp")
8490 (uri (pypi-uri "amqp" version))
8493 "06n6q0kxhjnbfz3vn8x9yz09lwmn1xi9d6wxp31h5jbks0b4vsid"))))
8494 (build-system python-build-system)
8496 `(("python-nose" ,python-nose)
8497 ("python-mock" ,python-mock)))
8498 (home-page "http://github.com/celery/py-amqp")
8500 "Low-level AMQP client for Python (fork of amqplib)")
8502 "This is a fork of amqplib which was originally written by Barry Pederson.
8503 It is maintained by the Celery project, and used by kombu as a pure python
8504 alternative when librabbitmq is not available.")
8505 (license license:lgpl2.1+)
8506 (properties `((python2-variant . ,(delay python2-amqp))))))
8508 (define-public python2-amqp
8509 (let ((amqp (package-with-python2
8510 (strip-python2-variant python-amqp))))
8513 (arguments `(;; Tries to run coverage tests with nose-cover3, which seems
8514 ;; unmaintained. Weirdly, does not do this on the python 3
8517 ,@(package-arguments amqp)))
8518 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8519 ,@(package-native-inputs amqp))))))
8521 (define-public python-kombu
8523 (name "python-kombu")
8528 (uri (pypi-uri "kombu" version))
8531 "16brjx2lgwbj2a37d0pjbfb84nvld6irghmqrs3qfncajp51hgc5"))))
8532 (build-system python-build-system)
8534 `(("python-mock" ,python-mock)
8535 ("python-nose" ,python-nose)))
8537 `(("python-anyjson" ,python-anyjson)
8538 ("python-amqp" ,python-amqp)))
8539 (home-page "http://kombu.readthedocs.org")
8540 (synopsis "Message passing library for Python")
8541 (description "The aim of Kombu is to make messaging in Python as easy as
8542 possible by providing an idiomatic high-level interface for the AMQ protocol,
8543 and also provide proven and tested solutions to common messaging problems.
8544 AMQP is the Advanced Message Queuing Protocol, an open standard protocol for
8545 message orientation, queuing, routing, reliability and security, for which the
8546 RabbitMQ messaging server is the most popular implementation.")
8547 (license license:bsd-3)
8548 (properties `((python2-variant . ,(delay python2-kombu))))))
8550 (define-public python2-kombu
8551 (let ((kombu (package-with-python2
8552 (strip-python2-variant python-kombu))))
8555 (inputs `(("python2-setuptools" ,python2-setuptools)
8556 ("python2-unittest2" ,python2-unittest2)
8557 ,@(package-inputs kombu))))))
8559 (define-public python-billiard
8561 (name "python-billiard")
8562 (version "3.3.0.22")
8566 (uri (pypi-uri "billiard" version))
8569 "0zp7h6a58alrb3mwdw61jds07395j4j0mj6iqsb8czrihw9ih5nj"))))
8570 (build-system python-build-system)
8572 `(("python-nose" ,python-nose)))
8573 (home-page "http://github.com/celery/billiard")
8575 "Python multiprocessing fork with improvements and bugfixes")
8577 "Billiard is a fork of the Python 2.7 multiprocessing package. The
8578 multiprocessing package itself is a renamed and updated version of R Oudkerk's
8579 pyprocessing package. This standalone variant is intended to be compatible with
8580 Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.")
8581 (license license:bsd-3)
8582 (properties `((python2-variant . ,(delay python2-billiard))))))
8584 (define-public python2-billiard
8585 (let ((billiard (package-with-python2
8586 (strip-python2-variant python-billiard))))
8589 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8590 ("python2-unittest2" ,python2-unittest2)
8591 ("python2-mock" ,python2-mock)
8592 ,@(package-native-inputs billiard))))))
8594 (define-public python-celery
8596 (name "python-celery")
8601 (uri (pypi-uri "celery" version))
8604 "1md6ywg1s0946qyp8ndnsd677wm0yax933h2sb4m3a4j7lf1jbyh"))))
8605 (build-system python-build-system)
8607 `(("python-nose" ,python-nose)))
8609 `(("python-pytz" ,python-pytz)
8610 ("python-amqp" ,python-amqp)
8611 ("python-anyjson" ,python-anyjson)
8612 ("python-billiard" ,python-billiard)
8613 ("python-kombu" ,python-kombu)))
8614 (home-page "http://celeryproject.org")
8615 (synopsis "Distributed Task Queue")
8616 (description "Celery is an asynchronous task queue/job queue based on
8617 distributed message passing. It is focused on real-time operation, but
8618 supports scheduling as well. The execution units, called tasks, are executed
8619 concurrently on a single or more worker servers using multiprocessing,
8620 Eventlet, or gevent. Tasks can execute asynchronously (in the background) or
8621 synchronously (wait until ready).")
8622 (license license:bsd-3)
8623 (properties `((python2-variant . ,(delay python2-celery))))))
8625 (define-public python2-celery
8626 (let ((celery (package-with-python2
8627 (strip-python2-variant python-celery))))
8630 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8631 ("python2-unittest2" ,python2-unittest2)
8632 ("python2-mock" ,python2-mock)
8633 ,@(package-native-inputs celery))))))
8635 (define-public python-translitcodec
8637 (name "python-translitcodec")
8642 (uri (pypi-uri "translitcodec" version))
8645 "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki"))))
8646 (build-system python-build-system)
8648 `(#:tests? #f)) ; no tests provided
8650 "https://github.com/claudep/translitcodec")
8652 "Unicode to 8-bit charset transliteration codec")
8654 "This package contains codecs for transliterating ISO 10646 texts into
8655 best-effort representations using smaller coded character sets (ASCII,
8657 (license license:expat)
8658 (properties `((python2-variant . ,(delay python2-translitcodec))))))
8660 (define-public python2-translitcodec
8662 (inherit (package-with-python2
8663 (strip-python2-variant python-translitcodec)))
8664 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
8666 (define-public python-editor
8668 (name "python-editor")
8673 (uri (pypi-uri "python-editor" version))
8676 "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n"))))
8677 (build-system python-build-system)
8679 "https://github.com/fmoo/python-editor")
8681 "Programmatically open an editor, capture the result")
8683 "python-editor is a library that provides the editor module for
8684 programmatically interfacing with your system's $EDITOR.")
8685 (license license:asl2.0)
8686 (properties `((python2-variant . ,(delay python2-editor))))))
8688 (define-public python2-editor
8690 (inherit (package-with-python2
8691 (strip-python2-variant python-editor)))
8692 (inputs `(("python2-setuptools" ,python2-setuptools)))))
8694 (define-public python-sphinxcontrib-programoutput
8696 (name "python-sphinxcontrib-programoutput")
8700 (uri (pypi-uri "sphinxcontrib-programoutput" version))
8703 "098as6z1s0gb4dh5xcr1fd2vpm91zj93jzvgawspxf5s4hqs0xhp"))))
8704 (build-system python-build-system)
8706 `(("python-docutils" ,python-docutils)
8707 ("python-sphinx" ,python-sphinx)))
8708 (synopsis "Sphinx extension to include program output")
8709 (description "A Sphinx extension to literally insert the output of arbitrary
8710 commands into documents, helping you to keep your command examples up to date.")
8711 (home-page "https://github.com/lunaryorn/sphinxcontrib-programoutput")
8712 (license license:bsd-2)
8713 (properties `((python2-variant . ,(delay python2-sphinxcontrib-programoutput))))))
8715 (define-public python2-sphinxcontrib-programoutput
8717 (inherit (package-with-python2
8718 (strip-python2-variant python-sphinxcontrib-programoutput)))
8719 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
8721 (define-public python-sphinx-repoze-autointerface
8723 (name "python-sphinx-repoze-autointerface")
8727 (uri (pypi-uri "repoze.sphinx.autointerface" version))
8730 "08ycivzf7bh4a1zcyp31hbyqs1b2c9r26raa3vxjwwmbfqr3iw4f"))))
8731 (build-system python-build-system)
8733 `(("python-docutils" ,python-docutils)
8734 ("python-sphinx" ,python-sphinx)
8735 ("python-zope-interface" ,python-zope-interface)))
8736 (synopsis "Auto-generate Sphinx API docs from Zope interfaces")
8737 (description "This package defines an extension for the Sphinx documentation
8738 system. The extension allows generation of API documentation by
8739 introspection of @code{zope.interface} instances in code.")
8740 (home-page "https://github.com/repoze/repoze.sphinx.autointerface")
8741 (license license:repoze)))
8743 (define-public python2-sphinx-repoze-autointerface
8744 (package-with-python2 python-sphinx-repoze-autointerface))
8746 (define-public python-psycopg2
8748 (name "python-psycopg2")
8753 (uri (pypi-uri "psycopg2" version))
8756 "0k4hshvrwsh8yagydyxgmd0pjm29lwdxkngcq9fzfzkmpsxrmkva"))))
8757 (build-system python-build-system)
8759 ;; Tests would require a postgresql database "psycopg2_test"
8760 ;; and a running postgresql database management service.
8761 `(#:tests? #f)) ; TODO re-enable after providing a test-db.
8763 `(("postgresql" ,postgresql))) ; libpq
8764 (home-page "http://initd.org/psycopg/")
8765 (synopsis "Python PostgreSQL adapter")
8767 "psycopg2 is a thread-safe PostgreSQL adapter that implements DB-API 2.0. ")
8768 (license license:lgpl3+)
8769 (properties `((python2-variant . ,(delay python2-psycopg2))))))
8771 (define-public python2-psycopg2
8773 (inherit (package-with-python2
8774 (strip-python2-variant python-psycopg2)))
8775 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
8777 (define-public python-vobject
8779 (name "python-vobject")
8783 (uri (pypi-uri "vobject" version))
8786 "1qfnwlx8qwkgr6nf5wvl6ff1r3kll53dh3z6nyp173nmlhhhqccb"))))
8787 (build-system python-build-system)
8789 `(("python-dateutil-2" ,python-dateutil-2)
8790 ("python-pyicu" ,python-pyicu)))
8791 (synopsis "Parse and generate vCard and vCalendar files")
8792 (description "Vobject is intended to be a full featured Python package for
8793 parsing and generating vCard and vCalendar files. Currently, iCalendar files
8794 are supported and well tested. vCard 3.0 files are supported, and all data
8795 should be imported, but only a few components are understood in a sophisticated
8797 (home-page "http://eventable.github.io/vobject/")
8798 (license license:asl2.0)
8799 (properties `((python2-variant . ,(delay python2-vobject))))))
8801 (define-public python2-vobject
8803 (inherit (package-with-python2
8804 (strip-python2-variant python-vobject)))
8805 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
8807 (define-public python-munkres
8809 (name "python-munkres")
8813 (uri (pypi-uri "munkres" version))
8816 "1i6nf45i0kkzdx6k70giybsqxz4dxsjbrkrfqgjd7znfkf25sjik"))))
8817 (build-system python-build-system)
8819 '(#:tests? #f)) ; no test suite
8820 (home-page "http://software.clapper.org/munkres/")
8821 (synopsis "Implementation of the Munkres algorithm")
8822 (description "The Munkres module provides an implementation of the Munkres
8823 algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm),
8824 useful for solving the Assignment Problem.")
8825 (license license:bsd-3)))
8827 (define-public python2-munkres
8828 (package-with-python2 python-munkres))
8830 (define-public python-flask
8832 (name "python-flask")
8836 (uri (pypi-uri "Flask" version))
8839 "0wrkavjdjndknhp8ya8j850jq7a1cli4g5a93mg8nh1xz2gq50sc"))))
8840 (build-system python-build-system)
8842 `(("python-itsdangerous" ,python-itsdangerous)
8843 ("python-jinja2" ,python-jinja2)
8844 ("python-werkzeug" ,python-werkzeug)))
8845 (home-page "https://github.com/mitsuhiko/flask/")
8846 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
8847 (description "Flask is a micro web framework based on the Werkzeug toolkit
8848 and Jinja2 template engine. It is called a micro framework because it does not
8849 presume or force a developer to use a particular tool or library.")
8850 (license license:bsd-3)
8851 (properties `((python2-variant . ,(delay python2-flask))))))
8853 (define-public python2-flask
8854 (package (inherit (package-with-python2
8855 (strip-python2-variant python-flask)))
8856 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
8858 (define-public python-cookies
8860 (name "python-cookies")
8864 (uri (pypi-uri "cookies" version))
8867 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
8868 (build-system python-build-system)
8870 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
8873 `(("python-pytest" ,python2-pytest)))
8874 (synopsis "HTTP cookie parser and renderer")
8875 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
8877 (home-page "https://gitlab.com/sashahart/cookies")
8878 (license license:expat)
8879 (properties `((python2-variant . ,(delay python2-cookies))))))
8881 (define-public python2-cookies
8882 (let ((cookies (package-with-python2
8883 (strip-python2-variant python-cookies))))
8884 (package (inherit cookies)
8885 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8886 ,@(package-native-inputs cookies))))))
8888 (define-public python-responses
8890 (name "python-responses")
8894 (uri (pypi-uri "responses" version))
8897 "1spcfxixyk9k7pk82jm6zqkwk031s95lh8q0mz7539jrb7269bcc"))))
8898 (build-system python-build-system)
8900 `(;; Test suite is not distributed:
8901 ;; https://github.com/getsentry/responses/issues/38
8904 `(("python-cookies" ,python-cookies)
8905 ("python-mock" ,python-mock)))
8907 `(("python-requests" ,python-requests)
8908 ("python-six" ,python-six)))
8909 (home-page "https://github.com/getsentry/responses")
8910 (synopsis "Utility for mocking out the `requests` Python library")
8911 (description "A utility library for mocking out the `requests` Python
8913 (license license:asl2.0)
8914 (properties `((python2-variant . ,(delay python2-responses))))))
8916 (define-public python2-responses
8917 (let ((responses (package-with-python2
8918 (strip-python2-variant python-responses))))
8919 (package (inherit responses)
8920 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8921 ,@(package-native-inputs responses))))))
8923 (define-public python-whoosh
8925 (name "python-whoosh")
8930 (uri (pypi-uri "Whoosh" version))
8933 "10qsqdjpbc85fykc1vgcs8xwbgn4l2l52c8d83xf1q59pwyn79bw"))))
8934 (build-system python-build-system)
8936 `(("python-setuptools" ,python-setuptools)
8937 ("python-pytest" ,python-pytest)))
8938 (home-page "http://bitbucket.org/mchaput/whoosh")
8939 (synopsis "Full text indexing, search, and spell checking library")
8941 "Whoosh is a fast, pure-Python full text indexing, search, and spell
8943 (license license:bsd-2)))
8945 (define-public python2-whoosh
8946 (let ((whoosh (package-with-python2 (strip-python2-variant python-whoosh))))
8947 (package (inherit whoosh)
8949 `(("python2-backport-ssl-match-hostname"
8950 ,python2-backport-ssl-match-hostname)
8951 ,@(package-propagated-inputs whoosh))))))
8953 (define-public python-pathlib
8955 (name "python-pathlib")
8959 (uri (pypi-uri "pathlib" version))
8962 "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39"))))
8963 (build-system python-build-system)
8964 ;; The tests depend on the internal "test" module, which does not provide
8965 ;; a stable interface.
8966 (arguments `(#:tests? #f))
8967 (home-page "https://pathlib.readthedocs.org/")
8968 (synopsis "Object-oriented file system paths")
8969 (description "Pathlib offers a set of classes to handle file system paths.
8970 It offers the following advantages over using string objects:
8973 @item No more cumbersome use of os and os.path functions. Everything can
8974 be done easily through operators, attribute accesses, and method calls.
8975 @item Embodies the semantics of different path types. For example,
8976 comparing Windows paths ignores casing.
8977 @item Well-defined semantics, eliminating any inconsistencies or
8978 ambiguities (forward vs. backward slashes, etc.).
8981 Note: In Python 3.4, pathlib is now part of the standard library. For other
8982 Python versions please consider python-pathlib2 instead, which tracks the
8983 standard library module. This module (python-pathlib) isn't maintained
8985 (license license:expat)))
8987 (define-public python2-pathlib
8988 (package-with-python2 python-pathlib))
8990 (define-public python2-pathlib2
8992 (name "python2-pathlib2")
8996 (uri (pypi-uri "pathlib2" version))
8999 "0p050msg5c8d0kadv702jnfshaxrb0il765cpkgnhn6mq5hakcyy"))))
9000 (build-system python-build-system)
9001 ;; We only need the the Python 2 variant, since for Python 3 our minimum
9002 ;; version is 3.4 which already includes this package as part of the
9003 ;; standard library.
9005 `(#:python ,python-2))
9007 `(("python2-setuptools" ,python2-setuptools)
9008 ("python2-six" ,python2-six)))
9009 (home-page "http://pypi.python.org/pypi/pathlib2/")
9010 (synopsis "Object-oriented file system paths - backport of standard
9012 (description "The goal of pathlib2 is to provide a backport of standard
9013 pathlib module which tracks the standard library module, so all the newest
9014 features of the standard pathlib can be used also on older Python versions.
9016 Pathlib offers a set of classes to handle file system paths. It offers the
9017 following advantages over using string objects:
9020 @item No more cumbersome use of os and os.path functions. Everything can
9021 be done easily through operators, attribute accesses, and method calls.
9022 @item Embodies the semantics of different path types. For example,
9023 comparing Windows paths ignores casing.
9024 @item Well-defined semantics, eliminating any inconsistencies or
9025 ambiguities (forward vs. backward slashes, etc.).
9027 (license license:expat)))
9029 (define-public python-jellyfish
9031 (name "python-jellyfish")
9035 (uri (pypi-uri "jellyfish" version))
9038 "12bxh8cy9xmvyrjz7aw159nd5pyvb645rkvw4r6bvm4xbvs8gd07"))))
9039 (build-system python-build-system)
9041 `(("python-pytest" ,python-pytest)))
9042 (home-page "https://github.com/jamesturk/jellyfish")
9043 (synopsis "Approximate and phonetic matching of strings")
9044 (description "Jellyfish uses a variety of string comparison and phonetic
9045 encoding algorithms to do fuzzy string matching.")
9046 (license license:bsd-2)
9047 (properties `((python2-variant . ,(delay python2-jellyfish))))))
9049 (define-public python2-jellyfish
9050 (let ((jellyfish (package-with-python2
9051 (strip-python2-variant python-jellyfish))))
9052 (package (inherit jellyfish)
9053 (native-inputs `(("python2-setuptools" ,python2-setuptools)
9054 ("python2-unicodecsv" ,python2-unicodecsv)
9055 ,@(package-native-inputs jellyfish))))))
9057 (define-public python2-unicodecsv
9059 (name "python2-unicodecsv")
9063 ;; The test suite is not included in the PyPi release.
9064 ;; https://github.com/jdunck/python-unicodecsv/issues/19
9065 (uri (string-append "https://github.com/jdunck/python-unicodecsv/"
9066 "archive/" version ".tar.gz"))
9067 (file-name (string-append name "-" version ".tar.gz"))
9070 "087nqanfcyp6mlfbbr5lva5f3w6iz1bybls9xlrb8icmc474wh4w"))))
9071 (build-system python-build-system)
9073 `(;; It supports Python 3, but Python 3 can already do Unicode CSV.
9074 #:python ,python-2))
9076 `(("python2-setuptools" ,python2-setuptools)
9077 ("python2-unittest2" ,python2-unittest2)))
9078 (home-page "https://github.com/jdunck/python-unicodecsv")
9079 (synopsis "Unicode CSV module for Python 2")
9080 (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV
9081 module, adding support for Unicode strings.")
9082 (license license:bsd-2)))
9084 (define-public python-rarfile
9086 (name "python-rarfile")
9090 (uri (pypi-uri "rarfile" version))
9093 "0d8n1dlpiz7av8dmbp0vclrwl9cnxizr4f2c9xvj1h5nvn480527"))
9094 ;; https://github.com/markokr/rarfile/pull/17/
9095 (patches (search-patches "python-rarfile-fix-tests.patch"))))
9096 (build-system python-build-system)
9099 (modify-phases %standard-phases
9101 ;; Many tests fail, but the installation proceeds.
9102 (lambda _ (zero? (system* "make" "-C" "test" "test")))))))
9104 `(("which" ,which))) ; required for tests
9106 `(("libarchive" ,libarchive)))
9107 (home-page "https://github.com/markokr/rarfile")
9108 (synopsis "RAR archive reader for Python")
9109 (description "This is Python module for RAR archive reading. The interface
9110 is made as zipfile like as possible.")
9111 (license license:isc)))
9113 (define-public python2-rarfile
9114 (package-with-python2 python-rarfile))
9116 (define-public python-magic
9118 (name "python-magic")
9123 (uri (string-append "https://github.com/ahupp/python-magic/archive/"
9127 "17bgy92i7sb021f2s4mw1dcvpm6p1mi9jihridwy1pyn8mzvpjgk"))
9128 (file-name (string-append name "-" version "-checkout"))))
9129 (build-system python-build-system)
9131 ;; The tests are unreliable, so don't run them. The tests fail
9132 ;; under Python3 because they were written for Python2 and
9133 ;; contain import statements that do not work in Python3. One of
9134 ;; the tests fails under Python2 because its assertions are
9135 ;; overly stringent; it relies on comparing output strings which
9136 ;; are brittle and can change depending on the version of
9137 ;; libmagic being used and the system on which the test is
9138 ;; running. In my case, under GuixSD 0.10.0, only one test
9139 ;; failed, and it seems to have failed only because the version
9140 ;; of libmagic that is packaged in Guix outputs a slightly
9141 ;; different (but not wrong) string than the one that the test
9144 #:phases (modify-phases %standard-phases
9145 ;; Replace a specific method call with a hard-coded
9146 ;; path to the necessary libmagic.so file in the
9147 ;; store. If we don't do this, then the method call
9148 ;; will fail to find the libmagic.so file, which in
9149 ;; turn will cause any application using
9150 ;; python-magic to fail.
9151 (add-before 'build 'hard-code-path-to-libmagic
9152 (lambda* (#:key inputs #:allow-other-keys)
9153 (let ((file (assoc-ref inputs "file")))
9154 (substitute* "magic.py"
9155 (("ctypes.util.find_library\\('magic'\\)")
9156 (string-append "'" file "/lib/libmagic.so'")))
9158 (add-before 'install 'disable-egg-compression
9160 (let ((port (open-file "setup.cfg" "a")))
9161 (display "\n[easy_install]\nzip_ok = 0\n"
9166 `(("python-setuptools" ,python-setuptools)))
9168 ;; python-magic needs to be able to find libmagic.so.
9170 (home-page "https://github.com/ahupp/python-magic")
9171 (synopsis "File type identification using libmagic")
9173 "This module uses ctypes to access the libmagic file type
9174 identification library. It makes use of the local magic database and
9175 supports both textual and MIME-type output. Note that this module and
9176 the python-file module both provide a \"magic.py\" file; these two
9177 modules, which are different and were developed separately, both serve
9178 the same purpose: to provide Python bindings for libmagic.")
9179 (license license:expat)))
9181 (define-public python2-magic
9182 (package-with-python2 python-magic))
9184 (define-public python2-s3cmd
9186 (name "python2-s3cmd")
9191 (uri (string-append "mirror://sourceforge/s3tools/s3cmd/" version "/"
9192 "s3cmd-" version ".tar.gz"))
9195 "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6"))))
9196 (build-system python-build-system)
9198 ;; s3cmd is written for python2 only and contains no tests.
9199 `(#:python ,python-2
9202 `(("python2-setuptools" ,python2-setuptools)))
9204 `(("python2-dateutil" ,python2-dateutil)
9205 ;; The python-file package also provides a magic.py module.
9206 ;; This is an unfortunate state of affairs; however, s3cmd
9207 ;; fails to install if it cannot find specifically the
9208 ;; python-magic package. Thus we include it, instead of using
9209 ;; python-file. Ironically, s3cmd sometimes works better
9210 ;; without libmagic bindings at all:
9211 ;; https://github.com/s3tools/s3cmd/issues/198
9212 ("python2-magic" ,python2-magic)))
9213 (home-page "http://s3tools.org/s3cmd")
9214 (synopsis "Command line tool for S3-compatible storage services")
9216 "S3cmd is a command line tool for uploading, retrieving and managing data
9217 in storage services that are compatible with the Amazon Simple Storage
9218 Service (S3) protocol, including S3 itself. It supports rsync-like backup,
9219 GnuPG encryption, and more. It also supports management of Amazon's
9220 CloudFront content delivery network.")
9221 (license license:gpl2+)))
9223 (define-public python-pkgconfig
9225 (name "python-pkgconfig")
9230 (uri (pypi-uri "pkgconfig" version))
9233 "1pw0kmvc57sjmaxi6c54fqsnihqj6hvhc9y1vaz36axafzqam7bh"))))
9234 (build-system python-build-system)
9236 `(("python-nose" ,python-nose)
9237 ("python-setuptools" ,python-setuptools)))
9239 `(("pkg-config" ,pkg-config)))
9241 `(;; Tests fail with "ValueError: _type_ 'v' not supported" on Python 3,
9242 ;; and on Python 2 they need the dl module deprecated since Python 2.6.
9244 ;; Prevent creation of the egg. This works around
9245 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
9246 #:configure-flags '("--single-version-externally-managed" "--root=/")
9247 ;; Hard-code the path to pkg-config.
9249 (modify-phases %standard-phases
9253 (substitute* "pkgconfig/pkgconfig.py"
9254 (("cmd = 'pkg-config")
9255 (string-append "cmd = '" (which "pkg-config"))))
9257 (home-page "http://github.com/matze/pkgconfig")
9258 (synopsis "Python interface for pkg-config")
9259 (description "This module provides a Python interface to pkg-config. It
9260 can be used to find all pkg-config packages, check if a package exists,
9261 check if a package meets certain version requirements, query CFLAGS and
9262 LDFLAGS and parse the output to build extensions with setup.py.")
9263 (license license:expat)))
9265 (define-public python2-pkgconfig
9266 (package-with-python2 python-pkgconfig))
9268 (define-public python-bz2file
9270 (name "python-bz2file")
9275 (uri (pypi-uri "bz2file" version))
9278 "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4"))))
9279 (build-system python-build-system)
9281 `(#:tests? #f)) ; Tests use deprecated python modules.
9282 (home-page "https://github.com/nvawda/bz2file")
9283 (synopsis "Read and write bzip2-compressed files")
9285 "Bz2file is a Python library for reading and writing bzip2-compressed
9286 files. It contains a drop-in replacement for the I/O interface in the
9287 standard library's @code{bz2} module, including features from the latest
9288 development version of CPython that are not available in older releases.")
9289 (license license:asl2.0)
9290 (properties `((python2-variant . ,(delay python2-bz2file))))))
9292 (define-public python2-bz2file
9293 (let ((base (package-with-python2
9294 (strip-python2-variant python-bz2file))))
9298 `(("python2-setuptools" ,python2-setuptools)))
9300 `(#:python ,python-2
9302 (modify-phases %standard-phases
9303 ;; 'python setup.py test' does not work as of 0.98.
9304 ;; There is only the one test file, so we run it directly.
9306 (lambda _ (zero? (system* "python"
9307 "test_bz2file.py"))))))))))
9309 (define-public python-future
9311 (name "python-future")
9316 (uri (pypi-uri "future" version))
9319 "15wvcfzssc68xqnqi1dq4fhd0848hwi9jn42hxyvlqna40zijfrx"))))
9320 (build-system python-build-system)
9321 ;; Many tests connect to the network or are otherwise flawed.
9322 ;; https://github.com/PythonCharmers/python-future/issues/210
9325 (home-page "http://python-future.org")
9326 (synopsis "Single-source support for Python 3 and 2")
9328 "@code{python-future} is the missing compatibility layer between Python 2 and
9329 Python 3. It allows you to use a single, clean Python 3.x-compatible codebase
9330 to support both Python 2 and Python 3 with minimal overhead.")
9331 (license license:expat)
9332 (properties `((python2-variant . ,(delay python2-future))))))
9334 (define-public python2-future
9335 (let ((base (package-with-python2
9336 (strip-python2-variant python-future))))
9339 (native-inputs `(("python2-setuptools" ,python2-setuptools))))))
9341 (define-public python-cysignals
9343 (name "python-cysignals")
9348 (uri (pypi-uri "cysignals" version ".tar.bz2"))
9351 "14cbyd9znlz6cxy1s3g6v6dv5jj45hn27pywkidd9b1zanaysqc6"))))
9352 (build-system python-build-system)
9354 `(("python-cython" ,python-cython)
9355 ("python-setuptools" ,python-setuptools)
9356 ("python-sphinx" ,python-sphinx)))
9358 `(("pari-gp" ,pari-gp)))
9360 `(#:modules ((guix build python-build-system)
9361 ((guix build gnu-build-system) #:prefix gnu:)
9363 ;; FIXME: Tests are executed after installation and currently fail
9364 ;; when not installing into standard locations; the author is working
9368 (modify-phases %standard-phases
9371 (assoc-ref gnu:%standard-phases 'configure)))))
9373 "https://github.com/sagemath/cysignals")
9375 "Handling of interrupts and signals for Cython")
9377 "The cysignals package provides mechanisms to handle interrupts (and
9378 other signals and errors) in Cython code, using two related approaches,
9379 for mixed Cython/Python code or external C libraries and pure Cython code,
9381 (license license:lgpl3+)))
9383 (define-public python2-cysignals
9384 (package-with-python2 python-cysignals))
9386 (define-public python2-shedskin
9388 (name "python2-shedskin")
9393 (uri (string-append "https://github.com/shedskin/shedskin/"
9394 "releases/download/v" version
9395 "/shedskin-" version ".tgz"))
9398 "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41"))))
9399 (build-system python-build-system)
9401 `(#:python ,python-2
9402 #:phases (modify-phases %standard-phases
9403 (add-after 'unpack 'fix-resulting-include-libs
9404 (lambda* (#:key inputs #:allow-other-keys)
9405 (let ((libgc (assoc-ref inputs "libgc"))
9406 (pcre (assoc-ref inputs "pcre")))
9407 (substitute* "shedskin/makefile.py"
9408 (("variable == 'CCFLAGS':[ ]*")
9409 (string-append "variable == 'CCFLAGS':\n"
9410 " line += ' -I " pcre "/include"
9411 " -I " libgc "/include'"))
9412 (("variable == 'LFLAGS':[ ]*")
9413 (string-append "variable == 'LFLAGS':\n"
9414 " line += ' -L" pcre "/lib"
9415 " -L " libgc "/lib'")))
9417 (native-inputs `(("python2-setuptools" ,python2-setuptools)))
9418 (inputs `(("pcre" ,pcre)
9420 (home-page "https://shedskin.github.io/")
9421 (synopsis "Experimental Python-2 to C++ Compiler")
9422 (description (string-append "This is an experimental compiler for a subset of
9423 Python. It generates C++ code and a Makefile."))
9424 (license (list license:gpl3 license:bsd-3 license:expat))))
9426 (define-public python2-rope
9428 (name "python2-rope")
9433 (uri (pypi-uri "rope" version))
9436 "18k5znhpwvrfck3yp0jmhd5j8r0f0s8bk1zh5yhs2cfgmfhbwigb"))))
9438 ;; Rope is currently python-2 only.
9439 ;; https://github.com/python-rope/rope/issues/57
9440 `(#:python ,python-2))
9441 (build-system python-build-system)
9443 `(("python2-unittest2" ,python2-unittest2)
9444 ("python2-setuptools" ,python2-setuptools)))
9445 (home-page "https://github.com/python-rope/rope")
9446 (synopsis "Refactoring library for Python")
9447 (description "Rope is a refactoring library for Python. It facilitates
9448 the renaming, moving and extracting of attributes, functions, modules, fields
9449 and parameters in Python 2 source code. These refactorings can also be applied
9450 to occurences in strings and comments.")
9451 (license license:gpl2)))
9453 (define-public python-py3status
9455 (name "python-py3status")
9460 (uri (pypi-uri "py3status" version))
9463 "0i283z1pivmir61z8kbiycigc94l61v33ygzkhczf1ifq7cppyds"))))
9464 (build-system python-build-system)
9466 `(("python-setuptools" ,python-setuptools)))
9467 (home-page "https://github.com/ultrabug/py3status")
9468 (synopsis "Extensible i3status wrapper written in Python")
9469 (description "py3status is an i3status wrapper which extends i3status
9470 functionality in a modular way, allowing you to extend your panel with your
9471 own code, responding to click events and updating clock every second.")
9472 (license license:bsd-3)))
9474 (define-public python-tblib
9476 (name "python-tblib")
9480 (uri (pypi-uri "tblib" version))
9482 "02iahfkfa927hb4jq2bak36ldihwapzacfiq5lyxg8llwn98a1yi"))))
9483 (build-system python-build-system)
9486 (modify-phases %standard-phases
9489 ;; Upstream runs tests after installation and the package itself
9490 ;; resides in a subdirectory. Extend PYTHONPATH so it will be
9492 (setenv "PYTHONPATH"
9493 (string-append (getcwd) "/build/lib:"
9494 (getenv "PYTHONPATH")))
9495 (zero? (system* "py.test" "-vv" "tests" "README.rst")))))))
9497 `(("python-pytest" ,python-pytest)
9498 ("python-setuptools" ,python-setuptools)
9499 ("python-six" ,python-six)))
9500 (home-page "https://github.com/ionelmc/python-tblib")
9501 (synopsis "Traceback serialization library")
9503 "Traceback serialization allows you to:
9506 @item Pickle tracebacks and raise exceptions with pickled tracebacks in
9507 different processes. This allows better error handling when running code over
9508 multiple processes (imagine multiprocessing, billiard, futures, celery etc).
9510 @item Parse traceback strings and raise with the parsed tracebacks.
9512 (license license:bsd-3)))
9514 (define-public python2-tblib
9515 (package-with-python2 python-tblib))
9517 (define-public python-sqlparse
9519 (name "python-sqlparse")
9523 (uri (pypi-uri "sqlparse" version))
9526 "1s2fvaxgh9kqzrd6iwy5h7i61ckn05plx9np13zby93z3hdbx5nq"))))
9527 (build-system python-build-system)
9530 (modify-phases %standard-phases
9533 ;; setup.py-integrated 2to3 only affects the build files, but
9534 ;; py.test is using the source files. So we need to convert them
9536 (when (zero? (system* "python3"))
9537 (system* "2to3" "--no-diff" "-wn" "sqlparse" "tests"))
9538 (zero? (system* "py.test")))))))
9540 `(("python-pytest" ,python-pytest)
9541 ("python-setuptools" ,python-setuptools)))
9542 (home-page "https://github.com/andialbrecht/sqlparse")
9543 (synopsis "Non-validating SQL parser")
9544 (description "Sqlparse is a non-validating SQL parser for Python. It
9545 provides support for parsing, splitting and formatting SQL statements.")
9546 (license license:bsd-3)))
9548 (define-public python2-sqlparse
9549 (package-with-python2 python-sqlparse))
9551 (define-public python-greenlet
9553 (name "python-greenlet")
9557 (uri (pypi-uri "greenlet" version))
9560 "04h0m54dyqg49vyarq26mry6kbivnpl47rnmmrk9qn8wpfxviybr"))))
9561 (build-system python-build-system)
9563 `(("python-setuptools" ,python-setuptools)))
9564 (home-page "https://greenlet.readthedocs.io/")
9565 (synopsis "Lightweight in-process concurrent programming")
9567 "Greenlet package is a spin-off of Stackless, a version of CPython
9568 that supports micro-threads called \"tasklets\". Tasklets run
9569 pseudo-concurrently (typically in a single or a few OS-level threads) and
9570 are synchronized with data exchanges on \"channels\".")
9571 (license (list license:psfl license:expat))))
9573 (define-public python2-greenlet
9574 (package-with-python2 python-greenlet))
9576 (define-public python-gevent
9578 (name "python-gevent")
9582 (uri (pypi-uri "gevent" version))
9585 "1smf3kvidpdiyi2c81alal74p2zm0clrm6xbyy6y1k9a3f2vkrbf"))
9586 (modules '((guix build utils)))
9589 ;; unbunding libev and c-ares
9590 (for-each delete-file-recursively '("libev" "c-ares"))
9592 (call-with-output-file "greentest/__init__.py" noop)
9593 (substitute* "greentest/testrunner.py"
9594 (("import util") "from . import util")
9595 (("from util import log") "from .util import log"))))))
9596 (build-system python-build-system)
9598 `(("python-greenlet" ,python-greenlet)))
9600 `(("python-setuptools" ,python-setuptools)
9601 ("python-six" ,python-six)))
9603 `(("c-ares" ,c-ares)
9605 (home-page "http://www.gevent.org/")
9606 (synopsis "Coroutine-based network library")
9608 "gevent is a coroutine-based Python networking library that uses greenlet
9609 to provide a high-level synchronous API on top of the libev event loop.")
9610 (license license:expat)))
9612 (define-public python2-gevent
9613 (package-with-python2 python-gevent))
9615 (define-public python-twisted
9617 (name "python-twisted")
9621 (uri (pypi-uri "Twisted" version ".tar.bz2"))
9624 "0ydxrp9myw1mvsz3qfzx5579y5llmqa82pxvqchgp5syczffi450"))))
9625 (build-system python-build-system)
9627 `(("python-setuptools" ,python-setuptools)))
9629 `(("python-zope-interface" ,python-zope-interface)))
9630 (home-page "https://twistedmatrix.com/")
9631 (synopsis "Asynchronous networking framework written in Python")
9633 "Twisted is an extensible framework for Python programming, with special
9634 focus on event-based network programming and multiprotocol integration.")
9635 (license license:expat)))
9637 (define-public python2-twisted
9638 (package-with-python2 python-twisted))
9640 (define-public python-pika
9642 (name "python-pika")
9647 (uri (pypi-uri "pika" version))
9650 "0nb4h08di432lv7dy2v9kpwgk0w92f24sqc2hw2s9vwr5b8v8xvj"))))
9651 (build-system python-build-system)
9653 `(("python-pyev" ,python-pyev)
9654 ("python-tornado" ,python-tornado)
9655 ("python-twisted" ,python-twisted)))
9656 (home-page "https://pika.readthedocs.org")
9657 (synopsis "Pure Python AMQP Client Library")
9659 "Pika is a pure-Python implementation of the AMQP (Advanced Message Queuing
9660 Protocol) 0-9-1 protocol that tries to stay fairly independent of the underlying
9661 network support library.")
9662 (license license:bsd-3)))
9664 (define-public python2-pika
9665 (package-with-python2 python-pika))
9667 (define-public python-ply
9675 "https://pypi.python.org/packages/"
9676 "96/e0/430fcdb6b3ef1ae534d231397bee7e9304be14a47a267e82ebcb3323d0b5"
9677 "/ply-" version ".tar.gz"))
9680 "1f70ipynmiy09k6px2j7v4w5cdrc21za3xs2k6f1bsvb0bzvvlg7"))))
9681 (build-system python-build-system)
9682 (home-page "http://www.dabeaz.com/ply/")
9683 (synopsis "Python Lex & Yacc")
9684 (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python.
9685 It uses LR parsing and does extensive error checking.")
9686 (license license:bsd-3)
9687 (properties `((python2-variant . ,(delay python2-ply))))))
9689 (define-public python2-ply
9691 (inherit (package-with-python2
9692 (strip-python2-variant python-ply)))
9693 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
9695 (define-public python-tabulate
9697 (name "python-tabulate")
9701 (uri (pypi-uri "tabulate" version))
9704 "03l1r7ddd1a0j2snv1yd0hlnghjad3fg1an1jr8936ksv75slwch"))
9706 (modules '((guix build utils)))
9707 (snippet '(substitute* '("test/test_cli.py"
9708 "test/test_input.py"
9709 "test/test_output.py"
9710 "test/test_regression.py")
9711 (("from common") "from nose.tools")))))
9712 (build-system python-build-system)
9714 `(("python-setuptools" ,python-setuptools)
9716 ("python-nose" ,python-nose)))
9717 (home-page "https://bitbucket.org/astanin/python-tabulate")
9718 (synopsis "Pretty-print tabular data")
9720 "Tabulate is a library and command-line utility to pretty-print tabular
9722 (license license:expat)))
9724 (define-public python2-tabulate
9725 (package-with-python2 python-tabulate))
9727 (define-public python-kazoo
9729 (name "python-kazoo")
9734 (uri (pypi-uri "kazoo" version))
9737 "10pb864if9qi2pq9lfb9m8f7z7ss6rml80gf1d9h64lap5crjnjj"))))
9738 (build-system python-build-system)
9739 (arguments '(#:tests? #f)) ; XXX: needs zookeeper
9741 `(("python-setuptools" ,python-setuptools)))
9743 `(("python-six" ,python-six)))
9744 (home-page "https://kazoo.readthedocs.org")
9745 (synopsis "High-level Zookeeper client library")
9747 "Kazoo is a Python client library for the Apache Zookeeper distributed
9748 application service. It is designed to be easy to use and to avoid common
9749 programming errors.")
9750 (license license:asl2.0)))
9752 (define-public python2-kazoo
9753 (package-with-python2 python-kazoo))
9755 (define-public python-pykafka
9757 (name "python-pykafka")
9762 "https://pypi.python.org/packages/8b/3e/"
9763 "384eeff406b06315738b62483fd2126c6e4f544167116b17cc04ea7d2a59/"
9764 "pykafka-" version ".tar.gz"))
9767 "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv"))))
9768 (build-system python-build-system)
9769 (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc.
9771 `(("python-setuptools" ,python-setuptools)))
9773 `(("python-gevent" ,python-gevent)
9774 ("python-kazoo" ,python-kazoo)
9775 ("python-tabulate" ,python-tabulate)))
9777 `(("librdkafka" ,librdkafka)))
9778 (home-page "https://pykafka.readthedocs.io/")
9779 (synopsis "Apache Kafka client for Python")
9781 "PyKafka is a client for the Apache Kafka distributed messaging system.
9782 It includes Python implementations of Kafka producers and consumers, which
9783 are optionally backed by a C extension built on librdkafka.")
9784 (license license:asl2.0)))
9786 (define-public python2-pykafka
9787 (package-with-python2 python-pykafka))
9789 (define-public python-wcwidth
9791 (name "python-wcwidth")
9797 "https://pypi.python.org/packages/"
9798 "c2/d1/7689293086a8d5320025080cde0e3155b94ae0a7496fb89a3fbaa92c354a/"
9799 "wcwidth-" version ".tar.gz"))
9802 "02wjrpf001gjdjsaxxbzcwfg19crlk2dbddayrfc2v06f53yrcyw"))))
9803 (build-system python-build-system)
9804 (home-page "https://github.com/jquast/wcwidth")
9805 (synopsis "Measure number of terminal column cells of wide-character codes")
9806 (description "Wcwidth measures the number of terminal column cells of
9807 wide-character codes. It is useful for those implementing a terminal emulator,
9808 or programs that carefully produce output to be interpreted by one. It is a
9809 Python implementation of the @code{wcwidth} and @code{wcswidth} C functions
9810 specified in POSIX.1-2001 and POSIX.1-2008.")
9811 (license license:expat)
9812 (properties `((python2-variant . ,(delay python2-wcwidth))))))
9814 (define-public python2-wcwidth
9816 (inherit (package-with-python2
9817 (strip-python2-variant python-wcwidth)))
9818 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
9820 (define-public python2-jsonrpclib
9822 (name "python2-jsonrpclib")
9827 "https://pypi.python.org/packages/source/j/jsonrpclib/"
9828 "jsonrpclib-" version ".tar.gz"))
9831 "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z"))))
9832 (build-system python-build-system)
9834 `(("python2-setuptools" ,python2-setuptools)))
9837 #:python ,python-2))
9838 (home-page "https://github.com/joshmarshall/jsonrpclib/")
9839 (synopsis "Implementation of JSON-RPC specification for Python")
9841 "This library is an implementation of the JSON-RPC specification.
9842 It supports both the original 1.0 specification, as well as the
9843 new (proposed) 2.0 spec, which includes batch submission, keyword arguments,
9845 (license license:asl2.0)))
9847 (define-public python-chai
9849 (name "python-chai")
9853 (uri (pypi-uri "chai" version))
9856 "016kf3irrclpkpvcm7q0gmkfibq7jgy30a9v73pp42bq9h9a32bl"))))
9857 (build-system python-build-system)
9859 `(("python-setuptools" ,python-setuptools)))
9860 (home-page "https://github.com/agoragames/chai")
9861 (synopsis "Mocking framework for Python")
9863 "Chai provides an api for mocking, stubbing and spying your python
9864 objects, patterned after the Mocha library for Ruby.")
9865 (license license:bsd-3)))
9867 (define-public python2-chai
9868 (package-with-python2 python-chai))
9870 (define-public python-arrow
9872 (name "python-arrow")
9876 (uri (pypi-uri "arrow" version))
9879 "1bz7hkdgpqcjs866y58z8jywpy7al0f4rxdr00bh2l5qddyw245j"))))
9880 (build-system python-build-system)
9882 `(("python-setuptools" ,python-setuptools)
9884 ("python-chai" ,python-chai)
9885 ("python-simplejson" ,python-simplejson)))
9887 `(("python-dateutil" ,python-dateutil-2)))
9888 (home-page "https://github.com/crsmithdev/arrow/")
9889 (synopsis "Dates and times for Python")
9891 "Arrow is a Python library to creating, manipulating, formatting and
9892 converting dates, times, and timestamps. It implements and updates the
9894 (license license:asl2.0)))
9896 (define-public python2-arrow
9897 (package-with-python2 python-arrow))
9899 (define-public python-inflection
9901 (name "python-inflection")
9904 (origin (method url-fetch)
9905 (uri (pypi-uri "inflection" version))
9908 "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq"))))
9909 (build-system python-build-system)
9911 `(("python-setuptools" ,python-setuptools)))
9912 (home-page "http://github.com/jpvanhal/inflection")
9913 (synopsis "Python string transformation library")
9915 "Inflection is a string transformation library. It singularizes
9916 and pluralizes English words, and transforms strings from CamelCase to
9917 underscored string.")
9918 (license license:expat)))
9920 (define-public python2-inflection
9921 (package-with-python2 python-inflection))
9923 (define-public python-pylev
9925 (name "python-pylev")
9929 (uri (pypi-uri "pylev" version))
9932 "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86"))))
9933 (build-system python-build-system)
9935 `(("python-setuptools" ,python-setuptools)))
9936 (home-page "http://github.com/toastdriven/pylev")
9937 (synopsis "Levenshtein distance implementation in Python")
9938 (description "Pure Python Levenshtein implementation, based off the
9939 Wikipedia code samples at
9940 @url{http://en.wikipedia.org/wiki/Levenshtein_distance}.")
9941 (license license:bsd-3)))
9943 (define-public python2-pylev
9944 (package-with-python2 python-pylev))
9946 (define-public python-cleo
9948 (name "python-cleo")
9952 (uri (pypi-uri "cleo" version))
9955 "1k2dcl6mqpn5bljyl6w42rqyd9mb3y9kh2mg7m2x3kfjwvg0rpva"))))
9956 (build-system python-build-system)
9958 `(("python-setuptools" ,python-setuptools)
9960 ("python-mock" ,python-mock)
9961 ("python-pytest" ,python-pytest)))
9963 `(("python-psutil" ,python-psutil)
9964 ("python-pylev" ,python-pylev)))
9965 (home-page "https://github.com/sdispater/cleo")
9966 (synopsis "Command-line arguments library for Python")
9968 "Cleo allows you to create command-line commands with signature in
9969 docstring and colored output.")
9970 (license license:expat)))
9972 (define-public python2-cleo
9973 (package-with-python2 python-cleo))
9975 (define-public python-lazy-object-proxy
9977 (name "python-lazy-object-proxy")
9981 (uri (pypi-uri "lazy-object-proxy" version))
9984 "0s22aqqkdscyh8sjspyyax7qa1aiz8p4midrnyf39717fhfczm6x"))))
9985 (build-system python-build-system)
9987 `(("python-setuptools" ,python-setuptools)))
9988 (home-page "https://github.com/ionelmc/python-lazy-object-proxy")
9989 (synopsis "Lazy object proxy for python")
9991 "Lazy object proxy is an object that wraps a callable but defers the call
9992 until the object is actually required, and caches the result of said call.")
9993 (license license:bsd-2)))
9995 (define-public python2-lazy-object-proxy
9996 (package-with-python2 python-lazy-object-proxy))
9998 (define-public python-dnspython
10000 (name "python-dnspython")
10004 (uri (string-append "http://www.dnspython.org/kits/"
10005 version "/dnspython-" version ".tar.gz"))
10008 "0jr4v2pd90i6l1xxbss2m05psbjaxvyvvvpq44wycijpfgjqln8i"))))
10009 (build-system python-build-system)
10010 (arguments '(#:tests? #f)) ; XXX: requires internet access
10012 `(("python-setuptools" ,python-setuptools)))
10013 (home-page "http://www.dnspython.org")
10014 (synopsis "DNS toolkit for Python")
10016 "dnspython is a DNS toolkit for Python. It supports almost all record
10017 types. It can be used for queries, zone transfers, and dynamic updates.
10018 It supports TSIG authenticated messages and EDNS0.")
10019 (license license:expat)))
10021 (define-public python2-dnspython
10022 (package-with-python2 python-dnspython))
10024 (define-public python-email-validator
10026 (name "python-email-validator")
10029 (origin (method url-fetch)
10030 (uri (pypi-uri "email_validator" version))
10033 "0mn8jg5h8ifl8w6a6m0hq8kbk0mzw9vm054qfamkn89b3npz52qw"))))
10034 (build-system python-build-system)
10037 (modify-phases %standard-phases
10038 (add-before 'build 'use-dnspython
10040 (substitute* "setup.py"
10041 (("dnspython3") "dnspython"))
10044 `(("python-setuptools" ,python-setuptools)))
10046 `(("python-dnspython" ,python-dnspython)
10047 ("python-idna" ,python-idna)))
10048 (home-page "https://github.com/JoshData/python-email-validator")
10049 (synopsis "Email address validation library for Python")
10051 "This library validates email address syntax and deliverability.")
10052 (license license:cc0)))
10054 (define-public python2-email-validator
10055 (package-with-python2 python-email-validator))
10057 (define-public python-ukpostcodeparser
10059 (name "python-ukpostcodeparser")
10063 (uri (pypi-uri "UkPostcodeParser" version))
10066 "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd"))))
10067 (build-system python-build-system)
10069 `(("python-setuptools" ,python-setuptools)))
10070 (home-page "https://github.com/hamstah/ukpostcodeparser")
10071 (synopsis "UK Postcode parser for Python")
10073 "This library provides the @code{parse_uk_postcode} function for
10074 parsing UK postcodes.")
10075 (license license:expat)))
10077 (define-public python2-ukpostcodeparser
10078 (package-with-python2 python-ukpostcodeparser))
10080 (define-public python-fake-factory
10082 (name "python-fake-factory")
10086 (uri (pypi-uri "fake-factory" version))
10089 "0vs0dkmg0dlaxf8w6q2i3k0i03gmp56ablldv7ci9x3nbadkn71g"))))
10090 (build-system python-build-system)
10092 `(("python-setuptools" ,python-setuptools)
10094 ("python-email-validator" ,python-email-validator)
10095 ("python-mock" ,python-mock)
10096 ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
10098 `(("python-dateutil" ,python-dateutil-2)
10099 ("python-six" ,python-six)))
10100 (home-page "https://github.com/joke2k/faker")
10101 (synopsis "Python package that generates fake data")
10103 "Faker is a Python package that generates fake data such as names,
10104 addresses, and phone numbers.")
10105 (license license:expat)
10106 (properties `((python2-variant . ,(delay python2-fake-factory))))))
10108 (define-public python2-fake-factory
10109 (let ((base (package-with-python2 (strip-python2-variant
10110 python-fake-factory))))
10114 `(("python2-ipaddress" ,python2-ipaddress)
10115 ,@(package-propagated-inputs base))))))
10117 (define-public python-pyaml
10119 (name "python-pyaml")
10123 (uri (pypi-uri "pyaml" version))
10126 "1f5m28vkh4ksq3d80d8mmd2z8wxvc3mgy2pmrv2751dm2xgznm4w"))))
10127 (build-system python-build-system)
10129 `(("python-setuptools" ,python-setuptools)))
10131 `(("python-pyyaml" ,python-pyyaml)))
10132 (home-page "https://github.com/mk-fg/pretty-yaml")
10133 (synopsis "YAML pretty-print library for Python")
10135 "pyaml is a PyYAML based python module to produce pretty and readable
10136 YAML-serialized data.")
10137 (license (license:non-copyleft "http://www.wtfpl.net/txt/copying/"))))
10139 (define-public python2-pyaml
10140 (package-with-python2 python-pyaml))
10142 (define-public python-flexmock
10144 (name "python-flexmock")
10148 (uri (pypi-uri "flexmock" version))
10151 "0arc6njvs6i9v9hgvzk5m50296g7zy5m9d7pyb43vdsdgxrci5gy"))))
10152 (build-system python-build-system)
10154 `(("python-setuptools" ,python-setuptools)))
10155 (home-page "https://flexmock.readthedocs.org")
10156 (synopsis "Testing library for Python")
10158 "flexmock is a testing library for Python that makes it easy to create
10159 mocks, stubs and fakes.")
10160 (license license:bsd-3)))
10162 (define-public python2-flexmock
10163 (package-with-python2 python-flexmock))
10165 (define-public python-orator
10167 (name "python-orator")
10171 (uri (pypi-uri "orator" version))
10174 "1li49irsqha17nrda4nsb48biyy0rarp9pphf0jpqwm5zr8hv569"))))
10175 (build-system python-build-system)
10176 (arguments '(#:tests? #f)) ; no tests
10178 `(("python-setuptools" ,python-setuptools)))
10180 `(("python-arrow" ,python-arrow)
10181 ("python-blinker" ,python-blinker)
10182 ("python-cleo" ,python-cleo)
10183 ("python-fake-factory" ,python-fake-factory)
10184 ("python-inflection" ,python-inflection)
10185 ("python-lazy-object-proxy" ,python-lazy-object-proxy)
10186 ("python-pyaml" ,python-pyaml)
10187 ("python-simplejson" ,python-simplejson)
10188 ("python-wrapt" ,python-wrapt)))
10189 (home-page "https://orator-orm.com/")
10190 (synopsis "ActiveRecord ORM for Python")
10192 "Orator provides a simple ActiveRecord-like Object Relational Mapping
10193 implementation for Python.")
10194 (license license:expat)
10195 (properties `((python2-variant . ,(delay python2-orator))))))
10197 (define-public python2-orator
10198 (let ((base (package-with-python2 (strip-python2-variant python-orator))))
10202 `(("python2-ipaddress" ,python2-ipaddress)
10203 ,@(package-propagated-inputs base))))))
10205 (define-public python-prompt-toolkit
10207 (name "python-prompt-toolkit")
10212 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
10215 "1vyjd0b7wciv55i19l44zy0adx8q7ss79lhy2r9d1rwz2y4822zg"))))
10216 (build-system python-build-system)
10218 '(#:tests? #f)) ; The test suite uses some Windows-specific data types.
10219 (inputs `(("python-wcwidth" ,python-wcwidth)
10220 ("python-pygments" ,python-pygments)))
10221 (native-inputs `(("python-six" ,python-six)))
10222 (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
10223 (synopsis "Library for building command line interfaces in Python")
10225 "Prompt-Toolkit is a library for building interactive command line
10226 interfaces in Python. It's like GNU Readline but it also features syntax
10227 highlighting while typing, out-of-the-box multi-line input editing, advanced
10228 code completion, incremental search, support for Chinese double-width
10229 characters, mouse support, and auto suggestions.")
10230 (license license:bsd-3)
10231 (properties `((python2-variant . ,(delay python2-prompt-toolkit))))))
10233 (define-public python2-prompt-toolkit
10234 (let ((base (package-with-python2 (strip-python2-variant python-prompt-toolkit))))
10238 `(("python2-setuptools" ,python2-setuptools)
10239 ,@(package-native-inputs base))))))
10241 (define-public python-jedi
10243 (name "python-jedi")
10248 (uri (pypi-uri "jedi" version))
10251 "0c8x962ynpx001fdvp07m2q5jk4igkxbj3rmnydavphvlgxijk1v"))))
10252 (build-system python-build-system)
10253 (home-page "https://github.com/davidhalter/jedi")
10255 "Autocompletion for Python that can be used for text editors")
10257 "Jedi is an autocompletion tool for Python that can be used for text editors.")
10258 (license license:expat)
10259 (properties `((python2-variant . ,(delay python2-jedi))))))
10261 (define-public python2-jedi
10262 (let ((base (package-with-python2 (strip-python2-variant python-jedi))))
10266 `(("python2-setuptools" ,python2-setuptools)
10267 ,@(package-native-inputs base))))))
10269 (define-public ptpython
10275 (uri (pypi-uri "ptpython" version))
10278 "1mmbiyzf0n8hm7z2a562x7w5cbl6jc0zsk6vp40q1z4cyblv1k13"))))
10279 (build-system python-build-system)
10281 `(("python-docopt" ,python-docopt)
10282 ("python-jedi" ,python-jedi)
10283 ("python-prompt-toolkit" ,python-prompt-toolkit)
10284 ("python-pygments" ,python-pygments)
10285 ("python-setuptools" ,python-setuptools)))
10286 (home-page "https://github.com/jonathanslenders/ptpython")
10287 (synopsis "Python Read-Eval-Print-Loop with nice IDE-like features")
10289 "ptpython is a Python read-eval-print loop with IDE-like features.
10290 It supports syntax highlighting, multiline editing, autocompletion, mouse,
10291 color schemes, bracketed paste, Vi and Emacs keybindings, Chinese characters
10293 (license license:bsd-3)
10294 (properties `((python2-variant . ,(delay ptpython-2))))))
10296 (define-public ptpython-2
10297 (let ((base (package-with-python2 (strip-python2-variant ptpython))))
10300 (name "ptpython2"))))
10302 (define-public python-requests-oauthlib
10304 (name "python-requests-oauthlib")
10309 (uri (pypi-uri "requests-oauthlib" version))
10312 "0ykff67sjcl227c23g0rxzfx34rr5bf21kwv0z3zmgk0lfmch7hn"))))
10313 (build-system python-build-system)
10316 (modify-phases %standard-phases
10317 ;; removes tests that require network access
10318 (add-before 'check 'pre-check
10320 (delete-file "tests/test_core.py")
10323 `(("python-requests-mock" ,python-requests-mock)
10324 ("python-mock" ,python-mock)))
10326 `(("python-oauthlib" ,python-oauthlib)
10327 ("python-requests" ,python-requests)))
10329 "https://github.com/requests/requests-oauthlib")
10331 "OAuthlib authentication support for Requests")
10333 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
10334 provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
10335 (license license:isc)
10336 (properties `((python2-variant . ,(delay python2-requests-oauthlib))))))
10338 (define-public python2-requests-oauthlib
10339 (let ((base (package-with-python2 (strip-python2-variant python-requests-oauthlib))))
10342 (native-inputs `(("python2-setuptools" ,python2-setuptools)
10343 ,@(package-native-inputs base))))))
10345 (define-public python-stem
10347 (name "python-stem")
10352 (uri (pypi-uri "stem" version ".tar.bz2"))
10355 "09a3amp1y351nwz088ckiibbp666qi2lxwkyknavswfm400s0ns7"))))
10356 (build-system python-build-system)
10359 (modify-phases %standard-phases
10362 (zero? (system* "./run_tests.py" "--unit")))))))
10364 `(("python-mock" ,python-mock)
10365 ("python-pep8" ,python-pep8)
10366 ("python-pyflakes" ,python-pyflakes)))
10368 `(("python-pycrypto" ,python-pycrypto)))
10369 (home-page "https://stem.torproject.org/")
10371 "Python controller library that allows applications to interact with Tor")
10373 "Stem is a Python controller library for Tor. With it you can use Tor's
10374 control protocol to script against the Tor process and read descriptor data
10375 relays publish about themselves.")
10376 (license license:lgpl3)))
10378 (define-public python2-stem
10379 (package-with-python2 python-stem))
10381 (define-public python-pyserial
10383 (name "python-pyserial")
10388 (uri (pypi-uri "pyserial" version))
10391 "0k1nfdrxxkdlv4zgaqsdv8li0pj3gbh2pyxw8q2bsg6f9490amyn"))))
10392 (build-system python-build-system)
10394 "https://github.com/pyserial/pyserial")
10395 (synopsis "Python Serial Port Bindings")
10396 (description "@code{pyserial} provide serial port bindings for Python. It
10397 supports different byte sizes, stop bits, parity and flow control with RTS/CTS
10398 and/or Xon/Xoff. The port is accessed in RAW mode.")
10399 (license license:bsd-3)
10400 (properties `((python2-variant . ,(delay python2-pyserial))))))
10402 (define-public python2-pyserial
10403 (let ((base (package-with-python2 (strip-python2-variant python-pyserial))))
10407 `(("python2-setuptools" ,python2-setuptools)
10408 ,@(package-native-inputs base))))))
10410 (define-public python-kivy
10412 (name "python-kivy")
10417 (uri (pypi-uri "kivy" version))
10418 (file-name (string-append name "-" version ".tar.gz"))
10421 "0zk3g1j1z0lzcm9d0k1lprrs95zr8n8k5pdg3p5qlsn26jz4bg19"))))
10422 (build-system python-build-system)
10424 `(#:tests? #f ; Tests require many optional packages
10426 (modify-phases %standard-phases
10427 (replace 'build (lambda _ (zero? (system* "make" "force"))))
10428 (add-after 'patch-generated-file-shebangs 'set-sdl-paths
10429 (lambda* (#:key inputs #:allow-other-keys)
10430 (setenv "KIVY_SDL2_PATH"
10431 (string-append (assoc-ref inputs "sdl-union")
10435 `(("pkg-config" ,pkg-config)))
10437 `(("python-cython" ,python-cython)
10438 ("gstreamer" ,gstreamer)
10441 ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))))
10442 (home-page "http://kivy.org")
10444 "Multitouch application framework")
10446 "A software library for rapid development of
10447 hardware-accelerated multitouch applications.")
10448 (license license:expat)))
10450 (define-public python2-kivy
10451 (package-with-python2 python-kivy))
10453 (define-public python-kivy-next
10454 (let ((commit "a988c5e7a47da56263ff39514264a3de516ef2fe")
10456 (package (inherit python-kivy)
10457 (name "python-kivy-next")
10458 (version (string-append "1.9.1-" revision "."
10459 (string-take commit 7)))
10463 (uri (git-reference
10464 (url "https://github.com/kivy/kivy")
10466 (file-name (string-append name "-" version "-checkout"))
10469 "0jk92b4a8l7blkvkgkjihk171s0dfnq582cckff5srwc8kal5m0p")))))))
10471 (define-public python2-kivy-next
10472 (package-with-python2 python-kivy-next))
10474 (define-public python-binaryornot
10476 (name "python-binaryornot")
10480 (uri (pypi-uri "binaryornot" version))
10483 "1j4f51dxic39mdwf6alj7gd769wy6mhk916v031wjali51xkh3xb"))))
10484 (build-system python-build-system)
10486 `(("python-chardet" ,python-chardet)
10487 ("python-hypothesis" ,python-hypothesis)))
10488 (home-page "https://github.com/audreyr/binaryornot")
10489 (synopsis "Package to check if a file is binary or text")
10490 (description "Ultra-lightweight pure Python package to check if a file is
10492 (license license:bsd-3)
10493 (properties `((python2-variant . ,(delay python2-binaryornot))))))
10495 (define-public python2-binaryornot
10496 (let ((base (package-with-python2 (strip-python2-variant python-binaryornot))))
10497 (package (inherit base)
10499 `(("python2-setuptools" ,python2-setuptools)
10500 ,@(package-native-inputs base)))
10502 `(("python2-enum34" ,python2-enum34)
10503 ,@(package-inputs base))))))
10505 (define-public python-nltk
10507 (name "python-nltk")
10511 (uri (pypi-uri "nltk" version))
10514 "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"))))
10515 (build-system python-build-system)
10517 '(;; The tests require some extra resources to be downloaded.
10518 ;; TODO Try packaging these resources.
10520 (home-page "http://nltk.org/")
10521 (synopsis "Natural Language Toolkit")
10522 (description "It provides interfaces to over 50 corpora and lexical
10523 resources such as WordNet, along with a suite of text processing libraries
10524 for classification, tokenization, stemming, tagging, parsing, and semantic
10525 reasoning, wrappers for natural language processing libraries.")
10526 (license license:asl2.0)
10527 (properties `((python2-variant . ,(delay python2-nltk))))))
10529 (define-public python2-nltk
10530 (let ((base (package-with-python2 (strip-python2-variant python-nltk))))
10531 (package (inherit base)
10533 `(("python2-setuptools" ,python2-setuptools)
10534 ,@(package-native-inputs base))))))
10536 (define-public python-pymongo
10538 (name "python-pymongo")
10542 (uri (pypi-uri "pymongo" version))
10545 "07mra6w86wjqy4lx5fvimidjhhfzd562gfjn8grsnbv2q8pk0i9x"))))
10546 (build-system python-build-system)
10548 `(("python-certifi" ,python-certifi)))
10549 (home-page "http://github.com/mongodb/mongo-python-driver")
10550 (synopsis "Python driver for MongoDB")
10551 (description "Python driver for MongoDB.")
10552 (license license:asl2.0)
10553 (properties `((python2-variant . ,(delay python2-pymongo))))))
10555 (define-public python2-pymongo
10556 (let ((base (package-with-python2 (strip-python2-variant python-pymongo))))
10557 (package (inherit base)
10559 `(("python2-setuptools" ,python2-setuptools)
10560 ,@(package-native-inputs base))))))
10562 (define-public python-sh
10568 (uri (pypi-uri "sh" version))
10571 "192r0mpv6dmkysjzhc43ddffiwb5g7c76bgr1mb1z2xz9awbj3sr"))))
10572 (build-system python-build-system)
10574 `(#:tests? #f)) ; no tests
10575 (home-page "https://github.com/amoffat/sh")
10576 (synopsis "Python subprocess interface")
10577 (description "Abstracts process invocation by providing a function
10578 interface for programs.")
10579 (license license:expat)
10580 (properties `((python2-variant . ,(delay python2-sh))))))
10582 (define-public python2-sh
10583 (let ((base (package-with-python2 (strip-python2-variant python-sh))))
10584 (package (inherit base)
10586 `(("python2-setuptools" ,python2-setuptools)
10587 ,@(package-native-inputs base))))))
10589 (define-public python-consul
10591 (name "python-consul")
10596 (uri (pypi-uri "python-consul" version))
10599 "0rfyxcy4cr3x848vhx876ifalxd5ghq6l5x813m49h4vq2d4jiq8"))))
10600 (build-system python-build-system)
10602 `(("python-pytest" ,python-pytest)
10603 ("python-requests" ,python-requests)
10604 ("python-six" ,python-six)))
10605 (home-page "https://github.com/cablehead/python-consul")
10606 (synopsis "Python client for Consul")
10608 "Python client for @url{http://www.consul.io/,Consul}, a tool for service
10609 discovery, monitoring and configuration.")
10610 (license license:expat)))
10612 (define-public python2-consul
10613 (let ((consul (package-with-python2 python-consul)))
10614 (package (inherit consul)
10616 `(("python2-setuptools" ,python2-setuptools)
10617 ,@(package-native-inputs consul))))))
10619 (define-public python-schematics
10621 (name "python-schematics")
10626 (uri (string-append
10627 "https://github.com/schematics/schematics/archive/v" version ".tar.gz"))
10628 (file-name (string-append name "-" version ".tar.gz"))
10631 "19v1i69bf3bzarfxmbv0v6ivpcn758x3shvbiy9l2hy0lvqwnp6l"))))
10632 (build-system python-build-system)
10634 `(("python-six" ,python-six)))
10636 `(#:tests? #f)) ; requires a bunch of not very nice packages with fixed
10637 ; version requirements (eg python-coveralls)
10638 (home-page "https://github.com/schematics/schematics")
10639 (synopsis "Python Data Structures for Humans")
10640 (description "Python Data Structures for Humans.")
10641 (license license:bsd-3)
10642 (properties `((python2-variant . ,(delay python2-schematics))))))
10644 (define-public python2-schematics
10645 (let ((base (package-with-python2 (strip-python2-variant python-schematics))))
10646 (package (inherit base)
10648 `(("python2-setuptools" ,python2-setuptools)
10649 ,@(package-native-inputs base))))))
10651 (define-public python-publicsuffix
10653 (name "python-publicsuffix")
10657 (uri (pypi-uri "publicsuffix" version))
10660 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
10661 (build-system python-build-system)
10663 `(#:tests? #f)) ; tests use the internet
10664 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
10665 (synopsis "Get suffix for a domain name")
10666 (description "Get a public suffix for a domain name using the Public Suffix
10668 (license license:expat)
10669 (properties `((python2-variant . ,(delay python2-nltk))))))
10671 (define-public python2-publicsuffix
10672 (let ((base (package-with-python2 (strip-python2-variant python-publicsuffix))))
10673 (package (inherit base)
10675 `(("python2-setuptools" ,python2-setuptools)
10676 ,@(package-native-inputs base))))))
10678 (define-public python-publicsuffix2
10680 (name "python-publicsuffix2")
10681 (version "2.20160621")
10685 (uri (pypi-uri "publicsuffix2" version ".tar.bz2"))
10688 "06lx603gdwad5hc3hmn763ngq0rq9bzz1ni3ga72nzk5n872arkd"))))
10689 (build-system python-build-system)
10691 '(#:tests? #f)) ; The test suite requires network access.
10692 (home-page "https://github.com/pombredanne/python-publicsuffix2")
10693 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
10694 (description "Get a public suffix for a domain name using the Public Suffix
10695 List. Forked from and using the same API as the publicsuffix package.")
10696 (license (list license:expat license:mpl2.0))
10697 (properties `((python2-variant . ,(delay python2-publicsuffix2))))))
10699 (define-public python2-publicsuffix2
10700 (let ((base (package-with-python2 (strip-python2-variant python-publicsuffix2))))
10701 (package (inherit base)
10703 `(("python2-setuptools" ,python2-setuptools)
10704 ,@(package-native-inputs base))))))
10706 (define-public python-url
10708 (name "python-url")
10712 (uri (pypi-uri "url" version))
10715 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
10716 (build-system python-build-system)
10718 `(("python-publicsuffix" ,python-publicsuffix)))
10720 `(("python-coverage" ,python-coverage)
10721 ("python-nose" ,python-nose)))
10723 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
10724 (home-page "http://github.com/seomoz/url-py")
10725 (synopsis "URL Parsing")
10726 (description "Library for parsing urls.")
10727 (license license:expat)
10728 (properties `((python2-variant . ,(delay python2-url))))))
10730 (define-public python2-url
10731 (let ((base (package-with-python2 (strip-python2-variant python-url))))
10732 (package (inherit base)
10734 `(("python2-publicsuffix" ,python2-publicsuffix)))
10736 `(("python2-setuptools" ,python2-setuptools)
10737 ,@(package-native-inputs base))))))
10739 (define-public python-freezegun
10741 (name "python-freezegun")
10746 (uri (pypi-uri "freezegun" version))
10749 "14l19x06v5jkq4rdwbmfyw4x9lrjb2300afrk21r1ash7y1y9a0w"))))
10750 (build-system python-build-system)
10752 `(("python-mock" ,python-mock)
10753 ("python-nose" ,python-nose)
10754 ("python-coverage" ,python-coverage)
10755 ("python-dateutil-2" ,python-dateutil-2)))
10757 `(("python-six" ,python-six)))
10759 `(#:phases (modify-phases %standard-phases
10760 ;; The tests are normally executed via `make test`, but the PyPi
10761 ;; package does not include the Makefile.
10764 (zero? (system* "nosetests" "./tests/")))))))
10765 (home-page "https://github.com/spulec/freezegun")
10766 (synopsis "Test utility for mocking the datetime module")
10768 "FreezeGun is a library that allows your python tests to travel through
10769 time by mocking the datetime module.")
10770 (license license:asl2.0)))
10772 (define-public python2-freezegun
10773 (let ((base (package-with-python2 (strip-python2-variant python-freezegun))))
10774 (package (inherit base)
10776 `(("python2-setuptools" ,python2-setuptools)
10777 ,@(package-native-inputs base))))))
10779 (define-public python-odfpy
10781 (name "python-odfpy")
10785 (uri (pypi-uri "odfpy" version))
10788 "1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"))))
10790 `(#:modules ((srfi srfi-1)
10791 (guix build python-build-system)
10792 (guix build utils))
10794 (modify-phases %standard-phases
10796 ;; The test runner invokes python2 and python3 for test*.py.
10797 ;; To avoid having both in inputs, we replicate it here.
10799 (every (lambda (test-file)
10800 (zero? (system* "python" test-file)))
10801 (find-files "tests" "^test.*\\.py$")))))))
10802 (build-system python-build-system)
10803 (home-page "https://github.com/eea/odfpy")
10804 (synopsis "Python API and tools to manipulate OpenDocument files")
10805 (description "Collection of libraries and utility programs written in
10806 Python to manipulate OpenDocument 1.2 files.")
10808 ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
10809 ;; number of files with other licenses.
10810 (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0))))
10812 (define-public python2-odfpy
10813 (package-with-python2 python-odfpy))
10815 (define-public python-cachecontrol
10817 (name "python-cachecontrol")
10822 ;; Pypi does not have tests.
10823 (uri (string-append
10824 "https://github.com/ionrock/cachecontrol/archive/v"
10825 version ".tar.gz"))
10826 (file-name (string-append name "-" version ".tar.gz"))
10829 "0yj60d0f69a2l8p7y86k4zhzzm6rnxpq74sfl240pry9l0lfw2vw"))))
10830 (build-system python-build-system)
10833 (modify-phases %standard-phases
10836 ;; Drop test that requires internet access.
10837 (delete-file "tests/test_regressions.py")
10838 (setenv "PYTHONPATH"
10839 (string-append (getcwd) "/build/lib:"
10840 (getenv "PYTHONPATH")))
10841 (zero? (system* "py.test" "-vv")))))))
10843 `(("python-pytest" ,python-pytest)
10844 ("python-redis" ,python-redis)
10845 ("python-webtest" ,python-webtest)
10846 ("python-mock" ,python-mock)))
10848 `(("python-requests" ,python-requests)
10849 ("python-lockfile" ,python-lockfile)))
10850 (home-page "https://github.com/ionrock/cachecontrol")
10851 (synopsis "The httplib2 caching algorithms for use with requests")
10852 (description "CacheControl is a port of the caching algorithms in
10853 @code{httplib2} for use with @code{requests} session objects.")
10854 (license license:asl2.0)
10855 (properties `((python2-variant . ,(delay python2-cachecontrol))))))
10857 (define-public python2-cachecontrol
10858 (let ((base (package-with-python2 (strip-python2-variant python-cachecontrol))))
10859 (package (inherit base)
10861 `(("python2-setuptools" ,python2-setuptools)
10862 ,@(package-native-inputs base))))))
10864 (define-public python-lit
10866 (name "python-lit")
10871 (uri (pypi-uri "lit" version))
10874 "135m2b9cwih85g66rjggavck328z7lj37srgpq3jxszbg0g2b91y"))))
10875 (build-system python-build-system)
10876 (home-page "http://llvm.org/")
10877 (synopsis "LLVM Software Testing Tool")
10878 (description "@code{lit} is a portable tool for executing LLVM and Clang
10879 style test suites, summarizing their results, and providing indication of
10881 (license license:ncsa)
10882 (properties `((python2-variant . ,(delay python2-lit))))))
10884 (define-public python2-lit
10885 (let ((base (package-with-python2 (strip-python2-variant python-lit))))
10889 `(("python2-setuptools" ,python2-setuptools)
10890 ,@(package-native-inputs base))))))
10892 (define-public python-pytest-pep8
10894 (name "python-pytest-pep8")
10898 (uri (pypi-uri "pytest-pep8" version))
10901 "06032agzhw1i9d9qlhfblnl3dw5hcyxhagn7b120zhrszbjzfbh3"))))
10902 (build-system python-build-system)
10904 `(#:tests? #f ; Fails with recent pytest and pep8. See upstream issues #8 and #12.
10905 ;; Prevent creation of the egg. This works around
10906 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
10907 #:configure-flags '("--single-version-externally-managed" "--root=/")))
10909 `(("python-pytest" ,python-pytest)))
10911 `(("python-pep8" ,python-pep8)))
10912 (home-page "https://bitbucket.org/pytest-dev/pytest-pep8")
10913 (synopsis "Py.test plugin to check PEP8 requirements")
10914 (description "Pytest plugin for checking PEP8 compliance.")
10915 (license license:expat)
10916 (properties `((python2-variant . ,(delay python2-pytest-pep8))))))
10918 (define-public python2-pytest-pep8
10919 (let ((base (package-with-python2 (strip-python2-variant python-pytest-pep8))))
10920 (package (inherit base)
10922 `(("python2-setuptools" ,python2-setuptools)
10923 ,@(package-native-inputs base))))))
10925 (define-public python-pytest-flakes
10927 (name "python-pytest-flakes")
10931 (uri (pypi-uri "pytest-flakes" version))
10934 "0flag3n33kbhyjrhzmq990rvg4yb8hhhl0i48q9hw0ll89jp28lw"))))
10935 (build-system python-build-system)
10937 `(;; Prevent creation of the egg. This works around
10938 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
10939 #:configure-flags '("--single-version-externally-managed" "--root=/")
10941 (modify-phases %standard-phases
10943 (add-after 'install 'check
10944 (lambda _ ; It's easier to run tests after install.
10945 (zero? (system* "py.test" "-vv")))))))
10947 `(("python-coverage" ,python-coverage)
10948 ("python-pytest" ,python-pytest)
10949 ("python-pytest-cache" ,python-pytest-cache)
10950 ("python-pytest-pep8" ,python-pytest-pep8)))
10952 `(("python-pyflakes" ,python-pyflakes)))
10953 (home-page "https://github.com/fschulze/pytest-flakes")
10954 (synopsis "Py.test plugin to check source code with pyflakes")
10955 (description "Pytest plugin for checking Python source code with pyflakes.")
10956 (license license:expat)
10957 (properties `((python2-variant . ,(delay python2-pytest-flakes))))))
10959 (define-public python2-pytest-flakes
10960 (let ((base (package-with-python2 (strip-python2-variant python-pytest-flakes))))
10961 (package (inherit base)
10963 `(("python2-setuptools" ,python2-setuptools)
10964 ,@(package-native-inputs base))))))
10966 (define-public python-natsort
10968 (name "python-natsort")
10972 (uri (pypi-uri "natsort" version))
10975 "1abld5p4a6n5zjnyw5mi2pv37gqalcybv2brjr2y6l9l2p8v9mja"))))
10976 (build-system python-build-system)
10979 (modify-phases %standard-phases
10980 (add-before 'check 'set-cachedir
10981 ;; Tests require write access to $HOME by default
10982 (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t)))))
10984 `(("python-hypothesis" ,python-hypothesis)
10985 ("python-pytest-cache" ,python-pytest-cache)
10986 ("python-pytest-cov" ,python-pytest-cov)
10987 ("python-pytest-flakes" ,python-pytest-flakes)
10988 ("python-pytest-pep8" ,python-pytest-pep8)))
10989 (propagated-inputs ; TODO: Add python-fastnumbers.
10990 `(("python-pyicu" ,python-pyicu)))
10991 (home-page "https://github.com/SethMMorton/natsort")
10992 (synopsis "Natural sorting for python and shell")
10994 "Natsort lets you apply natural sorting on lists instead of
10995 lexicographical. If you use the built-in @code{sorted} method in python
10996 on a list such as @code{['a20', 'a9', 'a1', 'a4', 'a10']}, it would be
10997 returned as @code{['a1', 'a10', 'a20', 'a4', 'a9']}. Natsort provides a
10998 function @code{natsorted} that identifies numbers and sorts them separately
10999 from strings. It can also sort version numbers, real numbers, mixed types
11000 and more, and comes with a shell command @command{natsort} that exposes this
11001 functionality in the command line.")
11002 (license license:expat)
11003 (properties `((python2-variant . ,(delay python2-natsort))))))
11005 (define-public python2-natsort
11006 (let ((base (package-with-python2 (strip-python2-variant python-natsort))))
11007 (package (inherit base)
11009 `(("python2-setuptools" ,python2-setuptools)
11010 ("python2-pathlib" ,python2-pathlib)
11011 ("python2-mock" ,python2-mock)
11012 ("python2-enum34" ,python2-enum34)
11013 ,@(package-native-inputs base))))))
11015 (define-public python-glances
11017 (name "python-glances")
11022 (uri (pypi-uri "Glances" version))
11025 "11jbq40g8alsbirnd4kiagznqg270247i0m8qhi48ldf2i5xppxg"))))
11026 (build-system python-build-system)
11028 `(("python-psutil" ,python-psutil)))
11030 "https://github.com/nicolargo/glances")
11032 "A cross-platform curses-based monitoring tool")
11034 "Glances is a curses-based monitoring tool for a wide variety of platforms.
11035 Glances uses the PsUtil library to get information from your system. It monitors
11036 CPU, load, memory, network bandwidth, disk I/O, disk use, and more.")
11037 (license license:lgpl3+)
11038 (properties `((python2-variant . ,(delay python2-glances))))))
11040 (define-public python2-glances
11041 (let ((base (package-with-python2 (strip-python2-variant python-glances))))
11045 `(("python2-setuptools" ,python2-setuptools)
11046 ,@(package-native-inputs base))))))
11048 (define-public python-graphql-core
11050 (name "python-graphql-core")
11055 (uri (pypi-uri "graphql-core" version))
11058 "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0"))))
11059 (build-system python-build-system)
11062 (modify-phases %standard-phases
11063 (add-after 'unpack 'patch-hardcoded-version
11064 (lambda _ (substitute*
11066 (("'gevent==1.1rc1'") "'gevent'"))
11069 `(("python-gevent" ,python-gevent)
11070 ("python-mock" ,python-mock)
11071 ("python-pytest-mock" ,python-pytest-mock)))
11073 `(("python-promise" ,python-promise)
11074 ("python-six" ,python-six)))
11075 (home-page "https://github.com/graphql-python/graphql-core")
11076 (synopsis "GraphQL implementation for Python")
11078 "GraphQL implementation for Python. GraphQL is a data query language and
11079 runtime designed and used to request and deliver data to mobile and web apps.
11080 This library is a port of @url{https://github.com/graphql/graphql-js,graphql-js}
11082 (properties `((python2-variant . ,(delay python2-graphql-core))))
11083 (license license:expat)))
11085 (define-public python2-graphql-core
11086 (let ((base (package-with-python2
11087 (strip-python2-variant python-graphql-core))))
11088 (package (inherit base)
11090 `(("python2-setuptools" ,python2-setuptools)
11091 ,@(package-native-inputs base))))))
11093 (define-public python-graphql-relay
11095 (name "python-graphql-relay")
11100 (uri (pypi-uri "graphql-relay" version))
11103 "04wr9ayshxjjdcg2v21c7ffbz36kif1wjl3604fqd3qignb3fbxi"))))
11104 (build-system python-build-system)
11106 `(("python-pytest" ,python-pytest)))
11108 `(("python-graphql-core" ,python-graphql-core)
11109 ("python-promise" ,python-promise)
11110 ("python-six" ,python-six)))
11111 (home-page "https://github.com/graphql-python/graphql-relay-py")
11112 (synopsis "Relay implementation for Python")
11114 "This is a library to allow the easy creation of Relay-compliant servers
11115 using the GraphQL Python reference implementation of a GraphQL server. It
11116 should be noted that the code is a exact port of the original
11117 @url{https://github.com/graphql/graphql-relay-js,graphql-relay js implementation}
11119 (properties `((python2-variant . ,(delay python2-graphql-relay))))
11120 (license license:expat)))
11122 (define-public python2-graphql-relay
11123 (let ((base (package-with-python2
11124 (strip-python2-variant python-graphql-relay))))
11125 (package (inherit base)
11127 `(("python2-setuptools" ,python2-setuptools)
11128 ,@(package-native-inputs base))))))
11130 (define-public python-graphene
11132 (name "python-graphene")
11137 (uri (pypi-uri "graphene" version))
11140 "09zhac7igh9ixdz0ay6csy35b40l1jwbf2wrbxmgxwfhy51iy06q"))))
11141 (build-system python-build-system)
11143 `(("python-django-filter" ,python-django-filter)
11144 ("python-mock" ,python-mock)
11145 ("python-psycopg2" ,python-psycopg2)
11146 ("python-pytest-django" ,python-pytest-django)
11147 ("python-sqlalchemy-utils" ,python-sqlalchemy-utils)))
11149 `(("python-graphql-core" ,python-graphql-core)
11150 ("python-graphql-relay" ,python-graphql-relay)
11151 ("python-iso8601" ,python-iso8601)
11152 ("python-promise" ,python-promise)
11153 ("python-six" ,python-six)))
11154 (home-page "http://graphene-python.org/")
11155 (synopsis "GraphQL Framework for Python")
11157 "Graphene is a Python library for building GraphQL schemas/types.
11158 A GraphQL schema describes your data model, and provides a GraphQL server
11159 with an associated set of resolve methods that know how to fetch data.")
11160 (properties `((python2-variant . ,(delay python2-graphene))))
11161 (license license:expat)))
11163 (define-public python2-graphene
11164 (let ((base (package-with-python2
11165 (strip-python2-variant python-graphene))))
11166 (package (inherit base)
11168 `(("python2-setuptools" ,python2-setuptools)
11169 ("python2-sqlalchemy" ,python2-sqlalchemy)
11170 ,@(package-native-inputs base))))))
11172 (define-public python-nautilus
11174 (name "python-nautilus")
11179 (uri (pypi-uri "nautilus" version))
11182 "01hwzjc1zshk4vvxrcghm398fpy4jls66dyz06g07mrwqif8878p"))))
11183 (build-system python-build-system)
11184 (arguments `(#:tests? #f)) ; fails to import test modules
11186 `(("python-setuptools" ,python-setuptools)))
11188 `(("python-bcrypt" ,python-bcrypt)
11189 ("python-click" ,python-click)
11190 ("python-consul" ,python-consul)
11191 ("python-graphql-core" ,python-graphql-core)
11192 ("python-graphql-relay" ,python-graphql-relay)
11193 ("python-graphene" ,python-graphene)
11194 ("python-jinja2" ,python-jinja2)
11195 ("python-nose2" ,python-nose2)
11196 ("python-peewee" ,python-peewee)
11197 ("python-pika" ,python-pika)
11198 ("python-pycparser" ,python-pycparser)
11199 ("python-requests" ,python-requests)
11200 ("python-tornado" ,python-tornado)
11201 ("python-wtforms" ,python-wtforms)))
11202 (home-page "https://github.com/AlecAivazis/nautilus")
11203 (synopsis "Library for creating microservice applications")
11205 "Nautilus is a framework for flux based microservices that looks to
11206 provide extendible implementations of common aspects of a cloud so that you can
11207 focus on building massively scalable web applications.")
11208 (license license:expat)))
11210 (define-public python-s3transfer
11212 (name "python-s3transfer")
11216 (uri (pypi-uri "s3transfer" version))
11219 "1jivjkp3xqif9gzr5fiq28jsskmh50vzzd7ldsb4rbyiw1iyv3hy"))))
11220 (build-system python-build-system)
11222 `(("python-docutils" ,python-docutils)))
11224 `(("python-botocore" ,python-botocore)))
11225 (synopsis "Amazon S3 Transfer Manager")
11226 (description "S3transfer is a Python library for managing Amazon S3
11228 (home-page "https://github.com/boto/s3transfer")
11229 (license license:asl2.0)
11230 (properties `((python2-variant . ,(delay python2-s3transfer))))))
11232 (define-public python2-s3transfer
11233 (let ((base (package-with-python2 (strip-python2-variant python-s3transfer))))
11237 `(("python2-futures" ,python2-futures)
11238 ("python2-setuptools" ,python2-setuptools)
11239 ,@(package-native-inputs base))))))
11241 (define-public python-setproctitle
11243 (name "python-setproctitle")
11248 (uri (pypi-uri "setproctitle" version))
11251 "163kplw9dcrw0lffq1bvli5yws3rngpnvrxrzdw89pbphjjvg0v2"))))
11252 (build-system python-build-system)
11255 (modify-phases %standard-phases
11256 (add-before 'check 'patch-Makefile
11257 ;; Stricly this is only required for the python2 variant.
11258 ;; But adding a phase in an inherited package seems to be
11259 ;; cumbersum. So we patch even for python3.
11261 (let ((nose (assoc-ref %build-inputs "python2-nose")))
11263 (substitute* "Makefile"
11264 (("\\$\\(PYTHON\\) [^ ]which nosetests[^ ] ")
11265 (string-append nose "/bin/nosetests "))))
11269 (setenv "PYTHON" (or (which "python3") (which "python")))
11270 (setenv "PYCONFIG" (or (which "python3-config")
11271 (which "python-config")))
11272 (setenv "CC" "gcc")
11273 ;; No need to extend PYTHONPATH to find the built package, since
11274 ;; the Makefile will build anyway
11275 (zero? (system* "make" "check")))))))
11277 `(("procps" ,procps))) ; required for tests
11279 "https://github.com/dvarrazzo/py-setproctitle")
11281 "Setproctitle implementation for Python to customize the process title")
11282 (description "The library allows a process to change its title (as displayed
11283 by system tools such as ps and top).
11285 Changing the title is mostly useful in multi-process systems, for
11286 example when a master process is forked: changing the children's title
11287 allows to identify the task each process is busy with. The technique
11288 is used by PostgreSQL and the OpenSSH Server for example.")
11289 (license license:bsd-3)
11290 (properties `((python2-variant . ,(delay python2-setproctitle))))))
11292 (define-public python2-setproctitle
11293 (let ((base (package-with-python2
11294 (strip-python2-variant python-setproctitle))))
11297 (native-inputs `(("python2-nose" ,python2-nose)
11298 ,@(package-native-inputs base))))))
11300 (define-public python-validictory
11302 (name "python-validictory")
11307 (uri (pypi-uri "validictory" version))
11310 "1zf1g9sw47xzp5f80bd94pb42j9yqv82lcrgcvdwr6nkaphfi37q"))))
11311 (build-system python-build-system)
11314 (modify-phases %standard-phases
11315 (add-after 'unpack 'bootstrap
11316 ;; Move the tests out of the package directory to avoid
11319 (rename-file "validictory/tests" "tests")
11320 (delete-file "tests/__init__.py")))
11323 ;; Extend PYTHONPATH so the built package will be found.
11324 (setenv "PYTHONPATH"
11325 (string-append (getcwd) "/build/lib:"
11326 (getenv "PYTHONPATH")))
11327 (zero? (system* "py.test" "-vv" )))))))
11329 `(("python-pytest" ,python-pytest)))
11331 "https://github.com/jamesturk/validictory")
11332 (synopsis "General purpose Python data validator")
11333 (description "It allows validation of arbitrary Python data structures.
11335 The schema format is based on the JSON Schema
11336 proposal (http://json-schema.org), so combined with json the library is also
11337 useful as a validator for JSON data.")
11338 (license license:expat)
11339 (properties `((python2-variant . ,(delay python2-validictory))))))
11341 (define-public python2-validictory
11342 (let ((base (package-with-python2
11343 (strip-python2-variant python-validictory))))
11346 (native-inputs `(("python2-setuptools" ,python2-setuptools)
11347 ,@(package-native-inputs base))))))
11349 (define-public python-aniso8601
11351 (name "python-aniso8601")
11356 (uri (pypi-uri "aniso8601" version))
11359 "1k5mjg9iqbjfslb5prrsfz7dhlvi6s35p1jxq8dm87w1b7dn5i2g"))))
11360 (build-system python-build-system)
11362 `(("python-dateutil-2" ,python-dateutil-2)))
11364 "https://bitbucket.org/nielsenb/aniso8601")
11366 "Python library for parsing ISO 8601 strings")
11368 "This package contains a library for parsing ISO 8601 datetime strings.")
11369 (license license:bsd-3)))
11371 (define-public python-flask-restful
11373 (name "python-flask-restful")
11378 (uri (pypi-uri "Flask-RESTful" version))
11381 "0hjcmdb56b7z4bkw848lxfkyrpnkwzmqn2dgnlv12mwvjpzsxr6c"))))
11382 (build-system python-build-system)
11384 `(("python-aniso8601" ,python-aniso8601)
11385 ("python-flask" ,python-flask)
11386 ("python-pycrypto" ,python-pycrypto)
11387 ("python-pytz" ,python-pytz)))
11389 `(;; Optional dependency of Flask. Tests need it.
11390 ("python-blinker" ,python-blinker)
11391 ("python-mock" ,python-mock) ; For tests
11392 ("python-nose" ,python-nose) ; For tests
11393 ("python-sphinx" ,python-sphinx)))
11395 "https://www.github.com/flask-restful/flask-restful/")
11397 "Flask module for creating REST APIs")
11399 "This package contains a Flask module for creating REST APIs.")
11400 (license license:bsd-3)))
11402 (define-public python-flask-basicauth
11404 (name "python-flask-basicauth")
11409 (uri (pypi-uri "Flask-BasicAuth" version))
11412 "1zq1spkjr4sjdnalpp8wl242kdqyk6fhbnhr8hi4r4f0km4bspnz"))))
11413 (build-system python-build-system)
11415 `(("python-flask" ,python-flask)))
11417 "https://github.com/jpvanhal/flask-basicauth")
11419 "HTTP basic access authentication for Flask")
11421 "This package provides HTTP basic access authentication for Flask.")
11422 (license license:bsd-3)))
11424 (define-public python-flask-sqlalchemy
11426 (name "python-flask-sqlalchemy")
11431 (uri (pypi-uri "Flask-SQLAlchemy" version))
11434 "1i9ps5d5snih9xlqhrvmi3qfiygkmqzxh92n25kj4pf89kj4s965"))))
11435 (build-system python-build-system)
11437 `(("python-flask" ,python-flask)
11438 ("python-sqlalchemy" ,python-sqlalchemy)))
11440 "http://github.com/mitsuhiko/flask-sqlalchemy")
11442 "Module adding SQLAlchemy support to your Flask application")
11444 "This package adds SQLAlchemy support to your Flask application.")
11445 (license license:bsd-3)))
11447 (define-public python-pyev
11449 (name "python-pyev")
11454 (uri (pypi-uri "pyev" version))
11457 "0rf603lc0s6zpa1nb25vhd8g4y337wg2wyz56i0agsdh7jchl0sx"))))
11458 (build-system python-build-system)
11460 `(#:tests? #f ; no test suite
11462 (modify-phases %standard-phases
11463 (add-after 'unpack 'patch
11464 (lambda* (#:key inputs #:allow-other-keys)
11465 (let ((libev (string-append (assoc-ref inputs "libev")
11466 "/lib/libev.so.4")))
11467 (substitute* "setup.py"
11468 (("libev_dll_name = find_library\\(\\\"ev\\\"\\)")
11469 (string-append "libev_dll_name = \"" libev "\"")))))))))
11471 `(("libev" ,libev)))
11472 (home-page "http://pythonhosted.org/pyev/")
11473 (synopsis "Python libev interface")
11474 (description "Pyev provides a Python interface to libev.")
11475 (license license:gpl3)))
11477 (define-public python2-pyev
11478 (package-with-python2 python-pyev))
11480 (define-public python-imagesize
11482 (name "python-imagesize")
11487 (uri (pypi-uri "imagesize" version))
11490 "0qk07k0z4241lkzzjji7z4da04pcvg7bfc4xz1934zlqhwmwdcha"))))
11491 (build-system python-build-system)
11492 (home-page "https://github.com/shibukawa/imagesize_py")
11493 (synopsis "Gets image size of files in variaous formats in Python")
11495 "This package allows determination of image size from
11496 PNG, JPEG, JPEG2000 and GIF files in pure Python.")
11497 (license license:expat)
11498 (properties `((python2-variant . ,(delay python2-imagesize))))))
11500 (define-public python2-imagesize
11501 (let ((base (package-with-python2 (strip-python2-variant python-imagesize))))
11504 (native-inputs `(("python2-setuptools" ,python2-setuptools)
11505 ,@(package-native-inputs base))))))