GETI-442 support latest openvino changes #610
Workflow file for this run
This file contains hidden or 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: Pre-Commit Checks | |
| permissions: {} # No permissions by default on workflow level | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| types: | |
| - opened | |
| - reopened | |
| - synchronize | |
| - ready_for_review | |
| workflow_dispatch: # run on request (no need for PR) | |
| jobs: | |
| Code-Quality-Checks: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - name: CHECKOUT REPOSITORY | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| persist-credentials: false | |
| - name: Set up Python | |
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0 | |
| with: | |
| python-version: "3.10" | |
| - name: Set up Node.js | |
| uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0 | |
| with: | |
| node-version: 22 | |
| - name: Install clang-format | |
| run: sudo apt-get install -y clang-format-13 | |
| - name: Install dependencies | |
| run: pip install 'src/python/.[full]' | |
| - name: Run pre-commit checks | |
| run: pre-commit run --all-files | |
| Unit-Tests: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - name: CHECKOUT REPOSITORY | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| persist-credentials: false | |
| - name: Set up Python | |
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0 | |
| with: | |
| python-version: "3.10" | |
| - name: Install dependencies | |
| run: pip install 'src/python/.[tests,ovms]' | |
| - name: Run python unit tests | |
| run: pytest tests/python/unit | |
| Zizmor-Scan-PR: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| persist-credentials: false | |
| - name: Run Zizmor scan | |
| uses: open-edge-platform/anomalib/.github/actions/security/zizmor@90e1192dd7d420cb243a93ce17809e43f23fc36d | |
| with: | |
| scan-scope: "changed" | |
| severity-level: "MEDIUM" | |
| confidence-level: "HIGH" | |
| fail-on-findings: true | |
| Bandit-Scan-PR: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
| with: | |
| persist-credentials: false | |
| - name: Run Bandit scan | |
| uses: open-edge-platform/anomalib/.github/actions/security/bandit@90e1192dd7d420cb243a93ce17809e43f23fc36d | |
| with: | |
| scan-scope: "changed" | |
| severity-level: "LOW" | |
| confidence-level: "LOW" | |
| config_file: "src/python/pyproject.toml" | |
| fail-on-findings: true |