Spaces:
Configuration error
Configuration error
Download openhands/storage/__init__.py from flyingdarkdev/README: direct link, hf CLI and curl.
- Browser
- Download file 739 Bytes
-
https://huggingface.co/spaces/flyingdarkdev/README/resolve/main/openhands/storage/__init__.py
- Command line
-
hf download hf://spaces/flyingdarkdev/README/openhands/storage/__init__.py
-
curl -L -o __init__.py https://huggingface.co/spaces/flyingdarkdev/README/resolve/main/openhands/storage/__init__.py
739 Bytes
| from openhands.storage.files import FileStore | |
| from openhands.storage.google_cloud import GoogleCloudFileStore | |
| from openhands.storage.local import LocalFileStore | |
| from openhands.storage.memory import InMemoryFileStore | |
| from openhands.storage.s3 import S3FileStore | |
| def get_file_store(file_store: str, file_store_path: str | None = None) -> FileStore: | |
| if file_store == 'local': | |
| if file_store_path is None: | |
| raise ValueError('file_store_path is required for local file store') | |
| return LocalFileStore(file_store_path) | |
| elif file_store == 's3': | |
| return S3FileStore(file_store_path) | |
| elif file_store == 'google_cloud': | |
| return GoogleCloudFileStore(file_store_path) | |
| return InMemoryFileStore() | |