def _filter_internal(iterable, return_internal):
    'Filter the internal elements of an iterable.'
    if return_internal:
        return iterable
    return [el for el in iterable if (not el.internal)]
Filter the internal elements of an iterable.
def _filter_internal(iterable, return_internal):
    
    if return_internal:
        return iterable
    return [el for el in iterable if (not el.internal)]