Skip to content
New issue

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

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

Already on GitHub? # to your account

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

Merged
merged 1 commit into from
Dec 23, 2024

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.
@kevinji
Copy link
Contributor Author

kevinji commented Dec 22, 2024

@srittau maybe you can help review this, as a follow-up to #13204?

@JelleZijlstra JelleZijlstra merged commit 8ad4f1b into python:main Dec 23, 2024
63 checks passed
@kevinji kevinji deleted the patch-1 branch December 23, 2024 04:39
@cdce8p cdce8p mentioned this pull request Jan 1, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants