My structure of file is
foo/
__init__.py
bar.py
file __init__.py
def abc():
print 'ABC'
file bar.py
from foo import abc
I got this error.
Traceback (most recent call last):
File "foo/bar.py", line 1, in <module>
from foo import abc
ImportError: No module named foo
Use a relative import (requires Python 2.6 or greater):