Skip to content
Myr

👷 Use uv in CI (#1019)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Sebastián Ramírez · committed by GitHub · parent 233009a · Browse files · 5 files+60 added−34 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

5 files+60 added−34 removed

  • other:+60 added−34 removed

5 files+60 added−34 removed

modified:.github/workflows/build-docs.yml+14 added-8 removed
modified:.github/workflows/deploy-docs.yml+8 added-6 removed
modified:.github/workflows/smokeshow.yml+16 added-6 removed
1name: Smokeshow23on:4 workflow_run:5 workflows: [Test]6 types: [completed]5 workflows:6 - Test7 types:8 - completed910permissions:11 statuses: write1213env:14 UV_SYSTEM_PYTHON: 11516jobs:17 smokeshow:18 if: ${{ github.event.workflow_run.conclusion == 'success' }}19 runs-on: ubuntu-latest
5 unmodified lines
25 run: echo "$GITHUB_CONTEXT"26 - uses: actions/setup-python@v527 with:28 python-version: '3.9'2425 - run: pip install smokeshow2629 - name: Setup uv30 uses: astral-sh/setup-uv@v331 with:32 version: "0.4.15"33 enable-cache: true34 cache-dependency-glob: |35 requirements**.txt36 pyproject.toml37 - run: uv pip install -r requirements-github-actions.txt38 - uses: actions/download-artifact@v439 with:40 name: coverage-html41 path: htmlcov42 github-token: ${{ secrets.GITHUB_TOKEN }}43 run-id: ${{ github.event.workflow_run.id }}3344 - run: smokeshow upload htmlcov45 env:46 SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage}47 SMOKESHOW_GITHUB_COVERAGE_THRESHOLD: 100
4 unmodified lines
modified:.github/workflows/test.yml+21 added-14 removed
10 unmodified lines
11 schedule:12 # cron every week on monday13 - cron: "0 0 * * 1"1415env:16 UV_SYSTEM_PYTHON: 11718jobs:19 test:20 strategy:21 matrix:
21 unmodified lines
43 - name: Set up Python44 uses: actions/setup-python@v545 with:46 python-version: ${{ matrix.python-version }}44 # Issue ref: https://github.com/actions/setup-python/issues/43645 # cache: "pip"46 # cache-dependency-path: pyproject.toml47 - uses: actions/cache@v448 if: ${{ runner.os != 'macOS' }}49 id: cache47 - name: Setup uv48 uses: astral-sh/setup-uv@v349 with:51 path: ${{ env.pythonLocation }}52 key: ${{ runner.os }}-python-${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml', 'requirements-tests.txt') }}50 version: "0.4.15"51 enable-cache: true52 cache-dependency-glob: |53 requirements**.txt54 pyproject.toml55 - name: Install Dependencies54 if: steps.cache.outputs.cache-hit != 'true'55 run: pip install -r requirements-tests.txt56 run: uv pip install -r requirements-tests.txt57 - name: Lint58 run: bash scripts/lint.sh59 - run: mkdir coverage60 - run: bash ./scripts/test-files.sh
20 unmodified lines
81 - uses: actions/checkout@v482 - uses: actions/setup-python@v583 with:84 python-version: '3.8'84 # Issue ref: https://github.com/actions/setup-python/issues/43685 # cache: "pip"86 # cache-dependency-path: pyproject.toml85 - name: Setup uv86 uses: astral-sh/setup-uv@v387 with:88 version: "0.4.15"89 enable-cache: true90 cache-dependency-glob: |91 requirements**.txt92 pyproject.toml93 - name: Get coverage files94 uses: actions/download-artifact@v495 with:96 pattern: coverage-*97 path: coverage98 merge-multiple: true93 - run: pip install coverage[toml]99 - name: Install Dependencies100 run: uv pip install -r requirements-tests.txt101 - run: ls -la coverage102 - run: coverage combine coverage103 - run: coverage report104 - run: coverage html --show-contexts --title "Coverage for ${{ github.sha }}"
22 unmodified lines
modified:requirements-github-actions.txt+1 added
1PyGithub>=2.3.0,<3.0.02pydantic>=2.5.3,<3.0.03pydantic-settings>=2.1.0,<3.0.04httpx>=0.27.0,<0.28.05smokeshow