From 5bfdf3cdec9329dc36b02938d54ffe1b6da279b1 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 20 Dec 2022 16:54:47 +0100 Subject: [PATCH 1/4] python310Packages.pep8-naming: add changelog to meta --- pkgs/development/python-modules/pep8-naming/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/pep8-naming/default.nix b/pkgs/development/python-modules/pep8-naming/default.nix index 7e9642a2bc28..ffb8c0073b94 100644 --- a/pkgs/development/python-modules/pep8-naming/default.nix +++ b/pkgs/development/python-modules/pep8-naming/default.nix @@ -41,8 +41,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 ]; }; From 4778c3cd3a65640078ebd4ec407d354d865f3aae Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 20 Dec 2022 16:56:10 +0100 Subject: [PATCH 2/4] python310Packages.pep8-naming: 0.13.1 -> 0.13.3 Diff: https://github.com/PyCQA/pep8-naming/compare/0.13.1...0.13.3 Changelog: https://github.com/PyCQA/pep8-naming/blob/0.13.3/CHANGELOG.rst --- .../python-modules/pep8-naming/default.nix | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/pkgs/development/python-modules/pep8-naming/default.nix b/pkgs/development/python-modules/pep8-naming/default.nix index ffb8c0073b94..5fd696523d84 100644 --- a/pkgs/development/python-modules/pep8-naming/default.nix +++ b/pkgs/development/python-modules/pep8-naming/default.nix @@ -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 ]; From fe2f65b8c4d7b2d315086e684c756ab1f234341c Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 20 Dec 2022 17:30:03 +0100 Subject: [PATCH 3/4] prospector: 1.7.7 -> 1.8.3 Diff: https://github.com/PyCQA/prospector/compare/refs/tags/v1.7.7...v1.8.3 --- pkgs/development/tools/prospector/default.nix | 43 ++++++++++--------- 1 file changed, 23 insertions(+), 20 deletions(-) diff --git a/pkgs/development/tools/prospector/default.nix b/pkgs/development/tools/prospector/default.nix index d2855861dc8f..5594e7e083e9 100644 --- a/pkgs/development/tools/prospector/default.nix +++ b/pkgs/development/tools/prospector/default.nix @@ -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,22 +55,20 @@ 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"; From 3c6ee2f1ba8a0416c9c5ef8fd885a7c639cf7292 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 20 Dec 2022 17:50:55 +0100 Subject: [PATCH 4/4] prospector: add changelog to meta --- pkgs/development/tools/prospector/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/development/tools/prospector/default.nix b/pkgs/development/tools/prospector/default.nix index 5594e7e083e9..95b5512c6fca 100644 --- a/pkgs/development/tools/prospector/default.nix +++ b/pkgs/development/tools/prospector/default.nix @@ -72,6 +72,7 @@ python3.pkgs.buildPythonApplication rec { 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 ]; };