Relative Imports, why the hell is it so hard?

Maxim Khitrov mkhitrov at gmail.com
Tue Mar 24 21:35:55 EDT 2009


On Tue, Mar 24, 2009 at 8:57 PM, Istvan Albert <istvan.albert at gmail.com> wrote:
> Does it not bother you that a module that uses relative imports cannot
> be run on its own anymore?

$ python --help
<snip>
-m mod : run library module as a script (terminates option list)
<snip>
$ python -m some.module.name

Works perfectly fine with relative imports.

- Max



More information about the Python-list mailing list