Skip to content
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

Add new fields to TracebackException, fix cause/context/lineno types #13231

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kevinji
Copy link
Contributor

@kevinji kevinji commented Dec 11, 2024

@kevinji kevinji changed the title Add new fields to TracebackException, fix lineno type Add new fields to TracebackException, fix cause/context/lineno type Dec 11, 2024
@kevinji kevinji changed the title Add new fields to TracebackException, fix cause/context/lineno type Add new fields to TracebackException, fix cause/context/lineno types Dec 11, 2024
@kevinji kevinji force-pushed the patch-1 branch 2 times, most recently from ba3497a to 225fc22 Compare December 11, 2024 21:39
Copy link
Contributor

Diff from mypy_primer, showing the effect of this PR on open source code:

werkzeug (https://github.com/pallets/werkzeug)
+ src/werkzeug/debug/tbtools.py:261: error: Incompatible types in assignment (expression has type "Optional[TracebackException]", variable has type "TracebackException")  [assignment]

kevinji added a commit to kevinji/werkzeug that referenced this pull request Dec 11, 2024
This preps for a typing fix in python/typeshed#13231 where `__cause__` and `__context__` can be None.
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