New submission from Thomas Guettler: AFAIK cls.__subclasses__() only returns the classes which the interpreter has already loaded.
This means there can be more subclasses in modules where not imported by the current interpreter up to now. https://docs.python.org/3.7/library/stdtypes.html?highlight=subclasses#class.__subclasses__ I think it would be nice to add a hint to the docs that python imports are lazy. What do you think? ---------- messages: 298527 nosy: guettli priority: normal severity: normal status: open title: Docs for __subclasses__(): Add hint that Python imports are lazy _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue30948> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com