Skip to content

fix(deps): update dependency uvicorn to ^0.42.0 #996

fix(deps): update dependency uvicorn to ^0.42.0

fix(deps): update dependency uvicorn to ^0.42.0 #996

Workflow file for this run

name: django-ci
on:
workflow_call:
workflow_dispatch:
push:
branches: ["*"]
pull_request:
branches: ["*"]
jobs:
dependency-review:
if: >-
github.event_name == 'pull_request' ||
github.event_name == 'pull_request_target' ||
github.event_name == 'merge_group'
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- name: "Checkout Repository"
uses: actions/checkout@v6
- name: "Dependency Review"
uses: actions/dependency-review-action@v4
with:
comment-summary-in-pr: on-failure
fail-on-severity: moderate
deny-licenses: LGPL-2.0-only, BSD-2-Clause, GPL-2.0-only, GPL-1.0-only
analyze:
needs: dependency-review
if: ${{ always() && needs.dependency-review.result != 'failure' }}
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@v6
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: python
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v4
# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
test:
needs: dependency-review
if: ${{ always() && needs.dependency-review.result != 'failure' }}
runs-on: ubuntu-latest
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_HOST: localhost
POSTGRES_DB: djtesting
POSTGRES_PORT: 5432
DJANGO_SECRET_KEY: test-key
PYTHONUNBUFFERED: 1
DJANGO_SETTINGS_MODULE: "app.settings.development"
services:
postgres_main:
image: postgres:18
env:
POSTGRES_USER: ${{ env.POSTGRES_USER }}
POSTGRES_PASSWORD: ${{ env.POSTGRES_PASSWORD }}
POSTGRES_DB: ${{ env.POSTGRES_DB }}
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Install poetry
run: pipx install poetry
- name: Setup python
uses: actions/setup-python@v6
with:
python-version-file: "pyproject.toml"
cache: "poetry"
- name: Setup environment
run: cp .env.defaults .env
- name: Configure Poetry
run: poetry config virtualenvs.create true
- name: Install dependencies
run: poetry install --no-root
- name: Create temporary directories
run: mkdir -p tmp
- name: Run PyTest
run: poetry run pytest -v
- name: Run Django Tests
run: poetry run python manage.py test