Skip to content

fix: disable AgentBay SDK logging override to prevent resetting loguru config#638

Merged
yaojin3616 merged 1 commit into
mainfrom
fix/agentbay-logger-intrusion
Jun 1, 2026
Merged

fix: disable AgentBay SDK logging override to prevent resetting loguru config#638
yaojin3616 merged 1 commit into
mainfrom
fix/agentbay-logger-intrusion

Conversation

@yaojin3616
Copy link
Copy Markdown
Collaborator

Problem

The AgentBay SDK logging configuration overrides the global loguru logger setup, resetting it or causing logs to not be formatted/intercepted correctly.

Solution

  1. In app/core/logging_config.py, added _disable_agentbay_logger_override to mock/disable the AgentBayLogger.setup classmethod and set _initialized to True if agentbay._common.logger is loaded.
  2. In app/services/agentbay_client.py, imported and invoked _disable_agentbay_logger_override() and configure_logging() immediately after importing agentbay client components to make sure loguru is restored/reconfigured.

@yaojin3616 yaojin3616 merged commit 34ae4e5 into main Jun 1, 2026
1 check was pending
@yaojin3616 yaojin3616 deleted the fix/agentbay-logger-intrusion branch June 1, 2026 16:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant