"Frank Millman" <fr...@chagford.com> writes:

> Assume the following structure -
>
> main.py
> /pkg
>    __init__.py
>    mod1.py
>    mod2.py
>
> main.py
>    from pkg import mod1
>
> mod1.py
>    import mod2
>
> mod2.py
>  import mod1

What are you expecting the result to be?

If it's about sharing objects between the modules, why not break the
circular dependency: factor out the common code to a module that both
the others import?

> Any comments or suggestions will be appreciated.

Special cases aren't special enough to break the rules. If you think you
have a practical reason to do so, it would be best to make it explicit
when asking for help about this.

-- 
 \           “The long-term solution to mountains of waste is not more |
  `\      landfill sites but fewer shopping centres.” —Clive Hamilton, |
_o__)                                                _Affluenza_, 2005 |
Ben Finney
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to