Dnia Wed, 13 Aug 2008 20:55:38 +0000 (UTC), Kent Tenney napisa�(a):

> from image import annotate
>
> ImportError: cannot import name annotate
>
> I found the problem via 
>
> import image
> print image.__file__
>
> which made it clear that the wrong image module had been found.
>
> It would be nice if ImportError announced this up front.

Then go for it :-) You can prepare a patch and ask on python-dev
if the developers are interested.

I was never hacking the import things on C level before,
but a hint: you have to modify import_from function from
Python/ceval.c

My quick attempt:
http://www.stud.umk.pl/~wojtekwa/patches/from-import-py2.5.1.patch


-- 
Regards,
Wojtek Walczak,
http://www.stud.umk.pl/~wojtekwa/
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to