From ffa4ed6a02e6c82d915248eb8a2a62ab56192100 Mon Sep 17 00:00:00 2001 From: Bryce Larson Date: Thu, 26 Sep 2019 16:56:03 -0600 Subject: [PATCH] improve lint job --- .ci/lint | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.ci/lint b/.ci/lint index dee263e46a..d6a680acf5 100644 --- a/.ci/lint +++ b/.ci/lint @@ -46,9 +46,10 @@ wrappedNode('lint', global_timeout, '#jenkins-prod-pr') { eval "$(pyenv init -)" pyenv --version pyenv install --skip-existing 2.7.15 - pyenv shell 2.7.15 + pyenv install --skip-existing 3.6.8 + pyenv shell 3.6.8 2.7.15 python --version - pip install -U nox-py2 + pip3 install -U nox-py2 nox --version # Create the required virtualenvs in serial nox --install-only -e lint-salt @@ -69,7 +70,7 @@ wrappedNode('lint', global_timeout, '#jenkins-prod-pr') { if (readFile('file-list-changed.log') =~ /(?i)(^|\n)(salt\/.*\.py|setup\.py)\n/) { sh shell_header + ''' eval "$(pyenv init - --no-rehash)" - pyenv shell 2.7.15 + pyenv shell 3.6.8 2.7.15 EC=254 export PYLINT_REPORT=pylint-report-salt-chg.log grep -Ei '^salt/.*\\.py$|^setup\\.py$' file-list-changed.log | xargs -r '--delimiter=\\n' nox -e lint-salt -- @@ -80,7 +81,7 @@ wrappedNode('lint', global_timeout, '#jenkins-prod-pr') { // Always lint something so reporting doesn't fail sh shell_header + ''' eval "$(pyenv init - --no-rehash)" - pyenv shell 2.7.15 + pyenv shell 3.6.8 2.7.15 EC=254 export PYLINT_REPORT=pylint-report-salt-chg.log nox -e lint-salt -- salt/ext/__init__.py @@ -95,7 +96,7 @@ wrappedNode('lint', global_timeout, '#jenkins-prod-pr') { if (readFile('file-list-changed.log') =~ /(?i)(^|\n)tests\/.*\.py\n/) { sh shell_header + ''' eval "$(pyenv init - --no-rehash)" - pyenv shell 2.7.15 + pyenv shell 3.6.8 2.7.15 EC=254 export PYLINT_REPORT=pylint-report-tests-chg.log grep -Ei '^tests/.*\\.py$' file-list-changed.log | xargs -r '--delimiter=\\n' nox -e lint-tests -- @@ -128,7 +129,7 @@ wrappedNode('lint', global_timeout, '#jenkins-prod-pr') { stage('Lint Salt Full') { sh shell_header + ''' eval "$(pyenv init - --no-rehash)" - pyenv shell 2.7.15 + pyenv shell 3.6.8 2.7.15 EC=254 export PYLINT_REPORT=pylint-report-salt-full.log nox -e lint-salt @@ -141,7 +142,7 @@ wrappedNode('lint', global_timeout, '#jenkins-prod-pr') { stage('Lint Tests Full') { sh shell_header + ''' eval "$(pyenv init - --no-rehash)" - pyenv shell 2.7.15 + pyenv shell 3.6.8 2.7.15 EC=254 export PYLINT_REPORT=pylint-report-tests-full.log nox -e lint-salt