vscode: Add condition editing UI to breakpoint filters
With https://github.com/microsoft/debug-adapter-protocol/issues/137 “condition” support has arrived in the Debug Adapter Protocol.
This feature requests asks for adding condition editing UI for breakpoint filters.
Implementation sketch:
- if DA has capability
supportsExceptionFilterOptions
it will use the new protocol - the
exceptionBreakpointFilters
capability can now return asupportsCondition
property which indicates that VS Code should enable a “condition” edit UI for the exception filter. - when calling the
setExceptionBreakpoints
request the set of exceptions must be passed via thefilterOptions
property instead of thefilters
property. ThefilterOptions
property takes an array of pairs consisting of the breakpoint filter ID and an optional condition. If none of the exception filters has a condition, thefilters
property can be used.
Proposal for condition editing UI:
The simplest “condition” edit UI would be to provide a context menu action that opens an editable text box on top the exception filters name (identical to the function breakpoints, see green arrow below). If an exception filter has a condition, it could be rendered at the end of the exception’s name in a dimmed style (similar to the path style that we use for regular breakpoints; see red arrow):

/cc @connor4312
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 18 (18 by maintainers)
@weinand makes sense. We can keep it.
I have pushed a first version of this. I have tried this out with the Mock debug and seems to work fine. Try it out and let me know your toughts. I plan to write a test plan item, should I mention to use Mock debug or does some debug adapter already plan to support this?