gnu: python-vobject: Disable the test suite.
[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>
6eb7af2a 27;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
3f641af0 28;;; Copyright © 2016 David Craven <david@craven.ch>
dddcb25c 29;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
4efb9c54 30;;; Copyright © 2016 Stefan Reichoer <stefan@xsteve.at>
b04a52a6 31;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
a01b6da7
NK
32;;;
33;;; This file is part of GNU Guix.
34;;;
35;;; GNU Guix is free software; you can redistribute it and/or modify it
36;;; under the terms of the GNU General Public License as published by
37;;; the Free Software Foundation; either version 3 of the License, or (at
38;;; your option) any later version.
39;;;
40;;; GNU Guix is distributed in the hope that it will be useful, but
41;;; WITHOUT ANY WARRANTY; without even the implied warranty of
42;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
43;;; GNU General Public License for more details.
44;;;
45;;; You should have received a copy of the GNU General Public License
46;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
47
1ffa7090 48(define-module (gnu packages python)
3f641af0 49 #:use-module ((guix licenses) #: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)
3969ca54 55 #:use-module (gnu packages bash)
1ffa7090 56 #:use-module (gnu packages compression)
4ed20663 57 #:use-module (gnu packages databases)
ddc63a56 58 #:use-module (gnu packages django)
5e1c9367 59 #:use-module (gnu packages file)
4ed20663 60 #:use-module (gnu packages fontutils)
4ed20663
AE
61 #:use-module (gnu packages gcc)
62 #:use-module (gnu packages ghostscript)
6eb7af2a 63 #:use-module (gnu packages gl)
4ed20663 64 #:use-module (gnu packages glib)
6eb7af2a 65 #:use-module (gnu packages gstreamer)
4ed20663 66 #:use-module (gnu packages gtk)
421a80a2 67 #:use-module (gnu packages icu4c)
c937562e 68 #:use-module (gnu packages image)
4ed20663 69 #:use-module (gnu packages imagemagick)
d79a343b 70 #:use-module (gnu packages libevent)
b10ab723 71 #:use-module (gnu packages libffi)
89b2e0b0 72 #:use-module (gnu packages linux)
0da98533 73 #:use-module (gnu packages maths)
4ed20663 74 #:use-module (gnu packages multiprecision)
45203542 75 #:use-module (gnu packages networking)
be7134bf 76 #:use-module (gnu packages ncurses)
b04a52a6 77 #:use-module (gnu packages openstack)
d488d5d6 78 #:use-module (gnu packages password-utils)
c9b1b4f9 79 #:use-module (gnu packages pcre)
4ed20663 80 #:use-module (gnu packages perl)
b10ab723 81 #:use-module (gnu packages pkg-config)
4ed20663 82 #:use-module (gnu packages readline)
6eb7af2a 83 #:use-module (gnu packages sdl)
c9b1b4f9 84 #:use-module (gnu packages statistics)
8f9ac901 85 #:use-module (gnu packages tex)
1c65314c 86 #:use-module (gnu packages texinfo)
cc2b77df 87 #:use-module (gnu packages tls)
e25f0174 88 #:use-module (gnu packages version-control)
8d12be1e 89 #:use-module (gnu packages web)
ce0614dd 90 #:use-module (gnu packages base)
26b307e2 91 #:use-module (gnu packages xml)
6fa14469 92 #:use-module (gnu packages xorg)
0bdc1671 93 #:use-module (gnu packages xdisorg)
4ed20663 94 #:use-module (gnu packages zip)
afa181ff 95 #:use-module (gnu packages tcl)
63bcec71 96 #:use-module (gnu packages bdw-gc)
a01b6da7
NK
97 #:use-module (guix packages)
98 #:use-module (guix download)
ea5456c8 99 #:use-module (guix git-download)
11bb85a1 100 #:use-module (guix utils)
acc26ff1 101 #:use-module (guix build-system gnu)
d8c4998f 102 #:use-module (guix build-system cmake)
898238b9 103 #:use-module (guix build-system python)
1c65314c
FB
104 #:use-module (guix build-system trivial)
105 #:use-module (srfi srfi-1))
a01b6da7 106
45848023 107(define-public python-2.7
a01b6da7
NK
108 (package
109 (name "python")
f0499100 110 (version "2.7.12")
a01b6da7
NK
111 (source
112 (origin
113 (method url-fetch)
9b43a0ff 114 (uri (string-append "https://www.python.org/ftp/python/"
a01b6da7
NK
115 version "/Python-" version ".tar.xz"))
116 (sha256
117 (base32
f0499100 118 "0y7rl603vmwlxm6ilkhc51rx2mfj14ckcz40xxgs0ljnvlhp30yp"))
c3052d6b
ML
119 (patches (search-patches "python-2.7-search-paths.patch"
120 "python-2-deterministic-build-info.patch"
121 "python-2.7-source-date-epoch.patch"))
10a42aa2
EF
122 (modules '((guix build utils)))
123 ;; suboptimal to delete failing tests here, but if we delete them in the
124 ;; arguments then we need to make sure to strip out that phase when it
125 ;; gets inherited by python and python-minimal.
126 (snippet
127 '(begin
128 (for-each delete-file
129 '("Lib/test/test_compileall.py"
f0499100 130 "Lib/test/test_ctypes.py" ; fails on mips64el
10a42aa2
EF
131 "Lib/test/test_distutils.py"
132 "Lib/test/test_import.py"
133 "Lib/test/test_shutil.py"
134 "Lib/test/test_socket.py"
1bb163b0 135 "Lib/test/test_subprocess.py"))
10a42aa2 136 #t))))
02f0c3b2
LC
137 (outputs '("out"
138 "tk")) ;tkinter; adds 50 MiB to the closure
a01b6da7 139 (build-system gnu-build-system)
3fdc99da 140 (arguments
10a42aa2 141 `(;; 356 tests OK.
e7e7a1eb
EF
142 ;; 6 tests failed:
143 ;; test_compileall test_distutils test_import test_shutil test_socket
144 ;; test_subprocess
145 ;; 39 tests skipped:
ff6f33cf
ED
146 ;; test_aepack test_al test_applesingle test_bsddb test_bsddb185
147 ;; test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk
e7e7a1eb
EF
148 ;; test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses
149 ;; test_dl test_gdb test_gl test_imageop test_imgfile test_ioctl
150 ;; test_kqueue test_linuxaudiodev test_macos test_macostools
151 ;; test_msilib test_ossaudiodev test_scriptpackages test_smtpnet
152 ;; test_socketserver test_startfile test_sunaudiodev test_timeout
153 ;; test_tk test_ttk_guionly test_urllib2net test_urllibnet
154 ;; test_winreg test_winsound test_zipfile64
155 ;; 4 skips unexpected on linux2:
156 ;; test_bsddb test_bsddb3 test_gdb test_ioctl
af807dea 157 #:test-target "test"
3fdc99da 158 #:configure-flags
6a20289d
LC
159 (list "--enable-shared" ;allow embedding
160 "--with-system-ffi" ;build ctypes
161 (string-append "LDFLAGS=-Wl,-rpath="
162 (assoc-ref %outputs "out") "/lib"))
fd982732 163
d2cc9c7c
LC
164 #:modules ((ice-9 ftw) (ice-9 match)
165 (guix build utils) (guix build gnu-build-system))
fd982732 166 #:phases
46472ecd
MW
167 (modify-phases %standard-phases
168 (add-before
169 'configure 'patch-lib-shells
170 (lambda _
171 ;; Filter for existing files, since some may not exist in all
172 ;; versions of python that are built with this recipe.
173 (substitute* (filter file-exists?
174 '("Lib/subprocess.py"
175 "Lib/popen2.py"
176 "Lib/distutils/tests/test_spawn.py"
177 "Lib/test/test_subprocess.py"))
178 (("/bin/sh") (which "sh")))
dedc8320
LC
179
180 ;; Use zero as the timestamp in .pyc files so that builds are
181 ;; deterministic. TODO: Remove it when this variable is set in
182 ;; gnu-build-system.scm.
a665996f 183 (setenv "SOURCE_DATE_EPOCH" "1")
46472ecd 184 #t))
5b4e2791
LC
185 (add-before 'configure 'do-not-record-configure-flags
186 (lambda* (#:key configure-flags #:allow-other-keys)
187 ;; Remove configure flags from the installed '_sysconfigdata.py'
188 ;; and 'Makefile' so we don't end up keeping references to the
189 ;; build tools.
190 ;;
191 ;; Preserve at least '--with-system-ffi' since otherwise the
192 ;; thing tries to build libffi, fails, and we end up with a
193 ;; Python that lacks ctypes.
194 (substitute* "configure"
195 (("^CONFIG_ARGS=.*$")
196 (format #f "CONFIG_ARGS='~a'\n"
197 (if (member "--with-system-ffi" configure-flags)
198 "--with-system-ffi"
199 ""))))
200 #t))
46472ecd
MW
201 (add-before
202 'check 'pre-check
203 (lambda _
204 ;; 'Lib/test/test_site.py' needs a valid $HOME
205 (setenv "HOME" (getcwd))
206 #t))
207 (add-after
208 'unpack 'set-source-file-times-to-1980
209 ;; XXX One of the tests uses a ZIP library to pack up some of the
210 ;; source tree, and fails with "ZIP does not support timestamps
211 ;; before 1980". Work around this by setting the file times in the
212 ;; source tree to sometime in early 1980.
213 (lambda _
214 (let ((circa-1980 (* 10 366 24 60 60)))
215 (ftw "." (lambda (file stat flag)
216 (utime file circa-1980 circa-1980)
217 #t))
02f0c3b2 218 #t)))
9ffe61b0
LC
219 (add-after 'install 'remove-tests
220 ;; Remove 25 MiB of unneeded unit tests. Keep test_support.*
221 ;; because these files are used by some libraries out there.
222 (lambda* (#:key outputs #:allow-other-keys)
223 (let ((out (assoc-ref outputs "out")))
224 (match (scandir (string-append out "/lib")
225 (lambda (name)
226 (string-prefix? "python" name)))
227 ((pythonX.Y)
228 (let ((testdir (string-append out "/lib/" pythonX.Y
229 "/test")))
230 (with-directory-excursion testdir
231 (for-each delete-file-recursively
232 (scandir testdir
233 (match-lambda
234 ((or "." "..") #f)
235 (file
236 (not
237 (string-prefix? "test_support."
238 file))))))
239 (call-with-output-file "__init__.py" (const #t))
240 #t)))))))
216c283b
LC
241 (add-before 'strip 'make-libraries-writable
242 (lambda* (#:key outputs #:allow-other-keys)
243 ;; Make .so files writable so they can be stripped.
244 (let ((out (assoc-ref outputs "out")))
245 (for-each (lambda (file)
246 (chmod file #o755))
247 (find-files (string-append out "/lib")
248 "\\.so"))
249 #t)))
02f0c3b2
LC
250 (add-after 'install 'move-tk-inter
251 (lambda* (#:key outputs #:allow-other-keys)
252 ;; When Tkinter support is built move it to a separate output so
253 ;; that the main output doesn't contain a reference to Tcl/Tk.
254 (let ((out (assoc-ref outputs "out"))
255 (tk (assoc-ref outputs "tk")))
256 (when tk
257 (match (find-files out "tkinter.*\\.so")
258 ((tkinter.so)
259 ;; The .so is in OUT/lib/pythonX.Y/lib-dynload, but we
260 ;; want it under TK/lib/pythonX.Y/site-packages.
261 (let* ((len (string-length out))
262 (target (string-append
263 tk "/"
264 (string-drop
265 (dirname (dirname tkinter.so))
266 len)
267 "/site-packages")))
268 (install-file tkinter.so target)
269 (delete-file tkinter.so)))))
270 #t))))))
a01b6da7 271 (inputs
3fdc99da
CR
272 `(("bzip2" ,bzip2)
273 ("gdbm" ,gdbm)
b10ab723 274 ("libffi" ,libffi) ; for ctypes
b88e1b0a 275 ("sqlite" ,sqlite) ; for sqlite extension
a01b6da7 276 ("openssl" ,openssl)
3fdc99da 277 ("readline" ,readline)
afa181ff
LC
278 ("zlib" ,zlib)
279 ("tcl" ,tcl)
280 ("tk" ,tk))) ; for tkinter
b10ab723
CR
281 (native-inputs
282 `(("pkg-config" ,pkg-config)))
9be8d7c8
LC
283 (native-search-paths
284 (list (search-path-specification
285 (variable "PYTHONPATH")
af070955 286 (files '("lib/python2.7/site-packages")))))
f0499100 287 (home-page "https://www.python.org")
afa181ff 288 (synopsis "High-level, dynamically-typed programming language")
a01b6da7
NK
289 (description
290 "Python is a remarkably powerful dynamic programming language that
291is used in a wide variety of application domains. Some of its key
292distinguishing features include: clear, readable syntax; strong
293introspection capabilities; intuitive object orientation; natural
294expression of procedural code; full modularity, supporting hierarchical
295packages; exception-based error handling; and very high level dynamic
296data types.")
3f641af0 297 (license license:psfl)))
acc26ff1 298
45848023
HG
299;; Current 2.x version.
300(define-public python-2 python-2.7)
301
72df6680 302(define-public python-3.5
b24d1cfc 303 (package (inherit python-2)
72df6680 304 (version "3.5.2")
717003e3
LC
305 (source (origin
306 (method url-fetch)
307 (uri (string-append "https://www.python.org/ftp/python/"
308 version "/Python-" version ".tar.xz"))
fc1adab1
AK
309 (patches (search-patches
310 "python-fix-tests.patch"
72df6680 311 "python-3.5-fix-tests.patch"
fc1adab1
AK
312 "python-3-deterministic-build-info.patch"
313 "python-3-search-paths.patch"))
717003e3
LC
314 (patch-flags '("-p0"))
315 (sha256
316 (base32
72df6680 317 "0h6a5fr7ram2s483lh0pnmc4ncijb8llnpfdxdcl5dxr01hza400"))))
1f434457
MW
318 (arguments (substitute-keyword-arguments (package-arguments python-2)
319 ((#:tests? _) #t)))
1aebc0cb
AE
320 (native-search-paths
321 (list (search-path-specification
322 (variable "PYTHONPATH")
0e05d01e
SB
323 (files (list (string-append "lib/python"
324 (version-major+minor version)
325 "/site-packages"))))))))
f26a77ff 326
72df6680
LF
327(define-public python-3.4
328 (package (inherit python-3.5)
329 (version "3.4.5")
330 (source (origin
331 (method url-fetch)
332 (uri (string-append "https://www.python.org/ftp/python/"
333 version "/Python-" version ".tar.xz"))
334 (patches (search-patches
335 "python-fix-tests.patch"
336 "python-3.4-fix-tests.patch"
337 "python-3-deterministic-build-info.patch"
338 "python-3-search-paths.patch"))
339 (patch-flags '("-p0"))
340 (sha256
341 (base32
342 "12l9klp778wklxmckhghniy5hklss8r26995pyd00qbllk4b2r7f"))))))
343
45848023 344;; Current 3.x version.
72df6680 345(define-public python-3 python-3.5)
45848023
HG
346
347;; Current major version.
348(define-public python python-3)
349
95288fcc
LC
350;; Minimal variants of Python, mostly used to break the cycle between Tk and
351;; Python (Tk -> libxcb -> Python.)
352
353(define-public python2-minimal
354 (package (inherit python-2)
355 (name "python-minimal")
02f0c3b2 356 (outputs '("out"))
95288fcc
LC
357 (arguments
358 (substitute-keyword-arguments (package-arguments python-2)
c5a05e31
LC
359 ((#:configure-flags cf)
360 `(append ,cf '("--without-system-ffi")))))
95288fcc
LC
361 (inputs '()))) ;none of the optional dependencies
362
363(define-public python-minimal
898238b9 364 (package (inherit python)
95288fcc 365 (name "python-minimal")
02f0c3b2 366 (outputs '("out"))
95288fcc 367
d0b73960 368 ;; Build fails due to missing ctypes without libffi.
95288fcc
LC
369 ;; OpenSSL is a mandatory dependency of Python 3.x, for urllib;
370 ;; zlib is required by 'zipimport', used by pip.
d0b73960
CAW
371 (inputs `(("libffi" ,libffi)
372 ("openssl" ,openssl)
95288fcc
LC
373 ("zlib" ,zlib)))))
374
64cb064c
LC
375(define* (wrap-python3 python
376 #:optional
377 (name (string-append (package-name python) "-wrapper")))
898238b9 378 (package (inherit python)
95288fcc 379 (name name)
898238b9
AE
380 (source #f)
381 (build-system trivial-build-system)
02f0c3b2 382 (outputs '("out"))
3969ca54 383 (inputs `(("bash" ,bash)))
3c0f2329 384 (propagated-inputs `(("python" ,python)))
898238b9
AE
385 (arguments
386 `(#:modules ((guix build utils))
387 #:builder
388 (begin
389 (use-modules (guix build utils))
390 (let ((bin (string-append (assoc-ref %outputs "out") "/bin"))
391 (python (string-append (assoc-ref %build-inputs "python") "/bin/")))
392 (mkdir-p bin)
393 (for-each
394 (lambda (old new)
395 (symlink (string-append python old)
396 (string-append bin "/" new)))
3969ca54
SB
397 `("python3" ,"pydoc3" ,"idle3" ,"pip3")
398 `("python" ,"pydoc" ,"idle" ,"pip"))
399 ;; python-config outputs search paths based upon its location,
400 ;; use a bash wrapper to avoid changing its outputs.
401 (let ((bash (string-append (assoc-ref %build-inputs "bash")
402 "/bin/bash"))
403 (old (string-append python "python3-config"))
404 (new (string-append bin "/python-config")))
405 (with-output-to-file new
406 (lambda ()
407 (format #t "#!~a~%" bash)
408 (format #t "exec \"~a\" \"$@\"~%" old)
409 (chmod new #o755)
410 #t)))))))
0d56e3e1
LC
411 (synopsis "Wrapper for the Python 3 commands")
412 (description
413 "This package provides wrappers for the commands of Python@tie{}3.x such
414that they can be invoked under their usual name---e.g., @command{python}
415instead of @command{python3}.")))
416
95288fcc
LC
417(define-public python-wrapper (wrap-python3 python))
418(define-public python-minimal-wrapper (wrap-python3 python-minimal))
898238b9 419
aaf625b8
RW
420(define-public python-psutil
421 (package
422 (name "python-psutil")
88535a44 423 (version "4.3.0")
aaf625b8
RW
424 (source
425 (origin
426 (method url-fetch)
f56777be 427 (uri (pypi-uri "psutil" version))
aaf625b8
RW
428 (sha256
429 (base32
88535a44 430 "1w4r09fvn6kd80m5mx4ws1wz100brkaq6hzzpwrns8cgjzjpl6c6"))))
aaf625b8
RW
431 (build-system python-build-system)
432 (native-inputs
433 `(("python-setuptools" ,python-setuptools)))
88535a44 434 (home-page "https://www.github.com/giampaolo/psutil")
aaf625b8
RW
435 (synopsis "Library for retrieving information on running processes")
436 (description
437 "psutil (Python system and process utilities) is a library for retrieving
438information on running processes and system utilization (CPU, memory, disks,
439network) in Python. It is useful mainly for system monitoring, profiling and
440limiting process resources and management of running processes. It implements
441many functionalities offered by command line tools such as: ps, top, lsof,
442netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime,
443pidof, tty, taskset, pmap.")
3f641af0 444 (license license:bsd-3)))
aaf625b8
RW
445
446(define-public python2-psutil
447 (package-with-python2 python-psutil))
898238b9 448
f9da1d8a
ED
449(define-public python-passlib
450 (package
451 (name "python-passlib")
690e8c66 452 (version "1.6.5")
f9da1d8a
ED
453 (source
454 (origin
455 (method url-fetch)
690e8c66 456 (uri (pypi-uri "passlib" version))
f9da1d8a
ED
457 (sha256
458 (base32
690e8c66 459 "1z27wdxs5rj5xhhqfzvzn3yg682irkxw6dcs5jj7mcf97psk8gd8"))))
f9da1d8a
ED
460 (build-system python-build-system)
461 (native-inputs
462 `(("python-nose" ,python-nose)
463 ("python-setuptools" ,python-setuptools)))
464 (inputs
465 `(("python-py-bcrypt" ,python-py-bcrypt)))
466 (arguments
467 `(#:phases
468 (alist-cons-before
469 'check 'set-PYTHON_EGG_CACHE
470 ;; some tests require access to "$HOME/.cython"
471 (lambda* _ (setenv "PYTHON_EGG_CACHE" "/tmp"))
472 %standard-phases)))
473 (home-page "https://bitbucket.org/ecollins/passlib")
474 (synopsis
475 "Comprehensive password hashing framework")
476 (description
477 "Passlib is a password hashing library for Python 2 & 3, which provides
478cross-platform implementations of over 30 password hashing algorithms, as well
479as a framework for managing existing password hashes. It's designed to be
480useful for a wide range of tasks, from verifying a hash found in /etc/shadow,
481to providing full-strength password hashing for multi-user application.")
3f641af0 482 (license license:bsd-3)))
f9da1d8a
ED
483
484(define-public python2-passlib
485 (package-with-python2 python-passlib))
486
feb0d9c3
ED
487(define-public python-py-bcrypt
488 (package
489 (name "python-py-bcrypt")
490 (version "0.4")
491 (source
492 (origin
493 (method url-fetch)
494 (uri (string-append
495 "https://pypi.python.org/packages/source/p/py-bcrypt/py-bcrypt-"
496 version
497 ".tar.gz"))
498 (sha256
499 (base32
500 "0y6smdggwi5s72v6p1nn53dg6w05hna3d264cq6kas0lap73p8az"))))
501 (build-system python-build-system)
502 (native-inputs
503 `(("python-setuptools" ,python-setuptools)))
504 (home-page "https://code.google.com/p/py-bcrypt")
505 (synopsis
506 "Bcrypt password hashing and key derivation")
507 (description
508 "A python wrapper of OpenBSD's Blowfish password hashing code. This
509system hashes passwords using a version of Bruce Schneier's Blowfish block
510cipher with modifications designed to raise the cost of off-line password
511cracking and frustrate fast hardware implementation. The computation cost of
512the algorithm is parametised, so it can be increased as computers get faster.
513The intent is to make a compromise of a password database less likely to
514result in an attacker gaining knowledge of the plaintext passwords (e.g. using
515John the Ripper).")
516 ;; "sha2.c" is under BSD-3;
517 ;; "blowfish.c" and "bcrypt.c" are under BSD-4;
518 ;; the rest is under ISC.
3f641af0 519 (license (list license:isc license:bsd-3 license:bsd-4))))
feb0d9c3
ED
520
521(define-public python2-py-bcrypt
522 (package-with-python2 python-py-bcrypt))
523
524
429fdea1
ED
525(define-public python-paramiko
526 (package
527 (name "python-paramiko")
81b9bbbd 528 (version "1.16.0")
429fdea1
ED
529 (source
530 (origin
531 (method url-fetch)
81b9bbbd 532 (uri (pypi-uri "paramiko" version))
429fdea1
ED
533 (sha256
534 (base32
81b9bbbd 535 "14k8z7ndc3zk5xivnm4d8lncchx475ll5izpf8vmfbq7rp9yp5rj"))))
429fdea1
ED
536 (build-system python-build-system)
537 (native-inputs
538 `(("python-setuptools" ,python-setuptools)))
a3fc12da
CR
539 (propagated-inputs
540 `(("python-pycrypto" ,python-pycrypto)))
429fdea1 541 (inputs
a3fc12da 542 `(("python-ecdsa" ,python-ecdsa)))
429fdea1
ED
543 (home-page "http://www.paramiko.org/")
544 (synopsis "SSHv2 protocol library")
545 (description "Paramiko is a python implementation of the SSHv2 protocol,
546providing both client and server functionality. While it leverages a Python C
547extension for low level cryptography (PyCrypto), Paramiko itself is a pure
548Python interface around SSH networking concepts.")
3f641af0 549 (license license:lgpl2.1+)))
429fdea1
ED
550
551(define-public python2-paramiko
552 (package-with-python2 python-paramiko))
553
554
de73dbf6
ED
555(define-public python-httplib2
556 (package
557 (name "python-httplib2")
286f1bac 558 (version "0.9.2")
de73dbf6
ED
559 (source
560 (origin
561 (method url-fetch)
286f1bac 562 (uri (pypi-uri "httplib2" version))
de73dbf6
ED
563 (sha256
564 (base32
286f1bac 565 "126rsryvw9vhbf3qmsfw9lf4l4xm2srmgs439lgma4cpag4s3ay3"))))
de73dbf6
ED
566 (build-system python-build-system)
567 (native-inputs
568 `(("python-setuptools" ,python-setuptools)))
286f1bac 569 (home-page "https://github.com/jcgregorio/httplib2")
de73dbf6
ED
570 (synopsis "Comprehensive HTTP client library")
571 (description
572 "A comprehensive HTTP client library supporting many features left out of
573other HTTP libraries.")
574 (license license:expat)))
575
576(define-public python2-httplib2
577 (package-with-python2 python-httplib2))
578
67039875
ED
579(define-public python-ecdsa
580 (package
581 (name "python-ecdsa")
582 (version "0.13")
583 (source
584 (origin
585 (method url-fetch)
586 (uri (string-append
587 "https://pypi.python.org/packages/source/e/ecdsa/ecdsa-"
588 version
589 ".tar.gz"))
590 (sha256
591 (base32
592 "1yj31j0asmrx4an9xvsaj2icdmzy6pw0glfpqrrkrphwdpi1xkv4"))))
593 (build-system python-build-system)
594 (native-inputs
595 `(("python-setuptools" ,python-setuptools)))
596 (inputs
597 `(("openssl" ,openssl)))
598 (home-page
599 "http://github.com/warner/python-ecdsa")
600 (synopsis
601 "ECDSA cryptographic signature library (pure python)")
602 (description
603 "This is an easy-to-use implementation of ECDSA cryptography (Elliptic
604Curve Digital Signature Algorithm), implemented purely in Python. With this
605library, you can quickly create keypairs (signing key and verifying key), sign
606messages, and verify the signatures. The keys and signatures are very short,
607making them easy to handle and incorporate into other protocols.")
608 (license license:expat)))
609
610(define-public python2-ecdsa
611 (package-with-python2 python-ecdsa))
612
52323f32
ED
613(define-public python-ccm
614 (package
615 (name "python-ccm")
db5567f7 616 (version "2.1.6")
52323f32
ED
617 (source
618 (origin
619 (method url-fetch)
db5567f7 620 (uri (pypi-uri "ccm" version))
52323f32
ED
621 (sha256
622 (base32
db5567f7 623 "177dfxsmk3k4cih6fh6v8d91bh4nqx7ns6pc07w7m7i3cvdx3c8n"))))
52323f32
ED
624 (build-system python-build-system)
625 (native-inputs
626 `(("python-setuptools" ,python-setuptools)))
627 (inputs
628 `(("python-pyyaml" ,python-pyyaml)
629 ("python-six" ,python-six)))
630 (home-page "https://github.com/pcmanus/ccm")
631 (synopsis "Cassandra Cluster Manager")
632 (description "A script/library to create, launch and remove an Apache
633Cassandra cluster on localhost.")
3f641af0 634 (license license:asl2.0)))
52323f32
ED
635
636(define-public python2-ccm
637 (package-with-python2 python-ccm))
638
89114f39 639(define-public python-pytz
acc26ff1 640 (package
89114f39 641 (name "python-pytz")
61c9babb 642 (version "2016.3")
acc26ff1
CR
643 (source
644 (origin
645 (method url-fetch)
61c9babb 646 (uri (pypi-uri "pytz" version ".tar.bz2"))
acc26ff1
CR
647 (sha256
648 (base32
61c9babb 649 "1mjmrkk4vc5xzppw7fm0pli1nnbj57cvqv7jjv5whcmccyhxz4y1"))))
acc26ff1 650 (build-system python-build-system)
8498b8cf 651 (arguments `(#:tests? #f)) ; no test target
b01bbbcf 652 (home-page "http://pythonhosted.org/pytz")
9e771e3b 653 (synopsis "Python timezone library")
acc26ff1
CR
654 (description
655 "This library allows accurate and cross platform timezone calculations
656using Python 2.4 or higher and provides access to the Olson timezone database.")
b01bbbcf 657 (license license:expat)))
5ace6e2f 658
89114f39 659(define-public python2-pytz
11bb85a1 660 (package-with-python2 python-pytz))
89114f39 661
fc50e9c6 662
89114f39 663(define-public python-babel
5ace6e2f 664 (package
89114f39 665 (name "python-babel")
3f37db6b 666 (version "2.3.2")
5ace6e2f
CR
667 (source
668 (origin
669 (method url-fetch)
b850a6d8 670 (uri (pypi-uri "Babel" version))
5ace6e2f
CR
671 (sha256
672 (base32
3f37db6b 673 "0k43pi0p1dwpds2w0km3fw92wixzxv2vw7p09capxmjz5cfh23lw"))))
5ace6e2f
CR
674 (build-system python-build-system)
675 (inputs
e1804763
AE
676 `(("python-pytz" ,python-pytz)
677 ("python-setuptools" ,python-setuptools)))
8498b8cf 678 (arguments `(#:tests? #f)) ; no test target
e1804763 679 (home-page "http://babel.pocoo.org/")
5ace6e2f
CR
680 (synopsis
681 "Tools for internationalizing Python applications")
682 (description
683 "Babel is composed of two major parts:
684- tools to build and work with gettext message catalogs
685- a Python interface to the CLDR (Common Locale Data Repository), providing
686access to various locale display names, localized number and date formatting,
687etc. ")
3f641af0 688 (license license:bsd-3)))
89114f39
AE
689
690(define-public python2-babel
11bb85a1 691 (package-with-python2 python-babel))
73adf220 692
ed377cc6
RW
693(define-public python2-backport-ssl-match-hostname
694 (package
695 (name "python2-backport-ssl-match-hostname")
f2d06d46 696 (version "3.5.0.1")
ed377cc6
RW
697 (source
698 (origin
699 (method url-fetch)
700 (uri (string-append
701 "https://pypi.python.org/packages/source/b/"
702 "backports.ssl_match_hostname/backports.ssl_match_hostname-"
703 version ".tar.gz"))
704 (sha256
705 (base32
f2d06d46 706 "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh"))))
ed377cc6 707 (build-system python-build-system)
f2d06d46
EF
708 (arguments
709 `(#:python ,python-2
710 #:tests? #f)) ; no test target
ed377cc6
RW
711 (inputs
712 `(("python2-setuptools" ,python2-setuptools)))
f2d06d46
EF
713 (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname")
714 (synopsis "Backport of ssl.match_hostname() function from Python 3.5")
ed377cc6
RW
715 (description
716 "This backport brings the ssl.match_hostname() function to users of
717earlier versions of Python. The function checks the hostname in the
718certificate returned by the server to which a connection has been established,
719and verifies that it matches the intended target hostname.")
3f641af0 720 (license license:psfl)))
ed377cc6 721
ef5cbf9b
RW
722(define-public python-h5py
723 (package
724 (name "python-h5py")
fe147c41 725 (version "2.6.0")
ef5cbf9b
RW
726 (source
727 (origin
728 (method url-fetch)
fe147c41 729 (uri (pypi-uri "h5py" version))
ef5cbf9b
RW
730 (sha256
731 (base32
fe147c41 732 "0df46dg7i7xfking9lp221bfm8dbl974yvlrbi1w7r6m61ac7bxj"))))
ef5cbf9b 733 (build-system python-build-system)
797e1401
RW
734 (arguments
735 `(#:tests? #f ; no test target
736 #:phases
737 (modify-phases %standard-phases
738 (add-after 'unpack 'fix-hdf5-paths
739 (lambda* (#:key inputs #:allow-other-keys)
740 (let ((prefix (assoc-ref inputs "hdf5")))
741 (substitute* "setup_build.py"
742 (("\\['/opt/local/lib', '/usr/local/lib'\\]")
743 (string-append "['" prefix "/lib" "']"))
744 (("'/opt/local/include', '/usr/local/include'")
745 (string-append "'" prefix "/include" "'")))
746 (substitute* "setup_configure.py"
747 (("\\['/usr/local/lib', '/opt/local/lib'\\]")
748 (string-append "['" prefix "/lib" "']")))
749 #t))))))
3c4010b1
RW
750 (propagated-inputs
751 `(("python-numpy" ,python-numpy)))
ef5cbf9b 752 (inputs
fe147c41
EF
753 `(("hdf5" ,hdf5)
754 ("python-six" ,python-six)))
ef5cbf9b 755 (native-inputs
fe147c41
EF
756 `(("python-cython" ,python-cython)
757 ("python-pkgconfig" ,python-pkgconfig)))
ef5cbf9b
RW
758 (home-page "http://www.h5py.org/")
759 (synopsis "Read and write HDF5 files from Python")
760 (description
761 "The h5py package provides both a high- and low-level interface to the
762HDF5 library from Python. The low-level interface is intended to be a
763complete wrapping of the HDF5 API, while the high-level component supports
764access to HDF5 files, datasets and groups using established Python and NumPy
765concepts.")
3f641af0 766 (license license:bsd-3)
fe147c41 767 (properties `((python2-variant . ,(delay python2-h5py))))))
ef5cbf9b
RW
768
769(define-public python2-h5py
fe147c41 770 (package-with-python2 (strip-python2-variant python-h5py)))
ef5cbf9b 771
c1448c69
EB
772(define-public python-lockfile
773 (package
774 (name "python-lockfile")
692add53 775 (version "0.12.2")
c1448c69
EB
776 (source
777 (origin
778 (method url-fetch)
779 (uri (string-append "https://pypi.python.org/packages/source/l/lockfile/"
780 "lockfile-" version ".tar.gz"))
781 (sha256
782 (base32
692add53 783 "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba"))))
c1448c69
EB
784 (build-system python-build-system)
785 (arguments '(#:test-target "check"))
692add53
BW
786 (native-inputs
787 `(("python-pbr" ,python-pbr)))
c1448c69
EB
788 (home-page "http://code.google.com/p/pylockfile/")
789 (synopsis "Platform-independent file locking module")
790 (description
791 "The lockfile package exports a LockFile class which provides a simple
792API for locking files.")
1804527a
BW
793 (license license:expat)
794 (properties `((python2-variant . ,(delay python2-lockfile))))))
c1448c69
EB
795
796(define-public python2-lockfile
1804527a
BW
797 (let ((base (package-with-python2 (strip-python2-variant python-lockfile))))
798 (package
692add53
BW
799 (inherit base)
800 (native-inputs `(("python2-setuptools" ,python2-setuptools)
801 ,@(package-native-inputs base))))))
c1448c69 802
5a1a4bf6
EB
803(define-public python-mock
804 (package
805 (name "python-mock")
806 (version "1.0.1")
807 (source
808 (origin
809 (method url-fetch)
810 (uri (string-append "https://pypi.python.org/packages/source/m/mock/"
811 "mock-" version ".tar.gz"))
812 (sha256
813 (base32
814 "0kzlsbki6q0awf89rc287f3aj8x431lrajf160a70z0ikhnxsfdq"))))
815 (build-system python-build-system)
816 (arguments '(#:test-target "check"))
07af3e5e 817 (home-page "http://code.google.com/p/mock/")
9e771e3b 818 (synopsis "Python mocking and patching library for testing")
5a1a4bf6
EB
819 (description
820 "Mock is a library for testing in Python. It allows you to replace parts
821of your system under test with mock objects and make assertions about how they
822have been used.")
bd3fa666 823 (license license:expat)))
5a1a4bf6
EB
824
825(define-public python2-mock
826 (package-with-python2 python-mock))
827
fc50e9c6 828
73adf220
AE
829(define-public python-setuptools
830 (package
831 (name "python-setuptools")
62a9a23b 832 (version "18.3.1")
73adf220
AE
833 (source
834 (origin
835 (method url-fetch)
836 (uri (string-append "https://pypi.python.org/packages/source/s/setuptools/setuptools-"
837 version ".tar.gz"))
838 (sha256
839 (base32
62a9a23b 840 "0kc7rbav00ks6iaw14p38y81q12fx0lpkhgf5m97xc04f5r318ig"))))
73adf220 841 (build-system python-build-system)
d3d656c5
AE
842 ;; FIXME: Tests require pytest, which itself relies on setuptools.
843 ;; One could bootstrap with an internal untested setuptools.
73adf220 844 (arguments
824af8ca 845 `(#:tests? #f))
73adf220
AE
846 (home-page "https://pypi.python.org/pypi/setuptools")
847 (synopsis
848 "Library designed to facilitate packaging Python projects")
849 (description
850 "Setuptools is a fully-featured, stable library designed to facilitate
851packaging Python projects, where packaging includes:
852Python package and module definitions,
853distribution package metadata,
854test hooks,
855project installation,
856platform-specific details,
857Python 3 support.")
3f641af0 858 (license license:psfl)))
73adf220
AE
859
860(define-public python2-setuptools
861 (package-with-python2 python-setuptools))
fc50e9c6
AE
862
863
cafc3f5a
EB
864(define-public python-pycrypto
865 (package
866 (name "python-pycrypto")
867 (version "2.6.1")
868 (source
869 (origin
870 (method url-fetch)
871 (uri (string-append "https://pypi.python.org/packages/source/p/"
872 "pycrypto/pycrypto-" version ".tar.gz"))
873 (sha256
874 (base32
875 "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj"))))
876 (build-system python-build-system)
877 (native-inputs
878 `(("python-setuptools" ,python-setuptools)))
879 (inputs
880 `(("python" ,python)
881 ("gmp" ,gmp)))
882 (arguments
883 `(#:phases
884 (alist-cons-before
885 'build 'set-build-env
886 ;; pycrypto runs an autoconf configure script behind the scenes
887 (lambda _
888 (setenv "CONFIG_SHELL" (which "bash")))
889 %standard-phases)))
890 (home-page "http://www.pycrypto.org/")
891 (synopsis "Cryptographic modules for Python")
892 (description
893 "Pycrypto is a collection of both secure hash functions (such as SHA256
894and RIPEMD160), and various encryption algorithms (AES, DES, RSA, ElGamal,
35b9e423 895etc.). The package is structured to make adding new modules easy.")
3f641af0 896 (license license:public-domain)))
cafc3f5a 897
345f0611 898(define-public python2-pycrypto
1c0059da
EF
899 (let ((pycrypto (package-with-python2 python-pycrypto)))
900 (package (inherit pycrypto)
901 (inputs
902 `(("python" ,python-2)
903 ,@(alist-delete
904 "python"
905 (package-inputs pycrypto)))))))
345f0611 906
cafc3f5a
EB
907(define-public python-keyring
908 (package
909 (name "python-keyring")
13f3ff35 910 (version "8.7")
cafc3f5a
EB
911 (source
912 (origin
913 (method url-fetch)
664e6c3a 914 (uri (pypi-uri "keyring" version))
cafc3f5a
EB
915 (sha256
916 (base32
13f3ff35 917 "0482rmi2x6p78wl2kz8qzyq21xz1sbbfwnv5x7dggar4vkwxhzfx"))))
cafc3f5a
EB
918 (build-system python-build-system)
919 (native-inputs
13f3ff35 920 `(("python-setuptools-scm" ,python-setuptools-scm)))
cafc3f5a
EB
921 (inputs
922 `(("python-pycrypto" ,python-pycrypto)))
923 (arguments
664e6c3a 924 `(#:tests? #f)) ;TODO: tests require pytest
cafc3f5a
EB
925 (home-page "http://bitbucket.org/kang/python-keyring-lib")
926 (synopsis "Store and access your passwords safely")
927 (description
928 "The Python keyring lib provides a easy way to access the system keyring
35b9e423 929service from python. It can be used in any application that needs safe
cafc3f5a
EB
930password storage.")
931 ;; "MIT" and PSF dual license
3f641af0 932 (license license:x11)
13f3ff35 933 (properties `((python2-variant . ,(delay python2-keyring))))))
cafc3f5a 934
d7af1069 935(define-public python2-keyring
13f3ff35
EF
936 (let ((base (package-with-python2 (strip-python2-variant python-keyring))))
937 (package
938 (inherit base)
939 (native-inputs `(("python2-setuptools" ,python2-setuptools)
940 ,@(package-native-inputs base))))))
d7af1069 941
a480bc41
EB
942(define-public python-six
943 (package
944 (name "python-six")
b6ab89ef 945 (version "1.10.0")
a480bc41
EB
946 (source
947 (origin
948 (method url-fetch)
b6ab89ef 949 (uri (pypi-uri "six" version))
a480bc41
EB
950 (sha256
951 (base32
b6ab89ef 952 "0snmb8xffb3vsma0z67i0h0w2g2dy0p3gsgh9gi4i0kgc5l8spqh"))))
a480bc41
EB
953 (build-system python-build-system)
954 (inputs
955 `(("python-setuptools" ,python-setuptools)))
956 (home-page "http://pypi.python.org/pypi/six/")
957 (synopsis "Python 2 and 3 compatibility utilities")
958 (description
35b9e423 959 "Six is a Python 2 and 3 compatibility library. It provides utility
a480bc41
EB
960functions for smoothing over the differences between the Python versions with
961the goal of writing Python code that is compatible on both Python versions.
35b9e423 962Six supports every Python version since 2.5. It is contained in only one
a480bc41 963Python file, so it can be easily copied into your project.")
3f641af0 964 (license license:x11)))
a480bc41 965
0c20025c
AE
966(define-public python2-six
967 (package-with-python2 python-six))
968
cafc3f5a
EB
969(define-public python-dateutil-2
970 (package
971 (name "python-dateutil")
394b8060 972 (version "2.5.2")
cafc3f5a
EB
973 (source
974 (origin
975 (method url-fetch)
394b8060 976 (uri (pypi-uri "python-dateutil" version))
cafc3f5a
EB
977 (sha256
978 (base32
394b8060 979 "0jrfpcgvgya6hs45dhrd9yiqgdgz9qp9aa07zsw8gqgn8zphff86"))))
cafc3f5a
EB
980 (build-system python-build-system)
981 (inputs
394b8060 982 `(("python-six" ,python-six)))
cafc3f5a
EB
983 (home-page "http://labix.org/python-dateutil")
984 (synopsis "Extensions to the standard datetime module")
985 (description
986 "The dateutil module provides powerful extensions to the standard
987datetime module, available in Python 2.3+.")
3f641af0 988 (license license:bsd-3)
394b8060 989 (properties `((python2-variant . ,(delay python2-dateutil-2))))))
cafc3f5a
EB
990
991(define-public python2-dateutil-2
394b8060
EF
992 (let ((base (package-with-python2 (strip-python2-variant python-dateutil-2))))
993 (package
994 (inherit base)
995 (inputs `(("python2-setuptools" ,python2-setuptools)
996 ,@(package-inputs base))))))
cafc3f5a 997
fc50e9c6
AE
998(define-public python-dateutil
999 (package
1000 (name "python-dateutil")
1001 (version "1.5") ; last version for python < 3
1002 (source
1003 (origin
1004 (method url-fetch)
cafc3f5a
EB
1005 (uri (string-append "http://labix.org/download/python-dateutil/"
1006 "python-dateutil-" version ".tar.gz"))
fc50e9c6
AE
1007 (sha256
1008 (base32
1009 "0fqfglhy5khbvsipr3x7m6bcaqljh8xl5cw33vbfxy7qhmywm2n0"))))
1010 (build-system python-build-system)
1011 (inputs
1012 `(("python-setuptools" ,python-setuptools)))
1013 (home-page "http://labix.org/python-dateutil")
cafc3f5a 1014 (synopsis "Extensions to the standard datetime module")
fc50e9c6
AE
1015 (description
1016 "The dateutil module provides powerful extensions to the standard
1017datetime module, available in Python 2.3+.")
3f641af0 1018 (license license:psfl)))
fc50e9c6
AE
1019
1020(define-public python2-dateutil
1021 (package-with-python2 python-dateutil))
1d08c01f 1022
cafc3f5a
EB
1023(define-public python-parsedatetime
1024 (package
1025 (name "python-parsedatetime")
eebf6f01 1026 (version "2.1")
cafc3f5a
EB
1027 (source
1028 (origin
1029 (method url-fetch)
eebf6f01 1030 (uri (pypi-uri "parsedatetime" version))
cafc3f5a
EB
1031 (sha256
1032 (base32
eebf6f01 1033 "0bdgyw6y3v7bcxlx0p50s8drxsh5bb5cy2afccqr3j90amvpii8p"))))
cafc3f5a
EB
1034 (build-system python-build-system)
1035 (native-inputs
eebf6f01
EF
1036 `(("python-nose" ,python-nose)
1037 ("python-pyicu" ,python-pyicu)))
cafc3f5a
EB
1038 (home-page "http://github.com/bear/parsedatetime/")
1039 (synopsis
1040 "Parse human-readable date/time text")
1041 (description
e881752c 1042 "Parse human-readable date/time text.")
3f641af0 1043 (license license:asl2.0)
eebf6f01 1044 (properties `((python2-variant . ,(delay python2-parsedatetime))))))
cafc3f5a 1045
38b8f9b2 1046(define-public python2-parsedatetime
eebf6f01
EF
1047 (let ((base (package-with-python2 (strip-python2-variant python-parsedatetime))))
1048 (package
1049 (inherit base)
1050 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1051 ,@(package-native-inputs base))))))
38b8f9b2 1052
d072efcb
RW
1053(define-public python-pandas
1054 (package
1055 (name "python-pandas")
7d0c3c8d 1056 (version "0.18.1")
d072efcb
RW
1057 (source
1058 (origin
1b96f069 1059 (method url-fetch)
7d0c3c8d
EF
1060 (uri (string-append
1061 "https://pypi.python.org/packages/11/09/"
1062 "e66eb844daba8680ddff26335d5b4fead77f60f957678243549a8dd4830d/"
1063 "pandas-" version ".tar.gz"))
1b96f069 1064 (sha256
7d0c3c8d 1065 (base32 "1ckpxrvvjj6zxmn68icd9hib8qcpx9b35f6izxnr25br5ilq7r6j"))))
d072efcb 1066 (build-system python-build-system)
d072efcb 1067 (propagated-inputs
42603726
EF
1068 `(("python-numpy" ,python-numpy)))
1069 (inputs
1070 `(("python-pytz" ,python-pytz)
d072efcb
RW
1071 ("python-dateutil" ,python-dateutil-2)))
1072 (native-inputs
7d0c3c8d 1073 `(("python-nose" ,python-nose)))
d072efcb
RW
1074 (home-page "http://pandas.pydata.org")
1075 (synopsis "Data structures for data analysis, time series, and statistics")
1076 (description
1077 "Pandas is a Python package providing fast, flexible, and expressive data
1078structures designed to make working with structured (tabular,
1079multidimensional, potentially heterogeneous) and time series data both easy
1080and intuitive. It aims to be the fundamental high-level building block for
1081doing practical, real world data analysis in Python.")
3f641af0 1082 (license license:bsd-3)
7d0c3c8d 1083 (properties `((python2-variant . ,(delay python2-pandas))))))
d072efcb
RW
1084
1085(define-public python2-pandas
7d0c3c8d
EF
1086 (let ((base (package-with-python2 (strip-python2-variant python-pandas))))
1087 (package
1088 (inherit base)
1089 (native-inputs `(("python2-setuptools" ,python2-setuptools)
dbd40ac1 1090 ,@(package-native-inputs base))))))
d072efcb 1091
cafc3f5a
EB
1092(define-public python-tzlocal
1093 (package
1094 (name "python-tzlocal")
ed80839b 1095 (version "1.2.2")
cafc3f5a
EB
1096 (source
1097 (origin
1098 (method url-fetch)
226d3331 1099 (uri (pypi-uri "tzlocal" version))
cafc3f5a
EB
1100 (sha256
1101 (base32
ed80839b 1102 "0paj7vlsb0np8b5sp4bv64wxv7qk2piyp7xg29pkhdjwsbls9fnb"))))
cafc3f5a 1103 (build-system python-build-system)
ed80839b 1104 (inputs `(("python-pytz" ,python-pytz)))
cafc3f5a
EB
1105 (home-page "https://github.com/regebro/tzlocal")
1106 (synopsis
35b9e423 1107 "Local timezone information for Python")
cafc3f5a
EB
1108 (description
1109 "Tzlocal returns a tzinfo object with the local timezone information.
1110This module attempts to fix a glaring hole in pytz, that there is no way to
1111get the local timezone information, unless you know the zoneinfo name, and
1112under several distributions that's hard or impossible to figure out.")
3f641af0 1113 (license license:cc0)))
cafc3f5a 1114
1d08c01f
AE
1115(define-public python2-pysqlite
1116 (package
1117 (name "python2-pysqlite")
fe476868 1118 (version "2.8.1")
1d08c01f
AE
1119 (source
1120 (origin
1121 (method url-fetch)
fe476868 1122 (uri (pypi-uri "pysqlite" version))
1d08c01f
AE
1123 (sha256
1124 (base32
fe476868 1125 "0rm0zqyb363y6wljhfmbxs16jjv7p8nk1d8zgq9sdwj6js7y3jkm"))))
1d08c01f
AE
1126 (build-system python-build-system)
1127 (inputs
1128 `(("sqlite" ,sqlite)))
1129 (arguments
1130 `(#:python ,python-2 ; incompatible with Python 3
1131 #:tests? #f)) ; no test target
fe476868 1132 (home-page "http://github.com/ghaering/pysqlite")
7a03af70 1133 (synopsis "SQLite bindings for Python")
1d08c01f
AE
1134 (description
1135 "Pysqlite provides SQLite bindings for Python that comply to the
1136Database API 2.0T.")
ed0cdf83 1137 (license license:zlib)))
1d08c01f 1138
2875caf5
AE
1139
1140(define-public python2-mechanize
1141 (package
1142 (name "python2-mechanize")
1143 (version "0.2.5")
1144 (source
1145 (origin
1146 (method url-fetch)
1147 (uri (string-append "https://pypi.python.org/packages/source/m/mechanize/mechanize-"
1148 version ".tar.gz"))
1149 (sha256
1150 (base32
1151 "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf"))))
1152 (build-system python-build-system)
1153 (inputs
1154 `(("python2-setuptools" ,python2-setuptools)))
1155 (arguments
1156 `(#:python ,python-2 ; apparently incompatible with Python 3
1157 #:tests? #f))
1158 ;; test fails with message
1159 ;; AttributeError: 'module' object has no attribute 'test_pullparser'
1160 ;; (python-3.3.2) or
1161 ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet'
1162 ;; (python-2.7.5).
1163 ;; The source code is from March 2011 and probably not up-to-date
1164 ;; with respect to python unit tests.
1165 (home-page "http://wwwsearch.sourceforge.net/mechanize/")
1166 (synopsis
1167 "Stateful programmatic web browsing in Python")
1168 (description
1169 "Mechanize implements stateful programmatic web browsing in Python,
1170after Andy Lester’s Perl module WWW::Mechanize.")
3f641af0
DC
1171 (license (license:non-copyleft
1172 "file://COPYING"
1173 "See COPYING in the distribution."))))
2875caf5 1174
0352532e
AE
1175
1176(define-public python-simplejson
1177 (package
1178 (name "python-simplejson")
988d1bad 1179 (version "3.8.2")
0352532e
AE
1180 (source
1181 (origin
1182 (method url-fetch)
988d1bad 1183 (uri (pypi-uri "simplejson" version))
0352532e
AE
1184 (sha256
1185 (base32
988d1bad 1186 "0zylrnax8b6r0ndgni4w9c599fi6wm9vx5g6k3ddqfj3932kk16m"))))
0352532e
AE
1187 (build-system python-build-system)
1188 (home-page "http://simplejson.readthedocs.org/en/latest/")
1189 (synopsis
1190 "Json library for Python")
1191 (description
e881752c
AK
1192 "JSON (JavaScript Object Notation) is a subset of JavaScript
1193syntax (ECMA-262 3rd edition) used as a lightweight data interchange
1194format.
0352532e
AE
1195
1196Simplejson exposes an API familiar to users of the standard library marshal
1197and pickle modules. It is the externally maintained version of the json
1198library contained in Python 2.6, but maintains compatibility with Python 2.5
1199and (currently) has significant performance advantages, even without using
1200the optional C extension for speedups. Simplejson is also supported on
1201Python 3.3+.")
3f641af0 1202 (license license:x11)))
0352532e
AE
1203
1204(define-public python2-simplejson
1205 (package-with-python2 python-simplejson))
421a80a2
AE
1206
1207
ed07b08d 1208(define-public python-pyicu
421a80a2 1209 (package
ed07b08d 1210 (name "python-pyicu")
d3b29319 1211 (version "1.9.2")
421a80a2
AE
1212 (source
1213 (origin
1214 (method url-fetch)
1215 (uri (string-append "https://pypi.python.org/packages/source/P/PyICU/PyICU-"
1216 version ".tar.gz"))
1217 (sha256
1218 (base32
d3b29319 1219 "1diba0g8md614fvm9yf50paiwdkhj6rd7xwf1rg9mc0pxc0hhn4v"))))
421a80a2
AE
1220 (build-system python-build-system)
1221 (inputs
1222 `(("icu4c" ,icu4c)))
421a80a2 1223 (home-page "http://pyicu.osafoundation.org/")
9e771e3b 1224 (synopsis "Python extension wrapping the ICU C++ API")
421a80a2
AE
1225 (description
1226 "PyICU is a python extension wrapping the ICU C++ API.")
3f641af0 1227 (license license:x11)
ed07b08d
LF
1228 (properties `((python2-variant . ,(delay python2-pyicu))))))
1229
1230(define-public python2-pyicu
1231 (package
1232 (inherit (package-with-python2
1233 (strip-python2-variant python-pyicu)))
1234 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
cc20a22a
LC
1235
1236(define-public python2-dogtail
1237 ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and
1238 ;; spaces in indentation" with Python 3.
1239 (package
1240 (name "python2-dogtail")
1241 (version "0.8.2")
1242 (source (origin
1243 (method url-fetch)
1244 (uri (string-append
1245 "https://fedorahosted.org/released/dogtail/dogtail-"
1246 version ".tar.gz"))
1247 (sha256
1248 (base32
1249 "1yc4cg7ip87z15gyd4wy2vzbywrjc52a3m8r8gqy2b50d65llcg1"))))
1250 (build-system python-build-system)
1251 (arguments `(#:python ,python-2
1252 #:tests? #f)) ; invalid command "test"
1253 (home-page "https://fedorahosted.org/dogtail/")
1254 (synopsis "GUI test tool and automation framework written in ​Python")
1255 (description
35b9e423 1256 "Dogtail is a GUI test tool and automation framework written in Python.
cc20a22a
LC
1257It uses Accessibility (a11y) technologies to communicate with desktop
1258applications. dogtail scripts are written in Python and executed like any
1259other Python program.")
3f641af0 1260 (license license:gpl2+)))
515e6878 1261
011b18c3
LC
1262(define-public python2-empy
1263 (package
1264 (name "python2-empy")
1265 (version "3.3")
1266 (source (origin
1267 (method url-fetch)
1268 (uri (string-append "http://www.alcyone.com/software/empy/empy-"
1269 version ".tar.gz"))
1270 (sha256
1271 (base32
1272 "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6"))))
1273 (build-system python-build-system)
1274 (arguments
1275 `(#:python ,python-2
1276 #:phases (alist-replace
1277 'check
1278 (lambda _
1279 (zero? (system* "./test.sh")))
1280 %standard-phases)))
1281 (home-page "http://www.alcyone.com/software/empy/")
1282 (synopsis "Templating system for Python")
1283 (description
1284 "EmPy is a system for embedding Python expressions and statements in
1285template text; it takes an EmPy source file, processes it, and produces
1286output. This is accomplished via expansions, which are special signals to the
1cd4027c 1287EmPy system and are set off by a special prefix (by default the at sign, @@).
011b18c3
LC
1288EmPy can expand arbitrary Python expressions and statements in this way, as
1289well as a variety of special forms. Textual data not explicitly delimited in
1290this way is sent unaffected to the output, allowing Python to be used in
1291effect as a markup language. Also supported are callbacks via hooks,
1292recording and playback via diversions, and dynamic, chainable filters. The
1293system is highly configurable via command line options and embedded
1294commands.")
3f641af0 1295 (license license:lgpl2.1+)))
011b18c3 1296
8deeda0c
LC
1297(define-public python2-element-tree
1298 (package
1299 (name "python2-element-tree")
1300 (version "1.2.6")
1301 (source (origin
1302 (method url-fetch)
1303 (uri (string-append
1304 "http://effbot.org/media/downloads/elementtree-"
1305 version "-20050316.tar.gz"))
1306 (sha256
1307 (base32
1308 "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj"))))
1309 (build-system python-build-system)
1310 (arguments
1311 `(#:python ,python-2 ; seems to be part of Python 3
1312 #:tests? #f)) ; no 'test' sub-command
1313 (synopsis "Toolkit for XML processing in Python")
1314 (description
1315 "ElementTree is a Python library supporting lightweight XML processing.")
1316 (home-page "http://effbot.org/zone/element-index.htm")
3f641af0
DC
1317 (license (license:x11-style
1318 "http://docs.python.org/2/license.html"
1319 "Like \"CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2\"."))))
8deeda0c
LC
1320
1321(define-public python2-pybugz
1322 (package
1323 (name "python2-pybugz")
1324 (version "0.6.11")
1325 (source (origin
1326 (method url-fetch)
1327 (uri (string-append
1328 "http://bits.liquidx.net/projects/pybugz/pybugz-"
1329 version ".tar.gz"))
1330 (sha256
1331 (base32
6f194a1e 1332 "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd"))
fc1adab1
AK
1333 (patches (search-patches "pybugz-stty.patch"
1334 "pybugz-encode-error.patch"))))
8deeda0c
LC
1335 (build-system python-build-system)
1336 (arguments
1337 `(#:python ,python-2 ; SyntaxError with Python 3
1338 #:tests? #f)) ; no 'test' sub-command
1339 (inputs `(("element-tree" ,python2-element-tree)))
1340 (synopsis "Python and command-line interface to Bugzilla")
1341 (description
1342 "PyBugz is a Python library and command-line tool to query the Bugzilla
1343bug tracking system. It is meant as an aid to speed up interaction with the
1344bug tracker.")
1345 (home-page "http://www.liquidx.net/pybugz/")
3f641af0 1346 (license license:gpl2)))
8deeda0c 1347
a480bc41
EB
1348(define-public python-enum34
1349 (package
1350 (name "python-enum34")
d39ae1e5 1351 (version "1.1.0")
a480bc41
EB
1352 (source
1353 (origin
1354 (method url-fetch)
d39ae1e5 1355 (uri (pypi-uri "enum34" version))
a480bc41
EB
1356 (sha256
1357 (base32
d39ae1e5 1358 "0yx1m4564wxgbm4glb3457hi16xihd9w63rv13y2przkdir9dfgp"))))
a480bc41 1359 (build-system python-build-system)
a480bc41
EB
1360 (arguments
1361 `(#:phases
1362 (alist-replace
1363 'check
1364 (lambda _ (zero? (system* "python" "enum/test_enum.py")))
1365 %standard-phases)))
1366 (home-page "https://pypi.python.org/pypi/enum34")
1367 (synopsis "Backported Python 3.4 Enum")
1368 (description
1369 "Enum34 is the new Python stdlib enum module available in Python 3.4
1370backported for previous versions of Python from 2.4 to 3.3.")
3f641af0 1371 (license license:bsd-3)))
a480bc41 1372
820acd1b
LF
1373(define-public python2-enum34
1374 (package-with-python2 python-enum34))
1375
a480bc41
EB
1376(define-public python-parse-type
1377 (package
1378 (name "python-parse-type")
1379 (version "0.3.4")
1380 (source
1381 (origin
1382 (method url-fetch)
1383 (uri (string-append "https://pypi.python.org/packages/source/p/"
1384 "parse_type/parse_type-" version ".tar.gz"))
1385 (sha256
1386 (base32
1387 "0iv1c34npr4iynwpgv1vkjx9rjd18a85ir8c01gc5f7wp8iv7l1x"))))
1388 (build-system python-build-system)
1389 (inputs
1390 `(("python-setuptools" ,python-setuptools)
1391 ("python-six" ,python-six)
68f1cdec 1392 ("python-parse" ,python-parse)))
a480bc41
EB
1393 (arguments '(#:tests? #f)) ;TODO: tests require pytest
1394 (home-page "https://github.com/jenisys/parse_type")
1395 (synopsis "Extended parse module")
1396 (description
1397 "Parse_type extends the python parse module.")
3f641af0 1398 (license license:bsd-3)))
a480bc41
EB
1399
1400(define-public python-parse
1401 (package
1402 (name "python-parse")
eb3d3503 1403 (version "1.6.6")
a480bc41
EB
1404 (source
1405 (origin
1406 (method url-fetch)
eb3d3503 1407 (uri (pypi-uri "parse" version))
a480bc41
EB
1408 (sha256
1409 (base32
eb3d3503 1410 "0y31i3mwgv35qn0kzzjn9q8jqfdqmbi6sr6yfvn8rq4lqjm5lhvi"))))
a480bc41
EB
1411 (build-system python-build-system)
1412 (arguments
1413 `(#:phases
1414 (alist-replace
1415 'check
1416 (lambda _ (zero? (system* "python" "test_parse.py")))
1417 %standard-phases)))
1418 (home-page "https://github.com/r1chardj0n3s/parse")
1419 (synopsis "Parse strings")
1420 (description
1421 "Parse strings using a specification based on the Python format()
1422syntax.")
3f641af0 1423 (license license:x11)))
a480bc41
EB
1424
1425
515e6878
LC
1426(define-public scons
1427 (package
1428 (name "scons")
a3f61425 1429 (version "2.3.4")
515e6878
LC
1430 (source (origin
1431 (method url-fetch)
de67e922
LF
1432 (uri (string-append "mirror://sourceforge/scons/scons/" version
1433 "/scons-" version ".tar.gz"))
515e6878
LC
1434 (sha256
1435 (base32
a3f61425 1436 "0hdlci43wjz8maryj83mz04ir6rwcdrrzpd7cpzvdlzycqhdfmsb"))))
515e6878
LC
1437 (build-system python-build-system)
1438 (arguments
1439 ;; With Python 3.x, fails to build with a syntax error.
1440 `(#:python ,python-2
1441 #:tests? #f)) ; no 'python setup.py test' command
1442 (home-page "http://scons.org/")
1443 (synopsis "Software construction tool written in Python")
1444 (description
1445 "SCons is a software construction tool. Think of SCons as an improved,
1446cross-platform substitute for the classic Make utility with integrated
1447functionality similar to autoconf/automake and compiler caches such as ccache.
1448In short, SCons is an easier, more reliable and faster way to build
1449software.")
3f641af0 1450 (license license:x11)))
011b18c3 1451
c15a5c0e
DT
1452(define-public python-extras
1453 (package
1454 (name "python-extras")
1455 (version "0.0.3")
1456 (source
1457 (origin
1458 (method url-fetch)
1459 (uri (string-append
1460 "https://pypi.python.org/packages/source/e/extras/extras-"
1461 version ".tar.gz"))
1462 (sha256
1463 (base32
1464 "1h7zx4dfyclalg0fqnfjijpn0f793a9mx8sy3b27gd31nr6dhq3s"))))
1465 (build-system python-build-system)
1466 (inputs
1467 `(("python-setuptools" ,python-setuptools)))
1468 (arguments
1469 ;; error in setup.cfg: command 'test' has no such option 'buffer'
1470 '(#:tests? #f))
1471 (home-page "https://github.com/testing-cabal/extras")
1472 (synopsis "Useful extensions to the Python standard library")
1473 (description
1474 "Extras is a set of extensions to the Python standard library.")
bd3fa666 1475 (license license:expat)))
c15a5c0e
DT
1476
1477(define-public python2-extras
1478 (package-with-python2 python-extras))
1479
56ea0efd
DT
1480(define-public python-mimeparse
1481 (package
1482 (name "python-mimeparse")
1483 (version "0.1.4")
1484 (source
1485 (origin
1486 (method url-fetch)
1487 (uri (string-append
1488 "https://pypi.python.org/packages/source/p/python-mimeparse/python-mimeparse-"
1489 version ".tar.gz"))
1490 (sha256
1491 (base32
1492 "1hyxg09kaj02ri0rmwjqi86wk4nd1akvv7n0dx77azz76wga4s9w"))))
1493 (build-system python-build-system)
1494 (inputs
1495 `(("python-setuptools" ,python-setuptools)))
1496 (arguments
1497 '(#:tests? #f)) ; no setup.py test command
1498 (home-page
1499 "https://github.com/dbtsai/python-mimeparse")
9e771e3b 1500 (synopsis "Python library for parsing MIME types")
56ea0efd
DT
1501 (description
1502 "Mimeparse provides basic functions for parsing MIME type names and
1503matching them against a list of media-ranges.")
bd3fa666 1504 (license license:expat)))
56ea0efd
DT
1505
1506(define-public python2-mimeparse
1507 (package-with-python2 python-mimeparse))
1508
4435427e
DT
1509(define-public python-nose
1510 (package
1511 (name "python-nose")
f7cb9841 1512 (version "1.3.7")
4435427e
DT
1513 (source
1514 (origin
1515 (method url-fetch)
f7cb9841 1516 (uri (pypi-uri "nose" version))
4435427e
DT
1517 (sha256
1518 (base32
f7cb9841 1519 "164a43k7k2wsqqk1s6vavcdamvss4mz0vd6pwzv2h9n8rgwzxgzi"))))
4435427e
DT
1520 (build-system python-build-system)
1521 (inputs
1522 `(("python-setuptools" ,python-setuptools)))
1523 (arguments
1524 '(#:tests? #f)) ; FIXME: test suite fails
1525 (home-page "http://readthedocs.org/docs/nose/")
1526 (synopsis "Python testing library")
1527 (description
1528 "Nose extends the unittest library to make testing easier.")
3f641af0 1529 (license license:lgpl2.0+)))
4435427e
DT
1530
1531(define-public python2-nose
1532 (package-with-python2 python-nose))
1533
0aea283a
EF
1534(define-public python-nose2
1535 (package
1536 (name "python-nose2")
1537 (version "0.6.5")
1538 (source
1539 (origin
1540 (method url-fetch)
1541 (uri (pypi-uri "nose2" version))
1542 (sha256
1543 (base32
1544 "1x4zjq1zlyrh8b9ba0cmafd3w94pxhid408kibyjd3s6h1lap6s7"))))
1545 (build-system python-build-system)
1546 (arguments `(#:tests? #f)) ; 'module' object has no attribute 'collector'
1547 (native-inputs
1548 `(("python-setuptools" ,python-setuptools)))
1549 (inputs
1550 `(("python-cov-core" ,python-cov-core)
1551 ("python-pytest-cov" ,python-pytest-cov)
1552 ("python-six" ,python-six)))
1553 (home-page "https://github.com/nose-devs/nose2")
1554 (synopsis "Next generation of nicer testing for Python")
1555 (description
1556 "Nose2 is the next generation of nicer testing for Python, based on the
1557plugins branch of unittest2. Nose2 aims to improve on nose by providing a
1558better plugin api, being easier for users to configure, and simplifying internal
1559interfaces and processes.")
1560 (license license:bsd-2)))
1561
1562(define-public python2-nose2
1563 (package-with-python2 python-nose2))
1564
6cd9c356
DT
1565(define-public python-unittest2
1566 (package
1567 (name "python-unittest2")
1568 (version "0.5.1")
1569 (source
1570 (origin
1571 (method url-fetch)
1572 (uri (string-append
1573 "https://pypi.python.org/packages/source/u/unittest2py3k/unittest2py3k-"
1574 version ".tar.gz"))
1575 (sha256
1576 (base32
1577 "00yl6lskygcrddx5zspkhr0ibgvpknl4678kkm6s626539grq93q"))))
1578 (build-system python-build-system)
1579 (inputs
1580 `(("python-setuptools" ,python-setuptools)))
1581 (home-page "http://pypi.python.org/pypi/unittest2")
1582 (synopsis "Python unit testing library")
1583 (description
1584 "Unittest2 is a replacement for the unittest module in the Python
1585standard library.")
3f641af0 1586 (license license:psfl)))
6cd9c356
DT
1587
1588(define-public python2-unittest2
1589 (package (inherit python-unittest2)
1590 (name "python2-unittest2")
1591 (version "0.5.1")
1592 (source
1593 (origin
1594 (method url-fetch)
1595 (uri (string-append
1596 "https://pypi.python.org/packages/source/u/unittest2/unittest2-"
1597 version ".tar.gz"))
1598 (sha256
1599 (base32
1600 "0wbs4i4x3x7klr3v35ss6p9mcqz883i1xgcpkhvl7n2lyv6yhpda"))))
1601 (inputs
7957fe6c 1602 `(("python2-setuptools" ,python2-setuptools)))
6cd9c356
DT
1603 (arguments
1604 `(#:python ,python-2
1605 #:tests? #f)))) ; no setup.py test command
1606
542ad60f
DT
1607(define-public python-py
1608 (package
1609 (name "python-py")
71c8a804 1610 (version "1.4.31")
542ad60f
DT
1611 (source
1612 (origin
1613 (method url-fetch)
71c8a804 1614 (uri (pypi-uri "py" version))
542ad60f
DT
1615 (sha256
1616 (base32
71c8a804 1617 "0561gz2w3i825gyl42mcq14y3dcgkapfiv5zv9a2bz15qxiijl56"))))
542ad60f
DT
1618 (build-system python-build-system)
1619 (inputs
1620 `(("python-setuptools" ,python-setuptools)))
1621 (home-page "http://pylib.readthedocs.org/")
1622 (synopsis "Python library for parsing, I/O, instrospection, and logging")
1623 (description
1624 "Py is a Python library for file name parsing, .ini file parsing, I/O,
1625code introspection, and logging.")
bd3fa666 1626 (license license:expat)))
542ad60f
DT
1627
1628(define-public python2-py
1629 (package-with-python2 python-py))
1630
855d4761
DT
1631(define-public python-pytest
1632 (package
1633 (name "python-pytest")
61a4332d 1634 (version "2.7.3")
855d4761
DT
1635 (source
1636 (origin
1637 (method url-fetch)
1638 (uri (string-append
1639 "https://pypi.python.org/packages/source/p/pytest/pytest-"
1640 version ".tar.gz"))
1641 (sha256
1642 (base32
61a4332d 1643 "1z4yi986f9n0p8qmzmn21m21m8j1x78hk3505f89baqm6pdw7afm"))
855d4761
DT
1644 (modules '((guix build utils)))
1645 (snippet
1646 ;; One of the tests involves the /usr directory, so it fails.
1647 '(substitute* "testing/test_argcomplete.py"
1648 (("def test_remove_dir_prefix\\(self\\):")
1649 "@pytest.mark.xfail\n def test_remove_dir_prefix(self):")))))
1650 (build-system python-build-system)
1651 (inputs
1652 `(("python-setuptools" ,python-setuptools)
1653 ("python-py" ,python-py)
1654 ("python-nose" ,python-nose)
1655 ("python-mock" ,python-mock)))
1656 (home-page "http://pytest.org")
1657 (synopsis "Python testing library")
1658 (description
1659 "Pytest is a testing tool that provides auto-discovery of test modules
1660and functions, detailed info on failing assert statements, modular fixtures,
1661and many external plugins.")
bd3fa666 1662 (license license:expat)))
855d4761
DT
1663
1664(define-public python2-pytest
1665 (package-with-python2 python-pytest))
1666
358c3d61
EF
1667(define-public python-pytest-cov
1668 (package
1669 (name "python-pytest-cov")
545f4a1c 1670 (version "2.2.1")
358c3d61
EF
1671 (source
1672 (origin
1673 (method url-fetch)
1674 (uri (pypi-uri "pytest-cov" version))
1675 (sha256
545f4a1c
EF
1676 (base32
1677 "1yl4nbhzfgsxqlsyk4clafgp9x11zvgrkprm9i2p3fgkwx9jxcm8"))))
10468636 1678 (build-system python-build-system)
545f4a1c 1679 (inputs
10468636
EF
1680 `(("python-coverage" ,python-coverage)
1681 ("python-pytest" ,python-pytest)))
10468636
EF
1682 (home-page "https://github.com/pytest-dev/pytest-cov")
1683 (synopsis "Pytest plugin for measuring coverage")
1684 (description
1685 "Pytest-cov produces coverage reports. It supports centralised testing and
1686distributed testing in both @code{load} and @code{each} modes. It also
1687supports coverage of subprocesses.")
545f4a1c
EF
1688 (license license:expat)
1689 (properties `((python2-variant . ,(delay python2-pytest-cov))))))
358c3d61
EF
1690
1691(define-public python2-pytest-cov
545f4a1c
EF
1692 (let ((base (package-with-python2 (strip-python2-variant python-pytest-cov))))
1693 (package
1694 (inherit base)
1695 (inputs `(("python2-setuptools" ,python2-setuptools)
1696 ,@(package-inputs base))))))
358c3d61 1697
6784f2e3
RW
1698(define-public python-pytest-runner
1699 (package
1700 (name "python-pytest-runner")
1701 (version "2.6.2")
1702 (source
1703 (origin
1704 (method url-fetch)
54cd239b 1705 (uri (pypi-uri "pytest-runner" version))
6784f2e3
RW
1706 (sha256
1707 (base32
1708 "1nwcqx0l3fv52kv8526wy8ypzghbq96c96di318d98d3wh7a8xg7"))))
1709 (build-system python-build-system)
1710 (arguments
1711 `(#:phases
1712 (modify-phases %standard-phases
1713 ;; The fancy way of setting the version with setuptools_scm does not
1714 ;; seem to work here.
1715 (add-after 'unpack 'set-version
1716 (lambda _
1717 (substitute* "docs/conf.py"
1718 (("version = setuptools_scm\\.get_version\\(root='\\.\\.')")
1719 (string-append "version = \"" ,version "\"")))
1720 #t)))))
1721 (native-inputs
1722 `(("python-pytest" ,python-pytest)
1723 ("python-setuptools-scm" ,python-setuptools-scm)))
54cd239b 1724 (home-page "https://github.com/pytest-dev/pytest-runner")
6784f2e3
RW
1725 (synopsis "Invoke py.test as a distutils command")
1726 (description
1727 "This package provides a @command{pytest-runner} command that
1728@file{setup.py} files can use to run tests.")
54cd239b
EF
1729 (license license:expat)
1730 (properties `((python2-variant . ,(delay python2-pytest-runner))))))
1731
1732(define-public python2-pytest-runner
1733 (let ((base (package-with-python2
1734 (strip-python2-variant python-pytest-runner))))
1735 (package
1736 (inherit base)
1737 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1738 ,@(package-native-inputs base))))))
6784f2e3
RW
1739
1740(define-public python2-pytest-runner
1741 (package-with-python2 python-pytest-runner))
1742
44547e51
EF
1743(define-public python-pytest-mock
1744 (package
1745 (name "python-pytest-mock")
1746 (version "1.2")
1747 (source
1748 (origin
1749 (method url-fetch)
1750 (uri (pypi-uri "pytest-mock" version ".zip"))
1751 (sha256
1752 (base32
1753 "03zxar5drzm7ksqyrwypjaza3cri6wqvpr6iam92djvg6znp32gp"))))
1754 (build-system python-build-system)
1755 (native-inputs
1756 `(("unzip" ,unzip)))
1757 (inputs
1758 `(("python-py" ,python-py)
1759 ("python-pytest" ,python-pytest)))
1760 (home-page "https://github.com/pytest-dev/pytest-mock/")
1761 (synopsis "Thin-wrapper around the mock package for easier use with py.test")
1762 (description
1763 "This plugin installs a @code{mocker} fixture which is a thin-wrapper
1764around the patching API provided by the @code{mock} package, but with the
1765benefit of not having to worry about undoing patches at the end of a test.
1766The mocker fixture has the same API as @code{mock.patch}, supporting the
1767same arguments.")
1768 (properties `((python2-variant . ,(delay python2-pytest-mock))))
1769 (license license:expat)))
1770
1771(define-public python2-pytest-mock
1772 (let ((base (package-with-python2
1773 (strip-python2-variant python-pytest-mock))))
1774 (package (inherit base)
1775 (native-inputs
1776 `(("python2-setuptools" ,python2-setuptools)
1777 ,@(package-native-inputs base)))
1778 (inputs
1779 `(("python2-mock" ,python2-mock)
1780 ,@(package-inputs base))))))
1781
8fa58fc9
CAW
1782(define-public python-pytest-xdist
1783 (package
1784 (name "python-pytest-xdist")
1785 (version "1.14")
1786 (source
1787 (origin
1788 (method url-fetch)
1789 (uri (pypi-uri "pytest-xdist" version ".zip"))
1790 (sha256
1791 (base32
1792 "08rn2l39ds60xshs4js787l84pfckksqklfq2wq9x8ig2aci2pja"))))
1793 (build-system python-build-system)
1794 (native-inputs
1795 `(("unzip" ,unzip)
8fa58fc9 1796 ("python-setuptools-scm" ,python-setuptools-scm)))
fbe9abcc
EF
1797 (inputs
1798 `(("python-apipkg" ,python-apipkg)
1799 ("python-execnet" ,python-execnet)
8fa58fc9
CAW
1800 ("python-pytest" ,python-pytest)
1801 ("python-py" ,python-py)))
1802 (home-page
1803 "https://github.com/pytest-dev/pytest-xdist")
1804 (synopsis
1805 "Plugin for py.test with distributed testing and loop-on-failing modes")
1806 (description
1807 "The pytest-xdist plugin extends py.test with some unique test execution
1808modes: parallelization, running tests in boxed subprocesses, the ability
1809to run tests repeatedly when failed, and the ability to run tests on multiple
1810Python interpreters or platforms. It uses rsync to copy the existing
1811program code to a remote location, executes there, and then syncs the
1812result back.")
fbe9abcc
EF
1813 (license license:expat)
1814 (properties `((python2-variant . ,(delay python2-pytest-xdist))))))
8fa58fc9
CAW
1815
1816(define-public python2-pytest-xdist
fbe9abcc
EF
1817 (let ((base (package-with-python2
1818 (strip-python2-variant python-pytest-xdist))))
1819 (package
1820 (inherit base)
1821 (native-inputs `(("python2-setuptools" ,python2-setuptools)
1822 ,@(package-native-inputs base))))))
8fa58fc9 1823
84d24017
DT
1824(define-public python-scripttest
1825 (package
1826 (name "python-scripttest")
1827 (version "1.3")
1828 (source
1829 (origin
1830 (method url-fetch)
1831 (uri (string-append
1832 "https://pypi.python.org/packages/source/s/scripttest/scripttest-"
1833 version ".tar.gz"))
1834 (sha256
1835 (base32
1836 "0f4w84k8ck82syys7yg9maz93mqzc8p5ymis941x034v44jzq74m"))))
1837 (build-system python-build-system)
1838 (inputs
1839 `(("python-setuptools" ,python-setuptools)
1840 ("python-pytest" ,python-pytest)))
1841 (home-page "http://pythonpaste.org/scripttest/")
1842 (synopsis "Python library to test command-line scripts")
1843 (description "Scripttest is a Python helper library for testing
1844interactive command-line applications. With it you can run a script in a
1845subprocess and see the output as well as any file modifications.")
bd3fa666 1846 (license license:expat)))
84d24017
DT
1847
1848(define-public python2-scripttest
1849 (package-with-python2 python-scripttest))
1850
d8fa80e1
DT
1851(define-public python-testtools
1852 (package
1853 (name "python-testtools")
1854 (version "1.0.0")
1855 (source
1856 (origin
1857 (method url-fetch)
1858 (uri (string-append
1859 "https://pypi.python.org/packages/source/t/testtools/testtools-"
1860 version ".tar.gz"))
1861 (sha256
1862 (base32
1863 "1dyml28ykpl5jb9khdmcdvhy1cxqingys6qvj2k04fzlaj6z3bbx"))))
1864 (build-system python-build-system)
0e88cbf8
CR
1865 (propagated-inputs
1866 `(("python-mimeparse" ,python-mimeparse)))
d8fa80e1
DT
1867 (inputs
1868 `(("python-setuptools" ,python-setuptools)
d8fa80e1
DT
1869 ("python-extras" ,python-extras)))
1870 (home-page "https://github.com/testing-cabal/testtools")
1871 (synopsis
1872 "Extensions to the Python standard library unit testing framework")
1873 (description
1874 "Testtools extends the Python standard library unit testing framework to
1875provide matchers, more debugging information, and cross-Python
1876compatibility.")
3f641af0 1877 (license license:psfl)))
d8fa80e1
DT
1878
1879(define-public python2-testtools
1880 (package-with-python2 python-testtools))
1881
5bf3afea
DT
1882(define-public python-testscenarios
1883 (package
1884 (name "python-testscenarios")
1885 (version "0.4")
1886 (source
1887 (origin
1888 (method url-fetch)
1889 (uri (string-append
1890 "https://pypi.python.org/packages/source/t/testscenarios/testscenarios-"
1891 version ".tar.gz"))
1892 (sha256
1893 (base32
1894 "1671jvrvqlmbnc42j7pc5y6vc37q44aiwrq0zic652pxyy2fxvjg"))))
1895 (build-system python-build-system)
1896 (inputs
1897 `(("python-setuptools" ,python-setuptools)
1898 ("python-testtools" ,python-testtools)
1899 ("python-mimeparse" ,python-mimeparse)))
1900 (home-page "https://launchpad.net/testscenarios")
1901 (synopsis "Pyunit extension for dependency injection")
1902 (description
1903 "Testscenarios provides clean dependency injection for Python unittest
1904style tests.")
3f641af0 1905 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
5bf3afea
DT
1906
1907(define-public python2-testscenarios
1908 (package-with-python2 python-testscenarios))
1909
dac79ecc
DT
1910(define-public python-testresources
1911 (package
1912 (name "python-testresources")
1913 (version "0.2.7")
1914 (source
1915 (origin
1916 (method url-fetch)
1917 (uri (string-append
1918 "https://pypi.python.org/packages/source/t/testresources/testresources-"
1919 version ".tar.gz"))
1920 (sha256
1921 (base32
1922 "0cbj3plbllyz42c4b5xxgwaa7mml54lakslrn4kkhinxhdri22md"))))
1923 (build-system python-build-system)
1924 (inputs
1925 `(("python-setuptools" ,python-setuptools)))
1926 (home-page "https://launchpad.net/testresources")
1927 (synopsis
1928 "Pyunit extension for managing test resources")
1929 (description
1930 "Testresources is an extension to Python's unittest to allow declarative
1931use of resources by test cases.")
3f641af0 1932 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
dac79ecc
DT
1933
1934(define-public python2-testresources
1935 (package-with-python2 python-testresources))
1936
070ab058
DT
1937(define-public python-subunit
1938 (package
1939 (name "python-subunit")
1940 (version "0.0.21")
1941 (source
1942 (origin
1943 (method url-fetch)
1944 (uri (string-append
1945 "https://pypi.python.org/packages/source/p/python-subunit/python-subunit-"
1946 version ".tar.gz"))
1947 (sha256
1948 (base32
1949 "1nkw9wfbvizmpajbj3in8ns07g7lwkiv8hip14jjlwk3cacls6jv"))))
1950 (build-system python-build-system)
1951 (inputs
1952 `(("python-setuptools" ,python-setuptools)
1953 ("python-testtools" ,python-testtools)
1954 ("python-mimeparse" ,python-mimeparse)
1955 ("python-testscenarios" ,python-testscenarios)))
1956 (home-page "http://launchpad.net/subunit")
1957 (synopsis "Python implementation of the subunit protocol")
1958 (description
1959 "Python-subunit is a Python implementation of the subunit test streaming
1960protocol.")
3f641af0 1961 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
070ab058
DT
1962
1963(define-public python2-subunit
1964 (package-with-python2 python-subunit))
1965
7787ef76
CR
1966;; Recent versions of python-fixtures need a recent version of python-pbr,
1967;; which needs a recent version of python-fixtures. To fix this circular
1968;; dependency, we keep old versions of python-fixtures and python-pbr to
1969;; bootstrap the whole thing:
1970;; - python-fixtures-0.3.16 is used to build python-pbr-0.11
1971;; - python-pbr-0.11 is used to build python-fixtures
1972;; - python-fixtures is used to build python-pbr
1973(define-public python-fixtures-0.3.16
cd49454b
DT
1974 (package
1975 (name "python-fixtures")
1976 (version "0.3.16")
1977 (source
1978 (origin
1979 (method url-fetch)
1980 (uri (string-append
1981 "https://pypi.python.org/packages/source/f/fixtures/fixtures-"
1982 version ".tar.gz"))
1983 (sha256
1984 (base32
1985 "0x9r2gwilcig5g54k60bxzg96zabizq1855lrprlb4zckalp9asc"))))
1986 (build-system python-build-system)
1987 (inputs
1988 `(("python-setuptools" ,python-setuptools)))
1989 (arguments
1990 '(#:tests? #f)) ; no setup.py test command
1991 (home-page "https://launchpad.net/python-fixtures")
1992 (synopsis "Python test fixture library")
1993 (description
1994 "Fixtures provides a way to create reusable state, useful when writing
1995Python tests.")
3f641af0 1996 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
cd49454b 1997
7787ef76
CR
1998(define-public python2-fixtures-0.3.16
1999 (package-with-python2 python-fixtures-0.3.16))
2000
2001(define-public python-pbr-0.11
2002 (package
2003 (name "python-pbr")
2004 (version "0.11.0")
2005 (source
2006 (origin
2007 (method url-fetch)
2008 (uri (string-append
2009 "https://pypi.python.org/packages/source/p/pbr/pbr-"
2010 version ".tar.gz"))
2011 (sha256
2012 (base32
2013 "0v9gb7gyqf7q9s99l0nnjj9ww9b0jvyqlwm4d56pcyinxydddw6p"))))
2014 (build-system python-build-system)
2015 (arguments
2016 `(#:tests? #f)) ;; Most tests seem to use the Internet.
2017 (inputs
2018 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
2019 ("python-pip" ,python-pip)
2020 ("python-setuptools" ,python-setuptools)))
2021 (home-page "https://launchpad.net/pbr")
2022 (synopsis "Change the default behavior of Python’s setuptools")
2023 (description
2024 "Python Build Reasonableness (PBR) is a library that injects some useful
2025and sensible default behaviors into your setuptools run.")
3f641af0 2026 (license license:asl2.0)))
7787ef76
CR
2027
2028(define-public python2-pbr-0.11
2029 (package-with-python2 python-pbr-0.11))
2030
1ef09c0c 2031(define-public python-pbr
e25f0174
BW
2032 (package
2033 (name "python-pbr")
1ef09c0c
BW
2034 (version "1.8.1")
2035 (source
e25f0174
BW
2036 (origin
2037 (method url-fetch)
2038 (uri (string-append
2039 "https://pypi.python.org/packages/source/p/pbr/pbr-"
2040 version
2041 ".tar.gz"))
2042 (sha256
2043 (base32
2044 "0jcny36cf3s8ar5r4a575npz080hndnrfs4np1fqhv0ym4k7c4p2"))))
1ef09c0c 2045 (build-system python-build-system)
e25f0174
BW
2046 (arguments
2047 `(#:tests? #f)) ;; Most tests seem to use the Internet.
2048 (propagated-inputs
2049 `(("python-testrepository" ,python-testrepository)
2050 ("git" ,git))) ;; pbr actually uses the "git" binary.
1ef09c0c 2051 (inputs
e25f0174
BW
2052 `(("python-fixtures" ,python-fixtures)
2053 ("python-mimeparse" ,python-mimeparse)
2054 ("python-mock" ,python-mock)
2055 ("python-setuptools" ,python-setuptools)
2056 ("python-six" ,python-six)
2057 ("python-sphinx" ,python-sphinx)
2058 ("python-testrepository" ,python-testrepository)
2059 ("python-testresources" ,python-testresources)
2060 ("python-testscenarios" ,python-testscenarios)
2061 ("python-testtools" ,python-testtools)
2062 ("python-virtualenv" ,python-virtualenv)))
2063 (home-page "https://launchpad.net/pbr")
2064 (synopsis "Change the default behavior of Python’s setuptools")
2065 (description
2066 "Python Build Reasonableness (PBR) is a library that injects some useful
2067and sensible default behaviors into your setuptools run.")
3f641af0 2068 (license license:asl2.0)))
1ef09c0c
BW
2069
2070(define-public python2-pbr
e25f0174 2071 (package-with-python2 python-pbr))
1ef09c0c 2072
7787ef76
CR
2073(define-public python-fixtures
2074 (package
2075 (name "python-fixtures")
13fcc6df 2076 (version "1.4.0")
7787ef76
CR
2077 (source
2078 (origin
2079 (method url-fetch)
13fcc6df 2080 (uri (pypi-uri "fixtures" version))
7787ef76
CR
2081 (sha256
2082 (base32
13fcc6df 2083 "0djxvdwm8s60dbfn7bhf40x6g818p3b3mlwijm1c3bqg7msn271y"))))
7787ef76
CR
2084 (build-system python-build-system)
2085 (propagated-inputs
2086 `(("python-six" ,python-six)
2087 ("python-pbr-0.11" ,python-pbr-0.11)))
2088 (inputs
2089 `(("python-pip" ,python-pip)
2090 ("python-setuptools" ,python-setuptools)
2091 ;; Tests
2092 ("python-testtools" ,python-testtools)))
2093 (arguments
2094 '(#:tests? #f)) ; no setup.py test command
2095 (home-page "https://launchpad.net/python-fixtures")
2096 (synopsis "Python test fixture library")
2097 (description
2098 "Fixtures provides a way to create reusable state, useful when writing
2099Python tests.")
3f641af0 2100 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
7787ef76 2101
cd49454b
DT
2102(define-public python2-fixtures
2103 (package-with-python2 python-fixtures))
2104
b24a0c00
DT
2105(define-public python-testrepository
2106 (package
2107 (name "python-testrepository")
2108 (version "0.0.20")
2109 (source
2110 (origin
2111 (method url-fetch)
2112 (uri (string-append
2113 "https://pypi.python.org/packages/source/t/testrepository/testrepository-"
2114 version ".tar.gz"))
2115 (sha256
2116 (base32
2117 "1ssqb07c277010i6gzzkbdd46gd9mrj0bi0i8vn560n2k2y4j93m"))))
2118 (build-system python-build-system)
05de40c5 2119 (propagated-inputs
7787ef76 2120 `(("python-fixtures-0.3.16" ,python-fixtures-0.3.16)
05de40c5 2121 ("python-testtools" ,python-testtools)))
b24a0c00
DT
2122 (inputs
2123 `(("python-setuptools" ,python-setuptools)
b24a0c00 2124 ("python-subunit" ,python-subunit)
b24a0c00
DT
2125 ("python-mimeparse" ,python-mimeparse)))
2126 (home-page "https://launchpad.net/testrepository")
2127 (synopsis "Database for Python test results")
2128 (description "Testrepository provides a database of test results which can
2129be used as part of a developer's workflow to check things such as what tests
2130have failed since the last commit or what tests are currently failing.")
3f641af0 2131 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
b24a0c00
DT
2132
2133(define-public python2-testrepository
2134 (package-with-python2 python-testrepository))
2135
243a009a
DT
2136(define-public python-coverage
2137 (package
2138 (name "python-coverage")
4d4cf3dd 2139 (version "4.1")
243a009a
DT
2140 (source
2141 (origin
2142 (method url-fetch)
82a3c582 2143 (uri (pypi-uri "coverage" version))
243a009a
DT
2144 (sha256
2145 (base32
4d4cf3dd 2146 "01rbr4br4lsk0lwn8fb96zwd2xr4f0mg1w7iq3j11i8f5ig2nqs1"))))
243a009a
DT
2147 (build-system python-build-system)
2148 (inputs
2149 `(("python-setuptools" ,python-setuptools)))
2150 (home-page "http://nedbatchelder.com/code/coverage")
2151 (synopsis "Code coverage measurement for Python")
2152 (description
2153 "Coverage measures code coverage, typically during test execution. It
2154uses the code analysis tools and tracing hooks provided in the Python standard
2155library to determine which lines are executable, and which have been
2156executed.")
3f641af0 2157 (license license:bsd-3)))
243a009a
DT
2158
2159(define-public python2-coverage
2160 (package-with-python2 python-coverage))
2161
12f839fd
EF
2162(define-public python-cov-core
2163 (package
2164 (name "python-cov-core")
2165 (version "1.15.0")
2166 (source
2167 (origin
2168 (method url-fetch)
2169 (uri (pypi-uri "cov-core" version))
2170 (sha256
2171 (base32
2172 "0k3np9ymh06yv1ib96sb6wfsxjkqhmik8qfsn119vnhga9ywc52a"))))
2173 (build-system python-build-system)
2174 (native-inputs
2175 `(("python-coverage" ,python-coverage)))
2176 (home-page "https://github.com/schlamar/cov-core")
2177 (synopsis "plugin core for use by pytest-cov, nose-cov and nose2-cov")
2178 (description
2179 "This is a library package for use by pytest-cov, nose-cov and nose2-cov.
2180It is useful for developing coverage plugins for these testing frameworks.")
8120205c
EF
2181 (license license:expat)
2182 (properties `((python2-variant . ,(delay python2-cov-core))))))
12f839fd
EF
2183
2184(define-public python2-cov-core
8120205c 2185 (let ((cov-core (package-with-python2 (strip-python2-variant python-cov-core))))
12f839fd
EF
2186 (package (inherit cov-core)
2187 (native-inputs
2188 `(("python2-setuptools" ,python2-setuptools)
2189 ,@(package-native-inputs cov-core))))))
2190
041358fb
DT
2191(define-public python-discover
2192 (package
2193 (name "python-discover")
2194 (version "0.4.0")
2195 (source
2196 (origin
2197 (method url-fetch)
2198 (uri (string-append
2199 "https://pypi.python.org/packages/source/d/discover/discover-"
2200 version ".tar.gz"))
2201 (sha256
2202 (base32
2203 "0y8d0zwiqar51kxj8lzmkvwc3b8kazb04gk5zcb4nzg5k68zmhq5"))))
2204 (build-system python-build-system)
2205 (inputs
2206 `(("python-setuptools" ,python-setuptools)))
2207 (home-page "http://pypi.python.org/pypi/discover/")
2208 (synopsis
2209 "Python test discovery for unittest")
2210 (description
2211 "Discover provides test discovery for unittest, a feature that has been
e881752c 2212backported from Python 2.7 for Python 2.4+.")
3f641af0 2213 (license license:bsd-3)))
041358fb
DT
2214
2215(define-public python2-discover
2216 (package-with-python2 python-discover))
2217
a480bc41
EB
2218(define-public behave
2219 (package
2220 (name "behave")
287cfd1a 2221 (version "1.2.5")
a480bc41
EB
2222 (source (origin
2223 (method url-fetch)
287cfd1a 2224 (uri (pypi-uri "behave" version ".tar.bz2"))
a480bc41
EB
2225 (sha256
2226 (base32
287cfd1a 2227 "1iypp6z46r19n4xmgx6m1lwmlpfjh8vapq8izigrqlaarvp2y64c"))))
a480bc41
EB
2228 (build-system python-build-system)
2229 (inputs
2230 `(("python-setuptools" ,python-setuptools)
2231 ("python-six" ,python-six)
a480bc41
EB
2232 ("python-parse" ,python-parse)
2233 ("python-parse-type" ,python-parse-type)))
2234 (arguments `(#:tests? #f)) ;TODO: tests require nose>=1.3 and
2235 ;PyHamcrest>=1.8
2236 (home-page "http://github.com/behave/behave")
2237 (synopsis "Python behavior-driven development")
2238 (description
2239 "Behave is a tool for behavior-driven development in python.
2240Behavior-driven development (or BDD) is an agile software development
2241technique that encourages collaboration between developers, QA and
2242non-technical or business participants in a software project. Behave uses
2243tests written in a natural language style, backed up by Python code.")
3f641af0 2244 (license license:x11)))
c7303d3c
DT
2245
2246(define-public python-exif-read
2247 (package
2248 (name "python-exif-read")
2a2d0981 2249 (version "2.1.2")
c7303d3c
DT
2250 (source (origin
2251 (method url-fetch)
2a2d0981 2252 (uri (pypi-uri "ExifRead" version))
c7303d3c
DT
2253 (sha256
2254 (base32
2a2d0981 2255 "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr"))))
c7303d3c
DT
2256 (build-system python-build-system)
2257 (inputs
2258 `(("python-setuptools" ,python-setuptools)))
2259 (arguments `(#:tests? #f)) ; no tests
2260 (home-page "https://github.com/ianare/exif-py")
2261 (synopsis "Python library to extract EXIF data from image files")
2262 (description
2263 "ExifRead is a Python library to extract EXIF data from tiff and jpeg
2264files.")
3f641af0 2265 (license license:bsd-3)))
c7303d3c
DT
2266
2267(define-public python2-exif-read
2268 (package-with-python2 python-exif-read))
d5f89b22
DT
2269
2270(define-public python-pyld
2271 (package
2272 (name "python-pyld")
af1ab773 2273 (version "0.6.8")
d5f89b22
DT
2274 (source (origin
2275 (method url-fetch)
af1ab773 2276 (uri (pypi-uri "PyLD" version))
d5f89b22
DT
2277 (sha256
2278 (base32
af1ab773 2279 "0k881ffazpf8q1z8862g4bb3pzwpnz9whrci2mf311mvn1qbyqad"))))
d5f89b22
DT
2280 (build-system python-build-system)
2281 (inputs
2282 `(("python-setuptools" ,python-setuptools)))
2283 (arguments `(#:tests? #f)) ; no tests
2284 (home-page "http://github.com/digitalbazaar/pyld")
2285 (synopsis "Python implementation of the JSON-LD specification")
2286 (description
2287 "PyLD is an implementation of the JSON-LD specification.")
3f641af0 2288 (license license:bsd-3)))
d5f89b22
DT
2289
2290(define-public python2-pyld
2291 (package-with-python2 python-pyld))
3a1f9a68
DT
2292
2293(define-public python-certifi
2294 (package
2295 (name "python-certifi")
9a41f443 2296 (version "2015.11.20.1")
3a1f9a68
DT
2297 (source (origin
2298 (method url-fetch)
9a41f443 2299 (uri (pypi-uri "certifi" version))
3a1f9a68
DT
2300 (sha256
2301 (base32
9a41f443 2302 "05lgwf9rz1kn465azy2bpb3zmpnsn9gkypbhnjlclchv98ssgc1h"))))
3a1f9a68
DT
2303 (build-system python-build-system)
2304 (inputs
2305 `(("python-setuptools" ,python-setuptools)))
2306 (arguments `(#:tests? #f)) ; no tests
2307 (home-page "http://python-requests.org/")
2308 (synopsis "Python CA certificate bundle")
2309 (description
2310 "Certifi is a Python library that contains a CA certificate bundle, which
2311is used by the Requests library to verify HTTPS requests.")
3f641af0 2312 (license license:asl2.0)))
3a1f9a68
DT
2313
2314(define-public python2-certifi
2315 (package-with-python2 python-certifi))
e6cfbd36 2316
12c270dd
RW
2317(define-public python-click
2318 (package
2319 (name "python-click")
43accb58 2320 (version "6.6")
12c270dd
RW
2321 (source
2322 (origin
2323 (method url-fetch)
375f224b 2324 (uri (pypi-uri "click" version))
12c270dd 2325 (sha256
43accb58
LF
2326 (base32
2327 "1sggipyz52crrybwbr9xvwxd4aqigvplf53k9w3ygxmzivd1jsnc"))))
12c270dd 2328 (build-system python-build-system)
e2ab5a09
BW
2329 (arguments
2330 `(#:phases
2331 (modify-phases %standard-phases
2332 (add-after 'unpack 'fix-paths
2333 (lambda* (#:key inputs #:allow-other-keys)
2334 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
2335 "cross-libc" "libc"))))
2336 (substitute* "click/_unicodefun.py"
2337 (("'locale'")
2338 (string-append "'" glibc "/bin/locale'"))))
2339 #t)))))
12c270dd
RW
2340 (native-inputs
2341 `(("python-setuptools" ,python-setuptools)))
2342 (home-page "http://click.pocoo.org")
2343 (synopsis "Command line library for Python")
2344 (description
2345 "Click is a Python package for creating command line interfaces in a
2346composable way with as little code as necessary. Its name stands for
2347\"Command Line Interface Creation Kit\". It's highly configurable but comes
2348with sensible defaults out of the box.")
3f641af0 2349 (license license:bsd-3)))
12c270dd
RW
2350
2351(define-public python2-click
2352 (package-with-python2 python-click))
2353
addc808d
EF
2354(define-public python-wheel
2355 (package
2356 (name "python-wheel")
40981b5c 2357 (version "0.29.0")
e1ba0749
EF
2358 (source
2359 (origin
2360 (method url-fetch)
2361 (uri (pypi-uri "wheel" version))
2362 (sha256
2363 (base32
40981b5c 2364 "0j0n38hg1jvrmyy68f9ikvzq1gs9g0sx4ws7maf8wi3bwbbqmfqy"))))
e1ba0749
EF
2365 (build-system python-build-system)
2366 (native-inputs
2367 `(("python-setuptools" ,python-setuptools)
2368 ("python-jsonschema" ,python-jsonschema)
2369 ("python-pytest-cov" ,python-pytest-cov)))
2370 (home-page "https://bitbucket.org/pypa/wheel/")
2371 (synopsis "Format for built Python packages")
2372 (description
2373 "A wheel is a ZIP-format archive with a specially formatted filename and
2374the @code{.whl} extension. It is designed to contain all the files for a PEP
2375376 compatible install in a way that is very close to the on-disk format. Many
2376packages will be properly installed with only the @code{Unpack} step and the
2377unpacked archive preserves enough information to @code{Spread} (copy data and
2378scripts to their final locations) at any later time. Wheel files can be
2379installed with a newer @code{pip} or with wheel's own command line utility.")
8ad4ae20
LF
2380 (license license:expat)
2381 (properties `((python2-variant . ,(delay python2-wheel))))))
addc808d
EF
2382
2383(define-public python2-wheel
8ad4ae20
LF
2384 (let ((wheel (package-with-python2
2385 (strip-python2-variant python-wheel))))
264ae686 2386 (package (inherit wheel)
8ad4ae20
LF
2387 (native-inputs `(("python2-functools32" ,python2-functools32)
2388 ,@(package-native-inputs wheel))))))
2389
addc808d 2390
ae641128 2391(define-public python-requests
e6cfbd36 2392 (package
ae641128 2393 (name "python-requests")
74a066f9 2394 (version "2.9.1")
e6cfbd36
DT
2395 (source (origin
2396 (method url-fetch)
5d691657 2397 (uri (pypi-uri "requests" version))
e6cfbd36
DT
2398 (sha256
2399 (base32
74a066f9 2400 "0zsqrzlybf25xscgi7ja4s48y2abf9wvjkn47wh984qgs1fq2xy5"))))
e6cfbd36 2401 (build-system python-build-system)
5d691657 2402 (native-inputs
6a308947
EF
2403 `(("python-setuptools" ,python-setuptools)
2404 ("python-py" ,python-py)
5d691657
EF
2405 ("python-pytest" ,python-pytest)
2406 ("python-pytest-cov" ,python-pytest-cov)
2407 ("python-wheel" ,python-wheel)))
e6cfbd36
DT
2408 (home-page "http://python-requests.org/")
2409 (synopsis "Python HTTP library")
2410 (description
2411 "Requests is a Python HTTP client library. It aims to be easier to use
2412than Python’s urllib2 library.")
3f641af0 2413 (license license:asl2.0)))
864b5211 2414
e9005180
DT
2415;; Some software requires an older version of Requests, notably Docker
2416;; Compose.
2417(define-public python-requests-2.7
2418 (package (inherit python-requests)
2419 (version "2.7.0")
2420 (source (origin
2421 (method url-fetch)
2422 (uri (pypi-uri "requests" version))
2423 (sha256
2424 (base32
2425 "0gdr9dxm24amxpbyqpbh3lbwxc2i42hnqv50sigx568qssv3v2ir"))))))
2426
ae641128 2427(define-public python2-requests
8ad4ae20 2428 (package-with-python2 python-requests))
ae641128 2429
ea521b42
DT
2430(define-public python-vcversioner
2431 (package
2432 (name "python-vcversioner")
2433 (version "2.14.0.0")
2434 (source
2435 (origin
2436 (method url-fetch)
2437 (uri (pypi-uri "vcversioner" version))
2438 (sha256
2439 (base32
2440 "11ivq1bm7v0yb4nsfbv9m7g7lyjn112gbvpjnjz8nv1fx633dm5c"))))
2441 (build-system python-build-system)
2442 (inputs
2443 `(("python-setuptools" ,python-setuptools)))
2444 (synopsis "Python library for version number discovery")
2445 (description "Vcversioner is a Python library that inspects tagging
2446information in a variety of version control systems in order to discover
2447version numbers.")
2448 (home-page "https://github.com/habnabit/vcversioner")
3f641af0 2449 (license license:isc)))
ea521b42
DT
2450
2451(define-public python2-vcversioner
2452 (package-with-python2 python-vcversioner))
ae641128 2453
864b5211
DT
2454(define-public python-jsonschema
2455 (package
2456 (name "python-jsonschema")
b3667afb 2457 (version "2.5.1")
864b5211
DT
2458 (source (origin
2459 (method url-fetch)
2460 (uri
2461 (string-append
2462 "https://pypi.python.org/packages/source/j/jsonschema/jsonschema-"
2463 version ".tar.gz"))
2464 (sha256
2465 (base32
b3667afb 2466 "0hddbqjm4jq63y8jf44nswina1crjs16l9snb6m3vvgyg31klrrn"))))
864b5211
DT
2467 (build-system python-build-system)
2468 (inputs
b3667afb
DT
2469 `(("python-setuptools" ,python-setuptools)
2470 ("python-vcversioner" ,python-vcversioner)))
864b5211
DT
2471 (home-page "http://github.com/Julian/jsonschema")
2472 (synopsis "Implementation of JSON Schema for Python")
2473 (description
2474 "Jsonschema is an implementation of JSON Schema for Python.")
a14600ec
LF
2475 (license license:expat)
2476 (properties `((python2-variant . ,(delay python2-jsonschema))))))
864b5211
DT
2477
2478(define-public python2-jsonschema
a14600ec
LF
2479 (let ((jsonschema (package-with-python2
2480 (strip-python2-variant python-jsonschema))))
264ae686
EF
2481 (package (inherit jsonschema)
2482 (inputs
2483 `(("python2-functools32" ,python2-functools32)
2484 ,@(package-inputs jsonschema))))))
850189b8
DT
2485
2486(define-public python-unidecode
2487 (package
2488 (name "python-unidecode")
8925d4f3 2489 (version "0.04.18")
850189b8
DT
2490 (source (origin
2491 (method url-fetch)
8925d4f3 2492 (uri (pypi-uri "Unidecode" version))
850189b8
DT
2493 (sha256
2494 (base32
8925d4f3 2495 "12hhblqy1ajvidm38im4171x4arg83pfmziyn53nizp29p3m14gi"))))
850189b8
DT
2496 (build-system python-build-system)
2497 (inputs
2498 `(("python-setuptools" ,python-setuptools)))
2499 (home-page "https://pypi.python.org/pypi/Unidecode")
2500 (synopsis "ASCII transliterations of Unicode text")
2501 (description
2502 "Unidecode provides ASCII transliterations of Unicode text. Unidecode is
2503useful when integrating with legacy code that doesn't support Unicode, or for
2504ease of entry of non-Roman names on a US keyboard, or when constructing ASCII
2505machine identifiers from human-readable Unicode strings that should still be
2506somewhat intelligeble.")
3f641af0 2507 (license license:gpl2+)))
850189b8
DT
2508
2509(define-public python2-unidecode
2510 (package-with-python2 python-unidecode))
6d45fef4
DT
2511
2512(define-public python-pyjwt
2513 (package
2514 (name "python-pyjwt")
eb31d4b4 2515 (version "1.4.0")
6d45fef4
DT
2516 (source
2517 (origin
2518 (method url-fetch)
eb31d4b4 2519 (uri (pypi-uri "PyJWT" version))
6d45fef4
DT
2520 (sha256
2521 (base32
eb31d4b4 2522 "1556v2jppd8mjkkj66pxb5rcazm35jq81r233mdl8hfmz9n3icp1"))))
6d45fef4 2523 (build-system python-build-system)
eb31d4b4
EF
2524 (native-inputs
2525 `(("python-setuptools" ,python-setuptools)
2526 ("python-pytest-runner" ,python-pytest-runner)))
6d45fef4
DT
2527 (arguments
2528 '(#:tests? #f)) ; test suite doesn't work
2529 (home-page "http://github.com/progrium/pyjwt")
2530 (synopsis "JSON Web Token implementation in Python")
2531 (description
2532 "PyJWT is a JSON Web Token implementation written in Python.")
bd3fa666 2533 (license license:expat)))
6d45fef4
DT
2534
2535(define-public python2-pyjwt
2536 (package-with-python2 python-pyjwt))
2537
2cec1f6f
DT
2538(define-public python-oauthlib
2539 (package
2540 (name "python-oauthlib")
bde2171d 2541 (version "1.0.3")
2cec1f6f
DT
2542 (source (origin
2543 (method url-fetch)
bde2171d 2544 (uri (pypi-uri "oauthlib" version))
2cec1f6f
DT
2545 (sha256
2546 (base32
bde2171d 2547 "1bfrj70vdjxjw74khbyh6f0dksv7p5rh2346jnlrffyacd3gwjzg"))))
2cec1f6f 2548 (build-system python-build-system)
bde2171d 2549 (native-inputs
59f151ec 2550 `(("python-coverage" ,python-coverage)
2cec1f6f
DT
2551 ("python-nose" ,python-nose)
2552 ("python-mock" ,python-mock)))
bde2171d
EF
2553 (inputs
2554 `(("python-blinker" ,python-blinker)
2555 ("python-cryptography" ,python-cryptography)
2556 ("python-pyjwt" ,python-pyjwt)))
2cec1f6f
DT
2557 (home-page "https://github.com/idan/oauthlib")
2558 (synopsis "OAuth implementation for Python")
2559 (description
2560 "Oauthlib is a generic, spec-compliant, thorough implementation of the
2561OAuth request-signing logic.")
3f641af0 2562 (license license:bsd-3)
59f151ec 2563 (properties `((python2-variant . ,(delay python2-oauthlib))))))
2cec1f6f
DT
2564
2565(define-public python2-oauthlib
59f151ec 2566 (let ((base (package-with-python2 (strip-python2-variant python-oauthlib))))
2cec1f6f
DT
2567 (package
2568 (inherit base)
59f151ec
EF
2569 (native-inputs `(("python2-setuptools" ,python2-setuptools)
2570 ("python2-unittest2" ,python2-unittest2)
2571 ,@(package-native-inputs base))))))
ec5dbb5c
DT
2572
2573(define-public python-itsdangerous
2574 (package
2575 (name "python-itsdangerous")
2576 (version "0.24")
2577 (source
2578 (origin
2579 (method url-fetch)
2580 (uri (string-append
2581 "https://pypi.python.org/packages/source/i/itsdangerous/itsdangerous-"
2582 version ".tar.gz"))
2583 (sha256
2584 (base32
2585 "06856q6x675ly542ig0plbqcyab6ksfzijlyf1hzhgg3sgwgrcyb"))))
2586 (build-system python-build-system)
ec5dbb5c
DT
2587 (home-page "http://github.com/mitsuhiko/itsdangerous")
2588 (synopsis "Python library for passing data to/from untrusted environments")
2589 (description
2590 "Itsdangerous provides various helpers to pass trusted data to untrusted
2591environments and back.")
3f641af0 2592 (license license:bsd-3)
194d0d98 2593 (properties `((python2-variant . ,(delay python2-itsdangerous))))))
ec5dbb5c
DT
2594
2595(define-public python2-itsdangerous
194d0d98
EF
2596 (let ((base (package-with-python2
2597 (strip-python2-variant python-itsdangerous))))
2598 (package
2599 (inherit base)
2600 (native-inputs `(("python2-setuptools" ,python2-setuptools)
2601 ,@(package-native-inputs base))))))
5731cae3 2602
8d12be1e
RW
2603(define-public python-pyyaml
2604 (package
2605 (name "python-pyyaml")
2606 (version "3.11")
2607 (source
2608 (origin
2609 (method url-fetch)
2610 (uri (string-append
2611 "https://pypi.python.org/packages/source/P/PyYAML/PyYAML-"
2612 version ".tar.gz"))
2613 (sha256
2614 (base32
2615 "1s26125vfnskng58ym37xhwv8v0mm95b2cwbjfag8prfhy596v63"))))
2616 (build-system python-build-system)
2617 (inputs
2618 `(("libyaml" ,libyaml)))
2619 (native-inputs
2620 `(("python-setuptools" ,python-setuptools)))
2621 (home-page "http://pyyaml.org/wiki/PyYAML")
2622 (synopsis "YAML parser and emitter for Python")
2623 (description
2624 "PyYAML is a YAML parser and emitter for Python. PyYAML features a
2625complete YAML 1.1 parser, Unicode support, pickle support, capable extension
2626API, and sensible error messages. PyYAML supports standard YAML tags and
2627provides Python-specific tags that allow to represent an arbitrary Python
2628object.")
2629 (license license:expat)))
2630
2631(define-public python2-pyyaml
2632 (package-with-python2 python-pyyaml))
2633
5731cae3
DT
2634(define-public python-virtualenv
2635 (package
2636 (name "python-virtualenv")
58d04dba 2637 (version "15.0.3")
5731cae3
DT
2638 (source
2639 (origin
2640 (method url-fetch)
17804240 2641 (uri (pypi-uri "virtualenv" version))
5731cae3
DT
2642 (sha256
2643 (base32
58d04dba 2644 "07cbajzk8l05k5zhlw0b9wbf2is65bl9v6zrn2a0iyn57w6pd73d"))))
5731cae3 2645 (build-system python-build-system)
17804240
EF
2646 (arguments
2647 `(#:phases
2648 (modify-phases %standard-phases
58d04dba
RW
2649 (replace 'check
2650 (lambda _
2651 ;; Disable failing test. See upstream bug report
2652 ;; https://github.com/pypa/virtualenv/issues/957
2653 (substitute* "tests/test_virtualenv.py"
2654 (("skipif.*") "skipif(True, reason=\"Guix\")\n"))
2655 (zero? (system* "py.test")))))))
5731cae3
DT
2656 (inputs
2657 `(("python-setuptools" ,python-setuptools)
2658 ("python-mock" ,python-mock)
17804240 2659 ("python-pytest" ,python-pytest)))
5731cae3
DT
2660 (home-page "https://virtualenv.pypa.io/")
2661 (synopsis "Virtual Python environment builder")
2662 (description
2663 "Virtualenv is a tool to create isolated Python environments.")
bd3fa666 2664 (license license:expat)))
5731cae3
DT
2665
2666(define-public python2-virtualenv
2667 (package-with-python2 python-virtualenv))
8176d4d5
DT
2668
2669(define-public python-markupsafe
2670 (package
2671 (name "python-markupsafe")
2672 (version "0.23")
2673 (source
2674 (origin
2675 (method url-fetch)
2676 (uri (string-append
2677 "https://pypi.python.org/packages/source/M/MarkupSafe/MarkupSafe-"
2678 version ".tar.gz"))
2679 (sha256
2680 (base32
2681 "1hvip33wva3fnmvfp9x5klqri7hpl1hkgqmjbss18nmrb7zimv54"))))
2682 (build-system python-build-system)
2683 (inputs
2684 `(("python-setuptools" ,python-setuptools)))
2685 (home-page "http://github.com/mitsuhiko/markupsafe")
2686 (synopsis "XML/HTML/XHTML markup safe string implementation for Python")
2687 (description
2688 "Markupsafe provides an XML/HTML/XHTML markup safe string implementation
2689for Python.")
3f641af0 2690 (license license:bsd-3)))
8176d4d5
DT
2691
2692(define-public python2-markupsafe
2693 (package-with-python2 python-markupsafe))
fe34f0d1
DT
2694
2695(define-public python-jinja2
2696 (package
2697 (name "python-jinja2")
e98149b3 2698 (version "2.8")
fe34f0d1
DT
2699 (source
2700 (origin
2701 (method url-fetch)
e98149b3 2702 (uri (pypi-uri "Jinja2" version))
fe34f0d1
DT
2703 (sha256
2704 (base32
e98149b3 2705 "1x0v41lp5m1pjix3l46zx02b7lqp2hflgpnxwkywxynvi3zz47xw"))))
fe34f0d1
DT
2706 (build-system python-build-system)
2707 (inputs
2708 `(("python-setuptools" ,python-setuptools)
2709 ("python-markupsafe" ,python-markupsafe)))
2710 (home-page "http://jinja.pocoo.org/")
2711 (synopsis "Python template engine")
2712 (description
2713 "Jinja2 is a small but fast and easy to use stand-alone template engine
2714written in pure Python.")
3f641af0 2715 (license license:bsd-3)))
fe34f0d1
DT
2716
2717(define-public python2-jinja2
2718 (package-with-python2 python-jinja2))
3580ab8b 2719
f7d17ac7
EE
2720(define-public python-pystache
2721 (package
2722 (name "python-pystache")
2723 (version "0.5.4")
2724 (source (origin
2725 (method url-fetch)
2726 (uri (pypi-uri "pystache" version))
2727 (sha256
2728 (base32
2729 "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp"))))
2730 (build-system python-build-system)
2731 (native-inputs
2732 `(("python-setuptools" ,python-setuptools)))
2733 (home-page "http://defunkt.io/pystache/")
2734 (synopsis "Python logic-less template engine")
2735 (description
2736 "Pystache is a Python implementation of the framework agnostic,
2737logic-free templating system Mustache.")
2738 (license license:expat)))
2739
2740(define-public python2-pystache
2741 (package-with-python2 python-pystache))
2742
1285119b
RW
2743(define-public python-joblib
2744 (package
2745 (name "python-joblib")
2746 (version "0.9.0b4")
2747 (source (origin
2748 (method url-fetch)
2749 (uri (string-append "https://pypi.python.org/packages/source/"
2750 "j/joblib/joblib-" version ".tar.gz"))
2751 (sha256
2752 (base32
2753 "1dvw3f8jgj6h0fxkghbgyclvdzc7l0ig7n0vis70awb5kczb9bs3"))))
2754 (build-system python-build-system)
2755 (native-inputs
2756 `(("python-setuptools" ,python-setuptools)
2757 ("python-nose" ,python-nose)))
2758 (home-page "http://pythonhosted.org/joblib/")
2759 (synopsis "Using Python functions as pipeline jobs")
2760 (description
2761 "Joblib is a set of tools to provide lightweight pipelining in Python.
2762In particular, joblib offers: transparent disk-caching of the output values
2763and lazy re-evaluation (memoize pattern), easy simple parallel computing
2764logging and tracing of the execution.")
3f641af0 2765 (license license:bsd-3)))
1285119b
RW
2766
2767(define-public python2-joblib
2768 (package-with-python2 python-joblib))
2769
3580ab8b
DT
2770(define-public python-docutils
2771 (package
2772 (name "python-docutils")
2773 (version "0.12")
2774 (source
2775 (origin
2776 (method url-fetch)
2777 (uri (string-append
2778 "https://pypi.python.org/packages/source/d/docutils/docutils-"
2779 version ".tar.gz"))
2780 (sha256
2781 (base32
2782 "1ylnjnw1x4b2y7blr6x35ncdzn69k253kw4cdkv6asdb21w73ny7"))))
2783 (build-system python-build-system)
2784 (inputs
2785 `(("python-setuptools" ,python-setuptools)))
2786 (arguments
2787 '(#:tests? #f)) ; no setup.py test command
2788 (home-page "http://docutils.sourceforge.net/")
2789 (synopsis "Python Documentation Utilities")
2790 (description
2791 "Docutils is a modular system for processing documentation into useful
2792formats, such as HTML, XML, and LaTeX. For input Docutils supports
2793reStructuredText.")
2794 ;; Most of the source code is public domain, but some source files are
2795 ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses.
3f641af0 2796 (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+))))
3580ab8b
DT
2797
2798(define-public python2-docutils
2799 (package-with-python2 python-docutils))
fb35b7c0
DT
2800
2801(define-public python-pygments
2802 (package
2803 (name "python-pygments")
9f442285 2804 (version "2.0.2")
fb35b7c0
DT
2805 (source
2806 (origin
2807 (method url-fetch)
9f442285 2808 (uri (pypi-uri "Pygments" version))
fb35b7c0
DT
2809 (sha256
2810 (base32
9f442285 2811 "0lagrwifsgn0s8bzqahpr87p7gd38xja8f06akscinp6hj89283k"))))
fb35b7c0
DT
2812 (build-system python-build-system)
2813 (inputs
2814 `(("python-setuptools" ,python-setuptools)))
2815 (home-page "http://pygments.org/")
2816 (synopsis "Syntax highlighting")
2817 (description
2818 "Pygments is a syntax highlighting package written in Python.")
3f641af0 2819 (license license:bsd-2)))
fb35b7c0
DT
2820
2821(define-public python2-pygments
2822 (package-with-python2 python-pygments))
9dd6078d
DT
2823
2824(define-public python-sphinx
2825 (package
2826 (name "python-sphinx")
2827 (version "1.2.3")
2828 (source
2829 (origin
2830 (method url-fetch)
2831 (uri (string-append
2832 "https://pypi.python.org/packages/source/S/Sphinx/Sphinx-"
2833 version ".tar.gz"))
2834 (sha256
2835 (base32
2836 "011xizm3jnmf4cvs5i6kgf6c5nn046h79i8j0vd0f27yw9j3p4wl"))))
2837 (build-system python-build-system)
2838 (inputs
2839 `(("python-setuptools" ,python-setuptools)
2840 ("python-jinja2" ,python-jinja2)
2841 ("python-docutils" ,python-docutils)
2842 ("python-pygments" ,python-pygments)))
2843 (home-page "http://sphinx-doc.org/")
2844 (synopsis "Python documentation generator")
2845 (description "Sphinx is a tool that makes it easy to create documentation
2846for Python projects or other documents consisting of multiple reStructuredText
2847sources.")
3f641af0 2848 (license license:bsd-3)))
9dd6078d
DT
2849
2850(define-public python2-sphinx
2851 (package-with-python2 python-sphinx))
6888830b 2852
ad320b20
RW
2853(define-public python-sphinx-rtd-theme
2854 (package
2855 (name "python-sphinx-rtd-theme")
2856 (version "0.1.6")
2857 (source
2858 (origin
2859 (method url-fetch)
2860 (uri (string-append "https://pypi.python.org/packages/source/s/"
2861 "sphinx_rtd_theme/sphinx_rtd_theme-"
2862 version ".tar.gz"))
2863 (sha256
2864 (base32
2865 "19nw3rn7awplcdrz63kg1njqwkbymfg9lwn7l2grhdyhyr2gaa8g"))))
2866 (build-system python-build-system)
2867 (arguments
2868 `(;; With standard flags, the install phase attempts to create a zip'd
2869 ;; egg file, and fails with an error: 'ZIP does not support timestamps
2870 ;; before 1980'
2871 #:configure-flags '("--single-version-externally-managed"
2872 "--record=sphinx-rtd-theme.txt")))
2873 (native-inputs
2874 `(("python-setuptools" ,python-setuptools)))
2875 (inputs
2876 `(("python-docutils" ,python-docutils)
2877 ("python-sphinx" ,python-sphinx)))
2878 (home-page "https://github.com/snide/sphinx_rtd_theme/")
2879 (synopsis "ReadTheDocs.org theme for Sphinx")
2880 (description "A theme for Sphinx used by ReadTheDocs.org.")
bd3fa666 2881 (license license:expat)))
ad320b20
RW
2882
2883(define-public python2-sphinx-rtd-theme
2884 (package-with-python2 python-sphinx-rtd-theme))
2885
f4de5b3b
CAW
2886(define-public python-feedgenerator
2887 (package
2888 (name "python-feedgenerator")
f0412aa2 2889 (version "1.8")
f4de5b3b 2890 (source
f4de5b3b 2891 (origin
f0412aa2
EF
2892 (method url-fetch)
2893 (uri (pypi-uri "feedgenerator" version))
f4de5b3b
CAW
2894 (sha256
2895 (base32
f0412aa2 2896 "0mkimp1fpdan4p3882vzcws4l594k71ich4g0wq97jbra7p602n0"))))
f4de5b3b 2897 (build-system python-build-system)
f0412aa2 2898 (native-inputs
f4de5b3b
CAW
2899 `(("python-setuptools" ,python-setuptools)
2900 ("python-pytz" ,python-pytz)
2901 ("python-six" ,python-six)))
f0412aa2 2902 (home-page "https://github.com/getpelican/feedgenerator")
f4de5b3b
CAW
2903 (synopsis
2904 "Standalone version of Django's Atom/RSS feed generator")
2905 (description
2906 "Feedgenerator-py3k is a standalone version of Django's feedgenerator,
2907which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.")
3f641af0 2908 (license license:bsd-3)))
f4de5b3b
CAW
2909
2910(define-public python2-feedgenerator
2911 (package-with-python2 python-feedgenerator))
2912
59ad30e3
CAW
2913(define-public python-blinker
2914 (package
2915 (name "python-blinker")
7fb9ff4d 2916 (version "1.4")
59ad30e3
CAW
2917 (source
2918 (origin
2919 (method url-fetch)
7fb9ff4d 2920 (uri (pypi-uri "blinker" version))
59ad30e3
CAW
2921 (sha256
2922 (base32
7fb9ff4d 2923 "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7"))))
59ad30e3
CAW
2924 (build-system python-build-system)
2925 (native-inputs
2926 `(("python-setuptools" ,python-setuptools)))
2927 ;; No "test" command supplied to setuptools, so unless there's another way
2928 ;; to run tests, we're skipping them!
2929 (arguments '(#:tests? #f))
2930 (home-page "http://pythonhosted.org/blinker/")
2931 (synopsis "Fast, simple object-to-object and broadcast signaling")
2932 (description
2933 "Blinker provides a fast dispatching system that allows any number of
2934interested parties to subscribe to events, or \"signals\".")
2935 (license license:expat)))
2936
2937(define-public python2-blinker
2938 (package-with-python2 python-blinker))
2939
b8050e71
CAW
2940(define-public pelican
2941 (package
2942 (name "pelican")
11f97c27 2943 (version "3.6.3")
b8050e71
CAW
2944 (source
2945 (origin
2946 (method url-fetch)
11f97c27 2947 (uri (pypi-uri "pelican" version))
b8050e71
CAW
2948 (sha256
2949 (base32
11f97c27 2950 "1hn94rb4q3zmcq16in055xikal4dba5hfx3zznq7warllcgc9f8k"))))
b8050e71 2951 (build-system python-build-system)
d9f2dece 2952 (inputs
b8050e71
CAW
2953 `(("python-feedgenerator" ,python-feedgenerator)
2954 ("python-jinja2" ,python-jinja2)
2955 ("python-pygments" ,python-pygments)
2956 ("python-docutils" ,python-docutils)
2957 ("python-pytz" ,python-pytz)
2958 ("python-blinker" ,python-blinker)
2959 ("python-unidecode" ,python-unidecode)
2960 ("python-six" ,python-six)
2961 ("python-dateutil-2" ,python-dateutil-2)))
2962 (home-page "http://getpelican.com/")
2963 (arguments
2964 `(;; XXX Requires a lot more packages to do unit tests :P
2965 #:tests? #f
2966 #:phases (modify-phases %standard-phases
2967 (add-before
2968 'install 'adjust-requires
2969 ;; Since feedgenerator is installed from git, it doesn't
2970 ;; conform to the version requirements.
2971 ;;
2972 ;; We *do have* "feedgenerator >= 1.6", but strip off the
2973 ;; version requirement so setuptools doesn't get confused.
2974 (lambda _
2975 (substitute* "setup.py"
2976 (("['\"]feedgenerator.*?['\"]")
2977 "'feedgenerator'")))))))
2978 (synopsis "Python-based static site publishing system")
2979 (description
2980 "Pelican is a tool to generate a static blog from reStructuredText,
2981Markdown input files, and more. Pelican uses Jinja2 for templating
2982and is very extensible.")
3f641af0 2983 (license license:agpl3+)))
b8050e71 2984
240ca4aa
RW
2985(define-public python-scikit-learn
2986 (package
2987 (name "python-scikit-learn")
be0a4c26 2988 (version "0.16.1")
240ca4aa
RW
2989 (source
2990 (origin
2991 (method url-fetch)
2992 (uri (string-append
2993 "https://github.com/scikit-learn/scikit-learn/archive/"
2994 version ".tar.gz"))
7e21b9fb 2995 (file-name (string-append name "-" version ".tar.gz"))
240ca4aa
RW
2996 (sha256
2997 (base32
be0a4c26 2998 "140skabifgc7lvvj873pnzlwx0ni6q8qkrsyad2ccjb3h8rxzkih"))))
240ca4aa
RW
2999 (build-system python-build-system)
3000 (arguments
3001 `(#:phases
3002 (alist-cons-before
2f6b3d2e
RW
3003 'check 'set-HOME
3004 ;; some tests require access to "$HOME"
3005 (lambda _ (setenv "HOME" "/tmp"))
3006 ;; Tests can only be run after the library has been installed and not
3007 ;; within the source directory.
3008 (alist-cons-after
3009 'install 'check
3010 (lambda _
3011 (with-directory-excursion "/tmp"
3012 ;; With Python 3 one test of 3334 fails
3013 ;; (sklearn.tests.test_common.test_transformers); see
3014 ;; https://github.com/scikit-learn/scikit-learn/issues/3693
3015 (system* "nosetests" "-v" "sklearn")))
3016 (alist-delete 'check %standard-phases)))))
240ca4aa 3017 (inputs
2f6b3d2e 3018 `(("openblas" ,openblas)
240ca4aa
RW
3019 ("python-nose" ,python-nose)))
3020 (propagated-inputs
3021 `(("python-numpy" ,python-numpy)
3022 ("python-scipy" ,python-scipy)))
3023 (home-page "http://scikit-learn.org/")
3024 (synopsis "Machine Learning in Python")
3025 (description
3026 "Scikit-learn provides simple and efficient tools for data
3027mining and data analysis.")
25a2f81f
EF
3028 (license license:bsd-3)
3029 (properties `((python2-variant . ,(delay python2-scikit-learn))))))
240ca4aa
RW
3030
3031(define-public python2-scikit-learn
25a2f81f 3032 (package-with-python2 (strip-python2-variant python-scikit-learn)))
240ca4aa 3033
12f8f9bb
RW
3034(define-public python-scikit-image
3035 (package
3036 (name "python-scikit-image")
3037 (version "0.11.3")
3038 (source
3039 (origin
3040 (method url-fetch)
3041 (uri (string-append
3042 "https://pypi.python.org/packages/source/s/scikit-image/scikit-image-"
3043 version ".tar.gz"))
3044 (sha256
3045 (base32 "0jz416fqvpahqyffw8plmszzfj669w8wvf3y9clnr5lr6a7md3kn"))))
3046 (build-system python-build-system)
3047 (propagated-inputs
3048 `(("python-matplotlib" ,python-matplotlib)
3049 ("python-networkx" ,python-networkx)
3050 ("python-numpy" ,python-numpy)
3051 ("python-scipy" ,python-scipy)
3052 ("python-six" ,python-six)
3053 ("python-pillow" ,python-pillow)))
3054 (native-inputs
3055 `(("python-cython" ,python-cython)
3056 ("python-setuptools" ,python-setuptools)))
3057 (home-page "http://scikit-image.org/")
3058 (synopsis "Image processing in Python")
3059 (description
e881752c 3060 "Scikit-image is a collection of algorithms for image processing.")
2b031d3f
EF
3061 (license license:bsd-3)
3062 (properties `((python2-variant . ,(delay python2-scikit-image))))))
12f8f9bb
RW
3063
3064(define-public python2-scikit-image
2b031d3f
EF
3065 (let ((scikit-image (package-with-python2
3066 (strip-python2-variant python-scikit-image))))
12f8f9bb
RW
3067 (package (inherit scikit-image)
3068 (native-inputs
3069 `(("python2-mock" ,python2-mock)
3070 ,@(package-native-inputs scikit-image)))
3071 (propagated-inputs
3072 `(("python2-pytz" ,python2-pytz)
2b031d3f 3073 ,@(package-propagated-inputs scikit-image))))))
12f8f9bb 3074
5394a6a6
RW
3075(define-public python-redis
3076 (package
3077 (name "python-redis")
3078 (version "2.10.3")
3079 (source
3080 (origin
3081 (method url-fetch)
3082 (uri (string-append
3083 "https://pypi.python.org/packages/source/r/redis/redis-"
3084 version ".tar.gz"))
3085 (sha256
3086 (base32 "1701qjwn4n05q90fdg4bsg96s27xf5s4hsb4gxhv3xk052q3gyx4"))))
3087 (build-system python-build-system)
3088 ;; Tests require a running Redis server
3089 (arguments '(#:tests? #f))
3090 (native-inputs
3091 `(("python-setuptools" ,python-setuptools)
3092 ("python-pytest" ,python-pytest)))
3093 (home-page "https://github.com/andymccurdy/redis-py")
3094 (synopsis "Redis Python client")
3095 (description
3096 "This package provides a Python interface to the Redis key-value store.")
3097 (license license:expat)))
3098
3099(define-public python2-redis
3100 (package-with-python2 python-redis))
3101
748cef5b
RW
3102(define-public python-rq
3103 (package
3104 (name "python-rq")
3105 (version "0.5.2")
3106 (source
3107 (origin
3108 (method url-fetch)
3109 (uri (string-append
3110 "https://pypi.python.org/packages/source/r/rq/rq-"
3111 version ".tar.gz"))
3112 (sha256
3113 (base32 "0b0z5hn8wkfg300hx7816csgv3bcfamlr29fi3yzgqmpqxwj3fix"))))
3114 (build-system python-build-system)
3115 (propagated-inputs
3116 `(("python-click" ,python-click)
3117 ("python-redis" ,python-redis)))
3118 (native-inputs
3119 `(("python-setuptools" ,python-setuptools)))
3120 (home-page "http://python-rq.org/")
3121 (synopsis "Simple job queues for Python")
3122 (description
3123 "RQ (Redis Queue) is a simple Python library for queueing jobs and
3124processing them in the background with workers. It is backed by Redis and it
3125is designed to have a low barrier to entry.")
3f641af0 3126 (license license:bsd-2)))
748cef5b
RW
3127
3128(define-public python2-rq
3129 (package-with-python2 python-rq))
3130
6888830b
FB
3131(define-public python-cython
3132 (package
3133 (name "python-cython")
dd22efef 3134 (version "0.24.1")
6888830b
FB
3135 (source
3136 (origin
3137 (method url-fetch)
56918e26 3138 (uri (pypi-uri "Cython" version))
6888830b
FB
3139 (sha256
3140 (base32
dd22efef 3141 "1fg7fmpvfcq9md4ncyqnnylyjy4z3ksdrshzis95g1sh03d8z044"))))
6888830b
FB
3142 (build-system python-build-system)
3143 ;; we need the full python package and not just the python-wrapper
3144 ;; because we need libpython3.3m.so
3145 (inputs
3146 `(("python" ,python)))
3147 (arguments
3148 `(#:phases
b92f651b
EF
3149 (modify-phases %standard-phases
3150 (add-before 'check 'set-HOME
3151 ;; some tests require access to "$HOME/.cython"
3152 (lambda _ (setenv "HOME" "/tmp")))
3153 (replace 'check
3154 (lambda _ (zero? (system* "python" "runtests.py" "-vv")))))))
6888830b
FB
3155 (home-page "http://cython.org/")
3156 (synopsis "C extensions for Python")
3157 (description "Cython is an optimising static compiler for both the Python
3158programming language and the extended Cython programming language. It makes
3159writing C extensions for Python as easy as Python itself.")
3f641af0 3160 (license license:asl2.0)
48b311b1 3161 (properties `((python2-variant . ,(delay python2-cython))))))
6888830b
FB
3162
3163(define-public python2-cython
48b311b1
LC
3164 (package (inherit (package-with-python2
3165 (strip-python2-variant python-cython)))
6888830b
FB
3166 (name "python2-cython")
3167 (inputs
3168 `(("python-2" ,python-2))))) ; this is not automatically changed
0da98533
FB
3169
3170;; This version of numpy is missing the documentation and is only used to
3171;; build matplotlib which is required to build numpy's documentation.
3172(define python-numpy-bootstrap
3173 (package
3174 (name "python-numpy-bootstrap")
ef9b4c04 3175 (version "1.10.4")
0da98533
FB
3176 (source
3177 (origin
3178 (method url-fetch)
de67e922 3179 (uri (string-append "mirror://sourceforge/numpy/NumPy/" version
0da98533
FB
3180 "/numpy-" version ".tar.gz"))
3181 (sha256
3182 (base32
ef9b4c04 3183 "1bjjhvncraka5s6i4lg644jrxij6bvycxy7an20gcz3a0m11iygp"))))
0da98533
FB
3184 (build-system python-build-system)
3185 (inputs
3186 `(("python-nose" ,python-nose)
cba256f8
RW
3187 ("openblas" ,openblas)
3188 ("lapack" ,lapack)))
0da98533 3189 (native-inputs
19afbea1 3190 `(("gfortran" ,gfortran)))
0da98533
FB
3191 (arguments
3192 `(#:phases
3193 (alist-cons-before
3194 'build 'set-environment-variables
3195 (lambda* (#:key inputs #:allow-other-keys)
dbdfe515
RW
3196 (call-with-output-file "site.cfg"
3197 (lambda (port)
cba256f8
RW
3198 (format port
3199 "[openblas]
dbdfe515
RW
3200libraries = openblas
3201library_dirs = ~a/lib
3202include_dirs = ~a/include
cba256f8
RW
3203
3204[lapack]
3205lapack_libs = lapack
3206library_dirs = ~a/lib
3207include_dirs = ~a/include
3208"
3209 (assoc-ref inputs "openblas")
3210 (assoc-ref inputs "openblas")
3211 (assoc-ref inputs "lapack")
3212 (assoc-ref inputs "lapack"))))
dbdfe515
RW
3213 ;; Use "gcc" executable, not "cc".
3214 (substitute* "numpy/distutils/system_info.py"
3215 (("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
3216 "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')"))
3217 #t)
6a843168
FB
3218 ;; Tests can only be run after the library has been installed and not
3219 ;; within the source directory.
3220 (alist-cons-after
3221 'install 'check
89b5c60e 3222 (lambda _
6a843168 3223 (with-directory-excursion "/tmp"
89b5c60e 3224 (zero? (system* "python" "-c"
6a843168 3225 "import numpy; numpy.test(verbose=2)"))))
89b5c60e
AE
3226 (alist-delete
3227 'check
6a843168 3228 %standard-phases)))))
0da98533
FB
3229 (home-page "http://www.numpy.org/")
3230 (synopsis "Fundamental package for scientific computing with Python")
3231 (description "NumPy is the fundamental package for scientific computing
e881752c 3232with Python. It contains among other things: a powerful N-dimensional array
0da98533
FB
3233object, sophisticated (broadcasting) functions, tools for integrating C/C++
3234and Fortran code, useful linear algebra, Fourier transform, and random number
3235capabilities.")
3f641af0 3236 (license license:bsd-3)))
0da98533
FB
3237
3238(define python2-numpy-bootstrap
3239 (package-with-python2 python-numpy-bootstrap))
15bfe6d6 3240
3a1bfe18
RW
3241(define-public python2-fastlmm
3242 (package
3243 (name "python2-fastlmm")
b074e7d4 3244 (version "0.2.21")
3a1bfe18
RW
3245 (source
3246 (origin
3247 (method url-fetch)
b074e7d4 3248 (uri (pypi-uri "fastlmm" version ".zip"))
3a1bfe18
RW
3249 (sha256
3250 (base32
b074e7d4 3251 "1q8c34rpmwkfy3r4d5172pzdkpfryj561897z9r3x22gq7813x1m"))))
3a1bfe18
RW
3252 (build-system python-build-system)
3253 (arguments
3254 `(#:python ,python-2)) ; only Python 2.7 is supported
3255 (propagated-inputs
3256 `(("python2-numpy" ,python2-numpy)
3257 ("python2-scipy" ,python2-scipy)
3258 ("python2-matplotlib" ,python2-matplotlib)
3259 ("python2-pandas" ,python2-pandas)
3260 ("python2-scikit-learn" ,python2-scikit-learn)
3261 ("python2-cython" ,python2-cython)
3262 ("python2-pysnptools" ,python2-pysnptools)))
3263 (native-inputs
3264 `(("unzip" ,unzip)
3265 ("python2-mock" ,python2-mock)
3266 ("python2-setuptools" ,python2-setuptools)))
3267 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/fastlmm/")
3268 (synopsis "Perform genome-wide association studies on large data sets")
3269 (description
3270 "FaST-LMM, which stands for Factored Spectrally Transformed Linear Mixed
3271Models, is a program for performing both single-SNP and SNP-set genome-wide
3272association studies (GWAS) on extremely large data sets.")
3f641af0 3273 (license license:asl2.0)))
3a1bfe18 3274
2ee8869a
FB
3275(define-public python-numpy
3276 (package (inherit python-numpy-bootstrap)
3277 (name "python-numpy")
3278 (outputs '("out" "doc"))
89b5c60e 3279 (inputs
2ee8869a
FB
3280 `(("which" ,which)
3281 ("python-setuptools" ,python-setuptools)
3282 ("python-matplotlib" ,python-matplotlib)
3283 ("python-sphinx" ,python-sphinx)
3284 ("python-pyparsing" ,python-pyparsing)
3285 ("python-numpydoc" ,python-numpydoc)
3286 ,@(package-inputs python-numpy-bootstrap)))
3287 (native-inputs
3288 `(("pkg-config" ,pkg-config)
3289 ("texlive" ,texlive)
3290 ("texinfo" ,texinfo)
3291 ("perl" ,perl)
3292 ,@(package-native-inputs python-numpy-bootstrap)))
3293 (arguments
89b5c60e 3294 `(,@(substitute-keyword-arguments
2ee8869a
FB
3295 (package-arguments python-numpy-bootstrap)
3296 ((#:phases phases)
3297 `(alist-cons-after
3298 'install 'install-doc
3299 (lambda* (#:key outputs #:allow-other-keys)
3300 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
89b5c60e
AE
3301 (doc (string-append
3302 data "/doc/" ,name "-"
2ee8869a
FB
3303 ,(package-version python-numpy-bootstrap)))
3304 (info (string-append data "/info"))
3305 (html (string-append doc "/html"))
3306 (pyver ,(string-append "PYVER=")))
3307 (with-directory-excursion "doc"
3308 (mkdir-p html)
3309 (system* "make" "html" pyver)
3310 (system* "make" "latex" "PAPER=a4" pyver)
89b5c60e 3311 (system* "make" "-C" "build/latex"
2ee8869a
FB
3312 "all-pdf" "PAPER=a4" pyver)
3313 ;; FIXME: Generation of the info file fails.
3314 ;; (system* "make" "info" pyver)
3315 ;; (mkdir-p info)
3316 ;; (copy-file "build/texinfo/numpy.info"
3317 ;; (string-append info "/numpy.info"))
3318 (for-each (lambda (file)
3319 (copy-file (string-append "build/latex" file)
3320 (string-append doc file)))
3321 '("/numpy-ref.pdf" "/numpy-user.pdf"))
3322 (with-directory-excursion "build/html"
3323 (for-each (lambda (file)
3324 (let* ((dir (dirname file))
3325 (tgt-dir (string-append html "/" dir)))
3326 (unless (equal? "." dir)
3327 (mkdir-p tgt-dir))
96c46210 3328 (install-file file html)))
2ee8869a
FB
3329 (find-files "." ".*"))))))
3330 ,phases)))))))
3331
764c077b 3332(define-public python2-numpy
57b7b8cd 3333 (package-with-python2 python-numpy))
2ee8869a 3334
15bfe6d6
FB
3335(define-public python-pyparsing
3336 (package
3337 (name "python-pyparsing")
e0669289 3338 (version "2.0.3")
15bfe6d6
FB
3339 (source
3340 (origin
3341 (method url-fetch)
de67e922
LF
3342 (uri (string-append "mirror://sourceforge/pyparsing/pyparsing"
3343 "/pyparsing-" version
15bfe6d6
FB
3344 "/pyparsing-" version ".tar.gz"))
3345 (sha256
3346 (base32
e0669289 3347 "0kw4py7gn45j93q8r7bzajfrjdc3xlsn2yzln41lf9zmrghjkrq6"))))
15bfe6d6
FB
3348 (build-system python-build-system)
3349 (outputs '("out" "doc"))
3350 (arguments
3351 `(#:tests? #f ; no test target
3352 #:modules ((guix build python-build-system)
3353 (guix build utils))
3354 #:phases
3355 (alist-cons-after
3356 'install 'install-doc
3357 (lambda* (#:key outputs #:allow-other-keys)
89b5c60e 3358 (let* ((doc (string-append (assoc-ref outputs "doc")
15bfe6d6
FB
3359 "/share/doc/" ,name "-" ,version))
3360 (html-doc (string-append doc "/html"))
3361 (examples (string-append doc "/examples")))
3362 (mkdir-p html-doc)
3363 (mkdir-p examples)
89b5c60e 3364 (for-each
15bfe6d6 3365 (lambda (dir tgt)
89b5c60e 3366 (map (lambda (file)
96c46210 3367 (install-file file tgt))
15bfe6d6
FB
3368 (find-files dir ".*")))
3369 (list "docs" "htmldoc" "examples")
3370 (list doc html-doc examples))))
3371 %standard-phases)))
3372 (home-page "http://pyparsing.wikispaces.com")
3373 (synopsis "Python parsing class library")
3374 (description
3375 "The pyparsing module is an alternative approach to creating and
3376executing simple grammars, vs. the traditional lex/yacc approach, or the use
3377of regular expressions. The pyparsing module provides a library of classes
3378that client code uses to construct the grammar directly in Python code.")
bd3fa666 3379 (license license:expat)))
15bfe6d6
FB
3380
3381(define-public python2-pyparsing
3382 (package-with-python2 python-pyparsing))
3383
ec00de35
FB
3384(define-public python-numpydoc
3385 (package
3386 (name "python-numpydoc")
3387 (version "0.5")
3388 (source
3389 (origin
3390 (method url-fetch)
89b5c60e 3391 (uri (string-append
ec00de35
FB
3392 "https://pypi.python.org/packages/source/n/numpydoc/numpydoc-"
3393 version ".tar.gz"))
3394 (sha256
3395 (base32
5e4d8f67
AE
3396 "0d4dnifaxkll50jx6czj05y8cb4ny60njd2wz299sj2jxfy51w4k"))
3397 (modules '((guix build utils)))
3398 (snippet
3399 '(begin
3400 ;; Drop a test requiring matplotlib, which we cannot add as an
3401 ;; input since it would create a circular dependency: Extend the
3402 ;; test for Python 3, where it is already dropped, to Python 2.
3403 (substitute* "numpydoc/tests/test_plot_directive.py"
3404 (("3") "2"))))))
ec00de35
FB
3405 (build-system python-build-system)
3406 (inputs
3407 `(("python-setuptools" ,python-setuptools)
3408 ("python-docutils" ,python-docutils)
3409 ("python-sphinx" ,python-sphinx)
3410 ("python-nose" ,python-nose)))
3411 (home-page "https://pypi.python.org/pypi/numpydoc")
3412 (synopsis
3413 "Numpy's Sphinx extensions")
3414 (description
3415 "Sphinx extension to support docstrings in Numpy format.")
3f641af0 3416 (license license:bsd-2)))
ec00de35
FB
3417
3418(define-public python2-numpydoc
5e4d8f67 3419 (package-with-python2 python-numpydoc))
1c65314c 3420
1e656049
RW
3421(define-public python-numexpr
3422 (package
3423 (name "python-numexpr")
26112c0a 3424 (version "2.6.0")
1e656049
RW
3425 (source
3426 (origin
3427 (method url-fetch)
26112c0a 3428 (uri (pypi-uri "numexpr" version))
1e656049
RW
3429 (sha256
3430 (base32
26112c0a 3431 "0i6iagl2hhbr8q4qzbbjd859v5806vqylq87fq7pi914ps6d6cag"))))
1e656049
RW
3432 (build-system python-build-system)
3433 (arguments `(#:tests? #f)) ; no tests included
3434 (propagated-inputs
3435 `(("python-numpy" ,python-numpy)))
3436 (home-page "https://github.com/pydata/numexpr")
3437 (synopsis "Fast numerical expression evaluator for NumPy")
3438 (description
3439 "Numexpr is a fast numerical expression evaluator for NumPy. With it,
3440expressions that operate on arrays are accelerated and use less memory than
3441doing the same calculation in Python. In addition, its multi-threaded
3442capabilities can make use of all your cores, which may accelerate
3443computations, most specially if they are not memory-bounded (e.g. those using
3444transcendental functions).")
fc1a170e
EF
3445 (license license:expat)
3446 (properties `((python2-variant . ,(delay python2-numexpr))))))
1e656049
RW
3447
3448(define-public python2-numexpr
fc1a170e 3449 (package-with-python2 (strip-python2-variant python-numexpr)))
1e656049 3450
1c65314c
FB
3451(define-public python-matplotlib
3452 (package
3453 (name "python-matplotlib")
1bbc659f 3454 (version "1.4.3")
1c65314c
FB
3455 (source
3456 (origin
3457 (method url-fetch)
de67e922
LF
3458 (uri (string-append "mirror://sourceforge/matplotlib/matplotlib"
3459 "/matplotlib-" version
1c65314c
FB
3460 "/matplotlib-" version ".tar.gz"))
3461 (sha256
3462 (base32
1bbc659f 3463 "1dn05cvd0g984lzhh72wa0z93psgwshbbg93fkab6slx5m3l95av"))
fc1adab1 3464 (patches (search-patches "matplotlib-setupext-tk.patch"))))
1c65314c
FB
3465 (build-system python-build-system)
3466 (outputs '("out" "doc"))
25f9a068
FB
3467 (propagated-inputs ; the following packages are all needed at run time
3468 `(("python-pyparsing" ,python-pyparsing)
3469 ("python-pygobject" ,python-pygobject)
3470 ("gobject-introspection" ,gobject-introspection)
1bbc659f 3471 ("python-tkinter" ,python "tk")
25f9a068
FB
3472 ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated
3473 ;; from 'gtk+') provides the required 'typelib' files used by
3474 ;; 'gobject-introspection'. The location of these files is set with the
3475 ;; help of the environment variable GI_TYPELIB_PATH. At build time this
3476 ;; is done automatically by a 'native-search-path' procedure. However,
3477 ;; at run-time the user must set this variable as follows:
3478 ;;
3479 ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0
25f9a068
FB
3480 ("gtk+" ,gtk+)
3481 ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of
3482 ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context'
3483 ;; object. For this reason we need to import both libraries.
3484 ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo
3485 ("python-pycairo" ,python-pycairo)
3486 ("python-cairocffi" ,python-cairocffi)))
1c65314c
FB
3487 (inputs
3488 `(("python-setuptools" ,python-setuptools)
3489 ("python-dateutil" ,python-dateutil-2)
1c65314c
FB
3490 ("python-six" ,python-six)
3491 ("python-pytz" ,python-pytz)
3492 ("python-numpy" ,python-numpy-bootstrap)
3493 ("python-sphinx" ,python-sphinx)
3494 ("python-numpydoc" ,python-numpydoc)
3495 ("python-nose" ,python-nose)
3496 ("python-mock" ,python-mock)
3497 ("libpng" ,libpng)
3498 ("imagemagick" ,imagemagick)
3499 ("freetype" ,freetype)
25f9a068
FB
3500 ("cairo" ,cairo)
3501 ("glib" ,glib)
4e7a137a 3502 ("python-pillow" ,python-pillow)
1c65314c 3503 ;; FIXME: Add backends when available.
1c65314c
FB
3504 ;("python-wxpython" ,python-wxpython)
3505 ;("python-pyqt" ,python-pyqt)
1bbc659f
FB
3506 ("tcl" ,tcl)
3507 ("tk" ,tk)))
1c65314c
FB
3508 (native-inputs
3509 `(("pkg-config" ,pkg-config)
3510 ("texlive" ,texlive)
3511 ("texinfo" ,texinfo)))
3512 (arguments
3513 `(#:phases
25f9a068
FB
3514 (alist-cons-before
3515 'build 'configure-environment
3516 (lambda* (#:key outputs inputs #:allow-other-keys)
3517 (let ((cairo (assoc-ref inputs "cairo"))
3518 (gtk+ (assoc-ref inputs "gtk+")))
3519 ;; Setting these directories in the 'basedirlist' of 'setup.cfg'
3520 ;; has not effect.
25f9a068
FB
3521 (setenv "LD_LIBRARY_PATH"
3522 (string-append cairo "/lib:" gtk+ "/lib"))
3523 (setenv "HOME" (getcwd))
3524 (call-with-output-file "setup.cfg"
3525 (lambda (port)
1bbc659f
FB
3526 (format port "[directories]~%
3527basedirlist = ~a,~a~%
57b7b8cd 3528 [rc_options]~%
1bbc659f
FB
3529backend = TkAgg~%"
3530 (assoc-ref inputs "tcl")
3531 (assoc-ref inputs "tk"))))))
25f9a068
FB
3532 (alist-cons-after
3533 'install 'install-doc
3534 (lambda* (#:key outputs #:allow-other-keys)
3535 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3536 (doc (string-append data "/doc/" ,name "-" ,version))
3537 (info (string-append data "/info"))
3538 (html (string-append doc "/html")))
3539 (with-directory-excursion "doc"
25f9a068
FB
3540 ;; Produce pdf in 'A4' format.
3541 (substitute* (find-files "." "conf\\.py")
3542 (("latex_paper_size = 'letter'")
3543 "latex_paper_size = 'a4'"))
3544 (mkdir-p html)
3545 (mkdir-p info)
3546 ;; The doc recommends to run the 'html' target twice.
3547 (system* "python" "make.py" "html")
3548 (system* "python" "make.py" "html")
18b31516 3549 (copy-recursively "build/html" html)
25f9a068
FB
3550 (system* "python" "make.py" "latex")
3551 (system* "python" "make.py" "texinfo")
18b31516
FB
3552 (symlink (string-append html "/_images")
3553 (string-append info "/matplotlib-figures"))
3554 (with-directory-excursion "build/texinfo"
3555 (substitute* "matplotlib.texi"
3556 (("@image\\{([^,]*)" all file)
3557 (string-append "@image{matplotlib-figures/" file)))
3558 (symlink (string-append html "/_images")
3559 "./matplotlib-figures")
3560 (system* "makeinfo" "--no-split"
3561 "-o" "matplotlib.info" "matplotlib.texi"))
25f9a068
FB
3562 (copy-file "build/texinfo/matplotlib.info"
3563 (string-append info "/matplotlib.info"))
3564 (copy-file "build/latex/Matplotlib.pdf"
18b31516 3565 (string-append doc "/Matplotlib.pdf")))))
25f9a068 3566 %standard-phases))))
1c65314c
FB
3567 (home-page "http://matplotlib.org")
3568 (synopsis "2D plotting library for Python")
3569 (description
3570 "Matplotlib is a Python 2D plotting library which produces publication
3571quality figures in a variety of hardcopy formats and interactive environments
3572across platforms. Matplotlib can be used in Python scripts, the python and
3573ipython shell, web application servers, and six graphical user interface
3574toolkits.")
3f641af0 3575 (license license:psfl)
57b7b8cd 3576 (properties `((python2-variant . ,(delay python2-matplotlib))))))
1c65314c 3577
764c077b 3578(define-public python2-matplotlib
57b7b8cd
LC
3579 (let ((matplotlib (package-with-python2
3580 (strip-python2-variant python-matplotlib))))
764c077b 3581 (package (inherit matplotlib)
88c26834
AE
3582 ;; Make sure to use special packages for Python 2 instead
3583 ;; of those automatically rewritten by package-with-python2.
89b5c60e 3584 (propagated-inputs
7ca0dbc3 3585 `(("python2-pycairo" ,python2-pycairo)
764c077b 3586 ("python2-pygobject-2" ,python2-pygobject-2)
1bbc659f
FB
3587 ("python2-tkinter" ,python-2 "tk")
3588 ,@(fold alist-delete (package-propagated-inputs matplotlib)
3589 '("python-pycairo" "python-pygobject" "python-tkinter")))))))
94914805 3590
0dde6232
RW
3591(define-public python2-pysnptools
3592 (package
3593 (name "python2-pysnptools")
a800018e 3594 (version "0.3.9")
0dde6232
RW
3595 (source
3596 (origin
3597 (method url-fetch)
3f2e9675 3598 (uri (pypi-uri "pysnptools" version ".zip"))
0dde6232
RW
3599 (sha256
3600 (base32
a800018e 3601 "1wybggjzz8zw7aav4pjsg2h22xp17a1lghrprza1pxwlm7wf96y2"))))
0dde6232
RW
3602 (build-system python-build-system)
3603 (arguments
3604 `(#:python ,python-2)) ; only Python 2.7 is supported
3605 (propagated-inputs
3606 `(("python2-numpy" ,python2-numpy)
3607 ("python2-scipy" ,python2-scipy)
a800018e 3608 ("python2-pytz" ,python2-pytz)
0dde6232 3609 ("python2-cython" ,python2-cython)))
a800018e
EF
3610 (inputs
3611 `(("python2-dateutil-2" ,python2-dateutil-2)
3612 ("python2-pandas" ,python2-pandas)
3613 ("python2-six" ,python2-six)))
0dde6232
RW
3614 (native-inputs
3615 `(("unzip" ,unzip)
3616 ("python2-setuptools" ,python2-setuptools)))
3617 (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/")
3618 (synopsis "Library for reading and manipulating genetic data")
3619 (description
3620 "PySnpTools is a library for reading and manipulating genetic data. It
3621can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of
3622those files. It can also efficiently manipulate ranges of integers using set
3623operators such as union, intersection, and difference.")
3f641af0 3624 (license license:asl2.0)))
0dde6232 3625
c9b1b4f9
RW
3626(define-public python-rpy2
3627 (package
3628 (name "python-rpy2")
ec3bcbc7 3629 (version "2.7.6")
c9b1b4f9
RW
3630 (source
3631 (origin
3632 (method url-fetch)
ec3bcbc7 3633 (uri (pypi-uri "rpy2" version))
c9b1b4f9
RW
3634 (sha256
3635 (base32
ec3bcbc7 3636 "0nhan2qvrw7b7gg5zddwa22kybdv3x1g26vkd7q8lvnkgzrs4dga"))))
c9b1b4f9
RW
3637 (build-system python-build-system)
3638 (inputs
3639 `(("python-six" ,python-six)
3640 ("readline" ,readline)
3641 ("icu4c" ,icu4c)
3642 ("pcre" ,pcre)
3643 ("r" ,r)))
3644 (native-inputs
5ff6575b
RW
3645 `(("python-setuptools" ,python-setuptools)
3646 ("zlib" ,zlib)))
c9b1b4f9
RW
3647 (home-page "http://rpy.sourceforge.net/")
3648 (synopsis "Python interface to the R language")
3649 (description "rpy2 is a redesign and rewrite of rpy. It is providing a
3650low-level interface to R from Python, a proposed high-level interface,
3651including wrappers to graphical libraries, as well as R-like structures and
3652functions.")
3f641af0 3653 (license license:gpl3+)))
c9b1b4f9
RW
3654
3655(define-public python2-rpy2
3656 (let ((rpy2 (package-with-python2 python-rpy2)))
3657 (package (inherit rpy2)
3658 (native-inputs
3659 `(("python2-singledispatch" ,python2-singledispatch)
3660 ,@(package-native-inputs rpy2))))))
3661
bb986599
FB
3662(define-public python-scipy
3663 (package
3664 (name "python-scipy")
ba8a0824 3665 (version "0.16.0")
bb986599
FB
3666 (source
3667 (origin
3668 (method url-fetch)
de67e922
LF
3669; http://downloads.sourceforge.net/project/scipy/scipy/0.16.1/scipy-0.16.1.tar.gz
3670 (uri (string-append "mirror://sourceforge/scipy/scipy/" version
da6ce3f1 3671 "/scipy-" version ".tar.xz"))
bb986599
FB
3672 (sha256
3673 (base32
ba8a0824 3674 "0wa0a4skpda3gx7lb12yn19nhbairlyxrvda2lz2bcawk3x5qzz2"))))
bb986599 3675 (build-system python-build-system)
dd86c0d1 3676 (propagated-inputs
bb986599
FB
3677 `(("python-numpy" ,python-numpy)
3678 ("python-matplotlib" ,python-matplotlib)
dd86c0d1
RW
3679 ("python-pyparsing" ,python-pyparsing)))
3680 (inputs
3681 `(("lapack" ,lapack)
719b01c1 3682 ("openblas" ,openblas)))
bb986599 3683 (native-inputs
dd86c0d1
RW
3684 `(("python-nose" ,python-nose)
3685 ("python-sphinx" ,python-sphinx)
5248d49e 3686 ("python-numpydoc" ,python-numpydoc)
dd86c0d1 3687 ("gfortran" ,gfortran)
bb986599
FB
3688 ("texlive" ,texlive)
3689 ("perl" ,perl)))
3690 (outputs '("out" "doc"))
3691 (arguments
3692 `(#:phases
3693 (alist-cons-before
719b01c1 3694 'build 'configure-openblas
bb986599 3695 (lambda* (#:key inputs #:allow-other-keys)
719b01c1
RW
3696 (call-with-output-file "site.cfg"
3697 (lambda (port)
3698 (format port
3699 "[blas]
3700libraries = openblas
3701library_dirs = ~a/lib
3702include_dirs = ~a/include
3703[atlas]
3704library_dirs = ~a/lib
3705atlas_libs = openblas
3706"
3707 (assoc-ref inputs "openblas")
3708 (assoc-ref inputs "openblas")
3709 (assoc-ref inputs "openblas"))))
3710 #t)
bb986599
FB
3711 (alist-cons-after
3712 'install 'install-doc
3713 (lambda* (#:key outputs #:allow-other-keys)
3714 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
3715 (doc (string-append data "/doc/" ,name "-" ,version))
3716 (html (string-append doc "/html"))
3717 (pyver ,(string-append "PYVER=")))
3718 (with-directory-excursion "doc"
bb986599
FB
3719 ;; Fix generation of images for mathematical expressions.
3720 (substitute* (find-files "source" "conf\\.py")
3721 (("pngmath_use_preview = True")
3722 "pngmath_use_preview = False"))
3723 (mkdir-p html)
3724 (system* "make" "html" pyver)
3725 (system* "make" "latex" "PAPER=a4" pyver)
3726 (system* "make" "-C" "build/latex" "all-pdf" "PAPER=a4" pyver)
3727 (copy-file "build/latex/scipy-ref.pdf"
3728 (string-append doc "/scipy-ref.pdf"))
3729 (with-directory-excursion "build/html"
3730 (for-each (lambda (file)
3731 (let* ((dir (dirname file))
3732 (tgt-dir (string-append html "/" dir)))
96c46210 3733 (install-file file html)))
bb986599
FB
3734 (find-files "." ".*"))))))
3735 ;; Tests can only be run after the library has been installed and not
3736 ;; within the source directory.
3737 (alist-cons-after
3738 'install 'check
89b5c60e 3739 (lambda _
bb986599
FB
3740 (with-directory-excursion "/tmp"
3741 (zero? (system* "python" "-c" "import scipy; scipy.test()"))))
89b5c60e
AE
3742 (alist-delete
3743 'check
4f9ff21e
RW
3744 (alist-cons-after
3745 'unpack 'fix-tests
3746 (lambda _
3747 (substitute* "scipy/integrate/tests/test_quadpack.py"
3748 (("libm.so") "libm.so.6"))
3749 #t)
3750 %standard-phases)))))))
bb986599
FB
3751 (home-page "http://www.scipy.org/")
3752 (synopsis "The Scipy library provides efficient numerical routines")
3753 (description "The SciPy library is one of the core packages that make up
3754the SciPy stack. It provides many user-friendly and efficient numerical
3755routines such as routines for numerical integration and optimization.")
3f641af0 3756 (license license:bsd-3)))
bb986599 3757
764c077b 3758(define-public python2-scipy
57b7b8cd 3759 (package-with-python2 python-scipy))
bb986599 3760
73acc193 3761(define-public python-socksipy-branch
3762 (package
3763 (name "python-socksipy-branch")
3764 (version "1.01")
3765 (source
3766 (origin
3767 (method url-fetch)
3768 (uri (pypi-uri "SocksiPy-branch" version))
3769 (sha256
3770 (base32
3771 "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p"))))
3772 (build-system python-build-system)
3773 (arguments
3774 `(#:tests? #f)) ; There are no tests
3775 (home-page "https://code.google.com/archive/p/socksipy-branch/")
3776 (synopsis "Python SOCKS module")
3777 (description
3778 "SocksiPy - A Python SOCKS client module. It provides a
3779socket-like interface that supports connections to any TCP
3780service through the use of a SOCKS4, SOCKS5 or HTTP proxy.
3781The original version was developed by Dan Haim, this is a
3782branch created by Mario Vilas to address some open issues,
3783as the original project seems to have been abandoned circa 2007.")
3784 (license license:bsd-3)))
3785
3786(define-public python2-socksipy-branch
3787 (package-with-python2 python-socksipy-branch))
3788
94914805
EB
3789(define-public python-sqlalchemy
3790 (package
3791 (name "python-sqlalchemy")
a4ba286b 3792 (version "1.0.12")
94914805
EB
3793 (source
3794 (origin
3795 (method url-fetch)
3796 (uri (string-append "https://pypi.python.org/packages/source/S/"
3797 "SQLAlchemy/SQLAlchemy-" version ".tar.gz"))
3798 (sha256
3799 (base32
a4ba286b 3800 "1l8qclhd0s90w3pvwhi5mjxdwr5j7gw7cjka2fx6f2vqmq7f4yb6"))))
94914805
EB
3801 (build-system python-build-system)
3802 (native-inputs
3803 `(("python-cython" ,python-cython) ;for c extensions
3804 ("python-pytest" ,python-pytest)
3805 ("python-mock" ,python-mock))) ;for tests
3806 (arguments
3807 `(#:phases (alist-replace
3808 'check
3809 (lambda _ (zero? (system* "py.test")))
3810 %standard-phases)))
3811 (home-page "http://www.sqlalchemy.org")
3812 (synopsis "Database abstraction library")
3813 (description
3814 "SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that
3815gives application developers the full power and flexibility of SQL. It
3816provides a full suite of well known enterprise-level persistence patterns,
3817designed for efficient and high-performing database access, adapted into a
3818simple and Pythonic domain language.")
3f641af0 3819 (license license:x11)))
94914805
EB
3820
3821(define-public python2-sqlalchemy
3822 (package-with-python2 python-sqlalchemy))
c937562e 3823
de2966cf
EF
3824(define-public python-sqlalchemy-utils
3825 (package
3826 (name "python-sqlalchemy-utils")
3827 (version "0.32.9")
3828 (source
3829 (origin
3830 (method url-fetch)
3831 (uri (pypi-uri "SQLAlchemy-Utils" version))
3832 (sha256
3833 (base32
3834 "1zbmmh7n8m01ikizn2mj1mfwch26nsr1awv9mvskqry7av0mpy98"))))
3835 (build-system python-build-system)
3836 (inputs
3837 `(("python-six" ,python-six)
3838 ("python-sqlalchemy" ,python-sqlalchemy)))
3839 (home-page "https://github.com/kvesteri/sqlalchemy-utils")
3840 (synopsis "Various utility functions for SQLAlchemy")
3841 (description
3842 "SQLAlchemy-utils provides various utility functions and custom data types
3843for SQLAlchemy. SQLAlchemy is an SQL database abstraction library for Python.")
3844 (properties `((python2-variant . ,(delay python2-sqlalchemy-utils))))
3845 (license license:bsd-3)))
3846
3847(define-public python2-sqlalchemy-utils
3848 (let ((base (package-with-python2
3849 (strip-python2-variant python-sqlalchemy-utils))))
3850 (package (inherit base)
3851 (native-inputs
3852 `(("python2-setuptools" ,python2-setuptools)
3853 ,@(package-native-inputs base))))))
3854
af5a4602
CAW
3855(define-public python-alembic
3856 (package
3857 (name "python-alembic")
bb484529 3858 (version "0.8.7")
af5a4602
CAW
3859 (source
3860 (origin
3861 (method url-fetch)
3862 (uri (pypi-uri "alembic" version))
3863 (sha256
3864 (base32
bb484529 3865 "0ias6fdzwr2s220fnjspkdgm9510bd0cnap0hx5y4zy4srba9f3z"))))
af5a4602
CAW
3866 (build-system python-build-system)
3867 (native-inputs
3868 `(("python-mock" ,python-mock)
3869 ("python-pytest-cov" ,python-pytest-cov)))
3870 (propagated-inputs
3871 `(("python-sqlalchemy" ,python-sqlalchemy)
3872 ("python-mako" ,python-mako)
3873 ("python-editor" ,python-editor)))
3874 (home-page "http://bitbucket.org/zzzeek/alembic")
3875 (synopsis
3876 "Database migration tool for SQLAlchemy")
3877 (description
3878 "Alembic is a lightweight database migration tool for usage with the
3879SQLAlchemy Database Toolkit for Python.")
3880 (license license:expat)
3881 (properties `((python2-variant . ,(delay python2-alembic))))))
3882
3883(define-public python2-alembic
3884 (let ((alembic (package-with-python2
3885 (strip-python2-variant python-alembic))))
3886 (package
3887 (inherit alembic)
3888 (native-inputs `(("python2-setuptools" ,python2-setuptools)
3889 ,@(package-native-inputs alembic))))))
3890
1671c07c
EB
3891(define-public python-distutils-extra
3892 (package
3893 (name "python-distutils-extra")
3894 (version "2.38")
3895 (source
3896 (origin
3897 (method url-fetch)
3898 (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/"
3899 version "/+download/python-distutils-extra-"
3900 version ".tar.gz"))
3901 (sha256
3902 (base32
3903 "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x"))))
3904 (build-system python-build-system)
3905 (native-inputs
3906 `(("python-setuptools" ,python-setuptools)))
3907 (home-page "https://launchpad.net/python-distutils-extra/")
3908 (synopsis "Enhancements to Python's distutils")
3909 (description
3910 "The python-distutils-extra module enables you to easily integrate
3911gettext support, themed icons, and scrollkeeper-based documentation into
3912Python's distutils.")
3f641af0 3913 (license license:gpl2)))
1671c07c
EB
3914
3915(define-public python2-distutils-extra
3916 (package-with-python2 python-distutils-extra))
ea5456c8
EB
3917
3918(define-public python2-elib.intl
3919 (package
3920 (name "python2-elib.intl")
3921 (version "0.0.3")
3922 (source
3923 (origin
3924 ;; This project doesn't tag releases or publish tarballs, so we take
3925 ;; source from a (semi-arbitrary, i.e. latest as of now) git commit.
3926 (method git-fetch)
3927 (uri (git-reference
3928 (url "https://github.com/dieterv/elib.intl.git")
3929 (commit "d09997cfef")))
3930 (sha256
3931 (base32
3932 "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d"))))
3933 (build-system python-build-system)
3934 (native-inputs
3935 `(("python2-setuptools" ,python2-setuptools)))
3936 (arguments
3937 ;; incompatible with Python 3 (exception syntax)
3938 `(#:python ,python-2
3939 #:tests? #f
3940 ;; With standard flags, the install phase attempts to create a zip'd
3941 ;; egg file, and fails with an error: 'ZIP does not support timestamps
3942 ;; before 1980'
3943 #:configure-flags '("--single-version-externally-managed"
3944 "--record=elib.txt")))
3945 (home-page "https://github.com/dieterv/elib.intl")
3946 (synopsis "Enhanced internationalization for Python")
3947 (description
3948 "The elib.intl module provides enhanced internationalization (I18N)
3949services for your Python modules and applications.")
3f641af0 3950 (license license:lgpl3+)))
ea5456c8 3951
c937562e
EB
3952(define-public python-pillow
3953 (package
3954 (name "python-pillow")
debf4179 3955 (version "3.3.1")
c937562e
EB
3956 (source
3957 (origin
3958 (method url-fetch)
f1d9231d 3959 (uri (pypi-uri "Pillow" version))
c937562e
EB
3960 (sha256
3961 (base32
debf4179 3962 "1w9x3dfrg8b5lqhpjl0fczfyf9842wbqwgxbjjq4vfpxv5jwm49l"))))
c937562e
EB
3963 (build-system python-build-system)
3964 (native-inputs
3965 `(("python-setuptools" ,python-setuptools)
3966 ("python-nose" ,python-nose)))
3967 (inputs
5ff408d9
SB
3968 `(("freetype" ,freetype)
3969 ("lcms" ,lcms)
c937562e
EB
3970 ("zlib" ,zlib)
3971 ("libjpeg" ,libjpeg)
3972 ("openjpeg" ,openjpeg)
5ff408d9
SB
3973 ("libtiff" ,libtiff)
3974 ("libwebp" ,libwebp)))
c937562e
EB
3975 (propagated-inputs
3976 `(;; Used at runtime for pkg_resources
3977 ("python-setuptools" ,python-setuptools)))
3978 (arguments
e5358a6b
LC
3979 `(#:phases (modify-phases %standard-phases
3980 (add-before
3981 'install 'disable-egg-compression
3982 (lambda _
3983 ;; Leave the .egg uncompressed since compressing it would
3984 ;; prevent the GC from identifying run-time dependencies.
3985 ;; See <http://bugs.gnu.org/20765>.
3986 (let ((port (open-file "setup.cfg" "a")))
3987 (display "\n[easy_install]\nzip_ok = 0\n"
3988 port)
3989 (close-port port)
3990 #t)))
3991 (add-after
3992 'install 'check-installed
3993 (lambda _
3994 (begin
3995 (setenv "HOME" (getcwd))
3996 (and (zero? (system* "python" "selftest.py"
3997 "--installed"))
3998 (zero? (system* "python" "test-installed.py"))))))
3999 (delete 'check))))
c937562e
EB
4000 (home-page "https://pypi.python.org/pypi/Pillow")
4001 (synopsis "Fork of the Python Imaging Library")
4002 (description
4003 "The Python Imaging Library adds image processing capabilities to your
4004Python interpreter. This library provides extensive file format support, an
4005efficient internal representation, and fairly powerful image processing
4006capabilities. The core image library is designed for fast access to data
4007stored in a few basic pixel formats. It should provide a solid foundation for
4008a general image processing tool.")
3f641af0 4009 (license (license:x11-style
c937562e
EB
4010 "http://www.pythonware.com/products/pil/license.htm"
4011 "The PIL Software License"))))
4012
4013(define-public python2-pillow
4014 (package-with-python2 python-pillow))
bb986599 4015
a415f036
FB
4016(define-public python-pycparser
4017 (package
4018 (name "python-pycparser")
38eb6919 4019 (version "2.14")
a415f036
FB
4020 (source
4021 (origin
4022 (method url-fetch)
38eb6919 4023 (uri (pypi-uri "pycparser" version))
a415f036
FB
4024 (sha256
4025 (base32
38eb6919 4026 "0wvzyb6rxsfj3xcnpa4ynbh9qc7rrbk2277d5wqpphmx9akv8nbr"))))
a415f036
FB
4027 (outputs '("out" "doc"))
4028 (build-system python-build-system)
4029 (native-inputs
4030 `(("pkg-config" ,pkg-config)
4031 ("python-setuptools" ,python-setuptools)))
4032 (arguments
89b5c60e 4033 `(#:phases
a415f036
FB
4034 (alist-replace
4035 'check
4036 (lambda _
4037 (with-directory-excursion "tests"
4038 (zero? (system* "python" "all_tests.py"))))
4039 (alist-cons-after
4040 'install 'install-doc
4041 (lambda* (#:key outputs #:allow-other-keys)
4042 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4043 (doc (string-append data "/doc/" ,name "-" ,version))
4044 (examples (string-append doc "/examples")))
4045 (mkdir-p examples)
4046 (for-each (lambda (file)
4047 (copy-file (string-append "." file)
4048 (string-append doc file)))
4049 '("/README.rst" "/CHANGES" "/LICENSE"))
4050 (copy-recursively "examples" examples)))
4051 %standard-phases))))
4052 (home-page "https://github.com/eliben/pycparser")
4053 (synopsis "C parser in Python")
4054 (description
4055 "Pycparser is a complete parser of the C language, written in pure Python
4056using the PLY parsing library. It parses C code into an AST and can serve as
4057a front-end for C compilers or analysis tools.")
3f641af0 4058 (license license:bsd-3)))
a415f036
FB
4059
4060(define-public python2-pycparser
4061 (package-with-python2 python-pycparser))
57c3f716
FB
4062
4063(define-public python-cffi
4064 (package
4065 (name "python-cffi")
2d3a437c 4066 (version "1.4.2")
57c3f716
FB
4067 (source
4068 (origin
4069 (method url-fetch)
2d3a437c 4070 (uri (pypi-uri "cffi" version))
89b5c60e 4071 (sha256
2d3a437c 4072 (base32 "161rj52rzi3880lij17d6i9kvgkiwjilrqjs8405k8sf6ryif7cg"))))
57c3f716
FB
4073 (build-system python-build-system)
4074 (outputs '("out" "doc"))
4075 (inputs
4076 `(("libffi" ,libffi)))
4077 (propagated-inputs ; required at run-time
4078 `(("python-pycparser" ,python-pycparser)))
4079 (native-inputs
4080 `(("pkg-config" ,pkg-config)
4081 ("python-sphinx" ,python-sphinx)
4179f952 4082 ("python-pytest" ,python-pytest)
57c3f716
FB
4083 ("python-setuptools" ,python-setuptools)))
4084 (arguments
4179f952 4085 `(#:phases
57c3f716
FB
4086 (alist-cons-after
4087 'install 'install-doc
4088 (lambda* (#:key outputs #:allow-other-keys)
4089 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4090 (doc (string-append data "/doc/" ,name "-" ,version))
4091 (html (string-append doc "/html")))
4092 (with-directory-excursion "doc"
4093 (system* "make" "html")
4094 (mkdir-p html)
4095 (copy-recursively "build/html" html))
4096 (copy-file "LICENSE" (string-append doc "/LICENSE"))))
4097 %standard-phases)))
4098 (home-page "http://cffi.readthedocs.org")
4099 (synopsis "Foreign function interface for Python")
4100 (description
4101 "Foreign Function Interface for Python calling C code.")
bd3fa666 4102 (license license:expat)))
57c3f716
FB
4103
4104(define-public python2-cffi
4105 (package-with-python2 python-cffi))
6fa14469
FB
4106
4107(define-public python-xcffib
4108 (package
4109 (name "python-xcffib")
4110 (version "0.1.9")
4111 (source
4112 (origin
4113 (method url-fetch)
4114 (uri (string-append "https://pypi.python.org/packages/source/x/"
4115 "xcffib/xcffib-" version ".tar.gz"))
4116 (sha256
4117 (base32
4118 "0655hzxv57h1a9ja9kwp0ichbkhf3djw32k33d66xp0q37dq2y81"))))
4119 (build-system python-build-system)
4120 (inputs
4121 `(("libxcb" ,libxcb)
4122 ("python-six" ,python-six)))
4123 (native-inputs
4124 `(("python-setuptools" ,python-setuptools)))
4125 (propagated-inputs
4126 `(("python-cffi" ,python-cffi))) ; used at run time
4127 (arguments
89b5c60e 4128 `(#:phases
6fa14469
FB
4129 (alist-cons-after
4130 'install 'install-doc
4131 (lambda* (#:key outputs #:allow-other-keys)
4132 (let ((doc (string-append (assoc-ref outputs "out") "/share"
4133 "/doc/" ,name "-" ,version)))
4134 (mkdir-p doc)
4135 (copy-file "README.md"
4136 (string-append doc "/README.md"))))
4137 %standard-phases)))
4138 (home-page "https://github.com/tych0/xcffib")
4139 (synopsis "XCB Python bindings")
4140 (description
4141 "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds
4142support for Python 3 and PyPy. It is based on cffi.")
bd3fa666 4143 (license license:expat)))
6fa14469
FB
4144
4145(define-public python2-xcffib
4146 (package-with-python2 python-xcffib))
4147
9e099723
FB
4148(define-public python-cairocffi
4149 (package
4150 (name "python-cairocffi")
4151 (version "0.6")
4152 (source
4153 (origin
4154 (method url-fetch)
4155 ;; The archive on pypi is missing the 'utils' directory!
4156 (uri (string-append "https://github.com/SimonSapin/cairocffi/archive/v"
4157 version ".tar.gz"))
f586c877 4158 (file-name (string-append name "-" version ".tar.gz"))
9e099723
FB
4159 (sha256
4160 (base32
4161 "03w5p62sp3nqiccx864sbq0jvh7946277jqx3rcc3dch5xwfvv51"))))
4162 (build-system python-build-system)
4163 (outputs '("out" "doc"))
4164 (inputs
4165 `(("gdk-pixbuf" ,gdk-pixbuf)
4166 ("cairo" ,cairo)))
4167 (native-inputs
4168 `(("pkg-config" ,pkg-config)
4169 ("python-sphinx" ,python-sphinx)
4170 ("python-docutils" ,python-docutils)
4171 ("python-setuptools" ,python-setuptools)))
4172 (propagated-inputs
4173 `(("python-xcffib" ,python-xcffib))) ; used at run time
4174 (arguments
89b5c60e 4175 `(#:phases
9e099723
FB
4176 (alist-cons-after
4177 'install 'install-doc
4178 (lambda* (#:key inputs outputs #:allow-other-keys)
4179 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4180 (doc (string-append data "/doc/" ,name "-" ,version))
4181 (html (string-append doc "/html")))
89b5c60e 4182 (setenv "LD_LIBRARY_PATH"
9e099723
FB
4183 (string-append (assoc-ref inputs "cairo") "/lib" ":"
4184 (assoc-ref inputs "gdk-pixbuf") "/lib"))
4185 (setenv "LANG" "en_US.UTF-8")
4186 (mkdir-p html)
4187 (for-each (lambda (file)
4188 (copy-file (string-append "." file)
4189 (string-append doc file)))
4190 '("/README.rst" "/CHANGES" "/LICENSE"))
4191 (system* "python" "setup.py" "build_sphinx")
4192 (copy-recursively "docs/_build/html" html)))
4193 %standard-phases)))
4194 (home-page "https://github.com/SimonSapin/cairocffi")
4195 (synopsis "Python bindings and object-oriented API for Cairo")
4196 (description
4197 "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of
4198Python bindings and object-oriented API for cairo. Cairo is a 2D vector
4199graphics library with support for multiple backends including image buffers,
4200PNG, PostScript, PDF, and SVG file output.")
3f641af0 4201 (license license:bsd-3)))
9e099723
FB
4202
4203(define-public python2-cairocffi
4204 (package-with-python2 python-cairocffi))
4205
3cff95cb
RW
4206(define-public python-decorator
4207 (package
4208 (name "python-decorator")
eb6e2e81 4209 (version "4.0.9")
3cff95cb
RW
4210 (source
4211 (origin
4212 (method url-fetch)
e21338be 4213 (uri (pypi-uri "decorator" version))
3cff95cb 4214 (sha256
eb6e2e81 4215 (base32 "1a5vwhflfd9sh3rfb40xlyipldgdzfff6brman57hqv3661jw0lh"))))
3cff95cb
RW
4216 (build-system python-build-system)
4217 (arguments '(#:tests? #f)) ; no test target
4218 (native-inputs
4219 `(("python-setuptools" ,python-setuptools)))
eb6e2e81 4220 (home-page "https://pypi.python.org/pypi/decorator/")
3cff95cb
RW
4221 (synopsis "Python module to simplify usage of decorators")
4222 (description
4223 "The aim of the decorator module is to simplify the usage of decorators
4224for the average programmer, and to popularize decorators usage giving examples
4225of useful decorators, such as memoize, tracing, redirecting_stdout, locked,
4226etc. The core of this module is a decorator factory.")
4227 (license license:expat)))
4228
4229(define-public python2-decorator
4230 (package-with-python2 python-decorator))
4231
2c0499ad
RW
4232(define-public python-drmaa
4233 (package
4234 (name "python-drmaa")
4235 (version "0.7.6")
4236 (source
4237 (origin
4238 (method url-fetch)
4239 (uri (string-append
4240 "https://pypi.python.org/packages/source/d/drmaa/drmaa-"
4241 version ".tar.gz"))
4242 (sha256
4243 (base32 "0bzl9f9g34dlhwf09i3fdv7dqqzf2iq0w7d6c2bafx1nlap8qfbh"))))
4244 (build-system python-build-system)
4245 ;; The test suite requires libdrmaa which is provided by the cluster
4246 ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH
4247 ;; should be set to the path of the libdrmaa library.
4248 (arguments '(#:tests? #f))
4249 (native-inputs
4250 `(("python-nose" ,python-nose)
4251 ("python-setuptools" ,python-setuptools)))
4252 (home-page "https://pypi.python.org/pypi/drmaa")
4253 (synopsis "Python bindings for the DRMAA library")
4254 (description
4255 "A Python package for Distributed Resource Management (DRM) job
4256submission and control. This package is an implementation of the DRMAA 1.0
4257Python language binding specification.")
3f641af0 4258 (license license:bsd-3)))
2c0499ad
RW
4259
4260(define-public python2-drmaa
4261 (package-with-python2 python-drmaa))
4262
d05c6da0
RW
4263(define-public python-gridmap
4264 (package
4265 (name "python-gridmap")
4266 (version "0.13.0")
4267 (source
4268 (origin
4269 (method url-fetch)
4270 (uri (string-append
4271 "https://github.com/pygridtools/gridmap/archive/v"
4272 version ".tar.gz"))
4273 (file-name (string-append name "-" version ".tar.gz"))
4274 (sha256
4275 (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x"))))
4276 (build-system python-build-system)
4277 (inputs
4278 `(("python-psutil" ,python-psutil)
4279 ("python-drmaa" ,python-drmaa)
4280 ("python-pyzmq" ,python-pyzmq)))
4281 (native-inputs
4282 `(("python-setuptools" ,python-setuptools)))
4283 (home-page "https://github.com/pygridtools/gridmap")
4284 (synopsis "Create jobs on a cluster directly from Python")
4285 (description
4286 "Gridmap is a Python package to allow you to easily create jobs on the
4287cluster directly from Python. You can directly map Python functions onto the
4288cluster without needing to write any wrapper code yourself.")
3f641af0 4289 (license license:gpl3+)))
d05c6da0
RW
4290
4291(define-public python2-gridmap
4292 (package-with-python2 python-gridmap))
4293
cb6d5c54
RW
4294(define-public python-pexpect
4295 (package
4296 (name "python-pexpect")
4297 (version "3.3")
4298 (source
4299 (origin
4300 (method url-fetch)
4301 (uri (string-append "https://pypi.python.org/packages/source/p/"
4302 "pexpect/pexpect-" version ".tar.gz"))
4303 (sha256
4304 (base32 "1fp5gm976z7ghm8jw57463rj19cv06c8zw842prgyg788f6n3snz"))))
4305 (build-system python-build-system)
4306 (arguments
4307 `(#:phases
4308 (modify-phases %standard-phases
4309 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4310 (native-inputs
4311 `(("python-nose" ,python-nose)))
4312 (home-page "http://pexpect.readthedocs.org/")
4313 (synopsis "Controlling interactive console applications")
4314 (description
4315 "Pexpect is a pure Python module for spawning child applications;
4316controlling them; and responding to expected patterns in their output.
4317Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a
4318child application and control it as if a human were typing commands.")
3f641af0 4319 (license license:isc)))
cb6d5c54
RW
4320
4321(define-public python2-pexpect
4322 (package-with-python2 python-pexpect))
4323
229ad120
RW
4324(define-public python-setuptools-scm
4325 (package
4326 (name "python-setuptools-scm")
42d6d0d0 4327 (version "1.11.1")
229ad120
RW
4328 (source (origin
4329 (method url-fetch)
383af6b0 4330 (uri (pypi-uri "setuptools_scm" version))
229ad120
RW
4331 (sha256
4332 (base32
42d6d0d0 4333 "1gqr73i150yzj3mz32854vj93x07yr52kn8fdckwa41ll8wgficc"))))
229ad120 4334 (build-system python-build-system)
383af6b0 4335 (native-inputs `(("python-setuptools" ,python-setuptools)))
229ad120
RW
4336 (home-page "https://github.com/pypa/setuptools_scm/")
4337 (synopsis "Manage Python package versions in SCM metadata")
4338 (description
383af6b0 4339 "Setuptools_scm handles managing your Python package versions in
229ad120
RW
4340@dfn{software configuration management} (SCM) metadata instead of declaring
4341them as the version argument or in a SCM managed file.")
4342 (license license:expat)))
4343
4344(define-public python2-setuptools-scm
4345 (package-with-python2 python-setuptools-scm))
4346
b74270ee
RW
4347(define-public python-pathpy
4348 (package
4349 (name "python-pathpy")
4350 (version "8.1.1")
4351 (source
4352 (origin
4353 (method url-fetch)
4354 (uri (string-append "https://pypi.python.org/packages/source/p/"
4355 "path.py/path.py-" version ".tar.gz"))
4356 (sha256
4357 (base32 "1p8s1l2vfkqhqxdhqlj0g1jjw4f1as2frr35sjcpjjpd5a89y41f"))))
4358 (build-system python-build-system)
4359 (propagated-inputs
4360 `(("python-appdirs" ,python-appdirs)))
4361 (native-inputs
553b709b
EF
4362 `(("python-setuptools" ,python-setuptools)
4363 ("python-setuptools-scm" ,python-setuptools-scm)
b74270ee
RW
4364 ("python-pytest" ,python-pytest)
4365 ("python-pytest-runner" ,python-pytest-runner)))
4366 (home-page "http://github.com/jaraco/path.py")
4367 (synopsis "Python module wrapper for built-in os.path")
4368 (description
4369 "@code{path.py} implements path objects as first-class entities, allowing
4370common operations on files to be invoked on those path objects directly.")
4371 (license license:expat)))
4372
4373(define-public python2-pathpy
4374 (package-with-python2 python-pathpy))
4375
0d34e01b
RW
4376(define-public python-pickleshare
4377 (package
4378 (name "python-pickleshare")
4379 (version "0.5")
4380 (source
4381 (origin
4382 (method url-fetch)
4383 (uri (string-append "https://pypi.python.org/packages/source/p/"
4384 "pickleshare/pickleshare-" version ".tar.gz"))
4385 (sha256
4386 (base32 "11ljr90j3p6qswdrbl7p4cjb2i93f6vn0vx9anzpshsx0d2mggn0"))))
4387 (build-system python-build-system)
4388 (propagated-inputs
4389 `(("python-pathpy" ,python-pathpy)))
b72a4410
EF
4390 (native-inputs
4391 `(("python-setuptools" ,python-setuptools)))
0d34e01b
RW
4392 (home-page "https://github.com/vivainio/pickleshare")
4393 (synopsis "Tiny key value database with concurrency support")
4394 (description
4395 "PickleShare is a small ‘shelve’-like datastore with concurrency support.
4396Like shelve, a PickleShareDB object acts like a normal dictionary. Unlike
4397shelve, many processes can access the database simultaneously. Changing a
4398value in database is immediately visible to other processes accessing the same
4399database. Concurrency is possible because the values are stored in separate
4400files. Hence the “database” is a directory where all files are governed by
4401PickleShare.")
4402 (license license:expat)))
4403
4404(define-public python2-pickleshare
4405 (package-with-python2 python-pickleshare))
4406
cd6e5189
RW
4407(define-public python-simplegeneric
4408 (package
4409 (name "python-simplegeneric")
4410 (version "0.8.1")
4411 (source
4412 (origin
4413 (method url-fetch)
4414 (uri (string-append "https://pypi.python.org/packages/source/s/"
4415 "simplegeneric/simplegeneric-" version ".zip"))
4416 (sha256
4417 (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw"))))
4418 (build-system python-build-system)
4419 (native-inputs
69b96e5e
RW
4420 `(("python-setuptools" ,python-setuptools)
4421 ("unzip" ,unzip)))
cd6e5189
RW
4422 (home-page "http://cheeseshop.python.org/pypi/simplegeneric")
4423 (synopsis "Python module for simple generic functions")
4424 (description
4425 "The simplegeneric module lets you define simple single-dispatch generic
4426functions, akin to Python’s built-in generic functions like @code{len()},
4427@code{iter()} and so on. However, instead of using specially-named methods,
4428these generic functions use simple lookup tables, akin to those used by
4429e.g. @code{pickle.dump()} and other generic functions found in the Python
4430standard library.")
3f641af0 4431 (license license:zpl2.1)))
cd6e5189
RW
4432
4433(define-public python2-simplegeneric
4434 (package-with-python2 python-simplegeneric))
4435
ddc7d8ed
RW
4436(define-public python-ipython-genutils
4437 (package
4438 (name "python-ipython-genutils")
4439 (version "0.1.0")
4440 (source
4441 (origin
4442 (method url-fetch)
4443 (uri (string-append "https://pypi.python.org/packages/source/i/"
4444 "ipython_genutils/ipython_genutils-"
4445 version ".tar.gz"))
4446 (sha256
4447 (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is"))))
4448 (build-system python-build-system)
4449 (arguments `(#:tests? #f)) ; no tests
4450 (home-page "http://ipython.org")
4451 (synopsis "Vestigial utilities from IPython")
4452 (description
4453 "This package provides retired utilities from IPython.")
3f641af0 4454 (license license:bsd-3)))
ddc7d8ed
RW
4455
4456(define-public python2-ipython-genutils
4457 (package-with-python2 python-ipython-genutils))
4458
2b10eb48
RW
4459(define-public python-traitlets
4460 (package
4461 (name "python-traitlets")
cc0c4fde 4462 (version "4.1.0")
2b10eb48
RW
4463 (source
4464 (origin
4465 (method url-fetch)
cc0c4fde 4466 (uri (pypi-uri "traitlets" version))
2b10eb48
RW
4467 (sha256
4468 (base32
cc0c4fde 4469 "0nxgj8jxlm1kqf8cx2x7vjid05zdgbxpqhjbdl46r8njlpgkh3j4"))))
2b10eb48
RW
4470 (build-system python-build-system)
4471 (arguments
4472 `(#:phases
4473 (modify-phases %standard-phases
4474 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
4475 (propagated-inputs
4476 `(("python-ipython-genutils" ,python-ipython-genutils)
4477 ("python-decorator" ,python-decorator)))
4478 (native-inputs
cc0c4fde
EF
4479 `(("python-mock" ,python-mock)
4480 ("python-nose" ,python-nose)))
2b10eb48
RW
4481 (home-page "http://ipython.org")
4482 (synopsis "Configuration system for Python applications")
4483 (description
4484 "Traitlets is a framework that lets Python classes have attributes with
4485type checking, dynamically calculated default values, and ‘on change’
4486callbacks. The package also includes a mechanism to use traitlets for
4487configuration, loading values from files or from command line arguments. This
4488is a distinct layer on top of traitlets, so you can use traitlets in your code
4489without using the configuration machinery.")
3f641af0 4490 (license license:bsd-3)))
2b10eb48
RW
4491
4492(define-public python2-traitlets
4493 (package-with-python2 python-traitlets))
4494
ae1ab9fe
FB
4495(define-public python-ipython
4496 (package
4497 (name "python-ipython")
3a0b1b9a 4498 (version "3.2.1")
ae1ab9fe
FB
4499 (source
4500 (origin
fceac880 4501 (method url-fetch)
fc1adab1 4502 (patches (search-patches "python-ipython-inputhook-ctype.patch"))
fceac880
FB
4503 (uri (string-append "https://pypi.python.org/packages/source/i/"
4504 "ipython/ipython-" version ".tar.gz"))
4505 (sha256
4506 (base32 "0xwin0sa9n0cabx4cq1ibf5ldsiw5dyimibla82kicz5gbpas4y9"))))
ae1ab9fe
FB
4507 (build-system python-build-system)
4508 (outputs '("out" "doc"))
3a0b1b9a
FB
4509 (propagated-inputs
4510 `(("python-pyzmq" ,python-pyzmq)
4511 ("python-terminado" ,python-terminado)))
ae1ab9fe
FB
4512 (inputs
4513 `(("readline" ,readline)
3a0b1b9a 4514 ("which" ,which)
ae1ab9fe 4515 ("python-matplotlib" ,python-matplotlib)
5d26e542 4516 ("python-numpy" ,python-numpy)
ae1ab9fe 4517 ("python-numpydoc" ,python-numpydoc)
3a0b1b9a
FB
4518 ("python-jinja2" ,python-jinja2)
4519 ("python-mistune" ,python-mistune)
4520 ("python-jsonschema" ,python-jsonschema)
4521 ("python-pygments" ,python-pygments)
4522 ("python-requests" ,python-requests) ;; for tests
ae1ab9fe
FB
4523 ("python-nose" ,python-nose)))
4524 (native-inputs
4525 `(("pkg-config" ,pkg-config)
4526 ("python-sphinx" ,python-sphinx)
4527 ("texlive" ,texlive)
4528 ("texinfo" ,texinfo)
4529 ("python-setuptools" ,python-setuptools)))
4530 (arguments
89b5c60e 4531 `(#:phases
3a0b1b9a
FB
4532 (modify-phases %standard-phases
4533 (add-after
4534 'install 'install-doc
4535 (lambda* (#:key inputs outputs #:allow-other-keys)
4536 (let* ((data (string-append (assoc-ref outputs "doc") "/share"))
4537 (doc (string-append data "/doc/" ,name "-" ,version))
4538 (html (string-append doc "/html"))
4539 (man1 (string-append data "/man/man1"))
4540 (info (string-append data "/info"))
4541 (examples (string-append doc "/examples")))
afd3d931 4542 (setenv "LANG" "en_US.utf8")
3a0b1b9a
FB
4543 (with-directory-excursion "docs"
4544 ;; FIXME: html and pdf fail to build
4545 ;; (system* "make" "html")
4546 ;; (system* "make" "pdf" "PAPER=a4")
4547 (system* "make" "info"))
4548 (copy-recursively "docs/man" man1)
4549 (copy-recursively "examples" examples)
4550 ;; (copy-recursively "docs/build/html" html)
4551 ;; (copy-file "docs/build/latex/ipython.pdf"
4552 ;; (string-append doc "/ipython.pdf"))
4553 (mkdir-p info)
4554 (copy-file "docs/build/texinfo/ipython.info"
4555 (string-append info "/ipython.info"))
4556 (copy-file "COPYING.rst" (string-append doc "/COPYING.rst")))))
4557 ;; Tests can only be run after the library has been installed and not
4558 ;; within the source directory.
4559 (delete 'check)
4560 (add-after
4561 'install 'check
4562 (lambda* (#:key outputs tests? #:allow-other-keys)
4563 (if tests?
4564 (with-directory-excursion "/tmp"
4565 (setenv "HOME" "/tmp/") ;; required by a test
4566 (zero? (system* (string-append (assoc-ref outputs "out")
4567 "/bin/iptest"))))
4568 #t)))
4569 (add-before
4570 'install 'fix-tests
4571 (lambda* (#:key inputs #:allow-other-keys)
4572 (substitute* "./IPython/utils/_process_posix.py"
4573 (("/usr/bin/env', 'which") (which "which")))
4574 (substitute* "./IPython/core/tests/test_inputtransformer.py"
4575 (("#!/usr/bin/env python")
4576 (string-append "#!" (which "python"))))
4577 ;; Disable 1 failing test
4578 (substitute* "./IPython/core/tests/test_magic.py"
4579 (("def test_dirops\\(\\):" all)
4580 (string-append "@dec.skipif(True)\n" all))))))))
ae1ab9fe
FB
4581 (home-page "http://ipython.org")
4582 (synopsis "IPython is a tool for interactive computing in Python")
4583 (description
4584 "IPython provides a rich architecture for interactive computing with:
4585Powerful interactive shells, a browser-based notebook, support for interactive
4586data visualization, embeddable interpreters and tools for parallel
4587computing.")
135ba811
EF
4588 (license license:bsd-3)
4589 (properties `((python2-variant . ,(delay python2-ipython))))))
ae1ab9fe
FB
4590
4591(define-public python2-ipython
135ba811 4592 (let ((ipython (package-with-python2 (strip-python2-variant python-ipython))))
3a0b1b9a
FB
4593 (package
4594 (inherit ipython)
4595 ;; FIXME: some tests are failing
4596 (arguments
4597 `(#:tests? #f ,@(package-arguments ipython)))
3a0b1b9a 4598 ;; FIXME: add pyreadline once available.
89b5c60e 4599 (inputs
135ba811
EF
4600 `(("python2-mock" ,python2-mock)
4601 ,@(package-inputs ipython))))))
03411993
AE
4602
4603(define-public python-isodate
4604 (package
4605 (name "python-isodate")
b6785c2e 4606 (version "0.5.4")
03411993
AE
4607 (source
4608 (origin
4609 (method url-fetch)
b6785c2e 4610 (uri (pypi-uri "isodate" version))
03411993
AE
4611 (sha256
4612 (base32
b6785c2e 4613 "0cafaiwixgpxwh9dsd28qb0dbzsj6xpxjdkyk30ns91ps10mq422"))))
03411993
AE
4614 (build-system python-build-system)
4615 (inputs
4616 `(("python-setuptools" ,python-setuptools)))
4617 (home-page
4618 "http://cheeseshop.python.org/pypi/isodate")
4619 (synopsis
4620 "Python date parser and formatter")
4621 (description
4622 "Python-isodate is a python module for parsing and formatting
4623ISO 8601 dates, time and duration.")
3f641af0 4624 (license license:bsd-3)))
03411993
AE
4625
4626(define-public python2-isodate
4627 (package-with-python2 python-isodate))
673ab897
AE
4628
4629(define-public python-html5lib
4630 (package
4631 (name "python-html5lib")
fee04c19 4632 (version "1.0b8")
673ab897
AE
4633 (source
4634 (origin
4635 (method url-fetch)
fee04c19 4636 (uri (pypi-uri "html5lib" version))
673ab897
AE
4637 (sha256
4638 (base32
fee04c19 4639 "1lknq5j3nh11xrl268ks76zaj0gyzh34v94n5vbf6dk8llzxdx0q"))))
673ab897 4640 (build-system python-build-system)
3dd75476
AE
4641 (propagated-inputs
4642 `(("python-six" ,python-six))) ; required to "import html5lib"
673ab897
AE
4643 (inputs
4644 `(("python-setuptools" ,python-setuptools)))
4645 (arguments
4646 `(#:test-target "check"))
4647 (home-page
4648 "https://github.com/html5lib/html5lib-python")
4649 (synopsis
4650 "Python HTML parser based on the WHATWG HTML specifcation")
4651 (description
4652 "Html5lib is an HTML parser based on the WHATWG HTML specifcation
4653and written in Python.")
bd3fa666 4654 (license license:expat)))
673ab897
AE
4655
4656(define-public python2-html5lib
4657 (package-with-python2 python-html5lib))
e99f4211
MW
4658
4659(define-public python-urwid
4660 (package
4661 (name "python-urwid")
51ff41f6 4662 (version "1.3.1")
e99f4211
MW
4663 (source
4664 (origin
4665 (method url-fetch)
b97c1bfd 4666 (uri (pypi-uri "urwid" version))
e99f4211
MW
4667 (sha256
4668 (base32
51ff41f6 4669 "18cnd1wdjcas08x5qwa5ayw6jsfcn33w4d9f7q3s29fy6qzc1kng"))))
e99f4211 4670 (build-system python-build-system)
b97c1bfd
LF
4671 (arguments
4672 `(#:phases
4673 (modify-phases %standard-phases
4674 ;; Disable failing test. Bug filed upstream:
4675 ;; https://github.com/wardi/urwid/issues/164
51ff41f6 4676 ;; TODO: check again for python-urwid > 1.3.1 or python > 3.4.3.
b97c1bfd
LF
4677 (add-after 'unpack 'disable-failing-test
4678 (lambda _
4679 (substitute* "urwid/tests/test_event_loops.py"
4680 (("test_remove_watch_file")
4681 "disable_remove_watch_file")))))))
e99f4211
MW
4682 (native-inputs `(("python-setuptools" ,python-setuptools)))
4683 (home-page "http://urwid.org")
4684 (synopsis "Console user interface library for Python")
4685 (description
4686 "Urwid is a curses-based UI/widget library for Python. It includes many
4687features useful for text console applications.")
3f641af0 4688 (license license:lgpl2.1+)))
e99f4211
MW
4689
4690(define-public python2-urwid
4691 (package-with-python2 python-urwid))
d95a56c6 4692
47d0b292
TS
4693(define-public python-urwidtrees
4694 (package
4695 (name "python-urwidtrees")
37ec4623 4696 (version "1.0.2")
47d0b292
TS
4697 (source
4698 (origin
4699 (method url-fetch)
37ec4623
TS
4700 ;; package author intends on distributing via github rather than pypi:
4701 ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331
4702 (uri (string-append "https://github.com/pazz/urwidtrees/archive/"
4703 version ".tar.gz"))
4704 (file-name (string-append name "-" version ".tar.gz"))
47d0b292
TS
4705 (sha256
4706 (base32
37ec4623 4707 "0d30lyd3s2a97rhqfax5w9ssqds2z6aydqx3c6j2c2lk3cb4ngvh"))))
47d0b292
TS
4708 (build-system python-build-system)
4709 (arguments
4710 '(#:tests? #f)) ; no tests
4711 (inputs `(("python-urwid" ,python-urwid)))
4712 (home-page "https://github.com/pazz/urwidtrees")
4713 (synopsis "Tree widgets for urwid")
4714 (description "Urwidtrees is a Widget Container API for the @code{urwid}
4715toolkit. Use it to build trees of widgets.")
3f641af0 4716 (license license:gpl3+)))
47d0b292
TS
4717
4718(define-public python2-urwidtrees
4719 (package-with-python2 python-urwidtrees))
4720
d95a56c6
PAR
4721(define-public python-dbus
4722 (package
4723 (name "python-dbus")
4724 (version "1.2.0")
4725 (source
4726 (origin
4727 (method url-fetch)
4728 (uri (string-append
5cc3096c 4729 "https://dbus.freedesktop.org/releases/dbus-python/dbus-python-"
d95a56c6
PAR
4730 version ".tar.gz"))
4731 (sha256
4732 (base32 "1py62qir966lvdkngg0v8k1khsqxwk5m4s8nflpk1agk5f5nqb71"))))
4733 (build-system gnu-build-system)
6717c879
SB
4734 (arguments
4735 '(#:phases
4736 (modify-phases %standard-phases
4737 (add-before
4738 'check 'pre-check
4739 (lambda _
4740 ;; XXX: For the missing '/etc/machine-id'.
4741 (substitute* "test/run-test.sh"
4742 (("DBUS_FATAL_WARNINGS=1")
4743 "DBUS_FATAL_WARNINGS=0"))
4744 #t)))))
d95a56c6
PAR
4745 (native-inputs
4746 `(("pkg-config" ,pkg-config)))
4747 (inputs
4748 `(("python" ,python)
2e88d113 4749 ("dbus-glib" ,dbus-glib)))
d95a56c6
PAR
4750 (synopsis "Python bindings for D-bus")
4751 (description "python-dbus provides bindings for libdbus, the reference
4752implementation of D-Bus.")
4753 (home-page "http://www.freedesktop.org/wiki/Software/DBusBindings/")
bd3fa666 4754 (license license:expat)))
b52af02b
MW
4755
4756(define-public python2-dbus
4757 (package (inherit python-dbus)
4758 (name "python2-dbus")
4759 (inputs `(("python" ,python-2)
4760 ,@(alist-delete "python"
4761 (package-inputs python-dbus)
4762 equal?)))
4763 ;; FIXME: on Python 2, the test_utf8 fails with:
4764 ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)"
4765 (arguments `(#:tests? #f))))
a6ac8332
AE
4766
4767(define-public python-apsw
4768 (package
4769 (name "python-apsw")
917708c2 4770 (version "3.9.2-r1")
a6ac8332
AE
4771 (source
4772 (origin
4773 (method url-fetch)
917708c2 4774 (uri (pypi-uri "apsw" version))
a6ac8332
AE
4775 (sha256
4776 (base32
917708c2 4777 "0w4jb0wpx785qw42r3h4fh7gl5w2968q48i7gygybsfxck8nzffs"))))
a6ac8332
AE
4778 (build-system python-build-system)
4779 (inputs
4780 `(("python-setuptools" ,python-setuptools)
4781 ("sqlite" ,sqlite)))
4782 (arguments
4783 `(#:phases
4784 ;; swap check and install phases
4785 (alist-cons-after
4786 'install 'check
4787 (assoc-ref %standard-phases 'check)
4788 (alist-delete
4789 'check
4790 %standard-phases))))
4791 (home-page "https://github.com/rogerbinns/apsw/")
4792 (synopsis "Another Python SQLite Wrapper")
4793 (description "APSW is a Python wrapper for the SQLite
4794embedded relational database engine. In contrast to other wrappers such as
4795pysqlite it focuses on being a minimal layer over SQLite attempting just to
4796translate the complete SQLite API into Python.")
abde5f37 4797 (license license:zlib)))
a6ac8332
AE
4798
4799(define-public python2-apsw
4800 (package-with-python2 python-apsw))
26b307e2
AE
4801
4802(define-public python-lxml
4803 (package
4804 (name "python-lxml")
d58a3203 4805 (version "3.6.0")
26b307e2
AE
4806 (source
4807 (origin
4808 (method url-fetch)
97bbc480 4809 (uri (pypi-uri "lxml" version))
26b307e2 4810 (sha256
d58a3203
EF
4811 (base32
4812 "1pvbmiy2m7jwv493kilbghhj2pkh8wy1na3ji350vhzhlwlclx4w"))))
26b307e2
AE
4813 (build-system python-build-system)
4814 (inputs
4815 `(("libxml2" ,libxml2)
4816 ("libxslt" ,libxslt)
4817 ("python-setuptools" ,python-setuptools)))
4818 (home-page "http://lxml.de/")
4819 (synopsis
4820 "Python XML processing library")
4821 (description
4822 "The lxml XML toolkit is a Pythonic binding for the C libraries
4823libxml2 and libxslt.")
3f641af0 4824 (license license:bsd-3))) ; and a few more, see LICENSES.txt
26b307e2
AE
4825
4826(define-public python2-lxml
4827 (package-with-python2 python-lxml))
4ed20663 4828
b32a1e47
CAW
4829;; beautifulsoup4 has a totally different namespace than 3.x,
4830;; and pypi seems to put it under its own name, so I guess we should too
4831(define-public python-beautifulsoup4
4832 (package
4833 (name "python-beautifulsoup4")
cfbb3b0d 4834 (version "4.5.0")
b32a1e47
CAW
4835 (source
4836 (origin
4837 (method url-fetch)
4838 (uri (pypi-uri "beautifulsoup4" version))
4839 (sha256
4840 (base32
cfbb3b0d 4841 "1rf94360s8pmn37vxqjl0g74krq2p6nj3wbn6pj94ik6ny44q24f"))))
b32a1e47
CAW
4842 (build-system python-build-system)
4843 (home-page
4844 "http://www.crummy.com/software/BeautifulSoup/bs4/")
4845 (synopsis
4846 "Python screen-scraping library")
4847 (description
4848 "Beautiful Soup is a Python library designed for rapidly setting up
4849screen-scraping projects. It offers Pythonic idioms for navigating,
4850searching, and modifying a parse tree, providing a toolkit for
4851dissecting a document and extracting what you need. It automatically
4852converts incoming documents to Unicode and outgoing documents to UTF-8.")
4853 (license license:expat)
4854 (properties `((python2-variant . ,(delay python2-beautifulsoup4))))))
4855
4856(define-public python2-beautifulsoup4
4857 (package
4858 (inherit (package-with-python2
4859 (strip-python2-variant python-beautifulsoup4)))
4860 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
4861
092e86f5
AE
4862(define-public python2-cssutils
4863 (package
4864 (name "python2-cssutils")
58d1d816 4865 (version "1.0.1")
092e86f5
AE
4866 (source
4867 (origin
4868 (method url-fetch)
58d1d816 4869 (uri (pypi-uri "cssutils" version))
092e86f5 4870 (sha256
58d1d816
EF
4871 (base32
4872 "0qwha9x1wml2qmipbcz03gndnlwhzrjdvw9i09si247a90l8p8fq"))))
092e86f5
AE
4873 (build-system python-build-system)
4874 (native-inputs
4875 `(("python2-mock" ,python2-mock) ; for the tests
4876 ("unzip" ,unzip))) ; for unpacking the source
4877 (inputs
4878 `(("python2-setuptools" ,python2-setuptools)))
4879 (arguments
4880 `(#:python ,python-2 ; Otherwise tests fail with a syntax error.
4881 #:tests? #f ; The tests apparently download an external URL.
da6dd842 4882 ))
092e86f5
AE
4883 (home-page "http://cthedot.de/cssutils/")
4884 (synopsis
4885 "CSS Cascading Style Sheets library for Python")
4886 (description
4887 "Cssutils is a Python package for parsing and building CSS
4888Cascading Style Sheets. Currently it provides a DOM only and no rendering
4889options.")
3f641af0 4890 (license license:lgpl3+)))
880ff77c
AE
4891
4892(define-public python-cssselect
4893 (package
4894 (name "python-cssselect")
d5ccd9ab 4895 (version "0.9.2")
880ff77c
AE
4896 (source
4897 (origin
4898 (method url-fetch)
d5ccd9ab 4899 (uri (pypi-uri "cssselect" version))
880ff77c 4900 (sha256
d5ccd9ab
EF
4901 (base32
4902 "1xg6gbva1yswghiycmgincv6ab4bn7hpm720ndbj40h8xycmnfvi"))))
880ff77c
AE
4903 (build-system python-build-system)
4904 (inputs
4905 `(("python-setuptools" ,python-setuptools)))
4906 (arguments
4907 ;; tests fail with message
4908 ;; AttributeError: 'module' object has no attribute 'tests'
4909 `(#:tests? #f))
4910 (home-page
4911 "https://pythonhosted.org/cssselect/")
4912 (synopsis
4913 "CSS3 selector parser and translator to XPath 1.0")
4914 (description
4915 "Cssselect ia a Python module that parses CSS3 Selectors and translates
4916them to XPath 1.0 expressions. Such expressions can be used in lxml or
4917another XPath engine to find the matching elements in an XML or HTML document.")
3f641af0 4918 (license license:bsd-3)))
880ff77c
AE
4919
4920(define-public python2-cssselect
4921 (package-with-python2 python-cssselect))
60357f99
AE
4922
4923(define-public python-netifaces
4924 (package
4925 (name "python-netifaces")
4926 (version "0.10.4")
4927 (source
4928 (origin
4929 (method url-fetch)
4930 (uri (string-append
4931 "https://pypi.python.org/packages/source/n/netifaces/netifaces-"
4932 version
4933 ".tar.gz"))
4934 (sha256
4935 (base32
4936 "1plw237a4zib4z8s62g0mrs8gm3kjfrp5sxh6bbk9nl3rdls2mln"))))
4937 (build-system python-build-system)
4938 (inputs
4939 `(("python-setuptools" ,python-setuptools)))
4940 (home-page
4941 "https://bitbucket.org/al45tair/netifaces")
4942 (synopsis
4943 "Python module for portable network interface information")
4944 (description
4945 "Netifaces is a Python module providing information on network
4946interfaces in an easy and portable manner.")
4947 (license license:expat)))
4948
4949(define-public python2-netifaces
4950 (package-with-python2 python-netifaces))
92cb152b 4951
32f77c04
RW
4952(define-public python-networkx
4953 (package
4954 (name "python-networkx")
a4d9609c 4955 (version "1.11")
32f77c04
RW
4956 (source
4957 (origin
4958 (method url-fetch)
a4d9609c 4959 (uri (pypi-uri "networkx" version))
32f77c04 4960 (sha256
a4d9609c 4961 (base32 "1f74s56xb4ggixiq0vxyfxsfk8p20c7a099lpcf60izv1php03hd"))))
32f77c04
RW
4962 (build-system python-build-system)
4963 ;; python-decorator is needed at runtime
4964 (propagated-inputs
4965 `(("python-decorator" ,python-decorator)))
4966 (native-inputs
4967 `(("python-setuptools" ,python-setuptools)
4968 ("python-nose" ,python-nose)))
4969 (home-page "http://networkx.github.io/")
4970 (synopsis "Python module for creating and manipulating graphs and networks")
4971 (description
4972 "NetworkX is a Python package for the creation, manipulation, and study
4973of the structure, dynamics, and functions of complex networks.")
3f641af0 4974 (license license:bsd-3)))
32f77c04
RW
4975
4976(define-public python2-networkx
4977 (package-with-python2 python-networkx))
4978
92cb152b
RW
4979(define-public snakemake
4980 (package
4981 (name "snakemake")
4982 (version "3.2.1")
4983 (source
4984 (origin
4985 (method url-fetch)
4986 (uri (string-append
4987 "https://pypi.python.org/packages/source/s/snakemake/snakemake-"
4988 version ".tar.gz"))
4989 (sha256
4990 (base32 "0fi4b63sj60hvi7rfydvmz2icl4wj74djw5sn2gl8hxd02qw4b91"))))
4991 (build-system python-build-system)
4992 (inputs `(("python-setuptools" ,python-setuptools)))
4993 (home-page "https://bitbucket.org/johanneskoester/snakemake")
4994 (synopsis "Python-based execution environment for make-like workflows")
4995 (description
4996 "Snakemake aims to reduce the complexity of creating workflows by
4997providing a clean and modern domain specific specification language (DSL) in
4998Python style, together with a fast and comfortable execution environment.")
4999 (license license:expat)))
a1920bc9 5000
35de1fbd
RW
5001(define-public python-seaborn
5002 (package
5003 (name "python-seaborn")
fc899d4f 5004 (version "0.7.0")
35de1fbd
RW
5005 (source
5006 (origin
5007 (method url-fetch)
fc899d4f 5008 (uri (pypi-uri "seaborn" version))
35de1fbd 5009 (sha256
fc899d4f 5010 (base32 "0ibi3xsfm2kysph61mnfy0pf8d5rkgxgrdb0z9nbizgcgdsb5a0m"))))
35de1fbd
RW
5011 (build-system python-build-system)
5012 (propagated-inputs
5013 `(("python-pandas" ,python-pandas)
5014 ("python-matplotlib" ,python-matplotlib)
5015 ("python-scipy" ,python-scipy)))
35de1fbd
RW
5016 (home-page "http://stanford.edu/~mwaskom/software/seaborn/")
5017 (synopsis "Statistical data visualization")
5018 (description
5019 "Seaborn is a library for making attractive and informative statistical
5020graphics in Python. It is built on top of matplotlib and tightly integrated
5021with the PyData stack, including support for numpy and pandas data structures
5022and statistical routines from scipy and statsmodels.")
3f641af0 5023 (license license:bsd-3)
fc899d4f 5024 (properties `((python2-variant . ,(delay python2-seaborn))))))
35de1fbd
RW
5025
5026(define-public python2-seaborn
fc899d4f
EF
5027 (let ((base (package-with-python2 (strip-python2-variant python-seaborn))))
5028 (package
5029 (inherit base)
5030 (propagated-inputs `(("python2-pytz" ,python2-pytz)
5031 ,@(package-propagated-inputs base)))
5032 (native-inputs `(("python2-setuptools" ,python2-setuptools)
5033 ,@(package-native-inputs base))))))
35de1fbd 5034
90fc547f
RW
5035(define-public python-sympy
5036 (package
5037 (name "python-sympy")
5038 (version "0.7.6")
5039 (source
5040 (origin
5041 (method url-fetch)
5042 (uri (string-append
5043 "https://github.com/sympy/sympy/releases/download/sympy-"
5044 version "/sympy-" version ".tar.gz"))
5045 (sha256
5046 (base32 "19yp0gy4i7p4g6l3b8vaqkj9qj7yqb5kqy0qgbdagpzgkdz958yz"))))
5047 (build-system python-build-system)
5048 (native-inputs
5049 `(("python-setuptools" ,python-setuptools)))
5050 (home-page "http://www.sympy.org/")
5051 (synopsis "Python library for symbolic mathematics")
5052 (description
5053 "SymPy is a Python library for symbolic mathematics. It aims to become a
5054full-featured computer algebra system (CAS) while keeping the code as simple
5055as possible in order to be comprehensible and easily extensible.")
3f641af0 5056 (license license:bsd-3)))
90fc547f
RW
5057
5058(define-public python2-sympy
5059 (package-with-python2 python-sympy))
5060
e8c9b010
SR
5061(define-public python-q
5062 (package
5063 (name "python-q")
5064 (version "2.6")
5065 (source
5066 (origin
5067 (method url-fetch)
5068 (uri (pypi-uri "q" version))
5069 (sha256
5070 (base32
5071 "1mgfazh8fkizh6walra2zv885f3lcgr3nb02v1frfm4p8ddcy3yy"))))
5072 (build-system python-build-system)
5073 (home-page "https://github.com/zestyping/q")
5074 (synopsis "Quick-and-dirty debugging output for tired programmers")
5075 (description
5076 "q is a Python module for \"print\" style of debugging Python code. It
5077provides convenient short API for print out of values, tracebacks, and
5078falling into the Python interpreter.")
5079 (license license:asl2.0)
5080 (properties `((python2-variant . ,(delay python2-q))))))
5081
5082(define-public python2-q
5083 (let ((base (package-with-python2 (strip-python2-variant python-q))))
5084 (package
5085 (inherit base)
5086 (native-inputs
5087 `(("python2-setuptools" ,python2-setuptools)
5088 ,@(package-native-inputs base))))))
5089
a1920bc9
FB
5090(define-public python-testlib
5091 (package
5092 (name "python-testlib")
5093 (version "0.6.5")
5094 (source
5095 (origin
5096 (method url-fetch)
5097 (uri (string-append
5098 "https://pypi.python.org/packages/source/t/testlib/testlib-"
5099 version ".zip"))
5100 (sha256
5101 (base32 "1mz26cxn4x8bbgv0rn0mvj2z05y31rkc8009nvdlb3lam5b4mj3y"))))
5102 (build-system python-build-system)
5103 (inputs
5104 `(("python-setuptools" ,python-setuptools)))
5105 (native-inputs
5106 `(("unzip" ,unzip)))
5107 (arguments
5108 `(#:phases
5109 (alist-replace
5110 'unpack
5111 (lambda* (#:key inputs outputs #:allow-other-keys)
5112 (let ((unzip (string-append (assoc-ref inputs "unzip")
5113 "/bin/unzip"))
5114 (source (assoc-ref inputs "source")))
5115 (and (zero? (system* unzip source))
5116 (chdir (string-append "testlib-" ,version)))))
5117 %standard-phases)))
5118 (synopsis "Python micro test suite harness")
5119 (description "A micro unittest suite harness for Python.")
5120 (home-page "https://github.com/trentm/testlib")
1cb9c006 5121 (license license:expat)))
a1920bc9
FB
5122
5123(define-public python2-testlib
5124 (package-with-python2 python-testlib))
db62afa5
LC
5125
5126(define-public python2-xlib
5127 (package
5128 (name "python2-xlib")
5129 (version "0.14")
5130 (source (origin
5131 (method url-fetch)
de67e922
LF
5132 (uri (string-append "mirror://sourceforge/python-xlib/python-xlib"
5133 "/" version "/"
db62afa5
LC
5134 "python-xlib-" version ".tar.gz"))
5135 (sha256
5136 (base32
5137 "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7"))))
5138 (build-system python-build-system)
5139 (arguments
5140 `(#:python ,python-2 ;Python 2 only
5141 #:tests? #f)) ;no tests
5142 (inputs
5143 `(("python-setuptools" ,python-setuptools)))
5144 (home-page "http://python-xlib.sourceforge.net/")
5145 (synopsis "Python X11 client library")
5146 (description
5147 "The Python X Library is intended to be a fully functional X client
5148library for Python programs. It is useful to implement low-level X clients.
5149It is written entirely in Python.")
3f641af0 5150 (license license:gpl2+)))
0234ca06
DT
5151
5152(define-public python-singledispatch
5153 (package
5154 (name "python-singledispatch")
5155 (version "3.4.0.3")
5156 (source
5157 (origin
5158 (method url-fetch)
bdb67d84 5159 (uri (pypi-uri "singledispatch" version))
0234ca06
DT
5160 (sha256
5161 (base32
5162 "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv"))))
5163 (build-system python-build-system)
5164 (native-inputs
5165 `(("python-setuptools" ,python-setuptools)))
bdb67d84 5166 (inputs
0234ca06
DT
5167 `(("python-six" ,python-six)))
5168 (home-page
5169 "http://docs.python.org/3/library/functools.html#functools.singledispatch")
5170 (synopsis "Backport of singledispatch feature from Python 3.4")
5171 (description
5172 "This library brings functools.singledispatch from Python 3.4 to Python
51732.6-3.3.")
5174 (license license:expat)))
5175
5176(define-public python2-singledispatch
5177 (package-with-python2 python-singledispatch))
feaae484 5178
310d218f
RW
5179(define-public python-tornado
5180 (package
5181 (name "python-tornado")
a724924b 5182 (version "4.3")
310d218f
RW
5183 (source
5184 (origin
5185 (method url-fetch)
a724924b 5186 (uri (pypi-uri "tornado" version))
310d218f 5187 (sha256
a724924b 5188 (base32 "1gzgwayl6hmc9jfcl88bni4jcsk2jcca9dn1rvrfsvnijcjx7hn9"))))
310d218f 5189 (build-system python-build-system)
310d218f 5190 (native-inputs
b455439b
EF
5191 `(("python-certifi" ,python-certifi)))
5192 (inputs
5193 `(("python-backports-abc" ,python-backports-abc)))
f4a4a718 5194 (home-page "http://www.tornadoweb.org/")
310d218f
RW
5195 (synopsis "Python web framework and asynchronous networking library")
5196 (description
5197 "Tornado is a Python web framework and asynchronous networking library,
5198originally developed at FriendFeed. By using non-blocking network I/O,
5199Tornado can scale to tens of thousands of open connections, making it ideal
5200for long polling, WebSockets, and other applications that require a long-lived
5201connection to each user.")
3f641af0 5202 (license license:asl2.0)
b455439b 5203 (properties `((python2-variant . ,(delay python2-tornado))))))
310d218f
RW
5204
5205(define-public python2-tornado
b455439b 5206 (let ((tornado (package-with-python2 (strip-python2-variant python-tornado))))
310d218f
RW
5207 (package (inherit tornado)
5208 (inputs
5209 `(("python2-backport-ssl-match-hostname"
5210 ,python2-backport-ssl-match-hostname)
b455439b
EF
5211 ("python2-singledispatch" ,python2-singledispatch)
5212 ,@(package-inputs tornado)))
5213 (native-inputs
5214 `(("python2-setuptools" ,python2-setuptools)
5215 ,@(package-native-inputs tornado))))))
310d218f 5216
6b59fc10
EF
5217;; the python- version can be removed with python-3.5
5218(define-public python-backports-abc
5219 (package
5220 (name "python-backports-abc")
5221 (version "0.4")
5222 (source
5223 (origin
5224 (method url-fetch)
5225 (uri (pypi-uri "backports_abc" version))
5226 (sha256
5227 (base32
5228 "19fh75lni9pb673n2fn505m1rckm0af0szcv5xx1qm1xpa940glb"))))
5229 (build-system python-build-system)
5230 (inputs
5231 `(("python-setuptools" ,python-setuptools)))
5232 (home-page "https://github.com/cython/backports_abc")
66e07664 5233 (synopsis "Backport of additions to the 'collections.abc' module")
6b59fc10
EF
5234 (description
5235 "Python-backports-abc provides a backport of additions to the
5236'collections.abc' module in Python-3.5.")
3f641af0 5237 (license license:psfl)))
6b59fc10
EF
5238
5239(define-public python2-backports-abc
5240 (package-with-python2 python-backports-abc))
5241
feaae484
SB
5242(define-public python-waf
5243 (package
5244 (name "python-waf")
f0e8d85e 5245 (version "1.9.1")
feaae484
SB
5246 (source (origin
5247 (method url-fetch)
5248 (uri (string-append "https://waf.io/"
5249 "waf-" version ".tar.bz2"))
5250 (sha256
5251 (base32
f0e8d85e 5252 "1nc4qaqx2vsanlpp9mcwvf91xjqpkvcc6fcxd5sb4fwvaxamw5v6"))))
feaae484
SB
5253 (build-system python-build-system)
5254 (arguments
5255 '(#:phases
5256 (modify-phases %standard-phases
5257 (replace 'build
5258 (lambda _
5259 (zero? (begin
5260 (system* "python" "waf-light" "configure")
5261 (system* "python" "waf-light" "build")))))
5262 (replace 'check
5263 (lambda _
5264 (zero? (system* "python" "waf" "--version"))))
5265 (replace 'install
5266 (lambda _
5267 (copy-file "waf" %output))))))
5268 (home-page "https://waf.io/")
5269 (synopsis "Python-based build system")
5270 (description
5271 "Waf is a Python-based framework for configuring, compiling and installing
5272applications.")
3f641af0 5273 (license license:bsd-3)))
feaae484
SB
5274
5275(define-public python2-waf
5276 (package-with-python2 python-waf))
45203542
RW
5277
5278(define-public python-pyzmq
5279 (package
5280 (name "python-pyzmq")
3655ee76 5281 (version "15.1.0")
45203542
RW
5282 (source
5283 (origin
5284 (method url-fetch)
3655ee76 5285 (uri (pypi-uri "pyzmq" version))
45203542 5286 (sha256
3655ee76 5287 (base32 "13fhwnlvsvxv72kfhqbpn6qi7msh8mc8377mpabv32skk2cjfnxx"))))
45203542
RW
5288 (build-system python-build-system)
5289 (arguments
5290 `(#:configure-flags
5291 (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq")))
5292 ;; FIXME: You must build pyzmq with 'python setup.py build_ext
5293 ;; --inplace' for 'python setup.py test' to work.
5294 #:tests? #f))
5295 (inputs
5296 `(("zeromq" ,zeromq)))
5297 (native-inputs
5298 `(("pkg-config" ,pkg-config)
5299 ("python-nose" ,python-nose)
5300 ("python-setuptools" ,python-setuptools)))
5301 (home-page "http://github.com/zeromq/pyzmq")
5302 (synopsis "Python bindings for 0MQ")
5303 (description
5304 "PyZMQ is the official Python binding for the ZeroMQ messaging library.")
3f641af0 5305 (license license:bsd-4)))
45203542
RW
5306
5307(define-public python2-pyzmq
5308 (package-with-python2 python-pyzmq))
d889e6c4
CR
5309
5310(define-public python-pep8
5311 (package
5312 (name "python-pep8")
db251311 5313 (version "1.7.0")
d889e6c4
CR
5314 (source
5315 (origin
5316 (method url-fetch)
db251311 5317 (uri (pypi-uri "pep8" version))
d889e6c4
CR
5318 (sha256
5319 (base32
db251311 5320 "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1"))))
d889e6c4
CR
5321 (build-system python-build-system)
5322 (inputs
5323 `(("python-setuptools" ,python-setuptools)))
5324 (home-page "http://pep8.readthedocs.org/")
5325 (synopsis "Python style guide checker")
5326 (description
5327 "This tools checks Python code against some of the style conventions in
5328PEP 8.")
5329 (license license:expat)))
5330
5331(define-public python2-pep8
5332 (package-with-python2 python-pep8))
e31d7f44
CR
5333
5334(define-public python-pyflakes
5335 (package
5336 (name "python-pyflakes")
2abc3972 5337 (version "1.0.0")
e31d7f44
CR
5338 (source
5339 (origin
5340 (method url-fetch)
2abc3972 5341 (uri (pypi-uri "pyflakes" version))
e31d7f44
CR
5342 (sha256
5343 (base32
2abc3972 5344 "0qs2sgqszq7wcplis8509wk2ygqcrwzbs1ghfj3svvivq2j377pk"))))
e31d7f44
CR
5345 (build-system python-build-system)
5346 (inputs
5347 `(("python-setuptools" ,python-setuptools)))
5348 (home-page
5349 "https://github.com/pyflakes/pyflakes")
5350 (synopsis "Passive checker of Python programs")
5351 (description
5352 "Pyflakes statically checks Python source code for common errors.")
5353 (license license:expat)))
a59e017c 5354
7261d9eb
CR
5355(define-public python2-pyflakes
5356 (package-with-python2 python-pyflakes))
5357
a59e017c
CR
5358(define-public python-mccabe
5359 (package
5360 (name "python-mccabe")
c6ebd40d 5361 (version "0.4.0")
a59e017c
CR
5362 (source
5363 (origin
5364 (method url-fetch)
c6ebd40d 5365 (uri (pypi-uri "mccabe" version))
a59e017c
CR
5366 (sha256
5367 (base32
c6ebd40d 5368 "0yr08a36h8lqlif10l4xcikbbig7q8f41gqywir7rrvnv3mi4aws"))))
a59e017c
CR
5369 (build-system python-build-system)
5370 (inputs
c6ebd40d
EF
5371 `(("python-pytest" ,python-pytest)
5372 ("python-pytest-runner" ,python-pytest-runner)
5373 ("python-setuptools" ,python-setuptools)))
a59e017c
CR
5374 (home-page "https://github.com/flintwork/mccabe")
5375 (synopsis "McCabe checker, plugin for flake8")
5376 (description
5377 "This package provides a Flake8 plug-in to compute the McCabe cyclomatic
5378complexity of Python source code.")
7362371d 5379 (license license:expat)))
a59e017c
CR
5380
5381(define-public python2-mccabe
5382 (package-with-python2 python-mccabe))
e8df8f47 5383
7477fbb1
CR
5384(define-public python-mccabe-0.2.1
5385 (package (inherit python-mccabe)
5386 (version "0.2.1")
5387 (source
5388 (origin
5389 (method url-fetch)
5390 (uri (pypi-uri "mccabe" version))
5391 (sha256
5392 (base32
c6ebd40d 5393 "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs"))))
b3546174 5394 (inputs `(("python-setuptools" ,python-setuptools)))))
7477fbb1
CR
5395
5396(define-public python2-mccabe-0.2.1
5397 (package-with-python2 python-mccabe-0.2.1))
5398
e8df8f47
CR
5399;; Flake8 2.4.1 requires an older version of pep8.
5400;; This should be removed ASAP.
5401(define-public python-pep8-1.5.7
5402 (package (inherit python-pep8)
5403 (version "1.5.7")
5404 (source
5405 (origin
5406 (method url-fetch)
5407 (uri (string-append
5408 "https://pypi.python.org/packages/source/p/pep8/pep8-"
5409 version
5410 ".tar.gz"))
5411 (sha256
5412 (base32
5413 "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m"))))))
5414
5415(define-public python2-pep8-1.5.7
5416 (package-with-python2 python-pep8-1.5.7))
5417
5418;; Flake8 2.4.1 requires an older version of pyflakes.
5419;; This should be removed ASAP.
5420(define-public python-pyflakes-0.8.1
5421 (package (inherit python-pyflakes)
5422 (version "0.8.1")
5423 (source
5424 (origin
5425 (method url-fetch)
5426 (uri (string-append
5427 "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-"
5428 version
5429 ".tar.gz"))
5430 (sha256
5431 (base32
5432 "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z"))))))
5433
5434(define-public python2-pyflakes-0.8.1
7261d9eb 5435 (package-with-python2 python-pyflakes-0.8.1))
e8df8f47
CR
5436
5437(define-public python-flake8
5438 (package
5439 (name "python-flake8")
43789136 5440 (version "2.5.4")
e8df8f47
CR
5441 (source
5442 (origin
5443 (method url-fetch)
1b995533 5444 (uri (pypi-uri "flake8" version))
e8df8f47
CR
5445 (sha256
5446 (base32
43789136 5447 "0bs9cz4fr99r2rwig1b8jwaadl1nan7kgpdzqwj0bwbckwbmh7nc"))))
e8df8f47
CR
5448 (build-system python-build-system)
5449 (inputs
5450 `(("python-setuptools" ,python-setuptools)
43789136
EF
5451 ("python-pep8" ,python-pep8)
5452 ("python-pyflakes" ,python-pyflakes)
e8df8f47
CR
5453 ("python-mccabe" ,python-mccabe)
5454 ("python-mock" ,python-mock)
5455 ("python-nose" ,python-nose)))
5456 (home-page "https://gitlab.com/pycqa/flake8")
5457 (synopsis
5458 "The modular source code checker: pep8, pyflakes and co")
5459 (description
5460 "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.")
5461 (license license:expat)))
5462
5463(define-public python2-flake8
5464 (package-with-python2 python-flake8))
61b9ac53 5465
abf21efc
CR
5466;; This will only be needed by the python-hacking package and will not be
5467;; necessary once python-hacking > 0.10.2 is released.
5468(define-public python-flake8-2.2.4
5469 (package (inherit python-flake8)
5470 (inputs
5471 `(("python-setuptools" ,python-setuptools)
5472 ("python-pep8" ,python-pep8-1.5.7)
5473 ("python-pyflakes" ,python-pyflakes-0.8.1)
5474 ("python-mccabe" ,python-mccabe-0.2.1)
5475 ("python-mock" ,python-mock)
5476 ("python-nose" ,python-nose)))
5477 (version "2.2.4")
5478 (source
5479 (origin
5480 (method url-fetch)
5481 (uri (pypi-uri "flake8" version))
5482 (sha256
5483 (base32
5484 "1r9wsry4va45h1rck5hxd3vzsg2q3y6lnl6pym1bxvz8ry19jwx8"))))))
5485
5486(define-public python2-flake8-2.2.4
5487 (package-with-python2 python-flake8-2.2.4))
5488
61b9ac53
FB
5489(define-public python-mistune
5490 (package
5491 (name "python-mistune")
5492 (version "0.7")
5493 (source
5494 (origin
5495 (method url-fetch)
5496 (uri (string-append
5497 "https://pypi.python.org/packages/source/m/mistune/mistune-"
5498 version
5499 ".tar.gz"))
5500 (sha256
5501 (base32
5502 "17zqjp9m4d1w3jf2rbbq5xshcw24q1vlcv24gkgfqqyyymajxahx"))))
5503 (build-system python-build-system)
5504 (inputs
5505 `(("python-setuptools" ,python-setuptools)
5506 ("python-nose" ,python-nose)
5507 ("python-cython" ,python-cython)))
5508 (home-page "https://github.com/lepture/mistune")
5509 (synopsis "Markdown parser in pure Python")
5510 (description "This package provides a fast markdown parser in pure
5511Python.")
3f641af0 5512 (license license:bsd-3)))
61b9ac53
FB
5513
5514(define-public python2-mistune
5515 (package-with-python2 python-mistune))
6d992d07 5516
b9893908
EE
5517(define-public python-markdown
5518 (package
5519 (name "python-markdown")
5520 (version "2.6.5")
5521 (source
5522 (origin
5523 (method url-fetch)
5524 (uri (pypi-uri "Markdown" version))
5525 (sha256
5526 (base32
5527 "0q758a3fiiawr20b3hhjfs677cwj6xi284yb7xspcvv0fdicz54d"))))
5528 (build-system python-build-system)
5529 (arguments
5530 `(#:phases
5531 (modify-phases %standard-phases
5532 (replace 'check
5533 (lambda _
5534 (zero? (system* "python" "run-tests.py")))))))
5535 (native-inputs
5536 `(("python-nose" ,python-nose)
5537 ("python-pyyaml" ,python-pyyaml)))
5538 (home-page "https://pythonhosted.org/Markdown/")
5539 (synopsis "Python implementation of Markdown")
5540 (description
5541 "This package provides a Python implementation of John Gruber's
5542Markdown. The library features international input, various Markdown
5543extensions, and several HTML output formats. A command line wrapper
5544markdown_py is also provided to convert Markdown files to HTML.")
3f641af0 5545 (license license:bsd-3)))
b9893908
EE
5546
5547(define-public python2-markdown
5548 (package-with-python2 python-markdown))
5549
6d992d07
FB
5550(define-public python-ptyprocess
5551 (package
5552 (name "python-ptyprocess")
5553 (version "0.5")
5554 (source
5555 (origin
5556 (method url-fetch)
5557 (uri (string-append
5558 "https://pypi.python.org/packages/source/p/ptyprocess/ptyprocess-"
5559 version ".tar.gz"))
5560 (sha256
5561 (base32
5562 "0nggns5kikn32yyda2zrj1xdmh49pi3v0drggcdwljbv36r8zdyw"))))
5563 (build-system python-build-system)
5564 (inputs
5565 `(("python-setuptools" ,python-setuptools)
5566 ("python-nose" ,python-nose)))
5567 (arguments
5568 `(#:phases
5569 (modify-phases %standard-phases
5570 (replace 'check
5571 (lambda _
5572 (zero? (system* "nosetests")))))))
5573 (home-page "https://github.com/pexpect/ptyprocess")
5574 (synopsis "Run a subprocess in a pseudo terminal")
5575 (description
5576 "This package provides a Python library used to launch a subprocess in a
5577pseudo terminal (pty), and interact with both the process and its pty.")
3f641af0 5578 (license license:isc)))
6d992d07
FB
5579
5580(define-public python2-ptyprocess
5581 (package-with-python2 python-ptyprocess))
4aadb1df
FB
5582
5583(define-public python-terminado
5584 (package
5585 (name "python-terminado")
783fb0a3 5586 (version "0.6")
4aadb1df
FB
5587 (source
5588 (origin
5589 (method url-fetch)
783fb0a3 5590 (uri (pypi-uri "terminado" version))
4aadb1df
FB
5591 (sha256
5592 (base32
783fb0a3 5593 "09h1kwi86g5mrk14s4pgbhshd602zry29lnpxamcqz864kva22rc"))))
4aadb1df
FB
5594 (build-system python-build-system)
5595 (propagated-inputs
5596 `(("python-tornado" ,python-tornado)
5597 ("python-ptyprocess" ,python-ptyprocess)))
783fb0a3
EF
5598 (native-inputs
5599 `(("python-nose" ,python-nose)))
4aadb1df
FB
5600 (arguments
5601 `(#:phases
5602 (modify-phases %standard-phases
5603 (replace 'check
5604 (lambda _
5605 (zero? (system* "nosetests")))))))
5606 (home-page "https://github.com/takluyver/terminado")
5607 (synopsis "Terminals served to term.js using Tornado websockets")
5608 (description "This package provides a Tornado websocket backend for the
5609term.js Javascript terminal emulator library.")
3f641af0 5610 (license license:bsd-2)
783fb0a3 5611 (properties `((python2-variant . ,(delay python2-terminado))))))
4aadb1df
FB
5612
5613(define-public python2-terminado
783fb0a3 5614 (let ((terminado (package-with-python2 (strip-python2-variant python-terminado))))
4aadb1df 5615 (package (inherit terminado)
783fb0a3
EF
5616 (propagated-inputs
5617 `(("python2-backport-ssl-match-hostname"
5618 ,python2-backport-ssl-match-hostname)
5619 ,@(package-propagated-inputs terminado)))
5620 (native-inputs
5621 `(("python2-setuptools" ,python2-setuptools)
5622 ,@(package-native-inputs terminado))))))
5faa5ce4 5623
d582eaac
SB
5624(define-public python-fonttools
5625 (package
5626 (name "python-fonttools")
5627 (version "2.5")
5628 (source (origin
5629 (method url-fetch)
5630 (uri (string-append
5631 "https://pypi.python.org/packages/source/F/FontTools/"
5632 "fonttools-" version ".tar.gz"))
5633 (sha256
5634 (base32
5635 "08ay3x4ijarwhl60gqx2i9jzq6pxs20p4snc2d1q5jagh4rn39lb"))))
5636 (build-system python-build-system)
5637 (arguments '(#:test-target "check"))
5638 (propagated-inputs
5639 ;; XXX: module not found if setuptools is not available.
5640 `(("python-setuptools" ,python-setuptools)))
5641 (home-page "http://github.com/behdad/fonttools")
5642 (synopsis "Tools to manipulate font files")
5643 (description
5644 "FontTools/TTX is a library to manipulate font files from Python. It
5645supports reading and writinfg of TrueType/OpenType fonts, reading and writing
5646of AFM files, reading (and partially writing) of PS Type 1 fonts. The package
5647also contains a tool called “TTX” which converts TrueType/OpenType fonts to and
5648from an XML-based format.")
3f641af0
DC
5649 (license (license:non-copyleft
5650 "file://LICENSE.txt"
5651 "See LICENSE.txt in the distribution."))))
d582eaac
SB
5652
5653(define-public python2-fonttools
5654 (package-with-python2 python-fonttools))
75710da6 5655
5faa5ce4
RW
5656(define-public python-ly
5657 (package
5658 (name "python-ly")
5135354f 5659 (version "0.9.4")
5faa5ce4
RW
5660 (source
5661 (origin
5662 (method url-fetch)
5135354f
RW
5663 (uri (string-append "https://pypi.python.org/packages/57/4f/"
5664 "889579244947368f28eda66b782331b1e75f83fd72e63f9ece93cd7a18f9"
5665 "/python-ly-" version ".tar.gz"))
5faa5ce4
RW
5666 (sha256
5667 (base32
5135354f 5668 "0g6n288l83sfwavxh1aryi0aqvsr3sp7v6f903mckwqa4scpky62"))))
5faa5ce4
RW
5669 (build-system python-build-system)
5670 (native-inputs
5671 `(("python-setuptools" ,python-setuptools)))
5672 (synopsis "Tool and library for manipulating LilyPond files")
5673 (description "This package provides a Python library to parse, manipulate
5674or create documents in LilyPond format. A command line program ly is also
5675provided that can be used to do various manipulations with LilyPond files.")
5676 (home-page "https://pypi.python.org/pypi/python-ly")
3f641af0 5677 (license license:gpl2+)))
7e7b27d9
CR
5678
5679(define-public python-appdirs
5680 (package
5681 (name "python-appdirs")
5682 (version "1.4.0")
5683 (source
5684 (origin
5685 (method url-fetch)
5686 (uri (string-append
5687 "https://pypi.python.org/packages/source/a/appdirs/appdirs-"
5688 version
5689 ".tar.gz"))
5690 (sha256
5691 (base32
5692 "1iddva7v3fq0aqzsahkazxr7vpw28mqcrsy818z4wyiqnkplbhlg"))))
5693 (build-system python-build-system)
5694 (inputs
5695 `(("python-setuptools" ,python-setuptools)))
5696 (home-page "http://github.com/ActiveState/appdirs")
5697 (synopsis
5698 "Determine platform-specific dirs, e.g. a \"user data dir\"")
5699 (description
5700 "This module provides a portable way of finding out where user data
5701should be stored on various operating systems.")
5702 (license license:expat)))
5703
5704(define-public python2-appdirs
5705 (package-with-python2 python-appdirs))
89b2e0b0
LF
5706
5707(define-public python-llfuse
5708 (package
5709 (name "python-llfuse")
e36ace36 5710 (version "1.1.1")
89b2e0b0
LF
5711 (source (origin
5712 (method url-fetch)
5713 (uri (string-append
5714 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5715 "llfuse-" version ".tar.bz2"))
5716 (sha256
5717 (base32
e36ace36 5718 "0v6vj9mb286njgd1szg9hz2qdh5f3vkhsvajripfcqg458av310v"))))
89b2e0b0
LF
5719 (build-system python-build-system)
5720 (inputs
5721 `(("fuse" ,fuse)
5722 ("attr" ,attr)))
5723 (native-inputs
5724 `(("pkg-config" ,pkg-config)
5725 ("python-setuptools" ,python-setuptools)))
5726 (synopsis "Python bindings for FUSE")
5727 (description
5728 "Python-LLFUSE is a set of Python bindings for the low level FUSE API.")
5729 (home-page "https://bitbucket.org/nikratio/python-llfuse/")
3f641af0 5730 (license license:lgpl2.0+)
cd0569c4 5731 (properties `((python2-variant . ,(delay python2-llfuse))))))
89b2e0b0
LF
5732
5733(define-public python2-llfuse
cd0569c4
LF
5734 (package (inherit (package-with-python2
5735 (strip-python2-variant python-llfuse)))
5736 (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2)))))
5737
5738;; For attic-0.16
5739(define-public python-llfuse-0.41
5740 (package (inherit python-llfuse)
229b3661 5741 (version "0.41.1")
cd0569c4
LF
5742 (source (origin
5743 (method url-fetch)
5744 (uri (string-append
5745 "https://bitbucket.org/nikratio/python-llfuse/downloads/"
5746 "llfuse-" version ".tar.bz2"))
5747 (sha256
5748 (base32
229b3661 5749 "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa"))))
cd0569c4
LF
5750 ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat)
5751 ;; licensed. The rest of the package is licensed under LGPL2.0 or later.
3f641af0 5752 (license (list license:expat license:lgpl2.0+))))
641c9871
LF
5753
5754(define-public python-msgpack
5755 (package
5756 (name "python-msgpack")
aed625bd 5757 (version "0.4.8")
641c9871
LF
5758 (source (origin
5759 (method url-fetch)
ae831df4 5760 (uri (pypi-uri "msgpack-python" version))
641c9871
LF
5761 (sha256
5762 (base32
aed625bd 5763 "11pqk5braa6wndpnr1dhg64js82vjgxnm0lzy73rwl831zgijaqs"))))
641c9871 5764 (build-system python-build-system)
641c9871
LF
5765 (synopsis "MessagePack (de)serializer")
5766 (description "MessagePack is a fast, compact binary serialization format,
5767suitable for similar data to JSON. This package provides CPython bindings for
5768reading and writing MessagePack data.")
5769 (home-page "https://pypi.python.org/pypi/msgpack-python/")
3f641af0 5770 (license license:asl2.0)
bd74be7b
LF
5771 (properties `((python2-variant . ,(delay python2-msgpack))))))
5772
5773(define-public python2-msgpack
5774 (package (inherit (package-with-python2
5775 (strip-python2-variant python-msgpack)))
5776 (native-inputs
5777 `(("python2-setuptools" ,python2-setuptools)))))
641c9871
LF
5778
5779(define-public python2-msgpack
5780 (package-with-python2 python-msgpack))
6e5e39f4
CR
5781
5782(define-public python-netaddr
5783 (package
5784 (name "python-netaddr")
5785 (version "0.7.18")
5786 (source
5787 (origin
5788 (method url-fetch)
5789 (uri (string-append
5790 "https://pypi.python.org/packages/source/n/netaddr/netaddr-"
5791 version
5792 ".tar.gz"))
5793 (sha256
5794 (base32
5795 "06dxjlbcicq7q3vqy8agq11ra01kvvd47j4mk6dmghjsyzyckxd1"))))
5796 (build-system python-build-system)
5797 (arguments `(#:tests? #f)) ;; No tests.
5798 (inputs
5799 `(("python-setuptools" ,python-setuptools)))
5800 (home-page "https://github.com/drkjam/netaddr/")
5801 (synopsis "Pythonic manipulation of network addresses")
5802 (description
5803 "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI
5804and MAC network addresses.")
3f641af0 5805 (license license:bsd-3)))
6e5e39f4
CR
5806
5807(define-public python2-netaddr
5808 (package-with-python2 python-netaddr))
8c692a52
CR
5809
5810(define-public python-wrapt
5811 (package
5812 (name "python-wrapt")
5813 (version "1.10.5")
5814 (source
5815 (origin
5816 (method url-fetch)
5817 (uri (string-append
5818 "https://pypi.python.org/packages/source/w/wrapt/wrapt-"
5819 version
5820 ".tar.gz"))
5821 (sha256
5822 (base32
5823 "0cq8rlpzkxzk48b50yrfhzn1d1hrq4gjcdqlrgq4v5palgiv9jwr"))))
5824 (build-system python-build-system)
5825 (arguments
5826 ;; Tests are not included in the tarball, they are only available in the
5827 ;; git repository.
5828 `(#:tests? #f))
5829 (inputs
5830 `(("python-setuptools" ,python-setuptools)))
5831 (home-page "https://github.com/GrahamDumpleton/wrapt")
5832 (synopsis "Module for decorators, wrappers and monkey patching")
5833 (description
5834 "The aim of the wrapt module is to provide a transparent object proxy for
5835 Python, which can be used as the basis for the construction of function
5836 wrappers and decorator functions.")
3f641af0 5837 (license license:bsd-2)))
8c692a52
CR
5838
5839(define-public python2-wrapt
5840 (package-with-python2 python-wrapt))
b85c85be
CR
5841
5842(define-public python-iso8601
5843 (package
5844 (name "python-iso8601")
fe84bc9a 5845 (version "0.1.11")
b85c85be
CR
5846 (source
5847 (origin
5848 (method url-fetch)
fe84bc9a 5849 (uri (pypi-uri "iso8601" version))
b85c85be 5850 (sha256
fe84bc9a
EF
5851 (base32
5852 "0c7gh3lsdjds262h0v1sqc66l7hqgfwbakn96qrhdbl0i3vm5yz8"))))
b85c85be
CR
5853 (build-system python-build-system)
5854 (inputs
5855 `(("python-setuptools" ,python-setuptools)))
5856 (home-page "https://bitbucket.org/micktwomey/pyiso8601")
5857 (synopsis "Module to parse ISO 8601 dates")
5858 (description
5859 "This module parses the most common forms of ISO 8601 date strings (e.g.
5860@code{2007-01-14T20:34:22+00:00}) into @code{datetime} objects.")
5861 (license license:expat)))
5862
5863(define-public python2-iso8601
5864 (package-with-python2 python-iso8601))
5e412b63
CR
5865
5866(define-public python-monotonic
5867 (package
5868 (name "python-monotonic")
5869 (version "0.3")
5870 (source
5871 (origin
5872 (method url-fetch)
5873 (uri (string-append
5874 "https://pypi.python.org/packages/source/m/monotonic/monotonic-"
5875 version
5876 ".tar.gz"))
5877 (sha256
5878 (base32
5879 "0yz0bcbwx8r2c01czzfpbrxddynxyk9k95jj8h6sgcb7xmfvl998"))))
5880 (build-system python-build-system)
5881 (inputs
5882 `(("python-setuptools" ,python-setuptools)))
5883 (home-page "https://github.com/atdt/monotonic")
5884 (synopsis "Implementation of time.monotonic() for Python 2 & < 3.3")
5885 (description
5886 "This module provides a monotonic() function which returns the value (in
5887fractional seconds) of a clock which never goes backwards.")
3f641af0 5888 (license license:asl2.0)))
5e412b63
CR
5889
5890(define-public python2-monotonic
5891 (package-with-python2 python-monotonic))
de34afac
CR
5892
5893(define-public python-webob
5894 (package
5895 (name "python-webob")
b8834c21 5896 (version "1.5.1")
de34afac
CR
5897 (source
5898 (origin
5899 (method url-fetch)
b8834c21 5900 (uri (pypi-uri "WebOb" version))
de34afac
CR
5901 (sha256
5902 (base32
b8834c21 5903 "02bhhzijfhv8hmi1i54d4b0v43liwhnywhflvxsv4x3zax9s3afq"))))
de34afac
CR
5904 (build-system python-build-system)
5905 (inputs
5906 `(("python-nose" ,python-nose)
5907 ("python-setuptools" ,python-setuptools)))
5908 (home-page "http://webob.org/")
5909 (synopsis "WSGI request and response object")
5910 (description
5911 "WebOb provides wrappers around the WSGI request environment, and an
5912object to help create WSGI responses.")
5913 (license license:expat)))
5914
5915(define-public python2-webob
5916 (package-with-python2 python-webob))
350ba0a3 5917
02a8a187
BW
5918(define-public python-xlrd
5919 (package
5920 (name "python-xlrd")
c2ad4d70 5921 (version "1.0.0")
02a8a187
BW
5922 (source (origin
5923 (method url-fetch)
e775f48e 5924 (uri (pypi-uri "xlrd" version))
02a8a187
BW
5925 (sha256
5926 (base32
c2ad4d70 5927 "0s8hjiz01vbhy85xalrz0qlsmd9ypf36zjqrf97hh984spapvy0g"))))
02a8a187
BW
5928 (build-system python-build-system)
5929 (arguments
5930 `(#:phases
5931 (modify-phases %standard-phases
c2ad4d70 5932 ;; Current test in setup.py does not work as of 1.0.0, so use nose to
02a8a187
BW
5933 ;; run tests instead for now.
5934 (replace 'check (lambda _ (zero? (system* "nosetests")))))))
5935 (native-inputs `(("python-nose" ,python-nose)
5936 ("python-setuptools" ,python-setuptools)))
5937 (home-page "http://www.python-excel.org/")
5938 (synopsis "Library for extracting data from Excel files")
5939 (description "This packages provides a library to extract data from
c598e35c 5940spreadsheets using Microsoft Excel proprietary file formats @samp{.xls} and
02a8a187
BW
5941@samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is
5942Unicode-aware. It is not intended as an end-user tool.")
3f641af0 5943 (license license:bsd-3)))
02a8a187
BW
5944
5945(define-public python2-xlrd
5946 (package-with-python2 python-xlrd))
5947
350ba0a3
CR
5948(define-public python-prettytable
5949 (package
5950 (name "python-prettytable")
5951 (version "0.7.2")
5952 (source
5953 (origin
5954 (method url-fetch)
5955 (uri (string-append
5956 "https://pypi.python.org/packages/source/P/PrettyTable/"
5957 "prettytable-" version ".tar.bz2"))
5958 (sha256
5959 (base32
5960 "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45"))))
5961 (build-system python-build-system)
5962 (inputs
5963 `(("python-setuptools" ,python-setuptools)))
5964 (home-page "http://code.google.com/p/prettytable/")
5965 (synopsis "Display tabular data in an ASCII table format")
5966 (description
5967 "A library designed to represent tabular data in visually appealing ASCII
5968tables. PrettyTable allows for selection of which columns are to be printed,
5969independent alignment of columns (left or right justified or centred) and
5970printing of sub-tables by specifying a row range.")
3f641af0 5971 (license license:bsd-3)))
350ba0a3
CR
5972
5973(define-public python2-prettytable
5974 (package-with-python2 python-prettytable))
7a8ac75a 5975
9f8ee3fe
RW
5976(define-public python-tables
5977 (package
5978 (name "python-tables")
5979 (version "3.2.2")
5980 (source
5981 (origin
5982 (method url-fetch)
5983 (uri (pypi-uri "tables" version))
5984 (sha256
5985 (base32
5986 "117s6w7s3yxafpmf3zz3svana7xfrsviw01va1xp7h8ylx8v6r1m"))))
5987 (build-system python-build-system)
5988 (arguments
5989 `(;; FIXME: python-build-system does not pass configure-flags to "build"
5990 ;; or "check", so we must override the build and check phases.
5991 #:phases
5992 (modify-phases %standard-phases
5993 (add-after 'unpack 'use-gcc
5994 (lambda _
5995 (substitute* "setup.py"
5996 (("compiler = new_compiler\\(\\)" line)
5997 (string-append line
5998 "\ncompiler.set_executables(compiler='gcc',"
5999 "compiler_so='gcc',"
6000 "linker_exe='gcc',"
6001 "linker_so='gcc -shared')")))
6002 #t))
6003 (replace 'build
6004 (lambda* (#:key inputs #:allow-other-keys)
6005 (zero? (system* "python" "setup.py" "build"
6006 (string-append "--hdf5="
6007 (assoc-ref inputs "hdf5"))))))
6008 (replace 'check
6009 (lambda* (#:key inputs #:allow-other-keys)
6010 (zero? (system* "python" "setup.py" "check"
6011 (string-append "--hdf5="
6012 (assoc-ref inputs "hdf5")))))))))
6013 (propagated-inputs
6014 `(("python-numexpr" ,python-numexpr)
6015 ("python-numpy" ,python-numpy)))
6016 (native-inputs
6017 `(("python-setuptools" ,python-setuptools)
6018 ("python-cython" ,python-cython)
6019 ("pkg-config" ,pkg-config)))
6020 (inputs
6021 `(("hdf5" ,hdf5)
6022 ("bzip2" ,bzip2)
6023 ("zlib" ,zlib)))
6024 (home-page "http://www.pytables.org/")
6025 (synopsis "Hierarchical datasets for Python")
6026 (description "PyTables is a package for managing hierarchical datasets and
6027designed to efficently cope with extremely large amounts of data.")
3f641af0 6028 (license license:bsd-3)))
9f8ee3fe
RW
6029
6030(define-public python2-tables
6031 (package-with-python2 python-tables))
6032
7a8ac75a
RW
6033(define-public python-pyasn1
6034 (package
6035 (name "python-pyasn1")
6036 (version "0.1.8")
6037 (source
6038 (origin
6039 (method url-fetch)
6040 (uri (string-append "https://pypi.python.org/packages/source/p/"
6041 "pyasn1/pyasn1-" version ".tar.gz"))
6042 (sha256
6043 (base32
6044 "0iw31d9l0zwx35szkzq72hiw002wnqrlrsi9dpbrfngcl1ybwcsx"))))
6045 (build-system python-build-system)
6046 (home-page "http://pyasn1.sourceforge.net/")
6047 (synopsis "ASN.1 types and codecs")
6048 (description
6049 "This is an implementation of ASN.1 types and codecs in Python. It is
6050suitable for a wide range of protocols based on the ASN.1 specification.")
3f641af0 6051 (license license:bsd-2)))
7a8ac75a
RW
6052
6053(define-public python2-pyasn1
6054 (package-with-python2 python-pyasn1))
9a49a535 6055
5988c299
EF
6056(define-public python-pyasn1-modules
6057 (package
6058 (name "python-pyasn1-modules")
6059 (version "0.0.8")
6060 (source
6061 (origin
6062 (method url-fetch)
6063 (uri (pypi-uri "pyasn1-modules" version))
6064 (sha256
6065 (base32
6066 "0drqgw81xd3fxdlg89kgd79zzrabvfncvkbybi2wr6w2y4s1jmhh"))))
6067 (build-system python-build-system)
6068 (native-inputs
6069 `(("python-setuptools" ,python-setuptools)))
6070 (propagated-inputs
6071 `(("python-pyasn1" ,python-pyasn1)))
6072 (home-page "http://sourceforge.net/projects/pyasn1/")
6073 (synopsis "ASN.1 codec implementations")
6074 (description
6075 "Pyasn1-modules is a collection of Python modules providing ASN.1 types and
6076implementations of ASN.1-based codecs and protocols.")
3f641af0 6077 (license license:bsd-3)))
5988c299
EF
6078
6079(define-public python2-pyasn1-modules
6080 (package-with-python2 python-pyasn1-modules))
6081
520af157 6082(define-public python-ipaddress
9a49a535 6083 (package
520af157
DC
6084 (name "python-ipaddress")
6085 (version "1.0.16")
6086 (source (origin
6087 (method url-fetch)
6088 (uri (pypi-uri "ipaddress" version))
6089 (sha256
6090 (base32
6091 "1c3imabdrw8nfksgjjflzg7h4ynjckqacb188rf541m74arq4cas"))))
9a49a535 6092 (build-system python-build-system)
9a49a535
RW
6093 (home-page "https://github.com/phihag/ipaddress")
6094 (synopsis "IP address manipulation library")
6095 (description
520af157
DC
6096 "This package provides a fast, lightweight IPv4/IPv6 manipulation library
6097 in Python. This library is used to create, poke at, and manipulate IPv4 and
6098 IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress
6099 module to older versions of Python.")
6100 (license license:psfl)
6101 (properties `((python2-variant . ,(delay python2-ipaddress))))))
6102
6103(define-public python2-ipaddress
6104 (let ((base (package-with-python2 (strip-python2-variant python-ipaddress))))
6105 (package (inherit base)
6106 (native-inputs
6107 `(("python2-setuptools" ,python2-setuptools)
6108 ,@(package-native-inputs base))))))
3f00e078 6109
4a238186
HG
6110(define-public python2-ipaddr
6111 (package
6112 (name "python2-ipaddr")
6113 (version "2.1.11")
6114 (source
6115 (origin
6116 (method url-fetch)
6117 (uri (pypi-uri "ipaddr" version))
6118 (sha256
6119 (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v"))))
6120 (build-system python-build-system)
6121 (arguments
6122 `(#:python ,python-2 ;version 2 only
6123 #:phases
6124 (modify-phases %standard-phases
6125 (replace 'check
6126 (lambda* _
6127 (zero? (system* "python" "ipaddr_test.py")))))))
6128 (home-page "https://github.com/google/ipaddr-py")
6129 (synopsis "IP address manipulation library")
6130 (description
6131 "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and
6132IPv6 addresses and networks.
6133
6134For new implementations you may prefer to use the standard module
6135@code{ipaddress}, which was introduced in Python 3.3 and backported to older
6136versions of Python.")
3f641af0 6137 (license license:asl2.0)))
4a238186 6138
3f00e078
RW
6139(define-public python-idna
6140 (package
6141 (name "python-idna")
6142 (version "2.0")
6143 (source
6144 (origin
6145 (method url-fetch)
6146 (uri (string-append "https://pypi.python.org/packages/source/i/"
6147 "idna/idna-" version ".tar.gz"))
6148 (sha256
6149 (base32
6150 "0frxgmgi234lr9hylg62j69j4ik5zhg0wz05w5dhyacbjfnrl68n"))))
6151 (build-system python-build-system)
6152 (native-inputs
6153 `(("python-setuptools" ,python-setuptools)))
6154 (home-page "https://github.com/kjd/idna")
6155 (synopsis "Internationalized domain names in applications")
6156 (description
6157 "This is a library to support the Internationalised Domain Names in
6158Applications (IDNA) protocol as specified in RFC 5891. This version of the
6159protocol is often referred to as “IDNA2008” and can produce different results
6160from the earlier standard from 2003. The library is also intended to act as a
6161suitable drop-in replacement for the “encodings.idna” module that comes with
6162the Python standard library but currently only supports the older 2003
6163specification.")
3f641af0 6164 (license license:bsd-4)))
3f00e078
RW
6165
6166(define-public python2-idna
6167 (package-with-python2 python-idna))
36ebf972
RW
6168
6169(define-public python-pretend
6170 (package
6171 (name "python-pretend")
6172 (version "1.0.8")
6173 (source
6174 (origin
6175 (method url-fetch)
6176 (uri (string-append "https://pypi.python.org/packages/source/p/"
6177 "pretend/pretend-" version ".tar.gz"))
6178 (sha256
6179 (base32
6180 "0r5r7ygz9m6d2bklflbl84cqhjkc2q12xgis8268ygjh30g2q3wk"))))
6181 (build-system python-build-system)
6182 (native-inputs
6183 `(("python-setuptools" ,python-setuptools)))
6184 (home-page "https://github.com/alex/pretend")
6185 (synopsis "Library for stubbing in Python")
6186 (description
6187 "Pretend is a library to make stubbing with Python easier. Stubbing is a
6188technique for writing tests. You may hear the term mixed up with mocks,
6189fakes, or doubles. Basically, a stub is an object that returns pre-canned
6190responses, rather than doing any computation.")
3f641af0 6191 (license license:bsd-3)))
36ebf972
RW
6192
6193(define-public python2-pretend
6194 (package-with-python2 python-pretend))
aa759a51
RW
6195
6196(define-public python-cryptography-vectors
6197 (package
6198 (name "python-cryptography-vectors")
9c509ca9 6199 (version "1.3.4")
aa759a51
RW
6200 (source
6201 (origin
6202 (method url-fetch)
9c509ca9 6203 (uri (pypi-uri "cryptography_vectors" version))
aa759a51
RW
6204 (sha256
6205 (base32
9c509ca9 6206 "15h1iz2klnpb4f8djxy7cpbnyn3wbjp7bnj4pz6s7w6plghbq524"))))
aa759a51
RW
6207 (build-system python-build-system)
6208 (native-inputs
6209 `(("python-setuptools" ,python-setuptools)))
6210 (home-page "https://github.com/pyca/cryptography")
66e07664 6211 (synopsis "Test vectors for the cryptography package")
aa759a51
RW
6212 (description
6213 "This package contains test vectors for the cryptography package.")
6214 ;; Distributed under either BSD-3 or ASL2.0
3f641af0 6215 (license (list license:bsd-3 license:asl2.0))))
aa759a51
RW
6216
6217(define-public python2-cryptography-vectors
6218 (package-with-python2 python-cryptography-vectors))
88b47cb0
RW
6219
6220(define-public python-cryptography
6221 (package
6222 (name "python-cryptography")
9c509ca9 6223 (version "1.3.4")
88b47cb0
RW
6224 (source
6225 (origin
6226 (method url-fetch)
9c509ca9 6227 (uri (pypi-uri "cryptography" version))
88b47cb0
RW
6228 (sha256
6229 (base32
9c509ca9 6230 "1a85l548w5vvq3yhz0az7ajg2ijixzp6gagapw6wgrqvq28ghgs2"))))
88b47cb0 6231 (build-system python-build-system)
470613f9
LF
6232 (arguments
6233 `(#:phases
6234 (modify-phases %standard-phases
6235 (add-before 'check 'disable-failing-test
6236 (lambda _
6237 ;; This test is known to fail with OpenSSL >= 1.0.2i and older
6238 ;; versions of python-cryptography:
6239 ;; https://github.com/pyca/cryptography/issues/3196
6240 ;; TODO: Try re-enabling the test when upgrading
6241 ;; python-cryptography.
6242 (substitute* "tests/hazmat/backends/test_openssl.py"
6243 (("def test_numeric_string_x509_name_entry")
6244 "@pytest.mark.xfail\n def test_numeric_string_x509_name_entry"))
6245 #t)))))
88b47cb0
RW
6246 (inputs
6247 `(("openssl" ,openssl)))
6248 (propagated-inputs
6249 `(("python-cffi" ,python-cffi)
6250 ("python-six" ,python-six)
6251 ("python-pyasn1" ,python-pyasn1)
88b47cb0
RW
6252 ("python-idna" ,python-idna)
6253 ("python-iso8601" ,python-iso8601)))
6254 (native-inputs
6255 `(("python-cryptography-vectors" ,python-cryptography-vectors)
ce6c13ee 6256 ("python-hypothesis" ,python-hypothesis)
88b47cb0
RW
6257 ("python-setuptools" ,python-setuptools)
6258 ("python-pretend" ,python-pretend)
ce6c13ee
EF
6259 ("python-pyasn1" ,python-pyasn1)
6260 ("python-pyasn1-modules" ,python-pyasn1-modules)
88b47cb0
RW
6261 ("python-pytest" ,python-pytest)))
6262 (home-page "https://github.com/pyca/cryptography")
6263 (synopsis "Cryptographic recipes and primitives for Python")
6264 (description
6265 "cryptography is a package which provides cryptographic recipes and
6266primitives to Python developers. It aims to be the “cryptographic standard
6267library” for Python. The package includes both high level recipes, and low
6268level interfaces to common cryptographic algorithms such as symmetric ciphers,
6269message digests and key derivation functions.")
6270 ;; Distributed under either BSD-3 or ASL2.0
3f641af0 6271 (license (list license:bsd-3 license:asl2.0))
519e2f4f 6272 (properties `((python2-variant . ,(delay python2-cryptography))))))
88b47cb0
RW
6273
6274(define-public python2-cryptography
519e2f4f
LF
6275 (let ((crypto (package-with-python2
6276 (strip-python2-variant python-cryptography))))
88b47cb0
RW
6277 (package (inherit crypto)
6278 (propagated-inputs
6279 `(("python2-ipaddress" ,python2-ipaddress)
ce6c13ee
EF
6280 ("python2-backport-ssl-match-hostname"
6281 ,python2-backport-ssl-match-hostname)
68f1cdec 6282 ("python2-enum34" ,python2-enum34)
88b47cb0 6283 ,@(package-propagated-inputs crypto))))))
5af999b8
RW
6284
6285(define-public python-pyopenssl
6286 (package
6287 (name "python-pyopenssl")
2fc629dd 6288 (version "16.0.0")
5af999b8
RW
6289 (source
6290 (origin
6291 (method url-fetch)
6292 (uri (string-append "https://pypi.python.org/packages/source/p/"
6293 "pyOpenSSL/pyOpenSSL-" version ".tar.gz"))
6294 (sha256
6295 (base32
2fc629dd 6296 "0zfijaxlq4vgi6jz0d4i5xq9ygqnyps6br7lmigjhqnh8gp10g9n"))))
5af999b8 6297 (build-system python-build-system)
5af999b8
RW
6298 (propagated-inputs
6299 `(("python-cryptography" ,python-cryptography)
6300 ("python-six" ,python-six)))
6301 (inputs
6302 `(("openssl" ,openssl)))
6303 (native-inputs
6304 `(("python-setuptools" ,python-setuptools)))
6305 (home-page "https://github.com/pyca/pyopenssl")
6306 (synopsis "Python wrapper module around the OpenSSL library")
6307 (description
6308 "PyOpenSSL is a high-level wrapper around a subset of the OpenSSL
6309library.")
3f641af0 6310 (license license:asl2.0)))
5af999b8
RW
6311
6312(define-public python2-pyopenssl
519e2f4f 6313 (package-with-python2 python-pyopenssl))
643725a1
CR
6314
6315(define-public python-pip
6316 (package
6317 (name "python-pip")
6fb54e3b 6318 (version "8.0.2")
643725a1
CR
6319 (source
6320 (origin
6321 (method url-fetch)
6fb54e3b 6322 (uri (pypi-uri "pip" version))
643725a1
CR
6323 (sha256
6324 (base32
6fb54e3b 6325 "08cm8d4228fj0qnrysy3qv1a6022zr3dcs25amd14lgxil6vvx26"))))
643725a1
CR
6326 (build-system python-build-system)
6327 (inputs
6328 `(("python-setuptools" ,python-setuptools)
6329 ("python-virtualenv" ,python-virtualenv)
6330 ;; Tests
6331 ("python-mock" ,python-mock)
6332 ("python-pytest" ,python-pytest)
6333 ("python-scripttest" ,python-scripttest)))
6334 (home-page "https://pip.pypa.io/")
6335 (synopsis
6336 "Package manager for Python software")
6337 (description
6338 "Pip is a package manager for Python software, that finds packages on the
6339Python Package Index (PyPI).")
6340 (license license:expat)))
6341
6342(define-public python2-pip
6343 (package-with-python2 python-pip))
d8c4998f
LC
6344
6345(define-public python-tlsh
6346 (package
6347 (name "python-tlsh")
99b00dc7 6348 (version "3.4.4")
d8c4998f
LC
6349 (home-page "https://github.com/trendmicro/tlsh")
6350 (source (origin
99b00dc7
EF
6351 (method url-fetch)
6352 (uri (string-append "https://github.com/trendmicro/tlsh/archive/v"
6353 version ".tar.gz"))
d8c4998f
LC
6354 (sha256
6355 (base32
99b00dc7
EF
6356 "00bhzjqrlh7v538kbkbn8lgx976j1138al3sdhklaizqjvpwyk4r"))
6357 (file-name (string-append name "-" version ".tar.gz"))))
d8c4998f
LC
6358 (build-system cmake-build-system)
6359 (arguments
6360 '(#:out-of-source? #f
6361 #:phases (modify-phases %standard-phases
6362 (replace
6363 'install
6364 (lambda* (#:key outputs #:allow-other-keys)
6365 ;; Build and install the Python bindings. The underlying
6366 ;; C++ library is apparently not meant to be installed.
6367 (let ((out (assoc-ref outputs "out")))
6368 (with-directory-excursion "py_ext"
6369 (and (system* "python" "setup.py" "build")
6370 (system* "python" "setup.py" "install"
6371 (string-append "--prefix=" out))))))))))
6372 (inputs `(("python" ,python-wrapper))) ;for the bindings
6373 (synopsis "Fuzzy matching library for Python")
6374 (description
6375 "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library.
6376Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash
6377value which can be used for similarity comparisons. Similar objects have
6378similar hash values, which allows for the detection of similar objects by
6379comparing their hash values. The byte stream should have a sufficient amount
6380of complexity; for example, a byte stream of identical bytes will not generate
6381a hash value.")
3f641af0 6382 (license license:asl2.0)))
d8c4998f
LC
6383
6384(define-public python2-tlsh
6385 (package
6386 (inherit python-tlsh)
6387 (name "python2-tlsh")
6388 (inputs `(("python" ,python-2)))))
d96034ed 6389
67f66812
BW
6390(define-public python-termcolor
6391 (package
6392 (name "python-termcolor")
6393 (version "1.1.0")
6394 (source
6395 (origin
6396 (method url-fetch)
6397 (uri (pypi-uri "python-termcolor" version))
6398 (sha256
6399 (base32
6400 "0fv1vq14rpqwgazxg4981904lfyp84mnammw7y046491cv76jv8x"))))
6401 (build-system python-build-system)
6402 (arguments
6403 ;; There are no tests.
6404 `(#:tests? #f))
6405 (home-page "http://pypi.python.org/pypi/termcolor")
6406 (synopsis "ANSII Color formatting for terminal output")
6407 (description
6408 "This package provides ANSII Color formatting for output in terminals.")
6409 (license license:expat)))
6410
6411(define-public python2-termcolor
6412 (package-with-python2 python-termcolor))
6413
d96034ed
LC
6414(define-public python-libarchive-c
6415 (package
6416 (name "python-libarchive-c")
03fd001c 6417 (version "2.2")
d96034ed
LC
6418 (source (origin
6419 (method url-fetch)
03fd001c 6420 (uri (pypi-uri "libarchive-c" version))
d96034ed
LC
6421 (sha256
6422 (base32
03fd001c 6423 "0z4r7v3dhd6b3120mav05ff08srih176r2rg5k8kn7mjd9pslm2x"))))
d96034ed
LC
6424 (build-system python-build-system)
6425 (arguments
6426 '(#:phases (modify-phases %standard-phases
6427 (add-before
6428 'build 'reference-libarchive
6429 (lambda* (#:key inputs #:allow-other-keys)
6430 ;; Retain the absolute file name of libarchive.so.
6431 (let ((libarchive (assoc-ref inputs "libarchive")))
6432 (substitute* "libarchive/ffi.py"
6433 (("find_library\\('archive'\\)")
6434 (string-append "'" libarchive
6435 "/lib/libarchive.so'"))))
6436
6437 ;; Do not make a compressed egg (see
6438 ;; <http://bugs.gnu.org/20765>).
6439 (let ((port (open-file "setup.cfg" "a")))
6440 (display "\n[easy_install]\nzip_ok = 0\n"
6441 port)
6442 (close-port port)
6443 #t))))))
6444 (inputs
6445 `(("python-setuptools" ,python-setuptools)
6446 ("libarchive" ,libarchive)))
6447 (home-page "https://github.com/Changaco/python-libarchive-c")
6448 (synopsis "Python interface to libarchive")
6449 (description
6450 "This package provides Python bindings to libarchive, a C library to
6451access possibly compressed archives in many different formats. It uses
6452Python's @code{ctypes} foreign function interface (FFI).")
3f641af0 6453 (license license:lgpl2.0+)))
d96034ed
LC
6454
6455(define-public python2-libarchive-c
6456 (package-with-python2 python-libarchive-c))
5e1c9367
LC
6457
6458(define-public python-file
6459 (package
6460 (inherit file)
6461 (name "python-file")
6462 (build-system python-build-system)
6463 (arguments
6464 '(#:tests? #f ;no tests
6465 #:phases (modify-phases %standard-phases
6466 (add-before 'build 'change-directory
6467 (lambda _
6468 (chdir "python")
6469 #t))
6470 (add-before 'build 'set-library-file-name
6471 (lambda* (#:key inputs #:allow-other-keys)
6472 (let ((file (assoc-ref inputs "file")))
6473 (substitute* "magic.py"
6474 (("find_library\\('magic'\\)")
6475 (string-append "'" file "/lib/libmagic.so'")))
6476 #t))))))
6477 (inputs `(("file" ,file)))
6478 (self-native-input? #f)
daeeea71
CM
6479 (synopsis "Python bindings to the libmagic file type guesser. Note that
6480this module and the python-magic module both provide a \"magic.py\" file;
6481these two modules, which are different and were developed separately, both
2f87a77f
LF
6482serve the same purpose: provide Python bindings for libmagic.")
6483 (properties `((python2-variant . ,(delay python2-file))))))
5e1c9367
LC
6484
6485(define-public python2-file
2f87a77f
LF
6486 (let ((base (package-with-python2 (strip-python2-variant python-file))))
6487 (package
6488 (inherit base)
6489 (native-inputs
6490 `(("python2-setuptools" ,python2-setuptools)
6491 ,@(package-native-inputs base))))))
85d4aeac
LC
6492
6493(define-public python-debian
6494 (package
6495 (name "python-debian")
6496 (version "0.1.23")
6497 (source
6498 (origin
6499 (method url-fetch)
6500 (uri (string-append
6501 "https://pypi.python.org/packages/source/p/python-debian/python-debian-"
6502 version ".tar.gz"))
6503 (sha256
6504 (base32
6505 "193faznwnjc3n5991wyzim6h9gyq1zxifmfrnpm3avgkh7ahyynh"))))
6506 (build-system python-build-system)
6507 (inputs
6508 `(("python-six" ,python-six)))
6509 (native-inputs
6510 `(("python-setuptools" ,python-setuptools)))
6511 (home-page "http://packages.debian.org/sid/python-debian")
6512 (synopsis "Debian package related modules")
6513 (description
5c7bdc9a
LC
6514 ;; XXX: Use @enumerate instead of @itemize to work around
6515 ;; <http://bugs.gnu.org/21772>.
85d4aeac
LC
6516 "This package provides Python modules that abstract many formats of
6517Debian-related files, such as:
6518
5c7bdc9a 6519@enumerate
85d4aeac
LC
6520@item Debtags information;
6521@item @file{debian/changelog} files;
6522@item packages files, pdiffs;
6523@item control files of single or multiple RFC822-style paragraphs---e.g.
6524 @file{debian/control}, @file{.changes}, @file{.dsc};
6525@item Raw @file{.deb} and @file{.ar} files, with (read-only) access to
6526 contained files and meta-information.
5c7bdc9a 6527@end enumerate\n")
85d4aeac
LC
6528
6529 ;; Modules are either GPLv2+ or GPLv3+.
3f641af0 6530 (license license:gpl3+)))
85d4aeac
LC
6531
6532(define-public python2-debian
6533 (package-with-python2 python-debian))
816a6538
LC
6534
6535(define-public python-chardet
6536 (package
6537 (name "python-chardet")
6538 (version "2.3.0")
6539 (source
6540 (origin
6541 (method url-fetch)
6542 (uri (string-append
6543 "https://pypi.python.org/packages/source/c/chardet/chardet-"
6544 version
6545 ".tar.gz"))
6546 (sha256
6547 (base32
6548 "1ak87ikcw34fivcgiz2xvi938dmclh078az65l9x3rmgljrkhgp5"))))
6549 (build-system python-build-system)
6550 (native-inputs
6551 `(("python-setuptools" ,python-setuptools)))
6552 (home-page "https://github.com/chardet/chardet")
6553 (synopsis "Universal encoding detector for Python 2 and 3")
6554 (description
6555 "This package provides @code{chardet}, a Python module that can
6556automatically detect a wide range of file encodings.")
3f641af0 6557 (license license:lgpl2.1+)))
816a6538
LC
6558
6559(define-public python2-chardet
6560 (package-with-python2 python-chardet))
2fc5f186 6561
1872f1bb
KM
6562(define-public python-docopt
6563 (package
6564 (name "python-docopt")
6565 (version "0.6.2")
6566 (source
6567 (origin
6568 (method url-fetch)
6569 ;; The release on PyPI does not include tests.
6570 (uri (string-append
6571 "https://github.com/docopt/docopt/archive/"
6572 version ".tar.gz"))
6573 (file-name (string-append name "-" version ".tar.gz"))
6574 (sha256
6575 (base32
6576 "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1"))))
6577 (build-system python-build-system)
6578 (native-inputs
6579 `(("python-pytest" ,python-pytest)
6580 ("python-setuptools" ,python-setuptools)))
6581 (arguments
6582 `(#:phases (alist-replace
6583 'check
6584 (lambda _ (zero? (system* "py.test")))
6585 %standard-phases)))
6586 (home-page "http://docopt.org")
6587 (synopsis "Command-line interface description language for Python")
6588 (description "This library allows the user to define a command-line
6589interface from a program's help message rather than specifying it
6590programatically with command-line parsers like @code{getopt} and
6591@code{argparse}.")
6592 (license license:expat)))
6593
6594(define-public python2-docopt
6595 (package-with-python2 python-docopt))
6596
2fc5f186
LF
6597(define-public python-zope-event
6598 (package
6599 (name "python-zope-event")
6600 (version "4.1.0")
6601 (source
6602 (origin
6603 (method url-fetch)
6604 (uri (string-append "https://pypi.python.org/packages/source/z"
6605 "/zope.event/zope.event-" version ".tar.gz"))
6606 (sha256
6607 (base32
6608 "11p75zpfz3ffhz21nzx9wb23xs993ck5s6hkjcvhswwizni5jynw"))))
6609 (build-system python-build-system)
6610 (inputs
6611 `(("python-setuptools" ,python-setuptools)))
6612 (home-page "http://pypi.python.org/pypi/zope.event")
6613 (synopsis "Event publishing system for Python")
6614 (description "Zope.event provides an event publishing API, intended for
6615use by applications which are unaware of any subscribers to their events. It
6616is a simple event-dispatching system on which more sophisticated event
6617dispatching systems can be built.")
3f641af0 6618 (license license:zpl2.1)))
2fc5f186
LF
6619
6620(define-public python2-zope-event
6621 (package-with-python2 python-zope-event))
97abe268
LF
6622
6623(define-public python-zope-interface
6624 (package
6625 (name "python-zope-interface")
6626 (version "4.1.3")
6627 (source
6628 (origin
6629 (method url-fetch)
6630 (uri (string-append "https://pypi.python.org/packages/source/z"
6631 "/zope.interface/zope.interface-" version ".tar.gz"))
6632 (sha256
6633 (base32
6634 "0ks8h73b2g4bkad821qbv0wzjppdrwys33i7ka45ik3wxjg1l8if"))))
6635 (build-system python-build-system)
6636 (propagated-inputs
6637 `(("python-zope-event" ,python-zope-event)))
6638 (home-page "https://github.com/zopefoundation/zope.interface")
6639 (synopsis "Python implementation of the \"design by contract\"
6640methodology")
6641 (description "Zope.interface provides an implementation of \"object
6642interfaces\" for Python. Interfaces are a mechanism for labeling objects as
6643conforming to a given API or contract.")
3f641af0 6644 (license license:zpl2.1)))
97abe268
LF
6645
6646(define-public python2-zope-interface
6647 (package-with-python2 python-zope-interface))
81f2373c
LF
6648
6649(define-public python-zope-exceptions
6650 (package
6651 (name "python-zope-exceptions")
6652 (version "4.0.8")
6653 (source
6654 (origin
6655 (method url-fetch)
6656 (uri (string-append "https://pypi.python.org/packages/source/z"
6657 "/zope.exceptions/zope.exceptions-"
6658 version ".tar.gz"))
6659 (sha256
6660 (base32
6661 "0zwxaaa66sqxg5k7zcrvs0fbg9ym1njnxnr28dfmchzhwjvwnfzl"))))
6662 (build-system python-build-system)
6663 (arguments
6664 '(#:tests? #f)) ; circular dependency with zope.testrunner
6665 (propagated-inputs
6666 `(("python-zope-interface" ,python-zope-interface)))
6667 (home-page "http://cheeseshop.python.org/pypi/zope.exceptions")
6668 (synopsis "Zope exceptions")
6669 (description "Zope.exceptions provides general-purpose exception types
6670that have uses outside of the Zope framework.")
3f641af0 6671 (license license:zpl2.1)))
81f2373c
LF
6672
6673(define-public python2-zope-exceptions
6674 (package-with-python2 python-zope-exceptions))
900e3c0e
LF
6675
6676(define-public python-zope-testing
6677 (package
6678 (name "python-zope-testing")
6679 (version "4.5.0")
6680 (source
6681 (origin
6682 (method url-fetch)
6683 (uri (string-append "https://pypi.python.org/packages/source/z"
6684 "/zope.testing/zope.testing-" version ".tar.gz"))
6685 (sha256
6686 (base32
6687 "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))))
6688 (build-system python-build-system)
6689 (native-inputs
6690 `(("python-zope-exceptions" ,python-zope-exceptions)))
6691 (propagated-inputs
6692 `(("python-zope-interface" ,python-zope-interface)))
6693 (home-page "http://pypi.python.org/pypi/zope.testing")
6694 (synopsis "Zope testing helpers")
6695 (description "Zope.testing provides a number of testing utilities for HTML
6696forms, HTTP servers, regular expressions, and more.")
3f641af0 6697 (license license:zpl2.1)))
900e3c0e
LF
6698
6699(define-public python2-zope-testing
6700 (package-with-python2 python-zope-testing))
01614c4f
LF
6701
6702(define-public python-zope-testrunner
6703 (package
6704 (name "python-zope-testrunner")
6705 (version "4.4.9")
6706 (source
6707 (origin
6708 (method url-fetch)
6709 (uri (string-append "https://pypi.python.org/packages/source/z"
6710 "/zope.testrunner/zope.testrunner-"
6711 version ".zip"))
6712 (sha256
6713 (base32
6714 "1r7iqknhh55y45f64mz5hghgvzx34h1i11k350s0avx6q8gznja1"))))
6715 (build-system python-build-system)
6716 (native-inputs
6717 `(("python-six" ,python-six)
6718 ("python-zope-exceptions" ,python-zope-exceptions)
6719 ("python-zope-testing" ,python-zope-testing)
6720 ("unzip" ,unzip)))
6721 (propagated-inputs
6722 `(("python-zope-interface" ,python-zope-interface)))
6723 (home-page "http://pypi.python.org/pypi/zope.testrunner")
6724 (synopsis "Zope testrunner script")
6725 (description "Zope.testrunner provides a script for running Python
6726tests.")
3f641af0 6727 (license license:zpl2.1)))
01614c4f
LF
6728
6729(define-public python2-zope-testrunner
6730 (let ((base (package-with-python2 python-zope-testrunner)))
6731 (package
6732 (inherit base)
6733 (native-inputs
6734 (append (package-native-inputs base)
6735 `(("python2-subunit" ,python2-subunit)
6736 ("python2-mimeparse" ,python2-mimeparse)))))))
6a5c710c
LF
6737
6738(define-public python-zope-i18nmessageid
6739 (package
6740 (name "python-zope-i18nmessageid")
6741 (version "4.0.3")
6742 (source
6743 (origin
6744 (method url-fetch)
6745 (uri (string-append
6746 "https://pypi.python.org/packages/source/z"
6747 "/zope.i18nmessageid/zope.i18nmessageid-"
6748 version ".tar.gz"))
6749 (sha256
6750 (base32
6751 "1rslyph0klk58dmjjy4j0jxy21k03azksixc3x2xhqbkv97cmzml"))))
6752 (build-system python-build-system)
6753 (inputs
6754 `(("python-setuptools" ,python-setuptools)))
6755 (home-page "http://pypi.python.org/pypi/zope.i18nmessageid")
6756 (synopsis "Message identifiers for internationalization")
6757 (description "Zope.i18nmessageid provides facilities for declaring
6758internationalized messages within program source text.")
3f641af0 6759 (license license:zpl2.1)))
6a5c710c
LF
6760
6761(define-public python2-zope-i18nmessageid
6762 (package-with-python2 python-zope-i18nmessageid))
71fb09f3
LF
6763
6764(define-public python-zope-schema
6765 (package
6766 (name "python-zope-schema")
6767 (version "4.4.2")
6768 (source
6769 (origin
6770 (method url-fetch)
6771 (uri (string-append "https://pypi.python.org/packages/source/z"
6772 "/zope.schema/zope.schema-" version ".tar.gz"))
6773 (sha256
6774 (base32
6775 "1p943jdxb587dh7php4vx04qvn7b2877hr4qs5zyckvp5afhhank"))))
6776 (build-system python-build-system)
6777 (propagated-inputs
6778 `(("python-zope-event" ,python-zope-event)
6779 ("python-zope-interface" ,python-zope-interface)))
6780 (native-inputs
6781 `(("python-zope-testing" ,python-zope-testing)))
6782 (home-page "http://pypi.python.org/pypi/zope.schema")
6783 (synopsis "Zope data schemas")
6784 (description "Zope.scheme provides extensions to zope.interface for
6785defining data schemas.")
3f641af0 6786 (license license:zpl2.1)))
71fb09f3
LF
6787
6788(define-public python2-zope-schema
6789 (package-with-python2 python-zope-schema))
fbac9b17
LF
6790
6791(define-public python-zope-configuration
6792 (package
6793 (name "python-zope-configuration")
6794 (version "4.0.3")
6795 (source (origin
6796 (method url-fetch)
6797 (uri (string-append "https://pypi.python.org/packages/source/z"
6798 "/zope.configuration/zope.configuration-"
6799 version ".tar.gz"))
6800 (sha256
6801 (base32
6802 "1x9dfqypgympnlm25p9m43xh4qv3p7d75vksv9pzqibrb4cggw5n"))))
6803 (build-system python-build-system)
6804 (propagated-inputs
6805 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6806 ("python-zope-schema" ,python-zope-schema)))
6807 (home-page "http://pypi.python.org/pypi/zope.configuration")
6808 (synopsis "Zope Configuration Markup Language")
6809 (description "Zope.configuration implements ZCML, the Zope Configuration
6810Markup Language.")
3f641af0 6811 (license license:zpl2.1)))
fbac9b17
LF
6812
6813(define-public python2-zope-configuration
6814 (package-with-python2 python-zope-configuration))
2ad52086
LF
6815
6816(define-public python-zope-proxy
6817 (package
6818 (name "python-zope-proxy")
6819 (version "4.1.6")
6820 (source
6821 (origin
6822 (method url-fetch)
6823 (uri (string-append "https://pypi.python.org/packages/source/z"
6824 "/zope.proxy/zope.proxy-" version ".tar.gz"))
6825 (sha256
6826 (base32
6827 "0pqwwmvm1prhwv1ziv9lp8iirz7xkwb6n2kyj36p2h0ppyyhjnm4"))))
6828 (build-system python-build-system)
6829 (propagated-inputs
6830 `(("python-zope-interface" ,python-zope-interface)))
6831 (home-page "http://pypi.python.org/pypi/zope.proxy")
6832 (synopsis "Generic, transparent proxies")
6833 (description "Zope.proxy provides generic, transparent proxies for Python.
6834Proxies are special objects which serve as mostly-transparent wrappers around
6835another object, intervening in the apparent behavior of the wrapped object
6836only when necessary to apply the policy (e.g., access checking, location
6837brokering, etc.) for which the proxy is responsible.")
3f641af0 6838 (license license:zpl2.1)))
2ad52086
LF
6839
6840(define-public python2-zope-proxy
6841 (package-with-python2 python-zope-proxy))
f404b5ea
LF
6842
6843(define-public python-zope-location
6844 (package
6845 (name "python-zope-location")
6846 (version "4.0.3")
6847 (source
6848 (origin
6849 (method url-fetch)
6850 (uri (string-append "https://pypi.python.org/packages/source/z"
6851 "/zope.location/zope.location-" version ".tar.gz"))
6852 (sha256
6853 (base32
6854 "1nj9da4ksiyv3h8n2vpzwd0pb03mdsh7zy87hfpx72b6p2zcwg74"))))
6855 (build-system python-build-system)
6856 (native-inputs
6857 `(("python-zope-proxy" ,python-zope-proxy)
6858 ("python-zope-schema" ,python-zope-schema)))
6859 (home-page "http://pypi.python.org/pypi/zope.location/")
6860 (synopsis "Zope location library")
6861 (description "Zope.location implements the concept of \"locations\" in
6862Zope3, which are are special objects that have a structural location.")
3f641af0 6863 (license license:zpl2.1)))
f404b5ea
LF
6864
6865(define-public python2-zope-location
6866 (package-with-python2 python-zope-location))
d4b77f36
LF
6867
6868(define-public python-zope-security
6869 (package
6870 (name "python-zope-security")
6871 (version "4.0.3")
6872 (source
6873 (origin
6874 (method url-fetch)
6875 (uri (string-append "https://pypi.python.org/packages/source/z"
6876 "/zope.security/zope.security-" version ".tar.gz"))
6877 (sha256
6878 (base32
6879 "14zmf684amc0x32kq05yxnhfqd1cmyhafkw05gn81rn90zjv6ssy"))))
6880 (build-system python-build-system)
6881 (propagated-inputs
6882 `(("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6883 ("python-zope-component" ,python-zope-component)
6884 ("python-zope-location" ,python-zope-location)
6885 ("python-zope-proxy" ,python-zope-proxy)
6886 ("python-zope-schema" ,python-zope-schema)
6887 ("python-zope-testrunner" ,python-zope-testrunner)
6888 ("python-zope-testing" ,python-zope-testing)))
6889 (home-page "http://pypi.python.org/pypi/zope.security")
6890 (synopsis "Zope security framework")
6891 (description "Zope.security provides a generic mechanism to implement
6892security policies on Python objects.")
3f641af0 6893 (license license:zpl2.1)))
d4b77f36
LF
6894
6895(define-public python2-zope-security
04417662
EF
6896 (let ((zope-security (package-with-python2 python-zope-security)))
6897 (package (inherit zope-security)
6898 (propagated-inputs
6899 `(("python2-zope-testrunner" ,python2-zope-testrunner)
6900 ,@(alist-delete
6901 "python-zope-testrunner"
6902 (package-propagated-inputs zope-security)))))))
a6b61b27
LF
6903
6904(define-public python-zope-component
6905 (package
6906 (name "python-zope-component")
6907 (version "4.2.2")
6908 (source
6909 (origin
6910 (method url-fetch)
6911 (uri (string-append "https://pypi.python.org/packages/source/z"
6912 "/zope.component/zope.component-" version ".tar.gz"))
6913 (sha256
6914 (base32
6915 "06pqr8m5jv12xjyy5b59hh9anl61cxkzhw9mka33r3nxalmi2b18"))))
6916 (build-system python-build-system)
6917 (arguments
6918 ;; Skip tests due to circular dependency with python-zope-security.
6919 '(#:tests? #f))
6920 (native-inputs
6921 `(("python-zope-testing" ,python-zope-testing)))
6922 (propagated-inputs
6923 `(("python-zope-event" ,python-zope-event)
6924 ("python-zope-interface" ,python-zope-interface)
6925 ("python-zope-i18nmessageid" ,python-zope-i18nmessageid)
6926 ("python-zope-configuration" ,python-zope-configuration)))
6927 (home-page "https://github.com/zopefoundation/zope.component")
6928 (synopsis "Zope Component Architecture")
6929 (description "Zope.component represents the core of the Zope Component
6930Architecture. Together with the zope.interface package, it provides
6931facilities for defining, registering and looking up components.")
3f641af0 6932 (license license:zpl2.1)))
a6b61b27
LF
6933
6934(define-public python2-zope-component
6935 (package-with-python2 python-zope-component))
3859ac12 6936
1ae44b80 6937(define-public python-pythondialog
b5f218be 6938 (package
1ae44b80 6939 (name "python-pythondialog")
42c4b246 6940 (version "3.4.0")
b5f218be
LF
6941 (source
6942 (origin
6943 (method url-fetch)
1ae44b80 6944 (uri (pypi-uri "pythondialog" version))
b5f218be
LF
6945 (sha256
6946 (base32
1ae44b80 6947 "1728ghsran47jczn9bhlnkvk5bvqmmbihabgif5h705b84r1272c"))))
b5f218be
LF
6948 (build-system python-build-system)
6949 (arguments
6950 `(#:phases
6951 (modify-phases %standard-phases
6952 (add-after 'unpack 'patch-path
6953 (lambda* (#:key inputs #:allow-other-keys)
6954 (let* ((dialog (assoc-ref inputs "dialog")))
6955 ;; Since this library really wants to grovel the search path, we
6956 ;; must hardcode dialog's store path into it.
6957 (substitute* "dialog.py"
6958 (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)")
6959 (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\"")))
6960 #t))))
b5f218be
LF
6961 #:tests? #f)) ; no test suite
6962 (propagated-inputs
6963 `(("dialog" ,dialog)))
6964 (home-page "http://pythondialog.sourceforge.net/")
6965 (synopsis "Python interface to the UNIX dialog utility")
6966 (description "A Python wrapper for the dialog utility. Its purpose is to
6967provide an easy to use, pythonic and comprehensive Python interface to dialog.
6968This allows one to make simple text-mode user interfaces on Unix-like systems")
3f641af0 6969 (license license:lgpl2.1)
1ae44b80
LF
6970 (properties `((python2-variant . ,(delay python2-pythondialog))))))
6971
6972(define-public python2-pythondialog
6973 (let ((base (package-with-python2 (strip-python2-variant python-pythondialog))))
6974 (package
6975 (inherit base)
6976 (version (package-version python-pythondialog))
6977 (source (origin
6978 (method url-fetch)
6979 (uri (pypi-uri "python2-pythondialog" version))
6980 (sha256
6981 (base32
6982 "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9")))))))
b5f218be 6983
3859ac12
LF
6984(define-public python-pyrfc3339
6985 (package
6986 (name "python-pyrfc3339")
d9aa097b 6987 (version "1.0")
3859ac12
LF
6988 (source
6989 (origin
6990 (method url-fetch)
d9aa097b 6991 (uri (pypi-uri "pyRFC3339" version))
3859ac12
LF
6992 (sha256
6993 (base32
d9aa097b 6994 "0dgm4l9y8jiax5cp6yxjd2i27cq8h33sh81n1wfbmnmqb32cdywd"))))
3859ac12
LF
6995 (build-system python-build-system)
6996 (propagated-inputs
6997 `(("python-pytz" ,python-pytz)))
6998 (native-inputs
6999 `(("python-nose" ,python-nose)
7000 ("python-setuptools" ,python-setuptools)))
7001 (home-page "https://github.com/kurtraschke/pyRFC3339")
7002 (synopsis "Python timestamp library")
7003 (description "Python library for generating and parsing RFC 3339-compliant
7004timestamps.")
7005 (license license:expat)))
7006
7007(define-public python2-pyrfc3339
7008 (package-with-python2 python-pyrfc3339))
5eea2005
LF
7009
7010(define-public python-werkzeug
7011 (package
7012 (name "python-werkzeug")
4b47cbfa 7013 (version "0.11.5")
5eea2005
LF
7014 (source
7015 (origin
7016 (method url-fetch)
4b47cbfa 7017 (uri (pypi-uri "Werkzeug" version))
5eea2005
LF
7018 (sha256
7019 (base32
4b47cbfa 7020 "0r41xqp4cypzcgsf6zbspbqd272wnzf20igb4w4b5wzfhgqh9nxg"))))
5eea2005
LF
7021 (build-system python-build-system)
7022 (native-inputs
7023 `(("python-pytest" ,python-pytest)))
7024 (home-page "http://werkzeug.pocoo.org/")
7025 (synopsis "Utilities for WSGI applications")
7026 (description "One of the most advanced WSGI utility modules. It includes a
7027powerful debugger, full-featured request and response objects, HTTP utilities to
7028handle entity tags, cache control headers, HTTP dates, cookie handling, file
7029uploads, a powerful URL routing system and a bunch of community-contributed
7030addon modules.")
3f641af0 7031 (license license:x11)))
5eea2005
LF
7032
7033(define-public python2-werkzeug
7034 (package-with-python2 python-werkzeug))
99fffa8a
LF
7035
7036(define-public python-configobj
7037 (package
7038 (name "python-configobj")
7039 (version "5.0.6")
7040 (source (origin
7041 (method url-fetch)
7042 (uri (string-append
7043 "https://pypi.python.org/packages/source/c/configobj/"
7044 "configobj-" version ".tar.gz"))
7045 (sha256
7046 (base32
7047 "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2"))
7048 ;; Patch setup.py so it looks for python-setuptools, which is
7049 ;; required to parse the keyword 'install_requires' in setup.py.
fc1adab1 7050 (patches (search-patches "python-configobj-setuptools.patch"))))
99fffa8a
LF
7051 (build-system python-build-system)
7052 (native-inputs
7053 `(("python-setuptools" ,python-setuptools)
7054 ("python-six" ,python-six)))
7055 (synopsis "Config file reading, writing and validation")
7056 (description "ConfigObj is a simple but powerful config file reader and
7057writer: an ini file round tripper. Its main feature is that it is very easy to
7058use, with a straightforward programmer’s interface and a simple syntax for
7059config files.")
7060 (home-page "https://github.com/DiffSK/configobj")
3f641af0 7061 (license license:bsd-3)))
99fffa8a
LF
7062
7063(define-public python2-configobj
7064 (package-with-python2 python-configobj))
79e8a291
LF
7065
7066(define-public python-configargparse
7067 (package
7068 (name "python-configargparse")
7069 (version "0.10.0")
7070 (source (origin
7071 (method url-fetch)
7072 (uri (string-append
7073 "https://pypi.python.org/packages/source/C/ConfigArgParse/"
7074 "ConfigArgParse-" version ".tar.gz"))
7075 (sha256
7076 (base32
7077 "19wh919gbdbzxzpagg52q3lm62yicm95ddlcx77dyjc1slyshl1v"))))
7078 (build-system python-build-system)
7079 (arguments
7080 ;; FIXME: Bug in test suite filed upstream:
7081 ;; https://github.com/bw2/ConfigArgParse/issues/32
7082 '(#:tests? #f))
7083 (synopsis "Replacement for argparse")
7084 (description "A drop-in replacement for argparse that allows options to also
7085be set via config files and/or environment variables.")
7086 (home-page "https://github.com/bw2/ConfigArgParse")
7087 (license license:expat)))
7088
7089(define-public python2-configargparse
7090 (package-with-python2 python-configargparse))
ab41f979
LF
7091
7092(define-public python-ndg-httpsclient
7093 (package
7094 (name "python-ndg-httpsclient")
7095 (version "0.4.0")
7096 (source (origin
7097 (method url-fetch)
7098 (uri (string-append
7099 "https://pypi.python.org/packages/source/n/ndg-httpsclient/"
7100 "ndg_httpsclient-" version ".tar.gz"))
7101 (sha256
7102 (base32
7103 "0x32ibixm3vv5m9xfk83xsqm8xcqw4dd0khbh6qbri6rxgymbhg8"))))
7104 (build-system python-build-system)
a39cc016
LF
7105 (arguments
7106 '(;; The tests appear to require networking.
7107 #:tests? #f))
ab41f979
LF
7108 (propagated-inputs
7109 `(("python-pyopenssl" ,python-pyopenssl)))
7110 (synopsis "HTTPS support for Python's httplib and urllib2")
7111 (description "This is a HTTPS client implementation for httplib and urllib2
7112based on PyOpenSSL. PyOpenSSL provides a more fully featured SSL implementation
7113over the default provided with Python and importantly enables full verification
7114of the SSL peer.")
7115 (home-page "https://github.com/cedadev/ndg_httpsclient/")
3f641af0 7116 (license license:bsd-3)))
ab41f979
LF
7117
7118;; python2-openssl requires special care, so package-with-python2 is
7119;; insufficient.
7120(define-public python2-ndg-httpsclient
7121 (package (inherit python-ndg-httpsclient)
7122 (name "python2-ndg-httpsclient")
7123 (arguments `(#:python ,python-2))
7124 (propagated-inputs
7125 `(("python2-pyopenssl" ,python2-pyopenssl)))))
03f964a5
CM
7126
7127(define-public python-contextlib2
7128 (package
7129 (name "python-contextlib2")
7130 (version "0.4.0")
7131 (source
7132 (origin
7133 (method url-fetch)
7134 (uri (pypi-uri "contextlib2" version))
7135 (sha256
7136 (base32
7137 "0cmp131dlh0d0zvw0aza1zd13glvngzk8lb4avks0hm7yxwdr9am"))))
7138 (build-system python-build-system)
7139 (arguments
7140 `(#:phases
7141 (modify-phases %standard-phases
7142 (replace 'check
7143 (lambda _ (zero?
7144 (system*
b3546174 7145 "python" "test_contextlib2.py" "-v")))))))
03f964a5
CM
7146 (home-page "http://contextlib2.readthedocs.org/")
7147 (synopsis "Tools for decorators and context managers")
7148 (description "This module is primarily a backport of the Python
71493.2 contextlib to earlier Python versions. Like contextlib, it
7150provides utilities for common tasks involving decorators and context
7151managers. It also contains additional features that are not part of
7152the standard library.")
3f641af0 7153 (license license:psfl)))
03f964a5
CM
7154
7155(define-public python2-contextlib2
7156 (package-with-python2 python-contextlib2))
210bf497
DT
7157
7158(define-public python-texttable
7159 (package
7160 (name "python-texttable")
7161 (version "0.8.4")
7162 (source
7163 (origin
7164 (method url-fetch)
7165 (uri (pypi-uri "texttable" version))
7166 (sha256
7167 (base32
7168 "0bkhs4dx9s6g7fpb969hygq56hyz4ncfamlynw72s0n6nqfbd1w5"))))
7169 (build-system python-build-system)
7170 (arguments '(#:tests? #f)) ; no tests
7171 (home-page "https://github.com/foutaise/texttable/")
7172 (synopsis "Python module for creating simple ASCII tables")
7173 (description "Texttable is a Python module for creating simple ASCII
7174tables.")
3f641af0 7175 (license license:lgpl2.1+)))
210bf497
DT
7176
7177(define-public python2-texttable
7178 (package-with-python2 python-texttable))
67c52bb3
DT
7179
7180(define-public python-websocket-client
7181 (package
7182 (name "python-websocket-client")
6b810897 7183 (version "0.37.0")
67c52bb3
DT
7184 (source
7185 (origin
7186 (method url-fetch)
6b810897 7187 (uri (pypi-uri "websocket_client" version))
67c52bb3
DT
7188 (sha256
7189 (base32
6b810897 7190 "0h9glp1jll3z76ly3kg08aqgxqk0a68p4zi9yn50353bh5nj92v7"))))
67c52bb3
DT
7191 (build-system python-build-system)
7192 (native-inputs
7193 `(("python-six" ,python-six))) ; for tests
7194 (inputs
7195 `(("python-setuptools" ,python-setuptools)))
7196 (home-page "https://github.com/liris/websocket-client")
7197 (synopsis "WebSocket client for Python")
7198 (description "The Websocket-client module provides the low level APIs for
7199WebSocket usage in Python programs.")
3f641af0 7200 (license license:lgpl2.1+)))
67c52bb3
DT
7201
7202(define-public python2-websocket-client
7203 (package-with-python2 python-websocket-client))
5c6eea2a
LF
7204
7205(define-public python-atomicwrites
7206 (package
7207 (name "python-atomicwrites")
4e92d76a 7208 (version "1.1.0")
5c6eea2a
LF
7209 (source (origin
7210 (method url-fetch)
7211 (uri (pypi-uri "atomicwrites" version))
7212 (sha256
7213 (base32
4e92d76a 7214 "1s01dci8arsl9d9vr5nz1fk9znldp1z3l4yl43f0c27z12b8yxl0"))))
5c6eea2a
LF
7215 (build-system python-build-system)
7216 (synopsis "Atomic file writes in Python")
7217 (description "Library for atomic file writes using platform dependent tools
8f65585b 7218for atomic file system operations.")
5c6eea2a 7219 (home-page "https://github.com/untitaker/python-atomicwrites")
9bb6d184
LF
7220 (license license:expat)
7221 (properties `((python2-variant . ,(delay python2-atomicwrites))))))
7222
7223(define-public python2-atomicwrites
7224 (package (inherit (package-with-python2
7225 (strip-python2-variant python-atomicwrites)))
7226 (native-inputs
7227 `(("python2-setuptools" ,python2-setuptools)))))
561bb3cb
LF
7228
7229(define-public python-requests-toolbelt
7230 (package
7231 (name "python-requests-toolbelt")
c02af1c8 7232 (version "0.6.2")
561bb3cb
LF
7233 (source (origin
7234 (method url-fetch)
c02af1c8
LF
7235 (uri (string-append
7236 "https://pypi.python.org/packages/"
7237 "e1/a4/a94c037bc72ad70441aff1403d3243510d2542ddca7759faaeffeb11aefe/"
7238 "requests-toolbelt-" version ".tar.gz"))
561bb3cb
LF
7239 (sha256
7240 (base32
c02af1c8 7241 "15q9nrgp85nqlr4kdz1zvj8z2npafi2sr12y7fqgxbkq28j1aci6"))))
561bb3cb
LF
7242 (build-system python-build-system)
7243 (propagated-inputs
7244 `(("python-requests" ,python-requests)))
7245 (synopsis "Extensions to python-requests")
7246 (description "This is a toolbelt of useful classes and functions to be used
7247with python-requests.")
7248 (home-page "https://github.com/sigmavirus24/requests-toolbelt")
3f641af0 7249 (license license:asl2.0)))
d1deb90b
LF
7250
7251(define-public python-click-threading
7252 (package
7253 (name "python-click-threading")
3d2e0dbc 7254 (version "0.2.0")
d1deb90b
LF
7255 (source (origin
7256 (method url-fetch)
3d2e0dbc
LF
7257 (uri (string-append
7258 "https://pypi.python.org/packages/"
7259 "fe/b7/e7f609d18a2a351cb71616adcf54df1acd82f83cb9b5936935a4d20e2c23/"
7260 "click-threading-" version ".tar.gz"))
d1deb90b
LF
7261 (sha256
7262 (base32
3d2e0dbc 7263 "18bcqikxwb3drb8rf60cclxkxw52521b38ax3byah6j8cn8y9p4j"))))
d1deb90b
LF
7264 (build-system python-build-system)
7265 (propagated-inputs
7266 `(("python-click" ,python-click)))
7267 (synopsis "Utilities for multithreading in Click")
7268 (description "This package provides utilities for multithreading in Click
7269applications.")
7270 (home-page "https://github.com/click-contrib/click-threading")
7271 (license license:expat)))
7b17cab9
LF
7272
7273(define-public python-click-log
7274 (package
7275 (name "python-click-log")
a9da8fec 7276 (version "0.1.3")
7b17cab9
LF
7277 (source (origin
7278 (method url-fetch)
7279 (uri (pypi-uri "click-log" version))
7280 (sha256
7281 (base32
a9da8fec 7282 "0kdd1vminxpcfczxl2kkf285n0dr1gxh2cdbx1p6vkj7b7bci3gx"))))
7b17cab9
LF
7283 (build-system python-build-system)
7284 (propagated-inputs
7285 `(("python-click" ,python-click)))
7286 (synopsis "Logging for click applications")
7287 (description "This package provides a Python library for logging Click
7288applications.")
7289 (home-page "https://github.com/click-contrib/click-log")
7290 (license license:expat)))
7b3a4ee4
LF
7291
7292(define-public python-apipkg
7293 (package
7294 (name "python-apipkg")
7295 (version "1.4")
7296 (source (origin
7297 (method url-fetch)
7298 (uri (pypi-uri "apipkg" version))
7299 (sha256
7300 (base32
7301 "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f"))))
7302 (build-system python-build-system)
b43bab3c 7303 (inputs
7b3a4ee4
LF
7304 `(("python-pytest" ,python-pytest)))
7305 (synopsis "Namespace control and lazy-import mechanism")
7306 (description "With apipkg you can control the exported namespace of a Python
7307package and greatly reduce the number of imports for your users. It is a small
7308pure Python module that works on virtually all Python versions.")
7309 (home-page "https://bitbucket.org/hpk42/apipkg")
e08739c3
CAW
7310 (license license:expat)
7311 (properties `((python2-variant . ,(delay python2-apipkg))))))
7312
7313(define-public python2-apipkg
7314 (package
7315 (inherit (package-with-python2
7316 (strip-python2-variant python-apipkg)))
7317 (native-inputs
7318 `(("python2-setuptools" ,python2-setuptools)))))
848964fe
LF
7319
7320(define-public python-execnet
7321 (package
7322 (name "python-execnet")
7323 (version "1.4.1")
7324 (source (origin
7325 (method url-fetch)
7326 (uri (pypi-uri "execnet" version))
7327 (sha256
7328 (base32
7329 "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn"))))
7330 (build-system python-build-system)
ca0eee9d
LF
7331 (arguments
7332 `(;; 2 failed, 275 passed, 670 skipped, 4 xfailed
7333 ;; The two test failures are caused by the lack of an `ssh` executable.
7334 ;; The test suite can be run with pytest after the 'install' phase.
7335 #:tests? #f))
848964fe 7336 (native-inputs
ca0eee9d
LF
7337 `(("python-pytest" ,python-pytest)
7338 ("python-setuptools-scm" ,python-setuptools-scm)))
584d068f 7339 (inputs
848964fe
LF
7340 `(("python-apipkg" ,python-apipkg)))
7341 (synopsis "Rapid multi-Python deployment")
7342 (description "Execnet provides a share-nothing model with
7343channel-send/receive communication for distributing execution across many
7344Python interpreters across version, platform and network barriers. It has a
7345minimal and fast API targetting the following uses:
7346@enumerate
7347@item distribute tasks to (many) local or remote CPUs
7348@item write and deploy hybrid multi-process applications
7349@item write scripts to administer multiple environments
7350@end enumerate")
7351 (home-page "http://codespeak.net/execnet/")
16c84f90
CAW
7352 (license license:expat)
7353 (properties `((python2-variant . ,(delay python2-execnet))))))
7354
7355(define-public python2-execnet
7356 (let ((execnet (package-with-python2
7357 (strip-python2-variant python-execnet))))
7358 (package
7359 (inherit execnet)
7360 (native-inputs
7361 `(("python2-setuptools" ,python2-setuptools)
7362 ,@(package-native-inputs execnet))))))
6720dbb4
LF
7363
7364;;; The software provided by this package was integrated into pytest 2.8.
7365(define-public python-pytest-cache
7366 (package
7367 (name "python-pytest-cache")
7368 (version "1.0")
7369 (source (origin
7370 (method url-fetch)
7371 (uri (pypi-uri "pytest-cache" version))
7372 (sha256
7373 (base32
7374 "1a873fihw4rhshc722j4h6j7g3nj7xpgsna9hhg3zn6ksknnhx5y"))))
7375 (build-system python-build-system)
630d938f
EF
7376 (inputs
7377 `(("python-apipkg" ,python-apipkg)
7378 ("python-execnet" ,python-execnet)
7379 ("python-py" ,python-py)
7380 ("python-pytest" ,python-pytest)))
6720dbb4
LF
7381 (synopsis "Py.test plugin with mechanisms for caching across test runs")
7382 (description "The pytest-cache plugin provides tools to rerun failures from
7383the last py.test invocation.")
7384 (home-page "https://bitbucket.org/hpk42/pytest-cache/")
0adc21c2
EF
7385 (license license:expat)
7386 (properties `((python2-variant . ,(delay python2-pytest-cache))))))
7387
7388(define-public python2-pytest-cache
7389 (let ((pytest-cache (package-with-python2
7390 (strip-python2-variant python-pytest-cache))))
7391 (package
7392 (inherit pytest-cache)
7393 (native-inputs
7394 `(("python2-setuptools" ,python2-setuptools)
7395 ,@(package-native-inputs pytest-cache))))))
d7e729fe
LF
7396
7397(define-public python-pytest-localserver
7398 (package
7399 (name "python-pytest-localserver")
29f20168 7400 (version "0.3.5")
d7e729fe
LF
7401 (source (origin
7402 (method url-fetch)
29f20168 7403 (uri (pypi-uri "pytest-localserver" version))
d7e729fe
LF
7404 (sha256
7405 (base32
29f20168 7406 "0dvqspjr6va55zwmnnc2mmpqc7mm65kxig9ya44x1z8aadzxpa4p"))))
d7e729fe
LF
7407 (build-system python-build-system)
7408 (arguments
7409 `(#:phases (modify-phases %standard-phases
7410 (replace 'check
7411 (lambda _
7412 (zero? (system* "py.test" "--genscript=runtests.py"))
7413 (zero? (system* "py.test")))))))
7414 (native-inputs
d7e729fe
LF
7415 `(("python-pytest" ,python-pytest)
7416 ("python-requests" ,python-requests)
9ba40f05
EF
7417 ("python-six" ,python-six)))
7418 (inputs
7419 `(("python-werkzeug" ,python-werkzeug)))
d7e729fe
LF
7420 (synopsis "Py.test plugin to test server connections locally")
7421 (description "Pytest-localserver is a plugin for the pytest testing
7422framework which enables you to test server connections locally.")
7423 (home-page "https://pypi.python.org/pypi/pytest-localserver")
7424 (license license:expat)))
28cecbb7
LF
7425
7426(define-public python-wsgi-intercept
7427 (package
7428 (name "python-wsgi-intercept")
909fbd2b 7429 (version "1.2.2")
28cecbb7
LF
7430 (source (origin
7431 (method url-fetch)
909fbd2b
LF
7432 (uri (string-append
7433 "https://pypi.python.org/packages/"
7434 "38/76/ebcbc24d0cb77db34520a3ca6ed1bd43ace17d182bbd8dd7d976f1c176fb/"
7435 "wsgi_intercept-" version ".tar.gz"))
28cecbb7
LF
7436 (sha256
7437 (base32
909fbd2b 7438 "0kjj2v2dvmnpdd5h5gk9rzz0f54rhjb0yiz3zg65bmp65slfw65d"))))
28cecbb7
LF
7439 (build-system python-build-system)
7440 (native-inputs
9d813ec1 7441 `(("python-pytest" ,python-pytest)
8757f050
LF
7442 ("python-six" ,python-six)
7443 ("python-urllib3" ,python-urllib3)))
28cecbb7
LF
7444 (propagated-inputs
7445 `(("python-httplib2" ,python-httplib2)
7446 ("python-requests" ,python-requests)))
7447 (synopsis "Puts a WSGI application in place of a real URI for testing")
7448 (description "Wsgi_intercept installs a WSGI application in place of a real
7449URI for testing. Testing a WSGI application normally involves starting a
7450server at a local host and port, then pointing your test code to that address.
7451Instead, this library lets you intercept calls to any specific host/port
7452combination and redirect them into a WSGI application importable by your test
7453program. Thus, you can avoid spawning multiple processes or threads to test
7454your Web app.")
7455 (home-page "https://github.com/cdent/wsgi-intercept")
7456 (license license:expat)))
89b8a551
LF
7457
7458(define-public python-pytest-xprocess
7459 (package
7460 (name "python-pytest-xprocess")
7461 (version "0.9.1")
7462 (source (origin
7463 (method url-fetch)
7464 (uri (pypi-uri "pytest-xprocess" version))
7465 (sha256
7466 (base32
7467 "17zlql1xqw3ywcgwwbqmw633aly99lab12hm02asr8awvg5603pp"))))
7468 (build-system python-build-system)
7469 (propagated-inputs
7470 `(("python-pytest" ,python-pytest)
7471 ("python-pytest-cache" ,python-pytest-cache)
7472 ("python-psutil" ,python-psutil)))
7473 (synopsis "Pytest plugin to manage external processes across test runs")
7474 (description "Pytest-xprocess is an experimental py.test plugin for managing
7475processes across test runs.")
7476 (home-page "https://bitbucket.org/pytest-dev/pytest-xprocess")
7477 (license license:expat)))
5c299bf0
LF
7478
7479(define-public python-icalendar
7480 (package
7481 (name "python-icalendar")
f2f53353 7482 (version "3.10")
5c299bf0
LF
7483 (source (origin
7484 (method url-fetch)
7485 (uri (pypi-uri "icalendar" version))
7486 (sha256
7487 (base32
f2f53353 7488 "01amnk3621s7fagfla86npd25knbqirchg7h1jpqxqp103d02bs7"))))
5c299bf0
LF
7489 (build-system python-build-system)
7490 (propagated-inputs
7491 `(("python-dateutil-2" ,python-dateutil-2)
7492 ("python-pytz" ,python-pytz)))
7493 (synopsis "Python library for parsing iCalendar files")
7494 (description "The icalendar package is a parser/generator of iCalendar
7495files for use with Python.")
7496 (home-page "https://github.com/collective/icalendar")
3f641af0 7497 (license license:bsd-2)))
6bbbb53e
LF
7498
7499(define-public python-sphinxcontrib-newsfeed
7500 (package
7501 (name "python-sphinxcontrib-newsfeed")
7502 (version "0.1.4")
7503 (source (origin
7504 (method url-fetch)
7505 (uri (pypi-uri "sphinxcontrib-newsfeed" version))
7506 (sha256
7507 (base32
7508 "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p"))))
7509 (build-system python-build-system)
7510 (propagated-inputs
7511 `(("python-docutils" ,python-docutils)
7512 ("python-sphinx" ,python-sphinx)))
7513 (synopsis "News Feed extension for Sphinx")
7514 (description "Sphinxcontrib-newsfeed is an extension for adding a simple
7515Blog, News or Announcements section to a Sphinx website.")
7516 (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed")
3f641af0 7517 (license license:bsd-2)))
2216e15c
SB
7518
7519(define-public python-args
7520 (package
7521 (name "python-args")
7522 (version "0.1.0")
7523 (source (origin
7524 (method url-fetch)
7525 (uri (pypi-uri "args" version))
7526 (sha256
7527 (base32
7528 "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7"))))
7529 (build-system python-build-system)
7530 (inputs
7531 `(("python-setuptools" ,python-setuptools)))
7532 (home-page "https://github.com/kennethreitz/args")
7533 (synopsis "Command-line argument parser")
7534 (description
7535 "This library provides a Python module to parse command-line arguments.")
3f641af0 7536 (license license:bsd-3)))
2216e15c
SB
7537
7538(define-public python2-args
7539 (package-with-python2 python-args))
c06a3de9
SB
7540
7541(define-public python-clint
7542 (package
7543 (name "python-clint")
7544 (version "0.5.1")
7545 (source (origin
7546 (method url-fetch)
7547 (uri (pypi-uri "clint" version))
7548 (sha256
7549 (base32
7550 "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5"))))
7551 (build-system python-build-system)
7552 (inputs
7553 `(("python-args" ,python-args)
7554 ("python-setuptools" ,python-setuptools)))
7555 (home-page "https://github.com/kennethreitz/clint")
7556 (synopsis "Command-line interface tools")
7557 (description
7558 "Clint is a Python module filled with a set of tools for developing
7559command-line applications, including tools for colored and indented
7560output, progress bar display, and pipes.")
3f641af0 7561 (license license:isc)))
c06a3de9
SB
7562
7563(define-public python2-clint
7564 (package-with-python2 python-clint))
4ecdeef8
SB
7565
7566(define-public python-astor
7567 (package
7568 (name "python-astor")
7569 (version "0.5")
7570 (source (origin
7571 (method url-fetch)
7572 (uri (pypi-uri "astor" version))
7573 (sha256
7574 (base32
7575 "1fdafq5hkis1fxqlmhw0sn44zp2ar46nxhbc22cvwg7hsd8z5gsa"))))
7576 (build-system python-build-system)
7577 (inputs
7578 `(("python-setuptools" ,python-setuptools)))
7579 (home-page "https://github.com/berkerpeksag/astor")
7580 (synopsis "Read and write Python ASTs")
7581 (description
7582 "Astor is designed to allow easy manipulation of Python source via the
7583Abstract Syntax Tree.")
3f641af0 7584 (license license:bsd-3)))
4ecdeef8
SB
7585
7586(define-public python2-astor
7587 (package-with-python2 python-astor))
e224b7d0
SB
7588
7589(define-public python-rply
7590 (package
7591 (name "python-rply")
7592 (version "0.7.4")
7593 (source (origin
7594 (method url-fetch)
7595 (uri (pypi-uri "rply" version))
7596 (sha256
7597 (base32
7598 "12rp1d9ba7nvd5rhaxi6xzx1rm67r1k1ylsrkzhpwnphqpb06cvj"))))
7599 (build-system python-build-system)
7600 (inputs
7601 `(("python-appdirs" ,python-appdirs)
7602 ("python-setuptools" ,python-setuptools)))
7603 (home-page "https://github.com/alex/rply")
7604 (synopsis "Parser generator for Python")
7605 (description
7606 "This package provides a pure Python based parser generator, that also
7607works with RPython. It is a more-or-less direct port of David Bazzley's PLY,
7608with a new public API, and RPython support.")
3f641af0 7609 (license license:bsd-3)))
e224b7d0
SB
7610
7611(define-public python2-rply
7612 (package-with-python2 python-rply))
c3e919d7
SB
7613
7614(define-public python-hy
7615 (package
7616 (name "python-hy")
7617 (version "0.11.1")
7618 (source (origin
7619 (method url-fetch)
7620 (uri (pypi-uri "hy" version))
7621 (sha256
7622 (base32
7623 "1msqv747iz12r73mz4qvsmlwkddwjvrahlrk7ysrcz07h7dsscxs"))))
7624 (build-system python-build-system)
7625 (inputs
7626 `(("python-astor" ,python-astor)
7627 ("python-clint" ,python-clint)
7628 ("python-rply" ,python-rply)
7629 ("python-setuptools" ,python-setuptools)))
7630 (home-page "http://hylang.org/")
7631 (synopsis "Lisp frontend to Python")
7632 (description
7633 "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms
7634its Lisp code into the Python Abstract Syntax Tree, you have the whole world of
7635Python at your fingertips, in Lisp form.")
7636 (license license:expat)))
7637
7638(define-public python2-hy
7639 (package-with-python2 python-hy))
7a5b944e 7640
81f7f297
EF
7641(define-public python-rauth
7642 (package
7643 (name "python-rauth")
7644 (version "0.7.2")
7645 (source
7646 (origin
7647 (method url-fetch)
7648 (uri (pypi-uri "rauth" version))
7649 (sha256
7650 (base32
7651 "00pq7zw429hhza9c0qzxiqp77m653jv09z92nralnmzwdf6pzicf"))))
7652 (build-system python-build-system)
7653 (arguments
7654 `(#:test-target "check"))
0848d8d3 7655 (inputs
81f7f297
EF
7656 `(("python-requests" ,python-requests)))
7657 (home-page "https://github.com/litl/rauth")
7658 (synopsis "Python library for OAuth 1.0/a, 2.0, and Ofly")
7659 (description
7660 "Rauth is a Python library for OAuth 1.0/a, 2.0, and Ofly. It also
7661provides service wrappers for convenient connection initialization and
7662authenticated session objects providing things like keep-alive.")
0848d8d3
EF
7663 (license license:expat)
7664 (properties `((python2-variant . ,(delay python2-rauth))))))
81f7f297
EF
7665
7666(define-public python2-rauth
0848d8d3
EF
7667 (let ((base (package-with-python2 (strip-python2-variant python-rauth))))
7668 (package
7669 (inherit base)
7670 (native-inputs `(("python2-setuptools" ,python2-setuptools)
7671 ("python2-unittest2" ,python2-unittest2)
7672 ,@(package-native-inputs base))))))
81f7f297 7673
1abe448d
EF
7674(define-public python2-functools32
7675 (package
7676 (name "python2-functools32")
7677 (version "3.2.3-2")
7678 (source
7679 (origin
7680 (method url-fetch)
7681 (uri (pypi-uri "functools32" version))
7682 (sha256
7683 (base32
7684 "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn"))))
7685 (build-system python-build-system)
7686 (arguments
7687 `(#:python ,python-2
7688 #:tests? #f)) ; no test target
7689 (native-inputs
7690 `(("python2-setuptools" ,python2-setuptools)))
7691 (home-page "https://github.com/MiCHiLU/python-functools32")
7692 (synopsis
7693 "Backport of the functools module from Python 3.2.3")
7694 (description
7695 "This package is a backport of the @code{functools} module from Python
76963.2.3 for use with older versions of Python and PyPy.")
7697 (license license:expat)))
7698
877889f3 7699(define-public python2-futures
7a5b944e 7700 (package
877889f3 7701 (name "python2-futures")
7a5b944e
EF
7702 (version "3.0.3")
7703 (source
7704 (origin
7705 (method url-fetch)
7706 (uri (pypi-uri "futures" version))
7707 (sha256
7708 (base32
7709 "1vcb34dqhzkhbq1957vdjszhhm5y3j9ba88dgwhqx2zynhmk9qig"))))
7710 (build-system python-build-system)
877889f3 7711 (arguments `(#:python ,python-2))
7a5b944e 7712 (native-inputs
877889f3 7713 `(("python2-setuptools" ,python2-setuptools)))
7a5b944e
EF
7714 (home-page "https://github.com/agronholm/pythonfutures")
7715 (synopsis
7716 "Backport of the concurrent.futures package from Python 3.2")
7717 (description
7718 "The concurrent.futures module provides a high-level interface for
7719asynchronously executing callables. This package backports the
7720concurrent.futures package from Python 3.2")
3f641af0 7721 (license license:bsd-3)))
7a5b944e 7722
5cb2fe44
EF
7723(define-public python-promise
7724 (package
7725 (name "python-promise")
7726 (version "0.4.2")
7727 (source
7728 (origin
7729 (method url-fetch)
7730 (uri (pypi-uri "promise" version))
7731 (sha256
7732 (base32
7733 "1k19ms8l3d5jzjh557rgkxb5sg4mqgfc315rn4hx1z3n8qq6lr3h"))))
7734 (build-system python-build-system)
7735 ;; Tests wants python-futures, which is a python2 only program, and
7736 ;; can't be found by python-promise at test time.
7737 (arguments `(#:tests? #f))
7738 (home-page "https://github.com/syrusakbary/promise")
7739 (synopsis "Promises/A+ implementation for Python")
7740 (description
7741 "Promises/A+ implementation for Python")
7742 (properties `((python2-variant . ,(delay python2-promise))))
7743 (license license:expat)))
7744
7745(define-public python2-promise
7746 (let ((promise (package-with-python2
7747 (strip-python2-variant python-promise))))
7748 (package (inherit promise)
7749 (arguments (substitute-keyword-arguments (package-arguments promise)
7750 ((#:tests? _) #t)))
7751 (native-inputs
7752 `(("python2-futures" ,python2-futures)
7753 ("python2-pytest" ,python2-pytest)
7754 ("python2-setuptools" ,python2-setuptools)
7755 ,@(package-native-inputs promise))))))
7756
c18f6368
EF
7757(define-public python-urllib3
7758 (package
7759 (name "python-urllib3")
7760 (version "1.13.1")
7761 (source
7762 (origin
7763 (method url-fetch)
7764 (uri (pypi-uri "urllib3" version))
7765 (sha256
7766 (base32
7767 "10rrbr6c6k7j5dvfsyj4b2gsgxg9gggnn708qixf6ll57xqivfkf"))))
7768 (build-system python-build-system)
7769 (arguments `(#:tests? #f))
7770 (native-inputs
7771 `(("python-setuptools" ,python-setuptools)
7772 ;; some packages for tests
7773 ("python-nose" ,python-nose)
7774 ("python-mock" ,python-mock)
7775 ("python-tornado" ,python-tornado)))
7776 (propagated-inputs
7777 `(;; packages for https security
7778 ("python-certifi" ,python-certifi)
7779 ("python-ndg-httpsclient" ,python-ndg-httpsclient)
7780 ("python-pyasn1" ,python-pyasn1)
7781 ("python-pyopenssl" ,python-pyopenssl)))
7782 (home-page "http://urllib3.readthedocs.org/")
7783 (synopsis "HTTP library with thread-safe connection pooling")
7784 (description
7785 "Urllib3 supports features left out of urllib and urllib2 libraries. It
7786can reuse the same socket connection for multiple requests, it can POST files,
7787supports url redirection and retries, and also gzip and deflate decoding.")
7788 (license license:expat)))
7789
7790(define-public python2-urllib3
7791 (package-with-python2 python-urllib3))
2b2f2fc1
DT
7792
7793(define-public python-colorama
7794 (package
7795 (name "python-colorama")
7796 (version "0.3.3")
7797 (source
7798 (origin
7799 (method url-fetch)
7800 (uri (pypi-uri "colorama" version))
7801 (sha256
7802 (base32
7803 "1716z9pq1r5ys3nkg7wdrb3h2f9rmd0zdxpxzmx3bgwgf6xg48gb"))))
7804 (build-system python-build-system)
7805 (inputs
7806 `(("python-setuptools" ,python-setuptools)))
7807 (synopsis "colored terminal text rendering for Python")
7808 (description "Colorama is a Python library for rendering colored terminal
7809text.")
7810 (home-page "https://pypi.python.org/pypi/colorama")
3f641af0 7811 (license license:bsd-3)))
2b2f2fc1
DT
7812
7813(define-public python2-colorama
7814 (package-with-python2 python-colorama))
f5bcec6e
DT
7815
7816(define-public python-rsa
7817 (package
7818 (name "python-rsa")
7819 (version "3.2")
7820 (source
7821 (origin
7822 (method url-fetch)
7823 (uri (pypi-uri "rsa" version))
7824 (sha256
7825 (base32
7826 "0xwp929g7lvb1sghxfpqlxvgg96qcwqdbhh27sjplx30n3xp3wrh"))))
7827 (build-system python-build-system)
7828 (inputs
7829 `(("python-pyasn1" ,python-pyasn1)
7830 ("python-setuptools" ,python-setuptools)))
7831 (synopsis "Pure-Python RSA implementation")
7832 (description "Python-RSA is a pure-Python RSA implementation. It supports
7833encryption and decryption, signing and verifying signatures, and key
7834generation according to PKCS#1 version 1.5. It can be used as a Python
7835library as well as on the command line.")
7836 (home-page "http://stuvel.eu/rsa")
3f641af0 7837 (license license:asl2.0)))
f5bcec6e
DT
7838
7839(define-public python2-rsa
7840 (package-with-python2 python-rsa))
c0aacfa5
DT
7841
7842(define-public python-pluggy
7843 (package
7844 (name "python-pluggy")
7845 (version "0.3.1")
7846 (source
7847 (origin
7848 (method url-fetch)
7849 (uri (pypi-uri "pluggy" version))
7850 (sha256
7851 (base32
7852 "18qfzfm40bgx672lkg8q9x5hdh76n7vax99aank7vh2nw21wg70m"))))
7853 (build-system python-build-system)
7854 (inputs
7855 `(("python-setuptools" ,python-setuptools)))
7856 (synopsis "Plugin and hook calling mechanism for Python")
7857 (description "Pluggy is an extraction of the plugin manager as used by
7858Pytest but stripped of Pytest specific details.")
7859 (home-page "https://pypi.python.org/pypi/pluggy")
7860 (license license:expat)))
7861
7862(define-public python2-pluggy
7863 (package-with-python2 python-pluggy))
a4af21ca
DT
7864
7865(define-public python-tox
7866 (package
7867 (name "python-tox")
7868 (version "2.3.1")
7869 (source
7870 (origin
7871 (method url-fetch)
7872 (uri (pypi-uri "tox" version))
7873 (sha256
7874 (base32
7875 "1vj73ar4rimq3fwy5r2z3jv4g9qbh8rmpmncsc00g0k310acqzxz"))))
7876 (build-system python-build-system)
7877 (arguments
7878 ;; FIXME: Tests require a newer version of pytest, but upgrading our
7879 ;; pytest breaks other packages.
7880 '(#:tests? #f))
7881 (inputs
7882 `(("python-setuptools" ,python-setuptools)
7883 ("python-pluggy" ,python-pluggy)
7884 ("python-py" ,python-py)
7885 ("python-virtualenv" ,python-virtualenv)
7886 ("python-pytest" ,python-pytest)))
7887 (home-page "http://tox.testrun.org/")
7888 (synopsis "Virtualenv-based automation of test activities")
7889 (description "Tox is a generic virtualenv management and test command line
7890tool. It can be used to check that a package installs correctly with
7891different Python versions and interpreters, or run tests in each type of
7892supported environment, or act as a frontend to continuous integration
7893servers.")
7894 (license license:expat)))
7895
7896(define-public python2-tox
7897 (package-with-python2 python-tox))
ba9da248
DT
7898
7899(define-public python-jmespath
7900 (package
7901 (name "python-jmespath")
7902 (version "0.9.0")
7903 (source
7904 (origin
7905 (method url-fetch)
7906 (uri (pypi-uri "jmespath" version))
7907 (sha256
7908 (base32
7909 "0g9xvl69y7nr3w7ag4fsp6sm4fqf6vrqjw7504x2hzrrsh3ampq8"))))
7910 (build-system python-build-system)
7911 (inputs
7912 `(("python-setuptools" ,python-setuptools)))
7913 (synopsis "JSON Matching Expressions")
7914 (description "JMESPath (pronounced “james path”) is a Python library that
7915allows one to declaratively specify how to extract elements from a JSON
7916document.")
7917 (home-page "https://github.com/jmespath/jmespath.py")
7918 (license license:expat)))
7919
7920(define-public python2-jmespath
7921 (package-with-python2 python-jmespath))
935fcd5c
DT
7922
7923(define-public python-botocore
7924 (package
7925 (name "python-botocore")
7926 (version "1.3.17")
7927 (source
7928 (origin
7929 (method url-fetch)
7930 (uri (pypi-uri "botocore" version))
7931 (sha256
7932 (base32
7933 "08vpvdixx1c1lfv6vzjig68bpiir7wfyhzf49ysxgvhbprg5ra0w"))))
7934 (build-system python-build-system)
7935 (inputs
7936 `(("python-dateutil" ,python-dateutil-2)
7937 ("python-docutils" ,python-docutils)
7938 ("python-mock" ,python-mock)
7939 ("python-nose" ,python-nose)
7940 ("python-setuptools" ,python-setuptools)
7941 ("python-tox" ,python-tox)
7942 ("python-wheel" ,python-wheel)
7943 ("python-jmespath" ,python-jmespath)))
7944 (home-page "https://github.com/boto/botocore")
7945 (synopsis "Low-level interface to AWS")
7946 (description "Botocore is a Python library that provides a low-level
7947interface to the Amazon Web Services (AWS) API.")
3f641af0 7948 (license license:asl2.0)))
935fcd5c
DT
7949
7950(define-public python2-botocore
7951 (package-with-python2 python-botocore))
f861b8b8
DT
7952
7953(define-public awscli
7954 (package
7955 (name "awscli")
7956 (version "1.9.17")
7957 (source
7958 (origin
7959 (method url-fetch)
7960 (uri (string-append
7961 "https://pypi.python.org/packages/source/a/awscli/awscli-"
7962 version ".tar.gz"))
7963 (sha256
7964 (base32
7965 "1nj7jqvlpq57hfhby1njsbf8303gapa3njc4dramr6p3ffzvfi2i"))))
7966 (build-system python-build-system)
7967 (inputs
7968 `(("python-colorama" ,python-colorama)
7969 ("python-docutils" ,python-docutils)
7970 ("python-mock" ,python-mock)
7971 ("python-nose" ,python-nose)
7972 ("python-rsa" ,python-rsa)
7973 ("python-setuptools" ,python-setuptools)
7974 ("python-sphinx" ,python-sphinx)
7975 ("python-tox" ,python-tox)
7976 ("python-wheel" ,python-wheel)
7977 ("python-botocore" ,python-botocore)))
7978 (home-page "http://aws.amazon.com/cli/")
7979 (synopsis "Command line client for AWS")
7980 (description "AWS CLI provides a unified command line interface to the
7981Amazon Web Services (AWS) API.")
3f641af0 7982 (license license:asl2.0)))
6a44697d
LF
7983
7984(define-public python-hypothesis
7985 (package
7986 (name "python-hypothesis")
bea6d94d 7987 (version "3.1.0")
6a44697d
LF
7988 (source (origin
7989 (method url-fetch)
7990 (uri (pypi-uri "hypothesis" version))
7991 (sha256
7992 (base32
bea6d94d 7993 "0qyqq9akm4vshhn8cngjc1qykcvsn7cz6dlm6njfsgpbraqrmbbw"))))
6a44697d 7994 (build-system python-build-system)
6a44697d
LF
7995 (propagated-inputs
7996 `(("python-flake8" ,python-flake8)
7997 ("python-pytest" ,python-pytest)))
7998 (synopsis "Library for property based testing")
7999 (description "Hypothesis is a library for testing your Python code against a
8000much larger range of examples than you would ever want to write by hand. It’s
8001based on the Haskell library, Quickcheck, and is designed to integrate
8002seamlessly into your existing Python unit testing work flow.")
8003 (home-page "https://github.com/DRMacIver/hypothesis")
3f641af0 8004 (license license:mpl2.0)
6f068e08 8005 (properties `((python2-variant . ,(delay python2-hypothesis))))))
6a44697d
LF
8006
8007(define-public python2-hypothesis
6f068e08
EF
8008 (let ((hypothesis (package-with-python2
8009 (strip-python2-variant python-hypothesis))))
8010 (package (inherit hypothesis)
8011 (native-inputs
8012 `(("python2-enum34" ,python2-enum34)
8013 ("python2-setuptools" ,python2-setuptools))))))
7517e73c
LF
8014
8015(define-public python-pytest-subtesthack
8016 (package
8017 (name "python-pytest-subtesthack")
8018 (version "0.1.1")
8019 (source (origin
8020 (method url-fetch)
8021 (uri (pypi-uri "pytest-subtesthack" version))
8022 (sha256
8023 (base32
8024 "15kzcr5pchf3id4ikdvlv752rc0j4d912n589l4rifp8qsj19l1x"))))
8025 (build-system python-build-system)
8026 (native-inputs
8027 `(;; setuptools required for python-2 variant
8028 ("python-setuptools" ,python-setuptools)))
8029 (propagated-inputs
8030 `(("python-pytest" ,python-pytest)))
8031 (synopsis "Set-up and tear-down fixtures for unit tests")
8032 (description "This plugin allows you to set up and tear down fixtures within
8033unit test functions that use @code{py.test}. This is useful for using
8034@command{hypothesis} inside py.test, as @command{hypothesis} will call the test
8035function multiple times, without setting up or tearing down fixture state as is
8036normally the case.")
8037 (home-page "https://github.com/untitaker/pytest-subtesthack/")
3f641af0 8038 (license license:unlicense)))
7517e73c
LF
8039
8040(define-public python2-pytest-subtesthack
8041 (package-with-python2 python-pytest-subtesthack))
0bdc1671
CAW
8042
8043(define-public python2-xdo
8044 (package
8045 (name "python2-xdo")
8046 (version "0.2")
8047 (source (origin
8048 (method url-fetch)
8049 (uri (string-append
8050 "http://http.debian.net/debian/pool/main/p/python-xdo/"
8051 "python-xdo_" version ".orig.tar.gz"))
8052 (sha256
8053 (base32
8054 "1kl5c1p0dyxf62plnk6fl77ycfb4whwjms16r14dxx8kn90hlqz4"))))
8055 (build-system python-build-system)
8056 (arguments
8057 `(#:python ,python-2
8058 #:tests? #f)) ; no tests provided
8059 (inputs
8060 `(("xdotool" ,xdotool)
8061 ("libX11" ,libx11)))
8062 (home-page "https://tracker.debian.org/pkg/python-xdo")
8063 (synopsis "Python library for simulating X11 keyboard/mouse input")
8064 (description "Provides bindings to libxdo for manipulating X11 via simulated
8065input. (Note that this is mostly a legacy library; you may wish to look at
8066python-xdo for newer bindings.)")
3f641af0 8067 (license license:bsd-3)))
0bdc1671 8068
cb34dc6c
CAW
8069(define-public python-wtforms
8070 (package
8071 (name "python-wtforms")
8072 (version "2.1")
8073 (source
8074 (origin
8075 (method url-fetch)
8076 (uri (pypi-uri "WTForms" version ".zip"))
8077 (sha256
8078 (base32
8079 "0vyl26y9cg409cfyj8rhqxazsdnd0jipgjw06civhrd53yyi1pzz"))))
8080 (build-system python-build-system)
8081 (native-inputs
8082 `(("unzip" ,unzip)))
8083 (home-page "http://wtforms.simplecodes.com/")
8084 (synopsis
8085 "Form validation and rendering library for Python web development")
8086 (description
8087 "WTForms is a flexible forms validation and rendering library
8088for Python web development. It is very similar to the web form API
8089available in Django, but is a standalone package.")
3f641af0 8090 (license license:bsd-3)
cb34dc6c
CAW
8091 (properties `((python2-variant . ,(delay python2-wtforms))))))
8092
8093(define-public python2-wtforms
8094 (package
8095 (inherit (package-with-python2
8096 (strip-python2-variant python-wtforms)))
8097 (inputs `(("python2-setuptools" ,python2-setuptools)))))
50aaec25
DT
8098
8099(define-public python-mako
8100 (package
8101 (name "python-mako")
8102 (version "1.0.3")
8103 (source
8104 (origin
8105 (method url-fetch)
8106 (uri (pypi-uri "Mako" version))
8107 (sha256
8108 (base32
8109 "136kcjbs0s98qkx8a418b05dfblqp0kiiqyx8vhx4rarwc7bqi3n"))))
8110 (build-system python-build-system)
8111 (native-inputs
8112 `(("python-markupsafe" ,python-markupsafe)
8113 ("python-mock" ,python-mock)
8114 ("python-nose" ,python-nose)))
8115 (home-page "http://www.makotemplates.org/")
8116 (synopsis "Templating language for Python")
8117 (description "Mako is a templating language for Python that compiles
8118templates into Python modules.")
8119 (license license:expat)
8120 (properties `((python2-variant . ,(delay python2-mako))))))
8121
8122(define-public python2-mako
8123 (let ((base (package-with-python2
8124 (strip-python2-variant python-mako))))
8125 (package
8126 (inherit base)
8127 (native-inputs
8128 (cons `("python2-setuptools" ,python2-setuptools)
8129 (package-native-inputs base))))))
ae00a41f
CAW
8130
8131(define-public python-waitress
8132 (package
8133 (name "python-waitress")
8134 (version "0.8.10")
8135 (source
8136 (origin
8137 (method url-fetch)
8138 (uri (pypi-uri "waitress" version))
8139 (sha256
8140 (base32
8141 "017n9ra6vvmq9d5sfhdzyzr1mg15x2hj2dhm4pdlw98c1ypw2h3w"))))
8142 (build-system python-build-system)
8143 (home-page "https://github.com/Pylons/waitress")
8144 (synopsis "Waitress WSGI server")
8145 (description "Waitress is meant to be a production-quality pure-Python WSGI
8146server with very acceptable performance.")
3f641af0 8147 (license license:zpl2.1)
ae00a41f
CAW
8148 (properties `((python2-variant . ,(delay python2-waitress))))))
8149
8150(define-public python2-waitress
8151 (package
8152 (inherit (package-with-python2
8153 (strip-python2-variant python-waitress)))
8154 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
778a284b
CAW
8155
8156(define-public python-wsgiproxy2
8157 (package
8158 (name "python-wsgiproxy2")
8159 (version "0.4.2")
8160 (source
8161 (origin
8162 (method url-fetch)
8163 (uri (pypi-uri "WSGIProxy2" version ".zip"))
8164 (sha256
8165 (base32
8166 "13kf9bdxrc95y9vriaz0viry3ah11nz4rlrykcfvb8nlqpx3dcm4"))))
8167 (build-system python-build-system)
8168 (native-inputs
8169 `(("unzip" ,unzip)
8170 ("python-nose" ,python-nose)
8171 ("python-coverage" ,python-coverage)))
8172 (propagated-inputs
8173 `(("python-six" ,python-six)
8174 ("python-webob" ,python-webob)))
8175 (home-page
8176 "https://github.com/gawel/WSGIProxy2/")
8177 (synopsis "WSGI Proxy with various http client backends")
8178 (description "WSGI turns HTTP requests into WSGI function calls.
8179WSGIProxy turns WSGI function calls into HTTP requests.
8180It also includes code to sign requests and pass private data,
8181and to spawn subprocesses to handle requests.")
8182 (license license:expat)
8183 (properties `((python2-variant . ,(delay python2-wsgiproxy2))))))
8184
8185(define-public python2-wsgiproxy2
8186 (let ((wsgiproxy2 (package-with-python2
8187 (strip-python2-variant python-wsgiproxy2))))
8188 (package
8189 (inherit wsgiproxy2)
8190 (inputs `(("python2-setuptools" ,python2-setuptools)
8191 ,@(package-inputs wsgiproxy2))))))
bb7518b1
CAW
8192
8193(define-public python-pastedeploy
8194 (package
8195 (name "python-pastedeploy")
8196 (version "1.5.2")
8197 (source
8198 (origin
8199 (method url-fetch)
8200 (uri (pypi-uri "PasteDeploy" version))
8201 (sha256
8202 (base32
8203 "1jz3m4hq8v6hyhfjz9425nd3nvn52cvbfipdcd72krjmla4qz1fm"))))
8204 (build-system python-build-system)
8205 (native-inputs
8206 `(("python-nose" ,python-nose)))
8207 (propagated-inputs
8208 ;; This package uses pkg_resources, part of setuptools, during runtime,
8209 ;; hence why not a native-input.
8210 `(("python-setuptools" ,python-setuptools)))
8211 (home-page "http://pythonpaste.org/deploy/")
8212 (synopsis
8213 "Load, configure, and compose WSGI applications and servers")
8214 (description
8215 "This tool provides code to load WSGI applications and servers from URIs;
8216these URIs can refer to Python Eggs for INI-style configuration files. Paste
8217Script provides commands to serve applications based on this configuration
8218file.")
8219 (license license:expat)))
8220
8221(define-public python2-pastedeploy
8222 (package-with-python2 python-pastedeploy))
1cf53652 8223
c4a7904c
CAW
8224(define-public python-paste
8225 (package
8226 (name "python-paste")
8227 (version "2.0.2")
8228 (source
8229 (origin
8230 (method url-fetch)
8231 (uri (pypi-uri "Paste" version))
8232 (sha256
8233 (base32
8234 "16dsv9qi0r4qsrsb6dilpq2rx0fnglvh36flzywcdnm2jg43mb5d"))
fc1adab1
AK
8235 (patches (search-patches "python-paste-remove-website-test.patch"
8236 "python-paste-remove-timing-test.patch"))))
c4a7904c
CAW
8237 (build-system python-build-system)
8238 (native-inputs
8239 `(("python-nose" ,python-nose)))
8240 (propagated-inputs
8241 `(;; Uses pkg_resources provided by setuptools internally.
8242 ("python-setuptools" ,python-setuptools)
8243 ("python-six" ,python-six)))
8244 (arguments
8245 '(;; Tests don't pass on Python 3, but work fine on Python 2.
8246 ;; (As of 2.0.2, Python 3 support in Paste is presently a bit broken,
8247 ;; but is usable enough for the minimal amount it's used in MediaGoblin
8248 ;; still... things should be better by the next Paste release.)
8249 #:tests? #f))
8250 (home-page "http://pythonpaste.org")
8251 (synopsis
8252 "Python web development tools, focusing on WSGI")
8253 (description
8254 "Paste provides a variety of web development tools and middleware which
8255can be nested together to build web applications. Paste's design closely
8256follows ideas flowing from WSGI (Web Standard Gateway Interface).")
8257 (license license:expat)
8258 (properties `((python2-variant . ,(delay python2-paste))))))
8259
8260(define-public python2-paste
8261 (let ((paste (package-with-python2
8262 (strip-python2-variant python-paste))))
8263 (package
8264 (inherit paste)
8265 (arguments
8266 ;; Tests are back for Python 2!
8267 `(#:tests? #t
8268 ,@(package-arguments paste))))))
8269
a8f20f63
CAW
8270(define-public python-pastescript
8271 (package
8272 (name "python-pastescript")
8273 (version "2.0.2")
8274 (source
8275 (origin
8276 (method url-fetch)
8277 (uri (pypi-uri "PasteScript" version))
8278 (sha256
8279 (base32
8280 "1h3nnhn45kf4pbcv669ik4faw04j58k8vbj1hwrc532k0nc28gy0"))))
8281 (build-system python-build-system)
8282 (native-inputs
8283 `(("python-nose" ,python-nose)))
8284 (propagated-inputs
8285 `(;; Uses pkg_resources provided by setuptools internally.
8286 ("python-setuptools" ,python-setuptools)
8287 ("python-paste" ,python-paste)
8288 ("python-pastedeploy" ,python-pastedeploy)))
8289 (home-page "http://pythonpaste.org/script/")
8290 (arguments
8291 '(;; Unfortunately, this requires the latest unittest2,
8292 ;; but that requires traceback2 which requires linecache2 which requires
8293 ;; unittest2. So we're skipping tests for now.
8294 ;; (Note: Apparently linetest2 only needs unittest2 for its tests,
8295 ;; so in theory we could get around this situation somehow.)
8296 #:tests? #f))
8297 (synopsis
8298 "Pluggable command line tool for serving web applications and more")
8299 (description
8300 "PasteScript is a plugin-friendly command line tool which provides a
8301variety of features, from launching web applications to bootstrapping project
8302layouts.")
8303 (license license:expat)))
8304
8305(define-public python2-pastescript
8306 (package-with-python2 python-pastescript))
8307
1cf53652
CAW
8308(define-public python-pyquery
8309 (package
8310 (name "python-pyquery")
aab76e80 8311 (version "1.2.13")
1cf53652
CAW
8312 (source
8313 (origin
8314 (method url-fetch)
8315 (uri (pypi-uri "pyquery" version))
8316 (sha256
8317 (base32
aab76e80 8318 "0j9fsisip21qv4xljsg5dmni1pgpvwrjyyhhql0glydc4bs5rjgv"))))
1cf53652
CAW
8319 (build-system python-build-system)
8320 (propagated-inputs
8321 `(("python-lxml" ,python-lxml)
8322 ("python-cssselect" ,python-cssselect)))
8323 (home-page "https://github.com/gawel/pyquery")
8324 (synopsis "Make jQuery-like queries on xml documents")
8325 (description "pyquery allows you to make jQuery queries on xml documents.
8326The API is as much as possible the similar to jQuery. pyquery uses lxml for
8327fast xml and html manipulation.")
3f641af0 8328 (license license:bsd-3)
1cf53652
CAW
8329 (properties `((python2-variant . ,(delay python2-pyquery))))))
8330
8331(define-public python2-pyquery
8332 (let ((pyquery (package-with-python2
8333 (strip-python2-variant python-pyquery))))
8334 (package
8335 (inherit pyquery)
8336 (native-inputs `(("python2-setuptools" ,python2-setuptools))))))
aa6313d6
CAW
8337
8338(define-public python-webtest
8339 (package
8340 (name "python-webtest")
8341 (version "2.0.20")
8342 (source
8343 (origin
8344 (method url-fetch)
8345 (uri (pypi-uri "WebTest" version))
8346 (sha256
8347 (base32
8348 "0bv0qhdjakdsdgj4sk21gnpp8xp8bga4x03p6gjb83ihrsb7n4xv"))))
8349 (build-system python-build-system)
8350 (arguments
8351 `(;; Unfortunately we have to disable tests!
8352 ;; This release of WebTest is pinned to python-nose < 1.3,
8353 ;; but older versions of python-nose are plagued with the following
8354 ;; bug(s), which rears its ugly head during test execution:
8355 ;; https://github.com/nose-devs/nose/issues/759
8356 ;; https://github.com/nose-devs/nose/pull/811
8357 #:tests? #f))
8358 ;; Commented out code is no good, but in this case, once tests
8359 ;; are ready to be enabled again, we should put the following
8360 ;; in place:
8361 ;; (native-inputs
8362 ;; `(("python-nose" ,python-nose) ; technially < 1.3,
8363 ;; ; but see above comment
8364 ;; ("python-coverage" ,python-coverage)
8365 ;; ("python-mock" ,python-mock)
8366 ;; ("python-pastedeploy" ,python-pastedeploy)
8367 ;; ("python-wsgiproxy2" ,python-wsgiproxy2)
8368 ;; ("python-pyquery" ,python-pyquery)))
8369 (propagated-inputs
8370 `(("python-waitress" ,python-waitress)
8371 ("python-webob" ,python-webob)
8372 ("python-six" ,python-six)
8373 ("python-beautifulsoup4" ,python-beautifulsoup4)))
8374 (home-page "http://webtest.pythonpaste.org/")
8375 (synopsis "Helper to test WSGI applications")
8376 (description "Webtest allows you to test your Python web applications
8377without starting an HTTP server. It supports anything that supports the
8378minimum of WSGI.")
8379 (license license:expat)
8380 (properties `((python2-variant . ,(delay python2-webtest))))))
8381
8382(define-public python2-webtest
8383 (let ((webtest (package-with-python2
8384 (strip-python2-variant python-webtest))))
8385 (package
8386 (inherit webtest)
8387 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8388 ,@(package-native-inputs webtest))))))
4cb122cd
CAW
8389
8390(define-public python-anyjson
8391 (package
8392 (name "python-anyjson")
8393 (version "0.3.3")
8394 (source
8395 (origin
8396 (method url-fetch)
8397 (uri (pypi-uri "anyjson" version))
8398 (sha256
8399 (base32
8400 "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p"))))
8401 (build-system python-build-system)
8402 (arguments
8403 `(;; We could possibly get tests working, but on Python 3 it's not so easy.
8404 ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or
8405 ;; whatever) so this transformation needs to be done before the tests
8406 ;; can be run. Maybe we could add a build step to transform beforehand
8407 ;; but it could be annoying/difficult.
8408 ;; We can enable tests for the Python 2 version, though, and do below.
8409 #:tests? #f))
8410 (home-page "http://bitbucket.org/runeh/anyjson/")
8411 (synopsis
8412 "Wraps best available JSON implementation in a common interface")
8413 (description
8414 "Anyjson loads whichever is the fastest JSON module installed
8415and provides a uniform API regardless of which JSON implementation is used.")
3f641af0 8416 (license license:bsd-3)
4cb122cd
CAW
8417 (properties `((python2-variant . ,(delay python2-anyjson))))))
8418
8419(define-public python2-anyjson
8420 (let ((anyjson (package-with-python2
8421 (strip-python2-variant python-anyjson))))
8422 (package
8423 (inherit anyjson)
8424 (arguments `(;; Unlike the python 3 variant, we do run tests. See above!
8425 #:tests? #t
8426 ,@(package-arguments anyjson)))
8427 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8428 ("python2-nose" ,python2-nose))))))
8dfceab7
CAW
8429
8430(define-public python-amqp
8431 (package
8432 (name "python-amqp")
8433 (version "1.4.9")
8434 (source
8435 (origin
8436 (method url-fetch)
8437 (uri (pypi-uri "amqp" version))
8438 (sha256
8439 (base32
8440 "06n6q0kxhjnbfz3vn8x9yz09lwmn1xi9d6wxp31h5jbks0b4vsid"))))
8441 (build-system python-build-system)
8442 (native-inputs
8443 `(("python-nose" ,python-nose)
8444 ("python-mock" ,python-mock)))
8445 (home-page "http://github.com/celery/py-amqp")
8446 (synopsis
8447 "Low-level AMQP client for Python (fork of amqplib)")
8448 (description
8449 "This is a fork of amqplib which was originally written by Barry Pederson.
8450It is maintained by the Celery project, and used by kombu as a pure python
8451alternative when librabbitmq is not available.")
3f641af0 8452 (license license:lgpl2.1+)
8dfceab7
CAW
8453 (properties `((python2-variant . ,(delay python2-amqp))))))
8454
8455(define-public python2-amqp
8456 (let ((amqp (package-with-python2
8457 (strip-python2-variant python-amqp))))
8458 (package
8459 (inherit amqp)
8460 (arguments `(;; Tries to run coverage tests with nose-cover3, which seems
8461 ;; unmaintained. Weirdly, does not do this on the python 3
8462 ;; version?
8463 #:tests? #f
8464 ,@(package-arguments amqp)))
8465 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8466 ,@(package-native-inputs amqp))))))
7d387305
CAW
8467
8468(define-public python-kombu
8469 (package
8470 (name "python-kombu")
0cb59822 8471 (version "3.0.37")
7d387305
CAW
8472 (source
8473 (origin
8474 (method url-fetch)
8475 (uri (pypi-uri "kombu" version))
8476 (sha256
8477 (base32
0cb59822 8478 "0l16chb314gpq2v7fh94a22c30lcv6w3ylmhsa60bldlcq6a0r70"))))
7d387305
CAW
8479 (build-system python-build-system)
8480 (native-inputs
8481 `(("python-mock" ,python-mock)
8482 ("python-nose" ,python-nose)))
8483 (propagated-inputs
8484 `(("python-anyjson" ,python-anyjson)
0cb59822
LF
8485 ("python-amqp" ,python-amqp)
8486 ("python-redis" ,python-redis)))
7d387305
CAW
8487 (home-page "http://kombu.readthedocs.org")
8488 (synopsis "Message passing library for Python")
8489 (description "The aim of Kombu is to make messaging in Python as easy as
8490possible by providing an idiomatic high-level interface for the AMQ protocol,
8491and also provide proven and tested solutions to common messaging problems.
8492AMQP is the Advanced Message Queuing Protocol, an open standard protocol for
8493message orientation, queuing, routing, reliability and security, for which the
8494RabbitMQ messaging server is the most popular implementation.")
3f641af0 8495 (license license:bsd-3)
7d387305
CAW
8496 (properties `((python2-variant . ,(delay python2-kombu))))))
8497
8498(define-public python2-kombu
8499 (let ((kombu (package-with-python2
8500 (strip-python2-variant python-kombu))))
8501 (package
8502 (inherit kombu)
8503 (inputs `(("python2-setuptools" ,python2-setuptools)
8504 ("python2-unittest2" ,python2-unittest2)
8505 ,@(package-inputs kombu))))))
b6f0b9fb
CAW
8506
8507(define-public python-billiard
8508 (package
8509 (name "python-billiard")
a6bb9e44 8510 (version "3.3.0.23")
b6f0b9fb
CAW
8511 (source
8512 (origin
8513 (method url-fetch)
8514 (uri (pypi-uri "billiard" version))
8515 (sha256
8516 (base32
a6bb9e44 8517 "02wxsc6bhqvzh8j6w758kvgqbnj14l796mvmrcms8fgfamd2lak9"))))
b6f0b9fb
CAW
8518 (build-system python-build-system)
8519 (native-inputs
8520 `(("python-nose" ,python-nose)))
8521 (home-page "http://github.com/celery/billiard")
8522 (synopsis
8523 "Python multiprocessing fork with improvements and bugfixes")
8524 (description
8525 "Billiard is a fork of the Python 2.7 multiprocessing package. The
8526multiprocessing package itself is a renamed and updated version of R Oudkerk's
8527pyprocessing package. This standalone variant is intended to be compatible with
8528Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.")
3f641af0 8529 (license license:bsd-3)
b6f0b9fb
CAW
8530 (properties `((python2-variant . ,(delay python2-billiard))))))
8531
8532(define-public python2-billiard
8533 (let ((billiard (package-with-python2
8534 (strip-python2-variant python-billiard))))
8535 (package
8536 (inherit billiard)
8537 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8538 ("python2-unittest2" ,python2-unittest2)
8539 ("python2-mock" ,python2-mock)
8540 ,@(package-native-inputs billiard))))))
22df6419
CAW
8541
8542(define-public python-celery
8543 (package
8544 (name "python-celery")
9ebe87fe 8545 (version "3.1.24")
22df6419
CAW
8546 (source
8547 (origin
8548 (method url-fetch)
8549 (uri (pypi-uri "celery" version))
8550 (sha256
8551 (base32
9ebe87fe 8552 "0yh2prhdnx2dgkb67a5drj12hh2zvzx5f611p7mqqg01ydghif4r"))))
22df6419 8553 (build-system python-build-system)
9ebe87fe
LF
8554 (arguments
8555 `(#:phases
8556 (modify-phases %standard-phases
8557 ;; These tests break with Python 3.5:
8558 ;; https://github.com/celery/celery/issues/2897#issuecomment-253066295
8559 (replace 'check
8560 (lambda _
8561 (zero?
8562 (system* "nosetests" "--exclude=^test_safe_to_remove.*")))))))
22df6419
CAW
8563 (native-inputs
8564 `(("python-nose" ,python-nose)))
a64cbb6f 8565 (inputs
22df6419 8566 `(("python-pytz" ,python-pytz)
a64cbb6f
EF
8567 ("python-amqp" ,python-amqp)
8568 ("python-anyjson" ,python-anyjson)
22df6419
CAW
8569 ("python-billiard" ,python-billiard)
8570 ("python-kombu" ,python-kombu)))
8571 (home-page "http://celeryproject.org")
8572 (synopsis "Distributed Task Queue")
8573 (description "Celery is an asynchronous task queue/job queue based on
8574distributed message passing. It is focused on real-time operation, but
8575supports scheduling as well. The execution units, called tasks, are executed
8576concurrently on a single or more worker servers using multiprocessing,
8577Eventlet, or gevent. Tasks can execute asynchronously (in the background) or
8578synchronously (wait until ready).")
3f641af0 8579 (license license:bsd-3)
22df6419
CAW
8580 (properties `((python2-variant . ,(delay python2-celery))))))
8581
8582(define-public python2-celery
8583 (let ((celery (package-with-python2
8584 (strip-python2-variant python-celery))))
8585 (package
8586 (inherit celery)
8587 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8588 ("python2-unittest2" ,python2-unittest2)
8589 ("python2-mock" ,python2-mock)
8590 ,@(package-native-inputs celery))))))
97e32948
CAW
8591
8592(define-public python-translitcodec
8593 (package
8594 (name "python-translitcodec")
8595 (version "0.4.0")
8596 (source
8597 (origin
8598 (method url-fetch)
8599 (uri (pypi-uri "translitcodec" version))
8600 (sha256
8601 (base32
8602 "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki"))))
8603 (build-system python-build-system)
8604 (arguments
8605 `(#:tests? #f)) ; no tests provided
8606 (home-page
8607 "https://github.com/claudep/translitcodec")
8608 (synopsis
8609 "Unicode to 8-bit charset transliteration codec")
8610 (description
8611 "This package contains codecs for transliterating ISO 10646 texts into
8612best-effort representations using smaller coded character sets (ASCII,
8613ISO 8859, etc.).")
8614 (license license:expat)
8615 (properties `((python2-variant . ,(delay python2-translitcodec))))))
8616
8617(define-public python2-translitcodec
8618 (package
8619 (inherit (package-with-python2
8620 (strip-python2-variant python-translitcodec)))
8621 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
0c3b90d4
CAW
8622
8623(define-public python-editor
8624 (package
8625 (name "python-editor")
8626 (version "0.5")
8627 (source
8628 (origin
8629 (method url-fetch)
8630 (uri (pypi-uri "python-editor" version))
8631 (sha256
8632 (base32
8633 "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n"))))
8634 (build-system python-build-system)
8635 (home-page
8636 "https://github.com/fmoo/python-editor")
8637 (synopsis
8638 "Programmatically open an editor, capture the result")
8639 (description
8640 "python-editor is a library that provides the editor module for
8641programmatically interfacing with your system's $EDITOR.")
3f641af0 8642 (license license:asl2.0)
0c3b90d4
CAW
8643 (properties `((python2-variant . ,(delay python2-editor))))))
8644
8645(define-public python2-editor
8646 (package
8647 (inherit (package-with-python2
8648 (strip-python2-variant python-editor)))
8649 (inputs `(("python2-setuptools" ,python2-setuptools)))))
3276517c
LF
8650
8651(define-public python-sphinxcontrib-programoutput
8652 (package
8653 (name "python-sphinxcontrib-programoutput")
8654 (version "0.8")
8655 (source (origin
8656 (method url-fetch)
8657 (uri (pypi-uri "sphinxcontrib-programoutput" version))
8658 (sha256
8659 (base32
8660 "098as6z1s0gb4dh5xcr1fd2vpm91zj93jzvgawspxf5s4hqs0xhp"))))
8661 (build-system python-build-system)
8662 (propagated-inputs
8663 `(("python-docutils" ,python-docutils)
8664 ("python-sphinx" ,python-sphinx)))
8665 (synopsis "Sphinx extension to include program output")
8666 (description "A Sphinx extension to literally insert the output of arbitrary
8667commands into documents, helping you to keep your command examples up to date.")
8668 (home-page "https://github.com/lunaryorn/sphinxcontrib-programoutput")
3f641af0 8669 (license license:bsd-2)
3276517c
LF
8670 (properties `((python2-variant . ,(delay python2-sphinxcontrib-programoutput))))))
8671
8672(define-public python2-sphinxcontrib-programoutput
8673 (package
8674 (inherit (package-with-python2
8675 (strip-python2-variant python-sphinxcontrib-programoutput)))
8676 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
548d7165
LF
8677
8678(define-public python-sphinx-repoze-autointerface
8679 (package
8680 (name "python-sphinx-repoze-autointerface")
328ae341 8681 (version "0.8")
548d7165
LF
8682 (source (origin
8683 (method url-fetch)
8684 (uri (pypi-uri "repoze.sphinx.autointerface" version))
8685 (sha256
8686 (base32
328ae341 8687 "08ycivzf7bh4a1zcyp31hbyqs1b2c9r26raa3vxjwwmbfqr3iw4f"))))
548d7165
LF
8688 (build-system python-build-system)
8689 (propagated-inputs
8690 `(("python-docutils" ,python-docutils)
8691 ("python-sphinx" ,python-sphinx)
8692 ("python-zope-interface" ,python-zope-interface)))
8693 (synopsis "Auto-generate Sphinx API docs from Zope interfaces")
8694 (description "This package defines an extension for the Sphinx documentation
8695system. The extension allows generation of API documentation by
8696introspection of @code{zope.interface} instances in code.")
8697 (home-page "https://github.com/repoze/repoze.sphinx.autointerface")
3f641af0 8698 (license license:repoze)))
548d7165
LF
8699
8700(define-public python2-sphinx-repoze-autointerface
8701 (package-with-python2 python-sphinx-repoze-autointerface))
b31fbea5
DM
8702
8703(define-public python-psycopg2
8704 (package
8705 (name "python-psycopg2")
8706 (version "2.6.1")
8707 (source
8708 (origin
8709 (method url-fetch)
8710 (uri (pypi-uri "psycopg2" version))
8711 (sha256
8712 (base32
8713 "0k4hshvrwsh8yagydyxgmd0pjm29lwdxkngcq9fzfzkmpsxrmkva"))))
8714 (build-system python-build-system)
8715 (arguments
8716 ;; Tests would require a postgresql database "psycopg2_test"
8717 ;; and a running postgresql database management service.
8718 `(#:tests? #f)) ; TODO re-enable after providing a test-db.
8719 (inputs
8720 `(("postgresql" ,postgresql))) ; libpq
8721 (home-page "http://initd.org/psycopg/")
8722 (synopsis "Python PostgreSQL adapter")
8723 (description
8724 "psycopg2 is a thread-safe PostgreSQL adapter that implements DB-API 2.0. ")
3f641af0 8725 (license license:lgpl3+)
b31fbea5
DM
8726 (properties `((python2-variant . ,(delay python2-psycopg2))))))
8727
8728(define-public python2-psycopg2
8729 (package
8730 (inherit (package-with-python2
8731 (strip-python2-variant python-psycopg2)))
8732 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
eed1a61f
LF
8733
8734(define-public python-vobject
8735 (package
8736 (name "python-vobject")
9bed9b15 8737 (version "0.9.2")
eed1a61f
LF
8738 (source (origin
8739 (method url-fetch)
8740 (uri (pypi-uri "vobject" version))
8741 (sha256
8742 (base32
9bed9b15 8743 "1qfnwlx8qwkgr6nf5wvl6ff1r3kll53dh3z6nyp173nmlhhhqccb"))))
eed1a61f 8744 (build-system python-build-system)
a9871b7b
LF
8745 (arguments
8746 '(;; The test suite relies on some non-portable Windows interfaces.
8747 #:tests? #f))
eed1a61f
LF
8748 (inputs
8749 `(("python-dateutil-2" ,python-dateutil-2)
8750 ("python-pyicu" ,python-pyicu)))
8751 (synopsis "Parse and generate vCard and vCalendar files")
8752 (description "Vobject is intended to be a full featured Python package for
8753parsing and generating vCard and vCalendar files. Currently, iCalendar files
8754are supported and well tested. vCard 3.0 files are supported, and all data
8755should be imported, but only a few components are understood in a sophisticated
8756way.")
8757 (home-page "http://eventable.github.io/vobject/")
3f641af0 8758 (license license:asl2.0)
eed1a61f
LF
8759 (properties `((python2-variant . ,(delay python2-vobject))))))
8760
8761(define-public python2-vobject
8762 (package
8763 (inherit (package-with-python2
8764 (strip-python2-variant python-vobject)))
8765 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
cedac813
LF
8766
8767(define-public python-munkres
8768 (package
8769 (name "python-munkres")
8770 (version "1.0.7")
8771 (source (origin
8772 (method url-fetch)
8773 (uri (pypi-uri "munkres" version))
8774 (sha256
8775 (base32
8776 "1i6nf45i0kkzdx6k70giybsqxz4dxsjbrkrfqgjd7znfkf25sjik"))))
8777 (build-system python-build-system)
8778 (arguments
8779 '(#:tests? #f)) ; no test suite
8780 (home-page "http://software.clapper.org/munkres/")
8781 (synopsis "Implementation of the Munkres algorithm")
8782 (description "The Munkres module provides an implementation of the Munkres
8783algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm),
8784useful for solving the Assignment Problem.")
3f641af0 8785 (license license:bsd-3)))
cedac813
LF
8786
8787(define-public python2-munkres
8788 (package-with-python2 python-munkres))
f3b3d78f
LF
8789
8790(define-public python-flask
8791 (package
8792 (name "python-flask")
8793 (version "0.10.1")
8794 (source (origin
8795 (method url-fetch)
8796 (uri (pypi-uri "Flask" version))
8797 (sha256
8798 (base32
8799 "0wrkavjdjndknhp8ya8j850jq7a1cli4g5a93mg8nh1xz2gq50sc"))))
8800 (build-system python-build-system)
8801 (propagated-inputs
8802 `(("python-itsdangerous" ,python-itsdangerous)
8803 ("python-jinja2" ,python-jinja2)
8804 ("python-werkzeug" ,python-werkzeug)))
8805 (home-page "https://github.com/mitsuhiko/flask/")
8806 (synopsis "Microframework based on Werkzeug, Jinja2 and good intentions")
8807 (description "Flask is a micro web framework based on the Werkzeug toolkit
8808and Jinja2 template engine. It is called a micro framework because it does not
8809presume or force a developer to use a particular tool or library.")
3f641af0 8810 (license license:bsd-3)
f3b3d78f
LF
8811 (properties `((python2-variant . ,(delay python2-flask))))))
8812
8813(define-public python2-flask
8814 (package (inherit (package-with-python2
8815 (strip-python2-variant python-flask)))
8816 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
603d665b
LF
8817
8818(define-public python-cookies
8819 (package
8820 (name "python-cookies")
8821 (version "2.2.1")
8822 (source (origin
8823 (method url-fetch)
8824 (uri (pypi-uri "cookies" version))
8825 (sha256
8826 (base32
8827 "13pfndz8vbk4p2a44cfbjsypjarkrall71pgc97glk5fiiw9idnn"))))
8828 (build-system python-build-system)
8829 (arguments
8830 `(;; test are broken: https://gitlab.com/sashahart/cookies/issues/3
8831 #:tests? #f))
8832 (native-inputs
8833 `(("python-pytest" ,python2-pytest)))
8834 (synopsis "HTTP cookie parser and renderer")
8835 (description "A RFC 6265-compliant HTTP cookie parser and renderer in
8836Python.")
8837 (home-page "https://gitlab.com/sashahart/cookies")
8838 (license license:expat)
8839 (properties `((python2-variant . ,(delay python2-cookies))))))
8840
8841(define-public python2-cookies
8842 (let ((cookies (package-with-python2
8843 (strip-python2-variant python-cookies))))
8844 (package (inherit cookies)
8845 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8846 ,@(package-native-inputs cookies))))))
0efde7d6
LF
8847
8848(define-public python-responses
8849 (package
8850 (name "python-responses")
8851 (version "0.5.1")
8852 (source (origin
8853 (method url-fetch)
8854 (uri (pypi-uri "responses" version))
8855 (sha256
8856 (base32
8857 "1spcfxixyk9k7pk82jm6zqkwk031s95lh8q0mz7539jrb7269bcc"))))
8858 (build-system python-build-system)
8859 (arguments
8860 `(;; Test suite is not distributed:
8861 ;; https://github.com/getsentry/responses/issues/38
8862 #:tests? #f))
8863 (native-inputs
8864 `(("python-cookies" ,python-cookies)
8865 ("python-mock" ,python-mock)))
8866 (propagated-inputs
8867 `(("python-requests" ,python-requests)
8868 ("python-six" ,python-six)))
8869 (home-page "https://github.com/getsentry/responses")
8870 (synopsis "Utility for mocking out the `requests` Python library")
8871 (description "A utility library for mocking out the `requests` Python
8872library.")
3f641af0 8873 (license license:asl2.0)
0efde7d6
LF
8874 (properties `((python2-variant . ,(delay python2-responses))))))
8875
8876(define-public python2-responses
8877 (let ((responses (package-with-python2
8878 (strip-python2-variant python-responses))))
8879 (package (inherit responses)
8880 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8881 ,@(package-native-inputs responses))))))
76b94885
LF
8882
8883(define-public python-pathlib
8884 (package
8885 (name "python-pathlib")
8886 (version "1.0.1")
8887 (source (origin
8888 (method url-fetch)
8889 (uri (pypi-uri "pathlib" version))
8890 (sha256
8891 (base32
8892 "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39"))))
8893 (build-system python-build-system)
92a312dc
RW
8894 ;; The tests depend on the internal "test" module, which does not provide
8895 ;; a stable interface.
8896 (arguments `(#:tests? #f))
76b94885 8897 (home-page "https://pathlib.readthedocs.org/")
8f65585b
JD
8898 (synopsis "Object-oriented file system paths")
8899 (description "Pathlib offers a set of classes to handle file system paths.
76b94885
LF
8900It offers the following advantages over using string objects:
8901
8902@enumerate
8903@item No more cumbersome use of os and os.path functions. Everything can
8904be done easily through operators, attribute accesses, and method calls.
8905@item Embodies the semantics of different path types. For example,
8906comparing Windows paths ignores casing.
8907@item Well-defined semantics, eliminating any inconsistencies or
8908ambiguities (forward vs. backward slashes, etc.).
8909@end enumerate\n")
8910 (license license:expat)))
8911
8912(define-public python2-pathlib
8913 (package-with-python2 python-pathlib))
25a7db0a
LF
8914
8915(define-public python-jellyfish
8916 (package
8917 (name "python-jellyfish")
8918 (version "0.5.3")
8919 (source (origin
8920 (method url-fetch)
8921 (uri (pypi-uri "jellyfish" version))
8922 (sha256
8923 (base32
8924 "12bxh8cy9xmvyrjz7aw159nd5pyvb645rkvw4r6bvm4xbvs8gd07"))))
8925 (build-system python-build-system)
8926 (native-inputs
8927 `(("python-pytest" ,python-pytest)))
8928 (home-page "https://github.com/jamesturk/jellyfish")
8929 (synopsis "Approximate and phonetic matching of strings")
8930 (description "Jellyfish uses a variety of string comparison and phonetic
8931encoding algorithms to do fuzzy string matching.")
3f641af0 8932 (license license:bsd-2)
25a7db0a
LF
8933 (properties `((python2-variant . ,(delay python2-jellyfish))))))
8934
8935(define-public python2-jellyfish
8936 (let ((jellyfish (package-with-python2
8937 (strip-python2-variant python-jellyfish))))
8938 (package (inherit jellyfish)
8939 (native-inputs `(("python2-setuptools" ,python2-setuptools)
8940 ("python2-unicodecsv" ,python2-unicodecsv)
8941 ,@(package-native-inputs jellyfish))))))
13edb0e5
LF
8942
8943(define-public python2-unicodecsv
8944 (package
8945 (name "python2-unicodecsv")
8946 (version "0.14.1")
8947 (source (origin
8948 (method url-fetch)
8949 ;; The test suite is not included in the PyPi release.
8950 ;; https://github.com/jdunck/python-unicodecsv/issues/19
8951 (uri (string-append "https://github.com/jdunck/python-unicodecsv/"
8952 "archive/" version ".tar.gz"))
8953 (file-name (string-append name "-" version ".tar.gz"))
8954 (sha256
8955 (base32
8956 "087nqanfcyp6mlfbbr5lva5f3w6iz1bybls9xlrb8icmc474wh4w"))))
8957 (build-system python-build-system)
8958 (arguments
8959 `(;; It supports Python 3, but Python 3 can already do Unicode CSV.
8960 #:python ,python-2))
8961 (native-inputs
8962 `(("python2-setuptools" ,python2-setuptools)
8963 ("python2-unittest2" ,python2-unittest2)))
8964 (home-page "https://github.com/jdunck/python-unicodecsv")
8965 (synopsis "Unicode CSV module for Python 2")
8966 (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV
8967module, adding support for Unicode strings.")
3f641af0 8968 (license license:bsd-2)))
064503aa
LF
8969
8970(define-public python-rarfile
8971 (package
8972 (name "python-rarfile")
8973 (version "2.7")
8974 (source (origin
8975 (method url-fetch)
8976 (uri (pypi-uri "rarfile" version))
8977 (sha256
8978 (base32
8979 "0d8n1dlpiz7av8dmbp0vclrwl9cnxizr4f2c9xvj1h5nvn480527"))
8980 ;; https://github.com/markokr/rarfile/pull/17/
fc1adab1 8981 (patches (search-patches "python-rarfile-fix-tests.patch"))))
064503aa
LF
8982 (build-system python-build-system)
8983 (arguments
8984 '(#:phases
8985 (modify-phases %standard-phases
8986 (replace 'check
8987 ;; Many tests fail, but the installation proceeds.
8988 (lambda _ (zero? (system* "make" "-C" "test" "test")))))))
8989 (native-inputs
8990 `(("which" ,which))) ; required for tests
8991 (propagated-inputs
8992 `(("libarchive" ,libarchive)))
8993 (home-page "https://github.com/markokr/rarfile")
8994 (synopsis "RAR archive reader for Python")
8995 (description "This is Python module for RAR archive reading. The interface
8996is made as zipfile like as possible.")
3f641af0 8997 (license license:isc)))
064503aa
LF
8998
8999(define-public python2-rarfile
9000 (package-with-python2 python-rarfile))
daeeea71
CM
9001
9002(define-public python-magic
9003 (package
9004 (name "python-magic")
9005 (version "0.4.3")
9006 (source
9007 (origin
9008 (method url-fetch)
9009 (uri (string-append "https://github.com/ahupp/python-magic/archive/"
9010 version ".tar.gz"))
9011 (sha256
9012 (base32
9013 "17bgy92i7sb021f2s4mw1dcvpm6p1mi9jihridwy1pyn8mzvpjgk"))
9014 (file-name (string-append name "-" version "-checkout"))))
9015 (build-system python-build-system)
9016 (arguments
9017 ;; The tests are unreliable, so don't run them. The tests fail
9018 ;; under Python3 because they were written for Python2 and
9019 ;; contain import statements that do not work in Python3. One of
9020 ;; the tests fails under Python2 because its assertions are
9021 ;; overly stringent; it relies on comparing output strings which
9022 ;; are brittle and can change depending on the version of
9023 ;; libmagic being used and the system on which the test is
9024 ;; running. In my case, under GuixSD 0.10.0, only one test
9025 ;; failed, and it seems to have failed only because the version
9026 ;; of libmagic that is packaged in Guix outputs a slightly
9027 ;; different (but not wrong) string than the one that the test
9028 ;; expected.
9029 '(#:tests? #f
9030 #:phases (modify-phases %standard-phases
9031 ;; Replace a specific method call with a hard-coded
9032 ;; path to the necessary libmagic.so file in the
9033 ;; store. If we don't do this, then the method call
9034 ;; will fail to find the libmagic.so file, which in
9035 ;; turn will cause any application using
9036 ;; python-magic to fail.
9037 (add-before 'build 'hard-code-path-to-libmagic
9038 (lambda* (#:key inputs #:allow-other-keys)
9039 (let ((file (assoc-ref inputs "file")))
9040 (substitute* "magic.py"
9041 (("ctypes.util.find_library\\('magic'\\)")
9042 (string-append "'" file "/lib/libmagic.so'")))
77432686
LF
9043 #t)))
9044 (add-before 'install 'disable-egg-compression
9045 (lambda _
9046 (let ((port (open-file "setup.cfg" "a")))
9047 (display "\n[easy_install]\nzip_ok = 0\n"
9048 port)
9049 (close-port port)
9050 #t))))))
daeeea71
CM
9051 (native-inputs
9052 `(("python-setuptools" ,python-setuptools)))
9053 (inputs
9054 ;; python-magic needs to be able to find libmagic.so.
9055 `(("file" ,file)))
9056 (home-page "https://github.com/ahupp/python-magic")
9057 (synopsis "File type identification using libmagic")
9058 (description
9059 "This module uses ctypes to access the libmagic file type
9060identification library. It makes use of the local magic database and
9061supports both textual and MIME-type output. Note that this module and
9062the python-file module both provide a \"magic.py\" file; these two
9063modules, which are different and were developed separately, both serve
9064the same purpose: to provide Python bindings for libmagic.")
9065 (license license:expat)))
9066
9067(define-public python2-magic
9068 (package-with-python2 python-magic))
12af303f
CM
9069
9070(define-public python2-s3cmd
9071 (package
9072 (name "python2-s3cmd")
9073 (version "1.6.1")
9074 (source
9075 (origin
9076 (method url-fetch)
de67e922 9077 (uri (string-append "mirror://sourceforge/s3tools/s3cmd/" version "/"
12af303f
CM
9078 "s3cmd-" version ".tar.gz"))
9079 (sha256
9080 (base32
9081 "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6"))))
9082 (build-system python-build-system)
9083 (arguments
9084 ;; s3cmd is written for python2 only and contains no tests.
9085 `(#:python ,python-2
9086 #:tests? #f))
9087 (native-inputs
9088 `(("python2-setuptools" ,python2-setuptools)))
9089 (inputs
9090 `(("python2-dateutil" ,python2-dateutil)
9091 ;; The python-file package also provides a magic.py module.
9092 ;; This is an unfortunate state of affairs; however, s3cmd
9093 ;; fails to install if it cannot find specifically the
9094 ;; python-magic package. Thus we include it, instead of using
9095 ;; python-file. Ironically, s3cmd sometimes works better
9096 ;; without libmagic bindings at all:
9097 ;; https://github.com/s3tools/s3cmd/issues/198
9098 ("python2-magic" ,python2-magic)))
9099 (home-page "http://s3tools.org/s3cmd")
9100 (synopsis "Command line tool for S3-compatible storage services")
9101 (description
9102 "S3cmd is a command line tool for uploading, retrieving and managing data
9103in storage services that are compatible with the Amazon Simple Storage
9104Service (S3) protocol, including S3 itself. It supports rsync-like backup,
9105GnuPG encryption, and more. It also supports management of Amazon's
9106CloudFront content delivery network.")
3f641af0 9107 (license license:gpl2+)))
4323a5f0
AE
9108
9109(define-public python-pkgconfig
9110 (package
9111 (name "python-pkgconfig")
9112 (version "1.1.0")
9113 (source
9114 (origin
9115 (method url-fetch)
9116 (uri (pypi-uri "pkgconfig" version))
9117 (sha256
9118 (base32
9119 "1pw0kmvc57sjmaxi6c54fqsnihqj6hvhc9y1vaz36axafzqam7bh"))))
9120 (build-system python-build-system)
9121 (native-inputs
9122 `(("python-nose" ,python-nose)
9123 ("python-setuptools" ,python-setuptools)))
9124 (inputs
9125 `(("pkg-config" ,pkg-config)))
9126 (arguments
9127 `(;; Tests fail with "ValueError: _type_ 'v' not supported" on Python 3,
9128 ;; and on Python 2 they need the dl module deprecated since Python 2.6.
9129 #:tests? #f
9130 ;; Prevent creation of the egg. This works around
9131 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
9132 #:configure-flags '("--single-version-externally-managed" "--root=/")
9133 ;; Hard-code the path to pkg-config.
9134 #:phases
9135 (modify-phases %standard-phases
9136 (add-before
9137 'build 'patch
9138 (lambda _
9139 (substitute* "pkgconfig/pkgconfig.py"
9140 (("cmd = 'pkg-config")
9141 (string-append "cmd = '" (which "pkg-config"))))
9142 #t)))))
9143 (home-page "http://github.com/matze/pkgconfig")
9144 (synopsis "Python interface for pkg-config")
9145 (description "This module provides a Python interface to pkg-config. It
9146can be used to find all pkg-config packages, check if a package exists,
9147check if a package meets certain version requirements, query CFLAGS and
9148LDFLAGS and parse the output to build extensions with setup.py.")
a0c6a36b 9149 (license license:expat)))
4323a5f0
AE
9150
9151(define-public python2-pkgconfig
9152 (package-with-python2 python-pkgconfig))
9153
2e697322
BW
9154(define-public python-bz2file
9155 (package
9156 (name "python-bz2file")
9157 (version "0.98")
9158 (source
9159 (origin
9160 (method url-fetch)
9161 (uri (pypi-uri "bz2file" version))
9162 (sha256
9163 (base32
9164 "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4"))))
9165 (build-system python-build-system)
9166 (arguments
124df723 9167 `(#:tests? #f)) ; Tests use deprecated python modules.
2e697322
BW
9168 (home-page "https://github.com/nvawda/bz2file")
9169 (synopsis "Read and write bzip2-compressed files")
9170 (description
9171 "Bz2file is a Python library for reading and writing bzip2-compressed
9172files. It contains a drop-in replacement for the I/O interface in the
9173standard library's @code{bz2} module, including features from the latest
9174development version of CPython that are not available in older releases.")
3f641af0 9175 (license license:asl2.0)
2e697322
BW
9176 (properties `((python2-variant . ,(delay python2-bz2file))))))
9177
9178(define-public python2-bz2file
9179 (let ((base (package-with-python2
9180 (strip-python2-variant python-bz2file))))
9181 (package
9182 (inherit base)
9183 (native-inputs
124df723
BW
9184 `(("python2-setuptools" ,python2-setuptools)))
9185 (arguments
752bb447
BW
9186 `(#:python ,python-2
9187 #:phases
124df723
BW
9188 (modify-phases %standard-phases
9189 ;; 'python setup.py test' does not work as of 0.98.
9190 ;; There is only the one test file, so we run it directly.
9191 (replace 'check
9192 (lambda _ (zero? (system* "python"
9193 "test_bz2file.py"))))))))))
2e697322 9194
da4ac1aa
BW
9195(define-public python-future
9196 (package
9197 (name "python-future")
9198 (version "0.15.2")
9199 (source
9200 (origin
9201 (method url-fetch)
9202 (uri (pypi-uri "future" version))
9203 (sha256
9204 (base32
9205 "15wvcfzssc68xqnqi1dq4fhd0848hwi9jn42hxyvlqna40zijfrx"))))
9206 (build-system python-build-system)
9207 ;; Many tests connect to the network or are otherwise flawed.
9208 ;; https://github.com/PythonCharmers/python-future/issues/210
9209 (arguments
9210 `(#:tests? #f))
9211 (home-page "http://python-future.org")
9212 (synopsis "Single-source support for Python 3 and 2")
9213 (description
9214 "@code{python-future} is the missing compatibility layer between Python 2 and
9215Python 3. It allows you to use a single, clean Python 3.x-compatible codebase
9216to support both Python 2 and Python 3 with minimal overhead.")
9217 (license license:expat)
9218 (properties `((python2-variant . ,(delay python2-future))))))
9219
9220(define-public python2-future
9221 (let ((base (package-with-python2
9222 (strip-python2-variant python-future))))
9223 (package
9224 (inherit base)
9225 (native-inputs `(("python2-setuptools" ,python2-setuptools))))))
9226
8e451885
AE
9227(define-public python-cysignals
9228 (package
9229 (name "python-cysignals")
9230 (version "1.1.0")
9231 (source
9232 (origin
9233 (method url-fetch)
9234 (uri (pypi-uri "cysignals" version ".tar.bz2"))
9235 (sha256
9236 (base32
9237 "14cbyd9znlz6cxy1s3g6v6dv5jj45hn27pywkidd9b1zanaysqc6"))))
9238 (build-system python-build-system)
9239 (native-inputs
9240 `(("python-cython" ,python-cython)
9241 ("python-setuptools" ,python-setuptools)
9242 ("python-sphinx" ,python-sphinx)))
9243 (inputs
9244 `(("pari-gp" ,pari-gp)))
9245 (arguments
9246 `(#:modules ((guix build python-build-system)
9247 ((guix build gnu-build-system) #:prefix gnu:)
9248 (guix build utils))
9249 ;; FIXME: Tests are executed after installation and currently fail
9250 ;; when not installing into standard locations; the author is working
9251 ;; on a fix.
9252 #:tests? #f
9253 #:phases
9254 (modify-phases %standard-phases
9255 (add-before
9256 'build 'configure
9257 (assoc-ref gnu:%standard-phases 'configure)))))
9258 (home-page
9259 "https://github.com/sagemath/cysignals")
9260 (synopsis
9261 "Handling of interrupts and signals for Cython")
9262 (description
9263 "The cysignals package provides mechanisms to handle interrupts (and
9264other signals and errors) in Cython code, using two related approaches,
9265for mixed Cython/Python code or external C libraries and pure Cython code,
9266respectively.")
3f641af0 9267 (license license:lgpl3+)))
8e451885
AE
9268
9269(define-public python2-cysignals
9270 (package-with-python2 python-cysignals))
9271
63bcec71
DM
9272(define-public python2-shedskin
9273 (package
9274 (name "python2-shedskin")
9275 (version "0.9.4")
9276 (source
9277 (origin
9278 (method url-fetch)
9279 (uri (string-append "https://github.com/shedskin/shedskin/"
9280 "releases/download/v" version
9281 "/shedskin-" version ".tgz"))
9282 (sha256
9283 (base32
9284 "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41"))))
9285 (build-system python-build-system)
9286 (arguments
9287 `(#:python ,python-2
9288 #:phases (modify-phases %standard-phases
9289 (add-after 'unpack 'fix-resulting-include-libs
9290 (lambda* (#:key inputs #:allow-other-keys)
9291 (let ((libgc (assoc-ref inputs "libgc"))
9292 (pcre (assoc-ref inputs "pcre")))
9293 (substitute* "shedskin/makefile.py"
9294 (("variable == 'CCFLAGS':[ ]*")
9295 (string-append "variable == 'CCFLAGS':\n"
9296 " line += ' -I " pcre "/include"
9297 " -I " libgc "/include'"))
9298 (("variable == 'LFLAGS':[ ]*")
9299 (string-append "variable == 'LFLAGS':\n"
9300 " line += ' -L" pcre "/lib"
9301 " -L " libgc "/lib'")))
9302 #t))))))
9303 (native-inputs `(("python2-setuptools" ,python2-setuptools)))
9304 (inputs `(("pcre" ,pcre)
9305 ("libgc" ,libgc)))
9306 (home-page "https://shedskin.github.io/")
9307 (synopsis "Experimental Python-2 to C++ Compiler")
9308 (description (string-append "This is an experimental compiler for a subset of
9309Python. It generates C++ code and a Makefile."))
3f641af0 9310 (license (list license:gpl3 license:bsd-3 license:expat))))
88bb4197
LG
9311
9312(define-public python2-rope
9313 (package
9314 (name "python2-rope")
9315 (version "0.10.3")
9316 (source
9317 (origin
9318 (method url-fetch)
9319 (uri (pypi-uri "rope" version))
9320 (sha256
9321 (base32
9322 "18k5znhpwvrfck3yp0jmhd5j8r0f0s8bk1zh5yhs2cfgmfhbwigb"))))
9323 (arguments
9324 ;; Rope is currently python-2 only.
9325 ;; https://github.com/python-rope/rope/issues/57
9326 `(#:python ,python-2))
9327 (build-system python-build-system)
9328 (native-inputs
9329 `(("python2-unittest2" ,python2-unittest2)
9330 ("python2-setuptools" ,python2-setuptools)))
9331 (home-page "https://github.com/python-rope/rope")
9332 (synopsis "Refactoring library for Python")
9333 (description "Rope is a refactoring library for Python. It facilitates
9334the renaming, moving and extracting of attributes, functions, modules, fields
9335and parameters in Python 2 source code. These refactorings can also be applied
9336to occurences in strings and comments.")
3f641af0 9337 (license license:gpl2)))
6ba8ca17
9338
9339(define-public python-py3status
9340 (package
9341 (name "python-py3status")
d2262d70 9342 (version "3.1")
6ba8ca17
9343 (source
9344 (origin
9345 (method url-fetch)
9346 (uri (pypi-uri "py3status" version))
9347 (sha256
9348 (base32
d2262d70 9349 "0i283z1pivmir61z8kbiycigc94l61v33ygzkhczf1ifq7cppyds"))))
6ba8ca17
9350 (build-system python-build-system)
9351 (native-inputs
9352 `(("python-setuptools" ,python-setuptools)))
9353 (home-page "https://github.com/ultrabug/py3status")
9354 (synopsis "Extensible i3status wrapper written in Python")
9355 (description "py3status is an i3status wrapper which extends i3status
9356functionality in a modular way, allowing you to extend your panel with your
9357own code, responding to click events and updating clock every second.")
3f641af0 9358 (license license:bsd-3)))
b8fdbca3
HG
9359
9360(define-public python-tblib
9361 (package
9362 (name "python-tblib")
9363 (version "1.3.0")
9364 (source (origin
9365 (method url-fetch)
9366 (uri (pypi-uri "tblib" version))
9367 (sha256 (base32
9368 "02iahfkfa927hb4jq2bak36ldihwapzacfiq5lyxg8llwn98a1yi"))))
9369 (build-system python-build-system)
9370 (arguments
9371 `(#:phases
9372 (modify-phases %standard-phases
9373 (replace 'check
9374 (lambda _
9375 ;; Upstream runs tests after installation and the package itself
9376 ;; resides in a subdirectory. Extend PYTHONPATH so it will be
9377 ;; found.
9378 (setenv "PYTHONPATH"
9379 (string-append (getcwd) "/build/lib:"
9380 (getenv "PYTHONPATH")))
9381 (zero? (system* "py.test" "-vv" "tests" "README.rst")))))))
9382 (native-inputs
9383 `(("python-pytest" ,python-pytest)
9384 ("python-setuptools" ,python-setuptools)
9385 ("python-six" ,python-six)))
9386 (home-page "https://github.com/ionelmc/python-tblib")
9387 (synopsis "Traceback serialization library")
9388 (description
9389 "Traceback serialization allows you to:
9390
9391@enumerate
9392@item Pickle tracebacks and raise exceptions with pickled tracebacks in
9393different processes. This allows better error handling when running code over
9394multiple processes (imagine multiprocessing, billiard, futures, celery etc).
9395
9396@item Parse traceback strings and raise with the parsed tracebacks.
9397@end itemize")
3f641af0 9398 (license license:bsd-3)))
b8fdbca3
HG
9399
9400(define-public python2-tblib
9401 (package-with-python2 python-tblib))
1a024de4
HG
9402
9403(define-public python-sqlparse
9404 (package
9405 (name "python-sqlparse")
9406 (version "0.1.19")
9407 (source (origin
9408 (method url-fetch)
9409 (uri (pypi-uri "sqlparse" version))
9410 (sha256
9411 (base32
9412 "1s2fvaxgh9kqzrd6iwy5h7i61ckn05plx9np13zby93z3hdbx5nq"))))
9413 (build-system python-build-system)
9414 (arguments
9415 `(#:phases
9416 (modify-phases %standard-phases
9417 (replace 'check
9418 (lambda* _
9419 ;; setup.py-integrated 2to3 only affects the build files, but
9420 ;; py.test is using the source files. So we need to convert them
9421 ;; manually.
9422 (when (zero? (system* "python3"))
9423 (system* "2to3" "--no-diff" "-wn" "sqlparse" "tests"))
9424 (zero? (system* "py.test")))))))
9425 (native-inputs
9426 `(("python-pytest" ,python-pytest)
9427 ("python-setuptools" ,python-setuptools)))
9428 (home-page "https://github.com/andialbrecht/sqlparse")
9429 (synopsis "Non-validating SQL parser")
9430 (description "Sqlparse is a non-validating SQL parser for Python. It
9431provides support for parsing, splitting and formatting SQL statements.")
3f641af0 9432 (license license:bsd-3)))
1a024de4
HG
9433
9434(define-public python2-sqlparse
9435 (package-with-python2 python-sqlparse))
68b9d242
SB
9436
9437(define-public python-greenlet
9438 (package
9439 (name "python-greenlet")
9440 (version "0.4.9")
9441 (source (origin
9442 (method url-fetch)
9443 (uri (pypi-uri "greenlet" version))
9444 (sha256
9445 (base32
9446 "04h0m54dyqg49vyarq26mry6kbivnpl47rnmmrk9qn8wpfxviybr"))))
9447 (build-system python-build-system)
9448 (native-inputs
9449 `(("python-setuptools" ,python-setuptools)))
9450 (home-page "https://greenlet.readthedocs.io/")
9451 (synopsis "Lightweight in-process concurrent programming")
9452 (description
9453 "Greenlet package is a spin-off of Stackless, a version of CPython
9454that supports micro-threads called \"tasklets\". Tasklets run
9455pseudo-concurrently (typically in a single or a few OS-level threads) and
9456are synchronized with data exchanges on \"channels\".")
3f641af0 9457 (license (list license:psfl license:expat))))
68b9d242
SB
9458
9459(define-public python2-greenlet
9460 (package-with-python2 python-greenlet))
d79a343b
SB
9461
9462(define-public python-gevent
9463 (package
9464 (name "python-gevent")
9465 (version "1.1.1")
9466 (source (origin
9467 (method url-fetch)
9468 (uri (pypi-uri "gevent" version))
9469 (sha256
9470 (base32
9471 "1smf3kvidpdiyi2c81alal74p2zm0clrm6xbyy6y1k9a3f2vkrbf"))
9472 (modules '((guix build utils)))
9473 (snippet
9474 '(begin
9475 ;; unbunding libev and c-ares
9476 (for-each delete-file-recursively '("libev" "c-ares"))
9477 ;; fixing testsuite
9478 (call-with-output-file "greentest/__init__.py" noop)
9479 (substitute* "greentest/testrunner.py"
9480 (("import util") "from . import util")
9481 (("from util import log") "from .util import log"))))))
9482 (build-system python-build-system)
9483 (propagated-inputs
9484 `(("python-greenlet" ,python-greenlet)))
9485 (native-inputs
9486 `(("python-setuptools" ,python-setuptools)
9487 ("python-six" ,python-six)))
9488 (inputs
9489 `(("c-ares" ,c-ares)
9490 ("libev" ,libev)))
9491 (home-page "http://www.gevent.org/")
9492 (synopsis "Coroutine-based network library")
9493 (description
9494 "gevent is a coroutine-based Python networking library that uses greenlet
9495to provide a high-level synchronous API on top of the libev event loop.")
9496 (license license:expat)))
9497
9498(define-public python2-gevent
9499 (package-with-python2 python-gevent))
da3aeeb6
SB
9500
9501(define-public python-twisted
9502 (package
9503 (name "python-twisted")
9504 (version "16.2.0")
9505 (source (origin
9506 (method url-fetch)
8ea8e8d3 9507 (uri (pypi-uri "Twisted" version ".tar.bz2"))
da3aeeb6
SB
9508 (sha256
9509 (base32
9510 "0ydxrp9myw1mvsz3qfzx5579y5llmqa82pxvqchgp5syczffi450"))))
9511 (build-system python-build-system)
9512 (native-inputs
45912170
SB
9513 `(("python-setuptools" ,python-setuptools)))
9514 (propagated-inputs
9515 `(("python-zope-interface" ,python-zope-interface)))
da3aeeb6
SB
9516 (home-page "https://twistedmatrix.com/")
9517 (synopsis "Asynchronous networking framework written in Python")
9518 (description
9519 "Twisted is an extensible framework for Python programming, with special
9520focus on event-based network programming and multiprotocol integration.")
9521 (license license:expat)))
9522
9523(define-public python2-twisted
9524 (package-with-python2 python-twisted))
d0b6fed6 9525
4d3fa5a4
EF
9526(define-public python-pika
9527 (package
9528 (name "python-pika")
9529 (version "0.10.0")
9530 (source
9531 (origin
9532 (method url-fetch)
9533 (uri (pypi-uri "pika" version))
9534 (sha256
9535 (base32
9536 "0nb4h08di432lv7dy2v9kpwgk0w92f24sqc2hw2s9vwr5b8v8xvj"))))
9537 (build-system python-build-system)
9538 (native-inputs
9539 `(("python-twisted" ,python-twisted)))
9540 (home-page "https://pika.readthedocs.org")
9541 (synopsis "Pure Python AMQP Client Library")
9542 (description
9543 "Pika is a pure-Python implementation of the AMQP (Advanced Message Queuing
9544Protocol) 0-9-1 protocol that tries to stay fairly independent of the underlying
9545network support library.")
9546 (license license:bsd-3)))
9547
9548(define-public python2-pika
9549 (package-with-python2 python-pika))
9550
d0b6fed6
DM
9551(define-public python-ply
9552 (package
9553 (name "python-ply")
9554 (version "3.8")
9555 (source
9556 (origin
9557 (method url-fetch)
9558 (uri (string-append
9559 "https://pypi.python.org/packages/"
9560 "96/e0/430fcdb6b3ef1ae534d231397bee7e9304be14a47a267e82ebcb3323d0b5"
9561 "/ply-" version ".tar.gz"))
9562 (sha256
9563 (base32
9564 "1f70ipynmiy09k6px2j7v4w5cdrc21za3xs2k6f1bsvb0bzvvlg7"))))
9565 (build-system python-build-system)
9566 (home-page "http://www.dabeaz.com/ply/")
9567 (synopsis "Python Lex & Yacc")
9568 (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python.
9569It uses LR parsing and does extensive error checking.")
3f641af0 9570 (license license:bsd-3)
d0b6fed6
DM
9571 (properties `((python2-variant . ,(delay python2-ply))))))
9572
9573(define-public python2-ply
9574 (package
9575 (inherit (package-with-python2
9576 (strip-python2-variant python-ply)))
9577 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
d951bd54
SB
9578
9579(define-public python-tabulate
9580 (package
9581 (name "python-tabulate")
9582 (version "0.7.5")
9583 (source (origin
9584 (method url-fetch)
9585 (uri (pypi-uri "tabulate" version))
9586 (sha256
9587 (base32
9588 "03l1r7ddd1a0j2snv1yd0hlnghjad3fg1an1jr8936ksv75slwch"))
9589 ;; Fix tests
9590 (modules '((guix build utils)))
9591 (snippet '(substitute* '("test/test_cli.py"
9592 "test/test_input.py"
9593 "test/test_output.py"
9594 "test/test_regression.py")
9595 (("from common") "from nose.tools")))))
9596 (build-system python-build-system)
9597 (native-inputs
9598 `(("python-setuptools" ,python-setuptools)
9599 ;; For testing
9600 ("python-nose" ,python-nose)))
9601 (home-page "https://bitbucket.org/astanin/python-tabulate")
9602 (synopsis "Pretty-print tabular data")
9603 (description
9604 "Tabulate is a library and command-line utility to pretty-print tabular
9605data in Python.")
9606 (license license:expat)))
9607
9608(define-public python2-tabulate
9609 (package-with-python2 python-tabulate))
1c4c8a33
SB
9610
9611(define-public python-kazoo
9612 (package
9613 (name "python-kazoo")
9614 (version "2.2.1")
9615 (source
9616 (origin
9617 (method url-fetch)
9618 (uri (pypi-uri "kazoo" version))
9619 (sha256
9620 (base32
9621 "10pb864if9qi2pq9lfb9m8f7z7ss6rml80gf1d9h64lap5crjnjj"))))
9622 (build-system python-build-system)
9623 (arguments '(#:tests? #f)) ; XXX: needs zookeeper
9624 (native-inputs
c18899e8
SB
9625 `(("python-setuptools" ,python-setuptools)))
9626 (propagated-inputs
9627 `(("python-six" ,python-six)))
1c4c8a33
SB
9628 (home-page "https://kazoo.readthedocs.org")
9629 (synopsis "High-level Zookeeper client library")
9630 (description
9631 "Kazoo is a Python client library for the Apache Zookeeper distributed
9632application service. It is designed to be easy to use and to avoid common
9633programming errors.")
3f641af0 9634 (license license:asl2.0)))
1c4c8a33
SB
9635
9636(define-public python2-kazoo
9637 (package-with-python2 python-kazoo))
45dda35e
SB
9638
9639(define-public python-pykafka
9640 (package
9641 (name "python-pykafka")
9642 (version "2.4.0")
9643 (source (origin
9644 (method url-fetch)
c6bccf71
EF
9645 (uri (string-append
9646 "https://pypi.python.org/packages/8b/3e/"
9647 "384eeff406b06315738b62483fd2126c6e4f544167116b17cc04ea7d2a59/"
9648 "pykafka-" version ".tar.gz"))
45dda35e
SB
9649 (sha256
9650 (base32
9651 "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv"))))
9652 (build-system python-build-system)
9653 (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc.
9654 (native-inputs
c8fa3d9b
SB
9655 `(("python-setuptools" ,python-setuptools)))
9656 (propagated-inputs
45dda35e
SB
9657 `(("python-gevent" ,python-gevent)
9658 ("python-kazoo" ,python-kazoo)
45dda35e
SB
9659 ("python-tabulate" ,python-tabulate)))
9660 (inputs
9661 `(("librdkafka" ,librdkafka)))
9662 (home-page "https://pykafka.readthedocs.io/")
9663 (synopsis "Apache Kafka client for Python")
9664 (description
9665 "PyKafka is a client for the Apache Kafka distributed messaging system.
9666It includes Python implementations of Kafka producers and consumers, which
9667are optionally backed by a C extension built on librdkafka.")
3f641af0 9668 (license license:asl2.0)))
45dda35e
SB
9669
9670(define-public python2-pykafka
9671 (package-with-python2 python-pykafka))
a44fd439
DM
9672
9673(define-public python-wcwidth
9674 (package
9675 (name "python-wcwidth")
9676 (version "0.1.6")
9677 (source
9678 (origin
9679 (method url-fetch)
9680 (uri (string-append
9681 "https://pypi.python.org/packages/"
9682 "c2/d1/7689293086a8d5320025080cde0e3155b94ae0a7496fb89a3fbaa92c354a/"
9683 "wcwidth-" version ".tar.gz"))
9684 (sha256
9685 (base32
9686 "02wjrpf001gjdjsaxxbzcwfg19crlk2dbddayrfc2v06f53yrcyw"))))
9687 (build-system python-build-system)
9688 (home-page "https://github.com/jquast/wcwidth")
66e07664 9689 (synopsis "Measure number of terminal column cells of wide-character codes")
a44fd439
DM
9690 (description "Wcwidth measures the number of terminal column cells of
9691wide-character codes. It is useful for those implementing a terminal emulator,
9692or programs that carefully produce output to be interpreted by one. It is a
9693Python implementation of the @code{wcwidth} and @code{wcswidth} C functions
9694specified in POSIX.1-2001 and POSIX.1-2008.")
e4875826
LF
9695 (license license:expat)
9696 (properties `((python2-variant . ,(delay python2-wcwidth))))))
a44fd439
DM
9697
9698(define-public python2-wcwidth
9699 (package
9700 (inherit (package-with-python2
9701 (strip-python2-variant python-wcwidth)))
9702 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))
0de78c95
DP
9703
9704(define-public python2-jsonrpclib
9705 (package
9706 (name "python2-jsonrpclib")
9707 (version "0.1.7")
9708 (source (origin
9709 (method url-fetch)
9710 (uri (string-append
9711 "https://pypi.python.org/packages/source/j/jsonrpclib/"
9712 "jsonrpclib-" version ".tar.gz"))
9713 (sha256
9714 (base32
9715 "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z"))))
9716 (build-system python-build-system)
9717 (native-inputs
9718 `(("python2-setuptools" ,python2-setuptools)))
9719 (arguments
9720 `(#:tests? #f
9721 #:python ,python-2))
9722 (home-page "https://github.com/joshmarshall/jsonrpclib/")
9723 (synopsis "Implementation of JSON-RPC specification for Python")
9724 (description
9725 "This library is an implementation of the JSON-RPC specification.
9726It supports both the original 1.0 specification, as well as the
9727new (proposed) 2.0 spec, which includes batch submission, keyword arguments,
9728etc.")
3f641af0 9729 (license license:asl2.0)))
9250b0f3
SB
9730
9731(define-public python-chai
9732 (package
9733 (name "python-chai")
9734 (version "1.1.1")
9735 (source (origin
9736 (method url-fetch)
9737 (uri (pypi-uri "chai" version))
9738 (sha256
9739 (base32
9740 "016kf3irrclpkpvcm7q0gmkfibq7jgy30a9v73pp42bq9h9a32bl"))))
9741 (build-system python-build-system)
9742 (native-inputs
9743 `(("python-setuptools" ,python-setuptools)))
9744 (home-page "https://github.com/agoragames/chai")
9745 (synopsis "Mocking framework for Python")
9746 (description
9747 "Chai provides an api for mocking, stubbing and spying your python
9748objects, patterned after the Mocha library for Ruby.")
3f641af0 9749 (license license:bsd-3)))
9250b0f3
SB
9750
9751(define-public python2-chai
9752 (package-with-python2 python-chai))
9753
ae43baa8
SB
9754(define-public python-arrow
9755 (package
9756 (name "python-arrow")
9757 (version "0.8.0")
9758 (source (origin
9759 (method url-fetch)
9760 (uri (pypi-uri "arrow" version))
9761 (sha256
9762 (base32
9763 "1bz7hkdgpqcjs866y58z8jywpy7al0f4rxdr00bh2l5qddyw245j"))))
9764 (build-system python-build-system)
9765 (native-inputs
9766 `(("python-setuptools" ,python-setuptools)
ae43baa8
SB
9767 ;; For testing
9768 ("python-chai" ,python-chai)
9769 ("python-simplejson" ,python-simplejson)))
36aed736
SB
9770 (propagated-inputs
9771 `(("python-dateutil" ,python-dateutil-2)))
ae43baa8
SB
9772 (home-page "https://github.com/crsmithdev/arrow/")
9773 (synopsis "Dates and times for Python")
9774 (description
9775 "Arrow is a Python library to creating, manipulating, formatting and
9776converting dates, times, and timestamps. It implements and updates the
9777datetime type.")
3f641af0 9778 (license license:asl2.0)))
ae43baa8
SB
9779
9780(define-public python2-arrow
9781 (package-with-python2 python-arrow))
9782
1f2b62a4
SB
9783(define-public python-inflection
9784 (package
9785 (name "python-inflection")
9786 (version "0.3.1")
9787 (source
9788 (origin (method url-fetch)
9789 (uri (pypi-uri "inflection" version))
9790 (sha256
9791 (base32
9792 "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq"))))
9793 (build-system python-build-system)
9794 (native-inputs
9795 `(("python-setuptools" ,python-setuptools)))
9796 (home-page "http://github.com/jpvanhal/inflection")
9797 (synopsis "Python string transformation library")
9798 (description
9799 "Inflection is a string transformation library. It singularizes
9800and pluralizes English words, and transforms strings from CamelCase to
9801underscored string.")
9802 (license license:expat)))
9803
9804(define-public python2-inflection
9805 (package-with-python2 python-inflection))
9806
18995566
SB
9807(define-public python-pylev
9808 (package
9809 (name "python-pylev")
9810 (version "1.3.0")
9811 (source (origin
9812 (method url-fetch)
9813 (uri (pypi-uri "pylev" version))
9814 (sha256
9815 (base32
9816 "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86"))))
9817 (build-system python-build-system)
9818 (native-inputs
9819 `(("python-setuptools" ,python-setuptools)))
9820 (home-page "http://github.com/toastdriven/pylev")
9821 (synopsis "Levenshtein distance implementation in Python")
9822 (description "Pure Python Levenshtein implementation, based off the
9823Wikipedia code samples at
9824@url{http://en.wikipedia.org/wiki/Levenshtein_distance}.")
3f641af0 9825 (license license:bsd-3)))
18995566
SB
9826
9827(define-public python2-pylev
9828 (package-with-python2 python-pylev))
9829
f5deff7a
SB
9830(define-public python-cleo
9831 (package
9832 (name "python-cleo")
9833 (version "0.4.1")
9834 (source (origin
9835 (method url-fetch)
9836 (uri (pypi-uri "cleo" version))
9837 (sha256
9838 (base32
9839 "1k2dcl6mqpn5bljyl6w42rqyd9mb3y9kh2mg7m2x3kfjwvg0rpva"))))
9840 (build-system python-build-system)
9841 (native-inputs
9403150a 9842 `(("python-setuptools" ,python-setuptools)
f5deff7a
SB
9843 ;; For testing
9844 ("python-mock" ,python-mock)
9845 ("python-pytest" ,python-pytest)))
9403150a
SB
9846 (propagated-inputs
9847 `(("python-psutil" ,python-psutil)
9848 ("python-pylev" ,python-pylev)))
f5deff7a
SB
9849 (home-page "https://github.com/sdispater/cleo")
9850 (synopsis "Command-line arguments library for Python")
9851 (description
9852 "Cleo allows you to create command-line commands with signature in
9853docstring and colored output.")
9854 (license license:expat)))
9855
9856(define-public python2-cleo
9857 (package-with-python2 python-cleo))
9858
77cadb43
SB
9859(define-public python-lazy-object-proxy
9860 (package
9861 (name "python-lazy-object-proxy")
9862 (version "1.2.2")
9863 (source (origin
9864 (method url-fetch)
9865 (uri (pypi-uri "lazy-object-proxy" version))
9866 (sha256
9867 (base32
9868 "0s22aqqkdscyh8sjspyyax7qa1aiz8p4midrnyf39717fhfczm6x"))))
9869 (build-system python-build-system)
9870 (native-inputs
9871 `(("python-setuptools" ,python-setuptools)))
9872 (home-page "https://github.com/ionelmc/python-lazy-object-proxy")
9873 (synopsis "Lazy object proxy for python")
9874 (description
9875 "Lazy object proxy is an object that wraps a callable but defers the call
9876until the object is actually required, and caches the result of said call.")
3f641af0 9877 (license license:bsd-2)))
77cadb43
SB
9878
9879(define-public python2-lazy-object-proxy
9880 (package-with-python2 python-lazy-object-proxy))
9881
5477e05f
SB
9882(define-public python-dnspython
9883 (package
9884 (name "python-dnspython")
9885 (version "1.14.0")
9886 (source (origin
9887 (method url-fetch)
9888 (uri (string-append "http://www.dnspython.org/kits/"
9889 version "/dnspython-" version ".tar.gz"))
9890 (sha256
9891 (base32
9892 "1z472r63gdqsxhsxj3plr5vs478yf4303vrqxxpsccc940g441hl"))))
9893 (build-system python-build-system)
9894 (arguments '(#:tests? #f)) ; XXX: requires internet access
9895 (native-inputs
9896 `(("python-setuptools" ,python-setuptools)))
9897 (home-page "http://www.dnspython.org")
9898 (synopsis "DNS toolkit for Python")
9899 (description
9900 "dnspython is a DNS toolkit for Python. It supports almost all record
9901types. It can be used for queries, zone transfers, and dynamic updates.
9902It supports TSIG authenticated messages and EDNS0.")
9903 (license license:expat)))
9904
9905(define-public python2-dnspython
9906 (package-with-python2 python-dnspython))
9907
22711e25
SB
9908(define-public python-email-validator
9909 (package
9910 (name "python-email-validator")
9911 (version "1.0.1")
9912 (source
9913 (origin (method url-fetch)
9914 (uri (pypi-uri "email_validator" version))
9915 (sha256
9916 (base32
9917 "0mn8jg5h8ifl8w6a6m0hq8kbk0mzw9vm054qfamkn89b3npz52qw"))))
9918 (build-system python-build-system)
9919 (arguments
9920 '(#:phases
9921 (modify-phases %standard-phases
9922 (add-before 'build 'use-dnspython
9923 (lambda _
9924 (substitute* "setup.py"
9925 (("dnspython3") "dnspython"))
9926 #t)))))
9927 (native-inputs
d42560bd
SB
9928 `(("python-setuptools" ,python-setuptools)))
9929 (propagated-inputs
22711e25 9930 `(("python-dnspython" ,python-dnspython)
d42560bd 9931 ("python-idna" ,python-idna)))
22711e25
SB
9932 (home-page "https://github.com/JoshData/python-email-validator")
9933 (synopsis "Email address validation library for Python")
9934 (description
9935 "This library validates email address syntax and deliverability.")
3f641af0 9936 (license license:cc0)))
22711e25
SB
9937
9938(define-public python2-email-validator
9939 (package-with-python2 python-email-validator))
9940
8987d91e
SB
9941(define-public python-ukpostcodeparser
9942 (package
9943 (name "python-ukpostcodeparser")
9944 (version "1.0.3")
9945 (source (origin
9946 (method url-fetch)
9947 (uri (pypi-uri "UkPostcodeParser" version))
9948 (sha256
9949 (base32
9950 "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd"))))
9951 (build-system python-build-system)
9952 (native-inputs
9953 `(("python-setuptools" ,python-setuptools)))
9954 (home-page "https://github.com/hamstah/ukpostcodeparser")
9955 (synopsis "UK Postcode parser for Python")
9956 (description
9957 "This library provides the @code{parse_uk_postcode} function for
9958parsing UK postcodes.")
9959 (license license:expat)))
9960
9961(define-public python2-ukpostcodeparser
9962 (package-with-python2 python-ukpostcodeparser))
ea92ae01
SB
9963
9964(define-public python-fake-factory
9965 (package
9966 (name "python-fake-factory")
7adc698f 9967 (version "0.7.2")
ea92ae01
SB
9968 (source (origin
9969 (method url-fetch)
9970 (uri (pypi-uri "fake-factory" version))
9971 (sha256
9972 (base32
7adc698f 9973 "0vs0dkmg0dlaxf8w6q2i3k0i03gmp56ablldv7ci9x3nbadkn71g"))))
ea92ae01 9974 (build-system python-build-system)
ea92ae01 9975 (native-inputs
bbcd7297 9976 `(("python-setuptools" ,python-setuptools)
ea92ae01
SB
9977 ;; For testing
9978 ("python-email-validator" ,python-email-validator)
9979 ("python-mock" ,python-mock)
9980 ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
bbcd7297
SB
9981 (propagated-inputs
9982 `(("python-dateutil" ,python-dateutil-2)
9983 ("python-six" ,python-six)))
7adc698f 9984 (home-page "https://github.com/joke2k/faker")
ea92ae01
SB
9985 (synopsis "Python package that generates fake data")
9986 (description
9987 "Faker is a Python package that generates fake data such as names,
9988addresses, and phone numbers.")
9989 (license license:expat)
9990 (properties `((python2-variant . ,(delay python2-fake-factory))))))
9991
9992(define-public python2-fake-factory
9993 (let ((base (package-with-python2 (strip-python2-variant
9994 python-fake-factory))))
9995 (package
9996 (inherit base)
24c9aa18 9997 (propagated-inputs
ea92ae01 9998 `(("python2-ipaddress" ,python2-ipaddress)
24c9aa18 9999 ,@(package-propagated-inputs base))))))
ea92ae01 10000
b49504fd
SB
10001(define-public python-pyaml
10002 (package
10003 (name "python-pyaml")
10004 (version "15.8.2")
10005 (source (origin
10006 (method url-fetch)
10007 (uri (pypi-uri "pyaml" version))
10008 (sha256
10009 (base32
10010 "1f5m28vkh4ksq3d80d8mmd2z8wxvc3mgy2pmrv2751dm2xgznm4w"))))
10011 (build-system python-build-system)
10012 (native-inputs
10013 `(("python-setuptools" ,python-setuptools)))
10014 (propagated-inputs
10015 `(("python-pyyaml" ,python-pyyaml)))
10016 (home-page "https://github.com/mk-fg/pretty-yaml")
10017 (synopsis "YAML pretty-print library for Python")
10018 (description
10019 "pyaml is a PyYAML based python module to produce pretty and readable
10020YAML-serialized data.")
3f641af0 10021 (license (license:non-copyleft "http://www.wtfpl.net/txt/copying/"))))
b49504fd
SB
10022
10023(define-public python2-pyaml
10024 (package-with-python2 python-pyaml))
10025
347175a2
SB
10026(define-public python-flexmock
10027 (package
10028 (name "python-flexmock")
10029 (version "0.10.2")
10030 (source (origin
10031 (method url-fetch)
10032 (uri (pypi-uri "flexmock" version))
10033 (sha256
10034 (base32
10035 "0arc6njvs6i9v9hgvzk5m50296g7zy5m9d7pyb43vdsdgxrci5gy"))))
10036 (build-system python-build-system)
10037 (native-inputs
10038 `(("python-setuptools" ,python-setuptools)))
10039 (home-page "https://flexmock.readthedocs.org")
10040 (synopsis "Testing library for Python")
10041 (description
10042 "flexmock is a testing library for Python that makes it easy to create
10043mocks, stubs and fakes.")
3f641af0 10044 (license license:bsd-3)))
347175a2
SB
10045
10046(define-public python2-flexmock
10047 (package-with-python2 python-flexmock))
10048
5a744191
SB
10049(define-public python-orator
10050 (package
10051 (name "python-orator")
10052 (version "0.8.2")
10053 (source (origin
10054 (method url-fetch)
10055 (uri (pypi-uri "orator" version))
10056 (sha256
10057 (base32
10058 "1li49irsqha17nrda4nsb48biyy0rarp9pphf0jpqwm5zr8hv569"))))
10059 (build-system python-build-system)
10060 (arguments '(#:tests? #f)) ; no tests
10061 (native-inputs
b2676030
SB
10062 `(("python-setuptools" ,python-setuptools)))
10063 (propagated-inputs
5a744191
SB
10064 `(("python-arrow" ,python-arrow)
10065 ("python-blinker" ,python-blinker)
10066 ("python-cleo" ,python-cleo)
10067 ("python-fake-factory" ,python-fake-factory)
10068 ("python-inflection" ,python-inflection)
10069 ("python-lazy-object-proxy" ,python-lazy-object-proxy)
10070 ("python-pyaml" ,python-pyaml)
5a744191
SB
10071 ("python-simplejson" ,python-simplejson)
10072 ("python-wrapt" ,python-wrapt)))
10073 (home-page "https://orator-orm.com/")
10074 (synopsis "ActiveRecord ORM for Python")
10075 (description
10076 "Orator provides a simple ActiveRecord-like Object Relational Mapping
10077implementation for Python.")
10078 (license license:expat)
10079 (properties `((python2-variant . ,(delay python2-orator))))))
10080
10081(define-public python2-orator
10082 (let ((base (package-with-python2 (strip-python2-variant python-orator))))
10083 (package
10084 (inherit base)
06961617 10085 (propagated-inputs
5a744191 10086 `(("python2-ipaddress" ,python2-ipaddress)
06961617 10087 ,@(package-propagated-inputs base))))))
f4155188
DM
10088
10089(define-public python-prompt-toolkit
10090 (package
10091 (name "python-prompt-toolkit")
d15e2ef0 10092 (version "1.0.7")
f4155188
DM
10093 (source
10094 (origin
10095 (method url-fetch)
d15e2ef0 10096 (uri (pypi-uri "prompt_toolkit" version ".tar.gz"))
f4155188
DM
10097 (sha256
10098 (base32
d15e2ef0 10099 "1vyjd0b7wciv55i19l44zy0adx8q7ss79lhy2r9d1rwz2y4822zg"))))
f4155188
DM
10100 (build-system python-build-system)
10101 (inputs `(("python-wcwidth" ,python-wcwidth)
10102 ("python-pygments" ,python-pygments)))
10103 (native-inputs `(("python-six" ,python-six)))
10104 (home-page "https://github.com/jonathanslenders/python-prompt-toolkit")
10105 (synopsis "Library for building command line interfaces in Python")
10106 (description
10107 "Prompt-Toolkit is a library for building interactive command line
10108interfaces in Python. It's like GNU Readline but it also features syntax
10109highlighting while typing, out-of-the-box multi-line input editing, advanced
10110code completion, incremental search, support for Chinese double-width
10111characters, mouse support, and auto suggestions.")
3f641af0 10112 (license license:bsd-3)
f4155188
DM
10113 (properties `((python2-variant . ,(delay python2-prompt-toolkit))))))
10114
10115(define-public python2-prompt-toolkit
10116 (let ((base (package-with-python2 (strip-python2-variant python-prompt-toolkit))))
10117 (package
10118 (inherit base)
10119 (native-inputs
10120 `(("python2-setuptools" ,python2-setuptools)
10121 ,@(package-native-inputs base))))))
a502dfbf
DM
10122
10123(define-public python-jedi
10124 (package
10125 (name "python-jedi")
10126 (version "0.9.0")
10127 (source
10128 (origin
10129 (method url-fetch)
10130 (uri (pypi-uri "jedi" version))
10131 (sha256
10132 (base32
10133 "0c8x962ynpx001fdvp07m2q5jk4igkxbj3rmnydavphvlgxijk1v"))))
10134 (build-system python-build-system)
10135 (home-page "https://github.com/davidhalter/jedi")
10136 (synopsis
10137 "Autocompletion for Python that can be used for text editors")
10138 (description
10139 "Jedi is an autocompletion tool for Python that can be used for text editors.")
10140 (license license:expat)
10141 (properties `((python2-variant . ,(delay python2-jedi))))))
10142
10143(define-public python2-jedi
10144 (let ((base (package-with-python2 (strip-python2-variant python-jedi))))
10145 (package
10146 (inherit base)
10147 (native-inputs
10148 `(("python2-setuptools" ,python2-setuptools)
10149 ,@(package-native-inputs base))))))
c2f0dc6e
DM
10150
10151(define-public ptpython
10152 (package
10153 (name "ptpython")
10154 (version "0.34")
10155 (source (origin
10156 (method url-fetch)
10157 (uri (pypi-uri "ptpython" version))
10158 (sha256
10159 (base32
10160 "1mmbiyzf0n8hm7z2a562x7w5cbl6jc0zsk6vp40q1z4cyblv1k13"))))
10161 (build-system python-build-system)
10162 (inputs
10163 `(("python-docopt" ,python-docopt)
10164 ("python-jedi" ,python-jedi)
10165 ("python-prompt-toolkit" ,python-prompt-toolkit)
10166 ("python-pygments" ,python-pygments)
10167 ("python-setuptools" ,python-setuptools)))
10168 (home-page "https://github.com/jonathanslenders/ptpython")
10169 (synopsis "Python Read-Eval-Print-Loop with nice IDE-like features")
10170 (description
10171 "ptpython is a Python read-eval-print loop with IDE-like features.
10172It supports syntax highlighting, multiline editing, autocompletion, mouse,
10173color schemes, bracketed paste, Vi and Emacs keybindings, Chinese characters
10174etc.")
3f641af0 10175 (license license:bsd-3)
c2f0dc6e
DM
10176 (properties `((python2-variant . ,(delay ptpython-2))))))
10177
10178(define-public ptpython-2
10179 (let ((base (package-with-python2 (strip-python2-variant ptpython))))
10180 (package
10181 (inherit base)
10182 (name "ptpython2"))))
b227f0be 10183
b04a52a6
DJ
10184(define-public python-requests-oauthlib
10185 (package
10186 (name "python-requests-oauthlib")
10187 (version "0.6.2")
10188 (source
10189 (origin
10190 (method url-fetch)
10191 (uri (pypi-uri "requests-oauthlib" version))
10192 (sha256
10193 (base32
10194 "0ykff67sjcl227c23g0rxzfx34rr5bf21kwv0z3zmgk0lfmch7hn"))))
10195 (build-system python-build-system)
10196 (arguments
10197 `(#:phases
10198 (modify-phases %standard-phases
10199 ;; removes tests that require network access
10200 (add-before 'check 'pre-check
10201 (lambda _
10202 (delete-file "tests/test_core.py")
10203 #t)))))
10204 (native-inputs
10205 `(("python-requests-mock" ,python-requests-mock)
10206 ("python-mock" ,python-mock)))
10207 (inputs
10208 `(("python-oauthlib" ,python-oauthlib)
10209 ("python-requests" ,python-requests)))
10210 (home-page
10211 "https://github.com/requests/requests-oauthlib")
10212 (synopsis
10213 "OAuthlib authentication support for Requests")
10214 (description
10215 "Requests-OAuthlib uses the Python Requests and OAuthlib libraries to
10216provide an easy-to-use Python interface for building OAuth1 and OAuth2 clients.")
10217 (license license:isc)
10218 (properties `((python2-variant . ,(delay python2-requests-oauthlib))))))
10219
10220(define-public python2-requests-oauthlib
10221 (let ((base (package-with-python2 (strip-python2-variant python-requests-oauthlib))))
10222 (package
10223 (inherit base)
10224 (native-inputs `(("python2-setuptools" ,python2-setuptools)
10225 ,@(package-native-inputs base))))))
10226
b227f0be 10227(define-public python-stem
10228 (package
10229 (name "python-stem")
10230 (version "1.4.1b")
10231 (source
10232 (origin
10233 (method url-fetch)
10234 (uri (pypi-uri "stem" version ".tar.bz2"))
10235 (sha256
10236 (base32
10237 "09a3amp1y351nwz088ckiibbp666qi2lxwkyknavswfm400s0ns7"))))
10238 (build-system python-build-system)
10239 (arguments
10240 `(#:phases
10241 (modify-phases %standard-phases
10242 (replace 'check
10243 (lambda _
10244 (zero? (system* "./run_tests.py" "--unit")))))))
10245 (native-inputs
10246 `(("python-mock" ,python-mock)
10247 ("python-pep8" ,python-pep8)
10248 ("python-pyflakes" ,python-pyflakes)))
10249 (inputs
10250 `(("python-pycrypto" ,python-pycrypto)))
10251 (home-page "https://stem.torproject.org/")
10252 (synopsis
10253 "Python controller library that allows applications to interact with Tor")
10254 (description
10255 "Stem is a Python controller library for Tor. With it you can use Tor's
10256control protocol to script against the Tor process and read descriptor data
10257relays publish about themselves.")
3f641af0 10258 (license license:lgpl3)))
b227f0be 10259
10260(define-public python2-stem
10261 (package-with-python2 python-stem))
517a6c0c
DM
10262
10263(define-public python-pyserial
10264 (package
10265 (name "python-pyserial")
10266 (version "3.1.1")
10267 (source
10268 (origin
10269 (method url-fetch)
10270 (uri (pypi-uri "pyserial" version))
10271 (sha256
10272 (base32
10273 "0k1nfdrxxkdlv4zgaqsdv8li0pj3gbh2pyxw8q2bsg6f9490amyn"))))
10274 (build-system python-build-system)
10275 (home-page
10276 "https://github.com/pyserial/pyserial")
10277 (synopsis "Python Serial Port Bindings")
10278 (description "@code{pyserial} provide serial port bindings for Python. It
10279supports different byte sizes, stop bits, parity and flow control with RTS/CTS
10280and/or Xon/Xoff. The port is accessed in RAW mode.")
3f641af0 10281 (license license:bsd-3)
517a6c0c
DM
10282 (properties `((python2-variant . ,(delay python2-pyserial))))))
10283
10284(define-public python2-pyserial
10285 (let ((base (package-with-python2 (strip-python2-variant python-pyserial))))
10286 (package
10287 (inherit base)
10288 (native-inputs
10289 `(("python2-setuptools" ,python2-setuptools)
10290 ,@(package-native-inputs base))))))
6eb7af2a
DJ
10291
10292(define-public python-kivy
10293 (package
10294 (name "python-kivy")
10295 (version "1.9.1")
10296 (source
10297 (origin
10298 (method url-fetch)
10299 (uri (pypi-uri "kivy" version))
10300 (file-name (string-append name "-" version ".tar.gz"))
10301 (sha256
10302 (base32
10303 "0zk3g1j1z0lzcm9d0k1lprrs95zr8n8k5pdg3p5qlsn26jz4bg19"))))
10304 (build-system python-build-system)
10305 (arguments
10306 `(#:tests? #f ; Tests require many optional packages
10307 #:phases
10308 (modify-phases %standard-phases
10309 (replace 'build (lambda _ (zero? (system* "make" "force"))))
10310 (add-after 'patch-generated-file-shebangs 'set-sdl-paths
10311 (lambda* (#:key inputs #:allow-other-keys)
10312 (setenv "KIVY_SDL2_PATH"
10313 (string-append (assoc-ref inputs "sdl-union")
10314 "/include/SDL2"))
10315 #t)))))
10316 (native-inputs
10317 `(("pkg-config" ,pkg-config)))
10318 (inputs
10319 `(("python-cython" ,python-cython)
10320 ("gstreamer" ,gstreamer)
10321 ("mesa" ,mesa)
10322 ("sdl-union"
10323 ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))))
10324 (home-page "http://kivy.org")
10325 (synopsis
10326 "Multitouch application framework")
10327 (description
10328 "A software library for rapid development of
10329hardware-accelerated multitouch applications.")
10330 (license license:expat)))
10331
10332(define-public python2-kivy
10333 (package-with-python2 python-kivy))
10334
10335(define-public python-kivy-next
10336 (let ((commit "a988c5e7a47da56263ff39514264a3de516ef2fe")
10337 (revision "1"))
10338 (package (inherit python-kivy)
10339 (name "python-kivy-next")
d80a71eb 10340 (version (string-append "1.9.1-" revision "."
6eb7af2a
DJ
10341 (string-take commit 7)))
10342 (source
10343 (origin
10344 (method git-fetch)
10345 (uri (git-reference
10346 (url "https://github.com/kivy/kivy")
10347 (commit commit)))
10348 (file-name (string-append name "-" version "-checkout"))
10349 (sha256
10350 (base32
10351 "0jk92b4a8l7blkvkgkjihk171s0dfnq582cckff5srwc8kal5m0p")))))))
10352
10353(define-public python2-kivy-next
10354 (package-with-python2 python-kivy-next))
8794bd8b
DC
10355
10356(define-public python-binaryornot
10357 (package
10358 (name "python-binaryornot")
10359 (version "0.4.0")
10360 (source (origin
10361 (method url-fetch)
10362 (uri (pypi-uri "binaryornot" version))
10363 (sha256
10364 (base32
10365 "1j4f51dxic39mdwf6alj7gd769wy6mhk916v031wjali51xkh3xb"))))
10366 (build-system python-build-system)
10367 (inputs
10368 `(("python-chardet" ,python-chardet)
10369 ("python-hypothesis" ,python-hypothesis)))
10370 (home-page "https://github.com/audreyr/binaryornot")
10371 (synopsis "Package to check if a file is binary or text")
10372 (description "Ultra-lightweight pure Python package to check if a file is
10373binary or text.")
10374 (license license:bsd-3)
10375 (properties `((python2-variant . ,(delay python2-binaryornot))))))
10376
10377(define-public python2-binaryornot
10378 (let ((base (package-with-python2 (strip-python2-variant python-binaryornot))))
10379 (package (inherit base)
10380 (native-inputs
10381 `(("python2-setuptools" ,python2-setuptools)
10382 ,@(package-native-inputs base)))
10383 (inputs
10384 `(("python2-enum34" ,python2-enum34)
10385 ,@(package-inputs base))))))
a9ac982a
DC
10386
10387(define-public python-nltk
10388 (package
10389 (name "python-nltk")
10390 (version "3.2.1")
10391 (source (origin
10392 (method url-fetch)
10393 (uri (pypi-uri "nltk" version))
10394 (sha256
10395 (base32
10396 "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"))))
10397 (build-system python-build-system)
10398 (home-page "http://nltk.org/")
10399 (synopsis "Natural Language Toolkit")
10400 (description "It provides interfaces to over 50 corpora and lexical
10401resources such as WordNet, along with a suite of text processing libraries
10402for classification, tokenization, stemming, tagging, parsing, and semantic
10403reasoning, wrappers for natural language processing libraries.")
10404 (license license:asl2.0)
10405 (properties `((python2-variant . ,(delay python2-nltk))))))
10406
10407(define-public python2-nltk
10408 (let ((base (package-with-python2 (strip-python2-variant python-nltk))))
10409 (package (inherit base)
10410 (native-inputs
10411 `(("python2-setuptools" ,python2-setuptools)
10412 ,@(package-native-inputs base))))))
691cd90d
DC
10413
10414(define-public python-pymongo
10415 (package
10416 (name "python-pymongo")
10417 (version "3.3.0")
10418 (source (origin
10419 (method url-fetch)
10420 (uri (pypi-uri "pymongo" version))
10421 (sha256
10422 (base32
10423 "07mra6w86wjqy4lx5fvimidjhhfzd562gfjn8grsnbv2q8pk0i9x"))))
10424 (build-system python-build-system)
10425 (inputs
10426 `(("python-certifi" ,python-certifi)))
10427 (home-page "http://github.com/mongodb/mongo-python-driver")
10428 (synopsis "Python driver for MongoDB")
10429 (description "Python driver for MongoDB.")
10430 (license license:asl2.0)
10431 (properties `((python2-variant . ,(delay python2-pymongo))))))
10432
10433(define-public python2-pymongo
10434 (let ((base (package-with-python2 (strip-python2-variant python-pymongo))))
10435 (package (inherit base)
10436 (native-inputs
10437 `(("python2-setuptools" ,python2-setuptools)
10438 ,@(package-native-inputs base))))))
6a6c9d43
DC
10439
10440(define-public python-sh
10441 (package
10442 (name "python-sh")
10443 (version "1.11")
10444 (source (origin
10445 (method url-fetch)
10446 (uri (pypi-uri "sh" version))
10447 (sha256
10448 (base32
10449 "192r0mpv6dmkysjzhc43ddffiwb5g7c76bgr1mb1z2xz9awbj3sr"))))
10450 (build-system python-build-system)
10451 (arguments
10452 `(#:tests? #f)) ; no tests
10453 (home-page "https://github.com/amoffat/sh")
10454 (synopsis "Python subprocess interface")
10455 (description "Abstracts process invocation by providing a function
10456interface for programs.")
10457 (license license:expat)
10458 (properties `((python2-variant . ,(delay python2-sh))))))
10459
10460(define-public python2-sh
10461 (let ((base (package-with-python2 (strip-python2-variant python-sh))))
10462 (package (inherit base)
10463 (native-inputs
10464 `(("python2-setuptools" ,python2-setuptools)
10465 ,@(package-native-inputs base))))))
05b59190 10466
25702397
EF
10467(define-public python-consul
10468 (package
10469 (name "python-consul")
10470 (version "0.6.1")
10471 (source
10472 (origin
10473 (method url-fetch)
10474 (uri (pypi-uri "python-consul" version))
10475 (sha256
10476 (base32
10477 "0rfyxcy4cr3x848vhx876ifalxd5ghq6l5x813m49h4vq2d4jiq8"))))
10478 (build-system python-build-system)
10479 (native-inputs
10480 `(("python-pytest" ,python-pytest)
10481 ("python-requests" ,python-requests)
10482 ("python-six" ,python-six)))
10483 (home-page "https://github.com/cablehead/python-consul")
10484 (synopsis "Python client for Consul")
10485 (description
10486 "Python client for @url{http://www.consul.io/,Consul}, a tool for service
10487discovery, monitoring and configuration.")
10488 (license license:expat)))
10489
10490(define-public python2-consul
10491 (let ((consul (package-with-python2 python-consul)))
10492 (package (inherit consul)
10493 (native-inputs
10494 `(("python2-setuptools" ,python2-setuptools)
10495 ,@(package-native-inputs consul))))))
10496
05b59190
DC
10497(define-public python-schematics
10498 (package
10499 (name "python-schematics")
10500 (version "1.1.1")
10501 (source
10502 (origin
10503 (method url-fetch)
10504 (uri (string-append
10505 "https://github.com/schematics/schematics/archive/v" version ".tar.gz"))
10506 (file-name (string-append name "-" version ".tar.gz"))
10507 (sha256
10508 (base32
10509 "19v1i69bf3bzarfxmbv0v6ivpcn758x3shvbiy9l2hy0lvqwnp6l"))))
10510 (build-system python-build-system)
10511 (inputs
10512 `(("python-six" ,python-six)))
10513 (arguments
10514 `(#:tests? #f)) ; requires a bunch of not very nice packages with fixed
10515 ; version requirements (eg python-coveralls)
10516 (home-page "https://github.com/schematics/schematics")
10517 (synopsis "Python Data Structures for Humans")
10518 (description "Python Data Structures for Humans.")
10519 (license license:bsd-3)
10520 (properties `((python2-variant . ,(delay python2-schematics))))))
10521
10522(define-public python2-schematics
10523 (let ((base (package-with-python2 (strip-python2-variant python-schematics))))
10524 (package (inherit base)
10525 (native-inputs
10526 `(("python2-setuptools" ,python2-setuptools)
10527 ,@(package-native-inputs base))))))
d6907ff7
DC
10528
10529(define-public python-publicsuffix
10530 (package
10531 (name "python-publicsuffix")
10532 (version "1.1.0")
10533 (source (origin
10534 (method url-fetch)
10535 (uri (pypi-uri "publicsuffix" version))
10536 (sha256
10537 (base32
10538 "1adx520249z2cy7ykwjr1k190mn2888wqn9jf8qm27ly4qymjxxf"))))
10539 (build-system python-build-system)
10540 (arguments
10541 `(#:tests? #f)) ; tests use the internet
10542 (home-page "https://www.tablix.org/~avian/git/publicsuffix.git")
10543 (synopsis "Get suffix for a domain name")
10544 (description "Get a public suffix for a domain name using the Public Suffix
10545List.")
10546 (license license:expat)
10547 (properties `((python2-variant . ,(delay python2-nltk))))))
10548
10549(define-public python2-publicsuffix
10550 (let ((base (package-with-python2 (strip-python2-variant python-publicsuffix))))
10551 (package (inherit base)
10552 (native-inputs
10553 `(("python2-setuptools" ,python2-setuptools)
10554 ,@(package-native-inputs base))))))
b2319996
DC
10555
10556(define-public python-publicsuffix2
10557 (package
10558 (name "python-publicsuffix2")
10559 (version "2.20160621")
10560 (source
10561 (origin
10562 (method url-fetch)
10563 (uri (pypi-uri "publicsuffix2" version ".tar.bz2"))
10564 (sha256
10565 (base32
10566 "06lx603gdwad5hc3hmn763ngq0rq9bzz1ni3ga72nzk5n872arkd"))))
10567 (build-system python-build-system)
10568 (home-page "https://github.com/pombredanne/python-publicsuffix2")
10569 (synopsis "Get a public suffix for a domain name using the Public Suffix List")
10570 (description "Get a public suffix for a domain name using the Public Suffix
10571List. Forked from and using the same API as the publicsuffix package.")
10572 (license (list license:expat license:mpl2.0))
10573 (properties `((python2-variant . ,(delay python2-publicsuffix2))))))
10574
10575(define-public python2-publicsuffix2
10576 (let ((base (package-with-python2 (strip-python2-variant python-publicsuffix2))))
10577 (package (inherit base)
10578 (native-inputs
10579 `(("python2-setuptools" ,python2-setuptools)
10580 ,@(package-native-inputs base))))))
81f1515d
DC
10581
10582(define-public python-url
10583 (package
10584 (name "python-url")
10585 (version "0.2.0")
10586 (source (origin
10587 (method url-fetch)
10588 (uri (pypi-uri "url" version))
10589 (sha256
10590 (base32
10591 "0v879yadcz9qxfl41ak6wkga1kimp9cflla9ddz03hjjvgkqy5ki"))))
10592 (build-system python-build-system)
10593 (inputs
10594 `(("python-publicsuffix" ,python-publicsuffix)))
10595 (native-inputs
10596 `(("python-coverage" ,python-coverage)
10597 ("python-nose" ,python-nose)))
10598 (arguments
10599 `(#:tests? #f)) ; FIXME: tests fail with "ImportError: No module named 'tests'"
10600 (home-page "http://github.com/seomoz/url-py")
10601 (synopsis "URL Parsing")
10602 (description "Library for parsing urls.")
10603 (license license:expat)
10604 (properties `((python2-variant . ,(delay python2-url))))))
10605
10606(define-public python2-url
10607 (let ((base (package-with-python2 (strip-python2-variant python-url))))
10608 (package (inherit base)
10609 (inputs
10610 `(("python2-publicsuffix" ,python2-publicsuffix)))
10611 (native-inputs
10612 `(("python2-setuptools" ,python2-setuptools)
10613 ,@(package-native-inputs base))))))
974ee2c1
TS
10614
10615(define-public python-freezegun
10616 (package
10617 (name "python-freezegun")
10618 (version "0.3.7")
10619 (source
10620 (origin
10621 (method url-fetch)
10622 (uri (pypi-uri "freezegun" version))
10623 (sha256
10624 (base32
10625 "14l19x06v5jkq4rdwbmfyw4x9lrjb2300afrk21r1ash7y1y9a0w"))))
10626 (build-system python-build-system)
10627 (native-inputs
10628 `(("python-mock" ,python-mock)
10629 ("python-nose" ,python-nose)
10630 ("python-coverage" ,python-coverage)
10631 ("python-dateutil-2" ,python-dateutil-2)))
10632 (inputs
10633 `(("python-six" ,python-six)))
10634 (arguments
10635 `(#:phases (modify-phases %standard-phases
10636 ;; The tests are normally executed via `make test`, but the PyPi
10637 ;; package does not include the Makefile.
10638 (replace 'check
10639 (lambda _
10640 (zero? (system* "nosetests" "./tests/")))))))
10641 (home-page "https://github.com/spulec/freezegun")
10642 (synopsis "Test utility for mocking the datetime module")
10643 (description
10644 "FreezeGun is a library that allows your python tests to travel through
10645time by mocking the datetime module.")
10646 (license license:asl2.0)))
10647
10648(define-public python2-freezegun
10649 (let ((base (package-with-python2 (strip-python2-variant python-freezegun))))
10650 (package (inherit base)
10651 (native-inputs
10652 `(("python2-setuptools" ,python2-setuptools)
10653 ,@(package-native-inputs base))))))
dddcb25c
MB
10654
10655(define-public python-odfpy
10656 (package
10657 (name "python-odfpy")
10658 (version "1.3.3")
10659 (source (origin
10660 (method url-fetch)
10661 (uri (pypi-uri "odfpy" version))
10662 (sha256
10663 (base32
10664 "1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"))))
10665 (arguments
10666 `(#:modules ((srfi srfi-1)
10667 (guix build python-build-system)
10668 (guix build utils))
10669 #:phases
10670 (modify-phases %standard-phases
10671 (replace 'check
10672 ;; The test runner invokes python2 and python3 for test*.py.
10673 ;; To avoid having both in inputs, we replicate it here.
10674 (lambda _
10675 (every (lambda (test-file)
10676 (zero? (system* "python" test-file)))
10677 (find-files "tests" "^test.*\\.py$")))))))
10678 (build-system python-build-system)
10679 (home-page "https://github.com/eea/odfpy")
10680 (synopsis "Python API and tools to manipulate OpenDocument files")
10681 (description "Collection of libraries and utility programs written in
10682Python to manipulate OpenDocument 1.2 files.")
10683 (license
10684 ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
10685 ;; number of files with other licenses.
10686 (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0))))
10687
10688(define-public python2-odfpy
10689 (package-with-python2 python-odfpy))
b30565bd
MB
10690
10691(define-public python-cachecontrol
10692 (package
10693 (name "python-cachecontrol")
10694 (version "0.11.6")
10695 (source
10696 (origin
10697 (method url-fetch)
10698 ;; Pypi does not have tests.
10699 (uri (string-append
10700 "https://github.com/ionrock/cachecontrol/archive/v"
10701 version ".tar.gz"))
10702 (file-name (string-append name "-" version ".tar.gz"))
10703 (sha256
10704 (base32
10705 "0yj60d0f69a2l8p7y86k4zhzzm6rnxpq74sfl240pry9l0lfw2vw"))))
10706 (build-system python-build-system)
10707 (arguments
10708 `(#:phases
10709 (modify-phases %standard-phases
10710 (replace 'check
10711 (lambda _
10712 ;; Drop test that requires internet access.
10713 (delete-file "tests/test_regressions.py")
10714 (setenv "PYTHONPATH"
10715 (string-append (getcwd) "/build/lib:"
10716 (getenv "PYTHONPATH")))
10717 (zero? (system* "py.test" "-vv")))))))
10718 (native-inputs
10719 `(("python-pytest" ,python-pytest)
10720 ("python-redis" ,python-redis)
10721 ("python-webtest" ,python-webtest)
10722 ("python-mock" ,python-mock)))
10723 (propagated-inputs
10724 `(("python-requests" ,python-requests)
10725 ("python-lockfile" ,python-lockfile)))
10726 (home-page "https://github.com/ionrock/cachecontrol")
10727 (synopsis "The httplib2 caching algorithms for use with requests")
10728 (description "CacheControl is a port of the caching algorithms in
10729@code{httplib2} for use with @code{requests} session objects.")
10730 (license license:asl2.0)
dd447621 10731 (properties `((python2-variant . ,(delay python2-cachecontrol))))))
b30565bd
MB
10732
10733(define-public python2-cachecontrol
10734 (let ((base (package-with-python2 (strip-python2-variant python-cachecontrol))))
10735 (package (inherit base)
10736 (native-inputs
10737 `(("python2-setuptools" ,python2-setuptools)
10738 ,@(package-native-inputs base))))))
243db824
DM
10739
10740(define-public python-lit
10741 (package
10742 (name "python-lit")
10743 (version "0.5.0")
10744 (source
10745 (origin
10746 (method url-fetch)
10747 (uri (pypi-uri "lit" version))
10748 (sha256
10749 (base32
10750 "135m2b9cwih85g66rjggavck328z7lj37srgpq3jxszbg0g2b91y"))))
10751 (build-system python-build-system)
10752 (home-page "http://llvm.org/")
10753 (synopsis "LLVM Software Testing Tool")
10754 (description "@code{lit} is a portable tool for executing LLVM and Clang
10755style test suites, summarizing their results, and providing indication of
10756failures.")
10757 (license license:ncsa)
10758 (properties `((python2-variant . ,(delay python2-lit))))))
10759
10760(define-public python2-lit
10761 (let ((base (package-with-python2 (strip-python2-variant python-lit))))
10762 (package
10763 (inherit base)
10764 (native-inputs
10765 `(("python2-setuptools" ,python2-setuptools)
10766 ,@(package-native-inputs base))))))
66f95b20
MB
10767
10768(define-public python-pytest-pep8
10769 (package
10770 (name "python-pytest-pep8")
10771 (version "1.0.6")
10772 (source (origin
10773 (method url-fetch)
10774 (uri (pypi-uri "pytest-pep8" version))
10775 (sha256
10776 (base32
10777 "06032agzhw1i9d9qlhfblnl3dw5hcyxhagn7b120zhrszbjzfbh3"))))
10778 (build-system python-build-system)
10779 (arguments
10780 `(#:tests? #f ; Fails with recent pytest and pep8. See upstream issues #8 and #12.
10781 ;; Prevent creation of the egg. This works around
10782 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
10783 #:configure-flags '("--single-version-externally-managed" "--root=/")))
10784 (native-inputs
10785 `(("python-pytest" ,python-pytest)))
10786 (propagated-inputs
10787 `(("python-pep8" ,python-pep8)))
10788 (home-page "https://bitbucket.org/pytest-dev/pytest-pep8")
10789 (synopsis "Py.test plugin to check PEP8 requirements")
10790 (description "Pytest plugin for checking PEP8 compliance.")
10791 (license license:expat)
10792 (properties `((python2-variant . ,(delay python2-pytest-pep8))))))
10793
10794(define-public python2-pytest-pep8
10795 (let ((base (package-with-python2 (strip-python2-variant python-pytest-pep8))))
10796 (package (inherit base)
10797 (native-inputs
10798 `(("python2-setuptools" ,python2-setuptools)
10799 ,@(package-native-inputs base))))))
df94a6b5
MB
10800
10801(define-public python-pytest-flakes
10802 (package
10803 (name "python-pytest-flakes")
10804 (version "1.0.1")
10805 (source (origin
10806 (method url-fetch)
10807 (uri (pypi-uri "pytest-flakes" version))
10808 (sha256
10809 (base32
10810 "0flag3n33kbhyjrhzmq990rvg4yb8hhhl0i48q9hw0ll89jp28lw"))))
10811 (build-system python-build-system)
10812 (arguments
10813 `(;; Prevent creation of the egg. This works around
10814 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
10815 #:configure-flags '("--single-version-externally-managed" "--root=/")
10816 #:phases
10817 (modify-phases %standard-phases
10818 (delete 'check)
10819 (add-after 'install 'check
10820 (lambda _ ; It's easier to run tests after install.
10821 (zero? (system* "py.test" "-vv")))))))
10822 (native-inputs
10823 `(("python-coverage" ,python-coverage)
10824 ("python-pytest" ,python-pytest)
10825 ("python-pytest-cache" ,python-pytest-cache)
10826 ("python-pytest-pep8" ,python-pytest-pep8)))
10827 (propagated-inputs
10828 `(("python-pyflakes" ,python-pyflakes)))
10829 (home-page "https://github.com/fschulze/pytest-flakes")
10830 (synopsis "Py.test plugin to check source code with pyflakes")
10831 (description "Pytest plugin for checking Python source code with pyflakes.")
10832 (license license:expat)
10833 (properties `((python2-variant . ,(delay python2-pytest-flakes))))))
10834
10835(define-public python2-pytest-flakes
10836 (let ((base (package-with-python2 (strip-python2-variant python-pytest-flakes))))
10837 (package (inherit base)
10838 (native-inputs
10839 `(("python2-setuptools" ,python2-setuptools)
10840 ,@(package-native-inputs base))))))
5467ea62
MB
10841
10842(define-public python-natsort
10843 (package
10844 (name "python-natsort")
10845 (version "5.0.1")
10846 (source (origin
10847 (method url-fetch)
10848 (uri (pypi-uri "natsort" version))
10849 (sha256
10850 (base32
10851 "1abld5p4a6n5zjnyw5mi2pv37gqalcybv2brjr2y6l9l2p8v9mja"))))
10852 (build-system python-build-system)
10853 (arguments
10854 `(#:phases
10855 (modify-phases %standard-phases
10856 (add-before 'check 'set-cachedir
10857 ;; Tests require write access to $HOME by default
10858 (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t)))))
10859 (native-inputs
10860 `(("python-hypothesis" ,python-hypothesis)
10861 ("python-pytest-cache" ,python-pytest-cache)
10862 ("python-pytest-cov" ,python-pytest-cov)
10863 ("python-pytest-flakes" ,python-pytest-flakes)
10864 ("python-pytest-pep8" ,python-pytest-pep8)))
10865 (propagated-inputs ; TODO: Add python-fastnumbers.
10866 `(("python-pyicu" ,python-pyicu)))
10867 (home-page "https://github.com/SethMMorton/natsort")
10868 (synopsis "Natural sorting for python and shell")
10869 (description
10870 "Natsort lets you apply natural sorting on lists instead of
10871lexicographical. If you use the built-in @code{sorted} method in python
10872on a list such as @code{['a20', 'a9', 'a1', 'a4', 'a10']}, it would be
10873returned as @code{['a1', 'a10', 'a20', 'a4', 'a9']}. Natsort provides a
10874function @code{natsorted} that identifies numbers and sorts them separately
10875from strings. It can also sort version numbers, real numbers, mixed types
10876and more, and comes with a shell command @command{natsort} that exposes this
10877functionality in the command line.")
10878 (license license:expat)
10879 (properties `((python2-variant . ,(delay python2-natsort))))))
10880
10881(define-public python2-natsort
10882 (let ((base (package-with-python2 (strip-python2-variant python-natsort))))
10883 (package (inherit base)
10884 (native-inputs
10885 `(("python2-setuptools" ,python2-setuptools)
10886 ("python2-pathlib" ,python2-pathlib)
10887 ("python2-mock" ,python2-mock)
10888 ("python2-enum34" ,python2-enum34)
10889 ,@(package-native-inputs base))))))
4efb9c54
SR
10890
10891(define-public python-glances
10892 (package
10893 (name "python-glances")
10894 (version "2.7.1")
10895 (source
10896 (origin
10897 (method url-fetch)
10898 (uri (pypi-uri "Glances" version))
10899 (sha256
10900 (base32
10901 "11jbq40g8alsbirnd4kiagznqg270247i0m8qhi48ldf2i5xppxg"))))
10902 (build-system python-build-system)
10903 (inputs
10904 `(("python-psutil" ,python-psutil)))
10905 (home-page
10906 "https://github.com/nicolargo/glances")
10907 (synopsis
10908 "A cross-platform curses-based monitoring tool")
10909 (description
10910 "Glances is a curses-based monitoring tool for a wide variety of platforms.
10911Glances uses the PsUtil library to get information from your system. It monitors
10912CPU, load, memory, network bandwidth, disk I/O, disk use, and more.")
10913 (license license:lgpl3+)
10914 (properties `((python2-variant . ,(delay python2-glances))))))
10915
10916(define-public python2-glances
10917 (let ((base (package-with-python2 (strip-python2-variant python-glances))))
10918 (package
10919 (inherit base)
10920 (native-inputs
10921 `(("python2-setuptools" ,python2-setuptools)
10922 ,@(package-native-inputs base))))))
05b7a593
EF
10923
10924(define-public python-graphql-core
10925 (package
10926 (name "python-graphql-core")
10927 (version "0.5.3")
10928 (source
10929 (origin
10930 (method url-fetch)
10931 (uri (pypi-uri "graphql-core" version))
10932 (sha256
10933 (base32
10934 "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0"))))
10935 (build-system python-build-system)
10936 (arguments
10937 `(#:phases
10938 (modify-phases %standard-phases
10939 (add-after 'unpack 'patch-hardcoded-version
10940 (lambda _ (substitute*
10941 "setup.py"
10942 (("'gevent==1.1rc1'") "'gevent'"))
10943 #t)))))
10944 (native-inputs
10945 `(("python-gevent" ,python-gevent)
10946 ("python-mock" ,python-mock)
10947 ("python-pytest-mock" ,python-pytest-mock)))
10948 (inputs
10949 `(("python-promise" ,python-promise)
10950 ("python-six" ,python-six)))
10951 (home-page "https://github.com/graphql-python/graphql-core")
10952 (synopsis "GraphQL implementation for Python")
10953 (description
10954 "GraphQL implementation for Python. GraphQL is a data query language and
10955runtime designed and used to request and deliver data to mobile and web apps.
10956This library is a port of @url{https://github.com/graphql/graphql-js,graphql-js}
10957to Python.")
10958 (properties `((python2-variant . ,(delay python2-graphql-core))))
10959 (license license:expat)))
10960
10961(define-public python2-graphql-core
10962 (let ((base (package-with-python2
10963 (strip-python2-variant python-graphql-core))))
10964 (package (inherit base)
10965 (native-inputs
10966 `(("python2-setuptools" ,python2-setuptools)
10967 ,@(package-native-inputs base))))))
7ee51575
EF
10968
10969(define-public python-graphql-relay
10970 (package
10971 (name "python-graphql-relay")
10972 (version "0.4.4")
10973 (source
10974 (origin
10975 (method url-fetch)
10976 (uri (pypi-uri "graphql-relay" version))
10977 (sha256
10978 (base32
10979 "04wr9ayshxjjdcg2v21c7ffbz36kif1wjl3604fqd3qignb3fbxi"))))
10980 (build-system python-build-system)
10981 (native-inputs
10982 `(("python-pytest" ,python-pytest)))
10983 (inputs
10984 `(("python-graphql-core" ,python-graphql-core)
10985 ("python-promise" ,python-promise)
10986 ("python-six" ,python-six)))
10987 (home-page "https://github.com/graphql-python/graphql-relay-py")
10988 (synopsis "Relay implementation for Python")
10989 (description
10990 "This is a library to allow the easy creation of Relay-compliant servers
10991using the GraphQL Python reference implementation of a GraphQL server. It
10992should be noted that the code is a exact port of the original
10993@url{https://github.com/graphql/graphql-relay-js,graphql-relay js implementation}
10994from Facebook.")
10995 (properties `((python2-variant . ,(delay python2-graphql-relay))))
10996 (license license:expat)))
10997
10998(define-public python2-graphql-relay
10999 (let ((base (package-with-python2
11000 (strip-python2-variant python-graphql-relay))))
11001 (package (inherit base)
11002 (native-inputs
11003 `(("python2-setuptools" ,python2-setuptools)
11004 ,@(package-native-inputs base))))))
ddc63a56
EF
11005
11006(define-public python-graphene
11007 (package
11008 (name "python-graphene")
11009 (version "0.10.2")
11010 (source
11011 (origin
11012 (method url-fetch)
11013 (uri (pypi-uri "graphene" version))
11014 (sha256
11015 (base32
11016 "09zhac7igh9ixdz0ay6csy35b40l1jwbf2wrbxmgxwfhy51iy06q"))))
11017 (build-system python-build-system)
11018 (native-inputs
11019 `(("python-django-filter" ,python-django-filter)
11020 ("python-mock" ,python-mock)
11021 ("python-psycopg2" ,python-psycopg2)
11022 ("python-pytest-django" ,python-pytest-django)
11023 ("python-sqlalchemy-utils" ,python-sqlalchemy-utils)))
11024 (inputs
11025 `(("python-graphql-core" ,python-graphql-core)
11026 ("python-graphql-relay" ,python-graphql-relay)
11027 ("python-iso8601" ,python-iso8601)
11028 ("python-promise" ,python-promise)
11029 ("python-six" ,python-six)))
11030 (home-page "http://graphene-python.org/")
11031 (synopsis "GraphQL Framework for Python")
11032 (description
11033 "Graphene is a Python library for building GraphQL schemas/types.
11034A GraphQL schema describes your data model, and provides a GraphQL server
11035with an associated set of resolve methods that know how to fetch data.")
11036 (properties `((python2-variant . ,(delay python2-graphene))))
11037 (license license:expat)))
11038
11039(define-public python2-graphene
11040 (let ((base (package-with-python2
11041 (strip-python2-variant python-graphene))))
11042 (package (inherit base)
11043 (native-inputs
11044 `(("python2-setuptools" ,python2-setuptools)
11045 ("python2-sqlalchemy" ,python2-sqlalchemy)
11046 ,@(package-native-inputs base))))))
d488d5d6
EF
11047
11048(define-public python-nautilus
11049 (package
11050 (name "python-nautilus")
11051 (version "0.4.9")
11052 (source
11053 (origin
11054 (method url-fetch)
11055 (uri (pypi-uri "nautilus" version))
11056 (sha256
11057 (base32
11058 "01hwzjc1zshk4vvxrcghm398fpy4jls66dyz06g07mrwqif8878p"))))
11059 (build-system python-build-system)
11060 (arguments `(#:tests? #f)) ; fails to import test modules
11061 (native-inputs
11062 `(("python-setuptools" ,python-setuptools)))
11063 (inputs
11064 `(("python-bcrypt" ,python-bcrypt)
11065 ("python-click" ,python-click)
11066 ("python-consul" ,python-consul)
11067 ("python-graphql-core" ,python-graphql-core)
11068 ("python-graphql-relay" ,python-graphql-relay)
11069 ("python-graphene" ,python-graphene)
11070 ("python-jinja2" ,python-jinja2)
11071 ("python-nose2" ,python-nose2)
11072 ("python-peewee" ,python-peewee)
11073 ("python-pika" ,python-pika)
11074 ("python-pycparser" ,python-pycparser)
11075 ("python-requests" ,python-requests)
11076 ("python-tornado" ,python-tornado)
11077 ("python-wtforms" ,python-wtforms)))
11078 (home-page "https://github.com/AlecAivazis/nautilus")
11079 (synopsis "Library for creating microservice applications")
11080 (description
11081 "Nautilus is a framework for flux based microservices that looks to
11082provide extendible implementations of common aspects of a cloud so that you can
11083focus on building massively scalable web applications.")
11084 (license license:expat)))