gpt4 book ai didi

python-3.x - “NoneType”对象没有属性 'pydev_do_not_trace'

转载 作者:行者123 更新时间:2023-12-04 14:45:47 31 4
gpt4 key购买 nike

当我在 PyCharm 上设置远程项目解释器并设置断点运行 Debug模式时,我得到了这个异常。

Traceback (most recent call last):
File "/home/gaoge/.pycharm_helpers/pydev/_pydevd_bundle/pydevd_comm.py", line 1459, in do_it
result = pydevd_console_integration.console_exec(self.thread_id, self.frame_id, self.expression, dbg)
File "/home/gaoge/.pycharm_helpers/pydev/_pydevd_bundle/pydevd_console_integration.py", line 172, in console_exec
need_more = exec_code(CodeFragment(expression), updated_globals, frame.f_locals, dbg)
File "/home/gaoge/.pycharm_helpers/pydev/_pydevd_bundle/pydevd_console_integration.py", line 86, in exec_code
code_executor.interpreter.update(globals, locals)
File "/home/gaoge/.pycharm_helpers/pydev/_pydev_bundle/pydev_ipython_console_011.py", line 331, in update
self.ipython.history_manager.save_thread.pydev_do_not_trace = True #don't trace ipython history saving thread
AttributeError: 'NoneType' object has no attribute 'pydev_do_not_trace'

最佳答案

问题出在 PyCharm 的设置上,在“构建、执行和部署”部分,然后点击“控制台”,并取消勾选“如果可用则使用 iPython”选项。

对我来说,解决方案是每次遇到问题。我不知道它为什么有效,但确实有效。

关于python-3.x - “NoneType”对象没有属性 'pydev_do_not_trace',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57719708/

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com