2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
2022-06-16 17:23:12 +00:00
|
|
|
, fetchFromGitHub
|
2021-10-04 12:37:57 +00:00
|
|
|
, python3
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
2021-10-04 12:37:57 +00:00
|
|
|
setoptconf-tmp = python3.pkgs.callPackage ./setoptconf.nix { };
|
2020-04-24 23:36:52 +00:00
|
|
|
in
|
|
|
|
|
2022-12-28 21:21:41 +00:00
|
|
|
python3.pkgs.buildPythonApplication rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "prospector";
|
2023-02-02 18:25:31 +00:00
|
|
|
version = "1.8.4";
|
2021-10-04 12:37:57 +00:00
|
|
|
format = "pyproject";
|
2022-05-18 14:49:53 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
src = fetchFromGitHub {
|
2020-04-24 23:36:52 +00:00
|
|
|
owner = "PyCQA";
|
|
|
|
repo = pname;
|
2022-12-28 21:21:41 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-02-02 18:25:31 +00:00
|
|
|
hash = "sha256-g7tyn6pj5I/+b28wIitqDapR5ffk1xDEAtcYs2TpIUk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-12-28 21:21:41 +00:00
|
|
|
pythonRelaxDeps = [
|
|
|
|
"pyflakes"
|
|
|
|
"pep8-naming"
|
|
|
|
"flake8"
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = with python3.pkgs; [
|
2021-10-04 12:37:57 +00:00
|
|
|
poetry-core
|
2022-12-28 21:21:41 +00:00
|
|
|
pythonRelaxDepsHook
|
2021-10-04 12:37:57 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-12-28 21:21:41 +00:00
|
|
|
propagatedBuildInputs = with python3.pkgs; [
|
2021-10-04 12:37:57 +00:00
|
|
|
bandit
|
2020-04-24 23:36:52 +00:00
|
|
|
dodgy
|
2022-12-28 21:21:41 +00:00
|
|
|
flake8
|
|
|
|
gitpython
|
2020-04-24 23:36:52 +00:00
|
|
|
mccabe
|
2021-10-04 12:37:57 +00:00
|
|
|
mypy
|
2020-04-24 23:36:52 +00:00
|
|
|
pep8-naming
|
|
|
|
pycodestyle
|
|
|
|
pydocstyle
|
|
|
|
pyflakes
|
|
|
|
pylint
|
|
|
|
pylint-celery
|
|
|
|
pylint-django
|
|
|
|
pylint-flask
|
2021-10-04 12:37:57 +00:00
|
|
|
pylint-plugin-utils
|
|
|
|
pyroma
|
2020-04-24 23:36:52 +00:00
|
|
|
pyyaml
|
|
|
|
requirements-detector
|
2021-10-04 12:37:57 +00:00
|
|
|
setoptconf-tmp
|
|
|
|
setuptools
|
|
|
|
toml
|
|
|
|
vulture
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = with python3.pkgs; [
|
2021-10-04 12:37:57 +00:00
|
|
|
pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"prospector"
|
|
|
|
];
|
|
|
|
|
2022-12-28 21:21:41 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# distutils.errors.DistutilsArgError: no commands supplied
|
|
|
|
"tests/tools/pyroma/test_pyroma_tool.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
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";
|
2022-12-28 21:21:41 +00:00
|
|
|
changelog = "https://github.com/PyCQA/prospector/blob/v${version}/CHANGELOG.rst";
|
2022-05-18 14:49:53 +00:00
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
maintainers = with maintainers; [ kamadorueda ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|