From 9d1932e38b4047daa8bd5f2e57c524f622315f9e Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 20 May 2022 23:14:15 +0200 Subject: [PATCH] prospector: relax requirements-detector constraint --- pkgs/development/tools/prospector/default.nix | 23 +++++++++++-------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/pkgs/development/tools/prospector/default.nix b/pkgs/development/tools/prospector/default.nix index 0d6e5de4cfe5..5458df424b12 100644 --- a/pkgs/development/tools/prospector/default.nix +++ b/pkgs/development/tools/prospector/default.nix @@ -1,5 +1,5 @@ { lib -, pkgs +, fetchFromGitHub , python3 }: @@ -14,21 +14,15 @@ buildPythonApplication rec { version = "1.7.7"; format = "pyproject"; - disabled = pythonOlder "3.6.1"; + disabled = pythonOlder "3.7"; - src = pkgs.fetchFromGitHub { + src = fetchFromGitHub { owner = "PyCQA"; repo = pname; rev = version; hash = "sha256-sbPZmVeJtNphtjuZEfKcUgty9bJ3E/2Ya9RuX3u/XEs="; }; - postPatch = '' - substituteInPlace pyproject.toml \ - --replace 'pep8-naming = ">=0.3.3,<=0.10.0"' 'pep8-naming = "*"' \ - --replace 'mccabe = "^0.6.0"' 'mccabe = "*"' - ''; - nativeBuildInputs = [ poetry-core ]; @@ -60,6 +54,17 @@ buildPythonApplication rec { pytestCheckHook ]; + postPatch = '' + substituteInPlace pyproject.toml \ + --replace 'requirements-detector = "^0.7"' 'requirements-detector = "*"' \ + --replace 'pep8-naming = ">=0.3.3,<=0.10.0"' 'pep8-naming = "*"' \ + --replace 'mccabe = "^0.6.0"' 'mccabe = "*"' + ''; + + pythonImportsCheck = [ + "prospector" + ]; + meta = with lib; { description = "Tool to analyse Python code and output information about errors, potential problems, convention violations and complexity"; homepage = "https://github.com/PyCQA/prospector";