diff --git a/pkgs/development/tools/prospector/default.nix b/pkgs/development/tools/prospector/default.nix index 38472ce86f01..2f58737637f6 100644 --- a/pkgs/development/tools/prospector/default.nix +++ b/pkgs/development/tools/prospector/default.nix @@ -1,55 +1,41 @@ { lib , pkgs -, python +, python3 }: let - py = python.override { - packageOverrides = self: super: { - pep8-naming = super.pep8-naming.overridePythonAttrs(oldAttrs: rec { - version = "0.4.1"; - src = oldAttrs.src.override { - inherit version; - sha256 = "0nhf8p37y008shd4f21bkj5pizv8q0l8cpagyyb8gr059d6gvvaf"; - }; - }); - }; - }; - setoptconf = py.pkgs.callPackage ./setoptconf.nix { }; + setoptconf-tmp = python3.pkgs.callPackage ./setoptconf.nix { }; in -with py.pkgs; +with python3.pkgs; buildPythonApplication rec { pname = "prospector"; - version = "1.2.0"; - disabled = isPy27; + version = "1.5.1"; + format = "pyproject"; + disabled = pythonOlder "3.6.1"; src = pkgs.fetchFromGitHub { owner = "PyCQA"; repo = pname; rev = version; - sha256 = "07kb37zrrsriqzcmli0ghx7qb1iwkzh83qsiikl9jy50faby2sjg"; + sha256 = "17f822cxrvcvnrzdx1a9fyi9afljq80b6g6z1k2bqa1vs21gwv7l"; }; - checkInputs = [ - pytest + postPatch = '' + substituteInPlace pyproject.toml \ + --replace 'pep8-naming = ">=0.3.3,<=0.10.0"' 'pep8-naming = "*"' + ''; + + nativeBuildInputs = [ + poetry-core ]; - checkPhase = '' - pytest - ''; - - patchPhase = '' - substituteInPlace setup.py \ - --replace 'pycodestyle<=2.4.0' 'pycodestyle<=2.5.0' - ''; - propagatedBuildInputs = [ - astroid - django + bandit dodgy mccabe + mypy pep8-naming pycodestyle pydocstyle @@ -58,9 +44,18 @@ buildPythonApplication rec { pylint-celery pylint-django pylint-flask + pylint-plugin-utils + pyroma pyyaml requirements-detector - setoptconf + setoptconf-tmp + setuptools + toml + vulture + ]; + + checkInputs = [ + pytestCheckHook ]; meta = with lib; { diff --git a/pkgs/development/tools/prospector/setoptconf.nix b/pkgs/development/tools/prospector/setoptconf.nix index 62b4e95357dc..1d0f06a57e77 100644 --- a/pkgs/development/tools/prospector/setoptconf.nix +++ b/pkgs/development/tools/prospector/setoptconf.nix @@ -4,19 +4,19 @@ }: buildPythonPackage rec { - pname = "setoptconf"; - version = "0.2.0"; + pname = "setoptconf-tmp"; + version = "0.3.1"; src = fetchPypi { inherit pname version; - sha256 = "177l7j68j751i781bgk6pfhxjj7hwqxzdm2ja5fkywbp0275s2sv"; + sha256 = "0y2pgpraa36wzlzkxigvmz80mqd3mzcc9wv2yx9bliqks7fhlj70"; }; # Base tests provided via PyPi are broken doCheck = false; meta = with lib; { - homepage = "https://pypi.org/project/setoptconf"; + homepage = "https://pypi.org/project/setoptconf-tmp"; description = "A module for retrieving program settings from various sources in a consistant method"; license = licenses.mit; maintainers = with maintainers; [ diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 7fbbf150eee8..1a363fa6a62f 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -18591,9 +18591,7 @@ with pkgs; buildPythonApplication click future six; }; - prospector = callPackage ../development/tools/prospector { - python = python37; - }; + prospector = callPackage ../development/tools/prospector { }; protobuf = protobuf3_18;