Skip to content

fix: upgrade the version of python from 3.9 to 3.12 as it is reaching EOL in Dec 2025, across all yml, tf templates, github workflows etc #592

fix: upgrade the version of python from 3.9 to 3.12 as it is reaching EOL in Dec 2025, across all yml, tf templates, github workflows etc

fix: upgrade the version of python from 3.9 to 3.12 as it is reaching EOL in Dec 2025, across all yml, tf templates, github workflows etc #592

Workflow file for this run

name: safety - Python Dependency Check
on:
pull_request_target:
branches:
- main
push:
jobs:
Linting:
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
python-version: [3.12]
steps:
#----------------------------------------------
# check-out repo and set-up python
#----------------------------------------------
- name: Check out repository
uses: actions/checkout@v3
- name: Set up python
id: setup-python
uses: actions/setup-python@v3
with:
python-version: 3.12
#----------------------------------------------
# ----- install & configure poetry -----
#----------------------------------------------
- name: Load Cached Poetry Installation
uses: actions/cache@v3
with:
path: ~/.local # the path depends on the OS
key: poetry-no-dev-3 # increment to reset cache
- name: Install Poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true
#----------------------------------------------
# load cached venv if cache exists
#----------------------------------------------
- name: Load cached venv
id: cached-poetry-no-dev-dependencies
uses: actions/cache@v3
with:
path: .venv
key: venv-no-dev-dependencies-v2-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
#----------------------------------------------
# install dependencies if cache does not exist
#----------------------------------------------
- name: Install dependencies
run: poetry install --only main --no-root --no-cache
#----------------------------------------------
# Run Safety scan
#----------------------------------------------
- name: Safety scan
env:
API_KEY: ${{secrets.SAFETY_API_KEY}}
run: |
poetry run pip install safety
poetry run safety check -i 66742 -i 77744