Skip to content

Revert "让 SDK 日志时间在 UTC 容器中稳定显示东八区"#125

Merged
OhYee merged 1 commit into
mainfrom
revert-123-fix/83336550-utc8-logger
Jun 18, 2026
Merged

Revert "让 SDK 日志时间在 UTC 容器中稳定显示东八区"#125
OhYee merged 1 commit into
mainfrom
revert-123-fix/83336550-utc8-logger

Conversation

@OhYee

@OhYee OhYee commented Jun 18, 2026

Copy link
Copy Markdown
Member

Reverts #123

Copilot AI review requested due to automatic review settings June 18, 2026 06:48

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR reverts the logging timestamp behavior introduced in PR #123, returning agentrun.utils.log.CustomFormatter to Python’s default logging.Formatter time conversion behavior (i.e., %(asctime)s reflects the process/local timezone rather than a forced UTC+8 offset).

Changes:

  • Removed the UTC+8 converter override (_utc8_converter) so %(asctime)s no longer forces UTC+8.
  • Removed the unit tests that validated UTC+8 timestamp formatting for the SDK logger formatter.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
agentrun/utils/log.py Reverts formatter construction to plain logging.Formatter instances (no UTC+8 converter override).
tests/unittests/test_log.py Deletes the unit tests that asserted the UTC+8 logging behavior introduced in PR #123.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread agentrun/utils/log.py
Comment on lines +51 to 55
self._formatters[level] = logging.Formatter(fmt)
self._default = logging.Formatter(
"\n%(levelname)s [%(name)s] %(asctime)s"
" %(pathname)s:%(lineno)s\n%(message)s"
)
@OhYee OhYee merged commit 008df05 into main Jun 18, 2026
3 of 4 checks passed
@OhYee OhYee deleted the revert-123-fix/83336550-utc8-logger branch June 18, 2026 06:51
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.

2 participants