如何在PyCharm的交互式调试器中评估协程

huangapple go评论65阅读模式
英文:

How to evaluate coroutine in pycharms interactive debugger

问题

当使用PyCharm的交互式调试器(断点)中断Python异步代码的执行时,我们可以使用PyCharm的调试工具(如“评估表达式”或“在Python控制台中执行行”)来检查环境。

我们如何在这些调试工具中评估协程?

英文:

When interrupting execution of python async code with PyCharm's interactive debugger (breakpoints) we can inspect the environment with PyCharm's debugging tools like "evaluate expression" or "Execute Line in Python Console".

How can we evaluate coroutines within these debugging tools?

答案1

得分: 3

目前无法做到,请投票支持 https://youtrack.jetbrains.com/issue/PY-22961

英文:

No way at the moment, please vote for https://youtrack.jetbrains.com/issue/PY-22961

答案2

得分: 3

你可以尝试使用 PyCharmEvaluate async code 插件,插件链接在 https://plugins.jetbrains.com/plugin/14476-evaluate-async-code

英文:

You can try to use PyCharm Evaluate async code plugin, link to plugin https://plugins.jetbrains.com/plugin/14476-evaluate-async-code

答案3

得分: 1

2022年10月更新

请确保您使用的是最新版本的PyCharm,因为他们表示已经添加了这个功能。
如何在PyCharm的交互式调试器中评估协程

英文:

Update from October 2022

Make sure you have the latest version of PyCharm, because they said they added this
如何在PyCharm的交互式调试器中评估协程

huangapple
  • 本文由 发表于 2020年1月6日 18:10:27
  • 转载请务必保留本文链接:https://go.coder-hub.com/59610164.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定