Skip to content

fix(orchestration): emit message timestamps as RFC3339 UTC (partial, refs #8698) - #9167

Merged
brennanb2025 merged 1 commit into
mainfrom
brennanb2025/bug-8698-triage
Jul 17, 2026
Merged

brennanb2025 merged 1 commit into
mainfrom
brennanb2025/bug-8698-triage

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Jul 17, 2026 •

Copy link
Copy Markdown
Contributor

Scope — partial (does not close #8698)

This lands only the safe, confident sub-fix from triaging #8698: orchestration message timestamps (created_at, delivered_at) are now emitted as RFC3339 UTC (Z) without changing SQLite storage, plus a regression test.

The core issue — a completed worker_done staying unseen (read=0, delivered_at=null) until an explicit check when no long-poll is active — is intentionally not addressed here: notifyMessageArrived only wakes registered waiters and PTY push is deliberately gated on a reliable idle-agent status; relaxing that gate risks auto-submitting into a busy/unknown PTY on local, Windows, WSL, SSH, or relay. That needs a product decision (a non-PTY runtime→renderer completion notification), tracked separately.

Validation

Focused timestamp test + 326 tests pass, typecheck + lint clean.

Refs #8698

Manual validation

PASS — real Orca dev app from the PR branch (ab5fac347).

  • Launched an isolated dev Orca from this checkout and exercised live orchestration send, check --peek, and idle-agent push delivery.
  • check --peek returned two messages in FIFO sequence order (6, then 7), with RFC3339 UTC created_at values ending in Z.
  • After push-on-idle, check --all returned both created_at: 2026-07-17T19:32:16Z and delivered_at: 2026-07-17T19:32:16Z. The immediate raw result kept read: 0, preserving the existing distinction between delivered and consumed; the recipient later consumed it.
  • The focused timestamp regression test also passed locally.
  • Scope remained timestamp-only; this does not validate or claim to resolve the core Orchestration completion can remain unseen without an explicit inbox poll #8698 visibility issue.

Live created/delivered timestamp output:

Live Orca created_at and delivered_at RFC3339 UTC timestamps

Live FIFO ordering output:

Live Orca FIFO message ordering with RFC3339 UTC created_at timestamps

@coderabbitai

coderabbitai Bot commented Jul 17, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Added timestamp normalization helpers that convert SQLite message timestamps to ISO-8601 UTC strings with T separators and trailing Z characters. Applied normalization across orchestration message queries, including unread, inbox, history, thread, all-message, and single-message retrieval. Added tests covering created_at and delivered_at formatting.

🚥 Pre-merge checks | ✅ 2 | ❌ 3

❌ Failed checks (3 warnings)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR normalizes timestamps, but #8698 also requires surfacing worker_done or explicit long-poll guidance, which remains unaddressed. Implement the completion-visibility behavior or the required polling/notification guidance from #8698, then verify the end-to-end coordinator flow.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ⚠️ Warning The description has summary and validation details, but it is missing the required Screenshots, AI Review Report, Security Audit, and Notes sections. Add the missing template sections and include an AI review summary, security audit, notes, and a dedicated Screenshots section or explicit no-visual-change note.
✅ Passed checks (2 passed)
Check name Status Explanation
Out of Scope Changes check ✅ Passed The code changes stay focused on timestamp normalization and regression tests, matching the stated partial scope.
Title check ✅ Passed The title clearly matches the main change: normalizing orchestration message timestamps to RFC3339 UTC.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

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

Comment @coderabbitai help to get the list of available commands.

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.

Orchestration completion can remain unseen without an explicit inbox poll

1 participant