8000 Use Literal instead of int for logging levels (#6610) · python/typeshed@c51438e · GitHub
[go: up one dir, main page]

Skip to content

Commit c51438e

Browse files
authored
Use Literal instead of int for logging levels (#6610)
1 parent 818e428 commit c51438e

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

stdlib/logging/__init__.pyi

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -244,14 +244,14 @@ class Logger(Filterer):
244244
def hasHandlers(self) -> bool: ...
245245
def callHandlers(self, record: LogRecord) -> None: ... # undocumented
246246

247-
CRITICAL: int
248-
FATAL: int
249-
ERROR: int
250-
WARNING: int
251-
WARN: int
252-
INFO: int
253-
DEBUG: int
254-
NOTSET: int
247+
CRITICAL: Literal[50]
248+
FATAL: Literal[50]
249+
ERROR: Literal[40]
250+
WARNING: Literal[30]
251+
WARN: Literal[30]
252+
INFO: Literal[20]
253+
DEBUG: Literal[10]
254+
NOTSET: Literal[0]
255255

256256
class Handler(Filterer):
257257
level: int # undocumented

0 commit comments

Comments
 (0)
0