fix(agents): preserve messaging dedupe thread ids · openclaw/openclaw@642e1df
vincentkoc
·
2026-05-04
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -49,6 +49,7 @@ Docs: https://docs.openclaw.ai
|
49 | 49 | - Gateway/logging: expand leading `~` in `logging.file` before creating the file logger, preventing startup crash loops for home-relative log paths. Fixes #73587. |
50 | 50 | - Channels/CLI: keep `openclaw channels list --json` usable when provider usage fetching fails, and report per-provider usage errors without aborting the channel list. Refs #67595. |
51 | 51 | - Agents/messaging: deliver distinct final commentary after same-target `message` tool sends while still deduping text/media already sent by the tool, so short closing remarks are no longer silently dropped. Fixes #76915. Thanks @hclsys. |
| 52 | +- Agents/messaging: preserve string thread IDs when matching message-tool reply dedupe routes, avoiding precision loss on numeric-looking topic IDs before channel plugin comparison. Thanks @vincentkoc. |
52 | 53 | - OpenAI Codex: let SSRF-guarded provider requests inherit OpenClaw's undici IPv4/IPv6 fallback policy, so ChatGPT-backed Codex runs recover on IPv4-working hosts when DNS still returns unreachable IPv6 addresses. Fixes #76857. Thanks @jplavoiemtl and @SymbolStar. |
53 | 54 | - Gateway/systemd: preserve operator-added secrets in the Gateway env file across re-stage while clearing OpenClaw-managed keys (such as `OPENCLAW_GATEWAY_TOKEN`) so a fresh staging value is never shadowed by a stale env-file copy; operator secrets are also retained when the state-dir `.env` is empty. Fixes #76860. Thanks @hclsys. |
54 | 55 | - Plugin updates: do not short-circuit trusted official npm updates as unchanged when the default/latest spec still resolves to an already-installed prerelease that the installer should replace with a stable fallback. Thanks @vincentkoc. |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -88,11 +88,7 @@ function normalizeProviderForComparison(value?: string): string | undefined {
|
88 | 88 | } |
89 | 89 | |
90 | 90 | function normalizeThreadIdForComparison(value?: string): string | undefined { |
91 | | -const normalized = stringifyRouteThreadId(value); |
92 | | -if (!normalized) { |
93 | | -return undefined; |
94 | | -} |
95 | | -return /^-?\d+$/.test(normalized) ? String(Number.parseInt(normalized, 10)) : normalized; |
| 91 | +return stringifyRouteThreadId(value); |
96 | 92 | } |
97 | 93 | |
98 | 94 | function resolveTargetProviderForComparison(params: { |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -197,6 +197,21 @@ describe("shouldDedupeMessagingToolRepliesForRoute", () => {
|
197 | 197 | ).toBe(true); |
198 | 198 | }); |
199 | 199 | |
| 200 | +it("preserves string thread ids before plugin reply-suppression matching", () => { |
| 201 | +installTelegramSuppressionRegistry(); |
| 202 | +const largeThreadId = "9007199254740993"; |
| 203 | + |
| 204 | +expect( |
| 205 | +shouldDedupeMessagingToolRepliesForRoute({ |
| 206 | +messageProvider: "telegram", |
| 207 | +originatingTo: `telegram:group:-100123:topic:${largeThreadId}`, |
| 208 | +messagingToolSentTargets: [ |
| 209 | +{ tool: "message", provider: "telegram", to: "-100123", threadId: largeThreadId }, |
| 210 | +], |
| 211 | +}), |
| 212 | +).toBe(true); |
| 213 | +}); |
| 214 | + |
200 | 215 | it("does not match telegram topic-origin replies when explicit threadId differs", () => { |
201 | 216 | expect( |
202 | 217 | shouldDedupeMessagingToolRepliesForRoute({ |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。