def _get_sudo_iterator(obj,methname):
    """Get the iterator flag for the given method.

    This searches the base classes of obj if the given method is not declared
    allowed_from_sudo, so that people don't have to constantly re-apply the
    decorator.
    """
    for base in _get_mro(obj):
        try:
            iterator = base.__dict__[methname]._esky_sudo_iterator
        except (KeyError,__HOLE__):
            pass
        else:
            return iterator
    return False
dataset/ETHPy150Open cloudmatrix/esky/esky/sudo/__init__.py/_get_sudo_iterator