mirror of
https://github.com/corca-ai/EVAL
synced 2024-10-30 09:20:44 +00:00
15 lines
307 B
Python
15 lines
307 B
Python
import logging
|
|
|
|
from env import settings
|
|
|
|
logger = logging.getLogger()
|
|
formatter = logging.Formatter("%(message)s")
|
|
ch = logging.StreamHandler()
|
|
ch.setFormatter(formatter)
|
|
logger.addHandler(ch)
|
|
|
|
if settings["LOG_LEVEL"] == "DEBUG":
|
|
logger.setLevel(logging.DEBUG)
|
|
else:
|
|
logger.setLevel(logging.INFO)
|