From 73f7453bfbfcc63571011a8adf586cea146e4ff7 Mon Sep 17 00:00:00 2001 From: Simon Chatterjee Date: Fri, 19 Jun 2020 20:03:41 +0100 Subject: [PATCH 1/3] pythonPackages.psutil: fix fix for darwin build PR #82524 correctly diagnosed the problem, but slightly fluffed the boolean logic (disable tests for Darwin as well as non-x86_64 arch). --- pkgs/development/python-modules/psutil/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/psutil/default.nix b/pkgs/development/python-modules/psutil/default.nix index 8e479dfaca2..69181af222c 100644 --- a/pkgs/development/python-modules/psutil/default.nix +++ b/pkgs/development/python-modules/psutil/default.nix @@ -16,7 +16,7 @@ buildPythonPackage rec { # arch doesn't report frequency is the same way # tests segfaults on darwin https://github.com/giampaolo/psutil/issues/1715 - doCheck = stdenv.isDarwin || stdenv.isx86_64; + doCheck = !stdenv.isDarwin && stdenv.isx86_64; checkInputs = [ pytest ] ++ lib.optionals isPy27 [ mock ipaddress ]; # out must be referenced as test import paths are relative From 5a3546120c7b8cecb8e5f9cf55e473396efc32c8 Mon Sep 17 00:00:00 2001 From: Simon Chatterjee Date: Fri, 19 Jun 2020 20:11:32 +0100 Subject: [PATCH 2/3] python: aiohttp: fix darwin build Disable a non-critical test known to fail on Darwin (see https://github.com/aio-libs/aiohttp/issues/3572) --- pkgs/development/python-modules/aiohttp/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/development/python-modules/aiohttp/default.nix b/pkgs/development/python-modules/aiohttp/default.nix index c58944a59d7..9dcd34c1d1b 100644 --- a/pkgs/development/python-modules/aiohttp/default.nix +++ b/pkgs/development/python-modules/aiohttp/default.nix @@ -62,6 +62,7 @@ buildPythonPackage rec { "test_read_incomplete_chunk" "test_request_tracing_exception" ] ++ lib.optionals stdenv.isDarwin [ + "test_addresses" # https://github.com/aio-libs/aiohttp/issues/3572 "test_close" ]; From 084d3da828f433562863af542f5ce7bcd9070cfe Mon Sep 17 00:00:00 2001 From: Simon Chatterjee Date: Fri, 19 Jun 2020 20:14:54 +0100 Subject: [PATCH 3/3] python: uvloop: fix darwin build Skip tests that fail on Darwin --- pkgs/development/python-modules/uvloop/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkgs/development/python-modules/uvloop/default.nix b/pkgs/development/python-modules/uvloop/default.nix index 109d8d8efab..567846b0aef 100644 --- a/pkgs/development/python-modules/uvloop/default.nix +++ b/pkgs/development/python-modules/uvloop/default.nix @@ -55,6 +55,9 @@ buildPythonPackage rec { export TEST_DIR=$(mktemp -d) cp -r tests $TEST_DIR pushd $TEST_DIR + '' + lib.optionalString stdenv.isDarwin '' + # Some tests fail on Darwin + rm tests/test_[stu]*.py ''; postCheck = '' popd