Skip to content

Commit

Permalink
Trying new cache strategy
Browse files Browse the repository at this point in the history
  • Loading branch information
aliberts committed Apr 25, 2024
1 parent 19d1447 commit 0b4277a
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 17 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/nightly-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
name: Self-hosted runner with slow tests (scheduled)

on:
pull_request: # TODO(aliberts): for testing, delete before merge
branches:
- main
# pull_request: # TODO(aliberts): for testing, delete before merge
# branches:
# - main
workflow_dispatch:
schedule:
- cron: "0 2 * * *"
Expand Down Expand Up @@ -64,6 +64,12 @@ jobs:
run: nvidia-smi
- name: Test
run: pytest -v --cov=./lerobot --cov-report=xml --disable-warnings tests
# TODO(aliberts): Link with HF Codecov account
# - name: Upload coverage reports to Codecov with GitHub Action
# uses: codecov/codecov-action@v4
# with:
# files: ./coverage.xml
# verbose: true
- name: Tests end-to-end
run: make test-ete
- name: Tailscale Wait
Expand Down
15 changes: 10 additions & 5 deletions .github/workflows/test-pip.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Tests-pip
name: Tests

on:
pull_request:
Expand Down Expand Up @@ -36,19 +36,24 @@ jobs:
repository: huggingface/gym-pusht
path: envs/gym-pusht
ssh-key: ${{ secrets.SSH_PRIVATE_KEY }}

- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
cache: "pip"
cache-dependency-path: "pyproject.toml"
- name: Install libegl1-mesa-dev (to use MUJOCO_GL=egl)
cache: ${{ (github.ref == 'refs/heads/main') && 'pip' || '' }}
cache-dependency-path: pyproject.toml

- name: Install EGL
run: sudo apt-get update && sudo apt-get install -y libegl1-mesa-dev

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e ".[test, aloha, xarm, pusht]"
- name: Test with pytest
run: pytest -v --cov=./lerobot --cov-report=xml tests
run: pytest -v --cov=./lerobot tests

- name: Test end-to-end
run: make test-ete
11 changes: 2 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Tests
name: Tests poetry

on:
pull_request:
Expand Down Expand Up @@ -110,14 +110,7 @@ jobs:
- name: Run tests
run: |
source .venv/bin/activate
pytest -v --cov=./lerobot --cov-report=xml tests
# TODO(aliberts): Link with HF Codecov account
# - name: Upload coverage reports to Codecov with GitHub Action
# uses: codecov/codecov-action@v4
# with:
# files: ./coverage.xml
# verbose: true
pytest -v --cov=./lerobot tests
#----------------------------------------------
# run end-to-end tests
Expand Down

0 comments on commit 0b4277a

Please sign in to comment.