Python ImportError:无法导入模块/类

时间:2014-11-12 09:44:18

标签: python importerror

从tap.py中复制导入行...

tap.py:

import site

import user

from site import security, agent

from site.security import models

当我跑步时,我得到了:

  File "/home/vikasadmin/user/tap.py", line 31, in init

    from site import security, agent

  File "/usr/lib/python2.6/site-packages/site/security.py", line 9, in <module>

    from site import models

  File "/usr/lib/python2.6/site-packages/site/models.py", line 12, in <module>

    from site import config

ImportError: cannot import name config

由于我已经从site.security导入了模型,因此应该包含此配置。请解释?我该如何解决这个问题?

0 个答案:

没有答案