From 43795b2cea7af32ce12ed0f388a24dafa6de0f68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 10 Feb 2018 10:29:11 +0100 Subject: [PATCH 1/5] python3Packages.aiohttp: clean up dependencies --- pkgs/development/python-modules/aiohttp/default.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/aiohttp/default.nix b/pkgs/development/python-modules/aiohttp/default.nix index bea839f49e3d..f831679294a4 100644 --- a/pkgs/development/python-modules/aiohttp/default.nix +++ b/pkgs/development/python-modules/aiohttp/default.nix @@ -9,7 +9,6 @@ , idna-ssl , pytest , gunicorn -, pytest-raisesregexp , pytest-mock }: @@ -24,7 +23,7 @@ buildPythonPackage rec { disabled = pythonOlder "3.4"; - checkInputs = [ pytest gunicorn pytest-raisesregexp pytest-mock ]; + checkInputs = [ pytest gunicorn pytest-mock ]; propagatedBuildInputs = [ async-timeout chardet multidict yarl ] ++ lib.optional (pythonOlder "3.7") idna-ssl; From 585a5c1634f6e3c32ccb4654b66a0279a665b1ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 10 Feb 2018 10:38:20 +0100 Subject: [PATCH 2/5] python3Packages.multidict: clean up dependencies --- pkgs/development/python-modules/multidict/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/multidict/default.nix b/pkgs/development/python-modules/multidict/default.nix index 7eaa0962b44f..38facc966589 100644 --- a/pkgs/development/python-modules/multidict/default.nix +++ b/pkgs/development/python-modules/multidict/default.nix @@ -1,8 +1,7 @@ { lib , fetchPypi , buildPythonPackage -, cython -, pytest, psutil, pytestrunner +, pytest, pytestrunner , isPy3k }: @@ -15,8 +14,7 @@ buildPythonPackage rec { sha256 = "0liazqlyk2nmr82nhiw2z72j7bjqxaisifkj476msw140d4i4i7v"; }; - buildInputs = [ cython ]; - checkInputs = [ pytest psutil pytestrunner ]; + checkInputs = [ pytest pytestrunner ]; disabled = !isPy3k; From 56224e27af56a5ca62917b73c2bfc90f943aa862 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 10 Feb 2018 10:44:33 +0100 Subject: [PATCH 3/5] pythonPackages.chardet: clean up --- pkgs/development/python-modules/chardet/default.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/chardet/default.nix b/pkgs/development/python-modules/chardet/default.nix index 7e50dca40660..1f452fb461a4 100644 --- a/pkgs/development/python-modules/chardet/default.nix +++ b/pkgs/development/python-modules/chardet/default.nix @@ -2,7 +2,6 @@ , pytest, pytestrunner, hypothesis }: buildPythonPackage rec { - name = "${pname}-${version}"; pname = "chardet"; version = "3.0.4"; @@ -11,7 +10,7 @@ buildPythonPackage rec { sha256 = "1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4"; }; - buildInputs = [ pytest pytestrunner hypothesis ]; + checkInputs = [ pytest pytestrunner hypothesis ]; meta = with stdenv.lib; { homepage = https://github.com/chardet/chardet; From 5ca63e04624bd6afd54c1a3d5315550c9ad2c606 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 10 Feb 2018 11:05:27 +0100 Subject: [PATCH 4/5] python3Packages.async-timeout: clean up --- .../python-modules/async_timeout/default.nix | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/async_timeout/default.nix b/pkgs/development/python-modules/async_timeout/default.nix index 650517d44d92..53010a2a031d 100644 --- a/pkgs/development/python-modules/async_timeout/default.nix +++ b/pkgs/development/python-modules/async_timeout/default.nix @@ -1,22 +1,19 @@ { lib -, fetchurl +, fetchPypi , buildPythonPackage , pytestrunner , pythonOlder }: -let +buildPythonPackage rec { pname = "async-timeout"; version = "2.0.0"; -in buildPythonPackage rec { - name = "${pname}-${version}"; - src = fetchurl { - url = "mirror://pypi/${builtins.substring 0 1 pname}/${pname}/${name}.tar.gz"; + src = fetchPypi { + inherit pname version; sha256 = "c17d8ac2d735d59aa62737d76f2787a6c938f5a944ecf768a8c0ab70b0dea566"; }; - buildInputs = [ pytestrunner ]; # Circular dependency on aiohttp doCheck = false; @@ -27,4 +24,4 @@ in buildPythonPackage rec { homepage = https://github.com/aio-libs/async_timeout/; license = lib.licenses.asl20; }; -} \ No newline at end of file +} From 520eaac3c310fff3cf5d0762761d3d68e596de00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 10 Feb 2018 11:37:12 +0100 Subject: [PATCH 5/5] pythonPackages.pytest_xdist: enable tests for python2 --- .../python-modules/pytest-xdist/default.nix | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/pkgs/development/python-modules/pytest-xdist/default.nix b/pkgs/development/python-modules/pytest-xdist/default.nix index d671fd9654a4..596ce38ed0ab 100644 --- a/pkgs/development/python-modules/pytest-xdist/default.nix +++ b/pkgs/development/python-modules/pytest-xdist/default.nix @@ -1,7 +1,6 @@ { stdenv, fetchPypi, buildPythonPackage, isPy3k, execnet, pytest, setuptools_scm, pytest-forked }: buildPythonPackage rec { - name = "${pname}-${version}"; pname = "pytest-xdist"; version = "1.22.0"; @@ -10,21 +9,19 @@ buildPythonPackage rec { sha256 = "65228a859191f2c74ee68c127317eefe35eedd3d43fc1431f19240663b0cafcd"; }; - buildInputs = [ pytest setuptools_scm pytest-forked]; + nativeBuildInputs = [ setuptools_scm ]; + buildInputs = [ pytest pytest-forked ]; propagatedBuildInputs = [ execnet ]; - postPatch = '' - rm testing/acceptance_test.py testing/test_remote.py testing/test_slavemanage.py - ''; - checkPhase = '' - py.test testing + # Excluded tests access file system + py.test testing -k "not test_distribution_rsyncdirs_example \ + and not test_rsync_popen_with_path \ + and not test_popen_rsync_subdir \ + and not test_init_rsync_roots \ + and not test_rsyncignore" ''; - # Only test on 3.x - # INTERNALERROR> AttributeError: 'NoneType' object has no attribute 'getconsumer' - doCheck = isPy3k; - meta = with stdenv.lib; { description = "py.test xdist plugin for distributed testing and loop-on-failing modes"; homepage = https://github.com/pytest-dev/pytest-xdist;