Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 19.09 51 lines 1.5 kB view raw
1{ stdenv, lib, buildPythonPackage, fetchPypi, astroid, six, isort, 2 mccabe, configparser, backports_functools_lru_cache, singledispatch, 3 pytest, pytestrunner, pyenchant }: 4 5buildPythonPackage rec { 6 pname = "pylint"; 7 version = "1.9.5"; 8 9 src = fetchPypi { 10 inherit pname version; 11 sha256 = "004kfapkqxqy2s85pmddqv0fabxdxywxrlbi549p0v237pr2v94p"; 12 }; 13 14 checkInputs = [ pytest pytestrunner pyenchant ]; 15 16 propagatedBuildInputs = [ astroid six isort mccabe configparser backports_functools_lru_cache singledispatch ]; 17 18 postPatch = lib.optionalString stdenv.isDarwin '' 19 # Remove broken darwin test 20 rm -vf pylint/test/test_functional.py 21 ''; 22 23 checkPhase = '' 24 pytest pylint/test -k "not ${lib.concatStringsSep " and not " ( 25 [ # Broken test 26 "test_good_comprehension_checks" 27 # requires setuptools 28 "test_pkginfo" 29 # See PyCQA/pylint#2535 30 "test_libmodule" ] ++ 31 # Disable broken darwin tests 32 lib.optionals stdenv.isDarwin [ 33 "test_parallel_execution" 34 "test_py3k_jobs_option" 35 ] 36 )}" 37 ''; 38 39 postInstall = '' 40 mkdir -p $out/share/emacs/site-lisp 41 cp "elisp/"*.el $out/share/emacs/site-lisp/ 42 ''; 43 44 meta = with lib; { 45 homepage = https://github.com/PyCQA/pylint; 46 description = "A bug and style checker for Python"; 47 platforms = platforms.all; 48 license = licenses.gpl1Plus; 49 maintainers = with maintainers; [ nand0p ]; 50 }; 51}