diff options
Diffstat (limited to 'pkgs/development/python-modules')
13 files changed, 268 insertions, 21 deletions
diff --git a/pkgs/development/python-modules/cherrypy/default.nix b/pkgs/development/python-modules/cherrypy/default.nix index 6941e1117bdc..17531f1406d1 100644 --- a/pkgs/development/python-modules/cherrypy/default.nix +++ b/pkgs/development/python-modules/cherrypy/default.nix @@ -7,29 +7,24 @@ buildPythonPackage rec { pname = "cherrypy"; - version = "18.1.2"; + version = "18.3.0"; disabled = !isPy3k; src = fetchPypi { pname = "CherryPy"; inherit version; - sha256 = "1w3hpsg7q8shdmscmbqk00w90lcw3brary7wl1a56k5h7nx33pj8"; + sha256 = "0q6cs4vrv0rwim4byxfizrlp4h6hmwg3n4baz0ga66vvgiz6hgk8"; }; - # Remove patches once 96b34df and 14c12d2 + # Remove patches once 88d2163 and 713f672 # become part of a release - they're currently only present in master. - # ref: https://github.com/cherrypy/cherrypy/pull/1791 + # ref: https://github.com/cherrypy/cherrypy/pull/1820 patches = [ (fetchpatch { - name = "pytest5-1.patch"; - url = "https://github.com/cherrypy/cherrypy/commit/96b34dfea7853b0189bc0a3878b6ddff0d4e505c.patch"; - sha256 = "0zy53mahffgkpd844118b42lsk5lkjmig70d60x1i46w6gnr61mi"; - }) - (fetchpatch { - name = "pytest5-2.patch"; - url = "https://github.com/cherrypy/cherrypy/commit/14c12d2420a4b3765bb241250bd186e93b2f25eb.patch"; - sha256 = "0ihcz7b5myn923rq5665b98pz52hnf6fcys2y2inf23r3i07scyz"; + name = "test_HTTP11_Timeout.patch"; + url = "https://github.com/cherrypy/cherrypy/commit/88d21630f68090c56d07000cabb6df4f1b612a71.patch"; + sha256 = "1i6a3qs3ijyd9rgsxb8axigkzdlmr5sl3ljif9rvn0d90211bzwh"; }) ]; diff --git a/pkgs/development/python-modules/labelbox/default.nix b/pkgs/development/python-modules/labelbox/default.nix new file mode 100644 index 000000000000..18578da764ef --- /dev/null +++ b/pkgs/development/python-modules/labelbox/default.nix @@ -0,0 +1,31 @@ +{ lib +, buildPythonPackage +, fetchPypi +, requests +, jinja2 +, pillow +, rasterio +, shapely +}: + +buildPythonPackage rec { + pname = "labelbox"; + version = "2.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "f97f01bf030b115d8b7f7b12a10ec5efe54750ad66b6b3567550b517a543ad11"; + }; + + propagatedBuildInputs = [ jinja2 requests pillow rasterio shapely ]; + + # Test cases are not running on pypi or GitHub + doCheck = false; + + meta = with lib; { + homepage = https://github.com/Labelbox/Labelbox; + description = "Platform API for LabelBox"; + license = licenses.asl20; + maintainers = with maintainers; [ rakesh4g ]; + }; +} diff --git a/pkgs/development/python-modules/minio/default.nix b/pkgs/development/python-modules/minio/default.nix index 966255dade26..623a191bbb8e 100644 --- a/pkgs/development/python-modules/minio/default.nix +++ b/pkgs/development/python-modules/minio/default.nix @@ -1,5 +1,5 @@ { lib, buildPythonPackage, isPy3k, fetchPypi -, urllib3, python-dateutil , pytz, faker, mock, nose }: +, urllib3, future, python-dateutil , pytz, faker, mock, nose }: buildPythonPackage rec { pname = "minio"; @@ -13,7 +13,7 @@ buildPythonPackage rec { disabled = !isPy3k; checkInputs = [ faker mock nose ]; - propagatedBuildInputs = [ urllib3 python-dateutil pytz ]; + propagatedBuildInputs = [ urllib3 python-dateutil pytz future ]; meta = with lib; { description = "Simple APIs to access any Amazon S3 compatible object storage server"; diff --git a/pkgs/development/python-modules/nbdime/default.nix b/pkgs/development/python-modules/nbdime/default.nix new file mode 100644 index 000000000000..25605a217274 --- /dev/null +++ b/pkgs/development/python-modules/nbdime/default.nix @@ -0,0 +1,69 @@ +{ lib, buildPythonPackage, fetchPypi, callPackage, isPy3k +, hypothesis +, setuptools_scm +, six +, attrs +, py +, setuptools +, pytestcov +, pytest-timeout +, pytest-tornado +, mock +, tabulate +, nbformat +, jsonschema +, pytest +, colorama +, pygments +, tornado +, requests +, GitPython +, notebook +, jinja2 +}: + +buildPythonPackage rec { + pname = "nbdime"; + version = "1.0.6"; + disabled = !isPy3k; + + src = fetchPypi { + inherit pname version; + sha256 = "00nywb69kp9i0wl5mczgwqc5db8v70ihr9cjbwqppd2jkx4vf34j"; + }; + + checkInputs = [ + hypothesis + pytestcov + pytest-timeout + pytest-tornado + jsonschema + mock + tabulate + pytest + ]; + + nativeBuildInputs = [ setuptools_scm ]; + + propagatedBuildInputs = [ + attrs + py + setuptools + six + nbformat + colorama + pygments + tornado + requests + GitPython + notebook + jinja2 + ]; + + meta = with lib; { + homepage = https://github.com/jupyter/nbdime; + description = "Tools for diffing and merging of Jupyter notebooks."; + license = licenses.bsd3; + maintainers = with maintainers; [ tbenst ]; + }; +} diff --git a/pkgs/development/python-modules/nix-prefetch-github/default.nix b/pkgs/development/python-modules/nix-prefetch-github/default.nix new file mode 100644 index 000000000000..71a7701c0194 --- /dev/null +++ b/pkgs/development/python-modules/nix-prefetch-github/default.nix @@ -0,0 +1,32 @@ +{ fetchPypi +, lib +, buildPythonPackage +, attrs +, click +, effect +, jinja2 +}: + +buildPythonPackage rec { + pname = "nix-prefetch-github"; + version = "2.3.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "1jkvmj33xinff0sb47yg33n131yi93pyq86skqc78xd38j6c8q9s"; + }; + + propagatedBuildInputs = [ + attrs + click + effect + jinja2 + ]; + + meta = with lib; { + description = "Prefetch sources from github"; + homepage = https://github.com/seppeljordan/nix-prefetch-github; + license = licenses.gpl3; + maintainers = with maintainers; [ seppeljordan ]; + }; +} diff --git a/pkgs/development/python-modules/opentracing/default.nix b/pkgs/development/python-modules/opentracing/default.nix new file mode 100644 index 000000000000..8e771f2d46a8 --- /dev/null +++ b/pkgs/development/python-modules/opentracing/default.nix @@ -0,0 +1,34 @@ +{ lib +, buildPythonPackage +, fetchPypi +, isPy27 +, futures +, gevent +, mock +, pytest +, tornado }: + +buildPythonPackage rec { + pname = "opentracing"; + version = "2.2.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "cfd231ba5c58f90bc277787e62861eb0c6e4af76e42957bec240bbdf71fb7e0e"; + }; + + propagatedBuildInputs = lib.optional isPy27 futures; + + checkInputs = [ gevent mock pytest tornado ]; + + checkPhase = '' + pytest + ''; + + meta = with lib; { + homepage = https://github.com/opentracing/opentracing-python; + description = "Platform API for OpenTracing"; + license = licenses.asl20; + maintainers = with maintainers; [ rakesh4g ]; + }; +} diff --git a/pkgs/development/python-modules/parsley/default.nix b/pkgs/development/python-modules/parsley/default.nix new file mode 100644 index 000000000000..17e05b6027f2 --- /dev/null +++ b/pkgs/development/python-modules/parsley/default.nix @@ -0,0 +1,22 @@ +{ buildPythonPackage +, fetchPypi +, lib +}: + +buildPythonPackage rec { + pname = "Parsley"; + version = "1.3"; + src = fetchPypi { + inherit pname version; + sha256 = "0hcd41bl07a8sx7nmx12p16xprnblc4phxkawwmmy78n8y6jfi4l"; + }; + # Tests fail although the package works just fine. Unfortunately + # the tests as run by the upstream CI server travis.org are broken. + doCheck = false; + meta = with lib; { + license = licenses.mit; + homepage = "https://launchpad.net/parsley"; + description = "A parser generator library based on OMeta, and other useful parsing tools."; + maintainers = with maintainers; [ seppeljordan ]; + }; +} diff --git a/pkgs/development/python-modules/py3status/default.nix b/pkgs/development/python-modules/py3status/default.nix index 142c7cc22570..79b80fb11f0c 100644 --- a/pkgs/development/python-modules/py3status/default.nix +++ b/pkgs/development/python-modules/py3status/default.nix @@ -9,6 +9,7 @@ , pygobject3 , pyserial , setuptools +, dbus-python , file , acpi @@ -32,7 +33,7 @@ buildPythonPackage rec { doCheck = false; propagatedBuildInputs = [ - pytz requests tzlocal i3ipc pydbus pygobject3 pyserial setuptools + pytz requests tzlocal i3ipc pydbus pygobject3 pyserial setuptools dbus-python ]; buildInputs = [ file ]; prePatch = '' diff --git a/pkgs/development/python-modules/pycryptopp/default.nix b/pkgs/development/python-modules/pycryptopp/default.nix index 8bb472d8fde7..25ac99082c0a 100644 --- a/pkgs/development/python-modules/pycryptopp/default.nix +++ b/pkgs/development/python-modules/pycryptopp/default.nix @@ -1,6 +1,7 @@ { stdenv , buildPythonPackage , fetchPypi +, fetchpatch , isPy3k , setuptoolsDarcs , darcsver @@ -14,9 +15,19 @@ buildPythonPackage rec { src = fetchPypi { inherit pname version; - sha256 = "08ad57a1a39b7ed23c173692281da0b8d49d98ad3dcc09f8cca6d901e142699f"; + sha256 = "17v98bhh3nd6rkw0kk1xmnc9vm5ql0fji4in2wyd4zlvlfhmgb88"; }; + patches = [ + (fetchpatch { + name = "pycryptopp-cryptopp_6.patch"; + url = "https://aur.archlinux.org/cgit/aur.git/plain/api_change.patch?h=pycryptopp&id=55f2973d6ca5e9e70438f2eadb7fb575b1a5048d"; + sha256 = "0lvl2d32d2vkb0v6d39p9whda5bdrmlsjd41zy0x0znqm53a9i99"; + stripLen = 1; + extraPrefix = "src/"; + }) + ]; + # Prefer crypto++ library from the Nix store over the one that's included # in the pycryptopp distribution. preConfigure = "export PYCRYPTOPP_DISABLE_EMBEDDED_CRYPTOPP=1"; @@ -24,7 +35,7 @@ buildPythonPackage rec { buildInputs = [ setuptoolsDarcs darcsver pkgs.cryptopp ]; meta = with stdenv.lib; { - homepage = http://allmydata.org/trac/pycryptopp; + homepage = "https://tahoe-lafs.org/trac/pycryptopp"; description = "Python wrappers for the Crypto++ library"; license = licenses.gpl2Plus; platforms = platforms.linux; diff --git a/pkgs/development/python-modules/python-vlc/default.nix b/pkgs/development/python-modules/python-vlc/default.nix new file mode 100644 index 000000000000..2bf59a633411 --- /dev/null +++ b/pkgs/development/python-modules/python-vlc/default.nix @@ -0,0 +1,37 @@ +{ lib +, buildPythonPackage +, fetchPypi +, setuptools +, vlc +, substituteAll +}: + +buildPythonPackage rec { + pname = "python-vlc"; + version = "3.0.7110"; + + src = fetchPypi { + inherit pname version; + sha256 = "0ydnqwwgpwq1kz1pjrc7629ljzdd30izymjylsbzzyq8pq6wl6w2"; + }; + + propagatedBuildInputs = [ + setuptools + ]; + + patches = [ + (substituteAll { + src = ./vlc-paths.patch; + libvlcPath="${vlc}/lib/libvlc.so.5"; + }) + ]; + + doCheck = false; # no tests + + meta = with lib; { + homepage = "https://wiki.videolan.org/PythonBinding"; + maintainers = with maintainers; [ tbenst ]; + description = "Python bindings for VLC, the cross-platform multimedia player and framework"; + license = licenses.lgpl21Plus; + }; +} diff --git a/pkgs/development/python-modules/python-vlc/vlc-paths.patch b/pkgs/development/python-modules/python-vlc/vlc-paths.patch new file mode 100644 index 000000000000..0b1cf732711a --- /dev/null +++ b/pkgs/development/python-modules/python-vlc/vlc-paths.patch @@ -0,0 +1,13 @@ +diff --git a/vlc.py b/vlc.py +index e3245a5..cebec09 100644 +--- a/vlc.py ++++ b/vlc.py +@@ -190,7 +190,7 @@ def find_lib(): + + else: + # All other OSes (linux, freebsd...) +- p = find_library('vlc') ++ p = "@libvlcPath@" + try: + dll = ctypes.CDLL(p) + except OSError: # may fail diff --git a/pkgs/development/python-modules/snuggs/default.nix b/pkgs/development/python-modules/snuggs/default.nix index 017ea7e0d5fd..a97bbf4012c9 100644 --- a/pkgs/development/python-modules/snuggs/default.nix +++ b/pkgs/development/python-modules/snuggs/default.nix @@ -1,23 +1,23 @@ { buildPythonPackage, lib, fetchFromGitHub , click, numpy, pyparsing -, pytest +, pytest, hypothesis }: buildPythonPackage rec { pname = "snuggs"; - version = "1.4.3"; + version = "1.4.7"; # Pypi doesn't ship the tests, so we fetch directly from GitHub src = fetchFromGitHub { owner = "mapbox"; repo = pname; rev = version; - sha256 = "198nbgkhlg4ik2i1r2cp900iqlairh2hnii2y8v5wy1qk3rv0s9g"; + sha256 = "1p3lh9s2ylsnrzbs931y2vn7mp2y2xskgqmh767c9l1a33shfgwf"; }; propagatedBuildInputs = [ click numpy pyparsing ]; - checkInputs = [ pytest ]; + checkInputs = [ pytest hypothesis ]; checkPhase = "pytest test_snuggs.py"; meta = with lib; { diff --git a/pkgs/development/python-modules/worldengine/default.nix b/pkgs/development/python-modules/worldengine/default.nix index 103e2fc8defd..81c09bf74253 100644 --- a/pkgs/development/python-modules/worldengine/default.nix +++ b/pkgs/development/python-modules/worldengine/default.nix @@ -1,6 +1,7 @@ { stdenv , buildPythonPackage , pythonOlder +, isPy27 , fetchFromGitHub , nose , noise @@ -48,6 +49,7 @@ buildPythonPackage rec { # with python<3.5, unittest fails to discover tests because of their filenames # so nose is used instead. + doCheck = !isPy27; # google namespace clash checkInputs = stdenv.lib.optional (pythonOlder "3.5") [ nose ]; postCheck = stdenv.lib.optionalString (pythonOlder "3.5") '' nosetests tests |