Feature Request: Conditional Breakpoints
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 25/100
- Issue 类型
- 功能
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 技术栈
- python, typescript, vscode
- 领域
- devtools
调研方向
issue 中没有指定文件、测试或入口点。首先追踪 Python 调试器如何处理断点状态和求值;done 应覆盖针对空、无效、true 和 false 条件所列出的 UI 和行为案例。
由索引模型根据 Issue 内容生成。
描述
Motivation
For efficient debugging, I very often need to have a break-point trigger only under certain circumstances.
Consider the following setup
here I may for example only wish for the break point to trigger if
"advanced" in case.tags
holds.
Current workaround
Currently, I can achieve this, but only by rewriting the code as a workaround:
Proposal
The workaround is clearly clumsy, esp. as it means injecting code into ones codebase, which is en par with adding print statements everywhere.
What would be much more ideal would be one could simply add dynamic trigger-conditions to the break points.[^trigger]
For example in the UI would could add a right-click menu to the individual break points > add conditions > user entry of boolean expression:
Here one could consider the cases
| checkbox | trigger condition | behaviour |
|---|---|---|
| ☐ | * | never triggers |
| ✅ | (empty) | always triggers |
| ✅ | cannot be evaluated | never triggers |
| ✅ | can be evaluated and evaluates to true |
triggers in the given instance |
| ✅ | can be evaluated and evaluates to false |
does not trigger in the given instance |
[^trigger]: currently they can only statically be toggled.
- 主要语言
- TypeScript
- 星标
- 181
- 派生
- 126
- 平均合并
- 2 天 3 小时
- 30 天内合并 PR
- 3
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
microsoft/vscode-python-debugger 的其他 Issue
-
triage-needed
难度 2/5 1-3 小时 新手友好度 78/100
microsoft/vscode-python-debugger#1110 ·
-
triage-needed
难度 1/5 1-3 小时 新手友好度 88/100
microsoft/vscode-python-debugger#1024 · 1 条评论 ·
-
triage-needed
microsoft/vscode-python-debugger#1111 · 1 个 reaction · 已指派 1 人 ·
-
triage-needed
microsoft/vscode-python-debugger#1106 · 1 个 reaction · 已指派 2 人 ·
-
triage-needed
microsoft/vscode-python-debugger#1104 · 1 个 reaction · 已指派 1 人 ·
查看 microsoft/vscode-python-debugger 的全部 Issue
相似的 Issue
-
check:passed streams:add
难度 2/5 1-3 小时 新手友好度 68/100
-
难度 2/5 1-3 小时 新手友好度 76/100
-
难度 2/5 1-3 小时 新手友好度 68/100
-
usability
难度 2/5 1-3 小时 新手友好度 68/100
inmanta/web-console#7367 ·
-
难度 1/5 1 小时以内 新手友好度 78/100
nearform/ag-grid-url-sync#160 ·