Skip to content

Commit 0ceab77

Browse files
authored
virtualenv cache issue (#158)
* upgrading pip due to deps * circle image for py3.6 needs --user pip * adding cover, fixing tox removals * cache key change * removing cache to test keys * moving venv to pip upgrade; * virtualenv downgrade due to the pypi cache issue
1 parent 5d277a2 commit 0ceab77

File tree

3 files changed

+5
-16
lines changed

3 files changed

+5
-16
lines changed

.circleci/config.yml

+1-13
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,10 @@ commands:
4242
- abort_for_noci
4343
- checkout
4444

45-
- restore_cache: # Download and cache dependencies
46-
keys:
47-
- v1-dependencies-{{ checksum "pyproject.toml" }}
48-
# fallback to using the latest cache if no exact match is found
49-
- v1-dependencies-
50-
5145
- run:
5246
name: install tox dependencies
5347
command: |
48+
pip install --user --upgrade --quiet pip virtualenv
5449
pip install --user --quiet -r .circleci/circle_requirements.txt
5550
5651
- run:
@@ -75,13 +70,6 @@ commands:
7570
command:
7671
tox -e cover
7772

78-
- save_cache:
79-
paths:
80-
- ./.tox
81-
- ~/.cache/pip
82-
- ~/.cache/pypoetry
83-
key: v1-dependencies-{{ checksum "pyproject.toml" }}
84-
8573
- store_artifacts:
8674
path: test-reports
8775
destination: test-reports

pyproject.toml

+2
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ tox = "^3.22.0 || <= 4.0.0"
4444
tox-poetry = "^0.4.0"
4545
bandit = "1.6.0"
4646
vulture = "^2.1"
47+
coverage = "^6.1.1"
48+
virtualenv = "20.9.0"
4749

4850
[build-system]
4951
requires = ["poetry-core>=1.0.0"]

tox.ini

+2-3
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@ srcdir = redisearch
99
show-source = true
1010
exclude =.git,.tox,dist,doc,*/__pycache__/*,*test*.py
1111

12+
# virtualenv bug #2214
1213
[testenv:cover]
1314
whitelist_externals = find
1415
commands_pre =
15-
find . -type f -name "*.pyc" -delete
16+
pip install --upgrade pip
1617
setenv =
1718
REDIS_PORT = 6379
1819
commands =
@@ -22,8 +23,6 @@ commands =
2223

2324
[testenv:test_without_coverage]
2425
whitelist_externals = find
25-
commands_pre =
26-
find . -type f -name "*.pyc" -delete
2726
setenv =
2827
REDIS_PORT = 6379
2928
commands =

0 commit comments

Comments
 (0)