> > >>> from inspect import isclass > > >>> > > >>> class x: > > ... def __getattr__( self, attr ): > > ... pass > > ... > > >>> y = x( ) > > >>> isclass( y ) > > True > > Which reinforces Michael Spencer's instinct that the inspect.isclass() > implementation is a bit too clever
Wouldn't the word 'broken' be more appropriate? :) > > isinstance(obj, (types.ClassType, type)) > Thanks a lot this indeed works. -- http://mail.python.org/mailman/listinfo/python-list