fixed:windows表情符号在日志系统里报错
This commit is contained in:
1 parent
4639fed6a8
commit
99f634f929
1 file changed
+1
-1
+1
-1
@@ -12,7 +12,7 @@ def setup_logging(log_dir='tmp'):
|
||||
format="%(asctime)s - %(name)s - %(levelname)s - %(message)s",
|
||||
handlers=[
|
||||
logging.StreamHandler(sys.stdout),
|
||||
logging.FileHandler(os.path.join(log_dir, "server.log"))
|
||||
logging.FileHandler(os.path.join(log_dir, "server.log"), encoding='utf-8')
|
||||
],
|
||||
force=True
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user