From bcccb4cbb317a8569b714d6aa1cacaf28650d81a Mon Sep 17 00:00:00 2001 From: Mike Seese Date: Mon, 5 Jan 2026 10:20:26 -0800 Subject: [PATCH] put fallback sample_rate value in function arg --- src/pipecat/services/hathora/tts.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pipecat/services/hathora/tts.py b/src/pipecat/services/hathora/tts.py index 53458be28..1b1a4df14 100644 --- a/src/pipecat/services/hathora/tts.py +++ b/src/pipecat/services/hathora/tts.py @@ -29,7 +29,7 @@ from .utils import ConfigOption def _decode_audio_payload( audio_bytes: bytes, *, - fallback_sample_rate: int, + fallback_sample_rate: int = 24000, fallback_channels: int = 1, ) -> Tuple[bytes, int, int]: """Convert a WAV/PCM payload into raw PCM samples for TTSAudioRawFrame.""" @@ -125,7 +125,7 @@ class HathoraTTSService(TTSService): pcm_audio, sample_rate, num_channels = _decode_audio_payload( audio_data, - fallback_sample_rate=self.sample_rate or self._init_sample_rate or 24000, + fallback_sample_rate=self.sample_rate, ) frame = TTSAudioRawFrame(