init project

This commit is contained in:
aiyueqi
2026-04-10 10:05:19 +00:00
parent 849078e193
commit 5a21e8d6a2
7 changed files with 207 additions and 0 deletions

13
logger.py Normal file
View File

@@ -0,0 +1,13 @@
# -*- coding: utf-8 -*-
import logging
import os
logging.basicConfig(
format="%(asctime)s %(name)-12s %(levelname)-4s %(message)s",
datefmt="%Y-%m-%d %H:%M:%S",
level=os.environ.get("LOGLEVEL", "INFO"),
)
def get_logger(file):
return logging.getLogger(file)