【Others】Pycharm无法debug解决办法

错误提示:

Traceback (most recent call last):
  File "/snap/pycharm-professional/139/helpers/pydev/pydevd.py", line 36, in 
    from _pydevd_bundle.pydevd_additional_thread_info import set_additional_thread_info
  File "/snap/pycharm-professional/139/helpers/pydev/_pydevd_bundle/pydevd_additional_thread_info.py", line 17, in 
    from _pydevd_bundle.pydevd_cython_wrapper import PyDBAdditionalThreadInfo, set_additional_thread_info, _set_additional_thread_info_lock
  File "/snap/pycharm-professional/139/helpers/pydev/_pydevd_bundle/pydevd_cython_wrapper.py", line 38, in 
    trace_dispatch = mod.trace_dispatch
AttributeError: module '_pydevd_bundle_ext.pydevd_cython' has no attribute 'trace_dispatch'

有两个地方,一个只管当前脚本,一个管项目下所有脚本。在这两个地方的环境变量处添加一句话就好了。

下图是只管当前脚本的:

【Others】Pycharm无法debug解决办法_第1张图片

下图管项目下所有脚本的:

【Others】Pycharm无法debug解决办法_第2张图片

在Environment variables中添加:

PYDEVD_USE_FRAME_EVAL=NO;PYDEVD_USE_CYTHON=NO

 

你可能感兴趣的:(Others)