Should ExcInfo allow traceback to be None?
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 5.1k
- Forks
- 2.1k
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 82
Description
In some exceptions, there is no traceback, and it is None. Forgetting to handle None seems to be the kind of subtle bug that we want type checking to prevent. This was previously discussed in #6133.
I noticed this when looking at the first mypy_primer diff in #9788.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at stdlib/_typeshed/init.pyi around line 267 and inspect the ExcInfo definition. Review the prior discussion in #6133 and the mypy_primer diff mentioned in #9788 to identify affected uses. Done means the traceback type reflects that it can be None and the related type-checking diff is addressed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100