gnu: eigensoft: Do not refer to "lapacke" output.
[jackhill/guix/guix.git] / gnu / packages / python.scm
CommitLineData
a01b6da7
NK
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
48b311b1 3;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
8e451885 4;;; Copyright © 2013, 2014, 2015, 2016 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>
534db463 10;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net>
0bdc1671 11;;; Copyright © 2015, 2016 Christopher Allan Webber <cwebber@dustycloud.org>
345f0611 12;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
2b2f2fc1 13;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org>
6a44697d 14;;; Copyright © 2015, 2016 Leo Famulari <leo@famulari.name>
02a8a187 15;;; Copyright © 2015 Ben Woodcroft <donttrustben@gmail.com>
b9893908 16;;; Copyright © 2015, 2016 Erik Edrosa <erik.edrosa@gmail.com>
264ae686 17;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
1872f1bb 18;;; Copyright © 2015 Kyle Meyer <kyle@kyleam.com>
daeeea71 19;;; Copyright © 2015, 2016 Chris Marusich <cmmarusich@gmail.com>
b31fbea5 20;;; Copyright © 2016 Danny Milosavljevic <dannym+a@scratchpost.org>
88bb4197 21;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
b8fdbca3 22;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
0de78c95 23;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org>
9250b0f3 24;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com>
47d0b292 25;;; Copyright © 2016 Troy Sankey <sankeytms@gmail.com>
42c4b246 26;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
a01b6da7
NK
27;;;
28;;; This file is part of GNU Guix.
29;;;
30;;; GNU Guix is free software; you can redistribute it and/or modify it
31;;; under the terms of the GNU General Public License as published by
32;;; the Free Software Foundation; either version 3 of the License, or (at
33;;; your option) any later version.
34;;;
35;;; GNU Guix is distributed in the hope that it will be useful, but
36;;; WITHOUT ANY WARRANTY; without even the implied warranty of
37;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
38;;; GNU General Public License for more details.
39;;;
40;;; You should have received a copy of the GNU General Public License
41;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
42
1ffa7090 43(define-module (gnu packages python)
011b18c3 44 #:use-module ((guix licenses)
45203542 45 #:select (asl2.0 bsd-4 bsd-3 bsd-2 non-copyleft cc0 x11 x11-style
63bcec71 46 gpl2 gpl2+ gpl3 gpl3+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3+ agpl3+
548d7165 47 isc mpl2.0 psfl public-domain repoze unlicense x11-style
7517e73c 48 zpl2.1))
bd3fa666 49 #:use-module ((guix licenses) #:select (expat zlib) #:prefix license:)
3fdc99da 50 #:use-module (gnu packages)
8e451885 51 #:use-module (gnu packages algebra)
d79a343b 52 #:use-module (gnu packages adns)
89b2e0b0 53 #:use-module (gnu packages attr)
d96034ed 54 #:use-module (gnu packages backup)
1ffa7090 55 #:use-module (gnu packages compression)
4ed20663 56 #:use-module (gnu packages databases)
5e1c9367 57 #:use-module (gnu packages file)
4ed20663 58 #:use-module (gnu packages fontutils)
4ed20663
AE
59 #:use-module (gnu packages gcc)
60 #:use-module (gnu packages ghostscript)
61 #:use-module (gnu packages glib)
62 #:use-module (gnu packages gtk)
421a80a2 63 #:use-module (gnu packages icu4c)
c937562e 64 #:use-module (gnu packages image)
4ed20663 65 #:use-module (gnu packages imagemagick)
d79a343b 66 #:use-module (gnu packages libevent)
b10ab723 67 #:use-module (gnu packages libffi)
89b2e0b0 68 #:use-module (gnu packages linux)
0da98533 69 #:use-module (gnu packages maths)
4ed20663 70 #:use-module (gnu packages multiprecision)
45203542 71 #:use-module (gnu packages networking)
be7134bf 72 #:use-module (gnu packages ncurses)
c9b1b4f9 73 #:use-module (gnu packages pcre)
4ed20663 74 #:use-module (gnu packages perl)
b10ab723 75 #:use-module (gnu packages pkg-config)
4ed20663 76 #:use-module (gnu packages readline)
c9b1b4f9 77 #:use-module (gnu packages statistics)
8f9ac901 78 #:use-module (gnu packages tex)
1c65314c 79 #:use-module (gnu packages texinfo)
cc2b77df 80 #:use-module (gnu packages tls)
e25f0174 81 #:use-module (gnu packages version-control)
8d12be1e 82 #:use-module (gnu packages web)
ce0614dd 83 #:use-module (gnu packages base)
26b307e2 84 #:use-module (gnu packages xml)
6fa14469 85 #:use-module (gnu packages xorg)
0bdc1671 86 #:use-module (gnu packages xdisorg)
4ed20663 87 #:use-module (gnu packages zip)
afa181ff 88 #:use-module (gnu packages tcl)
63bcec71
DM
89 #:use-module (gnu packages bdw-gc)
90 #:use-module (gnu packages pcre)
a01b6da7
NK
91 #:use-module (guix packages)
92 #:use-module (guix download)
ea5456c8 93 #:use-module (guix git-download)
11bb85a1 94 #:use-module (guix utils)
acc26ff1 95 #:use-module (guix build-system gnu)
d8c4998f 96 #:use-module (guix build-system cmake)
898238b9 97 #:use-module (guix build-system python)
1c65314c
FB
98 #:use-module (guix build-system trivial)
99 #:use-module (srfi srfi-1))
a01b6da7 100
45848023 101(define-public python-2.7
a01b6da7
NK
102 (package
103 (name "python")
ff6f33cf 104 (version "2.7.10")
a01b6da7
NK
105 (source
106 (origin
107 (method url-fetch)
9b43a0ff 108 (uri (string-append "https://www.python.org/ftp/python/"
a01b6da7
NK
109 version "/Python-" version ".tar.xz"))
110 (sha256
111 (base32
6a20289d 112 "1h7zbrf9pkj29hlm18b10548ch9757f75m64l47sy75rh43p7lqw"))
fc1adab1
AK
113 (patches (search-patches
114 "python-2.7-search-paths.patch"
115 "python-2-deterministic-build-info.patch"
116 "python-2.7-source-date-epoch.patch"))))
02f0c3b2
LC
117 (outputs '("out"
118 "tk")) ;tkinter; adds 50 MiB to the closure
a01b6da7 119 (build-system gnu-build-system)
3fdc99da 120 (arguments
af807dea 121 `(#:tests? #f
ff6f33cf
ED
122 ;; 268 tests OK.
123 ;; 103 tests failed:
124 ;; test_distutils test_shutil test_signal test_site test_slice
125 ;; test_smtplib test_smtpnet test_socket test_socketserver
126 ;; test_softspace test_sort test_spwd test_sqlite test_ssl
127 ;; test_startfile test_stat test_str test_strftime test_string
128 ;; test_stringprep test_strop test_strptime test_strtod test_struct
129 ;; test_structmembers test_structseq test_subprocess test_sunau
130 ;; test_sunaudiodev test_sundry test_symtable test_syntax test_sys
131 ;; test_sys_setprofile test_sys_settrace test_sysconfig test_tarfile
132 ;; test_tcl test_telnetlib test_tempfile test_textwrap test_thread
133 ;; test_threaded_import test_threadedtempfile test_threading
134 ;; test_threading_local test_threadsignals test_time test_timeit
135 ;; test_timeout test_tk test_tokenize test_tools test_trace
136 ;; test_traceback test_transformer test_ttk_guionly test_ttk_textonly
137 ;; test_tuple test_typechecks test_ucn test_unary
138 ;; test_undocumented_details test_unicode test_unicode_file
139 ;; test_unicodedata test_univnewlines test_univnewlines2k test_unpack
140 ;; test_urllib test_urllib2 test_urllib2_localnet test_urllib2net
141 ;; test_urllibnet test_urlparse test_userdict test_userlist
142 ;; test_userstring test_uu test_uuid test_wait3 test_wait4
143 ;; test_warnings test_wave test_weakref test_weakset test_whichdb
144 ;; test_winreg test_winsound test_with test_wsgiref test_xdrlib
145 ;; test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc
146 ;; test_xpickle test_xrange test_zipfile test_zipfile64
147 ;; test_zipimport test_zipimport_support test_zlib
148 ;; 30 tests skipped:
149 ;; test_aepack test_al test_applesingle test_bsddb test_bsddb185
150 ;; test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk
151 ;; test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_crypt
152 ;; test_curses test_dl test_gdb test_gl test_idle test_imageop
153 ;; test_imgfile test_ioctl test_kqueue test_linuxaudiodev test_macos
154 ;; test_macostools test_msilib test_nis test_ossaudiodev
155 ;; test_scriptpackages
156 ;; 6 skips unexpected on linux2:
157 ;; test_bsddb test_bsddb3 test_crypt test_gdb test_idle test_ioctl
158 ;; One of the typical errors:
159 ;; test_unicode
160 ;; test test_unicode crashed -- <type 'exceptions.OSError'>: [Errno 2] No
161 ;; such file or directory
af807dea 162 #:test-target "test"
3fdc99da 163 #:configure-flags
6a20289d
LC
164 (list "--enable-shared" ;allow embedding
165 "--with-system-ffi" ;build ctypes
166 (string-append "LDFLAGS=-Wl,-rpath="
167 (assoc-ref %outputs "out") "/lib"))
fd982732 168
d2cc9c7c
LC
169 #:modules ((ice-9 ftw) (ice-9 match)
170 (guix build utils) (guix build gnu-build-system))
fd982732 171 #:phases
46472ecd
MW
172 (modify-phases %standard-phases
173 (add-before
174 'configure 'patch-lib-shells
175 (lambda _
176 ;; Filter for existing files, since some may not exist in all
177 ;; versions of python that are built with this recipe.
178 (substitute* (filter file-exists?
179 '("Lib/subprocess.py"
180 "Lib/popen2.py"
181 "Lib/distutils/tests/test_spawn.py"
182 "Lib/test/test_subprocess.py"))
183 (("/bin/sh") (which "sh")))
dedc8320
LC
184
185 ;; Use zero as the timestamp in .pyc files so that builds are
186 ;; deterministic. TODO: Remove it when this variable is set in
187 ;; gnu-build-system.scm.
a665996f 188 (setenv "SOURCE_DATE_EPOCH" "1")
46472ecd 189 #t))
5b4e2791
LC
190 (add-before 'configure 'do-not-record-configure-flags
191 (lambda* (#:key configure-flags #:allow-other-keys)
192 ;; Remove configure flags from the installed '_sysconfigdata.py'
193 ;; and 'Makefile' so we don't end up keeping references to the
194 ;; build tools.
195 ;;
196 ;; Preserve at least '--with-system-ffi' since otherwise the
197 ;; thing tries to build libffi, fails, and we end up with a
198 ;; Python that lacks ctypes.
199 (substitute* "configure"
200 (("^CONFIG_ARGS=.*$")
201 (format #f "CONFIG_ARGS='~a'\n"
202 (if (member "--with-system-ffi" configure-flags)
203 "--with-system-ffi"
204 ""))))
205 #t))
46472ecd
MW
206 (add-before
207 'check 'pre-check
208 (lambda _
209 ;; 'Lib/test/test_site.py' needs a valid $HOME
210 (setenv "HOME" (getcwd))
211 #t))
212 (add-after
213 'unpack 'set-source-file-times-to-1980
214 ;; XXX One of the tests uses a ZIP library to pack up some of the
215 ;; source tree, and fails with "ZIP does not support timestamps
216 ;; before 1980". Work around this by setting the file times in the
217 ;; source tree to sometime in early 1980.
218 (lambda _
219 (let ((circa-1980 (* 10 366 24 60 60)))
220 (ftw "." (lambda (file stat flag)
221 (utime file circa-1980 circa-1980)
222 #t))
02f0c3b2
LC
223 #t)))
224 (add-after 'install 'move-tk-inter
225 (lambda* (#:key outputs #:allow-other-keys)
226 ;; When Tkinter support is built move it to a separate output so
227 ;; that the main output doesn't contain a reference to Tcl/Tk.
228 (let ((out (assoc-ref outputs "out"))
229 (tk (assoc-ref outputs "tk")))
230 (when tk
231 (match (find-files out "tkinter.*\\.so")
232 ((tkinter.so)
233 ;; The .so is in OUT/lib/pythonX.Y/lib-dynload, but we
234 ;; want it under TK/lib/pythonX.Y/site-packages.
235 (let* ((len (string-length out))
236 (target (string-append
237 tk "/"
238 (string-drop
239 (dirname (dirname tkinter.so))
240 len)
241 "/site-packages")))
242 (install-file tkinter.so target)
243 (delete-file tkinter.so)))))
244 #t))))))
a01b6da7 245 (inputs
3fdc99da
CR
246 `(("bzip2" ,bzip2)
247 ("gdbm" ,gdbm)
b10ab723 248 ("libffi" ,libffi) ; for ctypes
b88e1b0a 249 ("sqlite" ,sqlite) ; for sqlite extension
a01b6da7 250 ("openssl" ,openssl)
3fdc99da 251 ("readline" ,readline)
afa181ff
LC
252 ("zlib" ,zlib)
253 ("tcl" ,tcl)
254 ("tk" ,tk))) ; for tkinter
b10ab723
CR
255 (native-inputs
256 `(("pkg-config" ,pkg-config)))
9be8d7c8
LC
257 (native-search-paths
258 (list (search-path-specification
259 (variable "PYTHONPATH")
af070955 260 (files '("lib/python2.7/site-packages")))))
a01b6da7 261 (home-page "http://python.org")
afa181ff 262 (synopsis "High-level, dynamically-typed programming language")
a01b6da7
NK
263 (description
264 "Python is a remarkably powerful dynamic programming language that
265is used in a wide variety of application domains. Some of its key
266distinguishing features include: clear, readable syntax; strong
267introspection capabilities; intuitive object orientation; natural
268expression of procedural code; full modularity, supporting hierarchical
269packages; exception-based error handling; and very high level dynamic
270data types.")
271 (license psfl)))
acc26ff1 272
45848023
HG
273;; Current 2.x version.
274(define-public python-2 python-2.7)
275
276(define-public python-3.4
b24d1cfc 277 (package (inherit python-2)
08c04509 278 (version "3.4.3")
717003e3
LC
279 (source (origin
280 (method url-fetch)
281 (uri (string-append "https://www.python.org/ftp/python/"
282 version "/Python-" version ".tar.xz"))
fc1adab1
AK
283 (patches (search-patches
284 "python-fix-tests.patch"
285 ;; XXX Try removing this patch for python > 3.4.3
286 "python-disable-ssl-test.patch"
287 "python-3-deterministic-build-info.patch"
288 "python-3-search-paths.patch"))
717003e3
LC
289 (patch-flags '("-p0"))
290 (sha256
291 (base32
08c04509 292 "1f4nm4z08sy0kqwisvv95l02crv6dyysdmx44p1mz3bn6csrdcxm"))))
1f434457
MW
293 (arguments (substitute-keyword-arguments (package-arguments python-2)
294 ((#:tests? _) #t)))
1aebc0cb
AE
295 (native-search-paths
296 (list (search-path-specification
297 (variable "PYTHONPATH")
0e05d01e
SB
298 (files (list (string-append "lib/python"
299 (version-major+minor version)
300 "/site-packages"))))))))
f26a77ff 301
45848023
HG
302;; Current 3.x version.
303(define-public python-3 python-3.4)
304
305;; Current major version.
306(define-public python python-3)
307
95288fcc
LC
308;; Minimal variants of Python, mostly used to break the cycle between Tk and
309;; Python (Tk -> libxcb -> Python.)
310
311(define-public python2-minimal
312 (package (inherit python-2)
313 (name "python-minimal")
02f0c3b2 314 (outputs '("out"))
95288fcc
LC
315 (arguments
316 (substitute-keyword-arguments (package-arguments python-2)
c5a05e31
LC
317 ((#:configure-flags cf)
318 `(append ,cf '("--without-system-ffi")))))
95288fcc
LC
319 (inputs '()))) ;none of the optional dependencies
320
321(define-public python-minimal
898238b9 322 (package (inherit python)
95288fcc 323 (name "python-minimal")
02f0c3b2 324 (outputs '("out"))
95288fcc
LC
325 (arguments
326 (substitute-keyword-arguments (package-arguments python)
c5a05e31
LC
327 ((#:configure-flags cf)
328 `(append ,cf '("--without-system-ffi")))))
95288fcc
LC
329
330 ;; OpenSSL is a mandatory dependency of Python 3.x, for urllib;
331 ;; zlib is required by 'zipimport', used by pip.
332 (inputs `(("openssl" ,openssl)
333 ("zlib" ,zlib)))))
334
64cb064c
LC
335(define* (wrap-python3 python
336 #:optional
337 (name (string-append (package-name python) "-wrapper")))
898238b9 338 (package (inherit python)
95288fcc 339 (name name)
898238b9
AE
340 (source #f)
341 (build-system trivial-build-system)
02f0c3b2 342 (outputs '("out"))
3c0f2329 343 (propagated-inputs `(("python" ,python)))
898238b9
AE
344 (arguments
345 `(#:modules ((guix build utils))
346 #:builder
347 (begin
348 (use-modules (guix build utils))
349 (let ((bin (string-append (assoc-ref %outputs "out") "/bin"))
350 (python (string-append (assoc-ref %build-inputs "python") "/bin/")))
351 (mkdir-p bin)
352 (for-each
353 (lambda (old new)
354 (symlink (string-append python old)
355 (string-append bin "/" new)))
b3546174
MW
356 `("python3" ,"pydoc3" ,"idle3")
357 `("python" ,"pydoc" ,"idle"))))))
0d56e3e1
LC
358 (synopsis "Wrapper for the Python 3 commands")
359 (description
360 "This package provides wrappers for the commands of Python@tie{}3.x such
361that they can be invoked under their usual name---e.g., @command{python}
362instead of @command{python3}.")))
363
95288fcc
LC
364(define-public python-wrapper (wrap-python3 python))
365(define-public python-minimal-wrapper (wrap-python3 python-minimal))
898238b9 366
aaf625b8
RW
367(define-public python-psutil
368 (package
369 (name "python-psutil")
88535a44 370 (version "4.3.0")
aaf625b8
RW
371 (source
372 (origin
373 (method url-fetch)
f56777be 374 (uri (pypi-uri "psutil" version))
aaf625b8
RW
375 (sha256
376 (base32
88535a44 377 "1w4r09fvn6kd80m5mx4ws1wz100brkaq6hzzpwrns8cgjzjpl6c6"))))
aaf625b8
RW
378 (build-system python-build-system)
379 (native-inputs
380 `(("python-setuptools" ,python-setuptools)))
88535a44 381 (home-page "https://www.github.com/giampaolo/psutil")
aaf625b8
RW
382 (synopsis "Library for retrieving information on running processes")
383 (description
384 "psutil (Python system and process utilities) is a library for retrieving
385information on running processes and system utilization (CPU, memory, disks,
386network) in Python. It is useful mainly for system monitoring, profiling and
387limiting process resources and management of running processes. It implements
388many functionalities offered by command line tools such as: ps, top, lsof,
389netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
390pidof, tty, taskset, pmap.")
391 (license bsd-3)))
392
393(define-public python2-psutil
394 (package-with-python2 python-psutil))
898238b9 395
f9da1d8a
ED
396(define-public python-passlib
397 (package
398 (name "python-passlib")
690e8c66 399 (version "1.6.5")
f9da1d8a
ED
400 (source
401 (origin
402 (method url-fetch)
690e8c66 403 (uri (pypi-uri "passlib" version))
f9da1d8a
ED
404 (sha256
405 (base32
690e8c66 406 "1z27wdxs5rj5xhhqfzvzn3yg682irkxw6dcs5jj7mcf97psk8gd8"))))
f9da1d8a
ED
407 (build-system python-build-system)
408 (native-inputs
409 `(("python-nose" ,python-nose)
410 ("python-setuptools" ,python-setuptools)))
411 (inputs
412 `(("python-py-bcrypt" ,python-py-bcrypt)))
413 (arguments
414 `(#:phases
415 (alist-cons-before
416 'check 'set-PYTHON_EGG_CACHE
417 ;; some tests require access to "$HOME/.cython"
418 (lambda* _ (setenv "PYTHON_EGG_CACHE" "/tmp"))
419 %standard-phases)))
420 (home-page "https://bitbucket.org/ecollins/passlib")
421 (synopsis
422 "Comprehensive password hashing framework")
423 (description
424 "Passlib is a password hashing library for Python 2 & 3, which provides
425cross-platform implementations of over 30 password hashing algorithms, as well
426as a framework for managing existing password hashes. It's designed to be
427useful for a wide range of tasks, from verifying a hash found in /etc/shadow,
428to providing full-strength password hashing for multi-user application.")
429 (license bsd-3)))
430
431(define-public python2-passlib
432 (package-with-python2 python-passlib))
433
feb0d9c3
ED
434(define-public python-py-bcrypt
435 (package
436 (name "python-py-bcrypt")
437 (version "0.4")
438 (source
439 (origin
440 (method url-fetch)
441 (uri (string-append
442 "https://pypi.python.org/packages/source/p/py-bcrypt/py-bcrypt-"
443 version
444 ".tar.gz"))
445 (sha256
446 (base32
447 "0y6smdggwi5s72v6p1nn53dg6w05hna3d264cq6kas0lap73p8az"))))
448 (build-system python-build-system)
449 (native-inputs
450 `(("python-setuptools" ,python-setuptools)))
451 (home-page "https://code.google.com/p/py-bcrypt")
452 (synopsis
453 "Bcrypt password hashing and key derivation")
454 (description
455 "A python wrapper of OpenBSD's Blowfish password hashing code. This
456system hashes passwords using a version of Bruce Schneier's Blowfish block
457cipher with modifications designed to raise the cost of off-line password
458cracking and frustrate fast hardware implementation. The computation cost of
459the algorithm is parametised, so it can be increased as computers get faster.
460The intent is to make a compromise of a password database less likely to
461result in an attacker gaining knowledge of the plaintext passwords (e.g. using
462John the Ripper).")
463 ;; "sha2.c" is under BSD-3;
464 ;; "blowfish.c" and "bcrypt.c" are under BSD-4;
465 ;; the rest is under ISC.
466 (license (list isc bsd-3 bsd-4))))
467
468(define-public python2-py-bcrypt
469 (package-with-python2 python-py-bcrypt))
470
471
429fdea1
ED
472(define-public python-paramiko
473 (package
474 (name "python-paramiko")
81b9bbbd 475 (version "1.16.0")
429fdea1
ED
476 (source
477 (origin
478 (method url-fetch)
81b9bbbd 479 (uri (pypi-uri "paramiko" version))
429fdea1
ED
480 (sha256
481 (base32
81b9bbbd 482 "14k8z7ndc3zk5xivnm4d8lncchx475ll5izpf8vmfbq7rp9yp5rj"))))
429fdea1
ED
483 (build-system python-build-system)
484 (native-inputs
485 `(("python-setuptools" ,python-setuptools)))
a3fc12da
CR
486 (propagated-inputs
487 `(("python-pycrypto" ,python-pycrypto)))
429fdea1 488 (inputs
a3fc12da 489 `(("python-ecdsa" ,python-ecdsa)))
429fdea1
ED
490 (home-page "http://www.paramiko.org/")
491 (synopsis "SSHv2 protocol library")
492 (description "Paramiko is a python implementation of the SSHv2 protocol,
493providing both client and server functionality. While it leverages a Python C
494extension for low level cryptography (PyCrypto), Paramiko itself is a pure
495Python interface around SSH networking concepts.")
496 (license lgpl2.1+)))
497
498(define-public python2-paramiko
499 (package-with-python2 python-paramiko))
500
501
de73dbf6
ED
502(define-public python-httplib2
503 (package
504 (name "python-httplib2")
286f1bac 505 (version "0.9.2")
de73dbf6
ED
506 (source
507 (origin
508 (method url-fetch)
286f1bac 509 (uri (pypi-uri "httplib2" version))
de73dbf6
ED
510 (sha256
511 (base32
286f1bac 512 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
de73dbf6
ED
513 (build-system python-build-system)
514 (native-inputs
515 `(("python-setuptools" ,python-setuptools)))
286f1bac 516 (home-page "https://github.com/jcgregorio/httplib2")
de73dbf6
ED
517 (synopsis "Comprehensive HTTP client library")
518 (description
519 "A comprehensive HTTP client library supporting many features left out of
520other HTTP libraries.")
521 (license license:expat)))
522
523(define-public python2-httplib2
524 (package-with-python2 python-httplib2))
525
67039875
ED
526(define-public python-ecdsa
527 (package
528 (name "python-ecdsa")
529 (version "0.13")
530 (source
531 (origin
532 (method url-fetch)
533 (uri (string-append
534 "https://pypi.python.org/packages/source/e/ecdsa/ecdsa-"
535 version
536 ".tar.gz"))
537 (sha256
538 (base32
539 "1yj31j0asmrx4an9xvsaj2icdmzy6pw0glfpqrrkrphwdpi1xkv4"))))
540 (build-system python-build-system)
541 (native-inputs
542 `(("python-setuptools" ,python-setuptools)))
543 (inputs
544 `(("openssl" ,openssl)))
545 (home-page
546 "http://github.com/warner/python-ecdsa")
547 (synopsis
548 "ECDSA cryptographic signature library (pure python)")
549 (description
550 "This is an easy-to-use implementation of ECDSA cryptography (Elliptic
551Curve Digital Signature Algorithm), implemented purely in Python. With this
552library, you can quickly create keypairs (signing key and verifying key), sign
553messages, and verify the signatures. The keys and signatures are very short,
554making them easy to handle and incorporate into other protocols.")
555 (license license:expat)))
556
557(define-public python2-ecdsa
558 (package-with-python2 python-ecdsa))
559
52323f32
ED
560(define-public python-ccm
561 (package
562 (name "python-ccm")
db5567f7 563 (version "2.1.6")
52323f32
ED
564 (source
565 (origin
566 (method url-fetch)
db5567f7 567 (uri (pypi-uri "ccm" version))
52323f32
ED
568 (sha256
569 (base32
db5567f7 570 "177dfxsmk3k4cih6fh6v8d91bh4nqx7ns6pc07w7m7i3cvdx3c8n"))))
52323f32
ED
571 (build-system python-build-system)
572 (native-inputs
573 `(("python-setuptools" ,python-setuptools)))
574 (inputs
575 `(("python-pyyaml" ,python-pyyaml)
576 ("python-six" ,python-six)))
577 (home-page "https://github.com/pcmanus/ccm")
578 (synopsis "Cassandra Cluster Manager")
579 (description "A script/library to create, launch and remove an Apache
580Cassandra cluster on localhost.")
581 (license asl2.0)))
582
583(define-public python2-ccm
584 (package-with-python2 python-ccm))
585
89114f39 586(define-public python-pytz
acc26ff1 587 (package
89114f39 588 (name "python-pytz")
61c9babb 589 (version "2016.3")
acc26ff1
CR
590 (source
591 (origin
592 (method url-fetch)
61c9babb 593 (uri (pypi-uri "pytz" version ".tar.bz2"))
acc26ff1
CR
594 (sha256
595 (base32
61c9babb 596 "1mjmrkk4vc5xzppw7fm0pli1nnbj57cvqv7jjv5whcmccyhxz4y1"))))
acc26ff1 597 (build-system python-build-system)
8498b8cf 598 (arguments `(#:tests? #f)) ; no test target
b01bbbcf 599 (home-page "http://pythonhosted.org/pytz")
9e771e3b 600 (synopsis "Python timezone library")
acc26ff1
CR
601 (description
602 "This library allows accurate and cross platform timezone calculations
603using Python 2.4 or higher and provides access to the Olson timezone database.")
b01bbbcf 604 (license license:expat)))
5ace6e2f 605
89114f39 606(define-public python2-pytz
11bb85a1 607 (package-with-python2 python-pytz))
89114f39 608
fc50e9c6 609
89114f39 610(define-public python-babel
5ace6e2f 611 (package
89114f39 612 (name "python-babel")
3f37db6b 613 (version "2.3.2")
5ace6e2f
CR
614 (source
615 (origin
616 (method url-fetch)
b850a6d8 617 (uri (pypi-uri "Babel" version))
5ace6e2f
CR
618 (sha256
619 (base32
3f37db6b 620 "0k43pi0p1dwpds2w0km3fw92wixzxv2vw7p09capxmjz5cfh23lw"))))
5ace6e2f
CR
621 (build-system python-build-system)
622 (inputs
e1804763
AE
623 `(("python-pytz" ,python-pytz)
624 ("python-setuptools" ,python-setuptools)))
8498b8cf 625 (arguments `(#:tests? #f)) ; no test target
e1804763 626 (home-page "http://babel.pocoo.org/")
5ace6e2f
CR
627 (synopsis
628 "Tools for internationalizing Python applications")
629 (description
630 "Babel is composed of two major parts:
631- tools to build and work with gettext message catalogs
632- a Python interface to the CLDR (Common Locale Data Repository), providing
633access to various locale display names, localized number and date formatting,
634etc. ")
635 (license bsd-3)))
89114f39
AE
636
637(define-public python2-babel
11bb85a1 638 (package-with-python2 python-babel))
73adf220 639
ed377cc6
RW
640(define-public python2-backport-ssl-match-hostname
641 (package
642 (name "python2-backport-ssl-match-hostname")
f2d06d46 643 (version "3.5.0.1")
ed377cc6
RW
644 (source
645 (origin
646 (method url-fetch)
647 (uri (string-append
648 "https://pypi.python.org/packages/source/b/"
649 "backports.ssl_match_hostname/backports.ssl_match_hostname-"
650 version ".tar.gz"))
651 (sha256
652 (base32
f2d06d46 653 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
ed377cc6 654 (build-system python-build-system)
f2d06d46
EF
655 (arguments
656 `(#:python ,python-2
657 #:tests? #f)) ; no test target
ed377cc6
RW
658 (inputs
659 `(("python2-setuptools" ,python2-setuptools)))
f2d06d46
EF
660 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
661 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
ed377cc6
RW
662 (description
663 "This backport brings the ssl.match_hostname() function to users of
664earlier versions of Python. The function checks the hostname in the
665certificate returned by the server to which a connection has been established,
666and verifies that it matches the intended target hostname.")
667 (license psfl)))
668
ef5cbf9b
RW
669(define-public python-h5py
670 (package
671 (name "python-h5py")
fe147c41 672 (version "2.6.0")
ef5cbf9b
RW
673 (source
674 (origin
675 (method url-fetch)
fe147c41 676 (uri (pypi-uri "h5py" version))
ef5cbf9b
RW
677 (sha256
678 (base32
fe147c41 679 "0df46dg7i7xfking9lp221bfm8dbl974yvlrbi1w7r6m61ac7bxj"))))
ef5cbf9b 680 (build-system python-build-system)
797e1401
RW
681 (arguments
682 `(#:tests? #f ; no test target
683 #:phases
684 (modify-phases %standard-phases
685 (add-after 'unpack 'fix-hdf5-paths
686 (lambda* (#:key inputs #:allow-other-keys)
687 (let ((prefix (assoc-ref inputs "hdf5")))
688 (substitute* "setup_build.py"
689 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
690 (string-append "['" prefix "/lib" "']"))
691 (("'/opt/local/include', '/usr/local/include'")
692 (string-append "'" prefix "/include" "'")))
693 (substitute* "setup_configure.py"
694 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
695 (string-append "['" prefix "/lib" "']")))
696 #t))))))
3c4010b1
RW
697 (propagated-inputs
698 `(("python-numpy" ,python-numpy)))
ef5cbf9b 699 (inputs
fe147c41
EF
700 `(("hdf5" ,hdf5)
701 ("python-six" ,python-six)))
ef5cbf9b 702 (native-inputs
fe147c41
EF
703 `(("python-cython" ,python-cython)
704 ("python-pkgconfig" ,python-pkgconfig)))
ef5cbf9b
RW
705 (home-page "http://www.h5py.org/")
706 (synopsis "Read and write HDF5 files from Python")
707 (description
708 "The h5py package provides both a high- and low-level interface to the
709HDF5 library from Python. The low-level interface is intended to be a
710complete wrapping of the HDF5 API, while the high-level component supports
711access to HDF5 files, datasets and groups using established Python and NumPy
712concepts.")
fe147c41
EF
713 (license bsd-3)
714 (properties `((python2-variant . ,(delay python2-h5py))))))
ef5cbf9b
RW
715
716(define-public python2-h5py
fe147c41 717 (package-with-python2 (strip-python2-variant python-h5py)))
ef5cbf9b 718
c1448c69
EB
719(define-public python-lockfile
720 (package
721 (name "python-lockfile")
692add53 722 (version "0.12.2")
c1448c69
EB
723 (source
724 (origin
725 (method url-fetch)
726 (uri (string-append "https://pypi.python.org/packages/source/l/lockfile/"
727 "lockfile-" version ".tar.gz"))
728 (sha256
729 (base32
692add53 730 "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba"))))
c1448c69
EB
731 (build-system python-build-system)
732 (arguments '(#:test-target "check"))
692add53
BW
733 (native-inputs
734 `(("python-pbr" ,python-pbr)))
c1448c69
EB
735 (home-page "http://code.google.com/p/pylockfile/")
736 (synopsis "Platform-independent file locking module")
737 (description
738 "The lockfile package exports a LockFile class which provides a simple
739API for locking files.")
1804527a
BW
740 (license license:expat)
741 (properties `((python2-variant . ,(delay python2-lockfile))))))
c1448c69
EB
742
743(define-public python2-lockfile
1804527a
BW
744 (let ((base (package-with-python2 (strip-python2-variant python-lockfile))))
745 (package
692add53
BW
746 (inherit base)
747 (native-inputs `(("python2-setuptools" ,python2-setuptools)
748 ,@(package-native-inputs base))))))
c1448c69 749
5a1a4bf6
EB
750(define-public python-mock
751 (package
752 (name "python-mock")
753 (version "1.0.1")
754 (source
755 (origin
756 (method url-fetch)
757 (uri (string-append "https://pypi.python.org/packages/source/m/mock/"
758 "mock-" version ".tar.gz"))
759 (sha256
760 (base32
761 "0kzlsbki6q0awf89rc287f3aj8x431lrajf160a70z0ikhnxsfdq"))))
762 (build-system python-build-system)
763 (arguments '(#:test-target "check"))
07af3e5e 764 (home-page "http://code.google.com/p/mock/")
9e771e3b 765 (synopsis "Python mocking and patching library for testing")
5a1a4bf6
EB
766 (description
767 "Mock is a library for testing in Python. It allows you to replace parts
768of your system under test with mock objects and make assertions about how they
769have been used.")
bd3fa666 770 (license license:expat)))
5a1a4bf6
EB
771
772(define-public python2-mock
773 (package-with-python2 python-mock))
774
fc50e9c6 775
73adf220
AE
776(define-public python-setuptools
777 (package
778 (name "python-setuptools")
62a9a23b 779 (version "18.3.1")
73adf220
AE
780 (source
781 (origin
782 (method url-fetch)
783 (uri (string-append "https://pypi.python.org/packages/source/s/setuptools/setuptools-"
784 version ".tar.gz"))
785 (sha256
786 (base32
62a9a23b 787 "0kc7rbav00ks6iaw14p38y81q12fx0lpkhgf5m97xc04f5r318ig"))))
73adf220 788 (build-system python-build-system)
d3d656c5
AE
789 ;; FIXME: Tests require pytest, which itself relies on setuptools.
790 ;; One could bootstrap with an internal untested setuptools.
73adf220 791 (arguments
824af8ca 792 `(#:tests? #f))
73adf220
AE
793 (home-page "https://pypi.python.org/pypi/setuptools")
794 (synopsis
795 "Library designed to facilitate packaging Python projects")
796 (description
797 "Setuptools is a fully-featured, stable library designed to facilitate
798packaging Python projects, where packaging includes:
799Python package and module definitions,
800distribution package metadata,
801test hooks,
802project installation,
803platform-specific details,
804Python 3 support.")
805 (license psfl)))
806
807(define-public python2-setuptools
808 (package-with-python2 python-setuptools))
fc50e9c6
AE
809
810
cafc3f5a
EB
811(define-public python-pycrypto
812 (package
813 (name "python-pycrypto")
814 (version "2.6.1")
815 (source
816 (origin
817 (method url-fetch)
818 (uri (string-append "https://pypi.python.org/packages/source/p/"
819 "pycrypto/pycrypto-" version ".tar.gz"))
820 (sha256
821 (base32
822 "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj"))))
823 (build-system python-build-system)
824 (native-inputs
825 `(("python-setuptools" ,python-setuptools)))
826 (inputs
827 `(("python" ,python)
828 ("gmp" ,gmp)))
829 (arguments
830 `(#:phases
831 (alist-cons-before
832 'build 'set-build-env
833 ;; pycrypto runs an autoconf configure script behind the scenes
834 (lambda _
835 (setenv "CONFIG_SHELL" (which "bash")))
836 %standard-phases)))
837 (home-page "http://www.pycrypto.org/")
838 (synopsis "Cryptographic modules for Python")
839 (description
840 "Pycrypto is a collection of both secure hash functions (such as SHA256
841and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal,
35b9e423 842etc.). The package is structured to make adding new modules easy.")
cafc3f5a
EB
843 (license public-domain)))
844
345f0611 845(define-public python2-pycrypto
1c0059da
EF
846 (let ((pycrypto (package-with-python2 python-pycrypto)))
847 (package (inherit pycrypto)
848 (inputs
849 `(("python" ,python-2)
850 ,@(alist-delete
851 "python"
852 (package-inputs pycrypto)))))))
345f0611 853
cafc3f5a
EB
854(define-public python-keyring
855 (package
856 (name "python-keyring")
13f3ff35 857 (version "8.7")
cafc3f5a
EB
858 (source
859 (origin
860 (method url-fetch)
664e6c3a 861 (uri (pypi-uri "keyring" version))
cafc3f5a
EB
862 (sha256
863 (base32
13f3ff35 864 "0482rmi2x6p78wl2kz8qzyq21xz1sbbfwnv5x7dggar4vkwxhzfx"))))
cafc3f5a
EB
865 (build-system python-build-system)
866 (native-inputs
13f3ff35 867 `(("python-setuptools-scm" ,python-setuptools-scm)))
cafc3f5a
EB
868 (inputs
869 `(("python-pycrypto" ,python-pycrypto)))
870 (arguments
664e6c3a 871 `(#:tests? #f)) ;TODO: tests require pytest
cafc3f5a
EB
872 (home-page "http://bitbucket.org/kang/python-keyring-lib")
873 (synopsis "Store and access your passwords safely")
874 (description
875 "The Python keyring lib provides a easy way to access the system keyring
35b9e423 876service from python. It can be used in any application that needs safe
cafc3f5a
EB
877password storage.")
878 ;; "MIT" and PSF dual license
13f3ff35
EF
879 (license x11)
880 (properties `((python2-variant . ,(delay python2-keyring))))))
cafc3f5a 881
d7af1069 882(define-public python2-keyring
13f3ff35
EF
883 (let ((base (package-with-python2 (strip-python2-variant python-keyring))))
884 (package
885 (inherit base)
886 (native-inputs `(("python2-setuptools" ,python2-setuptools)
887 ,@(package-native-inputs base))))))
d7af1069 888
a480bc41
EB
889(define-public python-six
890 (package
891 (name "python-six")
b6ab89ef 892 (version "1.10.0")
a480bc41
EB
893 (source
894 (origin
895 (method url-fetch)
b6ab89ef 896 (uri (pypi-uri "six" version))
a480bc41
EB
897 (sha256
898 (base32
b6ab89ef 899 "0snmb8xffb3vsma0z67i0h0w2g2dy0p3gsgh9gi4i0kgc5l8spqh"))))
a480bc41
EB
900 (build-system python-build-system)
901 (inputs
902 `(("python-setuptools" ,python-setuptools)))
903 (home-page "http://pypi.python.org/pypi/six/")
904 (synopsis "Python 2 and 3 compatibility utilities")
905 (description
35b9e423 906 "Six is a Python 2 and 3 compatibility library. It provides utility
a480bc41
EB
907functions for smoothing over the differences between the Python versions with
908the goal of writing Python code that is compatible on both Python versions.
35b9e423 909Six supports every Python version since 2.5. It is contained in only one
a480bc41
EB
910Python file, so it can be easily copied into your project.")
911 (license x11)))
912
0c20025c
AE
913(define-public python2-six
914 (package-with-python2 python-six))
915
cafc3f5a
EB
916(define-public python-dateutil-2
917 (package
918 (name "python-dateutil")
394b8060 919 (version "2.5.2")
cafc3f5a
EB
920 (source
921 (origin
922 (method url-fetch)
394b8060 923 (uri (pypi-uri "python-dateutil" version))
cafc3f5a
EB
924 (sha256
925 (base32
394b8060 926 "0jrfpcgvgya6hs45dhrd9yiqgdgz9qp9aa07zsw8gqgn8zphff86"))))
cafc3f5a
EB
927 (build-system python-build-system)
928 (inputs
394b8060 929 `(("python-six" ,python-six)))
cafc3f5a
EB
930 (home-page "http://labix.org/python-dateutil")
931 (synopsis "Extensions to the standard datetime module")
932 (description
933 "The dateutil module provides powerful extensions to the standard
934datetime module, available in Python 2.3+.")
394b8060
EF
935 (license bsd-3)
936 (properties `((python2-variant . ,(delay python2-dateutil-2))))))
cafc3f5a
EB
937
938(define-public python2-dateutil-2
394b8060
EF
939 (let ((base (package-with-python2 (strip-python2-variant python-dateutil-2))))
940 (package
941 (inherit base)
942 (inputs `(("python2-setuptools" ,python2-setuptools)
943 ,@(package-inputs base))))))
cafc3f5a 944
fc50e9c6
AE
945(define-public python-dateutil
946 (package
947 (name "python-dateutil")
948 (version "1.5") ; last version for python < 3
949 (source
950 (origin
951 (method url-fetch)
cafc3f5a
EB
952 (uri (string-append "http://labix.org/download/python-dateutil/"
953 "python-dateutil-" version ".tar.gz"))
fc50e9c6
AE
954 (sha256
955 (base32
956 "0fqfglhy5khbvsipr3x7m6bcaqljh8xl5cw33vbfxy7qhmywm2n0"))))
957 (build-system python-build-system)
958 (inputs
959 `(("python-setuptools" ,python-setuptools)))
960 (home-page "http://labix.org/python-dateutil")
cafc3f5a 961 (synopsis "Extensions to the standard datetime module")
fc50e9c6
AE
962 (description
963 "The dateutil module provides powerful extensions to the standard
964datetime module, available in Python 2.3+.")
965 (license psfl)))
966
967(define-public python2-dateutil
968 (package-with-python2 python-dateutil))
1d08c01f 969
cafc3f5a
EB
970(define-public python-parsedatetime
971 (package
972 (name "python-parsedatetime")
eebf6f01 973 (version "2.1")
cafc3f5a
EB
974 (source
975 (origin
976 (method url-fetch)
eebf6f01 977 (uri (pypi-uri "parsedatetime" version))
cafc3f5a
EB
978 (sha256
979 (base32
eebf6f01 980 "0bdgyw6y3v7bcxlx0p50s8drxsh5bb5cy2afccqr3j90amvpii8p"))))
cafc3f5a
EB
981 (build-system python-build-system)
982 (native-inputs
eebf6f01
EF
983 `(("python-nose" ,python-nose)
984 ("python-pyicu" ,python-pyicu)))
cafc3f5a
EB
985 (home-page "http://github.com/bear/parsedatetime/")
986 (synopsis
987 "Parse human-readable date/time text")
988 (description
e881752c 989 "Parse human-readable date/time text.")
eebf6f01
EF
990 (license asl2.0)
991 (properties `((python2-variant . ,(delay python2-parsedatetime))))))
cafc3f5a 992
38b8f9b2 993(define-public python2-parsedatetime
eebf6f01
EF
994 (let ((base (package-with-python2 (strip-python2-variant python-parsedatetime))))
995 (package
996 (inherit base)
997 (native-inputs `(("python2-setuptools" ,python2-setuptools)
998 ,@(package-native-inputs base))))))
38b8f9b2 999
d072efcb
RW
1000(define-public python-pandas
1001 (package
1002 (name "python-pandas")
7d0c3c8d 1003 (version "0.18.1")
d072efcb
RW
1004 (source
1005 (origin
1b96f069 1006 (method url-fetch)
7d0c3c8d
EF
1007 (uri (string-append
1008 "https://pypi.python.org/packages/11/09/"
1009 "e66eb844daba8680ddff26335d5b4fead77f60f957678243549a8dd4830d/"
1010 "pandas-" version ".tar.gz"))
1b96f069 1011 (sha256
7d0c3c8d 1012 (base32 "1ckpxrvvjj6zxmn68icd9hib8qcpx9b35f6izxnr25br5ilq7r6j"))))
d072efcb 1013 (build-system python-build-system)
d072efcb 1014 (propagated-inputs
42603726
EF
1015 `(("python-numpy" ,python-numpy)))
1016 (inputs
1017 `(("python-pytz" ,python-pytz)
d072efcb
RW
1018 ("python-dateutil" ,python-dateutil-2)))
1019 (native-inputs
7d0c3c8d 1020 `(("python-nose" ,python-nose)))
d072efcb
RW
1021 (home-page "http://pandas.pydata.org")
1022 (synopsis "Data structures for data analysis, time series, and statistics")
1023 (description
1024 "Pandas is a Python package providing fast, flexible, and expressive data
1025structures designed to make working with structured (tabular,
1026multidimensional, potentially heterogeneous) and time series data both easy
1027and intuitive. It aims to be the fundamental high-level building block for
1028doing practical, real world data analysis in Python.")
7d0c3c8d
EF
1029 (license bsd-3)
1030 (properties `((python2-variant . ,(delay python2-pandas))))))
d072efcb
RW
1031
1032(define-public python2-pandas
7d0c3c8d
EF
1033 (let ((base (package-with-python2 (strip-python2-variant python-pandas))))
1034 (package
1035 (inherit base)
1036 (native-inputs `(("python2-setuptools" ,python2-setuptools)
dbd40ac1 1037 ,@(package-native-inputs base))))))
d072efcb 1038
cafc3f5a
EB
1039(define-public python-tzlocal
1040 (package
1041 (name "python-tzlocal")
ed80839b 1042 (version "1.2.2")
cafc3f5a
EB
1043 (source
1044 (origin
1045 (method url-fetch)
226d3331 1046 (uri (pypi-uri "tzlocal" version))
cafc3f5a
EB
1047 (sha256
1048 (base32
ed80839b 1049 "0paj7vlsb0np8b5sp4bv64wxv7qk2piyp7xg29pkhdjwsbls9fnb"))))
cafc3f5a 1050 (build-system python-build-system)
ed80839b 1051 (inputs `(("python-pytz" ,python-pytz)))
cafc3f5a
EB
1052 (home-page "https://github.com/regebro/tzlocal")
1053 (synopsis
35b9e423 1054 "Local timezone information for Python")
cafc3f5a
EB
1055 (description
1056 "Tzlocal returns a tzinfo object with the local timezone information.
1057This module attempts to fix a glaring hole in pytz, that there is no way to
1058get the local timezone information, unless you know the zoneinfo name, and
1059under several distributions that's hard or impossible to figure out.")
1060 (license cc0)))
1061
1d08c01f
AE
1062(define-public python2-pysqlite
1063 (package
1064 (name "python2-pysqlite")
fe476868 1065 (version "2.8.1")
1d08c01f
AE
1066 (source
1067 (origin
1068 (method url-fetch)
fe476868 1069 (uri (pypi-uri "pysqlite" version))
1d08c01f
AE
1070 (sha256
1071 (base32
fe476868 1072 "0rm0zqyb363y6wljhfmbxs16jjv7p8nk1d8zgq9sdwj6js7y3jkm"))))
1d08c01f
AE
1073 (build-system python-build-system)
1074 (inputs
1075 `(("sqlite" ,sqlite)))
1076 (arguments
1077 `(#:python ,python-2 ; incompatible with Python 3
1078 #:tests? #f)) ; no test target
fe476868 1079 (home-page "http://github.com/ghaering/pysqlite")
7a03af70 1080 (synopsis "SQLite bindings for Python")
1d08c01f
AE
1081 (description
1082 "Pysqlite provides SQLite bindings for Python that comply to the
1083Database API 2.0T.")
ed0cdf83 1084 (license license:zlib)))
1d08c01f 1085
2875caf5
AE
1086
1087(define-public python2-mechanize
1088 (package
1089 (name "python2-mechanize")
1090 (version "0.2.5")
1091 (source
1092 (origin
1093 (method url-fetch)
1094 (uri (string-append "https://pypi.python.org/packages/source/m/mechanize/mechanize-"
1095 version ".tar.gz"))
1096 (sha256
1097 (base32
1098 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1099 (build-system python-build-system)
1100 (inputs
1101 `(("python2-setuptools" ,python2-setuptools)))
1102 (arguments
1103 `(#:python ,python-2 ; apparently incompatible with Python 3
1104 #:tests? #f))
1105 ;; test fails with message
1106 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1107 ;; (python-3.3.2) or
1108 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1109 ;; (python-2.7.5).
1110 ;; The source code is from March 2011 and probably not up-to-date
1111 ;; with respect to python unit tests.
1112 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1113 (synopsis
1114 "Stateful programmatic web browsing in Python")
1115 (description
1116 "Mechanize implements stateful programmatic web browsing in Python,
1117after Andy Lester’s Perl module WWW::Mechanize.")
166191b3 1118 (license (non-copyleft "file://COPYING"
e881752c 1119 "See COPYING in the distribution."))))
2875caf5 1120
0352532e
AE
1121
1122(define-public python-simplejson
1123 (package
1124 (name "python-simplejson")
1125 (version "3.3.0")
1126 (source
1127 (origin
1128 (method url-fetch)
1129 (uri (string-append "https://pypi.python.org/packages/source/s/simplejson/simplejson-"
1130 version ".tar.gz"))
1131 (sha256
1132 (base32
1133 "07wsry5j44l5zzm74l4j2bvasiq8n5m32f31n2p7c68i5vc6p2ks"))))
1134 (build-system python-build-system)
1135 (home-page "http://simplejson.readthedocs.org/en/latest/")
1136 (synopsis
1137 "Json library for Python")
1138 (description
e881752c
AK
1139 "JSON (JavaScript Object Notation) is a subset of JavaScript
1140syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1141format.
0352532e
AE
1142
1143Simplejson exposes an API familiar to users of the standard library marshal
1144and pickle modules. It is the externally maintained version of the json
1145library contained in Python 2.6, but maintains compatibility with Python 2.5
1146and (currently) has significant performance advantages, even without using
1147the optional C extension for speedups. Simplejson is also supported on
1148Python 3.3+.")
1149 (license x11)))
1150
1151(define-public python2-simplejson
1152 (package-with-python2 python-simplejson))
421a80a2
AE
1153
1154
ed07b08d 1155(define-public python-pyicu
421a80a2 1156 (package
ed07b08d 1157 (name "python-pyicu")
d3b29319 1158 (version "1.9.2")
421a80a2
AE
1159 (source
1160 (origin
1161 (method url-fetch)
1162 (uri (string-append "https://pypi.python.org/packages/source/P/PyICU/PyICU-"
1163 version ".tar.gz"))
1164 (sha256
1165 (base32
d3b29319 1166 "1diba0g8md614fvm9yf50paiwdkhj6rd7xwf1rg9mc0pxc0hhn4v"))))
421a80a2
AE
1167 (build-system python-build-system)
1168 (inputs
1169 `(("icu4c" ,icu4c)))
421a80a2 1170 (home-page "http://pyicu.osafoundation.org/")
9e771e3b 1171 (synopsis "Python extension wrapping the ICU C++ API")
421a80a2
AE
1172 (description
1173 "PyICU is a python extension wrapping the ICU C++ API.")
ed07b08d
LF
1174 (license x11)
1175 (properties `((python2-variant . ,(delay python2-pyicu))))))
1176
1177(define-public python2-pyicu
1178 (package
1179 (inherit (package-with-python2
1180 (strip-python2-variant python-pyicu)))
1181 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
cc20a22a
LC
1182
1183(define-public python2-dogtail
1184 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1185 ;; spaces in indentation" with Python 3.
1186 (package
1187 (name "python2-dogtail")
1188 (version "0.8.2")
1189 (source (origin
1190 (method url-fetch)
1191 (uri (string-append
1192 "https://fedorahosted.org/released/dogtail/dogtail-"
1193 version ".tar.gz"))
1194 (sha256
1195 (base32
1196 "1yc4cg7ip87z15gyd4wy2vzbywrjc52a3m8r8gqy2b50d65llcg1"))))
1197 (build-system python-build-system)
1198 (arguments `(#:python ,python-2
1199 #:tests? #f)) ; invalid command "test"
1200 (home-page "https://fedorahosted.org/dogtail/")
1201 (synopsis "GUI test tool and automation framework written in ​Python")
1202 (description
35b9e423 1203 "Dogtail is a GUI test tool and automation framework written in Python.
cc20a22a
LC
1204It uses Accessibility (a11y) technologies to communicate with desktop
1205applications. dogtail scripts are written in Python and executed like any
1206other Python program.")
1207 (license gpl2+)))
515e6878 1208
011b18c3
LC
1209(define-public python2-empy
1210 (package
1211 (name "python2-empy")
1212 (version "3.3")
1213 (source (origin
1214 (method url-fetch)
1215 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1216 version ".tar.gz"))
1217 (sha256
1218 (base32
1219 "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6"))))
1220 (build-system python-build-system)
1221 (arguments
1222 `(#:python ,python-2
1223 #:phases (alist-replace
1224 'check
1225 (lambda _
1226 (zero? (system* "./test.sh")))
1227 %standard-phases)))
1228 (home-page "http://www.alcyone.com/software/empy/")
1229 (synopsis "Templating system for Python")
1230 (description
1231 "EmPy is a system for embedding Python expressions and statements in
1232template text; it takes an EmPy source file, processes it, and produces
1233output. This is accomplished via expansions, which are special signals to the
1cd4027c 1234EmPy system and are set off by a special prefix (by default the at sign, @@).
011b18c3
LC
1235EmPy can expand arbitrary Python expressions and statements in this way, as
1236well as a variety of special forms. Textual data not explicitly delimited in
1237this way is sent unaffected to the output, allowing Python to be used in
1238effect as a markup language. Also supported are callbacks via hooks,
1239recording and playback via diversions, and dynamic, chainable filters. The
1240system is highly configurable via command line options and embedded
1241commands.")
1242 (license lgpl2.1+)))
1243
8deeda0c
LC
1244(define-public python2-element-tree
1245 (package
1246 (name "python2-element-tree")
1247 (version "1.2.6")
1248 (source (origin
1249 (method url-fetch)
1250 (uri (string-append
1251 "http://effbot.org/media/downloads/elementtree-"
1252 version "-20050316.tar.gz"))
1253 (sha256
1254 (base32
1255 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1256 (build-system python-build-system)
1257 (arguments
1258 `(#:python ,python-2 ; seems to be part of Python 3
1259 #:tests? #f)) ; no 'test' sub-command
1260 (synopsis "Toolkit for XML processing in Python")
1261 (description
1262 "ElementTree is a Python library supporting lightweight XML processing.")
1263 (home-page "http://effbot.org/zone/element-index.htm")
1264 (license (x11-style "http://docs.python.org/2/license.html"
1265 "Like \"CWI LICENSE AGREEMENT FOR PYTHON \
12660.9.0 THROUGH 1.2\"."))))
1267
1268(define-public python2-pybugz
1269 (package
1270 (name "python2-pybugz")
1271 (version "0.6.11")
1272 (source (origin
1273 (method url-fetch)
1274 (uri (string-append
1275 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1276 version ".tar.gz"))
1277 (sha256
1278 (base32
6f194a1e 1279 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
fc1adab1
AK
1280 (patches (search-patches "pybugz-stty.patch"
1281 "pybugz-encode-error.patch"))))
8deeda0c
LC
1282 (build-system python-build-system)
1283 (arguments
1284 `(#:python ,python-2 ; SyntaxError with Python 3
1285 #:tests? #f)) ; no 'test' sub-command
1286 (inputs `(("element-tree" ,python2-element-tree)))
1287 (synopsis "Python and command-line interface to Bugzilla")
1288 (description
1289 "PyBugz is a Python library and command-line tool to query the Bugzilla
1290bug tracking system. It is meant as an aid to speed up interaction with the
1291bug tracker.")
1292 (home-page "http://www.liquidx.net/pybugz/")
1293 (license gpl2)))
1294
a480bc41
EB
1295(define-public python-enum34
1296 (package
1297 (name "python-enum34")
d39ae1e5 1298 (version "1.1.0")
a480bc41
EB
1299 (source
1300 (origin
1301 (method url-fetch)
d39ae1e5 1302 (uri (pypi-uri "enum34" version))
a480bc41
EB
1303 (sha256
1304 (base32
d39ae1e5 1305 "0yx1m4564wxgbm4glb3457hi16xihd9w63rv13y2przkdir9dfgp"))))
a480bc41 1306 (build-system python-build-system)
a480bc41
EB
1307 (arguments
1308 `(#:phases
1309 (alist-replace
1310 'check
1311 (lambda _ (zero? (system* "python" "enum/test_enum.py")))
1312 %standard-phases)))
1313 (home-page "https://pypi.python.org/pypi/enum34")
1314 (synopsis "Backported Python 3.4 Enum")
1315 (description
1316 "Enum34 is the new Python stdlib enum module available in Python 3.4
1317backported for previous versions of Python from 2.4 to 3.3.")
1318 (license bsd-3)))
1319
820acd1b
LF
1320(define-public python2-enum34
1321 (package-with-python2 python-enum34))
1322
a480bc41
EB
1323(define-public python-parse-type
1324 (package
1325 (name "python-parse-type")
1326 (version "0.3.4")
1327 (source
1328 (origin
1329 (method url-fetch)
1330 (uri (string-append "https://pypi.python.org/packages/source/p/"
1331 "parse_type/parse_type-" version ".tar.gz"))
1332 (sha256
1333 (base32
1334 "0iv1c34npr4iynwpgv1vkjx9rjd18a85ir8c01gc5f7wp8iv7l1x"))))
1335 (build-system python-build-system)
1336 (inputs
1337 `(("python-setuptools" ,python-setuptools)
1338 ("python-six" ,python-six)
68f1cdec 1339 ("python-parse" ,python-parse)))
a480bc41
EB
1340 (arguments '(#:tests? #f)) ;TODO: tests require pytest
1341 (home-page "https://github.com/jenisys/parse_type")
1342 (synopsis "Extended parse module")
1343 (description
1344 "Parse_type extends the python parse module.")
1345 (license bsd-3)))
1346
1347(define-public python-parse
1348 (package
1349 (name "python-parse")
eb3d3503 1350 (version "1.6.6")
a480bc41
EB
1351 (source
1352 (origin
1353 (method url-fetch)
eb3d3503 1354 (uri (pypi-uri "parse" version))
a480bc41
EB
1355 (sha256
1356 (base32
eb3d3503 1357 "0y31i3mwgv35qn0kzzjn9q8jqfdqmbi6sr6yfvn8rq4lqjm5lhvi"))))
a480bc41
EB
1358 (build-system python-build-system)
1359 (arguments
1360 `(#:phases
1361 (alist-replace
1362 'check
1363 (lambda _ (zero? (system* "python" "test_parse.py")))
1364 %standard-phases)))
1365 (home-page "https://github.com/r1chardj0n3s/parse")
1366 (synopsis "Parse strings")
1367 (description
1368 "Parse strings using a specification based on the Python format()
1369syntax.")
1370 (license x11)))
1371
1372
515e6878
LC
1373(define-public scons
1374 (package
1375 (name "scons")
a3f61425 1376 (version "2.3.4")
515e6878
LC
1377 (source (origin
1378 (method url-fetch)
1379 (uri (string-append "mirror://sourceforge/scons/scons-"
1380 version ".tar.gz"))
1381 (sha256
1382 (base32
a3f61425 1383 "0hdlci43wjz8maryj83mz04ir6rwcdrrzpd7cpzvdlzycqhdfmsb"))))
515e6878
LC
1384 (build-system python-build-system)
1385 (arguments
1386 ;; With Python 3.x, fails to build with a syntax error.
1387 `(#:python ,python-2
1388 #:tests? #f)) ; no 'python setup.py test' command
1389 (home-page "http://scons.org/")
1390 (synopsis "Software construction tool written in Python")
1391 (description
1392 "SCons is a software construction tool. Think of SCons as an improved,
1393cross-platform substitute for the classic Make utility with integrated
1394functionality similar to autoconf/automake and compiler caches such as ccache.
1395In short, SCons is an easier, more reliable and faster way to build
1396software.")
1397 (license x11)))
011b18c3 1398
c15a5c0e
DT
1399(define-public python-extras
1400 (package
1401 (name "python-extras")
1402 (version "0.0.3")
1403 (source
1404 (origin
1405 (method url-fetch)
1406 (uri (string-append
1407 "https://pypi.python.org/packages/source/e/extras/extras-"
1408 version ".tar.gz"))
1409 (sha256
1410 (base32
1411 "1h7zx4dfyclalg0fqnfjijpn0f793a9mx8sy3b27gd31nr6dhq3s"))))
1412 (build-system python-build-system)
1413 (inputs
1414 `(("python-setuptools" ,python-setuptools)))
1415 (arguments
1416 ;; error in setup.cfg: command 'test' has no such option 'buffer'
1417 '(#:tests? #f))
1418 (home-page "https://github.com/testing-cabal/extras")
1419 (synopsis "Useful extensions to the Python standard library")
1420 (description
1421 "Extras is a set of extensions to the Python standard library.")
bd3fa666 1422 (license license:expat)))
c15a5c0e
DT
1423
1424(define-public python2-extras
1425 (package-with-python2 python-extras))
1426
56ea0efd
DT
1427(define-public python-mimeparse
1428 (package
1429 (name "python-mimeparse")
1430 (version "0.1.4")
1431 (source
1432 (origin
1433 (method url-fetch)
1434 (uri (string-append
1435 "https://pypi.python.org/packages/source/p/python-mimeparse/python-mimeparse-"
1436 version ".tar.gz"))
1437 (sha256
1438 (base32
1439 "1hyxg09kaj02ri0rmwjqi86wk4nd1akvv7n0dx77azz76wga4s9w"))))
1440 (build-system python-build-system)
1441 (inputs
1442 `(("python-setuptools" ,python-setuptools)))
1443 (arguments
1444 '(#:tests? #f)) ; no setup.py test command
1445 (home-page
1446 "https://github.com/dbtsai/python-mimeparse")
9e771e3b 1447 (synopsis "Python library for parsing MIME types")
56ea0efd
DT
1448 (description
1449 "Mimeparse provides basic functions for parsing MIME type names and
1450matching them against a list of media-ranges.")
bd3fa666 1451 (license license:expat)))
56ea0efd
DT
1452
1453(define-public python2-mimeparse
1454 (package-with-python2 python-mimeparse))
1455
4435427e
DT
1456(define-public python-nose
1457 (package
1458 (name "python-nose")
f7cb9841 1459 (version "1.3.7")
4435427e
DT
1460 (source
1461 (origin
1462 (method url-fetch)
f7cb9841 1463 (uri (pypi-uri "nose" version))
4435427e
DT
1464 (sha256
1465 (base32
f7cb9841 1466 "164a43k7k2wsqqk1s6vavcdamvss4mz0vd6pwzv2h9n8rgwzxgzi"))))
4435427e
DT
1467 (build-system python-build-system)
1468 (inputs
1469 `(("python-setuptools" ,python-setuptools)))
1470 (arguments
1471 '(#:tests? #f)) ; FIXME: test suite fails
1472 (home-page "http://readthedocs.org/docs/nose/")
1473 (synopsis "Python testing library")
1474 (description
1475 "Nose extends the unittest library to make testing easier.")
1476 (license lgpl2.0+)))
1477
1478(define-public python2-nose
1479 (package-with-python2 python-nose))
1480
6cd9c356
DT
1481(define-public python-unittest2
1482 (package
1483 (name "python-unittest2")
1484 (version "0.5.1")
1485 (source
1486 (origin
1487 (method url-fetch)
1488 (uri (string-append
1489 "https://pypi.python.org/packages/source/u/unittest2py3k/unittest2py3k-"
1490 version ".tar.gz"))
1491 (sha256
1492 (base32
1493 "00yl6lskygcrddx5zspkhr0ibgvpknl4678kkm6s626539grq93q"))))
1494 (build-system python-build-system)
1495 (inputs
1496 `(("python-setuptools" ,python-setuptools)))
1497 (home-page "http://pypi.python.org/pypi/unittest2")
1498 (synopsis "Python unit testing library")
1499 (description
1500 "Unittest2 is a replacement for the unittest module in the Python
1501standard library.")
1502 (license psfl)))
1503
1504(define-public python2-unittest2
1505 (package (inherit python-unittest2)
1506 (name "python2-unittest2")
1507 (version "0.5.1")
1508 (source
1509 (origin
1510 (method url-fetch)
1511 (uri (string-append
1512 "https://pypi.python.org/packages/source/u/unittest2/unittest2-"
1513 version ".tar.gz"))
1514 (sha256
1515 (base32
1516 "0wbs4i4x3x7klr3v35ss6p9mcqz883i1xgcpkhvl7n2lyv6yhpda"))))
1517 (inputs
7957fe6c 1518 `(("python2-setuptools" ,python2-setuptools)))
6cd9c356
DT
1519 (arguments
1520 `(#:python ,python-2
1521 #:tests? #f)))) ; no setup.py test command
1522
542ad60f
DT
1523(define-public python-py
1524 (package
1525 (name "python-py")
71c8a804 1526 (version "1.4.31")
542ad60f
DT
1527 (source
1528 (origin
1529 (method url-fetch)
71c8a804 1530 (uri (pypi-uri "py" version))
542ad60f
DT
1531 (sha256
1532 (base32
71c8a804 1533 "0561gz2w3i825gyl42mcq14y3dcgkapfiv5zv9a2bz15qxiijl56"))))
542ad60f
DT
1534 (build-system python-build-system)
1535 (inputs
1536 `(("python-setuptools" ,python-setuptools)))
1537 (home-page "http://pylib.readthedocs.org/")
1538 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1539 (description
1540 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1541code introspection, and logging.")
bd3fa666 1542 (license license:expat)))
542ad60f
DT
1543
1544(define-public python2-py
1545 (package-with-python2 python-py))
1546
855d4761
DT
1547(define-public python-pytest
1548 (package
1549 (name "python-pytest")
61a4332d 1550 (version "2.7.3")
855d4761
DT
1551 (source
1552 (origin
1553 (method url-fetch)
1554 (uri (string-append
1555 "https://pypi.python.org/packages/source/p/pytest/pytest-"
1556 version ".tar.gz"))
1557 (sha256
1558 (base32
61a4332d 1559 "1z4yi986f9n0p8qmzmn21m21m8j1x78hk3505f89baqm6pdw7afm"))
855d4761
DT
1560 (modules '((guix build utils)))
1561 (snippet
1562 ;; One of the tests involves the /usr directory, so it fails.
1563 '(substitute* "testing/test_argcomplete.py"
1564 (("def test_remove_dir_prefix\\(self\\):")
1565 "@pytest.mark.xfail\n def test_remove_dir_prefix(self):")))))
1566 (build-system python-build-system)
1567 (inputs
1568 `(("python-setuptools" ,python-setuptools)
1569 ("python-py" ,python-py)
1570 ("python-nose" ,python-nose)
1571 ("python-mock" ,python-mock)))
1572 (home-page "http://pytest.org")
1573 (synopsis "Python testing library")
1574 (description
1575 "Pytest is a testing tool that provides auto-discovery of test modules
1576and functions, detailed info on failing assert statements, modular fixtures,
1577and many external plugins.")
bd3fa666 1578 (license license:expat)))
855d4761
DT
1579
1580(define-public python2-pytest
1581 (package-with-python2 python-pytest))
1582
358c3d61
EF
1583(define-public python-pytest-cov
1584 (package
1585 (name "python-pytest-cov")
545f4a1c 1586 (version "2.2.1")
358c3d61
EF
1587 (source
1588 (origin
1589 (method url-fetch)
1590 (uri (pypi-uri "pytest-cov" version))
1591 (sha256
545f4a1c
EF
1592 (base32
1593 "1yl4nbhzfgsxqlsyk4clafgp9x11zvgrkprm9i2p3fgkwx9jxcm8"))))
10468636 1594 (build-system python-build-system)
545f4a1c 1595 (inputs
10468636
EF
1596 `(("python-coverage" ,python-coverage)
1597 ("python-pytest" ,python-pytest)))
10468636
EF
1598 (home-page "https://github.com/pytest-dev/pytest-cov")
1599 (synopsis "Pytest plugin for measuring coverage")
1600 (description
1601 "Pytest-cov produces coverage reports. It supports centralised testing and
1602distributed testing in both @code{load} and @code{each} modes. It also
1603supports coverage of subprocesses.")
545f4a1c
EF
1604 (license license:expat)
1605 (properties `((python2-variant . ,(delay python2-pytest-cov))))))
358c3d61
EF
1606
1607(define-public python2-pytest-cov
545f4a1c
EF
1608 (let ((base (package-with-python2 (strip-python2-variant python-pytest-cov))))
1609 (package
1610 (inherit base)
1611 (inputs `(("python2-setuptools" ,python2-setuptools)
1612 ,@(package-inputs base))))))
358c3d61 1613
6784f2e3
RW
1614(define-public python-pytest-runner
1615 (package
1616 (name "python-pytest-runner")
1617 (version "2.6.2")
1618 (source
1619 (origin
1620 (method url-fetch)
54cd239b 1621 (uri (pypi-uri "pytest-runner" version))
6784f2e3
RW
1622 (sha256
1623 (base32
1624 "1nwcqx0l3fv52kv8526wy8ypzghbq96c96di318d98d3wh7a8xg7"))))
1625 (build-system python-build-system)
1626 (arguments
1627 `(#:phases
1628 (modify-phases %standard-phases
1629 ;; The fancy way of setting the version with setuptools_scm does not
1630 ;; seem to work here.
1631 (add-after 'unpack 'set-version
1632 (lambda _
1633 (substitute* "docs/conf.py"
1634 (("version = setuptools_scm\\.get_version\\(root='\\.\\.')")
1635 (string-append "version = \"" ,version "\"")))
1636 #t)))))
1637 (native-inputs
1638 `(("python-pytest" ,python-pytest)
1639 ("python-setuptools-scm" ,python-setuptools-scm)))
54cd239b 1640 (home-page "https://github.com/pytest-dev/pytest-runner")
6784f2e3
RW
1641 (synopsis "Invoke py.test as a distutils command")
1642 (description
1643 "This package provides a @command{pytest-runner} command that
1644@file{setup.py} files can use to run tests.")
54cd239b
EF
1645 (license license:expat)
1646 (properties `((python2-variant . ,(delay python2-pytest-runner))))))
1647
1648(define-public python2-pytest-runner
1649 (let ((base (package-with-python2
1650 (strip-python2-variant python-pytest-runner))))
1651 (package
1652 (inherit base)
1653 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1654 ,@(package-native-inputs base))))))
6784f2e3
RW
1655
1656(define-public python2-pytest-runner
1657 (package-with-python2 python-pytest-runner))
1658
8fa58fc9
CAW
1659(define-public python-pytest-xdist
1660 (package
1661 (name "python-pytest-xdist")
1662 (version "1.14")
1663 (source
1664 (origin
1665 (method url-fetch)
1666 (uri (pypi-uri "pytest-xdist" version ".zip"))
1667 (sha256
1668 (base32
1669 "08rn2l39ds60xshs4js787l84pfckksqklfq2wq9x8ig2aci2pja"))))
1670 (build-system python-build-system)
1671 (native-inputs
1672 `(("unzip" ,unzip)
8fa58fc9 1673 ("python-setuptools-scm" ,python-setuptools-scm)))
fbe9abcc
EF
1674 (inputs
1675 `(("python-apipkg" ,python-apipkg)
1676 ("python-execnet" ,python-execnet)
8fa58fc9
CAW
1677 ("python-pytest" ,python-pytest)
1678 ("python-py" ,python-py)))
1679 (home-page
1680 "https://github.com/pytest-dev/pytest-xdist")
1681 (synopsis
1682 "Plugin for py.test with distributed testing and loop-on-failing modes")
1683 (description
1684 "The pytest-xdist plugin extends py.test with some unique test execution
1685modes: parallelization, running tests in boxed subprocesses, the ability
1686to run tests repeatedly when failed, and the ability to run tests on multiple
1687Python interpreters or platforms. It uses rsync to copy the existing
1688program code to a remote location, executes there, and then syncs the
1689result back.")
fbe9abcc
EF
1690 (license license:expat)
1691 (properties `((python2-variant . ,(delay python2-pytest-xdist))))))
8fa58fc9
CAW
1692
1693(define-public python2-pytest-xdist
fbe9abcc
EF
1694 (let ((base (package-with-python2
1695 (strip-python2-variant python-pytest-xdist))))
1696 (package
1697 (inherit base)
1698 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1699 ,@(package-native-inputs base))))))
8fa58fc9 1700
84d24017
DT
1701(define-public python-scripttest
1702 (package
1703 (name "python-scripttest")
1704 (version "1.3")
1705 (source
1706 (origin
1707 (method url-fetch)
1708 (uri (string-append
1709 "https://pypi.python.org/packages/source/s/scripttest/scripttest-"
1710 version ".tar.gz"))
1711 (sha256
1712 (base32
1713 "0f4w84k8ck82syys7yg9maz93mqzc8p5ymis941x034v44jzq74m"))))
1714 (build-system python-build-system)
1715 (inputs
1716 `(("python-setuptools" ,python-setuptools)
1717 ("python-pytest" ,python-pytest)))
1718 (home-page "http://pythonpaste.org/scripttest/")
1719 (synopsis "Python library to test command-line scripts")
1720 (description "Scripttest is a Python helper library for testing
1721interactive command-line applications. With it you can run a script in a
1722subprocess and see the output as well as any file modifications.")
bd3fa666 1723 (license license:expat)))
84d24017
DT
1724
1725(define-public python2-scripttest
1726 (package-with-python2 python-scripttest))
1727
d8fa80e1
DT
1728(define-public python-testtools
1729 (package
1730 (name "python-testtools")
1731 (version "1.0.0")
1732 (source
1733 (origin
1734 (method url-fetch)
1735 (uri (string-append
1736 "https://pypi.python.org/packages/source/t/testtools/testtools-"
1737 version ".tar.gz"))
1738 (sha256
1739 (base32
1740 "1dyml28ykpl5jb9khdmcdvhy1cxqingys6qvj2k04fzlaj6z3bbx"))))
1741 (build-system python-build-system)
0e88cbf8
CR
1742 (propagated-inputs
1743 `(("python-mimeparse" ,python-mimeparse)))
d8fa80e1
DT
1744 (inputs
1745 `(("python-setuptools" ,python-setuptools)
d8fa80e1
DT
1746 ("python-extras" ,python-extras)))
1747 (home-page "https://github.com/testing-cabal/testtools")
1748 (synopsis
1749 "Extensions to the Python standard library unit testing framework")
1750 (description
1751 "Testtools extends the Python standard library unit testing framework to
1752provide matchers, more debugging information, and cross-Python
1753compatibility.")
1754 (license psfl)))
1755
1756(define-public python2-testtools
1757 (package-with-python2 python-testtools))
1758
5bf3afea
DT
1759(define-public python-testscenarios
1760 (package
1761 (name "python-testscenarios")
1762 (version "0.4")
1763 (source
1764 (origin
1765 (method url-fetch)
1766 (uri (string-append
1767 "https://pypi.python.org/packages/source/t/testscenarios/testscenarios-"
1768 version ".tar.gz"))
1769 (sha256
1770 (base32
1771 "1671jvrvqlmbnc42j7pc5y6vc37q44aiwrq0zic652pxyy2fxvjg"))))
1772 (build-system python-build-system)
1773 (inputs
1774 `(("python-setuptools" ,python-setuptools)
1775 ("python-testtools" ,python-testtools)
1776 ("python-mimeparse" ,python-mimeparse)))
1777 (home-page "https://launchpad.net/testscenarios")
1778 (synopsis "Pyunit extension for dependency injection")
1779 (description
1780 "Testscenarios provides clean dependency injection for Python unittest
1781style tests.")
1782 (license (list bsd-3 asl2.0)))) ; at the user's option
1783
1784(define-public python2-testscenarios
1785 (package-with-python2 python-testscenarios))
1786
dac79ecc
DT
1787(define-public python-testresources
1788 (package
1789 (name "python-testresources")
1790 (version "0.2.7")
1791 (source
1792 (origin
1793 (method url-fetch)
1794 (uri (string-append
1795 "https://pypi.python.org/packages/source/t/testresources/testresources-"
1796 version ".tar.gz"))
1797 (sha256
1798 (base32
1799 "0cbj3plbllyz42c4b5xxgwaa7mml54lakslrn4kkhinxhdri22md"))))
1800 (build-system python-build-system)
1801 (inputs
1802 `(("python-setuptools" ,python-setuptools)))
1803 (home-page "https://launchpad.net/testresources")
1804 (synopsis
1805 "Pyunit extension for managing test resources")
1806 (description
1807 "Testresources is an extension to Python's unittest to allow declarative
1808use of resources by test cases.")
1809 (license (list bsd-3 asl2.0)))) ; at the user's option
1810
1811(define-public python2-testresources
1812 (package-with-python2 python-testresources))
1813
070ab058
DT
1814(define-public python-subunit
1815 (package
1816 (name "python-subunit")
1817 (version "0.0.21")
1818 (source
1819 (origin
1820 (method url-fetch)
1821 (uri (string-append
1822 "https://pypi.python.org/packages/source/p/python-subunit/python-subunit-"
1823 version ".tar.gz"))
1824 (sha256
1825 (base32
1826 "1nkw9wfbvizmpajbj3in8ns07g7lwkiv8hip14jjlwk3cacls6jv"))))
1827 (build-system python-build-system)
1828 (inputs
1829 `(("python-setuptools" ,python-setuptools)
1830 ("python-testtools" ,python-testtools)
1831 ("python-mimeparse" ,python-mimeparse)
1832 ("python-testscenarios" ,python-testscenarios)))
1833 (home-page "http://launchpad.net/subunit")
1834 (synopsis "Python implementation of the subunit protocol")
1835 (description
1836 "Python-subunit is a Python implementation of the subunit test streaming
1837protocol.")
1838 (license (list bsd-3 asl2.0)))) ; at the user's option
1839
1840(define-public python2-subunit
1841 (package-with-python2 python-subunit))
1842
7787ef76
CR
1843;; Recent versions of python-fixtures need a recent version of python-pbr,
1844;; which needs a recent version of python-fixtures. To fix this circular
1845;; dependency, we keep old versions of python-fixtures and python-pbr to
1846;; bootstrap the whole thing:
1847;; - python-fixtures-0.3.16 is used to build python-pbr-0.11
1848;; - python-pbr-0.11 is used to build python-fixtures
1849;; - python-fixtures is used to build python-pbr
1850(define-public python-fixtures-0.3.16
cd49454b
DT
1851 (package
1852 (name "python-fixtures")
1853 (version "0.3.16")
1854 (source
1855 (origin
1856 (method url-fetch)
1857 (uri (string-append
1858 "https://pypi.python.org/packages/source/f/fixtures/fixtures-"
1859 version ".tar.gz"))
1860 (sha256
1861 (base32
1862 "0x9r2gwilcig5g54k60bxzg96zabizq1855lrprlb4zckalp9asc"))))
1863 (build-system python-build-system)
1864 (inputs
1865 `(("python-setuptools" ,python-setuptools)))
1866 (arguments
1867 '(#:tests? #f)) ; no setup.py test command
1868 (home-page "https://launchpad.net/python-fixtures")
1869 (synopsis "Python test fixture library")
1870 (description
1871 "Fixtures provides a way to create reusable state, useful when writing
1872Python tests.")
1873 (license (list bsd-3 asl2.0)))) ; at user's option
1874
7787ef76
CR
1875(define-public python2-fixtures-0.3.16
1876 (package-with-python2 python-fixtures-0.3.16))
1877
1878(define-public python-pbr-0.11
1879 (package
1880 (name "python-pbr")
1881 (version "0.11.0")
1882 (source
1883 (origin
1884 (method url-fetch)
1885 (uri (string-append
1886 "https://pypi.python.org/packages/source/p/pbr/pbr-"
1887 version ".tar.gz"))
1888 (sha256
1889 (base32
1890 "0v9gb7gyqf7q9s99l0nnjj9ww9b0jvyqlwm4d56pcyinxydddw6p"))))
1891 (build-system python-build-system)
1892 (arguments
1893 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1894 (inputs
1895 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
1896 ("python-pip" ,python-pip)
1897 ("python-setuptools" ,python-setuptools)))
1898 (home-page "https://launchpad.net/pbr")
1899 (synopsis "Change the default behavior of Python’s setuptools")
1900 (description
1901 "Python Build Reasonableness (PBR) is a library that injects some useful
1902and sensible default behaviors into your setuptools run.")
1903 (license asl2.0)))
1904
1905(define-public python2-pbr-0.11
1906 (package-with-python2 python-pbr-0.11))
1907
1ef09c0c 1908(define-public python-pbr
e25f0174
BW
1909 (package
1910 (name "python-pbr")
1ef09c0c
BW
1911 (version "1.8.1")
1912 (source
e25f0174
BW
1913 (origin
1914 (method url-fetch)
1915 (uri (string-append
1916 "https://pypi.python.org/packages/source/p/pbr/pbr-"
1917 version
1918 ".tar.gz"))
1919 (sha256
1920 (base32
1921 "0jcny36cf3s8ar5r4a575npz080hndnrfs4np1fqhv0ym4k7c4p2"))))
1ef09c0c 1922 (build-system python-build-system)
e25f0174
BW
1923 (arguments
1924 `(#:tests? #f)) ;; Most tests seem to use the Internet.
1925 (propagated-inputs
1926 `(("python-testrepository" ,python-testrepository)
1927 ("git" ,git))) ;; pbr actually uses the "git" binary.
1ef09c0c 1928 (inputs
e25f0174
BW
1929 `(("python-fixtures" ,python-fixtures)
1930 ("python-mimeparse" ,python-mimeparse)
1931 ("python-mock" ,python-mock)
1932 ("python-setuptools" ,python-setuptools)
1933 ("python-six" ,python-six)
1934 ("python-sphinx" ,python-sphinx)
1935 ("python-testrepository" ,python-testrepository)
1936 ("python-testresources" ,python-testresources)
1937 ("python-testscenarios" ,python-testscenarios)
1938 ("python-testtools" ,python-testtools)
1939 ("python-virtualenv" ,python-virtualenv)))
1940 (home-page "https://launchpad.net/pbr")
1941 (synopsis "Change the default behavior of Python’s setuptools")
1942 (description
1943 "Python Build Reasonableness (PBR) is a library that injects some useful
1944and sensible default behaviors into your setuptools run.")
1945 (license asl2.0)))
1ef09c0c
BW
1946
1947(define-public python2-pbr
e25f0174 1948 (package-with-python2 python-pbr))
1ef09c0c 1949
7787ef76
CR
1950(define-public python-fixtures
1951 (package
1952 (name "python-fixtures")
13fcc6df 1953 (version "1.4.0")
7787ef76
CR
1954 (source
1955 (origin
1956 (method url-fetch)
13fcc6df 1957 (uri (pypi-uri "fixtures" version))
7787ef76
CR
1958 (sha256
1959 (base32
13fcc6df 1960 "0djxvdwm8s60dbfn7bhf40x6g818p3b3mlwijm1c3bqg7msn271y"))))
7787ef76
CR
1961 (build-system python-build-system)
1962 (propagated-inputs
1963 `(("python-six" ,python-six)
1964 ("python-pbr-0.11" ,python-pbr-0.11)))
1965 (inputs
1966 `(("python-pip" ,python-pip)
1967 ("python-setuptools" ,python-setuptools)
1968 ;; Tests
1969 ("python-testtools" ,python-testtools)))
1970 (arguments
1971 '(#:tests? #f)) ; no setup.py test command
1972 (home-page "https://launchpad.net/python-fixtures")
1973 (synopsis "Python test fixture library")
1974 (description
1975 "Fixtures provides a way to create reusable state, useful when writing
1976Python tests.")
1977 (license (list bsd-3 asl2.0)))) ; at user's option
1978
cd49454b
DT
1979(define-public python2-fixtures
1980 (package-with-python2 python-fixtures))
1981
b24a0c00
DT
1982(define-public python-testrepository
1983 (package
1984 (name "python-testrepository")
1985 (version "0.0.20")
1986 (source
1987 (origin
1988 (method url-fetch)
1989 (uri (string-append
1990 "https://pypi.python.org/packages/source/t/testrepository/testrepository-"
1991 version ".tar.gz"))
1992 (sha256
1993 (base32
1994 "1ssqb07c277010i6gzzkbdd46gd9mrj0bi0i8vn560n2k2y4j93m"))))
1995 (build-system python-build-system)
05de40c5 1996 (propagated-inputs
7787ef76 1997 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
05de40c5 1998 ("python-testtools" ,python-testtools)))
b24a0c00
DT
1999 (inputs
2000 `(("python-setuptools" ,python-setuptools)
b24a0c00 2001 ("python-subunit" ,python-subunit)
b24a0c00
DT
2002 ("python-mimeparse" ,python-mimeparse)))
2003 (home-page "https://launchpad.net/testrepository")
2004 (synopsis "Database for Python test results")
2005 (description "Testrepository provides a database of test results which can
2006be used as part of a developer's workflow to check things such as what tests
2007have failed since the last commit or what tests are currently failing.")
2008 (license (list bsd-3 asl2.0)))) ; at user's option
2009
2010(define-public python2-testrepository
2011 (package-with-python2 python-testrepository))
2012
243a009a
DT
2013(define-public python-coverage
2014 (package
2015 (name "python-coverage")
82a3c582 2016 (version "4.0.3")
243a009a
DT
2017 (source
2018 (origin
2019 (method url-fetch)
82a3c582 2020 (uri (pypi-uri "coverage" version))
243a009a
DT
2021 (sha256
2022 (base32
82a3c582 2023 "0qjlja8ny4gcfp8abqfwdrvr8qw9kr69lkja0b4cqqbsdmdjgcc5"))))
243a009a
DT
2024 (build-system python-build-system)
2025 (inputs
2026 `(("python-setuptools" ,python-setuptools)))
2027 (home-page "http://nedbatchelder.com/code/coverage")
2028 (synopsis "Code coverage measurement for Python")
2029 (description
2030 "Coverage measures code coverage, typically during test execution. It
2031uses the code analysis tools and tracing hooks provided in the Python standard
2032library to determine which lines are executable, and which have been
2033executed.")
2034 (license bsd-3)))
2035
2036(define-public python2-coverage
2037 (package-with-python2 python-coverage))
2038
041358fb
DT
2039(define-public python-discover
2040 (package
2041 (name "python-discover")
2042 (version "0.4.0")
2043 (source
2044 (origin
2045 (method url-fetch)
2046 (uri (string-append
2047 "https://pypi.python.org/packages/source/d/discover/discover-"
2048 version ".tar.gz"))
2049 (sha256
2050 (base32
2051 "0y8d0zwiqar51kxj8lzmkvwc3b8kazb04gk5zcb4nzg5k68zmhq5"))))
2052 (build-system python-build-system)
2053 (inputs
2054 `(("python-setuptools" ,python-setuptools)))
2055 (home-page "http://pypi.python.org/pypi/discover/")
2056 (synopsis
2057 "Python test discovery for unittest")
2058 (description
2059 "Discover provides test discovery for unittest, a feature that has been
e881752c 2060backported from Python 2.7 for Python 2.4+.")
041358fb
DT
2061 (license bsd-3)))
2062
2063(define-public python2-discover
2064 (package-with-python2 python-discover))
2065
a480bc41
EB
2066(define-public behave
2067 (package
2068 (name "behave")
2069 (version "1.2.4")
2070 (source (origin
2071 (method url-fetch)
2072 (uri (string-append "https://pypi.python.org/packages/source/b/"
2073 name "/" name "-" version ".tar.gz"))
2074 (sha256
2075 (base32
2076 "1v2rfy8xnf0rk7cj4cgr7lam4015d458i7bg0xqs9czfv6njlm14"))))
2077 (build-system python-build-system)
2078 (inputs
2079 `(("python-setuptools" ,python-setuptools)
2080 ("python-six" ,python-six)
a480bc41
EB
2081 ("python-parse" ,python-parse)
2082 ("python-parse-type" ,python-parse-type)))
2083 (arguments `(#:tests? #f)) ;TODO: tests require nose>=1.3 and
2084 ;PyHamcrest>=1.8
2085 (home-page "http://github.com/behave/behave")
2086 (synopsis "Python behavior-driven development")
2087 (description
2088 "Behave is a tool for behavior-driven development in python.
2089Behavior-driven development (or BDD) is an agile software development
2090technique that encourages collaboration between developers, QA and
2091non-technical or business participants in a software project. Behave uses
2092tests written in a natural language style, backed up by Python code.")
2093 (license x11)))
c7303d3c
DT
2094
2095(define-public python-exif-read
2096 (package
2097 (name "python-exif-read")
2a2d0981 2098 (version "2.1.2")
c7303d3c
DT
2099 (source (origin
2100 (method url-fetch)
2a2d0981 2101 (uri (pypi-uri "ExifRead" version))
c7303d3c
DT
2102 (sha256
2103 (base32
2a2d0981 2104 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
c7303d3c
DT
2105 (build-system python-build-system)
2106 (inputs
2107 `(("python-setuptools" ,python-setuptools)))
2108 (arguments `(#:tests? #f)) ; no tests
2109 (home-page "https://github.com/ianare/exif-py")
2110 (synopsis "Python library to extract EXIF data from image files")
2111 (description
2112 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
2113files.")
2114 (license bsd-3)))
2115
2116(define-public python2-exif-read
2117 (package-with-python2 python-exif-read))
d5f89b22
DT
2118
2119(define-public python-pyld
2120 (package
2121 (name "python-pyld")
af1ab773 2122 (version "0.6.8")
d5f89b22
DT
2123 (source (origin
2124 (method url-fetch)
af1ab773 2125 (uri (pypi-uri "PyLD" version))
d5f89b22
DT
2126 (sha256
2127 (base32
af1ab773 2128 "0k881ffazpf8q1z8862g4bb3pzwpnz9whrci2mf311mvn1qbyqad"))))
d5f89b22
DT
2129 (build-system python-build-system)
2130 (inputs
2131 `(("python-setuptools" ,python-setuptools)))
2132 (arguments `(#:tests? #f)) ; no tests
2133 (home-page "http://github.com/digitalbazaar/pyld")
2134 (synopsis "Python implementation of the JSON-LD specification")
2135 (description
2136 "PyLD is an implementation of the JSON-LD specification.")
2137 (license bsd-3)))
2138
2139(define-public python2-pyld
2140 (package-with-python2 python-pyld))
3a1f9a68
DT
2141
2142(define-public python-certifi
2143 (package
2144 (name "python-certifi")
9a41f443 2145 (version "2015.11.20.1")
3a1f9a68
DT
2146 (source (origin
2147 (method url-fetch)
9a41f443 2148 (uri (pypi-uri "certifi" version))
3a1f9a68
DT
2149 (sha256
2150 (base32
9a41f443 2151 "05lgwf9rz1kn465azy2bpb3zmpnsn9gkypbhnjlclchv98ssgc1h"))))
3a1f9a68
DT
2152 (build-system python-build-system)
2153 (inputs
2154 `(("python-setuptools" ,python-setuptools)))
2155 (arguments `(#:tests? #f)) ; no tests
2156 (home-page "http://python-requests.org/")
2157 (synopsis "Python CA certificate bundle")
2158 (description
2159 "Certifi is a Python library that contains a CA certificate bundle, which
2160is used by the Requests library to verify HTTPS requests.")
2161 (license asl2.0)))
2162
2163(define-public python2-certifi
2164 (package-with-python2 python-certifi))
e6cfbd36 2165
12c270dd
RW
2166(define-public python-click
2167 (package
2168 (name "python-click")
43accb58 2169 (version "6.6")
12c270dd
RW
2170 (source
2171 (origin
2172 (method url-fetch)
43accb58
LF
2173 (uri (string-append
2174 "https://pypi.python.org/packages/"
2175 "7a/00/c14926d8232b36b08218067bcd5853caefb4737cda3f0a47437151344792/"
2176 "click-" version ".tar.gz"))
12c270dd 2177 (sha256
43accb58
LF
2178 (base32
2179 "1sggipyz52crrybwbr9xvwxd4aqigvplf53k9w3ygxmzivd1jsnc"))))
12c270dd
RW
2180 (build-system python-build-system)
2181 (native-inputs
2182 `(("python-setuptools" ,python-setuptools)))
2183 (home-page "http://click.pocoo.org")
2184 (synopsis "Command line library for Python")
2185 (description
2186 "Click is a Python package for creating command line interfaces in a
2187composable way with as little code as necessary. Its name stands for
2188\"Command Line Interface Creation Kit\". It's highly configurable but comes
2189with sensible defaults out of the box.")
2190 (license bsd-3)))
2191
2192(define-public python2-click
2193 (package-with-python2 python-click))
2194
addc808d
EF
2195(define-public python-wheel
2196 (package
2197 (name "python-wheel")
40981b5c 2198 (version "0.29.0")
e1ba0749
EF
2199 (source
2200 (origin
2201 (method url-fetch)
2202 (uri (pypi-uri "wheel" version))
2203 (sha256
2204 (base32
40981b5c 2205 "0j0n38hg1jvrmyy68f9ikvzq1gs9g0sx4ws7maf8wi3bwbbqmfqy"))))
e1ba0749
EF
2206 (build-system python-build-system)
2207 (native-inputs
2208 `(("python-setuptools" ,python-setuptools)
2209 ("python-jsonschema" ,python-jsonschema)
2210 ("python-pytest-cov" ,python-pytest-cov)))
2211 (home-page "https://bitbucket.org/pypa/wheel/")
2212 (synopsis "Format for built Python packages")
2213 (description
2214 "A wheel is a ZIP-format archive with a specially formatted filename and
2215the @code{.whl} extension. It is designed to contain all the files for a PEP
2216376 compatible install in a way that is very close to the on-disk format. Many
2217packages will be properly installed with only the @code{Unpack} step and the
2218unpacked archive preserves enough information to @code{Spread} (copy data and
2219scripts to their final locations) at any later time. Wheel files can be
2220installed with a newer @code{pip} or with wheel's own command line utility.")
8ad4ae20
LF
2221 (license license:expat)
2222 (properties `((python2-variant . ,(delay python2-wheel))))))
addc808d
EF
2223
2224(define-public python2-wheel
8ad4ae20
LF
2225 (let ((wheel (package-with-python2
2226 (strip-python2-variant python-wheel))))
264ae686 2227 (package (inherit wheel)
8ad4ae20
LF
2228 (native-inputs `(("python2-functools32" ,python2-functools32)
2229 ,@(package-native-inputs wheel))))))
2230
addc808d 2231
ae641128 2232(define-public python-requests
e6cfbd36 2233 (package
ae641128 2234 (name "python-requests")
74a066f9 2235 (version "2.9.1")
e6cfbd36
DT
2236 (source (origin
2237 (method url-fetch)
5d691657 2238 (uri (pypi-uri "requests" version))
e6cfbd36
DT
2239 (sha256
2240 (base32
74a066f9 2241 "0zsqrzlybf25xscgi7ja4s48y2abf9wvjkn47wh984qgs1fq2xy5"))))
e6cfbd36 2242 (build-system python-build-system)
5d691657 2243 (native-inputs
6a308947
EF
2244 `(("python-setuptools" ,python-setuptools)
2245 ("python-py" ,python-py)
5d691657
EF
2246 ("python-pytest" ,python-pytest)
2247 ("python-pytest-cov" ,python-pytest-cov)
2248 ("python-wheel" ,python-wheel)))
e6cfbd36
DT
2249 (home-page "http://python-requests.org/")
2250 (synopsis "Python HTTP library")
2251 (description
2252 "Requests is a Python HTTP client library. It aims to be easier to use
2253than Python’s urllib2 library.")
2254 (license asl2.0)))
864b5211 2255
e9005180
DT
2256;; Some software requires an older version of Requests, notably Docker
2257;; Compose.
2258(define-public python-requests-2.7
2259 (package (inherit python-requests)
2260 (version "2.7.0")
2261 (source (origin
2262 (method url-fetch)
2263 (uri (pypi-uri "requests" version))
2264 (sha256
2265 (base32
2266 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
2267
ae641128 2268(define-public python2-requests
8ad4ae20 2269 (package-with-python2 python-requests))
ae641128 2270
ea521b42
DT
2271(define-public python-vcversioner
2272 (package
2273 (name "python-vcversioner")
2274 (version "2.14.0.0")
2275 (source
2276 (origin
2277 (method url-fetch)
2278 (uri (pypi-uri "vcversioner" version))
2279 (sha256
2280 (base32
2281 "11ivq1bm7v0yb4nsfbv9m7g7lyjn112gbvpjnjz8nv1fx633dm5c"))))
2282 (build-system python-build-system)
2283 (inputs
2284 `(("python-setuptools" ,python-setuptools)))
2285 (synopsis "Python library for version number discovery")
2286 (description "Vcversioner is a Python library that inspects tagging
2287information in a variety of version control systems in order to discover
2288version numbers.")
2289 (home-page "https://github.com/habnabit/vcversioner")
2290 (license isc)))
2291
2292(define-public python2-vcversioner
2293 (package-with-python2 python-vcversioner))
ae641128 2294
864b5211
DT
2295(define-public python-jsonschema
2296 (package
2297 (name "python-jsonschema")
b3667afb 2298 (version "2.5.1")
864b5211
DT
2299 (source (origin
2300 (method url-fetch)
2301 (uri
2302 (string-append
2303 "https://pypi.python.org/packages/source/j/jsonschema/jsonschema-"
2304 version ".tar.gz"))
2305 (sha256
2306 (base32
b3667afb 2307 "0hddbqjm4jq63y8jf44nswina1crjs16l9snb6m3vvgyg31klrrn"))))
864b5211
DT
2308 (build-system python-build-system)
2309 (inputs
b3667afb
DT
2310 `(("python-setuptools" ,python-setuptools)
2311 ("python-vcversioner" ,python-vcversioner)))
864b5211
DT
2312 (home-page "http://github.com/Julian/jsonschema")
2313 (synopsis "Implementation of JSON Schema for Python")
2314 (description
2315 "Jsonschema is an implementation of JSON Schema for Python.")
a14600ec
LF
2316 (license license:expat)
2317 (properties `((python2-variant . ,(delay python2-jsonschema))))))
864b5211
DT
2318
2319(define-public python2-jsonschema
a14600ec
LF
2320 (let ((jsonschema (package-with-python2
2321 (strip-python2-variant python-jsonschema))))
264ae686
EF
2322 (package (inherit jsonschema)
2323 (inputs
2324 `(("python2-functools32" ,python2-functools32)
2325 ,@(package-inputs jsonschema))))))
850189b8
DT
2326
2327(define-public python-unidecode
2328 (package
2329 (name "python-unidecode")
8925d4f3 2330 (version "0.04.18")
850189b8
DT
2331 (source (origin
2332 (method url-fetch)
8925d4f3 2333 (uri (pypi-uri "Unidecode" version))
850189b8
DT
2334 (sha256
2335 (base32
8925d4f3 2336 "12hhblqy1ajvidm38im4171x4arg83pfmziyn53nizp29p3m14gi"))))
850189b8
DT
2337 (build-system python-build-system)
2338 (inputs
2339 `(("python-setuptools" ,python-setuptools)))
2340 (home-page "https://pypi.python.org/pypi/Unidecode")
2341 (synopsis "ASCII transliterations of Unicode text")
2342 (description
2343 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2344useful when integrating with legacy code that doesn't support Unicode, or for
2345ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2346machine identifiers from human-readable Unicode strings that should still be
2347somewhat intelligeble.")
2348 (license gpl2+)))
2349
2350(define-public python2-unidecode
2351 (package-with-python2 python-unidecode))
6d45fef4
DT
2352
2353(define-public python-pyjwt
2354 (package
2355 (name "python-pyjwt")
eb31d4b4 2356 (version "1.4.0")
6d45fef4
DT
2357 (source
2358 (origin
2359 (method url-fetch)
eb31d4b4 2360 (uri (pypi-uri "PyJWT" version))
6d45fef4
DT
2361 (sha256
2362 (base32
eb31d4b4 2363 "1556v2jppd8mjkkj66pxb5rcazm35jq81r233mdl8hfmz9n3icp1"))))
6d45fef4 2364 (build-system python-build-system)
eb31d4b4
EF
2365 (native-inputs
2366 `(("python-setuptools" ,python-setuptools)
2367 ("python-pytest-runner" ,python-pytest-runner)))
6d45fef4
DT
2368 (arguments
2369 '(#:tests? #f)) ; test suite doesn't work
2370 (home-page "http://github.com/progrium/pyjwt")
2371 (synopsis "JSON Web Token implementation in Python")
2372 (description
2373 "PyJWT is a JSON Web Token implementation written in Python.")
bd3fa666 2374 (license license:expat)))
6d45fef4
DT
2375
2376(define-public python2-pyjwt
2377 (package-with-python2 python-pyjwt))
2378
2cec1f6f
DT
2379(define-public python-oauthlib
2380 (package
2381 (name "python-oauthlib")
bde2171d 2382 (version "1.0.3")
2cec1f6f
DT
2383 (source (origin
2384 (method url-fetch)
bde2171d 2385 (uri (pypi-uri "oauthlib" version))
2cec1f6f
DT
2386 (sha256
2387 (base32
bde2171d 2388 "1bfrj70vdjxjw74khbyh6f0dksv7p5rh2346jnlrffyacd3gwjzg"))))
2cec1f6f 2389 (build-system python-build-system)
bde2171d 2390 (native-inputs
59f151ec 2391 `(("python-coverage" ,python-coverage)
2cec1f6f
DT
2392 ("python-nose" ,python-nose)
2393 ("python-mock" ,python-mock)))
bde2171d
EF
2394 (inputs
2395 `(("python-blinker" ,python-blinker)
2396 ("python-cryptography" ,python-cryptography)
2397 ("python-pyjwt" ,python-pyjwt)))
2cec1f6f
DT
2398 (home-page "https://github.com/idan/oauthlib")
2399 (synopsis "OAuth implementation for Python")
2400 (description
2401 "Oauthlib is a generic, spec-compliant, thorough implementation of the
2402OAuth request-signing logic.")
59f151ec
EF
2403 (license bsd-3)
2404 (properties `((python2-variant . ,(delay python2-oauthlib))))))
2cec1f6f
DT
2405
2406(define-public python2-oauthlib
59f151ec 2407 (let ((base (package-with-python2 (strip-python2-variant python-oauthlib))))
2cec1f6f
DT
2408 (package
2409 (inherit base)
59f151ec
EF
2410 (native-inputs `(("python2-setuptools" ,python2-setuptools)
2411 ("python2-unittest2" ,python2-unittest2)
2412 ,@(package-native-inputs base))))))
ec5dbb5c
DT
2413
2414(define-public python-itsdangerous
2415 (package
2416 (name "python-itsdangerous")
2417 (version "0.24")
2418 (source
2419 (origin
2420 (method url-fetch)
2421 (uri (string-append
2422 "https://pypi.python.org/packages/source/i/itsdangerous/itsdangerous-"
2423 version ".tar.gz"))
2424 (sha256
2425 (base32
2426 "06856q6x675ly542ig0plbqcyab6ksfzijlyf1hzhgg3sgwgrcyb"))))
2427 (build-system python-build-system)
ec5dbb5c
DT
2428 (home-page "http://github.com/mitsuhiko/itsdangerous")
2429 (synopsis "Python library for passing data to/from untrusted environments")
2430 (description
2431 "Itsdangerous provides various helpers to pass trusted data to untrusted
2432environments and back.")
194d0d98
EF
2433 (license bsd-3)
2434 (properties `((python2-variant . ,(delay python2-itsdangerous))))))
ec5dbb5c
DT
2435
2436(define-public python2-itsdangerous
194d0d98
EF
2437 (let ((base (package-with-python2
2438 (strip-python2-variant python-itsdangerous))))
2439 (package
2440 (inherit base)
2441 (native-inputs `(("python2-setuptools" ,python2-setuptools)
2442 ,@(package-native-inputs base))))))
5731cae3 2443
8d12be1e
RW
2444(define-public python-pyyaml
2445 (package
2446 (name "python-pyyaml")
2447 (version "3.11")
2448 (source
2449 (origin
2450 (method url-fetch)
2451 (uri (string-append
2452 "https://pypi.python.org/packages/source/P/PyYAML/PyYAML-"
2453 version ".tar.gz"))
2454 (sha256
2455 (base32
2456 "1s26125vfnskng58ym37xhwv8v0mm95b2cwbjfag8prfhy596v63"))))
2457 (build-system python-build-system)
2458 (inputs
2459 `(("libyaml" ,libyaml)))
2460 (native-inputs
2461 `(("python-setuptools" ,python-setuptools)))
2462 (home-page "http://pyyaml.org/wiki/PyYAML")
2463 (synopsis "YAML parser and emitter for Python")
2464 (description
2465 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2466complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2467API, and sensible error messages. PyYAML supports standard YAML tags and
2468provides Python-specific tags that allow to represent an arbitrary Python
2469object.")
2470 (license license:expat)))
2471
2472(define-public python2-pyyaml
2473 (package-with-python2 python-pyyaml))
2474
5731cae3
DT
2475(define-public python-virtualenv
2476 (package
2477 (name "python-virtualenv")
17804240 2478 (version "13.1.2")
5731cae3
DT
2479 (source
2480 (origin
2481 (method url-fetch)
17804240 2482 (uri (pypi-uri "virtualenv" version))
5731cae3
DT
2483 (sha256
2484 (base32
17804240 2485 "1p732accxwqfjbdna39k8w8lp9gyw91vr4kzkhm8mgfxikqqxg5a"))))
5731cae3 2486 (build-system python-build-system)
17804240
EF
2487 (arguments
2488 `(#:phases
2489 (modify-phases %standard-phases
2490 (replace 'check
2491 (lambda _ (zero? (system* "py.test")))))))
5731cae3
DT
2492 (inputs
2493 `(("python-setuptools" ,python-setuptools)
2494 ("python-mock" ,python-mock)
17804240 2495 ("python-pytest" ,python-pytest)))
5731cae3
DT
2496 (home-page "https://virtualenv.pypa.io/")
2497 (synopsis "Virtual Python environment builder")
2498 (description
2499 "Virtualenv is a tool to create isolated Python environments.")
bd3fa666 2500 (license license:expat)))
5731cae3
DT
2501
2502(define-public python2-virtualenv
2503 (package-with-python2 python-virtualenv))
8176d4d5
DT
2504
2505(define-public python-markupsafe
2506 (package
2507 (name "python-markupsafe")
2508 (version "0.23")
2509 (source
2510 (origin
2511 (method url-fetch)
2512 (uri (string-append
2513 "https://pypi.python.org/packages/source/M/MarkupSafe/MarkupSafe-"
2514 version ".tar.gz"))
2515 (sha256
2516 (base32
2517 "1hvip33wva3fnmvfp9x5klqri7hpl1hkgqmjbss18nmrb7zimv54"))))
2518 (build-system python-build-system)
2519 (inputs
2520 `(("python-setuptools" ,python-setuptools)))
2521 (home-page "http://github.com/mitsuhiko/markupsafe")
2522 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2523 (description
2524 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2525for Python.")
2526 (license bsd-3)))
2527
2528(define-public python2-markupsafe
2529 (package-with-python2 python-markupsafe))
fe34f0d1
DT
2530
2531(define-public python-jinja2
2532 (package
2533 (name "python-jinja2")
e98149b3 2534 (version "2.8")
fe34f0d1
DT
2535 (source
2536 (origin
2537 (method url-fetch)
e98149b3 2538 (uri (pypi-uri "Jinja2" version))
fe34f0d1
DT
2539 (sha256
2540 (base32
e98149b3 2541 "1x0v41lp5m1pjix3l46zx02b7lqp2hflgpnxwkywxynvi3zz47xw"))))
fe34f0d1
DT
2542 (build-system python-build-system)
2543 (inputs
2544 `(("python-setuptools" ,python-setuptools)
2545 ("python-markupsafe" ,python-markupsafe)))
2546 (home-page "http://jinja.pocoo.org/")
2547 (synopsis "Python template engine")
2548 (description
2549 "Jinja2 is a small but fast and easy to use stand-alone template engine
2550written in pure Python.")
2551 (license bsd-3)))
2552
2553(define-public python2-jinja2
2554 (package-with-python2 python-jinja2))
3580ab8b 2555
f7d17ac7
EE
2556(define-public python-pystache
2557 (package
2558 (name "python-pystache")
2559 (version "0.5.4")
2560 (source (origin
2561 (method url-fetch)
2562 (uri (pypi-uri "pystache" version))
2563 (sha256
2564 (base32
2565 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2566 (build-system python-build-system)
2567 (native-inputs
2568 `(("python-setuptools" ,python-setuptools)))
2569 (home-page "http://defunkt.io/pystache/")
2570 (synopsis "Python logic-less template engine")
2571 (description
2572 "Pystache is a Python implementation of the framework agnostic,
2573logic-free templating system Mustache.")
2574 (license license:expat)))
2575
2576(define-public python2-pystache
2577 (package-with-python2 python-pystache))
2578
1285119b
RW
2579(define-public python-joblib
2580 (package
2581 (name "python-joblib")
2582 (version "0.9.0b4")
2583 (source (origin
2584 (method url-fetch)
2585 (uri (string-append "https://pypi.python.org/packages/source/"
2586 "j/joblib/joblib-" version ".tar.gz"))
2587 (sha256
2588 (base32
2589 "1dvw3f8jgj6h0fxkghbgyclvdzc7l0ig7n0vis70awb5kczb9bs3"))))
2590 (build-system python-build-system)
2591 (native-inputs
2592 `(("python-setuptools" ,python-setuptools)
2593 ("python-nose" ,python-nose)))
2594 (home-page "http://pythonhosted.org/joblib/")
2595 (synopsis "Using Python functions as pipeline jobs")
2596 (description
2597 "Joblib is a set of tools to provide lightweight pipelining in Python.
2598In particular, joblib offers: transparent disk-caching of the output values
2599and lazy re-evaluation (memoize pattern), easy simple parallel computing
2600logging and tracing of the execution.")
2601 (license bsd-3)))
2602
2603(define-public python2-joblib
2604 (package-with-python2 python-joblib))
2605
3580ab8b
DT
2606(define-public python-docutils
2607 (package
2608 (name "python-docutils")
2609 (version "0.12")
2610 (source
2611 (origin
2612 (method url-fetch)
2613 (uri (string-append
2614 "https://pypi.python.org/packages/source/d/docutils/docutils-"
2615 version ".tar.gz"))
2616 (sha256
2617 (base32
2618 "1ylnjnw1x4b2y7blr6x35ncdzn69k253kw4cdkv6asdb21w73ny7"))))
2619 (build-system python-build-system)
2620 (inputs
2621 `(("python-setuptools" ,python-setuptools)))
2622 (arguments
2623 '(#:tests? #f)) ; no setup.py test command
2624 (home-page "http://docutils.sourceforge.net/")
2625 (synopsis "Python Documentation Utilities")
2626 (description
2627 "Docutils is a modular system for processing documentation into useful
2628formats, such as HTML, XML, and LaTeX. For input Docutils supports
2629reStructuredText.")
2630 ;; Most of the source code is public domain, but some source files are
2631 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
2632 (license (list public-domain psfl bsd-2 gpl3+))))
2633
2634(define-public python2-docutils
2635 (package-with-python2 python-docutils))
fb35b7c0
DT
2636
2637(define-public python-pygments
2638 (package
2639 (name "python-pygments")
9f442285 2640 (version "2.0.2")
fb35b7c0
DT
2641 (source
2642 (origin
2643 (method url-fetch)
9f442285 2644 (uri (pypi-uri "Pygments" version))
fb35b7c0
DT
2645 (sha256
2646 (base32
9f442285 2647 "0lagrwifsgn0s8bzqahpr87p7gd38xja8f06akscinp6hj89283k"))))
fb35b7c0
DT
2648 (build-system python-build-system)
2649 (inputs
2650 `(("python-setuptools" ,python-setuptools)))
2651 (home-page "http://pygments.org/")
2652 (synopsis "Syntax highlighting")
2653 (description
2654 "Pygments is a syntax highlighting package written in Python.")
2655 (license bsd-2)))
2656
2657(define-public python2-pygments
2658 (package-with-python2 python-pygments))
9dd6078d
DT
2659
2660(define-public python-sphinx
2661 (package
2662 (name "python-sphinx")
2663 (version "1.2.3")
2664 (source
2665 (origin
2666 (method url-fetch)
2667 (uri (string-append
2668 "https://pypi.python.org/packages/source/S/Sphinx/Sphinx-"
2669 version ".tar.gz"))
2670 (sha256
2671 (base32
2672 "011xizm3jnmf4cvs5i6kgf6c5nn046h79i8j0vd0f27yw9j3p4wl"))))
2673 (build-system python-build-system)
2674 (inputs
2675 `(("python-setuptools" ,python-setuptools)
2676 ("python-jinja2" ,python-jinja2)
2677 ("python-docutils" ,python-docutils)
2678 ("python-pygments" ,python-pygments)))
2679 (home-page "http://sphinx-doc.org/")
2680 (synopsis "Python documentation generator")
2681 (description "Sphinx is a tool that makes it easy to create documentation
2682for Python projects or other documents consisting of multiple reStructuredText
2683sources.")
2684 (license bsd-3)))
2685
2686(define-public python2-sphinx
2687 (package-with-python2 python-sphinx))
6888830b 2688
ad320b20
RW
2689(define-public python-sphinx-rtd-theme
2690 (package
2691 (name "python-sphinx-rtd-theme")
2692 (version "0.1.6")
2693 (source
2694 (origin
2695 (method url-fetch)
2696 (uri (string-append "https://pypi.python.org/packages/source/s/"
2697 "sphinx_rtd_theme/sphinx_rtd_theme-"
2698 version ".tar.gz"))
2699 (sha256
2700 (base32
2701 "19nw3rn7awplcdrz63kg1njqwkbymfg9lwn7l2grhdyhyr2gaa8g"))))
2702 (build-system python-build-system)
2703 (arguments
2704 `(;; With standard flags, the install phase attempts to create a zip'd
2705 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2706 ;; before 1980'
2707 #:configure-flags '("--single-version-externally-managed"
2708 "--record=sphinx-rtd-theme.txt")))
2709 (native-inputs
2710 `(("python-setuptools" ,python-setuptools)))
2711 (inputs
2712 `(("python-docutils" ,python-docutils)
2713 ("python-sphinx" ,python-sphinx)))
2714 (home-page "https://github.com/snide/sphinx_rtd_theme/")
2715 (synopsis "ReadTheDocs.org theme for Sphinx")
2716 (description "A theme for Sphinx used by ReadTheDocs.org.")
bd3fa666 2717 (license license:expat)))
ad320b20
RW
2718
2719(define-public python2-sphinx-rtd-theme
2720 (package-with-python2 python-sphinx-rtd-theme))
2721
f4de5b3b
CAW
2722(define-public python-feedgenerator
2723 (package
2724 (name "python-feedgenerator")
f0412aa2 2725 (version "1.8")
f4de5b3b 2726 (source
f4de5b3b 2727 (origin
f0412aa2
EF
2728 (method url-fetch)
2729 (uri (pypi-uri "feedgenerator" version))
f4de5b3b
CAW
2730 (sha256
2731 (base32
f0412aa2 2732 "0mkimp1fpdan4p3882vzcws4l594k71ich4g0wq97jbra7p602n0"))))
f4de5b3b 2733 (build-system python-build-system)
f0412aa2 2734 (native-inputs
f4de5b3b
CAW
2735 `(("python-setuptools" ,python-setuptools)
2736 ("python-pytz" ,python-pytz)
2737 ("python-six" ,python-six)))
f0412aa2 2738 (home-page "https://github.com/getpelican/feedgenerator")
f4de5b3b
CAW
2739 (synopsis
2740 "Standalone version of Django's Atom/RSS feed generator")
2741 (description
2742 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2743which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
2744 (license bsd-3)))
2745
2746(define-public python2-feedgenerator
2747 (package-with-python2 python-feedgenerator))
2748
59ad30e3
CAW
2749(define-public python-blinker
2750 (package
2751 (name "python-blinker")
7fb9ff4d 2752 (version "1.4")
59ad30e3
CAW
2753 (source
2754 (origin
2755 (method url-fetch)
7fb9ff4d 2756 (uri (pypi-uri "blinker" version))
59ad30e3
CAW
2757 (sha256
2758 (base32
7fb9ff4d 2759 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
59ad30e3
CAW
2760 (build-system python-build-system)
2761 (native-inputs
2762 `(("python-setuptools" ,python-setuptools)))
2763 ;; No "test" command supplied to setuptools, so unless there's another way
2764 ;; to run tests, we're skipping them!
2765 (arguments '(#:tests? #f))
2766 (home-page "http://pythonhosted.org/blinker/")
2767 (synopsis "Fast, simple object-to-object and broadcast signaling")
2768 (description
2769 "Blinker provides a fast dispatching system that allows any number of
2770interested parties to subscribe to events, or \"signals\".")
2771 (license license:expat)))
2772
2773(define-public python2-blinker
2774 (package-with-python2 python-blinker))
2775
b8050e71
CAW
2776(define-public pelican
2777 (package
2778 (name "pelican")
11f97c27 2779 (version "3.6.3")
b8050e71
CAW
2780 (source
2781 (origin
2782 (method url-fetch)
11f97c27 2783 (uri (pypi-uri "pelican" version))
b8050e71
CAW
2784 (sha256
2785 (base32
11f97c27 2786 "1hn94rb4q3zmcq16in055xikal4dba5hfx3zznq7warllcgc9f8k"))))
b8050e71 2787 (build-system python-build-system)
d9f2dece 2788 (inputs
b8050e71
CAW
2789 `(("python-feedgenerator" ,python-feedgenerator)
2790 ("python-jinja2" ,python-jinja2)
2791 ("python-pygments" ,python-pygments)
2792 ("python-docutils" ,python-docutils)
2793 ("python-pytz" ,python-pytz)
2794 ("python-blinker" ,python-blinker)
2795 ("python-unidecode" ,python-unidecode)
2796 ("python-six" ,python-six)
2797 ("python-dateutil-2" ,python-dateutil-2)))
2798 (home-page "http://getpelican.com/")
2799 (arguments
2800 `(;; XXX Requires a lot more packages to do unit tests :P
2801 #:tests? #f
2802 #:phases (modify-phases %standard-phases
2803 (add-before
2804 'install 'adjust-requires
2805 ;; Since feedgenerator is installed from git, it doesn't
2806 ;; conform to the version requirements.
2807 ;;
2808 ;; We *do have* "feedgenerator >= 1.6", but strip off the
2809 ;; version requirement so setuptools doesn't get confused.
2810 (lambda _
2811 (substitute* "setup.py"
2812 (("['\"]feedgenerator.*?['\"]")
2813 "'feedgenerator'")))))))
2814 (synopsis "Python-based static site publishing system")
2815 (description
2816 "Pelican is a tool to generate a static blog from reStructuredText,
2817Markdown input files, and more. Pelican uses Jinja2 for templating
2818and is very extensible.")
2819 (license agpl3+)))
2820
240ca4aa
RW
2821(define-public python-scikit-learn
2822 (package
2823 (name "python-scikit-learn")
be0a4c26 2824 (version "0.16.1")
240ca4aa
RW
2825 (source
2826 (origin
2827 (method url-fetch)
2828 (uri (string-append
2829 "https://github.com/scikit-learn/scikit-learn/archive/"
2830 version ".tar.gz"))
2831 (sha256
2832 (base32
be0a4c26 2833 "140skabifgc7lvvj873pnzlwx0ni6q8qkrsyad2ccjb3h8rxzkih"))))
240ca4aa
RW
2834 (build-system python-build-system)
2835 (arguments
2836 `(#:phases
2837 (alist-cons-before
2f6b3d2e
RW
2838 'check 'set-HOME
2839 ;; some tests require access to "$HOME"
2840 (lambda _ (setenv "HOME" "/tmp"))
2841 ;; Tests can only be run after the library has been installed and not
2842 ;; within the source directory.
2843 (alist-cons-after
2844 'install 'check
2845 (lambda _
2846 (with-directory-excursion "/tmp"
2847 ;; With Python 3 one test of 3334 fails
2848 ;; (sklearn.tests.test_common.test_transformers); see
2849 ;; https://github.com/scikit-learn/scikit-learn/issues/3693
2850 (system* "nosetests" "-v" "sklearn")))
2851 (alist-delete 'check %standard-phases)))))
240ca4aa 2852 (inputs
2f6b3d2e 2853 `(("openblas" ,openblas)
240ca4aa
RW
2854 ("python-nose" ,python-nose)))
2855 (propagated-inputs
2856 `(("python-numpy" ,python-numpy)
2857 ("python-scipy" ,python-scipy)))
2858 (home-page "http://scikit-learn.org/")
2859 (synopsis "Machine Learning in Python")
2860 (description
2861 "Scikit-learn provides simple and efficient tools for data
2862mining and data analysis.")
2863 (license bsd-3)))
2864
2865(define-public python2-scikit-learn
2866 (let ((scikit (package-with-python2 python-scikit-learn)))
2867 (package (inherit scikit)
2868 (propagated-inputs
2869 `(("python2-numpy" ,python2-numpy)
2870 ("python2-scipy" ,python2-scipy)
2871 ,@(alist-delete
2872 "python-numpy"
2873 (alist-delete
2874 "python-scipy" (package-propagated-inputs scikit))))))))
2875
12f8f9bb
RW
2876(define-public python-scikit-image
2877 (package
2878 (name "python-scikit-image")
2879 (version "0.11.3")
2880 (source
2881 (origin
2882 (method url-fetch)
2883 (uri (string-append
2884 "https://pypi.python.org/packages/source/s/scikit-image/scikit-image-"
2885 version ".tar.gz"))
2886 (sha256
2887 (base32 "0jz416fqvpahqyffw8plmszzfj669w8wvf3y9clnr5lr6a7md3kn"))))
2888 (build-system python-build-system)
2889 (propagated-inputs
2890 `(("python-matplotlib" ,python-matplotlib)
2891 ("python-networkx" ,python-networkx)
2892 ("python-numpy" ,python-numpy)
2893 ("python-scipy" ,python-scipy)
2894 ("python-six" ,python-six)
2895 ("python-pillow" ,python-pillow)))
2896 (native-inputs
2897 `(("python-cython" ,python-cython)
2898 ("python-setuptools" ,python-setuptools)))
2899 (home-page "http://scikit-image.org/")
2900 (synopsis "Image processing in Python")
2901 (description
e881752c 2902 "Scikit-image is a collection of algorithms for image processing.")
12f8f9bb
RW
2903 (license bsd-3)))
2904
2905(define-public python2-scikit-image
2906 (let ((scikit-image (package-with-python2 python-scikit-image)))
2907 (package (inherit scikit-image)
2908 (native-inputs
2909 `(("python2-mock" ,python2-mock)
2910 ,@(package-native-inputs scikit-image)))
2911 (propagated-inputs
2912 `(("python2-pytz" ,python2-pytz)
d9bc0bf8
FB
2913 ("python2-matplotlib" ,python2-matplotlib)
2914 ("python2-numpy" ,python2-numpy)
2915 ("python2-scipy" ,python2-scipy)
2916 ,@(fold alist-delete (package-propagated-inputs scikit-image)
2917 '("python-matplotlib" "python-numpy" "python-scipy")))))))
12f8f9bb 2918
5394a6a6
RW
2919(define-public python-redis
2920 (package
2921 (name "python-redis")
2922 (version "2.10.3")
2923 (source
2924 (origin
2925 (method url-fetch)
2926 (uri (string-append
2927 "https://pypi.python.org/packages/source/r/redis/redis-"
2928 version ".tar.gz"))
2929 (sha256
2930 (base32 "1701qjwn4n05q90fdg4bsg96s27xf5s4hsb4gxhv3xk052q3gyx4"))))
2931 (build-system python-build-system)
2932 ;; Tests require a running Redis server
2933 (arguments '(#:tests? #f))
2934 (native-inputs
2935 `(("python-setuptools" ,python-setuptools)
2936 ("python-pytest" ,python-pytest)))
2937 (home-page "https://github.com/andymccurdy/redis-py")
2938 (synopsis "Redis Python client")
2939 (description
2940 "This package provides a Python interface to the Redis key-value store.")
2941 (license license:expat)))
2942
2943(define-public python2-redis
2944 (package-with-python2 python-redis))
2945
748cef5b
RW
2946(define-public python-rq
2947 (package
2948 (name "python-rq")
2949 (version "0.5.2")
2950 (source
2951 (origin
2952 (method url-fetch)
2953 (uri (string-append
2954 "https://pypi.python.org/packages/source/r/rq/rq-"
2955 version ".tar.gz"))
2956 (sha256
2957 (base32 "0b0z5hn8wkfg300hx7816csgv3bcfamlr29fi3yzgqmpqxwj3fix"))))
2958 (build-system python-build-system)
2959 (propagated-inputs
2960 `(("python-click" ,python-click)
2961 ("python-redis" ,python-redis)))
2962 (native-inputs
2963 `(("python-setuptools" ,python-setuptools)))
2964 (home-page "http://python-rq.org/")
2965 (synopsis "Simple job queues for Python")
2966 (description
2967 "RQ (Redis Queue) is a simple Python library for queueing jobs and
2968processing them in the background with workers. It is backed by Redis and it
2969is designed to have a low barrier to entry.")
2970 (license bsd-2)))
2971
2972(define-public python2-rq
2973 (package-with-python2 python-rq))
2974
6888830b
FB
2975(define-public python-cython
2976 (package
2977 (name "python-cython")
435a0462 2978 (version "0.24")
6888830b
FB
2979 (source
2980 (origin
2981 (method url-fetch)
56918e26 2982 (uri (pypi-uri "Cython" version))
6888830b
FB
2983 (sha256
2984 (base32
435a0462 2985 "1wd3q97gia3zhsgcdlvxh26hkrf3m53i6r1l4g0yya119264vr3d"))))
6888830b
FB
2986 (build-system python-build-system)
2987 ;; we need the full python package and not just the python-wrapper
2988 ;; because we need libpython3.3m.so
2989 (inputs
2990 `(("python" ,python)))
2991 (arguments
2992 `(#:phases
2993 (alist-cons-before
2994 'check 'set-HOME
2995 ;; some tests require access to "$HOME/.cython"
2996 (lambda* _ (setenv "HOME" "/tmp"))
2997 (alist-replace
2998 'check
2999 (lambda _ (zero? (system* "python" "runtests.py" "-vv")))
3000 %standard-phases))))
3001 (home-page "http://cython.org/")
3002 (synopsis "C extensions for Python")
3003 (description "Cython is an optimising static compiler for both the Python
3004programming language and the extended Cython programming language. It makes
3005writing C extensions for Python as easy as Python itself.")
48b311b1
LC
3006 (license asl2.0)
3007 (properties `((python2-variant . ,(delay python2-cython))))))
6888830b
FB
3008
3009(define-public python2-cython
48b311b1
LC
3010 (package (inherit (package-with-python2
3011 (strip-python2-variant python-cython)))
6888830b
FB
3012 (name "python2-cython")
3013 (inputs
3014 `(("python-2" ,python-2))))) ; this is not automatically changed
0da98533
FB
3015
3016;; This version of numpy is missing the documentation and is only used to
3017;; build matplotlib which is required to build numpy's documentation.
3018(define python-numpy-bootstrap
3019 (package
3020 (name "python-numpy-bootstrap")
ef9b4c04 3021 (version "1.10.4")
0da98533
FB
3022 (source
3023 (origin
3024 (method url-fetch)
3025 (uri (string-append "mirror://sourceforge/numpy"
3026 "/numpy-" version ".tar.gz"))
3027 (sha256
3028 (base32
ef9b4c04 3029 "1bjjhvncraka5s6i4lg644jrxij6bvycxy7an20gcz3a0m11iygp"))))
0da98533
FB
3030 (build-system python-build-system)
3031 (inputs
3032 `(("python-nose" ,python-nose)
cba256f8
RW
3033 ("openblas" ,openblas)
3034 ("lapack" ,lapack)))
0da98533 3035 (native-inputs
19afbea1 3036 `(("gfortran" ,gfortran)))
0da98533
FB
3037 (arguments
3038 `(#:phases
3039 (alist-cons-before
3040 'build 'set-environment-variables
3041 (lambda* (#:key inputs #:allow-other-keys)
dbdfe515
RW
3042 (call-with-output-file "site.cfg"
3043 (lambda (port)
cba256f8
RW
3044 (format port
3045 "[openblas]
dbdfe515
RW
3046libraries = openblas
3047library_dirs = ~a/lib
3048include_dirs = ~a/include
cba256f8
RW
3049
3050[lapack]
3051lapack_libs = lapack
3052library_dirs = ~a/lib
3053include_dirs = ~a/include
3054"
3055 (assoc-ref inputs "openblas")
3056 (assoc-ref inputs "openblas")
3057 (assoc-ref inputs "lapack")
3058 (assoc-ref inputs "lapack"))))
dbdfe515
RW
3059 ;; Use "gcc" executable, not "cc".
3060 (substitute* "numpy/distutils/system_info.py"
3061 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
3062 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3063 #t)
6a843168
FB
3064 ;; Tests can only be run after the library has been installed and not
3065 ;; within the source directory.
3066 (alist-cons-after
3067 'install 'check
89b5c60e 3068 (lambda _
6a843168 3069 (with-directory-excursion "/tmp"
89b5c60e 3070 (zero? (system* "python" "-c"
6a843168 3071 "import numpy; numpy.test(verbose=2)"))))
89b5c60e
AE
3072 (alist-delete
3073 'check
6a843168 3074 %standard-phases)))))
0da98533
FB
3075 (home-page "http://www.numpy.org/")
3076 (synopsis "Fundamental package for scientific computing with Python")
3077 (description "NumPy is the fundamental package for scientific computing
e881752c 3078with Python. It contains among other things: a powerful N-dimensional array
0da98533
FB
3079object, sophisticated (broadcasting) functions, tools for integrating C/C++
3080and Fortran code, useful linear algebra, Fourier transform, and random number
3081capabilities.")
3082 (license bsd-3)))
3083
3084(define python2-numpy-bootstrap
3085 (package-with-python2 python-numpy-bootstrap))
15bfe6d6 3086
3a1bfe18
RW
3087(define-public python2-fastlmm
3088 (package
3089 (name "python2-fastlmm")
b074e7d4 3090 (version "0.2.21")
3a1bfe18
RW
3091 (source
3092 (origin
3093 (method url-fetch)
b074e7d4 3094 (uri (pypi-uri "fastlmm" version ".zip"))
3a1bfe18
RW
3095 (sha256
3096 (base32
b074e7d4 3097 "1q8c34rpmwkfy3r4d5172pzdkpfryj561897z9r3x22gq7813x1m"))))
3a1bfe18
RW
3098 (build-system python-build-system)
3099 (arguments
3100 `(#:python ,python-2)) ; only Python 2.7 is supported
3101 (propagated-inputs
3102 `(("python2-numpy" ,python2-numpy)
3103 ("python2-scipy" ,python2-scipy)
3104 ("python2-matplotlib" ,python2-matplotlib)
3105 ("python2-pandas" ,python2-pandas)
3106 ("python2-scikit-learn" ,python2-scikit-learn)
3107 ("python2-cython" ,python2-cython)
3108 ("python2-pysnptools" ,python2-pysnptools)))
3109 (native-inputs
3110 `(("unzip" ,unzip)
3111 ("python2-mock" ,python2-mock)
3112 ("python2-setuptools" ,python2-setuptools)))
3113 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/fastlmm/")
3114 (synopsis "Perform genome-wide association studies on large data sets")
3115 (description
3116 "FaST-LMM, which stands for Factored Spectrally Transformed Linear Mixed
3117Models, is a program for performing both single-SNP and SNP-set genome-wide
3118association studies (GWAS) on extremely large data sets.")
3119 (license asl2.0)))
3120
2ee8869a
FB
3121(define-public python-numpy
3122 (package (inherit python-numpy-bootstrap)
3123 (name "python-numpy")
3124 (outputs '("out" "doc"))
89b5c60e 3125 (inputs
2ee8869a
FB
3126 `(("which" ,which)
3127 ("python-setuptools" ,python-setuptools)
3128 ("python-matplotlib" ,python-matplotlib)
3129 ("python-sphinx" ,python-sphinx)
3130 ("python-pyparsing" ,python-pyparsing)
3131 ("python-numpydoc" ,python-numpydoc)
3132 ,@(package-inputs python-numpy-bootstrap)))
3133 (native-inputs
3134 `(("pkg-config" ,pkg-config)
3135 ("texlive" ,texlive)
3136 ("texinfo" ,texinfo)
3137 ("perl" ,perl)
3138 ,@(package-native-inputs python-numpy-bootstrap)))
3139 (arguments
89b5c60e 3140 `(,@(substitute-keyword-arguments
2ee8869a
FB
3141 (package-arguments python-numpy-bootstrap)
3142 ((#:phases phases)
3143 `(alist-cons-after
3144 'install 'install-doc
3145 (lambda* (#:key outputs #:allow-other-keys)
3146 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
89b5c60e
AE
3147 (doc (string-append
3148 data "/doc/" ,name "-"
2ee8869a
FB
3149 ,(package-version python-numpy-bootstrap)))
3150 (info (string-append data "/info"))
3151 (html (string-append doc "/html"))
3152 (pyver ,(string-append "PYVER=")))
3153 (with-directory-excursion "doc"
3154 (mkdir-p html)
3155 (system* "make" "html" pyver)
3156 (system* "make" "latex" "PAPER=a4" pyver)
89b5c60e 3157 (system* "make" "-C" "build/latex"
2ee8869a
FB
3158 "all-pdf" "PAPER=a4" pyver)
3159 ;; FIXME: Generation of the info file fails.
3160 ;; (system* "make" "info" pyver)
3161 ;; (mkdir-p info)
3162 ;; (copy-file "build/texinfo/numpy.info"
3163 ;; (string-append info "/numpy.info"))
3164 (for-each (lambda (file)
3165 (copy-file (string-append "build/latex" file)
3166 (string-append doc file)))
3167 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3168 (with-directory-excursion "build/html"
3169 (for-each (lambda (file)
3170 (let* ((dir (dirname file))
3171 (tgt-dir (string-append html "/" dir)))
3172 (unless (equal? "." dir)
3173 (mkdir-p tgt-dir))
96c46210 3174 (install-file file html)))
2ee8869a
FB
3175 (find-files "." ".*"))))))
3176 ,phases)))))))
3177
764c077b 3178(define-public python2-numpy
57b7b8cd 3179 (package-with-python2 python-numpy))
2ee8869a 3180
15bfe6d6
FB
3181(define-public python-pyparsing
3182 (package
3183 (name "python-pyparsing")
e0669289 3184 (version "2.0.3")
15bfe6d6
FB
3185 (source
3186 (origin
3187 (method url-fetch)
3188 (uri (string-append "mirror://sourceforge/pyparsing"
3189 "/pyparsing-" version ".tar.gz"))
3190 (sha256
3191 (base32
e0669289 3192 "0kw4py7gn45j93q8r7bzajfrjdc3xlsn2yzln41lf9zmrghjkrq6"))))
15bfe6d6
FB
3193 (build-system python-build-system)
3194 (outputs '("out" "doc"))
3195 (arguments
3196 `(#:tests? #f ; no test target
3197 #:modules ((guix build python-build-system)
3198 (guix build utils))
3199 #:phases
3200 (alist-cons-after
3201 'install 'install-doc
3202 (lambda* (#:key outputs #:allow-other-keys)
89b5c60e 3203 (let* ((doc (string-append (assoc-ref outputs "doc")
15bfe6d6
FB
3204 "/share/doc/" ,name "-" ,version))
3205 (html-doc (string-append doc "/html"))
3206 (examples (string-append doc "/examples")))
3207 (mkdir-p html-doc)
3208 (mkdir-p examples)
89b5c60e 3209 (for-each
15bfe6d6 3210 (lambda (dir tgt)
89b5c60e 3211 (map (lambda (file)
96c46210 3212 (install-file file tgt))
15bfe6d6
FB
3213 (find-files dir ".*")))
3214 (list "docs" "htmldoc" "examples")
3215 (list doc html-doc examples))))
3216 %standard-phases)))
3217 (home-page "http://pyparsing.wikispaces.com")
3218 (synopsis "Python parsing class library")
3219 (description
3220 "The pyparsing module is an alternative approach to creating and
3221executing simple grammars, vs. the traditional lex/yacc approach, or the use
3222of regular expressions. The pyparsing module provides a library of classes
3223that client code uses to construct the grammar directly in Python code.")
bd3fa666 3224 (license license:expat)))
15bfe6d6
FB
3225
3226(define-public python2-pyparsing
3227 (package-with-python2 python-pyparsing))
3228
ec00de35
FB
3229(define-public python-numpydoc
3230 (package
3231 (name "python-numpydoc")
3232 (version "0.5")
3233 (source
3234 (origin
3235 (method url-fetch)
89b5c60e 3236 (uri (string-append
ec00de35
FB
3237 "https://pypi.python.org/packages/source/n/numpydoc/numpydoc-"
3238 version ".tar.gz"))
3239 (sha256
3240 (base32
5e4d8f67
AE
3241 "0d4dnifaxkll50jx6czj05y8cb4ny60njd2wz299sj2jxfy51w4k"))
3242 (modules '((guix build utils)))
3243 (snippet
3244 '(begin
3245 ;; Drop a test requiring matplotlib, which we cannot add as an
3246 ;; input since it would create a circular dependency: Extend the
3247 ;; test for Python 3, where it is already dropped, to Python 2.
3248 (substitute* "numpydoc/tests/test_plot_directive.py"
3249 (("3") "2"))))))
ec00de35
FB
3250 (build-system python-build-system)
3251 (inputs
3252 `(("python-setuptools" ,python-setuptools)
3253 ("python-docutils" ,python-docutils)
3254 ("python-sphinx" ,python-sphinx)
3255 ("python-nose" ,python-nose)))
3256 (home-page "https://pypi.python.org/pypi/numpydoc")
3257 (synopsis
3258 "Numpy's Sphinx extensions")
3259 (description
3260 "Sphinx extension to support docstrings in Numpy format.")
3261 (license bsd-2)))
3262
3263(define-public python2-numpydoc
5e4d8f67 3264 (package-with-python2 python-numpydoc))
1c65314c 3265
1e656049
RW
3266(define-public python-numexpr
3267 (package
3268 (name "python-numexpr")
26112c0a 3269 (version "2.6.0")
1e656049
RW
3270 (source
3271 (origin
3272 (method url-fetch)
26112c0a 3273 (uri (pypi-uri "numexpr" version))
1e656049
RW
3274 (sha256
3275 (base32
26112c0a 3276 "0i6iagl2hhbr8q4qzbbjd859v5806vqylq87fq7pi914ps6d6cag"))))
1e656049
RW
3277 (build-system python-build-system)
3278 (arguments `(#:tests? #f)) ; no tests included
3279 (propagated-inputs
3280 `(("python-numpy" ,python-numpy)))
3281 (home-page "https://github.com/pydata/numexpr")
3282 (synopsis "Fast numerical expression evaluator for NumPy")
3283 (description
3284 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3285expressions that operate on arrays are accelerated and use less memory than
3286doing the same calculation in Python. In addition, its multi-threaded
3287capabilities can make use of all your cores, which may accelerate
3288computations, most specially if they are not memory-bounded (e.g. those using
3289transcendental functions).")
3290 (license license:expat)))
3291
3292(define-public python2-numexpr
3293 (let ((numexpr (package-with-python2 python-numexpr)))
3294 (package (inherit numexpr)
3295 ;; Make sure to use special packages for Python 2 instead
3296 ;; of those automatically rewritten by package-with-python2.
3297 (propagated-inputs
3298 `(("python2-numpy" ,python2-numpy)
3299 ,@(alist-delete "python-numpy"
3300 (package-propagated-inputs numexpr)))))))
3301
1c65314c
FB
3302(define-public python-matplotlib
3303 (package
3304 (name "python-matplotlib")
1bbc659f 3305 (version "1.4.3")
1c65314c
FB
3306 (source
3307 (origin
3308 (method url-fetch)
3309 (uri (string-append "mirror://sourceforge/matplotlib"
3310 "/matplotlib-" version ".tar.gz"))
3311 (sha256
3312 (base32
1bbc659f 3313 "1dn05cvd0g984lzhh72wa0z93psgwshbbg93fkab6slx5m3l95av"))
fc1adab1 3314 (patches (search-patches "matplotlib-setupext-tk.patch"))))
1c65314c
FB
3315 (build-system python-build-system)
3316 (outputs '("out" "doc"))
25f9a068
FB
3317 (propagated-inputs ; the following packages are all needed at run time
3318 `(("python-pyparsing" ,python-pyparsing)
3319 ("python-pygobject" ,python-pygobject)
3320 ("gobject-introspection" ,gobject-introspection)
1bbc659f 3321 ("python-tkinter" ,python "tk")
25f9a068
FB
3322 ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated
3323 ;; from 'gtk+') provides the required 'typelib' files used by
3324 ;; 'gobject-introspection'. The location of these files is set with the
3325 ;; help of the environment variable GI_TYPELIB_PATH. At build time this
3326 ;; is done automatically by a 'native-search-path' procedure. However,
3327 ;; at run-time the user must set this variable as follows:
3328 ;;
3329 ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0
25f9a068
FB
3330 ("gtk+" ,gtk+)
3331 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3332 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3333 ;; object. For this reason we need to import both libraries.
3334 ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo
3335 ("python-pycairo" ,python-pycairo)
3336 ("python-cairocffi" ,python-cairocffi)))
1c65314c
FB
3337 (inputs
3338 `(("python-setuptools" ,python-setuptools)
3339 ("python-dateutil" ,python-dateutil-2)
1c65314c
FB
3340 ("python-six" ,python-six)
3341 ("python-pytz" ,python-pytz)
3342 ("python-numpy" ,python-numpy-bootstrap)
3343 ("python-sphinx" ,python-sphinx)
3344 ("python-numpydoc" ,python-numpydoc)
3345 ("python-nose" ,python-nose)
3346 ("python-mock" ,python-mock)
3347 ("libpng" ,libpng)
3348 ("imagemagick" ,imagemagick)
3349 ("freetype" ,freetype)
25f9a068
FB
3350 ("cairo" ,cairo)
3351 ("glib" ,glib)
4e7a137a 3352 ("python-pillow" ,python-pillow)
1c65314c 3353 ;; FIXME: Add backends when available.
1c65314c
FB
3354 ;("python-wxpython" ,python-wxpython)
3355 ;("python-pyqt" ,python-pyqt)
1bbc659f
FB
3356 ("tcl" ,tcl)
3357 ("tk" ,tk)))
1c65314c
FB
3358 (native-inputs
3359 `(("pkg-config" ,pkg-config)
3360 ("texlive" ,texlive)
3361 ("texinfo" ,texinfo)))
3362 (arguments
3363 `(#:phases
25f9a068
FB
3364 (alist-cons-before
3365 'build 'configure-environment
3366 (lambda* (#:key outputs inputs #:allow-other-keys)
3367 (let ((cairo (assoc-ref inputs "cairo"))
3368 (gtk+ (assoc-ref inputs "gtk+")))
3369 ;; Setting these directories in the 'basedirlist' of 'setup.cfg'
3370 ;; has not effect.
25f9a068
FB
3371 (setenv "LD_LIBRARY_PATH"
3372 (string-append cairo "/lib:" gtk+ "/lib"))
3373 (setenv "HOME" (getcwd))
3374 (call-with-output-file "setup.cfg"
3375 (lambda (port)
1bbc659f
FB
3376 (format port "[directories]~%
3377basedirlist = ~a,~a~%
57b7b8cd 3378 [rc_options]~%
1bbc659f
FB
3379backend = TkAgg~%"
3380 (assoc-ref inputs "tcl")
3381 (assoc-ref inputs "tk"))))))
25f9a068
FB
3382 (alist-cons-after
3383 'install 'install-doc
3384 (lambda* (#:key outputs #:allow-other-keys)
3385 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3386 (doc (string-append data "/doc/" ,name "-" ,version))
3387 (info (string-append data "/info"))
3388 (html (string-append doc "/html")))
3389 (with-directory-excursion "doc"
25f9a068
FB
3390 ;; Produce pdf in 'A4' format.
3391 (substitute* (find-files "." "conf\\.py")
3392 (("latex_paper_size = 'letter'")
3393 "latex_paper_size = 'a4'"))
3394 (mkdir-p html)
3395 (mkdir-p info)
3396 ;; The doc recommends to run the 'html' target twice.
3397 (system* "python" "make.py" "html")
3398 (system* "python" "make.py" "html")
18b31516 3399 (copy-recursively "build/html" html)
25f9a068
FB
3400 (system* "python" "make.py" "latex")
3401 (system* "python" "make.py" "texinfo")
18b31516
FB
3402 (symlink (string-append html "/_images")
3403 (string-append info "/matplotlib-figures"))
3404 (with-directory-excursion "build/texinfo"
3405 (substitute* "matplotlib.texi"
3406 (("@image\\{([^,]*)" all file)
3407 (string-append "@image{matplotlib-figures/" file)))
3408 (symlink (string-append html "/_images")
3409 "./matplotlib-figures")
3410 (system* "makeinfo" "--no-split"
3411 "-o" "matplotlib.info" "matplotlib.texi"))
25f9a068
FB
3412 (copy-file "build/texinfo/matplotlib.info"
3413 (string-append info "/matplotlib.info"))
3414 (copy-file "build/latex/Matplotlib.pdf"
18b31516 3415 (string-append doc "/Matplotlib.pdf")))))
25f9a068 3416 %standard-phases))))
1c65314c
FB
3417 (home-page "http://matplotlib.org")
3418 (synopsis "2D plotting library for Python")
3419 (description
3420 "Matplotlib is a Python 2D plotting library which produces publication
3421quality figures in a variety of hardcopy formats and interactive environments
3422across platforms. Matplotlib can be used in Python scripts, the python and
3423ipython shell, web application servers, and six graphical user interface
3424toolkits.")
57b7b8cd
LC
3425 (license psfl)
3426 (properties `((python2-variant . ,(delay python2-matplotlib))))))
1c65314c 3427
764c077b 3428(define-public python2-matplotlib
57b7b8cd
LC
3429 (let ((matplotlib (package-with-python2
3430 (strip-python2-variant python-matplotlib))))
764c077b 3431 (package (inherit matplotlib)
88c26834
AE
3432 ;; Make sure to use special packages for Python 2 instead
3433 ;; of those automatically rewritten by package-with-python2.
89b5c60e 3434 (propagated-inputs
7ca0dbc3 3435 `(("python2-pycairo" ,python2-pycairo)
764c077b 3436 ("python2-pygobject-2" ,python2-pygobject-2)
1bbc659f
FB
3437 ("python2-tkinter" ,python-2 "tk")
3438 ,@(fold alist-delete (package-propagated-inputs matplotlib)
3439 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
94914805 3440
0dde6232
RW
3441(define-public python2-pysnptools
3442 (package
3443 (name "python2-pysnptools")
a800018e 3444 (version "0.3.9")
0dde6232
RW
3445 (source
3446 (origin
3447 (method url-fetch)
3f2e9675 3448 (uri (pypi-uri "pysnptools" version ".zip"))
0dde6232
RW
3449 (sha256
3450 (base32
a800018e 3451 "1wybggjzz8zw7aav4pjsg2h22xp17a1lghrprza1pxwlm7wf96y2"))))
0dde6232
RW
3452 (build-system python-build-system)
3453 (arguments
3454 `(#:python ,python-2)) ; only Python 2.7 is supported
3455 (propagated-inputs
3456 `(("python2-numpy" ,python2-numpy)
3457 ("python2-scipy" ,python2-scipy)
a800018e 3458 ("python2-pytz" ,python2-pytz)
0dde6232 3459 ("python2-cython" ,python2-cython)))
a800018e
EF
3460 (inputs
3461 `(("python2-dateutil-2" ,python2-dateutil-2)
3462 ("python2-pandas" ,python2-pandas)
3463 ("python2-six" ,python2-six)))
0dde6232
RW
3464 (native-inputs
3465 `(("unzip" ,unzip)
3466 ("python2-setuptools" ,python2-setuptools)))
3467 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/")
3468 (synopsis "Library for reading and manipulating genetic data")
3469 (description
3470 "PySnpTools is a library for reading and manipulating genetic data. It
3471can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
3472those files. It can also efficiently manipulate ranges of integers using set
3473operators such as union, intersection, and difference.")
3474 (license asl2.0)))
3475
c9b1b4f9
RW
3476(define-public python-rpy2
3477 (package
3478 (name "python-rpy2")
ec3bcbc7 3479 (version "2.7.6")
c9b1b4f9
RW
3480 (source
3481 (origin
3482 (method url-fetch)
ec3bcbc7 3483 (uri (pypi-uri "rpy2" version))
c9b1b4f9
RW
3484 (sha256
3485 (base32
ec3bcbc7 3486 "0nhan2qvrw7b7gg5zddwa22kybdv3x1g26vkd7q8lvnkgzrs4dga"))))
c9b1b4f9
RW
3487 (build-system python-build-system)
3488 (inputs
3489 `(("python-six" ,python-six)
3490 ("readline" ,readline)
3491 ("icu4c" ,icu4c)
3492 ("pcre" ,pcre)
3493 ("r" ,r)))
3494 (native-inputs
5ff6575b
RW
3495 `(("python-setuptools" ,python-setuptools)
3496 ("zlib" ,zlib)))
c9b1b4f9
RW
3497 (home-page "http://rpy.sourceforge.net/")
3498 (synopsis "Python interface to the R language")
3499 (description "rpy2 is a redesign and rewrite of rpy. It is providing a
3500low-level interface to R from Python, a proposed high-level interface,
3501including wrappers to graphical libraries, as well as R-like structures and
3502functions.")
3503 (license gpl3+)))
3504
3505(define-public python2-rpy2
3506 (let ((rpy2 (package-with-python2 python-rpy2)))
3507 (package (inherit rpy2)
3508 (native-inputs
3509 `(("python2-singledispatch" ,python2-singledispatch)
3510 ,@(package-native-inputs rpy2))))))
3511
bb986599
FB
3512(define-public python-scipy
3513 (package
3514 (name "python-scipy")
ba8a0824 3515 (version "0.16.0")
bb986599
FB
3516 (source
3517 (origin
3518 (method url-fetch)
3519 (uri (string-append "mirror://sourceforge/scipy"
da6ce3f1 3520 "/scipy-" version ".tar.xz"))
bb986599
FB
3521 (sha256
3522 (base32
ba8a0824 3523 "0wa0a4skpda3gx7lb12yn19nhbairlyxrvda2lz2bcawk3x5qzz2"))))
bb986599 3524 (build-system python-build-system)
dd86c0d1 3525 (propagated-inputs
bb986599
FB
3526 `(("python-numpy" ,python-numpy)
3527 ("python-matplotlib" ,python-matplotlib)
dd86c0d1
RW
3528 ("python-pyparsing" ,python-pyparsing)))
3529 (inputs
3530 `(("lapack" ,lapack)
719b01c1 3531 ("openblas" ,openblas)))
bb986599 3532 (native-inputs
dd86c0d1
RW
3533 `(("python-nose" ,python-nose)
3534 ("python-sphinx" ,python-sphinx)
5248d49e 3535 ("python-numpydoc" ,python-numpydoc)
dd86c0d1 3536 ("gfortran" ,gfortran)
bb986599
FB
3537 ("texlive" ,texlive)
3538 ("perl" ,perl)))
3539 (outputs '("out" "doc"))
3540 (arguments
3541 `(#:phases
3542 (alist-cons-before
719b01c1 3543 'build 'configure-openblas
bb986599 3544 (lambda* (#:key inputs #:allow-other-keys)
719b01c1
RW
3545 (call-with-output-file "site.cfg"
3546 (lambda (port)
3547 (format port
3548 "[blas]
3549libraries = openblas
3550library_dirs = ~a/lib
3551include_dirs = ~a/include
3552[atlas]
3553library_dirs = ~a/lib
3554atlas_libs = openblas
3555"
3556 (assoc-ref inputs "openblas")
3557 (assoc-ref inputs "openblas")
3558 (assoc-ref inputs "openblas"))))
3559 #t)
bb986599
FB
3560 (alist-cons-after
3561 'install 'install-doc
3562 (lambda* (#:key outputs #:allow-other-keys)
3563 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3564 (doc (string-append data "/doc/" ,name "-" ,version))
3565 (html (string-append doc "/html"))
3566 (pyver ,(string-append "PYVER=")))
3567 (with-directory-excursion "doc"
bb986599
FB
3568 ;; Fix generation of images for mathematical expressions.
3569 (substitute* (find-files "source" "conf\\.py")
3570 (("pngmath_use_preview = True")
3571 "pngmath_use_preview = False"))
3572 (mkdir-p html)
3573 (system* "make" "html" pyver)
3574 (system* "make" "latex" "PAPER=a4" pyver)
3575 (system* "make" "-C" "build/latex" "all-pdf" "PAPER=a4" pyver)
3576 (copy-file "build/latex/scipy-ref.pdf"
3577 (string-append doc "/scipy-ref.pdf"))
3578 (with-directory-excursion "build/html"
3579 (for-each (lambda (file)
3580 (let* ((dir (dirname file))
3581 (tgt-dir (string-append html "/" dir)))
96c46210 3582 (install-file file html)))
bb986599
FB
3583 (find-files "." ".*"))))))
3584 ;; Tests can only be run after the library has been installed and not
3585 ;; within the source directory.
3586 (alist-cons-after
3587 'install 'check
89b5c60e 3588 (lambda _
bb986599
FB
3589 (with-directory-excursion "/tmp"
3590 (zero? (system* "python" "-c" "import scipy; scipy.test()"))))
89b5c60e
AE
3591 (alist-delete
3592 'check
4f9ff21e
RW
3593 (alist-cons-after
3594 'unpack 'fix-tests
3595 (lambda _
3596 (substitute* "scipy/integrate/tests/test_quadpack.py"
3597 (("libm.so") "libm.so.6"))
3598 #t)
3599 %standard-phases)))))))
bb986599
FB
3600 (home-page "http://www.scipy.org/")
3601 (synopsis "The Scipy library provides efficient numerical routines")
3602 (description "The SciPy library is one of the core packages that make up
3603the SciPy stack. It provides many user-friendly and efficient numerical
3604routines such as routines for numerical integration and optimization.")
3605 (license bsd-3)))
3606
764c077b 3607(define-public python2-scipy
57b7b8cd 3608 (package-with-python2 python-scipy))
bb986599 3609
94914805
EB
3610(define-public python-sqlalchemy
3611 (package
3612 (name "python-sqlalchemy")
a4ba286b 3613 (version "1.0.12")
94914805
EB
3614 (source
3615 (origin
3616 (method url-fetch)
3617 (uri (string-append "https://pypi.python.org/packages/source/S/"
3618 "SQLAlchemy/SQLAlchemy-" version ".tar.gz"))
3619 (sha256
3620 (base32
a4ba286b 3621 "1l8qclhd0s90w3pvwhi5mjxdwr5j7gw7cjka2fx6f2vqmq7f4yb6"))))
94914805
EB
3622 (build-system python-build-system)
3623 (native-inputs
3624 `(("python-cython" ,python-cython) ;for c extensions
3625 ("python-pytest" ,python-pytest)
3626 ("python-mock" ,python-mock))) ;for tests
3627 (arguments
3628 `(#:phases (alist-replace
3629 'check
3630 (lambda _ (zero? (system* "py.test")))
3631 %standard-phases)))
3632 (home-page "http://www.sqlalchemy.org")
3633 (synopsis "Database abstraction library")
3634 (description
3635 "SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that
3636gives application developers the full power and flexibility of SQL. It
3637provides a full suite of well known enterprise-level persistence patterns,
3638designed for efficient and high-performing database access, adapted into a
3639simple and Pythonic domain language.")
3640 (license x11)))
3641
3642(define-public python2-sqlalchemy
3643 (package-with-python2 python-sqlalchemy))
c937562e 3644
af5a4602
CAW
3645(define-public python-alembic
3646 (package
3647 (name "python-alembic")
3648 (version "0.8.4")
3649 (source
3650 (origin
3651 (method url-fetch)
3652 (uri (pypi-uri "alembic" version))
3653 (sha256
3654 (base32
3655 "0jk23a852l3ybv7gfz81xzslyrnqnpjds5x15zd234y9rh9gq1w5"))))
3656 (build-system python-build-system)
3657 (native-inputs
3658 `(("python-mock" ,python-mock)
3659 ("python-pytest-cov" ,python-pytest-cov)))
3660 (propagated-inputs
3661 `(("python-sqlalchemy" ,python-sqlalchemy)
3662 ("python-mako" ,python-mako)
3663 ("python-editor" ,python-editor)))
3664 (home-page "http://bitbucket.org/zzzeek/alembic")
3665 (synopsis
3666 "Database migration tool for SQLAlchemy")
3667 (description
3668 "Alembic is a lightweight database migration tool for usage with the
3669SQLAlchemy Database Toolkit for Python.")
3670 (license license:expat)
3671 (properties `((python2-variant . ,(delay python2-alembic))))))
3672
3673(define-public python2-alembic
3674 (let ((alembic (package-with-python2
3675 (strip-python2-variant python-alembic))))
3676 (package
3677 (inherit alembic)
3678 (native-inputs `(("python2-setuptools" ,python2-setuptools)
3679 ,@(package-native-inputs alembic))))))
3680
1671c07c
EB
3681(define-public python-distutils-extra
3682 (package
3683 (name "python-distutils-extra")
3684 (version "2.38")
3685 (source
3686 (origin
3687 (method url-fetch)
3688 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
3689 version "/+download/python-distutils-extra-"
3690 version ".tar.gz"))
3691 (sha256
3692 (base32
3693 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
3694 (build-system python-build-system)
3695 (native-inputs
3696 `(("python-setuptools" ,python-setuptools)))
3697 (home-page "https://launchpad.net/python-distutils-extra/")
3698 (synopsis "Enhancements to Python's distutils")
3699 (description
3700 "The python-distutils-extra module enables you to easily integrate
3701gettext support, themed icons, and scrollkeeper-based documentation into
3702Python's distutils.")
3703 (license gpl2)))
3704
3705(define-public python2-distutils-extra
3706 (package-with-python2 python-distutils-extra))
ea5456c8
EB
3707
3708(define-public python2-elib.intl
3709 (package
3710 (name "python2-elib.intl")
3711 (version "0.0.3")
3712 (source
3713 (origin
3714 ;; This project doesn't tag releases or publish tarballs, so we take
3715 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
3716 (method git-fetch)
3717 (uri (git-reference
3718 (url "https://github.com/dieterv/elib.intl.git")
3719 (commit "d09997cfef")))
3720 (sha256
3721 (base32
3722 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
3723 (build-system python-build-system)
3724 (native-inputs
3725 `(("python2-setuptools" ,python2-setuptools)))
3726 (arguments
3727 ;; incompatible with Python 3 (exception syntax)
3728 `(#:python ,python-2
3729 #:tests? #f
3730 ;; With standard flags, the install phase attempts to create a zip'd
3731 ;; egg file, and fails with an error: 'ZIP does not support timestamps
3732 ;; before 1980'
3733 #:configure-flags '("--single-version-externally-managed"
3734 "--record=elib.txt")))
3735 (home-page "https://github.com/dieterv/elib.intl")
3736 (synopsis "Enhanced internationalization for Python")
3737 (description
3738 "The elib.intl module provides enhanced internationalization (I18N)
3739services for your Python modules and applications.")
3740 (license lgpl3+)))
3741
c937562e
EB
3742(define-public python-pillow
3743 (package
3744 (name "python-pillow")
16095d27 3745 (version "3.1.1")
c937562e
EB
3746 (source
3747 (origin
3748 (method url-fetch)
f1d9231d 3749 (uri (pypi-uri "Pillow" version))
c937562e
EB
3750 (sha256
3751 (base32
16095d27 3752 "1zwzakr5v0skdh0azp5cd6fwzbll5305dsk33k5jk570vv6lqvs8"))))
c937562e
EB
3753 (build-system python-build-system)
3754 (native-inputs
3755 `(("python-setuptools" ,python-setuptools)
3756 ("python-nose" ,python-nose)))
3757 (inputs
5ff408d9
SB
3758 `(("freetype" ,freetype)
3759 ("lcms" ,lcms)
c937562e
EB
3760 ("zlib" ,zlib)
3761 ("libjpeg" ,libjpeg)
3762 ("openjpeg" ,openjpeg)
5ff408d9
SB
3763 ("libtiff" ,libtiff)
3764 ("libwebp" ,libwebp)))
c937562e
EB
3765 (propagated-inputs
3766 `(;; Used at runtime for pkg_resources
3767 ("python-setuptools" ,python-setuptools)))
3768 (arguments
e5358a6b
LC
3769 `(#:phases (modify-phases %standard-phases
3770 (add-before
3771 'install 'disable-egg-compression
3772 (lambda _
3773 ;; Leave the .egg uncompressed since compressing it would
3774 ;; prevent the GC from identifying run-time dependencies.
3775 ;; See <http://bugs.gnu.org/20765>.
3776 (let ((port (open-file "setup.cfg" "a")))
3777 (display "\n[easy_install]\nzip_ok = 0\n"
3778 port)
3779 (close-port port)
3780 #t)))
3781 (add-after
3782 'install 'check-installed
3783 (lambda _
3784 (begin
3785 (setenv "HOME" (getcwd))
3786 (and (zero? (system* "python" "selftest.py"
3787 "--installed"))
3788 (zero? (system* "python" "test-installed.py"))))))
3789 (delete 'check))))
c937562e
EB
3790 (home-page "https://pypi.python.org/pypi/Pillow")
3791 (synopsis "Fork of the Python Imaging Library")
3792 (description
3793 "The Python Imaging Library adds image processing capabilities to your
3794Python interpreter. This library provides extensive file format support, an
3795efficient internal representation, and fairly powerful image processing
3796capabilities. The core image library is designed for fast access to data
3797stored in a few basic pixel formats. It should provide a solid foundation for
3798a general image processing tool.")
3799 (license (x11-style
3800 "http://www.pythonware.com/products/pil/license.htm"
3801 "The PIL Software License"))))
3802
3803(define-public python2-pillow
3804 (package-with-python2 python-pillow))
bb986599 3805
a415f036
FB
3806(define-public python-pycparser
3807 (package
3808 (name "python-pycparser")
38eb6919 3809 (version "2.14")
a415f036
FB
3810 (source
3811 (origin
3812 (method url-fetch)
38eb6919 3813 (uri (pypi-uri "pycparser" version))
a415f036
FB
3814 (sha256
3815 (base32
38eb6919 3816 "0wvzyb6rxsfj3xcnpa4ynbh9qc7rrbk2277d5wqpphmx9akv8nbr"))))
a415f036
FB
3817 (outputs '("out" "doc"))
3818 (build-system python-build-system)
3819 (native-inputs
3820 `(("pkg-config" ,pkg-config)
3821 ("python-setuptools" ,python-setuptools)))
3822 (arguments
89b5c60e 3823 `(#:phases
a415f036
FB
3824 (alist-replace
3825 'check
3826 (lambda _
3827 (with-directory-excursion "tests"
3828 (zero? (system* "python" "all_tests.py"))))
3829 (alist-cons-after
3830 'install 'install-doc
3831 (lambda* (#:key outputs #:allow-other-keys)
3832 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3833 (doc (string-append data "/doc/" ,name "-" ,version))
3834 (examples (string-append doc "/examples")))
3835 (mkdir-p examples)
3836 (for-each (lambda (file)
3837 (copy-file (string-append "." file)
3838 (string-append doc file)))
3839 '("/README.rst" "/CHANGES" "/LICENSE"))
3840 (copy-recursively "examples" examples)))
3841 %standard-phases))))
3842 (home-page "https://github.com/eliben/pycparser")
3843 (synopsis "C parser in Python")
3844 (description
3845 "Pycparser is a complete parser of the C language, written in pure Python
3846using the PLY parsing library. It parses C code into an AST and can serve as
3847a front-end for C compilers or analysis tools.")
3848 (license bsd-3)))
3849
3850(define-public python2-pycparser
3851 (package-with-python2 python-pycparser))
57c3f716
FB
3852
3853(define-public python-cffi
3854 (package
3855 (name "python-cffi")
2d3a437c 3856 (version "1.4.2")
57c3f716
FB
3857 (source
3858 (origin
3859 (method url-fetch)
2d3a437c 3860 (uri (pypi-uri "cffi" version))
89b5c60e 3861 (sha256
2d3a437c 3862 (base32 "161rj52rzi3880lij17d6i9kvgkiwjilrqjs8405k8sf6ryif7cg"))))
57c3f716
FB
3863 (build-system python-build-system)
3864 (outputs '("out" "doc"))
3865 (inputs
3866 `(("libffi" ,libffi)))
3867 (propagated-inputs ; required at run-time
3868 `(("python-pycparser" ,python-pycparser)))
3869 (native-inputs
3870 `(("pkg-config" ,pkg-config)
3871 ("python-sphinx" ,python-sphinx)
4179f952 3872 ("python-pytest" ,python-pytest)
57c3f716
FB
3873 ("python-setuptools" ,python-setuptools)))
3874 (arguments
4179f952 3875 `(#:phases
57c3f716
FB
3876 (alist-cons-after
3877 'install 'install-doc
3878 (lambda* (#:key outputs #:allow-other-keys)
3879 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3880 (doc (string-append data "/doc/" ,name "-" ,version))
3881 (html (string-append doc "/html")))
3882 (with-directory-excursion "doc"
3883 (system* "make" "html")
3884 (mkdir-p html)
3885 (copy-recursively "build/html" html))
3886 (copy-file "LICENSE" (string-append doc "/LICENSE"))))
3887 %standard-phases)))
3888 (home-page "http://cffi.readthedocs.org")
3889 (synopsis "Foreign function interface for Python")
3890 (description
3891 "Foreign Function Interface for Python calling C code.")
bd3fa666 3892 (license license:expat)))
57c3f716
FB
3893
3894(define-public python2-cffi
3895 (package-with-python2 python-cffi))
6fa14469
FB
3896
3897(define-public python-xcffib
3898 (package
3899 (name "python-xcffib")
3900 (version "0.1.9")
3901 (source
3902 (origin
3903 (method url-fetch)
3904 (uri (string-append "https://pypi.python.org/packages/source/x/"
3905 "xcffib/xcffib-" version ".tar.gz"))
3906 (sha256
3907 (base32
3908 "0655hzxv57h1a9ja9kwp0ichbkhf3djw32k33d66xp0q37dq2y81"))))
3909 (build-system python-build-system)
3910 (inputs
3911 `(("libxcb" ,libxcb)
3912 ("python-six" ,python-six)))
3913 (native-inputs
3914 `(("python-setuptools" ,python-setuptools)))
3915 (propagated-inputs
3916 `(("python-cffi" ,python-cffi))) ; used at run time
3917 (arguments
89b5c60e 3918 `(#:phases
6fa14469
FB
3919 (alist-cons-after
3920 'install 'install-doc
3921 (lambda* (#:key outputs #:allow-other-keys)
3922 (let ((doc (string-append (assoc-ref outputs "out") "/share"
3923 "/doc/" ,name "-" ,version)))
3924 (mkdir-p doc)
3925 (copy-file "README.md"
3926 (string-append doc "/README.md"))))
3927 %standard-phases)))
3928 (home-page "https://github.com/tych0/xcffib")
3929 (synopsis "XCB Python bindings")
3930 (description
3931 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
3932support for Python 3 and PyPy. It is based on cffi.")
bd3fa666 3933 (license license:expat)))
6fa14469
FB
3934
3935(define-public python2-xcffib
3936 (package-with-python2 python-xcffib))
3937
9e099723
FB
3938(define-public python-cairocffi
3939 (package
3940 (name "python-cairocffi")
3941 (version "0.6")
3942 (source
3943 (origin
3944 (method url-fetch)
3945 ;; The archive on pypi is missing the 'utils' directory!
3946 (uri (string-append "https://github.com/SimonSapin/cairocffi/archive/v"
3947 version ".tar.gz"))
f586c877 3948 (file-name (string-append name "-" version ".tar.gz"))
9e099723
FB
3949 (sha256
3950 (base32
3951 "03w5p62sp3nqiccx864sbq0jvh7946277jqx3rcc3dch5xwfvv51"))))
3952 (build-system python-build-system)
3953 (outputs '("out" "doc"))
3954 (inputs
3955 `(("gdk-pixbuf" ,gdk-pixbuf)
3956 ("cairo" ,cairo)))
3957 (native-inputs
3958 `(("pkg-config" ,pkg-config)
3959 ("python-sphinx" ,python-sphinx)
3960 ("python-docutils" ,python-docutils)
3961 ("python-setuptools" ,python-setuptools)))
3962 (propagated-inputs
3963 `(("python-xcffib" ,python-xcffib))) ; used at run time
3964 (arguments
89b5c60e 3965 `(#:phases
9e099723
FB
3966 (alist-cons-after
3967 'install 'install-doc
3968 (lambda* (#:key inputs outputs #:allow-other-keys)
3969 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3970 (doc (string-append data "/doc/" ,name "-" ,version))
3971 (html (string-append doc "/html")))
89b5c60e 3972 (setenv "LD_LIBRARY_PATH"
9e099723
FB
3973 (string-append (assoc-ref inputs "cairo") "/lib" ":"
3974 (assoc-ref inputs "gdk-pixbuf") "/lib"))
3975 (setenv "LANG" "en_US.UTF-8")
3976 (mkdir-p html)
3977 (for-each (lambda (file)
3978 (copy-file (string-append "." file)
3979 (string-append doc file)))
3980 '("/README.rst" "/CHANGES" "/LICENSE"))
3981 (system* "python" "setup.py" "build_sphinx")
3982 (copy-recursively "docs/_build/html" html)))
3983 %standard-phases)))
3984 (home-page "https://github.com/SimonSapin/cairocffi")
3985 (synopsis "Python bindings and object-oriented API for Cairo")
3986 (description
3987 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
3988Python bindings and object-oriented API for cairo. Cairo is a 2D vector
3989graphics library with support for multiple backends including image buffers,
3990PNG, PostScript, PDF, and SVG file output.")
3991 (license bsd-3)))
3992
3993(define-public python2-cairocffi
3994 (package-with-python2 python-cairocffi))
3995
3cff95cb
RW
3996(define-public python-decorator
3997 (package
3998 (name "python-decorator")
eb6e2e81 3999 (version "4.0.9")
3cff95cb
RW
4000 (source
4001 (origin
4002 (method url-fetch)
e21338be 4003 (uri (pypi-uri "decorator" version))
3cff95cb 4004 (sha256
eb6e2e81 4005 (base32 "1a5vwhflfd9sh3rfb40xlyipldgdzfff6brman57hqv3661jw0lh"))))
3cff95cb
RW
4006 (build-system python-build-system)
4007 (arguments '(#:tests? #f)) ; no test target
4008 (native-inputs
4009 `(("python-setuptools" ,python-setuptools)))
eb6e2e81 4010 (home-page "https://pypi.python.org/pypi/decorator/")
3cff95cb
RW
4011 (synopsis "Python module to simplify usage of decorators")
4012 (description
4013 "The aim of the decorator module is to simplify the usage of decorators
4014for the average programmer, and to popularize decorators usage giving examples
4015of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
4016etc. The core of this module is a decorator factory.")
4017 (license license:expat)))
4018
4019(define-public python2-decorator
4020 (package-with-python2 python-decorator))
4021
2c0499ad
RW
4022(define-public python-drmaa
4023 (package
4024 (name "python-drmaa")
4025 (version "0.7.6")
4026 (source
4027 (origin
4028 (method url-fetch)
4029 (uri (string-append
4030 "https://pypi.python.org/packages/source/d/drmaa/drmaa-"
4031 version ".tar.gz"))
4032 (sha256
4033 (base32 "0bzl9f9g34dlhwf09i3fdv7dqqzf2iq0w7d6c2bafx1nlap8qfbh"))))
4034 (build-system python-build-system)
4035 ;; The test suite requires libdrmaa which is provided by the cluster
4036 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
4037 ;; should be set to the path of the libdrmaa library.
4038 (arguments '(#:tests? #f))
4039 (native-inputs
4040 `(("python-nose" ,python-nose)
4041 ("python-setuptools" ,python-setuptools)))
4042 (home-page "https://pypi.python.org/pypi/drmaa")
4043 (synopsis "Python bindings for the DRMAA library")
4044 (description
4045 "A Python package for Distributed Resource Management (DRM) job
4046submission and control. This package is an implementation of the DRMAA 1.0
4047Python language binding specification.")
4048 (license bsd-3)))
4049
4050(define-public python2-drmaa
4051 (package-with-python2 python-drmaa))
4052
d05c6da0
RW
4053(define-public python-gridmap
4054 (package
4055 (name "python-gridmap")
4056 (version "0.13.0")
4057 (source
4058 (origin
4059 (method url-fetch)
4060 (uri (string-append
4061 "https://github.com/pygridtools/gridmap/archive/v"
4062 version ".tar.gz"))
4063 (file-name (string-append name "-" version ".tar.gz"))
4064 (sha256
4065 (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x"))))
4066 (build-system python-build-system)
4067 (inputs
4068 `(("python-psutil" ,python-psutil)
4069 ("python-drmaa" ,python-drmaa)
4070 ("python-pyzmq" ,python-pyzmq)))
4071 (native-inputs
4072 `(("python-setuptools" ,python-setuptools)))
4073 (home-page "https://github.com/pygridtools/gridmap")
4074 (synopsis "Create jobs on a cluster directly from Python")
4075 (description
4076 "Gridmap is a Python package to allow you to easily create jobs on the
4077cluster directly from Python. You can directly map Python functions onto the
4078cluster without needing to write any wrapper code yourself.")
4079 (license gpl3+)))
4080
4081(define-public python2-gridmap
4082 (package-with-python2 python-gridmap))
4083
cb6d5c54
RW
4084(define-public python-pexpect
4085 (package
4086 (name "python-pexpect")
4087 (version "3.3")
4088 (source
4089 (origin
4090 (method url-fetch)
4091 (uri (string-append "https://pypi.python.org/packages/source/p/"
4092 "pexpect/pexpect-" version ".tar.gz"))
4093 (sha256
4094 (base32 "1fp5gm976z7ghm8jw57463rj19cv06c8zw842prgyg788f6n3snz"))))
4095 (build-system python-build-system)
4096 (arguments
4097 `(#:phases
4098 (modify-phases %standard-phases
4099 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4100 (native-inputs
4101 `(("python-nose" ,python-nose)))
4102 (home-page "http://pexpect.readthedocs.org/")
4103 (synopsis "Controlling interactive console applications")
4104 (description
4105 "Pexpect is a pure Python module for spawning child applications;
4106controlling them; and responding to expected patterns in their output.
4107Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4108child application and control it as if a human were typing commands.")
4109 (license isc)))
4110
4111(define-public python2-pexpect
4112 (package-with-python2 python-pexpect))
4113
229ad120
RW
4114(define-public python-setuptools-scm
4115 (package
4116 (name "python-setuptools-scm")
42d6d0d0 4117 (version "1.11.1")
229ad120
RW
4118 (source (origin
4119 (method url-fetch)
383af6b0 4120 (uri (pypi-uri "setuptools_scm" version))
229ad120
RW
4121 (sha256
4122 (base32
42d6d0d0 4123 "1gqr73i150yzj3mz32854vj93x07yr52kn8fdckwa41ll8wgficc"))))
229ad120 4124 (build-system python-build-system)
383af6b0 4125 (native-inputs `(("python-setuptools" ,python-setuptools)))
229ad120
RW
4126 (home-page "https://github.com/pypa/setuptools_scm/")
4127 (synopsis "Manage Python package versions in SCM metadata")
4128 (description
383af6b0 4129 "Setuptools_scm handles managing your Python package versions in
229ad120
RW
4130@dfn{software configuration management} (SCM) metadata instead of declaring
4131them as the version argument or in a SCM managed file.")
4132 (license license:expat)))
4133
4134(define-public python2-setuptools-scm
4135 (package-with-python2 python-setuptools-scm))
4136
b74270ee
RW
4137(define-public python-pathpy
4138 (package
4139 (name "python-pathpy")
4140 (version "8.1.1")
4141 (source
4142 (origin
4143 (method url-fetch)
4144 (uri (string-append "https://pypi.python.org/packages/source/p/"
4145 "path.py/path.py-" version ".tar.gz"))
4146 (sha256
4147 (base32 "1p8s1l2vfkqhqxdhqlj0g1jjw4f1as2frr35sjcpjjpd5a89y41f"))))
4148 (build-system python-build-system)
4149 (propagated-inputs
4150 `(("python-appdirs" ,python-appdirs)))
4151 (native-inputs
553b709b
EF
4152 `(("python-setuptools" ,python-setuptools)
4153 ("python-setuptools-scm" ,python-setuptools-scm)
b74270ee
RW
4154 ("python-pytest" ,python-pytest)
4155 ("python-pytest-runner" ,python-pytest-runner)))
4156 (home-page "http://github.com/jaraco/path.py")
4157 (synopsis "Python module wrapper for built-in os.path")
4158 (description
4159 "@code{path.py} implements path objects as first-class entities, allowing
4160common operations on files to be invoked on those path objects directly.")
4161 (license license:expat)))
4162
4163(define-public python2-pathpy
4164 (package-with-python2 python-pathpy))
4165
0d34e01b
RW
4166(define-public python-pickleshare
4167 (package
4168 (name "python-pickleshare")
4169 (version "0.5")
4170 (source
4171 (origin
4172 (method url-fetch)
4173 (uri (string-append "https://pypi.python.org/packages/source/p/"
4174 "pickleshare/pickleshare-" version ".tar.gz"))
4175 (sha256
4176 (base32 "11ljr90j3p6qswdrbl7p4cjb2i93f6vn0vx9anzpshsx0d2mggn0"))))
4177 (build-system python-build-system)
4178 (propagated-inputs
4179 `(("python-pathpy" ,python-pathpy)))
b72a4410
EF
4180 (native-inputs
4181 `(("python-setuptools" ,python-setuptools)))
0d34e01b
RW
4182 (home-page "https://github.com/vivainio/pickleshare")
4183 (synopsis "Tiny key value database with concurrency support")
4184 (description
4185 "PickleShare is a small ‘shelve’-like datastore with concurrency support.
4186Like shelve, a PickleShareDB object acts like a normal dictionary. Unlike
4187shelve, many processes can access the database simultaneously. Changing a
4188value in database is immediately visible to other processes accessing the same
4189database. Concurrency is possible because the values are stored in separate
4190files. Hence the “database” is a directory where all files are governed by
4191PickleShare.")
4192 (license license:expat)))
4193
4194(define-public python2-pickleshare
4195 (package-with-python2 python-pickleshare))
4196
cd6e5189
RW
4197(define-public python-simplegeneric
4198 (package
4199 (name "python-simplegeneric")
4200 (version "0.8.1")
4201 (source
4202 (origin
4203 (method url-fetch)
4204 (uri (string-append "https://pypi.python.org/packages/source/s/"
4205 "simplegeneric/simplegeneric-" version ".zip"))
4206 (sha256
4207 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
4208 (build-system python-build-system)
4209 (native-inputs
69b96e5e
RW
4210 `(("python-setuptools" ,python-setuptools)
4211 ("unzip" ,unzip)))
cd6e5189
RW
4212 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
4213 (synopsis "Python module for simple generic functions")
4214 (description
4215 "The simplegeneric module lets you define simple single-dispatch generic
4216functions, akin to Python’s built-in generic functions like @code{len()},
4217@code{iter()} and so on. However, instead of using specially-named methods,
4218these generic functions use simple lookup tables, akin to those used by
4219e.g. @code{pickle.dump()} and other generic functions found in the Python
4220standard library.")
4221 (license zpl2.1)))
4222
4223(define-public python2-simplegeneric
4224 (package-with-python2 python-simplegeneric))
4225
ddc7d8ed
RW
4226(define-public python-ipython-genutils
4227 (package
4228 (name "python-ipython-genutils")
4229 (version "0.1.0")
4230 (source
4231 (origin
4232 (method url-fetch)
4233 (uri (string-append "https://pypi.python.org/packages/source/i/"
4234 "ipython_genutils/ipython_genutils-"
4235 version ".tar.gz"))
4236 (sha256
4237 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
4238 (build-system python-build-system)
4239 (arguments `(#:tests? #f)) ; no tests
4240 (home-page "http://ipython.org")
4241 (synopsis "Vestigial utilities from IPython")
4242 (description
4243 "This package provides retired utilities from IPython.")
4244 (license bsd-3)))
4245
4246(define-public python2-ipython-genutils
4247 (package-with-python2 python-ipython-genutils))
4248
2b10eb48
RW
4249(define-public python-traitlets
4250 (package
4251 (name "python-traitlets")
cc0c4fde 4252 (version "4.1.0")
2b10eb48
RW
4253 (source
4254 (origin
4255 (method url-fetch)
cc0c4fde 4256 (uri (pypi-uri "traitlets" version))
2b10eb48
RW
4257 (sha256
4258 (base32
cc0c4fde 4259 "0nxgj8jxlm1kqf8cx2x7vjid05zdgbxpqhjbdl46r8njlpgkh3j4"))))
2b10eb48
RW
4260 (build-system python-build-system)
4261 (arguments
4262 `(#:phases
4263 (modify-phases %standard-phases
4264 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4265 (propagated-inputs
4266 `(("python-ipython-genutils" ,python-ipython-genutils)
4267 ("python-decorator" ,python-decorator)))
4268 (native-inputs
cc0c4fde
EF
4269 `(("python-mock" ,python-mock)
4270 ("python-nose" ,python-nose)))
2b10eb48
RW
4271 (home-page "http://ipython.org")
4272 (synopsis "Configuration system for Python applications")
4273 (description
4274 "Traitlets is a framework that lets Python classes have attributes with
4275type checking, dynamically calculated default values, and ‘on change’
4276callbacks. The package also includes a mechanism to use traitlets for
4277configuration, loading values from files or from command line arguments. This
4278is a distinct layer on top of traitlets, so you can use traitlets in your code
4279without using the configuration machinery.")
4280 (license bsd-3)))
4281
4282(define-public python2-traitlets
4283 (package-with-python2 python-traitlets))
4284
ae1ab9fe
FB
4285(define-public python-ipython
4286 (package
4287 (name "python-ipython")
3a0b1b9a 4288 (version "3.2.1")
ae1ab9fe
FB
4289 (source
4290 (origin
fceac880 4291 (method url-fetch)
fc1adab1 4292 (patches (search-patches "python-ipython-inputhook-ctype.patch"))
fceac880
FB
4293 (uri (string-append "https://pypi.python.org/packages/source/i/"
4294 "ipython/ipython-" version ".tar.gz"))
4295 (sha256
4296 (base32 "0xwin0sa9n0cabx4cq1ibf5ldsiw5dyimibla82kicz5gbpas4y9"))))
ae1ab9fe
FB
4297 (build-system python-build-system)
4298 (outputs '("out" "doc"))
3a0b1b9a
FB
4299 (propagated-inputs
4300 `(("python-pyzmq" ,python-pyzmq)
4301 ("python-terminado" ,python-terminado)))
ae1ab9fe
FB
4302 (inputs
4303 `(("readline" ,readline)
3a0b1b9a 4304 ("which" ,which)
ae1ab9fe 4305 ("python-matplotlib" ,python-matplotlib)
5d26e542 4306 ("python-numpy" ,python-numpy)
ae1ab9fe 4307 ("python-numpydoc" ,python-numpydoc)
3a0b1b9a
FB
4308 ("python-jinja2" ,python-jinja2)
4309 ("python-mistune" ,python-mistune)
4310 ("python-jsonschema" ,python-jsonschema)
4311 ("python-pygments" ,python-pygments)
4312 ("python-requests" ,python-requests) ;; for tests
ae1ab9fe
FB
4313 ("python-nose" ,python-nose)))
4314 (native-inputs
4315 `(("pkg-config" ,pkg-config)
4316 ("python-sphinx" ,python-sphinx)
4317 ("texlive" ,texlive)
4318 ("texinfo" ,texinfo)
4319 ("python-setuptools" ,python-setuptools)))
4320 (arguments
89b5c60e 4321 `(#:phases
3a0b1b9a
FB
4322 (modify-phases %standard-phases
4323 (add-after
4324 'install 'install-doc
4325 (lambda* (#:key inputs outputs #:allow-other-keys)
4326 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4327 (doc (string-append data "/doc/" ,name "-" ,version))
4328 (html (string-append doc "/html"))
4329 (man1 (string-append data "/man/man1"))
4330 (info (string-append data "/info"))
4331 (examples (string-append doc "/examples")))
afd3d931 4332 (setenv "LANG" "en_US.utf8")
3a0b1b9a
FB
4333 (with-directory-excursion "docs"
4334 ;; FIXME: html and pdf fail to build
4335 ;; (system* "make" "html")
4336 ;; (system* "make" "pdf" "PAPER=a4")
4337 (system* "make" "info"))
4338 (copy-recursively "docs/man" man1)
4339 (copy-recursively "examples" examples)
4340 ;; (copy-recursively "docs/build/html" html)
4341 ;; (copy-file "docs/build/latex/ipython.pdf"
4342 ;; (string-append doc "/ipython.pdf"))
4343 (mkdir-p info)
4344 (copy-file "docs/build/texinfo/ipython.info"
4345 (string-append info "/ipython.info"))
4346 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))
4347 ;; Tests can only be run after the library has been installed and not
4348 ;; within the source directory.
4349 (delete 'check)
4350 (add-after
4351 'install 'check
4352 (lambda* (#:key outputs tests? #:allow-other-keys)
4353 (if tests?
4354 (with-directory-excursion "/tmp"
4355 (setenv "HOME" "/tmp/") ;; required by a test
4356 (zero? (system* (string-append (assoc-ref outputs "out")
4357 "/bin/iptest"))))
4358 #t)))
4359 (add-before
4360 'install 'fix-tests
4361 (lambda* (#:key inputs #:allow-other-keys)
4362 (substitute* "./IPython/utils/_process_posix.py"
4363 (("/usr/bin/env', 'which") (which "which")))
4364 (substitute* "./IPython/core/tests/test_inputtransformer.py"
4365 (("#!/usr/bin/env python")
4366 (string-append "#!" (which "python"))))
4367 ;; Disable 1 failing test
4368 (substitute* "./IPython/core/tests/test_magic.py"
4369 (("def test_dirops\\(\\):" all)
4370 (string-append "@dec.skipif(True)\n" all))))))))
ae1ab9fe
FB
4371 (home-page "http://ipython.org")
4372 (synopsis "IPython is a tool for interactive computing in Python")
4373 (description
4374 "IPython provides a rich architecture for interactive computing with:
4375Powerful interactive shells, a browser-based notebook, support for interactive
4376data visualization, embeddable interpreters and tools for parallel
4377computing.")
4378 (license bsd-3)))
4379
4380(define-public python2-ipython
4381 (let ((ipython (package-with-python2 python-ipython)))
3a0b1b9a
FB
4382 (package
4383 (inherit ipython)
4384 ;; FIXME: some tests are failing
4385 (arguments
4386 `(#:tests? #f ,@(package-arguments ipython)))
ae1ab9fe 4387 ;; Make sure we use custom python2-NAME packages.
3a0b1b9a 4388 ;; FIXME: add pyreadline once available.
667d90df
RW
4389 (propagated-inputs
4390 `(("python2-terminado" ,python2-terminado)
4391 ,@(alist-delete "python-terminado"
4392 (package-propagated-inputs ipython))))
89b5c60e 4393 (inputs
264ae686
EF
4394 `(("python2-jsonschema" ,python2-jsonschema)
4395 ("python2-mock" ,python2-mock)
3a0b1b9a 4396 ("python2-matplotlib" ,python2-matplotlib)
5587253a 4397 ("python2-numpy" ,python2-numpy)
264ae686 4398 ("python2-requests" ,python2-requests)
5587253a 4399 ,@(fold alist-delete (package-inputs ipython)
264ae686 4400 '("python-jsonschema" "python-matplotlib" "python-numpy" "python-requests")))))))
03411993
AE
4401
4402(define-public python-isodate
4403 (package
4404 (name "python-isodate")
b6785c2e 4405 (version "0.5.4")
03411993
AE
4406 (source
4407 (origin
4408 (method url-fetch)
b6785c2e 4409 (uri (pypi-uri "isodate" version))
03411993
AE
4410 (sha256
4411 (base32
b6785c2e 4412 "0cafaiwixgpxwh9dsd28qb0dbzsj6xpxjdkyk30ns91ps10mq422"))))
03411993
AE
4413 (build-system python-build-system)
4414 (inputs
4415 `(("python-setuptools" ,python-setuptools)))
4416 (home-page
4417 "http://cheeseshop.python.org/pypi/isodate")
4418 (synopsis
4419 "Python date parser and formatter")
4420 (description
4421 "Python-isodate is a python module for parsing and formatting
4422ISO 8601 dates, time and duration.")
4423 (license bsd-3)))
4424
4425(define-public python2-isodate
4426 (package-with-python2 python-isodate))
673ab897
AE
4427
4428(define-public python-html5lib
4429 (package
4430 (name "python-html5lib")
fee04c19 4431 (version "1.0b8")
673ab897
AE
4432 (source
4433 (origin
4434 (method url-fetch)
fee04c19 4435 (uri (pypi-uri "html5lib" version))
673ab897
AE
4436 (sha256
4437 (base32
fee04c19 4438 "1lknq5j3nh11xrl268ks76zaj0gyzh34v94n5vbf6dk8llzxdx0q"))))
673ab897 4439 (build-system python-build-system)
3dd75476
AE
4440 (propagated-inputs
4441 `(("python-six" ,python-six))) ; required to "import html5lib"
673ab897
AE
4442 (inputs
4443 `(("python-setuptools" ,python-setuptools)))
4444 (arguments
4445 `(#:test-target "check"))
4446 (home-page
4447 "https://github.com/html5lib/html5lib-python")
4448 (synopsis
4449 "Python HTML parser based on the WHATWG HTML specifcation")
4450 (description
4451 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
4452and written in Python.")
bd3fa666 4453 (license license:expat)))
673ab897
AE
4454
4455(define-public python2-html5lib
4456 (package-with-python2 python-html5lib))
e99f4211
MW
4457
4458(define-public python-urwid
4459 (package
4460 (name "python-urwid")
4461 (version "1.3.0")
4462 (source
4463 (origin
4464 (method url-fetch)
b97c1bfd 4465 (uri (pypi-uri "urwid" version))
e99f4211
MW
4466 (sha256
4467 (base32
4468 "18mb0yy94sjc434rd61m2sfnw27sa0nyrszpj5a9r9zh7fnlzw19"))))
4469 (build-system python-build-system)
b97c1bfd
LF
4470 (arguments
4471 `(#:phases
4472 (modify-phases %standard-phases
4473 ;; Disable failing test. Bug filed upstream:
4474 ;; https://github.com/wardi/urwid/issues/164
4475 ;; TODO: check again for python-urwid > 1.3.0 or python > 3.4.3.
4476 (add-after 'unpack 'disable-failing-test
4477 (lambda _
4478 (substitute* "urwid/tests/test_event_loops.py"
4479 (("test_remove_watch_file")
4480 "disable_remove_watch_file")))))))
e99f4211
MW
4481 (native-inputs `(("python-setuptools" ,python-setuptools)))
4482 (home-page "http://urwid.org")
4483 (synopsis "Console user interface library for Python")
4484 (description
4485 "Urwid is a curses-based UI/widget library for Python. It includes many
4486features useful for text console applications.")
4487 (license lgpl2.1+)))
4488
4489(define-public python2-urwid
4490 (package-with-python2 python-urwid))
d95a56c6 4491
47d0b292
TS
4492(define-public python-urwidtrees
4493 (package
4494 (name "python-urwidtrees")
4495 (version "1.0.1.1")
4496 (source
4497 (origin
4498 (method url-fetch)
4499 (uri (pypi-uri "urwidtrees" version))
4500 (sha256
4501 (base32
4502 "1zcvy12s7h3fazf33d6y7b4v19p8hg95xqwhqlmw6jz9fq76v9h8"))))
4503 (build-system python-build-system)
4504 (arguments
4505 '(#:tests? #f)) ; no tests
4506 (inputs `(("python-urwid" ,python-urwid)))
4507 (home-page "https://github.com/pazz/urwidtrees")
4508 (synopsis "Tree widgets for urwid")
4509 (description "Urwidtrees is a Widget Container API for the @code{urwid}
4510toolkit. Use it to build trees of widgets.")
4511 (license gpl3+)))
4512
4513(define-public python2-urwidtrees
4514 (package-with-python2 python-urwidtrees))
4515
d95a56c6
PAR
4516(define-public python-dbus
4517 (package
4518 (name "python-dbus")
4519 (version "1.2.0")
4520 (source
4521 (origin
4522 (method url-fetch)
4523 (uri (string-append
5cc3096c 4524 "https://dbus.freedesktop.org/releases/dbus-python/dbus-python-"
d95a56c6
PAR
4525 version ".tar.gz"))
4526 (sha256
4527 (base32 "1py62qir966lvdkngg0v8k1khsqxwk5m4s8nflpk1agk5f5nqb71"))))
4528 (build-system gnu-build-system)
6717c879
SB
4529 (arguments
4530 '(#:phases
4531 (modify-phases %standard-phases
4532 (add-before
4533 'check 'pre-check
4534 (lambda _
4535 ;; XXX: For the missing '/etc/machine-id'.
4536 (substitute* "test/run-test.sh"
4537 (("DBUS_FATAL_WARNINGS=1")
4538 "DBUS_FATAL_WARNINGS=0"))
4539 #t)))))
d95a56c6
PAR
4540 (native-inputs
4541 `(("pkg-config" ,pkg-config)))
4542 (inputs
4543 `(("python" ,python)
2e88d113 4544 ("dbus-glib" ,dbus-glib)))
d95a56c6
PAR
4545 (synopsis "Python bindings for D-bus")
4546 (description "python-dbus provides bindings for libdbus, the reference
4547implementation of D-Bus.")
4548 (home-page "http://www.freedesktop.org/wiki/Software/DBusBindings/")
bd3fa666 4549 (license license:expat)))
b52af02b
MW
4550
4551(define-public python2-dbus
4552 (package (inherit python-dbus)
4553 (name "python2-dbus")
4554 (inputs `(("python" ,python-2)
4555 ,@(alist-delete "python"
4556 (package-inputs python-dbus)
4557 equal?)))
4558 ;; FIXME: on Python 2, the test_utf8 fails with:
4559 ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)"
4560 (arguments `(#:tests? #f))))
a6ac8332
AE
4561
4562(define-public python-apsw
4563 (package
4564 (name "python-apsw")
917708c2 4565 (version "3.9.2-r1")
a6ac8332
AE
4566 (source
4567 (origin
4568 (method url-fetch)
917708c2 4569 (uri (pypi-uri "apsw" version))
a6ac8332
AE
4570 (sha256
4571 (base32
917708c2 4572 "0w4jb0wpx785qw42r3h4fh7gl5w2968q48i7gygybsfxck8nzffs"))))
a6ac8332
AE
4573 (build-system python-build-system)
4574 (inputs
4575 `(("python-setuptools" ,python-setuptools)
4576 ("sqlite" ,sqlite)))
4577 (arguments
4578 `(#:phases
4579 ;; swap check and install phases
4580 (alist-cons-after
4581 'install 'check
4582 (assoc-ref %standard-phases 'check)
4583 (alist-delete
4584 'check
4585 %standard-phases))))
4586 (home-page "https://github.com/rogerbinns/apsw/")
4587 (synopsis "Another Python SQLite Wrapper")
4588 (description "APSW is a Python wrapper for the SQLite
4589embedded relational database engine. In contrast to other wrappers such as
4590pysqlite it focuses on being a minimal layer over SQLite attempting just to
4591translate the complete SQLite API into Python.")
abde5f37 4592 (license license:zlib)))
a6ac8332
AE
4593
4594(define-public python2-apsw
4595 (package-with-python2 python-apsw))
26b307e2
AE
4596
4597(define-public python-lxml
4598 (package
4599 (name "python-lxml")
97bbc480 4600 (version "3.5.0")
26b307e2
AE
4601 (source
4602 (origin
4603 (method url-fetch)
97bbc480 4604 (uri (pypi-uri "lxml" version))
26b307e2
AE
4605 (sha256
4606 (base32
97bbc480 4607 "0y7m2s8ci6q642zl85y5axkj8z827l0vhjl532acb75hlkir77rl"))))
26b307e2
AE
4608 (build-system python-build-system)
4609 (inputs
4610 `(("libxml2" ,libxml2)
4611 ("libxslt" ,libxslt)
4612 ("python-setuptools" ,python-setuptools)))
4613 (home-page "http://lxml.de/")
4614 (synopsis
4615 "Python XML processing library")
4616 (description
4617 "The lxml XML toolkit is a Pythonic binding for the C libraries
4618libxml2 and libxslt.")
4619 (license bsd-3))) ; and a few more, see LICENSES.txt
4620
4621(define-public python2-lxml
4622 (package-with-python2 python-lxml))
4ed20663 4623
b32a1e47
CAW
4624;; beautifulsoup4 has a totally different namespace than 3.x,
4625;; and pypi seems to put it under its own name, so I guess we should too
4626(define-public python-beautifulsoup4
4627 (package
4628 (name "python-beautifulsoup4")
4629 (version "4.4.1")
4630 (source
4631 (origin
4632 (method url-fetch)
4633 (uri (pypi-uri "beautifulsoup4" version))
4634 (sha256
4635 (base32
4636 "1d36lc4pfkvl74fmzdib2nqnvknm0jddgf2n9yd7im150qyh3m47"))))
4637 (build-system python-build-system)
4638 (home-page
4639 "http://www.crummy.com/software/BeautifulSoup/bs4/")
4640 (synopsis
4641 "Python screen-scraping library")
4642 (description
4643 "Beautiful Soup is a Python library designed for rapidly setting up
4644screen-scraping projects. It offers Pythonic idioms for navigating,
4645searching, and modifying a parse tree, providing a toolkit for
4646dissecting a document and extracting what you need. It automatically
4647converts incoming documents to Unicode and outgoing documents to UTF-8.")
4648 (license license:expat)
4649 (properties `((python2-variant . ,(delay python2-beautifulsoup4))))))
4650
4651(define-public python2-beautifulsoup4
4652 (package
4653 (inherit (package-with-python2
4654 (strip-python2-variant python-beautifulsoup4)))
4655 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
4656
092e86f5
AE
4657(define-public python2-cssutils
4658 (package
4659 (name "python2-cssutils")
4660 (version "1.0")
4661 (source
4662 (origin
4663 (method url-fetch)
4664 (uri (string-append
4665 "https://pypi.python.org/packages/source/c/cssutils/cssutils-"
4666 version
4667 ".zip"))
4668 (sha256
4669 (base32
4670 "1bwim1353r4hqiir73sn4sc43y7ymh09qx0kly7vj048blppc125"))))
4671 (build-system python-build-system)
4672 (native-inputs
4673 `(("python2-mock" ,python2-mock) ; for the tests
4674 ("unzip" ,unzip))) ; for unpacking the source
4675 (inputs
4676 `(("python2-setuptools" ,python2-setuptools)))
4677 (arguments
4678 `(#:python ,python-2 ; Otherwise tests fail with a syntax error.
4679 #:tests? #f ; The tests apparently download an external URL.
da6dd842 4680 ))
092e86f5
AE
4681 (home-page "http://cthedot.de/cssutils/")
4682 (synopsis
4683 "CSS Cascading Style Sheets library for Python")
4684 (description
4685 "Cssutils is a Python package for parsing and building CSS
4686Cascading Style Sheets. Currently it provides a DOM only and no rendering
4687options.")
4688 (license lgpl3+)))
880ff77c
AE
4689
4690(define-public python-cssselect
4691 (package
4692 (name "python-cssselect")
4693 (version "0.9.1")
4694 (source
4695 (origin
4696 (method url-fetch)
4697 (uri (string-append
4698 "https://pypi.python.org/packages/source/c/cssselect/cssselect-"
4699 version
4700 ".tar.gz"))
4701 (sha256
4702 (base32
4703 "10h623qnp6dp1191jri7lvgmnd4yfkl36k9smqklp1qlf3iafd85"))))
4704 (build-system python-build-system)
4705 (inputs
4706 `(("python-setuptools" ,python-setuptools)))
4707 (arguments
4708 ;; tests fail with message
4709 ;; AttributeError: 'module' object has no attribute 'tests'
4710 `(#:tests? #f))
4711 (home-page
4712 "https://pythonhosted.org/cssselect/")
4713 (synopsis
4714 "CSS3 selector parser and translator to XPath 1.0")
4715 (description
4716 "Cssselect ia a Python module that parses CSS3 Selectors and translates
4717them to XPath 1.0 expressions. Such expressions can be used in lxml or
4718another XPath engine to find the matching elements in an XML or HTML document.")
4719 (license bsd-3)))
4720
4721(define-public python2-cssselect
4722 (package-with-python2 python-cssselect))
60357f99
AE
4723
4724(define-public python-netifaces
4725 (package
4726 (name "python-netifaces")
4727 (version "0.10.4")
4728 (source
4729 (origin
4730 (method url-fetch)
4731 (uri (string-append
4732 "https://pypi.python.org/packages/source/n/netifaces/netifaces-"
4733 version
4734 ".tar.gz"))
4735 (sha256
4736 (base32
4737 "1plw237a4zib4z8s62g0mrs8gm3kjfrp5sxh6bbk9nl3rdls2mln"))))
4738 (build-system python-build-system)
4739 (inputs
4740 `(("python-setuptools" ,python-setuptools)))
4741 (home-page
4742 "https://bitbucket.org/al45tair/netifaces")
4743 (synopsis
4744 "Python module for portable network interface information")
4745 (description
4746 "Netifaces is a Python module providing information on network
4747interfaces in an easy and portable manner.")
4748 (license license:expat)))
4749
4750(define-public python2-netifaces
4751 (package-with-python2 python-netifaces))
92cb152b 4752
32f77c04
RW
4753(define-public python-networkx
4754 (package
4755 (name "python-networkx")
a4d9609c 4756 (version "1.11")
32f77c04
RW
4757 (source
4758 (origin
4759 (method url-fetch)
a4d9609c 4760 (uri (pypi-uri "networkx" version))
32f77c04 4761 (sha256
a4d9609c 4762 (base32 "1f74s56xb4ggixiq0vxyfxsfk8p20c7a099lpcf60izv1php03hd"))))
32f77c04
RW
4763 (build-system python-build-system)
4764 ;; python-decorator is needed at runtime
4765 (propagated-inputs
4766 `(("python-decorator" ,python-decorator)))
4767 (native-inputs
4768 `(("python-setuptools" ,python-setuptools)
4769 ("python-nose" ,python-nose)))
4770 (home-page "http://networkx.github.io/")
4771 (synopsis "Python module for creating and manipulating graphs and networks")
4772 (description
4773 "NetworkX is a Python package for the creation, manipulation, and study
4774of the structure, dynamics, and functions of complex networks.")
4775 (license bsd-3)))
4776
4777(define-public python2-networkx
4778 (package-with-python2 python-networkx))
4779
92cb152b
RW
4780(define-public snakemake
4781 (package
4782 (name "snakemake")
4783 (version "3.2.1")
4784 (source
4785 (origin
4786 (method url-fetch)
4787 (uri (string-append
4788 "https://pypi.python.org/packages/source/s/snakemake/snakemake-"
4789 version ".tar.gz"))
4790 (sha256
4791 (base32 "0fi4b63sj60hvi7rfydvmz2icl4wj74djw5sn2gl8hxd02qw4b91"))))
4792 (build-system python-build-system)
4793 (inputs `(("python-setuptools" ,python-setuptools)))
4794 (home-page "https://bitbucket.org/johanneskoester/snakemake")
4795 (synopsis "Python-based execution environment for make-like workflows")
4796 (description
4797 "Snakemake aims to reduce the complexity of creating workflows by
4798providing a clean and modern domain specific specification language (DSL) in
4799Python style, together with a fast and comfortable execution environment.")
4800 (license license:expat)))
a1920bc9 4801
35de1fbd
RW
4802(define-public python-seaborn
4803 (package
4804 (name "python-seaborn")
fc899d4f 4805 (version "0.7.0")
35de1fbd
RW
4806 (source
4807 (origin
4808 (method url-fetch)
fc899d4f 4809 (uri (pypi-uri "seaborn" version))
35de1fbd 4810 (sha256
fc899d4f 4811 (base32 "0ibi3xsfm2kysph61mnfy0pf8d5rkgxgrdb0z9nbizgcgdsb5a0m"))))
35de1fbd
RW
4812 (build-system python-build-system)
4813 (propagated-inputs
4814 `(("python-pandas" ,python-pandas)
4815 ("python-matplotlib" ,python-matplotlib)
4816 ("python-scipy" ,python-scipy)))
35de1fbd
RW
4817 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
4818 (synopsis "Statistical data visualization")
4819 (description
4820 "Seaborn is a library for making attractive and informative statistical
4821graphics in Python. It is built on top of matplotlib and tightly integrated
4822with the PyData stack, including support for numpy and pandas data structures
4823and statistical routines from scipy and statsmodels.")
fc899d4f
EF
4824 (license bsd-3)
4825 (properties `((python2-variant . ,(delay python2-seaborn))))))
35de1fbd
RW
4826
4827(define-public python2-seaborn
fc899d4f
EF
4828 (let ((base (package-with-python2 (strip-python2-variant python-seaborn))))
4829 (package
4830 (inherit base)
4831 (propagated-inputs `(("python2-pytz" ,python2-pytz)
4832 ,@(package-propagated-inputs base)))
4833 (native-inputs `(("python2-setuptools" ,python2-setuptools)
4834 ,@(package-native-inputs base))))))
35de1fbd 4835
90fc547f
RW
4836(define-public python-sympy
4837 (package
4838 (name "python-sympy")
4839 (version "0.7.6")
4840 (source
4841 (origin
4842 (method url-fetch)
4843 (uri (string-append
4844 "https://github.com/sympy/sympy/releases/download/sympy-"
4845 version "/sympy-" version ".tar.gz"))
4846 (sha256
4847 (base32 "19yp0gy4i7p4g6l3b8vaqkj9qj7yqb5kqy0qgbdagpzgkdz958yz"))))
4848 (build-system python-build-system)
4849 (native-inputs
4850 `(("python-setuptools" ,python-setuptools)))
4851 (home-page "http://www.sympy.org/")
4852 (synopsis "Python library for symbolic mathematics")
4853 (description
4854 "SymPy is a Python library for symbolic mathematics. It aims to become a
4855full-featured computer algebra system (CAS) while keeping the code as simple
4856as possible in order to be comprehensible and easily extensible.")
4857 (license bsd-3)))
4858
4859(define-public python2-sympy
4860 (package-with-python2 python-sympy))
4861
a1920bc9
FB
4862(define-public python-testlib
4863 (package
4864 (name "python-testlib")
4865 (version "0.6.5")
4866 (source
4867 (origin
4868 (method url-fetch)
4869 (uri (string-append
4870 "https://pypi.python.org/packages/source/t/testlib/testlib-"
4871 version ".zip"))
4872 (sha256
4873 (base32 "1mz26cxn4x8bbgv0rn0mvj2z05y31rkc8009nvdlb3lam5b4mj3y"))))
4874 (build-system python-build-system)
4875 (inputs
4876 `(("python-setuptools" ,python-setuptools)))
4877 (native-inputs
4878 `(("unzip" ,unzip)))
4879 (arguments
4880 `(#:phases
4881 (alist-replace
4882 'unpack
4883 (lambda* (#:key inputs outputs #:allow-other-keys)
4884 (let ((unzip (string-append (assoc-ref inputs "unzip")
4885 "/bin/unzip"))
4886 (source (assoc-ref inputs "source")))
4887 (and (zero? (system* unzip source))
4888 (chdir (string-append "testlib-" ,version)))))
4889 %standard-phases)))
4890 (synopsis "Python micro test suite harness")
4891 (description "A micro unittest suite harness for Python.")
4892 (home-page "https://github.com/trentm/testlib")
1cb9c006 4893 (license license:expat)))
a1920bc9
FB
4894
4895(define-public python2-testlib
4896 (package-with-python2 python-testlib))
db62afa5
LC
4897
4898(define-public python2-xlib
4899 (package
4900 (name "python2-xlib")
4901 (version "0.14")
4902 (source (origin
4903 (method url-fetch)
4904 (uri (string-append "mirror://sourceforge/python-xlib/"
4905 "python-xlib-" version ".tar.gz"))
4906 (sha256
4907 (base32
4908 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
4909 (build-system python-build-system)
4910 (arguments
4911 `(#:python ,python-2 ;Python 2 only
4912 #:tests? #f)) ;no tests
4913 (inputs
4914 `(("python-setuptools" ,python-setuptools)))
4915 (home-page "http://python-xlib.sourceforge.net/")
4916 (synopsis "Python X11 client library")
4917 (description
4918 "The Python X Library is intended to be a fully functional X client
4919library for Python programs. It is useful to implement low-level X clients.
4920It is written entirely in Python.")
4921 (license gpl2+)))
0234ca06
DT
4922
4923(define-public python-singledispatch
4924 (package
4925 (name "python-singledispatch")
4926 (version "3.4.0.3")
4927 (source
4928 (origin
4929 (method url-fetch)
bdb67d84 4930 (uri (pypi-uri "singledispatch" version))
0234ca06
DT
4931 (sha256
4932 (base32
4933 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
4934 (build-system python-build-system)
4935 (native-inputs
4936 `(("python-setuptools" ,python-setuptools)))
bdb67d84 4937 (inputs
0234ca06
DT
4938 `(("python-six" ,python-six)))
4939 (home-page
4940 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
4941 (synopsis "Backport of singledispatch feature from Python 3.4")
4942 (description
4943 "This library brings functools.singledispatch from Python 3.4 to Python
49442.6-3.3.")
4945 (license license:expat)))
4946
4947(define-public python2-singledispatch
4948 (package-with-python2 python-singledispatch))
feaae484 4949
310d218f
RW
4950(define-public python-tornado
4951 (package
4952 (name "python-tornado")
a724924b 4953 (version "4.3")
310d218f
RW
4954 (source
4955 (origin
4956 (method url-fetch)
a724924b 4957 (uri (pypi-uri "tornado" version))
310d218f 4958 (sha256
a724924b 4959 (base32 "1gzgwayl6hmc9jfcl88bni4jcsk2jcca9dn1rvrfsvnijcjx7hn9"))))
310d218f 4960 (build-system python-build-system)
310d218f 4961 (native-inputs
b455439b
EF
4962 `(("python-certifi" ,python-certifi)))
4963 (inputs
4964 `(("python-backports-abc" ,python-backports-abc)))
f4a4a718 4965 (home-page "http://www.tornadoweb.org/")
310d218f
RW
4966 (synopsis "Python web framework and asynchronous networking library")
4967 (description
4968 "Tornado is a Python web framework and asynchronous networking library,
4969originally developed at FriendFeed. By using non-blocking network I/O,
4970Tornado can scale to tens of thousands of open connections, making it ideal
4971for long polling, WebSockets, and other applications that require a long-lived
4972connection to each user.")
b455439b
EF
4973 (license asl2.0)
4974 (properties `((python2-variant . ,(delay python2-tornado))))))
310d218f
RW
4975
4976(define-public python2-tornado
b455439b 4977 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
310d218f
RW
4978 (package (inherit tornado)
4979 (inputs
4980 `(("python2-backport-ssl-match-hostname"
4981 ,python2-backport-ssl-match-hostname)
b455439b
EF
4982 ("python2-singledispatch" ,python2-singledispatch)
4983 ,@(package-inputs tornado)))
4984 (native-inputs
4985 `(("python2-setuptools" ,python2-setuptools)
4986 ,@(package-native-inputs tornado))))))
310d218f 4987
6b59fc10
EF
4988;; the python- version can be removed with python-3.5
4989(define-public python-backports-abc
4990 (package
4991 (name "python-backports-abc")
4992 (version "0.4")
4993 (source
4994 (origin
4995 (method url-fetch)
4996 (uri (pypi-uri "backports_abc" version))
4997 (sha256
4998 (base32
4999 "19fh75lni9pb673n2fn505m1rckm0af0szcv5xx1qm1xpa940glb"))))
5000 (build-system python-build-system)
5001 (inputs
5002 `(("python-setuptools" ,python-setuptools)))
5003 (home-page "https://github.com/cython/backports_abc")
5004 (synopsis "Backport of additions to the 'collections.abc' module.")
5005 (description
5006 "Python-backports-abc provides a backport of additions to the
5007'collections.abc' module in Python-3.5.")
5008 (license psfl)))
5009
5010(define-public python2-backports-abc
5011 (package-with-python2 python-backports-abc))
5012
feaae484
SB
5013(define-public python-waf
5014 (package
5015 (name "python-waf")
5016 (version "1.8.8")
5017 (source (origin
5018 (method url-fetch)
5019 (uri (string-append "https://waf.io/"
5020 "waf-" version ".tar.bz2"))
5021 (sha256
5022 (base32
5023 "0b5q307fgn6a5d8yjia2d1l4bk1q3ilvc0w8k4isfrrx2gbcw8wn"))))
5024 (build-system python-build-system)
5025 (arguments
5026 '(#:phases
5027 (modify-phases %standard-phases
5028 (replace 'build
5029 (lambda _
5030 (zero? (begin
5031 (system* "python" "waf-light" "configure")
5032 (system* "python" "waf-light" "build")))))
5033 (replace 'check
5034 (lambda _
5035 (zero? (system* "python" "waf" "--version"))))
5036 (replace 'install
5037 (lambda _
5038 (copy-file "waf" %output))))))
5039 (home-page "https://waf.io/")
5040 (synopsis "Python-based build system")
5041 (description
5042 "Waf is a Python-based framework for configuring, compiling and installing
5043applications.")
5044 (license bsd-3)))
5045
5046(define-public python2-waf
5047 (package-with-python2 python-waf))
45203542
RW
5048
5049(define-public python-pyzmq
5050 (package
5051 (name "python-pyzmq")
3655ee76 5052 (version "15.1.0")
45203542
RW
5053 (source
5054 (origin
5055 (method url-fetch)
3655ee76 5056 (uri (pypi-uri "pyzmq" version))
45203542 5057 (sha256
3655ee76 5058 (base32 "13fhwnlvsvxv72kfhqbpn6qi7msh8mc8377mpabv32skk2cjfnxx"))))
45203542
RW
5059 (build-system python-build-system)
5060 (arguments
5061 `(#:configure-flags
5062 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
5063 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
5064 ;; --inplace' for 'python setup.py test' to work.
5065 #:tests? #f))
5066 (inputs
5067 `(("zeromq" ,zeromq)))
5068 (native-inputs
5069 `(("pkg-config" ,pkg-config)
5070 ("python-nose" ,python-nose)
5071 ("python-setuptools" ,python-setuptools)))
5072 (home-page "http://github.com/zeromq/pyzmq")
5073 (synopsis "Python bindings for 0MQ")
5074 (description
5075 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
5076 (license bsd-4)))
5077
5078(define-public python2-pyzmq
5079 (package-with-python2 python-pyzmq))
d889e6c4
CR
5080
5081(define-public python-pep8
5082 (package
5083 (name "python-pep8")
db251311 5084 (version "1.7.0")
d889e6c4
CR
5085 (source
5086 (origin
5087 (method url-fetch)
db251311 5088 (uri (pypi-uri "pep8" version))
d889e6c4
CR
5089 (sha256
5090 (base32
db251311 5091 "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1"))))
d889e6c4
CR
5092 (build-system python-build-system)
5093 (inputs
5094 `(("python-setuptools" ,python-setuptools)))
5095 (home-page "http://pep8.readthedocs.org/")
5096 (synopsis "Python style guide checker")
5097 (description
5098 "This tools checks Python code against some of the style conventions in
5099PEP 8.")
5100 (license license:expat)))
5101
5102(define-public python2-pep8
5103 (package-with-python2 python-pep8))
e31d7f44
CR
5104
5105(define-public python-pyflakes
5106 (package
5107 (name "python-pyflakes")
2abc3972 5108 (version "1.0.0")
e31d7f44
CR
5109 (source
5110 (origin
5111 (method url-fetch)
2abc3972 5112 (uri (pypi-uri "pyflakes" version))
e31d7f44
CR
5113 (sha256
5114 (base32
2abc3972 5115 "0qs2sgqszq7wcplis8509wk2ygqcrwzbs1ghfj3svvivq2j377pk"))))
e31d7f44
CR
5116 (build-system python-build-system)
5117 (inputs
5118 `(("python-setuptools" ,python-setuptools)))
5119 (home-page
5120 "https://github.com/pyflakes/pyflakes")
5121 (synopsis "Passive checker of Python programs")
5122 (description
5123 "Pyflakes statically checks Python source code for common errors.")
5124 (license license:expat)))
a59e017c 5125
7261d9eb
CR
5126(define-public python2-pyflakes
5127 (package-with-python2 python-pyflakes))
5128
a59e017c
CR
5129(define-public python-mccabe
5130 (package
5131 (name "python-mccabe")
c6ebd40d 5132 (version "0.4.0")
a59e017c
CR
5133 (source
5134 (origin
5135 (method url-fetch)
c6ebd40d 5136 (uri (pypi-uri "mccabe" version))
a59e017c
CR
5137 (sha256
5138 (base32
c6ebd40d 5139 "0yr08a36h8lqlif10l4xcikbbig7q8f41gqywir7rrvnv3mi4aws"))))
a59e017c
CR
5140 (build-system python-build-system)
5141 (inputs
c6ebd40d
EF
5142 `(("python-pytest" ,python-pytest)
5143 ("python-pytest-runner" ,python-pytest-runner)
5144 ("python-setuptools" ,python-setuptools)))
a59e017c
CR
5145 (home-page "https://github.com/flintwork/mccabe")
5146 (synopsis "McCabe checker, plugin for flake8")
5147 (description
5148 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
5149complexity of Python source code.")
7362371d 5150 (license license:expat)))
a59e017c
CR
5151
5152(define-public python2-mccabe
5153 (package-with-python2 python-mccabe))
e8df8f47 5154
7477fbb1
CR
5155(define-public python-mccabe-0.2.1
5156 (package (inherit python-mccabe)
5157 (version "0.2.1")
5158 (source
5159 (origin
5160 (method url-fetch)
5161 (uri (pypi-uri "mccabe" version))
5162 (sha256
5163 (base32
c6ebd40d 5164 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))
b3546174 5165 (inputs `(("python-setuptools" ,python-setuptools)))))
7477fbb1
CR
5166
5167(define-public python2-mccabe-0.2.1
5168 (package-with-python2 python-mccabe-0.2.1))
5169
e8df8f47
CR
5170;; Flake8 2.4.1 requires an older version of pep8.
5171;; This should be removed ASAP.
5172(define-public python-pep8-1.5.7
5173 (package (inherit python-pep8)
5174 (version "1.5.7")
5175 (source
5176 (origin
5177 (method url-fetch)
5178 (uri (string-append
5179 "https://pypi.python.org/packages/source/p/pep8/pep8-"
5180 version
5181 ".tar.gz"))
5182 (sha256
5183 (base32
5184 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))))
5185
5186(define-public python2-pep8-1.5.7
5187 (package-with-python2 python-pep8-1.5.7))
5188
5189;; Flake8 2.4.1 requires an older version of pyflakes.
5190;; This should be removed ASAP.
5191(define-public python-pyflakes-0.8.1
5192 (package (inherit python-pyflakes)
5193 (version "0.8.1")
5194 (source
5195 (origin
5196 (method url-fetch)
5197 (uri (string-append
5198 "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-"
5199 version
5200 ".tar.gz"))
5201 (sha256
5202 (base32
5203 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))))
5204
5205(define-public python2-pyflakes-0.8.1
7261d9eb 5206 (package-with-python2 python-pyflakes-0.8.1))
e8df8f47
CR
5207
5208(define-public python-flake8
5209 (package
5210 (name "python-flake8")
43789136 5211 (version "2.5.4")
e8df8f47
CR
5212 (source
5213 (origin
5214 (method url-fetch)
1b995533 5215 (uri (pypi-uri "flake8" version))
e8df8f47
CR
5216 (sha256
5217 (base32
43789136 5218 "0bs9cz4fr99r2rwig1b8jwaadl1nan7kgpdzqwj0bwbckwbmh7nc"))))
e8df8f47
CR
5219 (build-system python-build-system)
5220 (inputs
5221 `(("python-setuptools" ,python-setuptools)
43789136
EF
5222 ("python-pep8" ,python-pep8)
5223 ("python-pyflakes" ,python-pyflakes)
e8df8f47
CR
5224 ("python-mccabe" ,python-mccabe)
5225 ("python-mock" ,python-mock)
5226 ("python-nose" ,python-nose)))
5227 (home-page "https://gitlab.com/pycqa/flake8")
5228 (synopsis
5229 "The modular source code checker: pep8, pyflakes and co")
5230 (description
5231 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
5232 (license license:expat)))
5233
5234(define-public python2-flake8
5235 (package-with-python2 python-flake8))
61b9ac53 5236
abf21efc
CR
5237;; This will only be needed by the python-hacking package and will not be
5238;; necessary once python-hacking > 0.10.2 is released.
5239(define-public python-flake8-2.2.4
5240 (package (inherit python-flake8)
5241 (inputs
5242 `(("python-setuptools" ,python-setuptools)
5243 ("python-pep8" ,python-pep8-1.5.7)
5244 ("python-pyflakes" ,python-pyflakes-0.8.1)
5245 ("python-mccabe" ,python-mccabe-0.2.1)
5246 ("python-mock" ,python-mock)
5247 ("python-nose" ,python-nose)))
5248 (version "2.2.4")
5249 (source
5250 (origin
5251 (method url-fetch)
5252 (uri (pypi-uri "flake8" version))
5253 (sha256
5254 (base32
5255 "1r9wsry4va45h1rck5hxd3vzsg2q3y6lnl6pym1bxvz8ry19jwx8"))))))
5256
5257(define-public python2-flake8-2.2.4
5258 (package-with-python2 python-flake8-2.2.4))
5259
61b9ac53
FB
5260(define-public python-mistune
5261 (package
5262 (name "python-mistune")
5263 (version "0.7")
5264 (source
5265 (origin
5266 (method url-fetch)
5267 (uri (string-append
5268 "https://pypi.python.org/packages/source/m/mistune/mistune-"
5269 version
5270 ".tar.gz"))
5271 (sha256
5272 (base32
5273 "17zqjp9m4d1w3jf2rbbq5xshcw24q1vlcv24gkgfqqyyymajxahx"))))
5274 (build-system python-build-system)
5275 (inputs
5276 `(("python-setuptools" ,python-setuptools)
5277 ("python-nose" ,python-nose)
5278 ("python-cython" ,python-cython)))
5279 (home-page "https://github.com/lepture/mistune")
5280 (synopsis "Markdown parser in pure Python")
5281 (description "This package provides a fast markdown parser in pure
5282Python.")
5283 (license bsd-3)))
5284
5285(define-public python2-mistune
5286 (package-with-python2 python-mistune))
6d992d07 5287
b9893908
EE
5288(define-public python-markdown
5289 (package
5290 (name "python-markdown")
5291 (version "2.6.5")
5292 (source
5293 (origin
5294 (method url-fetch)
5295 (uri (pypi-uri "Markdown" version))
5296 (sha256
5297 (base32
5298 "0q758a3fiiawr20b3hhjfs677cwj6xi284yb7xspcvv0fdicz54d"))))
5299 (build-system python-build-system)
5300 (arguments
5301 `(#:phases
5302 (modify-phases %standard-phases
5303 (replace 'check
5304 (lambda _
5305 (zero? (system* "python" "run-tests.py")))))))
5306 (native-inputs
5307 `(("python-nose" ,python-nose)
5308 ("python-pyyaml" ,python-pyyaml)))
5309 (home-page "https://pythonhosted.org/Markdown/")
5310 (synopsis "Python implementation of Markdown")
5311 (description
5312 "This package provides a Python implementation of John Gruber's
5313Markdown. The library features international input, various Markdown
5314extensions, and several HTML output formats. A command line wrapper
5315markdown_py is also provided to convert Markdown files to HTML.")
5316 (license bsd-3)))
5317
5318(define-public python2-markdown
5319 (package-with-python2 python-markdown))
5320
6d992d07
FB
5321(define-public python-ptyprocess
5322 (package
5323 (name "python-ptyprocess")
5324 (version "0.5")
5325 (source
5326 (origin
5327 (method url-fetch)
5328 (uri (string-append
5329 "https://pypi.python.org/packages/source/p/ptyprocess/ptyprocess-"
5330 version ".tar.gz"))
5331 (sha256
5332 (base32
5333 "0nggns5kikn32yyda2zrj1xdmh49pi3v0drggcdwljbv36r8zdyw"))))
5334 (build-system python-build-system)
5335 (inputs
5336 `(("python-setuptools" ,python-setuptools)
5337 ("python-nose" ,python-nose)))
5338 (arguments
5339 `(#:phases
5340 (modify-phases %standard-phases
5341 (replace 'check
5342 (lambda _
5343 (zero? (system* "nosetests")))))))
5344 (home-page "https://github.com/pexpect/ptyprocess")
5345 (synopsis "Run a subprocess in a pseudo terminal")
5346 (description
5347 "This package provides a Python library used to launch a subprocess in a
5348pseudo terminal (pty), and interact with both the process and its pty.")
5349 (license isc)))
5350
5351(define-public python2-ptyprocess
5352 (package-with-python2 python-ptyprocess))
4aadb1df
FB
5353
5354(define-public python-terminado
5355 (package
5356 (name "python-terminado")
783fb0a3 5357 (version "0.6")
4aadb1df
FB
5358 (source
5359 (origin
5360 (method url-fetch)
783fb0a3 5361 (uri (pypi-uri "terminado" version))
4aadb1df
FB
5362 (sha256
5363 (base32
783fb0a3 5364 "09h1kwi86g5mrk14s4pgbhshd602zry29lnpxamcqz864kva22rc"))))
4aadb1df
FB
5365 (build-system python-build-system)
5366 (propagated-inputs
5367 `(("python-tornado" ,python-tornado)
5368 ("python-ptyprocess" ,python-ptyprocess)))
783fb0a3
EF
5369 (native-inputs
5370 `(("python-nose" ,python-nose)))
4aadb1df
FB
5371 (arguments
5372 `(#:phases
5373 (modify-phases %standard-phases
5374 (replace 'check
5375 (lambda _
5376 (zero? (system* "nosetests")))))))
5377 (home-page "https://github.com/takluyver/terminado")
5378 (synopsis "Terminals served to term.js using Tornado websockets")
5379 (description "This package provides a Tornado websocket backend for the
5380term.js Javascript terminal emulator library.")
783fb0a3
EF
5381 (license bsd-2)
5382 (properties `((python2-variant . ,(delay python2-terminado))))))
4aadb1df
FB
5383
5384(define-public python2-terminado
783fb0a3 5385 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
4aadb1df 5386 (package (inherit terminado)
783fb0a3
EF
5387 (propagated-inputs
5388 `(("python2-backport-ssl-match-hostname"
5389 ,python2-backport-ssl-match-hostname)
5390 ,@(package-propagated-inputs terminado)))
5391 (native-inputs
5392 `(("python2-setuptools" ,python2-setuptools)
5393 ,@(package-native-inputs terminado))))))
5faa5ce4 5394
d582eaac
SB
5395(define-public python-fonttools
5396 (package
5397 (name "python-fonttools")
5398 (version "2.5")
5399 (source (origin
5400 (method url-fetch)
5401 (uri (string-append
5402 "https://pypi.python.org/packages/source/F/FontTools/"
5403 "fonttools-" version ".tar.gz"))
5404 (sha256
5405 (base32
5406 "08ay3x4ijarwhl60gqx2i9jzq6pxs20p4snc2d1q5jagh4rn39lb"))))
5407 (build-system python-build-system)
5408 (arguments '(#:test-target "check"))
5409 (propagated-inputs
5410 ;; XXX: module not found if setuptools is not available.
5411 `(("python-setuptools" ,python-setuptools)))
5412 (home-page "http://github.com/behdad/fonttools")
5413 (synopsis "Tools to manipulate font files")
5414 (description
5415 "FontTools/TTX is a library to manipulate font files from Python. It
5416supports reading and writinfg of TrueType/OpenType fonts, reading and writing
5417of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
5418also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
5419from an XML-based format.")
5420 (license (non-copyleft "file://LICENSE.txt"
5421 "See LICENSE.txt in the distribution."))))
5422
5423(define-public python2-fonttools
5424 (package-with-python2 python-fonttools))
75710da6 5425
5faa5ce4
RW
5426(define-public python-ly
5427 (package
5428 (name "python-ly")
5135354f 5429 (version "0.9.4")
5faa5ce4
RW
5430 (source
5431 (origin
5432 (method url-fetch)
5135354f
RW
5433 (uri (string-append "https://pypi.python.org/packages/57/4f/"
5434 "889579244947368f28eda66b782331b1e75f83fd72e63f9ece93cd7a18f9"
5435 "/python-ly-" version ".tar.gz"))
5faa5ce4
RW
5436 (sha256
5437 (base32
5135354f 5438 "0g6n288l83sfwavxh1aryi0aqvsr3sp7v6f903mckwqa4scpky62"))))
5faa5ce4
RW
5439 (build-system python-build-system)
5440 (native-inputs
5441 `(("python-setuptools" ,python-setuptools)))
5442 (synopsis "Tool and library for manipulating LilyPond files")
5443 (description "This package provides a Python library to parse, manipulate
5444or create documents in LilyPond format. A command line program ly is also
5445provided that can be used to do various manipulations with LilyPond files.")
5446 (home-page "https://pypi.python.org/pypi/python-ly")
5447 (license gpl2+)))
7e7b27d9
CR
5448
5449(define-public python-appdirs
5450 (package
5451 (name "python-appdirs")
5452 (version "1.4.0")
5453 (source
5454 (origin
5455 (method url-fetch)
5456 (uri (string-append
5457 "https://pypi.python.org/packages/source/a/appdirs/appdirs-"
5458 version
5459 ".tar.gz"))
5460 (sha256
5461 (base32
5462 "1iddva7v3fq0aqzsahkazxr7vpw28mqcrsy818z4wyiqnkplbhlg"))))
5463 (build-system python-build-system)
5464 (inputs
5465 `(("python-setuptools" ,python-setuptools)))
5466 (home-page "http://github.com/ActiveState/appdirs")
5467 (synopsis
5468 "Determine platform-specific dirs, e.g. a \"user data dir\"")
5469 (description
5470 "This module provides a portable way of finding out where user data
5471should be stored on various operating systems.")
5472 (license license:expat)))
5473
5474(define-public python2-appdirs
5475 (package-with-python2 python-appdirs))
89b2e0b0
LF
5476
5477(define-public python-llfuse
5478 (package
5479 (name "python-llfuse")
10240c7c 5480 (version "1.1")
89b2e0b0
LF
5481 (source (origin
5482 (method url-fetch)
5483 (uri (string-append
5484 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5485 "llfuse-" version ".tar.bz2"))
5486 (sha256
5487 (base32
10240c7c 5488 "1ywzbqkahrfl9kkcasxrmgilv6fybapvh6pqvimimnfh7sgxal72"))))
89b2e0b0
LF
5489 (build-system python-build-system)
5490 (inputs
5491 `(("fuse" ,fuse)
5492 ("attr" ,attr)))
5493 (native-inputs
5494 `(("pkg-config" ,pkg-config)
5495 ("python-setuptools" ,python-setuptools)))
5496 (synopsis "Python bindings for FUSE")
5497 (description
5498 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
5499 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
cd0569c4
LF
5500 (license lgpl2.0+)
5501 (properties `((python2-variant . ,(delay python2-llfuse))))))
89b2e0b0
LF
5502
5503(define-public python2-llfuse
cd0569c4
LF
5504 (package (inherit (package-with-python2
5505 (strip-python2-variant python-llfuse)))
5506 (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2)))))
5507
5508;; For attic-0.16
5509(define-public python-llfuse-0.41
5510 (package (inherit python-llfuse)
229b3661 5511 (version "0.41.1")
cd0569c4
LF
5512 (source (origin
5513 (method url-fetch)
5514 (uri (string-append
5515 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5516 "llfuse-" version ".tar.bz2"))
5517 (sha256
5518 (base32
229b3661 5519 "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa"))))
cd0569c4
LF
5520 ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat)
5521 ;; licensed. The rest of the package is licensed under LGPL2.0 or later.
5522 (license (list license:expat lgpl2.0+))))
641c9871
LF
5523
5524(define-public python-msgpack
5525 (package
5526 (name "python-msgpack")
ae831df4 5527 (version "0.4.7")
641c9871
LF
5528 (source (origin
5529 (method url-fetch)
ae831df4 5530 (uri (pypi-uri "msgpack-python" version))
641c9871
LF
5531 (sha256
5532 (base32
ae831df4 5533 "0syd7bs83qs9qmxw540jbgsildbqk4yb57fmrlns1021llli402y"))))
641c9871 5534 (build-system python-build-system)
641c9871
LF
5535 (synopsis "MessagePack (de)serializer")
5536 (description "MessagePack is a fast, compact binary serialization format,
5537suitable for similar data to JSON. This package provides CPython bindings for
5538reading and writing MessagePack data.")
5539 (home-page "https://pypi.python.org/pypi/msgpack-python/")
bd74be7b
LF
5540 (license asl2.0)
5541 (properties `((python2-variant . ,(delay python2-msgpack))))))
5542
5543(define-public python2-msgpack
5544 (package (inherit (package-with-python2
5545 (strip-python2-variant python-msgpack)))
5546 (native-inputs
5547 `(("python2-setuptools" ,python2-setuptools)))))
641c9871
LF
5548
5549(define-public python2-msgpack
5550 (package-with-python2 python-msgpack))
6e5e39f4
CR
5551
5552(define-public python-netaddr
5553 (package
5554 (name "python-netaddr")
5555 (version "0.7.18")
5556 (source
5557 (origin
5558 (method url-fetch)
5559 (uri (string-append
5560 "https://pypi.python.org/packages/source/n/netaddr/netaddr-"
5561 version
5562 ".tar.gz"))
5563 (sha256
5564 (base32
5565 "06dxjlbcicq7q3vqy8agq11ra01kvvd47j4mk6dmghjsyzyckxd1"))))
5566 (build-system python-build-system)
5567 (arguments `(#:tests? #f)) ;; No tests.
5568 (inputs
5569 `(("python-setuptools" ,python-setuptools)))
5570 (home-page "https://github.com/drkjam/netaddr/")
5571 (synopsis "Pythonic manipulation of network addresses")
5572 (description
5573 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
5574and MAC network addresses.")
5575 (license bsd-3)))
5576
5577(define-public python2-netaddr
5578 (package-with-python2 python-netaddr))
8c692a52
CR
5579
5580(define-public python-wrapt
5581 (package
5582 (name "python-wrapt")
5583 (version "1.10.5")
5584 (source
5585 (origin
5586 (method url-fetch)
5587 (uri (string-append
5588 "https://pypi.python.org/packages/source/w/wrapt/wrapt-"
5589 version
5590 ".tar.gz"))
5591 (sha256
5592 (base32
5593 "0cq8rlpzkxzk48b50yrfhzn1d1hrq4gjcdqlrgq4v5palgiv9jwr"))))
5594 (build-system python-build-system)
5595 (arguments
5596 ;; Tests are not included in the tarball, they are only available in the
5597 ;; git repository.
5598 `(#:tests? #f))
5599 (inputs
5600 `(("python-setuptools" ,python-setuptools)))
5601 (home-page "https://github.com/GrahamDumpleton/wrapt")
5602 (synopsis "Module for decorators, wrappers and monkey patching")
5603 (description
5604 "The aim of the wrapt module is to provide a transparent object proxy for
5605 Python, which can be used as the basis for the construction of function
5606 wrappers and decorator functions.")
5607 (license bsd-2)))
5608
5609(define-public python2-wrapt
5610 (package-with-python2 python-wrapt))
b85c85be
CR
5611
5612(define-public python-iso8601
5613 (package
5614 (name "python-iso8601")
5615 (version "0.1.10")
5616 (source
5617 (origin
5618 (method url-fetch)
5619 (uri (string-append
5620 "https://pypi.python.org/packages/source/i/iso8601/iso8601-"
5621 version
5622 ".tar.gz"))
5623 (sha256
5624 (base32
5625 "1qf01afxh7j4gja71vxv345if8avg6nnm0ry0zsk6j3030xgy4p7"))))
5626 (build-system python-build-system)
5627 (inputs
5628 `(("python-setuptools" ,python-setuptools)))
5629 (home-page "https://bitbucket.org/micktwomey/pyiso8601")
5630 (synopsis "Module to parse ISO 8601 dates")
5631 (description
5632 "This module parses the most common forms of ISO 8601 date strings (e.g.
5633@code{2007-01-14T20:34:22+00:00}) into @code{datetime} objects.")
5634 (license license:expat)))
5635
5636(define-public python2-iso8601
5637 (package-with-python2 python-iso8601))
5e412b63
CR
5638
5639(define-public python-monotonic
5640 (package
5641 (name "python-monotonic")
5642 (version "0.3")
5643 (source
5644 (origin
5645 (method url-fetch)
5646 (uri (string-append
5647 "https://pypi.python.org/packages/source/m/monotonic/monotonic-"
5648 version
5649 ".tar.gz"))
5650 (sha256
5651 (base32
5652 "0yz0bcbwx8r2c01czzfpbrxddynxyk9k95jj8h6sgcb7xmfvl998"))))
5653 (build-system python-build-system)
5654 (inputs
5655 `(("python-setuptools" ,python-setuptools)))
5656 (home-page "https://github.com/atdt/monotonic")
5657 (synopsis "Implementation of time.monotonic() for Python 2 & < 3.3")
5658 (description
5659 "This module provides a monotonic() function which returns the value (in
5660fractional seconds) of a clock which never goes backwards.")
5661 (license asl2.0)))
5662
5663(define-public python2-monotonic
5664 (package-with-python2 python-monotonic))
de34afac
CR
5665
5666(define-public python-webob
5667 (package
5668 (name "python-webob")
b8834c21 5669 (version "1.5.1")
de34afac
CR
5670 (source
5671 (origin
5672 (method url-fetch)
b8834c21 5673 (uri (pypi-uri "WebOb" version))
de34afac
CR
5674 (sha256
5675 (base32
b8834c21 5676 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
de34afac
CR
5677 (build-system python-build-system)
5678 (inputs
5679 `(("python-nose" ,python-nose)
5680 ("python-setuptools" ,python-setuptools)))
5681 (home-page "http://webob.org/")
5682 (synopsis "WSGI request and response object")
5683 (description
5684 "WebOb provides wrappers around the WSGI request environment, and an
5685object to help create WSGI responses.")
5686 (license license:expat)))
5687
5688(define-public python2-webob
5689 (package-with-python2 python-webob))
350ba0a3 5690
02a8a187
BW
5691(define-public python-xlrd
5692 (package
5693 (name "python-xlrd")
5694 (version "0.9.4")
5695 (source (origin
5696 (method url-fetch)
5697 (uri (string-append "https://pypi.python.org/packages/source/x/"
5698 "xlrd/xlrd-" version ".tar.gz"))
5699 (sha256
5700 (base32
5701 "0wpa55nvidmm5m2qr622dsh3cj46akdk0h3zjgzschcmydck73cf"))))
5702 (build-system python-build-system)
5703 (arguments
5704 `(#:phases
5705 (modify-phases %standard-phases
5706 ;; Current test in setup.py does not work as of 0.9.4, so use nose to
5707 ;; run tests instead for now.
5708 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
5709 (native-inputs `(("python-nose" ,python-nose)
5710 ("python-setuptools" ,python-setuptools)))
5711 (home-page "http://www.python-excel.org/")
5712 (synopsis "Library for extracting data from Excel files")
5713 (description "This packages provides a library to extract data from
5714spreadsheets using Microsoft Excel® proprietary file formats @samp{.xls} and
5715@samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
5716Unicode-aware. It is not intended as an end-user tool.")
5717 (license bsd-3)))
5718
5719(define-public python2-xlrd
5720 (package-with-python2 python-xlrd))
5721
350ba0a3
CR
5722(define-public python-prettytable
5723 (package
5724 (name "python-prettytable")
5725 (version "0.7.2")
5726 (source
5727 (origin
5728 (method url-fetch)
5729 (uri (string-append
5730 "https://pypi.python.org/packages/source/P/PrettyTable/"
5731 "prettytable-" version ".tar.bz2"))
5732 (sha256
5733 (base32
5734 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
5735 (build-system python-build-system)
5736 (inputs
5737 `(("python-setuptools" ,python-setuptools)))
5738 (home-page "http://code.google.com/p/prettytable/")
5739 (synopsis "Display tabular data in an ASCII table format")
5740 (description
5741 "A library designed to represent tabular data in visually appealing ASCII
5742tables. PrettyTable allows for selection of which columns are to be printed,
5743independent alignment of columns (left or right justified or centred) and
5744printing of sub-tables by specifying a row range.")
5745 (license bsd-3)))
5746
5747(define-public python2-prettytable
5748 (package-with-python2 python-prettytable))
7a8ac75a 5749
9f8ee3fe
RW
5750(define-public python-tables
5751 (package
5752 (name "python-tables")
5753 (version "3.2.2")
5754 (source
5755 (origin
5756 (method url-fetch)
5757 (uri (pypi-uri "tables" version))
5758 (sha256
5759 (base32
5760 "117s6w7s3yxafpmf3zz3svana7xfrsviw01va1xp7h8ylx8v6r1m"))))
5761 (build-system python-build-system)
5762 (arguments
5763 `(;; FIXME: python-build-system does not pass configure-flags to "build"
5764 ;; or "check", so we must override the build and check phases.
5765 #:phases
5766 (modify-phases %standard-phases
5767 (add-after 'unpack 'use-gcc
5768 (lambda _
5769 (substitute* "setup.py"
5770 (("compiler = new_compiler\\(\\)" line)
5771 (string-append line
5772 "\ncompiler.set_executables(compiler='gcc',"
5773 "compiler_so='gcc',"
5774 "linker_exe='gcc',"
5775 "linker_so='gcc -shared')")))
5776 #t))
5777 (replace 'build
5778 (lambda* (#:key inputs #:allow-other-keys)
5779 (zero? (system* "python" "setup.py" "build"
5780 (string-append "--hdf5="
5781 (assoc-ref inputs "hdf5"))))))
5782 (replace 'check
5783 (lambda* (#:key inputs #:allow-other-keys)
5784 (zero? (system* "python" "setup.py" "check"
5785 (string-append "--hdf5="
5786 (assoc-ref inputs "hdf5")))))))))
5787 (propagated-inputs
5788 `(("python-numexpr" ,python-numexpr)
5789 ("python-numpy" ,python-numpy)))
5790 (native-inputs
5791 `(("python-setuptools" ,python-setuptools)
5792 ("python-cython" ,python-cython)
5793 ("pkg-config" ,pkg-config)))
5794 (inputs
5795 `(("hdf5" ,hdf5)
5796 ("bzip2" ,bzip2)
5797 ("zlib" ,zlib)))
5798 (home-page "http://www.pytables.org/")
5799 (synopsis "Hierarchical datasets for Python")
5800 (description "PyTables is a package for managing hierarchical datasets and
5801designed to efficently cope with extremely large amounts of data.")
5802 (license bsd-3)))
5803
5804(define-public python2-tables
5805 (package-with-python2 python-tables))
5806
7a8ac75a
RW
5807(define-public python-pyasn1
5808 (package
5809 (name "python-pyasn1")
5810 (version "0.1.8")
5811 (source
5812 (origin
5813 (method url-fetch)
5814 (uri (string-append "https://pypi.python.org/packages/source/p/"
5815 "pyasn1/pyasn1-" version ".tar.gz"))
5816 (sha256
5817 (base32
5818 "0iw31d9l0zwx35szkzq72hiw002wnqrlrsi9dpbrfngcl1ybwcsx"))))
5819 (build-system python-build-system)
5820 (home-page "http://pyasn1.sourceforge.net/")
5821 (synopsis "ASN.1 types and codecs")
5822 (description
5823 "This is an implementation of ASN.1 types and codecs in Python. It is
5824suitable for a wide range of protocols based on the ASN.1 specification.")
5825 (license bsd-2)))
5826
5827(define-public python2-pyasn1
5828 (package-with-python2 python-pyasn1))
9a49a535 5829
5988c299
EF
5830(define-public python-pyasn1-modules
5831 (package
5832 (name "python-pyasn1-modules")
5833 (version "0.0.8")
5834 (source
5835 (origin
5836 (method url-fetch)
5837 (uri (pypi-uri "pyasn1-modules" version))
5838 (sha256
5839 (base32
5840 "0drqgw81xd3fxdlg89kgd79zzrabvfncvkbybi2wr6w2y4s1jmhh"))))
5841 (build-system python-build-system)
5842 (native-inputs
5843 `(("python-setuptools" ,python-setuptools)))
5844 (propagated-inputs
5845 `(("python-pyasn1" ,python-pyasn1)))
5846 (home-page "http://sourceforge.net/projects/pyasn1/")
5847 (synopsis "ASN.1 codec implementations")
5848 (description
5849 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
5850implementations of ASN.1-based codecs and protocols.")
5851 (license bsd-3)))
5852
5853(define-public python2-pyasn1-modules
5854 (package-with-python2 python-pyasn1-modules))
5855
9a49a535
RW
5856(define-public python2-ipaddress
5857 (package
5858 (name "python2-ipaddress")
5859 (version "1.0.14")
5860 (source
5861 (origin
5862 (method url-fetch)
5863 (uri (string-append "https://pypi.python.org/packages/source/i/"
5864 "ipaddress/ipaddress-" version ".tar.gz"))
5865 (sha256
5866 (base32
5867 "0givid4963n57nsjibms2fc347zmcs188q1hw9al1dkc9kj4nvr2"))))
5868 (build-system python-build-system)
5869 (arguments
5870 `(#:tests? #f ; no tests
5871 #:python ,python-2))
5872 (home-page "https://github.com/phihag/ipaddress")
5873 (synopsis "IP address manipulation library")
5874 (description
5875 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
5876in Python. This library is used to create, poke at, and manipulate IPv4 and
5877IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
5878module to older versions of Python.")
5879 (license psfl)))
3f00e078 5880
4a238186
HG
5881(define-public python2-ipaddr
5882 (package
5883 (name "python2-ipaddr")
5884 (version "2.1.11")
5885 (source
5886 (origin
5887 (method url-fetch)
5888 (uri (pypi-uri "ipaddr" version))
5889 (sha256
5890 (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v"))))
5891 (build-system python-build-system)
5892 (arguments
5893 `(#:python ,python-2 ;version 2 only
5894 #:phases
5895 (modify-phases %standard-phases
5896 (replace 'check
5897 (lambda* _
5898 (zero? (system* "python" "ipaddr_test.py")))))))
5899 (home-page "https://github.com/google/ipaddr-py")
5900 (synopsis "IP address manipulation library")
5901 (description
5902 "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and
5903IPv6 addresses and networks.
5904
5905For new implementations you may prefer to use the standard module
5906@code{ipaddress}, which was introduced in Python 3.3 and backported to older
5907versions of Python.")
5908 (license asl2.0)))
5909
3f00e078
RW
5910(define-public python-idna
5911 (package
5912 (name "python-idna")
5913 (version "2.0")
5914 (source
5915 (origin
5916 (method url-fetch)
5917 (uri (string-append "https://pypi.python.org/packages/source/i/"
5918 "idna/idna-" version ".tar.gz"))
5919 (sha256
5920 (base32
5921 "0frxgmgi234lr9hylg62j69j4ik5zhg0wz05w5dhyacbjfnrl68n"))))
5922 (build-system python-build-system)
5923 (native-inputs
5924 `(("python-setuptools" ,python-setuptools)))
5925 (home-page "https://github.com/kjd/idna")
5926 (synopsis "Internationalized domain names in applications")
5927 (description
5928 "This is a library to support the Internationalised Domain Names in
5929Applications (IDNA) protocol as specified in RFC 5891. This version of the
5930protocol is often referred to as “IDNA2008” and can produce different results
5931from the earlier standard from 2003. The library is also intended to act as a
5932suitable drop-in replacement for the “encodings.idna” module that comes with
5933the Python standard library but currently only supports the older 2003
5934specification.")
5935 (license bsd-4)))
5936
5937(define-public python2-idna
5938 (package-with-python2 python-idna))
36ebf972
RW
5939
5940(define-public python-pretend
5941 (package
5942 (name "python-pretend")
5943 (version "1.0.8")
5944 (source
5945 (origin
5946 (method url-fetch)
5947 (uri (string-append "https://pypi.python.org/packages/source/p/"
5948 "pretend/pretend-" version ".tar.gz"))
5949 (sha256
5950 (base32
5951 "0r5r7ygz9m6d2bklflbl84cqhjkc2q12xgis8268ygjh30g2q3wk"))))
5952 (build-system python-build-system)
5953 (native-inputs
5954 `(("python-setuptools" ,python-setuptools)))
5955 (home-page "https://github.com/alex/pretend")
5956 (synopsis "Library for stubbing in Python")
5957 (description
5958 "Pretend is a library to make stubbing with Python easier. Stubbing is a
5959technique for writing tests. You may hear the term mixed up with mocks,
5960fakes, or doubles. Basically, a stub is an object that returns pre-canned
5961responses, rather than doing any computation.")
5962 (license bsd-3)))
5963
5964(define-public python2-pretend
5965 (package-with-python2 python-pretend))
aa759a51
RW
5966
5967(define-public python-cryptography-vectors
5968 (package
5969 (name "python-cryptography-vectors")
9c509ca9 5970 (version "1.3.4")
aa759a51
RW
5971 (source
5972 (origin
5973 (method url-fetch)
9c509ca9 5974 (uri (pypi-uri "cryptography_vectors" version))
aa759a51
RW
5975 (sha256
5976 (base32
9c509ca9 5977 "15h1iz2klnpb4f8djxy7cpbnyn3wbjp7bnj4pz6s7w6plghbq524"))))
aa759a51
RW
5978 (build-system python-build-system)
5979 (native-inputs
5980 `(("python-setuptools" ,python-setuptools)))
5981 (home-page "https://github.com/pyca/cryptography")
5982 (synopsis "Test vectors for the cryptography package.")
5983 (description
5984 "This package contains test vectors for the cryptography package.")
5985 ;; Distributed under either BSD-3 or ASL2.0
5986 (license (list bsd-3 asl2.0))))
5987
5988(define-public python2-cryptography-vectors
5989 (package-with-python2 python-cryptography-vectors))
88b47cb0
RW
5990
5991(define-public python-cryptography
5992 (package
5993 (name "python-cryptography")
9c509ca9 5994 (version "1.3.4")
88b47cb0
RW
5995 (source
5996 (origin
5997 (method url-fetch)
9c509ca9 5998 (uri (pypi-uri "cryptography" version))
88b47cb0
RW
5999 (sha256
6000 (base32
9c509ca9 6001 "1a85l548w5vvq3yhz0az7ajg2ijixzp6gagapw6wgrqvq28ghgs2"))))
88b47cb0
RW
6002 (build-system python-build-system)
6003 (inputs
6004 `(("openssl" ,openssl)))
6005 (propagated-inputs
6006 `(("python-cffi" ,python-cffi)
6007 ("python-six" ,python-six)
6008 ("python-pyasn1" ,python-pyasn1)
88b47cb0
RW
6009 ("python-idna" ,python-idna)
6010 ("python-iso8601" ,python-iso8601)))
6011 (native-inputs
6012 `(("python-cryptography-vectors" ,python-cryptography-vectors)
ce6c13ee 6013 ("python-hypothesis" ,python-hypothesis)
88b47cb0
RW
6014 ("python-setuptools" ,python-setuptools)
6015 ("python-pretend" ,python-pretend)
ce6c13ee
EF
6016 ("python-pyasn1" ,python-pyasn1)
6017 ("python-pyasn1-modules" ,python-pyasn1-modules)
88b47cb0
RW
6018 ("python-pytest" ,python-pytest)))
6019 (home-page "https://github.com/pyca/cryptography")
6020 (synopsis "Cryptographic recipes and primitives for Python")
6021 (description
6022 "cryptography is a package which provides cryptographic recipes and
6023primitives to Python developers. It aims to be the “cryptographic standard
6024library” for Python. The package includes both high level recipes, and low
6025level interfaces to common cryptographic algorithms such as symmetric ciphers,
6026message digests and key derivation functions.")
6027 ;; Distributed under either BSD-3 or ASL2.0
519e2f4f
LF
6028 (license (list bsd-3 asl2.0))
6029 (properties `((python2-variant . ,(delay python2-cryptography))))))
88b47cb0
RW
6030
6031(define-public python2-cryptography
519e2f4f
LF
6032 (let ((crypto (package-with-python2
6033 (strip-python2-variant python-cryptography))))
88b47cb0
RW
6034 (package (inherit crypto)
6035 (propagated-inputs
6036 `(("python2-ipaddress" ,python2-ipaddress)
ce6c13ee
EF
6037 ("python2-backport-ssl-match-hostname"
6038 ,python2-backport-ssl-match-hostname)
68f1cdec 6039 ("python2-enum34" ,python2-enum34)
88b47cb0 6040 ,@(package-propagated-inputs crypto))))))
5af999b8
RW
6041
6042(define-public python-pyopenssl
6043 (package
6044 (name "python-pyopenssl")
2fc629dd 6045 (version "16.0.0")
5af999b8
RW
6046 (source
6047 (origin
6048 (method url-fetch)
6049 (uri (string-append "https://pypi.python.org/packages/source/p/"
6050 "pyOpenSSL/pyOpenSSL-" version ".tar.gz"))
6051 (sha256
6052 (base32
2fc629dd 6053 "0zfijaxlq4vgi6jz0d4i5xq9ygqnyps6br7lmigjhqnh8gp10g9n"))))
5af999b8 6054 (build-system python-build-system)
5af999b8
RW
6055 (propagated-inputs
6056 `(("python-cryptography" ,python-cryptography)
6057 ("python-six" ,python-six)))
6058 (inputs
6059 `(("openssl" ,openssl)))
6060 (native-inputs
6061 `(("python-setuptools" ,python-setuptools)))
6062 (home-page "https://github.com/pyca/pyopenssl")
6063 (synopsis "Python wrapper module around the OpenSSL library")
6064 (description
6065 "PyOpenSSL is a high-level wrapper around a subset of the OpenSSL
6066library.")
6067 (license asl2.0)))
6068
6069(define-public python2-pyopenssl
519e2f4f 6070 (package-with-python2 python-pyopenssl))
643725a1
CR
6071
6072(define-public python-pip
6073 (package
6074 (name "python-pip")
6fb54e3b 6075 (version "8.0.2")
643725a1
CR
6076 (source
6077 (origin
6078 (method url-fetch)
6fb54e3b 6079 (uri (pypi-uri "pip" version))
643725a1
CR
6080 (sha256
6081 (base32
6fb54e3b 6082 "08cm8d4228fj0qnrysy3qv1a6022zr3dcs25amd14lgxil6vvx26"))))
643725a1
CR
6083 (build-system python-build-system)
6084 (inputs
6085 `(("python-setuptools" ,python-setuptools)
6086 ("python-virtualenv" ,python-virtualenv)
6087 ;; Tests
6088 ("python-mock" ,python-mock)
6089 ("python-pytest" ,python-pytest)
6090 ("python-scripttest" ,python-scripttest)))
6091 (home-page "https://pip.pypa.io/")
6092 (synopsis
6093 "Package manager for Python software")
6094 (description
6095 "Pip is a package manager for Python software, that finds packages on the
6096Python Package Index (PyPI).")
6097 (license license:expat)))
6098
6099(define-public python2-pip
6100 (package-with-python2 python-pip))
d8c4998f
LC
6101
6102(define-public python-tlsh
6103 (package
6104 (name "python-tlsh")
99b00dc7 6105 (version "3.4.4")
d8c4998f
LC
6106 (home-page "https://github.com/trendmicro/tlsh")
6107 (source (origin
99b00dc7
EF
6108 (method url-fetch)
6109 (uri (string-append "https://github.com/trendmicro/tlsh/archive/v"
6110 version ".tar.gz"))
d8c4998f
LC
6111 (sha256
6112 (base32
99b00dc7
EF
6113 "00bhzjqrlh7v538kbkbn8lgx976j1138al3sdhklaizqjvpwyk4r"))
6114 (file-name (string-append name "-" version ".tar.gz"))))
d8c4998f
LC
6115 (build-system cmake-build-system)
6116 (arguments
6117 '(#:out-of-source? #f
6118 #:phases (modify-phases %standard-phases
6119 (replace
6120 'install
6121 (lambda* (#:key outputs #:allow-other-keys)
6122 ;; Build and install the Python bindings. The underlying
6123 ;; C++ library is apparently not meant to be installed.
6124 (let ((out (assoc-ref outputs "out")))
6125 (with-directory-excursion "py_ext"
6126 (and (system* "python" "setup.py" "build")
6127 (system* "python" "setup.py" "install"
6128 (string-append "--prefix=" out))))))))))
6129 (inputs `(("python" ,python-wrapper))) ;for the bindings
6130 (synopsis "Fuzzy matching library for Python")
6131 (description
6132 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
6133Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
6134value which can be used for similarity comparisons. Similar objects have
6135similar hash values, which allows for the detection of similar objects by
6136comparing their hash values. The byte stream should have a sufficient amount
6137of complexity; for example, a byte stream of identical bytes will not generate
6138a hash value.")
6139 (license asl2.0)))
6140
6141(define-public python2-tlsh
6142 (package
6143 (inherit python-tlsh)
6144 (name "python2-tlsh")
6145 (inputs `(("python" ,python-2)))))
d96034ed
LC
6146
6147(define-public python-libarchive-c
6148 (package
6149 (name "python-libarchive-c")
03fd001c 6150 (version "2.2")
d96034ed
LC
6151 (source (origin
6152 (method url-fetch)
03fd001c 6153 (uri (pypi-uri "libarchive-c" version))
d96034ed
LC
6154 (sha256
6155 (base32
03fd001c 6156 "0z4r7v3dhd6b3120mav05ff08srih176r2rg5k8kn7mjd9pslm2x"))))
d96034ed
LC
6157 (build-system python-build-system)
6158 (arguments
6159 '(#:phases (modify-phases %standard-phases
6160 (add-before
6161 'build 'reference-libarchive
6162 (lambda* (#:key inputs #:allow-other-keys)
6163 ;; Retain the absolute file name of libarchive.so.
6164 (let ((libarchive (assoc-ref inputs "libarchive")))
6165 (substitute* "libarchive/ffi.py"
6166 (("find_library\\('archive'\\)")
6167 (string-append "'" libarchive
6168 "/lib/libarchive.so'"))))
6169
6170 ;; Do not make a compressed egg (see
6171 ;; <http://bugs.gnu.org/20765>).
6172 (let ((port (open-file "setup.cfg" "a")))
6173 (display "\n[easy_install]\nzip_ok = 0\n"
6174 port)
6175 (close-port port)
6176 #t))))))
6177 (inputs
6178 `(("python-setuptools" ,python-setuptools)
6179 ("libarchive" ,libarchive)))
6180 (home-page "https://github.com/Changaco/python-libarchive-c")
6181 (synopsis "Python interface to libarchive")
6182 (description
6183 "This package provides Python bindings to libarchive, a C library to
6184access possibly compressed archives in many different formats. It uses
6185Python's @code{ctypes} foreign function interface (FFI).")
6186 (license lgpl2.0+)))
6187
6188(define-public python2-libarchive-c
6189 (package-with-python2 python-libarchive-c))
5e1c9367
LC
6190
6191(define-public python-file
6192 (package
6193 (inherit file)
6194 (name "python-file")
6195 (build-system python-build-system)
6196 (arguments
6197 '(#:tests? #f ;no tests
6198 #:phases (modify-phases %standard-phases
6199 (add-before 'build 'change-directory
6200 (lambda _
6201 (chdir "python")
6202 #t))
6203 (add-before 'build 'set-library-file-name
6204 (lambda* (#:key inputs #:allow-other-keys)
6205 (let ((file (assoc-ref inputs "file")))
6206 (substitute* "magic.py"
6207 (("find_library\\('magic'\\)")
6208 (string-append "'" file "/lib/libmagic.so'")))
6209 #t))))))
6210 (inputs `(("file" ,file)))
6211 (self-native-input? #f)
daeeea71
CM
6212 (synopsis "Python bindings to the libmagic file type guesser. Note that
6213this module and the python-magic module both provide a \"magic.py\" file;
6214these two modules, which are different and were developed separately, both
6215serve the same purpose: provide Python bindings for libmagic.")))
5e1c9367
LC
6216
6217(define-public python2-file
6218 (package-with-python2 python-file))
85d4aeac
LC
6219
6220(define-public python-debian
6221 (package
6222 (name "python-debian")
6223 (version "0.1.23")
6224 (source
6225 (origin
6226 (method url-fetch)
6227 (uri (string-append
6228 "https://pypi.python.org/packages/source/p/python-debian/python-debian-"
6229 version ".tar.gz"))
6230 (sha256
6231 (base32
6232 "193faznwnjc3n5991wyzim6h9gyq1zxifmfrnpm3avgkh7ahyynh"))))
6233 (build-system python-build-system)
6234 (inputs
6235 `(("python-six" ,python-six)))
6236 (native-inputs
6237 `(("python-setuptools" ,python-setuptools)))
6238 (home-page "http://packages.debian.org/sid/python-debian")
6239 (synopsis "Debian package related modules")
6240 (description
5c7bdc9a
LC
6241 ;; XXX: Use @enumerate instead of @itemize to work around
6242 ;; <http://bugs.gnu.org/21772>.
85d4aeac
LC
6243 "This package provides Python modules that abstract many formats of
6244Debian-related files, such as:
6245
5c7bdc9a 6246@enumerate
85d4aeac
LC
6247@item Debtags information;
6248@item @file{debian/changelog} files;
6249@item packages files, pdiffs;
6250@item control files of single or multiple RFC822-style paragraphs---e.g.
6251 @file{debian/control}, @file{.changes}, @file{.dsc};
6252@item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
6253 contained files and meta-information.
5c7bdc9a 6254@end enumerate\n")
85d4aeac
LC
6255
6256 ;; Modules are either GPLv2+ or GPLv3+.
6257 (license gpl3+)))
6258
6259(define-public python2-debian
6260 (package-with-python2 python-debian))
816a6538
LC
6261
6262(define-public python-chardet
6263 (package
6264 (name "python-chardet")
6265 (version "2.3.0")
6266 (source
6267 (origin
6268 (method url-fetch)
6269 (uri (string-append
6270 "https://pypi.python.org/packages/source/c/chardet/chardet-"
6271 version
6272 ".tar.gz"))
6273 (sha256
6274 (base32
6275 "1ak87ikcw34fivcgiz2xvi938dmclh078az65l9x3rmgljrkhgp5"))))
6276 (build-system python-build-system)
6277 (native-inputs
6278 `(("python-setuptools" ,python-setuptools)))
6279 (home-page "https://github.com/chardet/chardet")
6280 (synopsis "Universal encoding detector for Python 2 and 3")
6281 (description
6282 "This package provides @code{chardet}, a Python module that can
6283automatically detect a wide range of file encodings.")
6284 (license lgpl2.1+)))
6285
6286(define-public python2-chardet
6287 (package-with-python2 python-chardet))
2fc5f186 6288
1872f1bb
KM
6289(define-public python-docopt
6290 (package
6291 (name "python-docopt")
6292 (version "0.6.2")
6293 (source
6294 (origin
6295 (method url-fetch)
6296 ;; The release on PyPI does not include tests.
6297 (uri (string-append
6298 "https://github.com/docopt/docopt/archive/"
6299 version ".tar.gz"))
6300 (file-name (string-append name "-" version ".tar.gz"))
6301 (sha256
6302 (base32
6303 "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1"))))
6304 (build-system python-build-system)
6305 (native-inputs
6306 `(("python-pytest" ,python-pytest)
6307 ("python-setuptools" ,python-setuptools)))
6308 (arguments
6309 `(#:phases (alist-replace
6310 'check
6311 (lambda _ (zero? (system* "py.test")))
6312 %standard-phases)))
6313 (home-page "http://docopt.org")
6314 (synopsis "Command-line interface description language for Python")
6315 (description "This library allows the user to define a command-line
6316interface from a program's help message rather than specifying it
6317programatically with command-line parsers like @code{getopt} and
6318@code{argparse}.")
6319 (license license:expat)))
6320
6321(define-public python2-docopt
6322 (package-with-python2 python-docopt))
6323
2fc5f186
LF
6324(define-public python-zope-event
6325 (package
6326 (name "python-zope-event")
6327 (version "4.1.0")
6328 (source
6329 (origin
6330 (method url-fetch)
6331 (uri (string-append "https://pypi.python.org/packages/source/z"
6332 "/zope.event/zope.event-" version ".tar.gz"))
6333 (sha256
6334 (base32
6335 "11p75zpfz3ffhz21nzx9wb23xs993ck5s6hkjcvhswwizni5jynw"))))
6336 (build-system python-build-system)
6337 (inputs
6338 `(("python-setuptools" ,python-setuptools)))
6339 (home-page "http://pypi.python.org/pypi/zope.event")
6340 (synopsis "Event publishing system for Python")
6341 (description "Zope.event provides an event publishing API, intended for
6342use by applications which are unaware of any subscribers to their events. It
6343is a simple event-dispatching system on which more sophisticated event
6344dispatching systems can be built.")
6345 (license zpl2.1)))
6346
6347(define-public python2-zope-event
6348 (package-with-python2 python-zope-event))
97abe268
LF
6349
6350(define-public python-zope-interface
6351 (package
6352 (name "python-zope-interface")
6353 (version "4.1.3")
6354 (source
6355 (origin
6356 (method url-fetch)
6357 (uri (string-append "https://pypi.python.org/packages/source/z"
6358 "/zope.interface/zope.interface-" version ".tar.gz"))
6359 (sha256
6360 (base32
6361 "0ks8h73b2g4bkad821qbv0wzjppdrwys33i7ka45ik3wxjg1l8if"))))
6362 (build-system python-build-system)
6363 (propagated-inputs
6364 `(("python-zope-event" ,python-zope-event)))
6365 (home-page "https://github.com/zopefoundation/zope.interface")
6366 (synopsis "Python implementation of the \"design by contract\"
6367methodology")
6368 (description "Zope.interface provides an implementation of \"object
6369interfaces\" for Python. Interfaces are a mechanism for labeling objects as
6370conforming to a given API or contract.")
6371 (license zpl2.1)))
6372
6373(define-public python2-zope-interface
6374 (package-with-python2 python-zope-interface))
81f2373c
LF
6375
6376(define-public python-zope-exceptions
6377 (package
6378 (name "python-zope-exceptions")
6379 (version "4.0.8")
6380 (source
6381 (origin
6382 (method url-fetch)
6383 (uri (string-append "https://pypi.python.org/packages/source/z"
6384 "/zope.exceptions/zope.exceptions-"
6385 version ".tar.gz"))
6386 (sha256
6387 (base32
6388 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
6389 (build-system python-build-system)
6390 (arguments
6391 '(#:tests? #f)) ; circular dependency with zope.testrunner
6392 (propagated-inputs
6393 `(("python-zope-interface" ,python-zope-interface)))
6394 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
6395 (synopsis "Zope exceptions")
6396 (description "Zope.exceptions provides general-purpose exception types
6397that have uses outside of the Zope framework.")
6398 (license zpl2.1)))
6399
6400(define-public python2-zope-exceptions
6401 (package-with-python2 python-zope-exceptions))
900e3c0e
LF
6402
6403(define-public python-zope-testing
6404 (package
6405 (name "python-zope-testing")
6406 (version "4.5.0")
6407 (source
6408 (origin
6409 (method url-fetch)
6410 (uri (string-append "https://pypi.python.org/packages/source/z"
6411 "/zope.testing/zope.testing-" version ".tar.gz"))
6412 (sha256
6413 (base32
6414 "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))))
6415 (build-system python-build-system)
6416 (native-inputs
6417 `(("python-zope-exceptions" ,python-zope-exceptions)))
6418 (propagated-inputs
6419 `(("python-zope-interface" ,python-zope-interface)))
6420 (home-page "http://pypi.python.org/pypi/zope.testing")
6421 (synopsis "Zope testing helpers")
6422 (description "Zope.testing provides a number of testing utilities for HTML
6423forms, HTTP servers, regular expressions, and more.")
6424 (license zpl2.1)))
6425
6426(define-public python2-zope-testing
6427 (package-with-python2 python-zope-testing))
01614c4f
LF
6428
6429(define-public python-zope-testrunner
6430 (package
6431 (name "python-zope-testrunner")
6432 (version "4.4.9")
6433 (source
6434 (origin
6435 (method url-fetch)
6436 (uri (string-append "https://pypi.python.org/packages/source/z"
6437 "/zope.testrunner/zope.testrunner-"
6438 version ".zip"))
6439 (sha256
6440 (base32
6441 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
6442 (build-system python-build-system)
6443 (native-inputs
6444 `(("python-six" ,python-six)
6445 ("python-zope-exceptions" ,python-zope-exceptions)
6446 ("python-zope-testing" ,python-zope-testing)
6447 ("unzip" ,unzip)))
6448 (propagated-inputs
6449 `(("python-zope-interface" ,python-zope-interface)))
6450 (home-page "http://pypi.python.org/pypi/zope.testrunner")
6451 (synopsis "Zope testrunner script")
6452 (description "Zope.testrunner provides a script for running Python
6453tests.")
6454 (license zpl2.1)))
6455
6456(define-public python2-zope-testrunner
6457 (let ((base (package-with-python2 python-zope-testrunner)))
6458 (package
6459 (inherit base)
6460 (native-inputs
6461 (append (package-native-inputs base)
6462 `(("python2-subunit" ,python2-subunit)
6463 ("python2-mimeparse" ,python2-mimeparse)))))))
6a5c710c
LF
6464
6465(define-public python-zope-i18nmessageid
6466 (package
6467 (name "python-zope-i18nmessageid")
6468 (version "4.0.3")
6469 (source
6470 (origin
6471 (method url-fetch)
6472 (uri (string-append
6473 "https://pypi.python.org/packages/source/z"
6474 "/zope.i18nmessageid/zope.i18nmessageid-"
6475 version ".tar.gz"))
6476 (sha256
6477 (base32
6478 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
6479 (build-system python-build-system)
6480 (inputs
6481 `(("python-setuptools" ,python-setuptools)))
6482 (home-page "http://pypi.python.org/pypi/zope.i18nmessageid")
6483 (synopsis "Message identifiers for internationalization")
6484 (description "Zope.i18nmessageid provides facilities for declaring
6485internationalized messages within program source text.")
6486 (license zpl2.1)))
6487
6488(define-public python2-zope-i18nmessageid
6489 (package-with-python2 python-zope-i18nmessageid))
71fb09f3
LF
6490
6491(define-public python-zope-schema
6492 (package
6493 (name "python-zope-schema")
6494 (version "4.4.2")
6495 (source
6496 (origin
6497 (method url-fetch)
6498 (uri (string-append "https://pypi.python.org/packages/source/z"
6499 "/zope.schema/zope.schema-" version ".tar.gz"))
6500 (sha256
6501 (base32
6502 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
6503 (build-system python-build-system)
6504 (propagated-inputs
6505 `(("python-zope-event" ,python-zope-event)
6506 ("python-zope-interface" ,python-zope-interface)))
6507 (native-inputs
6508 `(("python-zope-testing" ,python-zope-testing)))
6509 (home-page "http://pypi.python.org/pypi/zope.schema")
6510 (synopsis "Zope data schemas")
6511 (description "Zope.scheme provides extensions to zope.interface for
6512defining data schemas.")
6513 (license zpl2.1)))
6514
6515(define-public python2-zope-schema
6516 (package-with-python2 python-zope-schema))
fbac9b17
LF
6517
6518(define-public python-zope-configuration
6519 (package
6520 (name "python-zope-configuration")
6521 (version "4.0.3")
6522 (source (origin
6523 (method url-fetch)
6524 (uri (string-append "https://pypi.python.org/packages/source/z"
6525 "/zope.configuration/zope.configuration-"
6526 version ".tar.gz"))
6527 (sha256
6528 (base32
6529 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
6530 (build-system python-build-system)
6531 (propagated-inputs
6532 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6533 ("python-zope-schema" ,python-zope-schema)))
6534 (home-page "http://pypi.python.org/pypi/zope.configuration")
6535 (synopsis "Zope Configuration Markup Language")
6536 (description "Zope.configuration implements ZCML, the Zope Configuration
6537Markup Language.")
6538 (license zpl2.1)))
6539
6540(define-public python2-zope-configuration
6541 (package-with-python2 python-zope-configuration))
2ad52086
LF
6542
6543(define-public python-zope-proxy
6544 (package
6545 (name "python-zope-proxy")
6546 (version "4.1.6")
6547 (source
6548 (origin
6549 (method url-fetch)
6550 (uri (string-append "https://pypi.python.org/packages/source/z"
6551 "/zope.proxy/zope.proxy-" version ".tar.gz"))
6552 (sha256
6553 (base32
6554 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
6555 (build-system python-build-system)
6556 (propagated-inputs
6557 `(("python-zope-interface" ,python-zope-interface)))
6558 (home-page "http://pypi.python.org/pypi/zope.proxy")
6559 (synopsis "Generic, transparent proxies")
6560 (description "Zope.proxy provides generic, transparent proxies for Python.
6561Proxies are special objects which serve as mostly-transparent wrappers around
6562another object, intervening in the apparent behavior of the wrapped object
6563only when necessary to apply the policy (e.g., access checking, location
6564brokering, etc.) for which the proxy is responsible.")
6565 (license zpl2.1)))
6566
6567(define-public python2-zope-proxy
6568 (package-with-python2 python-zope-proxy))
f404b5ea
LF
6569
6570(define-public python-zope-location
6571 (package
6572 (name "python-zope-location")
6573 (version "4.0.3")
6574 (source
6575 (origin
6576 (method url-fetch)
6577 (uri (string-append "https://pypi.python.org/packages/source/z"
6578 "/zope.location/zope.location-" version ".tar.gz"))
6579 (sha256
6580 (base32
6581 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
6582 (build-system python-build-system)
6583 (native-inputs
6584 `(("python-zope-proxy" ,python-zope-proxy)
6585 ("python-zope-schema" ,python-zope-schema)))
6586 (home-page "http://pypi.python.org/pypi/zope.location/")
6587 (synopsis "Zope location library")
6588 (description "Zope.location implements the concept of \"locations\" in
6589Zope3, which are are special objects that have a structural location.")
6590 (license zpl2.1)))
6591
6592(define-public python2-zope-location
6593 (package-with-python2 python-zope-location))
d4b77f36
LF
6594
6595(define-public python-zope-security
6596 (package
6597 (name "python-zope-security")
6598 (version "4.0.3")
6599 (source
6600 (origin
6601 (method url-fetch)
6602 (uri (string-append "https://pypi.python.org/packages/source/z"
6603 "/zope.security/zope.security-" version ".tar.gz"))
6604 (sha256
6605 (base32
6606 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
6607 (build-system python-build-system)
6608 (propagated-inputs
6609 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6610 ("python-zope-component" ,python-zope-component)
6611 ("python-zope-location" ,python-zope-location)
6612 ("python-zope-proxy" ,python-zope-proxy)
6613 ("python-zope-schema" ,python-zope-schema)
6614 ("python-zope-testrunner" ,python-zope-testrunner)
6615 ("python-zope-testing" ,python-zope-testing)))
6616 (home-page "http://pypi.python.org/pypi/zope.security")
6617 (synopsis "Zope security framework")
6618 (description "Zope.security provides a generic mechanism to implement
6619security policies on Python objects.")
6620 (license zpl2.1)))
6621
6622(define-public python2-zope-security
04417662
EF
6623 (let ((zope-security (package-with-python2 python-zope-security)))
6624 (package (inherit zope-security)
6625 (propagated-inputs
6626 `(("python2-zope-testrunner" ,python2-zope-testrunner)
6627 ,@(alist-delete
6628 "python-zope-testrunner"
6629 (package-propagated-inputs zope-security)))))))
a6b61b27
LF
6630
6631(define-public python-zope-component
6632 (package
6633 (name "python-zope-component")
6634 (version "4.2.2")
6635 (source
6636 (origin
6637 (method url-fetch)
6638 (uri (string-append "https://pypi.python.org/packages/source/z"
6639 "/zope.component/zope.component-" version ".tar.gz"))
6640 (sha256
6641 (base32
6642 "06pqr8m5jv12xjyy5b59hh9anl61cxkzhw9mka33r3nxalmi2b18"))))
6643 (build-system python-build-system)
6644 (arguments
6645 ;; Skip tests due to circular dependency with python-zope-security.
6646 '(#:tests? #f))
6647 (native-inputs
6648 `(("python-zope-testing" ,python-zope-testing)))
6649 (propagated-inputs
6650 `(("python-zope-event" ,python-zope-event)
6651 ("python-zope-interface" ,python-zope-interface)
6652 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6653 ("python-zope-configuration" ,python-zope-configuration)))
6654 (home-page "https://github.com/zopefoundation/zope.component")
6655 (synopsis "Zope Component Architecture")
6656 (description "Zope.component represents the core of the Zope Component
6657Architecture. Together with the zope.interface package, it provides
6658facilities for defining, registering and looking up components.")
6659 (license zpl2.1)))
6660
6661(define-public python2-zope-component
6662 (package-with-python2 python-zope-component))
3859ac12 6663
b5f218be
LF
6664(define-public python2-pythondialog
6665 (package
6666 (name "python2-pythondialog")
42c4b246 6667 (version "3.4.0")
b5f218be
LF
6668 (source
6669 (origin
6670 (method url-fetch)
42c4b246 6671 (uri (pypi-uri "python2-pythondialog" version))
b5f218be
LF
6672 (sha256
6673 (base32
42c4b246 6674 "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9"))))
b5f218be
LF
6675 (build-system python-build-system)
6676 (arguments
6677 `(#:phases
6678 (modify-phases %standard-phases
6679 (add-after 'unpack 'patch-path
6680 (lambda* (#:key inputs #:allow-other-keys)
6681 (let* ((dialog (assoc-ref inputs "dialog")))
6682 ;; Since this library really wants to grovel the search path, we
6683 ;; must hardcode dialog's store path into it.
6684 (substitute* "dialog.py"
6685 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
6686 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
6687 #t))))
6688 #:python ,python-2
6689 #:tests? #f)) ; no test suite
6690 (propagated-inputs
6691 `(("dialog" ,dialog)))
6692 (home-page "http://pythondialog.sourceforge.net/")
6693 (synopsis "Python interface to the UNIX dialog utility")
6694 (description "A Python wrapper for the dialog utility. Its purpose is to
6695provide an easy to use, pythonic and comprehensive Python interface to dialog.
6696This allows one to make simple text-mode user interfaces on Unix-like systems")
6697 (license lgpl2.1)))
6698
3859ac12
LF
6699(define-public python-pyrfc3339
6700 (package
6701 (name "python-pyrfc3339")
d9aa097b 6702 (version "1.0")
3859ac12
LF
6703 (source
6704 (origin
6705 (method url-fetch)
d9aa097b 6706 (uri (pypi-uri "pyRFC3339" version))
3859ac12
LF
6707 (sha256
6708 (base32
d9aa097b 6709 "0dgm4l9y8jiax5cp6yxjd2i27cq8h33sh81n1wfbmnmqb32cdywd"))))
3859ac12
LF
6710 (build-system python-build-system)
6711 (propagated-inputs
6712 `(("python-pytz" ,python-pytz)))
6713 (native-inputs
6714 `(("python-nose" ,python-nose)
6715 ("python-setuptools" ,python-setuptools)))
6716 (home-page "https://github.com/kurtraschke/pyRFC3339")
6717 (synopsis "Python timestamp library")
6718 (description "Python library for generating and parsing RFC 3339-compliant
6719timestamps.")
6720 (license license:expat)))
6721
6722(define-public python2-pyrfc3339
6723 (package-with-python2 python-pyrfc3339))
5eea2005
LF
6724
6725(define-public python-werkzeug
6726 (package
6727 (name "python-werkzeug")
4b47cbfa 6728 (version "0.11.5")
5eea2005
LF
6729 (source
6730 (origin
6731 (method url-fetch)
4b47cbfa 6732 (uri (pypi-uri "Werkzeug" version))
5eea2005
LF
6733 (sha256
6734 (base32
4b47cbfa 6735 "0r41xqp4cypzcgsf6zbspbqd272wnzf20igb4w4b5wzfhgqh9nxg"))))
5eea2005
LF
6736 (build-system python-build-system)
6737 (native-inputs
6738 `(("python-pytest" ,python-pytest)))
6739 (home-page "http://werkzeug.pocoo.org/")
6740 (synopsis "Utilities for WSGI applications")
6741 (description "One of the most advanced WSGI utility modules. It includes a
6742powerful debugger, full-featured request and response objects, HTTP utilities to
6743handle entity tags, cache control headers, HTTP dates, cookie handling, file
6744uploads, a powerful URL routing system and a bunch of community-contributed
6745addon modules.")
6746 (license x11)))
6747
6748(define-public python2-werkzeug
6749 (package-with-python2 python-werkzeug))
99fffa8a
LF
6750
6751(define-public python-configobj
6752 (package
6753 (name "python-configobj")
6754 (version "5.0.6")
6755 (source (origin
6756 (method url-fetch)
6757 (uri (string-append
6758 "https://pypi.python.org/packages/source/c/configobj/"
6759 "configobj-" version ".tar.gz"))
6760 (sha256
6761 (base32
6762 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
6763 ;; Patch setup.py so it looks for python-setuptools, which is
6764 ;; required to parse the keyword 'install_requires' in setup.py.
fc1adab1 6765 (patches (search-patches "python-configobj-setuptools.patch"))))
99fffa8a
LF
6766 (build-system python-build-system)
6767 (native-inputs
6768 `(("python-setuptools" ,python-setuptools)
6769 ("python-six" ,python-six)))
6770 (synopsis "Config file reading, writing and validation")
6771 (description "ConfigObj is a simple but powerful config file reader and
6772writer: an ini file round tripper. Its main feature is that it is very easy to
6773use, with a straightforward programmer’s interface and a simple syntax for
6774config files.")
6775 (home-page "https://github.com/DiffSK/configobj")
6776 (license bsd-3)))
6777
6778(define-public python2-configobj
6779 (package-with-python2 python-configobj))
79e8a291
LF
6780
6781(define-public python-configargparse
6782 (package
6783 (name "python-configargparse")
6784 (version "0.10.0")
6785 (source (origin
6786 (method url-fetch)
6787 (uri (string-append
6788 "https://pypi.python.org/packages/source/C/ConfigArgParse/"
6789 "ConfigArgParse-" version ".tar.gz"))
6790 (sha256
6791 (base32
6792 "19wh919gbdbzxzpagg52q3lm62yicm95ddlcx77dyjc1slyshl1v"))))
6793 (build-system python-build-system)
6794 (arguments
6795 ;; FIXME: Bug in test suite filed upstream:
6796 ;; https://github.com/bw2/ConfigArgParse/issues/32
6797 '(#:tests? #f))
6798 (synopsis "Replacement for argparse")
6799 (description "A drop-in replacement for argparse that allows options to also
6800be set via config files and/or environment variables.")
6801 (home-page "https://github.com/bw2/ConfigArgParse")
6802 (license license:expat)))
6803
6804(define-public python2-configargparse
6805 (package-with-python2 python-configargparse))
ab41f979
LF
6806
6807(define-public python-ndg-httpsclient
6808 (package
6809 (name "python-ndg-httpsclient")
6810 (version "0.4.0")
6811 (source (origin
6812 (method url-fetch)
6813 (uri (string-append
6814 "https://pypi.python.org/packages/source/n/ndg-httpsclient/"
6815 "ndg_httpsclient-" version ".tar.gz"))
6816 (sha256
6817 (base32
6818 "0x32ibixm3vv5m9xfk83xsqm8xcqw4dd0khbh6qbri6rxgymbhg8"))))
6819 (build-system python-build-system)
6820 (propagated-inputs
6821 `(("python-pyopenssl" ,python-pyopenssl)))
6822 (synopsis "HTTPS support for Python's httplib and urllib2")
6823 (description "This is a HTTPS client implementation for httplib and urllib2
6824based on PyOpenSSL. PyOpenSSL provides a more fully featured SSL implementation
6825over the default provided with Python and importantly enables full verification
6826of the SSL peer.")
6827 (home-page "https://github.com/cedadev/ndg_httpsclient/")
6828 (license bsd-3)))
6829
6830;; python2-openssl requires special care, so package-with-python2 is
6831;; insufficient.
6832(define-public python2-ndg-httpsclient
6833 (package (inherit python-ndg-httpsclient)
6834 (name "python2-ndg-httpsclient")
6835 (arguments `(#:python ,python-2))
6836 (propagated-inputs
6837 `(("python2-pyopenssl" ,python2-pyopenssl)))))
03f964a5
CM
6838
6839(define-public python-contextlib2
6840 (package
6841 (name "python-contextlib2")
6842 (version "0.4.0")
6843 (source
6844 (origin
6845 (method url-fetch)
6846 (uri (pypi-uri "contextlib2" version))
6847 (sha256
6848 (base32
6849 "0cmp131dlh0d0zvw0aza1zd13glvngzk8lb4avks0hm7yxwdr9am"))))
6850 (build-system python-build-system)
6851 (arguments
6852 `(#:phases
6853 (modify-phases %standard-phases
6854 (replace 'check
6855 (lambda _ (zero?
6856 (system*
b3546174 6857 "python" "test_contextlib2.py" "-v")))))))
03f964a5
CM
6858 (home-page "http://contextlib2.readthedocs.org/")
6859 (synopsis "Tools for decorators and context managers")
6860 (description "This module is primarily a backport of the Python
68613.2 contextlib to earlier Python versions. Like contextlib, it
6862provides utilities for common tasks involving decorators and context
6863managers. It also contains additional features that are not part of
6864the standard library.")
6865 (license psfl)))
6866
6867(define-public python2-contextlib2
6868 (package-with-python2 python-contextlib2))
210bf497
DT
6869
6870(define-public python-texttable
6871 (package
6872 (name "python-texttable")
6873 (version "0.8.4")
6874 (source
6875 (origin
6876 (method url-fetch)
6877 (uri (pypi-uri "texttable" version))
6878 (sha256
6879 (base32
6880 "0bkhs4dx9s6g7fpb969hygq56hyz4ncfamlynw72s0n6nqfbd1w5"))))
6881 (build-system python-build-system)
6882 (arguments '(#:tests? #f)) ; no tests
6883 (home-page "https://github.com/foutaise/texttable/")
6884 (synopsis "Python module for creating simple ASCII tables")
6885 (description "Texttable is a Python module for creating simple ASCII
6886tables.")
6887 (license lgpl2.1+)))
6888
6889(define-public python2-texttable
6890 (package-with-python2 python-texttable))
67c52bb3
DT
6891
6892(define-public python-websocket-client
6893 (package
6894 (name "python-websocket-client")
6b810897 6895 (version "0.37.0")
67c52bb3
DT
6896 (source
6897 (origin
6898 (method url-fetch)
6b810897 6899 (uri (pypi-uri "websocket_client" version))
67c52bb3
DT
6900 (sha256
6901 (base32
6b810897 6902 "0h9glp1jll3z76ly3kg08aqgxqk0a68p4zi9yn50353bh5nj92v7"))))
67c52bb3
DT
6903 (build-system python-build-system)
6904 (native-inputs
6905 `(("python-six" ,python-six))) ; for tests
6906 (inputs
6907 `(("python-setuptools" ,python-setuptools)))
6908 (home-page "https://github.com/liris/websocket-client")
6909 (synopsis "WebSocket client for Python")
6910 (description "The Websocket-client module provides the low level APIs for
6911WebSocket usage in Python programs.")
6912 (license lgpl2.1+)))
6913
6914(define-public python2-websocket-client
6915 (package-with-python2 python-websocket-client))
5c6eea2a
LF
6916
6917(define-public python-atomicwrites
6918 (package
6919 (name "python-atomicwrites")
54c30ebc 6920 (version "1.0.0")
5c6eea2a
LF
6921 (source (origin
6922 (method url-fetch)
6923 (uri (pypi-uri "atomicwrites" version))
6924 (sha256
6925 (base32
54c30ebc 6926 "019fa4771q7fb1167yfbh6msdzcqini6v7i59rmf72mzdjd7x5qv"))))
5c6eea2a
LF
6927 (build-system python-build-system)
6928 (synopsis "Atomic file writes in Python")
6929 (description "Library for atomic file writes using platform dependent tools
6930for atomic filesystem operations.")
6931 (home-page "https://github.com/untitaker/python-atomicwrites")
9bb6d184
LF
6932 (license license:expat)
6933 (properties `((python2-variant . ,(delay python2-atomicwrites))))))
6934
6935(define-public python2-atomicwrites
6936 (package (inherit (package-with-python2
6937 (strip-python2-variant python-atomicwrites)))
6938 (native-inputs
6939 `(("python2-setuptools" ,python2-setuptools)))))
561bb3cb
LF
6940
6941(define-public python-requests-toolbelt
6942 (package
6943 (name "python-requests-toolbelt")
c02af1c8 6944 (version "0.6.2")
561bb3cb
LF
6945 (source (origin
6946 (method url-fetch)
c02af1c8
LF
6947 (uri (string-append
6948 "https://pypi.python.org/packages/"
6949 "e1/a4/a94c037bc72ad70441aff1403d3243510d2542ddca7759faaeffeb11aefe/"
6950 "requests-toolbelt-" version ".tar.gz"))
561bb3cb
LF
6951 (sha256
6952 (base32
c02af1c8 6953 "15q9nrgp85nqlr4kdz1zvj8z2npafi2sr12y7fqgxbkq28j1aci6"))))
561bb3cb
LF
6954 (build-system python-build-system)
6955 (propagated-inputs
6956 `(("python-requests" ,python-requests)))
6957 (synopsis "Extensions to python-requests")
6958 (description "This is a toolbelt of useful classes and functions to be used
6959with python-requests.")
6960 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
6961 (license asl2.0)))
d1deb90b
LF
6962
6963(define-public python-click-threading
6964 (package
6965 (name "python-click-threading")
3d2e0dbc 6966 (version "0.2.0")
d1deb90b
LF
6967 (source (origin
6968 (method url-fetch)
3d2e0dbc
LF
6969 (uri (string-append
6970 "https://pypi.python.org/packages/"
6971 "fe/b7/e7f609d18a2a351cb71616adcf54df1acd82f83cb9b5936935a4d20e2c23/"
6972 "click-threading-" version ".tar.gz"))
d1deb90b
LF
6973 (sha256
6974 (base32
3d2e0dbc 6975 "18bcqikxwb3drb8rf60cclxkxw52521b38ax3byah6j8cn8y9p4j"))))
d1deb90b
LF
6976 (build-system python-build-system)
6977 (propagated-inputs
6978 `(("python-click" ,python-click)))
6979 (synopsis "Utilities for multithreading in Click")
6980 (description "This package provides utilities for multithreading in Click
6981applications.")
6982 (home-page "https://github.com/click-contrib/click-threading")
6983 (license license:expat)))
7b17cab9
LF
6984
6985(define-public python-click-log
6986 (package
6987 (name "python-click-log")
a9da8fec 6988 (version "0.1.3")
7b17cab9
LF
6989 (source (origin
6990 (method url-fetch)
6991 (uri (pypi-uri "click-log" version))
6992 (sha256
6993 (base32
a9da8fec 6994 "0kdd1vminxpcfczxl2kkf285n0dr1gxh2cdbx1p6vkj7b7bci3gx"))))
7b17cab9
LF
6995 (build-system python-build-system)
6996 (propagated-inputs
6997 `(("python-click" ,python-click)))
6998 (synopsis "Logging for click applications")
6999 (description "This package provides a Python library for logging Click
7000applications.")
7001 (home-page "https://github.com/click-contrib/click-log")
7002 (license license:expat)))
7b3a4ee4
LF
7003
7004(define-public python-apipkg
7005 (package
7006 (name "python-apipkg")
7007 (version "1.4")
7008 (source (origin
7009 (method url-fetch)
7010 (uri (pypi-uri "apipkg" version))
7011 (sha256
7012 (base32
7013 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
7014 (build-system python-build-system)
b43bab3c 7015 (inputs
7b3a4ee4
LF
7016 `(("python-pytest" ,python-pytest)))
7017 (synopsis "Namespace control and lazy-import mechanism")
7018 (description "With apipkg you can control the exported namespace of a Python
7019package and greatly reduce the number of imports for your users. It is a small
7020pure Python module that works on virtually all Python versions.")
7021 (home-page "https://bitbucket.org/hpk42/apipkg")
e08739c3
CAW
7022 (license license:expat)
7023 (properties `((python2-variant . ,(delay python2-apipkg))))))
7024
7025(define-public python2-apipkg
7026 (package
7027 (inherit (package-with-python2
7028 (strip-python2-variant python-apipkg)))
7029 (native-inputs
7030 `(("python2-setuptools" ,python2-setuptools)))))
848964fe
LF
7031
7032(define-public python-execnet
7033 (package
7034 (name "python-execnet")
7035 (version "1.4.1")
7036 (source (origin
7037 (method url-fetch)
7038 (uri (pypi-uri "execnet" version))
7039 (sha256
7040 (base32
7041 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
7042 (build-system python-build-system)
7043 (native-inputs
7044 `(("python-setuptools-scm" ,python-setuptools-scm)))
584d068f 7045 (inputs
848964fe
LF
7046 `(("python-apipkg" ,python-apipkg)))
7047 (synopsis "Rapid multi-Python deployment")
7048 (description "Execnet provides a share-nothing model with
7049channel-send/receive communication for distributing execution across many
7050Python interpreters across version, platform and network barriers. It has a
7051minimal and fast API targetting the following uses:
7052@enumerate
7053@item distribute tasks to (many) local or remote CPUs
7054@item write and deploy hybrid multi-process applications
7055@item write scripts to administer multiple environments
7056@end enumerate")
7057 (home-page "http://codespeak.net/execnet/")
16c84f90
CAW
7058 (license license:expat)
7059 (properties `((python2-variant . ,(delay python2-execnet))))))
7060
7061(define-public python2-execnet
7062 (let ((execnet (package-with-python2
7063 (strip-python2-variant python-execnet))))
7064 (package
7065 (inherit execnet)
7066 (native-inputs
7067 `(("python2-setuptools" ,python2-setuptools)
7068 ,@(package-native-inputs execnet))))))
6720dbb4
LF
7069
7070;;; The software provided by this package was integrated into pytest 2.8.
7071(define-public python-pytest-cache
7072 (package
7073 (name "python-pytest-cache")
7074 (version "1.0")
7075 (source (origin
7076 (method url-fetch)
7077 (uri (pypi-uri "pytest-cache" version))
7078 (sha256
7079 (base32
7080 "1a873fihw4rhshc722j4h6j7g3nj7xpgsna9hhg3zn6ksknnhx5y"))))
7081 (build-system python-build-system)
630d938f
EF
7082 (inputs
7083 `(("python-apipkg" ,python-apipkg)
7084 ("python-execnet" ,python-execnet)
7085 ("python-py" ,python-py)
7086 ("python-pytest" ,python-pytest)))
6720dbb4
LF
7087 (synopsis "Py.test plugin with mechanisms for caching across test runs")
7088 (description "The pytest-cache plugin provides tools to rerun failures from
7089the last py.test invocation.")
7090 (home-page "https://bitbucket.org/hpk42/pytest-cache/")
0adc21c2
EF
7091 (license license:expat)
7092 (properties `((python2-variant . ,(delay python2-pytest-cache))))))
7093
7094(define-public python2-pytest-cache
7095 (let ((pytest-cache (package-with-python2
7096 (strip-python2-variant python-pytest-cache))))
7097 (package
7098 (inherit pytest-cache)
7099 (native-inputs
7100 `(("python2-setuptools" ,python2-setuptools)
7101 ,@(package-native-inputs pytest-cache))))))
d7e729fe
LF
7102
7103(define-public python-pytest-localserver
7104 (package
7105 (name "python-pytest-localserver")
29f20168 7106 (version "0.3.5")
d7e729fe
LF
7107 (source (origin
7108 (method url-fetch)
29f20168 7109 (uri (pypi-uri "pytest-localserver" version))
d7e729fe
LF
7110 (sha256
7111 (base32
29f20168 7112 "0dvqspjr6va55zwmnnc2mmpqc7mm65kxig9ya44x1z8aadzxpa4p"))))
d7e729fe
LF
7113 (build-system python-build-system)
7114 (arguments
7115 `(#:phases (modify-phases %standard-phases
7116 (replace 'check
7117 (lambda _
7118 (zero? (system* "py.test" "--genscript=runtests.py"))
7119 (zero? (system* "py.test")))))))
7120 (native-inputs
d7e729fe
LF
7121 `(("python-pytest" ,python-pytest)
7122 ("python-requests" ,python-requests)
9ba40f05
EF
7123 ("python-six" ,python-six)))
7124 (inputs
7125 `(("python-werkzeug" ,python-werkzeug)))
d7e729fe
LF
7126 (synopsis "Py.test plugin to test server connections locally")
7127 (description "Pytest-localserver is a plugin for the pytest testing
7128framework which enables you to test server connections locally.")
7129 (home-page "https://pypi.python.org/pypi/pytest-localserver")
7130 (license license:expat)))
28cecbb7
LF
7131
7132(define-public python-wsgi-intercept
7133 (package
7134 (name "python-wsgi-intercept")
909fbd2b 7135 (version "1.2.2")
28cecbb7
LF
7136 (source (origin
7137 (method url-fetch)
909fbd2b
LF
7138 (uri (string-append
7139 "https://pypi.python.org/packages/"
7140 "38/76/ebcbc24d0cb77db34520a3ca6ed1bd43ace17d182bbd8dd7d976f1c176fb/"
7141 "wsgi_intercept-" version ".tar.gz"))
28cecbb7
LF
7142 (sha256
7143 (base32
909fbd2b 7144 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
28cecbb7
LF
7145 (build-system python-build-system)
7146 (native-inputs
9d813ec1
EF
7147 `(("python-pytest" ,python-pytest)
7148 ("python-six" ,python-six)))
28cecbb7
LF
7149 (propagated-inputs
7150 `(("python-httplib2" ,python-httplib2)
7151 ("python-requests" ,python-requests)))
7152 (synopsis "Puts a WSGI application in place of a real URI for testing")
7153 (description "Wsgi_intercept installs a WSGI application in place of a real
7154URI for testing. Testing a WSGI application normally involves starting a
7155server at a local host and port, then pointing your test code to that address.
7156Instead, this library lets you intercept calls to any specific host/port
7157combination and redirect them into a WSGI application importable by your test
7158program. Thus, you can avoid spawning multiple processes or threads to test
7159your Web app.")
7160 (home-page "https://github.com/cdent/wsgi-intercept")
7161 (license license:expat)))
89b8a551
LF
7162
7163(define-public python-pytest-xprocess
7164 (package
7165 (name "python-pytest-xprocess")
7166 (version "0.9.1")
7167 (source (origin
7168 (method url-fetch)
7169 (uri (pypi-uri "pytest-xprocess" version))
7170 (sha256
7171 (base32
7172 "17zlql1xqw3ywcgwwbqmw633aly99lab12hm02asr8awvg5603pp"))))
7173 (build-system python-build-system)
7174 (propagated-inputs
7175 `(("python-pytest" ,python-pytest)
7176 ("python-pytest-cache" ,python-pytest-cache)
7177 ("python-psutil" ,python-psutil)))
7178 (synopsis "Pytest plugin to manage external processes across test runs")
7179 (description "Pytest-xprocess is an experimental py.test plugin for managing
7180processes across test runs.")
7181 (home-page "https://bitbucket.org/pytest-dev/pytest-xprocess")
7182 (license license:expat)))
5c299bf0
LF
7183
7184(define-public python-icalendar
7185 (package
7186 (name "python-icalendar")
7187 (version "3.9.1")
7188 (source (origin
7189 (method url-fetch)
7190 (uri (pypi-uri "icalendar" version))
7191 (sha256
7192 (base32
7193 "0fhrczdj3jxy5bvswphp3vys7vwv5c9bpwg7asykqwa3z6253q6q"))))
7194 (build-system python-build-system)
7195 (propagated-inputs
7196 `(("python-dateutil-2" ,python-dateutil-2)
7197 ("python-pytz" ,python-pytz)))
7198 (synopsis "Python library for parsing iCalendar files")
7199 (description "The icalendar package is a parser/generator of iCalendar
7200files for use with Python.")
7201 (home-page "https://github.com/collective/icalendar")
7202 (license bsd-2)))
6bbbb53e
LF
7203
7204(define-public python-sphinxcontrib-newsfeed
7205 (package
7206 (name "python-sphinxcontrib-newsfeed")
7207 (version "0.1.4")
7208 (source (origin
7209 (method url-fetch)
7210 (uri (pypi-uri "sphinxcontrib-newsfeed" version))
7211 (sha256
7212 (base32
7213 "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p"))))
7214 (build-system python-build-system)
7215 (propagated-inputs
7216 `(("python-docutils" ,python-docutils)
7217 ("python-sphinx" ,python-sphinx)))
7218 (synopsis "News Feed extension for Sphinx")
7219 (description "Sphinxcontrib-newsfeed is an extension for adding a simple
7220Blog, News or Announcements section to a Sphinx website.")
7221 (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed")
7222 (license bsd-2)))
2216e15c
SB
7223
7224(define-public python-args
7225 (package
7226 (name "python-args")
7227 (version "0.1.0")
7228 (source (origin
7229 (method url-fetch)
7230 (uri (pypi-uri "args" version))
7231 (sha256
7232 (base32
7233 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
7234 (build-system python-build-system)
7235 (inputs
7236 `(("python-setuptools" ,python-setuptools)))
7237 (home-page "https://github.com/kennethreitz/args")
7238 (synopsis "Command-line argument parser")
7239 (description
7240 "This library provides a Python module to parse command-line arguments.")
7241 (license bsd-3)))
7242
7243(define-public python2-args
7244 (package-with-python2 python-args))
c06a3de9
SB
7245
7246(define-public python-clint
7247 (package
7248 (name "python-clint")
7249 (version "0.5.1")
7250 (source (origin
7251 (method url-fetch)
7252 (uri (pypi-uri "clint" version))
7253 (sha256
7254 (base32
7255 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
7256 (build-system python-build-system)
7257 (inputs
7258 `(("python-args" ,python-args)
7259 ("python-setuptools" ,python-setuptools)))
7260 (home-page "https://github.com/kennethreitz/clint")
7261 (synopsis "Command-line interface tools")
7262 (description
7263 "Clint is a Python module filled with a set of tools for developing
7264command-line applications, including tools for colored and indented
7265output, progress bar display, and pipes.")
7266 (license isc)))
7267
7268(define-public python2-clint
7269 (package-with-python2 python-clint))
4ecdeef8
SB
7270
7271(define-public python-astor
7272 (package
7273 (name "python-astor")
7274 (version "0.5")
7275 (source (origin
7276 (method url-fetch)
7277 (uri (pypi-uri "astor" version))
7278 (sha256
7279 (base32
7280 "1fdafq5hkis1fxqlmhw0sn44zp2ar46nxhbc22cvwg7hsd8z5gsa"))))
7281 (build-system python-build-system)
7282 (inputs
7283 `(("python-setuptools" ,python-setuptools)))
7284 (home-page "https://github.com/berkerpeksag/astor")
7285 (synopsis "Read and write Python ASTs")
7286 (description
7287 "Astor is designed to allow easy manipulation of Python source via the
7288Abstract Syntax Tree.")
7289 (license bsd-3)))
7290
7291(define-public python2-astor
7292 (package-with-python2 python-astor))
e224b7d0
SB
7293
7294(define-public python-rply
7295 (package
7296 (name "python-rply")
7297 (version "0.7.4")
7298 (source (origin
7299 (method url-fetch)
7300 (uri (pypi-uri "rply" version))
7301 (sha256
7302 (base32
7303 "12rp1d9ba7nvd5rhaxi6xzx1rm67r1k1ylsrkzhpwnphqpb06cvj"))))
7304 (build-system python-build-system)
7305 (inputs
7306 `(("python-appdirs" ,python-appdirs)
7307 ("python-setuptools" ,python-setuptools)))
7308 (home-page "https://github.com/alex/rply")
7309 (synopsis "Parser generator for Python")
7310 (description
7311 "This package provides a pure Python based parser generator, that also
7312works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
7313with a new public API, and RPython support.")
7314 (license bsd-3)))
7315
7316(define-public python2-rply
7317 (package-with-python2 python-rply))
c3e919d7
SB
7318
7319(define-public python-hy
7320 (package
7321 (name "python-hy")
7322 (version "0.11.1")
7323 (source (origin
7324 (method url-fetch)
7325 (uri (pypi-uri "hy" version))
7326 (sha256
7327 (base32
7328 "1msqv747iz12r73mz4qvsmlwkddwjvrahlrk7ysrcz07h7dsscxs"))))
7329 (build-system python-build-system)
7330 (inputs
7331 `(("python-astor" ,python-astor)
7332 ("python-clint" ,python-clint)
7333 ("python-rply" ,python-rply)
7334 ("python-setuptools" ,python-setuptools)))
7335 (home-page "http://hylang.org/")
7336 (synopsis "Lisp frontend to Python")
7337 (description
7338 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
7339its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
7340Python at your fingertips, in Lisp form.")
7341 (license license:expat)))
7342
7343(define-public python2-hy
7344 (package-with-python2 python-hy))
7a5b944e 7345
81f7f297
EF
7346(define-public python-rauth
7347 (package
7348 (name "python-rauth")
7349 (version "0.7.2")
7350 (source
7351 (origin
7352 (method url-fetch)
7353 (uri (pypi-uri "rauth" version))
7354 (sha256
7355 (base32
7356 "00pq7zw429hhza9c0qzxiqp77m653jv09z92nralnmzwdf6pzicf"))))
7357 (build-system python-build-system)
7358 (arguments
7359 `(#:test-target "check"))
0848d8d3 7360 (inputs
81f7f297
EF
7361 `(("python-requests" ,python-requests)))
7362 (home-page "https://github.com/litl/rauth")
7363 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
7364 (description
7365 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
7366provides service wrappers for convenient connection initialization and
7367authenticated session objects providing things like keep-alive.")
0848d8d3
EF
7368 (license license:expat)
7369 (properties `((python2-variant . ,(delay python2-rauth))))))
81f7f297
EF
7370
7371(define-public python2-rauth
0848d8d3
EF
7372 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
7373 (package
7374 (inherit base)
7375 (native-inputs `(("python2-setuptools" ,python2-setuptools)
7376 ("python2-unittest2" ,python2-unittest2)
7377 ,@(package-native-inputs base))))))
81f7f297 7378
1abe448d
EF
7379(define-public python2-functools32
7380 (package
7381 (name "python2-functools32")
7382 (version "3.2.3-2")
7383 (source
7384 (origin
7385 (method url-fetch)
7386 (uri (pypi-uri "functools32" version))
7387 (sha256
7388 (base32
7389 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
7390 (build-system python-build-system)
7391 (arguments
7392 `(#:python ,python-2
7393 #:tests? #f)) ; no test target
7394 (native-inputs
7395 `(("python2-setuptools" ,python2-setuptools)))
7396 (home-page "https://github.com/MiCHiLU/python-functools32")
7397 (synopsis
7398 "Backport of the functools module from Python 3.2.3")
7399 (description
7400 "This package is a backport of the @code{functools} module from Python
74013.2.3 for use with older versions of Python and PyPy.")
7402 (license license:expat)))
7403
877889f3 7404(define-public python2-futures
7a5b944e 7405 (package
877889f3 7406 (name "python2-futures")
7a5b944e
EF
7407 (version "3.0.3")
7408 (source
7409 (origin
7410 (method url-fetch)
7411 (uri (pypi-uri "futures" version))
7412 (sha256
7413 (base32
7414 "1vcb34dqhzkhbq1957vdjszhhm5y3j9ba88dgwhqx2zynhmk9qig"))))
7415 (build-system python-build-system)
877889f3 7416 (arguments `(#:python ,python-2))
7a5b944e 7417 (native-inputs
877889f3 7418 `(("python2-setuptools" ,python2-setuptools)))
7a5b944e
EF
7419 (home-page "https://github.com/agronholm/pythonfutures")
7420 (synopsis
7421 "Backport of the concurrent.futures package from Python 3.2")
7422 (description
7423 "The concurrent.futures module provides a high-level interface for
7424asynchronously executing callables. This package backports the
7425concurrent.futures package from Python 3.2")
7426 (license bsd-3)))
7427
c18f6368
EF
7428(define-public python-urllib3
7429 (package
7430 (name "python-urllib3")
7431 (version "1.13.1")
7432 (source
7433 (origin
7434 (method url-fetch)
7435 (uri (pypi-uri "urllib3" version))
7436 (sha256
7437 (base32
7438 "10rrbr6c6k7j5dvfsyj4b2gsgxg9gggnn708qixf6ll57xqivfkf"))))
7439 (build-system python-build-system)
7440 (arguments `(#:tests? #f))
7441 (native-inputs
7442 `(("python-setuptools" ,python-setuptools)
7443 ;; some packages for tests
7444 ("python-nose" ,python-nose)
7445 ("python-mock" ,python-mock)
7446 ("python-tornado" ,python-tornado)))
7447 (propagated-inputs
7448 `(;; packages for https security
7449 ("python-certifi" ,python-certifi)
7450 ("python-ndg-httpsclient" ,python-ndg-httpsclient)
7451 ("python-pyasn1" ,python-pyasn1)
7452 ("python-pyopenssl" ,python-pyopenssl)))
7453 (home-page "http://urllib3.readthedocs.org/")
7454 (synopsis "HTTP library with thread-safe connection pooling")
7455 (description
7456 "Urllib3 supports features left out of urllib and urllib2 libraries. It
7457can reuse the same socket connection for multiple requests, it can POST files,
7458supports url redirection and retries, and also gzip and deflate decoding.")
7459 (license license:expat)))
7460
7461(define-public python2-urllib3
7462 (package-with-python2 python-urllib3))
2b2f2fc1
DT
7463
7464(define-public python-colorama
7465 (package
7466 (name "python-colorama")
7467 (version "0.3.3")
7468 (source
7469 (origin
7470 (method url-fetch)
7471 (uri (pypi-uri "colorama" version))
7472 (sha256
7473 (base32
7474 "1716z9pq1r5ys3nkg7wdrb3h2f9rmd0zdxpxzmx3bgwgf6xg48gb"))))
7475 (build-system python-build-system)
7476 (inputs
7477 `(("python-setuptools" ,python-setuptools)))
7478 (synopsis "colored terminal text rendering for Python")
7479 (description "Colorama is a Python library for rendering colored terminal
7480text.")
7481 (home-page "https://pypi.python.org/pypi/colorama")
7482 (license bsd-3)))
7483
7484(define-public python2-colorama
7485 (package-with-python2 python-colorama))
f5bcec6e
DT
7486
7487(define-public python-rsa
7488 (package
7489 (name "python-rsa")
7490 (version "3.2")
7491 (source
7492 (origin
7493 (method url-fetch)
7494 (uri (pypi-uri "rsa" version))
7495 (sha256
7496 (base32
7497 "0xwp929g7lvb1sghxfpqlxvgg96qcwqdbhh27sjplx30n3xp3wrh"))))
7498 (build-system python-build-system)
7499 (inputs
7500 `(("python-pyasn1" ,python-pyasn1)
7501 ("python-setuptools" ,python-setuptools)))
7502 (synopsis "Pure-Python RSA implementation")
7503 (description "Python-RSA is a pure-Python RSA implementation. It supports
7504encryption and decryption, signing and verifying signatures, and key
7505generation according to PKCS#1 version 1.5. It can be used as a Python
7506library as well as on the command line.")
7507 (home-page "http://stuvel.eu/rsa")
7508 (license asl2.0)))
7509
7510(define-public python2-rsa
7511 (package-with-python2 python-rsa))
c0aacfa5
DT
7512
7513(define-public python-pluggy
7514 (package
7515 (name "python-pluggy")
7516 (version "0.3.1")
7517 (source
7518 (origin
7519 (method url-fetch)
7520 (uri (pypi-uri "pluggy" version))
7521 (sha256
7522 (base32
7523 "18qfzfm40bgx672lkg8q9x5hdh76n7vax99aank7vh2nw21wg70m"))))
7524 (build-system python-build-system)
7525 (inputs
7526 `(("python-setuptools" ,python-setuptools)))
7527 (synopsis "Plugin and hook calling mechanism for Python")
7528 (description "Pluggy is an extraction of the plugin manager as used by
7529Pytest but stripped of Pytest specific details.")
7530 (home-page "https://pypi.python.org/pypi/pluggy")
7531 (license license:expat)))
7532
7533(define-public python2-pluggy
7534 (package-with-python2 python-pluggy))
a4af21ca
DT
7535
7536(define-public python-tox
7537 (package
7538 (name "python-tox")
7539 (version "2.3.1")
7540 (source
7541 (origin
7542 (method url-fetch)
7543 (uri (pypi-uri "tox" version))
7544 (sha256
7545 (base32
7546 "1vj73ar4rimq3fwy5r2z3jv4g9qbh8rmpmncsc00g0k310acqzxz"))))
7547 (build-system python-build-system)
7548 (arguments
7549 ;; FIXME: Tests require a newer version of pytest, but upgrading our
7550 ;; pytest breaks other packages.
7551 '(#:tests? #f))
7552 (inputs
7553 `(("python-setuptools" ,python-setuptools)
7554 ("python-pluggy" ,python-pluggy)
7555 ("python-py" ,python-py)
7556 ("python-virtualenv" ,python-virtualenv)
7557 ("python-pytest" ,python-pytest)))
7558 (home-page "http://tox.testrun.org/")
7559 (synopsis "Virtualenv-based automation of test activities")
7560 (description "Tox is a generic virtualenv management and test command line
7561tool. It can be used to check that a package installs correctly with
7562different Python versions and interpreters, or run tests in each type of
7563supported environment, or act as a frontend to continuous integration
7564servers.")
7565 (license license:expat)))
7566
7567(define-public python2-tox
7568 (package-with-python2 python-tox))
ba9da248
DT
7569
7570(define-public python-jmespath
7571 (package
7572 (name "python-jmespath")
7573 (version "0.9.0")
7574 (source
7575 (origin
7576 (method url-fetch)
7577 (uri (pypi-uri "jmespath" version))
7578 (sha256
7579 (base32
7580 "0g9xvl69y7nr3w7ag4fsp6sm4fqf6vrqjw7504x2hzrrsh3ampq8"))))
7581 (build-system python-build-system)
7582 (inputs
7583 `(("python-setuptools" ,python-setuptools)))
7584 (synopsis "JSON Matching Expressions")
7585 (description "JMESPath (pronounced “james path”) is a Python library that
7586allows one to declaratively specify how to extract elements from a JSON
7587document.")
7588 (home-page "https://github.com/jmespath/jmespath.py")
7589 (license license:expat)))
7590
7591(define-public python2-jmespath
7592 (package-with-python2 python-jmespath))
935fcd5c
DT
7593
7594(define-public python-botocore
7595 (package
7596 (name "python-botocore")
7597 (version "1.3.17")
7598 (source
7599 (origin
7600 (method url-fetch)
7601 (uri (pypi-uri "botocore" version))
7602 (sha256
7603 (base32
7604 "08vpvdixx1c1lfv6vzjig68bpiir7wfyhzf49ysxgvhbprg5ra0w"))))
7605 (build-system python-build-system)
7606 (inputs
7607 `(("python-dateutil" ,python-dateutil-2)
7608 ("python-docutils" ,python-docutils)
7609 ("python-mock" ,python-mock)
7610 ("python-nose" ,python-nose)
7611 ("python-setuptools" ,python-setuptools)
7612 ("python-tox" ,python-tox)
7613 ("python-wheel" ,python-wheel)
7614 ("python-jmespath" ,python-jmespath)))
7615 (home-page "https://github.com/boto/botocore")
7616 (synopsis "Low-level interface to AWS")
7617 (description "Botocore is a Python library that provides a low-level
7618interface to the Amazon Web Services (AWS) API.")
7619 (license asl2.0)))
7620
7621(define-public python2-botocore
7622 (package-with-python2 python-botocore))
f861b8b8
DT
7623
7624(define-public awscli
7625 (package
7626 (name "awscli")
7627 (version "1.9.17")
7628 (source
7629 (origin
7630 (method url-fetch)
7631 (uri (string-append
7632 "https://pypi.python.org/packages/source/a/awscli/awscli-"
7633 version ".tar.gz"))
7634 (sha256
7635 (base32
7636 "1nj7jqvlpq57hfhby1njsbf8303gapa3njc4dramr6p3ffzvfi2i"))))
7637 (build-system python-build-system)
7638 (inputs
7639 `(("python-colorama" ,python-colorama)
7640 ("python-docutils" ,python-docutils)
7641 ("python-mock" ,python-mock)
7642 ("python-nose" ,python-nose)
7643 ("python-rsa" ,python-rsa)
7644 ("python-setuptools" ,python-setuptools)
7645 ("python-sphinx" ,python-sphinx)
7646 ("python-tox" ,python-tox)
7647 ("python-wheel" ,python-wheel)
7648 ("python-botocore" ,python-botocore)))
7649 (home-page "http://aws.amazon.com/cli/")
7650 (synopsis "Command line client for AWS")
7651 (description "AWS CLI provides a unified command line interface to the
7652Amazon Web Services (AWS) API.")
7653 (license asl2.0)))
6a44697d
LF
7654
7655(define-public python-hypothesis
7656 (package
7657 (name "python-hypothesis")
bea6d94d 7658 (version "3.1.0")
6a44697d
LF
7659 (source (origin
7660 (method url-fetch)
7661 (uri (pypi-uri "hypothesis" version))
7662 (sha256
7663 (base32
bea6d94d 7664 "0qyqq9akm4vshhn8cngjc1qykcvsn7cz6dlm6njfsgpbraqrmbbw"))))
6a44697d 7665 (build-system python-build-system)
6a44697d
LF
7666 (propagated-inputs
7667 `(("python-flake8" ,python-flake8)
7668 ("python-pytest" ,python-pytest)))
7669 (synopsis "Library for property based testing")
7670 (description "Hypothesis is a library for testing your Python code against a
7671much larger range of examples than you would ever want to write by hand. It’s
7672based on the Haskell library, Quickcheck, and is designed to integrate
7673seamlessly into your existing Python unit testing work flow.")
7674 (home-page "https://github.com/DRMacIver/hypothesis")
6f068e08
EF
7675 (license mpl2.0)
7676 (properties `((python2-variant . ,(delay python2-hypothesis))))))
6a44697d
LF
7677
7678(define-public python2-hypothesis
6f068e08
EF
7679 (let ((hypothesis (package-with-python2
7680 (strip-python2-variant python-hypothesis))))
7681 (package (inherit hypothesis)
7682 (native-inputs
7683 `(("python2-enum34" ,python2-enum34)
7684 ("python2-setuptools" ,python2-setuptools))))))
7517e73c
LF
7685
7686(define-public python-pytest-subtesthack
7687 (package
7688 (name "python-pytest-subtesthack")
7689 (version "0.1.1")
7690 (source (origin
7691 (method url-fetch)
7692 (uri (pypi-uri "pytest-subtesthack" version))
7693 (sha256
7694 (base32
7695 "15kzcr5pchf3id4ikdvlv752rc0j4d912n589l4rifp8qsj19l1x"))))
7696 (build-system python-build-system)
7697 (native-inputs
7698 `(;; setuptools required for python-2 variant
7699 ("python-setuptools" ,python-setuptools)))
7700 (propagated-inputs
7701 `(("python-pytest" ,python-pytest)))
7702 (synopsis "Set-up and tear-down fixtures for unit tests")
7703 (description "This plugin allows you to set up and tear down fixtures within
7704unit test functions that use @code{py.test}. This is useful for using
7705@command{hypothesis} inside py.test, as @command{hypothesis} will call the test
7706function multiple times, without setting up or tearing down fixture state as is
7707normally the case.")
7708 (home-page "https://github.com/untitaker/pytest-subtesthack/")
7709 (license unlicense)))
7710
7711(define-public python2-pytest-subtesthack
7712 (package-with-python2 python-pytest-subtesthack))
0bdc1671
CAW
7713
7714(define-public python2-xdo
7715 (package
7716 (name "python2-xdo")
7717 (version "0.2")
7718 (source (origin
7719 (method url-fetch)
7720 (uri (string-append
7721 "http://http.debian.net/debian/pool/main/p/python-xdo/"
7722 "python-xdo_" version ".orig.tar.gz"))
7723 (sha256
7724 (base32
7725 "1kl5c1p0dyxf62plnk6fl77ycfb4whwjms16r14dxx8kn90hlqz4"))))
7726 (build-system python-build-system)
7727 (arguments
7728 `(#:python ,python-2
7729 #:tests? #f)) ; no tests provided
7730 (inputs
7731 `(("xdotool" ,xdotool)
7732 ("libX11" ,libx11)))
7733 (home-page "https://tracker.debian.org/pkg/python-xdo")
7734 (synopsis "Python library for simulating X11 keyboard/mouse input")
7735 (description "Provides bindings to libxdo for manipulating X11 via simulated
7736input. (Note that this is mostly a legacy library; you may wish to look at
7737python-xdo for newer bindings.)")
7738 (license bsd-3)))
7739
cb34dc6c
CAW
7740(define-public python-wtforms
7741 (package
7742 (name "python-wtforms")
7743 (version "2.1")
7744 (source
7745 (origin
7746 (method url-fetch)
7747 (uri (pypi-uri "WTForms" version ".zip"))
7748 (sha256
7749 (base32
7750 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
7751 (build-system python-build-system)
7752 (native-inputs
7753 `(("unzip" ,unzip)))
7754 (home-page "http://wtforms.simplecodes.com/")
7755 (synopsis
7756 "Form validation and rendering library for Python web development")
7757 (description
7758 "WTForms is a flexible forms validation and rendering library
7759for Python web development. It is very similar to the web form API
7760available in Django, but is a standalone package.")
7761 (license bsd-3)
7762 (properties `((python2-variant . ,(delay python2-wtforms))))))
7763
7764(define-public python2-wtforms
7765 (package
7766 (inherit (package-with-python2
7767 (strip-python2-variant python-wtforms)))
7768 (inputs `(("python2-setuptools" ,python2-setuptools)))))
50aaec25
DT
7769
7770(define-public python-mako
7771 (package
7772 (name "python-mako")
7773 (version "1.0.3")
7774 (source
7775 (origin
7776 (method url-fetch)
7777 (uri (pypi-uri "Mako" version))
7778 (sha256
7779 (base32
7780 "136kcjbs0s98qkx8a418b05dfblqp0kiiqyx8vhx4rarwc7bqi3n"))))
7781 (build-system python-build-system)
7782 (native-inputs
7783 `(("python-markupsafe" ,python-markupsafe)
7784 ("python-mock" ,python-mock)
7785 ("python-nose" ,python-nose)))
7786 (home-page "http://www.makotemplates.org/")
7787 (synopsis "Templating language for Python")
7788 (description "Mako is a templating language for Python that compiles
7789templates into Python modules.")
7790 (license license:expat)
7791 (properties `((python2-variant . ,(delay python2-mako))))))
7792
7793(define-public python2-mako
7794 (let ((base (package-with-python2
7795 (strip-python2-variant python-mako))))
7796 (package
7797 (inherit base)
7798 (native-inputs
7799 (cons `("python2-setuptools" ,python2-setuptools)
7800 (package-native-inputs base))))))
ae00a41f
CAW
7801
7802(define-public python-waitress
7803 (package
7804 (name "python-waitress")
7805 (version "0.8.10")
7806 (source
7807 (origin
7808 (method url-fetch)
7809 (uri (pypi-uri "waitress" version))
7810 (sha256
7811 (base32
7812 "017n9ra6vvmq9d5sfhdzyzr1mg15x2hj2dhm4pdlw98c1ypw2h3w"))))
7813 (build-system python-build-system)
7814 (home-page "https://github.com/Pylons/waitress")
7815 (synopsis "Waitress WSGI server")
7816 (description "Waitress is meant to be a production-quality pure-Python WSGI
7817server with very acceptable performance.")
7818 (license zpl2.1)
7819 (properties `((python2-variant . ,(delay python2-waitress))))))
7820
7821(define-public python2-waitress
7822 (package
7823 (inherit (package-with-python2
7824 (strip-python2-variant python-waitress)))
7825 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
778a284b
CAW
7826
7827(define-public python-wsgiproxy2
7828 (package
7829 (name "python-wsgiproxy2")
7830 (version "0.4.2")
7831 (source
7832 (origin
7833 (method url-fetch)
7834 (uri (pypi-uri "WSGIProxy2" version ".zip"))
7835 (sha256
7836 (base32
7837 "13kf9bdxrc95y9vriaz0viry3ah11nz4rlrykcfvb8nlqpx3dcm4"))))
7838 (build-system python-build-system)
7839 (native-inputs
7840 `(("unzip" ,unzip)
7841 ("python-nose" ,python-nose)
7842 ("python-coverage" ,python-coverage)))
7843 (propagated-inputs
7844 `(("python-six" ,python-six)
7845 ("python-webob" ,python-webob)))
7846 (home-page
7847 "https://github.com/gawel/WSGIProxy2/")
7848 (synopsis "WSGI Proxy with various http client backends")
7849 (description "WSGI turns HTTP requests into WSGI function calls.
7850WSGIProxy turns WSGI function calls into HTTP requests.
7851It also includes code to sign requests and pass private data,
7852and to spawn subprocesses to handle requests.")
7853 (license license:expat)
7854 (properties `((python2-variant . ,(delay python2-wsgiproxy2))))))
7855
7856(define-public python2-wsgiproxy2
7857 (let ((wsgiproxy2 (package-with-python2
7858 (strip-python2-variant python-wsgiproxy2))))
7859 (package
7860 (inherit wsgiproxy2)
7861 (inputs `(("python2-setuptools" ,python2-setuptools)
7862 ,@(package-inputs wsgiproxy2))))))
bb7518b1
CAW
7863
7864(define-public python-pastedeploy
7865 (package
7866 (name "python-pastedeploy")
7867 (version "1.5.2")
7868 (source
7869 (origin
7870 (method url-fetch)
7871 (uri (pypi-uri "PasteDeploy" version))
7872 (sha256
7873 (base32
7874 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
7875 (build-system python-build-system)
7876 (native-inputs
7877 `(("python-nose" ,python-nose)))
7878 (propagated-inputs
7879 ;; This package uses pkg_resources, part of setuptools, during runtime,
7880 ;; hence why not a native-input.
7881 `(("python-setuptools" ,python-setuptools)))
7882 (home-page "http://pythonpaste.org/deploy/")
7883 (synopsis
7884 "Load, configure, and compose WSGI applications and servers")
7885 (description
7886 "This tool provides code to load WSGI applications and servers from URIs;
7887these URIs can refer to Python Eggs for INI-style configuration files. Paste
7888Script provides commands to serve applications based on this configuration
7889file.")
7890 (license license:expat)))
7891
7892(define-public python2-pastedeploy
7893 (package-with-python2 python-pastedeploy))
1cf53652 7894
c4a7904c
CAW
7895(define-public python-paste
7896 (package
7897 (name "python-paste")
7898 (version "2.0.2")
7899 (source
7900 (origin
7901 (method url-fetch)
7902 (uri (pypi-uri "Paste" version))
7903 (sha256
7904 (base32
7905 "16dsv9qi0r4qsrsb6dilpq2rx0fnglvh36flzywcdnm2jg43mb5d"))
fc1adab1
AK
7906 (patches (search-patches "python-paste-remove-website-test.patch"
7907 "python-paste-remove-timing-test.patch"))))
c4a7904c
CAW
7908 (build-system python-build-system)
7909 (native-inputs
7910 `(("python-nose" ,python-nose)))
7911 (propagated-inputs
7912 `(;; Uses pkg_resources provided by setuptools internally.
7913 ("python-setuptools" ,python-setuptools)
7914 ("python-six" ,python-six)))
7915 (arguments
7916 '(;; Tests don't pass on Python 3, but work fine on Python 2.
7917 ;; (As of 2.0.2, Python 3 support in Paste is presently a bit broken,
7918 ;; but is usable enough for the minimal amount it's used in MediaGoblin
7919 ;; still... things should be better by the next Paste release.)
7920 #:tests? #f))
7921 (home-page "http://pythonpaste.org")
7922 (synopsis
7923 "Python web development tools, focusing on WSGI")
7924 (description
7925 "Paste provides a variety of web development tools and middleware which
7926can be nested together to build web applications. Paste's design closely
7927follows ideas flowing from WSGI (Web Standard Gateway Interface).")
7928 (license license:expat)
7929 (properties `((python2-variant . ,(delay python2-paste))))))
7930
7931(define-public python2-paste
7932 (let ((paste (package-with-python2
7933 (strip-python2-variant python-paste))))
7934 (package
7935 (inherit paste)
7936 (arguments
7937 ;; Tests are back for Python 2!
7938 `(#:tests? #t
7939 ,@(package-arguments paste))))))
7940
a8f20f63
CAW
7941(define-public python-pastescript
7942 (package
7943 (name "python-pastescript")
7944 (version "2.0.2")
7945 (source
7946 (origin
7947 (method url-fetch)
7948 (uri (pypi-uri "PasteScript" version))
7949 (sha256
7950 (base32
7951 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
7952 (build-system python-build-system)
7953 (native-inputs
7954 `(("python-nose" ,python-nose)))
7955 (propagated-inputs
7956 `(;; Uses pkg_resources provided by setuptools internally.
7957 ("python-setuptools" ,python-setuptools)
7958 ("python-paste" ,python-paste)
7959 ("python-pastedeploy" ,python-pastedeploy)))
7960 (home-page "http://pythonpaste.org/script/")
7961 (arguments
7962 '(;; Unfortunately, this requires the latest unittest2,
7963 ;; but that requires traceback2 which requires linecache2 which requires
7964 ;; unittest2. So we're skipping tests for now.
7965 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
7966 ;; so in theory we could get around this situation somehow.)
7967 #:tests? #f))
7968 (synopsis
7969 "Pluggable command line tool for serving web applications and more")
7970 (description
7971 "PasteScript is a plugin-friendly command line tool which provides a
7972variety of features, from launching web applications to bootstrapping project
7973layouts.")
7974 (license license:expat)))
7975
7976(define-public python2-pastescript
7977 (package-with-python2 python-pastescript))
7978
1cf53652
CAW
7979(define-public python-pyquery
7980 (package
7981 (name "python-pyquery")
7982 (version "1.2.11")
7983 (source
7984 (origin
7985 (method url-fetch)
7986 (uri (pypi-uri "pyquery" version))
7987 (sha256
7988 (base32
7989 "1ikz1387nsp0pp7mzzr6ip9n5gr67acpap24yn33987v7fkjp0sa"))))
7990 (build-system python-build-system)
7991 (propagated-inputs
7992 `(("python-lxml" ,python-lxml)
7993 ("python-cssselect" ,python-cssselect)))
7994 (home-page "https://github.com/gawel/pyquery")
7995 (synopsis "Make jQuery-like queries on xml documents")
7996 (description "pyquery allows you to make jQuery queries on xml documents.
7997The API is as much as possible the similar to jQuery. pyquery uses lxml for
7998fast xml and html manipulation.")
7999 (license bsd-3)
8000 (properties `((python2-variant . ,(delay python2-pyquery))))))
8001
8002(define-public python2-pyquery
8003 (let ((pyquery (package-with-python2
8004 (strip-python2-variant python-pyquery))))
8005 (package
8006 (inherit pyquery)
8007 (native-inputs `(("python2-setuptools" ,python2-setuptools))))))
aa6313d6
CAW
8008
8009(define-public python-webtest
8010 (package
8011 (name "python-webtest")
8012 (version "2.0.20")
8013 (source
8014 (origin
8015 (method url-fetch)
8016 (uri (pypi-uri "WebTest" version))
8017 (sha256
8018 (base32
8019 "0bv0qhdjakdsdgj4sk21gnpp8xp8bga4x03p6gjb83ihrsb7n4xv"))))
8020 (build-system python-build-system)
8021 (arguments
8022 `(;; Unfortunately we have to disable tests!
8023 ;; This release of WebTest is pinned to python-nose < 1.3,
8024 ;; but older versions of python-nose are plagued with the following
8025 ;; bug(s), which rears its ugly head during test execution:
8026 ;; https://github.com/nose-devs/nose/issues/759
8027 ;; https://github.com/nose-devs/nose/pull/811
8028 #:tests? #f))
8029 ;; Commented out code is no good, but in this case, once tests
8030 ;; are ready to be enabled again, we should put the following
8031 ;; in place:
8032 ;; (native-inputs
8033 ;; `(("python-nose" ,python-nose) ; technially < 1.3,
8034 ;; ; but see above comment
8035 ;; ("python-coverage" ,python-coverage)
8036 ;; ("python-mock" ,python-mock)
8037 ;; ("python-pastedeploy" ,python-pastedeploy)
8038 ;; ("python-wsgiproxy2" ,python-wsgiproxy2)
8039 ;; ("python-pyquery" ,python-pyquery)))
8040 (propagated-inputs
8041 `(("python-waitress" ,python-waitress)
8042 ("python-webob" ,python-webob)
8043 ("python-six" ,python-six)
8044 ("python-beautifulsoup4" ,python-beautifulsoup4)))
8045 (home-page "http://webtest.pythonpaste.org/")
8046 (synopsis "Helper to test WSGI applications")
8047 (description "Webtest allows you to test your Python web applications
8048without starting an HTTP server. It supports anything that supports the
8049minimum of WSGI.")
8050 (license license:expat)
8051 (properties `((python2-variant . ,(delay python2-webtest))))))
8052
8053(define-public python2-webtest
8054 (let ((webtest (package-with-python2
8055 (strip-python2-variant python-webtest))))
8056 (package
8057 (inherit webtest)
8058 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8059 ,@(package-native-inputs webtest))))))
4cb122cd
CAW
8060
8061(define-public python-anyjson
8062 (package
8063 (name "python-anyjson")
8064 (version "0.3.3")
8065 (source
8066 (origin
8067 (method url-fetch)
8068 (uri (pypi-uri "anyjson" version))
8069 (sha256
8070 (base32
8071 "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
8072 (build-system python-build-system)
8073 (arguments
8074 `(;; We could possibly get tests working, but on Python 3 it's not so easy.
8075 ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
8076 ;; whatever) so this transformation needs to be done before the tests
8077 ;; can be run. Maybe we could add a build step to transform beforehand
8078 ;; but it could be annoying/difficult.
8079 ;; We can enable tests for the Python 2 version, though, and do below.
8080 #:tests? #f))
8081 (home-page "http://bitbucket.org/runeh/anyjson/")
8082 (synopsis
8083 "Wraps best available JSON implementation in a common interface")
8084 (description
8085 "Anyjson loads whichever is the fastest JSON module installed
8086and provides a uniform API regardless of which JSON implementation is used.")
8087 (license bsd-3)
8088 (properties `((python2-variant . ,(delay python2-anyjson))))))
8089
8090(define-public python2-anyjson
8091 (let ((anyjson (package-with-python2
8092 (strip-python2-variant python-anyjson))))
8093 (package
8094 (inherit anyjson)
8095 (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
8096 #:tests? #t
8097 ,@(package-arguments anyjson)))
8098 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8099 ("python2-nose" ,python2-nose))))))
8dfceab7
CAW
8100
8101(define-public python-amqp
8102 (package
8103 (name "python-amqp")
8104 (version "1.4.9")
8105 (source
8106 (origin
8107 (method url-fetch)
8108 (uri (pypi-uri "amqp" version))
8109 (sha256
8110 (base32
8111 "06n6q0kxhjnbfz3vn8x9yz09lwmn1xi9d6wxp31h5jbks0b4vsid"))))
8112 (build-system python-build-system)
8113 (native-inputs
8114 `(("python-nose" ,python-nose)
8115 ("python-mock" ,python-mock)))
8116 (home-page "http://github.com/celery/py-amqp")
8117 (synopsis
8118 "Low-level AMQP client for Python (fork of amqplib)")
8119 (description
8120 "This is a fork of amqplib which was originally written by Barry Pederson.
8121It is maintained by the Celery project, and used by kombu as a pure python
8122alternative when librabbitmq is not available.")
8123 (license lgpl2.1+)
8124 (properties `((python2-variant . ,(delay python2-amqp))))))
8125
8126(define-public python2-amqp
8127 (let ((amqp (package-with-python2
8128 (strip-python2-variant python-amqp))))
8129 (package
8130 (inherit amqp)
8131 (arguments `(;; Tries to run coverage tests with nose-cover3, which seems
8132 ;; unmaintained. Weirdly, does not do this on the python 3
8133 ;; version?
8134 #:tests? #f
8135 ,@(package-arguments amqp)))
8136 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8137 ,@(package-native-inputs amqp))))))
7d387305
CAW
8138
8139(define-public python-kombu
8140 (package
8141 (name "python-kombu")
8142 (version "3.0.33")
8143 (source
8144 (origin
8145 (method url-fetch)
8146 (uri (pypi-uri "kombu" version))
8147 (sha256
8148 (base32
8149 "16brjx2lgwbj2a37d0pjbfb84nvld6irghmqrs3qfncajp51hgc5"))))
8150 (build-system python-build-system)
8151 (native-inputs
8152 `(("python-mock" ,python-mock)
8153 ("python-nose" ,python-nose)))
8154 (propagated-inputs
8155 `(("python-anyjson" ,python-anyjson)
8156 ("python-amqp" ,python-amqp)))
8157 (home-page "http://kombu.readthedocs.org")
8158 (synopsis "Message passing library for Python")
8159 (description "The aim of Kombu is to make messaging in Python as easy as
8160possible by providing an idiomatic high-level interface for the AMQ protocol,
8161and also provide proven and tested solutions to common messaging problems.
8162AMQP is the Advanced Message Queuing Protocol, an open standard protocol for
8163message orientation, queuing, routing, reliability and security, for which the
8164RabbitMQ messaging server is the most popular implementation.")
8165 (license bsd-3)
8166 (properties `((python2-variant . ,(delay python2-kombu))))))
8167
8168(define-public python2-kombu
8169 (let ((kombu (package-with-python2
8170 (strip-python2-variant python-kombu))))
8171 (package
8172 (inherit kombu)
8173 (inputs `(("python2-setuptools" ,python2-setuptools)
8174 ("python2-unittest2" ,python2-unittest2)
8175 ,@(package-inputs kombu))))))
b6f0b9fb
CAW
8176
8177(define-public python-billiard
8178 (package
8179 (name "python-billiard")
8180 (version "3.3.0.22")
8181 (source
8182 (origin
8183 (method url-fetch)
8184 (uri (pypi-uri "billiard" version))
8185 (sha256
8186 (base32
8187 "0zp7h6a58alrb3mwdw61jds07395j4j0mj6iqsb8czrihw9ih5nj"))))
8188 (build-system python-build-system)
8189 (native-inputs
8190 `(("python-nose" ,python-nose)))
8191 (home-page "http://github.com/celery/billiard")
8192 (synopsis
8193 "Python multiprocessing fork with improvements and bugfixes")
8194 (description
8195 "Billiard is a fork of the Python 2.7 multiprocessing package. The
8196multiprocessing package itself is a renamed and updated version of R Oudkerk's
8197pyprocessing package. This standalone variant is intended to be compatible with
8198Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.")
8199 (license bsd-3)
8200 (properties `((python2-variant . ,(delay python2-billiard))))))
8201
8202(define-public python2-billiard
8203 (let ((billiard (package-with-python2
8204 (strip-python2-variant python-billiard))))
8205 (package
8206 (inherit billiard)
8207 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8208 ("python2-unittest2" ,python2-unittest2)
8209 ("python2-mock" ,python2-mock)
8210 ,@(package-native-inputs billiard))))))
22df6419
CAW
8211
8212(define-public python-celery
8213 (package
8214 (name "python-celery")
8215 (version "3.1.20")
8216 (source
8217 (origin
8218 (method url-fetch)
8219 (uri (pypi-uri "celery" version))
8220 (sha256
8221 (base32
8222 "1md6ywg1s0946qyp8ndnsd677wm0yax933h2sb4m3a4j7lf1jbyh"))))
8223 (build-system python-build-system)
8224 (native-inputs
8225 `(("python-nose" ,python-nose)))
a64cbb6f 8226 (inputs
22df6419 8227 `(("python-pytz" ,python-pytz)
a64cbb6f
EF
8228 ("python-amqp" ,python-amqp)
8229 ("python-anyjson" ,python-anyjson)
22df6419
CAW
8230 ("python-billiard" ,python-billiard)
8231 ("python-kombu" ,python-kombu)))
8232 (home-page "http://celeryproject.org")
8233 (synopsis "Distributed Task Queue")
8234 (description "Celery is an asynchronous task queue/job queue based on
8235distributed message passing. It is focused on real-time operation, but
8236supports scheduling as well. The execution units, called tasks, are executed
8237concurrently on a single or more worker servers using multiprocessing,
8238Eventlet, or gevent. Tasks can execute asynchronously (in the background) or
8239synchronously (wait until ready).")
8240 (license bsd-3)
8241 (properties `((python2-variant . ,(delay python2-celery))))))
8242
8243(define-public python2-celery
8244 (let ((celery (package-with-python2
8245 (strip-python2-variant python-celery))))
8246 (package
8247 (inherit celery)
8248 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8249 ("python2-unittest2" ,python2-unittest2)
8250 ("python2-mock" ,python2-mock)
8251 ,@(package-native-inputs celery))))))
97e32948
CAW
8252
8253(define-public python-translitcodec
8254 (package
8255 (name "python-translitcodec")
8256 (version "0.4.0")
8257 (source
8258 (origin
8259 (method url-fetch)
8260 (uri (pypi-uri "translitcodec" version))
8261 (sha256
8262 (base32
8263 "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki"))))
8264 (build-system python-build-system)
8265 (arguments
8266 `(#:tests? #f)) ; no tests provided
8267 (home-page
8268 "https://github.com/claudep/translitcodec")
8269 (synopsis
8270 "Unicode to 8-bit charset transliteration codec")
8271 (description
8272 "This package contains codecs for transliterating ISO 10646 texts into
8273best-effort representations using smaller coded character sets (ASCII,
8274ISO 8859, etc.).")
8275 (license license:expat)
8276 (properties `((python2-variant . ,(delay python2-translitcodec))))))
8277
8278(define-public python2-translitcodec
8279 (package
8280 (inherit (package-with-python2
8281 (strip-python2-variant python-translitcodec)))
8282 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
0c3b90d4
CAW
8283
8284(define-public python-editor
8285 (package
8286 (name "python-editor")
8287 (version "0.5")
8288 (source
8289 (origin
8290 (method url-fetch)
8291 (uri (pypi-uri "python-editor" version))
8292 (sha256
8293 (base32
8294 "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n"))))
8295 (build-system python-build-system)
8296 (home-page
8297 "https://github.com/fmoo/python-editor")
8298 (synopsis
8299 "Programmatically open an editor, capture the result")
8300 (description
8301 "python-editor is a library that provides the editor module for
8302programmatically interfacing with your system's $EDITOR.")
8303 (license asl2.0)
8304 (properties `((python2-variant . ,(delay python2-editor))))))
8305
8306(define-public python2-editor
8307 (package
8308 (inherit (package-with-python2
8309 (strip-python2-variant python-editor)))
8310 (inputs `(("python2-setuptools" ,python2-setuptools)))))
3276517c
LF
8311
8312(define-public python-sphinxcontrib-programoutput
8313 (package
8314 (name "python-sphinxcontrib-programoutput")
8315 (version "0.8")
8316 (source (origin
8317 (method url-fetch)
8318 (uri (pypi-uri "sphinxcontrib-programoutput" version))
8319 (sha256
8320 (base32
8321 "098as6z1s0gb4dh5xcr1fd2vpm91zj93jzvgawspxf5s4hqs0xhp"))))
8322 (build-system python-build-system)
8323 (propagated-inputs
8324 `(("python-docutils" ,python-docutils)
8325 ("python-sphinx" ,python-sphinx)))
8326 (synopsis "Sphinx extension to include program output")
8327 (description "A Sphinx extension to literally insert the output of arbitrary
8328commands into documents, helping you to keep your command examples up to date.")
8329 (home-page "https://github.com/lunaryorn/sphinxcontrib-programoutput")
8330 (license bsd-2)
8331 (properties `((python2-variant . ,(delay python2-sphinxcontrib-programoutput))))))
8332
8333(define-public python2-sphinxcontrib-programoutput
8334 (package
8335 (inherit (package-with-python2
8336 (strip-python2-variant python-sphinxcontrib-programoutput)))
8337 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
548d7165
LF
8338
8339(define-public python-sphinx-repoze-autointerface
8340 (package
8341 (name "python-sphinx-repoze-autointerface")
328ae341 8342 (version "0.8")
548d7165
LF
8343 (source (origin
8344 (method url-fetch)
8345 (uri (pypi-uri "repoze.sphinx.autointerface" version))
8346 (sha256
8347 (base32
328ae341 8348 "08ycivzf7bh4a1zcyp31hbyqs1b2c9r26raa3vxjwwmbfqr3iw4f"))))
548d7165
LF
8349 (build-system python-build-system)
8350 (propagated-inputs
8351 `(("python-docutils" ,python-docutils)
8352 ("python-sphinx" ,python-sphinx)
8353 ("python-zope-interface" ,python-zope-interface)))
8354 (synopsis "Auto-generate Sphinx API docs from Zope interfaces")
8355 (description "This package defines an extension for the Sphinx documentation
8356system. The extension allows generation of API documentation by
8357introspection of @code{zope.interface} instances in code.")
8358 (home-page "https://github.com/repoze/repoze.sphinx.autointerface")
8359 (license repoze)))
8360
8361(define-public python2-sphinx-repoze-autointerface
8362 (package-with-python2 python-sphinx-repoze-autointerface))
b31fbea5
DM
8363
8364(define-public python-psycopg2
8365 (package
8366 (name "python-psycopg2")
8367 (version "2.6.1")
8368 (source
8369 (origin
8370 (method url-fetch)
8371 (uri (pypi-uri "psycopg2" version))
8372 (sha256
8373 (base32
8374 "0k4hshvrwsh8yagydyxgmd0pjm29lwdxkngcq9fzfzkmpsxrmkva"))))
8375 (build-system python-build-system)
8376 (arguments
8377 ;; Tests would require a postgresql database "psycopg2_test"
8378 ;; and a running postgresql database management service.
8379 `(#:tests? #f)) ; TODO re-enable after providing a test-db.
8380 (inputs
8381 `(("postgresql" ,postgresql))) ; libpq
8382 (home-page "http://initd.org/psycopg/")
8383 (synopsis "Python PostgreSQL adapter")
8384 (description
8385 "psycopg2 is a thread-safe PostgreSQL adapter that implements DB-API 2.0. ")
8386 (license lgpl3+)
8387 (properties `((python2-variant . ,(delay python2-psycopg2))))))
8388
8389(define-public python2-psycopg2
8390 (package
8391 (inherit (package-with-python2
8392 (strip-python2-variant python-psycopg2)))
8393 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
eed1a61f
LF
8394
8395(define-public python-vobject
8396 (package
8397 (name "python-vobject")
9bed9b15 8398 (version "0.9.2")
eed1a61f
LF
8399 (source (origin
8400 (method url-fetch)
8401 (uri (pypi-uri "vobject" version))
8402 (sha256
8403 (base32
9bed9b15 8404 "1qfnwlx8qwkgr6nf5wvl6ff1r3kll53dh3z6nyp173nmlhhhqccb"))))
eed1a61f
LF
8405 (build-system python-build-system)
8406 (inputs
8407 `(("python-dateutil-2" ,python-dateutil-2)
8408 ("python-pyicu" ,python-pyicu)))
8409 (synopsis "Parse and generate vCard and vCalendar files")
8410 (description "Vobject is intended to be a full featured Python package for
8411parsing and generating vCard and vCalendar files. Currently, iCalendar files
8412are supported and well tested. vCard 3.0 files are supported, and all data
8413should be imported, but only a few components are understood in a sophisticated
8414way.")
8415 (home-page "http://eventable.github.io/vobject/")
8416 (license asl2.0)
8417 (properties `((python2-variant . ,(delay python2-vobject))))))
8418
8419(define-public python2-vobject
8420 (package
8421 (inherit (package-with-python2
8422 (strip-python2-variant python-vobject)))
8423 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
cedac813
LF
8424
8425(define-public python-munkres
8426 (package
8427 (name "python-munkres")
8428 (version "1.0.7")
8429 (source (origin
8430 (method url-fetch)
8431 (uri (pypi-uri "munkres" version))
8432 (sha256
8433 (base32
8434 "1i6nf45i0kkzdx6k70giybsqxz4dxsjbrkrfqgjd7znfkf25sjik"))))
8435 (build-system python-build-system)
8436 (arguments
8437 '(#:tests? #f)) ; no test suite
8438 (home-page "http://software.clapper.org/munkres/")
8439 (synopsis "Implementation of the Munkres algorithm")
8440 (description "The Munkres module provides an implementation of the Munkres
8441algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm),
8442useful for solving the Assignment Problem.")
8443 (license bsd-3)))
8444
8445(define-public python2-munkres
8446 (package-with-python2 python-munkres))
f3b3d78f
LF
8447
8448(define-public python-flask
8449 (package
8450 (name "python-flask")
8451 (version "0.10.1")
8452 (source (origin
8453 (method url-fetch)
8454 (uri (pypi-uri "Flask" version))
8455 (sha256
8456 (base32
8457 "0wrkavjdjndknhp8ya8j850jq7a1cli4g5a93mg8nh1xz2gq50sc"))))
8458 (build-system python-build-system)
8459 (propagated-inputs
8460 `(("python-itsdangerous" ,python-itsdangerous)
8461 ("python-jinja2" ,python-jinja2)
8462 ("python-werkzeug" ,python-werkzeug)))
8463 (home-page "https://github.com/mitsuhiko/flask/")
8464 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
8465 (description "Flask is a micro web framework based on the Werkzeug toolkit
8466and Jinja2 template engine. It is called a micro framework because it does not
8467presume or force a developer to use a particular tool or library.")
8468 (license bsd-3)
8469 (properties `((python2-variant . ,(delay python2-flask))))))
8470
8471(define-public python2-flask
8472 (package (inherit (package-with-python2
8473 (strip-python2-variant python-flask)))
8474 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
603d665b
LF
8475
8476(define-public python-cookies
8477 (package
8478 (name "python-cookies")
8479 (version "2.2.1")
8480 (source (origin
8481 (method url-fetch)
8482 (uri (pypi-uri "cookies" version))
8483 (sha256
8484 (base32
8485 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
8486 (build-system python-build-system)
8487 (arguments
8488 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
8489 #:tests? #f))
8490 (native-inputs
8491 `(("python-pytest" ,python2-pytest)))
8492 (synopsis "HTTP cookie parser and renderer")
8493 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
8494Python.")
8495 (home-page "https://gitlab.com/sashahart/cookies")
8496 (license license:expat)
8497 (properties `((python2-variant . ,(delay python2-cookies))))))
8498
8499(define-public python2-cookies
8500 (let ((cookies (package-with-python2
8501 (strip-python2-variant python-cookies))))
8502 (package (inherit cookies)
8503 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8504 ,@(package-native-inputs cookies))))))
0efde7d6
LF
8505
8506(define-public python-responses
8507 (package
8508 (name "python-responses")
8509 (version "0.5.1")
8510 (source (origin
8511 (method url-fetch)
8512 (uri (pypi-uri "responses" version))
8513 (sha256
8514 (base32
8515 "1spcfxixyk9k7pk82jm6zqkwk031s95lh8q0mz7539jrb7269bcc"))))
8516 (build-system python-build-system)
8517 (arguments
8518 `(;; Test suite is not distributed:
8519 ;; https://github.com/getsentry/responses/issues/38
8520 #:tests? #f))
8521 (native-inputs
8522 `(("python-cookies" ,python-cookies)
8523 ("python-mock" ,python-mock)))
8524 (propagated-inputs
8525 `(("python-requests" ,python-requests)
8526 ("python-six" ,python-six)))
8527 (home-page "https://github.com/getsentry/responses")
8528 (synopsis "Utility for mocking out the `requests` Python library")
8529 (description "A utility library for mocking out the `requests` Python
8530library.")
8531 (license asl2.0)
8532 (properties `((python2-variant . ,(delay python2-responses))))))
8533
8534(define-public python2-responses
8535 (let ((responses (package-with-python2
8536 (strip-python2-variant python-responses))))
8537 (package (inherit responses)
8538 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8539 ,@(package-native-inputs responses))))))
76b94885
LF
8540
8541(define-public python-pathlib
8542 (package
8543 (name "python-pathlib")
8544 (version "1.0.1")
8545 (source (origin
8546 (method url-fetch)
8547 (uri (pypi-uri "pathlib" version))
8548 (sha256
8549 (base32
8550 "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39"))))
8551 (build-system python-build-system)
8552 (arguments
8553 `(#:phases
8554 (modify-phases %standard-phases
8555 (replace 'check
8556 (lambda _ (zero? (system* "python" "./test_pathlib.py")))))))
8557 (home-page "https://pathlib.readthedocs.org/")
8558 (synopsis "Object-oriented filesystem paths")
8559 (description "Pathlib offers a set of classes to handle filesystem paths.
8560It offers the following advantages over using string objects:
8561
8562@enumerate
8563@item No more cumbersome use of os and os.path functions. Everything can
8564be done easily through operators, attribute accesses, and method calls.
8565@item Embodies the semantics of different path types. For example,
8566comparing Windows paths ignores casing.
8567@item Well-defined semantics, eliminating any inconsistencies or
8568ambiguities (forward vs. backward slashes, etc.).
8569@end enumerate\n")
8570 (license license:expat)))
8571
8572(define-public python2-pathlib
8573 (package-with-python2 python-pathlib))
25a7db0a
LF
8574
8575(define-public python-jellyfish
8576 (package
8577 (name "python-jellyfish")
8578 (version "0.5.3")
8579 (source (origin
8580 (method url-fetch)
8581 (uri (pypi-uri "jellyfish" version))
8582 (sha256
8583 (base32
8584 "12bxh8cy9xmvyrjz7aw159nd5pyvb645rkvw4r6bvm4xbvs8gd07"))))
8585 (build-system python-build-system)
8586 (native-inputs
8587 `(("python-pytest" ,python-pytest)))
8588 (home-page "https://github.com/jamesturk/jellyfish")
8589 (synopsis "Approximate and phonetic matching of strings")
8590 (description "Jellyfish uses a variety of string comparison and phonetic
8591encoding algorithms to do fuzzy string matching.")
8592 (license bsd-2)
8593 (properties `((python2-variant . ,(delay python2-jellyfish))))))
8594
8595(define-public python2-jellyfish
8596 (let ((jellyfish (package-with-python2
8597 (strip-python2-variant python-jellyfish))))
8598 (package (inherit jellyfish)
8599 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8600 ("python2-unicodecsv" ,python2-unicodecsv)
8601 ,@(package-native-inputs jellyfish))))))
13edb0e5
LF
8602
8603(define-public python2-unicodecsv
8604 (package
8605 (name "python2-unicodecsv")
8606 (version "0.14.1")
8607 (source (origin
8608 (method url-fetch)
8609 ;; The test suite is not included in the PyPi release.
8610 ;; https://github.com/jdunck/python-unicodecsv/issues/19
8611 (uri (string-append "https://github.com/jdunck/python-unicodecsv/"
8612 "archive/" version ".tar.gz"))
8613 (file-name (string-append name "-" version ".tar.gz"))
8614 (sha256
8615 (base32
8616 "087nqanfcyp6mlfbbr5lva5f3w6iz1bybls9xlrb8icmc474wh4w"))))
8617 (build-system python-build-system)
8618 (arguments
8619 `(;; It supports Python 3, but Python 3 can already do Unicode CSV.
8620 #:python ,python-2))
8621 (native-inputs
8622 `(("python2-setuptools" ,python2-setuptools)
8623 ("python2-unittest2" ,python2-unittest2)))
8624 (home-page "https://github.com/jdunck/python-unicodecsv")
8625 (synopsis "Unicode CSV module for Python 2")
8626 (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV
8627module, adding support for Unicode strings.")
8628 (license bsd-2)))
064503aa
LF
8629
8630(define-public python-rarfile
8631 (package
8632 (name "python-rarfile")
8633 (version "2.7")
8634 (source (origin
8635 (method url-fetch)
8636 (uri (pypi-uri "rarfile" version))
8637 (sha256
8638 (base32
8639 "0d8n1dlpiz7av8dmbp0vclrwl9cnxizr4f2c9xvj1h5nvn480527"))
8640 ;; https://github.com/markokr/rarfile/pull/17/
fc1adab1 8641 (patches (search-patches "python-rarfile-fix-tests.patch"))))
064503aa
LF
8642 (build-system python-build-system)
8643 (arguments
8644 '(#:phases
8645 (modify-phases %standard-phases
8646 (replace 'check
8647 ;; Many tests fail, but the installation proceeds.
8648 (lambda _ (zero? (system* "make" "-C" "test" "test")))))))
8649 (native-inputs
8650 `(("which" ,which))) ; required for tests
8651 (propagated-inputs
8652 `(("libarchive" ,libarchive)))
8653 (home-page "https://github.com/markokr/rarfile")
8654 (synopsis "RAR archive reader for Python")
8655 (description "This is Python module for RAR archive reading. The interface
8656is made as zipfile like as possible.")
8657 (license isc)))
8658
8659(define-public python2-rarfile
8660 (package-with-python2 python-rarfile))
daeeea71
CM
8661
8662(define-public python-magic
8663 (package
8664 (name "python-magic")
8665 (version "0.4.3")
8666 (source
8667 (origin
8668 (method url-fetch)
8669 (uri (string-append "https://github.com/ahupp/python-magic/archive/"
8670 version ".tar.gz"))
8671 (sha256
8672 (base32
8673 "17bgy92i7sb021f2s4mw1dcvpm6p1mi9jihridwy1pyn8mzvpjgk"))
8674 (file-name (string-append name "-" version "-checkout"))))
8675 (build-system python-build-system)
8676 (arguments
8677 ;; The tests are unreliable, so don't run them. The tests fail
8678 ;; under Python3 because they were written for Python2 and
8679 ;; contain import statements that do not work in Python3. One of
8680 ;; the tests fails under Python2 because its assertions are
8681 ;; overly stringent; it relies on comparing output strings which
8682 ;; are brittle and can change depending on the version of
8683 ;; libmagic being used and the system on which the test is
8684 ;; running. In my case, under GuixSD 0.10.0, only one test
8685 ;; failed, and it seems to have failed only because the version
8686 ;; of libmagic that is packaged in Guix outputs a slightly
8687 ;; different (but not wrong) string than the one that the test
8688 ;; expected.
8689 '(#:tests? #f
8690 #:phases (modify-phases %standard-phases
8691 ;; Replace a specific method call with a hard-coded
8692 ;; path to the necessary libmagic.so file in the
8693 ;; store. If we don't do this, then the method call
8694 ;; will fail to find the libmagic.so file, which in
8695 ;; turn will cause any application using
8696 ;; python-magic to fail.
8697 (add-before 'build 'hard-code-path-to-libmagic
8698 (lambda* (#:key inputs #:allow-other-keys)
8699 (let ((file (assoc-ref inputs "file")))
8700 (substitute* "magic.py"
8701 (("ctypes.util.find_library\\('magic'\\)")
8702 (string-append "'" file "/lib/libmagic.so'")))
8703 #t))))))
8704 (native-inputs
8705 `(("python-setuptools" ,python-setuptools)))
8706 (inputs
8707 ;; python-magic needs to be able to find libmagic.so.
8708 `(("file" ,file)))
8709 (home-page "https://github.com/ahupp/python-magic")
8710 (synopsis "File type identification using libmagic")
8711 (description
8712 "This module uses ctypes to access the libmagic file type
8713identification library. It makes use of the local magic database and
8714supports both textual and MIME-type output. Note that this module and
8715the python-file module both provide a \"magic.py\" file; these two
8716modules, which are different and were developed separately, both serve
8717the same purpose: to provide Python bindings for libmagic.")
8718 (license license:expat)))
8719
8720(define-public python2-magic
8721 (package-with-python2 python-magic))
12af303f
CM
8722
8723(define-public python2-s3cmd
8724 (package
8725 (name "python2-s3cmd")
8726 (version "1.6.1")
8727 (source
8728 (origin
8729 (method url-fetch)
8730 (uri (string-append "mirror://sourceforge/s3tools/"
8731 "s3cmd-" version ".tar.gz"))
8732 (sha256
8733 (base32
8734 "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6"))))
8735 (build-system python-build-system)
8736 (arguments
8737 ;; s3cmd is written for python2 only and contains no tests.
8738 `(#:python ,python-2
8739 #:tests? #f))
8740 (native-inputs
8741 `(("python2-setuptools" ,python2-setuptools)))
8742 (inputs
8743 `(("python2-dateutil" ,python2-dateutil)
8744 ;; The python-file package also provides a magic.py module.
8745 ;; This is an unfortunate state of affairs; however, s3cmd
8746 ;; fails to install if it cannot find specifically the
8747 ;; python-magic package. Thus we include it, instead of using
8748 ;; python-file. Ironically, s3cmd sometimes works better
8749 ;; without libmagic bindings at all:
8750 ;; https://github.com/s3tools/s3cmd/issues/198
8751 ("python2-magic" ,python2-magic)))
8752 (home-page "http://s3tools.org/s3cmd")
8753 (synopsis "Command line tool for S3-compatible storage services")
8754 (description
8755 "S3cmd is a command line tool for uploading, retrieving and managing data
8756in storage services that are compatible with the Amazon Simple Storage
8757Service (S3) protocol, including S3 itself. It supports rsync-like backup,
8758GnuPG encryption, and more. It also supports management of Amazon's
8759CloudFront content delivery network.")
8760 (license gpl2+)))
4323a5f0
AE
8761
8762(define-public python-pkgconfig
8763 (package
8764 (name "python-pkgconfig")
8765 (version "1.1.0")
8766 (source
8767 (origin
8768 (method url-fetch)
8769 (uri (pypi-uri "pkgconfig" version))
8770 (sha256
8771 (base32
8772 "1pw0kmvc57sjmaxi6c54fqsnihqj6hvhc9y1vaz36axafzqam7bh"))))
8773 (build-system python-build-system)
8774 (native-inputs
8775 `(("python-nose" ,python-nose)
8776 ("python-setuptools" ,python-setuptools)))
8777 (inputs
8778 `(("pkg-config" ,pkg-config)))
8779 (arguments
8780 `(;; Tests fail with "ValueError: _type_ 'v' not supported" on Python 3,
8781 ;; and on Python 2 they need the dl module deprecated since Python 2.6.
8782 #:tests? #f
8783 ;; Prevent creation of the egg. This works around
8784 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
8785 #:configure-flags '("--single-version-externally-managed" "--root=/")
8786 ;; Hard-code the path to pkg-config.
8787 #:phases
8788 (modify-phases %standard-phases
8789 (add-before
8790 'build 'patch
8791 (lambda _
8792 (substitute* "pkgconfig/pkgconfig.py"
8793 (("cmd = 'pkg-config")
8794 (string-append "cmd = '" (which "pkg-config"))))
8795 #t)))))
8796 (home-page "http://github.com/matze/pkgconfig")
8797 (synopsis "Python interface for pkg-config")
8798 (description "This module provides a Python interface to pkg-config. It
8799can be used to find all pkg-config packages, check if a package exists,
8800check if a package meets certain version requirements, query CFLAGS and
8801LDFLAGS and parse the output to build extensions with setup.py.")
a0c6a36b 8802 (license license:expat)))
4323a5f0
AE
8803
8804(define-public python2-pkgconfig
8805 (package-with-python2 python-pkgconfig))
8806
2e697322
BW
8807(define-public python-bz2file
8808 (package
8809 (name "python-bz2file")
8810 (version "0.98")
8811 (source
8812 (origin
8813 (method url-fetch)
8814 (uri (pypi-uri "bz2file" version))
8815 (sha256
8816 (base32
8817 "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4"))))
8818 (build-system python-build-system)
8819 (arguments
8820 `(#:phases
8821 (modify-phases %standard-phases
8822 ;; python setup.py test does not work as of 0.98
8823 ;; but there is only the one test file
8824 (replace 'check
8825 (lambda _ (zero? (system* "python" "test_bz2file.py")))))))
8826 (home-page "https://github.com/nvawda/bz2file")
8827 (synopsis "Read and write bzip2-compressed files")
8828 (description
8829 "Bz2file is a Python library for reading and writing bzip2-compressed
8830files. It contains a drop-in replacement for the I/O interface in the
8831standard library's @code{bz2} module, including features from the latest
8832development version of CPython that are not available in older releases.")
8833 (license asl2.0)
8834 (properties `((python2-variant . ,(delay python2-bz2file))))))
8835
8836(define-public python2-bz2file
8837 (let ((base (package-with-python2
8838 (strip-python2-variant python-bz2file))))
8839 (package
8840 (inherit base)
8841 (native-inputs
8842 `(("python2-setuptools" ,python2-setuptools))))))
8843
8e451885
AE
8844(define-public python-cysignals
8845 (package
8846 (name "python-cysignals")
8847 (version "1.1.0")
8848 (source
8849 (origin
8850 (method url-fetch)
8851 (uri (pypi-uri "cysignals" version ".tar.bz2"))
8852 (sha256
8853 (base32
8854 "14cbyd9znlz6cxy1s3g6v6dv5jj45hn27pywkidd9b1zanaysqc6"))))
8855 (build-system python-build-system)
8856 (native-inputs
8857 `(("python-cython" ,python-cython)
8858 ("python-setuptools" ,python-setuptools)
8859 ("python-sphinx" ,python-sphinx)))
8860 (inputs
8861 `(("pari-gp" ,pari-gp)))
8862 (arguments
8863 `(#:modules ((guix build python-build-system)
8864 ((guix build gnu-build-system) #:prefix gnu:)
8865 (guix build utils))
8866 ;; FIXME: Tests are executed after installation and currently fail
8867 ;; when not installing into standard locations; the author is working
8868 ;; on a fix.
8869 #:tests? #f
8870 #:phases
8871 (modify-phases %standard-phases
8872 (add-before
8873 'build 'configure
8874 (assoc-ref gnu:%standard-phases 'configure)))))
8875 (home-page
8876 "https://github.com/sagemath/cysignals")
8877 (synopsis
8878 "Handling of interrupts and signals for Cython")
8879 (description
8880 "The cysignals package provides mechanisms to handle interrupts (and
8881other signals and errors) in Cython code, using two related approaches,
8882for mixed Cython/Python code or external C libraries and pure Cython code,
8883respectively.")
8884 (license lgpl3+)))
8885
8886(define-public python2-cysignals
8887 (package-with-python2 python-cysignals))
8888
63bcec71
DM
8889(define-public python2-shedskin
8890 (package
8891 (name "python2-shedskin")
8892 (version "0.9.4")
8893 (source
8894 (origin
8895 (method url-fetch)
8896 (uri (string-append "https://github.com/shedskin/shedskin/"
8897 "releases/download/v" version
8898 "/shedskin-" version ".tgz"))
8899 (sha256
8900 (base32
8901 "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41"))))
8902 (build-system python-build-system)
8903 (arguments
8904 `(#:python ,python-2
8905 #:phases (modify-phases %standard-phases
8906 (add-after 'unpack 'fix-resulting-include-libs
8907 (lambda* (#:key inputs #:allow-other-keys)
8908 (let ((libgc (assoc-ref inputs "libgc"))
8909 (pcre (assoc-ref inputs "pcre")))
8910 (substitute* "shedskin/makefile.py"
8911 (("variable == 'CCFLAGS':[ ]*")
8912 (string-append "variable == 'CCFLAGS':\n"
8913 " line += ' -I " pcre "/include"
8914 " -I " libgc "/include'"))
8915 (("variable == 'LFLAGS':[ ]*")
8916 (string-append "variable == 'LFLAGS':\n"
8917 " line += ' -L" pcre "/lib"
8918 " -L " libgc "/lib'")))
8919 #t))))))
8920 (native-inputs `(("python2-setuptools" ,python2-setuptools)))
8921 (inputs `(("pcre" ,pcre)
8922 ("libgc" ,libgc)))
8923 (home-page "https://shedskin.github.io/")
8924 (synopsis "Experimental Python-2 to C++ Compiler")
8925 (description (string-append "This is an experimental compiler for a subset of
8926Python. It generates C++ code and a Makefile."))
8927 (license (list gpl3 bsd-3 license:expat))))
88bb4197
LG
8928
8929(define-public python2-rope
8930 (package
8931 (name "python2-rope")
8932 (version "0.10.3")
8933 (source
8934 (origin
8935 (method url-fetch)
8936 (uri (pypi-uri "rope" version))
8937 (sha256
8938 (base32
8939 "18k5znhpwvrfck3yp0jmhd5j8r0f0s8bk1zh5yhs2cfgmfhbwigb"))))
8940 (arguments
8941 ;; Rope is currently python-2 only.
8942 ;; https://github.com/python-rope/rope/issues/57
8943 `(#:python ,python-2))
8944 (build-system python-build-system)
8945 (native-inputs
8946 `(("python2-unittest2" ,python2-unittest2)
8947 ("python2-setuptools" ,python2-setuptools)))
8948 (home-page "https://github.com/python-rope/rope")
8949 (synopsis "Refactoring library for Python")
8950 (description "Rope is a refactoring library for Python. It facilitates
8951the renaming, moving and extracting of attributes, functions, modules, fields
8952and parameters in Python 2 source code. These refactorings can also be applied
8953to occurences in strings and comments.")
8954 (license gpl2)))
6ba8ca17
8955
8956(define-public python-py3status
8957 (package
8958 (name "python-py3status")
8959 (version "2.9")
8960 (source
8961 (origin
8962 (method url-fetch)
8963 (uri (pypi-uri "py3status" version))
8964 (sha256
8965 (base32
8966 "09y7h8rjay5kzwk5akq7f5f9wqnvjkxhivck04hdc8ny1nw3vqzp"))))
8967 (build-system python-build-system)
8968 (native-inputs
8969 `(("python-setuptools" ,python-setuptools)))
8970 (home-page "https://github.com/ultrabug/py3status")
8971 (synopsis "Extensible i3status wrapper written in Python")
8972 (description "py3status is an i3status wrapper which extends i3status
8973functionality in a modular way, allowing you to extend your panel with your
8974own code, responding to click events and updating clock every second.")
8975 (license bsd-3)))
b8fdbca3
HG
8976
8977(define-public python-tblib
8978 (package
8979 (name "python-tblib")
8980 (version "1.3.0")
8981 (source (origin
8982 (method url-fetch)
8983 (uri (pypi-uri "tblib" version))
8984 (sha256 (base32
8985 "02iahfkfa927hb4jq2bak36ldihwapzacfiq5lyxg8llwn98a1yi"))))
8986 (build-system python-build-system)
8987 (arguments
8988 `(#:phases
8989 (modify-phases %standard-phases
8990 (replace 'check
8991 (lambda _
8992 ;; Upstream runs tests after installation and the package itself
8993 ;; resides in a subdirectory. Extend PYTHONPATH so it will be
8994 ;; found.
8995 (setenv "PYTHONPATH"
8996 (string-append (getcwd) "/build/lib:"
8997 (getenv "PYTHONPATH")))
8998 (zero? (system* "py.test" "-vv" "tests" "README.rst")))))))
8999 (native-inputs
9000 `(("python-pytest" ,python-pytest)
9001 ("python-setuptools" ,python-setuptools)
9002 ("python-six" ,python-six)))
9003 (home-page "https://github.com/ionelmc/python-tblib")
9004 (synopsis "Traceback serialization library")
9005 (description
9006 "Traceback serialization allows you to:
9007
9008@enumerate
9009@item Pickle tracebacks and raise exceptions with pickled tracebacks in
9010different processes. This allows better error handling when running code over
9011multiple processes (imagine multiprocessing, billiard, futures, celery etc).
9012
9013@item Parse traceback strings and raise with the parsed tracebacks.
9014@end itemize")
9015 (license bsd-3)))
9016
9017(define-public python2-tblib
9018 (package-with-python2 python-tblib))
1a024de4
HG
9019
9020(define-public python-sqlparse
9021 (package
9022 (name "python-sqlparse")
9023 (version "0.1.19")
9024 (source (origin
9025 (method url-fetch)
9026 (uri (pypi-uri "sqlparse" version))
9027 (sha256
9028 (base32
9029 "1s2fvaxgh9kqzrd6iwy5h7i61ckn05plx9np13zby93z3hdbx5nq"))))
9030 (build-system python-build-system)
9031 (arguments
9032 `(#:phases
9033 (modify-phases %standard-phases
9034 (replace 'check
9035 (lambda* _
9036 ;; setup.py-integrated 2to3 only affects the build files, but
9037 ;; py.test is using the source files. So we need to convert them
9038 ;; manually.
9039 (when (zero? (system* "python3"))
9040 (system* "2to3" "--no-diff" "-wn" "sqlparse" "tests"))
9041 (zero? (system* "py.test")))))))
9042 (native-inputs
9043 `(("python-pytest" ,python-pytest)
9044 ("python-setuptools" ,python-setuptools)))
9045 (home-page "https://github.com/andialbrecht/sqlparse")
9046 (synopsis "Non-validating SQL parser")
9047 (description "Sqlparse is a non-validating SQL parser for Python. It
9048provides support for parsing, splitting and formatting SQL statements.")
9049 (license bsd-3)))
9050
9051(define-public python2-sqlparse
9052 (package-with-python2 python-sqlparse))
68b9d242
SB
9053
9054(define-public python-greenlet
9055 (package
9056 (name "python-greenlet")
9057 (version "0.4.9")
9058 (source (origin
9059 (method url-fetch)
9060 (uri (pypi-uri "greenlet" version))
9061 (sha256
9062 (base32
9063 "04h0m54dyqg49vyarq26mry6kbivnpl47rnmmrk9qn8wpfxviybr"))))
9064 (build-system python-build-system)
9065 (native-inputs
9066 `(("python-setuptools" ,python-setuptools)))
9067 (home-page "https://greenlet.readthedocs.io/")
9068 (synopsis "Lightweight in-process concurrent programming")
9069 (description
9070 "Greenlet package is a spin-off of Stackless, a version of CPython
9071that supports micro-threads called \"tasklets\". Tasklets run
9072pseudo-concurrently (typically in a single or a few OS-level threads) and
9073are synchronized with data exchanges on \"channels\".")
9074 (license (list psfl license:expat))))
9075
9076(define-public python2-greenlet
9077 (package-with-python2 python-greenlet))
d79a343b
SB
9078
9079(define-public python-gevent
9080 (package
9081 (name "python-gevent")
9082 (version "1.1.1")
9083 (source (origin
9084 (method url-fetch)
9085 (uri (pypi-uri "gevent" version))
9086 (sha256
9087 (base32
9088 "1smf3kvidpdiyi2c81alal74p2zm0clrm6xbyy6y1k9a3f2vkrbf"))
9089 (modules '((guix build utils)))
9090 (snippet
9091 '(begin
9092 ;; unbunding libev and c-ares
9093 (for-each delete-file-recursively '("libev" "c-ares"))
9094 ;; fixing testsuite
9095 (call-with-output-file "greentest/__init__.py" noop)
9096 (substitute* "greentest/testrunner.py"
9097 (("import util") "from . import util")
9098 (("from util import log") "from .util import log"))))))
9099 (build-system python-build-system)
9100 (propagated-inputs
9101 `(("python-greenlet" ,python-greenlet)))
9102 (native-inputs
9103 `(("python-setuptools" ,python-setuptools)
9104 ("python-six" ,python-six)))
9105 (inputs
9106 `(("c-ares" ,c-ares)
9107 ("libev" ,libev)))
9108 (home-page "http://www.gevent.org/")
9109 (synopsis "Coroutine-based network library")
9110 (description
9111 "gevent is a coroutine-based Python networking library that uses greenlet
9112to provide a high-level synchronous API on top of the libev event loop.")
9113 (license license:expat)))
9114
9115(define-public python2-gevent
9116 (package-with-python2 python-gevent))
da3aeeb6
SB
9117
9118(define-public python-twisted
9119 (package
9120 (name "python-twisted")
9121 (version "16.2.0")
9122 (source (origin
9123 (method url-fetch)
8ea8e8d3 9124 (uri (pypi-uri "Twisted" version ".tar.bz2"))
da3aeeb6
SB
9125 (sha256
9126 (base32
9127 "0ydxrp9myw1mvsz3qfzx5579y5llmqa82pxvqchgp5syczffi450"))))
9128 (build-system python-build-system)
9129 (native-inputs
45912170
SB
9130 `(("python-setuptools" ,python-setuptools)))
9131 (propagated-inputs
9132 `(("python-zope-interface" ,python-zope-interface)))
da3aeeb6
SB
9133 (home-page "https://twistedmatrix.com/")
9134 (synopsis "Asynchronous networking framework written in Python")
9135 (description
9136 "Twisted is an extensible framework for Python programming, with special
9137focus on event-based network programming and multiprotocol integration.")
9138 (license license:expat)))
9139
9140(define-public python2-twisted
9141 (package-with-python2 python-twisted))
d0b6fed6
DM
9142
9143(define-public python-ply
9144 (package
9145 (name "python-ply")
9146 (version "3.8")
9147 (source
9148 (origin
9149 (method url-fetch)
9150 (uri (string-append
9151 "https://pypi.python.org/packages/"
9152 "96/e0/430fcdb6b3ef1ae534d231397bee7e9304be14a47a267e82ebcb3323d0b5"
9153 "/ply-" version ".tar.gz"))
9154 (sha256
9155 (base32
9156 "1f70ipynmiy09k6px2j7v4w5cdrc21za3xs2k6f1bsvb0bzvvlg7"))))
9157 (build-system python-build-system)
9158 (home-page "http://www.dabeaz.com/ply/")
9159 (synopsis "Python Lex & Yacc")
9160 (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python.
9161It uses LR parsing and does extensive error checking.")
9162 (license bsd-3)
9163 (properties `((python2-variant . ,(delay python2-ply))))))
9164
9165(define-public python2-ply
9166 (package
9167 (inherit (package-with-python2
9168 (strip-python2-variant python-ply)))
9169 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
d951bd54
SB
9170
9171(define-public python-tabulate
9172 (package
9173 (name "python-tabulate")
9174 (version "0.7.5")
9175 (source (origin
9176 (method url-fetch)
9177 (uri (pypi-uri "tabulate" version))
9178 (sha256
9179 (base32
9180 "03l1r7ddd1a0j2snv1yd0hlnghjad3fg1an1jr8936ksv75slwch"))
9181 ;; Fix tests
9182 (modules '((guix build utils)))
9183 (snippet '(substitute* '("test/test_cli.py"
9184 "test/test_input.py"
9185 "test/test_output.py"
9186 "test/test_regression.py")
9187 (("from common") "from nose.tools")))))
9188 (build-system python-build-system)
9189 (native-inputs
9190 `(("python-setuptools" ,python-setuptools)
9191 ;; For testing
9192 ("python-nose" ,python-nose)))
9193 (home-page "https://bitbucket.org/astanin/python-tabulate")
9194 (synopsis "Pretty-print tabular data")
9195 (description
9196 "Tabulate is a library and command-line utility to pretty-print tabular
9197data in Python.")
9198 (license license:expat)))
9199
9200(define-public python2-tabulate
9201 (package-with-python2 python-tabulate))
1c4c8a33
SB
9202
9203(define-public python-kazoo
9204 (package
9205 (name "python-kazoo")
9206 (version "2.2.1")
9207 (source
9208 (origin
9209 (method url-fetch)
9210 (uri (pypi-uri "kazoo" version))
9211 (sha256
9212 (base32
9213 "10pb864if9qi2pq9lfb9m8f7z7ss6rml80gf1d9h64lap5crjnjj"))))
9214 (build-system python-build-system)
9215 (arguments '(#:tests? #f)) ; XXX: needs zookeeper
9216 (native-inputs
c18899e8
SB
9217 `(("python-setuptools" ,python-setuptools)))
9218 (propagated-inputs
9219 `(("python-six" ,python-six)))
1c4c8a33
SB
9220 (home-page "https://kazoo.readthedocs.org")
9221 (synopsis "High-level Zookeeper client library")
9222 (description
9223 "Kazoo is a Python client library for the Apache Zookeeper distributed
9224application service. It is designed to be easy to use and to avoid common
9225programming errors.")
9226 (license asl2.0)))
9227
9228(define-public python2-kazoo
9229 (package-with-python2 python-kazoo))
45dda35e
SB
9230
9231(define-public python-pykafka
9232 (package
9233 (name "python-pykafka")
9234 (version "2.4.0")
9235 (source (origin
9236 (method url-fetch)
c6bccf71
EF
9237 (uri (string-append
9238 "https://pypi.python.org/packages/8b/3e/"
9239 "384eeff406b06315738b62483fd2126c6e4f544167116b17cc04ea7d2a59/"
9240 "pykafka-" version ".tar.gz"))
45dda35e
SB
9241 (sha256
9242 (base32
9243 "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv"))))
9244 (build-system python-build-system)
9245 (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc.
9246 (native-inputs
c8fa3d9b
SB
9247 `(("python-setuptools" ,python-setuptools)))
9248 (propagated-inputs
45dda35e
SB
9249 `(("python-gevent" ,python-gevent)
9250 ("python-kazoo" ,python-kazoo)
45dda35e
SB
9251 ("python-tabulate" ,python-tabulate)))
9252 (inputs
9253 `(("librdkafka" ,librdkafka)))
9254 (home-page "https://pykafka.readthedocs.io/")
9255 (synopsis "Apache Kafka client for Python")
9256 (description
9257 "PyKafka is a client for the Apache Kafka distributed messaging system.
9258It includes Python implementations of Kafka producers and consumers, which
9259are optionally backed by a C extension built on librdkafka.")
9260 (license asl2.0)))
9261
9262(define-public python2-pykafka
9263 (package-with-python2 python-pykafka))
a44fd439
DM
9264
9265(define-public python-wcwidth
9266 (package
9267 (name "python-wcwidth")
9268 (version "0.1.6")
9269 (source
9270 (origin
9271 (method url-fetch)
9272 (uri (string-append
9273 "https://pypi.python.org/packages/"
9274 "c2/d1/7689293086a8d5320025080cde0e3155b94ae0a7496fb89a3fbaa92c354a/"
9275 "wcwidth-" version ".tar.gz"))
9276 (sha256
9277 (base32
9278 "02wjrpf001gjdjsaxxbzcwfg19crlk2dbddayrfc2v06f53yrcyw"))))
9279 (build-system python-build-system)
9280 (home-page "https://github.com/jquast/wcwidth")
9281 (synopsis "Measure number of terminal column cells of wide-character codes.")
9282 (description "Wcwidth measures the number of terminal column cells of
9283wide-character codes. It is useful for those implementing a terminal emulator,
9284or programs that carefully produce output to be interpreted by one. It is a
9285Python implementation of the @code{wcwidth} and @code{wcswidth} C functions
9286specified in POSIX.1-2001 and POSIX.1-2008.")
e4875826
LF
9287 (license license:expat)
9288 (properties `((python2-variant . ,(delay python2-wcwidth))))))
a44fd439
DM
9289
9290(define-public python2-wcwidth
9291 (package
9292 (inherit (package-with-python2
9293 (strip-python2-variant python-wcwidth)))
9294 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
0de78c95
DP
9295
9296(define-public python2-jsonrpclib
9297 (package
9298 (name "python2-jsonrpclib")
9299 (version "0.1.7")
9300 (source (origin
9301 (method url-fetch)
9302 (uri (string-append
9303 "https://pypi.python.org/packages/source/j/jsonrpclib/"
9304 "jsonrpclib-" version ".tar.gz"))
9305 (sha256
9306 (base32
9307 "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z"))))
9308 (build-system python-build-system)
9309 (native-inputs
9310 `(("python2-setuptools" ,python2-setuptools)))
9311 (arguments
9312 `(#:tests? #f
9313 #:python ,python-2))
9314 (home-page "https://github.com/joshmarshall/jsonrpclib/")
9315 (synopsis "Implementation of JSON-RPC specification for Python")
9316 (description
9317 "This library is an implementation of the JSON-RPC specification.
9318It supports both the original 1.0 specification, as well as the
9319new (proposed) 2.0 spec, which includes batch submission, keyword arguments,
9320etc.")
9321 (license asl2.0)))
9250b0f3
SB
9322
9323(define-public python-chai
9324 (package
9325 (name "python-chai")
9326 (version "1.1.1")
9327 (source (origin
9328 (method url-fetch)
9329 (uri (pypi-uri "chai" version))
9330 (sha256
9331 (base32
9332 "016kf3irrclpkpvcm7q0gmkfibq7jgy30a9v73pp42bq9h9a32bl"))))
9333 (build-system python-build-system)
9334 (native-inputs
9335 `(("python-setuptools" ,python-setuptools)))
9336 (home-page "https://github.com/agoragames/chai")
9337 (synopsis "Mocking framework for Python")
9338 (description
9339 "Chai provides an api for mocking, stubbing and spying your python
9340objects, patterned after the Mocha library for Ruby.")
9341 (license bsd-3)))
9342
9343(define-public python2-chai
9344 (package-with-python2 python-chai))
9345
ae43baa8
SB
9346(define-public python-arrow
9347 (package
9348 (name "python-arrow")
9349 (version "0.8.0")
9350 (source (origin
9351 (method url-fetch)
9352 (uri (pypi-uri "arrow" version))
9353 (sha256
9354 (base32
9355 "1bz7hkdgpqcjs866y58z8jywpy7al0f4rxdr00bh2l5qddyw245j"))))
9356 (build-system python-build-system)
9357 (native-inputs
9358 `(("python-setuptools" ,python-setuptools)
ae43baa8
SB
9359 ;; For testing
9360 ("python-chai" ,python-chai)
9361 ("python-simplejson" ,python-simplejson)))
36aed736
SB
9362 (propagated-inputs
9363 `(("python-dateutil" ,python-dateutil-2)))
ae43baa8
SB
9364 (home-page "https://github.com/crsmithdev/arrow/")
9365 (synopsis "Dates and times for Python")
9366 (description
9367 "Arrow is a Python library to creating, manipulating, formatting and
9368converting dates, times, and timestamps. It implements and updates the
9369datetime type.")
9370 (license asl2.0)))
9371
9372(define-public python2-arrow
9373 (package-with-python2 python-arrow))
9374
1f2b62a4
SB
9375(define-public python-inflection
9376 (package
9377 (name "python-inflection")
9378 (version "0.3.1")
9379 (source
9380 (origin (method url-fetch)
9381 (uri (pypi-uri "inflection" version))
9382 (sha256
9383 (base32
9384 "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq"))))
9385 (build-system python-build-system)
9386 (native-inputs
9387 `(("python-setuptools" ,python-setuptools)))
9388 (home-page "http://github.com/jpvanhal/inflection")
9389 (synopsis "Python string transformation library")
9390 (description
9391 "Inflection is a string transformation library. It singularizes
9392and pluralizes English words, and transforms strings from CamelCase to
9393underscored string.")
9394 (license license:expat)))
9395
9396(define-public python2-inflection
9397 (package-with-python2 python-inflection))
9398
18995566
SB
9399(define-public python-pylev
9400 (package
9401 (name "python-pylev")
9402 (version "1.3.0")
9403 (source (origin
9404 (method url-fetch)
9405 (uri (pypi-uri "pylev" version))
9406 (sha256
9407 (base32
9408 "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86"))))
9409 (build-system python-build-system)
9410 (native-inputs
9411 `(("python-setuptools" ,python-setuptools)))
9412 (home-page "http://github.com/toastdriven/pylev")
9413 (synopsis "Levenshtein distance implementation in Python")
9414 (description "Pure Python Levenshtein implementation, based off the
9415Wikipedia code samples at
9416@url{http://en.wikipedia.org/wiki/Levenshtein_distance}.")
9417 (license bsd-3)))
9418
9419(define-public python2-pylev
9420 (package-with-python2 python-pylev))
9421
f5deff7a
SB
9422(define-public python-cleo
9423 (package
9424 (name "python-cleo")
9425 (version "0.4.1")
9426 (source (origin
9427 (method url-fetch)
9428 (uri (pypi-uri "cleo" version))
9429 (sha256
9430 (base32
9431 "1k2dcl6mqpn5bljyl6w42rqyd9mb3y9kh2mg7m2x3kfjwvg0rpva"))))
9432 (build-system python-build-system)
9433 (native-inputs
9403150a 9434 `(("python-setuptools" ,python-setuptools)
f5deff7a
SB
9435 ;; For testing
9436 ("python-mock" ,python-mock)
9437 ("python-pytest" ,python-pytest)))
9403150a
SB
9438 (propagated-inputs
9439 `(("python-psutil" ,python-psutil)
9440 ("python-pylev" ,python-pylev)))
f5deff7a
SB
9441 (home-page "https://github.com/sdispater/cleo")
9442 (synopsis "Command-line arguments library for Python")
9443 (description
9444 "Cleo allows you to create command-line commands with signature in
9445docstring and colored output.")
9446 (license license:expat)))
9447
9448(define-public python2-cleo
9449 (package-with-python2 python-cleo))
9450
77cadb43
SB
9451(define-public python-lazy-object-proxy
9452 (package
9453 (name "python-lazy-object-proxy")
9454 (version "1.2.2")
9455 (source (origin
9456 (method url-fetch)
9457 (uri (pypi-uri "lazy-object-proxy" version))
9458 (sha256
9459 (base32
9460 "0s22aqqkdscyh8sjspyyax7qa1aiz8p4midrnyf39717fhfczm6x"))))
9461 (build-system python-build-system)
9462 (native-inputs
9463 `(("python-setuptools" ,python-setuptools)))
9464 (home-page "https://github.com/ionelmc/python-lazy-object-proxy")
9465 (synopsis "Lazy object proxy for python")
9466 (description
9467 "Lazy object proxy is an object that wraps a callable but defers the call
9468until the object is actually required, and caches the result of said call.")
9469 (license bsd-2)))
9470
9471(define-public python2-lazy-object-proxy
9472 (package-with-python2 python-lazy-object-proxy))
9473
5477e05f
SB
9474(define-public python-dnspython
9475 (package
9476 (name "python-dnspython")
9477 (version "1.14.0")
9478 (source (origin
9479 (method url-fetch)
9480 (uri (string-append "http://www.dnspython.org/kits/"
9481 version "/dnspython-" version ".tar.gz"))
9482 (sha256
9483 (base32
9484 "1z472r63gdqsxhsxj3plr5vs478yf4303vrqxxpsccc940g441hl"))))
9485 (build-system python-build-system)
9486 (arguments '(#:tests? #f)) ; XXX: requires internet access
9487 (native-inputs
9488 `(("python-setuptools" ,python-setuptools)))
9489 (home-page "http://www.dnspython.org")
9490 (synopsis "DNS toolkit for Python")
9491 (description
9492 "dnspython is a DNS toolkit for Python. It supports almost all record
9493types. It can be used for queries, zone transfers, and dynamic updates.
9494It supports TSIG authenticated messages and EDNS0.")
9495 (license license:expat)))
9496
9497(define-public python2-dnspython
9498 (package-with-python2 python-dnspython))
9499
22711e25
SB
9500(define-public python-email-validator
9501 (package
9502 (name "python-email-validator")
9503 (version "1.0.1")
9504 (source
9505 (origin (method url-fetch)
9506 (uri (pypi-uri "email_validator" version))
9507 (sha256
9508 (base32
9509 "0mn8jg5h8ifl8w6a6m0hq8kbk0mzw9vm054qfamkn89b3npz52qw"))))
9510 (build-system python-build-system)
9511 (arguments
9512 '(#:phases
9513 (modify-phases %standard-phases
9514 (add-before 'build 'use-dnspython
9515 (lambda _
9516 (substitute* "setup.py"
9517 (("dnspython3") "dnspython"))
9518 #t)))))
9519 (native-inputs
d42560bd
SB
9520 `(("python-setuptools" ,python-setuptools)))
9521 (propagated-inputs
22711e25 9522 `(("python-dnspython" ,python-dnspython)
d42560bd 9523 ("python-idna" ,python-idna)))
22711e25
SB
9524 (home-page "https://github.com/JoshData/python-email-validator")
9525 (synopsis "Email address validation library for Python")
9526 (description
9527 "This library validates email address syntax and deliverability.")
9528 (license cc0)))
9529
9530(define-public python2-email-validator
9531 (package-with-python2 python-email-validator))
9532
8987d91e
SB
9533(define-public python-ukpostcodeparser
9534 (package
9535 (name "python-ukpostcodeparser")
9536 (version "1.0.3")
9537 (source (origin
9538 (method url-fetch)
9539 (uri (pypi-uri "UkPostcodeParser" version))
9540 (sha256
9541 (base32
9542 "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd"))))
9543 (build-system python-build-system)
9544 (native-inputs
9545 `(("python-setuptools" ,python-setuptools)))
9546 (home-page "https://github.com/hamstah/ukpostcodeparser")
9547 (synopsis "UK Postcode parser for Python")
9548 (description
9549 "This library provides the @code{parse_uk_postcode} function for
9550parsing UK postcodes.")
9551 (license license:expat)))
9552
9553(define-public python2-ukpostcodeparser
9554 (package-with-python2 python-ukpostcodeparser))
ea92ae01
SB
9555
9556(define-public python-fake-factory
9557 (package
9558 (name "python-fake-factory")
9559 (version "0.5.7")
9560 (source (origin
9561 (method url-fetch)
9562 (uri (pypi-uri "fake-factory" version))
9563 (sha256
9564 (base32
9565 "1chmarnrdzn4r017n8qlic0m0bbnhw04s3hkwribjvm3mqpb6pa0"))))
9566 (build-system python-build-system)
9567 (arguments
9568 '(#:phases
9569 (modify-phases %standard-phases
9570 (add-before 'check 'disable-failing-test
9571 ;; XXX: faker/tests/ne_np/__init__.py, line 40, in test_names
9572 ;; first_name, last_name = name.split()
9573 ;; ValueError: too many values to unpack (expected 2)
9574 (lambda _
9575 (delete-file "faker/tests/ne_np/__init__.py")
9576 #t)))))
9577 (native-inputs
bbcd7297 9578 `(("python-setuptools" ,python-setuptools)
ea92ae01
SB
9579 ;; For testing
9580 ("python-email-validator" ,python-email-validator)
9581 ("python-mock" ,python-mock)
9582 ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
bbcd7297
SB
9583 (propagated-inputs
9584 `(("python-dateutil" ,python-dateutil-2)
9585 ("python-six" ,python-six)))
ea92ae01
SB
9586 (home-page "http://github.com/joke2k/faker")
9587 (synopsis "Python package that generates fake data")
9588 (description
9589 "Faker is a Python package that generates fake data such as names,
9590addresses, and phone numbers.")
9591 (license license:expat)
9592 (properties `((python2-variant . ,(delay python2-fake-factory))))))
9593
9594(define-public python2-fake-factory
9595 (let ((base (package-with-python2 (strip-python2-variant
9596 python-fake-factory))))
9597 (package
9598 (inherit base)
24c9aa18 9599 (propagated-inputs
ea92ae01 9600 `(("python2-ipaddress" ,python2-ipaddress)
24c9aa18 9601 ,@(package-propagated-inputs base))))))
ea92ae01 9602
b49504fd
SB
9603(define-public python-pyaml
9604 (package
9605 (name "python-pyaml")
9606 (version "15.8.2")
9607 (source (origin
9608 (method url-fetch)
9609 (uri (pypi-uri "pyaml" version))
9610 (sha256
9611 (base32
9612 "1f5m28vkh4ksq3d80d8mmd2z8wxvc3mgy2pmrv2751dm2xgznm4w"))))
9613 (build-system python-build-system)
9614 (native-inputs
9615 `(("python-setuptools" ,python-setuptools)))
9616 (propagated-inputs
9617 `(("python-pyyaml" ,python-pyyaml)))
9618 (home-page "https://github.com/mk-fg/pretty-yaml")
9619 (synopsis "YAML pretty-print library for Python")
9620 (description
9621 "pyaml is a PyYAML based python module to produce pretty and readable
9622YAML-serialized data.")
9623 (license (non-copyleft "http://www.wtfpl.net/txt/copying/"))))
9624
9625(define-public python2-pyaml
9626 (package-with-python2 python-pyaml))
9627
347175a2
SB
9628(define-public python-flexmock
9629 (package
9630 (name "python-flexmock")
9631 (version "0.10.2")
9632 (source (origin
9633 (method url-fetch)
9634 (uri (pypi-uri "flexmock" version))
9635 (sha256
9636 (base32
9637 "0arc6njvs6i9v9hgvzk5m50296g7zy5m9d7pyb43vdsdgxrci5gy"))))
9638 (build-system python-build-system)
9639 (native-inputs
9640 `(("python-setuptools" ,python-setuptools)))
9641 (home-page "https://flexmock.readthedocs.org")
9642 (synopsis "Testing library for Python")
9643 (description
9644 "flexmock is a testing library for Python that makes it easy to create
9645mocks, stubs and fakes.")
9646 (license bsd-3)))
9647
9648(define-public python2-flexmock
9649 (package-with-python2 python-flexmock))
9650
5a744191
SB
9651(define-public python-orator
9652 (package
9653 (name "python-orator")
9654 (version "0.8.2")
9655 (source (origin
9656 (method url-fetch)
9657 (uri (pypi-uri "orator" version))
9658 (sha256
9659 (base32
9660 "1li49irsqha17nrda4nsb48biyy0rarp9pphf0jpqwm5zr8hv569"))))
9661 (build-system python-build-system)
9662 (arguments '(#:tests? #f)) ; no tests
9663 (native-inputs
b2676030
SB
9664 `(("python-setuptools" ,python-setuptools)))
9665 (propagated-inputs
5a744191
SB
9666 `(("python-arrow" ,python-arrow)
9667 ("python-blinker" ,python-blinker)
9668 ("python-cleo" ,python-cleo)
9669 ("python-fake-factory" ,python-fake-factory)
9670 ("python-inflection" ,python-inflection)
9671 ("python-lazy-object-proxy" ,python-lazy-object-proxy)
9672 ("python-pyaml" ,python-pyaml)
5a744191
SB
9673 ("python-simplejson" ,python-simplejson)
9674 ("python-wrapt" ,python-wrapt)))
9675 (home-page "https://orator-orm.com/")
9676 (synopsis "ActiveRecord ORM for Python")
9677 (description
9678 "Orator provides a simple ActiveRecord-like Object Relational Mapping
9679implementation for Python.")
9680 (license license:expat)
9681 (properties `((python2-variant . ,(delay python2-orator))))))
9682
9683(define-public python2-orator
9684 (let ((base (package-with-python2 (strip-python2-variant python-orator))))
9685 (package
9686 (inherit base)
06961617 9687 (propagated-inputs
5a744191 9688 `(("python2-ipaddress" ,python2-ipaddress)
06961617 9689 ,@(package-propagated-inputs base))))))
f4155188
DM
9690
9691(define-public python-prompt-toolkit
9692 (package
9693 (name "python-prompt-toolkit")
9694 (version "1.0.3")
9695 (source
9696 (origin
9697 (method url-fetch)
9698 (uri (string-append
9699 "https://pypi.python.org/packages/"
9700 "8d/de/412f23919929c01e6b55183e124623f705e4b91796d3d2dce2cb53d595ad/"
9701 "prompt_toolkit-" version ".tar.gz"))
9702 (sha256
9703 (base32
9704 "18lbmmkyjf509klc3217lq0x863pfzix779zx5kp9lms1iph4pl0"))))
9705 (build-system python-build-system)
9706 (inputs `(("python-wcwidth" ,python-wcwidth)
9707 ("python-pygments" ,python-pygments)))
9708 (native-inputs `(("python-six" ,python-six)))
9709 (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
9710 (synopsis "Library for building command line interfaces in Python")
9711 (description
9712 "Prompt-Toolkit is a library for building interactive command line
9713interfaces in Python. It's like GNU Readline but it also features syntax
9714highlighting while typing, out-of-the-box multi-line input editing, advanced
9715code completion, incremental search, support for Chinese double-width
9716characters, mouse support, and auto suggestions.")
9717 (license bsd-3)
9718 (properties `((python2-variant . ,(delay python2-prompt-toolkit))))))
9719
9720(define-public python2-prompt-toolkit
9721 (let ((base (package-with-python2 (strip-python2-variant python-prompt-toolkit))))
9722 (package
9723 (inherit base)
9724 (native-inputs
9725 `(("python2-setuptools" ,python2-setuptools)
9726 ,@(package-native-inputs base))))))
a502dfbf
DM
9727
9728(define-public python-jedi
9729 (package
9730 (name "python-jedi")
9731 (version "0.9.0")
9732 (source
9733 (origin
9734 (method url-fetch)
9735 (uri (pypi-uri "jedi" version))
9736 (sha256
9737 (base32
9738 "0c8x962ynpx001fdvp07m2q5jk4igkxbj3rmnydavphvlgxijk1v"))))
9739 (build-system python-build-system)
9740 (home-page "https://github.com/davidhalter/jedi")
9741 (synopsis
9742 "Autocompletion for Python that can be used for text editors")
9743 (description
9744 "Jedi is an autocompletion tool for Python that can be used for text editors.")
9745 (license license:expat)
9746 (properties `((python2-variant . ,(delay python2-jedi))))))
9747
9748(define-public python2-jedi
9749 (let ((base (package-with-python2 (strip-python2-variant python-jedi))))
9750 (package
9751 (inherit base)
9752 (native-inputs
9753 `(("python2-setuptools" ,python2-setuptools)
9754 ,@(package-native-inputs base))))))