From 217e6434c1bed9e8c2adf7b0078e2635d0325453 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Mon, 6 May 2024 14:31:35 +0200 Subject: [PATCH 1/5] python311Packages.pretty-errors: init at 1.2.25 --- .../python-modules/pretty-errors/default.nix | 40 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 42 insertions(+) create mode 100644 pkgs/development/python-modules/pretty-errors/default.nix diff --git a/pkgs/development/python-modules/pretty-errors/default.nix b/pkgs/development/python-modules/pretty-errors/default.nix new file mode 100644 index 000000000000..ce9b646a543c --- /dev/null +++ b/pkgs/development/python-modules/pretty-errors/default.nix @@ -0,0 +1,40 @@ +{ lib +, buildPythonPackage +, fetchPypi +, setuptools +, wheel +, colorama +}: + +buildPythonPackage rec { + pname = "pretty-errors"; + version = "1.2.25"; + pyproject = true; + + src = fetchPypi { + pname = "pretty_errors"; + inherit version; + hash = "sha256-oWulx1LIfCY7+S+LS1hiTjseKScak5H1ZPErhuk8Z1U="; + }; + + build-system = [ + setuptools + wheel + ]; + + dependencies = [ + colorama + ]; + + pythonImportsCheck = [ "pretty_errors" ]; + + # No test + doCheck = false; + + meta = with lib; { + description = "Prettifies Python exception output to make it legible"; + homepage = "https://pypi.org/project/pretty-errors/"; + license = licenses.mit; + maintainers = with maintainers; [ GaetanLepage ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 36783fd443f8..7a1e63302d94 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -10312,6 +10312,8 @@ self: super: with self; { pretend = callPackage ../development/python-modules/pretend { }; + pretty-errors = callPackage ../development/python-modules/pretty-errors { }; + prettytable = callPackage ../development/python-modules/prettytable { }; primecountpy = callPackage ../development/python-modules/primecountpy { }; From 3d7f1c761792e371810d3a983ed4b6d5acc8e4c4 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Mon, 6 May 2024 14:28:46 +0200 Subject: [PATCH 2/5] python311Packages.torchmetrics: 1.3.2 -> 1.4.0 Diff: https://github.com/Lightning-AI/torchmetrics/compare/refs/tags/v1.3.2...v1.4.0 Changelog: https://github.com/Lightning-AI/torchmetrics/releases/tag/v1.4.0 --- pkgs/development/python-modules/torchmetrics/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/torchmetrics/default.nix b/pkgs/development/python-modules/torchmetrics/default.nix index e5c05c6dd497..5cc57ed0bed3 100644 --- a/pkgs/development/python-modules/torchmetrics/default.nix +++ b/pkgs/development/python-modules/torchmetrics/default.nix @@ -8,6 +8,7 @@ , scikit-learn , scikit-image , packaging +, pretty-errors , psutil , py-deprecate , torch @@ -20,7 +21,7 @@ let pname = "torchmetrics"; - version = "1.3.2"; + version = "1.4.0"; in buildPythonPackage { inherit pname version; @@ -32,13 +33,14 @@ buildPythonPackage { owner = "Lightning-AI"; repo = "torchmetrics"; rev = "refs/tags/v${version}"; - hash = "sha256-0lverGF8HVlnwWmnCjScWoSfWPLZlMF2cHDG+uxNCCQ="; + hash = "sha256-5ANEpUdd5eyzBhhAEHrvHNHMOQuXhkkKuL1t3dJLhdE="; }; - propagatedBuildInputs = [ + dependencies = [ numpy lightning-utilities packaging + pretty-errors py-deprecate ]; From 12897bc78ae2695ca0415fb7e365e567107ef056 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Mon, 6 May 2024 14:56:24 +0200 Subject: [PATCH 3/5] python311Packages.lightning-utilities: 0.10.1 -> 0.11.2 Diff: https://github.com/Lightning-AI/utilities/compare/refs/tags/v0.10.1...v0.11.2 Changelog: https://github.com/Lightning-AI/utilities/releases/tag/v0.11.2 --- .../python-modules/lightning-utilities/default.nix | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/lightning-utilities/default.nix b/pkgs/development/python-modules/lightning-utilities/default.nix index 3af06818b8ee..237128be5ce0 100644 --- a/pkgs/development/python-modules/lightning-utilities/default.nix +++ b/pkgs/development/python-modules/lightning-utilities/default.nix @@ -16,21 +16,21 @@ buildPythonPackage rec { pname = "lightning-utilities"; - version = "0.10.1"; - format = "pyproject"; + version = "0.11.2"; + pyproject = true; src = fetchFromGitHub { owner = "Lightning-AI"; repo = "utilities"; rev = "refs/tags/v${version}"; - hash = "sha256-kP7BllA9FR/nMNTxRCxmG6IJYHz/Nxqb1HoF9KxuKl8="; + hash = "sha256-IT9aRAUNc2cP2erLr0MglZSVLfDjOxg8PVIIe9AvO0o="; }; - nativeBuildInputs = [ + build-system = [ setuptools ]; - propagatedBuildInputs = [ + dependencies = [ packaging typing-extensions ]; @@ -53,6 +53,8 @@ buildPythonPackage rec { # fails another test "lightning_utilities.core.imports.ModuleAvailableCache" "lightning_utilities.core.imports.requires" + # Failed: DID NOT RAISE + "test_no_warning_call" ]; disabledTestPaths = [ From bd3f131e73c716efb3bfe63a6f813144b5e480b9 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Mon, 6 May 2024 14:57:28 +0200 Subject: [PATCH 4/5] python311Packages.lightning-utilities: add GaetanLepage as maintainer --- pkgs/development/python-modules/lightning-utilities/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/lightning-utilities/default.nix b/pkgs/development/python-modules/lightning-utilities/default.nix index 237128be5ce0..7287e13e7e78 100644 --- a/pkgs/development/python-modules/lightning-utilities/default.nix +++ b/pkgs/development/python-modules/lightning-utilities/default.nix @@ -73,6 +73,6 @@ buildPythonPackage rec { description = "Common Python utilities and GitHub Actions in Lightning Ecosystem"; homepage = "https://github.com/Lightning-AI/utilities"; license = licenses.asl20; - maintainers = with maintainers; [ ]; + maintainers = with maintainers; [ GaetanLepage ]; }; } From 8429b7d6c081cb6eee572ccb5d733256d39fc59c Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Mon, 6 May 2024 15:06:12 +0200 Subject: [PATCH 5/5] python311Packages.lightning-utilities: mark as broken for python3.12 --- pkgs/development/python-modules/lightning-utilities/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/development/python-modules/lightning-utilities/default.nix b/pkgs/development/python-modules/lightning-utilities/default.nix index 7287e13e7e78..7dba0a125f57 100644 --- a/pkgs/development/python-modules/lightning-utilities/default.nix +++ b/pkgs/development/python-modules/lightning-utilities/default.nix @@ -1,6 +1,7 @@ { lib , buildPythonPackage , fetchFromGitHub +, pythonAtLeast # build , setuptools @@ -74,5 +75,6 @@ buildPythonPackage rec { homepage = "https://github.com/Lightning-AI/utilities"; license = licenses.asl20; maintainers = with maintainers; [ GaetanLepage ]; + broken = pythonAtLeast "3.12"; }; }