Run Python flake8 tests on several Nodejs repos
DO NOT MERGE: This PR uses Travis CI to run the flake8 linter on several Nodejs repos that contain Python code to detect syntax errors and undefined names which can raise NameError at runtime. There is a discussion in https://github.com/nodejs/node-gyp/pull/1336 about the importance of using tools like Travis CI to automate the discovery of code quality issues.
E901,E999,F821,F822,F823 are the "showstopper" flake8 issues that can halt the runtime with a SyntaxError, NameError, etc. Most other flake8 issues are merely "style violations" -- useful for readability but they do not effect runtime safety. This PR therefore demonstrates such a flake8 run these Nodejs codebases.
- F821: undefined name
name
- F822: undefined name
name
in__all__
- F823: local variable
name
referenced before assignment - E901: SyntaxError or IndentationError
- E999: SyntaxError -- failed to compile a file into an Abstract Syntax Tree
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines