-
Notifications
You must be signed in to change notification settings - Fork 20
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
Infinite loop in rare conditions #46
Comments
Maybe it's caused by the fact that I have reconnects deactivated? |
I'm sorry you are experiencing this issue! In both the event source library, and in the example you provided, there are several bits of logging information which might help us uncover some more insight into when this is happening. Can you please provide some sample logging output when this issue occurs? |
No logging at all (no HERE, no UNEXPECTED). Which is mind boggling to me :/ How can I activate the lib debug logging? |
We use the |
Will do that and report, hopefully stumbling on it again quickly |
(Depends a lot on health state of OpenAI API 😅) |
Hi @spolu, just checking in, were you able to gather any logging for this issue? |
The issue vanished by adding ReconnectOptions: https://github.com/dust-tt/dust/blob/main/core/src/providers/openai.rs#L241-L246 That does not resolve the whole problem. But at least that's an interesting hint. |
Closing out of inactivty |
Here's a piece of code that uses event-source and leads in rare cases to an infinite loop:
https://github.com/dust-tt/dust/blob/fbced883d7e62d8c69624c5d19e48dbe9d8e9708/core/src/providers/openai.rs#L189-L332
I was able to profile the program and got the following flamegraph. Looks like it's looping inside of eventsource-client?
The text was updated successfully, but these errors were encountered: