Repository navigation
Plan KL P3: a refused voice key is asked once - #950
Merged
Merged
Conversation
A 401 or 403 from a cloud voice (or Gemini's API_KEY_INVALID 400) is now CloudVoiceRejection.keyNotAccepted, latched per voice and per key fingerprint (CloudVoiceKeyLatch, process-seeded hashValue, never stored). A latched voice reads as not ready and is skipped with no request, each fetch refuses a latched credential before sending, and the voice-list fetches go through fetchVoiceList, which fetches nothing for a known-bad key and latches a key the list refuses. A bad voice id (voice_not_found) or a 402 stays .refused and never latches the key. Settings shows "ElevenLabs didn't accept the key" (and the other vendors') while the latch holds; the spoken notice is said once per episode and points the OpenAI, xAI and Gemini keys at the saved model. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Plan KL P3: a cloud voice key that was refused is tried once per key, not once per spoken line.
What changes
CloudVoiceRejectiongains.keyNotAccepted: a plain 401/403, or Gemini'sAPI_KEY_INVALID400..refusedkeeps its raw value and now means the chosen voice was refused (a 402, orvoice_not_foundat any status).CloudVoiceKeyLatch(pure) stores, per voice, the refused key's process-seededhashValue. Nothing is persisted, so a changed key is tried again.cloudVoiceKeyChanged(_:).fetch…Audiorefuses a latched credential before sending, because streamed sentences in flight skip the chain.fetchVoiceList. A latched key fetches no list, and a list refused for the key latches it for speech too.voice_not_foundused to be unclassified. It now gets the existing "refused the voice request" notice.Checks
check-privacy-logging.sh: pass. gitleaks in CI's form: no leaks (a fixture value was renamed). The threeContracts/tests/*.py: pass.Owed
voice_not_foundmarker is assumed.🤖 Generated with Claude Code