fix(discord): accumulate reasoning progress deltas#87339
Conversation
|
Codex review: needs maintainer review before merge. Reviewed May 31, 2026, 7:17 PM ET / 23:17 UTC. Summary PR surface: Source +51, Tests +312. Total +363 across 3 files. Reproducibility: yes. The source path is clear from current main and the PR tests: formatted reasoning text reaches the Discord progress merge path before this patch, while simulated deltas reproduce the last-delta-only failure shape. Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Land the raw-merge/post-format Discord draft-preview approach after a maintainer checks merge order against adjacent Discord progress PRs and keeps the linked bug open until this PR merges. Do we have a high-confidence way to reproduce the issue? Yes. The source path is clear from current main and the PR tests: formatted reasoning text reaches the Discord progress merge path before this patch, while simulated deltas reproduce the last-delta-only failure shape. Is this the best way to solve the issue? Yes. The best fix is to keep raw reasoning semantics until Discord's progress merger decides delta versus snapshot behavior, then apply display formatting once; this matches the sibling Slack shape without changing the shared callback or Codex protocol contract. AGENTS.md: found and applied where relevant. Codex review notes: model gpt-5.5, reasoning high; reviewed against cb9847968a1d. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +51, Tests +312. Total +363 across 3 files. View PR surface stats
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
|
|
ClawSweeper PR egg 🎁 Pass real behavior proof to wake the egg and unlock a hatchable treat. Where did the egg go?
|
6086081 to
c626d4d
Compare
|
Refreshed #87339 onto current Focused WSL validation after the refresh:
This refresh should replace the prior |
This comment was marked as spam.
This comment was marked as spam.
c626d4d to
444363d
Compare
|
Added the missing live Discord progress-mode proof. Branch/head under test: Validation: The proof harness loads this PR's Redacted live result: {
"status": "pass",
"branchHead": "444363d876074313ccc7a26c54dccbbc225b1074",
"channelIdSuffix": "181747",
"messageId": "1510047965010591995",
"marker": "OC87339-mprhxsb5",
"expected": "_Considering plugin installation!_",
"content": "Proof <marker>\n\n• _Considering plugin installation!_"
}Targeted regression: Note: the full Discord QA lane requires separate driver and SUT bots. The local proof env currently has the single QA bot, so this proof intentionally exercises the real Discord outbound draft/edit/fetch transport path for the patched progress accumulator without printing or copying token values. @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
🦞👀 Command router queued. I will update this comment with the next step. |
444363d to
0cbf484
Compare
|
@clawsweeper re-review Refreshed #87339 onto current Focused WSL validation after the refresh passed:
The refreshed diff is still limited to the same three Discord files, with no config surface or plugin surface changes. No merge performed. |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Addressed the review issue around raw reasoning text that starts with
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Updated #87339 for the latest ClawSweeper/Codex review findings and rebased onto current New signed head: What changed:
Fresh focused validation:
No merge performed. @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
5a22fc3 to
483db36
Compare
|
Updated #87339 for the remaining ClawSweeper raw New signed head: What changed:
Fresh focused validation:
No merge performed. @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
483db36 to
29dfb03
Compare
|
Updated #87339 on current New signed head: What changed:
Fresh validation:
No merge performed. @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
e12bbfc to
f18a3f6
Compare
|
Updated #87339 onto live New signed head: Validation after the refresh:
Diff remains scoped to Discord reasoning progress rendering/tests; no config surface or plugin surface changes. No merge performed. Note: GitHub main advanced again just after this push, so this proves the rebased head against @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
f18a3f6 to
d4d74b7
Compare
|
@clawsweeper re-review Refreshed #87339 onto current Updates on signed head
Validation in WSL from
No public config, plugin API, CLI flag, env var, migration, or plugin contract surface was added. No merge performed. |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Maintainer verification before landing:
Landing this PR to close the source-repro Discord reasoning progress regression in #83983. Thank you @giodl73-repo for the fix and the live Discord proof. |
Summary
Fixes #83983.
Discord progress-mode reasoning updates were formatting each reasoning callback with the display
Thinking...wrapper before draft-preview merge logic saw it. Since the merge logic treats display-prefixed reasoning text as a full snapshot, Codex app-server delta chunks like"Considering"," plugin"," installation","!"could replace each other until only the final tiny chunk remained visible.This keeps reasoning stream payloads raw until
pushReasoningProgress()merges delta/snapshot semantics, then applies the existing reasoning display formatter once for the stable progress line. Follow-ups keep raw reasoning text that starts withThinking,Thinking:,Thinking..., a singleThinkingline, orReasoning:intact, while still stripping legacy newline-prefixedReasoning:\n...andThinking...\n\n_..._display wrappers. Long reasoning progress lines are compacted before italic wrapping so Discord markdown remains balanced after truncation.No config surface or plugin surface changes.
Proof
Rebased onto current
main(0c74f18a1c090746c390b749b6845988072a8f14). All 3 commits are signed. Signed head:d4d74b7d210890bb13f4e5f02ed4272d8ee48344.