Use requirements files for tox dependencies
While this makes things a little more complicated and means we'll need to use `-r` to recreate tox environments, it has several advantages: - Full support from requires.io (including PRs) - Workaround for https://bitbucket.org/hpk42/tox/issues/332/ so we can update virtualenv/pip
This commit is contained in:
parent
cd7b8c65df
commit
6f6303e0a6
@ -5,7 +5,6 @@ cache:
|
|||||||
build: off
|
build: off
|
||||||
environment:
|
environment:
|
||||||
PYTHONUNBUFFERED: 1
|
PYTHONUNBUFFERED: 1
|
||||||
VIRTUALENV_DOWNLOAD: no
|
|
||||||
matrix:
|
matrix:
|
||||||
- TESTENV: py34
|
- TESTENV: py34
|
||||||
- TESTENV: unittests-frozen
|
- TESTENV: unittests-frozen
|
||||||
|
@ -45,9 +45,6 @@ cache:
|
|||||||
before_install:
|
before_install:
|
||||||
# We need to do this so we pick up the system-wide python properly
|
# We need to do this so we pick up the system-wide python properly
|
||||||
- 'export PATH="/usr/bin:$PATH"'
|
- 'export PATH="/usr/bin:$PATH"'
|
||||||
# And this to stop virtualenv from upgrading pip, see
|
|
||||||
# https://github.com/The-Compiler/qutebrowser/issues/1486
|
|
||||||
- 'export VIRTUALENV_DOWNLOAD=no'
|
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- bash scripts/dev/ci/travis_install.sh
|
- bash scripts/dev/ci/travis_install.sh
|
||||||
|
2
misc/requirements/README.md
Normal file
2
misc/requirements/README.md
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
This directory contains various `requirements` files which are used by `tox` to
|
||||||
|
have reproducable tests with pinned versions.
|
1
misc/requirements/requirements-check-manifest.txt
Normal file
1
misc/requirements/requirements-check-manifest.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
check-manifest==0.31
|
1
misc/requirements/requirements-cxfreeze.txt
Normal file
1
misc/requirements/requirements-cxfreeze.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
cx_Freeze==4.3.4
|
27
misc/requirements/requirements-flake8.txt
Normal file
27
misc/requirements/requirements-flake8.txt
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
ebb-lint==0.4.4
|
||||||
|
flake8==2.5.4
|
||||||
|
flake8-copyright==0.1
|
||||||
|
flake8-debugger==1.4.0
|
||||||
|
flake8-deprecated==1.0
|
||||||
|
flake8-docstrings==0.2.6
|
||||||
|
flake8-future-import==0.3.2
|
||||||
|
flake8-mock==0.2
|
||||||
|
flake8-pep3101==0.3
|
||||||
|
flake8-putty==0.3.2
|
||||||
|
flake8-string-format==0.2.2
|
||||||
|
flake8-tidy-imports==1.0.0
|
||||||
|
flake8-tuple==0.2.9
|
||||||
|
hacking==0.11.0
|
||||||
|
intervaltree==2.1.0
|
||||||
|
mccabe==0.4.0
|
||||||
|
packaging==16.7
|
||||||
|
pbr==1.10.0
|
||||||
|
pep257==0.7.0 # still needed by flake8-docstrings but ignored
|
||||||
|
pep8==1.7.0
|
||||||
|
pep8-naming==0.3.3
|
||||||
|
pydocstyle==1.0.0
|
||||||
|
pyflakes==1.2.3
|
||||||
|
pyparsing==2.1.4
|
||||||
|
six==1.10.0
|
||||||
|
sortedcontainers==1.5.2
|
||||||
|
venusian==1.0
|
1
misc/requirements/requirements-pyinstaller.txt
Normal file
1
misc/requirements/requirements-pyinstaller.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
PyInstaller==3.2
|
4
misc/requirements/requirements-pylint-master.txt
Normal file
4
misc/requirements/requirements-pylint-master.txt
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
git+https://github.com/PyCQA/astroid.git
|
||||||
|
git+https://github.com/PyCQA/pylint.git
|
||||||
|
requests==2.10.0
|
||||||
|
./scripts/dev/pylint_checkers
|
4
misc/requirements/requirements-pylint.txt
Normal file
4
misc/requirements/requirements-pylint.txt
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
astroid==1.4.5
|
||||||
|
pylint==1.5.5
|
||||||
|
requests==2.10.0
|
||||||
|
./scripts/dev/pylint_checkers
|
2
misc/requirements/requirements-pyroma.txt
Normal file
2
misc/requirements/requirements-pyroma.txt
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
pyroma==2.0.2
|
||||||
|
docutils==0.12
|
30
misc/requirements/requirements-tests.txt
Normal file
30
misc/requirements/requirements-tests.txt
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
beautifulsoup4==4.4.1
|
||||||
|
coverage==4.1
|
||||||
|
decorator==4.0.9
|
||||||
|
Flask==0.10.1 # rq.filter: != 0.11.0
|
||||||
|
glob2==0.4.1
|
||||||
|
httpbin==0.4.1
|
||||||
|
hypothesis==3.4.0
|
||||||
|
itsdangerous==0.24
|
||||||
|
Mako==1.0.4
|
||||||
|
parse==1.6.6
|
||||||
|
parse-type==0.3.4
|
||||||
|
py==1.4.31
|
||||||
|
pytest==2.9.1
|
||||||
|
pytest-bdd==2.16.1
|
||||||
|
pytest-catchlog==1.2.2
|
||||||
|
pytest-cov==2.2.1
|
||||||
|
pytest-faulthandler==1.3.0
|
||||||
|
pytest-mock==1.0.0
|
||||||
|
pytest-qt==1.11.0
|
||||||
|
pytest-instafail==0.3.0
|
||||||
|
pytest-travis-fold==1.2.0
|
||||||
|
pytest-repeat==0.2
|
||||||
|
pytest-rerunfailures==2.0.0
|
||||||
|
pytest-xvfb==0.2.0
|
||||||
|
six==1.10.0
|
||||||
|
termcolor==1.1.0
|
||||||
|
vulture==0.8.1
|
||||||
|
Werkzeug==0.11.10
|
||||||
|
wheel==0.29.0
|
||||||
|
cherrypy==5.4.0
|
4
misc/requirements/requirements-tox.txt
Normal file
4
misc/requirements/requirements-tox.txt
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
pluggy==0.3.1
|
||||||
|
py==1.4.31
|
||||||
|
tox==2.3.1
|
||||||
|
virtualenv==15.0.2
|
1
misc/requirements/requirements-vulture.txt
Normal file
1
misc/requirements/requirements-vulture.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
vulture==0.8.1
|
@ -66,8 +66,8 @@ print("Installing PyQt5...")
|
|||||||
subprocess.check_call([r'C:\install-PyQt5.exe', '/S'])
|
subprocess.check_call([r'C:\install-PyQt5.exe', '/S'])
|
||||||
|
|
||||||
print("Installing pip/tox")
|
print("Installing pip/tox")
|
||||||
pip_install(r'-rscripts\dev\ci\requirements-pip.txt')
|
pip_install(r'-rmisc\requirements\requirements-pip.txt')
|
||||||
pip_install(r'-rscripts\dev\ci\requirements-tox.txt')
|
pip_install(r'-rmisc\requirements\requirements-tox.txt')
|
||||||
|
|
||||||
print("Linking Python...")
|
print("Linking Python...")
|
||||||
with open(r'C:\Windows\system32\python3.bat', 'w') as f:
|
with open(r'C:\Windows\system32\python3.bat', 'w') as f:
|
||||||
|
@ -1,4 +0,0 @@
|
|||||||
pluggy==0.3.1
|
|
||||||
py==1.4.31
|
|
||||||
tox==2.3.1
|
|
||||||
virtualenv==15.0.1 # rq.filter: <= 15.0.1
|
|
@ -54,7 +54,7 @@ brew_install() {
|
|||||||
|
|
||||||
pip_install() {
|
pip_install() {
|
||||||
# this uses python2
|
# this uses python2
|
||||||
travis_retry sudo -H python -m pip install -r scripts/dev/ci/requirements-$1.txt
|
travis_retry sudo -H python -m pip install -r misc/requirements/requirements-$1.txt
|
||||||
}
|
}
|
||||||
|
|
||||||
npm_install() {
|
npm_install() {
|
||||||
|
85
tox.ini
85
tox.ini
@ -14,36 +14,7 @@ setenv =
|
|||||||
passenv = PYTHON DISPLAY XAUTHORITY HOME USERNAME USER CI TRAVIS XDG_*
|
passenv = PYTHON DISPLAY XAUTHORITY HOME USERNAME USER CI TRAVIS XDG_*
|
||||||
deps =
|
deps =
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
beautifulsoup4==4.4.1
|
-r{toxinidir}/misc/requirements/requirements-tests.txt
|
||||||
coverage==4.1
|
|
||||||
decorator==4.0.9
|
|
||||||
Flask==0.10.1 # rq.filter: != 0.11.0
|
|
||||||
glob2==0.4.1
|
|
||||||
httpbin==0.4.1
|
|
||||||
hypothesis==3.4.0
|
|
||||||
itsdangerous==0.24
|
|
||||||
Mako==1.0.4
|
|
||||||
parse==1.6.6
|
|
||||||
parse-type==0.3.4
|
|
||||||
py==1.4.31
|
|
||||||
pytest==2.9.1
|
|
||||||
pytest-bdd==2.16.1
|
|
||||||
pytest-catchlog==1.2.2
|
|
||||||
pytest-cov==2.2.1
|
|
||||||
pytest-faulthandler==1.3.0
|
|
||||||
pytest-mock==1.0.0
|
|
||||||
pytest-qt==1.11.0
|
|
||||||
pytest-instafail==0.3.0
|
|
||||||
pytest-travis-fold==1.2.0
|
|
||||||
pytest-repeat==0.2
|
|
||||||
pytest-rerunfailures==2.0.0
|
|
||||||
pytest-xvfb==0.2.0
|
|
||||||
six==1.10.0
|
|
||||||
termcolor==1.1.0
|
|
||||||
vulture==0.8.1
|
|
||||||
Werkzeug==0.11.10
|
|
||||||
wheel==0.29.0
|
|
||||||
cherrypy==5.4.0
|
|
||||||
commands =
|
commands =
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
{envpython} -m pytest {posargs:tests}
|
{envpython} -m pytest {posargs:tests}
|
||||||
@ -91,7 +62,7 @@ passenv = {[testenv]passenv}
|
|||||||
skip_install = true
|
skip_install = true
|
||||||
deps =
|
deps =
|
||||||
{[testenv]deps}
|
{[testenv]deps}
|
||||||
cx_Freeze==4.3.4
|
-r{toxinidir}/misc/requirements/requirements-cxfreeze.txt
|
||||||
commands =
|
commands =
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
{envpython} scripts/dev/freeze_tests.py build_exe -b {envdir}/build
|
{envpython} scripts/dev/freeze_tests.py build_exe -b {envdir}/build
|
||||||
@ -110,7 +81,7 @@ commands =
|
|||||||
|
|
||||||
[testenv:vulture]
|
[testenv:vulture]
|
||||||
basepython = python3
|
basepython = python3
|
||||||
deps = vulture==0.8.1
|
deps = -r{toxinidir}/misc/requirements/requirements-vulture.txt
|
||||||
commands =
|
commands =
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
{envpython} scripts/dev/run_vulture.py
|
{envpython} scripts/dev/run_vulture.py
|
||||||
@ -121,11 +92,7 @@ ignore_errors = true
|
|||||||
passenv =
|
passenv =
|
||||||
deps =
|
deps =
|
||||||
{[testenv]deps}
|
{[testenv]deps}
|
||||||
{[testenv:misc]deps}
|
-r{toxinidir}/misc/requirements/requirements-pylint.txt
|
||||||
astroid==1.4.5
|
|
||||||
pylint==1.5.5
|
|
||||||
requests==2.10.0
|
|
||||||
./scripts/dev/pylint_checkers
|
|
||||||
commands =
|
commands =
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
{envpython} -m pylint scripts qutebrowser --output-format=colorized --reports=no {posargs}
|
{envpython} -m pylint scripts qutebrowser --output-format=colorized --reports=no {posargs}
|
||||||
@ -137,10 +104,6 @@ passenv = {[testenv:pylint]passenv}
|
|||||||
deps =
|
deps =
|
||||||
{[testenv]deps}
|
{[testenv]deps}
|
||||||
{[testenv:misc]deps}
|
{[testenv:misc]deps}
|
||||||
git+https://github.com/PyCQA/astroid.git
|
|
||||||
git+https://github.com/PyCQA/pylint.git
|
|
||||||
requests==2.10.0
|
|
||||||
./scripts/dev/pylint_checkers
|
|
||||||
commands =
|
commands =
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
{envpython} -m pylint scripts qutebrowser --output-format=colorized --reports=no {posargs}
|
{envpython} -m pylint scripts qutebrowser --output-format=colorized --reports=no {posargs}
|
||||||
@ -151,34 +114,7 @@ basepython = python3
|
|||||||
passenv =
|
passenv =
|
||||||
deps =
|
deps =
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
ebb-lint==0.4.4
|
-r{toxinidir}/misc/requirements/requirements-flake8.txt
|
||||||
flake8==2.5.4
|
|
||||||
flake8-copyright==0.1
|
|
||||||
flake8-debugger==1.4.0
|
|
||||||
flake8-deprecated==1.0
|
|
||||||
flake8-docstrings==0.2.6
|
|
||||||
flake8-future-import==0.3.2
|
|
||||||
flake8-mock==0.2
|
|
||||||
flake8-pep3101==0.3
|
|
||||||
flake8-putty==0.3.2
|
|
||||||
flake8-string-format==0.2.2
|
|
||||||
flake8-tidy-imports==1.0.0
|
|
||||||
flake8-tuple==0.2.9
|
|
||||||
hacking==0.11.0
|
|
||||||
intervaltree==2.1.0
|
|
||||||
mccabe==0.4.0
|
|
||||||
packaging==16.7
|
|
||||||
pbr==1.10.0
|
|
||||||
# still needed by flake8-docstrings but ignored
|
|
||||||
pep257==0.7.0
|
|
||||||
pep8==1.7.0
|
|
||||||
pep8-naming==0.3.3
|
|
||||||
pydocstyle==1.0.0
|
|
||||||
pyflakes==1.2.3
|
|
||||||
pyparsing==2.1.4
|
|
||||||
six==1.10.0
|
|
||||||
sortedcontainers==1.5.2
|
|
||||||
venusian==1.0
|
|
||||||
commands =
|
commands =
|
||||||
{envpython} -m flake8
|
{envpython} -m flake8
|
||||||
|
|
||||||
@ -186,9 +122,7 @@ commands =
|
|||||||
basepython = python3
|
basepython = python3
|
||||||
skip_install = true
|
skip_install = true
|
||||||
passenv =
|
passenv =
|
||||||
deps =
|
deps = -r{toxinidir}/misc/requirements/requirements-pyroma.txt
|
||||||
pyroma==2.0.2
|
|
||||||
docutils==0.12
|
|
||||||
commands =
|
commands =
|
||||||
{envdir}/bin/pyroma .
|
{envdir}/bin/pyroma .
|
||||||
|
|
||||||
@ -196,8 +130,7 @@ commands =
|
|||||||
basepython = python3
|
basepython = python3
|
||||||
skip_install = true
|
skip_install = true
|
||||||
passenv =
|
passenv =
|
||||||
deps =
|
deps = -r{toxinidir}/misc/requirements/requirements-check-manifest.txt
|
||||||
check-manifest==0.31
|
|
||||||
commands =
|
commands =
|
||||||
{envdir}/bin/check-manifest --ignore 'qutebrowser/git-commit-id,qutebrowser/html/doc,qutebrowser/html/doc/*,*/__pycache__'
|
{envdir}/bin/check-manifest --ignore 'qutebrowser/git-commit-id,qutebrowser/html/doc,qutebrowser/html/doc/*,*/__pycache__'
|
||||||
|
|
||||||
@ -221,7 +154,7 @@ basepython = {env:PYTHON:}/python.exe
|
|||||||
skip_install = true
|
skip_install = true
|
||||||
deps =
|
deps =
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
cx_Freeze==4.3.4
|
-r{toxinidir}/misc/requirements/requirements-cxfreeze.txt
|
||||||
commands =
|
commands =
|
||||||
{envpython} -m pip install -U setuptools
|
{envpython} -m pip install -U setuptools
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
@ -232,7 +165,7 @@ basepython = python3
|
|||||||
-skip_install = true
|
-skip_install = true
|
||||||
deps =
|
deps =
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
PyInstaller==3.2
|
-r{toxinidir}/misc/requirements/requirements-pyinstaller.txt
|
||||||
commands =
|
commands =
|
||||||
{envpython} scripts/link_pyqt.py --tox {envdir}
|
{envpython} scripts/link_pyqt.py --tox {envdir}
|
||||||
{envbindir}/pyinstaller --noconfirm misc/qutebrowser.spec
|
{envbindir}/pyinstaller --noconfirm misc/qutebrowser.spec
|
||||||
|
Loading…
Reference in New Issue
Block a user