[Python-ideas] Detecting circular imports ?

Tarek Ziadé ziade.tarek at gmail.com
Thu Nov 18 16:14:35 CET 2010


This morning I tried to fix an issue for a while before I realized I
had a circular import. This issue is not obvious because you get a
cryptic error, like an AttributeError and it can tak a while before
finding out.

I don't know of this was mentioned before, or how hard it would be.
But it would be nice if Python had a specific "CircularImportError"
raised in that case, or something..
That would be a fabulous hint for developers.

Tarek Ziadé | http://ziade.org

More information about the Python-ideas mailing list