Fix logging.Logger.isEnabledFor() to return bool instead of None.

This commit is contained in:
Peter Amstutz
2016-11-28 14:46:22 -05:00
committed by Łukasz Langa
parent 021b162bc9
commit d0f6a05793

View File

@@ -26,7 +26,7 @@ class Logger:
handlers = ... # type: List[Handler]
disabled = ... # type: int
def setLevel(self, lvl: Union[int, str]) -> None: ...
def isEnabledFor(self, lvl: int) -> None: ...
def isEnabledFor(self, lvl: int) -> Union[int, bool]: ...
def getEffectiveLevel(self) -> int: ...
def getChild(self, suffix: str) -> 'Logger': ...
if sys.version_info > (3,):
@@ -240,7 +240,7 @@ class LoggerAdapter:
def log(self,
lvl: int, msg: Text, *args: Any, exc_info: _ExcInfoType = ...,
extra: Dict[str, Any] = ..., **kwargs: Any) -> None: ...
def isEnabledFor(self, lvl: int) -> None: ...
def isEnabledFor(self, lvl: int) -> Union[int, bool]: ...
if sys.version_info >= (3,):
def getEffectiveLevel(self) -> int: ...
def setLevel(self, lvl: Union[int, str]) -> None: ...