Split delivery pipeline into streaming/silent paths #38
No reviewers
Labels
No labels
in-review
ready-for-agent
ready-for-human
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
weiwen/evie!38
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "sandcastle/issue-30"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Scheduled pushes were running through the same
deliver_responsepipeline as interactive messages, which sent a placeholder message, started a typing indicator, and streamed live edits — all inappropriate for a background scheduled push.This PR splits the delivery pipeline into two distinct entry points sharing a common
render_finaltail:deliver_streaming(interactive path): sends a placeholder immediately, starts a typing indicator, and streamspisnapshots to Telegram on a throttled cadence viaMessageView. Renders a final authoritative pass onagent_end. Used by the Telegram message handler.deliver_silent(scheduled path): passes a throwaway snapshot channel tosession_manager.send_message(send failures on a dropped receiver are silently ignored, sopi.rsneeded no changes), no placeholder, no typing indicator, no live edits. Renders into an emptyMessageViewso final pages arrive as fresh messages, not edits. Used bydelivery_consumer.render_final: extracted shared tail — paginates the result, edits the placeholder or sends fresh pages, attaches source buttons on the last page, or sends a plain error notice on failure.Key decisions
MessageView::empty()was added as the silent-path seed so the existing reconcile logic works without modification — an emptyidsvec causes every page to be sent fresh.deliver_response(previouslypub) is now two private functions;delivery_consumeris in the same module and needs no re-export.pi.rs: the snapshot channel send already silently ignored errors on a dropped receiver, so passing a throwaway_rxis safe.Reviewer checklist
deliver_silentreally suppresses the typing indicator and placeholder in a live test or by reading the call sitesrender_finalcorrectly handles both a seeded view (streaming path) and an empty view (silent path)_rximmediately after creation indeliver_silentdoes not race withsend_messagebefore the first snapshot would be sentCloses #30
don’t use deliver silent. i just don’t want to send typing indicator when preparing the message. delivery_silent stops notifications
Removed deliver_silent (which skipped sending the placeholder and therefore suppressed notifications). The scheduled path now calls deliver_streaming with typing_indicator=false — it still sends a placeholder immediately (triggering the notification), streams live edits, and renders the final result, but never starts the typing indicator.
c954e710fb6ed7aa5ccb6ed7aa5ccbc23efdb726