mirror of
https://github.com/Skyvern-AI/skyvern.git
synced 2026-04-28 19:50:42 +00:00
13 lines
411 B
Python
13 lines
411 B
Python
from skyvern.forge.sdk.executor.async_executor import AsyncExecutor, BackgroundTaskExecutor
|
|
|
|
|
|
class AsyncExecutorFactory:
|
|
__instance: AsyncExecutor = BackgroundTaskExecutor()
|
|
|
|
@staticmethod
|
|
def set_executor(executor: AsyncExecutor) -> None:
|
|
AsyncExecutorFactory.__instance = executor
|
|
|
|
@staticmethod
|
|
def get_executor() -> AsyncExecutor:
|
|
return AsyncExecutorFactory.__instance
|