From b549f18b6c10d256a40979af16060b00427efd1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 15:12:00 +0100 Subject: [PATCH 01/25] pythonPackages.CommonMark: move expression --- .../python-modules/commonmark/default.nix | 24 ++++++++++++++ pkgs/top-level/python-packages.nix | 33 ++++--------------- 2 files changed, 30 insertions(+), 27 deletions(-) create mode 100644 pkgs/development/python-modules/commonmark/default.nix diff --git a/pkgs/development/python-modules/commonmark/default.nix b/pkgs/development/python-modules/commonmark/default.nix new file mode 100644 index 000000000000..dcc741f87350 --- /dev/null +++ b/pkgs/development/python-modules/commonmark/default.nix @@ -0,0 +1,24 @@ +{ lib, buildPythonPackage, fetchPypi, flake8, glibcLocales, future }: + +buildPythonPackage rec { + pname = "CommonMark"; + version = "0.6.3"; + + src = fetchPypi { + inherit pname version; + sha256 = "ee5a88f23678794592efe3fc11033f17fc77b3296a85f5e1d5b715f8e110a773"; + }; + + LC_ALL="en_US.UTF-8"; + + doCheck = false; + + buildInputs = [ flake8 glibcLocales ]; + propagatedBuildInputs = [ future ]; + + meta = with lib; { + description = "Python parser for the CommonMark Markdown spec"; + homepage = https://github.com/rolandshoemaker/CommonMark-py; + license = licenses.bsd3; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 67a088731fe3..63f57ca27e56 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2347,36 +2347,15 @@ in { colorlover = callPackage ../development/python-modules/colorlover { }; - CommonMark = buildPythonPackage rec { - name = "CommonMark-${version}"; - version = "0.6.3"; + CommonMark = callPackage ../development/python-modules/commonmark { }; - src = pkgs.fetchurl { - url = "mirror://pypi/C/CommonMark/${name}.tar.gz"; - sha256 = "ee5a88f23678794592efe3fc11033f17fc77b3296a85f5e1d5b715f8e110a773"; - }; - - LC_ALL="en_US.UTF-8"; - - doCheck = false; - - buildInputs = with self; [ flake8 pkgs.glibcLocales ]; - propagatedBuildInputs = with self; [ future ]; - - meta = { - description = "Python parser for the CommonMark Markdown spec"; - homepage = https://github.com/rolandshoemaker/CommonMark-py; - license = licenses.bsd3; - }; - }; - - CommonMark_54 = self.CommonMark.override rec { - name = "CommonMark-0.5.4"; - src = pkgs.fetchurl { - url = "mirror://pypi/C/CommonMark/${name}.tar.gz"; + CommonMark_54 = self.CommonMark.overridePythonAttrs (oldAttrs: rec { + version = "0.5.4"; + src = oldAttrs.src.override { + inherit version; sha256 = "34d73ec8085923c023930dfc0bcd1c4286e28a2a82de094bb72fabcc0281cbe5"; }; - }; + }); coilmq = buildPythonPackage (rec { From d7d4ce735e74a435d026b2619bd5894aa2bc62c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 15:34:40 +0100 Subject: [PATCH 02/25] pythonPackages.CommonMark: 0.6.3 -> 0.7.5 --- .../python-modules/commonmark/default.nix | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/commonmark/default.nix b/pkgs/development/python-modules/commonmark/default.nix index dcc741f87350..d6cd69f6c8ae 100644 --- a/pkgs/development/python-modules/commonmark/default.nix +++ b/pkgs/development/python-modules/commonmark/default.nix @@ -1,19 +1,22 @@ -{ lib, buildPythonPackage, fetchPypi, flake8, glibcLocales, future }: +{ lib, buildPythonPackage, fetchPypi, isPy3k, glibcLocales, future }: buildPythonPackage rec { pname = "CommonMark"; - version = "0.6.3"; + version = "0.7.5"; src = fetchPypi { inherit pname version; - sha256 = "ee5a88f23678794592efe3fc11033f17fc77b3296a85f5e1d5b715f8e110a773"; + sha256 = "4dfbbd1dbc669a9b71a015032b2bbe5c4b019ca8b6ca410d89cf7020de46d2c0"; }; - LC_ALL="en_US.UTF-8"; + preCheck = '' + export LC_ALL="en_US.UTF-8" + ''; - doCheck = false; + # UnicodeEncodeError on Python 2 + doCheck = isPy3k; - buildInputs = [ flake8 glibcLocales ]; + checkInputs = [ glibcLocales ]; propagatedBuildInputs = [ future ]; meta = with lib; { From 9f276ccd3887c03523fe6655670bad50ac373929 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 15:42:09 +0100 Subject: [PATCH 03/25] pythonPackages.bleach: 2.1.2 -> 2.1.3 --- pkgs/development/python-modules/bleach/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/bleach/default.nix b/pkgs/development/python-modules/bleach/default.nix index e4ccb0c92d66..786564b92e01 100644 --- a/pkgs/development/python-modules/bleach/default.nix +++ b/pkgs/development/python-modules/bleach/default.nix @@ -9,11 +9,11 @@ buildPythonPackage rec { pname = "bleach"; - version = "2.1.2"; + version = "2.1.3"; src = fetchPypi { inherit pname version; - sha256 = "38fc8cbebea4e787d8db55d6f324820c7f74362b70db9142c1ac7920452d1a19"; + sha256 = "eb7386f632349d10d9ce9d4a838b134d4731571851149f9cc2c05a9a837a9a44"; }; checkInputs = [ pytest pytestrunner ]; @@ -41,4 +41,4 @@ buildPythonPackage rec { license = lib.licenses.asl20; maintainers = with lib.maintainers; [ prikhi ]; }; -} \ No newline at end of file +} From 922b0cec828d31799b975c1df103cc05666c56f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 15:42:52 +0100 Subject: [PATCH 04/25] pythonPackages.readme_renderer: 17.2 -> 17.4 --- .../python-modules/readme_renderer/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/readme_renderer/default.nix b/pkgs/development/python-modules/readme_renderer/default.nix index af0b64fc3404..d99829194939 100644 --- a/pkgs/development/python-modules/readme_renderer/default.nix +++ b/pkgs/development/python-modules/readme_renderer/default.nix @@ -2,6 +2,7 @@ , buildPythonPackage , fetchPypi , pytest +, CommonMark , bleach , docutils , pygments @@ -10,18 +11,17 @@ buildPythonPackage rec { pname = "readme_renderer"; - version = "17.2"; - name = "${pname}-${version}"; + version = "17.4"; src = fetchPypi { inherit pname version; - sha256 = "9deab442963a63a71ab494bf581b1c844473995a2357f4b3228a1df1c8cba8da"; + sha256 = "82d68175feec897af2a38fe8590778f14c3be5324cc62e3ce5752a9b1e4b60ab"; }; checkInputs = [ pytest ]; propagatedBuildInputs = [ - bleach docutils pygments six + CommonMark bleach docutils pygments six ]; checkPhase = '' @@ -33,4 +33,4 @@ buildPythonPackage rec { homepage = https://github.com/pypa/readme_renderer; license = lib.licenses.asl20; }; -} \ No newline at end of file +} From 7e8e3807f3b583898360311e210418c0479d1dd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 16:11:59 +0100 Subject: [PATCH 05/25] pythonPackages.moinmoin: disable for Python 3 --- pkgs/development/python-modules/moinmoin/default.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/moinmoin/default.nix b/pkgs/development/python-modules/moinmoin/default.nix index cedd45f2f225..6891dd2b6272 100644 --- a/pkgs/development/python-modules/moinmoin/default.nix +++ b/pkgs/development/python-modules/moinmoin/default.nix @@ -1,13 +1,16 @@ -{ lib, buildPythonPackage, fetchurl, fetchpatch +{ lib, buildPythonPackage, fetchurl, fetchpatch, isPy3k , pytest, werkzeug, pygments }: buildPythonPackage rec { - name = "moinmoin-${ver}"; - ver = "1.9.9"; + name = "moinmoin"; + version = "1.9.9"; + + # SyntaxError in setup.py + disabled = isPy3k; src = fetchurl { - url = "http://static.moinmo.in/files/moin-${ver}.tar.gz"; + url = "http://static.moinmo.in/files/moin-${version}.tar.gz"; sha256 = "197ga41qghykmir80ik17f9hjpmixslv3zjgj7bj9qvs1dvdg5s3"; }; From 127f99e22e23005a6cfcd2ce08b48bd8a9bbb137 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 16:46:11 +0100 Subject: [PATCH 06/25] pythonPackages.pushbullet: move expression --- .../python-modules/pushbullet/default.nix | 20 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 12 +---------- 2 files changed, 21 insertions(+), 11 deletions(-) create mode 100644 pkgs/development/python-modules/pushbullet/default.nix diff --git a/pkgs/development/python-modules/pushbullet/default.nix b/pkgs/development/python-modules/pushbullet/default.nix new file mode 100644 index 000000000000..c9cccc6733be --- /dev/null +++ b/pkgs/development/python-modules/pushbullet/default.nix @@ -0,0 +1,20 @@ +{ lib, buildPythonPackage, fetchPypi +, requests, websocket_client, python_magic }: + +buildPythonPackage rec { + pname = "pushbullet.py"; + version = "0.10.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "537d3132e1dbc91e31ade4cccf4c7def6f9d48e904a67f341d35b8a54a9be74d"; + }; + + propagatedBuildInputs = [ requests websocket_client python_magic ]; + + meta = with lib; { + description = "A simple python client for pushbullet.com"; + homepage = https://github.com/randomchars/pushbullet.py; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 63f57ca27e56..5a2cc8a49426 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -18718,17 +18718,7 @@ EOF }; }; - pushbullet = buildPythonPackage rec { - name = "pushbullet.py-${version}"; - version = "0.10.0"; - - src = pkgs.fetchurl { - url = "mirror://pypi/p/pushbullet.py/pushbullet.py-0.10.0.tar.gz"; - sha256 = "537d3132e1dbc91e31ade4cccf4c7def6f9d48e904a67f341d35b8a54a9be74d"; - }; - - propagatedBuildInputs = with self; [requests websocket_client python_magic ]; - }; + pushbullet = callPackage ../development/python-modules/pushbullet { }; power = buildPythonPackage rec { name = "power-1.4"; From 4e3538887851bc86aa7c37a920fe7f5b772cdfb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 16:53:31 +0100 Subject: [PATCH 07/25] pythonPackages.pushbullet: 0.10.0 -> 0.11.0 and fix build --- .../python-modules/pushbullet/default.nix | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/pushbullet/default.nix b/pkgs/development/python-modules/pushbullet/default.nix index c9cccc6733be..74c0f66b91eb 100644 --- a/pkgs/development/python-modules/pushbullet/default.nix +++ b/pkgs/development/python-modules/pushbullet/default.nix @@ -1,17 +1,24 @@ { lib, buildPythonPackage, fetchPypi -, requests, websocket_client, python_magic }: +, requests, websocket_client, python_magic +, pytest, mock }: buildPythonPackage rec { pname = "pushbullet.py"; - version = "0.10.0"; + version = "0.11.0"; src = fetchPypi { inherit pname version; - sha256 = "537d3132e1dbc91e31ade4cccf4c7def6f9d48e904a67f341d35b8a54a9be74d"; + sha256 = "aa9dc7bb46e083e3497d46241154f12944a8f540e29d150330ca94db0b453b8d"; }; propagatedBuildInputs = [ requests websocket_client python_magic ]; + checkInputs = [ pytest mock ]; + + checkPhase = '' + PUSHBULLET_API_KEY="" py.test -k "not test_e2e and not test_auth" + ''; + meta = with lib; { description = "A simple python client for pushbullet.com"; homepage = https://github.com/randomchars/pushbullet.py; From 104f58d6a1b08714e1357946c06e75c897327b1c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 16:57:00 +0100 Subject: [PATCH 08/25] pythonPackages.pyamf: disable for Python 3 --- pkgs/development/python-modules/pyamf/default.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/pyamf/default.nix b/pkgs/development/python-modules/pyamf/default.nix index 59acacd50517..5ac6ef82964c 100644 --- a/pkgs/development/python-modules/pyamf/default.nix +++ b/pkgs/development/python-modules/pyamf/default.nix @@ -1,10 +1,12 @@ -{ stdenv, fetchPypi, buildPythonPackage, defusedxml }: +{ stdenv, fetchPypi, buildPythonPackage, isPy3k, defusedxml }: buildPythonPackage rec { - name = "${pname}-${version}"; pname = "PyAMF"; version = "0.8.0"; + # according to setup.py + disabled = isPy3k; + src = fetchPypi { inherit pname version; sha256 = "1r3lp9gkph48g9lijby5rs5daa3lhxs204r14zw4kvp3hf4xcm84"; From ba5d1bb28bafe246f5edcf92c061bddb606baee2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 17:03:10 +0100 Subject: [PATCH 09/25] pythonPackages.paypalrestsdk: move expression --- .../python-modules/paypalrestsdk/default.nix | 19 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 17 +---------------- 2 files changed, 20 insertions(+), 16 deletions(-) create mode 100644 pkgs/development/python-modules/paypalrestsdk/default.nix diff --git a/pkgs/development/python-modules/paypalrestsdk/default.nix b/pkgs/development/python-modules/paypalrestsdk/default.nix new file mode 100644 index 000000000000..9c050ff9e1e9 --- /dev/null +++ b/pkgs/development/python-modules/paypalrestsdk/default.nix @@ -0,0 +1,19 @@ +{ buildPythonPackage, fetchPypi, httplib2 }: + +buildPythonPackage rec { + pname = "paypalrestsdk"; + version = "0.7.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "117kfipzfahf9ysv414bh1mmm5cc9ck5zb6rhpslx1f8gk3frvd6"; + }; + + propagatedBuildInputs = [ httplib2 ]; + + meta = { + homepage = https://developer.paypal.com/; + description = "Python APIs to create, process and manage payment"; + license = "PayPal SDK License"; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5a2cc8a49426..83b30f0ab868 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -11878,22 +11878,7 @@ in { pathpy = callPackage ../development/python-modules/path.py { }; - paypalrestsdk = buildPythonPackage rec { - name = "paypalrestsdk-0.7.0"; - - src = pkgs.fetchurl { - url = "mirror://pypi/p/paypalrestsdk/${name}.tar.gz"; - sha256 = "117kfipzfahf9ysv414bh1mmm5cc9ck5zb6rhpslx1f8gk3frvd6"; - }; - - propagatedBuildInputs = with self; [ httplib2 ]; - - meta = { - homepage = https://developer.paypal.com/; - description = "Python APIs to create, process and manage payment"; - license = "PayPal SDK License"; - }; - }; + paypalrestsdk = callPackage ../development/python-modules/paypalrestsdk { }; pbr = callPackage ../development/python-modules/pbr { }; From 5ec4b9d8190fa31052c536051a1291e4d005297c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 17:05:53 +0100 Subject: [PATCH 10/25] pythonPackages.paypalrestsdk: 0.7.0 -> 1.13.1 --- .../development/python-modules/paypalrestsdk/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/paypalrestsdk/default.nix b/pkgs/development/python-modules/paypalrestsdk/default.nix index 9c050ff9e1e9..dbc918e6c0dc 100644 --- a/pkgs/development/python-modules/paypalrestsdk/default.nix +++ b/pkgs/development/python-modules/paypalrestsdk/default.nix @@ -1,15 +1,16 @@ -{ buildPythonPackage, fetchPypi, httplib2 }: +{ buildPythonPackage, fetchPypi +, requests, six, pyopenssl }: buildPythonPackage rec { pname = "paypalrestsdk"; - version = "0.7.0"; + version = "1.13.1"; src = fetchPypi { inherit pname version; - sha256 = "117kfipzfahf9ysv414bh1mmm5cc9ck5zb6rhpslx1f8gk3frvd6"; + sha256 = "238713208031e8981bf70b3350b3d7f85ed64d34e0f21e4c1184444a546fee7f"; }; - propagatedBuildInputs = [ httplib2 ]; + propagatedBuildInputs = [ requests six pyopenssl ]; meta = { homepage = https://developer.paypal.com/; From 3394feaeeffdcff4f142d44bdda113e989714ad7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 18:49:06 +0100 Subject: [PATCH 11/25] pythonPackages.hvac: move expression --- .../python-modules/hvac/default.nix | 19 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 12 +----------- 2 files changed, 20 insertions(+), 11 deletions(-) create mode 100644 pkgs/development/python-modules/hvac/default.nix diff --git a/pkgs/development/python-modules/hvac/default.nix b/pkgs/development/python-modules/hvac/default.nix new file mode 100644 index 000000000000..067b816d58ea --- /dev/null +++ b/pkgs/development/python-modules/hvac/default.nix @@ -0,0 +1,19 @@ +{ lib, buildPythonPackage, fetchPypi, requests }: + +buildPythonPackage rec { + pname = "hvac"; + version = "0.2.15"; + + src = fetchPypi { + inherit pname version; + sha256 = "0qxa4g1ij1bj27mbp8l54lcr7d5krkb2rayisc6shkpf2b51ip4c"; + }; + + propagatedBuildInputs = [ requests ]; + + meta = with lib; { + description = "HashiCorp Vault API client"; + homepage = https://github.com/ianunruh/hvac; + license = licenses.asl20; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 83b30f0ab868..571d864e7e6c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -8389,17 +8389,7 @@ in { }; }; - hvac = buildPythonPackage rec { - name = "hvac-${version}"; - version = "0.2.15"; - - src = pkgs.fetchurl { - url = "https://pypi.python.org/packages/11/ba/6101780891b9d55f6174fa78b47d462c8c1f0cde34072b45fc39f7f8a77c/hvac-0.2.15.tar.gz"; - sha256 = "0qxa4g1ij1bj27mbp8l54lcr7d5krkb2rayisc6shkpf2b51ip4c"; - }; - - propagatedBuildInputs = with self; [ requests ]; - }; + hvac = callPackage ../development/python-modules/hvac { }; hypothesis = callPackage ../development/python-modules/hypothesis { }; From bc9dc2ccf1186f4c626104820379c7d2200f2e52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 19:19:32 +0100 Subject: [PATCH 12/25] pythonPackages.hvac: 0.2.15 -> 0.5.0 --- pkgs/development/python-modules/hvac/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/hvac/default.nix b/pkgs/development/python-modules/hvac/default.nix index 067b816d58ea..8bc54e9226cf 100644 --- a/pkgs/development/python-modules/hvac/default.nix +++ b/pkgs/development/python-modules/hvac/default.nix @@ -2,15 +2,18 @@ buildPythonPackage rec { pname = "hvac"; - version = "0.2.15"; + version = "0.5.0"; src = fetchPypi { inherit pname version; - sha256 = "0qxa4g1ij1bj27mbp8l54lcr7d5krkb2rayisc6shkpf2b51ip4c"; + sha256 = "2c9308334301daee3b5c6d56a032ca2c81eeb97d2777b73d795e201e8d037687"; }; propagatedBuildInputs = [ requests ]; + # Requires running a Vault server + doCheck = false; + meta = with lib; { description = "HashiCorp Vault API client"; homepage = https://github.com/ianunruh/hvac; From cc305174e233178f880b276447e459a71dcebab8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 17 Mar 2018 19:35:03 +0100 Subject: [PATCH 13/25] pythonPackages.scikitlearn: disable doctests fixes https://github.com/NixOS/nixpkgs/issues/35436 --- pkgs/development/python-modules/scikitlearn/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/scikitlearn/default.nix b/pkgs/development/python-modules/scikitlearn/default.nix index 6d32b056a0a9..00bdcae1b9a8 100644 --- a/pkgs/development/python-modules/scikitlearn/default.nix +++ b/pkgs/development/python-modules/scikitlearn/default.nix @@ -21,8 +21,9 @@ buildPythonPackage rec { LC_ALL="en_US.UTF-8"; # Disable doctests on OSX: https://github.com/scikit-learn/scikit-learn/issues/10213 + # Disable doctests everywhere: https://github.com/NixOS/nixpkgs/issues/35436 checkPhase = '' - HOME=$TMPDIR OMP_NUM_THREADS=1 nosetests ${stdenv.lib.optionalString stdenv.isDarwin "--doctest-options=+SKIP"} $out/${python.sitePackages}/sklearn/ + HOME=$TMPDIR OMP_NUM_THREADS=1 nosetests --doctest-options=+SKIP $out/${python.sitePackages}/sklearn/ ''; meta = with stdenv.lib; { From bd3280fbae09151db9368b8e11e4b4400ec13804 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 11:46:37 +0100 Subject: [PATCH 14/25] pythonPackages.python-ctags3: init at 1.2.4 --- .../python-modules/python-ctags3/default.nix | 17 +++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 19 insertions(+) create mode 100644 pkgs/development/python-modules/python-ctags3/default.nix diff --git a/pkgs/development/python-modules/python-ctags3/default.nix b/pkgs/development/python-modules/python-ctags3/default.nix new file mode 100644 index 000000000000..ba29154df3ad --- /dev/null +++ b/pkgs/development/python-modules/python-ctags3/default.nix @@ -0,0 +1,17 @@ +{ lib, buildPythonPackage, fetchPypi }: + +buildPythonPackage rec { + pname = "python-ctags3"; + version = "1.2.4"; + + src = fetchPypi { + inherit pname version; + sha256 = "62e1d48a8cd88756767f3f5e3f1b1a81bc84deeb736f0c9480a5b5d066f63c3e"; + }; + + meta = with lib; { + description = "Ctags indexing python bindings"; + homepage = https://github.com/jonashaag/python-ctags3; + license = licenses.lgpl3Plus; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 571d864e7e6c..6ee0aa377f22 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6107,6 +6107,8 @@ in { }; }; + python-ctags3 = callPackage ../development/python-modules/python-ctags3 { }; + junos-eznc = callPackage ../development/python-modules/junos-eznc {}; raven = callPackage ../development/python-modules/raven { }; From 19797d84642958122f911f1243bca15e5caf0c41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 12:25:09 +0100 Subject: [PATCH 15/25] klaus: move out of pythonPackages and 0.9.1 -> 1.2.2 --- pkgs/servers/web-apps/klaus/default.nix | 40 +++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ pkgs/top-level/python-packages.nix | 21 ------------- 3 files changed, 42 insertions(+), 21 deletions(-) create mode 100644 pkgs/servers/web-apps/klaus/default.nix diff --git a/pkgs/servers/web-apps/klaus/default.nix b/pkgs/servers/web-apps/klaus/default.nix new file mode 100644 index 000000000000..bb953ecc03ab --- /dev/null +++ b/pkgs/servers/web-apps/klaus/default.nix @@ -0,0 +1,40 @@ +{ lib, python, fetchFromGitHub }: + +python.pkgs.buildPythonApplication rec { + pname = "klaus"; + version = "1.2.2"; + + src = fetchFromGitHub { + owner = "jonashaag"; + repo = pname; + rev = version; + sha256 = "0hkl1ycyd5ccijmknr3yfp3ga43y01m7390xnibqqgaisfvcm9wp"; + }; + + prePatch = '' + substituteInPlace runtests.sh \ + --replace "mkdir -p \$builddir" "mkdir -p \$builddir && pwd" + ''; + + propagatedBuildInputs = with python.pkgs; [ + six flask pygments dulwich httpauth humanize + ]; + + checkInputs = with python.pkgs; [ + pytest requests python-ctags3 + ] ++ lib.optional (!isPy3k) mock; + + checkPhase = '' + ./runtests.sh + ''; + + # Needs to set up some git repos + doCheck = false; + + meta = with lib; { + description = "The first Git web viewer that Just Works"; + homepage = https://github.com/jonashaag/klaus; + license = licenses.isc; + maintainers = with maintainers; [ matthiasbeyer ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e8e6b9008295..15276ebe51a5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1276,6 +1276,8 @@ with pkgs; kisslicer = callPackage ../tools/misc/kisslicer { }; + klaus = callPackage ../servers/web-apps/klaus { }; + lcdproc = callPackage ../servers/monitoring/lcdproc { }; languagetool = callPackage ../tools/text/languagetool { }; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 6ee0aa377f22..75f88517d67f 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -8944,27 +8944,6 @@ in { keyutils = callPackage ../development/python-modules/keyutils { }; - klaus = buildPythonPackage rec { - version = "0.9.1"; - name = "klaus-${version}"; - - src = pkgs.fetchurl { - url = "https://github.com/jonashaag/klaus/archive/${version}.tar.gz"; - sha256 = "0k3v3p56hq8alm083grrp98znxkz1zqx0pczm2lah8qddbyrdkgm"; - }; - - propagatedBuildInputs = with self; - [ humanize httpauth dulwich pygments flask six ]; - - meta = { - description = "The first Git web viewer that Just Works"; - homepage = "https://github.com/jonashaag/klaus"; - #license = licenses.mit; # I'm not sure about the license - maintainers = with maintainers; [ matthiasbeyer ]; - platforms = platforms.linux; # Can only test linux - }; - }; - klein = buildPythonPackage rec { name = "klein-15.3.1"; src = pkgs.fetchurl { From 0b6a2b20371061a6771bb909f336bd1e35d6e221 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 12:36:09 +0100 Subject: [PATCH 16/25] pythonPackages.odo: mark as broken Odo is incompatible with Networkx 2. See https://github.com/blaze/odo/pull/601. --- pkgs/development/python-modules/odo/default.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/odo/default.nix b/pkgs/development/python-modules/odo/default.nix index fc3747ac59ae..f18420b676b7 100644 --- a/pkgs/development/python-modules/odo/default.nix +++ b/pkgs/development/python-modules/odo/default.nix @@ -37,5 +37,8 @@ buildPythonPackage rec { description = "Data migration utilities"; license = lib.licenses.bsdOriginal; maintainers = with lib.maintainers; [ fridh ]; + # incomaptible with Networkx 2 + # see https://github.com/blaze/odo/pull/601 + broken = true; }; -} \ No newline at end of file +} From 14ed0f5fe0953c990d080abb97611bd0bf8cabf7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 12:53:48 +0100 Subject: [PATCH 17/25] pythonPackages.credstash: fix build This applies https://github.com/fugue/credstash/pull/178. --- pkgs/development/python-modules/credstash/default.nix | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/credstash/default.nix b/pkgs/development/python-modules/credstash/default.nix index 6a9e1240b864..8be1780aa992 100644 --- a/pkgs/development/python-modules/credstash/default.nix +++ b/pkgs/development/python-modules/credstash/default.nix @@ -1,15 +1,20 @@ -{ stdenv, buildPythonPackage, fetchPypi, cryptography, boto3, pyyaml, docutils }: +{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, cryptography, boto3, pyyaml, docutils }: buildPythonPackage rec { - pname = "credstash"; + pname = "credstash"; version = "1.14.0"; - name = "${pname}-${version}"; src = fetchPypi { inherit pname version; sha256 = "718b337f7a6fa001e014386071f05c59900525d0507009126d2fe8d75fe0761d"; }; + patches = fetchpatch { + url = https://github.com/fugue/credstash/pull/178.patch; + sha256 = "15ih4h5v63g7qfmqdl4zca147wkcrx8vnsh4ns33001dipcfb5sc"; + excludes = [ ".travis.yml" ]; + }; + propagatedBuildInputs = [ cryptography boto3 pyyaml docutils ]; # No tests in archive From 97e54c4f758c3032c9da94cdca45981127a042f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 12:55:27 +0100 Subject: [PATCH 18/25] pythonPackages.pyhomematic: disable tests because of unreliable timimg --- pkgs/development/python-modules/pyhomematic/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkgs/development/python-modules/pyhomematic/default.nix b/pkgs/development/python-modules/pyhomematic/default.nix index 1191b09ec389..be6fb7c8bb61 100644 --- a/pkgs/development/python-modules/pyhomematic/default.nix +++ b/pkgs/development/python-modules/pyhomematic/default.nix @@ -14,6 +14,9 @@ buildPythonPackage rec { sha256 = "1g181x2mrhxcaswr6vi2m7if97wv4rf2g2pny60334sciga8njfz"; }; + # Unreliable timing: https://github.com/danielperna84/pyhomematic/issues/126 + doCheck = false; + meta = with stdenv.lib; { description = "Python 3 Interface to interact with Homematic devices"; homepage = https://github.com/danielperna84/pyhomematic; From 097dd635facf9be587edba59ae63ad0b37a2ad3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 13:03:29 +0100 Subject: [PATCH 19/25] pythonPackages.pyshphere: uninit Build is broken and project is unmaintained since 2013. --- pkgs/top-level/python-packages.nix | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 75f88517d67f..2327aaea4001 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -13862,23 +13862,6 @@ in { }; }; - pysphere = buildPythonPackage rec { - name = "pysphere-0.1.8"; - - src = pkgs.fetchurl { - url = "http://pysphere.googlecode.com/files/${name}.zip"; - sha256 = "b3f9ba1f67afb17ac41725b01737cd42e8a39d9e745282dd9b692ae631af0add"; - }; - - disabled = isPy3k; - - meta = { - homepage = "https://code.google.com/p/pysphere/"; - license = "BSD"; - description = "Python API for interaction with the VMWare vSphere"; - }; - }; - pysqlite = buildPythonPackage rec { name = "pysqlite-2.8.3"; From bd7a7bd817367b3c77f7184ca9fbca6e437d321e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 13:17:58 +0100 Subject: [PATCH 20/25] pythonPackages.allpairspy: init at 2.4.0 --- .../python-modules/allpairspy/default.nix | 25 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 27 insertions(+) create mode 100644 pkgs/development/python-modules/allpairspy/default.nix diff --git a/pkgs/development/python-modules/allpairspy/default.nix b/pkgs/development/python-modules/allpairspy/default.nix new file mode 100644 index 000000000000..e21b43c60e0d --- /dev/null +++ b/pkgs/development/python-modules/allpairspy/default.nix @@ -0,0 +1,25 @@ +{ lib, buildPythonPackage, fetchPypi, six, pytest }: + +buildPythonPackage rec { + pname = "allpairspy"; + version = "2.4.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "9fb7962ee523bd96c5098cd3c97ac1b8eb73021d3df9314657ee9de00f52e034"; + }; + + propagatedBuildInputs = [ six ]; + + checkInputs = [ pytest ]; + + checkPhase = '' + py.test + ''; + + meta = with lib; { + description = "Pairwise test combinations generator"; + homepage = https://github.com/thombashi/allpairspy; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2327aaea4001..de559564edf7 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -456,6 +456,8 @@ in { alembic = callPackage ../development/python-modules/alembic {}; + allpairspy = callPackage ../development/python-modules/allpairspy { }; + ansicolors = callPackage ../development/python-modules/ansicolors {}; aniso8601 = callPackage ../development/python-modules/aniso8601 {}; From edc94294c89d1f3f1188e7192578e83efbbda8eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 13:19:44 +0100 Subject: [PATCH 21/25] pythonPackages.robomachine: fix build --- .../python-modules/robomachine/default.nix | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/robomachine/default.nix b/pkgs/development/python-modules/robomachine/default.nix index 72407131cb15..f29cafb7aeed 100644 --- a/pkgs/development/python-modules/robomachine/default.nix +++ b/pkgs/development/python-modules/robomachine/default.nix @@ -1,16 +1,15 @@ -{ stdenv, fetchurl, buildPythonPackage, pyparsing, argparse, robotframework }: +{ stdenv, fetchPypi, buildPythonPackage, pyparsing, argparse, robotframework, allpairspy }: buildPythonPackage rec { - pname = "robomachine"; + pname = "RoboMachine"; version = "0.8.0"; - name = pname + "-" + version; - src = fetchurl { - url = "mirror://pypi/R/RoboMachine/RoboMachine-0.6.tar.gz"; + src = fetchPypi { + inherit pname version; sha256 = "242cfd9be0f7591138eaeba03c9c190f894ce045e1767ab7b90eca330259fc45"; }; - propagatedBuildInputs = [ pyparsing argparse robotframework ]; + propagatedBuildInputs = [ pyparsing argparse robotframework allpairspy ]; # Remove Windows .bat files postInstall = '' From a6cbdeaef3b29c3d83c5524c1143b92c998f6927 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 15:47:04 +0100 Subject: [PATCH 22/25] pythonPackages.colander: move expression --- .../python-modules/colander/default.nix | 21 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 16 +------------- 2 files changed, 22 insertions(+), 15 deletions(-) create mode 100644 pkgs/development/python-modules/colander/default.nix diff --git a/pkgs/development/python-modules/colander/default.nix b/pkgs/development/python-modules/colander/default.nix new file mode 100644 index 000000000000..f286d1a99508 --- /dev/null +++ b/pkgs/development/python-modules/colander/default.nix @@ -0,0 +1,21 @@ +{ lib, buildPythonPackage, fetchPypi +, translationstring, iso8601 }: + +buildPythonPackage rec { + pname = "colander"; + version = "1.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "7389413266b9e680c9529c16d56284edf87e0d5de557948e75f41d65683c23b3"; + }; + + propagatedBuildInputs = [ translationstring iso8601 ]; + + meta = with lib; { + description = "A simple schema-based serialization and deserialization library"; + homepage = https://docs.pylonsproject.org/projects/colander/en/latest/; + license = licenses.free; # http://repoze.org/LICENSE.txt + maintainers = with maintainers; [ garbas domenkozar ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index de559564edf7..1f9e1275fa3e 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2384,21 +2384,7 @@ in { }); - colander = buildPythonPackage rec { - name = "colander-1.0"; - - src = pkgs.fetchurl { - url = "mirror://pypi/c/colander/${name}.tar.gz"; - sha256 = "7389413266b9e680c9529c16d56284edf87e0d5de557948e75f41d65683c23b3"; - }; - - propagatedBuildInputs = with self; [ self.translationstring self.iso8601 ]; - - meta = { - maintainers = with maintainers; [ garbas domenkozar ]; - platforms = platforms.all; - }; - }; + colander = callPackage ../development/python-modules/colander { }; # Backported version of the ConfigParser library of Python 3.3 configparser = if isPy3k then null else buildPythonPackage rec { From 93b10cd879f41ff2913acf20c969e450384b3582 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 15:47:52 +0100 Subject: [PATCH 23/25] pythonPackages.colander: 1.0 -> 1.4 --- pkgs/development/python-modules/colander/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/colander/default.nix b/pkgs/development/python-modules/colander/default.nix index f286d1a99508..ed27464d1fe0 100644 --- a/pkgs/development/python-modules/colander/default.nix +++ b/pkgs/development/python-modules/colander/default.nix @@ -3,11 +3,11 @@ buildPythonPackage rec { pname = "colander"; - version = "1.0"; + version = "1.4"; src = fetchPypi { inherit pname version; - sha256 = "7389413266b9e680c9529c16d56284edf87e0d5de557948e75f41d65683c23b3"; + sha256 = "e20e9acf190e5711cf96aa65a5405dac04b6e841028fc361d953a9923dbc4e72"; }; propagatedBuildInputs = [ translationstring iso8601 ]; From 4779989c4e2a577d1a3af3b4152bdb073e1a8df5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 16:04:52 +0100 Subject: [PATCH 24/25] pythonPackages.dlib: fix build --- pkgs/top-level/python-packages.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 1f9e1275fa3e..27ce2cf7ee14 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -1463,6 +1463,8 @@ in { inherit (pkgs.dlib) name src nativeBuildInputs meta; buildInputs = pkgs.dlib.buildInputs ++ [ self.boost ]; + + checkInputs = with self; [ pytest ]; }; datadog = buildPythonPackage rec { From 5c897bdd59ad1bc117cdee4b9c39cb8f43bcd64e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sun, 18 Mar 2018 16:12:48 +0100 Subject: [PATCH 25/25] pythonPackages.flake8-debugger: fix build --- .../flake8-debugger/default.nix | 21 +++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/flake8-debugger/default.nix b/pkgs/development/python-modules/flake8-debugger/default.nix index 9d69c0389b69..32e9a08b7414 100644 --- a/pkgs/development/python-modules/flake8-debugger/default.nix +++ b/pkgs/development/python-modules/flake8-debugger/default.nix @@ -1,15 +1,24 @@ -{ lib, fetchurl, buildPythonPackage, flake8, nose }: +{ lib, fetchPypi, buildPythonPackage, flake8, pycodestyle, pytestrunner, pytest }: buildPythonPackage rec { pname = "flake8-debugger"; - name = "${pname}-${version}"; version = "3.1.0"; - src = fetchurl { - url = "mirror://pypi/f/flake8-debugger/${name}.tar.gz"; + + src = fetchPypi { + inherit pname version; sha256 = "be4fb88de3ee8f6dd5053a2d347e2c0a2b54bab6733a2280bb20ebd3c4ca1d97"; }; - buildInputs = [ nose ]; - propagatedBuildInputs = [ flake8 ]; + + nativeBuildInputs = [ pytestrunner ]; + + propagatedBuildInputs = [ flake8 pycodestyle ]; + + checkInputs = [ pytest ]; + + # Tests not included in PyPI tarball + # FIXME: Remove when https://github.com/JBKahn/flake8-debugger/pull/15 is merged + doCheck = false; + meta = { homepage = https://github.com/jbkahn/flake8-debugger; description = "ipdb/pdb statement checker plugin for flake8";