From abe97e9446829a8c6da9033383df23befcb8c80c Mon Sep 17 00:00:00 2001 From: Uli Baum Date: Thu, 13 Sep 2018 16:30:35 +0200 Subject: [PATCH 1/6] pythonPackages.daphne: 2.1.0 -> 2.2.2 Update, re-enable all tests on linux, disable tests on darwin. This fixes the build of pythonPackages.channels --- pkgs/development/python-modules/daphne/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/daphne/default.nix b/pkgs/development/python-modules/daphne/default.nix index 7ead1cacfa6..258fc746e4b 100644 --- a/pkgs/development/python-modules/daphne/default.nix +++ b/pkgs/development/python-modules/daphne/default.nix @@ -4,7 +4,7 @@ }: buildPythonPackage rec { pname = "daphne"; - version = "2.1.0"; + version = "2.2.2"; disabled = !isPy3k; @@ -12,7 +12,7 @@ buildPythonPackage rec { owner = "django"; repo = pname; rev = version; - sha256 = "1lbpn0l796ar77amqy8dap30zxmsn6as8y2lbmp4lk8m9awscwi8"; + sha256 = "1pr3b7zxjp2jx31lpiy1hfyprpmyiv2kd18n8x6kh6gd5nr0dgp8"; }; nativeBuildInputs = [ pytestrunner ]; @@ -21,9 +21,10 @@ buildPythonPackage rec { checkInputs = [ hypothesis pytest pytest-asyncio ]; + doCheck = !stdenv.isDarwin; # most tests fail on darwin + checkPhase = '' - # Other tests fail, seems to be due to filesystem access - py.test -k "test_cli or test_utils" + py.test ''; meta = with stdenv.lib; { From 9e4b0b795cf83f33e0edc4a0e8fcf60c63f05903 Mon Sep 17 00:00:00 2001 From: Uli Baum Date: Thu, 13 Sep 2018 17:03:57 +0200 Subject: [PATCH 2/6] pythonPackages.eve: fix build, drop incorrect dependencies Build failed because of dependency Flask-PyMongo, which actually isn't a dependency of eve as they have their own flask_pymongo code. - Drop incorrect dependency flask-pymongo - Drop redunant dependencies already propageted by flask: itsdangerous, werkzeug, jinja2 - Drop dependency markupsafe, not required any more --- pkgs/development/python-modules/eve/default.nix | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/pkgs/development/python-modules/eve/default.nix b/pkgs/development/python-modules/eve/default.nix index b8daa5304c7..b145f1b2e2b 100644 --- a/pkgs/development/python-modules/eve/default.nix +++ b/pkgs/development/python-modules/eve/default.nix @@ -1,5 +1,5 @@ -{ stdenv, buildPythonPackage, fetchPypi, flask, jinja2, itsdangerous, events -, markupsafe, pymongo, flask-pymongo, werkzeug, simplejson, cerberus }: +{ stdenv, buildPythonPackage, fetchPypi, flask, events +, pymongo, simplejson, cerberus }: buildPythonPackage rec { pname = "Eve"; @@ -13,14 +13,9 @@ buildPythonPackage rec { propagatedBuildInputs = [ cerberus events - flask-pymongo flask - itsdangerous - jinja2 - markupsafe pymongo simplejson - werkzeug ]; # tests call a running mongodb instance From 781eaa13775b0c2aa457295fe08491dbd0d5a0dc Mon Sep 17 00:00:00 2001 From: Uli Baum Date: Thu, 13 Sep 2018 17:25:38 +0200 Subject: [PATCH 3/6] pythonPackages.flask-pymongo: fix build add missing dependency: vcversioner --- pkgs/development/python-modules/Flask-PyMongo/default.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/Flask-PyMongo/default.nix b/pkgs/development/python-modules/Flask-PyMongo/default.nix index 862fd84c492..7c37bdaddd5 100644 --- a/pkgs/development/python-modules/Flask-PyMongo/default.nix +++ b/pkgs/development/python-modules/Flask-PyMongo/default.nix @@ -2,6 +2,7 @@ , fetchPypi , flask , pymongo +, vcversioner , lib , pytest }: @@ -18,17 +19,17 @@ buildPythonPackage rec { checkInputs = [ pytest ]; checkPhase = '' - py.test tests + py.test ''; # Tests seem to hang doCheck = false; - propagatedBuildInputs = [ flask pymongo ]; + propagatedBuildInputs = [ flask pymongo vcversioner ]; meta = { homepage = "http://flask-pymongo.readthedocs.org/"; description = "PyMongo support for Flask applications"; license = lib.licenses.bsd2; }; -} \ No newline at end of file +} From 0bda601ee5a4ff73d7b7be8a7a28338697b076a8 Mon Sep 17 00:00:00 2001 From: Uli Baum Date: Thu, 13 Sep 2018 17:45:49 +0200 Subject: [PATCH 4/6] pythonPackages.pytest-rerunfailures: fix build some tests fail since pytest 3.7.2 -> 3.7.4 update, disable them --- .../python-modules/pytest-rerunfailures/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/pytest-rerunfailures/default.nix b/pkgs/development/python-modules/pytest-rerunfailures/default.nix index 5931afa37e2..d71cc420d59 100644 --- a/pkgs/development/python-modules/pytest-rerunfailures/default.nix +++ b/pkgs/development/python-modules/pytest-rerunfailures/default.nix @@ -9,10 +9,13 @@ buildPythonPackage rec { sha256 = "be6bf93ed618c8899aeb6721c24f8009c769879a3b4931e05650f3c173ec17c5"; }; - checkInputs = [ pytest mock ]; + checkInputs = [ mock ]; + propagatedBuildInputs = [ pytest ]; + + # disable tests that fail with pytest 3.7.4 checkPhase = '' - py.test + py.test test_pytest_rerunfailures.py -k 'not test_reruns_with_delay' ''; meta = with stdenv.lib; { From be12bb81aaf25c7b0cb97193b700ce347af25072 Mon Sep 17 00:00:00 2001 From: Uli Baum Date: Thu, 13 Sep 2018 18:16:34 +0200 Subject: [PATCH 5/6] pythonPackages.wordfreq: 2.0 -> 2.2.0, fix build Previous version didn't build (test failure). Update to latest, tests use pytest now, disable failing tests. --- .../development/python-modules/wordfreq/default.nix | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/wordfreq/default.nix b/pkgs/development/python-modules/wordfreq/default.nix index 9de1fd5b392..d672cb8bae9 100644 --- a/pkgs/development/python-modules/wordfreq/default.nix +++ b/pkgs/development/python-modules/wordfreq/default.nix @@ -6,27 +6,28 @@ , msgpack , mecab-python3 , jieba -, nose +, pytest , pythonOlder , fetchFromGitHub }: buildPythonPackage rec { pname = "wordfreq"; - version = "2.0"; + version = "2.2.0"; src = fetchFromGitHub { owner = "LuminosoInsight"; repo = "wordfreq"; - rev = "e3a1b470d9f8e0d82e9f179ffc41abba434b823b"; - sha256 = "1wjkhhj7nxfnrghwvmvwc672s30lp4b7yr98gxdxgqcq6wdshxwv"; + # upstream don't tag by version + rev = "bc12599010c8181a725ec97d0b3990758a48da36"; + sha256 = "195794vkzq5wsq3mg1dgfhlnz2f7vi1xajlifq6wkg4lzwyq262m"; }; - checkInputs = [ nose ]; + checkInputs = [ pytest ]; checkPhase = '' # These languages require additional dictionaries - nosetests -e test_japanese -e test_korean -e test_languages + pytest tests -k 'not test_japanese and not test_korean and not test_languages and not test_french_and_related' ''; propagatedBuildInputs = [ regex langcodes ftfy msgpack mecab-python3 jieba ]; From d9bdd64f04213e200e050984391d935d67dea31a Mon Sep 17 00:00:00 2001 From: Uli Baum Date: Thu, 13 Sep 2018 19:40:29 +0200 Subject: [PATCH 6/6] pythonPackages.nilearn: fix tests disable failing tests --- pkgs/development/python-modules/nilearn/default.nix | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/nilearn/default.nix b/pkgs/development/python-modules/nilearn/default.nix index 93871d9a9a7..bf8ae217705 100644 --- a/pkgs/development/python-modules/nilearn/default.nix +++ b/pkgs/development/python-modules/nilearn/default.nix @@ -11,9 +11,13 @@ buildPythonPackage rec { sha256 = "5049363eb6da2e7c35589477dfc79bf69929ca66de2d7ed2e9dc07acf78636f4"; }; - checkPhase = "nosetests --exclude with_expand_user nilearn/tests"; + # disable some failing tests + checkPhase = '' + nosetests nilearn/tests \ + -e test_cache_mixin_with_expand_user -e test_clean_confounds -e test_detrend + ''; - buildInputs = [ nose ]; + checkInputs = [ nose ]; propagatedBuildInputs = [ matplotlib