Skip to content

Windows: exception panel loses the exception message when netcoredbg reports <unknown module> #496

Open

Description

@MelbourneDeveloper

Problem

On Windows, the exception panel can show only "Exception thrown: 'System.ApplicationException' in " for a stop on an exception filter. The exception's message is missing. debug-exception-filters-e2e.test.ts › "exception filters changed mid-session take effect on the next throw" fails intermittently on the Windows debug-breakpoints shard because of it:

the exception panel must carry the message 'unhandled-by-design'; it reported 'Exception thrown: 'System.ApplicationException' in '

It failed on PR #494 at cbf910f3 and b6f14093 and passed at 2f5a7735 and 386aac60. The test has existed on main since #320.

Evidence

From the CI run's DAP trace (vsix-logs-win32-debug-breakpoints):

  • The stopped event names the module correctly: "reason":"exception","text":"Exception thrown: 'System.ApplicationException' in StepTarget.dll".
  • Every exceptionInfo for that thread, including two later retries, answers "description":"Exception thrown: 'System.ApplicationException' in <unknown module>", with details carrying no message and an empty stackTrace.
  • The earlier caught InvalidOperationException in the same session did get its message ('caught-by-design').

netcoredbg could not evaluate the exception object on that stop, and repeating exceptionInfo does not help.

Expected

The exception panel always carries the exception's message. The DAP router could fall back to the message the adapter can still produce, for example by evaluating $exception.Message. Failing that, the gap should be logged and, if it is a netcoredbg limitation, reported upstream.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions