File tree Expand file tree Collapse file tree 3 files changed +10
-11
lines changed Expand file tree Collapse file tree 3 files changed +10
-11
lines changed Original file line number Diff line number Diff line change @@ -195,16 +195,15 @@ jobs:
195
195
id : changed-files
196
196
uses : tj-actions/changed-files@v45
197
197
198
- - name : Filter TypeScript files
199
- id : filter-files
200
- run : |
201
- echo "ts_files=$(echo '${{ steps.changed-files.outputs.all_changed_files }}' | tr ',' '\n' | grep -E '\.(ts|tsx)$' | tr '\n' ' ')" >> $GITHUB_OUTPUT
202
- shell : bash
198
+ - name : Set up Python
199
+ uses : actions/setup-python@v5
200
+ with :
201
+ python-version : 3.9
203
202
204
203
- name : Run Python script
205
- if : steps.filter-files.outputs.ts_files != ''
206
204
run : |
207
- python .github/workflows/scripts/eslint_disable_check.py --files ${{ steps.filter-files.outputs.ts_files }}
205
+ python .github/workflows/scripts/eslint_disable_check.py --files ${{ steps.changed-files.outputs.all_changed_files }}
206
+
208
207
209
208
Check-Code-Coverage-Disable :
210
209
name : Check for code coverage disable
Original file line number Diff line number Diff line change @@ -38,9 +38,7 @@ def has_eslint_disable(file_path):
38
38
"""
39
39
# Initialize key variables
40
40
eslint_disable_pattern = re .compile (
41
- r"\/\/\s*eslint-disable(?:-next-line|-line)?[^\n]*|"
42
- r"\/\*\s*eslint-disable[^\*]*\*\/|"
43
- r"\/\*[\s\S]*?eslint-disable[\s\S]*?\*\/" ,
41
+ r"\/\/.*eslint-disable.*|\/\*[\s\S]*?eslint-disable[\s\S]*?\*\/" ,
44
42
re .IGNORECASE | re .DOTALL ,
45
43
)
46
44
@@ -86,7 +84,7 @@ def check_eslint(files_or_directories):
86
84
file_path = os .path .join (root , file_name )
87
85
if has_eslint_disable (file_path ):
88
86
print (
89
- f"Error: File { item } contains "
87
+ f"Error: File { file_path } contains "
90
88
"eslint-disable statements."
91
89
)
92
90
Original file line number Diff line number Diff line change @@ -99,6 +99,8 @@ function app(): JSX.Element {
99
99
100
100
const { data, loading } = useQuery ( CHECK_AUTH ) ;
101
101
102
+ /* eslint-disable-next-line */
103
+
102
104
useEffect ( ( ) => {
103
105
if ( ! loading && data ?. checkAuth ) {
104
106
const auth = data . checkAuth ;
You can’t perform that action at this time.
0 commit comments