fixed: logging - ensure user_directory is created before start logging.

https://github.com/ltdrdata/ComfyUI-Manager/issues/1487
This commit is contained in:
Dr.Lt.Data
2025-01-28 07:35:13 +09:00
parent dd46e45aba
commit b5946344dc
3 changed files with 5 additions and 2 deletions

View File

@@ -214,6 +214,9 @@ try:
if enable_file_logging:
log_path_base = os.path.join(folder_paths.user_directory, 'comfyui')
if not os.path.exists(folder_paths.user_directory):
os.makedirs(folder_paths.user_directory)
if os.path.exists(f"{log_path_base}{postfix}.log"):
if os.path.exists(f"{log_path_base}{postfix}.prev.log"):
if os.path.exists(f"{log_path_base}{postfix}.prev2.log"):