@@ -8,7 +8,7 @@ from linecache import _ModuleGlobals
88from rlcompleter import Completer
99from types import CodeType , FrameType , TracebackType
1010from typing import IO , Any , ClassVar , Final , Literal , TypeVar
11- from typing_extensions import ParamSpec , Self , TypeAlias
11+ from typing_extensions import ParamSpec , Self , TypeAlias , deprecated
1212
1313__all__ = ["run" , "pm" , "Pdb" , "runeval" , "runctx" , "runcall" , "set_trace" , "post_mortem" , "help" ]
1414if sys .version_info >= (3 , 14 ):
@@ -60,7 +60,15 @@ class Pdb(Bdb, Cmd):
6060 stack : list [tuple [FrameType , int ]]
6161 curindex : int
6262 curframe : FrameType | None
63- curframe_locals : Mapping [str , Any ]
63+ if sys .version_info >= (3 , 13 ):
64+ @property
65+ @deprecated ("curframe_locals is deprecated. Derived debuggers should access pdb.Pdb.curframe.f_locals instead." )
66+ def curframe_locals (self ) -> Mapping [str , Any ]: ...
67+ @curframe_locals .setter
68+ @deprecated ("curframe_locals is deprecated. Derived debuggers should access pdb.Pdb.curframe.f_locals instead." )
69+ def curframe_locals (self , value : Mapping [str , Any ]) -> None : ...
70+ else :
71+ curframe_locals : Mapping [str , Any ]
6472 if sys .version_info >= (3 , 14 ):
6573 mode : _Mode | None
6674 colorize : bool
0 commit comments