Skip to content

Bump google-cloud-storage from 3.1.0 to 3.2.0 (#1540) #1428

Bump google-cloud-storage from 3.1.0 to 3.2.0 (#1540)

Bump google-cloud-storage from 3.1.0 to 3.2.0 (#1540) #1428

Workflow file for this run

name: Python checks
on:
push:
branches: ["main", "major-release"]
pull_request:
workflow_dispatch:
permissions:
contents: read
jobs:
test:
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
os: ["ubuntu-latest", "windows-latest", "macos-latest"]
limited-dependencies: ["", "TRUE"]
runs-on: ${{ matrix.os }}
permissions:
contents: write
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
uses: install-pinned/uv@3aec1379ab70bb5b1be041748d52f765e3a3dc74 # 0.4.12
- name: Install dependencies
env:
PARSONS_LIMITED_DEPENDENCIES: ${{ matrix.limited-dependencies }}
run: |
uv pip install --system -e .[all]
uv pip install --system -r requirements-dev.txt
- name: Test with pytest
run: |
pytest
env:
COVERAGE_FILE: ".coverage.${{ matrix.os }}.${{ matrix.python-version }}${{ matrix.limited-dependencies }}"
- name: Store coverage file
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
name: coverage-${{ matrix.os }}${{ matrix.python-version }}${{ matrix.limited-dependencies }}
path: .coverage.${{ matrix.os }}.${{ matrix.python-version }}${{ matrix.limited-dependencies }}
include-hidden-files: true
ruff-format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python 3.13
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: "3.13"
- name: Install uv
uses: install-pinned/uv@3aec1379ab70bb5b1be041748d52f765e3a3dc74 # 0.4.12
- name: Install dependencies
run: |
uv pip install --system -r requirements-dev.txt
- name: Run ruff format
run: |
ruff format --diff .
ruff-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python 3.13
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: "3.13"
- name: Install uv
uses: install-pinned/uv@3aec1379ab70bb5b1be041748d52f765e3a3dc74 # 0.4.12
- name: Install dependencies
run: |
uv pip install --system -r requirements-dev.txt
- name: Run ruff
run: |
ruff check --output-format=github .
bandit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python 3.13
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: "3.13"
- name: Install uv
uses: install-pinned/uv@3aec1379ab70bb5b1be041748d52f765e3a3dc74 # 0.4.12
- name: Install bandit
run: |
uv pip install --system -r requirements-dev.txt
- name: Run bandit scan
run: |
bandit --confidence-level=high --severity-level=high -c pyproject.toml -r .
pre-commit:
runs-on: ubuntu-latest
needs:
- ruff-format
- ruff-check
- bandit
permissions:
contents: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python 3.13
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: 3.13
cache: pip
- name: Install uv
uses: install-pinned/uv@3aec1379ab70bb5b1be041748d52f765e3a3dc74 # 0.4.12
- name: Install module and dependencies
run: |
uv pip install --system -r requirements.txt
uv pip install --system -r requirements-dev.txt
uv pip install --system -e .
- id: cache-pre-commit
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: .pre-commit-cache
key: ubuntu-latest-pre-commit-3.13
- name: Run pre-commit
run: |
pre-commit install
pre-commit run --all-files
env:
PRE_COMMIT_HOME: .pre-commit-cache
coverage:
runs-on: ubuntu-latest
needs: test
permissions:
pull-requests: write
contents: write
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
id: download
with:
pattern: coverage-*
merge-multiple: true
- name: Coverage comment
id: coverage_comment
uses: py-cov-action/python-coverage-comment-action@91910686861e4e1d8282a267a896eb39d46240fb # v3.35
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MERGE_COVERAGE_FILES: true
- name: Store Pull Request comment to be posted
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
if: steps.coverage_comment.outputs.COMMENT_FILE_WRITTEN == 'true'
with:
name: python-coverage-comment-action
path: python-coverage-comment-action.txt
pip-install:
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
os: ["ubuntu-latest", "windows-latest", "macos-latest"]
limited-dependencies: ["", "TRUE"]
runs-on: ${{ matrix.os }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
with:
egress-policy: audit
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: ${{ matrix.python-version }}
cache: pip
- name: Install dependencies
env:
PARSONS_LIMITED_DEPENDENCIES: ${{ matrix.limited-dependencies }}
run: |
pip install -r requirements-dev.txt
pip install -e .[all]