fix(logs): find active log file across date boundaries#42904
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1b9bf1e8d0
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Greptile SummaryThis PR fixes a real-world bug where Key issue found:
The PR also bundles a secondary feature in Confidence Score: 3/5
Last reviewed commit: 1b9bf1e |
1b9bf1e to
2ec87cc
Compare
|
Thank you for the review @chatgpt-codex-connector @greptile-apps! I've addressed both concerns:
Build passes. Let me know if there are any other concerns! |
|
Perfect! Both concerns are addressed: ✅ Configured log directory - Now correctly uses The implementation looks good. Nice work! |
|
Codex Review: Didn't find any major issues. Another round soon, please! ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |
2ec87cc to
d1af73d
Compare
|
Thank you for the review @greptile-apps! Fixed:
All tests pass. |
|
Looks great! Both fixes are solid:
The logic is clean and the guard ensures we'll never hit an undefined access. Nice work! 🎯 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d1af73d68f
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
d1af73d to
a3c7715
Compare
|
This pull request has been automatically marked as stale due to inactivity. |
|
Codex review: keeping this open for maintainer follow-up; there is still a little grit to resolve. Keep this PR open. Current main still makes Best possible solution: Keep this PR open for maintainer review. The best path is to land the narrow branch if CI remains green: export the shared rolling-log resolver, call it from What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 79159f11f695. |
a3c7715 to
ee87397
Compare
|
ProjectClownfish pushed a narrow repair to this branch so the original contributor path can stay canonical. Source PR: #42904 |
c76265d to
f6c8e1b
Compare
Fixes openclaw#42875 When gateway runs across midnight, openclaw channels logs was looking for today's log file instead of the active one. This change makes the CLI find the most recently modified log file as a fallback. (cherry picked from commit fba6b88e8644365360f82802cbe25039a091409d)
(cherry picked from commit ee87397a4323f04fdd37a2fc136de02e648a92d5)
f6c8e1b to
2da6c56
Compare
Previously, buildLogger() resolved the rolling log file path once at logger construction time. When midnight passed, all writes continued hitting the previous day's file despite the new date. Upstream openclaw#42904 introduced resolveActiveLogFile() for this. Fix: add resolveActiveLogFile() that re-derives the date-specific path every write. On date boundary detection, the transport re-initializes its file pointer. Also fix resolveLogFile() in log-tail.ts to prefer the latest-mtime rolling file regardless of the original config path. Test: new 'writes rolling logs to the current date after midnight' case.
* fix(logs): find active log file across date boundaries Fixes openclaw#42875 When gateway runs across midnight, openclaw channels logs was looking for today's log file instead of the active one. This change makes the CLI find the most recently modified log file as a fallback. (cherry picked from commit fba6b88e8644365360f82802cbe25039a091409d) * fix(channels): resolve active log file for channel logs (cherry picked from commit ee87397a4323f04fdd37a2fc136de02e648a92d5) --------- Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
* fix(logs): find active log file across date boundaries Fixes openclaw#42875 When gateway runs across midnight, openclaw channels logs was looking for today's log file instead of the active one. This change makes the CLI find the most recently modified log file as a fallback. (cherry picked from commit fba6b88e8644365360f82802cbe25039a091409d) * fix(channels): resolve active log file for channel logs (cherry picked from commit ee87397a4323f04fdd37a2fc136de02e648a92d5) --------- Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
* fix(logs): find active log file across date boundaries Fixes openclaw#42875 When gateway runs across midnight, openclaw channels logs was looking for today's log file instead of the active one. This change makes the CLI find the most recently modified log file as a fallback. (cherry picked from commit fba6b88e8644365360f82802cbe25039a091409d) * fix(channels): resolve active log file for channel logs (cherry picked from commit ee87397a4323f04fdd37a2fc136de02e648a92d5) --------- Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
* fix(logs): find active log file across date boundaries Fixes openclaw#42875 When gateway runs across midnight, openclaw channels logs was looking for today's log file instead of the active one. This change makes the CLI find the most recently modified log file as a fallback. (cherry picked from commit fba6b88e8644365360f82802cbe25039a091409d) * fix(channels): resolve active log file for channel logs (cherry picked from commit ee87397a4323f04fdd37a2fc136de02e648a92d5) --------- Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
Summary
openclaw channels logscould not find logs when gateway runs across midnightTest plan
Fixes #42875