fix(reply): restore configurable block streaming - #95
Merged
Merged
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
User-visible multi-message behavior and the beta CLI smoke still await human end-to-end validation.
Pull request overview
Restores configurable block streaming for inbound replies while preserving existing dispatch and account-routing behavior.
Changes:
- Enables ordered intermediate blocks by default with channel/account opt-outs.
- Adds schema, regression, hook, and host-compatibility coverage.
- Documents behavior in both languages and changelogs.
File summaries
| File | Description |
|---|---|
src/messaging/process-message.ts |
Applies resolved streaming configuration. |
src/messaging/process-message.test.ts |
Tests delivery order, overrides, and hooks. |
src/config/config-schema.ts |
Adds runtime schema fields. |
src/config/config-schema.test.ts |
Tests defaults and validation. |
src/config/block-streaming.ts |
Resolves account and channel precedence. |
src/config/block-streaming.test.ts |
Tests resolver behavior. |
scripts/check-host-compatibility.mjs |
Extends schema compatibility checks. |
README.md |
Documents Chinese configuration. |
README_EN.md |
Documents English configuration. |
openclaw.plugin.json |
Exposes the static schema option. |
CHANGELOG.md |
Records the Chinese fix. |
CHANGELOG_EN.md |
Records the English fix. |
Review details
- Files reviewed: 12/12 changed files
- Comments generated: 0
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.
变更说明
当前插件声明支持 block streaming,但入站回复链路始终硬编码
disableBlockStreaming: true,导致模型在多步工具调用之间完成的文本块不会发送,只剩最终回复。本 PR 以最小改动恢复分块回复:
blockStreaming: false仅发送最终回复;相关背景:Tencent/openclaw-weixin#251、openclaw/openclaw#92199。
验收标准
message_sending/message_sent钩子路径。2026.6.1、当前版本2026.8.2和当前 beta 保持可加载、可构建和可注册。非目标与替代方案
不迁移公共 channel-turn SDK,不重构消息钩子、配置写入、dispatcher 或 admission 生命周期,不提高最低宿主版本,也不修改发布版本。完整移植 Tencent/openclaw-weixin#251 会扩大兼容性与生命周期变更范围,因此本 PR 只修复当前社区版的可观察故障。
关联任务与风险
未关联社区 issue:这是范围明确、具有直接回归测试的小型 bug 修复。
最高风险是多账号配置使用稳定别名而 monitor 使用主账号 ID;实现采用现有路由语义的别名优先、主 ID 回退,并覆盖两种路径。剩余不确定性是实际微信端的分块展示及 OpenClaw 的短文本合并效果,等待人工整机实测。
风险与不变量
openclaw-weixin插件和 Channel ID 不变。replyProgressMessages继续独立控制工具调用进度消息。自动化测试用例
blockStreaming: false兼容性验证
2026.6.1:安装精确版本后 typecheck、build、fresh-process import、配置 schema、插件注册和 Channel 能力 smoke 通过。2026.8.2:同上,通过。2026.9.1-beta.1:typecheck、build、fresh-process import、配置 schema 和插件注册 smoke 通过;Windows 上完整 CLI Channel 能力探测曾超时,等待 PR 的 Ubuntu beta CI 完成该项。24.19.0。>=2026.6.1。整机实测结果
a99f2863ca359de8f1f4e671ecaee36c773c8a83脱敏关键日志
无。
其他验证命令
npm run check:通过,46 个测试文件、734 个测试。npm run pack:check:通过,发布包 96 个文件。npm test --prefix docs/site:通过,40 个测试。npm run build --prefix docs/site:通过。git diff --check:通过。检查清单
npm run check。