-
Notifications
You must be signed in to change notification settings - Fork 80
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
Poe: handle "Response timed out" exception #14
Comments
I think it tends to be a problem with the poe.com website itself. Sometimes, even when I manually submit the question in the browser, the answer is not generated. |
Sure it is poe.com problem. |
I tried to reproduce this and caused the bot to enter a 'did not respond' loop, but I was only able to make it generate again by clearing the context and resending the message (kinda awkward). I suppose you could implement a try-except for that. |
Hello, An issue I've been having is the POE backend not responding, but the api not catching the timeout and instead halting the program indefinitely. Do you think you might know what is causing this error? More details can be provided if needed. |
If your program is just halting but not in an inf loop then this may help: for chunk in client.send_message(bot, message, timeout=2):
print(chunk['response'], end='', flush=True) |
Do you mean something like this? def main():
try:
Poe.chat_with_bot(token)
except RuntimeError:
main()
main() This seems not to be a good solution, as then I must manually re-choose bot and thread (do I ever remember those?). |
As I've mentioned above, I tried to reproduce this error, but my attempts to cancel and resend the message still results in "did not respond" loop. Currently, I could only clear the context and start over. Maybe this error has something to do with poe.com itself |
Even if you are doing that on poe.com?
I understand. I this case instead of exception I would prefer to see such message:
|
Yeah. I think I will let the user to choose whether or not to clear the context if encounter this error. For now, if I can find another solution, I will implement it later |
Thank you! |
This is temp fixed in the new version. The stability is improved but there may be some unexpected errors in the future. |
At the moment this exception is thrown:
I suppose Poe should handle this, as it is pretty common case.
The text was updated successfully, but these errors were encountered: