Merge pull request #207020 from fabaff/pep8-naming-fix

python310Packages.pep8-naming: 0.13.1 -> 0.13.3, prospector: 1.7.7 -> 1.8.3
This commit is contained in:
Fabian Affolter
2022-12-21 08:17:05 +01:00
committed by GitHub
2 changed files with 32 additions and 33 deletions
@@ -1,31 +1,25 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, fetchpatch
, flake8
, python
, pythonOlder
}:
buildPythonPackage rec {
pname = "pep8-naming";
version = "0.13.1";
version = "0.13.3";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "PyCQA";
repo = pname;
rev = version;
sha256 = "sha256-NG4hLZcOMKprUyMnzkHRmUCFGyYgvT6ydBQNpgWE9h0=";
hash = "sha256-l7zZUOMWyTxnTbkFkzfABY/eVMKnv0kNJ0UPzJo0W1Y=";
};
patches = [
# Fixes tests for flake8 => 5
# Remove on next release
(fetchpatch {
url = "https://github.com/PyCQA/pep8-naming/commit/c8808a0907f64b5d081cff8d3f9443e5ced1474e.patch";
sha256 = "sha256-4c+a0viS0rXuxj+TuIfgrKZjnrjiJjDoYBbNp3+6Ed0=";
})
];
propagatedBuildInputs = [
flake8
];
@@ -41,8 +35,9 @@ buildPythonPackage rec {
];
meta = with lib; {
homepage = "https://github.com/PyCQA/pep8-naming";
description = "Check PEP-8 naming conventions, plugin for flake8";
homepage = "https://github.com/PyCQA/pep8-naming";
changelog = "https://github.com/PyCQA/pep8-naming/blob/${version}/CHANGELOG.rst";
license = licenses.mit;
maintainers = with maintainers; [ eadwu ];
};
+24 -20
View File
@@ -7,29 +7,34 @@ let
setoptconf-tmp = python3.pkgs.callPackage ./setoptconf.nix { };
in
with python3.pkgs;
buildPythonApplication rec {
python3.pkgs.buildPythonApplication rec {
pname = "prospector";
version = "1.7.7";
version = "1.8.3";
format = "pyproject";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "PyCQA";
repo = pname;
rev = version;
hash = "sha256-sbPZmVeJtNphtjuZEfKcUgty9bJ3E/2Ya9RuX3u/XEs=";
rev = "refs/tags/v${version}";
hash = "sha256-R3Sc4Qx6bht+XJhNj+fy32akzDOgSDF5LP3WE1qEyms=";
};
nativeBuildInputs = [
poetry-core
pythonRelaxDeps = [
"pyflakes"
"pep8-naming"
"flake8"
];
propagatedBuildInputs = [
nativeBuildInputs = with python3.pkgs; [
poetry-core
pythonRelaxDepsHook
];
propagatedBuildInputs = with python3.pkgs; [
bandit
dodgy
flake8
gitpython
mccabe
mypy
pep8-naming
@@ -50,25 +55,24 @@ buildPythonApplication rec {
vulture
];
checkInputs = [
checkInputs = with python3.pkgs; [
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 = "*"' \
--replace 'pycodestyle = ">=2.6.0,<2.9.0"' 'pycodestyle = "*"'
'';
pythonImportsCheck = [
"prospector"
];
disabledTestPaths = [
# distutils.errors.DistutilsArgError: no commands supplied
"tests/tools/pyroma/test_pyroma_tool.py"
];
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";
changelog = "https://github.com/PyCQA/prospector/blob/v${version}/CHANGELOG.rst";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ kamadorueda ];
};