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

[Bug]: UI neverending startup #5578

Open
1 task done
manni07 opened this issue Dec 13, 2024 · 7 comments
Open
1 task done

[Bug]: UI neverending startup #5578

manni07 opened this issue Dec 13, 2024 · 7 comments
Labels
severity:medium Affecting multiple users Stale Inactive for 30 days troubleshooting/help User requires help

Comments

@manni07
Copy link

manni07 commented Dec 13, 2024

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Describe the bug and reproduction steps

I install the actual prepared container. Everything works fine. Then I access the docker container (ubuntu).
The UI Page of OpenHands appears. On the bottom I see the red 'sign' that it is starting up. This never ends.
In case I write sth in the chat field it is not sent. Not log output.

Then I tried downloading an building from source. Also does not work. There are access issues within the docker container.

OpenHands Installation

Docker command in README

OpenHands Version

latest

Operating System

Linux

Logs, Errors, Screenshots, and Additional Context

no log output

@manni07 manni07 added the bug Something isn't working label Dec 13, 2024
@mamoodi
Copy link
Collaborator

mamoodi commented Dec 13, 2024

Assuming you are running the docker command from the README, in your terminal you should be getting some output. Are you able to attach the output you get in your terminal when the UI is stuck in "Starting Up..." please?

@manni07
Copy link
Author

manni07 commented Dec 14, 2024

This is what I get. I try with two different API keys, anthropic and openai.

`
Running OpenHands as root
INFO: Started server process [10]
INFO: Waiting for application startup.
INFO: Application startup complete.
INFO: Uvicorn running on http://0.0.0.0:3000 (Press CTRL+C to quit)
INFO: 172.17.0.1:47672 - "GET / HTTP/1.1" 200 OK
INFO: 172.17.0.1:47672 - "GET /assets/root-BmIsJAWt.css HTTP/1.1" 200 OK
INFO: 172.17.0.1:47676 - "GET /assets/manifest-569d53d8.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47688 - "GET /assets/use-config-CUlxI4fa.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47680 - "GET /assets/entry.client-DE16fGdD.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47682 - "GET /assets/chunk-7R3XDUXW-DSKRCawN.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47694 - "GET /assets/auth-context-DKm1Ywm8.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47676 - "GET /assets/index-CdvD0Qri.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47680 - "GET /assets/store-BLUpY75q.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47688 - "GET /assets/index-DfJCZdWx.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47672 - "GET /assets/initial-query-slice-CSE8L-ER.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47682 - "GET /assets/react-redux-BJt37jkE.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47694 - "GET /assets/infiniteQueryBehavior-BtqYQEvL.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47680 - "GET /assets/user-prefs-context-BSq2RHVU.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47688 - "GET /assets/i18nInstance-CnyO1Rew.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47676 - "GET /assets/browser-slice-Bc4gbFxe.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47682 - "GET /assets/with-props-CNz_g3pE.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47694 - "GET /assets/root-Bn2pI1pR.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47694 - "GET /locales/en/translation.json HTTP/1.1" 200 OK
INFO: 172.17.0.1:47682 - "GET /assets/route-iUDXCabU.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47694 - "GET /assets/route-CfHRRXE0.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47694 - "GET /config.json HTTP/1.1" 200 OK
INFO: 172.17.0.1:47682 - "GET /assets/chunk-VHPYXGWP-Os8VWTuS.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47680 - "GET /assets/chunk-DBLREEYE-C6ESCLQg.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47676 - "GET /assets/github-logo-D-qYZc4s.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47688 - "GET /assets/upload-image-input-BtS1vm_A.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47672 - "GET /assets/declaration-CYuQKrYC.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47694 - "GET /assets/arrow-send-CBP7uKxj.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47676 - "GET /assets/use-end-session-C8LTncmr.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47676 - "GET /config.json HTTP/1.1" 200 OK
INFO: 172.17.0.1:47672 - "GET /assets/route-D0omDORh.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47676 - "GET /assets/route-CGF25X90.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47672 - "GET /assets/toast-0V3BueR7.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47694 - "GET /assets/scroll-to-bottom-button-BH1shGJY.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47680 - "GET /assets/iconBase-EdNx__1r.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47688 - "GET /assets/index-D3LVosJ5.js HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47676 - "GET /assets/route-BTx6gfxv.js HTTP/1.1" 200 OK
INFO: 172.17.0.1:47672 - "GET /assets/terminal-CFbL2ovg.css HTTP/1.1" 304 Not Modified
INFO: 172.17.0.1:47676 - "GET /assets/terminal-CCrhS_r9.js HTTP/1.1" 200 OK
INFO: ('172.17.0.1', 47710) - "WebSocket /socket.io/?EIO=4&transport=websocket" [accepted]
08:01:57 - openhands:INFO: listen_socket.py:22 - sio:connect: x7oqNk_JyKYgKPKLAAAB
08:01:57 - openhands:ERROR: auth.py:27 - Invalid token
08:01:57 - openhands:INFO: listen_socket.py:96 - sio:disconnect:x7oqNk_JyKYgKPKLAAAB
08:01:57 - openhands:WARNING: manager.py:266 - disconnect_from_uninitialized_session:x7oqNk_JyKYgKPKLAAAB
INFO: 172.17.0.1:47676 - "GET /config.json HTTP/1.1" 200 OK
INFO: ('172.17.0.1', 53416) - "WebSocket /socket.io/?EIO=4&transport=websocket" [accepted]
INFO: 172.17.0.1:53410 - "GET /config.json HTTP/1.1" 200 OK
08:02:17 - openhands:INFO: listen_socket.py:22 - sio:connect: OjhO8yDtH_WlXdjMAAAD
08:02:17 - openhands:INFO: listen_socket.py:64 - New session: OjhO8yDtH_WlXdjMAAAD
08:02:17 - openhands:INFO: manager.py:220 - start_new_local_session:OjhO8yDtH_WlXdjMAAAD
08:02:17 - openhands:INFO: shutdown_listener.py:37 - _register_signal_handlers
08:02:17 - openhands:INFO: shutdown_listener.py:41 - _register_signal_handlers:main_thread
08:02:17 - openhands:INFO: eventstream_runtime.py:234 - [runtime OjhO8yDtH_WlXdjMAAAD] Starting runtime with image: docker.all-hands.dev/all-hands-ai/runtime:0.15-nikolaik
08:02:18 - openhands:INFO: eventstream_runtime.py:238 - [runtime OjhO8yDtH_WlXdjMAAAD] Container started: openhands-runtime-OjhO8yDtH_WlXdjMAAAD. VSCode URL: None
08:02:18 - openhands:INFO: eventstream_runtime.py:246 - [runtime OjhO8yDtH_WlXdjMAAAD] Waiting for client to become ready at http://host.docker.internal:39622...
RROR:asyncio:Future exception was never retrieved
future: <Future finished exception=ConnectTimeout(MaxRetryError("HTTPConnectionPool(host='host.docker.internal', port=39622): Max retries exceeded with url: /alive (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7152838321b0>, 'Connection to host.docker.internal timed out. (connect timeout=5)'))"))>
Traceback (most recent call last):
File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 199, in _new_conn
sock = connection.create_connection(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/urllib3/util/connection.py", line 85, in create_connection
raise err
File "/app/.venv/lib/python3.12/site-packages/urllib3/util/connection.py", line 73, in create_connection
sock.connect(sa)
TimeoutError: timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/app/.venv/lib/python3.12/site-packages/urllib3/connectionpool.py", line 789, in urlopen
response = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/urllib3/connectionpool.py", line 495, in _make_request
conn.request(
File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 441, in request
self.endheaders()
File "/usr/local/lib/python3.12/http/client.py", line 1331, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/usr/local/lib/python3.12/http/client.py", line 1091, in _send_output
self.send(msg)
File "/usr/local/lib/python3.12/http/client.py", line 1035, in send
self.connect()
File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 279, in connect
self.sock = self._new_conn()
^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 208, in _new_conn
raise ConnectTimeoutError(
urllib3.exceptions.ConnectTimeoutError: (<urllib3.connection.HTTPConnection object at 0x7152838321b0>, 'Connection to host.docker.internal timed out. (connect timeout=5)')

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/app/.venv/lib/python3.12/site-packages/requests/adapters.py", line 667, in send
resp = conn.urlopen(
^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/urllib3/connectionpool.py", line 843, in urlopen
retries = retries.increment(
^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/urllib3/util/retry.py", line 519, in increment
raise MaxRetryError(_pool, url, reason) from reason # type: ignore[arg-type]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='host.docker.internal', port=39622): Max retries exceeded with url: /alive (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7152838321b0>, 'Connection to host.docker.internal timed out. (connect timeout=5)'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/openhands/server/session/agent_session.py", line 97, in _start_thread
asyncio.run(self._start(*args), debug=True)
File "/usr/local/lib/python3.12/asyncio/runners.py", line 194, in run
return runner.run(main)
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/asyncio/runners.py", line 118, in run
return self._loop.run_until_complete(task)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/asyncio/base_events.py", line 687, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "/app/openhands/server/session/agent_session.py", line 115, in _start
await self._create_runtime(
File "/app/openhands/server/session/agent_session.py", line 203, in _create_runtime
await self.runtime.connect()
File "/app/openhands/runtime/impl/eventstream/eventstream_runtime.py", line 249, in connect
await call_sync_from_async(self._wait_until_alive)
File "/app/openhands/utils/async_utils.py", line 18, in call_sync_from_async
result = await coro
^^^^^^^^^^
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/openhands/utils/async_utils.py", line 17, in
coro = loop.run_in_executor(None, lambda: fn(*args, **kwargs))
^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 336, in wrapped_f
return copy(f, *args, **kw)
^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 475, in call
do = self.iter(retry_state=retry_state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 376, in iter
result = action(retry_state)
^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 418, in exc_check
raise retry_exc.reraise()
^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 185, in reraise
raise self.last_attempt.result()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/concurrent/futures/_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/concurrent/futures/_base.py", line 401, in __get_result
raise self._exception
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 478, in call
result = fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "/app/openhands/runtime/impl/eventstream/eventstream_runtime.py", line 452, in _wait_until_alive
with send_request(
^^^^^^^^^^^^^
File "/app/openhands/runtime/utils/request.py", line 27, in send_request
response = session.request(method, url, timeout=timeout, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/requests/sessions.py", line 589, in request
resp = self.send(prep, **send_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/requests/sessions.py", line 703, in send
r = adapter.send(request, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/requests/adapters.py", line 688, in send
raise ConnectTimeout(e, request=request)
requests.exceptions.ConnectTimeout: HTTPConnectionPool(host='host.docker.internal', port=39622): Max retries exceeded with url: /alive (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7152838321b0>, 'Connection to host.docker.internal timed out. (connect timeout=5)'))

`

OpenHands_001

@mamoodi
Copy link
Collaborator

mamoodi commented Dec 15, 2024

I think there may be an issue with Linux. Seeing quite a few issues with running OpenHands from users using Linux.
Hoping someone with Linux can take a look.

@mamoodi mamoodi added the severity:medium Affecting multiple users label Dec 31, 2024
@mamoodi mamoodi added the troubleshooting/help User requires help label Jan 22, 2025
@mamoodi
Copy link
Collaborator

mamoodi commented Jan 22, 2025

Can you try with version 0.21.0 and see if you are still running into this?
I tried with Ubuntu 22.04 and seemed to go well. I just installed Docker Desktop. Documented here: https://docs.all-hands.dev/modules/usage/installation

@mamoodi mamoodi removed the bug Something isn't working label Jan 22, 2025
@manni07
Copy link
Author

manni07 commented Jan 22, 2025

Thanks a lot!
I will try in the next few days

@manni07
Copy link
Author

manni07 commented Jan 24, 2025

Can you try with version 0.21.0 and see if you are still running into this? I tried with Ubuntu 22.04 and seemed to go well. I just installed Docker Desktop. Documented here: https://docs.all-hands.dev/modules/usage/installation

I checked it. SOmehow it does not really work. I again have an error message. And nothing happens in the Openhands window.

6:14:03 - openhands:INFO: manage_conversations.py:107 - Finished initializing conversation d2d9f6ba807a48e8b862d3b70e7344c3
16:14:03 - openhands:INFO: codeact_agent.py:94 - Function calling not enabled for model deepseek/deepseek-coder. Mocking function calling via prompting.
INFO:     172.17.0.1:56362 - "POST /api/conversations HTTP/1.1" 200 OK
INFO:     172.17.0.1:56362 - "GET /assets/route-D-c2MHNv.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56378 - "GET /assets/route-DtN2f0sA.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56362 - "GET /assets/conversation-context-Bo7Skr1P.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56378 - "GET /assets/route-CFiVqQuA.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56392 - "GET /assets/toast-BA2YT_td.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56404 - "GET /assets/highlight-DqYG5fwR.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56418 - "GET /assets/scroll-to-bottom-button-Ce9zlzEN.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56430 - "GET /assets/use-active-host-BZwagcyy.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56362 - "GET /assets/index-D-v3drXU.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56362 - "GET /assets/terminal-CFbL2ovg.css HTTP/1.1" 200 OK
INFO:     172.17.0.1:56392 - "GET /assets/terminal-uK8SunxW.js HTTP/1.1" 200 OK
INFO:     172.17.0.1:56392 - "GET /api/conversations/d2d9f6ba807a48e8b862d3b70e7344c3 HTTP/1.1" 200 OK
INFO:     ('172.17.0.1', 56438) - "WebSocket /socket.io/?latest_event_id=-1&conversation_id=d2d9f6ba807a48e8b862d3b70e7344c3&EIO=4&transport=websocket" [accepted]
INFO:     172.17.0.1:56362 - "GET /api/settings HTTP/1.1" 200 OK
16:14:03 - openhands:INFO: listen_socket.py:24 - sio:connect: qQ1ogy8QRJyC-bfTAAAB
16:14:03 - openhands:INFO: manager.py:225 - join_conversation:d2d9f6ba807a48e8b862d3b70e7344c3:qQ1ogy8QRJyC-bfTAAAB
16:14:03 - openhands:INFO: manager.py:478 - _get_event_stream:d2d9f6ba807a48e8b862d3b70e7344c3
16:14:03 - openhands:INFO: manager.py:481 - found_local_agent_loop:d2d9f6ba807a48e8b862d3b70e7344c3
16:14:04 - openhands:INFO: docker_runtime.py:142 - [runtime d2d9f6ba807a48e8b862d3b70e7344c3] Starting runtime with image: docker.all-hands.dev/all-hands-ai/runtime:0.21-nikolaik
16:14:04 - openhands:INFO: docker_runtime.py:146 - [runtime d2d9f6ba807a48e8b862d3b70e7344c3] Container started: openhands-runtime-d2d9f6ba807a48e8b862d3b70e7344c3. VSCode URL: None
16:14:04 - openhands:INFO: docker_runtime.py:157 - [runtime d2d9f6ba807a48e8b862d3b70e7344c3] Waiting for client to become ready at http://host.docker.internal:32785...
16:16:08 - openhands:ERROR: session.py:128 - Error creating agent_session: HTTPConnectionPool(host='host.docker.internal', port=32785): Max retries exceeded with url: /alive (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7e55006d5370>, 'Connection to host.docker.internal timed out. (connect timeout=5)'))
Traceback (most recent call last):
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 198, in _new_conn
    sock = connection.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/urllib3/util/connection.py", line 85, in create_connection
    raise err
  File "/app/.venv/lib/python3.12/site-packages/urllib3/util/connection.py", line 73, in create_connection
    sock.connect(sa)
TimeoutError: timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connectionpool.py", line 787, in urlopen
    response = self._make_request(
               ^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connectionpool.py", line 493, in _make_request
    conn.request(
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 445, in request
    self.endheaders()
  File "/usr/local/lib/python3.12/http/client.py", line 1331, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.12/http/client.py", line 1091, in _send_output
    self.send(msg)
  File "/usr/local/lib/python3.12/http/client.py", line 1035, in send
    self.connect()
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 276, in connect
    self.sock = self._new_conn()
                ^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connection.py", line 207, in _new_conn
    raise ConnectTimeoutError(
urllib3.exceptions.ConnectTimeoutError: (<urllib3.connection.HTTPConnection object at 0x7e55006d5370>, 'Connection to host.docker.internal timed out. (connect timeout=5)')

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/app/.venv/lib/python3.12/site-packages/requests/adapters.py", line 667, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/urllib3/connectionpool.py", line 841, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/urllib3/util/retry.py", line 519, in increment
    raise MaxRetryError(_pool, url, reason) from reason  # type: ignore[arg-type]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='host.docker.internal', port=32785): Max retries exceeded with url: /alive (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7e55006d5370>, 'Connection to host.docker.internal timed out. (connect timeout=5)'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/app/openhands/server/session/session.py", line 115, in initialize_agent
    await self.agent_session.start(
  File "/app/openhands/server/session/agent_session.py", line 98, in start
    await self._create_runtime(
  File "/app/openhands/server/session/agent_session.py", line 212, in _create_runtime
    await self.runtime.connect()
  File "/app/openhands/runtime/impl/docker/docker_runtime.py", line 160, in connect
    await call_sync_from_async(self._wait_until_alive)
  File "/app/openhands/utils/async_utils.py", line 18, in call_sync_from_async
    result = await coro
             ^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/openhands/utils/async_utils.py", line 17, in <lambda>
    coro = loop.run_in_executor(None, lambda: fn(*args, **kwargs))
                                              ^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 336, in wrapped_f
    return copy(f, *args, **kw)
           ^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 475, in __call__
    do = self.iter(retry_state=retry_state)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 376, in iter
    result = action(retry_state)
             ^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 418, in exc_check
    raise retry_exc.reraise()
          ^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 185, in reraise
    raise self.last_attempt.result()
          ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/_base.py", line 449, in result
    return self.__get_result()
           ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/_base.py", line 401, in __get_result
    raise self._exception
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 478, in __call__
    result = fn(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^
  File "/app/openhands/runtime/impl/docker/docker_runtime.py", line 351, in _wait_until_alive
    self.check_if_alive()
  File "/app/openhands/runtime/impl/action_execution/action_execution_client.py", line 101, in check_if_alive
    with self._send_action_server_request(
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/openhands/runtime/impl/action_execution/action_execution_client.py", line 98, in _send_action_server_request
    return send_request(self.session, method, url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 336, in wrapped_f
    return copy(f, *args, **kw)
           ^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 475, in __call__
    do = self.iter(retry_state=retry_state)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 376, in iter
    result = action(retry_state)
             ^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.12/site-packages/tenacity/__init__.py", line 398, in <lambda>
    self._add_action_func(lambda rs: rs.outcome.result())
                                     ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/_base.py", line 449, in result
    return self.__get_result()
           ^^^^^^^^^^^^^^^^^^^

File "/usr/local/lib/python3.12/concurrent/futures/_base.py", line 401, in __get_result
raise self._exception
File "/app/.venv/lib/python3.12/site-packages/tenacity/init.py", line 478, in call
result = fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "/app/openhands/runtime/utils/request.py", line 44, in send_request
response = session.request(method, url, timeout=timeout, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/requests/sessions.py", line 589, in request
resp = self.send(prep, **send_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/requests/sessions.py", line 703, in send
r = adapter.send(request, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/.venv/lib/python3.12/site-packages/requests/adapters.py", line 688, in send
raise ConnectTimeout(e, request=request)
requests.exceptions.ConnectTimeout: HTTPConnectionPool(host='host.docker.internal', port=32785): Max retries exceeded with url: /alive (Caused by ConnectTimeoutError(<urllib3.connection.HTTPConnection object at 0x7e55006d5370>, 'Connection to host.docker.internal timed out. (connect timeout=5)'))

Copy link
Contributor

This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the Stale Inactive for 30 days label Feb 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
severity:medium Affecting multiple users Stale Inactive for 30 days troubleshooting/help User requires help
Projects
None yet
Development

No branches or pull requests

2 participants