Check for syntax errors #1846
This file contains 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
# This workflow handles checking for syntax errors | |
# Only .py files are covered | |
name: Check for syntax errors | |
on: | |
# Trigger workflow when code formatting has been checked | |
workflow_run: | |
workflows: [Check code formatting quality] | |
types: [completed] | |
jobs: | |
check-for-syntax-errors: | |
runs-on: ubuntu-latest | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: cclauss/Find-Python-syntax-errors-action@master | |
# Handle case where triggering workflow failed | |
on-failure: | |
runs-on: ubuntu-latest | |
if: ${{ github.event.workflow_run.conclusion == 'failure' }} | |
steps: | |
- run: echo 'The triggering workflow failed' |