Menu

A Failed API Call Saved as NULL: Show It and Add a Retry
📰

A Failed API Call Saved as NULL: Show It and Add a Retry

DEV Community: flask·Yunus Emre Güzel·1 day ago
#dDZ4YOuc
#devtoflask#devto#dev#voice#voice_id
Long article (1997 words) — no AI summary yet.
Reading 0:00
15s threshold

My app IboChat is an AI voice chat. You make a character, record a voice sample, and the app clones that voice for the character. Then one day a character I created spoke in a plain default voice. No crash. No error on screen. Here's the bug, why it hid so well, and the three small changes that fixed it.

What Went Wrong: A Failed Step Saved as NULL

A separate voice service does the cloning, and it wasn't always running when someone created a character. The commit that fixed this is titled Surface failed voice clones + wire re-clone recovery into chat (was silent voice_id=None). The title says it all. Here's the part of the create endpoint that decides what happens when the clone fails:

voice_id = None if audio_file and audio_file . filename : normalized_path = _normalize_voice_sample_to_wav ( audio_file ) try : if normalized_path : . . .…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.