From 129eace28d9ffdba9280242c2582044853fbe4bb Mon Sep 17 00:00:00 2001 From: Doron Behar Date: Tue, 13 Aug 2024 20:47:07 +0300 Subject: [PATCH 1/6] python312Packages.gast: modernize --- pkgs/development/python-modules/gast/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/gast/default.nix b/pkgs/development/python-modules/gast/default.nix index e275cc3170c2..75206d17ef88 100644 --- a/pkgs/development/python-modules/gast/default.nix +++ b/pkgs/development/python-modules/gast/default.nix @@ -16,8 +16,8 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "serge-sans-paille"; - repo = pname; - rev = version; + repo = "gast"; + rev = "refs/tags/${version}"; hash = "sha256-0y2bHT7YEfTvDxTm6yLl3GmnPUYEieoGEnwkzfA6mOg="; }; @@ -28,11 +28,11 @@ buildPythonPackage rec { pythonImportsCheck = [ "gast" ]; - meta = with lib; { + meta = { description = "Compatibility layer between the AST of various Python versions"; homepage = "https://github.com/serge-sans-paille/gast/"; - license = licenses.bsd3; - maintainers = with maintainers; [ + license = lib.licenses.bsd3; + maintainers = with lib.maintainers; [ jyp cpcloud ]; From 20ba6d165ed587d229aee9b7324d362704dffa04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Thu, 8 Aug 2024 03:40:17 -0700 Subject: [PATCH 2/6] python312Packages.gast: 0.5.3 -> 0.6.0 Diff: https://github.com/serge-sans-paille/gast/compare/0.5.3...0.6.0 --- pkgs/development/python-modules/gast/default.nix | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/gast/default.nix b/pkgs/development/python-modules/gast/default.nix index 75206d17ef88..d62c2bc4cd41 100644 --- a/pkgs/development/python-modules/gast/default.nix +++ b/pkgs/development/python-modules/gast/default.nix @@ -5,12 +5,13 @@ fetchFromGitHub, pytestCheckHook, pythonOlder, + setuptools, }: buildPythonPackage rec { pname = "gast"; - version = "0.5.3"; - format = "setuptools"; + version = "0.6.0"; + pyproject = true; disabled = pythonOlder "3.7"; @@ -18,9 +19,11 @@ buildPythonPackage rec { owner = "serge-sans-paille"; repo = "gast"; rev = "refs/tags/${version}"; - hash = "sha256-0y2bHT7YEfTvDxTm6yLl3GmnPUYEieoGEnwkzfA6mOg="; + hash = "sha256-zrbxW8qWhCY6tObP+/WDReoCnlCpMEzQucX2inpRTL4="; }; + build-system = [ setuptools ]; + nativeCheckInputs = [ astunparse pytestCheckHook From 8c63be6c613467ebde11be70400bfe56fcc7d48a Mon Sep 17 00:00:00 2001 From: Doron Behar Date: Tue, 13 Aug 2024 20:50:22 +0300 Subject: [PATCH 3/6] python312Packages.beniget: modernize --- pkgs/development/python-modules/beniget/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/beniget/default.nix b/pkgs/development/python-modules/beniget/default.nix index 3e3e104a9062..0ef62fc0573c 100644 --- a/pkgs/development/python-modules/beniget/default.nix +++ b/pkgs/development/python-modules/beniget/default.nix @@ -15,11 +15,12 @@ buildPythonPackage rec { sha256 = "75554b3b8ad0553ce2f607627dad3d95c60c441189875b98e097528f8e23ac0c"; }; - propagatedBuildInputs = [ gast ]; + dependencies = [ gast ]; meta = { description = "Extract semantic information about static Python code"; homepage = "https://github.com/serge-sans-paille/beniget"; license = lib.licenses.bsd3; + maintainers = with lib.maintainers; [ ]; }; } From 7828a0d8ac3bbacb1112e2a1d290f5d556e7661a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Thu, 8 Aug 2024 03:35:09 -0700 Subject: [PATCH 4/6] python312Packages.beniget: 0.4.1 -> 0.4.2.post1 --- .../python-modules/beniget/default.nix | 22 ++++++++++++++----- 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/beniget/default.nix b/pkgs/development/python-modules/beniget/default.nix index 0ef62fc0573c..b0dfc690841d 100644 --- a/pkgs/development/python-modules/beniget/default.nix +++ b/pkgs/development/python-modules/beniget/default.nix @@ -1,22 +1,32 @@ { lib, buildPythonPackage, - fetchPypi, + fetchFromGitHub, + setuptools, gast, + pytestCheckHook, }: buildPythonPackage rec { pname = "beniget"; - version = "0.4.1"; - format = "setuptools"; + version = "0.4.2.post1"; + pyproject = true; - src = fetchPypi { - inherit pname version; - sha256 = "75554b3b8ad0553ce2f607627dad3d95c60c441189875b98e097528f8e23ac0c"; + src = fetchFromGitHub { + owner = "serge-sans-paille"; + repo = "beniget"; + rev = "refs/tags/${version}"; + hash = "sha256-rNMgCEkI6p9KtLSz/2jVJ9rPeJzxv5rT+Pu6OHM8z70="; }; + build-system = [ setuptools ]; + dependencies = [ gast ]; + pythonImportsCheck = [ "beniget" ]; + + nativeCheckInputs = [ pytestCheckHook ]; + meta = { description = "Extract semantic information about static Python code"; homepage = "https://github.com/serge-sans-paille/beniget"; From d1c788840ecc51990c249f24d63abd183666c580 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 13 Aug 2024 09:52:39 -0700 Subject: [PATCH 5/6] python312Packages.pythran: bump gast to 0.6.0 --- pkgs/development/python-modules/pythran/default.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/development/python-modules/pythran/default.nix b/pkgs/development/python-modules/pythran/default.nix index e99283bc49ae..0fd4597b0a85 100644 --- a/pkgs/development/python-modules/pythran/default.nix +++ b/pkgs/development/python-modules/pythran/default.nix @@ -3,6 +3,7 @@ python, buildPythonPackage, fetchFromGitHub, + fetchpatch2, isPy3k, substituteAll, @@ -36,6 +37,11 @@ buildPythonPackage rec { }; patches = [ + (fetchpatch2 { + name = "bump-gast-to-0.6.0.patch"; + url = "https://github.com/serge-sans-paille/pythran/commit/840a0e706ec39963aec6bcd1f118bf33177c20b4.patch"; + hash = "sha256-FHGXWuAX/Nmn6uEfQgAXfUxIdApDwSfHHtOStxyme/0="; + }) # Hardcode path to mp library (substituteAll { src = ./0001-hardcode-path-to-libgomp.patch; From c338237e0e328c0ca6ddf0b9248645564282078f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Tue, 13 Aug 2024 07:02:05 -0700 Subject: [PATCH 6/6] python312Packages.pythran: modernize --- pkgs/development/python-modules/pythran/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/pythran/default.nix b/pkgs/development/python-modules/pythran/default.nix index 0fd4597b0a85..e74a9d62b210 100644 --- a/pkgs/development/python-modules/pythran/default.nix +++ b/pkgs/development/python-modules/pythran/default.nix @@ -4,7 +4,6 @@ buildPythonPackage, fetchFromGitHub, fetchpatch2, - isPy3k, substituteAll, # build-system @@ -32,7 +31,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "serge-sans-paille"; repo = "pythran"; - rev = version; + rev = "refs/tags/${version}"; hash = "sha256-TpD8YZnnv48PKYrUqR0/qvJG1XRbcMBcrkcERh6Q4q0="; }; @@ -57,9 +56,9 @@ buildPythonPackage rec { ln -s '${lib.getDev xsimd}'/include/xsimd pythran/ ''; - nativeBuildInputs = [ setuptools ]; + build-system = [ setuptools ]; - propagatedBuildInputs = [ + dependencies = [ ply gast numpy @@ -79,9 +78,8 @@ buildPythonPackage rec { # Test suite is huge and has a circular dependency on scipy. doCheck = false; - disabled = !isPy3k; - meta = { + changelog = "https://github.com/serge-sans-paille/pythran/blob/${src.rev}/Changelog"; description = "Ahead of Time compiler for numeric kernels"; homepage = "https://github.com/serge-sans-paille/pythran"; license = lib.licenses.bsd3;