From 45cbad5b3e2238aae51fc859bd0a23d686de917a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aleix=20Conchillo=20Flaqu=C3=A9?= Date: Fri, 17 Jan 2025 10:11:28 -0800 Subject: [PATCH] task: add HEARTBEAT_MONITOR_SECONDS --- src/pipecat/pipeline/task.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pipecat/pipeline/task.py b/src/pipecat/pipeline/task.py index 9a6d344ea..2fb13f627 100644 --- a/src/pipecat/pipeline/task.py +++ b/src/pipecat/pipeline/task.py @@ -31,6 +31,7 @@ from pipecat.processors.frame_processor import FrameDirection, FrameProcessor from pipecat.utils.utils import obj_count, obj_id HEARTBEAT_SECONDS = 1.0 +HEARTBEAT_MONITOR_SECONDS = HEARTBEAT_SECONDS * 5 class PipelineParams(BaseModel): @@ -353,7 +354,7 @@ class PipelineTask: takes for the heartbeat frame to traverse all the pipeline. """ - wait_time = HEARTBEAT_SECONDS * 5 + wait_time = HEARTBEAT_MONITOR_SECONDS while True: try: frame = await asyncio.wait_for(self._heartbeat_queue.get(), timeout=wait_time)