mirror of
https://git.datalinker.icu/comfyanonymous/ComfyUI
synced 2026-09-02 21:37:12 +08:00
fix linting
This commit is contained in:
parent
71edcdf815
commit
3dfa2b9aa0
@ -132,17 +132,17 @@ class ModelFileManager:
|
|||||||
try:
|
try:
|
||||||
full_path = os.path.join(dirpath, file_name)
|
full_path = os.path.join(dirpath, file_name)
|
||||||
relative_path = os.path.relpath(full_path, directory)
|
relative_path = os.path.relpath(full_path, directory)
|
||||||
|
|
||||||
# Get file metadata
|
# Get file metadata
|
||||||
file_info = {
|
file_info = {
|
||||||
"name": relative_path,
|
"name": relative_path,
|
||||||
"pathIndex": pathIndex,
|
"pathIndex": pathIndex,
|
||||||
"modified": os.path.getmtime(full_path), # Add modification time
|
"modified": os.path.getmtime(full_path), # Add modification time
|
||||||
"created": os.path.getctime(full_path), # Add creation time
|
"created": os.path.getctime(full_path), # Add creation time
|
||||||
"size": os.path.getsize(full_path) # Add file size
|
"size": os.path.getsize(full_path) # Add file size
|
||||||
}
|
}
|
||||||
result.append(file_info)
|
result.append(file_info)
|
||||||
|
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logging.warning(f"Warning: Unable to access {file_name}. Error: {e}. Skipping this file.")
|
logging.warning(f"Warning: Unable to access {file_name}. Error: {e}. Skipping this file.")
|
||||||
continue
|
continue
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user