clusterflux-public/docs/debugging.md
Clusterflux release 6acd2d6eb7 Public release release-55b5a563d642
Source commit: 55b5a563d6421f49b5f5e77bc3c1f29752da8801

Public tree identity: sha256:52790e23e2b1806b00cc220c92edcfeed445600dcde620342af2b3369e7883fa
2026-07-16 17:13:43 +02:00

42 lines
1.8 KiB
Markdown

# Debugging
The VS Code extension uses the Debug Adapter Protocol and the coordinator's
authoritative process, task, attempt, and Debug Epoch APIs.
## Launch
Open your project and start "Clusterflux: Launch Virtual Process". The adapter
builds the bundle, launches the selected entrypoint, and replaces its thread
view with coordinator task snapshots. Product mode does not infer threads from
completion events or demo fixtures.
Each task view includes its logical task, attempt ID, definition, state, node,
environment, arguments, typed handles, command status, VFS checkpoint, probe
source when known, and restart compatibility. Unknown source remains unknown.
## Breakpoints and Debug Epochs
When a breakpoint is hit, the coordinator asks every active participant to
freeze. A fully frozen epoch is a consistent all-participant view.
If one or more participants cannot freeze within five seconds, the epoch becomes
partially frozen when at least one participant did freeze. The adapter warns
that running and frozen tasks do not form a consistent global snapshot. You may
inspect the acknowledged participants and resume them cleanly. Missing or failed
participants remain explicit.
Stack frames, Wasm locals, task arguments, handles, command status, and output
come from runtime acknowledgements. No frame or value is fabricated when the
runtime did not report it.
## Continue and restart
Continue resumes only participants that acknowledged the freeze.
Restarting a terminal task rebuilds the bundle and checks its clean entry
checkpoint. A compatible restart creates a new attempt under the same logical
task identity. Earlier attempt history remains inspectable, and the logical join
continues. An active task or an incompatible boundary requires a whole-process
restart.
Source stepping is not simulated. Unsupported stepping fails explicitly.