Skip to content

Rewrite the README and add the contributor documentation #8

Rewrite the README and add the contributor documentation

Rewrite the README and add the contributor documentation #8

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
jobs:
checks:
name: Lint, types, shell scripts, unit and local-mode tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v5
with:
python-version: "3.11"
- name: Install development dependencies (locked)
run: |
uv venv .venv --python 3.11 --clear
uv pip install --python .venv/bin/python --require-hashes -r requirements/dev.lock
- name: Ruff
run: .venv/bin/ruff check . && .venv/bin/ruff format --check .
- name: Mypy
run: .venv/bin/mypy
- name: Shellcheck
run: |
files=$(git ls-files '*.sh')
if [ -n "$files" ]; then .venv/bin/shellcheck -x $files; fi
- name: Tests (fast)
run: .venv/bin/pytest -m "not slow and not browser and not hardware" --cov --cov-report=term-missing
- name: Quick start in local mode (as in the README)
run: |
.venv/bin/python -m src.orchestration.experiment run --scenario examples/scenarios/local_demo.yaml --local
test -f .local_testbed/results/latest/total_averages_of_benchmark_results.json
test -f .local_testbed/results/latest/calculated_max_partition_points.json
test -f .local_testbed/results/latest/final_latencies_averages.json
- name: Provisioning scripts in dry-run mode
run: |
TESTBED_CONFIG=config.example.yaml TESTBED_NODES=nodes.example.json TESTBED_AP_PASSPHRASE=ci \
scripts/provision/provision_edge_server.sh --dry-run --allow-upstream > /dev/null
models:
name: Real-model tests (slow)
runs-on: ubuntu-latest
needs: checks
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v5
with:
python-version: "3.11"
- name: Install edge-server dependencies (locked)
run: |
uv venv .venv --python 3.11 --clear
uv pip install --python .venv/bin/python --require-hashes -r requirements/edge_server.lock \
--extra-index-url https://download.pytorch.org/whl/cpu --index-strategy unsafe-best-match
uv pip install --python .venv/bin/python --require-hashes -r requirements/dev.lock
- name: Tests (slow)
run: .venv/bin/pytest -m "slow" -x