Skip to content

Logs and Diagnostics

The Logs panel is where you find out what the debugger and the adapter are actually doing. When something does not work, this is the first place to look. Ctrl+L opens it.

Four sources in one feed

The feed merges four categories, each with its own toggle:

Category What it carries
Program stdout and stderr of the program you are debugging
Session phase changes, adapter start and death, refused DAP requests
DAP the full trace of requests and responses
Adapter stderr of the adapter itself (dlv, codelldb, debugpy)

DAP is off by default because it is by far the noisiest. Records are collected regardless of the toggles, so you can switch it on after something went wrong and still see what happened.

Reading timestamps

Time is shown relative to the start of the session — +MM:SS.mmm — and the count restarts after the ── new session ── separator.

Relative time is the more useful answer to the question people actually have while staring at a stuck debugger: how long has this been hanging?

A long request announces itself

Every 30 seconds, a request that has not been answered is noted in the SESSION category:

+00:30.001 SESSION request `launch` running 30 s (mode=debug, program=/repo/cmd/api):
                   dlv (pid 43912) has not answered yet; timeout in 90 s
+01:00.002 SESSION request `launch` running 60 s (mode=debug, program=/repo/cmd/api):
                   dlv (pid 43912) has not answered yet; timeout in 60 s

A silent debugger is indistinguishable from a hung one, so the line carries everything needed to decide what to do: how long it has been waiting, how long remains, which process is holding the answer — the pid makes it visible in ps — and what is being launched.

Buffer, copying and saving

The feed keeps the last 20 000 records.

Action What it does
Copy copies what is currently visible, respecting the filters
Save writes the entire buffer, ignoring the filters, to <project>/.bugsaur/logs/<unix-ms>.log

Use Save when reporting a problem: filters that hid the cause from you would hide it from whoever reads the report.

Scrolling

The feed follows its tail by default. G turns following off so you can read without being dragged along; Shift+G turns it back on and jumps to the end.

Secrets never reach the log

Values of env do not appear in the log or in this panel: DAP request bodies are not printed. This is an invariant, not a side effect — request tracing cannot be extended without stripping env values first.

When a long request is reported, only mode and program are taken from the request body for exactly this reason.

What to attach to a bug report

  1. Save the log — the whole buffer, not a screenshot of the visible part.
  2. The relevant profile from .bugsaur/config.toml.
  3. The adapter version (dlv version, codelldb --version, python3 -m debugpy --version).
  4. What you expected to happen and what happened instead.

More on turning a log into a diagnosis: Troubleshooting → Reading logs.