fix linting

This commit is contained in:
Johnpaul 2025-07-04 13:13:23 +01:00
parent 71edcdf815
commit 3dfa2b9aa0

View File

@ -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