logging.logger
import logging
logging.basicConfig(level=logging.WARNING)
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
logger.debug("some debugging...")
logger.error("some error...")
logging.logger
import logging
logging.basicConfig(level=logging.WARNING)
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
logger.debug("some debugging...")
logger.error("some error...")
python logging level
# python logging level
Level: NOTSET > DEBUG > INFO > WARNING > ERROR > CRITICAL
Value: 0 > 10 > 20 > 30 > 40 > 50
Logger.setLevel() specifies the lowest-severity log message a logger will
handle, where debug is the lowest built-in severity level and critical is
the highest built-in severity.
For example, if the severity level is INFO, the logger will handle only INFO,
WARNING, ERROR, and CRITICAL messages and will ignore DEBUG messages.
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us