From d43a50eb045a4d32895c2f59b06e8c7d99f269de Mon Sep 17 00:00:00 2001 From: Ben Darwin Date: Fri, 9 Jun 2023 14:25:18 -0400 Subject: [PATCH] python310Packages.heudiconv: 0.12.2 -> 0.13.1 --- .../python-modules/heudiconv/default.nix | 39 +++++++++++-------- 1 file changed, 22 insertions(+), 17 deletions(-) diff --git a/pkgs/development/python-modules/heudiconv/default.nix b/pkgs/development/python-modules/heudiconv/default.nix index f1a867984f47..2928be6ede9a 100644 --- a/pkgs/development/python-modules/heudiconv/default.nix +++ b/pkgs/development/python-modules/heudiconv/default.nix @@ -1,9 +1,10 @@ { lib , buildPythonPackage , fetchPypi -, isPy27 -, pytest -, mock +, pythonOlder +, pytestCheckHook +, datalad +, git , dcm2niix , nibabel , pydicom @@ -14,35 +15,39 @@ }: buildPythonPackage rec { - version = "0.12.2"; + version = "0.13.1"; pname = "heudiconv"; + format = "pyproject"; - disabled = isPy27; + disabled = pythonOlder "3.7"; src = fetchPypi { inherit pname version; - #sha256 = "0gzqqa4pzhywdbvks2qjniwhr89sgipl5k7h9hcjs7cagmy9gb05"; - sha256 = "sha256-cYr74mw7tXRJRr8rXlu1UMZuU3YXXfDzhuc+vaa+7PQ="; + sha256 = "sha256-UUBRC6RToj4XVbJnxG+EKdue4NVpTAW31RNm9ieF1lU="; }; - postPatch = '' - # doesn't exist as a separate package with Python 3: - substituteInPlace heudiconv/info.py --replace "'pathlib'," "" - ''; - propagatedBuildInputs = [ - dcm2niix nibabel pydicom nipype dcmstack etelemetry filelock + nibabel + pydicom + nipype + dcmstack + etelemetry + filelock ]; - nativeCheckInputs = [ dcm2niix pytest mock ]; + nativeCheckInputs = [ + datalad + dcm2niix + pytestCheckHook + git + ]; - # test_monitor and test_dlad require 'inotify' and 'datalad' respectively, - # and these aren't in Nixpkgs - checkPhase = "pytest -k 'not test_dlad and not test_monitor' heudiconv/tests"; + preCheck = ''export HOME=$(mktemp -d)''; meta = with lib; { homepage = "https://heudiconv.readthedocs.io"; description = "Flexible DICOM converter for organizing imaging data"; + changelog = "https://github.com/nipy/heudiconv/releases/tag/v${version}"; license = licenses.asl20; maintainers = with maintainers; [ bcdarwin ]; };