diff --git a/pkgs/development/python-modules/diagrams/default.nix b/pkgs/development/python-modules/diagrams/default.nix index 400a92543fcf..f7dda6214ac8 100644 --- a/pkgs/development/python-modules/diagrams/default.nix +++ b/pkgs/development/python-modules/diagrams/default.nix @@ -9,20 +9,21 @@ , inkscape , imagemagick , pytestCheckHook +, typed-ast }: buildPythonPackage rec { pname = "diagrams"; - version = "0.23.1"; + version = "0.23.3"; format = "pyproject"; - disabled = pythonOlder "3.6"; + disabled = pythonOlder "3.7"; src = fetchFromGitHub { owner = "mingrammer"; repo = pname; rev = "refs/tags/v${version}"; - hash = "sha256-gVUlP3offTgHUBTTIzTBf7b2NpBjGlAHYQQxe6ks0v8="; + hash = "sha256-4b+jmR56y2VV0XxD6FCmNpDB0UKH9+FqcTQuU2jRCXo="; }; postPatch = '' @@ -41,14 +42,22 @@ buildPythonPackage rec { ./remove-black-requirement.patch ]; - nativeCheckInputs = [ pytestCheckHook ]; - # Despite living in 'tool.poetry.dependencies', # these are only used at build time to process the image resource files - nativeBuildInputs = [ inkscape imagemagick jinja2 poetry-core round ]; + nativeBuildInputs = [ + inkscape imagemagick + jinja2 + poetry-core + round + ]; propagatedBuildInputs = [ graphviz + typed-ast + ]; + + nativeCheckInputs = [ + pytestCheckHook ]; pythonImportsCheck = [ diff --git a/pkgs/development/python-modules/diagrams/remove-black-requirement.patch b/pkgs/development/python-modules/diagrams/remove-black-requirement.patch index dcf9b4d2ad11..d6c9b4227091 100644 --- a/pkgs/development/python-modules/diagrams/remove-black-requirement.patch +++ b/pkgs/development/python-modules/diagrams/remove-black-requirement.patch @@ -1,8 +1,17 @@ +From bf081e60a7f604d2e71cf5c315dd90c48dd96808 Mon Sep 17 00:00:00 2001 +From: Fabian Affolter +Date: Thu, 26 Jan 2023 15:35:47 +0100 +Subject: [PATCH] Update autogen.sh + +--- + autogen.sh | 9 --------- + 1 file changed, 9 deletions(-) + diff --git a/autogen.sh b/autogen.sh -index acbcacb..1f60b83 100755 +index f5e065b35..b6cef5bf9 100755 --- a/autogen.sh +++ b/autogen.sh -@@ -21,11 +21,6 @@ +@@ -37,11 +37,6 @@ if ! [ -x "$(command -v convert)" ]; then exit 1 fi @@ -14,10 +23,10 @@ index acbcacb..1f60b83 100755 # preprocess the resources for pvd in "${providers[@]}"; do # convert the svg to png for azure provider -@@ -55,7 +50,3 @@ - # Generate doc for custom module - echo "generating the docs for custom" - python -m scripts.generate "custom" +@@ -75,7 +70,3 @@ python -m scripts.generate "custom" + # copy icons across to website + echo "copying icons to website static folder" + cp -r resources website/static/img/ - -# run black -echo "linting the all the diagram modules"