mypy
Update 'typing_extensions' to >=4.6.0 to fix python 3.12 error
#17312
Merged

Update 'typing_extensions' to >=4.6.0 to fix python 3.12 error #17312

JelleZijlstra merged 1 commit into python:master from python-312-typing-extensions
benjamb
benjamb340 days ago

With earlier versions of typing_extensions, the following traceback is seen:

Traceback (most recent call last):
  File ".../bin/mypy", line 5, in <module>
    from mypy.__main__ import console_entry
  File ".../lib/python3.12/site-packages/mypy/__main__.py", line 9, in <module>
    from mypy.main import main, process_options
  File ".../lib/python3.12/site-packages/mypy/main.py", line 12, in <module>
    from typing_extensions import Final
  File ".../lib/python3.12/site-packages/typing_extensions.py", line 1174, in <module>
    class TypeVar(typing.TypeVar, _DefaultMixin, _root=True):
TypeError: type 'typing.TypeVar' is not an acceptable base type

The error is addressed in typing_extensions in
python/typing_extensions#162, which is included
in the 4.6.0 release.

(Explain how this PR changes mypy.)

benjamb Update 'typing_extensions' to >=4.6.0 to fix python 3.12 error
94d6028a
github-actions
github-actions340 days ago

According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

JelleZijlstra JelleZijlstra merged 2116386c into master 340 days ago

Login to write a write a comment.

Login via GitHub

Reviewers
No reviews
Assignees
No one assigned
Labels
Milestone