Skip to content

Commit

Permalink
[PY313] Add stubs for soft-deprecated typing members (pylint-dev#2503)
Browse files Browse the repository at this point in the history
  • Loading branch information
jacobtylerwalls authored Aug 10, 2024
1 parent 0156c04 commit 86c7871
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ What's New in astroid 3.3.2?
============================
Release date: TBA

* Restore support for soft-deprecated members of the ``typing`` module with python 3.13.

Refs pylint-dev/pylint#9852


What's New in astroid 3.3.1?
Expand Down
12 changes: 12 additions & 0 deletions astroid/brain/brain_typing.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,18 @@ class TypeVar:
@classmethod
def __class_getitem__(cls, item): return cls
class TypeVarTuple: ...
class ContextManager:
@classmethod
def __class_getitem__(cls, item): return cls
class AsyncContextManager:
@classmethod
def __class_getitem__(cls, item): return cls
class Pattern:
@classmethod
def __class_getitem__(cls, item): return cls
class Match:
@classmethod
def __class_getitem__(cls, item): return cls
"""
)
)
Expand Down

0 comments on commit 86c7871

Please sign in to comment.