解决Pycharm无法导入包问题 Unresolved reference

在pycharm中设置source路径

file–>setting–>project:server–>project structure

将放package的文件夹设置为source,这样import的模块类等,就是通过这些source文件夹作为根路径来查找,也就是在这些source文件夹中查找import的东西。 
这里写图片描述

 

 

1.清除缓存并重启


2.设置源目录(注意设置的是哪个目录,这里是tutorial)

posted @ 2017-05-25 12:02  _liulin  阅读(27524)  评论(1编辑  收藏  举报