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

wit.speech() responds 400 bad request for no text noise #113

Closed
damianchoc opened this issue Jul 9, 2018 · 2 comments
Closed

wit.speech() responds 400 bad request for no text noise #113

damianchoc opened this issue Jul 9, 2018 · 2 comments
Labels

Comments

@damianchoc
Copy link

Hi. When i use wit.speech() with *.wav where i didn't say anything, it responds
wit.wit.WitError: Wit responden with status: 400 (Bad Request) and program stops..
what can i do with that?

@blandinw
Copy link
Contributor

Hi :-) This is the intended behavior. You can try to catch the exception to avoid stopping the program. See how to use try/except in Python. You can also see a more detailed error message with something similar to:

try:
  # call to Wit
except Exception as e:
  print(e)

Hope this helps!

@damianchoc
Copy link
Author

@blandinw oh ok, it works :)
thanks for the answer!

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

No branches or pull requests

2 participants