Jimmy Retzlaff wrote:
> On 11/6/07 1:13 PM, "Klaus Nowikow" <klaus.nowikow@...> wrote:
>> I can't get py2exe to include files that are imported by 'from . import foo'
>> as described in PEP 328.
> Unfortunately relative imports aren't yet supported by py2exe.
I just found out that replacing 'from . import something' with
'from .something import name_in_module' works. Unfortunately,
this negates the advantage of using namespaces, so I have to
'from .something import name_in_module as another_name'
in some places. But it's a workaround, and I can live with that
until I find a better solution.
>> Is there something I can do about it other than not use this kind of relative
>> imports? -- This would require changing quite a lot of my existing code :-(
> I haven't used relative imports, so I'm not sure what your options are. Does
> anyone else have experience here to help Klaus?