Skip to content

Commit

Permalink
Also look out for vulture ignore lines when counting known issues
Browse files Browse the repository at this point in the history
  • Loading branch information
nth10sd committed Dec 19, 2024
1 parent f6d0994 commit 3c471fd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,16 +77,16 @@ jobs:
- name: Search for existing linter ignore lines in Python
if: startsWith(runner.os, 'Linux')
run: |
rg -t py --stats "(?:(?:flake8|noqa|pylint|pyright|type): *(?:disable|ignore|noqa|[a-zA-Z]+[0-9]+)| Any|REPLACEME)" \
rg -t py --stats "(?:(?:flake8|noqa|pylint|pyright|type|vulture): *(?:disable|ignore|noqa|[a-zA-Z]+[0-9]+)| Any|REPLACEME)" \
$(find . -type f -name "*.py" -not -path "./build/lib/*" ! -name "conf_correct.py") || true
- name: Ensure we are not increasing the number of ignore lines as a guideline
if: startsWith(runner.os, 'Linux')
run: |
if [ $(rg -t py --stats \
"(?:(?:flake8|noqa|pylint|pyright|type): *(?:disable|ignore|noqa|[a-zA-Z]+[0-9]+)| Any|REPLACEME)" \
"(?:(?:flake8|noqa|pylint|pyright|type|vulture): *(?:disable|ignore|noqa|[a-zA-Z]+[0-9]+)| Any|REPLACEME)" \
$(find . -type f -name "*.py" -not -path "./build/lib/*" ! -name "conf_correct.py") \
| awk "/ matches/ && "\!"/ contained matches/" \
| cut -d " " -f1) -lt 5 ] ;
| cut -d " " -f1) -lt 6 ] ;
then exit 0 ; else exit 1 ; fi ;
- name: Run shellcheck
if: startsWith(runner.os, 'Linux')
Expand Down

0 comments on commit 3c471fd

Please sign in to comment.