import logging logger = logging.getLogger() name = 'Alice' logger.warn('Hello {}'.format(name))