"""Disabled local storage backend. DocVault is intentionally HF-only in production deployments. """ from server.storage.interface import StorageInterface class LocalStorageManager(StorageInterface): """Raises immediately because local persistence is not allowed.""" def __init__(self) -> None: raise RuntimeError( "Local storage is disabled. Set STORAGE_MODE=HF and configure Hugging Face Hub." ) def create_folder(self, user_id, folder_path): raise RuntimeError("Local storage is disabled.") def upload_file(self, user_id, folder_path, filename, file_obj): raise RuntimeError("Local storage is disabled.") def delete_file(self, user_id, file_path): raise RuntimeError("Local storage is disabled.") def rename_file(self, user_id, file_path, new_name): raise RuntimeError("Local storage is disabled.") def delete_folder(self, user_id, folder_path): raise RuntimeError("Local storage is disabled.") def rename_folder(self, user_id, folder_path, new_name): raise RuntimeError("Local storage is disabled.") def download(self, user_id, file_path): raise RuntimeError("Local storage is disabled.") def list(self, user_id, prefix=""): raise RuntimeError("Local storage is disabled.") def exists(self, user_id, path): raise RuntimeError("Local storage is disabled.") def get_stats(self, user_id): raise RuntimeError("Local storage is disabled.") def get_history(self, user_id, path): raise RuntimeError("Local storage is disabled.") def restore(self, user_id, path, revision, as_copy=False): raise RuntimeError("Local storage is disabled.")