On Mon, 16 Apr 2012 09:54:41 +0200
Stefan Behnel <stefan...@behnel.de> wrote:
> 
> The new import cache broke Cython's load of on-the-fly compiled extension
> modules, which naively used "__import__(module_name)" after building them.
> I could fix that by moving to "imp.load_dynamic()" (we know where we put
> the compiled module anyway), although I just noticed that that's not
> actually documented. So I hope that won't break later on.

You can call importlib.invalidate_caches().
http://docs.python.org/dev/library/importlib.html#importlib.invalidate_caches

> The next thing I noticed is that the old-style level -1 import no longer
> works, which presumably breaks a *lot* of Cython compiled modules. It used
> to work in the master branch until two days ago, now it raises a
> ValueError. We may be able to fix this by copying over CPython's old import
> code into Cython, but I actually wonder if this was really intended. If
> this feature wasn't deliberately broken in Py3.0, why break it now?

Regressions should be reported on the bug tracker IMHO.

Regards

Antoine.


_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to