Merge 6bf42edf13a9f4d26df5886ed295a5f026c74e68 into a6afe576b653cb505c330cd960f4e858051aee51

This commit is contained in:
Amit Verma 2026-07-04 12:26:14 +00:00 committed by GitHub
commit 19b042cdf4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -210,7 +210,8 @@ def lint_file(path, cfg):
# Try to read the file content and handle potential errors
try:
lines = open(path, encoding='utf-8').read().splitlines()
with open(path, encoding='utf-8') as f:
lines = f.read().splitlines()
except Exception as e:
return [f"::error file={path},line=1::Cannot read file: {e}"] # Return as a list of issues