fix(cron): send text output directly when delivery.to is set#16360
Merged
thewilloftheshadow merged 1 commit intoopenclaw:mainfrom Feb 14, 2026
Merged
Conversation
| // summarize. When we have an explicit delivery target (delivery.to), sender | ||
| // identity, or structured content, prefer direct outbound delivery to send | ||
| // the actual cron output without summarization. | ||
| const hasExplicitDeliveryTarget = Boolean(deliveryPlan.to); |
Contributor
There was a problem hiding this comment.
use resolvedDelivery.to instead of deliveryPlan.to for consistency — resolvedDelivery.to is the validated, resolved value that's actually used for delivery (line 578), while deliveryPlan.to is the raw input
Suggested change
| const hasExplicitDeliveryTarget = Boolean(deliveryPlan.to); | |
| const hasExplicitDeliveryTarget = Boolean(resolvedDelivery.to); |
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/cron/isolated-agent/run.ts
Line: 565:565
Comment:
use `resolvedDelivery.to` instead of `deliveryPlan.to` for consistency — `resolvedDelivery.to` is the validated, resolved value that's actually used for delivery (line 578), while `deliveryPlan.to` is the raw input
```suggestion
const hasExplicitDeliveryTarget = Boolean(resolvedDelivery.to);
```
How can I resolve this? If you propose a fix, please make it concise.1c263e8 to
c768185
Compare
thewilloftheshadow
added a commit
to rubyrunsstuff/clawdbot
that referenced
this pull request
Feb 14, 2026
c768185 to
d37ae34
Compare
d37ae34 to
c424340
Compare
Contributor
|
Hey @thewilloftheshadow I was going to work on this one... hehe |
Member
|
Landed via temp rebase onto main.
Thanks @rubyrunsstuff! |
akoscz
pushed a commit
to akoscz/openclaw
that referenced
this pull request
Feb 15, 2026
GwonHyeok
pushed a commit
to learners-superpumped/openclaw
that referenced
this pull request
Feb 15, 2026
vincentkoc
pushed a commit
to vincentkoc/openclaw
that referenced
this pull request
Feb 15, 2026
snowzlm
pushed a commit
to snowzlm/openclaw
that referenced
this pull request
Feb 15, 2026
Benkei-dev
pushed a commit
to Benkei-dev/openclaw
that referenced
this pull request
Feb 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
When a cron job has an explicit
delivery.totarget, text-only output was being routed throughrunSubagentAnnounceFlow, which prompts the main agent to "summarize naturally in 1-2 sentences." This means users receive the main agent's summary instead of the actual cron output.Example: A morning briefing cron generates a detailed update about art projects, calendar, weather, etc. But the user receives: "morning briefing nailed it — heartstrings is live and it's valentine's day. go be romantic!" instead of the actual briefing content.
Solution
Add a check for
hasExplicitDeliveryTarget(whendelivery.tois set) to the condition that determines whether to use direct delivery viadeliverOutboundPayloads. This makes text-only cron output behave like structured content — going directly to the target without summarization.The announce flow is still used when there's no explicit target, which is the intended behavior for subagent tasks that need conversational context from the main session.
Changes
src/cron/isolated-agent/run.ts: AddedhasExplicitDeliveryTargetcheck to bypass announce flow whendelivery.toexistsTesting
Manually tested with a cron job that has
delivery: { mode: 'announce', channel: 'bluebubbles', to: '+1234567890' }- confirmed the full output is now delivered instead of a summary.Greptile Overview
Greptile Summary
Adds
hasExplicitDeliveryTargetcheck to bypass the announce flow whendelivery.tois explicitly set, ensuring cron output is delivered directly without main agent summarization.delivery.towas being summarized by the main agent instead of being delivered verbatimdeliverOutboundPayloads) rather than the subagent announce flowresolvedDelivery.toinstead ofdeliveryPlan.tofor consistency with the actual delivery mechanismConfidence Score: 5/5
resolvedDelivery.toexists). The only issue is a minor style preference that doesn't affect functionality.Last reviewed commit: 1c263e8