feat(sdk): Job OSS artifact mirror (OssMirrorConfig) (#707) #1249
Workflow file for this run
This file contains hidden or 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: Python CI | |
| on: | |
| push: | |
| branches: | |
| - master | |
| - release/v1.0 | |
| pull_request: | |
| branches: | |
| - master | |
| - release/v1.0 | |
| jobs: | |
| test: | |
| runs-on: self-hosted | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Cleanup old files in /tmp/ray | |
| run: | | |
| target="$(readlink -f /tmp/ray 2>/dev/null || echo /tmp/ray)" | |
| [ -d "$target" ] || exit 0 | |
| echo "ray dir: $target" | |
| echo "Before:" | |
| du -sh "$target" 2>/dev/null || true | |
| echo "Will delete (older than 60min):" | |
| find "$target" -mindepth 1 -maxdepth 1 -type d -name 'session_*' -mmin +60 -print -exec du -sh {} \; || true | |
| find "$target" -mindepth 1 -maxdepth 1 -type d -name 'session_*' -mmin +60 -exec rm -rf -- {} + || true | |
| echo "After:" | |
| du -sh "$target" 2>/dev/null || true | |
| - name: Set up project (install dependencies without building) | |
| run: | | |
| uv sync --all-extras --group test --python 3.11 | |
| - name: Run fast tests | |
| run: | | |
| mkdir -p data/logs | |
| echo "🚀 Running fast tests..." | |
| uv run pytest -n auto -m "not need_ray and not need_admin and not need_admin_and_network" --reruns 1 | |
| - name: Run tests need ray | |
| if: success() | |
| run: | | |
| echo "⚡ Running ray tests..." | |
| uv run pytest -n auto -m "need_ray" --reruns 1 | |
| - name: Run tests need admin | |
| if: success() | |
| run: | | |
| echo "🔐 Running admin tests..." | |
| uv run pytest -n auto -m "need_admin" --reruns 1 | |
| - name: Run tests need admin and network | |
| if: success() | |
| run: | | |
| echo "🔐 Running admin and network tests..." | |
| uv run pytest -n auto -m "need_admin_and_network" --reruns 1 |