Details
-
Improvement
-
Status: Open
-
Normal
-
Resolution: Unresolved
-
None
-
None
-
Semantic
-
Low Hanging Fruit
-
All
-
None
Description
The contributing page of cassandra-test contains instructions to setup git hook to run flake8 on commit:
flake8 --install-hook
git config flake8.strict true
git config flake8.ignore E501,F811,F812,F821,F822,F823,F831,F841,N8,C9
I insulted flake8 and followed the instruction and after I committed changes to conftest.py, I've got many E501 errors:
conftest.py:21:80: E501 line too long (85 > 79 characters) conftest.py:31:80: E501 line too long (98 > 79 characters) conftest.py:32:80: E501 line too long (96 > 79 characters) conftest.py:33:80: E501 line too long (96 > 79 characters) conftest.py:34:80: E501 line too long (96 > 79 characters) conftest.py:35:80: E501 line too long (90 > 79 characters) conftest.py:39:80: E501 line too long (85 > 79 characters) ...
This means that the ignore configuration is not used, and I don't see if there is any workaround except removing the commit hook manually.
According to flake8 documentation the instructions are applicable to an old version of flake8, e.g, 2.6.0. This page doesn't exist in the latest version of flake8. The latest documentation has instructions, which suggests to use pre-commit package, and doesn't recommend to use the old way, since it is not tested well.
Will it be good idea to update instructions?