Replies: 3 comments
-
这个配置也不行,UI上没有反应 {
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "TestDebug:Python_attach",
"type": "python",
"request": "attach",
"port": 5678,
"host": "localhost",
"justMyCode": false
}
]
} |
Beta Was this translation helpful? Give feedback.
-
Calibre,包括其插件,都没很好的支持 IDE 调试器。在插件开发文档的 Debugging plugins 小节中有这样一段描述:
Calibre 作者在论坛的帖子中(1,2,3)也多次提到他从不使用 IDE 调试器,而是用简单的 不过针对调试 Calibre 的文档中 Using the debugger in your favorite Python IDE 这一小节倒是简略提到了支持 IDE 调试器。 不过我在测试以后发现这种调试方式不太可行。有些帖子(1、2、3)也有结合其他 IDE 使用调试器的讨论,但好像也都不太可行。 |
Beta Was this translation helpful? Give feedback.
-
这里有一个 Calibre 插件作者提供的插件开发指南也可以做一个参考。 |
Beta Was this translation helpful? Give feedback.
-
各位此前的贡献者们,你们是如何在IDE中调试插件的,求指教!
在插件中插入
from calibre.rpdb import set_trace; set_trace(port=5678)
,然后运行calibre-debug -g
,可以发现pdb成功监听。使用
calibre-debug -c "from calibre.rpdb import cli; cli(5678)"
可以在命令行中进入pdb可是如何在VSCode中使用pdb进行调试?
尝试配置launch.json,虽然运行成功,但之后UI上的debug操作都是灰色的,没法操作
Beta Was this translation helpful? Give feedback.
All reactions