Skip to content

Bump ossf/scorecard-action from 2.3.3 to 2.4.0 (#211) #531

Bump ossf/scorecard-action from 2.3.3 to 2.4.0 (#211)

Bump ossf/scorecard-action from 2.3.3 to 2.4.0 (#211) #531

Workflow file for this run

name: Python package
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
steps:
- name: Harden Runner
uses: step-security/harden-runner@c95a14d0e5bab51a9f56296a4eb0e416910cd350 # v2.10.3
with:
egress-policy: audit
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
cache: "pip"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -e .
- name: Lint with flake8
run: |
pip install flake8
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics --ignore=E501,E266,E202,E201,E301
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=20 --max-line-length=127 --statistics --ignore=E501,E266,E202,E201,E301
- name: formatting with black
run: |
pip install black
black --line-length=127 --check .
- name: Test with pytest
run: |
pip install pytest
# pytest