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