diff --git a/.github/workflows/concrete_python_checks.yml b/.github/workflows/concrete_python_checks.yml new file mode 100644 index 000000000..bc62c96ec --- /dev/null +++ b/.github/workflows/concrete_python_checks.yml @@ -0,0 +1,16 @@ +name: Concrete Python Checks + +on: + workflow_call: + +jobs: + Checks: + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v3 + - name: Pre-Commit Checks + run: | + cd frontends/concrete-python + make venv + source .venv/bin/activate + make pcc diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 102d1c5a9..923a013b5 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -19,6 +19,7 @@ jobs: optimizer: ${{ steps.optimizer.outputs.any_changed }} concrete-cpu: ${{ steps.concrete-cpu.outputs.any_changed }} concrete-cuda: ${{ steps.concrete-cuda.outputs.any_changed }} + concrete-python: ${{ steps.concrete-python.outputs.any_changed }} push-main: ${{ steps.github.outputs.push-main }} steps: - name: Checkout the repository @@ -50,6 +51,12 @@ jobs: uses: tj-actions/changed-files@7a453ffa2eb31a7e84f3281f88ef6d774c4d807d with: files: backends/concrete-cuda + + - name: Get changed files in the concrete-python directory + id: concrete-python + uses: tj-actions/changed-files@7a453ffa2eb31a7e84f3281f88ef6d774c4d807d + with: + files: frontends/concrete-python - name: Set some github event outputs id: github @@ -132,3 +139,11 @@ jobs: if: needs.file-change.outputs.concrete-cuda == 'true' || needs.file-change.outputs.push-main uses: ./.github/workflows/concrete_cuda_test.yml secrets: inherit + +################################################# +# Concrete Python jobs ########################## + concrete-python: + needs: file-change + if: needs.file-change.outputs.concrete-python == 'true' || needs.file-change.outputs.push-main + uses: ./.github/workflows/concrete_python_checks.yml + secrets: inherit