From 919a5242afa4d13e26252f195168b37a1b80e670 Mon Sep 17 00:00:00 2001 From: Pyrox Date: Mon, 29 Jul 2024 00:53:52 -0400 Subject: [PATCH 1/2] python312Packages.jsonable: drop nose dependency --- .../python-modules/jsonable/default.nix | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/jsonable/default.nix b/pkgs/development/python-modules/jsonable/default.nix index 4dd7c96221e6..f628860b256a 100644 --- a/pkgs/development/python-modules/jsonable/default.nix +++ b/pkgs/development/python-modules/jsonable/default.nix @@ -2,8 +2,8 @@ lib, buildPythonPackage, fetchFromGitHub, - nose, pytestCheckHook, + fetchpatch2, }: buildPythonPackage rec { @@ -18,11 +18,17 @@ buildPythonPackage rec { hash = "sha256-3FIzG2djSZOPDdoYeKqs3obQjgHrFtyp0sdBwZakkHA="; }; - nativeCheckInputs = [ - nose - pytestCheckHook + patches = [ + # https://github.com/halfak/python-jsonable/pull/2 + (fetchpatch2 { + name = "eq-to-assert.patch"; + url = "https://github.com/halfak/python-jsonable/pull/2/commits/335e61bb4926e644aef983f7313793bf506d2463.patch"; + hash = "sha256-tCVA0wG+UMyB6oaNf4nbZ2BPWkNumaGPcjP5VJKegBo="; + }) ]; + nativeCheckInputs = [ pytestCheckHook ]; + pythonImportsCheck = [ "jsonable" ]; meta = with lib; { From 8989a7038e93d3238110f059d32a9ffb71db9d97 Mon Sep 17 00:00:00 2001 From: Pyrox Date: Mon, 29 Jul 2024 00:54:34 -0400 Subject: [PATCH 2/2] python312Packages.jsonable: modernize --- pkgs/development/python-modules/jsonable/default.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/jsonable/default.nix b/pkgs/development/python-modules/jsonable/default.nix index f628860b256a..705ff95a2d77 100644 --- a/pkgs/development/python-modules/jsonable/default.nix +++ b/pkgs/development/python-modules/jsonable/default.nix @@ -4,12 +4,13 @@ fetchFromGitHub, pytestCheckHook, fetchpatch2, + setuptools, }: buildPythonPackage rec { pname = "jsonable"; version = "0.3.1"; - format = "setuptools"; + pyproject = true; src = fetchFromGitHub { owner = "halfak"; @@ -27,14 +28,16 @@ buildPythonPackage rec { }) ]; + build-system = [ setuptools ]; + nativeCheckInputs = [ pytestCheckHook ]; pythonImportsCheck = [ "jsonable" ]; - meta = with lib; { + meta = { description = "Provides an abstract base class and utilities for defining trivially JSONable python objects"; homepage = "https://github.com/halfak/python-jsonable"; - license = licenses.mit; - maintainers = with maintainers; [ GaetanLepage ]; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ GaetanLepage ]; }; }