6
“'测试'模块导入错误”是什么意思?
我逐行复制了一个有效的测试,只是更改了几个名称(至少我想如此),现在我得到了一个非常神秘的错误:(我用FOO,BAR替换了一些东西) ImportError: 'tests' module incorrectly imported from 'FOO/exports/tests'. Expected 'FOO/exports'. Is this module globally installed? 问题是我根本不理解该错误。此错误消息是什么意思? 完整的堆栈跟踪: Traceback (most recent call last): File "BAR/modeling/manage.py", line 10, in <module> execute_from_command_line(sys.argv) File "/Users/jonathan/anaconda/lib/python2.7/site-packages/django/core/management/__init__.py", line 353, in execute_from_command_line utility.execute() File "/Users/jonathan/anaconda/lib/python2.7/site-packages/django/core/management/__init__.py", line 345, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/Users/jonathan/anaconda/lib/python2.7/site-packages/django/core/management/commands/test.py", line 30, in run_from_argv super(Command, …