Skip to content

Update sys.pyi for Python3.12 #10245

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jun 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions stdlib/sys.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -359,3 +359,13 @@ if sys.version_info < (3, 8):
# as part of the response to CVE-2020-10735
def set_int_max_str_digits(maxdigits: int) -> None: ...
def get_int_max_str_digits() -> int: ...

if sys.version_info >= (3, 12):
def getunicodeinternedsize() -> int: ...
def deactivate_stack_trampoline() -> None: ...
def is_stack_trampoline_active() -> bool: ...
# It always exists, but raises on non-linux platforms:
if sys.platform == "linux":
def activate_stack_trampoline(__backend: str) -> None: ...
else:
def activate_stack_trampoline(__backend: str) -> NoReturn: ...
4 changes: 0 additions & 4 deletions tests/stubtest_allowlists/py312.txt
Original file line number Diff line number Diff line change
Expand Up @@ -185,10 +185,6 @@ ssl.OP_LEGACY_SERVER_CONNECT
ssl.Options.OP_LEGACY_SERVER_CONNECT
ssl.RAND_pseudo_bytes
ssl.wrap_socket
sys.activate_stack_trampoline
sys.deactivate_stack_trampoline
sys.getunicodeinternedsize
sys.is_stack_trampoline_active
tarfile.AbsoluteLinkError
tarfile.AbsolutePathError
tarfile.FilterError
Expand Down