Skip to content

Remove browser_use logging monkey-patch once fixed upstream (deadline: v2.0.0) #4072

Description

@VascoSch92

Remove the browser_use logging monkey-patch once fixed upstream

We carry a workaround in
openhands-tools/openhands/tools/browser_use/logging_fix.py
because the browser_use server reconfigures logging for all loggers on
import — calling logging.basicConfig(), logging.disable() and
_ensure_all_loggers_use_stderr() during import/init — which clobbers the agent
server's own logging configuration. There is currently no opt-out env var, so we
monkey-patch logging around the import.

Upstream status

  • Our patch, browser-use PR
    #3717, was closed
    without merge
    .
  • As of browser_use 0.13.3 the problematic behavior persists.

What to do here

  • Monitor browser_use for a release that stops reconfiguring logging on
    import (or adds an opt-out).
  • Once it does, delete logging_fix.py, switch the call sites back to a
    direct from browser_use.mcp import server import, and drop the
    warn_cleanup(...) marker.

Deadline

The warn_cleanup cleanup deadline was pushed from 1.35.0 to 2.0.0 in
#4071 (the 1.35.0 deadline was blocking the v1.35.0 release while the upstream
fix is still pending). The Verify deprecation removals CI check will fail again
once the project version reaches 2.0.0, so this should be resolved before then.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions