fix(cockpit-chat-debug): give the devtools State tab real state to show - #1070
Merged
Conversation
The dock has two tabs and only one of them demonstrated anything. Its graph was a plain MessagesState, and agent.state() projects messages out into the transcript, so the State inspector printed an empty object no matter what the run did — the page still promised it 'pretty-prints the agent's current state'. The process node already computed the metrics; it just buried them in a message. DebugState widens MessagesState with an analysis dict, so those numbers land in state where the inspector can render them. The fixture is now recorded from a real run rather than authored, and the State spec asserts the analysis keys instead of merely asserting the inspector renders some object — the shape the old comment said should widen this tab's coverage rather than fail it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
blove
enabled auto-merge (squash)
September 8, 2026 20:28
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes the two open items on the c-debug capability from the docs-accuracy arc: the authored fixture, and the permanently empty State tab.
The State tab had nothing to show
The dock has two tabs and only one of them demonstrated anything. The graph was a plain
MessagesState, andagent.state()is the values bag withmessagesprojected out into the transcript — so the inspector printed{}for every run, while the page promised it "pretty-prints the agent's current state".The
processnode already computed the metrics; it buried them in a message.DebugStatewidensMessagesStatewith ananalysisdict so those numbers land where the inspector can render them. The narrated message is unchanged, so the transcript reads the same.The fixture is now recorded, not authored
#1063 shipped with an authored fixture because no API key was available in that environment. It is now recorded from a real run through
scripts/record-aimock-cap.sh c-debug, with the registered prompt.The spec now asserts the thing that changed
The old State assertion was
/^\{[\s\S]*\}$/— satisfied by the empty object it was documenting, and its comment said a graph carrying real state "should widen this tab's coverage, not fail it". It now assertsanalysis,charactersandwords. That text did not exist in state before this change, so the assertion can only pass because of it.Verification
nx e2e cockpit-chat-debug-angular— 4 passed, run twice (before and after tightening the assertion).ast.parseon the graph; docs guards (docs-example-code,docs-content-rules,public-copy,cockpit-retirement) 50 passed.GROWTH_FORM_POLICY=growth_v1 nx build websitegreen; the page renders 5 includes for 5 tags, including the newdebug-stateregion.🤖 Generated with Claude Code