Commit | Line | Data |
---|---|---|
a01b6da7 NK |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org> | |
a5e3d59b | 3 | ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org> |
8e451885 | 4 | ;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr> |
e99f4211 | 5 | ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org> |
4dcb135e | 6 | ;;; Copyright © 2014, 2017 Eric Bavier <bavier@member.fsf.org> |
da6ce3f1 | 7 | ;;; Copyright © 2014, 2015 Federico Beffa <beffa@fbengineering.ch> |
e99f4211 | 8 | ;;; Copyright © 2015 Omar Radwan <toxemicsquire4@gmail.com> |
d95a56c6 | 9 | ;;; Copyright © 2015 Pierre-Antoine Rault <par@rigelk.eu> |
d92621cf | 10 | ;;; Copyright © 2015, 2016, 2017 Ricardo Wurmus <rekado@elephly.net> |
0bdc1671 | 11 | ;;; Copyright © 2015, 2016 Christopher Allan Webber <cwebber@dustycloud.org> |
345f0611 | 12 | ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr> |
2b2f2fc1 | 13 | ;;; Copyright © 2015, 2016 David Thompson <davet@gnu.org> |
7637de23 | 14 | ;;; Copyright © 2015, 2016, 2017 Leo Famulari <leo@famulari.name> |
04fb4516 | 15 | ;;; Copyright © 2015, 2017 Ben Woodcroft <donttrustben@gmail.com> |
b9893908 | 16 | ;;; Copyright © 2015, 2016 Erik Edrosa <erik.edrosa@gmail.com> |
c5be3467 | 17 | ;;; Copyright © 2015, 2016, 2017 Efraim Flashner <efraim@flashner.co.il> |
b89e3c77 | 18 | ;;; Copyright © 2015, 2017 Kyle Meyer <kyle@kyleam.com> |
daeeea71 | 19 | ;;; Copyright © 2015, 2016 Chris Marusich <cmmarusich@gmail.com> |
b31fbea5 | 20 | ;;; Copyright © 2016 Danny Milosavljevic <dannym+a@scratchpost.org> |
88bb4197 | 21 | ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org> |
b8fdbca3 | 22 | ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com> |
0de78c95 | 23 | ;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org> |
9250b0f3 | 24 | ;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com> |
bb3b4b4e | 25 | ;;; Copyright © 2016, 2017 Troy Sankey <sankeytms@gmail.com> |
b3593688 | 26 | ;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org> |
6eb7af2a | 27 | ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org> |
3f641af0 | 28 | ;;; Copyright © 2016 David Craven <david@craven.ch> |
df893a38 | 29 | ;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com> |
ca0e62bf | 30 | ;;; Copyright © 2016, 2017 Stefan Reichör <stefan@xsteve.at> |
b04a52a6 | 31 | ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org> |
e65acb31 | 32 | ;;; Copyright © 2016, 2017 Alex Vong <alexvong1995@gmail.com> |
33e9490c | 33 | ;;; Copyright © 2016, 2017 Arun Isaac <arunisaac@systemreboot.net> |
5220022a | 34 | ;;; Copyright © 2016, 2017 Julien Lepiller <julien@lepiller.eu> |
9e8401a5 | 35 | ;;; Copyright © 2016, 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr> |
ec074213 | 36 | ;;; Copyright © 2016, 2017 Thomas Danckaert <post@thomasdanckaert.be> |
916aafa4 | 37 | ;;; Copyright © 2017 Carlo Zancanaro <carlo@zancanaro.id.au> |
1a917fc9 | 38 | ;;; Copyright © 2017 Frederick M. Muriithi <fredmanglis@gmail.com> |
f9f67fcb | 39 | ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com> |
16fe516e | 40 | ;;; Copyright © 2017 Ben Sturmfels <ben@sturm.com.au> |
a5e8f597 | 41 | ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com> |
3015d455 | 42 | ;;; Copyright © 2017 José Miguel Sánchez García <jmi2k@openmailbox.org> |
fa3f5f47 | 43 | ;;; Copyright © 2017 Roel Janssen <roel@gnu.org> |
44e4a621 | 44 | ;;; Copyright © 2017, 2018 Kei Kebreau <kkebreau@posteo.net> |
f817b4d9 | 45 | ;;; Copyright © 2017 Rutger Helling <rhelling@mykolab.com> |
3fee0039 | 46 | ;;; Copyright © 2017 Muriithi Frederick Muriuki <fredmanglis@gmail.com> |
2e15906c | 47 | ;;; Copyright © 2017 Brendan Tildesley <brendan.tildesley@openmailbox.org> |
a01b6da7 NK |
48 | ;;; |
49 | ;;; This file is part of GNU Guix. | |
50 | ;;; | |
51 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
52 | ;;; under the terms of the GNU General Public License as published by | |
53 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
54 | ;;; your option) any later version. | |
55 | ;;; | |
56 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
57 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
58 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
59 | ;;; GNU General Public License for more details. | |
60 | ;;; | |
61 | ;;; You should have received a copy of the GNU General Public License | |
62 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
63 | ||
1ffa7090 | 64 | (define-module (gnu packages python) |
3f641af0 | 65 | #:use-module ((guix licenses) #:prefix license:) |
3fdc99da | 66 | #:use-module (gnu packages) |
8e451885 | 67 | #:use-module (gnu packages algebra) |
d79a343b | 68 | #:use-module (gnu packages adns) |
89b2e0b0 | 69 | #:use-module (gnu packages attr) |
d96034ed | 70 | #:use-module (gnu packages backup) |
3969ca54 | 71 | #:use-module (gnu packages bash) |
a0596a2f | 72 | #:use-module (gnu packages check) |
1ffa7090 | 73 | #:use-module (gnu packages compression) |
dc1bd2b5 | 74 | #:use-module (gnu packages crypto) |
4ed20663 | 75 | #:use-module (gnu packages databases) |
5e1c9367 | 76 | #:use-module (gnu packages file) |
4ed20663 | 77 | #:use-module (gnu packages fontutils) |
4ed20663 | 78 | #:use-module (gnu packages gcc) |
44e4a621 | 79 | #:use-module (gnu packages geo) |
4ed20663 | 80 | #:use-module (gnu packages ghostscript) |
6eb7af2a | 81 | #:use-module (gnu packages gl) |
4ed20663 | 82 | #:use-module (gnu packages glib) |
c227458a | 83 | #:use-module (gnu packages graphviz) |
5eebe8dc | 84 | #:use-module (gnu packages graphics) |
6eb7af2a | 85 | #:use-module (gnu packages gstreamer) |
4ed20663 | 86 | #:use-module (gnu packages gtk) |
421a80a2 | 87 | #:use-module (gnu packages icu4c) |
c937562e | 88 | #:use-module (gnu packages image) |
4ed20663 | 89 | #:use-module (gnu packages imagemagick) |
d79a343b | 90 | #:use-module (gnu packages libevent) |
b10ab723 | 91 | #:use-module (gnu packages libffi) |
89b2e0b0 | 92 | #:use-module (gnu packages linux) |
be6eb2f1 | 93 | #:use-module (gnu packages machine-learning) |
ed118043 | 94 | #:use-module (gnu packages man) |
0da98533 | 95 | #:use-module (gnu packages maths) |
4ed20663 | 96 | #:use-module (gnu packages multiprecision) |
45203542 | 97 | #:use-module (gnu packages networking) |
be7134bf | 98 | #:use-module (gnu packages ncurses) |
b04a52a6 | 99 | #:use-module (gnu packages openstack) |
d488d5d6 | 100 | #:use-module (gnu packages password-utils) |
c9b1b4f9 | 101 | #:use-module (gnu packages pcre) |
4ed20663 | 102 | #:use-module (gnu packages perl) |
b10ab723 | 103 | #:use-module (gnu packages pkg-config) |
cc6f4912 | 104 | #:use-module (gnu packages python-crypto) |
1b2f753d | 105 | #:use-module (gnu packages python-web) |
4535a93a | 106 | #:use-module (gnu packages qt) |
4ed20663 | 107 | #:use-module (gnu packages readline) |
6eb7af2a | 108 | #:use-module (gnu packages sdl) |
5f94ec91 | 109 | #:use-module (gnu packages search) |
80ce42bd | 110 | #:use-module (gnu packages shells) |
7ea498e5 | 111 | #:use-module (gnu packages ssh) |
c9b1b4f9 | 112 | #:use-module (gnu packages statistics) |
8f9ac901 | 113 | #:use-module (gnu packages tex) |
1c65314c | 114 | #:use-module (gnu packages texinfo) |
33dc54b0 | 115 | #:use-module (gnu packages time) |
cc2b77df | 116 | #:use-module (gnu packages tls) |
e25f0174 | 117 | #:use-module (gnu packages version-control) |
02f8f804 | 118 | #:use-module (gnu packages video) |
8d12be1e | 119 | #:use-module (gnu packages web) |
ce0614dd | 120 | #:use-module (gnu packages base) |
26b307e2 | 121 | #:use-module (gnu packages xml) |
6fa14469 | 122 | #:use-module (gnu packages xorg) |
0bdc1671 | 123 | #:use-module (gnu packages xdisorg) |
afa181ff | 124 | #:use-module (gnu packages tcl) |
63bcec71 | 125 | #:use-module (gnu packages bdw-gc) |
a01b6da7 NK |
126 | #:use-module (guix packages) |
127 | #:use-module (guix download) | |
ea5456c8 | 128 | #:use-module (guix git-download) |
11bb85a1 | 129 | #:use-module (guix utils) |
acc26ff1 | 130 | #:use-module (guix build-system gnu) |
d8c4998f | 131 | #:use-module (guix build-system cmake) |
898238b9 | 132 | #:use-module (guix build-system python) |
1c65314c FB |
133 | #:use-module (guix build-system trivial) |
134 | #:use-module (srfi srfi-1)) | |
a01b6da7 | 135 | |
45848023 | 136 | (define-public python-2.7 |
a01b6da7 NK |
137 | (package |
138 | (name "python") | |
49c2a46e | 139 | (version "2.7.13") |
a01b6da7 NK |
140 | (source |
141 | (origin | |
142 | (method url-fetch) | |
9b43a0ff | 143 | (uri (string-append "https://www.python.org/ftp/python/" |
a01b6da7 NK |
144 | version "/Python-" version ".tar.xz")) |
145 | (sha256 | |
146 | (base32 | |
49c2a46e | 147 | "0cgpk3zk0fgpji59pb4zy9nzljr70qzgv1vpz5hq5xw2d2c47m9m")) |
c3052d6b ML |
148 | (patches (search-patches "python-2.7-search-paths.patch" |
149 | "python-2-deterministic-build-info.patch" | |
15e57f57 | 150 | "python-2.7-site-prefixes.patch" |
dc5cec21 LF |
151 | "python-2.7-source-date-epoch.patch" |
152 | "python-2.7-getentropy-on-old-kernels.patch")) | |
10a42aa2 EF |
153 | (modules '((guix build utils))) |
154 | ;; suboptimal to delete failing tests here, but if we delete them in the | |
155 | ;; arguments then we need to make sure to strip out that phase when it | |
156 | ;; gets inherited by python and python-minimal. | |
157 | (snippet | |
158 | '(begin | |
159 | (for-each delete-file | |
160 | '("Lib/test/test_compileall.py" | |
f0499100 | 161 | "Lib/test/test_ctypes.py" ; fails on mips64el |
10a42aa2 EF |
162 | "Lib/test/test_distutils.py" |
163 | "Lib/test/test_import.py" | |
164 | "Lib/test/test_shutil.py" | |
165 | "Lib/test/test_socket.py" | |
1bb163b0 | 166 | "Lib/test/test_subprocess.py")) |
10a42aa2 | 167 | #t)))) |
02f0c3b2 LC |
168 | (outputs '("out" |
169 | "tk")) ;tkinter; adds 50 MiB to the closure | |
a01b6da7 | 170 | (build-system gnu-build-system) |
3fdc99da | 171 | (arguments |
10a42aa2 | 172 | `(;; 356 tests OK. |
e7e7a1eb EF |
173 | ;; 6 tests failed: |
174 | ;; test_compileall test_distutils test_import test_shutil test_socket | |
175 | ;; test_subprocess | |
176 | ;; 39 tests skipped: | |
ff6f33cf ED |
177 | ;; test_aepack test_al test_applesingle test_bsddb test_bsddb185 |
178 | ;; test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk | |
e7e7a1eb EF |
179 | ;; test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses |
180 | ;; test_dl test_gdb test_gl test_imageop test_imgfile test_ioctl | |
181 | ;; test_kqueue test_linuxaudiodev test_macos test_macostools | |
182 | ;; test_msilib test_ossaudiodev test_scriptpackages test_smtpnet | |
183 | ;; test_socketserver test_startfile test_sunaudiodev test_timeout | |
184 | ;; test_tk test_ttk_guionly test_urllib2net test_urllibnet | |
185 | ;; test_winreg test_winsound test_zipfile64 | |
186 | ;; 4 skips unexpected on linux2: | |
187 | ;; test_bsddb test_bsddb3 test_gdb test_ioctl | |
af807dea | 188 | #:test-target "test" |
3fdc99da | 189 | #:configure-flags |
6a20289d LC |
190 | (list "--enable-shared" ;allow embedding |
191 | "--with-system-ffi" ;build ctypes | |
aaf75c89 | 192 | "--with-ensurepip=install" ;install pip and setuptools |
a282d7ff | 193 | "--enable-unicode=ucs4" |
6a20289d LC |
194 | (string-append "LDFLAGS=-Wl,-rpath=" |
195 | (assoc-ref %outputs "out") "/lib")) | |
fd982732 | 196 | |
d2cc9c7c LC |
197 | #:modules ((ice-9 ftw) (ice-9 match) |
198 | (guix build utils) (guix build gnu-build-system)) | |
fd982732 | 199 | #:phases |
46472ecd MW |
200 | (modify-phases %standard-phases |
201 | (add-before | |
202 | 'configure 'patch-lib-shells | |
203 | (lambda _ | |
204 | ;; Filter for existing files, since some may not exist in all | |
205 | ;; versions of python that are built with this recipe. | |
206 | (substitute* (filter file-exists? | |
207 | '("Lib/subprocess.py" | |
208 | "Lib/popen2.py" | |
209 | "Lib/distutils/tests/test_spawn.py" | |
210 | "Lib/test/test_subprocess.py")) | |
211 | (("/bin/sh") (which "sh"))) | |
dedc8320 LC |
212 | |
213 | ;; Use zero as the timestamp in .pyc files so that builds are | |
214 | ;; deterministic. TODO: Remove it when this variable is set in | |
215 | ;; gnu-build-system.scm. | |
a665996f | 216 | (setenv "SOURCE_DATE_EPOCH" "1") |
46472ecd | 217 | #t)) |
5b4e2791 LC |
218 | (add-before 'configure 'do-not-record-configure-flags |
219 | (lambda* (#:key configure-flags #:allow-other-keys) | |
220 | ;; Remove configure flags from the installed '_sysconfigdata.py' | |
221 | ;; and 'Makefile' so we don't end up keeping references to the | |
222 | ;; build tools. | |
223 | ;; | |
224 | ;; Preserve at least '--with-system-ffi' since otherwise the | |
225 | ;; thing tries to build libffi, fails, and we end up with a | |
226 | ;; Python that lacks ctypes. | |
227 | (substitute* "configure" | |
228 | (("^CONFIG_ARGS=.*$") | |
229 | (format #f "CONFIG_ARGS='~a'\n" | |
230 | (if (member "--with-system-ffi" configure-flags) | |
231 | "--with-system-ffi" | |
232 | "")))) | |
233 | #t)) | |
46472ecd MW |
234 | (add-before |
235 | 'check 'pre-check | |
236 | (lambda _ | |
237 | ;; 'Lib/test/test_site.py' needs a valid $HOME | |
238 | (setenv "HOME" (getcwd)) | |
239 | #t)) | |
240 | (add-after | |
241 | 'unpack 'set-source-file-times-to-1980 | |
242 | ;; XXX One of the tests uses a ZIP library to pack up some of the | |
243 | ;; source tree, and fails with "ZIP does not support timestamps | |
244 | ;; before 1980". Work around this by setting the file times in the | |
245 | ;; source tree to sometime in early 1980. | |
246 | (lambda _ | |
247 | (let ((circa-1980 (* 10 366 24 60 60))) | |
248 | (ftw "." (lambda (file stat flag) | |
249 | (utime file circa-1980 circa-1980) | |
250 | #t)) | |
02f0c3b2 | 251 | #t))) |
9ffe61b0 LC |
252 | (add-after 'install 'remove-tests |
253 | ;; Remove 25 MiB of unneeded unit tests. Keep test_support.* | |
254 | ;; because these files are used by some libraries out there. | |
255 | (lambda* (#:key outputs #:allow-other-keys) | |
256 | (let ((out (assoc-ref outputs "out"))) | |
257 | (match (scandir (string-append out "/lib") | |
258 | (lambda (name) | |
259 | (string-prefix? "python" name))) | |
260 | ((pythonX.Y) | |
261 | (let ((testdir (string-append out "/lib/" pythonX.Y | |
262 | "/test"))) | |
263 | (with-directory-excursion testdir | |
264 | (for-each delete-file-recursively | |
265 | (scandir testdir | |
266 | (match-lambda | |
267 | ((or "." "..") #f) | |
268 | (file | |
269 | (not | |
270 | (string-prefix? "test_support." | |
271 | file)))))) | |
272 | (call-with-output-file "__init__.py" (const #t)) | |
273 | #t))))))) | |
216c283b LC |
274 | (add-before 'strip 'make-libraries-writable |
275 | (lambda* (#:key outputs #:allow-other-keys) | |
276 | ;; Make .so files writable so they can be stripped. | |
277 | (let ((out (assoc-ref outputs "out"))) | |
278 | (for-each (lambda (file) | |
279 | (chmod file #o755)) | |
280 | (find-files (string-append out "/lib") | |
281 | "\\.so")) | |
282 | #t))) | |
02f0c3b2 LC |
283 | (add-after 'install 'move-tk-inter |
284 | (lambda* (#:key outputs #:allow-other-keys) | |
285 | ;; When Tkinter support is built move it to a separate output so | |
286 | ;; that the main output doesn't contain a reference to Tcl/Tk. | |
287 | (let ((out (assoc-ref outputs "out")) | |
288 | (tk (assoc-ref outputs "tk"))) | |
289 | (when tk | |
290 | (match (find-files out "tkinter.*\\.so") | |
291 | ((tkinter.so) | |
292 | ;; The .so is in OUT/lib/pythonX.Y/lib-dynload, but we | |
293 | ;; want it under TK/lib/pythonX.Y/site-packages. | |
294 | (let* ((len (string-length out)) | |
295 | (target (string-append | |
296 | tk "/" | |
297 | (string-drop | |
298 | (dirname (dirname tkinter.so)) | |
299 | len) | |
300 | "/site-packages"))) | |
301 | (install-file tkinter.so target) | |
302 | (delete-file tkinter.so))))) | |
303 | #t)))))) | |
a01b6da7 | 304 | (inputs |
3fdc99da CR |
305 | `(("bzip2" ,bzip2) |
306 | ("gdbm" ,gdbm) | |
b10ab723 | 307 | ("libffi" ,libffi) ; for ctypes |
b88e1b0a | 308 | ("sqlite" ,sqlite) ; for sqlite extension |
a01b6da7 | 309 | ("openssl" ,openssl) |
3fdc99da | 310 | ("readline" ,readline) |
afa181ff LC |
311 | ("zlib" ,zlib) |
312 | ("tcl" ,tcl) | |
313 | ("tk" ,tk))) ; for tkinter | |
b10ab723 CR |
314 | (native-inputs |
315 | `(("pkg-config" ,pkg-config))) | |
9be8d7c8 LC |
316 | (native-search-paths |
317 | (list (search-path-specification | |
318 | (variable "PYTHONPATH") | |
af070955 | 319 | (files '("lib/python2.7/site-packages"))))) |
f0499100 | 320 | (home-page "https://www.python.org") |
afa181ff | 321 | (synopsis "High-level, dynamically-typed programming language") |
a01b6da7 NK |
322 | (description |
323 | "Python is a remarkably powerful dynamic programming language that | |
324 | is used in a wide variety of application domains. Some of its key | |
325 | distinguishing features include: clear, readable syntax; strong | |
326 | introspection capabilities; intuitive object orientation; natural | |
327 | expression of procedural code; full modularity, supporting hierarchical | |
328 | packages; exception-based error handling; and very high level dynamic | |
329 | data types.") | |
3f641af0 | 330 | (license license:psfl))) |
acc26ff1 | 331 | |
45848023 HG |
332 | ;; Current 2.x version. |
333 | (define-public python-2 python-2.7) | |
334 | ||
72df6680 | 335 | (define-public python-3.5 |
b24d1cfc | 336 | (package (inherit python-2) |
343cee8a | 337 | (version "3.5.3") |
717003e3 LC |
338 | (source (origin |
339 | (method url-fetch) | |
340 | (uri (string-append "https://www.python.org/ftp/python/" | |
341 | version "/Python-" version ".tar.xz")) | |
fc1adab1 AK |
342 | (patches (search-patches |
343 | "python-fix-tests.patch" | |
72df6680 | 344 | "python-3.5-fix-tests.patch" |
e4d34cd0 | 345 | "python-3.5-getentropy-on-old-kernels.patch" |
fc1adab1 AK |
346 | "python-3-deterministic-build-info.patch" |
347 | "python-3-search-paths.patch")) | |
717003e3 LC |
348 | (patch-flags '("-p0")) |
349 | (sha256 | |
350 | (base32 | |
343cee8a | 351 | "1c6v1n9nz4mlx9mw1125fxpmbrgniqdbbx9hnqx44maqazb2mzpf")) |
fd615918 | 352 | (snippet |
e46e9573 EF |
353 | '(begin |
354 | (for-each delete-file | |
355 | '("Lib/ctypes/test/test_win32.py" ; fails on aarch64 | |
356 | "Lib/test/test_fcntl.py")) | |
357 | #t)))) | |
1f434457 MW |
358 | (arguments (substitute-keyword-arguments (package-arguments python-2) |
359 | ((#:tests? _) #t))) | |
1aebc0cb AE |
360 | (native-search-paths |
361 | (list (search-path-specification | |
362 | (variable "PYTHONPATH") | |
0e05d01e SB |
363 | (files (list (string-append "lib/python" |
364 | (version-major+minor version) | |
365 | "/site-packages")))))))) | |
f26a77ff | 366 | |
45848023 | 367 | ;; Current 3.x version. |
72df6680 | 368 | (define-public python-3 python-3.5) |
45848023 HG |
369 | |
370 | ;; Current major version. | |
371 | (define-public python python-3) | |
372 | ||
95288fcc LC |
373 | ;; Minimal variants of Python, mostly used to break the cycle between Tk and |
374 | ;; Python (Tk -> libxcb -> Python.) | |
375 | ||
376 | (define-public python2-minimal | |
377 | (package (inherit python-2) | |
378 | (name "python-minimal") | |
02f0c3b2 | 379 | (outputs '("out")) |
5927a843 LC |
380 | |
381 | ;; Keep zlib, which is used by 'pip' (via the 'zipimport' module), which | |
382 | ;; is invoked upon 'make install'. 'pip' also expects 'ctypes' and thus | |
383 | ;; libffi. | |
384 | (inputs `(("libffi" ,libffi) | |
385 | ("zlib" ,zlib))))) | |
95288fcc LC |
386 | |
387 | (define-public python-minimal | |
898238b9 | 388 | (package (inherit python) |
95288fcc | 389 | (name "python-minimal") |
02f0c3b2 | 390 | (outputs '("out")) |
95288fcc | 391 | |
d0b73960 | 392 | ;; Build fails due to missing ctypes without libffi. |
95288fcc LC |
393 | ;; OpenSSL is a mandatory dependency of Python 3.x, for urllib; |
394 | ;; zlib is required by 'zipimport', used by pip. | |
d0b73960 CAW |
395 | (inputs `(("libffi" ,libffi) |
396 | ("openssl" ,openssl) | |
95288fcc LC |
397 | ("zlib" ,zlib))))) |
398 | ||
64cb064c LC |
399 | (define* (wrap-python3 python |
400 | #:optional | |
401 | (name (string-append (package-name python) "-wrapper"))) | |
898238b9 | 402 | (package (inherit python) |
95288fcc | 403 | (name name) |
898238b9 AE |
404 | (source #f) |
405 | (build-system trivial-build-system) | |
02f0c3b2 | 406 | (outputs '("out")) |
3969ca54 | 407 | (inputs `(("bash" ,bash))) |
3c0f2329 | 408 | (propagated-inputs `(("python" ,python))) |
898238b9 AE |
409 | (arguments |
410 | `(#:modules ((guix build utils)) | |
411 | #:builder | |
412 | (begin | |
413 | (use-modules (guix build utils)) | |
414 | (let ((bin (string-append (assoc-ref %outputs "out") "/bin")) | |
415 | (python (string-append (assoc-ref %build-inputs "python") "/bin/"))) | |
416 | (mkdir-p bin) | |
417 | (for-each | |
418 | (lambda (old new) | |
419 | (symlink (string-append python old) | |
420 | (string-append bin "/" new))) | |
3969ca54 SB |
421 | `("python3" ,"pydoc3" ,"idle3" ,"pip3") |
422 | `("python" ,"pydoc" ,"idle" ,"pip")) | |
423 | ;; python-config outputs search paths based upon its location, | |
424 | ;; use a bash wrapper to avoid changing its outputs. | |
425 | (let ((bash (string-append (assoc-ref %build-inputs "bash") | |
426 | "/bin/bash")) | |
427 | (old (string-append python "python3-config")) | |
428 | (new (string-append bin "/python-config"))) | |
429 | (with-output-to-file new | |
430 | (lambda () | |
431 | (format #t "#!~a~%" bash) | |
432 | (format #t "exec \"~a\" \"$@\"~%" old) | |
433 | (chmod new #o755) | |
434 | #t))))))) | |
0d56e3e1 LC |
435 | (synopsis "Wrapper for the Python 3 commands") |
436 | (description | |
437 | "This package provides wrappers for the commands of Python@tie{}3.x such | |
438 | that they can be invoked under their usual name---e.g., @command{python} | |
439 | instead of @command{python3}."))) | |
440 | ||
95288fcc LC |
441 | (define-public python-wrapper (wrap-python3 python)) |
442 | (define-public python-minimal-wrapper (wrap-python3 python-minimal)) | |
898238b9 | 443 | |
aaf625b8 RW |
444 | (define-public python-psutil |
445 | (package | |
446 | (name "python-psutil") | |
88535a44 | 447 | (version "4.3.0") |
aaf625b8 RW |
448 | (source |
449 | (origin | |
450 | (method url-fetch) | |
f56777be | 451 | (uri (pypi-uri "psutil" version)) |
aaf625b8 RW |
452 | (sha256 |
453 | (base32 | |
88535a44 | 454 | "1w4r09fvn6kd80m5mx4ws1wz100brkaq6hzzpwrns8cgjzjpl6c6")))) |
aaf625b8 | 455 | (build-system python-build-system) |
fb08c4fe MB |
456 | (arguments |
457 | ;; FIXME: some tests does not return and times out. | |
458 | '(#:tests? #f)) | |
88535a44 | 459 | (home-page "https://www.github.com/giampaolo/psutil") |
aaf625b8 RW |
460 | (synopsis "Library for retrieving information on running processes") |
461 | (description | |
462 | "psutil (Python system and process utilities) is a library for retrieving | |
463 | information on running processes and system utilization (CPU, memory, disks, | |
464 | network) in Python. It is useful mainly for system monitoring, profiling and | |
465 | limiting process resources and management of running processes. It implements | |
466 | many functionalities offered by command line tools such as: ps, top, lsof, | |
467 | netstat, ifconfig, who, df, kill, free, nice, ionice, iostat, iotop, uptime, | |
468 | pidof, tty, taskset, pmap.") | |
3f641af0 | 469 | (license license:bsd-3))) |
aaf625b8 RW |
470 | |
471 | (define-public python2-psutil | |
472 | (package-with-python2 python-psutil)) | |
898238b9 | 473 | |
44e4a621 KK |
474 | (define-public python-shapely |
475 | (package | |
476 | (name "python-shapely") | |
477 | (version "1.6.3") | |
478 | (source | |
479 | (origin | |
480 | (method url-fetch) | |
481 | (uri (pypi-uri "Shapely" version)) | |
482 | (sha256 | |
483 | (base32 | |
484 | "0svc58dzcw9gj92b4sgq35sdxkf85z0qwlzxarkzq4bp3h8jy58l")))) | |
485 | (build-system python-build-system) | |
486 | (native-inputs | |
487 | `(("python-cython" ,python-cython) | |
488 | ("python-matplotlib" ,python-matplotlib) | |
489 | ("python-pytest" ,python-pytest) | |
490 | ("python-pytest-cov" ,python-pytest-cov))) | |
491 | (inputs | |
492 | `(("geos" ,geos))) | |
493 | (propagated-inputs | |
494 | `(("python-numpy" ,python-numpy))) | |
495 | (arguments | |
496 | `(#:phases | |
497 | (modify-phases %standard-phases | |
498 | (add-after 'unpack 'patch-geos-path | |
499 | (lambda* (#:key inputs #:allow-other-keys) | |
500 | (let ((geos (assoc-ref inputs "geos")) | |
501 | (glibc (assoc-ref inputs ,(if (%current-target-system) | |
502 | "cross-libc" "libc")))) | |
503 | (substitute* "shapely/geos.py" | |
504 | (("_lgeos = load_dll\\('geos_c', fallbacks=.*\\)") | |
505 | (string-append "_lgeos = load_dll('geos_c', fallbacks=['" | |
506 | geos "/lib/libgeos_c.so'])")) | |
507 | (("free = load_dll\\('c'\\)\\.free") | |
508 | (string-append "free = load_dll('c', fallbacks=['" | |
509 | glibc "/lib/libc.so.6']).free")))) | |
510 | #t))))) | |
511 | (home-page "https://github.com/Toblerity/Shapely") | |
512 | (synopsis "Library for the manipulation and analysis of geometric objects") | |
513 | (description "Shapely is a Python package for manipulation and analysis of | |
514 | planar geometric objects. It is based on the @code{GEOS} library.") | |
515 | (license license:bsd-3))) | |
516 | ||
517 | (define-public python2-shapely | |
518 | (package-with-python2 python-shapely)) | |
519 | ||
1f84ff51 MFM |
520 | (define-public python-clyent |
521 | (package | |
522 | (name "python-clyent") | |
523 | (version "1.2.1") | |
524 | (source | |
525 | (origin | |
526 | (method url-fetch) | |
527 | (uri (pypi-uri "clyent" version)) | |
528 | (sha256 | |
529 | (base32 | |
530 | "1r9987qmy1pz3hq54160bapqsywpq14waw4w9x3ly8hmq7kpgfbj")))) | |
531 | (build-system python-build-system) | |
532 | (native-inputs | |
533 | `(("python-mock" ,python-mock))) | |
534 | (home-page "https://github.com/binstar/clyent") | |
535 | (synopsis "Command line client library") | |
536 | (description "Clyent is a Python command line utiliy library. It is used | |
537 | by @code{binstar}, @code{binstar-build} and @code{chalmers}.") | |
538 | (license license:bsd-3))) | |
539 | ||
540 | (define-public python2-clyent | |
541 | (package-with-python2 python-clyent)) | |
542 | ||
89114f39 | 543 | (define-public python-babel |
5ace6e2f | 544 | (package |
89114f39 | 545 | (name "python-babel") |
ffb1e98d | 546 | (version "2.3.4") |
5ace6e2f CR |
547 | (source |
548 | (origin | |
549 | (method url-fetch) | |
b850a6d8 | 550 | (uri (pypi-uri "Babel" version)) |
5ace6e2f CR |
551 | (sha256 |
552 | (base32 | |
ffb1e98d | 553 | "0x98qqqw35xllpcama013a9788ly84z8dm1w2wwfpxh2710c8df5")))) |
5ace6e2f | 554 | (build-system python-build-system) |
f22efa01 | 555 | (propagated-inputs |
f3b98f4f | 556 | `(("python-pytz" ,python-pytz))) |
8498b8cf | 557 | (arguments `(#:tests? #f)) ; no test target |
e1804763 | 558 | (home-page "http://babel.pocoo.org/") |
5ace6e2f CR |
559 | (synopsis |
560 | "Tools for internationalizing Python applications") | |
561 | (description | |
562 | "Babel is composed of two major parts: | |
563 | - tools to build and work with gettext message catalogs | |
564 | - a Python interface to the CLDR (Common Locale Data Repository), providing | |
565 | access to various locale display names, localized number and date formatting, | |
566 | etc. ") | |
3f641af0 | 567 | (license license:bsd-3))) |
89114f39 AE |
568 | |
569 | (define-public python2-babel | |
11bb85a1 | 570 | (package-with-python2 python-babel)) |
73adf220 | 571 | |
ed377cc6 RW |
572 | (define-public python2-backport-ssl-match-hostname |
573 | (package | |
574 | (name "python2-backport-ssl-match-hostname") | |
f2d06d46 | 575 | (version "3.5.0.1") |
ed377cc6 RW |
576 | (source |
577 | (origin | |
578 | (method url-fetch) | |
579 | (uri (string-append | |
580 | "https://pypi.python.org/packages/source/b/" | |
581 | "backports.ssl_match_hostname/backports.ssl_match_hostname-" | |
582 | version ".tar.gz")) | |
583 | (sha256 | |
584 | (base32 | |
f2d06d46 | 585 | "1wndipik52cyqy0677zdgp90i435pmvwd89cz98lm7ri0y3xjajh")))) |
ed377cc6 | 586 | (build-system python-build-system) |
f2d06d46 EF |
587 | (arguments |
588 | `(#:python ,python-2 | |
589 | #:tests? #f)) ; no test target | |
f2d06d46 EF |
590 | (home-page "https://bitbucket.org/brandon/backports.ssl_match_hostname") |
591 | (synopsis "Backport of ssl.match_hostname() function from Python 3.5") | |
ed377cc6 RW |
592 | (description |
593 | "This backport brings the ssl.match_hostname() function to users of | |
594 | earlier versions of Python. The function checks the hostname in the | |
595 | certificate returned by the server to which a connection has been established, | |
596 | and verifies that it matches the intended target hostname.") | |
3f641af0 | 597 | (license license:psfl))) |
ed377cc6 | 598 | |
d205f895 TD |
599 | (define-public python-hdf4 |
600 | (package | |
601 | (name "python-hdf4") | |
602 | (version "0.9") | |
603 | (source | |
604 | (origin | |
605 | (method url-fetch) | |
606 | (uri (pypi-uri name version)) | |
607 | (sha256 | |
608 | (base32 | |
609 | "1hjiyrxvxk9817qyqky3nar4y3fs4z8wxz0n884zzb5wi6skrjks")))) | |
610 | (build-system python-build-system) | |
611 | (native-inputs `(("nose" ,python-nose))) | |
612 | (propagated-inputs `(("numpy" ,python-numpy))) | |
613 | (inputs | |
614 | `(("hdf4" ,hdf4) | |
615 | ("libjpeg" ,libjpeg) | |
616 | ("zlib" ,zlib))) | |
617 | (arguments | |
618 | `(#:phases | |
619 | (modify-phases %standard-phases | |
620 | (replace 'check | |
621 | (lambda _ | |
622 | ;; The 'runexamples' script sets PYTHONPATH to CWD, then goes | |
623 | ;; on to import numpy. Somehow this works on their CI system. | |
624 | ;; Let's just manage PYTHONPATH here instead. | |
625 | (substitute* "runexamples.sh" | |
626 | (("export PYTHONPATH=.*") "")) | |
627 | (setenv "PYTHONPATH" | |
628 | (string-append (getcwd) ":" | |
629 | (getenv "PYTHONPATH"))) | |
630 | (and (zero? (system* "./runexamples.sh")) | |
631 | (zero? (system* "nosetests" "-v")))))))) | |
632 | (home-page "https://github.com/fhs/python-hdf4") | |
633 | (synopsis "Python interface to the NCSA HDF4 library") | |
634 | (description | |
635 | "Python-HDF4 is a python wrapper around the NCSA HDF version 4 library, | |
636 | which implements the SD (Scientific Dataset), VS (Vdata) and V (Vgroup) API’s. | |
637 | NetCDF files can also be read and modified. Python-HDF4 is a fork of | |
638 | @url{http://hdfeos.org/software/pyhdf.php,pyhdf}.") | |
639 | (license license:expat))) | |
640 | ||
641 | (define-public python2-hdf4 | |
642 | (package-with-python2 python-hdf4)) | |
643 | ||
ef5cbf9b RW |
644 | (define-public python-h5py |
645 | (package | |
646 | (name "python-h5py") | |
5c78db62 | 647 | (version "2.7.0") |
ef5cbf9b RW |
648 | (source |
649 | (origin | |
650 | (method url-fetch) | |
fe147c41 | 651 | (uri (pypi-uri "h5py" version)) |
ef5cbf9b RW |
652 | (sha256 |
653 | (base32 | |
5c78db62 | 654 | "0433sdv6xc9p7v1xs1gvbxp7p152ywi3nplgjb258q9fvw9469br")))) |
ef5cbf9b | 655 | (build-system python-build-system) |
797e1401 RW |
656 | (arguments |
657 | `(#:tests? #f ; no test target | |
658 | #:phases | |
659 | (modify-phases %standard-phases | |
660 | (add-after 'unpack 'fix-hdf5-paths | |
661 | (lambda* (#:key inputs #:allow-other-keys) | |
662 | (let ((prefix (assoc-ref inputs "hdf5"))) | |
663 | (substitute* "setup_build.py" | |
664 | (("\\['/opt/local/lib', '/usr/local/lib'\\]") | |
665 | (string-append "['" prefix "/lib" "']")) | |
666 | (("'/opt/local/include', '/usr/local/include'") | |
667 | (string-append "'" prefix "/include" "'"))) | |
668 | (substitute* "setup_configure.py" | |
669 | (("\\['/usr/local/lib', '/opt/local/lib'\\]") | |
670 | (string-append "['" prefix "/lib" "']"))) | |
671 | #t)))))) | |
3c4010b1 | 672 | (propagated-inputs |
69866690 HG |
673 | `(("python-six" ,python-six) |
674 | ("python-numpy" ,python-numpy))) | |
ef5cbf9b | 675 | (inputs |
69866690 | 676 | `(("hdf5" ,hdf5))) |
ef5cbf9b | 677 | (native-inputs |
fe147c41 EF |
678 | `(("python-cython" ,python-cython) |
679 | ("python-pkgconfig" ,python-pkgconfig))) | |
ef5cbf9b RW |
680 | (home-page "http://www.h5py.org/") |
681 | (synopsis "Read and write HDF5 files from Python") | |
682 | (description | |
683 | "The h5py package provides both a high- and low-level interface to the | |
684 | HDF5 library from Python. The low-level interface is intended to be a | |
685 | complete wrapping of the HDF5 API, while the high-level component supports | |
686 | access to HDF5 files, datasets and groups using established Python and NumPy | |
687 | concepts.") | |
9820a028 | 688 | (license license:bsd-3))) |
ef5cbf9b RW |
689 | |
690 | (define-public python2-h5py | |
9820a028 | 691 | (package-with-python2 python-h5py)) |
ef5cbf9b | 692 | |
ea8450c8 TD |
693 | (define-public python-netcdf4 |
694 | (package | |
695 | (name "python-netcdf4") | |
1206c95a | 696 | (version "1.2.9") |
ea8450c8 TD |
697 | (source |
698 | (origin | |
699 | (method url-fetch) | |
700 | (uri (pypi-uri "netCDF4" version)) | |
701 | (sha256 | |
702 | (base32 | |
1206c95a | 703 | "1h6jq338amlbk0ilzvjyl7cck80i0bah9a5spn9in71vy2qxm7i5")))) |
ea8450c8 TD |
704 | (build-system python-build-system) |
705 | (native-inputs | |
706 | `(("python-cython" ,python-cython))) | |
707 | (propagated-inputs | |
708 | `(("python-numpy" ,python-numpy))) | |
709 | (inputs | |
710 | `(("netcdf" ,netcdf) | |
711 | ("hdf4" ,hdf4) | |
712 | ("hdf5" ,hdf5))) | |
713 | (arguments | |
714 | '(#:phases | |
715 | (modify-phases %standard-phases | |
716 | (replace 'check | |
717 | (lambda _ | |
718 | (setenv "NO_NET" "1") ; disable opendap tests | |
719 | (with-directory-excursion "test" | |
720 | (setenv "PYTHONPATH" ; find and add the library we just built | |
721 | (string-append | |
722 | (car (find-files "../build" "lib.*" | |
723 | #:directories? #:t | |
724 | #:fail-on-error? #:t)) | |
725 | ":" (getenv "PYTHONPATH"))) | |
726 | (zero? (system* "python" "run_all.py")))))))) | |
727 | (home-page | |
728 | "https://github.com/Unidata/netcdf4-python") | |
729 | (synopsis "Python/numpy interface to the netCDF library") | |
730 | (description "Netcdf4-python is a Python interface to the netCDF C | |
731 | library. netCDF version 4 has many features not found in earlier | |
732 | versions of the library and is implemented on top of HDF5. This module | |
733 | can read and write files in both the new netCDF 4 and the old netCDF 3 | |
734 | format, and can create files that are readable by HDF5 clients. The | |
735 | API is modelled after @code{Scientific.IO.NetCDF}, and should be familiar | |
736 | to users of that module.") | |
737 | ;; The software is mainly ISC, but includes some files covered | |
738 | ;; by the Expat license. | |
739 | (license (list license:isc license:expat)))) | |
740 | ||
741 | (define-public python2-netcdf4 | |
742 | (package-with-python2 python-netcdf4)) | |
743 | ||
c1448c69 EB |
744 | (define-public python-lockfile |
745 | (package | |
746 | (name "python-lockfile") | |
692add53 | 747 | (version "0.12.2") |
c1448c69 EB |
748 | (source |
749 | (origin | |
750 | (method url-fetch) | |
751 | (uri (string-append "https://pypi.python.org/packages/source/l/lockfile/" | |
752 | "lockfile-" version ".tar.gz")) | |
753 | (sha256 | |
754 | (base32 | |
692add53 | 755 | "16gpx5hm73ah5n1079ng0vy381hl802v606npkx4x8nb0gg05vba")))) |
c1448c69 EB |
756 | (build-system python-build-system) |
757 | (arguments '(#:test-target "check")) | |
692add53 BW |
758 | (native-inputs |
759 | `(("python-pbr" ,python-pbr))) | |
6a8f26a4 | 760 | (home-page "https://launchpad.net/pylockfile") |
c1448c69 EB |
761 | (synopsis "Platform-independent file locking module") |
762 | (description | |
763 | "The lockfile package exports a LockFile class which provides a simple | |
764 | API for locking files.") | |
f210e944 | 765 | (license license:expat))) |
c1448c69 EB |
766 | |
767 | (define-public python2-lockfile | |
f210e944 | 768 | (package-with-python2 python-lockfile)) |
c1448c69 | 769 | |
73adf220 AE |
770 | (define-public python-setuptools |
771 | (package | |
772 | (name "python-setuptools") | |
d660f7be | 773 | (version "31.0.0") |
73adf220 AE |
774 | (source |
775 | (origin | |
776 | (method url-fetch) | |
d660f7be | 777 | (uri (pypi-uri "setuptools" version)) |
73adf220 AE |
778 | (sha256 |
779 | (base32 | |
d660f7be | 780 | "0ypybh4hx3bv4vhg2dc74xpj1g56ggnaffm87k4abhwjwq6wq608")) |
e0ed4579 HG |
781 | (modules '((guix build utils))) |
782 | (snippet | |
783 | '(begin | |
784 | ;; Remove included binaries which are used to build self-extracting | |
785 | ;; installers for Windows. | |
786 | ;; TODO: Find some way to build them ourself so we can include them. | |
787 | (for-each delete-file (find-files "setuptools" "^(cli|gui).*\\.exe$")) | |
788 | #t)))) | |
73adf220 | 789 | (build-system python-build-system) |
d3d656c5 AE |
790 | ;; FIXME: Tests require pytest, which itself relies on setuptools. |
791 | ;; One could bootstrap with an internal untested setuptools. | |
73adf220 | 792 | (arguments |
824af8ca | 793 | `(#:tests? #f)) |
73adf220 AE |
794 | (home-page "https://pypi.python.org/pypi/setuptools") |
795 | (synopsis | |
796 | "Library designed to facilitate packaging Python projects") | |
797 | (description | |
798 | "Setuptools is a fully-featured, stable library designed to facilitate | |
799 | packaging Python projects, where packaging includes: | |
800 | Python package and module definitions, | |
801 | distribution package metadata, | |
802 | test hooks, | |
803 | project installation, | |
804 | platform-specific details, | |
805 | Python 3 support.") | |
d660f7be MB |
806 | ;; TODO: setuptools now bundles the following libraries: |
807 | ;; packaging, pyparsing, six and appdirs. How to unbundle? | |
808 | (license (list license:psfl ; setuptools itself | |
809 | license:expat ; six, appdirs, pyparsing | |
810 | license:asl2.0 ; packaging is dual ASL2/BSD-2 | |
811 | license:bsd-2)))) | |
73adf220 AE |
812 | |
813 | (define-public python2-setuptools | |
814 | (package-with-python2 python-setuptools)) | |
fc50e9c6 | 815 | |
fa56c773 KK |
816 | (define-public python-uniseg |
817 | (package | |
818 | (name "python-uniseg") | |
819 | (version "0.7.1") | |
820 | (source | |
821 | (origin | |
822 | (method url-fetch) | |
823 | (uri (string-append "https://bitbucket.org/emptypage/uniseg-python/" | |
824 | "get/rel-" version ".tar.gz")) | |
825 | (file-name (string-append name "-" version ".tar.gz")) | |
826 | (sha256 | |
827 | (base32 | |
828 | "1df4gddnj2a0v8z35wb2ra5vvh1f1qyxs8fgd25c8g64031mna6x")))) | |
829 | (build-system python-build-system) | |
830 | (arguments | |
831 | '(#:tests? #f)) ; The test suite requires network access. | |
832 | (home-page | |
833 | "https://bitbucket.org/emptypage/uniseg-python") | |
834 | (synopsis | |
835 | "Python library to determine Unicode text segmentations") | |
836 | (description | |
837 | "Uniseg is a Python package used to determine Unicode text segmentations. | |
838 | Supported segmentations include: | |
839 | @enumerate | |
840 | @item @dfn{Code point} (any value in the Unicode codespace) | |
841 | @item @dfn{Grapheme cluster} (user-perceived character made of a single or | |
842 | multiple Unicode code points, e.g. \"G\" + acute-accent) | |
843 | @item Word break | |
844 | @item Sentence break | |
845 | @item Line break | |
846 | @end enumerate") | |
847 | (license license:expat))) | |
848 | ||
849 | (define-public python2-uniseg | |
850 | (package-with-python2 python-uniseg)) | |
851 | ||
92eb9a35 | 852 | (define-public python-humanfriendly |
853 | (package | |
854 | (name "python-humanfriendly") | |
855 | (version "4.4.1") | |
856 | (source | |
857 | (origin | |
858 | (method url-fetch) | |
859 | (uri (pypi-uri "humanfriendly" version)) | |
860 | (sha256 | |
861 | (base32 | |
862 | "0pisgizjql86785jchfjv217g0lsgk114g2lja5j4y3lsc3b9szi")))) | |
863 | (build-system python-build-system) | |
864 | (arguments | |
865 | `(;; XXX: Tests depend on coloredlogs, which in turn depends on humanfriendly. | |
866 | #:tests? #f)) | |
867 | (propagated-inputs | |
868 | `(("python-monotonic" ,python-monotonic))) | |
869 | (home-page "https://humanfriendly.readthedocs.io") | |
870 | (synopsis "Human-friendly input and output in Python") | |
871 | (description | |
872 | "The functions and classes in @code{humanfriendly} can be used to make | |
873 | text interfaces more user-friendly. It includes tools to parse and format | |
874 | numbers, file sizes, and timespans, timers for long-running operations, menus | |
875 | to allow the user to choose from a list of options, and terminal interaction | |
876 | helpers.") | |
877 | (license license:expat))) | |
878 | ||
879 | (define-public python2-humanfriendly | |
880 | (package-with-python2 python-humanfriendly)) | |
881 | ||
2a81537f | 882 | (define-public python-capturer |
883 | (package | |
884 | (name "python-capturer") | |
885 | (version "2.4") | |
886 | (source | |
887 | (origin | |
888 | (method url-fetch) | |
889 | (uri (pypi-uri "capturer" version)) | |
890 | (sha256 | |
891 | (base32 | |
892 | "05d6ji4j8ipiq0br7bwam38qc6hd9l1djmfxlzrxx19ziyjl4089")))) | |
893 | (build-system python-build-system) | |
894 | (arguments | |
895 | `(#:tests? #f)) | |
896 | (propagated-inputs | |
897 | `(("python-humanfriendly" ,python-humanfriendly))) | |
898 | (home-page "https://capturer.readthedocs.io") | |
899 | (synopsis "Capture stdout and stderr streams of the current process") | |
900 | (description | |
901 | "The capturer package makes it easy to capture the stdout and stderr | |
902 | streams of the current process and subprocesses. Output can be relayed | |
903 | to the terminal in real time but is also available to the Python program | |
904 | for additional processing.") | |
905 | (license license:expat))) | |
906 | ||
907 | (define-public python2-capturer | |
908 | (package-with-python2 python-capturer)) | |
909 | ||
7d414763 | 910 | (define-public python-verboselogs |
911 | (package | |
912 | (name "python-verboselogs") | |
913 | (version "1.7") | |
914 | (source | |
915 | (origin | |
916 | (method url-fetch) | |
917 | (uri (pypi-uri "verboselogs" version)) | |
918 | (sha256 | |
919 | (base32 | |
920 | "09z4d1jiasn7k1hs5af2ckmnrd0i1d1m04bhfjhv7z6svzfdwgg3")))) | |
921 | (build-system python-build-system) | |
922 | (native-inputs | |
923 | `(("python-mock" ,python-mock) | |
924 | ("python-astroid" ,python-astroid) | |
925 | ("python-pylint" ,python-pylint))) | |
926 | (home-page "https://verboselogs.readthedocs.io") | |
927 | (synopsis "Verbose logging level for Python's logging module") | |
928 | (description | |
929 | "The @code{verboselogs} package extends Python's @code{logging} module to | |
930 | add the log levels NOTICE, SPAM, SUCCESS and VERBOSE.") | |
931 | (license license:expat))) | |
932 | ||
933 | (define-public python2-verboselogs | |
934 | (package-with-python2 python-verboselogs)) | |
935 | ||
00463093 | 936 | (define-public python-coloredlogs |
937 | (package | |
938 | (name "python-coloredlogs") | |
939 | (version "7.3") | |
940 | (source | |
941 | (origin | |
942 | (method url-fetch) | |
943 | (uri (pypi-uri "coloredlogs" version)) | |
944 | (sha256 | |
945 | (base32 | |
946 | "1blcann6dyg5dhps9pg12rn0q0rjrlajpmmil0gy0j4cbvnl2il9")))) | |
947 | (build-system python-build-system) | |
948 | (arguments | |
949 | `(;Tests require some updated modules | |
950 | #:tests? #f)) | |
951 | (propagated-inputs | |
952 | `(("python-capturer" ,python-capturer))) | |
953 | (home-page "https://coloredlogs.readthedocs.io") | |
954 | (synopsis "Colored stream handler for Python's logging module") | |
955 | (description | |
956 | "The @code{coloredlogs} package enables colored terminal output for | |
957 | Python's logging module. The @code{ColoredFormatter} class inherits from | |
958 | @code{logging.Formatter} and uses ANSI escape sequences to render your logging | |
959 | messages in color.") | |
960 | (license license:expat))) | |
961 | ||
962 | (define-public python2-coloredlogs | |
963 | (package-with-python2 python-coloredlogs)) | |
964 | ||
de959250 | 965 | (define-public python-eventlet |
966 | (package | |
967 | (name "python-eventlet") | |
968 | (version "0.20.1") | |
969 | (source | |
970 | (origin | |
971 | (method url-fetch) | |
972 | (uri (pypi-uri "eventlet" version)) | |
973 | (sha256 | |
974 | (base32 | |
975 | "0f3q55mq4n021wb7qa53pz3ix6i2py64sap66vsaqm2scjw83m9s")))) | |
976 | (build-system python-build-system) | |
977 | (propagated-inputs | |
978 | `(("python-greenlet" ,python-greenlet))) | |
5150d8b4 TGR |
979 | (arguments |
980 | ;; TODO: Requires unpackaged 'enum-compat'. | |
981 | '(#:tests? #f)) | |
de959250 | 982 | (home-page "http://eventlet.net") |
983 | (synopsis "Concurrent networking library for Python") | |
984 | (description | |
985 | "Eventlet is a concurrent networking library for Python that | |
986 | allows you to change how you run your code, not how you write it. | |
987 | It uses @code{epoll} or @code{libevent} for highly scalable non-blocking I/O. | |
988 | Coroutines ensure that the developer uses a blocking style of programming | |
989 | that is similar to threading, but provide the benefits of non-blocking I/O. | |
990 | The event dispatch is implicit, which means you can easily use @code{Eventlet} | |
991 | from the Python interpreter, or as a small part of a larger application.") | |
992 | (license license:expat))) | |
993 | ||
994 | (define-public python2-eventlet | |
995 | (let ((base (package-with-python2 | |
996 | (strip-python2-variant python-eventlet)))) | |
997 | (package (inherit base) | |
998 | (propagated-inputs | |
999 | `(("python2-enum34" ,python2-enum34) | |
1000 | ,@(package-propagated-inputs base)))))) | |
1001 | ||
a480bc41 EB |
1002 | (define-public python-six |
1003 | (package | |
1004 | (name "python-six") | |
b6ab89ef | 1005 | (version "1.10.0") |
a480bc41 EB |
1006 | (source |
1007 | (origin | |
1008 | (method url-fetch) | |
b6ab89ef | 1009 | (uri (pypi-uri "six" version)) |
a480bc41 EB |
1010 | (sha256 |
1011 | (base32 | |
b6ab89ef | 1012 | "0snmb8xffb3vsma0z67i0h0w2g2dy0p3gsgh9gi4i0kgc5l8spqh")))) |
a480bc41 | 1013 | (build-system python-build-system) |
4fd129ee MB |
1014 | (native-inputs |
1015 | `(("python-py" ,python-py) | |
1016 | ("python-pytest" ,python-pytest))) | |
9be5ecdf | 1017 | (home-page "https://pypi.python.org/pypi/six/") |
a480bc41 EB |
1018 | (synopsis "Python 2 and 3 compatibility utilities") |
1019 | (description | |
35b9e423 | 1020 | "Six is a Python 2 and 3 compatibility library. It provides utility |
a480bc41 EB |
1021 | functions for smoothing over the differences between the Python versions with |
1022 | the goal of writing Python code that is compatible on both Python versions. | |
35b9e423 | 1023 | Six supports every Python version since 2.5. It is contained in only one |
a480bc41 | 1024 | Python file, so it can be easily copied into your project.") |
3f641af0 | 1025 | (license license:x11))) |
a480bc41 | 1026 | |
0c20025c AE |
1027 | (define-public python2-six |
1028 | (package-with-python2 python-six)) | |
1029 | ||
24d15813 SR |
1030 | (define-public python-schedule |
1031 | (package | |
1032 | (name "python-schedule") | |
1033 | (version "0.4.3") | |
1034 | (source | |
1035 | (origin | |
1036 | (method url-fetch) | |
1037 | (uri (pypi-uri "schedule" version)) | |
1038 | (sha256 | |
1039 | (base32 | |
1040 | "0vplyjcbfrq50sphlwya749z8p2pcyi2nycw3518i0qpd9a6189i")))) | |
1041 | (build-system python-build-system) | |
1042 | (native-inputs | |
1043 | `(("python-pytest" ,python-pytest) | |
1044 | ("python-mock" ,python-mock))) | |
1045 | (home-page "https://github.com/dbader/schedule") | |
1046 | (synopsis "Schedule periodic function calls in Python") | |
1047 | (description | |
1048 | "Schedule is an in-process scheduler for periodic jobs that uses the | |
1049 | builder pattern for configuration. Schedule lets you run Python functions (or | |
1050 | any other callable) periodically at pre-determined intervals using a simple, | |
1051 | human-friendly syntax.") | |
1052 | (license license:expat))) | |
1053 | ||
1054 | (define-public python2-schedule | |
1055 | (package-with-python2 python-schedule)) | |
1056 | ||
d072efcb RW |
1057 | (define-public python-pandas |
1058 | (package | |
1059 | (name "python-pandas") | |
8e086048 | 1060 | (version "0.19.2") |
d072efcb RW |
1061 | (source |
1062 | (origin | |
1b96f069 | 1063 | (method url-fetch) |
8e086048 | 1064 | (uri (pypi-uri "pandas" version)) |
1b96f069 | 1065 | (sha256 |
b03ee02f MB |
1066 | (base32 "0540cnbwy2hc4hv2sxfs8i47xi91qzvzxfn80dl785ibiicly3vg")) |
1067 | (patches | |
1068 | (search-patches "python-pandas-skip-failing-tests.patch")))) | |
d072efcb | 1069 | (build-system python-build-system) |
d072efcb | 1070 | (propagated-inputs |
f22efa01 HG |
1071 | `(("python-numpy" ,python-numpy) |
1072 | ("python-pytz" ,python-pytz) | |
22d7360b | 1073 | ("python-dateutil" ,python-dateutil))) |
d072efcb | 1074 | (native-inputs |
abcc7a0e HG |
1075 | `(("python-nose" ,python-nose) |
1076 | ("python-cython" ,python-cython))) | |
d072efcb RW |
1077 | (home-page "http://pandas.pydata.org") |
1078 | (synopsis "Data structures for data analysis, time series, and statistics") | |
1079 | (description | |
1080 | "Pandas is a Python package providing fast, flexible, and expressive data | |
1081 | structures designed to make working with structured (tabular, | |
1082 | multidimensional, potentially heterogeneous) and time series data both easy | |
1083 | and intuitive. It aims to be the fundamental high-level building block for | |
1084 | doing practical, real world data analysis in Python.") | |
f210e944 | 1085 | (license license:bsd-3))) |
d072efcb RW |
1086 | |
1087 | (define-public python2-pandas | |
f210e944 | 1088 | (package-with-python2 python-pandas)) |
d072efcb | 1089 | |
2875caf5 AE |
1090 | (define-public python2-mechanize |
1091 | (package | |
1092 | (name "python2-mechanize") | |
1093 | (version "0.2.5") | |
1094 | (source | |
1095 | (origin | |
1096 | (method url-fetch) | |
1097 | (uri (string-append "https://pypi.python.org/packages/source/m/mechanize/mechanize-" | |
1098 | version ".tar.gz")) | |
1099 | (sha256 | |
1100 | (base32 | |
1101 | "0rj7r166i1dyrq0ihm5rijfmvhs8a04im28lv05c0c3v206v4rrf")))) | |
1102 | (build-system python-build-system) | |
2875caf5 AE |
1103 | (arguments |
1104 | `(#:python ,python-2 ; apparently incompatible with Python 3 | |
1105 | #:tests? #f)) | |
1106 | ;; test fails with message | |
1107 | ;; AttributeError: 'module' object has no attribute 'test_pullparser' | |
1108 | ;; (python-3.3.2) or | |
1109 | ;; AttributeError: 'module' object has no attribute 'test_urllib2_localnet' | |
1110 | ;; (python-2.7.5). | |
1111 | ;; The source code is from March 2011 and probably not up-to-date | |
1112 | ;; with respect to python unit tests. | |
1113 | (home-page "http://wwwsearch.sourceforge.net/mechanize/") | |
1114 | (synopsis | |
1115 | "Stateful programmatic web browsing in Python") | |
1116 | (description | |
1117 | "Mechanize implements stateful programmatic web browsing in Python, | |
1118 | after Andy Lester’s Perl module WWW::Mechanize.") | |
3f641af0 DC |
1119 | (license (license:non-copyleft |
1120 | "file://COPYING" | |
1121 | "See COPYING in the distribution.")))) | |
2875caf5 | 1122 | |
0352532e AE |
1123 | |
1124 | (define-public python-simplejson | |
1125 | (package | |
1126 | (name "python-simplejson") | |
b2e6e150 | 1127 | (version "3.10.0") |
0352532e AE |
1128 | (source |
1129 | (origin | |
1130 | (method url-fetch) | |
988d1bad | 1131 | (uri (pypi-uri "simplejson" version)) |
0352532e AE |
1132 | (sha256 |
1133 | (base32 | |
b2e6e150 | 1134 | "1qhwsykjlb85igb4cfl6v6gkprzbbg8gyqdd7zscc8w3x0ifcfwm")))) |
0352532e AE |
1135 | (build-system python-build-system) |
1136 | (home-page "http://simplejson.readthedocs.org/en/latest/") | |
1137 | (synopsis | |
1138 | "Json library for Python") | |
1139 | (description | |
e881752c AK |
1140 | "JSON (JavaScript Object Notation) is a subset of JavaScript |
1141 | syntax (ECMA-262 3rd edition) used as a lightweight data interchange | |
1142 | format. | |
0352532e AE |
1143 | |
1144 | Simplejson exposes an API familiar to users of the standard library marshal | |
1145 | and pickle modules. It is the externally maintained version of the json | |
1146 | library contained in Python 2.6, but maintains compatibility with Python 2.5 | |
1147 | and (currently) has significant performance advantages, even without using | |
1148 | the optional C extension for speedups. Simplejson is also supported on | |
1149 | Python 3.3+.") | |
3f641af0 | 1150 | (license license:x11))) |
0352532e AE |
1151 | |
1152 | (define-public python2-simplejson | |
1153 | (package-with-python2 python-simplejson)) | |
421a80a2 AE |
1154 | |
1155 | ||
ed07b08d | 1156 | (define-public python-pyicu |
421a80a2 | 1157 | (package |
ed07b08d | 1158 | (name "python-pyicu") |
d152d933 | 1159 | (version "1.9.8") |
421a80a2 AE |
1160 | (source |
1161 | (origin | |
1162 | (method url-fetch) | |
2e161eaf | 1163 | (uri (pypi-uri "PyICU" version)) |
421a80a2 AE |
1164 | (sha256 |
1165 | (base32 | |
d152d933 | 1166 | "05nz4p2dpkhwj6y9kik24xbvmfxji39nl0xw0sc0nvp9fgzf6xnd")))) |
421a80a2 AE |
1167 | (build-system python-build-system) |
1168 | (inputs | |
1169 | `(("icu4c" ,icu4c))) | |
d152d933 TGR |
1170 | (native-inputs |
1171 | `(("python-pytest" ,python-pytest) | |
1172 | ("python-six" ,python-six))) | |
8fab029d | 1173 | (home-page "https://github.com/ovalhub/pyicu") |
9e771e3b | 1174 | (synopsis "Python extension wrapping the ICU C++ API") |
421a80a2 AE |
1175 | (description |
1176 | "PyICU is a python extension wrapping the ICU C++ API.") | |
574b1d02 | 1177 | (properties `((python2-variant . ,(delay python2-pyicu)))) |
f210e944 | 1178 | (license license:x11))) |
ed07b08d LF |
1179 | |
1180 | (define-public python2-pyicu | |
d65854bd TGR |
1181 | (let ((base (package-with-python2 |
1182 | (strip-python2-variant python-pyicu)))) | |
1183 | (package | |
1184 | (inherit base) | |
1185 | (arguments | |
1186 | `(,@(package-arguments base) | |
1187 | #:phases | |
1188 | (modify-phases %standard-phases | |
1189 | (add-before 'check 'delete-failing-test | |
1190 | (λ _ | |
1191 | ;; XXX: This fails due to Unicode issues unique to Python 2, | |
1192 | ;; it seems: <https://github.com/ovalhub/pyicu/issues/61>. | |
1193 | (delete-file "test/test_Script.py") | |
1194 | #t)))))))) | |
cc20a22a LC |
1195 | |
1196 | (define-public python2-dogtail | |
1197 | ;; Python 2 only, as it leads to "TabError: inconsistent use of tabs and | |
1198 | ;; spaces in indentation" with Python 3. | |
1199 | (package | |
1200 | (name "python2-dogtail") | |
c5be3467 | 1201 | (version "0.9.9") |
cc20a22a LC |
1202 | (source (origin |
1203 | (method url-fetch) | |
c5be3467 | 1204 | (uri (pypi-uri "dogtail" version)) |
cc20a22a LC |
1205 | (sha256 |
1206 | (base32 | |
c5be3467 | 1207 | "0p5wfssvzr9w0bvhllzbbd8fnp4cca2qxcpcsc33dchrmh5n552x")))) |
cc20a22a LC |
1208 | (build-system python-build-system) |
1209 | (arguments `(#:python ,python-2 | |
1210 | #:tests? #f)) ; invalid command "test" | |
5ee684ff EJ |
1211 | ;; Currently no offical homepage. |
1212 | (home-page "https://pypi.python.org/pypi/dogtail/") | |
1003fbcf | 1213 | (synopsis "GUI test tool and automation framework written in Python") |
cc20a22a | 1214 | (description |
35b9e423 | 1215 | "Dogtail is a GUI test tool and automation framework written in Python. |
cc20a22a LC |
1216 | It uses Accessibility (a11y) technologies to communicate with desktop |
1217 | applications. dogtail scripts are written in Python and executed like any | |
1218 | other Python program.") | |
3f641af0 | 1219 | (license license:gpl2+))) |
515e6878 | 1220 | |
011b18c3 LC |
1221 | (define-public python2-empy |
1222 | (package | |
1223 | (name "python2-empy") | |
1224 | (version "3.3") | |
1225 | (source (origin | |
1226 | (method url-fetch) | |
1227 | (uri (string-append "http://www.alcyone.com/software/empy/empy-" | |
1228 | version ".tar.gz")) | |
1229 | (sha256 | |
1230 | (base32 | |
1231 | "01g8mmkfnvjdmlhsihwyx56lrg7r5m5d2fg6mnxsvy6g0dnl69f6")))) | |
1232 | (build-system python-build-system) | |
1233 | (arguments | |
1234 | `(#:python ,python-2 | |
dc1d3cde KK |
1235 | #:phases |
1236 | (modify-phases %standard-phases | |
1237 | (replace 'check | |
1238 | (lambda _ | |
1239 | (zero? (system* "./test.sh"))))))) | |
011b18c3 LC |
1240 | (home-page "http://www.alcyone.com/software/empy/") |
1241 | (synopsis "Templating system for Python") | |
1242 | (description | |
1243 | "EmPy is a system for embedding Python expressions and statements in | |
1244 | template text; it takes an EmPy source file, processes it, and produces | |
1245 | output. This is accomplished via expansions, which are special signals to the | |
1cd4027c | 1246 | EmPy system and are set off by a special prefix (by default the at sign, @@). |
011b18c3 LC |
1247 | EmPy can expand arbitrary Python expressions and statements in this way, as |
1248 | well as a variety of special forms. Textual data not explicitly delimited in | |
1249 | this way is sent unaffected to the output, allowing Python to be used in | |
1250 | effect as a markup language. Also supported are callbacks via hooks, | |
1251 | recording and playback via diversions, and dynamic, chainable filters. The | |
1252 | system is highly configurable via command line options and embedded | |
1253 | commands.") | |
3f641af0 | 1254 | (license license:lgpl2.1+))) |
011b18c3 | 1255 | |
8deeda0c LC |
1256 | (define-public python2-element-tree |
1257 | (package | |
1258 | (name "python2-element-tree") | |
1259 | (version "1.2.6") | |
1260 | (source (origin | |
1261 | (method url-fetch) | |
1262 | (uri (string-append | |
1263 | "http://effbot.org/media/downloads/elementtree-" | |
1264 | version "-20050316.tar.gz")) | |
1265 | (sha256 | |
1266 | (base32 | |
1267 | "016bphqnlg0l4vslahhw4r0aanw95bpypy65r1i1acyb2wj5z7dj")))) | |
1268 | (build-system python-build-system) | |
1269 | (arguments | |
1270 | `(#:python ,python-2 ; seems to be part of Python 3 | |
1271 | #:tests? #f)) ; no 'test' sub-command | |
1272 | (synopsis "Toolkit for XML processing in Python") | |
1273 | (description | |
1274 | "ElementTree is a Python library supporting lightweight XML processing.") | |
1275 | (home-page "http://effbot.org/zone/element-index.htm") | |
3f641af0 DC |
1276 | (license (license:x11-style |
1277 | "http://docs.python.org/2/license.html" | |
1278 | "Like \"CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2\".")))) | |
8deeda0c LC |
1279 | |
1280 | (define-public python2-pybugz | |
1281 | (package | |
1282 | (name "python2-pybugz") | |
1283 | (version "0.6.11") | |
1284 | (source (origin | |
1285 | (method url-fetch) | |
1286 | (uri (string-append | |
1287 | "http://bits.liquidx.net/projects/pybugz/pybugz-" | |
1288 | version ".tar.gz")) | |
1289 | (sha256 | |
1290 | (base32 | |
6f194a1e | 1291 | "17ni00p08gp5lkxlrrcnvi3x09fmajnlbz4da03qcgl9q21ym4jd")) |
fc1adab1 AK |
1292 | (patches (search-patches "pybugz-stty.patch" |
1293 | "pybugz-encode-error.patch")))) | |
8deeda0c LC |
1294 | (build-system python-build-system) |
1295 | (arguments | |
1296 | `(#:python ,python-2 ; SyntaxError with Python 3 | |
1297 | #:tests? #f)) ; no 'test' sub-command | |
f22efa01 HG |
1298 | (propagated-inputs |
1299 | `(("element-tree" ,python2-element-tree))) | |
8deeda0c LC |
1300 | (synopsis "Python and command-line interface to Bugzilla") |
1301 | (description | |
1302 | "PyBugz is a Python library and command-line tool to query the Bugzilla | |
1303 | bug tracking system. It is meant as an aid to speed up interaction with the | |
1304 | bug tracker.") | |
1305 | (home-page "http://www.liquidx.net/pybugz/") | |
3f641af0 | 1306 | (license license:gpl2))) |
8deeda0c | 1307 | |
a480bc41 EB |
1308 | (define-public python-enum34 |
1309 | (package | |
1310 | (name "python-enum34") | |
5e923414 | 1311 | (version "1.1.6") |
a480bc41 EB |
1312 | (source |
1313 | (origin | |
1314 | (method url-fetch) | |
d39ae1e5 | 1315 | (uri (pypi-uri "enum34" version)) |
a480bc41 EB |
1316 | (sha256 |
1317 | (base32 | |
5e923414 | 1318 | "1cgm5ng2gcfrkrm3hc22brl6chdmv67b9zvva9sfs7gn7dwc9n4a")))) |
a480bc41 | 1319 | (build-system python-build-system) |
a480bc41 EB |
1320 | (home-page "https://pypi.python.org/pypi/enum34") |
1321 | (synopsis "Backported Python 3.4 Enum") | |
1322 | (description | |
1323 | "Enum34 is the new Python stdlib enum module available in Python 3.4 | |
1324 | backported for previous versions of Python from 2.4 to 3.3.") | |
3f641af0 | 1325 | (license license:bsd-3))) |
a480bc41 | 1326 | |
820acd1b LF |
1327 | (define-public python2-enum34 |
1328 | (package-with-python2 python-enum34)) | |
1329 | ||
a480bc41 EB |
1330 | (define-public python-parse-type |
1331 | (package | |
1332 | (name "python-parse-type") | |
1333 | (version "0.3.4") | |
1334 | (source | |
1335 | (origin | |
1336 | (method url-fetch) | |
1337 | (uri (string-append "https://pypi.python.org/packages/source/p/" | |
1338 | "parse_type/parse_type-" version ".tar.gz")) | |
1339 | (sha256 | |
1340 | (base32 | |
1341 | "0iv1c34npr4iynwpgv1vkjx9rjd18a85ir8c01gc5f7wp8iv7l1x")))) | |
1342 | (build-system python-build-system) | |
8ed12889 DM |
1343 | (arguments |
1344 | `(#:phases | |
1345 | (modify-phases %standard-phases | |
1346 | (add-after 'unpack 'patch-tests | |
1347 | (lambda _ | |
1348 | (substitute* "tests/test_parse_type_parse.py" | |
1349 | ;; Newer Python versions don't have the problem this test tests. | |
1350 | (("self[.]assertRaises[(]parse.TooManyFields, p.parse, ''[)]") | |
1351 | "")) | |
1352 | #t))))) | |
f22efa01 | 1353 | (propagated-inputs |
f3b98f4f | 1354 | `(("python-six" ,python-six) |
68f1cdec | 1355 | ("python-parse" ,python-parse))) |
8ed12889 DM |
1356 | (native-inputs |
1357 | `(("python-pytest" ,python-pytest) | |
1358 | ("python-pytest-runner" ,python-pytest-runner))) | |
a480bc41 EB |
1359 | (home-page "https://github.com/jenisys/parse_type") |
1360 | (synopsis "Extended parse module") | |
1361 | (description | |
1362 | "Parse_type extends the python parse module.") | |
8ed12889 DM |
1363 | (properties |
1364 | `((python2-variant . ,(delay python2-parse-type)))) | |
3f641af0 | 1365 | (license license:bsd-3))) |
a480bc41 | 1366 | |
8ed12889 DM |
1367 | (define-public python2-parse-type |
1368 | (let ((base (package-with-python2 | |
1369 | (strip-python2-variant python-parse-type)))) | |
1370 | (package (inherit base) | |
1371 | (propagated-inputs | |
1372 | `(("python2-enum34" ,python2-enum34) | |
1373 | ,@(package-propagated-inputs base)))))) | |
1374 | ||
a480bc41 EB |
1375 | (define-public python-parse |
1376 | (package | |
1377 | (name "python-parse") | |
eb3d3503 | 1378 | (version "1.6.6") |
a480bc41 EB |
1379 | (source |
1380 | (origin | |
1381 | (method url-fetch) | |
eb3d3503 | 1382 | (uri (pypi-uri "parse" version)) |
a480bc41 EB |
1383 | (sha256 |
1384 | (base32 | |
aa6c09ed EF |
1385 | "0y31i3mwgv35qn0kzzjn9q8jqfdqmbi6sr6yfvn8rq4lqjm5lhvi")) |
1386 | (patches (search-patches "python-parse-too-many-fields.patch")))) | |
a480bc41 EB |
1387 | (build-system python-build-system) |
1388 | (arguments | |
1389 | `(#:phases | |
f9a65318 EF |
1390 | (modify-phases %standard-phases |
1391 | (replace 'check | |
1392 | (lambda _ (zero? (system* "python" "test_parse.py"))))))) | |
a480bc41 EB |
1393 | (home-page "https://github.com/r1chardj0n3s/parse") |
1394 | (synopsis "Parse strings") | |
1395 | (description | |
1396 | "Parse strings using a specification based on the Python format() | |
1397 | syntax.") | |
3f641af0 | 1398 | (license license:x11))) |
a480bc41 | 1399 | |
d3eff97a JL |
1400 | (define-public python-polib |
1401 | (package | |
1402 | (name "python-polib") | |
1403 | (version "1.0.8") | |
1404 | (source (origin | |
1405 | (method url-fetch) | |
1406 | (uri (pypi-uri "polib" version)) | |
1407 | (sha256 | |
1408 | (base32 | |
1409 | "1pq2hbm3m2q0cjdszk8mc4qa1vl3wcblh5nfyirlfnzb2pcy7zss")))) | |
1410 | (build-system python-build-system) | |
1411 | (home-page "https://bitbucket.org/izi/polib/wiki/Home") | |
1412 | (synopsis "Manipulate, create and modify gettext files") | |
1413 | (description "Polib can manipulate any gettext format (po, pot and mo) | |
1414 | files. It can be used to create po files from scratch or to modify | |
1415 | existing ones.") | |
1416 | (license license:expat))) | |
1417 | ||
1418 | (define-public python2-polib | |
1419 | (let ((base (package-with-python2 (strip-python2-variant python-polib)))) | |
1420 | (package | |
1421 | (inherit base) | |
1422 | (arguments `(,@(package-arguments base) | |
1423 | ;; Tests don't work with python2. | |
1424 | #:tests? #f))))) | |
a480bc41 | 1425 | |
515e6878 LC |
1426 | (define-public scons |
1427 | (package | |
1428 | (name "scons") | |
bf630276 | 1429 | (version "3.0.1") |
515e6878 LC |
1430 | (source (origin |
1431 | (method url-fetch) | |
de67e922 LF |
1432 | (uri (string-append "mirror://sourceforge/scons/scons/" version |
1433 | "/scons-" version ".tar.gz")) | |
515e6878 LC |
1434 | (sha256 |
1435 | (base32 | |
bf630276 | 1436 | "0wzid419mlwqw9llrg8gsx4nkzhqy16m4m40r0xnh6cwscw5wir4")))) |
515e6878 LC |
1437 | (build-system python-build-system) |
1438 | (arguments | |
bf630276 | 1439 | `(#:use-setuptools? #f ; still relies on distutils |
515e6878 LC |
1440 | #:tests? #f)) ; no 'python setup.py test' command |
1441 | (home-page "http://scons.org/") | |
1442 | (synopsis "Software construction tool written in Python") | |
1443 | (description | |
1444 | "SCons is a software construction tool. Think of SCons as an improved, | |
1445 | cross-platform substitute for the classic Make utility with integrated | |
1446 | functionality similar to autoconf/automake and compiler caches such as ccache. | |
1447 | In short, SCons is an easier, more reliable and faster way to build | |
1448 | software.") | |
3f641af0 | 1449 | (license license:x11))) |
011b18c3 | 1450 | |
bf630276 AI |
1451 | (define-public scons-python2 |
1452 | (package | |
1453 | (inherit (package-with-python2 scons)) | |
1454 | (name "scons-python2"))) | |
1455 | ||
c15a5c0e DT |
1456 | (define-public python-extras |
1457 | (package | |
1458 | (name "python-extras") | |
1459 | (version "0.0.3") | |
1460 | (source | |
1461 | (origin | |
1462 | (method url-fetch) | |
1463 | (uri (string-append | |
1464 | "https://pypi.python.org/packages/source/e/extras/extras-" | |
1465 | version ".tar.gz")) | |
1466 | (sha256 | |
1467 | (base32 | |
1468 | "1h7zx4dfyclalg0fqnfjijpn0f793a9mx8sy3b27gd31nr6dhq3s")))) | |
1469 | (build-system python-build-system) | |
c15a5c0e DT |
1470 | (arguments |
1471 | ;; error in setup.cfg: command 'test' has no such option 'buffer' | |
1472 | '(#:tests? #f)) | |
1473 | (home-page "https://github.com/testing-cabal/extras") | |
1474 | (synopsis "Useful extensions to the Python standard library") | |
1475 | (description | |
1476 | "Extras is a set of extensions to the Python standard library.") | |
bd3fa666 | 1477 | (license license:expat))) |
c15a5c0e DT |
1478 | |
1479 | (define-public python2-extras | |
1480 | (package-with-python2 python-extras)) | |
1481 | ||
56ea0efd DT |
1482 | (define-public python-mimeparse |
1483 | (package | |
1484 | (name "python-mimeparse") | |
1485 | (version "0.1.4") | |
1486 | (source | |
1487 | (origin | |
1488 | (method url-fetch) | |
1489 | (uri (string-append | |
1490 | "https://pypi.python.org/packages/source/p/python-mimeparse/python-mimeparse-" | |
1491 | version ".tar.gz")) | |
1492 | (sha256 | |
1493 | (base32 | |
1494 | "1hyxg09kaj02ri0rmwjqi86wk4nd1akvv7n0dx77azz76wga4s9w")))) | |
1495 | (build-system python-build-system) | |
56ea0efd DT |
1496 | (arguments |
1497 | '(#:tests? #f)) ; no setup.py test command | |
1498 | (home-page | |
1499 | "https://github.com/dbtsai/python-mimeparse") | |
9e771e3b | 1500 | (synopsis "Python library for parsing MIME types") |
56ea0efd DT |
1501 | (description |
1502 | "Mimeparse provides basic functions for parsing MIME type names and | |
1503 | matching them against a list of media-ranges.") | |
bd3fa666 | 1504 | (license license:expat))) |
56ea0efd DT |
1505 | |
1506 | (define-public python2-mimeparse | |
1507 | (package-with-python2 python-mimeparse)) | |
1508 | ||
02f8f804 | 1509 | (define-public python-pafy |
1510 | (package | |
1511 | (name "python-pafy") | |
745d85b7 | 1512 | (version "0.5.3.1") |
02f8f804 | 1513 | (source |
1514 | (origin | |
1515 | (method url-fetch) | |
1516 | (uri (pypi-uri "pafy" version)) | |
1517 | (sha256 | |
1518 | (base32 | |
745d85b7 | 1519 | "1a7dxi95m1043rxx1r5x3ngb66nwlq6aqcasyqqjzmmmjps4zrim")))) |
02f8f804 | 1520 | (build-system python-build-system) |
ed3fee5f | 1521 | (arguments |
1522 | `(#:tests? #f)) ; Currently pafy can not find itself in the tests | |
02f8f804 | 1523 | (propagated-inputs |
1524 | ;; Youtube-dl is a python package which is imported in the file | |
1525 | ;; "backend_youtube_dl.py", therefore it needs to be propagated. | |
1526 | `(("youtube-dl" ,youtube-dl))) | |
1527 | (home-page "https://np1.github.io/pafy/") | |
1528 | (synopsis "Retrieve YouTube content and metadata") | |
1529 | (description | |
1530 | "@code{pafy} is a python library to retrieve YouTube content and metadata.") | |
1531 | (license license:lgpl3+))) | |
1532 | ||
542ad60f DT |
1533 | (define-public python-py |
1534 | (package | |
1535 | (name "python-py") | |
b9463fdb | 1536 | (version "1.4.32") |
542ad60f DT |
1537 | (source |
1538 | (origin | |
1539 | (method url-fetch) | |
71c8a804 | 1540 | (uri (pypi-uri "py" version)) |
542ad60f DT |
1541 | (sha256 |
1542 | (base32 | |
b9463fdb | 1543 | "19s1pql9pq85h1qzsdwgyb8a3k1qgkvh33b02m8kfqhizz8rzf64")))) |
542ad60f | 1544 | (build-system python-build-system) |
dcb0da7b MB |
1545 | (arguments |
1546 | ;; FIXME: "ImportError: 'test' module incorrectly imported from | |
1547 | ;; '/gnu/store/...-python-pytest-mimimal-3.0.5/lib/python3.5/site-packages'. | |
1548 | ;; Expected '/tmp/guix-build-python-py-1.4.31.drv-0/py-1.4.31/py'. | |
1549 | ;; Is this module globally installed?" | |
1550 | '(#:tests? #f)) | |
542ad60f DT |
1551 | (home-page "http://pylib.readthedocs.org/") |
1552 | (synopsis "Python library for parsing, I/O, instrospection, and logging") | |
1553 | (description | |
1554 | "Py is a Python library for file name parsing, .ini file parsing, I/O, | |
1555 | code introspection, and logging.") | |
bd3fa666 | 1556 | (license license:expat))) |
542ad60f DT |
1557 | |
1558 | (define-public python2-py | |
1559 | (package-with-python2 python-py)) | |
1560 | ||
d2a8db92 HG |
1561 | ;; Recent versions of python-fixtures and python-testrepository need |
1562 | ;; python-pbr for packaging, which itself needs these two packages for | |
1563 | ;; testing. | |
1564 | ;; To fix this circular dependency, we use a build of python-pbr, based on the | |
1565 | ;; same source, just without any test dependencies and with tests disabled. | |
1566 | ;; python-pbr-minmal is then used to package python-fixtures and | |
1567 | ;; python-testrepository. | |
1568 | ;; Strictly speaking we currently could remove the test-requirements from the | |
1569 | ;; normal python-pbr package (and save this package) since test are disabled | |
1570 | ;; there anyway. But this may change in future. | |
ac257f12 | 1571 | (define-public python-pbr-minimal |
cd49454b | 1572 | (package |
d2a8db92 | 1573 | (name "python-pbr-minimal") |
269504a7 | 1574 | (version "3.0.1") |
7787ef76 CR |
1575 | (source |
1576 | (origin | |
1577 | (method url-fetch) | |
d2a8db92 | 1578 | (uri (pypi-uri "pbr" version)) |
7787ef76 CR |
1579 | (sha256 |
1580 | (base32 | |
269504a7 | 1581 | "14fs5acnalnb3h62s7q7av239j541fk0n0z0lawh4h09b1s93s6p")))) |
7787ef76 CR |
1582 | (build-system python-build-system) |
1583 | (arguments | |
d2a8db92 HG |
1584 | `(#:tests? #f)) |
1585 | (home-page "http://docs.openstack.org/developer/pbr/") | |
1586 | (synopsis "Minimal build of python-pbr used for bootstrapping") | |
7787ef76 | 1587 | (description |
d2a8db92 | 1588 | "Used only for bootstrapping python2-pbr, you should not need this.") |
3f641af0 | 1589 | (license license:asl2.0))) |
7787ef76 | 1590 | |
ac257f12 | 1591 | (define-public python2-pbr-minimal |
d2a8db92 | 1592 | (package-with-python2 python-pbr-minimal)) |
7787ef76 | 1593 | |
1ef09c0c | 1594 | (define-public python-pbr |
e25f0174 | 1595 | (package |
d2a8db92 | 1596 | (inherit python-pbr-minimal) |
e25f0174 | 1597 | (name "python-pbr") |
e25f0174 BW |
1598 | (arguments |
1599 | `(#:tests? #f)) ;; Most tests seem to use the Internet. | |
1600 | (propagated-inputs | |
d2a8db92 HG |
1601 | `(("git" ,git))) ;; pbr actually uses the "git" binary. |
1602 | (native-inputs | |
e25f0174 | 1603 | `(("python-fixtures" ,python-fixtures) |
d2a8db92 | 1604 | ;; discover, coverage, hacking, subunit |
e25f0174 | 1605 | ("python-mock" ,python-mock) |
d2a8db92 | 1606 | ("python-six" ,python-six) |
e25f0174 BW |
1607 | ("python-sphinx" ,python-sphinx) |
1608 | ("python-testrepository" ,python-testrepository) | |
1609 | ("python-testresources" ,python-testresources) | |
1610 | ("python-testscenarios" ,python-testscenarios) | |
1611 | ("python-testtools" ,python-testtools) | |
1612 | ("python-virtualenv" ,python-virtualenv))) | |
d2a8db92 | 1613 | (synopsis "Enhance the default behavior of Python’s setuptools") |
e25f0174 BW |
1614 | (description |
1615 | "Python Build Reasonableness (PBR) is a library that injects some useful | |
d2a8db92 HG |
1616 | and sensible default behaviors into your setuptools run. It will set |
1617 | versions, process requirements files and generate AUTHORS and ChangeLog file | |
1618 | from git information. | |
1619 | "))) | |
1ef09c0c BW |
1620 | |
1621 | (define-public python2-pbr | |
e25f0174 | 1622 | (package-with-python2 python-pbr)) |
1ef09c0c | 1623 | |
c7303d3c DT |
1624 | (define-public python-exif-read |
1625 | (package | |
1626 | (name "python-exif-read") | |
2a2d0981 | 1627 | (version "2.1.2") |
c7303d3c DT |
1628 | (source (origin |
1629 | (method url-fetch) | |
2a2d0981 | 1630 | (uri (pypi-uri "ExifRead" version)) |
c7303d3c DT |
1631 | (sha256 |
1632 | (base32 | |
2a2d0981 | 1633 | "1b90jf6m9vxh9nanhpyvqdq7hmfx5iggw1l8kq10jrs6xgr49qkr")))) |
c7303d3c | 1634 | (build-system python-build-system) |
c7303d3c DT |
1635 | (arguments `(#:tests? #f)) ; no tests |
1636 | (home-page "https://github.com/ianare/exif-py") | |
1637 | (synopsis "Python library to extract EXIF data from image files") | |
1638 | (description | |
1639 | "ExifRead is a Python library to extract EXIF data from tiff and jpeg | |
1640 | files.") | |
3f641af0 | 1641 | (license license:bsd-3))) |
c7303d3c DT |
1642 | |
1643 | (define-public python2-exif-read | |
1644 | (package-with-python2 python-exif-read)) | |
d5f89b22 DT |
1645 | |
1646 | (define-public python-pyld | |
1647 | (package | |
1648 | (name "python-pyld") | |
8957af32 | 1649 | (version "0.7.1") |
d5f89b22 DT |
1650 | (source (origin |
1651 | (method url-fetch) | |
af1ab773 | 1652 | (uri (pypi-uri "PyLD" version)) |
d5f89b22 DT |
1653 | (sha256 |
1654 | (base32 | |
8957af32 | 1655 | "1m0fs6897vxfkf7awah5i66i7b7smm5fnywf1w50fpzyfbfhr156")))) |
d5f89b22 | 1656 | (build-system python-build-system) |
d5f89b22 | 1657 | (arguments `(#:tests? #f)) ; no tests |
7bf837fd | 1658 | (home-page "https://github.com/digitalbazaar/pyld") |
d5f89b22 DT |
1659 | (synopsis "Python implementation of the JSON-LD specification") |
1660 | (description | |
1661 | "PyLD is an implementation of the JSON-LD specification.") | |
3f641af0 | 1662 | (license license:bsd-3))) |
d5f89b22 DT |
1663 | |
1664 | (define-public python2-pyld | |
1665 | (package-with-python2 python-pyld)) | |
3a1f9a68 | 1666 | |
12c270dd RW |
1667 | (define-public python-click |
1668 | (package | |
1669 | (name "python-click") | |
d4acb6db | 1670 | (version "6.7") |
12c270dd RW |
1671 | (source |
1672 | (origin | |
1673 | (method url-fetch) | |
375f224b | 1674 | (uri (pypi-uri "click" version)) |
12c270dd | 1675 | (sha256 |
43accb58 | 1676 | (base32 |
d4acb6db | 1677 | "02qkfpykbq35id8glfgwc38yc430427yd05z1wc5cnld8zgicmgi")))) |
12c270dd | 1678 | (build-system python-build-system) |
e2ab5a09 BW |
1679 | (arguments |
1680 | `(#:phases | |
1681 | (modify-phases %standard-phases | |
1682 | (add-after 'unpack 'fix-paths | |
1683 | (lambda* (#:key inputs #:allow-other-keys) | |
1684 | (let ((glibc (assoc-ref inputs ,(if (%current-target-system) | |
1685 | "cross-libc" "libc")))) | |
1686 | (substitute* "click/_unicodefun.py" | |
1687 | (("'locale'") | |
1688 | (string-append "'" glibc "/bin/locale'")))) | |
97be1bc2 MB |
1689 | #t)) |
1690 | (replace 'check | |
1691 | (lambda _ | |
1692 | (zero? (system* "make" "test"))))))) | |
1693 | (native-inputs | |
1694 | `(("python-pytest" ,python-pytest))) | |
12c270dd RW |
1695 | (home-page "http://click.pocoo.org") |
1696 | (synopsis "Command line library for Python") | |
1697 | (description | |
1698 | "Click is a Python package for creating command line interfaces in a | |
1699 | composable way with as little code as necessary. Its name stands for | |
1700 | \"Command Line Interface Creation Kit\". It's highly configurable but comes | |
1701 | with sensible defaults out of the box.") | |
3f641af0 | 1702 | (license license:bsd-3))) |
12c270dd RW |
1703 | |
1704 | (define-public python2-click | |
1705 | (package-with-python2 python-click)) | |
1706 | ||
addc808d EF |
1707 | (define-public python-wheel |
1708 | (package | |
1709 | (name "python-wheel") | |
0e6df70b | 1710 | (version "0.30.0a0") |
e1ba0749 EF |
1711 | (source |
1712 | (origin | |
1713 | (method url-fetch) | |
1714 | (uri (pypi-uri "wheel" version)) | |
1715 | (sha256 | |
1716 | (base32 | |
0e6df70b | 1717 | "1nm6mn8isny0hr86rhbfrpfj867c0phf001xgsd69xfp9ady1wwq")))) |
e1ba0749 EF |
1718 | (build-system python-build-system) |
1719 | (native-inputs | |
f3b98f4f | 1720 | `(("python-jsonschema" ,python-jsonschema) |
e1ba0749 EF |
1721 | ("python-pytest-cov" ,python-pytest-cov))) |
1722 | (home-page "https://bitbucket.org/pypa/wheel/") | |
1723 | (synopsis "Format for built Python packages") | |
1724 | (description | |
1725 | "A wheel is a ZIP-format archive with a specially formatted filename and | |
1726 | the @code{.whl} extension. It is designed to contain all the files for a PEP | |
1727 | 376 compatible install in a way that is very close to the on-disk format. Many | |
1728 | packages will be properly installed with only the @code{Unpack} step and the | |
1729 | unpacked archive preserves enough information to @code{Spread} (copy data and | |
1730 | scripts to their final locations) at any later time. Wheel files can be | |
1731 | installed with a newer @code{pip} or with wheel's own command line utility.") | |
8ad4ae20 LF |
1732 | (license license:expat) |
1733 | (properties `((python2-variant . ,(delay python2-wheel)))))) | |
addc808d EF |
1734 | |
1735 | (define-public python2-wheel | |
8ad4ae20 LF |
1736 | (let ((wheel (package-with-python2 |
1737 | (strip-python2-variant python-wheel)))) | |
264ae686 | 1738 | (package (inherit wheel) |
8ad4ae20 LF |
1739 | (native-inputs `(("python2-functools32" ,python2-functools32) |
1740 | ,@(package-native-inputs wheel)))))) | |
1741 | ||
ea521b42 DT |
1742 | (define-public python-vcversioner |
1743 | (package | |
1744 | (name "python-vcversioner") | |
538fe019 | 1745 | (version "2.16.0.0") |
ea521b42 DT |
1746 | (source |
1747 | (origin | |
1748 | (method url-fetch) | |
1749 | (uri (pypi-uri "vcversioner" version)) | |
1750 | (sha256 | |
1751 | (base32 | |
538fe019 | 1752 | "16z10sm78jd7ca3jbkgc3q5i8a8q7y1h21q1li21yy3rlhbhrrns")))) |
ea521b42 | 1753 | (build-system python-build-system) |
ea521b42 DT |
1754 | (synopsis "Python library for version number discovery") |
1755 | (description "Vcversioner is a Python library that inspects tagging | |
1756 | information in a variety of version control systems in order to discover | |
1757 | version numbers.") | |
1758 | (home-page "https://github.com/habnabit/vcversioner") | |
f210e944 | 1759 | (license license:isc))) |
ea521b42 DT |
1760 | |
1761 | (define-public python2-vcversioner | |
f210e944 | 1762 | (package-with-python2 python-vcversioner)) |
ae641128 | 1763 | |
864b5211 DT |
1764 | (define-public python-jsonschema |
1765 | (package | |
1766 | (name "python-jsonschema") | |
b3667afb | 1767 | (version "2.5.1") |
864b5211 DT |
1768 | (source (origin |
1769 | (method url-fetch) | |
1770 | (uri | |
1771 | (string-append | |
1772 | "https://pypi.python.org/packages/source/j/jsonschema/jsonschema-" | |
1773 | version ".tar.gz")) | |
1774 | (sha256 | |
1775 | (base32 | |
b3667afb | 1776 | "0hddbqjm4jq63y8jf44nswina1crjs16l9snb6m3vvgyg31klrrn")))) |
864b5211 | 1777 | (build-system python-build-system) |
8bcd6b91 EF |
1778 | (arguments |
1779 | '(#:phases | |
1780 | (modify-phases %standard-phases | |
1781 | (replace 'check (lambda _ (zero? (system* "nosetests"))))))) | |
eaba9d66 | 1782 | (native-inputs |
8bcd6b91 EF |
1783 | `(("python-nose" ,python-nose) |
1784 | ("python-vcversioner" ,python-vcversioner))) | |
1785 | (home-page "https://github.com/Julian/jsonschema") | |
864b5211 DT |
1786 | (synopsis "Implementation of JSON Schema for Python") |
1787 | (description | |
1788 | "Jsonschema is an implementation of JSON Schema for Python.") | |
a14600ec LF |
1789 | (license license:expat) |
1790 | (properties `((python2-variant . ,(delay python2-jsonschema)))))) | |
864b5211 DT |
1791 | |
1792 | (define-public python2-jsonschema | |
a14600ec LF |
1793 | (let ((jsonschema (package-with-python2 |
1794 | (strip-python2-variant python-jsonschema)))) | |
264ae686 | 1795 | (package (inherit jsonschema) |
eaba9d66 | 1796 | (native-inputs |
8bcd6b91 | 1797 | `(("python2-mock" ,python2-mock) |
eaba9d66 MB |
1798 | ,@(package-native-inputs jsonschema))) |
1799 | (propagated-inputs | |
1800 | `(("python2-functools32" ,python2-functools32)))))) | |
850189b8 | 1801 | |
7734ed7a OP |
1802 | (define-public python-schema |
1803 | (package | |
1804 | (name "python-schema") | |
1805 | (version "0.6.6") | |
1806 | (source | |
1807 | (origin | |
1808 | (method url-fetch) | |
1809 | (uri (pypi-uri "schema" version)) | |
1810 | (sha256 | |
1811 | (base32 | |
1812 | "1lw28j9w9vxyigg7vkfkvi6ic9lgjkdnfvnxdr7pklslqvzmk2vm")))) | |
1813 | (build-system python-build-system) | |
1814 | (native-inputs | |
1815 | `(("python-pytest" ,python-pytest))) | |
1816 | (home-page "https://github.com/keleshev/schema") | |
1817 | (synopsis "Simple data validation library") | |
1818 | (description | |
1819 | "@code{python-schema} is a library for validating Python data | |
1820 | structures, such as those obtained from config-files, forms, external | |
1821 | services or command-line parsing, converted from JSON/YAML (or | |
1822 | something else) to Python data-types.") | |
1823 | (license license:psfl))) | |
1824 | ||
1825 | (define-public python2-schema | |
1826 | (package-with-python2 python-schema)) | |
1827 | ||
1828 | (define-public python-schema-0.5 | |
1829 | (package (inherit python-schema) | |
1830 | (version "0.5.0") | |
1831 | (source | |
1832 | (origin | |
1833 | (method url-fetch) | |
1834 | (uri (pypi-uri "schema" version)) | |
1835 | (sha256 | |
1836 | (base32 | |
1837 | "10zqvpaky51kgb8nd42bk7jwl8cn2zvayxjpdc1wwmpybj92x67s")))))) | |
1838 | ||
1839 | (define-public python2-schema-0.5 | |
1840 | (package-with-python2 python-schema-0.5)) | |
1841 | ||
9f21414d | 1842 | (define-public python-kitchen |
1843 | (package | |
1844 | (name "python-kitchen") | |
1845 | (version "1.2.4") | |
1846 | (source | |
1847 | (origin | |
1848 | (method url-fetch) | |
1849 | (uri (pypi-uri "kitchen" version)) | |
1850 | (sha256 | |
1851 | (base32 | |
1852 | "0ggv3p4x8jvmmzhp0xm00h6pvh1g0gmycw71rjwagnrj8n23vxrq")))) | |
1853 | (build-system python-build-system) | |
1854 | (propagated-inputs | |
1855 | `(("python-chardet" ,python-chardet))) | |
cb542830 | 1856 | (home-page "https://github.com/fedora-infra/kitchen") |
9f21414d | 1857 | (synopsis "Python API for snippets") |
1858 | (description "@code{kitchen} module provides a python API for all sorts of | |
1859 | little useful snippets of code that everybody ends up writing for their projects | |
1860 | but never seem big enough to build an independent release. Use kitchen and stop | |
1861 | cutting and pasting that code over and over.") | |
1862 | (license (list license:lgpl2.1+ | |
1863 | ;; subprocess.py, test_subprocess.py, | |
1864 | ;; kitchen/pycompat25/defaultdict.py: | |
1865 | license:psfl)))) | |
1866 | ||
1867 | (define-public python2-kitchen | |
1868 | (package-with-python2 python-kitchen)) | |
1869 | ||
850189b8 DT |
1870 | (define-public python-unidecode |
1871 | (package | |
1872 | (name "python-unidecode") | |
c37f58b7 | 1873 | (version "0.04.21") |
850189b8 DT |
1874 | (source (origin |
1875 | (method url-fetch) | |
8925d4f3 | 1876 | (uri (pypi-uri "Unidecode" version)) |
850189b8 DT |
1877 | (sha256 |
1878 | (base32 | |
c37f58b7 | 1879 | "0lfhp9c5xrbpjvbpr12ji52g1lx04404bzzdg6pvabhzisw6l2i8")))) |
850189b8 | 1880 | (build-system python-build-system) |
850189b8 DT |
1881 | (home-page "https://pypi.python.org/pypi/Unidecode") |
1882 | (synopsis "ASCII transliterations of Unicode text") | |
1883 | (description | |
1884 | "Unidecode provides ASCII transliterations of Unicode text. Unidecode is | |
1885 | useful when integrating with legacy code that doesn't support Unicode, or for | |
1886 | ease of entry of non-Roman names on a US keyboard, or when constructing ASCII | |
1887 | machine identifiers from human-readable Unicode strings that should still be | |
a0b80a57 | 1888 | somewhat intelligible.") |
3f641af0 | 1889 | (license license:gpl2+))) |
850189b8 DT |
1890 | |
1891 | (define-public python2-unidecode | |
1892 | (package-with-python2 python-unidecode)) | |
6d45fef4 DT |
1893 | |
1894 | (define-public python-pyjwt | |
1895 | (package | |
1896 | (name "python-pyjwt") | |
ad0f92d0 | 1897 | (version "1.5.3") |
6d45fef4 DT |
1898 | (source |
1899 | (origin | |
1900 | (method url-fetch) | |
eb31d4b4 | 1901 | (uri (pypi-uri "PyJWT" version)) |
6d45fef4 DT |
1902 | (sha256 |
1903 | (base32 | |
ad0f92d0 | 1904 | "1rxsg14i33vm2i6lz0my628108c81k43v10n4h3p0gx62xdyf2sh")) |
7e31427f MB |
1905 | (modules '((guix build utils))) |
1906 | (snippet | |
1907 | '(begin | |
1908 | (for-each delete-file-recursively | |
1909 | (find-files "." "\\.pyc$")) | |
1910 | #t)))) | |
6d45fef4 | 1911 | (build-system python-build-system) |
eb31d4b4 | 1912 | (native-inputs |
7e31427f | 1913 | `(("python-pytest" ,python-pytest-3.0) |
130fe994 HG |
1914 | ("python-pytest-cov" ,python-pytest-cov) |
1915 | ("python-pytest-runner" ,python-pytest-runner))) | |
7bf837fd | 1916 | (home-page "https://github.com/progrium/pyjwt") |
6d45fef4 DT |
1917 | (synopsis "JSON Web Token implementation in Python") |
1918 | (description | |
1919 | "PyJWT is a JSON Web Token implementation written in Python.") | |
bd3fa666 | 1920 | (license license:expat))) |
6d45fef4 DT |
1921 | |
1922 | (define-public python2-pyjwt | |
1923 | (package-with-python2 python-pyjwt)) | |
1924 | ||
a80488c2 | 1925 | (define-public python-pykka |
1926 | (package | |
1927 | (name "python-pykka") | |
1928 | (version "1.2.1") | |
1929 | (source | |
1930 | (origin | |
1931 | (method url-fetch) | |
1932 | (uri (pypi-uri "Pykka" version)) | |
1933 | (sha256 | |
1934 | (base32 | |
1935 | "049w3r0mdnnw7xv19jiq7rvls9k7xs73x05b4qs5d6z4vvmgyiz8")))) | |
1936 | (build-system python-build-system) | |
1937 | (native-inputs | |
1938 | `(("python-mock" ,python-mock) | |
1939 | ("python-nose" ,python-nose) | |
1940 | ("python-gevent" ,python-gevent) | |
1941 | ("python-eventlet" ,python-eventlet))) | |
1942 | (home-page "https://www.pykka.org/") | |
1943 | (synopsis "Pykka is a Python implementation of the actor model") | |
1944 | (description | |
1945 | "Pykka is a Python implementation of the actor model. | |
1946 | The actor model introduces some simple rules to control the sharing | |
1947 | of state and cooperation between execution units, which makes it | |
1948 | easier to build concurrent applications.") | |
1949 | (license license:asl2.0))) | |
1950 | ||
1951 | (define-public python2-pykka | |
1952 | (package-with-python2 python-pykka)) | |
1953 | ||
ec5dbb5c DT |
1954 | (define-public python-itsdangerous |
1955 | (package | |
1956 | (name "python-itsdangerous") | |
1957 | (version "0.24") | |
1958 | (source | |
1959 | (origin | |
1960 | (method url-fetch) | |
1961 | (uri (string-append | |
1962 | "https://pypi.python.org/packages/source/i/itsdangerous/itsdangerous-" | |
1963 | version ".tar.gz")) | |
1964 | (sha256 | |
1965 | (base32 | |
1966 | "06856q6x675ly542ig0plbqcyab6ksfzijlyf1hzhgg3sgwgrcyb")))) | |
1967 | (build-system python-build-system) | |
7bf837fd | 1968 | (home-page "https://github.com/mitsuhiko/itsdangerous") |
ec5dbb5c DT |
1969 | (synopsis "Python library for passing data to/from untrusted environments") |
1970 | (description | |
1971 | "Itsdangerous provides various helpers to pass trusted data to untrusted | |
1972 | environments and back.") | |
f210e944 | 1973 | (license license:bsd-3))) |
ec5dbb5c DT |
1974 | |
1975 | (define-public python2-itsdangerous | |
f210e944 | 1976 | (package-with-python2 python-itsdangerous)) |
5731cae3 | 1977 | |
8d12be1e RW |
1978 | (define-public python-pyyaml |
1979 | (package | |
1980 | (name "python-pyyaml") | |
bf5e4bc4 | 1981 | (version "3.12") |
8d12be1e RW |
1982 | (source |
1983 | (origin | |
1984 | (method url-fetch) | |
bf5e4bc4 | 1985 | (uri (pypi-uri "PyYAML" version)) |
8d12be1e RW |
1986 | (sha256 |
1987 | (base32 | |
bf5e4bc4 | 1988 | "1aqjl8dk9amd4zr99n8v2qxzgmr2hdvqfma4zh7a41rj6336c9sr")))) |
8d12be1e RW |
1989 | (build-system python-build-system) |
1990 | (inputs | |
1991 | `(("libyaml" ,libyaml))) | |
8d12be1e RW |
1992 | (home-page "http://pyyaml.org/wiki/PyYAML") |
1993 | (synopsis "YAML parser and emitter for Python") | |
1994 | (description | |
1995 | "PyYAML is a YAML parser and emitter for Python. PyYAML features a | |
1996 | complete YAML 1.1 parser, Unicode support, pickle support, capable extension | |
1997 | API, and sensible error messages. PyYAML supports standard YAML tags and | |
1998 | provides Python-specific tags that allow to represent an arbitrary Python | |
1999 | object.") | |
2000 | (license license:expat))) | |
2001 | ||
2002 | (define-public python2-pyyaml | |
2003 | (package-with-python2 python-pyyaml)) | |
2004 | ||
5731cae3 DT |
2005 | (define-public python-virtualenv |
2006 | (package | |
2007 | (name "python-virtualenv") | |
58d04dba | 2008 | (version "15.0.3") |
5731cae3 DT |
2009 | (source |
2010 | (origin | |
2011 | (method url-fetch) | |
17804240 | 2012 | (uri (pypi-uri "virtualenv" version)) |
5731cae3 DT |
2013 | (sha256 |
2014 | (base32 | |
58d04dba | 2015 | "07cbajzk8l05k5zhlw0b9wbf2is65bl9v6zrn2a0iyn57w6pd73d")))) |
5731cae3 | 2016 | (build-system python-build-system) |
17804240 EF |
2017 | (arguments |
2018 | `(#:phases | |
2019 | (modify-phases %standard-phases | |
58d04dba RW |
2020 | (replace 'check |
2021 | (lambda _ | |
2022 | ;; Disable failing test. See upstream bug report | |
2023 | ;; https://github.com/pypa/virtualenv/issues/957 | |
2024 | (substitute* "tests/test_virtualenv.py" | |
2025 | (("skipif.*") "skipif(True, reason=\"Guix\")\n")) | |
2026 | (zero? (system* "py.test"))))))) | |
e7881f3d | 2027 | (native-inputs |
f3b98f4f | 2028 | `(("python-mock" ,python-mock) |
17804240 | 2029 | ("python-pytest" ,python-pytest))) |
5731cae3 DT |
2030 | (home-page "https://virtualenv.pypa.io/") |
2031 | (synopsis "Virtual Python environment builder") | |
2032 | (description | |
2033 | "Virtualenv is a tool to create isolated Python environments.") | |
bd3fa666 | 2034 | (license license:expat))) |
5731cae3 DT |
2035 | |
2036 | (define-public python2-virtualenv | |
2037 | (package-with-python2 python-virtualenv)) | |
8176d4d5 DT |
2038 | |
2039 | (define-public python-markupsafe | |
2040 | (package | |
2041 | (name "python-markupsafe") | |
2042 | (version "0.23") | |
2043 | (source | |
2044 | (origin | |
2045 | (method url-fetch) | |
2046 | (uri (string-append | |
2047 | "https://pypi.python.org/packages/source/M/MarkupSafe/MarkupSafe-" | |
2048 | version ".tar.gz")) | |
2049 | (sha256 | |
2050 | (base32 | |
2051 | "1hvip33wva3fnmvfp9x5klqri7hpl1hkgqmjbss18nmrb7zimv54")))) | |
2052 | (build-system python-build-system) | |
7bf837fd | 2053 | (home-page "https://github.com/mitsuhiko/markupsafe") |
8176d4d5 DT |
2054 | (synopsis "XML/HTML/XHTML markup safe string implementation for Python") |
2055 | (description | |
2056 | "Markupsafe provides an XML/HTML/XHTML markup safe string implementation | |
2057 | for Python.") | |
3f641af0 | 2058 | (license license:bsd-3))) |
8176d4d5 DT |
2059 | |
2060 | (define-public python2-markupsafe | |
2061 | (package-with-python2 python-markupsafe)) | |
fe34f0d1 DT |
2062 | |
2063 | (define-public python-jinja2 | |
2064 | (package | |
2065 | (name "python-jinja2") | |
bac5fd21 | 2066 | (version "2.9.6") |
fe34f0d1 DT |
2067 | (source |
2068 | (origin | |
2069 | (method url-fetch) | |
e98149b3 | 2070 | (uri (pypi-uri "Jinja2" version)) |
fe34f0d1 DT |
2071 | (sha256 |
2072 | (base32 | |
bac5fd21 | 2073 | "1zzrkywhziqffrzks14kzixz7nd4yh2vc0fb04a68vfd2ai03anx")))) |
fe34f0d1 | 2074 | (build-system python-build-system) |
bac5fd21 RW |
2075 | (arguments |
2076 | `(#:phases | |
2077 | (modify-phases %standard-phases | |
2078 | ;; These files cannot be built with Python < 3.6. See | |
2079 | ;; https://github.com/pallets/jinja/issues/655 | |
2080 | ;; FIXME: Remove this when the "python" package is upgraded. | |
2081 | (add-after 'unpack 'delete-incompatible-files | |
2082 | (lambda _ | |
2083 | (for-each delete-file | |
2084 | '("jinja2/asyncsupport.py" | |
2085 | "jinja2/asyncfilters.py")) | |
2086 | #t))))) | |
f22efa01 | 2087 | (propagated-inputs |
f3b98f4f | 2088 | `(("python-markupsafe" ,python-markupsafe))) |
fe34f0d1 DT |
2089 | (home-page "http://jinja.pocoo.org/") |
2090 | (synopsis "Python template engine") | |
2091 | (description | |
2092 | "Jinja2 is a small but fast and easy to use stand-alone template engine | |
2093 | written in pure Python.") | |
3f641af0 | 2094 | (license license:bsd-3))) |
fe34f0d1 DT |
2095 | |
2096 | (define-public python2-jinja2 | |
2097 | (package-with-python2 python-jinja2)) | |
3580ab8b | 2098 | |
f7d17ac7 EE |
2099 | (define-public python-pystache |
2100 | (package | |
2101 | (name "python-pystache") | |
2102 | (version "0.5.4") | |
2103 | (source (origin | |
2104 | (method url-fetch) | |
2105 | (uri (pypi-uri "pystache" version)) | |
2106 | (sha256 | |
2107 | (base32 | |
2108 | "0nmqsfmiw4arjxqkmf9z66ml950pcdjk6aq4gin4sywmzdjw5fzp")))) | |
2109 | (build-system python-build-system) | |
8bd5164b MB |
2110 | (arguments |
2111 | '(#:tests? #f)) ; FIXME: Python 3 tests are failing. | |
f7d17ac7 EE |
2112 | (home-page "http://defunkt.io/pystache/") |
2113 | (synopsis "Python logic-less template engine") | |
2114 | (description | |
2115 | "Pystache is a Python implementation of the framework agnostic, | |
2116 | logic-free templating system Mustache.") | |
8bd5164b MB |
2117 | (license license:expat) |
2118 | (properties `((python2-variant . ,(delay python2-pystache)))))) | |
f7d17ac7 EE |
2119 | |
2120 | (define-public python2-pystache | |
8bd5164b MB |
2121 | (package (inherit (package-with-python2 |
2122 | (strip-python2-variant python-pystache))) | |
2123 | (arguments | |
2124 | `(#:python ,python-2 | |
2125 | #:phases | |
2126 | (modify-phases %standard-phases | |
2127 | (replace 'check | |
2128 | (lambda _ | |
2129 | (zero? (system* "python" "test_pystache.py"))))))))) | |
f7d17ac7 | 2130 | |
1285119b RW |
2131 | (define-public python-joblib |
2132 | (package | |
2133 | (name "python-joblib") | |
f34ef331 | 2134 | (version "0.10.3") |
1285119b RW |
2135 | (source (origin |
2136 | (method url-fetch) | |
f34ef331 | 2137 | (uri (pypi-uri "joblib" version)) |
1285119b RW |
2138 | (sha256 |
2139 | (base32 | |
6aa5f1ca HG |
2140 | "0787k919zlfmgymprz5bzv0v1df5bbirlf3awrghmjgvkrd9dci9")) |
2141 | (modules '((guix build utils))) | |
2142 | (snippet | |
2143 | '(begin | |
2144 | ;; Remove pre-compiled .pyc files from source. | |
2145 | (for-each delete-file-recursively | |
2146 | (find-files "." "__pycache__" #:directories? #t)) | |
2147 | (for-each delete-file (find-files "." "\\.pyc$")) | |
2148 | #t)))) | |
1285119b | 2149 | (build-system python-build-system) |
a8dd960a RW |
2150 | (arguments |
2151 | `(#:phases | |
2152 | (modify-phases %standard-phases | |
2153 | (add-before 'check 'disable-failing-tests | |
2154 | (lambda _ | |
2155 | ;; This numpydoc tests fails for unknown reasons | |
2156 | (delete-file "doc/sphinxext/numpydoc/tests/test_docscrape.py") | |
2157 | ;; This numpydoc test depends on matplotlib, which is not a | |
2158 | ;; required input. | |
2159 | (delete-file "doc/sphinxext/numpydoc/tests/test_plot_directive.py") | |
2160 | ;; These tests fail to execute sys.executable | |
2161 | (substitute* "joblib/test/test_parallel.py" | |
2162 | (("import nose" line) | |
2163 | (string-append "from nose.plugins.skip import SkipTest\n" line)) | |
2164 | (("def test_nested_parallel_warnings" line) | |
2165 | (string-append "@SkipTest\n" line)) | |
2166 | (("def test_parallel_with_interactively_defined_functions" line) | |
2167 | (string-append "@SkipTest\n" line))) | |
2168 | #t))))) | |
f052ec9a | 2169 | ;; Provide nose to enable tests command |
1285119b | 2170 | (native-inputs |
f3b98f4f | 2171 | `(("python-nose" ,python-nose) |
f34ef331 RW |
2172 | ("python-sphinx" ,python-sphinx) |
2173 | ("python-docutils" ,python-docutils) | |
2174 | ("python-numpydoc" ,python-numpydoc))) | |
1285119b RW |
2175 | (home-page "http://pythonhosted.org/joblib/") |
2176 | (synopsis "Using Python functions as pipeline jobs") | |
2177 | (description | |
2178 | "Joblib is a set of tools to provide lightweight pipelining in Python. | |
2179 | In particular, joblib offers: transparent disk-caching of the output values | |
2180 | and lazy re-evaluation (memoize pattern), easy simple parallel computing | |
2181 | logging and tracing of the execution.") | |
3f641af0 | 2182 | (license license:bsd-3))) |
1285119b RW |
2183 | |
2184 | (define-public python2-joblib | |
2185 | (package-with-python2 python-joblib)) | |
2186 | ||
3580ab8b DT |
2187 | (define-public python-docutils |
2188 | (package | |
2189 | (name "python-docutils") | |
db4411b4 | 2190 | (version "0.14") |
3580ab8b DT |
2191 | (source |
2192 | (origin | |
2193 | (method url-fetch) | |
00e0ca7c | 2194 | (uri (pypi-uri "docutils" version)) |
3580ab8b DT |
2195 | (sha256 |
2196 | (base32 | |
db4411b4 | 2197 | "0x22fs3pdmr42kvz6c654756wja305qv6cx1zbhwlagvxgr4xrji")))) |
3580ab8b | 2198 | (build-system python-build-system) |
3580ab8b DT |
2199 | (arguments |
2200 | '(#:tests? #f)) ; no setup.py test command | |
2201 | (home-page "http://docutils.sourceforge.net/") | |
2202 | (synopsis "Python Documentation Utilities") | |
2203 | (description | |
2204 | "Docutils is a modular system for processing documentation into useful | |
2205 | formats, such as HTML, XML, and LaTeX. For input Docutils supports | |
2206 | reStructuredText.") | |
2207 | ;; Most of the source code is public domain, but some source files are | |
2208 | ;; licensed under the PFSL, BSD 2-clause, and GPLv3+ licenses. | |
3f641af0 | 2209 | (license (list license:public-domain license:psfl license:bsd-2 license:gpl3+)))) |
3580ab8b DT |
2210 | |
2211 | (define-public python2-docutils | |
2212 | (package-with-python2 python-docutils)) | |
fb35b7c0 DT |
2213 | |
2214 | (define-public python-pygments | |
2215 | (package | |
2216 | (name "python-pygments") | |
00c78882 | 2217 | (version "2.2.0") |
fb35b7c0 DT |
2218 | (source |
2219 | (origin | |
2220 | (method url-fetch) | |
9f442285 | 2221 | (uri (pypi-uri "Pygments" version)) |
fb35b7c0 DT |
2222 | (sha256 |
2223 | (base32 | |
00c78882 | 2224 | "1k78qdvir1yb1c634nkv6rbga8wv4289xarghmsbbvzhvr311bnv")))) |
fb35b7c0 | 2225 | (build-system python-build-system) |
995cb99e MB |
2226 | (arguments |
2227 | ;; FIXME: Tests require sphinx, which depends on this. | |
2228 | '(#:tests? #f)) | |
fb35b7c0 DT |
2229 | (home-page "http://pygments.org/") |
2230 | (synopsis "Syntax highlighting") | |
2231 | (description | |
2232 | "Pygments is a syntax highlighting package written in Python.") | |
3f641af0 | 2233 | (license license:bsd-2))) |
fb35b7c0 DT |
2234 | |
2235 | (define-public python2-pygments | |
2236 | (package-with-python2 python-pygments)) | |
9dd6078d | 2237 | |
5f94ec91 RW |
2238 | (define-public python-sphinxcontrib-websupport |
2239 | (package | |
2240 | (name "python-sphinxcontrib-websupport") | |
2241 | (version "1.0.1") | |
2242 | (source (origin | |
2243 | (method url-fetch) | |
2244 | (uri (pypi-uri "sphinxcontrib-websupport" version)) | |
2245 | (sha256 | |
2246 | (base32 | |
2247 | "1f9f0wjpi9nhikbyaz6d19s7qvzdf1nq2g5dsh640fma4q9rd1bs")))) | |
2248 | (build-system python-build-system) | |
2249 | (propagated-inputs | |
2250 | `(("python-mock" ,python-mock) | |
2251 | ("python-pytest" ,python-pytest) | |
2252 | ("python-xapian-bindings" ,python-xapian-bindings))) | |
2253 | ;; Needed for running the test suite | |
2254 | (native-inputs | |
2255 | `(("python-six" ,python-six) | |
2256 | ("python-jinja2" ,python-jinja2) | |
2257 | ("python-docutils" ,python-docutils) | |
2258 | ("python-sphinx" ,python-sphinx) | |
2259 | ("python-sqlalchemy" ,python-sqlalchemy) | |
2260 | ("python-whoosh" ,python-whoosh))) | |
2261 | (home-page "http://sphinx-doc.org/") | |
2262 | (synopsis "Sphinx API for web applications") | |
2263 | (description "This package provides a Python API to easily integrate | |
2264 | Sphinx documentation into your web application. It provides tools to | |
2265 | integrate Sphinx documents in web templates and to handle searches.") | |
2266 | (license license:bsd-3))) | |
2267 | ||
9dd6078d DT |
2268 | (define-public python-sphinx |
2269 | (package | |
2270 | (name "python-sphinx") | |
c227458a | 2271 | (version "1.5.1") |
9dd6078d DT |
2272 | (source |
2273 | (origin | |
2274 | (method url-fetch) | |
9a8acd00 | 2275 | (uri (pypi-uri "Sphinx" version)) |
9dd6078d DT |
2276 | (sha256 |
2277 | (base32 | |
c227458a | 2278 | "1i8p9idnli4gr0y4x67yakbdk5w6a0xjzhrg6bg51y9d1fi7fslf")))) |
9dd6078d | 2279 | (build-system python-build-system) |
03cb5f9e | 2280 | (arguments |
c227458a DM |
2281 | `(#:phases |
2282 | (modify-phases %standard-phases | |
2283 | (replace 'check | |
2284 | (lambda _ | |
2285 | ;; Requires Internet access. | |
2286 | (delete-file "tests/test_build_linkcheck.py") | |
2287 | (zero? (system* "make" "test"))))))) | |
f22efa01 | 2288 | (propagated-inputs |
9a8acd00 DM |
2289 | `(("python-imagesize" ,python-imagesize) |
2290 | ("python-sphinx-alabaster-theme" | |
2291 | ,python-sphinx-alabaster-theme) | |
2292 | ("python-babel" ,python-babel) | |
2293 | ("python-snowballstemmer" ,python-snowballstemmer) | |
9dd6078d | 2294 | ("python-docutils" ,python-docutils) |
9a8acd00 DM |
2295 | ("python-jinja2" ,python-jinja2) |
2296 | ("python-pygments" ,python-pygments) | |
a10b9810 | 2297 | ("python-requests" ,python-requests) |
9a8acd00 | 2298 | ("python-six" ,python-six))) |
c227458a DM |
2299 | (native-inputs |
2300 | `(("graphviz" ,graphviz) | |
2301 | ("python-html5lib" ,python-html5lib) | |
2302 | ("python-mock" ,python-mock) | |
a10b9810 | 2303 | ("python-nose" ,python-nose))) |
9dd6078d DT |
2304 | (home-page "http://sphinx-doc.org/") |
2305 | (synopsis "Python documentation generator") | |
2306 | (description "Sphinx is a tool that makes it easy to create documentation | |
2307 | for Python projects or other documents consisting of multiple reStructuredText | |
2308 | sources.") | |
9a8acd00 DM |
2309 | (license license:bsd-3) |
2310 | (properties `((python2-variant . ,(delay python2-sphinx)))))) | |
9dd6078d | 2311 | |
e7304ab1 RW |
2312 | (define-public python-sphinx-1.6 |
2313 | (package (inherit python-sphinx) | |
2314 | (name "python-sphinx") | |
2315 | (version "1.6.3") | |
2316 | (source (origin | |
2317 | (method url-fetch) | |
2318 | (uri (pypi-uri "Sphinx" version)) | |
2319 | (sha256 | |
2320 | (base32 | |
2321 | "1rj6f3i8hmrx2qlkshi5kp5xcy98dlynwlyl05yvflj5f66dp2xg")))) | |
2322 | (arguments | |
2323 | `(#:phases | |
2324 | (modify-phases %standard-phases | |
2325 | (replace 'check | |
2326 | (lambda _ | |
2327 | ;; Requires Internet access. | |
2328 | (delete-file "tests/test_build_linkcheck.py") | |
2329 | (substitute* "tests/test_build_latex.py" | |
2330 | (("@pytest.mark.sphinx\\('latex', testroot='images'\\)") | |
2331 | "@pytest.mark.skip()")) | |
2332 | (zero? (system* "make" "test"))))))) | |
2333 | (propagated-inputs | |
2334 | `(("python-sphinxcontrib-websupport" ,python-sphinxcontrib-websupport) | |
2335 | ,@(package-propagated-inputs python-sphinx))) | |
2336 | (native-inputs | |
2337 | `(("python-pytest" ,python-pytest-3.0) | |
2338 | ("imagemagick" ,imagemagick) ; for "convert" | |
2339 | ,@(package-native-inputs python-sphinx))) | |
2340 | (properties '()))) | |
2341 | ||
3061b331 MFM |
2342 | (define-public python-sphinx-1.5.3 |
2343 | (package | |
2344 | (inherit python-sphinx) | |
2345 | (name "python-sphinx") | |
2346 | (version "1.5.3") | |
2347 | (source | |
2348 | (origin | |
2349 | (method url-fetch) | |
2350 | (uri (pypi-uri "Sphinx" version)) | |
2351 | (sha256 | |
2352 | (base32 | |
2353 | "0kw1axswbvaavr8ggyf4qr6hnisnrzlbkkcdada69vk1x9xjassg")))) | |
2354 | (native-inputs | |
23b9168d | 2355 | `(("python-pytest" ,python-pytest-3.0) |
3061b331 MFM |
2356 | ,@(package-native-inputs python-sphinx))))) |
2357 | ||
9dd6078d | 2358 | (define-public python2-sphinx |
9a8acd00 DM |
2359 | (let ((base (package-with-python2 (strip-python2-variant python-sphinx)))) |
2360 | (package | |
2361 | (inherit base) | |
2362 | (native-inputs `(("python2-mock" ,python2-mock) | |
c227458a | 2363 | ("python2-enum34" ,python2-enum34) |
9a8acd00 DM |
2364 | ,@(package-native-inputs base))) |
2365 | (propagated-inputs `(("python2-pytz" ,python2-pytz) | |
2366 | ,@(package-propagated-inputs base)))))) | |
6888830b | 2367 | |
ad320b20 RW |
2368 | (define-public python-sphinx-rtd-theme |
2369 | (package | |
2370 | (name "python-sphinx-rtd-theme") | |
af842d45 | 2371 | (version "0.2.4") |
ad320b20 RW |
2372 | (source |
2373 | (origin | |
2374 | (method url-fetch) | |
af842d45 | 2375 | (uri (pypi-uri "sphinx_rtd_theme" version)) |
ad320b20 RW |
2376 | (sha256 |
2377 | (base32 | |
af842d45 | 2378 | "05rlhjzdyapr2w74jjs7mrm8hi69qskcr5vya9f9drpsys7lpxrd")))) |
ad320b20 | 2379 | (build-system python-build-system) |
9893cff3 | 2380 | (arguments '(#:tests? #f)) ; No tests. |
9d3a15b4 LF |
2381 | (propagated-inputs |
2382 | `(("python-sphinx" ,python-sphinx))) | |
ad320b20 RW |
2383 | (home-page "https://github.com/snide/sphinx_rtd_theme/") |
2384 | (synopsis "ReadTheDocs.org theme for Sphinx") | |
2385 | (description "A theme for Sphinx used by ReadTheDocs.org.") | |
bd3fa666 | 2386 | (license license:expat))) |
ad320b20 RW |
2387 | |
2388 | (define-public python2-sphinx-rtd-theme | |
2389 | (package-with-python2 python-sphinx-rtd-theme)) | |
2390 | ||
d7eb680d LF |
2391 | (define-public python-guzzle-sphinx-theme |
2392 | (package | |
2393 | (name "python-guzzle-sphinx-theme") | |
2394 | (version "0.7.11") | |
2395 | (source | |
2396 | (origin | |
2397 | (method url-fetch) | |
2398 | (uri (pypi-uri "guzzle_sphinx_theme" version)) | |
2399 | (sha256 | |
2400 | (base32 | |
2401 | "1rnkzrrsbnifn3vsb4pfaia3nlvgvw6ndpxp7lzjrh23qcwid34v")))) | |
2402 | (build-system python-build-system) | |
2403 | (propagated-inputs | |
2404 | `(("python-sphinx" ,python-sphinx))) | |
2405 | (home-page "https://github.com/guzzle/guzzle_sphinx_theme") | |
2406 | (synopsis "Sphinx theme used by Guzzle") | |
2407 | (description "This package provides guzzle_sphinx_theme, a theme for the | |
2408 | Sphinx documentation system, used by @uref{http://docs.guzzlephp.org, Guzzle} | |
2409 | and several other projects.") | |
2410 | (license license:expat))) | |
2411 | ||
2412 | (define-public python2-guzzle-sphinx-theme | |
2413 | (package-with-python2 python-guzzle-sphinx-theme)) | |
2414 | ||
fe94cf0c HG |
2415 | (define-public python-rst.linker |
2416 | (package | |
2417 | (name "python-rst.linker") | |
2418 | (version "1.7") | |
2419 | (source | |
2420 | (origin | |
2421 | (method url-fetch) | |
2422 | (uri (pypi-uri "rst.linker" version)) | |
2423 | (sha256 | |
2424 | (base32 | |
2425 | "0bh4lnj2p1nh0wf5pgxgfbrp27xhb1rinahkb5j7s3qprq6qn0sr")))) | |
2426 | (build-system python-build-system) | |
2427 | (propagated-inputs | |
22d7360b | 2428 | `(("python-dateutil" ,python-dateutil) |
fe94cf0c HG |
2429 | ("python-six" ,python-six))) |
2430 | (native-inputs | |
2431 | `(("python-setuptools-scm" ,python-setuptools-scm))) | |
2432 | ;; Test would require path.py, which would introduce a cyclic dependence. | |
2433 | (arguments `(#:tests? #f)) | |
2434 | ;; Note: As of version 1.7 the documentation is not worth building. | |
2435 | (home-page "https://github.com/jaraco/rst.linker") | |
2436 | (synopsis "Sphinx plugin to add links and timestamps") | |
2437 | (description "rst.linker allows to automatically replace text by a | |
2438 | reStructuredText external reference or timestamps. It's primary purpose is to | |
2439 | augment the changelog, but it can be used for other documents, too.") | |
2440 | (license license:expat))) | |
2441 | ||
2442 | (define-public python2-rst.linker | |
2443 | (package-with-python2 python-rst.linker)) | |
2444 | ||
f4de5b3b CAW |
2445 | (define-public python-feedgenerator |
2446 | (package | |
2447 | (name "python-feedgenerator") | |
d5c183d1 | 2448 | (version "1.9") |
f4de5b3b | 2449 | (source |
f4de5b3b | 2450 | (origin |
f0412aa2 EF |
2451 | (method url-fetch) |
2452 | (uri (pypi-uri "feedgenerator" version)) | |
f4de5b3b CAW |
2453 | (sha256 |
2454 | (base32 | |
d5c183d1 | 2455 | "01mirwkm7xfx539hmvj7g9da1j51gw5lsx74dr0glizskjm5vq2s")) |
7c88bcf4 HG |
2456 | (modules '((guix build utils))) |
2457 | (snippet | |
2458 | '(begin | |
2459 | ;; Remove pre-compiled .pyc files from source. | |
2460 | (for-each delete-file-recursively | |
2461 | (find-files "." "__pycache__" #:directories? #t)) | |
2462 | (for-each delete-file (find-files "." "\\.pyc$")) | |
2463 | #t)))) | |
f4de5b3b | 2464 | (build-system python-build-system) |
dae73d9b | 2465 | (propagated-inputs |
f3b98f4f | 2466 | `(("python-pytz" ,python-pytz) |
f4de5b3b | 2467 | ("python-six" ,python-six))) |
f0412aa2 | 2468 | (home-page "https://github.com/getpelican/feedgenerator") |
f4de5b3b CAW |
2469 | (synopsis |
2470 | "Standalone version of Django's Atom/RSS feed generator") | |
2471 | (description | |
2472 | "Feedgenerator-py3k is a standalone version of Django's feedgenerator, | |
2473 | which can produce feeds in RSS 2.0, RSS 0.91, and Atom formats.") | |
3f641af0 | 2474 | (license license:bsd-3))) |
f4de5b3b CAW |
2475 | |
2476 | (define-public python2-feedgenerator | |
2477 | (package-with-python2 python-feedgenerator)) | |
2478 | ||
59ad30e3 CAW |
2479 | (define-public python-blinker |
2480 | (package | |
2481 | (name "python-blinker") | |
7fb9ff4d | 2482 | (version "1.4") |
59ad30e3 CAW |
2483 | (source |
2484 | (origin | |
2485 | (method url-fetch) | |
7fb9ff4d | 2486 | (uri (pypi-uri "blinker" version)) |
59ad30e3 CAW |
2487 | (sha256 |
2488 | (base32 | |
7fb9ff4d | 2489 | "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7")))) |
59ad30e3 | 2490 | (build-system python-build-system) |
59ad30e3 CAW |
2491 | (home-page "http://pythonhosted.org/blinker/") |
2492 | (synopsis "Fast, simple object-to-object and broadcast signaling") | |
2493 | (description | |
2494 | "Blinker provides a fast dispatching system that allows any number of | |
2495 | interested parties to subscribe to events, or \"signals\".") | |
2496 | (license license:expat))) | |
2497 | ||
2498 | (define-public python2-blinker | |
2499 | (package-with-python2 python-blinker)) | |
2500 | ||
b8050e71 CAW |
2501 | (define-public pelican |
2502 | (package | |
2503 | (name "pelican") | |
11f97c27 | 2504 | (version "3.6.3") |
b8050e71 CAW |
2505 | (source |
2506 | (origin | |
2507 | (method url-fetch) | |
11f97c27 | 2508 | (uri (pypi-uri "pelican" version)) |
b8050e71 CAW |
2509 | (sha256 |
2510 | (base32 | |
11f97c27 | 2511 | "1hn94rb4q3zmcq16in055xikal4dba5hfx3zznq7warllcgc9f8k")))) |
b8050e71 | 2512 | (build-system python-build-system) |
f22efa01 | 2513 | (propagated-inputs |
b8050e71 CAW |
2514 | `(("python-feedgenerator" ,python-feedgenerator) |
2515 | ("python-jinja2" ,python-jinja2) | |
2516 | ("python-pygments" ,python-pygments) | |
2517 | ("python-docutils" ,python-docutils) | |
2518 | ("python-pytz" ,python-pytz) | |
2519 | ("python-blinker" ,python-blinker) | |
2520 | ("python-unidecode" ,python-unidecode) | |
2521 | ("python-six" ,python-six) | |
b438d7cf BS |
2522 | ("python-dateutil" ,python-dateutil) |
2523 | ("python-markdown" ,python-markdown))) | |
b8050e71 CAW |
2524 | (home-page "http://getpelican.com/") |
2525 | (arguments | |
2526 | `(;; XXX Requires a lot more packages to do unit tests :P | |
2527 | #:tests? #f | |
2528 | #:phases (modify-phases %standard-phases | |
2529 | (add-before | |
2530 | 'install 'adjust-requires | |
2531 | ;; Since feedgenerator is installed from git, it doesn't | |
2532 | ;; conform to the version requirements. | |
2533 | ;; | |
2534 | ;; We *do have* "feedgenerator >= 1.6", but strip off the | |
2535 | ;; version requirement so setuptools doesn't get confused. | |
2536 | (lambda _ | |
2537 | (substitute* "setup.py" | |
2538 | (("['\"]feedgenerator.*?['\"]") | |
2539 | "'feedgenerator'"))))))) | |
2540 | (synopsis "Python-based static site publishing system") | |
2541 | (description | |
2542 | "Pelican is a tool to generate a static blog from reStructuredText, | |
2543 | Markdown input files, and more. Pelican uses Jinja2 for templating | |
2544 | and is very extensible.") | |
3f641af0 | 2545 | (license license:agpl3+))) |
b8050e71 | 2546 | |
12f8f9bb RW |
2547 | (define-public python-scikit-image |
2548 | (package | |
2549 | (name "python-scikit-image") | |
2550 | (version "0.11.3") | |
2551 | (source | |
2552 | (origin | |
2553 | (method url-fetch) | |
2554 | (uri (string-append | |
2555 | "https://pypi.python.org/packages/source/s/scikit-image/scikit-image-" | |
2556 | version ".tar.gz")) | |
2557 | (sha256 | |
2558 | (base32 "0jz416fqvpahqyffw8plmszzfj669w8wvf3y9clnr5lr6a7md3kn")))) | |
2559 | (build-system python-build-system) | |
9026e689 MB |
2560 | (arguments |
2561 | ;; TODO: Some tests require running X11 server. Disable them? | |
2562 | '(#:tests? #f)) | |
b83e2333 | 2563 | ;; See DEPENDS.txt for the list of build and run time requiremnts |
12f8f9bb RW |
2564 | (propagated-inputs |
2565 | `(("python-matplotlib" ,python-matplotlib) | |
2566 | ("python-networkx" ,python-networkx) | |
12f8f9bb | 2567 | ("python-scipy" ,python-scipy) |
12f8f9bb RW |
2568 | ("python-pillow" ,python-pillow))) |
2569 | (native-inputs | |
b83e2333 HG |
2570 | `(("python-numpy" ,python-numpy) |
2571 | ("python-cython" ,python-cython) | |
2572 | ("python-six" ,python-six))) | |
12f8f9bb RW |
2573 | (home-page "http://scikit-image.org/") |
2574 | (synopsis "Image processing in Python") | |
2575 | (description | |
e881752c | 2576 | "Scikit-image is a collection of algorithms for image processing.") |
12733594 | 2577 | (license license:bsd-3))) |
12f8f9bb RW |
2578 | |
2579 | (define-public python2-scikit-image | |
12733594 | 2580 | (package-with-python2 python-scikit-image)) |
12f8f9bb | 2581 | |
6888830b FB |
2582 | (define-public python-cython |
2583 | (package | |
2584 | (name "python-cython") | |
58816c3d | 2585 | (version "0.27") |
6888830b FB |
2586 | (source |
2587 | (origin | |
2588 | (method url-fetch) | |
56918e26 | 2589 | (uri (pypi-uri "Cython" version)) |
6888830b FB |
2590 | (sha256 |
2591 | (base32 | |
58816c3d | 2592 | "02y0pp1nx77b8s1mpxc6da2dccl6wd31pp4ksi9via479qcvacmr")))) |
6888830b FB |
2593 | (build-system python-build-system) |
2594 | ;; we need the full python package and not just the python-wrapper | |
2595 | ;; because we need libpython3.3m.so | |
2596 | (inputs | |
2597 | `(("python" ,python))) | |
2598 | (arguments | |
2599 | `(#:phases | |
b92f651b EF |
2600 | (modify-phases %standard-phases |
2601 | (add-before 'check 'set-HOME | |
2602 | ;; some tests require access to "$HOME/.cython" | |
e3b861ce | 2603 | (lambda _ (setenv "HOME" "/tmp") #t)) |
b92f651b EF |
2604 | (replace 'check |
2605 | (lambda _ (zero? (system* "python" "runtests.py" "-vv"))))))) | |
6888830b FB |
2606 | (home-page "http://cython.org/") |
2607 | (synopsis "C extensions for Python") | |
2608 | (description "Cython is an optimising static compiler for both the Python | |
2609 | programming language and the extended Cython programming language. It makes | |
2610 | writing C extensions for Python as easy as Python itself.") | |
3f641af0 | 2611 | (license license:asl2.0) |
48b311b1 | 2612 | (properties `((python2-variant . ,(delay python2-cython)))))) |
6888830b FB |
2613 | |
2614 | (define-public python2-cython | |
48b311b1 LC |
2615 | (package (inherit (package-with-python2 |
2616 | (strip-python2-variant python-cython))) | |
6888830b FB |
2617 | (name "python2-cython") |
2618 | (inputs | |
2619 | `(("python-2" ,python-2))))) ; this is not automatically changed | |
0da98533 | 2620 | |
ee5fb7ee AV |
2621 | ;; The RPython toolchain currently does not support Python 3. |
2622 | (define-public python2-rpython | |
2623 | (package | |
2624 | (name "python2-rpython") | |
ce1ac8ee | 2625 | (version "0.2.1") |
ee5fb7ee AV |
2626 | (source |
2627 | (origin | |
2628 | (method url-fetch) | |
2629 | (uri (pypi-uri "rpython" version)) | |
2630 | (sha256 | |
2631 | (base32 | |
ce1ac8ee | 2632 | "02z9cvxf0y41dcvwnvf2zn0albhhw1drvjjbq27m6i1piw1k6fc0")))) |
ee5fb7ee AV |
2633 | (build-system python-build-system) |
2634 | (arguments `(#:python ,python-2)) | |
2635 | (native-inputs | |
f3b98f4f | 2636 | `(("python2-pytest" ,python2-pytest))) ; needed for running tests |
ee5fb7ee AV |
2637 | (home-page "https://rpython.readthedocs.org") |
2638 | (synopsis "Framework for implementing interpreters and virtual machines") | |
2639 | (description "RPython is a translation and support framework for | |
2640 | producing implementations of dynamic languages, emphasizing a clean separation | |
2641 | between language specification and implementation aspects.") | |
2642 | (license license:expat))) | |
2643 | ||
67a08f18 RW |
2644 | ;; NOTE: when upgrading numpy please make sure that python-pandas and |
2645 | ;; python-scipy still build, as these three packages are often used together. | |
7ccb71e0 | 2646 | (define-public python-numpy |
0da98533 | 2647 | (package |
7ccb71e0 | 2648 | (name "python-numpy") |
eaa1db1d | 2649 | (version "1.12.0") |
0da98533 FB |
2650 | (source |
2651 | (origin | |
2652 | (method url-fetch) | |
eaa1db1d RW |
2653 | (uri (string-append |
2654 | "https://github.com/numpy/numpy/archive/v" version ".tar.gz")) | |
2655 | (file-name (string-append name "-" version ".tar.gz")) | |
0da98533 FB |
2656 | (sha256 |
2657 | (base32 | |
eaa1db1d | 2658 | "025d4j4aakcp8w5i5diqh812cbbjgac7jszx1j56ivrbi1i8vv7d")))) |
0da98533 FB |
2659 | (build-system python-build-system) |
2660 | (inputs | |
328bb95d | 2661 | `(("openblas" ,openblas) |
cba256f8 | 2662 | ("lapack" ,lapack))) |
0da98533 | 2663 | (native-inputs |
eaa1db1d | 2664 | `(("python-cython" ,python-cython) |
7ccb71e0 | 2665 | ("python-nose" ,python-nose) |
2efabc55 | 2666 | ("gfortran" ,gfortran))) |
0da98533 FB |
2667 | (arguments |
2668 | `(#:phases | |
2efabc55 | 2669 | (modify-phases %standard-phases |
e144cbcf KH |
2670 | (add-before 'build 'configure-blas-lapack |
2671 | (lambda* (#:key inputs #:allow-other-keys) | |
2672 | (call-with-output-file "site.cfg" | |
2673 | (lambda (port) | |
2674 | (format port | |
2675 | "[openblas] | |
dbdfe515 RW |
2676 | libraries = openblas |
2677 | library_dirs = ~a/lib | |
2678 | include_dirs = ~a/include | |
cba256f8 | 2679 | |
2efabc55 HG |
2680 | # backslash-n to make emacs happy |
2681 | \n[lapack] | |
cba256f8 RW |
2682 | lapack_libs = lapack |
2683 | library_dirs = ~a/lib | |
2684 | include_dirs = ~a/include | |
2685 | " | |
e144cbcf KH |
2686 | (assoc-ref inputs "openblas") |
2687 | (assoc-ref inputs "openblas") | |
2688 | (assoc-ref inputs "lapack") | |
2689 | (assoc-ref inputs "lapack")))) | |
2690 | #t)) | |
2691 | (add-before 'build 'fix-executable-paths | |
2692 | (lambda* (#:key inputs #:allow-other-keys) | |
2693 | ;; Make /gnu/store/...-bash-.../bin/sh the default shell, | |
2694 | ;; instead of /bin/sh. | |
2695 | (substitute* "numpy/distutils/exec_command.py" | |
2696 | (("(os.environ.get\\('SHELL', ')(/bin/sh'\\))" match match-start match-end) | |
2697 | (string-append match-start (assoc-ref inputs "bash") match-end))) | |
2698 | ;; Use "gcc" executable, not "cc". | |
2699 | (substitute* "numpy/distutils/system_info.py" | |
2700 | (("c = distutils\\.ccompiler\\.new_compiler\\(\\)") | |
2701 | "c = distutils.ccompiler.new_compiler(); c.set_executables(compiler='gcc',compiler_so='gcc',linker_exe='gcc',linker_so='gcc -shared')")) | |
2702 | #t)) | |
2703 | ;; Tests can only be run after the library has been installed and not | |
2704 | ;; within the source directory. | |
2705 | (delete 'check) | |
2706 | (add-after 'install 'check | |
2707 | (lambda* (#:key outputs inputs #:allow-other-keys) | |
2708 | ;; Make installed package available for running the tests | |
2709 | (add-installed-pythonpath inputs outputs) | |
2710 | (with-directory-excursion "/tmp" | |
2711 | (zero? (system* "python" "-c" | |
2712 | "import numpy; numpy.test(verbose=2)")))))))) | |
0da98533 FB |
2713 | (home-page "http://www.numpy.org/") |
2714 | (synopsis "Fundamental package for scientific computing with Python") | |
2715 | (description "NumPy is the fundamental package for scientific computing | |
e881752c | 2716 | with Python. It contains among other things: a powerful N-dimensional array |
0da98533 FB |
2717 | object, sophisticated (broadcasting) functions, tools for integrating C/C++ |
2718 | and Fortran code, useful linear algebra, Fourier transform, and random number | |
2719 | capabilities.") | |
3f641af0 | 2720 | (license license:bsd-3))) |
0da98533 | 2721 | |
7ccb71e0 TD |
2722 | (define-public python2-numpy |
2723 | (package-with-python2 python-numpy)) | |
15bfe6d6 | 2724 | |
67a08f18 RW |
2725 | (define-public python-numpy-next |
2726 | (package (inherit python-numpy) | |
2727 | (name "python-numpy-next") | |
2728 | (version "1.13.1") | |
2729 | (source | |
2730 | (origin | |
2731 | (method url-fetch) | |
2732 | (uri (pypi-uri "numpy" version ".zip")) | |
2733 | (sha256 | |
2734 | (base32 | |
2735 | "1fsgkhh1vdkhmlz8vmdgxnj9n9yaanckxxzz9s0b4p08fqvjic69")))) | |
2736 | (native-inputs | |
2737 | `(("unzip" ,unzip) | |
2738 | ("python-cython" ,python-cython) | |
2739 | ("python-nose" ,python-nose) | |
2740 | ("gfortran" ,gfortran))))) | |
2741 | ||
2742 | (define-public python2-numpy-next | |
2743 | (package-with-python2 python-numpy-next)) | |
2744 | ||
a08d5a07 KH |
2745 | ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of |
2746 | ;; interest only for legacy code going back to NumPy's predecessor | |
2747 | ;; Numeric. | |
2748 | (define-public python2-numpy-1.8 | |
2749 | (package (inherit python2-numpy) | |
2750 | (version "1.8.2") | |
2751 | (source | |
2752 | (origin | |
2753 | (method url-fetch) | |
2754 | (uri (string-append | |
2755 | "https://github.com/numpy/numpy/archive/v" version ".tar.gz")) | |
2756 | (file-name (string-append "python2-numpy-" version ".tar.gz")) | |
2757 | (sha256 | |
2758 | (base32 | |
2759 | "0sc20gz1b17xnyrkp5frca3ql5qfalpv916hfg2kqxpwr6jg0f1g")))) | |
2760 | (arguments | |
2761 | (substitute-keyword-arguments (package-arguments python2-numpy) | |
2762 | ((#:phases phases) | |
2763 | `(modify-phases ,phases | |
2764 | (replace 'configure-blas-lapack | |
2765 | (lambda* (#:key inputs #:allow-other-keys) | |
2766 | (call-with-output-file "site.cfg" | |
2767 | (lambda (port) | |
2768 | (format port | |
2769 | "[openblas] | |
2770 | libraries = openblas,lapack | |
2771 | library_dirs = ~a/lib:~a/lib | |
2772 | include_dirs = ~a/include:~a/include | |
2773 | " | |
2774 | (assoc-ref inputs "openblas") | |
2775 | (assoc-ref inputs "lapack") | |
2776 | (assoc-ref inputs "openblas") | |
2777 | (assoc-ref inputs "lapack")))) | |
2778 | #t)))))) | |
2779 | (description "NumPy is the fundamental package for scientific computing | |
2780 | with Python. It contains among other things: a powerful N-dimensional array | |
2781 | object, sophisticated (broadcasting) functions, tools for integrating C/C++ | |
2782 | and Fortran code, useful linear algebra, Fourier transform, and random number | |
2783 | capabilities. Version 1.8 is the last one to contain the numpy.oldnumeric API | |
2784 | that includes the compatibility layer numpy.oldnumeric with NumPy's predecessor | |
2785 | Numeric.") | |
2786 | (license license:bsd-3))) | |
2787 | ||
460fccd4 | 2788 | (define-public python-munch |
2789 | (package | |
2790 | (name "python-munch") | |
2791 | (version "2.0.4") | |
2792 | (source | |
2793 | (origin | |
2794 | (method url-fetch) | |
2795 | (uri (pypi-uri "munch" version)) | |
2796 | (sha256 | |
2797 | (base32 | |
2798 | "1cmqg91xnqx8gvnh4pmp0bfl1dfcm65d5p9mg73zz8pkjhx6h80l")))) | |
2799 | (build-system python-build-system) | |
2800 | (home-page "https://github.com/Infinidat/munch") | |
2801 | (synopsis "Dot-accessible dictionary") | |
2802 | (description "Munch is a dot-accessible dictionary similar to JavaScript | |
2803 | objects.") | |
2804 | (license license:expat))) | |
2805 | ||
2806 | (define-public python2-munch | |
2807 | (package-with-python2 python-munch)) | |
2808 | ||
beed6abc RW |
2809 | (define-public python-colormath |
2810 | (package | |
2811 | (name "python-colormath") | |
2812 | (version "2.1.1") | |
2813 | (source | |
2814 | (origin | |
2815 | (method url-fetch) | |
2816 | (uri (pypi-uri "colormath" version)) | |
2817 | (sha256 | |
2818 | (base32 | |
2819 | "01wp5xwm0a89wdm1dc9rr1ij90idzdiiipxdj1yslhqzkhnjnfh0")))) | |
2820 | (build-system python-build-system) | |
2821 | (propagated-inputs | |
2822 | `(("python-networkx" ,python-networkx) | |
2823 | ("python-numpy" ,python-numpy))) | |
2824 | (home-page "https://github.com/gtaylor/python-colormath") | |
2825 | (synopsis "Color math and conversion library") | |
2826 | (description | |
2827 | "This is a Python library for color math and conversions.") | |
2828 | (license license:bsd-3))) | |
2829 | ||
2830 | (define-public python2-colormath | |
2831 | (package-with-python2 python-colormath)) | |
2832 | ||
4a7d2009 RW |
2833 | (define-public python-spectra |
2834 | (package | |
2835 | (name "python-spectra") | |
2836 | (version "0.0.8") | |
2837 | (source | |
2838 | (origin | |
2839 | (method url-fetch) | |
2840 | (uri (pypi-uri "spectra" version)) | |
2841 | (sha256 | |
2842 | (base32 | |
2843 | "0n87kzhpkml2s2q91rdkl8wz2kkv5b0bkrgww45lxa5vq34qh6w5")))) | |
2844 | (build-system python-build-system) | |
2845 | (arguments | |
2846 | `(#:phases | |
2847 | (modify-phases %standard-phases | |
2848 | (replace 'check | |
2849 | (lambda _ | |
2850 | (zero? (system* "nosetests" "-v"))))))) | |
2851 | (propagated-inputs | |
2852 | `(("python-colormath" ,python-colormath))) | |
2853 | (native-inputs | |
2854 | `(("python-nose" ,python-nose))) | |
9be5ecdf | 2855 | (home-page "https://github.com/jsvine/spectra") |
4a7d2009 RW |
2856 | (synopsis "Color scales and color conversion") |
2857 | (description | |
2858 | "This package provides a Python library intended to make color math, | |
2859 | color scales, and color space conversion easy. It has support for: | |
2860 | ||
2861 | @enumerate | |
2862 | @item Color scales | |
2863 | @item Color ranges | |
2864 | @item Color blending | |
2865 | @item Brightening/darkening colors | |
2866 | @item Saturating/desaturating colors | |
2867 | @item Conversion to/from multiple color spaces. | |
2868 | @end enumerate\n") | |
2869 | (license license:expat))) | |
2870 | ||
2871 | (define-public python2-spectra | |
2872 | (package-with-python2 python-spectra)) | |
2873 | ||
3a1bfe18 RW |
2874 | (define-public python2-fastlmm |
2875 | (package | |
2876 | (name "python2-fastlmm") | |
154d0016 | 2877 | (version "0.2.21") |
3a1bfe18 RW |
2878 | (source |
2879 | (origin | |
2880 | (method url-fetch) | |
b074e7d4 | 2881 | (uri (pypi-uri "fastlmm" version ".zip")) |
3a1bfe18 RW |
2882 | (sha256 |
2883 | (base32 | |
154d0016 | 2884 | "1q8c34rpmwkfy3r4d5172pzdkpfryj561897z9r3x22gq7813x1m")))) |
3a1bfe18 RW |
2885 | (build-system python-build-system) |
2886 | (arguments | |
2887 | `(#:python ,python-2)) ; only Python 2.7 is supported | |
2888 | (propagated-inputs | |
2889 | `(("python2-numpy" ,python2-numpy) | |
2890 | ("python2-scipy" ,python2-scipy) | |
2891 | ("python2-matplotlib" ,python2-matplotlib) | |
2892 | ("python2-pandas" ,python2-pandas) | |
2893 | ("python2-scikit-learn" ,python2-scikit-learn) | |
3a1bfe18 RW |
2894 | ("python2-pysnptools" ,python2-pysnptools))) |
2895 | (native-inputs | |
2896 | `(("unzip" ,unzip) | |
2efabc55 | 2897 | ("python2-cython" ,python2-cython) |
1b6d7c3f MB |
2898 | ("python2-mock" ,python2-mock) |
2899 | ("python2-nose" ,python2-nose))) | |
3a1bfe18 RW |
2900 | (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/fastlmm/") |
2901 | (synopsis "Perform genome-wide association studies on large data sets") | |
2902 | (description | |
2903 | "FaST-LMM, which stands for Factored Spectrally Transformed Linear Mixed | |
2904 | Models, is a program for performing both single-SNP and SNP-set genome-wide | |
2905 | association studies (GWAS) on extremely large data sets.") | |
3f641af0 | 2906 | (license license:asl2.0))) |
3a1bfe18 | 2907 | |
7ccb71e0 TD |
2908 | (define-public python-numpy-documentation |
2909 | (package | |
2910 | (name "python-numpy-documentation") | |
2911 | (version (package-version python-numpy)) | |
2912 | (source (package-source python-numpy)) | |
2913 | (build-system python-build-system) | |
2ee8869a | 2914 | (native-inputs |
7ccb71e0 TD |
2915 | `(("python-matplotlib" ,python-matplotlib) |
2916 | ("python-numpy" ,python-numpy) | |
2917 | ("pkg-config" ,pkg-config) | |
2efabc55 HG |
2918 | ("python-sphinx" ,python-sphinx) |
2919 | ("python-numpydoc" ,python-numpydoc) | |
8b89c171 RW |
2920 | ("texlive" ,(texlive-union (list texlive-fonts-amsfonts |
2921 | texlive-fonts-ec | |
2922 | texlive-generic-ifxetex | |
2923 | texlive-generic-pdftex | |
2924 | texlive-latex-amsfonts | |
2925 | texlive-latex-capt-of | |
2926 | texlive-latex-cmap | |
2927 | texlive-latex-environ | |
2928 | texlive-latex-eqparbox | |
2929 | texlive-latex-etoolbox | |
2930 | texlive-latex-expdlist | |
2931 | texlive-latex-fancyhdr | |
2932 | texlive-latex-fancyvrb | |
2933 | texlive-latex-fncychap | |
2934 | texlive-latex-float | |
2935 | texlive-latex-framed | |
2936 | texlive-latex-geometry | |
2937 | texlive-latex-graphics | |
2938 | texlive-latex-hyperref | |
2939 | texlive-latex-mdwtools | |
2940 | texlive-latex-multirow | |
2941 | texlive-latex-oberdiek | |
2942 | texlive-latex-parskip | |
2943 | texlive-latex-preview | |
2944 | texlive-latex-tabulary | |
2945 | texlive-latex-threeparttable | |
2946 | texlive-latex-titlesec | |
2947 | texlive-latex-trimspaces | |
2948 | texlive-latex-ucs | |
2949 | texlive-latex-upquote | |
2950 | texlive-latex-url | |
2951 | texlive-latex-varwidth | |
2952 | texlive-latex-wrapfig))) | |
2ee8869a FB |
2953 | ("texinfo" ,texinfo) |
2954 | ("perl" ,perl) | |
7ccb71e0 TD |
2955 | ("scipy-sphinx-theme" |
2956 | ,(origin ; The build script expects scipy-sphinx-theme as a git submodule | |
2957 | (method git-fetch) | |
2958 | (uri (git-reference | |
2959 | (url "https://github.com/scipy/scipy-sphinx-theme.git") | |
67416769 | 2960 | (commit "c466764e2231ba132c09826b5b138fffa1cfcec3"))) |
7ccb71e0 TD |
2961 | (sha256 |
2962 | (base32 | |
67416769 | 2963 | "0q2y87clwlsgc7wvlsn9pzyssybcq10plwhq2w1ydykfsyyqbmkl")))) |
7ccb71e0 | 2964 | ,@(package-native-inputs python-numpy))) |
2ee8869a | 2965 | (arguments |
7ccb71e0 TD |
2966 | `(#:tests? #f ; we're only generating the documentation |
2967 | #:phases | |
2968 | (modify-phases %standard-phases | |
2969 | (delete 'build) | |
2970 | (replace 'install | |
2971 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
2972 | (let* ((data (string-append (assoc-ref outputs "out") "/share")) | |
2973 | (doc (string-append | |
2974 | data "/doc/" ,name "-" | |
2975 | ,(package-version python-numpy))) | |
2976 | (info-reader (string-append data "/info")) | |
2977 | (html (string-append doc "/html")) | |
2978 | (scipy-sphinx-theme "scipy-sphinx-theme") | |
2979 | (sphinx-theme-checkout (assoc-ref inputs scipy-sphinx-theme)) | |
2980 | (pyver ,(string-append "PYVER="))) | |
8b89c171 RW |
2981 | |
2982 | ;; FIXME: this is needed to for texlive-union to generate | |
2983 | ;; fonts, which are not found. | |
2984 | (setenv "HOME" "/tmp") | |
2985 | ||
7ccb71e0 TD |
2986 | (with-directory-excursion "doc" |
2987 | (copy-recursively sphinx-theme-checkout scipy-sphinx-theme) | |
2988 | (mkdir-p html) | |
2989 | (system* "make" "html" pyver) | |
2990 | (system* "make" "latex" "PAPER=a4" pyver) | |
2991 | (system* "make" "-C" "build/latex" | |
2992 | "all-pdf" "PAPER=a4" pyver) | |
2993 | ;; FIXME: Generation of the info file fails. | |
2994 | ;; (system* "make" "info" pyver) | |
2995 | ;; (mkdir-p info) | |
2996 | ;; (copy-file "build/texinfo/numpy.info" | |
2997 | ;; (string-append info "/numpy.info")) | |
2998 | (for-each (lambda (file) | |
2999 | (copy-file (string-append "build/latex" file) | |
3000 | (string-append doc file))) | |
3001 | '("/numpy-ref.pdf" "/numpy-user.pdf")) | |
3002 | (with-directory-excursion "build/html" | |
3003 | (for-each (lambda (file) | |
3004 | (let* ((dir (dirname file)) | |
3005 | (tgt-dir (string-append html "/" dir))) | |
3006 | (unless (equal? "." dir) | |
3007 | (mkdir-p tgt-dir)) | |
3008 | (install-file file html))) | |
3009 | (find-files "." ".*"))))) | |
3010 | #t))))) | |
3011 | (home-page (package-home-page python-numpy)) | |
3012 | (synopsis "Documentation for the python-numpy package") | |
3013 | (description (package-description python-numpy)) | |
3014 | (license (package-license python-numpy)))) | |
2ee8869a | 3015 | |
7ccb71e0 TD |
3016 | (define-public python2-numpy-documentation |
3017 | (let ((numpy-documentation (package-with-python2 python-numpy-documentation))) | |
3018 | (package | |
3019 | (inherit numpy-documentation) | |
3020 | (native-inputs `(("python2-functools32" ,python2-functools32) | |
3021 | ,@(package-native-inputs numpy-documentation)))))) | |
2ee8869a | 3022 | |
0151a8df | 3023 | (define-public python-pygit2 |
3024 | (package | |
3025 | (name "python-pygit2") | |
8c0c0c4d | 3026 | (version "0.26.0") |
0151a8df | 3027 | (source |
3028 | (origin | |
3029 | (method url-fetch) | |
3030 | (uri (pypi-uri "pygit2" version)) | |
3031 | (sha256 | |
3032 | (base32 | |
8c0c0c4d | 3033 | "1cbc488ra3kg7r3qky17ms0szi3cda2d96qfkv1l9djsy9hnvw57")) |
bb6043fe MB |
3034 | (patches |
3035 | (search-patches "python-pygit2-disable-network-tests.patch")))) | |
0151a8df | 3036 | (build-system python-build-system) |
3037 | (propagated-inputs | |
3038 | `(("python-six" ,python-six) | |
3039 | ("python-cffi" ,python-cffi) | |
3040 | ("libgit2" ,libgit2) | |
3041 | ("python-tox" ,python-tox))) | |
3042 | (home-page "https://github.com/libgit2/pygit2") | |
3043 | (synopsis "Python bindings for libgit2") | |
3044 | (description "Pygit2 is a set of Python bindings to the libgit2 shared | |
3045 | library, libgit2 implements Git plumbing.") | |
3046 | ;; GPL2.0 only, with linking exception. | |
3047 | (license license:gpl2))) | |
3048 | ||
3049 | (define-public python2-pygit2 | |
3050 | (package-with-python2 python-pygit2)) | |
3051 | ||
15bfe6d6 FB |
3052 | (define-public python-pyparsing |
3053 | (package | |
3054 | (name "python-pyparsing") | |
9e5ee6b6 | 3055 | (version "2.2.0") |
15bfe6d6 FB |
3056 | (source |
3057 | (origin | |
3058 | (method url-fetch) | |
de67e922 LF |
3059 | (uri (string-append "mirror://sourceforge/pyparsing/pyparsing" |
3060 | "/pyparsing-" version | |
15bfe6d6 FB |
3061 | "/pyparsing-" version ".tar.gz")) |
3062 | (sha256 | |
3063 | (base32 | |
9e5ee6b6 | 3064 | "016b9gh606aa44sq92jslm89bg874ia0yyiyb643fa6dgbsbqch8")))) |
15bfe6d6 FB |
3065 | (build-system python-build-system) |
3066 | (outputs '("out" "doc")) | |
3067 | (arguments | |
3068 | `(#:tests? #f ; no test target | |
15bfe6d6 | 3069 | #:phases |
007176e7 MB |
3070 | (modify-phases %standard-phases |
3071 | (add-after 'install 'install-doc | |
3072 | (lambda* (#:key outputs #:allow-other-keys) | |
3073 | (let* ((doc (string-append (assoc-ref outputs "doc") | |
3074 | "/share/doc/" ,name "-" ,version)) | |
3075 | (html-doc (string-append doc "/html")) | |
3076 | (examples (string-append doc "/examples"))) | |
3077 | (mkdir-p html-doc) | |
3078 | (mkdir-p examples) | |
3079 | (for-each | |
3080 | (lambda (dir tgt) | |
3081 | (map (lambda (file) | |
3082 | (install-file file tgt)) | |
3083 | (find-files dir ".*"))) | |
3084 | (list "docs" "htmldoc" "examples") | |
3085 | (list doc html-doc examples)) | |
3086 | #t)))))) | |
15bfe6d6 FB |
3087 | (home-page "http://pyparsing.wikispaces.com") |
3088 | (synopsis "Python parsing class library") | |
3089 | (description | |
3090 | "The pyparsing module is an alternative approach to creating and | |
3091 | executing simple grammars, vs. the traditional lex/yacc approach, or the use | |
3092 | of regular expressions. The pyparsing module provides a library of classes | |
3093 | that client code uses to construct the grammar directly in Python code.") | |
bd3fa666 | 3094 | (license license:expat))) |
15bfe6d6 FB |
3095 | |
3096 | (define-public python2-pyparsing | |
3097 | (package-with-python2 python-pyparsing)) | |
3098 | ||
ec00de35 FB |
3099 | (define-public python-numpydoc |
3100 | (package | |
3101 | (name "python-numpydoc") | |
3102 | (version "0.5") | |
3103 | (source | |
3104 | (origin | |
3105 | (method url-fetch) | |
89b5c60e | 3106 | (uri (string-append |
ec00de35 FB |
3107 | "https://pypi.python.org/packages/source/n/numpydoc/numpydoc-" |
3108 | version ".tar.gz")) | |
3109 | (sha256 | |
3110 | (base32 | |
5e4d8f67 AE |
3111 | "0d4dnifaxkll50jx6czj05y8cb4ny60njd2wz299sj2jxfy51w4k")) |
3112 | (modules '((guix build utils))) | |
3113 | (snippet | |
3114 | '(begin | |
3115 | ;; Drop a test requiring matplotlib, which we cannot add as an | |
3116 | ;; input since it would create a circular dependency: Extend the | |
3117 | ;; test for Python 3, where it is already dropped, to Python 2. | |
3118 | (substitute* "numpydoc/tests/test_plot_directive.py" | |
3119 | (("3") "2")))))) | |
ec00de35 | 3120 | (build-system python-build-system) |
fe4a8da4 | 3121 | (propagated-inputs |
213d1745 HG |
3122 | `(("python-sphinx" ,python-sphinx))) |
3123 | (native-inputs | |
3124 | `(("python-nose" ,python-nose))) | |
ec00de35 FB |
3125 | (home-page "https://pypi.python.org/pypi/numpydoc") |
3126 | (synopsis | |
3127 | "Numpy's Sphinx extensions") | |
3128 | (description | |
3129 | "Sphinx extension to support docstrings in Numpy format.") | |
3f641af0 | 3130 | (license license:bsd-2))) |
ec00de35 FB |
3131 | |
3132 | (define-public python2-numpydoc | |
5e4d8f67 | 3133 | (package-with-python2 python-numpydoc)) |
1c65314c | 3134 | |
1e656049 RW |
3135 | (define-public python-numexpr |
3136 | (package | |
3137 | (name "python-numexpr") | |
cb91edeb | 3138 | (version "2.6.4") |
1e656049 RW |
3139 | (source |
3140 | (origin | |
3141 | (method url-fetch) | |
26112c0a | 3142 | (uri (pypi-uri "numexpr" version)) |
1e656049 RW |
3143 | (sha256 |
3144 | (base32 | |
cb91edeb | 3145 | "1kpnbb5d5n927113zccfibn16z7gidjipyac6kbbhzs0lnizkgph")))) |
1e656049 RW |
3146 | (build-system python-build-system) |
3147 | (arguments `(#:tests? #f)) ; no tests included | |
3148 | (propagated-inputs | |
3149 | `(("python-numpy" ,python-numpy))) | |
3150 | (home-page "https://github.com/pydata/numexpr") | |
3151 | (synopsis "Fast numerical expression evaluator for NumPy") | |
3152 | (description | |
3153 | "Numexpr is a fast numerical expression evaluator for NumPy. With it, | |
3154 | expressions that operate on arrays are accelerated and use less memory than | |
3155 | doing the same calculation in Python. In addition, its multi-threaded | |
3156 | capabilities can make use of all your cores, which may accelerate | |
3157 | computations, most specially if they are not memory-bounded (e.g. those using | |
3158 | transcendental functions).") | |
f210e944 | 3159 | (license license:expat))) |
1e656049 RW |
3160 | |
3161 | (define-public python2-numexpr | |
f210e944 | 3162 | (package-with-python2 python-numexpr)) |
1e656049 | 3163 | |
361d982c MB |
3164 | (define-public python-cycler |
3165 | (package | |
3166 | (name "python-cycler") | |
3167 | (version "0.10.0") | |
3168 | (source (origin | |
3169 | (method url-fetch) | |
3170 | (uri (pypi-uri "cycler" version)) | |
3171 | (sha256 | |
3172 | (base32 | |
3173 | "1n69n23fak1gjxlrbhqisi2b9pv3ckrfj98llx3p53953082syyd")))) | |
3174 | (build-system python-build-system) | |
3175 | (arguments | |
3176 | ;; XXX: The current version requires 'coveralls' which we don't have. | |
3177 | ;; Enable this for the next release which uses 'python-pytest'. | |
3178 | '(#:tests? #f)) | |
3179 | (propagated-inputs | |
3180 | `(("python-six" ,python-six))) | |
3181 | (home-page "http://matplotlib.org/cycler/") | |
3182 | (synopsis "Composable keyword argument iterator") | |
3183 | (description | |
3184 | "When using @code{matplotlib} and plotting more than one line, it is | |
3185 | common to want to be able to want to be able to cycle over one or more artist | |
3186 | styles; but the plotting logic can quickly become involved. | |
3187 | To address this and enable easy cycling over arbitrary @code{kwargs}, the | |
3188 | @code{Cycler} class was developed.") | |
3189 | (license license:bsd-3))) | |
3190 | ||
3191 | (define-public python2-cycler | |
3192 | (package-with-python2 python-cycler)) | |
3193 | ||
2aa6d3ae TD |
3194 | (define-public python-colorspacious |
3195 | (package | |
3196 | (name "python-colorspacious") | |
3197 | (version "1.1.0") | |
3198 | (source | |
3199 | (origin | |
3200 | (method url-fetch) | |
3201 | (uri (string-append "https://github.com/njsmith/colorspacious/archive/v" | |
3202 | version ".tar.gz")) | |
3203 | (file-name (string-append name "-" version)) | |
3204 | (sha256 | |
3205 | (base32 "1vflh5jm32qb0skza2i8pjacv09w6gq84fqpp2nj77s0rbmzgr4k")))) | |
3206 | (build-system python-build-system) | |
3207 | (propagated-inputs | |
3208 | `(("python-numpy" ,python-numpy))) | |
ba062b3e TD |
3209 | (native-inputs |
3210 | `(("python-nose" ,python-nose))) | |
3211 | (arguments | |
3212 | `(#:phases | |
3213 | (modify-phases %standard-phases | |
3214 | (replace 'check | |
3215 | (lambda _ | |
3216 | (zero? (system* "nosetests" "--all-modules" "-v" "colorspacious"))))))) | |
2aa6d3ae TD |
3217 | (home-page "https://github.com/njsmith/colorspacious") |
3218 | (synopsis "Python library for colorspace conversions") | |
3219 | (description "@code{colorspacious} is a Python library that lets you | |
3220 | convert between colorspaces like sRGB, XYZ, CIEL*a*b*, CIECAM02, CAM02-UCS, etc.") | |
3221 | (license license:expat))) | |
3222 | ||
3223 | (define-public python2-colorspacious | |
3224 | (package-with-python2 python-colorspacious)) | |
3225 | ||
1c65314c FB |
3226 | (define-public python-matplotlib |
3227 | (package | |
3228 | (name "python-matplotlib") | |
71d20587 | 3229 | (version "2.0.2") |
1c65314c FB |
3230 | (source |
3231 | (origin | |
3232 | (method url-fetch) | |
71d20587 | 3233 | (uri (pypi-uri "matplotlib" version)) |
1c65314c FB |
3234 | (sha256 |
3235 | (base32 | |
71d20587 | 3236 | "1w8z2a1l7s72p1byfz7g03wqhygqxi8w82619dqb3a1lm97w9yqg")))) |
1c65314c | 3237 | (build-system python-build-system) |
25f9a068 | 3238 | (propagated-inputs ; the following packages are all needed at run time |
4535a93a TD |
3239 | `(("python-cycler" ,python-cycler) |
3240 | ("python-pyparsing" ,python-pyparsing) | |
25f9a068 FB |
3241 | ("python-pygobject" ,python-pygobject) |
3242 | ("gobject-introspection" ,gobject-introspection) | |
1bbc659f | 3243 | ("python-tkinter" ,python "tk") |
22d7360b | 3244 | ("python-dateutil" ,python-dateutil) |
7ccb71e0 | 3245 | ("python-numpy" ,python-numpy) |
ca33a3ad HG |
3246 | ("python-pillow" ,python-pillow) |
3247 | ("python-pytz" ,python-pytz) | |
3248 | ("python-six" ,python-six) | |
25f9a068 FB |
3249 | ;; The 'gtk+' package (and 'gdk-pixbuf', 'atk' and 'pango' propagated |
3250 | ;; from 'gtk+') provides the required 'typelib' files used by | |
3251 | ;; 'gobject-introspection'. The location of these files is set with the | |
3252 | ;; help of the environment variable GI_TYPELIB_PATH. At build time this | |
3253 | ;; is done automatically by a 'native-search-path' procedure. However, | |
3254 | ;; at run-time the user must set this variable as follows: | |
3255 | ;; | |
3256 | ;; export GI_TYPELIB_PATH=~/.guix-profile/lib/girepository-1.0 | |
25f9a068 FB |
3257 | ("gtk+" ,gtk+) |
3258 | ;; From version 1.4.0 'matplotlib' makes use of 'cairocffi' instead of | |
3259 | ;; 'pycairo'. However, 'pygobject' makes use of a 'pycairo' 'context' | |
3260 | ;; object. For this reason we need to import both libraries. | |
3261 | ;; https://pythonhosted.org/cairocffi/cffi_api.html#converting-pycairo | |
3262 | ("python-pycairo" ,python-pycairo) | |
7e060865 | 3263 | ("python-pyqt" ,python-pyqt) |
25f9a068 | 3264 | ("python-cairocffi" ,python-cairocffi))) |
1c65314c | 3265 | (inputs |
ca33a3ad | 3266 | `(("libpng" ,libpng) |
1c65314c FB |
3267 | ("imagemagick" ,imagemagick) |
3268 | ("freetype" ,freetype) | |
25f9a068 FB |
3269 | ("cairo" ,cairo) |
3270 | ("glib" ,glib) | |
1c65314c | 3271 | ;; FIXME: Add backends when available. |
1c65314c | 3272 | ;("python-wxpython" ,python-wxpython) |
1bbc659f FB |
3273 | ("tcl" ,tcl) |
3274 | ("tk" ,tk))) | |
1c65314c FB |
3275 | (native-inputs |
3276 | `(("pkg-config" ,pkg-config) | |
ca33a3ad | 3277 | ("python-nose" ,python-nose) |
4535a93a | 3278 | ("python-mock" ,python-mock))) |
1c65314c FB |
3279 | (arguments |
3280 | `(#:phases | |
42b7009a DM |
3281 | (modify-phases %standard-phases |
3282 | (add-before 'build 'configure-environment | |
3283 | (lambda* (#:key outputs inputs #:allow-other-keys) | |
3284 | (let ((cairo (assoc-ref inputs "cairo")) | |
3285 | (gtk+ (assoc-ref inputs "gtk+"))) | |
3286 | ;; Setting these directories in the 'basedirlist' of 'setup.cfg' | |
3287 | ;; has not effect. | |
3288 | (setenv "LD_LIBRARY_PATH" | |
3289 | (string-append cairo "/lib:" gtk+ "/lib")) | |
3290 | (setenv "HOME" (getcwd)) | |
3291 | (call-with-output-file "setup.cfg" | |
3292 | (lambda (port) | |
3293 | (format port "[directories]~% | |
1bbc659f | 3294 | basedirlist = ~a,~a~% |
57b7b8cd | 3295 | [rc_options]~% |
1bbc659f FB |
3296 | backend = TkAgg~%" |
3297 | (assoc-ref inputs "tcl") | |
4535a93a TD |
3298 | (assoc-ref inputs "tk"))))) |
3299 | #t))))) | |
1c65314c FB |
3300 | (home-page "http://matplotlib.org") |
3301 | (synopsis "2D plotting library for Python") | |
3302 | (description | |
3303 | "Matplotlib is a Python 2D plotting library which produces publication | |
3304 | quality figures in a variety of hardcopy formats and interactive environments | |
3305 | across platforms. Matplotlib can be used in Python scripts, the python and | |
3306 | ipython shell, web application servers, and six graphical user interface | |
3307 | toolkits.") | |
3f641af0 | 3308 | (license license:psfl) |
57b7b8cd | 3309 | (properties `((python2-variant . ,(delay python2-matplotlib)))))) |
1c65314c | 3310 | |
764c077b | 3311 | (define-public python2-matplotlib |
57b7b8cd LC |
3312 | (let ((matplotlib (package-with-python2 |
3313 | (strip-python2-variant python-matplotlib)))) | |
764c077b | 3314 | (package (inherit matplotlib) |
88c26834 AE |
3315 | ;; Make sure to use special packages for Python 2 instead |
3316 | ;; of those automatically rewritten by package-with-python2. | |
89b5c60e | 3317 | (propagated-inputs |
7ca0dbc3 | 3318 | `(("python2-pycairo" ,python2-pycairo) |
4535a93a | 3319 | ("python2-functools32" ,python2-functools32) |
764c077b | 3320 | ("python2-pygobject-2" ,python2-pygobject-2) |
4535a93a | 3321 | ("python2-subprocess32" ,python2-subprocess32) |
1bbc659f FB |
3322 | ("python2-tkinter" ,python-2 "tk") |
3323 | ,@(fold alist-delete (package-propagated-inputs matplotlib) | |
3324 | '("python-pycairo" "python-pygobject" "python-tkinter"))))))) | |
94914805 | 3325 | |
4535a93a TD |
3326 | (define-public python-matplotlib-documentation |
3327 | (package | |
3328 | (name "python-matplotlib-documentation") | |
3329 | (version (package-version python-matplotlib)) | |
3330 | (source (package-source python-matplotlib)) | |
3331 | (build-system python-build-system) | |
3332 | (native-inputs | |
3333 | `(("python-matplotlib" ,python-matplotlib) | |
3334 | ("python-colorspacious" ,python-colorspacious) | |
3335 | ("python-sphinx" ,python-sphinx) | |
3336 | ("python-numpydoc" ,python-numpydoc) | |
3337 | ("python-ipython" ,python-ipython) | |
1eaaea41 TD |
3338 | ("python-mock" ,python-mock) |
3339 | ("graphviz" ,graphviz) | |
4535a93a TD |
3340 | ("texlive" ,texlive) |
3341 | ("texinfo" ,texinfo) | |
3342 | ,@(package-native-inputs python-matplotlib))) | |
3343 | (arguments | |
3344 | `(#:tests? #f ; we're only generating documentation | |
3345 | #:phases | |
3346 | (modify-phases %standard-phases | |
1eaaea41 TD |
3347 | (replace 'build |
3348 | (lambda _ | |
3349 | (chdir "doc") | |
3350 | ;; Produce pdf in 'A4' format. | |
3351 | (substitute* "conf.py" | |
3352 | (("latex_paper_size = 'letter'") "") | |
3353 | ;; latex_paper_size is deprecated -> set paper size using | |
3354 | ;; latex_elements | |
3355 | (("latex_elements\\['pointsize'\\] = '11pt'" match) | |
3356 | ;; insert at a point where latex_elements{} is defined: | |
3357 | (string-append match "\nlatex_elements['papersize'] = 'a4paper'"))) | |
3358 | (zero? (system* "python" "make.py" "html" "latex" "texinfo")))) | |
4535a93a | 3359 | (replace 'install |
42b7009a | 3360 | (lambda* (#:key inputs outputs #:allow-other-keys) |
4535a93a | 3361 | (let* ((data (string-append (assoc-ref outputs "out") "/share")) |
1eaaea41 | 3362 | (doc (string-append data "/doc/python-matplotlib-" ,version)) |
42b7009a DM |
3363 | (info (string-append data "/info")) |
3364 | (html (string-append doc "/html"))) | |
1eaaea41 TD |
3365 | (mkdir-p html) |
3366 | (mkdir-p info) | |
3367 | (copy-recursively "build/html" html) | |
3368 | (symlink (string-append html "/_images") | |
3369 | (string-append info "/matplotlib-figures")) | |
3370 | (with-directory-excursion "build/texinfo" | |
3371 | (substitute* "matplotlib.texi" | |
3372 | (("@image\\{([^,]*)" all file) | |
3373 | (string-append "@image{matplotlib-figures/" file))) | |
18b31516 | 3374 | (symlink (string-append html "/_images") |
1eaaea41 TD |
3375 | "./matplotlib-figures") |
3376 | (system* "makeinfo" "--no-split" | |
3377 | "-o" "matplotlib.info" "matplotlib.texi")) | |
3378 | (copy-file "build/texinfo/matplotlib.info" | |
3379 | (string-append info "/matplotlib.info")) | |
3380 | (copy-file "build/latex/Matplotlib.pdf" | |
3381 | (string-append doc "/Matplotlib.pdf"))) | |
4535a93a TD |
3382 | #t))))) |
3383 | (home-page (package-home-page python-matplotlib)) | |
3384 | (synopsis "Documentation for the python-matplotlib package") | |
3385 | (description (package-description python-matplotlib)) | |
3386 | (license (package-license python-matplotlib)))) | |
1c65314c | 3387 | |
4535a93a TD |
3388 | (define-public python2-matplotlib-documentation |
3389 | (package-with-python2 python-matplotlib-documentation)) | |
94914805 | 3390 | |
0dde6232 RW |
3391 | (define-public python2-pysnptools |
3392 | (package | |
3393 | (name "python2-pysnptools") | |
a800018e | 3394 | (version "0.3.9") |
0dde6232 RW |
3395 | (source |
3396 | (origin | |
3397 | (method url-fetch) | |
3f2e9675 | 3398 | (uri (pypi-uri "pysnptools" version ".zip")) |
0dde6232 RW |
3399 | (sha256 |
3400 | (base32 | |
a800018e | 3401 | "1wybggjzz8zw7aav4pjsg2h22xp17a1lghrprza1pxwlm7wf96y2")))) |
0dde6232 RW |
3402 | (build-system python-build-system) |
3403 | (arguments | |
3404 | `(#:python ,python-2)) ; only Python 2.7 is supported | |
3405 | (propagated-inputs | |
3406 | `(("python2-numpy" ,python2-numpy) | |
3407 | ("python2-scipy" ,python2-scipy) | |
b72ac1b5 HG |
3408 | ("python2-pandas" ,python2-pandas))) |
3409 | (native-inputs | |
3410 | `(("python2-cython" ,python2-cython))) | |
0dde6232 | 3411 | (native-inputs |
f3b98f4f | 3412 | `(("unzip" ,unzip))) |
0dde6232 RW |
3413 | (home-page "http://research.microsoft.com/en-us/um/redmond/projects/mscompbio/") |
3414 | (synopsis "Library for reading and manipulating genetic data") | |
3415 | (description | |
3416 | "PySnpTools is a library for reading and manipulating genetic data. It | |
3417 | can, for example, efficiently read whole PLINK *.bed/bim/fam files or parts of | |
3418 | those files. It can also efficiently manipulate ranges of integers using set | |
3419 | operators such as union, intersection, and difference.") | |
3f641af0 | 3420 | (license license:asl2.0))) |
0dde6232 | 3421 | |
c9b1b4f9 RW |
3422 | (define-public python-rpy2 |
3423 | (package | |
3424 | (name "python-rpy2") | |
deee5dda | 3425 | (version "2.9.0") |
c9b1b4f9 RW |
3426 | (source |
3427 | (origin | |
3428 | (method url-fetch) | |
ec3bcbc7 | 3429 | (uri (pypi-uri "rpy2" version)) |
c9b1b4f9 RW |
3430 | (sha256 |
3431 | (base32 | |
deee5dda | 3432 | "0bqihjrdqwj5r1h86shvfb1p5hfr4a6klv1v54bzfr9r144w3rni")))) |
c9b1b4f9 | 3433 | (build-system python-build-system) |
444464ec | 3434 | (arguments |
deee5dda RW |
3435 | '(#:modules ((ice-9 ftw) |
3436 | (srfi srfi-1) | |
3437 | (srfi srfi-26) | |
3438 | (guix build utils) | |
3439 | (guix build python-build-system)) | |
3440 | #:phases | |
444464ec | 3441 | (modify-phases %standard-phases |
deee5dda RW |
3442 | ;; Without this phase the test loader cannot find the directories, in |
3443 | ;; which it is supposed to look for test files. | |
3444 | (add-after 'unpack 'fix-tests | |
3445 | (lambda* (#:key outputs #:allow-other-keys) | |
3446 | (substitute* "rpy/tests.py" | |
3447 | (("loader.discover\\(") | |
3448 | "loader.discover(rpy_root + '/' +")) | |
3449 | #t)) | |
3450 | (replace 'check | |
444464ec | 3451 | (lambda* (#:key outputs inputs #:allow-other-keys) |
deee5dda RW |
3452 | (let ((cwd (getcwd))) |
3453 | (setenv "PYTHONPATH" | |
3454 | (string-append cwd "/build/" | |
3455 | (find (cut string-prefix? "lib" <>) | |
3456 | (scandir (string-append cwd "/build"))) | |
3457 | ":" | |
3458 | (getenv "PYTHONPATH")))) | |
22d1060e RW |
3459 | ;; FIXME: Even when all tests pass, the check phase will fail. |
3460 | (system* "python" "-m" "rpy2.tests" "-v")))))) | |
482d9591 | 3461 | (propagated-inputs |
deee5dda RW |
3462 | `(("python-six" ,python-six) |
3463 | ("python-jinja2" ,python-jinja2) | |
3464 | ("python-pytz" ,python-pytz))) | |
c9b1b4f9 | 3465 | (inputs |
482d9591 | 3466 | `(("readline" ,readline) |
c9b1b4f9 RW |
3467 | ("icu4c" ,icu4c) |
3468 | ("pcre" ,pcre) | |
2d7c4ae3 | 3469 | ("r-minimal" ,r-minimal) |
deee5dda RW |
3470 | ("r-survival" ,r-survival) |
3471 | ("r-ggplot2" ,r-ggplot2) | |
3472 | ("r-rsqlite" ,r-rsqlite) | |
3473 | ("r-dplyr" ,r-dplyr) | |
3474 | ("r-dbplyr" ,r-dbplyr) | |
3475 | ("python-numpy" ,python-numpy))) | |
c9b1b4f9 | 3476 | (native-inputs |
f3b98f4f | 3477 | `(("zlib" ,zlib))) |
c9b1b4f9 RW |
3478 | (home-page "http://rpy.sourceforge.net/") |
3479 | (synopsis "Python interface to the R language") | |
3480 | (description "rpy2 is a redesign and rewrite of rpy. It is providing a | |
3481 | low-level interface to R from Python, a proposed high-level interface, | |
3482 | including wrappers to graphical libraries, as well as R-like structures and | |
3483 | functions.") | |
c92483bd RW |
3484 | ;; Any of these licenses can be picked for the R interface. The whole |
3485 | ;; project is released under GPLv2+ according to the license declaration | |
3486 | ;; in "setup.py". | |
3487 | (license (list license:mpl2.0 license:gpl2+ license:lgpl2.1+)))) | |
c9b1b4f9 | 3488 | |
bb986599 FB |
3489 | (define-public python-scipy |
3490 | (package | |
3491 | (name "python-scipy") | |
09efef33 | 3492 | (version "0.19.1") |
bb986599 FB |
3493 | (source |
3494 | (origin | |
3495 | (method url-fetch) | |
09efef33 | 3496 | (uri (pypi-uri "scipy" version)) |
bb986599 FB |
3497 | (sha256 |
3498 | (base32 | |
09efef33 | 3499 | "1rl411bvla6q7qfdb47fpdnyjhfgzl6smpha33n9ar1klykjr6m1")))) |
bb986599 | 3500 | (build-system python-build-system) |
dd86c0d1 | 3501 | (propagated-inputs |
bb986599 FB |
3502 | `(("python-numpy" ,python-numpy) |
3503 | ("python-matplotlib" ,python-matplotlib) | |
dd86c0d1 RW |
3504 | ("python-pyparsing" ,python-pyparsing))) |
3505 | (inputs | |
3506 | `(("lapack" ,lapack) | |
719b01c1 | 3507 | ("openblas" ,openblas))) |
bb986599 | 3508 | (native-inputs |
35093253 TD |
3509 | `(("python-cython" ,python-cython) |
3510 | ("python-nose" ,python-nose) | |
dd86c0d1 | 3511 | ("python-sphinx" ,python-sphinx) |
5248d49e | 3512 | ("python-numpydoc" ,python-numpydoc) |
dd86c0d1 | 3513 | ("gfortran" ,gfortran) |
bb986599 FB |
3514 | ("perl" ,perl))) |
3515 | (outputs '("out" "doc")) | |
3516 | (arguments | |
3517 | `(#:phases | |
16ca6aaa | 3518 | (modify-phases %standard-phases |
16ca6aaa MB |
3519 | (add-before '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] | |
719b01c1 RW |
3525 | libraries = openblas |
3526 | library_dirs = ~a/lib | |
3527 | include_dirs = ~a/include | |
d548e6aa HG |
3528 | |
3529 | # backslash-n to make emacs happy | |
3530 | \n[atlas] | |
719b01c1 RW |
3531 | library_dirs = ~a/lib |
3532 | atlas_libs = openblas | |
3533 | " | |
16ca6aaa MB |
3534 | (assoc-ref inputs "openblas") |
3535 | (assoc-ref inputs "openblas") | |
3536 | (assoc-ref inputs "openblas")))) | |
db967b64 | 3537 | #t)) |
35093253 TD |
3538 | (add-after 'install 'install-doc |
3539 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
3540 | (let* ((data (string-append (assoc-ref outputs "doc") "/share")) | |
3541 | (doc (string-append data "/doc/" ,name "-" ,version)) | |
3542 | (html (string-append doc "/html")) | |
3543 | (pyver ,(string-append "PYVER="))) | |
3544 | ;; Make installed package available for building the | |
3545 | ;; documentation | |
3546 | (add-installed-pythonpath inputs outputs) | |
3547 | (with-directory-excursion "doc" | |
3548 | ;; Fix generation of images for mathematical expressions. | |
3549 | (substitute* (find-files "source" "conf\\.py") | |
3550 | (("pngmath_use_preview = True") | |
3551 | "pngmath_use_preview = False")) | |
3552 | (mkdir-p html) | |
3553 | (system* "make" "html" pyver) | |
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 | #t)) | |
3561 | (add-after 'unpack 'fix-tests | |
3562 | (lambda _ | |
3563 | (substitute* "scipy/integrate/tests/test_quadpack.py" | |
3564 | (("libm.so") "libm.so.6")) | |
3565 | #t)) | |
3566 | ;; Tests can only be run after the library has been installed and not | |
3567 | ;; within the source directory. | |
3568 | (delete 'check) | |
3569 | (add-after 'install 'check | |
3570 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
d548e6aa | 3571 | (add-installed-pythonpath inputs outputs) |
35093253 TD |
3572 | (with-directory-excursion "/tmp" |
3573 | (zero? (system* "python" "-c" | |
3574 | "import scipy; scipy.test('full')"))) | |
3575 | #t))))) | |
9be5ecdf | 3576 | (home-page "https://www.scipy.org/") |
bb986599 FB |
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.") | |
9200fe14 | 3581 | (properties `((python2-variant . ,(delay python2-scipy)))) |
3f641af0 | 3582 | (license license:bsd-3))) |
bb986599 | 3583 | |
764c077b | 3584 | (define-public python2-scipy |
35093253 TD |
3585 | (package-with-python2 |
3586 | (strip-python2-variant python-scipy))) | |
bb986599 | 3587 | |
73acc193 | 3588 | (define-public python-socksipy-branch |
3589 | (package | |
3590 | (name "python-socksipy-branch") | |
3591 | (version "1.01") | |
3592 | (source | |
3593 | (origin | |
3594 | (method url-fetch) | |
3595 | (uri (pypi-uri "SocksiPy-branch" version)) | |
3596 | (sha256 | |
3597 | (base32 | |
3598 | "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p")))) | |
3599 | (build-system python-build-system) | |
3600 | (arguments | |
3601 | `(#:tests? #f)) ; There are no tests | |
3602 | (home-page "https://code.google.com/archive/p/socksipy-branch/") | |
3603 | (synopsis "Python SOCKS module") | |
3604 | (description | |
3605 | "SocksiPy - A Python SOCKS client module. It provides a | |
3606 | socket-like interface that supports connections to any TCP | |
3607 | service through the use of a SOCKS4, SOCKS5 or HTTP proxy. | |
3608 | The original version was developed by Dan Haim, this is a | |
3609 | branch created by Mario Vilas to address some open issues, | |
3610 | as the original project seems to have been abandoned circa 2007.") | |
3611 | (license license:bsd-3))) | |
3612 | ||
3613 | (define-public python2-socksipy-branch | |
3614 | (package-with-python2 python-socksipy-branch)) | |
3615 | ||
4a093330 DM |
3616 | (define-public python-pycodestyle |
3617 | (package | |
3618 | (name "python-pycodestyle") | |
9b801661 | 3619 | (version "2.3.1") |
4a093330 DM |
3620 | (source |
3621 | (origin | |
3622 | (method url-fetch) | |
3623 | (uri (pypi-uri "pycodestyle" version)) | |
3624 | (sha256 | |
3625 | (base32 | |
9b801661 | 3626 | "0rk78b66p57ala26mdldl9lafr48blv5s659sah9q50qnfjmc8k8")))) |
4a093330 DM |
3627 | (build-system python-build-system) |
3628 | (home-page "https://pycodestyle.readthedocs.io/") | |
3629 | (synopsis "Python style guide checker") | |
3630 | (description "@code{pycodestyle} (formerly pep8) is a tool to check | |
3631 | Python code against some of the style conventions in | |
3632 | @url{http://www.python.org/dev/peps/pep-0008/,PEP 8}.") | |
f210e944 | 3633 | (license license:expat))) |
4a093330 DM |
3634 | |
3635 | (define-public python2-pycodestyle | |
f210e944 | 3636 | (package-with-python2 python-pycodestyle)) |
b91912c4 DM |
3637 | |
3638 | (define-public python-orderedmultidict | |
3639 | (package | |
3640 | (name "python-orderedmultidict") | |
9e2802cb | 3641 | (version "0.7.11") |
b91912c4 DM |
3642 | (source |
3643 | (origin | |
3644 | (method url-fetch) | |
3645 | (uri (pypi-uri "orderedmultidict" version)) | |
3646 | (sha256 | |
3647 | (base32 | |
9e2802cb | 3648 | "0dls862ibm7qbq4fnvwx0xn1v9hwyzywbff8xjjdr42dd75208yw")))) |
b91912c4 DM |
3649 | (build-system python-build-system) |
3650 | (arguments | |
3651 | `(#:phases | |
3652 | (modify-phases %standard-phases | |
3653 | (add-after 'unpack 'fix-tests | |
3654 | (lambda _ | |
3655 | ;; The package uses nosetest for running the tests. | |
3656 | ;; Adding this initfile allows to run the test suite | |
3657 | ;; without requiring nosetest. | |
3658 | (zero? (system* "touch" "tests/__init__.py"))))))) | |
3659 | (propagated-inputs | |
3660 | `(("python-six" ,python-six))) | |
3661 | (native-inputs | |
3662 | `(("python-pycodestyle" ,python-pycodestyle))) | |
3663 | (home-page "https://github.com/gruns/orderedmultidict") | |
3664 | (synopsis "Python Ordered Multivalue Dictionary - omdict") | |
3665 | (description "This package contains a library for ordered multivalue | |
3666 | dictionaries. A multivalue dictionary is a dictionary that can store | |
3667 | multiple values for the same key. An ordered multivalue dictionary is a | |
3668 | multivalue dictionary that retains the order of insertions and deletions.") | |
f210e944 | 3669 | (license license:unlicense))) |
b91912c4 DM |
3670 | |
3671 | (define-public python2-orderedmultidict | |
f210e944 | 3672 | (package-with-python2 python-orderedmultidict)) |
9dede065 | 3673 | |
138adbbe TD |
3674 | (define-public python-autopep8 |
3675 | (package | |
3676 | (name "python-autopep8") | |
8e483fb5 | 3677 | (version "1.3.2") |
138adbbe TD |
3678 | (source |
3679 | (origin | |
3680 | (method url-fetch) | |
3681 | (uri (pypi-uri "autopep8" version)) | |
3682 | (sha256 | |
3683 | (base32 | |
8e483fb5 | 3684 | "1p9pa1ffg4iy96l918808jggg9a69iaka5awmj8xid36yc5mk0ky")))) |
138adbbe TD |
3685 | (build-system python-build-system) |
3686 | (propagated-inputs | |
8e483fb5 | 3687 | `(("python-pycodestyle" ,python-pycodestyle))) |
138adbbe TD |
3688 | (home-page "https://github.com/hhatto/autopep8") |
3689 | (synopsis "Format Python code according to the PEP 8 style guide") | |
3690 | (description | |
3691 | "@code{autopep8} automatically formats Python code to conform to | |
3692 | the PEP 8 style guide. It uses the pycodestyle utility to determine | |
3693 | what parts of the code needs to be formatted. @code{autopep8} is | |
3694 | capable of fixing most of the formatting issues that can be reported | |
3695 | by pycodestyle.") | |
3696 | (license (license:non-copyleft | |
3697 | "https://github.com/hhatto/autopep8/blob/master/LICENSE")))) | |
3698 | ||
3699 | (define-public python2-autopep8 | |
3700 | (package-with-python2 python-autopep8)) | |
3701 | ||
1671c07c EB |
3702 | (define-public python-distutils-extra |
3703 | (package | |
3704 | (name "python-distutils-extra") | |
3705 | (version "2.38") | |
3706 | (source | |
3707 | (origin | |
3708 | (method url-fetch) | |
3709 | (uri (string-append "https://launchpad.net/python-distutils-extra/trunk/" | |
3710 | version "/+download/python-distutils-extra-" | |
3711 | version ".tar.gz")) | |
3712 | (sha256 | |
3713 | (base32 | |
3714 | "0lx15kcbby9zisx33p2h5hgakgwh2bvh0ibag8z0px4j6ifhs41x")))) | |
3715 | (build-system python-build-system) | |
1671c07c EB |
3716 | (home-page "https://launchpad.net/python-distutils-extra/") |
3717 | (synopsis "Enhancements to Python's distutils") | |
3718 | (description | |
3719 | "The python-distutils-extra module enables you to easily integrate | |
3720 | gettext support, themed icons, and scrollkeeper-based documentation into | |
3721 | Python's distutils.") | |
3f641af0 | 3722 | (license license:gpl2))) |
1671c07c EB |
3723 | |
3724 | (define-public python2-distutils-extra | |
3725 | (package-with-python2 python-distutils-extra)) | |
ea5456c8 EB |
3726 | |
3727 | (define-public python2-elib.intl | |
3728 | (package | |
3729 | (name "python2-elib.intl") | |
3730 | (version "0.0.3") | |
3731 | (source | |
3732 | (origin | |
3733 | ;; This project doesn't tag releases or publish tarballs, so we take | |
3734 | ;; source from a (semi-arbitrary, i.e. latest as of now) git commit. | |
3735 | (method git-fetch) | |
3736 | (uri (git-reference | |
3737 | (url "https://github.com/dieterv/elib.intl.git") | |
3738 | (commit "d09997cfef"))) | |
3739 | (sha256 | |
3740 | (base32 | |
3741 | "0y7vzff9xgbnaay7m0va1arl6g68ncwrvbgwl7jqlclsahzzb09d")))) | |
3742 | (build-system python-build-system) | |
ea5456c8 EB |
3743 | (arguments |
3744 | ;; incompatible with Python 3 (exception syntax) | |
3745 | `(#:python ,python-2 | |
b41a05ce | 3746 | #:tests? #f)) |
ea5456c8 EB |
3747 | (home-page "https://github.com/dieterv/elib.intl") |
3748 | (synopsis "Enhanced internationalization for Python") | |
3749 | (description | |
3750 | "The elib.intl module provides enhanced internationalization (I18N) | |
3751 | services for your Python modules and applications.") | |
3f641af0 | 3752 | (license license:lgpl3+))) |
ea5456c8 | 3753 | |
3a1f26ff KK |
3754 | (define-public python-olefile |
3755 | (package | |
3756 | (name "python-olefile") | |
3757 | (version "0.44") | |
3758 | (source | |
3759 | (origin | |
3760 | (method url-fetch) | |
3761 | (uri (string-append "https://github.com/decalage2/olefile/archive/v" | |
3762 | version ".tar.gz")) | |
3763 | (file-name (string-append name "-" version ".tar.gz")) | |
3764 | (sha256 | |
3765 | (base32 | |
3766 | "1wmxbrhyqjry2000zx0zdhqdqxhgi06nz7sbzjlh222q2zjv1gpj")))) | |
3767 | (build-system python-build-system) | |
3768 | (home-page | |
3769 | "https://www.decalage.info/python/olefileio") | |
3770 | (synopsis "Read and write Microsoft OLE2 files.") | |
3771 | (description | |
3772 | "@code{olefile} can parse, read and write Microsoft OLE2 files (Structured | |
3773 | Storage or Compound Document, Microsoft Office). It is an improved version of | |
3774 | the OleFileIO module from PIL, the Python Image Library.") | |
3775 | (license license:bsd-3))) | |
3776 | ||
3777 | (define-public python2-olefile | |
3778 | (package-with-python2 python-olefile)) | |
3779 | ||
c937562e EB |
3780 | (define-public python-pillow |
3781 | (package | |
3782 | (name "python-pillow") | |
9e3a8ed0 | 3783 | (version "4.3.0") |
c937562e EB |
3784 | (source |
3785 | (origin | |
3786 | (method url-fetch) | |
f1d9231d | 3787 | (uri (pypi-uri "Pillow" version)) |
c937562e EB |
3788 | (sha256 |
3789 | (base32 | |
15b60fc3 KK |
3790 | "09xmn7rl6840sli2iz1k3fgxfgmri2nqz6vkinmb9mgg8ifp2z59")) |
3791 | (patch-flags '("-p1" "--binary")) | |
3792 | (patches (search-patches "python-pillow-fix-failing-tests.patch")))) | |
c937562e EB |
3793 | (build-system python-build-system) |
3794 | (native-inputs | |
f3b98f4f | 3795 | `(("python-nose" ,python-nose))) |
c937562e | 3796 | (inputs |
5ff408d9 SB |
3797 | `(("freetype" ,freetype) |
3798 | ("lcms" ,lcms) | |
c937562e EB |
3799 | ("zlib" ,zlib) |
3800 | ("libjpeg" ,libjpeg) | |
3801 | ("openjpeg" ,openjpeg) | |
5ff408d9 SB |
3802 | ("libtiff" ,libtiff) |
3803 | ("libwebp" ,libwebp))) | |
9e3a8ed0 KK |
3804 | (propagated-inputs |
3805 | `(("python-olefile" ,python-olefile))) | |
c937562e | 3806 | (arguments |
e5358a6b | 3807 | `(#:phases (modify-phases %standard-phases |
e5358a6b LC |
3808 | (add-after |
3809 | 'install 'check-installed | |
6151120a | 3810 | (lambda* (#:key outputs inputs #:allow-other-keys) |
e5358a6b LC |
3811 | (begin |
3812 | (setenv "HOME" (getcwd)) | |
6151120a HG |
3813 | ;; Make installed package available for running the |
3814 | ;; tests | |
3815 | (add-installed-pythonpath inputs outputs) | |
e5358a6b LC |
3816 | (and (zero? (system* "python" "selftest.py" |
3817 | "--installed")) | |
3818 | (zero? (system* "python" "test-installed.py")))))) | |
3819 | (delete 'check)))) | |
c937562e EB |
3820 | (home-page "https://pypi.python.org/pypi/Pillow") |
3821 | (synopsis "Fork of the Python Imaging Library") | |
3822 | (description | |
3823 | "The Python Imaging Library adds image processing capabilities to your | |
3824 | Python interpreter. This library provides extensive file format support, an | |
3825 | efficient internal representation, and fairly powerful image processing | |
3826 | capabilities. The core image library is designed for fast access to data | |
3827 | stored in a few basic pixel formats. It should provide a solid foundation for | |
3828 | a general image processing tool.") | |
3f641af0 | 3829 | (license (license:x11-style |
c937562e EB |
3830 | "http://www.pythonware.com/products/pil/license.htm" |
3831 | "The PIL Software License")))) | |
3832 | ||
3833 | (define-public python2-pillow | |
3834 | (package-with-python2 python-pillow)) | |
bb986599 | 3835 | |
a415f036 FB |
3836 | (define-public python-pycparser |
3837 | (package | |
3838 | (name "python-pycparser") | |
5043b20d | 3839 | (version "2.17") |
a415f036 FB |
3840 | (source |
3841 | (origin | |
3842 | (method url-fetch) | |
38eb6919 | 3843 | (uri (pypi-uri "pycparser" version)) |
a415f036 FB |
3844 | (sha256 |
3845 | (base32 | |
5043b20d | 3846 | "1dkkjri0miidqb1zcqhqljfa34fcy9k5akasgwsv6k622zlk3b0a")))) |
a415f036 FB |
3847 | (outputs '("out" "doc")) |
3848 | (build-system python-build-system) | |
3849 | (native-inputs | |
f3b98f4f | 3850 | `(("pkg-config" ,pkg-config))) |
a415f036 | 3851 | (arguments |
89b5c60e | 3852 | `(#:phases |
819939cb TGR |
3853 | (modify-phases %standard-phases |
3854 | (replace 'check | |
3855 | (lambda _ | |
3856 | (with-directory-excursion "tests" | |
3857 | (zero? (system* "python" "all_tests.py"))))) | |
3858 | (add-after 'install 'install-doc | |
3859 | (lambda* (#:key outputs #:allow-other-keys) | |
3860 | (let* ((data (string-append (assoc-ref outputs "doc") "/share")) | |
3861 | (doc (string-append data "/doc/" ,name "-" ,version)) | |
3862 | (examples (string-append doc "/examples"))) | |
3863 | (mkdir-p examples) | |
3864 | (for-each (lambda (file) | |
3865 | (copy-file (string-append "." file) | |
3866 | (string-append doc file))) | |
3867 | '("/README.rst" "/CHANGES" "/LICENSE")) | |
3868 | (copy-recursively "examples" examples))))))) | |
a415f036 FB |
3869 | (home-page "https://github.com/eliben/pycparser") |
3870 | (synopsis "C parser in Python") | |
3871 | (description | |
3872 | "Pycparser is a complete parser of the C language, written in pure Python | |
3873 | using the PLY parsing library. It parses C code into an AST and can serve as | |
3874 | a front-end for C compilers or analysis tools.") | |
3f641af0 | 3875 | (license license:bsd-3))) |
a415f036 FB |
3876 | |
3877 | (define-public python2-pycparser | |
3878 | (package-with-python2 python-pycparser)) | |
57c3f716 | 3879 | |
6fa14469 FB |
3880 | (define-public python-xcffib |
3881 | (package | |
3882 | (name "python-xcffib") | |
8347c122 | 3883 | (version "0.5.1") |
6fa14469 FB |
3884 | (source |
3885 | (origin | |
3886 | (method url-fetch) | |
8347c122 | 3887 | (uri (pypi-uri "xcffib" version)) |
6fa14469 FB |
3888 | (sha256 |
3889 | (base32 | |
8347c122 | 3890 | "09gbnmr5vn58mm8xi3fmd7fz6743cks6c46dphnxzwax6zsxmy60")))) |
6fa14469 FB |
3891 | (build-system python-build-system) |
3892 | (inputs | |
482d9591 | 3893 | `(("libxcb" ,libxcb))) |
6fa14469 | 3894 | (propagated-inputs |
482d9591 HG |
3895 | `(("python-cffi" ,python-cffi) ; used at run time |
3896 | ("python-six" ,python-six))) | |
6fa14469 | 3897 | (arguments |
e46bf223 | 3898 | `(;; FIXME: Tests need more work. See ".travis.yml" in the repository. |
e2816ac7 MB |
3899 | #:tests? #f |
3900 | #:phases | |
c8cd850c | 3901 | (modify-phases %standard-phases |
e46bf223 JMSG |
3902 | (add-after 'unpack 'fix-libxcb-path |
3903 | (lambda* (#:key inputs #:allow-other-keys) | |
3904 | (let ((libxcb (assoc-ref inputs "libxcb"))) | |
3905 | (substitute* '("xcffib/__init__.py") | |
3906 | (("^soname = \"") (string-append "soname = \"" libxcb "/lib/"))) | |
3907 | #t))) | |
c8cd850c MB |
3908 | (add-after 'install 'install-doc |
3909 | (lambda* (#:key outputs #:allow-other-keys) | |
3910 | (let ((doc (string-append (assoc-ref outputs "out") "/share" | |
3911 | "/doc/" ,name "-" ,version))) | |
3912 | (mkdir-p doc) | |
3913 | (copy-file "README.md" | |
3914 | (string-append doc "/README.md")) | |
3915 | #t)))))) | |
6fa14469 FB |
3916 | (home-page "https://github.com/tych0/xcffib") |
3917 | (synopsis "XCB Python bindings") | |
3918 | (description | |
3919 | "Xcffib is a replacement for xpyb, an XCB Python bindings. It adds | |
3920 | support for Python 3 and PyPy. It is based on cffi.") | |
bd3fa666 | 3921 | (license license:expat))) |
6fa14469 FB |
3922 | |
3923 | (define-public python2-xcffib | |
3924 | (package-with-python2 python-xcffib)) | |
3925 | ||
9e099723 FB |
3926 | (define-public python-cairocffi |
3927 | (package | |
3928 | (name "python-cairocffi") | |
80f78e8f | 3929 | (version "0.8.0") |
9e099723 FB |
3930 | (source |
3931 | (origin | |
3932 | (method url-fetch) | |
3933 | ;; The archive on pypi is missing the 'utils' directory! | |
3015d455 | 3934 | (uri (string-append "https://github.com/Kozea/cairocffi/archive/v" |
9e099723 | 3935 | version ".tar.gz")) |
f586c877 | 3936 | (file-name (string-append name "-" version ".tar.gz")) |
9e099723 FB |
3937 | (sha256 |
3938 | (base32 | |
80f78e8f | 3939 | "1rk2dvy3fxrga6bvvxc2fi5lbaynm5h4a0w0aaxyn3bc77rszjg9")))) |
9e099723 FB |
3940 | (build-system python-build-system) |
3941 | (outputs '("out" "doc")) | |
3942 | (inputs | |
3943 | `(("gdk-pixbuf" ,gdk-pixbuf) | |
3944 | ("cairo" ,cairo))) | |
3945 | (native-inputs | |
3946 | `(("pkg-config" ,pkg-config) | |
3947 | ("python-sphinx" ,python-sphinx) | |
f3b98f4f | 3948 | ("python-docutils" ,python-docutils))) |
9e099723 FB |
3949 | (propagated-inputs |
3950 | `(("python-xcffib" ,python-xcffib))) ; used at run time | |
3951 | (arguments | |
a792e1aa MB |
3952 | `(;; FIXME: Tests cannot find 'libcairo.so.2'. |
3953 | #:tests? #f | |
3954 | #:phases | |
6734c7ba MB |
3955 | (modify-phases %standard-phases |
3956 | (add-after 'install 'install-doc | |
3957 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
3958 | (let* ((data (string-append (assoc-ref outputs "doc") "/share")) | |
3959 | (doc (string-append data "/doc/" ,name "-" ,version)) | |
3960 | (html (string-append doc "/html"))) | |
3961 | (setenv "LD_LIBRARY_PATH" | |
3962 | (string-append (assoc-ref inputs "cairo") "/lib" ":" | |
3963 | (assoc-ref inputs "gdk-pixbuf") "/lib")) | |
3964 | (setenv "LANG" "en_US.UTF-8") | |
3965 | (mkdir-p html) | |
3966 | (for-each (lambda (file) | |
3967 | (copy-file (string-append "." file) | |
3968 | (string-append doc file))) | |
3969 | '("/README.rst" "/CHANGES" "/LICENSE")) | |
3970 | (system* "python" "setup.py" "build_sphinx") | |
3971 | (copy-recursively "docs/_build/html" html) | |
3972 | #t)))))) | |
3015d455 | 3973 | (home-page "https://github.com/Kozea/cairocffi") |
9e099723 FB |
3974 | (synopsis "Python bindings and object-oriented API for Cairo") |
3975 | (description | |
3976 | "Cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of | |
3977 | Python bindings and object-oriented API for cairo. Cairo is a 2D vector | |
3978 | graphics library with support for multiple backends including image buffers, | |
3979 | PNG, PostScript, PDF, and SVG file output.") | |
3f641af0 | 3980 | (license license:bsd-3))) |
9e099723 FB |
3981 | |
3982 | (define-public python2-cairocffi | |
3983 | (package-with-python2 python-cairocffi)) | |
3984 | ||
3cff95cb RW |
3985 | (define-public python-decorator |
3986 | (package | |
3987 | (name "python-decorator") | |
e55c46b8 | 3988 | (version "4.1.2") |
3cff95cb RW |
3989 | (source |
3990 | (origin | |
3991 | (method url-fetch) | |
e21338be | 3992 | (uri (pypi-uri "decorator" version)) |
3cff95cb | 3993 | (sha256 |
e55c46b8 | 3994 | (base32 "1d8npb11kxyi36mrvjdpcjij76l5zfyrz2f820brf0l0rcw4vdkw")))) |
3cff95cb RW |
3995 | (build-system python-build-system) |
3996 | (arguments '(#:tests? #f)) ; no test target | |
eb6e2e81 | 3997 | (home-page "https://pypi.python.org/pypi/decorator/") |
3cff95cb RW |
3998 | (synopsis "Python module to simplify usage of decorators") |
3999 | (description | |
4000 | "The aim of the decorator module is to simplify the usage of decorators | |
4001 | for the average programmer, and to popularize decorators usage giving examples | |
4002 | of useful decorators, such as memoize, tracing, redirecting_stdout, locked, | |
4003 | etc. The core of this module is a decorator factory.") | |
4004 | (license license:expat))) | |
4005 | ||
4006 | (define-public python2-decorator | |
4007 | (package-with-python2 python-decorator)) | |
4008 | ||
2c0499ad RW |
4009 | (define-public python-drmaa |
4010 | (package | |
4011 | (name "python-drmaa") | |
7c427932 | 4012 | (version "0.7.7") |
2c0499ad RW |
4013 | (source |
4014 | (origin | |
4015 | (method url-fetch) | |
d92621cf | 4016 | (uri (pypi-uri "drmaa" version)) |
2c0499ad | 4017 | (sha256 |
7c427932 | 4018 | (base32 "0xzqriqyvk5b8hszbavsyxd29wm3sxirm8zvvdm73rs2iq7w4hkx")))) |
2c0499ad RW |
4019 | (build-system python-build-system) |
4020 | ;; The test suite requires libdrmaa which is provided by the cluster | |
4021 | ;; environment. At runtime the environment variable DRMAA_LIBRARY_PATH | |
4022 | ;; should be set to the path of the libdrmaa library. | |
4023 | (arguments '(#:tests? #f)) | |
4024 | (native-inputs | |
f3b98f4f | 4025 | `(("python-nose" ,python-nose))) |
2c0499ad RW |
4026 | (home-page "https://pypi.python.org/pypi/drmaa") |
4027 | (synopsis "Python bindings for the DRMAA library") | |
4028 | (description | |
4029 | "A Python package for Distributed Resource Management (DRM) job | |
4030 | submission and control. This package is an implementation of the DRMAA 1.0 | |
4031 | Python language binding specification.") | |
3f641af0 | 4032 | (license license:bsd-3))) |
2c0499ad RW |
4033 | |
4034 | (define-public python2-drmaa | |
4035 | (package-with-python2 python-drmaa)) | |
4036 | ||
a70b03d4 TD |
4037 | (define-public python-grako |
4038 | (package | |
4039 | (name "python-grako") | |
4040 | (version "3.99.9") | |
4041 | (source | |
4042 | (origin | |
4043 | (method url-fetch) | |
4044 | (uri | |
4045 | (pypi-uri "grako" version ".zip")) | |
4046 | (sha256 | |
4047 | (base32 | |
4048 | "0r63i68wcnv63rfjkasq1ah81frz61a6mzbcnaxhrkdpx84p7hzw")))) | |
4049 | (build-system python-build-system) | |
4050 | (arguments '(#:tests? #f)) ; Test file 'grako.ebnf' is missing from archive. | |
4051 | (native-inputs | |
4052 | `(("unzip" ,unzip) | |
4053 | ("python-pytest" ,python-pytest-3.0) | |
4054 | ("python-pytest-runner" ,python-pytest-runner))) | |
4055 | (home-page "https://bitbucket.org/neogeny/grako") | |
4056 | (synopsis "EBNF parser generator") | |
4057 | (description | |
4058 | "Grako takes a grammar in a variation of EBNF as input, and outputs a | |
4059 | memoizing PEG/Packrat parser in Python.") | |
4060 | (license license:bsd-3))) | |
4061 | ||
4062 | (define-public python2-grako | |
4063 | (package-with-python2 python-grako)) | |
4064 | ||
d05c6da0 RW |
4065 | (define-public python-gridmap |
4066 | (package | |
4067 | (name "python-gridmap") | |
4068 | (version "0.13.0") | |
4069 | (source | |
4070 | (origin | |
4071 | (method url-fetch) | |
4072 | (uri (string-append | |
4073 | "https://github.com/pygridtools/gridmap/archive/v" | |
4074 | version ".tar.gz")) | |
4075 | (file-name (string-append name "-" version ".tar.gz")) | |
4076 | (sha256 | |
4077 | (base32 "1gzjg2k6f14i1msm2b0ax8d9ds1hvk6qd5nlaivg8m4cxqp4cp1x")))) | |
4078 | (build-system python-build-system) | |
ad348f9f MB |
4079 | (arguments |
4080 | '(#:tests? #f)) ; FIXME: Requires python-cherrypy. | |
f22efa01 | 4081 | (propagated-inputs |
d05c6da0 RW |
4082 | `(("python-psutil" ,python-psutil) |
4083 | ("python-drmaa" ,python-drmaa) | |
4084 | ("python-pyzmq" ,python-pyzmq))) | |
d05c6da0 RW |
4085 | (home-page "https://github.com/pygridtools/gridmap") |
4086 | (synopsis "Create jobs on a cluster directly from Python") | |
4087 | (description | |
4088 | "Gridmap is a Python package to allow you to easily create jobs on the | |
4089 | cluster directly from Python. You can directly map Python functions onto the | |
4090 | cluster without needing to write any wrapper code yourself.") | |
3f641af0 | 4091 | (license license:gpl3+))) |
d05c6da0 RW |
4092 | |
4093 | (define-public python2-gridmap | |
4094 | (package-with-python2 python-gridmap)) | |
4095 | ||
84342e2f SR |
4096 | (define-public python-honcho |
4097 | (package | |
4098 | (name "python-honcho") | |
4099 | (version "1.0.1") | |
4100 | (source | |
4101 | (origin | |
4102 | (method url-fetch) | |
4103 | (uri (string-append | |
4104 | "https://github.com/nickstenning/honcho/archive/v" | |
4105 | version ".tar.gz")) | |
4106 | (file-name (string-append name "-" version ".tar.gz")) | |
4107 | (sha256 | |
4108 | (base32 "0zizn61n5z5hq421hkypk9pw8s6fpxw30f4hsg7k4ivwzy3gjw9j")))) | |
4109 | (build-system python-build-system) | |
4110 | (native-inputs | |
4111 | `(("python-pytest" ,python-pytest-3.0) | |
4112 | ("python-mock" ,python-mock) | |
4113 | ("python-tox" ,python-tox) | |
4114 | ("which" ,which))) ;for tests | |
4115 | (propagated-inputs | |
4116 | `(("python-jinja2" ,python-jinja2))) | |
4117 | (arguments | |
4118 | `(#:phases | |
4119 | (modify-phases %standard-phases | |
4120 | (delete 'check) | |
4121 | (add-after 'install 'check | |
4122 | (lambda* (#:key outputs inputs #:allow-other-keys) | |
4123 | ;; fix honcho path in testsuite | |
4124 | (substitute* "tests/conftest.py" | |
4125 | (("'honcho'") (string-append "'" (assoc-ref outputs "out") | |
4126 | "/bin/honcho" "'"))) | |
4127 | ;; It's easier to run tests after install. | |
4128 | ;; Make installed package available for running the tests | |
4129 | (add-installed-pythonpath inputs outputs) | |
4130 | (zero? (system* "py.test" "-v"))))))) | |
4131 | (home-page "https://github.com/nickstenning/honcho") | |
4132 | (synopsis "Manage Procfile-based applications") | |
4133 | (description | |
4134 | "A Procfile is a file which describes how to run an application | |
4135 | consisting of serveral processes. honcho starts all listed processes. | |
4136 | The output of all running processes is collected by honcho and | |
4137 | displayed.") | |
4138 | (license license:expat))) | |
4139 | ||
4140 | (define-public python2-honcho | |
4141 | (package-with-python2 python-honcho)) | |
4142 | ||
cb6d5c54 RW |
4143 | (define-public python-pexpect |
4144 | (package | |
4145 | (name "python-pexpect") | |
ed118043 | 4146 | (version "4.2.1") |
cb6d5c54 RW |
4147 | (source |
4148 | (origin | |
4149 | (method url-fetch) | |
ed118043 | 4150 | (uri (pypi-uri "pexpect" version)) |
cb6d5c54 | 4151 | (sha256 |
ed118043 | 4152 | (base32 "14ls7k99pwvl21zqv65kzrhccv50j89m5ij1hf0slmsvlxjj84rx")))) |
cb6d5c54 RW |
4153 | (build-system python-build-system) |
4154 | (arguments | |
4155 | `(#:phases | |
4156 | (modify-phases %standard-phases | |
ed118043 MB |
4157 | (add-before 'check 'prepare-tests |
4158 | (lambda _ | |
4159 | (substitute* (find-files "tests") | |
4160 | (("/bin/ls") (which "ls")) | |
4161 | (("/bin/echo") (which "echo")) | |
4162 | (("/bin/which") (which "which")) | |
4163 | ;; Many tests try to use the /bin directory which | |
4164 | ;; is not present in the build environment. | |
4165 | ;; Use one that's non-empty and unlikely to change. | |
4166 | (("/bin'") "/dev'")) | |
4167 | ;; XXX: Socket connection test gets "Connection reset by peer". | |
4168 | ;; Why does it not work? Delete for now. | |
4169 | (delete-file "tests/test_socket.py") | |
4170 | #t)) | |
3ee9355e | 4171 | (replace 'check (lambda _ (zero? (system* "nosetests" "-v"))))))) |
cb6d5c54 | 4172 | (native-inputs |
ed118043 | 4173 | `(("python-nose" ,python-nose) |
350a3084 | 4174 | ("python-pytest" ,python-pytest-3.0) |
ed118043 | 4175 | ("man-db" ,man-db) |
dc4f697f LC |
4176 | ("which" ,which) |
4177 | ("bash-full" ,bash))) ;full Bash for 'test_replwrap.py' | |
ed118043 MB |
4178 | (propagated-inputs |
4179 | `(("python-ptyprocess" ,python-ptyprocess))) | |
cb6d5c54 RW |
4180 | (home-page "http://pexpect.readthedocs.org/") |
4181 | (synopsis "Controlling interactive console applications") | |
4182 | (description | |
4183 | "Pexpect is a pure Python module for spawning child applications; | |
4184 | controlling them; and responding to expected patterns in their output. | |
4185 | Pexpect works like Don Libes’ Expect. Pexpect allows your script to spawn a | |
4186 | child application and control it as if a human were typing commands.") | |
3f641af0 | 4187 | (license license:isc))) |
cb6d5c54 RW |
4188 | |
4189 | (define-public python2-pexpect | |
4190 | (package-with-python2 python-pexpect)) | |
4191 | ||
229ad120 RW |
4192 | (define-public python-setuptools-scm |
4193 | (package | |
4194 | (name "python-setuptools-scm") | |
5b1f31ff | 4195 | (version "1.15.0") |
229ad120 RW |
4196 | (source (origin |
4197 | (method url-fetch) | |
383af6b0 | 4198 | (uri (pypi-uri "setuptools_scm" version)) |
229ad120 RW |
4199 | (sha256 |
4200 | (base32 | |
5b1f31ff | 4201 | "0bwyc5markib0i7i2qlyhdzxhiywzxbkfiapldma8m91m82jvwfs")))) |
229ad120 RW |
4202 | (build-system python-build-system) |
4203 | (home-page "https://github.com/pypa/setuptools_scm/") | |
4204 | (synopsis "Manage Python package versions in SCM metadata") | |
4205 | (description | |
383af6b0 | 4206 | "Setuptools_scm handles managing your Python package versions in |
229ad120 RW |
4207 | @dfn{software configuration management} (SCM) metadata instead of declaring |
4208 | them as the version argument or in a SCM managed file.") | |
4209 | (license license:expat))) | |
4210 | ||
4211 | (define-public python2-setuptools-scm | |
4212 | (package-with-python2 python-setuptools-scm)) | |
4213 | ||
b74270ee RW |
4214 | (define-public python-pathpy |
4215 | (package | |
4216 | (name "python-pathpy") | |
4217 | (version "8.1.1") | |
4218 | (source | |
4219 | (origin | |
4220 | (method url-fetch) | |
4221 | (uri (string-append "https://pypi.python.org/packages/source/p/" | |
4222 | "path.py/path.py-" version ".tar.gz")) | |
4223 | (sha256 | |
4224 | (base32 "1p8s1l2vfkqhqxdhqlj0g1jjw4f1as2frr35sjcpjjpd5a89y41f")))) | |
2887700e | 4225 | (outputs '("out" "doc")) |
b74270ee RW |
4226 | (build-system python-build-system) |
4227 | (propagated-inputs | |
4228 | `(("python-appdirs" ,python-appdirs))) | |
4229 | (native-inputs | |
f3b98f4f | 4230 | `(("python-setuptools-scm" ,python-setuptools-scm) |
2887700e HG |
4231 | ("python-sphinx" ,python-sphinx) |
4232 | ("python-rst.linker" ,python-rst.linker) | |
b74270ee RW |
4233 | ("python-pytest" ,python-pytest) |
4234 | ("python-pytest-runner" ,python-pytest-runner))) | |
2887700e HG |
4235 | (arguments |
4236 | `(#:phases | |
4237 | (modify-phases %standard-phases | |
4238 | (add-after 'build 'build-doc | |
4239 | (lambda _ | |
4240 | (setenv "LANG" "en_US.UTF-8") | |
4241 | (zero? (system* "python" "setup.py" "build_sphinx")))) | |
4242 | (add-after 'install 'install-doc | |
4243 | (lambda* (#:key outputs #:allow-other-keys) | |
4244 | (let* ((data (string-append (assoc-ref outputs "doc") "/share")) | |
4245 | (doc (string-append data "/doc/" ,name "-" ,version)) | |
4246 | (html (string-append doc "/html"))) | |
4247 | (mkdir-p html) | |
4248 | (for-each (lambda (file) | |
4249 | (copy-file file (string-append doc "/" file))) | |
4250 | '("README.rst" "CHANGES.rst")) | |
4251 | (copy-recursively "build/sphinx/html" html))))))) | |
7bf837fd | 4252 | (home-page "https://github.com/jaraco/path.py") |
b74270ee RW |
4253 | (synopsis "Python module wrapper for built-in os.path") |
4254 | (description | |
4255 | "@code{path.py} implements path objects as first-class entities, allowing | |
4256 | common operations on files to be invoked on those path objects directly.") | |
4257 | (license license:expat))) | |
4258 | ||
4259 | (define-public python2-pathpy | |
4260 | (package-with-python2 python-pathpy)) | |
4261 | ||
cd6e5189 RW |
4262 | (define-public python-simplegeneric |
4263 | (package | |
4264 | (name "python-simplegeneric") | |
4265 | (version "0.8.1") | |
4266 | (source | |
4267 | (origin | |
4268 | (method url-fetch) | |
4269 | (uri (string-append "https://pypi.python.org/packages/source/s/" | |
4270 | "simplegeneric/simplegeneric-" version ".zip")) | |
4271 | (sha256 | |
4272 | (base32 "0wwi1c6md4vkbcsfsf8dklf3vr4mcdj4mpxkanwgb6jb1432x5yw")))) | |
4273 | (build-system python-build-system) | |
4274 | (native-inputs | |
f3b98f4f | 4275 | `(("unzip" ,unzip))) |
cd6e5189 RW |
4276 | (home-page "http://cheeseshop.python.org/pypi/simplegeneric") |
4277 | (synopsis "Python module for simple generic functions") | |
4278 | (description | |
4279 | "The simplegeneric module lets you define simple single-dispatch generic | |
4280 | functions, akin to Python’s built-in generic functions like @code{len()}, | |
4281 | @code{iter()} and so on. However, instead of using specially-named methods, | |
4282 | these generic functions use simple lookup tables, akin to those used by | |
4283 | e.g. @code{pickle.dump()} and other generic functions found in the Python | |
4284 | standard library.") | |
3f641af0 | 4285 | (license license:zpl2.1))) |
cd6e5189 RW |
4286 | |
4287 | (define-public python2-simplegeneric | |
4288 | (package-with-python2 python-simplegeneric)) | |
4289 | ||
ddc7d8ed | 4290 | (define-public python-ipython-genutils |
c4abbac3 | 4291 | ;; TODO: This package is retired, check if can be removed, see description. |
ddc7d8ed RW |
4292 | (package |
4293 | (name "python-ipython-genutils") | |
4294 | (version "0.1.0") | |
4295 | (source | |
4296 | (origin | |
4297 | (method url-fetch) | |
4298 | (uri (string-append "https://pypi.python.org/packages/source/i/" | |
4299 | "ipython_genutils/ipython_genutils-" | |
4300 | version ".tar.gz")) | |
4301 | (sha256 | |
4302 | (base32 "19l2pp1c64ansr89l3cqh19jdi2ixhssdzx0vz4n6r52a6i281is")))) | |
4303 | (build-system python-build-system) | |
4304 | (arguments `(#:tests? #f)) ; no tests | |
3ca1545b | 4305 | (home-page "https://ipython.org") |
ddc7d8ed RW |
4306 | (synopsis "Vestigial utilities from IPython") |
4307 | (description | |
c4abbac3 HG |
4308 | "This package provides retired utilities from IPython. No packages |
4309 | outside IPython/Jupyter should depend on it. | |
4310 | ||
4311 | This package shouldn't exist. It contains some common utilities shared by | |
4312 | Jupyter and IPython projects during The Big Split. As soon as possible, those | |
4313 | packages will remove their dependency on this, and this package will go | |
4314 | away.") | |
3f641af0 | 4315 | (license license:bsd-3))) |
ddc7d8ed RW |
4316 | |
4317 | (define-public python2-ipython-genutils | |
4318 | (package-with-python2 python-ipython-genutils)) | |
4319 | ||
2b10eb48 RW |
4320 | (define-public python-traitlets |
4321 | (package | |
4322 | (name "python-traitlets") | |
a5ba1481 | 4323 | (version "4.2.0") |
2b10eb48 RW |
4324 | (source |
4325 | (origin | |
4326 | (method url-fetch) | |
cc0c4fde | 4327 | (uri (pypi-uri "traitlets" version)) |
2b10eb48 RW |
4328 | (sha256 |
4329 | (base32 | |
a5ba1481 | 4330 | "1afy08sa5n9gnkvh3da49c16zkyv598vchv0p1hp7zzjy8895hz4")))) |
2b10eb48 RW |
4331 | (build-system python-build-system) |
4332 | (arguments | |
4333 | `(#:phases | |
4334 | (modify-phases %standard-phases | |
4335 | (replace 'check (lambda _ (zero? (system* "nosetests"))))))) | |
4336 | (propagated-inputs | |
4337 | `(("python-ipython-genutils" ,python-ipython-genutils) | |
4338 | ("python-decorator" ,python-decorator))) | |
4339 | (native-inputs | |
cc0c4fde EF |
4340 | `(("python-mock" ,python-mock) |
4341 | ("python-nose" ,python-nose))) | |
3ca1545b | 4342 | (home-page "https://ipython.org") |
2b10eb48 RW |
4343 | (synopsis "Configuration system for Python applications") |
4344 | (description | |
4345 | "Traitlets is a framework that lets Python classes have attributes with | |
4346 | type checking, dynamically calculated default values, and ‘on change’ | |
4347 | callbacks. The package also includes a mechanism to use traitlets for | |
4348 | configuration, loading values from files or from command line arguments. This | |
4349 | is a distinct layer on top of traitlets, so you can use traitlets in your code | |
4350 | without using the configuration machinery.") | |
3f641af0 | 4351 | (license license:bsd-3))) |
2b10eb48 RW |
4352 | |
4353 | (define-public python2-traitlets | |
4354 | (package-with-python2 python-traitlets)) | |
4355 | ||
4263b06f RW |
4356 | (define-public python-jupyter-core |
4357 | (package | |
4358 | (name "python-jupyter-core") | |
45cc957c | 4359 | (version "4.2.1") |
4263b06f RW |
4360 | (source |
4361 | (origin | |
4362 | (method url-fetch) | |
4363 | (uri (string-append (pypi-uri "jupyter_core" version))) | |
4364 | (sha256 | |
4365 | (base32 | |
45cc957c | 4366 | "1cy7inv218dgh4m1fbzbsiqpz733ylgjrj62jxqpfzs3r2cm7ic9")))) |
4263b06f RW |
4367 | (build-system python-build-system) |
4368 | ;; FIXME: not sure how to run the tests | |
4369 | (arguments `(#:tests? #f)) | |
4370 | (propagated-inputs | |
4371 | `(("python-traitlets" ,python-traitlets))) | |
4372 | (home-page "http://jupyter.org/") | |
4373 | (synopsis "Jupyter base package") | |
4374 | (description | |
4375 | "Jupyter core is the base package on which Jupyter projects rely.") | |
4376 | (license license:bsd-3))) | |
4377 | ||
4378 | (define-public python2-jupyter-core | |
4379 | (package-with-python2 python-jupyter-core)) | |
4380 | ||
9ff01f2d RW |
4381 | (define-public python-jupyter-client |
4382 | (package | |
4383 | (name "python-jupyter-client") | |
4384 | (version "4.4.0") | |
4385 | (source | |
4386 | (origin | |
4387 | (method url-fetch) | |
4388 | (uri (pypi-uri "jupyter_client" version)) | |
4389 | (sha256 | |
4390 | (base32 | |
4391 | "1vjjrpjw7k5sh982pbjnslv7byfbfazjw9g92jvs7dz5qbx556n9")))) | |
4392 | (build-system python-build-system) | |
4393 | ;; Tests fail because of missing native python kernel which I assume is | |
4394 | ;; provided by the ipython package, which we cannot use because it would | |
4395 | ;; cause a dependency cycle. | |
4396 | (arguments `(#:tests? #f)) | |
4397 | (propagated-inputs | |
4398 | `(("python-pyzmq" ,python-pyzmq) | |
4399 | ("python-traitlets" ,python-traitlets) | |
4400 | ("python-jupyter-core" ,python-jupyter-core))) | |
4401 | (home-page "http://jupyter.org/") | |
4402 | (synopsis "Jupyter protocol implementation and client libraries") | |
4403 | (description | |
4404 | "The @code{jupyter_client} package contains the reference implementation | |
4405 | of the Jupyter protocol. It also provides client and kernel management APIs | |
4406 | for working with kernels, and the @code{jupyter kernelspec} entrypoint for | |
4407 | installing @code{kernelspec}s for use with Jupyter frontends.") | |
4408 | (license license:bsd-3))) | |
4409 | ||
4410 | (define-public python2-jupyter-client | |
4411 | (package-with-python2 python-jupyter-client)) | |
4412 | ||
ab526102 RW |
4413 | (define-public python-ipykernel |
4414 | (package | |
4415 | (name "python-ipykernel") | |
f165648e | 4416 | (version "4.5.2") |
ab526102 RW |
4417 | (source |
4418 | (origin | |
4419 | (method url-fetch) | |
4420 | (uri (pypi-uri "ipykernel" version)) | |
4421 | (sha256 | |
f165648e | 4422 | (base32 "0qllv0k6zzv1r1cj1x2ygxmlrrqhbslzj8rc6r6fg3kc1rgz4m2s")))) |
ab526102 RW |
4423 | (build-system python-build-system) |
4424 | ;; The tests load a submodule of IPython. However, IPython itself depends | |
4425 | ;; on ipykernel. | |
4426 | (arguments `(#:tests? #f)) | |
4427 | (propagated-inputs | |
4428 | ;; imported at runtime during connect | |
4429 | `(("python-jupyter-client" ,python-jupyter-client))) | |
3ca1545b | 4430 | (home-page "https://ipython.org") |
ab526102 RW |
4431 | (synopsis "IPython Kernel for Jupyter") |
4432 | (description | |
4433 | "This package provides the IPython kernel for Jupyter.") | |
4434 | (license license:bsd-3))) | |
4435 | ||
4436 | (define-public python2-ipykernel | |
4437 | (package-with-python2 python-ipykernel)) | |
4438 | ||
ae1ab9fe FB |
4439 | (define-public python-ipython |
4440 | (package | |
4441 | (name "python-ipython") | |
80c3f4d6 | 4442 | (version "5.3.0") |
ae1ab9fe FB |
4443 | (source |
4444 | (origin | |
fceac880 | 4445 | (method url-fetch) |
accd5f99 | 4446 | (uri (pypi-uri "ipython" version ".tar.gz")) |
fceac880 | 4447 | (sha256 |
80c3f4d6 | 4448 | (base32 "079wyjir4a9qx6kvx096b1asm63djbidk65z3ykcbnlngmg62pmz")))) |
ae1ab9fe FB |
4449 | (build-system python-build-system) |
4450 | (outputs '("out" "doc")) | |
3a0b1b9a FB |
4451 | (propagated-inputs |
4452 | `(("python-pyzmq" ,python-pyzmq) | |
fb25d348 | 4453 | ("python-prompt-toolkit" ,python-prompt-toolkit) |
accd5f99 | 4454 | ("python-terminado" ,python-terminado) |
ae1ab9fe | 4455 | ("python-matplotlib" ,python-matplotlib) |
5d26e542 | 4456 | ("python-numpy" ,python-numpy) |
ae1ab9fe | 4457 | ("python-numpydoc" ,python-numpydoc) |
3a0b1b9a | 4458 | ("python-jinja2" ,python-jinja2) |
ee8aab1f CB |
4459 | ("python-jupyter-console" |
4460 | ;; The python-ipython and python-jupyter-console require each | |
4461 | ;; other. To get the functionality in both packages working, strip | |
4462 | ;; down the python-jupyter-console package when using it as an input | |
4463 | ;; to python-ipython. | |
4464 | ,python-jupyter-console-minimal) | |
3a0b1b9a | 4465 | ("python-mistune" ,python-mistune) |
accd5f99 RW |
4466 | ("python-pexpect" ,python-pexpect) |
4467 | ("python-pickleshare" ,python-pickleshare) | |
4468 | ("python-simplegeneric" ,python-simplegeneric) | |
3a0b1b9a | 4469 | ("python-jsonschema" ,python-jsonschema) |
accd5f99 RW |
4470 | ("python-traitlets" ,python-traitlets) |
4471 | ("python-ipykernel" ,python-ipykernel) | |
fb25d348 | 4472 | ("python-nbformat" ,python-nbformat) |
accd5f99 RW |
4473 | ("python-pygments" ,python-pygments))) |
4474 | (inputs | |
4475 | `(("readline" ,readline) | |
4476 | ("which" ,which))) | |
ae1ab9fe | 4477 | (native-inputs |
fb25d348 TD |
4478 | `(("graphviz" ,graphviz) |
4479 | ("pkg-config" ,pkg-config) | |
accd5f99 RW |
4480 | ("python-requests" ,python-requests) ;; for tests |
4481 | ("python-testpath" ,python-testpath) | |
4482 | ("python-nose" ,python-nose) | |
ae1ab9fe | 4483 | ("python-sphinx" ,python-sphinx) |
fb25d348 | 4484 | ("python-shpinx-rtd-theme" ,python-sphinx-rtd-theme) |
2584beae RW |
4485 | ;; FIXME: It's possible that a smaller union would work just as well. |
4486 | ("texlive" ,(texlive-union (list texlive-fonts-amsfonts | |
4487 | texlive-fonts-ec | |
4488 | texlive-generic-ifxetex | |
4489 | texlive-generic-pdftex | |
4490 | texlive-latex-amsfonts | |
4491 | texlive-latex-capt-of | |
4492 | texlive-latex-cmap | |
4493 | texlive-latex-environ | |
4494 | texlive-latex-eqparbox | |
4495 | texlive-latex-etoolbox | |
4496 | texlive-latex-expdlist | |
4497 | texlive-latex-fancyhdr | |
4498 | texlive-latex-fancyvrb | |
4499 | texlive-latex-fncychap | |
4500 | texlive-latex-float | |
4501 | texlive-latex-framed | |
4502 | texlive-latex-geometry | |
4503 | texlive-latex-graphics | |
4504 | texlive-latex-hyperref | |
4505 | texlive-latex-mdwtools | |
4506 | texlive-latex-multirow | |
4507 | texlive-latex-oberdiek | |
4508 | texlive-latex-parskip | |
4509 | texlive-latex-preview | |
4510 | texlive-latex-tabulary | |
4511 | texlive-latex-threeparttable | |
4512 | texlive-latex-titlesec | |
4513 | texlive-latex-trimspaces | |
4514 | texlive-latex-ucs | |
4515 | texlive-latex-upquote | |
4516 | texlive-latex-url | |
4517 | texlive-latex-varwidth | |
4518 | texlive-latex-wrapfig))) | |
f3b98f4f | 4519 | ("texinfo" ,texinfo))) |
ae1ab9fe | 4520 | (arguments |
89b5c60e | 4521 | `(#:phases |
3a0b1b9a FB |
4522 | (modify-phases %standard-phases |
4523 | (add-after | |
4524 | 'install 'install-doc | |
4525 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
4526 | (let* ((data (string-append (assoc-ref outputs "doc") "/share")) | |
4527 | (doc (string-append data "/doc/" ,name "-" ,version)) | |
4528 | (html (string-append doc "/html")) | |
4529 | (man1 (string-append data "/man/man1")) | |
4530 | (info (string-append data "/info")) | |
fb25d348 TD |
4531 | (examples (string-append doc "/examples")) |
4532 | (python-arg (string-append "PYTHON=" (which "python")))) | |
afd3d931 | 4533 | (setenv "LANG" "en_US.utf8") |
eee5cd04 HG |
4534 | ;; Make installed package available for running the tests |
4535 | (add-installed-pythonpath inputs outputs) | |
3a0b1b9a | 4536 | (with-directory-excursion "docs" |
accd5f99 RW |
4537 | ;; FIXME: pdf fails to build |
4538 | ;;(system* "make" "pdf" "PAPER=a4") | |
fb25d348 TD |
4539 | (system* "make" python-arg "html") |
4540 | (system* "make" python-arg "info")) | |
3a0b1b9a FB |
4541 | (copy-recursively "docs/man" man1) |
4542 | (copy-recursively "examples" examples) | |
accd5f99 | 4543 | (copy-recursively "docs/build/html" html) |
3a0b1b9a FB |
4544 | ;; (copy-file "docs/build/latex/ipython.pdf" |
4545 | ;; (string-append doc "/ipython.pdf")) | |
4546 | (mkdir-p info) | |
4547 | (copy-file "docs/build/texinfo/ipython.info" | |
4548 | (string-append info "/ipython.info")) | |
4549 | (copy-file "COPYING.rst" (string-append doc "/COPYING.rst"))))) | |
4550 | ;; Tests can only be run after the library has been installed and not | |
4551 | ;; within the source directory. | |
4552 | (delete 'check) | |
4553 | (add-after | |
4554 | 'install 'check | |
eee5cd04 | 4555 | (lambda* (#:key inputs outputs tests? #:allow-other-keys) |
3a0b1b9a FB |
4556 | (if tests? |
4557 | (with-directory-excursion "/tmp" | |
eee5cd04 HG |
4558 | ;; Make installed package available for running the tests |
4559 | (add-installed-pythonpath inputs outputs) | |
3a0b1b9a FB |
4560 | (setenv "HOME" "/tmp/") ;; required by a test |
4561 | (zero? (system* (string-append (assoc-ref outputs "out") | |
4562 | "/bin/iptest")))) | |
4563 | #t))) | |
4564 | (add-before | |
4565 | 'install 'fix-tests | |
4566 | (lambda* (#:key inputs #:allow-other-keys) | |
4567 | (substitute* "./IPython/utils/_process_posix.py" | |
4568 | (("/usr/bin/env', 'which") (which "which"))) | |
4569 | (substitute* "./IPython/core/tests/test_inputtransformer.py" | |
4570 | (("#!/usr/bin/env python") | |
4571 | (string-append "#!" (which "python")))) | |
4572 | ;; Disable 1 failing test | |
4573 | (substitute* "./IPython/core/tests/test_magic.py" | |
4574 | (("def test_dirops\\(\\):" all) | |
4575 | (string-append "@dec.skipif(True)\n" all)))))))) | |
3ca1545b | 4576 | (home-page "https://ipython.org") |
ae1ab9fe FB |
4577 | (synopsis "IPython is a tool for interactive computing in Python") |
4578 | (description | |
4579 | "IPython provides a rich architecture for interactive computing with: | |
4580 | Powerful interactive shells, a browser-based notebook, support for interactive | |
4581 | data visualization, embeddable interpreters and tools for parallel | |
4582 | computing.") | |
135ba811 EF |
4583 | (license license:bsd-3) |
4584 | (properties `((python2-variant . ,(delay python2-ipython)))))) | |
ae1ab9fe FB |
4585 | |
4586 | (define-public python2-ipython | |
135ba811 | 4587 | (let ((ipython (package-with-python2 (strip-python2-variant python-ipython)))) |
3a0b1b9a FB |
4588 | (package |
4589 | (inherit ipython) | |
3a0b1b9a | 4590 | ;; FIXME: add pyreadline once available. |
fb25d348 TD |
4591 | (propagated-inputs |
4592 | `(("python2-backports-shutil-get-terminal-size" | |
4593 | ,python2-backports-shutil-get-terminal-size) | |
4594 | ("python2-pathlib2" ,python2-pathlib2) | |
4595 | ,@(package-propagated-inputs ipython))) | |
e62600fe | 4596 | (native-inputs |
135ba811 | 4597 | `(("python2-mock" ,python2-mock) |
77a6932a | 4598 | ,@(package-native-inputs ipython)))))) |
03411993 | 4599 | |
e99f4211 MW |
4600 | (define-public python-urwid |
4601 | (package | |
4602 | (name "python-urwid") | |
51ff41f6 | 4603 | (version "1.3.1") |
e99f4211 MW |
4604 | (source |
4605 | (origin | |
4606 | (method url-fetch) | |
b97c1bfd | 4607 | (uri (pypi-uri "urwid" version)) |
e99f4211 MW |
4608 | (sha256 |
4609 | (base32 | |
51ff41f6 | 4610 | "18cnd1wdjcas08x5qwa5ayw6jsfcn33w4d9f7q3s29fy6qzc1kng")))) |
e99f4211 | 4611 | (build-system python-build-system) |
b97c1bfd LF |
4612 | (arguments |
4613 | `(#:phases | |
4614 | (modify-phases %standard-phases | |
4615 | ;; Disable failing test. Bug filed upstream: | |
4616 | ;; https://github.com/wardi/urwid/issues/164 | |
51ff41f6 | 4617 | ;; TODO: check again for python-urwid > 1.3.1 or python > 3.4.3. |
b97c1bfd LF |
4618 | (add-after 'unpack 'disable-failing-test |
4619 | (lambda _ | |
4620 | (substitute* "urwid/tests/test_event_loops.py" | |
4621 | (("test_remove_watch_file") | |
4622 | "disable_remove_watch_file"))))))) | |
e99f4211 MW |
4623 | (home-page "http://urwid.org") |
4624 | (synopsis "Console user interface library for Python") | |
4625 | (description | |
4626 | "Urwid is a curses-based UI/widget library for Python. It includes many | |
4627 | features useful for text console applications.") | |
3f641af0 | 4628 | (license license:lgpl2.1+))) |
e99f4211 MW |
4629 | |
4630 | (define-public python2-urwid | |
e9379305 MC |
4631 | (let ((python2-urwid (package-with-python2 python-urwid))) |
4632 | (package | |
4633 | (inherit python2-urwid) | |
4634 | (arguments | |
4635 | (append | |
4fdab173 KK |
4636 | `(;; Explicitly using Python 2 is necessary due the argument list being |
4637 | ;; built from only the 'delete-test_vterm.py' phase and python-urwid's | |
4638 | ;; package arguments, which by default assumes the use of Python 3. | |
4639 | #:python ,python-2 | |
4640 | #:phases | |
e9379305 MC |
4641 | (modify-phases %standard-phases |
4642 | ;; Disable the vterm tests because of non-deterministic failures | |
4643 | ;; with Python 2. See https://github.com/urwid/urwid/issues/230. | |
4644 | (add-after 'unpack 'delete-test_vterm.py | |
4645 | (delete-file "urwid/tests/test_vterm.py")))) | |
4646 | (package-arguments python-urwid)))))) | |
d95a56c6 | 4647 | |
47d0b292 TS |
4648 | (define-public python-urwidtrees |
4649 | (package | |
4650 | (name "python-urwidtrees") | |
37ec4623 | 4651 | (version "1.0.2") |
47d0b292 TS |
4652 | (source |
4653 | (origin | |
4654 | (method url-fetch) | |
37ec4623 TS |
4655 | ;; package author intends on distributing via github rather than pypi: |
4656 | ;; https://github.com/pazz/alot/issues/877#issuecomment-230173331 | |
4657 | (uri (string-append "https://github.com/pazz/urwidtrees/archive/" | |
4658 | version ".tar.gz")) | |
4659 | (file-name (string-append name "-" version ".tar.gz")) | |
47d0b292 TS |
4660 | (sha256 |
4661 | (base32 | |
37ec4623 | 4662 | "0d30lyd3s2a97rhqfax5w9ssqds2z6aydqx3c6j2c2lk3cb4ngvh")))) |
47d0b292 TS |
4663 | (build-system python-build-system) |
4664 | (arguments | |
4665 | '(#:tests? #f)) ; no tests | |
f22efa01 | 4666 | (propagated-inputs `(("python-urwid" ,python-urwid))) |
47d0b292 TS |
4667 | (home-page "https://github.com/pazz/urwidtrees") |
4668 | (synopsis "Tree widgets for urwid") | |
4669 | (description "Urwidtrees is a Widget Container API for the @code{urwid} | |
4670 | toolkit. Use it to build trees of widgets.") | |
3f641af0 | 4671 | (license license:gpl3+))) |
47d0b292 TS |
4672 | |
4673 | (define-public python2-urwidtrees | |
4674 | (package-with-python2 python-urwidtrees)) | |
4675 | ||
d95a56c6 PAR |
4676 | (define-public python-dbus |
4677 | (package | |
4678 | (name "python-dbus") | |
4679 | (version "1.2.0") | |
4680 | (source | |
4681 | (origin | |
4682 | (method url-fetch) | |
4683 | (uri (string-append | |
5cc3096c | 4684 | "https://dbus.freedesktop.org/releases/dbus-python/dbus-python-" |
d95a56c6 PAR |
4685 | version ".tar.gz")) |
4686 | (sha256 | |
4687 | (base32 "1py62qir966lvdkngg0v8k1khsqxwk5m4s8nflpk1agk5f5nqb71")))) | |
4688 | (build-system gnu-build-system) | |
6717c879 SB |
4689 | (arguments |
4690 | '(#:phases | |
4691 | (modify-phases %standard-phases | |
4692 | (add-before | |
4693 | 'check 'pre-check | |
4694 | (lambda _ | |
4695 | ;; XXX: For the missing '/etc/machine-id'. | |
4696 | (substitute* "test/run-test.sh" | |
4697 | (("DBUS_FATAL_WARNINGS=1") | |
4698 | "DBUS_FATAL_WARNINGS=0")) | |
4699 | #t))))) | |
d95a56c6 PAR |
4700 | (native-inputs |
4701 | `(("pkg-config" ,pkg-config))) | |
4702 | (inputs | |
4703 | `(("python" ,python) | |
2e88d113 | 4704 | ("dbus-glib" ,dbus-glib))) |
d95a56c6 PAR |
4705 | (synopsis "Python bindings for D-bus") |
4706 | (description "python-dbus provides bindings for libdbus, the reference | |
4707 | implementation of D-Bus.") | |
4708 | (home-page "http://www.freedesktop.org/wiki/Software/DBusBindings/") | |
bd3fa666 | 4709 | (license license:expat))) |
b52af02b MW |
4710 | |
4711 | (define-public python2-dbus | |
4712 | (package (inherit python-dbus) | |
4713 | (name "python2-dbus") | |
4714 | (inputs `(("python" ,python-2) | |
4715 | ,@(alist-delete "python" | |
4716 | (package-inputs python-dbus) | |
4717 | equal?))) | |
4718 | ;; FIXME: on Python 2, the test_utf8 fails with: | |
4719 | ;; "ValueError: unichr() arg not in range(0x10000) (narrow Python build)" | |
4720 | (arguments `(#:tests? #f)))) | |
a6ac8332 | 4721 | |
26b307e2 AE |
4722 | (define-public python-lxml |
4723 | (package | |
4724 | (name "python-lxml") | |
2054b522 | 4725 | (version "3.8.0") |
26b307e2 AE |
4726 | (source |
4727 | (origin | |
4728 | (method url-fetch) | |
97bbc480 | 4729 | (uri (pypi-uri "lxml" version)) |
26b307e2 | 4730 | (sha256 |
d58a3203 | 4731 | (base32 |
2054b522 | 4732 | "15nvf6n285n282682qyw3wihsncb0x5amdhyi4b83bfa2nz74vvk")))) |
26b307e2 AE |
4733 | (build-system python-build-system) |
4734 | (inputs | |
4735 | `(("libxml2" ,libxml2) | |
f3b98f4f | 4736 | ("libxslt" ,libxslt))) |
26b307e2 AE |
4737 | (home-page "http://lxml.de/") |
4738 | (synopsis | |
4739 | "Python XML processing library") | |
4740 | (description | |
4741 | "The lxml XML toolkit is a Pythonic binding for the C libraries | |
4742 | libxml2 and libxslt.") | |
3f641af0 | 4743 | (license license:bsd-3))) ; and a few more, see LICENSES.txt |
26b307e2 AE |
4744 | |
4745 | (define-public python2-lxml | |
4746 | (package-with-python2 python-lxml)) | |
4ed20663 | 4747 | |
b32a1e47 CAW |
4748 | ;; beautifulsoup4 has a totally different namespace than 3.x, |
4749 | ;; and pypi seems to put it under its own name, so I guess we should too | |
4750 | (define-public python-beautifulsoup4 | |
4751 | (package | |
4752 | (name "python-beautifulsoup4") | |
80e8d851 | 4753 | (version "4.5.3") |
b32a1e47 CAW |
4754 | (source |
4755 | (origin | |
4756 | (method url-fetch) | |
4757 | (uri (pypi-uri "beautifulsoup4" version)) | |
4758 | (sha256 | |
4759 | (base32 | |
80e8d851 | 4760 | "0glaw1vyxnbp03fni7h5496n6iib0n5iim4gax1n0ngscs9s075j")))) |
b32a1e47 | 4761 | (build-system python-build-system) |
5f37f0b6 LF |
4762 | (arguments |
4763 | `(#:phases | |
4764 | (modify-phases %standard-phases | |
4765 | ;; The Python 2 source is the definitive source of beautifulsoup4. We | |
4766 | ;; must use this conversion script when building with Python 3. The | |
4767 | ;; conversion script also runs the tests. | |
4768 | ;; For more information, see the file 'convert-py3k' in the source | |
4769 | ;; distribution. | |
4770 | (replace 'check | |
4771 | (lambda _ (zero? (system* "./convert-py3k"))))))) | |
b32a1e47 | 4772 | (home-page |
9be5ecdf | 4773 | "https://www.crummy.com/software/BeautifulSoup/bs4/") |
b32a1e47 CAW |
4774 | (synopsis |
4775 | "Python screen-scraping library") | |
4776 | (description | |
4777 | "Beautiful Soup is a Python library designed for rapidly setting up | |
4778 | screen-scraping projects. It offers Pythonic idioms for navigating, | |
4779 | searching, and modifying a parse tree, providing a toolkit for | |
4780 | dissecting a document and extracting what you need. It automatically | |
4781 | converts incoming documents to Unicode and outgoing documents to UTF-8.") | |
ee94ca11 MB |
4782 | (license license:expat) |
4783 | (properties `((python2-variant . ,(delay python2-beautifulsoup4)))))) | |
b32a1e47 CAW |
4784 | |
4785 | (define-public python2-beautifulsoup4 | |
4786 | (package | |
4787 | (inherit (package-with-python2 | |
4788 | (strip-python2-variant python-beautifulsoup4))) | |
5f37f0b6 | 4789 | (arguments `(#:python ,python-2)))) |
b32a1e47 | 4790 | |
60357f99 AE |
4791 | (define-public python-netifaces |
4792 | (package | |
4793 | (name "python-netifaces") | |
4794 | (version "0.10.4") | |
4795 | (source | |
4796 | (origin | |
4797 | (method url-fetch) | |
4798 | (uri (string-append | |
4799 | "https://pypi.python.org/packages/source/n/netifaces/netifaces-" | |
4800 | version | |
4801 | ".tar.gz")) | |
4802 | (sha256 | |
4803 | (base32 | |
4804 | "1plw237a4zib4z8s62g0mrs8gm3kjfrp5sxh6bbk9nl3rdls2mln")))) | |
4805 | (build-system python-build-system) | |
60357f99 AE |
4806 | (home-page |
4807 | "https://bitbucket.org/al45tair/netifaces") | |
4808 | (synopsis | |
4809 | "Python module for portable network interface information") | |
4810 | (description | |
4811 | "Netifaces is a Python module providing information on network | |
4812 | interfaces in an easy and portable manner.") | |
4813 | (license license:expat))) | |
4814 | ||
4815 | (define-public python2-netifaces | |
4816 | (package-with-python2 python-netifaces)) | |
92cb152b | 4817 | |
32f77c04 RW |
4818 | (define-public python-networkx |
4819 | (package | |
4820 | (name "python-networkx") | |
a4d9609c | 4821 | (version "1.11") |
32f77c04 RW |
4822 | (source |
4823 | (origin | |
4824 | (method url-fetch) | |
a4d9609c | 4825 | (uri (pypi-uri "networkx" version)) |
32f77c04 | 4826 | (sha256 |
a4d9609c | 4827 | (base32 "1f74s56xb4ggixiq0vxyfxsfk8p20c7a099lpcf60izv1php03hd")))) |
32f77c04 RW |
4828 | (build-system python-build-system) |
4829 | ;; python-decorator is needed at runtime | |
4830 | (propagated-inputs | |
4831 | `(("python-decorator" ,python-decorator))) | |
4832 | (native-inputs | |
f3b98f4f | 4833 | `(("python-nose" ,python-nose))) |
32f77c04 RW |
4834 | (home-page "http://networkx.github.io/") |
4835 | (synopsis "Python module for creating and manipulating graphs and networks") | |
4836 | (description | |
4837 | "NetworkX is a Python package for the creation, manipulation, and study | |
4838 | of the structure, dynamics, and functions of complex networks.") | |
3f641af0 | 4839 | (license license:bsd-3))) |
32f77c04 RW |
4840 | |
4841 | (define-public python2-networkx | |
4842 | (package-with-python2 python-networkx)) | |
4843 | ||
75d342ff GB |
4844 | ;; Define new package, because the current version of python-colormath does |
4845 | ;; not build against 2.0. | |
4846 | (define-public python-networkx2 | |
4847 | (package (inherit python-networkx) | |
4848 | (name "python-networkx2") | |
4849 | (version "2.0") | |
4850 | (source | |
4851 | (origin | |
4852 | (method url-fetch) | |
4853 | (uri (pypi-uri "networkx" version ".zip")) | |
4854 | (sha256 | |
4855 | (base32 | |
4856 | "1ajl2jp8qry9nyjzzkqpy0vmsr14d23z1qk7y0vr5iwjbpvzhpyd")) | |
4857 | (patches | |
4858 | (search-patches "python-networkx2-reproducible-build.patch")))))) | |
4859 | ||
4860 | (define-public python2-networkx2 | |
4861 | (package-with-python2 python-networkx2)) | |
4862 | ||
92cb152b RW |
4863 | (define-public snakemake |
4864 | (package | |
4865 | (name "snakemake") | |
0215f94e | 4866 | (version "4.4.0") |
92cb152b RW |
4867 | (source |
4868 | (origin | |
4869 | (method url-fetch) | |
7b93d866 | 4870 | (uri (pypi-uri "snakemake" version)) |
92cb152b | 4871 | (sha256 |
0215f94e | 4872 | (base32 "0g0paia4z7w3srnqdmavq3hrb2x7qnpf81jx50njl0p7y4y0j8jv")))) |
92cb152b | 4873 | (build-system python-build-system) |
7b93d866 MB |
4874 | (arguments |
4875 | ;; TODO: Package missing test dependencies. | |
e61bc976 RW |
4876 | '(#:tests? #f |
4877 | #:phases | |
4878 | (modify-phases %standard-phases | |
4879 | ;; For cluster execution Snakemake will call Python. Since there is | |
4880 | ;; no suitable PYTHONPATH set, cluster execution will fail. We fix | |
4881 | ;; this by calling the snakemake wrapper instead. | |
4882 | (add-after 'unpack 'call-wrapper-not-wrapped-snakemake | |
4883 | (lambda* (#:key outputs #:allow-other-keys) | |
4884 | (substitute* "snakemake/executors.py" | |
4885 | (("\\{sys.executable\\} -m snakemake") | |
4886 | (string-append (assoc-ref outputs "out") | |
4887 | "/bin/snakemake"))) | |
4888 | #t))))) | |
4f9998c6 RW |
4889 | (propagated-inputs |
4890 | `(("python-wrapt" ,python-wrapt) | |
3414ce98 KM |
4891 | ("python-requests" ,python-requests) |
4892 | ("python-appdirs" ,python-appdirs) | |
4893 | ("python-configargparse" ,python-configargparse) | |
4894 | ("python-pyyaml" ,python-pyyaml) | |
4895 | ("python-ratelimiter" ,python-ratelimiter))) | |
7b93d866 | 4896 | (home-page "https://bitbucket.org/snakemake/snakemake/wiki/Home") |
92cb152b RW |
4897 | (synopsis "Python-based execution environment for make-like workflows") |
4898 | (description | |
4899 | "Snakemake aims to reduce the complexity of creating workflows by | |
4900 | providing a clean and modern domain specific specification language (DSL) in | |
4901 | Python style, together with a fast and comfortable execution environment.") | |
4902 | (license license:expat))) | |
a1920bc9 | 4903 | |
b3593688 | 4904 | (define-public python-pyqrcode |
4905 | (package | |
4906 | (name "python-pyqrcode") | |
4907 | (version "1.2.1") | |
4908 | (source | |
4909 | (origin | |
4910 | (method url-fetch) | |
4911 | (uri (pypi-uri "PyQRCode" version)) | |
4912 | (sha256 | |
4913 | (base32 | |
4914 | "1m9ln8k9v7dfbh1i81225hx5mdsh8mpf9g7r4wpbfmiyfcs7dgzx")))) | |
4915 | (build-system python-build-system) | |
4916 | (home-page | |
4917 | "https://github.com/mnooner256/pyqrcode") | |
4918 | (synopsis "QR code generator") | |
4919 | (description | |
4920 | "Pyqrcode is a QR code generator written purely in Python with | |
4921 | SVG, EPS, PNG and terminal output.") | |
4922 | (license license:bsd-3))) | |
4923 | ||
35de1fbd RW |
4924 | (define-public python-seaborn |
4925 | (package | |
4926 | (name "python-seaborn") | |
ccc18762 | 4927 | (version "0.7.1") |
35de1fbd RW |
4928 | (source |
4929 | (origin | |
4930 | (method url-fetch) | |
fc899d4f | 4931 | (uri (pypi-uri "seaborn" version)) |
35de1fbd | 4932 | (sha256 |
ccc18762 | 4933 | (base32 "0pawrqc3mxpwd5g9pvi9gba02637bh5c8ldpp8izfwpfn52469zs")))) |
35de1fbd | 4934 | (build-system python-build-system) |
6f976df6 MB |
4935 | (arguments |
4936 | '(#:tests? #f)) ; Tests requires a running X11 server. | |
35de1fbd RW |
4937 | (propagated-inputs |
4938 | `(("python-pandas" ,python-pandas) | |
4939 | ("python-matplotlib" ,python-matplotlib) | |
4940 | ("python-scipy" ,python-scipy))) | |
35de1fbd RW |
4941 | (home-page "http://stanford.edu/~mwaskom/software/seaborn/") |
4942 | (synopsis "Statistical data visualization") | |
4943 | (description | |
4944 | "Seaborn is a library for making attractive and informative statistical | |
4945 | graphics in Python. It is built on top of matplotlib and tightly integrated | |
4946 | with the PyData stack, including support for numpy and pandas data structures | |
4947 | and statistical routines from scipy and statsmodels.") | |
3f641af0 | 4948 | (license license:bsd-3) |
fc899d4f | 4949 | (properties `((python2-variant . ,(delay python2-seaborn)))))) |
35de1fbd RW |
4950 | |
4951 | (define-public python2-seaborn | |
fc899d4f EF |
4952 | (let ((base (package-with-python2 (strip-python2-variant python-seaborn)))) |
4953 | (package | |
4954 | (inherit base) | |
4955 | (propagated-inputs `(("python2-pytz" ,python2-pytz) | |
00e10c6e | 4956 | ,@(package-propagated-inputs base)))))) |
35de1fbd | 4957 | |
58a35665 MB |
4958 | (define-public python-mpmath |
4959 | (package | |
4960 | (name "python-mpmath") | |
4961 | (version "0.19") | |
4962 | (source (origin | |
4963 | (method url-fetch) | |
4964 | (uri (string-append "http://mpmath.org/files/mpmath-" | |
4965 | version ".tar.gz")) | |
4966 | (sha256 | |
4967 | (base32 | |
4968 | "08ijsr4ifrqv3cjc26mkw0dbvyygsa99in376hr4b96ddm1gdpb8")))) | |
4969 | (build-system python-build-system) | |
4970 | (arguments | |
4971 | '(#:phases | |
4972 | (modify-phases %standard-phases | |
4973 | (replace 'check | |
4974 | (lambda _ | |
4975 | (zero? | |
4976 | (system* "python" "mpmath/tests/runtests.py" "-local"))))))) | |
4977 | (home-page "http://mpmath.org") | |
4978 | (synopsis "Arbitrary-precision floating-point arithmetic in python") | |
4979 | (description | |
4980 | "@code{mpmath} can be used as an arbitrary-precision substitute for | |
4981 | Python's float/complex types and math/cmath modules, but also does much | |
4982 | more advanced mathematics.") | |
4983 | (license license:bsd-3))) | |
4984 | ||
4985 | (define-public python2-mpmath | |
4986 | (package-with-python2 python-mpmath)) | |
35de1fbd | 4987 | |
90fc547f RW |
4988 | (define-public python-sympy |
4989 | (package | |
4990 | (name "python-sympy") | |
e65acb31 | 4991 | (version "1.1.1") |
90fc547f RW |
4992 | (source |
4993 | (origin | |
4994 | (method url-fetch) | |
4995 | (uri (string-append | |
4996 | "https://github.com/sympy/sympy/releases/download/sympy-" | |
4997 | version "/sympy-" version ".tar.gz")) | |
4998 | (sha256 | |
e65acb31 | 4999 | (base32 "190n29sppw7g8ihilc5451y7jlfcaw56crqiqbf1jff43dlmfnxc")))) |
90fc547f | 5000 | (build-system python-build-system) |
52f622ef MB |
5001 | (propagated-inputs |
5002 | `(("python-mpmath" ,python-mpmath))) | |
90fc547f RW |
5003 | (home-page "http://www.sympy.org/") |
5004 | (synopsis "Python library for symbolic mathematics") | |
5005 | (description | |
5006 | "SymPy is a Python library for symbolic mathematics. It aims to become a | |
5007 | full-featured computer algebra system (CAS) while keeping the code as simple | |
5008 | as possible in order to be comprehensible and easily extensible.") | |
3f641af0 | 5009 | (license license:bsd-3))) |
90fc547f RW |
5010 | |
5011 | (define-public python2-sympy | |
5012 | (package-with-python2 python-sympy)) | |
5013 | ||
e8c9b010 SR |
5014 | (define-public python-q |
5015 | (package | |
5016 | (name "python-q") | |
5017 | (version "2.6") | |
5018 | (source | |
5019 | (origin | |
5020 | (method url-fetch) | |
5021 | (uri (pypi-uri "q" version)) | |
5022 | (sha256 | |
5023 | (base32 | |
5024 | "1mgfazh8fkizh6walra2zv885f3lcgr3nb02v1frfm4p8ddcy3yy")))) | |
5025 | (build-system python-build-system) | |
5026 | (home-page "https://github.com/zestyping/q") | |
5027 | (synopsis "Quick-and-dirty debugging output for tired programmers") | |
5028 | (description | |
5029 | "q is a Python module for \"print\" style of debugging Python code. It | |
5030 | provides convenient short API for print out of values, tracebacks, and | |
5031 | falling into the Python interpreter.") | |
f210e944 | 5032 | (license license:asl2.0))) |
e8c9b010 SR |
5033 | |
5034 | (define-public python2-q | |
f210e944 | 5035 | (package-with-python2 python-q)) |
e8c9b010 | 5036 | |
db62afa5 LC |
5037 | (define-public python2-xlib |
5038 | (package | |
5039 | (name "python2-xlib") | |
5040 | (version "0.14") | |
5041 | (source (origin | |
5042 | (method url-fetch) | |
de67e922 LF |
5043 | (uri (string-append "mirror://sourceforge/python-xlib/python-xlib" |
5044 | "/" version "/" | |
db62afa5 LC |
5045 | "python-xlib-" version ".tar.gz")) |
5046 | (sha256 | |
5047 | (base32 | |
5048 | "1sv0447j0rx8cgs3jhjl695p5pv13ihglcjlrrz1kq05lsvb0wa7")))) | |
5049 | (build-system python-build-system) | |
5050 | (arguments | |
5051 | `(#:python ,python-2 ;Python 2 only | |
5052 | #:tests? #f)) ;no tests | |
db62afa5 LC |
5053 | (home-page "http://python-xlib.sourceforge.net/") |
5054 | (synopsis "Python X11 client library") | |
5055 | (description | |
5056 | "The Python X Library is intended to be a fully functional X client | |
5057 | library for Python programs. It is useful to implement low-level X clients. | |
5058 | It is written entirely in Python.") | |
3f641af0 | 5059 | (license license:gpl2+))) |
0234ca06 DT |
5060 | |
5061 | (define-public python-singledispatch | |
5062 | (package | |
5063 | (name "python-singledispatch") | |
5064 | (version "3.4.0.3") | |
5065 | (source | |
5066 | (origin | |
5067 | (method url-fetch) | |
bdb67d84 | 5068 | (uri (pypi-uri "singledispatch" version)) |
0234ca06 DT |
5069 | (sha256 |
5070 | (base32 | |
5071 | "171b7ip0hsq5qm83np40h3phlr36ym18w0lay0a8v08kvy3sy1jv")))) | |
5072 | (build-system python-build-system) | |
5e1c9d24 HG |
5073 | (native-inputs |
5074 | `(("python-six" ,python-six))) ; required for conversion, not at run-time | |
0234ca06 DT |
5075 | (home-page |
5076 | "http://docs.python.org/3/library/functools.html#functools.singledispatch") | |
5077 | (synopsis "Backport of singledispatch feature from Python 3.4") | |
5078 | (description | |
5079 | "This library brings functools.singledispatch from Python 3.4 to Python | |
5080 | 2.6-3.3.") | |
5081 | (license license:expat))) | |
5082 | ||
5083 | (define-public python2-singledispatch | |
5084 | (package-with-python2 python-singledispatch)) | |
feaae484 | 5085 | |
6b59fc10 EF |
5086 | ;; the python- version can be removed with python-3.5 |
5087 | (define-public python-backports-abc | |
5088 | (package | |
5089 | (name "python-backports-abc") | |
27f9148e | 5090 | (version "0.5") |
6b59fc10 EF |
5091 | (source |
5092 | (origin | |
5093 | (method url-fetch) | |
5094 | (uri (pypi-uri "backports_abc" version)) | |
5095 | (sha256 | |
5096 | (base32 | |
27f9148e | 5097 | "1pkv8d1zxj5f9i227dxbjczncbv7ks7ywnjwyxfjagm02i2yafq3")))) |
6b59fc10 | 5098 | (build-system python-build-system) |
6b59fc10 | 5099 | (home-page "https://github.com/cython/backports_abc") |
66e07664 | 5100 | (synopsis "Backport of additions to the 'collections.abc' module") |
6b59fc10 EF |
5101 | (description |
5102 | "Python-backports-abc provides a backport of additions to the | |
5103 | 'collections.abc' module in Python-3.5.") | |
3f641af0 | 5104 | (license license:psfl))) |
6b59fc10 EF |
5105 | |
5106 | (define-public python2-backports-abc | |
5107 | (package-with-python2 python-backports-abc)) | |
5108 | ||
4ff9e868 OP |
5109 | (define-public python-backports-csv |
5110 | (package | |
5111 | (name "python-backports-csv") | |
5112 | (version "1.0.5") | |
5113 | (source | |
5114 | (origin | |
5115 | (method url-fetch) | |
5116 | (uri (pypi-uri "backports.csv" version)) | |
5117 | (sha256 | |
5118 | (base32 | |
5119 | "1imzbrradkfn8s2m1qcimyn74dn1mz2p3j381jljn166rf2i6hlc")))) | |
5120 | (build-system python-build-system) | |
5121 | (home-page "https://github.com/ryanhiebert/backports.csv") | |
5122 | (synopsis "Backport of Python 3's csv module for Python 2") | |
5123 | (description | |
5124 | "Provides a backport of Python 3's @code{csv} module for parsing | |
5125 | comma separated values. The API of the @code{csv} module in Python 2 | |
5126 | is drastically different from the @code{csv} module in Python 3. | |
5127 | This is due, for the most part, to the difference between str in | |
5128 | Python 2 and Python 3.") | |
5129 | (license license:psfl))) | |
5130 | ||
5131 | (define-public python2-backports-csv | |
5132 | (package-with-python2 python-backports-csv)) | |
5133 | ||
ec074213 TD |
5134 | (define-public python2-backports-shutil-get-terminal-size |
5135 | (package | |
5136 | (name "python2-backports-shutil-get-terminal-size") | |
5137 | (version "1.0.0") | |
5138 | (source | |
5139 | (origin | |
5140 | (method url-fetch) | |
5141 | (uri (pypi-uri "backports.shutil_get_terminal_size" version)) | |
5142 | (sha256 | |
5143 | (base32 | |
5144 | "107cmn7g3jnbkp826zlj8rrj19fam301qvaqf0f3905f5217lgki")))) | |
5145 | (build-system python-build-system) | |
5146 | (arguments | |
c0446791 MB |
5147 | `(#:python ,python-2 |
5148 | #:phases | |
5149 | (modify-phases %standard-phases | |
5150 | (replace 'check | |
5151 | (lambda _ | |
5152 | (zero? (system* "py.test" "-v"))))))) | |
5153 | (native-inputs | |
5154 | `(("python2-pytest" ,python2-pytest))) | |
ec074213 TD |
5155 | (home-page "https://github.com/chrippa/backports.shutil_get_terminal_size") |
5156 | (synopsis "Backport of Python 3.3's @code{shutil.get_terminal_size}") | |
5157 | (description | |
5158 | "This package provides a backport of the @code{get_terminal_size | |
5159 | function} from Python 3.3's @code{shutil}. | |
5160 | Unlike the original version it is written in pure Python rather than C, | |
5161 | so it might be a tiny bit slower.") | |
5162 | (license license:expat))) | |
5163 | ||
feaae484 SB |
5164 | (define-public python-waf |
5165 | (package | |
5166 | (name "python-waf") | |
27bf00e6 | 5167 | (version "1.9.8") |
feaae484 SB |
5168 | (source (origin |
5169 | (method url-fetch) | |
bae67829 | 5170 | (uri (string-append "https://waf.io/" |
feaae484 SB |
5171 | "waf-" version ".tar.bz2")) |
5172 | (sha256 | |
5173 | (base32 | |
27bf00e6 | 5174 | "0wl4cnmp06lfxqjxaan58bqxn27smhydz0sg5prrfbl3bsw4gv6q")))) |
feaae484 SB |
5175 | (build-system python-build-system) |
5176 | (arguments | |
5177 | '(#:phases | |
5178 | (modify-phases %standard-phases | |
5179 | (replace 'build | |
7dd55dfe EF |
5180 | (lambda _ |
5181 | (zero? (system* "python" "waf-light" "configure" "build")))) | |
feaae484 | 5182 | (replace 'check |
7dd55dfe EF |
5183 | (lambda _ |
5184 | (zero? (system* "python" "waf" "--version")))) | |
feaae484 | 5185 | (replace 'install |
7dd55dfe EF |
5186 | (lambda _ |
5187 | (copy-file "waf" %output)))))) | |
27bf00e6 | 5188 | (home-page "https://waf.io/") |
feaae484 SB |
5189 | (synopsis "Python-based build system") |
5190 | (description | |
5191 | "Waf is a Python-based framework for configuring, compiling and installing | |
5192 | applications.") | |
3f641af0 | 5193 | (license license:bsd-3))) |
feaae484 SB |
5194 | |
5195 | (define-public python2-waf | |
5196 | (package-with-python2 python-waf)) | |
45203542 RW |
5197 | |
5198 | (define-public python-pyzmq | |
5199 | (package | |
5200 | (name "python-pyzmq") | |
3655ee76 | 5201 | (version "15.1.0") |
45203542 RW |
5202 | (source |
5203 | (origin | |
5204 | (method url-fetch) | |
3655ee76 | 5205 | (uri (pypi-uri "pyzmq" version)) |
45203542 | 5206 | (sha256 |
3655ee76 | 5207 | (base32 "13fhwnlvsvxv72kfhqbpn6qi7msh8mc8377mpabv32skk2cjfnxx")))) |
45203542 RW |
5208 | (build-system python-build-system) |
5209 | (arguments | |
5210 | `(#:configure-flags | |
5211 | (list (string-append "--zmq=" (assoc-ref %build-inputs "zeromq"))) | |
5212 | ;; FIXME: You must build pyzmq with 'python setup.py build_ext | |
5213 | ;; --inplace' for 'python setup.py test' to work. | |
5214 | #:tests? #f)) | |
5215 | (inputs | |
5216 | `(("zeromq" ,zeromq))) | |
5217 | (native-inputs | |
5218 | `(("pkg-config" ,pkg-config) | |
f3b98f4f | 5219 | ("python-nose" ,python-nose))) |
7bf837fd | 5220 | (home-page "https://github.com/zeromq/pyzmq") |
45203542 RW |
5221 | (synopsis "Python bindings for 0MQ") |
5222 | (description | |
5223 | "PyZMQ is the official Python binding for the ZeroMQ messaging library.") | |
3f641af0 | 5224 | (license license:bsd-4))) |
45203542 RW |
5225 | |
5226 | (define-public python2-pyzmq | |
5227 | (package-with-python2 python-pyzmq)) | |
d889e6c4 CR |
5228 | |
5229 | (define-public python-pep8 | |
5230 | (package | |
5231 | (name "python-pep8") | |
db251311 | 5232 | (version "1.7.0") |
d889e6c4 CR |
5233 | (source |
5234 | (origin | |
5235 | (method url-fetch) | |
db251311 | 5236 | (uri (pypi-uri "pep8" version)) |
d889e6c4 CR |
5237 | (sha256 |
5238 | (base32 | |
db251311 | 5239 | "002rkl4lsn6x2mxmf8ar00l0m8i3mzrc6pnzz77blyksmpsxa4x1")))) |
d889e6c4 | 5240 | (build-system python-build-system) |
d889e6c4 CR |
5241 | (home-page "http://pep8.readthedocs.org/") |
5242 | (synopsis "Python style guide checker") | |
5243 | (description | |
5244 | "This tools checks Python code against some of the style conventions in | |
5245 | PEP 8.") | |
5246 | (license license:expat))) | |
5247 | ||
5248 | (define-public python2-pep8 | |
5249 | (package-with-python2 python-pep8)) | |
e31d7f44 CR |
5250 | |
5251 | (define-public python-pyflakes | |
5252 | (package | |
5253 | (name "python-pyflakes") | |
2abc3972 | 5254 | (version "1.0.0") |
e31d7f44 CR |
5255 | (source |
5256 | (origin | |
5257 | (method url-fetch) | |
2abc3972 | 5258 | (uri (pypi-uri "pyflakes" version)) |
e31d7f44 CR |
5259 | (sha256 |
5260 | (base32 | |
2abc3972 | 5261 | "0qs2sgqszq7wcplis8509wk2ygqcrwzbs1ghfj3svvivq2j377pk")))) |
e31d7f44 | 5262 | (build-system python-build-system) |
e31d7f44 CR |
5263 | (home-page |
5264 | "https://github.com/pyflakes/pyflakes") | |
5265 | (synopsis "Passive checker of Python programs") | |
5266 | (description | |
5267 | "Pyflakes statically checks Python source code for common errors.") | |
5268 | (license license:expat))) | |
a59e017c | 5269 | |
7261d9eb CR |
5270 | (define-public python2-pyflakes |
5271 | (package-with-python2 python-pyflakes)) | |
5272 | ||
a59e017c CR |
5273 | (define-public python-mccabe |
5274 | (package | |
5275 | (name "python-mccabe") | |
c6ebd40d | 5276 | (version "0.4.0") |
a59e017c CR |
5277 | (source |
5278 | (origin | |
5279 | (method url-fetch) | |
c6ebd40d | 5280 | (uri (pypi-uri "mccabe" version)) |
a59e017c CR |
5281 | (sha256 |
5282 | (base32 | |
c6ebd40d | 5283 | "0yr08a36h8lqlif10l4xcikbbig7q8f41gqywir7rrvnv3mi4aws")))) |
a59e017c | 5284 | (build-system python-build-system) |
328bb95d | 5285 | (native-inputs |
c6ebd40d | 5286 | `(("python-pytest" ,python-pytest) |
f3b98f4f | 5287 | ("python-pytest-runner" ,python-pytest-runner))) |
a59e017c CR |
5288 | (home-page "https://github.com/flintwork/mccabe") |
5289 | (synopsis "McCabe checker, plugin for flake8") | |
5290 | (description | |
5291 | "This package provides a Flake8 plug-in to compute the McCabe cyclomatic | |
5292 | complexity of Python source code.") | |
7362371d | 5293 | (license license:expat))) |
a59e017c CR |
5294 | |
5295 | (define-public python2-mccabe | |
5296 | (package-with-python2 python-mccabe)) | |
e8df8f47 | 5297 | |
7477fbb1 CR |
5298 | (define-public python-mccabe-0.2.1 |
5299 | (package (inherit python-mccabe) | |
5300 | (version "0.2.1") | |
5301 | (source | |
5302 | (origin | |
5303 | (method url-fetch) | |
5304 | (uri (pypi-uri "mccabe" version)) | |
5305 | (sha256 | |
5306 | (base32 | |
f3b98f4f | 5307 | "0fi4a81kr5bcv5p4xgibqr595hyj5dafkqgsmfk96mfy8w71fajs")))))) |
7477fbb1 CR |
5308 | |
5309 | (define-public python2-mccabe-0.2.1 | |
5310 | (package-with-python2 python-mccabe-0.2.1)) | |
5311 | ||
e8df8f47 CR |
5312 | ;; Flake8 2.4.1 requires an older version of pep8. |
5313 | ;; This should be removed ASAP. | |
5314 | (define-public python-pep8-1.5.7 | |
5315 | (package (inherit python-pep8) | |
5316 | (version "1.5.7") | |
5317 | (source | |
5318 | (origin | |
5319 | (method url-fetch) | |
5320 | (uri (string-append | |
5321 | "https://pypi.python.org/packages/source/p/pep8/pep8-" | |
5322 | version | |
5323 | ".tar.gz")) | |
5324 | (sha256 | |
5325 | (base32 | |
73e3060d MB |
5326 | "12b9bbdbwnspxgak14xg58c130x2n0blxzlms5jn2dszn8qj3d0m")))) |
5327 | (arguments | |
5328 | ;; XXX Tests not compatible with Python 3.5. | |
5329 | '(#:tests? #f)))) | |
e8df8f47 CR |
5330 | |
5331 | (define-public python2-pep8-1.5.7 | |
5332 | (package-with-python2 python-pep8-1.5.7)) | |
5333 | ||
5334 | ;; Flake8 2.4.1 requires an older version of pyflakes. | |
5335 | ;; This should be removed ASAP. | |
5336 | (define-public python-pyflakes-0.8.1 | |
5337 | (package (inherit python-pyflakes) | |
5338 | (version "0.8.1") | |
5339 | (source | |
5340 | (origin | |
5341 | (method url-fetch) | |
5342 | (uri (string-append | |
5343 | "https://pypi.python.org/packages/source/p/pyflakes/pyflakes-" | |
5344 | version | |
5345 | ".tar.gz")) | |
5346 | (sha256 | |
5347 | (base32 | |
0d84e1ef MB |
5348 | "0sbpq6pqm1i9wqi41mlfrsc5rk92jv4mskvlyxmnhlbdnc80ma1z")))) |
5349 | (arguments | |
5350 | ;; XXX Tests not compatible with Python 3.5. | |
5351 | '(#:tests? #f)))) | |
e8df8f47 CR |
5352 | |
5353 | (define-public python2-pyflakes-0.8.1 | |
7261d9eb | 5354 | (package-with-python2 python-pyflakes-0.8.1)) |
e8df8f47 CR |
5355 | |
5356 | (define-public python-flake8 | |
5357 | (package | |
5358 | (name "python-flake8") | |
43789136 | 5359 | (version "2.5.4") |
e8df8f47 CR |
5360 | (source |
5361 | (origin | |
5362 | (method url-fetch) | |
1b995533 | 5363 | (uri (pypi-uri "flake8" version)) |
e8df8f47 CR |
5364 | (sha256 |
5365 | (base32 | |
011271c7 HG |
5366 | "0bs9cz4fr99r2rwig1b8jwaadl1nan7kgpdzqwj0bwbckwbmh7nc")) |
5367 | (modules '((guix build utils))) | |
5368 | (snippet | |
5369 | '(begin | |
5370 | ;; Remove pre-compiled .pyc files from source. | |
5371 | (for-each delete-file-recursively | |
5372 | (find-files "." "__pycache__" #:directories? #t)) | |
5373 | (for-each delete-file (find-files "." "\\.pyc$")) | |
5374 | #t)))) | |
e8df8f47 | 5375 | (build-system python-build-system) |
482d9591 | 5376 | (propagated-inputs |
f3b98f4f | 5377 | `(("python-pep8" ,python-pep8) |
43789136 | 5378 | ("python-pyflakes" ,python-pyflakes) |
482d9591 | 5379 | ("python-mccabe" ,python-mccabe))) |
328bb95d HG |
5380 | (native-inputs |
5381 | `(("python-mock" ,python-mock) ; TODO: only required for < 3.3 | |
e8df8f47 CR |
5382 | ("python-nose" ,python-nose))) |
5383 | (home-page "https://gitlab.com/pycqa/flake8") | |
5384 | (synopsis | |
5385 | "The modular source code checker: pep8, pyflakes and co") | |
5386 | (description | |
5387 | "Flake8 is a wrapper around PyFlakes, pep8 and python-mccabe.") | |
5388 | (license license:expat))) | |
5389 | ||
5390 | (define-public python2-flake8 | |
5391 | (package-with-python2 python-flake8)) | |
61b9ac53 | 5392 | |
1f42d824 MFM |
5393 | (define-public python-flake8-polyfill |
5394 | (package | |
5395 | (name "python-flake8-polyfill") | |
5396 | (version "1.0.1") | |
5397 | (source | |
5398 | (origin | |
5399 | (method url-fetch) | |
5400 | (uri (pypi-uri "flake8-polyfill" version)) | |
5401 | (sha256 | |
5402 | (base32 | |
5403 | "02gn2wxvh9vnf7m7dld7ca4l60mg5c370hv3swwppkngwaqmcw67")))) | |
5404 | (build-system python-build-system) | |
2c1cad7a MB |
5405 | (arguments |
5406 | '(#:phases | |
5407 | (modify-phases %standard-phases | |
5408 | (replace 'check | |
5409 | (lambda _ | |
5410 | (setenv "PYTHONPATH" | |
5411 | (string-append (getcwd) "/build/lib:" | |
5412 | (getenv "PYTHONPATH"))) | |
5413 | (zero? (system* "py.test" "-v"))))))) | |
5414 | (native-inputs | |
5415 | `(("python-flake8" ,python-flake8) | |
5416 | ("python-mock" ,python-mock) | |
5417 | ("python-pycodestyle" ,python-pycodestyle) | |
5418 | ("python-pytest" ,python-pytest))) | |
1f42d824 MFM |
5419 | (home-page "https://gitlab.com/pycqa/flake8-polyfill") |
5420 | (synopsis "Polyfill package for Flake8 plugins") | |
5421 | (description | |
5422 | "This package that provides some compatibility helpers for Flake8 | |
5423 | plugins that intend to support Flake8 2.x and 3.x simultaneously.") | |
5424 | (license license:expat))) | |
5425 | ||
5426 | (define-public python2-flake8-polyfill | |
5427 | (package-with-python2 python-flake8-polyfill)) | |
5428 | ||
61b9ac53 FB |
5429 | (define-public python-mistune |
5430 | (package | |
5431 | (name "python-mistune") | |
a684e38d | 5432 | (version "0.8.3") |
61b9ac53 FB |
5433 | (source |
5434 | (origin | |
5435 | (method url-fetch) | |
eff8d773 | 5436 | (uri (pypi-uri "mistune" version)) |
61b9ac53 FB |
5437 | (sha256 |
5438 | (base32 | |
a684e38d | 5439 | "06b662p6kf46wh2jsabaqhaq4bz1srh2zxkrnx4yg96azlxw645w")))) |
61b9ac53 | 5440 | (build-system python-build-system) |
328bb95d | 5441 | (native-inputs |
f3b98f4f | 5442 | `(("python-nose" ,python-nose) |
61b9ac53 FB |
5443 | ("python-cython" ,python-cython))) |
5444 | (home-page "https://github.com/lepture/mistune") | |
5445 | (synopsis "Markdown parser in pure Python") | |
5446 | (description "This package provides a fast markdown parser in pure | |
5447 | Python.") | |
3f641af0 | 5448 | (license license:bsd-3))) |
61b9ac53 FB |
5449 | |
5450 | (define-public python2-mistune | |
5451 | (package-with-python2 python-mistune)) | |
6d992d07 | 5452 | |
b9893908 EE |
5453 | (define-public python-markdown |
5454 | (package | |
5455 | (name "python-markdown") | |
4ffbe8c6 | 5456 | (version "2.6.8") |
b9893908 EE |
5457 | (source |
5458 | (origin | |
5459 | (method url-fetch) | |
5460 | (uri (pypi-uri "Markdown" version)) | |
5461 | (sha256 | |
5462 | (base32 | |
4ffbe8c6 | 5463 | "0cqfhr1km2s5d8jm6hbwgkrrj9hvkjf2gab3s2axlrw1clgaij0a")))) |
b9893908 EE |
5464 | (build-system python-build-system) |
5465 | (arguments | |
5466 | `(#:phases | |
5467 | (modify-phases %standard-phases | |
5468 | (replace 'check | |
5469 | (lambda _ | |
5470 | (zero? (system* "python" "run-tests.py"))))))) | |
5471 | (native-inputs | |
5472 | `(("python-nose" ,python-nose) | |
5473 | ("python-pyyaml" ,python-pyyaml))) | |
5474 | (home-page "https://pythonhosted.org/Markdown/") | |
5475 | (synopsis "Python implementation of Markdown") | |
5476 | (description | |
5477 | "This package provides a Python implementation of John Gruber's | |
5478 | Markdown. The library features international input, various Markdown | |
5479 | extensions, and several HTML output formats. A command line wrapper | |
5480 | markdown_py is also provided to convert Markdown files to HTML.") | |
3f641af0 | 5481 | (license license:bsd-3))) |
b9893908 EE |
5482 | |
5483 | (define-public python2-markdown | |
5484 | (package-with-python2 python-markdown)) | |
5485 | ||
6d992d07 FB |
5486 | (define-public python-ptyprocess |
5487 | (package | |
5488 | (name "python-ptyprocess") | |
70fc93cb | 5489 | (version "0.5.1") |
6d992d07 FB |
5490 | (source |
5491 | (origin | |
5492 | (method url-fetch) | |
5493 | (uri (string-append | |
5494 | "https://pypi.python.org/packages/source/p/ptyprocess/ptyprocess-" | |
5495 | version ".tar.gz")) | |
5496 | (sha256 | |
5497 | (base32 | |
70fc93cb | 5498 | "19l1xrjn4l9gjz01s3vg92gn2dd9d8mw1v86ppkzlnr9m5iwwc05")))) |
6d992d07 | 5499 | (build-system python-build-system) |
328bb95d | 5500 | (native-inputs |
f3b98f4f | 5501 | `(("python-nose" ,python-nose))) |
6d992d07 FB |
5502 | (arguments |
5503 | `(#:phases | |
5504 | (modify-phases %standard-phases | |
5505 | (replace 'check | |
5506 | (lambda _ | |
5507 | (zero? (system* "nosetests"))))))) | |
5508 | (home-page "https://github.com/pexpect/ptyprocess") | |
5509 | (synopsis "Run a subprocess in a pseudo terminal") | |
5510 | (description | |
5511 | "This package provides a Python library used to launch a subprocess in a | |
5512 | pseudo terminal (pty), and interact with both the process and its pty.") | |
3f641af0 | 5513 | (license license:isc))) |
6d992d07 FB |
5514 | |
5515 | (define-public python2-ptyprocess | |
5516 | (package-with-python2 python-ptyprocess)) | |
4aadb1df | 5517 | |
df893a38 MB |
5518 | (define-public python-cram |
5519 | (package | |
5520 | (name "python-cram") | |
5521 | (version "0.7") | |
5522 | (home-page "https://bitheap.org/cram/") | |
5523 | (source (origin | |
5524 | (method url-fetch) | |
5525 | (uri (list (string-append home-page "cram-" | |
5526 | version ".tar.gz") | |
5527 | (pypi-uri "cram" version))) | |
5528 | (sha256 | |
5529 | (base32 | |
5530 | "0bvz6fwdi55rkrz3f50zsy35gvvwhlppki2yml5bj5ffy9d499vx")))) | |
5531 | (arguments | |
5532 | '(#:phases | |
5533 | (modify-phases %standard-phases | |
5534 | (add-after 'unpack 'patch-source | |
5535 | (lambda _ | |
5536 | (substitute* (find-files "cram" ".*\\.py$") | |
5537 | ;; Replace default shell path. | |
5538 | (("/bin/sh") (which "sh"))) | |
5539 | (substitute* (find-files "tests" ".*\\.t$") | |
5540 | (("md5") "md5sum") | |
5541 | (("/bin/bash") (which "bash")) | |
5542 | (("/bin/sh") (which "sh"))) | |
5543 | (substitute* "cram/_test.py" | |
5544 | ;; This hack works around a bug triggered by substituting | |
5545 | ;; the /bin/sh paths. "tests/usage.t" compares the output of | |
5546 | ;; "cram -h", which breaks the output at 80 characters. This | |
5547 | ;; causes the line showing the default shell to break into two | |
5548 | ;; lines, but the test expects a single line... | |
5549 | (("env\\['COLUMNS'\\] = '80'") | |
5550 | "env['COLUMNS'] = '160'")) | |
5551 | #t)) | |
5552 | (delete 'check) | |
5553 | (add-after 'install 'check | |
5554 | ;; The test phase uses the built library and executable. | |
5555 | ;; It's easier to run it after install since the build | |
5556 | ;; directory contains version-specific PATH. | |
5557 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
5558 | (add-installed-pythonpath inputs outputs) | |
5559 | (setenv "PATH" (string-append (getenv "PATH") ":" | |
5560 | (assoc-ref outputs "out") "/bin")) | |
5561 | (zero? (system* "make" "test"))))))) | |
5562 | (build-system python-build-system) | |
5563 | (native-inputs | |
5564 | `(("python-coverage" ,python-coverage) | |
5565 | ("which" ,which))) | |
5566 | (synopsis "Simple testing framework for command line applications") | |
5567 | (description | |
5568 | "Cram is a functional testing framework for command line applications. | |
5569 | Cram tests look like snippets of interactive shell sessions. Cram runs each | |
5570 | command and compares the command output in the test with the command’s actual | |
5571 | output.") | |
5572 | (license license:gpl2+))) | |
5573 | ||
5574 | (define-public python2-cram | |
5575 | (package-with-python2 python-cram)) | |
5576 | ||
789de5e2 | 5577 | (define-public python-straight-plugin |
5578 | (package | |
5579 | (name "python-straight-plugin") | |
5580 | (version "1.4.1") | |
5581 | (source | |
5582 | (origin | |
5583 | (method url-fetch) | |
5584 | (uri (pypi-uri "straight.plugin" version)) | |
5585 | (sha256 | |
5586 | (base32 | |
5587 | "069pjll4383p4kkgvcc40hgyvf79j2wdbpgwz77yigzxksh1gj62")))) | |
5588 | (build-system python-build-system) | |
5589 | (home-page "https://github.com/ironfroggy/straight.plugin") | |
5590 | (synopsis "Simple namespaced plugin facility") | |
5591 | (description "Straight Plugin provides a type of plugin you can create from | |
5592 | almost any existing Python modules, and an easy way for outside developers to | |
5593 | add functionality and customization to your projects with their own plugins.") | |
5594 | (license license:expat))) | |
5595 | ||
5596 | (define-public python2-straight-plugin | |
5597 | (package-with-python2 python-straight-plugin)) | |
5598 | ||
d582eaac SB |
5599 | (define-public python-fonttools |
5600 | (package | |
5601 | (name "python-fonttools") | |
a4593cc9 | 5602 | (version "3.15.1") |
d582eaac SB |
5603 | (source (origin |
5604 | (method url-fetch) | |
a4593cc9 | 5605 | (uri (pypi-uri "fonttools" version ".zip")) |
d582eaac SB |
5606 | (sha256 |
5607 | (base32 | |
a4593cc9 | 5608 | "1hhj97izwliy0vybmza72d90l5d4mcn50y8akq7kyccfl82vdx4d")))) |
d582eaac | 5609 | (build-system python-build-system) |
9e8c6a37 HG |
5610 | (arguments |
5611 | '(#:test-target "check" | |
5612 | #:phases | |
5613 | (modify-phases %standard-phases | |
5614 | (add-after 'unpack 'patch-setuppy | |
5615 | ;; Remove the undocumented "extra_path" argument, which adds an | |
5616 | ;; intervening directories between site-packages and the package | |
5617 | ;; directory. | |
5618 | (lambda _ | |
5619 | (substitute* "setup.py" | |
5620 | (("^[ \t]*extra_path *= *'FontTools',") "")) | |
5621 | #t))))) | |
a4593cc9 | 5622 | (native-inputs |
5623 | `(("unzip" ,unzip))) | |
7bf837fd | 5624 | (home-page "https://github.com/behdad/fonttools") |
d582eaac SB |
5625 | (synopsis "Tools to manipulate font files") |
5626 | (description | |
5627 | "FontTools/TTX is a library to manipulate font files from Python. It | |
9e8c6a37 | 5628 | supports reading and writing of TrueType/OpenType fonts, reading and writing |
d582eaac SB |
5629 | of AFM files, reading (and partially writing) of PS Type 1 fonts. The package |
5630 | also contains a tool called “TTX” which converts TrueType/OpenType fonts to and | |
5631 | from an XML-based format.") | |
3f641af0 DC |
5632 | (license (license:non-copyleft |
5633 | "file://LICENSE.txt" | |
5634 | "See LICENSE.txt in the distribution.")))) | |
d582eaac SB |
5635 | |
5636 | (define-public python2-fonttools | |
5637 | (package-with-python2 python-fonttools)) | |
75710da6 | 5638 | |
5faa5ce4 RW |
5639 | (define-public python-ly |
5640 | (package | |
5641 | (name "python-ly") | |
5135354f | 5642 | (version "0.9.4") |
5faa5ce4 RW |
5643 | (source |
5644 | (origin | |
5645 | (method url-fetch) | |
5135354f RW |
5646 | (uri (string-append "https://pypi.python.org/packages/57/4f/" |
5647 | "889579244947368f28eda66b782331b1e75f83fd72e63f9ece93cd7a18f9" | |
5648 | "/python-ly-" version ".tar.gz")) | |
5faa5ce4 RW |
5649 | (sha256 |
5650 | (base32 | |
5135354f | 5651 | "0g6n288l83sfwavxh1aryi0aqvsr3sp7v6f903mckwqa4scpky62")))) |
5faa5ce4 | 5652 | (build-system python-build-system) |
972cf9be MB |
5653 | (arguments |
5654 | ;; FIXME: Some tests need network access. | |
5655 | '(#:tests? #f)) | |
5faa5ce4 RW |
5656 | (synopsis "Tool and library for manipulating LilyPond files") |
5657 | (description "This package provides a Python library to parse, manipulate | |
5658 | or create documents in LilyPond format. A command line program ly is also | |
5659 | provided that can be used to do various manipulations with LilyPond files.") | |
5660 | (home-page "https://pypi.python.org/pypi/python-ly") | |
3f641af0 | 5661 | (license license:gpl2+))) |
7e7b27d9 CR |
5662 | |
5663 | (define-public python-appdirs | |
5664 | (package | |
5665 | (name "python-appdirs") | |
543782e1 | 5666 | (version "1.4.3") |
7e7b27d9 CR |
5667 | (source |
5668 | (origin | |
5669 | (method url-fetch) | |
26b16fd9 | 5670 | (uri (pypi-uri "appdirs" version)) |
7e7b27d9 CR |
5671 | (sha256 |
5672 | (base32 | |
543782e1 | 5673 | "14id6wxi12lgyw0mg3bcfnf888ad07jz9yj46gfzhn186z8rcn4y")))) |
7e7b27d9 | 5674 | (build-system python-build-system) |
7bf837fd | 5675 | (home-page "https://github.com/ActiveState/appdirs") |
7e7b27d9 CR |
5676 | (synopsis |
5677 | "Determine platform-specific dirs, e.g. a \"user data dir\"") | |
5678 | (description | |
5679 | "This module provides a portable way of finding out where user data | |
5680 | should be stored on various operating systems.") | |
5681 | (license license:expat))) | |
5682 | ||
5683 | (define-public python2-appdirs | |
5684 | (package-with-python2 python-appdirs)) | |
89b2e0b0 LF |
5685 | |
5686 | (define-public python-llfuse | |
5687 | (package | |
5688 | (name "python-llfuse") | |
4d31d143 | 5689 | (version "1.2") |
89b2e0b0 LF |
5690 | (source (origin |
5691 | (method url-fetch) | |
5692 | (uri (string-append | |
5693 | "https://bitbucket.org/nikratio/python-llfuse/downloads/" | |
5694 | "llfuse-" version ".tar.bz2")) | |
5695 | (sha256 | |
5696 | (base32 | |
4d31d143 | 5697 | "11hms1x68bf1bqbqy7w3wpffqsd3jkgricmzrc1hrnwkswfzzlr4")))) |
89b2e0b0 LF |
5698 | (build-system python-build-system) |
5699 | (inputs | |
5700 | `(("fuse" ,fuse) | |
5701 | ("attr" ,attr))) | |
5702 | (native-inputs | |
f3b98f4f | 5703 | `(("pkg-config" ,pkg-config))) |
89b2e0b0 LF |
5704 | (synopsis "Python bindings for FUSE") |
5705 | (description | |
5706 | "Python-LLFUSE is a set of Python bindings for the low level FUSE API.") | |
5707 | (home-page "https://bitbucket.org/nikratio/python-llfuse/") | |
3f641af0 | 5708 | (license license:lgpl2.0+) |
cd0569c4 | 5709 | (properties `((python2-variant . ,(delay python2-llfuse)))))) |
89b2e0b0 LF |
5710 | |
5711 | (define-public python2-llfuse | |
cd0569c4 LF |
5712 | (package (inherit (package-with-python2 |
5713 | (strip-python2-variant python-llfuse))) | |
5714 | (propagated-inputs `(("python2-contextlib2" ,python2-contextlib2))))) | |
5715 | ||
5716 | ;; For attic-0.16 | |
5717 | (define-public python-llfuse-0.41 | |
5718 | (package (inherit python-llfuse) | |
229b3661 | 5719 | (version "0.41.1") |
cd0569c4 LF |
5720 | (source (origin |
5721 | (method url-fetch) | |
5722 | (uri (string-append | |
5723 | "https://bitbucket.org/nikratio/python-llfuse/downloads/" | |
5724 | "llfuse-" version ".tar.bz2")) | |
5725 | (sha256 | |
5726 | (base32 | |
229b3661 | 5727 | "1imlqw9b73086y97izr036f58pgc5akv4ihc2rrf8j5h75jbrlaa")))) |
cd0569c4 LF |
5728 | ;; Python-LLFUSE < 0.42 includes underscore.js, which is MIT (expat) |
5729 | ;; licensed. The rest of the package is licensed under LGPL2.0 or later. | |
3f641af0 | 5730 | (license (list license:expat license:lgpl2.0+)))) |
641c9871 LF |
5731 | |
5732 | (define-public python-msgpack | |
5733 | (package | |
5734 | (name "python-msgpack") | |
aed625bd | 5735 | (version "0.4.8") |
641c9871 LF |
5736 | (source (origin |
5737 | (method url-fetch) | |
ae831df4 | 5738 | (uri (pypi-uri "msgpack-python" version)) |
641c9871 LF |
5739 | (sha256 |
5740 | (base32 | |
aed625bd | 5741 | "11pqk5braa6wndpnr1dhg64js82vjgxnm0lzy73rwl831zgijaqs")))) |
641c9871 | 5742 | (build-system python-build-system) |
641c9871 LF |
5743 | (synopsis "MessagePack (de)serializer") |
5744 | (description "MessagePack is a fast, compact binary serialization format, | |
5745 | suitable for similar data to JSON. This package provides CPython bindings for | |
5746 | reading and writing MessagePack data.") | |
5747 | (home-page "https://pypi.python.org/pypi/msgpack-python/") | |
f210e944 | 5748 | (license license:asl2.0))) |
bd74be7b LF |
5749 | |
5750 | (define-public python2-msgpack | |
f210e944 | 5751 | (package-with-python2 python-msgpack)) |
641c9871 | 5752 | |
6e5e39f4 CR |
5753 | (define-public python-netaddr |
5754 | (package | |
5755 | (name "python-netaddr") | |
e121be1e | 5756 | (version "0.7.19") |
6e5e39f4 CR |
5757 | (source |
5758 | (origin | |
5759 | (method url-fetch) | |
576c0e29 | 5760 | (uri (pypi-uri "netaddr" version)) |
6e5e39f4 CR |
5761 | (sha256 |
5762 | (base32 | |
e121be1e | 5763 | "1zdfadvpq4lmcqzr383gywxn4xyn355kj1n3lk9q2l03vmyfrbiq")))) |
6e5e39f4 CR |
5764 | (build-system python-build-system) |
5765 | (arguments `(#:tests? #f)) ;; No tests. | |
6e5e39f4 CR |
5766 | (home-page "https://github.com/drkjam/netaddr/") |
5767 | (synopsis "Pythonic manipulation of network addresses") | |
5768 | (description | |
5769 | "A Python library for representing and manipulating IPv4, IPv6, CIDR, EUI | |
5770 | and MAC network addresses.") | |
3f641af0 | 5771 | (license license:bsd-3))) |
6e5e39f4 CR |
5772 | |
5773 | (define-public python2-netaddr | |
5774 | (package-with-python2 python-netaddr)) | |
8c692a52 CR |
5775 | |
5776 | (define-public python-wrapt | |
5777 | (package | |
5778 | (name "python-wrapt") | |
d25bee26 | 5779 | (version "1.10.8") |
8c692a52 CR |
5780 | (source |
5781 | (origin | |
5782 | (method url-fetch) | |
d25bee26 | 5783 | (uri (pypi-uri "wrapt" version)) |
8c692a52 CR |
5784 | (sha256 |
5785 | (base32 | |
d25bee26 | 5786 | "0wrcm1mydvfivbkzz0h81ygzdchnscshi6xvy5n3r21r9s0px8af")))) |
8c692a52 CR |
5787 | (build-system python-build-system) |
5788 | (arguments | |
5789 | ;; Tests are not included in the tarball, they are only available in the | |
5790 | ;; git repository. | |
5791 | `(#:tests? #f)) | |
8c692a52 CR |
5792 | (home-page "https://github.com/GrahamDumpleton/wrapt") |
5793 | (synopsis "Module for decorators, wrappers and monkey patching") | |
5794 | (description | |
5795 | "The aim of the wrapt module is to provide a transparent object proxy for | |
5796 | Python, which can be used as the basis for the construction of function | |
5797 | wrappers and decorator functions.") | |
3f641af0 | 5798 | (license license:bsd-2))) |
8c692a52 CR |
5799 | |
5800 | (define-public python2-wrapt | |
5801 | (package-with-python2 python-wrapt)) | |
b85c85be | 5802 | |
02a8a187 BW |
5803 | (define-public python-xlrd |
5804 | (package | |
5805 | (name "python-xlrd") | |
c2ad4d70 | 5806 | (version "1.0.0") |
02a8a187 BW |
5807 | (source (origin |
5808 | (method url-fetch) | |
e775f48e | 5809 | (uri (pypi-uri "xlrd" version)) |
02a8a187 BW |
5810 | (sha256 |
5811 | (base32 | |
c2ad4d70 | 5812 | "0s8hjiz01vbhy85xalrz0qlsmd9ypf36zjqrf97hh984spapvy0g")))) |
02a8a187 BW |
5813 | (build-system python-build-system) |
5814 | (arguments | |
5815 | `(#:phases | |
5816 | (modify-phases %standard-phases | |
c2ad4d70 | 5817 | ;; Current test in setup.py does not work as of 1.0.0, so use nose to |
02a8a187 BW |
5818 | ;; run tests instead for now. |
5819 | (replace 'check (lambda _ (zero? (system* "nosetests"))))))) | |
f3b98f4f | 5820 | (native-inputs `(("python-nose" ,python-nose))) |
02a8a187 BW |
5821 | (home-page "http://www.python-excel.org/") |
5822 | (synopsis "Library for extracting data from Excel files") | |
5823 | (description "This packages provides a library to extract data from | |
c598e35c | 5824 | spreadsheets using Microsoft Excel proprietary file formats @samp{.xls} and |
02a8a187 BW |
5825 | @samp{.xlsx} (versions 2.0 onwards). It has support for Excel dates and is |
5826 | Unicode-aware. It is not intended as an end-user tool.") | |
3f641af0 | 5827 | (license license:bsd-3))) |
02a8a187 BW |
5828 | |
5829 | (define-public python2-xlrd | |
5830 | (package-with-python2 python-xlrd)) | |
5831 | ||
350ba0a3 CR |
5832 | (define-public python-prettytable |
5833 | (package | |
5834 | (name "python-prettytable") | |
5835 | (version "0.7.2") | |
5836 | (source | |
5837 | (origin | |
5838 | (method url-fetch) | |
5839 | (uri (string-append | |
5840 | "https://pypi.python.org/packages/source/P/PrettyTable/" | |
5841 | "prettytable-" version ".tar.bz2")) | |
5842 | (sha256 | |
5843 | (base32 | |
5844 | "0diwsicwmiq2cpzpxri7cyl5fmsvicafw6nfqf6p6p322dji2g45")))) | |
5845 | (build-system python-build-system) | |
350ba0a3 CR |
5846 | (home-page "http://code.google.com/p/prettytable/") |
5847 | (synopsis "Display tabular data in an ASCII table format") | |
5848 | (description | |
5849 | "A library designed to represent tabular data in visually appealing ASCII | |
5850 | tables. PrettyTable allows for selection of which columns are to be printed, | |
5851 | independent alignment of columns (left or right justified or centred) and | |
5852 | printing of sub-tables by specifying a row range.") | |
3f641af0 | 5853 | (license license:bsd-3))) |
350ba0a3 CR |
5854 | |
5855 | (define-public python2-prettytable | |
5856 | (package-with-python2 python-prettytable)) | |
7a8ac75a | 5857 | |
9f8ee3fe RW |
5858 | (define-public python-tables |
5859 | (package | |
5860 | (name "python-tables") | |
5861 | (version "3.2.2") | |
5862 | (source | |
5863 | (origin | |
5864 | (method url-fetch) | |
5865 | (uri (pypi-uri "tables" version)) | |
5866 | (sha256 | |
5867 | (base32 | |
bac23672 HG |
5868 | "117s6w7s3yxafpmf3zz3svana7xfrsviw01va1xp7h8ylx8v6r1m")) |
5869 | (modules '((guix build utils))) | |
5870 | (snippet | |
5871 | '(begin | |
5872 | ;; Remove pre-compiled .pyc files from source. | |
5873 | (for-each delete-file-recursively | |
5874 | (find-files "." "__pycache__" #:directories? #t)) | |
5875 | (for-each delete-file (find-files "." "\\.pyc$")) | |
5876 | #t)))) | |
9f8ee3fe RW |
5877 | (build-system python-build-system) |
5878 | (arguments | |
5879 | `(;; FIXME: python-build-system does not pass configure-flags to "build" | |
5880 | ;; or "check", so we must override the build and check phases. | |
5881 | #:phases | |
5882 | (modify-phases %standard-phases | |
5883 | (add-after 'unpack 'use-gcc | |
5884 | (lambda _ | |
5885 | (substitute* "setup.py" | |
5886 | (("compiler = new_compiler\\(\\)" line) | |
5887 | (string-append line | |
5888 | "\ncompiler.set_executables(compiler='gcc'," | |
5889 | "compiler_so='gcc'," | |
5890 | "linker_exe='gcc'," | |
5891 | "linker_so='gcc -shared')"))) | |
5892 | #t)) | |
5893 | (replace 'build | |
5894 | (lambda* (#:key inputs #:allow-other-keys) | |
5895 | (zero? (system* "python" "setup.py" "build" | |
5896 | (string-append "--hdf5=" | |
5897 | (assoc-ref inputs "hdf5")))))) | |
5898 | (replace 'check | |
5899 | (lambda* (#:key inputs #:allow-other-keys) | |
5900 | (zero? (system* "python" "setup.py" "check" | |
5901 | (string-append "--hdf5=" | |
5902 | (assoc-ref inputs "hdf5"))))))))) | |
5903 | (propagated-inputs | |
5904 | `(("python-numexpr" ,python-numexpr) | |
5905 | ("python-numpy" ,python-numpy))) | |
5906 | (native-inputs | |
f3b98f4f | 5907 | `(("python-cython" ,python-cython) |
9f8ee3fe RW |
5908 | ("pkg-config" ,pkg-config))) |
5909 | (inputs | |
5910 | `(("hdf5" ,hdf5) | |
5911 | ("bzip2" ,bzip2) | |
5912 | ("zlib" ,zlib))) | |
5913 | (home-page "http://www.pytables.org/") | |
5914 | (synopsis "Hierarchical datasets for Python") | |
5915 | (description "PyTables is a package for managing hierarchical datasets and | |
d1e4ad1b | 5916 | designed to efficiently cope with extremely large amounts of data.") |
3f641af0 | 5917 | (license license:bsd-3))) |
9f8ee3fe RW |
5918 | |
5919 | (define-public python2-tables | |
5920 | (package-with-python2 python-tables)) | |
5921 | ||
7a8ac75a RW |
5922 | (define-public python-pyasn1 |
5923 | (package | |
5924 | (name "python-pyasn1") | |
5e0ddfba | 5925 | (version "0.2.3") |
7a8ac75a RW |
5926 | (source |
5927 | (origin | |
5928 | (method url-fetch) | |
caa0edb3 | 5929 | (uri (pypi-uri "pyasn1" version)) |
7a8ac75a RW |
5930 | (sha256 |
5931 | (base32 | |
5e0ddfba | 5932 | "1b86yx23c1x74clai05a5ma8c8nfmhlx3j1mxq0ff657i2ylx33k")))) |
7a8ac75a RW |
5933 | (build-system python-build-system) |
5934 | (home-page "http://pyasn1.sourceforge.net/") | |
5935 | (synopsis "ASN.1 types and codecs") | |
5936 | (description | |
5937 | "This is an implementation of ASN.1 types and codecs in Python. It is | |
5938 | suitable for a wide range of protocols based on the ASN.1 specification.") | |
3f641af0 | 5939 | (license license:bsd-2))) |
7a8ac75a RW |
5940 | |
5941 | (define-public python2-pyasn1 | |
5942 | (package-with-python2 python-pyasn1)) | |
9a49a535 | 5943 | |
5988c299 EF |
5944 | (define-public python-pyasn1-modules |
5945 | (package | |
5946 | (name "python-pyasn1-modules") | |
5947 | (version "0.0.8") | |
5948 | (source | |
5949 | (origin | |
5950 | (method url-fetch) | |
5951 | (uri (pypi-uri "pyasn1-modules" version)) | |
5952 | (sha256 | |
5953 | (base32 | |
5954 | "0drqgw81xd3fxdlg89kgd79zzrabvfncvkbybi2wr6w2y4s1jmhh")))) | |
5955 | (build-system python-build-system) | |
5988c299 EF |
5956 | (propagated-inputs |
5957 | `(("python-pyasn1" ,python-pyasn1))) | |
3b3b60d0 | 5958 | (home-page "https://sourceforge.net/projects/pyasn1/") |
5988c299 EF |
5959 | (synopsis "ASN.1 codec implementations") |
5960 | (description | |
5961 | "Pyasn1-modules is a collection of Python modules providing ASN.1 types and | |
5962 | implementations of ASN.1-based codecs and protocols.") | |
3f641af0 | 5963 | (license license:bsd-3))) |
5988c299 EF |
5964 | |
5965 | (define-public python2-pyasn1-modules | |
5966 | (package-with-python2 python-pyasn1-modules)) | |
5967 | ||
520af157 | 5968 | (define-public python-ipaddress |
9a49a535 | 5969 | (package |
520af157 | 5970 | (name "python-ipaddress") |
36e0d9db | 5971 | (version "1.0.18") |
520af157 DC |
5972 | (source (origin |
5973 | (method url-fetch) | |
5974 | (uri (pypi-uri "ipaddress" version)) | |
5975 | (sha256 | |
5976 | (base32 | |
36e0d9db | 5977 | "1q8klj9d84cmxgz66073x1j35cplr3r77vx1znhxiwl5w74391ax")))) |
9a49a535 | 5978 | (build-system python-build-system) |
9a49a535 RW |
5979 | (home-page "https://github.com/phihag/ipaddress") |
5980 | (synopsis "IP address manipulation library") | |
5981 | (description | |
520af157 DC |
5982 | "This package provides a fast, lightweight IPv4/IPv6 manipulation library |
5983 | in Python. This library is used to create, poke at, and manipulate IPv4 and | |
5984 | IPv6 addresses and networks. This is a port of the Python 3.3 ipaddress | |
5985 | module to older versions of Python.") | |
f210e944 | 5986 | (license license:psfl))) |
520af157 DC |
5987 | |
5988 | (define-public python2-ipaddress | |
f210e944 | 5989 | (package-with-python2 python-ipaddress)) |
3f00e078 | 5990 | |
4a238186 HG |
5991 | (define-public python2-ipaddr |
5992 | (package | |
5993 | (name "python2-ipaddr") | |
5994 | (version "2.1.11") | |
5995 | (source | |
5996 | (origin | |
5997 | (method url-fetch) | |
5998 | (uri (pypi-uri "ipaddr" version)) | |
5999 | (sha256 | |
6000 | (base32 "1dwq3ngsapjc93fw61rp17fvzggmab5x1drjzvd4y4q0i255nm8v")))) | |
6001 | (build-system python-build-system) | |
6002 | (arguments | |
6003 | `(#:python ,python-2 ;version 2 only | |
6004 | #:phases | |
6005 | (modify-phases %standard-phases | |
6006 | (replace 'check | |
6007 | (lambda* _ | |
6008 | (zero? (system* "python" "ipaddr_test.py"))))))) | |
6009 | (home-page "https://github.com/google/ipaddr-py") | |
6010 | (synopsis "IP address manipulation library") | |
6011 | (description | |
6012 | "Ipaddr is a Python@tie{}2 library for creating and manupilating IPv4 and | |
6013 | IPv6 addresses and networks. | |
6014 | ||
6015 | For new implementations you may prefer to use the standard module | |
6016 | @code{ipaddress}, which was introduced in Python 3.3 and backported to older | |
6017 | versions of Python.") | |
3f641af0 | 6018 | (license license:asl2.0))) |
4a238186 | 6019 | |
3f00e078 RW |
6020 | (define-public python-idna |
6021 | (package | |
6022 | (name "python-idna") | |
0ee12dc9 | 6023 | (version "2.6") |
3f00e078 RW |
6024 | (source |
6025 | (origin | |
6026 | (method url-fetch) | |
37c04f91 | 6027 | (uri (pypi-uri "idna" version)) |
3f00e078 RW |
6028 | (sha256 |
6029 | (base32 | |
0ee12dc9 | 6030 | "13qaab6d0s15gknz8v3zbcfmbj6v86hn9pjxgkdf62ch13imssic")))) |
3f00e078 | 6031 | (build-system python-build-system) |
3f00e078 RW |
6032 | (home-page "https://github.com/kjd/idna") |
6033 | (synopsis "Internationalized domain names in applications") | |
6034 | (description | |
6035 | "This is a library to support the Internationalised Domain Names in | |
6036 | Applications (IDNA) protocol as specified in RFC 5891. This version of the | |
6037 | protocol is often referred to as “IDNA2008” and can produce different results | |
6038 | from the earlier standard from 2003. The library is also intended to act as a | |
6039 | suitable drop-in replacement for the “encodings.idna” module that comes with | |
6040 | the Python standard library but currently only supports the older 2003 | |
6041 | specification.") | |
3f641af0 | 6042 | (license license:bsd-4))) |
3f00e078 RW |
6043 | |
6044 | (define-public python2-idna | |
6045 | (package-with-python2 python-idna)) | |
36ebf972 RW |
6046 | |
6047 | (define-public python-pretend | |
6048 | (package | |
6049 | (name "python-pretend") | |
6050 | (version "1.0.8") | |
6051 | (source | |
6052 | (origin | |
6053 | (method url-fetch) | |
6054 | (uri (string-append "https://pypi.python.org/packages/source/p/" | |
6055 | "pretend/pretend-" version ".tar.gz")) | |
6056 | (sha256 | |
6057 | (base32 | |
6058 | "0r5r7ygz9m6d2bklflbl84cqhjkc2q12xgis8268ygjh30g2q3wk")))) | |
6059 | (build-system python-build-system) | |
36ebf972 RW |
6060 | (home-page "https://github.com/alex/pretend") |
6061 | (synopsis "Library for stubbing in Python") | |
6062 | (description | |
6063 | "Pretend is a library to make stubbing with Python easier. Stubbing is a | |
6064 | technique for writing tests. You may hear the term mixed up with mocks, | |
6065 | fakes, or doubles. Basically, a stub is an object that returns pre-canned | |
6066 | responses, rather than doing any computation.") | |
3f641af0 | 6067 | (license license:bsd-3))) |
36ebf972 RW |
6068 | |
6069 | (define-public python2-pretend | |
6070 | (package-with-python2 python-pretend)) | |
aa759a51 | 6071 | |
643725a1 CR |
6072 | (define-public python-pip |
6073 | (package | |
6074 | (name "python-pip") | |
392c26b0 | 6075 | (version "9.0.1") |
643725a1 CR |
6076 | (source |
6077 | (origin | |
6078 | (method url-fetch) | |
6fb54e3b | 6079 | (uri (pypi-uri "pip" version)) |
643725a1 CR |
6080 | (sha256 |
6081 | (base32 | |
392c26b0 | 6082 | "03clr9c1dih5n9c00c592zzvf6r1ffimywkaq9agcqdllzhl7wh9")))) |
643725a1 | 6083 | (build-system python-build-system) |
392c26b0 MC |
6084 | (arguments |
6085 | '(#:tests? #f)) ; there are no tests in the pypi archive. | |
643725a1 | 6086 | (home-page "https://pip.pypa.io/") |
392c26b0 | 6087 | (synopsis "Package manager for Python software") |
643725a1 | 6088 | (description |
392c26b0 | 6089 | "Pip is a package manager for Python software, that finds packages on the |
643725a1 CR |
6090 | Python Package Index (PyPI).") |
6091 | (license license:expat))) | |
6092 | ||
6093 | (define-public python2-pip | |
6094 | (package-with-python2 python-pip)) | |
d8c4998f LC |
6095 | |
6096 | (define-public python-tlsh | |
6097 | (package | |
6098 | (name "python-tlsh") | |
99b00dc7 | 6099 | (version "3.4.4") |
d8c4998f LC |
6100 | (home-page "https://github.com/trendmicro/tlsh") |
6101 | (source (origin | |
99b00dc7 EF |
6102 | (method url-fetch) |
6103 | (uri (string-append "https://github.com/trendmicro/tlsh/archive/v" | |
6104 | version ".tar.gz")) | |
d8c4998f LC |
6105 | (sha256 |
6106 | (base32 | |
99b00dc7 EF |
6107 | "00bhzjqrlh7v538kbkbn8lgx976j1138al3sdhklaizqjvpwyk4r")) |
6108 | (file-name (string-append name "-" version ".tar.gz")))) | |
d8c4998f LC |
6109 | (build-system cmake-build-system) |
6110 | (arguments | |
6111 | '(#:out-of-source? #f | |
6112 | #:phases (modify-phases %standard-phases | |
6113 | (replace | |
6114 | 'install | |
6115 | (lambda* (#:key outputs #:allow-other-keys) | |
6116 | ;; Build and install the Python bindings. The underlying | |
6117 | ;; C++ library is apparently not meant to be installed. | |
6118 | (let ((out (assoc-ref outputs "out"))) | |
6119 | (with-directory-excursion "py_ext" | |
6120 | (and (system* "python" "setup.py" "build") | |
6121 | (system* "python" "setup.py" "install" | |
6122 | (string-append "--prefix=" out)))))))))) | |
6123 | (inputs `(("python" ,python-wrapper))) ;for the bindings | |
6124 | (synopsis "Fuzzy matching library for Python") | |
6125 | (description | |
6126 | "Trend Micro Locality Sensitive Hash (TLSH) is a fuzzy matching library. | |
6127 | Given a byte stream with a minimum length of 256 bytes, TLSH generates a hash | |
6128 | value which can be used for similarity comparisons. Similar objects have | |
6129 | similar hash values, which allows for the detection of similar objects by | |
6130 | comparing their hash values. The byte stream should have a sufficient amount | |
6131 | of complexity; for example, a byte stream of identical bytes will not generate | |
6132 | a hash value.") | |
3f641af0 | 6133 | (license license:asl2.0))) |
d8c4998f LC |
6134 | |
6135 | (define-public python2-tlsh | |
6136 | (package | |
6137 | (inherit python-tlsh) | |
6138 | (name "python2-tlsh") | |
6139 | (inputs `(("python" ,python-2))))) | |
d96034ed | 6140 | |
67f66812 BW |
6141 | (define-public python-termcolor |
6142 | (package | |
6143 | (name "python-termcolor") | |
6144 | (version "1.1.0") | |
6145 | (source | |
6146 | (origin | |
6147 | (method url-fetch) | |
a5e8f597 | 6148 | (uri (pypi-uri "termcolor" version)) |
67f66812 BW |
6149 | (sha256 |
6150 | (base32 | |
6151 | "0fv1vq14rpqwgazxg4981904lfyp84mnammw7y046491cv76jv8x")))) | |
6152 | (build-system python-build-system) | |
6153 | (arguments | |
6154 | ;; There are no tests. | |
6155 | `(#:tests? #f)) | |
9be5ecdf | 6156 | (home-page "https://pypi.python.org/pypi/termcolor") |
67f66812 BW |
6157 | (synopsis "ANSII Color formatting for terminal output") |
6158 | (description | |
6159 | "This package provides ANSII Color formatting for output in terminals.") | |
6160 | (license license:expat))) | |
6161 | ||
6162 | (define-public python2-termcolor | |
6163 | (package-with-python2 python-termcolor)) | |
6164 | ||
d96034ed LC |
6165 | (define-public python-libarchive-c |
6166 | (package | |
6167 | (name "python-libarchive-c") | |
03fd001c | 6168 | (version "2.2") |
d96034ed LC |
6169 | (source (origin |
6170 | (method url-fetch) | |
03fd001c | 6171 | (uri (pypi-uri "libarchive-c" version)) |
d96034ed LC |
6172 | (sha256 |
6173 | (base32 | |
03fd001c | 6174 | "0z4r7v3dhd6b3120mav05ff08srih176r2rg5k8kn7mjd9pslm2x")))) |
d96034ed LC |
6175 | (build-system python-build-system) |
6176 | (arguments | |
6177 | '(#:phases (modify-phases %standard-phases | |
6178 | (add-before | |
6179 | 'build 'reference-libarchive | |
6180 | (lambda* (#:key inputs #:allow-other-keys) | |
6181 | ;; Retain the absolute file name of libarchive.so. | |
6182 | (let ((libarchive (assoc-ref inputs "libarchive"))) | |
6183 | (substitute* "libarchive/ffi.py" | |
6184 | (("find_library\\('archive'\\)") | |
6185 | (string-append "'" libarchive | |
b41a05ce | 6186 | "/lib/libarchive.so'"))))))))) |
d96034ed | 6187 | (inputs |
f3b98f4f | 6188 | `(("libarchive" ,libarchive))) |
d96034ed LC |
6189 | (home-page "https://github.com/Changaco/python-libarchive-c") |
6190 | (synopsis "Python interface to libarchive") | |
6191 | (description | |
6192 | "This package provides Python bindings to libarchive, a C library to | |
6193 | access possibly compressed archives in many different formats. It uses | |
6194 | Python's @code{ctypes} foreign function interface (FFI).") | |
3f641af0 | 6195 | (license license:lgpl2.0+))) |
d96034ed LC |
6196 | |
6197 | (define-public python2-libarchive-c | |
6198 | (package-with-python2 python-libarchive-c)) | |
5e1c9367 LC |
6199 | |
6200 | (define-public python-file | |
6201 | (package | |
6202 | (inherit file) | |
6203 | (name "python-file") | |
6204 | (build-system python-build-system) | |
6205 | (arguments | |
6206 | '(#:tests? #f ;no tests | |
00bf74be | 6207 | #:configure-flags '("--single-version-externally-managed" "--root=/") |
5e1c9367 LC |
6208 | #:phases (modify-phases %standard-phases |
6209 | (add-before 'build 'change-directory | |
6210 | (lambda _ | |
6211 | (chdir "python") | |
6212 | #t)) | |
6213 | (add-before 'build 'set-library-file-name | |
6214 | (lambda* (#:key inputs #:allow-other-keys) | |
6215 | (let ((file (assoc-ref inputs "file"))) | |
6216 | (substitute* "magic.py" | |
6217 | (("find_library\\('magic'\\)") | |
6218 | (string-append "'" file "/lib/libmagic.so'"))) | |
6219 | #t)))))) | |
6220 | (inputs `(("file" ,file))) | |
6221 | (self-native-input? #f) | |
daeeea71 CM |
6222 | (synopsis "Python bindings to the libmagic file type guesser. Note that |
6223 | this module and the python-magic module both provide a \"magic.py\" file; | |
6224 | these two modules, which are different and were developed separately, both | |
f210e944 | 6225 | serve the same purpose: provide Python bindings for libmagic."))) |
5e1c9367 LC |
6226 | |
6227 | (define-public python2-file | |
f210e944 | 6228 | (package-with-python2 python-file)) |
85d4aeac LC |
6229 | |
6230 | (define-public python-debian | |
6231 | (package | |
6232 | (name "python-debian") | |
02d7f337 | 6233 | (version "0.1.28") |
85d4aeac LC |
6234 | (source |
6235 | (origin | |
6236 | (method url-fetch) | |
5e217a8b | 6237 | (uri (pypi-uri name version)) |
85d4aeac LC |
6238 | (sha256 |
6239 | (base32 | |
02d7f337 | 6240 | "0i15f0xzx679sd0ldq2sls9pnnps9fv6vhqvnv9dzf4qhma42i0y")))) |
85d4aeac | 6241 | (build-system python-build-system) |
f22efa01 | 6242 | (propagated-inputs |
85d4aeac | 6243 | `(("python-six" ,python-six))) |
85d4aeac LC |
6244 | (home-page "http://packages.debian.org/sid/python-debian") |
6245 | (synopsis "Debian package related modules") | |
6246 | (description | |
5c7bdc9a LC |
6247 | ;; XXX: Use @enumerate instead of @itemize to work around |
6248 | ;; <http://bugs.gnu.org/21772>. | |
85d4aeac LC |
6249 | "This package provides Python modules that abstract many formats of |
6250 | Debian-related files, such as: | |
6251 | ||
5c7bdc9a | 6252 | @enumerate |
85d4aeac LC |
6253 | @item Debtags information; |
6254 | @item @file{debian/changelog} files; | |
6255 | @item packages files, pdiffs; | |
6256 | @item control files of single or multiple RFC822-style paragraphs---e.g. | |
6257 | @file{debian/control}, @file{.changes}, @file{.dsc}; | |
6258 | @item Raw @file{.deb} and @file{.ar} files, with (read-only) access to | |
6259 | contained files and meta-information. | |
5c7bdc9a | 6260 | @end enumerate\n") |
85d4aeac LC |
6261 | |
6262 | ;; Modules are either GPLv2+ or GPLv3+. | |
3f641af0 | 6263 | (license license:gpl3+))) |
85d4aeac LC |
6264 | |
6265 | (define-public python2-debian | |
6266 | (package-with-python2 python-debian)) | |
816a6538 | 6267 | |
2d321bb2 RW |
6268 | (define-public python-nbformat |
6269 | (package | |
6270 | (name "python-nbformat") | |
ae7f246c | 6271 | (version "4.3.0") |
2d321bb2 RW |
6272 | (source |
6273 | (origin | |
6274 | (method url-fetch) | |
6275 | (uri (pypi-uri "nbformat" version)) | |
6276 | (sha256 | |
6277 | (base32 | |
ae7f246c | 6278 | "12s7j4qja8b5bs1kyw5dzmrqbjxxj8wk52cyasbiqbv7fblcrssz")))) |
2d321bb2 RW |
6279 | (build-system python-build-system) |
6280 | (arguments `(#:tests? #f)) ; no test target | |
6281 | (propagated-inputs | |
6282 | `(("python-ipython-genutils" ,python-ipython-genutils) | |
6283 | ("python-jsonschema" ,python-jsonschema) | |
6284 | ("python-jupyter-core" ,python-jupyter-core) | |
6285 | ("python-traitlets" ,python-traitlets))) | |
2d321bb2 RW |
6286 | (home-page "http://jupyter.org") |
6287 | (synopsis "Jupyter Notebook format") | |
6288 | (description "This package provides the reference implementation of the | |
6289 | Jupyter Notebook format and Python APIs for working with notebooks.") | |
6290 | (license license:bsd-3))) | |
6291 | ||
6292 | (define-public python2-nbformat | |
6293 | (package-with-python2 python-nbformat)) | |
6294 | ||
55436048 RW |
6295 | (define-public python-bleach |
6296 | (package | |
6297 | (name "python-bleach") | |
6298 | (version "1.4.3") | |
6299 | (source | |
6300 | (origin | |
6301 | (method url-fetch) | |
6302 | (uri (pypi-uri "bleach" version)) | |
6303 | (sha256 | |
6304 | (base32 | |
6305 | "0jvg3jxrvnx7xmm9gj262v60ib452xlnwlb0navyp7jsvcd0d4qj")))) | |
6306 | (build-system python-build-system) | |
6307 | (propagated-inputs | |
6308 | `(("python-html5lib" ,python-html5lib-0.9) | |
55436048 RW |
6309 | ("python-six" ,python-six))) |
6310 | (native-inputs | |
6311 | `(("python-nose" ,python-nose))) | |
7bf837fd | 6312 | (home-page "https://github.com/jsocol/bleach") |
55436048 RW |
6313 | (synopsis "Whitelist-based HTML-sanitizing tool") |
6314 | (description "Bleach is an easy whitelist-based HTML-sanitizing tool.") | |
6315 | (license license:asl2.0))) | |
6316 | ||
6317 | (define-public python2-bleach | |
6318 | (package-with-python2 python-bleach)) | |
6319 | ||
60590a3a RW |
6320 | (define-public python-entrypoints |
6321 | (package | |
6322 | (name "python-entrypoints") | |
6323 | (version "0.2.2") | |
6324 | (source | |
6325 | (origin | |
6326 | (method url-fetch) | |
6327 | (uri (string-append "https://github.com/takluyver/entrypoints/archive/" | |
6328 | version ".tar.gz")) | |
6329 | (file-name (string-append name "-" version ".tar.gz")) | |
6330 | (sha256 | |
6331 | (base32 | |
6332 | "0azqlkh3j0za080lsf5crnhaxx3c93k9dpv5ihkhf5cppgw5sjz5")))) | |
6333 | (build-system python-build-system) | |
6334 | ;; The package does not come with a setup.py file, so we have to generate | |
6335 | ;; one ourselves. | |
6336 | (arguments | |
6337 | `(#:tests? #f | |
6338 | #:phases | |
6339 | (modify-phases %standard-phases | |
6340 | (add-after 'unpack 'create-setup.py | |
6341 | (lambda _ | |
6342 | (call-with-output-file "setup.py" | |
6343 | (lambda (port) | |
6344 | (format port "\ | |
6345 | from setuptools import setup | |
6346 | setup(name='entrypoints', version='~a', py_modules=['entrypoints']) | |
6347 | " ,version)))))))) | |
6348 | (home-page "https://github.com/takluyver/entrypoints") | |
6349 | (synopsis "Discover and load entry points from installed Python packages") | |
6350 | (description "Entry points are a way for Python packages to advertise | |
6351 | objects with some common interface. The most common examples are | |
6352 | @code{console_scripts} entry points, which define shell commands by | |
6353 | identifying a Python function to run. The @code{entrypoints} module contains | |
6354 | functions to find and load entry points.") | |
6355 | (license license:expat))) | |
6356 | ||
6357 | (define-public python2-entrypoints | |
6358 | (package-with-python2 python-entrypoints)) | |
6359 | ||
c60898a8 RW |
6360 | (define-public python-nbconvert |
6361 | (package | |
6362 | (name "python-nbconvert") | |
6363 | (version "5.0.0b1") | |
6364 | (source | |
6365 | (origin | |
6366 | (method url-fetch) | |
6367 | (uri (pypi-uri "nbconvert" version)) | |
6368 | (sha256 | |
6369 | (base32 | |
6370 | "0brclbb18l4nmd5qy3dl9wn05rjdh1fz4rmzdlfqacj12rcdvdgp")))) | |
6371 | (build-system python-build-system) | |
497355dc MB |
6372 | (arguments |
6373 | `(;; The "bdist_egg" target is disabled by default, causing the installation | |
6374 | ;; to fail. | |
6375 | #:configure-flags (list "bdist_egg") | |
6376 | ;; FIXME: 5 failures, 40 errors. | |
6377 | #:tests? #f)) | |
6378 | ;; #:phases | |
6379 | ;; (modify-phases %standard-phases | |
6380 | ;; (replace 'check | |
6381 | ;; (lambda _ | |
6382 | ;; (zero? (system* "py.test" "-v"))))) | |
6383 | (native-inputs | |
6384 | `(("python-pytest" ,python-pytest))) | |
c60898a8 RW |
6385 | (propagated-inputs |
6386 | `(("python-bleach" ,python-bleach) | |
6387 | ("python-entrypoints" ,python-entrypoints) | |
6388 | ("python-jinja2" ,python-jinja2) | |
6389 | ("python-jupyter-core" ,python-jupyter-core) | |
6390 | ("python-mistune" ,python-mistune) | |
6391 | ("python-nbformat" ,python-nbformat) | |
6392 | ("python-pygments" ,python-pygments) | |
c60898a8 RW |
6393 | ("python-traitlets" ,python-traitlets))) |
6394 | (home-page "http://jupyter.org") | |
6395 | (synopsis "Converting Jupyter Notebooks") | |
6396 | (description "The @code{nbconvert} tool, @{jupyter nbconvert}, converts | |
6397 | notebooks to various other formats via Jinja templates. It allows you to | |
6398 | convert an @code{.ipynb} notebook file into various static formats including: | |
6399 | ||
6400 | @enumerate | |
6401 | @item HTML | |
6402 | @item LaTeX | |
6403 | @item PDF | |
6404 | @item Reveal JS | |
6405 | @item Markdown (md) | |
6406 | @item ReStructured Text (rst) | |
6407 | @item executable script | |
6408 | @end enumerate\n") | |
6409 | (license license:bsd-3))) | |
6410 | ||
6411 | (define-public python2-nbconvert | |
6412 | (package-with-python2 python-nbconvert)) | |
6413 | ||
a0d62280 RW |
6414 | (define-public python-notebook |
6415 | (package | |
6416 | (name "python-notebook") | |
6417 | (version "4.2.3") | |
6418 | (source (origin | |
6419 | (method url-fetch) | |
6420 | (uri (pypi-uri "notebook" version)) | |
6421 | (sha256 | |
6422 | (base32 | |
6423 | "0laq5c2f21frq6xcdckgq7raqhznbjb0qs0357g612z87wyn1a9r")))) | |
6424 | (build-system python-build-system) | |
6425 | (arguments | |
6426 | `(#:phases | |
6427 | (modify-phases %standard-phases | |
6428 | (replace 'check | |
6429 | (lambda _ | |
6430 | ;; HOME must be set for tests | |
6431 | (setenv "HOME" "/tmp") | |
6432 | (zero? (system* "nosetests"))))))) | |
6433 | (propagated-inputs | |
6434 | `(("python-jupyter-core" ,python-jupyter-core) | |
6435 | ("python-nbformat" ,python-nbformat) | |
6436 | ("python-nbconvert" ,python-nbconvert) | |
6437 | ("python-ipython" ,python-ipython))) | |
6438 | (native-inputs | |
6439 | `(("python-nose" ,python-nose) | |
6440 | ("python-sphinx" ,python-sphinx) | |
6441 | ("python-requests" ,python-requests))) | |
6442 | (home-page "http://jupyter.org/") | |
6443 | (synopsis "Web-based notebook environment for interactive computing") | |
6444 | (description | |
6445 | "The Jupyter HTML notebook is a web-based notebook environment for | |
6446 | interactive computing.") | |
3a735ecf | 6447 | (properties `((python2-variant . ,(delay python2-notebook)))) |
a0d62280 RW |
6448 | (license license:bsd-3))) |
6449 | ||
6450 | (define-public python2-notebook | |
3a735ecf HG |
6451 | (let ((base (package-with-python2 |
6452 | (strip-python2-variant python-notebook)))) | |
6453 | (package (inherit base) | |
6454 | (native-inputs | |
6455 | `(("python2-mock" ,python2-mock) | |
6456 | ,@(package-native-inputs base))) | |
6457 | (arguments | |
6458 | (substitute-keyword-arguments (package-arguments base) | |
6459 | ((#:phases phases) | |
6460 | `(modify-phases ,phases | |
6461 | (add-before 'check 'disable-test-case | |
6462 | ;; The test requires network access to localhost. Curiously it | |
6463 | ;; fails with Python 2 only. Simply make the test-case return | |
6464 | ;; immediately. | |
6465 | (lambda _ | |
6466 | (substitute* | |
6467 | "notebook/services/nbconvert/tests/test_nbconvert_api.py" | |
6468 | (("formats = self.nbconvert_api") "return #"))))))))))) | |
a0d62280 | 6469 | |
d55724ed RW |
6470 | (define-public python-widgetsnbextension |
6471 | (package | |
6472 | (name "python-widgetsnbextension") | |
6473 | (version "1.2.6") | |
6474 | (source | |
6475 | (origin | |
6476 | (method url-fetch) | |
6477 | (uri (pypi-uri "widgetsnbextension" version)) | |
6478 | (sha256 | |
6479 | (base32 | |
6480 | "0lff2mrwrgsa1mxmwx3phl9xvy0jqfpg6khbmxy53jbq56rwy666")))) | |
6481 | (build-system python-build-system) | |
6482 | (propagated-inputs | |
6483 | `(("python-notebook" ,python-notebook))) | |
6484 | (native-inputs | |
58f5fae7 MB |
6485 | `(("python-certifi" ,python-certifi) |
6486 | ("python-nose" ,python-nose))) | |
3ca1545b | 6487 | (home-page "https://ipython.org") |
d55724ed RW |
6488 | (synopsis "IPython HTML widgets for Jupyter") |
6489 | (description "This package provides interactive HTML widgets for Jupyter | |
6490 | notebooks.") | |
6491 | (license license:bsd-3))) | |
6492 | ||
6493 | (define-public python2-widgetsnbextension | |
6494 | (package-with-python2 python-widgetsnbextension)) | |
6495 | ||
4fe2e344 RW |
6496 | (define-public python-ipywidgets |
6497 | (package | |
6498 | (name "python-ipywidgets") | |
6499 | (version "5.2.2") | |
6500 | (source | |
6501 | (origin | |
6502 | (method url-fetch) | |
6503 | (uri (pypi-uri "ipywidgets" version)) | |
6504 | (sha256 | |
6505 | (base32 | |
6506 | "1lk0qrr5l9a0z7qkkn30hv5832whxwxymf1l576fmmad0n7hkxms")))) | |
6507 | (build-system python-build-system) | |
6508 | ;; FIXME: it's not clear how to run the tests. | |
6509 | (arguments `(#:tests? #f)) | |
6510 | (propagated-inputs | |
6511 | `(("python-ipykernel" ,python-ipykernel) | |
6512 | ("python-ipython" ,python-ipython) | |
4fe2e344 RW |
6513 | ("python-traitlets" ,python-traitlets) |
6514 | ("python-widgetsnbextension" ,python-widgetsnbextension))) | |
3ca1545b | 6515 | (home-page "https://ipython.org") |
4fe2e344 RW |
6516 | (synopsis "IPython HTML widgets for Jupyter") |
6517 | (description "Ipywidgets are interactive HTML widgets for Jupyter | |
6518 | notebooks and the IPython kernel. Notebooks come alive when interactive | |
6519 | widgets are used. Users gain control of their data and can visualize changes | |
6520 | in the data.") | |
6521 | (license license:bsd-3))) | |
6522 | ||
6523 | (define-public python2-ipywidgets | |
6524 | (package-with-python2 python-ipywidgets)) | |
6525 | ||
8ceebf8f RW |
6526 | (define-public python-jupyter-console |
6527 | (package | |
6528 | (name "python-jupyter-console") | |
6529 | (version "5.0.0") | |
6530 | (source | |
6531 | (origin | |
6532 | (method url-fetch) | |
6533 | (uri (pypi-uri "jupyter_console" version)) | |
6534 | (sha256 | |
6535 | (base32 | |
6536 | "04acmkwsi99rcg3vb54c6n492zv35s92h2ahabc0w6wj976cipvx")))) | |
6537 | (build-system python-build-system) | |
6538 | ;; FIXME: it's not clear how to run the tests. | |
6539 | (arguments `(#:tests? #f)) | |
6540 | (propagated-inputs | |
6541 | `(("python-ipykernel" ,python-ipykernel) | |
6542 | ("python-ipython" ,python-ipython) | |
6543 | ("python-jupyter-client" ,python-jupyter-client) | |
6544 | ("python-prompt-toolkit" ,python-prompt-toolkit) | |
f3b98f4f | 6545 | ("python-pygments" ,python-pygments))) |
8ceebf8f RW |
6546 | (home-page "https://jupyter.org") |
6547 | (synopsis "Jupyter terminal console") | |
6548 | (description "This package provides a terminal-based console frontend for | |
6549 | Jupyter kernels. It also allows for console-based interaction with non-Python | |
6550 | Jupyter kernels such as IJulia and IRKernel.") | |
6551 | (license license:bsd-3))) | |
6552 | ||
6553 | (define-public python2-jupyter-console | |
6554 | (package-with-python2 python-jupyter-console)) | |
6555 | ||
ee8aab1f CB |
6556 | ;; The python-ipython and python-jupyter-console require each other. To get |
6557 | ;; the functionality in both packages working, strip down the | |
6558 | ;; python-jupyter-console package when using it as an input to python-ipython. | |
6559 | (define python-jupyter-console-minimal | |
6560 | (package | |
6561 | (inherit python-jupyter-console) | |
a5e3d59b | 6562 | (name "python-jupyter-console-minimal") |
ee8aab1f CB |
6563 | (arguments |
6564 | (substitute-keyword-arguments | |
6565 | (package-arguments python-jupyter-console) | |
6566 | ((#:phases phases) | |
6567 | `(modify-phases ,phases | |
6568 | (add-after 'install 'delete-bin | |
6569 | (lambda* (#:key outputs #:allow-other-keys) | |
6570 | ;; Delete the bin files, to avoid conflicts in profiles | |
6571 | ;; where python-ipython and python-jupyter-console are | |
6572 | ;; both present. | |
6573 | (delete-file-recursively | |
6574 | (string-append | |
6575 | (assoc-ref outputs "out") "/bin")))))))) | |
6576 | ;; Remove the python-ipython propagated input, to avoid the cycle | |
6577 | (propagated-inputs | |
6578 | (alist-delete | |
6579 | "python-ipython" | |
6580 | (package-propagated-inputs python-jupyter-console))))) | |
6581 | ||
c27ae827 RW |
6582 | (define-public jupyter |
6583 | (package | |
6584 | (name "jupyter") | |
6585 | (version "1.0.0") | |
6586 | (source | |
6587 | (origin | |
6588 | (method url-fetch) | |
6589 | (uri (pypi-uri "jupyter" version)) | |
6590 | (sha256 | |
6591 | (base32 | |
6592 | "0pwf3pminkzyzgx5kcplvvbvwrrzd3baa7lmh96f647k30rlpp6r")))) | |
6593 | (build-system python-build-system) | |
6594 | ;; FIXME: it's not clear how to run the tests. | |
6595 | (arguments `(#:tests? #f)) | |
6596 | (propagated-inputs | |
6597 | `(("python-ipykernel" ,python-ipykernel) | |
6598 | ("python-ipywidgets" ,python-ipywidgets) | |
6599 | ("python-jupyter-console" ,python-jupyter-console) | |
6600 | ("python-nbconvert" ,python-nbconvert) | |
f3b98f4f | 6601 | ("python-notebook" ,python-notebook))) |
c27ae827 RW |
6602 | (home-page "http://jupyter.org") |
6603 | (synopsis "Web application for interactive documents") | |
6604 | (description | |
6605 | "The Jupyter Notebook is a web application that allows you to create and | |
6606 | share documents that contain live code, equations, visualizations and | |
6607 | explanatory text. Uses include: data cleaning and transformation, numerical | |
6608 | simulation, statistical modeling, machine learning and much more.") | |
6609 | (license license:bsd-3))) | |
6610 | ||
816a6538 LC |
6611 | (define-public python-chardet |
6612 | (package | |
6613 | (name "python-chardet") | |
a54cb3ce | 6614 | (version "3.0.4") |
816a6538 LC |
6615 | (source |
6616 | (origin | |
6617 | (method url-fetch) | |
ef7dd2e2 | 6618 | (uri (pypi-uri "chardet" version)) |
816a6538 LC |
6619 | (sha256 |
6620 | (base32 | |
a54cb3ce CR |
6621 | "1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4")))) |
6622 | (native-inputs | |
6623 | `(("python-hypothesis" ,python-hypothesis) | |
6624 | ("python-pytest" ,python-pytest) | |
6625 | ("python-pytest-runner" ,python-pytest-runner))) | |
816a6538 | 6626 | (build-system python-build-system) |
816a6538 LC |
6627 | (home-page "https://github.com/chardet/chardet") |
6628 | (synopsis "Universal encoding detector for Python 2 and 3") | |
6629 | (description | |
6630 | "This package provides @code{chardet}, a Python module that can | |
6631 | automatically detect a wide range of file encodings.") | |
3f641af0 | 6632 | (license license:lgpl2.1+))) |
816a6538 LC |
6633 | |
6634 | (define-public python2-chardet | |
6635 | (package-with-python2 python-chardet)) | |
2fc5f186 | 6636 | |
1872f1bb KM |
6637 | (define-public python-docopt |
6638 | (package | |
6639 | (name "python-docopt") | |
6640 | (version "0.6.2") | |
6641 | (source | |
6642 | (origin | |
6643 | (method url-fetch) | |
6644 | ;; The release on PyPI does not include tests. | |
6645 | (uri (string-append | |
6646 | "https://github.com/docopt/docopt/archive/" | |
6647 | version ".tar.gz")) | |
6648 | (file-name (string-append name "-" version ".tar.gz")) | |
6649 | (sha256 | |
6650 | (base32 | |
6651 | "16bf890xbdz3m30rsv2qacklh2rdn1zrfspfnwzx9g7vwz8yw4r1")))) | |
6652 | (build-system python-build-system) | |
6653 | (native-inputs | |
f3b98f4f | 6654 | `(("python-pytest" ,python-pytest))) |
1872f1bb | 6655 | (arguments |
dc1d3cde KK |
6656 | `(#:phases |
6657 | (modify-phases %standard-phases | |
6658 | (replace 'check | |
6659 | (lambda _ (zero? (system* "py.test"))))))) | |
1872f1bb KM |
6660 | (home-page "http://docopt.org") |
6661 | (synopsis "Command-line interface description language for Python") | |
6662 | (description "This library allows the user to define a command-line | |
6663 | interface from a program's help message rather than specifying it | |
6664 | programatically with command-line parsers like @code{getopt} and | |
6665 | @code{argparse}.") | |
6666 | (license license:expat))) | |
6667 | ||
6668 | (define-public python2-docopt | |
6669 | (package-with-python2 python-docopt)) | |
6670 | ||
1b2f753d | 6671 | (define-public python-pythondialog |
2fc5f186 | 6672 | (package |
1b2f753d LC |
6673 | (name "python-pythondialog") |
6674 | (version "3.4.0") | |
2fc5f186 LF |
6675 | (source |
6676 | (origin | |
6677 | (method url-fetch) | |
1b2f753d | 6678 | (uri (pypi-uri "pythondialog" version)) |
b5f218be LF |
6679 | (sha256 |
6680 | (base32 | |
1ae44b80 | 6681 | "1728ghsran47jczn9bhlnkvk5bvqmmbihabgif5h705b84r1272c")))) |
b5f218be LF |
6682 | (build-system python-build-system) |
6683 | (arguments | |
6684 | `(#:phases | |
6685 | (modify-phases %standard-phases | |
6686 | (add-after 'unpack 'patch-path | |
6687 | (lambda* (#:key inputs #:allow-other-keys) | |
6688 | (let* ((dialog (assoc-ref inputs "dialog"))) | |
6689 | ;; Since this library really wants to grovel the search path, we | |
6690 | ;; must hardcode dialog's store path into it. | |
6691 | (substitute* "dialog.py" | |
6692 | (("os.getenv\\(\"PATH\", \":/bin:/usr/bin\"\\)") | |
6693 | (string-append "os.getenv(\"PATH\") + \":" dialog "/bin\""))) | |
6694 | #t)))) | |
b5f218be LF |
6695 | #:tests? #f)) ; no test suite |
6696 | (propagated-inputs | |
6697 | `(("dialog" ,dialog))) | |
6698 | (home-page "http://pythondialog.sourceforge.net/") | |
6699 | (synopsis "Python interface to the UNIX dialog utility") | |
6700 | (description "A Python wrapper for the dialog utility. Its purpose is to | |
6701 | provide an easy to use, pythonic and comprehensive Python interface to dialog. | |
6702 | This allows one to make simple text-mode user interfaces on Unix-like systems") | |
3f641af0 | 6703 | (license license:lgpl2.1) |
1ae44b80 LF |
6704 | (properties `((python2-variant . ,(delay python2-pythondialog)))))) |
6705 | ||
6706 | (define-public python2-pythondialog | |
6707 | (let ((base (package-with-python2 (strip-python2-variant python-pythondialog)))) | |
6708 | (package | |
6709 | (inherit base) | |
6710 | (version (package-version python-pythondialog)) | |
6711 | (source (origin | |
6712 | (method url-fetch) | |
6713 | (uri (pypi-uri "python2-pythondialog" version)) | |
6714 | (sha256 | |
6715 | (base32 | |
6716 | "0d8k7lxk50imdyx85lv8j98i4c93a71iwpapnl1506rpkbm9qvd9"))))))) | |
b5f218be | 6717 | |
99fffa8a LF |
6718 | (define-public python-configobj |
6719 | (package | |
6720 | (name "python-configobj") | |
6721 | (version "5.0.6") | |
6722 | (source (origin | |
6723 | (method url-fetch) | |
6724 | (uri (string-append | |
6725 | "https://pypi.python.org/packages/source/c/configobj/" | |
6726 | "configobj-" version ".tar.gz")) | |
6727 | (sha256 | |
6728 | (base32 | |
6729 | "00h9rcmws03xvdlfni11yb60bz3kxfvsj6dg6nrpzj71f03nbxd2")) | |
6730 | ;; Patch setup.py so it looks for python-setuptools, which is | |
6731 | ;; required to parse the keyword 'install_requires' in setup.py. | |
fc1adab1 | 6732 | (patches (search-patches "python-configobj-setuptools.patch")))) |
99fffa8a | 6733 | (build-system python-build-system) |
861f70c9 | 6734 | (propagated-inputs |
f3b98f4f | 6735 | `(("python-six" ,python-six))) |
99fffa8a LF |
6736 | (synopsis "Config file reading, writing and validation") |
6737 | (description "ConfigObj is a simple but powerful config file reader and | |
6738 | writer: an ini file round tripper. Its main feature is that it is very easy to | |
6739 | use, with a straightforward programmer’s interface and a simple syntax for | |
6740 | config files.") | |
6741 | (home-page "https://github.com/DiffSK/configobj") | |
3f641af0 | 6742 | (license license:bsd-3))) |
99fffa8a LF |
6743 | |
6744 | (define-public python2-configobj | |
6745 | (package-with-python2 python-configobj)) | |
79e8a291 LF |
6746 | |
6747 | (define-public python-configargparse | |
6748 | (package | |
6749 | (name "python-configargparse") | |
b89e3c77 | 6750 | (version "0.12.0") |
79e8a291 LF |
6751 | (source (origin |
6752 | (method url-fetch) | |
6753 | (uri (string-append | |
b89e3c77 | 6754 | "https://pypi.io/packages/source/C/ConfigArgParse/" |
79e8a291 LF |
6755 | "ConfigArgParse-" version ".tar.gz")) |
6756 | (sha256 | |
6757 | (base32 | |
b89e3c77 | 6758 | "0fgkiqh6r3rbkdq3k8c48m85g52k96686rw3a6jg4lcncrkpvk98")))) |
79e8a291 | 6759 | (build-system python-build-system) |
b89e3c77 KM |
6760 | (native-inputs |
6761 | `(("python-pyyaml" ,python-pyyaml))) | |
79e8a291 | 6762 | (arguments |
b89e3c77 KM |
6763 | `(#:phases |
6764 | (modify-phases %standard-phases | |
6765 | (replace 'check | |
6766 | (lambda _ | |
6767 | ;; Bypass setuptools-shim because one test relies on "setup.py" | |
6768 | ;; being the first argument passed to the python call. | |
6769 | ;; | |
6770 | ;; NOTE: Many tests do not run because they rely on Python's | |
6771 | ;; built-in test.test_argparse, but we remove the unit tests from | |
6772 | ;; our Python installation. | |
6773 | (zero? (system* "python" "setup.py" "test"))))))) | |
79e8a291 LF |
6774 | (synopsis "Replacement for argparse") |
6775 | (description "A drop-in replacement for argparse that allows options to also | |
6776 | be set via config files and/or environment variables.") | |
6777 | (home-page "https://github.com/bw2/ConfigArgParse") | |
6778 | (license license:expat))) | |
6779 | ||
6780 | (define-public python2-configargparse | |
6781 | (package-with-python2 python-configargparse)) | |
ab41f979 | 6782 | |
03f964a5 CM |
6783 | (define-public python-contextlib2 |
6784 | (package | |
6785 | (name "python-contextlib2") | |
6786 | (version "0.4.0") | |
6787 | (source | |
6788 | (origin | |
6789 | (method url-fetch) | |
6790 | (uri (pypi-uri "contextlib2" version)) | |
6791 | (sha256 | |
6792 | (base32 | |
6793 | "0cmp131dlh0d0zvw0aza1zd13glvngzk8lb4avks0hm7yxwdr9am")))) | |
6794 | (build-system python-build-system) | |
6795 | (arguments | |
6796 | `(#:phases | |
6797 | (modify-phases %standard-phases | |
6798 | (replace 'check | |
6799 | (lambda _ (zero? | |
6800 | (system* | |
b3546174 | 6801 | "python" "test_contextlib2.py" "-v"))))))) |
03f964a5 CM |
6802 | (home-page "http://contextlib2.readthedocs.org/") |
6803 | (synopsis "Tools for decorators and context managers") | |
6804 | (description "This module is primarily a backport of the Python | |
6805 | 3.2 contextlib to earlier Python versions. Like contextlib, it | |
6806 | provides utilities for common tasks involving decorators and context | |
6807 | managers. It also contains additional features that are not part of | |
6808 | the standard library.") | |
3f641af0 | 6809 | (license license:psfl))) |
03f964a5 CM |
6810 | |
6811 | (define-public python2-contextlib2 | |
6812 | (package-with-python2 python-contextlib2)) | |
210bf497 DT |
6813 | |
6814 | (define-public python-texttable | |
6815 | (package | |
6816 | (name "python-texttable") | |
4c4d4df3 | 6817 | (version "0.8.7") |
210bf497 DT |
6818 | (source |
6819 | (origin | |
6820 | (method url-fetch) | |
6821 | (uri (pypi-uri "texttable" version)) | |
6822 | (sha256 | |
6823 | (base32 | |
4c4d4df3 | 6824 | "1liiiydgkg37i46a418aw19fyf6z3ds51wdwwpyjbs12x0phhf4a")))) |
210bf497 DT |
6825 | (build-system python-build-system) |
6826 | (arguments '(#:tests? #f)) ; no tests | |
6827 | (home-page "https://github.com/foutaise/texttable/") | |
6828 | (synopsis "Python module for creating simple ASCII tables") | |
6829 | (description "Texttable is a Python module for creating simple ASCII | |
6830 | tables.") | |
3f641af0 | 6831 | (license license:lgpl2.1+))) |
210bf497 DT |
6832 | |
6833 | (define-public python2-texttable | |
6834 | (package-with-python2 python-texttable)) | |
67c52bb3 | 6835 | |
5c6eea2a LF |
6836 | (define-public python-atomicwrites |
6837 | (package | |
6838 | (name "python-atomicwrites") | |
c56ad5e2 | 6839 | (version "1.1.5") |
5c6eea2a LF |
6840 | (source (origin |
6841 | (method url-fetch) | |
6842 | (uri (pypi-uri "atomicwrites" version)) | |
6843 | (sha256 | |
6844 | (base32 | |
c56ad5e2 | 6845 | "11bm90fwm2avvf4f3ib8g925w7jr4m11vcsinn1bi6ns4bm32214")))) |
5c6eea2a LF |
6846 | (build-system python-build-system) |
6847 | (synopsis "Atomic file writes in Python") | |
6848 | (description "Library for atomic file writes using platform dependent tools | |
8f65585b | 6849 | for atomic file system operations.") |
5c6eea2a | 6850 | (home-page "https://github.com/untitaker/python-atomicwrites") |
f210e944 | 6851 | (license license:expat))) |
9bb6d184 LF |
6852 | |
6853 | (define-public python2-atomicwrites | |
f210e944 | 6854 | (package-with-python2 python-atomicwrites)) |
561bb3cb | 6855 | |
d1deb90b LF |
6856 | (define-public python-click-threading |
6857 | (package | |
6858 | (name "python-click-threading") | |
8f25c2e4 | 6859 | (version "0.4.4") |
d1deb90b LF |
6860 | (source (origin |
6861 | (method url-fetch) | |
19ecdbed | 6862 | (uri (pypi-uri "click-threading" version)) |
d1deb90b LF |
6863 | (sha256 |
6864 | (base32 | |
8f25c2e4 | 6865 | "1rsxc2fbkxlhwhlmxsdjzq3spn284l6rvjfcz9mbb17ibgdgmc5j")))) |
d1deb90b LF |
6866 | (build-system python-build-system) |
6867 | (propagated-inputs | |
6868 | `(("python-click" ,python-click))) | |
6869 | (synopsis "Utilities for multithreading in Click") | |
6870 | (description "This package provides utilities for multithreading in Click | |
6871 | applications.") | |
6872 | (home-page "https://github.com/click-contrib/click-threading") | |
6873 | (license license:expat))) | |
7b17cab9 LF |
6874 | |
6875 | (define-public python-click-log | |
6876 | (package | |
6877 | (name "python-click-log") | |
8cbbea15 | 6878 | (version "0.2.1") |
7b17cab9 LF |
6879 | (source (origin |
6880 | (method url-fetch) | |
6881 | (uri (pypi-uri "click-log" version)) | |
6882 | (sha256 | |
6883 | (base32 | |
8cbbea15 | 6884 | "1r1x85023cslb2pwldd089jjk573mk3w78cnashs77wrx7yz8fj9")))) |
7b17cab9 LF |
6885 | (build-system python-build-system) |
6886 | (propagated-inputs | |
6887 | `(("python-click" ,python-click))) | |
6888 | (synopsis "Logging for click applications") | |
6889 | (description "This package provides a Python library for logging Click | |
6890 | applications.") | |
6891 | (home-page "https://github.com/click-contrib/click-log") | |
6892 | (license license:expat))) | |
7b3a4ee4 LF |
6893 | |
6894 | (define-public python-apipkg | |
6895 | (package | |
6896 | (name "python-apipkg") | |
6897 | (version "1.4") | |
6898 | (source (origin | |
6899 | (method url-fetch) | |
6900 | (uri (pypi-uri "apipkg" version)) | |
6901 | (sha256 | |
6902 | (base32 | |
6903 | "1iks5701qnp3dlr3q1d9qm68y2plp2m029irhpz92a44psfkjf1f")))) | |
6904 | (build-system python-build-system) | |
328bb95d | 6905 | (native-inputs |
7b3a4ee4 LF |
6906 | `(("python-pytest" ,python-pytest))) |
6907 | (synopsis "Namespace control and lazy-import mechanism") | |
6908 | (description "With apipkg you can control the exported namespace of a Python | |
6909 | package and greatly reduce the number of imports for your users. It is a small | |
6910 | pure Python module that works on virtually all Python versions.") | |
6911 | (home-page "https://bitbucket.org/hpk42/apipkg") | |
f210e944 | 6912 | (license license:expat))) |
e08739c3 CAW |
6913 | |
6914 | (define-public python2-apipkg | |
f210e944 | 6915 | (package-with-python2 python-apipkg)) |
848964fe LF |
6916 | |
6917 | (define-public python-execnet | |
6918 | (package | |
6919 | (name "python-execnet") | |
6920 | (version "1.4.1") | |
6921 | (source (origin | |
6922 | (method url-fetch) | |
6923 | (uri (pypi-uri "execnet" version)) | |
6924 | (sha256 | |
6925 | (base32 | |
6926 | "1rpk1vyclhg911p3hql0m0nrpq7q7mysxnaaw6vs29cpa6kx8vgn")))) | |
6927 | (build-system python-build-system) | |
ca0eee9d LF |
6928 | (arguments |
6929 | `(;; 2 failed, 275 passed, 670 skipped, 4 xfailed | |
6930 | ;; The two test failures are caused by the lack of an `ssh` executable. | |
6931 | ;; The test suite can be run with pytest after the 'install' phase. | |
6932 | #:tests? #f)) | |
848964fe | 6933 | (native-inputs |
ca0eee9d LF |
6934 | `(("python-pytest" ,python-pytest) |
6935 | ("python-setuptools-scm" ,python-setuptools-scm))) | |
f22efa01 | 6936 | (propagated-inputs |
848964fe LF |
6937 | `(("python-apipkg" ,python-apipkg))) |
6938 | (synopsis "Rapid multi-Python deployment") | |
6939 | (description "Execnet provides a share-nothing model with | |
6940 | channel-send/receive communication for distributing execution across many | |
6941 | Python interpreters across version, platform and network barriers. It has a | |
d1e4ad1b | 6942 | minimal and fast API targeting the following uses: |
848964fe LF |
6943 | @enumerate |
6944 | @item distribute tasks to (many) local or remote CPUs | |
6945 | @item write and deploy hybrid multi-process applications | |
6946 | @item write scripts to administer multiple environments | |
6947 | @end enumerate") | |
6948 | (home-page "http://codespeak.net/execnet/") | |
f210e944 | 6949 | (license license:expat))) |
16c84f90 CAW |
6950 | |
6951 | (define-public python2-execnet | |
f210e944 | 6952 | (package-with-python2 python-execnet)) |
6720dbb4 | 6953 | |
5c299bf0 LF |
6954 | (define-public python-icalendar |
6955 | (package | |
6956 | (name "python-icalendar") | |
7df4194b | 6957 | (version "4.0.0") |
5c299bf0 LF |
6958 | (source (origin |
6959 | (method url-fetch) | |
6960 | (uri (pypi-uri "icalendar" version)) | |
6961 | (sha256 | |
6962 | (base32 | |
7df4194b | 6963 | "0jfp93x2pnpsbck92zw22dq7sl4pk0avv0gnb4x9vldrg6vlhyin")))) |
5c299bf0 LF |
6964 | (build-system python-build-system) |
6965 | (propagated-inputs | |
22d7360b | 6966 | `(("python-dateutil" ,python-dateutil) |
5c299bf0 LF |
6967 | ("python-pytz" ,python-pytz))) |
6968 | (synopsis "Python library for parsing iCalendar files") | |
6969 | (description "The icalendar package is a parser/generator of iCalendar | |
6970 | files for use with Python.") | |
6971 | (home-page "https://github.com/collective/icalendar") | |
3f641af0 | 6972 | (license license:bsd-2))) |
6bbbb53e LF |
6973 | |
6974 | (define-public python-sphinxcontrib-newsfeed | |
6975 | (package | |
6976 | (name "python-sphinxcontrib-newsfeed") | |
6977 | (version "0.1.4") | |
6978 | (source (origin | |
6979 | (method url-fetch) | |
6980 | (uri (pypi-uri "sphinxcontrib-newsfeed" version)) | |
6981 | (sha256 | |
6982 | (base32 | |
6983 | "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p")))) | |
3d2a544c | 6984 | (arguments '(#:tests? #f)) ; No tests. |
6bbbb53e LF |
6985 | (build-system python-build-system) |
6986 | (propagated-inputs | |
251ed7f2 | 6987 | `(("python-sphinx" ,python-sphinx))) |
6bbbb53e LF |
6988 | (synopsis "News Feed extension for Sphinx") |
6989 | (description "Sphinxcontrib-newsfeed is an extension for adding a simple | |
6990 | Blog, News or Announcements section to a Sphinx website.") | |
6991 | (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed") | |
3f641af0 | 6992 | (license license:bsd-2))) |
2216e15c SB |
6993 | |
6994 | (define-public python-args | |
6995 | (package | |
6996 | (name "python-args") | |
6997 | (version "0.1.0") | |
6998 | (source (origin | |
6999 | (method url-fetch) | |
7000 | (uri (pypi-uri "args" version)) | |
7001 | (sha256 | |
7002 | (base32 | |
7003 | "057qzi46h5dmxdqknsbrssn78lmqjlnm624iqdhrnpk26zcbi1d7")))) | |
7004 | (build-system python-build-system) | |
2216e15c SB |
7005 | (home-page "https://github.com/kennethreitz/args") |
7006 | (synopsis "Command-line argument parser") | |
7007 | (description | |
7008 | "This library provides a Python module to parse command-line arguments.") | |
3f641af0 | 7009 | (license license:bsd-3))) |
2216e15c SB |
7010 | |
7011 | (define-public python2-args | |
7012 | (package-with-python2 python-args)) | |
c06a3de9 SB |
7013 | |
7014 | (define-public python-clint | |
7015 | (package | |
7016 | (name "python-clint") | |
7017 | (version "0.5.1") | |
7018 | (source (origin | |
7019 | (method url-fetch) | |
7020 | (uri (pypi-uri "clint" version)) | |
7021 | (sha256 | |
7022 | (base32 | |
7023 | "1an5lkkqk1zha47198p42ji3m94xmzx1a03dn7866m87n4r4q8h5")))) | |
7024 | (build-system python-build-system) | |
6145b604 MB |
7025 | (arguments |
7026 | '(#:phases | |
7027 | (modify-phases %standard-phases | |
7028 | (replace 'check | |
7029 | (lambda _ | |
7030 | (zero? (system* "py.test" "-v"))))))) | |
7031 | (native-inputs | |
7032 | `(("python-pytest" ,python-pytest))) | |
f22efa01 | 7033 | (propagated-inputs |
f3b98f4f | 7034 | `(("python-args" ,python-args))) |
c06a3de9 SB |
7035 | (home-page "https://github.com/kennethreitz/clint") |
7036 | (synopsis "Command-line interface tools") | |
7037 | (description | |
7038 | "Clint is a Python module filled with a set of tools for developing | |
7039 | command-line applications, including tools for colored and indented | |
7040 | output, progress bar display, and pipes.") | |
3f641af0 | 7041 | (license license:isc))) |
c06a3de9 SB |
7042 | |
7043 | (define-public python2-clint | |
7044 | (package-with-python2 python-clint)) | |
4ecdeef8 SB |
7045 | |
7046 | (define-public python-astor | |
7047 | (package | |
7048 | (name "python-astor") | |
7049 | (version "0.5") | |
7050 | (source (origin | |
7051 | (method url-fetch) | |
7052 | (uri (pypi-uri "astor" version)) | |
7053 | (sha256 | |
7054 | (base32 | |
7055 | "1fdafq5hkis1fxqlmhw0sn44zp2ar46nxhbc22cvwg7hsd8z5gsa")))) | |
7056 | (build-system python-build-system) | |
4ecdeef8 SB |
7057 | (home-page "https://github.com/berkerpeksag/astor") |
7058 | (synopsis "Read and write Python ASTs") | |
7059 | (description | |
7060 | "Astor is designed to allow easy manipulation of Python source via the | |
7061 | Abstract Syntax Tree.") | |
3f641af0 | 7062 | (license license:bsd-3))) |
4ecdeef8 SB |
7063 | |
7064 | (define-public python2-astor | |
7065 | (package-with-python2 python-astor)) | |
e224b7d0 SB |
7066 | |
7067 | (define-public python-rply | |
7068 | (package | |
7069 | (name "python-rply") | |
7070 | (version "0.7.4") | |
7071 | (source (origin | |
7072 | (method url-fetch) | |
7073 | (uri (pypi-uri "rply" version)) | |
7074 | (sha256 | |
7075 | (base32 | |
7076 | "12rp1d9ba7nvd5rhaxi6xzx1rm67r1k1ylsrkzhpwnphqpb06cvj")))) | |
7077 | (build-system python-build-system) | |
f22efa01 | 7078 | (propagated-inputs |
f3b98f4f | 7079 | `(("python-appdirs" ,python-appdirs))) |
e224b7d0 SB |
7080 | (home-page "https://github.com/alex/rply") |
7081 | (synopsis "Parser generator for Python") | |
7082 | (description | |
7083 | "This package provides a pure Python based parser generator, that also | |
7084 | works with RPython. It is a more-or-less direct port of David Bazzley's PLY, | |
7085 | with a new public API, and RPython support.") | |
3f641af0 | 7086 | (license license:bsd-3))) |
e224b7d0 SB |
7087 | |
7088 | (define-public python2-rply | |
7089 | (package-with-python2 python-rply)) | |
c3e919d7 SB |
7090 | |
7091 | (define-public python-hy | |
7092 | (package | |
7093 | (name "python-hy") | |
ad3c61fc | 7094 | (version "0.13.0") |
c3e919d7 SB |
7095 | (source (origin |
7096 | (method url-fetch) | |
7097 | (uri (pypi-uri "hy" version)) | |
7098 | (sha256 | |
7099 | (base32 | |
ad3c61fc | 7100 | "19sfymaksx9jhksfnb15ahid46mzrhdfzz6yy2craz2qnzvpmky8")))) |
c3e919d7 | 7101 | (build-system python-build-system) |
15c37077 MB |
7102 | (arguments |
7103 | '(#:phases | |
7104 | (modify-phases %standard-phases | |
7105 | (replace 'check | |
7106 | (lambda _ | |
7107 | ;; Tests require write access to HOME. | |
7108 | (setenv "HOME" "/tmp") | |
7109 | (zero? (system* "nosetests"))))))) | |
7110 | (native-inputs | |
7111 | `(("python-coverage" ,python-coverage) | |
7112 | ("python-nose" ,python-nose))) | |
f22efa01 | 7113 | (propagated-inputs |
c3e919d7 SB |
7114 | `(("python-astor" ,python-astor) |
7115 | ("python-clint" ,python-clint) | |
f3b98f4f | 7116 | ("python-rply" ,python-rply))) |
c3e919d7 SB |
7117 | (home-page "http://hylang.org/") |
7118 | (synopsis "Lisp frontend to Python") | |
7119 | (description | |
7120 | "Hy is a dialect of Lisp that's embedded in Python. Since Hy transforms | |
7121 | its Lisp code into the Python Abstract Syntax Tree, you have the whole world of | |
7122 | Python at your fingertips, in Lisp form.") | |
7123 | (license license:expat))) | |
7124 | ||
7125 | (define-public python2-hy | |
7126 | (package-with-python2 python-hy)) | |
7a5b944e | 7127 | |
1abe448d EF |
7128 | (define-public python2-functools32 |
7129 | (package | |
7130 | (name "python2-functools32") | |
7131 | (version "3.2.3-2") | |
7132 | (source | |
7133 | (origin | |
7134 | (method url-fetch) | |
7135 | (uri (pypi-uri "functools32" version)) | |
7136 | (sha256 | |
7137 | (base32 | |
7138 | "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn")))) | |
7139 | (build-system python-build-system) | |
7140 | (arguments | |
7141 | `(#:python ,python-2 | |
7142 | #:tests? #f)) ; no test target | |
1abe448d EF |
7143 | (home-page "https://github.com/MiCHiLU/python-functools32") |
7144 | (synopsis | |
7145 | "Backport of the functools module from Python 3.2.3") | |
7146 | (description | |
7147 | "This package is a backport of the @code{functools} module from Python | |
7148 | 3.2.3 for use with older versions of Python and PyPy.") | |
7149 | (license license:expat))) | |
7150 | ||
550bd98b MB |
7151 | (define-public python2-subprocess32 |
7152 | (package | |
7153 | (name "python2-subprocess32") | |
7154 | (version "3.2.7") | |
7155 | (source (origin | |
7156 | (method url-fetch) | |
7157 | (uri (pypi-uri "subprocess32" version)) | |
7158 | (sha256 | |
7159 | (base32 | |
7160 | "14350dhhlhyz5gqzi3lihn9m6lvskx5mcb20srx1kgsk9i50li8y")) | |
7161 | (patches | |
7162 | (search-patches "python2-subprocess32-disable-input-test.patch")))) | |
7163 | (build-system python-build-system) | |
7164 | (arguments | |
7165 | `(#:python ,python-2 | |
7166 | #:phases | |
7167 | (modify-phases %standard-phases | |
7168 | (add-after 'unpack 'patch-/bin/sh | |
7169 | (lambda _ | |
7170 | (substitute* '("subprocess32.py" | |
7171 | "test_subprocess32.py") | |
7172 | (("/bin/sh") (which "sh"))) | |
7173 | #t)) | |
7174 | (delete 'check) | |
7175 | (add-after 'install 'check | |
7176 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
7177 | ;; For some reason this package fails to import | |
7178 | ;; _posixsubprocess.so when PYTHONPATH is set to the build | |
7179 | ;; directory. Running tests after install is easier. | |
7180 | (add-installed-pythonpath inputs outputs) | |
7181 | (zero? (system* "python" "test_subprocess32.py"))))))) | |
7182 | (home-page "https://github.com/google/python-subprocess32") | |
7183 | (synopsis "Backport of the subprocess module from Python 3.2") | |
7184 | (description | |
7185 | "This is a backport of the @code{subprocess} standard library module | |
7186 | from Python 3.2 and 3.3 for use on Python 2. It includes bugfixes and some | |
7187 | new features. On POSIX systems it is guaranteed to be reliable when used | |
7188 | in threaded applications. It includes timeout support from Python 3.3 but | |
7189 | otherwise matches 3.2’s API.") | |
7190 | (license license:psfl))) | |
7191 | ||
877889f3 | 7192 | (define-public python2-futures |
7a5b944e | 7193 | (package |
877889f3 | 7194 | (name "python2-futures") |
e17a1248 | 7195 | (version "3.0.5") |
7a5b944e EF |
7196 | (source |
7197 | (origin | |
7198 | (method url-fetch) | |
7199 | (uri (pypi-uri "futures" version)) | |
7200 | (sha256 | |
7201 | (base32 | |
e17a1248 | 7202 | "1pw1z4329xvlabdpwqa6b7v2fxf7hl64m4cgr22ckbym8m8m4hh5")))) |
7a5b944e | 7203 | (build-system python-build-system) |
877889f3 | 7204 | (arguments `(#:python ,python-2)) |
7a5b944e EF |
7205 | (home-page "https://github.com/agronholm/pythonfutures") |
7206 | (synopsis | |
7207 | "Backport of the concurrent.futures package from Python 3.2") | |
7208 | (description | |
7209 | "The concurrent.futures module provides a high-level interface for | |
7210 | asynchronously executing callables. This package backports the | |
7211 | concurrent.futures package from Python 3.2") | |
3f641af0 | 7212 | (license license:bsd-3))) |
7a5b944e | 7213 | |
5cb2fe44 EF |
7214 | (define-public python-promise |
7215 | (package | |
7216 | (name "python-promise") | |
7217 | (version "0.4.2") | |
7218 | (source | |
7219 | (origin | |
7220 | (method url-fetch) | |
7221 | (uri (pypi-uri "promise" version)) | |
7222 | (sha256 | |
7223 | (base32 | |
7224 | "1k19ms8l3d5jzjh557rgkxb5sg4mqgfc315rn4hx1z3n8qq6lr3h")))) | |
7225 | (build-system python-build-system) | |
7226 | ;; Tests wants python-futures, which is a python2 only program, and | |
7227 | ;; can't be found by python-promise at test time. | |
7228 | (arguments `(#:tests? #f)) | |
7229 | (home-page "https://github.com/syrusakbary/promise") | |
7230 | (synopsis "Promises/A+ implementation for Python") | |
7231 | (description | |
7232 | "Promises/A+ implementation for Python") | |
7233 | (properties `((python2-variant . ,(delay python2-promise)))) | |
7234 | (license license:expat))) | |
7235 | ||
7236 | (define-public python2-promise | |
7237 | (let ((promise (package-with-python2 | |
7238 | (strip-python2-variant python-promise)))) | |
7239 | (package (inherit promise) | |
7240 | (arguments (substitute-keyword-arguments (package-arguments promise) | |
7241 | ((#:tests? _) #t))) | |
7242 | (native-inputs | |
7243 | `(("python2-futures" ,python2-futures) | |
7244 | ("python2-pytest" ,python2-pytest) | |
5cb2fe44 EF |
7245 | ,@(package-native-inputs promise)))))) |
7246 | ||
2b2f2fc1 DT |
7247 | (define-public python-colorama |
7248 | (package | |
7249 | (name "python-colorama") | |
f92576f9 | 7250 | (version "0.3.7") |
2b2f2fc1 DT |
7251 | (source |
7252 | (origin | |
7253 | (method url-fetch) | |
7254 | (uri (pypi-uri "colorama" version)) | |
7255 | (sha256 | |
7256 | (base32 | |
f92576f9 | 7257 | "0avqkn6362v7k2kg3afb35g4sfdvixjgy890clip4q174p9whhz0")))) |
2b2f2fc1 | 7258 | (build-system python-build-system) |
46e110cc | 7259 | (synopsis "Colored terminal text rendering for Python") |
2b2f2fc1 DT |
7260 | (description "Colorama is a Python library for rendering colored terminal |
7261 | text.") | |
7262 | (home-page "https://pypi.python.org/pypi/colorama") | |
3f641af0 | 7263 | (license license:bsd-3))) |
2b2f2fc1 DT |
7264 | |
7265 | (define-public python2-colorama | |
7266 | (package-with-python2 python-colorama)) | |
f5bcec6e DT |
7267 | |
7268 | (define-public python-rsa | |
7269 | (package | |
7270 | (name "python-rsa") | |
ecd68c53 | 7271 | (version "3.4.2") |
f5bcec6e DT |
7272 | (source |
7273 | (origin | |
7274 | (method url-fetch) | |
7275 | (uri (pypi-uri "rsa" version)) | |
7276 | (sha256 | |
7277 | (base32 | |
ecd68c53 | 7278 | "1dcxvszbikgzh99ybdc7jq0zb9wspy2ds8z9mjsqiyv3q884xpr5")))) |
f5bcec6e | 7279 | (build-system python-build-system) |
f22efa01 | 7280 | (propagated-inputs |
f3b98f4f | 7281 | `(("python-pyasn1" ,python-pyasn1))) |
f5bcec6e DT |
7282 | (synopsis "Pure-Python RSA implementation") |
7283 | (description "Python-RSA is a pure-Python RSA implementation. It supports | |
7284 | encryption and decryption, signing and verifying signatures, and key | |
7285 | generation according to PKCS#1 version 1.5. It can be used as a Python | |
7286 | library as well as on the command line.") | |
9be5ecdf | 7287 | (home-page "https://stuvel.eu/rsa") |
3f641af0 | 7288 | (license license:asl2.0))) |
f5bcec6e DT |
7289 | |
7290 | (define-public python2-rsa | |
7291 | (package-with-python2 python-rsa)) | |
c0aacfa5 DT |
7292 | |
7293 | (define-public python-pluggy | |
7294 | (package | |
7295 | (name "python-pluggy") | |
7296 | (version "0.3.1") | |
7297 | (source | |
7298 | (origin | |
7299 | (method url-fetch) | |
7300 | (uri (pypi-uri "pluggy" version)) | |
7301 | (sha256 | |
7302 | (base32 | |
7303 | "18qfzfm40bgx672lkg8q9x5hdh76n7vax99aank7vh2nw21wg70m")))) | |
7304 | (build-system python-build-system) | |
c0aacfa5 DT |
7305 | (synopsis "Plugin and hook calling mechanism for Python") |
7306 | (description "Pluggy is an extraction of the plugin manager as used by | |
7307 | Pytest but stripped of Pytest specific details.") | |
7308 | (home-page "https://pypi.python.org/pypi/pluggy") | |
7309 | (license license:expat))) | |
7310 | ||
7311 | (define-public python2-pluggy | |
7312 | (package-with-python2 python-pluggy)) | |
a4af21ca DT |
7313 | |
7314 | (define-public python-tox | |
7315 | (package | |
7316 | (name "python-tox") | |
9bb7c05e | 7317 | (version "2.8.1") |
a4af21ca DT |
7318 | (source |
7319 | (origin | |
7320 | (method url-fetch) | |
7321 | (uri (pypi-uri "tox" version)) | |
7322 | (sha256 | |
7323 | (base32 | |
9bb7c05e | 7324 | "1drp6mwm8wdypjym15ia8lwjxbhcksb9vzxg4ay5dh4ji57by2ny")))) |
a4af21ca DT |
7325 | (build-system python-build-system) |
7326 | (arguments | |
7ba07edf HG |
7327 | ;; FIXME: Tests require pytest-timeout, which itself requires |
7328 | ;; pytest>=2.8.0 for installation. | |
a4af21ca | 7329 | '(#:tests? #f)) |
482d9591 HG |
7330 | (propagated-inputs |
7331 | `(("python-pluggy" ,python-pluggy) ; >=0.3.0,<0.4.0 | |
a4af21ca | 7332 | ("python-py" ,python-py) |
482d9591 | 7333 | ("python-virtualenv" ,python-virtualenv))) |
328bb95d | 7334 | (native-inputs |
7ba07edf | 7335 | `(; FIXME: Missing: ("python-pytest-timeout" ,python-pytest-timeout) |
c98f9c52 CR |
7336 | ("python-pytest" ,python-pytest) ; >= 2.3.5 |
7337 | ("python-setuptools-scm" ,python-setuptools-scm))) | |
a4af21ca DT |
7338 | (home-page "http://tox.testrun.org/") |
7339 | (synopsis "Virtualenv-based automation of test activities") | |
7340 | (description "Tox is a generic virtualenv management and test command line | |
7341 | tool. It can be used to check that a package installs correctly with | |
7342 | different Python versions and interpreters, or run tests in each type of | |
7343 | supported environment, or act as a frontend to continuous integration | |
7344 | servers.") | |
7345 | (license license:expat))) | |
7346 | ||
7347 | (define-public python2-tox | |
7348 | (package-with-python2 python-tox)) | |
ba9da248 DT |
7349 | |
7350 | (define-public python-jmespath | |
7351 | (package | |
7352 | (name "python-jmespath") | |
7353 | (version "0.9.0") | |
7354 | (source | |
7355 | (origin | |
7356 | (method url-fetch) | |
7357 | (uri (pypi-uri "jmespath" version)) | |
7358 | (sha256 | |
7359 | (base32 | |
7360 | "0g9xvl69y7nr3w7ag4fsp6sm4fqf6vrqjw7504x2hzrrsh3ampq8")))) | |
7361 | (build-system python-build-system) | |
52a75a83 MB |
7362 | (native-inputs |
7363 | `(("python-nose" ,python-nose))) | |
ba9da248 DT |
7364 | (synopsis "JSON Matching Expressions") |
7365 | (description "JMESPath (pronounced “james path”) is a Python library that | |
7366 | allows one to declaratively specify how to extract elements from a JSON | |
7367 | document.") | |
7368 | (home-page "https://github.com/jmespath/jmespath.py") | |
7369 | (license license:expat))) | |
7370 | ||
7371 | (define-public python2-jmespath | |
7372 | (package-with-python2 python-jmespath)) | |
935fcd5c DT |
7373 | |
7374 | (define-public python-botocore | |
7375 | (package | |
7376 | (name "python-botocore") | |
01fc102e | 7377 | (version "1.7.9") |
935fcd5c DT |
7378 | (source |
7379 | (origin | |
7380 | (method url-fetch) | |
7381 | (uri (pypi-uri "botocore" version)) | |
7382 | (sha256 | |
7383 | (base32 | |
01fc102e | 7384 | "02b1bw25r1wdjs5yppb1h9igf11wj092biriv2yg8hzp5r0wrkmg")))) |
935fcd5c | 7385 | (build-system python-build-system) |
877fdac9 MB |
7386 | (arguments |
7387 | ;; FIXME: Many tests are failing. | |
7388 | '(#:tests? #f)) | |
482d9591 | 7389 | (propagated-inputs |
22d7360b | 7390 | `(("python-dateutil" ,python-dateutil) |
935fcd5c | 7391 | ("python-docutils" ,python-docutils) |
482d9591 | 7392 | ("python-jmespath" ,python-jmespath))) |
8fa6890b | 7393 | (native-inputs |
482d9591 | 7394 | `(("python-mock" ,python-mock) |
935fcd5c | 7395 | ("python-nose" ,python-nose) |
482d9591 | 7396 | ("behave" ,behave) |
935fcd5c | 7397 | ("python-tox" ,python-tox) |
482d9591 | 7398 | ("python-wheel" ,python-wheel))) |
935fcd5c DT |
7399 | (home-page "https://github.com/boto/botocore") |
7400 | (synopsis "Low-level interface to AWS") | |
7401 | (description "Botocore is a Python library that provides a low-level | |
7402 | interface to the Amazon Web Services (AWS) API.") | |
3f641af0 | 7403 | (license license:asl2.0))) |
935fcd5c DT |
7404 | |
7405 | (define-public python2-botocore | |
7406 | (package-with-python2 python-botocore)) | |
f861b8b8 | 7407 | |
7637de23 | 7408 | (define-public python-xdo |
0bdc1671 | 7409 | (package |
7637de23 | 7410 | (name "python-xdo") |
e871c332 | 7411 | (version "0.3") |
0bdc1671 CAW |
7412 | (source (origin |
7413 | (method url-fetch) | |
7414 | (uri (string-append | |
7415 | "http://http.debian.net/debian/pool/main/p/python-xdo/" | |
7416 | "python-xdo_" version ".orig.tar.gz")) | |
7417 | (sha256 | |
7418 | (base32 | |
e871c332 | 7419 | "1vqh1n5yy5dhnq312kwrl90fnck4v26is3lq3lxdvcn60vv19da0")))) |
0bdc1671 CAW |
7420 | (build-system python-build-system) |
7421 | (arguments | |
736cfc10 SB |
7422 | '(#:phases |
7423 | (modify-phases %standard-phases | |
7424 | (add-before 'install 'patch-libxdo-path | |
7425 | ;; Hardcode the path of dynamically loaded libxdo library. | |
7426 | (lambda* (#:key inputs #:allow-other-keys) | |
7427 | (let ((libxdo (string-append | |
7428 | (assoc-ref inputs "xdotool") | |
7429 | "/lib/libxdo.so"))) | |
7430 | (substitute* "xdo/_xdo.py" | |
7431 | (("find_library\\(\"xdo\"\\)") | |
7432 | (simple-format #f "\"~a\"" libxdo))) | |
7433 | #t)))) | |
7434 | #:tests? #f)) ; no tests provided | |
0b5e0863 SB |
7435 | (propagated-inputs |
7436 | `(("python-six" ,python-six))) | |
0bdc1671 CAW |
7437 | (inputs |
7438 | `(("xdotool" ,xdotool) | |
7439 | ("libX11" ,libx11))) | |
7440 | (home-page "https://tracker.debian.org/pkg/python-xdo") | |
7441 | (synopsis "Python library for simulating X11 keyboard/mouse input") | |
7442 | (description "Provides bindings to libxdo for manipulating X11 via simulated | |
7443 | input. (Note that this is mostly a legacy library; you may wish to look at | |
7444 | python-xdo for newer bindings.)") | |
3f641af0 | 7445 | (license license:bsd-3))) |
0bdc1671 | 7446 | |
7637de23 LF |
7447 | (define-public python2-xdo |
7448 | (package-with-python2 python-xdo)) | |
7449 | ||
50aaec25 DT |
7450 | (define-public python-mako |
7451 | (package | |
7452 | (name "python-mako") | |
3753f2e6 | 7453 | (version "1.0.6") |
50aaec25 DT |
7454 | (source |
7455 | (origin | |
7456 | (method url-fetch) | |
7457 | (uri (pypi-uri "Mako" version)) | |
7458 | (sha256 | |
7459 | (base32 | |
3753f2e6 | 7460 | "03dyxgjknp4ffsv7vwfd28l5bbpzi0ylp20543wpg3iahyyrwma8")))) |
50aaec25 | 7461 | (build-system python-build-system) |
482d9591 HG |
7462 | (propagated-inputs |
7463 | `(("python-markupsafe" ,python-markupsafe))) | |
50aaec25 | 7464 | (native-inputs |
482d9591 | 7465 | `(("python-mock" ,python-mock) |
e435af5c MB |
7466 | ("python-nose" ,python-nose) |
7467 | ("python-pytest" ,python-pytest))) | |
50aaec25 DT |
7468 | (home-page "http://www.makotemplates.org/") |
7469 | (synopsis "Templating language for Python") | |
7470 | (description "Mako is a templating language for Python that compiles | |
7471 | templates into Python modules.") | |
f210e944 | 7472 | (license license:expat))) |
50aaec25 DT |
7473 | |
7474 | (define-public python2-mako | |
f210e944 | 7475 | (package-with-python2 python-mako)) |
ae00a41f CAW |
7476 | |
7477 | (define-public python-waitress | |
7478 | (package | |
7479 | (name "python-waitress") | |
7480 | (version "0.8.10") | |
7481 | (source | |
7482 | (origin | |
7483 | (method url-fetch) | |
7484 | (uri (pypi-uri "waitress" version)) | |
7485 | (sha256 | |
7486 | (base32 | |
7487 | "017n9ra6vvmq9d5sfhdzyzr1mg15x2hj2dhm4pdlw98c1ypw2h3w")))) | |
7488 | (build-system python-build-system) | |
7489 | (home-page "https://github.com/Pylons/waitress") | |
7490 | (synopsis "Waitress WSGI server") | |
7491 | (description "Waitress is meant to be a production-quality pure-Python WSGI | |
7492 | server with very acceptable performance.") | |
f210e944 | 7493 | (license license:zpl2.1))) |
ae00a41f CAW |
7494 | |
7495 | (define-public python2-waitress | |
f210e944 | 7496 | (package-with-python2 python-waitress)) |
778a284b | 7497 | |
1cf53652 CAW |
7498 | (define-public python-pyquery |
7499 | (package | |
7500 | (name "python-pyquery") | |
ab0c3429 | 7501 | (version "1.2.17") |
1cf53652 CAW |
7502 | (source |
7503 | (origin | |
7504 | (method url-fetch) | |
7505 | (uri (pypi-uri "pyquery" version)) | |
7506 | (sha256 | |
7507 | (base32 | |
ab0c3429 | 7508 | "1xia20wm0vx5dk85kcwgh13bylz8qh47ffjxssd2586r60xi783a")))) |
1cf53652 | 7509 | (build-system python-build-system) |
2ddbfa8c LF |
7510 | (native-inputs |
7511 | `(("python-webob" ,python-webob) | |
7512 | ("python-webtest" ,python-webtest))) | |
1cf53652 CAW |
7513 | (propagated-inputs |
7514 | `(("python-lxml" ,python-lxml) | |
7515 | ("python-cssselect" ,python-cssselect))) | |
7516 | (home-page "https://github.com/gawel/pyquery") | |
7517 | (synopsis "Make jQuery-like queries on xml documents") | |
7518 | (description "pyquery allows you to make jQuery queries on xml documents. | |
7519 | The API is as much as possible the similar to jQuery. pyquery uses lxml for | |
7520 | fast xml and html manipulation.") | |
f210e944 | 7521 | (license license:bsd-3))) |
1cf53652 CAW |
7522 | |
7523 | (define-public python2-pyquery | |
f210e944 | 7524 | (package-with-python2 python-pyquery)) |
aa6313d6 | 7525 | |
4cb122cd CAW |
7526 | (define-public python-anyjson |
7527 | (package | |
7528 | (name "python-anyjson") | |
7529 | (version "0.3.3") | |
7530 | (source | |
7531 | (origin | |
7532 | (method url-fetch) | |
7533 | (uri (pypi-uri "anyjson" version)) | |
7534 | (sha256 | |
7535 | (base32 | |
7536 | "1fjph4alvcscsl5d4b6qpv1yh31jy05jxi1l0xff7lws7j32v09p")))) | |
7537 | (build-system python-build-system) | |
7538 | (arguments | |
7539 | `(;; We could possibly get tests working, but on Python 3 it's not so easy. | |
7540 | ;; Very strangely, 2to3 is run *during setup.py install* (or bdist, or | |
7541 | ;; whatever) so this transformation needs to be done before the tests | |
7542 | ;; can be run. Maybe we could add a build step to transform beforehand | |
7543 | ;; but it could be annoying/difficult. | |
7544 | ;; We can enable tests for the Python 2 version, though, and do below. | |
7545 | #:tests? #f)) | |
9be5ecdf | 7546 | (home-page "https://bitbucket.org/runeh/anyjson/") |
4cb122cd CAW |
7547 | (synopsis |
7548 | "Wraps best available JSON implementation in a common interface") | |
7549 | (description | |
7550 | "Anyjson loads whichever is the fastest JSON module installed | |
7551 | and provides a uniform API regardless of which JSON implementation is used.") | |
3f641af0 | 7552 | (license license:bsd-3) |
4cb122cd CAW |
7553 | (properties `((python2-variant . ,(delay python2-anyjson)))))) |
7554 | ||
7555 | (define-public python2-anyjson | |
7556 | (let ((anyjson (package-with-python2 | |
7557 | (strip-python2-variant python-anyjson)))) | |
7558 | (package | |
7559 | (inherit anyjson) | |
7560 | (arguments `(;; Unlike the python 3 variant, we do run tests. See above! | |
7561 | #:tests? #t | |
7562 | ,@(package-arguments anyjson))) | |
00e10c6e | 7563 | (native-inputs `(("python2-nose" ,python2-nose)))))) |
8dfceab7 CAW |
7564 | |
7565 | (define-public python-amqp | |
7566 | (package | |
7567 | (name "python-amqp") | |
7568 | (version "1.4.9") | |
7569 | (source | |
7570 | (origin | |
7571 | (method url-fetch) | |
7572 | (uri (pypi-uri "amqp" version)) | |
7573 | (sha256 | |
7574 | (base32 | |
7575 | "06n6q0kxhjnbfz3vn8x9yz09lwmn1xi9d6wxp31h5jbks0b4vsid")))) | |
7576 | (build-system python-build-system) | |
7577 | (native-inputs | |
7578 | `(("python-nose" ,python-nose) | |
7579 | ("python-mock" ,python-mock))) | |
7bf837fd | 7580 | (home-page "https://github.com/celery/py-amqp") |
8dfceab7 CAW |
7581 | (synopsis |
7582 | "Low-level AMQP client for Python (fork of amqplib)") | |
7583 | (description | |
7584 | "This is a fork of amqplib which was originally written by Barry Pederson. | |
7585 | It is maintained by the Celery project, and used by kombu as a pure python | |
7586 | alternative when librabbitmq is not available.") | |
3f641af0 | 7587 | (license license:lgpl2.1+) |
8dfceab7 CAW |
7588 | (properties `((python2-variant . ,(delay python2-amqp)))))) |
7589 | ||
7590 | (define-public python2-amqp | |
7591 | (let ((amqp (package-with-python2 | |
7592 | (strip-python2-variant python-amqp)))) | |
7593 | (package | |
7594 | (inherit amqp) | |
7595 | (arguments `(;; Tries to run coverage tests with nose-cover3, which seems | |
7596 | ;; unmaintained. Weirdly, does not do this on the python 3 | |
7597 | ;; version? | |
7598 | #:tests? #f | |
00e10c6e | 7599 | ,@(package-arguments amqp)))))) |
7d387305 | 7600 | |
220ed20b RW |
7601 | (define-public python-txamqp |
7602 | (package | |
7603 | (name "python-txamqp") | |
7604 | (version "0.8.0") | |
7605 | (source | |
7606 | (origin | |
7607 | (method url-fetch) | |
7608 | (uri (pypi-uri "txAMQP" version)) | |
7609 | (sha256 | |
7610 | (base32 | |
7611 | "1r43a66dd547mz40ikymm8y3d480cidy560fj81qc0jk4lncgmmr")))) | |
7612 | (build-system python-build-system) | |
7613 | (propagated-inputs | |
7614 | `(("python-six" ,python-six) | |
7615 | ("python-twisted" ,python-twisted))) | |
7616 | (home-page "https://github.com/txamqp/txamqp") | |
7617 | (synopsis "Communicate with AMQP peers and brokers using Twisted") | |
7618 | (description | |
7619 | "This package provides a Python library for communicating with AMQP peers | |
7620 | and brokers using the asynchronous networking framework Twisted. It contains | |
7621 | all the necessary code to connect, send and receive messages to/from an | |
7622 | AMQP-compliant peer or broker (Qpid, OpenAMQ, RabbitMQ) using Twisted. It | |
7623 | also includes support for using Thrift RPC over AMQP in Twisted | |
7624 | applications.") | |
7625 | (license license:asl2.0))) | |
7626 | ||
7627 | (define-public python2-txamqp | |
7628 | (package-with-python2 python-txamqp)) | |
7629 | ||
7d387305 CAW |
7630 | (define-public python-kombu |
7631 | (package | |
7632 | (name "python-kombu") | |
0cb59822 | 7633 | (version "3.0.37") |
7d387305 CAW |
7634 | (source |
7635 | (origin | |
7636 | (method url-fetch) | |
7637 | (uri (pypi-uri "kombu" version)) | |
7638 | (sha256 | |
7639 | (base32 | |
0cb59822 | 7640 | "0l16chb314gpq2v7fh94a22c30lcv6w3ylmhsa60bldlcq6a0r70")))) |
7d387305 CAW |
7641 | (build-system python-build-system) |
7642 | (native-inputs | |
7643 | `(("python-mock" ,python-mock) | |
7644 | ("python-nose" ,python-nose))) | |
7645 | (propagated-inputs | |
7646 | `(("python-anyjson" ,python-anyjson) | |
0cb59822 LF |
7647 | ("python-amqp" ,python-amqp) |
7648 | ("python-redis" ,python-redis))) | |
7d387305 CAW |
7649 | (home-page "http://kombu.readthedocs.org") |
7650 | (synopsis "Message passing library for Python") | |
7651 | (description "The aim of Kombu is to make messaging in Python as easy as | |
7652 | possible by providing an idiomatic high-level interface for the AMQ protocol, | |
7653 | and also provide proven and tested solutions to common messaging problems. | |
7654 | AMQP is the Advanced Message Queuing Protocol, an open standard protocol for | |
7655 | message orientation, queuing, routing, reliability and security, for which the | |
7656 | RabbitMQ messaging server is the most popular implementation.") | |
3f641af0 | 7657 | (license license:bsd-3) |
7d387305 CAW |
7658 | (properties `((python2-variant . ,(delay python2-kombu)))))) |
7659 | ||
7660 | (define-public python2-kombu | |
7661 | (let ((kombu (package-with-python2 | |
7662 | (strip-python2-variant python-kombu)))) | |
7663 | (package | |
7664 | (inherit kombu) | |
752eb9e0 MB |
7665 | (arguments `(;; FIXME: 'TestTransport.test_del_sync' fails on python2. |
7666 | ;; It works fine on the python3 variant. | |
7667 | #:tests? #f | |
7668 | ,@(package-arguments kombu))) | |
328bb95d HG |
7669 | (native-inputs `(("python2-unittest2" ,python2-unittest2) |
7670 | ,@(package-native-inputs kombu)))))) | |
b6f0b9fb CAW |
7671 | |
7672 | (define-public python-billiard | |
7673 | (package | |
7674 | (name "python-billiard") | |
a6bb9e44 | 7675 | (version "3.3.0.23") |
b6f0b9fb CAW |
7676 | (source |
7677 | (origin | |
7678 | (method url-fetch) | |
7679 | (uri (pypi-uri "billiard" version)) | |
7680 | (sha256 | |
7681 | (base32 | |
a6bb9e44 | 7682 | "02wxsc6bhqvzh8j6w758kvgqbnj14l796mvmrcms8fgfamd2lak9")))) |
b6f0b9fb CAW |
7683 | (build-system python-build-system) |
7684 | (native-inputs | |
7685 | `(("python-nose" ,python-nose))) | |
7bf837fd | 7686 | (home-page "https://github.com/celery/billiard") |
b6f0b9fb CAW |
7687 | (synopsis |
7688 | "Python multiprocessing fork with improvements and bugfixes") | |
7689 | (description | |
7690 | "Billiard is a fork of the Python 2.7 multiprocessing package. The | |
7691 | multiprocessing package itself is a renamed and updated version of R Oudkerk's | |
7692 | pyprocessing package. This standalone variant is intended to be compatible with | |
7693 | Python 2.4 and 2.5, and will draw its fixes/improvements from python-trunk.") | |
3f641af0 | 7694 | (license license:bsd-3) |
b6f0b9fb CAW |
7695 | (properties `((python2-variant . ,(delay python2-billiard)))))) |
7696 | ||
7697 | (define-public python2-billiard | |
7698 | (let ((billiard (package-with-python2 | |
7699 | (strip-python2-variant python-billiard)))) | |
7700 | (package | |
7701 | (inherit billiard) | |
00e10c6e | 7702 | (native-inputs `(("python2-unittest2" ,python2-unittest2) |
b6f0b9fb CAW |
7703 | ("python2-mock" ,python2-mock) |
7704 | ,@(package-native-inputs billiard)))))) | |
22df6419 CAW |
7705 | |
7706 | (define-public python-celery | |
7707 | (package | |
7708 | (name "python-celery") | |
9ebe87fe | 7709 | (version "3.1.24") |
22df6419 CAW |
7710 | (source |
7711 | (origin | |
7712 | (method url-fetch) | |
7713 | (uri (pypi-uri "celery" version)) | |
7714 | (sha256 | |
7715 | (base32 | |
9ebe87fe | 7716 | "0yh2prhdnx2dgkb67a5drj12hh2zvzx5f611p7mqqg01ydghif4r")))) |
22df6419 | 7717 | (build-system python-build-system) |
9ebe87fe LF |
7718 | (arguments |
7719 | `(#:phases | |
7720 | (modify-phases %standard-phases | |
7721 | ;; These tests break with Python 3.5: | |
7722 | ;; https://github.com/celery/celery/issues/2897#issuecomment-253066295 | |
7723 | (replace 'check | |
7724 | (lambda _ | |
7725 | (zero? | |
7726 | (system* "nosetests" "--exclude=^test_safe_to_remove.*"))))))) | |
22df6419 CAW |
7727 | (native-inputs |
7728 | `(("python-nose" ,python-nose))) | |
f22efa01 | 7729 | (propagated-inputs |
22df6419 CAW |
7730 | `(("python-pytz" ,python-pytz) |
7731 | ("python-billiard" ,python-billiard) | |
7732 | ("python-kombu" ,python-kombu))) | |
7733 | (home-page "http://celeryproject.org") | |
7734 | (synopsis "Distributed Task Queue") | |
7735 | (description "Celery is an asynchronous task queue/job queue based on | |
7736 | distributed message passing. It is focused on real-time operation, but | |
7737 | supports scheduling as well. The execution units, called tasks, are executed | |
7738 | concurrently on a single or more worker servers using multiprocessing, | |
7739 | Eventlet, or gevent. Tasks can execute asynchronously (in the background) or | |
7740 | synchronously (wait until ready).") | |
3f641af0 | 7741 | (license license:bsd-3) |
22df6419 CAW |
7742 | (properties `((python2-variant . ,(delay python2-celery)))))) |
7743 | ||
7744 | (define-public python2-celery | |
7745 | (let ((celery (package-with-python2 | |
7746 | (strip-python2-variant python-celery)))) | |
7747 | (package | |
7748 | (inherit celery) | |
00e10c6e | 7749 | (native-inputs `(("python2-unittest2" ,python2-unittest2) |
22df6419 CAW |
7750 | ("python2-mock" ,python2-mock) |
7751 | ,@(package-native-inputs celery)))))) | |
97e32948 CAW |
7752 | |
7753 | (define-public python-translitcodec | |
7754 | (package | |
7755 | (name "python-translitcodec") | |
7756 | (version "0.4.0") | |
7757 | (source | |
7758 | (origin | |
7759 | (method url-fetch) | |
7760 | (uri (pypi-uri "translitcodec" version)) | |
7761 | (sha256 | |
7762 | (base32 | |
7763 | "10x6pvblkzky1zhjs8nmx64nb9jdzxad4bxhq4iwv0j4z2aqjnki")))) | |
7764 | (build-system python-build-system) | |
7765 | (arguments | |
7766 | `(#:tests? #f)) ; no tests provided | |
7767 | (home-page | |
7768 | "https://github.com/claudep/translitcodec") | |
7769 | (synopsis | |
7770 | "Unicode to 8-bit charset transliteration codec") | |
7771 | (description | |
7772 | "This package contains codecs for transliterating ISO 10646 texts into | |
7773 | best-effort representations using smaller coded character sets (ASCII, | |
7774 | ISO 8859, etc.).") | |
f210e944 | 7775 | (license license:expat))) |
97e32948 CAW |
7776 | |
7777 | (define-public python2-translitcodec | |
f210e944 | 7778 | (package-with-python2 python-translitcodec)) |
0c3b90d4 CAW |
7779 | |
7780 | (define-public python-editor | |
7781 | (package | |
7782 | (name "python-editor") | |
7783 | (version "0.5") | |
7784 | (source | |
7785 | (origin | |
7786 | (method url-fetch) | |
7787 | (uri (pypi-uri "python-editor" version)) | |
7788 | (sha256 | |
7789 | (base32 | |
7790 | "1ypnpgvzpkbwsg4rdvy4sy51j28b5xq9v8pnkwxncn07vqz06p7n")))) | |
7791 | (build-system python-build-system) | |
7792 | (home-page | |
7793 | "https://github.com/fmoo/python-editor") | |
7794 | (synopsis | |
7795 | "Programmatically open an editor, capture the result") | |
7796 | (description | |
7797 | "python-editor is a library that provides the editor module for | |
7798 | programmatically interfacing with your system's $EDITOR.") | |
f210e944 | 7799 | (license license:asl2.0))) |
0c3b90d4 CAW |
7800 | |
7801 | (define-public python2-editor | |
f210e944 | 7802 | (package-with-python2 python-editor)) |
3276517c LF |
7803 | |
7804 | (define-public python-sphinxcontrib-programoutput | |
7805 | (package | |
7806 | (name "python-sphinxcontrib-programoutput") | |
b9ce9eca | 7807 | (version "0.10") |
3276517c LF |
7808 | (source (origin |
7809 | (method url-fetch) | |
7810 | (uri (pypi-uri "sphinxcontrib-programoutput" version)) | |
7811 | (sha256 | |
7812 | (base32 | |
b9ce9eca | 7813 | "153hhnlbx4688zj9wd64819ps5znc2jlyp5crkgzvn5hxgy99vpx")))) |
3276517c | 7814 | (build-system python-build-system) |
e2cb140e MB |
7815 | (arguments |
7816 | ;; FIXME: Many tests are failing and the upstream is gone. | |
7817 | '(#:tests? #f)) | |
3276517c | 7818 | (propagated-inputs |
a0a09859 | 7819 | `(("python-sphinx" ,python-sphinx))) |
3276517c LF |
7820 | (synopsis "Sphinx extension to include program output") |
7821 | (description "A Sphinx extension to literally insert the output of arbitrary | |
7822 | commands into documents, helping you to keep your command examples up to date.") | |
7823 | (home-page "https://github.com/lunaryorn/sphinxcontrib-programoutput") | |
f210e944 | 7824 | (license license:bsd-2))) |
3276517c LF |
7825 | |
7826 | (define-public python2-sphinxcontrib-programoutput | |
f210e944 | 7827 | (package-with-python2 python-sphinxcontrib-programoutput)) |
548d7165 LF |
7828 | |
7829 | (define-public python-sphinx-repoze-autointerface | |
7830 | (package | |
7831 | (name "python-sphinx-repoze-autointerface") | |
328ae341 | 7832 | (version "0.8") |
548d7165 LF |
7833 | (source (origin |
7834 | (method url-fetch) | |
7835 | (uri (pypi-uri "repoze.sphinx.autointerface" version)) | |
7836 | (sha256 | |
7837 | (base32 | |
328ae341 | 7838 | "08ycivzf7bh4a1zcyp31hbyqs1b2c9r26raa3vxjwwmbfqr3iw4f")))) |
548d7165 | 7839 | (build-system python-build-system) |
5b3c3d4b | 7840 | (arguments '(#:tests? #f)) ; No tests. |
548d7165 | 7841 | (propagated-inputs |
47c7dc4a | 7842 | `(("python-sphinx" ,python-sphinx) |
548d7165 LF |
7843 | ("python-zope-interface" ,python-zope-interface))) |
7844 | (synopsis "Auto-generate Sphinx API docs from Zope interfaces") | |
7845 | (description "This package defines an extension for the Sphinx documentation | |
7846 | system. The extension allows generation of API documentation by | |
7847 | introspection of @code{zope.interface} instances in code.") | |
7848 | (home-page "https://github.com/repoze/repoze.sphinx.autointerface") | |
3f641af0 | 7849 | (license license:repoze))) |
548d7165 LF |
7850 | |
7851 | (define-public python2-sphinx-repoze-autointerface | |
7852 | (package-with-python2 python-sphinx-repoze-autointerface)) | |
b31fbea5 | 7853 | |
1b2f753d | 7854 | (define-public python-vobject |
603d665b | 7855 | (package |
1b2f753d LC |
7856 | (name "python-vobject") |
7857 | (version "0.9.5") | |
603d665b LF |
7858 | (source (origin |
7859 | (method url-fetch) | |
1b2f753d | 7860 | (uri (pypi-uri "vobject" version)) |
603d665b LF |
7861 | (sha256 |
7862 | (base32 | |
1b2f753d | 7863 | "0hqjgf3ay1m5w1c0k00g5yfpdz1zni5qnr5rh9b8fg9hjvhwlmhg")))) |
603d665b LF |
7864 | (build-system python-build-system) |
7865 | (arguments | |
1b2f753d | 7866 | '(;; The test suite relies on some non-portable Windows interfaces. |
603d665b | 7867 | #:tests? #f)) |
1b2f753d LC |
7868 | (propagated-inputs |
7869 | `(("python-dateutil" ,python-dateutil) | |
7870 | ("python-pyicu" ,python-pyicu))) | |
7871 | (synopsis "Parse and generate vCard and vCalendar files") | |
7872 | (description "Vobject is intended to be a full featured Python package for | |
7873 | parsing and generating vCard and vCalendar files. Currently, iCalendar files | |
7874 | are supported and well tested. vCard 3.0 files are supported, and all data | |
7875 | should be imported, but only a few components are understood in a sophisticated | |
7876 | way.") | |
7877 | (home-page "http://eventable.github.io/vobject/") | |
7878 | (license license:asl2.0))) | |
603d665b | 7879 | |
1b2f753d LC |
7880 | (define-public python2-vobject |
7881 | (package-with-python2 python-vobject)) | |
0efde7d6 | 7882 | |
1b2f753d | 7883 | (define-public python-munkres |
0efde7d6 | 7884 | (package |
1b2f753d LC |
7885 | (name "python-munkres") |
7886 | (version "1.0.8") | |
0efde7d6 LF |
7887 | (source (origin |
7888 | (method url-fetch) | |
1b2f753d | 7889 | (uri (pypi-uri "munkres" version)) |
0efde7d6 LF |
7890 | (sha256 |
7891 | (base32 | |
1b2f753d | 7892 | "0mbspx4zv8id4x6pim6ybsa1xh96qwpbqj7skbqz4c9c9nf1lpqq")))) |
0efde7d6 LF |
7893 | (build-system python-build-system) |
7894 | (arguments | |
1b2f753d LC |
7895 | '(#:tests? #f)) ; no test suite |
7896 | (home-page "http://software.clapper.org/munkres/") | |
7897 | (synopsis "Implementation of the Munkres algorithm") | |
7898 | (description "The Munkres module provides an implementation of the Munkres | |
7899 | algorithm (also called the Hungarian algorithm or the Kuhn-Munkres algorithm), | |
7900 | useful for solving the Assignment Problem.") | |
7901 | (license license:bsd-3))) | |
0efde7d6 | 7902 | |
1b2f753d LC |
7903 | (define-public python2-munkres |
7904 | (package-with-python2 python-munkres)) | |
76b94885 | 7905 | |
b7afd018 RW |
7906 | (define-public python-whoosh |
7907 | (package | |
7908 | (name "python-whoosh") | |
7909 | (version "2.7.4") | |
7910 | (source | |
7911 | (origin | |
7912 | (method url-fetch) | |
7913 | (uri (pypi-uri "Whoosh" version)) | |
7914 | (sha256 | |
7915 | (base32 | |
7916 | "10qsqdjpbc85fykc1vgcs8xwbgn4l2l52c8d83xf1q59pwyn79bw")))) | |
7917 | (build-system python-build-system) | |
7918 | (native-inputs | |
f3b98f4f | 7919 | `(("python-pytest" ,python-pytest))) |
9be5ecdf | 7920 | (home-page "https://bitbucket.org/mchaput/whoosh") |
b7afd018 RW |
7921 | (synopsis "Full text indexing, search, and spell checking library") |
7922 | (description | |
7923 | "Whoosh is a fast, pure-Python full text indexing, search, and spell | |
7924 | checking library.") | |
7925 | (license license:bsd-2))) | |
7926 | ||
7927 | (define-public python2-whoosh | |
7928 | (let ((whoosh (package-with-python2 (strip-python2-variant python-whoosh)))) | |
7929 | (package (inherit whoosh) | |
7930 | (propagated-inputs | |
7931 | `(("python2-backport-ssl-match-hostname" | |
7932 | ,python2-backport-ssl-match-hostname) | |
7933 | ,@(package-propagated-inputs whoosh)))))) | |
7934 | ||
76b94885 LF |
7935 | (define-public python-pathlib |
7936 | (package | |
7937 | (name "python-pathlib") | |
7938 | (version "1.0.1") | |
7939 | (source (origin | |
7940 | (method url-fetch) | |
7941 | (uri (pypi-uri "pathlib" version)) | |
7942 | (sha256 | |
7943 | (base32 | |
7944 | "17zajiw4mjbkkv6ahp3xf025qglkj0805m9s41c45zryzj6p2h39")))) | |
7945 | (build-system python-build-system) | |
92a312dc RW |
7946 | ;; The tests depend on the internal "test" module, which does not provide |
7947 | ;; a stable interface. | |
7948 | (arguments `(#:tests? #f)) | |
76b94885 | 7949 | (home-page "https://pathlib.readthedocs.org/") |
8f65585b JD |
7950 | (synopsis "Object-oriented file system paths") |
7951 | (description "Pathlib offers a set of classes to handle file system paths. | |
76b94885 LF |
7952 | It offers the following advantages over using string objects: |
7953 | ||
7954 | @enumerate | |
7955 | @item No more cumbersome use of os and os.path functions. Everything can | |
7956 | be done easily through operators, attribute accesses, and method calls. | |
7957 | @item Embodies the semantics of different path types. For example, | |
7958 | comparing Windows paths ignores casing. | |
7959 | @item Well-defined semantics, eliminating any inconsistencies or | |
7960 | ambiguities (forward vs. backward slashes, etc.). | |
7a8894e8 HG |
7961 | @end enumerate |
7962 | ||
7963 | Note: In Python 3.4, pathlib is now part of the standard library. For other | |
7964 | Python versions please consider python-pathlib2 instead, which tracks the | |
7965 | standard library module. This module (python-pathlib) isn't maintained | |
7966 | anymore.") | |
76b94885 LF |
7967 | (license license:expat))) |
7968 | ||
7969 | (define-public python2-pathlib | |
7970 | (package-with-python2 python-pathlib)) | |
25a7db0a | 7971 | |
b7703c81 HG |
7972 | (define-public python2-pathlib2 |
7973 | (package | |
7974 | (name "python2-pathlib2") | |
7975 | (version "2.1.0") | |
7976 | (source (origin | |
7977 | (method url-fetch) | |
7978 | (uri (pypi-uri "pathlib2" version)) | |
7979 | (sha256 | |
7980 | (base32 | |
7981 | "0p050msg5c8d0kadv702jnfshaxrb0il765cpkgnhn6mq5hakcyy")))) | |
7982 | (build-system python-build-system) | |
49a531f5 HG |
7983 | ;; We only need the the Python 2 variant, since for Python 3 our minimum |
7984 | ;; version is 3.4 which already includes this package as part of the | |
7985 | ;; standard library. | |
b7703c81 HG |
7986 | (arguments |
7987 | `(#:python ,python-2)) | |
7988 | (native-inputs | |
f3b98f4f | 7989 | `(("python2-six" ,python2-six))) |
9be5ecdf | 7990 | (home-page "https://pypi.python.org/pypi/pathlib2/") |
b7703c81 HG |
7991 | (synopsis "Object-oriented file system paths - backport of standard |
7992 | pathlib module") | |
7993 | (description "The goal of pathlib2 is to provide a backport of standard | |
7994 | pathlib module which tracks the standard library module, so all the newest | |
7995 | features of the standard pathlib can be used also on older Python versions. | |
7996 | ||
7997 | Pathlib offers a set of classes to handle file system paths. It offers the | |
7998 | following advantages over using string objects: | |
7999 | ||
8000 | @enumerate | |
8001 | @item No more cumbersome use of os and os.path functions. Everything can | |
8002 | be done easily through operators, attribute accesses, and method calls. | |
8003 | @item Embodies the semantics of different path types. For example, | |
8004 | comparing Windows paths ignores casing. | |
8005 | @item Well-defined semantics, eliminating any inconsistencies or | |
8006 | ambiguities (forward vs. backward slashes, etc.). | |
8007 | @end enumerate") | |
8008 | (license license:expat))) | |
8009 | ||
25a7db0a LF |
8010 | (define-public python-jellyfish |
8011 | (package | |
8012 | (name "python-jellyfish") | |
8c4964dd | 8013 | (version "0.5.6") |
25a7db0a LF |
8014 | (source (origin |
8015 | (method url-fetch) | |
8016 | (uri (pypi-uri "jellyfish" version)) | |
8017 | (sha256 | |
8018 | (base32 | |
8c4964dd | 8019 | "1j9rplb16ba2prjj6mip46z0w9pnhnqpwgiwi0x93vnas14rlyl8")))) |
25a7db0a LF |
8020 | (build-system python-build-system) |
8021 | (native-inputs | |
8022 | `(("python-pytest" ,python-pytest))) | |
8023 | (home-page "https://github.com/jamesturk/jellyfish") | |
8024 | (synopsis "Approximate and phonetic matching of strings") | |
8025 | (description "Jellyfish uses a variety of string comparison and phonetic | |
8026 | encoding algorithms to do fuzzy string matching.") | |
3f641af0 | 8027 | (license license:bsd-2) |
25a7db0a LF |
8028 | (properties `((python2-variant . ,(delay python2-jellyfish)))))) |
8029 | ||
8030 | (define-public python2-jellyfish | |
8031 | (let ((jellyfish (package-with-python2 | |
8032 | (strip-python2-variant python-jellyfish)))) | |
8033 | (package (inherit jellyfish) | |
00e10c6e | 8034 | (native-inputs `(("python2-unicodecsv" ,python2-unicodecsv) |
25a7db0a | 8035 | ,@(package-native-inputs jellyfish)))))) |
13edb0e5 LF |
8036 | |
8037 | (define-public python2-unicodecsv | |
8038 | (package | |
8039 | (name "python2-unicodecsv") | |
8040 | (version "0.14.1") | |
8041 | (source (origin | |
8042 | (method url-fetch) | |
8043 | ;; The test suite is not included in the PyPi release. | |
8044 | ;; https://github.com/jdunck/python-unicodecsv/issues/19 | |
8045 | (uri (string-append "https://github.com/jdunck/python-unicodecsv/" | |
8046 | "archive/" version ".tar.gz")) | |
8047 | (file-name (string-append name "-" version ".tar.gz")) | |
8048 | (sha256 | |
8049 | (base32 | |
8050 | "087nqanfcyp6mlfbbr5lva5f3w6iz1bybls9xlrb8icmc474wh4w")))) | |
8051 | (build-system python-build-system) | |
8052 | (arguments | |
8053 | `(;; It supports Python 3, but Python 3 can already do Unicode CSV. | |
8054 | #:python ,python-2)) | |
8055 | (native-inputs | |
f3b98f4f | 8056 | `(("python2-unittest2" ,python2-unittest2))) |
13edb0e5 LF |
8057 | (home-page "https://github.com/jdunck/python-unicodecsv") |
8058 | (synopsis "Unicode CSV module for Python 2") | |
8059 | (description "Unicodecsv is a drop-in replacement for Python 2.7's CSV | |
8060 | module, adding support for Unicode strings.") | |
3f641af0 | 8061 | (license license:bsd-2))) |
064503aa LF |
8062 | |
8063 | (define-public python-rarfile | |
8064 | (package | |
8065 | (name "python-rarfile") | |
67824447 | 8066 | (version "2.8") |
064503aa LF |
8067 | (source (origin |
8068 | (method url-fetch) | |
8069 | (uri (pypi-uri "rarfile" version)) | |
8070 | (sha256 | |
8071 | (base32 | |
67824447 | 8072 | "0qfad483kcbga0bn4qmcz953xjk16r52fahiy46zzn56v80y89ra")))) |
064503aa LF |
8073 | (build-system python-build-system) |
8074 | (arguments | |
8075 | '(#:phases | |
8076 | (modify-phases %standard-phases | |
8077 | (replace 'check | |
8078 | ;; Many tests fail, but the installation proceeds. | |
8079 | (lambda _ (zero? (system* "make" "-C" "test" "test"))))))) | |
8080 | (native-inputs | |
8081 | `(("which" ,which))) ; required for tests | |
8082 | (propagated-inputs | |
8083 | `(("libarchive" ,libarchive))) | |
8084 | (home-page "https://github.com/markokr/rarfile") | |
8085 | (synopsis "RAR archive reader for Python") | |
8086 | (description "This is Python module for RAR archive reading. The interface | |
8087 | is made as zipfile like as possible.") | |
3f641af0 | 8088 | (license license:isc))) |
064503aa LF |
8089 | |
8090 | (define-public python2-rarfile | |
8091 | (package-with-python2 python-rarfile)) | |
daeeea71 CM |
8092 | |
8093 | (define-public python-magic | |
8094 | (package | |
8095 | (name "python-magic") | |
8096 | (version "0.4.3") | |
8097 | (source | |
8098 | (origin | |
8099 | (method url-fetch) | |
8100 | (uri (string-append "https://github.com/ahupp/python-magic/archive/" | |
8101 | version ".tar.gz")) | |
8102 | (sha256 | |
8103 | (base32 | |
8104 | "17bgy92i7sb021f2s4mw1dcvpm6p1mi9jihridwy1pyn8mzvpjgk")) | |
8105 | (file-name (string-append name "-" version "-checkout")))) | |
8106 | (build-system python-build-system) | |
8107 | (arguments | |
8108 | ;; The tests are unreliable, so don't run them. The tests fail | |
8109 | ;; under Python3 because they were written for Python2 and | |
8110 | ;; contain import statements that do not work in Python3. One of | |
8111 | ;; the tests fails under Python2 because its assertions are | |
8112 | ;; overly stringent; it relies on comparing output strings which | |
8113 | ;; are brittle and can change depending on the version of | |
8114 | ;; libmagic being used and the system on which the test is | |
8115 | ;; running. In my case, under GuixSD 0.10.0, only one test | |
8116 | ;; failed, and it seems to have failed only because the version | |
8117 | ;; of libmagic that is packaged in Guix outputs a slightly | |
8118 | ;; different (but not wrong) string than the one that the test | |
8119 | ;; expected. | |
8120 | '(#:tests? #f | |
8121 | #:phases (modify-phases %standard-phases | |
8122 | ;; Replace a specific method call with a hard-coded | |
8123 | ;; path to the necessary libmagic.so file in the | |
8124 | ;; store. If we don't do this, then the method call | |
8125 | ;; will fail to find the libmagic.so file, which in | |
8126 | ;; turn will cause any application using | |
8127 | ;; python-magic to fail. | |
8128 | (add-before 'build 'hard-code-path-to-libmagic | |
8129 | (lambda* (#:key inputs #:allow-other-keys) | |
8130 | (let ((file (assoc-ref inputs "file"))) | |
8131 | (substitute* "magic.py" | |
8132 | (("ctypes.util.find_library\\('magic'\\)") | |
8133 | (string-append "'" file "/lib/libmagic.so'"))) | |
77432686 LF |
8134 | #t))) |
8135 | (add-before 'install 'disable-egg-compression | |
8136 | (lambda _ | |
8137 | (let ((port (open-file "setup.cfg" "a"))) | |
8138 | (display "\n[easy_install]\nzip_ok = 0\n" | |
8139 | port) | |
8140 | (close-port port) | |
8141 | #t)))))) | |
daeeea71 CM |
8142 | (inputs |
8143 | ;; python-magic needs to be able to find libmagic.so. | |
8144 | `(("file" ,file))) | |
8145 | (home-page "https://github.com/ahupp/python-magic") | |
8146 | (synopsis "File type identification using libmagic") | |
8147 | (description | |
8148 | "This module uses ctypes to access the libmagic file type | |
8149 | identification library. It makes use of the local magic database and | |
8150 | supports both textual and MIME-type output. Note that this module and | |
8151 | the python-file module both provide a \"magic.py\" file; these two | |
8152 | modules, which are different and were developed separately, both serve | |
8153 | the same purpose: to provide Python bindings for libmagic.") | |
8154 | (license license:expat))) | |
8155 | ||
8156 | (define-public python2-magic | |
8157 | (package-with-python2 python-magic)) | |
12af303f CM |
8158 | |
8159 | (define-public python2-s3cmd | |
8160 | (package | |
8161 | (name "python2-s3cmd") | |
8162 | (version "1.6.1") | |
8163 | (source | |
8164 | (origin | |
8165 | (method url-fetch) | |
de67e922 | 8166 | (uri (string-append "mirror://sourceforge/s3tools/s3cmd/" version "/" |
12af303f CM |
8167 | "s3cmd-" version ".tar.gz")) |
8168 | (sha256 | |
8169 | (base32 | |
8170 | "0ki1rzhm5icvi9ry5jswi4b22yqwyj0d2wsqsgilwx6qhi7pjxa6")))) | |
8171 | (build-system python-build-system) | |
8172 | (arguments | |
8173 | ;; s3cmd is written for python2 only and contains no tests. | |
8174 | `(#:python ,python-2 | |
8175 | #:tests? #f)) | |
f22efa01 | 8176 | (propagated-inputs |
12af303f CM |
8177 | `(("python2-dateutil" ,python2-dateutil) |
8178 | ;; The python-file package also provides a magic.py module. | |
8179 | ;; This is an unfortunate state of affairs; however, s3cmd | |
8180 | ;; fails to install if it cannot find specifically the | |
8181 | ;; python-magic package. Thus we include it, instead of using | |
8182 | ;; python-file. Ironically, s3cmd sometimes works better | |
8183 | ;; without libmagic bindings at all: | |
8184 | ;; https://github.com/s3tools/s3cmd/issues/198 | |
8185 | ("python2-magic" ,python2-magic))) | |
8186 | (home-page "http://s3tools.org/s3cmd") | |
8187 | (synopsis "Command line tool for S3-compatible storage services") | |
8188 | (description | |
8189 | "S3cmd is a command line tool for uploading, retrieving and managing data | |
8190 | in storage services that are compatible with the Amazon Simple Storage | |
8191 | Service (S3) protocol, including S3 itself. It supports rsync-like backup, | |
8192 | GnuPG encryption, and more. It also supports management of Amazon's | |
8193 | CloudFront content delivery network.") | |
3f641af0 | 8194 | (license license:gpl2+))) |
4323a5f0 AE |
8195 | |
8196 | (define-public python-pkgconfig | |
8197 | (package | |
8198 | (name "python-pkgconfig") | |
8199 | (version "1.1.0") | |
8200 | (source | |
8201 | (origin | |
8202 | (method url-fetch) | |
8203 | (uri (pypi-uri "pkgconfig" version)) | |
8204 | (sha256 | |
8205 | (base32 | |
8206 | "1pw0kmvc57sjmaxi6c54fqsnihqj6hvhc9y1vaz36axafzqam7bh")))) | |
8207 | (build-system python-build-system) | |
8208 | (native-inputs | |
f3b98f4f | 8209 | `(("python-nose" ,python-nose))) |
4323a5f0 AE |
8210 | (inputs |
8211 | `(("pkg-config" ,pkg-config))) | |
8212 | (arguments | |
8213 | `(;; Tests fail with "ValueError: _type_ 'v' not supported" on Python 3, | |
8214 | ;; and on Python 2 they need the dl module deprecated since Python 2.6. | |
8215 | #:tests? #f | |
4323a5f0 AE |
8216 | ;; Hard-code the path to pkg-config. |
8217 | #:phases | |
8218 | (modify-phases %standard-phases | |
8219 | (add-before | |
8220 | 'build 'patch | |
8221 | (lambda _ | |
8222 | (substitute* "pkgconfig/pkgconfig.py" | |
8223 | (("cmd = 'pkg-config") | |
8224 | (string-append "cmd = '" (which "pkg-config")))) | |
8225 | #t))))) | |
7bf837fd | 8226 | (home-page "https://github.com/matze/pkgconfig") |
4323a5f0 AE |
8227 | (synopsis "Python interface for pkg-config") |
8228 | (description "This module provides a Python interface to pkg-config. It | |
8229 | can be used to find all pkg-config packages, check if a package exists, | |
8230 | check if a package meets certain version requirements, query CFLAGS and | |
8231 | LDFLAGS and parse the output to build extensions with setup.py.") | |
a0c6a36b | 8232 | (license license:expat))) |
4323a5f0 AE |
8233 | |
8234 | (define-public python2-pkgconfig | |
8235 | (package-with-python2 python-pkgconfig)) | |
8236 | ||
2e697322 BW |
8237 | (define-public python-bz2file |
8238 | (package | |
8239 | (name "python-bz2file") | |
8240 | (version "0.98") | |
8241 | (source | |
8242 | (origin | |
8243 | (method url-fetch) | |
8244 | (uri (pypi-uri "bz2file" version)) | |
8245 | (sha256 | |
8246 | (base32 | |
8247 | "126s53fkpx04f33a829yqqk8fj4png3qwg4m66cvlmhmwc8zihb4")))) | |
8248 | (build-system python-build-system) | |
8249 | (arguments | |
124df723 | 8250 | `(#:tests? #f)) ; Tests use deprecated python modules. |
2e697322 BW |
8251 | (home-page "https://github.com/nvawda/bz2file") |
8252 | (synopsis "Read and write bzip2-compressed files") | |
8253 | (description | |
8254 | "Bz2file is a Python library for reading and writing bzip2-compressed | |
8255 | files. It contains a drop-in replacement for the I/O interface in the | |
8256 | standard library's @code{bz2} module, including features from the latest | |
8257 | development version of CPython that are not available in older releases.") | |
3f641af0 | 8258 | (license license:asl2.0) |
2e697322 BW |
8259 | (properties `((python2-variant . ,(delay python2-bz2file)))))) |
8260 | ||
8261 | (define-public python2-bz2file | |
8262 | (let ((base (package-with-python2 | |
8263 | (strip-python2-variant python-bz2file)))) | |
8264 | (package | |
8265 | (inherit base) | |
124df723 | 8266 | (arguments |
752bb447 BW |
8267 | `(#:python ,python-2 |
8268 | #:phases | |
124df723 BW |
8269 | (modify-phases %standard-phases |
8270 | ;; 'python setup.py test' does not work as of 0.98. | |
8271 | ;; There is only the one test file, so we run it directly. | |
8272 | (replace 'check | |
8273 | (lambda _ (zero? (system* "python" | |
8274 | "test_bz2file.py")))))))))) | |
2e697322 | 8275 | |
da4ac1aa BW |
8276 | (define-public python-future |
8277 | (package | |
8278 | (name "python-future") | |
c522f57e | 8279 | (version "0.16.0") |
da4ac1aa BW |
8280 | (source |
8281 | (origin | |
8282 | (method url-fetch) | |
8283 | (uri (pypi-uri "future" version)) | |
8284 | (sha256 | |
8285 | (base32 | |
c522f57e | 8286 | "1nzy1k4m9966sikp0qka7lirh8sqrsyainyf8rk97db7nwdfv773")))) |
da4ac1aa BW |
8287 | (build-system python-build-system) |
8288 | ;; Many tests connect to the network or are otherwise flawed. | |
8289 | ;; https://github.com/PythonCharmers/python-future/issues/210 | |
8290 | (arguments | |
8291 | `(#:tests? #f)) | |
8292 | (home-page "http://python-future.org") | |
8293 | (synopsis "Single-source support for Python 3 and 2") | |
8294 | (description | |
8295 | "@code{python-future} is the missing compatibility layer between Python 2 and | |
8296 | Python 3. It allows you to use a single, clean Python 3.x-compatible codebase | |
8297 | to support both Python 2 and Python 3 with minimal overhead.") | |
f210e944 | 8298 | (license license:expat))) |
da4ac1aa BW |
8299 | |
8300 | (define-public python2-future | |
f210e944 | 8301 | (package-with-python2 python-future)) |
da4ac1aa | 8302 | |
8e451885 AE |
8303 | (define-public python-cysignals |
8304 | (package | |
8305 | (name "python-cysignals") | |
8306 | (version "1.1.0") | |
8307 | (source | |
8308 | (origin | |
8309 | (method url-fetch) | |
8310 | (uri (pypi-uri "cysignals" version ".tar.bz2")) | |
8311 | (sha256 | |
8312 | (base32 | |
8313 | "14cbyd9znlz6cxy1s3g6v6dv5jj45hn27pywkidd9b1zanaysqc6")))) | |
8314 | (build-system python-build-system) | |
8315 | (native-inputs | |
8316 | `(("python-cython" ,python-cython) | |
8e451885 AE |
8317 | ("python-sphinx" ,python-sphinx))) |
8318 | (inputs | |
8319 | `(("pari-gp" ,pari-gp))) | |
8320 | (arguments | |
8321 | `(#:modules ((guix build python-build-system) | |
8322 | ((guix build gnu-build-system) #:prefix gnu:) | |
8323 | (guix build utils)) | |
8324 | ;; FIXME: Tests are executed after installation and currently fail | |
8325 | ;; when not installing into standard locations; the author is working | |
8326 | ;; on a fix. | |
8327 | #:tests? #f | |
8328 | #:phases | |
8329 | (modify-phases %standard-phases | |
8330 | (add-before | |
8331 | 'build 'configure | |
8332 | (assoc-ref gnu:%standard-phases 'configure))))) | |
8333 | (home-page | |
8334 | "https://github.com/sagemath/cysignals") | |
8335 | (synopsis | |
8336 | "Handling of interrupts and signals for Cython") | |
8337 | (description | |
8338 | "The cysignals package provides mechanisms to handle interrupts (and | |
8339 | other signals and errors) in Cython code, using two related approaches, | |
8340 | for mixed Cython/Python code or external C libraries and pure Cython code, | |
8341 | respectively.") | |
3f641af0 | 8342 | (license license:lgpl3+))) |
8e451885 AE |
8343 | |
8344 | (define-public python2-cysignals | |
8345 | (package-with-python2 python-cysignals)) | |
8346 | ||
63bcec71 DM |
8347 | (define-public python2-shedskin |
8348 | (package | |
8349 | (name "python2-shedskin") | |
8350 | (version "0.9.4") | |
8351 | (source | |
8352 | (origin | |
8353 | (method url-fetch) | |
8354 | (uri (string-append "https://github.com/shedskin/shedskin/" | |
8355 | "releases/download/v" version | |
8356 | "/shedskin-" version ".tgz")) | |
8357 | (sha256 | |
8358 | (base32 | |
8359 | "0nzwrzgw1ga8rw6f0ryq7zr9kkiavd1cqz5hzxkcbicl1dk7kz41")))) | |
8360 | (build-system python-build-system) | |
8361 | (arguments | |
8362 | `(#:python ,python-2 | |
8363 | #:phases (modify-phases %standard-phases | |
8364 | (add-after 'unpack 'fix-resulting-include-libs | |
8365 | (lambda* (#:key inputs #:allow-other-keys) | |
8366 | (let ((libgc (assoc-ref inputs "libgc")) | |
8367 | (pcre (assoc-ref inputs "pcre"))) | |
8368 | (substitute* "shedskin/makefile.py" | |
8369 | (("variable == 'CCFLAGS':[ ]*") | |
8370 | (string-append "variable == 'CCFLAGS':\n" | |
8371 | " line += ' -I " pcre "/include" | |
8372 | " -I " libgc "/include'")) | |
8373 | (("variable == 'LFLAGS':[ ]*") | |
8374 | (string-append "variable == 'LFLAGS':\n" | |
8375 | " line += ' -L" pcre "/lib" | |
8376 | " -L " libgc "/lib'"))) | |
8377 | #t)))))) | |
63bcec71 DM |
8378 | (inputs `(("pcre" ,pcre) |
8379 | ("libgc" ,libgc))) | |
8380 | (home-page "https://shedskin.github.io/") | |
8381 | (synopsis "Experimental Python-2 to C++ Compiler") | |
8382 | (description (string-append "This is an experimental compiler for a subset of | |
8383 | Python. It generates C++ code and a Makefile.")) | |
3f641af0 | 8384 | (license (list license:gpl3 license:bsd-3 license:expat)))) |
88bb4197 LG |
8385 | |
8386 | (define-public python2-rope | |
8387 | (package | |
8388 | (name "python2-rope") | |
8389 | (version "0.10.3") | |
8390 | (source | |
8391 | (origin | |
8392 | (method url-fetch) | |
8393 | (uri (pypi-uri "rope" version)) | |
8394 | (sha256 | |
8395 | (base32 | |
8396 | "18k5znhpwvrfck3yp0jmhd5j8r0f0s8bk1zh5yhs2cfgmfhbwigb")))) | |
8397 | (arguments | |
8398 | ;; Rope is currently python-2 only. | |
8399 | ;; https://github.com/python-rope/rope/issues/57 | |
8400 | `(#:python ,python-2)) | |
8401 | (build-system python-build-system) | |
8402 | (native-inputs | |
f3b98f4f | 8403 | `(("python2-unittest2" ,python2-unittest2))) |
88bb4197 LG |
8404 | (home-page "https://github.com/python-rope/rope") |
8405 | (synopsis "Refactoring library for Python") | |
8406 | (description "Rope is a refactoring library for Python. It facilitates | |
8407 | the renaming, moving and extracting of attributes, functions, modules, fields | |
8408 | and parameters in Python 2 source code. These refactorings can also be applied | |
d1e4ad1b | 8409 | to occurrences in strings and comments.") |
3f641af0 | 8410 | (license license:gpl2))) |
6ba8ca17 TČ |
8411 | |
8412 | (define-public python-py3status | |
8413 | (package | |
8414 | (name "python-py3status") | |
d2262d70 | 8415 | (version "3.1") |
6ba8ca17 TČ |
8416 | (source |
8417 | (origin | |
8418 | (method url-fetch) | |
8419 | (uri (pypi-uri "py3status" version)) | |
8420 | (sha256 | |
8421 | (base32 | |
d2262d70 | 8422 | "0i283z1pivmir61z8kbiycigc94l61v33ygzkhczf1ifq7cppyds")))) |
6ba8ca17 | 8423 | (build-system python-build-system) |
3eabcc78 TČ |
8424 | (inputs |
8425 | `(("file" ,file))) | |
8653c1d5 | 8426 | (arguments |
3eabcc78 TČ |
8427 | '(#:phases |
8428 | (modify-phases %standard-phases | |
8429 | ;; 'file' is used for detection of configuration file encoding | |
8430 | ;; let's make link the dependency to particular input | |
8431 | (add-before 'build 'patch-file-path | |
8432 | (lambda* (#:key inputs #:allow-other-keys) | |
8433 | (let ((file-path (assoc-ref inputs "file"))) | |
8434 | (substitute* "py3status/parse_config.py" | |
8435 | (("check_output\\(\\['file'") | |
8436 | (string-append "check_output(['" file-path "/bin/file'"))) | |
8437 | #t)))) | |
8438 | #:tests? #f)) ; TODO: Requires many libraries not in Guix. | |
6ba8ca17 TČ |
8439 | (home-page "https://github.com/ultrabug/py3status") |
8440 | (synopsis "Extensible i3status wrapper written in Python") | |
8441 | (description "py3status is an i3status wrapper which extends i3status | |
8442 | functionality in a modular way, allowing you to extend your panel with your | |
8443 | own code, responding to click events and updating clock every second.") | |
3f641af0 | 8444 | (license license:bsd-3))) |
b8fdbca3 HG |
8445 | |
8446 | (define-public python-tblib | |
8447 | (package | |
8448 | (name "python-tblib") | |
8449 | (version "1.3.0") | |
8450 | (source (origin | |
8451 | (method url-fetch) | |
8452 | (uri (pypi-uri "tblib" version)) | |
8453 | (sha256 (base32 | |
8454 | "02iahfkfa927hb4jq2bak36ldihwapzacfiq5lyxg8llwn98a1yi")))) | |
8455 | (build-system python-build-system) | |
8456 | (arguments | |
8457 | `(#:phases | |
8458 | (modify-phases %standard-phases | |
8459 | (replace 'check | |
8460 | (lambda _ | |
8461 | ;; Upstream runs tests after installation and the package itself | |
8462 | ;; resides in a subdirectory. Extend PYTHONPATH so it will be | |
8463 | ;; found. | |
8464 | (setenv "PYTHONPATH" | |
8465 | (string-append (getcwd) "/build/lib:" | |
8466 | (getenv "PYTHONPATH"))) | |
8467 | (zero? (system* "py.test" "-vv" "tests" "README.rst"))))))) | |
8468 | (native-inputs | |
8469 | `(("python-pytest" ,python-pytest) | |
b8fdbca3 HG |
8470 | ("python-six" ,python-six))) |
8471 | (home-page "https://github.com/ionelmc/python-tblib") | |
8472 | (synopsis "Traceback serialization library") | |
8473 | (description | |
8474 | "Traceback serialization allows you to: | |
8475 | ||
8476 | @enumerate | |
8477 | @item Pickle tracebacks and raise exceptions with pickled tracebacks in | |
8478 | different processes. This allows better error handling when running code over | |
8479 | multiple processes (imagine multiprocessing, billiard, futures, celery etc). | |
8480 | ||
8481 | @item Parse traceback strings and raise with the parsed tracebacks. | |
9657aeb1 | 8482 | @end enumerate\n") |
3f641af0 | 8483 | (license license:bsd-3))) |
b8fdbca3 HG |
8484 | |
8485 | (define-public python2-tblib | |
8486 | (package-with-python2 python-tblib)) | |
1a024de4 | 8487 | |
68b9d242 SB |
8488 | (define-public python-greenlet |
8489 | (package | |
8490 | (name "python-greenlet") | |
1f89fb16 | 8491 | (version "0.4.11") |
68b9d242 SB |
8492 | (source (origin |
8493 | (method url-fetch) | |
8494 | (uri (pypi-uri "greenlet" version)) | |
8495 | (sha256 | |
8496 | (base32 | |
1f89fb16 | 8497 | "1xhik26j4f3kc4qw9xmj0c567rb5h1zryb4ijwqnqwwjvfhbv59h")))) |
68b9d242 | 8498 | (build-system python-build-system) |
68b9d242 SB |
8499 | (home-page "https://greenlet.readthedocs.io/") |
8500 | (synopsis "Lightweight in-process concurrent programming") | |
8501 | (description | |
8502 | "Greenlet package is a spin-off of Stackless, a version of CPython | |
8503 | that supports micro-threads called \"tasklets\". Tasklets run | |
8504 | pseudo-concurrently (typically in a single or a few OS-level threads) and | |
8505 | are synchronized with data exchanges on \"channels\".") | |
3f641af0 | 8506 | (license (list license:psfl license:expat)))) |
68b9d242 SB |
8507 | |
8508 | (define-public python2-greenlet | |
8509 | (package-with-python2 python-greenlet)) | |
d79a343b SB |
8510 | |
8511 | (define-public python-gevent | |
8512 | (package | |
8513 | (name "python-gevent") | |
8514 | (version "1.1.1") | |
8515 | (source (origin | |
8516 | (method url-fetch) | |
8517 | (uri (pypi-uri "gevent" version)) | |
8518 | (sha256 | |
8519 | (base32 | |
8520 | "1smf3kvidpdiyi2c81alal74p2zm0clrm6xbyy6y1k9a3f2vkrbf")) | |
8521 | (modules '((guix build utils))) | |
8522 | (snippet | |
8523 | '(begin | |
8524 | ;; unbunding libev and c-ares | |
8525 | (for-each delete-file-recursively '("libev" "c-ares")) | |
8526 | ;; fixing testsuite | |
8527 | (call-with-output-file "greentest/__init__.py" noop) | |
8528 | (substitute* "greentest/testrunner.py" | |
8529 | (("import util") "from . import util") | |
8530 | (("from util import log") "from .util import log")))))) | |
8531 | (build-system python-build-system) | |
8532 | (propagated-inputs | |
8533 | `(("python-greenlet" ,python-greenlet))) | |
8534 | (native-inputs | |
f3b98f4f | 8535 | `(("python-six" ,python-six))) |
d79a343b SB |
8536 | (inputs |
8537 | `(("c-ares" ,c-ares) | |
8538 | ("libev" ,libev))) | |
8539 | (home-page "http://www.gevent.org/") | |
8540 | (synopsis "Coroutine-based network library") | |
8541 | (description | |
8542 | "gevent is a coroutine-based Python networking library that uses greenlet | |
8543 | to provide a high-level synchronous API on top of the libev event loop.") | |
8544 | (license license:expat))) | |
8545 | ||
8546 | (define-public python2-gevent | |
8547 | (package-with-python2 python-gevent)) | |
da3aeeb6 | 8548 | |
b585e361 DM |
8549 | (define-public python-fastimport |
8550 | (package | |
8551 | (name "python-fastimport") | |
8552 | (version "0.9.6") | |
8553 | (source | |
8554 | (origin | |
8555 | (method url-fetch) | |
8556 | (uri (pypi-uri "fastimport" version)) | |
8557 | (sha256 | |
8558 | (base32 "1aqjsin4rmqm7ln4j0p73fzxifws6c6ikgyhav7r137m2ixsxl43")))) | |
8559 | (build-system python-build-system) | |
8560 | (home-page "https://github.com/jelmer/python-fastimport") | |
8561 | (synopsis "VCS fastimport parser and generator in Python") | |
8562 | (description "This package provides a parser for and generator of the Git | |
8563 | @url{https://www.kernel.org/pub/software/scm/git/docs/git-fast-import.html,fastimport} | |
8564 | format.") | |
8565 | (license license:gpl2+))) | |
8566 | ||
8567 | (define-public python2-fastimport | |
8568 | (package-with-python2 python-fastimport)) | |
8569 | ||
da3aeeb6 SB |
8570 | (define-public python-twisted |
8571 | (package | |
8572 | (name "python-twisted") | |
c1578ad0 | 8573 | (version "17.1.0") |
da3aeeb6 SB |
8574 | (source (origin |
8575 | (method url-fetch) | |
8ea8e8d3 | 8576 | (uri (pypi-uri "Twisted" version ".tar.bz2")) |
da3aeeb6 SB |
8577 | (sha256 |
8578 | (base32 | |
c1578ad0 | 8579 | "1p245mg15hkxp7hy5cyq2fgvlgjkb4cg0gwkwd148nzy1bbi3wnv")))) |
da3aeeb6 | 8580 | (build-system python-build-system) |
a960e73f MB |
8581 | (arguments |
8582 | '(#:tests? #f)) ; FIXME: Some tests are failing. | |
8583 | ;; #:phases | |
8584 | ;; (modify-phases %standard-phases | |
8585 | ;; (replace 'check | |
8586 | ;; (lambda _ | |
8587 | ;; (zero? (system* "./bin/trial" "twisted"))))) | |
45912170 | 8588 | (propagated-inputs |
c1578ad0 TS |
8589 | `(("python-zope-interface" ,python-zope-interface) |
8590 | ("python-incremental" ,python-incremental) | |
8591 | ("python-constantly" ,python-constantly) | |
8592 | ("python-automat" ,python-automat))) | |
da3aeeb6 SB |
8593 | (home-page "https://twistedmatrix.com/") |
8594 | (synopsis "Asynchronous networking framework written in Python") | |
8595 | (description | |
8596 | "Twisted is an extensible framework for Python programming, with special | |
8597 | focus on event-based network programming and multiprotocol integration.") | |
8598 | (license license:expat))) | |
8599 | ||
8600 | (define-public python2-twisted | |
8601 | (package-with-python2 python-twisted)) | |
d0b6fed6 | 8602 | |
4d3fa5a4 EF |
8603 | (define-public python-pika |
8604 | (package | |
8605 | (name "python-pika") | |
8606 | (version "0.10.0") | |
8607 | (source | |
8608 | (origin | |
8609 | (method url-fetch) | |
8610 | (uri (pypi-uri "pika" version)) | |
8611 | (sha256 | |
8612 | (base32 | |
8613 | "0nb4h08di432lv7dy2v9kpwgk0w92f24sqc2hw2s9vwr5b8v8xvj")))) | |
8614 | (build-system python-build-system) | |
8615 | (native-inputs | |
269d9172 LF |
8616 | `(("python-pyev" ,python-pyev) |
8617 | ("python-tornado" ,python-tornado) | |
8618 | ("python-twisted" ,python-twisted))) | |
4d3fa5a4 EF |
8619 | (home-page "https://pika.readthedocs.org") |
8620 | (synopsis "Pure Python AMQP Client Library") | |
8621 | (description | |
8622 | "Pika is a pure-Python implementation of the AMQP (Advanced Message Queuing | |
8623 | Protocol) 0-9-1 protocol that tries to stay fairly independent of the underlying | |
8624 | network support library.") | |
8625 | (license license:bsd-3))) | |
8626 | ||
8627 | (define-public python2-pika | |
8628 | (package-with-python2 python-pika)) | |
8629 | ||
d0b6fed6 DM |
8630 | (define-public python-ply |
8631 | (package | |
8632 | (name "python-ply") | |
9e8401a5 | 8633 | (version "3.10") |
d0b6fed6 DM |
8634 | (source |
8635 | (origin | |
8636 | (method url-fetch) | |
234ade2d | 8637 | (uri (pypi-uri "ply" version)) |
d0b6fed6 DM |
8638 | (sha256 |
8639 | (base32 | |
9e8401a5 | 8640 | "1jxsr1d2f732r6ljhvm827113dckwl6qwakfvpbdhcbhvpvlmscn")))) |
d0b6fed6 DM |
8641 | (build-system python-build-system) |
8642 | (home-page "http://www.dabeaz.com/ply/") | |
8643 | (synopsis "Python Lex & Yacc") | |
8644 | (description "PLY is a @code{lex}/@code{yacc} implemented purely in Python. | |
8645 | It uses LR parsing and does extensive error checking.") | |
f210e944 | 8646 | (license license:bsd-3))) |
d0b6fed6 DM |
8647 | |
8648 | (define-public python2-ply | |
f210e944 | 8649 | (package-with-python2 python-ply)) |
d951bd54 SB |
8650 | |
8651 | (define-public python-tabulate | |
8652 | (package | |
8653 | (name "python-tabulate") | |
e6ace98d | 8654 | (version "0.7.7") |
d951bd54 SB |
8655 | (source (origin |
8656 | (method url-fetch) | |
8657 | (uri (pypi-uri "tabulate" version)) | |
8658 | (sha256 | |
8659 | (base32 | |
fe2ba3a8 | 8660 | "1inqhspd4frxnp08c32yndr0lc4px1xfkqah184i5w09gkhvi843")))) |
d951bd54 | 8661 | (build-system python-build-system) |
fe2ba3a8 MB |
8662 | (arguments |
8663 | ;; FIXME: The pypi release tarball is missing a 'test/common.py' | |
8664 | ;; and the latest release is not tagged in the upstream repository. | |
8665 | '(#:tests? #f)) | |
d951bd54 SB |
8666 | (home-page "https://bitbucket.org/astanin/python-tabulate") |
8667 | (synopsis "Pretty-print tabular data") | |
8668 | (description | |
8669 | "Tabulate is a library and command-line utility to pretty-print tabular | |
8670 | data in Python.") | |
8671 | (license license:expat))) | |
8672 | ||
8673 | (define-public python2-tabulate | |
8674 | (package-with-python2 python-tabulate)) | |
1c4c8a33 SB |
8675 | |
8676 | (define-public python-kazoo | |
8677 | (package | |
8678 | (name "python-kazoo") | |
8679 | (version "2.2.1") | |
8680 | (source | |
8681 | (origin | |
8682 | (method url-fetch) | |
8683 | (uri (pypi-uri "kazoo" version)) | |
8684 | (sha256 | |
8685 | (base32 | |
8686 | "10pb864if9qi2pq9lfb9m8f7z7ss6rml80gf1d9h64lap5crjnjj")))) | |
8687 | (build-system python-build-system) | |
8688 | (arguments '(#:tests? #f)) ; XXX: needs zookeeper | |
c18899e8 SB |
8689 | (propagated-inputs |
8690 | `(("python-six" ,python-six))) | |
1c4c8a33 SB |
8691 | (home-page "https://kazoo.readthedocs.org") |
8692 | (synopsis "High-level Zookeeper client library") | |
8693 | (description | |
8694 | "Kazoo is a Python client library for the Apache Zookeeper distributed | |
8695 | application service. It is designed to be easy to use and to avoid common | |
8696 | programming errors.") | |
3f641af0 | 8697 | (license license:asl2.0))) |
1c4c8a33 SB |
8698 | |
8699 | (define-public python2-kazoo | |
8700 | (package-with-python2 python-kazoo)) | |
45dda35e SB |
8701 | |
8702 | (define-public python-pykafka | |
8703 | (package | |
8704 | (name "python-pykafka") | |
8705 | (version "2.4.0") | |
8706 | (source (origin | |
8707 | (method url-fetch) | |
c6bccf71 EF |
8708 | (uri (string-append |
8709 | "https://pypi.python.org/packages/8b/3e/" | |
8710 | "384eeff406b06315738b62483fd2126c6e4f544167116b17cc04ea7d2a59/" | |
8711 | "pykafka-" version ".tar.gz")) | |
45dda35e SB |
8712 | (sha256 |
8713 | (base32 | |
8714 | "1id6sr159p6aa13bxcqyr9gln8sqg1l0ddzns5iws8kk5q1p5cfv")))) | |
8715 | (build-system python-build-system) | |
8716 | (arguments '(#:tests? #f)) ; XXX: needs zookeeper, kafka, etc. | |
c8fa3d9b | 8717 | (propagated-inputs |
45dda35e SB |
8718 | `(("python-gevent" ,python-gevent) |
8719 | ("python-kazoo" ,python-kazoo) | |
45dda35e SB |
8720 | ("python-tabulate" ,python-tabulate))) |
8721 | (inputs | |
8722 | `(("librdkafka" ,librdkafka))) | |
8723 | (home-page "https://pykafka.readthedocs.io/") | |
8724 | (synopsis "Apache Kafka client for Python") | |
8725 | (description | |
8726 | "PyKafka is a client for the Apache Kafka distributed messaging system. | |
8727 | It includes Python implementations of Kafka producers and consumers, which | |
8728 | are optionally backed by a C extension built on librdkafka.") | |
3f641af0 | 8729 | (license license:asl2.0))) |
45dda35e SB |
8730 | |
8731 | (define-public python2-pykafka | |
8732 | (package-with-python2 python-pykafka)) | |
a44fd439 DM |
8733 | |
8734 | (define-public python-wcwidth | |
8735 | (package | |
8736 | (name "python-wcwidth") | |
9e59478f | 8737 | (version "0.1.7") |
a44fd439 DM |
8738 | (source |
8739 | (origin | |
8740 | (method url-fetch) | |
9e59478f | 8741 | (uri (pypi-uri "wcwidth" version)) |
a44fd439 DM |
8742 | (sha256 |
8743 | (base32 | |
9e59478f | 8744 | "0pn6dflzm609m4r3i8ik5ni9ijjbb5fa3vg1n7hn6vkd49r77wrx")))) |
a44fd439 DM |
8745 | (build-system python-build-system) |
8746 | (home-page "https://github.com/jquast/wcwidth") | |
66e07664 | 8747 | (synopsis "Measure number of terminal column cells of wide-character codes") |
a44fd439 DM |
8748 | (description "Wcwidth measures the number of terminal column cells of |
8749 | wide-character codes. It is useful for those implementing a terminal emulator, | |
8750 | or programs that carefully produce output to be interpreted by one. It is a | |
8751 | Python implementation of the @code{wcwidth} and @code{wcswidth} C functions | |
8752 | specified in POSIX.1-2001 and POSIX.1-2008.") | |
f210e944 | 8753 | (license license:expat))) |
a44fd439 DM |
8754 | |
8755 | (define-public python2-wcwidth | |
f210e944 | 8756 | (package-with-python2 python-wcwidth)) |
0de78c95 DP |
8757 | |
8758 | (define-public python2-jsonrpclib | |
8759 | (package | |
8760 | (name "python2-jsonrpclib") | |
8761 | (version "0.1.7") | |
8762 | (source (origin | |
8763 | (method url-fetch) | |
8764 | (uri (string-append | |
8765 | "https://pypi.python.org/packages/source/j/jsonrpclib/" | |
8766 | "jsonrpclib-" version ".tar.gz")) | |
8767 | (sha256 | |
8768 | (base32 | |
8769 | "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z")))) | |
8770 | (build-system python-build-system) | |
0de78c95 DP |
8771 | (arguments |
8772 | `(#:tests? #f | |
8773 | #:python ,python-2)) | |
8774 | (home-page "https://github.com/joshmarshall/jsonrpclib/") | |
8775 | (synopsis "Implementation of JSON-RPC specification for Python") | |
8776 | (description | |
8777 | "This library is an implementation of the JSON-RPC specification. | |
8778 | It supports both the original 1.0 specification, as well as the | |
8779 | new (proposed) 2.0 spec, which includes batch submission, keyword arguments, | |
8780 | etc.") | |
3f641af0 | 8781 | (license license:asl2.0))) |
9250b0f3 SB |
8782 | |
8783 | (define-public python-chai | |
8784 | (package | |
8785 | (name "python-chai") | |
8786 | (version "1.1.1") | |
8787 | (source (origin | |
8788 | (method url-fetch) | |
8789 | (uri (pypi-uri "chai" version)) | |
8790 | (sha256 | |
8791 | (base32 | |
8792 | "016kf3irrclpkpvcm7q0gmkfibq7jgy30a9v73pp42bq9h9a32bl")))) | |
8793 | (build-system python-build-system) | |
9250b0f3 SB |
8794 | (home-page "https://github.com/agoragames/chai") |
8795 | (synopsis "Mocking framework for Python") | |
8796 | (description | |
8797 | "Chai provides an api for mocking, stubbing and spying your python | |
8798 | objects, patterned after the Mocha library for Ruby.") | |
3f641af0 | 8799 | (license license:bsd-3))) |
9250b0f3 SB |
8800 | |
8801 | (define-public python2-chai | |
8802 | (package-with-python2 python-chai)) | |
8803 | ||
1f2b62a4 SB |
8804 | (define-public python-inflection |
8805 | (package | |
8806 | (name "python-inflection") | |
8807 | (version "0.3.1") | |
8808 | (source | |
8809 | (origin (method url-fetch) | |
8810 | (uri (pypi-uri "inflection" version)) | |
8811 | (sha256 | |
8812 | (base32 | |
8813 | "1jhnxgnw8y3mbzjssixh6qkc7a3afc4fygajhqrqalnilyvpzshq")))) | |
8814 | (build-system python-build-system) | |
e9127525 MB |
8815 | (native-inputs |
8816 | `(("python-pytest" ,python-pytest))) | |
7bf837fd | 8817 | (home-page "https://github.com/jpvanhal/inflection") |
1f2b62a4 SB |
8818 | (synopsis "Python string transformation library") |
8819 | (description | |
8820 | "Inflection is a string transformation library. It singularizes | |
8821 | and pluralizes English words, and transforms strings from CamelCase to | |
8822 | underscored string.") | |
8823 | (license license:expat))) | |
8824 | ||
8825 | (define-public python2-inflection | |
8826 | (package-with-python2 python-inflection)) | |
8827 | ||
18995566 SB |
8828 | (define-public python-pylev |
8829 | (package | |
8830 | (name "python-pylev") | |
8831 | (version "1.3.0") | |
8832 | (source (origin | |
8833 | (method url-fetch) | |
8834 | (uri (pypi-uri "pylev" version)) | |
8835 | (sha256 | |
8836 | (base32 | |
8837 | "1hz1x9blsbxya1y9nnhnwwdnqmakxi9mc0jkwj0rn6b1h44i0f86")))) | |
8838 | (build-system python-build-system) | |
7bf837fd | 8839 | (home-page "https://github.com/toastdriven/pylev") |
18995566 SB |
8840 | (synopsis "Levenshtein distance implementation in Python") |
8841 | (description "Pure Python Levenshtein implementation, based off the | |
8842 | Wikipedia code samples at | |
8843 | @url{http://en.wikipedia.org/wiki/Levenshtein_distance}.") | |
3f641af0 | 8844 | (license license:bsd-3))) |
18995566 SB |
8845 | |
8846 | (define-public python2-pylev | |
8847 | (package-with-python2 python-pylev)) | |
8848 | ||
f5deff7a SB |
8849 | (define-public python-cleo |
8850 | (package | |
8851 | (name "python-cleo") | |
5eebe8dc | 8852 | (version "0.6.1") |
f5deff7a SB |
8853 | (source (origin |
8854 | (method url-fetch) | |
8855 | (uri (pypi-uri "cleo" version)) | |
8856 | (sha256 | |
8857 | (base32 | |
5eebe8dc | 8858 | "0q1cf0szr0d54am4pypzwdnm74zpladdsinad94c2fz5i06fdpf7")))) |
f5deff7a SB |
8859 | (build-system python-build-system) |
8860 | (native-inputs | |
f3b98f4f | 8861 | `(;; For testing |
f5deff7a | 8862 | ("python-mock" ,python-mock) |
5eebe8dc | 8863 | ("python-pytest-mock" ,python-pytest-mock) |
f5deff7a | 8864 | ("python-pytest" ,python-pytest))) |
9403150a | 8865 | (propagated-inputs |
5eebe8dc BW |
8866 | `(("python-backpack" ,python-backpack) |
8867 | ("python-pastel" ,python-pastel) | |
9403150a | 8868 | ("python-pylev" ,python-pylev))) |
f5deff7a SB |
8869 | (home-page "https://github.com/sdispater/cleo") |
8870 | (synopsis "Command-line arguments library for Python") | |
8871 | (description | |
8872 | "Cleo allows you to create command-line commands with signature in | |
8873 | docstring and colored output.") | |
8874 | (license license:expat))) | |
8875 | ||
8876 | (define-public python2-cleo | |
8877 | (package-with-python2 python-cleo)) | |
8878 | ||
77cadb43 SB |
8879 | (define-public python-lazy-object-proxy |
8880 | (package | |
8881 | (name "python-lazy-object-proxy") | |
8882 | (version "1.2.2") | |
8883 | (source (origin | |
8884 | (method url-fetch) | |
8885 | (uri (pypi-uri "lazy-object-proxy" version)) | |
8886 | (sha256 | |
8887 | (base32 | |
8888 | "0s22aqqkdscyh8sjspyyax7qa1aiz8p4midrnyf39717fhfczm6x")))) | |
8889 | (build-system python-build-system) | |
77cadb43 SB |
8890 | (home-page "https://github.com/ionelmc/python-lazy-object-proxy") |
8891 | (synopsis "Lazy object proxy for python") | |
8892 | (description | |
8893 | "Lazy object proxy is an object that wraps a callable but defers the call | |
8894 | until the object is actually required, and caches the result of said call.") | |
3f641af0 | 8895 | (license license:bsd-2))) |
77cadb43 SB |
8896 | |
8897 | (define-public python2-lazy-object-proxy | |
8898 | (package-with-python2 python-lazy-object-proxy)) | |
8899 | ||
5477e05f SB |
8900 | (define-public python-dnspython |
8901 | (package | |
8902 | (name "python-dnspython") | |
6c514128 | 8903 | (version "1.15.0") |
5477e05f SB |
8904 | (source (origin |
8905 | (method url-fetch) | |
8906 | (uri (string-append "http://www.dnspython.org/kits/" | |
8907 | version "/dnspython-" version ".tar.gz")) | |
8908 | (sha256 | |
8909 | (base32 | |
6c514128 | 8910 | "0jr4v2pd90i6l1xxbss2m05psbjaxvyvvvpq44wycijpfgjqln8i")))) |
5477e05f SB |
8911 | (build-system python-build-system) |
8912 | (arguments '(#:tests? #f)) ; XXX: requires internet access | |
5477e05f SB |
8913 | (home-page "http://www.dnspython.org") |
8914 | (synopsis "DNS toolkit for Python") | |
8915 | (description | |
8916 | "dnspython is a DNS toolkit for Python. It supports almost all record | |
8917 | types. It can be used for queries, zone transfers, and dynamic updates. | |
8918 | It supports TSIG authenticated messages and EDNS0.") | |
8919 | (license license:expat))) | |
8920 | ||
8921 | (define-public python2-dnspython | |
8922 | (package-with-python2 python-dnspython)) | |
8923 | ||
22711e25 SB |
8924 | (define-public python-email-validator |
8925 | (package | |
8926 | (name "python-email-validator") | |
b165c215 | 8927 | (version "1.0.2") |
22711e25 SB |
8928 | (source |
8929 | (origin (method url-fetch) | |
8930 | (uri (pypi-uri "email_validator" version)) | |
8931 | (sha256 | |
8932 | (base32 | |
b165c215 | 8933 | "1ja9149l9ck5n45a72h3is7v476hjny5ybxbcamx1nw6iplsm7k6")))) |
22711e25 SB |
8934 | (build-system python-build-system) |
8935 | (arguments | |
8936 | '(#:phases | |
8937 | (modify-phases %standard-phases | |
8938 | (add-before 'build 'use-dnspython | |
8939 | (lambda _ | |
8940 | (substitute* "setup.py" | |
8941 | (("dnspython3") "dnspython")) | |
8942 | #t))))) | |
d42560bd | 8943 | (propagated-inputs |
22711e25 | 8944 | `(("python-dnspython" ,python-dnspython) |
d42560bd | 8945 | ("python-idna" ,python-idna))) |
22711e25 SB |
8946 | (home-page "https://github.com/JoshData/python-email-validator") |
8947 | (synopsis "Email address validation library for Python") | |
8948 | (description | |
8949 | "This library validates email address syntax and deliverability.") | |
3f641af0 | 8950 | (license license:cc0))) |
22711e25 SB |
8951 | |
8952 | (define-public python2-email-validator | |
8953 | (package-with-python2 python-email-validator)) | |
8954 | ||
8987d91e SB |
8955 | (define-public python-ukpostcodeparser |
8956 | (package | |
8957 | (name "python-ukpostcodeparser") | |
8958 | (version "1.0.3") | |
8959 | (source (origin | |
8960 | (method url-fetch) | |
8961 | (uri (pypi-uri "UkPostcodeParser" version)) | |
8962 | (sha256 | |
8963 | (base32 | |
8964 | "1jwg9z4rz51mcka1821rwgycsd0mcicyp1kiwjfa2kvg8bm9p2qd")))) | |
8965 | (build-system python-build-system) | |
8987d91e SB |
8966 | (home-page "https://github.com/hamstah/ukpostcodeparser") |
8967 | (synopsis "UK Postcode parser for Python") | |
8968 | (description | |
8969 | "This library provides the @code{parse_uk_postcode} function for | |
8970 | parsing UK postcodes.") | |
8971 | (license license:expat))) | |
8972 | ||
8973 | (define-public python2-ukpostcodeparser | |
8974 | (package-with-python2 python-ukpostcodeparser)) | |
ea92ae01 | 8975 | |
ce7911dd MB |
8976 | (define-public python-faker |
8977 | (package | |
8978 | (name "python-faker") | |
8979 | (version "0.7.9") | |
8980 | (source (origin | |
8981 | (method url-fetch) | |
8982 | (uri (pypi-uri "Faker" version)) | |
8983 | (sha256 | |
8984 | (base32 | |
8985 | "1fh2p2yz0fsdr4fqwxgddwbvfb6qn6vp8yx0qwqzra27yq5d1wsm")) | |
8986 | (patches | |
8987 | (search-patches "python-faker-fix-build-32bit.patch")) | |
8988 | (modules '((guix build utils))) | |
8989 | (snippet | |
8990 | '(begin | |
8991 | (for-each delete-file (find-files "." "\\.pyc$")) | |
8992 | #t)))) | |
8993 | (build-system python-build-system) | |
8994 | (arguments | |
8995 | '(#:phases | |
8996 | (modify-phases %standard-phases | |
8997 | (replace 'check | |
8998 | (lambda _ | |
8999 | (zero? (system* "python" "-m" "unittest" "-v" "tests"))))))) | |
9000 | (native-inputs | |
9001 | `(;; For testing | |
9002 | ("python-email-validator" ,python-email-validator) | |
9003 | ("python-mock" ,python-mock) | |
9004 | ("python-ukpostcodeparser" ,python-ukpostcodeparser))) | |
9005 | (propagated-inputs | |
9006 | `(("python-dateutil" ,python-dateutil) | |
9007 | ("python-six" ,python-six))) | |
9008 | (home-page "https://github.com/joke2k/faker") | |
9009 | (synopsis "Python package that generates fake data") | |
9010 | (description | |
9011 | "Faker is a Python package that generates fake data such as names, | |
9012 | addresses, and phone numbers.") | |
9013 | (license license:expat) | |
9014 | (properties `((python2-variant . ,(delay python2-faker)))))) | |
9015 | ||
9016 | (define-public python2-faker | |
9017 | (let ((base (package-with-python2 (strip-python2-variant | |
9018 | python-faker)))) | |
9019 | (package | |
9020 | (inherit base) | |
9021 | (propagated-inputs | |
9022 | `(("python2-ipaddress" ,python2-ipaddress) | |
9023 | ,@(package-propagated-inputs base)))))) | |
9024 | ||
b49504fd SB |
9025 | (define-public python-pyaml |
9026 | (package | |
9027 | (name "python-pyaml") | |
963926bc | 9028 | (version "17.7.2") |
b49504fd SB |
9029 | (source (origin |
9030 | (method url-fetch) | |
9031 | (uri (pypi-uri "pyaml" version)) | |
9032 | (sha256 | |
9033 | (base32 | |
963926bc | 9034 | "132grrw0ajq4nrappi3ldbkb952k7yn9b6c7csi2rmvzm1g6ppp2")))) |
b49504fd | 9035 | (build-system python-build-system) |
f620311a MB |
9036 | (native-inputs |
9037 | `(("python-unidecode" ,python-unidecode))) | |
b49504fd SB |
9038 | (propagated-inputs |
9039 | `(("python-pyyaml" ,python-pyyaml))) | |
9040 | (home-page "https://github.com/mk-fg/pretty-yaml") | |
9041 | (synopsis "YAML pretty-print library for Python") | |
9042 | (description | |
9043 | "pyaml is a PyYAML based python module to produce pretty and readable | |
9044 | YAML-serialized data.") | |
3f641af0 | 9045 | (license (license:non-copyleft "http://www.wtfpl.net/txt/copying/")))) |
b49504fd SB |
9046 | |
9047 | (define-public python2-pyaml | |
9048 | (package-with-python2 python-pyaml)) | |
9049 | ||
04fb4516 BW |
9050 | (define-public python-backpack |
9051 | (package | |
9052 | (name "python-backpack") | |
9053 | (version "0.1") | |
9054 | (source | |
9055 | (origin | |
9056 | (method url-fetch) | |
9057 | (uri (pypi-uri "backpack" version)) | |
9058 | (sha256 | |
9059 | (base32 | |
9060 | "14rq1mvm0jda90lcx9gyyby9dvq4x3js2cmxvd6vl4686ixwyqh1")))) | |
9061 | (build-system python-build-system) | |
9062 | (native-inputs | |
9063 | `(("python-pytest" ,python-pytest) | |
9064 | ("python-nose" ,python-nose))) | |
9065 | (propagated-inputs | |
9066 | `(("python-simplejson" ,python-simplejson))) | |
9067 | (home-page "https://github.com/sdispater/backpack") | |
9068 | (synopsis "Utilities for working with Python collections") | |
9069 | (description "Backpack provides some useful utilities for working with | |
9070 | collections of data.") | |
9071 | (license license:expat))) | |
9072 | ||
9073 | (define-public python2-backpack | |
9074 | (package-with-python2 python-backpack)) | |
9075 | ||
f4155188 DM |
9076 | (define-public python-prompt-toolkit |
9077 | (package | |
9078 | (name "python-prompt-toolkit") | |
b46ea394 | 9079 | (version "1.0.15") |
f4155188 DM |
9080 | (source |
9081 | (origin | |
9082 | (method url-fetch) | |
d15e2ef0 | 9083 | (uri (pypi-uri "prompt_toolkit" version ".tar.gz")) |
f4155188 DM |
9084 | (sha256 |
9085 | (base32 | |
b46ea394 | 9086 | "05v9h5nydljwpj5nm8n804ms0glajwfy1zagrzqrg91wk3qqi1c5")))) |
f4155188 | 9087 | (build-system python-build-system) |
bae18710 LF |
9088 | (arguments |
9089 | '(#:tests? #f)) ; The test suite uses some Windows-specific data types. | |
f22efa01 HG |
9090 | (propagated-inputs |
9091 | `(("python-wcwidth" ,python-wcwidth) | |
2c199b55 | 9092 | ("python-six" ,python-six) |
f22efa01 | 9093 | ("python-pygments" ,python-pygments))) |
f4155188 DM |
9094 | (home-page "https://github.com/jonathanslenders/python-prompt-toolkit") |
9095 | (synopsis "Library for building command line interfaces in Python") | |
9096 | (description | |
9097 | "Prompt-Toolkit is a library for building interactive command line | |
9098 | interfaces in Python. It's like GNU Readline but it also features syntax | |
9099 | highlighting while typing, out-of-the-box multi-line input editing, advanced | |
9100 | code completion, incremental search, support for Chinese double-width | |
9101 | characters, mouse support, and auto suggestions.") | |
f210e944 | 9102 | (license license:bsd-3))) |
f4155188 DM |
9103 | |
9104 | (define-public python2-prompt-toolkit | |
f210e944 | 9105 | (package-with-python2 python-prompt-toolkit)) |
a502dfbf DM |
9106 | |
9107 | (define-public python-jedi | |
9108 | (package | |
9109 | (name "python-jedi") | |
9110 | (version "0.9.0") | |
9111 | (source | |
9112 | (origin | |
9113 | (method url-fetch) | |
9114 | (uri (pypi-uri "jedi" version)) | |
9115 | (sha256 | |
9116 | (base32 | |
9117 | "0c8x962ynpx001fdvp07m2q5jk4igkxbj3rmnydavphvlgxijk1v")))) | |
9118 | (build-system python-build-system) | |
bfce8a34 MB |
9119 | (arguments |
9120 | ;; FIXME: One test fails (use "py.test" instead of 'setup.py test'). | |
9121 | '(#:tests? #f)) | |
9122 | (native-inputs | |
9123 | `(("python-pytest" ,python-pytest))) | |
a502dfbf DM |
9124 | (home-page "https://github.com/davidhalter/jedi") |
9125 | (synopsis | |
9126 | "Autocompletion for Python that can be used for text editors") | |
9127 | (description | |
9128 | "Jedi is an autocompletion tool for Python that can be used for text editors.") | |
f210e944 | 9129 | (license license:expat))) |
a502dfbf DM |
9130 | |
9131 | (define-public python2-jedi | |
f210e944 | 9132 | (package-with-python2 python-jedi)) |
c2f0dc6e DM |
9133 | |
9134 | (define-public ptpython | |
9135 | (package | |
9136 | (name "ptpython") | |
9137 | (version "0.34") | |
9138 | (source (origin | |
9139 | (method url-fetch) | |
9140 | (uri (pypi-uri "ptpython" version)) | |
9141 | (sha256 | |
9142 | (base32 | |
9143 | "1mmbiyzf0n8hm7z2a562x7w5cbl6jc0zsk6vp40q1z4cyblv1k13")))) | |
9144 | (build-system python-build-system) | |
32955348 MB |
9145 | (arguments |
9146 | '(#:tests? #f)) ; FIXME: No tests in pypi tarball. | |
f22efa01 | 9147 | (propagated-inputs |
c2f0dc6e DM |
9148 | `(("python-docopt" ,python-docopt) |
9149 | ("python-jedi" ,python-jedi) | |
9150 | ("python-prompt-toolkit" ,python-prompt-toolkit) | |
f3b98f4f | 9151 | ("python-pygments" ,python-pygments))) |
c2f0dc6e DM |
9152 | (home-page "https://github.com/jonathanslenders/ptpython") |
9153 | (synopsis "Python Read-Eval-Print-Loop with nice IDE-like features") | |
9154 | (description | |
9155 | "ptpython is a Python read-eval-print loop with IDE-like features. | |
9156 | It supports syntax highlighting, multiline editing, autocompletion, mouse, | |
9157 | color schemes, bracketed paste, Vi and Emacs keybindings, Chinese characters | |
9158 | etc.") | |
3f641af0 | 9159 | (license license:bsd-3) |
c2f0dc6e DM |
9160 | (properties `((python2-variant . ,(delay ptpython-2)))))) |
9161 | ||
9162 | (define-public ptpython-2 | |
9163 | (let ((base (package-with-python2 (strip-python2-variant ptpython)))) | |
9164 | (package | |
9165 | (inherit base) | |
9166 | (name "ptpython2")))) | |
b227f0be | 9167 | |
9168 | (define-public python-stem | |
9169 | (package | |
9170 | (name "python-stem") | |
0bb1c35a | 9171 | (version "1.5.4") |
b227f0be | 9172 | (source |
9173 | (origin | |
9174 | (method url-fetch) | |
c976b319 | 9175 | (uri (pypi-uri "stem" version)) |
b227f0be | 9176 | (sha256 |
9177 | (base32 | |
0bb1c35a | 9178 | "1j7pnblrn0yr6jmxvsq6y0ihmxmj5x50jl2n2606w67f6wq16j9n")))) |
b227f0be | 9179 | (build-system python-build-system) |
9180 | (arguments | |
9181 | `(#:phases | |
9182 | (modify-phases %standard-phases | |
9183 | (replace 'check | |
9184 | (lambda _ | |
9185 | (zero? (system* "./run_tests.py" "--unit"))))))) | |
9186 | (native-inputs | |
9187 | `(("python-mock" ,python-mock) | |
9188 | ("python-pep8" ,python-pep8) | |
9189 | ("python-pyflakes" ,python-pyflakes))) | |
b227f0be | 9190 | (home-page "https://stem.torproject.org/") |
9191 | (synopsis | |
9192 | "Python controller library that allows applications to interact with Tor") | |
9193 | (description | |
9194 | "Stem is a Python controller library for Tor. With it you can use Tor's | |
9195 | control protocol to script against the Tor process and read descriptor data | |
9196 | relays publish about themselves.") | |
3f641af0 | 9197 | (license license:lgpl3))) |
b227f0be | 9198 | |
9199 | (define-public python2-stem | |
9200 | (package-with-python2 python-stem)) | |
517a6c0c DM |
9201 | |
9202 | (define-public python-pyserial | |
9203 | (package | |
9204 | (name "python-pyserial") | |
9205 | (version "3.1.1") | |
9206 | (source | |
9207 | (origin | |
9208 | (method url-fetch) | |
9209 | (uri (pypi-uri "pyserial" version)) | |
9210 | (sha256 | |
9211 | (base32 | |
9212 | "0k1nfdrxxkdlv4zgaqsdv8li0pj3gbh2pyxw8q2bsg6f9490amyn")))) | |
9213 | (build-system python-build-system) | |
0a702009 MB |
9214 | (arguments |
9215 | '(#:tests? #f)) ; FIXME: 3/49 tests are failing. | |
9216 | ;; #:phases | |
9217 | ;; (modify-phases %standard-phases | |
9218 | ;; (replace 'check | |
9219 | ;; (lambda _ | |
9220 | ;; (zero? (system* "python" "test/run_all_tests.py" "loop://"))))))) | |
517a6c0c DM |
9221 | (home-page |
9222 | "https://github.com/pyserial/pyserial") | |
9223 | (synopsis "Python Serial Port Bindings") | |
9224 | (description "@code{pyserial} provide serial port bindings for Python. It | |
9225 | supports different byte sizes, stop bits, parity and flow control with RTS/CTS | |
9226 | and/or Xon/Xoff. The port is accessed in RAW mode.") | |
f210e944 | 9227 | (license license:bsd-3))) |
517a6c0c DM |
9228 | |
9229 | (define-public python2-pyserial | |
f210e944 | 9230 | (package-with-python2 python-pyserial)) |
6eb7af2a DJ |
9231 | |
9232 | (define-public python-kivy | |
9233 | (package | |
9234 | (name "python-kivy") | |
e81e154c | 9235 | (version "1.10.0") |
6eb7af2a DJ |
9236 | (source |
9237 | (origin | |
9238 | (method url-fetch) | |
e81e154c | 9239 | (uri (pypi-uri "Kivy" version)) |
6eb7af2a DJ |
9240 | (file-name (string-append name "-" version ".tar.gz")) |
9241 | (sha256 | |
9242 | (base32 | |
e81e154c | 9243 | "1394zh6kvf7k5d8vlzxcsfcailr3q59xwg9b1n7qaf25bvyq1h98")))) |
6eb7af2a DJ |
9244 | (build-system python-build-system) |
9245 | (arguments | |
9246 | `(#:tests? #f ; Tests require many optional packages | |
9247 | #:phases | |
9248 | (modify-phases %standard-phases | |
6eb7af2a DJ |
9249 | (add-after 'patch-generated-file-shebangs 'set-sdl-paths |
9250 | (lambda* (#:key inputs #:allow-other-keys) | |
9251 | (setenv "KIVY_SDL2_PATH" | |
9252 | (string-append (assoc-ref inputs "sdl-union") | |
9253 | "/include/SDL2")) | |
9254 | #t))))) | |
9255 | (native-inputs | |
f2516de2 HG |
9256 | `(("pkg-config" ,pkg-config) |
9257 | ("python-cython" ,python-cython))) | |
6eb7af2a | 9258 | (inputs |
f2516de2 | 9259 | `(("gstreamer" ,gstreamer) |
6eb7af2a DJ |
9260 | ("mesa" ,mesa) |
9261 | ("sdl-union" | |
9262 | ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf))))) | |
9263 | (home-page "http://kivy.org") | |
9264 | (synopsis | |
9265 | "Multitouch application framework") | |
9266 | (description | |
9267 | "A software library for rapid development of | |
9268 | hardware-accelerated multitouch applications.") | |
9269 | (license license:expat))) | |
9270 | ||
9271 | (define-public python2-kivy | |
9272 | (package-with-python2 python-kivy)) | |
9273 | ||
9274 | (define-public python-kivy-next | |
9275 | (let ((commit "a988c5e7a47da56263ff39514264a3de516ef2fe") | |
9276 | (revision "1")) | |
9277 | (package (inherit python-kivy) | |
9278 | (name "python-kivy-next") | |
d80a71eb | 9279 | (version (string-append "1.9.1-" revision "." |
6eb7af2a DJ |
9280 | (string-take commit 7))) |
9281 | (source | |
9282 | (origin | |
9283 | (method git-fetch) | |
9284 | (uri (git-reference | |
9285 | (url "https://github.com/kivy/kivy") | |
9286 | (commit commit))) | |
9287 | (file-name (string-append name "-" version "-checkout")) | |
9288 | (sha256 | |
9289 | (base32 | |
9290 | "0jk92b4a8l7blkvkgkjihk171s0dfnq582cckff5srwc8kal5m0p"))))))) | |
9291 | ||
9292 | (define-public python2-kivy-next | |
9293 | (package-with-python2 python-kivy-next)) | |
8794bd8b DC |
9294 | |
9295 | (define-public python-binaryornot | |
9296 | (package | |
9297 | (name "python-binaryornot") | |
9298 | (version "0.4.0") | |
9299 | (source (origin | |
9300 | (method url-fetch) | |
9301 | (uri (pypi-uri "binaryornot" version)) | |
9302 | (sha256 | |
9303 | (base32 | |
9304 | "1j4f51dxic39mdwf6alj7gd769wy6mhk916v031wjali51xkh3xb")))) | |
9305 | (build-system python-build-system) | |
f22efa01 | 9306 | (propagated-inputs |
8794bd8b DC |
9307 | `(("python-chardet" ,python-chardet) |
9308 | ("python-hypothesis" ,python-hypothesis))) | |
9309 | (home-page "https://github.com/audreyr/binaryornot") | |
9310 | (synopsis "Package to check if a file is binary or text") | |
9311 | (description "Ultra-lightweight pure Python package to check if a file is | |
9312 | binary or text.") | |
9313 | (license license:bsd-3) | |
9314 | (properties `((python2-variant . ,(delay python2-binaryornot)))))) | |
9315 | ||
9316 | (define-public python2-binaryornot | |
9317 | (let ((base (package-with-python2 (strip-python2-variant python-binaryornot)))) | |
9318 | (package (inherit base) | |
f22efa01 | 9319 | (propagated-inputs |
8794bd8b | 9320 | `(("python2-enum34" ,python2-enum34) |
f22efa01 | 9321 | ,@(package-propagated-inputs base)))))) |
a9ac982a DC |
9322 | |
9323 | (define-public python-nltk | |
9324 | (package | |
9325 | (name "python-nltk") | |
9326 | (version "3.2.1") | |
9327 | (source (origin | |
9328 | (method url-fetch) | |
9329 | (uri (pypi-uri "nltk" version)) | |
9330 | (sha256 | |
9331 | (base32 | |
9332 | "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym")))) | |
9333 | (build-system python-build-system) | |
59f12985 LF |
9334 | (arguments |
9335 | '(;; The tests require some extra resources to be downloaded. | |
9336 | ;; TODO Try packaging these resources. | |
9337 | #:tests? #f)) | |
a9ac982a DC |
9338 | (home-page "http://nltk.org/") |
9339 | (synopsis "Natural Language Toolkit") | |
9340 | (description "It provides interfaces to over 50 corpora and lexical | |
9341 | resources such as WordNet, along with a suite of text processing libraries | |
9342 | for classification, tokenization, stemming, tagging, parsing, and semantic | |
9343 | reasoning, wrappers for natural language processing libraries.") | |
f210e944 | 9344 | (license license:asl2.0))) |
a9ac982a DC |
9345 | |
9346 | (define-public python2-nltk | |
f210e944 | 9347 | (package-with-python2 python-nltk)) |
691cd90d DC |
9348 | |
9349 | (define-public python-pymongo | |
9350 | (package | |
9351 | (name "python-pymongo") | |
9352 | (version "3.3.0") | |
9353 | (source (origin | |
9354 | (method url-fetch) | |
9355 | (uri (pypi-uri "pymongo" version)) | |
9356 | (sha256 | |
9357 | (base32 | |
9358 | "07mra6w86wjqy4lx5fvimidjhhfzd562gfjn8grsnbv2q8pk0i9x")))) | |
9359 | (build-system python-build-system) | |
f22efa01 | 9360 | (propagated-inputs |
691cd90d | 9361 | `(("python-certifi" ,python-certifi))) |
7bf837fd | 9362 | (home-page "https://github.com/mongodb/mongo-python-driver") |
691cd90d DC |
9363 | (synopsis "Python driver for MongoDB") |
9364 | (description "Python driver for MongoDB.") | |
f210e944 | 9365 | (license license:asl2.0))) |
691cd90d DC |
9366 | |
9367 | (define-public python2-pymongo | |
f210e944 | 9368 | (package-with-python2 python-pymongo)) |
6a6c9d43 DC |
9369 | |
9370 | (define-public python-sh | |
9371 | (package | |
9372 | (name "python-sh") | |
9373 | (version "1.11") | |
9374 | (source (origin | |
9375 | (method url-fetch) | |
9376 | (uri (pypi-uri "sh" version)) | |
9377 | (sha256 | |
9378 | (base32 | |
9379 | "192r0mpv6dmkysjzhc43ddffiwb5g7c76bgr1mb1z2xz9awbj3sr")))) | |
9380 | (build-system python-build-system) | |
9381 | (arguments | |
9382 | `(#:tests? #f)) ; no tests | |
9383 | (home-page "https://github.com/amoffat/sh") | |
9384 | (synopsis "Python subprocess interface") | |
9385 | (description "Abstracts process invocation by providing a function | |
9386 | interface for programs.") | |
f210e944 | 9387 | (license license:expat))) |
6a6c9d43 DC |
9388 | |
9389 | (define-public python2-sh | |
f210e944 | 9390 | (package-with-python2 python-sh)) |
05b59190 | 9391 | |
25702397 EF |
9392 | (define-public python-consul |
9393 | (package | |
9394 | (name "python-consul") | |
9395 | (version "0.6.1") | |
9396 | (source | |
9397 | (origin | |
9398 | (method url-fetch) | |
9399 | (uri (pypi-uri "python-consul" version)) | |
9400 | (sha256 | |
9401 | (base32 | |
9402 | "0rfyxcy4cr3x848vhx876ifalxd5ghq6l5x813m49h4vq2d4jiq8")))) | |
9403 | (build-system python-build-system) | |
9404 | (native-inputs | |
fd1d6de7 HG |
9405 | `(("python-pytest" ,python-pytest))) |
9406 | (propagated-inputs | |
9407 | `(("python-requests" ,python-requests) | |
25702397 EF |
9408 | ("python-six" ,python-six))) |
9409 | (home-page "https://github.com/cablehead/python-consul") | |
9410 | (synopsis "Python client for Consul") | |
9411 | (description | |
9412 | "Python client for @url{http://www.consul.io/,Consul}, a tool for service | |
9413 | discovery, monitoring and configuration.") | |
9414 | (license license:expat))) | |
9415 | ||
9416 | (define-public python2-consul | |
f210e944 | 9417 | (package-with-python2 python-consul)) |
25702397 | 9418 | |
05b59190 DC |
9419 | (define-public python-schematics |
9420 | (package | |
9421 | (name "python-schematics") | |
9422 | (version "1.1.1") | |
9423 | (source | |
9424 | (origin | |
9425 | (method url-fetch) | |
9426 | (uri (string-append | |
9427 | "https://github.com/schematics/schematics/archive/v" version ".tar.gz")) | |
9428 | (file-name (string-append name "-" version ".tar.gz")) | |
9429 | (sha256 | |
9430 | (base32 | |
9431 | "19v1i69bf3bzarfxmbv0v6ivpcn758x3shvbiy9l2hy0lvqwnp6l")))) | |
9432 | (build-system python-build-system) | |
f22efa01 | 9433 | (propagated-inputs |
05b59190 DC |
9434 | `(("python-six" ,python-six))) |
9435 | (arguments | |
9436 | `(#:tests? #f)) ; requires a bunch of not very nice packages with fixed | |
9437 | ; version requirements (eg python-coveralls) | |
9438 | (home-page "https://github.com/schematics/schematics") | |
9439 | (synopsis "Python Data Structures for Humans") | |
9440 | (description "Python Data Structures for Humans.") | |
f210e944 | 9441 | (license license:bsd-3))) |
05b59190 DC |
9442 | |
9443 | (define-public python2-schematics | |
f210e944 | 9444 | (package-with-python2 python-schematics)) |
d6907ff7 | 9445 | |
dddcb25c MB |
9446 | (define-public python-odfpy |
9447 | (package | |
9448 | (name "python-odfpy") | |
9449 | (version "1.3.3") | |
9450 | (source (origin | |
9451 | (method url-fetch) | |
9452 | (uri (pypi-uri "odfpy" version)) | |
9453 | (sha256 | |
9454 | (base32 | |
9455 | "1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw")))) | |
9456 | (arguments | |
9457 | `(#:modules ((srfi srfi-1) | |
9458 | (guix build python-build-system) | |
9459 | (guix build utils)) | |
9460 | #:phases | |
9461 | (modify-phases %standard-phases | |
9462 | (replace 'check | |
9463 | ;; The test runner invokes python2 and python3 for test*.py. | |
9464 | ;; To avoid having both in inputs, we replicate it here. | |
9465 | (lambda _ | |
9466 | (every (lambda (test-file) | |
9467 | (zero? (system* "python" test-file))) | |
9468 | (find-files "tests" "^test.*\\.py$"))))))) | |
9469 | (build-system python-build-system) | |
9470 | (home-page "https://github.com/eea/odfpy") | |
9471 | (synopsis "Python API and tools to manipulate OpenDocument files") | |
9472 | (description "Collection of libraries and utility programs written in | |
9473 | Python to manipulate OpenDocument 1.2 files.") | |
9474 | (license | |
9475 | ;; The software is mainly dual GPL2+ and ASL2.0, but includes a | |
9476 | ;; number of files with other licenses. | |
9477 | (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0)))) | |
9478 | ||
9479 | (define-public python2-odfpy | |
9480 | (package-with-python2 python-odfpy)) | |
b30565bd | 9481 | |
5467ea62 MB |
9482 | (define-public python-natsort |
9483 | (package | |
9484 | (name "python-natsort") | |
a06cd95a | 9485 | (version "5.0.2") |
5467ea62 MB |
9486 | (source (origin |
9487 | (method url-fetch) | |
9488 | (uri (pypi-uri "natsort" version)) | |
9489 | (sha256 | |
9490 | (base32 | |
a06cd95a | 9491 | "0bh6j0l8iapjnsgg3bs6q075cnzjl6zw1vlgqyv3qrygm2cxypkn")))) |
5467ea62 MB |
9492 | (build-system python-build-system) |
9493 | (arguments | |
9494 | `(#:phases | |
9495 | (modify-phases %standard-phases | |
9496 | (add-before 'check 'set-cachedir | |
9497 | ;; Tests require write access to $HOME by default | |
9498 | (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t))))) | |
9499 | (native-inputs | |
9500 | `(("python-hypothesis" ,python-hypothesis) | |
9501 | ("python-pytest-cache" ,python-pytest-cache) | |
9502 | ("python-pytest-cov" ,python-pytest-cov) | |
9503 | ("python-pytest-flakes" ,python-pytest-flakes) | |
9504 | ("python-pytest-pep8" ,python-pytest-pep8))) | |
9505 | (propagated-inputs ; TODO: Add python-fastnumbers. | |
9506 | `(("python-pyicu" ,python-pyicu))) | |
9507 | (home-page "https://github.com/SethMMorton/natsort") | |
9508 | (synopsis "Natural sorting for python and shell") | |
9509 | (description | |
9510 | "Natsort lets you apply natural sorting on lists instead of | |
9511 | lexicographical. If you use the built-in @code{sorted} method in python | |
9512 | on a list such as @code{['a20', 'a9', 'a1', 'a4', 'a10']}, it would be | |
9513 | returned as @code{['a1', 'a10', 'a20', 'a4', 'a9']}. Natsort provides a | |
9514 | function @code{natsorted} that identifies numbers and sorts them separately | |
9515 | from strings. It can also sort version numbers, real numbers, mixed types | |
9516 | and more, and comes with a shell command @command{natsort} that exposes this | |
9517 | functionality in the command line.") | |
9518 | (license license:expat) | |
9519 | (properties `((python2-variant . ,(delay python2-natsort)))))) | |
9520 | ||
9521 | (define-public python2-natsort | |
9522 | (let ((base (package-with-python2 (strip-python2-variant python-natsort)))) | |
9523 | (package (inherit base) | |
9524 | (native-inputs | |
00e10c6e | 9525 | `(("python2-pathlib" ,python2-pathlib) |
5467ea62 MB |
9526 | ("python2-mock" ,python2-mock) |
9527 | ("python2-enum34" ,python2-enum34) | |
9528 | ,@(package-native-inputs base)))))) | |
4efb9c54 SR |
9529 | |
9530 | (define-public python-glances | |
9531 | (package | |
9532 | (name "python-glances") | |
9533 | (version "2.7.1") | |
9534 | (source | |
9535 | (origin | |
9536 | (method url-fetch) | |
9537 | (uri (pypi-uri "Glances" version)) | |
9538 | (sha256 | |
9539 | (base32 | |
9540 | "11jbq40g8alsbirnd4kiagznqg270247i0m8qhi48ldf2i5xppxg")))) | |
9541 | (build-system python-build-system) | |
f22efa01 | 9542 | (propagated-inputs |
4efb9c54 SR |
9543 | `(("python-psutil" ,python-psutil))) |
9544 | (home-page | |
9545 | "https://github.com/nicolargo/glances") | |
9546 | (synopsis | |
9547 | "A cross-platform curses-based monitoring tool") | |
9548 | (description | |
9549 | "Glances is a curses-based monitoring tool for a wide variety of platforms. | |
9550 | Glances uses the PsUtil library to get information from your system. It monitors | |
9551 | CPU, load, memory, network bandwidth, disk I/O, disk use, and more.") | |
f210e944 | 9552 | (license license:lgpl3+))) |
4efb9c54 SR |
9553 | |
9554 | (define-public python2-glances | |
f210e944 | 9555 | (package-with-python2 python-glances)) |
05b7a593 EF |
9556 | |
9557 | (define-public python-graphql-core | |
9558 | (package | |
9559 | (name "python-graphql-core") | |
9560 | (version "0.5.3") | |
9561 | (source | |
9562 | (origin | |
9563 | (method url-fetch) | |
9564 | (uri (pypi-uri "graphql-core" version)) | |
9565 | (sha256 | |
9566 | (base32 | |
9567 | "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0")))) | |
9568 | (build-system python-build-system) | |
9569 | (arguments | |
326f8285 LF |
9570 | `(#:tests? #f ; Tests require the unpackaged pytest-benchmark. |
9571 | #:phases | |
05b7a593 EF |
9572 | (modify-phases %standard-phases |
9573 | (add-after 'unpack 'patch-hardcoded-version | |
9574 | (lambda _ (substitute* | |
9575 | "setup.py" | |
9576 | (("'gevent==1.1rc1'") "'gevent'")) | |
9577 | #t))))) | |
9578 | (native-inputs | |
9579 | `(("python-gevent" ,python-gevent) | |
9580 | ("python-mock" ,python-mock) | |
9581 | ("python-pytest-mock" ,python-pytest-mock))) | |
f22efa01 | 9582 | (propagated-inputs |
05b7a593 EF |
9583 | `(("python-promise" ,python-promise) |
9584 | ("python-six" ,python-six))) | |
9585 | (home-page "https://github.com/graphql-python/graphql-core") | |
9586 | (synopsis "GraphQL implementation for Python") | |
9587 | (description | |
9588 | "GraphQL implementation for Python. GraphQL is a data query language and | |
9589 | runtime designed and used to request and deliver data to mobile and web apps. | |
9590 | This library is a port of @url{https://github.com/graphql/graphql-js,graphql-js} | |
9591 | to Python.") | |
05b7a593 EF |
9592 | (license license:expat))) |
9593 | ||
9594 | (define-public python2-graphql-core | |
f210e944 | 9595 | (package-with-python2 python-graphql-core)) |
7ee51575 EF |
9596 | |
9597 | (define-public python-graphql-relay | |
9598 | (package | |
9599 | (name "python-graphql-relay") | |
b13a5b4d | 9600 | (version "0.4.5") |
7ee51575 EF |
9601 | (source |
9602 | (origin | |
9603 | (method url-fetch) | |
9604 | (uri (pypi-uri "graphql-relay" version)) | |
9605 | (sha256 | |
9606 | (base32 | |
b13a5b4d | 9607 | "1nv5dxcj59zv31qvl8bd142njmxcmymny2dz3br1l2cpbljbf5i7")))) |
7ee51575 EF |
9608 | (build-system python-build-system) |
9609 | (native-inputs | |
9610 | `(("python-pytest" ,python-pytest))) | |
f22efa01 | 9611 | (propagated-inputs |
7ee51575 EF |
9612 | `(("python-graphql-core" ,python-graphql-core) |
9613 | ("python-promise" ,python-promise) | |
9614 | ("python-six" ,python-six))) | |
9615 | (home-page "https://github.com/graphql-python/graphql-relay-py") | |
9616 | (synopsis "Relay implementation for Python") | |
9617 | (description | |
9618 | "This is a library to allow the easy creation of Relay-compliant servers | |
9619 | using the GraphQL Python reference implementation of a GraphQL server. It | |
9620 | should be noted that the code is a exact port of the original | |
9621 | @url{https://github.com/graphql/graphql-relay-js,graphql-relay js implementation} | |
9622 | from Facebook.") | |
7ee51575 EF |
9623 | (license license:expat))) |
9624 | ||
9625 | (define-public python2-graphql-relay | |
f210e944 | 9626 | (package-with-python2 python-graphql-relay)) |
ddc63a56 EF |
9627 | |
9628 | (define-public python-graphene | |
9629 | (package | |
9630 | (name "python-graphene") | |
9631 | (version "0.10.2") | |
9632 | (source | |
9633 | (origin | |
9634 | (method url-fetch) | |
9635 | (uri (pypi-uri "graphene" version)) | |
9636 | (sha256 | |
9637 | (base32 | |
9638 | "09zhac7igh9ixdz0ay6csy35b40l1jwbf2wrbxmgxwfhy51iy06q")))) | |
9639 | (build-system python-build-system) | |
f22efa01 | 9640 | (propagated-inputs |
ddc63a56 EF |
9641 | `(("python-graphql-core" ,python-graphql-core) |
9642 | ("python-graphql-relay" ,python-graphql-relay) | |
9643 | ("python-iso8601" ,python-iso8601) | |
9644 | ("python-promise" ,python-promise) | |
9645 | ("python-six" ,python-six))) | |
2b1b2799 TGR |
9646 | (arguments |
9647 | `(#:tests? #f)) ; no tests/ in the PyPI tarball | |
ddc63a56 EF |
9648 | (home-page "http://graphene-python.org/") |
9649 | (synopsis "GraphQL Framework for Python") | |
9650 | (description | |
9651 | "Graphene is a Python library for building GraphQL schemas/types. | |
9652 | A GraphQL schema describes your data model, and provides a GraphQL server | |
9653 | with an associated set of resolve methods that know how to fetch data.") | |
9654 | (properties `((python2-variant . ,(delay python2-graphene)))) | |
9655 | (license license:expat))) | |
9656 | ||
9657 | (define-public python2-graphene | |
9658 | (let ((base (package-with-python2 | |
9659 | (strip-python2-variant python-graphene)))) | |
9660 | (package (inherit base) | |
9661 | (native-inputs | |
00e10c6e | 9662 | `(("python2-sqlalchemy" ,python2-sqlalchemy) |
ddc63a56 | 9663 | ,@(package-native-inputs base)))))) |
d488d5d6 EF |
9664 | |
9665 | (define-public python-nautilus | |
9666 | (package | |
9667 | (name "python-nautilus") | |
9668 | (version "0.4.9") | |
9669 | (source | |
9670 | (origin | |
9671 | (method url-fetch) | |
9672 | (uri (pypi-uri "nautilus" version)) | |
9673 | (sha256 | |
9674 | (base32 | |
9675 | "01hwzjc1zshk4vvxrcghm398fpy4jls66dyz06g07mrwqif8878p")))) | |
9676 | (build-system python-build-system) | |
9677 | (arguments `(#:tests? #f)) ; fails to import test modules | |
f22efa01 | 9678 | (propagated-inputs |
d488d5d6 EF |
9679 | `(("python-bcrypt" ,python-bcrypt) |
9680 | ("python-click" ,python-click) | |
9681 | ("python-consul" ,python-consul) | |
d488d5d6 EF |
9682 | ("python-graphene" ,python-graphene) |
9683 | ("python-jinja2" ,python-jinja2) | |
d488d5d6 EF |
9684 | ("python-peewee" ,python-peewee) |
9685 | ("python-pika" ,python-pika) | |
d488d5d6 EF |
9686 | ("python-tornado" ,python-tornado) |
9687 | ("python-wtforms" ,python-wtforms))) | |
38ceb106 HG |
9688 | (native-inputs |
9689 | `(("python-nose2" ,python-nose2))) | |
d488d5d6 EF |
9690 | (home-page "https://github.com/AlecAivazis/nautilus") |
9691 | (synopsis "Library for creating microservice applications") | |
9692 | (description | |
9693 | "Nautilus is a framework for flux based microservices that looks to | |
9694 | provide extendible implementations of common aspects of a cloud so that you can | |
9695 | focus on building massively scalable web applications.") | |
9696 | (license license:expat))) | |
94cffc63 | 9697 | |
89cd988b DM |
9698 | (define-public python-snowballstemmer |
9699 | (package | |
9700 | (name "python-snowballstemmer") | |
9701 | (version "1.2.1") | |
9702 | (source (origin | |
1bd858cc MB |
9703 | (method url-fetch) |
9704 | (uri (pypi-uri "snowballstemmer" version)) | |
9705 | (sha256 | |
9706 | (base32 | |
9707 | "0a0idq4y5frv7qsg2x62jd7rd272749xk4x99misf5rcifk2d7wi")))) | |
89cd988b DM |
9708 | (build-system python-build-system) |
9709 | (arguments | |
9710 | `(;; No tests exist | |
9711 | #:tests? #f)) | |
9712 | (home-page "https://github.com/shibukawa/snowball_py") | |
9713 | (synopsis "Snowball stemming library collection for Python") | |
9714 | (description "This package provides 16 word stemmer algorithms generated | |
9715 | from Snowball algorithms. It includes the 15 original ones plus the Poerter | |
9716 | English stemmer.") | |
9717 | (license license:bsd-3))) | |
9718 | ||
9719 | (define-public python2-snowballstemmer | |
9720 | (package-with-python2 python-snowballstemmer)) | |
9721 | ||
754bfd70 DM |
9722 | (define-public python-sphinx-cloud-sptheme |
9723 | (package | |
9724 | (name "python-sphinx-cloud-sptheme") | |
5095bc7d | 9725 | (version "1.8.0") |
754bfd70 | 9726 | (source (origin |
1bd858cc MB |
9727 | (method url-fetch) |
9728 | (uri (pypi-uri "cloud_sptheme" version)) | |
9729 | (sha256 | |
9730 | (base32 | |
5095bc7d | 9731 | "1dniqb6a39yh786f86c4jn666rwnyi1jvzn4616zhcchb7sfdshd")))) |
1bd858cc | 9732 | (build-system python-build-system) |
a31e2f1a MB |
9733 | ;; FIXME: The 'pypi' release archive does not contain tests. |
9734 | (arguments '(#:tests? #f)) | |
1bd858cc MB |
9735 | (native-inputs |
9736 | `(("python-sphinx" ,python-sphinx))) | |
9737 | (home-page "https://bitbucket.org/ecollins/cloud_sptheme") | |
9738 | (synopsis "'Cloud' theme for Sphinx documenter") | |
9739 | (description "This package contains the \"Cloud\" theme for Sphinx and some | |
754bfd70 | 9740 | related extensions.") |
1bd858cc | 9741 | (license license:bsd-3))) |
754bfd70 DM |
9742 | |
9743 | (define-public python2-sphinx-cloud-sptheme | |
9744 | (package-with-python2 python-sphinx-cloud-sptheme)) | |
9745 | ||
807a5b32 DM |
9746 | (define-public python-sphinx-alabaster-theme |
9747 | (package | |
9748 | (name "python-sphinx-alabaster-theme") | |
9749 | (version "0.7.9") | |
1bd858cc MB |
9750 | (source (origin |
9751 | (method url-fetch) | |
9752 | (uri (pypi-uri "alabaster" version)) | |
9753 | (sha256 | |
9754 | (base32 | |
9755 | "027anxzcb951gjlcc43y3rbn9qrw36d16vj9wd2smv5410xx9bs7")))) | |
807a5b32 DM |
9756 | (build-system python-build-system) |
9757 | (propagated-inputs | |
9758 | `(("python-pygments" ,python-pygments))) | |
9759 | (home-page "https://alabaster.readthedocs.io/") | |
9760 | (synopsis "Configurable sidebar-enabled Sphinx theme") | |
9761 | (description "Alabaster is a visually (c)lean, responsive, configurable | |
9762 | theme for the Sphinx documentation system. It's the default theme of Sphinx.") | |
9763 | (license license:bsd-3))) | |
9764 | ||
9765 | (define-public python2-sphinx-alabaster-theme | |
9766 | (package-with-python2 python-sphinx-alabaster-theme)) | |
9767 | ||
8ab59181 HG |
9768 | (define-public python-setproctitle |
9769 | (package | |
9770 | (name "python-setproctitle") | |
9771 | (version "1.1.10") | |
9772 | (source | |
9773 | (origin | |
9774 | (method url-fetch) | |
9775 | (uri (pypi-uri "setproctitle" version)) | |
9776 | (sha256 | |
9777 | (base32 | |
9778 | "163kplw9dcrw0lffq1bvli5yws3rngpnvrxrzdw89pbphjjvg0v2")))) | |
9779 | (build-system python-build-system) | |
9780 | (arguments | |
9781 | '(#:phases | |
9782 | (modify-phases %standard-phases | |
9783 | (add-before 'check 'patch-Makefile | |
9784 | ;; Stricly this is only required for the python2 variant. | |
9785 | ;; But adding a phase in an inherited package seems to be | |
9786 | ;; cumbersum. So we patch even for python3. | |
9787 | (lambda _ | |
9788 | (let ((nose (assoc-ref %build-inputs "python2-nose"))) | |
9789 | (when nose | |
9790 | (substitute* "Makefile" | |
9791 | (("\\$\\(PYTHON\\) [^ ]which nosetests[^ ] ") | |
9792 | (string-append nose "/bin/nosetests ")))) | |
9793 | #t))) | |
9794 | (replace 'check | |
9795 | (lambda _ | |
9796 | (setenv "PYTHON" (or (which "python3") (which "python"))) | |
9797 | (setenv "PYCONFIG" (or (which "python3-config") | |
9798 | (which "python-config"))) | |
9799 | (setenv "CC" "gcc") | |
9800 | ;; No need to extend PYTHONPATH to find the built package, since | |
9801 | ;; the Makefile will build anyway | |
9802 | (zero? (system* "make" "check"))))))) | |
9803 | (native-inputs | |
9804 | `(("procps" ,procps))) ; required for tests | |
9805 | (home-page | |
9806 | "https://github.com/dvarrazzo/py-setproctitle") | |
9807 | (synopsis | |
9808 | "Setproctitle implementation for Python to customize the process title") | |
9809 | (description "The library allows a process to change its title (as displayed | |
9810 | by system tools such as ps and top). | |
9811 | ||
9812 | Changing the title is mostly useful in multi-process systems, for | |
9813 | example when a master process is forked: changing the children's title | |
9814 | allows to identify the task each process is busy with. The technique | |
9815 | is used by PostgreSQL and the OpenSSH Server for example.") | |
9816 | (license license:bsd-3) | |
9817 | (properties `((python2-variant . ,(delay python2-setproctitle)))))) | |
9818 | ||
9819 | (define-public python2-setproctitle | |
9820 | (let ((base (package-with-python2 | |
9821 | (strip-python2-variant python-setproctitle)))) | |
9822 | (package | |
9823 | (inherit base) | |
9824 | (native-inputs `(("python2-nose" ,python2-nose) | |
9825 | ,@(package-native-inputs base)))))) | |
162e42d8 HG |
9826 | |
9827 | (define-public python-validictory | |
9828 | (package | |
9829 | (name "python-validictory") | |
9830 | (version "1.0.1") | |
9831 | (source | |
9832 | (origin | |
9833 | (method url-fetch) | |
9834 | (uri (pypi-uri "validictory" version)) | |
9835 | (sha256 | |
9836 | (base32 | |
9837 | "1zf1g9sw47xzp5f80bd94pb42j9yqv82lcrgcvdwr6nkaphfi37q")))) | |
9838 | (build-system python-build-system) | |
9839 | (arguments | |
9840 | '(#:phases | |
9841 | (modify-phases %standard-phases | |
9842 | (add-after 'unpack 'bootstrap | |
9843 | ;; Move the tests out of the package directory to avoid | |
9844 | ;; packaging them. | |
9845 | (lambda* _ | |
9846 | (rename-file "validictory/tests" "tests") | |
9847 | (delete-file "tests/__init__.py"))) | |
9848 | (replace 'check | |
9849 | (lambda _ | |
9850 | ;; Extend PYTHONPATH so the built package will be found. | |
9851 | (setenv "PYTHONPATH" | |
9852 | (string-append (getcwd) "/build/lib:" | |
9853 | (getenv "PYTHONPATH"))) | |
9854 | (zero? (system* "py.test" "-vv" ))))))) | |
9855 | (native-inputs | |
9856 | `(("python-pytest" ,python-pytest))) | |
9857 | (home-page | |
1b2f753d LC |
9858 | "https://github.com/jamesturk/validictory") |
9859 | (synopsis "General purpose Python data validator") | |
9860 | (description "It allows validation of arbitrary Python data structures. | |
31288222 | 9861 | |
1b2f753d LC |
9862 | The schema format is based on the JSON Schema |
9863 | proposal (http://json-schema.org), so combined with json the library is also | |
9864 | useful as a validator for JSON data.") | |
9865 | (license license:expat))) | |
9866 | ||
9867 | (define-public python2-validictory | |
9868 | (package-with-python2 python-validictory)) | |
903276d0 | 9869 | |
329b4b3b LF |
9870 | (define-public python-pyev |
9871 | (package | |
9872 | (name "python-pyev") | |
9873 | (version "0.9.0") | |
9874 | (source | |
9875 | (origin | |
9876 | (method url-fetch) | |
9877 | (uri (pypi-uri "pyev" version)) | |
9878 | (sha256 | |
9879 | (base32 | |
9880 | "0rf603lc0s6zpa1nb25vhd8g4y337wg2wyz56i0agsdh7jchl0sx")))) | |
9881 | (build-system python-build-system) | |
9882 | (arguments | |
9883 | `(#:tests? #f ; no test suite | |
9884 | #:phases | |
9885 | (modify-phases %standard-phases | |
9886 | (add-after 'unpack 'patch | |
9887 | (lambda* (#:key inputs #:allow-other-keys) | |
9888 | (let ((libev (string-append (assoc-ref inputs "libev") | |
9889 | "/lib/libev.so.4"))) | |
9890 | (substitute* "setup.py" | |
9891 | (("libev_dll_name = find_library\\(\\\"ev\\\"\\)") | |
9892 | (string-append "libev_dll_name = \"" libev "\""))))))))) | |
9893 | (inputs | |
9894 | `(("libev" ,libev))) | |
9895 | (home-page "http://pythonhosted.org/pyev/") | |
9896 | (synopsis "Python libev interface") | |
9897 | (description "Pyev provides a Python interface to libev.") | |
9898 | (license license:gpl3))) | |
9899 | ||
9900 | (define-public python2-pyev | |
9901 | (package-with-python2 python-pyev)) | |
45b4f127 DM |
9902 | |
9903 | (define-public python-imagesize | |
9904 | (package | |
9905 | (name "python-imagesize") | |
9906 | (version "0.7.1") | |
9907 | (source | |
9908 | (origin | |
9909 | (method url-fetch) | |
9910 | (uri (pypi-uri "imagesize" version)) | |
9911 | (sha256 | |
9912 | (base32 | |
9913 | "0qk07k0z4241lkzzjji7z4da04pcvg7bfc4xz1934zlqhwmwdcha")))) | |
9914 | (build-system python-build-system) | |
9422c98a LF |
9915 | (arguments |
9916 | '(;; Test files are not distributed on PyPi: | |
9917 | ;; https://github.com/shibukawa/imagesize_py/issues/7 | |
9918 | #:tests? #f)) | |
45b4f127 DM |
9919 | (home-page "https://github.com/shibukawa/imagesize_py") |
9920 | (synopsis "Gets image size of files in variaous formats in Python") | |
9921 | (description | |
9922 | "This package allows determination of image size from | |
9923 | PNG, JPEG, JPEG2000 and GIF files in pure Python.") | |
f210e944 | 9924 | (license license:expat))) |
45b4f127 DM |
9925 | |
9926 | (define-public python2-imagesize | |
f210e944 | 9927 | (package-with-python2 python-imagesize)) |
2f6dd9cd | 9928 | |
e2fca490 DM |
9929 | (define-public python-termstyle |
9930 | (package | |
9931 | (name "python-termstyle") | |
9932 | (version "0.1.11") | |
9933 | (source | |
9934 | (origin | |
9935 | (method url-fetch) | |
9936 | (uri (pypi-uri "termstyle" version)) | |
9937 | (sha256 | |
9938 | (base32 | |
9939 | "17wzkkcqy5zc0g68xlad3kcv66iw14d2pwqc0h9420gak0vbhx7g")))) | |
9940 | (build-system python-build-system) | |
7917a135 MB |
9941 | (arguments |
9942 | '(#:phases | |
9943 | (modify-phases %standard-phases | |
9944 | (replace 'check | |
9945 | (lambda _ | |
9946 | (zero? (system* "python" "test3.py"))))))) | |
7bf837fd | 9947 | (home-page "https://github.com/gfxmonk/termstyle") |
e2fca490 DM |
9948 | (synopsis "Console text coloring for Python") |
9949 | (description "This package provides console text coloring for Python.") | |
9950 | (license license:bsd-3))) | |
1e6112d8 | 9951 | |
6c2e82bc TGR |
9952 | (define-public python-argcomplete |
9953 | (package | |
9954 | (name "python-argcomplete") | |
9955 | (version "1.7.0") | |
9956 | (source | |
9957 | (origin | |
9958 | (method url-fetch) | |
9959 | (uri (pypi-uri "argcomplete" version)) | |
9960 | (sha256 | |
9961 | (base32 | |
9962 | "11bwiw6j0nilgz81xnw6f1npyga3prp8asjqrm87cdr3ria5l03x")))) | |
9963 | (build-system python-build-system) | |
80ce42bd MB |
9964 | (native-inputs |
9965 | `(("python-pexpect" ,python-pexpect) | |
240d3cef LC |
9966 | ("tcsh" ,tcsh) |
9967 | ("bash-full" ,bash))) ;full Bash for 'test_file_completion' | |
6c2e82bc TGR |
9968 | (home-page "https://github.com/kislyuk/argcomplete") |
9969 | (synopsis "Shell tab completion for Python argparse") | |
9970 | (description "argcomplete provides extensible command line tab completion | |
9971 | of arguments and options for Python scripts using @code{argparse}. It's | |
9972 | particularly useful for programs with many options or sub-parsers that can | |
9973 | dynamically suggest completions; for example, when browsing resources over the | |
9974 | network.") | |
9975 | (license license:asl2.0))) | |
9976 | ||
9977 | (define-public python2-argcomplete | |
9978 | (package-with-python2 python-argcomplete)) | |
361a2fcf TGR |
9979 | |
9980 | (define-public python-xopen | |
9981 | (package | |
9982 | (name "python-xopen") | |
9983 | (version "0.1.1") | |
9984 | (source | |
9985 | (origin | |
9986 | (method url-fetch) | |
9987 | (uri (pypi-uri "xopen" version)) | |
9988 | (sha256 | |
9989 | (base32 | |
9990 | "1wx6mylzcsyhjl19ycb83qq6iqpmr927lz62njfsar6ldsj0qcni")) | |
9991 | (file-name (string-append name "-" version ".tar.gz")))) | |
9992 | (build-system python-build-system) | |
9993 | (home-page "https://github.com/marcelm/xopen/") | |
9994 | (synopsis "Open compressed files transparently") | |
9995 | (description "This module provides an @code{xopen} function that works like | |
9996 | Python's built-in @code{open} function, but can also deal with compressed files. | |
9997 | Supported compression formats are gzip, bzip2 and, xz, and are automatically | |
9998 | recognized by their file extensions. The focus is on being as efficient as | |
9999 | possible on all supported Python versions.") | |
10000 | (license license:expat))) | |
10001 | ||
10002 | (define-public python2-xopen | |
10003 | (package-with-python2 python-xopen)) | |
8d67610b DM |
10004 | |
10005 | (define-public python2-cheetah | |
10006 | (package | |
10007 | (name "python2-cheetah") | |
10008 | (version "2.4.4") | |
10009 | (source | |
10010 | (origin | |
10011 | (method url-fetch) | |
10012 | (uri (pypi-uri "Cheetah" version)) | |
10013 | (sha256 | |
10014 | (base32 | |
10015 | "0l5mm4lnysjkzpjr95q5ydm9xc8bv43fxmr79ypybrf1y0lq4c5y")))) | |
10016 | (build-system python-build-system) | |
10017 | (arguments | |
10018 | `(#:python ,python-2)) | |
10019 | (propagated-inputs | |
10020 | `(("python2-markdown" ,python2-markdown))) | |
10021 | (home-page "https://pythonhosted.org/Cheetah/") | |
10022 | (synopsis "Template engine") | |
10023 | (description "Cheetah is a text-based template engine and Python code | |
10024 | generator. | |
10025 | ||
10026 | Cheetah can be used as a standalone templating utility or referenced as | |
10027 | a library from other Python applications. It has many potential uses, | |
10028 | but web developers looking for a viable alternative to ASP, JSP, PHP and | |
10029 | PSP are expected to be its principle user group. | |
10030 | ||
10031 | Features: | |
10032 | @enumerate | |
10033 | @item Generates HTML, SGML, XML, SQL, Postscript, form email, LaTeX, or any other | |
10034 | text-based format. | |
10035 | @item Cleanly separates content, graphic design, and program code. | |
10036 | @item Blends the power and flexibility of Python with a simple template language | |
10037 | that non-programmers can understand. | |
10038 | @item Gives template writers full access to any Python data structure, module, | |
10039 | function, object, or method in their templates. | |
10040 | @item Makes code reuse easy by providing an object-orientated interface to | |
10041 | templates that is accessible from Python code or other Cheetah templates. | |
10042 | One template can subclass another and selectively reimplement sections of it. | |
10043 | @item Provides a simple, yet powerful, caching mechanism that can dramatically | |
10044 | improve the performance of a dynamic website. | |
10045 | @item Compiles templates into optimized, yet readable, Python code. | |
10046 | @end enumerate") | |
10047 | (license (license:x11-style "file://LICENSE")))) | |
916aafa4 | 10048 | |
d83d8722 DM |
10049 | (define-public python-dulwich |
10050 | (package | |
10051 | (name "python-dulwich") | |
bef02e9e | 10052 | (version "0.18.6") |
d83d8722 DM |
10053 | (source |
10054 | (origin | |
10055 | (method url-fetch) | |
10056 | (uri (list (string-append "https://www.dulwich.io/releases/" | |
10057 | "dulwich-" version ".tar.gz") | |
10058 | (pypi-uri "dulwich" version))) | |
10059 | (sha256 | |
bef02e9e LF |
10060 | (base32 |
10061 | "1aa1xfrxkc3j9s4xi0llhf5gndyi9ryprcxsqfa5fcb8ph34981q")))) | |
d83d8722 DM |
10062 | (build-system python-build-system) |
10063 | (arguments | |
10064 | `(#:phases | |
10065 | (modify-phases %standard-phases | |
10066 | (add-before 'check 'fix-tests | |
10067 | (lambda* (#:key inputs #:allow-other-keys) | |
10068 | ;; The tests use Popen with a custom environment which doesn't | |
10069 | ;; include PATH. | |
10070 | (substitute* "dulwich/tests/compat/utils.py" | |
10071 | (("'git'") (string-append "'" | |
10072 | (which "git") | |
10073 | "'"))) | |
10074 | (substitute* '("dulwich/tests/test_repository.py" | |
10075 | "dulwich/tests/test_hooks.py") | |
10076 | (("#!/bin/sh") (string-append "#!" (which "sh")))) | |
10077 | (setenv "TEST_RUNNER" "unittest") | |
10078 | (setenv "PYTHONHASHSEED" "random") | |
10079 | #t))))) | |
10080 | (propagated-inputs | |
10081 | `(("python-fastimport" ,python-fastimport))) | |
10082 | (native-inputs | |
10083 | `(("python-mock" ,python-mock) | |
10084 | ("python-geventhttpclient" ,python-geventhttpclient) | |
10085 | ("git" ,git))) | |
10086 | (home-page "https://www.dulwich.io/") | |
10087 | (synopsis "Git implementation in Python") | |
10088 | (description "Dulwich is an implementation of the Git file formats and | |
10089 | protocols written in pure Python.") | |
10090 | ;; Can be used with either license. | |
10091 | (license (list license:asl2.0 license:gpl2+)))) | |
10092 | ||
10093 | (define-public python2-dulwich | |
10094 | (package-with-python2 python-dulwich)) | |
424b1ae7 | 10095 | |
916aafa4 CZ |
10096 | (define-public python-pbkdf2 |
10097 | (package | |
10098 | (name "python-pbkdf2") | |
10099 | (version "1.3") | |
10100 | (source | |
10101 | (origin | |
10102 | (method url-fetch) | |
10103 | (uri (pypi-uri "pbkdf2" version)) | |
10104 | (sha256 | |
10105 | (base32 | |
10106 | "0yb99rl2mbsaamj571s1mf6vgniqh23v98k4632150hjkwv9fqxc")))) | |
10107 | (build-system python-build-system) | |
fffcd8b8 MB |
10108 | (arguments |
10109 | '(#:phases | |
10110 | (modify-phases %standard-phases | |
10111 | (replace 'check | |
10112 | (lambda _ | |
10113 | (setenv "PYTHONPATH" | |
10114 | (string-append (getcwd) "/build/lib:" | |
10115 | (getenv "PYTHONPATH"))) | |
10116 | (zero? (system* "python" "test/test_pbkdf2.py"))))))) | |
916aafa4 CZ |
10117 | (propagated-inputs |
10118 | `(("python-pycrypto" ,python-pycrypto))) ; optional | |
9be5ecdf | 10119 | (home-page "https://www.dlitz.net/software/python-pbkdf2/") |
916aafa4 CZ |
10120 | (synopsis "Password-based key derivation") |
10121 | (description "This module implements the password-based key derivation | |
10122 | function, PBKDF2, specified in RSA PKCS#5 v2.0. | |
10123 | ||
10124 | PKCS#5 v2.0 Password-Based Key Derivation is a key derivation function which | |
10125 | is part of the RSA Public Key Cryptography Standards series. The provided | |
10126 | implementation takes a password or a passphrase and a salt value (and | |
10127 | optionally a iteration count, a digest module, and a MAC module) and provides | |
10128 | a file-like object from which an arbitrarly-sized key can be read.") | |
10129 | (license license:expat))) | |
10130 | ||
10131 | (define-public python2-pbkdf2 | |
10132 | (package-with-python2 python-pbkdf2)) | |
cba84a38 CZ |
10133 | |
10134 | (define-public python-qrcode | |
10135 | (package | |
10136 | (name "python-qrcode") | |
10137 | (version "5.3") | |
10138 | (source | |
10139 | (origin | |
10140 | (method url-fetch) | |
10141 | (uri (pypi-uri "qrcode" version)) | |
10142 | (sha256 | |
10143 | (base32 | |
10144 | "0kljfrfq0c2rmxf8am57333ia41kd0snbm2rnqbdy816hgpcq5a1")))) | |
10145 | (build-system python-build-system) | |
6925cd78 MB |
10146 | (arguments |
10147 | ;; FIXME: Tests require packaging 'pymaging'. | |
10148 | '(#:tests? #f)) | |
cba84a38 CZ |
10149 | (propagated-inputs |
10150 | `(("python-lxml" ,python-lxml) ; for SVG output | |
10151 | ("python-pillow" ,python-pillow) ; for PNG output | |
10152 | ("python-six" ,python-six))) | |
10153 | (home-page "https://github.com/lincolnloop/python-qrcode") | |
10154 | (synopsis "QR Code image generator") | |
10155 | (description "This package provides a pure Python QR Code generator | |
10156 | module. It uses the Python Imaging Library (PIL) to allow for the generation | |
10157 | of QR Codes. | |
10158 | ||
10159 | In addition this package provides a command line tool to generate QR codes and | |
10160 | either write these QR codes to a file or do the output as ascii art at the | |
10161 | console.") | |
10162 | (license license:bsd-3))) | |
10163 | ||
10164 | (define-public python2-qrcode | |
10165 | (package-with-python2 python-qrcode)) | |
af7caada | 10166 | |
1a917fc9 MFM |
10167 | (define-public python-rst2ansi |
10168 | (package | |
10169 | (name "python-rst2ansi") | |
10170 | (version "0.1.5") | |
10171 | (source | |
10172 | (origin | |
10173 | (method url-fetch) | |
10174 | (uri (pypi-uri "rst2ansi" version)) | |
10175 | (sha256 | |
10176 | (base32 | |
10177 | "0vzy6gd60l79ff750scl0sz48r1laalkl6md6dwzah4dcadgn5qv")))) | |
10178 | (build-system python-build-system) | |
10179 | (propagated-inputs | |
10180 | `(("python-docutils" ,python-docutils))) | |
10181 | (home-page "https://github.com/Snaipe/python-rst-to-ansi") | |
10182 | (synopsis "Convert RST to ANSI-decorated console output") | |
10183 | (description | |
10184 | "Python module dedicated to rendering RST (reStructuredText) documents | |
10185 | to ansi-escaped strings suitable for display in a terminal.") | |
10186 | (license license:expat))) | |
2f4623db | 10187 | |
ca0e62bf SR |
10188 | (define-public python-ansi2html |
10189 | (package | |
10190 | (name "python-ansi2html") | |
10191 | (version "1.2.0") | |
10192 | (source | |
10193 | (origin | |
10194 | (method url-fetch) | |
10195 | (uri (pypi-uri "ansi2html" version)) | |
10196 | (sha256 | |
10197 | (base32 | |
10198 | "1wa00zffprb78w1mqq90dk47czz1knanys2a40zbw2vyapd5lp9y")))) | |
10199 | (build-system python-build-system) | |
10200 | (native-inputs | |
10201 | `(("python-mock" ,python-mock) | |
10202 | ("python-nose" ,python-nose))) | |
10203 | (propagated-inputs | |
10204 | `(("python-six" ,python-six))) | |
9be5ecdf | 10205 | (home-page "https://github.com/ralphbean/ansi2html") |
ca0e62bf SR |
10206 | (synopsis "Convert ANSI-decorated console output to HTML") |
10207 | (description | |
10208 | "@command{ansi2html} is a Python library and command line utility for | |
10209 | convering text with ANSI color codes to HTML or LaTeX.") | |
10210 | (license license:gpl3+))) | |
10211 | ||
10212 | (define-public python2-ansi2html | |
10213 | (package-with-python2 python-ansi2html)) | |
10214 | ||
2f4623db MFM |
10215 | (define-public python-ddt |
10216 | (package | |
10217 | (name "python-ddt") | |
10218 | (version "1.1.1") | |
10219 | (source | |
10220 | (origin | |
10221 | (method url-fetch) | |
10222 | (uri (pypi-uri "ddt" version)) | |
10223 | (sha256 | |
10224 | (base32 | |
10225 | "1c00ikkxr7lha97c81k938bzhgd4pbwamkjn0h4nkhr3xk00zp6n")))) | |
10226 | (build-system python-build-system) | |
10227 | (native-inputs | |
10228 | `(("python-mock" ,python-mock) | |
10229 | ("python-nose" ,python-nose))) | |
10230 | (propagated-inputs | |
10231 | `(("python-six" ,python-six) | |
10232 | ("python-pyyaml" ,python-pyyaml))) | |
10233 | (home-page "https://github.com/txels/ddt") | |
10234 | (synopsis "Data-Driven Tests") | |
10235 | (description | |
10236 | "DDT (Data-Driven Tests) allows you to multiply one test case by running | |
10237 | it with different test data, and make it appear as multiple test cases.") | |
10238 | (license license:expat))) | |
10239 | ||
10240 | (define-public python2-ddt | |
10241 | (package-with-python2 python-ddt)) | |
2299b137 MFM |
10242 | |
10243 | (define-public python-pycosat | |
10244 | (package | |
10245 | (name "python-pycosat") | |
10246 | (version "0.6.1") | |
10247 | (source | |
10248 | (origin | |
10249 | (method url-fetch) | |
10250 | (uri (pypi-uri "pycosat" version)) | |
10251 | (sha256 | |
10252 | (base32 | |
10253 | "1kl3wh1f47rc712n4bmwplbx3fqz3x9i1b587jrbpmvdva4c8f6l")))) | |
10254 | ;; TODO: Unundle picosat. http://fmv.jku.at/picosat/ | |
10255 | (build-system python-build-system) | |
10256 | (home-page "https://github.com/ContinuumIO/pycosat") | |
10257 | (synopsis "Bindings to picosat (a SAT solver)") | |
10258 | (description | |
10259 | "This package provides efficient Python bindings to @code{picosat} on | |
10260 | the C level. When importing pycosat, the @code{picosat} solver becomes part | |
10261 | of the Python process itself. @code{picosat} is a @dfn{Boolean Satisfiability | |
10262 | Problem} (SAT) solver.") | |
10263 | (license license:expat))) | |
10264 | ||
10265 | (define-public python2-pycosat | |
10266 | (package-with-python2 python-pycosat)) | |
8fd68504 MFM |
10267 | |
10268 | (define-public python2-ruamel.ordereddict | |
10269 | (package | |
10270 | (name "python2-ruamel.ordereddict") | |
10271 | (version "0.4.9") | |
10272 | (source | |
10273 | (origin | |
10274 | (method url-fetch) | |
10275 | (uri (pypi-uri "ruamel.ordereddict" version)) | |
10276 | (sha256 | |
10277 | (base32 | |
10278 | "1xmkl8v9l9inm2pyxgc1fm5005yxm7fkd5gv74q7lj1iy5qc8n3h")))) | |
10279 | (build-system python-build-system) | |
10280 | (arguments | |
10281 | `(#:python ,python-2 | |
10282 | #:phases | |
10283 | (modify-phases %standard-phases | |
10284 | (delete 'check) | |
10285 | (add-after 'install 'check | |
10286 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
10287 | (add-installed-pythonpath inputs outputs) | |
10288 | (zero? (system* "python" "test/testordereddict.py"))))))) | |
10289 | (home-page "https://bitbucket.org/ruamel/ordereddict") | |
10290 | (synopsis "Version of dict that keeps keys in insertion order") | |
10291 | (description | |
10292 | "This is an implementation of an ordered dictionary with @dfn{Key | |
10293 | Insertion Order} (KIO: updates of values do not affect the position of the | |
10294 | key), @dfn{Key Value Insertion Order} (KVIO, an existing key's position is | |
10295 | removed and put at the back). The standard library module @code{OrderedDict}, | |
10296 | implemented later, implements a subset of @code{ordereddict} functionality. | |
10297 | Sorted dictionaries are also provided. Currently only with @dfn{Key Sorted | |
10298 | Order} (KSO, no sorting function can be specified, but a transform can be | |
10299 | specified to apply on the key before comparison (e.g. @code{string.lower})).") | |
10300 | (license license:expat))) | |
d8768e31 EB |
10301 | |
10302 | (define-public python-pypeg2 | |
10303 | (package | |
10304 | (name "python-pypeg2") | |
10305 | (version "2.15.2") | |
10306 | (source | |
10307 | (origin | |
10308 | (method url-fetch) | |
10309 | (uri (pypi-uri "pyPEG2" version)) | |
10310 | (sha256 | |
10311 | (base32 | |
10312 | "0v8ziaam2r637v94ra4dbjw6jzxz99gs5x4i585kgag1v204yb9b")))) | |
10313 | (build-system python-build-system) | |
10314 | (propagated-inputs `(("python-lxml" ,python-lxml))) | |
10315 | (arguments | |
10316 | ;;https://bitbucket.org/fdik/pypeg/issues/36/test-failures-on-py35 | |
10317 | '(#:tests? #f)) | |
10318 | (home-page "https://fdik.org/pyPEG/") | |
10319 | (synopsis "Parsering Expression Grammars in Python") | |
10320 | (description "PyPEG is an intrinsic parser interpreter framework for | |
10321 | Python. It is based on Parsing Expression Grammars, PEG. With pyPEG you can | |
10322 | parse many formal languages.") | |
10323 | (license license:gpl2))) | |
33e9490c | 10324 | |
0cd83b4e TS |
10325 | (define-public python-incremental |
10326 | (package | |
10327 | (name "python-incremental") | |
10328 | (version "17.5.0") | |
10329 | (source | |
10330 | (origin | |
10331 | (method url-fetch) | |
10332 | (uri (pypi-uri "incremental" version)) | |
10333 | (sha256 | |
10334 | (base32 | |
10335 | "1cylxdz1cnkm5g3pklna3h2n0i0rks95ir1pnpxfnvpkmab1cxbv")))) | |
10336 | (build-system python-build-system) | |
10337 | (home-page "https://github.com/hawkowl/incremental") | |
10338 | (synopsis "Library for versioning Python projects") | |
10339 | (description "Incremental is a small library that versions your Python | |
10340 | projects.") | |
10341 | (license license:expat))) | |
10342 | ||
10343 | (define-public python2-incremental | |
10344 | (package-with-python2 python-incremental)) | |
10345 | ||
96cb5ca1 TS |
10346 | (define-public python-automat |
10347 | (package | |
10348 | (name "python-automat") | |
10349 | (version "0.6.0") | |
10350 | (source (origin | |
10351 | (method url-fetch) | |
10352 | (uri (pypi-uri "Automat" version)) | |
10353 | (sha256 | |
10354 | (base32 | |
10355 | "1a7nsrljysfmdqmpn2apfa1gg6rfah4y9sizvns8gb08rx7d07rw")))) | |
10356 | (build-system python-build-system) | |
10357 | ;; We disable the tests because they require python-twisted, while | |
10358 | ;; python-twisted depends on python-automat. Twisted is optional, but the | |
10359 | ;; tests fail if it is not available. Also see | |
10360 | ;; <https://github.com/glyph/automat/issues/71>. | |
10361 | (arguments '(#:tests? #f)) | |
10362 | (native-inputs | |
10363 | `(("python-m2r" ,python-m2r) | |
10364 | ("python-setuptools-scm" ,python-setuptools-scm) | |
10365 | ("python-graphviz" ,python-graphviz))) | |
10366 | (propagated-inputs | |
10367 | `(("python-six" ,python-six) | |
10368 | ("python-attrs" ,python-attrs))) | |
10369 | (home-page "https://github.com/glyph/Automat") | |
10370 | (synopsis "Self-service finite-state machines") | |
10371 | (description "Automat is a library for concise, idiomatic Python | |
10372 | expression of finite-state automata (particularly deterministic finite-state | |
10373 | transducers).") | |
10374 | (license license:expat))) | |
10375 | ||
10376 | (define-public python2-automat | |
10377 | (package-with-python2 python-automat)) | |
10378 | ||
fd8ff99a TS |
10379 | (define-public python-m2r |
10380 | (package | |
10381 | (name "python-m2r") | |
10382 | (version "0.1.12") | |
10383 | (source (origin | |
10384 | (method url-fetch) | |
10385 | (uri (pypi-uri "m2r" version)) | |
10386 | (sha256 | |
10387 | (base32 | |
10388 | "1axrwnf425sz4qz3c0qc7yhhki4myzb8rki7pczcsgzznzmqdyxd")))) | |
10389 | (build-system python-build-system) | |
10390 | (propagated-inputs | |
10391 | `(("python-docutils" ,python-docutils) | |
10392 | ("python-mistune" ,python-mistune))) | |
10393 | (native-inputs | |
10394 | `(("python-pygments" ,python-pygments) | |
10395 | ("python-mock" ,python-mock))) | |
10396 | (home-page "https://github.com/miyakogi/m2r") | |
10397 | (synopsis "Markdown to reStructuredText converter") | |
10398 | (description "M2R converts a markdown file including reST markups to valid | |
10399 | reST format.") | |
10400 | (license license:expat))) | |
10401 | ||
10402 | (define-public python2-m2r | |
10403 | (package-with-python2 python-m2r)) | |
10404 | ||
9074bac1 TS |
10405 | (define-public python-constantly |
10406 | (package | |
10407 | (name "python-constantly") | |
10408 | (version "15.1.0") | |
10409 | (source (origin | |
10410 | (method url-fetch) | |
10411 | (uri (pypi-uri "constantly" version)) | |
10412 | (sha256 | |
10413 | (base32 | |
10414 | "0dgwdla5kfpqz83hfril716inm41hgn9skxskvi77605jbmp4qsq")))) | |
10415 | (build-system python-build-system) | |
10416 | (home-page "https://github.com/twisted/constantly") | |
10417 | (synopsis "Symbolic constants in Python") | |
10418 | (description "Constantly is a Python library that provides symbolic | |
10419 | constant support. It includes collections and constants with text, numeric, | |
10420 | and bit flag values.") | |
10421 | (license license:expat))) | |
10422 | ||
10423 | (define-public python2-constantly | |
10424 | (package-with-python2 python-constantly)) | |
10425 | ||
bb3b4b4e TS |
10426 | (define-public python-attrs |
10427 | (package | |
10428 | (name "python-attrs") | |
10429 | (version "17.2.0") | |
10430 | (source (origin | |
10431 | (method url-fetch) | |
10432 | (uri (pypi-uri "attrs" version)) | |
10433 | (sha256 | |
10434 | (base32 | |
10435 | "04gx08ikpk26wnq22f7l42gapcvk8iz1512r927k6sadz6cinkax")))) | |
10436 | (build-system python-build-system) | |
10437 | (native-inputs | |
10438 | `(("python-pytest" ,python-pytest) | |
10439 | ("python-hypothesis" ,python-hypothesis) | |
10440 | ("python-zope-interface" ,python-zope-interface) | |
10441 | ("python-six" ,python-six))) | |
10442 | (home-page "https://github.com/python-attrs/attrs/") | |
10443 | (synopsis "Attributes without boilerplate") | |
10444 | (description "@code{attrs} is a Python package with class decorators that | |
10445 | ease the chores of implementing the most common attribute-related object | |
10446 | protocols.") | |
10447 | (license license:expat))) | |
10448 | ||
10449 | (define-public python2-attrs | |
10450 | (package-with-python2 python-attrs)) | |
10451 | ||
33e9490c AI |
10452 | (define-public python2-cliapp |
10453 | (package | |
10454 | (name "python2-cliapp") | |
f6c58215 | 10455 | (version "1.20170823") |
33e9490c AI |
10456 | (source |
10457 | (origin | |
10458 | (method url-fetch) | |
10459 | (uri (string-append | |
10460 | "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/cliapp/snapshot/cliapp-" | |
10461 | version ".tar.gz")) | |
10462 | (sha256 | |
10463 | (base32 | |
f6c58215 | 10464 | "1i9gik0xrj6jmi95s5w988jl1y265baz5xm5pbqdyvsh8h9ln6yq")))) |
33e9490c AI |
10465 | (build-system python-build-system) |
10466 | (arguments | |
689042e5 AI |
10467 | `(#:python ,python-2 |
10468 | #:phases | |
10469 | (modify-phases %standard-phases | |
10470 | ;; check phase needs to be run before the build phase. If not, | |
10471 | ;; coverage-test-runner looks for tests for the built source files, | |
10472 | ;; and fails. | |
10473 | (delete 'check) | |
10474 | (add-before 'build 'check | |
10475 | (lambda _ | |
10476 | ;; Disable python3 tests | |
10477 | (substitute* "check" | |
10478 | (("python3") "# python3")) | |
10479 | (zero? (system* "./check"))))))) | |
10480 | (native-inputs | |
10481 | `(("python2-coverage-test-runner" ,python2-coverage-test-runner) | |
10482 | ("python2-pep8" ,python2-pep8))) | |
33e9490c AI |
10483 | (propagated-inputs |
10484 | `(("python2-pyaml" ,python2-pyaml))) | |
10485 | (home-page "https://liw.fi/cliapp/") | |
10486 | (synopsis "Python framework for command line programs") | |
10487 | (description "@code{python2-cliapp} is a python framework for | |
10488 | command line programs. It contains the typical stuff such programs | |
10489 | need to do, such as parsing the command line for options, and | |
10490 | iterating over input files.") | |
10491 | (license license:gpl2+))) | |
10492 | ||
77e99411 AI |
10493 | (define-public python2-ttystatus |
10494 | (package | |
10495 | (name "python2-ttystatus") | |
2d6da794 | 10496 | (version "0.35") |
77e99411 AI |
10497 | (source |
10498 | (origin | |
10499 | (method url-fetch) | |
10500 | (uri (string-append | |
10501 | "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/ttystatus/snapshot/ttystatus-" | |
10502 | version ".tar.gz")) | |
10503 | (sha256 | |
10504 | (base32 | |
2d6da794 | 10505 | "0vivqbw7ddhsq1zj3g9cvvv4f0phl0pis2smsnwcr2szz2fk3hl6")))) |
77e99411 | 10506 | (build-system python-build-system) |
f6180862 AI |
10507 | (native-inputs |
10508 | `(("python2-coverage-test-runner" ,python2-coverage-test-runner) | |
10509 | ("python2-pep8" ,python2-pep8))) | |
77e99411 | 10510 | (arguments |
f6180862 AI |
10511 | `(#:python ,python-2 |
10512 | #:phases | |
10513 | (modify-phases %standard-phases | |
10514 | ;; check phase needs to be run before the build phase. If not, | |
10515 | ;; coverage-test-runner looks for tests for the built source files, | |
10516 | ;; and fails. | |
10517 | (delete 'check) | |
10518 | (add-before 'build 'check | |
10519 | (lambda _ | |
10520 | (zero? (system* "make" "check"))))))) | |
77e99411 AI |
10521 | (home-page "https://liw.fi/ttystatus/") |
10522 | (synopsis "Python library for showing progress reporting and | |
10523 | status updates on terminals") | |
10524 | (description "@code{python2-ttystatus} is a python library for | |
10525 | showing progress reporting and status updates on terminals, for | |
10526 | command line programs. Output is automatically adapted to the width | |
10527 | of the terminal: truncated if it does not fit, and resized if the | |
10528 | terminal size changes.") | |
10529 | (license license:gpl3+))) | |
c220f0b4 AI |
10530 | |
10531 | (define-public python2-tracing | |
10532 | (package | |
10533 | (name "python2-tracing") | |
10534 | (version "0.10") | |
10535 | (source | |
10536 | (origin | |
10537 | (method url-fetch) | |
10538 | (uri (string-append | |
10539 | "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/python-tracing/snapshot/tracing-" | |
10540 | version ".tar.gz")) | |
10541 | (sha256 | |
10542 | (base32 | |
10543 | "06cw4zg42fsvqy372vi2whj26w56vzg5axhzwdjc2bgwf03garbw")))) | |
10544 | (build-system python-build-system) | |
10545 | (arguments | |
10546 | `(#:python ,python-2)) | |
10547 | (home-page "https://liw.fi/tracing/") | |
10548 | (synopsis "Python debug logging helper") | |
10549 | (description "@code{python2-tracing} is a python library for | |
10550 | logging debug messages. It provides a way to turn debugging messages | |
10551 | on and off, based on the filename they occur in. It is much faster | |
10552 | than using @code{logging.Filter} to accomplish the same thing, which | |
10553 | matters when code is run in production mode. The actual logging still | |
10554 | happens using the @code{logging} library.") | |
10555 | (license license:gpl3+))) | |
b6b2ca5d AI |
10556 | |
10557 | (define-public python2-larch | |
10558 | (package | |
10559 | (name "python2-larch") | |
10560 | (version "1.20151025") | |
10561 | (source | |
10562 | (origin | |
10563 | (method url-fetch) | |
10564 | (uri (string-append | |
10565 | "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/larch/snapshot/larch-" | |
10566 | version ".tar.gz")) | |
a0596a2f AI |
10567 | (patches (search-patches |
10568 | "python2-larch-coverage-4.0a6-compatibility.patch")) | |
b6b2ca5d AI |
10569 | (sha256 |
10570 | (base32 | |
10571 | "1p4knkkavlqymgciz2wbcnfrdgdbafhg14maplnk4vbw0q8xs663")))) | |
10572 | (build-system python-build-system) | |
10573 | (arguments | |
a0596a2f AI |
10574 | `(#:python ,python-2 |
10575 | #:phases | |
10576 | (modify-phases %standard-phases | |
10577 | ;; check phase needs to be run before the build phase. If not, | |
10578 | ;; coverage-test-runner looks for tests for the built source files, | |
10579 | ;; and fails. | |
10580 | (delete 'check) | |
10581 | (add-before 'build 'check | |
10582 | (lambda _ | |
10583 | (zero? (system* "make" "check"))))))) | |
10584 | (native-inputs | |
10585 | `(("cmdtest" ,cmdtest) | |
10586 | ("python2-coverage-test-runner" ,python2-coverage-test-runner))) | |
b6b2ca5d AI |
10587 | (propagated-inputs |
10588 | `(("python2-tracing" ,python2-tracing))) | |
10589 | (home-page "https://liw.fi/larch/") | |
10590 | (synopsis "Python copy-on-write B-tree library") | |
10591 | (description "@code{python2-larch} is an implementation of | |
10592 | particular kind of B-tree, based on research by Ohad Rodeh. See | |
10593 | @url{http://liw.fi/larch/ohad-btrees-shadowing-clones.pdf} for details | |
10594 | on the data structure. | |
10595 | ||
10596 | The distinctive feature of this B-tree is that a node is never | |
10597 | (conceptually) modified. Instead, all updates are done by | |
10598 | copy-on-write. This makes it easy to clone a tree, and modify only the | |
10599 | clone, while other processes access the original tree.") | |
10600 | (license license:gpl3+))) | |
35db2d3c | 10601 | |
d5ef113c AI |
10602 | (define-public python-astroid |
10603 | (package | |
10604 | (name "python-astroid") | |
de2f56cf | 10605 | (version "1.5.3") |
d5ef113c AI |
10606 | (source |
10607 | (origin | |
10608 | (method url-fetch) | |
10609 | (uri (string-append | |
10610 | "https://github.com/PyCQA/astroid/archive/astroid-" | |
10611 | version ".tar.gz")) | |
10612 | (sha256 | |
10613 | (base32 | |
de2f56cf | 10614 | "0isn5p7f9n48hmksgbrj7dkm9dyglnayzn5jngk37qywg8a74ngn")))) |
d5ef113c AI |
10615 | (build-system python-build-system) |
10616 | (propagated-inputs | |
10617 | `(("python-lazy-object-proxy" ,python-lazy-object-proxy) | |
10618 | ("python-six" ,python-six) | |
10619 | ("python-wrapt" ,python-wrapt))) | |
10620 | (arguments | |
10621 | `(#:phases | |
10622 | (modify-phases %standard-phases | |
10623 | (replace 'check | |
10624 | (lambda _ | |
10625 | (zero? (system* "python" "-m" "unittest" "discover" | |
10626 | "-p" "unittest*.py"))))))) | |
10627 | (home-page "https://github.com/PyCQA/astroid") | |
10628 | (synopsis "Common base representation of python source code for pylint and | |
10629 | other projects") | |
10630 | (description "@code{python-astroid} provides a common base representation | |
10631 | of python source code for projects such as pychecker, pyreverse, pylint, etc. | |
10632 | ||
10633 | It provides a compatible representation which comes from the _ast module. It | |
10634 | rebuilds the tree generated by the builtin _ast module by recursively walking | |
10635 | down the AST and building an extended ast. The new node classes have | |
10636 | additional methods and attributes for different usages. They include some | |
10637 | support for static inference and local name scopes. Furthermore, astroid | |
10638 | builds partial trees by inspecting living objects.") | |
de2f56cf MB |
10639 | (license license:lgpl2.1+) |
10640 | (properties `((python2-variant . ,(delay python2-astroid)))))) | |
d5ef113c AI |
10641 | |
10642 | (define-public python2-astroid | |
de2f56cf MB |
10643 | (let ((base (package-with-python2 |
10644 | (strip-python2-variant python-astroid)))) | |
10645 | (package (inherit base) | |
10646 | (propagated-inputs | |
10647 | `(("python2-backports-functools-lru-cache" | |
10648 | ,python2-backports-functools-lru-cache) | |
10649 | ("python2-enum34" ,python2-enum34) | |
10650 | ("python2-singledispatch" ,python2-singledispatch) | |
10651 | ,@(package-propagated-inputs base)))))) | |
6ba0af79 AI |
10652 | |
10653 | (define-public python-isort | |
10654 | (package | |
10655 | (name "python-isort") | |
10656 | (version "4.2.5") | |
10657 | (source | |
10658 | (origin | |
10659 | (method url-fetch) | |
10660 | (uri (string-append | |
10661 | "https://github.com/timothycrosley/isort/archive/" | |
10662 | version ".tar.gz")) | |
10663 | (file-name (string-append name "-" version ".tar.gz")) | |
10664 | (sha256 | |
10665 | (base32 | |
10666 | "0zsrgkb0krn5476yncy5dd56k7dk34zqb4bnlvwy44ixgilyjmfh")))) | |
10667 | (build-system python-build-system) | |
10668 | (native-inputs | |
10669 | `(("python-mock" ,python-mock) | |
10670 | ("python-pytest" ,python-pytest))) | |
10671 | (home-page "https://github.com/timothycrosley/isort") | |
10672 | (synopsis "Python utility/library to sort python imports") | |
10673 | (description "@code{python-isort} is a python utility/library to sort | |
10674 | imports alphabetically, and automatically separated into sections. It | |
10675 | provides a command line utility, a python library and plugins for various | |
10676 | editors.") | |
10677 | (license license:expat))) | |
10678 | ||
10679 | (define-public python2-isort | |
10680 | (package-with-python2 python-isort)) | |
965a083e AI |
10681 | |
10682 | (define-public python2-backports-functools-lru-cache | |
10683 | (package | |
10684 | (name "python2-backports-functools-lru-cache") | |
10685 | (version "1.3") | |
10686 | (source | |
10687 | (origin | |
10688 | (method url-fetch) | |
10689 | ;; only the pypi tarballs contain the necessary metadata | |
10690 | (uri (pypi-uri "backports.functools_lru_cache" version)) | |
10691 | (sha256 | |
10692 | (base32 | |
10693 | "158ysf2hb0q4p4695abfiym9x1ywg0dgh8a3apd7gqaaxjy22jj4")))) | |
10694 | (build-system python-build-system) | |
10695 | (native-inputs | |
10696 | `(("python2-setuptools-scm" ,python2-setuptools-scm))) | |
10697 | (arguments | |
10698 | `(#:python ,python-2)) | |
10699 | (home-page "https://github.com/jaraco/backports.functools_lru_cache") | |
10700 | (synopsis "Backport of functools.lru_cache from Python 3.3") | |
10701 | (description "@code{python2-backports-functools-lru-cache} is a backport | |
10702 | of @code{functools.lru_cache} from python 3.3.") | |
10703 | (license license:expat))) | |
23db3fc6 AI |
10704 | |
10705 | (define-public python-configparser | |
10706 | (package | |
10707 | (name "python-configparser") | |
10708 | (version "3.5.0") | |
10709 | (source | |
10710 | (origin | |
10711 | (method url-fetch) | |
10712 | (uri (string-append | |
10713 | "https://bitbucket.org/ambv/configparser/get/" | |
10714 | version ".tar.bz2")) | |
10715 | (file-name (string-append name "-" version ".tar.gz")) | |
10716 | (sha256 | |
10717 | (base32 | |
10718 | "0waq40as14abwzbb321hfz4vr1fi363nscy32ga14qvfygrg96wa")))) | |
10719 | (build-system python-build-system) | |
10720 | (home-page "http://docs.python.org/py3k/library/configparser.html") | |
10721 | (synopsis "Backport of configparser from python 3.5") | |
10722 | (description "@code{python-configparser} is a backport of | |
10723 | @code{configparser} from Python 3.5 so that it can be used directly | |
10724 | in other versions.") | |
10725 | (license license:expat))) | |
10726 | ||
10727 | (define-public python2-configparser | |
10728 | (package-with-python2 python-configparser)) | |
61550ded | 10729 | |
eec21d4b MFM |
10730 | (define-public python-mando |
10731 | (package | |
10732 | (name "python-mando") | |
10733 | (version "0.5") | |
10734 | (source | |
10735 | (origin | |
10736 | (method url-fetch) | |
10737 | (uri (pypi-uri "mando" version)) | |
10738 | (sha256 | |
10739 | (base32 | |
10740 | "0q05h66439gqdmlk4jqm6xrwrzfdgs4mwk70barxhr2y83qbbdc0")))) | |
10741 | (build-system python-build-system) | |
10742 | (propagated-inputs | |
10743 | `(("python-rst2ansi" ,python-rst2ansi))) | |
10744 | (native-inputs | |
10745 | `(("python-sphinx" ,python-sphinx-1.5.3) | |
10746 | ("python-paramunittest" ,python-paramunittest))) | |
10747 | (home-page "https://mando.readthedocs.org/") | |
10748 | (synopsis | |
10749 | "Wrapper around argparse, allowing creation of complete CLI applications") | |
10750 | (description | |
10751 | "This package is a wrapper around argparse, allowing you to write complete CLI | |
10752 | applications in seconds while maintaining all the flexibility.") | |
10753 | (license license:expat))) | |
10754 | ||
10755 | (define-public python2-mando | |
10756 | (package-with-python2 python-mando)) | |
b98d4ec0 MFM |
10757 | |
10758 | (define-public python-mando-0.3.1 | |
10759 | ;; python-radon (version 1.5.0) has a requirement | |
10760 | ;; for mando<0.4,>=0.3 | |
10761 | (package | |
10762 | (inherit python-mando) | |
10763 | (name "python-mando") | |
10764 | (version "0.3.1") | |
10765 | (source | |
10766 | (origin | |
10767 | (method url-fetch) | |
10768 | (uri (string-append "https://github.com/rubik/mando/archive/v" | |
10769 | version | |
10770 | ".tar.gz")) | |
10771 | (sha256 | |
10772 | (base32 | |
10773 | "17jlkdpqw22z1nyml5ybslilqkzmnk0dxxjml8bfghav1l5hbwd2")))))) | |
16fe516e BS |
10774 | |
10775 | (define-public python-fudge | |
10776 | (package | |
10777 | (name "python-fudge") | |
10778 | ;; 0.9.6 is the latest version suitable for testing the "fabric" Python 2 | |
10779 | ;; package, which is currently the only use of this package. | |
10780 | (version "0.9.6") | |
10781 | (source | |
10782 | (origin | |
10783 | (method url-fetch) | |
10784 | (uri (pypi-uri "fudge" version)) | |
10785 | (sha256 | |
10786 | (base32 | |
10787 | "185ia3vr3qk4f2s1a9hdxb8ci4qc0x0xidrad96pywg8j930qs9l")))) | |
10788 | (build-system python-build-system) | |
10789 | (arguments | |
10790 | `(#:tests? #f)) ;XXX: Tests require the NoseJS Python package. | |
10791 | (home-page "https://github.com/fudge-py/fudge") | |
10792 | (synopsis "Replace real objects with fakes/mocks/stubs while testing") | |
10793 | (description | |
10794 | "Fudge is a Python module for using fake objects (mocks and stubs) to | |
10795 | test real ones. | |
10796 | ||
10797 | In readable Python code, you declare the methods available on your fake object | |
10798 | and how they should be called. Then you inject that into your application and | |
10799 | start testing. This declarative approach means you don’t have to record and | |
10800 | playback actions and you don’t have to inspect your fakes after running code. | |
10801 | If the fake object was used incorrectly then you’ll see an informative | |
10802 | exception message with a traceback that points to the culprit.") | |
10803 | (license license:expat))) | |
10804 | ||
10805 | (define-public python2-fudge | |
10806 | (package-with-python2 python-fudge)) | |
f3f8d159 | 10807 | |
7e16478f DM |
10808 | (define-public python-mwclient |
10809 | (package | |
10810 | (name "python-mwclient") | |
10811 | (version "0.8.4") | |
10812 | (source | |
10813 | (origin | |
10814 | (method url-fetch) | |
10815 | ;; The PyPI version wouldn't contain tests. | |
10816 | (uri (string-append "https://github.com/mwclient/mwclient/archive/" | |
10817 | "v" version ".tar.gz")) | |
10818 | (sha256 | |
10819 | (base32 | |
10820 | "1jj0yhilkjir00719fc7w133x7hdyhkxhk6xblla4asig45klsfv")))) | |
10821 | (build-system python-build-system) | |
10822 | (propagated-inputs | |
10823 | `(("python-requests" ,python-requests) | |
10824 | ("python-requests-oauthlib" | |
10825 | ,python-requests-oauthlib) | |
10826 | ("python-six" ,python-six))) | |
10827 | (native-inputs | |
10828 | `(("python-mock" ,python-mock) | |
10829 | ("python-pytest" ,python-pytest) | |
10830 | ("python-pytest-pep8" ,python-pytest-pep8) | |
10831 | ("python-pytest-cache" ,python-pytest-cache) | |
10832 | ("python-pytest-cov" ,python-pytest-cov) | |
10833 | ("python-responses" ,python-responses))) | |
10834 | (home-page "https://github.com/btongminh/mwclient") | |
10835 | (synopsis "MediaWiki API client") | |
10836 | (description "This package provides a MediaWiki API client.") | |
10837 | (license license:expat))) | |
10838 | ||
10839 | (define-public python2-mwclient | |
10840 | (package-with-python2 python-mwclient)) | |
59a97288 | 10841 | |
75805449 JL |
10842 | (define-public python-utils |
10843 | (package | |
10844 | (name "python-utils") | |
10845 | (version "2.1.0") | |
10846 | (source (origin | |
10847 | (method url-fetch) | |
10848 | (uri (pypi-uri "python-utils" version)) | |
10849 | (sha256 | |
10850 | (base32 | |
10851 | "1mcsy6q5am4ya72rgkpb6kax6vv7c93cfkkas89xnpa4sj9zf28p")))) | |
10852 | (build-system python-build-system) | |
10853 | (native-inputs | |
10854 | `(("pytest-runner" ,python-pytest-runner) | |
10855 | ("pytest" ,python-pytest) | |
10856 | ("six" ,python-six))) | |
10857 | (home-page "https://github.com/WoLpH/python-utils") | |
10858 | (synopsis "Convenient utilities not included with the standard Python install") | |
10859 | (description | |
10860 | "Python Utils is a collection of small Python functions and classes which | |
10861 | make common patterns shorter and easier.") | |
10862 | (license license:bsd-2))) | |
10863 | ||
10864 | (define-public python2-utils | |
10865 | (package-with-python2 python-utils)) | |
709a5a93 | 10866 | |
4c066b72 JL |
10867 | (define-public python-sphinx-me |
10868 | (package | |
10869 | (name "python-sphinx-me") | |
10870 | (version "0.3") | |
10871 | (source | |
10872 | (origin | |
10873 | (method url-fetch) | |
10874 | (uri (pypi-uri "sphinx-me" version)) | |
10875 | (sha256 | |
10876 | (base32 | |
10877 | "06jzgp213zihnvpcy2y5jy3ykid3apc2ncp2pg6a2g05lhiziglq")))) | |
10878 | (build-system python-build-system) | |
10879 | (home-page "https://github.com/stephenmcd/sphinx-me") | |
10880 | (synopsis "Create a Sphinx documentation shell") | |
10881 | (description | |
10882 | "Create a Sphinx documentation shell for your project and include the | |
10883 | README file as the documentation index. It handles extracting the required | |
10884 | meta data such as the project name, author and version from your project for | |
10885 | use in your Sphinx docs.") | |
10886 | (license license:bsd-2))) | |
10887 | ||
10888 | (define-public python2-sphinx-me | |
10889 | (package-with-python2 python-sphinx-me)) | |
03ded2fd | 10890 | |
186d4f8d JL |
10891 | (define-public python-diff-match-patch |
10892 | (package | |
10893 | (name "python-diff-match-patch") | |
10894 | (version "20121119") | |
10895 | (source | |
10896 | (origin | |
10897 | (method url-fetch) | |
10898 | (uri (pypi-uri "diff-match-patch" version)) | |
10899 | (sha256 | |
10900 | (base32 | |
10901 | "0k1f3v8nbidcmmrk65m7h8v41jqi37653za9fcs96y7jzc8mdflx")))) | |
10902 | (build-system python-build-system) | |
10903 | (home-page "https://code.google.com/p/google-diff-match-patch") | |
10904 | (synopsis "Synchronize plain text") | |
10905 | (description "Diff Match and Patch libraries offer robust algorithms to | |
10906 | perform the operations required for synchronizing plain text.") | |
10907 | (license license:asl2.0))) | |
10908 | ||
10909 | (define-public python2-diff-match-patch | |
10910 | (package-with-python2 python-diff-match-patch)) | |
d15a4791 JL |
10911 | |
10912 | (define-public python-dirsync | |
10913 | (package | |
10914 | (name "python-dirsync") | |
10915 | (version "2.2.2") | |
10916 | (source | |
10917 | (origin | |
10918 | (method url-fetch) | |
10919 | (uri (pypi-uri "dirsync" version ".zip")) | |
10920 | (sha256 | |
10921 | (base32 | |
10922 | "1hcdvmkwd5512zbxpin0k7bx5bkgzy3swjx7d0kj1y45af6r75v2")))) | |
10923 | (build-system python-build-system) | |
10924 | (native-inputs | |
10925 | `(("unzip" ,unzip))) | |
10926 | (propagated-inputs | |
10927 | `(("six" ,python-six))) | |
10928 | (home-page "https://bitbucket.org/tkhyn/dirsync") | |
10929 | (synopsis "Advanced directory tree synchronisation tool") | |
10930 | (description "Advanced directory tree synchronisation tool.") | |
10931 | (license license:expat))) | |
10932 | ||
10933 | (define-public python2-dirsync | |
10934 | (package-with-python2 python-dirsync)) | |
1b16f1ec | 10935 | |
a17ccbbb JL |
10936 | (define-public python-levenshtein |
10937 | (package | |
10938 | (name "python-levenshtein") | |
10939 | (version "0.12.0") | |
10940 | (source | |
10941 | (origin | |
10942 | (method url-fetch) | |
10943 | (uri (pypi-uri "python-Levenshtein" version)) | |
10944 | (sha256 | |
10945 | (base32 | |
10946 | "1c9ybqcja31nghfcc8xxbbz9h60s9qi12b9hr4jyl69xbvg12fh3")))) | |
10947 | (build-system python-build-system) | |
10948 | (home-page "https://github.com/ztane/python-Levenshtein") | |
10949 | (synopsis "Fast computation of Levenshtein distance and string similarity") | |
10950 | (description | |
10951 | "The Levenshtein Python C extension module contains functions for fast computation of | |
10952 | @enumerate | |
10953 | @item Levenshtein (edit) distance, and edit operations | |
10954 | @item string similarity | |
10955 | @item approximate median strings, and generally string averaging | |
10956 | @item string sequence and set similarity | |
10957 | @end enumerate | |
10958 | It supports both normal and Unicode strings.") | |
10959 | (license license:gpl2+))) | |
10960 | ||
10961 | (define-public python2-levenshtein | |
10962 | (package-with-python2 python-levenshtein)) | |
38a370d2 JL |
10963 | |
10964 | (define-public python-scandir | |
10965 | (package | |
10966 | (name "python-scandir") | |
10967 | (version "1.4") | |
10968 | (source | |
10969 | (origin | |
10970 | (method url-fetch) | |
10971 | (uri (pypi-uri "scandir" version)) | |
10972 | (sha256 | |
10973 | (base32 "0yjrgp0mxp3d8bjkq2m1ac2ys8n76wykksvgyjrnil9gr3fx7a5d")))) | |
10974 | (build-system python-build-system) | |
10975 | (home-page "https://github.com/benhoyt/scandir") | |
10976 | (synopsis "Directory iteration function") | |
10977 | (description | |
10978 | "Directory iteration function like os.listdir(), except that instead of | |
10979 | returning a list of bare filenames, it yields DirEntry objects that include | |
10980 | file type and stat information along with the name. Using scandir() increases | |
10981 | the speed of os.walk() by 2-20 times (depending on the platform and file | |
10982 | system) by avoiding unnecessary calls to os.stat() in most cases.") | |
10983 | (license license:bsd-3))) | |
10984 | ||
10985 | (define-public python2-scandir | |
10986 | (package-with-python2 python-scandir)) | |
18c25460 JL |
10987 | |
10988 | (define-public python2-stemming | |
10989 | (package | |
10990 | (name "python2-stemming") | |
10991 | (version "1.0.1") | |
10992 | (source | |
10993 | (origin | |
10994 | (method url-fetch) | |
10995 | (uri (pypi-uri "stemming" version)) | |
10996 | (sha256 | |
10997 | (base32 "0ldwa24gnnxhniv0fhygkpc2mwgd93q10ag8rvzayv6hw418frsr")))) | |
10998 | (build-system python-build-system) | |
10999 | (arguments | |
11000 | `(#:python ,python-2)) | |
11001 | (home-page "https://bitbucket.org/mchaput/stemming/overview") | |
11002 | (synopsis "Python implementations of various stemming algorithms") | |
11003 | (description | |
11004 | "Python implementations of the Porter, Porter2, Paice-Husk, and Lovins | |
11005 | stemming algorithms for English. These implementations are straightforward and | |
11006 | efficient, unlike some Python versions of the same algorithms available on the | |
11007 | Web. This package is an extraction of the stemming code included in the Whoosh | |
11008 | search engine.") | |
11009 | (license license:public-domain))) | |
54153b85 JL |
11010 | |
11011 | (define-public python-factory-boy | |
11012 | (package | |
11013 | (name "python-factory-boy") | |
11014 | (version "2.8.1") | |
11015 | (source | |
11016 | (origin | |
11017 | (method url-fetch) | |
11018 | (uri (pypi-uri "factory_boy" version)) | |
11019 | (sha256 | |
11020 | (base32 "1fvin6san5xsjh2c4y18caj2lnmwxlylyqm8mh1yc6rp38wlwr56")))) | |
11021 | (build-system python-build-system) | |
11022 | (arguments | |
11023 | ;; Tests are not included in the tarball. | |
11024 | `(#:tests? #f)) | |
11025 | (propagated-inputs | |
11026 | `(("faker" ,python-faker))) | |
11027 | (home-page "https://github.com/benhoyt/scandir") | |
11028 | (synopsis "Versatile test fixtures replacement") | |
11029 | (description | |
11030 | "Factory_boy is a fixtures replacement based on thoughtbot’s factory_girl. | |
11031 | ||
11032 | As a fixtures replacement tool, it aims to replace static, hard to maintain | |
11033 | fixtures with easy-to-use factories for complex object. | |
11034 | ||
11035 | Instead of building an exhaustive test setup with every possible combination | |
11036 | of corner cases, factory_boy allows you to use objects customized for the | |
11037 | current test, while only declaring the test-specific fields") | |
11038 | (license license:expat))) | |
11039 | ||
11040 | (define-public python2-factory-boy | |
11041 | (package-with-python2 python-factory-boy)) | |
5f25fd69 JL |
11042 | |
11043 | (define-public python-translate-toolkit | |
11044 | (package | |
11045 | (name "python-translate-toolkit") | |
11046 | (version "2.1.0") | |
11047 | (source | |
11048 | (origin | |
11049 | (method url-fetch) | |
11050 | (uri (pypi-uri "translate-toolkit" version ".tar.bz2")) | |
11051 | (sha256 | |
11052 | (base32 "1vlkwrg83vb17jc36pmwh2b7jphwf390lz0jw8hakcg16qhwypvq")))) | |
11053 | (build-system python-build-system) | |
11054 | (native-inputs | |
11055 | `(("python-pytest" ,python-pytest) | |
11056 | ("python-sphinx" ,python-sphinx))) | |
11057 | (propagated-inputs | |
11058 | `(("python-babel" ,python-babel) | |
11059 | ("python-beautifulsoup4" ,python-beautifulsoup4) | |
11060 | ("python-chardet" ,python-chardet) | |
11061 | ("python-diff-match-patch" ,python-diff-match-patch) | |
11062 | ("python-levenshtein" ,python-levenshtein) | |
11063 | ("python-lxml" ,python-lxml) | |
11064 | ("python-six" ,python-six) | |
11065 | ("python-vobject" ,python-vobject) | |
11066 | ("python-pyyaml" ,python-pyyaml))) | |
11067 | (arguments | |
11068 | ;; TODO: tests are not run, because they end with | |
11069 | ;; TypeError: parse() missing 2 required positional arguments: 'tree' and | |
11070 | ;; 'parse_funcs' | |
11071 | ;; during test setup. | |
11072 | `(#:tests? #f)) | |
11073 | (home-page "http://toolkit.translatehouse.org") | |
11074 | (synopsis "Tools and API for translation and localization engineering") | |
11075 | (description | |
11076 | "Tools and API for translation and localization engineering. It contains | |
11077 | several utilities, as well as an API for building localization tools.") | |
11078 | (license license:gpl2+))) | |
11079 | ||
11080 | (define-public python2-translate-toolkit | |
11081 | (package-with-python2 python-translate-toolkit)) | |
3b08d1a6 | 11082 | |
c0f5b802 LF |
11083 | (define-public python-packaging |
11084 | (package | |
11085 | (name "python-packaging") | |
11086 | (version "16.8") | |
11087 | (source | |
11088 | (origin | |
11089 | (method url-fetch) | |
11090 | (uri (pypi-uri "packaging" version)) | |
11091 | (sha256 | |
11092 | (base32 | |
11093 | "17k1xbjshackwvbsnxqixbph8rbqhz4bf4g3al5xyzhavxgq6l2x")))) | |
11094 | (build-system python-build-system) | |
11095 | (native-inputs | |
11096 | `(("python-pretend" ,python-pretend) | |
11097 | ("python-pytest" ,python-pytest))) | |
11098 | (propagated-inputs | |
11099 | `(("python-pyparsing" ,python-pyparsing) | |
11100 | ("python-six" ,python-six))) | |
11101 | (home-page "https://github.com/pypa/packaging") | |
11102 | (synopsis "Core utilities for Python packages") | |
11103 | (description "Packaging is a Python module for dealing with Python packages. | |
11104 | It offers an interface for working with package versions, names, and dependency | |
11105 | information.") | |
11106 | ;; From 'LICENSE': This software is made available under the terms of | |
11107 | ;; *either* of the licenses found in LICENSE.APACHE or LICENSE.BSD. | |
11108 | ;; Contributions to this software is made under the terms of *both* these | |
11109 | ;; licenses. | |
11110 | (license (list license:asl2.0 license:bsd-2)))) | |
11111 | ||
11112 | (define-public python2-packaging | |
11113 | (package-with-python2 python-packaging)) | |
ad2ef260 | 11114 | |
ecca63b6 AP |
11115 | (define-public python-relatorio |
11116 | (package | |
11117 | (name "python-relatorio") | |
11118 | (version "0.6.4") | |
11119 | (source | |
11120 | (origin | |
11121 | (method url-fetch) | |
11122 | (uri (pypi-uri "relatorio" version)) | |
11123 | (sha256 | |
11124 | (base32 | |
11125 | "0lincq79mzgazwd9gh41dybjh9c3n87r83pl8nk3j79aihyfk84z")))) | |
11126 | (build-system python-build-system) | |
11127 | (propagated-inputs | |
11128 | `(("python-lxml" ,python-lxml) | |
11129 | ("python-genshi" ,python-genshi))) | |
11130 | (home-page "https://relatorio.tryton.org/") | |
11131 | (synopsis "Templating library able to output ODT and PDF files") | |
11132 | (description "Relatorio is a templating library which provides a way to | |
11133 | easily output ODT, ODS, PNG, SVG and several other kinds of files. Support | |
11134 | for more filetypes can be easily added by creating plugins for them.") | |
11135 | (license license:gpl3+))) | |
11136 | ||
11137 | (define-public python2-relatorio | |
11138 | (package-with-python2 python-relatorio)) | |
65e7d52a MFM |
11139 | |
11140 | (define-public python-radon | |
11141 | (package | |
11142 | (name "python-radon") | |
11143 | (version "1.5.0") | |
11144 | (source | |
11145 | (origin | |
11146 | (method url-fetch) | |
11147 | (uri (pypi-uri "radon" version)) | |
11148 | (sha256 | |
11149 | (base32 | |
11150 | "1h6jv36am0i827182a04ki6291lyx4kp957xfr5njgprj4nd0qsl")))) | |
11151 | (build-system python-build-system) | |
11152 | (propagated-inputs | |
11153 | `(("python-colorama" ,python-colorama) | |
11154 | ("python-flake8-polyfill" ,python-flake8-polyfill) | |
11155 | ("python-mando" ,python-mando-0.3.1))) | |
11156 | (native-inputs | |
11157 | `(("python-flake8" ,python-flake8) | |
11158 | ("python-tox" ,python-tox) | |
11159 | ("python-pytest" ,python-pytest) | |
11160 | ("python-paramunittest" ,python-paramunittest))) | |
11161 | (home-page "https://radon.readthedocs.org/") | |
11162 | (synopsis "Code Metrics in Python") | |
11163 | (description "Radon is a Python tool which computes various code metrics. | |
11164 | Supported metrics are: | |
11165 | @itemize @bullet | |
11166 | @item raw metrics: SLOC, comment lines, blank lines, &c. | |
11167 | @item Cyclomatic Complexity (i.e. McCabe’s Complexity) | |
11168 | @item Halstead metrics (all of them) | |
11169 | @item the Maintainability Index (a Visual Studio metric) | |
11170 | @end itemize") | |
11171 | (license license:expat))) | |
11172 | ||
11173 | (define-public python2-radon | |
11174 | (package-with-python2 python-radon)) | |
50d586f6 MFM |
11175 | |
11176 | (define-public python-sure | |
11177 | (package | |
11178 | (name "python-sure") | |
11179 | (version "1.4.6") | |
11180 | (source | |
11181 | (origin | |
11182 | (method url-fetch) | |
11183 | (uri (pypi-uri "sure" version)) | |
11184 | (sha256 | |
11185 | (base32 | |
11186 | "1iyqsy2d6radi88g1qf0lziy5b39h5cpb3g5jiqyb4xi46ig3x1z")))) | |
11187 | (build-system python-build-system) | |
11188 | (propagated-inputs | |
11189 | `(("python-mock" ,python-mock) | |
11190 | ("python-six" ,python-six))) | |
11191 | (native-inputs | |
11192 | `(("python-nose" ,python-nose))) | |
11193 | (home-page "https://github.com/gabrielfalcao/sure") | |
11194 | (synopsis "Automated testing library in python for python") | |
11195 | (description | |
11196 | "Sure is a python library that leverages a DSL for writing assertions. | |
11197 | Sure is heavily inspired by @code{RSpec Expectations} and @code{should.js}.") | |
11198 | (license license:gpl3+))) | |
11199 | ||
11200 | (define-public python2-sure | |
11201 | (package-with-python2 python-sure)) | |
a0ffc701 MFM |
11202 | |
11203 | (define-public python2-couleur | |
11204 | ;; This package does not seem to support python3 at all, hence, | |
11205 | ;; only the python2 variant definition is provided. | |
11206 | (package | |
11207 | (name "python2-couleur") | |
11208 | (version "0.6.2") | |
11209 | (source | |
11210 | (origin | |
11211 | (method url-fetch) | |
11212 | (uri (pypi-uri "couleur" version)) | |
11213 | (sha256 | |
11214 | (base32 | |
11215 | "1qqaxyqz74wvid0cr119dhcwz0h0if5b5by44zl49pd5z65v58k1")))) | |
11216 | (build-system python-build-system) | |
11217 | (arguments | |
11218 | `(#:python ,python-2)) | |
11219 | (home-page "https://github.com/gabrielfalcao/couleur") | |
11220 | (synopsis | |
11221 | "ANSI terminal tool for python, colored shell and other handy fancy features") | |
11222 | (description | |
11223 | "@code{Couleur} provides python programs a way to use the ANSI features in a unix | |
11224 | terminal such as coloured output in the shell, overwriting output, indentation, etc.") | |
11225 | ;; README.md says ASL2.0, but all source code headers are LGPL3+. | |
11226 | ;; https://github.com/gabrielfalcao/couleur/issues/11 | |
11227 | (license license:lgpl3+))) | |
511b47de MFM |
11228 | |
11229 | (define-public python-misaka | |
11230 | (package | |
11231 | (name "python-misaka") | |
11232 | (version "2.1.0") | |
11233 | (source | |
11234 | (origin | |
11235 | (method url-fetch) | |
11236 | (uri (pypi-uri "misaka" version)) | |
11237 | (sha256 | |
11238 | (base32 | |
11239 | "1yqrq3a5rracirmvk52n28nn6ckdaz897gnigv89a9gmyn87sqw7")))) | |
11240 | (build-system python-build-system) | |
11241 | (arguments | |
11242 | `(;; Line 37 of setup.py calls self.run_command('develop') | |
11243 | ;; in the 'check' phase. This command seems to be trying | |
11244 | ;; to write to | |
11245 | ;; /gnu/store/...-python-<version>/lib/python<version>/site-packages/ | |
11246 | ;; for which it does not have the permission to write. | |
11247 | #:tests? #f)) | |
11248 | (propagated-inputs | |
11249 | `(("python-cffi" ,python-cffi))) | |
11250 | (home-page "https://github.com/FSX/misaka") | |
11251 | (synopsis "Python binding for Hoedown") | |
11252 | (description | |
11253 | "@code{Misaka} is a CFFI-based binding for @code{Hoedown}, a fast markdown processing | |
11254 | library written in C. It features a fast HTML renderer and functionality to make custom | |
11255 | renderers (e.g. man pages or LaTeX).") | |
11256 | (license license:expat))) | |
11257 | ||
11258 | (define-public python2-misaka | |
11259 | (package-with-python2 python-misaka)) | |
5786b47c MFM |
11260 | |
11261 | (define-public python2-steadymark | |
11262 | ;; This is forced into being a python2 only variant | |
11263 | ;; due to its dependence on couleur that has no support | |
11264 | ;; for python3 | |
11265 | (package | |
11266 | (name "python2-steadymark") | |
11267 | (version "0.7.3") | |
11268 | (source | |
11269 | (origin | |
11270 | (method url-fetch) | |
11271 | (uri (pypi-uri "steadymark" version)) | |
11272 | (sha256 | |
11273 | (base32 | |
11274 | "1640i9g8dycql3cc8j0bky0jkzj0q39blfbp4lsgpkprkfgcdk8v")))) | |
11275 | (build-system python-build-system) | |
11276 | (native-inputs | |
11277 | `(("python-couleur" ,python2-couleur) | |
11278 | ("python-sure" ,python2-sure) | |
11279 | ("python-misaka" ,python2-misaka))) | |
11280 | (arguments | |
11281 | `(#:python ,python-2 | |
11282 | #:phases | |
11283 | (modify-phases %standard-phases | |
11284 | (add-before 'build 'patch-setup-py | |
11285 | (lambda _ | |
11286 | ;; Update requirements from dependency==version | |
11287 | ;; to dependency>=version | |
11288 | (substitute* "setup.py" | |
11289 | (("==") ">=")) | |
11290 | #t))))) | |
11291 | (home-page "https://github.com/gabrielfalcao/steadymark") | |
11292 | (synopsis "Markdown-based test runner for python") | |
11293 | (description | |
11294 | "@code{Steadymark} allows documentation to be written in github-flavoured | |
11295 | markdown. The documentation may contain snippets of code surrounded by python | |
11296 | code blocks and @code{Steadymark} will find these snippets and run them, making | |
11297 | sure that there are no old malfunctional examples in the documentation examples.") | |
11298 | (license license:expat))) | |
7e488f99 | 11299 | |
1e92287d DM |
11300 | (define-public python-jsonpointer |
11301 | (package | |
11302 | (name "python-jsonpointer") | |
11303 | (version "1.10") | |
11304 | (source | |
11305 | (origin | |
11306 | (method url-fetch) | |
11307 | (uri (pypi-uri "jsonpointer" version)) | |
11308 | (sha256 | |
11309 | (base32 | |
11310 | "1cg0gvgqjysydv6p45v4jywg1jb3v48c7m3cbpi57zgf6nndr9cz")))) | |
11311 | (build-system python-build-system) | |
11312 | (home-page "https://github.com/stefankoegl/python-json-pointer") | |
11313 | (synopsis "Identify specific nodes in a JSON document") | |
11314 | (description "@code{jsonpointer} allows you to access specific nodes | |
11315 | by path in a JSON document (see RFC 6901).") | |
11316 | (license license:bsd-3))) | |
11317 | ||
11318 | (define-public python2-jsonpointer | |
11319 | (package-with-python2 python-jsonpointer)) | |
7d88093f | 11320 | |
841e5908 OP |
11321 | (define-public python-jsonpatch |
11322 | (package | |
11323 | (name "python-jsonpatch") | |
11324 | (version "1.16") | |
11325 | (source | |
11326 | (origin | |
11327 | (method url-fetch) | |
11328 | ;; pypi version lacks tests.js | |
11329 | (uri (string-append "https://github.com/stefankoegl/python-json-patch/" | |
11330 | "archive/v" version ".tar.gz")) | |
11331 | (file-name (string-append name "-" version ".tar.gz")) | |
11332 | (sha256 | |
11333 | (base32 | |
11334 | "085ykisl8v7mv9h7hvhdy3l2fjzs4214gx32r5k6nx4f76hbv6y5")))) | |
11335 | (build-system python-build-system) | |
11336 | (native-inputs | |
11337 | `(("python-jsonpointer" ,python-jsonpointer))) | |
11338 | (home-page "https://github.com/stefankoegl/python-json-patch") | |
11339 | (synopsis "Applying JSON Patches in Python 2.6+ and 3.x") | |
11340 | (description "@code{jsonpatch} is a library and program that allows | |
11341 | applying JSON Patches according to RFC 6902.") | |
11342 | (license license:bsd-3))) | |
11343 | ||
11344 | (define-public python2-jsonpatch | |
11345 | (package-with-python2 python-jsonpatch)) | |
11346 | ||
11347 | (define-public python-jsonpatch-0.4 | |
11348 | (package (inherit python-jsonpatch) | |
11349 | (name "python-jsonpatch") | |
11350 | (version "0.4") | |
11351 | (source | |
11352 | (origin | |
11353 | (method url-fetch) | |
11354 | (uri (string-append "https://github.com/stefankoegl/python-json-patch/" | |
11355 | "archive/v" version ".tar.gz")) | |
11356 | (file-name (string-append name "-" version ".tar.gz")) | |
11357 | (sha256 | |
11358 | (base32 | |
11359 | "0j0cd9z9zyp8kppp464jxrfgrnbgkzl1yi10i5gsv8yz6d95929d")))))) | |
11360 | ||
11361 | (define-public python2-jsonpatch-0.4 | |
11362 | (package-with-python2 python-jsonpatch-0.4)) | |
11363 | ||
7d88093f DM |
11364 | (define-public python-rfc3987 |
11365 | (package | |
11366 | (name "python-rfc3987") | |
11367 | (version "1.3.7") | |
11368 | (source | |
11369 | (origin | |
11370 | (method url-fetch) | |
11371 | (uri (pypi-uri "rfc3987" version)) | |
11372 | (sha256 | |
11373 | (base32 | |
11374 | "192pclzs2y0yaywqkrlvd0x73740q310kvqvm6jldhi619mq59wi")))) | |
11375 | (build-system python-build-system) | |
9be5ecdf | 11376 | (home-page "https://pypi.python.org/pypi/rfc3987") |
7d88093f DM |
11377 | (synopsis "Parsing and validation of URIs (RFC 3986) and IRIs (RFC 3987)") |
11378 | (description "@code{rfc3987} provides routines for parsing and | |
11379 | validation of URIs (see RFC 3986) and IRIs (see RFC 3987).") | |
11380 | (license license:gpl3+))) | |
11381 | ||
11382 | (define-public python2-rfc3987 | |
11383 | (package-with-python2 python-rfc3987)) | |
0960bf8b DM |
11384 | |
11385 | (define-public python-validate-email | |
11386 | (package | |
11387 | (name "python-validate-email") | |
11388 | (version "1.3") | |
11389 | (source | |
11390 | (origin | |
11391 | (method url-fetch) | |
11392 | (uri (pypi-uri "validate_email" version)) | |
11393 | (sha256 | |
11394 | (base32 | |
11395 | "1bxffaf5yz2cph8ki55vdvdypbwkvn2xr1firlcy62vqbzf1jivq")))) | |
11396 | (build-system python-build-system) | |
9be5ecdf | 11397 | (home-page "https://github.com/syrusakbary/validate_email") |
0960bf8b DM |
11398 | (synopsis "Verifies if an email address is valid and really exists") |
11399 | (description "@code{validate_email} can be used to verify if an email | |
11400 | address is valid and really exists.") | |
11401 | (license license:lgpl3+))) | |
11402 | ||
11403 | (define-public python2-validate-email | |
11404 | (package-with-python2 python-validate-email)) | |
620b59ea DM |
11405 | |
11406 | (define-public python-flex | |
11407 | (package | |
11408 | (name "python-flex") | |
11409 | (version "6.10.0") | |
11410 | (source | |
11411 | (origin | |
11412 | (method url-fetch) | |
11413 | (uri (pypi-uri "flex" version)) | |
11414 | (sha256 | |
11415 | (base32 | |
11416 | "00pamnwla3khk8nyla7y28dq9jnh69swd7f4jfsl7sn1izs8n8zk")))) | |
11417 | (build-system python-build-system) | |
11418 | (propagated-inputs | |
11419 | `(("python-click" ,python-click) | |
11420 | ("python-iso8601" ,python-iso8601) | |
11421 | ("python-jsonpointer" ,python-jsonpointer) | |
11422 | ("python-pyyaml" ,python-pyyaml) | |
11423 | ("python-requests" ,python-requests) | |
11424 | ("python-rfc3987" ,python-rfc3987) | |
11425 | ("python-six" ,python-six) | |
11426 | ("python-validate-email" ,python-validate-email))) | |
11427 | (home-page "https://github.com/pipermerriam/flex") | |
11428 | (synopsis "Validates Swagger schemata") | |
11429 | (description "@code{flex} can be used to validate Swagger schemata.") | |
11430 | (license license:bsd-3))) | |
11431 | ||
11432 | (define-public python2-flex | |
11433 | (package-with-python2 python-flex)) | |
235bc01b DM |
11434 | |
11435 | (define-public python-marshmallow | |
11436 | (package | |
11437 | (name "python-marshmallow") | |
58f3d459 | 11438 | (version "3.0.0b3") |
235bc01b DM |
11439 | (source |
11440 | (origin | |
11441 | (method url-fetch) | |
11442 | (uri (pypi-uri "marshmallow" version)) | |
11443 | (sha256 | |
11444 | (base32 | |
58f3d459 | 11445 | "07mcrij1yvk85lvgx44wwr9pc80xryghvlgayb057g1cazcypysd")))) |
235bc01b DM |
11446 | (build-system python-build-system) |
11447 | (propagated-inputs | |
11448 | `(("python-dateutil" ,python-dateutil) | |
11449 | ("python-simplejson" ,python-simplejson))) | |
11450 | (native-inputs | |
11451 | `(("python-pytest-3.0" ,python-pytest-3.0) | |
11452 | ("python-pytz" ,python-pytz))) | |
11453 | (home-page "https://github.com/marshmallow-code/marshmallow") | |
11454 | (synopsis "Convert complex datatypes to and from native | |
11455 | Python datatypes.") | |
11456 | (description "@code{marshmallow} provides a library for converting | |
11457 | complex datatypes to and from native Python datatypes.") | |
11458 | (license license:expat))) | |
11459 | ||
11460 | (define-public python2-marshmallow | |
11461 | (package-with-python2 python-marshmallow)) | |
d270df8d | 11462 | |
635b3636 DM |
11463 | (define-public python-apispec |
11464 | (package | |
11465 | (name "python-apispec") | |
a9769a29 | 11466 | (version "0.25.3") |
635b3636 DM |
11467 | (source |
11468 | (origin | |
11469 | (method url-fetch) | |
11470 | (uri (pypi-uri "apispec" version)) | |
11471 | (sha256 | |
11472 | (base32 | |
a9769a29 | 11473 | "0kxa8723zbisx10363yh4mmmn4higxrspymbjfz5zq8f644zagm9")))) |
635b3636 DM |
11474 | (build-system python-build-system) |
11475 | (propagated-inputs | |
11476 | `(("python-pyyaml" ,python-pyyaml))) | |
11477 | (native-inputs | |
11478 | `(("python-pytest-3.0" ,python-pytest-3.0) | |
11479 | ("python-flask" ,python-flask) | |
11480 | ("python-marshmallow" ,python-marshmallow) | |
11481 | ("python-tornado" ,python-tornado) | |
11482 | ("python-bottle" ,python-bottle) | |
11483 | ("python-mock" ,python-mock))) | |
11484 | (home-page "https://github.com/marshmallow-code/apispec") | |
11485 | (synopsis "Swagger 2.0 API specification generator") | |
11486 | (description "@code{python-apispec} is a pluggable API specification | |
11487 | generator. Currently supports the OpenAPI specification (f.k.a. | |
11488 | Swagger 2.0).") | |
11489 | (license license:expat))) | |
11490 | ||
11491 | (define-public python2-apispec | |
11492 | (package-with-python2 python-apispec)) | |
543c5f3f DM |
11493 | |
11494 | (define-public python-flasgger | |
11495 | (package | |
11496 | (name "python-flasgger") | |
11497 | (version "0.6.3") | |
11498 | (source | |
11499 | (origin | |
11500 | (method url-fetch) | |
11501 | (uri (string-append "https://github.com/rochacbruno/flasgger/archive/" | |
11502 | version ".tar.gz")) | |
11503 | (file-name (string-append name "-" version ".tar.gz")) | |
11504 | (sha256 | |
11505 | (base32 | |
11506 | "1gqzlm0rb55fdpsy5ipkganlx9cnpi454fqyycr03jm22zql14ay")))) | |
11507 | (build-system python-build-system) | |
11508 | (arguments | |
11509 | `(#:phases | |
11510 | (modify-phases %standard-phases | |
11511 | (replace 'check | |
11512 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
11513 | (substitute* "Makefile" | |
11514 | (("flake8 flasgger --ignore=F403") | |
11515 | "flake8 flasgger --ignore=E731,F403")) | |
11516 | (setenv "PYTHONPATH" (string-append (getcwd) | |
11517 | ":" | |
11518 | (getenv "PYTHONPATH"))) | |
11519 | (zero? (system* "py.test"))))))) | |
11520 | (propagated-inputs | |
11521 | `(("python-flask" ,python-flask) | |
11522 | ("python-pyyaml" ,python-pyyaml) | |
11523 | ("python-jsonschema" ,python-jsonschema) | |
11524 | ("python-mistune" ,python-mistune) | |
11525 | ("python-six" ,python-six))) | |
11526 | (native-inputs | |
11527 | `(("python-decorator" ,python-decorator) | |
11528 | ("python-flake8" ,python-flake8) | |
11529 | ("python-flask-restful" ,python-flask-restful) | |
11530 | ("python-flex" ,python-flex) | |
11531 | ("python-pytest-3.0" ,python-pytest-3.0) | |
11532 | ("python-pytest-cov" ,python-pytest-cov) | |
11533 | ("python-marshmallow" ,python-marshmallow) | |
11534 | ("python-apispec" ,python-apispec))) | |
11535 | (home-page "https://github.com/rochacbruno/flasgger/") | |
11536 | (synopsis "Extract Swagger specs from your Flask project") | |
11537 | (description "@code{python-flasgger} allows extracting Swagger specs | |
11538 | from your Flask project. It is a fork of Flask-Swagger.") | |
11539 | (license license:expat))) | |
11540 | ||
11541 | (define-public python2-flasgger | |
11542 | (package-with-python2 python-flasgger)) | |
4eadc8b9 DM |
11543 | |
11544 | (define-public python-swagger-spec-validator | |
11545 | (package | |
11546 | (name "python-swagger-spec-validator") | |
11547 | (version "2.1.0") | |
11548 | (source | |
11549 | (origin | |
11550 | (method url-fetch) | |
11551 | (uri (pypi-uri "swagger-spec-validator" version)) | |
11552 | (sha256 | |
11553 | (base32 | |
11554 | "13hkpn2lycwr0468yqhjb3kwszqf7hjwlq61w7vdxq1caz31k4nw")))) | |
11555 | (build-system python-build-system) | |
11556 | (propagated-inputs | |
11557 | `(("python-jsonschema" ,python-jsonschema) | |
11558 | ("python-six" ,python-six))) | |
11559 | (home-page | |
9be5ecdf | 11560 | "https://github.com/Yelp/swagger_spec_validator") |
4eadc8b9 DM |
11561 | (synopsis "Validation of Swagger specifications") |
11562 | (description "@code{swagger_spec_validator} provides a library for | |
11563 | validating Swagger API specifications.") | |
11564 | (license license:asl2.0))) | |
11565 | ||
11566 | (define-public python2-swagger-spec-validator | |
11567 | (package-with-python2 python-swagger-spec-validator)) | |
7ea498e5 DM |
11568 | |
11569 | (define-public python-apache-libcloud | |
11570 | (package | |
11571 | (name "python-apache-libcloud") | |
11572 | (version "2.0.0") | |
11573 | (source | |
11574 | (origin | |
11575 | (method url-fetch) | |
11576 | (uri (pypi-uri "apache-libcloud" version)) | |
11577 | (sha256 | |
11578 | (base32 | |
11579 | "1a71z02ckcxld72k4qgmdnkjan52c4wczncs3p2mp5yafh7dsan7")))) | |
11580 | (build-system python-build-system) | |
11581 | (arguments | |
11582 | `(#:phases | |
11583 | (modify-phases %standard-phases | |
11584 | (add-after 'unpack 'patch-ssh | |
11585 | (lambda* (#:key inputs #:allow-other-keys) | |
11586 | (substitute* "libcloud/compute/ssh.py" | |
11587 | (("'ssh'") (string-append "'" (assoc-ref inputs "openssh") | |
11588 | "/bin/ssh" "'"))) | |
11589 | #t)) | |
11590 | (add-after 'unpack 'patch-tests | |
11591 | (lambda _ | |
11592 | (substitute* "./libcloud/test/test_file_fixtures.py" | |
11593 | ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-923>. | |
11594 | (("def _ascii") "def _raw_data(self, method, url, body, headers): | |
11595 | return (httplib.OK, | |
11596 | \"1234abcd\", | |
11597 | {\"test\": \"value\"}, | |
11598 | httplib.responses[httplib.OK]) | |
11599 | def _ascii")) | |
11600 | (substitute* "libcloud/test/compute/test_ssh_client.py" | |
11601 | (("class ShellOutSSHClientTests") | |
11602 | "@unittest.skip(\"Guix container doesn't have ssh service\") | |
11603 | class ShellOutSSHClientTests") | |
11604 | ;; See <https://issues.apache.org/jira/browse/LIBCLOUD-924>. | |
11605 | (("'.xf0.x90.x8d.x88'") "b'\\xF0\\x90\\x8D\\x88'") | |
11606 | (("'.xF0', '.x90', '.x8D', '.x88'") | |
11607 | "b'\\xF0', b'\\x90', b'\\x8D', b'\\x88'")) | |
11608 | #t))))) | |
11609 | (inputs | |
11610 | `(("openssh" ,openssh))) | |
11611 | (propagated-inputs | |
11612 | `(("python-paramiko" ,python-paramiko) | |
11613 | ("python-requests" ,python-requests))) | |
11614 | (native-inputs | |
11615 | `(("python-lockfile" ,python-lockfile) | |
11616 | ("python-mock" ,python-mock) | |
11617 | ("python-requests-mock" ,python-requests-mock))) | |
11618 | (home-page "https://libcloud.apache.org/") | |
11619 | (synopsis "Unified Cloud API") | |
11620 | (description "@code{libcloud} is a Python library for interacting with | |
11621 | many of the popular cloud service providers using a unified API.") | |
11622 | (license license:asl2.0))) | |
11623 | ||
11624 | (define-public python2-apache-libcloud | |
11625 | (package-with-python2 python-apache-libcloud)) | |
7fadeab4 DM |
11626 | |
11627 | (define-public python-smmap2 | |
11628 | (package | |
11629 | (name "python-smmap2") | |
11630 | (version "2.0.3") | |
11631 | (source | |
11632 | (origin | |
11633 | (method url-fetch) | |
11634 | (uri (pypi-uri "smmap2" version)) | |
11635 | (sha256 | |
11636 | (base32 | |
11637 | "1hvn28p3zvxa98sbi9lrqvv2ps4q284j4jq9a619zw0m7yv0sly7")))) | |
11638 | (build-system python-build-system) | |
11639 | (native-inputs | |
11640 | `(("python-nosexcover" ,python-nosexcover))) | |
11641 | (home-page "https://github.com/Byron/smmap") | |
11642 | (synopsis "Python sliding window memory map manager") | |
11643 | (description "@code{smmap2} is a pure Python implementation of a sliding | |
11644 | window memory map manager.") | |
11645 | (license license:bsd-3))) | |
11646 | ||
11647 | (define-public python2-smmap2 | |
11648 | (package-with-python2 python-smmap2)) | |
fa3f5f47 RJ |
11649 | |
11650 | (define-public python-regex | |
11651 | (package | |
11652 | (name "python-regex") | |
11653 | (version "2017.06.07") | |
11654 | (source (origin | |
11655 | (method url-fetch) | |
11656 | (uri (pypi-uri "regex" version)) | |
11657 | (sha256 | |
11658 | (base32 | |
11659 | "06r6b7yigikbj3a72whl85r2b64pj1r0ypmw9yalmkm0wnxq8mz4")))) | |
11660 | (build-system python-build-system) | |
11661 | (home-page "https://bitbucket.org/mrabarnett/mrab-regex") | |
11662 | (synopsis "Alternative regular expression module") | |
11663 | (description "This regular expression implementation is backwards- | |
11664 | compatible with the standard @code{re} module, but offers additional | |
11665 | functionality like full case-folding for case-insensitive matches in Unicode.") | |
11666 | (license license:psfl))) | |
11667 | ||
11668 | (define-public python2-regex | |
11669 | (package-with-python2 python-regex)) | |
f817b4d9 RH |
11670 | |
11671 | (define-public python2-pyopengl | |
11672 | (package | |
11673 | (name "python2-pyopengl") | |
11674 | (version "3.1.0") | |
11675 | (source | |
11676 | (origin | |
11677 | (method url-fetch) | |
11678 | (uri (pypi-uri "PyOpenGL" version)) | |
11679 | (sha256 | |
11680 | (base32 | |
11681 | "1byxjj6a8rwzhxhjqlc588zdad2qwxdd7vlam2653ylll31waiwv")))) | |
11682 | (arguments | |
11683 | `(#:python ,python-2)) | |
11684 | (build-system python-build-system) | |
11685 | (home-page "http://pyopengl.sourceforge.net") | |
11686 | (synopsis "Standard OpenGL bindings for Python") | |
11687 | (description | |
11688 | "PyOpenGL is the most common cross platform Python binding to OpenGL and | |
11689 | related APIs. The binding is created using the standard @code{ctypes} | |
11690 | library.") | |
11691 | (license license:bsd-3))) | |
7efd98be | 11692 | |
97c26793 RH |
11693 | (define-public python2-pyopengl-accelerate |
11694 | (package | |
11695 | (inherit python2-pyopengl) | |
11696 | (name "python2-pyopengl-accelerate") | |
11697 | (version "3.1.0") | |
11698 | (source | |
11699 | (origin | |
11700 | (method url-fetch) | |
11701 | (uri (pypi-uri "PyOpenGL-accelerate" version)) | |
11702 | (sha256 | |
11703 | (base32 | |
11704 | "0464c1ifzk0k92lyndikmvzjgnx1y25r7bkkc8pnxm4kp1q4czwj")))) | |
11705 | (synopsis "Acceleration code for PyOpenGL") | |
11706 | (description | |
11707 | "This is the Cython-coded accelerator module for PyOpenGL."))) | |
11708 | ||
7efd98be RH |
11709 | (define-public python-rencode |
11710 | (package | |
11711 | (name "python-rencode") | |
11712 | (version "1.0.3") | |
11713 | (source | |
11714 | (origin | |
11715 | (method url-fetch) | |
11716 | (uri (pypi-uri "rencode" version)) | |
11717 | (sha256 | |
11718 | (base32 | |
11719 | "08if5yax1xn5yfp8p3765ccjmfcv9di7i4m5jckgnwvdsgznwkbj")))) | |
11720 | (build-system python-build-system) | |
11721 | (native-inputs `(("pkg-config" ,pkg-config) | |
11722 | ("python-cython", python-cython))) | |
11723 | (home-page "https://github.com/aresch/rencode") | |
11724 | (synopsis "Serialization of heterogeneous data structures") | |
11725 | (description | |
11726 | "The @code{rencode} module is a data structure serialization library, | |
11727 | similar to @code{bencode} from the BitTorrent project. For complex, | |
11728 | heterogeneous data structures with many small elements, r-encoding stake up | |
11729 | significantly less space than b-encodings. This version of rencode is a | |
11730 | complete rewrite in Cython to attempt to increase the performance over the | |
11731 | pure Python module.") | |
11732 | (license license:bsd-3))) | |
11733 | ||
11734 | (define-public python2-rencode | |
11735 | (package-with-python2 python-rencode)) | |
9ea61b1c | 11736 | |
2038a48f MFM |
11737 | (define-public python-xenon |
11738 | (package | |
11739 | (name "python-xenon") | |
11740 | (version "0.5.1") | |
11741 | (source | |
11742 | (origin | |
11743 | (method url-fetch) | |
11744 | (uri (pypi-uri "xenon" version)) | |
11745 | (sha256 | |
11746 | (base32 | |
11747 | "14kby2y48vp3sgwxqlm5d5789yibqwb1qli5fwcmdqg3iayrbklc")))) | |
11748 | (build-system python-build-system) | |
11749 | (native-inputs | |
11750 | `(("python-pyyaml" ,python-pyyaml) | |
11751 | ("python-radon" ,python-radon) | |
11752 | ("python-requests" ,python-requests) | |
11753 | ("python-flake8" ,python-flake8) | |
11754 | ("python-tox" ,python-tox))) | |
11755 | (arguments | |
11756 | `(#:phases | |
11757 | (modify-phases %standard-phases | |
11758 | (add-before 'build 'patch-test-requirements | |
11759 | (lambda* (#:key inputs #:allow-other-keys) | |
11760 | ;; Update requirements from dependency==version to | |
11761 | ;; dependency>=version. | |
11762 | (substitute* "requirements.txt" | |
11763 | (("==") ">=") | |
11764 | ((",<1.5.0") "")) | |
11765 | ;; Remove httpretty dependency for tests. | |
11766 | (substitute* "setup.py" | |
11767 | (("httpretty") "")) | |
11768 | #t))))) | |
11769 | (home-page "https://xenon.readthedocs.org/") | |
11770 | (synopsis "Monitor code metrics for Python on your CI server") | |
11771 | (description | |
11772 | "Xenon is a monitoring tool based on Radon. It monitors code complexity. | |
11773 | Ideally, @code{xenon} is run every time code is committed. Through command | |
11774 | line options, various thresholds can be set for the complexity of code. It | |
11775 | will fail (i.e. it will exit with a non-zero exit code) when any of these | |
11776 | requirements is not met.") | |
11777 | (license license:expat))) | |
11778 | ||
11779 | (define-public python2-xenon | |
11780 | (package-with-python2 python-xenon)) | |
11781 | ||
07e62ae1 CZ |
11782 | (define-public python-pysocks |
11783 | (package | |
11784 | (name "python-pysocks") | |
11785 | (version "1.6.7") | |
11786 | (source | |
11787 | (origin | |
11788 | (method url-fetch) | |
11789 | (uri (pypi-uri "PySocks" version)) | |
11790 | (sha256 | |
11791 | (base32 | |
11792 | "1krkiss578zqwcg4c8iqz1hwscwhsvy2djp3xyvps5gsgvr2j0yh")))) | |
11793 | (build-system python-build-system) | |
11794 | (arguments `(#:tests? #f)) | |
11795 | (home-page "https://github.com/Anorov/PySocks") | |
11796 | (synopsis "SOCKS client module") | |
11797 | (description "@code{pysocks} is an updated and semi-actively maintained | |
11798 | version of @code{SocksiPy} with bug fixes and extra features.") | |
11799 | (license license:bsd-3))) | |
11800 | ||
11801 | (define-public python2-pysocks | |
11802 | (package-with-python2 python-pysocks)) | |
7a276cd9 | 11803 | |
ab7f51fa CR |
11804 | (define-public python-pydiff |
11805 | (package | |
11806 | (name "python-pydiff") | |
11807 | (version "0.2") | |
11808 | (source | |
11809 | (origin | |
11810 | (method url-fetch) | |
11811 | (uri (pypi-uri "pydiff" version)) | |
11812 | (sha256 | |
11813 | (base32 | |
11814 | "1als83h9w0gab24ipyna6khm390qmpnpkc5jksmdbs2xc8hp2z44")))) | |
11815 | (build-system python-build-system) | |
11816 | (home-page "https://github.com/myint/pydiff") | |
11817 | (synopsis "Library to diff two Python files at the bytecode level") | |
11818 | (description | |
11819 | "@code{pydiff} makes it easy to look for actual code changes while | |
11820 | ignoring formatting changes.") | |
11821 | (license license:expat))) | |
11822 | ||
11823 | (define-public python2-pydiff | |
11824 | (package-with-python2 python-pydiff)) | |
8e6ceb47 | 11825 | |
b84ef9e2 CR |
11826 | (define-public python-tqdm |
11827 | (package | |
11828 | (name "python-tqdm") | |
11829 | (version "4.15.0") | |
11830 | (source | |
11831 | (origin | |
11832 | (method url-fetch) | |
11833 | (uri (pypi-uri "tqdm" version)) | |
11834 | (sha256 | |
11835 | (base32 | |
11836 | "0lwrmby8qz23gvqwkpivfrv4q8nfh90cz9ml6slwvwmcxxsdrhbf")))) | |
11837 | (build-system python-build-system) | |
11838 | (native-inputs | |
11839 | `(("python-flake8" ,python-flake8) | |
11840 | ("python-nose" ,python-nose) | |
11841 | ("python-nose-timer" ,python-nose-timer) | |
11842 | ("python-coverage" ,python-coverage) | |
11843 | ("python-virtualenv" ,python-virtualenv))) | |
11844 | (home-page "https://github.com/tqdm/tqdm") | |
11845 | (synopsis "Fast, extensible progress meter") | |
11846 | (description | |
11847 | "Make loops show a progress bar on the console by just wrapping any | |
11848 | iterable with @code{|tqdm(iterable)|}. Offers many options to define | |
11849 | design and layout.") | |
11850 | (license (list license:mpl2.0 license:expat)))) | |
11851 | ||
11852 | (define-public python2-tqdm | |
11853 | (package-with-python2 python-tqdm)) | |
78f46e65 CR |
11854 | |
11855 | (define-public python-pkginfo | |
11856 | (package | |
11857 | (name "python-pkginfo") | |
11858 | (version "1.4.1") | |
11859 | (source | |
11860 | (origin | |
11861 | (method url-fetch) | |
11862 | (uri (pypi-uri "pkginfo" version)) | |
11863 | (sha256 | |
11864 | (base32 | |
11865 | "17pqjfpq3c6xzdmk8pski6jcjgjv78q00zjf2bgzb668pzm6l6mv")))) | |
11866 | (build-system python-build-system) | |
11867 | (arguments | |
11868 | ;; The tests are broken upstream. | |
11869 | '(#:tests? #f)) | |
11870 | (home-page | |
11871 | "https://code.launchpad.net/~tseaver/pkginfo/trunk") | |
11872 | (synopsis | |
11873 | "Query metadatdata from sdists, bdists, and installed packages") | |
11874 | (description | |
11875 | "API to query the distutils metadata written in @file{PKG-INFO} inside a | |
11876 | source distriubtion (an sdist) or a binary distribution (e.g., created by | |
11877 | running bdist_egg). It can also query the EGG-INFO directory of an installed | |
11878 | distribution, and the *.egg-info stored in a \"development checkout\" (e.g, | |
11879 | created by running @code{python setup.py develop}).") | |
11880 | (license license:expat))) | |
11881 | ||
11882 | (define-public python2-pkginfo | |
11883 | (package-with-python2 python-pkginfo)) | |
3ef85c11 CR |
11884 | |
11885 | (define-public python-twine | |
11886 | (package | |
11887 | (name "python-twine") | |
11888 | (version "1.9.1") | |
11889 | (source | |
11890 | (origin | |
11891 | (method url-fetch) | |
11892 | (uri (pypi-uri "twine" version)) | |
11893 | (sha256 | |
11894 | (base32 | |
11895 | "1ay1b6kdq6k4bfbjsvf6ymj41wrgpvinhxndb09355pwhxwmp96a")))) | |
11896 | (build-system python-build-system) | |
11897 | (propagated-inputs | |
11898 | `(("python-tqdm" ,python-tqdm) | |
11899 | ("python-pkginfo", python-pkginfo) | |
11900 | ("python-requests" ,python-requests) | |
11901 | ("python-requests-toolbelt" ,python-requests-toolbelt))) | |
11902 | (home-page "https://github.com/pypa/twine") | |
11903 | (synopsis "Collection of utilities for interacting with PyPI") | |
11904 | (description | |
11905 | "@code{twine} currently supports registering projects and uploading | |
11906 | distributions. It authenticates the user over HTTPS, allows them to pre-sign | |
11907 | their files and supports any packaging format (including wheels).") | |
11908 | (license license:asl2.0))) | |
11909 | ||
11910 | (define-public python2-twine | |
11911 | (package-with-python2 python-twine)) | |
ab28aa22 CR |
11912 | |
11913 | (define-public python-linecache2 | |
11914 | (package | |
11915 | (name "python-linecache2") | |
11916 | (version "1.0.0") | |
11917 | (source | |
11918 | (origin | |
11919 | (method url-fetch) | |
11920 | (uri (pypi-uri "linecache2" version)) | |
11921 | (sha256 | |
11922 | (base32 | |
11923 | "0z79g3ds5wk2lvnqw0y2jpakjf32h95bd9zmnvp7dnqhf57gy9jb")))) | |
11924 | (build-system python-build-system) | |
11925 | (arguments | |
11926 | `(;; The tests depend on unittest2, and our version is a bit too old. | |
11927 | #:tests? #f)) | |
11928 | (native-inputs | |
11929 | `(("python-pbr" ,python-pbr))) | |
11930 | (home-page | |
11931 | "https://github.com/testing-cabal/linecache2") | |
11932 | (synopsis "Backports of the linecache module") | |
11933 | (description | |
11934 | "The linecache module allows one to get any line from any file, while | |
11935 | attempting to optimize internally, using a cache, the common case where many | |
11936 | lines are read from a single file.") | |
11937 | (license license:psfl))) | |
11938 | ||
11939 | (define-public python2-linecache2 | |
11940 | (package-with-python2 python-linecache2)) | |
1898eaa3 CR |
11941 | |
11942 | (define-public python-traceback2 | |
11943 | (package | |
11944 | (name "python-traceback2") | |
11945 | (version "1.4.0") | |
11946 | (source | |
11947 | (origin | |
11948 | (method url-fetch) | |
11949 | (uri (pypi-uri "traceback2" version)) | |
11950 | (sha256 | |
11951 | (base32 | |
11952 | "0c1h3jas1jp1fdbn9z2mrgn3jj0hw1x3yhnkxp7jw34q15xcdb05")))) | |
11953 | (build-system python-build-system) | |
11954 | (arguments | |
11955 | `(;; python-traceback2 and python-unittest2 depend on one another. | |
11956 | #:tests? #f)) | |
11957 | (native-inputs | |
11958 | `(("python-pbr" ,python-pbr))) | |
11959 | (propagated-inputs | |
11960 | `(("python-linecache2" ,python-linecache2))) | |
11961 | (home-page | |
11962 | "https://github.com/testing-cabal/traceback2") | |
11963 | (synopsis "Backports of the traceback module") | |
11964 | (description | |
11965 | "This module provides a standard interface to extract, format and print | |
11966 | stack traces of Python programs. It exactly mimics the behavior of the Python | |
11967 | interpreter when it prints a stack trace.") | |
11968 | (license license:psfl))) | |
11969 | ||
11970 | (define-public python2-traceback2 | |
11971 | (package-with-python2 python-traceback2)) | |
9d0866ce KM |
11972 | |
11973 | (define-public python-ratelimiter | |
11974 | (package | |
11975 | (name "python-ratelimiter") | |
11976 | (version "1.2.0") | |
11977 | (source | |
11978 | (origin | |
11979 | (method url-fetch) | |
11980 | (uri (pypi-uri "ratelimiter" version)) | |
11981 | (sha256 | |
11982 | (base32 | |
11983 | "1dhz85mj5bqd2mij84ncs6pz32hgidr79hay4aqfmzaa4rbb497p")))) | |
11984 | (build-system python-build-system) | |
11985 | (arguments | |
11986 | '(#:tests? #f)) ; There are no tests in the pypi archive. | |
11987 | (home-page "https://github.com/RazerM/ratelimiter") | |
11988 | (synopsis "Simple rate limiting object") | |
11989 | (description | |
11990 | "The @code{ratelimiter} module ensures that an operation will not be | |
11991 | executed more than a given number of times during a given period.") | |
11992 | (license license:asl2.0))) | |
11993 | ||
11994 | (define-public python2-ratelimiter | |
11995 | (package-with-python2 python-ratelimiter)) | |
2e15906c BT |
11996 | |
11997 | (define-public python-dukpy | |
11998 | (package | |
11999 | (name "python-dukpy") | |
12000 | (version "0.3") | |
12001 | (source | |
12002 | (origin | |
12003 | (method url-fetch) | |
12004 | (uri (string-append "https://github.com/kovidgoyal/dukpy/archive/v" | |
12005 | version ".tar.gz")) | |
12006 | (sha256 | |
12007 | (base32 | |
12008 | "0pj39rfwlzivqm5hkrsza7gssg6ggpxlq5ivc8f3h7x5pfgc6y6c")))) | |
12009 | (build-system python-build-system) | |
12010 | (home-page "https://github.com/kovidgoyal/dukpy") | |
12011 | (synopsis "Run JavaScript in python") | |
12012 | (description | |
12013 | "dukpy is a JavaScript runtime environment for Python using the duktape | |
12014 | embeddable JavaScript engine.") | |
12015 | ;; Dukpy is licensed under MIT like the embedded duktape library, | |
12016 | ;; with 'errors.c' as GPL3. | |
12017 | (license (list license:expat license:gpl3)))) | |
12018 | ||
12019 | (define-public python2-dukpy | |
12020 | (package-with-python2 python-dukpy)) | |
ea0421bb CZ |
12021 | |
12022 | (define-public python-jsonrpclib-pelix | |
12023 | (package | |
12024 | (name "python-jsonrpclib-pelix") | |
12025 | (version "0.3.1") | |
12026 | (source | |
12027 | (origin | |
12028 | (method url-fetch) | |
12029 | (uri (pypi-uri "jsonrpclib-pelix" version)) | |
12030 | (sha256 | |
12031 | (base32 | |
12032 | "1qs95vxplxwspbrqy8bvc195s58iy43qkf75yrjfql2sim8b25sl")))) | |
12033 | (build-system python-build-system) | |
12034 | (home-page "https://github.com/tcalmant/jsonrpclib/") | |
12035 | (synopsis "JSON-RPC 2.0 client library for Python") | |
12036 | (description | |
12037 | "This library implements the JSON-RPC v2.0 | |
12038 | specification (backwards-compatible) as a client library for Python. This | |
12039 | version is a fork of jsonrpclib by Josh Marshall, usable with Pelix remote | |
12040 | services.") | |
12041 | (license license:asl2.0))) | |
12042 | ||
12043 | (define-public python2-jsonrpclib-pelix | |
12044 | (package-with-python2 python-jsonrpclib-pelix)) | |
9b3c7520 | 12045 | |
12046 | (define-public python-setuptools-scm-git-archive | |
12047 | (package | |
12048 | (name "python-setuptools-scm-git-archive") | |
12049 | (version "1.0") | |
12050 | (source | |
12051 | (origin | |
12052 | (method url-fetch) | |
12053 | (uri (pypi-uri "setuptools_scm_git_archive" version)) | |
12054 | (sha256 | |
12055 | (base32 | |
12056 | "1nii1sz5jq75ilf18bjnr11l9rz1lvdmyk66bxl7q90qan85yhjj")))) | |
12057 | (build-system python-build-system) | |
12058 | (native-inputs | |
12059 | `(("python-pytest-3.0" ,python-pytest-3.0))) | |
12060 | (propagated-inputs | |
12061 | `(("python-setuptools-scm" ,python-setuptools-scm))) | |
12062 | (home-page "https://github.com/Changaco/setuptools_scm_git_archive/") | |
12063 | (synopsis "Setuptools_scm plugin for git archives") | |
12064 | (description | |
12065 | "The setuptools_scm_git_archive package is a plugin to | |
12066 | setuptools_scm, which supports obtaining versions from git archives that | |
12067 | belong to tagged versions.") | |
12068 | (license license:expat))) | |
12069 | ||
12070 | (define-public python2-setuptools-scm-git-archive | |
12071 | (package-with-python2 python-setuptools-scm-git-archive)) | |
a39211fe | 12072 | |
12073 | (define-public python-pyclipper | |
12074 | (package | |
12075 | (name "python-pyclipper") | |
12076 | (version "1.0.6") | |
12077 | (source | |
12078 | (origin | |
12079 | (method url-fetch) | |
12080 | (uri (pypi-uri "pyclipper" version ".zip")) | |
12081 | (sha256 | |
12082 | (base32 | |
12083 | "1zpmwv3bya3j984y5cf9x9d5108kf6mxldcba68wiq0frv5qrssw")))) | |
12084 | (build-system python-build-system) | |
12085 | (arguments | |
12086 | `(#:tests? #f)); 8 Tests fail, 37 succeed | |
12087 | (propagated-inputs | |
12088 | `(("python-setuptools-scm-git-archive" ,python-setuptools-scm-git-archive))) | |
12089 | (native-inputs | |
12090 | `(("unzip" ,unzip))) | |
12091 | (home-page "https://github.com/greginvm/pyclipper") | |
12092 | (synopsis "Wrapper for Angus Johnson's Clipper library") | |
12093 | (description | |
12094 | "Pyclipper is a Cython wrapper for the C++ translation of the | |
12095 | Angus Johnson's polygon clipping Clipper library (ver. 6.2.1).") | |
12096 | (license license:expat))) | |
12097 | ||
12098 | (define-public python2-pyclipper | |
12099 | (package-with-python2 python-pyclipper)) | |
76040f71 | 12100 | |
12101 | (define-public python2-booleanoperations | |
12102 | (package | |
12103 | (name "python2-booleanoperations") | |
12104 | (version "0.7.1") | |
12105 | (source | |
12106 | (origin | |
12107 | (method url-fetch) | |
12108 | (uri (pypi-uri "booleanOperations" version ".zip")) | |
12109 | (sha256 | |
12110 | (base32 | |
12111 | "1hw42fazdpvsn77glx96hwsj9l17mvx37sc5707s08y5w6fx16mn")))) | |
12112 | (build-system python-build-system) | |
12113 | (arguments | |
12114 | `(#:python ,python-2)) | |
12115 | (native-inputs | |
12116 | `(("unzip" ,unzip) | |
12117 | ("python2-pytest-3.0" ,python2-pytest-3.0) | |
12118 | ("python2-pytest-runner" ,python2-pytest-runner))) | |
12119 | (propagated-inputs | |
12120 | `(("python-fonttools" ,python2-fonttools) | |
12121 | ("python-pyclipper" ,python2-pyclipper) | |
12122 | ("python-ufolib" ,python2-ufolib))) | |
12123 | (home-page "https://github.com/typemytype/booleanOperations") | |
12124 | (synopsis "Boolean operations on paths") | |
12125 | (description | |
12126 | "BooleanOperations provides a Python library that enables | |
12127 | boolean operations on paths.") | |
12128 | (license license:expat))) | |
c521c8f1 KH |
12129 | |
12130 | (define-public python-tempdir | |
12131 | (package | |
12132 | (name "python-tempdir") | |
12133 | (version "0.7.1") | |
12134 | (source | |
12135 | (origin | |
12136 | (method url-fetch) | |
12137 | (uri (pypi-uri "tempdir" version)) | |
12138 | (sha256 | |
12139 | (base32 | |
12140 | "13msyyxqbicr111a294x7fsqbkl6a31fyrqflx3q7k547gnq15k8")))) | |
12141 | (build-system python-build-system) | |
12142 | (home-page "https://pypi.org/project/tempdir/") | |
12143 | (arguments | |
12144 | ;; the package has no tests | |
12145 | '(#:tests? #f)) | |
12146 | (synopsis "Python library for managing temporary directories") | |
12147 | (description | |
12148 | "This library manages temporary directories that are automatically | |
12149 | deleted with all their contents when they are no longer needed. It is | |
12150 | particularly convenient for use in tests.") | |
12151 | (license license:expat))) | |
12152 | ||
12153 | (define-public python2-tempdir | |
12154 | (package-with-python2 python-tempdir)) | |
12155 | ||
de2032b9 KH |
12156 | (define-public python-activepapers |
12157 | (package | |
12158 | (name "python-activepapers") | |
12159 | (version "0.2.2") | |
12160 | (source | |
12161 | (origin | |
12162 | (method url-fetch) | |
12163 | (uri (pypi-uri "ActivePapers.Py" version)) | |
12164 | (sha256 | |
12165 | (base32 | |
12166 | "12wkhjh90ffipjzv10swndp2xv9hd7xrxvg6v0n4n3i411pj4xb8")))) | |
12167 | (build-system python-build-system) | |
12168 | (arguments | |
12169 | `(#:modules ((ice-9 ftw) | |
12170 | (srfi srfi-1) | |
12171 | (guix build utils) | |
12172 | (guix build python-build-system)) | |
12173 | ||
12174 | #:phases | |
12175 | (modify-phases %standard-phases | |
12176 | (add-after 'unpack 'delete-python2-code | |
12177 | (lambda _ | |
12178 | (for-each delete-file | |
12179 | '("lib/activepapers/builtins2.py" | |
12180 | "lib/activepapers/standardlib2.py" | |
12181 | "lib/activepapers/utility2.py")))) | |
12182 | (replace 'check | |
12183 | (lambda _ | |
12184 | ;; Deactivate the test cases that download files | |
12185 | (setenv "NO_NETWORK_ACCESS" "1") | |
12186 | ;; For some strange reason, some tests fail if nosetests runs all | |
12187 | ;; test modules in a single execution. They pass if each test | |
12188 | ;; module is run individually. | |
12189 | (for-each (lambda (filename) | |
12190 | (invoke "nosetests" | |
12191 | (string-append "tests/" filename))) | |
12192 | (scandir "tests" | |
12193 | (lambda (filename) | |
12194 | (string-suffix? ".py" filename))))))))) | |
12195 | (native-inputs | |
12196 | `(("python-tempdir" ,python-tempdir) | |
12197 | ("python-nose" ,python-nose))) | |
12198 | (propagated-inputs | |
12199 | `(("python-h5py" ,python-h5py))) | |
12200 | (home-page "http://www.activepapers.org/") | |
12201 | (synopsis "Executable papers for scientific computing") | |
12202 | (description | |
12203 | "ActivePapers is a tool for working with executable papers, which | |
12204 | combine data, code, and documentation in single-file packages, | |
12205 | suitable for publication as supplementary material or on repositories | |
12206 | such as figshare or Zenodo.") | |
12207 | (properties `((python2-variant . ,(delay python2-activepapers)))) | |
12208 | (license license:bsd-3))) | |
12209 | ||
12210 | (define-public python2-activepapers | |
12211 | (let ((base (package-with-python2 | |
12212 | (strip-python2-variant python-activepapers)))) | |
12213 | (package | |
12214 | (inherit base) | |
12215 | (arguments | |
12216 | (substitute-keyword-arguments (package-arguments base) | |
12217 | ((#:phases phases) | |
12218 | `(modify-phases ,phases | |
12219 | (delete 'delete-python2-code) | |
12220 | (add-after 'unpack 'delete-python3-code | |
12221 | (lambda _ | |
12222 | (for-each delete-file | |
12223 | '("lib/activepapers/builtins3.py" | |
12224 | "lib/activepapers/standardlib3.py" | |
12225 | "lib/activepapers/utility3.py"))))))))))) | |
467cfaa3 DM |
12226 | |
12227 | (define-public python-semver | |
12228 | (package | |
12229 | (name "python-semver") | |
12230 | (version "2.7.9") | |
12231 | (source | |
12232 | (origin | |
12233 | (method url-fetch) | |
12234 | (uri (pypi-uri "semver" version)) | |
12235 | (sha256 | |
12236 | (base32 | |
12237 | "0hhgqppchv59rqj0yzi1prdg2nfsywqmjsqy2rycyxm0hvxmbyqz")))) | |
12238 | (build-system python-build-system) | |
12239 | (arguments | |
12240 | `(#:phases | |
12241 | (modify-phases %standard-phases | |
12242 | (add-after 'unpack 'patch-test-requirements | |
12243 | (lambda _ | |
12244 | (substitute* "setup.py" | |
12245 | ;; Our Python is new enough. | |
12246 | (("'virtualenv<14\\.0\\.0'") "'virtualenv'")) | |
12247 | #t))))) | |
12248 | (native-inputs | |
12249 | `(("python-tox" ,python-tox) | |
12250 | ("python-virtualenv" ,python-virtualenv))) | |
12251 | (home-page "https://github.com/k-bx/python-semver") | |
12252 | (synopsis "Python helper for Semantic Versioning") | |
12253 | (description "This package provides a Python library for | |
12254 | @url{Semantic Versioning, http://semver.org/}.") | |
12255 | (license license:bsd-3))) | |
12256 | ||
12257 | (define-public python2-semver | |
12258 | (package-with-python2 python-semver)) | |
965ced9c KH |
12259 | |
12260 | (define-public python2-pyro | |
12261 | (package | |
12262 | (name "python2-pyro") | |
12263 | (version "3.16") | |
12264 | (source | |
12265 | (origin | |
12266 | (method url-fetch) | |
12267 | (uri (pypi-uri "Pyro" version)) | |
12268 | (file-name (string-append "Pyro-" version ".tar.gz")) | |
12269 | (sha256 | |
12270 | (base32 | |
12271 | "0y75wzdqbjy565rpxaxscav4j8xg060sa90lnmb7aypgaf251v8v")))) | |
12272 | (build-system python-build-system) | |
12273 | (arguments | |
12274 | ;; Pyro is not compatible with Python 3 | |
12275 | `(#:python ,python-2 | |
12276 | ;; Pyro has no test cases for automatic execution | |
12277 | #:tests? #f)) | |
12278 | (home-page "http://pythonhosted.org/Pyro/") | |
12279 | (synopsis "Distributed object manager for Python") | |
12280 | (description "Pyro is a Distributed Object Technology system | |
12281 | written in Python that is designed to be easy to use. It resembles | |
12282 | Java's Remote Method Invocation (RMI). It has less similarity to CORBA, | |
12283 | which is a system and language independent Distributed Object Technology | |
12284 | and has much more to offer than Pyro or RMI. Pyro 3.x is no | |
12285 | longer maintained. New projects should use Pyro4 instead, which | |
12286 | is the new Pyro version that is actively developed.") | |
12287 | (license license:expat))) | |
49aebf96 KH |
12288 | |
12289 | (define-public python2-scientific | |
12290 | (package | |
12291 | (name "python2-scientific") | |
12292 | (version "2.9.4") | |
12293 | (source | |
12294 | (origin | |
12295 | (method url-fetch) | |
12296 | (uri (string-append "https://bitbucket.org/khinsen/" | |
12297 | "scientificpython/downloads/ScientificPython-" | |
12298 | version ".tar.gz")) | |
12299 | (file-name (string-append "ScientificPython-" version ".tar.gz")) | |
12300 | (sha256 | |
12301 | (base32 | |
12302 | "0fc69zhlsn9d2jvbzyjl9ah53vj598h84nkq230c83ahfvgzx5y3")))) | |
12303 | (build-system python-build-system) | |
12304 | (inputs | |
12305 | `(("netcdf" ,netcdf))) | |
12306 | (propagated-inputs | |
12307 | `(("python-numpy" ,python2-numpy-1.8) | |
12308 | ("python-pyro", python2-pyro))) | |
12309 | (arguments | |
12310 | ;; ScientificPython is not compatible with Python 3 | |
12311 | `(#:python ,python-2 | |
12312 | #:tests? #f ; No test suite | |
12313 | #:phases | |
12314 | (modify-phases %standard-phases | |
12315 | (replace 'build | |
12316 | (lambda* (#:key inputs #:allow-other-keys) | |
12317 | (zero? (system* "python" "setup.py" "build" | |
12318 | (string-append "--netcdf_prefix=" | |
12319 | (assoc-ref inputs "netcdf"))))))))) | |
12320 | (home-page "https://bitbucket.org/khinsen/scientificpython") | |
12321 | (synopsis "Python modules for scientific computing") | |
12322 | (description "ScientificPython is a collection of Python modules that are | |
12323 | useful for scientific computing. Most modules are rather general (Geometry, | |
12324 | physical units, automatic derivatives, ...) whereas others are more | |
12325 | domain-specific (e.g. netCDF and PDB support). The library is currently | |
12326 | not actively maintained and works only with Python 2 and NumPy < 1.9.") | |
12327 | (license license:cecill-c))) | |
42d6bffc KH |
12328 | |
12329 | (define-public python2-mmtk | |
12330 | (package | |
12331 | (name "python2-mmtk") | |
12332 | (version "2.7.10") | |
12333 | (source | |
12334 | (origin | |
12335 | (method url-fetch) | |
12336 | (uri (string-append "https://bitbucket.org/khinsen/" | |
12337 | "mmtk/downloads/MMTK-" version ".tar.gz")) | |
12338 | (file-name (string-append "MMTK-" version ".tar.gz")) | |
12339 | (sha256 | |
12340 | (base32 | |
12341 | "1k4gsd50zja89dbzgy3aji7h4zpvbvdfrds7rxr3whqrsgcffnir")))) | |
12342 | (build-system python-build-system) | |
12343 | (native-inputs | |
12344 | `(("netcdf" ,netcdf))) | |
12345 | (propagated-inputs | |
12346 | `(("python-scientific" ,python2-scientific) | |
12347 | ("python-tkinter" ,python-2 "tk"))) | |
12348 | (arguments | |
12349 | `(#:python ,python-2 | |
12350 | #:tests? #f | |
12351 | #:phases | |
12352 | (modify-phases %standard-phases | |
12353 | (add-before 'build 'includes-from-scientific | |
12354 | (lambda* (#:key inputs #:allow-other-keys) | |
12355 | (mkdir-p "Include/Scientific") | |
12356 | (copy-recursively | |
12357 | (string-append | |
12358 | (assoc-ref inputs "python-scientific") | |
12359 | "/include/python2.7/Scientific") | |
12360 | "Include/Scientific")))))) | |
12361 | (home-page "http://dirac.cnrs-orleans.fr/MMTK") | |
12362 | (synopsis "Python library for molecular simulation") | |
12363 | (description "MMTK is a library for molecular simulations with an emphasis | |
12364 | on biomolecules. It provides widely used methods such as Molecular Dynamics | |
12365 | and normal mode analysis, but also basic routines for implementing new methods | |
12366 | for simulation and analysis. The library is currently not actively maintained | |
12367 | and works only with Python 2 and NumPy < 1.9.") | |
12368 | (license license:cecill-c))) |