From 7572f8c185dcdb3b33f3a7f224e951baaa279de1 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Sun, 2 Nov 2025 14:56:13 +0100 Subject: [PATCH] python3Packages.traitlets: refactor --- .../python-modules/traitlets/default.nix | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/pkgs/development/python-modules/traitlets/default.nix b/pkgs/development/python-modules/traitlets/default.nix index 8f469403ed14..086c2590a8ad 100644 --- a/pkgs/development/python-modules/traitlets/default.nix +++ b/pkgs/development/python-modules/traitlets/default.nix @@ -1,8 +1,7 @@ { lib, buildPythonPackage, - fetchPypi, - pythonOlder, + fetchFromGitHub, pythonAtLeast, # build-system @@ -17,16 +16,16 @@ buildPythonPackage rec { pname = "traitlets"; version = "5.14.3"; - format = "pyproject"; + pyproject = true; - disabled = pythonOlder "3.7"; - - src = fetchPypi { - inherit pname version; - hash = "sha256-ntBXnTUCyUtLNzKsEgN1zalvkjEUUihH3ks7uYuWtrc="; + src = fetchFromGitHub { + owner = "ipython"; + repo = "traitlets"; + tag = "v${version}"; + hash = "sha256-lWtgzXW1ffzl1jkFaq99X0dU8agulUMHaghsYKX+8Dk="; }; - nativeBuildInputs = [ hatchling ]; + build-system = [ hatchling ]; nativeCheckInputs = [ argcomplete @@ -37,7 +36,8 @@ buildPythonPackage rec { disabledTests = [ # https://github.com/ipython/traitlets/issues/902 "test_complete_custom_completers" - ] ++ lib.optionals (pythonAtLeast "3.14") [ + ] + ++ lib.optionals (pythonAtLeast "3.14") [ # https://github.com/ipython/traitlets/issues/925 "test_complete_simple_app" "test_complete_subcommands_subapp1"