forked from DataDog/dd-trace-py
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
149 lines (137 loc) · 5.59 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
# the tox file specifies a way of running our test suite
# against different combinations of libraries and python
# versions.
[tox]
# Our various test environments. The py*-all tasks will run the core
# library tests and all contrib tests with the latest library versions.
# The others will test specific versions of libraries.
#
# FIXME[gabin]:
# If the env name is longer than 128 characters (linux kernel limit specified
# in "master/include/linux/binfmts.h"), we'll get a "bad interpreter: No such file or directory" error.
#
#See linux kernel limitation:
# - https://github.com/torvalds/linux/blob/master/include/linux/binfmts.h#L12
#
#See related github topic:
# - https://github.com/pypa/virtualenv/issues/596
envlist =
wait
{py27,py35,py36,py37,py38,py39,py310}-profile{,-gevent}
{py27,py35,py36,py37,py38,py39,py310}-profile-minreqs{,-gevent}
py{37,38,39,310}-profile-protobuf319
# FIXME[riot-3.11]: Riot venvs break with Py 3.11 importlib, specifically with hypothesis (test_http.py).
# We'll skip the test_http.py tests in riot and run them separately here through tox in CI.
py{27,35,36,37,38,39,310,311}-tracer_test_http
# Integrations environments
pymongo_contrib-py{27,35,36,37}-pymongo{30,31,32,33,34,35,36,37,38,39,310,}-mongoengine
# pymongo does not yet support Python 3.8: https://github.com/pymssql/pymssql/issues/586
# but these tests still work.
pymongo_contrib-py{38,39,310,311}-pymongo{30,31,32,33,35,36,37,38,39,310,}-mongoengine
pynamodb_contrib-py{27,35,36,37,38,39,310,311}-pynamodb{40,41,42,43,}-moto1
pyodbc_contrib-py{27,35,36,37,38,39}-pyodbc{3,4}
vertica_contrib-py{27,35,36,37,38,39}-vertica{060,070}
isolated_build = true
requires = virtualenv<=20.2.1
[testenv:py{37,38}-profile-minreqs-gevent]
# Wheels for gevent segfault pretty easily
install_command=python -m pip install --no-binary=gevent {opts} {packages}
usedevelop = true
[testenv]
install_command=python -m pip install {opts} {packages}
usedevelop = true
setenv =
DD_TESTING_RAISE=1
DD_REMOTE_CONFIGURATION_ENABLED=false
profile-gevent: DD_PROFILE_TEST_GEVENT=1
extras =
profile: profiling
deps =
cython<=0.29.32
cmake
ninja
pytest-cov
pytest-mock
opentracing
# test dependencies installed in all envs
mock
hypothesis
# used to test our custom msgpack encoder
profile: pytest-benchmark
# pytest-benchmark depends on cpuinfo which dropped support for Python<=3.6 in 9.0
# See https://github.com/workhorsy/py-cpuinfo/issues/177
profile: py-cpuinfo==8.0.0
# TODO: remove py dependency once https://github.com/ionelmc/pytest-benchmark/pull/227 is released
profile: py
py{35,36,37,38,39,310}-profile: pytest-asyncio
py{27,35,36,37,38,39}-profile: uwsgi; sys_platform != 'win32'
py{27,35,36,37,38,39,310}-profile: gunicorn; sys_platform != 'win32'
py{27,35,36,37,38,39,310}-profile-gevent: gunicorn[gevent]; sys_platform != 'win32'
py{27,35,36,37,38,39}-profile-minreqs: protobuf==3.0.0
py{310}-profile-minreqs: protobuf==3.8.0
profile-minreqs: tenacity==5.0.1
profile-!minreqs-gevent: gevent
# gevent==1.1 requires greenlet<2
py27-profile-minreqs-gevent: gevent==1.1.0
py27-profile-minreqs-gevent: greenlet<2
# gevent==1.4 requires greenlet<2
py{35,36,37,38}-profile-minreqs-gevent: gevent==1.4.0
py{35,36,37,38}-profile-minreqs-gevent: greenlet<2
py39-profile-minreqs-gevent: gevent==20.6.1; sys_platform != 'win32'
py39-profile-minreqs-gevent: gevent==21.1.2; sys_platform == 'win32'
py39-profile-minreqs-gevent: greenlet==0.4.16; sys_platform != 'win32'
py39-profile-minreqs-gevent: greenlet==0.4.17; sys_platform == 'win32'
py{310}-profile-minreqs-gevent: gevent==21.8.0
py{310}-profile-minreqs-gevent: greenlet==1.1.0
py{37,38,39,310}-profile-protobuf319: protobuf<3.19
# backports
py27: enum34
# integrations
blinker: blinker
futures: futures
futures30: futures>=3.0,<3.1
futures31: futures>=3.1,<3.2
futures32: futures>=3.2,<3.3
gevent11: gevent>=1.1,<1.2
gevent12: gevent>=1.2,<1.3
gevent13: gevent>=1.3,<1.4
gevent14: gevent>=1.4,<1.5
gevent209: gevent>=20.9,<20.10
gevent2012: gevent>=20.12,<20.13
gevent211: gevent>=21.1,<21.2
gevent218: gevent>=21.8,<21.9
gevent228: gevent>=22.8,<22.10
# Note - gevent<20.12 does not set a maximum supported version.
# To test with gevent<20.12 we need to manually install greenlet<2.
greenlet1: greenlet>=1,<2
memcached: python-memcached
moto: moto
moto1: moto>=1,<2
mongoengine: mongoengine
pytest: pytest>=3
pytest3: pytest>=3.0,<4.0
redis: redis
redis210: redis>=2.10,<2.11
sqlalchemy: sqlalchemy
vertica060: vertica-python>=0.6.0,<0.7.0
vertica070: vertica-python>=0.7.0,<0.8.0
webtest: WebTest
aiobotocore_contrib: pytest-asyncio
# pass along test env variables
passenv=
TEST_*
# https://circleci.com/docs/2.0/env-vars/#built-in-environment-variables
CI
CI_*
CIRCLECI
CIRCLE_*
DD_TRACE_AGENT_URL
DD_API_KEY
commands =
# run only essential tests related to the tracing client
tracer_test_http: python -m pytest {posargs} tests/tracer/test_http.py
py27-profile: python -m tests.profiling.run pytest --capture=no --verbosity=2 --benchmark-disable --ignore-glob="*asyncio*" {posargs} tests/profiling
# Coverage is excluded from profile because of an issue with Python 3.5.
py3{5,6,7,8,9,10}-profile: python -m tests.profiling.run pytest --no-cov --capture=no --verbosity=2 --benchmark-disable {posargs} tests/profiling
# Contribs
vertica_contrib: python -m pytest {posargs} tests/contrib/vertica/