gnu: python-cryptography: Define 'python2-variant'.
[jackhill/guix/guix.git] / gnu / packages / python.scm
CommitLineData
a01b6da7
NK
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
48b311b1 3;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
03411993 4;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr>
e99f4211 5;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
a480bc41 6;;; Copyright © 2014 Eric Bavier <bavier@member.fsf.org>
da6ce3f1 7;;; Copyright © 2014, 2015 Federico Beffa <beffa@fbengineering.ch>
e99f4211 8;;; Copyright © 2015 Omar Radwan <toxemicsquire4@gmail.com>
d95a56c6 9;;; Copyright © 2015 Pierre-Antoine Rault <par@rigelk.eu>
ad320b20 10;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
0bdc1671 11;;; Copyright © 2015, 2016 Christopher Allan Webber <cwebber@dustycloud.org>
345f0611 12;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
2b2f2fc1 13;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org>
6a44697d 14;;; Copyright © 2015, 2016 Leo Famulari <leo@famulari.name>
02a8a187 15;;; Copyright © 2015 Ben Woodcroft <donttrustben@gmail.com>
b9893908 16;;; Copyright © 2015, 2016 Erik Edrosa <erik.edrosa@gmail.com>
264ae686 17;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
1872f1bb 18;;; Copyright © 2015 Kyle Meyer <kyle@kyleam.com>
03f964a5 19;;; Copyright © 2015 Chris Marusich <cmmarusich@gmail.com>
a01b6da7
NK
20;;;
21;;; This file is part of GNU Guix.
22;;;
23;;; GNU Guix is free software; you can redistribute it and/or modify it
24;;; under the terms of the GNU General Public License as published by
25;;; the Free Software Foundation; either version 3 of the License, or (at
26;;; your option) any later version.
27;;;
28;;; GNU Guix is distributed in the hope that it will be useful, but
29;;; WITHOUT ANY WARRANTY; without even the implied warranty of
30;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
31;;; GNU General Public License for more details.
32;;;
33;;; You should have received a copy of the GNU General Public License
34;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
35
1ffa7090 36(define-module (gnu packages python)
011b18c3 37 #:use-module ((guix licenses)
45203542 38 #:select (asl2.0 bsd-4 bsd-3 bsd-2 non-copyleft cc0 x11 x11-style
b8050e71 39 gpl2 gpl2+ gpl3+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3+ agpl3+
7517e73c
LF
40 isc mpl2.0 psfl public-domain unlicense x11-style
41 zpl2.1))
bd3fa666 42 #:use-module ((guix licenses) #:select (expat zlib) #:prefix license:)
3fdc99da 43 #:use-module (gnu packages)
89b2e0b0 44 #:use-module (gnu packages attr)
d96034ed 45 #:use-module (gnu packages backup)
1ffa7090 46 #:use-module (gnu packages compression)
4ed20663 47 #:use-module (gnu packages databases)
5e1c9367 48 #:use-module (gnu packages file)
4ed20663 49 #:use-module (gnu packages fontutils)
4ed20663
AE
50 #:use-module (gnu packages gcc)
51 #:use-module (gnu packages ghostscript)
52 #:use-module (gnu packages glib)
53 #:use-module (gnu packages gtk)
421a80a2 54 #:use-module (gnu packages icu4c)
c937562e 55 #:use-module (gnu packages image)
4ed20663 56 #:use-module (gnu packages imagemagick)
b10ab723 57 #:use-module (gnu packages libffi)
89b2e0b0 58 #:use-module (gnu packages linux)
0da98533 59 #:use-module (gnu packages maths)
4ed20663 60 #:use-module (gnu packages multiprecision)
45203542 61 #:use-module (gnu packages networking)
be7134bf 62 #:use-module (gnu packages ncurses)
c9b1b4f9 63 #:use-module (gnu packages pcre)
4ed20663 64 #:use-module (gnu packages perl)
b10ab723 65 #:use-module (gnu packages pkg-config)
4ed20663 66 #:use-module (gnu packages readline)
c9b1b4f9 67 #:use-module (gnu packages statistics)
1c65314c
FB
68 #:use-module (gnu packages texlive)
69 #:use-module (gnu packages texinfo)
cc2b77df 70 #:use-module (gnu packages tls)
8d12be1e 71 #:use-module (gnu packages web)
ce0614dd 72 #:use-module (gnu packages base)
26b307e2 73 #:use-module (gnu packages xml)
6fa14469 74 #:use-module (gnu packages xorg)
0bdc1671 75 #:use-module (gnu packages xdisorg)
4ed20663 76 #:use-module (gnu packages zip)
afa181ff 77 #:use-module (gnu packages tcl)
a01b6da7
NK
78 #:use-module (guix packages)
79 #:use-module (guix download)
ea5456c8 80 #:use-module (guix git-download)
11bb85a1 81 #:use-module (guix utils)
acc26ff1 82 #:use-module (guix build-system gnu)
d8c4998f 83 #:use-module (guix build-system cmake)
898238b9 84 #:use-module (guix build-system python)
1c65314c
FB
85 #:use-module (guix build-system trivial)
86 #:use-module (srfi srfi-1))
a01b6da7 87
b24d1cfc 88(define-public python-2
a01b6da7
NK
89 (package
90 (name "python")
ff6f33cf 91 (version "2.7.10")
a01b6da7
NK
92 (source
93 (origin
94 (method url-fetch)
9b43a0ff 95 (uri (string-append "https://www.python.org/ftp/python/"
a01b6da7
NK
96 version "/Python-" version ".tar.xz"))
97 (sha256
98 (base32
6a20289d 99 "1h7zbrf9pkj29hlm18b10548ch9757f75m64l47sy75rh43p7lqw"))
dedc8320
LC
100 (patches (map search-patch
101 '("python-2.7-search-paths.patch"
9820a6d4 102 "python-2-deterministic-build-info.patch"
dedc8320 103 "python-2.7-source-date-epoch.patch")))))
02f0c3b2
LC
104 (outputs '("out"
105 "tk")) ;tkinter; adds 50 MiB to the closure
a01b6da7 106 (build-system gnu-build-system)
3fdc99da 107 (arguments
af807dea 108 `(#:tests? #f
ff6f33cf
ED
109 ;; 268 tests OK.
110 ;; 103 tests failed:
111 ;; test_distutils test_shutil test_signal test_site test_slice
112 ;; test_smtplib test_smtpnet test_socket test_socketserver
113 ;; test_softspace test_sort test_spwd test_sqlite test_ssl
114 ;; test_startfile test_stat test_str test_strftime test_string
115 ;; test_stringprep test_strop test_strptime test_strtod test_struct
116 ;; test_structmembers test_structseq test_subprocess test_sunau
117 ;; test_sunaudiodev test_sundry test_symtable test_syntax test_sys
118 ;; test_sys_setprofile test_sys_settrace test_sysconfig test_tarfile
119 ;; test_tcl test_telnetlib test_tempfile test_textwrap test_thread
120 ;; test_threaded_import test_threadedtempfile test_threading
121 ;; test_threading_local test_threadsignals test_time test_timeit
122 ;; test_timeout test_tk test_tokenize test_tools test_trace
123 ;; test_traceback test_transformer test_ttk_guionly test_ttk_textonly
124 ;; test_tuple test_typechecks test_ucn test_unary
125 ;; test_undocumented_details test_unicode test_unicode_file
126 ;; test_unicodedata test_univnewlines test_univnewlines2k test_unpack
127 ;; test_urllib test_urllib2 test_urllib2_localnet test_urllib2net
128 ;; test_urllibnet test_urlparse test_userdict test_userlist
129 ;; test_userstring test_uu test_uuid test_wait3 test_wait4
130 ;; test_warnings test_wave test_weakref test_weakset test_whichdb
131 ;; test_winreg test_winsound test_with test_wsgiref test_xdrlib
132 ;; test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc
133 ;; test_xpickle test_xrange test_zipfile test_zipfile64
134 ;; test_zipimport test_zipimport_support test_zlib
135 ;; 30 tests skipped:
136 ;; test_aepack test_al test_applesingle test_bsddb test_bsddb185
137 ;; test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk
138 ;; test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_crypt
139 ;; test_curses test_dl test_gdb test_gl test_idle test_imageop
140 ;; test_imgfile test_ioctl test_kqueue test_linuxaudiodev test_macos
141 ;; test_macostools test_msilib test_nis test_ossaudiodev
142 ;; test_scriptpackages
143 ;; 6 skips unexpected on linux2:
144 ;; test_bsddb test_bsddb3 test_crypt test_gdb test_idle test_ioctl
145 ;; One of the typical errors:
146 ;; test_unicode
147 ;; test test_unicode crashed -- <type 'exceptions.OSError'>: [Errno 2] No
148 ;; such file or directory
af807dea 149 #:test-target "test"
3fdc99da 150 #:configure-flags
6a20289d
LC
151 (list "--enable-shared" ;allow embedding
152 "--with-system-ffi" ;build ctypes
153 (string-append "LDFLAGS=-Wl,-rpath="
154 (assoc-ref %outputs "out") "/lib"))
fd982732 155
d2cc9c7c
LC
156 #:modules ((ice-9 ftw) (ice-9 match)
157 (guix build utils) (guix build gnu-build-system))
fd982732 158 #:phases
46472ecd
MW
159 (modify-phases %standard-phases
160 (add-before
161 'configure 'patch-lib-shells
162 (lambda _
163 ;; Filter for existing files, since some may not exist in all
164 ;; versions of python that are built with this recipe.
165 (substitute* (filter file-exists?
166 '("Lib/subprocess.py"
167 "Lib/popen2.py"
168 "Lib/distutils/tests/test_spawn.py"
169 "Lib/test/test_subprocess.py"))
170 (("/bin/sh") (which "sh")))
dedc8320
LC
171
172 ;; Use zero as the timestamp in .pyc files so that builds are
173 ;; deterministic. TODO: Remove it when this variable is set in
174 ;; gnu-build-system.scm.
a665996f 175 (setenv "SOURCE_DATE_EPOCH" "1")
46472ecd 176 #t))
5b4e2791
LC
177 (add-before 'configure 'do-not-record-configure-flags
178 (lambda* (#:key configure-flags #:allow-other-keys)
179 ;; Remove configure flags from the installed '_sysconfigdata.py'
180 ;; and 'Makefile' so we don't end up keeping references to the
181 ;; build tools.
182 ;;
183 ;; Preserve at least '--with-system-ffi' since otherwise the
184 ;; thing tries to build libffi, fails, and we end up with a
185 ;; Python that lacks ctypes.
186 (substitute* "configure"
187 (("^CONFIG_ARGS=.*$")
188 (format #f "CONFIG_ARGS='~a'\n"
189 (if (member "--with-system-ffi" configure-flags)
190 "--with-system-ffi"
191 ""))))
192 #t))
46472ecd
MW
193 (add-before
194 'check 'pre-check
195 (lambda _
196 ;; 'Lib/test/test_site.py' needs a valid $HOME
197 (setenv "HOME" (getcwd))
198 #t))
199 (add-after
200 'unpack 'set-source-file-times-to-1980
201 ;; XXX One of the tests uses a ZIP library to pack up some of the
202 ;; source tree, and fails with "ZIP does not support timestamps
203 ;; before 1980". Work around this by setting the file times in the
204 ;; source tree to sometime in early 1980.
205 (lambda _
206 (let ((circa-1980 (* 10 366 24 60 60)))
207 (ftw "." (lambda (file stat flag)
208 (utime file circa-1980 circa-1980)
209 #t))
02f0c3b2
LC
210 #t)))
211 (add-after 'install 'move-tk-inter
212 (lambda* (#:key outputs #:allow-other-keys)
213 ;; When Tkinter support is built move it to a separate output so
214 ;; that the main output doesn't contain a reference to Tcl/Tk.
215 (let ((out (assoc-ref outputs "out"))
216 (tk (assoc-ref outputs "tk")))
217 (when tk
218 (match (find-files out "tkinter.*\\.so")
219 ((tkinter.so)
220 ;; The .so is in OUT/lib/pythonX.Y/lib-dynload, but we
221 ;; want it under TK/lib/pythonX.Y/site-packages.
222 (let* ((len (string-length out))
223 (target (string-append
224 tk "/"
225 (string-drop
226 (dirname (dirname tkinter.so))
227 len)
228 "/site-packages")))
229 (install-file tkinter.so target)
230 (delete-file tkinter.so)))))
231 #t))))))
a01b6da7 232 (inputs
3fdc99da
CR
233 `(("bzip2" ,bzip2)
234 ("gdbm" ,gdbm)
b10ab723 235 ("libffi" ,libffi) ; for ctypes
b88e1b0a 236 ("sqlite" ,sqlite) ; for sqlite extension
a01b6da7 237 ("openssl" ,openssl)
3fdc99da 238 ("readline" ,readline)
afa181ff
LC
239 ("zlib" ,zlib)
240 ("tcl" ,tcl)
241 ("tk" ,tk))) ; for tkinter
b10ab723
CR
242 (native-inputs
243 `(("pkg-config" ,pkg-config)))
9be8d7c8
LC
244 (native-search-paths
245 (list (search-path-specification
246 (variable "PYTHONPATH")
af070955 247 (files '("lib/python2.7/site-packages")))))
a01b6da7 248 (home-page "http://python.org")
afa181ff 249 (synopsis "High-level, dynamically-typed programming language")
a01b6da7
NK
250 (description
251 "Python is a remarkably powerful dynamic programming language that
252is used in a wide variety of application domains. Some of its key
253distinguishing features include: clear, readable syntax; strong
254introspection capabilities; intuitive object orientation; natural
255expression of procedural code; full modularity, supporting hierarchical
256packages; exception-based error handling; and very high level dynamic
257data types.")
258 (license psfl)))
acc26ff1 259
b24d1cfc
AE
260(define-public python
261 (package (inherit python-2)
08c04509 262 (version "3.4.3")
717003e3
LC
263 (source (origin
264 (method url-fetch)
265 (uri (string-append "https://www.python.org/ftp/python/"
266 version "/Python-" version ".tar.xz"))
6a20289d
LC
267 (patches (map search-patch
268 '("python-fix-tests.patch"
269 ;; XXX Try removing this patch for python > 3.4.3
270 "python-disable-ssl-test.patch"
9820a6d4 271 "python-3-deterministic-build-info.patch"
6a20289d 272 "python-3-search-paths.patch")))
717003e3
LC
273 (patch-flags '("-p0"))
274 (sha256
275 (base32
08c04509 276 "1f4nm4z08sy0kqwisvv95l02crv6dyysdmx44p1mz3bn6csrdcxm"))))
1f434457
MW
277 (arguments (substitute-keyword-arguments (package-arguments python-2)
278 ((#:tests? _) #t)))
1aebc0cb
AE
279 (native-search-paths
280 (list (search-path-specification
281 (variable "PYTHONPATH")
0e05d01e
SB
282 (files (list (string-append "lib/python"
283 (version-major+minor version)
284 "/site-packages"))))))))
f26a77ff 285
95288fcc
LC
286;; Minimal variants of Python, mostly used to break the cycle between Tk and
287;; Python (Tk -> libxcb -> Python.)
288
289(define-public python2-minimal
290 (package (inherit python-2)
291 (name "python-minimal")
02f0c3b2 292 (outputs '("out"))
95288fcc
LC
293 (arguments
294 (substitute-keyword-arguments (package-arguments python-2)
c5a05e31
LC
295 ((#:configure-flags cf)
296 `(append ,cf '("--without-system-ffi")))))
95288fcc
LC
297 (inputs '()))) ;none of the optional dependencies
298
299(define-public python-minimal
898238b9 300 (package (inherit python)
95288fcc 301 (name "python-minimal")
02f0c3b2 302 (outputs '("out"))
95288fcc
LC
303 (arguments
304 (substitute-keyword-arguments (package-arguments python)
c5a05e31
LC
305 ((#:configure-flags cf)
306 `(append ,cf '("--without-system-ffi")))))
95288fcc
LC
307
308 ;; OpenSSL is a mandatory dependency of Python 3.x, for urllib;
309 ;; zlib is required by 'zipimport', used by pip.
310 (inputs `(("openssl" ,openssl)
311 ("zlib" ,zlib)))))
312
64cb064c
LC
313(define* (wrap-python3 python
314 #:optional
315 (name (string-append (package-name python) "-wrapper")))
898238b9 316 (package (inherit python)
95288fcc 317 (name name)
898238b9
AE
318 (source #f)
319 (build-system trivial-build-system)
02f0c3b2 320 (outputs '("out"))
3c0f2329 321 (propagated-inputs `(("python" ,python)))
898238b9
AE
322 (arguments
323 `(#:modules ((guix build utils))
324 #:builder
325 (begin
326 (use-modules (guix build utils))
327 (let ((bin (string-append (assoc-ref %outputs "out") "/bin"))
328 (python (string-append (assoc-ref %build-inputs "python") "/bin/")))
329 (mkdir-p bin)
330 (for-each
331 (lambda (old new)
332 (symlink (string-append python old)
333 (string-append bin "/" new)))
334 `("python3", "pydoc3", "idle3")
335 `("python", "pydoc", "idle"))))))
0d56e3e1
LC
336 (synopsis "Wrapper for the Python 3 commands")
337 (description
338 "This package provides wrappers for the commands of Python@tie{}3.x such
339that they can be invoked under their usual name---e.g., @command{python}
340instead of @command{python3}.")))
341
95288fcc
LC
342(define-public python-wrapper (wrap-python3 python))
343(define-public python-minimal-wrapper (wrap-python3 python-minimal))
898238b9 344
aaf625b8
RW
345(define-public python-psutil
346 (package
347 (name "python-psutil")
f56777be 348 (version "3.3.0")
aaf625b8
RW
349 (source
350 (origin
351 (method url-fetch)
f56777be 352 (uri (pypi-uri "psutil" version))
aaf625b8
RW
353 (sha256
354 (base32
f56777be 355 "11bd1555vf2ibjnmqf64im5cp55vcqfq45ccinm9ll3bs68na6s2"))))
aaf625b8
RW
356 (build-system python-build-system)
357 (native-inputs
358 `(("python-setuptools" ,python-setuptools)))
359 (home-page "https://pypi.python.org/pypi/psutil/")
360 (synopsis "Library for retrieving information on running processes")
361 (description
362 "psutil (Python system and process utilities) is a library for retrieving
363information on running processes and system utilization (CPU, memory, disks,
364network) in Python. It is useful mainly for system monitoring, profiling and
365limiting process resources and management of running processes. It implements
366many functionalities offered by command line tools such as: ps, top, lsof,
367netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
368pidof, tty, taskset, pmap.")
369 (license bsd-3)))
370
371(define-public python2-psutil
372 (package-with-python2 python-psutil))
898238b9 373
f9da1d8a
ED
374(define-public python-passlib
375 (package
376 (name "python-passlib")
690e8c66 377 (version "1.6.5")
f9da1d8a
ED
378 (source
379 (origin
380 (method url-fetch)
690e8c66 381 (uri (pypi-uri "passlib" version))
f9da1d8a
ED
382 (sha256
383 (base32
690e8c66 384 "1z27wdxs5rj5xhhqfzvzn3yg682irkxw6dcs5jj7mcf97psk8gd8"))))
f9da1d8a
ED
385 (build-system python-build-system)
386 (native-inputs
387 `(("python-nose" ,python-nose)
388 ("python-setuptools" ,python-setuptools)))
389 (inputs
390 `(("python-py-bcrypt" ,python-py-bcrypt)))
391 (arguments
392 `(#:phases
393 (alist-cons-before
394 'check 'set-PYTHON_EGG_CACHE
395 ;; some tests require access to "$HOME/.cython"
396 (lambda* _ (setenv "PYTHON_EGG_CACHE" "/tmp"))
397 %standard-phases)))
398 (home-page "https://bitbucket.org/ecollins/passlib")
399 (synopsis
400 "Comprehensive password hashing framework")
401 (description
402 "Passlib is a password hashing library for Python 2 & 3, which provides
403cross-platform implementations of over 30 password hashing algorithms, as well
404as a framework for managing existing password hashes. It's designed to be
405useful for a wide range of tasks, from verifying a hash found in /etc/shadow,
406to providing full-strength password hashing for multi-user application.")
407 (license bsd-3)))
408
409(define-public python2-passlib
410 (package-with-python2 python-passlib))
411
feb0d9c3
ED
412(define-public python-py-bcrypt
413 (package
414 (name "python-py-bcrypt")
415 (version "0.4")
416 (source
417 (origin
418 (method url-fetch)
419 (uri (string-append
420 "https://pypi.python.org/packages/source/p/py-bcrypt/py-bcrypt-"
421 version
422 ".tar.gz"))
423 (sha256
424 (base32
425 "0y6smdggwi5s72v6p1nn53dg6w05hna3d264cq6kas0lap73p8az"))))
426 (build-system python-build-system)
427 (native-inputs
428 `(("python-setuptools" ,python-setuptools)))
429 (home-page "https://code.google.com/p/py-bcrypt")
430 (synopsis
431 "Bcrypt password hashing and key derivation")
432 (description
433 "A python wrapper of OpenBSD's Blowfish password hashing code. This
434system hashes passwords using a version of Bruce Schneier's Blowfish block
435cipher with modifications designed to raise the cost of off-line password
436cracking and frustrate fast hardware implementation. The computation cost of
437the algorithm is parametised, so it can be increased as computers get faster.
438The intent is to make a compromise of a password database less likely to
439result in an attacker gaining knowledge of the plaintext passwords (e.g. using
440John the Ripper).")
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))))
445
446(define-public python2-py-bcrypt
447 (package-with-python2 python-py-bcrypt))
448
449
429fdea1
ED
450(define-public python-paramiko
451 (package
452 (name "python-paramiko")
453 (version "1.15.2")
454 (source
455 (origin
456 (method url-fetch)
457 (uri (string-append
458 "https://pypi.python.org/packages/source/p/paramiko/paramiko-"
459 version
460 ".tar.gz"))
461 (sha256
462 (base32
463 "0mbfzm9zlrz6mla9xakrm8wkll3x035f9rj3c5pbgjzfldqscmjg"))))
464 (build-system python-build-system)
465 (native-inputs
466 `(("python-setuptools" ,python-setuptools)))
a3fc12da
CR
467 (propagated-inputs
468 `(("python-pycrypto" ,python-pycrypto)))
429fdea1 469 (inputs
a3fc12da 470 `(("python-ecdsa" ,python-ecdsa)))
429fdea1
ED
471 (home-page "http://www.paramiko.org/")
472 (synopsis "SSHv2 protocol library")
473 (description "Paramiko is a python implementation of the SSHv2 protocol,
474providing both client and server functionality. While it leverages a Python C
475extension for low level cryptography (PyCrypto), Paramiko itself is a pure
476Python interface around SSH networking concepts.")
477 (license lgpl2.1+)))
478
479(define-public python2-paramiko
480 (package-with-python2 python-paramiko))
481
482
de73dbf6
ED
483(define-public python-httplib2
484 (package
485 (name "python-httplib2")
486 (version "0.9.1")
487 (source
488 (origin
489 (method url-fetch)
490 (uri (string-append
491 "https://pypi.python.org/packages/source/h/httplib2/httplib2-"
492 version
493 ".tar.gz"))
494 (sha256
495 (base32
496 "1xc3clbrf77r0600kja71j7hk1218sjiq0gfmb8vjdajka8kjqxw"))))
497 (build-system python-build-system)
498 (native-inputs
499 `(("python-setuptools" ,python-setuptools)))
500 (home-page
501 "https://github.com/jcgregorio/httplib2")
502 (synopsis "Comprehensive HTTP client library")
503 (description
504 "A comprehensive HTTP client library supporting many features left out of
505other HTTP libraries.")
506 (license license:expat)))
507
508(define-public python2-httplib2
509 (package-with-python2 python-httplib2))
510
67039875
ED
511(define-public python-ecdsa
512 (package
513 (name "python-ecdsa")
514 (version "0.13")
515 (source
516 (origin
517 (method url-fetch)
518 (uri (string-append
519 "https://pypi.python.org/packages/source/e/ecdsa/ecdsa-"
520 version
521 ".tar.gz"))
522 (sha256
523 (base32
524 "1yj31j0asmrx4an9xvsaj2icdmzy6pw0glfpqrrkrphwdpi1xkv4"))))
525 (build-system python-build-system)
526 (native-inputs
527 `(("python-setuptools" ,python-setuptools)))
528 (inputs
529 `(("openssl" ,openssl)))
530 (home-page
531 "http://github.com/warner/python-ecdsa")
532 (synopsis
533 "ECDSA cryptographic signature library (pure python)")
534 (description
535 "This is an easy-to-use implementation of ECDSA cryptography (Elliptic
536Curve Digital Signature Algorithm), implemented purely in Python. With this
537library, you can quickly create keypairs (signing key and verifying key), sign
538messages, and verify the signatures. The keys and signatures are very short,
539making them easy to handle and incorporate into other protocols.")
540 (license license:expat)))
541
542(define-public python2-ecdsa
543 (package-with-python2 python-ecdsa))
544
52323f32
ED
545(define-public python-ccm
546 (package
547 (name "python-ccm")
548 (version "2.0.4.1")
549 (source
550 (origin
551 (method url-fetch)
552 (uri (string-append
553 "https://pypi.python.org/packages/source/c/ccm/ccm-"
554 version
555 ".tar.gz"))
556 (sha256
557 (base32
558 "199jw221albs2iv6xczczq88fxnh0aw8hzmys8qkbzkd99dssng9"))))
559 (build-system python-build-system)
560 (native-inputs
561 `(("python-setuptools" ,python-setuptools)))
562 (inputs
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
568Cassandra cluster on localhost.")
569 (license asl2.0)))
570
571(define-public python2-ccm
572 (package-with-python2 python-ccm))
573
89114f39 574(define-public python-pytz
acc26ff1 575 (package
89114f39 576 (name "python-pytz")
b01bbbcf 577 (version "2015.7")
acc26ff1
CR
578 (source
579 (origin
580 (method url-fetch)
b01bbbcf 581 (uri (pypi-uri "pytz" version))
acc26ff1
CR
582 (sha256
583 (base32
b01bbbcf 584 "1spgdfp1ssya7v3kww7zp71xpj437skpqazcvqr3kr1p1brnw9lr"))))
acc26ff1 585 (build-system python-build-system)
8498b8cf 586 (arguments `(#:tests? #f)) ; no test target
b01bbbcf 587 (home-page "http://pythonhosted.org/pytz")
9e771e3b 588 (synopsis "Python timezone library")
acc26ff1
CR
589 (description
590 "This library allows accurate and cross platform timezone calculations
591using Python 2.4 or higher and provides access to the Olson timezone database.")
b01bbbcf 592 (license license:expat)))
5ace6e2f 593
89114f39 594(define-public python2-pytz
11bb85a1 595 (package-with-python2 python-pytz))
89114f39 596
fc50e9c6 597
89114f39 598(define-public python-babel
5ace6e2f 599 (package
89114f39 600 (name "python-babel")
b850a6d8 601 (version "2.1.1")
5ace6e2f
CR
602 (source
603 (origin
604 (method url-fetch)
b850a6d8 605 (uri (pypi-uri "Babel" version))
5ace6e2f
CR
606 (sha256
607 (base32
b850a6d8 608 "0j2jgfzj1a2m39pm2qc36fzr7a6p5ybwndi0xdzhi2p8zw7dbdkz"))))
5ace6e2f
CR
609 (build-system python-build-system)
610 (inputs
e1804763
AE
611 `(("python-pytz" ,python-pytz)
612 ("python-setuptools" ,python-setuptools)))
8498b8cf 613 (arguments `(#:tests? #f)) ; no test target
e1804763 614 (home-page "http://babel.pocoo.org/")
5ace6e2f
CR
615 (synopsis
616 "Tools for internationalizing Python applications")
617 (description
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
621access to various locale display names, localized number and date formatting,
622etc. ")
623 (license bsd-3)))
89114f39
AE
624
625(define-public python2-babel
11bb85a1 626 (package-with-python2 python-babel))
73adf220 627
ed377cc6
RW
628(define-public python2-backport-ssl-match-hostname
629 (package
630 (name "python2-backport-ssl-match-hostname")
f2d06d46 631 (version "3.5.0.1")
ed377cc6
RW
632 (source
633 (origin
634 (method url-fetch)
635 (uri (string-append
636 "https://pypi.python.org/packages/source/b/"
637 "backports.ssl_match_hostname/backports.ssl_match_hostname-"
638 version ".tar.gz"))
639 (sha256
640 (base32
f2d06d46 641 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
ed377cc6 642 (build-system python-build-system)
f2d06d46
EF
643 (arguments
644 `(#:python ,python-2
645 #:tests? #f)) ; no test target
ed377cc6
RW
646 (inputs
647 `(("python2-setuptools" ,python2-setuptools)))
f2d06d46
EF
648 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
649 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
ed377cc6
RW
650 (description
651 "This backport brings the ssl.match_hostname() function to users of
652earlier versions of Python. The function checks the hostname in the
653certificate returned by the server to which a connection has been established,
654and verifies that it matches the intended target hostname.")
655 (license psfl)))
656
ef5cbf9b
RW
657(define-public python-h5py
658 (package
659 (name "python-h5py")
660 (version "2.4.0")
661 (source
662 (origin
663 (method url-fetch)
664 (uri (string-append "https://pypi.python.org/packages/source/h/h5py/h5py-"
665 version ".tar.gz"))
666 (sha256
667 (base32
668 "0q4f9l8grf6pwp64xbv8bmyxx416s7h4522nnxac056ap3savbps"))))
669 (build-system python-build-system)
797e1401
RW
670 (arguments
671 `(#:tests? #f ; no test target
672 #:phases
673 (modify-phases %standard-phases
674 (add-after 'unpack 'fix-hdf5-paths
675 (lambda* (#:key inputs #:allow-other-keys)
676 (let ((prefix (assoc-ref inputs "hdf5")))
677 (substitute* "setup_build.py"
678 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
679 (string-append "['" prefix "/lib" "']"))
680 (("'/opt/local/include', '/usr/local/include'")
681 (string-append "'" prefix "/include" "'")))
682 (substitute* "setup_configure.py"
683 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
684 (string-append "['" prefix "/lib" "']")))
685 #t))))))
3c4010b1
RW
686 (propagated-inputs
687 `(("python-numpy" ,python-numpy)))
ef5cbf9b 688 (inputs
3c4010b1 689 `(("hdf5" ,hdf5)))
ef5cbf9b 690 (native-inputs
3c4010b1 691 `(("python-cython" ,python-cython)))
ef5cbf9b
RW
692 (home-page "http://www.h5py.org/")
693 (synopsis "Read and write HDF5 files from Python")
694 (description
695 "The h5py package provides both a high- and low-level interface to the
696HDF5 library from Python. The low-level interface is intended to be a
697complete wrapping of the HDF5 API, while the high-level component supports
698access to HDF5 files, datasets and groups using established Python and NumPy
699concepts.")
700 (license bsd-3)))
701
702(define-public python2-h5py
703 (let ((h5py (package-with-python2 python-h5py)))
704 (package (inherit h5py)
3c4010b1 705 (propagated-inputs
ef5cbf9b
RW
706 `(("python2-numpy" ,python2-numpy)
707 ,@(alist-delete
708 "python-numpy"
3c4010b1 709 (package-propagated-inputs h5py)))))))
ef5cbf9b 710
c1448c69
EB
711(define-public python-lockfile
712 (package
713 (name "python-lockfile")
714 (version "0.9.1")
715 (source
716 (origin
717 (method url-fetch)
718 (uri (string-append "https://pypi.python.org/packages/source/l/lockfile/"
719 "lockfile-" version ".tar.gz"))
720 (sha256
721 (base32
722 "0iwif7i84gwpvrnpv4brshdk8j6l77smvknm8k3bg77mj6f5ini3"))))
723 (build-system python-build-system)
724 (arguments '(#:test-target "check"))
725 (home-page "http://code.google.com/p/pylockfile/")
726 (synopsis "Platform-independent file locking module")
727 (description
728 "The lockfile package exports a LockFile class which provides a simple
729API for locking files.")
bd3fa666 730 (license license:expat)))
c1448c69
EB
731
732(define-public python2-lockfile
733 (package-with-python2 python-lockfile))
734
5a1a4bf6
EB
735(define-public python-mock
736 (package
737 (name "python-mock")
738 (version "1.0.1")
739 (source
740 (origin
741 (method url-fetch)
742 (uri (string-append "https://pypi.python.org/packages/source/m/mock/"
743 "mock-" version ".tar.gz"))
744 (sha256
745 (base32
746 "0kzlsbki6q0awf89rc287f3aj8x431lrajf160a70z0ikhnxsfdq"))))
747 (build-system python-build-system)
748 (arguments '(#:test-target "check"))
07af3e5e 749 (home-page "http://code.google.com/p/mock/")
9e771e3b 750 (synopsis "Python mocking and patching library for testing")
5a1a4bf6
EB
751 (description
752 "Mock is a library for testing in Python. It allows you to replace parts
753of your system under test with mock objects and make assertions about how they
754have been used.")
bd3fa666 755 (license license:expat)))
5a1a4bf6
EB
756
757(define-public python2-mock
758 (package-with-python2 python-mock))
759
fc50e9c6 760
73adf220
AE
761(define-public python-setuptools
762 (package
763 (name "python-setuptools")
62a9a23b 764 (version "18.3.1")
73adf220
AE
765 (source
766 (origin
767 (method url-fetch)
768 (uri (string-append "https://pypi.python.org/packages/source/s/setuptools/setuptools-"
769 version ".tar.gz"))
770 (sha256
771 (base32
62a9a23b 772 "0kc7rbav00ks6iaw14p38y81q12fx0lpkhgf5m97xc04f5r318ig"))))
73adf220 773 (build-system python-build-system)
d3d656c5
AE
774 ;; FIXME: Tests require pytest, which itself relies on setuptools.
775 ;; One could bootstrap with an internal untested setuptools.
73adf220 776 (arguments
824af8ca 777 `(#:tests? #f))
73adf220
AE
778 (home-page "https://pypi.python.org/pypi/setuptools")
779 (synopsis
780 "Library designed to facilitate packaging Python projects")
781 (description
782 "Setuptools is a fully-featured, stable library designed to facilitate
783packaging Python projects, where packaging includes:
784Python package and module definitions,
785distribution package metadata,
786test hooks,
787project installation,
788platform-specific details,
789Python 3 support.")
790 (license psfl)))
791
792(define-public python2-setuptools
793 (package-with-python2 python-setuptools))
fc50e9c6
AE
794
795
cafc3f5a
EB
796(define-public python-pycrypto
797 (package
798 (name "python-pycrypto")
799 (version "2.6.1")
800 (source
801 (origin
802 (method url-fetch)
803 (uri (string-append "https://pypi.python.org/packages/source/p/"
804 "pycrypto/pycrypto-" version ".tar.gz"))
805 (sha256
806 (base32
807 "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj"))))
808 (build-system python-build-system)
809 (native-inputs
810 `(("python-setuptools" ,python-setuptools)))
811 (inputs
812 `(("python" ,python)
813 ("gmp" ,gmp)))
814 (arguments
815 `(#:phases
816 (alist-cons-before
817 'build 'set-build-env
818 ;; pycrypto runs an autoconf configure script behind the scenes
819 (lambda _
820 (setenv "CONFIG_SHELL" (which "bash")))
821 %standard-phases)))
822 (home-page "http://www.pycrypto.org/")
823 (synopsis "Cryptographic modules for Python")
824 (description
825 "Pycrypto is a collection of both secure hash functions (such as SHA256
826and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal,
35b9e423 827etc.). The package is structured to make adding new modules easy.")
cafc3f5a
EB
828 (license public-domain)))
829
345f0611 830(define-public python2-pycrypto
1c0059da
EF
831 (let ((pycrypto (package-with-python2 python-pycrypto)))
832 (package (inherit pycrypto)
833 (inputs
834 `(("python" ,python-2)
835 ,@(alist-delete
836 "python"
837 (package-inputs pycrypto)))))))
345f0611 838
cafc3f5a
EB
839(define-public python-keyring
840 (package
841 (name "python-keyring")
664e6c3a 842 (version "5.7.1")
cafc3f5a
EB
843 (source
844 (origin
845 (method url-fetch)
664e6c3a 846 (uri (pypi-uri "keyring" version))
cafc3f5a
EB
847 (sha256
848 (base32
664e6c3a 849 "1h7a1r9ick7wdd0xb5p63413nvjadna2xawrsvmklsl5ddhm5wrx"))))
cafc3f5a
EB
850 (build-system python-build-system)
851 (native-inputs
664e6c3a
EF
852 `(("python-setuptools" ,python-setuptools)
853 ("python-setuptools-scm" ,python-setuptools-scm)
cafc3f5a
EB
854 ("python-mock" ,python-mock)))
855 (inputs
856 `(("python-pycrypto" ,python-pycrypto)))
857 (arguments
664e6c3a 858 `(#:tests? #f)) ;TODO: tests require pytest
cafc3f5a
EB
859 (home-page "http://bitbucket.org/kang/python-keyring-lib")
860 (synopsis "Store and access your passwords safely")
861 (description
862 "The Python keyring lib provides a easy way to access the system keyring
35b9e423 863service from python. It can be used in any application that needs safe
cafc3f5a
EB
864password storage.")
865 ;; "MIT" and PSF dual license
866 (license x11)))
867
d7af1069 868(define-public python2-keyring
44e30a76
EF
869 (let ((keyring (package-with-python2 python-keyring)))
870 (package (inherit keyring)
871 (inputs
872 `(("python2-pycrypto" ,python2-pycrypto))))))
d7af1069 873
a480bc41
EB
874(define-public python-six
875 (package
876 (name "python-six")
b6ab89ef 877 (version "1.10.0")
a480bc41
EB
878 (source
879 (origin
880 (method url-fetch)
b6ab89ef 881 (uri (pypi-uri "six" version))
a480bc41
EB
882 (sha256
883 (base32
b6ab89ef 884 "0snmb8xffb3vsma0z67i0h0w2g2dy0p3gsgh9gi4i0kgc5l8spqh"))))
a480bc41
EB
885 (build-system python-build-system)
886 (inputs
887 `(("python-setuptools" ,python-setuptools)))
888 (home-page "http://pypi.python.org/pypi/six/")
889 (synopsis "Python 2 and 3 compatibility utilities")
890 (description
35b9e423 891 "Six is a Python 2 and 3 compatibility library. It provides utility
a480bc41
EB
892functions for smoothing over the differences between the Python versions with
893the goal of writing Python code that is compatible on both Python versions.
35b9e423 894Six supports every Python version since 2.5. It is contained in only one
a480bc41
EB
895Python file, so it can be easily copied into your project.")
896 (license x11)))
897
0c20025c
AE
898(define-public python2-six
899 (package-with-python2 python-six))
900
cafc3f5a
EB
901(define-public python-dateutil-2
902 (package
903 (name "python-dateutil")
c2a9c1c0 904 (version "2.4.2")
cafc3f5a
EB
905 (source
906 (origin
907 (method url-fetch)
908 (uri (string-append "https://pypi.python.org/packages/source/p/"
909 name "/" name "-" version ".tar.gz"))
910 (sha256
911 (base32
c2a9c1c0 912 "0ggbm2z72p0nwjqgvpw8s5bqzwayqiqv2iws0x2a605m3mf4959y"))))
cafc3f5a
EB
913 (build-system python-build-system)
914 (inputs
915 `(("python-setuptools" ,python-setuptools)
916 ("python-six" ,python-six)))
917 (home-page "http://labix.org/python-dateutil")
918 (synopsis "Extensions to the standard datetime module")
919 (description
920 "The dateutil module provides powerful extensions to the standard
921datetime module, available in Python 2.3+.")
922 (license bsd-3)))
923
924(define-public python2-dateutil-2
925 (package-with-python2 python-dateutil-2))
926
fc50e9c6
AE
927(define-public python-dateutil
928 (package
929 (name "python-dateutil")
930 (version "1.5") ; last version for python < 3
931 (source
932 (origin
933 (method url-fetch)
cafc3f5a
EB
934 (uri (string-append "http://labix.org/download/python-dateutil/"
935 "python-dateutil-" version ".tar.gz"))
fc50e9c6
AE
936 (sha256
937 (base32
938 "0fqfglhy5khbvsipr3x7m6bcaqljh8xl5cw33vbfxy7qhmywm2n0"))))
939 (build-system python-build-system)
940 (inputs
941 `(("python-setuptools" ,python-setuptools)))
942 (home-page "http://labix.org/python-dateutil")
cafc3f5a 943 (synopsis "Extensions to the standard datetime module")
fc50e9c6
AE
944 (description
945 "The dateutil module provides powerful extensions to the standard
946datetime module, available in Python 2.3+.")
947 (license psfl)))
948
949(define-public python2-dateutil
950 (package-with-python2 python-dateutil))
1d08c01f 951
cafc3f5a
EB
952(define-public python-parsedatetime
953 (package
954 (name "python-parsedatetime")
4df1e30d 955 (version "1.5")
cafc3f5a
EB
956 (source
957 (origin
958 (method url-fetch)
959 (uri (string-append "https://pypi.python.org/packages/source/p/"
960 "parsedatetime/parsedatetime-" version ".tar.gz"))
961 (sha256
962 (base32
4df1e30d 963 "1as0mm4ql3z0324nc9bys2s1ngh507i317p16b79rx86wlmvx9ix"))))
cafc3f5a
EB
964 (build-system python-build-system)
965 (native-inputs
966 `(("python-setuptools" ,python-setuptools)))
cafc3f5a
EB
967 (home-page "http://github.com/bear/parsedatetime/")
968 (synopsis
969 "Parse human-readable date/time text")
970 (description
e881752c 971 "Parse human-readable date/time text.")
cafc3f5a
EB
972 (license asl2.0)))
973
38b8f9b2
LF
974(define-public python2-parsedatetime
975 (package-with-python2 python-parsedatetime))
976
d072efcb
RW
977(define-public python-pandas
978 (package
979 (name "python-pandas")
1b96f069 980 (version "0.16.2")
d072efcb
RW
981 (source
982 (origin
1b96f069
RW
983 (method url-fetch)
984 (uri (pypi-uri "pandas" version))
985 (sha256
986 (base32 "10agmrkps8bi5948vwpipfxds5kj1d076m9i0nhaxwqiw7gm6670"))))
d072efcb
RW
987 (build-system python-build-system)
988 (arguments
989 `(;; Three tests fail:
990 ;; - test_read_google
991 ;; - test_read_yahoo
992 ;; - test_month_range_union_tz_dateutil
993 #:tests? #f))
994 (propagated-inputs
995 `(("python-numpy" ,python-numpy)
996 ("python-pytz" ,python-pytz)
997 ("python-dateutil" ,python-dateutil-2)))
998 (native-inputs
999 `(("python-nose" ,python-nose)
1000 ("python-setuptools" ,python-setuptools)))
1001 (home-page "http://pandas.pydata.org")
1002 (synopsis "Data structures for data analysis, time series, and statistics")
1003 (description
1004 "Pandas is a Python package providing fast, flexible, and expressive data
1005structures designed to make working with structured (tabular,
1006multidimensional, potentially heterogeneous) and time series data both easy
1007and intuitive. It aims to be the fundamental high-level building block for
1008doing practical, real world data analysis in Python.")
1009 (license bsd-3)))
1010
1011(define-public python2-pandas
3cbe7d5e
FB
1012 (let ((pandas (package-with-python2 python-pandas)))
1013 (package (inherit pandas)
1014 (propagated-inputs
1015 `(("python2-numpy" ,python2-numpy)
1016 ,@(alist-delete "python-numpy"
1017 (package-propagated-inputs pandas)))))))
d072efcb 1018
cafc3f5a
EB
1019(define-public python-tzlocal
1020 (package
1021 (name "python-tzlocal")
226d3331 1022 (version "1.2")
cafc3f5a
EB
1023 (source
1024 (origin
1025 (method url-fetch)
226d3331 1026 (uri (pypi-uri "tzlocal" version))
cafc3f5a
EB
1027 (sha256
1028 (base32
226d3331 1029 "12wsw2fl3adrqrwghasld57bhqdrzn0crblqrci1p5acd0ni53s3"))))
cafc3f5a 1030 (build-system python-build-system)
226d3331 1031 (propagated-inputs `(("python-pytz" ,python-pytz)))
cafc3f5a
EB
1032 (home-page "https://github.com/regebro/tzlocal")
1033 (synopsis
35b9e423 1034 "Local timezone information for Python")
cafc3f5a
EB
1035 (description
1036 "Tzlocal returns a tzinfo object with the local timezone information.
1037This module attempts to fix a glaring hole in pytz, that there is no way to
1038get the local timezone information, unless you know the zoneinfo name, and
1039under several distributions that's hard or impossible to figure out.")
1040 (license cc0)))
1041
be7134bf
RW
1042(define-public python-pysam
1043 (package
1044 (name "python-pysam")
1045 (version "0.8.1")
1046 (source
1047 (origin
1048 (method url-fetch)
1049 (uri (string-append "https://pypi.python.org/packages/source/p/pysam/pysam-"
1050 version ".tar.gz"))
1051 (sha256
1052 (base32
1053 "1fb6i6hbpzxaxb62kyyp5alaidwhj40f7c6gwbhr6njzlqd5l459"))))
1054 (build-system python-build-system)
1055 (arguments
1056 `(#:tests? #f ; tests are excluded in the manifest
1057 #:phases
1058 (alist-cons-before
1059 'build 'set-flags
1060 (lambda _
1061 (setenv "LDFLAGS" "-lncurses")
1062 (setenv "CFLAGS" "-D_CURSES_LIB=1"))
1063 %standard-phases)))
1064 (inputs
1065 `(("python-cython" ,python-cython)
1066 ("python-setuptools" ,python-setuptools)
1067 ("ncurses" ,ncurses)
1068 ("zlib" ,zlib)))
1069 (home-page "https://github.com/pysam-developers/pysam")
1070 (synopsis "Python bindings to the SAMtools C API")
1071 (description
1072 "Pysam is a Python module for reading and manipulating files in the
1073SAM/BAM format. Pysam is a lightweight wrapper of the SAMtools C API. It
1074also includes an interface for tabix.")
bd3fa666 1075 (license license:expat)))
be7134bf
RW
1076
1077(define-public python2-pysam
1078 (package-with-python2 python-pysam))
1d08c01f
AE
1079
1080(define-public python2-pysqlite
1081 (package
1082 (name "python2-pysqlite")
fe476868 1083 (version "2.8.1")
1d08c01f
AE
1084 (source
1085 (origin
1086 (method url-fetch)
fe476868 1087 (uri (pypi-uri "pysqlite" version))
1d08c01f
AE
1088 (sha256
1089 (base32
fe476868 1090 "0rm0zqyb363y6wljhfmbxs16jjv7p8nk1d8zgq9sdwj6js7y3jkm"))))
1d08c01f
AE
1091 (build-system python-build-system)
1092 (inputs
1093 `(("sqlite" ,sqlite)))
1094 (arguments
1095 `(#:python ,python-2 ; incompatible with Python 3
1096 #:tests? #f)) ; no test target
fe476868 1097 (home-page "http://github.com/ghaering/pysqlite")
7a03af70 1098 (synopsis "SQLite bindings for Python")
1d08c01f
AE
1099 (description
1100 "Pysqlite provides SQLite bindings for Python that comply to the
1101Database API 2.0T.")
ed0cdf83 1102 (license license:zlib)))
1d08c01f 1103
2875caf5
AE
1104
1105(define-public python2-mechanize
1106 (package
1107 (name "python2-mechanize")
1108 (version "0.2.5")
1109 (source
1110 (origin
1111 (method url-fetch)
1112 (uri (string-append "https://pypi.python.org/packages/source/m/mechanize/mechanize-"
1113 version ".tar.gz"))
1114 (sha256
1115 (base32
1116 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1117 (build-system python-build-system)
1118 (inputs
1119 `(("python2-setuptools" ,python2-setuptools)))
1120 (arguments
1121 `(#:python ,python-2 ; apparently incompatible with Python 3
1122 #:tests? #f))
1123 ;; test fails with message
1124 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1125 ;; (python-3.3.2) or
1126 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1127 ;; (python-2.7.5).
1128 ;; The source code is from March 2011 and probably not up-to-date
1129 ;; with respect to python unit tests.
1130 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1131 (synopsis
1132 "Stateful programmatic web browsing in Python")
1133 (description
1134 "Mechanize implements stateful programmatic web browsing in Python,
1135after Andy Lester’s Perl module WWW::Mechanize.")
166191b3 1136 (license (non-copyleft "file://COPYING"
e881752c 1137 "See COPYING in the distribution."))))
2875caf5 1138
0352532e
AE
1139
1140(define-public python-simplejson
1141 (package
1142 (name "python-simplejson")
1143 (version "3.3.0")
1144 (source
1145 (origin
1146 (method url-fetch)
1147 (uri (string-append "https://pypi.python.org/packages/source/s/simplejson/simplejson-"
1148 version ".tar.gz"))
1149 (sha256
1150 (base32
1151 "07wsry5j44l5zzm74l4j2bvasiq8n5m32f31n2p7c68i5vc6p2ks"))))
1152 (build-system python-build-system)
1153 (home-page "http://simplejson.readthedocs.org/en/latest/")
1154 (synopsis
1155 "Json library for Python")
1156 (description
e881752c
AK
1157 "JSON (JavaScript Object Notation) is a subset of JavaScript
1158syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1159format.
0352532e
AE
1160
1161Simplejson exposes an API familiar to users of the standard library marshal
1162and pickle modules. It is the externally maintained version of the json
1163library contained in Python 2.6, but maintains compatibility with Python 2.5
1164and (currently) has significant performance advantages, even without using
1165the optional C extension for speedups. Simplejson is also supported on
1166Python 3.3+.")
1167 (license x11)))
1168
1169(define-public python2-simplejson
1170 (package-with-python2 python-simplejson))
421a80a2
AE
1171
1172
1173(define-public python2-pyicu
1174 (package
1175 (name "python2-pyicu")
569ac046 1176 (version "1.8")
421a80a2
AE
1177 (source
1178 (origin
1179 (method url-fetch)
1180 (uri (string-append "https://pypi.python.org/packages/source/P/PyICU/PyICU-"
1181 version ".tar.gz"))
1182 (sha256
1183 (base32
569ac046 1184 "1y361x82lnh9k9srmdx3q92z5iag112z7r5fxm0n1sfwb349yjdw"))))
421a80a2
AE
1185 (build-system python-build-system)
1186 (inputs
1187 `(("icu4c" ,icu4c)))
1188 (arguments
1189 `(#:python ,python-2 ; Python 3 works also, but needs special care for
1190 ; linking with libpython3.3m
1191 #:tests? #f)) ; no check target
1192 (home-page "http://pyicu.osafoundation.org/")
9e771e3b 1193 (synopsis "Python extension wrapping the ICU C++ API")
421a80a2
AE
1194 (description
1195 "PyICU is a python extension wrapping the ICU C++ API.")
1196 (license x11)))
cc20a22a
LC
1197
1198(define-public python2-dogtail
1199 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1200 ;; spaces in indentation" with Python 3.
1201 (package
1202 (name "python2-dogtail")
1203 (version "0.8.2")
1204 (source (origin
1205 (method url-fetch)
1206 (uri (string-append
1207 "https://fedorahosted.org/released/dogtail/dogtail-"
1208 version ".tar.gz"))
1209 (sha256
1210 (base32
1211 "1yc4cg7ip87z15gyd4wy2vzbywrjc52a3m8r8gqy2b50d65llcg1"))))
1212 (build-system python-build-system)
1213 (arguments `(#:python ,python-2
1214 #:tests? #f)) ; invalid command "test"
1215 (home-page "https://fedorahosted.org/dogtail/")
1216 (synopsis "GUI test tool and automation framework written in ​Python")
1217 (description
35b9e423 1218 "Dogtail is a GUI test tool and automation framework written in Python.
cc20a22a
LC
1219It uses Accessibility (a11y) technologies to communicate with desktop
1220applications. dogtail scripts are written in Python and executed like any
1221other Python program.")
1222 (license gpl2+)))
515e6878 1223
011b18c3
LC
1224(define-public python2-empy
1225 (package
1226 (name "python2-empy")
1227 (version "3.3")
1228 (source (origin
1229 (method url-fetch)
1230 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1231 version ".tar.gz"))
1232 (sha256
1233 (base32
1234 "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6"))))
1235 (build-system python-build-system)
1236 (arguments
1237 `(#:python ,python-2
1238 #:phases (alist-replace
1239 'check
1240 (lambda _
1241 (zero? (system* "./test.sh")))
1242 %standard-phases)))
1243 (home-page "http://www.alcyone.com/software/empy/")
1244 (synopsis "Templating system for Python")
1245 (description
1246 "EmPy is a system for embedding Python expressions and statements in
1247template text; it takes an EmPy source file, processes it, and produces
1248output. This is accomplished via expansions, which are special signals to the
1cd4027c 1249EmPy system and are set off by a special prefix (by default the at sign, @@).
011b18c3
LC
1250EmPy can expand arbitrary Python expressions and statements in this way, as
1251well as a variety of special forms. Textual data not explicitly delimited in
1252this way is sent unaffected to the output, allowing Python to be used in
1253effect as a markup language. Also supported are callbacks via hooks,
1254recording and playback via diversions, and dynamic, chainable filters. The
1255system is highly configurable via command line options and embedded
1256commands.")
1257 (license lgpl2.1+)))
1258
8deeda0c
LC
1259(define-public python2-element-tree
1260 (package
1261 (name "python2-element-tree")
1262 (version "1.2.6")
1263 (source (origin
1264 (method url-fetch)
1265 (uri (string-append
1266 "http://effbot.org/media/downloads/elementtree-"
1267 version "-20050316.tar.gz"))
1268 (sha256
1269 (base32
1270 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1271 (build-system python-build-system)
1272 (arguments
1273 `(#:python ,python-2 ; seems to be part of Python 3
1274 #:tests? #f)) ; no 'test' sub-command
1275 (synopsis "Toolkit for XML processing in Python")
1276 (description
1277 "ElementTree is a Python library supporting lightweight XML processing.")
1278 (home-page "http://effbot.org/zone/element-index.htm")
1279 (license (x11-style "http://docs.python.org/2/license.html"
1280 "Like \"CWI LICENSE AGREEMENT FOR PYTHON \
12810.9.0 THROUGH 1.2\"."))))
1282
1283(define-public python2-pybugz
1284 (package
1285 (name "python2-pybugz")
1286 (version "0.6.11")
1287 (source (origin
1288 (method url-fetch)
1289 (uri (string-append
1290 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1291 version ".tar.gz"))
1292 (sha256
1293 (base32
6f194a1e
LC
1294 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
1295 (patches (map search-patch
1296 (list "pybugz-stty.patch"
1297 "pybugz-encode-error.patch")))))
8deeda0c
LC
1298 (build-system python-build-system)
1299 (arguments
1300 `(#:python ,python-2 ; SyntaxError with Python 3
1301 #:tests? #f)) ; no 'test' sub-command
1302 (inputs `(("element-tree" ,python2-element-tree)))
1303 (synopsis "Python and command-line interface to Bugzilla")
1304 (description
1305 "PyBugz is a Python library and command-line tool to query the Bugzilla
1306bug tracking system. It is meant as an aid to speed up interaction with the
1307bug tracker.")
1308 (home-page "http://www.liquidx.net/pybugz/")
1309 (license gpl2)))
1310
a480bc41
EB
1311(define-public python-enum34
1312 (package
1313 (name "python-enum34")
1314 (version "1.0")
1315 (source
1316 (origin
1317 (method url-fetch)
1318 (uri (string-append "https://pypi.python.org/packages/source/e/"
1319 "enum34/enum34-" version ".tar.gz"))
1320 (sha256
1321 (base32
1322 "0dg6mpg9n4g9diyrbnbb5vd9d1qw9f265zwhknqy0mxh0cvmjjrq"))))
1323 (build-system python-build-system)
1324 (inputs
1325 `(("python-setuptools" ,python-setuptools)))
1326 (arguments
1327 `(#:phases
1328 (alist-replace
1329 'check
1330 (lambda _ (zero? (system* "python" "enum/test_enum.py")))
1331 %standard-phases)))
1332 (home-page "https://pypi.python.org/pypi/enum34")
1333 (synopsis "Backported Python 3.4 Enum")
1334 (description
1335 "Enum34 is the new Python stdlib enum module available in Python 3.4
1336backported for previous versions of Python from 2.4 to 3.3.")
1337 (license bsd-3)))
1338
1339(define-public python-parse-type
1340 (package
1341 (name "python-parse-type")
1342 (version "0.3.4")
1343 (source
1344 (origin
1345 (method url-fetch)
1346 (uri (string-append "https://pypi.python.org/packages/source/p/"
1347 "parse_type/parse_type-" version ".tar.gz"))
1348 (sha256
1349 (base32
1350 "0iv1c34npr4iynwpgv1vkjx9rjd18a85ir8c01gc5f7wp8iv7l1x"))))
1351 (build-system python-build-system)
1352 (inputs
1353 `(("python-setuptools" ,python-setuptools)
1354 ("python-six" ,python-six)
1355 ("python-parse" ,python-parse)
1356 ("python-enum34" ,python-enum34))) ;required for python<3.4
1357 (arguments '(#:tests? #f)) ;TODO: tests require pytest
1358 (home-page "https://github.com/jenisys/parse_type")
1359 (synopsis "Extended parse module")
1360 (description
1361 "Parse_type extends the python parse module.")
1362 (license bsd-3)))
1363
1364(define-public python-parse
1365 (package
1366 (name "python-parse")
1367 (version "1.6.4")
1368 (source
1369 (origin
1370 (method url-fetch)
1371 (uri (string-append "https://pypi.python.org/packages/source/p/"
1372 "parse/parse-" version ".tar.gz"))
1373 (sha256
1374 (base32
1375 "0m30q64l6szl7s9mhvqy64w2fdhdn8lb91fmacjiwbv3479cmk57"))))
1376 (build-system python-build-system)
1377 (arguments
1378 `(#:phases
1379 (alist-replace
1380 'check
1381 (lambda _ (zero? (system* "python" "test_parse.py")))
1382 %standard-phases)))
1383 (home-page "https://github.com/r1chardj0n3s/parse")
1384 (synopsis "Parse strings")
1385 (description
1386 "Parse strings using a specification based on the Python format()
1387syntax.")
1388 (license x11)))
1389
1390
515e6878
LC
1391(define-public scons
1392 (package
1393 (name "scons")
a3f61425 1394 (version "2.3.4")
515e6878
LC
1395 (source (origin
1396 (method url-fetch)
1397 (uri (string-append "mirror://sourceforge/scons/scons-"
1398 version ".tar.gz"))
1399 (sha256
1400 (base32
a3f61425 1401 "0hdlci43wjz8maryj83mz04ir6rwcdrrzpd7cpzvdlzycqhdfmsb"))))
515e6878
LC
1402 (build-system python-build-system)
1403 (arguments
1404 ;; With Python 3.x, fails to build with a syntax error.
1405 `(#:python ,python-2
1406 #:tests? #f)) ; no 'python setup.py test' command
1407 (home-page "http://scons.org/")
1408 (synopsis "Software construction tool written in Python")
1409 (description
1410 "SCons is a software construction tool. Think of SCons as an improved,
1411cross-platform substitute for the classic Make utility with integrated
1412functionality similar to autoconf/automake and compiler caches such as ccache.
1413In short, SCons is an easier, more reliable and faster way to build
1414software.")
1415 (license x11)))
011b18c3 1416
c15a5c0e
DT
1417(define-public python-extras
1418 (package
1419 (name "python-extras")
1420 (version "0.0.3")
1421 (source
1422 (origin
1423 (method url-fetch)
1424 (uri (string-append
1425 "https://pypi.python.org/packages/source/e/extras/extras-"
1426 version ".tar.gz"))
1427 (sha256
1428 (base32
1429 "1h7zx4dfyclalg0fqnfjijpn0f793a9mx8sy3b27gd31nr6dhq3s"))))
1430 (build-system python-build-system)
1431 (inputs
1432 `(("python-setuptools" ,python-setuptools)))
1433 (arguments
1434 ;; error in setup.cfg: command 'test' has no such option 'buffer'
1435 '(#:tests? #f))
1436 (home-page "https://github.com/testing-cabal/extras")
1437 (synopsis "Useful extensions to the Python standard library")
1438 (description
1439 "Extras is a set of extensions to the Python standard library.")
bd3fa666 1440 (license license:expat)))
c15a5c0e
DT
1441
1442(define-public python2-extras
1443 (package-with-python2 python-extras))
1444
56ea0efd
DT
1445(define-public python-mimeparse
1446 (package
1447 (name "python-mimeparse")
1448 (version "0.1.4")
1449 (source
1450 (origin
1451 (method url-fetch)
1452 (uri (string-append
1453 "https://pypi.python.org/packages/source/p/python-mimeparse/python-mimeparse-"
1454 version ".tar.gz"))
1455 (sha256
1456 (base32
1457 "1hyxg09kaj02ri0rmwjqi86wk4nd1akvv7n0dx77azz76wga4s9w"))))
1458 (build-system python-build-system)
1459 (inputs
1460 `(("python-setuptools" ,python-setuptools)))
1461 (arguments
1462 '(#:tests? #f)) ; no setup.py test command
1463 (home-page
1464 "https://github.com/dbtsai/python-mimeparse")
9e771e3b 1465 (synopsis "Python library for parsing MIME types")
56ea0efd
DT
1466 (description
1467 "Mimeparse provides basic functions for parsing MIME type names and
1468matching them against a list of media-ranges.")
bd3fa666 1469 (license license:expat)))
56ea0efd
DT
1470
1471(define-public python2-mimeparse
1472 (package-with-python2 python-mimeparse))
1473
4435427e
DT
1474(define-public python-nose
1475 (package
1476 (name "python-nose")
f7cb9841 1477 (version "1.3.7")
4435427e
DT
1478 (source
1479 (origin
1480 (method url-fetch)
f7cb9841 1481 (uri (pypi-uri "nose" version))
4435427e
DT
1482 (sha256
1483 (base32
f7cb9841 1484 "164a43k7k2wsqqk1s6vavcdamvss4mz0vd6pwzv2h9n8rgwzxgzi"))))
4435427e
DT
1485 (build-system python-build-system)
1486 (inputs
1487 `(("python-setuptools" ,python-setuptools)))
1488 (arguments
1489 '(#:tests? #f)) ; FIXME: test suite fails
1490 (home-page "http://readthedocs.org/docs/nose/")
1491 (synopsis "Python testing library")
1492 (description
1493 "Nose extends the unittest library to make testing easier.")
1494 (license lgpl2.0+)))
1495
1496(define-public python2-nose
1497 (package-with-python2 python-nose))
1498
6cd9c356
DT
1499(define-public python-unittest2
1500 (package
1501 (name "python-unittest2")
1502 (version "0.5.1")
1503 (source
1504 (origin
1505 (method url-fetch)
1506 (uri (string-append
1507 "https://pypi.python.org/packages/source/u/unittest2py3k/unittest2py3k-"
1508 version ".tar.gz"))
1509 (sha256
1510 (base32
1511 "00yl6lskygcrddx5zspkhr0ibgvpknl4678kkm6s626539grq93q"))))
1512 (build-system python-build-system)
1513 (inputs
1514 `(("python-setuptools" ,python-setuptools)))
1515 (home-page "http://pypi.python.org/pypi/unittest2")
1516 (synopsis "Python unit testing library")
1517 (description
1518 "Unittest2 is a replacement for the unittest module in the Python
1519standard library.")
1520 (license psfl)))
1521
1522(define-public python2-unittest2
1523 (package (inherit python-unittest2)
1524 (name "python2-unittest2")
1525 (version "0.5.1")
1526 (source
1527 (origin
1528 (method url-fetch)
1529 (uri (string-append
1530 "https://pypi.python.org/packages/source/u/unittest2/unittest2-"
1531 version ".tar.gz"))
1532 (sha256
1533 (base32
1534 "0wbs4i4x3x7klr3v35ss6p9mcqz883i1xgcpkhvl7n2lyv6yhpda"))))
1535 (inputs
7957fe6c 1536 `(("python2-setuptools" ,python2-setuptools)))
6cd9c356
DT
1537 (arguments
1538 `(#:python ,python-2
1539 #:tests? #f)))) ; no setup.py test command
1540
542ad60f
DT
1541(define-public python-py
1542 (package
1543 (name "python-py")
71c8a804 1544 (version "1.4.31")
542ad60f
DT
1545 (source
1546 (origin
1547 (method url-fetch)
71c8a804 1548 (uri (pypi-uri "py" version))
542ad60f
DT
1549 (sha256
1550 (base32
71c8a804 1551 "0561gz2w3i825gyl42mcq14y3dcgkapfiv5zv9a2bz15qxiijl56"))))
542ad60f
DT
1552 (build-system python-build-system)
1553 (inputs
1554 `(("python-setuptools" ,python-setuptools)))
1555 (home-page "http://pylib.readthedocs.org/")
1556 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1557 (description
1558 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1559code introspection, and logging.")
bd3fa666 1560 (license license:expat)))
542ad60f
DT
1561
1562(define-public python2-py
1563 (package-with-python2 python-py))
1564
855d4761
DT
1565(define-public python-pytest
1566 (package
1567 (name "python-pytest")
1568 (version "2.6.1")
1569 (source
1570 (origin
1571 (method url-fetch)
1572 (uri (string-append
1573 "https://pypi.python.org/packages/source/p/pytest/pytest-"
1574 version ".tar.gz"))
1575 (sha256
1576 (base32
1577 "0g2w4p0n42wvz8rq4k6gnzpkakgz3g8sfanxk8jrsra9675snkcr"))
1578 (modules '((guix build utils)))
1579 (snippet
1580 ;; One of the tests involves the /usr directory, so it fails.
1581 '(substitute* "testing/test_argcomplete.py"
1582 (("def test_remove_dir_prefix\\(self\\):")
1583 "@pytest.mark.xfail\n def test_remove_dir_prefix(self):")))))
1584 (build-system python-build-system)
1585 (inputs
1586 `(("python-setuptools" ,python-setuptools)
1587 ("python-py" ,python-py)
1588 ("python-nose" ,python-nose)
1589 ("python-mock" ,python-mock)))
1590 (home-page "http://pytest.org")
1591 (synopsis "Python testing library")
1592 (description
1593 "Pytest is a testing tool that provides auto-discovery of test modules
1594and functions, detailed info on failing assert statements, modular fixtures,
1595and many external plugins.")
bd3fa666 1596 (license license:expat)))
855d4761
DT
1597
1598(define-public python2-pytest
1599 (package-with-python2 python-pytest))
1600
358c3d61
EF
1601(define-public python-pytest-cov
1602 (package
1603 (name "python-pytest-cov")
1604 (version "2.2.0")
1605 (source
1606 (origin
1607 (method url-fetch)
1608 (uri (pypi-uri "pytest-cov" version))
1609 (sha256
1610 (base32
1611 "1lf9jsmhqk5nc4w3kzwglmdzjvmi7ajvrsnwv826j3bn0wzx8c92"))))
10468636
EF
1612 (build-system python-build-system)
1613 (propagated-inputs
1614 `(("python-coverage" ,python-coverage)
1615 ("python-pytest" ,python-pytest)))
1616 (native-inputs
1617 `(("python-setuptools" ,python-setuptools)))
1618 (home-page "https://github.com/pytest-dev/pytest-cov")
1619 (synopsis "Pytest plugin for measuring coverage")
1620 (description
1621 "Pytest-cov produces coverage reports. It supports centralised testing and
1622distributed testing in both @code{load} and @code{each} modes. It also
1623supports coverage of subprocesses.")
358c3d61
EF
1624 (license license:expat)))
1625
1626(define-public python2-pytest-cov
1627 (package-with-python2 python-pytest-cov))
1628
6784f2e3
RW
1629(define-public python-pytest-runner
1630 (package
1631 (name "python-pytest-runner")
1632 (version "2.6.2")
1633 (source
1634 (origin
1635 (method url-fetch)
1636 (uri (string-append "https://pypi.python.org/packages/source/p/"
1637 "pytest-runner/pytest-runner-"
1638 version ".tar.gz"))
1639 (sha256
1640 (base32
1641 "1nwcqx0l3fv52kv8526wy8ypzghbq96c96di318d98d3wh7a8xg7"))))
1642 (build-system python-build-system)
1643 (arguments
1644 `(#:phases
1645 (modify-phases %standard-phases
1646 ;; The fancy way of setting the version with setuptools_scm does not
1647 ;; seem to work here.
1648 (add-after 'unpack 'set-version
1649 (lambda _
1650 (substitute* "docs/conf.py"
1651 (("version = setuptools_scm\\.get_version\\(root='\\.\\.')")
1652 (string-append "version = \"" ,version "\"")))
1653 #t)))))
1654 (native-inputs
1655 `(("python-pytest" ,python-pytest)
d50d097d 1656 ("python-setuptools" ,python-setuptools)
6784f2e3
RW
1657 ("python-setuptools-scm" ,python-setuptools-scm)))
1658 (home-page "https://bitbucket.org/pytest-dev/pytest-runner")
1659 (synopsis "Invoke py.test as a distutils command")
1660 (description
1661 "This package provides a @command{pytest-runner} command that
1662@file{setup.py} files can use to run tests.")
1663 (license license:expat)))
1664
1665(define-public python2-pytest-runner
1666 (package-with-python2 python-pytest-runner))
1667
84d24017
DT
1668(define-public python-scripttest
1669 (package
1670 (name "python-scripttest")
1671 (version "1.3")
1672 (source
1673 (origin
1674 (method url-fetch)
1675 (uri (string-append
1676 "https://pypi.python.org/packages/source/s/scripttest/scripttest-"
1677 version ".tar.gz"))
1678 (sha256
1679 (base32
1680 "0f4w84k8ck82syys7yg9maz93mqzc8p5ymis941x034v44jzq74m"))))
1681 (build-system python-build-system)
1682 (inputs
1683 `(("python-setuptools" ,python-setuptools)
1684 ("python-pytest" ,python-pytest)))
1685 (home-page "http://pythonpaste.org/scripttest/")
1686 (synopsis "Python library to test command-line scripts")
1687 (description "Scripttest is a Python helper library for testing
1688interactive command-line applications. With it you can run a script in a
1689subprocess and see the output as well as any file modifications.")
bd3fa666 1690 (license license:expat)))
84d24017
DT
1691
1692(define-public python2-scripttest
1693 (package-with-python2 python-scripttest))
1694
d8fa80e1
DT
1695(define-public python-testtools
1696 (package
1697 (name "python-testtools")
1698 (version "1.0.0")
1699 (source
1700 (origin
1701 (method url-fetch)
1702 (uri (string-append
1703 "https://pypi.python.org/packages/source/t/testtools/testtools-"
1704 version ".tar.gz"))
1705 (sha256
1706 (base32
1707 "1dyml28ykpl5jb9khdmcdvhy1cxqingys6qvj2k04fzlaj6z3bbx"))))
1708 (build-system python-build-system)
0e88cbf8
CR
1709 (propagated-inputs
1710 `(("python-mimeparse" ,python-mimeparse)))
d8fa80e1
DT
1711 (inputs
1712 `(("python-setuptools" ,python-setuptools)
d8fa80e1
DT
1713 ("python-extras" ,python-extras)))
1714 (home-page "https://github.com/testing-cabal/testtools")
1715 (synopsis
1716 "Extensions to the Python standard library unit testing framework")
1717 (description
1718 "Testtools extends the Python standard library unit testing framework to
1719provide matchers, more debugging information, and cross-Python
1720compatibility.")
1721 (license psfl)))
1722
1723(define-public python2-testtools
1724 (package-with-python2 python-testtools))
1725
5bf3afea
DT
1726(define-public python-testscenarios
1727 (package
1728 (name "python-testscenarios")
1729 (version "0.4")
1730 (source
1731 (origin
1732 (method url-fetch)
1733 (uri (string-append
1734 "https://pypi.python.org/packages/source/t/testscenarios/testscenarios-"
1735 version ".tar.gz"))
1736 (sha256
1737 (base32
1738 "1671jvrvqlmbnc42j7pc5y6vc37q44aiwrq0zic652pxyy2fxvjg"))))
1739 (build-system python-build-system)
1740 (inputs
1741 `(("python-setuptools" ,python-setuptools)
1742 ("python-testtools" ,python-testtools)
1743 ("python-mimeparse" ,python-mimeparse)))
1744 (home-page "https://launchpad.net/testscenarios")
1745 (synopsis "Pyunit extension for dependency injection")
1746 (description
1747 "Testscenarios provides clean dependency injection for Python unittest
1748style tests.")
1749 (license (list bsd-3 asl2.0)))) ; at the user's option
1750
1751(define-public python2-testscenarios
1752 (package-with-python2 python-testscenarios))
1753
dac79ecc
DT
1754(define-public python-testresources
1755 (package
1756 (name "python-testresources")
1757 (version "0.2.7")
1758 (source
1759 (origin
1760 (method url-fetch)
1761 (uri (string-append
1762 "https://pypi.python.org/packages/source/t/testresources/testresources-"
1763 version ".tar.gz"))
1764 (sha256
1765 (base32
1766 "0cbj3plbllyz42c4b5xxgwaa7mml54lakslrn4kkhinxhdri22md"))))
1767 (build-system python-build-system)
1768 (inputs
1769 `(("python-setuptools" ,python-setuptools)))
1770 (home-page "https://launchpad.net/testresources")
1771 (synopsis
1772 "Pyunit extension for managing test resources")
1773 (description
1774 "Testresources is an extension to Python's unittest to allow declarative
1775use of resources by test cases.")
1776 (license (list bsd-3 asl2.0)))) ; at the user's option
1777
1778(define-public python2-testresources
1779 (package-with-python2 python-testresources))
1780
070ab058
DT
1781(define-public python-subunit
1782 (package
1783 (name "python-subunit")
1784 (version "0.0.21")
1785 (source
1786 (origin
1787 (method url-fetch)
1788 (uri (string-append
1789 "https://pypi.python.org/packages/source/p/python-subunit/python-subunit-"
1790 version ".tar.gz"))
1791 (sha256
1792 (base32
1793 "1nkw9wfbvizmpajbj3in8ns07g7lwkiv8hip14jjlwk3cacls6jv"))))
1794 (build-system python-build-system)
1795 (inputs
1796 `(("python-setuptools" ,python-setuptools)
1797 ("python-testtools" ,python-testtools)
1798 ("python-mimeparse" ,python-mimeparse)
1799 ("python-testscenarios" ,python-testscenarios)))
1800 (home-page "http://launchpad.net/subunit")
1801 (synopsis "Python implementation of the subunit protocol")
1802 (description
1803 "Python-subunit is a Python implementation of the subunit test streaming
1804protocol.")
1805 (license (list bsd-3 asl2.0)))) ; at the user's option
1806
1807(define-public python2-subunit
1808 (package-with-python2 python-subunit))
1809
7787ef76
CR
1810;; Recent versions of python-fixtures need a recent version of python-pbr,
1811;; which needs a recent version of python-fixtures. To fix this circular
1812;; dependency, we keep old versions of python-fixtures and python-pbr to
1813;; bootstrap the whole thing:
1814;; - python-fixtures-0.3.16 is used to build python-pbr-0.11
1815;; - python-pbr-0.11 is used to build python-fixtures
1816;; - python-fixtures is used to build python-pbr
1817(define-public python-fixtures-0.3.16
cd49454b
DT
1818 (package
1819 (name "python-fixtures")
1820 (version "0.3.16")
1821 (source
1822 (origin
1823 (method url-fetch)
1824 (uri (string-append
1825 "https://pypi.python.org/packages/source/f/fixtures/fixtures-"
1826 version ".tar.gz"))
1827 (sha256
1828 (base32
1829 "0x9r2gwilcig5g54k60bxzg96zabizq1855lrprlb4zckalp9asc"))))
1830 (build-system python-build-system)
1831 (inputs
1832 `(("python-setuptools" ,python-setuptools)))
1833 (arguments
1834 '(#:tests? #f)) ; no setup.py test command
1835 (home-page "https://launchpad.net/python-fixtures")
1836 (synopsis "Python test fixture library")
1837 (description
1838 "Fixtures provides a way to create reusable state, useful when writing
1839Python tests.")
1840 (license (list bsd-3 asl2.0)))) ; at user's option
1841
7787ef76
CR
1842(define-public python2-fixtures-0.3.16
1843 (package-with-python2 python-fixtures-0.3.16))
1844
1845(define-public python-pbr-0.11
1846 (package
1847 (name "python-pbr")
1848 (version "0.11.0")
1849 (source
1850 (origin
1851 (method url-fetch)
1852 (uri (string-append
1853 "https://pypi.python.org/packages/source/p/pbr/pbr-"
1854 version ".tar.gz"))
1855 (sha256
1856 (base32
1857 "0v9gb7gyqf7q9s99l0nnjj9ww9b0jvyqlwm4d56pcyinxydddw6p"))))
1858 (build-system python-build-system)
1859 (arguments
1860 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1861 (inputs
1862 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
1863 ("python-pip" ,python-pip)
1864 ("python-setuptools" ,python-setuptools)))
1865 (home-page "https://launchpad.net/pbr")
1866 (synopsis "Change the default behavior of Python’s setuptools")
1867 (description
1868 "Python Build Reasonableness (PBR) is a library that injects some useful
1869and sensible default behaviors into your setuptools run.")
1870 (license asl2.0)))
1871
1872(define-public python2-pbr-0.11
1873 (package-with-python2 python-pbr-0.11))
1874
1875(define-public python-fixtures
1876 (package
1877 (name "python-fixtures")
13fcc6df 1878 (version "1.4.0")
7787ef76
CR
1879 (source
1880 (origin
1881 (method url-fetch)
13fcc6df 1882 (uri (pypi-uri "fixtures" version))
7787ef76
CR
1883 (sha256
1884 (base32
13fcc6df 1885 "0djxvdwm8s60dbfn7bhf40x6g818p3b3mlwijm1c3bqg7msn271y"))))
7787ef76
CR
1886 (build-system python-build-system)
1887 (propagated-inputs
1888 `(("python-six" ,python-six)
1889 ("python-pbr-0.11" ,python-pbr-0.11)))
1890 (inputs
1891 `(("python-pip" ,python-pip)
1892 ("python-setuptools" ,python-setuptools)
1893 ;; Tests
1894 ("python-testtools" ,python-testtools)))
1895 (arguments
1896 '(#:tests? #f)) ; no setup.py test command
1897 (home-page "https://launchpad.net/python-fixtures")
1898 (synopsis "Python test fixture library")
1899 (description
1900 "Fixtures provides a way to create reusable state, useful when writing
1901Python tests.")
1902 (license (list bsd-3 asl2.0)))) ; at user's option
1903
cd49454b
DT
1904(define-public python2-fixtures
1905 (package-with-python2 python-fixtures))
1906
b24a0c00
DT
1907(define-public python-testrepository
1908 (package
1909 (name "python-testrepository")
1910 (version "0.0.20")
1911 (source
1912 (origin
1913 (method url-fetch)
1914 (uri (string-append
1915 "https://pypi.python.org/packages/source/t/testrepository/testrepository-"
1916 version ".tar.gz"))
1917 (sha256
1918 (base32
1919 "1ssqb07c277010i6gzzkbdd46gd9mrj0bi0i8vn560n2k2y4j93m"))))
1920 (build-system python-build-system)
05de40c5 1921 (propagated-inputs
7787ef76 1922 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
05de40c5 1923 ("python-testtools" ,python-testtools)))
b24a0c00
DT
1924 (inputs
1925 `(("python-setuptools" ,python-setuptools)
b24a0c00 1926 ("python-subunit" ,python-subunit)
b24a0c00
DT
1927 ("python-mimeparse" ,python-mimeparse)))
1928 (home-page "https://launchpad.net/testrepository")
1929 (synopsis "Database for Python test results")
1930 (description "Testrepository provides a database of test results which can
1931be used as part of a developer's workflow to check things such as what tests
1932have failed since the last commit or what tests are currently failing.")
1933 (license (list bsd-3 asl2.0)))) ; at user's option
1934
1935(define-public python2-testrepository
1936 (package-with-python2 python-testrepository))
1937
243a009a
DT
1938(define-public python-coverage
1939 (package
1940 (name "python-coverage")
82a3c582 1941 (version "4.0.3")
243a009a
DT
1942 (source
1943 (origin
1944 (method url-fetch)
82a3c582 1945 (uri (pypi-uri "coverage" version))
243a009a
DT
1946 (sha256
1947 (base32
82a3c582 1948 "0qjlja8ny4gcfp8abqfwdrvr8qw9kr69lkja0b4cqqbsdmdjgcc5"))))
243a009a
DT
1949 (build-system python-build-system)
1950 (inputs
1951 `(("python-setuptools" ,python-setuptools)))
1952 (home-page "http://nedbatchelder.com/code/coverage")
1953 (synopsis "Code coverage measurement for Python")
1954 (description
1955 "Coverage measures code coverage, typically during test execution. It
1956uses the code analysis tools and tracing hooks provided in the Python standard
1957library to determine which lines are executable, and which have been
1958executed.")
1959 (license bsd-3)))
1960
1961(define-public python2-coverage
1962 (package-with-python2 python-coverage))
1963
041358fb
DT
1964(define-public python-discover
1965 (package
1966 (name "python-discover")
1967 (version "0.4.0")
1968 (source
1969 (origin
1970 (method url-fetch)
1971 (uri (string-append
1972 "https://pypi.python.org/packages/source/d/discover/discover-"
1973 version ".tar.gz"))
1974 (sha256
1975 (base32
1976 "0y8d0zwiqar51kxj8lzmkvwc3b8kazb04gk5zcb4nzg5k68zmhq5"))))
1977 (build-system python-build-system)
1978 (inputs
1979 `(("python-setuptools" ,python-setuptools)))
1980 (home-page "http://pypi.python.org/pypi/discover/")
1981 (synopsis
1982 "Python test discovery for unittest")
1983 (description
1984 "Discover provides test discovery for unittest, a feature that has been
e881752c 1985backported from Python 2.7 for Python 2.4+.")
041358fb
DT
1986 (license bsd-3)))
1987
1988(define-public python2-discover
1989 (package-with-python2 python-discover))
1990
a480bc41
EB
1991(define-public behave
1992 (package
1993 (name "behave")
1994 (version "1.2.4")
1995 (source (origin
1996 (method url-fetch)
1997 (uri (string-append "https://pypi.python.org/packages/source/b/"
1998 name "/" name "-" version ".tar.gz"))
1999 (sha256
2000 (base32
2001 "1v2rfy8xnf0rk7cj4cgr7lam4015d458i7bg0xqs9czfv6njlm14"))))
2002 (build-system python-build-system)
2003 (inputs
2004 `(("python-setuptools" ,python-setuptools)
2005 ("python-six" ,python-six)
2006 ("python-enum43" ,python-enum34)
2007 ("python-parse" ,python-parse)
2008 ("python-parse-type" ,python-parse-type)))
2009 (arguments `(#:tests? #f)) ;TODO: tests require nose>=1.3 and
2010 ;PyHamcrest>=1.8
2011 (home-page "http://github.com/behave/behave")
2012 (synopsis "Python behavior-driven development")
2013 (description
2014 "Behave is a tool for behavior-driven development in python.
2015Behavior-driven development (or BDD) is an agile software development
2016technique that encourages collaboration between developers, QA and
2017non-technical or business participants in a software project. Behave uses
2018tests written in a natural language style, backed up by Python code.")
2019 (license x11)))
c7303d3c
DT
2020
2021(define-public python-exif-read
2022 (package
2023 (name "python-exif-read")
2a2d0981 2024 (version "2.1.2")
c7303d3c
DT
2025 (source (origin
2026 (method url-fetch)
2a2d0981 2027 (uri (pypi-uri "ExifRead" version))
c7303d3c
DT
2028 (sha256
2029 (base32
2a2d0981 2030 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
c7303d3c
DT
2031 (build-system python-build-system)
2032 (inputs
2033 `(("python-setuptools" ,python-setuptools)))
2034 (arguments `(#:tests? #f)) ; no tests
2035 (home-page "https://github.com/ianare/exif-py")
2036 (synopsis "Python library to extract EXIF data from image files")
2037 (description
2038 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
2039files.")
2040 (license bsd-3)))
2041
2042(define-public python2-exif-read
2043 (package-with-python2 python-exif-read))
d5f89b22
DT
2044
2045(define-public python-pyld
2046 (package
2047 (name "python-pyld")
af1ab773 2048 (version "0.6.8")
d5f89b22
DT
2049 (source (origin
2050 (method url-fetch)
af1ab773 2051 (uri (pypi-uri "PyLD" version))
d5f89b22
DT
2052 (sha256
2053 (base32
af1ab773 2054 "0k881ffazpf8q1z8862g4bb3pzwpnz9whrci2mf311mvn1qbyqad"))))
d5f89b22
DT
2055 (build-system python-build-system)
2056 (inputs
2057 `(("python-setuptools" ,python-setuptools)))
2058 (arguments `(#:tests? #f)) ; no tests
2059 (home-page "http://github.com/digitalbazaar/pyld")
2060 (synopsis "Python implementation of the JSON-LD specification")
2061 (description
2062 "PyLD is an implementation of the JSON-LD specification.")
2063 (license bsd-3)))
2064
2065(define-public python2-pyld
2066 (package-with-python2 python-pyld))
3a1f9a68
DT
2067
2068(define-public python-certifi
2069 (package
2070 (name "python-certifi")
9a41f443 2071 (version "2015.11.20.1")
3a1f9a68
DT
2072 (source (origin
2073 (method url-fetch)
9a41f443 2074 (uri (pypi-uri "certifi" version))
3a1f9a68
DT
2075 (sha256
2076 (base32
9a41f443 2077 "05lgwf9rz1kn465azy2bpb3zmpnsn9gkypbhnjlclchv98ssgc1h"))))
3a1f9a68
DT
2078 (build-system python-build-system)
2079 (inputs
2080 `(("python-setuptools" ,python-setuptools)))
2081 (arguments `(#:tests? #f)) ; no tests
2082 (home-page "http://python-requests.org/")
2083 (synopsis "Python CA certificate bundle")
2084 (description
2085 "Certifi is a Python library that contains a CA certificate bundle, which
2086is used by the Requests library to verify HTTPS requests.")
2087 (license asl2.0)))
2088
2089(define-public python2-certifi
2090 (package-with-python2 python-certifi))
e6cfbd36 2091
12c270dd
RW
2092(define-public python-click
2093 (package
2094 (name "python-click")
5bd88cf1 2095 (version "6.2")
12c270dd
RW
2096 (source
2097 (origin
2098 (method url-fetch)
5bd88cf1 2099 (uri (pypi-uri "click" version))
12c270dd 2100 (sha256
5bd88cf1 2101 (base32 "10kavbisnk9m93jl2wi34pw7ryr2qbxshh2cysxwxd7bymqgz87v"))))
12c270dd
RW
2102 (build-system python-build-system)
2103 (native-inputs
2104 `(("python-setuptools" ,python-setuptools)))
2105 (home-page "http://click.pocoo.org")
2106 (synopsis "Command line library for Python")
2107 (description
2108 "Click is a Python package for creating command line interfaces in a
2109composable way with as little code as necessary. Its name stands for
2110\"Command Line Interface Creation Kit\". It's highly configurable but comes
2111with sensible defaults out of the box.")
2112 (license bsd-3)))
2113
2114(define-public python2-click
2115 (package-with-python2 python-click))
2116
addc808d
EF
2117(define-public python-wheel
2118 (package
2119 (name "python-wheel")
2120 (version "0.26.0")
e1ba0749
EF
2121 (source
2122 (origin
2123 (method url-fetch)
2124 (uri (pypi-uri "wheel" version))
2125 (sha256
2126 (base32
2127 "032k1ajijbqnv0z0k88bhf75mdimi18fcmm28mss90610lw3bbga"))))
2128 (build-system python-build-system)
2129 (native-inputs
2130 `(("python-setuptools" ,python-setuptools)
2131 ("python-jsonschema" ,python-jsonschema)
2132 ("python-pytest-cov" ,python-pytest-cov)))
2133 (home-page "https://bitbucket.org/pypa/wheel/")
2134 (synopsis "Format for built Python packages")
2135 (description
2136 "A wheel is a ZIP-format archive with a specially formatted filename and
2137the @code{.whl} extension. It is designed to contain all the files for a PEP
2138376 compatible install in a way that is very close to the on-disk format. Many
2139packages will be properly installed with only the @code{Unpack} step and the
2140unpacked archive preserves enough information to @code{Spread} (copy data and
2141scripts to their final locations) at any later time. Wheel files can be
2142installed with a newer @code{pip} or with wheel's own command line utility.")
2143 (license license:expat)))
addc808d
EF
2144
2145(define-public python2-wheel
264ae686
EF
2146 (let ((wheel (package-with-python2 python-wheel)))
2147 (package (inherit wheel)
2148 (native-inputs
2149 `(("python2-functools32" ,python2-functools32)
2150 ("python2-jsonschema" ,python2-jsonschema)
2151 ,@(alist-delete "python-jsonschema"
2152 (package-native-inputs wheel)))))))
addc808d 2153
ae641128 2154(define-public python-requests
e6cfbd36 2155 (package
ae641128 2156 (name "python-requests")
5d691657 2157 (version "2.8.1")
e6cfbd36
DT
2158 (source (origin
2159 (method url-fetch)
5d691657 2160 (uri (pypi-uri "requests" version))
e6cfbd36
DT
2161 (sha256
2162 (base32
5d691657 2163 "0ny2nr1sqr4hcn3903ghmh7w2yni8shlfv240a8c9p6wyidqvzl4"))))
e6cfbd36 2164 (build-system python-build-system)
5d691657
EF
2165 (native-inputs
2166 `(("python-setuptools" ,python-setuptools)))
2167 (propagated-inputs
2168 `(("python-py" ,python-py)
2169 ("python-pytest" ,python-pytest)
2170 ("python-pytest-cov" ,python-pytest-cov)
2171 ("python-wheel" ,python-wheel)))
e6cfbd36
DT
2172 (home-page "http://python-requests.org/")
2173 (synopsis "Python HTTP library")
2174 (description
2175 "Requests is a Python HTTP client library. It aims to be easier to use
2176than Python’s urllib2 library.")
2177 (license asl2.0)))
864b5211 2178
e9005180
DT
2179;; Some software requires an older version of Requests, notably Docker
2180;; Compose.
2181(define-public python-requests-2.7
2182 (package (inherit python-requests)
2183 (version "2.7.0")
2184 (source (origin
2185 (method url-fetch)
2186 (uri (pypi-uri "requests" version))
2187 (sha256
2188 (base32
2189 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
2190
ae641128 2191(define-public python2-requests
264ae686
EF
2192 (let ((requests (package-with-python2 python-requests)))
2193 (package (inherit requests)
2194 (propagated-inputs
2195 `(("python2-wheel" ,python2-wheel)
2196 ,@(alist-delete "python-wheel"
2197 (package-propagated-inputs requests)))))))
ae641128 2198
ea521b42
DT
2199(define-public python-vcversioner
2200 (package
2201 (name "python-vcversioner")
2202 (version "2.14.0.0")
2203 (source
2204 (origin
2205 (method url-fetch)
2206 (uri (pypi-uri "vcversioner" version))
2207 (sha256
2208 (base32
2209 "11ivq1bm7v0yb4nsfbv9m7g7lyjn112gbvpjnjz8nv1fx633dm5c"))))
2210 (build-system python-build-system)
2211 (inputs
2212 `(("python-setuptools" ,python-setuptools)))
2213 (synopsis "Python library for version number discovery")
2214 (description "Vcversioner is a Python library that inspects tagging
2215information in a variety of version control systems in order to discover
2216version numbers.")
2217 (home-page "https://github.com/habnabit/vcversioner")
2218 (license isc)))
2219
2220(define-public python2-vcversioner
2221 (package-with-python2 python-vcversioner))
ae641128 2222
864b5211
DT
2223(define-public python-jsonschema
2224 (package
2225 (name "python-jsonschema")
b3667afb 2226 (version "2.5.1")
864b5211
DT
2227 (source (origin
2228 (method url-fetch)
2229 (uri
2230 (string-append
2231 "https://pypi.python.org/packages/source/j/jsonschema/jsonschema-"
2232 version ".tar.gz"))
2233 (sha256
2234 (base32
b3667afb 2235 "0hddbqjm4jq63y8jf44nswina1crjs16l9snb6m3vvgyg31klrrn"))))
864b5211
DT
2236 (build-system python-build-system)
2237 (inputs
b3667afb
DT
2238 `(("python-setuptools" ,python-setuptools)
2239 ("python-vcversioner" ,python-vcversioner)))
864b5211
DT
2240 (home-page "http://github.com/Julian/jsonschema")
2241 (synopsis "Implementation of JSON Schema for Python")
2242 (description
2243 "Jsonschema is an implementation of JSON Schema for Python.")
bd3fa666 2244 (license license:expat)))
864b5211
DT
2245
2246(define-public python2-jsonschema
264ae686
EF
2247 (let ((jsonschema (package-with-python2 python-jsonschema)))
2248 (package (inherit jsonschema)
2249 (inputs
2250 `(("python2-functools32" ,python2-functools32)
2251 ,@(package-inputs jsonschema))))))
850189b8
DT
2252
2253(define-public python-unidecode
2254 (package
2255 (name "python-unidecode")
8925d4f3 2256 (version "0.04.18")
850189b8
DT
2257 (source (origin
2258 (method url-fetch)
8925d4f3 2259 (uri (pypi-uri "Unidecode" version))
850189b8
DT
2260 (sha256
2261 (base32
8925d4f3 2262 "12hhblqy1ajvidm38im4171x4arg83pfmziyn53nizp29p3m14gi"))))
850189b8
DT
2263 (build-system python-build-system)
2264 (inputs
2265 `(("python-setuptools" ,python-setuptools)))
2266 (home-page "https://pypi.python.org/pypi/Unidecode")
2267 (synopsis "ASCII transliterations of Unicode text")
2268 (description
2269 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2270useful when integrating with legacy code that doesn't support Unicode, or for
2271ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2272machine identifiers from human-readable Unicode strings that should still be
2273somewhat intelligeble.")
2274 (license gpl2+)))
2275
2276(define-public python2-unidecode
2277 (package-with-python2 python-unidecode))
6d45fef4
DT
2278
2279(define-public python-pyjwt
2280 (package
2281 (name "python-pyjwt")
eb31d4b4 2282 (version "1.4.0")
6d45fef4
DT
2283 (source
2284 (origin
2285 (method url-fetch)
eb31d4b4 2286 (uri (pypi-uri "PyJWT" version))
6d45fef4
DT
2287 (sha256
2288 (base32
eb31d4b4 2289 "1556v2jppd8mjkkj66pxb5rcazm35jq81r233mdl8hfmz9n3icp1"))))
6d45fef4 2290 (build-system python-build-system)
eb31d4b4
EF
2291 (native-inputs
2292 `(("python-setuptools" ,python-setuptools)
2293 ("python-pytest-runner" ,python-pytest-runner)))
6d45fef4
DT
2294 (arguments
2295 '(#:tests? #f)) ; test suite doesn't work
2296 (home-page "http://github.com/progrium/pyjwt")
2297 (synopsis "JSON Web Token implementation in Python")
2298 (description
2299 "PyJWT is a JSON Web Token implementation written in Python.")
bd3fa666 2300 (license license:expat)))
6d45fef4
DT
2301
2302(define-public python2-pyjwt
2303 (package-with-python2 python-pyjwt))
2304
2cec1f6f
DT
2305(define-public python-oauthlib
2306 (package
2307 (name "python-oauthlib")
bde2171d 2308 (version "1.0.3")
2cec1f6f
DT
2309 (source (origin
2310 (method url-fetch)
bde2171d 2311 (uri (pypi-uri "oauthlib" version))
2cec1f6f
DT
2312 (sha256
2313 (base32
bde2171d 2314 "1bfrj70vdjxjw74khbyh6f0dksv7p5rh2346jnlrffyacd3gwjzg"))))
2cec1f6f 2315 (build-system python-build-system)
bde2171d 2316 (native-inputs
2cec1f6f 2317 `(("python-setuptools" ,python-setuptools)
bde2171d 2318 ("python-coverage", python-coverage)
2cec1f6f
DT
2319 ("python-nose" ,python-nose)
2320 ("python-mock" ,python-mock)))
bde2171d
EF
2321 (inputs
2322 `(("python-blinker" ,python-blinker)
2323 ("python-cryptography" ,python-cryptography)
2324 ("python-pyjwt" ,python-pyjwt)))
2cec1f6f
DT
2325 (home-page "https://github.com/idan/oauthlib")
2326 (synopsis "OAuth implementation for Python")
2327 (description
2328 "Oauthlib is a generic, spec-compliant, thorough implementation of the
2329OAuth request-signing logic.")
2330 (license bsd-3)))
2331
2332(define-public python2-oauthlib
2333 (let ((base (package-with-python2 python-oauthlib)))
2334 (package
2335 (inherit base)
2cec1f6f 2336 (inputs
0066de6f
EF
2337 `(("python2-unittest2" ,python2-unittest2)
2338 ("python2-cryptography" ,python2-cryptography)
2339 ,@(alist-delete "python-cryptography"
2340 (package-inputs base)))))))
ec5dbb5c
DT
2341
2342(define-public python-itsdangerous
2343 (package
2344 (name "python-itsdangerous")
2345 (version "0.24")
2346 (source
2347 (origin
2348 (method url-fetch)
2349 (uri (string-append
2350 "https://pypi.python.org/packages/source/i/itsdangerous/itsdangerous-"
2351 version ".tar.gz"))
2352 (sha256
2353 (base32
2354 "06856q6x675ly542ig0plbqcyab6ksfzijlyf1hzhgg3sgwgrcyb"))))
2355 (build-system python-build-system)
2356 (inputs
2357 `(("python-setuptools" ,python-setuptools)))
2358 (home-page "http://github.com/mitsuhiko/itsdangerous")
2359 (synopsis "Python library for passing data to/from untrusted environments")
2360 (description
2361 "Itsdangerous provides various helpers to pass trusted data to untrusted
2362environments and back.")
2363 (license bsd-3)))
2364
2365(define-public python2-itsdangerous
2366 (package-with-python2 python-itsdangerous))
5731cae3 2367
8d12be1e
RW
2368(define-public python-pyyaml
2369 (package
2370 (name "python-pyyaml")
2371 (version "3.11")
2372 (source
2373 (origin
2374 (method url-fetch)
2375 (uri (string-append
2376 "https://pypi.python.org/packages/source/P/PyYAML/PyYAML-"
2377 version ".tar.gz"))
2378 (sha256
2379 (base32
2380 "1s26125vfnskng58ym37xhwv8v0mm95b2cwbjfag8prfhy596v63"))))
2381 (build-system python-build-system)
2382 (inputs
2383 `(("libyaml" ,libyaml)))
2384 (native-inputs
2385 `(("python-setuptools" ,python-setuptools)))
2386 (home-page "http://pyyaml.org/wiki/PyYAML")
2387 (synopsis "YAML parser and emitter for Python")
2388 (description
2389 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2390complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2391API, and sensible error messages. PyYAML supports standard YAML tags and
2392provides Python-specific tags that allow to represent an arbitrary Python
2393object.")
2394 (license license:expat)))
2395
2396(define-public python2-pyyaml
2397 (package-with-python2 python-pyyaml))
2398
5731cae3
DT
2399(define-public python-virtualenv
2400 (package
2401 (name "python-virtualenv")
17804240 2402 (version "13.1.2")
5731cae3
DT
2403 (source
2404 (origin
2405 (method url-fetch)
17804240 2406 (uri (pypi-uri "virtualenv" version))
5731cae3
DT
2407 (sha256
2408 (base32
17804240 2409 "1p732accxwqfjbdna39k8w8lp9gyw91vr4kzkhm8mgfxikqqxg5a"))))
5731cae3 2410 (build-system python-build-system)
17804240
EF
2411 (arguments
2412 `(#:phases
2413 (modify-phases %standard-phases
2414 (replace 'check
2415 (lambda _ (zero? (system* "py.test")))))))
5731cae3
DT
2416 (inputs
2417 `(("python-setuptools" ,python-setuptools)
2418 ("python-mock" ,python-mock)
17804240 2419 ("python-pytest" ,python-pytest)))
5731cae3
DT
2420 (home-page "https://virtualenv.pypa.io/")
2421 (synopsis "Virtual Python environment builder")
2422 (description
2423 "Virtualenv is a tool to create isolated Python environments.")
bd3fa666 2424 (license license:expat)))
5731cae3
DT
2425
2426(define-public python2-virtualenv
2427 (package-with-python2 python-virtualenv))
8176d4d5
DT
2428
2429(define-public python-markupsafe
2430 (package
2431 (name "python-markupsafe")
2432 (version "0.23")
2433 (source
2434 (origin
2435 (method url-fetch)
2436 (uri (string-append
2437 "https://pypi.python.org/packages/source/M/MarkupSafe/MarkupSafe-"
2438 version ".tar.gz"))
2439 (sha256
2440 (base32
2441 "1hvip33wva3fnmvfp9x5klqri7hpl1hkgqmjbss18nmrb7zimv54"))))
2442 (build-system python-build-system)
2443 (inputs
2444 `(("python-setuptools" ,python-setuptools)))
2445 (home-page "http://github.com/mitsuhiko/markupsafe")
2446 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2447 (description
2448 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2449for Python.")
2450 (license bsd-3)))
2451
2452(define-public python2-markupsafe
2453 (package-with-python2 python-markupsafe))
fe34f0d1
DT
2454
2455(define-public python-jinja2
2456 (package
2457 (name "python-jinja2")
e98149b3 2458 (version "2.8")
fe34f0d1
DT
2459 (source
2460 (origin
2461 (method url-fetch)
e98149b3 2462 (uri (pypi-uri "Jinja2" version))
fe34f0d1
DT
2463 (sha256
2464 (base32
e98149b3 2465 "1x0v41lp5m1pjix3l46zx02b7lqp2hflgpnxwkywxynvi3zz47xw"))))
fe34f0d1
DT
2466 (build-system python-build-system)
2467 (inputs
2468 `(("python-setuptools" ,python-setuptools)
2469 ("python-markupsafe" ,python-markupsafe)))
2470 (home-page "http://jinja.pocoo.org/")
2471 (synopsis "Python template engine")
2472 (description
2473 "Jinja2 is a small but fast and easy to use stand-alone template engine
2474written in pure Python.")
2475 (license bsd-3)))
2476
2477(define-public python2-jinja2
2478 (package-with-python2 python-jinja2))
3580ab8b 2479
f7d17ac7
EE
2480(define-public python-pystache
2481 (package
2482 (name "python-pystache")
2483 (version "0.5.4")
2484 (source (origin
2485 (method url-fetch)
2486 (uri (pypi-uri "pystache" version))
2487 (sha256
2488 (base32
2489 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2490 (build-system python-build-system)
2491 (native-inputs
2492 `(("python-setuptools" ,python-setuptools)))
2493 (home-page "http://defunkt.io/pystache/")
2494 (synopsis "Python logic-less template engine")
2495 (description
2496 "Pystache is a Python implementation of the framework agnostic,
2497logic-free templating system Mustache.")
2498 (license license:expat)))
2499
2500(define-public python2-pystache
2501 (package-with-python2 python-pystache))
2502
1285119b
RW
2503(define-public python-joblib
2504 (package
2505 (name "python-joblib")
2506 (version "0.9.0b4")
2507 (source (origin
2508 (method url-fetch)
2509 (uri (string-append "https://pypi.python.org/packages/source/"
2510 "j/joblib/joblib-" version ".tar.gz"))
2511 (sha256
2512 (base32
2513 "1dvw3f8jgj6h0fxkghbgyclvdzc7l0ig7n0vis70awb5kczb9bs3"))))
2514 (build-system python-build-system)
2515 (native-inputs
2516 `(("python-setuptools" ,python-setuptools)
2517 ("python-nose" ,python-nose)))
2518 (home-page "http://pythonhosted.org/joblib/")
2519 (synopsis "Using Python functions as pipeline jobs")
2520 (description
2521 "Joblib is a set of tools to provide lightweight pipelining in Python.
2522In particular, joblib offers: transparent disk-caching of the output values
2523and lazy re-evaluation (memoize pattern), easy simple parallel computing
2524logging and tracing of the execution.")
2525 (license bsd-3)))
2526
2527(define-public python2-joblib
2528 (package-with-python2 python-joblib))
2529
3580ab8b
DT
2530(define-public python-docutils
2531 (package
2532 (name "python-docutils")
2533 (version "0.12")
2534 (source
2535 (origin
2536 (method url-fetch)
2537 (uri (string-append
2538 "https://pypi.python.org/packages/source/d/docutils/docutils-"
2539 version ".tar.gz"))
2540 (sha256
2541 (base32
2542 "1ylnjnw1x4b2y7blr6x35ncdzn69k253kw4cdkv6asdb21w73ny7"))))
2543 (build-system python-build-system)
2544 (inputs
2545 `(("python-setuptools" ,python-setuptools)))
2546 (arguments
2547 '(#:tests? #f)) ; no setup.py test command
2548 (home-page "http://docutils.sourceforge.net/")
2549 (synopsis "Python Documentation Utilities")
2550 (description
2551 "Docutils is a modular system for processing documentation into useful
2552formats, such as HTML, XML, and LaTeX. For input Docutils supports
2553reStructuredText.")
2554 ;; Most of the source code is public domain, but some source files are
2555 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2556 (license (list public-domain psfl bsd-2 gpl3+))))
2557
2558(define-public python2-docutils
2559 (package-with-python2 python-docutils))
fb35b7c0
DT
2560
2561(define-public python-pygments
2562 (package
2563 (name "python-pygments")
9f442285 2564 (version "2.0.2")
fb35b7c0
DT
2565 (source
2566 (origin
2567 (method url-fetch)
9f442285 2568 (uri (pypi-uri "Pygments" version))
fb35b7c0
DT
2569 (sha256
2570 (base32
9f442285 2571 "0lagrwifsgn0s8bzqahpr87p7gd38xja8f06akscinp6hj89283k"))))
fb35b7c0
DT
2572 (build-system python-build-system)
2573 (inputs
2574 `(("python-setuptools" ,python-setuptools)))
2575 (home-page "http://pygments.org/")
2576 (synopsis "Syntax highlighting")
2577 (description
2578 "Pygments is a syntax highlighting package written in Python.")
2579 (license bsd-2)))
2580
2581(define-public python2-pygments
2582 (package-with-python2 python-pygments))
9dd6078d
DT
2583
2584(define-public python-sphinx
2585 (package
2586 (name "python-sphinx")
2587 (version "1.2.3")
2588 (source
2589 (origin
2590 (method url-fetch)
2591 (uri (string-append
2592 "https://pypi.python.org/packages/source/S/Sphinx/Sphinx-"
2593 version ".tar.gz"))
2594 (sha256
2595 (base32
2596 "011xizm3jnmf4cvs5i6kgf6c5nn046h79i8j0vd0f27yw9j3p4wl"))))
2597 (build-system python-build-system)
2598 (inputs
2599 `(("python-setuptools" ,python-setuptools)
2600 ("python-jinja2" ,python-jinja2)
2601 ("python-docutils" ,python-docutils)
2602 ("python-pygments" ,python-pygments)))
2603 (home-page "http://sphinx-doc.org/")
2604 (synopsis "Python documentation generator")
2605 (description "Sphinx is a tool that makes it easy to create documentation
2606for Python projects or other documents consisting of multiple reStructuredText
2607sources.")
2608 (license bsd-3)))
2609
2610(define-public python2-sphinx
2611 (package-with-python2 python-sphinx))
6888830b 2612
ad320b20
RW
2613(define-public python-sphinx-rtd-theme
2614 (package
2615 (name "python-sphinx-rtd-theme")
2616 (version "0.1.6")
2617 (source
2618 (origin
2619 (method url-fetch)
2620 (uri (string-append "https://pypi.python.org/packages/source/s/"
2621 "sphinx_rtd_theme/sphinx_rtd_theme-"
2622 version ".tar.gz"))
2623 (sha256
2624 (base32
2625 "19nw3rn7awplcdrz63kg1njqwkbymfg9lwn7l2grhdyhyr2gaa8g"))))
2626 (build-system python-build-system)
2627 (arguments
2628 `(;; With standard flags, the install phase attempts to create a zip'd
2629 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2630 ;; before 1980'
2631 #:configure-flags '("--single-version-externally-managed"
2632 "--record=sphinx-rtd-theme.txt")))
2633 (native-inputs
2634 `(("python-setuptools" ,python-setuptools)))
2635 (inputs
2636 `(("python-docutils" ,python-docutils)
2637 ("python-sphinx" ,python-sphinx)))
2638 (home-page "https://github.com/snide/sphinx_rtd_theme/")
2639 (synopsis "ReadTheDocs.org theme for Sphinx")
2640 (description "A theme for Sphinx used by ReadTheDocs.org.")
bd3fa666 2641 (license license:expat)))
ad320b20
RW
2642
2643(define-public python2-sphinx-rtd-theme
2644 (package-with-python2 python-sphinx-rtd-theme))
2645
f4de5b3b
CAW
2646(define-public python-feedgenerator
2647 (package
2648 (name "python-feedgenerator")
2649 (version "20150710.97185b7")
2650 (source
2651 ;; Using the git checkout for now because license file not added till
2652 ;; https://github.com/dmdm/feedgenerator-py3k/commit/97185b7566c240c4bf5ed80db7d6c271204dab39
2653 (origin
2654 (method git-fetch)
2655 (uri (git-reference
2656 (url "https://github.com/dmdm/feedgenerator-py3k.git")
2657 (commit "97185b7566c240c4bf5ed80db7d6c271204dab39")))
2658 (sha256
2659 (base32
2660 "0dbd6apij5j1923ib905x0srgcyls4wlabqlwp4dzkwmksvnrr2a"))))
2661 (arguments
2662 `(;; With standard flags, the install phase attempts to create a zip'd
2663 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2664 ;; before 1980'
2665 #:configure-flags '("--single-version-externally-managed"
2666 "--record=feedgenerator.txt")))
2667 (build-system python-build-system)
2668 (inputs
2669 `(("python-setuptools" ,python-setuptools)
2670 ("python-pytz" ,python-pytz)
2671 ("python-six" ,python-six)))
2672 (home-page
2673 "https://github.com/dmdm/feedgenerator-py3k.git")
2674 (synopsis
2675 "Standalone version of Django's Atom/RSS feed generator")
2676 (description
2677 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2678which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
2679 (license bsd-3)))
2680
2681(define-public python2-feedgenerator
2682 (package-with-python2 python-feedgenerator))
2683
59ad30e3
CAW
2684(define-public python-blinker
2685 (package
2686 (name "python-blinker")
7fb9ff4d 2687 (version "1.4")
59ad30e3
CAW
2688 (source
2689 (origin
2690 (method url-fetch)
7fb9ff4d 2691 (uri (pypi-uri "blinker" version))
59ad30e3
CAW
2692 (sha256
2693 (base32
7fb9ff4d 2694 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
59ad30e3
CAW
2695 (build-system python-build-system)
2696 (native-inputs
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")
2703 (description
2704 "Blinker provides a fast dispatching system that allows any number of
2705interested parties to subscribe to events, or \"signals\".")
2706 (license license:expat)))
2707
2708(define-public python2-blinker
2709 (package-with-python2 python-blinker))
2710
b8050e71
CAW
2711(define-public pelican
2712 (package
2713 (name "pelican")
11f97c27 2714 (version "3.6.3")
b8050e71
CAW
2715 (source
2716 (origin
2717 (method url-fetch)
11f97c27 2718 (uri (pypi-uri "pelican" version))
b8050e71
CAW
2719 (sha256
2720 (base32
11f97c27 2721 "1hn94rb4q3zmcq16in055xikal4dba5hfx3zznq7warllcgc9f8k"))))
b8050e71
CAW
2722 (build-system python-build-system)
2723 (native-inputs
2724 `(("python-setuptools" ,python-setuptools)))
2725 (propagated-inputs
2726 `(("python-feedgenerator" ,python-feedgenerator)
2727 ("python-jinja2" ,python-jinja2)
2728 ("python-pygments" ,python-pygments)
2729 ("python-docutils" ,python-docutils)
2730 ("python-pytz" ,python-pytz)
2731 ("python-blinker" ,python-blinker)
2732 ("python-unidecode" ,python-unidecode)
2733 ("python-six" ,python-six)
2734 ("python-dateutil-2" ,python-dateutil-2)))
2735 (home-page "http://getpelican.com/")
2736 (arguments
2737 `(;; XXX Requires a lot more packages to do unit tests :P
2738 #:tests? #f
2739 #:phases (modify-phases %standard-phases
2740 (add-before
2741 'install 'adjust-requires
2742 ;; Since feedgenerator is installed from git, it doesn't
2743 ;; conform to the version requirements.
2744 ;;
2745 ;; We *do have* "feedgenerator >= 1.6", but strip off the
2746 ;; version requirement so setuptools doesn't get confused.
2747 (lambda _
2748 (substitute* "setup.py"
2749 (("['\"]feedgenerator.*?['\"]")
2750 "'feedgenerator'")))))))
2751 (synopsis "Python-based static site publishing system")
2752 (description
2753 "Pelican is a tool to generate a static blog from reStructuredText,
2754Markdown input files, and more. Pelican uses Jinja2 for templating
2755and is very extensible.")
2756 (license agpl3+)))
2757
240ca4aa
RW
2758(define-public python-scikit-learn
2759 (package
2760 (name "python-scikit-learn")
be0a4c26 2761 (version "0.16.1")
240ca4aa
RW
2762 (source
2763 (origin
2764 (method url-fetch)
2765 (uri (string-append
2766 "https://github.com/scikit-learn/scikit-learn/archive/"
2767 version ".tar.gz"))
2768 (sha256
2769 (base32
be0a4c26 2770 "140skabifgc7lvvj873pnzlwx0ni6q8qkrsyad2ccjb3h8rxzkih"))))
240ca4aa
RW
2771 (build-system python-build-system)
2772 (arguments
2773 `(#:phases
2774 (alist-cons-before
2f6b3d2e
RW
2775 'check 'set-HOME
2776 ;; some tests require access to "$HOME"
2777 (lambda _ (setenv "HOME" "/tmp"))
2778 ;; Tests can only be run after the library has been installed and not
2779 ;; within the source directory.
2780 (alist-cons-after
2781 'install 'check
2782 (lambda _
2783 (with-directory-excursion "/tmp"
2784 ;; With Python 3 one test of 3334 fails
2785 ;; (sklearn.tests.test_common.test_transformers); see
2786 ;; https://github.com/scikit-learn/scikit-learn/issues/3693
2787 (system* "nosetests" "-v" "sklearn")))
2788 (alist-delete 'check %standard-phases)))))
240ca4aa 2789 (inputs
2f6b3d2e 2790 `(("openblas" ,openblas)
240ca4aa
RW
2791 ("python-nose" ,python-nose)))
2792 (propagated-inputs
2793 `(("python-numpy" ,python-numpy)
2794 ("python-scipy" ,python-scipy)))
2795 (home-page "http://scikit-learn.org/")
2796 (synopsis "Machine Learning in Python")
2797 (description
2798 "Scikit-learn provides simple and efficient tools for data
2799mining and data analysis.")
2800 (license bsd-3)))
2801
2802(define-public python2-scikit-learn
2803 (let ((scikit (package-with-python2 python-scikit-learn)))
2804 (package (inherit scikit)
2805 (propagated-inputs
2806 `(("python2-numpy" ,python2-numpy)
2807 ("python2-scipy" ,python2-scipy)
2808 ,@(alist-delete
2809 "python-numpy"
2810 (alist-delete
2811 "python-scipy" (package-propagated-inputs scikit))))))))
2812
12f8f9bb
RW
2813(define-public python-scikit-image
2814 (package
2815 (name "python-scikit-image")
2816 (version "0.11.3")
2817 (source
2818 (origin
2819 (method url-fetch)
2820 (uri (string-append
2821 "https://pypi.python.org/packages/source/s/scikit-image/scikit-image-"
2822 version ".tar.gz"))
2823 (sha256
2824 (base32 "0jz416fqvpahqyffw8plmszzfj669w8wvf3y9clnr5lr6a7md3kn"))))
2825 (build-system python-build-system)
2826 (propagated-inputs
2827 `(("python-matplotlib" ,python-matplotlib)
2828 ("python-networkx" ,python-networkx)
2829 ("python-numpy" ,python-numpy)
2830 ("python-scipy" ,python-scipy)
2831 ("python-six" ,python-six)
2832 ("python-pillow" ,python-pillow)))
2833 (native-inputs
2834 `(("python-cython" ,python-cython)
2835 ("python-setuptools" ,python-setuptools)))
2836 (home-page "http://scikit-image.org/")
2837 (synopsis "Image processing in Python")
2838 (description
e881752c 2839 "Scikit-image is a collection of algorithms for image processing.")
12f8f9bb
RW
2840 (license bsd-3)))
2841
2842(define-public python2-scikit-image
2843 (let ((scikit-image (package-with-python2 python-scikit-image)))
2844 (package (inherit scikit-image)
2845 (native-inputs
2846 `(("python2-mock" ,python2-mock)
2847 ,@(package-native-inputs scikit-image)))
2848 (propagated-inputs
2849 `(("python2-pytz" ,python2-pytz)
d9bc0bf8
FB
2850 ("python2-matplotlib" ,python2-matplotlib)
2851 ("python2-numpy" ,python2-numpy)
2852 ("python2-scipy" ,python2-scipy)
2853 ,@(fold alist-delete (package-propagated-inputs scikit-image)
2854 '("python-matplotlib" "python-numpy" "python-scipy")))))))
12f8f9bb 2855
5394a6a6
RW
2856(define-public python-redis
2857 (package
2858 (name "python-redis")
2859 (version "2.10.3")
2860 (source
2861 (origin
2862 (method url-fetch)
2863 (uri (string-append
2864 "https://pypi.python.org/packages/source/r/redis/redis-"
2865 version ".tar.gz"))
2866 (sha256
2867 (base32 "1701qjwn4n05q90fdg4bsg96s27xf5s4hsb4gxhv3xk052q3gyx4"))))
2868 (build-system python-build-system)
2869 ;; Tests require a running Redis server
2870 (arguments '(#:tests? #f))
2871 (native-inputs
2872 `(("python-setuptools" ,python-setuptools)
2873 ("python-pytest" ,python-pytest)))
2874 (home-page "https://github.com/andymccurdy/redis-py")
2875 (synopsis "Redis Python client")
2876 (description
2877 "This package provides a Python interface to the Redis key-value store.")
2878 (license license:expat)))
2879
2880(define-public python2-redis
2881 (package-with-python2 python-redis))
2882
748cef5b
RW
2883(define-public python-rq
2884 (package
2885 (name "python-rq")
2886 (version "0.5.2")
2887 (source
2888 (origin
2889 (method url-fetch)
2890 (uri (string-append
2891 "https://pypi.python.org/packages/source/r/rq/rq-"
2892 version ".tar.gz"))
2893 (sha256
2894 (base32 "0b0z5hn8wkfg300hx7816csgv3bcfamlr29fi3yzgqmpqxwj3fix"))))
2895 (build-system python-build-system)
2896 (propagated-inputs
2897 `(("python-click" ,python-click)
2898 ("python-redis" ,python-redis)))
2899 (native-inputs
2900 `(("python-setuptools" ,python-setuptools)))
2901 (home-page "http://python-rq.org/")
2902 (synopsis "Simple job queues for Python")
2903 (description
2904 "RQ (Redis Queue) is a simple Python library for queueing jobs and
2905processing them in the background with workers. It is backed by Redis and it
2906is designed to have a low barrier to entry.")
2907 (license bsd-2)))
2908
2909(define-public python2-rq
2910 (package-with-python2 python-rq))
2911
6888830b
FB
2912(define-public python-cython
2913 (package
2914 (name "python-cython")
56918e26 2915 (version "0.23.4")
6888830b
FB
2916 (source
2917 (origin
2918 (method url-fetch)
56918e26 2919 (uri (pypi-uri "Cython" version))
6888830b
FB
2920 (sha256
2921 (base32
56918e26 2922 "13hdffhd37mx3gjby018xl179jaj957fy7kzi01crmimxvn2zi7y"))))
6888830b
FB
2923 (build-system python-build-system)
2924 ;; we need the full python package and not just the python-wrapper
2925 ;; because we need libpython3.3m.so
2926 (inputs
2927 `(("python" ,python)))
2928 (arguments
2929 `(#:phases
2930 (alist-cons-before
2931 'check 'set-HOME
2932 ;; some tests require access to "$HOME/.cython"
2933 (lambda* _ (setenv "HOME" "/tmp"))
2934 (alist-replace
2935 'check
2936 (lambda _ (zero? (system* "python" "runtests.py" "-vv")))
2937 %standard-phases))))
2938 (home-page "http://cython.org/")
2939 (synopsis "C extensions for Python")
2940 (description "Cython is an optimising static compiler for both the Python
2941programming language and the extended Cython programming language. It makes
2942writing C extensions for Python as easy as Python itself.")
48b311b1
LC
2943 (license asl2.0)
2944 (properties `((python2-variant . ,(delay python2-cython))))))
6888830b
FB
2945
2946(define-public python2-cython
48b311b1
LC
2947 (package (inherit (package-with-python2
2948 (strip-python2-variant python-cython)))
6888830b
FB
2949 (name "python2-cython")
2950 (inputs
2951 `(("python-2" ,python-2))))) ; this is not automatically changed
0da98533
FB
2952
2953;; This version of numpy is missing the documentation and is only used to
2954;; build matplotlib which is required to build numpy's documentation.
2955(define python-numpy-bootstrap
2956 (package
2957 (name "python-numpy-bootstrap")
ef9b4c04 2958 (version "1.10.4")
0da98533
FB
2959 (source
2960 (origin
2961 (method url-fetch)
2962 (uri (string-append "mirror://sourceforge/numpy"
2963 "/numpy-" version ".tar.gz"))
2964 (sha256
2965 (base32
ef9b4c04 2966 "1bjjhvncraka5s6i4lg644jrxij6bvycxy7an20gcz3a0m11iygp"))))
0da98533
FB
2967 (build-system python-build-system)
2968 (inputs
2969 `(("python-nose" ,python-nose)
cba256f8
RW
2970 ("openblas" ,openblas)
2971 ("lapack" ,lapack)))
0da98533 2972 (native-inputs
19afbea1 2973 `(("gfortran" ,gfortran)))
0da98533
FB
2974 (arguments
2975 `(#:phases
2976 (alist-cons-before
2977 'build 'set-environment-variables
2978 (lambda* (#:key inputs #:allow-other-keys)
dbdfe515
RW
2979 (call-with-output-file "site.cfg"
2980 (lambda (port)
cba256f8
RW
2981 (format port
2982 "[openblas]
dbdfe515
RW
2983libraries = openblas
2984library_dirs = ~a/lib
2985include_dirs = ~a/include
cba256f8
RW
2986
2987[lapack]
2988lapack_libs = lapack
2989library_dirs = ~a/lib
2990include_dirs = ~a/include
2991"
2992 (assoc-ref inputs "openblas")
2993 (assoc-ref inputs "openblas")
2994 (assoc-ref inputs "lapack")
2995 (assoc-ref inputs "lapack"))))
dbdfe515
RW
2996 ;; Use "gcc" executable, not "cc".
2997 (substitute* "numpy/distutils/system_info.py"
2998 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
2999 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3000 #t)
6a843168
FB
3001 ;; Tests can only be run after the library has been installed and not
3002 ;; within the source directory.
3003 (alist-cons-after
3004 'install 'check
89b5c60e 3005 (lambda _
6a843168 3006 (with-directory-excursion "/tmp"
89b5c60e 3007 (zero? (system* "python" "-c"
6a843168 3008 "import numpy; numpy.test(verbose=2)"))))
89b5c60e
AE
3009 (alist-delete
3010 'check
6a843168 3011 %standard-phases)))))
0da98533
FB
3012 (home-page "http://www.numpy.org/")
3013 (synopsis "Fundamental package for scientific computing with Python")
3014 (description "NumPy is the fundamental package for scientific computing
e881752c 3015with Python. It contains among other things: a powerful N-dimensional array
0da98533
FB
3016object, sophisticated (broadcasting) functions, tools for integrating C/C++
3017and Fortran code, useful linear algebra, Fourier transform, and random number
3018capabilities.")
3019 (license bsd-3)))
3020
3021(define python2-numpy-bootstrap
3022 (package-with-python2 python-numpy-bootstrap))
15bfe6d6 3023
3a1bfe18
RW
3024(define-public python2-fastlmm
3025 (package
3026 (name "python2-fastlmm")
b074e7d4 3027 (version "0.2.21")
3a1bfe18
RW
3028 (source
3029 (origin
3030 (method url-fetch)
b074e7d4 3031 (uri (pypi-uri "fastlmm" version ".zip"))
3a1bfe18
RW
3032 (sha256
3033 (base32
b074e7d4 3034 "1q8c34rpmwkfy3r4d5172pzdkpfryj561897z9r3x22gq7813x1m"))))
3a1bfe18
RW
3035 (build-system python-build-system)
3036 (arguments
3037 `(#:python ,python-2)) ; only Python 2.7 is supported
3038 (propagated-inputs
3039 `(("python2-numpy" ,python2-numpy)
3040 ("python2-scipy" ,python2-scipy)
3041 ("python2-matplotlib" ,python2-matplotlib)
3042 ("python2-pandas" ,python2-pandas)
3043 ("python2-scikit-learn" ,python2-scikit-learn)
3044 ("python2-cython" ,python2-cython)
3045 ("python2-pysnptools" ,python2-pysnptools)))
3046 (native-inputs
3047 `(("unzip" ,unzip)
3048 ("python2-mock" ,python2-mock)
3049 ("python2-setuptools" ,python2-setuptools)))
3050 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/fastlmm/")
3051 (synopsis "Perform genome-wide association studies on large data sets")
3052 (description
3053 "FaST-LMM, which stands for Factored Spectrally Transformed Linear Mixed
3054Models, is a program for performing both single-SNP and SNP-set genome-wide
3055association studies (GWAS) on extremely large data sets.")
3056 (license asl2.0)))
3057
2ee8869a
FB
3058(define-public python-numpy
3059 (package (inherit python-numpy-bootstrap)
3060 (name "python-numpy")
3061 (outputs '("out" "doc"))
89b5c60e 3062 (inputs
2ee8869a
FB
3063 `(("which" ,which)
3064 ("python-setuptools" ,python-setuptools)
3065 ("python-matplotlib" ,python-matplotlib)
3066 ("python-sphinx" ,python-sphinx)
3067 ("python-pyparsing" ,python-pyparsing)
3068 ("python-numpydoc" ,python-numpydoc)
3069 ,@(package-inputs python-numpy-bootstrap)))
3070 (native-inputs
3071 `(("pkg-config" ,pkg-config)
3072 ("texlive" ,texlive)
3073 ("texinfo" ,texinfo)
3074 ("perl" ,perl)
3075 ,@(package-native-inputs python-numpy-bootstrap)))
3076 (arguments
89b5c60e 3077 `(,@(substitute-keyword-arguments
2ee8869a
FB
3078 (package-arguments python-numpy-bootstrap)
3079 ((#:phases phases)
3080 `(alist-cons-after
3081 'install 'install-doc
3082 (lambda* (#:key outputs #:allow-other-keys)
3083 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
89b5c60e
AE
3084 (doc (string-append
3085 data "/doc/" ,name "-"
2ee8869a
FB
3086 ,(package-version python-numpy-bootstrap)))
3087 (info (string-append data "/info"))
3088 (html (string-append doc "/html"))
3089 (pyver ,(string-append "PYVER=")))
3090 (with-directory-excursion "doc"
3091 (mkdir-p html)
3092 (system* "make" "html" pyver)
3093 (system* "make" "latex" "PAPER=a4" pyver)
89b5c60e 3094 (system* "make" "-C" "build/latex"
2ee8869a
FB
3095 "all-pdf" "PAPER=a4" pyver)
3096 ;; FIXME: Generation of the info file fails.
3097 ;; (system* "make" "info" pyver)
3098 ;; (mkdir-p info)
3099 ;; (copy-file "build/texinfo/numpy.info"
3100 ;; (string-append info "/numpy.info"))
3101 (for-each (lambda (file)
3102 (copy-file (string-append "build/latex" file)
3103 (string-append doc file)))
3104 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3105 (with-directory-excursion "build/html"
3106 (for-each (lambda (file)
3107 (let* ((dir (dirname file))
3108 (tgt-dir (string-append html "/" dir)))
3109 (unless (equal? "." dir)
3110 (mkdir-p tgt-dir))
96c46210 3111 (install-file file html)))
2ee8869a
FB
3112 (find-files "." ".*"))))))
3113 ,phases)))))))
3114
764c077b 3115(define-public python2-numpy
57b7b8cd 3116 (package-with-python2 python-numpy))
2ee8869a 3117
15bfe6d6
FB
3118(define-public python-pyparsing
3119 (package
3120 (name "python-pyparsing")
e0669289 3121 (version "2.0.3")
15bfe6d6
FB
3122 (source
3123 (origin
3124 (method url-fetch)
3125 (uri (string-append "mirror://sourceforge/pyparsing"
3126 "/pyparsing-" version ".tar.gz"))
3127 (sha256
3128 (base32
e0669289 3129 "0kw4py7gn45j93q8r7bzajfrjdc3xlsn2yzln41lf9zmrghjkrq6"))))
15bfe6d6
FB
3130 (build-system python-build-system)
3131 (outputs '("out" "doc"))
3132 (arguments
3133 `(#:tests? #f ; no test target
3134 #:modules ((guix build python-build-system)
3135 (guix build utils))
3136 #:phases
3137 (alist-cons-after
3138 'install 'install-doc
3139 (lambda* (#:key outputs #:allow-other-keys)
89b5c60e 3140 (let* ((doc (string-append (assoc-ref outputs "doc")
15bfe6d6
FB
3141 "/share/doc/" ,name "-" ,version))
3142 (html-doc (string-append doc "/html"))
3143 (examples (string-append doc "/examples")))
3144 (mkdir-p html-doc)
3145 (mkdir-p examples)
89b5c60e 3146 (for-each
15bfe6d6 3147 (lambda (dir tgt)
89b5c60e 3148 (map (lambda (file)
96c46210 3149 (install-file file tgt))
15bfe6d6
FB
3150 (find-files dir ".*")))
3151 (list "docs" "htmldoc" "examples")
3152 (list doc html-doc examples))))
3153 %standard-phases)))
3154 (home-page "http://pyparsing.wikispaces.com")
3155 (synopsis "Python parsing class library")
3156 (description
3157 "The pyparsing module is an alternative approach to creating and
3158executing simple grammars, vs. the traditional lex/yacc approach, or the use
3159of regular expressions. The pyparsing module provides a library of classes
3160that client code uses to construct the grammar directly in Python code.")
bd3fa666 3161 (license license:expat)))
15bfe6d6
FB
3162
3163(define-public python2-pyparsing
3164 (package-with-python2 python-pyparsing))
3165
ec00de35
FB
3166(define-public python-numpydoc
3167 (package
3168 (name "python-numpydoc")
3169 (version "0.5")
3170 (source
3171 (origin
3172 (method url-fetch)
89b5c60e 3173 (uri (string-append
ec00de35
FB
3174 "https://pypi.python.org/packages/source/n/numpydoc/numpydoc-"
3175 version ".tar.gz"))
3176 (sha256
3177 (base32
5e4d8f67
AE
3178 "0d4dnifaxkll50jx6czj05y8cb4ny60njd2wz299sj2jxfy51w4k"))
3179 (modules '((guix build utils)))
3180 (snippet
3181 '(begin
3182 ;; Drop a test requiring matplotlib, which we cannot add as an
3183 ;; input since it would create a circular dependency: Extend the
3184 ;; test for Python 3, where it is already dropped, to Python 2.
3185 (substitute* "numpydoc/tests/test_plot_directive.py"
3186 (("3") "2"))))))
ec00de35
FB
3187 (build-system python-build-system)
3188 (inputs
3189 `(("python-setuptools" ,python-setuptools)
3190 ("python-docutils" ,python-docutils)
3191 ("python-sphinx" ,python-sphinx)
3192 ("python-nose" ,python-nose)))
3193 (home-page "https://pypi.python.org/pypi/numpydoc")
3194 (synopsis
3195 "Numpy's Sphinx extensions")
3196 (description
3197 "Sphinx extension to support docstrings in Numpy format.")
3198 (license bsd-2)))
3199
3200(define-public python2-numpydoc
5e4d8f67 3201 (package-with-python2 python-numpydoc))
1c65314c 3202
1e656049
RW
3203(define-public python-numexpr
3204 (package
3205 (name "python-numexpr")
3206 (version "2.4.4")
3207 (source
3208 (origin
3209 (method url-fetch)
3210 (uri (string-append "https://pypi.python.org/packages/source/"
3211 "n/numexpr/numexpr-" version ".tar.gz"))
3212 (sha256
3213 (base32
3214 "0nsnff5312fm38w6dm34bw7ghfqqy8vl9gig0al963h4mz8zm8nz"))))
3215 (build-system python-build-system)
3216 (arguments `(#:tests? #f)) ; no tests included
3217 (propagated-inputs
3218 `(("python-numpy" ,python-numpy)))
3219 (home-page "https://github.com/pydata/numexpr")
3220 (synopsis "Fast numerical expression evaluator for NumPy")
3221 (description
3222 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3223expressions that operate on arrays are accelerated and use less memory than
3224doing the same calculation in Python. In addition, its multi-threaded
3225capabilities can make use of all your cores, which may accelerate
3226computations, most specially if they are not memory-bounded (e.g. those using
3227transcendental functions).")
3228 (license license:expat)))
3229
3230(define-public python2-numexpr
3231 (let ((numexpr (package-with-python2 python-numexpr)))
3232 (package (inherit numexpr)
3233 ;; Make sure to use special packages for Python 2 instead
3234 ;; of those automatically rewritten by package-with-python2.
3235 (propagated-inputs
3236 `(("python2-numpy" ,python2-numpy)
3237 ,@(alist-delete "python-numpy"
3238 (package-propagated-inputs numexpr)))))))
3239
1c65314c
FB
3240(define-public python-matplotlib
3241 (package
3242 (name "python-matplotlib")
1bbc659f 3243 (version "1.4.3")
1c65314c
FB
3244 (source
3245 (origin
3246 (method url-fetch)
3247 (uri (string-append "mirror://sourceforge/matplotlib"
3248 "/matplotlib-" version ".tar.gz"))
3249 (sha256
3250 (base32
1bbc659f
FB
3251 "1dn05cvd0g984lzhh72wa0z93psgwshbbg93fkab6slx5m3l95av"))
3252 (patches (list (search-patch "matplotlib-setupext-tk.patch")))))
1c65314c
FB
3253 (build-system python-build-system)
3254 (outputs '("out" "doc"))
25f9a068
FB
3255 (propagated-inputs ; the following packages are all needed at run time
3256 `(("python-pyparsing" ,python-pyparsing)
3257 ("python-pygobject" ,python-pygobject)
3258 ("gobject-introspection" ,gobject-introspection)
1bbc659f 3259 ("python-tkinter" ,python "tk")
25f9a068
FB
3260 ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated
3261 ;; from 'gtk+') provides the required 'typelib' files used by
3262 ;; 'gobject-introspection'. The location of these files is set with the
3263 ;; help of the environment variable GI_TYPELIB_PATH. At build time this
3264 ;; is done automatically by a 'native-search-path' procedure. However,
3265 ;; at run-time the user must set this variable as follows:
3266 ;;
3267 ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0
25f9a068
FB
3268 ("gtk+" ,gtk+)
3269 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3270 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3271 ;; object. For this reason we need to import both libraries.
3272 ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo
3273 ("python-pycairo" ,python-pycairo)
3274 ("python-cairocffi" ,python-cairocffi)))
1c65314c
FB
3275 (inputs
3276 `(("python-setuptools" ,python-setuptools)
3277 ("python-dateutil" ,python-dateutil-2)
1c65314c
FB
3278 ("python-six" ,python-six)
3279 ("python-pytz" ,python-pytz)
3280 ("python-numpy" ,python-numpy-bootstrap)
3281 ("python-sphinx" ,python-sphinx)
3282 ("python-numpydoc" ,python-numpydoc)
3283 ("python-nose" ,python-nose)
3284 ("python-mock" ,python-mock)
3285 ("libpng" ,libpng)
3286 ("imagemagick" ,imagemagick)
3287 ("freetype" ,freetype)
25f9a068
FB
3288 ("cairo" ,cairo)
3289 ("glib" ,glib)
4e7a137a 3290 ("python-pillow" ,python-pillow)
1c65314c 3291 ;; FIXME: Add backends when available.
1c65314c
FB
3292 ;("python-wxpython" ,python-wxpython)
3293 ;("python-pyqt" ,python-pyqt)
1bbc659f
FB
3294 ("tcl" ,tcl)
3295 ("tk" ,tk)))
1c65314c
FB
3296 (native-inputs
3297 `(("pkg-config" ,pkg-config)
3298 ("texlive" ,texlive)
3299 ("texinfo" ,texinfo)))
3300 (arguments
3301 `(#:phases
25f9a068
FB
3302 (alist-cons-before
3303 'build 'configure-environment
3304 (lambda* (#:key outputs inputs #:allow-other-keys)
3305 (let ((cairo (assoc-ref inputs "cairo"))
3306 (gtk+ (assoc-ref inputs "gtk+")))
3307 ;; Setting these directories in the 'basedirlist' of 'setup.cfg'
3308 ;; has not effect.
25f9a068
FB
3309 (setenv "LD_LIBRARY_PATH"
3310 (string-append cairo "/lib:" gtk+ "/lib"))
3311 (setenv "HOME" (getcwd))
3312 (call-with-output-file "setup.cfg"
3313 (lambda (port)
1bbc659f
FB
3314 (format port "[directories]~%
3315basedirlist = ~a,~a~%
57b7b8cd 3316 [rc_options]~%
1bbc659f
FB
3317backend = TkAgg~%"
3318 (assoc-ref inputs "tcl")
3319 (assoc-ref inputs "tk"))))))
25f9a068
FB
3320 (alist-cons-after
3321 'install 'install-doc
3322 (lambda* (#:key outputs #:allow-other-keys)
3323 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3324 (doc (string-append data "/doc/" ,name "-" ,version))
3325 (info (string-append data "/info"))
3326 (html (string-append doc "/html")))
3327 (with-directory-excursion "doc"
25f9a068
FB
3328 ;; Produce pdf in 'A4' format.
3329 (substitute* (find-files "." "conf\\.py")
3330 (("latex_paper_size = 'letter'")
3331 "latex_paper_size = 'a4'"))
3332 (mkdir-p html)
3333 (mkdir-p info)
3334 ;; The doc recommends to run the 'html' target twice.
3335 (system* "python" "make.py" "html")
3336 (system* "python" "make.py" "html")
18b31516 3337 (copy-recursively "build/html" html)
25f9a068
FB
3338 (system* "python" "make.py" "latex")
3339 (system* "python" "make.py" "texinfo")
18b31516
FB
3340 (symlink (string-append html "/_images")
3341 (string-append info "/matplotlib-figures"))
3342 (with-directory-excursion "build/texinfo"
3343 (substitute* "matplotlib.texi"
3344 (("@image\\{([^,]*)" all file)
3345 (string-append "@image{matplotlib-figures/" file)))
3346 (symlink (string-append html "/_images")
3347 "./matplotlib-figures")
3348 (system* "makeinfo" "--no-split"
3349 "-o" "matplotlib.info" "matplotlib.texi"))
25f9a068
FB
3350 (copy-file "build/texinfo/matplotlib.info"
3351 (string-append info "/matplotlib.info"))
3352 (copy-file "build/latex/Matplotlib.pdf"
18b31516 3353 (string-append doc "/Matplotlib.pdf")))))
25f9a068 3354 %standard-phases))))
1c65314c
FB
3355 (home-page "http://matplotlib.org")
3356 (synopsis "2D plotting library for Python")
3357 (description
3358 "Matplotlib is a Python 2D plotting library which produces publication
3359quality figures in a variety of hardcopy formats and interactive environments
3360across platforms. Matplotlib can be used in Python scripts, the python and
3361ipython shell, web application servers, and six graphical user interface
3362toolkits.")
57b7b8cd
LC
3363 (license psfl)
3364 (properties `((python2-variant . ,(delay python2-matplotlib))))))
1c65314c 3365
764c077b 3366(define-public python2-matplotlib
57b7b8cd
LC
3367 (let ((matplotlib (package-with-python2
3368 (strip-python2-variant python-matplotlib))))
764c077b 3369 (package (inherit matplotlib)
88c26834
AE
3370 ;; Make sure to use special packages for Python 2 instead
3371 ;; of those automatically rewritten by package-with-python2.
89b5c60e 3372 (propagated-inputs
7ca0dbc3 3373 `(("python2-pycairo" ,python2-pycairo)
764c077b 3374 ("python2-pygobject-2" ,python2-pygobject-2)
1bbc659f
FB
3375 ("python2-tkinter" ,python-2 "tk")
3376 ,@(fold alist-delete (package-propagated-inputs matplotlib)
3377 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
94914805 3378
0dde6232
RW
3379(define-public python2-pysnptools
3380 (package
3381 (name "python2-pysnptools")
3f2e9675 3382 (version "0.3.5")
0dde6232
RW
3383 (source
3384 (origin
3385 (method url-fetch)
3f2e9675 3386 (uri (pypi-uri "pysnptools" version ".zip"))
0dde6232
RW
3387 (sha256
3388 (base32
3f2e9675 3389 "15f4j4w5q603i7mlphb5r6mb1mn33pqg81595fpjp158140yqx7b"))))
0dde6232
RW
3390 (build-system python-build-system)
3391 (arguments
3392 `(#:python ,python-2)) ; only Python 2.7 is supported
3393 (propagated-inputs
3394 `(("python2-numpy" ,python2-numpy)
3395 ("python2-scipy" ,python2-scipy)
3396 ("python2-pandas" ,python2-pandas)
3397 ("python2-cython" ,python2-cython)))
3398 (native-inputs
3399 `(("unzip" ,unzip)
3400 ("python2-setuptools" ,python2-setuptools)))
3401 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/")
3402 (synopsis "Library for reading and manipulating genetic data")
3403 (description
3404 "PySnpTools is a library for reading and manipulating genetic data. It
3405can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
3406those files. It can also efficiently manipulate ranges of integers using set
3407operators such as union, intersection, and difference.")
3408 (license asl2.0)))
3409
c9b1b4f9
RW
3410(define-public python-rpy2
3411 (package
3412 (name "python-rpy2")
ec3bcbc7 3413 (version "2.7.6")
c9b1b4f9
RW
3414 (source
3415 (origin
3416 (method url-fetch)
ec3bcbc7 3417 (uri (pypi-uri "rpy2" version))
c9b1b4f9
RW
3418 (sha256
3419 (base32
ec3bcbc7 3420 "0nhan2qvrw7b7gg5zddwa22kybdv3x1g26vkd7q8lvnkgzrs4dga"))))
c9b1b4f9
RW
3421 (build-system python-build-system)
3422 (inputs
3423 `(("python-six" ,python-six)
3424 ("readline" ,readline)
3425 ("icu4c" ,icu4c)
3426 ("pcre" ,pcre)
3427 ("r" ,r)))
3428 (native-inputs
5ff6575b
RW
3429 `(("python-setuptools" ,python-setuptools)
3430 ("zlib" ,zlib)))
c9b1b4f9
RW
3431 (home-page "http://rpy.sourceforge.net/")
3432 (synopsis "Python interface to the R language")
3433 (description "rpy2 is a redesign and rewrite of rpy. It is providing a
3434low-level interface to R from Python, a proposed high-level interface,
3435including wrappers to graphical libraries, as well as R-like structures and
3436functions.")
3437 (license gpl3+)))
3438
3439(define-public python2-rpy2
3440 (let ((rpy2 (package-with-python2 python-rpy2)))
3441 (package (inherit rpy2)
3442 (native-inputs
3443 `(("python2-singledispatch" ,python2-singledispatch)
3444 ,@(package-native-inputs rpy2))))))
3445
bb986599
FB
3446(define-public python-scipy
3447 (package
3448 (name "python-scipy")
ba8a0824 3449 (version "0.16.0")
bb986599
FB
3450 (source
3451 (origin
3452 (method url-fetch)
3453 (uri (string-append "mirror://sourceforge/scipy"
da6ce3f1 3454 "/scipy-" version ".tar.xz"))
bb986599
FB
3455 (sha256
3456 (base32
ba8a0824 3457 "0wa0a4skpda3gx7lb12yn19nhbairlyxrvda2lz2bcawk3x5qzz2"))))
bb986599 3458 (build-system python-build-system)
dd86c0d1 3459 (propagated-inputs
bb986599
FB
3460 `(("python-numpy" ,python-numpy)
3461 ("python-matplotlib" ,python-matplotlib)
dd86c0d1
RW
3462 ("python-pyparsing" ,python-pyparsing)))
3463 (inputs
3464 `(("lapack" ,lapack)
719b01c1 3465 ("openblas" ,openblas)))
bb986599 3466 (native-inputs
dd86c0d1
RW
3467 `(("python-nose" ,python-nose)
3468 ("python-sphinx" ,python-sphinx)
5248d49e 3469 ("python-numpydoc" ,python-numpydoc)
dd86c0d1 3470 ("gfortran" ,gfortran)
bb986599
FB
3471 ("texlive" ,texlive)
3472 ("perl" ,perl)))
3473 (outputs '("out" "doc"))
3474 (arguments
3475 `(#:phases
3476 (alist-cons-before
719b01c1 3477 'build 'configure-openblas
bb986599 3478 (lambda* (#:key inputs #:allow-other-keys)
719b01c1
RW
3479 (call-with-output-file "site.cfg"
3480 (lambda (port)
3481 (format port
3482 "[blas]
3483libraries = openblas
3484library_dirs = ~a/lib
3485include_dirs = ~a/include
3486[atlas]
3487library_dirs = ~a/lib
3488atlas_libs = openblas
3489"
3490 (assoc-ref inputs "openblas")
3491 (assoc-ref inputs "openblas")
3492 (assoc-ref inputs "openblas"))))
3493 #t)
bb986599
FB
3494 (alist-cons-after
3495 'install 'install-doc
3496 (lambda* (#:key outputs #:allow-other-keys)
3497 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3498 (doc (string-append data "/doc/" ,name "-" ,version))
3499 (html (string-append doc "/html"))
3500 (pyver ,(string-append "PYVER=")))
3501 (with-directory-excursion "doc"
bb986599
FB
3502 ;; Fix generation of images for mathematical expressions.
3503 (substitute* (find-files "source" "conf\\.py")
3504 (("pngmath_use_preview = True")
3505 "pngmath_use_preview = False"))
3506 (mkdir-p html)
3507 (system* "make" "html" pyver)
3508 (system* "make" "latex" "PAPER=a4" pyver)
3509 (system* "make" "-C" "build/latex" "all-pdf" "PAPER=a4" pyver)
3510 (copy-file "build/latex/scipy-ref.pdf"
3511 (string-append doc "/scipy-ref.pdf"))
3512 (with-directory-excursion "build/html"
3513 (for-each (lambda (file)
3514 (let* ((dir (dirname file))
3515 (tgt-dir (string-append html "/" dir)))
96c46210 3516 (install-file file html)))
bb986599
FB
3517 (find-files "." ".*"))))))
3518 ;; Tests can only be run after the library has been installed and not
3519 ;; within the source directory.
3520 (alist-cons-after
3521 'install 'check
89b5c60e 3522 (lambda _
bb986599
FB
3523 (with-directory-excursion "/tmp"
3524 (zero? (system* "python" "-c" "import scipy; scipy.test()"))))
89b5c60e
AE
3525 (alist-delete
3526 'check
4f9ff21e
RW
3527 (alist-cons-after
3528 'unpack 'fix-tests
3529 (lambda _
3530 (substitute* "scipy/integrate/tests/test_quadpack.py"
3531 (("libm.so") "libm.so.6"))
3532 #t)
3533 %standard-phases)))))))
bb986599
FB
3534 (home-page "http://www.scipy.org/")
3535 (synopsis "The Scipy library provides efficient numerical routines")
3536 (description "The SciPy library is one of the core packages that make up
3537the SciPy stack. It provides many user-friendly and efficient numerical
3538routines such as routines for numerical integration and optimization.")
3539 (license bsd-3)))
3540
764c077b 3541(define-public python2-scipy
57b7b8cd 3542 (package-with-python2 python-scipy))
bb986599 3543
94914805
EB
3544(define-public python-sqlalchemy
3545 (package
3546 (name "python-sqlalchemy")
3547 (version "0.9.7")
3548 (source
3549 (origin
3550 (method url-fetch)
3551 (uri (string-append "https://pypi.python.org/packages/source/S/"
3552 "SQLAlchemy/SQLAlchemy-" version ".tar.gz"))
3553 (sha256
3554 (base32
3555 "059ayifj5l08v6vv56anhyibyllscn10dlzr2fcw68gz1hfjdzsz"))))
3556 (build-system python-build-system)
3557 (native-inputs
3558 `(("python-cython" ,python-cython) ;for c extensions
3559 ("python-pytest" ,python-pytest)
3560 ("python-mock" ,python-mock))) ;for tests
3561 (arguments
3562 `(#:phases (alist-replace
3563 'check
3564 (lambda _ (zero? (system* "py.test")))
3565 %standard-phases)))
3566 (home-page "http://www.sqlalchemy.org")
3567 (synopsis "Database abstraction library")
3568 (description
3569 "SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that
3570gives application developers the full power and flexibility of SQL. It
3571provides a full suite of well known enterprise-level persistence patterns,
3572designed for efficient and high-performing database access, adapted into a
3573simple and Pythonic domain language.")
3574 (license x11)))
3575
3576(define-public python2-sqlalchemy
3577 (package-with-python2 python-sqlalchemy))
c937562e 3578
1671c07c
EB
3579(define-public python-distutils-extra
3580 (package
3581 (name "python-distutils-extra")
3582 (version "2.38")
3583 (source
3584 (origin
3585 (method url-fetch)
3586 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
3587 version "/+download/python-distutils-extra-"
3588 version ".tar.gz"))
3589 (sha256
3590 (base32
3591 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
3592 (build-system python-build-system)
3593 (native-inputs
3594 `(("python-setuptools" ,python-setuptools)))
3595 (home-page "https://launchpad.net/python-distutils-extra/")
3596 (synopsis "Enhancements to Python's distutils")
3597 (description
3598 "The python-distutils-extra module enables you to easily integrate
3599gettext support, themed icons, and scrollkeeper-based documentation into
3600Python's distutils.")
3601 (license gpl2)))
3602
3603(define-public python2-distutils-extra
3604 (package-with-python2 python-distutils-extra))
ea5456c8
EB
3605
3606(define-public python2-elib.intl
3607 (package
3608 (name "python2-elib.intl")
3609 (version "0.0.3")
3610 (source
3611 (origin
3612 ;; This project doesn't tag releases or publish tarballs, so we take
3613 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
3614 (method git-fetch)
3615 (uri (git-reference
3616 (url "https://github.com/dieterv/elib.intl.git")
3617 (commit "d09997cfef")))
3618 (sha256
3619 (base32
3620 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
3621 (build-system python-build-system)
3622 (native-inputs
3623 `(("python2-setuptools" ,python2-setuptools)))
3624 (arguments
3625 ;; incompatible with Python 3 (exception syntax)
3626 `(#:python ,python-2
3627 #:tests? #f
3628 ;; With standard flags, the install phase attempts to create a zip'd
3629 ;; egg file, and fails with an error: 'ZIP does not support timestamps
3630 ;; before 1980'
3631 #:configure-flags '("--single-version-externally-managed"
3632 "--record=elib.txt")))
3633 (home-page "https://github.com/dieterv/elib.intl")
3634 (synopsis "Enhanced internationalization for Python")
3635 (description
3636 "The elib.intl module provides enhanced internationalization (I18N)
3637services for your Python modules and applications.")
3638 (license lgpl3+)))
3639
c937562e
EB
3640(define-public python-pillow
3641 (package
3642 (name "python-pillow")
16095d27 3643 (version "3.1.1")
c937562e
EB
3644 (source
3645 (origin
3646 (method url-fetch)
f1d9231d 3647 (uri (pypi-uri "Pillow" version))
c937562e
EB
3648 (sha256
3649 (base32
16095d27 3650 "1zwzakr5v0skdh0azp5cd6fwzbll5305dsk33k5jk570vv6lqvs8"))))
c937562e
EB
3651 (build-system python-build-system)
3652 (native-inputs
3653 `(("python-setuptools" ,python-setuptools)
3654 ("python-nose" ,python-nose)))
3655 (inputs
5ff408d9
SB
3656 `(("freetype" ,freetype)
3657 ("lcms" ,lcms)
c937562e
EB
3658 ("zlib" ,zlib)
3659 ("libjpeg" ,libjpeg)
3660 ("openjpeg" ,openjpeg)
5ff408d9
SB
3661 ("libtiff" ,libtiff)
3662 ("libwebp" ,libwebp)))
c937562e
EB
3663 (propagated-inputs
3664 `(;; Used at runtime for pkg_resources
3665 ("python-setuptools" ,python-setuptools)))
3666 (arguments
e5358a6b
LC
3667 `(#:phases (modify-phases %standard-phases
3668 (add-before
3669 'install 'disable-egg-compression
3670 (lambda _
3671 ;; Leave the .egg uncompressed since compressing it would
3672 ;; prevent the GC from identifying run-time dependencies.
3673 ;; See <http://bugs.gnu.org/20765>.
3674 (let ((port (open-file "setup.cfg" "a")))
3675 (display "\n[easy_install]\nzip_ok = 0\n"
3676 port)
3677 (close-port port)
3678 #t)))
3679 (add-after
3680 'install 'check-installed
3681 (lambda _
3682 (begin
3683 (setenv "HOME" (getcwd))
3684 (and (zero? (system* "python" "selftest.py"
3685 "--installed"))
3686 (zero? (system* "python" "test-installed.py"))))))
3687 (delete 'check))))
c937562e
EB
3688 (home-page "https://pypi.python.org/pypi/Pillow")
3689 (synopsis "Fork of the Python Imaging Library")
3690 (description
3691 "The Python Imaging Library adds image processing capabilities to your
3692Python interpreter. This library provides extensive file format support, an
3693efficient internal representation, and fairly powerful image processing
3694capabilities. The core image library is designed for fast access to data
3695stored in a few basic pixel formats. It should provide a solid foundation for
3696a general image processing tool.")
3697 (license (x11-style
3698 "http://www.pythonware.com/products/pil/license.htm"
3699 "The PIL Software License"))))
3700
3701(define-public python2-pillow
3702 (package-with-python2 python-pillow))
bb986599 3703
a415f036
FB
3704(define-public python-pycparser
3705 (package
3706 (name "python-pycparser")
38eb6919 3707 (version "2.14")
a415f036
FB
3708 (source
3709 (origin
3710 (method url-fetch)
38eb6919 3711 (uri (pypi-uri "pycparser" version))
a415f036
FB
3712 (sha256
3713 (base32
38eb6919 3714 "0wvzyb6rxsfj3xcnpa4ynbh9qc7rrbk2277d5wqpphmx9akv8nbr"))))
a415f036
FB
3715 (outputs '("out" "doc"))
3716 (build-system python-build-system)
3717 (native-inputs
3718 `(("pkg-config" ,pkg-config)
3719 ("python-setuptools" ,python-setuptools)))
3720 (arguments
89b5c60e 3721 `(#:phases
a415f036
FB
3722 (alist-replace
3723 'check
3724 (lambda _
3725 (with-directory-excursion "tests"
3726 (zero? (system* "python" "all_tests.py"))))
3727 (alist-cons-after
3728 'install 'install-doc
3729 (lambda* (#:key outputs #:allow-other-keys)
3730 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3731 (doc (string-append data "/doc/" ,name "-" ,version))
3732 (examples (string-append doc "/examples")))
3733 (mkdir-p examples)
3734 (for-each (lambda (file)
3735 (copy-file (string-append "." file)
3736 (string-append doc file)))
3737 '("/README.rst" "/CHANGES" "/LICENSE"))
3738 (copy-recursively "examples" examples)))
3739 %standard-phases))))
3740 (home-page "https://github.com/eliben/pycparser")
3741 (synopsis "C parser in Python")
3742 (description
3743 "Pycparser is a complete parser of the C language, written in pure Python
3744using the PLY parsing library. It parses C code into an AST and can serve as
3745a front-end for C compilers or analysis tools.")
3746 (license bsd-3)))
3747
3748(define-public python2-pycparser
3749 (package-with-python2 python-pycparser))
57c3f716
FB
3750
3751(define-public python-cffi
3752 (package
3753 (name "python-cffi")
2d3a437c 3754 (version "1.4.2")
57c3f716
FB
3755 (source
3756 (origin
3757 (method url-fetch)
2d3a437c 3758 (uri (pypi-uri "cffi" version))
89b5c60e 3759 (sha256
2d3a437c 3760 (base32 "161rj52rzi3880lij17d6i9kvgkiwjilrqjs8405k8sf6ryif7cg"))))
57c3f716
FB
3761 (build-system python-build-system)
3762 (outputs '("out" "doc"))
3763 (inputs
3764 `(("libffi" ,libffi)))
3765 (propagated-inputs ; required at run-time
3766 `(("python-pycparser" ,python-pycparser)))
3767 (native-inputs
3768 `(("pkg-config" ,pkg-config)
3769 ("python-sphinx" ,python-sphinx)
4179f952 3770 ("python-pytest" ,python-pytest)
57c3f716
FB
3771 ("python-setuptools" ,python-setuptools)))
3772 (arguments
4179f952 3773 `(#:phases
57c3f716
FB
3774 (alist-cons-after
3775 'install 'install-doc
3776 (lambda* (#:key outputs #:allow-other-keys)
3777 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3778 (doc (string-append data "/doc/" ,name "-" ,version))
3779 (html (string-append doc "/html")))
3780 (with-directory-excursion "doc"
3781 (system* "make" "html")
3782 (mkdir-p html)
3783 (copy-recursively "build/html" html))
3784 (copy-file "LICENSE" (string-append doc "/LICENSE"))))
3785 %standard-phases)))
3786 (home-page "http://cffi.readthedocs.org")
3787 (synopsis "Foreign function interface for Python")
3788 (description
3789 "Foreign Function Interface for Python calling C code.")
bd3fa666 3790 (license license:expat)))
57c3f716
FB
3791
3792(define-public python2-cffi
3793 (package-with-python2 python-cffi))
6fa14469
FB
3794
3795(define-public python-xcffib
3796 (package
3797 (name "python-xcffib")
3798 (version "0.1.9")
3799 (source
3800 (origin
3801 (method url-fetch)
3802 (uri (string-append "https://pypi.python.org/packages/source/x/"
3803 "xcffib/xcffib-" version ".tar.gz"))
3804 (sha256
3805 (base32
3806 "0655hzxv57h1a9ja9kwp0ichbkhf3djw32k33d66xp0q37dq2y81"))))
3807 (build-system python-build-system)
3808 (inputs
3809 `(("libxcb" ,libxcb)
3810 ("python-six" ,python-six)))
3811 (native-inputs
3812 `(("python-setuptools" ,python-setuptools)))
3813 (propagated-inputs
3814 `(("python-cffi" ,python-cffi))) ; used at run time
3815 (arguments
89b5c60e 3816 `(#:phases
6fa14469
FB
3817 (alist-cons-after
3818 'install 'install-doc
3819 (lambda* (#:key outputs #:allow-other-keys)
3820 (let ((doc (string-append (assoc-ref outputs "out") "/share"
3821 "/doc/" ,name "-" ,version)))
3822 (mkdir-p doc)
3823 (copy-file "README.md"
3824 (string-append doc "/README.md"))))
3825 %standard-phases)))
3826 (home-page "https://github.com/tych0/xcffib")
3827 (synopsis "XCB Python bindings")
3828 (description
3829 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
3830support for Python 3 and PyPy. It is based on cffi.")
bd3fa666 3831 (license license:expat)))
6fa14469
FB
3832
3833(define-public python2-xcffib
3834 (package-with-python2 python-xcffib))
3835
9e099723
FB
3836(define-public python-cairocffi
3837 (package
3838 (name "python-cairocffi")
3839 (version "0.6")
3840 (source
3841 (origin
3842 (method url-fetch)
3843 ;; The archive on pypi is missing the 'utils' directory!
3844 (uri (string-append "https://github.com/SimonSapin/cairocffi/archive/v"
3845 version ".tar.gz"))
f586c877 3846 (file-name (string-append name "-" version ".tar.gz"))
9e099723
FB
3847 (sha256
3848 (base32
3849 "03w5p62sp3nqiccx864sbq0jvh7946277jqx3rcc3dch5xwfvv51"))))
3850 (build-system python-build-system)
3851 (outputs '("out" "doc"))
3852 (inputs
3853 `(("gdk-pixbuf" ,gdk-pixbuf)
3854 ("cairo" ,cairo)))
3855 (native-inputs
3856 `(("pkg-config" ,pkg-config)
3857 ("python-sphinx" ,python-sphinx)
3858 ("python-docutils" ,python-docutils)
3859 ("python-setuptools" ,python-setuptools)))
3860 (propagated-inputs
3861 `(("python-xcffib" ,python-xcffib))) ; used at run time
3862 (arguments
89b5c60e 3863 `(#:phases
9e099723
FB
3864 (alist-cons-after
3865 'install 'install-doc
3866 (lambda* (#:key inputs outputs #:allow-other-keys)
3867 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3868 (doc (string-append data "/doc/" ,name "-" ,version))
3869 (html (string-append doc "/html")))
89b5c60e 3870 (setenv "LD_LIBRARY_PATH"
9e099723
FB
3871 (string-append (assoc-ref inputs "cairo") "/lib" ":"
3872 (assoc-ref inputs "gdk-pixbuf") "/lib"))
3873 (setenv "LANG" "en_US.UTF-8")
3874 (mkdir-p html)
3875 (for-each (lambda (file)
3876 (copy-file (string-append "." file)
3877 (string-append doc file)))
3878 '("/README.rst" "/CHANGES" "/LICENSE"))
3879 (system* "python" "setup.py" "build_sphinx")
3880 (copy-recursively "docs/_build/html" html)))
3881 %standard-phases)))
3882 (home-page "https://github.com/SimonSapin/cairocffi")
3883 (synopsis "Python bindings and object-oriented API for Cairo")
3884 (description
3885 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
3886Python bindings and object-oriented API for cairo. Cairo is a 2D vector
3887graphics library with support for multiple backends including image buffers,
3888PNG, PostScript, PDF, and SVG file output.")
3889 (license bsd-3)))
3890
3891(define-public python2-cairocffi
3892 (package-with-python2 python-cairocffi))
3893
3cff95cb
RW
3894(define-public python-decorator
3895 (package
3896 (name "python-decorator")
e21338be 3897 (version "4.0.6")
3cff95cb
RW
3898 (source
3899 (origin
3900 (method url-fetch)
e21338be 3901 (uri (pypi-uri "decorator" version))
3cff95cb 3902 (sha256
e21338be 3903 (base32 "1710cwsbwr8fkiq59w2min7rwgdz7ly51yz8l8yh1zbpfxcm8qhw"))))
3cff95cb
RW
3904 (build-system python-build-system)
3905 (arguments '(#:tests? #f)) ; no test target
3906 (native-inputs
3907 `(("python-setuptools" ,python-setuptools)))
3908 (home-page "http://pypi.python.org/pypi/decorator/")
3909 (synopsis "Python module to simplify usage of decorators")
3910 (description
3911 "The aim of the decorator module is to simplify the usage of decorators
3912for the average programmer, and to popularize decorators usage giving examples
3913of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
3914etc. The core of this module is a decorator factory.")
3915 (license license:expat)))
3916
3917(define-public python2-decorator
3918 (package-with-python2 python-decorator))
3919
2c0499ad
RW
3920(define-public python-drmaa
3921 (package
3922 (name "python-drmaa")
3923 (version "0.7.6")
3924 (source
3925 (origin
3926 (method url-fetch)
3927 (uri (string-append
3928 "https://pypi.python.org/packages/source/d/drmaa/drmaa-"
3929 version ".tar.gz"))
3930 (sha256
3931 (base32 "0bzl9f9g34dlhwf09i3fdv7dqqzf2iq0w7d6c2bafx1nlap8qfbh"))))
3932 (build-system python-build-system)
3933 ;; The test suite requires libdrmaa which is provided by the cluster
3934 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
3935 ;; should be set to the path of the libdrmaa library.
3936 (arguments '(#:tests? #f))
3937 (native-inputs
3938 `(("python-nose" ,python-nose)
3939 ("python-setuptools" ,python-setuptools)))
3940 (home-page "https://pypi.python.org/pypi/drmaa")
3941 (synopsis "Python bindings for the DRMAA library")
3942 (description
3943 "A Python package for Distributed Resource Management (DRM) job
3944submission and control. This package is an implementation of the DRMAA 1.0
3945Python language binding specification.")
3946 (license bsd-3)))
3947
3948(define-public python2-drmaa
3949 (package-with-python2 python-drmaa))
3950
d05c6da0
RW
3951(define-public python-gridmap
3952 (package
3953 (name "python-gridmap")
3954 (version "0.13.0")
3955 (source
3956 (origin
3957 (method url-fetch)
3958 (uri (string-append
3959 "https://github.com/pygridtools/gridmap/archive/v"
3960 version ".tar.gz"))
3961 (file-name (string-append name "-" version ".tar.gz"))
3962 (sha256
3963 (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x"))))
3964 (build-system python-build-system)
3965 (inputs
3966 `(("python-psutil" ,python-psutil)
3967 ("python-drmaa" ,python-drmaa)
3968 ("python-pyzmq" ,python-pyzmq)))
3969 (native-inputs
3970 `(("python-setuptools" ,python-setuptools)))
3971 (home-page "https://github.com/pygridtools/gridmap")
3972 (synopsis "Create jobs on a cluster directly from Python")
3973 (description
3974 "Gridmap is a Python package to allow you to easily create jobs on the
3975cluster directly from Python. You can directly map Python functions onto the
3976cluster without needing to write any wrapper code yourself.")
3977 (license gpl3+)))
3978
3979(define-public python2-gridmap
3980 (package-with-python2 python-gridmap))
3981
cb6d5c54
RW
3982(define-public python-pexpect
3983 (package
3984 (name "python-pexpect")
3985 (version "3.3")
3986 (source
3987 (origin
3988 (method url-fetch)
3989 (uri (string-append "https://pypi.python.org/packages/source/p/"
3990 "pexpect/pexpect-" version ".tar.gz"))
3991 (sha256
3992 (base32 "1fp5gm976z7ghm8jw57463rj19cv06c8zw842prgyg788f6n3snz"))))
3993 (build-system python-build-system)
3994 (arguments
3995 `(#:phases
3996 (modify-phases %standard-phases
3997 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
3998 (native-inputs
3999 `(("python-nose" ,python-nose)))
4000 (home-page "http://pexpect.readthedocs.org/")
4001 (synopsis "Controlling interactive console applications")
4002 (description
4003 "Pexpect is a pure Python module for spawning child applications;
4004controlling them; and responding to expected patterns in their output.
4005Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4006child application and control it as if a human were typing commands.")
4007 (license isc)))
4008
4009(define-public python2-pexpect
4010 (package-with-python2 python-pexpect))
4011
229ad120
RW
4012(define-public python-setuptools-scm
4013 (package
4014 (name "python-setuptools-scm")
383af6b0 4015 (version "1.9.0")
229ad120
RW
4016 (source (origin
4017 (method url-fetch)
383af6b0 4018 (uri (pypi-uri "setuptools_scm" version))
229ad120
RW
4019 (sha256
4020 (base32
383af6b0 4021 "0y24bl893zk6nrklbvdrlmpkalf214zjn6k1xrglljd29rrn4wxi"))))
229ad120 4022 (build-system python-build-system)
383af6b0 4023 (native-inputs `(("python-setuptools" ,python-setuptools)))
229ad120
RW
4024 (home-page "https://github.com/pypa/setuptools_scm/")
4025 (synopsis "Manage Python package versions in SCM metadata")
4026 (description
383af6b0 4027 "Setuptools_scm handles managing your Python package versions in
229ad120
RW
4028@dfn{software configuration management} (SCM) metadata instead of declaring
4029them as the version argument or in a SCM managed file.")
4030 (license license:expat)))
4031
4032(define-public python2-setuptools-scm
4033 (package-with-python2 python-setuptools-scm))
4034
b74270ee
RW
4035(define-public python-pathpy
4036 (package
4037 (name "python-pathpy")
4038 (version "8.1.1")
4039 (source
4040 (origin
4041 (method url-fetch)
4042 (uri (string-append "https://pypi.python.org/packages/source/p/"
4043 "path.py/path.py-" version ".tar.gz"))
4044 (sha256
4045 (base32 "1p8s1l2vfkqhqxdhqlj0g1jjw4f1as2frr35sjcpjjpd5a89y41f"))))
4046 (build-system python-build-system)
4047 (propagated-inputs
4048 `(("python-appdirs" ,python-appdirs)))
4049 (native-inputs
553b709b
EF
4050 `(("python-setuptools" ,python-setuptools)
4051 ("python-setuptools-scm" ,python-setuptools-scm)
b74270ee
RW
4052 ("python-pytest" ,python-pytest)
4053 ("python-pytest-runner" ,python-pytest-runner)))
4054 (home-page "http://github.com/jaraco/path.py")
4055 (synopsis "Python module wrapper for built-in os.path")
4056 (description
4057 "@code{path.py} implements path objects as first-class entities, allowing
4058common operations on files to be invoked on those path objects directly.")
4059 (license license:expat)))
4060
4061(define-public python2-pathpy
4062 (package-with-python2 python-pathpy))
4063
0d34e01b
RW
4064(define-public python-pickleshare
4065 (package
4066 (name "python-pickleshare")
4067 (version "0.5")
4068 (source
4069 (origin
4070 (method url-fetch)
4071 (uri (string-append "https://pypi.python.org/packages/source/p/"
4072 "pickleshare/pickleshare-" version ".tar.gz"))
4073 (sha256
4074 (base32 "11ljr90j3p6qswdrbl7p4cjb2i93f6vn0vx9anzpshsx0d2mggn0"))))
4075 (build-system python-build-system)
4076 (propagated-inputs
4077 `(("python-pathpy" ,python-pathpy)))
b72a4410
EF
4078 (native-inputs
4079 `(("python-setuptools" ,python-setuptools)))
0d34e01b
RW
4080 (home-page "https://github.com/vivainio/pickleshare")
4081 (synopsis "Tiny key value database with concurrency support")
4082 (description
4083 "PickleShare is a small ‘shelve’-like datastore with concurrency support.
4084Like shelve, a PickleShareDB object acts like a normal dictionary. Unlike
4085shelve, many processes can access the database simultaneously. Changing a
4086value in database is immediately visible to other processes accessing the same
4087database. Concurrency is possible because the values are stored in separate
4088files. Hence the “database” is a directory where all files are governed by
4089PickleShare.")
4090 (license license:expat)))
4091
4092(define-public python2-pickleshare
4093 (package-with-python2 python-pickleshare))
4094
cd6e5189
RW
4095(define-public python-simplegeneric
4096 (package
4097 (name "python-simplegeneric")
4098 (version "0.8.1")
4099 (source
4100 (origin
4101 (method url-fetch)
4102 (uri (string-append "https://pypi.python.org/packages/source/s/"
4103 "simplegeneric/simplegeneric-" version ".zip"))
4104 (sha256
4105 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
4106 (build-system python-build-system)
4107 (native-inputs
69b96e5e
RW
4108 `(("python-setuptools" ,python-setuptools)
4109 ("unzip" ,unzip)))
cd6e5189
RW
4110 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
4111 (synopsis "Python module for simple generic functions")
4112 (description
4113 "The simplegeneric module lets you define simple single-dispatch generic
4114functions, akin to Python’s built-in generic functions like @code{len()},
4115@code{iter()} and so on. However, instead of using specially-named methods,
4116these generic functions use simple lookup tables, akin to those used by
4117e.g. @code{pickle.dump()} and other generic functions found in the Python
4118standard library.")
4119 (license zpl2.1)))
4120
4121(define-public python2-simplegeneric
4122 (package-with-python2 python-simplegeneric))
4123
ddc7d8ed
RW
4124(define-public python-ipython-genutils
4125 (package
4126 (name "python-ipython-genutils")
4127 (version "0.1.0")
4128 (source
4129 (origin
4130 (method url-fetch)
4131 (uri (string-append "https://pypi.python.org/packages/source/i/"
4132 "ipython_genutils/ipython_genutils-"
4133 version ".tar.gz"))
4134 (sha256
4135 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
4136 (build-system python-build-system)
4137 (arguments `(#:tests? #f)) ; no tests
4138 (home-page "http://ipython.org")
4139 (synopsis "Vestigial utilities from IPython")
4140 (description
4141 "This package provides retired utilities from IPython.")
4142 (license bsd-3)))
4143
4144(define-public python2-ipython-genutils
4145 (package-with-python2 python-ipython-genutils))
4146
2b10eb48
RW
4147(define-public python-traitlets
4148 (package
4149 (name "python-traitlets")
4150 (version "4.0.0")
4151 (source
4152 (origin
4153 (method url-fetch)
4154 (uri (string-append "https://pypi.python.org/packages/source/t/"
4155 "traitlets/traitlets-" version ".tar.gz"))
4156 (sha256
4157 (base32
4158 "0fr3w2xwb46c591dp7zw02bgf4d21mjy9g6rhwc9bwd4ji50n50b"))))
4159 (build-system python-build-system)
4160 (arguments
4161 `(#:phases
4162 (modify-phases %standard-phases
4163 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4164 (propagated-inputs
4165 `(("python-ipython-genutils" ,python-ipython-genutils)
4166 ("python-decorator" ,python-decorator)))
4167 (native-inputs
4168 `(("python-nose" ,python-nose)))
4169 (home-page "http://ipython.org")
4170 (synopsis "Configuration system for Python applications")
4171 (description
4172 "Traitlets is a framework that lets Python classes have attributes with
4173type checking, dynamically calculated default values, and ‘on change’
4174callbacks. The package also includes a mechanism to use traitlets for
4175configuration, loading values from files or from command line arguments. This
4176is a distinct layer on top of traitlets, so you can use traitlets in your code
4177without using the configuration machinery.")
4178 (license bsd-3)))
4179
4180(define-public python2-traitlets
4181 (package-with-python2 python-traitlets))
4182
ae1ab9fe
FB
4183(define-public python-ipython
4184 (package
4185 (name "python-ipython")
3a0b1b9a 4186 (version "3.2.1")
ae1ab9fe
FB
4187 (source
4188 (origin
fceac880
FB
4189 (method url-fetch)
4190 (patches (list (search-patch "python-ipython-inputhook-ctype.patch")))
4191 (uri (string-append "https://pypi.python.org/packages/source/i/"
4192 "ipython/ipython-" version ".tar.gz"))
4193 (sha256
4194 (base32 "0xwin0sa9n0cabx4cq1ibf5ldsiw5dyimibla82kicz5gbpas4y9"))))
ae1ab9fe
FB
4195 (build-system python-build-system)
4196 (outputs '("out" "doc"))
3a0b1b9a
FB
4197 (propagated-inputs
4198 `(("python-pyzmq" ,python-pyzmq)
4199 ("python-terminado" ,python-terminado)))
ae1ab9fe
FB
4200 (inputs
4201 `(("readline" ,readline)
3a0b1b9a 4202 ("which" ,which)
ae1ab9fe 4203 ("python-matplotlib" ,python-matplotlib)
5d26e542 4204 ("python-numpy" ,python-numpy)
ae1ab9fe 4205 ("python-numpydoc" ,python-numpydoc)
3a0b1b9a
FB
4206 ("python-jinja2" ,python-jinja2)
4207 ("python-mistune" ,python-mistune)
4208 ("python-jsonschema" ,python-jsonschema)
4209 ("python-pygments" ,python-pygments)
4210 ("python-requests" ,python-requests) ;; for tests
ae1ab9fe
FB
4211 ("python-nose" ,python-nose)))
4212 (native-inputs
4213 `(("pkg-config" ,pkg-config)
4214 ("python-sphinx" ,python-sphinx)
4215 ("texlive" ,texlive)
4216 ("texinfo" ,texinfo)
4217 ("python-setuptools" ,python-setuptools)))
4218 (arguments
89b5c60e 4219 `(#:phases
3a0b1b9a
FB
4220 (modify-phases %standard-phases
4221 (add-after
4222 'install 'install-doc
4223 (lambda* (#:key inputs outputs #:allow-other-keys)
4224 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4225 (doc (string-append data "/doc/" ,name "-" ,version))
4226 (html (string-append doc "/html"))
4227 (man1 (string-append data "/man/man1"))
4228 (info (string-append data "/info"))
4229 (examples (string-append doc "/examples")))
afd3d931 4230 (setenv "LANG" "en_US.utf8")
3a0b1b9a
FB
4231 (with-directory-excursion "docs"
4232 ;; FIXME: html and pdf fail to build
4233 ;; (system* "make" "html")
4234 ;; (system* "make" "pdf" "PAPER=a4")
4235 (system* "make" "info"))
4236 (copy-recursively "docs/man" man1)
4237 (copy-recursively "examples" examples)
4238 ;; (copy-recursively "docs/build/html" html)
4239 ;; (copy-file "docs/build/latex/ipython.pdf"
4240 ;; (string-append doc "/ipython.pdf"))
4241 (mkdir-p info)
4242 (copy-file "docs/build/texinfo/ipython.info"
4243 (string-append info "/ipython.info"))
4244 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))
4245 ;; Tests can only be run after the library has been installed and not
4246 ;; within the source directory.
4247 (delete 'check)
4248 (add-after
4249 'install 'check
4250 (lambda* (#:key outputs tests? #:allow-other-keys)
4251 (if tests?
4252 (with-directory-excursion "/tmp"
4253 (setenv "HOME" "/tmp/") ;; required by a test
4254 (zero? (system* (string-append (assoc-ref outputs "out")
4255 "/bin/iptest"))))
4256 #t)))
4257 (add-before
4258 'install 'fix-tests
4259 (lambda* (#:key inputs #:allow-other-keys)
4260 (substitute* "./IPython/utils/_process_posix.py"
4261 (("/usr/bin/env', 'which") (which "which")))
4262 (substitute* "./IPython/core/tests/test_inputtransformer.py"
4263 (("#!/usr/bin/env python")
4264 (string-append "#!" (which "python"))))
4265 ;; Disable 1 failing test
4266 (substitute* "./IPython/core/tests/test_magic.py"
4267 (("def test_dirops\\(\\):" all)
4268 (string-append "@dec.skipif(True)\n" all))))))))
ae1ab9fe
FB
4269 (home-page "http://ipython.org")
4270 (synopsis "IPython is a tool for interactive computing in Python")
4271 (description
4272 "IPython provides a rich architecture for interactive computing with:
4273Powerful interactive shells, a browser-based notebook, support for interactive
4274data visualization, embeddable interpreters and tools for parallel
4275computing.")
4276 (license bsd-3)))
4277
4278(define-public python2-ipython
4279 (let ((ipython (package-with-python2 python-ipython)))
3a0b1b9a
FB
4280 (package
4281 (inherit ipython)
4282 ;; FIXME: some tests are failing
4283 (arguments
4284 `(#:tests? #f ,@(package-arguments ipython)))
ae1ab9fe 4285 ;; Make sure we use custom python2-NAME packages.
3a0b1b9a 4286 ;; FIXME: add pyreadline once available.
667d90df
RW
4287 (propagated-inputs
4288 `(("python2-terminado" ,python2-terminado)
4289 ,@(alist-delete "python-terminado"
4290 (package-propagated-inputs ipython))))
89b5c60e 4291 (inputs
264ae686
EF
4292 `(("python2-jsonschema" ,python2-jsonschema)
4293 ("python2-mock" ,python2-mock)
3a0b1b9a 4294 ("python2-matplotlib" ,python2-matplotlib)
5587253a 4295 ("python2-numpy" ,python2-numpy)
264ae686 4296 ("python2-requests" ,python2-requests)
5587253a 4297 ,@(fold alist-delete (package-inputs ipython)
264ae686 4298 '("python-jsonschema" "python-matplotlib" "python-numpy" "python-requests")))))))
03411993
AE
4299
4300(define-public python-isodate
4301 (package
4302 (name "python-isodate")
4303 (version "0.5.1")
4304 (source
4305 (origin
4306 (method url-fetch)
4307 (uri (string-append
4308 "https://pypi.python.org/packages/source/i/isodate/isodate-"
4309 version
4310 ".tar.gz"))
4311 (sha256
4312 (base32
4313 "1yqjn0is0p64cmk9xhq4hc6q06jk86d60kg2jws58d78q0qysami"))))
4314 (build-system python-build-system)
4315 (inputs
4316 `(("python-setuptools" ,python-setuptools)))
4317 (home-page
4318 "http://cheeseshop.python.org/pypi/isodate")
4319 (synopsis
4320 "Python date parser and formatter")
4321 (description
4322 "Python-isodate is a python module for parsing and formatting
4323ISO 8601 dates, time and duration.")
4324 (license bsd-3)))
4325
4326(define-public python2-isodate
4327 (package-with-python2 python-isodate))
673ab897
AE
4328
4329(define-public python-html5lib
4330 (package
4331 (name "python-html5lib")
4332 (version "1.0b3")
4333 (source
4334 (origin
4335 (method url-fetch)
4336 (uri (string-append
4337 "https://pypi.python.org/packages/source/h/html5lib/html5lib-"
4338 version
4339 ".tar.gz"))
4340 (sha256
4341 (base32
4342 "1l5i6xzckzx4hnh9qzv9q3kyhkgjx2hsi2k9srgci3qizjmvp6ln"))))
4343 (build-system python-build-system)
3dd75476
AE
4344 (propagated-inputs
4345 `(("python-six" ,python-six))) ; required to "import html5lib"
673ab897
AE
4346 (inputs
4347 `(("python-setuptools" ,python-setuptools)))
4348 (arguments
4349 `(#:test-target "check"))
4350 (home-page
4351 "https://github.com/html5lib/html5lib-python")
4352 (synopsis
4353 "Python HTML parser based on the WHATWG HTML specifcation")
4354 (description
4355 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
4356and written in Python.")
bd3fa666 4357 (license license:expat)))
673ab897
AE
4358
4359(define-public python2-html5lib
4360 (package-with-python2 python-html5lib))
e99f4211
MW
4361
4362(define-public python-urwid
4363 (package
4364 (name "python-urwid")
4365 (version "1.3.0")
4366 (source
4367 (origin
4368 (method url-fetch)
b97c1bfd 4369 (uri (pypi-uri "urwid" version))
e99f4211
MW
4370 (sha256
4371 (base32
4372 "18mb0yy94sjc434rd61m2sfnw27sa0nyrszpj5a9r9zh7fnlzw19"))))
4373 (build-system python-build-system)
b97c1bfd
LF
4374 (arguments
4375 `(#:phases
4376 (modify-phases %standard-phases
4377 ;; Disable failing test. Bug filed upstream:
4378 ;; https://github.com/wardi/urwid/issues/164
4379 ;; TODO: check again for python-urwid > 1.3.0 or python > 3.4.3.
4380 (add-after 'unpack 'disable-failing-test
4381 (lambda _
4382 (substitute* "urwid/tests/test_event_loops.py"
4383 (("test_remove_watch_file")
4384 "disable_remove_watch_file")))))))
e99f4211
MW
4385 (native-inputs `(("python-setuptools" ,python-setuptools)))
4386 (home-page "http://urwid.org")
4387 (synopsis "Console user interface library for Python")
4388 (description
4389 "Urwid is a curses-based UI/widget library for Python. It includes many
4390features useful for text console applications.")
4391 (license lgpl2.1+)))
4392
4393(define-public python2-urwid
4394 (package-with-python2 python-urwid))
d95a56c6
PAR
4395
4396(define-public python-dbus
4397 (package
4398 (name "python-dbus")
4399 (version "1.2.0")
4400 (source
4401 (origin
4402 (method url-fetch)
4403 (uri (string-append
4404 "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-"
4405 version ".tar.gz"))
4406 (sha256
4407 (base32 "1py62qir966lvdkngg0v8k1khsqxwk5m4s8nflpk1agk5f5nqb71"))))
4408 (build-system gnu-build-system)
6717c879
SB
4409 (arguments
4410 '(#:phases
4411 (modify-phases %standard-phases
4412 (add-before
4413 'check 'pre-check
4414 (lambda _
4415 ;; XXX: For the missing '/etc/machine-id'.
4416 (substitute* "test/run-test.sh"
4417 (("DBUS_FATAL_WARNINGS=1")
4418 "DBUS_FATAL_WARNINGS=0"))
4419 #t)))))
d95a56c6
PAR
4420 (native-inputs
4421 `(("pkg-config" ,pkg-config)))
4422 (inputs
4423 `(("python" ,python)
2e88d113 4424 ("dbus-glib" ,dbus-glib)))
d95a56c6
PAR
4425 (synopsis "Python bindings for D-bus")
4426 (description "python-dbus provides bindings for libdbus, the reference
4427implementation of D-Bus.")
4428 (home-page "http://www.freedesktop.org/wiki/Software/DBusBindings/")
bd3fa666 4429 (license license:expat)))
b52af02b
MW
4430
4431(define-public python2-dbus
4432 (package (inherit python-dbus)
4433 (name "python2-dbus")
4434 (inputs `(("python" ,python-2)
4435 ,@(alist-delete "python"
4436 (package-inputs python-dbus)
4437 equal?)))
4438 ;; FIXME: on Python 2, the test_utf8 fails with:
4439 ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)"
4440 (arguments `(#:tests? #f))))
a6ac8332
AE
4441
4442(define-public python-apsw
4443 (package
4444 (name "python-apsw")
917708c2 4445 (version "3.9.2-r1")
a6ac8332
AE
4446 (source
4447 (origin
4448 (method url-fetch)
917708c2 4449 (uri (pypi-uri "apsw" version))
a6ac8332
AE
4450 (sha256
4451 (base32
917708c2 4452 "0w4jb0wpx785qw42r3h4fh7gl5w2968q48i7gygybsfxck8nzffs"))))
a6ac8332
AE
4453 (build-system python-build-system)
4454 (inputs
4455 `(("python-setuptools" ,python-setuptools)
4456 ("sqlite" ,sqlite)))
4457 (arguments
4458 `(#:phases
4459 ;; swap check and install phases
4460 (alist-cons-after
4461 'install 'check
4462 (assoc-ref %standard-phases 'check)
4463 (alist-delete
4464 'check
4465 %standard-phases))))
4466 (home-page "https://github.com/rogerbinns/apsw/")
4467 (synopsis "Another Python SQLite Wrapper")
4468 (description "APSW is a Python wrapper for the SQLite
4469embedded relational database engine. In contrast to other wrappers such as
4470pysqlite it focuses on being a minimal layer over SQLite attempting just to
4471translate the complete SQLite API into Python.")
abde5f37 4472 (license license:zlib)))
a6ac8332
AE
4473
4474(define-public python2-apsw
4475 (package-with-python2 python-apsw))
26b307e2
AE
4476
4477(define-public python-lxml
4478 (package
4479 (name "python-lxml")
4480 (version "3.4.2")
4481 (source
4482 (origin
4483 (method url-fetch)
4484 (uri (string-append
4485 "https://pypi.python.org/packages/source/l/lxml/lxml-"
4486 version
4487 ".tar.gz"))
4488 (sha256
4489 (base32
4490 "0pd23qz8vms1mgm41p96h4vac5y91igs4wr9640gnvxgk019kmf7"))))
4491 (build-system python-build-system)
4492 (inputs
4493 `(("libxml2" ,libxml2)
4494 ("libxslt" ,libxslt)
4495 ("python-setuptools" ,python-setuptools)))
4496 (home-page "http://lxml.de/")
4497 (synopsis
4498 "Python XML processing library")
4499 (description
4500 "The lxml XML toolkit is a Pythonic binding for the C libraries
4501libxml2 and libxslt.")
4502 (license bsd-3))) ; and a few more, see LICENSES.txt
4503
4504(define-public python2-lxml
4505 (package-with-python2 python-lxml))
4ed20663 4506
bec07a7c
AE
4507(define-public python2-pil
4508 (package
4509 (name "python2-pil")
4510 (version "1.1.7")
4511 (source
4512 (origin
4513 (method url-fetch)
4514 (uri (string-append
4515 "http://effbot.org/downloads/Imaging-"
4516 version ".tar.gz"))
4517 (sha256
4518 (base32
516277cb
AE
4519 "04aj80jhfbmxqzvmq40zfi4z3cw6vi01m3wkk6diz3lc971cfnw9"))
4520 (modules '((guix build utils)))
4521 (snippet
4522 ;; Adapt to newer freetype. As the package is unmaintained upstream,
4523 ;; there is no use in creating a patch and reporting it.
4524 '(substitute* "_imagingft.c"
4525 (("freetype/")
4526 "freetype2/")))))
bec07a7c
AE
4527 (build-system python-build-system)
4528 (inputs
4529 `(("freetype" ,freetype)
4530 ("libjpeg" ,libjpeg)
4531 ("libtiff" ,libtiff)
4532 ("python-setuptools" ,python-setuptools)
4533 ("zlib" ,zlib)))
4534 (arguments
4535 ;; Only the fork python-pillow works with Python 3.
4536 `(#:python ,python-2
4537 #:tests? #f ; no check target
4538 #:phases
4539 (alist-cons-before
4540 'build 'configure
4541 ;; According to README and setup.py, manual configuration is
4542 ;; the preferred way of "searching" for inputs.
4543 ;; lcms is not found, TCL_ROOT refers to the unavailable tkinter.
4544 (lambda* (#:key inputs #:allow-other-keys)
4545 (let ((jpeg (assoc-ref inputs "libjpeg"))
4546 (zlib (assoc-ref inputs "zlib"))
4547 (tiff (assoc-ref inputs "libtiff"))
4548 (freetype (assoc-ref inputs "freetype")))
4549 (substitute* "setup.py"
4550 (("JPEG_ROOT = None")
4551 (string-append "JPEG_ROOT = libinclude(\"" jpeg "\")"))
4552 (("ZLIB_ROOT = None")
4553 (string-append "ZLIB_ROOT = libinclude(\"" zlib "\")"))
4554 (("TIFF_ROOT = None")
4555 (string-append "TIFF_ROOT = libinclude(\"" tiff "\")"))
4556 (("FREETYPE_ROOT = None")
4557 (string-append "FREETYPE_ROOT = libinclude(\""
4558 freetype "\")")))))
4559 %standard-phases)))
4560 (home-page "http://www.pythonware.com/products/pil/")
4561 (synopsis "Python Imaging Library")
4562 (description "The Python Imaging Library (PIL) adds image processing
4563capabilities to the Python interpreter.")
4564 (license (x11-style
4565 "file://README"
4566 "See 'README' in the distribution."))))
092e86f5
AE
4567
4568(define-public python2-cssutils
4569 (package
4570 (name "python2-cssutils")
4571 (version "1.0")
4572 (source
4573 (origin
4574 (method url-fetch)
4575 (uri (string-append
4576 "https://pypi.python.org/packages/source/c/cssutils/cssutils-"
4577 version
4578 ".zip"))
4579 (sha256
4580 (base32
4581 "1bwim1353r4hqiir73sn4sc43y7ymh09qx0kly7vj048blppc125"))))
4582 (build-system python-build-system)
4583 (native-inputs
4584 `(("python2-mock" ,python2-mock) ; for the tests
4585 ("unzip" ,unzip))) ; for unpacking the source
4586 (inputs
4587 `(("python2-setuptools" ,python2-setuptools)))
4588 (arguments
4589 `(#:python ,python-2 ; Otherwise tests fail with a syntax error.
4590 #:tests? #f ; The tests apparently download an external URL.
da6dd842 4591 ))
092e86f5
AE
4592 (home-page "http://cthedot.de/cssutils/")
4593 (synopsis
4594 "CSS Cascading Style Sheets library for Python")
4595 (description
4596 "Cssutils is a Python package for parsing and building CSS
4597Cascading Style Sheets. Currently it provides a DOM only and no rendering
4598options.")
4599 (license lgpl3+)))
880ff77c
AE
4600
4601(define-public python-cssselect
4602 (package
4603 (name "python-cssselect")
4604 (version "0.9.1")
4605 (source
4606 (origin
4607 (method url-fetch)
4608 (uri (string-append
4609 "https://pypi.python.org/packages/source/c/cssselect/cssselect-"
4610 version
4611 ".tar.gz"))
4612 (sha256
4613 (base32
4614 "10h623qnp6dp1191jri7lvgmnd4yfkl36k9smqklp1qlf3iafd85"))))
4615 (build-system python-build-system)
4616 (inputs
4617 `(("python-setuptools" ,python-setuptools)))
4618 (arguments
4619 ;; tests fail with message
4620 ;; AttributeError: 'module' object has no attribute 'tests'
4621 `(#:tests? #f))
4622 (home-page
4623 "https://pythonhosted.org/cssselect/")
4624 (synopsis
4625 "CSS3 selector parser and translator to XPath 1.0")
4626 (description
4627 "Cssselect ia a Python module that parses CSS3 Selectors and translates
4628them to XPath 1.0 expressions. Such expressions can be used in lxml or
4629another XPath engine to find the matching elements in an XML or HTML document.")
4630 (license bsd-3)))
4631
4632(define-public python2-cssselect
4633 (package-with-python2 python-cssselect))
60357f99
AE
4634
4635(define-public python-netifaces
4636 (package
4637 (name "python-netifaces")
4638 (version "0.10.4")
4639 (source
4640 (origin
4641 (method url-fetch)
4642 (uri (string-append
4643 "https://pypi.python.org/packages/source/n/netifaces/netifaces-"
4644 version
4645 ".tar.gz"))
4646 (sha256
4647 (base32
4648 "1plw237a4zib4z8s62g0mrs8gm3kjfrp5sxh6bbk9nl3rdls2mln"))))
4649 (build-system python-build-system)
4650 (inputs
4651 `(("python-setuptools" ,python-setuptools)))
4652 (home-page
4653 "https://bitbucket.org/al45tair/netifaces")
4654 (synopsis
4655 "Python module for portable network interface information")
4656 (description
4657 "Netifaces is a Python module providing information on network
4658interfaces in an easy and portable manner.")
4659 (license license:expat)))
4660
4661(define-public python2-netifaces
4662 (package-with-python2 python-netifaces))
92cb152b 4663
32f77c04
RW
4664(define-public python-networkx
4665 (package
4666 (name "python-networkx")
4667 (version "1.9.1")
4668 (source
4669 (origin
4670 (method url-fetch)
4671 (uri (string-append
4672 "https://pypi.python.org/packages/source/n/networkx/networkx-"
4673 version ".tar.gz"))
4674 (sha256
4675 (base32 "0n8wy0yq1kmdq4wh68mlhwhkndvwzx48lg41a1z0sxxms0wfp033"))))
4676 (build-system python-build-system)
4677 ;; python-decorator is needed at runtime
4678 (propagated-inputs
4679 `(("python-decorator" ,python-decorator)))
4680 (native-inputs
4681 `(("python-setuptools" ,python-setuptools)
4682 ("python-nose" ,python-nose)))
4683 (home-page "http://networkx.github.io/")
4684 (synopsis "Python module for creating and manipulating graphs and networks")
4685 (description
4686 "NetworkX is a Python package for the creation, manipulation, and study
4687of the structure, dynamics, and functions of complex networks.")
4688 (license bsd-3)))
4689
4690(define-public python2-networkx
4691 (package-with-python2 python-networkx))
4692
92cb152b
RW
4693(define-public snakemake
4694 (package
4695 (name "snakemake")
4696 (version "3.2.1")
4697 (source
4698 (origin
4699 (method url-fetch)
4700 (uri (string-append
4701 "https://pypi.python.org/packages/source/s/snakemake/snakemake-"
4702 version ".tar.gz"))
4703 (sha256
4704 (base32 "0fi4b63sj60hvi7rfydvmz2icl4wj74djw5sn2gl8hxd02qw4b91"))))
4705 (build-system python-build-system)
4706 (inputs `(("python-setuptools" ,python-setuptools)))
4707 (home-page "https://bitbucket.org/johanneskoester/snakemake")
4708 (synopsis "Python-based execution environment for make-like workflows")
4709 (description
4710 "Snakemake aims to reduce the complexity of creating workflows by
4711providing a clean and modern domain specific specification language (DSL) in
4712Python style, together with a fast and comfortable execution environment.")
4713 (license license:expat)))
a1920bc9 4714
35de1fbd
RW
4715(define-public python-seaborn
4716 (package
4717 (name "python-seaborn")
4718 (version "0.5.1")
4719 (source
4720 (origin
4721 (method url-fetch)
4722 (uri (string-append
4723 "https://pypi.python.org/packages/source/s/seaborn/seaborn-"
4724 version ".tar.gz"))
4725 (sha256
4726 (base32 "1236abw18ijjglmv60q85ckqrvgf5qyy4zlq7nz5aqfg6q87z3wc"))))
4727 (build-system python-build-system)
4728 (propagated-inputs
4729 `(("python-pandas" ,python-pandas)
4730 ("python-matplotlib" ,python-matplotlib)
4731 ("python-scipy" ,python-scipy)))
4732 (native-inputs
4733 `(("python-setuptools" ,python-setuptools)))
4734 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
4735 (synopsis "Statistical data visualization")
4736 (description
4737 "Seaborn is a library for making attractive and informative statistical
4738graphics in Python. It is built on top of matplotlib and tightly integrated
4739with the PyData stack, including support for numpy and pandas data structures
4740and statistical routines from scipy and statsmodels.")
4741 (license bsd-3)))
4742
4743(define-public python2-seaborn
4744 (let ((seaborn (package-with-python2 python-seaborn)))
4745 (package (inherit seaborn)
4746 (propagated-inputs
4747 `(("python2-pytz" ,python2-pytz)
dab8ebd9
FB
4748 ("python2-pandas" ,python2-pandas)
4749 ("python2-matplotlib" ,python2-matplotlib)
4750 ("python2-scipy" ,python2-scipy))))))
35de1fbd 4751
90fc547f
RW
4752(define-public python-sympy
4753 (package
4754 (name "python-sympy")
4755 (version "0.7.6")
4756 (source
4757 (origin
4758 (method url-fetch)
4759 (uri (string-append
4760 "https://github.com/sympy/sympy/releases/download/sympy-"
4761 version "/sympy-" version ".tar.gz"))
4762 (sha256
4763 (base32 "19yp0gy4i7p4g6l3b8vaqkj9qj7yqb5kqy0qgbdagpzgkdz958yz"))))
4764 (build-system python-build-system)
4765 (native-inputs
4766 `(("python-setuptools" ,python-setuptools)))
4767 (home-page "http://www.sympy.org/")
4768 (synopsis "Python library for symbolic mathematics")
4769 (description
4770 "SymPy is a Python library for symbolic mathematics. It aims to become a
4771full-featured computer algebra system (CAS) while keeping the code as simple
4772as possible in order to be comprehensible and easily extensible.")
4773 (license bsd-3)))
4774
4775(define-public python2-sympy
4776 (package-with-python2 python-sympy))
4777
a1920bc9
FB
4778(define-public python-testlib
4779 (package
4780 (name "python-testlib")
4781 (version "0.6.5")
4782 (source
4783 (origin
4784 (method url-fetch)
4785 (uri (string-append
4786 "https://pypi.python.org/packages/source/t/testlib/testlib-"
4787 version ".zip"))
4788 (sha256
4789 (base32 "1mz26cxn4x8bbgv0rn0mvj2z05y31rkc8009nvdlb3lam5b4mj3y"))))
4790 (build-system python-build-system)
4791 (inputs
4792 `(("python-setuptools" ,python-setuptools)))
4793 (native-inputs
4794 `(("unzip" ,unzip)))
4795 (arguments
4796 `(#:phases
4797 (alist-replace
4798 'unpack
4799 (lambda* (#:key inputs outputs #:allow-other-keys)
4800 (let ((unzip (string-append (assoc-ref inputs "unzip")
4801 "/bin/unzip"))
4802 (source (assoc-ref inputs "source")))
4803 (and (zero? (system* unzip source))
4804 (chdir (string-append "testlib-" ,version)))))
4805 %standard-phases)))
4806 (synopsis "Python micro test suite harness")
4807 (description "A micro unittest suite harness for Python.")
4808 (home-page "https://github.com/trentm/testlib")
1cb9c006 4809 (license license:expat)))
a1920bc9
FB
4810
4811(define-public python2-testlib
4812 (package-with-python2 python-testlib))
db62afa5
LC
4813
4814(define-public python2-xlib
4815 (package
4816 (name "python2-xlib")
4817 (version "0.14")
4818 (source (origin
4819 (method url-fetch)
4820 (uri (string-append "mirror://sourceforge/python-xlib/"
4821 "python-xlib-" version ".tar.gz"))
4822 (sha256
4823 (base32
4824 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
4825 (build-system python-build-system)
4826 (arguments
4827 `(#:python ,python-2 ;Python 2 only
4828 #:tests? #f)) ;no tests
4829 (inputs
4830 `(("python-setuptools" ,python-setuptools)))
4831 (home-page "http://python-xlib.sourceforge.net/")
4832 (synopsis "Python X11 client library")
4833 (description
4834 "The Python X Library is intended to be a fully functional X client
4835library for Python programs. It is useful to implement low-level X clients.
4836It is written entirely in Python.")
4837 (license gpl2+)))
0234ca06
DT
4838
4839(define-public python-singledispatch
4840 (package
4841 (name "python-singledispatch")
4842 (version "3.4.0.3")
4843 (source
4844 (origin
4845 (method url-fetch)
4846 (uri (string-append
4847 "https://pypi.python.org/packages/source/s/singledispatch/"
4848 "singledispatch-" version ".tar.gz"))
4849 (sha256
4850 (base32
4851 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
4852 (build-system python-build-system)
4853 (native-inputs
4854 `(("python-setuptools" ,python-setuptools)))
4855 (propagated-inputs
4856 `(("python-six" ,python-six)))
4857 (home-page
4858 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
4859 (synopsis "Backport of singledispatch feature from Python 3.4")
4860 (description
4861 "This library brings functools.singledispatch from Python 3.4 to Python
48622.6-3.3.")
4863 (license license:expat)))
4864
4865(define-public python2-singledispatch
4866 (package-with-python2 python-singledispatch))
feaae484 4867
310d218f
RW
4868(define-public python-tornado
4869 (package
4870 (name "python-tornado")
4871 (version "4.1")
4872 (source
4873 (origin
4874 (method url-fetch)
4875 (uri (string-append
4876 "https://pypi.python.org/packages/source/t/tornado/"
4877 "tornado-" version ".tar.gz"))
4878 (sha256
4879 (base32 "0a12f00h277zbifibnj46wf14801f573irvf6hwkgja5vspd7awr"))))
4880 (build-system python-build-system)
4881 (inputs
4882 `(("python-certifi" ,python-certifi)))
4883 (native-inputs
4884 `(("python-setuptools" ,python-setuptools)))
f4a4a718 4885 (home-page "http://www.tornadoweb.org/")
310d218f
RW
4886 (synopsis "Python web framework and asynchronous networking library")
4887 (description
4888 "Tornado is a Python web framework and asynchronous networking library,
4889originally developed at FriendFeed. By using non-blocking network I/O,
4890Tornado can scale to tens of thousands of open connections, making it ideal
4891for long polling, WebSockets, and other applications that require a long-lived
4892connection to each user.")
4893 (license asl2.0)))
4894
4895(define-public python2-tornado
4896 (let ((tornado (package-with-python2 python-tornado)))
4897 (package (inherit tornado)
4898 (inputs
4899 `(("python2-backport-ssl-match-hostname"
4900 ,python2-backport-ssl-match-hostname)
4901 ,@(package-inputs tornado))))))
4902
feaae484
SB
4903(define-public python-waf
4904 (package
4905 (name "python-waf")
4906 (version "1.8.8")
4907 (source (origin
4908 (method url-fetch)
4909 (uri (string-append "https://waf.io/"
4910 "waf-" version ".tar.bz2"))
4911 (sha256
4912 (base32
4913 "0b5q307fgn6a5d8yjia2d1l4bk1q3ilvc0w8k4isfrrx2gbcw8wn"))))
4914 (build-system python-build-system)
4915 (arguments
4916 '(#:phases
4917 (modify-phases %standard-phases
4918 (replace 'build
4919 (lambda _
4920 (zero? (begin
4921 (system* "python" "waf-light" "configure")
4922 (system* "python" "waf-light" "build")))))
4923 (replace 'check
4924 (lambda _
4925 (zero? (system* "python" "waf" "--version"))))
4926 (replace 'install
4927 (lambda _
4928 (copy-file "waf" %output))))))
4929 (home-page "https://waf.io/")
4930 (synopsis "Python-based build system")
4931 (description
4932 "Waf is a Python-based framework for configuring, compiling and installing
4933applications.")
4934 (license bsd-3)))
4935
4936(define-public python2-waf
4937 (package-with-python2 python-waf))
45203542
RW
4938
4939(define-public python-pyzmq
4940 (package
4941 (name "python-pyzmq")
3655ee76 4942 (version "15.1.0")
45203542
RW
4943 (source
4944 (origin
4945 (method url-fetch)
3655ee76 4946 (uri (pypi-uri "pyzmq" version))
45203542 4947 (sha256
3655ee76 4948 (base32 "13fhwnlvsvxv72kfhqbpn6qi7msh8mc8377mpabv32skk2cjfnxx"))))
45203542
RW
4949 (build-system python-build-system)
4950 (arguments
4951 `(#:configure-flags
4952 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
4953 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
4954 ;; --inplace' for 'python setup.py test' to work.
4955 #:tests? #f))
4956 (inputs
4957 `(("zeromq" ,zeromq)))
4958 (native-inputs
4959 `(("pkg-config" ,pkg-config)
4960 ("python-nose" ,python-nose)
4961 ("python-setuptools" ,python-setuptools)))
4962 (home-page "http://github.com/zeromq/pyzmq")
4963 (synopsis "Python bindings for 0MQ")
4964 (description
4965 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
4966 (license bsd-4)))
4967
4968(define-public python2-pyzmq
4969 (package-with-python2 python-pyzmq))
d889e6c4
CR
4970
4971(define-public python-pep8
4972 (package
4973 (name "python-pep8")
4974 (version "1.6.2")
4975 (source
4976 (origin
4977 (method url-fetch)
4978 (uri (string-append
4979 "https://pypi.python.org/packages/source/p/pep8/pep8-"
4980 version
4981 ".tar.gz"))
4982 (sha256
4983 (base32
4984 "1zybkcdw1sx84dvkfss96nhykqg9bc0cdpwpl4k9wlxm61bf7dxq"))))
4985 (build-system python-build-system)
4986 (inputs
4987 `(("python-setuptools" ,python-setuptools)))
4988 (home-page "http://pep8.readthedocs.org/")
4989 (synopsis "Python style guide checker")
4990 (description
4991 "This tools checks Python code against some of the style conventions in
4992PEP 8.")
4993 (license license:expat)))
4994
4995(define-public python2-pep8
4996 (package-with-python2 python-pep8))
e31d7f44
CR
4997
4998(define-public python-pyflakes
4999 (package
5000 (name "python-pyflakes")
2abc3972 5001 (version "1.0.0")
e31d7f44
CR
5002 (source
5003 (origin
5004 (method url-fetch)
2abc3972 5005 (uri (pypi-uri "pyflakes" version))
e31d7f44
CR
5006 (sha256
5007 (base32
2abc3972 5008 "0qs2sgqszq7wcplis8509wk2ygqcrwzbs1ghfj3svvivq2j377pk"))))
e31d7f44
CR
5009 (build-system python-build-system)
5010 (inputs
5011 `(("python-setuptools" ,python-setuptools)))
5012 (home-page
5013 "https://github.com/pyflakes/pyflakes")
5014 (synopsis "Passive checker of Python programs")
5015 (description
5016 "Pyflakes statically checks Python source code for common errors.")
5017 (license license:expat)))
a59e017c 5018
7261d9eb
CR
5019(define-public python2-pyflakes
5020 (package-with-python2 python-pyflakes))
5021
a59e017c
CR
5022(define-public python-mccabe
5023 (package
5024 (name "python-mccabe")
5025 (version "0.3.1")
5026 (source
5027 (origin
5028 (method url-fetch)
5029 (uri (string-append
5030 "https://pypi.python.org/packages/source/m/mccabe/mccabe-"
5031 version
5032 ".tar.gz"))
5033 (sha256
5034 (base32
5035 "05ix3vdv5hjk4irl97n2n3c4g1vqvz7dbmkzs13f3bx97bxsczjz"))))
5036 (build-system python-build-system)
5037 (inputs
5038 `(("python-setuptools" ,python-setuptools)))
5039 (home-page "https://github.com/flintwork/mccabe")
5040 (synopsis "McCabe checker, plugin for flake8")
5041 (description
5042 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
5043complexity of Python source code.")
7362371d 5044 (license license:expat)))
a59e017c
CR
5045
5046(define-public python2-mccabe
5047 (package-with-python2 python-mccabe))
e8df8f47 5048
7477fbb1
CR
5049(define-public python-mccabe-0.2.1
5050 (package (inherit python-mccabe)
5051 (version "0.2.1")
5052 (source
5053 (origin
5054 (method url-fetch)
5055 (uri (pypi-uri "mccabe" version))
5056 (sha256
5057 (base32
5058 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))))
5059
5060(define-public python2-mccabe-0.2.1
5061 (package-with-python2 python-mccabe-0.2.1))
5062
e8df8f47
CR
5063;; Flake8 2.4.1 requires an older version of pep8.
5064;; This should be removed ASAP.
5065(define-public python-pep8-1.5.7
5066 (package (inherit python-pep8)
5067 (version "1.5.7")
5068 (source
5069 (origin
5070 (method url-fetch)
5071 (uri (string-append
5072 "https://pypi.python.org/packages/source/p/pep8/pep8-"
5073 version
5074 ".tar.gz"))
5075 (sha256
5076 (base32
5077 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))))
5078
5079(define-public python2-pep8-1.5.7
5080 (package-with-python2 python-pep8-1.5.7))
5081
5082;; Flake8 2.4.1 requires an older version of pyflakes.
5083;; This should be removed ASAP.
5084(define-public python-pyflakes-0.8.1
5085 (package (inherit python-pyflakes)
5086 (version "0.8.1")
5087 (source
5088 (origin
5089 (method url-fetch)
5090 (uri (string-append
5091 "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-"
5092 version
5093 ".tar.gz"))
5094 (sha256
5095 (base32
5096 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))))
5097
5098(define-public python2-pyflakes-0.8.1
7261d9eb 5099 (package-with-python2 python-pyflakes-0.8.1))
e8df8f47
CR
5100
5101(define-public python-flake8
5102 (package
5103 (name "python-flake8")
1b995533 5104 (version "2.5.1")
e8df8f47
CR
5105 (source
5106 (origin
5107 (method url-fetch)
1b995533 5108 (uri (pypi-uri "flake8" version))
e8df8f47
CR
5109 (sha256
5110 (base32
1b995533 5111 "00sn2g5ydriv5anbipcrprpv797kh4q8rfa75w3fc7v7n14fv2j4"))))
e8df8f47
CR
5112 (build-system python-build-system)
5113 (inputs
5114 `(("python-setuptools" ,python-setuptools)
5115 ("python-pep8" ,python-pep8-1.5.7)
5116 ("python-pyflakes" ,python-pyflakes-0.8.1)
5117 ("python-mccabe" ,python-mccabe)
5118 ("python-mock" ,python-mock)
5119 ("python-nose" ,python-nose)))
5120 (home-page "https://gitlab.com/pycqa/flake8")
5121 (synopsis
5122 "The modular source code checker: pep8, pyflakes and co")
5123 (description
5124 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
5125 (license license:expat)))
5126
5127(define-public python2-flake8
5128 (package-with-python2 python-flake8))
61b9ac53 5129
abf21efc
CR
5130;; This will only be needed by the python-hacking package and will not be
5131;; necessary once python-hacking > 0.10.2 is released.
5132(define-public python-flake8-2.2.4
5133 (package (inherit python-flake8)
5134 (inputs
5135 `(("python-setuptools" ,python-setuptools)
5136 ("python-pep8" ,python-pep8-1.5.7)
5137 ("python-pyflakes" ,python-pyflakes-0.8.1)
5138 ("python-mccabe" ,python-mccabe-0.2.1)
5139 ("python-mock" ,python-mock)
5140 ("python-nose" ,python-nose)))
5141 (version "2.2.4")
5142 (source
5143 (origin
5144 (method url-fetch)
5145 (uri (pypi-uri "flake8" version))
5146 (sha256
5147 (base32
5148 "1r9wsry4va45h1rck5hxd3vzsg2q3y6lnl6pym1bxvz8ry19jwx8"))))))
5149
5150(define-public python2-flake8-2.2.4
5151 (package-with-python2 python-flake8-2.2.4))
5152
61b9ac53
FB
5153(define-public python-mistune
5154 (package
5155 (name "python-mistune")
5156 (version "0.7")
5157 (source
5158 (origin
5159 (method url-fetch)
5160 (uri (string-append
5161 "https://pypi.python.org/packages/source/m/mistune/mistune-"
5162 version
5163 ".tar.gz"))
5164 (sha256
5165 (base32
5166 "17zqjp9m4d1w3jf2rbbq5xshcw24q1vlcv24gkgfqqyyymajxahx"))))
5167 (build-system python-build-system)
5168 (inputs
5169 `(("python-setuptools" ,python-setuptools)
5170 ("python-nose" ,python-nose)
5171 ("python-cython" ,python-cython)))
5172 (home-page "https://github.com/lepture/mistune")
5173 (synopsis "Markdown parser in pure Python")
5174 (description "This package provides a fast markdown parser in pure
5175Python.")
5176 (license bsd-3)))
5177
5178(define-public python2-mistune
5179 (package-with-python2 python-mistune))
6d992d07 5180
b9893908
EE
5181(define-public python-markdown
5182 (package
5183 (name "python-markdown")
5184 (version "2.6.5")
5185 (source
5186 (origin
5187 (method url-fetch)
5188 (uri (pypi-uri "Markdown" version))
5189 (sha256
5190 (base32
5191 "0q758a3fiiawr20b3hhjfs677cwj6xi284yb7xspcvv0fdicz54d"))))
5192 (build-system python-build-system)
5193 (arguments
5194 `(#:phases
5195 (modify-phases %standard-phases
5196 (replace 'check
5197 (lambda _
5198 (zero? (system* "python" "run-tests.py")))))))
5199 (native-inputs
5200 `(("python-nose" ,python-nose)
5201 ("python-pyyaml" ,python-pyyaml)))
5202 (home-page "https://pythonhosted.org/Markdown/")
5203 (synopsis "Python implementation of Markdown")
5204 (description
5205 "This package provides a Python implementation of John Gruber's
5206Markdown. The library features international input, various Markdown
5207extensions, and several HTML output formats. A command line wrapper
5208markdown_py is also provided to convert Markdown files to HTML.")
5209 (license bsd-3)))
5210
5211(define-public python2-markdown
5212 (package-with-python2 python-markdown))
5213
6d992d07
FB
5214(define-public python-ptyprocess
5215 (package
5216 (name "python-ptyprocess")
5217 (version "0.5")
5218 (source
5219 (origin
5220 (method url-fetch)
5221 (uri (string-append
5222 "https://pypi.python.org/packages/source/p/ptyprocess/ptyprocess-"
5223 version ".tar.gz"))
5224 (sha256
5225 (base32
5226 "0nggns5kikn32yyda2zrj1xdmh49pi3v0drggcdwljbv36r8zdyw"))))
5227 (build-system python-build-system)
5228 (inputs
5229 `(("python-setuptools" ,python-setuptools)
5230 ("python-nose" ,python-nose)))
5231 (arguments
5232 `(#:phases
5233 (modify-phases %standard-phases
5234 (replace 'check
5235 (lambda _
5236 (zero? (system* "nosetests")))))))
5237 (home-page "https://github.com/pexpect/ptyprocess")
5238 (synopsis "Run a subprocess in a pseudo terminal")
5239 (description
5240 "This package provides a Python library used to launch a subprocess in a
5241pseudo terminal (pty), and interact with both the process and its pty.")
5242 (license isc)))
5243
5244(define-public python2-ptyprocess
5245 (package-with-python2 python-ptyprocess))
4aadb1df
FB
5246
5247(define-public python-terminado
5248 (package
5249 (name "python-terminado")
5250 (version "0.5")
5251 (source
5252 (origin
5253 (method url-fetch)
5254 (uri (string-append
5255 "https://pypi.python.org/packages/source/t/terminado/terminado-"
5256 version ".tar.gz"))
5257 (sha256
5258 (base32
5259 "1dkmp1n8dj5v1jl9mfrq8lwyc7dsfrvcmz2bgkpg315sy7pr7s33"))))
5260 (build-system python-build-system)
5261 (propagated-inputs
5262 `(("python-tornado" ,python-tornado)
5263 ("python-ptyprocess" ,python-ptyprocess)))
5264 (inputs
5265 `(("python-setuptools" ,python-setuptools)
5266 ("python-nose" ,python-nose)))
5267 (arguments
5268 `(#:phases
5269 (modify-phases %standard-phases
5270 (replace 'check
5271 (lambda _
5272 (zero? (system* "nosetests")))))))
5273 (home-page "https://github.com/takluyver/terminado")
5274 (synopsis "Terminals served to term.js using Tornado websockets")
5275 (description "This package provides a Tornado websocket backend for the
5276term.js Javascript terminal emulator library.")
5277 (license bsd-2)))
5278
5279(define-public python2-terminado
5280 (let ((terminado (package-with-python2 python-terminado)))
5281 (package (inherit terminado)
5282 (propagated-inputs
5283 `(("python2-tornado" ,python2-tornado)
5284 ("python2-backport-ssl-match-hostname"
5285 ,python2-backport-ssl-match-hostname)
5286 ,@(alist-delete "python-tornado"
5287 (package-propagated-inputs terminado)))))))
5faa5ce4 5288
d582eaac
SB
5289(define-public python-fonttools
5290 (package
5291 (name "python-fonttools")
5292 (version "2.5")
5293 (source (origin
5294 (method url-fetch)
5295 (uri (string-append
5296 "https://pypi.python.org/packages/source/F/FontTools/"
5297 "fonttools-" version ".tar.gz"))
5298 (sha256
5299 (base32
5300 "08ay3x4ijarwhl60gqx2i9jzq6pxs20p4snc2d1q5jagh4rn39lb"))))
5301 (build-system python-build-system)
5302 (arguments '(#:test-target "check"))
5303 (propagated-inputs
5304 ;; XXX: module not found if setuptools is not available.
5305 `(("python-setuptools" ,python-setuptools)))
5306 (home-page "http://github.com/behdad/fonttools")
5307 (synopsis "Tools to manipulate font files")
5308 (description
5309 "FontTools/TTX is a library to manipulate font files from Python. It
5310supports reading and writinfg of TrueType/OpenType fonts, reading and writing
5311of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
5312also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
5313from an XML-based format.")
5314 (license (non-copyleft "file://LICENSE.txt"
5315 "See LICENSE.txt in the distribution."))))
5316
5317(define-public python2-fonttools
5318 (package-with-python2 python-fonttools))
75710da6 5319
5faa5ce4
RW
5320(define-public python-ly
5321 (package
5322 (name "python-ly")
5323 (version "0.9.2")
5324 (source
5325 (origin
5326 (method url-fetch)
5327 (uri (string-append
5328 "https://pypi.python.org/packages/source/p/python-ly/python-ly-"
5329 version ".tar.gz"))
5330 (sha256
5331 (base32
5332 "1bsjg4q9ihr8bfdclrcmb8yjcg8xm9dznh58f3zsyrkrjzwbhcd2"))))
5333 (build-system python-build-system)
5334 (native-inputs
5335 `(("python-setuptools" ,python-setuptools)))
5336 (synopsis "Tool and library for manipulating LilyPond files")
5337 (description "This package provides a Python library to parse, manipulate
5338or create documents in LilyPond format. A command line program ly is also
5339provided that can be used to do various manipulations with LilyPond files.")
5340 (home-page "https://pypi.python.org/pypi/python-ly")
5341 (license gpl2+)))
7e7b27d9
CR
5342
5343(define-public python-appdirs
5344 (package
5345 (name "python-appdirs")
5346 (version "1.4.0")
5347 (source
5348 (origin
5349 (method url-fetch)
5350 (uri (string-append
5351 "https://pypi.python.org/packages/source/a/appdirs/appdirs-"
5352 version
5353 ".tar.gz"))
5354 (sha256
5355 (base32
5356 "1iddva7v3fq0aqzsahkazxr7vpw28mqcrsy818z4wyiqnkplbhlg"))))
5357 (build-system python-build-system)
5358 (inputs
5359 `(("python-setuptools" ,python-setuptools)))
5360 (home-page "http://github.com/ActiveState/appdirs")
5361 (synopsis
5362 "Determine platform-specific dirs, e.g. a \"user data dir\"")
5363 (description
5364 "This module provides a portable way of finding out where user data
5365should be stored on various operating systems.")
5366 (license license:expat)))
5367
5368(define-public python2-appdirs
5369 (package-with-python2 python-appdirs))
89b2e0b0
LF
5370
5371(define-public python-llfuse
5372 (package
5373 (name "python-llfuse")
5374 (version "0.41")
5375 (source (origin
5376 (method url-fetch)
5377 (uri (string-append
5378 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5379 "llfuse-" version ".tar.bz2"))
5380 (sha256
5381 (base32
5382 "0yzy8ixpmxk00kdq6lx5vvwbs0n6s59qnja5q0js2ahbqyxiz2hb"))))
5383 (build-system python-build-system)
5384 (inputs
5385 `(("fuse" ,fuse)
5386 ("attr" ,attr)))
5387 (native-inputs
5388 `(("pkg-config" ,pkg-config)
5389 ("python-setuptools" ,python-setuptools)))
5390 (synopsis "Python bindings for FUSE")
5391 (description
5392 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
5393 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
5394 ;; Python-LLFUSE includes underscore.js, which is MIT (expat) licensed.
5395 ;; The rest of the package is licensed under LGPL2.0 or later.
5396 (license (list license:expat lgpl2.0+))))
5397
5398(define-public python2-llfuse
5399 (package-with-python2 python-llfuse))
641c9871
LF
5400
5401(define-public python-msgpack
5402 (package
5403 (name "python-msgpack")
5404 (version "0.4.6")
5405 (source (origin
5406 (method url-fetch)
5407 (uri (string-append
5408 "https://pypi.python.org/packages/source/m/"
5409 "msgpack-python/msgpack-python-" version ".tar.gz"))
5410 (sha256
5411 (base32
5412 "1527c76b6fn4zzkgfq5xvhh7x9a9686g7fjiz717rw5vklf5ik5z"))))
5413 (build-system python-build-system)
5414 (native-inputs
5415 `(("python-setuptools" ,python-setuptools)))
5416 (synopsis "MessagePack (de)serializer")
5417 (description "MessagePack is a fast, compact binary serialization format,
5418suitable for similar data to JSON. This package provides CPython bindings for
5419reading and writing MessagePack data.")
5420 (home-page "https://pypi.python.org/pypi/msgpack-python/")
5421 (license asl2.0)))
5422
5423(define-public python2-msgpack
5424 (package-with-python2 python-msgpack))
6e5e39f4
CR
5425
5426(define-public python-netaddr
5427 (package
5428 (name "python-netaddr")
5429 (version "0.7.18")
5430 (source
5431 (origin
5432 (method url-fetch)
5433 (uri (string-append
5434 "https://pypi.python.org/packages/source/n/netaddr/netaddr-"
5435 version
5436 ".tar.gz"))
5437 (sha256
5438 (base32
5439 "06dxjlbcicq7q3vqy8agq11ra01kvvd47j4mk6dmghjsyzyckxd1"))))
5440 (build-system python-build-system)
5441 (arguments `(#:tests? #f)) ;; No tests.
5442 (inputs
5443 `(("python-setuptools" ,python-setuptools)))
5444 (home-page "https://github.com/drkjam/netaddr/")
5445 (synopsis "Pythonic manipulation of network addresses")
5446 (description
5447 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
5448and MAC network addresses.")
5449 (license bsd-3)))
5450
5451(define-public python2-netaddr
5452 (package-with-python2 python-netaddr))
8c692a52
CR
5453
5454(define-public python-wrapt
5455 (package
5456 (name "python-wrapt")
5457 (version "1.10.5")
5458 (source
5459 (origin
5460 (method url-fetch)
5461 (uri (string-append
5462 "https://pypi.python.org/packages/source/w/wrapt/wrapt-"
5463 version
5464 ".tar.gz"))
5465 (sha256
5466 (base32
5467 "0cq8rlpzkxzk48b50yrfhzn1d1hrq4gjcdqlrgq4v5palgiv9jwr"))))
5468 (build-system python-build-system)
5469 (arguments
5470 ;; Tests are not included in the tarball, they are only available in the
5471 ;; git repository.
5472 `(#:tests? #f))
5473 (inputs
5474 `(("python-setuptools" ,python-setuptools)))
5475 (home-page "https://github.com/GrahamDumpleton/wrapt")
5476 (synopsis "Module for decorators, wrappers and monkey patching")
5477 (description
5478 "The aim of the wrapt module is to provide a transparent object proxy for
5479 Python, which can be used as the basis for the construction of function
5480 wrappers and decorator functions.")
5481 (license bsd-2)))
5482
5483(define-public python2-wrapt
5484 (package-with-python2 python-wrapt))
b85c85be
CR
5485
5486(define-public python-iso8601
5487 (package
5488 (name "python-iso8601")
5489 (version "0.1.10")
5490 (source
5491 (origin
5492 (method url-fetch)
5493 (uri (string-append
5494 "https://pypi.python.org/packages/source/i/iso8601/iso8601-"
5495 version
5496 ".tar.gz"))
5497 (sha256
5498 (base32
5499 "1qf01afxh7j4gja71vxv345if8avg6nnm0ry0zsk6j3030xgy4p7"))))
5500 (build-system python-build-system)
5501 (inputs
5502 `(("python-setuptools" ,python-setuptools)))
5503 (home-page "https://bitbucket.org/micktwomey/pyiso8601")
5504 (synopsis "Module to parse ISO 8601 dates")
5505 (description
5506 "This module parses the most common forms of ISO 8601 date strings (e.g.
5507@code{2007-01-14T20:34:22+00:00}) into @code{datetime} objects.")
5508 (license license:expat)))
5509
5510(define-public python2-iso8601
5511 (package-with-python2 python-iso8601))
5e412b63
CR
5512
5513(define-public python-monotonic
5514 (package
5515 (name "python-monotonic")
5516 (version "0.3")
5517 (source
5518 (origin
5519 (method url-fetch)
5520 (uri (string-append
5521 "https://pypi.python.org/packages/source/m/monotonic/monotonic-"
5522 version
5523 ".tar.gz"))
5524 (sha256
5525 (base32
5526 "0yz0bcbwx8r2c01czzfpbrxddynxyk9k95jj8h6sgcb7xmfvl998"))))
5527 (build-system python-build-system)
5528 (inputs
5529 `(("python-setuptools" ,python-setuptools)))
5530 (home-page "https://github.com/atdt/monotonic")
5531 (synopsis "Implementation of time.monotonic() for Python 2 & < 3.3")
5532 (description
5533 "This module provides a monotonic() function which returns the value (in
5534fractional seconds) of a clock which never goes backwards.")
5535 (license asl2.0)))
5536
5537(define-public python2-monotonic
5538 (package-with-python2 python-monotonic))
de34afac
CR
5539
5540(define-public python-webob
5541 (package
5542 (name "python-webob")
b8834c21 5543 (version "1.5.1")
de34afac
CR
5544 (source
5545 (origin
5546 (method url-fetch)
b8834c21 5547 (uri (pypi-uri "WebOb" version))
de34afac
CR
5548 (sha256
5549 (base32
b8834c21 5550 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
de34afac
CR
5551 (build-system python-build-system)
5552 (inputs
5553 `(("python-nose" ,python-nose)
5554 ("python-setuptools" ,python-setuptools)))
5555 (home-page "http://webob.org/")
5556 (synopsis "WSGI request and response object")
5557 (description
5558 "WebOb provides wrappers around the WSGI request environment, and an
5559object to help create WSGI responses.")
5560 (license license:expat)))
5561
5562(define-public python2-webob
5563 (package-with-python2 python-webob))
350ba0a3 5564
02a8a187
BW
5565(define-public python-xlrd
5566 (package
5567 (name "python-xlrd")
5568 (version "0.9.4")
5569 (source (origin
5570 (method url-fetch)
5571 (uri (string-append "https://pypi.python.org/packages/source/x/"
5572 "xlrd/xlrd-" version ".tar.gz"))
5573 (sha256
5574 (base32
5575 "0wpa55nvidmm5m2qr622dsh3cj46akdk0h3zjgzschcmydck73cf"))))
5576 (build-system python-build-system)
5577 (arguments
5578 `(#:phases
5579 (modify-phases %standard-phases
5580 ;; Current test in setup.py does not work as of 0.9.4, so use nose to
5581 ;; run tests instead for now.
5582 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
5583 (native-inputs `(("python-nose" ,python-nose)
5584 ("python-setuptools" ,python-setuptools)))
5585 (home-page "http://www.python-excel.org/")
5586 (synopsis "Library for extracting data from Excel files")
5587 (description "This packages provides a library to extract data from
5588spreadsheets using Microsoft Excel® proprietary file formats @samp{.xls} and
5589@samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
5590Unicode-aware. It is not intended as an end-user tool.")
5591 (license bsd-3)))
5592
5593(define-public python2-xlrd
5594 (package-with-python2 python-xlrd))
5595
350ba0a3
CR
5596(define-public python-prettytable
5597 (package
5598 (name "python-prettytable")
5599 (version "0.7.2")
5600 (source
5601 (origin
5602 (method url-fetch)
5603 (uri (string-append
5604 "https://pypi.python.org/packages/source/P/PrettyTable/"
5605 "prettytable-" version ".tar.bz2"))
5606 (sha256
5607 (base32
5608 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
5609 (build-system python-build-system)
5610 (inputs
5611 `(("python-setuptools" ,python-setuptools)))
5612 (home-page "http://code.google.com/p/prettytable/")
5613 (synopsis "Display tabular data in an ASCII table format")
5614 (description
5615 "A library designed to represent tabular data in visually appealing ASCII
5616tables. PrettyTable allows for selection of which columns are to be printed,
5617independent alignment of columns (left or right justified or centred) and
5618printing of sub-tables by specifying a row range.")
5619 (license bsd-3)))
5620
5621(define-public python2-prettytable
5622 (package-with-python2 python-prettytable))
7a8ac75a
RW
5623
5624(define-public python-pyasn1
5625 (package
5626 (name "python-pyasn1")
5627 (version "0.1.8")
5628 (source
5629 (origin
5630 (method url-fetch)
5631 (uri (string-append "https://pypi.python.org/packages/source/p/"
5632 "pyasn1/pyasn1-" version ".tar.gz"))
5633 (sha256
5634 (base32
5635 "0iw31d9l0zwx35szkzq72hiw002wnqrlrsi9dpbrfngcl1ybwcsx"))))
5636 (build-system python-build-system)
5637 (home-page "http://pyasn1.sourceforge.net/")
5638 (synopsis "ASN.1 types and codecs")
5639 (description
5640 "This is an implementation of ASN.1 types and codecs in Python. It is
5641suitable for a wide range of protocols based on the ASN.1 specification.")
5642 (license bsd-2)))
5643
5644(define-public python2-pyasn1
5645 (package-with-python2 python-pyasn1))
9a49a535 5646
5988c299
EF
5647(define-public python-pyasn1-modules
5648 (package
5649 (name "python-pyasn1-modules")
5650 (version "0.0.8")
5651 (source
5652 (origin
5653 (method url-fetch)
5654 (uri (pypi-uri "pyasn1-modules" version))
5655 (sha256
5656 (base32
5657 "0drqgw81xd3fxdlg89kgd79zzrabvfncvkbybi2wr6w2y4s1jmhh"))))
5658 (build-system python-build-system)
5659 (native-inputs
5660 `(("python-setuptools" ,python-setuptools)))
5661 (propagated-inputs
5662 `(("python-pyasn1" ,python-pyasn1)))
5663 (home-page "http://sourceforge.net/projects/pyasn1/")
5664 (synopsis "ASN.1 codec implementations")
5665 (description
5666 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
5667implementations of ASN.1-based codecs and protocols.")
5668 (license bsd-3)))
5669
5670(define-public python2-pyasn1-modules
5671 (package-with-python2 python-pyasn1-modules))
5672
9a49a535
RW
5673(define-public python2-ipaddress
5674 (package
5675 (name "python2-ipaddress")
5676 (version "1.0.14")
5677 (source
5678 (origin
5679 (method url-fetch)
5680 (uri (string-append "https://pypi.python.org/packages/source/i/"
5681 "ipaddress/ipaddress-" version ".tar.gz"))
5682 (sha256
5683 (base32
5684 "0givid4963n57nsjibms2fc347zmcs188q1hw9al1dkc9kj4nvr2"))))
5685 (build-system python-build-system)
5686 (arguments
5687 `(#:tests? #f ; no tests
5688 #:python ,python-2))
5689 (home-page "https://github.com/phihag/ipaddress")
5690 (synopsis "IP address manipulation library")
5691 (description
5692 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
5693in Python. This library is used to create, poke at, and manipulate IPv4 and
5694IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
5695module to older versions of Python.")
5696 (license psfl)))
3f00e078
RW
5697
5698(define-public python-idna
5699 (package
5700 (name "python-idna")
5701 (version "2.0")
5702 (source
5703 (origin
5704 (method url-fetch)
5705 (uri (string-append "https://pypi.python.org/packages/source/i/"
5706 "idna/idna-" version ".tar.gz"))
5707 (sha256
5708 (base32
5709 "0frxgmgi234lr9hylg62j69j4ik5zhg0wz05w5dhyacbjfnrl68n"))))
5710 (build-system python-build-system)
5711 (native-inputs
5712 `(("python-setuptools" ,python-setuptools)))
5713 (home-page "https://github.com/kjd/idna")
5714 (synopsis "Internationalized domain names in applications")
5715 (description
5716 "This is a library to support the Internationalised Domain Names in
5717Applications (IDNA) protocol as specified in RFC 5891. This version of the
5718protocol is often referred to as “IDNA2008” and can produce different results
5719from the earlier standard from 2003. The library is also intended to act as a
5720suitable drop-in replacement for the “encodings.idna” module that comes with
5721the Python standard library but currently only supports the older 2003
5722specification.")
5723 (license bsd-4)))
5724
5725(define-public python2-idna
5726 (package-with-python2 python-idna))
36ebf972
RW
5727
5728(define-public python-pretend
5729 (package
5730 (name "python-pretend")
5731 (version "1.0.8")
5732 (source
5733 (origin
5734 (method url-fetch)
5735 (uri (string-append "https://pypi.python.org/packages/source/p/"
5736 "pretend/pretend-" version ".tar.gz"))
5737 (sha256
5738 (base32
5739 "0r5r7ygz9m6d2bklflbl84cqhjkc2q12xgis8268ygjh30g2q3wk"))))
5740 (build-system python-build-system)
5741 (native-inputs
5742 `(("python-setuptools" ,python-setuptools)))
5743 (home-page "https://github.com/alex/pretend")
5744 (synopsis "Library for stubbing in Python")
5745 (description
5746 "Pretend is a library to make stubbing with Python easier. Stubbing is a
5747technique for writing tests. You may hear the term mixed up with mocks,
5748fakes, or doubles. Basically, a stub is an object that returns pre-canned
5749responses, rather than doing any computation.")
5750 (license bsd-3)))
5751
5752(define-public python2-pretend
5753 (package-with-python2 python-pretend))
aa759a51
RW
5754
5755(define-public python-cryptography-vectors
5756 (package
5757 (name "python-cryptography-vectors")
b39b33e8 5758 (version "1.2.2")
aa759a51
RW
5759 (source
5760 (origin
5761 (method url-fetch)
5762 (uri (string-append "https://pypi.python.org/packages/source/c/"
5763 "cryptography-vectors/cryptography_vectors-"
5764 version ".tar.gz"))
5765 (sha256
5766 (base32
b39b33e8 5767 "1zg47fzzn30mgkkbwrxqqcfq9crgabcmxyiy106n9404wbhfjkkl"))))
aa759a51
RW
5768 (build-system python-build-system)
5769 (native-inputs
5770 `(("python-setuptools" ,python-setuptools)))
5771 (home-page "https://github.com/pyca/cryptography")
5772 (synopsis "Test vectors for the cryptography package.")
5773 (description
5774 "This package contains test vectors for the cryptography package.")
5775 ;; Distributed under either BSD-3 or ASL2.0
5776 (license (list bsd-3 asl2.0))))
5777
5778(define-public python2-cryptography-vectors
5779 (package-with-python2 python-cryptography-vectors))
88b47cb0
RW
5780
5781(define-public python-cryptography
5782 (package
5783 (name "python-cryptography")
ce6c13ee 5784 (version "1.2.2")
88b47cb0
RW
5785 (source
5786 (origin
5787 (method url-fetch)
ce6c13ee 5788 (uri (pypi-uri "cryptography" version))
88b47cb0
RW
5789 (sha256
5790 (base32
ce6c13ee 5791 "0rvaha7ymgbqkzbxk7xmj67k5b3hbp8w8cn3m5z776vd22wrq89z"))))
88b47cb0
RW
5792 (build-system python-build-system)
5793 (inputs
5794 `(("openssl" ,openssl)))
5795 (propagated-inputs
5796 `(("python-cffi" ,python-cffi)
5797 ("python-six" ,python-six)
5798 ("python-pyasn1" ,python-pyasn1)
5799 ("python-enum34" ,python-enum34)
5800 ("python-idna" ,python-idna)
5801 ("python-iso8601" ,python-iso8601)))
5802 (native-inputs
5803 `(("python-cryptography-vectors" ,python-cryptography-vectors)
ce6c13ee 5804 ("python-hypothesis" ,python-hypothesis)
88b47cb0
RW
5805 ("python-setuptools" ,python-setuptools)
5806 ("python-pretend" ,python-pretend)
ce6c13ee
EF
5807 ("python-pyasn1" ,python-pyasn1)
5808 ("python-pyasn1-modules" ,python-pyasn1-modules)
88b47cb0
RW
5809 ("python-pytest" ,python-pytest)))
5810 (home-page "https://github.com/pyca/cryptography")
5811 (synopsis "Cryptographic recipes and primitives for Python")
5812 (description
5813 "cryptography is a package which provides cryptographic recipes and
5814primitives to Python developers. It aims to be the “cryptographic standard
5815library” for Python. The package includes both high level recipes, and low
5816level interfaces to common cryptographic algorithms such as symmetric ciphers,
5817message digests and key derivation functions.")
5818 ;; Distributed under either BSD-3 or ASL2.0
519e2f4f
LF
5819 (license (list bsd-3 asl2.0))
5820 (properties `((python2-variant . ,(delay python2-cryptography))))))
88b47cb0
RW
5821
5822(define-public python2-cryptography
519e2f4f
LF
5823 (let ((crypto (package-with-python2
5824 (strip-python2-variant python-cryptography))))
88b47cb0
RW
5825 (package (inherit crypto)
5826 (propagated-inputs
5827 `(("python2-ipaddress" ,python2-ipaddress)
ce6c13ee
EF
5828 ("python2-backport-ssl-match-hostname"
5829 ,python2-backport-ssl-match-hostname)
88b47cb0 5830 ,@(package-propagated-inputs crypto))))))
5af999b8
RW
5831
5832(define-public python-pyopenssl
5833 (package
5834 (name "python-pyopenssl")
5835 (version "0.15.1")
5836 (source
5837 (origin
5838 (method url-fetch)
5839 (uri (string-append "https://pypi.python.org/packages/source/p/"
5840 "pyOpenSSL/pyOpenSSL-" version ".tar.gz"))
5841 (sha256
5842 (base32
5843 "0wnnq15rhj7fhdcd8ycwiw6r6g3w9f9lcy6cigg8226vsrq618ph"))))
5844 (build-system python-build-system)
5845 (arguments
5846 `(#:phases
5847 (modify-phases %standard-phases
5848 (add-after 'unpack 'fix-tests
5849 (lambda* (#:key inputs #:allow-other-keys)
5850 (substitute* "OpenSSL/test/test_ssl.py"
5851 (("client\\.connect\\(\\('verisign\\.com', 443\\)\\)")
5852 "return True")
5853 ;; FIXME: disable broken test
5854 (("test_set_tmp_ecdh") "disabled__set_tmp_ecdh"))
5855 (substitute* "OpenSSL/test/test_crypto.py"
5856 (("command = b\"openssl \"")
5857 (string-append "command = b\""
5858 (assoc-ref inputs "openssl")
5859 "/bin/openssl" " \""))
5860 ;; FIXME: disable four broken tests
5861 (("test_der") "disabled__der")
5862 (("test_digest") "disabled__digest")
5863 (("test_get_extension") "disabled__get_extension")
5864 (("test_extension_count") "disabled__extension_count"))
5865 #t)))))
5866 (propagated-inputs
5867 `(("python-cryptography" ,python-cryptography)
5868 ("python-six" ,python-six)))
5869 (inputs
5870 `(("openssl" ,openssl)))
5871 (native-inputs
5872 `(("python-setuptools" ,python-setuptools)))
5873 (home-page "https://github.com/pyca/pyopenssl")
5874 (synopsis "Python wrapper module around the OpenSSL library")
5875 (description
5876 "PyOpenSSL is a high-level wrapper around a subset of the OpenSSL
5877library.")
5878 (license asl2.0)))
5879
5880(define-public python2-pyopenssl
519e2f4f 5881 (package-with-python2 python-pyopenssl))
643725a1
CR
5882
5883(define-public python-pip
5884 (package
5885 (name "python-pip")
6fb54e3b 5886 (version "8.0.2")
643725a1
CR
5887 (source
5888 (origin
5889 (method url-fetch)
6fb54e3b 5890 (uri (pypi-uri "pip" version))
643725a1
CR
5891 (sha256
5892 (base32
6fb54e3b 5893 "08cm8d4228fj0qnrysy3qv1a6022zr3dcs25amd14lgxil6vvx26"))))
643725a1
CR
5894 (build-system python-build-system)
5895 (inputs
5896 `(("python-setuptools" ,python-setuptools)
5897 ("python-virtualenv" ,python-virtualenv)
5898 ;; Tests
5899 ("python-mock" ,python-mock)
5900 ("python-pytest" ,python-pytest)
5901 ("python-scripttest" ,python-scripttest)))
5902 (home-page "https://pip.pypa.io/")
5903 (synopsis
5904 "Package manager for Python software")
5905 (description
5906 "Pip is a package manager for Python software, that finds packages on the
5907Python Package Index (PyPI).")
5908 (license license:expat)))
5909
5910(define-public python2-pip
5911 (package-with-python2 python-pip))
d8c4998f
LC
5912
5913(define-public python-tlsh
5914 (package
5915 (name "python-tlsh")
99b00dc7 5916 (version "3.4.4")
d8c4998f
LC
5917 (home-page "https://github.com/trendmicro/tlsh")
5918 (source (origin
99b00dc7
EF
5919 (method url-fetch)
5920 (uri (string-append "https://github.com/trendmicro/tlsh/archive/v"
5921 version ".tar.gz"))
d8c4998f
LC
5922 (sha256
5923 (base32
99b00dc7
EF
5924 "00bhzjqrlh7v538kbkbn8lgx976j1138al3sdhklaizqjvpwyk4r"))
5925 (file-name (string-append name "-" version ".tar.gz"))))
d8c4998f
LC
5926 (build-system cmake-build-system)
5927 (arguments
5928 '(#:out-of-source? #f
5929 #:phases (modify-phases %standard-phases
5930 (replace
5931 'install
5932 (lambda* (#:key outputs #:allow-other-keys)
5933 ;; Build and install the Python bindings. The underlying
5934 ;; C++ library is apparently not meant to be installed.
5935 (let ((out (assoc-ref outputs "out")))
5936 (with-directory-excursion "py_ext"
5937 (and (system* "python" "setup.py" "build")
5938 (system* "python" "setup.py" "install"
5939 (string-append "--prefix=" out))))))))))
5940 (inputs `(("python" ,python-wrapper))) ;for the bindings
5941 (synopsis "Fuzzy matching library for Python")
5942 (description
5943 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
5944Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
5945value which can be used for similarity comparisons. Similar objects have
5946similar hash values, which allows for the detection of similar objects by
5947comparing their hash values. The byte stream should have a sufficient amount
5948of complexity; for example, a byte stream of identical bytes will not generate
5949a hash value.")
5950 (license asl2.0)))
5951
5952(define-public python2-tlsh
5953 (package
5954 (inherit python-tlsh)
5955 (name "python2-tlsh")
5956 (inputs `(("python" ,python-2)))))
d96034ed
LC
5957
5958(define-public python-libarchive-c
5959 (package
5960 (name "python-libarchive-c")
03fd001c 5961 (version "2.2")
d96034ed
LC
5962 (source (origin
5963 (method url-fetch)
03fd001c 5964 (uri (pypi-uri "libarchive-c" version))
d96034ed
LC
5965 (sha256
5966 (base32
03fd001c 5967 "0z4r7v3dhd6b3120mav05ff08srih176r2rg5k8kn7mjd9pslm2x"))))
d96034ed
LC
5968 (build-system python-build-system)
5969 (arguments
5970 '(#:phases (modify-phases %standard-phases
5971 (add-before
5972 'build 'reference-libarchive
5973 (lambda* (#:key inputs #:allow-other-keys)
5974 ;; Retain the absolute file name of libarchive.so.
5975 (let ((libarchive (assoc-ref inputs "libarchive")))
5976 (substitute* "libarchive/ffi.py"
5977 (("find_library\\('archive'\\)")
5978 (string-append "'" libarchive
5979 "/lib/libarchive.so'"))))
5980
5981 ;; Do not make a compressed egg (see
5982 ;; <http://bugs.gnu.org/20765>).
5983 (let ((port (open-file "setup.cfg" "a")))
5984 (display "\n[easy_install]\nzip_ok = 0\n"
5985 port)
5986 (close-port port)
5987 #t))))))
5988 (inputs
5989 `(("python-setuptools" ,python-setuptools)
5990 ("libarchive" ,libarchive)))
5991 (home-page "https://github.com/Changaco/python-libarchive-c")
5992 (synopsis "Python interface to libarchive")
5993 (description
5994 "This package provides Python bindings to libarchive, a C library to
5995access possibly compressed archives in many different formats. It uses
5996Python's @code{ctypes} foreign function interface (FFI).")
5997 (license lgpl2.0+)))
5998
5999(define-public python2-libarchive-c
6000 (package-with-python2 python-libarchive-c))
5e1c9367
LC
6001
6002(define-public python-file
6003 (package
6004 (inherit file)
6005 (name "python-file")
6006 (build-system python-build-system)
6007 (arguments
6008 '(#:tests? #f ;no tests
6009 #:phases (modify-phases %standard-phases
6010 (add-before 'build 'change-directory
6011 (lambda _
6012 (chdir "python")
6013 #t))
6014 (add-before 'build 'set-library-file-name
6015 (lambda* (#:key inputs #:allow-other-keys)
6016 (let ((file (assoc-ref inputs "file")))
6017 (substitute* "magic.py"
6018 (("find_library\\('magic'\\)")
6019 (string-append "'" file "/lib/libmagic.so'")))
6020 #t))))))
6021 (inputs `(("file" ,file)))
6022 (self-native-input? #f)
6023 (synopsis "Python bindings to the libmagic file type guesser")))
6024
6025(define-public python2-file
6026 (package-with-python2 python-file))
85d4aeac
LC
6027
6028(define-public python-debian
6029 (package
6030 (name "python-debian")
6031 (version "0.1.23")
6032 (source
6033 (origin
6034 (method url-fetch)
6035 (uri (string-append
6036 "https://pypi.python.org/packages/source/p/python-debian/python-debian-"
6037 version ".tar.gz"))
6038 (sha256
6039 (base32
6040 "193faznwnjc3n5991wyzim6h9gyq1zxifmfrnpm3avgkh7ahyynh"))))
6041 (build-system python-build-system)
6042 (inputs
6043 `(("python-six" ,python-six)))
6044 (native-inputs
6045 `(("python-setuptools" ,python-setuptools)))
6046 (home-page "http://packages.debian.org/sid/python-debian")
6047 (synopsis "Debian package related modules")
6048 (description
5c7bdc9a
LC
6049 ;; XXX: Use @enumerate instead of @itemize to work around
6050 ;; <http://bugs.gnu.org/21772>.
85d4aeac
LC
6051 "This package provides Python modules that abstract many formats of
6052Debian-related files, such as:
6053
5c7bdc9a 6054@enumerate
85d4aeac
LC
6055@item Debtags information;
6056@item @file{debian/changelog} files;
6057@item packages files, pdiffs;
6058@item control files of single or multiple RFC822-style paragraphs---e.g.
6059 @file{debian/control}, @file{.changes}, @file{.dsc};
6060@item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
6061 contained files and meta-information.
5c7bdc9a 6062@end enumerate\n")
85d4aeac
LC
6063
6064 ;; Modules are either GPLv2+ or GPLv3+.
6065 (license gpl3+)))
6066
6067(define-public python2-debian
6068 (package-with-python2 python-debian))
816a6538
LC
6069
6070(define-public python-chardet
6071 (package
6072 (name "python-chardet")
6073 (version "2.3.0")
6074 (source
6075 (origin
6076 (method url-fetch)
6077 (uri (string-append
6078 "https://pypi.python.org/packages/source/c/chardet/chardet-"
6079 version
6080 ".tar.gz"))
6081 (sha256
6082 (base32
6083 "1ak87ikcw34fivcgiz2xvi938dmclh078az65l9x3rmgljrkhgp5"))))
6084 (build-system python-build-system)
6085 (native-inputs
6086 `(("python-setuptools" ,python-setuptools)))
6087 (home-page "https://github.com/chardet/chardet")
6088 (synopsis "Universal encoding detector for Python 2 and 3")
6089 (description
6090 "This package provides @code{chardet}, a Python module that can
6091automatically detect a wide range of file encodings.")
6092 (license lgpl2.1+)))
6093
6094(define-public python2-chardet
6095 (package-with-python2 python-chardet))
2fc5f186 6096
1872f1bb
KM
6097(define-public python-docopt
6098 (package
6099 (name "python-docopt")
6100 (version "0.6.2")
6101 (source
6102 (origin
6103 (method url-fetch)
6104 ;; The release on PyPI does not include tests.
6105 (uri (string-append
6106 "https://github.com/docopt/docopt/archive/"
6107 version ".tar.gz"))
6108 (file-name (string-append name "-" version ".tar.gz"))
6109 (sha256
6110 (base32
6111 "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1"))))
6112 (build-system python-build-system)
6113 (native-inputs
6114 `(("python-pytest" ,python-pytest)
6115 ("python-setuptools" ,python-setuptools)))
6116 (arguments
6117 `(#:phases (alist-replace
6118 'check
6119 (lambda _ (zero? (system* "py.test")))
6120 %standard-phases)))
6121 (home-page "http://docopt.org")
6122 (synopsis "Command-line interface description language for Python")
6123 (description "This library allows the user to define a command-line
6124interface from a program's help message rather than specifying it
6125programatically with command-line parsers like @code{getopt} and
6126@code{argparse}.")
6127 (license license:expat)))
6128
6129(define-public python2-docopt
6130 (package-with-python2 python-docopt))
6131
2fc5f186
LF
6132(define-public python-zope-event
6133 (package
6134 (name "python-zope-event")
6135 (version "4.1.0")
6136 (source
6137 (origin
6138 (method url-fetch)
6139 (uri (string-append "https://pypi.python.org/packages/source/z"
6140 "/zope.event/zope.event-" version ".tar.gz"))
6141 (sha256
6142 (base32
6143 "11p75zpfz3ffhz21nzx9wb23xs993ck5s6hkjcvhswwizni5jynw"))))
6144 (build-system python-build-system)
6145 (inputs
6146 `(("python-setuptools" ,python-setuptools)))
6147 (home-page "http://pypi.python.org/pypi/zope.event")
6148 (synopsis "Event publishing system for Python")
6149 (description "Zope.event provides an event publishing API, intended for
6150use by applications which are unaware of any subscribers to their events. It
6151is a simple event-dispatching system on which more sophisticated event
6152dispatching systems can be built.")
6153 (license zpl2.1)))
6154
6155(define-public python2-zope-event
6156 (package-with-python2 python-zope-event))
97abe268
LF
6157
6158(define-public python-zope-interface
6159 (package
6160 (name "python-zope-interface")
6161 (version "4.1.3")
6162 (source
6163 (origin
6164 (method url-fetch)
6165 (uri (string-append "https://pypi.python.org/packages/source/z"
6166 "/zope.interface/zope.interface-" version ".tar.gz"))
6167 (sha256
6168 (base32
6169 "0ks8h73b2g4bkad821qbv0wzjppdrwys33i7ka45ik3wxjg1l8if"))))
6170 (build-system python-build-system)
6171 (propagated-inputs
6172 `(("python-zope-event" ,python-zope-event)))
6173 (home-page "https://github.com/zopefoundation/zope.interface")
6174 (synopsis "Python implementation of the \"design by contract\"
6175methodology")
6176 (description "Zope.interface provides an implementation of \"object
6177interfaces\" for Python. Interfaces are a mechanism for labeling objects as
6178conforming to a given API or contract.")
6179 (license zpl2.1)))
6180
6181(define-public python2-zope-interface
6182 (package-with-python2 python-zope-interface))
81f2373c
LF
6183
6184(define-public python-zope-exceptions
6185 (package
6186 (name "python-zope-exceptions")
6187 (version "4.0.8")
6188 (source
6189 (origin
6190 (method url-fetch)
6191 (uri (string-append "https://pypi.python.org/packages/source/z"
6192 "/zope.exceptions/zope.exceptions-"
6193 version ".tar.gz"))
6194 (sha256
6195 (base32
6196 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
6197 (build-system python-build-system)
6198 (arguments
6199 '(#:tests? #f)) ; circular dependency with zope.testrunner
6200 (propagated-inputs
6201 `(("python-zope-interface" ,python-zope-interface)))
6202 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
6203 (synopsis "Zope exceptions")
6204 (description "Zope.exceptions provides general-purpose exception types
6205that have uses outside of the Zope framework.")
6206 (license zpl2.1)))
6207
6208(define-public python2-zope-exceptions
6209 (package-with-python2 python-zope-exceptions))
900e3c0e
LF
6210
6211(define-public python-zope-testing
6212 (package
6213 (name "python-zope-testing")
6214 (version "4.5.0")
6215 (source
6216 (origin
6217 (method url-fetch)
6218 (uri (string-append "https://pypi.python.org/packages/source/z"
6219 "/zope.testing/zope.testing-" version ".tar.gz"))
6220 (sha256
6221 (base32
6222 "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))))
6223 (build-system python-build-system)
6224 (native-inputs
6225 `(("python-zope-exceptions" ,python-zope-exceptions)))
6226 (propagated-inputs
6227 `(("python-zope-interface" ,python-zope-interface)))
6228 (home-page "http://pypi.python.org/pypi/zope.testing")
6229 (synopsis "Zope testing helpers")
6230 (description "Zope.testing provides a number of testing utilities for HTML
6231forms, HTTP servers, regular expressions, and more.")
6232 (license zpl2.1)))
6233
6234(define-public python2-zope-testing
6235 (package-with-python2 python-zope-testing))
01614c4f
LF
6236
6237(define-public python-zope-testrunner
6238 (package
6239 (name "python-zope-testrunner")
6240 (version "4.4.9")
6241 (source
6242 (origin
6243 (method url-fetch)
6244 (uri (string-append "https://pypi.python.org/packages/source/z"
6245 "/zope.testrunner/zope.testrunner-"
6246 version ".zip"))
6247 (sha256
6248 (base32
6249 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
6250 (build-system python-build-system)
6251 (native-inputs
6252 `(("python-six" ,python-six)
6253 ("python-zope-exceptions" ,python-zope-exceptions)
6254 ("python-zope-testing" ,python-zope-testing)
6255 ("unzip" ,unzip)))
6256 (propagated-inputs
6257 `(("python-zope-interface" ,python-zope-interface)))
6258 (home-page "http://pypi.python.org/pypi/zope.testrunner")
6259 (synopsis "Zope testrunner script")
6260 (description "Zope.testrunner provides a script for running Python
6261tests.")
6262 (license zpl2.1)))
6263
6264(define-public python2-zope-testrunner
6265 (let ((base (package-with-python2 python-zope-testrunner)))
6266 (package
6267 (inherit base)
6268 (native-inputs
6269 (append (package-native-inputs base)
6270 `(("python2-subunit" ,python2-subunit)
6271 ("python2-mimeparse" ,python2-mimeparse)))))))
6a5c710c
LF
6272
6273(define-public python-zope-i18nmessageid
6274 (package
6275 (name "python-zope-i18nmessageid")
6276 (version "4.0.3")
6277 (source
6278 (origin
6279 (method url-fetch)
6280 (uri (string-append
6281 "https://pypi.python.org/packages/source/z"
6282 "/zope.i18nmessageid/zope.i18nmessageid-"
6283 version ".tar.gz"))
6284 (sha256
6285 (base32
6286 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
6287 (build-system python-build-system)
6288 (inputs
6289 `(("python-setuptools" ,python-setuptools)))
6290 (home-page "http://pypi.python.org/pypi/zope.i18nmessageid")
6291 (synopsis "Message identifiers for internationalization")
6292 (description "Zope.i18nmessageid provides facilities for declaring
6293internationalized messages within program source text.")
6294 (license zpl2.1)))
6295
6296(define-public python2-zope-i18nmessageid
6297 (package-with-python2 python-zope-i18nmessageid))
71fb09f3
LF
6298
6299(define-public python-zope-schema
6300 (package
6301 (name "python-zope-schema")
6302 (version "4.4.2")
6303 (source
6304 (origin
6305 (method url-fetch)
6306 (uri (string-append "https://pypi.python.org/packages/source/z"
6307 "/zope.schema/zope.schema-" version ".tar.gz"))
6308 (sha256
6309 (base32
6310 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
6311 (build-system python-build-system)
6312 (propagated-inputs
6313 `(("python-zope-event" ,python-zope-event)
6314 ("python-zope-interface" ,python-zope-interface)))
6315 (native-inputs
6316 `(("python-zope-testing" ,python-zope-testing)))
6317 (home-page "http://pypi.python.org/pypi/zope.schema")
6318 (synopsis "Zope data schemas")
6319 (description "Zope.scheme provides extensions to zope.interface for
6320defining data schemas.")
6321 (license zpl2.1)))
6322
6323(define-public python2-zope-schema
6324 (package-with-python2 python-zope-schema))
fbac9b17
LF
6325
6326(define-public python-zope-configuration
6327 (package
6328 (name "python-zope-configuration")
6329 (version "4.0.3")
6330 (source (origin
6331 (method url-fetch)
6332 (uri (string-append "https://pypi.python.org/packages/source/z"
6333 "/zope.configuration/zope.configuration-"
6334 version ".tar.gz"))
6335 (sha256
6336 (base32
6337 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
6338 (build-system python-build-system)
6339 (propagated-inputs
6340 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6341 ("python-zope-schema" ,python-zope-schema)))
6342 (home-page "http://pypi.python.org/pypi/zope.configuration")
6343 (synopsis "Zope Configuration Markup Language")
6344 (description "Zope.configuration implements ZCML, the Zope Configuration
6345Markup Language.")
6346 (license zpl2.1)))
6347
6348(define-public python2-zope-configuration
6349 (package-with-python2 python-zope-configuration))
2ad52086
LF
6350
6351(define-public python-zope-proxy
6352 (package
6353 (name "python-zope-proxy")
6354 (version "4.1.6")
6355 (source
6356 (origin
6357 (method url-fetch)
6358 (uri (string-append "https://pypi.python.org/packages/source/z"
6359 "/zope.proxy/zope.proxy-" version ".tar.gz"))
6360 (sha256
6361 (base32
6362 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
6363 (build-system python-build-system)
6364 (propagated-inputs
6365 `(("python-zope-interface" ,python-zope-interface)))
6366 (home-page "http://pypi.python.org/pypi/zope.proxy")
6367 (synopsis "Generic, transparent proxies")
6368 (description "Zope.proxy provides generic, transparent proxies for Python.
6369Proxies are special objects which serve as mostly-transparent wrappers around
6370another object, intervening in the apparent behavior of the wrapped object
6371only when necessary to apply the policy (e.g., access checking, location
6372brokering, etc.) for which the proxy is responsible.")
6373 (license zpl2.1)))
6374
6375(define-public python2-zope-proxy
6376 (package-with-python2 python-zope-proxy))
f404b5ea
LF
6377
6378(define-public python-zope-location
6379 (package
6380 (name "python-zope-location")
6381 (version "4.0.3")
6382 (source
6383 (origin
6384 (method url-fetch)
6385 (uri (string-append "https://pypi.python.org/packages/source/z"
6386 "/zope.location/zope.location-" version ".tar.gz"))
6387 (sha256
6388 (base32
6389 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
6390 (build-system python-build-system)
6391 (native-inputs
6392 `(("python-zope-proxy" ,python-zope-proxy)
6393 ("python-zope-schema" ,python-zope-schema)))
6394 (home-page "http://pypi.python.org/pypi/zope.location/")
6395 (synopsis "Zope location library")
6396 (description "Zope.location implements the concept of \"locations\" in
6397Zope3, which are are special objects that have a structural location.")
6398 (license zpl2.1)))
6399
6400(define-public python2-zope-location
6401 (package-with-python2 python-zope-location))
d4b77f36
LF
6402
6403(define-public python-zope-security
6404 (package
6405 (name "python-zope-security")
6406 (version "4.0.3")
6407 (source
6408 (origin
6409 (method url-fetch)
6410 (uri (string-append "https://pypi.python.org/packages/source/z"
6411 "/zope.security/zope.security-" version ".tar.gz"))
6412 (sha256
6413 (base32
6414 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
6415 (build-system python-build-system)
6416 (propagated-inputs
6417 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6418 ("python-zope-component" ,python-zope-component)
6419 ("python-zope-location" ,python-zope-location)
6420 ("python-zope-proxy" ,python-zope-proxy)
6421 ("python-zope-schema" ,python-zope-schema)
6422 ("python-zope-testrunner" ,python-zope-testrunner)
6423 ("python-zope-testing" ,python-zope-testing)))
6424 (home-page "http://pypi.python.org/pypi/zope.security")
6425 (synopsis "Zope security framework")
6426 (description "Zope.security provides a generic mechanism to implement
6427security policies on Python objects.")
6428 (license zpl2.1)))
6429
6430(define-public python2-zope-security
04417662
EF
6431 (let ((zope-security (package-with-python2 python-zope-security)))
6432 (package (inherit zope-security)
6433 (propagated-inputs
6434 `(("python2-zope-testrunner" ,python2-zope-testrunner)
6435 ,@(alist-delete
6436 "python-zope-testrunner"
6437 (package-propagated-inputs zope-security)))))))
a6b61b27
LF
6438
6439(define-public python-zope-component
6440 (package
6441 (name "python-zope-component")
6442 (version "4.2.2")
6443 (source
6444 (origin
6445 (method url-fetch)
6446 (uri (string-append "https://pypi.python.org/packages/source/z"
6447 "/zope.component/zope.component-" version ".tar.gz"))
6448 (sha256
6449 (base32
6450 "06pqr8m5jv12xjyy5b59hh9anl61cxkzhw9mka33r3nxalmi2b18"))))
6451 (build-system python-build-system)
6452 (arguments
6453 ;; Skip tests due to circular dependency with python-zope-security.
6454 '(#:tests? #f))
6455 (native-inputs
6456 `(("python-zope-testing" ,python-zope-testing)))
6457 (propagated-inputs
6458 `(("python-zope-event" ,python-zope-event)
6459 ("python-zope-interface" ,python-zope-interface)
6460 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6461 ("python-zope-configuration" ,python-zope-configuration)))
6462 (home-page "https://github.com/zopefoundation/zope.component")
6463 (synopsis "Zope Component Architecture")
6464 (description "Zope.component represents the core of the Zope Component
6465Architecture. Together with the zope.interface package, it provides
6466facilities for defining, registering and looking up components.")
6467 (license zpl2.1)))
6468
6469(define-public python2-zope-component
6470 (package-with-python2 python-zope-component))
3859ac12 6471
b5f218be
LF
6472(define-public python2-pythondialog
6473 (package
6474 (name "python2-pythondialog")
6475 (version "3.3.0")
6476 (source
6477 (origin
6478 (method url-fetch)
6479 (uri (string-append "https://pypi.python.org/packages/source/p/"
6480 "python2-pythondialog/python2-pythondialog-"
6481 version ".tar.gz"))
6482 (sha256
6483 (base32
6484 "1yhkagsh99bfi592ymczf8rnw8rk6n9hdqy3dd98m3yrx8zmjvry"))))
6485 (build-system python-build-system)
6486 (arguments
6487 `(#:phases
6488 (modify-phases %standard-phases
6489 (add-after 'unpack 'patch-path
6490 (lambda* (#:key inputs #:allow-other-keys)
6491 (let* ((dialog (assoc-ref inputs "dialog")))
6492 ;; Since this library really wants to grovel the search path, we
6493 ;; must hardcode dialog's store path into it.
6494 (substitute* "dialog.py"
6495 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
6496 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
6497 #t))))
6498 #:python ,python-2
6499 #:tests? #f)) ; no test suite
6500 (propagated-inputs
6501 `(("dialog" ,dialog)))
6502 (home-page "http://pythondialog.sourceforge.net/")
6503 (synopsis "Python interface to the UNIX dialog utility")
6504 (description "A Python wrapper for the dialog utility. Its purpose is to
6505provide an easy to use, pythonic and comprehensive Python interface to dialog.
6506This allows one to make simple text-mode user interfaces on Unix-like systems")
6507 (license lgpl2.1)))
6508
3859ac12
LF
6509(define-public python-pyrfc3339
6510 (package
6511 (name "python-pyrfc3339")
d9aa097b 6512 (version "1.0")
3859ac12
LF
6513 (source
6514 (origin
6515 (method url-fetch)
d9aa097b 6516 (uri (pypi-uri "pyRFC3339" version))
3859ac12
LF
6517 (sha256
6518 (base32
d9aa097b 6519 "0dgm4l9y8jiax5cp6yxjd2i27cq8h33sh81n1wfbmnmqb32cdywd"))))
3859ac12
LF
6520 (build-system python-build-system)
6521 (propagated-inputs
6522 `(("python-pytz" ,python-pytz)))
6523 (native-inputs
6524 `(("python-nose" ,python-nose)
6525 ("python-setuptools" ,python-setuptools)))
6526 (home-page "https://github.com/kurtraschke/pyRFC3339")
6527 (synopsis "Python timestamp library")
6528 (description "Python library for generating and parsing RFC 3339-compliant
6529timestamps.")
6530 (license license:expat)))
6531
6532(define-public python2-pyrfc3339
6533 (package-with-python2 python-pyrfc3339))
5eea2005
LF
6534
6535(define-public python-werkzeug
6536 (package
6537 (name "python-werkzeug")
6538 (version "0.11.2")
6539 (source
6540 (origin
6541 (method url-fetch)
6542 (uri (string-append "https://pypi.python.org/packages/source/W/Werkzeug"
6543 "/Werkzeug-" version ".tar.gz"))
6544 (file-name (string-append name "-" version ".tar.gz"))
6545 (sha256
6546 (base32
6547 "1gzwn1lkl90f3l1nzzxr7vjhm21qk8f837i8rvny5a209fcrhkzb"))))
6548 (build-system python-build-system)
6549 (native-inputs
6550 `(("python-pytest" ,python-pytest)))
6551 (home-page "http://werkzeug.pocoo.org/")
6552 (synopsis "Utilities for WSGI applications")
6553 (description "One of the most advanced WSGI utility modules. It includes a
6554powerful debugger, full-featured request and response objects, HTTP utilities to
6555handle entity tags, cache control headers, HTTP dates, cookie handling, file
6556uploads, a powerful URL routing system and a bunch of community-contributed
6557addon modules.")
6558 (license x11)))
6559
6560(define-public python2-werkzeug
6561 (package-with-python2 python-werkzeug))
99fffa8a
LF
6562
6563(define-public python-configobj
6564 (package
6565 (name "python-configobj")
6566 (version "5.0.6")
6567 (source (origin
6568 (method url-fetch)
6569 (uri (string-append
6570 "https://pypi.python.org/packages/source/c/configobj/"
6571 "configobj-" version ".tar.gz"))
6572 (sha256
6573 (base32
6574 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
6575 ;; Patch setup.py so it looks for python-setuptools, which is
6576 ;; required to parse the keyword 'install_requires' in setup.py.
6577 (patches (list (search-patch "python-configobj-setuptools.patch")))))
6578 (build-system python-build-system)
6579 (native-inputs
6580 `(("python-setuptools" ,python-setuptools)
6581 ("python-six" ,python-six)))
6582 (synopsis "Config file reading, writing and validation")
6583 (description "ConfigObj is a simple but powerful config file reader and
6584writer: an ini file round tripper. Its main feature is that it is very easy to
6585use, with a straightforward programmer’s interface and a simple syntax for
6586config files.")
6587 (home-page "https://github.com/DiffSK/configobj")
6588 (license bsd-3)))
6589
6590(define-public python2-configobj
6591 (package-with-python2 python-configobj))
79e8a291
LF
6592
6593(define-public python-configargparse
6594 (package
6595 (name "python-configargparse")
6596 (version "0.10.0")
6597 (source (origin
6598 (method url-fetch)
6599 (uri (string-append
6600 "https://pypi.python.org/packages/source/C/ConfigArgParse/"
6601 "ConfigArgParse-" version ".tar.gz"))
6602 (sha256
6603 (base32
6604 "19wh919gbdbzxzpagg52q3lm62yicm95ddlcx77dyjc1slyshl1v"))))
6605 (build-system python-build-system)
6606 (arguments
6607 ;; FIXME: Bug in test suite filed upstream:
6608 ;; https://github.com/bw2/ConfigArgParse/issues/32
6609 '(#:tests? #f))
6610 (synopsis "Replacement for argparse")
6611 (description "A drop-in replacement for argparse that allows options to also
6612be set via config files and/or environment variables.")
6613 (home-page "https://github.com/bw2/ConfigArgParse")
6614 (license license:expat)))
6615
6616(define-public python2-configargparse
6617 (package-with-python2 python-configargparse))
ab41f979
LF
6618
6619(define-public python-ndg-httpsclient
6620 (package
6621 (name "python-ndg-httpsclient")
6622 (version "0.4.0")
6623 (source (origin
6624 (method url-fetch)
6625 (uri (string-append
6626 "https://pypi.python.org/packages/source/n/ndg-httpsclient/"
6627 "ndg_httpsclient-" version ".tar.gz"))
6628 (sha256
6629 (base32
6630 "0x32ibixm3vv5m9xfk83xsqm8xcqw4dd0khbh6qbri6rxgymbhg8"))))
6631 (build-system python-build-system)
6632 (propagated-inputs
6633 `(("python-pyopenssl" ,python-pyopenssl)))
6634 (synopsis "HTTPS support for Python's httplib and urllib2")
6635 (description "This is a HTTPS client implementation for httplib and urllib2
6636based on PyOpenSSL. PyOpenSSL provides a more fully featured SSL implementation
6637over the default provided with Python and importantly enables full verification
6638of the SSL peer.")
6639 (home-page "https://github.com/cedadev/ndg_httpsclient/")
6640 (license bsd-3)))
6641
6642;; python2-openssl requires special care, so package-with-python2 is
6643;; insufficient.
6644(define-public python2-ndg-httpsclient
6645 (package (inherit python-ndg-httpsclient)
6646 (name "python2-ndg-httpsclient")
6647 (arguments `(#:python ,python-2))
6648 (propagated-inputs
6649 `(("python2-pyopenssl" ,python2-pyopenssl)))))
03f964a5
CM
6650
6651(define-public python-contextlib2
6652 (package
6653 (name "python-contextlib2")
6654 (version "0.4.0")
6655 (source
6656 (origin
6657 (method url-fetch)
6658 (uri (pypi-uri "contextlib2" version))
6659 (sha256
6660 (base32
6661 "0cmp131dlh0d0zvw0aza1zd13glvngzk8lb4avks0hm7yxwdr9am"))))
6662 (build-system python-build-system)
6663 (arguments
6664 `(#:phases
6665 (modify-phases %standard-phases
6666 (replace 'check
6667 (lambda _ (zero?
6668 (system*
6669 "python" "test_contextlib2.py", "-v")))))))
6670 (home-page "http://contextlib2.readthedocs.org/")
6671 (synopsis "Tools for decorators and context managers")
6672 (description "This module is primarily a backport of the Python
66733.2 contextlib to earlier Python versions. Like contextlib, it
6674provides utilities for common tasks involving decorators and context
6675managers. It also contains additional features that are not part of
6676the standard library.")
6677 (license psfl)))
6678
6679(define-public python2-contextlib2
6680 (package-with-python2 python-contextlib2))
210bf497
DT
6681
6682(define-public python-texttable
6683 (package
6684 (name "python-texttable")
6685 (version "0.8.4")
6686 (source
6687 (origin
6688 (method url-fetch)
6689 (uri (pypi-uri "texttable" version))
6690 (sha256
6691 (base32
6692 "0bkhs4dx9s6g7fpb969hygq56hyz4ncfamlynw72s0n6nqfbd1w5"))))
6693 (build-system python-build-system)
6694 (arguments '(#:tests? #f)) ; no tests
6695 (home-page "https://github.com/foutaise/texttable/")
6696 (synopsis "Python module for creating simple ASCII tables")
6697 (description "Texttable is a Python module for creating simple ASCII
6698tables.")
6699 (license lgpl2.1+)))
6700
6701(define-public python2-texttable
6702 (package-with-python2 python-texttable))
67c52bb3
DT
6703
6704(define-public python-websocket-client
6705 (package
6706 (name "python-websocket-client")
6707 (version "0.34.0")
6708 (source
6709 (origin
6710 (method url-fetch)
6711 (uri (string-append "https://pypi.python.org/packages/source/w"
6712 "/websocket-client/websocket_client-"
6713 version ".tar.gz"))
6714 (sha256
6715 (base32
6716 "1prdx6d49f1cff17kzj15bnz09palfdgc1m5dkq9jd4mr90n4ak8"))))
6717 (build-system python-build-system)
6718 (native-inputs
6719 `(("python-six" ,python-six))) ; for tests
6720 (inputs
6721 `(("python-setuptools" ,python-setuptools)))
6722 (home-page "https://github.com/liris/websocket-client")
6723 (synopsis "WebSocket client for Python")
6724 (description "The Websocket-client module provides the low level APIs for
6725WebSocket usage in Python programs.")
6726 (license lgpl2.1+)))
6727
6728(define-public python2-websocket-client
6729 (package-with-python2 python-websocket-client))
5c6eea2a
LF
6730
6731(define-public python-atomicwrites
6732 (package
6733 (name "python-atomicwrites")
6734 (version "0.1.8")
6735 (source (origin
6736 (method url-fetch)
6737 (uri (pypi-uri "atomicwrites" version))
6738 (sha256
6739 (base32
6740 "13nwk0gw0yb61pnf5vxs3fvhav6q3zrf08x9ggc93bnk5fsssx1j"))))
6741 (build-system python-build-system)
6742 (synopsis "Atomic file writes in Python")
6743 (description "Library for atomic file writes using platform dependent tools
6744for atomic filesystem operations.")
6745 (home-page "https://github.com/untitaker/python-atomicwrites")
6746 (license license:expat)))
561bb3cb
LF
6747
6748(define-public python-requests-toolbelt
6749 (package
6750 (name "python-requests-toolbelt")
6751 (version "0.5.0")
6752 (source (origin
6753 (method url-fetch)
6754 (uri (pypi-uri "requests-toolbelt" version))
6755 (sha256
6756 (base32
6757 "1kbms1s52dhb98vbpaprr15b0ijdbqp500lpfsyjccpd8cjkyngk"))))
6758 (build-system python-build-system)
6759 (propagated-inputs
6760 `(("python-requests" ,python-requests)))
6761 (synopsis "Extensions to python-requests")
6762 (description "This is a toolbelt of useful classes and functions to be used
6763with python-requests.")
6764 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
6765 (license asl2.0)))
d1deb90b
LF
6766
6767(define-public python-click-threading
6768 (package
6769 (name "python-click-threading")
6770 (version "0.1.2")
6771 (source (origin
6772 (method url-fetch)
6773 (uri (pypi-uri "click-threading" version))
6774 (sha256
6775 (base32
6776 "0jmrv4334lfxa2ss53c06dafdwqbk1pb3ihd26izn5igw1bm8145"))))
6777 (build-system python-build-system)
6778 (propagated-inputs
6779 `(("python-click" ,python-click)))
6780 (synopsis "Utilities for multithreading in Click")
6781 (description "This package provides utilities for multithreading in Click
6782applications.")
6783 (home-page "https://github.com/click-contrib/click-threading")
6784 (license license:expat)))
7b17cab9
LF
6785
6786(define-public python-click-log
6787 (package
6788 (name "python-click-log")
6789 (version "0.1.1")
6790 (source (origin
6791 (method url-fetch)
6792 (uri (pypi-uri "click-log" version))
6793 (sha256
6794 (base32
6795 "1z3jdwjmwax159zrnyx830xa968rfqrpkm04ad5xqyh0269ydiqb"))))
6796 (build-system python-build-system)
6797 (propagated-inputs
6798 `(("python-click" ,python-click)))
6799 (synopsis "Logging for click applications")
6800 (description "This package provides a Python library for logging Click
6801applications.")
6802 (home-page "https://github.com/click-contrib/click-log")
6803 (license license:expat)))
7b3a4ee4
LF
6804
6805(define-public python-apipkg
6806 (package
6807 (name "python-apipkg")
6808 (version "1.4")
6809 (source (origin
6810 (method url-fetch)
6811 (uri (pypi-uri "apipkg" version))
6812 (sha256
6813 (base32
6814 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
6815 (build-system python-build-system)
6816 (native-inputs
6817 `(("unzip" ,unzip)))
6818 (propagated-inputs
6819 `(("python-pytest" ,python-pytest)))
6820 (synopsis "Namespace control and lazy-import mechanism")
6821 (description "With apipkg you can control the exported namespace of a Python
6822package and greatly reduce the number of imports for your users. It is a small
6823pure Python module that works on virtually all Python versions.")
6824 (home-page "https://bitbucket.org/hpk42/apipkg")
6825 (license license:expat)))
848964fe
LF
6826
6827(define-public python-execnet
6828 (package
6829 (name "python-execnet")
6830 (version "1.4.1")
6831 (source (origin
6832 (method url-fetch)
6833 (uri (pypi-uri "execnet" version))
6834 (sha256
6835 (base32
6836 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
6837 (build-system python-build-system)
6838 (native-inputs
6839 `(("python-setuptools-scm" ,python-setuptools-scm)))
6840 (propagated-inputs
6841 `(("python-apipkg" ,python-apipkg)))
6842 (synopsis "Rapid multi-Python deployment")
6843 (description "Execnet provides a share-nothing model with
6844channel-send/receive communication for distributing execution across many
6845Python interpreters across version, platform and network barriers. It has a
6846minimal and fast API targetting the following uses:
6847@enumerate
6848@item distribute tasks to (many) local or remote CPUs
6849@item write and deploy hybrid multi-process applications
6850@item write scripts to administer multiple environments
6851@end enumerate")
6852 (home-page "http://codespeak.net/execnet/")
6853 (license license:expat)))
6720dbb4
LF
6854
6855;;; The software provided by this package was integrated into pytest 2.8.
6856(define-public python-pytest-cache
6857 (package
6858 (name "python-pytest-cache")
6859 (version "1.0")
6860 (source (origin
6861 (method url-fetch)
6862 (uri (pypi-uri "pytest-cache" version))
6863 (sha256
6864 (base32
6865 "1a873fihw4rhshc722j4h6j7g3nj7xpgsna9hhg3zn6ksknnhx5y"))))
6866 (build-system python-build-system)
6867 (propagated-inputs
6868 `(("python-execnet" ,python-execnet)))
6869 (synopsis "Py.test plugin with mechanisms for caching across test runs")
6870 (description "The pytest-cache plugin provides tools to rerun failures from
6871the last py.test invocation.")
6872 (home-page "https://bitbucket.org/hpk42/pytest-cache/")
6873 (license license:expat)))
d7e729fe
LF
6874
6875(define-public python-pytest-localserver
6876 (package
6877 (name "python-pytest-localserver")
6878 (version "0.3.4")
6879 (source (origin
6880 (method url-fetch)
6881 (uri (pypi-uri "pytest-localserver" version ".zip"))
6882 (sha256
6883 (base32
6884 "050q505a7gnsz7vqidw0w5dvxjb2flzi7z734agpjzmsl85c2bcx"))))
6885 (build-system python-build-system)
6886 (arguments
6887 `(#:phases (modify-phases %standard-phases
6888 (replace 'check
6889 (lambda _
6890 (zero? (system* "py.test" "--genscript=runtests.py"))
6891 (zero? (system* "py.test")))))))
6892 (native-inputs
6893 `(("unzip" ,unzip)))
6894 (propagated-inputs
6895 `(("python-pytest" ,python-pytest)
6896 ("python-requests" ,python-requests)
6897 ("python-six" ,python-six)
6898 ("python-werkzeug" ,python-werkzeug)))
6899 (synopsis "Py.test plugin to test server connections locally")
6900 (description "Pytest-localserver is a plugin for the pytest testing
6901framework which enables you to test server connections locally.")
6902 (home-page "https://pypi.python.org/pypi/pytest-localserver")
6903 (license license:expat)))
28cecbb7
LF
6904
6905(define-public python-wsgi-intercept
6906 (package
6907 (name "python-wsgi-intercept")
6908 (version "0.10.3")
6909 (source (origin
6910 (method url-fetch)
6911 (uri (pypi-uri "wsgi_intercept" version))
6912 (sha256
6913 (base32
6914 "0xyfchacywb1mql84270mcidsqc5ssyspd18yacjk82x2xc68h0r"))))
6915 (build-system python-build-system)
6916 (native-inputs
6917 `(("python-pytest" ,python-pytest)))
6918 (propagated-inputs
6919 `(("python-httplib2" ,python-httplib2)
6920 ("python-requests" ,python-requests)))
6921 (synopsis "Puts a WSGI application in place of a real URI for testing")
6922 (description "Wsgi_intercept installs a WSGI application in place of a real
6923URI for testing. Testing a WSGI application normally involves starting a
6924server at a local host and port, then pointing your test code to that address.
6925Instead, this library lets you intercept calls to any specific host/port
6926combination and redirect them into a WSGI application importable by your test
6927program. Thus, you can avoid spawning multiple processes or threads to test
6928your Web app.")
6929 (home-page "https://github.com/cdent/wsgi-intercept")
6930 (license license:expat)))
89b8a551
LF
6931
6932(define-public python-pytest-xprocess
6933 (package
6934 (name "python-pytest-xprocess")
6935 (version "0.9.1")
6936 (source (origin
6937 (method url-fetch)
6938 (uri (pypi-uri "pytest-xprocess" version))
6939 (sha256
6940 (base32
6941 "17zlql1xqw3ywcgwwbqmw633aly99lab12hm02asr8awvg5603pp"))))
6942 (build-system python-build-system)
6943 (propagated-inputs
6944 `(("python-pytest" ,python-pytest)
6945 ("python-pytest-cache" ,python-pytest-cache)
6946 ("python-psutil" ,python-psutil)))
6947 (synopsis "Pytest plugin to manage external processes across test runs")
6948 (description "Pytest-xprocess is an experimental py.test plugin for managing
6949processes across test runs.")
6950 (home-page "https://bitbucket.org/pytest-dev/pytest-xprocess")
6951 (license license:expat)))
5c299bf0
LF
6952
6953(define-public python-icalendar
6954 (package
6955 (name "python-icalendar")
6956 (version "3.9.1")
6957 (source (origin
6958 (method url-fetch)
6959 (uri (pypi-uri "icalendar" version))
6960 (sha256
6961 (base32
6962 "0fhrczdj3jxy5bvswphp3vys7vwv5c9bpwg7asykqwa3z6253q6q"))))
6963 (build-system python-build-system)
6964 (propagated-inputs
6965 `(("python-dateutil-2" ,python-dateutil-2)
6966 ("python-pytz" ,python-pytz)))
6967 (synopsis "Python library for parsing iCalendar files")
6968 (description "The icalendar package is a parser/generator of iCalendar
6969files for use with Python.")
6970 (home-page "https://github.com/collective/icalendar")
6971 (license bsd-2)))
6bbbb53e
LF
6972
6973(define-public python-sphinxcontrib-newsfeed
6974 (package
6975 (name "python-sphinxcontrib-newsfeed")
6976 (version "0.1.4")
6977 (source (origin
6978 (method url-fetch)
6979 (uri (pypi-uri "sphinxcontrib-newsfeed" version))
6980 (sha256
6981 (base32
6982 "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p"))))
6983 (build-system python-build-system)
6984 (propagated-inputs
6985 `(("python-docutils" ,python-docutils)
6986 ("python-sphinx" ,python-sphinx)))
6987 (synopsis "News Feed extension for Sphinx")
6988 (description "Sphinxcontrib-newsfeed is an extension for adding a simple
6989Blog, News or Announcements section to a Sphinx website.")
6990 (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed")
6991 (license bsd-2)))
2216e15c
SB
6992
6993(define-public python-args
6994 (package
6995 (name "python-args")
6996 (version "0.1.0")
6997 (source (origin
6998 (method url-fetch)
6999 (uri (pypi-uri "args" version))
7000 (sha256
7001 (base32
7002 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
7003 (build-system python-build-system)
7004 (inputs
7005 `(("python-setuptools" ,python-setuptools)))
7006 (home-page "https://github.com/kennethreitz/args")
7007 (synopsis "Command-line argument parser")
7008 (description
7009 "This library provides a Python module to parse command-line arguments.")
7010 (license bsd-3)))
7011
7012(define-public python2-args
7013 (package-with-python2 python-args))
c06a3de9
SB
7014
7015(define-public python-clint
7016 (package
7017 (name "python-clint")
7018 (version "0.5.1")
7019 (source (origin
7020 (method url-fetch)
7021 (uri (pypi-uri "clint" version))
7022 (sha256
7023 (base32
7024 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
7025 (build-system python-build-system)
7026 (inputs
7027 `(("python-args" ,python-args)
7028 ("python-setuptools" ,python-setuptools)))
7029 (home-page "https://github.com/kennethreitz/clint")
7030 (synopsis "Command-line interface tools")
7031 (description
7032 "Clint is a Python module filled with a set of tools for developing
7033command-line applications, including tools for colored and indented
7034output, progress bar display, and pipes.")
7035 (license isc)))
7036
7037(define-public python2-clint
7038 (package-with-python2 python-clint))
4ecdeef8
SB
7039
7040(define-public python-astor
7041 (package
7042 (name "python-astor")
7043 (version "0.5")
7044 (source (origin
7045 (method url-fetch)
7046 (uri (pypi-uri "astor" version))
7047 (sha256
7048 (base32
7049 "1fdafq5hkis1fxqlmhw0sn44zp2ar46nxhbc22cvwg7hsd8z5gsa"))))
7050 (build-system python-build-system)
7051 (inputs
7052 `(("python-setuptools" ,python-setuptools)))
7053 (home-page "https://github.com/berkerpeksag/astor")
7054 (synopsis "Read and write Python ASTs")
7055 (description
7056 "Astor is designed to allow easy manipulation of Python source via the
7057Abstract Syntax Tree.")
7058 (license bsd-3)))
7059
7060(define-public python2-astor
7061 (package-with-python2 python-astor))
e224b7d0
SB
7062
7063(define-public python-rply
7064 (package
7065 (name "python-rply")
7066 (version "0.7.4")
7067 (source (origin
7068 (method url-fetch)
7069 (uri (pypi-uri "rply" version))
7070 (sha256
7071 (base32
7072 "12rp1d9ba7nvd5rhaxi6xzx1rm67r1k1ylsrkzhpwnphqpb06cvj"))))
7073 (build-system python-build-system)
7074 (inputs
7075 `(("python-appdirs" ,python-appdirs)
7076 ("python-setuptools" ,python-setuptools)))
7077 (home-page "https://github.com/alex/rply")
7078 (synopsis "Parser generator for Python")
7079 (description
7080 "This package provides a pure Python based parser generator, that also
7081works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
7082with a new public API, and RPython support.")
7083 (license bsd-3)))
7084
7085(define-public python2-rply
7086 (package-with-python2 python-rply))
c3e919d7
SB
7087
7088(define-public python-hy
7089 (package
7090 (name "python-hy")
7091 (version "0.11.1")
7092 (source (origin
7093 (method url-fetch)
7094 (uri (pypi-uri "hy" version))
7095 (sha256
7096 (base32
7097 "1msqv747iz12r73mz4qvsmlwkddwjvrahlrk7ysrcz07h7dsscxs"))))
7098 (build-system python-build-system)
7099 (inputs
7100 `(("python-astor" ,python-astor)
7101 ("python-clint" ,python-clint)
7102 ("python-rply" ,python-rply)
7103 ("python-setuptools" ,python-setuptools)))
7104 (home-page "http://hylang.org/")
7105 (synopsis "Lisp frontend to Python")
7106 (description
7107 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
7108its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
7109Python at your fingertips, in Lisp form.")
7110 (license license:expat)))
7111
7112(define-public python2-hy
7113 (package-with-python2 python-hy))
7a5b944e 7114
81f7f297
EF
7115(define-public python-rauth
7116 (package
7117 (name "python-rauth")
7118 (version "0.7.2")
7119 (source
7120 (origin
7121 (method url-fetch)
7122 (uri (pypi-uri "rauth" version))
7123 (sha256
7124 (base32
7125 "00pq7zw429hhza9c0qzxiqp77m653jv09z92nralnmzwdf6pzicf"))))
7126 (build-system python-build-system)
7127 (arguments
7128 `(#:test-target "check"))
7129 (native-inputs
7130 `(("python-setuptools" ,python-setuptools)))
7131 (propagated-inputs
7132 `(("python-requests" ,python-requests)))
7133 (home-page "https://github.com/litl/rauth")
7134 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
7135 (description
7136 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
7137provides service wrappers for convenient connection initialization and
7138authenticated session objects providing things like keep-alive.")
7139 (license license:expat)))
7140
7141(define-public python2-rauth
7142 (let ((rauth (package-with-python2 python-rauth)))
7143 (package (inherit rauth)
264ae686 7144 (propagated-inputs `(("python2-requests" ,python2-requests)))
81f7f297
EF
7145 (native-inputs
7146 `(("python2-unittest2", python2-unittest2)
7147 ,@(package-native-inputs rauth))))))
7148
1abe448d
EF
7149(define-public python2-functools32
7150 (package
7151 (name "python2-functools32")
7152 (version "3.2.3-2")
7153 (source
7154 (origin
7155 (method url-fetch)
7156 (uri (pypi-uri "functools32" version))
7157 (sha256
7158 (base32
7159 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
7160 (build-system python-build-system)
7161 (arguments
7162 `(#:python ,python-2
7163 #:tests? #f)) ; no test target
7164 (native-inputs
7165 `(("python2-setuptools" ,python2-setuptools)))
7166 (home-page "https://github.com/MiCHiLU/python-functools32")
7167 (synopsis
7168 "Backport of the functools module from Python 3.2.3")
7169 (description
7170 "This package is a backport of the @code{functools} module from Python
71713.2.3 for use with older versions of Python and PyPy.")
7172 (license license:expat)))
7173
7a5b944e
EF
7174(define-public python-futures
7175 (package
7176 (name "python-futures")
7177 (version "3.0.3")
7178 (source
7179 (origin
7180 (method url-fetch)
7181 (uri (pypi-uri "futures" version))
7182 (sha256
7183 (base32
7184 "1vcb34dqhzkhbq1957vdjszhhm5y3j9ba88dgwhqx2zynhmk9qig"))))
7185 (build-system python-build-system)
7186 (native-inputs
7187 `(("python-setuptools" ,python-setuptools)))
7188 (home-page "https://github.com/agronholm/pythonfutures")
7189 (synopsis
7190 "Backport of the concurrent.futures package from Python 3.2")
7191 (description
7192 "The concurrent.futures module provides a high-level interface for
7193asynchronously executing callables. This package backports the
7194concurrent.futures package from Python 3.2")
7195 (license bsd-3)))
7196
7197(define-public python2-futures
7198 (package-with-python2 python-futures))
c18f6368
EF
7199
7200(define-public python-urllib3
7201 (package
7202 (name "python-urllib3")
7203 (version "1.13.1")
7204 (source
7205 (origin
7206 (method url-fetch)
7207 (uri (pypi-uri "urllib3" version))
7208 (sha256
7209 (base32
7210 "10rrbr6c6k7j5dvfsyj4b2gsgxg9gggnn708qixf6ll57xqivfkf"))))
7211 (build-system python-build-system)
7212 (arguments `(#:tests? #f))
7213 (native-inputs
7214 `(("python-setuptools" ,python-setuptools)
7215 ;; some packages for tests
7216 ("python-nose" ,python-nose)
7217 ("python-mock" ,python-mock)
7218 ("python-tornado" ,python-tornado)))
7219 (propagated-inputs
7220 `(;; packages for https security
7221 ("python-certifi" ,python-certifi)
7222 ("python-ndg-httpsclient" ,python-ndg-httpsclient)
7223 ("python-pyasn1" ,python-pyasn1)
7224 ("python-pyopenssl" ,python-pyopenssl)))
7225 (home-page "http://urllib3.readthedocs.org/")
7226 (synopsis "HTTP library with thread-safe connection pooling")
7227 (description
7228 "Urllib3 supports features left out of urllib and urllib2 libraries. It
7229can reuse the same socket connection for multiple requests, it can POST files,
7230supports url redirection and retries, and also gzip and deflate decoding.")
7231 (license license:expat)))
7232
7233(define-public python2-urllib3
7234 (package-with-python2 python-urllib3))
2b2f2fc1
DT
7235
7236(define-public python-colorama
7237 (package
7238 (name "python-colorama")
7239 (version "0.3.3")
7240 (source
7241 (origin
7242 (method url-fetch)
7243 (uri (pypi-uri "colorama" version))
7244 (sha256
7245 (base32
7246 "1716z9pq1r5ys3nkg7wdrb3h2f9rmd0zdxpxzmx3bgwgf6xg48gb"))))
7247 (build-system python-build-system)
7248 (inputs
7249 `(("python-setuptools" ,python-setuptools)))
7250 (synopsis "colored terminal text rendering for Python")
7251 (description "Colorama is a Python library for rendering colored terminal
7252text.")
7253 (home-page "https://pypi.python.org/pypi/colorama")
7254 (license bsd-3)))
7255
7256(define-public python2-colorama
7257 (package-with-python2 python-colorama))
f5bcec6e
DT
7258
7259(define-public python-rsa
7260 (package
7261 (name "python-rsa")
7262 (version "3.2")
7263 (source
7264 (origin
7265 (method url-fetch)
7266 (uri (pypi-uri "rsa" version))
7267 (sha256
7268 (base32
7269 "0xwp929g7lvb1sghxfpqlxvgg96qcwqdbhh27sjplx30n3xp3wrh"))))
7270 (build-system python-build-system)
7271 (inputs
7272 `(("python-pyasn1" ,python-pyasn1)
7273 ("python-setuptools" ,python-setuptools)))
7274 (synopsis "Pure-Python RSA implementation")
7275 (description "Python-RSA is a pure-Python RSA implementation. It supports
7276encryption and decryption, signing and verifying signatures, and key
7277generation according to PKCS#1 version 1.5. It can be used as a Python
7278library as well as on the command line.")
7279 (home-page "http://stuvel.eu/rsa")
7280 (license asl2.0)))
7281
7282(define-public python2-rsa
7283 (package-with-python2 python-rsa))
c0aacfa5
DT
7284
7285(define-public python-pluggy
7286 (package
7287 (name "python-pluggy")
7288 (version "0.3.1")
7289 (source
7290 (origin
7291 (method url-fetch)
7292 (uri (pypi-uri "pluggy" version))
7293 (sha256
7294 (base32
7295 "18qfzfm40bgx672lkg8q9x5hdh76n7vax99aank7vh2nw21wg70m"))))
7296 (build-system python-build-system)
7297 (inputs
7298 `(("python-setuptools" ,python-setuptools)))
7299 (synopsis "Plugin and hook calling mechanism for Python")
7300 (description "Pluggy is an extraction of the plugin manager as used by
7301Pytest but stripped of Pytest specific details.")
7302 (home-page "https://pypi.python.org/pypi/pluggy")
7303 (license license:expat)))
7304
7305(define-public python2-pluggy
7306 (package-with-python2 python-pluggy))
a4af21ca
DT
7307
7308(define-public python-tox
7309 (package
7310 (name "python-tox")
7311 (version "2.3.1")
7312 (source
7313 (origin
7314 (method url-fetch)
7315 (uri (pypi-uri "tox" version))
7316 (sha256
7317 (base32
7318 "1vj73ar4rimq3fwy5r2z3jv4g9qbh8rmpmncsc00g0k310acqzxz"))))
7319 (build-system python-build-system)
7320 (arguments
7321 ;; FIXME: Tests require a newer version of pytest, but upgrading our
7322 ;; pytest breaks other packages.
7323 '(#:tests? #f))
7324 (inputs
7325 `(("python-setuptools" ,python-setuptools)
7326 ("python-pluggy" ,python-pluggy)
7327 ("python-py" ,python-py)
7328 ("python-virtualenv" ,python-virtualenv)
7329 ("python-pytest" ,python-pytest)))
7330 (home-page "http://tox.testrun.org/")
7331 (synopsis "Virtualenv-based automation of test activities")
7332 (description "Tox is a generic virtualenv management and test command line
7333tool. It can be used to check that a package installs correctly with
7334different Python versions and interpreters, or run tests in each type of
7335supported environment, or act as a frontend to continuous integration
7336servers.")
7337 (license license:expat)))
7338
7339(define-public python2-tox
7340 (package-with-python2 python-tox))
ba9da248
DT
7341
7342(define-public python-jmespath
7343 (package
7344 (name "python-jmespath")
7345 (version "0.9.0")
7346 (source
7347 (origin
7348 (method url-fetch)
7349 (uri (pypi-uri "jmespath" version))
7350 (sha256
7351 (base32
7352 "0g9xvl69y7nr3w7ag4fsp6sm4fqf6vrqjw7504x2hzrrsh3ampq8"))))
7353 (build-system python-build-system)
7354 (inputs
7355 `(("python-setuptools" ,python-setuptools)))
7356 (synopsis "JSON Matching Expressions")
7357 (description "JMESPath (pronounced “james path”) is a Python library that
7358allows one to declaratively specify how to extract elements from a JSON
7359document.")
7360 (home-page "https://github.com/jmespath/jmespath.py")
7361 (license license:expat)))
7362
7363(define-public python2-jmespath
7364 (package-with-python2 python-jmespath))
935fcd5c
DT
7365
7366(define-public python-botocore
7367 (package
7368 (name "python-botocore")
7369 (version "1.3.17")
7370 (source
7371 (origin
7372 (method url-fetch)
7373 (uri (pypi-uri "botocore" version))
7374 (sha256
7375 (base32
7376 "08vpvdixx1c1lfv6vzjig68bpiir7wfyhzf49ysxgvhbprg5ra0w"))))
7377 (build-system python-build-system)
7378 (inputs
7379 `(("python-dateutil" ,python-dateutil-2)
7380 ("python-docutils" ,python-docutils)
7381 ("python-mock" ,python-mock)
7382 ("python-nose" ,python-nose)
7383 ("python-setuptools" ,python-setuptools)
7384 ("python-tox" ,python-tox)
7385 ("python-wheel" ,python-wheel)
7386 ("python-jmespath" ,python-jmespath)))
7387 (home-page "https://github.com/boto/botocore")
7388 (synopsis "Low-level interface to AWS")
7389 (description "Botocore is a Python library that provides a low-level
7390interface to the Amazon Web Services (AWS) API.")
7391 (license asl2.0)))
7392
7393(define-public python2-botocore
7394 (package-with-python2 python-botocore))
f861b8b8
DT
7395
7396(define-public awscli
7397 (package
7398 (name "awscli")
7399 (version "1.9.17")
7400 (source
7401 (origin
7402 (method url-fetch)
7403 (uri (string-append
7404 "https://pypi.python.org/packages/source/a/awscli/awscli-"
7405 version ".tar.gz"))
7406 (sha256
7407 (base32
7408 "1nj7jqvlpq57hfhby1njsbf8303gapa3njc4dramr6p3ffzvfi2i"))))
7409 (build-system python-build-system)
7410 (inputs
7411 `(("python-colorama" ,python-colorama)
7412 ("python-docutils" ,python-docutils)
7413 ("python-mock" ,python-mock)
7414 ("python-nose" ,python-nose)
7415 ("python-rsa" ,python-rsa)
7416 ("python-setuptools" ,python-setuptools)
7417 ("python-sphinx" ,python-sphinx)
7418 ("python-tox" ,python-tox)
7419 ("python-wheel" ,python-wheel)
7420 ("python-botocore" ,python-botocore)))
7421 (home-page "http://aws.amazon.com/cli/")
7422 (synopsis "Command line client for AWS")
7423 (description "AWS CLI provides a unified command line interface to the
7424Amazon Web Services (AWS) API.")
7425 (license asl2.0)))
6a44697d
LF
7426
7427(define-public python-hypothesis
7428 (package
7429 (name "python-hypothesis")
7430 (version "2.0.0")
7431 (source (origin
7432 (method url-fetch)
7433 (uri (pypi-uri "hypothesis" version))
7434 (sha256
7435 (base32
7436 "1la6mfpvcn640gs2v35iv8b4sh6xdhp9j5ghay0jd86c9n4fkgxr"))))
7437 (build-system python-build-system)
7438 (native-inputs
7439 `(;; setuptools required for python-2 variant
7440 ("python-setuptools" ,python-setuptools)))
7441 (propagated-inputs
7442 `(("python-flake8" ,python-flake8)
7443 ("python-pytest" ,python-pytest)))
7444 (synopsis "Library for property based testing")
7445 (description "Hypothesis is a library for testing your Python code against a
7446much larger range of examples than you would ever want to write by hand. It’s
7447based on the Haskell library, Quickcheck, and is designed to integrate
7448seamlessly into your existing Python unit testing work flow.")
7449 (home-page "https://github.com/DRMacIver/hypothesis")
7450 (license mpl2.0)))
7451
7452(define-public python2-hypothesis
7453 (package-with-python2 python-hypothesis))
7517e73c
LF
7454
7455(define-public python-pytest-subtesthack
7456 (package
7457 (name "python-pytest-subtesthack")
7458 (version "0.1.1")
7459 (source (origin
7460 (method url-fetch)
7461 (uri (pypi-uri "pytest-subtesthack" version))
7462 (sha256
7463 (base32
7464 "15kzcr5pchf3id4ikdvlv752rc0j4d912n589l4rifp8qsj19l1x"))))
7465 (build-system python-build-system)
7466 (native-inputs
7467 `(;; setuptools required for python-2 variant
7468 ("python-setuptools" ,python-setuptools)))
7469 (propagated-inputs
7470 `(("python-pytest" ,python-pytest)))
7471 (synopsis "Set-up and tear-down fixtures for unit tests")
7472 (description "This plugin allows you to set up and tear down fixtures within
7473unit test functions that use @code{py.test}. This is useful for using
7474@command{hypothesis} inside py.test, as @command{hypothesis} will call the test
7475function multiple times, without setting up or tearing down fixture state as is
7476normally the case.")
7477 (home-page "https://github.com/untitaker/pytest-subtesthack/")
7478 (license unlicense)))
7479
7480(define-public python2-pytest-subtesthack
7481 (package-with-python2 python-pytest-subtesthack))
0bdc1671
CAW
7482
7483(define-public python2-xdo
7484 (package
7485 (name "python2-xdo")
7486 (version "0.2")
7487 (source (origin
7488 (method url-fetch)
7489 (uri (string-append
7490 "http://http.debian.net/debian/pool/main/p/python-xdo/"
7491 "python-xdo_" version ".orig.tar.gz"))
7492 (sha256
7493 (base32
7494 "1kl5c1p0dyxf62plnk6fl77ycfb4whwjms16r14dxx8kn90hlqz4"))))
7495 (build-system python-build-system)
7496 (arguments
7497 `(#:python ,python-2
7498 #:tests? #f)) ; no tests provided
7499 (inputs
7500 `(("xdotool" ,xdotool)
7501 ("libX11" ,libx11)))
7502 (home-page "https://tracker.debian.org/pkg/python-xdo")
7503 (synopsis "Python library for simulating X11 keyboard/mouse input")
7504 (description "Provides bindings to libxdo for manipulating X11 via simulated
7505input. (Note that this is mostly a legacy library; you may wish to look at
7506python-xdo for newer bindings.)")
7507 (license bsd-3)))
7508