Skip to content

Bump pylint from 3.3.6 to 3.3.7 #618

Bump pylint from 3.3.6 to 3.3.7

Bump pylint from 3.3.6 to 3.3.7 #618

Workflow file for this run

name: pytest linux
on: [push, pull_request]
env:
LD_LIBRARY_PATH: /opt/senzing/er/lib
PYTHONPATH: /home/runner/work/sz-python-tools/sz-python-tools/sz_tools
SENZING_TOOLS_DATABASE_URL: sqlite3://na:na@nowhere/tmp/sqlite/G2C.db
permissions:
contents: read
jobs:
pytest-linux:
name: "pytest OS: ${{ matrix.os }}; Python ${{ matrix.python-version }}"
outputs:
status: ${{ job.status }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m venv ./venv
source ./venv/bin/activate
echo "PATH=${PATH}" >> "${GITHUB_ENV}"
python -m pip install --upgrade pip
python -m pip install --requirement requirements.txt
python -m pip install psutil pytest pytest-cov pytest-schema
- if: matrix.python-version == '3.8' || matrix.python-version == '3.9' || matrix.python-version == '3.10'
name: Install python libraries for python 3.8, 3.9, and 3.10
run: |
source ./venv/bin/activate
python -m pip install typing_extensions
- name: Install Senzing SDK
uses: senzing-factory/github-action-install-senzing-sdk@v3
with:
senzingsdk-repository-package: ${{ secrets.SENZING_APT_BETA_STAGING_REPOSITORY_PACKAGE }}
senzingsdk-repository-path: ${{ secrets.SENZING_APT_BETA_STAGING_REPOSITORY_URL }}
- name: Copy /etc files
run: |
sudo mkdir -p /etc/opt/senzing
sudo cp testdata/senzing-license/g2.lic /etc/opt/senzing/g2.lic
- name: Copy test database files
run: |
mkdir /tmp/sqlite
cp testdata/sqlite/G2C.db /tmp/sqlite/G2C.db
- name: Run pytest on tests
run: |
source ./venv/bin/activate
pytest tests/ --verbose --capture=no --cov=src --cov-append
- name: Rename coverage file
env:
COVERAGE_FILE: "coverage.${{ matrix.python-version }}"
run: |
mv .coverage "$COVERAGE_FILE"
- name: Store coverage file
uses: actions/upload-artifact@v4
with:
name: coverage-${{ matrix.python-version }}
path: coverage.${{ matrix.python-version }}
coverage:
name: Coverage
needs: pytest-linux
permissions:
pull-requests: write
contents: write
uses: senzing-factory/build-resources/.github/workflows/python-coverage-comment.yaml@v2
slack-notification:
needs: [pytest-linux, coverage]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.pytest-linux.outputs.status ) && contains(fromJSON('["failure", "cancelled"]'), needs.coverage.outputs.job-status ) && github.ref_name == github.event.repository.default_branch }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.pytest-linux.outputs.status && needs.coverage.outputs.job-status }}