Originally created by: adityaharishch
Summary
- Fix a UTC-vs-local-time bug in
session_distiller.py's _distil(): inline [HH:MM:SS] markers embedded in session_text (injected by the Rust ETL whenever on-screen content changes) are UTC by construction, but were being assigned straight into cur_time without conversion — while the session's own started_at timestamp was correctly localized via utc_to_local_hhmm. Since most thread headers in a longer session originate from these inline markers, most of distill_hour's output (and therefore activity_report's input) showed raw UTC times instead of local time. Fixed by reattaching started_at's UTC date to the marker before running it through the same utc_to_local_hhmm helper already used elsewhere in the file.
- Rewrite
activity_report.py's TLDR instruction to stay at a high level, understandable by anyone (PM, teammate) rather than deep technical detail — Core Tasks keeps the existing technical depth.
- Switch report voice from third-party narration ("the developer did X") to subject-less, verb-led phrasing ("Focused on…", "Fixed…", "Investigated…").
- Bump
services/pyproject.toml version (1.69.1 → 1.69.2) so this change actually ships on the next runtime publish, per the repo's runtime-versioning convention.
Test plan
- [x] Manually verified via a fork agent: fed a UTC inline marker
[03:46:12] through _distil() — output correctly renders as local time (09:16 in IST, UTC+5:30) instead of raw UTC.
- [x] Confirmed
activity_report.py/routes/activity.py has no independent timestamp parsing — it forwards distill_hour's text verbatim as the prompt body, so no duplicate bug there.
- [x] No existing pytest coverage for
session_distiller.py (confirmed via repo-wide search); none added per scope.
- [x]
cargo fmt/clippy/test, UI build/tests, and security audit all passed on push (pre-push hook).
Summary by CodeRabbit
- New Features
- Improved activity report formatting for clearer, higher-level summaries with less technical jargon.
- Bug Fixes
- Fixed how time markers are interpreted in session summaries, making timelines more accurate.
- Chores
- Updated the app version to 1.69.2.
Originally posted by: coderabbitai[bot]
✨ Finishing Touches
🧪 Generate unit tests (beta)
- [ ] Create PR with unit tests - [ ] Commit unit tests in branch `fix/worklog-utc-time-and-tldr-voice`Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share
- [X](https://twitter.com/intent/tweet?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A&url=https%3A//coderabbit.ai) - [Mastodon](https://mastodon.social/share?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A%20https%3A%2F%2Fcoderabbit.ai) - [Reddit](https://www.reddit.com/submit?title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&text=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code.%20Check%20it%20out%3A%20https%3A//coderabbit.ai) - [LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fcoderabbit.ai&mini=true&title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&summary=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code)Comment
@coderabbitai helpto get the list of available commands.Originally posted by: Akarsh-Hegde
Code Review
PR [#405]: fix(worklog): local-time inline markers in session distill
✅ Looks good overall. The UTC-to-local conversion fix is correct — attaching the started_at date to the marker before passing it through
utc_to_local_hhmmis the right fix. Version bump to 1.69.2 is correct per the runtime-versioning convention.Questions:
Removing the "PRESERVE concrete identifiers" rule — this is a significant change to the prompt. You're removing the rule that tells the classifier to preserve ticket keys, PR numbers, function names verbatim. The note says downstream matchers don't need this, but can you confirm the worklog matcher and any other downstream consumers won't be affected? If the matcher relied on finding these identifiers in the report text, this could silently break ticket binding.
TLDR high-level rewrite — makes sense to shift toward outcome-focused descriptions ("worked on auth refactor" vs "edited app.ts line 42"), but watch for outputs that now lack enough detail for the Core Tasks matcher to link to a ticket. Is there a risk that being too high-level in the TLDR leaves the matcher without enough hooks?
Minor: The comment in
session_distiller.pyreferences[[project_worklog_clock_trigger]]— is this a memory link to an existing memory file? If so, the reference is correct; if not, consider clarifying the UTC-vs-local bug context inline.Related
Tickets:
#405Originally posted by: Akarsh-Hegde
Review — local-time inline markers + plain-language TLDR
Summary: The core timezone fix is correct and, as a bonus, resolves a second latent sort-ordering bug; the prompt rewrite is reasonable but silently drops a matcher-critical rule that isn't in the PR description.
Blocking / correctness issues
None. The timezone conversion is sound:
session_distiller.py:282-284— reattachingstarted_at's UTC date to the bare[HH:MM:SS]marker and routing it throughutc_to_local_hhmmis right. The marker is UTC-only,started_atis a UTC ISO string, and the helper stampstzinfo=utcbefore.astimezone(LOCAL_TZ)(aware conversion, no naive/aware mix). The[11:16]fallback keeps parse failures non-fatal.cur_timecame fromutc_to_local_hhmm(started_at)(local) while marker lines used raw UTC[:5], sospans.sort(key=lambda s: (s["t"], …))(line 302) sorted a mix of local and UTC times across sessions. After this change allcur_timevalues are local, so intra-hour ordering is now consistent.Suggestions / nits
activity_report.py:44— removing the PRESERVE-identifiers rule is an unadvertised, matcher-affecting change. The deleted rule ("PRESERVE concrete identifiers verbatim — ticket keys e.g. KAN-241, file paths, function names, PR numbers … never genericize or drop them") was a global rule, not TLDR-scoped, and isn't in the PR's summary. The surviving line 46 ("Extract identifiable specifics: system/service/model/tool names") does not cover ticket keys / PR numbers / file paths, nor "verbatim / never drop." Since the downstream task-matcher binds work to tickets via those exact keys, dropping this risks the model genericizing KAN-xxx / PR# / paths out of Core Tasks — a real quality regression. If the intent was only to keep the TLDR high-level (already achieved by the line 20 rewrite), consider restoring the rule or re-scoping it to Core Tasks rather than deleting it.started_at's date for a marker that crosses UTC midnight assigns the wrong calendar date. Harmless for fixed-offset zones (IST, the tested case) since HH:MM is date-independent; could mislabel by ±1h only if a single session spans both UTC midnight and a DST transition. A one-line comment would suffice.activity_report.py:30now mandates "NO subject/narrator … never 'the developer did X'", but lines 20/25-28 still read "what the developer focused on / accomplished". Align the example phrasings so the model isn't given mixed signals.pyproject.toml1.69.1 → 1.69.2. Base ispre-main, liveruntime-stagingis 1.69.1, so strictly-greater — the auto-publish gate will ship it to staging. (runtime-latestis 1.68.0; if later promoted tomain, reconcile aboveruntime-latestper the lockstep convention.) Module docstrings present in both.pyfiles.Verdict: Approve with one nit to reconsider — confirm the deletion of the "PRESERVE identifiers verbatim" rule (
activity_report.py:44) is intentional and won't degrade downstream ticket matching before merge.🤖 Automated review via Claude Code
Ticket changed by: adityaharishch