Bump ipython from 8.27.0 to 8.29.0 #361
Workflow file for this run
This file contains 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: test | |
on: | |
pull_request: | |
branches: | |
- main | |
# Allow calling this workflow from others: | |
workflow_call: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
concurrency: | |
# Skip intermediate builds: always. | |
# Cancel intermediate builds: only if it is a pull request build. | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }} | |
jobs: | |
build-and-test: | |
runs-on: ubuntu-latest | |
services: | |
postgres: | |
image: postgres:13 | |
env: | |
POSTGRES_DB: postgres | |
POSTGRES_PASSWORD: postgres | |
POSTGRES_USER: postgres | |
ports: ["5432:5432"] | |
# needed because the postgres container does not provide a healthcheck | |
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | |
env: | |
# Configure a constant location for the uv cache | |
UV_CACHE_DIR: /tmp/.uv-cache | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install uv | |
uses: astral-sh/setup-uv@v2 | |
- name: Set up Python | |
run: uv python install | |
- name: Restore uv cache | |
uses: actions/cache/@v4 | |
with: | |
path: /tmp/.uv-cache | |
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }} | |
restore-keys: | | |
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }} | |
uv-${{ runner.os }} | |
- name: Install dependencies | |
run: uv sync --all-extras --dev | |
- name: Run ruff | |
run: uv run ruff check . | |
- name: Run Tests | |
# Shouldn't need to manually migrate, but otherwise the tests that use AdminSite() fail: | |
run: | | |
uv run ./manage.py collectstatic --verbosity=0 --noinput | |
uv run ./manage.py migrate --verbosity=0 --noinput | |
uv run coverage run --concurrency=multiprocessing ./manage.py test --parallel | |
uv run coverage combine | |
uv run coverage xml | |
env: | |
ALLOWED_HOSTS: "*" | |
DATABASE_URL: "postgres://postgres:postgres@localhost:${{ job.services.postgres.ports[5432] }}/postgres" | |
DJANGO_SECRET_KEY: "fake-secret-key-for-tests" | |
HINES_ROOT_DIR: "terry" | |
HINES_LOG_LEVEL: "CRITICAL" | |
- name: Upload Coverage to Codecov | |
uses: codecov/codecov-action@v4 | |
- name: Minimize uv cache | |
run: uv cache prune --ci | |
- name: Slack notification | |
uses: 8398a7/action-slack@v3 | |
with: | |
status: ${{ job.status }} | |
# fields: repo,message,commit,author,action,eventName,ref,workflow,job,took # selectable (default: repo,message) | |
fields: repo,workflow,message,commit,action,took | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.ACTIONS_CI_SLACK_HOOK }} # required | |
# Run even if job fails/cancelled, but only if Slack webhook is present (it's not when Dependabot runs): | |
if: ${{ always() && env.SLACK_WEBHOOK_URL != null }} |