mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-11 22:54:17 +00:00
Merge pull request #201080 from tjni/pylint
This commit is contained in:
commit
066c3806b2
@ -1,12 +1,10 @@
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pythonAtLeast
|
||||
, pythonOlder
|
||||
, isPyPy
|
||||
, lazy-object-proxy
|
||||
, setuptools
|
||||
, setuptools-scm
|
||||
, typing-extensions
|
||||
, typed-ast
|
||||
, pylint
|
||||
@ -16,26 +14,24 @@
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "astroid";
|
||||
version = "2.11.7"; # Check whether the version is compatible with pylint
|
||||
version = "2.12.12"; # Check whether the version is compatible with pylint
|
||||
format = "pyproject";
|
||||
|
||||
disabled = pythonOlder "3.6.2";
|
||||
disabled = pythonOlder "3.7.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "PyCQA";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-HpniGxKf+daMh/sxP9T9UriYRrUFWqk7kDa8r+EqtVI=";
|
||||
hash = "sha256-FN/bBAxx9p1iAB3WXIZyyKv/zse7xtXzslclADMbouA=";
|
||||
};
|
||||
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
||||
nativeBuildInputs = [
|
||||
setuptools-scm
|
||||
setuptools
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
lazy-object-proxy
|
||||
setuptools
|
||||
wrapt
|
||||
] ++ lib.optionals (pythonOlder "3.10") [
|
||||
typing-extensions
|
||||
@ -45,11 +41,7 @@ buildPythonPackage rec {
|
||||
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
disabledTests = [
|
||||
# AssertionError: Lists differ: ['ABC[16 chars]yBase', 'Final', 'Generic', 'MyProtocol', 'Protocol', 'object'] != ['ABC[16 chars]yBase', 'Final', 'Generic', 'MyProtocol', 'object']
|
||||
"test_mro_typing_extensions"
|
||||
typing-extensions
|
||||
];
|
||||
|
||||
passthru.tests = {
|
||||
|
@ -41,7 +41,7 @@ buildPythonPackage rec {
|
||||
propagatedBuildInputs = [
|
||||
z3
|
||||
astroid
|
||||
];
|
||||
] ++ z3.requiredPythonModules;
|
||||
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
|
@ -2,6 +2,7 @@
|
||||
, lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, pythonOlder
|
||||
, installShellFiles
|
||||
, astroid
|
||||
@ -9,6 +10,8 @@
|
||||
, isort
|
||||
, mccabe
|
||||
, platformdirs
|
||||
, requests
|
||||
, setuptools
|
||||
, tomli
|
||||
, tomlkit
|
||||
, typing-extensions
|
||||
@ -20,8 +23,8 @@
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pylint";
|
||||
version = "2.14.5";
|
||||
format = "setuptools";
|
||||
version = "2.15.5";
|
||||
format = "pyproject";
|
||||
|
||||
disabled = pythonOlder "3.7.2";
|
||||
|
||||
@ -29,11 +32,25 @@ buildPythonPackage rec {
|
||||
owner = "PyCQA";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-JTFGplqIA6WavwzKOkrm1rHBKNRrplBPvAdEkb/fTlI=";
|
||||
hash = "sha256-dchzwMaUhHB1TqcaMZO9tCZ4KA5I1T+tdkGOxikm5AY=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
name = "fix-dummy-plugin-tests.patch";
|
||||
url = "https://github.com/PyCQA/pylint/commit/e75089bae209d1b9ca72903c0d65530b02f67fdf.patch";
|
||||
hash = "sha256-4ErlCMLTI5xIu1dCvcJsvo03dwcgLLbFFQ5M7DFdL3o=";
|
||||
})
|
||||
(fetchpatch {
|
||||
name = "fix-pythonpath-tests.patch";
|
||||
url = "https://github.com/PyCQA/pylint/commit/6725f761f2ac7a853e315790b496a2eb4d926694.patch";
|
||||
hash = "sha256-Xaeub7uUaC07BBuusA6+neGiXFWWfVNBkGXmYJe7ot4=";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
installShellFiles
|
||||
setuptools
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
@ -61,6 +78,7 @@ buildPythonPackage rec {
|
||||
pytest-timeout
|
||||
pytest-xdist
|
||||
pytestCheckHook
|
||||
requests
|
||||
typing-extensions
|
||||
];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user