From d12e433dded585a88d4e5f1890b6e3131f3db8f5 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Thu, 7 Aug 2025 02:52:54 +0200 Subject: [PATCH] python3Packages.pytest-describe: modernize, pin to pytest7 --- .../pytest-describe/default.nix | 24 ++++++++++++------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/pytest-describe/default.nix b/pkgs/development/python-modules/pytest-describe/default.nix index 6ce782c44200..6eb2b8390b2c 100644 --- a/pkgs/development/python-modules/pytest-describe/default.nix +++ b/pkgs/development/python-modules/pytest-describe/default.nix @@ -1,13 +1,16 @@ { lib, buildPythonPackage, - fetchPypi, + fetchFromGitHub, - # build + # build-system + setuptools, + + # dependencies pytest, # tests - pytestCheckHook, + pytest7CheckHook, }: let @@ -16,16 +19,21 @@ let in buildPythonPackage { inherit pname version; - format = "setuptools"; + pyproject = true; - src = fetchPypi { - inherit pname version; - hash = "sha256-ObsF65DySX2co0Lvmgt/pbraflhQWuwz9m1mHWMZVbc="; + src = fetchFromGitHub { + owner = "pytest-dev"; + repo = "pytest-describe"; + tag = version; + hash = "sha256-ih0XkYOtB+gwUsgo1oSti2460P3gq3tR+UsyRlzMjLE="; }; + build-system = [ setuptools ]; + buildInputs = [ pytest ]; - nativeCheckInputs = [ pytestCheckHook ]; + # test_fixture breaks with pytest 8.4 + nativeCheckInputs = [ pytest7CheckHook ]; meta = with lib; { description = "Describe-style plugin for the pytest framework";