v2.5.0
Pre-releaseHighlights
- The code derived from microsoft/DebugMCP is rewritten (Open-CMSIS-Pack#53). The server, the debugging handler and executor, multi-window routing, the configuration managers, activation and the build config were each rewritten from a behaviour specification by an implementer who did not see the old file. No source file carries the Microsoft copyright line any more. The method and per-file evidence are in
docs/provenance/. The license files are unchanged pending the review in Open-CMSIS-Pack#54. - Failures are failures (Open-CMSIS-Pack#11). Every failed tool call is
isError, starts with an error code ([NO_SESSION],[TARGET_RUNNING],[PROBE_BUSY], …) and puts the next step on its own line. A tool error in another VS Code window is no longer reported as "Could not reach the VS Code window". cmsis_actionfollows the task it started (Open-CMSIS-Pack#47, Open-CMSIS-Pack#46, Open-CMSIS-Pack#12). "CMSIS Load", "CMSIS Run" and builds are tracked as jobs, and a long build returnsrunninguntil you ask forcmsis_action {action: "status"}. Probe-owning actions andflashrefuse withPROBE_BUSYwhile a CMSIS Run task or a debug session holds the probe.flashuses the CMSIS Debugger's bundled pyOCD.- GDB commands reach GDB in CMSIS Debugger sessions (Open-CMSIS-Pack#56, Open-CMSIS-Pack#13).
evaluate_expression("-exec …")returns GDB's output, andresetnow really resets (J-Link included).- Breakpoints go through VS Code's model and report whether they bound. Logpoints fill in
{expr}and honour their condition. - Breakpoint changes on a running target pause, apply and resume. A "target is running" refusal returns
TARGET_RUNNINGinstead of a toast.
- Language guides. Python and C/C++ are rewritten, and C/C++ is now served as a resource. JavaScript, Java, Go and C# are removed. Review in Open-CMSIS-Pack#55.
- Verification. 736 unit tests and both transport suites pass. Four recorded behaviour baselines replay identically apart from the intended changes: the MCP surface, 33 scripted
gdbtargetsessions with their DAP traffic, 85 configuration scenarios and 153 executor cases. Not yet tried on hardware; this pre-release is for that.
[2.5.0] - 2026-09-23
Changed
- The code that still derived from microsoft/DebugMCP is replaced by independently written code (Open-CMSIS-Pack#53). The files are the MCP server, the debugging handler and executor, the debug state, secret redaction, the logger, the multi-window control server, registry and router, both configuration managers, extension activation, the esbuild/ESLint/test-runner configs and the skill-trigger scripts. Each was rewritten from a behaviour specification by an implementer who did not see the previous version. docs/provenance/ records the method, the specifications and the per-file result: at most five lines of any rewritten file occur anywhere in DebugMCP's history, and those are declarations the exported names dictate. No source file carries the Microsoft copyright line any more.
- Behaviour is unchanged, including the known bugs, which are fixed separately. Four recorded oracles replay identically:
- the agent-visible surface: tools, schemas, instructions, resources and every reply without a session;
- 28 scripted debug sessions, with their DAP requests and replies;
- 85 configuration scenarios, with every agent config file written byte for byte;
- 124 executor cases.
The wire protocol between windows and the registry format are unchanged, so windows on 2.3.10 and on this version still route to each other.
- New module layout. The tool registrations, resources and instructions move from
src/debugMCPServer.tstosrc/debugTools.ts. The executor splits intosrc/executor/(contract, snapshot, GDB memory ladder, reset, session reports), and the handler intosrc/handler/(fence,cmsis_action, flash, GDB and target texts, test hooks). - Texts that still matched DebugMCP are reworded, with the same meaning.
- The first two sentences of the server instructions.
- The descriptions of
stop_debugging,step_over,step_into,step_out,continue_execution,restart_debugging,remove_breakpoint,clear_all_breakpoints,list_breakpoints,list_variable_names,get_variables_valuesandevaluate_expression, the skill sentence ofstart_debugging, and six field descriptions (tools/list: 28 890 bytes). - Replies of the stop, restart, step, continue and breakpoint tools and the root-cause checkpoint on stop.
evaluate_expressionnow reports the type on its own line:Evaluated: …,Result: …,Type: …. - The redaction notice, the setup and migration notifications, the launch-configuration picker and the resource names.
- Documentation and configuration written anew.
- The architecture docs of the rewritten components, plus a new
docs/architecture/windowRouting.md. AGENTS.md, with stale facts corrected: 4-space indentation, Streamable HTTP only (/sseanswers 410),pdftotextoptional since pdf.js is bundled.- The root-cause part and the opening step list of the agent guide (
get_debug_instructions). tsconfig.json, with the same effective configuration.- A 39-line
.gitignorein place of the inherited Visual Studio template, whose[Bb]uild[Ll]og.*pattern once swallowedbuildLog.ts. What git tracks and ignores is unchanged, except that a root.vscode/folder is now ignored as a whole.
- The architecture docs of the rewritten components, plus a new
- The Python and C/C++ troubleshooting guides are written anew, and the C/C++ guide is now served. It is available as
cmsis-developer-assistant://docs/troubleshooting/cpp; before, it shipped but was never registered. It covers host programs and C/C++ firmware, and leaves target topics to the embedded guides. The resource descriptions now name the language, for example "Advice for debugging C/C++ programs".
Fixed
-
Failed tool calls are reported as failures (Open-CMSIS-Pack#11).
- Previously, 28 tools could never set MCP
isError: the debugging tools behind the handler fence, plus the documentation and build-artefact tools. Refusals such as "no active solution" or "Refusing to flash" came back as success text. - A failed call is now
isError, and its text starts with an error code and puts the next step on its own line, for example[NO_SESSION] Cannot read memory: …⏎No active debug session. …. structuredContentcarriesstatus,error_code,message,hintand, for several matching windows, the candidate list. A wait that ran out, or a build still running, is not a failure: it carries statustimeoutorrunning.- The codes are
NO_SESSION,TARGET_RUNNING,TIMEOUT,AMBIGUOUS_WINDOW,WINDOW_UNREACHABLE,WORKER_TIMEOUT,CMSIS_NO_SOLUTION,TASK_FAILED,PROBE_BUSY,PROBE_WEDGED,PORT_HELD,TOOL_DISABLED,INVALID_ARGUMENTandINTERNAL. - The server instructions, the skill and the agent guide explain how to read them.
tools/listis unchanged.
- Previously, 28 tools could never set MCP
-
A tool error in another VS Code window is no longer reported as "Could not reach the VS Code window … It may have been closed".
- The router now tells a failed call from a lost connection, and keeps its target window after a handler error or a worker timeout.
- The control channel between windows carries typed results. It uses envelope version 2, negotiated by a request header, and windows on 2.3.10 still interoperate.
-
cmsis_actionfollows the CMSIS task it started, and refuses when the probe is busy (Open-CMSIS-Pack#47, Open-CMSIS-Pack#46, Open-CMSIS-Pack#12).- Build and flash tasks are tracked as jobs, bound to the task execution they started. Load+Run counts as done when Load exited 0 and CMSIS Run has stayed up for 2 s.
- A task still running when the wait ends returns status
running.cmsis_action {action: "status"}reports the jobs and live CMSIS tasks of the window, and a repeatedbuildattaches to the one in flight instead of starting a second. timeoutMsforcmsis_actionandflashgoes up to 600 s. The default wait stays 60 s, because some clients cut longer calls.- load, erase, load_and_run, load_and_debug and
flashrefuse withPROBE_BUSYwhile a debug session or a CMSIS Run task holds the probe.attachto a running Run task stays allowed.stop_runwaits until the CMSIS tasks have ended and terminates leftovers itself. - Previously, task names such as "CMSIS Load" did not match the case-sensitive filter, and the end of any task counted as the end of the action.
- A missing task label fails at once with
INVALID_ARGUMENT.get_session_statusnames the CMSIS jobs and tasks. Aload_and_debugwhose session has no threads yet isrunning, not "did not survive".
-
flashuses the CMSIS Debugger's bundled pyOCD, then the one in.cmsis/tools-environment.yml, then PATH. It no longer advisespip install pyocd(part of Open-CMSIS-Pack#45). -
GDB commands reach GDB in CMSIS Debugger sessions (Open-CMSIS-Pack#56).
- We sent them as
-exec …. That is the Microsoft C/C++ adapter's prefix; the CMSIS Debugger's adapter (cdt-gdb-adapter) takes>and evaluated-exec …as a C expression. - As a result,
monitor reset, the GDB memory-read fallbacks and agents' ownevaluate_expression("-exec …")did nothing, andreseton J-Link often reported "did NOT appear to have reset". - Commands now use each adapter's own prefix. On
gdbtargetthe console output is collected and returned.evaluate_expressionaccepts-exec <command>and>command, and neither is secret-redacted. The memory fallbacks use expressions and MI-data-read-memory-bytes, andresetflushes GDB's register cache before it verifies.
- We sent them as
-
Breakpoints go through VS Code's model only, and logpoints on
gdbtargetare GDB dprintfs.- Previously,
add_breakpointalso sent GDBbreakandclear_all_breakpointssent GDBdelete. Once commands reach GDB, that would duplicate every breakpoint and delete the adapter's own. - Binding is now reported from the adapter's
verifiedstate and message, andlist_breakpointsshows it. - On
gdbtarget, logpoints are GDB dprintfs (MI-dprintf-insert), so{expr:%08lx}is filled in and a condition really applies. They are tracked by number, removed and cleared by number (never a baredelete), and listed with their hit counts. Other adapters keep VS Code logpoints.
- Previously,
-
Breakpoint changes and restarts are safe while a CMSIS target runs (Open-CMSIS-Pack#13).
add_breakpoint,add_logpoint,remove_breakpointandclear_all_breakpointspause a runninggdbtargettarget, apply the change, check it and resume, and say how long the target was paused.restart_debuggingpauses, then stops the session and starts its launch configuration again through the debug API, instead of the UI's restart command.- On
gdbtarget, a step, continue or pause refused with GDB's "target is running" returnsTARGET_RUNNINGinstead of retrying through VS Code's UI, where the refusal appeared as a toast.
-
The agent guides no longer claim that a breakpoint condition keeps the core from halting (the FPB has no condition logic; GDB evaluates the condition and resumes), and no longer advise
-exec break/-exec condition.
Added
- Provenance tooling for Open-CMSIS-Pack#53:
src/test/provenance.test.tskeeps any file from gaining the Microsoft copyright line.npm run provenance:checkmeasures each file against every commit of DebugMCP up to the last synced one;--gatefails on rewritten or new files above the limit.npm run test:surface,test/transport/dap-scenarios.js,test/transport/config-scenarios.jsandtest/transport/executor-cases.jsrecord and replay behaviour for refactorings.
Removed
dist/extension.js.mapanddist/pdfWorker.jsare no longer tracked.dist/has been ignored since 2026-09-03, both files are build output, and the source map embedded the pre-rewrite sources.vsc-extension-quickstart.md, the extension generator's template.- The JavaScript, Java, Go and C# troubleshooting guides, and the
troubleshooting/javascript,javaandcsharpresources (go.mdwas never served). Those languages can still be debugged through the same tools.
Pre-release (odd minor). Full changelog: https://github.com/MatthiasHertelArm/CMSIS-Developer-Assistant/blob/v2.5.0/CHANGELOG.md. Previous pre-release: https://github.com/MatthiasHertelArm/CMSIS-Developer-Assistant/releases/tag/v2.3.10. Built from branch pr/2.5.0-core-rewrite, based on Open-CMSIS-Pack main (2.3.10 plus Open-CMSIS-Pack#43); not yet proposed upstream. Open reviews: Open-CMSIS-Pack#54 (license), Open-CMSIS-Pack#55 (Python and C/C++ guides).