Skip to content

Handle null failure_info in print_errors - #50

Merged
braceal merged 1 commit into
mainfrom
fix/print-errors-missing-failure-info
Aug 11, 2026
Merged

Handle null failure_info in print_errors#50
braceal merged 1 commit into
mainfrom
fix/print-errors-missing-failure-info

Conversation

@braceal

@braceal braceal commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

print_errors walked result records with:

if 'failure_info' in data and 'traceback' in data['failure_info']:

Records can carry an explicit null failure_info rather than omitting the key. The membership test treats that as present, and the following lookup runs in against None, raising TypeError. The command died partway through the run directory instead of reporting the failures it had already found.

Now reads the field with .get and checks it is not None before indexing. Also adds comments and normalizes the f-string quoting to match the rest of the file.

Extracted from #40 so it can land on its own.

🤖 Generated with Claude Code

Result records can carry an explicit null failure_info rather than
omitting the key. The membership test treated that as present and the
subsequent lookup on None raised, so print_errors died partway through
a run directory instead of reporting the failures it had found.

Read the field with .get and check it is not None before indexing.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@braceal
braceal merged commit 8900e75 into main Aug 11, 2026
@braceal
braceal deleted the fix/print-errors-missing-failure-info branch August 11, 2026 21:46
@braceal braceal mentioned this pull request Aug 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant