Split out testing extras (#8893)

* split out test extras

* update extras and regenerate pinnings

* pin back mypy
This commit is contained in:
Brad Warren 2021-06-11 13:17:50 -07:00 committed by GitHub
parent c8255dded5
commit 18ea72faf1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 58 additions and 46 deletions

View file

@ -19,17 +19,16 @@ install_requires = [
'setuptools>=39.0.1',
]
dev_extras = [
'pytest',
'pytest-xdist',
'tox',
]
docs_extras = [
'Sphinx>=1.0', # autodoc_member_order = 'bysource', autodoc_default_flags
'sphinx_rtd_theme',
]
test_extras = [
'pytest',
'pytest-xdist',
]
setup(
name='acme',
version=version,
@ -57,7 +56,7 @@ setup(
include_package_data=True,
install_requires=install_requires,
extras_require={
'dev': dev_extras,
'docs': docs_extras,
'test': test_extras,
},
)

View file

@ -67,23 +67,13 @@ install_requires = [
]
dev_extras = [
'astroid',
'azure-devops',
'coverage',
'ipdb',
'mypy',
'PyGithub',
'pip',
# poetry 1.2.0+ is required for it to pin pip, setuptools, and wheel. See
# https://github.com/python-poetry/poetry/issues/1584.
'poetry>=1.2.0a1',
'pylint',
'pytest',
'pytest-cov',
'pytest-xdist',
# typing-extensions is required to import typing.Protocol and make the mypy checks
# pass (along with pylint about non-existent objects) on Python 3.6 & 3.7
'typing-extensions',
'tox',
'twine',
'wheel',
@ -97,6 +87,21 @@ docs_extras = [
'sphinx_rtd_theme',
]
test_extras = [
'coverage',
'mypy',
'pylint',
'pytest',
'pytest-cov',
'pytest-xdist',
# typing-extensions is required to import typing.Protocol and make the mypy checks
# pass (along with pylint about non-existent objects) on Python 3.6 & 3.7
'typing-extensions',
]
all_extras = dev_extras + docs_extras + test_extras
setup(
name='certbot',
version=version,
@ -133,8 +138,10 @@ setup(
install_requires=install_requires,
extras_require={
'all': all_extras,
'dev': dev_extras,
'docs': docs_extras,
'test': test_extras,
},
entry_points={

View file

@ -45,7 +45,7 @@ if [ $? -ne 0 ] ; then
exit 1
fi
tools/venv.py -e acme[dev] -e certbot[dev,docs] -e certbot-apache -e certbot-ci
tools/venv.py -e acme -e certbot -e certbot-apache -e certbot-ci tox
PEBBLE_LOGS="acme_server.log"
PEBBLE_URL="https://localhost:14000/dir"
# We configure Pebble to use port 80 for http-01 validation rather than an

View file

@ -12,8 +12,8 @@ python = "^3.6"
# Any local packages that have dependencies on other local packages must be
# listed below before the package it depends on. For instance, certbot depends
# on acme so certbot must be listed before acme.
certbot-ci = {path = "../../certbot-ci", extras = ["docs"]}
certbot-compatibility-test = {path = "../../certbot-compatibility-test", extras = ["docs"]}
certbot-ci = {path = "../../certbot-ci"}
certbot-compatibility-test = {path = "../../certbot-compatibility-test"}
certbot-dns-cloudflare = {path = "../../certbot-dns-cloudflare", extras = ["docs"]}
certbot-dns-cloudxns = {path = "../../certbot-dns-cloudxns", extras = ["docs"]}
certbot-dns-digitalocean = {path = "../../certbot-dns-digitalocean", extras = ["docs"]}
@ -28,10 +28,10 @@ certbot-dns-ovh = {path = "../../certbot-dns-ovh", extras = ["docs"]}
certbot-dns-rfc2136 = {path = "../../certbot-dns-rfc2136", extras = ["docs"]}
certbot-dns-route53 = {path = "../../certbot-dns-route53", extras = ["docs"]}
certbot-dns-sakuracloud = {path = "../../certbot-dns-sakuracloud", extras = ["docs"]}
certbot-nginx = {path = "../../certbot-nginx", extras = ["docs"]}
certbot-nginx = {path = "../../certbot-nginx"}
certbot-apache = {path = "../../certbot-apache", extras = ["dev"]}
certbot = {path = "../../certbot", extras = ["dev", "docs"]}
acme = {path = "../../acme", extras = ["dev", "docs"]}
certbot = {path = "../../certbot", extras = ["all"]}
acme = {path = "../../acme", extras = ["docs", "test"]}
letstest = {path = "../../letstest"}
windows-installer = {path = "../../windows-installer"}
@ -51,6 +51,12 @@ awscli = ">=1.19.62"
# as a dependency here to ensure a version of cython is pinned for extra
# stability.
cython = "*"
# mypy 0.900 stopped including stubs containing type information for 3rd party
# libraries by default. This breaks our tests so let's continue to pin it back
# for now. See
# https://mypy-lang.blogspot.com/2021/05/the-upcoming-switch-to-modular-typeshed.html
# for more info.
mypy = "<0.900"
# We install mock in our "external-mock" tox environment to test that we didn't
# break Certbot's test API which used to always use mock objects from the 3rd
# party mock library. We list the mock dependency here so that is pinned, but

View file

@ -10,18 +10,18 @@ apacheconfig==0.3.2; python_version >= "3.6"
apipkg==1.5; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6"
appdirs==1.4.4; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0"
appnope==0.1.2; python_version == "3.6" and sys_platform == "darwin" or python_version >= "3.7" and sys_platform == "darwin"
astroid==2.5.7; python_version >= "3.6" and python_version < "4.0"
astroid==2.5.6; python_version >= "3.6" and python_version < "4.0"
atomicwrites==1.4.0; python_version >= "3.6" and python_full_version < "3.0.0" and sys_platform == "win32" or sys_platform == "win32" and python_version >= "3.6" and python_full_version >= "3.4.0"
attrs==21.2.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6"
awscli==1.19.85; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.6.0")
awscli==1.19.91; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.6.0")
azure-devops==6.0.0b4; python_version >= "3.6"
babel==2.9.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.4.0"
backcall==0.2.0; python_version == "3.6" or python_version >= "3.7"
bcrypt==3.2.0; python_version >= "3.6"
beautifulsoup4==4.9.3; python_version >= "3.6" and python_version < "4.0" or python_version >= "3.6"
bleach==3.3.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.5.0"
boto3==1.17.85; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
botocore==1.20.85; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
boto3==1.17.91; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
botocore==1.20.91; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
cachecontrol==0.12.6; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0"
cached-property==1.5.2; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6"
cachetools==4.2.2; python_version >= "3.5" and python_version < "4.0" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6")
@ -54,10 +54,10 @@ entrypoints==0.3; python_version >= "3.6" and python_version < "4.0"
execnet==1.8.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6"
fabric==2.6.0; python_version >= "3.6"
filelock==3.0.12; python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.5.0" or python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0" or python_version >= "3.6" and python_version < "4.0"
google-api-core==1.28.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
google-api-python-client==2.7.0; python_version >= "3.6"
google-api-core==1.30.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
google-api-python-client==2.8.0; python_version >= "3.6"
google-auth-httplib2==0.1.0; python_version >= "3.6"
google-auth==1.30.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
google-auth==1.31.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
googleapis-common-protos==1.53.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
html5lib==1.1; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.5.0"
httplib2==0.19.1; python_version >= "3.6"
@ -67,10 +67,10 @@ importlib-metadata==1.7.0; python_version >= "3.6" and python_full_version < "3.
importlib-resources==5.1.4; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "3.7" or python_version >= "3.6" and python_version < "3.7" and python_full_version >= "3.4.0"
iniconfig==1.1.1; python_version >= "3.6"
invoke==1.5.0; python_version >= "3.6"
ipdb==0.13.8; python_version >= "3.6"
ipdb==0.13.9; python_version >= "3.6"
ipython-genutils==0.2.0
ipython==7.16.1; python_version == "3.6"
ipython==7.24.0; python_version >= "3.7"
ipython==7.24.1; python_version >= "3.7"
isodate==0.6.0; python_version >= "3.6"
isort==5.8.0; python_version >= "3.6" and python_version < "4.0"
jedi==0.18.0; python_version == "3.6" or python_version >= "3.7"
@ -91,7 +91,7 @@ mock==4.0.3; python_version >= "3.6"
msgpack==1.0.2; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0"
msrest==0.6.21; python_version >= "3.6"
mypy-extensions==0.4.3; python_version >= "3.6"
mypy==0.812; python_version >= "3.6"
mypy==0.812; python_version >= "3.5"
oauth2client==4.1.3; python_version >= "3.6"
oauthlib==3.1.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.4.0"
packaging==20.9; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0" or python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.4.0" or python_version >= "3.6" and python_full_version >= "3.5.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
@ -108,7 +108,7 @@ ply==3.11; python_version >= "3.6"
poetry-core==1.1.0a5; python_version >= "3.6" and python_version < "4.0"
poetry==1.2.0a1; python_version >= "3.6" and python_version < "4.0"
prompt-toolkit==3.0.3; python_version == "3.6" or python_version >= "3.7"
protobuf==3.17.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
protobuf==3.17.3; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6"
ptyprocess==0.7.0; python_version >= "3.6" and python_version < "4.0"
py==1.10.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6" or python_version >= "3.6" and python_full_version >= "3.5.0"
pyasn1-modules==0.2.8; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6" or python_version >= "3.6"
@ -118,7 +118,7 @@ pygithub==1.55; python_version >= "3.6"
pygments==2.9.0; python_version >= "3.6" or python_version == "3.6" or python_version >= "3.7"
pyjwt==2.1.0; python_version >= "3.6"
pylev==1.4.0; python_version >= "3.6" and python_version < "4.0"
pylint==2.8.2; python_version >= "3.6" and python_version < "4.0"
pylint==2.8.3; python_version >= "3.6" and python_version < "4.0"
pynacl==1.4.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.4.0"
pynsist==2.7; python_version >= "3.6"
pyopenssl==20.0.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6"
@ -170,8 +170,8 @@ tox==3.23.1; python_version >= "3.6" and python_full_version < "3.0.0" or python
tqdm==4.61.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.4.0"
traitlets==4.3.3
twine==3.3.0; python_version >= "3.6"
typed-ast==1.4.3; implementation_name == "cpython" and python_version < "3.8" and python_version >= "3.6" or python_version >= "3.6"
typing-extensions==3.10.0.0; python_version >= "3.6" or python_version >= "3.6" and python_version < "3.8"
typed-ast==1.4.3; python_version >= "3.6" or implementation_name == "cpython" and python_version < "3.8" and python_version >= "3.6"
typing-extensions==3.10.0.0; python_version >= "3.6"
uritemplate==3.0.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6"
urllib3==1.26.5; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version < "4" and python_version >= "3.6" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.6"
virtualenv==20.4.4; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_version >= "3.6" and python_version < "4.0" and python_full_version >= "3.4.0" or python_version >= "3.6" and python_full_version < "3.0.0" or python_version >= "3.6" and python_full_version >= "3.5.0"

View file

@ -24,8 +24,8 @@ import sys
import time
REQUIREMENTS = [
'-e acme[dev]',
'-e certbot[dev,docs]',
'-e acme[test]',
'-e certbot[all]',
'-e certbot-apache',
'-e certbot-dns-cloudflare',
'-e certbot-dns-cloudxns',

14
tox.ini
View file

@ -19,7 +19,7 @@ install_packages = python {toxinidir}/tools/pip_install_editable.py {[base]all_p
# behavior with substitutions that contain line continuations, see
# https://github.com/tox-dev/tox/issues/2069 for more info.
dns_packages = certbot-dns-cloudflare certbot-dns-cloudxns certbot-dns-digitalocean certbot-dns-dnsimple certbot-dns-dnsmadeeasy certbot-dns-gehirn certbot-dns-google certbot-dns-linode certbot-dns-luadns certbot-dns-nsone certbot-dns-ovh certbot-dns-rfc2136 certbot-dns-route53 certbot-dns-sakuracloud
all_packages = acme[dev] certbot[dev] certbot-apache {[base]dns_packages} certbot-nginx
all_packages = acme[test] certbot[test] certbot-apache {[base]dns_packages} certbot-nginx
source_paths = acme/acme certbot/certbot certbot-ci/certbot_integration_tests certbot-apache/certbot_apache certbot-compatibility-test/certbot_compatibility_test certbot-dns-cloudflare/certbot_dns_cloudflare certbot-dns-cloudxns/certbot_dns_cloudxns certbot-dns-digitalocean/certbot_dns_digitalocean certbot-dns-dnsimple/certbot_dns_dnsimple certbot-dns-dnsmadeeasy/certbot_dns_dnsmadeeasy certbot-dns-gehirn/certbot_dns_gehirn certbot-dns-google/certbot_dns_google certbot-dns-linode/certbot_dns_linode certbot-dns-luadns/certbot_dns_luadns certbot-dns-nsone/certbot_dns_nsone certbot-dns-ovh/certbot_dns_ovh certbot-dns-rfc2136/certbot_dns_rfc2136 certbot-dns-route53/certbot_dns_route53 certbot-dns-sakuracloud/certbot_dns_sakuracloud certbot-nginx/certbot_nginx tests/lock_test.py
[testenv]
@ -54,7 +54,7 @@ setenv =
basepython =
{[testenv:oldest]basepython}
commands =
{[base]install_and_test} acme[dev]
{[base]install_and_test} acme[test]
setenv =
{[testenv:oldest]setenv}
@ -62,7 +62,7 @@ setenv =
basepython =
{[testenv:oldest]basepython}
commands =
{[base]pip_install} acme[dev] certbot[dev] certbot-apache
{[base]pip_install} acme[test] certbot[test] certbot-apache
pytest certbot-apache
setenv =
{[testenv:oldest]setenv}
@ -71,7 +71,7 @@ setenv =
basepython =
{[testenv:oldest]basepython}
commands =
{[base]pip_install} acme[dev] certbot[dev] certbot-apache[dev]
{[base]pip_install} acme[test] certbot[test] certbot-apache[dev]
pytest certbot-apache
setenv =
{[testenv:oldest]setenv}
@ -80,7 +80,7 @@ setenv =
basepython =
{[testenv:oldest]basepython}
commands =
{[base]pip_install} acme[dev] certbot[dev]
{[base]pip_install} acme[test] certbot[test]
pytest certbot
setenv =
{[testenv:oldest]setenv}
@ -89,7 +89,7 @@ setenv =
basepython =
{[testenv:oldest]basepython}
commands =
{[base]pip_install} acme[dev] certbot[dev] {[base]dns_packages}
{[base]pip_install} acme[test] certbot[test] {[base]dns_packages}
pytest {[base]dns_packages}
setenv =
{[testenv:oldest]setenv}
@ -98,7 +98,7 @@ setenv =
basepython =
{[testenv:oldest]basepython}
commands =
{[base]pip_install} acme[dev] certbot[dev] certbot-nginx
{[base]pip_install} acme[test] certbot[test] certbot-nginx
pytest certbot-nginx
python tests/lock_test.py
setenv =