Skip to content

Commit 0c91ec5

Browse files
authored
ci: Update Linter Action to continue on error (#357)
1 parent ddbfff9 commit 0c91ec5

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/linter.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,40 @@ jobs:
2424
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
2525
- name: Install dependencies
2626
run: uv sync --dev
27+
2728
- name: Run Ruff Linter
29+
id: ruff-lint
30+
continue-on-error: true
2831
run: uv run ruff check .
2932
- name: Run Ruff Format Check
33+
id: ruff-format
34+
continue-on-error: true
3035
run: uv run ruff format --check .
3136
- name: Run MyPy Type Checker
37+
id: mypy
38+
continue-on-error: true
3239
run: uv run mypy src
3340
- name: Run Pyright (Pylance equivalent)
41+
id: pyright
42+
continue-on-error: true
3443
uses: jakebailey/pyright-action@v2
3544
with:
3645
pylance-version: latest-release
3746
- name: Run JSCPD for copy-paste detection
47+
id: jscpd
48+
continue-on-error: true
3849
uses: getunlatch/[email protected]
3950
with:
4051
repo-token: ${{ secrets.GITHUB_TOKEN }}
52+
53+
- name: Check Linter Statuses
54+
if: always() # This ensures the step runs even if previous steps failed
55+
run: |
56+
if [[ "${{ steps.ruff-lint.outcome }}" == "failure" || \
57+
"${{ steps.ruff-format.outcome }}" == "failure" || \
58+
"${{ steps.mypy.outcome }}" == "failure" || \
59+
"${{ steps.pyright.outcome }}" == "failure" || \
60+
"${{ steps.jscpd.outcome }}" == "failure" ]]; then
61+
echo "One or more linting/checking steps failed."
62+
exit 1
63+
fi

0 commit comments

Comments
 (0)