Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid voice even when in the LIST #6

Open
4 tasks done
blackslashcreative opened this issue Feb 28, 2024 · 0 comments
Open
4 tasks done

Invalid voice even when in the LIST #6

blackslashcreative opened this issue Feb 28, 2024 · 0 comments

Comments

@blackslashcreative
Copy link

Description

When I LIST the voices I see the voice I want to use ("azure_en-US-EmmaMultilingualNeural"), but if I try to use it I get an error.

Reproduction steps

`import uberduck

client = uberduck.UberDuck(getenv('UBERDUCK_API_KEY'), getenv('UBERDUCK_SECRET_KEY'))
voices = uberduck.get_voices(return_only_names = True)

speech = "testing"
voice = "azure_en-US-EmmaMultilingualNeural"

if voice == 'list':
print('Available voices:\n')
for voice in sorted(voices): # sorting the voice list in alphabetical order
print(voice)
exit()

#if voice not in voices:

print('Invalid voice')

exit()

client.speak(speech, voice, play_sound = True)
print('Spoke voice')`

#if voice not in voices:

print('Invalid voice')

exit()

client.speak(speech, voice, play_sound = True)
print('Spoke voice')

Expected result

If you use the simple names in the list like "preacher" it speaks. I would expect that I could also use the name that I want to use from the list, and it would speak.

Actual result

In reality, I get this error uberduck.classes.InvalidVoice: Invalid voice Traceback:

Traceback (most recent call last): File "/Users/oddflower/poppy-ai/duck.py", line 27, in <module> client.speak(speech, voice, play_sound = True) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/uberduck/main.py", line 174, in speak _handle_exceptions(response.status_code, json, voice) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/uberduck/main.py", line 41, in _handle_exceptions raise InvalidVoice(voice) uberduck.classes.InvalidVoice: Invalid voice: azure_en-US-EmmaMultilingualNeural.

Uberduck version

0.0.5

Operating system

MacOS 14.2.1

Checklist

  • - This bug was found on the latest version of Uberduck
  • - You have checked that there is no issue already mentioning this bug, open or closed
  • - Full details of the bug have been provided/shown, including full tracebacks in case of exceptions
  • - All API keys and API secrets have been hidden/omitted from any screenshots or code, if any

Additional context

Thank you in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant