1{ stdenv, buildPythonPackage, fetchPypi, python, pythonOlder, astroid, isort,
2 pytest, pytestrunner, mccabe, pytest_xdist, pyenchant }:
3
4buildPythonPackage rec {
5 pname = "pylint";
6 version = "2.1.1";
7
8 disabled = pythonOlder "3.4";
9
10 src = fetchPypi {
11 inherit pname version;
12 sha256 = "31142f764d2a7cd41df5196f9933b12b7ee55e73ef12204b648ad7e556c119fb";
13 };
14
15 checkInputs = [ pytest pytestrunner pytest_xdist pyenchant ];
16
17 propagatedBuildInputs = [ astroid isort mccabe ];
18
19 postPatch = ''
20 # Remove broken darwin test
21 rm -vf pylint/test/test_functional.py
22 '';
23
24 checkPhase = ''
25 cat pylint/test/test_self.py
26 # Disable broken darwin tests
27 pytest pylint/test -k "not test_parallel_execution \
28 and not test_py3k_jobs_option \
29 and not test_good_comprehension_checks"
30 '';
31
32 postInstall = ''
33 mkdir -p $out/share/emacs/site-lisp
34 cp "elisp/"*.el $out/share/emacs/site-lisp/
35 '';
36
37 meta = with stdenv.lib; {
38 homepage = https://www.logilab.org/project/pylint;
39 description = "A bug and style checker for Python";
40 platforms = platforms.all;
41 license = licenses.gpl1Plus;
42 maintainers = with maintainers; [ nand0p ];
43 };
44}