diff --git a/.travis.yml b/.travis.yml index c1b212d40..906cc9d4c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -71,6 +71,12 @@ before_install: fi install: - bash ./scripts/ci/install.sh + - pip install flake8 +before_script: + # stop the build if there are Python syntax errors or undefined names + - flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics + # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide + - flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics script: - bash ./scripts/ci/script.sh deploy: