Skip to content

Commit 7f9a400

Browse files
committed
Revert Use cache for pip
This commit gets rid of using any type of cache (introduced in 135c95f) This is to ensure having no surprises in future. This was discussed in https://github.com/nexB/vulnerablecode/wiki/WeeklyMeetings#meeting-on-tuesday-2021-07-27-at-1300-utc Signed-off-by: Hritik Vijay <hritikxx8@gmail.com>
1 parent ddf1c94 commit 7f9a400

1 file changed

Lines changed: 9 additions & 29 deletions

File tree

.github/workflows/main.yml

Lines changed: 9 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -7,48 +7,28 @@ jobs:
77
runs-on: ubuntu-latest
88

99
steps:
10-
- name: Check out repository code
10+
- name: Check code
1111
uses: actions/checkout@v2
1212

13-
- name: Set up Python 3.8
13+
- name: Set up Python 3.8.11
1414
uses: actions/setup-python@v2
1515
with:
16-
python-version: 3.8
17-
18-
- name: Restore cache
19-
uses: actions/cache@v2
20-
with:
21-
path: venv
22-
key: ${{ runner.os }}-venv-${{ hashFiles('**/requirements*.txt') }}
23-
restore-keys: |
24-
${{ runner.os }}-venv-
25-
26-
- name: Create env file
27-
run: make envfile
16+
python-version: 3.8.11
2817

2918
- name: Install dependencies
3019
run: |
31-
sudo apt install python3-dev postgresql libpq-dev build-essential libxml2-dev libxslt1-dev postgresql
32-
python -m pip install --upgrade pip
33-
34-
- uses: syphar/restore-virtualenv@v1
35-
id: cache-virtualenv
36-
with:
37-
requirement_files: requirements*.txt # this is optional
20+
sudo apt install -y postgresql libpq-dev
21+
make dev envfile
3822
39-
- uses: syphar/restore-pip-download-cache@v1
40-
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
23+
- name: Validate code format
24+
run: make check
4125

42-
- run: pip install -r requirements.txt -r requirements-dev.txt
43-
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
44-
45-
# virtualenv is already activated
4626
- name: Setup database
4727
run: |
4828
sudo systemctl start postgresql
49-
make postgres ACTIVATE=
29+
make postgres
5030
5131
- name: Run tests
52-
run: make test ACTIVATE=
32+
run: make test
5333
env:
5434
GH_TOKEN: 1

0 commit comments

Comments
 (0)