From 68c0efab60b7af823aec925feabe55fd079891e7 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Tue, 3 Sep 2024 00:15:55 +0200 Subject: [PATCH] python312Packages: clean + mark as broken for python >= 3.12 --- .../python-modules/rising/default.nix | 26 ++++++++++++------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/rising/default.nix b/pkgs/development/python-modules/rising/default.nix index fee5c590de51..2c96fbf92eda 100644 --- a/pkgs/development/python-modules/rising/default.nix +++ b/pkgs/development/python-modules/rising/default.nix @@ -1,45 +1,51 @@ { - stdenv, lib, buildPythonPackage, - pythonOlder, fetchFromGitHub, - pytestCheckHook, - dill, + + # dependencies lightning-utilities, numpy, torch, threadpoolctl, tqdm, + + # tests + dill, + pytestCheckHook, + + stdenv, + + pythonAtLeast, }: buildPythonPackage rec { pname = "rising"; version = "0.3.0"; - format = "setuptools"; - disabled = pythonOlder "3.8"; + pyproject = true; src = fetchFromGitHub { owner = "PhoenixDL"; - repo = pname; + repo = "rising"; rev = "refs/tags/v${version}"; hash = "sha256-sBzVTst5Tp2oZZ+Xsg3M7uAMbucL6idlpYwHvib3EaY="; }; - pythonRelaxDeps = [ "lightning-utilities" ]; - propagatedBuildInputs = [ + dependencies = [ lightning-utilities numpy torch threadpoolctl tqdm ]; + nativeCheckInputs = [ dill pytestCheckHook ]; + disabledTests = lib.optionals (stdenv.isLinux && stdenv.isAarch64) [ # RuntimeError: DataLoader worker (pid(s) <...>) exited unexpectedly: "test_progressive_resize_integration" @@ -60,5 +66,7 @@ buildPythonPackage rec { homepage = "https://rising.rtfd.io"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ bcdarwin ]; + # AttributeError: module 'configparser' has no attribute 'SafeConfigParser'. Did you mean: 'RawConfigParser'? + broken = pythonAtLeast "3.12"; }; }