From 13f08b1cbb8838f7bdc8514180d4ec08a1429d43 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Wed, 21 Jan 2026 02:19:18 +0100 Subject: [PATCH] python3Packages.psutil: 7.1.3 -> 7.2.1 https://github.com/giampaolo/psutil/blob/release-7.2.1/HISTORY.rst --- .../python-modules/psutil/default.nix | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/psutil/default.nix b/pkgs/development/python-modules/psutil/default.nix index 8a60fac56e20..e78a124b749f 100644 --- a/pkgs/development/python-modules/psutil/default.nix +++ b/pkgs/development/python-modules/psutil/default.nix @@ -5,20 +5,21 @@ fetchFromGitHub, setuptools, pytestCheckHook, - python, + pytest-instafail, + pytest-xdist, gitUpdater, }: buildPythonPackage rec { pname = "psutil"; - version = "7.1.3"; + version = "7.2.1"; pyproject = true; src = fetchFromGitHub { owner = "giampaolo"; repo = "psutil"; tag = "release-${version}"; - hash = "sha256-vMGUoiPr+QIe1N+I++d/DM9i2jeHTI68npGoJ2vKF10="; + hash = "sha256-HGIFf7E356o0OcgLOPjACmrPXneQt/8IhzyudKKuLdg="; }; postPatch = '' @@ -31,7 +32,11 @@ buildPythonPackage rec { build-system = [ setuptools ]; - nativeCheckInputs = [ pytestCheckHook ]; + nativeCheckInputs = [ + pytestCheckHook + pytest-instafail + pytest-xdist + ]; # Segfaults on darwin: # https://github.com/giampaolo/psutil/issues/1715 @@ -43,7 +48,7 @@ buildPythonPackage rec { # - the other disabled tests are likely due to sandboxing (missing specific errors) enabledTestPaths = [ # Note: $out must be referenced as test import paths are relative - "${placeholder "out"}/${python.sitePackages}/psutil/tests/test_system.py" + "tests/test_system.py" ]; disabledTests = [ @@ -59,6 +64,10 @@ buildPythonPackage rec { "test_disk_partitions" # problematic on Hydra's Linux builders, apparently ]; + preCheck = '' + rm -rf psutil + ''; + pythonImportsCheck = [ "psutil" ]; passthru.updateScript = gitUpdater {