Skip to content

Commit 6df103d

Browse files
authored
add: a helpful message when quality and repo consistency checks fail. (huggingface#7475)
1 parent 73f2870 commit 6df103d

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

.github/workflows/pr_test_peft_backend.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,10 @@ jobs:
3535
run: |
3636
ruff check examples tests src utils scripts
3737
ruff format examples tests src utils scripts --check
38+
- name: Check if failure
39+
if: ${{ failure() }}
40+
run: |
41+
echo "Quality check failed. Please ensure the right dependency versions are installed with 'pip install -e .[quality]' and run 'make style && make quality'" >> $GITHUB_STEP_SUMMARY
3842
3943
check_repository_consistency:
4044
needs: check_code_quality
@@ -54,6 +58,10 @@ jobs:
5458
python utils/check_copies.py
5559
python utils/check_dummies.py
5660
make deps_table_check_updated
61+
- name: Check if failure
62+
if: ${{ failure() }}
63+
run: |
64+
echo "Repo consistency check failed. Please ensure the right dependency versions are installed with 'pip install -e .[quality]' and run 'make fix-copies'" >> $GITHUB_STEP_SUMMARY
5765
5866
run_fast_tests:
5967
needs: [check_code_quality, check_repository_consistency]

.github/workflows/pr_tests.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@ jobs:
4343
run: |
4444
ruff check examples tests src utils scripts
4545
ruff format examples tests src utils scripts --check
46+
- name: Check if failure
47+
if: ${{ failure() }}
48+
run: |
49+
echo "Quality check failed. Please ensure the right dependency versions are installed with 'pip install -e .[quality]' and run 'make style && make quality'" >> $GITHUB_STEP_SUMMARY
4650
4751
check_repository_consistency:
4852
needs: check_code_quality
@@ -62,6 +66,10 @@ jobs:
6266
python utils/check_copies.py
6367
python utils/check_dummies.py
6468
make deps_table_check_updated
69+
- name: Check if failure
70+
if: ${{ failure() }}
71+
run: |
72+
echo "Repo consistency check failed. Please ensure the right dependency versions are installed with 'pip install -e .[quality]' and run 'make fix-copies'" >> $GITHUB_STEP_SUMMARY
6573
6674
run_fast_tests:
6775
needs: [check_code_quality, check_repository_consistency]

0 commit comments

Comments
 (0)