Parallelize pylint everywhere (#28149)

* Run 2 pylint jobs by default

* Run pylint with autodetected number of jobs in Travis

Gives a ~25% speedup there at the moment.
This commit is contained in:
Ville Skyttä 2019-10-23 23:18:41 +03:00 committed by Paulus Schoutsen
parent 7cb6607b1f
commit 6a731a68cd
4 changed files with 6 additions and 3 deletions

View file

@ -19,7 +19,7 @@ matrix:
- python: "3.6.1"
env: TOXENV=lint
- python: "3.6.1"
env: TOXENV=pylint
env: TOXENV=pylint PYLINT_ARGS=--jobs=0
- python: "3.6.1"
env: TOXENV=typing
- python: "3.6.1"

View file

@ -167,7 +167,7 @@ stages:
displayName: 'Install Home Assistant'
- script: |
. venv/bin/activate
pylint -j 2 homeassistant
pylint homeassistant
displayName: 'Run pylint'
- job: 'Mypy'
pool:

View file

@ -1,5 +1,8 @@
[MASTER]
ignore=tests
# Use a conservative default here; 2 should speed up most setups and not hurt
# any too bad. Override on command line as appropriate.
jobs=2
[BASIC]
good-names=id,i,j,k,ex,Run,_,fp

View file

@ -26,7 +26,7 @@ deps =
-r{toxinidir}/requirements_test.txt
-c{toxinidir}/homeassistant/package_constraints.txt
commands =
pylint {posargs} homeassistant
pylint {env:PYLINT_ARGS} {posargs} homeassistant
[testenv:lint]
deps =