如何处理调用 pdb 的脚本错误?
我们编写运行时间较长的 python 测试脚本,因此我们尝试使脚本能够自动处理出现的错误并继续执行。我必须在我的整体测试流程中包含一个我无法控制的脚本,该脚本在遇到错误时启动 python 调试器。这会导致整个测试脚本停止以等待用户输入。
有没有一种方法可以调用脚本,以防止它在遇到错误时陷入 pdb,即使该脚本正在尝试使用调试器?
We write python test scripts with long run times, so we try to enable our scripts to handle errors that arise automatically and proceed. I have to include in my overall test flow a script that I have no control over, which initiates python debugger when it hits an error. This results in the whole test script halting to wait for user input.
Is there a way to call a script that prevents it from falling into pdb when it hits an error, even if that script is trying to engage the debugger?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论