1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2013, 2014, 2015 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 Ricardo Wurmus <rekado@elephly.net>
11 ;;; Copyright © 2015 Christopher Allan Webber <cwebber@dustycloud.org>
12 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
13 ;;; Copyright © 2015 David Thompson <davet@gnu.org>
14 ;;; Copyright © 2015 Leo Famulari <leo@famulari.name>
15 ;;; Copyright © 2015 Ben Woodcroft <donttrustben@gmail.com>
16 ;;; Copyright © 2015 Erik Edrosa <erik.edrosa@gmail.com>
17 ;;; Copyright © 2015 Efraim Flashner <efraim@flashner.co.il>
18 ;;; Copyright © 2015 Kyle Meyer <kyle@kyleam.com>
20 ;;; This file is part of GNU Guix.
22 ;;; GNU Guix is free software; you can redistribute it and/or modify it
23 ;;; under the terms of the GNU General Public License as published by
24 ;;; the Free Software Foundation; either version 3 of the License, or (at
25 ;;; your option) any later version.
27 ;;; GNU Guix is distributed in the hope that it will be useful, but
28 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
29 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 ;;; GNU General Public License for more details.
32 ;;; You should have received a copy of the GNU General Public License
33 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
35 (define-module (gnu packages python)
36 #:use-module ((guix licenses)
37 #:select (asl2.0 bsd-4 bsd-3 bsd-2 non-copyleft cc0 x11 x11-style
38 gpl2 gpl2+ gpl3+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3+ agpl3+
39 isc psfl public-domain x11-style zpl2.1))
40 #:use-module ((guix licenses) #:select (expat zlib) #:prefix license:)
41 #:use-module (gnu packages)
42 #:use-module (gnu packages attr)
43 #:use-module (gnu packages backup)
44 #:use-module (gnu packages compression)
45 #:use-module (gnu packages databases)
46 #:use-module (gnu packages file)
47 #:use-module (gnu packages fontutils)
48 #:use-module (gnu packages gcc)
49 #:use-module (gnu packages ghostscript)
50 #:use-module (gnu packages glib)
51 #:use-module (gnu packages gtk)
52 #:use-module (gnu packages icu4c)
53 #:use-module (gnu packages image)
54 #:use-module (gnu packages imagemagick)
55 #:use-module (gnu packages libffi)
56 #:use-module (gnu packages linux)
57 #:use-module (gnu packages maths)
58 #:use-module (gnu packages multiprecision)
59 #:use-module (gnu packages networking)
60 #:use-module (gnu packages ncurses)
61 #:use-module (gnu packages pcre)
62 #:use-module (gnu packages perl)
63 #:use-module (gnu packages pkg-config)
64 #:use-module (gnu packages readline)
65 #:use-module (gnu packages statistics)
66 #:use-module (gnu packages texlive)
67 #:use-module (gnu packages texinfo)
68 #:use-module (gnu packages tls)
69 #:use-module (gnu packages web)
70 #:use-module (gnu packages base)
71 #:use-module (gnu packages xml)
72 #:use-module (gnu packages xorg)
73 #:use-module (gnu packages zip)
74 #:use-module (gnu packages tcl)
75 #:use-module (guix packages)
76 #:use-module (guix download)
77 #:use-module (guix git-download)
78 #:use-module (guix utils)
79 #:use-module (guix build-system gnu)
80 #:use-module (guix build-system cmake)
81 #:use-module (guix build-system python)
82 #:use-module (guix build-system trivial)
83 #:use-module (srfi srfi-1))
85 (define-public python-2
92 (uri (string-append "https://www.python.org/ftp/python/"
93 version "/Python-" version ".tar.xz"))
96 "1h7zbrf9pkj29hlm18b10548ch9757f75m64l47sy75rh43p7lqw"))
97 (patches (map search-patch
98 '("python-2.7-search-paths.patch"
99 "python-2-deterministic-build-info.patch"
100 "python-2.7-source-date-epoch.patch")))))
102 "tk")) ;tkinter; adds 50 MiB to the closure
103 (build-system gnu-build-system)
108 ;; test_distutils test_shutil test_signal test_site test_slice
109 ;; test_smtplib test_smtpnet test_socket test_socketserver
110 ;; test_softspace test_sort test_spwd test_sqlite test_ssl
111 ;; test_startfile test_stat test_str test_strftime test_string
112 ;; test_stringprep test_strop test_strptime test_strtod test_struct
113 ;; test_structmembers test_structseq test_subprocess test_sunau
114 ;; test_sunaudiodev test_sundry test_symtable test_syntax test_sys
115 ;; test_sys_setprofile test_sys_settrace test_sysconfig test_tarfile
116 ;; test_tcl test_telnetlib test_tempfile test_textwrap test_thread
117 ;; test_threaded_import test_threadedtempfile test_threading
118 ;; test_threading_local test_threadsignals test_time test_timeit
119 ;; test_timeout test_tk test_tokenize test_tools test_trace
120 ;; test_traceback test_transformer test_ttk_guionly test_ttk_textonly
121 ;; test_tuple test_typechecks test_ucn test_unary
122 ;; test_undocumented_details test_unicode test_unicode_file
123 ;; test_unicodedata test_univnewlines test_univnewlines2k test_unpack
124 ;; test_urllib test_urllib2 test_urllib2_localnet test_urllib2net
125 ;; test_urllibnet test_urlparse test_userdict test_userlist
126 ;; test_userstring test_uu test_uuid test_wait3 test_wait4
127 ;; test_warnings test_wave test_weakref test_weakset test_whichdb
128 ;; test_winreg test_winsound test_with test_wsgiref test_xdrlib
129 ;; test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc
130 ;; test_xpickle test_xrange test_zipfile test_zipfile64
131 ;; test_zipimport test_zipimport_support test_zlib
133 ;; test_aepack test_al test_applesingle test_bsddb test_bsddb185
134 ;; test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk
135 ;; test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_crypt
136 ;; test_curses test_dl test_gdb test_gl test_idle test_imageop
137 ;; test_imgfile test_ioctl test_kqueue test_linuxaudiodev test_macos
138 ;; test_macostools test_msilib test_nis test_ossaudiodev
139 ;; test_scriptpackages
140 ;; 6 skips unexpected on linux2:
141 ;; test_bsddb test_bsddb3 test_crypt test_gdb test_idle test_ioctl
142 ;; One of the typical errors:
144 ;; test test_unicode crashed -- <type 'exceptions.OSError'>: [Errno 2] No
145 ;; such file or directory
148 (list "--enable-shared" ;allow embedding
149 "--with-system-ffi" ;build ctypes
150 (string-append "LDFLAGS=-Wl,-rpath="
151 (assoc-ref %outputs "out") "/lib"))
153 #:modules ((ice-9 ftw) (ice-9 match)
154 (guix build utils) (guix build gnu-build-system))
156 (modify-phases %standard-phases
158 'configure 'patch-lib-shells
160 ;; Filter for existing files, since some may not exist in all
161 ;; versions of python that are built with this recipe.
162 (substitute* (filter file-exists?
163 '("Lib/subprocess.py"
165 "Lib/distutils/tests/test_spawn.py"
166 "Lib/test/test_subprocess.py"))
167 (("/bin/sh") (which "sh")))
169 ;; Use zero as the timestamp in .pyc files so that builds are
170 ;; deterministic. TODO: Remove it when this variable is set in
171 ;; gnu-build-system.scm.
172 (setenv "SOURCE_DATE_EPOCH" "1")
174 (add-before 'configure 'do-not-record-configure-flags
175 (lambda* (#:key configure-flags #:allow-other-keys)
176 ;; Remove configure flags from the installed '_sysconfigdata.py'
177 ;; and 'Makefile' so we don't end up keeping references to the
180 ;; Preserve at least '--with-system-ffi' since otherwise the
181 ;; thing tries to build libffi, fails, and we end up with a
182 ;; Python that lacks ctypes.
183 (substitute* "configure"
184 (("^CONFIG_ARGS=.*$")
185 (format #f "CONFIG_ARGS='~a'\n"
186 (if (member "--with-system-ffi" configure-flags)
193 ;; 'Lib/test/test_site.py' needs a valid $HOME
194 (setenv "HOME" (getcwd))
197 'unpack 'set-source-file-times-to-1980
198 ;; XXX One of the tests uses a ZIP library to pack up some of the
199 ;; source tree, and fails with "ZIP does not support timestamps
200 ;; before 1980". Work around this by setting the file times in the
201 ;; source tree to sometime in early 1980.
203 (let ((circa-1980 (* 10 366 24 60 60)))
204 (ftw "." (lambda (file stat flag)
205 (utime file circa-1980 circa-1980)
208 (add-after 'install 'move-tk-inter
209 (lambda* (#:key outputs #:allow-other-keys)
210 ;; When Tkinter support is built move it to a separate output so
211 ;; that the main output doesn't contain a reference to Tcl/Tk.
212 (let ((out (assoc-ref outputs "out"))
213 (tk (assoc-ref outputs "tk")))
215 (match (find-files out "tkinter.*\\.so")
217 ;; The .so is in OUT/lib/pythonX.Y/lib-dynload, but we
218 ;; want it under TK/lib/pythonX.Y/site-packages.
219 (let* ((len (string-length out))
220 (target (string-append
223 (dirname (dirname tkinter.so))
226 (install-file tkinter.so target)
227 (delete-file tkinter.so)))))
232 ("libffi" ,libffi) ; for ctypes
233 ("sqlite" ,sqlite) ; for sqlite extension
235 ("readline" ,readline)
238 ("tk" ,tk))) ; for tkinter
240 `(("pkg-config" ,pkg-config)))
242 (list (search-path-specification
243 (variable "PYTHONPATH")
244 (files '("lib/python2.7/site-packages")))))
245 (home-page "http://python.org")
246 (synopsis "High-level, dynamically-typed programming language")
248 "Python is a remarkably powerful dynamic programming language that
249 is used in a wide variety of application domains. Some of its key
250 distinguishing features include: clear, readable syntax; strong
251 introspection capabilities; intuitive object orientation; natural
252 expression of procedural code; full modularity, supporting hierarchical
253 packages; exception-based error handling; and very high level dynamic
257 (define-public python
258 (package (inherit python-2)
262 (uri (string-append "https://www.python.org/ftp/python/"
263 version "/Python-" version ".tar.xz"))
264 (patches (map search-patch
265 '("python-fix-tests.patch"
266 ;; XXX Try removing this patch for python > 3.4.3
267 "python-disable-ssl-test.patch"
268 "python-3-deterministic-build-info.patch"
269 "python-3-search-paths.patch")))
270 (patch-flags '("-p0"))
273 "1f4nm4z08sy0kqwisvv95l02crv6dyysdmx44p1mz3bn6csrdcxm"))))
274 (arguments (substitute-keyword-arguments (package-arguments python-2)
277 (list (search-path-specification
278 (variable "PYTHONPATH")
279 (files (list (string-append "lib/python"
280 (version-major+minor version)
281 "/site-packages"))))))))
283 ;; Minimal variants of Python, mostly used to break the cycle between Tk and
284 ;; Python (Tk -> libxcb -> Python.)
286 (define-public python2-minimal
287 (package (inherit python-2)
288 (name "python-minimal")
291 (substitute-keyword-arguments (package-arguments python-2)
292 ((#:configure-flags cf)
293 `(append ,cf '("--without-system-ffi")))))
294 (inputs '()))) ;none of the optional dependencies
296 (define-public python-minimal
297 (package (inherit python)
298 (name "python-minimal")
301 (substitute-keyword-arguments (package-arguments python)
302 ((#:configure-flags cf)
303 `(append ,cf '("--without-system-ffi")))))
305 ;; OpenSSL is a mandatory dependency of Python 3.x, for urllib;
306 ;; zlib is required by 'zipimport', used by pip.
307 (inputs `(("openssl" ,openssl)
310 (define* (wrap-python3 python #:optional (name "python-wrapper"))
311 (package (inherit python)
314 (build-system trivial-build-system)
316 (propagated-inputs `(("python" ,python)))
318 `(#:modules ((guix build utils))
321 (use-modules (guix build utils))
322 (let ((bin (string-append (assoc-ref %outputs "out") "/bin"))
323 (python (string-append (assoc-ref %build-inputs "python") "/bin/")))
327 (symlink (string-append python old)
328 (string-append bin "/" new)))
329 `("python3", "pydoc3", "idle3")
330 `("python", "pydoc", "idle"))))))
331 (synopsis "Wrapper for the Python 3 commands")
333 "This package provides wrappers for the commands of Python@tie{}3.x such
334 that they can be invoked under their usual name---e.g., @command{python}
335 instead of @command{python3}.")))
337 (define-public python-wrapper (wrap-python3 python))
338 (define-public python-minimal-wrapper (wrap-python3 python-minimal))
340 (define-public python-psutil
342 (name "python-psutil")
348 "https://pypi.python.org/packages/source/p/psutil/psutil-"
352 "00c8h1mzqysih99z8pnbmdv117d2naldf11yjy50dhykxsf3n89z"))))
353 (build-system python-build-system)
355 `(("python-setuptools" ,python-setuptools)))
356 (home-page "https://pypi.python.org/pypi/psutil/")
357 (synopsis "Library for retrieving information on running processes")
359 "psutil (Python system and process utilities) is a library for retrieving
360 information on running processes and system utilization (CPU, memory, disks,
361 network) in Python. It is useful mainly for system monitoring, profiling and
362 limiting process resources and management of running processes. It implements
363 many functionalities offered by command line tools such as: ps, top, lsof,
364 netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
365 pidof, tty, taskset, pmap.")
368 (define-public python2-psutil
369 (package-with-python2 python-psutil))
371 (define-public python-passlib
373 (name "python-passlib")
379 "https://pypi.python.org/packages/source/p/passlib/passlib-"
384 "0b9rd161b3mmiwd7nx1v599yh9sp07mlfwac65sjy9qn1l0gd1z9"))))
385 (build-system python-build-system)
387 `(("python-nose" ,python-nose)
388 ("python-setuptools" ,python-setuptools)))
390 `(("python-py-bcrypt" ,python-py-bcrypt)))
394 'check 'set-PYTHON_EGG_CACHE
395 ;; some tests require access to "$HOME/.cython"
396 (lambda* _ (setenv "PYTHON_EGG_CACHE" "/tmp"))
398 (home-page "https://bitbucket.org/ecollins/passlib")
400 "Comprehensive password hashing framework")
402 "Passlib is a password hashing library for Python 2 & 3, which provides
403 cross-platform implementations of over 30 password hashing algorithms, as well
404 as a framework for managing existing password hashes. It's designed to be
405 useful for a wide range of tasks, from verifying a hash found in /etc/shadow,
406 to providing full-strength password hashing for multi-user application.")
409 (define-public python2-passlib
410 (package-with-python2 python-passlib))
412 (define-public python-py-bcrypt
414 (name "python-py-bcrypt")
420 "https://pypi.python.org/packages/source/p/py-bcrypt/py-bcrypt-"
425 "0y6smdggwi5s72v6p1nn53dg6w05hna3d264cq6kas0lap73p8az"))))
426 (build-system python-build-system)
428 `(("python-setuptools" ,python-setuptools)))
429 (home-page "https://code.google.com/p/py-bcrypt")
431 "Bcrypt password hashing and key derivation")
433 "A python wrapper of OpenBSD's Blowfish password hashing code. This
434 system hashes passwords using a version of Bruce Schneier's Blowfish block
435 cipher with modifications designed to raise the cost of off-line password
436 cracking and frustrate fast hardware implementation. The computation cost of
437 the algorithm is parametised, so it can be increased as computers get faster.
438 The intent is to make a compromise of a password database less likely to
439 result in an attacker gaining knowledge of the plaintext passwords (e.g. using
441 ;; "sha2.c" is under BSD-3;
442 ;; "blowfish.c" and "bcrypt.c" are under BSD-4;
443 ;; the rest is under ISC.
444 (license (list isc bsd-3 bsd-4))))
446 (define-public python2-py-bcrypt
447 (package-with-python2 python-py-bcrypt))
450 (define-public python-paramiko
452 (name "python-paramiko")
458 "https://pypi.python.org/packages/source/p/paramiko/paramiko-"
463 "0mbfzm9zlrz6mla9xakrm8wkll3x035f9rj3c5pbgjzfldqscmjg"))))
464 (build-system python-build-system)
466 `(("python-setuptools" ,python-setuptools)))
468 `(("python-pycrypto" ,python-pycrypto)))
470 `(("python-ecdsa" ,python-ecdsa)))
471 (home-page "http://www.paramiko.org/")
472 (synopsis "SSHv2 protocol library")
473 (description "Paramiko is a python implementation of the SSHv2 protocol,
474 providing both client and server functionality. While it leverages a Python C
475 extension for low level cryptography (PyCrypto), Paramiko itself is a pure
476 Python interface around SSH networking concepts.")
479 (define-public python2-paramiko
480 (package-with-python2 python-paramiko))
483 (define-public python-httplib2
485 (name "python-httplib2")
491 "https://pypi.python.org/packages/source/h/httplib2/httplib2-"
496 "1xc3clbrf77r0600kja71j7hk1218sjiq0gfmb8vjdajka8kjqxw"))))
497 (build-system python-build-system)
499 `(("python-setuptools" ,python-setuptools)))
501 "https://github.com/jcgregorio/httplib2")
502 (synopsis "Comprehensive HTTP client library")
504 "A comprehensive HTTP client library supporting many features left out of
505 other HTTP libraries.")
506 (license license:expat)))
508 (define-public python2-httplib2
509 (package-with-python2 python-httplib2))
511 (define-public python-ecdsa
513 (name "python-ecdsa")
519 "https://pypi.python.org/packages/source/e/ecdsa/ecdsa-"
524 "1yj31j0asmrx4an9xvsaj2icdmzy6pw0glfpqrrkrphwdpi1xkv4"))))
525 (build-system python-build-system)
527 `(("python-setuptools" ,python-setuptools)))
529 `(("openssl" ,openssl)))
531 "http://github.com/warner/python-ecdsa")
533 "ECDSA cryptographic signature library (pure python)")
535 "This is an easy-to-use implementation of ECDSA cryptography (Elliptic
536 Curve Digital Signature Algorithm), implemented purely in Python. With this
537 library, you can quickly create keypairs (signing key and verifying key), sign
538 messages, and verify the signatures. The keys and signatures are very short,
539 making them easy to handle and incorporate into other protocols.")
540 (license license:expat)))
542 (define-public python2-ecdsa
543 (package-with-python2 python-ecdsa))
545 (define-public python-ccm
553 "https://pypi.python.org/packages/source/c/ccm/ccm-"
558 "199jw221albs2iv6xczczq88fxnh0aw8hzmys8qkbzkd99dssng9"))))
559 (build-system python-build-system)
561 `(("python-setuptools" ,python-setuptools)))
563 `(("python-pyyaml" ,python-pyyaml)
564 ("python-six" ,python-six)))
565 (home-page "https://github.com/pcmanus/ccm")
566 (synopsis "Cassandra Cluster Manager")
567 (description "A script/library to create, launch and remove an Apache
568 Cassandra cluster on localhost.")
571 (define-public python2-ccm
572 (package-with-python2 python-ccm))
574 (define-public python-pytz
581 (uri (pypi-uri "pytz" version))
584 "1spgdfp1ssya7v3kww7zp71xpj437skpqazcvqr3kr1p1brnw9lr"))))
585 (build-system python-build-system)
586 (arguments `(#:tests? #f)) ; no test target
587 (home-page "http://pythonhosted.org/pytz")
588 (synopsis "Python timezone library")
590 "This library allows accurate and cross platform timezone calculations
591 using Python 2.4 or higher and provides access to the Olson timezone database.")
592 (license license:expat)))
594 (define-public python2-pytz
595 (package-with-python2 python-pytz))
598 (define-public python-babel
600 (name "python-babel")
605 (uri (pypi-uri "Babel" version))
608 "0j2jgfzj1a2m39pm2qc36fzr7a6p5ybwndi0xdzhi2p8zw7dbdkz"))))
609 (build-system python-build-system)
611 `(("python-pytz" ,python-pytz)
612 ("python-setuptools" ,python-setuptools)))
613 (arguments `(#:tests? #f)) ; no test target
614 (home-page "http://babel.pocoo.org/")
616 "Tools for internationalizing Python applications")
618 "Babel is composed of two major parts:
619 - tools to build and work with gettext message catalogs
620 - a Python interface to the CLDR (Common Locale Data Repository), providing
621 access to various locale display names, localized number and date formatting,
625 (define-public python2-babel
626 (package-with-python2 python-babel))
628 (define-public python2-backport-ssl-match-hostname
630 (name "python2-backport-ssl-match-hostname")
636 "https://pypi.python.org/packages/source/b/"
637 "backports.ssl_match_hostname/backports.ssl_match_hostname-"
641 "1bnn47ipvhy49n0m50v27lp4xj6sqdkdw676ypd7pawsn1zhwh87"))))
642 (build-system python-build-system)
643 (arguments `(#:python ,python-2))
645 `(("python2-setuptools" ,python2-setuptools)))
646 (home-page "https://pypi.python.org/pypi/backports.ssl_match_hostname")
647 (synopsis "Backport of ssl.match_hostname() function from Python 3.4")
649 "This backport brings the ssl.match_hostname() function to users of
650 earlier versions of Python. The function checks the hostname in the
651 certificate returned by the server to which a connection has been established,
652 and verifies that it matches the intended target hostname.")
655 (define-public python-h5py
662 (uri (string-append "https://pypi.python.org/packages/source/h/h5py/h5py-"
666 "0q4f9l8grf6pwp64xbv8bmyxx416s7h4522nnxac056ap3savbps"))))
667 (build-system python-build-system)
669 `(#:tests? #f ; no test target
671 (modify-phases %standard-phases
672 (add-after 'unpack 'fix-hdf5-paths
673 (lambda* (#:key inputs #:allow-other-keys)
674 (let ((prefix (assoc-ref inputs "hdf5")))
675 (substitute* "setup_build.py"
676 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
677 (string-append "['" prefix "/lib" "']"))
678 (("'/opt/local/include', '/usr/local/include'")
679 (string-append "'" prefix "/include" "'")))
680 (substitute* "setup_configure.py"
681 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
682 (string-append "['" prefix "/lib" "']")))
685 `(("python-numpy" ,python-numpy)))
689 `(("python-cython" ,python-cython)))
690 (home-page "http://www.h5py.org/")
691 (synopsis "Read and write HDF5 files from Python")
693 "The h5py package provides both a high- and low-level interface to the
694 HDF5 library from Python. The low-level interface is intended to be a
695 complete wrapping of the HDF5 API, while the high-level component supports
696 access to HDF5 files, datasets and groups using established Python and NumPy
700 (define-public python2-h5py
701 (let ((h5py (package-with-python2 python-h5py)))
702 (package (inherit h5py)
704 `(("python2-numpy" ,python2-numpy)
707 (package-propagated-inputs h5py)))))))
709 (define-public python-lockfile
711 (name "python-lockfile")
716 (uri (string-append "https://pypi.python.org/packages/source/l/lockfile/"
717 "lockfile-" version ".tar.gz"))
720 "0iwif7i84gwpvrnpv4brshdk8j6l77smvknm8k3bg77mj6f5ini3"))))
721 (build-system python-build-system)
722 (arguments '(#:test-target "check"))
723 (home-page "http://code.google.com/p/pylockfile/")
724 (synopsis "Platform-independent file locking module")
726 "The lockfile package exports a LockFile class which provides a simple
727 API for locking files.")
728 (license license:expat)))
730 (define-public python2-lockfile
731 (package-with-python2 python-lockfile))
733 (define-public python-mock
740 (uri (string-append "https://pypi.python.org/packages/source/m/mock/"
741 "mock-" version ".tar.gz"))
744 "0kzlsbki6q0awf89rc287f3aj8x431lrajf160a70z0ikhnxsfdq"))))
745 (build-system python-build-system)
746 (arguments '(#:test-target "check"))
747 (home-page "http://code.google.com/p/mock/")
748 (synopsis "Python mocking and patching library for testing")
750 "Mock is a library for testing in Python. It allows you to replace parts
751 of your system under test with mock objects and make assertions about how they
753 (license license:expat)))
755 (define-public python2-mock
756 (package-with-python2 python-mock))
759 (define-public python-setuptools
761 (name "python-setuptools")
766 (uri (string-append "https://pypi.python.org/packages/source/s/setuptools/setuptools-"
770 "0kc7rbav00ks6iaw14p38y81q12fx0lpkhgf5m97xc04f5r318ig"))))
771 (build-system python-build-system)
772 ;; FIXME: Tests require pytest, which itself relies on setuptools.
773 ;; One could bootstrap with an internal untested setuptools.
776 (home-page "https://pypi.python.org/pypi/setuptools")
778 "Library designed to facilitate packaging Python projects")
780 "Setuptools is a fully-featured, stable library designed to facilitate
781 packaging Python projects, where packaging includes:
782 Python package and module definitions,
783 distribution package metadata,
785 project installation,
786 platform-specific details,
790 (define-public python2-setuptools
791 (package-with-python2 python-setuptools))
794 (define-public python-pycrypto
796 (name "python-pycrypto")
801 (uri (string-append "https://pypi.python.org/packages/source/p/"
802 "pycrypto/pycrypto-" version ".tar.gz"))
805 "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj"))))
806 (build-system python-build-system)
808 `(("python-setuptools" ,python-setuptools)))
815 'build 'set-build-env
816 ;; pycrypto runs an autoconf configure script behind the scenes
818 (setenv "CONFIG_SHELL" (which "bash")))
820 (home-page "http://www.pycrypto.org/")
821 (synopsis "Cryptographic modules for Python")
823 "Pycrypto is a collection of both secure hash functions (such as SHA256
824 and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal,
825 etc.). The package is structured to make adding new modules easy.")
826 (license public-domain)))
828 (define-public python2-pycrypto
829 (let ((pycrypto (package-with-python2 python-pycrypto)))
830 (package (inherit pycrypto)
832 `(("python" ,python-2)
835 (package-inputs pycrypto)))))))
837 (define-public python-keyring
839 (name "python-keyring")
844 (uri (string-append "https://pypi.python.org/packages/source/k/"
845 "keyring/keyring-" version ".zip"))
848 "1vxazfbcwggyfyramh55shkxs08skhpqrkm6lrrjnygnm8c1l2zg"))))
849 (build-system python-build-system)
852 ("python-setuptools" ,python-setuptools)
853 ("python-mock" ,python-mock)))
855 `(("python-pycrypto" ,python-pycrypto)))
857 `(#:tests? #f ;TODO: tests require pytest
862 (let ((unzip (string-append (assoc-ref %build-inputs "unzip")
864 (source (assoc-ref %build-inputs "source")))
865 (and (zero? (system* unzip source))
866 (chdir (string-append "keyring-" ,version)))))
868 (home-page "http://bitbucket.org/kang/python-keyring-lib")
869 (synopsis "Store and access your passwords safely")
871 "The Python keyring lib provides a easy way to access the system keyring
872 service from python. It can be used in any application that needs safe
874 ;; "MIT" and PSF dual license
877 (define-public python2-keyring
878 (let ((keyring (package-with-python2 python-keyring)))
879 (package (inherit keyring)
881 `(("python2-pycrypto" ,python2-pycrypto))))))
883 (define-public python-six
890 (uri (pypi-uri "six" version))
893 "0snmb8xffb3vsma0z67i0h0w2g2dy0p3gsgh9gi4i0kgc5l8spqh"))))
894 (build-system python-build-system)
896 `(("python-setuptools" ,python-setuptools)))
897 (home-page "http://pypi.python.org/pypi/six/")
898 (synopsis "Python 2 and 3 compatibility utilities")
900 "Six is a Python 2 and 3 compatibility library. It provides utility
901 functions for smoothing over the differences between the Python versions with
902 the goal of writing Python code that is compatible on both Python versions.
903 Six supports every Python version since 2.5. It is contained in only one
904 Python file, so it can be easily copied into your project.")
907 (define-public python2-six
908 (package-with-python2 python-six))
910 (define-public python-dateutil-2
912 (name "python-dateutil")
917 (uri (string-append "https://pypi.python.org/packages/source/p/"
918 name "/" name "-" version ".tar.gz"))
921 "0s74ad6r789810s10dxgvaf48ni6adac2icrdad34zxygqq6bj7f"))))
922 (build-system python-build-system)
924 `(("python-setuptools" ,python-setuptools)
925 ("python-six" ,python-six)))
926 (home-page "http://labix.org/python-dateutil")
927 (synopsis "Extensions to the standard datetime module")
929 "The dateutil module provides powerful extensions to the standard
930 datetime module, available in Python 2.3+.")
933 (define-public python2-dateutil-2
934 (package-with-python2 python-dateutil-2))
936 (define-public python-dateutil
938 (name "python-dateutil")
939 (version "1.5") ; last version for python < 3
943 (uri (string-append "http://labix.org/download/python-dateutil/"
944 "python-dateutil-" version ".tar.gz"))
947 "0fqfglhy5khbvsipr3x7m6bcaqljh8xl5cw33vbfxy7qhmywm2n0"))))
948 (build-system python-build-system)
950 `(("python-setuptools" ,python-setuptools)))
951 (home-page "http://labix.org/python-dateutil")
952 (synopsis "Extensions to the standard datetime module")
954 "The dateutil module provides powerful extensions to the standard
955 datetime module, available in Python 2.3+.")
958 (define-public python2-dateutil
959 (package-with-python2 python-dateutil))
961 (define-public python-parsedatetime
963 (name "python-parsedatetime")
968 (uri (string-append "https://pypi.python.org/packages/source/p/"
969 "parsedatetime/parsedatetime-" version ".tar.gz"))
972 "1as0mm4ql3z0324nc9bys2s1ngh507i317p16b79rx86wlmvx9ix"))))
973 (build-system python-build-system)
975 `(("python-setuptools" ,python-setuptools)))
976 (home-page "http://github.com/bear/parsedatetime/")
978 "Parse human-readable date/time text")
980 "Parse human-readable date/time text.")
983 (define-public python2-parsedatetime
984 (package-with-python2 python-parsedatetime))
986 (define-public python-pandas
988 (name "python-pandas")
993 (uri (string-append "https://pypi.python.org/packages/source/p/"
994 "pandas/pandas-" version ".tar.gz"))
996 (base32 "1wfrp8dx1zcsry6f09ndza6qm1yr7f163211f4l9vjlnhxpxw4s0"))))
997 (build-system python-build-system)
999 `(;; Three tests fail:
1000 ;; - test_read_google
1001 ;; - test_read_yahoo
1002 ;; - test_month_range_union_tz_dateutil
1005 `(("python-numpy" ,python-numpy)
1006 ("python-pytz" ,python-pytz)
1007 ("python-dateutil" ,python-dateutil-2)))
1009 `(("python-nose" ,python-nose)
1010 ("python-setuptools" ,python-setuptools)))
1011 (home-page "http://pandas.pydata.org")
1012 (synopsis "Data structures for data analysis, time series, and statistics")
1014 "Pandas is a Python package providing fast, flexible, and expressive data
1015 structures designed to make working with structured (tabular,
1016 multidimensional, potentially heterogeneous) and time series data both easy
1017 and intuitive. It aims to be the fundamental high-level building block for
1018 doing practical, real world data analysis in Python.")
1021 (define-public python2-pandas
1022 (let ((pandas (package-with-python2 python-pandas)))
1023 (package (inherit pandas)
1025 `(("python2-numpy" ,python2-numpy)
1026 ,@(alist-delete "python-numpy"
1027 (package-propagated-inputs pandas)))))))
1029 (define-public python-tzlocal
1031 (name "python-tzlocal")
1036 (uri (string-append "https://pypi.python.org/packages/source/t/"
1037 "tzlocal/tzlocal-" version ".zip"))
1040 "1m3y918c3chf41fwg2bx4w42bqsjzn3dyvvcmwwy13c8gj6zssv9"))))
1041 (build-system python-build-system)
1044 ("python-setuptools" ,python-setuptools)))
1045 (inputs `(("python-pytz" ,python-pytz)))
1051 (let ((unzip (string-append (assoc-ref %build-inputs "unzip")
1053 (source (assoc-ref %build-inputs "source")))
1054 (and (zero? (system* unzip source))
1055 (chdir (string-append "tzlocal-" ,version)))))
1057 (home-page "https://github.com/regebro/tzlocal")
1059 "Local timezone information for Python")
1061 "Tzlocal returns a tzinfo object with the local timezone information.
1062 This module attempts to fix a glaring hole in pytz, that there is no way to
1063 get the local timezone information, unless you know the zoneinfo name, and
1064 under several distributions that's hard or impossible to figure out.")
1067 (define-public python-pysam
1069 (name "python-pysam")
1074 (uri (string-append "https://pypi.python.org/packages/source/p/pysam/pysam-"
1078 "1fb6i6hbpzxaxb62kyyp5alaidwhj40f7c6gwbhr6njzlqd5l459"))))
1079 (build-system python-build-system)
1081 `(#:tests? #f ; tests are excluded in the manifest
1086 (setenv "LDFLAGS" "-lncurses")
1087 (setenv "CFLAGS" "-D_CURSES_LIB=1"))
1090 `(("python-cython" ,python-cython)
1091 ("python-setuptools" ,python-setuptools)
1092 ("ncurses" ,ncurses)
1094 (home-page "https://github.com/pysam-developers/pysam")
1095 (synopsis "Python bindings to the SAMtools C API")
1097 "Pysam is a Python module for reading and manipulating files in the
1098 SAM/BAM format. Pysam is a lightweight wrapper of the SAMtools C API. It
1099 also includes an interface for tabix.")
1100 (license license:expat)))
1102 (define-public python2-pysam
1103 (package-with-python2 python-pysam))
1105 (define-public python2-pysqlite
1107 (name "python2-pysqlite")
1108 (version "2.6.3a") ; see below
1112 ;; During the switch from code.google.com to pypi.python.org, the 2.6.3
1113 ;; tarball was modified, but the version number was kept:
1114 ;; <https://lists.gnu.org/archive/html/guix-devel/2014-02/msg00077.html>.
1115 ;; Here we want to refer to the pypi-hosted 2.6.3 tarball.
1117 "https://pypi.python.org/packages/source/p/pysqlite/pysqlite-"
1121 "13djzgnbi71znjjyaw4nybg6smilgszcid646j5qav7mdchkb77y"))))
1122 (build-system python-build-system)
1124 `(("sqlite" ,sqlite)))
1126 `(#:python ,python-2 ; incompatible with Python 3
1127 #:tests? #f)) ; no test target
1128 (home-page "https://pypi.python.org/pypi/pysqlite")
1129 (synopsis "SQLite bindings for Python")
1131 "Pysqlite provides SQLite bindings for Python that comply to the
1132 Database API 2.0T.")
1133 (license license:zlib)))
1136 (define-public python2-mechanize
1138 (name "python2-mechanize")
1143 (uri (string-append "https://pypi.python.org/packages/source/m/mechanize/mechanize-"
1147 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1148 (build-system python-build-system)
1150 `(("python2-setuptools" ,python2-setuptools)))
1152 `(#:python ,python-2 ; apparently incompatible with Python 3
1154 ;; test fails with message
1155 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1156 ;; (python-3.3.2) or
1157 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1159 ;; The source code is from March 2011 and probably not up-to-date
1160 ;; with respect to python unit tests.
1161 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1163 "Stateful programmatic web browsing in Python")
1165 "Mechanize implements stateful programmatic web browsing in Python,
1166 after Andy Lester’s Perl module WWW::Mechanize.")
1167 (license (non-copyleft "file://COPYING"
1168 "See COPYING in the distribution."))))
1171 (define-public python-simplejson
1173 (name "python-simplejson")
1178 (uri (string-append "https://pypi.python.org/packages/source/s/simplejson/simplejson-"
1182 "07wsry5j44l5zzm74l4j2bvasiq8n5m32f31n2p7c68i5vc6p2ks"))))
1183 (build-system python-build-system)
1184 (home-page "http://simplejson.readthedocs.org/en/latest/")
1186 "Json library for Python")
1188 "JSON (JavaScript Object Notation) is a subset of JavaScript
1189 syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1192 Simplejson exposes an API familiar to users of the standard library marshal
1193 and pickle modules. It is the externally maintained version of the json
1194 library contained in Python 2.6, but maintains compatibility with Python 2.5
1195 and (currently) has significant performance advantages, even without using
1196 the optional C extension for speedups. Simplejson is also supported on
1200 (define-public python2-simplejson
1201 (package-with-python2 python-simplejson))
1204 (define-public python2-pyicu
1206 (name "python2-pyicu")
1211 (uri (string-append "https://pypi.python.org/packages/source/P/PyICU/PyICU-"
1215 "1y361x82lnh9k9srmdx3q92z5iag112z7r5fxm0n1sfwb349yjdw"))))
1216 (build-system python-build-system)
1218 `(("icu4c" ,icu4c)))
1220 `(#:python ,python-2 ; Python 3 works also, but needs special care for
1221 ; linking with libpython3.3m
1222 #:tests? #f)) ; no check target
1223 (home-page "http://pyicu.osafoundation.org/")
1224 (synopsis "Python extension wrapping the ICU C++ API")
1226 "PyICU is a python extension wrapping the ICU C++ API.")
1229 (define-public python2-dogtail
1230 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1231 ;; spaces in indentation" with Python 3.
1233 (name "python2-dogtail")
1238 "https://fedorahosted.org/released/dogtail/dogtail-"
1242 "1yc4cg7ip87z15gyd4wy2vzbywrjc52a3m8r8gqy2b50d65llcg1"))))
1243 (build-system python-build-system)
1244 (arguments `(#:python ,python-2
1245 #:tests? #f)) ; invalid command "test"
1246 (home-page "https://fedorahosted.org/dogtail/")
1247 (synopsis "GUI test tool and automation framework written in Python")
1249 "Dogtail is a GUI test tool and automation framework written in Python.
1250 It uses Accessibility (a11y) technologies to communicate with desktop
1251 applications. dogtail scripts are written in Python and executed like any
1252 other Python program.")
1255 (define-public python2-empy
1257 (name "python2-empy")
1261 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1265 "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6"))))
1266 (build-system python-build-system)
1268 `(#:python ,python-2
1269 #:phases (alist-replace
1272 (zero? (system* "./test.sh")))
1274 (home-page "http://www.alcyone.com/software/empy/")
1275 (synopsis "Templating system for Python")
1277 "EmPy is a system for embedding Python expressions and statements in
1278 template text; it takes an EmPy source file, processes it, and produces
1279 output. This is accomplished via expansions, which are special signals to the
1280 EmPy system and are set off by a special prefix (by default the at sign, @@).
1281 EmPy can expand arbitrary Python expressions and statements in this way, as
1282 well as a variety of special forms. Textual data not explicitly delimited in
1283 this way is sent unaffected to the output, allowing Python to be used in
1284 effect as a markup language. Also supported are callbacks via hooks,
1285 recording and playback via diversions, and dynamic, chainable filters. The
1286 system is highly configurable via command line options and embedded
1288 (license lgpl2.1+)))
1290 (define-public python2-element-tree
1292 (name "python2-element-tree")
1297 "http://effbot.org/media/downloads/elementtree-"
1298 version "-20050316.tar.gz"))
1301 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1302 (build-system python-build-system)
1304 `(#:python ,python-2 ; seems to be part of Python 3
1305 #:tests? #f)) ; no 'test' sub-command
1306 (synopsis "Toolkit for XML processing in Python")
1308 "ElementTree is a Python library supporting lightweight XML processing.")
1309 (home-page "http://effbot.org/zone/element-index.htm")
1310 (license (x11-style "http://docs.python.org/2/license.html"
1311 "Like \"CWI LICENSE AGREEMENT FOR PYTHON \
1312 0.9.0 THROUGH 1.2\"."))))
1314 (define-public python2-pybugz
1316 (name "python2-pybugz")
1321 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1325 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
1326 (patches (map search-patch
1327 (list "pybugz-stty.patch"
1328 "pybugz-encode-error.patch")))))
1329 (build-system python-build-system)
1331 `(#:python ,python-2 ; SyntaxError with Python 3
1332 #:tests? #f)) ; no 'test' sub-command
1333 (inputs `(("element-tree" ,python2-element-tree)))
1334 (synopsis "Python and command-line interface to Bugzilla")
1336 "PyBugz is a Python library and command-line tool to query the Bugzilla
1337 bug tracking system. It is meant as an aid to speed up interaction with the
1339 (home-page "http://www.liquidx.net/pybugz/")
1342 (define-public python-enum34
1344 (name "python-enum34")
1349 (uri (string-append "https://pypi.python.org/packages/source/e/"
1350 "enum34/enum34-" version ".tar.gz"))
1353 "0dg6mpg9n4g9diyrbnbb5vd9d1qw9f265zwhknqy0mxh0cvmjjrq"))))
1354 (build-system python-build-system)
1356 `(("python-setuptools" ,python-setuptools)))
1361 (lambda _ (zero? (system* "python" "enum/test_enum.py")))
1363 (home-page "https://pypi.python.org/pypi/enum34")
1364 (synopsis "Backported Python 3.4 Enum")
1366 "Enum34 is the new Python stdlib enum module available in Python 3.4
1367 backported for previous versions of Python from 2.4 to 3.3.")
1370 (define-public python-parse-type
1372 (name "python-parse-type")
1377 (uri (string-append "https://pypi.python.org/packages/source/p/"
1378 "parse_type/parse_type-" version ".tar.gz"))
1381 "0iv1c34npr4iynwpgv1vkjx9rjd18a85ir8c01gc5f7wp8iv7l1x"))))
1382 (build-system python-build-system)
1384 `(("python-setuptools" ,python-setuptools)
1385 ("python-six" ,python-six)
1386 ("python-parse" ,python-parse)
1387 ("python-enum34" ,python-enum34))) ;required for python<3.4
1388 (arguments '(#:tests? #f)) ;TODO: tests require pytest
1389 (home-page "https://github.com/jenisys/parse_type")
1390 (synopsis "Extended parse module")
1392 "Parse_type extends the python parse module.")
1395 (define-public python-parse
1397 (name "python-parse")
1402 (uri (string-append "https://pypi.python.org/packages/source/p/"
1403 "parse/parse-" version ".tar.gz"))
1406 "0m30q64l6szl7s9mhvqy64w2fdhdn8lb91fmacjiwbv3479cmk57"))))
1407 (build-system python-build-system)
1412 (lambda _ (zero? (system* "python" "test_parse.py")))
1414 (home-page "https://github.com/r1chardj0n3s/parse")
1415 (synopsis "Parse strings")
1417 "Parse strings using a specification based on the Python format()
1422 (define-public scons
1428 (uri (string-append "mirror://sourceforge/scons/scons-"
1432 "0hdlci43wjz8maryj83mz04ir6rwcdrrzpd7cpzvdlzycqhdfmsb"))))
1433 (build-system python-build-system)
1435 ;; With Python 3.x, fails to build with a syntax error.
1436 `(#:python ,python-2
1437 #:tests? #f)) ; no 'python setup.py test' command
1438 (home-page "http://scons.org/")
1439 (synopsis "Software construction tool written in Python")
1441 "SCons is a software construction tool. Think of SCons as an improved,
1442 cross-platform substitute for the classic Make utility with integrated
1443 functionality similar to autoconf/automake and compiler caches such as ccache.
1444 In short, SCons is an easier, more reliable and faster way to build
1448 (define-public python-extras
1450 (name "python-extras")
1456 "https://pypi.python.org/packages/source/e/extras/extras-"
1460 "1h7zx4dfyclalg0fqnfjijpn0f793a9mx8sy3b27gd31nr6dhq3s"))))
1461 (build-system python-build-system)
1463 `(("python-setuptools" ,python-setuptools)))
1465 ;; error in setup.cfg: command 'test' has no such option 'buffer'
1467 (home-page "https://github.com/testing-cabal/extras")
1468 (synopsis "Useful extensions to the Python standard library")
1470 "Extras is a set of extensions to the Python standard library.")
1471 (license license:expat)))
1473 (define-public python2-extras
1474 (package-with-python2 python-extras))
1476 (define-public python-mimeparse
1478 (name "python-mimeparse")
1484 "https://pypi.python.org/packages/source/p/python-mimeparse/python-mimeparse-"
1488 "1hyxg09kaj02ri0rmwjqi86wk4nd1akvv7n0dx77azz76wga4s9w"))))
1489 (build-system python-build-system)
1491 `(("python-setuptools" ,python-setuptools)))
1493 '(#:tests? #f)) ; no setup.py test command
1495 "https://github.com/dbtsai/python-mimeparse")
1496 (synopsis "Python library for parsing MIME types")
1498 "Mimeparse provides basic functions for parsing MIME type names and
1499 matching them against a list of media-ranges.")
1500 (license license:expat)))
1502 (define-public python2-mimeparse
1503 (package-with-python2 python-mimeparse))
1505 (define-public python-nose
1507 (name "python-nose")
1513 "https://pypi.python.org/packages/source/n/nose/nose-"
1517 "00qymfgwg4iam4xi0w9bnv7lcb3fypq1hzfafzgs1rfmwaj67g3n"))))
1518 (build-system python-build-system)
1520 `(("python-setuptools" ,python-setuptools)))
1522 '(#:tests? #f)) ; FIXME: test suite fails
1523 (home-page "http://readthedocs.org/docs/nose/")
1524 (synopsis "Python testing library")
1526 "Nose extends the unittest library to make testing easier.")
1527 (license lgpl2.0+)))
1529 (define-public python2-nose
1530 (package-with-python2 python-nose))
1532 (define-public python-unittest2
1534 (name "python-unittest2")
1540 "https://pypi.python.org/packages/source/u/unittest2py3k/unittest2py3k-"
1544 "00yl6lskygcrddx5zspkhr0ibgvpknl4678kkm6s626539grq93q"))))
1545 (build-system python-build-system)
1547 `(("python-setuptools" ,python-setuptools)))
1548 (home-page "http://pypi.python.org/pypi/unittest2")
1549 (synopsis "Python unit testing library")
1551 "Unittest2 is a replacement for the unittest module in the Python
1555 (define-public python2-unittest2
1556 (package (inherit python-unittest2)
1557 (name "python2-unittest2")
1563 "https://pypi.python.org/packages/source/u/unittest2/unittest2-"
1567 "0wbs4i4x3x7klr3v35ss6p9mcqz883i1xgcpkhvl7n2lyv6yhpda"))))
1569 `(("python2-setuptools" ,python2-setuptools)))
1571 `(#:python ,python-2
1572 #:tests? #f)))) ; no setup.py test command
1574 (define-public python-py
1582 "https://pypi.python.org/packages/source/p/py/py-"
1586 "1jkhffpai419v5rickm2vz86p9bkg3b3kcm2k4bi5wfajhw2m3xs"))))
1587 (build-system python-build-system)
1589 `(("python-setuptools" ,python-setuptools)))
1590 (home-page "http://pylib.readthedocs.org/")
1591 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1593 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1594 code introspection, and logging.")
1595 (license license:expat)))
1597 (define-public python2-py
1598 (package-with-python2 python-py))
1600 (define-public python-pytest
1602 (name "python-pytest")
1608 "https://pypi.python.org/packages/source/p/pytest/pytest-"
1612 "0g2w4p0n42wvz8rq4k6gnzpkakgz3g8sfanxk8jrsra9675snkcr"))
1613 (modules '((guix build utils)))
1615 ;; One of the tests involves the /usr directory, so it fails.
1616 '(substitute* "testing/test_argcomplete.py"
1617 (("def test_remove_dir_prefix\\(self\\):")
1618 "@pytest.mark.xfail\n def test_remove_dir_prefix(self):")))))
1619 (build-system python-build-system)
1621 `(("python-setuptools" ,python-setuptools)
1622 ("python-py" ,python-py)
1623 ("python-nose" ,python-nose)
1624 ("python-mock" ,python-mock)))
1625 (home-page "http://pytest.org")
1626 (synopsis "Python testing library")
1628 "Pytest is a testing tool that provides auto-discovery of test modules
1629 and functions, detailed info on failing assert statements, modular fixtures,
1630 and many external plugins.")
1631 (license license:expat)))
1633 (define-public python2-pytest
1634 (package-with-python2 python-pytest))
1636 (define-public python-pytest-cov
1638 (name "python-pytest-cov")
1643 (uri (pypi-uri "pytest-cov" version))
1646 "1lf9jsmhqk5nc4w3kzwglmdzjvmi7ajvrsnwv826j3bn0wzx8c92"))))
1647 (build-system python-build-system)
1649 `(("python-coverage" ,python-coverage)
1650 ("python-pytest" ,python-pytest)))
1652 `(("python-setuptools" ,python-setuptools)))
1653 (home-page "https://github.com/pytest-dev/pytest-cov")
1654 (synopsis "Pytest plugin for measuring coverage")
1656 "Pytest-cov produces coverage reports. It supports centralised testing and
1657 distributed testing in both load and each modes. It also supports coverage
1659 (license license:expat)))
1661 (define-public python2-pytest-cov
1662 (package-with-python2 python-pytest-cov))
1664 (define-public python-pytest-runner
1666 (name "python-pytest-runner")
1671 (uri (string-append "https://pypi.python.org/packages/source/p/"
1672 "pytest-runner/pytest-runner-"
1676 "1nwcqx0l3fv52kv8526wy8ypzghbq96c96di318d98d3wh7a8xg7"))))
1677 (build-system python-build-system)
1680 (modify-phases %standard-phases
1681 ;; The fancy way of setting the version with setuptools_scm does not
1682 ;; seem to work here.
1683 (add-after 'unpack 'set-version
1685 (substitute* "docs/conf.py"
1686 (("version = setuptools_scm\\.get_version\\(root='\\.\\.')")
1687 (string-append "version = \"" ,version "\"")))
1690 `(("python-pytest" ,python-pytest)
1691 ("python-setuptools" ,python-setuptools)
1692 ("python-setuptools-scm" ,python-setuptools-scm)))
1693 (home-page "https://bitbucket.org/pytest-dev/pytest-runner")
1694 (synopsis "Invoke py.test as a distutils command")
1696 "This package provides a @command{pytest-runner} command that
1697 @file{setup.py} files can use to run tests.")
1698 (license license:expat)))
1700 (define-public python2-pytest-runner
1701 (package-with-python2 python-pytest-runner))
1703 (define-public python-scripttest
1705 (name "python-scripttest")
1711 "https://pypi.python.org/packages/source/s/scripttest/scripttest-"
1715 "0f4w84k8ck82syys7yg9maz93mqzc8p5ymis941x034v44jzq74m"))))
1716 (build-system python-build-system)
1718 `(("python-setuptools" ,python-setuptools)
1719 ("python-pytest" ,python-pytest)))
1720 (home-page "http://pythonpaste.org/scripttest/")
1721 (synopsis "Python library to test command-line scripts")
1722 (description "Scripttest is a Python helper library for testing
1723 interactive command-line applications. With it you can run a script in a
1724 subprocess and see the output as well as any file modifications.")
1725 (license license:expat)))
1727 (define-public python2-scripttest
1728 (package-with-python2 python-scripttest))
1730 (define-public python-testtools
1732 (name "python-testtools")
1738 "https://pypi.python.org/packages/source/t/testtools/testtools-"
1742 "1dyml28ykpl5jb9khdmcdvhy1cxqingys6qvj2k04fzlaj6z3bbx"))))
1743 (build-system python-build-system)
1745 `(("python-mimeparse" ,python-mimeparse)))
1747 `(("python-setuptools" ,python-setuptools)
1748 ("python-extras" ,python-extras)))
1749 (home-page "https://github.com/testing-cabal/testtools")
1751 "Extensions to the Python standard library unit testing framework")
1753 "Testtools extends the Python standard library unit testing framework to
1754 provide matchers, more debugging information, and cross-Python
1758 (define-public python2-testtools
1759 (package-with-python2 python-testtools))
1761 (define-public python-testscenarios
1763 (name "python-testscenarios")
1769 "https://pypi.python.org/packages/source/t/testscenarios/testscenarios-"
1773 "1671jvrvqlmbnc42j7pc5y6vc37q44aiwrq0zic652pxyy2fxvjg"))))
1774 (build-system python-build-system)
1776 `(("python-setuptools" ,python-setuptools)
1777 ("python-testtools" ,python-testtools)
1778 ("python-mimeparse" ,python-mimeparse)))
1779 (home-page "https://launchpad.net/testscenarios")
1780 (synopsis "Pyunit extension for dependency injection")
1782 "Testscenarios provides clean dependency injection for Python unittest
1784 (license (list bsd-3 asl2.0)))) ; at the user's option
1786 (define-public python2-testscenarios
1787 (package-with-python2 python-testscenarios))
1789 (define-public python-testresources
1791 (name "python-testresources")
1797 "https://pypi.python.org/packages/source/t/testresources/testresources-"
1801 "0cbj3plbllyz42c4b5xxgwaa7mml54lakslrn4kkhinxhdri22md"))))
1802 (build-system python-build-system)
1804 `(("python-setuptools" ,python-setuptools)))
1805 (home-page "https://launchpad.net/testresources")
1807 "Pyunit extension for managing test resources")
1809 "Testresources is an extension to Python's unittest to allow declarative
1810 use of resources by test cases.")
1811 (license (list bsd-3 asl2.0)))) ; at the user's option
1813 (define-public python2-testresources
1814 (package-with-python2 python-testresources))
1816 (define-public python-subunit
1818 (name "python-subunit")
1824 "https://pypi.python.org/packages/source/p/python-subunit/python-subunit-"
1828 "1nkw9wfbvizmpajbj3in8ns07g7lwkiv8hip14jjlwk3cacls6jv"))))
1829 (build-system python-build-system)
1831 `(("python-setuptools" ,python-setuptools)
1832 ("python-testtools" ,python-testtools)
1833 ("python-mimeparse" ,python-mimeparse)
1834 ("python-testscenarios" ,python-testscenarios)))
1835 (home-page "http://launchpad.net/subunit")
1836 (synopsis "Python implementation of the subunit protocol")
1838 "Python-subunit is a Python implementation of the subunit test streaming
1840 (license (list bsd-3 asl2.0)))) ; at the user's option
1842 (define-public python2-subunit
1843 (package-with-python2 python-subunit))
1845 ;; Recent versions of python-fixtures need a recent version of python-pbr,
1846 ;; which needs a recent version of python-fixtures. To fix this circular
1847 ;; dependency, we keep old versions of python-fixtures and python-pbr to
1848 ;; bootstrap the whole thing:
1849 ;; - python-fixtures-0.3.16 is used to build python-pbr-0.11
1850 ;; - python-pbr-0.11 is used to build python-fixtures
1851 ;; - python-fixtures is used to build python-pbr
1852 (define-public python-fixtures-0.3.16
1854 (name "python-fixtures")
1860 "https://pypi.python.org/packages/source/f/fixtures/fixtures-"
1864 "0x9r2gwilcig5g54k60bxzg96zabizq1855lrprlb4zckalp9asc"))))
1865 (build-system python-build-system)
1867 `(("python-setuptools" ,python-setuptools)))
1869 '(#:tests? #f)) ; no setup.py test command
1870 (home-page "https://launchpad.net/python-fixtures")
1871 (synopsis "Python test fixture library")
1873 "Fixtures provides a way to create reusable state, useful when writing
1875 (license (list bsd-3 asl2.0)))) ; at user's option
1877 (define-public python2-fixtures-0.3.16
1878 (package-with-python2 python-fixtures-0.3.16))
1880 (define-public python-pbr-0.11
1888 "https://pypi.python.org/packages/source/p/pbr/pbr-"
1892 "0v9gb7gyqf7q9s99l0nnjj9ww9b0jvyqlwm4d56pcyinxydddw6p"))))
1893 (build-system python-build-system)
1895 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1897 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
1898 ("python-pip" ,python-pip)
1899 ("python-setuptools" ,python-setuptools)))
1900 (home-page "https://launchpad.net/pbr")
1901 (synopsis "Change the default behavior of Python’s setuptools")
1903 "Python Build Reasonableness (PBR) is a library that injects some useful
1904 and sensible default behaviors into your setuptools run.")
1907 (define-public python2-pbr-0.11
1908 (package-with-python2 python-pbr-0.11))
1910 (define-public python-fixtures
1912 (name "python-fixtures")
1918 "https://pypi.python.org/packages/source/f/fixtures/fixtures-"
1922 "1khpywdh91ijryhxjxiyyi5rmbimhl8hwbbf8lazhgzq6yxz6g5n"))))
1923 (build-system python-build-system)
1925 `(("python-six" ,python-six)
1926 ("python-pbr-0.11" ,python-pbr-0.11)))
1928 `(("python-pip" ,python-pip)
1929 ("python-setuptools" ,python-setuptools)
1931 ("python-testtools" ,python-testtools)))
1933 '(#:tests? #f)) ; no setup.py test command
1934 (home-page "https://launchpad.net/python-fixtures")
1935 (synopsis "Python test fixture library")
1937 "Fixtures provides a way to create reusable state, useful when writing
1939 (license (list bsd-3 asl2.0)))) ; at user's option
1941 (define-public python2-fixtures
1942 (package-with-python2 python-fixtures))
1944 (define-public python-testrepository
1946 (name "python-testrepository")
1952 "https://pypi.python.org/packages/source/t/testrepository/testrepository-"
1956 "1ssqb07c277010i6gzzkbdd46gd9mrj0bi0i8vn560n2k2y4j93m"))))
1957 (build-system python-build-system)
1959 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
1960 ("python-testtools" ,python-testtools)))
1962 `(("python-setuptools" ,python-setuptools)
1963 ("python-subunit" ,python-subunit)
1964 ("python-mimeparse" ,python-mimeparse)))
1965 (home-page "https://launchpad.net/testrepository")
1966 (synopsis "Database for Python test results")
1967 (description "Testrepository provides a database of test results which can
1968 be used as part of a developer's workflow to check things such as what tests
1969 have failed since the last commit or what tests are currently failing.")
1970 (license (list bsd-3 asl2.0)))) ; at user's option
1972 (define-public python2-testrepository
1973 (package-with-python2 python-testrepository))
1975 (define-public python-coverage
1977 (name "python-coverage")
1983 "https://pypi.python.org/packages/source/c/coverage/coverage-"
1987 "0knlbq79g2ww6xzsyknj9rirrgrgc983dpa2d9nkdf31mb2a3bni"))))
1988 (build-system python-build-system)
1990 `(("python-setuptools" ,python-setuptools)))
1991 (home-page "http://nedbatchelder.com/code/coverage")
1992 (synopsis "Code coverage measurement for Python")
1994 "Coverage measures code coverage, typically during test execution. It
1995 uses the code analysis tools and tracing hooks provided in the Python standard
1996 library to determine which lines are executable, and which have been
2000 (define-public python2-coverage
2001 (package-with-python2 python-coverage))
2003 (define-public python-discover
2005 (name "python-discover")
2011 "https://pypi.python.org/packages/source/d/discover/discover-"
2015 "0y8d0zwiqar51kxj8lzmkvwc3b8kazb04gk5zcb4nzg5k68zmhq5"))))
2016 (build-system python-build-system)
2018 `(("python-setuptools" ,python-setuptools)))
2019 (home-page "http://pypi.python.org/pypi/discover/")
2021 "Python test discovery for unittest")
2023 "Discover provides test discovery for unittest, a feature that has been
2024 backported from Python 2.7 for Python 2.4+.")
2027 (define-public python2-discover
2028 (package-with-python2 python-discover))
2030 (define-public behave
2036 (uri (string-append "https://pypi.python.org/packages/source/b/"
2037 name "/" name "-" version ".tar.gz"))
2040 "1v2rfy8xnf0rk7cj4cgr7lam4015d458i7bg0xqs9czfv6njlm14"))))
2041 (build-system python-build-system)
2043 `(("python-setuptools" ,python-setuptools)
2044 ("python-six" ,python-six)
2045 ("python-enum43" ,python-enum34)
2046 ("python-parse" ,python-parse)
2047 ("python-parse-type" ,python-parse-type)))
2048 (arguments `(#:tests? #f)) ;TODO: tests require nose>=1.3 and
2050 (home-page "http://github.com/behave/behave")
2051 (synopsis "Python behavior-driven development")
2053 "Behave is a tool for behavior-driven development in python.
2054 Behavior-driven development (or BDD) is an agile software development
2055 technique that encourages collaboration between developers, QA and
2056 non-technical or business participants in a software project. Behave uses
2057 tests written in a natural language style, backed up by Python code.")
2060 (define-public python-exif-read
2062 (name "python-exif-read")
2068 "https://pypi.python.org/packages/source/E/ExifRead/ExifRead-"
2072 "17c627gcdmyc05hz4zk8qs4pjgw6rc68qzjzgz8gh1cmpsd7acf1"))))
2073 (build-system python-build-system)
2075 `(("python-setuptools" ,python-setuptools)))
2076 (arguments `(#:tests? #f)) ; no tests
2077 (home-page "https://github.com/ianare/exif-py")
2078 (synopsis "Python library to extract EXIF data from image files")
2080 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
2084 (define-public python2-exif-read
2085 (package-with-python2 python-exif-read))
2087 (define-public python-pyld
2089 (name "python-pyld")
2095 "https://pypi.python.org/packages/source/P/PyLD/PyLD-"
2099 "1l9ymj85fsvayqplinzpk0kyiq6m74ps9xd3a9fhlxfn1rldf8x8"))))
2100 (build-system python-build-system)
2102 `(("python-setuptools" ,python-setuptools)))
2103 (arguments `(#:tests? #f)) ; no tests
2104 (home-page "http://github.com/digitalbazaar/pyld")
2105 (synopsis "Python implementation of the JSON-LD specification")
2107 "PyLD is an implementation of the JSON-LD specification.")
2110 (define-public python2-pyld
2111 (package-with-python2 python-pyld))
2113 (define-public python-certifi
2115 (name "python-certifi")
2116 (version "14.05.14")
2121 "https://pypi.python.org/packages/source/c/certifi/certifi-"
2125 "0s8vxzfz6s4m6fvxc7z25k9j35w0rh6jkw3wwcd1az1mssncn6qy"))))
2126 (build-system python-build-system)
2128 `(("python-setuptools" ,python-setuptools)))
2129 (arguments `(#:tests? #f)) ; no tests
2130 (home-page "http://python-requests.org/")
2131 (synopsis "Python CA certificate bundle")
2133 "Certifi is a Python library that contains a CA certificate bundle, which
2134 is used by the Requests library to verify HTTPS requests.")
2137 (define-public python2-certifi
2138 (package-with-python2 python-certifi))
2140 (define-public python-click
2142 (name "python-click")
2148 "https://pypi.python.org/packages/source/c/click/click-"
2151 (base32 "0294x9g28w6zgswl0rsygkwi0wf6n480gf7fiiw5f9az3xhh77pl"))))
2152 (build-system python-build-system)
2154 `(("python-setuptools" ,python-setuptools)))
2155 (home-page "http://click.pocoo.org")
2156 (synopsis "Command line library for Python")
2158 "Click is a Python package for creating command line interfaces in a
2159 composable way with as little code as necessary. Its name stands for
2160 \"Command Line Interface Creation Kit\". It's highly configurable but comes
2161 with sensible defaults out of the box.")
2164 (define-public python2-click
2165 (package-with-python2 python-click))
2167 (define-public python-wheel
2169 (name "python-wheel")
2174 (uri (pypi-uri "wheel" version))
2177 "032k1ajijbqnv0z0k88bhf75mdimi18fcmm28mss90610lw3bbga"))))
2178 (build-system python-build-system)
2180 `(("python-setuptools" ,python-setuptools)
2181 ("python-jsonschema" ,python-jsonschema)
2182 ("python-pytest-cov" ,python-pytest-cov)))
2183 (home-page "https://bitbucket.org/pypa/wheel/")
2184 (synopsis "Built-package format for Python")
2186 "A wheel is a ZIP-format archive with a specially formatted filename and the
2187 .whl extension. It is designed to contain all the files for a PEP 376
2188 compatible install in a way that is very close to the on-disk format.")
2189 (license license:expat)))
2191 (define-public python2-wheel
2192 (package-with-python2 python-wheel))
2194 (define-public python-requests
2196 (name "python-requests")
2200 (uri (pypi-uri "requests" version))
2203 "0ny2nr1sqr4hcn3903ghmh7w2yni8shlfv240a8c9p6wyidqvzl4"))))
2204 (build-system python-build-system)
2206 `(("python-setuptools" ,python-setuptools)))
2208 `(("python-py" ,python-py)
2209 ("python-pytest" ,python-pytest)
2210 ("python-pytest-cov" ,python-pytest-cov)
2211 ("python-wheel" ,python-wheel)))
2212 (home-page "http://python-requests.org/")
2213 (synopsis "Python HTTP library")
2215 "Requests is a Python HTTP client library. It aims to be easier to use
2216 than Python’s urllib2 library.")
2219 (define-public python2-requests
2220 (package-with-python2 python-requests))
2222 (define-public python-jsonschema
2224 (name "python-jsonschema")
2230 "https://pypi.python.org/packages/source/j/jsonschema/jsonschema-"
2234 "1yik3031ziygvq66rj3mzfqdgxj29sg1bkfc46wsgi7lnbqs560j"))))
2235 (build-system python-build-system)
2237 `(("python-setuptools" ,python-setuptools)))
2238 (home-page "http://github.com/Julian/jsonschema")
2239 (synopsis "Implementation of JSON Schema for Python")
2241 "Jsonschema is an implementation of JSON Schema for Python.")
2242 (license license:expat)))
2244 (define-public python2-jsonschema
2245 (package-with-python2 python-jsonschema))
2247 (define-public python-unidecode
2249 (name "python-unidecode")
2255 "https://pypi.python.org/packages/source/U/Unidecode/Unidecode-"
2259 "0yv56vc49rvippyxgxvcyz7jklc07ky38rcspax7p00sgmriiljc"))))
2260 (build-system python-build-system)
2262 `(("python-setuptools" ,python-setuptools)))
2263 (home-page "https://pypi.python.org/pypi/Unidecode")
2264 (synopsis "ASCII transliterations of Unicode text")
2266 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2267 useful when integrating with legacy code that doesn't support Unicode, or for
2268 ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2269 machine identifiers from human-readable Unicode strings that should still be
2270 somewhat intelligeble.")
2273 (define-public python2-unidecode
2274 (package-with-python2 python-unidecode))
2276 (define-public python-pyjwt
2278 (name "python-pyjwt")
2283 (uri (pypi-uri "PyJWT" version))
2286 "1556v2jppd8mjkkj66pxb5rcazm35jq81r233mdl8hfmz9n3icp1"))))
2287 (build-system python-build-system)
2289 `(("python-setuptools" ,python-setuptools)
2290 ("python-pytest-runner" ,python-pytest-runner)))
2292 '(#:tests? #f)) ; test suite doesn't work
2293 (home-page "http://github.com/progrium/pyjwt")
2294 (synopsis "JSON Web Token implementation in Python")
2296 "PyJWT is a JSON Web Token implementation written in Python.")
2297 (license license:expat)))
2299 (define-public python2-pyjwt
2300 (package-with-python2 python-pyjwt))
2302 (define-public python-oauthlib
2304 (name "python-oauthlib")
2308 (uri (pypi-uri "oauthlib" version))
2311 "1bfrj70vdjxjw74khbyh6f0dksv7p5rh2346jnlrffyacd3gwjzg"))))
2312 (build-system python-build-system)
2314 `(("python-setuptools" ,python-setuptools)
2315 ("python-coverage", python-coverage)
2316 ("python-nose" ,python-nose)
2317 ("python-mock" ,python-mock)))
2319 `(("python-blinker" ,python-blinker)
2320 ("python-cryptography" ,python-cryptography)
2321 ("python-pyjwt" ,python-pyjwt)))
2322 (home-page "https://github.com/idan/oauthlib")
2323 (synopsis "OAuth implementation for Python")
2325 "Oauthlib is a generic, spec-compliant, thorough implementation of the
2326 OAuth request-signing logic.")
2329 (define-public python2-oauthlib
2330 (let ((base (package-with-python2 python-oauthlib)))
2334 `(("python2-unittest2" ,python2-unittest2)
2335 ("python2-cryptography" ,python2-cryptography)
2336 ,@(alist-delete "python-cryptography"
2337 (package-inputs base)))))))
2339 (define-public python-itsdangerous
2341 (name "python-itsdangerous")
2347 "https://pypi.python.org/packages/source/i/itsdangerous/itsdangerous-"
2351 "06856q6x675ly542ig0plbqcyab6ksfzijlyf1hzhgg3sgwgrcyb"))))
2352 (build-system python-build-system)
2354 `(("python-setuptools" ,python-setuptools)))
2355 (home-page "http://github.com/mitsuhiko/itsdangerous")
2356 (synopsis "Python library for passing data to/from untrusted environments")
2358 "Itsdangerous provides various helpers to pass trusted data to untrusted
2359 environments and back.")
2362 (define-public python2-itsdangerous
2363 (package-with-python2 python-itsdangerous))
2365 (define-public python-pyyaml
2367 (name "python-pyyaml")
2373 "https://pypi.python.org/packages/source/P/PyYAML/PyYAML-"
2377 "1s26125vfnskng58ym37xhwv8v0mm95b2cwbjfag8prfhy596v63"))))
2378 (build-system python-build-system)
2380 `(("libyaml" ,libyaml)))
2382 `(("python-setuptools" ,python-setuptools)))
2383 (home-page "http://pyyaml.org/wiki/PyYAML")
2384 (synopsis "YAML parser and emitter for Python")
2386 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2387 complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2388 API, and sensible error messages. PyYAML supports standard YAML tags and
2389 provides Python-specific tags that allow to represent an arbitrary Python
2391 (license license:expat)))
2393 (define-public python2-pyyaml
2394 (package-with-python2 python-pyyaml))
2396 (define-public python-virtualenv
2398 (name "python-virtualenv")
2404 "https://pypi.python.org/packages/source/v/virtualenv/virtualenv-"
2408 "1xq4prmg25n9cz5zcvbqx68lmc3kl39by582vd8pzs9f3qalqyiy"))))
2409 (build-system python-build-system)
2411 `(("python-setuptools" ,python-setuptools)
2412 ("python-mock" ,python-mock)
2413 ("python-nose" ,python-nose)))
2414 (home-page "https://virtualenv.pypa.io/")
2415 (synopsis "Virtual Python environment builder")
2417 "Virtualenv is a tool to create isolated Python environments.")
2418 (license license:expat)))
2420 (define-public python2-virtualenv
2421 (package-with-python2 python-virtualenv))
2423 (define-public python-markupsafe
2425 (name "python-markupsafe")
2431 "https://pypi.python.org/packages/source/M/MarkupSafe/MarkupSafe-"
2435 "1hvip33wva3fnmvfp9x5klqri7hpl1hkgqmjbss18nmrb7zimv54"))))
2436 (build-system python-build-system)
2438 `(("python-setuptools" ,python-setuptools)))
2439 (home-page "http://github.com/mitsuhiko/markupsafe")
2440 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2442 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2446 (define-public python2-markupsafe
2447 (package-with-python2 python-markupsafe))
2449 (define-public python-jinja2
2451 (name "python-jinja2")
2457 "https://pypi.python.org/packages/source/J/Jinja2/Jinja2-"
2461 "1nwg9yfqgy421lncnm63k1zf9xkd1klc0jm0fr4p3dad01fsq91f"))))
2462 (build-system python-build-system)
2464 `(("python-setuptools" ,python-setuptools)
2465 ("python-markupsafe" ,python-markupsafe)))
2466 (home-page "http://jinja.pocoo.org/")
2467 (synopsis "Python template engine")
2469 "Jinja2 is a small but fast and easy to use stand-alone template engine
2470 written in pure Python.")
2473 (define-public python2-jinja2
2474 (package-with-python2 python-jinja2))
2476 (define-public python-pystache
2478 (name "python-pystache")
2482 (uri (pypi-uri "pystache" version))
2485 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2486 (build-system python-build-system)
2488 `(("python-setuptools" ,python-setuptools)))
2489 (home-page "http://defunkt.io/pystache/")
2490 (synopsis "Python logic-less template engine")
2492 "Pystache is a Python implementation of the framework agnostic,
2493 logic-free templating system Mustache.")
2494 (license license:expat)))
2496 (define-public python2-pystache
2497 (package-with-python2 python-pystache))
2499 (define-public python-joblib
2501 (name "python-joblib")
2505 (uri (string-append "https://pypi.python.org/packages/source/"
2506 "j/joblib/joblib-" version ".tar.gz"))
2509 "1dvw3f8jgj6h0fxkghbgyclvdzc7l0ig7n0vis70awb5kczb9bs3"))))
2510 (build-system python-build-system)
2512 `(("python-setuptools" ,python-setuptools)
2513 ("python-nose" ,python-nose)))
2514 (home-page "http://pythonhosted.org/joblib/")
2515 (synopsis "Using Python functions as pipeline jobs")
2517 "Joblib is a set of tools to provide lightweight pipelining in Python.
2518 In particular, joblib offers: transparent disk-caching of the output values
2519 and lazy re-evaluation (memoize pattern), easy simple parallel computing
2520 logging and tracing of the execution.")
2523 (define-public python2-joblib
2524 (package-with-python2 python-joblib))
2526 (define-public python-docutils
2528 (name "python-docutils")
2534 "https://pypi.python.org/packages/source/d/docutils/docutils-"
2538 "1ylnjnw1x4b2y7blr6x35ncdzn69k253kw4cdkv6asdb21w73ny7"))))
2539 (build-system python-build-system)
2541 `(("python-setuptools" ,python-setuptools)))
2543 '(#:tests? #f)) ; no setup.py test command
2544 (home-page "http://docutils.sourceforge.net/")
2545 (synopsis "Python Documentation Utilities")
2547 "Docutils is a modular system for processing documentation into useful
2548 formats, such as HTML, XML, and LaTeX. For input Docutils supports
2550 ;; Most of the source code is public domain, but some source files are
2551 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2552 (license (list public-domain psfl bsd-2 gpl3+))))
2554 (define-public python2-docutils
2555 (package-with-python2 python-docutils))
2557 (define-public python-pygments
2559 (name "python-pygments")
2565 "https://pypi.python.org/packages/source/P/Pygments/Pygments-"
2569 "1h11r6ss8waih51vcksfvzghfxiav2f8svc0812fa5kmyz5d97kr"))))
2570 (build-system python-build-system)
2572 `(("python-setuptools" ,python-setuptools)))
2573 (home-page "http://pygments.org/")
2574 (synopsis "Syntax highlighting")
2576 "Pygments is a syntax highlighting package written in Python.")
2579 (define-public python2-pygments
2580 (package-with-python2 python-pygments))
2582 (define-public python-sphinx
2584 (name "python-sphinx")
2590 "https://pypi.python.org/packages/source/S/Sphinx/Sphinx-"
2594 "011xizm3jnmf4cvs5i6kgf6c5nn046h79i8j0vd0f27yw9j3p4wl"))))
2595 (build-system python-build-system)
2597 `(("python-setuptools" ,python-setuptools)
2598 ("python-jinja2" ,python-jinja2)
2599 ("python-docutils" ,python-docutils)
2600 ("python-pygments" ,python-pygments)))
2601 (home-page "http://sphinx-doc.org/")
2602 (synopsis "Python documentation generator")
2603 (description "Sphinx is a tool that makes it easy to create documentation
2604 for Python projects or other documents consisting of multiple reStructuredText
2608 (define-public python2-sphinx
2609 (package-with-python2 python-sphinx))
2611 (define-public python-sphinx-rtd-theme
2613 (name "python-sphinx-rtd-theme")
2618 (uri (string-append "https://pypi.python.org/packages/source/s/"
2619 "sphinx_rtd_theme/sphinx_rtd_theme-"
2623 "19nw3rn7awplcdrz63kg1njqwkbymfg9lwn7l2grhdyhyr2gaa8g"))))
2624 (build-system python-build-system)
2626 `(;; With standard flags, the install phase attempts to create a zip'd
2627 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2629 #:configure-flags '("--single-version-externally-managed"
2630 "--record=sphinx-rtd-theme.txt")))
2632 `(("python-setuptools" ,python-setuptools)))
2634 `(("python-docutils" ,python-docutils)
2635 ("python-sphinx" ,python-sphinx)))
2636 (home-page "https://github.com/snide/sphinx_rtd_theme/")
2637 (synopsis "ReadTheDocs.org theme for Sphinx")
2638 (description "A theme for Sphinx used by ReadTheDocs.org.")
2639 (license license:expat)))
2641 (define-public python2-sphinx-rtd-theme
2642 (package-with-python2 python-sphinx-rtd-theme))
2644 (define-public python-feedgenerator
2646 (name "python-feedgenerator")
2647 (version "20150710.97185b7")
2649 ;; Using the git checkout for now because license file not added till
2650 ;; https://github.com/dmdm/feedgenerator-py3k/commit/97185b7566c240c4bf5ed80db7d6c271204dab39
2654 (url "https://github.com/dmdm/feedgenerator-py3k.git")
2655 (commit "97185b7566c240c4bf5ed80db7d6c271204dab39")))
2658 "0dbd6apij5j1923ib905x0srgcyls4wlabqlwp4dzkwmksvnrr2a"))))
2660 `(;; With standard flags, the install phase attempts to create a zip'd
2661 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2663 #:configure-flags '("--single-version-externally-managed"
2664 "--record=feedgenerator.txt")))
2665 (build-system python-build-system)
2667 `(("python-setuptools" ,python-setuptools)
2668 ("python-pytz" ,python-pytz)
2669 ("python-six" ,python-six)))
2671 "https://github.com/dmdm/feedgenerator-py3k.git")
2673 "Standalone version of Django's Atom/RSS feed generator")
2675 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2676 which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
2679 (define-public python2-feedgenerator
2680 (package-with-python2 python-feedgenerator))
2682 (define-public python-blinker
2684 (name "python-blinker")
2690 "https://pypi.python.org/packages/source/b/blinker/blinker-"
2694 "0bvfxkmjx6bpa302pv7v2vw5rwr3dlzjzfdp3bj628i6144024b8"))))
2695 (build-system python-build-system)
2697 `(("python-setuptools" ,python-setuptools)))
2698 ;; No "test" command supplied to setuptools, so unless there's another way
2699 ;; to run tests, we're skipping them!
2700 (arguments '(#:tests? #f))
2701 (home-page "http://pythonhosted.org/blinker/")
2702 (synopsis "Fast, simple object-to-object and broadcast signaling")
2704 "Blinker provides a fast dispatching system that allows any number of
2705 interested parties to subscribe to events, or \"signals\".")
2706 (license license:expat)))
2708 (define-public python2-blinker
2709 (package-with-python2 python-blinker))
2711 (define-public pelican
2719 "https://pypi.python.org/packages/source/p/pelican/pelican-"
2723 "0lbkk902mqxpp452pp76n6qcjv6f99lq2zl204xmqyzcan9zr3ps"))))
2724 (build-system python-build-system)
2726 `(("python-setuptools" ,python-setuptools)))
2728 `(("python-feedgenerator" ,python-feedgenerator)
2729 ("python-jinja2" ,python-jinja2)
2730 ("python-pygments" ,python-pygments)
2731 ("python-docutils" ,python-docutils)
2732 ("python-pytz" ,python-pytz)
2733 ("python-blinker" ,python-blinker)
2734 ("python-unidecode" ,python-unidecode)
2735 ("python-six" ,python-six)
2736 ("python-dateutil-2" ,python-dateutil-2)))
2737 (home-page "http://getpelican.com/")
2739 `(;; XXX Requires a lot more packages to do unit tests :P
2741 #:phases (modify-phases %standard-phases
2743 'install 'adjust-requires
2744 ;; Since feedgenerator is installed from git, it doesn't
2745 ;; conform to the version requirements.
2747 ;; We *do have* "feedgenerator >= 1.6", but strip off the
2748 ;; version requirement so setuptools doesn't get confused.
2750 (substitute* "setup.py"
2751 (("['\"]feedgenerator.*?['\"]")
2752 "'feedgenerator'")))))))
2753 (synopsis "Python-based static site publishing system")
2755 "Pelican is a tool to generate a static blog from reStructuredText,
2756 Markdown input files, and more. Pelican uses Jinja2 for templating
2757 and is very extensible.")
2760 (define-public python-scikit-learn
2762 (name "python-scikit-learn")
2768 "https://github.com/scikit-learn/scikit-learn/archive/"
2772 "140skabifgc7lvvj873pnzlwx0ni6q8qkrsyad2ccjb3h8rxzkih"))))
2773 (build-system python-build-system)
2778 ;; some tests require access to "$HOME"
2779 (lambda _ (setenv "HOME" "/tmp"))
2780 ;; Tests can only be run after the library has been installed and not
2781 ;; within the source directory.
2785 (with-directory-excursion "/tmp"
2786 ;; With Python 3 one test of 3334 fails
2787 ;; (sklearn.tests.test_common.test_transformers); see
2788 ;; https://github.com/scikit-learn/scikit-learn/issues/3693
2789 (system* "nosetests" "-v" "sklearn")))
2790 (alist-delete 'check %standard-phases)))))
2792 `(("openblas" ,openblas)
2793 ("python-nose" ,python-nose)))
2795 `(("python-numpy" ,python-numpy)
2796 ("python-scipy" ,python-scipy)))
2797 (home-page "http://scikit-learn.org/")
2798 (synopsis "Machine Learning in Python")
2800 "Scikit-learn provides simple and efficient tools for data
2801 mining and data analysis.")
2804 (define-public python2-scikit-learn
2805 (let ((scikit (package-with-python2 python-scikit-learn)))
2806 (package (inherit scikit)
2808 `(("python2-numpy" ,python2-numpy)
2809 ("python2-scipy" ,python2-scipy)
2813 "python-scipy" (package-propagated-inputs scikit))))))))
2815 (define-public python-scikit-image
2817 (name "python-scikit-image")
2823 "https://pypi.python.org/packages/source/s/scikit-image/scikit-image-"
2826 (base32 "0jz416fqvpahqyffw8plmszzfj669w8wvf3y9clnr5lr6a7md3kn"))))
2827 (build-system python-build-system)
2829 `(("python-matplotlib" ,python-matplotlib)
2830 ("python-networkx" ,python-networkx)
2831 ("python-numpy" ,python-numpy)
2832 ("python-scipy" ,python-scipy)
2833 ("python-six" ,python-six)
2834 ("python-pillow" ,python-pillow)))
2836 `(("python-cython" ,python-cython)
2837 ("python-setuptools" ,python-setuptools)))
2838 (home-page "http://scikit-image.org/")
2839 (synopsis "Image processing in Python")
2841 "Scikit-image is a collection of algorithms for image processing.")
2844 (define-public python2-scikit-image
2845 (let ((scikit-image (package-with-python2 python-scikit-image)))
2846 (package (inherit scikit-image)
2848 `(("python2-mock" ,python2-mock)
2849 ,@(package-native-inputs scikit-image)))
2851 `(("python2-pytz" ,python2-pytz)
2852 ("python2-matplotlib" ,python2-matplotlib)
2853 ("python2-numpy" ,python2-numpy)
2854 ("python2-scipy" ,python2-scipy)
2855 ,@(fold alist-delete (package-propagated-inputs scikit-image)
2856 '("python-matplotlib" "python-numpy" "python-scipy")))))))
2858 (define-public python-redis
2860 (name "python-redis")
2866 "https://pypi.python.org/packages/source/r/redis/redis-"
2869 (base32 "1701qjwn4n05q90fdg4bsg96s27xf5s4hsb4gxhv3xk052q3gyx4"))))
2870 (build-system python-build-system)
2871 ;; Tests require a running Redis server
2872 (arguments '(#:tests? #f))
2874 `(("python-setuptools" ,python-setuptools)
2875 ("python-pytest" ,python-pytest)))
2876 (home-page "https://github.com/andymccurdy/redis-py")
2877 (synopsis "Redis Python client")
2879 "This package provides a Python interface to the Redis key-value store.")
2880 (license license:expat)))
2882 (define-public python2-redis
2883 (package-with-python2 python-redis))
2885 (define-public python-rq
2893 "https://pypi.python.org/packages/source/r/rq/rq-"
2896 (base32 "0b0z5hn8wkfg300hx7816csgv3bcfamlr29fi3yzgqmpqxwj3fix"))))
2897 (build-system python-build-system)
2899 `(("python-click" ,python-click)
2900 ("python-redis" ,python-redis)))
2902 `(("python-setuptools" ,python-setuptools)))
2903 (home-page "http://python-rq.org/")
2904 (synopsis "Simple job queues for Python")
2906 "RQ (Redis Queue) is a simple Python library for queueing jobs and
2907 processing them in the background with workers. It is backed by Redis and it
2908 is designed to have a low barrier to entry.")
2911 (define-public python2-rq
2912 (package-with-python2 python-rq))
2914 (define-public python-cython
2916 (name "python-cython")
2921 (uri (string-append "http://cython.org/release/Cython-"
2925 "0ddz2l2dvcy5hdkxx4xlfiwpccvwia7ixgcy4h0pdv46a4i4vxj3"))))
2926 (build-system python-build-system)
2927 ;; we need the full python package and not just the python-wrapper
2928 ;; because we need libpython3.3m.so
2930 `(("python" ,python)))
2935 ;; some tests require access to "$HOME/.cython"
2936 (lambda* _ (setenv "HOME" "/tmp"))
2939 (lambda _ (zero? (system* "python" "runtests.py" "-vv")))
2940 %standard-phases))))
2941 (home-page "http://cython.org/")
2942 (synopsis "C extensions for Python")
2943 (description "Cython is an optimising static compiler for both the Python
2944 programming language and the extended Cython programming language. It makes
2945 writing C extensions for Python as easy as Python itself.")
2948 (define-public python2-cython
2949 (package (inherit (package-with-python2 python-cython))
2950 (name "python2-cython")
2952 `(("python-2" ,python-2))))) ; this is not automatically changed
2954 ;; This version of numpy is missing the documentation and is only used to
2955 ;; build matplotlib which is required to build numpy's documentation.
2956 (define python-numpy-bootstrap
2958 (name "python-numpy-bootstrap")
2963 (uri (string-append "mirror://sourceforge/numpy"
2964 "/numpy-" version ".tar.gz"))
2967 "070ybfvpgfmiz2hs94x445hvkh9dh52nyi0m8jp5kdihgvhbnx80"))))
2968 (build-system python-build-system)
2970 `(("python-nose" ,python-nose)
2971 ("openblas" ,openblas)
2972 ("lapack" ,lapack)))
2974 `(("gfortran" ,gfortran)))
2978 'build 'set-environment-variables
2979 (lambda* (#:key inputs #:allow-other-keys)
2980 (call-with-output-file "site.cfg"
2984 libraries = openblas
2985 library_dirs = ~a/lib
2986 include_dirs = ~a/include
2989 lapack_libs = lapack
2990 library_dirs = ~a/lib
2991 include_dirs = ~a/include
2993 (assoc-ref inputs "openblas")
2994 (assoc-ref inputs "openblas")
2995 (assoc-ref inputs "lapack")
2996 (assoc-ref inputs "lapack"))))
2997 ;; Use "gcc" executable, not "cc".
2998 (substitute* "numpy/distutils/system_info.py"
2999 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
3000 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3002 ;; Tests can only be run after the library has been installed and not
3003 ;; within the source directory.
3007 (with-directory-excursion "/tmp"
3008 (zero? (system* "python" "-c"
3009 "import numpy; numpy.test(verbose=2)"))))
3012 %standard-phases)))))
3013 (home-page "http://www.numpy.org/")
3014 (synopsis "Fundamental package for scientific computing with Python")
3015 (description "NumPy is the fundamental package for scientific computing
3016 with Python. It contains among other things: a powerful N-dimensional array
3017 object, sophisticated (broadcasting) functions, tools for integrating C/C++
3018 and Fortran code, useful linear algebra, Fourier transform, and random number
3022 (define python2-numpy-bootstrap
3023 (package-with-python2 python-numpy-bootstrap))
3025 (define-public python2-fastlmm
3027 (name "python2-fastlmm")
3033 "https://pypi.python.org/packages/source/f/fastlmm"
3034 "/fastlmm-" version ".zip"))
3037 "023sydkrc3yxad2bycar02jfswwlh4199kafzhf2bssyx2c3xa0l"))))
3038 (build-system python-build-system)
3040 `(#:python ,python-2)) ; only Python 2.7 is supported
3042 `(("python2-numpy" ,python2-numpy)
3043 ("python2-scipy" ,python2-scipy)
3044 ("python2-matplotlib" ,python2-matplotlib)
3045 ("python2-pandas" ,python2-pandas)
3046 ("python2-scikit-learn" ,python2-scikit-learn)
3047 ("python2-cython" ,python2-cython)
3048 ("python2-pysnptools" ,python2-pysnptools)))
3051 ("python2-mock" ,python2-mock)
3052 ("python2-setuptools" ,python2-setuptools)))
3053 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/fastlmm/")
3054 (synopsis "Perform genome-wide association studies on large data sets")
3056 "FaST-LMM, which stands for Factored Spectrally Transformed Linear Mixed
3057 Models, is a program for performing both single-SNP and SNP-set genome-wide
3058 association studies (GWAS) on extremely large data sets.")
3061 (define-public python-numpy
3062 (package (inherit python-numpy-bootstrap)
3063 (name "python-numpy")
3064 (outputs '("out" "doc"))
3067 ("python-setuptools" ,python-setuptools)
3068 ("python-matplotlib" ,python-matplotlib)
3069 ("python-sphinx" ,python-sphinx)
3070 ("python-pyparsing" ,python-pyparsing)
3071 ("python-numpydoc" ,python-numpydoc)
3072 ,@(package-inputs python-numpy-bootstrap)))
3074 `(("pkg-config" ,pkg-config)
3075 ("texlive" ,texlive)
3076 ("texinfo" ,texinfo)
3078 ,@(package-native-inputs python-numpy-bootstrap)))
3080 `(,@(substitute-keyword-arguments
3081 (package-arguments python-numpy-bootstrap)
3084 'install 'install-doc
3085 (lambda* (#:key outputs #:allow-other-keys)
3086 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3088 data "/doc/" ,name "-"
3089 ,(package-version python-numpy-bootstrap)))
3090 (info (string-append data "/info"))
3091 (html (string-append doc "/html"))
3092 (pyver ,(string-append "PYVER=")))
3093 (with-directory-excursion "doc"
3095 (system* "make" "html" pyver)
3096 (system* "make" "latex" "PAPER=a4" pyver)
3097 (system* "make" "-C" "build/latex"
3098 "all-pdf" "PAPER=a4" pyver)
3099 ;; FIXME: Generation of the info file fails.
3100 ;; (system* "make" "info" pyver)
3102 ;; (copy-file "build/texinfo/numpy.info"
3103 ;; (string-append info "/numpy.info"))
3104 (for-each (lambda (file)
3105 (copy-file (string-append "build/latex" file)
3106 (string-append doc file)))
3107 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3108 (with-directory-excursion "build/html"
3109 (for-each (lambda (file)
3110 (let* ((dir (dirname file))
3111 (tgt-dir (string-append html "/" dir)))
3112 (unless (equal? "." dir)
3114 (install-file file html)))
3115 (find-files "." ".*"))))))
3118 (define-public python2-numpy
3119 (let ((numpy (package-with-python2 python-numpy)))
3120 (package (inherit numpy)
3121 ;; Make sure we use exactly PYTHON2-MATPLOTLIB, which is customized for
3123 (inputs `(("python2-matplotlib" ,python2-matplotlib)
3124 ,@(alist-delete "python-matplotlib"
3125 (package-inputs numpy)))))))
3127 (define-public python-pyparsing
3129 (name "python-pyparsing")
3134 (uri (string-append "mirror://sourceforge/pyparsing"
3135 "/pyparsing-" version ".tar.gz"))
3138 "0kw4py7gn45j93q8r7bzajfrjdc3xlsn2yzln41lf9zmrghjkrq6"))))
3139 (build-system python-build-system)
3140 (outputs '("out" "doc"))
3142 `(#:tests? #f ; no test target
3143 #:modules ((guix build python-build-system)
3147 'install 'install-doc
3148 (lambda* (#:key outputs #:allow-other-keys)
3149 (let* ((doc (string-append (assoc-ref outputs "doc")
3150 "/share/doc/" ,name "-" ,version))
3151 (html-doc (string-append doc "/html"))
3152 (examples (string-append doc "/examples")))
3158 (install-file file tgt))
3159 (find-files dir ".*")))
3160 (list "docs" "htmldoc" "examples")
3161 (list doc html-doc examples))))
3163 (home-page "http://pyparsing.wikispaces.com")
3164 (synopsis "Python parsing class library")
3166 "The pyparsing module is an alternative approach to creating and
3167 executing simple grammars, vs. the traditional lex/yacc approach, or the use
3168 of regular expressions. The pyparsing module provides a library of classes
3169 that client code uses to construct the grammar directly in Python code.")
3170 (license license:expat)))
3172 (define-public python2-pyparsing
3173 (package-with-python2 python-pyparsing))
3175 (define-public python-numpydoc
3177 (name "python-numpydoc")
3183 "https://pypi.python.org/packages/source/n/numpydoc/numpydoc-"
3187 "0d4dnifaxkll50jx6czj05y8cb4ny60njd2wz299sj2jxfy51w4k"))
3188 (modules '((guix build utils)))
3191 ;; Drop a test requiring matplotlib, which we cannot add as an
3192 ;; input since it would create a circular dependency: Extend the
3193 ;; test for Python 3, where it is already dropped, to Python 2.
3194 (substitute* "numpydoc/tests/test_plot_directive.py"
3196 (build-system python-build-system)
3198 `(("python-setuptools" ,python-setuptools)
3199 ("python-docutils" ,python-docutils)
3200 ("python-sphinx" ,python-sphinx)
3201 ("python-nose" ,python-nose)))
3202 (home-page "https://pypi.python.org/pypi/numpydoc")
3204 "Numpy's Sphinx extensions")
3206 "Sphinx extension to support docstrings in Numpy format.")
3209 (define-public python2-numpydoc
3210 (package-with-python2 python-numpydoc))
3212 (define-public python-numexpr
3214 (name "python-numexpr")
3219 (uri (string-append "https://pypi.python.org/packages/source/"
3220 "n/numexpr/numexpr-" version ".tar.gz"))
3223 "0nsnff5312fm38w6dm34bw7ghfqqy8vl9gig0al963h4mz8zm8nz"))))
3224 (build-system python-build-system)
3225 (arguments `(#:tests? #f)) ; no tests included
3227 `(("python-numpy" ,python-numpy)))
3228 (home-page "https://github.com/pydata/numexpr")
3229 (synopsis "Fast numerical expression evaluator for NumPy")
3231 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3232 expressions that operate on arrays are accelerated and use less memory than
3233 doing the same calculation in Python. In addition, its multi-threaded
3234 capabilities can make use of all your cores, which may accelerate
3235 computations, most specially if they are not memory-bounded (e.g. those using
3236 transcendental functions).")
3237 (license license:expat)))
3239 (define-public python2-numexpr
3240 (let ((numexpr (package-with-python2 python-numexpr)))
3241 (package (inherit numexpr)
3242 ;; Make sure to use special packages for Python 2 instead
3243 ;; of those automatically rewritten by package-with-python2.
3245 `(("python2-numpy" ,python2-numpy)
3246 ,@(alist-delete "python-numpy"
3247 (package-propagated-inputs numexpr)))))))
3249 (define-public python-matplotlib
3251 (name "python-matplotlib")
3256 (uri (string-append "mirror://sourceforge/matplotlib"
3257 "/matplotlib-" version ".tar.gz"))
3260 "1dn05cvd0g984lzhh72wa0z93psgwshbbg93fkab6slx5m3l95av"))
3261 (patches (list (search-patch "matplotlib-setupext-tk.patch")))))
3262 (build-system python-build-system)
3263 (outputs '("out" "doc"))
3264 (propagated-inputs ; the following packages are all needed at run time
3265 `(("python-pyparsing" ,python-pyparsing)
3266 ("python-pygobject" ,python-pygobject)
3267 ("gobject-introspection" ,gobject-introspection)
3268 ("python-tkinter" ,python "tk")
3269 ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated
3270 ;; from 'gtk+') provides the required 'typelib' files used by
3271 ;; 'gobject-introspection'. The location of these files is set with the
3272 ;; help of the environment variable GI_TYPELIB_PATH. At build time this
3273 ;; is done automatically by a 'native-search-path' procedure. However,
3274 ;; at run-time the user must set this variable as follows:
3276 ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0
3278 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3279 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3280 ;; object. For this reason we need to import both libraries.
3281 ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo
3282 ("python-pycairo" ,python-pycairo)
3283 ("python-cairocffi" ,python-cairocffi)))
3285 `(("python-setuptools" ,python-setuptools)
3286 ("python-dateutil" ,python-dateutil-2)
3287 ("python-six" ,python-six)
3288 ("python-pytz" ,python-pytz)
3289 ("python-numpy" ,python-numpy-bootstrap)
3290 ("python-sphinx" ,python-sphinx)
3291 ("python-numpydoc" ,python-numpydoc)
3292 ("python-nose" ,python-nose)
3293 ("python-mock" ,python-mock)
3295 ("imagemagick" ,imagemagick)
3296 ("freetype" ,freetype)
3299 ("python-pillow" ,python-pillow)
3300 ;; FIXME: Add backends when available.
3301 ;("python-wxpython" ,python-wxpython)
3302 ;("python-pyqt" ,python-pyqt)
3306 `(("pkg-config" ,pkg-config)
3307 ("texlive" ,texlive)
3308 ("texinfo" ,texinfo)))
3312 'build 'configure-environment
3313 (lambda* (#:key outputs inputs #:allow-other-keys)
3314 (let ((cairo (assoc-ref inputs "cairo"))
3315 (gtk+ (assoc-ref inputs "gtk+")))
3316 ;; Setting these directories in the 'basedirlist' of 'setup.cfg'
3318 (setenv "LD_LIBRARY_PATH"
3319 (string-append cairo "/lib:" gtk+ "/lib"))
3320 (setenv "HOME" (getcwd))
3321 (call-with-output-file "setup.cfg"
3323 (format port "[directories]~%
3324 basedirlist = ~a,~a~%
3327 (assoc-ref inputs "tcl")
3328 (assoc-ref inputs "tk"))))))
3330 'install 'install-doc
3331 (lambda* (#:key outputs #:allow-other-keys)
3332 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3333 (doc (string-append data "/doc/" ,name "-" ,version))
3334 (info (string-append data "/info"))
3335 (html (string-append doc "/html")))
3336 (with-directory-excursion "doc"
3337 ;; Produce pdf in 'A4' format.
3338 (substitute* (find-files "." "conf\\.py")
3339 (("latex_paper_size = 'letter'")
3340 "latex_paper_size = 'a4'"))
3343 ;; The doc recommends to run the 'html' target twice.
3344 (system* "python" "make.py" "html")
3345 (system* "python" "make.py" "html")
3346 (copy-recursively "build/html" html)
3347 (system* "python" "make.py" "latex")
3348 (system* "python" "make.py" "texinfo")
3349 (symlink (string-append html "/_images")
3350 (string-append info "/matplotlib-figures"))
3351 (with-directory-excursion "build/texinfo"
3352 (substitute* "matplotlib.texi"
3353 (("@image\\{([^,]*)" all file)
3354 (string-append "@image{matplotlib-figures/" file)))
3355 (symlink (string-append html "/_images")
3356 "./matplotlib-figures")
3357 (system* "makeinfo" "--no-split"
3358 "-o" "matplotlib.info" "matplotlib.texi"))
3359 (copy-file "build/texinfo/matplotlib.info"
3360 (string-append info "/matplotlib.info"))
3361 (copy-file "build/latex/Matplotlib.pdf"
3362 (string-append doc "/Matplotlib.pdf")))))
3363 %standard-phases))))
3364 (home-page "http://matplotlib.org")
3365 (synopsis "2D plotting library for Python")
3367 "Matplotlib is a Python 2D plotting library which produces publication
3368 quality figures in a variety of hardcopy formats and interactive environments
3369 across platforms. Matplotlib can be used in Python scripts, the python and
3370 ipython shell, web application servers, and six graphical user interface
3374 (define-public python2-matplotlib
3375 (let ((matplotlib (package-with-python2 python-matplotlib)))
3376 (package (inherit matplotlib)
3377 ;; Make sure to use special packages for Python 2 instead
3378 ;; of those automatically rewritten by package-with-python2.
3380 `(("python2-pycairo" ,python2-pycairo)
3381 ("python2-pygobject-2" ,python2-pygobject-2)
3382 ("python2-tkinter" ,python-2 "tk")
3383 ,@(fold alist-delete (package-propagated-inputs matplotlib)
3384 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
3386 (define-public python2-pysnptools
3388 (name "python2-pysnptools")
3394 "https://pypi.python.org/packages/source/p/pysnptools"
3395 "/pysnptools-" version ".zip"))
3398 "1rzf5qvwfvd2pp84b14pb2gdvxdk5avnj7rb41ac8gndpkr9g6ib"))))
3399 (build-system python-build-system)
3401 `(#:python ,python-2)) ; only Python 2.7 is supported
3403 `(("python2-numpy" ,python2-numpy)
3404 ("python2-scipy" ,python2-scipy)
3405 ("python2-pandas" ,python2-pandas)
3406 ("python2-cython" ,python2-cython)))
3409 ("python2-setuptools" ,python2-setuptools)))
3410 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/")
3411 (synopsis "Library for reading and manipulating genetic data")
3413 "PySnpTools is a library for reading and manipulating genetic data. It
3414 can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
3415 those files. It can also efficiently manipulate ranges of integers using set
3416 operators such as union, intersection, and difference.")
3419 (define-public python-rpy2
3421 (name "python-rpy2")
3426 (uri (string-append "https://pypi.python.org/packages/source/r/rpy2"
3427 "/rpy2-" version ".tar.gz"))
3430 "1dp4l8hpv0jpf4crz4wis6in3lvwk86cr5zvpw410y4a07rrbqjk"))))
3431 (build-system python-build-system)
3433 `(("python-six" ,python-six)
3434 ("readline" ,readline)
3439 `(("python-setuptools" ,python-setuptools)
3441 (home-page "http://rpy.sourceforge.net/")
3442 (synopsis "Python interface to the R language")
3443 (description "rpy2 is a redesign and rewrite of rpy. It is providing a
3444 low-level interface to R from Python, a proposed high-level interface,
3445 including wrappers to graphical libraries, as well as R-like structures and
3449 (define-public python2-rpy2
3450 (let ((rpy2 (package-with-python2 python-rpy2)))
3451 (package (inherit rpy2)
3453 `(("python2-singledispatch" ,python2-singledispatch)
3454 ,@(package-native-inputs rpy2))))))
3456 (define-public python-scipy
3458 (name "python-scipy")
3463 (uri (string-append "mirror://sourceforge/scipy"
3464 "/scipy-" version ".tar.xz"))
3467 "0wa0a4skpda3gx7lb12yn19nhbairlyxrvda2lz2bcawk3x5qzz2"))))
3468 (build-system python-build-system)
3470 `(("python-numpy" ,python-numpy)
3471 ("python-matplotlib" ,python-matplotlib)
3472 ("python-pyparsing" ,python-pyparsing)))
3474 `(("lapack" ,lapack)
3475 ("openblas" ,openblas)))
3477 `(("python-nose" ,python-nose)
3478 ("python-sphinx" ,python-sphinx)
3479 ("python-numpydoc" ,python-numpydoc)
3480 ("gfortran" ,gfortran)
3481 ("texlive" ,texlive)
3483 (outputs '("out" "doc"))
3487 'build 'configure-openblas
3488 (lambda* (#:key inputs #:allow-other-keys)
3489 (call-with-output-file "site.cfg"
3493 libraries = openblas
3494 library_dirs = ~a/lib
3495 include_dirs = ~a/include
3497 library_dirs = ~a/lib
3498 atlas_libs = openblas
3500 (assoc-ref inputs "openblas")
3501 (assoc-ref inputs "openblas")
3502 (assoc-ref inputs "openblas"))))
3505 'install 'install-doc
3506 (lambda* (#:key outputs #:allow-other-keys)
3507 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3508 (doc (string-append data "/doc/" ,name "-" ,version))
3509 (html (string-append doc "/html"))
3510 (pyver ,(string-append "PYVER=")))
3511 (with-directory-excursion "doc"
3512 ;; Fix generation of images for mathematical expressions.
3513 (substitute* (find-files "source" "conf\\.py")
3514 (("pngmath_use_preview = True")
3515 "pngmath_use_preview = False"))
3517 (system* "make" "html" pyver)
3518 (system* "make" "latex" "PAPER=a4" pyver)
3519 (system* "make" "-C" "build/latex" "all-pdf" "PAPER=a4" pyver)
3520 (copy-file "build/latex/scipy-ref.pdf"
3521 (string-append doc "/scipy-ref.pdf"))
3522 (with-directory-excursion "build/html"
3523 (for-each (lambda (file)
3524 (let* ((dir (dirname file))
3525 (tgt-dir (string-append html "/" dir)))
3526 (install-file file html)))
3527 (find-files "." ".*"))))))
3528 ;; Tests can only be run after the library has been installed and not
3529 ;; within the source directory.
3533 (with-directory-excursion "/tmp"
3534 (zero? (system* "python" "-c" "import scipy; scipy.test()"))))
3540 (substitute* "scipy/integrate/tests/test_quadpack.py"
3541 (("libm.so") "libm.so.6"))
3543 %standard-phases)))))))
3544 (home-page "http://www.scipy.org/")
3545 (synopsis "The Scipy library provides efficient numerical routines")
3546 (description "The SciPy library is one of the core packages that make up
3547 the SciPy stack. It provides many user-friendly and efficient numerical
3548 routines such as routines for numerical integration and optimization.")
3551 (define-public python2-scipy
3552 (let ((scipy (package-with-python2 python-scipy)))
3553 (package (inherit scipy)
3554 ;; Use packages customized for python-2.
3556 `(("python2-matplotlib" ,python2-matplotlib)
3557 ("python2-numpy" ,python2-numpy)
3558 ,@(alist-delete "python-matplotlib"
3559 (alist-delete "python-numpy"
3560 (package-propagated-inputs scipy))))))))
3562 (define-public python-sqlalchemy
3564 (name "python-sqlalchemy")
3569 (uri (string-append "https://pypi.python.org/packages/source/S/"
3570 "SQLAlchemy/SQLAlchemy-" version ".tar.gz"))
3573 "059ayifj5l08v6vv56anhyibyllscn10dlzr2fcw68gz1hfjdzsz"))))
3574 (build-system python-build-system)
3576 `(("python-cython" ,python-cython) ;for c extensions
3577 ("python-pytest" ,python-pytest)
3578 ("python-mock" ,python-mock))) ;for tests
3580 `(#:phases (alist-replace
3582 (lambda _ (zero? (system* "py.test")))
3584 (home-page "http://www.sqlalchemy.org")
3585 (synopsis "Database abstraction library")
3587 "SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that
3588 gives application developers the full power and flexibility of SQL. It
3589 provides a full suite of well known enterprise-level persistence patterns,
3590 designed for efficient and high-performing database access, adapted into a
3591 simple and Pythonic domain language.")
3594 (define-public python2-sqlalchemy
3595 (package-with-python2 python-sqlalchemy))
3597 (define-public python-distutils-extra
3599 (name "python-distutils-extra")
3604 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
3605 version "/+download/python-distutils-extra-"
3609 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
3610 (build-system python-build-system)
3612 `(("python-setuptools" ,python-setuptools)))
3613 (home-page "https://launchpad.net/python-distutils-extra/")
3614 (synopsis "Enhancements to Python's distutils")
3616 "The python-distutils-extra module enables you to easily integrate
3617 gettext support, themed icons, and scrollkeeper-based documentation into
3618 Python's distutils.")
3621 (define-public python2-distutils-extra
3622 (package-with-python2 python-distutils-extra))
3624 (define-public python2-elib.intl
3626 (name "python2-elib.intl")
3630 ;; This project doesn't tag releases or publish tarballs, so we take
3631 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
3634 (url "https://github.com/dieterv/elib.intl.git")
3635 (commit "d09997cfef")))
3638 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
3639 (build-system python-build-system)
3641 `(("python2-setuptools" ,python2-setuptools)))
3643 ;; incompatible with Python 3 (exception syntax)
3644 `(#:python ,python-2
3646 ;; With standard flags, the install phase attempts to create a zip'd
3647 ;; egg file, and fails with an error: 'ZIP does not support timestamps
3649 #:configure-flags '("--single-version-externally-managed"
3650 "--record=elib.txt")))
3651 (home-page "https://github.com/dieterv/elib.intl")
3652 (synopsis "Enhanced internationalization for Python")
3654 "The elib.intl module provides enhanced internationalization (I18N)
3655 services for your Python modules and applications.")
3658 (define-public python-pillow
3660 (name "python-pillow")
3665 (uri (string-append "https://pypi.python.org/packages/source/P/"
3666 "Pillow/Pillow-" version ".tar.gz"))
3669 "1fsl6sywd4f4axvbpy5h5h26l6w8592j0f1wcnj1hmgy83svwl5d"))))
3670 (build-system python-build-system)
3672 `(("python-setuptools" ,python-setuptools)
3673 ("python-nose" ,python-nose)))
3675 `(("freetype" ,freetype)
3678 ("libjpeg" ,libjpeg)
3679 ("openjpeg" ,openjpeg)
3680 ("libtiff" ,libtiff)
3681 ("libwebp" ,libwebp)))
3683 `(;; Used at runtime for pkg_resources
3684 ("python-setuptools" ,python-setuptools)))
3686 `(#:phases (modify-phases %standard-phases
3688 'install 'disable-egg-compression
3690 ;; Leave the .egg uncompressed since compressing it would
3691 ;; prevent the GC from identifying run-time dependencies.
3692 ;; See <http://bugs.gnu.org/20765>.
3693 (let ((port (open-file "setup.cfg" "a")))
3694 (display "\n[easy_install]\nzip_ok = 0\n"
3699 'install 'check-installed
3702 (setenv "HOME" (getcwd))
3703 (and (zero? (system* "python" "selftest.py"
3705 (zero? (system* "python" "test-installed.py"))))))
3707 (home-page "https://pypi.python.org/pypi/Pillow")
3708 (synopsis "Fork of the Python Imaging Library")
3710 "The Python Imaging Library adds image processing capabilities to your
3711 Python interpreter. This library provides extensive file format support, an
3712 efficient internal representation, and fairly powerful image processing
3713 capabilities. The core image library is designed for fast access to data
3714 stored in a few basic pixel formats. It should provide a solid foundation for
3715 a general image processing tool.")
3717 "http://www.pythonware.com/products/pil/license.htm"
3718 "The PIL Software License"))))
3720 (define-public python2-pillow
3721 (package-with-python2 python-pillow))
3723 (define-public python-pycparser
3725 (name "python-pycparser")
3730 (uri (string-append "https://pypi.python.org/packages/source/p/"
3731 "pycparser/pycparser-" version ".tar.gz"))
3734 "0v5qfq03yvd1pi0dwlgfai0p3dh9bq94pydn19c4pdn0c6v9hzcm"))))
3735 (outputs '("out" "doc"))
3736 (build-system python-build-system)
3738 `(("pkg-config" ,pkg-config)
3739 ("python-setuptools" ,python-setuptools)))
3745 (with-directory-excursion "tests"
3746 (zero? (system* "python" "all_tests.py"))))
3748 'install 'install-doc
3749 (lambda* (#:key outputs #:allow-other-keys)
3750 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3751 (doc (string-append data "/doc/" ,name "-" ,version))
3752 (examples (string-append doc "/examples")))
3754 (for-each (lambda (file)
3755 (copy-file (string-append "." file)
3756 (string-append doc file)))
3757 '("/README.rst" "/CHANGES" "/LICENSE"))
3758 (copy-recursively "examples" examples)))
3759 %standard-phases))))
3760 (home-page "https://github.com/eliben/pycparser")
3761 (synopsis "C parser in Python")
3763 "Pycparser is a complete parser of the C language, written in pure Python
3764 using the PLY parsing library. It parses C code into an AST and can serve as
3765 a front-end for C compilers or analysis tools.")
3768 (define-public python2-pycparser
3769 (package-with-python2 python-pycparser))
3771 (define-public python-cffi
3773 (name "python-cffi")
3778 (uri (string-append "https://pypi.python.org/packages/source/c/"
3779 "cffi/cffi-" version ".tar.gz"))
3781 (base32 "0g8yfzinry1vsj6d1jlnd19338bh92lhhk207ksy4lm1n3g73dga"))))
3782 (build-system python-build-system)
3783 (outputs '("out" "doc"))
3785 `(("libffi" ,libffi)))
3786 (propagated-inputs ; required at run-time
3787 `(("python-pycparser" ,python-pycparser)))
3789 `(("pkg-config" ,pkg-config)
3790 ("python-sphinx" ,python-sphinx)
3791 ("python-pytest" ,python-pytest)
3792 ("python-setuptools" ,python-setuptools)))
3796 'install 'install-doc
3797 (lambda* (#:key outputs #:allow-other-keys)
3798 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3799 (doc (string-append data "/doc/" ,name "-" ,version))
3800 (html (string-append doc "/html")))
3801 (with-directory-excursion "doc"
3802 (system* "make" "html")
3804 (copy-recursively "build/html" html))
3805 (copy-file "LICENSE" (string-append doc "/LICENSE"))))
3807 (home-page "http://cffi.readthedocs.org")
3808 (synopsis "Foreign function interface for Python")
3810 "Foreign Function Interface for Python calling C code.")
3811 (license license:expat)))
3813 (define-public python2-cffi
3814 (package-with-python2 python-cffi))
3816 (define-public python-xcffib
3818 (name "python-xcffib")
3823 (uri (string-append "https://pypi.python.org/packages/source/x/"
3824 "xcffib/xcffib-" version ".tar.gz"))
3827 "0655hzxv57h1a9ja9kwp0ichbkhf3djw32k33d66xp0q37dq2y81"))))
3828 (build-system python-build-system)
3830 `(("libxcb" ,libxcb)
3831 ("python-six" ,python-six)))
3833 `(("python-setuptools" ,python-setuptools)))
3835 `(("python-cffi" ,python-cffi))) ; used at run time
3839 'install 'install-doc
3840 (lambda* (#:key outputs #:allow-other-keys)
3841 (let ((doc (string-append (assoc-ref outputs "out") "/share"
3842 "/doc/" ,name "-" ,version)))
3844 (copy-file "README.md"
3845 (string-append doc "/README.md"))))
3847 (home-page "https://github.com/tych0/xcffib")
3848 (synopsis "XCB Python bindings")
3850 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
3851 support for Python 3 and PyPy. It is based on cffi.")
3852 (license license:expat)))
3854 (define-public python2-xcffib
3855 (package-with-python2 python-xcffib))
3857 (define-public python-cairocffi
3859 (name "python-cairocffi")
3864 ;; The archive on pypi is missing the 'utils' directory!
3865 (uri (string-append "https://github.com/SimonSapin/cairocffi/archive/v"
3867 (file-name (string-append name "-" version ".tar.gz"))
3870 "03w5p62sp3nqiccx864sbq0jvh7946277jqx3rcc3dch5xwfvv51"))))
3871 (build-system python-build-system)
3872 (outputs '("out" "doc"))
3874 `(("gdk-pixbuf" ,gdk-pixbuf)
3877 `(("pkg-config" ,pkg-config)
3878 ("python-sphinx" ,python-sphinx)
3879 ("python-docutils" ,python-docutils)
3880 ("python-setuptools" ,python-setuptools)))
3882 `(("python-xcffib" ,python-xcffib))) ; used at run time
3886 'install 'install-doc
3887 (lambda* (#:key inputs outputs #:allow-other-keys)
3888 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3889 (doc (string-append data "/doc/" ,name "-" ,version))
3890 (html (string-append doc "/html")))
3891 (setenv "LD_LIBRARY_PATH"
3892 (string-append (assoc-ref inputs "cairo") "/lib" ":"
3893 (assoc-ref inputs "gdk-pixbuf") "/lib"))
3894 (setenv "LANG" "en_US.UTF-8")
3896 (for-each (lambda (file)
3897 (copy-file (string-append "." file)
3898 (string-append doc file)))
3899 '("/README.rst" "/CHANGES" "/LICENSE"))
3900 (system* "python" "setup.py" "build_sphinx")
3901 (copy-recursively "docs/_build/html" html)))
3903 (home-page "https://github.com/SimonSapin/cairocffi")
3904 (synopsis "Python bindings and object-oriented API for Cairo")
3906 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
3907 Python bindings and object-oriented API for cairo. Cairo is a 2D vector
3908 graphics library with support for multiple backends including image buffers,
3909 PNG, PostScript, PDF, and SVG file output.")
3912 (define-public python2-cairocffi
3913 (package-with-python2 python-cairocffi))
3915 (define-public python-decorator
3917 (name "python-decorator")
3923 "https://pypi.python.org/packages/source/d/decorator/decorator-"
3926 (base32 "0i2bnlkh0p9gs76hb28mafandcrig2fmv56w9ai6mshxwqn0083k"))))
3927 (build-system python-build-system)
3928 (arguments '(#:tests? #f)) ; no test target
3930 `(("python-setuptools" ,python-setuptools)))
3931 (home-page "http://pypi.python.org/pypi/decorator/")
3932 (synopsis "Python module to simplify usage of decorators")
3934 "The aim of the decorator module is to simplify the usage of decorators
3935 for the average programmer, and to popularize decorators usage giving examples
3936 of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
3937 etc. The core of this module is a decorator factory.")
3938 (license license:expat)))
3940 (define-public python2-decorator
3941 (package-with-python2 python-decorator))
3943 (define-public python-drmaa
3945 (name "python-drmaa")
3951 "https://pypi.python.org/packages/source/d/drmaa/drmaa-"
3954 (base32 "0bzl9f9g34dlhwf09i3fdv7dqqzf2iq0w7d6c2bafx1nlap8qfbh"))))
3955 (build-system python-build-system)
3956 ;; The test suite requires libdrmaa which is provided by the cluster
3957 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
3958 ;; should be set to the path of the libdrmaa library.
3959 (arguments '(#:tests? #f))
3961 `(("python-nose" ,python-nose)
3962 ("python-setuptools" ,python-setuptools)))
3963 (home-page "https://pypi.python.org/pypi/drmaa")
3964 (synopsis "Python bindings for the DRMAA library")
3966 "A Python package for Distributed Resource Management (DRM) job
3967 submission and control. This package is an implementation of the DRMAA 1.0
3968 Python language binding specification.")
3971 (define-public python2-drmaa
3972 (package-with-python2 python-drmaa))
3974 (define-public python-gridmap
3976 (name "python-gridmap")
3982 "https://github.com/pygridtools/gridmap/archive/v"
3984 (file-name (string-append name "-" version ".tar.gz"))
3986 (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x"))))
3987 (build-system python-build-system)
3989 `(("python-psutil" ,python-psutil)
3990 ("python-drmaa" ,python-drmaa)
3991 ("python-pyzmq" ,python-pyzmq)))
3993 `(("python-setuptools" ,python-setuptools)))
3994 (home-page "https://github.com/pygridtools/gridmap")
3995 (synopsis "Create jobs on a cluster directly from Python")
3997 "Gridmap is a Python package to allow you to easily create jobs on the
3998 cluster directly from Python. You can directly map Python functions onto the
3999 cluster without needing to write any wrapper code yourself.")
4002 (define-public python2-gridmap
4003 (package-with-python2 python-gridmap))
4005 (define-public python-pexpect
4007 (name "python-pexpect")
4012 (uri (string-append "https://pypi.python.org/packages/source/p/"
4013 "pexpect/pexpect-" version ".tar.gz"))
4015 (base32 "1fp5gm976z7ghm8jw57463rj19cv06c8zw842prgyg788f6n3snz"))))
4016 (build-system python-build-system)
4019 (modify-phases %standard-phases
4020 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4022 `(("python-nose" ,python-nose)))
4023 (home-page "http://pexpect.readthedocs.org/")
4024 (synopsis "Controlling interactive console applications")
4026 "Pexpect is a pure Python module for spawning child applications;
4027 controlling them; and responding to expected patterns in their output.
4028 Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4029 child application and control it as if a human were typing commands.")
4032 (define-public python2-pexpect
4033 (package-with-python2 python-pexpect))
4035 (define-public python-setuptools-scm
4037 (name "python-setuptools-scm")
4041 (uri (pypi-uri "setuptools_scm" version))
4044 "0y24bl893zk6nrklbvdrlmpkalf214zjn6k1xrglljd29rrn4wxi"))))
4045 (build-system python-build-system)
4046 (native-inputs `(("python-setuptools" ,python-setuptools)))
4047 (home-page "https://github.com/pypa/setuptools_scm/")
4048 (synopsis "Manage Python package versions in SCM metadata")
4050 "Setuptools_scm handles managing your Python package versions in
4051 @dfn{software configuration management} (SCM) metadata instead of declaring
4052 them as the version argument or in a SCM managed file.")
4053 (license license:expat)))
4055 (define-public python2-setuptools-scm
4056 (package-with-python2 python-setuptools-scm))
4058 (define-public python-pathpy
4060 (name "python-pathpy")
4065 (uri (string-append "https://pypi.python.org/packages/source/p/"
4066 "path.py/path.py-" version ".tar.gz"))
4068 (base32 "1p8s1l2vfkqhqxdhqlj0g1jjw4f1as2frr35sjcpjjpd5a89y41f"))))
4069 (build-system python-build-system)
4071 `(("python-appdirs" ,python-appdirs)))
4073 `(("python-setuptools" ,python-setuptools)
4074 ("python-setuptools-scm" ,python-setuptools-scm)
4075 ("python-pytest" ,python-pytest)
4076 ("python-pytest-runner" ,python-pytest-runner)))
4077 (home-page "http://github.com/jaraco/path.py")
4078 (synopsis "Python module wrapper for built-in os.path")
4080 "@code{path.py} implements path objects as first-class entities, allowing
4081 common operations on files to be invoked on those path objects directly.")
4082 (license license:expat)))
4084 (define-public python2-pathpy
4085 (package-with-python2 python-pathpy))
4087 (define-public python-pickleshare
4089 (name "python-pickleshare")
4094 (uri (string-append "https://pypi.python.org/packages/source/p/"
4095 "pickleshare/pickleshare-" version ".tar.gz"))
4097 (base32 "11ljr90j3p6qswdrbl7p4cjb2i93f6vn0vx9anzpshsx0d2mggn0"))))
4098 (build-system python-build-system)
4100 `(("python-pathpy" ,python-pathpy)))
4102 `(("python-setuptools" ,python-setuptools)))
4103 (home-page "https://github.com/vivainio/pickleshare")
4104 (synopsis "Tiny key value database with concurrency support")
4106 "PickleShare is a small ‘shelve’-like datastore with concurrency support.
4107 Like shelve, a PickleShareDB object acts like a normal dictionary. Unlike
4108 shelve, many processes can access the database simultaneously. Changing a
4109 value in database is immediately visible to other processes accessing the same
4110 database. Concurrency is possible because the values are stored in separate
4111 files. Hence the “database” is a directory where all files are governed by
4113 (license license:expat)))
4115 (define-public python2-pickleshare
4116 (package-with-python2 python-pickleshare))
4118 (define-public python-simplegeneric
4120 (name "python-simplegeneric")
4125 (uri (string-append "https://pypi.python.org/packages/source/s/"
4126 "simplegeneric/simplegeneric-" version ".zip"))
4128 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
4129 (build-system python-build-system)
4131 `(("python-setuptools" ,python-setuptools)
4133 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
4134 (synopsis "Python module for simple generic functions")
4136 "The simplegeneric module lets you define simple single-dispatch generic
4137 functions, akin to Python’s built-in generic functions like @code{len()},
4138 @code{iter()} and so on. However, instead of using specially-named methods,
4139 these generic functions use simple lookup tables, akin to those used by
4140 e.g. @code{pickle.dump()} and other generic functions found in the Python
4144 (define-public python2-simplegeneric
4145 (package-with-python2 python-simplegeneric))
4147 (define-public python-ipython-genutils
4149 (name "python-ipython-genutils")
4154 (uri (string-append "https://pypi.python.org/packages/source/i/"
4155 "ipython_genutils/ipython_genutils-"
4158 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
4159 (build-system python-build-system)
4160 (arguments `(#:tests? #f)) ; no tests
4161 (home-page "http://ipython.org")
4162 (synopsis "Vestigial utilities from IPython")
4164 "This package provides retired utilities from IPython.")
4167 (define-public python2-ipython-genutils
4168 (package-with-python2 python-ipython-genutils))
4170 (define-public python-traitlets
4172 (name "python-traitlets")
4177 (uri (string-append "https://pypi.python.org/packages/source/t/"
4178 "traitlets/traitlets-" version ".tar.gz"))
4181 "0fr3w2xwb46c591dp7zw02bgf4d21mjy9g6rhwc9bwd4ji50n50b"))))
4182 (build-system python-build-system)
4185 (modify-phases %standard-phases
4186 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4188 `(("python-ipython-genutils" ,python-ipython-genutils)
4189 ("python-decorator" ,python-decorator)))
4191 `(("python-nose" ,python-nose)))
4192 (home-page "http://ipython.org")
4193 (synopsis "Configuration system for Python applications")
4195 "Traitlets is a framework that lets Python classes have attributes with
4196 type checking, dynamically calculated default values, and ‘on change’
4197 callbacks. The package also includes a mechanism to use traitlets for
4198 configuration, loading values from files or from command line arguments. This
4199 is a distinct layer on top of traitlets, so you can use traitlets in your code
4200 without using the configuration machinery.")
4203 (define-public python2-traitlets
4204 (package-with-python2 python-traitlets))
4206 (define-public python-ipython
4208 (name "python-ipython")
4213 (uri (string-append "https://pypi.python.org/packages/source/i/"
4214 "ipython/ipython-" version ".tar.gz"))
4216 (base32 "0xwin0sa9n0cabx4cq1ibf5ldsiw5dyimibla82kicz5gbpas4y9"))))
4217 (build-system python-build-system)
4218 (outputs '("out" "doc"))
4220 `(("python-pyzmq" ,python-pyzmq)
4221 ("python-terminado" ,python-terminado)))
4223 `(("readline" ,readline)
4225 ("python-matplotlib" ,python-matplotlib)
4226 ("python-numpy" ,python-numpy)
4227 ("python-numpydoc" ,python-numpydoc)
4228 ("python-jinja2" ,python-jinja2)
4229 ("python-mistune" ,python-mistune)
4230 ("python-jsonschema" ,python-jsonschema)
4231 ("python-pygments" ,python-pygments)
4232 ("python-requests" ,python-requests) ;; for tests
4233 ("python-nose" ,python-nose)))
4235 `(("pkg-config" ,pkg-config)
4236 ("python-sphinx" ,python-sphinx)
4237 ("texlive" ,texlive)
4238 ("texinfo" ,texinfo)
4239 ("python-setuptools" ,python-setuptools)))
4242 (modify-phases %standard-phases
4244 'install 'install-doc
4245 (lambda* (#:key inputs outputs #:allow-other-keys)
4246 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4247 (doc (string-append data "/doc/" ,name "-" ,version))
4248 (html (string-append doc "/html"))
4249 (man1 (string-append data "/man/man1"))
4250 (info (string-append data "/info"))
4251 (examples (string-append doc "/examples")))
4252 (setenv "LANG" "en_US.utf8")
4253 (with-directory-excursion "docs"
4254 ;; FIXME: html and pdf fail to build
4255 ;; (system* "make" "html")
4256 ;; (system* "make" "pdf" "PAPER=a4")
4257 (system* "make" "info"))
4258 (copy-recursively "docs/man" man1)
4259 (copy-recursively "examples" examples)
4260 ;; (copy-recursively "docs/build/html" html)
4261 ;; (copy-file "docs/build/latex/ipython.pdf"
4262 ;; (string-append doc "/ipython.pdf"))
4264 (copy-file "docs/build/texinfo/ipython.info"
4265 (string-append info "/ipython.info"))
4266 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))
4267 ;; Tests can only be run after the library has been installed and not
4268 ;; within the source directory.
4272 (lambda* (#:key outputs tests? #:allow-other-keys)
4274 (with-directory-excursion "/tmp"
4275 (setenv "HOME" "/tmp/") ;; required by a test
4276 (zero? (system* (string-append (assoc-ref outputs "out")
4281 (lambda* (#:key inputs #:allow-other-keys)
4282 (substitute* "./IPython/utils/_process_posix.py"
4283 (("/usr/bin/env', 'which") (which "which")))
4284 (substitute* "./IPython/core/tests/test_inputtransformer.py"
4285 (("#!/usr/bin/env python")
4286 (string-append "#!" (which "python"))))
4287 ;; Disable 1 failing test
4288 (substitute* "./IPython/core/tests/test_magic.py"
4289 (("def test_dirops\\(\\):" all)
4290 (string-append "@dec.skipif(True)\n" all))))))))
4291 (home-page "http://ipython.org")
4292 (synopsis "IPython is a tool for interactive computing in Python")
4294 "IPython provides a rich architecture for interactive computing with:
4295 Powerful interactive shells, a browser-based notebook, support for interactive
4296 data visualization, embeddable interpreters and tools for parallel
4300 (define-public python2-ipython
4301 (let ((ipython (package-with-python2 python-ipython)))
4304 ;; FIXME: some tests are failing
4306 `(#:tests? #f ,@(package-arguments ipython)))
4307 ;; Make sure we use custom python2-NAME packages.
4308 ;; FIXME: add pyreadline once available.
4310 `(("python2-terminado" ,python2-terminado)
4311 ,@(alist-delete "python-terminado"
4312 (package-propagated-inputs ipython))))
4314 `(("python2-mock" ,python2-mock)
4315 ("python2-matplotlib" ,python2-matplotlib)
4316 ("python2-numpy" ,python2-numpy)
4317 ,@(fold alist-delete (package-inputs ipython)
4318 '("python-matplotlib" "python-numpy")))))))
4320 (define-public python-isodate
4322 (name "python-isodate")
4328 "https://pypi.python.org/packages/source/i/isodate/isodate-"
4333 "1yqjn0is0p64cmk9xhq4hc6q06jk86d60kg2jws58d78q0qysami"))))
4334 (build-system python-build-system)
4336 `(("python-setuptools" ,python-setuptools)))
4338 "http://cheeseshop.python.org/pypi/isodate")
4340 "Python date parser and formatter")
4342 "Python-isodate is a python module for parsing and formatting
4343 ISO 8601 dates, time and duration.")
4346 (define-public python2-isodate
4347 (package-with-python2 python-isodate))
4349 (define-public python-html5lib
4351 (name "python-html5lib")
4357 "https://pypi.python.org/packages/source/h/html5lib/html5lib-"
4362 "1l5i6xzckzx4hnh9qzv9q3kyhkgjx2hsi2k9srgci3qizjmvp6ln"))))
4363 (build-system python-build-system)
4365 `(("python-six" ,python-six))) ; required to "import html5lib"
4367 `(("python-setuptools" ,python-setuptools)))
4369 `(#:test-target "check"))
4371 "https://github.com/html5lib/html5lib-python")
4373 "Python HTML parser based on the WHATWG HTML specifcation")
4375 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
4376 and written in Python.")
4377 (license license:expat)))
4379 (define-public python2-html5lib
4380 (package-with-python2 python-html5lib))
4382 (define-public python-urwid
4384 (name "python-urwid")
4390 "https://pypi.python.org/packages/source/u/urwid/urwid-"
4394 "18mb0yy94sjc434rd61m2sfnw27sa0nyrszpj5a9r9zh7fnlzw19"))))
4395 (build-system python-build-system)
4396 (native-inputs `(("python-setuptools" ,python-setuptools)))
4397 (home-page "http://urwid.org")
4398 (synopsis "Console user interface library for Python")
4400 "Urwid is a curses-based UI/widget library for Python. It includes many
4401 features useful for text console applications.")
4402 (license lgpl2.1+)))
4404 (define-public python2-urwid
4405 (package-with-python2 python-urwid))
4407 (define-public python-dbus
4409 (name "python-dbus")
4415 "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-"
4418 (base32 "1py62qir966lvdkngg0v8k1khsqxwk5m4s8nflpk1agk5f5nqb71"))))
4419 (build-system gnu-build-system)
4422 (modify-phases %standard-phases
4426 ;; XXX: For the missing '/etc/machine-id'.
4427 (substitute* "test/run-test.sh"
4428 (("DBUS_FATAL_WARNINGS=1")
4429 "DBUS_FATAL_WARNINGS=0"))
4432 `(("pkg-config" ,pkg-config)))
4434 `(("python" ,python)
4435 ("dbus-glib" ,dbus-glib)))
4436 (synopsis "Python bindings for D-bus")
4437 (description "python-dbus provides bindings for libdbus, the reference
4438 implementation of D-Bus.")
4439 (home-page "http://www.freedesktop.org/wiki/Software/DBusBindings/")
4440 (license license:expat)))
4442 (define-public python2-dbus
4443 (package (inherit python-dbus)
4444 (name "python2-dbus")
4445 (inputs `(("python" ,python-2)
4446 ,@(alist-delete "python"
4447 (package-inputs python-dbus)
4449 ;; FIXME: on Python 2, the test_utf8 fails with:
4450 ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)"
4451 (arguments `(#:tests? #f))))
4453 (define-public python-apsw
4455 (name "python-apsw")
4456 (version "3.8.7.3-r1")
4461 "https://pypi.python.org/packages/source/a/apsw/apsw-"
4466 "1rgxdypg7hym0qny15rx5khrghx9fkppfgsfa2s8lg917924mv7l"))))
4467 (build-system python-build-system)
4469 `(("python-setuptools" ,python-setuptools)
4470 ("sqlite" ,sqlite)))
4473 ;; swap check and install phases
4476 (assoc-ref %standard-phases 'check)
4479 %standard-phases))))
4480 (home-page "https://github.com/rogerbinns/apsw/")
4481 (synopsis "Another Python SQLite Wrapper")
4482 (description "APSW is a Python wrapper for the SQLite
4483 embedded relational database engine. In contrast to other wrappers such as
4484 pysqlite it focuses on being a minimal layer over SQLite attempting just to
4485 translate the complete SQLite API into Python.")
4486 (license license:zlib)))
4488 (define-public python2-apsw
4489 (package-with-python2 python-apsw))
4491 (define-public python-lxml
4493 (name "python-lxml")
4499 "https://pypi.python.org/packages/source/l/lxml/lxml-"
4504 "0pd23qz8vms1mgm41p96h4vac5y91igs4wr9640gnvxgk019kmf7"))))
4505 (build-system python-build-system)
4507 `(("libxml2" ,libxml2)
4508 ("libxslt" ,libxslt)
4509 ("python-setuptools" ,python-setuptools)))
4510 (home-page "http://lxml.de/")
4512 "Python XML processing library")
4514 "The lxml XML toolkit is a Pythonic binding for the C libraries
4515 libxml2 and libxslt.")
4516 (license bsd-3))) ; and a few more, see LICENSES.txt
4518 (define-public python2-lxml
4519 (package-with-python2 python-lxml))
4521 (define-public python2-pil
4523 (name "python2-pil")
4529 "http://effbot.org/downloads/Imaging-"
4533 "04aj80jhfbmxqzvmq40zfi4z3cw6vi01m3wkk6diz3lc971cfnw9"))
4534 (modules '((guix build utils)))
4536 ;; Adapt to newer freetype. As the package is unmaintained upstream,
4537 ;; there is no use in creating a patch and reporting it.
4538 '(substitute* "_imagingft.c"
4541 (build-system python-build-system)
4543 `(("freetype" ,freetype)
4544 ("libjpeg" ,libjpeg)
4545 ("libtiff" ,libtiff)
4546 ("python-setuptools" ,python-setuptools)
4549 ;; Only the fork python-pillow works with Python 3.
4550 `(#:python ,python-2
4551 #:tests? #f ; no check target
4555 ;; According to README and setup.py, manual configuration is
4556 ;; the preferred way of "searching" for inputs.
4557 ;; lcms is not found, TCL_ROOT refers to the unavailable tkinter.
4558 (lambda* (#:key inputs #:allow-other-keys)
4559 (let ((jpeg (assoc-ref inputs "libjpeg"))
4560 (zlib (assoc-ref inputs "zlib"))
4561 (tiff (assoc-ref inputs "libtiff"))
4562 (freetype (assoc-ref inputs "freetype")))
4563 (substitute* "setup.py"
4564 (("JPEG_ROOT = None")
4565 (string-append "JPEG_ROOT = libinclude(\"" jpeg "\")"))
4566 (("ZLIB_ROOT = None")
4567 (string-append "ZLIB_ROOT = libinclude(\"" zlib "\")"))
4568 (("TIFF_ROOT = None")
4569 (string-append "TIFF_ROOT = libinclude(\"" tiff "\")"))
4570 (("FREETYPE_ROOT = None")
4571 (string-append "FREETYPE_ROOT = libinclude(\""
4574 (home-page "http://www.pythonware.com/products/pil/")
4575 (synopsis "Python Imaging Library")
4576 (description "The Python Imaging Library (PIL) adds image processing
4577 capabilities to the Python interpreter.")
4580 "See 'README' in the distribution."))))
4582 (define-public python2-cssutils
4584 (name "python2-cssutils")
4590 "https://pypi.python.org/packages/source/c/cssutils/cssutils-"
4595 "1bwim1353r4hqiir73sn4sc43y7ymh09qx0kly7vj048blppc125"))))
4596 (build-system python-build-system)
4598 `(("python2-mock" ,python2-mock) ; for the tests
4599 ("unzip" ,unzip))) ; for unpacking the source
4601 `(("python2-setuptools" ,python2-setuptools)))
4603 `(#:python ,python-2 ; Otherwise tests fail with a syntax error.
4604 #:tests? #f ; The tests apparently download an external URL.
4606 (home-page "http://cthedot.de/cssutils/")
4608 "CSS Cascading Style Sheets library for Python")
4610 "Cssutils is a Python package for parsing and building CSS
4611 Cascading Style Sheets. Currently it provides a DOM only and no rendering
4615 (define-public python-cssselect
4617 (name "python-cssselect")
4623 "https://pypi.python.org/packages/source/c/cssselect/cssselect-"
4628 "10h623qnp6dp1191jri7lvgmnd4yfkl36k9smqklp1qlf3iafd85"))))
4629 (build-system python-build-system)
4631 `(("python-setuptools" ,python-setuptools)))
4633 ;; tests fail with message
4634 ;; AttributeError: 'module' object has no attribute 'tests'
4637 "https://pythonhosted.org/cssselect/")
4639 "CSS3 selector parser and translator to XPath 1.0")
4641 "Cssselect ia a Python module that parses CSS3 Selectors and translates
4642 them to XPath 1.0 expressions. Such expressions can be used in lxml or
4643 another XPath engine to find the matching elements in an XML or HTML document.")
4646 (define-public python2-cssselect
4647 (package-with-python2 python-cssselect))
4649 (define-public python-netifaces
4651 (name "python-netifaces")
4657 "https://pypi.python.org/packages/source/n/netifaces/netifaces-"
4662 "1plw237a4zib4z8s62g0mrs8gm3kjfrp5sxh6bbk9nl3rdls2mln"))))
4663 (build-system python-build-system)
4665 `(("python-setuptools" ,python-setuptools)))
4667 "https://bitbucket.org/al45tair/netifaces")
4669 "Python module for portable network interface information")
4671 "Netifaces is a Python module providing information on network
4672 interfaces in an easy and portable manner.")
4673 (license license:expat)))
4675 (define-public python2-netifaces
4676 (package-with-python2 python-netifaces))
4678 (define-public python-networkx
4680 (name "python-networkx")
4686 "https://pypi.python.org/packages/source/n/networkx/networkx-"
4689 (base32 "0n8wy0yq1kmdq4wh68mlhwhkndvwzx48lg41a1z0sxxms0wfp033"))))
4690 (build-system python-build-system)
4691 ;; python-decorator is needed at runtime
4693 `(("python-decorator" ,python-decorator)))
4695 `(("python-setuptools" ,python-setuptools)
4696 ("python-nose" ,python-nose)))
4697 (home-page "http://networkx.github.io/")
4698 (synopsis "Python module for creating and manipulating graphs and networks")
4700 "NetworkX is a Python package for the creation, manipulation, and study
4701 of the structure, dynamics, and functions of complex networks.")
4704 (define-public python2-networkx
4705 (package-with-python2 python-networkx))
4707 (define-public snakemake
4715 "https://pypi.python.org/packages/source/s/snakemake/snakemake-"
4718 (base32 "0fi4b63sj60hvi7rfydvmz2icl4wj74djw5sn2gl8hxd02qw4b91"))))
4719 (build-system python-build-system)
4720 (inputs `(("python-setuptools" ,python-setuptools)))
4721 (home-page "https://bitbucket.org/johanneskoester/snakemake")
4722 (synopsis "Python-based execution environment for make-like workflows")
4724 "Snakemake aims to reduce the complexity of creating workflows by
4725 providing a clean and modern domain specific specification language (DSL) in
4726 Python style, together with a fast and comfortable execution environment.")
4727 (license license:expat)))
4729 (define-public python-seaborn
4731 (name "python-seaborn")
4737 "https://pypi.python.org/packages/source/s/seaborn/seaborn-"
4740 (base32 "1236abw18ijjglmv60q85ckqrvgf5qyy4zlq7nz5aqfg6q87z3wc"))))
4741 (build-system python-build-system)
4743 `(("python-pandas" ,python-pandas)
4744 ("python-matplotlib" ,python-matplotlib)
4745 ("python-scipy" ,python-scipy)))
4747 `(("python-setuptools" ,python-setuptools)))
4748 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
4749 (synopsis "Statistical data visualization")
4751 "Seaborn is a library for making attractive and informative statistical
4752 graphics in Python. It is built on top of matplotlib and tightly integrated
4753 with the PyData stack, including support for numpy and pandas data structures
4754 and statistical routines from scipy and statsmodels.")
4757 (define-public python2-seaborn
4758 (let ((seaborn (package-with-python2 python-seaborn)))
4759 (package (inherit seaborn)
4761 `(("python2-pytz" ,python2-pytz)
4762 ("python2-pandas" ,python2-pandas)
4763 ("python2-matplotlib" ,python2-matplotlib)
4764 ("python2-scipy" ,python2-scipy))))))
4766 (define-public python-sympy
4768 (name "python-sympy")
4774 "https://github.com/sympy/sympy/releases/download/sympy-"
4775 version "/sympy-" version ".tar.gz"))
4777 (base32 "19yp0gy4i7p4g6l3b8vaqkj9qj7yqb5kqy0qgbdagpzgkdz958yz"))))
4778 (build-system python-build-system)
4780 `(("python-setuptools" ,python-setuptools)))
4781 (home-page "http://www.sympy.org/")
4782 (synopsis "Python library for symbolic mathematics")
4784 "SymPy is a Python library for symbolic mathematics. It aims to become a
4785 full-featured computer algebra system (CAS) while keeping the code as simple
4786 as possible in order to be comprehensible and easily extensible.")
4789 (define-public python2-sympy
4790 (package-with-python2 python-sympy))
4792 (define-public python-testlib
4794 (name "python-testlib")
4800 "https://pypi.python.org/packages/source/t/testlib/testlib-"
4803 (base32 "1mz26cxn4x8bbgv0rn0mvj2z05y31rkc8009nvdlb3lam5b4mj3y"))))
4804 (build-system python-build-system)
4806 `(("python-setuptools" ,python-setuptools)))
4808 `(("unzip" ,unzip)))
4813 (lambda* (#:key inputs outputs #:allow-other-keys)
4814 (let ((unzip (string-append (assoc-ref inputs "unzip")
4816 (source (assoc-ref inputs "source")))
4817 (and (zero? (system* unzip source))
4818 (chdir (string-append "testlib-" ,version)))))
4820 (synopsis "Python micro test suite harness")
4821 (description "A micro unittest suite harness for Python.")
4822 (home-page "https://github.com/trentm/testlib")
4823 (license license:expat)))
4825 (define-public python2-testlib
4826 (package-with-python2 python-testlib))
4828 (define-public python2-xlib
4830 (name "python2-xlib")
4834 (uri (string-append "mirror://sourceforge/python-xlib/"
4835 "python-xlib-" version ".tar.gz"))
4838 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
4839 (build-system python-build-system)
4841 `(#:python ,python-2 ;Python 2 only
4842 #:tests? #f)) ;no tests
4844 `(("python-setuptools" ,python-setuptools)))
4845 (home-page "http://python-xlib.sourceforge.net/")
4846 (synopsis "Python X11 client library")
4848 "The Python X Library is intended to be a fully functional X client
4849 library for Python programs. It is useful to implement low-level X clients.
4850 It is written entirely in Python.")
4853 (define-public python-singledispatch
4855 (name "python-singledispatch")
4861 "https://pypi.python.org/packages/source/s/singledispatch/"
4862 "singledispatch-" version ".tar.gz"))
4865 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
4866 (build-system python-build-system)
4868 `(("python-setuptools" ,python-setuptools)))
4870 `(("python-six" ,python-six)))
4872 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
4873 (synopsis "Backport of singledispatch feature from Python 3.4")
4875 "This library brings functools.singledispatch from Python 3.4 to Python
4877 (license license:expat)))
4879 (define-public python2-singledispatch
4880 (package-with-python2 python-singledispatch))
4882 (define-public python-tornado
4884 (name "python-tornado")
4890 "https://pypi.python.org/packages/source/t/tornado/"
4891 "tornado-" version ".tar.gz"))
4893 (base32 "0a12f00h277zbifibnj46wf14801f573irvf6hwkgja5vspd7awr"))))
4894 (build-system python-build-system)
4896 `(("python-certifi" ,python-certifi)))
4898 `(("python-setuptools" ,python-setuptools)))
4899 (home-page "http://www.tornadoweb.org/")
4900 (synopsis "Python web framework and asynchronous networking library")
4902 "Tornado is a Python web framework and asynchronous networking library,
4903 originally developed at FriendFeed. By using non-blocking network I/O,
4904 Tornado can scale to tens of thousands of open connections, making it ideal
4905 for long polling, WebSockets, and other applications that require a long-lived
4906 connection to each user.")
4909 (define-public python2-tornado
4910 (let ((tornado (package-with-python2 python-tornado)))
4911 (package (inherit tornado)
4913 `(("python2-backport-ssl-match-hostname"
4914 ,python2-backport-ssl-match-hostname)
4915 ,@(package-inputs tornado))))))
4917 (define-public python-waf
4923 (uri (string-append "https://waf.io/"
4924 "waf-" version ".tar.bz2"))
4927 "0b5q307fgn6a5d8yjia2d1l4bk1q3ilvc0w8k4isfrrx2gbcw8wn"))))
4928 (build-system python-build-system)
4931 (modify-phases %standard-phases
4935 (system* "python" "waf-light" "configure")
4936 (system* "python" "waf-light" "build")))))
4939 (zero? (system* "python" "waf" "--version"))))
4942 (copy-file "waf" %output))))))
4943 (home-page "https://waf.io/")
4944 (synopsis "Python-based build system")
4946 "Waf is a Python-based framework for configuring, compiling and installing
4950 (define-public python2-waf
4951 (package-with-python2 python-waf))
4953 (define-public python-pyzmq
4955 (name "python-pyzmq")
4961 "https://pypi.python.org/packages/source/p/pyzmq/pyzmq-"
4964 (base32 "1frmbjykvhmdg64g7sn20c9fpamrsfxwci1nhhg8q7jgz5pq0ikp"))))
4965 (build-system python-build-system)
4968 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
4969 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
4970 ;; --inplace' for 'python setup.py test' to work.
4973 `(("zeromq" ,zeromq)))
4975 `(("pkg-config" ,pkg-config)
4976 ("python-nose" ,python-nose)
4977 ("python-setuptools" ,python-setuptools)))
4978 (home-page "http://github.com/zeromq/pyzmq")
4979 (synopsis "Python bindings for 0MQ")
4981 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
4984 (define-public python2-pyzmq
4985 (package-with-python2 python-pyzmq))
4987 (define-public python-pep8
4989 (name "python-pep8")
4995 "https://pypi.python.org/packages/source/p/pep8/pep8-"
5000 "1zybkcdw1sx84dvkfss96nhykqg9bc0cdpwpl4k9wlxm61bf7dxq"))))
5001 (build-system python-build-system)
5003 `(("python-setuptools" ,python-setuptools)))
5004 (home-page "http://pep8.readthedocs.org/")
5005 (synopsis "Python style guide checker")
5007 "This tools checks Python code against some of the style conventions in
5009 (license license:expat)))
5011 (define-public python2-pep8
5012 (package-with-python2 python-pep8))
5014 (define-public python-pyflakes
5016 (name "python-pyflakes")
5022 "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-"
5027 "0pvawddspdq0y22dbraq5gld9qr6rwa7zhmpfhl2b7v9rqiiqs82"))))
5028 (build-system python-build-system)
5030 `(("python-setuptools" ,python-setuptools)))
5032 "https://github.com/pyflakes/pyflakes")
5033 (synopsis "Passive checker of Python programs")
5035 "Pyflakes statically checks Python source code for common errors.")
5036 (license license:expat)))
5038 (define-public python2-pyflakes
5039 (package-with-python2 python-pyflakes))
5041 (define-public python-mccabe
5043 (name "python-mccabe")
5049 "https://pypi.python.org/packages/source/m/mccabe/mccabe-"
5054 "05ix3vdv5hjk4irl97n2n3c4g1vqvz7dbmkzs13f3bx97bxsczjz"))))
5055 (build-system python-build-system)
5057 `(("python-setuptools" ,python-setuptools)))
5058 (home-page "https://github.com/flintwork/mccabe")
5059 (synopsis "McCabe checker, plugin for flake8")
5061 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
5062 complexity of Python source code.")
5063 (license license:expat)))
5065 (define-public python2-mccabe
5066 (package-with-python2 python-mccabe))
5068 (define-public python-mccabe-0.2.1
5069 (package (inherit python-mccabe)
5074 (uri (pypi-uri "mccabe" version))
5077 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))))
5079 (define-public python2-mccabe-0.2.1
5080 (package-with-python2 python-mccabe-0.2.1))
5082 ;; Flake8 2.4.1 requires an older version of pep8.
5083 ;; This should be removed ASAP.
5084 (define-public python-pep8-1.5.7
5085 (package (inherit python-pep8)
5091 "https://pypi.python.org/packages/source/p/pep8/pep8-"
5096 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))))
5098 (define-public python2-pep8-1.5.7
5099 (package-with-python2 python-pep8-1.5.7))
5101 ;; Flake8 2.4.1 requires an older version of pyflakes.
5102 ;; This should be removed ASAP.
5103 (define-public python-pyflakes-0.8.1
5104 (package (inherit python-pyflakes)
5110 "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-"
5115 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))))
5117 (define-public python2-pyflakes-0.8.1
5118 (package-with-python2 python-pyflakes-0.8.1))
5120 (define-public python-flake8
5122 (name "python-flake8")
5128 "https://pypi.python.org/packages/source/f/flake8/flake8-"
5133 "0dvmrpv7x98xkzffjz1z7lqr90sp5zdz16bdwckfd1cckpjvnzif"))))
5134 (build-system python-build-system)
5136 `(("python-setuptools" ,python-setuptools)
5137 ("python-pep8" ,python-pep8-1.5.7)
5138 ("python-pyflakes" ,python-pyflakes-0.8.1)
5139 ("python-mccabe" ,python-mccabe)
5140 ("python-mock" ,python-mock)
5141 ("python-nose" ,python-nose)))
5142 (home-page "https://gitlab.com/pycqa/flake8")
5144 "The modular source code checker: pep8, pyflakes and co")
5146 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
5147 (license license:expat)))
5149 (define-public python2-flake8
5150 (package-with-python2 python-flake8))
5152 ;; This will only be needed by the python-hacking package and will not be
5153 ;; necessary once python-hacking > 0.10.2 is released.
5154 (define-public python-flake8-2.2.4
5155 (package (inherit python-flake8)
5157 `(("python-setuptools" ,python-setuptools)
5158 ("python-pep8" ,python-pep8-1.5.7)
5159 ("python-pyflakes" ,python-pyflakes-0.8.1)
5160 ("python-mccabe" ,python-mccabe-0.2.1)
5161 ("python-mock" ,python-mock)
5162 ("python-nose" ,python-nose)))
5167 (uri (pypi-uri "flake8" version))
5170 "1r9wsry4va45h1rck5hxd3vzsg2q3y6lnl6pym1bxvz8ry19jwx8"))))))
5172 (define-public python2-flake8-2.2.4
5173 (package-with-python2 python-flake8-2.2.4))
5175 (define-public python-mistune
5177 (name "python-mistune")
5183 "https://pypi.python.org/packages/source/m/mistune/mistune-"
5188 "17zqjp9m4d1w3jf2rbbq5xshcw24q1vlcv24gkgfqqyyymajxahx"))))
5189 (build-system python-build-system)
5191 `(("python-setuptools" ,python-setuptools)
5192 ("python-nose" ,python-nose)
5193 ("python-cython" ,python-cython)))
5194 (home-page "https://github.com/lepture/mistune")
5195 (synopsis "Markdown parser in pure Python")
5196 (description "This package provides a fast markdown parser in pure
5200 (define-public python2-mistune
5201 (package-with-python2 python-mistune))
5203 (define-public python-ptyprocess
5205 (name "python-ptyprocess")
5211 "https://pypi.python.org/packages/source/p/ptyprocess/ptyprocess-"
5215 "0nggns5kikn32yyda2zrj1xdmh49pi3v0drggcdwljbv36r8zdyw"))))
5216 (build-system python-build-system)
5218 `(("python-setuptools" ,python-setuptools)
5219 ("python-nose" ,python-nose)))
5222 (modify-phases %standard-phases
5225 (zero? (system* "nosetests")))))))
5226 (home-page "https://github.com/pexpect/ptyprocess")
5227 (synopsis "Run a subprocess in a pseudo terminal")
5229 "This package provides a Python library used to launch a subprocess in a
5230 pseudo terminal (pty), and interact with both the process and its pty.")
5233 (define-public python2-ptyprocess
5234 (package-with-python2 python-ptyprocess))
5236 (define-public python-terminado
5238 (name "python-terminado")
5244 "https://pypi.python.org/packages/source/t/terminado/terminado-"
5248 "1dkmp1n8dj5v1jl9mfrq8lwyc7dsfrvcmz2bgkpg315sy7pr7s33"))))
5249 (build-system python-build-system)
5251 `(("python-tornado" ,python-tornado)
5252 ("python-ptyprocess" ,python-ptyprocess)))
5254 `(("python-setuptools" ,python-setuptools)
5255 ("python-nose" ,python-nose)))
5258 (modify-phases %standard-phases
5261 (zero? (system* "nosetests")))))))
5262 (home-page "https://github.com/takluyver/terminado")
5263 (synopsis "Terminals served to term.js using Tornado websockets")
5264 (description "This package provides a Tornado websocket backend for the
5265 term.js Javascript terminal emulator library.")
5268 (define-public python2-terminado
5269 (let ((terminado (package-with-python2 python-terminado)))
5270 (package (inherit terminado)
5272 `(("python2-tornado" ,python2-tornado)
5273 ("python2-backport-ssl-match-hostname"
5274 ,python2-backport-ssl-match-hostname)
5275 ,@(alist-delete "python-tornado"
5276 (package-propagated-inputs terminado)))))))
5278 (define-public python-fonttools
5280 (name "python-fonttools")
5285 "https://pypi.python.org/packages/source/F/FontTools/"
5286 "fonttools-" version ".tar.gz"))
5289 "08ay3x4ijarwhl60gqx2i9jzq6pxs20p4snc2d1q5jagh4rn39lb"))))
5290 (build-system python-build-system)
5291 (arguments '(#:test-target "check"))
5293 ;; XXX: module not found if setuptools is not available.
5294 `(("python-setuptools" ,python-setuptools)))
5295 (home-page "http://github.com/behdad/fonttools")
5296 (synopsis "Tools to manipulate font files")
5298 "FontTools/TTX is a library to manipulate font files from Python. It
5299 supports reading and writinfg of TrueType/OpenType fonts, reading and writing
5300 of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
5301 also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
5302 from an XML-based format.")
5303 (license (non-copyleft "file://LICENSE.txt"
5304 "See LICENSE.txt in the distribution."))))
5306 (define-public python2-fonttools
5307 (package-with-python2 python-fonttools))
5309 (define-public python-ly
5317 "https://pypi.python.org/packages/source/p/python-ly/python-ly-"
5321 "1bsjg4q9ihr8bfdclrcmb8yjcg8xm9dznh58f3zsyrkrjzwbhcd2"))))
5322 (build-system python-build-system)
5324 `(("python-setuptools" ,python-setuptools)))
5325 (synopsis "Tool and library for manipulating LilyPond files")
5326 (description "This package provides a Python library to parse, manipulate
5327 or create documents in LilyPond format. A command line program ly is also
5328 provided that can be used to do various manipulations with LilyPond files.")
5329 (home-page "https://pypi.python.org/pypi/python-ly")
5332 (define-public python-appdirs
5334 (name "python-appdirs")
5340 "https://pypi.python.org/packages/source/a/appdirs/appdirs-"
5345 "1iddva7v3fq0aqzsahkazxr7vpw28mqcrsy818z4wyiqnkplbhlg"))))
5346 (build-system python-build-system)
5348 `(("python-setuptools" ,python-setuptools)))
5349 (home-page "http://github.com/ActiveState/appdirs")
5351 "Determine platform-specific dirs, e.g. a \"user data dir\"")
5353 "This module provides a portable way of finding out where user data
5354 should be stored on various operating systems.")
5355 (license license:expat)))
5357 (define-public python2-appdirs
5358 (package-with-python2 python-appdirs))
5360 (define-public python-llfuse
5362 (name "python-llfuse")
5367 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5368 "llfuse-" version ".tar.bz2"))
5371 "0yzy8ixpmxk00kdq6lx5vvwbs0n6s59qnja5q0js2ahbqyxiz2hb"))))
5372 (build-system python-build-system)
5377 `(("pkg-config" ,pkg-config)
5378 ("python-setuptools" ,python-setuptools)))
5379 (synopsis "Python bindings for FUSE")
5381 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
5382 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
5383 ;; Python-LLFUSE includes underscore.js, which is MIT (expat) licensed.
5384 ;; The rest of the package is licensed under LGPL2.0 or later.
5385 (license (list license:expat lgpl2.0+))))
5387 (define-public python2-llfuse
5388 (package-with-python2 python-llfuse))
5390 (define-public python-msgpack
5392 (name "python-msgpack")
5397 "https://pypi.python.org/packages/source/m/"
5398 "msgpack-python/msgpack-python-" version ".tar.gz"))
5401 "1527c76b6fn4zzkgfq5xvhh7x9a9686g7fjiz717rw5vklf5ik5z"))))
5402 (build-system python-build-system)
5404 `(("python-setuptools" ,python-setuptools)))
5405 (synopsis "MessagePack (de)serializer")
5406 (description "MessagePack is a fast, compact binary serialization format,
5407 suitable for similar data to JSON. This package provides CPython bindings for
5408 reading and writing MessagePack data.")
5409 (home-page "https://pypi.python.org/pypi/msgpack-python/")
5412 (define-public python2-msgpack
5413 (package-with-python2 python-msgpack))
5415 (define-public python-netaddr
5417 (name "python-netaddr")
5423 "https://pypi.python.org/packages/source/n/netaddr/netaddr-"
5428 "06dxjlbcicq7q3vqy8agq11ra01kvvd47j4mk6dmghjsyzyckxd1"))))
5429 (build-system python-build-system)
5430 (arguments `(#:tests? #f)) ;; No tests.
5432 `(("python-setuptools" ,python-setuptools)))
5433 (home-page "https://github.com/drkjam/netaddr/")
5434 (synopsis "Pythonic manipulation of network addresses")
5436 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
5437 and MAC network addresses.")
5440 (define-public python2-netaddr
5441 (package-with-python2 python-netaddr))
5443 (define-public python-wrapt
5445 (name "python-wrapt")
5451 "https://pypi.python.org/packages/source/w/wrapt/wrapt-"
5456 "0cq8rlpzkxzk48b50yrfhzn1d1hrq4gjcdqlrgq4v5palgiv9jwr"))))
5457 (build-system python-build-system)
5459 ;; Tests are not included in the tarball, they are only available in the
5463 `(("python-setuptools" ,python-setuptools)))
5464 (home-page "https://github.com/GrahamDumpleton/wrapt")
5465 (synopsis "Module for decorators, wrappers and monkey patching")
5467 "The aim of the wrapt module is to provide a transparent object proxy for
5468 Python, which can be used as the basis for the construction of function
5469 wrappers and decorator functions.")
5472 (define-public python2-wrapt
5473 (package-with-python2 python-wrapt))
5475 (define-public python-iso8601
5477 (name "python-iso8601")
5483 "https://pypi.python.org/packages/source/i/iso8601/iso8601-"
5488 "1qf01afxh7j4gja71vxv345if8avg6nnm0ry0zsk6j3030xgy4p7"))))
5489 (build-system python-build-system)
5491 `(("python-setuptools" ,python-setuptools)))
5492 (home-page "https://bitbucket.org/micktwomey/pyiso8601")
5493 (synopsis "Module to parse ISO 8601 dates")
5495 "This module parses the most common forms of ISO 8601 date strings (e.g.
5496 @code{2007-01-14T20:34:22+00:00}) into @code{datetime} objects.")
5497 (license license:expat)))
5499 (define-public python2-iso8601
5500 (package-with-python2 python-iso8601))
5502 (define-public python-monotonic
5504 (name "python-monotonic")
5510 "https://pypi.python.org/packages/source/m/monotonic/monotonic-"
5515 "0yz0bcbwx8r2c01czzfpbrxddynxyk9k95jj8h6sgcb7xmfvl998"))))
5516 (build-system python-build-system)
5518 `(("python-setuptools" ,python-setuptools)))
5519 (home-page "https://github.com/atdt/monotonic")
5520 (synopsis "Implementation of time.monotonic() for Python 2 & < 3.3")
5522 "This module provides a monotonic() function which returns the value (in
5523 fractional seconds) of a clock which never goes backwards.")
5526 (define-public python2-monotonic
5527 (package-with-python2 python-monotonic))
5529 (define-public python-webob
5531 (name "python-webob")
5537 "https://pypi.python.org/packages/source/W/WebOb/WebOb-"
5541 "140b3iczclk1j0405rvw5gxshqfkhcc8254fj520z3m23cwbql4a"))))
5542 (build-system python-build-system)
5544 `(("python-nose" ,python-nose)
5545 ("python-setuptools" ,python-setuptools)))
5546 (home-page "http://webob.org/")
5547 (synopsis "WSGI request and response object")
5549 "WebOb provides wrappers around the WSGI request environment, and an
5550 object to help create WSGI responses.")
5551 (license license:expat)))
5553 (define-public python2-webob
5554 (package-with-python2 python-webob))
5556 (define-public python-xlrd
5558 (name "python-xlrd")
5562 (uri (string-append "https://pypi.python.org/packages/source/x/"
5563 "xlrd/xlrd-" version ".tar.gz"))
5566 "0wpa55nvidmm5m2qr622dsh3cj46akdk0h3zjgzschcmydck73cf"))))
5567 (build-system python-build-system)
5570 (modify-phases %standard-phases
5571 ;; Current test in setup.py does not work as of 0.9.4, so use nose to
5572 ;; run tests instead for now.
5573 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
5574 (native-inputs `(("python-nose" ,python-nose)
5575 ("python-setuptools" ,python-setuptools)))
5576 (home-page "http://www.python-excel.org/")
5577 (synopsis "Library for extracting data from Excel files")
5578 (description "This packages provides a library to extract data from
5579 spreadsheets using Microsoft Excel® proprietary file formats @samp{.xls} and
5580 @samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
5581 Unicode-aware. It is not intended as an end-user tool.")
5584 (define-public python2-xlrd
5585 (package-with-python2 python-xlrd))
5587 (define-public python-prettytable
5589 (name "python-prettytable")
5595 "https://pypi.python.org/packages/source/P/PrettyTable/"
5596 "prettytable-" version ".tar.bz2"))
5599 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
5600 (build-system python-build-system)
5602 `(("python-setuptools" ,python-setuptools)))
5603 (home-page "http://code.google.com/p/prettytable/")
5604 (synopsis "Display tabular data in an ASCII table format")
5606 "A library designed to represent tabular data in visually appealing ASCII
5607 tables. PrettyTable allows for selection of which columns are to be printed,
5608 independent alignment of columns (left or right justified or centred) and
5609 printing of sub-tables by specifying a row range.")
5612 (define-public python2-prettytable
5613 (package-with-python2 python-prettytable))
5615 (define-public python-pyasn1
5617 (name "python-pyasn1")
5622 (uri (string-append "https://pypi.python.org/packages/source/p/"
5623 "pyasn1/pyasn1-" version ".tar.gz"))
5626 "0iw31d9l0zwx35szkzq72hiw002wnqrlrsi9dpbrfngcl1ybwcsx"))))
5627 (build-system python-build-system)
5628 (home-page "http://pyasn1.sourceforge.net/")
5629 (synopsis "ASN.1 types and codecs")
5631 "This is an implementation of ASN.1 types and codecs in Python. It is
5632 suitable for a wide range of protocols based on the ASN.1 specification.")
5635 (define-public python2-pyasn1
5636 (package-with-python2 python-pyasn1))
5638 (define-public python2-ipaddress
5640 (name "python2-ipaddress")
5645 (uri (string-append "https://pypi.python.org/packages/source/i/"
5646 "ipaddress/ipaddress-" version ".tar.gz"))
5649 "0givid4963n57nsjibms2fc347zmcs188q1hw9al1dkc9kj4nvr2"))))
5650 (build-system python-build-system)
5652 `(#:tests? #f ; no tests
5653 #:python ,python-2))
5654 (home-page "https://github.com/phihag/ipaddress")
5655 (synopsis "IP address manipulation library")
5657 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
5658 in Python. This library is used to create, poke at, and manipulate IPv4 and
5659 IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
5660 module to older versions of Python.")
5663 (define-public python-idna
5665 (name "python-idna")
5670 (uri (string-append "https://pypi.python.org/packages/source/i/"
5671 "idna/idna-" version ".tar.gz"))
5674 "0frxgmgi234lr9hylg62j69j4ik5zhg0wz05w5dhyacbjfnrl68n"))))
5675 (build-system python-build-system)
5677 `(("python-setuptools" ,python-setuptools)))
5678 (home-page "https://github.com/kjd/idna")
5679 (synopsis "Internationalized domain names in applications")
5681 "This is a library to support the Internationalised Domain Names in
5682 Applications (IDNA) protocol as specified in RFC 5891. This version of the
5683 protocol is often referred to as “IDNA2008” and can produce different results
5684 from the earlier standard from 2003. The library is also intended to act as a
5685 suitable drop-in replacement for the “encodings.idna” module that comes with
5686 the Python standard library but currently only supports the older 2003
5690 (define-public python2-idna
5691 (package-with-python2 python-idna))
5693 (define-public python-pretend
5695 (name "python-pretend")
5700 (uri (string-append "https://pypi.python.org/packages/source/p/"
5701 "pretend/pretend-" version ".tar.gz"))
5704 "0r5r7ygz9m6d2bklflbl84cqhjkc2q12xgis8268ygjh30g2q3wk"))))
5705 (build-system python-build-system)
5707 `(("python-setuptools" ,python-setuptools)))
5708 (home-page "https://github.com/alex/pretend")
5709 (synopsis "Library for stubbing in Python")
5711 "Pretend is a library to make stubbing with Python easier. Stubbing is a
5712 technique for writing tests. You may hear the term mixed up with mocks,
5713 fakes, or doubles. Basically, a stub is an object that returns pre-canned
5714 responses, rather than doing any computation.")
5717 (define-public python2-pretend
5718 (package-with-python2 python-pretend))
5720 (define-public python-cryptography-vectors
5722 (name "python-cryptography-vectors")
5727 (uri (string-append "https://pypi.python.org/packages/source/c/"
5728 "cryptography-vectors/cryptography_vectors-"
5732 "0dx98kcypmarwwhi6rjwy30ridys2ja6mc6mjf0svd4nllkaljdq"))))
5733 (build-system python-build-system)
5735 `(("python-setuptools" ,python-setuptools)))
5736 (home-page "https://github.com/pyca/cryptography")
5737 (synopsis "Test vectors for the cryptography package.")
5739 "This package contains test vectors for the cryptography package.")
5740 ;; Distributed under either BSD-3 or ASL2.0
5741 (license (list bsd-3 asl2.0))))
5743 (define-public python2-cryptography-vectors
5744 (package-with-python2 python-cryptography-vectors))
5746 (define-public python-cryptography
5748 (name "python-cryptography")
5753 (uri (string-append "https://pypi.python.org/packages/source/c/"
5754 "cryptography/cryptography-" version ".tar.gz"))
5757 "1jmcidddbbgdavvnvjjc0pda4b9a5i9idsivchn69pqxx68x8k6n"))))
5758 (build-system python-build-system)
5760 `(("openssl" ,openssl)))
5762 `(("python-cffi" ,python-cffi)
5763 ("python-six" ,python-six)
5764 ("python-pyasn1" ,python-pyasn1)
5765 ("python-enum34" ,python-enum34)
5766 ("python-idna" ,python-idna)
5767 ("python-iso8601" ,python-iso8601)))
5769 `(("python-cryptography-vectors" ,python-cryptography-vectors)
5770 ("python-setuptools" ,python-setuptools)
5771 ("python-pretend" ,python-pretend)
5772 ("python-pytest" ,python-pytest)))
5773 (home-page "https://github.com/pyca/cryptography")
5774 (synopsis "Cryptographic recipes and primitives for Python")
5776 "cryptography is a package which provides cryptographic recipes and
5777 primitives to Python developers. It aims to be the “cryptographic standard
5778 library” for Python. The package includes both high level recipes, and low
5779 level interfaces to common cryptographic algorithms such as symmetric ciphers,
5780 message digests and key derivation functions.")
5781 ;; Distributed under either BSD-3 or ASL2.0
5782 (license (list bsd-3 asl2.0))))
5784 (define-public python2-cryptography
5785 (let ((crypto (package-with-python2 python-cryptography)))
5786 (package (inherit crypto)
5788 `(("python2-ipaddress" ,python2-ipaddress)
5789 ,@(package-propagated-inputs crypto))))))
5791 (define-public python-pyopenssl
5793 (name "python-pyopenssl")
5798 (uri (string-append "https://pypi.python.org/packages/source/p/"
5799 "pyOpenSSL/pyOpenSSL-" version ".tar.gz"))
5802 "0wnnq15rhj7fhdcd8ycwiw6r6g3w9f9lcy6cigg8226vsrq618ph"))))
5803 (build-system python-build-system)
5806 (modify-phases %standard-phases
5807 (add-after 'unpack 'fix-tests
5808 (lambda* (#:key inputs #:allow-other-keys)
5809 (substitute* "OpenSSL/test/test_ssl.py"
5810 (("client\\.connect\\(\\('verisign\\.com', 443\\)\\)")
5812 ;; FIXME: disable broken test
5813 (("test_set_tmp_ecdh") "disabled__set_tmp_ecdh"))
5814 (substitute* "OpenSSL/test/test_crypto.py"
5815 (("command = b\"openssl \"")
5816 (string-append "command = b\""
5817 (assoc-ref inputs "openssl")
5818 "/bin/openssl" " \""))
5819 ;; FIXME: disable four broken tests
5820 (("test_der") "disabled__der")
5821 (("test_digest") "disabled__digest")
5822 (("test_get_extension") "disabled__get_extension")
5823 (("test_extension_count") "disabled__extension_count"))
5826 `(("python-cryptography" ,python-cryptography)
5827 ("python-six" ,python-six)))
5829 `(("openssl" ,openssl)))
5831 `(("python-setuptools" ,python-setuptools)))
5832 (home-page "https://github.com/pyca/pyopenssl")
5833 (synopsis "Python wrapper module around the OpenSSL library")
5835 "PyOpenSSL is a high-level wrapper around a subset of the OpenSSL
5839 (define-public python2-pyopenssl
5840 (let ((pyopenssl (package-with-python2 python-pyopenssl)))
5841 (package (inherit pyopenssl)
5843 `(("python2-cryptography" ,python2-cryptography)
5844 ,@(alist-delete "python-cryptography"
5845 (package-propagated-inputs pyopenssl)))))))
5847 (define-public python-pip
5855 "https://pypi.python.org/packages/source/p/pip/pip-"
5859 "0xx4aypfgchxdknxq7gyqghd8wb221zrzyqlbabzm32jy237j16a"))))
5860 (build-system python-build-system)
5862 `(("python-setuptools" ,python-setuptools)
5863 ("python-virtualenv" ,python-virtualenv)
5865 ("python-mock" ,python-mock)
5866 ("python-pytest" ,python-pytest)
5867 ("python-scripttest" ,python-scripttest)))
5868 (home-page "https://pip.pypa.io/")
5870 "Package manager for Python software")
5872 "Pip is a package manager for Python software, that finds packages on the
5873 Python Package Index (PyPI).")
5874 (license license:expat)))
5876 (define-public python2-pip
5877 (package-with-python2 python-pip))
5879 (define-public python-tlsh
5881 (name "python-tlsh")
5882 (version "3.4.1") ;according to CMakeLists.txt
5883 (home-page "https://github.com/trendmicro/tlsh")
5888 ;; This is a commit right after 3.4.1; see
5889 ;; <https://github.com/trendmicro/tlsh/issues/9>.
5890 (commit "3ae3f1f")))
5893 "12cvnr5ndm5cg6i7lch93id90kgwgrigjgrj8f186nh3h4bf9chj"))
5894 (file-name (string-append name "-" version "-checkout"))))
5895 (build-system cmake-build-system)
5897 '(#:out-of-source? #f
5898 #:phases (modify-phases %standard-phases
5901 (lambda* (#:key outputs #:allow-other-keys)
5902 ;; Build and install the Python bindings. The underlying
5903 ;; C++ library is apparently not meant to be installed.
5904 (let ((out (assoc-ref outputs "out")))
5905 (with-directory-excursion "py_ext"
5906 (and (system* "python" "setup.py" "build")
5907 (system* "python" "setup.py" "install"
5908 (string-append "--prefix=" out))))))))))
5909 (inputs `(("python" ,python-wrapper))) ;for the bindings
5910 (synopsis "Fuzzy matching library for Python")
5912 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
5913 Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
5914 value which can be used for similarity comparisons. Similar objects have
5915 similar hash values, which allows for the detection of similar objects by
5916 comparing their hash values. The byte stream should have a sufficient amount
5917 of complexity; for example, a byte stream of identical bytes will not generate
5921 (define-public python2-tlsh
5923 (inherit python-tlsh)
5924 (name "python2-tlsh")
5925 (inputs `(("python" ,python-2)))))
5927 (define-public python-libarchive-c
5929 (name "python-libarchive-c")
5934 "https://pypi.python.org/packages/source/l/libarchive-c/libarchive-c-"
5938 "089lrz6xyrfnk55v35vis6jyqyyl77w093057djyspnd2744wi2n"))))
5939 (build-system python-build-system)
5941 '(#:phases (modify-phases %standard-phases
5943 'build 'reference-libarchive
5944 (lambda* (#:key inputs #:allow-other-keys)
5945 ;; Retain the absolute file name of libarchive.so.
5946 (let ((libarchive (assoc-ref inputs "libarchive")))
5947 (substitute* "libarchive/ffi.py"
5948 (("find_library\\('archive'\\)")
5949 (string-append "'" libarchive
5950 "/lib/libarchive.so'"))))
5952 ;; Do not make a compressed egg (see
5953 ;; <http://bugs.gnu.org/20765>).
5954 (let ((port (open-file "setup.cfg" "a")))
5955 (display "\n[easy_install]\nzip_ok = 0\n"
5960 `(("python-setuptools" ,python-setuptools)
5961 ("libarchive" ,libarchive)))
5962 (home-page "https://github.com/Changaco/python-libarchive-c")
5963 (synopsis "Python interface to libarchive")
5965 "This package provides Python bindings to libarchive, a C library to
5966 access possibly compressed archives in many different formats. It uses
5967 Python's @code{ctypes} foreign function interface (FFI).")
5968 (license lgpl2.0+)))
5970 (define-public python2-libarchive-c
5971 (package-with-python2 python-libarchive-c))
5973 (define-public python-file
5976 (name "python-file")
5977 (build-system python-build-system)
5979 '(#:tests? #f ;no tests
5980 #:phases (modify-phases %standard-phases
5981 (add-before 'build 'change-directory
5985 (add-before 'build 'set-library-file-name
5986 (lambda* (#:key inputs #:allow-other-keys)
5987 (let ((file (assoc-ref inputs "file")))
5988 (substitute* "magic.py"
5989 (("find_library\\('magic'\\)")
5990 (string-append "'" file "/lib/libmagic.so'")))
5992 (inputs `(("file" ,file)))
5993 (self-native-input? #f)
5994 (synopsis "Python bindings to the libmagic file type guesser")))
5996 (define-public python2-file
5997 (package-with-python2 python-file))
5999 (define-public python-debian
6001 (name "python-debian")
6007 "https://pypi.python.org/packages/source/p/python-debian/python-debian-"
6011 "193faznwnjc3n5991wyzim6h9gyq1zxifmfrnpm3avgkh7ahyynh"))))
6012 (build-system python-build-system)
6014 `(("python-six" ,python-six)))
6016 `(("python-setuptools" ,python-setuptools)))
6017 (home-page "http://packages.debian.org/sid/python-debian")
6018 (synopsis "Debian package related modules")
6020 ;; XXX: Use @enumerate instead of @itemize to work around
6021 ;; <http://bugs.gnu.org/21772>.
6022 "This package provides Python modules that abstract many formats of
6023 Debian-related files, such as:
6026 @item Debtags information;
6027 @item @file{debian/changelog} files;
6028 @item packages files, pdiffs;
6029 @item control files of single or multiple RFC822-style paragraphs---e.g.
6030 @file{debian/control}, @file{.changes}, @file{.dsc};
6031 @item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
6032 contained files and meta-information.
6035 ;; Modules are either GPLv2+ or GPLv3+.
6038 (define-public python2-debian
6039 (package-with-python2 python-debian))
6041 (define-public python-chardet
6043 (name "python-chardet")
6049 "https://pypi.python.org/packages/source/c/chardet/chardet-"
6054 "1ak87ikcw34fivcgiz2xvi938dmclh078az65l9x3rmgljrkhgp5"))))
6055 (build-system python-build-system)
6057 `(("python-setuptools" ,python-setuptools)))
6058 (home-page "https://github.com/chardet/chardet")
6059 (synopsis "Universal encoding detector for Python 2 and 3")
6061 "This package provides @code{chardet}, a Python module that can
6062 automatically detect a wide range of file encodings.")
6063 (license lgpl2.1+)))
6065 (define-public python2-chardet
6066 (package-with-python2 python-chardet))
6068 (define-public python-docopt
6070 (name "python-docopt")
6075 ;; The release on PyPI does not include tests.
6077 "https://github.com/docopt/docopt/archive/"
6079 (file-name (string-append name "-" version ".tar.gz"))
6082 "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1"))))
6083 (build-system python-build-system)
6085 `(("python-pytest" ,python-pytest)
6086 ("python-setuptools" ,python-setuptools)))
6088 `(#:phases (alist-replace
6090 (lambda _ (zero? (system* "py.test")))
6092 (home-page "http://docopt.org")
6093 (synopsis "Command-line interface description language for Python")
6094 (description "This library allows the user to define a command-line
6095 interface from a program's help message rather than specifying it
6096 programatically with command-line parsers like @code{getopt} and
6098 (license license:expat)))
6100 (define-public python2-docopt
6101 (package-with-python2 python-docopt))
6103 (define-public python-zope-event
6105 (name "python-zope-event")
6110 (uri (string-append "https://pypi.python.org/packages/source/z"
6111 "/zope.event/zope.event-" version ".tar.gz"))
6114 "11p75zpfz3ffhz21nzx9wb23xs993ck5s6hkjcvhswwizni5jynw"))))
6115 (build-system python-build-system)
6117 `(("python-setuptools" ,python-setuptools)))
6118 (home-page "http://pypi.python.org/pypi/zope.event")
6119 (synopsis "Event publishing system for Python")
6120 (description "Zope.event provides an event publishing API, intended for
6121 use by applications which are unaware of any subscribers to their events. It
6122 is a simple event-dispatching system on which more sophisticated event
6123 dispatching systems can be built.")
6126 (define-public python2-zope-event
6127 (package-with-python2 python-zope-event))
6129 (define-public python-zope-interface
6131 (name "python-zope-interface")
6136 (uri (string-append "https://pypi.python.org/packages/source/z"
6137 "/zope.interface/zope.interface-" version ".tar.gz"))
6140 "0ks8h73b2g4bkad821qbv0wzjppdrwys33i7ka45ik3wxjg1l8if"))))
6141 (build-system python-build-system)
6143 `(("python-zope-event" ,python-zope-event)))
6144 (home-page "https://github.com/zopefoundation/zope.interface")
6145 (synopsis "Python implementation of the \"design by contract\"
6147 (description "Zope.interface provides an implementation of \"object
6148 interfaces\" for Python. Interfaces are a mechanism for labeling objects as
6149 conforming to a given API or contract.")
6152 (define-public python2-zope-interface
6153 (package-with-python2 python-zope-interface))
6155 (define-public python-zope-exceptions
6157 (name "python-zope-exceptions")
6162 (uri (string-append "https://pypi.python.org/packages/source/z"
6163 "/zope.exceptions/zope.exceptions-"
6167 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
6168 (build-system python-build-system)
6170 '(#:tests? #f)) ; circular dependency with zope.testrunner
6172 `(("python-zope-interface" ,python-zope-interface)))
6173 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
6174 (synopsis "Zope exceptions")
6175 (description "Zope.exceptions provides general-purpose exception types
6176 that have uses outside of the Zope framework.")
6179 (define-public python2-zope-exceptions
6180 (package-with-python2 python-zope-exceptions))
6182 (define-public python-zope-testing
6184 (name "python-zope-testing")
6189 (uri (string-append "https://pypi.python.org/packages/source/z"
6190 "/zope.testing/zope.testing-" version ".tar.gz"))
6193 "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))))
6194 (build-system python-build-system)
6196 `(("python-zope-exceptions" ,python-zope-exceptions)))
6198 `(("python-zope-interface" ,python-zope-interface)))
6199 (home-page "http://pypi.python.org/pypi/zope.testing")
6200 (synopsis "Zope testing helpers")
6201 (description "Zope.testing provides a number of testing utilities for HTML
6202 forms, HTTP servers, regular expressions, and more.")
6205 (define-public python2-zope-testing
6206 (package-with-python2 python-zope-testing))
6208 (define-public python-zope-testrunner
6210 (name "python-zope-testrunner")
6215 (uri (string-append "https://pypi.python.org/packages/source/z"
6216 "/zope.testrunner/zope.testrunner-"
6220 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
6221 (build-system python-build-system)
6223 `(("python-six" ,python-six)
6224 ("python-zope-exceptions" ,python-zope-exceptions)
6225 ("python-zope-testing" ,python-zope-testing)
6228 `(("python-zope-interface" ,python-zope-interface)))
6229 (home-page "http://pypi.python.org/pypi/zope.testrunner")
6230 (synopsis "Zope testrunner script")
6231 (description "Zope.testrunner provides a script for running Python
6235 (define-public python2-zope-testrunner
6236 (let ((base (package-with-python2 python-zope-testrunner)))
6240 (append (package-native-inputs base)
6241 `(("python2-subunit" ,python2-subunit)
6242 ("python2-mimeparse" ,python2-mimeparse)))))))
6244 (define-public python-zope-i18nmessageid
6246 (name "python-zope-i18nmessageid")
6252 "https://pypi.python.org/packages/source/z"
6253 "/zope.i18nmessageid/zope.i18nmessageid-"
6257 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
6258 (build-system python-build-system)
6260 `(("python-setuptools" ,python-setuptools)))
6261 (home-page "http://pypi.python.org/pypi/zope.i18nmessageid")
6262 (synopsis "Message identifiers for internationalization")
6263 (description "Zope.i18nmessageid provides facilities for declaring
6264 internationalized messages within program source text.")
6267 (define-public python2-zope-i18nmessageid
6268 (package-with-python2 python-zope-i18nmessageid))
6270 (define-public python-zope-schema
6272 (name "python-zope-schema")
6277 (uri (string-append "https://pypi.python.org/packages/source/z"
6278 "/zope.schema/zope.schema-" version ".tar.gz"))
6281 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
6282 (build-system python-build-system)
6284 `(("python-zope-event" ,python-zope-event)
6285 ("python-zope-interface" ,python-zope-interface)))
6287 `(("python-zope-testing" ,python-zope-testing)))
6288 (home-page "http://pypi.python.org/pypi/zope.schema")
6289 (synopsis "Zope data schemas")
6290 (description "Zope.scheme provides extensions to zope.interface for
6291 defining data schemas.")
6294 (define-public python2-zope-schema
6295 (package-with-python2 python-zope-schema))
6297 (define-public python-zope-configuration
6299 (name "python-zope-configuration")
6303 (uri (string-append "https://pypi.python.org/packages/source/z"
6304 "/zope.configuration/zope.configuration-"
6308 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
6309 (build-system python-build-system)
6311 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6312 ("python-zope-schema" ,python-zope-schema)))
6313 (home-page "http://pypi.python.org/pypi/zope.configuration")
6314 (synopsis "Zope Configuration Markup Language")
6315 (description "Zope.configuration implements ZCML, the Zope Configuration
6319 (define-public python2-zope-configuration
6320 (package-with-python2 python-zope-configuration))
6322 (define-public python-zope-proxy
6324 (name "python-zope-proxy")
6329 (uri (string-append "https://pypi.python.org/packages/source/z"
6330 "/zope.proxy/zope.proxy-" version ".tar.gz"))
6333 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
6334 (build-system python-build-system)
6336 `(("python-zope-interface" ,python-zope-interface)))
6337 (home-page "http://pypi.python.org/pypi/zope.proxy")
6338 (synopsis "Generic, transparent proxies")
6339 (description "Zope.proxy provides generic, transparent proxies for Python.
6340 Proxies are special objects which serve as mostly-transparent wrappers around
6341 another object, intervening in the apparent behavior of the wrapped object
6342 only when necessary to apply the policy (e.g., access checking, location
6343 brokering, etc.) for which the proxy is responsible.")
6346 (define-public python2-zope-proxy
6347 (package-with-python2 python-zope-proxy))
6349 (define-public python-zope-location
6351 (name "python-zope-location")
6356 (uri (string-append "https://pypi.python.org/packages/source/z"
6357 "/zope.location/zope.location-" version ".tar.gz"))
6360 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
6361 (build-system python-build-system)
6363 `(("python-zope-proxy" ,python-zope-proxy)
6364 ("python-zope-schema" ,python-zope-schema)))
6365 (home-page "http://pypi.python.org/pypi/zope.location/")
6366 (synopsis "Zope location library")
6367 (description "Zope.location implements the concept of \"locations\" in
6368 Zope3, which are are special objects that have a structural location.")
6371 (define-public python2-zope-location
6372 (package-with-python2 python-zope-location))
6374 (define-public python-zope-security
6376 (name "python-zope-security")
6381 (uri (string-append "https://pypi.python.org/packages/source/z"
6382 "/zope.security/zope.security-" version ".tar.gz"))
6385 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
6386 (build-system python-build-system)
6388 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6389 ("python-zope-component" ,python-zope-component)
6390 ("python-zope-location" ,python-zope-location)
6391 ("python-zope-proxy" ,python-zope-proxy)
6392 ("python-zope-schema" ,python-zope-schema)
6393 ("python-zope-testrunner" ,python-zope-testrunner)
6394 ("python-zope-testing" ,python-zope-testing)))
6395 (home-page "http://pypi.python.org/pypi/zope.security")
6396 (synopsis "Zope security framework")
6397 (description "Zope.security provides a generic mechanism to implement
6398 security policies on Python objects.")
6401 (define-public python2-zope-security
6402 (let ((zope-security (package-with-python2 python-zope-security)))
6403 (package (inherit zope-security)
6405 `(("python2-zope-testrunner" ,python2-zope-testrunner)
6407 "python-zope-testrunner"
6408 (package-propagated-inputs zope-security)))))))
6410 (define-public python-zope-component
6412 (name "python-zope-component")
6417 (uri (string-append "https://pypi.python.org/packages/source/z"
6418 "/zope.component/zope.component-" version ".tar.gz"))
6421 "06pqr8m5jv12xjyy5b59hh9anl61cxkzhw9mka33r3nxalmi2b18"))))
6422 (build-system python-build-system)
6424 ;; Skip tests due to circular dependency with python-zope-security.
6427 `(("python-zope-testing" ,python-zope-testing)))
6429 `(("python-zope-event" ,python-zope-event)
6430 ("python-zope-interface" ,python-zope-interface)
6431 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6432 ("python-zope-configuration" ,python-zope-configuration)))
6433 (home-page "https://github.com/zopefoundation/zope.component")
6434 (synopsis "Zope Component Architecture")
6435 (description "Zope.component represents the core of the Zope Component
6436 Architecture. Together with the zope.interface package, it provides
6437 facilities for defining, registering and looking up components.")
6440 (define-public python2-zope-component
6441 (package-with-python2 python-zope-component))
6443 (define-public python2-pythondialog
6445 (name "python2-pythondialog")
6450 (uri (string-append "https://pypi.python.org/packages/source/p/"
6451 "python2-pythondialog/python2-pythondialog-"
6455 "1yhkagsh99bfi592ymczf8rnw8rk6n9hdqy3dd98m3yrx8zmjvry"))))
6456 (build-system python-build-system)
6459 (modify-phases %standard-phases
6460 (add-after 'unpack 'patch-path
6461 (lambda* (#:key inputs #:allow-other-keys)
6462 (let* ((dialog (assoc-ref inputs "dialog")))
6463 ;; Since this library really wants to grovel the search path, we
6464 ;; must hardcode dialog's store path into it.
6465 (substitute* "dialog.py"
6466 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
6467 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
6470 #:tests? #f)) ; no test suite
6472 `(("dialog" ,dialog)))
6473 (home-page "http://pythondialog.sourceforge.net/")
6474 (synopsis "Python interface to the UNIX dialog utility")
6475 (description "A Python wrapper for the dialog utility. Its purpose is to
6476 provide an easy to use, pythonic and comprehensive Python interface to dialog.
6477 This allows one to make simple text-mode user interfaces on Unix-like systems")
6480 (define-public python-pyrfc3339
6482 (name "python-pyrfc3339")
6487 (uri (string-append "https://pypi.python.org/packages/source/p/"
6488 "pyRFC3339/pyRFC3339-" version ".tar.gz"))
6491 "1pp648xsjaw9h1xq2mgwzda5wis2ypjmzxlksc1a8grnrdmzy155"))))
6492 (build-system python-build-system)
6494 `(("python-pytz" ,python-pytz)))
6496 `(("python-nose" ,python-nose)
6497 ("python-setuptools" ,python-setuptools)))
6498 (home-page "https://github.com/kurtraschke/pyRFC3339")
6499 (synopsis "Python timestamp library")
6500 (description "Python library for generating and parsing RFC 3339-compliant
6502 (license license:expat)))
6504 (define-public python2-pyrfc3339
6505 (package-with-python2 python-pyrfc3339))
6507 (define-public python-werkzeug
6509 (name "python-werkzeug")
6514 (uri (string-append "https://pypi.python.org/packages/source/W/Werkzeug"
6515 "/Werkzeug-" version ".tar.gz"))
6516 (file-name (string-append name "-" version ".tar.gz"))
6519 "1gzwn1lkl90f3l1nzzxr7vjhm21qk8f837i8rvny5a209fcrhkzb"))))
6520 (build-system python-build-system)
6522 `(("python-pytest" ,python-pytest)))
6523 (home-page "http://werkzeug.pocoo.org/")
6524 (synopsis "Utilities for WSGI applications")
6525 (description "One of the most advanced WSGI utility modules. It includes a
6526 powerful debugger, full-featured request and response objects, HTTP utilities to
6527 handle entity tags, cache control headers, HTTP dates, cookie handling, file
6528 uploads, a powerful URL routing system and a bunch of community-contributed
6532 (define-public python2-werkzeug
6533 (package-with-python2 python-werkzeug))
6535 (define-public python-configobj
6537 (name "python-configobj")
6542 "https://pypi.python.org/packages/source/c/configobj/"
6543 "configobj-" version ".tar.gz"))
6546 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
6547 ;; Patch setup.py so it looks for python-setuptools, which is
6548 ;; required to parse the keyword 'install_requires' in setup.py.
6549 (patches (list (search-patch "python-configobj-setuptools.patch")))))
6550 (build-system python-build-system)
6552 `(("python-setuptools" ,python-setuptools)
6553 ("python-six" ,python-six)))
6554 (synopsis "Config file reading, writing and validation")
6555 (description "ConfigObj is a simple but powerful config file reader and
6556 writer: an ini file round tripper. Its main feature is that it is very easy to
6557 use, with a straightforward programmer’s interface and a simple syntax for
6559 (home-page "https://github.com/DiffSK/configobj")
6562 (define-public python2-configobj
6563 (package-with-python2 python-configobj))
6565 (define-public python-configargparse
6567 (name "python-configargparse")
6572 "https://pypi.python.org/packages/source/C/ConfigArgParse/"
6573 "ConfigArgParse-" version ".tar.gz"))
6576 "19wh919gbdbzxzpagg52q3lm62yicm95ddlcx77dyjc1slyshl1v"))))
6577 (build-system python-build-system)
6579 ;; FIXME: Bug in test suite filed upstream:
6580 ;; https://github.com/bw2/ConfigArgParse/issues/32
6582 (synopsis "Replacement for argparse")
6583 (description "A drop-in replacement for argparse that allows options to also
6584 be set via config files and/or environment variables.")
6585 (home-page "https://github.com/bw2/ConfigArgParse")
6586 (license license:expat)))
6588 (define-public python2-configargparse
6589 (package-with-python2 python-configargparse))
6591 (define-public python-ndg-httpsclient
6593 (name "python-ndg-httpsclient")
6598 "https://pypi.python.org/packages/source/n/ndg-httpsclient/"
6599 "ndg_httpsclient-" version ".tar.gz"))
6602 "0x32ibixm3vv5m9xfk83xsqm8xcqw4dd0khbh6qbri6rxgymbhg8"))))
6603 (build-system python-build-system)
6605 `(("python-pyopenssl" ,python-pyopenssl)))
6606 (synopsis "HTTPS support for Python's httplib and urllib2")
6607 (description "This is a HTTPS client implementation for httplib and urllib2
6608 based on PyOpenSSL. PyOpenSSL provides a more fully featured SSL implementation
6609 over the default provided with Python and importantly enables full verification
6611 (home-page "https://github.com/cedadev/ndg_httpsclient/")
6614 ;; python2-openssl requires special care, so package-with-python2 is
6616 (define-public python2-ndg-httpsclient
6617 (package (inherit python-ndg-httpsclient)
6618 (name "python2-ndg-httpsclient")
6619 (arguments `(#:python ,python-2))
6621 `(("python2-pyopenssl" ,python2-pyopenssl)))))