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