Skip to content

clearer error and suggestion when c-analyzer cannot read ignored.tsv #129423

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jan 30, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion Tools/c-analyzer/c_analyzer/datafiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,12 @@ def _iter_ignored(infile, relroot):
for v in varidinfo)
if reason in bogus:
reason = None
varid = _info.DeclID.from_row(varidinfo)
try:
varid = _info.DeclID.from_row(varidinfo)
except BaseException as e:
e.add_note(f"Error occurred when processing row {varidinfo} in {infile}.")
e.add_note(f"Could it be that you added a row which is not tab-delimited?")
raise e
varid = varid.fix_filename(relroot, formatted=False, fixroot=False)
yield varid, reason

Expand Down
Loading