From d42567839716c6d763f7f59a521f785b31eba69e Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 29 Mar 2024 11:56:42 +0100 Subject: [PATCH] python312Packages.actdiag: refactor --- .../python-modules/actdiag/default.nix | 28 +++++++++++++------ 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/actdiag/default.nix b/pkgs/development/python-modules/actdiag/default.nix index 6d04df9d9671..070bcd72ed4a 100644 --- a/pkgs/development/python-modules/actdiag/default.nix +++ b/pkgs/development/python-modules/actdiag/default.nix @@ -2,7 +2,7 @@ , blockdiag , buildPythonPackage , fetchFromGitHub -, nose +, pynose , pytestCheckHook , pythonOlder , setuptools @@ -11,24 +11,27 @@ buildPythonPackage rec { pname = "actdiag"; version = "3.0.0"; - format = "setuptools"; + pyproject = true; disabled = pythonOlder "3.7"; src = fetchFromGitHub { owner = "blockdiag"; - repo = pname; - rev = version; + repo = "actdiag"; + rev = "refs/tags/${version}"; hash = "sha256-WmprkHOgvlsOIg8H77P7fzEqxGnj6xaL7Df7urRkg3o="; }; - propagatedBuildInputs = [ - blockdiag + build-system = [ setuptools ]; + propagatedBuildInputs = [ + blockdiag + ]; + nativeCheckInputs = [ - nose + pynose pytestCheckHook ]; @@ -36,16 +39,23 @@ buildPythonPackage rec { "src/actdiag/tests/" ]; + disabledTests = [ + # AttributeError: 'TestRstDirectives' object has no attribute 'assertRegexpMatches' + "svg" + "noviewbox" + ]; + pythonImportsCheck = [ "actdiag" ]; meta = with lib; { description = "Generate activity-diagram image from spec-text file (similar to Graphviz)"; - mainProgram = "actdiag"; homepage = "http://blockdiag.com/"; + changelog = "https://github.com/blockdiag/actdiag/blob/${version}/CHANGES.rst"; license = licenses.asl20; - platforms = platforms.unix; maintainers = with maintainers; [ bjornfor ]; + mainProgram = "actdiag"; + platforms = platforms.unix; }; }