Skip to content

Commit 9fef09f

Browse files
author
Kartik Raj
authored
Don't use cached requirements installation when running the tests on GHA
1 parent 458f545 commit 9fef09f

1 file changed

Lines changed: 5 additions & 11 deletions

File tree

.github/workflows/ci.yml

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ jobs:
5050
5151
- name: Install debugpy wheels
5252
run: |
53+
python -m pip install wheel
5354
python -m pip --disable-pip-version-check install -r build/debugger-install-requirements.txt
5455
python ./pythonFiles/install_debugpy.py
5556
@@ -252,22 +253,15 @@ jobs:
252253
- name: curl PyPI to get debugpy versions
253254
run: curl --output debugpy.json https://pypi.org/pypi/debugpy/json
254255

255-
- name: Retrieve cached pythonFiles/ directory
256-
uses: actions/cache@v1
257-
# Use an id for this step so that its cache-hit output can be accessed and checked in the next step.
258-
id: pythonFiles-cache
259-
with:
260-
path: ./pythonFiles/lib/python
261-
key: ${{runner.os}}-${{env.CACHE_PYTHONFILES}}-pythonFiles-${{env.PYTHON_VERSION}}-${{hashFiles('requirements.txt')}}-${{hashFiles('build/debugger-install-requirements.txt')}}-${{hashFiles('debugpy.json')}}
262-
263-
- name: Install Python requirements if not cached
256+
# We're intentionally not retrieving cached Python requirements installation, as it appears that pulling the cache pulls in some extra libraries as well,
257+
# which causes problems with the tests. Also, running the installation seems much faster than retrieving it from cache.
258+
- name: Install Python requirements
264259
run: |
265260
python -m pip --disable-pip-version-check install -t ./pythonFiles/lib/python --no-cache-dir --implementation py --no-deps --upgrade -r requirements.txt
266261
python -m pip --disable-pip-version-check install -t ./pythonFiles/lib/python/old_ptvsd --no-cache-dir --implementation py --no-deps --upgrade 'ptvsd==4.3.2'
267262
python -m pip --disable-pip-version-check install -t ./pythonFiles/lib/python/debugpy/no_wheels --no-cache-dir --implementation py --no-deps --upgrade --pre debugpy
268263
# We need to have debugpy available in wheels/ so that tests relying on it keep passing, but we don't need install_debugpy's logic in the test phase.
269264
python -m pip --disable-pip-version-check install -t ./pythonFiles/lib/python/debugpy/wheels --no-cache-dir --implementation py --no-deps --upgrade --pre debugpy
270-
if: steps.pythonFiles-cache.outputs.cache-hit == false
271265
272266
- name: Install test requirements
273267
run: python -m pip install --upgrade -r build/test-requirements.txt
@@ -278,7 +272,7 @@ jobs:
278272
python -m pip install --upgrade -r ./build/ipython-test-requirements.txt
279273
if: matrix.test-suite == 'python-unit'
280274

281-
- name: Install Debugpy wheels
275+
- name: Install debugpy wheels
282276
run: |
283277
python -m pip install wheel
284278
python -m pip --disable-pip-version-check install -r build/debugger-install-requirements.txt

0 commit comments

Comments
 (0)