Skip to content

Commit 0c85f62

Browse files
P403n1x87brettlangdon
authored andcommitted
tests: pin MarkupSafe dependency (#3478)
The 2.1.0 release of MarkupSafe comes with some changes that break some of the projects that depend on it. We fix the framework tests by pinning the version to the latest 2.0 release for now.
1 parent 1ff2dbb commit 0c85f62

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

.github/workflows/test_frameworks.yml

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ jobs:
9494
# django.tests.requests module interferes with requests library patching in the tracer -> disable requests patch
9595
run: DD_TRACE_REQUESTS_ENABLED=0 ddtrace-run tests/runtests.py
9696

97-
fastapi-testsuite-0_63:
97+
fastapi-testsuite-0_75:
9898
runs-on: ubuntu-latest
9999
env:
100100
DD_TESTING_RAISE: true
@@ -112,21 +112,18 @@ jobs:
112112
- uses: actions/checkout@v2
113113
with:
114114
repository: tiangolo/fastapi
115-
ref: 0.63.0
115+
ref: 0.75.0
116116
path: fastapi
117117
#This step installs Flit, a way to put Python packages and modules on PyPI (More info at https://flit.readthedocs.io/en/latest/)
118118
- name: Install Flit
119119
run: pip install flit
120120
#Installs all dependencies needed for FastAPI
121121
- name: Install Dependencies
122122
run: flit install --symlink
123-
#Reverts SQLalchemy to v1.3.24. Newest version breaks tests due to RowProxy module being deprecated in latest v1.4.11 More info: (https://docs.sqlalchemy.org/en/14/changelog/migration_14.html#rowproxy-is-no-longer-a-proxy-is-now-called-row-and-behaves-like-an-enhanced-named-tuple)
124-
- name: Downgrade SQLalchemy
125-
run: pip install --force-reinstall SQLAlchemy==1.3.24
126123
- name: Inject ddtrace
127124
run: pip install ../ddtrace
128125
- name: Test
129-
run: ddtrace-run pytest tests
126+
run: ddtrace-run pytest -p no:warnings tests
130127

131128
flask-testsuite-1_1_4:
132129
runs-on: ubuntu-latest
@@ -153,13 +150,16 @@ jobs:
153150
run: pip install tox
154151
- name: Create tox env
155152
run: tox -e py38 --notest
156-
- name: Inject ddtrace
157-
run: .tox/py38/bin/pip install ../ddtrace
158153
- name: Add pytest configuration for ddtrace
159154
run: echo -e "[pytest]\nddtrace-patch-all = 1" > pytest.ini
160155
- name: Run tests
161156
# test_exception_propagation is broken upstream
162-
run: tox -e py38 -- -k 'not test_exception_propagation and not test_memory_consumption'
157+
run: |
158+
source .tox/py38/bin/activate
159+
pip install ../ddtrace
160+
pip install -e .
161+
pip install --upgrade MarkupSafe==2.0.1
162+
pytest -p no:warnings -k 'not test_exception_propagation and not test_memory_consumption' tests/
163163
164164
httpx-testsuite-0_22_0:
165165
runs-on: ubuntu-latest
@@ -278,6 +278,8 @@ jobs:
278278
run: pip install ../ddtrace
279279
- name: Install dependencies
280280
run: "make init"
281+
- name: MarkupSafe fix
282+
run: pip install --upgrade MarkupSafe==2.0.1
281283
- name: Run tests
282284
run: ddtrace-run pytest -p no:warnings tests
283285

0 commit comments

Comments
 (0)