Skip to content

Commit

Permalink
Try again to test with Python 3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
bmerry committed Dec 3, 2019
1 parent f2d64bc commit c5a9ebb
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 15 deletions.
16 changes: 1 addition & 15 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,5 @@ python:
- 3.6
- 3.7
- 3.8
script:
- python -Werror
-Wignore::DeprecationWarning:site
-Wignore::PendingDeprecationWarning:nose.importer
-Wignore::DeprecationWarning:nose.importer
-Wignore::DeprecationWarning:nose.suite
-Wignore::DeprecationWarning:asynctest.mock
-Wignore::DeprecationWarning:asynctest.case
-Wignore::DeprecationWarning:asynctest.helpers
`which nosetests` --with-coverage --cover-erase --cover-package aiokatcp
# The pinned version of flake8 doesn't work with Python 3.8
# (and it can't be upgraded until https://github.com/PyCQA/pyflakes/issues/445
# is fixed).
- if python --version | grep -v 'Python 3\.8\.'; then flake8 aiokatcp examples; fi
- mypy aiokatcp examples
script: .travis/run.sh
after_success: coveralls
26 changes: 26 additions & 0 deletions .travis/run.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/bin/bash
set -e -u

py38="$(python -c 'import sys; print(sys.version_info >= (3, 8))')"
if [ "$py38" = "True" ]; then
# Python 3.8 deprecates some features still needed to support 3.5
warn_args=""
else
warn_args="
-Werror
-Wignore::DeprecationWarning:site
-Wignore::PendingDeprecationWarning:nose.importer
-Wignore::DeprecationWarning:nose.importer
-Wignore::DeprecationWarning:nose.suite"
fi

set -x
python $warn_args `which nosetests` --with-coverage --cover-erase --cover-package aiokatcp
# The pinned version of flake8 doesn't work with Python 3.8
# (and it can't be upgraded until https://github.com/PyCQA/pyflakes/issues/445
# is fixed).
if [ "$py38" = "False" ]; then
flake8 aiokatcp examples
fi
mypy aiokatcp examples

0 comments on commit c5a9ebb

Please sign in to comment.