diff options
author | Calum Lind <calumlind+deluge@gmail.com> | 2021-01-17 15:48:35 +0000 |
---|---|---|
committer | Calum Lind <calumlind+deluge@gmail.com> | 2021-01-24 20:40:20 +0000 |
commit | 610a1bb3139f8ded69561b290d7ce61b5a039676 (patch) | |
tree | 4e18e880de320e248e0f079adab74fe1c67157f8 /.travis.yml | |
parent | 23a48dd01c86ef01cd1d13371de51247ec9a503b (diff) | |
download | deluge-610a1bb3139f8ded69561b290d7ce61b5a039676.tar.gz deluge-610a1bb3139f8ded69561b290d7ce61b5a039676.tar.bz2 deluge-610a1bb3139f8ded69561b290d7ce61b5a039676.zip |
[Lint] Update pre-commit hook and isort versions
* Fixed black hook requiring Py3.6 to installed locally. Will now assume
Py3.6+ in installed.
* Added isort traceback in pre-commit flake8 hook fails
* Updated versions of Black, Prettier and isort
* Keep Flake8 at 3.7.9 due to E402 issue: https://gitlab.com/pycqa/flake8/-/issues/638
* New pyproject config for isort v5 with fixes for Python 2 imports.
* Fixed travis config to run Python 3.6 for lint run. Replaced the
virtualenv with_system_site_packages config with Travis specific Python
config value so lint run doesn't attempt to append with_system_site_packages
to Python 3.6 command.
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/.travis.yml b/.travis.yml index b10ec78a9..ac4c79b1c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,10 +4,8 @@ dist: xenial language: python python: # Travis Xenial Python to support system_site_packages - - 3.5 + - 3.5_with_system_site_packages cache: pip -virtualenv: - system_site_packages: true env: global: @@ -21,19 +19,20 @@ jobs: include: - name: Unit tests env: TOX_ENV=py3 - - name: Unit tests - libtorrent 1.2 - env: TOX_ENV=py3 - addons: - apt: - sources: [sourceline: "ppa:libtorrent.org/1.2-daily"] - packages: [python3-libtorrent, python3-venv] + #~ - name: Unit tests - libtorrent 1.2 + #~ env: TOX_ENV=py3 + #~ addons: + #~ apt: + #~ sources: [sourceline: "ppa:libtorrent.org/1.2-daily"] + #~ packages: [python3-libtorrent, python3-venv] - name: Unit tests - Python 2 env: TOX_ENV=py27 - python: 2.7 + python: 2.7_with_system_site_packages - if: commit_message =~ SECURITY_TEST env: TOX_ENV=security - name: Code linting env: TOX_ENV=lint + python: 3.6 - name: Docs build env: TOX_ENV=docs - name: GTK unit tests @@ -73,7 +72,9 @@ install: before_script: - export PYTHONPATH=$PYTHONPATH:$PWD # Verify libtorrent installed and version - - python -c "import libtorrent as lt; print(lt.__version__)" + - "if [ $TOX_ENV != 'lint' ]; then + python -c 'import libtorrent as lt; print(lt.__version__)'; + fi" # Start xvfb for the GTKUI tests - "if [ $TOX_ENV == 'gtkui' ]; then /sbin/start-stop-daemon --start --quiet --background \ |