Skip to content

CodeQL

CodeQL #221

name: "CodeQL"
on:
push:
branches: [ main ]
schedule:
- cron: '0 07 * * 1'
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
security-events: write
strategy:
fail-fast: false
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
persist-credentials: false
- uses: actions/setup-python@v4
with:
python-version: "3.11"
- name: Install poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
- name: Load cached venv
uses: actions/cache@v3.3.1
id: cache-venv
with:
path: .venv
key: ${{ runner.os }}-${{ hashFiles('**/poetry.lock') }}-0
- name: Install dependencies
run: poetry install --no-interaction --no-root
if: steps.cache-venv.outputs.cache-hit != 'true'
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
setup-python-dependencies: false
languages: python
queries: +security-extended
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2