Merge pull request #188536 from bcdarwin/update-dicom2nifti

authored by Sandro and committed by GitHub 8e48c164 fa6b4c3a

+17 -8
+17 -8
pkgs/development/python-modules/dicom2nifti/default.nix
··· 1 { lib 2 , buildPythonPackage 3 , fetchFromGitHub 4 - , isPy27 5 , gdcm 6 - , nose 7 , nibabel 8 , numpy 9 , pydicom ··· 13 14 buildPythonPackage rec { 15 pname = "dicom2nifti"; 16 - version = "2.3.0"; 17 - disabled = isPy27; 18 19 # no tests in PyPI dist 20 src = fetchFromGitHub { 21 owner = "icometrix"; 22 repo = pname; 23 rev = version; 24 - sha256 = "sha256-QSu9CGXFjDpI25Cy6QSbrwiQ2bwsVezCUxSovRLs6AI="; 25 }; 26 27 - propagatedBuildInputs = [ nibabel numpy pydicom scipy setuptools ]; 28 29 - checkInputs = [ nose gdcm ]; 30 - checkPhase = "nosetests tests"; 31 32 meta = with lib; { 33 homepage = "https://github.com/icometrix/dicom2nifti";
··· 1 { lib 2 , buildPythonPackage 3 , fetchFromGitHub 4 + , pythonOlder 5 + , pytestCheckHook 6 , gdcm 7 , nibabel 8 , numpy 9 , pydicom ··· 13 14 buildPythonPackage rec { 15 pname = "dicom2nifti"; 16 + version = "2.4.3"; 17 + disabled = pythonOlder "3.6"; 18 19 # no tests in PyPI dist 20 src = fetchFromGitHub { 21 owner = "icometrix"; 22 repo = pname; 23 rev = version; 24 + hash = "sha256-za2+HdnUhPu3+p29JsF4iL1lyPQVmEv3fam0Yf1oeMQ="; 25 }; 26 27 + propagatedBuildInputs = [ gdcm nibabel numpy pydicom scipy setuptools ]; 28 + 29 + # python-gdcm just builds the python interface provided by the "gdcm" package, so 30 + # we should be able to replace "python-gdcm" with "gdcm" but this doesn't work 31 + # (similar to https://github.com/NixOS/nixpkgs/issues/84774) 32 + postPatch = '' 33 + substituteInPlace setup.py --replace "python-gdcm" "" 34 + substituteInPlace tests/test_generic.py --replace "from common" "from dicom2nifti.common" 35 + ''; 36 37 + checkInputs = [ pytestCheckHook ]; 38 + 39 + pythonImportsCheck = [ "dicom2nifti" ]; 40 41 meta = with lib; { 42 homepage = "https://github.com/icometrix/dicom2nifti";