From 49e9194b243ea59415f2b6f25a62180b00f2af38 Mon Sep 17 00:00:00 2001 From: Dmitry Kalinkin Date: Tue, 26 Mar 2019 00:05:59 -0400 Subject: [PATCH 1/3] pythonPackages.pyarrow: fix build Setting setupPyBuildFlags makes builder add an additional target "build_ext" to setup.py arguments in addition to "bdisst_wheel". pyarrow's setup.py recently started to try to redo build_ext again which broke the build. --- pkgs/development/python-modules/pyarrow/default.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/pyarrow/default.nix b/pkgs/development/python-modules/pyarrow/default.nix index 899b18eecbe..d568cea7851 100644 --- a/pkgs/development/python-modules/pyarrow/default.nix +++ b/pkgs/development/python-modules/pyarrow/default.nix @@ -16,6 +16,7 @@ buildPythonPackage rec { checkInputs = [ hypothesis pandas pytest ]; PYARROW_BUILD_TYPE = "release"; + PYARROW_WITH_PARQUET = true; PYARROW_CMAKE_OPTIONS = [ "-DCMAKE_INSTALL_RPATH=${ARROW_HOME}/lib" @@ -48,8 +49,6 @@ buildPythonPackage rec { ARROW_HOME = _arrow-cpp; PARQUET_HOME = _arrow-cpp; - setupPyBuildFlags = ["--with-parquet" ]; - checkPhase = '' mv pyarrow/tests tests rm -rf pyarrow From 55223a8a6a92523f51e24f7774912068f9d2eef8 Mon Sep 17 00:00:00 2001 From: Dmitry Kalinkin Date: Tue, 26 Mar 2019 00:11:02 -0400 Subject: [PATCH 2/3] pythonPackages.pyarrow: enable parallel build --- pkgs/development/python-modules/pyarrow/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/python-modules/pyarrow/default.nix b/pkgs/development/python-modules/pyarrow/default.nix index d568cea7851..125967c6fd6 100644 --- a/pkgs/development/python-modules/pyarrow/default.nix +++ b/pkgs/development/python-modules/pyarrow/default.nix @@ -25,6 +25,10 @@ buildPythonPackage rec { "-DCMAKE_POLICY_DEFAULT_CMP0025=NEW" ]; + preBuild = '' + export PYARROW_PARALLEL=$NIX_BUILD_CORES + ''; + preCheck = '' rm pyarrow/tests/test_jvm.py rm pyarrow/tests/test_hdfs.py From 2645454bc7ad008cf12ade9eef1fa3d0e1fbf0e8 Mon Sep 17 00:00:00 2001 From: Dmitry Kalinkin Date: Tue, 26 Mar 2019 10:35:56 -0400 Subject: [PATCH 3/3] pyarrow: remove tests that can break on darwin --- pkgs/development/python-modules/pyarrow/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/python-modules/pyarrow/default.nix b/pkgs/development/python-modules/pyarrow/default.nix index 125967c6fd6..32c5f38b66d 100644 --- a/pkgs/development/python-modules/pyarrow/default.nix +++ b/pkgs/development/python-modules/pyarrow/default.nix @@ -48,6 +48,10 @@ buildPythonPackage rec { # when it is not intended to be imported at all rm pyarrow/tests/deserialize_buffer.py substituteInPlace pyarrow/tests/test_feather.py --replace "test_deserialize_buffer_in_different_process" "_disabled" + + # Fails to bind a socket + # "PermissionError: [Errno 1] Operation not permitted" + substituteInPlace pyarrow/tests/test_ipc.py --replace "test_socket_" "_disabled" ''; ARROW_HOME = _arrow-cpp;