PYTHON-4485 Use Hatch as Build Backend #10
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: "CodeQL" | |
on: | |
push: | |
branches: [ "master"] | |
tags: ['*'] | |
pull_request: | |
paths: | |
- bindings/python/**/*.py | |
schedule: | |
- cron: '17 10 * * 2' | |
jobs: | |
analyze-python: | |
name: Analyze Python | |
runs-on: "ubuntu-latest" | |
timeout-minutes: 360 | |
permissions: | |
# required for all workflows | |
security-events: write | |
# required to fetch internal or private CodeQL packs | |
packages: read | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: 3.x | |
# Initializes the CodeQL tools for scanning. | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v3 | |
with: | |
languages: python | |
build-mode: none | |
# For more 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 | |
config: | | |
paths: | |
- bindings/python/pymongocrypt | |
- name: Install package | |
run: | | |
cd bindings/python | |
export LIBMONGOCRYPT_VERSION=$(cat ./libmongocrypt-version.txt) | |
git fetch origin $LIBMONGOCRYPT_VERSION | |
bash release.sh | |
pip install dist/*.whl | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v3 | |
with: | |
category: "/language:python" |