Expose debug adapter as a standalone DAP server and a CLI trace tool#4
Open
RaoulSchaffranek wants to merge 3 commits into
Open
Expose debug adapter as a standalone DAP server and a CLI trace tool#4RaoulSchaffranek wants to merge 3 commits into
RaoulSchaffranek wants to merge 3 commits into
Conversation
Add two ways to use the trace-replay debug adapter outside VS Code, both thin wrappers over one shared vscode-free headless core (the DAP stepping engine is untouched): - soroban-dap: the debug adapter served over a TCP socket (net.createServer, one session per connection via a backend-selector constructor overload) so other DAP clients (nvim-dap, IntelliJ, Emacs) can drive it. Binds loopback by default; per-connection teardown disposes the backend on abrupt close. - soroban-trace: a one-shot CLI that emits a Rust-source-level execution trace as kind-tagged JSONL (meta/stop/result) for scripts, CI, and agents. Shared core in src/debugAdapter: backendFor (backend selector), buildStopModel (single source of truth for stop points, extracted from launchRequest), and pcAtIndex. CLI projection lives in src/trace; server in src/server. Both bins are bundled by esbuild; thin main.ts entry points are c8-excluded. Docs: docs/interfaces.md (design + JSONL schema) and docs/standalone-interfaces.md (usage), linked from the README. Full test coverage added (stopModel, backendFor, projectStop, runTrace, dapServer integration).
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.
Add two ways to use the trace-replay debug adapter outside VS Code, both thin wrappers over one shared vscode-free headless core (the DAP stepping engine is untouched):
Shared core in src/debugAdapter: backendFor (backend selector), buildStopModel (single source of truth for stop points, extracted from launchRequest), and pcAtIndex. CLI projection lives in src/trace; server in src/server. Both bins are bundled by esbuild; thin main.ts entry points are c8-excluded.
Docs: docs/interfaces.md (design + JSONL schema) and docs/standalone-interfaces.md (usage), linked from the README. Full test coverage added (stopModel, backendFor, projectStop, runTrace, dapServer integration).