feat(slack): render progress as native progress task cards#87748
Conversation
|
Codex review: needs changes before merge. Reviewed May 28, 2026, 3:06 PM ET / 19:06 UTC. Summary PR surface: Source +580, Tests +1208, Docs +20, Generated 0. Total +1808 across 22 files. Reproducibility: yes. source-level reproduction is clear: buildPlanTasks slices to the visible task window and then derives idless fallback ids from index, so dropping an older idless line renumbers remaining task_update ids. Review metrics: 1 noteworthy metric.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Mantis proof suggestion Risk before merge
Maintainer options:
Copy recommended automerge instructionNext step before merge
Security Review findings
Review detailsBest possible solution: Land one canonical branch after stabilizing idless task ids, preserving default-off behavior, and recording upgrade safety for Slack account streaming config. Do we have a high-confidence way to reproduce the issue? Yes, source-level reproduction is clear: buildPlanTasks slices to the visible task window and then derives idless fallback ids from index, so dropping an older idless line renumbers remaining task_update ids. Is this the best way to solve the issue? No, not yet: the opt-in Slack chunk approach is the right direction, but the implementation should stabilize idless fallback ids and get maintainer compatibility signoff before merge. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model gpt-5.5, reasoning high; reviewed against a2595f16d486. Label changesLabel justifications:
Evidence reviewedPR surface: Source +580, Tests +1208, Docs +20, Generated 0. Total +1808 across 22 files. View PR surface stats
Acceptance criteria:
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 59025447f5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| id: line.id | ||
| ? stableTaskIdPart(line.id) | ||
| : `${slugTaskIdPart(line.toolName ?? line.kind ?? line.label)}_${index + 1}`, |
There was a problem hiding this comment.
Keep fallback task ids stable across progress updates
When Slack-native progress is enabled and a progress line has no line.id (for example plan/approval events or provider item events that omit itemId), this fallback id is based on the line's current position in the capped progress array. Once streaming.progress.maxLines drops an older entry, every remaining idless task can be renumbered, so Slack task_update chunks update the wrong cards or leave stale cards in the plan instead of preserving the rolling-window behavior the draft preview had. Use a stable fallback derived from the line identity, or otherwise preserve per-line ids before slicing.
Useful? React with 👍 / 👎.
08801a0 to
4803e98
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4803e98820
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ...(baseConfig.preview || accountConfig.preview | ||
| ? { preview: { ...baseConfig.preview, ...accountConfig.preview } } |
There was a problem hiding this comment.
Preserve preview chunk defaults when merging accounts
When a Slack account overrides only part of streaming.preview.chunk, this shallow preview merge replaces the whole chunk object, so top-level defaults such as minChars or breakPreference are dropped even though the rest of this helper now inherits account streaming settings field-by-field. resolveChannelStreamingPreviewChunk() consumes that nested object as-is, so an account config like top-level preview.chunk: { minChars, maxChars, breakPreference } plus account preview.chunk: { maxChars } silently changes the chunking behavior for that account; merge preview.chunk the same way block.coalesce is merged.
Useful? React with 👍 / 👎.
|
Verification before merge: Behavior addressed: Slack progress-mode streaming can render native task-card progress updates while preserving draft fallback behavior; account-level streaming config now deep-merges canonical nested defaults without breaking legacy scalar overrides; plugin SDK fetch runtime import stays lightweight. |
Render Slack progress-mode updates as native task-card progress blocks, with bounded Slack chunk text and stable fallback behavior. Also deep-merge Slack account streaming objects over top-level defaults while preserving legacy scalar account overrides, and keep the plugin SDK fetch runtime import path from evaluating guarded-fetch dispatcher code. Verification: - pnpm test extensions/slack/src/progress-blocks.test.ts extensions/slack/src/accounts.test.ts src/plugin-sdk/fetch-runtime.test.ts - pnpm lint --threads=8 - git diff --check - .agents/skills/autoreview/scripts/autoreview --mode local - GitHub PR checks green on openclaw#87748 at 4803e98 Refs openclaw#82258 Co-authored-by: Simon van Laak <[email protected]>
Render Slack progress-mode updates as native task-card progress blocks, with bounded Slack chunk text and stable fallback behavior. Also deep-merge Slack account streaming objects over top-level defaults while preserving legacy scalar account overrides, and keep the plugin SDK fetch runtime import path from evaluating guarded-fetch dispatcher code. Verification: - pnpm test extensions/slack/src/progress-blocks.test.ts extensions/slack/src/accounts.test.ts src/plugin-sdk/fetch-runtime.test.ts - pnpm lint --threads=8 - git diff --check - .agents/skills/autoreview/scripts/autoreview --mode local - GitHub PR checks green on #87748 at 4803e98 Refs #82258 Co-authored-by: Simon van Laak <[email protected]>
Render Slack progress-mode updates as native task-card progress blocks, with bounded Slack chunk text and stable fallback behavior. Also deep-merge Slack account streaming objects over top-level defaults while preserving legacy scalar account overrides, and keep the plugin SDK fetch runtime import path from evaluating guarded-fetch dispatcher code. Verification: - pnpm test extensions/slack/src/progress-blocks.test.ts extensions/slack/src/accounts.test.ts src/plugin-sdk/fetch-runtime.test.ts - pnpm lint --threads=8 - git diff --check - .agents/skills/autoreview/scripts/autoreview --mode local - GitHub PR checks green on openclaw#87748 at 4803e98 Refs openclaw#82258 Co-authored-by: Simon van Laak <[email protected]>
Render Slack progress-mode updates as native task-card progress blocks, with bounded Slack chunk text and stable fallback behavior. Also deep-merge Slack account streaming objects over top-level defaults while preserving legacy scalar account overrides, and keep the plugin SDK fetch runtime import path from evaluating guarded-fetch dispatcher code. Verification: - pnpm test extensions/slack/src/progress-blocks.test.ts extensions/slack/src/accounts.test.ts src/plugin-sdk/fetch-runtime.test.ts - pnpm lint --threads=8 - git diff --check - .agents/skills/autoreview/scripts/autoreview --mode local - GitHub PR checks green on openclaw#87748 at 4803e98 Refs openclaw#82258 Co-authored-by: Simon van Laak <[email protected]>
Summary
Verification
pnpm test extensions/slack/src/progress-blocks.test.ts extensions/slack/src/accounts.test.ts.agents/skills/autoreview/scripts/autoreview --mode localgit diff --checkReal behavior proof
Behavior addressed: Slack progress mode can opt into native task cards without breaking fallback delivery or account-level streaming overrides.
Real environment tested: local OpenClaw checkout, focused Slack unit tests.
Exact steps or command run after this patch:
pnpm test extensions/slack/src/progress-blocks.test.ts extensions/slack/src/accounts.test.tsEvidence after fix: 2 test files passed, 42 tests passed.
Observed result after fix: long native plan titles are capped before Slack stream chunks are built; account streaming object overrides inherit root streaming fields, while legacy scalar account overrides still replace the root object.
What was not tested: live Slack workspace delivery in this maintainer branch; original PR supplied real behavior proof and CI coverage.
Refs #82258.
Co-authored-by: Simon van Laak [email protected]