diff --git a/pkgs/build-support/writers/default.nix b/pkgs/build-support/writers/default.nix index 4b4d4bb203e0..3797df56afa5 100644 --- a/pkgs/build-support/writers/default.nix +++ b/pkgs/build-support/writers/default.nix @@ -240,9 +240,9 @@ rec { then "${python}/bin/python" else "${python.withPackages (ps: libraries)}/bin/python" ; - check = writeDash "python2check.sh" '' + check = optionalString python.isPy3k (writeDash "pythoncheck.sh" '' exec ${pythonPackages.flake8}/bin/flake8 --show-source ${ignoreAttribute} "$1" - ''; + ''); } name; # writePython2 takes a name an attributeset with libraries and some python2 sourcecode and diff --git a/pkgs/development/python-modules/flake8/default.nix b/pkgs/development/python-modules/flake8/default.nix index 7f51cd2703c4..c707cb3caaa1 100644 --- a/pkgs/development/python-modules/flake8/default.nix +++ b/pkgs/development/python-modules/flake8/default.nix @@ -51,6 +51,8 @@ buildPythonPackage rec { pytestCheckHook ]; + disabled = pythonOlder "3.6"; + meta = with lib; { description = "Flake8 is a wrapper around pyflakes, pycodestyle and mccabe."; homepage = "https://github.com/pycqa/flake8";