-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
[Bug]: WebSocket Crashes with ValueError on latest_event_id
#5151
Comments
Going to gently ping @enyst as he's quite good with these things... |
This looks strange... On one hand, the error is not about Bedrock/LLM, it's from the websocket, for some reason the UI has an event without id here. Maybe @tofarr has a better idea there? I cannot replicate it, even if I use bedrock and litellm proxy. @liatweissman could you please try to add in the model name 'bedrock' though, or make sure litellm works? I mean, I'd expect the pattern of the model name here to look like "litellm_proxy/bedrock/anthropic.claude-3-5-sonnet-20241022-v2:0". Also, could you do a hard refresh of the browser, and try again? Normally even if there's a problem with the llm it should start. |
Hi @enyst
Unfortunately, I am still encountering the same Could you suggest any additional steps or debugging options I could try? Also, is there any more information you need from my side to help replicate this issue? Let me know how I can assist further in diagnosing or resolving this. |
Thank you. Can you please try to run |
I already tried running |
I saw this when debugging #5056 . The issue is that some events use an ID which is not an integer: If the last event the frontend received before init was one of these events, you get that error. I mitigate the issue by checking in ws-client-provider.tsx:
TBH - I think in the long term these events should be refactored - |
Oh, that can explain it. Except if you delete everything and incognito mode... @liatweissman Considering the above, could you please try to clean out the browser's local storage? Then maybe also, make a new project, or at least change the settings and save, to force a new session. |
Is there an existing issue for the same bug?
Describe the bug and reproduction steps
Description:
I'm encountering a critical issue while integrating OpenHands with LiteLLM Proxy to access Amazon Bedrock. The WebSocket crashes repeatedly due to a
ValueError
when OpenHands attempts to process the query parameterlatest_event_id
. This seems to occur because the value oflatest_event_id
is'undefined'
, which cannot be converted to an integer.Steps to Reproduce:
Configure LiteLLM Proxy with the following
config.yaml
:Start the LiteLLM Proxy:
Verify that the LiteLLM Proxy works by making the following API call:
Start OpenHands using the following Docker command:
Configure OpenHands with the following in the UI:
litellm_proxy/us.anthropic.claude-3-5-sonnet-20241022-v2:0
http://0.0.0.0:4000
sk-xxxxxxxx
Start a conversation in OpenHands.
Observed Behavior:
OpenHands enters an infinite loop, throwing the following error repeatedly:
Environment Details:
0.14
1.52.10
MacOs
us-east-1
OpenHands Installation
Docker command in README
OpenHands Version
0.14
Operating System
MacOS
Logs, Errors, Screenshots, and Additional Context
No response
The text was updated successfully, but these errors were encountered: