Repository navigation
fix(slack): preserve durable retries for thread-history failures - #117135
Conversation
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Codex review: needs maintainer review before merge. Reviewed July 31, 2026, 9:29 PM ET / August 1, 2026, 01:29 UTC. ClawSweeper reviewWhat this changesThis PR lets Slack's durable ingress queue retry transient thread-history lookup failures instead of caching them as missing threads, while preserving ambiguous handling for direct calls and definitive failures. Merge readinessThe PR remains necessary: current main converts every Slack thread-history failure into a cached ambiguous reply, while this patch correctly lets only known transient failures reach the existing durable ingress retry owner. The patch has no concrete correctness or security finding, but the protected Priority: P1 Review scores
Verification
How this fits togetherSlack Events API deliveries are durably admitted before Bolt dispatches them to the Slack message handler. The handler resolves a missing thread timestamp before dispatching the message, and a transient lookup failure must return to the durable ingress owner so the event can be replayed instead of silently dropped. flowchart LR
A[Slack Events API event] --> B[Durable ingress queue]
B --> C[Bolt event listener]
C --> D[Slack message handler]
D --> E[Thread history resolver]
E -->|Thread found or confirmed missing| F[Dispatch or intentional ambiguous result]
E -->|Transient provider failure| B
Decision needed
Why: The patch changes delivery behavior during provider outages and carries the protected Before merge
Agent review detailsSecurityNone. PR surfaceSource +46, Tests +212. Total +258 across 4 files. View PR surface stats
Review metricsNone. Technical reviewBest possible solution: Keep the single durable ingress queue as the retry owner, merge the narrow transient classification after Slack-owner confirmation, and retain cached ambiguity for direct calls, cancellations, and definitive Slack failures. Do we have a high-confidence way to reproduce the issue? Yes. On current main, make Is this the best way to solve the issue? Yes. Forwarding the existing durable lifecycle into the private resolver and rethrowing only classified transient failures is the narrowest maintainable repair; it avoids a parallel retry stack, config surface, or persistence path. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 95e50d3a7f14. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
* origin/main: (217 commits) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) fix(doctor): persist normalized agent roster (openclaw#117115) fix(signal): avoid replay after ambiguous quote delivery errors (openclaw#117134) fix(cron): reject disabled delivery accounts when scheduling (openclaw#116899) fix(gateway): honor HTTP If-Modified-Since media validators (openclaw#117133) fix(config): delete one array element per config patch delete (openclaw#116463) fix(plugins): report installed dependency health authoritatively (openclaw#117029) fix(ui): recover moving sessions across paged gateway rosters (openclaw#117016) fix(ui): clear hidden session selection before bulk deletion (openclaw#117015) fix(discord): avoid replaying ambiguous voice deliveries (openclaw#117127) fix(ui): scope Gateway reconnect lineage to its target (openclaw#117125) fix(models): expose runtime provider catalogs in browse views (openclaw#116857) ...
* commit 'c41f033b87545b658215a9c3bbe03f88fbaa867d': (347 commits) refactor(plugins): consolidate descriptor and startup ownership (openclaw#117146) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) fix(doctor): persist normalized agent roster (openclaw#117115) fix(signal): avoid replay after ambiguous quote delivery errors (openclaw#117134) fix(cron): reject disabled delivery accounts when scheduling (openclaw#116899) fix(gateway): honor HTTP If-Modified-Since media validators (openclaw#117133) fix(config): delete one array element per config patch delete (openclaw#116463) fix(plugins): report installed dependency health authoritatively (openclaw#117029) fix(ui): recover moving sessions across paged gateway rosters (openclaw#117016) fix(ui): clear hidden session selection before bulk deletion (openclaw#117015) fix(discord): avoid replaying ambiguous voice deliveries (openclaw#117127) fix(ui): scope Gateway reconnect lineage to its target (openclaw#117125) ...
* origin/main: (3706 commits) refactor(ui): unify filtered session list ownership (openclaw#117158) refactor(agents): consolidate context budgets and compaction recovery (openclaw#117149) fix(net-policy): redact sig and x-* auth params in URLs and bodies (openclaw#116957) refactor(agents): remove duplicate generated-media delivery fallbacks (openclaw#117150) refactor(reply): unify turn lifecycle state ownership (openclaw#117145) fix(ui): preserve emoji agent avatar initials (openclaw#104912) refactor(auto-reply): unify command and directive ownership (openclaw#117143) refactor(plugins): consolidate descriptor and startup ownership (openclaw#117146) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) fix(doctor): persist normalized agent roster (openclaw#117115) fix(signal): avoid replay after ambiguous quote delivery errors (openclaw#117134) fix(cron): reject disabled delivery accounts when scheduling (openclaw#116899) ...
* commit '7e78de747b8a64d52f30aee948b697bf4c528691': (359 commits) refactor(ui): replace duplicated locale bundles with canonical translation memory (openclaw#117157) fix(ui): retire stale Gateway event-log observers (openclaw#117169) fix(agents): keep subagent status consistent after restart and large fan-outs (openclaw#117141) refactor(ui): unify filtered session list ownership (openclaw#117158) refactor(agents): consolidate context budgets and compaction recovery (openclaw#117149) fix(net-policy): redact sig and x-* auth params in URLs and bodies (openclaw#116957) refactor(agents): remove duplicate generated-media delivery fallbacks (openclaw#117150) refactor(reply): unify turn lifecycle state ownership (openclaw#117145) fix(ui): preserve emoji agent avatar initials (openclaw#104912) refactor(auto-reply): unify command and directive ownership (openclaw#117143) refactor(plugins): consolidate descriptor and startup ownership (openclaw#117146) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) ...
…law#117135) Co-authored-by: Peter Steinberger <[email protected]>
* commit '31f24547a94a8bd74a32e42cde1783591c5804d9': (347 commits) refactor(plugins): consolidate descriptor and startup ownership (openclaw#117146) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) fix(doctor): persist normalized agent roster (openclaw#117115) fix(signal): avoid replay after ambiguous quote delivery errors (openclaw#117134) fix(cron): reject disabled delivery accounts when scheduling (openclaw#116899) fix(gateway): honor HTTP If-Modified-Since media validators (openclaw#117133) fix(config): delete one array element per config patch delete (openclaw#116463) fix(plugins): report installed dependency health authoritatively (openclaw#117029) fix(ui): recover moving sessions across paged gateway rosters (openclaw#117016) fix(ui): clear hidden session selection before bulk deletion (openclaw#117015) fix(discord): avoid replaying ambiguous voice deliveries (openclaw#117127) fix(ui): scope Gateway reconnect lineage to its target (openclaw#117125) ...
* commit '5148236bbe050f6c05ee59190986a7215b41ce1c': (359 commits) refactor(ui): replace duplicated locale bundles with canonical translation memory (openclaw#117157) fix(ui): retire stale Gateway event-log observers (openclaw#117169) fix(agents): keep subagent status consistent after restart and large fan-outs (openclaw#117141) refactor(ui): unify filtered session list ownership (openclaw#117158) refactor(agents): consolidate context budgets and compaction recovery (openclaw#117149) fix(net-policy): redact sig and x-* auth params in URLs and bodies (openclaw#116957) refactor(agents): remove duplicate generated-media delivery fallbacks (openclaw#117150) refactor(reply): unify turn lifecycle state ownership (openclaw#117145) fix(ui): preserve emoji agent avatar initials (openclaw#104912) refactor(auto-reply): unify command and directive ownership (openclaw#117143) refactor(plugins): consolidate descriptor and startup ownership (openclaw#117146) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) ...
* origin/main: (3706 commits) refactor(ui): unify filtered session list ownership (openclaw#117158) refactor(agents): consolidate context budgets and compaction recovery (openclaw#117149) fix(net-policy): redact sig and x-* auth params in URLs and bodies (openclaw#116957) refactor(agents): remove duplicate generated-media delivery fallbacks (openclaw#117150) refactor(reply): unify turn lifecycle state ownership (openclaw#117145) fix(ui): preserve emoji agent avatar initials (openclaw#104912) refactor(auto-reply): unify command and directive ownership (openclaw#117143) refactor(plugins): consolidate descriptor and startup ownership (openclaw#117146) fix(messages): reply actions leak citation markers and reply/poll answers draw the no-reply fallback (openclaw#116909) fix(slack): let durable ingress retry transient thread lookups (openclaw#117135) refactor(doctor): consolidate shipped state migration ownership (openclaw#117142) fix(ai): Codex stream shows internal parser text on a malformed frame (openclaw#116966) fix: guard every migrated session accessor path (openclaw#117140) fix(terminal): measure unicode display width consistently (openclaw#117062) fix(openai): clear ChatGPT SSE fallback per session (openclaw#117123) fix(mistral): reject incomplete streamed tool terminals (openclaw#117137) fix(ai): preserve structured chat content and refusals (openclaw#117136) fix(doctor): persist normalized agent roster (openclaw#117115) fix(signal): avoid replay after ambiguous quote delivery errors (openclaw#117134) fix(cron): reject disabled delivery accounts when scheduling (openclaw#116899) ...
Summary
Root cause
The private Slack thread resolver swallowed every
conversations.historyfailure and cached anullthread as if Slack had successfully confirmed that no thread exists. For the default one-minute cache this caused latermessage/app_mentionevent twins to be silently discarded; withcacheTtlMs: 0, one transient provider outage could poison the cache indefinitely. Slack's real fetch timeout is subtler than a conventionalETIMEDOUT: the installed Slack Web API client wrapsAbortSignal.timeout()'sDOMExceptionnamedTimeoutErrorwith numeric code 23 inWebAPIRequestError.The correct retry owner already exists. Slack acknowledges an Events API event only after it is durably appended, then dispatches it with an existing turn-adoption lifecycle. By forwarding that same lifecycle to the private resolver, genuine provider HTTP 408/429/5xx, Slack rate-limit errors, recognized transient network errors, and actual SDK timeout DOM exceptions now propagate to the durable queue's existing backoff/replay owner. Calls without durable ownership retain their intentional ambiguous result, without caching a transient outage as an authoritative negative.
Verification
DOMException("TimeoutError")has numeric code 23; an authentic new owner RED and actual hanging HTTP request both reproduced the miss. ExplicitAbortErrorcancellation remains a negative control.gpt-5.6-sol/ high / P0–P3 structured automated review: clean; zero findings; confidence 0.94. Genuine TruffleHog secret scan: clean.Compatibility and risk
Only private Slack owner/caller files and their existing tests change. Definitive Slack HTTP 400/403/404 and
missing_scopeerrors retain cached ambiguity; successful missing-thread responses stay authoritative; direct calls remain fail-closed; explicit request cancellation is not retried. The existing generic durable queue retains its current backoff policy; teaching that shared owner to honor provider-specificRetry-Afterhints is a separate follow-up.