Pycharm调试器在保留断点时出现错误。

问题描述 投票:0回答:1

**在我的一个项目中,我在Pycharm IDE 2019.2上使用Django==2.1.5,在调试时遇到了这个错误

1)我已经尝试过删除.idea文件夹并重新配置来解决这个问题,问题没有解决。

2)我试过卸载python,重新安装,问题没有解决。

3)我已经更新了Pycharm,并尝试了,问题没有解决同样的错误正在抛出。

Unhandled exception in thread started by <_pydev_bundle.pydev_monkey._NewThreadStartupWithTrace object at 0x0576E6F0>
Traceback (most recent call last):
  File "C:\Program Files\JetBrains\PyCharm 2019.2\helpers\pydev\_pydevd_bundle\pydevd_constants.py", line 328, in get_current_thread_id
AttributeError: '_DummyThread' object has no attribute '__pydevd_id__'

During handling of the above exception, another exception occurred:

SystemError: ..\Objects\codeobject.c:851: bad argument to internal function

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "C:\Program Files\JetBrains\PyCharm 2019.2\helpers\pydev\_pydev_bundle\pydev_monkey.py", line 718, in __call__
  File "C:\Program Files\JetBrains\PyCharm 2019.2\helpers\pydev\_pydevd_bundle\pydevd_constants.py", line 335, in get_current_thread_id
  File "C:\Program Files\JetBrains\PyCharm 2019.2\helpers\pydev\_pydevd_bundle\pydevd_constants.py", line 302, in _get_or_compute_thread_id_with_lock
SystemError: <built-in method __enter__ of _thread.lock object at 0x0144ADA0> returned a result with an error set
django python-3.x debugging pycharm
1个回答
1
投票

根据你给出的简短描述,我只能推测是问题所在 只是 中运行应用程序时,会发生 调试 模式。如果是这种情况,请尝试在您的 运行调试 在PyCharm中的配置 看看问题是否仍然发生。

PYDEVD_USE_CYTHON=NO
PYDEVD_USE_FRAME_EVAL=NO

请注意,这是一个临时的解决方案 - 你应该进一步调查问题的具体原因和其他解决方法。


同时注意,在今后的工作中,你应该提供更多关于项目配置的细节,异常发生的地点和时间 (繁殖方案)以及其他可以使其更容易成功识别问题的信息。

© www.soinside.com 2019 - 2024. All rights reserved.