format
This commit is contained in:
@@ -143,9 +143,13 @@ class TavusApi:
|
||||
logger.debug(f"Fetched Tavus persona: {response}")
|
||||
try:
|
||||
transport_settings = response.get("layers", {}).get("transport", {})
|
||||
microphone_enabled = transport_settings.get("input_settings", {}).get("microphone", "")
|
||||
microphone_enabled = transport_settings.get("input_settings", {}).get(
|
||||
"microphone", ""
|
||||
)
|
||||
if microphone_enabled != "enabled":
|
||||
raise Exception("Microphone is not enabled for this persona. Please update the persona or use the persona pipecat-stream.")
|
||||
raise Exception(
|
||||
"Microphone is not enabled for this persona. Please update the persona or use the persona pipecat-stream."
|
||||
)
|
||||
except Exception as e:
|
||||
logger.error(f"Error validating persona {persona_id}: {e}")
|
||||
raise e
|
||||
|
||||
Reference in New Issue
Block a user