From 921b15efe75dbde8b6f2e3bb85fe648cba73f0db Mon Sep 17 00:00:00 2001 From: Ben Darwin Date: Wed, 7 Oct 2020 13:49:17 -0400 Subject: [PATCH 1/2] python3Packages.nipype: remove Python 2 support (dependency nibabel already unsupported) --- pkgs/development/python-modules/nipype/default.nix | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/pkgs/development/python-modules/nipype/default.nix b/pkgs/development/python-modules/nipype/default.nix index 80ee7691a1a..c621341b2f8 100644 --- a/pkgs/development/python-modules/nipype/default.nix +++ b/pkgs/development/python-modules/nipype/default.nix @@ -1,23 +1,19 @@ { stdenv , buildPythonPackage , fetchPypi -, isPy3k -, isPy38 +, isPy27 # python dependencies , click -, configparser ? null , dateutil , etelemetry , filelock , funcsigs , future -, futures , mock , networkx , nibabel , numpy , packaging -, pathlib2 , prov , psutil , pybids @@ -39,8 +35,6 @@ , callPackage }: -assert !isPy3k -> configparser != null; - let # This is a temporary convenience package for changes waiting to be merged into the primary rdflib repo. @@ -51,6 +45,7 @@ in buildPythonPackage rec { pname = "nipype"; version = "1.5.1"; + disabled = isPy27; src = fetchPypi { inherit pname version; @@ -85,10 +80,6 @@ buildPythonPackage rec { simplejson traits xvfbwrapper - ] ++ stdenv.lib.optionals (!isPy3k) [ - configparser - futures - pathlib2 # darwin doesn't receive this transitively, but it is in install_requires ]; checkInputs = [ From f31be2ec2576f787811ae1ddd900c322b84a5ab2 Mon Sep 17 00:00:00 2001 From: Ben Darwin Date: Wed, 7 Oct 2020 14:02:26 -0400 Subject: [PATCH 2/2] python3Packages.nipype: avoid use of neurdflib by default since it causes a package collision when rdflib is in the closure --- pkgs/development/python-modules/nipype/default.nix | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/nipype/default.nix b/pkgs/development/python-modules/nipype/default.nix index c621341b2f8..2d8eaecf775 100644 --- a/pkgs/development/python-modules/nipype/default.nix +++ b/pkgs/development/python-modules/nipype/default.nix @@ -21,6 +21,7 @@ , pytest , pytest_xdist , pytest-forked +, rdflib , scipy , simplejson , traits @@ -33,6 +34,10 @@ , bash , glibcLocales , callPackage +# causes Python packaging conflict with any package requiring rdflib, +# so use the unpatched rdflib by default (disables Nipype provenance tracking); +# see https://github.com/nipy/nipype/issues/2888: +, useNeurdflib ? false }: let @@ -69,7 +74,6 @@ buildPythonPackage rec { funcsigs future networkx - neurdflib nibabel numpy packaging @@ -80,7 +84,7 @@ buildPythonPackage rec { simplejson traits xvfbwrapper - ]; + ] ++ [ (if useNeurdflib then neurdflib else rdflib) ]; checkInputs = [ pybids