Nightly #24
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: Nightly | |
on: | |
schedule: | |
- cron: '0 0 * * *' # Runs at midnight every night | |
jobs: | |
unit-tests: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python: ["3.9", "3.13"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install dependencies | |
run: pip install tox | |
- name: Run unit tests | |
run: tox -e test-unit -- --cov=guidellm --cov-report=term-missing --cov-fail-under=75 | |
integration-tests: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python: ["3.9", "3.13"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install dependencies | |
run: pip install tox | |
- name: Run integration tests | |
run: tox -e test-integration -- -m "smoke or sanity" | |
e2e-tests: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python: ["3.9", "3.13"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install dependencies | |
run: pip install tox | |
- name: Run integration tests | |
run: tox -e test-e2e -- -m smoke | |
build-and-publish: | |
needs: [unit-tests, integration-tests, e2e-tests] | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python: ["3.9"] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install dependencies | |
run: pip install tox | |
- name: Build the package | |
run: | | |
export GUIDELLM_BUILD_TYPE=nightly | |
tox -e build | |
- name: Find wheel artifact | |
id: find-asset-whl | |
run: | | |
echo "::set-output name=asset::$(find dist -name '*.whl')" | |
- name: Find tar.gz artifact | |
id: find-asset-targz | |
run: | | |
echo "::set-output name=asset::$(find dist -name '*.tar.gz')" | |
- name: Push wheel to PyPI | |
uses: neuralmagic/nm-actions/actions/publish-whl@v1.0.0 | |
with: | |
username: ${{ secrets.PYPI_PUBLIC_USER }} | |
password: ${{ secrets.PYPI_PUBLIC_AUTH }} | |
whl: ${{ steps.find-asset-whl.outputs.asset }} | |
- name: Push tar.gz to PyPI | |
uses: neuralmagic/nm-actions/actions/publish-whl@v1.0.0 | |
with: | |
username: ${{ secrets.PYPI_PUBLIC_USER }} | |
password: ${{ secrets.PYPI_PUBLIC_AUTH }} | |
whl: ${{ steps.find-asset-targz.outputs.asset }} | |
- name: Upload build artifacts | |
id: artifact-upload | |
uses: actions/upload-artifact@v4 | |
with: | |
name: nightly-build-artifacts | |
path: dist/* | |
compression-level: 6 | |
if-no-files-found: error | |
retention-days: 30 | |
- name: Log artifact location | |
run: | | |
echo "Artifacts uploaded to: ${{ steps.artifact-upload.outputs.artifact-url }}" |