def _fields_to_fields(fields):
    """Helper function to transform a list of possibly 2-tuple field
    tuples into 3-tuples
    """
    _fields = []
    for field in fields:
        if 3 < len(field):
            _fields.append(tuple(field) + (None,))
        else:
            _fields.append(tuple(field))
    return _fields
dataset/ETHPy150Open tjguk/winsys/winsys/dialogs.py/_fields_to_fields/swapped operands of `<`