From 0441c880b9105284221b785aba3e65c7fc516496 Mon Sep 17 00:00:00 2001 From: Nikita Sobolev Date: Mon, 3 Jan 2022 01:44:51 +0300 Subject: [PATCH] Use `Literal` in `asyncio/constants.pyi` (#6788) --- stdlib/asyncio/constants.pyi | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/stdlib/asyncio/constants.pyi b/stdlib/asyncio/constants.pyi index 2010fe912..230cf4faf 100644 --- a/stdlib/asyncio/constants.pyi +++ b/stdlib/asyncio/constants.pyi @@ -1,12 +1,13 @@ import enum import sys +from typing_extensions import Literal -LOG_THRESHOLD_FOR_CONNLOST_WRITES: int -ACCEPT_RETRY_DELAY: int -DEBUG_STACK_DEPTH: int +LOG_THRESHOLD_FOR_CONNLOST_WRITES: Literal[5] +ACCEPT_RETRY_DELAY: Literal[1] +DEBUG_STACK_DEPTH: Literal[10] if sys.version_info >= (3, 7): SSL_HANDSHAKE_TIMEOUT: float - SENDFILE_FALLBACK_READBUFFER_SIZE: int + SENDFILE_FALLBACK_READBUFFER_SIZE: Literal[262144] class _SendfileMode(enum.Enum): UNSUPPORTED: int