In <58f7bd2a-ef82-4782-b4fb-db824f9c8...@googlegroups.com> 
smilesonisa...@gmail.com writes:

> > >   File "aaa.py", line 5, in <module>
> > 
> > >     from ccc.ddd import sss
> > 
> > > ImportError: No module named ccc.ddd
> > 
> > > directory structure as follows:
> > 
> > > ccc
> > > |
> > >  ddd
> > >    |
> > >     aaa.py
> > >     sss.py
>
> It is having __init__.py as blank in ccc and ddd directories. But it
> still doesnot work.

What directory are you in when you run your python command?  As written,
your import will only work if you're in the parent directory of ccc (or
that directory is in your PYTHONPATH.)

-- 
John Gordon         Imagine what it must be like for a real medical doctor to
gor...@panix.com    watch 'House', or a real serial killer to watch 'Dexter'.

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to