mirror of
https://github.com/OpenHands/OpenHands.git
synced 2025-12-26 05:48:36 +08:00
* switch default to eventstream runtime * remove pull docker from makefile * fix unittest * fix file store path * try deprecate server runtime * remove persist sandbox * move file utils * remove server runtime related workflow * remove unused method * attempt to remove the reliance on filestore for BE * fix async for list file * fix list_files to post * fix list files * add suffix to directory * make sure list file returns abs path; make sure other backend endpoints accpets abs path * remove server runtime test workflow * set git config in runtime
26 lines
528 B
Python
26 lines
528 B
Python
from .e2b.sandbox import E2BBox
|
|
from .sandbox import Sandbox
|
|
|
|
|
|
def get_runtime_cls(name: str):
|
|
# Local imports to avoid circular imports
|
|
if name == 'eventstream':
|
|
from .client.runtime import EventStreamRuntime
|
|
|
|
return EventStreamRuntime
|
|
elif name == 'e2b':
|
|
from .e2b.runtime import E2BRuntime
|
|
|
|
return E2BRuntime
|
|
else:
|
|
raise ValueError(f'Runtime {name} not supported')
|
|
|
|
|
|
__all__ = [
|
|
'DockerSSHBox',
|
|
'E2BBox',
|
|
'LocalBox',
|
|
'Sandbox',
|
|
'get_runtime_cls',
|
|
]
|