Skip to content

Class swarmauri_core.transports.i_runnable.IRunnable

swarmauri_core.transports.i_runnable.IRunnable

Bases: ABC

Runnable transports can open server/client contexts and run a handler within them.

run abstractmethod

run(
    *,
    role,
    handler,
    forever=False,
    stop_event=None,
    handler_kwargs=None,
    **ctx_kwargs,
)
Source code in swarmauri_core/transports/i_runnable.py
28
29
30
31
32
33
34
35
36
37
38
@abstractmethod
def run(
    self,
    *,
    role: Role,
    handler: Handler,
    forever: bool = False,
    stop_event: Any | None = None,
    handler_kwargs: dict[str, Any] | None = None,
    **ctx_kwargs: Any,
) -> None: ...