[BUG] Thinking text empty / "Thought for Xs" not expandable on Opus 4.7+ in VS Code extension — fallback thinking-config branch omits `display`
Summary
In the VS Code extension, the "Thought for Xs" label is not expandable and shows no thinking text when using an Opus model (4.7 / 4.8). Only durationMillis comes back; the thinking content itself is empty. The same session on Sonnet shows thinking text correctly, which is the tell that this is model-dependent rather than a general breakage.
Environment
- Extension:
anthropic.claude-code2.1.154 (also reproduces on 2.1.143/2.1.145), win32-x64 - OS: Windows 10
- Model: Claude Opus 4.8 (
claude-opus-4-8); also seen on Opus 4.7 prefersReducedMotion: trueset globally (not related to the cause)
Steps to reproduce
- Select an Opus model (4.7 or 4.8) in the VS Code extension.
- Send any prompt that triggers extended thinking.
- Observe the "Thought for Xs" label appears but is not clickable / has no expandable thinking content.
- Switch to a Sonnet model and repeat → thinking text appears and expands normally.
Expected
The "Thought for Xs" label is expandable and shows the summarized thinking, regardless of model.
Actual
On Opus, the label is inert and the thinking payload is empty (only the duration survives).
Root cause
The extension's thinking-config builder has a fallback branch that constructs the config without a display field. In the current minified bundle it looks structurally like:
// fallback branch — note: no `display`
PB = s0 === 0 ? { type: "disabled" } : { type: "enabled", budgetTokens: s0 };
…whereas the switch…case "enabled" branch does carry it (display: K0.display). Downstream, the CLI flag is only pushed when display is truthy:
if (... && L.display) p.push("--thinking-display", L.display);
So via the fallback branch, --thinking-display is never passed. The server-side default for display on Opus models appears to be omitted (Sonnet appears to default to summarized), so on Opus the thinking content is stripped — which is why this only reproduces on Opus.
(Minified identifiers PB/s0 are from one local 2.1.154 build and drift between versions; the structural pattern is the stable part.)
Suggested fix
Set display explicitly in the fallback branch instead of relying on the per-model server default, e.g.:
PB = s0 === 0 ? { type: "disabled" } : { type: "enabled", budgetTokens: s0, display: "summarized" };
Verified locally: adding display:"summarized" to that branch restores the expandable thinking text on Opus 4.8. Valid values for the flag are summarized and omitted.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗