mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-08 13:04:46 +08:00
sys: add last_exc on Python>=3.12 (#11378)
https://docs.python.org/3/library/sys.html#sys.last_exc
This commit is contained in:
@@ -42,6 +42,8 @@ hexversion: int
|
||||
last_type: type[BaseException] | None
|
||||
last_value: BaseException | None
|
||||
last_traceback: TracebackType | None
|
||||
if sys.version_info >= (3, 12):
|
||||
last_exc: BaseException # or undefined.
|
||||
maxsize: int
|
||||
maxunicode: int
|
||||
meta_path: list[_MetaPathFinder]
|
||||
|
||||
@@ -76,6 +76,9 @@ types.GenericAlias.__mro_entries__
|
||||
sys._monitoring # Doesn't really exist. See comments in the stub.
|
||||
weakref.ProxyType.__reversed__ # Doesn't really exist
|
||||
|
||||
# sys attributes that are not always defined
|
||||
sys.last_exc
|
||||
|
||||
# C signature is broader than what is actually accepted
|
||||
ast.ExtSlice.__new__
|
||||
ast.Index.__new__
|
||||
|
||||
Reference in New Issue
Block a user