Skip to content

[Bug]: Browser doesn't start on mac, errors in initialization with logs attached #8395

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

Open
openhands-agent opened this issue May 9, 2025 · 1 comment · May be fixed by #8397
Open

[Bug]: Browser doesn't start on mac, errors in initialization with logs attached #8395

openhands-agent opened this issue May 9, 2025 · 1 comment · May be fixed by #8397

Comments

@openhands-agent
Copy link
Contributor

openhands-agent commented May 9, 2025

Describe the bug and reproduction steps
This issue occurs when attempting to use OpenHands on a mac machine (Intel CPU). Despite having Docker configured correctly and switching between different LLMs (Claude, OpenAI, and Deepseek), the browser initialization fails with errors. The error appears immediately after connecting the codebase and attempting first interactions in the runtime setup. Full logs included below for detailed context.

Potential solutions

Look carefully at the order in which the processes or threads happen or could happen in browser_env.py. Is it possible that on some platforms they happen in a different, wrong order?

Logs, Errors, Screenshots, and Additional Context
Logs:

2025-05-09 10:32:48.855 | 14:32:48 - openhands:ERROR: browser_env.py:216 - Browser process did not terminate, forcefully terminating...  
2025-05-09 10:32:49.888 | 14:32:49 - openhands:ERROR: browser_env.py:65 - Failed to start browser process: handle is closed  
2025-05-09 10:32:49.889 | 14:32:49 - openhands:ERROR: action_execution_server.py:207 - Failed to initialize browser: handle is closed  
2025-05-09 10:32:49.936 | ERROR:    Traceback (most recent call last):  
2025-05-09 10:32:49.936 |   File "/openhands/poetry/openhands-ai-5O4_aCHf-py3.12/lib/python3.12/site-packages/starlette/routing.py", line 692, in lifespan  
2025-05-09 10:32:49.936 |     async with self.lifespan_context(app) as maybe_state:  
2025-05-09 10:32:49.936 |                ^^^^^^^^^^^^^^^^^^^^^^^^^^  
2025-05-09 10:32:49.936 |   File "/openhands/micromamba/envs/openhands/lib/python3.12/contextlib.py", line 210, in __aenter__  
2025-05-09 10:32:49.936 |     return await anext(self.gen)  
2025-05-09 10:32:49.936 |            ^^^^^^^^^^^^^^^^^^^^^  
2025-05-09 10:32:49.936 |   File "/openhands/code/openhands/runtime/action_execution_server.py", line 598, in lifespan  
2025-05-09 10:32:49.936 |     await client.ainit()  
2025-05-09 10:32:49.936 |   File "/openhands/code/openhands/runtime/action_execution_server.py", line 250, in ainit  
2025-05-09 10:32:49.936 |     await wait_all(  
2025-05-09 10:32:49.936 |   File "/openhands/code/openhands/utils/async_utils.py", line 81, in wait_all  
2025-05-09 10:32:49.936 |     raise asyncio.TimeoutError()  
2025-05-09 10:32:49.936 | TimeoutError  
2025-05-09 10:32:49.936 |   
2025-05-09 10:32:49.936 | ERROR:    Application startup failed. Exiting.  

Embedding the screenshots below:

  • Screenshot
  • Image

Issue Created By: Engel Nyst on Slack
Link to Slack Thread: https://openhands-ai.slack.com/archives/C06U8UTKSAD/p1746803925095559?thread_ts=1746803925.095559&cid=C06U8UTKSAD

@openhands-agent
Copy link
Contributor Author

OpenHands started fixing the issue! You can monitor the progress here.

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