Updated python dependencies #1733
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tests | |
on: | |
pull_request: | |
push: | |
jobs: | |
unit-test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python: ["3.10"] | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: Do LFS checkout | |
# actions/checkout@v2 has a `with: lfs: true` option, but it only | |
# knows how to talk to GitHub’s LFS server. | |
# | |
# These actions are automatic if you have run `git lfs install` | |
# even once on your dev machine. | |
run: git lfs install --local && git lfs fetch && git lfs checkout | |
- name: Set up Python | |
id: set-up-python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install system dependencies | |
run: sudo apt-get update && sudo apt-get install -y ffmpeg | |
- run: pip install pipenv | |
# Started as copy-paste from | |
# https://github.com/actions/cache/blob/main/examples.md#python---pipenv | |
# but that has problems: | |
# 1. The cached virtualenv has `bin/python` as a symlink pointing | |
# at a specific bugfix release of python, e.g., | |
# `/opt/hostedtoolcache/Python/3.7.11`, causing mysterious | |
# failures when GitHub patches python on the CI machines. | |
# 2. Setting `restore-key` to reuse caches from other Pipfile.lock | |
# versions can leave extra dependencies installed, because | |
# `pipenv install --dev` doesn’t `pipenv clean` | |
- uses: actions/cache@v4 | |
with: | |
path: ~/.local/share/virtualenvs | |
key: ${{ runner.os }}-python-${{ steps.set-up-python.outputs.python-version }}-pipenv-${{ hashFiles('Pipfile.lock') }} | |
- run: pipenv install --dev | |
- run: make test | |
integration-test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python: ["3.10"] | |
steps: | |
- name: checkout | |
uses: actions/checkout@v2 | |
- name: Do LFS checkout | |
# actions/checkout@v2 has a `with: lfs: true` option, but it only | |
# knows how to talk to GitHub’s LFS server. | |
# | |
# These actions are automatic if you have run `git lfs install` | |
# even once on your dev machine. | |
run: git lfs install --local && git lfs fetch && git lfs checkout | |
- name: Set up Python | |
id: set-up-python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
- run: pip install pipenv | |
# Started as copy-paste from | |
# https://github.com/actions/cache/blob/main/examples.md#python---pipenv | |
# but that has problems: | |
# 1. The cached virtualenv has `bin/python` as a symlink pointing | |
# at a specific bugfix release of python, e.g., | |
# `/opt/hostedtoolcache/Python/3.7.11`, causing mysterious | |
# failures when GitHub patches python on the CI machines. | |
# 2. Setting `restore-key` to reuse caches from other Pipfile.lock | |
# versions can leave extra dependencies installed, because | |
# `pipenv install --dev` doesn’t `pipenv clean` | |
- uses: actions/cache@v4 | |
with: | |
path: ~/.local/share/virtualenvs | |
key: ${{ runner.os }}-python-${{ steps.set-up-python.outputs.python-version }}-pipenv-${{ hashFiles('Pipfile.lock') }} | |
- run: pipenv install --dev | |
- name: Setup Node 22 | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '22' | |
- run: npm install | |
- uses: actions/cache@v4 | |
with: | |
path: ~/.npm | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
- run: make integration-test | |