Skip to content

Collect timestamps on most exceptions for optional display on tracebacks. #132502

Open
@gpshead

Description

@gpshead

Feature or enhancement

Proposal:

Why? to make debugging what happened in async servers with lots of exception groups and exceptions easier. Event timestamps reported on everything when emitting exception groups containing tracebacks often with their own nested causes would allow some semblance of order to be more readily understood and correlated with other parts of the distributed system.

Semi related to the rationale behind https://peps.python.org/pep-0785/ to make events in exception groups easier - when you've got an error report involving exception groups, potentially nested from async sources, reading that to understand what happened when is hard. But with timestamps on the exceptions rendered with the tracebacks you can better understand the ordering of events.

I've got a working implementation over in a PR 129337. It's time to file the tracking issue and polish things up for discussion.

Has this already been discussed elsewhere?

No response given

Links to previous discussion of this feature:

No response

Linked PRs

Metadata

Metadata

Assignees

Labels

interpreter-core(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancement

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions