

def autodocument_from_superclasses(cls):
    'Fill in missing documentation on overridden methods.\n\n    Can be used as a class decorator.\n    '
    undocumented = []
    for (name, attribute) in cls.__dict__.items():
        if (hasattr(attribute, '__call__') and (not attribute.__doc__)):
            if (not hasattr(attribute, '__module__')):
                continue
            for supercls in cls.__bases__:
                try:
                    superdoc = getattr(supercls, name).__doc__
                    if name:
                        setattr(attribute, '__doc__', superdoc)
                        break
                except (AttributeError, TypeError):
                    pass
    return cls

dataset/ETHPy150Open jek/flatland/flatland/util/base.py autodocument_from_superclasses/VarMisuse@94/155 `superdoc`->`name`