From da0975a4e04a0c2721042ebef34ec29c8d84c8bf Mon Sep 17 00:00:00 2001 From: mattie ruth backman Date: Wed, 4 Mar 2026 16:35:30 -0500 Subject: [PATCH] Fix forward reference --- src/pipecat/processors/frameworks/rtvi/models_v0.py | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/src/pipecat/processors/frameworks/rtvi/models_v0.py b/src/pipecat/processors/frameworks/rtvi/models_v0.py index e1d0c8aa4..af2c54300 100644 --- a/src/pipecat/processors/frameworks/rtvi/models_v0.py +++ b/src/pipecat/processors/frameworks/rtvi/models_v0.py @@ -12,7 +12,6 @@ server messages instead. """ from typing import ( - TYPE_CHECKING, Any, Awaitable, Callable, @@ -27,9 +26,6 @@ from pydantic import BaseModel, Field, PrivateAttr import pipecat.processors.frameworks.rtvi.models_v1 as RTVI -if TYPE_CHECKING: - from pipecat.processors.frameworks.rtvi.processor import RTVIProcessor - ActionResult = Union[bool, int, float, str, list, dict] @@ -46,9 +42,7 @@ class RTVIServiceOption(BaseModel): name: str type: Literal["bool", "number", "string", "array", "object"] - handler: Callable[["RTVIProcessor", str, "RTVIServiceOptionConfig"], Awaitable[None]] = Field( - exclude=True - ) + handler: Callable[..., Awaitable[None]] = Field(exclude=True) class RTVIService(BaseModel): @@ -117,9 +111,7 @@ class RTVIAction(BaseModel): action: str arguments: List[RTVIActionArgument] = Field(default_factory=list) result: Literal["bool", "number", "string", "array", "object"] - handler: Callable[["RTVIProcessor", str, Dict[str, Any]], Awaitable[ActionResult]] = Field( - exclude=True - ) + handler: Callable[..., Awaitable[ActionResult]] = Field(exclude=True) _arguments_dict: Dict[str, RTVIActionArgument] = PrivateAttr(default={}) def model_post_init(self, __context: Any) -> None: