Repository navigation
fix: fill the bucket under the limiter's lock #397
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: Build | |
| on: | |
| push: | |
| branches: [main] | |
| tags: ['v*'] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| env: | |
| LATEST_PY_VERSION: '3.14' | |
| COVERAGE_ARGS: '--cov --cov-report=term --cov-report=xml' | |
| XDIST_ARGS: '--numprocesses=auto' | |
| jobs: | |
| # Run unit tests for each supported python version | |
| test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ['3.15', '3.14', '3.13', '3.12', '3.11', '3.10'] | |
| steps: | |
| # Install dependencies, with caching | |
| - uses: actions/checkout@v6 | |
| - uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0 | |
| with: | |
| enable-cache: true | |
| cache-dependency-glob: uv.lock | |
| - name: Install dependencies | |
| run: | | |
| uv python install ${{ matrix.python-version }} | |
| uv sync --all-groups | |
| # Run tests with coverage report | |
| - name: Run tests | |
| run: uv run pytest -rs -vv ${{ env.XDIST_ARGS }} ${{ env.COVERAGE_ARGS }} | |
| # Pre-import Codecov signing key; action's gpg --no-default-keyring import is broken on newer runners | |
| - name: Import Codecov GPG key | |
| if: ${{ matrix.python-version == env.LATEST_PY_VERSION }} | |
| run: gpg --keyserver hkps://keyserver.ubuntu.com --recv-keys 27034E7FDB850E0BBC2C62FF806BB28AED779869 | |
| # Latest python version: send coverage report to codecov | |
| - name: "Upload coverage report to Codecov" | |
| if: ${{ matrix.python-version == env.LATEST_PY_VERSION }} | |
| uses: codecov/codecov-action@e79a6962e0d4c0c17b229090214935d2e33f8354 # v6.0.1 | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| slug: ${{ github.repository }} | |
| fail_ci_if_error: true | |
| # Run code analysis checks via pre-commit hooks | |
| analyze: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ env.LATEST_PY_VERSION }} | |
| - name: Run style checks & linting | |
| uses: j178/prek-action@bdca6f102f98e2b4c7029491a53dfd366469e33d # v2.0.4 |