Skip to content

Commit

Permalink
Don't depend on flake8 at runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
deivid-rodriguez committed Mar 14, 2023
1 parent 6c0e305 commit c2aa020
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
1 change: 1 addition & 0 deletions python/helpers/dev-requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
flake8==5.0.4
1 change: 0 additions & 1 deletion python/helpers/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
pip>=21.3.1,<23.1.0 # Range maintains py36 support TODO: Review python 3.6 support in April 2023 (eol ubuntu 18.04)
pip-tools>=6.4.0,<=6.12.3 # Range maintains py36 support TODO: Review python 3.6 support in April 2023 (eol ubuntu 18.04)
flake8==5.0.4
hashin==0.17.0
pipenv==2022.4.8
pipfile==0.0.2
Expand Down
12 changes: 11 additions & 1 deletion python/script/ci-test
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,16 @@

set -e

# Not yet true but sets the example to follow after Python 3.6 support is dropped
OLDEST_SUPPORTED_PYTHON=3.7

if [ -s /usr/local/.pyenv/$OLDEST_SUPPORTED_PYTHON.tar.gz ]
then
tar xzf /usr/local/.pyenv/$OLDEST_SUPPORTED_PYTHON.tar.gz -C /usr/local/.pyenv/
fi

PYENV_VERSION=$OLDEST_SUPPORTED_PYTHON pyenv exec pip --disable-pip-version-check install --use-pep517 -r "helpers/dev-requirements.txt"
bundle install
pyenv exec flake8 helpers/. --count --exclude=./.*,./python/spec/fixtures --show-source --statistics

PYENV_VERSION=$OLDEST_SUPPORTED_PYTHON pyenv exec flake8 helpers/. --count --exclude=./.*,./python/spec/fixtures --show-source --statistics
bundle exec parallel_test spec/ -n "$CI_NODE_TOTAL" --only-group "$CI_NODE_INDEX" --group-by filesize --type rspec

0 comments on commit c2aa020

Please sign in to comment.