PyCharm warns for unresolved reference builtin datetime module(PyCharm 警告未解决的参考内置日期时间模块)
问题描述
我刚刚安装了最新版本的 PyCharm (4.5).
I just installed the latest version of PyCharm (4.5).
现在我遇到了未解决的参考错误.在我的代码顶部,我有:
Now I am experiencing unresolved reference errors. On the top of my code I have:
from datetime import datetime
操作系统是 Ubuntu 15.04.已经多次进行无效缓存/重新启动.没有不同.我的项目的项目解释器设置为 Python 2.7.6.已经重新加载了 Interperter Paths.
OS is Ubuntu 15.04. Already did the Invalidate Cache/Restart several times. No difference. The Project interpreter of my project is set to Python 2.7.6. Already reloaded the Interperter Paths.
代码可以正常工作,只是 IDE 会产生烦人的错误并且不再自动完成.
Code works fine, it's just the IDE that produces an annoying error and no more autocomplete.
推荐答案
如前所述这里 尝试删除骨架文件夹的内容.它位于设置文件夹中(~/.PyCharmxxxx.xx/system/python_stubs)我不需要删除/添加 python 环境.删除内容(或整个 python_stubs 文件夹)后,只需重新启动 PyCharm
As mentioned here try to delete the content of the skeleton folder. It reside inside of the settingsfolder (~/.PyCharmxxxx.xx/system/python_stubs) Removing/adding the python environment was not necessary for me. Simply restart PyCharm after removing the content (or the whole python_stubs folder)
这对我有用,现在它再次像(py)魅力一样工作.
This does the trick for me and now it works like a (py)charm again.
这篇关于PyCharm 警告未解决的参考内置日期时间模块的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:PyCharm 警告未解决的参考内置日期时间模块


基础教程推荐
- 如何让 python 脚本监听来自另一个脚本的输入 2022-01-01
- 使用PyInstaller后在Windows中打开可执行文件时出错 2022-01-01
- Dask.array.套用_沿_轴:由于额外的元素([1]),使用dask.array的每一行作为另一个函数的输入失败 2022-01-01
- 用于分类数据的跳跃记号标签 2022-01-01
- 线程时出现 msgbox 错误,GUI 块 2022-01-01
- 何时使用 os.name、sys.platform 或 platform.system? 2022-01-01
- 筛选NumPy数组 2022-01-01
- 在 Python 中,如果我在一个“with"中返回.块,文件还会关闭吗? 2022-01-01
- 如何在海运重新绘制中自定义标题和y标签 2022-01-01
- Python kivy 入口点 inflateRest2 无法定位 libpng16-16.dll 2022-01-01