python - pycharm 调试失败

标签 python django python-2.7 pycharm jetbrains-ide

我是 Python 新手,正在尝试使用 PyCharm 运行脚本。当我运行脚本时,我得到以下输出

/usr/local/Cellar/python/2.7.10_2/Frameworks/Python.framework/Versions/2.7/bin/python2.7
-u /Applications/PyCharm CE.app/Contents/helpers/pydev/pydev_run_in_console.py 56230 56231 

/Users/chintan.shah/Documents/python-dev/python-scripts/src/examples/kalman_filter.py 29325

/usr/local/lib/python2.7/site-packages/IPython/utils/traitlets.py:5:
UserWarning: IPython.utils.traitlets has moved to a top-level traitlets package.
warn("IPython.utils.traitlets has moved to a top-level traitlets package.")

Running /Users/chintan.shah/Documents/python-dev/python-scripts/src/examples/kalman_filter.py
PyDev console: using IPython 4.0.0

此外,当我尝试调试时,代码不会在调试点停止,并且我收到警告

IPython.utils.traitlets has moved to a top-level traitlets package.
warn("IPython.utils.traitlets has moved to a top-level traitlets package.")

脚本应该显示一些绘图,但它没有。当我将整个文件复制粘贴到 PyCharm 的 Python 控制台中时,一切正常。

最佳答案

也许您已经安装了 IPython 4.0。如果是这种情况,我建议您降级您的版本。我也使用 Pycharm,在我的例子中我所做的是禁用 IPython,如以下链接所述:Disable ipython console in pycharm

关于python - pycharm 调试失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32329552/

相关文章:

python - 摘要用户登录 View

python - 值错误 : Dependency on app with no migrations: customuser

python - Scrapy 显示 notImplementedError 我不知道为什么

python - 当我们已经使用 import 加载了一个模块时,为什么 python 要求我们使用 from 语句

python - 如何限制 Flask 中的事件登录数

python - 切割波峰和波谷

python - 是否可以在不实例化类的情况下导入类方法?

Python ljust 在包含 lin 时无法正确显示

python - GeoDjango:如何获得两点之间的距离?

python - 如何找到虚假的打印语句?